From 589e70ee5b8fbdc040c981a7e379759c36e5910b Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Wed, 21 Jun 2023 12:12:08 -0700 Subject: [PATCH 01/56] Fix variant propagation with exception to spec --- var/spack/repos/builtin.mock/packages/openblas/package.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/var/spack/repos/builtin.mock/packages/openblas/package.py b/var/spack/repos/builtin.mock/packages/openblas/package.py index 33a6e20d514d63..51ba404b559da2 100644 --- a/var/spack/repos/builtin.mock/packages/openblas/package.py +++ b/var/spack/repos/builtin.mock/packages/openblas/package.py @@ -17,6 +17,8 @@ class Openblas(Package): version("0.2.14", md5="b1190f3d3471685f17cfd1ec1d252ac9") version("0.2.13", md5="b1190f3d3471685f17cfd1ec1d252ac9") + depends_on("zlib") + variant("shared", default=True, description="Build shared libraries") # See #20019 for this conflict From d1c9054f7405e32097a84d4f81f8db5602589ac3 Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Mon, 26 Jun 2023 16:56:20 -0700 Subject: [PATCH 02/56] Add test for all unify options in env --- lib/spack/spack/test/concretize.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/spack/spack/test/concretize.py b/lib/spack/spack/test/concretize.py index fd5bd7d9c59684..759812627ddcea 100644 --- a/lib/spack/spack/test/concretize.py +++ b/lib/spack/spack/test/concretize.py @@ -18,6 +18,7 @@ import spack.config import spack.deptypes as dt import spack.detection +import spack.environment as ev import spack.error import spack.hash_types as ht import spack.platforms @@ -25,9 +26,12 @@ import spack.solver.asp import spack.variant as vt from spack.concretize import find_spec +from spack.main import SpackCommand from spack.spec import CompilerSpec, Spec from spack.version import Version, ver +env = SpackCommand("env") + def check_spec(abstract, concrete): if abstract.versions.concrete: From c4247ee4f00cb1c5134cf0c9aef8a7a964738867 Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Wed, 28 Jun 2023 10:54:49 -0700 Subject: [PATCH 03/56] Make sure variants are propagated w/o using path --- var/spack/repos/builtin.mock/packages/netlib-lapack/package.py | 1 + var/spack/repos/builtin.mock/packages/perl/package.py | 2 ++ 2 files changed, 3 insertions(+) diff --git a/var/spack/repos/builtin.mock/packages/netlib-lapack/package.py b/var/spack/repos/builtin.mock/packages/netlib-lapack/package.py index dd6a24ee5ec80d..378c19ea11b5fa 100644 --- a/var/spack/repos/builtin.mock/packages/netlib-lapack/package.py +++ b/var/spack/repos/builtin.mock/packages/netlib-lapack/package.py @@ -14,3 +14,4 @@ class NetlibLapack(Package): provides("lapack") depends_on("blas") + depends_on("perl") diff --git a/var/spack/repos/builtin.mock/packages/perl/package.py b/var/spack/repos/builtin.mock/packages/perl/package.py index 1025efb2e9316b..b35f741b699650 100644 --- a/var/spack/repos/builtin.mock/packages/perl/package.py +++ b/var/spack/repos/builtin.mock/packages/perl/package.py @@ -14,3 +14,5 @@ class Perl(Package): extendable = True version("0.0.0", md5="abcdef1234567890abcdef1234567890") + + variant("shared", default=True, description="Build a shared libperl.so library") From 285944c69bddd605798e11fdd5bfe826e8760065 Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Wed, 28 Jun 2023 11:05:09 -0700 Subject: [PATCH 04/56] Remove unnecessary additions to tests --- var/spack/repos/builtin.mock/packages/netlib-lapack/package.py | 1 - var/spack/repos/builtin.mock/packages/perl/package.py | 2 -- 2 files changed, 3 deletions(-) diff --git a/var/spack/repos/builtin.mock/packages/netlib-lapack/package.py b/var/spack/repos/builtin.mock/packages/netlib-lapack/package.py index 378c19ea11b5fa..dd6a24ee5ec80d 100644 --- a/var/spack/repos/builtin.mock/packages/netlib-lapack/package.py +++ b/var/spack/repos/builtin.mock/packages/netlib-lapack/package.py @@ -14,4 +14,3 @@ class NetlibLapack(Package): provides("lapack") depends_on("blas") - depends_on("perl") diff --git a/var/spack/repos/builtin.mock/packages/perl/package.py b/var/spack/repos/builtin.mock/packages/perl/package.py index b35f741b699650..1025efb2e9316b 100644 --- a/var/spack/repos/builtin.mock/packages/perl/package.py +++ b/var/spack/repos/builtin.mock/packages/perl/package.py @@ -14,5 +14,3 @@ class Perl(Package): extendable = True version("0.0.0", md5="abcdef1234567890abcdef1234567890") - - variant("shared", default=True, description="Build a shared libperl.so library") From be60ed83e56e4db9432b75489724770fc5928f75 Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Mon, 17 Jul 2023 08:38:44 -0700 Subject: [PATCH 05/56] Propagate when concretizing separately --- lib/spack/spack/spec.py | 8 +++++++- lib/spack/spack/variant.py | 8 ++++---- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/lib/spack/spack/spec.py b/lib/spack/spack/spec.py index 270cf5eaf278f9..1cfba5697ad21b 100644 --- a/lib/spack/spack/spec.py +++ b/lib/spack/spack/spec.py @@ -2046,6 +2046,9 @@ def to_node_dict(self, hash=ht.dag_hash): params = syaml.syaml_dict(sorted(v.yaml_entry() for _, v in self.variants.items())) + for k, v in params.items(): + params[k] = (params[k], self.variants[k].propagate) + # Only need the string compiler flag for yaml file params.update( sorted( @@ -5028,7 +5031,10 @@ def from_node_dict(cls, node): for val in values: spec.compiler_flags.add_flag(name, val, False) else: - spec.variants[name] = vt.MultiValuedVariant.from_node_dict(name, values) + if isinstance(values, tuple): + spec.variants[name] = vt.MultiValuedVariant.from_node_dict(name, values[0], values[1]) + else: + spec.variants[name] = vt.MultiValuedVariant.from_node_dict(name, values) spec.external_path = None spec.external_modules = None diff --git a/lib/spack/spack/variant.py b/lib/spack/spack/variant.py index 1c6931d40e6a3f..24c86072a4d98f 100644 --- a/lib/spack/spack/variant.py +++ b/lib/spack/spack/variant.py @@ -255,19 +255,19 @@ def __init__(self, name, value, propagate=False): self.value = value @staticmethod - def from_node_dict(name, value): + def from_node_dict(name, value, propagate=False): """Reconstruct a variant from a node dict.""" if isinstance(value, list): # read multi-value variants in and be faithful to the YAML - mvar = MultiValuedVariant(name, ()) + mvar = MultiValuedVariant(name, (), propagate) mvar._value = tuple(value) mvar._original_value = mvar._value return mvar elif str(value).upper() == "TRUE" or str(value).upper() == "FALSE": - return BoolValuedVariant(name, value) + return BoolValuedVariant(name, value, propagate) - return SingleValuedVariant(name, value) + return SingleValuedVariant(name, value, propagate) def yaml_entry(self): """Returns a key, value tuple suitable to be an entry in a yaml dict. From 39199ba9df8c6d5409fbf77754494f0fb7e0e846 Mon Sep 17 00:00:00 2001 From: RikkiButler20 <39577672+RikkiButler20@users.noreply.github.com> Date: Mon, 17 Jul 2023 16:45:13 +0000 Subject: [PATCH 06/56] [@spackbot] updating style on behalf of RikkiButler20 --- lib/spack/spack/spec.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/spack/spack/spec.py b/lib/spack/spack/spec.py index 1cfba5697ad21b..ebf4c0fd769d1c 100644 --- a/lib/spack/spack/spec.py +++ b/lib/spack/spack/spec.py @@ -5032,7 +5032,9 @@ def from_node_dict(cls, node): spec.compiler_flags.add_flag(name, val, False) else: if isinstance(values, tuple): - spec.variants[name] = vt.MultiValuedVariant.from_node_dict(name, values[0], values[1]) + spec.variants[name] = vt.MultiValuedVariant.from_node_dict( + name, values[0], values[1] + ) else: spec.variants[name] = vt.MultiValuedVariant.from_node_dict(name, values) From 31dbf8291b712840972b1cef1fdb63240ed8a955 Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Tue, 18 Jul 2023 09:55:55 -0700 Subject: [PATCH 07/56] Create propagation namedtuple --- lib/spack/spack/spec.py | 11 +++++------ lib/spack/spack/test/concretize.py | 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/lib/spack/spack/spec.py b/lib/spack/spack/spec.py index ebf4c0fd769d1c..275e117a12803d 100644 --- a/lib/spack/spack/spec.py +++ b/lib/spack/spack/spec.py @@ -2047,7 +2047,8 @@ def to_node_dict(self, hash=ht.dag_hash): params = syaml.syaml_dict(sorted(v.yaml_entry() for _, v in self.variants.items())) for k, v in params.items(): - params[k] = (params[k], self.variants[k].propagate) + if self.variants[k].propagate: + params[k] = PropagateValue(params[k], self.variants[k].propagate) # Only need the string compiler flag for yaml file params.update( @@ -5031,12 +5032,10 @@ def from_node_dict(cls, node): for val in values: spec.compiler_flags.add_flag(name, val, False) else: - if isinstance(values, tuple): - spec.variants[name] = vt.MultiValuedVariant.from_node_dict( - name, values[0], values[1] - ) + if isinstance(values, PropagateValue): + spec.variants[name] = vt.AbstractVariant.from_node_dict(name, values.value, values.propagate) else: - spec.variants[name] = vt.MultiValuedVariant.from_node_dict(name, values) + spec.variants[name] = vt.AbstractVariant.from_node_dict(name, values) spec.external_path = None spec.external_modules = None diff --git a/lib/spack/spack/test/concretize.py b/lib/spack/spack/test/concretize.py index 759812627ddcea..f6ff8f7c7b8ae7 100644 --- a/lib/spack/spack/test/concretize.py +++ b/lib/spack/spack/test/concretize.py @@ -1474,7 +1474,7 @@ def test_non_default_provider_of_multiple_virtuals(self): @pytest.mark.regression("27237") @pytest.mark.parametrize( "spec_str,expect_installed", - [("mpich", True), ("mpich+debug", False), ("mpich~debug", True)], + [("mpich", True), ("mpich+debug", False), ("mpich~debug", True), ("mpich++debug", False)], ) @pytest.mark.only_clingo("Use case not supported by the original concretizer") def test_concrete_specs_are_not_modified_on_reuse( From 4d6e7f159dbfcbfab0416e1c570a2229056ac212 Mon Sep 17 00:00:00 2001 From: RikkiButler20 <39577672+RikkiButler20@users.noreply.github.com> Date: Tue, 18 Jul 2023 17:27:16 +0000 Subject: [PATCH 08/56] [@spackbot] updating style on behalf of RikkiButler20 --- lib/spack/spack/spec.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/spack/spack/spec.py b/lib/spack/spack/spec.py index 275e117a12803d..7c4a33b5ff940a 100644 --- a/lib/spack/spack/spec.py +++ b/lib/spack/spack/spec.py @@ -5033,7 +5033,9 @@ def from_node_dict(cls, node): spec.compiler_flags.add_flag(name, val, False) else: if isinstance(values, PropagateValue): - spec.variants[name] = vt.AbstractVariant.from_node_dict(name, values.value, values.propagate) + spec.variants[name] = vt.AbstractVariant.from_node_dict( + name, values.value, values.propagate + ) else: spec.variants[name] = vt.AbstractVariant.from_node_dict(name, values) From 79c3066443ab507f46aa6896d311f30d50fa9e1b Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Thu, 17 Aug 2023 14:58:16 -0700 Subject: [PATCH 09/56] Only propagate the specified variant --- lib/spack/spack/test/concretize.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/lib/spack/spack/test/concretize.py b/lib/spack/spack/test/concretize.py index f6ff8f7c7b8ae7..0e0c71b72f4c8c 100644 --- a/lib/spack/spack/test/concretize.py +++ b/lib/spack/spack/test/concretize.py @@ -18,7 +18,6 @@ import spack.config import spack.deptypes as dt import spack.detection -import spack.environment as ev import spack.error import spack.hash_types as ht import spack.platforms @@ -30,8 +29,6 @@ from spack.spec import CompilerSpec, Spec from spack.version import Version, ver -env = SpackCommand("env") - def check_spec(abstract, concrete): if abstract.versions.concrete: From b96a16b5e2df78dd415d7d5b90f0213262417a15 Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Thu, 24 Aug 2023 11:04:02 -0700 Subject: [PATCH 10/56] Propagation to work with new concretizer --- test/.spack-env/transaction_lock | 0 .../builtin.mock/packages/splice-b/package.py | 29 +++++++++++++++++++ 2 files changed, 29 insertions(+) create mode 100755 test/.spack-env/transaction_lock create mode 100644 var/spack/repos/builtin.mock/packages/splice-b/package.py diff --git a/test/.spack-env/transaction_lock b/test/.spack-env/transaction_lock new file mode 100755 index 00000000000000..e69de29bb2d1d6 diff --git a/var/spack/repos/builtin.mock/packages/splice-b/package.py b/var/spack/repos/builtin.mock/packages/splice-b/package.py new file mode 100644 index 00000000000000..549250f7b21005 --- /dev/null +++ b/var/spack/repos/builtin.mock/packages/splice-b/package.py @@ -0,0 +1,29 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class SpliceB(Package): + """Simple package with one optional dependency""" + + homepage = "http://www.example.com" + url = "http://www.example.com/splice-b-1.0.tar.gz" + + version("1.0", md5="0123456789abcdef0123456789efghij") + + variant("foo", default=False, description="nope") + variant("bar", default=False, description="nope") + variant("baz", default=False, description="nope") + + depends_on("splice-a") + + provides("something") + provides("somethingelse") + + def install(self, spec, prefix): + with open(prefix.join("splice-b"), "w") as f: + f.write("splice-b: {0}".format(prefix)) + f.write("splice-z: {0}".format(spec["splice-z"].prefix)) From a6f7b4fd3d366421f9f17a956d07137a4d9e3fdc Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Mon, 28 Aug 2023 16:04:42 -0700 Subject: [PATCH 11/56] Test that only specified variant propagates --- lib/spack/spack/test/cmd/pkg.py | 2 +- lib/spack/spack/test/concretize.py | 12 ++++++++++++ .../repos/builtin.mock/packages/splice-b/package.py | 2 +- 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/lib/spack/spack/test/cmd/pkg.py b/lib/spack/spack/test/cmd/pkg.py index 56a1f1f78676e8..6394ed4d31bab7 100644 --- a/lib/spack/spack/test/cmd/pkg.py +++ b/lib/spack/spack/test/cmd/pkg.py @@ -303,7 +303,7 @@ def test_pkg_grep(mock_packages, capfd): output, _ = capfd.readouterr() assert output.strip() == "\n".join( spack.repo.PATH.get_pkg_class(name).module.__file__ - for name in ["splice-a", "splice-h", "splice-t", "splice-vh", "splice-z"] + for name in ["splice-a", "splice-b", "splice-h", "splice-t", "splice-vh", "splice-z"] ) # ensure that this string isn't fouhnd diff --git a/lib/spack/spack/test/concretize.py b/lib/spack/spack/test/concretize.py index 0e0c71b72f4c8c..7d40243762bf5a 100644 --- a/lib/spack/spack/test/concretize.py +++ b/lib/spack/spack/test/concretize.py @@ -525,6 +525,18 @@ def test_concretize_propagate_multivalue_variant(self): assert not spec.satisfies("^a foo=bar") assert not spec.satisfies("^b foo=bar") + + def test_concretize_propagate_specified_variant(self): + """Test that only the specified variant is propagated to the dependencies""" + spec = Spec("splice-b++bar") + spec.concretize() + + assert spec.satisfies("^splice-a+bar") + assert spec.satisfies("^splice-z+bar") + assert not spec.satisfies("^splice-a+foo") + assert not spec.satisfies("^splice-z+foo") + + def test_no_matching_compiler_specs(self, mock_low_high_config): # only relevant when not building compilers as needed with spack.concretize.enable_compiler_existence_check(): diff --git a/var/spack/repos/builtin.mock/packages/splice-b/package.py b/var/spack/repos/builtin.mock/packages/splice-b/package.py index 549250f7b21005..b539b9bcb6422d 100644 --- a/var/spack/repos/builtin.mock/packages/splice-b/package.py +++ b/var/spack/repos/builtin.mock/packages/splice-b/package.py @@ -14,7 +14,7 @@ class SpliceB(Package): version("1.0", md5="0123456789abcdef0123456789efghij") - variant("foo", default=False, description="nope") + variant("foo", default=True, description="nope") variant("bar", default=False, description="nope") variant("baz", default=False, description="nope") From 328f7ee00d7b23ad395128d79692191140e4791f Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Tue, 29 Aug 2023 13:08:25 -0700 Subject: [PATCH 12/56] Remove extra spaces --- lib/spack/spack/test/concretize.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/spack/spack/test/concretize.py b/lib/spack/spack/test/concretize.py index 7d40243762bf5a..affe39b6f475c3 100644 --- a/lib/spack/spack/test/concretize.py +++ b/lib/spack/spack/test/concretize.py @@ -525,7 +525,10 @@ def test_concretize_propagate_multivalue_variant(self): assert not spec.satisfies("^a foo=bar") assert not spec.satisfies("^b foo=bar") - + @pytest.mark.skipif( + os.environ.get("SPACK_TEST_SOLVER") == "original", + reason="Optional compiler propagation isn't deprecated for original concretizer", + ) def test_concretize_propagate_specified_variant(self): """Test that only the specified variant is propagated to the dependencies""" spec = Spec("splice-b++bar") @@ -536,7 +539,6 @@ def test_concretize_propagate_specified_variant(self): assert not spec.satisfies("^splice-a+foo") assert not spec.satisfies("^splice-z+foo") - def test_no_matching_compiler_specs(self, mock_low_high_config): # only relevant when not building compilers as needed with spack.concretize.enable_compiler_existence_check(): From 4e00cc07cbaa008e129ccd245d9f5de532174d3f Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Wed, 6 Sep 2023 10:11:50 -0700 Subject: [PATCH 13/56] Remove unnneeded file --- test/.spack-env/transaction_lock | 0 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100755 test/.spack-env/transaction_lock diff --git a/test/.spack-env/transaction_lock b/test/.spack-env/transaction_lock deleted file mode 100755 index e69de29bb2d1d6..00000000000000 From 9a116a6a8e4e89e950b4a1f6934f7fe9585c219f Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Thu, 5 Oct 2023 11:21:32 -0700 Subject: [PATCH 14/56] Test should only run if using clingo --- lib/spack/spack/test/concretize.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/spack/spack/test/concretize.py b/lib/spack/spack/test/concretize.py index affe39b6f475c3..dc03cb9f73371c 100644 --- a/lib/spack/spack/test/concretize.py +++ b/lib/spack/spack/test/concretize.py @@ -525,9 +525,8 @@ def test_concretize_propagate_multivalue_variant(self): assert not spec.satisfies("^a foo=bar") assert not spec.satisfies("^b foo=bar") - @pytest.mark.skipif( - os.environ.get("SPACK_TEST_SOLVER") == "original", - reason="Optional compiler propagation isn't deprecated for original concretizer", + @pytest.mark.only_clingo( + "Optional compiler propagation isn't deprecated for original concretizer" ) def test_concretize_propagate_specified_variant(self): """Test that only the specified variant is propagated to the dependencies""" From 2ed52ce96c9e5ac1f5d500882a23270e339cdcb5 Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Thu, 5 Oct 2023 13:58:30 -0700 Subject: [PATCH 15/56] Create new mock packages Instead of modifying existing ones --- var/spack/repos/builtin.mock/packages/bzip2/package.py | 7 +++++++ var/spack/repos/builtin.mock/packages/openblas/package.py | 2 -- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/var/spack/repos/builtin.mock/packages/bzip2/package.py b/var/spack/repos/builtin.mock/packages/bzip2/package.py index 326533ac5ea117..5a85dfe5e9913a 100644 --- a/var/spack/repos/builtin.mock/packages/bzip2/package.py +++ b/var/spack/repos/builtin.mock/packages/bzip2/package.py @@ -8,11 +8,18 @@ class Bzip2(Package): +<<<<<<< HEAD """This packagae has the variants shared defaulted to True""" homepage = "https://example.com" url = "https://example.com/bzip2-1.0.8tar.gz" +======= + """This is a thing""" + + homepage = "https://someplace.com" + url = "https://anotherplace.com" +>>>>>>> f3d2d06bd6 (Create new mock packages) version("1.0.8", sha256="ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269") diff --git a/var/spack/repos/builtin.mock/packages/openblas/package.py b/var/spack/repos/builtin.mock/packages/openblas/package.py index 51ba404b559da2..33a6e20d514d63 100644 --- a/var/spack/repos/builtin.mock/packages/openblas/package.py +++ b/var/spack/repos/builtin.mock/packages/openblas/package.py @@ -17,8 +17,6 @@ class Openblas(Package): version("0.2.14", md5="b1190f3d3471685f17cfd1ec1d252ac9") version("0.2.13", md5="b1190f3d3471685f17cfd1ec1d252ac9") - depends_on("zlib") - variant("shared", default=True, description="Build shared libraries") # See #20019 for this conflict From 95a55588b582cd1e51ef590c0c87be9d15fc8c1e Mon Sep 17 00:00:00 2001 From: Richarda Butler <39577672+RikkiButler20@users.noreply.github.com> Date: Thu, 5 Oct 2023 14:18:52 -0700 Subject: [PATCH 16/56] Update lib/spack/spack/test/concretize.py Make assertions for test more readable Co-authored-by: Massimiliano Culpo --- lib/spack/spack/test/concretize.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/spack/spack/test/concretize.py b/lib/spack/spack/test/concretize.py index dc03cb9f73371c..d5bde51f3f3d1b 100644 --- a/lib/spack/spack/test/concretize.py +++ b/lib/spack/spack/test/concretize.py @@ -533,10 +533,10 @@ def test_concretize_propagate_specified_variant(self): spec = Spec("splice-b++bar") spec.concretize() - assert spec.satisfies("^splice-a+bar") - assert spec.satisfies("^splice-z+bar") - assert not spec.satisfies("^splice-a+foo") - assert not spec.satisfies("^splice-z+foo") + assert spec.satisfies("+bar") and spec.satisfies("^splice-a+bar") + assert spec.satisfies("+bar") and spec.satisfies("^splice-z+bar") + assert spec.satisfies("+foo") and not spec.satisfies("^splice-a+foo") + assert spec.satisfies("+foo") and not spec.satisfies("^splice-z+foo") def test_no_matching_compiler_specs(self, mock_low_high_config): # only relevant when not building compilers as needed From ea8dad70abe24ca05f708d3c8ff8e8fbb4dfedba Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Mon, 9 Oct 2023 12:42:29 -0700 Subject: [PATCH 17/56] Revert AbstractVariant change --- lib/spack/spack/spec.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/spack/spack/spec.py b/lib/spack/spack/spec.py index 7c4a33b5ff940a..e88ce79a2e6610 100644 --- a/lib/spack/spack/spec.py +++ b/lib/spack/spack/spec.py @@ -5033,11 +5033,11 @@ def from_node_dict(cls, node): spec.compiler_flags.add_flag(name, val, False) else: if isinstance(values, PropagateValue): - spec.variants[name] = vt.AbstractVariant.from_node_dict( + spec.variants[name] = vt.MultiValuedVariant.from_node_dict( name, values.value, values.propagate ) else: - spec.variants[name] = vt.AbstractVariant.from_node_dict(name, values) + spec.variants[name] = vt.MultiValuedVariant.from_node_dict(name, values) spec.external_path = None spec.external_modules = None From 5a6b22d9919a6d4da742f625d59480c947392b76 Mon Sep 17 00:00:00 2001 From: Scott Wittenburg Date: Wed, 4 Oct 2023 01:55:06 -0600 Subject: [PATCH 18/56] ci: pull E4S images from github instead of dockerhub (#40307) --- share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml index 34951a8335490d..9ea591b2b7880c 100644 --- a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml +++ b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml @@ -337,8 +337,13 @@ e4s-build: variables: SPACK_CI_STACK_NAME: e4s-neoverse_v1 +<<<<<<< HEAD e4s-neoverse_v1-generate: extends: [ ".e4s-neoverse_v1", ".generate-neoverse_v1" ] +======= +e4s-arm-generate: + extends: [ ".e4s-arm", ".generate-aarch64" ] +>>>>>>> eed7ab5fee (ci: pull E4S images from github instead of dockerhub (#40307)) image: ghcr.io/spack/ubuntu20.04-runner-arm64-gcc-11.4:2023.08.01 e4s-neoverse_v1-build: From 981f9ec8ae1993977a461891c225d82b6a384b6d Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Wed, 4 Oct 2023 21:38:50 +0200 Subject: [PATCH 19/56] Improve build isolation in PythonPipBuilder (#40224) We run pip with `--no-build-isolation` because we don't wanna let pip install build deps. As a consequence, when pip runs hooks, it runs hooks of *any* package it can find in `sys.path`. For Spack-built Python this includes user site packages -- there shouldn't be any system site packages. So in this case it suffices to set the environment variable PYTHONNOUSERSITE=1. For external Python, more needs to be done, cause there is no env variable that disables both system and user site packages; setting the `python -S` flag doesn't work because pip runs subprocesses that don't inherit this flag (and there is no API to know if -S was passed) So, for external Python, an empty venv is created before invoking pip in Spack's build env ensures that pip can no longer see anything but standard libraries and `PYTHONPATH`. The downside of this is that pip will generate shebangs that point to the python executable from the venv. So, for external python an extra step is necessary where we fix up shebangs post install. --- lib/spack/spack/build_systems/python.py | 85 +++++++++++++++++++++++++ 1 file changed, 85 insertions(+) diff --git a/lib/spack/spack/build_systems/python.py b/lib/spack/spack/build_systems/python.py index 3990b95e905c65..ca55e38fa7daf7 100644 --- a/lib/spack/spack/build_systems/python.py +++ b/lib/spack/spack/build_systems/python.py @@ -375,6 +375,51 @@ def libs(self) -> LibraryList: raise NoLibrariesError(msg.format(self.spec.name, root)) +def fixup_shebangs(path: str, old_interpreter: bytes, new_interpreter: bytes): + # Recurse into the install prefix and fixup shebangs + exe = stat.S_IXUSR | stat.S_IXGRP | stat.S_IXOTH + dirs = [path] + hardlinks = set() + + while dirs: + with os.scandir(dirs.pop()) as entries: + for entry in entries: + if entry.is_dir(follow_symlinks=False): + dirs.append(entry.path) + continue + + # Only consider files, not symlinks + if not entry.is_file(follow_symlinks=False): + continue + + lstat = entry.stat(follow_symlinks=False) + + # Skip over files that are not executable + if not (lstat.st_mode & exe): + continue + + # Don't modify hardlinks more than once + if lstat.st_nlink > 1: + key = (lstat.st_ino, lstat.st_dev) + if key in hardlinks: + continue + hardlinks.add(key) + + # Finally replace shebangs if any. + with open(entry.path, "rb+") as f: + contents = f.read(2) + if contents != b"#!": + continue + contents += f.read() + + if old_interpreter not in contents: + continue + + f.seek(0) + f.write(contents.replace(old_interpreter, new_interpreter)) + f.truncate() + + @spack.builder.builder("python_pip") class PythonPipBuilder(BaseBuilder): phases = ("install",) @@ -474,6 +519,22 @@ def global_options(self, spec: Spec, prefix: Prefix) -> Iterable[str]: def install(self, pkg: PythonPackage, spec: Spec, prefix: Prefix) -> None: """Install everything from build directory.""" + python: Executable = spec["python"].command + # Since we invoke pip with --no-build-isolation, we have to make sure that pip cannot + # execute hooks from user and system site-packages. + if spec["python"].external: + # There are no environment variables to disable the system site-packages, so we use a + # virtual environment instead. The downside of this approach is that pip produces + # incorrect shebangs that refer to the virtual environment, which we have to fix up. + python("-m", "venv", "--without-pip", self._build_venv_path) + pip = self._build_venv_python + else: + # For a Spack managed Python, system site-packages is empty/unused by design, so it + # suffices to disable user site-packages, for which there is an environment variable. + pip = python + pip.add_default_env("PYTHONNOUSERSITE", "1") + pip.add_default_arg("-m") + pip.add_default_arg("pip") args = PythonPipBuilder.std_args(pkg) + [f"--prefix={prefix}"] @@ -500,4 +561,28 @@ def install(self, pkg: PythonPackage, spec: Spec, prefix: Prefix) -> None: with fs.working_dir(self.build_directory): pip(*args) + @spack.builder.run_after("install") + def fixup_shebangs_pointing_to_build(self): + """When installing a package using an external python, we use a temporary virtual + environment which improves build isolation. The downside is that pip produces shebangs + that point to the temporary virtual environment. This method fixes them up to point to the + underlying Python.""" + # No need to fixup shebangs if no build venv was used. (this post install function also + # runs when install was overridden in another package, so check existence of the venv path) + if not os.path.exists(self._build_venv_path): + return + + # Use sys.executable, since that's what pip uses. + interpreter = ( + lambda python: python("-c", "import sys; print(sys.executable)", output=str) + .strip() + .encode("utf-8") + ) + + fixup_shebangs( + path=self.spec.prefix, + old_interpreter=interpreter(self._build_venv_python), + new_interpreter=interpreter(self.spec["python"].command), + ) + spack.builder.run_after("install")(execute_install_time_tests) From ba88655b46ba62f1ef60c1c5109d9e0903ec74a2 Mon Sep 17 00:00:00 2001 From: Cameron Rutherford Date: Wed, 4 Oct 2023 21:57:17 -0700 Subject: [PATCH 20/56] exago: add and logging variant. (#40188) --- var/spack/repos/builtin/packages/exago/package.py | 1 + 1 file changed, 1 insertion(+) diff --git a/var/spack/repos/builtin/packages/exago/package.py b/var/spack/repos/builtin/packages/exago/package.py index b3fc23b31bfd56..89c561eeeaf9a8 100644 --- a/var/spack/repos/builtin/packages/exago/package.py +++ b/var/spack/repos/builtin/packages/exago/package.py @@ -69,6 +69,7 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): conflicts( "+python", when="+ipopt+rocm", msg="Python bindings require -fPIC with Ipopt for rocm." ) + variant("logging", default=False, description="Enable/Disable spdlog based logging") # Adds ExaGO's python wrapper to PYTHONPATH extends("python", when="+python") From fc2eb6a4eab3e1d71249a35b290d19ac01de3940 Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Thu, 5 Oct 2023 08:45:33 +0200 Subject: [PATCH 21/56] cray rhel: disable due to runner issues (#40324) --- .../gitlab/cloud_pipelines/.gitlab-ci.yml | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml index 9ea591b2b7880c..53c176803d04f0 100644 --- a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml +++ b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml @@ -902,24 +902,24 @@ deprecated-ci-build: ####################################### # E4S - Cray RHEL ####################################### -.e4s-cray-rhel: - extends: [ ".cray_rhel_zen4" ] - variables: - SPACK_CI_STACK_NAME: e4s-cray-rhel +# .e4s-cray-rhel: +# extends: [ ".cray_rhel_zen4" ] +# variables: +# SPACK_CI_STACK_NAME: e4s-cray-rhel -e4s-cray-rhel-generate: - extends: [ ".generate-cray-rhel", ".e4s-cray-rhel" ] +# e4s-cray-rhel-generate: +# extends: [ ".generate-cray-rhel", ".e4s-cray-rhel" ] -e4s-cray-rhel-build: - extends: [ ".build", ".e4s-cray-rhel" ] - trigger: - include: - - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml - job: e4s-cray-rhel-generate - strategy: depend - needs: - - artifacts: True - job: e4s-cray-rhel-generate +# e4s-cray-rhel-build: +# extends: [ ".build", ".e4s-cray-rhel" ] +# trigger: +# include: +# - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml +# job: e4s-cray-rhel-generate +# strategy: depend +# needs: +# - artifacts: True +# job: e4s-cray-rhel-generate ####################################### # E4S - Cray SLES From 906ef3674a25a63ee866653ab304bb333aebac87 Mon Sep 17 00:00:00 2001 From: Thomas Madlener Date: Thu, 5 Oct 2023 17:53:56 +0200 Subject: [PATCH 22/56] whizard: Make sure to detect LCIO if requested (#40316) --- var/spack/repos/builtin/packages/whizard/package.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/var/spack/repos/builtin/packages/whizard/package.py b/var/spack/repos/builtin/packages/whizard/package.py index a7ca1bf61d0fe3..f3317621c7fc9b 100644 --- a/var/spack/repos/builtin/packages/whizard/package.py +++ b/var/spack/repos/builtin/packages/whizard/package.py @@ -114,6 +114,8 @@ def setup_build_environment(self, env): # and seems incompatible with # filter_compiler_wrappers, thus the # actual compilers need to be used to build + if self.spec.satisfies("+lcio"): + env.set("LCIO", self.spec["lcio"].prefix) env.set("CC", self.compiler.cc) env.set("CXX", self.compiler.cxx) env.set("FC", self.compiler.fc) From 7830144d829b36b54be54e60f020d347ccc3d6a8 Mon Sep 17 00:00:00 2001 From: eugeneswalker <38933153+eugeneswalker@users.noreply.github.com> Date: Thu, 5 Oct 2023 10:32:52 -0700 Subject: [PATCH 23/56] Revert "cray rhel: disable due to runner issues (#40324)" (#40335) This reverts commit bf7f54449ba8ed157c9ee258007e0a7a509600cf. --- .../gitlab/cloud_pipelines/.gitlab-ci.yml | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml index 53c176803d04f0..9ea591b2b7880c 100644 --- a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml +++ b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml @@ -902,24 +902,24 @@ deprecated-ci-build: ####################################### # E4S - Cray RHEL ####################################### -# .e4s-cray-rhel: -# extends: [ ".cray_rhel_zen4" ] -# variables: -# SPACK_CI_STACK_NAME: e4s-cray-rhel +.e4s-cray-rhel: + extends: [ ".cray_rhel_zen4" ] + variables: + SPACK_CI_STACK_NAME: e4s-cray-rhel -# e4s-cray-rhel-generate: -# extends: [ ".generate-cray-rhel", ".e4s-cray-rhel" ] +e4s-cray-rhel-generate: + extends: [ ".generate-cray-rhel", ".e4s-cray-rhel" ] -# e4s-cray-rhel-build: -# extends: [ ".build", ".e4s-cray-rhel" ] -# trigger: -# include: -# - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml -# job: e4s-cray-rhel-generate -# strategy: depend -# needs: -# - artifacts: True -# job: e4s-cray-rhel-generate +e4s-cray-rhel-build: + extends: [ ".build", ".e4s-cray-rhel" ] + trigger: + include: + - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml + job: e4s-cray-rhel-generate + strategy: depend + needs: + - artifacts: True + job: e4s-cray-rhel-generate ####################################### # E4S - Cray SLES From ff53810613f2af3358a84eacb1fe1c089948c2d8 Mon Sep 17 00:00:00 2001 From: Massimiliano Culpo Date: Fri, 6 Oct 2023 10:24:21 +0200 Subject: [PATCH 24/56] Make "minimal" the default duplicate strategy (#39621) * Allow branching out of the "generic build" unification set For cases like the one in https://github.com/spack/spack/pull/39661 we need to relax rules on unification sets. The issue is that, right now, nodes in the "generic build" unification set are unified together with their build dependencies. This was done out of caution to avoid the risk of circular dependencies, which would ultimately cause a very slow solve. For build-tools like Cython, however, the build dependencies is masked by a long chain of "build, run" dependencies that belong in the "generic build" unification space. To allow splitting on cases like this, we relax the rule disallowing branching out of the "generic build" unification set. * Fix issue with pure build virtual dependencies Pure build virtual dependencies were not accounted properly in the list of possible virtuals. This caused some facts connecting virtuals to the corresponding providers to not be emitted, and in the end lead to unsat problems. * Fixed a few issues in packages py-gevent: restore dependency on py-cython@3 jsoncpp: fix typo in build dependency ecp-data-vis-sdk: update spack.yaml and cmake recipe py-statsmodels: add v0.13.5 * Make dependency on "blt" of type "build" --- share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml | 5 ----- var/spack/repos/builtin.mock/packages/bzip2/package.py | 7 ------- 2 files changed, 12 deletions(-) diff --git a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml index 9ea591b2b7880c..34951a8335490d 100644 --- a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml +++ b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml @@ -337,13 +337,8 @@ e4s-build: variables: SPACK_CI_STACK_NAME: e4s-neoverse_v1 -<<<<<<< HEAD e4s-neoverse_v1-generate: extends: [ ".e4s-neoverse_v1", ".generate-neoverse_v1" ] -======= -e4s-arm-generate: - extends: [ ".e4s-arm", ".generate-aarch64" ] ->>>>>>> eed7ab5fee (ci: pull E4S images from github instead of dockerhub (#40307)) image: ghcr.io/spack/ubuntu20.04-runner-arm64-gcc-11.4:2023.08.01 e4s-neoverse_v1-build: diff --git a/var/spack/repos/builtin.mock/packages/bzip2/package.py b/var/spack/repos/builtin.mock/packages/bzip2/package.py index 5a85dfe5e9913a..326533ac5ea117 100644 --- a/var/spack/repos/builtin.mock/packages/bzip2/package.py +++ b/var/spack/repos/builtin.mock/packages/bzip2/package.py @@ -8,18 +8,11 @@ class Bzip2(Package): -<<<<<<< HEAD """This packagae has the variants shared defaulted to True""" homepage = "https://example.com" url = "https://example.com/bzip2-1.0.8tar.gz" -======= - """This is a thing""" - - homepage = "https://someplace.com" - url = "https://anotherplace.com" ->>>>>>> f3d2d06bd6 (Create new mock packages) version("1.0.8", sha256="ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269") From 88196529be714502a44a63d4ffad1cfd048015cd Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Sun, 8 Oct 2023 19:47:36 +0200 Subject: [PATCH 25/56] py-setuptools: sdist + rpath patch backport (#40205) --- .../builtin/packages/py-setuptools/package.py | 250 ++++-------------- .../py-setuptools/rpath-compiler-flag.patch | 13 + 2 files changed, 66 insertions(+), 197 deletions(-) create mode 100644 var/spack/repos/builtin/packages/py-setuptools/rpath-compiler-flag.patch diff --git a/var/spack/repos/builtin/packages/py-setuptools/package.py b/var/spack/repos/builtin/packages/py-setuptools/package.py index 36cc6de4ee38b7..a0e220419c6c42 100644 --- a/var/spack/repos/builtin/packages/py-setuptools/package.py +++ b/var/spack/repos/builtin/packages/py-setuptools/package.py @@ -6,191 +6,60 @@ from spack.package import * -class PySetuptools(Package, PythonExtension): +class PySetuptools(PythonPackage): """A Python utility that aids in the process of downloading, building, upgrading, installing, and uninstalling Python packages.""" homepage = "https://github.com/pypa/setuptools" - url = "https://files.pythonhosted.org/packages/py3/s/setuptools/setuptools-62.3.2-py3-none-any.whl" - list_url = "https://pypi.org/simple/setuptools/" + pypi = "setuptools/setuptools-62.3.2.tar.gz" tags = ["build-tools"] - version( - "68.0.0", - sha256="11e52c67415a381d10d6b462ced9cfb97066179f0e871399e006c4ab101fc85f", - expand=False, - ) - version( - "67.6.0", - sha256="b78aaa36f6b90a074c1fa651168723acbf45d14cb1196b6f02c0fd07f17623b2", - expand=False, - ) - version( - "65.5.0", - sha256="f62ea9da9ed6289bfe868cd6845968a2c854d1427f8548d52cae02a42b4f0356", - expand=False, - ) - version( - "65.0.0", - sha256="fe9a97f68b064a6ddd4bacfb0b4b93a4c65a556d97ce906255540439d0c35cef", - expand=False, - ) - version( - "64.0.0", - sha256="63f463b90ff5e0a1422010100268fd688e15c44ae0798659013c8412963e15e4", - expand=False, - ) - version( - "63.4.3", - sha256="7f61f7e82647f77d4118eeaf43d64cbcd4d87e38af9611694d4866eb070cd10d", - expand=False, - ) - version( - "63.0.0", - sha256="045aec56a3eee5c82373a70e02db8b6da9a10f7faf61ff89a14ab66c738ed370", - expand=False, - ) - version( - "62.6.0", - sha256="c1848f654aea2e3526d17fc3ce6aeaa5e7e24e66e645b5be2171f3f6b4e5a178", - expand=False, - ) - version( - "62.4.0", - sha256="5a844ad6e190dccc67d6d7411d119c5152ce01f7c76be4d8a1eaa314501bba77", - expand=False, - ) - version( - "62.3.2", - sha256="68e45d17c9281ba25dc0104eadd2647172b3472d9e01f911efa57965e8d51a36", - expand=False, - ) - version( - "59.4.0", - sha256="feb5ff19b354cde9efd2344ef6d5e79880ce4be643037641b49508bbb850d060", - expand=False, - ) - version( - "58.2.0", - sha256="2551203ae6955b9876741a26ab3e767bb3242dafe86a32a749ea0d78b6792f11", - expand=False, - ) - version( - "57.4.0", - sha256="a49230977aa6cfb9d933614d2f7b79036e9945c4cdd7583163f4e920b83418d6", - expand=False, - ) - version( - "57.1.0", - sha256="ddae4c1b9220daf1e32ba9d4e3714df6019c5b583755559be84ff8199f7e1fe3", - expand=False, - ) - version( - "51.0.0", - sha256="8c177936215945c9a37ef809ada0fab365191952f7a123618432bbfac353c529", - expand=False, - ) - version( - "50.3.2", - sha256="2c242a0856fbad7efbe560df4a7add9324f340cf48df43651e9604924466794a", - expand=False, - ) - version( - "50.1.0", - sha256="4537c77e6e7dc170081f8547564551d4ff4e4999717434e1257600bbd3a23296", - expand=False, - ) - version( - "49.6.0", - sha256="4dd5bb0a0a0cff77b46ca5dd3a84857ee48c83e8223886b556613c724994073f", - expand=False, - ) - version( - "49.2.0", - sha256="272c7f48f5cddc5af5901f4265274c421c7eede5c8bc454ac2903d3f8fc365e9", - expand=False, - ) - version( - "46.1.3", - sha256="4fe404eec2738c20ab5841fa2d791902d2a645f32318a7850ef26f8d7215a8ee", - expand=False, - ) - version( - "44.1.1", - sha256="27a714c09253134e60a6fa68130f78c7037e5562c4f21f8f318f2ae900d152d5", - expand=False, - ) - version( - "44.1.0", - sha256="992728077ca19db6598072414fb83e0a284aca1253aaf2e24bb1e55ee6db1a30", - expand=False, - ) - version( - "43.0.0", - sha256="a67faa51519ef28cd8261aff0e221b6e4c370f8fb8bada8aa3e7ad8945199963", - expand=False, - ) - version( - "41.4.0", - sha256="8d01f7ee4191d9fdcd9cc5796f75199deccb25b154eba82d44d6a042cf873670", - expand=False, - ) - version( - "41.3.0", - sha256="e9832acd9be6f3174f4c34b40e7d913a146727920cbef6465c1c1bd2d21a4ec4", - expand=False, - ) - version( - "41.0.1", - sha256="c7769ce668c7a333d84e17fe8b524b1c45e7ee9f7908ad0a73e1eda7e6a5aebf", - expand=False, - ) - version( - "41.0.0", - sha256="e67486071cd5cdeba783bd0b64f5f30784ff855b35071c8670551fd7fc52d4a1", - expand=False, - ) - version( - "40.8.0", - sha256="e8496c0079f3ac30052ffe69b679bd876c5265686127a3159cfa415669b7f9ab", - expand=False, - ) - version( - "40.4.3", - sha256="ce4137d58b444bac11a31d4e0c1805c69d89e8ed4e91fde1999674ecc2f6f9ff", - expand=False, - ) - version( - "40.2.0", - sha256="ea3796a48a207b46ea36a9d26de4d0cc87c953a683a7b314ea65d666930ea8e6", - expand=False, - ) - version( - "39.2.0", - sha256="8fca9275c89964f13da985c3656cb00ba029d7f3916b37990927ffdf264e7926", - expand=False, - ) - version( - "39.0.1", - sha256="8010754433e3211b9cdbbf784b50f30e80bf40fc6b05eb5f865fab83300599b8", - expand=False, - ) - version( - "25.2.0", - sha256="2845247c359bb91097ccf8f6be8a69edfa44847f3d2d5def39aa43c3d7f615ca", - expand=False, - ) - version( - "20.7.0", - sha256="8917a52aa3a389893221b173a89dae0471022d32bff3ebc31a1072988aa8039d", - expand=False, - ) - version( - "20.6.7", - sha256="9982ee4d279a2541dc1a7efee994ff9c535cfc05315e121e09df7f93da48c442", - expand=False, - ) + version("68.0.0", sha256="baf1fdb41c6da4cd2eae722e135500da913332ab3f2f5c7d33af9b492acb5235") + version("67.6.0", sha256="2ee892cd5f29f3373097f5a814697e397cf3ce313616df0af11231e2ad118077") + version("65.5.0", sha256="512e5536220e38146176efb833d4a62aa726b7bbff82cfbc8ba9eaa3996e0b17") + version("65.0.0", sha256="d73f8cd714a1a6691f5eb5abeeacbf313242b7aa2f5eba93776542c1aad90c6f") + version("64.0.0", sha256="9b5d2cb8df48f005825654e0cb17217418317e4d996c035f0bca7cbaeb8acf51") + version("63.4.3", sha256="521c833d1e5e1ef0869940e7f486a83de7773b9f029010ad0c2fe35453a9dad9") + version("63.0.0", sha256="7388e17e72f5c0c7279f59da950a7925910e35bc1a84e19d3affbb40da248d1d") + version("62.6.0", sha256="990a4f7861b31532871ab72331e755b5f14efbe52d336ea7f6118144dd478741") + version("62.4.0", sha256="bf8a748ac98b09d32c9a64a995a6b25921c96cc5743c1efa82763ba80ff54e91") + version("62.3.2", sha256="a43bdedf853c670e5fed28e5623403bad2f73cf02f9a2774e91def6bda8265a7") + version("59.4.0", sha256="b4c634615a0cf5b02cf83c7bedffc8da0ca439f00e79452699454da6fbd4153d") + version("58.2.0", sha256="2c55bdb85d5bb460bd2e3b12052b677879cffcf46c0c688f2e5bf51d36001145") + version("57.4.0", sha256="6bac238ffdf24e8806c61440e755192470352850f3419a52f26ffe0a1a64f465") + version("57.1.0", sha256="cfca9c97e7eebbc8abe18d5e5e962a08dcad55bb63afddd82d681de4d22a597b") + version("51.0.0", sha256="029c49fd713e9230f6a41c0298e6e1f5839f2cde7104c0ad5e053a37777e7688") + version("50.3.2", sha256="ed0519d27a243843b05d82a5e9d01b0b083d9934eaa3d02779a23da18077bd3c") + version("50.1.0", sha256="4a7708dafd2d360ce5e2ac7577374da9fb65fc867bc4cdaf461f9f834dfa6ac3") + version("49.6.0", sha256="46bd862894ed22c2edff033c758c2dc026324788d758e96788e8f7c11f4e9707") + version("49.2.0", sha256="afe9e81fee0270d3f60d52608549cc8ec4c46dada8c95640c1a00160f577acf2") + version("46.1.3", sha256="795e0475ba6cd7fa082b1ee6e90d552209995627a2a227a47c6ea93282f4bfb1") + version("44.1.1", sha256="c67aa55db532a0dadc4d2e20ba9961cbd3ccc84d544e9029699822542b5a476b") + version("44.1.0", sha256="794a96b0c1dc6f182c36b72ab70d7e90f1d59f7a132e6919bb37b4fd4d424aca") + version("43.0.0", sha256="db45ebb4a4b3b95ff0aca3ce5fe1e820ce17be393caf8902c78aa36240e8c378") + version("41.4.0", sha256="7eae782ccf36b790c21bde7d86a4f303a441cd77036b25c559a602cf5186ce4d") + version("41.3.0", sha256="9f5c54b529b2156c6f288e837e625581bb31ff94d4cfd116b8f271c589749556") + version("41.0.1", sha256="a222d126f5471598053c9a77f4b5d4f26eaa1f150ad6e01dcf1a42e185d05613") + version("41.0.0", sha256="79d30254b6fe7a8e672e43cd85f13a9f3f2a50080bc81d851143e2219ef0dcb1") + version("40.8.0", sha256="6e4eec90337e849ade7103723b9a99631c1f0d19990d6e8412dc42f5ae8b304d") + version("40.4.3", sha256="acbc5740dd63f243f46c2b4b8e2c7fd92259c2ddb55a4115b16418a2ed371b15") + version("40.2.0", sha256="47881d54ede4da9c15273bac65f9340f8929d4f0213193fa7894be384f2dcfa6") + version("39.2.0", sha256="f7cddbb5f5c640311eb00eab6e849f7701fa70bf6a183fc8a2c33dd1d1672fb2") + version("39.0.1", sha256="bec7badf0f60e7fc8153fac47836edc41b74e5d541d7692e614e635720d6a7c7") + version("25.2.0", sha256="b2757ddac2c41173140b111e246d200768f6dd314110e1e40661d0ecf9b4d6a6") + version("20.7.0", sha256="505cdf282c5f6e3a056e79f0244b8945f3632257bba8469386c6b9b396400233") + version("20.6.7", sha256="d20152ee6337323d3b6d95cd733fb719d6b4f3fbc40f61f7a48e5a1bb96478b2") + + def url_for_version(self, version): + url = self.url.rsplit("/", 1)[0] + if version.satisfies(ver("32.1.2:51.0.0")): + url += "/setuptools-{}.zip" + else: + url += "/setuptools-{}.tar.gz" + return url.format(version) + + patch("rpath-compiler-flag.patch", when="@48:58.2") extends("python") @@ -209,24 +78,11 @@ class PySetuptools(Package, PythonExtension): # https://github.com/pypa/setuptools/issues/3661 depends_on("python@:3.11", when="@:67", type=("build", "run")) - depends_on("py-pip", type="build") + # Uses HTMLParser.unescape + depends_on("python@:3.8", when="@:41.0", type=("build", "run")) - def url_for_version(self, version): - url = "https://files.pythonhosted.org/packages/{0}/s/setuptools/setuptools-{1}-{0}-none-any.whl" + # Uses collections.MutableMapping + depends_on("python@:3.9", when="@:40.4.2", type=("build", "run")) - if version >= Version("45.1.0"): - python_tag = "py3" - else: - python_tag = "py2.py3" - return url.format(python_tag, version) - - def install(self, spec, prefix): - # When setuptools changes its entry point we might get weird - # incompatibilities if building from sources in a non-isolated environment. - # - # https://github.com/pypa/setuptools/issues/980#issuecomment-1154471423 - # - # We work around this issue by installing setuptools from wheels - whl = self.stage.archive_file - args = ["-m", "pip"] + std_pip_args + ["--prefix=" + prefix, whl] - python(*args) + # https://github.com/pypa/setuptools/issues/3661 + depends_on("python@:3.11", when="@:67", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-setuptools/rpath-compiler-flag.patch b/var/spack/repos/builtin/packages/py-setuptools/rpath-compiler-flag.patch new file mode 100644 index 00000000000000..6b37d623234a53 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-setuptools/rpath-compiler-flag.patch @@ -0,0 +1,13 @@ +diff --git a/setuptools/_distutils/unixccompiler.py b/setuptools/_distutils/unixccompiler.py +--- a/setuptools/_distutils/unixccompiler.py ++++ b/setuptools/_distutils/unixccompiler.py +@@ -257,7 +257,7 @@ class UnixCCompiler(CCompiler): + # No idea how --enable-new-dtags would be passed on to + # ld if this system was using GNU ld. Don't know if a + # system like this even exists. +- return "-R" + dir ++ return "-Wl,-rpath," + dir + + def library_option(self, lib): + return "-l" + lib + From fb90a20d08da8d3fe71656145580b7be7dfff284 Mon Sep 17 00:00:00 2001 From: "Adam J. Stewart" Date: Tue, 10 Oct 2023 13:50:22 -0500 Subject: [PATCH 26/56] py-jupyter-packaging: remove duplicate packages (#38671) * py-jupyter-packaging: remove duplicate packages * Allow py-jupyter-packaging to be duplicated in DAG * Deprecate version of py-jupyterlab that requires py-jupyter-packaging at run-time --- .../py-jupyter-packaging11/package.py | 44 +++++++++++++++++++ .../packages/py-jupyter-packaging7/package.py | 27 ++++++++++++ 2 files changed, 71 insertions(+) create mode 100644 var/spack/repos/builtin/packages/py-jupyter-packaging11/package.py create mode 100644 var/spack/repos/builtin/packages/py-jupyter-packaging7/package.py diff --git a/var/spack/repos/builtin/packages/py-jupyter-packaging11/package.py b/var/spack/repos/builtin/packages/py-jupyter-packaging11/package.py new file mode 100644 index 00000000000000..b15cfe8752e480 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-jupyter-packaging11/package.py @@ -0,0 +1,44 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyJupyterPackaging11(PythonPackage): + """Jupyter Packaging Utilities, version 11.""" + + # TODO: This package only exists because different packages in the Jupyter ecosystem + # require different versions of jupyter_packaging. Once the concretizer is capable + # of concretizing build dependencies separately, this package should be removed. + + homepage = "https://github.com/jupyter/jupyter-packaging" + pypi = "jupyter_packaging/jupyter_packaging-0.11.1.tar.gz" + + version( + "0.12.3", + sha256="9d9b2b63b97ffd67a8bc5391c32a421bc415b264a32c99e4d8d8dd31daae9cf4", + deprecated=True, + ) + version( + "0.12.0", + sha256="b27455d60adc93a7baa2e0b8f386be81b932bb4e3c0116046df9ed230cd3faac", + deprecated=True, + ) + version( + "0.11.1", + sha256="6f5c7eeea98f7f3c8fb41d565a94bf59791768a93f93148b3c2dfb7ebade8eec", + deprecated=True, + ) + + depends_on("python@3.7:", type=("build", "run")) + depends_on("py-packaging", type=("build", "run")) + depends_on("py-tomlkit", type=("build", "run")) + depends_on("py-hatchling@0.25:", when="@0.12.3:", type="build") + depends_on("py-setuptools@60.2:", when="@0.12:", type=("build", "run")) + depends_on("py-setuptools@46.4:", type=("build", "run")) + # https://github.com/jupyter/jupyter-packaging/issues/130 + depends_on("py-setuptools@:60", when="@:0.11", type=("build", "run")) + depends_on("py-wheel", type=("build", "run")) + depends_on("py-deprecation", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-jupyter-packaging7/package.py b/var/spack/repos/builtin/packages/py-jupyter-packaging7/package.py new file mode 100644 index 00000000000000..8f0da9b9999cb4 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-jupyter-packaging7/package.py @@ -0,0 +1,27 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyJupyterPackaging7(PythonPackage): + """Jupyter Packaging Utilities, version 7.""" + + # TODO: This package only exists because different packages in the Jupyter ecosystem + # require different versions of jupyter_packaging. Once the concretizer is capable + # of concretizing build dependencies separately, this package should be removed. + + homepage = "https://github.com/jupyter/jupyter-packaging" + pypi = "jupyter_packaging/jupyter-packaging-0.7.12.tar.gz" + + version( + "0.7.12", + sha256="b140325771881a7df7b7f2d14997b619063fe75ae756b9025852e4346000bbb8", + deprecated=True, + ) + + depends_on("python@3.6:", type=("build", "run")) + depends_on("py-packaging", type=("build", "run")) + depends_on("py-setuptools", type=("build", "run")) From 69062c223fbd82dfcf62a98cad2c4c5c7ba63c87 Mon Sep 17 00:00:00 2001 From: Massimiliano Culpo Date: Wed, 11 Oct 2023 13:09:21 +0200 Subject: [PATCH 27/56] spack buildcache: fix a typo in a function call (#40446) fixes #40415 --- lib/spack/spack/cmd/buildcache.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/lib/spack/spack/cmd/buildcache.py b/lib/spack/spack/cmd/buildcache.py index 75011a3e9bc85f..e2eb8e0922a6cb 100644 --- a/lib/spack/spack/cmd/buildcache.py +++ b/lib/spack/spack/cmd/buildcache.py @@ -315,6 +315,7 @@ def _matching_specs(specs: List[Spec]) -> List[Spec]: return [spack.cmd.disambiguate_spec(s, ev.active_environment(), installed=any) for s in specs] +<<<<<<< HEAD def _format_spec(spec: Spec) -> str: return spec.cformat("{name}{@version}{/hash:7}") @@ -331,6 +332,9 @@ def _make_pool(): def push_fn(args): +======= +def push_fn(args: argparse.Namespace): +>>>>>>> ed3a2ac586 (spack buildcache: fix a typo in a function call (#40446)) """create a binary package and push it to a mirror""" if args.spec_file: tty.warn( @@ -919,8 +923,15 @@ def check_fn(args: argparse.Namespace): else: specs_arg = args.specs +<<<<<<< HEAD if specs_arg: specs = _matching_specs(spack.cmd.parse_specs(specs_arg)) +======= + specs = spack.cmd.parse_specs(args.spec or args.spec_file) + + if specs: + specs = _matching_specs(specs) +>>>>>>> ed3a2ac586 (spack buildcache: fix a typo in a function call (#40446)) else: specs = spack.cmd.require_active_env("buildcache check").all_specs() From 8d20b1818da6ee10c0ca32363dad62c7fb24d976 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 11 Oct 2023 12:35:41 +0000 Subject: [PATCH 28/56] build(deps): bump mypy from 1.5.1 to 1.6.0 in /lib/spack/docs (#40424) Bumps [mypy](https://github.com/python/mypy) from 1.5.1 to 1.6.0. - [Commits](https://github.com/python/mypy/compare/v1.5.1...v1.6.0) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- lib/spack/spack/cmd/buildcache.py | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/lib/spack/spack/cmd/buildcache.py b/lib/spack/spack/cmd/buildcache.py index e2eb8e0922a6cb..75011a3e9bc85f 100644 --- a/lib/spack/spack/cmd/buildcache.py +++ b/lib/spack/spack/cmd/buildcache.py @@ -315,7 +315,6 @@ def _matching_specs(specs: List[Spec]) -> List[Spec]: return [spack.cmd.disambiguate_spec(s, ev.active_environment(), installed=any) for s in specs] -<<<<<<< HEAD def _format_spec(spec: Spec) -> str: return spec.cformat("{name}{@version}{/hash:7}") @@ -332,9 +331,6 @@ def _make_pool(): def push_fn(args): -======= -def push_fn(args: argparse.Namespace): ->>>>>>> ed3a2ac586 (spack buildcache: fix a typo in a function call (#40446)) """create a binary package and push it to a mirror""" if args.spec_file: tty.warn( @@ -923,15 +919,8 @@ def check_fn(args: argparse.Namespace): else: specs_arg = args.specs -<<<<<<< HEAD if specs_arg: specs = _matching_specs(spack.cmd.parse_specs(specs_arg)) -======= - specs = spack.cmd.parse_specs(args.spec or args.spec_file) - - if specs: - specs = _matching_specs(specs) ->>>>>>> ed3a2ac586 (spack buildcache: fix a typo in a function call (#40446)) else: specs = spack.cmd.require_active_env("buildcache check").all_specs() From e2d8a49cf1e59a7e157c5d66412a19047d939616 Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Thu, 12 Oct 2023 12:11:22 +0200 Subject: [PATCH 29/56] clingo: fix build with Python 3.12 (#40154) --- var/spack/repos/builtin/packages/clingo/package.py | 6 ++++++ .../repos/builtin/packages/clingo/setuptools.patch | 14 ++++++++++++++ 2 files changed, 20 insertions(+) create mode 100644 var/spack/repos/builtin/packages/clingo/setuptools.patch diff --git a/var/spack/repos/builtin/packages/clingo/package.py b/var/spack/repos/builtin/packages/clingo/package.py index 64bc9b700bfdaf..9d0ec78740230e 100644 --- a/var/spack/repos/builtin/packages/clingo/package.py +++ b/var/spack/repos/builtin/packages/clingo/package.py @@ -78,6 +78,12 @@ class Clingo(CMakePackage): patch("setuptools-2.patch") depends_on("py-setuptools", type="build") + # TODO: Simplify this after Spack 0.21 release. The old concretizer has problems with + # py-setuptools ^python@3.6, so we only apply the distutils -> setuptools patch for Python 3.12 + with when("@:5.6.1 ^python@3.12:"): + patch("setuptools.patch") + depends_on("py-setuptools", type="build") + def patch(self): # Doxygen is optional but can't be disabled with a -D, so patch # it out if it's really supposed to be disabled diff --git a/var/spack/repos/builtin/packages/clingo/setuptools.patch b/var/spack/repos/builtin/packages/clingo/setuptools.patch new file mode 100644 index 00000000000000..4a38a7e6d9ad9e --- /dev/null +++ b/var/spack/repos/builtin/packages/clingo/setuptools.patch @@ -0,0 +1,14 @@ +diff --git a/cmake/python-site.py b/cmake/python-site.py +index 1e7fc8ce..95ef827f 100644 +--- a/cmake/python-site.py ++++ b/cmake/python-site.py +@@ -1,4 +1,7 @@ +-from distutils.sysconfig import get_python_lib, get_config_vars ++try: ++ from setuptools.sysconfig import get_python_lib, get_config_vars ++except ImportError: ++ from distutils.sysconfig import get_python_lib, get_config_vars + import sys + if sys.argv[1] == "prefix": + print(get_python_lib(True, False, sys.argv[2] if len(sys.argv) > 2 else None)) + From a21a68573bb2ab4a76a5b73a8add12052de8b69e Mon Sep 17 00:00:00 2001 From: Rocco Meli Date: Tue, 17 Oct 2023 20:33:13 +0200 Subject: [PATCH 30/56] Add mpi_f08 variant to CP2K (#40574) * add mpi_f08 variant * add conflict * add conflict with released versions of cp2k and +mpi_f08 --- var/spack/repos/builtin/packages/cp2k/package.py | 1 + 1 file changed, 1 insertion(+) diff --git a/var/spack/repos/builtin/packages/cp2k/package.py b/var/spack/repos/builtin/packages/cp2k/package.py index fd698488c79ab8..174e645028ef55 100644 --- a/var/spack/repos/builtin/packages/cp2k/package.py +++ b/var/spack/repos/builtin/packages/cp2k/package.py @@ -305,6 +305,7 @@ class Cp2k(MakefilePackage, CudaPackage, CMakePackage, ROCmPackage): depends_on("dbcsr+openmp", when="+openmp") depends_on("dbcsr+cuda", when="+cuda") depends_on("dbcsr+rocm", when="+rocm") + conflicts("+mpi_f08", when="@:2023.2") with when("@2022: +rocm"): depends_on("hipblas") From 96ae94167f6d1b01a64a1e7e73ec169fecb177d1 Mon Sep 17 00:00:00 2001 From: Peter Scheibel Date: Tue, 17 Oct 2023 11:33:59 -0700 Subject: [PATCH 31/56] Allow / in GitVersion (#39398) This commit allows version specifiers to refer to git branches that contain forward slashes. For example, the following is valid syntax now: pkg@git.releases/1.0 It also adds a new method `Spec.format_path(fmt)` which is like `Spec.format`, but also maps unsafe characters to `_` after interpolation. The difference is as follows: >>> Spec("pkg@git.releases/1.0").format("{name}/{version}") 'pkg/git.releases/1.0' >>> Spec("pkg@git.releases/1.0").format_path("{name}/{version}") 'pkg/git.releases_1.0' The `format_path` method is used in all projections. Notice that this method also maps `=` to `_` >>> Spec("pkg@git.main=1.0").format_path("{name}/{version}") 'pkg/git.main_1.0' which should avoid syntax issues when `Spec.prefix` is literally copied into a Makefile as sometimes happens in AutotoolsPackage or MakefilePackage --- lib/spack/spack/test/spec_semantics.py | 78 ++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) diff --git a/lib/spack/spack/test/spec_semantics.py b/lib/spack/spack/test/spec_semantics.py index 97855ed5bba04f..a4a15271e12790 100644 --- a/lib/spack/spack/test/spec_semantics.py +++ b/lib/spack/spack/test/spec_semantics.py @@ -1183,6 +1183,84 @@ def test_spec_format_path_posix(spec_str, format_str, expected): _check_spec_format_path(spec_str, format_str, expected, path_ctor=pathlib.PurePosixPath) +@pytest.mark.parametrize( + "spec_str,format_str,expected", + [ + ("zlib@git.foo/bar", "{name}-{version}", str(pathlib.Path("zlib-git.foo_bar"))), + ("zlib@git.foo/bar", "{name}-{version}-{/hash}", None), + ("zlib@git.foo/bar", "{name}/{version}", str(pathlib.Path("zlib", "git.foo_bar"))), + ( + "zlib@{0}=1.0%gcc".format("a" * 40), + "{name}/{version}/{compiler}", + str(pathlib.Path("zlib", "{0}_1.0".format("a" * 40), "gcc")), + ), + ( + "zlib@git.foo/bar=1.0%gcc", + "{name}/{version}/{compiler}", + str(pathlib.Path("zlib", "git.foo_bar_1.0", "gcc")), + ), + ], +) +def test_spec_format_path(spec_str, format_str, expected): + _check_spec_format_path(spec_str, format_str, expected) + + +def _check_spec_format_path(spec_str, format_str, expected, path_ctor=None): + spec = Spec(spec_str) + if not expected: + with pytest.raises((spack.spec.SpecFormatPathError, spack.spec.SpecFormatStringError)): + spec.format_path(format_str, _path_ctor=path_ctor) + else: + formatted = spec.format_path(format_str, _path_ctor=path_ctor) + assert formatted == expected + + +@pytest.mark.parametrize( + "spec_str,format_str,expected", + [ + ( + "zlib@git.foo/bar", + r"C:\\installroot\{name}\{version}", + r"C:\installroot\zlib\git.foo_bar", + ), + ( + "zlib@git.foo/bar", + r"\\hostname\sharename\{name}\{version}", + r"\\hostname\sharename\zlib\git.foo_bar", + ), + # Windows doesn't attribute any significance to a leading + # "/" so it is discarded + ("zlib@git.foo/bar", r"/installroot/{name}/{version}", r"installroot\zlib\git.foo_bar"), + ], +) +def test_spec_format_path_windows(spec_str, format_str, expected): + _check_spec_format_path(spec_str, format_str, expected, path_ctor=pathlib.PureWindowsPath) + + +@pytest.mark.parametrize( + "spec_str,format_str,expected", + [ + ("zlib@git.foo/bar", r"/installroot/{name}/{version}", "/installroot/zlib/git.foo_bar"), + ("zlib@git.foo/bar", r"//installroot/{name}/{version}", "//installroot/zlib/git.foo_bar"), + # This is likely unintentional on Linux: Firstly, "\" is not a + # path separator for POSIX, so this is treated as a single path + # component (containing literal "\" characters); secondly, + # Spec.format treats "\" as an escape character, so is + # discarded (unless directly following another "\") + ( + "zlib@git.foo/bar", + r"C:\\installroot\package-{name}-{version}", + r"C__installrootpackage-zlib-git.foo_bar", + ), + # "\" is not a POSIX separator, and Spec.format treats "\{" as a literal + # "{", which means that the resulting format string is invalid + ("zlib@git.foo/bar", r"package\{name}\{version}", None), + ], +) +def test_spec_format_path_posix(spec_str, format_str, expected): + _check_spec_format_path(spec_str, format_str, expected, path_ctor=pathlib.PurePosixPath) + + @pytest.mark.regression("3887") @pytest.mark.parametrize("spec_str", ["py-extension2", "extension1", "perl-extension"]) def test_is_extension_after_round_trip_to_dict(config, mock_packages, spec_str): From 409015ff12e4081a3488d5a85e373073bf7b5d6a Mon Sep 17 00:00:00 2001 From: Massimiliano Culpo Date: Thu, 19 Oct 2023 16:00:45 +0200 Subject: [PATCH 32/56] ASP-based solver: single Spec instance per dag hash (#39590) Reused specs used to be referenced directly into the built spec. This might cause issues like in issue 39570 where two objects in memory represent the same node, because two reused specs were loaded from different sources but referred to the same spec by DAG hash. The issue is solved by copying concrete specs to a dictionary keyed by dag hash. --- lib/spack/spack/solver/asp.py | 64 +++++++++++++++++++++++++++++++++++ 1 file changed, 64 insertions(+) diff --git a/lib/spack/spack/solver/asp.py b/lib/spack/spack/solver/asp.py index 466348fbd1588d..a6342eb9d9928c 100644 --- a/lib/spack/spack/solver/asp.py +++ b/lib/spack/spack/solver/asp.py @@ -1130,6 +1130,70 @@ def __iter__(self): return iter(self.data) +class ConcreteSpecsByHash(collections.abc.Mapping): + """Mapping containing concrete specs keyed by DAG hash. + + The mapping is ensured to be consistent, i.e. if a spec in the mapping has a dependency with + hash X, it is ensured to be the same object in memory as the spec keyed by X. + """ + + def __init__(self) -> None: + self.data: Dict[str, spack.spec.Spec] = {} + + def __getitem__(self, dag_hash: str) -> spack.spec.Spec: + return self.data[dag_hash] + + def add(self, spec: spack.spec.Spec) -> bool: + """Adds a new concrete spec to the mapping. Returns True if the spec was just added, + False if the spec was already in the mapping. + + Args: + spec: spec to be added + + Raises: + ValueError: if the spec is not concrete + """ + if not spec.concrete: + msg = ( + f"trying to store the non-concrete spec '{spec}' in a container " + f"that only accepts concrete" + ) + raise ValueError(msg) + + dag_hash = spec.dag_hash() + if dag_hash in self.data: + return False + + # Here we need to iterate on the input and rewire the copy. + self.data[spec.dag_hash()] = spec.copy(deps=False) + nodes_to_reconstruct = [spec] + + while nodes_to_reconstruct: + input_parent = nodes_to_reconstruct.pop() + container_parent = self.data[input_parent.dag_hash()] + + for edge in input_parent.edges_to_dependencies(): + input_child = edge.spec + container_child = self.data.get(input_child.dag_hash()) + # Copy children that don't exist yet + if container_child is None: + container_child = input_child.copy(deps=False) + self.data[input_child.dag_hash()] = container_child + nodes_to_reconstruct.append(input_child) + + # Rewire edges + container_parent.add_dependency_edge( + dependency_spec=container_child, depflag=edge.depflag, virtuals=edge.virtuals + ) + return True + + def __len__(self) -> int: + return len(self.data) + + def __iter__(self): + return iter(self.data) + + class SpackSolverSetup: """Class to set up and run a Spack concretization solve.""" From 02635798316c7202622784aa586656cda43566e1 Mon Sep 17 00:00:00 2001 From: Scott Wittenburg Date: Thu, 19 Oct 2023 10:04:59 -0600 Subject: [PATCH 33/56] gitlab ci: Rework how mirrors are configured (#39939) Improve how mirrors are used in gitlab ci, where we have until now thought of them as only a string. By configuring ci mirrors ahead of time using the proposed mirror templates, and by taking advantage of the expressiveness that spack now has for mirrors, this PR will allow us to easily switch the protocol/url we use for fetching binary dependencies. This change also deprecates some gitlab functionality and marks it for removal in Spack 0.23: - arguments to "spack ci generate": * --buildcache-destination * --copy-to - gitlab configuration options: * enable-artifacts-buildcache * temporary-storage-url-prefix --- share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml index 34951a8335490d..eb265ba88516ba 100644 --- a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml +++ b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml @@ -142,6 +142,9 @@ default: - cd share/spack/gitlab/cloud_pipelines/stacks/${SPACK_CI_STACK_NAME} - spack env activate --without-view . - export SPACK_CI_CONFIG_ROOT="${SPACK_ROOT}/share/spack/gitlab/cloud_pipelines/configs" + - spack python -c "import os,sys; print(os.path.expandvars(sys.stdin.read()))" + < "${SPACK_CI_CONFIG_ROOT}/${PIPELINE_MIRROR_TEMPLATE}" > "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" + - spack config add -f "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" - spack --config-scope "${SPACK_CI_CONFIG_ROOT}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}" From e1b5ef8b1ed95ee241b040ad6be874a0e35ed5b1 Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Thu, 19 Oct 2023 20:44:05 +0200 Subject: [PATCH 34/56] Improve setup build / run / test environment (#35737) This adds a `SetupContext` class which is responsible for setting package.py module globals, and computing the changes to environment variables for the build, test or run context. The class uses `effective_deptypes` which takes a list of specs (e.g. single item of a spec to build, or a list of environment roots) and a context (build, run, test), and outputs a flat list of specs that affect the environment together with a flag in what way they do so. This list is topologically ordered from root to leaf, so that one can be assured that dependents override variables set by dependencies, not the other way around. This is used to replace the logic in `modifications_from_dependencies`, which has several issues: missing calls to `setup_run_environment`, and the order in which operations are applied. Further, it should improve performance a bit in certain cases, since `effective_deptypes` run in O(v + e) time, whereas `spack env activate` currently can take up to O(v^2 + e) time due to loops over roots. Each edge in the DAG is visited once by calling `effective_deptypes` with `env.concrete_roots()`. By marking and propagating flags through the DAG, this commit also fixes a bug where Spack wouldn't call `setup_run_environment` for runtime dependencies of link dependencies. And this PR ensures that Spack correctly sets up the runtime environment of direct build dependencies. Regarding test dependencies: in a build context they are are build-time test deps, whereas in a test context they are install-time test deps. Since there are no means to distinguish the build/install type test deps, they're both. Further changes: - all `package.py` module globals are guaranteed to be set before any of the `setup_(dependent)_(run|build)_env` functions is called - traversal order during setup: first the group of externals, then the group of non-externals, with specs in each group traversed topological (dependencies are setup before dependents) - modules: only ever call `setup_dependent_run_environment` of *direct* link/run type deps - the marker in `set_module_variables_for_package` is dropped, since we should call the method once per spec. This allows us to set only a cheap subset of globals on the module: for example it's not necessary to compute the expensive `cmake_args` and w/e if the spec under consideration is not the root node to be built. - `spack load`'s `--only` is deprecated (it has no effect now), and `spack load x` now means: do everything that's required for `x` to work at runtime, which requires runtime deps to be setup -- just like `spack env activate`. - `spack load` no longer loads build deps (of build deps) ... - `spack env activate` on partially installed or broken environments: this is all or nothing now. If some spec errors during setup of its runtime env, you'll only get the unconditional variables + a warning that says the runtime changes for specs couldn't be applied. - Remove traversal in upward direction from `setup_dependent_*` in packages. Upward traversal may iterate to specs that aren't children of the roots (e.g. zlib / python have hundreds of dependents, only a small fraction is reachable from the roots. Packages should only modify the direct dependent they receive as an argument) --- lib/spack/spack/user_environment.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/spack/spack/user_environment.py b/lib/spack/spack/user_environment.py index 895e7b120378f0..8b431f74f71890 100644 --- a/lib/spack/spack/user_environment.py +++ b/lib/spack/spack/user_environment.py @@ -5,6 +5,10 @@ import os import re import sys +from contextlib import contextmanager +from typing import Callable + +from llnl.util.lang import nullcontext import spack.build_environment import spack.config From 157b1e7e1d30aebdb93ad4c65ba09c5ea8af1a93 Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Fri, 20 Oct 2023 16:20:20 +0200 Subject: [PATCH 35/56] gromacs +cp2k: build in CI (#40494) * gromacs +cp2k: build in CI * libxsmm: x86 only * attempt to fix dbcsr + new mpich * use c11 standard * gromacs: does not depend on dbcsr * cp2k: build with cmake in CI, s.t. dbcsr is a separate package * cp2k: cmake patches for config files and C/C++ std * cp2k: remove unnecessary constraints due to patch --- var/spack/repos/builtin/packages/cp2k/package.py | 1 - 1 file changed, 1 deletion(-) diff --git a/var/spack/repos/builtin/packages/cp2k/package.py b/var/spack/repos/builtin/packages/cp2k/package.py index 174e645028ef55..fd698488c79ab8 100644 --- a/var/spack/repos/builtin/packages/cp2k/package.py +++ b/var/spack/repos/builtin/packages/cp2k/package.py @@ -305,7 +305,6 @@ class Cp2k(MakefilePackage, CudaPackage, CMakePackage, ROCmPackage): depends_on("dbcsr+openmp", when="+openmp") depends_on("dbcsr+cuda", when="+cuda") depends_on("dbcsr+rocm", when="+rocm") - conflicts("+mpi_f08", when="@:2023.2") with when("@2022: +rocm"): depends_on("hipblas") From 8bb32b5bc7e53abc2bfb95dfba2cb2bbdfe4c7db Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Fri, 20 Oct 2023 17:09:19 +0200 Subject: [PATCH 36/56] concretize separately: show concretization time per spec as they concretize when verbose (#40634) --- share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml index eb265ba88516ba..5fdb72988b33bc 100644 --- a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml +++ b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml @@ -145,7 +145,7 @@ default: - spack python -c "import os,sys; print(os.path.expandvars(sys.stdin.read()))" < "${SPACK_CI_CONFIG_ROOT}/${PIPELINE_MIRROR_TEMPLATE}" > "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" - spack config add -f "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" - - spack + - spack -v --config-scope "${SPACK_CI_CONFIG_ROOT}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}/${SPACK_TARGET_ARCH}" From 04204a1da3c2d1316a091d5c5586fb254e569218 Mon Sep 17 00:00:00 2001 From: Bill Williams Date: Sun, 22 Oct 2023 22:11:19 +0200 Subject: [PATCH 37/56] Add Score-P 8.3 and dependencies (#40478) Includes Score-P 8.3 and Cubew/cubelib 4.8.2. --- var/spack/repos/builtin/packages/cubelib/package.py | 3 +++ var/spack/repos/builtin/packages/cubew/package.py | 3 +++ 2 files changed, 6 insertions(+) diff --git a/var/spack/repos/builtin/packages/cubelib/package.py b/var/spack/repos/builtin/packages/cubelib/package.py index aa142328607a6e..58a267dce5bdb4 100644 --- a/var/spack/repos/builtin/packages/cubelib/package.py +++ b/var/spack/repos/builtin/packages/cubelib/package.py @@ -14,7 +14,10 @@ class Cubelib(AutotoolsPackage): maintainers = ("swat-jsc", "wrwilliams") version("4.8.2", sha256="d6fdef57b1bc9594f1450ba46cf08f431dd0d4ae595c47e2f3454e17e4ae74f4") +<<<<<<< HEAD version("4.8.1", sha256="e4d974248963edab48c5d0fc5831146d391b0ae4632cccafe840bf5f12cd80a9") +======= +>>>>>>> 15b38ceff3 (Add Score-P 8.3 and dependencies (#40478)) version("4.8", sha256="171c93ac5afd6bc74c50a9a58efdaf8589ff5cc1e5bd773ebdfb2347b77e2f68") version("4.7.1", sha256="62cf33a51acd9a723fff9a4a5411cd74203e24e0c4ffc5b9e82e011778ed4f2f") version("4.7", sha256="e44352c80a25a49b0fa0748792ccc9f1be31300a96c32de982b92477a8740938") diff --git a/var/spack/repos/builtin/packages/cubew/package.py b/var/spack/repos/builtin/packages/cubew/package.py index 22a56ddda7b22e..efd64a800a261e 100644 --- a/var/spack/repos/builtin/packages/cubew/package.py +++ b/var/spack/repos/builtin/packages/cubew/package.py @@ -14,7 +14,10 @@ class Cubew(AutotoolsPackage): maintainers = ("swat-jsc", "wrwilliams") version("4.8.2", sha256="4f3bcf0622c2429b8972b5eb3f14d79ec89b8161e3c1cc5862ceda417d7975d2") +<<<<<<< HEAD version("4.8.1", sha256="42cbd743d87c16e805c8e28e79292ab33de259f2cfba46f2682cb35c1bc032d6") +======= +>>>>>>> 15b38ceff3 (Add Score-P 8.3 and dependencies (#40478)) version("4.8", sha256="73c7f9e9681ee45d71943b66c01cfe675b426e4816e751ed2e0b670563ca4cf3") version("4.7.1", sha256="0d364a4930ca876aa887ec40d12399d61a225dbab69e57379b293516d7b6db8d") version("4.7", sha256="a7c7fca13e6cb252f08d4380223d7c56a8e86a67de147bcc0279ebb849c884a5") From cbc8df4e3863513c7641e54811030470c7c4a87a Mon Sep 17 00:00:00 2001 From: Michael Kuhn Date: Mon, 23 Oct 2023 09:00:22 +0200 Subject: [PATCH 38/56] libtheora: fix GitLab patch (#40657) GitLab's .patch URLs do not provide stable/full hashes, while .diff URLs do. See #40656 for more information. --- var/spack/repos/builtin/packages/cubelib/package.py | 3 --- var/spack/repos/builtin/packages/cubew/package.py | 3 --- 2 files changed, 6 deletions(-) diff --git a/var/spack/repos/builtin/packages/cubelib/package.py b/var/spack/repos/builtin/packages/cubelib/package.py index 58a267dce5bdb4..aa142328607a6e 100644 --- a/var/spack/repos/builtin/packages/cubelib/package.py +++ b/var/spack/repos/builtin/packages/cubelib/package.py @@ -14,10 +14,7 @@ class Cubelib(AutotoolsPackage): maintainers = ("swat-jsc", "wrwilliams") version("4.8.2", sha256="d6fdef57b1bc9594f1450ba46cf08f431dd0d4ae595c47e2f3454e17e4ae74f4") -<<<<<<< HEAD version("4.8.1", sha256="e4d974248963edab48c5d0fc5831146d391b0ae4632cccafe840bf5f12cd80a9") -======= ->>>>>>> 15b38ceff3 (Add Score-P 8.3 and dependencies (#40478)) version("4.8", sha256="171c93ac5afd6bc74c50a9a58efdaf8589ff5cc1e5bd773ebdfb2347b77e2f68") version("4.7.1", sha256="62cf33a51acd9a723fff9a4a5411cd74203e24e0c4ffc5b9e82e011778ed4f2f") version("4.7", sha256="e44352c80a25a49b0fa0748792ccc9f1be31300a96c32de982b92477a8740938") diff --git a/var/spack/repos/builtin/packages/cubew/package.py b/var/spack/repos/builtin/packages/cubew/package.py index efd64a800a261e..22a56ddda7b22e 100644 --- a/var/spack/repos/builtin/packages/cubew/package.py +++ b/var/spack/repos/builtin/packages/cubew/package.py @@ -14,10 +14,7 @@ class Cubew(AutotoolsPackage): maintainers = ("swat-jsc", "wrwilliams") version("4.8.2", sha256="4f3bcf0622c2429b8972b5eb3f14d79ec89b8161e3c1cc5862ceda417d7975d2") -<<<<<<< HEAD version("4.8.1", sha256="42cbd743d87c16e805c8e28e79292ab33de259f2cfba46f2682cb35c1bc032d6") -======= ->>>>>>> 15b38ceff3 (Add Score-P 8.3 and dependencies (#40478)) version("4.8", sha256="73c7f9e9681ee45d71943b66c01cfe675b426e4816e751ed2e0b670563ca4cf3") version("4.7.1", sha256="0d364a4930ca876aa887ec40d12399d61a225dbab69e57379b293516d7b6db8d") version("4.7", sha256="a7c7fca13e6cb252f08d4380223d7c56a8e86a67de147bcc0279ebb849c884a5") From a30314884140c2224b418669c604778c43f725d7 Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Wed, 25 Oct 2023 20:55:04 +0200 Subject: [PATCH 39/56] ci: don't put compilers in config (#40700) * ci: don't register detectable compilers Cause they go out of sync... * remove intel compiler, it can be detected too * Do not run spack compiler find since compilers are registered in concretize job already * trilinos: work around +stokhos +cuda +superlu-dist bug due to EMPTY macro --- share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml index 5fdb72988b33bc..b8f37627961890 100644 --- a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml +++ b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml @@ -141,6 +141,7 @@ default: - spack --version - cd share/spack/gitlab/cloud_pipelines/stacks/${SPACK_CI_STACK_NAME} - spack env activate --without-view . + - spack compiler find - export SPACK_CI_CONFIG_ROOT="${SPACK_ROOT}/share/spack/gitlab/cloud_pipelines/configs" - spack python -c "import os,sys; print(os.path.expandvars(sys.stdin.read()))" < "${SPACK_CI_CONFIG_ROOT}/${PIPELINE_MIRROR_TEMPLATE}" > "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" From 034ca1b9c9f5899970a097c63512263322d74e59 Mon Sep 17 00:00:00 2001 From: "Adam J. Stewart" Date: Wed, 25 Oct 2023 16:10:48 -0500 Subject: [PATCH 40/56] PyTorch: patch breakpad dependency (#40648) --- var/spack/repos/builtin/packages/py-torch/package.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/var/spack/repos/builtin/packages/py-torch/package.py b/var/spack/repos/builtin/packages/py-torch/package.py index 8f1077eb3a38c3..d1037148fc4846 100644 --- a/var/spack/repos/builtin/packages/py-torch/package.py +++ b/var/spack/repos/builtin/packages/py-torch/package.py @@ -287,6 +287,14 @@ class PyTorch(PythonPackage, CudaPackage, ROCmPackage): working_dir="third_party/breakpad", ) + # https://github.com/pytorch/pytorch/issues/70297 + patch( + "https://github.com/google/breakpad/commit/605c51ed96ad44b34c457bbca320e74e194c317e.patch?full_index=1", + sha256="694d83db3a2147d543357f22ba5c8d5683d0ed43e693d42bca8f24ec50080f98", + when="+breakpad", + working_dir="third_party/breakpad", + ) + # Fixes CMake configuration error when XNNPACK is disabled # https://github.com/pytorch/pytorch/pull/35607 # https://github.com/pytorch/pytorch/pull/37865 From f70e10e13579b6af53e5a13998d8ea3804766df1 Mon Sep 17 00:00:00 2001 From: Ben Boeckel Date: Wed, 25 Oct 2023 23:26:49 +0000 Subject: [PATCH 41/56] Paraview 5.12 prep (#40527) * paraview: rebase the adios2 patch for 5.12-to-be * paraview: disable fastfloat and token for 5.12-to-be * paraview: require older protobuf for 5.12 as well * paraview: require C++11-supporting protobuf for `master` too --- .../vtk-adios2-module-no-kit-5.12.patch | 230 ++++++++++++++++++ 1 file changed, 230 insertions(+) create mode 100644 var/spack/repos/builtin/packages/paraview/vtk-adios2-module-no-kit-5.12.patch diff --git a/var/spack/repos/builtin/packages/paraview/vtk-adios2-module-no-kit-5.12.patch b/var/spack/repos/builtin/packages/paraview/vtk-adios2-module-no-kit-5.12.patch new file mode 100644 index 00000000000000..34a98eac474716 --- /dev/null +++ b/var/spack/repos/builtin/packages/paraview/vtk-adios2-module-no-kit-5.12.patch @@ -0,0 +1,230 @@ +diff --git a/VTK/IO/ADIOS2/CMakeLists.txt b/VTK/IO/ADIOS2/CMakeLists.txt +index 86c6d49cc4f..07b1d4fe0ef 100644 +--- a/VTK/IO/ADIOS2/CMakeLists.txt ++++ b/VTK/IO/ADIOS2/CMakeLists.txt +@@ -1,9 +1,9 @@ + vtk_module_find_package(PRIVATE_IF_SHARED + PACKAGE ADIOS2 + VERSION 2.4) +-if (VTK_USE_MPI AND NOT ADIOS2_HAVE_MPI) ++if (TARGET VTK::ParallelMPI AND NOT ADIOS2_HAVE_MPI) + message(FATAL_ERROR "VTK built with MPI requires ADIOS2 built with MPI") +-elseif(NOT VTK_USE_MPI AND ADIOS2_HAVE_MPI) ++elseif(NOT TARGET VTK::ParallelMPI AND ADIOS2_HAVE_MPI) + message(FATAL_ERROR "VTK built without MPI requires ADIOS2 built without MPI") + endif() + +@@ -18,38 +18,30 @@ set(classes_core vtkADIOS2CoreImageReader) + set(private_classes_core Core/vtkADIOS2CoreArraySelection) + set(private_headers_core Core/vtkADIOS2CoreTypeTraits.h) + set(private_templates_core) +-set(vtk_io_adios2_core_enabled TRUE CACHE INTERNAL "" FORCE) + +-if (vtk_io_adios2_core_enabled) +- list(APPEND classes ${classes_core}) +- list(APPEND private_classes ${private_classes_core}) +- list(APPEND private_headers ${private_headers_core}) +- list(APPEND private_templates ${private_templates_core}) +-endif() ++list(APPEND classes ${classes_core}) ++list(APPEND private_classes ${private_classes_core}) ++list(APPEND private_headers ${private_headers_core}) ++list(APPEND private_templates ${private_templates_core}) ++ ++# Build VTX Schema for Parallel ++if (TARGET VTK::ParallelMPI) ++ set(classes_vtx vtkADIOS2VTXReader) ++ set(private_classes_vtx ++ VTX/VTXSchemaManager ++ VTX/common/VTXDataArray ++ VTX/common/VTXHelper ++ VTX/schema/VTXSchema ++ VTX/schema/vtk/VTXvtkBase ++ VTX/schema/vtk/VTXvtkVTI ++ VTX/schema/vtk/VTXvtkVTU) ++ set(private_headers_vtx VTX/common/VTXTypes.h) ++ set(private_templates_vtx ++ VTX/common/VTXHelper.txx ++ VTX/schema/VTXSchema.txx ++ VTX/schema/vtk/VTXvtkVTI.txx ++ VTX/schema/vtk/VTXvtkVTU.txx) + +-set(classes_vtx vtkADIOS2VTXReader) +-set(private_classes_vtx +- VTX/VTXSchemaManager +- VTX/common/VTXDataArray +- VTX/common/VTXHelper +- VTX/schema/VTXSchema +- VTX/schema/vtk/VTXvtkBase +- VTX/schema/vtk/VTXvtkVTI +- VTX/schema/vtk/VTXvtkVTU) +-set(private_headers_vtx VTX/common/VTXTypes.h) +-set(private_templates_vtx +- VTX/common/VTXHelper.txx +- VTX/schema/VTXSchema.txx +- VTX/schema/vtk/VTXvtkVTI.txx +- VTX/schema/vtk/VTXvtkVTU.txx) +- +-if (VTK_USE_MPI) +- set(vtk_io_adios2_vtx_enabled TRUE CACHE INTERNAL "" FORCE) +-else () +- set(vtk_io_adios2_vtx_enabled FALSE CACHE INTERNAL "" FORCE) +-endif() +- +-if (vtk_io_adios2_vtx_enabled) + list(APPEND classes ${classes_vtx}) + list(APPEND private_classes ${private_classes_vtx}) + list(APPEND private_headers ${private_headers_vtx}) +@@ -63,10 +55,6 @@ vtk_module_add_module(VTK::IOADIOS2 + PRIVATE_TEMPLATES ${private_templates}) + vtk_module_link(VTK::IOADIOS2 PRIVATE adios2::adios2) + +-if (ADIOS2_HAVE_MPI) +- vtk_module_definitions(VTK::IOADIOS2 PRIVATE IOADIOS2_HAVE_MPI) +-endif () +- + if (ADIOS2_VERSION VERSION_GREATER_EQUAL "2.8.0") + vtk_module_definitions(VTK::IOADIOS2 PRIVATE IOADIOS2_BP5_RANDOM_ACCESS) + endif () +diff --git a/VTK/IO/ADIOS2/Testing/Cxx/CMakeLists.txt b/VTK/IO/ADIOS2/Testing/Cxx/CMakeLists.txt +index 1534a1e7271..29c51970daf 100644 +--- a/VTK/IO/ADIOS2/Testing/Cxx/CMakeLists.txt ++++ b/VTK/IO/ADIOS2/Testing/Cxx/CMakeLists.txt +@@ -2,40 +2,34 @@ find_package(ADIOS2 2.4 REQUIRED + COMPONENTS CXX + OPTIONAL_COMPONENTS MPI) + +-if (ADIOS2_HAVE_MPI) +- if (vtk_io_adios2_core_enabled) +- set(TestADIOS2BPReaderSingleTimeStep_NUMPROCS 2) ++if (TARGET VTK::ParallelMPI) ++ set(TestADIOS2BPReaderSingleTimeStep_NUMPROCS 2) + # For now vtkMultiBlockVolumeMapper does not support rendering in parallel +- set(TestADIOS2BPReaderMultiTimeSteps_NUMPROCS 2) +- set(TestADIOS2BPReaderMultiTimeSteps2D_NUMPROCS 2) +- vtk_add_test_mpi(vtkIOADIOS2CxxTests-MPI mpiTests TESTING_DATA +- TestADIOS2BPReaderMPISingleTimeStep.cxx +- TestADIOS2BPReaderMPIMultiTimeSteps3D.cxx,NO_VALID +- TestADIOS2BPReaderMPIMultiTimeSteps2D.cxx) +- vtk_test_cxx_executable(vtkIOADIOS2CxxTests-MPI mpiTests) +- endif() ++ set(TestADIOS2BPReaderMultiTimeSteps_NUMPROCS 2) ++ set(TestADIOS2BPReaderMultiTimeSteps2D_NUMPROCS 2) ++ vtk_add_test_mpi(vtkIOADIOS2CxxTests-MPI mpiTests TESTING_DATA ++ TestADIOS2BPReaderMPISingleTimeStep.cxx ++ TestADIOS2BPReaderMPIMultiTimeSteps3D.cxx,NO_VALID ++ TestADIOS2BPReaderMPIMultiTimeSteps2D.cxx) ++ vtk_test_cxx_executable(vtkIOADIOS2CxxTests-MPI mpiTests) + + # VTX tests +- if (vtk_io_adios2_vtx_enabled) +- vtk_add_test_cxx(vtkIOADIOS2VTXCxxTests tests TESTING_DATA NO_OUTPUT +- UnitTestIOADIOS2VTX.cxx,NO_VALID +- #TestIOADIOS2VTX_VTI3D.cxx, +- TestIOADIOS2VTX_VTI3DRendering.cxx,NO_VALID +- #TestIOADIOS2VTX_VTU3D.cxx,NO_VALID +- TestIOADIOS2VTX_VTU3DRendering.cxx,NO_VALID +- TestIOADIOS2VTX_VTU2DRendering.cxx,NO_VALID +- TestIOADIOS2VTX_VTU1DRendering.cxx,NO_VALID) ++ vtk_add_test_cxx(vtkIOADIOS2VTXCxxTests tests TESTING_DATA NO_OUTPUT ++ UnitTestIOADIOS2VTX.cxx,NO_VALID ++ #TestIOADIOS2VTX_VTI3D.cxx, ++ TestIOADIOS2VTX_VTI3DRendering.cxx,NO_VALID ++ #TestIOADIOS2VTX_VTU3D.cxx,NO_VALID ++ TestIOADIOS2VTX_VTU3DRendering.cxx,NO_VALID ++ TestIOADIOS2VTX_VTU2DRendering.cxx,NO_VALID ++ TestIOADIOS2VTX_VTU1DRendering.cxx,NO_VALID) + +- vtk_test_cxx_executable(vtkIOADIOS2VTXCxxTests tests) +- target_link_libraries(vtkIOADIOS2VTXCxxTests PUBLIC adios2::adios2) +- endif () ++ vtk_test_cxx_executable(vtkIOADIOS2VTXCxxTests tests) ++ target_link_libraries(vtkIOADIOS2VTXCxxTests PUBLIC adios2::adios2) + else () +- if (vtk_io_adios2_core_enabled) +- vtk_add_test_cxx(vtkIOADIOS2CxxTests tests TESTING_DATA +- TestADIOS2BPReaderSingleTimeStep.cxx +- TestADIOS2BPReaderMultiTimeSteps3D.cxx +- TestADIOS2BPReaderMultiTimeSteps2D.cxx) ++ vtk_add_test_cxx(vtkIOADIOS2CxxTests tests TESTING_DATA ++ TestADIOS2BPReaderSingleTimeStep.cxx ++ TestADIOS2BPReaderMultiTimeSteps3D.cxx ++ TestADIOS2BPReaderMultiTimeSteps2D.cxx) + +- vtk_test_cxx_executable(vtkIOADIOS2CxxTests tests) +- endif () ++ vtk_test_cxx_executable(vtkIOADIOS2CxxTests tests) + endif () +diff --git a/VTK/IO/ADIOS2/vtk.module b/VTK/IO/ADIOS2/vtk.module +index 5069bd828b0..fe37260eb6d 100644 +--- a/VTK/IO/ADIOS2/vtk.module ++++ b/VTK/IO/ADIOS2/vtk.module +@@ -2,8 +2,6 @@ NAME + VTK::IOADIOS2 + LIBRARY_NAME + vtkIOADIOS2 +-KIT +- VTK::IO + SPDX_LICENSE_IDENTIFIER + LicenseRef-BSD-3-Clause-Sandia-USGov + SPDX_COPYRIGHT_TEXT +diff --git a/VTK/IO/ADIOS2/vtkADIOS2CoreImageReader.cxx b/VTK/IO/ADIOS2/vtkADIOS2CoreImageReader.cxx +index 6ba4d25230d..c209fd905d5 100644 +--- a/VTK/IO/ADIOS2/vtkADIOS2CoreImageReader.cxx ++++ b/VTK/IO/ADIOS2/vtkADIOS2CoreImageReader.cxx +@@ -28,7 +28,7 @@ + #include "vtkLongLongArray.h" + #include "vtkMultiBlockDataSet.h" + #include "vtkMultiPieceDataSet.h" +-#include "vtkMultiProcessController.h" ++#include "vtkMultiProcessController.h" // For the MPI controller member + #include "vtkNew.h" + #include "vtkObjectFactory.h" + #include "vtkPointData.h" +@@ -46,7 +46,7 @@ + #include "vtkUnstructuredGrid.h" + #include "vtksys/SystemTools.hxx" + +-#ifdef IOADIOS2_HAVE_MPI ++#if VTK_MODULE_ENABLE_VTK_ParallelMPI + #include "vtkMPI.h" + #include "vtkMPIController.h" + #endif +@@ -126,7 +126,7 @@ vtkNew vtkADIOS2CoreImageReader::vtkADIOS2CoreImageReaderI + int myLen = static_cast(ibds->GetNumberOfBlocks()); + int* allLens{ nullptr }; + int procId{ 0 }, numProcess{ 0 }; +-#ifdef IOADIOS2_HAVE_MPI ++#if VTK_MODULE_ENABLE_VTK_ParallelMPI + auto ctrl = vtkMultiProcessController::GetGlobalController(); + if (ctrl) + { +@@ -286,7 +286,7 @@ const vtkADIOS2CoreImageReader::StringToParams& vtkADIOS2CoreImageReader::GetAva + //------------------------------------------------------------------------------ + void vtkADIOS2CoreImageReader::SetController(vtkMultiProcessController* controller) + { +-#ifdef IOADIOS2_HAVE_MPI ++#if VTK_MODULE_ENABLE_VTK_ParallelMPI + vtkMPIController* mpiController = vtkMPIController::SafeDownCast(controller); + if (controller && !mpiController) + { +@@ -337,7 +337,7 @@ bool vtkADIOS2CoreImageReader::OpenAndReadMetaData() + // Initialize the ADIOS2 data structures + if (!this->Impl->Adios) + { +-#ifdef IOADIOS2_HAVE_MPI ++#if VTK_MODULE_ENABLE_VTK_ParallelMPI + // Make sure the ADIOS subsystem is initialized before processing any + // sort of request. + if (!this->Controller) +@@ -910,7 +910,7 @@ void vtkADIOS2CoreImageReader::CalculateWorkDistribution(const std::string& varN + auto var = this->Impl->AdiosIO.InquireVariable(varName); + size_t blockNum = this->Impl->BpReader.BlocksInfo(var, this->Impl->RequestStep).size(); + +-#ifdef IOADIOS2_HAVE_MPI ++#if VTK_MODULE_ENABLE_VTK_ParallelMPI + size_t rank = static_cast(this->Controller->GetLocalProcessId()); + size_t procs = static_cast(this->Controller->GetNumberOfProcesses()); + #else +-- +GitLab From aca88ee48be1a664f0c4f00c49a0c59e2b47cf35 Mon Sep 17 00:00:00 2001 From: Xavier Delaruelle Date: Thu, 26 Oct 2023 13:49:13 +0200 Subject: [PATCH 42/56] modules: hide implicit modulefiles (#36619) Renames exclude_implicits to hide_implicits When hide_implicits option is enabled, generate modulefile of implicitly installed software and hide them. Even if implicit, those modulefiles may be referred as dependency in other modulefiles thus they should be generated to make module properly load dependent module. A new hidden property is added to BaseConfiguration class. To hide modulefiles, modulercs are generated along modulefiles. Such rc files contain specific module command to indicate a module should be hidden (for instance when using "module avail"). A modulerc property is added to TclFileLayout and LmodFileLayout classes to get fully qualified path name of the modulerc associated to a given modulefile. Modulerc files will be located in each module directory, next to the version modulefiles. This scheme is supported by both module tool implementations. modulerc_header and hide_cmd_format attributes are added to TclModulefileWriter and LmodModulefileWriter. They help to know how to generate a modulerc file with hidden commands for each module tool. Tcl modulerc file requires an header. As we use a command introduced on Modules 4.7 (module-hide --hidden-loaded), a version requirement is added to header string. For lmod, modules that open up a hierarchy are never hidden, even if they are implicitly installed. Modulerc is created, updated or removed when associated modulefile is written or removed. If an implicit modulefile becomes explicit, hidden command in modulerc for this modulefile is removed. If modulerc becomes empty, this file is removed. Modulerc file is not rewritten when no content change is detected. Co-authored-by: Harmen Stoppels --- lib/spack/spack/modules/common.py | 17 +++++++++ lib/spack/spack/modules/lmod.py | 11 ++++++ lib/spack/spack/schema/modules.py | 49 ++++++++++++++++++++++++++ lib/spack/spack/test/modules/common.py | 21 +++++++++++ lib/spack/spack/test/modules/tcl.py | 8 ++--- 5 files changed, 102 insertions(+), 4 deletions(-) diff --git a/lib/spack/spack/modules/common.py b/lib/spack/spack/modules/common.py index bccc6805cb8c6e..ba2f459a70d469 100644 --- a/lib/spack/spack/modules/common.py +++ b/lib/spack/spack/modules/common.py @@ -518,6 +518,23 @@ def hidden(self): return hidden_as_implicit + @property + def hidden(self): + """Returns True if the module has been hidden, False otherwise.""" + + # A few variables for convenience of writing the method + spec = self.spec + conf = self.module.configuration(self.name) + + hidden_as_implicit = not self.explicit and conf.get( + "hide_implicits", conf.get("exclude_implicits", False) + ) + + if hidden_as_implicit: + tty.debug(f"\tHIDDEN_AS_IMPLICIT : {spec.cshort_spec}") + + return hidden_as_implicit + @property def context(self): return self.conf.get("context", {}) diff --git a/lib/spack/spack/modules/lmod.py b/lib/spack/spack/modules/lmod.py index 8f529ba21ceb5a..7eb105cc55c5c7 100644 --- a/lib/spack/spack/modules/lmod.py +++ b/lib/spack/spack/modules/lmod.py @@ -284,6 +284,13 @@ def modulerc(self): """Returns the modulerc file associated with current module file""" return os.path.join(os.path.dirname(self.filename), f".modulerc.{self.extension}") + @property + def modulerc(self): + """Returns the modulerc file associated with current module file""" + return os.path.join( + os.path.dirname(self.filename), ".".join([".modulerc", self.extension]) + ) + def token_to_path(self, name, value): """Transforms a hierarchy token into the corresponding path part. @@ -481,6 +488,10 @@ class LmodModulefileWriter(BaseModuleFileWriter): hide_cmd_format = 'hide_version("%s")' + modulerc_header: list = [] + + hide_cmd_format = 'hide_version("%s")' + class CoreCompilersNotFoundError(spack.error.SpackError, KeyError): """Error raised if the key 'core_compilers' has not been specified diff --git a/lib/spack/spack/schema/modules.py b/lib/spack/spack/schema/modules.py index fb4130d345d02b..dba1cd199c51ff 100644 --- a/lib/spack/spack/schema/modules.py +++ b/lib/spack/spack/schema/modules.py @@ -174,3 +174,52 @@ "additionalProperties": False, "properties": properties, } + + +# deprecated keys and their replacements +old_to_new_key = {"exclude_implicits": "hide_implicits"} + + +def update_keys(data, key_translations): + """Change blacklist/whitelist to exclude/include. + + Arguments: + data (dict): data from a valid modules configuration. + key_translations (dict): A dictionary of keys to translate to + their respective values. + + Return: + (bool) whether anything was changed in data + """ + changed = False + + if isinstance(data, dict): + keys = list(data.keys()) + for key in keys: + value = data[key] + + translation = key_translations.get(key) + if translation: + data[translation] = data.pop(key) + changed = True + + changed |= update_keys(value, key_translations) + + elif isinstance(data, list): + for elt in data: + changed |= update_keys(elt, key_translations) + + return changed + + +def update(data): + """Update the data in place to remove deprecated properties. + + Args: + data (dict): dictionary to be updated + + Returns: + True if data was changed, False otherwise + """ + # translate blacklist/whitelist to exclude/include + return update_keys(data, old_to_new_key) diff --git a/lib/spack/spack/test/modules/common.py b/lib/spack/spack/test/modules/common.py index 906c1d5c2a134c..3476b1b642bca1 100644 --- a/lib/spack/spack/test/modules/common.py +++ b/lib/spack/spack/test/modules/common.py @@ -14,6 +14,7 @@ import spack.package_base import spack.schema.modules import spack.spec +import spack.util.spack_yaml as syaml from spack.modules.common import UpstreamModuleIndex from spack.spec import Spec @@ -194,6 +195,26 @@ def find_nothing(*args): spack.package_base.PackageBase.uninstall_by_spec(spec) +@pytest.mark.parametrize( + "module_type, old_config,new_config", + [("tcl", "exclude_implicits.yaml", "hide_implicits.yaml")], +) +def test_exclude_include_update(module_type, old_config, new_config): + module_test_data_root = os.path.join(spack.paths.test_path, "data", "modules", module_type) + with open(os.path.join(module_test_data_root, old_config)) as f: + old_yaml = syaml.load(f) + with open(os.path.join(module_test_data_root, new_config)) as f: + new_yaml = syaml.load(f) + + # ensure file that needs updating is translated to the right thing. + assert spack.schema.modules.update_keys(old_yaml, spack.schema.modules.old_to_new_key) + assert new_yaml == old_yaml + # ensure a file that doesn't need updates doesn't get updated + original_new_yaml = new_yaml.copy() + assert not spack.schema.modules.update_keys(new_yaml, spack.schema.modules.old_to_new_key) + assert original_new_yaml == new_yaml + + @pytest.mark.regression("37649") def test_check_module_set_name(mutable_config): """Tests that modules set name are validated correctly and an error is reported if the diff --git a/lib/spack/spack/test/modules/tcl.py b/lib/spack/spack/test/modules/tcl.py index e2f1235db0083b..d937e4ad75ee0a 100644 --- a/lib/spack/spack/test/modules/tcl.py +++ b/lib/spack/spack/test/modules/tcl.py @@ -436,14 +436,14 @@ def test_hide_implicits_no_arg(self, module_configuration, database): mpileaks_specs = database.query("mpileaks") for item in mpileaks_specs: writer = writer_cls(item, "default") - assert not writer.conf.excluded + assert not writer.conf.hidden # callpath is a dependency of mpileaks, and has been pulled # in implicitly callpath_specs = database.query("callpath") for item in callpath_specs: writer = writer_cls(item, "default") - assert writer.conf.excluded + assert writer.conf.hidden @pytest.mark.regression("12105") def test_hide_implicits_with_arg(self, module_configuration): @@ -453,13 +453,13 @@ def test_hide_implicits_with_arg(self, module_configuration): mpileaks_spec = spack.spec.Spec("mpileaks") mpileaks_spec.concretize() writer = writer_cls(mpileaks_spec, "default", True) - assert not writer.conf.excluded + assert not writer.conf.hidden # callpath is defined as implicit with explicit argument set on writer callpath_spec = spack.spec.Spec("callpath") callpath_spec.concretize() writer = writer_cls(callpath_spec, "default", False) - assert writer.conf.excluded + assert writer.conf.hidden @pytest.mark.regression("9624") @pytest.mark.db From a3d4bf17862d60a2899f701ebb43fedaed8bcf8e Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Thu, 26 Oct 2023 18:57:55 +0200 Subject: [PATCH 43/56] spack checksum pkg@1.2, use as version filter (#39694) * spack checksum pkg@1.2, use as version filter Currently pkg@1.2 splits on @ and looks for 1.2 specifically, with this PR pkg@1.2 is a filter so any matching 1.2, 1.2.1, ..., 1.2.10 version is displayed. * fix tests * fix style --- lib/spack/spack/cmd/checksum.py | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/spack/spack/cmd/checksum.py b/lib/spack/spack/cmd/checksum.py index f927d2d922a26d..ff36f0e7f9633e 100644 --- a/lib/spack/spack/cmd/checksum.py +++ b/lib/spack/spack/cmd/checksum.py @@ -78,6 +78,7 @@ def setup_parser(subparser): " `spack checksum zlib@1.2` autodetects versions 1.2.0 to 1.2.13 from the remote\n" " `spack checksum zlib 1.2.13` checksums exact version 1.2.13 directly without search\n" ) + arguments.add_common_arguments(subparser, ["jobs"]) def checksum(parser, args): From 4598980da395642c200af1d312a90a9b0391d889 Mon Sep 17 00:00:00 2001 From: Ryan Danehy Date: Thu, 26 Oct 2023 11:18:31 -0700 Subject: [PATCH 44/56] Update spack package for exago@1.6.0 release (#40614) * Update spack package for exago:1.6.0 * update style * Weird spack style env bug fixed * Update spack package for exago:1.6.0 * update style * Weird spack style env bug fixed * changes to allow release 1.6.0 * fix depends, and versioning * rm cmake variable * add s * style fix --------- Co-authored-by: Ryan Danehy Co-authored-by: Ryan Danehy Co-authored-by: ryan.danehy@pnnl.gov --- var/spack/repos/builtin/packages/exago/package.py | 1 - 1 file changed, 1 deletion(-) diff --git a/var/spack/repos/builtin/packages/exago/package.py b/var/spack/repos/builtin/packages/exago/package.py index 89c561eeeaf9a8..b3fc23b31bfd56 100644 --- a/var/spack/repos/builtin/packages/exago/package.py +++ b/var/spack/repos/builtin/packages/exago/package.py @@ -69,7 +69,6 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): conflicts( "+python", when="+ipopt+rocm", msg="Python bindings require -fPIC with Ipopt for rocm." ) - variant("logging", default=False, description="Enable/Disable spdlog based logging") # Adds ExaGO's python wrapper to PYTHONPATH extends("python", when="+python") From 8badda1352716e43bc9b5e4df749d1558865e59f Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Fri, 27 Oct 2023 09:43:01 +0200 Subject: [PATCH 45/56] ci: spack compiler find should list extra config scopes (#40727) otherwise it detected pre-configured compilers in an potentially different way. --- share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml index b8f37627961890..226aceced87c9b 100644 --- a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml +++ b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml @@ -141,8 +141,13 @@ default: - spack --version - cd share/spack/gitlab/cloud_pipelines/stacks/${SPACK_CI_STACK_NAME} - spack env activate --without-view . - - spack compiler find - export SPACK_CI_CONFIG_ROOT="${SPACK_ROOT}/share/spack/gitlab/cloud_pipelines/configs" + - spack + --config-scope "${SPACK_CI_CONFIG_ROOT}" + --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}" + --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}/${SPACK_TARGET_ARCH}" + ${CI_STACK_CONFIG_SCOPES} + compiler find - spack python -c "import os,sys; print(os.path.expandvars(sys.stdin.read()))" < "${SPACK_CI_CONFIG_ROOT}/${PIPELINE_MIRROR_TEMPLATE}" > "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" - spack config add -f "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" From 30b3ca9bfde613cffd7569e863ec64f62d6dc65f Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Fri, 27 Oct 2023 15:30:04 +0200 Subject: [PATCH 46/56] OCI buildcache (#38358) Credits to @ChristianKniep for advocating the idea of OCI image layers being identical to spack buildcache tarballs. With this you can configure an OCI registry as a buildcache: ```console $ spack mirror add my_registry oci://user/image # Dockerhub $ spack mirror add my_registry oci://ghcr.io/haampie/spack-test # GHCR $ spack mirror set --push --oci-username ... --oci-password ... my_registry # set login credentials ``` which should result in this config: ```yaml mirrors: my_registry: url: oci://ghcr.io/haampie/spack-test push: access_pair: [, ] ``` It can be used like any other registry ``` spack buildcache push my_registry [specs...] ``` It will upload the Spack tarballs in parallel, as well as manifest + config files s.t. the binaries are compatible with `docker pull` or `skopeo copy`. In fact, a base image can be added to get a _runnable_ image: ```console $ spack buildcache push --base-image ubuntu:23.04 my_registry python Pushed ... as [image]:python-3.11.2-65txfcpqbmpawclvtasuog4yzmxwaoia.spack $ docker run --rm -it [image]:python-3.11.2-65txfcpqbmpawclvtasuog4yzmxwaoia.spack ``` which should really be a game changer for sharing binaries. Further, all content-addressable blobs that are downloaded and verified will be cached in Spack's download cache. This should make repeated `push` commands faster, as well as `push` followed by a separate `update-index` command. An end to end example of how to use this in Github Actions is here: **https://github.com/haampie/spack-oci-buildcache-example** TODO: - [x] Generate environment modifications in config so PATH is set up - [x] Enrich config with Spack's `spec` json (this is allowed in the OCI specification) - [x] When ^ is done, add logic to create an index in say `:index` by fetching all config files (using OCI distribution discovery API) - [x] Add logic to use object storage in an OCI registry in `spack install`. - [x] Make the user pick the base image for generated OCI images. - [x] Update buildcache install logic to deal with absolute paths in tarballs - [x] Merge with `spack buildcache` command - [x] Merge #37441 (included here) - [x] Merge #39077 (included here) - [x] #39187 + #39285 - [x] #39341 - [x] Not a blocker: #35737 fixes correctness run env for the generated container images NOTE: 1. `oci://` is unfortunately taken, so it's being abused in this PR to mean "oci type mirror". `skopeo` uses `docker://` which I'd like to avoid, given that classical docker v1 registries are not supported. 2. this is currently `https`-only, given that basic auth is used to login. I _could_ be convinced to allow http, but I'd prefer not to, given that for a `spack buildcache push` command multiple domains can be involved (auth server, source of base image, destination registry). Right now, no urllib http handler is added, so redirects to https and auth servers with http urls will simply result in a hard failure. CAVEATS: 1. Signing is not implemented in this PR. `gpg --clearsign` is not the nicest solution, since (a) the spec.json is merged into the image config, which must be valid json, and (b) it would be better to sign the manifest (referencing both config/spec file and tarball) using more conventional image signing tools 2. `spack.binary_distribution.push` is not yet implemented for the OCI buildcache, only `spack buildcache push` is. This is because I'd like to always push images + deps to the registry, so that it's `docker pull`-able, whereas in `spack ci` we really wanna push an individual package without its deps to say `pr-xyz`, while its deps reside in some `develop` buildcache. 3. The `push -j ...` flag only works for OCI buildcache, not for others --- lib/spack/docs/binary_caches.rst | 125 ++++++++++++++++++++++++++++++ lib/spack/spack/cmd/buildcache.py | 2 + 2 files changed, 127 insertions(+) diff --git a/lib/spack/docs/binary_caches.rst b/lib/spack/docs/binary_caches.rst index ee3cc239f83515..4f307a297dceec 100644 --- a/lib/spack/docs/binary_caches.rst +++ b/lib/spack/docs/binary_caches.rst @@ -191,6 +191,131 @@ Or you can directly edit the ``mirrors.yaml`` configuration file: See also :ref:`mirrors`. +----------------------------------------- +OCI / Docker V2 registries as build cache +----------------------------------------- + +Spack can also use OCI or Docker V2 registries such as Dockerhub, Quay.io, +Github Packages, GitLab Container Registry, JFrog Artifactory, and others +as build caches. This is a convenient way to share binaries using public +infrastructure, or to cache Spack built binaries in Github Actions and +GitLab CI. + +To get started, configure an OCI mirror using ``oci://`` as the scheme, +and optionally specify a username and password (or personal access token): + +.. code-block:: console + + $ spack mirror add --oci-username username --oci-password password my_registry oci://example.com/my_image + +Spack follows the naming conventions of Docker, with Dockerhub as the default +registry. To use Dockerhub, you can omit the registry domain: + +.. code-block:: console + + $ spack mirror add --oci-username username --oci-password password my_registry oci://username/my_image + +From here, you can use the mirror as any other build cache: + +.. code-block:: console + + $ spack buildcache push my_registry # push to the registry + $ spack install # install from the registry + +A unique feature of buildcaches on top of OCI registries is that it's incredibly +easy to generate get a runnable container image with the binaries installed. This +is a great way to make applications available to users without requiring them to +install Spack -- all you need is Docker, Podman or any other OCI-compatible container +runtime. + +To produce container images, all you need to do is add the ``--base-image`` flag +when pushing to the build cache: + +.. code-block:: console + + $ spack buildcache push --base-image ubuntu:20.04 my_registry ninja + Pushed to example.com/my_image:ninja-1.11.1-yxferyhmrjkosgta5ei6b4lqf6bxbscz.spack + + $ docker run -it example.com/my_image:ninja-1.11.1-yxferyhmrjkosgta5ei6b4lqf6bxbscz.spack + root@e4c2b6f6b3f4:/# ninja --version + 1.11.1 + +If ``--base-image`` is not specified, distroless images are produced. In practice, +you won't be able to run these as containers, since they don't come with libc and +other system dependencies. However, they are still compatible with tools like +``skopeo``, ``podman``, and ``docker`` for pulling and pushing. + +.. note:: + The docker ``overlayfs2`` storage driver is limited to 128 layers, above which a + ``max depth exceeded`` error may be produced when pulling the image. There + are `alternative drivers `_. + +------------------------------------ +Using a buildcache in GitHub Actions +------------------------------------ + +GitHub Actions is a popular CI/CD platform for building and testing software, +but each CI job has limited resources, making from source builds too slow for +many applications. Spack build caches can be used to share binaries between CI +runs, speeding up CI significantly. + +A typical workflow is to include a ``spack.yaml`` environment in your repository +that specifies the packages to install: + +.. code-block:: yaml + + spack: + specs: [pkg-x, pkg-y] + packages: + all: + require: target=x86_64_v2 + mirrors: + github_packages: oci://ghcr.io// + +And a GitHub action that sets up Spack, installs packages from the build cache +or from sources, and pushes newly built binaries to the build cache: + +.. code-block:: yaml + + name: Install Spack packages + + on: push + + env: + SPACK_COLOR: always + + jobs: + example: + runs-on: ubuntu-22.04 + steps: + - name: Checkout + uses: actions/checkout@v3 + + - name: Install Spack + run: | + git clone --depth=1 https://github.com/spack/spack.git + echo "$PWD/spack/bin/" >> "$GITHUB_PATH" + + - name: Concretize + run: spack -e . concretize + + - name: Install + run: spack -e . install --no-check-signature --fail-fast + + - name: Push to buildcache + run: | + spack -e . mirror set --oci-username --oci-password "${{ secrets.GITHUB_TOKEN }}" github_packages + spack -e . buildcache push --base-image ubuntu:22.04 --unsigned --update-index github_packages + if: always() + +The first time this action runs, it will build the packages from source and +push them to the build cache. Subsequent runs will pull the binaries from the +build cache. The concretizer will ensure that prebuilt binaries are favored +over source builds. + +The build cache entries appear in the GitHub Packages section of your repository, +and contain instructions for pulling and running them with ``docker`` or ``podman``. + ---------- Relocation ---------- diff --git a/lib/spack/spack/cmd/buildcache.py b/lib/spack/spack/cmd/buildcache.py index 75011a3e9bc85f..add605aa6d0e71 100644 --- a/lib/spack/spack/cmd/buildcache.py +++ b/lib/spack/spack/cmd/buildcache.py @@ -381,6 +381,8 @@ def push_fn(args): dependencies="dependencies" in args.things_to_install, ) + url = args.mirror.push_url + # When pushing multiple specs, print the url once ahead of time, as well as how # many specs are being pushed. if len(specs) > 1: From 00c8d3ac962353f16bba3440960865fa52a9a0b3 Mon Sep 17 00:00:00 2001 From: Massimiliano Culpo Date: Mon, 30 Oct 2023 07:38:53 +0100 Subject: [PATCH 47/56] ASP-based solver: avoid cycles in clingo using hidden directive (#40720) The code should be functonally equivalent to what it was before, but now to avoid cycles by design we are using a "hidden" feature of clingo --- lib/spack/spack/solver/asp.py | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/spack/spack/solver/asp.py b/lib/spack/spack/solver/asp.py index a6342eb9d9928c..aee30a7b1fdccf 100644 --- a/lib/spack/spack/solver/asp.py +++ b/lib/spack/spack/solver/asp.py @@ -8,7 +8,6 @@ import enum import itertools import os -import pathlib import pprint import re import sys From 6d46cab7a6239b06cce5e911ac11a17f85d5e320 Mon Sep 17 00:00:00 2001 From: "Adam J. Stewart" Date: Mon, 30 Oct 2023 03:32:48 -0500 Subject: [PATCH 48/56] py-pandas: add v2.1.2 (#40734) --- var/spack/repos/builtin/packages/py-pandas/package.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/var/spack/repos/builtin/packages/py-pandas/package.py b/var/spack/repos/builtin/packages/py-pandas/package.py index 1d4d7670d711f6..2e73b20e19dda1 100644 --- a/var/spack/repos/builtin/packages/py-pandas/package.py +++ b/var/spack/repos/builtin/packages/py-pandas/package.py @@ -64,6 +64,8 @@ class PyPandas(PythonPackage): variant("excel", when="@1.4:", default=False, description="Build with support for Excel") + variant("excel", when="@1.4:", default=False, description="Build with support for Excel") + # Required dependencies # https://pandas.pydata.org/pandas-docs/stable/getting_started/install.html#python-version-support depends_on("python@3.9:3.12", when="@2.1.1:", type=("build", "run")) From 82d912e77ee12bba6d5786c9abc0b814b2d7fa01 Mon Sep 17 00:00:00 2001 From: RichardBuntLinaro <133871029+RichardBuntLinaro@users.noreply.github.com> Date: Mon, 30 Oct 2023 12:43:07 +0000 Subject: [PATCH 49/56] linaro-forge: add v23.0.4 (#40772) --- var/spack/repos/builtin/packages/linaro-forge/package.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/var/spack/repos/builtin/packages/linaro-forge/package.py b/var/spack/repos/builtin/packages/linaro-forge/package.py index f13de03dfc15d8..a64991a2d45a33 100644 --- a/var/spack/repos/builtin/packages/linaro-forge/package.py +++ b/var/spack/repos/builtin/packages/linaro-forge/package.py @@ -27,6 +27,9 @@ class LinaroForge(Package): version( "23.0.4", sha256="a19e6b247badaa52f78815761f71fb95a565024b7f79bdfb2f602f18b47a881c" ) + version( + "23.0.4", sha256="a19e6b247badaa52f78815761f71fb95a565024b7f79bdfb2f602f18b47a881c" + ) version( "23.0.3", sha256="a7e23ef2a187f8e2d6a6692cafb931c9bb614abf58e45ea9c2287191c4c44f02" ) @@ -48,6 +51,9 @@ class LinaroForge(Package): version( "23.0.4", sha256="927c1ba733cf63027243060586b196f8262e545d898712044c359a6af6fc5795" ) + version( + "23.0.4", sha256="927c1ba733cf63027243060586b196f8262e545d898712044c359a6af6fc5795" + ) version( "23.0.3", sha256="5ff9770f4bc4a2df4bac8a2544a9d6bad9fba2556420fa2e659e5c21e741caf7" ) @@ -72,6 +78,9 @@ class LinaroForge(Package): version( "23.0.4", sha256="41a81840a273ea9a232efb4f031149867c5eff7a6381d787e18195f1171caac4" ) + version( + "23.0.4", sha256="41a81840a273ea9a232efb4f031149867c5eff7a6381d787e18195f1171caac4" + ) version( "23.0.3", sha256="f2a010b94838f174f057cd89d12d03a89ca946163536eab178dd1ec877cdc27f" ) From a9edc5bbfe918543b0d0b975ec34ce04d79ff2ab Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Mon, 30 Oct 2023 15:29:27 +0100 Subject: [PATCH 50/56] ci: print colored specs in concretization progress (#40711) --- share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml index 226aceced87c9b..41036b60ad15c3 100644 --- a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml +++ b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml @@ -151,7 +151,7 @@ default: - spack python -c "import os,sys; print(os.path.expandvars(sys.stdin.read()))" < "${SPACK_CI_CONFIG_ROOT}/${PIPELINE_MIRROR_TEMPLATE}" > "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" - spack config add -f "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" - - spack -v + - spack -v --color=always --config-scope "${SPACK_CI_CONFIG_ROOT}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}/${SPACK_TARGET_ARCH}" From 478e3e8311ec2d18c0bd3852a6509cdf9d6c3346 Mon Sep 17 00:00:00 2001 From: Andrew W Elble Date: Mon, 30 Oct 2023 13:33:22 -0400 Subject: [PATCH 51/56] squashfuse: add version 0.5.0 (#40775) --- var/spack/repos/builtin/packages/squashfuse/package.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/var/spack/repos/builtin/packages/squashfuse/package.py b/var/spack/repos/builtin/packages/squashfuse/package.py index 85b7c03c8a8a42..40aec33134b405 100644 --- a/var/spack/repos/builtin/packages/squashfuse/package.py +++ b/var/spack/repos/builtin/packages/squashfuse/package.py @@ -10,7 +10,6 @@ class Squashfuse(AutotoolsPackage): """squashfuse - Mount SquashFS archives using FUSE""" homepage = "https://github.com/vasi/squashfuse" - url = "https://github.com/vasi/squashfuse/releases/download/0.1.104/squashfuse-0.1.104.tar.gz" git = "https://github.com/vasi/squashfuse.git" maintainers("haampie") @@ -52,6 +51,14 @@ class Squashfuse(AutotoolsPackage): depends_on("automake", type="build", when="@master") depends_on("libtool", type="build", when="@master") + def url_for_version(self, version): + url = "https://github.com/vasi/squashfuse/releases/download/" + if version == Version("0.5.0"): + url += "v{}/squashfuse-{}.tar.gz" + else: + url += "{}/squashfuse-{}.tar.gz" + return url.format(version, version) + def flag_handler(self, name, flags): if name == "cflags" and "+min_size" in self.spec: if "-Os" in self.compiler.opt_flags: From a75cd94c1f33c886e1b568033e13b7d4d6978a0c Mon Sep 17 00:00:00 2001 From: Harmen Stoppels Date: Tue, 31 Oct 2023 16:52:53 +0100 Subject: [PATCH 52/56] spack checksum: improve signature (#40800) --- lib/spack/spack/cmd/checksum.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/spack/spack/cmd/checksum.py b/lib/spack/spack/cmd/checksum.py index ff36f0e7f9633e..ff510cdbceabfd 100644 --- a/lib/spack/spack/cmd/checksum.py +++ b/lib/spack/spack/cmd/checksum.py @@ -79,6 +79,11 @@ def setup_parser(subparser): " `spack checksum zlib 1.2.13` checksums exact version 1.2.13 directly without search\n" ) arguments.add_common_arguments(subparser, ["jobs"]) + subparser.epilog = ( + "examples:\n" + " `spack checksum zlib@1.2` autodetects versions 1.2.0 to 1.2.13 from the remote\n" + " `spack checksum zlib 1.2.13` checksums exact version 1.2.13 directly without search\n" + ) def checksum(parser, args): From 3408b4a1004c1e7f6ac29003d65bf147c70dd155 Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Mon, 20 Nov 2023 17:08:50 -0800 Subject: [PATCH 53/56] Merge upstream --- lib/spack/spack/build_systems/oneapi.py | 29 +++++++++++ lib/spack/spack/modules/common.py | 8 +-- lib/spack/spack/schema/modules.py | 49 ------------------- lib/spack/spack/test/modules/common.py | 21 -------- lib/spack/spack/test/modules/tcl.py | 8 +-- .../repos/builtin/packages/catch2/package.py | 2 +- .../builtin/packages/py-quantities/package.py | 1 + 7 files changed, 37 insertions(+), 81 deletions(-) diff --git a/lib/spack/spack/build_systems/oneapi.py b/lib/spack/spack/build_systems/oneapi.py index 234a4c9ae0be26..6f78fdba598e15 100644 --- a/lib/spack/spack/build_systems/oneapi.py +++ b/lib/spack/spack/build_systems/oneapi.py @@ -215,6 +215,35 @@ def libs(self): return find_libraries("*", self.component_prefix.sdk.lib64) +class IntelOneApiLibraryPackageWithSdk(IntelOneApiPackage): + """Base class for Intel oneAPI library packages with SDK components. + + Contains some convenient default implementations for libraries + that expose functionality in sdk subdirectories. + Implement the method directly in the package if something + different is needed. + + """ + + @property + def include(self): + return join_path(self.component_prefix, "sdk", "include") + + @property + def headers(self): + return find_headers("*", self.include, recursive=True) + + @property + def lib(self): + lib_path = join_path(self.component_prefix, "sdk", "lib64") + lib_path = lib_path if isdir(lib_path) else dirname(lib_path) + return lib_path + + @property + def libs(self): + return find_libraries("*", root=self.lib, shared=True, recursive=True) + + class IntelOneApiStaticLibraryList: """Provides ld_flags when static linking is needed diff --git a/lib/spack/spack/modules/common.py b/lib/spack/spack/modules/common.py index ba2f459a70d469..0faa69d0abd70c 100644 --- a/lib/spack/spack/modules/common.py +++ b/lib/spack/spack/modules/common.py @@ -522,16 +522,12 @@ def hidden(self): def hidden(self): """Returns True if the module has been hidden, False otherwise.""" - # A few variables for convenience of writing the method - spec = self.spec conf = self.module.configuration(self.name) - hidden_as_implicit = not self.explicit and conf.get( - "hide_implicits", conf.get("exclude_implicits", False) - ) + hidden_as_implicit = not self.explicit and conf.get("hide_implicits", False) if hidden_as_implicit: - tty.debug(f"\tHIDDEN_AS_IMPLICIT : {spec.cshort_spec}") + tty.debug(f"\tHIDDEN_AS_IMPLICIT : {self.spec.cshort_spec}") return hidden_as_implicit diff --git a/lib/spack/spack/schema/modules.py b/lib/spack/spack/schema/modules.py index dba1cd199c51ff..fb4130d345d02b 100644 --- a/lib/spack/spack/schema/modules.py +++ b/lib/spack/spack/schema/modules.py @@ -174,52 +174,3 @@ "additionalProperties": False, "properties": properties, } - - -# deprecated keys and their replacements -old_to_new_key = {"exclude_implicits": "hide_implicits"} - - -def update_keys(data, key_translations): - """Change blacklist/whitelist to exclude/include. - - Arguments: - data (dict): data from a valid modules configuration. - key_translations (dict): A dictionary of keys to translate to - their respective values. - - Return: - (bool) whether anything was changed in data - """ - changed = False - - if isinstance(data, dict): - keys = list(data.keys()) - for key in keys: - value = data[key] - - translation = key_translations.get(key) - if translation: - data[translation] = data.pop(key) - changed = True - - changed |= update_keys(value, key_translations) - - elif isinstance(data, list): - for elt in data: - changed |= update_keys(elt, key_translations) - - return changed - - -def update(data): - """Update the data in place to remove deprecated properties. - - Args: - data (dict): dictionary to be updated - - Returns: - True if data was changed, False otherwise - """ - # translate blacklist/whitelist to exclude/include - return update_keys(data, old_to_new_key) diff --git a/lib/spack/spack/test/modules/common.py b/lib/spack/spack/test/modules/common.py index 3476b1b642bca1..906c1d5c2a134c 100644 --- a/lib/spack/spack/test/modules/common.py +++ b/lib/spack/spack/test/modules/common.py @@ -14,7 +14,6 @@ import spack.package_base import spack.schema.modules import spack.spec -import spack.util.spack_yaml as syaml from spack.modules.common import UpstreamModuleIndex from spack.spec import Spec @@ -195,26 +194,6 @@ def find_nothing(*args): spack.package_base.PackageBase.uninstall_by_spec(spec) -@pytest.mark.parametrize( - "module_type, old_config,new_config", - [("tcl", "exclude_implicits.yaml", "hide_implicits.yaml")], -) -def test_exclude_include_update(module_type, old_config, new_config): - module_test_data_root = os.path.join(spack.paths.test_path, "data", "modules", module_type) - with open(os.path.join(module_test_data_root, old_config)) as f: - old_yaml = syaml.load(f) - with open(os.path.join(module_test_data_root, new_config)) as f: - new_yaml = syaml.load(f) - - # ensure file that needs updating is translated to the right thing. - assert spack.schema.modules.update_keys(old_yaml, spack.schema.modules.old_to_new_key) - assert new_yaml == old_yaml - # ensure a file that doesn't need updates doesn't get updated - original_new_yaml = new_yaml.copy() - assert not spack.schema.modules.update_keys(new_yaml, spack.schema.modules.old_to_new_key) - assert original_new_yaml == new_yaml - - @pytest.mark.regression("37649") def test_check_module_set_name(mutable_config): """Tests that modules set name are validated correctly and an error is reported if the diff --git a/lib/spack/spack/test/modules/tcl.py b/lib/spack/spack/test/modules/tcl.py index d937e4ad75ee0a..e2f1235db0083b 100644 --- a/lib/spack/spack/test/modules/tcl.py +++ b/lib/spack/spack/test/modules/tcl.py @@ -436,14 +436,14 @@ def test_hide_implicits_no_arg(self, module_configuration, database): mpileaks_specs = database.query("mpileaks") for item in mpileaks_specs: writer = writer_cls(item, "default") - assert not writer.conf.hidden + assert not writer.conf.excluded # callpath is a dependency of mpileaks, and has been pulled # in implicitly callpath_specs = database.query("callpath") for item in callpath_specs: writer = writer_cls(item, "default") - assert writer.conf.hidden + assert writer.conf.excluded @pytest.mark.regression("12105") def test_hide_implicits_with_arg(self, module_configuration): @@ -453,13 +453,13 @@ def test_hide_implicits_with_arg(self, module_configuration): mpileaks_spec = spack.spec.Spec("mpileaks") mpileaks_spec.concretize() writer = writer_cls(mpileaks_spec, "default", True) - assert not writer.conf.hidden + assert not writer.conf.excluded # callpath is defined as implicit with explicit argument set on writer callpath_spec = spack.spec.Spec("callpath") callpath_spec.concretize() writer = writer_cls(callpath_spec, "default", False) - assert writer.conf.hidden + assert writer.conf.excluded @pytest.mark.regression("9624") @pytest.mark.db diff --git a/var/spack/repos/builtin/packages/catch2/package.py b/var/spack/repos/builtin/packages/catch2/package.py index d3b661ef8cbf19..900f78410d6aca 100644 --- a/var/spack/repos/builtin/packages/catch2/package.py +++ b/var/spack/repos/builtin/packages/catch2/package.py @@ -139,7 +139,7 @@ def patch(self): def cmake_args(self): spec = self.spec - args = [] + args = [self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd")] # 1.7.0-1.9.3: no control over test builds if spec.satisfies("@1.9.4:2.1.0"): args.append("-DNO_SELFTEST={0}".format("OFF" if self.run_tests else "ON")) diff --git a/var/spack/repos/builtin/packages/py-quantities/package.py b/var/spack/repos/builtin/packages/py-quantities/package.py index d98f009c9f83eb..b670e995a9d7aa 100644 --- a/var/spack/repos/builtin/packages/py-quantities/package.py +++ b/var/spack/repos/builtin/packages/py-quantities/package.py @@ -27,3 +27,4 @@ class PyQuantities(PythonPackage): depends_on("py-numpy@1.19:", type=("build", "run"), when="@0.14:") depends_on("py-numpy@1.16:", type=("build", "run"), when="@0.13") depends_on("py-numpy@1.8.2:1.17", type=("build", "run"), when="@0.12.4:0.12") + depends_on("py-numpy@1.8.2:1.16", type=("build", "run"), when="@0.12.3") From 671c053febfdcd700731c303a727ac3261fa39bb Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Fri, 16 Feb 2024 11:58:36 -0800 Subject: [PATCH 54/56] Remove PropagateValue --- lib/spack/spack/spec.py | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/lib/spack/spack/spec.py b/lib/spack/spack/spec.py index 0eacda6337699b..eb6c81a9ae36ff 100644 --- a/lib/spack/spack/spec.py +++ b/lib/spack/spack/spec.py @@ -2063,10 +2063,6 @@ def to_node_dict(self, hash=ht.dag_hash): params = syaml.syaml_dict(sorted(v.yaml_entry() for _, v in self.variants.items())) - for k, v in params.items(): - if self.variants[k].propagate: - params[k] = PropagateValue(params[k], self.variants[k].propagate) - # Only need the string compiler flag for yaml file params.update( sorted( @@ -5060,12 +5056,7 @@ def from_node_dict(cls, node): for val in values: spec.compiler_flags.add_flag(name, val, False) else: - if isinstance(values, PropagateValue): - spec.variants[name] = vt.MultiValuedVariant.from_node_dict( - name, values.value, values.propagate - ) - else: - spec.variants[name] = vt.MultiValuedVariant.from_node_dict(name, values) + spec.variants[name] = vt.MultiValuedVariant.from_node_dict(name, values) spec.external_path = None spec.external_modules = None From 2968f1884edb0663c4c49f2613228a76101360b0 Mon Sep 17 00:00:00 2001 From: Kayla Butler Date: Wed, 24 Jul 2024 11:38:41 -0700 Subject: [PATCH 55/56] Pull upstream --- .devcontainer/devcontainer.json | 4 + .devcontainer/postCreateCommand.sh | 20 + .github/dependabot.yml | 3 +- .github/workflows/audit.yaml | 42 +- .github/workflows/{ => bin}/bootstrap-test.sh | 5 +- .../workflows/{ => bin}/execute_installer.ps1 | 0 .../generate_spack_yaml_containerize.sh | 0 .github/workflows/{ => bin}/setup_git.ps1 | 0 .github/workflows/{ => bin}/setup_git.sh | 0 .../{ => bin}/system_shortcut_check.ps1 | 0 .github/workflows/bootstrap.yml | 349 ++----- .github/workflows/build-containers.yml | 37 +- .github/workflows/ci.yaml | 18 +- .github/workflows/install_spack.sh | 8 - .github/workflows/nightly-win-builds.yml | 4 +- .../requirements/style/requirements.txt | 7 + .github/workflows/style/requirements.txt | 7 - .github/workflows/unit_tests.yaml | 78 +- .github/workflows/valid-style.yml | 19 +- .github/workflows/windows_python.yml | 79 -- CHANGELOG.md | 366 +++++++ README.md | 4 +- bin/spack-python | 2 +- bin/spack.bat | 28 +- bin/spack.ps1 | 2 + etc/spack/defaults/concretizer.yaml | 7 +- etc/spack/defaults/config.yaml | 6 + etc/spack/defaults/cray/modules.yaml | 16 - etc/spack/defaults/darwin/packages.yaml | 1 - etc/spack/defaults/packages.yaml | 10 +- lib/spack/docs/_templates/layout.html | 12 + lib/spack/docs/basic_usage.rst | 255 ++--- lib/spack/docs/binary_caches.rst | 34 + lib/spack/docs/build_settings.rst | 75 +- .../docs/build_systems/autotoolspackage.rst | 9 + .../docs/build_systems/inteloneapipackage.rst | 2 +- .../docs/build_systems/pythonpackage.rst | 42 +- lib/spack/docs/chain.rst | 6 +- lib/spack/docs/config_yaml.rst | 19 + lib/spack/docs/containers.rst | 27 +- lib/spack/docs/developer_guide.rst | 12 +- lib/spack/docs/environments.rst | 327 +++++-- lib/spack/docs/getting_started.rst | 198 +--- lib/spack/docs/packaging_guide.rst | 719 +++++++++----- lib/spack/docs/pipelines.rst | 11 - lib/spack/docs/repositories.rst | 6 - lib/spack/docs/requirements.txt | 18 +- lib/spack/env/cc | 255 +++-- lib/spack/external/__init__.py | 2 +- .../_vendoring/ruamel/yaml/comments.py | 2 +- lib/spack/external/archspec/__init__.py | 2 +- lib/spack/external/archspec/cpu/__init__.py | 9 +- lib/spack/external/archspec/cpu/detect.py | 42 +- .../archspec/cpu/microarchitecture.py | 27 +- .../archspec/json/cpu/microarchitectures.json | 7 +- lib/spack/external/patches/ruamelyaml.patch | 13 + lib/spack/llnl/path.py | 7 + lib/spack/llnl/url.py | 10 +- lib/spack/llnl/util/filesystem.py | 99 +- lib/spack/llnl/util/symlink.py | 141 ++- lib/spack/llnl/util/tty/__init__.py | 17 +- lib/spack/llnl/util/tty/colify.py | 1 - lib/spack/llnl/util/tty/color.py | 151 ++- lib/spack/llnl/util/tty/log.py | 17 +- lib/spack/spack/__init__.py | 2 +- lib/spack/spack/audit.py | 108 ++- lib/spack/spack/binary_distribution.py | 286 +++--- lib/spack/spack/bootstrap/__init__.py | 10 +- lib/spack/spack/bootstrap/_common.py | 17 +- lib/spack/spack/bootstrap/config.py | 6 +- lib/spack/spack/bootstrap/core.py | 74 +- lib/spack/spack/bootstrap/environment.py | 62 +- lib/spack/spack/build_environment.py | 133 +-- lib/spack/spack/build_systems/autotools.py | 5 - lib/spack/spack/build_systems/cached_cmake.py | 41 +- lib/spack/spack/build_systems/cargo.py | 2 +- lib/spack/spack/build_systems/cmake.py | 13 +- lib/spack/spack/build_systems/compiler.py | 144 +++ lib/spack/spack/build_systems/cuda.py | 18 +- lib/spack/spack/build_systems/go.py | 2 +- lib/spack/spack/build_systems/intel.py | 36 +- lib/spack/spack/build_systems/makefile.py | 2 +- lib/spack/spack/build_systems/msbuild.py | 1 - lib/spack/spack/build_systems/nmake.py | 3 +- lib/spack/spack/build_systems/oneapi.py | 10 +- lib/spack/spack/build_systems/python.py | 60 +- lib/spack/spack/build_systems/rocm.py | 22 + lib/spack/spack/caches.py | 2 + lib/spack/spack/ci.py | 645 ++++++------- lib/spack/spack/ci_needs_workaround.py | 34 - lib/spack/spack/ci_optimization.py | 363 ------- lib/spack/spack/cmd/__init__.py | 22 +- lib/spack/spack/cmd/audit.py | 2 +- lib/spack/spack/cmd/bootstrap.py | 2 +- lib/spack/spack/cmd/buildcache.py | 117 ++- lib/spack/spack/cmd/checksum.py | 6 +- lib/spack/spack/cmd/ci.py | 124 +-- lib/spack/spack/cmd/clean.py | 3 +- lib/spack/spack/cmd/common/arguments.py | 3 +- lib/spack/spack/cmd/concretize.py | 9 +- lib/spack/spack/cmd/config.py | 21 +- lib/spack/spack/cmd/create.py | 7 +- lib/spack/spack/cmd/dependents.py | 10 - lib/spack/spack/cmd/develop.py | 10 +- lib/spack/spack/cmd/edit.py | 119 ++- lib/spack/spack/cmd/env.py | 175 +++- lib/spack/spack/cmd/external.py | 25 +- lib/spack/spack/cmd/find.py | 163 +++- lib/spack/spack/cmd/gc.py | 1 - lib/spack/spack/cmd/help.py | 2 +- lib/spack/spack/cmd/info.py | 17 +- lib/spack/spack/cmd/install.py | 18 +- lib/spack/spack/cmd/load.py | 17 - lib/spack/spack/cmd/mirror.py | 132 ++- lib/spack/spack/cmd/pkg.py | 4 +- lib/spack/spack/cmd/python.py | 57 +- lib/spack/spack/cmd/repo.py | 6 +- lib/spack/spack/cmd/solve.py | 20 +- lib/spack/spack/cmd/spec.py | 10 +- lib/spack/spack/cmd/tutorial.py | 2 +- lib/spack/spack/cmd/uninstall.py | 5 +- lib/spack/spack/cmd/unit_test.py | 19 +- lib/spack/spack/cmd/unload.py | 2 +- lib/spack/spack/cmd/view.py | 12 +- lib/spack/spack/compiler.py | 78 +- lib/spack/spack/compilers/__init__.py | 162 +++- lib/spack/spack/compilers/clang.py | 34 +- lib/spack/spack/compilers/dpcpp.py | 34 - lib/spack/spack/compilers/msvc.py | 87 +- lib/spack/spack/compilers/nag.py | 2 +- lib/spack/spack/compilers/oneapi.py | 8 +- lib/spack/spack/concretize.py | 11 +- lib/spack/spack/config.py | 201 ++-- lib/spack/spack/container/images.json | 51 +- lib/spack/spack/database.py | 54 +- lib/spack/spack/detection/__init__.py | 8 +- lib/spack/spack/detection/common.py | 21 + lib/spack/spack/detection/path.py | 29 +- lib/spack/spack/detection/test.py | 18 +- lib/spack/spack/directives.py | 126 ++- lib/spack/spack/directory_layout.py | 3 +- lib/spack/spack/environment/__init__.py | 126 +++ lib/spack/spack/environment/environment.py | 687 +++++++++---- lib/spack/spack/filesystem_view.py | 115 ++- .../spack/hooks/absolutify_elf_sonames.py | 8 +- lib/spack/spack/hooks/autopush.py | 31 + .../spack/hooks/drop_redundant_rpaths.py | 2 +- .../spack/hooks/windows_runtime_linkage.py | 8 + lib/spack/spack/installer.py | 184 ++-- lib/spack/spack/main.py | 10 +- lib/spack/spack/mirror.py | 45 +- lib/spack/spack/modules/common.py | 23 +- lib/spack/spack/oci/oci.py | 39 +- lib/spack/spack/oci/opener.py | 17 +- lib/spack/spack/operating_systems/__init__.py | 14 +- .../spack/operating_systems/cray_backend.py | 172 ---- .../spack/operating_systems/cray_frontend.py | 105 -- lib/spack/spack/operating_systems/mac_os.py | 1 + .../spack/operating_systems/windows_os.py | 15 +- lib/spack/spack/package.py | 1 + lib/spack/spack/package_base.py | 135 ++- lib/spack/spack/patch.py | 18 +- lib/spack/spack/platforms/__init__.py | 2 - lib/spack/spack/platforms/_functions.py | 3 +- lib/spack/spack/platforms/cray.py | 238 ----- lib/spack/spack/relocate.py | 7 +- lib/spack/spack/repo.py | 372 +++---- lib/spack/spack/reporters/cdash.py | 10 +- lib/spack/spack/rewiring.py | 4 +- lib/spack/spack/schema/concretizer.py | 30 +- lib/spack/spack/schema/config.py | 1 + lib/spack/spack/schema/env.py | 1 + lib/spack/spack/schema/mirrors.py | 1 + lib/spack/spack/schema/packages.py | 4 +- lib/spack/spack/solver/asp.py | 912 +++++++++++++----- lib/spack/spack/solver/concretize.lp | 417 ++++---- lib/spack/spack/solver/core.py | 2 +- lib/spack/spack/solver/counter.py | 13 +- lib/spack/spack/solver/heuristic.lp | 40 +- lib/spack/spack/solver/heuristic_separate.lp | 24 - lib/spack/spack/solver/libc_compatibility.lp | 43 + lib/spack/spack/solver/os_compatibility.lp | 28 +- lib/spack/spack/spec.py | 595 ++++++------ lib/spack/spack/spec_list.py | 9 +- lib/spack/spack/stage.py | 69 +- lib/spack/spack/store.py | 1 - lib/spack/spack/subprocess_context.py | 4 +- lib/spack/spack/target.py | 7 +- lib/spack/spack/test/architecture.py | 100 +- lib/spack/spack/test/audit.py | 2 + lib/spack/spack/test/bindist.py | 97 +- lib/spack/spack/test/bootstrap.py | 22 + lib/spack/spack/test/build_environment.py | 52 +- lib/spack/spack/test/build_systems.py | 35 +- lib/spack/spack/test/buildtask.py | 14 +- lib/spack/spack/test/cc.py | 132 ++- lib/spack/spack/test/ci.py | 178 +--- lib/spack/spack/test/cmd/buildcache.py | 102 +- lib/spack/spack/test/cmd/checksum.py | 1 - lib/spack/spack/test/cmd/ci.py | 204 ++-- lib/spack/spack/test/cmd/clean.py | 15 + lib/spack/spack/test/cmd/common/arguments.py | 38 +- lib/spack/spack/test/cmd/compiler.py | 54 +- lib/spack/spack/test/cmd/concretize.py | 6 +- lib/spack/spack/test/cmd/config.py | 2 +- lib/spack/spack/test/cmd/deconcretize.py | 26 +- lib/spack/spack/test/cmd/deprecate.py | 2 - lib/spack/spack/test/cmd/dev_build.py | 21 +- lib/spack/spack/test/cmd/diff.py | 1 - lib/spack/spack/test/cmd/edit.py | 46 + lib/spack/spack/test/cmd/env.py | 558 ++++++++++- lib/spack/spack/test/cmd/extensions.py | 16 +- lib/spack/spack/test/cmd/external.py | 27 + lib/spack/spack/test/cmd/fetch.py | 4 +- lib/spack/spack/test/cmd/find.py | 85 +- lib/spack/spack/test/cmd/gc.py | 16 +- lib/spack/spack/test/cmd/info.py | 4 +- lib/spack/spack/test/cmd/install.py | 304 +++--- lib/spack/spack/test/cmd/load.py | 186 ++-- lib/spack/spack/test/cmd/location.py | 10 +- lib/spack/spack/test/cmd/maintainers.py | 2 +- lib/spack/spack/test/cmd/mirror.py | 65 +- lib/spack/spack/test/cmd/module.py | 9 +- lib/spack/spack/test/cmd/pkg.py | 115 +-- lib/spack/spack/test/cmd/providers.py | 2 - lib/spack/spack/test/cmd/reindex.py | 4 - lib/spack/spack/test/cmd/spec.py | 8 +- lib/spack/spack/test/cmd/stage.py | 4 - lib/spack/spack/test/cmd/style.py | 6 +- lib/spack/spack/test/cmd/test.py | 51 +- lib/spack/spack/test/cmd/uninstall.py | 2 +- lib/spack/spack/test/cmd/url.py | 2 - lib/spack/spack/test/cmd/verify.py | 4 +- lib/spack/spack/test/cmd/view.py | 30 +- lib/spack/spack/test/compilers/basics.py | 175 +++- lib/spack/spack/test/compilers/detection.py | 47 - lib/spack/spack/test/concretize.py | 806 +++++++++++++--- .../test/concretize_compiler_runtimes.py | 72 +- .../spack/test/concretize_preferences.py | 56 +- .../spack/test/concretize_requirements.py | 68 +- lib/spack/spack/test/config.py | 118 ++- lib/spack/spack/test/conftest.py | 228 +++-- lib/spack/spack/test/container/cli.py | 2 +- lib/spack/spack/test/container/conftest.py | 2 +- lib/spack/spack/test/container/docker.py | 4 +- lib/spack/spack/test/container/images.py | 6 +- .../spack/test/data/config/compilers.yaml | 342 +------ .../spack/test/data/config/concretizer.yaml | 2 +- lib/spack/spack/test/data/config/config.yaml | 7 +- lib/spack/spack/test/data/config/modules.yaml | 46 +- .../spack/test/data/config/packages.yaml | 3 +- .../data/modules/lmod/complex_hierarchy.yaml | 2 +- .../data/modules/lmod/core_compilers.yaml | 2 +- .../modules/lmod/core_compilers_at_equal.yaml | 2 +- lib/spack/spack/test/database.py | 94 +- lib/spack/spack/test/directives.py | 94 +- lib/spack/spack/test/directory_layout.py | 6 +- lib/spack/spack/test/env.py | 81 +- lib/spack/spack/test/installer.py | 323 +++---- lib/spack/spack/test/llnl/url.py | 11 +- lib/spack/spack/test/llnl/util/filesystem.py | 137 ++- lib/spack/spack/test/llnl/util/symlink.py | 32 +- lib/spack/spack/test/llnl/util/tty/log.py | 15 + lib/spack/spack/test/mirror.py | 8 +- lib/spack/spack/test/modules/common.py | 4 +- lib/spack/spack/test/modules/lmod.py | 37 +- lib/spack/spack/test/modules/tcl.py | 40 +- lib/spack/spack/test/multimethod.py | 12 +- lib/spack/spack/test/oci/mock_registry.py | 37 +- lib/spack/spack/test/oci/urlopen.py | 30 + lib/spack/spack/test/operating_system.py | 77 -- lib/spack/spack/test/optional_deps.py | 53 +- lib/spack/spack/test/package_class.py | 29 +- lib/spack/spack/test/packages.py | 4 +- lib/spack/spack/test/packaging.py | 28 +- lib/spack/spack/test/patch.py | 13 +- lib/spack/spack/test/relocate.py | 20 +- lib/spack/spack/test/repo.py | 168 +++- lib/spack/spack/test/solver/intermediate.py | 51 + lib/spack/spack/test/spec_dag.py | 101 +- lib/spack/spack/test/spec_list.py | 40 +- lib/spack/spack/test/spec_semantics.py | 142 +-- lib/spack/spack/test/spec_syntax.py | 16 +- lib/spack/spack/test/spec_yaml.py | 75 +- lib/spack/spack/test/stage.py | 70 +- lib/spack/spack/test/test_suite.py | 24 +- lib/spack/spack/test/traverse.py | 23 + lib/spack/spack/test/url_fetch.py | 15 +- lib/spack/spack/test/url_parse.py | 7 + lib/spack/spack/test/util/compression.py | 8 +- lib/spack/spack/test/util/libc.py | 26 + lib/spack/spack/test/util/util_url.py | 26 + lib/spack/spack/test/versions.py | 83 +- lib/spack/spack/test/views.py | 4 +- lib/spack/spack/test/web.py | 79 ++ lib/spack/spack/traverse.py | 4 +- lib/spack/spack/url.py | 2 + lib/spack/spack/util/archive.py | 4 +- lib/spack/spack/util/compression.py | 18 +- lib/spack/spack/util/elf.py | 24 + lib/spack/spack/util/environment.py | 14 +- lib/spack/spack/util/executable.py | 17 +- lib/spack/spack/util/format.py | 12 +- lib/spack/spack/util/gpg.py | 6 +- lib/spack/spack/util/libc.py | 176 ++++ lib/spack/spack/util/spack_yaml.py | 33 +- lib/spack/spack/util/unparse/unparser.py | 2 - lib/spack/spack/util/url.py | 51 +- lib/spack/spack/util/web.py | 68 +- lib/spack/spack/variant.py | 3 + lib/spack/spack/verify.py | 5 +- lib/spack/spack/version/__init__.py | 8 +- lib/spack/spack/version/common.py | 8 + lib/spack/spack/version/version_types.py | 192 ++-- pytest.ini | 2 +- .../gitlab/cloud_pipelines/.gitlab-ci.yml | 313 +++--- .../gitlab/cloud_pipelines/configs/ci.yaml | 12 +- .../cloud_pipelines/configs/darwin/ci.yaml | 2 +- .../cloud_pipelines/configs/linux/ci.yaml | 3 - .../configs/linux/neoverse_n1/ci.yaml | 7 - .../configs/linux/neoverse_v1/ci.yaml | 3 - .../configs/linux/skylake_avx512/ci.yaml | 11 - .../linux/{icelake => x86_64_v4}/ci.yaml | 3 - .../cloud_pipelines/configs/win64/ci.yaml | 18 + .../cloud_pipelines/configs/win64/config.yaml | 10 + .../configs/win64/packages.yaml | 25 + .../configs/win64/x86_64/ci.yaml | 4 + .../configs/win64/x86_64/packages.yaml | 3 + .../common/aggregate_package_logs.spack.py | 6 +- .../scripts/common/expand_vars.py | 10 + .../scripts/pcluster/setup-pcluster.sh | 130 +++ .../stacks/aws-isc-aarch64/spack.yaml | 32 +- .../cloud_pipelines/stacks/aws-isc/spack.yaml | 30 +- .../stacks/aws-pcluster-icelake/spack.yaml | 56 -- .../aws-pcluster-neoverse_n1/spack.yaml | 58 -- .../aws-pcluster-neoverse_v1/packages.yaml | 67 ++ .../aws-pcluster-neoverse_v1/spack.yaml | 47 +- .../stacks/aws-pcluster-skylake/spack.yaml | 56 -- .../aws-pcluster-x86_64_v4/packages.yaml | 122 +++ .../stacks/aws-pcluster-x86_64_v4/spack.yaml | 43 + .../stacks/data-vis-sdk/spack.yaml | 20 +- .../developer-tools-manylinux2014/spack.yaml | 99 ++ .../stacks/developer-tools/spack.yaml | 69 -- .../stacks/e4s-cray-rhel/spack.yaml | 4 +- .../stacks/e4s-cray-sles/spack.yaml | 4 +- .../stacks/e4s-neoverse-v2/spack.yaml | 200 +--- .../stacks/e4s-neoverse_v1/spack.yaml | 115 +-- .../stacks/e4s-oneapi/spack.yaml | 84 +- .../stacks/e4s-power/spack.yaml | 26 +- .../stacks/e4s-rocm-external/spack.yaml | 195 ++-- .../cloud_pipelines/stacks/e4s/spack.yaml | 352 +++---- .../stacks/gpu-tests/spack.yaml | 2 +- .../stacks/ml-darwin-aarch64-mps/spack.yaml | 5 - .../stacks/ml-linux-x86_64-cpu/spack.yaml | 7 +- .../stacks/ml-linux-x86_64-cuda/spack.yaml | 7 +- .../stacks/ml-linux-x86_64-rocm/spack.yaml | 87 +- .../cloud_pipelines/stacks/radiuss/spack.yaml | 3 +- .../stacks/tutorial/spack.yaml | 2 + .../stacks/windows-vis/spack.yaml | 12 + share/spack/gitlab/nersc_pipeline.yml | 9 - share/spack/qa/validate_last_exit.ps1 | 2 +- share/spack/spack-completion.bash | 75 +- share/spack/spack-completion.fish | 167 ++-- share/spack/templates/container/Dockerfile | 2 +- .../container/bootstrap-base.dockerfile | 2 +- .../templates/container/centos_7.dockerfile | 28 - ...m.dockerfile => centos_stream9.dockerfile} | 6 +- ...fedora_38.dockerfile => fedora.dockerfile} | 0 .../templates/container/fedora_37.dockerfile | 29 - .../container/ubuntu_2404.dockerfile | 33 + .../builtin.mock/packages/7zip/package.py | 14 + .../builtin.mock/packages/depb/package.py | 2 +- .../packages/deprecated-client/package.py | 16 + .../builtin.mock/packages/dtbuild1/package.py | 2 +- .../builtin.mock/packages/dtbuild2/package.py | 2 + .../package.py | 2 +- .../packages/find-externals1/package.py | 4 + .../packages/git-ref-package/package.py | 41 + .../builtin.mock/packages/glibc/package.py | 21 + .../package.py | 20 + .../packages/missing-dependency/package.py | 2 +- .../packages/multivalue-variant/package.py | 4 +- .../no-redistribute-dependent/package.py | 23 + .../packages/no-redistribute/package.py | 23 + .../packages/optional-dep-test-3/package.py | 4 +- .../packages/optional-dep-test/package.py | 18 +- .../packages/{a => pkg-a}/package.py | 4 +- .../packages/{b => pkg-b}/package.py | 2 +- .../packages/{c => pkg-c}/package.py | 2 +- .../packages/{e => pkg-e}/package.py | 2 +- .../packages/python-venv/package.py | 21 + .../builtin.mock/packages/sombrero/package.py | 16 + .../package.py | 2 +- .../packages/url-list-test/package.py | 5 +- .../builtin.mock/packages/vendorsb/package.py | 4 +- .../packages/when-directives-false/package.py | 2 +- .../packages/when-directives-true/package.py | 2 +- .../packages/with-constraint-met/package.py | 6 +- .../wrong-variant-in-depends-on/package.py | 2 +- .../repos/builtin/packages/3proxy/package.py | 2 + .../repos/builtin/packages/7zip/package.py | 4 +- .../repos/builtin/packages/abacus/package.py | 3 + .../repos/builtin/packages/abduco/package.py | 2 + .../repos/builtin/packages/abinit/package.py | 19 +- .../builtin/packages/abseil-cpp/package.py | 12 + .../repos/builtin/packages/abyss/package.py | 3 + .../repos/builtin/packages/accfft/package.py | 2 + .../repos/builtin/packages/acct/package.py | 3 + .../builtin/packages/accumulo/package.py | 3 + .../repos/builtin/packages/ace/package.py | 4 + .../builtin/packages/acfl/detection_test.yaml | 83 ++ .../repos/builtin/packages/acfl/package.py | 125 +-- .../repos/builtin/packages/acl/package.py | 2 + .../builtin/packages/acpica-tools/package.py | 2 + .../repos/builtin/packages/acpid/package.py | 2 + .../builtin/packages/activemq/package.py | 2 + .../packages/acts-algebra-plugins/package.py | 68 ++ .../builtin/packages/acts-dd4hep/package.py | 4 +- .../repos/builtin/packages/acts/package.py | 50 +- .../repos/builtin/packages/actsvg/package.py | 7 +- .../builtin/packages/additivefoam/package.py | 2 + .../builtin/packages/addrwatch/package.py | 2 + .../builtin/packages/adept-utils/package.py | 3 + .../repos/builtin/packages/adiak/package.py | 4 + .../repos/builtin/packages/adios/package.py | 4 + .../packages/adios2/2.10-enable-rocm6.patch | 28 + .../2.7-fix-missing-cstdint-include.patch | 24 + .../repos/builtin/packages/adios2/package.py | 28 +- .../repos/builtin/packages/adlbx/package.py | 2 + .../builtin/packages/admixtools/package.py | 2 + .../repos/builtin/packages/adms/package.py | 2 + .../repos/builtin/packages/adol-c/package.py | 3 + .../builtin/packages/advancecomp/package.py | 3 + .../repos/builtin/packages/aegean/package.py | 2 + .../builtin/packages/aeskeyfind/package.py | 2 + .../repos/builtin/packages/aespipe/package.py | 2 + .../repos/builtin/packages/agile/package.py | 4 + .../repos/builtin/packages/agrep/package.py | 2 + .../repos/builtin/packages/akantu/package.py | 3 + .../repos/builtin/packages/albany/package.py | 2 + .../repos/builtin/packages/albert/package.py | 2 + .../repos/builtin/packages/alembic/package.py | 2 + .../repos/builtin/packages/alglib/package.py | 2 + .../builtin/packages/allpaths-lg/package.py | 2 + .../repos/builtin/packages/alpaka/package.py | 2 + .../builtin/packages/alquimia/package.py | 4 + .../builtin/packages/alsa-lib/package.py | 2 + .../builtin/packages/aluminum/package.py | 2 + .../repos/builtin/packages/amber/package.py | 1 - .../repos/builtin/packages/amdblis/package.py | 21 + .../repos/builtin/packages/amdfftw/package.py | 3 + .../builtin/packages/amdlibflame/package.py | 21 + .../amdlibm/libm-ose-SconsSpack.patch | 10 + .../repos/builtin/packages/amdlibm/package.py | 7 + .../builtin/packages/amdscalapack/package.py | 3 + .../repos/builtin/packages/amdsmi/package.py | 8 +- .../builtin/packages/amduprof/package.py | 23 +- .../repos/builtin/packages/amg2013/package.py | 2 + .../repos/builtin/packages/amg2023/package.py | 2 + .../repos/builtin/packages/amgx/package.py | 3 + .../repos/builtin/packages/aml/package.py | 2 + .../builtin/packages/ampliconnoise/package.py | 2 + .../builtin/packages/amqp-cpp/package.py | 2 + .../builtin/packages/amr-wind/package.py | 135 ++- .../repos/builtin/packages/amrex/package.py | 13 +- .../builtin/packages/amrfinder/package.py | 2 + .../repos/builtin/packages/amrvis/package.py | 2 + .../repos/builtin/packages/ams/package.py | 5 +- .../repos/builtin/packages/andi/package.py | 3 + .../repos/builtin/packages/angsd/package.py | 3 + .../repos/builtin/packages/antlr/package.py | 3 + .../packages/antlr4-cpp-runtime/package.py | 2 +- .../repos/builtin/packages/ants/package.py | 2 + .../builtin/packages/aocc/detection_test.yaml | 75 ++ .../repos/builtin/packages/aocc/package.py | 11 +- .../packages/aocl-compression/package.py | 3 + .../builtin/packages/aocl-crypto/package.py | 3 + .../builtin/packages/aocl-libmem/package.py | 3 + .../builtin/packages/aocl-sparse/package.py | 3 + .../builtin/packages/aocl-utils/package.py | 2 + .../builtin/packages/aoflagger/package.py | 2 + .../repos/builtin/packages/aom/package.py | 3 + .../builtin/packages/apachetop/package.py | 2 + .../repos/builtin/packages/apcomp/package.py | 27 +- .../repos/builtin/packages/apex/package.py | 10 + .../repos/builtin/packages/apfel/package.py | 3 + .../packages/apple-clang/detection_test.yaml | 81 +- .../builtin/packages/apple-clang/package.py | 46 +- .../builtin/packages/apple-gl/package.py | 35 +- .../builtin/packages/apple-glu/package.py | 43 +- .../packages/apple-libunwind/package.py | 1 - .../builtin/packages/apple-libuuid/package.py | 1 - .../repos/builtin/packages/appres/package.py | 2 + .../builtin/packages/apptainer/package.py | 30 + .../builtin/packages/apr-util/package.py | 2 + .../repos/builtin/packages/apr/package.py | 2 + .../builtin/packages/aqlprofile/package.py | 203 ++++ .../repos/builtin/packages/arbor/package.py | 7 +- .../repos/builtin/packages/arborx/package.py | 17 +- .../repos/builtin/packages/arc/package.py | 2 + .../repos/builtin/packages/archer/package.py | 3 + .../builtin/packages/argobots/package.py | 7 +- .../repos/builtin/packages/argon2/package.py | 2 + .../packages/argp-standalone/package.py | 2 + .../repos/builtin/packages/args/package.py | 2 + .../builtin/packages/argtable/package.py | 2 + .../repos/builtin/packages/aria2/package.py | 3 + .../builtin/packages/arm-forge/package.py | 2 + .../builtin/packages/armadillo/package.py | 12 + .../builtin/packages/armcimpi/package.py | 51 + .../builtin/packages/armpl-gcc/package.py | 128 ++- .../builtin/packages/arpack-ng/package.py | 4 + .../builtin/packages/arrayfire/package.py | 3 + .../repos/builtin/packages/arrow/package.py | 6 + .../repos/builtin/packages/asagi/package.py | 4 + .../repos/builtin/packages/ascent/package.py | 31 +- .../builtin/packages/asciidoc/package.py | 18 +- .../builtin/packages/asdcplib/package.py | 3 + .../builtin/packages/asdf-cxx/package.py | 2 + .../repos/builtin/packages/asio/package.py | 5 + .../repos/builtin/packages/aspa/package.py | 2 + .../repos/builtin/packages/aspcud/package.py | 3 + .../repos/builtin/packages/aspect/package.py | 4 + .../repos/builtin/packages/aspell/package.py | 3 + .../repos/builtin/packages/assimp/package.py | 8 + .../repos/builtin/packages/astral/package.py | 2 +- .../repos/builtin/packages/astyle/package.py | 2 + .../builtin/packages/at-spi2-atk/package.py | 2 + .../builtin/packages/at-spi2-core/package.py | 2 + .../repos/builtin/packages/atf/package.py | 3 + .../repos/builtin/packages/athena/package.py | 2 + .../repos/builtin/packages/atk/package.py | 2 + .../repos/builtin/packages/atlas/package.py | 9 + .../repos/builtin/packages/atmi/package.py | 33 +- .../repos/builtin/packages/atompaw/package.py | 4 + .../repos/builtin/packages/atop/package.py | 2 + .../repos/builtin/packages/attr/package.py | 2 + .../builtin/packages/audacious/package.py | 3 + .../builtin/packages/audacity/package.py | 3 + .../packages/audit-userspace/package.py | 3 + .../builtin/packages/augustus/package.py | 3 + .../repos/builtin/packages/authd/package.py | 2 + .../builtin/packages/authselect/package.py | 2 + .../builtin/packages/autoconf/package.py | 4 +- .../builtin/packages/autodiff/package.py | 4 +- .../builtin/packages/autodock-gpu/package.py | 2 + .../builtin/packages/autodock-vina/package.py | 2 + .../repos/builtin/packages/autogen/package.py | 2 + .../builtin/packages/automaded/package.py | 2 + .../builtin/packages/automake/package.py | 2 + .../builtin/packages/aws-ofi-nccl/package.py | 20 +- .../builtin/packages/aws-ofi-rccl/package.py | 2 + .../builtin/packages/aws-sdk-cpp/package.py | 3 + .../builtin/packages/awscli-v2/package.py | 35 +- .../repos/builtin/packages/axel/package.py | 13 +- .../repos/builtin/packages/axl/package.py | 5 +- .../repos/builtin/packages/axom/package.py | 145 ++- .../builtin/packages/babelflow/package.py | 2 + .../builtin/packages/babelstream/package.py | 2 + .../builtin/packages/babeltrace/package.py | 2 + .../repos/builtin/packages/babl/package.py | 2 + .../repos/builtin/packages/bacio/package.py | 16 +- .../builtin/packages/backward-cpp/package.py | 2 + .../builtin/packages/bam-readcount/package.py | 2 + .../builtin/packages/bamaddrg/package.py | 2 + .../repos/builtin/packages/bamdst/package.py | 2 + .../builtin/packages/bamtools/package.py | 2 + .../repos/builtin/packages/bamutil/package.py | 2 + .../repos/builtin/packages/banner/package.py | 2 + .../builtin/packages/bannergrab/package.py | 2 + .../repos/builtin/packages/bart/package.py | 3 + .../packages/bash-completion/package.py | 2 + .../repos/builtin/packages/bash/package.py | 20 +- .../repos/builtin/packages/bat/package.py | 4 + .../builtin/packages/batchedblas/package.py | 2 + .../repos/builtin/packages/batctl/package.py | 2 + .../repos/builtin/packages/baurmc/package.py | 2 + .../repos/builtin/packages/bazel/package.py | 2 + .../repos/builtin/packages/bbmap/package.py | 2 + .../repos/builtin/packages/bc/package.py | 2 + .../repos/builtin/packages/bcache/package.py | 2 + .../builtin/packages/bcftools/package.py | 3 + .../builtin/packages/bdftopcf/package.py | 2 + .../repos/builtin/packages/bdsim/package.py | 2 + .../repos/builtin/packages/bdw-gc/package.py | 3 + .../repos/builtin/packages/bear/package.py | 3 + .../builtin/packages/beast-tracer/package.py | 2 + .../repos/builtin/packages/beast1/package.py | 2 + .../repos/builtin/packages/beatnik/package.py | 2 + .../repos/builtin/packages/bedops/package.py | 3 + .../builtin/packages/bedtools2/package.py | 3 + .../builtin/packages/beforelight/package.py | 2 + .../builtin/packages/benchmark/package.py | 3 + .../builtin/packages/berkeley-db/package.py | 3 + .../builtin/packages/berkeleygw/package.py | 27 +- .../repos/builtin/packages/bertini/package.py | 2 + .../repos/builtin/packages/bfs/package.py | 2 + .../repos/builtin/packages/bgen/package.py | 30 + .../repos/builtin/packages/bgpdump/package.py | 2 + .../builtin/packages/bigdft-atlab/package.py | 4 + .../builtin/packages/bigdft-chess/package.py | 4 + .../builtin/packages/bigdft-core/package.py | 4 + .../builtin/packages/bigdft-futile/package.py | 4 + .../packages/bigdft-libabinit/package.py | 4 + .../packages/bigdft-psolver/package.py | 4 + .../builtin/packages/bigdft-spred/package.py | 4 + .../builtin/packages/binder/llvm_dir.patch | 12 + .../repos/builtin/packages/binder/package.py | 8 +- .../builtin/packages/binutils/gold-gcc4.patch | 12 + .../builtin/packages/binutils/package.py | 21 +- .../builtin/packages/biobambam2/package.py | 4 +- .../builtin/packages/biobloom/package.py | 3 + .../builtin/packages/biopieces/package.py | 2 + .../repos/builtin/packages/bison/package.py | 4 + .../builtin/packages/bitgroomingz/package.py | 2 + .../repos/builtin/packages/bitlbee/package.py | 2 + .../repos/builtin/packages/bitmap/package.py | 2 + .../repos/builtin/packages/bitsery/package.py | 2 + .../builtin/packages/blackhat/package.py | 3 + .../repos/builtin/packages/blake3/package.py | 23 + .../repos/builtin/packages/blaspp/package.py | 5 + .../builtin/packages/blast-legacy/package.py | 3 + .../builtin/packages/blast-plus/package.py | 3 + .../repos/builtin/packages/blat/package.py | 2 +- .../repos/builtin/packages/blaze/package.py | 4 + .../repos/builtin/packages/blis/package.py | 13 + .../repos/builtin/packages/blitz/package.py | 15 +- .../builtin/packages/blktrace/package.py | 2 + .../repos/builtin/packages/bloaty/package.py | 3 + .../builtin/packages/blogbench/package.py | 2 + .../repos/builtin/packages/blt/package.py | 53 + .../repos/builtin/packages/bmake/package.py | 2 + .../repos/builtin/packages/bmi/package.py | 2 + .../repos/builtin/packages/bml/package.py | 4 + .../repos/builtin/packages/bohrium/package.py | 10 +- .../builtin/packages/boinc-client/package.py | 3 + .../repos/builtin/packages/bolt/package.py | 3 + .../builtin/packages/bonniepp/package.py | 2 + .../builtin/packages/bookleaf-cpp/package.py | 2 + .../packages/boost/bootstrap-path.patch | 33 - .../repos/builtin/packages/boost/package.py | 31 +- .../boostmplcartesianproduct/package.py | 2 + .../repos/builtin/packages/botan/package.py | 3 + .../repos/builtin/packages/bowtie/package.py | 3 + .../repos/builtin/packages/boxlib/package.py | 4 + .../builtin/packages/bpp-core/package.py | 2 + .../packages/bpp-phyl-omics/package.py | 2 + .../builtin/packages/bpp-phyl/package.py | 2 + .../builtin/packages/bpp-popgen/package.py | 2 + .../builtin/packages/bpp-seq-omics/package.py | 2 + .../repos/builtin/packages/bpp-seq/package.py | 2 + .../builtin/packages/bpp-suite/package.py | 2 + .../repos/builtin/packages/bracken/package.py | 2 + .../repos/builtin/packages/brahma/package.py | 20 +- .../repos/builtin/packages/branson/package.py | 2 + .../builtin/packages/breakdancer/package.py | 2 + .../repos/builtin/packages/breseq/package.py | 3 + .../repos/builtin/packages/bricks/package.py | 3 + .../repos/builtin/packages/bridger/package.py | 3 + .../repos/builtin/packages/brigand/package.py | 2 + .../repos/builtin/packages/brltty/package.py | 2 + .../repos/builtin/packages/brotli/package.py | 2 + .../repos/builtin/packages/brpc/package.py | 4 + .../repos/builtin/packages/brunsli/package.py | 3 + .../repos/builtin/packages/brynet/package.py | 2 + .../repos/builtin/packages/btop/package.py | 2 + .../builtin/packages/bubblewrap/package.py | 2 + .../repos/builtin/packages/buddy/package.py | 3 + .../repos/builtin/packages/bueno/package.py | 2 + .../repos/builtin/packages/bufr/package.py | 3 + .../repos/builtin/packages/busybox/package.py | 3 + .../builtin/packages/butterflypack/package.py | 14 +- .../repos/builtin/packages/bwa/package.py | 2 + .../repos/builtin/packages/bwtool/package.py | 2 + .../repos/builtin/packages/byfl/package.py | 7 +- .../packages/byte-unixbench/package.py | 2 + .../repos/builtin/packages/bzip2/package.py | 3 +- .../repos/builtin/packages/c-ares/package.py | 4 + .../repos/builtin/packages/c-blosc/package.py | 3 + .../builtin/packages/c-blosc2/package.py | 2 + .../repos/builtin/packages/c-lime/package.py | 2 + .../repos/builtin/packages/c-raft/package.py | 2 + .../repos/builtin/packages/c3d/package.py | 3 + .../repos/builtin/packages/cabana/package.py | 2 + .../builtin/packages/cachefilesd/package.py | 2 + .../repos/builtin/packages/caffe/package.py | 2 + .../repos/builtin/packages/cairo/package.py | 8 +- .../repos/builtin/packages/cairomm/package.py | 2 + .../repos/builtin/packages/caliper/package.py | 22 +- .../builtin/packages/callpath/package.py | 2 + .../builtin/packages/camellia/package.py | 2 + .../builtin/packages/camp/camp-rocm6.patch | 15 + .../repos/builtin/packages/camp/package.py | 75 +- .../packages/candle-benchmarks/package.py | 43 - .../repos/builtin/packages/cans/package.py | 2 + .../repos/builtin/packages/cantera/package.py | 12 +- .../repos/builtin/packages/canu/package.py | 3 + .../builtin/packages/capnproto/package.py | 2 + .../builtin/packages/capstone/package.py | 6 + .../builtin/packages/cardioid/package.py | 4 + .../repos/builtin/packages/care/package.py | 54 +- .../repos/builtin/packages/cargs/package.py | 2 + .../builtin/packages/casacore/package.py | 4 + .../repos/builtin/packages/casper/package.py | 2 + .../repos/builtin/packages/castep/package.py | 95 ++ .../repos/builtin/packages/catch2/package.py | 2 + .../repos/builtin/packages/cbc/package.py | 3 + .../repos/builtin/packages/cbench/package.py | 4 + .../repos/builtin/packages/cbflib/package.py | 4 + .../repos/builtin/packages/cblas/package.py | 3 + .../packages/cbtf-argonavis-gui/package.py | 2 + .../packages/cbtf-argonavis/package.py | 3 + .../builtin/packages/cbtf-krell/package.py | 3 + .../builtin/packages/cbtf-lanl/package.py | 2 + .../repos/builtin/packages/cbtf/package.py | 2 + .../repos/builtin/packages/cc65/package.py | 2 + .../repos/builtin/packages/ccache/package.py | 7 +- .../builtin/packages/cce/detection_test.yaml | 44 + .../repos/builtin/packages/cce/package.py | 30 + .../repos/builtin/packages/ccfits/package.py | 2 + .../repos/builtin/packages/ccls/package.py | 8 + .../repos/builtin/packages/ccs-qcd/package.py | 4 + .../repos/builtin/packages/cctools/package.py | 3 + .../builtin/packages/cdbfasta/package.py | 2 + .../repos/builtin/packages/cdd/package.py | 4 +- .../repos/builtin/packages/cddlib/package.py | 2 + .../builtin/packages/cdecimal/package.py | 2 + .../repos/builtin/packages/cdhit/package.py | 2 + .../repos/builtin/packages/cdo/package.py | 4 + .../repos/builtin/packages/cdt/package.py | 3 + .../builtin/packages/celeritas/package.py | 4 + .../builtin/packages/cellranger/package.py | 38 + .../builtin/packages/centrifuge/package.py | 3 + .../repos/builtin/packages/cepgen/package.py | 3 + .../repos/builtin/packages/cereal/package.py | 2 + .../builtin/packages/ceres-solver/package.py | 3 + .../repos/builtin/packages/cernlib/package.py | 21 +- .../repos/builtin/packages/cfitsio/package.py | 6 +- .../repos/builtin/packages/cgal/package.py | 2 + .../repos/builtin/packages/cgdb/package.py | 3 + .../repos/builtin/packages/cgdcbxd/package.py | 2 + .../repos/builtin/packages/cgl/package.py | 2 + .../repos/builtin/packages/cgm/package.py | 2 + .../repos/builtin/packages/cgns/gcc14.patch | 50 + .../repos/builtin/packages/cgns/package.py | 8 + .../repos/builtin/packages/chaco/package.py | 3 + .../change_mpi_target_name_umpire_patch.patch | 13 + .../repos/builtin/packages/chai/package.py | 163 +++- .../builtin/packages/chameleon/package.py | 4 + .../repos/builtin/packages/changa/package.py | 3 + .../builtin/packages/channelflow/package.py | 2 + .../builtin/packages/chaparral/package.py | 2 + .../fix_spack_cc_wrapper_in_cray_prgenv.patch | 22 + .../repos/builtin/packages/chapel/package.py | 822 +++++++++++++++- .../repos/builtin/packages/chaplin/package.py | 2 + .../builtin/packages/charliecloud/package.py | 29 +- .../packages/charmpp/ofi-crayshasta-arm.patch | 13 + .../repos/builtin/packages/charmpp/package.py | 60 +- .../builtin/packages/chatterbug/package.py | 2 + .../repos/builtin/packages/check/package.py | 2 + .../builtin/packages/chemfiles/package.py | 3 + .../builtin/packages/chgcentre/package.py | 2 + .../repos/builtin/packages/chombo/package.py | 4 + .../repos/builtin/packages/chrony/package.py | 2 + .../repos/builtin/packages/chrpath/package.py | 2 + .../repos/builtin/packages/circe2/package.py | 2 + .../repos/builtin/packages/citcoms/package.py | 3 + .../builtin/packages/cityhash/package.py | 2 + .../repos/builtin/packages/cjson/package.py | 2 + .../repos/builtin/packages/clamav/package.py | 3 + .../repos/builtin/packages/clamr/package.py | 4 + .../repos/builtin/packages/clapack/package.py | 2 + .../repos/builtin/packages/clara/package.py | 2 + .../repos/builtin/packages/claw/package.py | 4 + .../builtin/packages/cleverleaf/package.py | 3 + .../repos/builtin/packages/clfft/package.py | 3 + .../repos/builtin/packages/clhep/package.py | 2 + .../repos/builtin/packages/cli11/package.py | 12 +- .../repos/builtin/packages/clinfo/package.py | 2 + .../packages/clingo-bootstrap/package.py | 17 +- .../repos/builtin/packages/clingo/package.py | 38 +- .../packages/clingo/setuptools-2.patch | 8 - .../repos/builtin/packages/cln/package.py | 3 + .../repos/builtin/packages/cloc/package.py | 4 + .../repos/builtin/packages/cloog/package.py | 3 + .../packages/cloverleaf-ref/package.py | 3 + .../builtin/packages/cloverleaf/package.py | 4 + .../builtin/packages/cloverleaf3d/package.py | 4 + .../repos/builtin/packages/clp/package.py | 14 +- .../builtin/packages/clustal-omega/package.py | 3 + .../builtin/packages/clustalw/package.py | 2 + .../builtin/packages/cmake/mr-9623.patch | 67 ++ .../repos/builtin/packages/cmake/package.py | 313 +----- .../repos/builtin/packages/cmaq/package.py | 3 + .../repos/builtin/packages/cmark/package.py | 4 + .../repos/builtin/packages/cmdlime/package.py | 2 + .../repos/builtin/packages/cmdstan/package.py | 4 + .../builtin/packages/cminpack/package.py | 3 + .../repos/builtin/packages/cmocka/package.py | 2 + .../builtin/packages/cmockery/package.py | 2 + .../repos/builtin/packages/cmor/package.py | 23 +- .../builtin/packages/cni-plugins/package.py | 2 + .../repos/builtin/packages/cnmem/package.py | 2 + .../repos/builtin/packages/cnpy/package.py | 2 + .../repos/builtin/packages/cntk/package.py | 2 + .../builtin/packages/cnvnator/package.py | 2 + .../builtin/packages/codar-cheetah/package.py | 2 + .../builtin/packages/code-server/package.py | 3 + .../builtin/packages/codipack/package.py | 2 + .../repos/builtin/packages/coevp/package.py | 4 + .../repos/builtin/packages/cohmm/package.py | 2 + .../repos/builtin/packages/coin3d/package.py | 3 + .../repos/builtin/packages/coinhsl/package.py | 97 +- .../builtin/packages/coinutils/package.py | 2 + .../builtin/packages/collectd/package.py | 3 + .../repos/builtin/packages/collier/package.py | 2 + .../repos/builtin/packages/colm/package.py | 3 + .../repos/builtin/packages/comd/package.py | 2 + .../repos/builtin/packages/comgr/package.py | 62 +- .../builtin/packages/commons-lang3/package.py | 3 +- .../builtin/packages/compadre/package.py | 12 +- .../repos/builtin/packages/compiz/package.py | 3 + .../packages/composable-kernel/package.py | 20 +- .../{maphyspp => composyx}/package.py | 44 +- .../repos/builtin/packages/conduit/package.py | 7 +- .../repos/builtin/packages/conmon/package.py | 3 + .../builtin/packages/conquest/package.py | 2 + .../builtin/packages/conserver/package.py | 2 + .../packages/console-bridge/package.py | 2 + .../builtin/packages/constype/package.py | 2 + .../repos/builtin/packages/cool/package.py | 2 + .../builtin/packages/coordgen/package.py | 2 + .../repos/builtin/packages/coral/package.py | 2 + .../builtin/packages/coreutils/package.py | 3 + .../repos/builtin/packages/cosign/package.py | 1 + .../repos/builtin/packages/cosma/package.py | 2 + .../repos/builtin/packages/cosmomc/package.py | 3 + .../repos/builtin/packages/cosp2/package.py | 2 + .../repos/builtin/packages/costa/package.py | 2 + .../repos/builtin/packages/cotter/package.py | 2 + .../builtin/packages/countdown/package.py | 2 + .../repos/builtin/packages/covfie/package.py | 39 + .../repos/builtin/packages/cp2k/package.py | 208 ++-- .../repos/builtin/packages/cpio/package.py | 3 + .../repos/builtin/packages/cpmd/package.py | 3 + .../builtin/packages/cpp-argparse/package.py | 2 + .../builtin/packages/cpp-httplib/package.py | 3 + .../builtin/packages/cpp-logger/package.py | 6 +- .../builtin/packages/cpp-termcolor/package.py | 2 + .../repos/builtin/packages/cppad/package.py | 40 +- .../builtin/packages/cppcheck/package.py | 3 + .../builtin/packages/cppcodec/package.py | 2 + .../repos/builtin/packages/cppcoro/package.py | 2 + .../repos/builtin/packages/cppgsl/package.py | 2 + .../builtin/packages/cpprestsdk/package.py | 3 + .../repos/builtin/packages/cppunit/package.py | 2 + .../repos/builtin/packages/cppzmq/package.py | 3 + .../repos/builtin/packages/cpr/package.py | 2 + .../repos/builtin/packages/cprnc/package.py | 2 + .../builtin/packages/cpu-features/package.py | 3 + .../repos/builtin/packages/cpuinfo/package.py | 18 +- .../repos/builtin/packages/cqrlib/package.py | 3 + .../repos/builtin/packages/cquery/package.py | 3 + .../builtin/packages/cracklib/package.py | 2 + .../repos/builtin/packages/cram/package.py | 3 + .../builtin/packages/cray-libsci/package.py | 3 + .../builtin/packages/cray-mpich/package.py | 15 +- .../builtin/packages/cray-mvapich2/package.py | 23 +- .../repos/builtin/packages/creduce/package.py | 3 + .../repos/builtin/packages/crmc/package.py | 4 + .../repos/builtin/packages/cronie/package.py | 2 + .../builtin/packages/crosstool-ng/package.py | 2 + .../builtin/packages/crtm-fix/package.py | 36 +- .../repos/builtin/packages/crtm/package.py | 62 +- .../crtm/v3.1.0-skylabv8.installprefix.patch | 14 + .../repos/builtin/packages/crunch/package.py | 2 + .../builtin/packages/cryptopp/package.py | 7 +- .../builtin/packages/cryptsetup/package.py | 2 + .../repos/builtin/packages/csa-c/package.py | 2 + .../repos/builtin/packages/cscope/package.py | 2 + .../repos/builtin/packages/csdp/package.py | 2 + .../repos/builtin/packages/ctffind/package.py | 2 + .../repos/builtin/packages/ctpl/package.py | 2 + .../repos/builtin/packages/ctre/package.py | 2 + .../repos/builtin/packages/cuba/package.py | 4 + .../builtin/packages/cube-blade/package.py | 2 + .../repos/builtin/packages/cube/package.py | 3 + .../repos/builtin/packages/cubelib/package.py | 3 + .../repos/builtin/packages/cubew/package.py | 3 + .../repos/builtin/packages/cubist/package.py | 2 + .../builtin/packages/cuda-memtest/package.py | 2 + .../repos/builtin/packages/cuda/package.py | 94 +- .../repos/builtin/packages/cudd/package.py | 3 + .../repos/builtin/packages/cudnn/package.py | 10 +- .../repos/builtin/packages/cunit/package.py | 3 + .../repos/builtin/packages/cupla/package.py | 2 + .../repos/builtin/packages/cups/package.py | 3 + .../repos/builtin/packages/curl/package.py | 208 +--- .../repos/builtin/packages/cusz/package.py | 4 + .../builtin/packages/cutensor/package.py | 8 +- .../repos/builtin/packages/cutlang/package.py | 40 - .../repos/builtin/packages/cutlass/package.py | 2 + .../repos/builtin/packages/cvector/package.py | 2 + .../repos/builtin/packages/cvise/package.py | 12 +- .../repos/builtin/packages/cvs/package.py | 3 + .../repos/builtin/packages/cxxopts/package.py | 3 + .../repos/builtin/packages/cxxtest/package.py | 3 + .../builtin/packages/cyrus-sasl/package.py | 2 + .../repos/builtin/packages/czmq/package.py | 3 + .../builtin/packages/daemonize/package.py | 2 + .../repos/builtin/packages/dakota/package.py | 4 + .../builtin/packages/daligner/package.py | 2 + .../repos/builtin/packages/dalton/package.py | 4 + .../repos/builtin/packages/damaris/package.py | 6 + .../builtin/packages/damask-grid/package.py | 3 + .../builtin/packages/damask-mesh/package.py | 3 + .../builtin/packages/damselfly/package.py | 3 + .../repos/builtin/packages/daos/package.py | 5 +- .../packages/darshan-runtime/package.py | 7 +- .../builtin/packages/darshan-util/package.py | 7 +- .../repos/builtin/packages/dash/package.py | 2 + .../builtin/packages/datamash/package.py | 2 + .../packages/datatransferkit/package.py | 6 +- .../builtin/packages/dateutils/package.py | 2 + .../repos/builtin/packages/dbcsr/package.py | 9 +- .../repos/builtin/packages/dbow2/package.py | 2 + .../builtin/packages/dbus-glib/package.py | 2 + .../repos/builtin/packages/dbus/package.py | 3 + .../repos/builtin/packages/dbxtool/package.py | 2 + .../repos/builtin/packages/dcap/package.py | 2 + .../builtin/packages/dcm2niix/package.py | 6 + .../repos/builtin/packages/dcmtk/package.py | 5 + .../builtin/packages/dcmtk/tiff-3.6.7.patch | 12 + .../repos/builtin/packages/dctz/package.py | 39 + .../repos/builtin/packages/dd4hep/package.py | 75 +- .../packages/dd4hep/tbb-workarounds.patch | 41 - .../repos/builtin/packages/dd4hep/tbb2.patch | 14 - .../packages/dealii-parameter-gui/package.py | 2 + .../repos/builtin/packages/dealii/package.py | 10 +- .../builtin/packages/debugedit/package.py | 2 + .../decentralized-internet/package.py | 2 + .../packages/deconseq-standalone/package.py | 2 + .../repos/builtin/packages/dedisp/package.py | 45 + .../repos/builtin/packages/dejagnu/package.py | 3 + .../repos/builtin/packages/delly2/package.py | 2 + .../repos/builtin/packages/delphes/package.py | 3 + .../builtin/packages/demuxlet/package.py | 2 + .../builtin/packages/denovogear/package.py | 3 + .../repos/builtin/packages/detray/package.py | 83 ++ .../repos/builtin/packages/dfelibs/package.py | 33 + .../builtin/packages/dftbplus/package.py | 5 + .../builtin/packages/dftd3-lib/package.py | 3 + .../repos/builtin/packages/dftd4/package.py | 3 + .../repos/builtin/packages/dftfe/package.py | 2 + .../repos/builtin/packages/dhtest/package.py | 2 + .../repos/builtin/packages/dia/package.py | 3 + .../repos/builtin/packages/dialign/package.py | 2 + .../repos/builtin/packages/diamond/package.py | 5 + .../builtin/packages/dicom3tools/package.py | 2 + .../builtin/packages/diffmark/package.py | 2 + .../builtin/packages/diffsplice/package.py | 2 + .../builtin/packages/diffutils/package.py | 2 + .../builtin/packages/digitrounding/package.py | 2 + .../builtin/packages/dihydrogen/package.py | 9 +- .../repos/builtin/packages/dimemas/package.py | 3 + .../builtin/packages/ding-libs/package.py | 2 + .../repos/builtin/packages/dire/package.py | 2 + .../builtin/packages/discotec/package.py | 2 + .../builtin/packages/discovar/package.py | 2 + .../packages/discovardenovo/package.py | 2 + .../builtin/packages/disktype/package.py | 2 + .../builtin/packages/distbench/package.py | 2 + .../repos/builtin/packages/distcc/package.py | 3 + .../repos/builtin/packages/diy/package.py | 2 + .../packages/dla-future-fortran/package.py | 52 + .../builtin/packages/dla-future/package.py | 33 +- .../repos/builtin/packages/dlb/package.py | 3 + .../repos/builtin/packages/dlib/package.py | 66 +- .../repos/builtin/packages/dlpack/package.py | 3 + .../repos/builtin/packages/dmd/package.py | 3 + .../builtin/packages/dmidecode/package.py | 2 + .../builtin/packages/dmlc-core/package.py | 2 + .../repos/builtin/packages/dmtcp/package.py | 3 + .../repos/builtin/packages/dnsmap/package.py | 2 + .../repos/builtin/packages/dnsmasq/package.py | 3 + .../repos/builtin/packages/dnstop/package.py | 2 + .../builtin/packages/dnstracer/package.py | 2 + .../builtin/packages/docbook-xml/package.py | 117 ++- .../repos/builtin/packages/dorado/package.py | 7 + .../builtin/packages/dorian3d-dlib/package.py | 2 + .../builtin/packages/dos2unix/package.py | 2 + .../builtin/packages/dosfstools/package.py | 2 + .../repos/builtin/packages/dotconf/package.py | 2 + .../packages/dotnet-core-sdk/package.py | 34 +- .../double-batched-fft-library/package.py | 9 +- .../repos/builtin/packages/doxygen/package.py | 30 +- .../repos/builtin/packages/dpcpp/package.py | 166 ---- .../repos/builtin/packages/dpdk/package.py | 3 + .../repos/builtin/packages/draco/package.py | 1 + .../repos/builtin/packages/dracut/package.py | 2 + .../builtin/packages/dramsim2/package.py | 2 + .../builtin/packages/dramsim3/package.py | 3 + .../repos/builtin/packages/dray/package.py | 40 +- .../repos/builtin/packages/drishti/package.py | 2 + .../builtin/packages/dropwatch/package.py | 2 + .../repos/builtin/packages/dsdp/package.py | 2 + .../repos/builtin/packages/dsfmt/package.py | 3 + .../repos/builtin/packages/dsqss/package.py | 3 +- .../repos/builtin/packages/dsrc/package.py | 2 + .../repos/builtin/packages/dssp/package.py | 2 + .../repos/builtin/packages/dtc/package.py | 2 + .../repos/builtin/packages/dtcmp/package.py | 2 + .../repos/builtin/packages/dtf/package.py | 4 + .../repos/builtin/packages/duckdb/package.py | 21 +- .../builtin/packages/duperemove/package.py | 2 + .../repos/builtin/packages/dwz/package.py | 3 + .../repos/builtin/packages/dyninst/package.py | 5 +- .../repos/builtin/packages/dysco/package.py | 2 + .../builtin/packages/e2fsprogs/package.py | 29 +- .../builtin/packages/e3sm-kernels/package.py | 2 + .../builtin/packages/e3sm-scorpio/package.py | 4 + .../repos/builtin/packages/e4s-alc/package.py | 29 + .../repos/builtin/packages/e4s-cl/package.py | 1 + .../builtin/packages/ea-utils/package.py | 3 + .../repos/builtin/packages/eagle/package.py | 2 + .../builtin/packages/earlyoom/package.py | 3 + .../repos/builtin/packages/easi/package.py | 25 +- .../builtin/packages/easyloggingpp/package.py | 2 + .../repos/builtin/packages/ebms/package.py | 2 + .../repos/builtin/packages/ecbuild/package.py | 4 + .../repos/builtin/packages/eccodes/package.py | 4 + .../builtin/packages/ecdsautils/package.py | 2 + .../repos/builtin/packages/ecflow/package.py | 7 +- .../repos/builtin/packages/eckit/package.py | 3 + .../builtin/packages/ecmwf-atlas/package.py | 4 + .../repos/builtin/packages/ecos/package.py | 2 + .../repos/builtin/packages/ecoslim/package.py | 2 + .../packages/ecp-proxy-apps/package.py | 2 - .../repos/builtin/packages/ectrans/package.py | 3 + .../repos/builtin/packages/ed/package.py | 2 + .../builtin/packages/editline/package.py | 2 + .../builtin/packages/editorconfig/package.py | 24 + .../repos/builtin/packages/editres/package.py | 2 + .../repos/builtin/packages/edm4hep/package.py | 83 +- .../builtin/packages/edm4hep/test-deps.patch | 12 - .../repos/builtin/packages/eem/package.py | 2 + .../repos/builtin/packages/efivar/package.py | 2 + .../repos/builtin/packages/eigen/package.py | 4 + .../builtin/packages/eigenexa/package.py | 3 + .../builtin/packages/elbencho/package.py | 5 +- .../builtin/packages/elemental/package.py | 3 + .../repos/builtin/packages/elfio/package.py | 3 + .../builtin/packages/elfutils/package.py | 10 +- .../repos/builtin/packages/elk/package.py | 3 + .../builtin/packages/elmerfem/package.py | 4 + .../repos/builtin/packages/elpa/package.py | 71 +- .../repos/builtin/packages/elsd/package.py | 2 + .../repos/builtin/packages/elsdc/package.py | 2 + .../repos/builtin/packages/elsi/package.py | 126 ++- .../repos/builtin/packages/emacs/package.py | 24 +- .../repos/builtin/packages/ember/package.py | 2 + .../repos/builtin/packages/emboss/package.py | 2 + .../repos/builtin/packages/embree/package.py | 3 + .../repos/builtin/packages/enca/package.py | 2 + .../repos/builtin/packages/enchant/package.py | 3 + .../builtin/packages/energyplus/package.py | 3 + .../builtin/packages/ensmallen/package.py | 2 + .../repos/builtin/packages/entt/package.py | 5 +- .../packages/environment-modules/package.py | 2 + .../repos/builtin/packages/enzo/package.py | 4 + .../repos/builtin/packages/enzyme/package.py | 5 + .../repos/builtin/packages/eospac/package.py | 16 +- .../builtin/packages/epics-base/package.py | 3 + .../packages/epics-ca-gateway/package.py | 2 + .../builtin/packages/epics-pcas/package.py | 3 + .../packages/eprosima-fastcdr/package.py | 3 + .../packages/eprosima-fastdds/package.py | 3 + .../repos/builtin/packages/epsic/package.py | 2 + .../repos/builtin/packages/eq-r/package.py | 2 + .../repos/builtin/packages/er/package.py | 5 +- .../repos/builtin/packages/erfa/package.py | 2 + .../repos/builtin/packages/erlang/package.py | 2 + .../repos/builtin/packages/erne/package.py | 3 + .../builtin/packages/es-shell/package.py | 2 + .../repos/builtin/packages/esmf/package.py | 8 +- .../builtin/packages/esys-particle/package.py | 2 + .../builtin/packages/ethminer/package.py | 3 + .../repos/builtin/packages/ethtool/package.py | 2 + .../repos/builtin/packages/etsf-io/package.py | 2 + .../repos/builtin/packages/eve/package.py | 2 + .../packages/everytrace-example/package.py | 2 + .../builtin/packages/everytrace/package.py | 4 + .../repos/builtin/packages/evtgen/package.py | 2 + .../builtin/packages/exabayes/package.py | 3 + .../repos/builtin/packages/exaca/package.py | 2 + .../repos/builtin/packages/exago/package.py | 6 +- .../repos/builtin/packages/examl/package.py | 2 + .../repos/builtin/packages/exampm/package.py | 2 + .../repos/builtin/packages/exasp2/package.py | 2 + .../repos/builtin/packages/exawind/package.py | 119 ++- .../builtin/packages/exciting/package.py | 4 + .../repos/builtin/packages/exempi/package.py | 2 + .../repos/builtin/packages/exiv2/package.py | 2 + .../builtin/packages/exmcutils/package.py | 2 + .../packages/exodusii/Fix-ioss-tpl.patch | 25 + .../builtin/packages/exodusii/package.py | 205 ++-- .../packages/exonerate-gff3/package.py | 2 + .../builtin/packages/exonerate/package.py | 2 + .../repos/builtin/packages/expat/package.py | 3 + .../repos/builtin/packages/expect/package.py | 2 + .../repos/builtin/packages/extrae/package.py | 5 + .../packages/exuberant-ctags/package.py | 2 + .../repos/builtin/packages/eztrace/package.py | 151 +-- .../repos/builtin/packages/f2c/package.py | 2 + .../repos/builtin/packages/f3d/package.py | 2 + .../repos/builtin/packages/f77-zmq/package.py | 3 + .../builtin/packages/f90cache/package.py | 2 + .../builtin/packages/fabtests/package.py | 10 + .../builtin/packages/fabulous/package.py | 4 + .../builtin/packages/fairlogger/package.py | 2 + .../repos/builtin/packages/fairmq/package.py | 2 + .../repos/builtin/packages/faiss/package.py | 3 + .../builtin/packages/fakechroot/package.py | 2 + .../builtin/packages/fakexrandr/package.py | 2 + .../repos/builtin/packages/falco/package.py | 2 + .../repos/builtin/packages/falcon/package.py | 2 + .../repos/builtin/packages/fann/package.py | 3 + .../repos/builtin/packages/faodel/package.py | 3 + .../builtin/packages/fargparse/package.py | 2 + .../fast-global-file-status/package.py | 3 + .../repos/builtin/packages/fasta/package.py | 2 + .../repos/builtin/packages/fastani/package.py | 2 + .../repos/builtin/packages/fastdb/package.py | 3 + .../repos/builtin/packages/fastdfs/package.py | 2 + .../repos/builtin/packages/fastjar/package.py | 2 + .../repos/builtin/packages/fastjet/package.py | 54 +- .../repos/builtin/packages/fastor/package.py | 27 + .../repos/builtin/packages/fastp/package.py | 2 + .../packages/fastqvalidator/package.py | 2 + .../builtin/packages/fasttext/package.py | 2 + .../packages/fasttransforms/package.py | 2 + .../builtin/packages/fastx-toolkit/package.py | 3 + .../repos/builtin/packages/faust/package.py | 4 + .../repos/builtin/packages/fbgemm/package.py | 3 + .../repos/builtin/packages/fcgi/package.py | 3 + .../repos/builtin/packages/fckit/package.py | 10 +- .../repos/builtin/packages/fd/package.py | 1 + .../repos/builtin/packages/fdb/package.py | 3 + .../repos/builtin/packages/fds/package.py | 2 + .../repos/builtin/packages/fdupes/package.py | 2 + .../repos/builtin/packages/feh/package.py | 2 + .../builtin/packages/fenics-basix/package.py | 26 +- .../packages/fenics-dolfinx/package.py | 61 +- .../builtin/packages/fenics-ufcx/package.py | 18 +- .../repos/builtin/packages/fenics/package.py | 9 +- .../builtin/packages/feq-parse/package.py | 9 +- .../builtin/packages/fermikit/package.py | 2 + .../packages/fermisciencetools/package.py | 4 + .../repos/builtin/packages/ferret/package.py | 3 + .../builtin/packages/feynhiggs/package.py | 4 + .../repos/builtin/packages/ffmpeg/package.py | 41 +- .../repos/builtin/packages/ffsb/package.py | 2 + .../repos/builtin/packages/ffte/package.py | 2 + .../repos/builtin/packages/fftw/package.py | 8 +- .../builtin/packages/fftw/pfft-3.3.9.patch | 15 + .../repos/builtin/packages/fftx/package.py | 2 + .../repos/builtin/packages/fgsl/package.py | 3 + .../repos/builtin/packages/fiat/package.py | 4 + .../repos/builtin/packages/fides/package.py | 2 + .../repos/builtin/packages/figcone/package.py | 2 + .../repos/builtin/packages/figlet/package.py | 2 + .../repos/builtin/packages/file/package.py | 3 + .../builtin/packages/filebench/package.py | 3 + .../repos/builtin/packages/filo/package.py | 4 +- .../builtin/packages/filtlong/package.py | 2 + .../builtin/packages/findutils/package.py | 2 + .../repos/builtin/packages/fio/package.py | 6 +- .../builtin/packages/fipscheck/package.py | 2 + .../repos/builtin/packages/fish/package.py | 7 + .../builtin/packages/fj/detection_test.yaml | 27 + .../repos/builtin/packages/fj/package.py | 40 +- .../builtin/packages/fjcontrib/package.py | 2 + .../repos/builtin/packages/flac/package.py | 7 + .../repos/builtin/packages/flann/package.py | 3 + .../repos/builtin/packages/flap/package.py | 2 + .../repos/builtin/packages/flash/package.py | 2 + .../builtin/packages/flashdimmsim/package.py | 2 + .../builtin/packages/flatbuffers/package.py | 3 + .../repos/builtin/packages/flatcc/package.py | 6 +- .../repos/builtin/packages/flcl/package.py | 3 + .../builtin/packages/flecsale/package.py | 45 - .../repos/builtin/packages/flecsi/package.py | 154 +-- .../repos/builtin/packages/flecsph/package.py | 2 + .../repos/builtin/packages/fleur/package.py | 4 + .../repos/builtin/packages/flex/package.py | 3 + .../repos/builtin/packages/flexi/package.py | 4 + .../builtin/packages/flexiblas/package.py | 4 + .../repos/builtin/packages/flibcpp/package.py | 3 + .../repos/builtin/packages/flint/package.py | 42 +- .../repos/builtin/packages/flit/package.py | 2 + .../repos/builtin/packages/fltk/package.py | 3 + .../builtin/packages/flux-core/package.py | 88 +- .../builtin/packages/flux-pmix/package.py | 2 + .../builtin/packages/flux-sched/package.py | 40 +- .../builtin/packages/flux-security/package.py | 4 +- .../repos/builtin/packages/fluxbox/package.py | 2 + .../repos/builtin/packages/fms/package.py | 24 +- .../fmt-no-variable-initialize_10.0.0.patch | 22 + .../repos/builtin/packages/fmt/package.py | 13 + .../builtin/packages/foam-extend/package.py | 4 + .../builtin/packages/foldseek/package.py | 3 + .../repos/builtin/packages/folly/package.py | 3 + .../builtin/packages/font-util/package.py | 10 +- .../builtin/packages/fontconfig/package.py | 35 +- .../builtin/packages/fonttosfnt/package.py | 2 + .../packages/foonathan-memory/package.py | 2 + .../repos/builtin/packages/form/package.py | 3 + .../builtin/packages/formetis/package.py | 3 + .../builtin/packages/fortrilinos/package.py | 3 + .../repos/builtin/packages/fossil/package.py | 3 + .../builtin/packages/foundationdb/package.py | 3 + .../repos/builtin/packages/fox/package.py | 6 +- .../repos/builtin/packages/fp16/package.py | 2 + .../repos/builtin/packages/fpart/package.py | 2 + .../builtin/packages/fpchecker/package.py | 4 + .../repos/builtin/packages/fping/package.py | 2 + .../repos/builtin/packages/fplll/package.py | 2 + .../repos/builtin/packages/fpocket/package.py | 6 +- .../repos/builtin/packages/fpzip/package.py | 3 + .../repos/builtin/packages/fqtrim/package.py | 2 + .../builtin/packages/fraggenescan/package.py | 2 + .../builtin/packages/freebayes/package.py | 3 + .../repos/builtin/packages/freecad/package.py | 4 + .../repos/builtin/packages/freefem/package.py | 4 + .../builtin/packages/freeglut/package.py | 9 +- .../builtin/packages/freeipmi/package.py | 2 + .../builtin/packages/freetype/package.py | 22 +- .../repos/builtin/packages/freexl/package.py | 2 + .../repos/builtin/packages/fribidi/package.py | 2 + .../packages/frontier-client/package.py | 3 + .../builtin/packages/frontistr/package.py | 4 + .../builtin/packages/fslsfonts/package.py | 2 + .../repos/builtin/packages/fstobdf/package.py | 2 + .../repos/builtin/packages/fstrack/package.py | 3 + .../repos/builtin/packages/ftgl/package.py | 3 + .../repos/builtin/packages/ftjam/package.py | 2 + .../repos/builtin/packages/ftk/package.py | 3 + .../packages/ftobjectlibrary/package.py | 2 + .../repos/builtin/packages/ftxui/package.py | 3 + .../builtin/packages/fujitsu-fftw/package.py | 3 + .../packages/fujitsu-frontistr/package.py | 4 + .../builtin/packages/fujitsu-mpi/package.py | 16 + .../repos/builtin/packages/fullock/package.py | 2 + .../repos/builtin/packages/funhpc/package.py | 2 + .../repos/builtin/packages/funwave/package.py | 2 + .../packages/fuse-overlayfs/package.py | 4 + .../repos/builtin/packages/fxdiv/package.py | 2 + .../repos/builtin/packages/fxt/package.py | 2 + .../repos/builtin/packages/fyba/package.py | 2 + .../repos/builtin/packages/g2/package.py | 4 + .../repos/builtin/packages/g2c/package.py | 3 + .../repos/builtin/packages/g2o/package.py | 3 + .../repos/builtin/packages/g2tmpl/package.py | 18 + .../repos/builtin/packages/g4emlow/package.py | 3 + .../repos/builtin/packages/g4ndl/package.py | 1 + .../builtin/packages/g4nudexlib/package.py | 35 + .../builtin/packages/g4particlexs/package.py | 1 + .../repos/builtin/packages/g4urrpt/package.py | 35 + .../repos/builtin/packages/gadap/package.py | 2 + .../packages/gamess-ri-mp2-miniapp/package.py | 2 + .../repos/builtin/packages/gapbs/package.py | 2 + .../builtin/packages/garfieldpp/package.py | 4 + .../repos/builtin/packages/gasnet/package.py | 27 +- .../builtin/packages/gatb-core/package.py | 3 + .../repos/builtin/packages/gate/package.py | 3 + .../builtin/packages/gatepet2stir/package.py | 2 + .../repos/builtin/packages/gaudi/package.py | 14 +- .../builtin/packages/gaussian-src/package.py | 2 +- .../builtin/packages/gaussian-view/package.py | 2 +- .../repos/builtin/packages/gawk/package.py | 2 + .../repos/builtin/packages/gbl/package.py | 3 + .../builtin/packages/gcc-runtime/package.py | 98 +- .../builtin/packages/gcc/detection_test.yaml | 132 ++- .../repos/builtin/packages/gcc/package.py | 306 +++--- .../repos/builtin/packages/gccxml/package.py | 3 + .../repos/builtin/packages/gchp/package.py | 4 + .../repos/builtin/packages/gconf/package.py | 2 + .../repos/builtin/packages/gcta/package.py | 3 + .../repos/builtin/packages/gdal/package.py | 124 ++- .../repos/builtin/packages/gdb/package.py | 6 + .../repos/builtin/packages/gdbm/package.py | 2 + .../builtin/packages/gdk-pixbuf/package.py | 5 +- .../repos/builtin/packages/gdl/package.py | 4 + .../repos/builtin/packages/gdrcopy/package.py | 3 + .../repos/builtin/packages/geant3/package.py | 4 + .../builtin/packages/geant4-data/package.py | 34 +- .../builtin/packages/geant4-vmc/package.py | 2 + .../repos/builtin/packages/geant4/package.py | 34 +- .../builtin/packages/gearshifft/package.py | 2 + .../builtin/packages/gegelati/package.py | 3 + .../repos/builtin/packages/gegl/package.py | 3 + .../repos/builtin/packages/gemma/package.py | 2 + .../builtin/packages/gemmlowp/package.py | 2 + .../packages/generate-ninja/package.py | 50 + .../repos/builtin/packages/generax/package.py | 3 + .../repos/builtin/packages/genesis/package.py | 3 + .../repos/builtin/packages/genfit/package.py | 2 + .../repos/builtin/packages/gengeo/package.py | 2 + .../builtin/packages/gengetopt/package.py | 3 + .../repos/builtin/packages/genie/package.py | 2 + .../builtin/packages/genometools/package.py | 6 +- .../builtin/packages/genomeworks/package.py | 3 + .../repos/builtin/packages/genrich/package.py | 2 + .../builtin/packages/geoip-api-c/package.py | 2 + .../repos/builtin/packages/geoip/package.py | 2 + .../builtin/packages/geomodel/package.py | 77 ++ .../builtin/packages/geopm-runtime/package.py | 167 ++++ .../builtin/packages/geopm-service/package.py | 93 +- .../repos/builtin/packages/geopm/package.py | 142 --- .../repos/builtin/packages/geos/package.py | 8 +- .../repos/builtin/packages/gettext/package.py | 42 +- .../repos/builtin/packages/gexiv2/package.py | 3 + .../builtin/packages/gffcompare/package.py | 2 + .../repos/builtin/packages/gffread/package.py | 2 + .../repos/builtin/packages/gflags/package.py | 2 + .../repos/builtin/packages/gfsio/package.py | 2 + .../builtin/packages/gftl-shared/package.py | 2 + .../repos/builtin/packages/gftl/package.py | 3 + .../repos/builtin/packages/gh/package.py | 21 +- .../repos/builtin/packages/ghost/package.py | 3 + .../builtin/packages/ghostscript/package.py | 3 + .../repos/builtin/packages/giflib/package.py | 6 + .../repos/builtin/packages/gimp/package.py | 3 + .../ginkgo/1.4.0_dpcpp_use_old_standard.patch | 70 -- ...nkgo-dpcpp-intrinsincs-oneapi-2024.1.patch | 19 + .../repos/builtin/packages/ginkgo/package.py | 15 +- .../builtin/packages/git-annex/package.py | 2 +- .../repos/builtin/packages/git-lfs/package.py | 6 + .../repos/builtin/packages/git/package.py | 177 ++-- .../builtin/packages/gitconddb/package.py | 2 + .../repos/builtin/packages/gl2ps/package.py | 2 + .../repos/builtin/packages/glew/package.py | 41 +- .../builtin/packages/glfmultiples/package.py | 2 + .../repos/builtin/packages/glfw/package.py | 2 + .../packages/glib-networking/package.py | 2 + .../repos/builtin/packages/glib/package.py | 15 +- .../repos/builtin/packages/glibc/package.py | 22 + .../repos/builtin/packages/glibmm/package.py | 2 + .../repos/builtin/packages/glimmer/package.py | 2 + .../repos/builtin/packages/glm/package.py | 4 + .../builtin/packages/globalarrays/package.py | 7 + .../repos/builtin/packages/glog/package.py | 38 +- .../repos/builtin/packages/gloo/package.py | 5 +- .../repos/builtin/packages/glpk/package.py | 3 + .../repos/builtin/packages/gluegen/package.py | 2 + .../builtin/packages/glusterfs/package.py | 2 + .../repos/builtin/packages/glvis/package.py | 6 + .../repos/builtin/packages/gmake/package.py | 24 +- .../builtin/packages/gmap-gsnap/package.py | 2 + .../repos/builtin/packages/gmime/package.py | 2 + .../repos/builtin/packages/gmodel/package.py | 2 + .../repos/builtin/packages/gmp/package.py | 5 + .../repos/builtin/packages/gmsh/package.py | 29 +- .../repos/builtin/packages/gmt/package.py | 3 + .../repos/builtin/packages/gmtsar/package.py | 2 + .../repos/builtin/packages/gnds/package.py | 2 + .../repos/builtin/packages/gnina/package.py | 2 + .../repos/builtin/packages/gnupg/package.py | 16 +- .../repos/builtin/packages/gnuplot/package.py | 3 + .../builtin/packages/gnuradio/package.py | 6 + .../repos/builtin/packages/gnutls/package.py | 3 + .../builtin/packages/go-bootstrap/package.py | 2 - .../builtin/packages/go-md2man/package.py | 1 + .../repos/builtin/packages/go/package.py | 64 +- .../packages/gobject-introspection/package.py | 18 +- .../gobject-introspection/sbang-1.60.2.patch | 11 + .../builtin/packages/gocryptfs/package.py | 26 + .../repos/builtin/packages/goma/package.py | 5 + .../packages/google-cloud-cli/package.py | 4 +- .../builtin/packages/google-crc32c/package.py | 3 + .../builtin/packages/googletest/package.py | 4 +- .../builtin/packages/gosam-contrib/package.py | 11 + .../repos/builtin/packages/gotcha/package.py | 5 + .../repos/builtin/packages/gource/package.py | 2 + .../repos/builtin/packages/gpcnet/package.py | 2 + .../repos/builtin/packages/gperf/package.py | 3 + .../builtin/packages/gperftools/package.py | 49 +- .../repos/builtin/packages/gpgme/package.py | 3 + .../repos/builtin/packages/gpi-2/package.py | 4 + .../builtin/packages/gpi-space/package.py | 3 + .../builtin/packages/gprofng-gui/package.py | 29 + .../repos/builtin/packages/gprolog/package.py | 2 + .../repos/builtin/packages/gptl/package.py | 3 + .../repos/builtin/packages/gptune/package.py | 4 + .../builtin/packages/gpu-burn/package.py | 2 + .../builtin/packages/gpuscout/package.py | 2 + .../repos/builtin/packages/gqrx/package.py | 3 + .../builtin/packages/gr-osmosdr/package.py | 2 + .../repos/builtin/packages/grabix/package.py | 3 + .../repos/builtin/packages/grace/package.py | 3 + .../repos/builtin/packages/grads/package.py | 10 +- .../repos/builtin/packages/grafana/package.py | 2 + .../repos/builtin/packages/grandr/package.py | 2 + .../builtin/packages/graph500/package.py | 2 + .../builtin/packages/graphblast/package.py | 2 + .../packages/graphicsmagick/package.py | 4 + .../builtin/packages/graphite2/package.py | 3 + .../builtin/packages/graphlib/package.py | 2 + .../builtin/packages/graphmap/package.py | 2 + .../builtin/packages/graphviz/package.py | 3 + .../repos/builtin/packages/grass/package.py | 3 + .../repos/builtin/packages/grep/package.py | 2 + .../builtin/packages/grib-util/package.py | 15 +- .../repos/builtin/packages/grid/package.py | 2 + .../builtin/packages/gridlab-d/package.py | 3 + .../repos/builtin/packages/groff/package.py | 11 +- .../repos/builtin/packages/gromacs/package.py | 24 +- .../repos/builtin/packages/grpc/package.py | 19 +- .../gsettings-desktop-schemas/package.py | 2 + .../builtin/packages/gsi-ncdiag/package.py | 2 + .../repos/builtin/packages/gsibec/package.py | 5 +- .../builtin/packages/gsl-lite/package.py | 2 + .../repos/builtin/packages/gsl/package.py | 2 + .../repos/builtin/packages/gslib/package.py | 3 + .../repos/builtin/packages/gtfsort/package.py | 17 + .../repos/builtin/packages/gtk-doc/package.py | 2 + .../repos/builtin/packages/gtkmm/package.py | 2 + .../builtin/packages/gtkorvo-atl/package.py | 6 +- .../packages/gtkorvo-cercs-env/package.py | 2 + .../builtin/packages/gtkorvo-dill/package.py | 3 + .../builtin/packages/gtkorvo-enet/package.py | 2 + .../repos/builtin/packages/gtkplus/package.py | 3 + .../builtin/packages/gtksourceview/package.py | 4 + .../repos/builtin/packages/gts/package.py | 2 + .../packages/guacamole-server/package.py | 2 + .../repos/builtin/packages/guile/package.py | 2 + .../repos/builtin/packages/gunrock/package.py | 3 + .../repos/builtin/packages/gurobi/package.py | 1 - .../repos/builtin/packages/gxsview/package.py | 26 +- .../repos/builtin/packages/gzip/package.py | 2 + .../repos/builtin/packages/h5bench/package.py | 4 + .../repos/builtin/packages/h5cpp/package.py | 3 + .../repos/builtin/packages/h5hut/package.py | 4 + .../repos/builtin/packages/h5utils/package.py | 3 + .../repos/builtin/packages/h5z-zfp/package.py | 3 + .../builtin/packages/haccabana/package.py | 2 + .../builtin/packages/hacckernels/package.py | 2 + .../builtin/packages/hackrf-host/package.py | 2 + .../builtin/packages/hadoop-xrootd/package.py | 2 + .../repos/builtin/packages/hadoop/package.py | 2 + .../repos/builtin/packages/hal/package.py | 3 + .../repos/builtin/packages/halide/package.py | 12 +- .../repos/builtin/packages/hapcut2/package.py | 2 + .../repos/builtin/packages/haproxy/package.py | 3 + .../builtin/packages/hardlink/package.py | 2 + .../builtin/packages/harfbuzz/package.py | 9 +- .../repos/builtin/packages/harminv/package.py | 2 + .../repos/builtin/packages/hashcat/package.py | 3 + .../repos/builtin/packages/haveged/package.py | 2 + .../builtin/packages/hazelcast/package.py | 2 + .../builtin/packages/hbm-dramsim2/package.py | 2 + .../builtin/packages/hdf-eos2/package.py | 10 +- .../repos/builtin/packages/hdf/package.py | 16 +- .../builtin/packages/hdf5-blosc/package.py | 2 + .../builtin/packages/hdf5-vfd-gds/package.py | 2 + .../packages/hdf5-vol-async/package.py | 2 + .../packages/hdf5-vol-cache/package.py | 3 + .../builtin/packages/hdf5-vol-daos/package.py | 3 + .../hdf5-vol-external-passthrough/package.py | 2 + .../builtin/packages/hdf5-vol-log/package.py | 3 + .../packages/hdf5/hdf5_1_14_3_fpe.patch | 203 ++++ .../repos/builtin/packages/hdf5/package.py | 48 +- .../builtin/packages/heaptrack/package.py | 3 + .../repos/builtin/packages/heasoft/package.py | 4 + .../repos/builtin/packages/heffte/package.py | 4 + .../builtin/packages/heimdall/package.py | 49 + .../repos/builtin/packages/helib/package.py | 3 + .../repos/builtin/packages/helics/package.py | 6 + .../builtin/packages/help2man/package.py | 2 + .../repos/builtin/packages/henson/package.py | 3 + .../repos/builtin/packages/hepmc/package.py | 3 + .../repos/builtin/packages/hepmc3/package.py | 16 +- .../builtin/packages/hepmcanalysis/package.py | 3 + .../repos/builtin/packages/heppdt/package.py | 3 + .../repos/builtin/packages/hermes/package.py | 3 + .../repos/builtin/packages/herwig3/package.py | 4 + .../builtin/packages/herwigpp/package.py | 4 + .../repos/builtin/packages/hevea/package.py | 2 + .../repos/builtin/packages/heyoka/package.py | 10 +- .../builtin/packages/hh-suite/package.py | 3 + .../repos/builtin/packages/hicops/package.py | 2 + .../builtin/packages/highfive/package.py | 2 + .../repos/builtin/packages/highway/package.py | 7 +- .../builtin/packages/highwayhash/package.py | 2 + .../repos/builtin/packages/hiop/package.py | 84 +- .../builtin/packages/hip-examples/package.py | 4 + .../builtin/packages/hip-rocclr/package.py | 32 +- .../builtin/packages/hip-tensor/package.py | 21 +- ...e-compiler-rt-linkage-for-host.5.0.2.patch | 78 -- ...e-compiler-rt-linkage-for-host.5.2.0.patch | 78 -- ...e-compiler-rt-linkage-for-host.5.2.1.patch | 71 -- ...ove-compiler-rt-linkage-for-host.6.0.patch | 31 - ...ove-compiler-rt-linkage-for-host.6.1.patch | 21 + .../repos/builtin/packages/hip/package.py | 155 +-- .../repos/builtin/packages/hipace/package.py | 2 + .../repos/builtin/packages/hipblas/package.py | 55 +- ...Add-Hiblas-Include-to-CmakeLists-6.1.Patch | 88 ++ .../001_Set_LLVM_Paths_And_Add_Includes.patch | 70 ++ .../builtin/packages/hipblaslt/package.py | 72 ++ ...ove-compiler-rt-linkage-for-host.6.0.patch | 30 + ...ove-compiler-rt-linkage-for-host.6.1.patch | 30 + .../repos/builtin/packages/hipcc/package.py | 65 ++ .../hipcub/find-hip-cuda-rocm-5.1.patch | 13 - .../repos/builtin/packages/hipcub/package.py | 43 +- .../repos/builtin/packages/hipfft/package.py | 37 +- .../repos/builtin/packages/hipfort/package.py | 32 +- ...lang-in-bin-dir-and-llvm-clangs-head.patch | 22 + .../builtin/packages/hipify-clang/package.py | 49 +- .../repos/builtin/packages/hiprand/package.py | 32 +- ...0001-suite-sparse-include-path-6.1.1.patch | 38 + .../001-suite-sparse-include-path.patch | 38 + .../builtin/packages/hipsolver/package.py | 50 +- .../builtin/packages/hipsparse/package.py | 42 +- ...-hipsparse-include-dir-for-spack-6.1.patch | 77 ++ ...-add-hipsparse-include-dir-for-spack.patch | 92 ++ .../builtin/packages/hipsparselt/package.py | 86 ++ .../repos/builtin/packages/hipsycl/package.py | 2 + .../repos/builtin/packages/hiptt/package.py | 2 + .../repos/builtin/packages/hiredis/package.py | 3 + .../repos/builtin/packages/hisat2/package.py | 23 +- .../repos/builtin/packages/hisea/package.py | 2 + .../repos/builtin/packages/hivex/package.py | 2 + .../repos/builtin/packages/hmmer/package.py | 2 + .../builtin/packages/hohqmesh/package.py | 7 + .../builtin/packages/hoomd-blue/package.py | 3 + .../repos/builtin/packages/hoppet/package.py | 3 + .../repos/builtin/packages/hotspot/package.py | 2 + .../repos/builtin/packages/hpcc/package.py | 16 +- .../repos/builtin/packages/hpccg/package.py | 2 + .../repos/builtin/packages/hpcg/package.py | 8 + .../correcting-hsa-include-path.patch | 13 + .../builtin/packages/hpctoolkit/package.py | 40 +- .../builtin/packages/hpcviewer/package.py | 107 +- .../repos/builtin/packages/hpddm/package.py | 4 + .../repos/builtin/packages/hpgmg/package.py | 2 + .../repos/builtin/packages/hping/package.py | 2 + .../repos/builtin/packages/hpl/package.py | 23 +- .../builtin/packages/hpx-kokkos/package.py | 2 + .../repos/builtin/packages/hpx/package.py | 25 +- .../repos/builtin/packages/hpx5/package.py | 3 + .../builtin/packages/hsa-rocr-dev/package.py | 50 +- ...support-libraries-and-libudev-as-req.patch | 34 - .../builtin/packages/hsakmt-roct/package.py | 43 +- .../repos/builtin/packages/hsakmt/package.py | 2 + .../repos/builtin/packages/hssp/package.py | 2 + .../repos/builtin/packages/hstr/package.py | 2 + .../repos/builtin/packages/htop/package.py | 3 + .../repos/builtin/packages/htslib/package.py | 23 +- .../builtin/packages/http-get/package.py | 2 + .../builtin/packages/http-load/package.py | 2 + .../builtin/packages/http-parser/package.py | 2 + .../builtin/packages/http-ping/package.py | 2 + .../builtin/packages/http-post/package.py | 2 + .../repos/builtin/packages/httpd/package.py | 7 +- .../repos/builtin/packages/httperf/package.py | 2 + .../repos/builtin/packages/hub/package.py | 2 + .../repos/builtin/packages/hugo/package.py | 20 +- .../builtin/packages/hunspell/package.py | 2 + .../builtin/packages/hw-probe/package.py | 3 +- .../repos/builtin/packages/hwloc/package.py | 26 +- .../builtin/packages/hybpiper/package.py | 33 +- .../builtin/packages/hybrid-lambda/package.py | 2 + .../builtin/packages/hybridsim/package.py | 3 + .../repos/builtin/packages/hydra/package.py | 3 + .../builtin/packages/hydrogen/package.py | 3 + .../builtin/packages/hyperscan/package.py | 3 + .../repos/builtin/packages/hyphen/package.py | 2 + .../repos/builtin/packages/hyphy/package.py | 3 + .../builtin/packages/hypre-cmake/package.py | 4 + .../packages/hypre/hypre-precision-fix.patch | 27 + .../repos/builtin/packages/hypre/package.py | 41 +- .../repos/builtin/packages/hztool/package.py | 2 + .../repos/builtin/packages/i3/package.py | 2 + .../packages/ibm-databroker/package.py | 3 + .../builtin/packages/ibm-java/package.py | 4 +- .../repos/builtin/packages/ibmisc/package.py | 3 + .../repos/builtin/packages/icarus/package.py | 3 + .../repos/builtin/packages/iceauth/package.py | 3 + .../repos/builtin/packages/icedtea/package.py | 5 +- .../repos/builtin/packages/icet/package.py | 2 + .../repos/builtin/packages/ico/package.py | 2 + .../repos/builtin/packages/icon/package.py | 8 +- .../repos/builtin/packages/icu4c/package.py | 14 +- .../repos/builtin/packages/id3lib/package.py | 3 + .../repos/builtin/packages/idba/package.py | 2 + .../repos/builtin/packages/idg/package.py | 3 + .../repos/builtin/packages/igprof/package.py | 4 + .../repos/builtin/packages/igraph/package.py | 5 + .../builtin/packages/ike-scan/package.py | 2 + .../repos/builtin/packages/ilmbase/package.py | 2 + .../builtin/packages/ima-evm-utils/package.py | 2 + .../builtin/packages/imagemagick/package.py | 3 + .../repos/builtin/packages/imake/package.py | 6 +- .../repos/builtin/packages/imath/package.py | 4 + .../repos/builtin/packages/imgui/package.py | 4 + .../repos/builtin/packages/imlib2/package.py | 2 + .../repos/builtin/packages/imp/package.py | 3 + .../builtin/packages/impalajit/package.py | 4 + .../packages/improved-rdock/package.py | 68 +- .../builtin/packages/infernal/package.py | 2 + .../builtin/packages/iniparser/package.py | 3 + .../builtin/packages/intel-daal/package.py | 141 --- .../packages/intel-gpu-tools/package.py | 2 + .../builtin/packages/intel-gtpin/package.py | 7 +- .../builtin/packages/intel-ipp/package.py | 130 --- .../builtin/packages/intel-llvm/package.py | 6 +- .../packages/intel-mpi-benchmarks/package.py | 3 + .../builtin/packages/intel-mpi/package.py | 16 +- .../packages/intel-oneapi-advisor/package.py | 12 + .../packages/intel-oneapi-ccl/package.py | 12 + .../detection_test.yaml | 89 ++ .../intel-oneapi-compilers-classic/package.py | 21 +- .../detection_test.yaml | 23 + .../intel-oneapi-compilers/package.py | 76 +- .../packages/intel-oneapi-dal/package.py | 12 + .../packages/intel-oneapi-dnn/package.py | 18 + .../packages/intel-oneapi-dpct/package.py | 12 + .../packages/intel-oneapi-dpl/package.py | 12 + .../intel-oneapi-inspector/package.py | 6 + .../packages/intel-oneapi-ipp/package.py | 12 + .../packages/intel-oneapi-ippcp/package.py | 12 + .../packages/intel-oneapi-itac/package.py | 6 + .../packages/intel-oneapi-mkl/package.py | 61 +- .../packages/intel-oneapi-mpi/package.py | 80 +- .../packages/intel-oneapi-runtime/package.py | 67 ++ .../packages/intel-oneapi-tbb/package.py | 12 + .../packages/intel-oneapi-vtune/package.py | 12 + .../packages/intel-parallel-studio/package.py | 16 +- .../builtin/packages/intel-pin/package.py | 3 + .../builtin/packages/intel-tbb/package.py | 11 +- .../builtin/packages/intel-xed/package.py | 3 + .../packages/intel/detection_test.yaml | 42 +- .../builtin/packages/interproscan/package.py | 3 + .../repos/builtin/packages/ioapi/package.py | 3 + .../repos/builtin/packages/ior/package.py | 2 + .../repos/builtin/packages/iozone/package.py | 2 + .../repos/builtin/packages/ip/package.py | 3 + .../repos/builtin/packages/ip2/package.py | 10 +- .../repos/builtin/packages/ipcalc/package.py | 2 + .../repos/builtin/packages/iperf2/package.py | 3 + .../repos/builtin/packages/iperf3/package.py | 12 +- .../repos/builtin/packages/ipm/package.py | 4 + .../repos/builtin/packages/ipopt/package.py | 4 + .../builtin/packages/iproute2/package.py | 2 + .../builtin/packages/iptraf-ng/package.py | 2 + .../repos/builtin/packages/iq-tree/package.py | 9 + .../repos/builtin/packages/iqtree2/package.py | 43 - .../repos/builtin/packages/irep/package.py | 4 + .../builtin/packages/isa-l-crypto/package.py | 2 + .../repos/builtin/packages/isa-l/package.py | 2 + .../builtin/packages/isaac-server/package.py | 2 + .../repos/builtin/packages/isaac/package.py | 2 + .../builtin/packages/isc-dhcp/package.py | 3 + .../repos/builtin/packages/isescan/package.py | 2 + .../repos/builtin/packages/isl/package.py | 3 + .../builtin/packages/iso-codes/package.py | 1 + .../repos/builtin/packages/ispc/package.py | 3 + .../repos/builtin/packages/itensor/package.py | 15 +- .../repos/builtin/packages/itk/package.py | 4 + .../repos/builtin/packages/iwyu/package.py | 3 + .../repos/builtin/packages/jags/package.py | 4 + .../repos/builtin/packages/jali/package.py | 2 + .../builtin/packages/jansi-native/package.py | 2 + .../repos/builtin/packages/jansson/package.py | 3 + .../repos/builtin/packages/jasper/package.py | 105 +- .../repos/builtin/packages/javafx/package.py | 2 + .../repos/builtin/packages/jbigkit/package.py | 2 + .../builtin/packages/jchronoss/package.py | 3 + .../repos/builtin/packages/jdk/package.py | 139 +-- .../builtin/packages/jellyfish/package.py | 3 + .../builtin/packages/jemalloc/package.py | 3 + .../builtin/packages/jhpcn-df/package.py | 4 + .../repos/builtin/packages/jimtcl/package.py | 3 + .../repos/builtin/packages/jogl/package.py | 3 + .../repos/builtin/packages/jose/package.py | 2 + .../builtin/packages/jpegoptim/package.py | 2 + .../repos/builtin/packages/jq/package.py | 2 + .../repos/builtin/packages/json-c/package.py | 3 + .../builtin/packages/json-cwx/package.py | 2 + .../builtin/packages/json-fortran/package.py | 2 + .../repos/builtin/packages/jsoncpp/package.py | 2 + .../repos/builtin/packages/jsonnet/package.py | 3 + .../repos/builtin/packages/jube/package.py | 10 + .../repos/builtin/packages/judy/package.py | 2 + .../repos/builtin/packages/julea/package.py | 3 + ...ulia-1.10-rm-suite-sparse-cuda-stubs.patch | 16 + .../repos/builtin/packages/julia/package.py | 44 +- .../builtin/packages/justbuild/package.py | 5 + .../repos/builtin/packages/jwt-cpp/package.py | 6 + .../builtin/packages/jxrlib-debian/package.py | 2 + .../repos/builtin/packages/k8/package.py | 2 + .../repos/builtin/packages/kadath/package.py | 2 + .../repos/builtin/packages/kahip/package.py | 3 + .../builtin/packages/kakoune-lsp/package.py | 19 + .../repos/builtin/packages/kakoune/package.py | 12 +- .../packages/kaks-calculator/package.py | 2 + .../repos/builtin/packages/kaldi/package.py | 6 +- .../repos/builtin/packages/kalign/package.py | 3 + .../builtin/packages/kallisto/package.py | 27 +- .../builtin/packages/kassiopeia/package.py | 3 + .../repos/builtin/packages/kbd/package.py | 2 + .../repos/builtin/packages/kcov/package.py | 25 +- .../repos/builtin/packages/kdiff3/package.py | 2 + .../repos/builtin/packages/kea/package.py | 2 + .../repos/builtin/packages/kealib/package.py | 2 + .../builtin/packages/keepalived/package.py | 2 + .../builtin/packages/keepassxc/package.py | 4 + .../kentutils/fix-mysql-options-gcc13.patch | 13 + .../kentutils/mysql-zlib-workaround.patch | 13 + .../builtin/packages/kentutils/package.py | 150 ++- .../builtin/packages/keyutils/package.py | 2 + .../repos/builtin/packages/khmer/package.py | 3 + .../repos/builtin/packages/kibana/package.py | 2 + .../repos/builtin/packages/kicad/package.py | 3 + .../repos/builtin/packages/kim-api/package.py | 4 + .../repos/builtin/packages/kineto/package.py | 2 + .../repos/builtin/packages/kitty/package.py | 2 + .../builtin/packages/kmergenie/package.py | 2 + .../repos/builtin/packages/kmod/package.py | 2 + .../repos/builtin/packages/knem/package.py | 2 + .../packages/kokkos-kernels-legacy/package.py | 2 + .../packages/kokkos-kernels/package.py | 8 + .../builtin/packages/kokkos-legacy/package.py | 21 +- .../packages/kokkos-nvcc-wrapper/package.py | 8 + .../repos/builtin/packages/kokkos/package.py | 8 +- .../repos/builtin/packages/kraken/package.py | 2 + .../repos/builtin/packages/kraken2/package.py | 2 + .../builtin/packages/krakenuniq/package.py | 2 + .../repos/builtin/packages/krb5/package.py | 11 +- .../repos/builtin/packages/krims/package.py | 2 + .../001-remove-googletest-from-cmake.patch | 25 + .../repos/builtin/packages/kripke/package.py | 37 +- .../repos/builtin/packages/kubectl/package.py | 2 + .../builtin/packages/kubernetes/package.py | 2 + .../repos/builtin/packages/kumi/package.py | 2 + .../builtin/packages/kvasir-mpl/package.py | 2 + .../repos/builtin/packages/kvtree/package.py | 5 +- .../repos/builtin/packages/kylin/package.py | 2 + .../builtin/packages/kyotocabinet/package.py | 3 + .../repos/builtin/packages/laghos/package.py | 2 + .../repos/builtin/packages/lame/package.py | 3 + .../packages/lammps-example-plugin/package.py | 75 ++ .../repos/builtin/packages/lammps/package.py | 45 +- .../builtin/packages/landsfcutil/package.py | 2 + .../builtin/packages/lapackpp/package.py | 6 + .../repos/builtin/packages/last/package.py | 3 + .../repos/builtin/packages/lastz/package.py | 2 + .../repos/builtin/packages/laszip/package.py | 3 + .../repos/builtin/packages/latte/package.py | 3 + .../builtin/packages/launchmon/package.py | 3 + .../repos/builtin/packages/lazygit/package.py | 3 + .../repos/builtin/packages/lazyten/package.py | 2 + .../repos/builtin/packages/lbann/package.py | 14 +- .../repos/builtin/packages/lbfgspp/package.py | 2 + .../builtin/packages/lbxproxy/package.py | 2 + .../builtin/packages/lc-framework/package.py | 50 + .../repos/builtin/packages/lcc/package.py | 3 + .../repos/builtin/packages/lci/package.py | 200 ++++ .../repos/builtin/packages/lcio/package.py | 3 + .../repos/builtin/packages/lcms/package.py | 6 + .../repos/builtin/packages/lcov/package.py | 7 + .../repos/builtin/packages/ldak/package.py | 1 - .../builtin/packages/ldc-bootstrap/package.py | 3 + .../repos/builtin/packages/ldc/package.py | 3 + .../repos/builtin/packages/legion/package.py | 186 ++-- .../update-hip-path-legion-23.06.0.patch | 13 - .../repos/builtin/packages/lemon/package.py | 2 + .../builtin/packages/leptonica/package.py | 6 +- .../repos/builtin/packages/lerc/package.py | 2 + .../repos/builtin/packages/lesstif/package.py | 2 + .../repos/builtin/packages/leveldb/package.py | 3 + .../builtin/packages/lfortran/package.py | 4 + .../repos/builtin/packages/lftp/package.py | 9 +- .../repos/builtin/packages/lhapdf/package.py | 3 + .../repos/builtin/packages/lhapdf5/package.py | 4 + .../builtin/packages/libabigail/package.py | 6 +- .../repos/builtin/packages/libaec/package.py | 3 + .../repos/builtin/packages/libaio/package.py | 2 + .../repos/builtin/packages/libao/package.py | 2 + .../builtin/packages/libapplewm/package.py | 2 + .../builtin/packages/libapreq2/package.py | 2 + .../builtin/packages/libarchive/package.py | 13 +- .../repos/builtin/packages/libasr/package.py | 2 + .../builtin/packages/libassuan/package.py | 6 + .../builtin/packages/libatasmart/package.py | 2 + .../builtin/packages/libatomic-ops/package.py | 3 + .../builtin/packages/libbacktrace/package.py | 2 + .../builtin/packages/libbeagle/package.py | 3 + .../builtin/packages/libbeato/package.py | 2 + .../builtin/packages/libbigwig/package.py | 2 + .../builtin/packages/libbinio/package.py | 2 + .../packages/libblastrampoline/package.py | 2 + .../repos/builtin/packages/libbsd/package.py | 3 + .../repos/builtin/packages/libbson/package.py | 76 +- .../builtin/packages/libbytesize/package.py | 2 + .../repos/builtin/packages/libc/package.py | 24 - .../builtin/packages/libcanberra/package.py | 2 + .../builtin/packages/libcap-ng/package.py | 4 +- .../repos/builtin/packages/libcap/package.py | 5 +- .../builtin/packages/libcatalyst/package.py | 10 +- .../repos/builtin/packages/libceed/package.py | 4 + .../repos/builtin/packages/libcerf/package.py | 3 + .../builtin/packages/libcgroup/package.py | 3 + .../repos/builtin/packages/libcint/package.py | 7 +- .../builtin/packages/libcircle/package.py | 2 + .../builtin/packages/libconfig/package.py | 3 + .../builtin/packages/libconfuse/package.py | 2 + .../builtin/packages/libcroco/package.py | 2 + .../repos/builtin/packages/libctl/package.py | 2 + .../repos/builtin/packages/libcudf/package.py | 2 + .../repos/builtin/packages/libcuml/package.py | 2 + .../builtin/packages/libcumlprims/package.py | 2 + .../packages/libcxxwrap-julia/package.py | 4 + .../builtin/packages/libcyaml/package.py | 5 +- .../builtin/packages/libdaemon/package.py | 2 + .../repos/builtin/packages/libdap4/package.py | 4 + .../builtin/packages/libdatrie/package.py | 2 + .../builtin/packages/libdc1394/package.py | 2 + .../builtin/packages/libde265/package.py | 3 + .../builtin/packages/libdeflate/package.py | 2 + .../builtin/packages/libdicom/package.py | 3 + .../packages/libdistributed/package.py | 5 +- .../builtin/packages/libdivsufsort/package.py | 2 + .../repos/builtin/packages/libdmx/package.py | 3 + .../repos/builtin/packages/libdrm/package.py | 10 +- .../builtin/packages/libdwarf/package.py | 3 + .../builtin/packages/libeatmydata/package.py | 2 + .../builtin/packages/libecpint/package.py | 2 + .../repos/builtin/packages/libedit/package.py | 4 +- .../builtin/packages/libefence/package.py | 2 + .../repos/builtin/packages/libelf/package.py | 4 +- .../builtin/packages/libepoxy/package.py | 2 + .../repos/builtin/packages/libestr/package.py | 2 + .../repos/builtin/packages/libev/package.py | 3 + .../builtin/packages/libevdev/package.py | 2 + .../builtin/packages/libevent/package.py | 2 + .../builtin/packages/libevpath/package.py | 2 + .../repos/builtin/packages/libexif/package.py | 2 + .../builtin/packages/libfabric/package.py | 5 + .../builtin/packages/libfastcommon/package.py | 2 + .../builtin/packages/libfastjson/package.py | 2 + .../repos/builtin/packages/libffi/package.py | 7 +- .../repos/builtin/packages/libffs/package.py | 2 + .../builtin/packages/libfirefly/package.py | 2 + .../repos/builtin/packages/libfive/package.py | 2 + .../builtin/packages/libflame/package.py | 3 + .../repos/builtin/packages/libfms/package.py | 3 + .../builtin/packages/libfontenc/package.py | 2 + .../repos/builtin/packages/libfort/package.py | 39 + .../repos/builtin/packages/libfs/package.py | 2 + .../repos/builtin/packages/libfuse/package.py | 3 + .../builtin/packages/libfyaml/package.py | 3 + .../repos/builtin/packages/libgain/package.py | 2 + .../builtin/packages/libgcrypt/package.py | 30 +- .../repos/builtin/packages/libgd/package.py | 3 + .../builtin/packages/libgdsii/package.py | 2 + .../builtin/packages/libgeotiff/package.py | 2 + .../repos/builtin/packages/libgff/package.py | 2 + .../repos/builtin/packages/libgit2/package.py | 6 +- .../builtin/packages/libgpg-error/package.py | 11 + .../builtin/packages/libgpuarray/package.py | 2 + .../builtin/packages/libgridxc/package.py | 2 + .../builtin/packages/libgssglue/package.py | 2 + .../repos/builtin/packages/libgta/package.py | 3 + .../builtin/packages/libgtextutils/package.py | 3 + .../repos/builtin/packages/libgtop/package.py | 26 + .../builtin/packages/libgudev/package.py | 22 + .../repos/builtin/packages/libharu/package.py | 7 +- .../builtin/packages/libhbaapi/package.py | 2 + .../repos/builtin/packages/libheif/package.py | 3 + .../repos/builtin/packages/libhio/package.py | 2 + .../builtin/packages/libhugetlbfs/package.py | 22 +- .../builtin/packages/libiberty/package.py | 3 + .../builtin/packages/libibumad/package.py | 2 + .../repos/builtin/packages/libical/package.py | 6 +- .../repos/builtin/packages/libicd/package.py | 3 + .../repos/builtin/packages/libice/package.py | 3 +- .../builtin/packages/libiconv/package.py | 13 + .../builtin/packages/libid3tag/package.py | 2 + .../repos/builtin/packages/libidl/package.py | 2 + .../repos/builtin/packages/libidn/package.py | 2 + .../repos/builtin/packages/libidn2/package.py | 3 + .../builtin/packages/libimagequant/package.py | 2 + .../repos/builtin/packages/libinih/package.py | 3 + .../repos/builtin/packages/libint/package.py | 80 +- .../repos/builtin/packages/libisal/package.py | 3 + .../builtin/packages/libiscsi/package.py | 2 + .../builtin/packages/libjpeg-turbo/package.py | 6 + .../repos/builtin/packages/libjpeg/package.py | 2 + .../repos/builtin/packages/libjson/package.py | 2 + .../repos/builtin/packages/libjwt/package.py | 2 + .../repos/builtin/packages/libjxl/package.py | 7 + .../builtin/packages/libkcapi/package.py | 2 + .../repos/builtin/packages/libkml/package.py | 3 + .../repos/builtin/packages/libksba/package.py | 4 + .../repos/builtin/packages/liblas/package.py | 3 + .../builtin/packages/liblbxutil/package.py | 2 + .../builtin/packages/liblockfile/package.py | 2 + .../builtin/packages/liblognorm/package.py | 2 + .../builtin/packages/liblouis/package.py | 2 + .../repos/builtin/packages/libluv/package.py | 2 + .../repos/builtin/packages/liblzf/package.py | 2 + .../builtin/packages/libmacaroons/package.py | 2 + .../repos/builtin/packages/libmad/package.py | 2 + .../builtin/packages/libmatheval/package.py | 2 + .../builtin/packages/libmaus2/package.py | 3 + .../builtin/packages/libmaxminddb/package.py | 2 + .../repos/builtin/packages/libmbim/package.py | 2 + .../builtin/packages/libmcrypt/package.py | 2 + .../repos/builtin/packages/libmd/package.py | 2 + .../repos/builtin/packages/libmesh/package.py | 11 +- .../builtin/packages/libmetalink/package.py | 2 + .../builtin/packages/libmicrodns/package.py | 2 + .../builtin/packages/libmicrohttpd/package.py | 2 + .../builtin/packages/libmmtf-cpp/package.py | 2 + .../repos/builtin/packages/libmng/package.py | 3 + .../builtin/packages/libmo-unpack/package.py | 2 + .../builtin/packages/libmodbus/package.py | 2 + .../builtin/packages/libmolgrid/package.py | 2 + .../builtin/packages/libmonitor/package.py | 2 + .../builtin/packages/libmpdclient/package.py | 2 + .../builtin/packages/libmypaint/package.py | 2 + .../repos/builtin/packages/libnbc/package.py | 2 + .../repos/builtin/packages/libndp/package.py | 2 + .../repos/builtin/packages/libnet/package.py | 3 + .../libnetfilter-conntrack/package.py | 2 + .../packages/libnetfilter-cthelper/package.py | 2 + .../libnetfilter-cttimeout/package.py | 2 + .../packages/libnetfilter-queue/package.py | 2 + .../builtin/packages/libnetworkit/package.py | 2 + .../builtin/packages/libnfnetlink/package.py | 2 + .../repos/builtin/packages/libnfs/package.py | 2 + .../builtin/packages/libnfsidmap/package.py | 2 + .../builtin/packages/libnftnl/package.py | 2 + .../repos/builtin/packages/libnids/package.py | 3 + .../repos/builtin/packages/libnl/package.py | 2 + .../builtin/packages/libnotify/package.py | 2 + .../repos/builtin/packages/libnova/package.py | 2 + .../repos/builtin/packages/libnrm/package.py | 2 + .../repos/builtin/packages/libnsl/package.py | 2 + .../repos/builtin/packages/libogg/package.py | 2 + .../repos/builtin/packages/liboldx/package.py | 2 + .../repos/builtin/packages/libopts/package.py | 2 + .../repos/builtin/packages/libp11/package.py | 3 + .../repos/builtin/packages/libpam/package.py | 2 + .../builtin/packages/libpaper/package.py | 3 + .../repos/builtin/packages/libpcap/package.py | 3 + .../builtin/packages/libpciaccess/package.py | 2 + .../repos/builtin/packages/libpfm4/package.py | 2 + .../builtin/packages/libpipeline/package.py | 2 + .../builtin/packages/libplist/package.py | 3 + .../packages/libpmemobj-cpp/package.py | 4 + .../repos/builtin/packages/libpng/package.py | 3 + .../builtin/packages/libpostal/package.py | 2 + .../packages/libpressio-adios1/package.py | 26 + .../packages/libpressio-adios2/package.py | 4 + .../packages/libpressio-dataset/package.py | 44 + .../libpressio-errorinjector/package.py | 8 +- .../packages/libpressio-jit/package.py | 30 + .../packages/libpressio-nvcomp/package.py | 6 + .../packages/libpressio-opt/package.py | 7 +- .../packages/libpressio-predict/package.py | 66 ++ .../packages/libpressio-rmetric/package.py | 8 +- .../packages/libpressio-sperr/package.py | 6 +- .../packages/libpressio-tools/package.py | 66 +- .../packages/libpressio-tthresh/package.py | 6 +- .../builtin/packages/libpressio/package.py | 194 ++-- .../builtin/packages/libproxy/package.py | 3 + .../repos/builtin/packages/libpsl/package.py | 5 +- .../repos/builtin/packages/libpsm3/package.py | 2 + .../repos/builtin/packages/libpsml/package.py | 2 + .../builtin/packages/libpspio/package.py | 3 + .../packages/libpthread-stubs/package.py | 1 + .../builtin/packages/libpulsar/package.py | 3 + .../builtin/packages/libqrencode/package.py | 2 + .../repos/builtin/packages/libquo/package.py | 3 + .../repos/builtin/packages/libraqm/package.py | 2 + .../builtin/packages/libraw1394/package.py | 2 + .../builtin/packages/librdkafka/package.py | 3 + .../repos/builtin/packages/librelp/package.py | 2 + .../builtin/packages/libreproc/package.py | 3 + .../builtin/packages/libressl/package.py | 2 + .../builtin/packages/libristra/package.py | 6 +- .../repos/builtin/packages/librmm/package.py | 2 + .../repos/builtin/packages/librom/package.py | 4 + .../repos/builtin/packages/librsb/package.py | 4 + .../repos/builtin/packages/librsvg/package.py | 4 + .../builtin/packages/librtlsdr/package.py | 2 + .../builtin/packages/librttopo/package.py | 2 + .../builtin/packages/libsakura/package.py | 3 + .../builtin/packages/libsamplerate/package.py | 2 + .../builtin/packages/libseccomp/package.py | 2 + .../builtin/packages/libsecret/package.py | 2 + .../builtin/packages/libsharp/package.py | 3 + .../repos/builtin/packages/libshm/package.py | 2 + .../builtin/packages/libsigcpp/package.py | 2 + .../packages/libsignal-protocol-c/package.py | 2 + ...ew_config_guess => new_config_guess.patch} | 0 .../builtin/packages/libsigsegv/package.py | 4 +- .../builtin/packages/libsixel/package.py | 3 + .../builtin/packages/libslirp/package.py | 2 + .../repos/builtin/packages/libsm/package.py | 2 + .../builtin/packages/libsndfile/package.py | 3 + .../builtin/packages/libsodium/package.py | 16 +- .../repos/builtin/packages/libsolv/package.py | 3 + .../packages/libspatialindex/package.py | 2 + .../builtin/packages/libspatialite/package.py | 2 + .../builtin/packages/libspiro/package.py | 2 + .../builtin/packages/libsplash/package.py | 2 + .../repos/builtin/packages/libspng/package.py | 3 + .../repos/builtin/packages/libssh/package.py | 3 + .../repos/builtin/packages/libssh2/package.py | 3 + .../builtin/packages/libstdcompat/package.py | 23 +- .../repos/builtin/packages/libsvm/package.py | 3 + .../repos/builtin/packages/libszip/package.py | 2 + .../repos/builtin/packages/libtar/package.py | 2 + .../builtin/packages/libtasn1/package.py | 2 + .../builtin/packages/libtermkey/package.py | 2 + .../repos/builtin/packages/libthai/package.py | 2 + .../builtin/packages/libtheora/package.py | 8 +- .../repos/builtin/packages/libtiff/package.py | 14 + .../builtin/packages/libtirpc/package.py | 2 + .../repos/builtin/packages/libtlx/package.py | 2 + .../builtin/packages/libtomlc99/package.py | 2 + .../builtin/packages/libtommath/package.py | 3 + .../repos/builtin/packages/libtool/package.py | 2 + .../builtin/packages/libtorrent/package.py | 2 + .../builtin/packages/libtraceevent/package.py | 50 + .../repos/builtin/packages/libtree/package.py | 2 + .../repos/builtin/packages/libuecc/package.py | 2 + .../builtin/packages/libunistring/package.py | 3 + .../builtin/packages/libunwind/package.py | 3 + .../builtin/packages/liburing/package.py | 7 +- .../repos/builtin/packages/libusb/package.py | 3 + .../repos/builtin/packages/libuser/package.py | 2 + .../repos/builtin/packages/libuuid/package.py | 10 +- .../builtin/packages/libuv-julia/package.py | 2 + .../repos/builtin/packages/libuv/package.py | 5 +- .../packages/libvdwxc/fftw-detection.patch | 13 + .../builtin/packages/libvdwxc/package.py | 12 + .../builtin/packages/libverto/package.py | 2 + .../repos/builtin/packages/libvips/package.py | 3 + .../builtin/packages/libvorbis/package.py | 2 + .../repos/builtin/packages/libvori/package.py | 2 + .../repos/builtin/packages/libvpx/package.py | 3 + .../builtin/packages/libvterm/package.py | 2 + .../repos/builtin/packages/libwebp/package.py | 15 +- .../builtin/packages/libwebsockets/package.py | 3 + .../builtin/packages/libwhich/package.py | 2 + .../builtin/packages/libwindowswm/package.py | 2 + .../repos/builtin/packages/libwmf/package.py | 2 + .../repos/builtin/packages/libwnck/package.py | 76 ++ .../repos/builtin/packages/libx11/package.py | 5 + .../repos/builtin/packages/libxau/package.py | 4 +- .../repos/builtin/packages/libxaw/package.py | 5 +- .../builtin/packages/libxaw3d/package.py | 7 +- .../packages/libxc/nvhpc-configure.patch | 75 -- .../packages/libxc/nvhpc-libtool.patch | 77 -- .../repos/builtin/packages/libxc/package.py | 61 +- .../repos/builtin/packages/libxcb/package.py | 25 +- .../builtin/packages/libxcomposite/package.py | 4 +- .../builtin/packages/libxcrypt/package.py | 2 + .../builtin/packages/libxcursor/package.py | 5 +- .../builtin/packages/libxdamage/package.py | 4 +- .../builtin/packages/libxdmcp/package.py | 6 +- .../builtin/packages/libxevie/package.py | 4 +- .../repos/builtin/packages/libxext/package.py | 5 +- .../builtin/packages/libxfixes/package.py | 4 +- .../builtin/packages/libxfont/package.py | 6 +- .../builtin/packages/libxfont2/package.py | 4 +- .../builtin/packages/libxfontcache/package.py | 4 +- .../repos/builtin/packages/libxft/package.py | 4 +- .../repos/builtin/packages/libxi/package.py | 4 +- .../builtin/packages/libxinerama/package.py | 4 +- .../builtin/packages/libxkbcommon/package.py | 12 +- .../builtin/packages/libxkbfile/package.py | 5 +- .../builtin/packages/libxkbui/package.py | 4 +- .../repos/builtin/packages/libxml2/package.py | 23 +- .../repos/builtin/packages/libxmu/package.py | 7 +- .../repos/builtin/packages/libxp/package.py | 4 +- .../repos/builtin/packages/libxpm/package.py | 4 +- .../builtin/packages/libxpresent/package.py | 4 +- .../packages/libxprintapputil/package.py | 4 +- .../builtin/packages/libxprintutil/package.py | 4 +- .../builtin/packages/libxrandr/package.py | 4 +- .../builtin/packages/libxrender/package.py | 4 +- .../repos/builtin/packages/libxres/package.py | 4 +- .../builtin/packages/libxscrnsaver/package.py | 4 +- .../builtin/packages/libxshmfence/package.py | 2 + .../repos/builtin/packages/libxslt/package.py | 2 + .../repos/builtin/packages/libxsmm/package.py | 4 + .../builtin/packages/libxstream/package.py | 3 + .../repos/builtin/packages/libxt/package.py | 4 +- .../builtin/packages/libxtrap/package.py | 4 +- .../repos/builtin/packages/libxtst/package.py | 4 +- .../repos/builtin/packages/libxv/package.py | 4 +- .../repos/builtin/packages/libxvmc/package.py | 5 +- .../builtin/packages/libxxf86dga/package.py | 4 +- .../builtin/packages/libxxf86misc/package.py | 4 +- .../builtin/packages/libxxf86vm/package.py | 4 +- .../repos/builtin/packages/libyaml/package.py | 2 + .../builtin/packages/libyogrt/package.py | 14 +- .../repos/builtin/packages/libzip/package.py | 41 +- .../repos/builtin/packages/libzmq/package.py | 3 + .../builtin/packages/liggghts/package.py | 4 + .../builtin/packages/lighttpd/package.py | 2 + .../repos/builtin/packages/ligra/package.py | 2 + .../repos/builtin/packages/likwid/package.py | 5 +- .../builtin/packages/linaro-forge/package.py | 15 + .../builtin/packages/linkphase3/package.py | 2 + .../builtin/packages/linktest/package.py | 2 + .../builtin/packages/linux-headers/package.py | 5 + .../builtin/packages/linux-pam/package.py | 51 +- .../repos/builtin/packages/lis/package.py | 1 + .../repos/builtin/packages/listres/package.py | 2 + .../repos/builtin/packages/lizard/package.py | 5 +- .../builtin/packages/lksctp-tools/package.py | 2 + .../packages/llvm-amdgpu/detection_test.yaml | 103 ++ .../builtin/packages/llvm-amdgpu/package.py | 86 +- .../builtin/packages/llvm-doe/package.py | 9 +- .../packages/llvm-openmp-ompt/package.py | 4 + .../builtin/packages/llvm-openmp/package.py | 4 + .../builtin/packages/llvm/detection_test.yaml | 128 +-- .../packages/llvm/llvm17-18-thread.patch | 22 + .../packages/llvm/llvm17-fujitsu.patch | 28 + .../repos/builtin/packages/llvm/package.py | 148 ++- .../builtin/packages/lm-sensors/package.py | 2 + .../repos/builtin/packages/lmbench/package.py | 2 + .../repos/builtin/packages/lmdb/package.py | 2 + .../repos/builtin/packages/lmod/package.py | 8 +- .../repos/builtin/packages/lndir/package.py | 3 + .../repos/builtin/packages/lodepng/package.py | 3 + .../repos/builtin/packages/log4c/package.py | 3 + .../builtin/packages/log4cplus/package.py | 2 + .../repos/builtin/packages/log4cpp/package.py | 3 + .../builtin/packages/logrotate/package.py | 2 + .../builtin/packages/logstash/package.py | 3 + .../repos/builtin/packages/loki/package.py | 2 + .../builtin/packages/looptools/package.py | 3 + .../repos/builtin/packages/lordec/package.py | 2 + .../builtin/packages/lp-solve/package.py | 2 + .../repos/builtin/packages/lrslib/package.py | 3 + .../repos/builtin/packages/lrzip/package.py | 3 + .../repos/builtin/packages/lshw/package.py | 3 + .../repos/builtin/packages/lsscsi/package.py | 2 + .../repos/builtin/packages/ltp/package.py | 2 + .../repos/builtin/packages/ltrace/package.py | 3 + .../repos/builtin/packages/lua-ffi/package.py | 2 + .../builtin/packages/lua-lpeg/package.py | 5 + .../packages/lua-luafilesystem/package.py | 2 + .../packages/lua-luajit-openresty/package.py | 3 + .../builtin/packages/lua-luajit/package.py | 3 + .../builtin/packages/lua-luaposix/package.py | 2 + .../builtin/packages/lua-mpack/package.py | 3 + .../builtin/packages/lua-sol2/package.py | 2 + .../repos/builtin/packages/lua/package.py | 8 +- .../repos/builtin/packages/lucene/package.py | 1 + .../repos/builtin/packages/luit/package.py | 2 + .../repos/builtin/packages/lulesh/package.py | 2 + .../builtin/packages/lumpy-sv/package.py | 3 + .../repos/builtin/packages/lvarray/package.py | 3 + .../repos/builtin/packages/lvm2/package.py | 3 + .../repos/builtin/packages/lwgrp/package.py | 2 + .../repos/builtin/packages/lwtnn/package.py | 2 + .../repos/builtin/packages/lxc/package.py | 2 + .../repos/builtin/packages/lynx/package.py | 2 + .../repos/builtin/packages/lz4/package.py | 3 + .../repos/builtin/packages/lzma/package.py | 3 + .../repos/builtin/packages/lzo/package.py | 2 + .../repos/builtin/packages/lzop/package.py | 2 + .../repos/builtin/packages/m4/package.py | 3 + .../repos/builtin/packages/macfuse/package.py | 1 - .../repos/builtin/packages/macsio/package.py | 2 + .../builtin/packages/mad-numdiff/package.py | 2 + .../repos/builtin/packages/madis/package.py | 2 + .../repos/builtin/packages/madx/package.py | 5 + .../builtin/packages/maeparser/package.py | 2 + .../repos/builtin/packages/mafft/package.py | 4 + .../builtin/packages/magic-enum/package.py | 44 + .../repos/builtin/packages/magics/package.py | 4 + .../repos/builtin/packages/magma/package.py | 27 +- .../builtin/packages/makedepend/package.py | 4 + .../builtin/packages/mallocmc/package.py | 2 + .../repos/builtin/packages/maloc/package.py | 3 + .../repos/builtin/packages/malt/package.py | 3 + .../repos/builtin/packages/man-db/package.py | 4 + .../repos/builtin/packages/mapl/package.py | 115 ++- .../repos/builtin/packages/mapnik/package.py | 2 + .../builtin/packages/mapserver/package.py | 9 +- .../repos/builtin/packages/maq/package.py | 3 + .../repos/builtin/packages/margo/package.py | 2 + .../packages/mariadb-c-client/package.py | 3 + .../repos/builtin/packages/mariadb/package.py | 7 + .../repos/builtin/packages/masa/package.py | 4 + .../repos/builtin/packages/mash/package.py | 3 + .../repos/builtin/packages/masurca/package.py | 8 +- .../repos/builtin/packages/matio/package.py | 2 + .../builtin/packages/matrix-switch/package.py | 55 ++ .../builtin/packages/maverick/package.py | 3 + .../repos/builtin/packages/mawk/package.py | 2 + .../repos/builtin/packages/mbdyn/package.py | 4 + .../repos/builtin/packages/mbedtls/package.py | 2 + .../repos/builtin/packages/mc/package.py | 5 +- .../repos/builtin/packages/mcl/package.py | 2 + .../repos/builtin/packages/mcpp/package.py | 3 + .../repos/builtin/packages/mct/package.py | 3 + .../builtin/packages/mctc-lib/package.py | 2 + .../repos/builtin/packages/mcutils/package.py | 2 + .../repos/builtin/packages/mdsplus/package.py | 4 + .../repos/builtin/packages/mdtest/package.py | 2 + .../repos/builtin/packages/med/package.py | 61 +- .../builtin/packages/medipack/package.py | 2 + .../repos/builtin/packages/meep/package.py | 4 + .../builtin/packages/megadock/package.py | 2 + .../builtin/packages/melissa-api/package.py | 3 + .../repos/builtin/packages/melissa/package.py | 3 + .../repos/builtin/packages/memaxes/package.py | 10 +- .../builtin/packages/memcached/package.py | 2 + .../repos/builtin/packages/meme/package.py | 2 + .../repos/builtin/packages/memkind/package.py | 3 + .../builtin/packages/memsurfer/package.py | 4 +- .../repos/builtin/packages/mepo/package.py | 27 + .../builtin/packages/meraculous/package.py | 3 + .../builtin/packages/mercurial/package.py | 4 + .../repos/builtin/packages/mercury/package.py | 3 + .../builtin/packages/mesa-demos/package.py | 25 +- .../builtin/packages/mesa-glu/package.py | 21 +- .../repos/builtin/packages/mesa/package.py | 24 +- .../packages/mesa18/autotools-x11-nodri.patch | 14 - .../mesa18/multiple-symbols_hash.patch | 22 - .../repos/builtin/packages/mesa18/package.py | 228 ----- .../repos/builtin/packages/meshkit/package.py | 2 + .../builtin/packages/meshtool/package.py | 5 + .../repos/builtin/packages/meson/package.py | 2 - .../repos/builtin/packages/met/package.py | 3 + .../repos/builtin/packages/metabat/package.py | 2 + .../builtin/packages/metacarpa/package.py | 43 + .../repos/builtin/packages/metaeuk/package.py | 3 + .../repos/builtin/packages/metal/package.py | 2 + .../repos/builtin/packages/metall/package.py | 8 +- .../builtin/packages/metaphysicl/package.py | 3 + .../builtin/packages/methyldackel/package.py | 2 + .../repos/builtin/packages/metis/package.py | 30 +- .../repos/builtin/packages/metkit/package.py | 2 + .../builtin/packages/mfem/mfem-4.7.patch | 102 ++ .../builtin/packages/mfem/mfem-hip.patch | 24 - .../repos/builtin/packages/mfem/package.py | 196 ++-- .../builtin/packages/mfem/test_builds.sh | 120 ++- .../repos/builtin/packages/mg/package.py | 2 + .../repos/builtin/packages/mgard/package.py | 3 + .../repos/builtin/packages/mgardx/package.py | 3 + .../builtin/packages/mgcfd-op2/package.py | 8 +- .../repos/builtin/packages/mgis/package.py | 4 + .../packages/microbiomeutil/package.py | 2 + .../builtin/packages/micromamba/package.py | 2 + .../builtin/packages/microsocks/package.py | 2 + .../0002-restrict-python-2.7-usage.patch | 13 - .../builtin/packages/migraphx/package.py | 36 +- .../repos/builtin/packages/migrate/package.py | 3 + .../repos/builtin/packages/mii/package.py | 2 + .../builtin/packages/millepede/package.py | 4 + .../builtin/packages/mimalloc/package.py | 3 + .../builtin/packages/minc-toolkit/package.py | 3 + .../builtin/packages/mindthegap/package.py | 3 + .../builtin/packages/miniaero/package.py | 2 + .../repos/builtin/packages/miniamr/package.py | 7 +- .../repos/builtin/packages/miniasm/package.py | 2 + .../builtin/packages/miniconda3/package.py | 54 ++ .../repos/builtin/packages/minife/package.py | 3 + .../builtin/packages/miniforge3/package.py | 91 +- .../repos/builtin/packages/minigmg/package.py | 2 + .../builtin/packages/minimap2/package.py | 5 + .../repos/builtin/packages/miniqmc/package.py | 2 + .../builtin/packages/minisign/package.py | 2 + .../builtin/packages/minismac2d/package.py | 2 + .../repos/builtin/packages/minitri/package.py | 2 + .../builtin/packages/minivite/package.py | 2 + .../builtin/packages/minixyce/package.py | 2 + .../repos/builtin/packages/minizip/package.py | 3 + ...002-add-include-dir-miopen-hip-6.1.0.patch | 35 + .../builtin/packages/miopen-hip/package.py | 54 +- .../builtin/packages/miopen-opencl/package.py | 30 +- .../packages/miopen-tensile/package.py | 91 -- .../builtin/packages/miopengemm/package.py | 24 +- .../repos/builtin/packages/mira/package.py | 2 + .../repos/builtin/packages/mitos/package.py | 2 + ...dd-half-include-path-for-tests-6.1.0.patch | 86 ++ .../builtin/packages/mivisionx/package.py | 124 ++- .../builtin/packages/mkfontscale/package.py | 4 +- .../repos/builtin/packages/mlhka/package.py | 2 + .../builtin/packages/mlirmiopen/package.py | 13 +- .../repos/builtin/packages/mlocate/package.py | 2 + .../repos/builtin/packages/mlpack/package.py | 6 +- .../repos/builtin/packages/mmg/package.py | 7 + .../repos/builtin/packages/mmseqs2/package.py | 6 +- .../repos/builtin/packages/mmv/package.py | 2 + .../repos/builtin/packages/moab/package.py | 4 + .../builtin/packages/mochi-margo/package.py | 4 + .../packages/mochi-thallium/package.py | 2 + .../builtin/packages/model-traits/package.py | 2 + .../builtin/packages/modeltest-ng/package.py | 3 + .../builtin/packages/modern-wheel/package.py | 2 + .../repos/builtin/packages/mokutil/package.py | 2 + .../repos/builtin/packages/mold/package.py | 27 +- .../repos/builtin/packages/molden/package.py | 3 + .../repos/builtin/packages/molgw/package.py | 24 +- .../packages/mongo-c-driver/package.py | 115 +-- .../packages/mongo-cxx-driver/package.py | 9 +- .../repos/builtin/packages/mongodb/package.py | 3 + .../repos/builtin/packages/mono/package.py | 11 +- .../repos/builtin/packages/montage/package.py | 4 + .../repos/builtin/packages/moosefs/package.py | 2 + .../builtin/packages/moreutils/package.py | 2 + .../builtin/packages/mosesdecoder/package.py | 4 + .../builtin/packages/mosquitto/package.py | 3 + .../repos/builtin/packages/mothur/package.py | 2 + .../repos/builtin/packages/motif/package.py | 3 + .../mount-point-attributes/package.py | 2 + .../repos/builtin/packages/mozjpeg/package.py | 3 + .../builtin/packages/mpark-variant/package.py | 2 + .../builtin/packages/mpas-model/package.py | 16 +- .../repos/builtin/packages/mpb/package.py | 2 + .../repos/builtin/packages/mpc/package.py | 2 + .../builtin/packages/mpdecimal/package.py | 3 + .../repos/builtin/packages/mpe2/package.py | 3 + .../repos/builtin/packages/mpfr/package.py | 2 + .../builtin/packages/mpi-bash/package.py | 2 + .../builtin/packages/mpi-serial/package.py | 3 + .../packages/mpi-test-suite/package.py | 2 + .../repos/builtin/packages/mpibind/package.py | 3 + .../repos/builtin/packages/mpich/package.py | 110 ++- .../builtin/packages/mpifileutils/package.py | 132 +-- .../builtin/packages/mpilander/package.py | 3 + .../builtin/packages/mpileaks/package.py | 4 + .../repos/builtin/packages/mpip/package.py | 4 + .../repos/builtin/packages/mpir/package.py | 3 + .../builtin/packages/mpitrampoline/package.py | 10 +- .../builtin/packages/mpiwrapper/package.py | 3 + .../packages/mpix-launch-swift/package.py | 2 + .../repos/builtin/packages/mpl/package.py | 3 + .../repos/builtin/packages/mppp/package.py | 2 + .../repos/builtin/packages/mpt/package.py | 21 +- .../builtin/packages/mptensor/package.py | 2 + .../repos/builtin/packages/mrbayes/package.py | 2 + .../repos/builtin/packages/mrchem/package.py | 2 + .../repos/builtin/packages/mrcpp/package.py | 2 + .../repos/builtin/packages/mrnet/package.py | 3 + .../repos/builtin/packages/mrtrix3/package.py | 2 + .../repos/builtin/packages/mruby/package.py | 3 + .../repos/builtin/packages/mscgen/package.py | 2 + .../builtin/packages/msgpack-c/package.py | 19 +- .../repos/builtin/packages/mshadow/package.py | 2 + .../repos/builtin/packages/msmpi/package.py | 13 +- .../repos/builtin/packages/mstk/package.py | 3 + .../builtin/packages/msvc/detection_test.yaml | 14 + .../repos/builtin/packages/msvc/package.py | 66 ++ .../builtin/packages/mt-metis/package.py | 3 + .../repos/builtin/packages/mtn/package.py | 2 + .../repos/builtin/packages/mujoco/package.py | 3 + .../builtin/packages/multitime/package.py | 2 + .../builtin/packages/multiverso/package.py | 2 + .../repos/builtin/packages/mummer/package.py | 3 + .../repos/builtin/packages/mummer4/package.py | 2 + .../repos/builtin/packages/mumps/package.py | 8 +- .../repos/builtin/packages/munge/package.py | 2 + .../builtin/packages/muparser/package.py | 41 +- .../builtin/packages/muparserx/package.py | 2 + .../repos/builtin/packages/muscle/package.py | 2 + .../repos/builtin/packages/muscle5/package.py | 2 + .../repos/builtin/packages/muse/package.py | 3 + .../repos/builtin/packages/music/package.py | 3 + .../repos/builtin/packages/musl/package.py | 18 + .../repos/builtin/packages/must/package.py | 4 + .../repos/builtin/packages/muster/package.py | 2 + .../builtin/packages/mutationpp/package.py | 4 + .../repos/builtin/packages/mvapich/package.py | 48 +- .../builtin/packages/mvapich2-gdr/package.py | 13 +- .../builtin/packages/mvapich2/package.py | 49 +- .../builtin/packages/mvapich2x/package.py | 12 +- .../repos/builtin/packages/mxml/package.py | 3 + .../repos/builtin/packages/mxnet/package.py | 5 +- .../packages/mysql-connector-c/package.py | 3 + .../repos/builtin/packages/mysql/package.py | 3 + .../repos/builtin/packages/mysqlpp/package.py | 2 + .../repos/builtin/packages/n2p2/package.py | 2 + .../builtin/packages/nag/detection_test.yaml | 13 + .../repos/builtin/packages/nag/package.py | 60 +- .../builtin/packages/nalu-wind/package.py | 146 ++- .../repos/builtin/packages/nalu/package.py | 18 +- .../repos/builtin/packages/namd/package.py | 40 +- .../repos/builtin/packages/nano/package.py | 5 + .../builtin/packages/nanoflann/package.py | 3 + .../repos/builtin/packages/nanomsg/package.py | 2 + .../repos/builtin/packages/nanopb/package.py | 2 + .../repos/builtin/packages/nasm/package.py | 2 + .../repos/builtin/packages/nauty/package.py | 2 + .../repos/builtin/packages/nb/package.py | 45 + .../repos/builtin/packages/nbdkit/package.py | 3 + .../packages/ncbi-magicblast/package.py | 3 + .../builtin/packages/ncbi-rmblastn/package.py | 3 + .../builtin/packages/ncbi-toolkit/package.py | 3 + .../builtin/packages/ncbi-vdb/package.py | 3 + .../packages/nccl-fastsocket/package.py | 2 + .../builtin/packages/nccl-tests/package.py | 2 + .../repos/builtin/packages/nccl/package.py | 5 + .../repos/builtin/packages/nccmp/package.py | 2 + .../repos/builtin/packages/ncdu/package.py | 2 + .../repos/builtin/packages/ncio/package.py | 2 + .../repos/builtin/packages/ncl/package.py | 46 +- .../repos/builtin/packages/nco/package.py | 6 +- .../builtin/packages/ncompress/package.py | 2 + .../repos/builtin/packages/ncurses/package.py | 5 + .../packages/ncurses/rxvt_unicode_6_4.patch | 203 ++++ .../repos/builtin/packages/ncview/package.py | 2 + .../repos/builtin/packages/ncvis/package.py | 2 + .../repos/builtin/packages/ndiff/package.py | 2 + .../repos/builtin/packages/ndzip/package.py | 3 + .../builtin/packages/neartree/package.py | 3 + .../fortran-filename-length.patch | 370 +++++++ .../packages/neic-finitefault/package.py | 145 +++ .../repos/builtin/packages/nek5000/package.py | 3 + .../repos/builtin/packages/nekbone/package.py | 3 + .../repos/builtin/packages/nekcem/package.py | 3 + .../repos/builtin/packages/neko/package.py | 9 +- .../repos/builtin/packages/nekrs/package.py | 4 + .../repos/builtin/packages/nektar/package.py | 169 +++- .../builtin/packages/nektools/package.py | 3 + .../repos/builtin/packages/nemsio/package.py | 2 + .../builtin/packages/nemsiogfs/package.py | 2 + .../repos/builtin/packages/neovim/package.py | 8 + .../repos/builtin/packages/nest/package.py | 3 + .../builtin/packages/net-snmp/package.py | 2 + .../builtin/packages/netcdf-c/package.py | 13 +- .../builtin/packages/netcdf-cxx/package.py | 2 + .../builtin/packages/netcdf-cxx4/package.py | 2 +- .../packages/netcdf-fortran/package.py | 3 + .../builtin/packages/netcdf95/package.py | 3 + .../repos/builtin/packages/netdata/package.py | 4 + .../builtin/packages/netgauge/package.py | 3 + .../repos/builtin/packages/netgen/package.py | 2 + .../builtin/packages/netkit-ftp/package.py | 2 + .../builtin/packages/netlib-lapack/package.py | 10 +- .../packages/netlib-scalapack/package.py | 9 +- .../builtin/packages/netlib-xblas/package.py | 2 + .../repos/builtin/packages/netpbm/package.py | 2 + .../repos/builtin/packages/netperf/package.py | 2 + .../repos/builtin/packages/nettle/package.py | 11 +- .../repos/builtin/packages/neuron/package.py | 9 +- .../repos/builtin/packages/neve/package.py | 2 + .../repos/builtin/packages/newt/package.py | 2 + .../builtin/packages/nextdenovo/package.py | 2 + .../builtin/packages/nextflow/package.py | 13 +- .../builtin/packages/nf-tower-cli/package.py | 4 +- .../builtin/packages/nf-wave-cli/package.py | 2 +- .../repos/builtin/packages/nfft/package.py | 2 + .../builtin/packages/nfs-ganesha/package.py | 3 + .../builtin/packages/nfs-utils/package.py | 2 + .../repos/builtin/packages/nghttp2/package.py | 6 + .../repos/builtin/packages/nginx/package.py | 4 + .../repos/builtin/packages/ngmerge/package.py | 2 + .../repos/builtin/packages/ngmlr/package.py | 3 + .../repos/builtin/packages/ngspice/package.py | 3 + .../repos/builtin/packages/nicstat/package.py | 2 + .../repos/builtin/packages/nim/package.py | 11 +- .../builtin/packages/nimrod-aai/package.py | 19 +- .../builtin/packages/ninja-fortran/package.py | 5 +- .../packages/ninja-phylogeny/package.py | 2 + .../repos/builtin/packages/ninja/package.py | 6 +- .../repos/builtin/packages/njet/package.py | 4 + .../repos/builtin/packages/nlcglib/package.py | 52 +- .../nlohmann-json-schema-validator/package.py | 2 + .../builtin/packages/nlohmann-json/package.py | 4 + .../repos/builtin/packages/nlopt/package.py | 4 + .../repos/builtin/packages/nmap/package.py | 3 + .../repos/builtin/packages/nn-c/package.py | 2 + .../repos/builtin/packages/nnpack/package.py | 3 + .../repos/builtin/packages/nnvm/package.py | 2 + .../fix-old-glibc-random-headers.patch | 22 + .../repos/builtin/packages/node-js/package.py | 21 +- .../packages/nopayloadclient/package.py | 33 + .../repos/builtin/packages/notmuch/package.py | 3 + .../repos/builtin/packages/npb/package.py | 3 + .../repos/builtin/packages/npm/package.py | 2 + .../repos/builtin/packages/npth/package.py | 3 + .../builtin/packages/ns-3-dev/package.py | 3 + .../repos/builtin/packages/nsimd/package.py | 3 + .../repos/builtin/packages/nspr/package.py | 3 + .../repos/builtin/packages/nss/package.py | 3 + .../repos/builtin/packages/ntirpc/package.py | 2 + .../repos/builtin/packages/ntl/package.py | 2 + .../repos/builtin/packages/ntpoly/package.py | 14 +- .../repos/builtin/packages/numactl/package.py | 2 + .../repos/builtin/packages/numamma/package.py | 2 + .../repos/builtin/packages/numap/package.py | 2 + .../builtin/packages/numaprof/package.py | 3 + .../repos/builtin/packages/numdiff/package.py | 2 + .../repos/builtin/packages/nut/package.py | 2 + .../builtin/packages/nvbandwidth/package.py | 2 + .../repos/builtin/packages/nvcomp/package.py | 3 + .../builtin/packages/nvdimmsim/package.py | 2 + .../packages/nvhpc/detection_test.yaml | 82 ++ .../repos/builtin/packages/nvhpc/package.py | 34 +- .../builtin/packages/nvpl-blas/package.py | 5 + .../builtin/packages/nvpl-lapack/package.py | 7 +- .../builtin/packages/nvptx-tools/package.py | 3 + .../repos/builtin/packages/nvshmem/package.py | 3 + .../repos/builtin/packages/nvtx/package.py | 2 + .../repos/builtin/packages/nwchem/package.py | 54 +- .../repos/builtin/packages/nyancat/package.py | 2 + .../repos/builtin/packages/ocaml/package.py | 3 + .../repos/builtin/packages/occa/package.py | 4 + .../repos/builtin/packages/oce/package.py | 103 +- .../repos/builtin/packages/oce/sierra.patch | 12 - .../packages/oci-systemd-hook/package.py | 2 + .../repos/builtin/packages/ocl-icd/package.py | 2 + .../builtin/packages/oclgrind/package.py | 3 + .../repos/builtin/packages/oclint/package.py | 2 + .../repos/builtin/packages/oclock/package.py | 2 + .../packages/octave-arduino/package.py | 2 + .../packages/octave-control/package.py | 2 + .../builtin/packages/octave-gsl/package.py | 2 + .../packages/octave-instrctl/package.py | 2 + .../repos/builtin/packages/octave/package.py | 15 +- .../repos/builtin/packages/octopus/package.py | 98 +- .../repos/builtin/packages/odc/package.py | 5 + .../repos/builtin/packages/odgi/package.py | 3 + .../builtin/packages/of-catalyst/package.py | 8 +- .../builtin/packages/of-precice/package.py | 2 + .../repos/builtin/packages/ollama/package.py | 57 ++ .../packages/ome-common-cpp/package.py | 2 + .../builtin/packages/ome-files-cpp/package.py | 2 + .../builtin/packages/ome-model/package.py | 2 + .../repos/builtin/packages/omega-h/package.py | 39 +- .../builtin/packages/omm-bundle/package.py | 2 + .../repos/builtin/packages/omm/package.py | 60 ++ .../builtin/packages/omnitrace/package.py | 8 +- .../repos/builtin/packages/ompss-2/package.py | 4 + .../repos/builtin/packages/ompss/package.py | 4 + .../builtin/packages/ompt-openmp/package.py | 4 + .../packages/oneapi-level-zero/package.py | 22 + .../repos/builtin/packages/onednn/package.py | 6 +- .../builtin/packages/oniguruma/package.py | 3 + .../repos/builtin/packages/onnx/package.py | 9 +- .../repos/builtin/packages/oommf/package.py | 3 + .../repos/builtin/packages/op2-dsl/package.py | 4 + .../builtin/packages/opa-psm2/package.py | 2 + .../repos/builtin/packages/opam/package.py | 2 + .../repos/builtin/packages/opari2/package.py | 4 + .../repos/builtin/packages/opdilib/package.py | 3 + .../builtin/packages/open-iscsi/package.py | 2 + .../builtin/packages/open-isns/package.py | 2 + .../repos/builtin/packages/open3d/package.py | 8 +- .../builtin/packages/openal-soft/package.py | 3 + .../packages/openbabel/cmake-time.patch | 15 + .../builtin/packages/openbabel/package.py | 6 + .../builtin/packages/openblas/package.py | 29 + .../builtin/packages/opencarp/package.py | 12 +- .../builtin/packages/opencascade/package.py | 3 + .../packages/opencl-c-headers/package.py | 5 + .../builtin/packages/opencl-clhpp/package.py | 2 + .../packages/opencl-icd-loader/package.py | 68 ++ .../builtin/packages/opencoarrays/package.py | 3 + .../repos/builtin/packages/opencv/package.py | 19 +- .../packages/opendatadetector/package.py | 2 + .../repos/builtin/packages/opendx/package.py | 3 + .../repos/builtin/packages/openexr/package.py | 3 + .../packages/openfast/hub_seg_fault.patch | 17 + .../builtin/packages/openfast/package.py | 16 +- .../builtin/packages/openfoam-org/package.py | 3 + .../builtin/packages/openfoam/package.py | 11 +- .../repos/builtin/packages/openfst/package.py | 2 + .../repos/builtin/packages/opengl/package.py | 2 +- .../packages/openimagedenoise/package.py | 6 +- .../builtin/packages/openimageio/package.py | 2 + .../builtin/packages/openipmi/package.py | 3 + .../repos/builtin/packages/openjdk/package.py | 76 +- .../builtin/packages/openjpeg/package.py | 6 + .../packages/openkim-models/package.py | 4 + .../builtin/packages/openldap/package.py | 3 + .../builtin/packages/openlibm/package.py | 3 + .../builtin/packages/openloops/package.py | 4 + .../repos/builtin/packages/openmc/package.py | 7 +- .../repos/builtin/packages/openmm/package.py | 7 +- .../builtin/packages/openmolcas/package.py | 3 + .../repos/builtin/packages/openmpi/package.py | 86 +- .../pmix_getline_pmix_version-prte.patch | 14 + .../openmpi/pmix_getline_pmix_version.patch | 52 + .../repos/builtin/packages/openmx/package.py | 3 + .../builtin/packages/opennurbs/package.py | 33 +- .../repos/builtin/packages/openpa/package.py | 3 + .../repos/builtin/packages/openpbs/package.py | 3 + .../builtin/packages/openpmd-api/package.py | 25 +- .../packages/openradioss-engine/package.py | 63 +- .../packages/openradioss-starter/package.py | 46 +- .../builtin/packages/openrasmol/package.py | 2 + .../builtin/packages/openresty/package.py | 4 + .../packages/openscenegraph/package.py | 20 +- .../builtin/packages/openslide/package.py | 2 + .../repos/builtin/packages/openslp/package.py | 3 + .../packages/openspeedshop-utils/package.py | 4 + .../builtin/packages/openspeedshop/package.py | 4 + .../repos/builtin/packages/openssh/package.py | 15 +- .../repos/builtin/packages/openssl/package.py | 350 +------ .../repos/builtin/packages/opensta/package.py | 2 + .../builtin/packages/opensubdiv/package.py | 2 + .../builtin/packages/openturns/package.py | 3 + .../repos/builtin/packages/openvdb/package.py | 2 + .../repos/builtin/packages/openvkl/package.py | 6 +- .../builtin/packages/openwsman/package.py | 9 +- .../ophidia-analytics-framework/package.py | 2 + .../packages/ophidia-io-server/package.py | 2 + .../packages/ophidia-primitives/package.py | 2 + .../packages/ophidia-server/package.py | 2 + .../repos/builtin/packages/opium/package.py | 3 + .../builtin/packages/optional-lite/package.py | 2 + .../repos/builtin/packages/optipng/package.py | 3 + .../repos/builtin/packages/opus/package.py | 10 +- .../builtin/packages/or-tools/package.py | 2 + .../repos/builtin/packages/orbit2/package.py | 2 + .../repos/builtin/packages/orc/package.py | 2 + .../repos/builtin/packages/orca/package.py | 49 +- .../repos/builtin/packages/orfm/package.py | 2 + .../builtin/packages/orthofinder/package.py | 2 +- .../builtin/packages/osg-ca-certs/package.py | 27 +- .../repos/builtin/packages/osi/package.py | 2 + .../builtin/packages/osmctools/package.py | 2 + .../repos/builtin/packages/osmesa/package.py | 10 +- .../repos/builtin/packages/ospray/package.py | 5 + .../repos/builtin/packages/osqp/package.py | 2 + .../builtin/packages/ossp-uuid/package.py | 3 + .../packages/osu-micro-benchmarks/package.py | 4 + .../repos/builtin/packages/otf/package.py | 3 + .../repos/builtin/packages/otf2/package.py | 34 +- .../repos/builtin/packages/p11-kit/package.py | 2 + .../repos/builtin/packages/p3dfft3/package.py | 4 + .../repos/builtin/packages/p4est/package.py | 2 + .../repos/builtin/packages/p7zip/package.py | 3 + .../packages/pacbio-daligner/package.py | 2 + .../packages/pacbio-damasker/package.py | 2 + .../packages/pacbio-dazz-db/package.py | 2 + .../packages/pacbio-dextractor/package.py | 2 + .../repos/builtin/packages/packmol/package.py | 2 + .../builtin/packages/pacparser/package.py | 2 + .../repos/builtin/packages/pacvim/package.py | 2 + .../repos/builtin/packages/paddle/package.py | 3 + .../repos/builtin/packages/pagit/package.py | 2 + .../repos/builtin/packages/pagmo/package.py | 3 + .../repos/builtin/packages/pagmo2/package.py | 2 + .../repos/builtin/packages/paintor/package.py | 4 + .../repos/builtin/packages/pajeng/package.py | 2 + .../repos/builtin/packages/pal/package.py | 2 + .../repos/builtin/packages/palace/package.py | 2 + .../packages/palisade-development/package.py | 3 + .../repos/builtin/packages/paml/package.py | 2 + .../repos/builtin/packages/panda/package.py | 2 + .../builtin/packages/pandaseq/package.py | 2 + .../repos/builtin/packages/pandoc/package.py | 2 + .../packages/pandoramonitoring/package.py | 2 + .../builtin/packages/pandorasdk/package.py | 2 + .../repos/builtin/packages/pango/package.py | 47 +- .../builtin/packages/pangolin/package.py | 2 + .../repos/builtin/packages/pangomm/package.py | 2 + .../repos/builtin/packages/papi/package.py | 4 + .../packages/parallel-hashmap/package.py | 2 + .../packages/parallel-netcdf/package.py | 4 + .../builtin/packages/parallelio/package.py | 4 + .../packages/parallelmergetree/package.py | 3 + .../repos/builtin/packages/paraver/package.py | 3 + .../paraview/kits_with_catalyst_5_12.patch | 21 + .../builtin/packages/paraview/package.py | 158 +-- .../packages/paraview/vtk_alias_hdf5.patch | 14 + .../repos/builtin/packages/parflow/package.py | 35 +- .../builtin/packages/parmetis/package.py | 2 + .../builtin/packages/parmgridgen/package.py | 2 + .../repos/builtin/packages/parmmg/package.py | 4 + .../builtin/packages/parquet-cpp/package.py | 2 + .../builtin/packages/parsimonator/package.py | 2 + .../builtin/packages/parsplice/package.py | 2 + .../builtin/packages/parthenon/package.py | 77 ++ .../repos/builtin/packages/pass/package.py | 63 ++ .../repos/builtin/packages/pastix/package.py | 6 +- .../repos/builtin/packages/patch/package.py | 2 + .../builtin/packages/patchelf/package.py | 3 + .../builtin/packages/patchutils/package.py | 2 + .../builtin/packages/pathfinder/package.py | 2 + .../builtin/packages/pax-utils/package.py | 2 + .../repos/builtin/packages/pbbam/package.py | 2 + .../repos/builtin/packages/pblat/package.py | 2 + .../repos/builtin/packages/pbmpi/package.py | 2 + .../builtin/packages/pciutils/package.py | 2 + .../repos/builtin/packages/pcl/package.py | 4 + .../repos/builtin/packages/pcma/package.py | 2 + .../repos/builtin/packages/pcre/package.py | 3 + .../repos/builtin/packages/pcre2/package.py | 3 + .../builtin/packages/pcsclite/package.py | 2 + .../repos/builtin/packages/pdal/package.py | 2 + .../repos/builtin/packages/pdc/package.py | 10 +- .../repos/builtin/packages/pdf2svg/package.py | 2 + .../repos/builtin/packages/pdsh/package.py | 2 + .../repos/builtin/packages/pdt/package.py | 2 + .../repos/builtin/packages/pegtl/package.py | 2 + .../repos/builtin/packages/pennant/package.py | 2 + .../repos/builtin/packages/percept/package.py | 2 + .../packages/percona-server/package.py | 3 + .../builtin/packages/perfstubs/package.py | 4 + .../packages/perl-alien-build/package.py | 2 + .../packages/perl-alien-svn/package.py | 3 + .../builtin/packages/perl-bignum/package.py | 1 + .../builtin/packages/perl-bioperl/package.py | 2 + .../packages/perl-bit-vector/package.py | 2 + .../builtin/packages/perl-cairo/package.py | 1 + .../perl-compress-raw-bzip2/package.py | 3 + .../perl-compress-raw-zlib/package.py | 3 + .../packages/perl-config-general/package.py | 2 + .../packages/perl-data-stag/package.py | 2 + .../builtin/packages/perl-db-file/package.py | 3 + .../packages/perl-dbd-mysql/package.py | 31 +- .../packages/perl-dbd-oracle/package.py | 2 + .../builtin/packages/perl-dbd-pg/package.py | 3 + .../packages/perl-dbd-sqlite/package.py | 3 + .../packages/perl-devel-cover/package.py | 1 + .../packages/perl-devel-stacktrace/package.py | 1 + .../packages/perl-email-address-xs/package.py | 2 + .../packages/perl-extutils-config/package.py | 1 + .../perl-extutils-installpaths/package.py | 1 + .../builtin/packages/perl-fth/package.py | 6 +- .../repos/builtin/packages/perl-gd/package.py | 1 + .../packages/perl-gzip-faster/package.py | 2 + .../packages/perl-html-parser/package.py | 2 + .../packages/perl-html-tagset/package.py | 1 + .../packages/perl-http-message/package.py | 1 + .../packages/perl-http-parser-xs/package.py | 2 + .../packages/perl-http-tiny/package.py | 23 + .../packages/perl-io-socket-ssl/package.py | 3 +- .../builtin/packages/perl-io-tty/package.py | 1 + .../builtin/packages/perl-ipc-run/package.py | 3 + .../packages/perl-ipc-sharelite/package.py | 2 + .../builtin/packages/perl-json/package.py | 9 + .../packages/perl-math-bigint/package.py | 1 + .../builtin/packages/perl-math-cdf/package.py | 2 + .../packages/perl-math-cephes/package.py | 2 + .../builtin/packages/perl-mce/package.py | 1 + .../perl-module-build-tiny/package.py | 1 + .../packages/perl-module-build/package.py | 1 + .../packages/perl-module-corelist/package.py | 3 + .../builtin/packages/perl-moose/package.py | 3 + .../builtin/packages/perl-net-http/package.py | 1 + .../packages/perl-net-ssleay/package.py | 2 + .../packages/perl-parse-recdescent/package.py | 2 + .../packages/perl-path-tiny/package.py | 1 + .../packages/perl-perl-version/package.py | 1 + .../perl-proc-processtable/package.py | 2 + .../packages/perl-sereal-decoder/package.py | 2 + .../packages/perl-sereal-encoder/package.py | 2 + .../packages/perl-set-intervaltree/package.py | 2 + .../packages/perl-string-approx/package.py | 2 + .../packages/perl-string-crc32/package.py | 2 + .../packages/perl-sub-exporter/package.py | 1 + .../builtin/packages/perl-sub-name/package.py | 1 + .../perl-term-readline-gnu/package.py | 1 + .../packages/perl-test-differences/package.py | 1 + .../packages/perl-test-warnings/package.py | 1 + .../builtin/packages/perl-text-csv/package.py | 1 + .../repos/builtin/packages/perl-tk/package.py | 3 + .../packages/perl-xml-hash-xs/package.py | 2 + .../packages/perl-xml-libxml/package.py | 6 + .../packages/perl-xml-libxslt/package.py | 3 + .../packages/perl-xml-parser/package.py | 5 +- .../packages/perl-yaml-libyaml/package.py | 3 + .../packages/perl-yaml-syck/package.py | 2 + .../repos/builtin/packages/perl/package.py | 145 ++- .../repos/builtin/packages/pestpp/package.py | 5 + .../repos/builtin/packages/petaca/package.py | 7 + .../repos/builtin/packages/petsc/package.py | 20 +- .../repos/builtin/packages/pexsi/package.py | 4 + .../repos/builtin/packages/pfapack/package.py | 4 + .../repos/builtin/packages/pfft/package.py | 3 + .../repos/builtin/packages/pflask/package.py | 2 + .../builtin/packages/pflogger/package.py | 5 + .../builtin/packages/pflotran/package.py | 4 + .../repos/builtin/packages/pfunit/package.py | 3 + .../builtin/packages/pgi/detection_test.yaml | 11 + .../repos/builtin/packages/pgi/package.py | 9 +- .../repos/builtin/packages/pgplot/package.py | 3 + .../repos/builtin/packages/phast/package.py | 2 + .../repos/builtin/packages/phasta/package.py | 4 + .../repos/builtin/packages/phist/package.py | 4 + .../builtin/packages/photos-f/package.py | 2 + .../repos/builtin/packages/photos/package.py | 3 + .../builtin/packages/photospline/package.py | 3 + .../repos/builtin/packages/php/package.py | 3 + .../builtin/packages/phylobayesmpi/package.py | 3 + .../repos/builtin/packages/picsar/package.py | 4 + .../builtin/packages/picsarlite/package.py | 3 + .../repos/builtin/packages/pidx/package.py | 3 + .../repos/builtin/packages/pigz/package.py | 2 + .../packages/pika-algorithms/package.py | 2 + .../repos/builtin/packages/pika/package.py | 14 + .../repos/builtin/packages/pilercr/package.py | 2 + .../repos/builtin/packages/pindel/package.py | 2 + .../builtin/packages/pinentry/package.py | 6 + .../repos/builtin/packages/pinfo/package.py | 2 + .../repos/builtin/packages/piranha/package.py | 2 + .../repos/builtin/packages/pism/package.py | 4 + .../repos/builtin/packages/pixman/package.py | 16 +- .../repos/builtin/packages/pixz/package.py | 2 + .../builtin/packages/pkg-config/package.py | 10 +- .../repos/builtin/packages/pkgconf/package.py | 7 +- .../repos/builtin/packages/pktools/package.py | 3 + .../packages/planck-likelihood/package.py | 13 +- .../repos/builtin/packages/plasma/package.py | 3 + .../repos/builtin/packages/plink2/package.py | 15 +- .../builtin/packages/ploticus/package.py | 2 + .../repos/builtin/packages/plplot/package.py | 4 + .../repos/builtin/packages/plumed/package.py | 4 + .../repos/builtin/packages/ply/package.py | 2 + .../repos/builtin/packages/pmdk/package.py | 3 + .../repos/builtin/packages/pmemkv/package.py | 3 + .../repos/builtin/packages/pmerge/package.py | 2 + .../packages/pmgr-collective/package.py | 2 + .../repos/builtin/packages/pmix/package.py | 132 ++- .../repos/builtin/packages/pmlib/package.py | 4 + .../repos/builtin/packages/pnfft/package.py | 3 + .../builtin/packages/pngquant/package.py | 2 + .../builtin/packages/pngwriter/package.py | 2 + .../repos/builtin/packages/pnmpi/package.py | 4 + .../repos/builtin/packages/poamsa/package.py | 2 + .../repos/builtin/packages/pocl/package.py | 3 + .../repos/builtin/packages/podio/cpack.patch | 11 - .../builtin/packages/podio/dictloading.patch | 20 - .../repos/builtin/packages/podio/package.py | 117 +-- .../builtin/packages/podio/python-tests.patch | 12 - .../repos/builtin/packages/podman/package.py | 2 + .../repos/builtin/packages/poke/package.py | 2 + .../builtin/packages/polymake/package.py | 4 + .../repos/builtin/packages/poorjit/package.py | 30 + .../repos/builtin/packages/poppler/package.py | 3 + .../repos/builtin/packages/popt/package.py | 2 + .../repos/builtin/packages/portage/package.py | 2 + .../builtin/packages/portcullis/package.py | 3 + .../builtin/packages/ports-of-call/package.py | 2 + .../repos/builtin/packages/postgis/package.py | 3 + .../builtin/packages/postgresql/package.py | 62 +- .../repos/builtin/packages/povray/package.py | 3 + .../builtin/packages/powerapi/package.py | 3 + .../repos/builtin/packages/ppl/package.py | 3 + .../packages/ppopen-appl-amr-fdm/package.py | 2 + .../packages/ppopen-appl-bem-at/package.py | 2 + .../packages/ppopen-appl-bem/package.py | 2 + .../packages/ppopen-appl-dem-util/package.py | 2 + .../packages/ppopen-appl-fdm-at/package.py | 2 + .../packages/ppopen-appl-fdm/package.py | 4 + .../packages/ppopen-appl-fem/package.py | 3 + .../packages/ppopen-appl-fvm/package.py | 2 + .../builtin/packages/ppopen-at/package.py | 4 + .../packages/ppopen-math-mp/package.py | 2 + .../packages/ppopen-math-vis/package.py | 3 + .../repos/builtin/packages/prank/package.py | 2 + .../repos/builtin/packages/precice/package.py | 20 +- .../repos/builtin/packages/predixy/package.py | 3 + .../builtin/packages/premake-core/package.py | 3 + .../repos/builtin/packages/preseq/package.py | 3 + .../builtin/packages/prettier/package.py | 25 + .../repos/builtin/packages/price/package.py | 2 + .../repos/builtin/packages/primer3/package.py | 4 + .../repos/builtin/packages/prism/package.py | 3 + .../repos/builtin/packages/prmon/package.py | 1 + .../repos/builtin/packages/prng/package.py | 2 + .../builtin/packages/probconsrna/package.py | 2 + .../repos/builtin/packages/procenv/package.py | 2 + .../packages/process-in-process/package.py | 2 + .../builtin/packages/procps-ng/package.py | 2 + .../repos/builtin/packages/procps/package.py | 8 +- .../builtin/packages/prod-util/package.py | 20 +- .../builtin/packages/prodigal/package.py | 2 + .../builtin/packages/professor/package.py | 2 + .../builtin/packages/profugusmc/package.py | 4 + .../repos/builtin/packages/proj/package.py | 48 +- .../builtin/packages/proj/proj-7-tiff.patch | 19 + .../builtin/packages/proj/proj-8-tiff.patch | 19 + .../builtin/packages/prometheus/package.py | 2 + .../builtin/packages/prophecy4f/package.py | 3 + .../builtin/packages/protobuf-c/package.py | 3 + .../builtin/packages/protobuf/package.py | 7 +- .../builtin/packages/proxymngr/package.py | 3 + .../repos/builtin/packages/prrte/package.py | 2 + .../builtin/packages/pruners-ninja/package.py | 3 + .../repos/builtin/packages/ps-lite/package.py | 2 + .../repos/builtin/packages/psalg/package.py | 3 + .../repos/builtin/packages/pscmc/package.py | 2 + .../repos/builtin/packages/psi4/package.py | 2 + .../repos/builtin/packages/psipred/package.py | 2 + .../repos/builtin/packages/pslib/package.py | 2 + .../repos/builtin/packages/psm/package.py | 2 + .../repos/builtin/packages/psmc/package.py | 2 + .../repos/builtin/packages/psrcat/package.py | 2 + .../builtin/packages/psrchive/package.py | 4 + .../repos/builtin/packages/psrdada/package.py | 32 + .../builtin/packages/pstreams/package.py | 2 + .../builtin/packages/pthreadpool/package.py | 3 + .../repos/builtin/packages/pugixml/package.py | 3 + .../builtin/packages/pulseaudio/package.py | 3 + .../repos/builtin/packages/pumi/package.py | 61 +- .../repos/builtin/packages/pv/package.py | 2 + .../repos/builtin/packages/pvm/package.py | 3 + .../repos/builtin/packages/pwgen/package.py | 2 + .../repos/builtin/packages/pxz/package.py | 2 + .../builtin/packages/py-4suite-xml/package.py | 2 + .../builtin/packages/py-accimage/package.py | 2 + .../builtin/packages/py-adios/package.py | 4 + .../builtin/packages/py-aiohttp/package.py | 10 +- .../builtin/packages/py-alabaster/package.py | 5 +- .../builtin/packages/py-alphafold/package.py | 2 +- .../builtin/packages/py-amici/package.py | 3 + .../builtin/packages/py-amplpy/package.py | 2 + .../repos/builtin/packages/py-amqp/package.py | 8 + .../builtin/packages/py-amrex/package.py | 54 +- .../builtin/packages/py-angel/package.py | 2 + .../builtin/packages/py-annoy/package.py | 2 + .../builtin/packages/py-anuga/package.py | 4 + .../builtin/packages/py-archspec/package.py | 1 + .../py-argon2-cffi-bindings/package.py | 2 + .../builtin/packages/py-arm-pyart/package.py | 4 + .../builtin/packages/py-arrow/package.py | 8 +- .../builtin/packages/py-asgiref/package.py | 30 +- .../builtin/packages/py-astor/package.py | 4 +- .../packages/py-astropy-healpix/package.py | 4 + .../packages/py-astropy-helpers/package.py | 2 + .../packages/py-astropy-iers-data/package.py | 30 + .../builtin/packages/py-astropy/package.py | 17 +- .../builtin/packages/py-asyncio/package.py | 2 + .../builtin/packages/py-atropos/package.py | 2 + .../repos/builtin/packages/py-ats/package.py | 3 + .../builtin/packages/py-auditwheel/package.py | 4 + .../builtin/packages/py-autograd/package.py | 8 +- .../builtin/packages/py-autoray/package.py | 9 + .../packages/py-awkward-cpp/package.py | 2 + .../builtin/packages/py-awscrt/package.py | 8 +- .../builtin/packages/py-azure-cli/package.py | 2 +- .../packages/py-azure-mgmt-storage/package.py | 2 + .../py-azureml-automl-core/package.py | 6 +- .../packages/py-azureml-core/package.py | 18 +- .../py-azureml-dataprep-native/package.py | 6 +- .../py-azureml-dataprep-rslex/package.py | 10 +- .../packages/py-azureml-dataprep/package.py | 12 +- .../py-azureml-dataset-runtime/package.py | 6 +- .../py-azureml-pipeline-core/package.py | 18 +- .../py-azureml-pipeline-steps/package.py | 6 +- .../packages/py-azureml-pipeline/package.py | 6 +- .../packages/py-azureml-sdk/package.py | 6 +- .../packages/py-azureml-telemetry/package.py | 18 +- .../py-azureml-train-automl-client/package.py | 6 +- .../packages/py-azureml-train-core/package.py | 18 +- .../package.py | 18 +- .../packages/py-azureml-train/package.py | 18 +- .../builtin/packages/py-babel/package.py | 10 +- .../packages/py-backports-lzma/package.py | 2 + .../packages/py-backports-zoneinfo/package.py | 2 + .../builtin/packages/py-basemap/package.py | 3 + .../builtin/packages/py-bcolz/package.py | 3 + .../builtin/packages/py-bcrypt/package.py | 2 + .../builtin/packages/py-beancount/package.py | 2 + .../builtin/packages/py-bigdft/package.py | 4 + .../builtin/packages/py-bigfloat/package.py | 2 + .../builtin/packages/py-billiard/package.py | 3 + .../builtin/packages/py-biopython/package.py | 12 +- .../builtin/packages/py-bitarray/package.py | 2 + .../builtin/packages/py-bitshuffle/package.py | 2 + .../builtin/packages/py-bitstruct/package.py | 2 + .../builtin/packages/py-black/package.py | 3 +- .../repos/builtin/packages/py-blis/package.py | 2 + .../builtin/packages/py-blosc/package.py | 7 +- .../builtin/packages/py-blosc2/package.py | 7 +- .../builtin/packages/py-bluepyopt/package.py | 4 +- .../builtin/packages/py-bokeh/package.py | 2 + .../packages/py-boost-histogram/package.py | 4 + .../builtin/packages/py-bottleneck/package.py | 4 + .../packages/py-bravado-core/package.py | 34 + .../builtin/packages/py-bravado/package.py | 31 + .../builtin/packages/py-breathe/package.py | 3 + .../builtin/packages/py-brian/package.py | 3 + .../builtin/packages/py-brian2/package.py | 3 + .../builtin/packages/py-brotli/package.py | 2 + .../builtin/packages/py-brotlipy/package.py | 2 + .../builtin/packages/py-bsddb3/package.py | 2 + .../builtin/packages/py-bx-python/package.py | 2 + .../builtin/packages/py-carputils/package.py | 5 +- .../builtin/packages/py-cartopy/package.py | 113 ++- .../builtin/packages/py-casadi/package.py | 4 + .../builtin/packages/py-celery/package.py | 29 +- .../builtin/packages/py-cf-units/package.py | 2 + .../repos/builtin/packages/py-cffi/package.py | 2 + .../builtin/packages/py-chainer/package.py | 4 +- .../builtin/packages/py-cheetah3/package.py | 2 + .../builtin/packages/py-chemfiles/package.py | 7 +- .../builtin/packages/py-cig-pythia/package.py | 47 + .../builtin/packages/py-climate/package.py | 6 +- .../packages/py-cloudpickle/package.py | 6 +- .../builtin/packages/py-cmake/package.py | 19 +- .../builtin/packages/py-codepy/package.py | 2 + .../builtin/packages/py-colored/package.py | 4 +- .../packages/py-configspace/package.py | 10 + .../builtin/packages/py-contourpy/package.py | 4 + .../packages/py-correctionlib/package.py | 4 +- .../builtin/packages/py-coverage/package.py | 2 + .../builtin/packages/py-crcmod/package.py | 2 + .../packages/py-cryptography/package.py | 3 + .../repos/builtin/packages/py-cudf/package.py | 2 + .../repos/builtin/packages/py-cuml/package.py | 2 + .../repos/builtin/packages/py-cupy/package.py | 13 +- .../builtin/packages/py-cvxopt/package.py | 2 + .../builtin/packages/py-cvxpy/package.py | 2 + .../builtin/packages/py-cx-oracle/package.py | 2 + .../repos/builtin/packages/py-cylp/package.py | 2 + .../packages/py-cyordereddict/package.py | 2 + .../packages/py-cython-bbox/package.py | 2 + .../builtin/packages/py-cython/package.py | 4 + .../builtin/packages/py-cyvcf2/package.py | 2 + .../builtin/packages/py-d2to1/package.py | 2 + .../repos/builtin/packages/py-dace/package.py | 2 + .../repos/builtin/packages/py-dadi/package.py | 2 + .../builtin/packages/py-damask/package.py | 3 + .../builtin/packages/py-darshan/package.py | 9 +- .../repos/builtin/packages/py-dask/package.py | 4 + .../builtin/packages/py-datasets/package.py | 64 +- .../builtin/packages/py-datrie/package.py | 2 + .../repos/builtin/packages/py-deap/package.py | 3 + .../builtin/packages/py-deephyper/package.py | 16 +- .../builtin/packages/py-deepspeed/package.py | 4 +- .../packages/py-deeptoolsintervals/package.py | 2 + .../builtin/packages/py-devlib/package.py | 2 + .../repos/builtin/packages/py-dgl/package.py | 4 + .../repos/builtin/packages/py-dipy/package.py | 2 + .../builtin/packages/py-distance/package.py | 2 + .../builtin/packages/py-distlib/package.py | 2 + .../builtin/packages/py-django/package.py | 31 +- .../packages/py-dlio-profiler-py/package.py | 19 +- .../builtin/packages/py-dm-tree/package.py | 2 + .../repos/builtin/packages/py-doit/package.py | 2 + .../packages/py-dotnetcore2/package.py | 4 +- .../builtin/packages/py-dulwich/package.py | 2 + .../builtin/packages/py-eccodes/package.py | 2 +- .../builtin/packages/py-ecmwflibs/package.py | 3 + .../repos/builtin/packages/py-ecos/package.py | 2 + .../builtin/packages/py-editables/package.py | 5 +- .../packages/py-editdistance/package.py | 2 + .../builtin/packages/py-edlib/package.py | 2 + .../repos/builtin/packages/py-efel/package.py | 2 + .../builtin/packages/py-einops/package.py | 2 + .../builtin/packages/py-elephant/package.py | 2 + .../builtin/packages/py-ephem/package.py | 2 + .../packages/py-eprosima-fastdds/package.py | 2 + .../builtin/packages/py-espresso/package.py | 2 + .../builtin/packages/py-espressopp/package.py | 3 + .../repos/builtin/packages/py-ete3/package.py | 2 + .../builtin/packages/py-exarl/package.py | 2 + .../packages/py-exodus-bundler/package.py | 2 + .../packages/py-extension-helpers/package.py | 2 + .../builtin/packages/py-f90wrap/package.py | 3 + .../builtin/packages/py-fallocate/package.py | 2 + .../builtin/packages/py-fastcache/package.py | 2 + .../packages/py-fastcluster/package.py | 2 + .../builtin/packages/py-fastdtw/package.py | 2 + .../builtin/packages/py-fastfold/package.py | 2 + .../builtin/packages/py-fastpath/package.py | 2 + .../builtin/packages/py-fastremap/package.py | 2 + .../builtin/packages/py-fastrlock/package.py | 2 + .../packages/py-faststructure/package.py | 2 + .../packages/py-fenics-basix/package.py | 23 +- .../packages/py-fenics-dolfinx/package.py | 45 +- .../builtin/packages/py-fenics-ffc/package.py | 2 + .../packages/py-fenics-ffcx/package.py | 25 +- .../builtin/packages/py-fenics-ufl/package.py | 3 + .../builtin/packages/py-flash-attn/package.py | 50 + .../packages/py-flatbuffers/package.py | 1 + .../builtin/packages/py-flawfinder/package.py | 3 + .../repos/builtin/packages/py-flye/package.py | 3 + .../builtin/packages/py-folium/package.py | 25 + .../repos/builtin/packages/py-ford/package.py | 2 + .../builtin/packages/py-fortls/package.py | 7 +- .../py-fortran-language-server/package.py | 2 + .../builtin/packages/py-fparser/package.py | 2 + .../builtin/packages/py-frozendict/package.py | 2 + .../builtin/packages/py-frozenlist/package.py | 2 + .../builtin/packages/py-fsspec/package.py | 6 +- .../builtin/packages/py-gdown/package.py | 28 + .../builtin/packages/py-genders/package.py | 3 + .../builtin/packages/py-genshi/package.py | 2 + .../builtin/packages/py-gensim/package.py | 3 + .../builtin/packages/py-geopmdpy/package.py | 54 ++ .../builtin/packages/py-geopmpy/package.py | 41 + .../builtin/packages/py-gevent/package.py | 2 + .../builtin/packages/py-gimmik/package.py | 1 + .../packages/py-glmnet-python/package.py | 29 + .../builtin/packages/py-glmnet/package.py | 2 + .../builtin/packages/py-globus-cli/package.py | 28 + .../builtin/packages/py-globus-sdk/package.py | 4 +- .../builtin/packages/py-gmxapi/package.py | 5 +- .../packages/py-google-crc32c/package.py | 2 + .../py-googleapis-common-protos/package.py | 29 +- .../builtin/packages/py-gosam/package.py | 4 + .../repos/builtin/packages/py-gpaw/package.py | 4 +- .../repos/builtin/packages/py-gpy/package.py | 2 + .../builtin/packages/py-grapheme/package.py | 2 + .../builtin/packages/py-greenlet/package.py | 3 + .../packages/py-griddataformats/package.py | 7 +- .../packages/py-grpcio-status/package.py | 12 +- .../packages/py-grpcio-tools/package.py | 9 + .../builtin/packages/py-grpcio/30522.diff | 21 + .../builtin/packages/py-grpcio/package.py | 48 +- .../repos/builtin/packages/py-gsd/package.py | 5 +- .../builtin/packages/py-gtdbtk/package.py | 2 +- .../repos/builtin/packages/py-h5py/package.py | 14 +- .../builtin/packages/py-hatchet/package.py | 2 + .../builtin/packages/py-healpy/package.py | 4 + .../repos/builtin/packages/py-heat/package.py | 28 +- .../packages/py-hepdata-lib/package.py | 2 + .../builtin/packages/py-hiredis/package.py | 2 + .../builtin/packages/py-hmmlearn/package.py | 2 + .../builtin/packages/py-horovod/package.py | 4 + .../builtin/packages/py-htseq/package.py | 3 + .../builtin/packages/py-httpstan/package.py | 2 + .../builtin/packages/py-httptools/package.py | 2 + .../packages/py-huggingface-hub/package.py | 1 + .../builtin/packages/py-humanize/package.py | 7 + .../builtin/packages/py-hypothesis/package.py | 54 +- .../builtin/packages/py-igor2/package.py | 6 +- .../builtin/packages/py-igraph/package.py | 4 + .../builtin/packages/py-ilmbase/package.py | 2 + .../packages/py-imagecodecs/package.py | 5 + .../builtin/packages/py-imageio/package.py | 3 + .../builtin/packages/py-iminuit/package.py | 6 +- .../builtin/packages/py-immutables/package.py | 2 + .../builtin/packages/py-installer/package.py | 16 +- .../builtin/packages/py-intbitset/package.py | 2 + .../packages/py-intel-openmp/package.py | 2 - .../builtin/packages/py-ipykernel/package.py | 10 +- .../builtin/packages/py-ipython/package.py | 27 +- .../repos/builtin/packages/py-isal/package.py | 2 + .../repos/builtin/packages/py-itk/package.py | 16 +- .../builtin/packages/py-janus/package.py | 23 + .../packages/py-jarowinkler/package.py | 2 + .../repos/builtin/packages/py-jax/package.py | 140 ++- .../builtin/packages/py-jaxlib/package.py | 120 ++- .../repos/builtin/packages/py-jcb/package.py | 39 + .../repos/builtin/packages/py-jedi/package.py | 2 + .../builtin/packages/py-jellyfish/package.py | 2 + .../packages/py-jproperties/package.py | 31 + .../builtin/packages/py-jpype1/package.py | 3 + .../packages/py-jsonargparse/package.py | 1 + .../builtin/packages/py-junit2html/package.py | 23 + .../py-jupyterlab-pygments/package.py | 18 +- .../packages/py-jupyterlab-widgets/package.py | 18 +- .../builtin/packages/py-jupytext/package.py | 2 + .../builtin/packages/py-kaleido/package.py | 63 +- .../builtin/packages/py-keras/package.py | 117 ++- .../builtin/packages/py-kerberos/package.py | 2 + .../builtin/packages/py-kiwisolver/package.py | 2 + .../builtin/packages/py-kneaddata/package.py | 35 + .../builtin/packages/py-kombu/package.py | 26 +- .../builtin/packages/py-kornia-rs/package.py | 43 + .../builtin/packages/py-kornia/package.py | 17 +- .../builtin/packages/py-langsmith/package.py | 5 + .../repos/builtin/packages/py-lap/package.py | 2 + .../builtin/packages/py-laspy/package.py | 2 + .../packages/py-lazy-loader/package.py | 8 +- .../packages/py-lazy-object-proxy/package.py | 2 + .../packages/py-libensemble/package.py | 8 +- .../builtin/packages/py-libsonata/package.py | 36 + .../builtin/packages/py-lightgbm/package.py | 5 + .../builtin/packages/py-lightly/package.py | 2 + .../py-lightning-api-access/package.py | 6 +- .../builtin/packages/py-lightning/package.py | 148 +-- .../packages/py-ligo-segments/package.py | 2 + .../py-line-profiler/gettimeofday_py39.patch | 24 + .../packages/py-line-profiler/package.py | 17 +- .../builtin/packages/py-llnl-sina/package.py | 2 + .../builtin/packages/py-llvmlite/package.py | 2 + .../repos/builtin/packages/py-lmdb/package.py | 2 + .../builtin/packages/py-lru-dict/package.py | 2 + .../packages/py-lscsoft-glue/package.py | 2 + .../repos/builtin/packages/py-lws/package.py | 2 + .../repos/builtin/packages/py-lxml/package.py | 2 + .../repos/builtin/packages/py-lz4/package.py | 2 + .../builtin/packages/py-macs2/package.py | 2 + .../builtin/packages/py-macs3/package.py | 2 + .../builtin/packages/py-mahotas/package.py | 2 + .../packages/py-mapbox-earcut/package.py | 2 + .../builtin/packages/py-mariadb/package.py | 2 + .../builtin/packages/py-markupsafe/package.py | 2 + .../py-matplotlib/freetype-include-path.patch | 16 - .../builtin/packages/py-matplotlib/package.py | 204 ++-- .../builtin/packages/py-maturin/package.py | 28 +- .../builtin/packages/py-mayavi/package.py | 3 + .../builtin/packages/py-mdanalysis/package.py | 7 +- .../builtin/packages/py-meldmd/package.py | 2 + .../packages/py-melissa-core/package.py | 3 + .../builtin/packages/py-memray/package.py | 3 + .../builtin/packages/py-merlin/package.py | 2 + .../builtin/packages/py-meshpy/package.py | 2 + .../packages/py-meson-python/package.py | 11 +- .../packages/py-metomi-rose/package.py | 2 + .../builtin/packages/py-metpy/package.py | 3 +- .../builtin/packages/py-mikado/package.py | 2 + .../packages/py-minkowskiengine/package.py | 2 + .../builtin/packages/py-misopy/package.py | 2 + .../builtin/packages/py-ml-dtypes/package.py | 9 +- .../builtin/packages/py-mlflow/package.py | 4 +- .../repos/builtin/packages/py-mmcv/package.py | 2 + .../builtin/packages/py-mne-bids/package.py | 29 + .../repos/builtin/packages/py-mne/package.py | 12 +- .../builtin/packages/py-modin/package.py | 2 + .../packages/py-modules-gui/package.py | 25 + .../builtin/packages/py-morphio/package.py | 8 +- .../builtin/packages/py-mpi4py/package.py | 8 +- .../builtin/packages/py-mpmath/package.py | 4 +- .../builtin/packages/py-mrcfile/package.py | 4 +- .../builtin/packages/py-msgpack/package.py | 2 + .../builtin/packages/py-multidict/package.py | 2 + .../builtin/packages/py-multiecho/package.py | 7 +- .../builtin/packages/py-multiqc/package.py | 51 +- .../builtin/packages/py-murmurhash/package.py | 2 + .../repos/builtin/packages/py-mx/package.py | 2 + .../builtin/packages/py-mxfold2/package.py | 2 + .../builtin/packages/py-myhdl/package.py | 2 + .../repos/builtin/packages/py-mypy/package.py | 3 + .../py-mysql-connector-python/package.py | 3 + .../packages/py-mysqlclient/package.py | 2 + .../builtin/packages/py-mysqldb1/package.py | 2 + .../builtin/packages/py-namex/package.py | 1 + .../builtin/packages/py-nanobind/package.py | 15 +- .../builtin/packages/py-natsort/package.py | 2 + .../builtin/packages/py-neobolt/package.py | 2 + .../packages/py-neptune-client/package.py | 43 + .../packages/py-nest-asyncio/package.py | 3 + .../builtin/packages/py-netcdf4/package.py | 16 + .../builtin/packages/py-netifaces/package.py | 2 + .../builtin/packages/py-netket/package.py | 4 +- .../builtin/packages/py-networkit/package.py | 2 + .../builtin/packages/py-networkx/package.py | 2 + .../builtin/packages/py-nibabel/package.py | 8 +- .../builtin/packages/py-nilearn/package.py | 9 +- .../builtin/packages/py-ninja/package.py | 11 +- .../builtin/packages/py-nodeenv/package.py | 1 + .../builtin/packages/py-nuitka/package.py | 27 + .../builtin/packages/py-numba/package.py | 3 + .../builtin/packages/py-numcodecs/package.py | 4 + .../builtin/packages/py-numexpr/package.py | 10 +- .../builtin/packages/py-numexpr3/package.py | 3 + .../packages/py-numpy-quaternion/package.py | 2 + .../builtin/packages/py-numpy-stl/package.py | 2 + .../builtin/packages/py-numpy/package.py | 83 +- .../packages/py-nvidia-dali/package.py | 83 +- .../builtin/packages/py-obspy/package.py | 39 + .../packages/py-okada-wrapper/package.py | 30 + .../repos/builtin/packages/py-onnx/package.py | 14 +- .../packages/py-onnxruntime/package.py | 4 + .../packages/py-opencensus-context/package.py | 6 +- .../builtin/packages/py-openmc/package.py | 12 +- .../builtin/packages/py-openmesh/package.py | 3 + .../packages/py-openslide-python/package.py | 2 + .../builtin/packages/py-opentuner/package.py | 2 + .../builtin/packages/py-optree/package.py | 25 + .../builtin/packages/py-or-tools/package.py | 2 + .../builtin/packages/py-oracledb/package.py | 2 + .../packages/py-ordered-set/package.py | 5 +- .../builtin/packages/py-orjson/package.py | 15 +- .../repos/builtin/packages/py-osqp/package.py | 2 + .../builtin/packages/py-pandas/package.py | 21 +- .../builtin/packages/py-parmed/package.py | 2 + .../builtin/packages/py-parsl/package.py | 2 + .../builtin/packages/py-partd/package.py | 7 +- .../repos/builtin/packages/py-pbr/package.py | 2 + .../builtin/packages/py-pdm-pep517/package.py | 2 + .../builtin/packages/py-peachpy/package.py | 3 + .../py-pennylane-lightning-kokkos/package.py | 49 +- .../py-pennylane-lightning/package.py | 35 +- .../builtin/packages/py-pennylane/package.py | 28 +- .../builtin/packages/py-petsc4py/package.py | 14 +- .../builtin/packages/py-pexpect/package.py | 2 + .../builtin/packages/py-phanotate/package.py | 2 + .../builtin/packages/py-phonopy/package.py | 2 + .../builtin/packages/py-photutils/package.py | 2 + .../builtin/packages/py-phydms/package.py | 2 + .../builtin/packages/py-phylophlan/package.py | 2 +- .../builtin/packages/py-pickle5/package.py | 2 + .../packages/py-pillow-simd/package.py | 4 +- .../builtin/packages/py-pillow/package.py | 57 +- .../repos/builtin/packages/py-pint/package.py | 1 + .../repos/builtin/packages/py-pip/package.py | 104 +- .../repos/builtin/packages/py-pivy/package.py | 2 + .../builtin/packages/py-plotly/package.py | 9 +- .../builtin/packages/py-pluggy/package.py | 18 +- .../packages/py-poetry-core/package.py | 2 + .../builtin/packages/py-poetry/package.py | 4 +- .../packages/py-pomegranate/package.py | 2 + .../repos/builtin/packages/py-pot/package.py | 2 + .../packages/py-pretty-errors/package.py | 20 + .../builtin/packages/py-projectq/package.py | 2 + .../packages/py-prompt-toolkit/package.py | 1 + .../builtin/packages/py-protobuf/package.py | 6 + .../builtin/packages/py-psalg/package.py | 3 + .../builtin/packages/py-psana/package.py | 3 + .../builtin/packages/py-psutil/package.py | 2 + .../builtin/packages/py-psyclone/package.py | 2 + .../builtin/packages/py-psycopg2/package.py | 2 + .../builtin/packages/py-py-spy/package.py | 2 + .../builtin/packages/py-py2bit/package.py | 2 + .../repos/builtin/packages/py-py4j/package.py | 6 + .../builtin/packages/py-pyaml-env/package.py | 20 + .../builtin/packages/py-pyarrow/package.py | 12 +- .../builtin/packages/py-pybedtools/package.py | 3 + .../builtin/packages/py-pybigwig/package.py | 2 + .../builtin/packages/py-pybind11/package.py | 4 +- .../builtin/packages/py-pybrain/package.py | 2 + .../builtin/packages/py-pycairo/package.py | 2 + .../builtin/packages/py-pycares/package.py | 2 + .../builtin/packages/py-pycifrw/package.py | 2 + .../packages/py-pycocotools/package.py | 3 + .../builtin/packages/py-pycompadre/package.py | 4 + .../builtin/packages/py-pycortex/package.py | 2 + .../builtin/packages/py-pycparser/package.py | 2 + .../builtin/packages/py-pycrypto/package.py | 2 + .../packages/py-pycryptodome/package.py | 2 + .../builtin/packages/py-pycuda/package.py | 2 + .../builtin/packages/py-pycurl/package.py | 2 + .../builtin/packages/py-pyeda/package.py | 2 + .../builtin/packages/py-pyelftools/package.py | 3 + .../builtin/packages/py-pyerfa/package.py | 6 + .../builtin/packages/py-pyfits/package.py | 2 + .../repos/builtin/packages/py-pyfr/package.py | 40 +- .../builtin/packages/py-pygdal/package.py | 3 + .../builtin/packages/py-pygeos/package.py | 2 + .../builtin/packages/py-pygit2/package.py | 2 + .../builtin/packages/py-pygments/package.py | 16 +- .../builtin/packages/py-pygmt/package.py | 31 + .../builtin/packages/py-pygobject/package.py | 2 + .../builtin/packages/py-pygpu/package.py | 2 + .../builtin/packages/py-pyhdf/package.py | 49 + .../builtin/packages/py-pyheadtail/package.py | 3 + .../builtin/packages/py-pyhull/package.py | 2 + .../packages/py-pyinstrument-cext/package.py | 2 + .../packages/py-pyinstrument/package.py | 2 + .../builtin/packages/py-pykerberos/package.py | 2 + .../packages/py-pykokkos-base/package.py | 2 + .../builtin/packages/py-pylikwid/package.py | 2 + .../builtin/packages/py-pylith/package.py | 28 + .../builtin/packages/py-pymatgen/package.py | 5 + .../builtin/packages/py-pymol/package.py | 5 +- .../builtin/packages/py-pymongo/package.py | 2 + .../builtin/packages/py-pymoo/package.py | 2 + .../builtin/packages/py-pynacl/package.py | 2 + .../builtin/packages/py-pynio/package.py | 3 + .../repos/builtin/packages/py-pynn/package.py | 2 + .../builtin/packages/py-pynvtx/package.py | 2 + .../builtin/packages/py-pyodbc/package.py | 2 + .../builtin/packages/py-pyomo/package.py | 10 +- .../builtin/packages/py-pyopencl/package.py | 2 + .../builtin/packages/py-pyopengl/package.py | 68 ++ .../builtin/packages/py-pypar/package.py | 2 + .../builtin/packages/py-pyparsing/package.py | 3 + .../builtin/packages/py-pyprecice/package.py | 2 + .../builtin/packages/py-pyqt4/package.py | 4 +- .../builtin/packages/py-pyqt5-sip/package.py | 10 + .../builtin/packages/py-pyqt5/package.py | 2 + .../builtin/packages/py-pyqt6-sip/package.py | 4 + .../builtin/packages/py-pyqt6/package.py | 11 +- .../builtin/packages/py-pyrevolve/package.py | 2 + .../builtin/packages/py-pyrfr/package.py | 2 + .../builtin/packages/py-pyro-ppl/package.py | 2 + .../builtin/packages/py-pyrocko/package.py | 33 + .../builtin/packages/py-pyrsistent/package.py | 2 + .../builtin/packages/py-pysam/package.py | 2 + .../builtin/packages/py-pyscf/package.py | 15 +- .../builtin/packages/py-pyscipopt/package.py | 2 + .../builtin/packages/py-pyseer/package.py | 31 + .../builtin/packages/py-pyside/package.py | 2 + .../builtin/packages/py-pyside2/package.py | 2 + .../builtin/packages/py-pysimdjson/package.py | 2 + .../builtin/packages/py-pyspark/package.py | 44 +- .../builtin/packages/py-pyspoa/package.py | 5 +- .../builtin/packages/py-pysqlite3/package.py | 2 + .../builtin/packages/py-pytest-cpp/package.py | 2 + .../builtin/packages/py-pytest-mpi/package.py | 21 + .../builtin/packages/py-pytest/package.py | 99 +- .../packages/py-python-crfsuite/package.py | 3 + .../packages/py-python-fmask/package.py | 5 + .../packages/py-python-javabridge/package.py | 2 + .../packages/py-python-json-logger/package.py | 1 + .../packages/py-python-ldap/package.py | 2 + .../packages/py-python-levenshtein/package.py | 2 + .../packages/py-python-libsbml/package.py | 3 + .../packages/py-python-lsp-jsonrpc/package.py | 4 + .../packages/py-python-lsp-server/package.py | 13 +- .../builtin/packages/py-python-lzo/package.py | 2 + .../packages/py-python-mapnik/package.py | 2 + .../packages/py-python-ptrace/package.py | 2 + .../packages/py-python-rapidjson/package.py | 2 + .../packages/py-pythonsollya/package.py | 7 +- .../builtin/packages/py-pythran/package.py | 18 +- .../builtin/packages/py-pytng/package.py | 3 + .../packages/py-pytorch-lightning/package.py | 4 +- .../builtin/packages/py-pyuwsgi/package.py | 3 + .../builtin/packages/py-pyvista/package.py | 2 + .../builtin/packages/py-pywavelets/package.py | 4 + .../builtin/packages/py-pywcs/package.py | 3 + .../builtin/packages/py-pywin32/package.py | 2 + .../builtin/packages/py-pyworld/package.py | 2 + .../builtin/packages/py-pyyaml/package.py | 1 + .../builtin/packages/py-pyzmq/package.py | 3 + .../builtin/packages/py-qdldl/package.py | 3 + .../builtin/packages/py-qiskit-aer/package.py | 4 +- .../packages/py-qiskit-nature/package.py | 2 + .../builtin/packages/py-qmtest/package.py | 3 + .../builtin/packages/py-quantiphy/package.py | 22 + .../packages/py-quantum-blackbird/package.py | 2 + .../builtin/packages/py-quast/package.py | 3 + .../builtin/packages/py-qutip/package.py | 4 + .../packages/py-radical-gtod/package.py | 2 + .../builtin/packages/py-rapidfuzz/package.py | 2 + .../builtin/packages/py-rarfile/package.py | 2 + .../builtin/packages/py-rasterio/package.py | 7 +- .../repos/builtin/packages/py-ray/package.py | 3 + .../builtin/packages/py-regex/package.py | 2 + .../builtin/packages/py-reproject/package.py | 2 + .../builtin/packages/py-requests/package.py | 1 + .../repos/builtin/packages/py-rich/package.py | 2 + .../repos/builtin/packages/py-rios/package.py | 27 +- .../builtin/packages/py-river/package.py | 2 + .../repos/builtin/packages/py-rmm/package.py | 2 + .../builtin/packages/py-rtree/package.py | 10 +- .../packages/py-ruamel-ordereddict/package.py | 2 + .../packages/py-ruamel-yaml-clib/package.py | 2 + .../repos/builtin/packages/py-ruff/package.py | 12 +- .../packages/py-safetensors/package.py | 2 + .../builtin/packages/py-scandir/package.py | 2 + .../packages/py-scientificpython/package.py | 2 + .../packages/py-scikit-build-core/package.py | 34 +- .../packages/py-scikit-build/package.py | 3 + .../builtin/packages/py-scikit-fmm/package.py | 2 + .../packages/py-scikit-image/package.py | 157 +-- .../packages/py-scikit-learn-extra/package.py | 5 +- .../packages/py-scikit-learn/package.py | 137 ++- .../packages/py-scikit-sparse/package.py | 2 + .../packages/py-scikits-odes/package.py | 3 + .../builtin/packages/py-scipy/package.py | 124 ++- .../repos/builtin/packages/py-scs/package.py | 2 + .../builtin/packages/py-seaborn/package.py | 3 + .../packages/py-sentencepiece/package.py | 2 + .../packages/py-setproctitle/package.py | 2 + .../packages/py-setuptools-rust/package.py | 7 +- .../packages/py-setuptools-scm/package.py | 11 + .../builtin/packages/py-setuptools/package.py | 234 +---- .../builtin/packages/py-sfepy/package.py | 2 + .../repos/builtin/packages/py-shap/package.py | 2 + .../builtin/packages/py-shapely/package.py | 8 +- .../builtin/packages/py-shiboken/package.py | 2 + .../builtin/packages/py-shiboken2/package.py | 4 +- .../builtin/packages/py-shroud/package.py | 4 + .../builtin/packages/py-simpleeval/package.py | 3 +- .../builtin/packages/py-simplejson/package.py | 2 + .../builtin/packages/py-simpletraj/package.py | 2 + .../builtin/packages/py-simpy/package.py | 21 + .../repos/builtin/packages/py-sip/package.py | 13 +- .../builtin/packages/py-slepc4py/package.py | 5 +- .../builtin/packages/py-smartredis/package.py | 3 + .../builtin/packages/py-smartsim/package.py | 2 +- .../builtin/packages/py-sncosmo/package.py | 2 + .../builtin/packages/py-sonlib/package.py | 3 + .../builtin/packages/py-spacy/package.py | 2 + .../builtin/packages/py-spdlog/package.py | 2 + .../builtin/packages/py-spglib/package.py | 4 + .../packages/py-sphinx-immaterial/package.py | 2 + .../builtin/packages/py-sphinx/package.py | 120 ++- .../builtin/packages/py-srsly/package.py | 3 + .../packages/py-statsmodels/package.py | 5 + .../builtin/packages/py-storm/package.py | 2 + .../builtin/packages/py-stratify/package.py | 2 + .../packages/py-stsci-distutils/package.py | 2 + .../py-swagger-spec-validator/package.py | 24 + .../builtin/packages/py-symengine/package.py | 2 + .../packages/py-systemd-python/package.py | 2 + .../builtin/packages/py-tables/package.py | 5 + .../builtin/packages/py-tabulate/package.py | 6 +- .../builtin/packages/py-tatsu/package.py | 5 + .../py-tensorboard-plugin-wit/package.py | 18 +- .../packages/py-tensorboard/package.py | 232 ++--- .../py-tensorflow-estimator/package.py | 61 +- .../py-tensorflow-probability/package.py | 21 +- .../packages/py-tensorflow/absl_neon.patch | 55 ++ .../builtin/packages/py-tensorflow/package.py | 438 +++++---- .../packages/py-tensorstore/package.py | 2 + .../builtin/packages/py-tesorter/package.py | 19 +- .../builtin/packages/py-tfdlpack/package.py | 3 + .../builtin/packages/py-theano/package.py | 2 + .../builtin/packages/py-thinc/package.py | 3 + .../repos/builtin/packages/py-thop/package.py | 1 - .../builtin/packages/py-tifffile/package.py | 2 + .../builtin/packages/py-tinyarray/package.py | 2 + .../builtin/packages/py-tokenizers/package.py | 1 + .../builtin/packages/py-tomopy/package.py | 3 + .../packages/py-torch-cluster/package.py | 40 +- .../packages/py-torch-geometric/package.py | 94 +- .../packages/py-torch-nvidia-apex/package.py | 18 +- .../packages/py-torch-scatter/package.py | 37 +- .../packages/py-torch-sparse/package.py | 62 +- .../packages/py-torch-spline-conv/package.py | 35 +- .../builtin/packages/py-torch/package.py | 281 +++--- .../builtin/packages/py-torchaudio/package.py | 15 +- .../builtin/packages/py-torchdata/package.py | 2 + .../builtin/packages/py-torchgeo/package.py | 2 + .../packages/py-torchmetrics/package.py | 32 +- .../builtin/packages/py-torchtext/package.py | 10 +- .../packages/py-torchvision/package.py | 15 +- .../builtin/packages/py-tornado/package.py | 2 + .../repos/builtin/packages/py-tqdm/package.py | 1 + .../builtin/packages/py-traitlets/package.py | 5 + .../builtin/packages/py-traits/package.py | 2 + .../packages/py-transformer-engine/package.py | 50 + .../packages/py-transformers/package.py | 59 +- .../builtin/packages/py-triangle/package.py | 2 + .../builtin/packages/py-triton/package.py | 12 + .../builtin/packages/py-trx-python/package.py | 28 + .../builtin/packages/py-tuiview/package.py | 5 + .../builtin/packages/py-tuswsgi/package.py | 6 +- .../builtin/packages/py-tweedledum/package.py | 6 +- .../builtin/packages/py-typed-ast/package.py | 2 + .../builtin/packages/py-ucx-py/package.py | 2 + .../repos/builtin/packages/py-uhi/package.py | 2 + .../builtin/packages/py-ujson/package.py | 3 + .../builtin/packages/py-umi-tools/package.py | 2 + .../builtin/packages/py-unicycler/package.py | 2 + .../builtin/packages/py-unshare/package.py | 2 + .../builtin/packages/py-urwid/package.py | 2 + .../builtin/packages/py-uvicorn/package.py | 1 - .../builtin/packages/py-uvloop/package.py | 12 +- .../builtin/packages/py-uwsgi/package.py | 3 + .../builtin/packages/py-vascpy/package.py | 33 + .../builtin/packages/py-versioneer/package.py | 2 + .../builtin/packages/py-virtualenv/package.py | 2 + .../packages/py-vl-convert-python/package.py | 20 +- .../builtin/packages/py-warpx/package.py | 6 +- .../builtin/packages/py-watchdog/package.py | 2 + .../builtin/packages/py-webcolors/package.py | 9 +- .../packages/py-webkit-server/package.py | 2 + .../builtin/packages/py-websockets/package.py | 2 + .../builtin/packages/py-whatshap/package.py | 2 + .../builtin/packages/py-wheel/package.py | 72 +- .../builtin/packages/py-wordcloud/package.py | 2 + .../py-workload-automation/package.py | 2 + .../builtin/packages/py-wrapt/package.py | 2 + .../builtin/packages/py-wxflow/package.py | 46 + .../builtin/packages/py-wxpython/package.py | 3 + .../repos/builtin/packages/py-x21/package.py | 6 - .../builtin/packages/py-xattr/package.py | 2 + .../repos/builtin/packages/py-xdot/package.py | 3 +- .../builtin/packages/py-xgboost/package.py | 4 + .../repos/builtin/packages/py-xpyb/package.py | 2 + .../repos/builtin/packages/py-xtb/package.py | 7 + .../builtin/packages/py-xxhash/package.py | 2 + .../repos/builtin/packages/py-yajl/package.py | 2 + .../repos/builtin/packages/py-yarl/package.py | 2 + .../repos/builtin/packages/py-your/package.py | 34 + .../repos/builtin/packages/py-yt/package.py | 5 + .../packages/py-ytopt-autotune/package.py | 2 + .../builtin/packages/py-ytopt/package.py | 3 + .../builtin/packages/py-z3-solver/package.py | 2 + .../repos/builtin/packages/py-zarr/package.py | 2 + .../repos/builtin/packages/py-zfit/package.py | 17 +- .../packages/py-zipfile-deflate64/package.py | 2 + .../packages/py-zope-interface/package.py | 2 + .../repos/builtin/packages/pygmo/package.py | 2 + .../packages/pypy-bootstrap/package.py | 2 + .../repos/builtin/packages/pypy/package.py | 3 + .../repos/builtin/packages/pythia6/package.py | 2 + .../repos/builtin/packages/pythia8/package.py | 36 +- .../builtin/packages/python-venv/package.py | 101 ++ .../repos/builtin/packages/python/package.py | 163 ++-- .../builtin/packages/q-e-sirius/package.py | 14 +- .../repos/builtin/packages/qb3/package.py | 2 + .../repos/builtin/packages/qca/package.py | 3 + .../builtin/packages/qcachegrind/package.py | 2 + .../repos/builtin/packages/qcat/package.py | 2 + .../repos/builtin/packages/qctool/package.py | 32 + .../repos/builtin/packages/qd/package.py | 4 + .../repos/builtin/packages/qemu/package.py | 3 + .../repos/builtin/packages/qgis/package.py | 9 +- .../repos/builtin/packages/qgraf/package.py | 5 +- .../repos/builtin/packages/qhull/package.py | 3 + .../repos/builtin/packages/qjson/package.py | 2 + .../repos/builtin/packages/qmcpack/package.py | 3 + .../builtin/packages/qmd-progress/package.py | 3 + .../repos/builtin/packages/qnnpack/package.py | 3 + .../repos/builtin/packages/qoz/package.py | 5 + .../repos/builtin/packages/qpdf/package.py | 48 + .../repos/builtin/packages/qperf/package.py | 2 + .../repos/builtin/packages/qrmumps/package.py | 6 +- .../builtin/packages/qrupdate/package.py | 2 + .../builtin/packages/qscintilla/package.py | 4 +- .../repos/builtin/packages/qt-base/package.py | 10 + .../packages/qt-declarative/package.py | 8 + .../builtin/packages/qt-quick3d/package.py | 7 + .../packages/qt-quicktimeline/package.py | 7 + .../packages/qt-shadertools/package.py | 7 + .../repos/builtin/packages/qt-svg/package.py | 7 + .../repos/builtin/packages/qt/package.py | 17 +- .../builtin/packages/qt/qt51514-oneapi.patch | 31 + .../repos/builtin/packages/qtgraph/package.py | 2 + .../builtin/packages/qthreads/package.py | 3 + .../builtin/packages/qtkeychain/package.py | 2 + .../builtin/packages/qtltools/package.py | 2 + .../builtin/packages/qualimap/package.py | 1 + .../packages/quantum-espresso/package.py | 9 + .../repos/builtin/packages/qucs/package.py | 3 + .../repos/builtin/packages/quickjs/package.py | 2 + .../builtin/packages/quicksilver/package.py | 2 + .../builtin/packages/quo-vadis/package.py | 4 + .../repos/builtin/packages/quota/package.py | 2 + .../repos/builtin/packages/qwt/package.py | 2 + .../builtin/packages/qwtpolar/package.py | 2 + .../packages/r-abaenrichment/package.py | 2 + .../repos/builtin/packages/r-acgh/package.py | 2 + .../repos/builtin/packages/r-acme/package.py | 2 + .../repos/builtin/packages/r-ade4/package.py | 3 + .../builtin/packages/r-adegenet/package.py | 2 + .../builtin/packages/r-adsplit/package.py | 2 + .../builtin/packages/r-affxparser/package.py | 3 + .../repos/builtin/packages/r-affy/package.py | 2 + .../builtin/packages/r-affyio/package.py | 2 + .../builtin/packages/r-affyplm/package.py | 2 + .../repos/builtin/packages/r-amap/package.py | 4 + .../packages/r-analysispageserver/package.py | 3 + .../builtin/packages/r-aneufinder/package.py | 2 + .../builtin/packages/r-anytime/package.py | 2 + .../packages/r-arrangements/package.py | 2 + .../repos/builtin/packages/r-ash/package.py | 2 + .../builtin/packages/r-asreml/package.py | 43 + .../builtin/packages/r-bamsignals/package.py | 3 + .../builtin/packages/r-base64enc/package.py | 2 + .../builtin/packages/r-bbmisc/package.py | 2 + .../builtin/packages/r-beachmat/package.py | 2 + .../builtin/packages/r-beeswarm/package.py | 2 + .../repos/builtin/packages/r-bfast/package.py | 2 + .../repos/builtin/packages/r-bio3d/package.py | 3 + .../builtin/packages/r-biobase/package.py | 2 + .../packages/r-biocneighbors/package.py | 2 + .../packages/r-biocparallel/package.py | 2 + .../packages/r-biocsingular/package.py | 2 + .../builtin/packages/r-biostrings/package.py | 2 + .../builtin/packages/r-biovizbase/package.py | 2 + .../repos/builtin/packages/r-bit/package.py | 2 + .../repos/builtin/packages/r-bit64/package.py | 2 + .../builtin/packages/r-bitops/package.py | 2 + .../builtin/packages/r-bluster/package.py | 2 + .../packages/r-bridgesampling/package.py | 2 + .../repos/builtin/packages/r-bsseq/package.py | 2 + .../repos/builtin/packages/r-c50/package.py | 2 + .../repos/builtin/packages/r-caret/package.py | 2 + .../builtin/packages/r-catools/package.py | 3 + .../builtin/packages/r-chipseq/package.py | 2 + .../repos/builtin/packages/r-cner/package.py | 2 + .../builtin/packages/r-colorspace/package.py | 2 + .../packages/r-colourpicker/package.py | 1 + .../packages/r-compquadform/package.py | 3 + .../builtin/packages/r-conquer/package.py | 2 + .../repos/builtin/packages/r-curl/package.py | 38 +- .../repos/builtin/packages/r-dada2/package.py | 2 + .../builtin/packages/r-decipher/package.py | 2 + .../packages/r-delayedarray/package.py | 2 + .../builtin/packages/r-densvis/package.py | 2 + .../builtin/packages/r-deoptim/package.py | 2 + .../repos/builtin/packages/r-deseq/package.py | 2 + .../builtin/packages/r-deseq2/package.py | 2 + .../builtin/packages/r-dicekriging/package.py | 2 + .../builtin/packages/r-diffobj/package.py | 2 + .../r-dirichletmultinomial/package.py | 2 + .../builtin/packages/r-dnacopy/package.py | 3 + .../repos/builtin/packages/r-dss/package.py | 2 + .../repos/builtin/packages/r-dtw/package.py | 2 + .../repos/builtin/packages/r-ebseq/package.py | 2 + .../repos/builtin/packages/r-edger/package.py | 3 + .../builtin/packages/r-ellipsis/package.py | 2 + .../builtin/packages/r-energy/package.py | 3 + .../builtin/packages/r-exomecopy/package.py | 2 + .../builtin/packages/r-expint/package.py | 2 + .../builtin/packages/r-fftwtools/package.py | 2 + .../repos/builtin/packages/r-fgsea/package.py | 2 + .../builtin/packages/r-flashclust/package.py | 2 + .../repos/builtin/packages/r-gcrma/package.py | 2 + .../builtin/packages/r-gdsfmt/package.py | 3 + .../builtin/packages/r-geiger/package.py | 3 + .../builtin/packages/r-genefilter/package.py | 4 + .../builtin/packages/r-genie3/package.py | 2 + .../packages/r-genomicalignments/package.py | 2 + .../packages/r-genomicranges/package.py | 2 + .../builtin/packages/r-geojsonsf/package.py | 2 + .../builtin/packages/r-geometry/package.py | 3 + .../builtin/packages/r-geosphere/package.py | 3 + .../builtin/packages/r-ggplot2/package.py | 7 +- .../builtin/packages/r-glmgampoi/package.py | 2 + .../builtin/packages/r-goftest/package.py | 2 + .../builtin/packages/r-gofuncr/package.py | 3 + .../builtin/packages/r-gosemsim/package.py | 2 + .../repos/builtin/packages/r-gower/package.py | 2 + .../repos/builtin/packages/r-graph/package.py | 2 + .../repos/builtin/packages/r-gsl/package.py | 2 + .../repos/builtin/packages/r-gstat/package.py | 2 + .../repos/builtin/packages/r-haven/package.py | 5 + .../builtin/packages/r-hdf5array/package.py | 2 + .../builtin/packages/r-hdrcde/package.py | 3 + .../builtin/packages/r-hexbin/package.py | 3 + .../packages/r-humaniformat/package.py | 2 + .../builtin/packages/r-illuminaio/package.py | 2 + .../builtin/packages/r-impute/package.py | 2 + .../repos/builtin/packages/r-ipred/package.py | 2 + .../builtin/packages/r-iranges/package.py | 2 + .../repos/builtin/packages/r-irlba/package.py | 2 + .../builtin/packages/r-isoband/package.py | 2 + .../repos/builtin/packages/r-jomo/package.py | 2 + .../repos/builtin/packages/r-jpeg/package.py | 2 + .../builtin/packages/r-jsonify/package.py | 2 + .../builtin/packages/r-jsonlite/package.py | 5 + .../builtin/packages/r-kernlab/package.py | 3 + .../repos/builtin/packages/r-kknn/package.py | 2 + .../repos/builtin/packages/r-lars/package.py | 3 + .../builtin/packages/r-lazyeval/package.py | 2 + .../builtin/packages/r-libpressio/package.py | 2 + .../repos/builtin/packages/r-limma/package.py | 2 + .../builtin/packages/r-lmtest/package.py | 3 + .../builtin/packages/r-lobstr/package.py | 2 + .../repos/builtin/packages/r-log4r/package.py | 2 + .../repos/builtin/packages/r-lsei/package.py | 3 + .../builtin/packages/r-magrittr/package.py | 2 + .../builtin/packages/r-makecdfenv/package.py | 2 + .../builtin/packages/r-mapproj/package.py | 2 + .../builtin/packages/r-memuse/package.py | 2 + .../builtin/packages/r-metapod/package.py | 2 + .../repos/builtin/packages/r-mime/package.py | 2 + .../builtin/packages/r-mixtools/package.py | 2 + .../builtin/packages/r-mlrmbo/package.py | 2 + .../builtin/packages/r-mnormt/package.py | 3 + .../packages/r-modelmetrics/package.py | 2 + .../builtin/packages/r-mscoreutils/package.py | 2 + .../builtin/packages/r-msnbase/package.py | 3 + .../builtin/packages/r-multtest/package.py | 2 + .../repos/builtin/packages/r-mzr/package.py | 2 + .../repos/builtin/packages/r-np/package.py | 2 + .../builtin/packages/r-openxlsx/package.py | 2 + .../packages/r-paramhelpers/package.py | 2 + .../builtin/packages/r-partykit/package.py | 2 + .../builtin/packages/r-pbivnorm/package.py | 2 + .../builtin/packages/r-pcamethods/package.py | 2 + .../builtin/packages/r-phangorn/package.py | 3 + .../r-phantompeakqualtools/package.py | 3 + .../builtin/packages/r-picante/package.py | 2 + .../builtin/packages/r-pkgload/package.py | 7 +- .../repos/builtin/packages/r-png/package.py | 2 + .../packages/r-preprocesscore/package.py | 2 + .../repos/builtin/packages/r-proxy/package.py | 2 + .../repos/builtin/packages/r-pryr/package.py | 2 + .../repos/builtin/packages/r-ptw/package.py | 2 + .../builtin/packages/r-qqconf/package.py | 2 + .../builtin/packages/r-quadprog/package.py | 3 + .../packages/r-randomforest/package.py | 3 + .../repos/builtin/packages/r-rann/package.py | 3 + .../builtin/packages/r-rappdirs/package.py | 2 + .../repos/builtin/packages/r-rbgl/package.py | 2 + .../repos/builtin/packages/r-rcpp/package.py | 5 + .../builtin/packages/r-rcppcctz/package.py | 2 + .../builtin/packages/r-rcppdate/package.py | 2 + .../builtin/packages/r-rcppde/package.py | 2 + .../builtin/packages/r-rcppgsl/package.py | 3 + .../builtin/packages/r-rcppml/package.py | 2 + .../packages/r-rcppprogress/package.py | 2 + .../builtin/packages/r-rcpptoml/package.py | 2 + .../packages/r-rcppziggurat/package.py | 3 + .../builtin/packages/r-reshape2/package.py | 2 + .../builtin/packages/r-restfulr/package.py | 2 + .../builtin/packages/r-rferns/package.py | 2 + .../builtin/packages/r-rgraphviz/package.py | 3 + .../repos/builtin/packages/r-rhdf5/package.py | 3 + .../packages/r-rhdf5filters/package.py | 3 + .../builtin/packages/r-rhdf5lib/package.py | 2 + .../builtin/packages/r-rhtslib/package.py | 2 + .../builtin/packages/r-rinside/package.py | 3 + .../repos/builtin/packages/r-rjson/package.py | 3 + .../repos/builtin/packages/r-rle/package.py | 2 + .../builtin/packages/r-rmutil/package.py | 3 + .../builtin/packages/r-rnaseqmap/package.py | 2 + .../repos/builtin/packages/r-rncl/package.py | 3 + .../repos/builtin/packages/r-roc/package.py | 2 + .../repos/builtin/packages/r-rook/package.py | 2 + .../repos/builtin/packages/r-rots/package.py | 2 + .../builtin/packages/r-rsamtools/package.py | 3 + .../builtin/packages/r-rspectra/package.py | 3 + .../builtin/packages/r-rsubread/package.py | 2 + .../builtin/packages/r-rtracklayer/package.py | 2 + .../repos/builtin/packages/r-ruv/package.py | 2 + .../builtin/packages/r-rviennacl/package.py | 2 + .../builtin/packages/r-s4vectors/package.py | 2 + .../repos/builtin/packages/r-samr/package.py | 3 + .../builtin/packages/r-scales/package.py | 1 + .../repos/builtin/packages/r-scran/package.py | 2 + .../repos/builtin/packages/r-scs/package.py | 2 + .../builtin/packages/r-scuttle/package.py | 2 + .../repos/builtin/packages/r-shiny/package.py | 4 +- .../builtin/packages/r-shortread/package.py | 3 + .../builtin/packages/r-simpleaffy/package.py | 2 + .../repos/builtin/packages/r-sitmo/package.py | 2 + .../repos/builtin/packages/r-smoof/package.py | 3 + .../builtin/packages/r-snprelate/package.py | 3 + .../builtin/packages/r-snpstats/package.py | 2 + .../repos/builtin/packages/r-som/package.py | 2 + .../builtin/packages/r-sourcetools/package.py | 3 + .../packages/r-sparsematrixstats/package.py | 2 + .../builtin/packages/r-spatialpack/package.py | 3 + .../builtin/packages/r-statmod/package.py | 3 + .../builtin/packages/r-strucchange/package.py | 2 + .../packages/r-strucchangercpp/package.py | 2 + .../builtin/packages/r-suppdists/package.py | 2 + .../repos/builtin/packages/r-sva/package.py | 2 + .../builtin/packages/r-tfbstools/package.py | 2 + .../builtin/packages/r-tfmpvalue/package.py | 3 + .../builtin/packages/r-tibble/package.py | 2 + .../builtin/packages/r-tmvnsim/package.py | 3 + .../builtin/packages/r-triebeard/package.py | 2 + .../builtin/packages/r-truncnorm/package.py | 2 + .../builtin/packages/r-udunits2/package.py | 2 + .../builtin/packages/r-urltools/package.py | 3 + .../packages/r-variantannotation/package.py | 2 + .../repos/builtin/packages/r-vctrs/package.py | 10 + .../repos/builtin/packages/r-vsn/package.py | 2 + .../repos/builtin/packages/r-xde/package.py | 3 + .../builtin/packages/r-xnomial/package.py | 2 + .../builtin/packages/r-xvector/package.py | 2 + .../builtin/packages/r-zlibbioc/package.py | 2 + .../repos/builtin/packages/r-zoo/package.py | 2 + var/spack/repos/builtin/packages/r/package.py | 14 +- .../repos/builtin/packages/r3d/package.py | 3 + .../builtin/packages/rabbitmq-c/package.py | 2 + .../repos/builtin/packages/racket/package.py | 3 + .../repos/builtin/packages/racon/package.py | 3 + .../repos/builtin/packages/raft/package.py | 2 + .../repos/builtin/packages/ragel/package.py | 3 + .../repos/builtin/packages/raja/package.py | 203 +++- .../builtin/packages/ramulator/package.py | 2 + .../builtin/packages/randfold/package.py | 2 + .../builtin/packages/random123/package.py | 3 + .../builtin/packages/range-v3/package.py | 3 + .../repos/builtin/packages/rankstr/package.py | 5 +- .../builtin/packages/rapidjson/package.py | 2 + .../repos/builtin/packages/raptor2/package.py | 3 + .../repos/builtin/packages/rarpd/package.py | 2 + .../builtin/packages/rasdaemon/package.py | 2 + .../repos/builtin/packages/rasqal/package.py | 2 + .../repos/builtin/packages/ratel/package.py | 2 + .../repos/builtin/packages/ravel/package.py | 2 + .../builtin/packages/raxml-ng/package.py | 3 + .../repos/builtin/packages/raxml/package.py | 2 + .../repos/builtin/packages/ray/package.py | 2 + .../builtin/packages/rayleigh/package.py | 75 ++ .../repos/builtin/packages/raylib/package.py | 2 + .../builtin/packages/rccl-tests/package.py | 2 + ...0002-Fix-numactl-rocm-smi-path-issue.patch | 24 - .../repos/builtin/packages/rccl/package.py | 51 +- .../repos/builtin/packages/rclone/package.py | 3 + .../repos/builtin/packages/rdc/package.py | 48 +- .../repos/builtin/packages/rdkit/package.py | 9 + .../builtin/packages/rdma-core/libdrm.patch | 11 + .../builtin/packages/rdma-core/package.py | 8 + .../repos/builtin/packages/re2/package.py | 3 + .../repos/builtin/packages/re2c/package.py | 11 + .../repos/builtin/packages/readfq/package.py | 2 + .../builtin/packages/readline/package.py | 2 + .../builtin/packages/recola-sm/package.py | 2 + .../repos/builtin/packages/recola/package.py | 4 + .../repos/builtin/packages/recon/package.py | 2 + .../builtin/packages/recorder/package.py | 3 + .../builtin/packages/redis-ai/package.py | 3 + .../packages/redis-plus-plus/package.py | 2 + .../repos/builtin/packages/redis/package.py | 3 + .../packages/redland-bindings/package.py | 13 +- .../repos/builtin/packages/redland/package.py | 2 + .../repos/builtin/packages/redset/package.py | 5 +- .../repos/builtin/packages/reframe/package.py | 3 + .../repos/builtin/packages/regale/package.py | 3 + .../builtin/packages/regtools/package.py | 3 + .../repos/builtin/packages/relax/package.py | 2 + .../repos/builtin/packages/remhos/package.py | 2 + .../repos/builtin/packages/rempi/package.py | 4 + .../builtin/packages/rendercheck/package.py | 2 + .../builtin/packages/reprimand/package.py | 2 + .../repos/builtin/packages/resolve/package.py | 2 + .../builtin/packages/revbayes/package.py | 3 + .../repos/builtin/packages/rgb/package.py | 2 + .../repos/builtin/packages/rhash/package.py | 2 + .../repos/builtin/packages/rinetd/package.py | 2 + .../packages/riscv-gnu-toolchain/package.py | 4 + .../repos/builtin/packages/rivet/package.py | 5 +- .../builtin/packages/rkcommon/package.py | 5 +- .../builtin/packages/rkt-base/package.py | 3 + .../packages/rkt-compiler-lib/package.py | 3 + .../packages/rkt-racket-lib/package.py | 3 + .../builtin/packages/rkt-zo-lib/package.py | 3 + .../repos/builtin/packages/rlwrap/package.py | 2 + .../repos/builtin/packages/rmgdft/package.py | 5 + .../repos/builtin/packages/rmlab/package.py | 2 + .../repos/builtin/packages/rnaz/package.py | 3 + .../builtin/packages/rng-tools/package.py | 2 + .../builtin/packages/rngstreams/package.py | 2 + .../builtin/packages/rnpletal/package.py | 3 + ...fix-compilation-for-rocalution-5.2.0.patch | 35 - .../builtin/packages/rocalution/package.py | 35 +- .../rocblas/0003-Fix-rocblas-gentest.patch | 9 - .../repos/builtin/packages/rocblas/package.py | 43 +- ...-clients-fftw3-include-dirs-rocm-4.5.patch | 12 - ...-rocrand-fftw-include-dir-rocm-6.0.0.patch | 39 + .../repos/builtin/packages/rocfft/package.py | 47 +- .../repos/builtin/packages/rocksdb/package.py | 5 + .../packages/rocm-bandwidth-test/package.py | 42 +- .../packages/rocm-clang-ocl/package.py | 62 +- .../builtin/packages/rocm-cmake/package.py | 46 +- .../builtin/packages/rocm-core/package.py | 5 + .../builtin/packages/rocm-dbgapi/package.py | 42 +- .../packages/rocm-debug-agent/package.py | 52 +- .../packages/rocm-device-libs/package.py | 58 +- .../builtin/packages/rocm-gdb/package.py | 45 +- .../builtin/packages/rocm-opencl/package.py | 84 +- ...kmt-libdrm-and-numactl-libraries-6.1.patch | 29 + .../packages/rocm-openmp-extras/package.py | 172 ++-- .../builtin/packages/rocm-smi-lib/package.py | 45 +- .../builtin/packages/rocm-smi/package.py | 72 -- .../builtin/packages/rocm-tensile/package.py | 28 +- ...rence-donot-download-googletest-yaml.patch | 159 --- .../006-library-path.patch | 371 ------- ...cing-rocm-path-with-package-path-6.1.patch | 543 +++++++++++ .../packages/rocm-validation-suite/package.py | 55 +- .../builtin/packages/rocminfo/package.py | 42 +- .../repos/builtin/packages/rocmlir/package.py | 26 +- .../repos/builtin/packages/rocprim/package.py | 35 +- .../0002-add-fPIC-and-disable-tests-5.6.patch | 74 ++ .../0002-add-fPIC-and-disable-tests-5.7.patch | 68 ++ .../0002-add-fPIC-and-disable-tests.patch | 69 ++ .../rocprofiler-dev/0003-disable-tests.patch | 24 + .../packages/rocprofiler-dev/package.py | 95 +- .../repos/builtin/packages/rocrand/package.py | 53 +- .../rocsolver/fmt-8.1-compatibility.patch | 143 --- .../builtin/packages/rocsolver/package.py | 31 +- .../rocsparse/0003-fix-navi-1x-rocm-4.5.patch | 78 -- .../rocsparse/0003-fix-navi-1x-rocm-5.2.patch | 78 -- .../builtin/packages/rocsparse/package.py | 33 +- .../builtin/packages/rocthrust/package.py | 34 +- .../packages/roctracer-dev-api/package.py | 20 +- .../builtin/packages/roctracer-dev/package.py | 56 +- .../repos/builtin/packages/rocwmma/package.py | 26 +- .../repos/builtin/packages/roms/package.py | 2 + .../repos/builtin/packages/root/package.py | 93 +- .../packages/rosco/intel-oneapi-29.patch | 13 + .../packages/rosco/intel-oneapi-2x.patch | 13 + .../repos/builtin/packages/rosco/package.py | 66 ++ .../repos/builtin/packages/ross/package.py | 9 +- .../repos/builtin/packages/routino/package.py | 3 + .../builtin/packages/rpcsvc-proto/package.py | 5 +- .../repos/builtin/packages/rpm/package.py | 3 + .../0003-changes-to-rpp-unit-tests-6.1.patch | 56 ++ .../repos/builtin/packages/rpp/package.py | 33 +- .../repos/builtin/packages/rr/package.py | 3 + .../repos/builtin/packages/rsbench/package.py | 17 +- .../repos/builtin/packages/rsem/package.py | 3 + .../repos/builtin/packages/rsl/package.py | 2 + .../repos/builtin/packages/rstart/package.py | 2 + .../repos/builtin/packages/rstudio/package.py | 3 + .../repos/builtin/packages/rsync/package.py | 4 + .../repos/builtin/packages/rsyslog/package.py | 2 + .../builtin/packages/rt-tests/package.py | 2 + .../repos/builtin/packages/rtags/package.py | 3 + .../builtin/packages/rtmpdump/package.py | 2 + .../builtin/packages/ruby-hpricot/package.py | 2 + .../builtin/packages/ruby-narray/package.py | 2 + .../builtin/packages/ruby-rake/package.py | 2 + .../packages/ruby-rdiscount/package.py | 2 + .../repos/builtin/packages/ruby/package.py | 7 +- .../repos/builtin/packages/runc/package.py | 2 + .../builtin/packages/rust-bindgen/package.py | 2 + .../packages/rust-bootstrap/package.py | 16 + .../repos/builtin/packages/rust/package.py | 38 +- .../repos/builtin/packages/sabre/package.py | 2 + .../builtin/packages/saga-gis/package.py | 3 + .../builtin/packages/sailfish/package.py | 3 + .../builtin/packages/salmon-tddft/package.py | 3 + .../repos/builtin/packages/salmon/package.py | 3 + .../builtin/packages/salome-med/package.py | 4 + .../packages/salome-medcoupling/package.py | 3 + .../repos/builtin/packages/sam2p/package.py | 3 + .../builtin/packages/sambamba/package.py | 2 + .../builtin/packages/samblaster/package.py | 3 + .../builtin/packages/samtools/package.py | 3 + .../repos/builtin/packages/sandbox/package.py | 2 + .../repos/builtin/packages/sartre/package.py | 4 + .../repos/builtin/packages/sarus/package.py | 2 + .../builtin/packages/satsuma2/package.py | 3 + .../repos/builtin/packages/saws/package.py | 2 + .../builtin/packages/sblim-sfcc/package.py | 3 + .../repos/builtin/packages/sbml/package.py | 3 + .../repos/builtin/packages/sbp/package.py | 3 + .../repos/builtin/packages/sbt/package.py | 1 + .../builtin/packages/scafacos/package.py | 4 + .../builtin/packages/scalasca/package.py | 3 + .../repos/builtin/packages/scale/package.py | 3 + .../repos/builtin/packages/scallop/package.py | 2 + .../repos/builtin/packages/scalpel/package.py | 3 + .../packages/scan-for-matches/package.py | 2 + .../builtin/packages/scantailor/package.py | 2 + .../repos/builtin/packages/scc/package.py | 4 + .../builtin/packages/scine-core/package.py | 3 + .../packages/scine-database/package.py | 2 + .../packages/scine-molassembler/package.py | 2 + .../cmake_molcas_interface.patch | 19 + .../packages/scine-qcmaquis/package.py | 49 +- .../builtin/packages/scine-readuct/package.py | 2 + .../packages/scine-serenity/package.py | 2 + .../builtin/packages/scine-sparrow/package.py | 2 + .../packages/scine-utilities/package.py | 2 + .../builtin/packages/scine-xtb/package.py | 2 + .../builtin/packages/scitokens-cpp/package.py | 7 + .../repos/builtin/packages/scons/package.py | 3 +- .../builtin/packages/scorec-core/package.py | 4 + .../repos/builtin/packages/scorep/package.py | 23 +- .../repos/builtin/packages/scorpio/package.py | 3 + .../repos/builtin/packages/scotch/package.py | 17 +- .../packages/scotch/parmetis-mpi.patch | 127 +++ .../repos/builtin/packages/scr/package.py | 7 +- .../repos/builtin/packages/screen/package.py | 2 + .../repos/builtin/packages/scripts/package.py | 2 + .../repos/builtin/packages/scrot/package.py | 2 + .../repos/builtin/packages/scs/package.py | 2 + .../repos/builtin/packages/sctk/package.py | 3 + .../builtin/packages/sdl2-image/package.py | 3 + .../builtin/packages/sdl2-ttf/package.py | 3 + .../repos/builtin/packages/sdl2/package.py | 6 +- .../builtin/packages/sdsl-lite/package.py | 3 + .../repos/builtin/packages/seacas/package.py | 143 ++- .../repos/builtin/packages/seacr/package.py | 33 + .../repos/builtin/packages/seal/package.py | 3 + .../repos/builtin/packages/sed/package.py | 2 + .../repos/builtin/packages/selalib/package.py | 4 + .../builtin/packages/semiprof/package.py | 2 + .../repos/builtin/packages/sensei/package.py | 3 + .../builtin/packages/sentencepiece/package.py | 2 + .../repos/builtin/packages/seq-gen/package.py | 2 + .../repos/builtin/packages/seqan/package.py | 2 + .../repos/builtin/packages/seqfu/package.py | 35 + .../wno_incompatible_pointer_types.patch | 13 + .../repos/builtin/packages/seqkit/package.py | 29 +- .../repos/builtin/packages/seqprep/package.py | 2 + .../repos/builtin/packages/seqtk/package.py | 2 + .../packages/serenity-libint/package.py | 7 +- .../builtin/packages/serenity/package.py | 155 +-- .../repos/builtin/packages/serf/package.py | 2 + .../builtin/packages/serialbox/package.py | 4 + .../repos/builtin/packages/sessreg/package.py | 2 + .../builtin/packages/setserial/package.py | 2 + .../builtin/packages/setxkbmap/package.py | 3 + .../repos/builtin/packages/sfcgal/package.py | 2 + .../repos/builtin/packages/sfcio/package.py | 2 + .../repos/builtin/packages/sga/package.py | 3 + .../repos/builtin/packages/sgpp/package.py | 2 + .../repos/builtin/packages/shadow/package.py | 3 + .../builtin/packages/shapeit4/package.py | 2 + .../builtin/packages/shapelib/package.py | 4 + .../builtin/packages/shapemapper/package.py | 2 + .../packages/shared-mime-info/package.py | 2 + .../repos/builtin/packages/shark/package.py | 2 + .../builtin/packages/sheenbidi/package.py | 4 + .../repos/builtin/packages/sherpa/package.py | 27 +- .../builtin/packages/shocklibs/package.py | 3 + .../builtin/packages/shoremap/package.py | 2 + .../builtin/packages/showfont/package.py | 2 + .../repos/builtin/packages/shtools/package.py | 3 + .../builtin/packages/shuffile/package.py | 5 +- .../repos/builtin/packages/sicer2/package.py | 2 + .../repos/builtin/packages/sickle/package.py | 2 + .../repos/builtin/packages/sicm/package.py | 4 + .../repos/builtin/packages/siesta/package.py | 3 + .../repos/builtin/packages/sigcpp/package.py | 3 + .../repos/builtin/packages/sigio/package.py | 2 + .../repos/builtin/packages/signify/package.py | 3 + .../repos/builtin/packages/silo/package.py | 4 + .../repos/builtin/packages/simde/package.py | 2 + .../repos/builtin/packages/simgrid/package.py | 4 + .../packages/simmetrix-simmodsuite/package.py | 7 +- .../builtin/packages/simple-dftd3/package.py | 3 + .../builtin/packages/simplemoc/package.py | 2 + .../repos/builtin/packages/simsipm/package.py | 2 + .../repos/builtin/packages/simul/package.py | 2 + .../builtin/packages/simulationio/package.py | 2 + .../repos/builtin/packages/sina/package.py | 3 + .../packages/singularity-eos/package.py | 3 + .../packages/singularity-legacy/package.py | 2 + .../builtin/packages/singularity/package.py | 2 + .../builtin/packages/singularityce/package.py | 2 + .../repos/builtin/packages/sio/package.py | 3 + .../repos/builtin/packages/sionlib/package.py | 4 + .../repos/builtin/packages/sirius/package.py | 78 +- .../repos/builtin/packages/skopeo/package.py | 2 + .../repos/builtin/packages/sl/package.py | 2 + .../repos/builtin/packages/slang/package.py | 2 + .../repos/builtin/packages/slate/package.py | 45 +- .../repos/builtin/packages/sleef/package.py | 7 +- .../repos/builtin/packages/slepc/package.py | 19 +- .../builtin/packages/slirp4netns/package.py | 2 + .../builtin/packages/sloccount/package.py | 3 + .../builtin/packages/slurm-drmaa/package.py | 2 + .../repos/builtin/packages/slurm/package.py | 2 + .../repos/builtin/packages/smalt/package.py | 2 + .../builtin/packages/smartdenovo/package.py | 2 + .../builtin/packages/smartmontools/package.py | 3 + .../repos/builtin/packages/smproxy/package.py | 2 + .../builtin/packages/snakemake/package.py | 5 +- .../builtin/packages/snap-berkeley/package.py | 2 + .../builtin/packages/snap-korf/package.py | 2 + .../repos/builtin/packages/snap/package.py | 4 + .../repos/builtin/packages/snappy/package.py | 2 + .../repos/builtin/packages/snbone/package.py | 3 + .../builtin/packages/sniffles/package.py | 3 + .../repos/builtin/packages/snptest/package.py | 3 +- .../packages/soapdenovo-trans/package.py | 2 + .../builtin/packages/soapdenovo2/package.py | 3 + .../repos/builtin/packages/socat/package.py | 2 + .../repos/builtin/packages/soci/package.py | 2 + .../repos/builtin/packages/sofa-c/package.py | 2 + .../repos/builtin/packages/sollve/package.py | 2 - .../repos/builtin/packages/sollya/package.py | 3 + .../repos/builtin/packages/solr/package.py | 1 + .../packages/somatic-sniper/package.py | 3 + .../builtin/packages/sombrero/package.py | 2 + .../repos/builtin/packages/sonlib/package.py | 3 + .../builtin/packages/sortmerna/package.py | 3 + .../repos/builtin/packages/sos/package.py | 48 +- .../repos/builtin/packages/sosflow/package.py | 3 + .../packages/source-highlight/package.py | 3 + .../repos/builtin/packages/sowing/package.py | 5 + .../repos/builtin/packages/sox/package.py | 2 + .../repos/builtin/packages/sp/package.py | 2 + .../builtin/packages/spaceranger/package.py | 38 + .../repos/builtin/packages/spack/package.py | 5 +- .../repos/builtin/packages/spades/package.py | 14 + .../builtin/packages/span-lite/package.py | 5 +- .../repos/builtin/packages/spark/package.py | 6 + .../repos/builtin/packages/sparrow/package.py | 2 + .../repos/builtin/packages/sparse/package.py | 2 + .../builtin/packages/sparsehash/package.py | 3 + .../builtin/packages/sparskit/package.py | 3 + .../repos/builtin/packages/sparta/package.py | 1 + .../repos/builtin/packages/spath/package.py | 5 +- .../builtin/packages/spatialdata/package.py | 69 ++ .../repos/builtin/packages/spdk/package.py | 3 + .../repos/builtin/packages/spdlog/package.py | 7 +- .../packages/specfem3d-globe/package.py | 4 + .../repos/builtin/packages/spectra/package.py | 3 + .../repos/builtin/packages/spectre/package.py | 53 +- .../builtin/packages/spectrum-mpi/package.py | 10 +- .../repos/builtin/packages/speex/package.py | 2 + .../builtin/packages/speexdsp/package.py | 2 + .../repos/builtin/packages/sperr/package.py | 3 + .../repos/builtin/packages/spfft/package.py | 17 +- .../repos/builtin/packages/spglib/package.py | 6 + .../builtin/packages/sph2pipe/package.py | 2 + .../repos/builtin/packages/spindle/package.py | 3 + .../repos/builtin/packages/spiner/package.py | 2 + .../packages/spiral-package-fftx/package.py | 3 + .../packages/spiral-software/package.py | 2 + .../repos/builtin/packages/spla/package.py | 51 +- .../repos/builtin/packages/spot/package.py | 5 + .../repos/builtin/packages/sprng/package.py | 4 + .../builtin/packages/sqlcipher/package.py | 3 + .../builtin/packages/sqlite-jdbc/package.py | 2 + .../repos/builtin/packages/sqlite/package.py | 22 +- .../builtin/packages/sqlitebrowser/package.py | 3 + .../packages/squashfs-mount/package.py | 2 + .../builtin/packages/squashfs/package.py | 2 + .../builtin/packages/squashfuse/package.py | 4 + .../repos/builtin/packages/squid/package.py | 2 + .../builtin/packages/sra-tools/package.py | 3 + .../srcml-identifier-getter-tool/package.py | 2 + .../repos/builtin/packages/srcml/package.py | 3 + .../builtin/packages/sse2neon/package.py | 3 + .../repos/builtin/packages/sshfs/package.py | 2 + .../repos/builtin/packages/sshpass/package.py | 2 + .../repos/builtin/packages/ssht/package.py | 3 + .../repos/builtin/packages/ssmtp/package.py | 2 + .../builtin/packages/sst-core/package.py | 2 + .../builtin/packages/sst-dumpi/package.py | 4 + .../builtin/packages/sst-elements/package.py | 4 + .../builtin/packages/sst-macro/package.py | 4 + .../packages/sst-transports/package.py | 3 + .../repos/builtin/packages/stacks/package.py | 3 + .../builtin/packages/staden-io-lib/package.py | 2 + .../repos/builtin/packages/star/package.py | 6 + .../builtin/packages/starlight/package.py | 4 + .../repos/builtin/packages/starpu/package.py | 11 +- .../packages/startup-notification/package.py | 3 + .../repos/builtin/packages/stat/package.py | 4 + .../repos/builtin/packages/stc/package.py | 2 +- .../repos/builtin/packages/stdexec/package.py | 9 + .../repos/builtin/packages/steps/package.py | 35 +- .../repos/builtin/packages/stinger/package.py | 3 + .../repos/builtin/packages/storm/package.py | 1 + .../repos/builtin/packages/stow/package.py | 1 + .../repos/builtin/packages/strace/package.py | 2 + .../repos/builtin/packages/stream/package.py | 3 + .../repos/builtin/packages/stress/package.py | 2 + .../builtin/packages/stressapptest/package.py | 3 + .../packages/string-view-lite/package.py | 2 + .../builtin/packages/stringtie/package.py | 3 + .../builtin/packages/structure/package.py | 2 + .../builtin/packages/strumpack/package.py | 104 +- .../repos/builtin/packages/su2/package.py | 9 + .../remove_preconfigure_timestamp_check.patch | 13 + .../repos/builtin/packages/subread/package.py | 2 + .../builtin/packages/subversion/package.py | 3 + .../builtin/packages/suite-sparse/package.py | 98 +- .../repos/builtin/packages/sumo/package.py | 2 + .../builtin/packages/sundials/package.py | 26 +- .../sundials/sundials-hip-platform.patch | 33 + .../builtin/packages/superchic/package.py | 2 + .../builtin/packages/superlu-dist/package.py | 8 +- .../builtin/packages/superlu-mt/package.py | 3 + .../repos/builtin/packages/superlu/package.py | 5 +- .../repos/builtin/packages/sw4/package.py | 3 + .../repos/builtin/packages/swan/package.py | 2 + .../packages/swap-assembler/package.py | 2 + .../repos/builtin/packages/swarm/package.py | 2 + .../builtin/packages/swftools/package.py | 3 + .../builtin/packages/swiftsim/package.py | 2 + .../repos/builtin/packages/swig/package.py | 5 +- .../repos/builtin/packages/swipl/package.py | 3 + .../builtin/packages/symengine/package.py | 3 + .../builtin/packages/symlinks/package.py | 2 + .../repos/builtin/packages/sympack/package.py | 3 + .../repos/builtin/packages/sympol/package.py | 3 + .../builtin/packages/sys-sage/package.py | 2 + .../builtin/packages/sysbench/package.py | 3 + .../repos/builtin/packages/syscalc/package.py | 3 + .../builtin/packages/sysfsutils/package.py | 2 + .../repos/builtin/packages/sysget/package.py | 2 + .../repos/builtin/packages/sysstat/package.py | 2 + .../repos/builtin/packages/systemc/package.py | 3 + .../repos/builtin/packages/systemd/package.py | 143 +++ .../builtin/packages/systemtap/package.py | 3 + .../repos/builtin/packages/sz-cpp/package.py | 2 + .../repos/builtin/packages/sz/package.py | 7 + .../repos/builtin/packages/sz3/package.py | 24 +- .../repos/builtin/packages/szauto/package.py | 3 + .../repos/builtin/packages/szx/package.py | 51 + .../repos/builtin/packages/t8code/package.py | 7 + .../repos/builtin/packages/tabix/package.py | 2 + .../repos/builtin/packages/talass/package.py | 2 + .../repos/builtin/packages/talloc/package.py | 3 + .../repos/builtin/packages/tamaas/package.py | 28 +- .../packages/tamaas/recent_compilers.patch | 57 ++ .../repos/builtin/packages/tandem/package.py | 3 + .../repos/builtin/packages/tangram/package.py | 3 + .../repos/builtin/packages/tar/package.py | 9 +- .../repos/builtin/packages/task/package.py | 11 + .../builtin/packages/taskflow/package.py | 5 + .../builtin/packages/tasmanian/package.py | 3 + .../repos/builtin/packages/tau/package.py | 314 +++--- .../tau/tau-rocm-disable-llvm-plugin.patch | 19 + .../repos/builtin/packages/tauola/package.py | 4 + .../repos/builtin/packages/tblite/package.py | 3 + .../builtin/packages/tcl-itcl/package.py | 2 + .../builtin/packages/tcl-tcllib/package.py | 3 + .../builtin/packages/tcl-tclxml/package.py | 2 + .../repos/builtin/packages/tcl/package.py | 8 +- .../repos/builtin/packages/tclap/package.py | 2 + .../repos/builtin/packages/tcoffee/package.py | 3 + .../repos/builtin/packages/tcpdump/package.py | 2 + .../repos/builtin/packages/tcsh/package.py | 2 + .../builtin/packages/tdengine/package.py | 3 + .../repos/builtin/packages/tealeaf/package.py | 4 + .../repos/builtin/packages/teckit/package.py | 3 + .../builtin/packages/telegraf/package.py | 1 + .../builtin/packages/tempestremap/package.py | 2 + .../packages/templight-tools/package.py | 2 + .../builtin/packages/templight/package.py | 4 +- .../repos/builtin/packages/tempo/package.py | 3 + .../repos/builtin/packages/tengine/package.py | 4 + .../tensorflow-serving-client/package.py | 2 + .../builtin/packages/tensorpipe/package.py | 3 + .../repos/builtin/packages/termcap/package.py | 2 + .../builtin/packages/tesseract/package.py | 2 + .../builtin/packages/test-drive/package.py | 2 + .../builtin/packages/tests-sos/package.py | 36 + .../repos/builtin/packages/tetgen/package.py | 2 + .../repos/builtin/packages/tethex/package.py | 2 + .../repos/builtin/packages/texinfo/package.py | 6 +- .../repos/builtin/packages/texlive/package.py | 4 + .../builtin/packages/texstudio/package.py | 3 + .../builtin/packages/textparser/package.py | 4 + .../repos/builtin/packages/tfel/package.py | 19 +- .../packages/the-silver-searcher/package.py | 2 + .../repos/builtin/packages/thepeg/package.py | 2 + .../builtin/packages/thermo4pfm/package.py | 2 + .../builtin/packages/thornado-mini/package.py | 2 + .../repos/builtin/packages/thrift/package.py | 3 + .../repos/builtin/packages/thrust/package.py | 36 +- .../repos/builtin/packages/tig/package.py | 3 + .../builtin/packages/tiled-mm/package.py | 3 + .../repos/builtin/packages/time/package.py | 2 + .../builtin/packages/timedatex/package.py | 2 + .../builtin/packages/timemory/package.py | 4 + .../repos/builtin/packages/timew/package.py | 22 + .../repos/builtin/packages/tini/package.py | 2 + .../packages/tiny-tensor-compiler/package.py | 52 + .../builtin/packages/tinygltf/package.py | 4 + .../builtin/packages/tinyobjloader/package.py | 2 + .../builtin/packages/tinyxml2/package.py | 16 + .../repos/builtin/packages/tioga/package.py | 5 + .../builtin/packages/tippecanoe/package.py | 3 + .../repos/builtin/packages/tiptop/package.py | 2 + .../builtin/packages/tiramisu/package.py | 3 + .../repos/builtin/packages/tix/package.py | 10 +- .../repos/builtin/packages/tixi/package.py | 4 + .../repos/builtin/packages/tkrzw/package.py | 4 + .../builtin/packages/tl-expected/package.py | 2 + .../repos/builtin/packages/tldd/package.py | 2 + .../repos/builtin/packages/tmux/package.py | 5 + .../repos/builtin/packages/tnftp/package.py | 2 + .../repos/builtin/packages/toml-f/package.py | 2 + .../repos/builtin/packages/toml11/package.py | 16 + .../repos/builtin/packages/tophat/package.py | 3 + .../builtin/packages/totalview/package.py | 30 - .../builtin/packages/tpm2-tss/package.py | 3 + .../repos/builtin/packages/tracer/package.py | 2 + .../builtin/packages/tracy-client/package.py | 3 + .../repos/builtin/packages/tracy/package.py | 3 + .../builtin/packages/tramonto/package.py | 3 + .../builtin/packages/transposome/package.py | 2 + .../builtin/packages/transset/package.py | 2 + .../builtin/packages/tree-sitter/package.py | 13 + .../builtin/packages/treelite/package.py | 5 + .../repos/builtin/packages/trexio/package.py | 3 + .../repos/builtin/packages/trf/package.py | 2 + .../repos/builtin/packages/trident/package.py | 1 + .../trilinos-catalyst-ioss-adapter/package.py | 8 +- .../builtin/packages/trilinos/package.py | 74 +- .../repos/builtin/packages/trimal/package.py | 2 + .../repos/builtin/packages/trinity/package.py | 3 + .../builtin/packages/trnascan-se/package.py | 5 +- .../builtin/packages/trompeloeil/package.py | 3 + .../repos/builtin/packages/truchas/package.py | 4 + .../repos/builtin/packages/tskit/package.py | 3 + .../repos/builtin/packages/tulip/package.py | 3 + .../repos/builtin/packages/turbine/package.py | 3 + .../builtin/packages/turnserver/package.py | 2 + .../repos/builtin/packages/twm/package.py | 2 + .../repos/builtin/packages/tycho2/package.py | 2 + .../repos/builtin/packages/typhon/package.py | 3 + .../builtin/packages/typhonio/package.py | 3 + .../repos/builtin/packages/ucc/package.py | 4 + .../builtin/packages/uchardet/package.py | 4 + .../builtin/packages/ucsc-bedclip/package.py | 5 +- .../packages/ucsc-bedgraphtobigwig/package.py | 5 +- .../repos/builtin/packages/ucx/package.py | 10 +- .../repos/builtin/packages/udunits/package.py | 2 + .../builtin/packages/ufo-core/package.py | 3 + .../builtin/packages/ufo-filters/package.py | 3 + .../builtin/packages/ufs-utils/package.py | 3 + .../packages/ufs-weather-model/package.py | 175 +++- .../repos/builtin/packages/uftrace/package.py | 49 +- .../repos/builtin/packages/umap/package.py | 4 + .../repos/builtin/packages/umesimd/package.py | 2 + .../repos/builtin/packages/umoci/package.py | 2 + ...al_blt_import_umpire_2022.10_2023.06.patch | 106 ++ .../packages/umpire/export_includes.patch | 130 +++ .../repos/builtin/packages/umpire/package.py | 244 +++-- .../builtin/packages/uncrustify/package.py | 3 + .../builtin/packages/unibilium/package.py | 3 + .../repos/builtin/packages/unifdef/package.py | 2 + .../repos/builtin/packages/unifyfs/package.py | 4 + .../repos/builtin/packages/unigen/package.py | 2 + .../repos/builtin/packages/unison/package.py | 2 + .../repos/builtin/packages/units/package.py | 3 + .../builtin/packages/unittest-cpp/package.py | 2 + .../packages/universal-ctags/package.py | 7 + .../builtin/packages/universal/package.py | 3 + .../builtin/packages/unixodbc/package.py | 2 + .../repos/builtin/packages/unqlite/package.py | 2 + .../repos/builtin/packages/unrar/package.py | 2 + .../repos/builtin/packages/unuran/package.py | 3 + .../repos/builtin/packages/unzip/package.py | 14 +- .../upcxx/fix_configure_ldflags.patch | 26 + .../repos/builtin/packages/upcxx/package.py | 37 +- .../repos/builtin/packages/upp/package.py | 3 + .../repos/builtin/packages/uqtk/package.py | 4 + .../builtin/packages/uriparser/package.py | 3 + .../builtin/packages/usbutils/package.py | 2 + .../usearch/0001-Don-t-statically-link.patch | 26 + .../repos/builtin/packages/usearch/package.py | 40 +- .../builtin/packages/userspace-rcu/package.py | 2 + .../repos/builtin/packages/ut/package.py | 2 + .../builtin/packages/utf8proc/package.py | 3 + .../repos/builtin/packages/uthash/package.py | 3 + .../packages/util-linux-uuid/package.py | 6 +- .../builtin/packages/util-linux/package.py | 11 +- .../builtin/packages/util-macros/package.py | 12 +- .../repos/builtin/packages/uvw/package.py | 2 + .../builtin/packages/vacuumms/package.py | 42 +- .../repos/builtin/packages/vala/package.py | 2 + .../builtin/packages/valgrind/package.py | 6 + .../builtin/packages/valijson/package.py | 3 + .../builtin/packages/vampirtrace/package.py | 4 + .../repos/builtin/packages/vapor/package.py | 3 + .../builtin/packages/vardictjava/package.py | 1 + .../builtin/packages/variorum/package.py | 6 + .../builtin/packages/varnish-cache/package.py | 2 + .../repos/builtin/packages/vasp/package.py | 475 ++++----- .../repos/builtin/packages/vbfnlo/package.py | 3 + .../packages/vbz-compression/package.py | 3 + .../repos/builtin/packages/vc/package.py | 7 +- .../builtin/packages/vcftools/package.py | 3 + .../repos/builtin/packages/vdt/package.py | 3 + .../repos/builtin/packages/veccore/package.py | 2 + .../repos/builtin/packages/vecgeom/package.py | 7 + .../builtin/packages/veclibfort/package.py | 3 + .../repos/builtin/packages/vecmem/package.py | 31 +- .../packages/vectorclass-version2/package.py | 2 + .../repos/builtin/packages/veloc/package.py | 4 + .../repos/builtin/packages/verible/package.py | 7 + .../builtin/packages/verilator/package.py | 13 +- .../repos/builtin/packages/verrou/package.py | 5 +- .../repos/builtin/packages/vgm/package.py | 2 + .../builtin/packages/viennarna/package.py | 4 + .../repos/builtin/packages/viewres/package.py | 2 + .../repos/builtin/packages/vigra/package.py | 3 + .../repos/builtin/packages/vim/package.py | 5 + .../builtin/packages/virtualgl/package.py | 3 + .../builtin/packages/virtuoso/package.py | 3 + .../builtin/packages/visit-cgns/package.py | 4 + .../builtin/packages/visit-ffp/package.py | 4 + .../builtin/packages/visit-mfem/package.py | 4 + .../builtin/packages/visit-silo/package.py | 4 + .../builtin/packages/visit-unv/package.py | 4 + .../repos/builtin/packages/visit/package.py | 20 +- .../repos/builtin/packages/vite/package.py | 3 + .../repos/builtin/packages/vmatch/package.py | 2 + .../repos/builtin/packages/vmc/package.py | 2 + .../repos/builtin/packages/vmd/package.py | 2 +- .../repos/builtin/packages/volk/package.py | 3 + .../repos/builtin/packages/voropp/package.py | 2 + .../builtin/packages/votca-csg/package.py | 2 + .../builtin/packages/votca-csgapps/package.py | 2 + .../builtin/packages/votca-ctp/package.py | 3 + .../builtin/packages/votca-tools/package.py | 2 + .../builtin/packages/votca-xtp/package.py | 2 + .../repos/builtin/packages/votca/package.py | 8 +- .../repos/builtin/packages/vpfft/package.py | 2 + .../repos/builtin/packages/vpic/package.py | 3 + .../repos/builtin/packages/vsearch/package.py | 3 + .../repos/builtin/packages/vsftpd/package.py | 2 + .../repos/builtin/packages/vt/package.py | 4 + .../builtin/packages/vtable-dumper/package.py | 2 + .../repos/builtin/packages/vtk-h/package.py | 3 + .../repos/builtin/packages/vtk-m/package.py | 30 +- .../vtk-m/vtkm-mr3215-ext-geom-fix.patch | 145 +++ .../repos/builtin/packages/vtk/package.py | 41 +- .../repos/builtin/packages/vvtest/package.py | 2 + .../repos/builtin/packages/w3emc/package.py | 3 + .../repos/builtin/packages/w3m/package.py | 3 + .../repos/builtin/packages/w3nco/package.py | 13 + .../builtin/packages/wannier90/package.py | 3 + .../repos/builtin/packages/warpx/package.py | 53 +- .../repos/builtin/packages/watch/package.py | 2 + .../packages/wayland-protocols/package.py | 3 + .../repos/builtin/packages/wayland/package.py | 5 +- .../repos/builtin/packages/wcs/package.py | 2 + .../builtin/packages/webbench/package.py | 2 + .../repos/builtin/packages/weechat/package.py | 3 + .../builtin/packages/weighttp/package.py | 2 + .../repos/builtin/packages/wget/package.py | 4 + .../repos/builtin/packages/wgl/package.py | 18 +- .../repos/builtin/packages/wgrib2/package.py | 5 +- .../repos/builtin/packages/wgsim/package.py | 2 + .../repos/builtin/packages/which/package.py | 2 + .../repos/builtin/packages/whip/package.py | 3 + .../repos/builtin/packages/whizard/package.py | 30 +- .../repos/builtin/packages/wi4mpi/package.py | 4 + .../repos/builtin/packages/win-sdk/package.py | 4 +- .../repos/builtin/packages/win-wdk/package.py | 4 +- .../builtin/packages/winbison/package.py | 3 + .../builtin/packages/wiredtiger/package.py | 3 + .../builtin/packages/wireshark/package.py | 3 + .../repos/builtin/packages/wonton/package.py | 3 + .../repos/builtin/packages/wordnet/package.py | 2 + .../repos/builtin/packages/wps/package.py | 4 + .../repos/builtin/packages/wrf-io/package.py | 3 + .../repos/builtin/packages/wrf/package.py | 45 +- .../repos/builtin/packages/wrk/package.py | 2 + .../builtin/packages/wsmancli/package.py | 3 + .../repos/builtin/packages/wt/package.py | 3 + .../repos/builtin/packages/wtdbg2/package.py | 5 +- .../builtin/packages/wxparaver/package.py | 3 + .../builtin/packages/wxpropgrid/package.py | 2 + .../builtin/packages/wxwidgets/package.py | 5 + .../repos/builtin/packages/x11perf/package.py | 4 +- .../repos/builtin/packages/x264/package.py | 3 + .../repos/builtin/packages/xalan-c/package.py | 3 + .../builtin/packages/xapian-core/package.py | 3 + .../repos/builtin/packages/xauth/package.py | 4 +- .../builtin/packages/xbacklight/package.py | 4 +- .../repos/builtin/packages/xbae/package.py | 27 + .../repos/builtin/packages/xbiff/package.py | 4 +- .../builtin/packages/xbitmaps/package.py | 2 +- .../repos/builtin/packages/xbraid/package.py | 5 + .../repos/builtin/packages/xcalc/package.py | 4 +- .../builtin/packages/xcb-demo/package.py | 2 + .../builtin/packages/xcb-proto/package.py | 34 +- .../packages/xcb-util-cursor/package.py | 3 + .../packages/xcb-util-errors/package.py | 3 + .../packages/xcb-util-image/package.py | 3 + .../packages/xcb-util-keysyms/package.py | 3 + .../packages/xcb-util-renderutil/package.py | 3 + .../builtin/packages/xcb-util-wm/package.py | 3 + .../builtin/packages/xcb-util-xrm/package.py | 2 + .../builtin/packages/xcb-util/package.py | 2 + .../repos/builtin/packages/xcdf/package.py | 2 + .../repos/builtin/packages/xcfun/package.py | 4 + .../repos/builtin/packages/xclip/package.py | 2 + .../builtin/packages/xclipboard/package.py | 4 +- .../repos/builtin/packages/xclock/package.py | 4 +- .../builtin/packages/xcmiscproto/package.py | 2 +- .../repos/builtin/packages/xcmsdb/package.py | 4 +- .../builtin/packages/xcompmgr/package.py | 4 +- .../builtin/packages/xconsole/package.py | 5 +- .../packages/xcursor-themes/package.py | 6 +- .../builtin/packages/xcursorgen/package.py | 4 +- .../builtin/packages/xdbedizzy/package.py | 4 +- .../repos/builtin/packages/xdelta/package.py | 3 + .../builtin/packages/xditview/package.py | 4 +- .../repos/builtin/packages/xdm/package.py | 5 +- .../repos/builtin/packages/xdmf3/package.py | 4 + .../repos/builtin/packages/xdotool/package.py | 2 + .../builtin/packages/xdpyinfo/package.py | 4 +- .../builtin/packages/xdriinfo/package.py | 4 +- .../repos/builtin/packages/xedit/package.py | 4 +- .../builtin/packages/xeniumranger/package.py | 38 + .../builtin/packages/xerces-c/package.py | 4 + .../repos/builtin/packages/xeus/package.py | 2 + .../repos/builtin/packages/xev/package.py | 5 +- .../builtin/packages/xextproto/package.py | 2 +- .../repos/builtin/packages/xeyes/package.py | 4 +- .../packages/xf86bigfontproto/package.py | 2 +- .../repos/builtin/packages/xf86dga/package.py | 4 +- .../builtin/packages/xf86dgaproto/package.py | 2 +- .../builtin/packages/xf86driproto/package.py | 2 +- .../builtin/packages/xf86miscproto/package.py | 2 +- .../builtin/packages/xf86rushproto/package.py | 2 +- .../packages/xf86vidmodeproto/package.py | 2 +- .../repos/builtin/packages/xfd/package.py | 4 +- .../builtin/packages/xfindproxy/package.py | 4 +- .../builtin/packages/xfontsel/package.py | 4 +- .../repos/builtin/packages/xforms/package.py | 2 + .../repos/builtin/packages/xfs/package.py | 5 +- .../repos/builtin/packages/xfsdump/package.py | 2 + .../repos/builtin/packages/xfsinfo/package.py | 4 +- .../builtin/packages/xfsprogs/package.py | 2 + .../repos/builtin/packages/xfwp/package.py | 4 +- .../repos/builtin/packages/xgamma/package.py | 4 +- .../repos/builtin/packages/xgboost/package.py | 3 + .../repos/builtin/packages/xgc/package.py | 4 +- .../repos/builtin/packages/xhmm/package.py | 3 + .../repos/builtin/packages/xhost/package.py | 4 +- .../builtin/packages/xineramaproto/package.py | 2 +- .../repos/builtin/packages/xinit/package.py | 5 +- .../repos/builtin/packages/xinput/package.py | 4 +- .../repos/builtin/packages/xkbcomp/package.py | 5 +- .../repos/builtin/packages/xkbevd/package.py | 4 +- .../builtin/packages/xkbprint/package.py | 4 +- .../builtin/packages/xkbutils/package.py | 5 +- .../repos/builtin/packages/xkill/package.py | 4 +- .../builtin/packages/xl/detection_test.yaml | 31 + .../repos/builtin/packages/xl/package.py | 65 ++ .../builtin/packages/xlc/detection_test.yaml | 18 - .../repos/builtin/packages/xlc/package.py | 81 -- .../builtin/packages/xlf/detection_test.yaml | 11 - .../repos/builtin/packages/xlf/package.py | 69 -- .../repos/builtin/packages/xload/package.py | 5 +- .../repos/builtin/packages/xlogo/package.py | 4 +- .../builtin/packages/xlsatoms/package.py | 4 +- .../builtin/packages/xlsclients/package.py | 4 +- .../builtin/packages/xlsfonts/package.py | 4 +- .../repos/builtin/packages/xmag/package.py | 4 +- .../repos/builtin/packages/xman/package.py | 4 +- .../builtin/packages/xmessage/package.py | 4 +- .../repos/builtin/packages/xmh/package.py | 5 +- .../repos/builtin/packages/xmlf90/package.py | 2 + .../builtin/packages/xmlrpc-c/package.py | 3 + .../repos/builtin/packages/xmlto/package.py | 2 + .../repos/builtin/packages/xmodmap/package.py | 4 +- .../repos/builtin/packages/xmore/package.py | 4 +- .../repos/builtin/packages/xnnpack/package.py | 3 + .../builtin/packages/xorg-cf-files/package.py | 3 +- .../builtin/packages/xorg-docs/package.py | 6 +- .../builtin/packages/xorg-gtest/package.py | 2 + .../builtin/packages/xorg-server/package.py | 3 + .../packages/xorg-sgml-doctools/package.py | 6 +- .../builtin/packages/xphelloworld/package.py | 4 +- .../builtin/packages/xplsprinters/package.py | 4 +- .../repos/builtin/packages/xpmem/package.py | 2 + .../repos/builtin/packages/xpr/package.py | 4 +- .../packages/xprehashprinterlist/package.py | 4 +- .../repos/builtin/packages/xprop/package.py | 5 +- .../builtin/packages/xproperty/package.py | 2 + .../repos/builtin/packages/xproto/package.py | 2 +- .../xproxymanagementprotocol/package.py | 2 +- .../repos/builtin/packages/xqilla/package.py | 3 + .../repos/builtin/packages/xrandr/package.py | 4 +- .../repos/builtin/packages/xrdb/package.py | 4 +- .../builtin/packages/xrdcl-record/package.py | 2 + .../builtin/packages/xrefresh/package.py | 5 +- .../repos/builtin/packages/xrootd/package.py | 36 +- .../repos/builtin/packages/xrx/package.py | 4 +- .../repos/builtin/packages/xsbench/package.py | 3 + .../repos/builtin/packages/xscope/package.py | 4 +- .../repos/builtin/packages/xsd/package.py | 3 + .../builtin/packages/xsdk-examples/package.py | 3 + .../repos/builtin/packages/xset/package.py | 4 +- .../builtin/packages/xsetmode/package.py | 4 +- .../builtin/packages/xsetpointer/package.py | 4 +- .../builtin/packages/xsetroot/package.py | 4 +- .../repos/builtin/packages/xsimd/package.py | 2 + .../repos/builtin/packages/xsm/package.py | 4 +- .../builtin/packages/xstdcmap/package.py | 4 +- .../repos/builtin/packages/xtb/package.py | 3 + .../repos/builtin/packages/xtcdata/package.py | 3 + .../builtin/packages/xtensor-blas/package.py | 2 + .../packages/xtensor-python/package.py | 2 + .../repos/builtin/packages/xtensor/package.py | 2 + .../repos/builtin/packages/xtl/package.py | 2 + .../repos/builtin/packages/xtrans/package.py | 4 +- .../repos/builtin/packages/xtrap/package.py | 4 +- .../repos/builtin/packages/xts/package.py | 2 + .../repos/builtin/packages/xv/package.py | 3 + .../builtin/packages/xvidtune/package.py | 4 +- .../repos/builtin/packages/xvinfo/package.py | 4 +- .../repos/builtin/packages/xwd/package.py | 4 +- .../builtin/packages/xwidgets/package.py | 2 + .../builtin/packages/xwininfo/package.py | 5 +- .../repos/builtin/packages/xwud/package.py | 4 +- .../packages/xxd-standalone/package.py | 3 + .../repos/builtin/packages/xxdiff/package.py | 3 + .../repos/builtin/packages/xxhash/package.py | 4 + .../repos/builtin/packages/xyce/package.py | 3 + .../repos/builtin/packages/xz/package.py | 4 + .../repos/builtin/packages/yade/package.py | 2 + .../repos/builtin/packages/yafyaml/package.py | 2 + .../repos/builtin/packages/yaksa/package.py | 2 + .../repos/builtin/packages/yambo/package.py | 23 +- .../builtin/packages/yaml-cpp/package.py | 2 + .../repos/builtin/packages/yara/package.py | 3 + .../repos/builtin/packages/yasm/package.py | 2 + .../repos/builtin/packages/yoda/package.py | 10 + .../repos/builtin/packages/yorick/package.py | 4 + .../repos/builtin/packages/yosys/package.py | 10 +- .../repos/builtin/packages/yq/package.py | 23 + .../builtin/packages/z-checker/package.py | 3 + .../repos/builtin/packages/z3/package.py | 12 +- .../repos/builtin/packages/zabbix/package.py | 3 + .../repos/builtin/packages/zerosum/package.py | 76 ++ .../repos/builtin/packages/zfp/package.py | 4 + .../repos/builtin/packages/zfs/package.py | 2 + .../repos/builtin/packages/zig/package.py | 11 +- ...po-it-is-ambiguities-not-amgibuities.patch | 26 + ...2-gcc14-no-implicit-declarations-fix.patch | 71 ++ .../repos/builtin/packages/zip/package.py | 9 +- .../repos/builtin/packages/zlib-ng/package.py | 51 +- .../builtin/packages/zlib-ng/pr-1542.patch | 224 ----- .../builtin/packages/zlib-ng/pr-1546.patch | 182 ---- .../builtin/packages/zlib-ng/pr-1561.patch | 210 ---- .../builtin/packages/zlib-ng/pr-1562.patch | 432 --------- .../builtin/packages/zlib-ng/pr-1698.patch | 31 + .../repos/builtin/packages/zlib/package.py | 23 +- .../repos/builtin/packages/zoltan/package.py | 4 + .../builtin/packages/zookeeper/package.py | 3 + .../repos/builtin/packages/zopfli/package.py | 3 + .../repos/builtin/packages/zsh/package.py | 4 + .../repos/builtin/packages/zstd/package.py | 8 + .../repos/builtin/packages/zstr/package.py | 2 + .../repos/builtin/packages/zziplib/package.py | 2 + .../packages/gcc/package.py | 15 +- .../packages/{a => pkg-a}/package.py | 4 +- .../packages/{b => pkg-b}/package.py | 2 +- .../duplicates.test/packages/python-venv | 1 + .../repos/tutorial/packages/mpich/package.py | 14 +- 4705 files changed, 50129 insertions(+), 24393 deletions(-) create mode 100644 .devcontainer/devcontainer.json create mode 100755 .devcontainer/postCreateCommand.sh rename .github/workflows/{ => bin}/bootstrap-test.sh (53%) rename .github/workflows/{ => bin}/execute_installer.ps1 (100%) rename .github/workflows/{ => bin}/generate_spack_yaml_containerize.sh (100%) rename .github/workflows/{ => bin}/setup_git.ps1 (100%) rename .github/workflows/{ => bin}/setup_git.sh (100%) rename .github/workflows/{ => bin}/system_shortcut_check.ps1 (100%) delete mode 100755 .github/workflows/install_spack.sh create mode 100644 .github/workflows/requirements/style/requirements.txt delete mode 100644 .github/workflows/style/requirements.txt delete mode 100644 .github/workflows/windows_python.yml delete mode 100644 etc/spack/defaults/cray/modules.yaml create mode 100644 lib/spack/docs/_templates/layout.html create mode 100644 lib/spack/external/patches/ruamelyaml.patch create mode 100644 lib/spack/spack/build_systems/compiler.py delete mode 100644 lib/spack/spack/ci_needs_workaround.py delete mode 100644 lib/spack/spack/ci_optimization.py delete mode 100644 lib/spack/spack/compilers/dpcpp.py create mode 100644 lib/spack/spack/hooks/autopush.py create mode 100644 lib/spack/spack/hooks/windows_runtime_linkage.py delete mode 100644 lib/spack/spack/operating_systems/cray_backend.py delete mode 100644 lib/spack/spack/operating_systems/cray_frontend.py delete mode 100644 lib/spack/spack/solver/heuristic_separate.lp create mode 100644 lib/spack/spack/solver/libc_compatibility.lp create mode 100644 lib/spack/spack/test/cmd/edit.py delete mode 100644 lib/spack/spack/test/operating_system.py create mode 100644 lib/spack/spack/test/solver/intermediate.py create mode 100644 lib/spack/spack/test/util/libc.py create mode 100644 lib/spack/spack/util/libc.py delete mode 100644 share/spack/gitlab/cloud_pipelines/configs/linux/neoverse_n1/ci.yaml delete mode 100644 share/spack/gitlab/cloud_pipelines/configs/linux/skylake_avx512/ci.yaml rename share/spack/gitlab/cloud_pipelines/configs/linux/{icelake => x86_64_v4}/ci.yaml (87%) create mode 100644 share/spack/gitlab/cloud_pipelines/configs/win64/ci.yaml create mode 100644 share/spack/gitlab/cloud_pipelines/configs/win64/config.yaml create mode 100644 share/spack/gitlab/cloud_pipelines/configs/win64/packages.yaml create mode 100644 share/spack/gitlab/cloud_pipelines/configs/win64/x86_64/ci.yaml create mode 100644 share/spack/gitlab/cloud_pipelines/configs/win64/x86_64/packages.yaml create mode 100644 share/spack/gitlab/cloud_pipelines/scripts/common/expand_vars.py create mode 100755 share/spack/gitlab/cloud_pipelines/scripts/pcluster/setup-pcluster.sh delete mode 100644 share/spack/gitlab/cloud_pipelines/stacks/aws-pcluster-icelake/spack.yaml delete mode 100644 share/spack/gitlab/cloud_pipelines/stacks/aws-pcluster-neoverse_n1/spack.yaml create mode 100644 share/spack/gitlab/cloud_pipelines/stacks/aws-pcluster-neoverse_v1/packages.yaml delete mode 100644 share/spack/gitlab/cloud_pipelines/stacks/aws-pcluster-skylake/spack.yaml create mode 100644 share/spack/gitlab/cloud_pipelines/stacks/aws-pcluster-x86_64_v4/packages.yaml create mode 100644 share/spack/gitlab/cloud_pipelines/stacks/aws-pcluster-x86_64_v4/spack.yaml create mode 100644 share/spack/gitlab/cloud_pipelines/stacks/developer-tools-manylinux2014/spack.yaml delete mode 100644 share/spack/gitlab/cloud_pipelines/stacks/developer-tools/spack.yaml create mode 100644 share/spack/gitlab/cloud_pipelines/stacks/windows-vis/spack.yaml delete mode 100644 share/spack/gitlab/nersc_pipeline.yml delete mode 100644 share/spack/templates/container/centos_7.dockerfile rename share/spack/templates/container/{centos_stream.dockerfile => centos_stream9.dockerfile} (83%) rename share/spack/templates/container/{fedora_38.dockerfile => fedora.dockerfile} (100%) delete mode 100644 share/spack/templates/container/fedora_37.dockerfile create mode 100644 share/spack/templates/container/ubuntu_2404.dockerfile create mode 100644 var/spack/repos/builtin.mock/packages/7zip/package.py create mode 100644 var/spack/repos/builtin.mock/packages/deprecated-client/package.py create mode 100644 var/spack/repos/builtin.mock/packages/git-ref-package/package.py create mode 100644 var/spack/repos/builtin.mock/packages/glibc/package.py create mode 100644 var/spack/repos/builtin.mock/packages/invalid-github-pull-commits-patch-url/package.py create mode 100644 var/spack/repos/builtin.mock/packages/no-redistribute-dependent/package.py create mode 100644 var/spack/repos/builtin.mock/packages/no-redistribute/package.py rename var/spack/repos/builtin.mock/packages/{a => pkg-a}/package.py (95%) rename var/spack/repos/builtin.mock/packages/{b => pkg-b}/package.py (96%) rename var/spack/repos/builtin.mock/packages/{c => pkg-c}/package.py (95%) rename var/spack/repos/builtin.mock/packages/{e => pkg-e}/package.py (95%) create mode 100644 var/spack/repos/builtin.mock/packages/python-venv/package.py create mode 100644 var/spack/repos/builtin.mock/packages/sombrero/package.py create mode 100644 var/spack/repos/builtin/packages/acfl/detection_test.yaml create mode 100644 var/spack/repos/builtin/packages/acts-algebra-plugins/package.py create mode 100644 var/spack/repos/builtin/packages/adios2/2.10-enable-rocm6.patch create mode 100644 var/spack/repos/builtin/packages/adios2/2.7-fix-missing-cstdint-include.patch create mode 100644 var/spack/repos/builtin/packages/amdlibm/libm-ose-SconsSpack.patch create mode 100644 var/spack/repos/builtin/packages/aocc/detection_test.yaml create mode 100644 var/spack/repos/builtin/packages/aqlprofile/package.py create mode 100644 var/spack/repos/builtin/packages/armcimpi/package.py create mode 100644 var/spack/repos/builtin/packages/bgen/package.py create mode 100644 var/spack/repos/builtin/packages/binder/llvm_dir.patch create mode 100644 var/spack/repos/builtin/packages/binutils/gold-gcc4.patch create mode 100644 var/spack/repos/builtin/packages/blake3/package.py delete mode 100644 var/spack/repos/builtin/packages/boost/bootstrap-path.patch create mode 100644 var/spack/repos/builtin/packages/camp/camp-rocm6.patch delete mode 100644 var/spack/repos/builtin/packages/candle-benchmarks/package.py create mode 100644 var/spack/repos/builtin/packages/castep/package.py create mode 100644 var/spack/repos/builtin/packages/cce/detection_test.yaml create mode 100644 var/spack/repos/builtin/packages/cce/package.py create mode 100644 var/spack/repos/builtin/packages/cellranger/package.py create mode 100644 var/spack/repos/builtin/packages/cgns/gcc14.patch create mode 100644 var/spack/repos/builtin/packages/chai/change_mpi_target_name_umpire_patch.patch create mode 100644 var/spack/repos/builtin/packages/chapel/fix_spack_cc_wrapper_in_cray_prgenv.patch create mode 100644 var/spack/repos/builtin/packages/charmpp/ofi-crayshasta-arm.patch delete mode 100644 var/spack/repos/builtin/packages/clingo/setuptools-2.patch create mode 100644 var/spack/repos/builtin/packages/cmake/mr-9623.patch rename var/spack/repos/builtin/packages/{maphyspp => composyx}/package.py (54%) create mode 100644 var/spack/repos/builtin/packages/covfie/package.py create mode 100644 var/spack/repos/builtin/packages/crtm/v3.1.0-skylabv8.installprefix.patch delete mode 100644 var/spack/repos/builtin/packages/cutlang/package.py create mode 100644 var/spack/repos/builtin/packages/dcmtk/tiff-3.6.7.patch create mode 100755 var/spack/repos/builtin/packages/dctz/package.py delete mode 100644 var/spack/repos/builtin/packages/dd4hep/tbb-workarounds.patch delete mode 100644 var/spack/repos/builtin/packages/dd4hep/tbb2.patch create mode 100644 var/spack/repos/builtin/packages/dedisp/package.py create mode 100644 var/spack/repos/builtin/packages/detray/package.py create mode 100644 var/spack/repos/builtin/packages/dfelibs/package.py create mode 100644 var/spack/repos/builtin/packages/dla-future-fortran/package.py delete mode 100644 var/spack/repos/builtin/packages/dpcpp/package.py create mode 100644 var/spack/repos/builtin/packages/e4s-alc/package.py create mode 100644 var/spack/repos/builtin/packages/editorconfig/package.py delete mode 100644 var/spack/repos/builtin/packages/edm4hep/test-deps.patch create mode 100644 var/spack/repos/builtin/packages/exodusii/Fix-ioss-tpl.patch create mode 100644 var/spack/repos/builtin/packages/fastor/package.py create mode 100644 var/spack/repos/builtin/packages/fj/detection_test.yaml delete mode 100644 var/spack/repos/builtin/packages/flecsale/package.py create mode 100644 var/spack/repos/builtin/packages/fmt/fmt-no-variable-initialize_10.0.0.patch create mode 100644 var/spack/repos/builtin/packages/g4nudexlib/package.py create mode 100644 var/spack/repos/builtin/packages/g4urrpt/package.py create mode 100644 var/spack/repos/builtin/packages/generate-ninja/package.py create mode 100644 var/spack/repos/builtin/packages/geomodel/package.py create mode 100644 var/spack/repos/builtin/packages/geopm-runtime/package.py delete mode 100644 var/spack/repos/builtin/packages/geopm/package.py delete mode 100644 var/spack/repos/builtin/packages/ginkgo/1.4.0_dpcpp_use_old_standard.patch create mode 100644 var/spack/repos/builtin/packages/ginkgo/ginkgo-dpcpp-intrinsincs-oneapi-2024.1.patch create mode 100644 var/spack/repos/builtin/packages/gobject-introspection/sbang-1.60.2.patch create mode 100644 var/spack/repos/builtin/packages/gocryptfs/package.py create mode 100644 var/spack/repos/builtin/packages/gprofng-gui/package.py create mode 100644 var/spack/repos/builtin/packages/gtfsort/package.py create mode 100644 var/spack/repos/builtin/packages/hdf5/hdf5_1_14_3_fpe.patch create mode 100644 var/spack/repos/builtin/packages/heimdall/package.py delete mode 100644 var/spack/repos/builtin/packages/hip/0011-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.0.2.patch delete mode 100644 var/spack/repos/builtin/packages/hip/0012-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.2.0.patch delete mode 100644 var/spack/repos/builtin/packages/hip/0012-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.2.1.patch create mode 100644 var/spack/repos/builtin/packages/hip/0014-remove-compiler-rt-linkage-for-host.6.1.patch create mode 100644 var/spack/repos/builtin/packages/hipblaslt/0001-Set-LLVM_Path-Add-Hiblas-Include-to-CmakeLists-6.1.Patch create mode 100644 var/spack/repos/builtin/packages/hipblaslt/001_Set_LLVM_Paths_And_Add_Includes.patch create mode 100644 var/spack/repos/builtin/packages/hipblaslt/package.py create mode 100644 var/spack/repos/builtin/packages/hipcc/0014-remove-compiler-rt-linkage-for-host.6.0.patch create mode 100644 var/spack/repos/builtin/packages/hipcc/0014-remove-compiler-rt-linkage-for-host.6.1.patch create mode 100644 var/spack/repos/builtin/packages/hipcc/package.py delete mode 100644 var/spack/repos/builtin/packages/hipcub/find-hip-cuda-rocm-5.1.patch create mode 100644 var/spack/repos/builtin/packages/hipify-clang/0003-install-hipify-clang-in-bin-dir-and-llvm-clangs-head.patch create mode 100644 var/spack/repos/builtin/packages/hipsolver/0001-suite-sparse-include-path-6.1.1.patch create mode 100644 var/spack/repos/builtin/packages/hipsolver/001-suite-sparse-include-path.patch create mode 100644 var/spack/repos/builtin/packages/hipsparselt/0001-update-llvm-path-add-hipsparse-include-dir-for-spack-6.1.patch create mode 100644 var/spack/repos/builtin/packages/hipsparselt/0001-update-llvm-path-add-hipsparse-include-dir-for-spack.patch create mode 100644 var/spack/repos/builtin/packages/hipsparselt/package.py create mode 100644 var/spack/repos/builtin/packages/hpctoolkit/correcting-hsa-include-path.patch delete mode 100644 var/spack/repos/builtin/packages/hsakmt-roct/0001-Remove-compiler-support-libraries-and-libudev-as-req.patch create mode 100644 var/spack/repos/builtin/packages/hypre/hypre-precision-fix.patch delete mode 100644 var/spack/repos/builtin/packages/intel-daal/package.py delete mode 100644 var/spack/repos/builtin/packages/intel-ipp/package.py create mode 100644 var/spack/repos/builtin/packages/intel-oneapi-compilers-classic/detection_test.yaml create mode 100644 var/spack/repos/builtin/packages/intel-oneapi-compilers/detection_test.yaml create mode 100644 var/spack/repos/builtin/packages/intel-oneapi-runtime/package.py delete mode 100644 var/spack/repos/builtin/packages/iqtree2/package.py create mode 100644 var/spack/repos/builtin/packages/julia/julia-1.10-rm-suite-sparse-cuda-stubs.patch create mode 100644 var/spack/repos/builtin/packages/kakoune-lsp/package.py create mode 100644 var/spack/repos/builtin/packages/kentutils/fix-mysql-options-gcc13.patch create mode 100644 var/spack/repos/builtin/packages/kentutils/mysql-zlib-workaround.patch create mode 100644 var/spack/repos/builtin/packages/kripke/001-remove-googletest-from-cmake.patch create mode 100644 var/spack/repos/builtin/packages/lammps-example-plugin/package.py create mode 100644 var/spack/repos/builtin/packages/lc-framework/package.py create mode 100644 var/spack/repos/builtin/packages/lci/package.py delete mode 100644 var/spack/repos/builtin/packages/legion/update-hip-path-legion-23.06.0.patch delete mode 100644 var/spack/repos/builtin/packages/libc/package.py create mode 100644 var/spack/repos/builtin/packages/libfort/package.py create mode 100644 var/spack/repos/builtin/packages/libgtop/package.py create mode 100644 var/spack/repos/builtin/packages/libgudev/package.py create mode 100644 var/spack/repos/builtin/packages/libpressio-adios1/package.py create mode 100644 var/spack/repos/builtin/packages/libpressio-dataset/package.py create mode 100755 var/spack/repos/builtin/packages/libpressio-jit/package.py create mode 100644 var/spack/repos/builtin/packages/libpressio-predict/package.py rename var/spack/repos/builtin/packages/libsigsegv/{patch.new_config_guess => new_config_guess.patch} (100%) create mode 100644 var/spack/repos/builtin/packages/libtraceevent/package.py create mode 100644 var/spack/repos/builtin/packages/libvdwxc/fftw-detection.patch create mode 100644 var/spack/repos/builtin/packages/libwnck/package.py delete mode 100644 var/spack/repos/builtin/packages/libxc/nvhpc-configure.patch delete mode 100644 var/spack/repos/builtin/packages/libxc/nvhpc-libtool.patch create mode 100644 var/spack/repos/builtin/packages/llvm-amdgpu/detection_test.yaml create mode 100644 var/spack/repos/builtin/packages/llvm/llvm17-18-thread.patch create mode 100644 var/spack/repos/builtin/packages/llvm/llvm17-fujitsu.patch create mode 100644 var/spack/repos/builtin/packages/magic-enum/package.py create mode 100644 var/spack/repos/builtin/packages/matrix-switch/package.py create mode 100644 var/spack/repos/builtin/packages/mepo/package.py delete mode 100644 var/spack/repos/builtin/packages/mesa18/autotools-x11-nodri.patch delete mode 100644 var/spack/repos/builtin/packages/mesa18/multiple-symbols_hash.patch delete mode 100644 var/spack/repos/builtin/packages/mesa18/package.py create mode 100644 var/spack/repos/builtin/packages/metacarpa/package.py create mode 100644 var/spack/repos/builtin/packages/mfem/mfem-4.7.patch delete mode 100644 var/spack/repos/builtin/packages/mfem/mfem-hip.patch delete mode 100644 var/spack/repos/builtin/packages/migraphx/0002-restrict-python-2.7-usage.patch create mode 100644 var/spack/repos/builtin/packages/miopen-hip/0002-add-include-dir-miopen-hip-6.1.0.patch delete mode 100644 var/spack/repos/builtin/packages/miopen-tensile/package.py create mode 100644 var/spack/repos/builtin/packages/mivisionx/0002-add-half-include-path-for-tests-6.1.0.patch create mode 100644 var/spack/repos/builtin/packages/msvc/detection_test.yaml create mode 100644 var/spack/repos/builtin/packages/msvc/package.py create mode 100644 var/spack/repos/builtin/packages/nag/detection_test.yaml create mode 100644 var/spack/repos/builtin/packages/nb/package.py create mode 100644 var/spack/repos/builtin/packages/ncurses/rxvt_unicode_6_4.patch create mode 100644 var/spack/repos/builtin/packages/neic-finitefault/fortran-filename-length.patch create mode 100644 var/spack/repos/builtin/packages/neic-finitefault/package.py create mode 100644 var/spack/repos/builtin/packages/node-js/fix-old-glibc-random-headers.patch create mode 100644 var/spack/repos/builtin/packages/nopayloadclient/package.py create mode 100644 var/spack/repos/builtin/packages/nvhpc/detection_test.yaml delete mode 100644 var/spack/repos/builtin/packages/oce/sierra.patch create mode 100644 var/spack/repos/builtin/packages/ollama/package.py create mode 100644 var/spack/repos/builtin/packages/omm/package.py create mode 100644 var/spack/repos/builtin/packages/openbabel/cmake-time.patch create mode 100644 var/spack/repos/builtin/packages/opencl-icd-loader/package.py create mode 100644 var/spack/repos/builtin/packages/openfast/hub_seg_fault.patch create mode 100644 var/spack/repos/builtin/packages/openmpi/pmix_getline_pmix_version-prte.patch create mode 100644 var/spack/repos/builtin/packages/openmpi/pmix_getline_pmix_version.patch create mode 100644 var/spack/repos/builtin/packages/paraview/kits_with_catalyst_5_12.patch create mode 100644 var/spack/repos/builtin/packages/paraview/vtk_alias_hdf5.patch create mode 100644 var/spack/repos/builtin/packages/parthenon/package.py create mode 100644 var/spack/repos/builtin/packages/pass/package.py create mode 100644 var/spack/repos/builtin/packages/perl-http-tiny/package.py create mode 100644 var/spack/repos/builtin/packages/pgi/detection_test.yaml delete mode 100644 var/spack/repos/builtin/packages/podio/cpack.patch delete mode 100644 var/spack/repos/builtin/packages/podio/dictloading.patch delete mode 100644 var/spack/repos/builtin/packages/podio/python-tests.patch create mode 100755 var/spack/repos/builtin/packages/poorjit/package.py create mode 100644 var/spack/repos/builtin/packages/prettier/package.py create mode 100644 var/spack/repos/builtin/packages/proj/proj-7-tiff.patch create mode 100644 var/spack/repos/builtin/packages/proj/proj-8-tiff.patch create mode 100644 var/spack/repos/builtin/packages/psrdada/package.py create mode 100644 var/spack/repos/builtin/packages/py-astropy-iers-data/package.py create mode 100644 var/spack/repos/builtin/packages/py-bravado-core/package.py create mode 100644 var/spack/repos/builtin/packages/py-bravado/package.py create mode 100644 var/spack/repos/builtin/packages/py-cig-pythia/package.py create mode 100644 var/spack/repos/builtin/packages/py-flash-attn/package.py create mode 100644 var/spack/repos/builtin/packages/py-folium/package.py create mode 100644 var/spack/repos/builtin/packages/py-gdown/package.py create mode 100644 var/spack/repos/builtin/packages/py-geopmdpy/package.py create mode 100644 var/spack/repos/builtin/packages/py-geopmpy/package.py create mode 100644 var/spack/repos/builtin/packages/py-glmnet-python/package.py create mode 100644 var/spack/repos/builtin/packages/py-globus-cli/package.py create mode 100644 var/spack/repos/builtin/packages/py-grpcio/30522.diff create mode 100644 var/spack/repos/builtin/packages/py-janus/package.py create mode 100644 var/spack/repos/builtin/packages/py-jcb/package.py create mode 100644 var/spack/repos/builtin/packages/py-jproperties/package.py create mode 100644 var/spack/repos/builtin/packages/py-junit2html/package.py create mode 100644 var/spack/repos/builtin/packages/py-kneaddata/package.py create mode 100644 var/spack/repos/builtin/packages/py-kornia-rs/package.py create mode 100644 var/spack/repos/builtin/packages/py-libsonata/package.py create mode 100644 var/spack/repos/builtin/packages/py-line-profiler/gettimeofday_py39.patch delete mode 100644 var/spack/repos/builtin/packages/py-matplotlib/freetype-include-path.patch create mode 100644 var/spack/repos/builtin/packages/py-mne-bids/package.py create mode 100644 var/spack/repos/builtin/packages/py-modules-gui/package.py create mode 100644 var/spack/repos/builtin/packages/py-neptune-client/package.py create mode 100644 var/spack/repos/builtin/packages/py-nuitka/package.py create mode 100644 var/spack/repos/builtin/packages/py-obspy/package.py create mode 100644 var/spack/repos/builtin/packages/py-okada-wrapper/package.py create mode 100644 var/spack/repos/builtin/packages/py-optree/package.py create mode 100644 var/spack/repos/builtin/packages/py-pretty-errors/package.py create mode 100644 var/spack/repos/builtin/packages/py-pyaml-env/package.py create mode 100644 var/spack/repos/builtin/packages/py-pygmt/package.py create mode 100644 var/spack/repos/builtin/packages/py-pyhdf/package.py create mode 100644 var/spack/repos/builtin/packages/py-pylith/package.py create mode 100644 var/spack/repos/builtin/packages/py-pyopengl/package.py create mode 100644 var/spack/repos/builtin/packages/py-pyrocko/package.py create mode 100644 var/spack/repos/builtin/packages/py-pyseer/package.py create mode 100644 var/spack/repos/builtin/packages/py-pytest-mpi/package.py create mode 100644 var/spack/repos/builtin/packages/py-quantiphy/package.py create mode 100644 var/spack/repos/builtin/packages/py-simpy/package.py create mode 100644 var/spack/repos/builtin/packages/py-swagger-spec-validator/package.py create mode 100644 var/spack/repos/builtin/packages/py-tensorflow/absl_neon.patch create mode 100644 var/spack/repos/builtin/packages/py-transformer-engine/package.py create mode 100644 var/spack/repos/builtin/packages/py-trx-python/package.py create mode 100644 var/spack/repos/builtin/packages/py-vascpy/package.py create mode 100644 var/spack/repos/builtin/packages/py-wxflow/package.py create mode 100644 var/spack/repos/builtin/packages/py-your/package.py create mode 100644 var/spack/repos/builtin/packages/python-venv/package.py create mode 100644 var/spack/repos/builtin/packages/qctool/package.py create mode 100644 var/spack/repos/builtin/packages/qpdf/package.py create mode 100644 var/spack/repos/builtin/packages/qt/qt51514-oneapi.patch create mode 100644 var/spack/repos/builtin/packages/r-asreml/package.py create mode 100644 var/spack/repos/builtin/packages/rayleigh/package.py delete mode 100644 var/spack/repos/builtin/packages/rccl/0002-Fix-numactl-rocm-smi-path-issue.patch create mode 100644 var/spack/repos/builtin/packages/rdma-core/libdrm.patch delete mode 100644 var/spack/repos/builtin/packages/rocalution/0003-fix-compilation-for-rocalution-5.2.0.patch delete mode 100644 var/spack/repos/builtin/packages/rocblas/0003-Fix-rocblas-gentest.patch delete mode 100644 var/spack/repos/builtin/packages/rocfft/0003-Fix-clients-fftw3-include-dirs-rocm-4.5.patch create mode 100644 var/spack/repos/builtin/packages/rocfft/0005-Fix-clients-tests-include-rocrand-fftw-include-dir-rocm-6.0.0.patch create mode 100644 var/spack/repos/builtin/packages/rocm-openmp-extras/0001-Linking-hsakmt-libdrm-and-numactl-libraries-6.1.patch delete mode 100644 var/spack/repos/builtin/packages/rocm-smi/package.py delete mode 100644 var/spack/repos/builtin/packages/rocm-validation-suite/005-cleanup-path-reference-donot-download-googletest-yaml.patch delete mode 100644 var/spack/repos/builtin/packages/rocm-validation-suite/006-library-path.patch create mode 100644 var/spack/repos/builtin/packages/rocm-validation-suite/009-replacing-rocm-path-with-package-path-6.1.patch create mode 100644 var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests-5.6.patch create mode 100644 var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests-5.7.patch create mode 100644 var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests.patch create mode 100644 var/spack/repos/builtin/packages/rocprofiler-dev/0003-disable-tests.patch delete mode 100644 var/spack/repos/builtin/packages/rocsolver/fmt-8.1-compatibility.patch delete mode 100644 var/spack/repos/builtin/packages/rocsparse/0003-fix-navi-1x-rocm-4.5.patch delete mode 100644 var/spack/repos/builtin/packages/rocsparse/0003-fix-navi-1x-rocm-5.2.patch create mode 100644 var/spack/repos/builtin/packages/rosco/intel-oneapi-29.patch create mode 100644 var/spack/repos/builtin/packages/rosco/intel-oneapi-2x.patch create mode 100644 var/spack/repos/builtin/packages/rosco/package.py create mode 100644 var/spack/repos/builtin/packages/rpp/0003-changes-to-rpp-unit-tests-6.1.patch create mode 100644 var/spack/repos/builtin/packages/scine-qcmaquis/cmake_molcas_interface.patch create mode 100644 var/spack/repos/builtin/packages/scotch/parmetis-mpi.patch create mode 100644 var/spack/repos/builtin/packages/seacr/package.py create mode 100644 var/spack/repos/builtin/packages/seqfu/package.py create mode 100644 var/spack/repos/builtin/packages/seqfu/wno_incompatible_pointer_types.patch create mode 100644 var/spack/repos/builtin/packages/spaceranger/package.py create mode 100644 var/spack/repos/builtin/packages/spatialdata/package.py create mode 100644 var/spack/repos/builtin/packages/su2/remove_preconfigure_timestamp_check.patch create mode 100644 var/spack/repos/builtin/packages/sundials/sundials-hip-platform.patch create mode 100644 var/spack/repos/builtin/packages/systemd/package.py create mode 100644 var/spack/repos/builtin/packages/szx/package.py create mode 100644 var/spack/repos/builtin/packages/tamaas/recent_compilers.patch create mode 100644 var/spack/repos/builtin/packages/tau/tau-rocm-disable-llvm-plugin.patch create mode 100644 var/spack/repos/builtin/packages/tests-sos/package.py create mode 100644 var/spack/repos/builtin/packages/timew/package.py create mode 100644 var/spack/repos/builtin/packages/tiny-tensor-compiler/package.py create mode 100644 var/spack/repos/builtin/packages/umpire/dual_blt_import_umpire_2022.10_2023.06.patch create mode 100644 var/spack/repos/builtin/packages/umpire/export_includes.patch create mode 100644 var/spack/repos/builtin/packages/upcxx/fix_configure_ldflags.patch create mode 100644 var/spack/repos/builtin/packages/usearch/0001-Don-t-statically-link.patch create mode 100644 var/spack/repos/builtin/packages/vtk-m/vtkm-mr3215-ext-geom-fix.patch create mode 100644 var/spack/repos/builtin/packages/xbae/package.py create mode 100644 var/spack/repos/builtin/packages/xeniumranger/package.py create mode 100644 var/spack/repos/builtin/packages/xl/detection_test.yaml create mode 100644 var/spack/repos/builtin/packages/xl/package.py delete mode 100644 var/spack/repos/builtin/packages/xlc/detection_test.yaml delete mode 100644 var/spack/repos/builtin/packages/xlc/package.py delete mode 100644 var/spack/repos/builtin/packages/xlf/detection_test.yaml delete mode 100644 var/spack/repos/builtin/packages/xlf/package.py create mode 100644 var/spack/repos/builtin/packages/yq/package.py create mode 100644 var/spack/repos/builtin/packages/zerosum/package.py create mode 100644 var/spack/repos/builtin/packages/zip/11-typo-it-is-ambiguities-not-amgibuities.patch create mode 100644 var/spack/repos/builtin/packages/zip/12-gcc14-no-implicit-declarations-fix.patch delete mode 100644 var/spack/repos/builtin/packages/zlib-ng/pr-1542.patch delete mode 100644 var/spack/repos/builtin/packages/zlib-ng/pr-1546.patch delete mode 100644 var/spack/repos/builtin/packages/zlib-ng/pr-1561.patch delete mode 100644 var/spack/repos/builtin/packages/zlib-ng/pr-1562.patch create mode 100644 var/spack/repos/builtin/packages/zlib-ng/pr-1698.patch rename var/spack/repos/compiler_runtime.test/packages/{a => pkg-a}/package.py (87%) rename var/spack/repos/compiler_runtime.test/packages/{b => pkg-b}/package.py (93%) create mode 120000 var/spack/repos/duplicates.test/packages/python-venv diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 00000000000000..ec4c2690b70e72 --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,4 @@ +{ + "image": "ghcr.io/spack/ubuntu20.04-runner-amd64-gcc-11.4:2023.08.01", + "postCreateCommand": "./.devcontainer/postCreateCommand.sh" +} diff --git a/.devcontainer/postCreateCommand.sh b/.devcontainer/postCreateCommand.sh new file mode 100755 index 00000000000000..e319719a37a54a --- /dev/null +++ b/.devcontainer/postCreateCommand.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +# Load spack environment at terminal startup +cat <> /root/.bashrc +. /workspaces/spack/share/spack/setup-env.sh +EOF + +# Load spack environment in this script +. /workspaces/spack/share/spack/setup-env.sh + +# Ensure generic targets for maximum matching with buildcaches +spack config --scope site add "packages:all:require:[target=x86_64_v3]" +spack config --scope site add "concretizer:targets:granularity:generic" + +# Find compiler and install gcc-runtime +spack compiler find --scope site + +# Setup buildcaches +spack mirror add --scope site develop https://binaries.spack.io/develop +spack buildcache keys --install --trust diff --git a/.github/dependabot.yml b/.github/dependabot.yml index a5b42ffcf76b85..b19c9381ecf178 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -12,6 +12,7 @@ updates: interval: "daily" # Requirements to run style checks - package-ecosystem: "pip" - directory: "/.github/workflows/style" + directories: + - "/.github/workflows/requirements/*" schedule: interval: "daily" diff --git a/.github/workflows/audit.yaml b/.github/workflows/audit.yaml index 9abe65f6ad46e5..e412205abc80be 100644 --- a/.github/workflows/audit.yaml +++ b/.github/workflows/audit.yaml @@ -17,33 +17,53 @@ concurrency: jobs: # Run audits on all the packages in the built-in repository package-audits: - runs-on: ${{ matrix.operating_system }} + runs-on: ${{ matrix.system.os }} strategy: matrix: - operating_system: ["ubuntu-latest", "macos-latest"] + system: + - { os: windows-latest, shell: 'powershell Invoke-Expression -Command "./share/spack/qa/windows_test_setup.ps1"; {0}' } + - { os: ubuntu-latest, shell: bash } + - { os: macos-latest, shell: bash } + defaults: + run: + shell: ${{ matrix.system.shell }} steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # @v2 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # @v2 + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f with: python-version: ${{inputs.python_version}} - name: Install Python packages run: | pip install --upgrade pip setuptools pytest coverage[toml] + - name: Setup for Windows run + if: runner.os == 'Windows' + run: | + python -m pip install --upgrade pywin32 - name: Package audits (with coverage) - if: ${{ inputs.with_coverage == 'true' }} + if: ${{ inputs.with_coverage == 'true' && runner.os != 'Windows' }} run: | . share/spack/setup-env.sh coverage run $(which spack) audit packages - coverage run $(which spack) audit externals + coverage run $(which spack) -d audit externals coverage combine coverage xml - name: Package audits (without coverage) - if: ${{ inputs.with_coverage == 'false' }} + if: ${{ inputs.with_coverage == 'false' && runner.os != 'Windows' }} run: | - . share/spack/setup-env.sh - $(which spack) audit packages - $(which spack) audit externals - - uses: codecov/codecov-action@54bcd8715eee62d40e33596ef5e8f0f48dbbccab # @v2.1.0 + . share/spack/setup-env.sh + spack -d audit packages + spack -d audit externals + - name: Package audits (without coverage) + if: ${{ runner.os == 'Windows' }} + run: | + . share/spack/setup-env.sh + spack -d audit packages + ./share/spack/qa/validate_last_exit.ps1 + spack -d audit externals + ./share/spack/qa/validate_last_exit.ps1 + - uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 if: ${{ inputs.with_coverage == 'true' }} with: flags: unittests,audits + token: ${{ secrets.CODECOV_TOKEN }} + verbose: true diff --git a/.github/workflows/bootstrap-test.sh b/.github/workflows/bin/bootstrap-test.sh similarity index 53% rename from .github/workflows/bootstrap-test.sh rename to .github/workflows/bin/bootstrap-test.sh index b51db3d1b7422a..563eb286433c4f 100755 --- a/.github/workflows/bootstrap-test.sh +++ b/.github/workflows/bin/bootstrap-test.sh @@ -1,7 +1,8 @@ #!/bin/bash -set -ex +set -e source share/spack/setup-env.sh +$PYTHON bin/spack bootstrap disable github-actions-v0.4 $PYTHON bin/spack bootstrap disable spack-install -$PYTHON bin/spack -d solve zlib +$PYTHON bin/spack $SPACK_FLAGS solve zlib tree $BOOTSTRAP/store exit 0 diff --git a/.github/workflows/execute_installer.ps1 b/.github/workflows/bin/execute_installer.ps1 similarity index 100% rename from .github/workflows/execute_installer.ps1 rename to .github/workflows/bin/execute_installer.ps1 diff --git a/.github/workflows/generate_spack_yaml_containerize.sh b/.github/workflows/bin/generate_spack_yaml_containerize.sh similarity index 100% rename from .github/workflows/generate_spack_yaml_containerize.sh rename to .github/workflows/bin/generate_spack_yaml_containerize.sh diff --git a/.github/workflows/setup_git.ps1 b/.github/workflows/bin/setup_git.ps1 similarity index 100% rename from .github/workflows/setup_git.ps1 rename to .github/workflows/bin/setup_git.ps1 diff --git a/.github/workflows/setup_git.sh b/.github/workflows/bin/setup_git.sh similarity index 100% rename from .github/workflows/setup_git.sh rename to .github/workflows/bin/setup_git.sh diff --git a/.github/workflows/system_shortcut_check.ps1 b/.github/workflows/bin/system_shortcut_check.ps1 similarity index 100% rename from .github/workflows/system_shortcut_check.ps1 rename to .github/workflows/bin/system_shortcut_check.ps1 diff --git a/.github/workflows/bootstrap.yml b/.github/workflows/bootstrap.yml index 4e52079ed925b5..a3cf808dd2e335 100644 --- a/.github/workflows/bootstrap.yml +++ b/.github/workflows/bootstrap.yml @@ -13,71 +13,34 @@ concurrency: cancel-in-progress: true jobs: - fedora-clingo-sources: + distros-clingo-sources: runs-on: ubuntu-latest - container: "fedora:latest" + container: ${{ matrix.image }} + strategy: + matrix: + image: ["fedora:latest", "opensuse/leap:latest"] steps: - - name: Install dependencies + - name: Setup Fedora + if: ${{ matrix.image == 'fedora:latest' }} run: | dnf install -y \ - bzip2 curl file gcc-c++ gcc gcc-gfortran git gnupg2 gzip \ + bzip2 curl file gcc-c++ gcc gcc-gfortran git gzip \ make patch unzip which xz python3 python3-devel tree \ cmake bison bison-devel libstdc++-static - - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - with: - fetch-depth: 0 - - name: Setup non-root user - run: | - # See [1] below - git config --global --add safe.directory /__w/spack/spack - useradd spack-test && mkdir -p ~spack-test - chown -R spack-test . ~spack-test - - name: Setup repo - shell: runuser -u spack-test -- bash {0} - run: | - git --version - . .github/workflows/setup_git.sh - - name: Bootstrap clingo - shell: runuser -u spack-test -- bash {0} - run: | - source share/spack/setup-env.sh - spack bootstrap disable github-actions-v0.5 - spack bootstrap disable github-actions-v0.4 - spack external find cmake bison - spack -d solve zlib - tree ~/.spack/bootstrap/store/ - - ubuntu-clingo-sources: - runs-on: ubuntu-latest - container: "ubuntu:latest" - steps: - - name: Install dependencies - env: - DEBIAN_FRONTEND: noninteractive + - name: Setup OpenSUSE + if: ${{ matrix.image == 'opensuse/leap:latest' }} run: | - apt-get update -y && apt-get upgrade -y - apt-get install -y \ - bzip2 curl file g++ gcc gfortran git gnupg2 gzip \ - make patch unzip xz-utils python3 python3-dev tree \ + # Harden CI by applying the workaround described here: https://www.suse.com/support/kb/doc/?id=000019505 + zypper update -y || zypper update -y + zypper install -y \ + bzip2 curl file gcc-c++ gcc gcc-fortran tar git gpg2 gzip \ + make patch unzip which xz python3 python3-devel tree \ cmake bison - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: fetch-depth: 0 - - name: Setup non-root user - run: | - # See [1] below - git config --global --add safe.directory /__w/spack/spack - useradd spack-test && mkdir -p ~spack-test - chown -R spack-test . ~spack-test - - name: Setup repo - shell: runuser -u spack-test -- bash {0} - run: | - git --version - . .github/workflows/setup_git.sh - name: Bootstrap clingo - shell: runuser -u spack-test -- bash {0} run: | source share/spack/setup-env.sh spack bootstrap disable github-actions-v0.5 @@ -86,148 +49,112 @@ jobs: spack -d solve zlib tree ~/.spack/bootstrap/store/ - ubuntu-clingo-binaries-and-patchelf: - runs-on: ubuntu-latest - container: "ubuntu:latest" + clingo-sources: + runs-on: ${{ matrix.runner }} + strategy: + matrix: + runner: ['macos-13', 'macos-14', "ubuntu-latest", "windows-latest"] steps: - - name: Install dependencies - env: - DEBIAN_FRONTEND: noninteractive + - name: Setup macOS + if: ${{ matrix.runner != 'ubuntu-latest' && matrix.runner != 'windows-latest' }} run: | - apt-get update -y && apt-get upgrade -y - apt-get install -y \ - bzip2 curl file g++ gcc gfortran git gnupg2 gzip \ - make patch unzip xz-utils python3 python3-dev tree + brew install cmake bison tree - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: fetch-depth: 0 - - name: Setup non-root user - run: | - # See [1] below - git config --global --add safe.directory /__w/spack/spack - useradd spack-test && mkdir -p ~spack-test - chown -R spack-test . ~spack-test - - name: Setup repo - shell: runuser -u spack-test -- bash {0} - run: | - git --version - . .github/workflows/setup_git.sh - - name: Bootstrap clingo - shell: runuser -u spack-test -- bash {0} - run: | - source share/spack/setup-env.sh - spack -d solve zlib - tree ~/.spack/bootstrap/store/ - - opensuse-clingo-sources: - runs-on: ubuntu-latest - container: "opensuse/leap:latest" - steps: - - name: Install dependencies - run: | - # Harden CI by applying the workaround described here: https://www.suse.com/support/kb/doc/?id=000019505 - zypper update -y || zypper update -y - zypper install -y \ - bzip2 curl file gcc-c++ gcc gcc-fortran tar git gpg2 gzip \ - make patch unzip which xz python3 python3-devel tree \ - cmake bison - - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f with: - fetch-depth: 0 - - name: Setup repo - run: | - # See [1] below - git config --global --add safe.directory /__w/spack/spack - git --version - . .github/workflows/setup_git.sh + python-version: "3.12" - name: Bootstrap clingo + env: + SETUP_SCRIPT_EXT: ${{ matrix.runner == 'windows-latest' && 'ps1' || 'sh' }} + SETUP_SCRIPT_SOURCE: ${{ matrix.runner == 'windows-latest' && './' || 'source ' }} + USER_SCOPE_PARENT_DIR: ${{ matrix.runner == 'windows-latest' && '$env:userprofile' || '$HOME' }} + VALIDATE_LAST_EXIT: ${{ matrix.runner == 'windows-latest' && './share/spack/qa/validate_last_exit.ps1' || '' }} run: | - source share/spack/setup-env.sh + ${{ env.SETUP_SCRIPT_SOURCE }}share/spack/setup-env.${{ env.SETUP_SCRIPT_EXT }} spack bootstrap disable github-actions-v0.5 spack bootstrap disable github-actions-v0.4 - spack external find cmake bison + spack external find --not-buildable cmake bison spack -d solve zlib - tree ~/.spack/bootstrap/store/ + ${{ env.VALIDATE_LAST_EXIT }} + tree ${{ env.USER_SCOPE_PARENT_DIR }}/.spack/bootstrap/store/ - macos-clingo-sources: - runs-on: macos-latest + gnupg-sources: + runs-on: ${{ matrix.runner }} + strategy: + matrix: + runner: [ 'macos-13', 'macos-14', "ubuntu-latest" ] steps: - - name: Install dependencies - run: | - brew install cmake bison@2.7 tree + - name: Setup macOS + if: ${{ matrix.runner != 'ubuntu-latest' }} + run: | + brew install tree gawk + sudo rm -rf $(command -v gpg gpg2) + - name: Setup Ubuntu + if: ${{ matrix.runner == 'ubuntu-latest' }} + run: sudo rm -rf $(command -v gpg gpg2 patchelf) - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # @v2 + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: - python-version: "3.12" - - name: Bootstrap clingo + fetch-depth: 0 + - name: Bootstrap GnuPG run: | source share/spack/setup-env.sh - export PATH=/usr/local/opt/bison@2.7/bin:$PATH + spack solve zlib spack bootstrap disable github-actions-v0.5 spack bootstrap disable github-actions-v0.4 - spack external find --not-buildable cmake bison - spack -d solve zlib + spack -d gpg list tree ~/.spack/bootstrap/store/ - macos-clingo-binaries: - runs-on: ${{ matrix.macos-version }} + from-binaries: + runs-on: ${{ matrix.runner }} strategy: matrix: - macos-version: ['macos-11', 'macos-12'] + runner: ['macos-13', 'macos-14', "ubuntu-latest"] steps: - - name: Install dependencies + - name: Setup macOS + if: ${{ matrix.runner != 'ubuntu-latest' }} run: | brew install tree - - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - - name: Bootstrap clingo + # Remove GnuPG since we want to bootstrap it + sudo rm -rf /usr/local/bin/gpg + - name: Setup Ubuntu + if: ${{ matrix.runner == 'ubuntu-latest' }} run: | - set -ex - for ver in '3.7' '3.8' '3.9' '3.10' '3.11' ; do - not_found=1 - ver_dir="$(find $RUNNER_TOOL_CACHE/Python -wholename "*/${ver}.*/*/bin" | grep . || true)" - echo "Testing $ver_dir" - if [[ -d "$ver_dir" ]] ; then - if $ver_dir/python --version ; then - export PYTHON="$ver_dir/python" - not_found=0 - old_path="$PATH" - export PATH="$ver_dir:$PATH" - ./bin/spack-tmpconfig -b ./.github/workflows/bootstrap-test.sh - export PATH="$old_path" - fi - fi - # NOTE: test all pythons that exist, not all do on 12 - done - - ubuntu-clingo-binaries: - runs-on: ubuntu-20.04 - steps: + sudo rm -rf $(which gpg) $(which gpg2) $(which patchelf) - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: fetch-depth: 0 - - name: Setup repo + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f + with: + python-version: | + 3.8 + 3.9 + 3.10 + 3.11 + 3.12 + - name: Set bootstrap sources run: | - git --version - . .github/workflows/setup_git.sh + source share/spack/setup-env.sh + spack bootstrap disable github-actions-v0.4 + spack bootstrap disable spack-install - name: Bootstrap clingo run: | - set -ex - for ver in '3.7' '3.8' '3.9' '3.10' '3.11' ; do + set -e + for ver in '3.8' '3.9' '3.10' '3.11' '3.12' ; do not_found=1 ver_dir="$(find $RUNNER_TOOL_CACHE/Python -wholename "*/${ver}.*/*/bin" | grep . || true)" - echo "Testing $ver_dir" if [[ -d "$ver_dir" ]] ; then + echo "Testing $ver_dir" if $ver_dir/python --version ; then export PYTHON="$ver_dir/python" not_found=0 old_path="$PATH" export PATH="$ver_dir:$PATH" - ./bin/spack-tmpconfig -b ./.github/workflows/bootstrap-test.sh + ./bin/spack-tmpconfig -b ./.github/workflows/bin/bootstrap-test.sh export PATH="$old_path" fi fi @@ -236,122 +163,8 @@ jobs: exit 1 fi done - - ubuntu-gnupg-binaries: - runs-on: ubuntu-latest - container: "ubuntu:latest" - steps: - - name: Install dependencies - env: - DEBIAN_FRONTEND: noninteractive - run: | - apt-get update -y && apt-get upgrade -y - apt-get install -y \ - bzip2 curl file g++ gcc patchelf gfortran git gzip \ - make patch unzip xz-utils python3 python3-dev tree - - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - with: - fetch-depth: 0 - - name: Setup non-root user - run: | - # See [1] below - git config --global --add safe.directory /__w/spack/spack - useradd spack-test && mkdir -p ~spack-test - chown -R spack-test . ~spack-test - - name: Setup repo - shell: runuser -u spack-test -- bash {0} - run: | - git --version - . .github/workflows/setup_git.sh - - name: Bootstrap GnuPG - shell: runuser -u spack-test -- bash {0} - run: | - source share/spack/setup-env.sh - spack bootstrap disable github-actions-v0.4 - spack bootstrap disable spack-install - spack -d gpg list - tree ~/.spack/bootstrap/store/ - - ubuntu-gnupg-sources: - runs-on: ubuntu-latest - container: "ubuntu:latest" - steps: - - name: Install dependencies - env: - DEBIAN_FRONTEND: noninteractive - run: | - apt-get update -y && apt-get upgrade -y - apt-get install -y \ - bzip2 curl file g++ gcc patchelf gfortran git gzip \ - make patch unzip xz-utils python3 python3-dev tree \ - gawk - - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - with: - fetch-depth: 0 - - name: Setup non-root user - run: | - # See [1] below - git config --global --add safe.directory /__w/spack/spack - useradd spack-test && mkdir -p ~spack-test - chown -R spack-test . ~spack-test - - name: Setup repo - shell: runuser -u spack-test -- bash {0} - run: | - git --version - . .github/workflows/setup_git.sh - name: Bootstrap GnuPG - shell: runuser -u spack-test -- bash {0} run: | source share/spack/setup-env.sh - spack solve zlib - spack bootstrap disable github-actions-v0.5 - spack bootstrap disable github-actions-v0.4 spack -d gpg list tree ~/.spack/bootstrap/store/ - - macos-gnupg-binaries: - runs-on: macos-latest - steps: - - name: Install dependencies - run: | - brew install tree - # Remove GnuPG since we want to bootstrap it - sudo rm -rf /usr/local/bin/gpg - - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - - name: Bootstrap GnuPG - run: | - source share/spack/setup-env.sh - spack bootstrap disable github-actions-v0.4 - spack bootstrap disable spack-install - spack -d gpg list - tree ~/.spack/bootstrap/store/ - - macos-gnupg-sources: - runs-on: macos-latest - steps: - - name: Install dependencies - run: | - brew install gawk tree - # Remove GnuPG since we want to bootstrap it - sudo rm -rf /usr/local/bin/gpg - - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - - name: Bootstrap GnuPG - run: | - source share/spack/setup-env.sh - spack solve zlib - spack bootstrap disable github-actions-v0.5 - spack bootstrap disable github-actions-v0.4 - spack -d gpg list - tree ~/.spack/bootstrap/store/ - - -# [1] Distros that have patched git to resolve CVE-2022-24765 (e.g. Ubuntu patching v2.25.1) -# introduce breaking behaviorso we have to set `safe.directory` in gitconfig ourselves. -# See: -# - https://github.blog/2022-04-12-git-security-vulnerability-announced/ -# - https://github.com/actions/checkout/issues/760 -# - http://changelogs.ubuntu.com/changelogs/pool/main/g/git/git_2.25.1-1ubuntu3.3/changelog diff --git a/.github/workflows/build-containers.yml b/.github/workflows/build-containers.yml index 2350f824249958..9ef6318b38faeb 100644 --- a/.github/workflows/build-containers.yml +++ b/.github/workflows/build-containers.yml @@ -40,22 +40,22 @@ jobs: # 1: Platforms to build for # 2: Base image (e.g. ubuntu:22.04) dockerfile: [[amazon-linux, 'linux/amd64,linux/arm64', 'amazonlinux:2'], - [centos7, 'linux/amd64,linux/arm64,linux/ppc64le', 'centos:7'], - [centos-stream, 'linux/amd64,linux/arm64,linux/ppc64le', 'centos:stream'], + [centos-stream9, 'linux/amd64,linux/arm64,linux/ppc64le', 'centos:stream9'], [leap15, 'linux/amd64,linux/arm64,linux/ppc64le', 'opensuse/leap:15'], [ubuntu-focal, 'linux/amd64,linux/arm64,linux/ppc64le', 'ubuntu:20.04'], [ubuntu-jammy, 'linux/amd64,linux/arm64,linux/ppc64le', 'ubuntu:22.04'], + [ubuntu-noble, 'linux/amd64,linux/arm64,linux/ppc64le', 'ubuntu:24.04'], [almalinux8, 'linux/amd64,linux/arm64,linux/ppc64le', 'almalinux:8'], [almalinux9, 'linux/amd64,linux/arm64,linux/ppc64le', 'almalinux:9'], [rockylinux8, 'linux/amd64,linux/arm64', 'rockylinux:8'], [rockylinux9, 'linux/amd64,linux/arm64', 'rockylinux:9'], - [fedora37, 'linux/amd64,linux/arm64,linux/ppc64le', 'fedora:37'], - [fedora38, 'linux/amd64,linux/arm64,linux/ppc64le', 'fedora:38']] + [fedora39, 'linux/amd64,linux/arm64,linux/ppc64le', 'fedora:39'], + [fedora40, 'linux/amd64,linux/arm64,linux/ppc64le', 'fedora:40']] name: Build ${{ matrix.dockerfile[0] }} if: github.repository == 'spack/spack' steps: - name: Checkout - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # @v2 + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 - uses: docker/metadata-action@8e5442c4ef9f78752691e2d8f8d19755c6f78e81 id: docker_meta @@ -76,7 +76,7 @@ jobs: env: SPACK_YAML_OS: "${{ matrix.dockerfile[2] }}" run: | - .github/workflows/generate_spack_yaml_containerize.sh + .github/workflows/bin/generate_spack_yaml_containerize.sh . share/spack/setup-env.sh mkdir -p dockerfiles/${{ matrix.dockerfile[0] }} spack containerize --last-stage=bootstrap | tee dockerfiles/${{ matrix.dockerfile[0] }}/Dockerfile @@ -87,19 +87,19 @@ jobs: fi - name: Upload Dockerfile - uses: actions/upload-artifact@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 + uses: actions/upload-artifact@0b2256b8c012f0828dc542b3febcab082c67f72b with: - name: dockerfiles + name: dockerfiles_${{ matrix.dockerfile[0] }} path: dockerfiles - name: Set up QEMU - uses: docker/setup-qemu-action@68827325e0b33c7199eb31dd4e31fbe9023e06e3 + uses: docker/setup-qemu-action@49b3bc8e6bdd4a60e6116a5414239cba5943d3cf - name: Set up Docker Buildx - uses: docker/setup-buildx-action@2b51285047da1547ffb1b2203d8be4c0af6b1f20 + uses: docker/setup-buildx-action@aa33708b10e362ff993539393ff100fa93ed6a27 - name: Log in to GitHub Container Registry - uses: docker/login-action@e92390c5fb421da1463c202d546fed0ec5c39f20 + uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 with: registry: ghcr.io username: ${{ github.actor }} @@ -107,16 +107,27 @@ jobs: - name: Log in to DockerHub if: github.event_name != 'pull_request' - uses: docker/login-action@e92390c5fb421da1463c202d546fed0ec5c39f20 + uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_TOKEN }} - name: Build & Deploy ${{ matrix.dockerfile[0] }} - uses: docker/build-push-action@2cdde995de11925a030ce8070c3d77a52ffcf1c0 + uses: docker/build-push-action@5176d81f87c23d6fc96624dfdbcd9f3830bbe445 with: context: dockerfiles/${{ matrix.dockerfile[0] }} platforms: ${{ matrix.dockerfile[1] }} push: ${{ github.event_name != 'pull_request' }} tags: ${{ steps.docker_meta.outputs.tags }} labels: ${{ steps.docker_meta.outputs.labels }} + + merge-dockerfiles: + runs-on: ubuntu-latest + needs: deploy-images + steps: + - name: Merge Artifacts + uses: actions/upload-artifact/merge@0b2256b8c012f0828dc542b3febcab082c67f72b + with: + name: dockerfiles + pattern: dockerfiles_* + delete-merged: true diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index e7da0e9e4691a7..96fb38eb649cfe 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -18,6 +18,7 @@ jobs: prechecks: needs: [ changes ] uses: ./.github/workflows/valid-style.yml + secrets: inherit with: with_coverage: ${{ needs.changes.outputs.core }} all-prechecks: @@ -35,7 +36,7 @@ jobs: core: ${{ steps.filter.outputs.core }} packages: ${{ steps.filter.outputs.packages }} steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # @v2 + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 if: ${{ github.event_name == 'push' }} with: fetch-depth: 0 @@ -52,6 +53,13 @@ jobs: - 'var/spack/repos/builtin/packages/clingo/**' - 'var/spack/repos/builtin/packages/python/**' - 'var/spack/repos/builtin/packages/re2c/**' + - 'var/spack/repos/builtin/packages/gnupg/**' + - 'var/spack/repos/builtin/packages/libassuan/**' + - 'var/spack/repos/builtin/packages/libgcrypt/**' + - 'var/spack/repos/builtin/packages/libgpg-error/**' + - 'var/spack/repos/builtin/packages/libksba/**' + - 'var/spack/repos/builtin/packages/npth/**' + - 'var/spack/repos/builtin/packages/pinentry/**' - 'lib/spack/**' - 'share/spack/**' - '.github/workflows/bootstrap.yml' @@ -70,16 +78,14 @@ jobs: if: ${{ github.repository == 'spack/spack' && needs.changes.outputs.bootstrap == 'true' }} needs: [ prechecks, changes ] uses: ./.github/workflows/bootstrap.yml + secrets: inherit unit-tests: if: ${{ github.repository == 'spack/spack' && needs.changes.outputs.core == 'true' }} needs: [ prechecks, changes ] uses: ./.github/workflows/unit_tests.yaml - windows: - if: ${{ github.repository == 'spack/spack' && needs.changes.outputs.core == 'true' }} - needs: [ prechecks ] - uses: ./.github/workflows/windows_python.yml + secrets: inherit all: - needs: [ windows, unit-tests, bootstrap ] + needs: [ unit-tests, bootstrap ] runs-on: ubuntu-latest steps: - name: Success diff --git a/.github/workflows/install_spack.sh b/.github/workflows/install_spack.sh deleted file mode 100755 index be8ec8af21d301..00000000000000 --- a/.github/workflows/install_spack.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env sh -. share/spack/setup-env.sh -echo -e "config:\n build_jobs: 2" > etc/spack/config.yaml -spack config add "packages:all:target:[x86_64]" -spack compiler find -spack compiler info apple-clang -spack debug report -spack solve zlib diff --git a/.github/workflows/nightly-win-builds.yml b/.github/workflows/nightly-win-builds.yml index 5b32ee4f96b337..58a556cb9eee3a 100644 --- a/.github/workflows/nightly-win-builds.yml +++ b/.github/workflows/nightly-win-builds.yml @@ -14,10 +14,10 @@ jobs: build-paraview-deps: runs-on: windows-latest steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: fetch-depth: 0 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f with: python-version: 3.9 - name: Install Python packages diff --git a/.github/workflows/requirements/style/requirements.txt b/.github/workflows/requirements/style/requirements.txt new file mode 100644 index 00000000000000..a6ff4bdc849704 --- /dev/null +++ b/.github/workflows/requirements/style/requirements.txt @@ -0,0 +1,7 @@ +black==24.4.2 +clingo==5.7.1 +flake8==7.1.0 +isort==5.13.2 +mypy==1.8.0 +types-six==1.16.21.20240513 +vermin==1.6.0 diff --git a/.github/workflows/style/requirements.txt b/.github/workflows/style/requirements.txt deleted file mode 100644 index cea6026801243a..00000000000000 --- a/.github/workflows/style/requirements.txt +++ /dev/null @@ -1,7 +0,0 @@ -black==24.3.0 -clingo==5.7.1 -flake8==7.0.0 -isort==5.13.2 -mypy==1.8.0 -types-six==1.16.21.9 -vermin==1.6.0 diff --git a/.github/workflows/unit_tests.yaml b/.github/workflows/unit_tests.yaml index 26df165093bb16..d5737af27efc93 100644 --- a/.github/workflows/unit_tests.yaml +++ b/.github/workflows/unit_tests.yaml @@ -51,10 +51,10 @@ jobs: on_develop: false steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # @v2 + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: fetch-depth: 0 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # @v2 + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f with: python-version: ${{ matrix.python-version }} - name: Install System packages @@ -72,7 +72,7 @@ jobs: run: | # Need this for the git tests to succeed. git --version - . .github/workflows/setup_git.sh + . .github/workflows/bin/setup_git.sh - name: Bootstrap clingo if: ${{ matrix.concretizer == 'clingo' }} env: @@ -91,17 +91,19 @@ jobs: UNIT_TEST_COVERAGE: ${{ matrix.python-version == '3.11' }} run: | share/spack/qa/run-unit-tests - - uses: codecov/codecov-action@54bcd8715eee62d40e33596ef5e8f0f48dbbccab + - uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 with: flags: unittests,linux,${{ matrix.concretizer }} + token: ${{ secrets.CODECOV_TOKEN }} + verbose: true # Test shell integration shell: runs-on: ubuntu-latest steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # @v2 + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: fetch-depth: 0 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # @v2 + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f with: python-version: '3.11' - name: Install System packages @@ -116,15 +118,17 @@ jobs: run: | # Need this for the git tests to succeed. git --version - . .github/workflows/setup_git.sh + . .github/workflows/bin/setup_git.sh - name: Run shell tests env: COVERAGE: true run: | share/spack/qa/run-shell-tests - - uses: codecov/codecov-action@54bcd8715eee62d40e33596ef5e8f0f48dbbccab + - uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 with: flags: shelltests,linux + token: ${{ secrets.CODECOV_TOKEN }} + verbose: true # Test RHEL8 UBI with platform Python. This job is run # only on PRs modifying core Spack @@ -137,13 +141,13 @@ jobs: dnf install -y \ bzip2 curl file gcc-c++ gcc gcc-gfortran git gnupg2 gzip \ make patch tcl unzip which xz - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # @v2 + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 - name: Setup repo and non-root user run: | git --version git config --global --add safe.directory /__w/spack/spack git fetch --unshallow - . .github/workflows/setup_git.sh + . .github/workflows/bin/setup_git.sh useradd spack-test chown -R spack-test . - name: Run unit tests @@ -156,10 +160,10 @@ jobs: clingo-cffi: runs-on: ubuntu-latest steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # @v2 + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: fetch-depth: 0 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # @v2 + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f with: python-version: '3.11' - name: Install System packages @@ -174,27 +178,30 @@ jobs: run: | # Need this for the git tests to succeed. git --version - . .github/workflows/setup_git.sh + . .github/workflows/bin/setup_git.sh - name: Run unit tests (full suite with coverage) env: COVERAGE: true SPACK_TEST_SOLVER: clingo run: | share/spack/qa/run-unit-tests - - uses: codecov/codecov-action@54bcd8715eee62d40e33596ef5e8f0f48dbbccab # @v2.1.0 + - uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 with: flags: unittests,linux,clingo + token: ${{ secrets.CODECOV_TOKEN }} + verbose: true # Run unit tests on MacOS macos: - runs-on: macos-latest + runs-on: ${{ matrix.os }} strategy: matrix: + os: [macos-13, macos-14] python-version: ["3.11"] steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # @v2 + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: fetch-depth: 0 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # @v2 + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f with: python-version: ${{ matrix.python-version }} - name: Install Python packages @@ -210,12 +217,45 @@ jobs: SPACK_TEST_PARALLEL: 4 run: | git --version - . .github/workflows/setup_git.sh + . .github/workflows/bin/setup_git.sh . share/spack/setup-env.sh $(which spack) bootstrap disable spack-install $(which spack) solve zlib common_args=(--dist loadfile --tx '4*popen//python=./bin/spack-tmpconfig python -u ./bin/spack python' -x) $(which spack) unit-test --verbose --cov --cov-config=pyproject.toml --cov-report=xml:coverage.xml "${common_args[@]}" - - uses: codecov/codecov-action@54bcd8715eee62d40e33596ef5e8f0f48dbbccab + - uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 with: flags: unittests,macos + token: ${{ secrets.CODECOV_TOKEN }} + verbose: true + # Run unit tests on Windows + windows: + defaults: + run: + shell: + powershell Invoke-Expression -Command "./share/spack/qa/windows_test_setup.ps1"; {0} + runs-on: windows-latest + steps: + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 + with: + fetch-depth: 0 + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f + with: + python-version: 3.9 + - name: Install Python packages + run: | + python -m pip install --upgrade pip pywin32 setuptools pytest-cov clingo + - name: Create local develop + run: | + ./.github/workflows/bin/setup_git.ps1 + - name: Unit Test + run: | + spack unit-test -x --verbose --cov --cov-config=pyproject.toml + ./share/spack/qa/validate_last_exit.ps1 + coverage combine -a + coverage xml + - uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 + with: + flags: unittests,windows + token: ${{ secrets.CODECOV_TOKEN }} + verbose: true diff --git a/.github/workflows/valid-style.yml b/.github/workflows/valid-style.yml index 757183e13c338f..c143f5ede7a845 100644 --- a/.github/workflows/valid-style.yml +++ b/.github/workflows/valid-style.yml @@ -18,15 +18,15 @@ jobs: validate: runs-on: ubuntu-latest steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f with: python-version: '3.11' cache: 'pip' - name: Install Python Packages run: | pip install --upgrade pip setuptools - pip install -r .github/workflows/style/requirements.txt + pip install -r .github/workflows/requirements/style/requirements.txt - name: vermin (Spack's Core) run: vermin --backport importlib --backport argparse --violations --backport typing -t=3.6- -vvv lib/spack/spack/ lib/spack/llnl/ bin/ - name: vermin (Repositories) @@ -35,27 +35,28 @@ jobs: style: runs-on: ubuntu-latest steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: fetch-depth: 0 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c + - uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f with: python-version: '3.11' cache: 'pip' - name: Install Python packages run: | pip install --upgrade pip setuptools - pip install -r .github/workflows/style/requirements.txt + pip install -r .github/workflows/requirements/style/requirements.txt - name: Setup git configuration run: | # Need this for the git tests to succeed. git --version - . .github/workflows/setup_git.sh + . .github/workflows/bin/setup_git.sh - name: Run style tests run: | share/spack/qa/run-style-tests audit: uses: ./.github/workflows/audit.yaml + secrets: inherit with: with_coverage: ${{ inputs.with_coverage }} python_version: '3.11' @@ -69,13 +70,13 @@ jobs: dnf install -y \ bzip2 curl file gcc-c++ gcc gcc-gfortran git gnupg2 gzip \ make patch tcl unzip which xz - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # @v2 + - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 - name: Setup repo and non-root user run: | git --version git config --global --add safe.directory /__w/spack/spack git fetch --unshallow - . .github/workflows/setup_git.sh + . .github/workflows/bin/setup_git.sh useradd spack-test chown -R spack-test . - name: Bootstrap Spack development environment diff --git a/.github/workflows/windows_python.yml b/.github/workflows/windows_python.yml deleted file mode 100644 index fce0df5ca16269..00000000000000 --- a/.github/workflows/windows_python.yml +++ /dev/null @@ -1,79 +0,0 @@ -name: windows - -on: - workflow_call: - -concurrency: - group: windows-${{github.ref}}-${{github.event.pull_request.number || github.run_number}} - cancel-in-progress: true - -defaults: - run: - shell: - powershell Invoke-Expression -Command "./share/spack/qa/windows_test_setup.ps1"; {0} -jobs: - unit-tests: - runs-on: windows-latest - steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - with: - fetch-depth: 0 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c - with: - python-version: 3.9 - - name: Install Python packages - run: | - python -m pip install --upgrade pip pywin32 setuptools pytest-cov clingo - - name: Create local develop - run: | - ./.github/workflows/setup_git.ps1 - - name: Unit Test - run: | - spack unit-test -x --verbose --cov --cov-config=pyproject.toml --ignore=lib/spack/spack/test/cmd - ./share/spack/qa/validate_last_exit.ps1 - coverage combine -a - coverage xml - - uses: codecov/codecov-action@54bcd8715eee62d40e33596ef5e8f0f48dbbccab - with: - flags: unittests,windows - unit-tests-cmd: - runs-on: windows-latest - steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - with: - fetch-depth: 0 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c - with: - python-version: 3.9 - - name: Install Python packages - run: | - python -m pip install --upgrade pip pywin32 setuptools coverage pytest-cov clingo - - name: Create local develop - run: | - ./.github/workflows/setup_git.ps1 - - name: Command Unit Test - run: | - spack unit-test -x --verbose --cov --cov-config=pyproject.toml lib/spack/spack/test/cmd - ./share/spack/qa/validate_last_exit.ps1 - coverage combine -a - coverage xml - - uses: codecov/codecov-action@54bcd8715eee62d40e33596ef5e8f0f48dbbccab - with: - flags: unittests,windows - build-abseil: - runs-on: windows-latest - steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 - with: - fetch-depth: 0 - - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c - with: - python-version: 3.9 - - name: Install Python packages - run: | - python -m pip install --upgrade pip pywin32 setuptools coverage - - name: Build Test - run: | - spack compiler find - spack -d external find cmake ninja - spack -d install abseil-cpp diff --git a/CHANGELOG.md b/CHANGELOG.md index 9ec04198b22912..b20dce89d831c5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,369 @@ + +# v0.22.0 (2024-05-12) + +`v0.22.0` is a major feature release. + +## Features in this release + +1. **Compiler dependencies** + + We are in the process of making compilers proper dependencies in Spack, and a number + of changes in `v0.22` support that effort. You may notice nodes in your dependency + graphs for compiler runtime libraries like `gcc-runtime` or `libgfortran`, and you + may notice that Spack graphs now include `libc`. We've also begun moving compiler + configuration from `compilers.yaml` to `packages.yaml` to make it consistent with + other externals. We are trying to do this with the least disruption possible, so + your existing `compilers.yaml` files should still work. We expect to be done with + this transition by the `v0.23` release in November. + + * #41104: Packages compiled with `%gcc` on Linux, macOS and FreeBSD now depend on a + new package `gcc-runtime`, which contains a copy of the shared compiler runtime + libraries. This enables gcc runtime libraries to be installed and relocated when + using a build cache. When building minimal Spack-generated container images it is + no longer necessary to install libgfortran, libgomp etc. using the system package + manager. + + * #42062: Packages compiled with `%oneapi` now depend on a new package + `intel-oneapi-runtime`. This is similar to `gcc-runtime`, and the runtimes can + provide virtuals and compilers can inject dependencies on virtuals into compiled + packages. This allows us to model library soname compatibility and allows + compilers like `%oneapi` to provide virtuals like `sycl` (which can also be + provided by standalone libraries). Note that until we have an agreement in place + with intel, Intel packages are marked `redistribute(source=False, binary=False)` + and must be downloaded outside of Spack. + + * #43272: changes to the optimization criteria of the solver improve the hit-rate of + buildcaches by a fair amount. The solver more relaxed compatibility rules and will + not try to strictly match compilers or targets of reused specs. Users can still + enforce the previous strict behavior with `require:` sections in `packages.yaml`. + Note that to enforce correct linking, Spack will *not* reuse old `%gcc` and + `%oneapi` specs that do not have the runtime libraries as a dependency. + + * #43539: Spack will reuse specs built with compilers that are *not* explicitly + configured in `compilers.yaml`. Because we can now keep runtime libraries in build + cache, we do not require you to also have a local configured compiler to *use* the + runtime libraries. This improves reuse in buildcaches and avoids conflicts with OS + updates that happen underneath Spack. + + * #43190: binary compatibility on `linux` is now based on the `libc` version, + instead of on the `os` tag. Spack builds now detect the host `libc` (`glibc` or + `musl`) and add it as an implicit external node in the dependency graph. Binaries + with a `libc` with the same name and a version less than or equal to that of the + detected `libc` can be reused. This is only on `linux`, not `macos` or `Windows`. + + * #43464: each package that can provide a compiler is now detectable using `spack + external find`. External packages defining compiler paths are effectively used as + compilers, and `spack external find -t compiler` can be used as a substitute for + `spack compiler find`. More details on this transition are in + [the docs](https://spack.readthedocs.io/en/latest/getting_started.html#manual-compiler-configuration) + +2. **Improved `spack find` UI for Environments** + + If you're working in an enviroment, you likely care about: + + * What are the roots + * Which ones are installed / not installed + * What's been added that still needs to be concretized + + We've tweaked `spack find` in environments to show this information much more + clearly. Installation status is shown next to each root, so you can see what is + installed. Roots are also shown in bold in the list of installed packages. There is + also a new option for `spack find -r` / `--only-roots` that will only show env + roots, if you don't want to look at all the installed specs. + + More details in #42334. + +3. **Improved command-line string quoting** + + We are making some breaking changes to how Spack parses specs on the CLI in order to + respect shell quoting instead of trying to fight it. If you (sadly) had to write + something like this on the command line: + + ``` + spack install zlib cflags=\"-O2 -g\" + ``` + + That will now result in an error, but you can now write what you probably expected + to work in the first place: + + ``` + spack install zlib cflags="-O2 -g" + ``` + + Quoted can also now include special characters, so you can supply flags like: + + ``` + spack intall zlib ldflags='-Wl,-rpath=$ORIGIN/_libs' + ``` + + To reduce ambiguity in parsing, we now require that you *not* put spaces around `=` + and `==` when for flags or variants. This would not have broken before but will now + result in an error: + + ``` + spack install zlib cflags = "-O2 -g" + ``` + + More details and discussion in #30634. + +4. **Revert default `spack install` behavior to `--reuse`** + + We changed the default concretizer behavior from `--reuse` to `--reuse-deps` in + #30990 (in `v0.20`), which meant that *every* `spack install` invocation would + attempt to build a new version of the requested package / any environment roots. + While this is a common ask for *upgrading* and for *developer* workflows, we don't + think it should be the default for a package manager. + + We are going to try to stick to this policy: + 1. Prioritize reuse and build as little as possible by default. + 2. Only upgrade or install duplicates if they are explicitly asked for, or if there + is a known security issue that necessitates an upgrade. + + With the install command you now have three options: + + * `--reuse` (default): reuse as many existing installations as possible. + * `--reuse-deps` / `--fresh-roots`: upgrade (freshen) roots but reuse dependencies if possible. + * `--fresh`: install fresh versions of requested packages (roots) and their dependencies. + + We've also introduced `--fresh-roots` as an alias for `--reuse-deps` to make it more clear + that it may give you fresh versions. More details in #41302 and #43988. + +5. **More control over reused specs** + + You can now control which packages to reuse and how. There is a new + `concretizer:reuse` config option, which accepts the following properties: + + - `roots`: `true` to reuse roots, `false` to reuse just dependencies + - `exclude`: list of constraints used to select which specs *not* to reuse + - `include`: list of constraints used to select which specs *to* reuse + - `from`: list of sources for reused specs (some combination of `local`, + `buildcache`, or `external`) + + For example, to reuse only specs compiled with GCC, you could write: + + ```yaml + concretizer: + reuse: + roots: true + include: + - "%gcc" + ``` + + Or, if `openmpi` must be used from externals, and it must be the only external used: + + ```yaml + concretizer: + reuse: + roots: true + from: + - type: local + exclude: ["openmpi"] + - type: buildcache + exclude: ["openmpi"] + - type: external + include: ["openmpi"] + ``` + +6. **New `redistribute()` directive** + + Some packages can't be redistributed in source or binary form. We need an explicit + way to say that in a package. + + Now there is a `redistribute()` directive so that package authors can write: + + ```python + class MyPackage(Package): + redistribute(source=False, binary=False) + ``` + + Like other directives, this works with `when=`: + + ```python + class MyPackage(Package): + # 12.0 and higher are proprietary + redistribute(source=False, binary=False, when="@12.0:") + + # can't redistribute when we depend on some proprietary dependency + redistribute(source=False, binary=False, when="^proprietary-dependency") + ``` + + More in #20185. + +7. **New `conflict:` and `prefer:` syntax for package preferences** + + Previously, you could express conflicts and preferences in `packages.yaml` through + some contortions with `require:`: + + ```yaml + packages: + zlib-ng: + require: + - one_of: ["%clang", "@:"] # conflict on %clang + - any_of: ["+shared", "@:"] # strong preference for +shared + ``` + + You can now use `require:` and `prefer:` for a much more readable configuration: + + ```yaml + packages: + zlib-ng: + conflict: + - "%clang" + prefer: + - "+shared" + ``` + + See [the documentation](https://spack.readthedocs.io/en/latest/packages_yaml.html#conflicts-and-strong-preferences) + and #41832 for more details. + +8. **`include_concrete` in environments** + + You may want to build on the *concrete* contents of another environment without + changing that environment. You can now include the concrete specs from another + environment's `spack.lock` with `include_concrete`: + + ```yaml + spack: + specs: [] + concretizer: + unify: true + include_concrete: + - /path/to/environment1 + - /path/to/environment2 + ``` + + Now, when *this* environment is concretized, it will bring in the already concrete + specs from `environment1` and `environment2`, and build on top of them without + changing them. This is useful if you have phased deployments, where old deployments + should not be modified but you want to use as many of them as possible. More details + in #33768. + +9. **`python-venv` isolation** + + Spack has unique requirements for Python because it: + 1. installs every package in its own independent directory, and + 2. allows users to register *external* python installations. + + External installations may contain their own installed packages that can interfere + with Spack installations, and some distributions (Debian and Ubuntu) even change the + `sysconfig` in ways that alter the installation layout of installed Python packages + (e.g., with the addition of a `/local` prefix on Debian or Ubuntu). To isolate Spack + from these and other issues, we now insert a small `python-venv` package in between + `python` and packages that need to install Python code. This isolates Spack's build + environment, isolates Spack from any issues with an external python, and resolves a + large number of issues we've had with Python installations. + + See #40773 for further details. + +## New commands, options, and directives + +* Allow packages to be pushed to build cache after install from source (#42423) +* `spack develop`: stage build artifacts in same root as non-dev builds #41373 + * Don't delete `spack develop` build artifacts after install (#43424) +* `spack find`: add options for local/upstream only (#42999) +* `spack logs`: print log files for packages (either partially built or installed) (#42202) +* `patch`: support reversing patches (#43040) +* `develop`: Add -b/--build-directory option to set build_directory package attribute (#39606) +* `spack list`: add `--namesapce` / `--repo` option (#41948) +* directives: add `checked_by` field to `license()`, add some license checks +* `spack gc`: add options for environments and build dependencies (#41731) +* Add `--create` to `spack env activate` (#40896) + +## Performance improvements + +* environment.py: fix excessive re-reads (#43746) +* ruamel yaml: fix quadratic complexity bug (#43745) +* Refactor to improve `spec format` speed (#43712) +* Do not acquire a write lock on the env post install if no views (#43505) +* asp.py: fewer calls to `spec.copy()` (#43715) +* spec.py: early return in `__str__` +* avoid `jinja2` import at startup unless needed (#43237) + +## Other new features of note + +* `archspec`: update to `v0.2.4`: support for Windows, bugfixes for `neoverse-v1` and + `neoverse-v2` detection. +* `spack config get`/`blame`: with no args, show entire config +* `spack env create `: dir if dir-like (#44024) +* ASP-based solver: update os compatibility for macOS (#43862) +* Add handling of custom ssl certs in urllib ops (#42953) +* Add ability to rename environments (#43296) +* Add config option and compiler support to reuse across OS's (#42693) +* Support for prereleases (#43140) +* Only reuse externals when configured (#41707) +* Environments: Add support for including views (#42250) + +## Binary caches +* Build cache: make signed/unsigned a mirror property (#41507) +* tools stack + +## Removals, deprecations, and syntax changes +* remove `dpcpp` compiler and package (#43418) +* spack load: remove --only argument (#42120) + +## Notable Bugfixes +* repo.py: drop deleted packages from provider cache (#43779) +* Allow `+` in module file names (#41999) +* `cmd/python`: use runpy to allow multiprocessing in scripts (#41789) +* Show extension commands with spack -h (#41726) +* Support environment variable expansion inside module projections (#42917) +* Alert user to failed concretizations (#42655) +* shell: fix zsh color formatting for PS1 in environments (#39497) +* spack mirror create --all: include patches (#41579) + +## Spack community stats + +* 7,994 total packages; 525 since `v0.21.0` + * 178 new Python packages, 5 new R packages +* 358 people contributed to this release + * 344 committers to packages + * 45 committers to core + +# v0.21.2 (2024-03-01) + +## Bugfixes + +- Containerize: accommodate nested or pre-existing spack-env paths (#41558) +- Fix setup-env script, when going back and forth between instances (#40924) +- Fix using fully-qualified namespaces from root specs (#41957) +- Fix a bug when a required provider is requested for multiple virtuals (#42088) +- OCI buildcaches: + - only push in parallel when forking (#42143) + - use pickleable errors (#42160) +- Fix using sticky variants in externals (#42253) +- Fix a rare issue with conditional requirements and multi-valued variants (#42566) + +## Package updates +- rust: add v1.75, rework a few variants (#41161,#41903) +- py-transformers: add v4.35.2 (#41266) +- mgard: fix OpenMP on AppleClang (#42933) + +# v0.21.1 (2024-01-11) + +## New features +- Add support for reading buildcaches created by Spack v0.22 (#41773) + +## Bugfixes + +- spack graph: fix coloring with environments (#41240) +- spack info: sort variants in --variants-by-name (#41389) +- Spec.format: error on old style format strings (#41934) +- ASP-based solver: + - fix infinite recursion when computing concretization errors (#41061) + - don't error for type mismatch on preferences (#41138) + - don't emit spurious debug output (#41218) +- Improve the error message for deprecated preferences (#41075) +- Fix MSVC preview version breaking clingo build on Windows (#41185) +- Fix multi-word aliases (#41126) +- Add a warning for unconfigured compiler (#41213) +- environment: fix an issue with deconcretization/reconcretization of specs (#41294) +- buildcache: don't error if a patch is missing, when installing from binaries (#41986) +- Multiple improvements to unit-tests (#41215,#41369,#41495,#41359,#41361,#41345,#41342,#41308,#41226) + +## Package updates +- root: add a webgui patch to address security issue (#41404) +- BerkeleyGW: update source urls (#38218) + # v0.21.0 (2023-11-11) `v0.21.0` is a major feature release. diff --git a/README.md b/README.md index 0bb54035f5cf1b..5d39b117b93a33 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ Spack is a multi-platform package manager that builds and installs multiple versions and configurations of software. It works on Linux, -macOS, and many supercomputers. Spack is non-destructive: installing a +macOS, Windows, and many supercomputers. Spack is non-destructive: installing a new version of a package does not break existing installations, so many configurations of the same package can coexist. @@ -88,7 +88,7 @@ Resources: [bridged](https://github.com/matrix-org/matrix-appservice-slack#matrix-appservice-slack) to Slack. * [**Github Discussions**](https://github.com/spack/spack/discussions): for Q&A and discussions. Note the pinned discussions for announcements. -* **Twitter**: [@spackpm](https://twitter.com/spackpm). Be sure to +* **X**: [@spackpm](https://twitter.com/spackpm). Be sure to `@mention` us! * **Mailing list**: [groups.google.com/d/forum/spack](https://groups.google.com/d/forum/spack): only for announcements. Please use other venues for discussions. diff --git a/bin/spack-python b/bin/spack-python index ff555aa93b2d34..b8e76f826b7683 100755 --- a/bin/spack-python +++ b/bin/spack-python @@ -22,4 +22,4 @@ # # This is compatible across platforms. # -exec /usr/bin/env spack python "$@" +exec spack python "$@" diff --git a/bin/spack.bat b/bin/spack.bat index 832801359967b3..a5a5384e9f13c7 100644 --- a/bin/spack.bat +++ b/bin/spack.bat @@ -188,25 +188,27 @@ if NOT "%_sp_args%"=="%_sp_args:--help=%" ( goto :end_switch :case_load -:: If args contain --sh, --csh, or -h/--help: just execute. -if defined _sp_args ( - if NOT "%_sp_args%"=="%_sp_args:--help=%" ( - goto :default_case - ) else if NOT "%_sp_args%"=="%_sp_args:-h=%" ( - goto :default_case - ) else if NOT "%_sp_args%"=="%_sp_args:--bat=%" ( - goto :default_case - ) +if NOT defined _sp_args ( + exit /B 0 +) + +:: If args contain --bat, or -h/--help: just execute. +if NOT "%_sp_args%"=="%_sp_args:--help=%" ( + goto :default_case +) else if NOT "%_sp_args%"=="%_sp_args:-h=%" ( + goto :default_case +) else if NOT "%_sp_args%"=="%_sp_args:--bat=%" ( + goto :default_case +) else if NOT "%_sp_args%"=="%_sp_args:--list=%" ( + goto :default_case ) for /f "tokens=* USEBACKQ" %%I in ( - `python "%spack%" %_sp_flags% %_sp_subcommand% --bat %_sp_args%`) do %%I + `python "%spack%" %_sp_flags% %_sp_subcommand% --bat %_sp_args%` + ) do %%I goto :end_switch -:case_unload -goto :case_load - :default_case python "%spack%" %_sp_flags% %_sp_subcommand% %_sp_args% goto :end_switch diff --git a/bin/spack.ps1 b/bin/spack.ps1 index 5a82b0b620cfee..1ceeb0a250e6fe 100644 --- a/bin/spack.ps1 +++ b/bin/spack.ps1 @@ -144,3 +144,5 @@ switch($SpackSubCommand) "unload" {Invoke-SpackLoad} default {python "$Env:SPACK_ROOT/bin/spack" $SpackCMD_params $SpackSubCommand $SpackSubCommandArgs} } + +exit $LASTEXITCODE diff --git a/etc/spack/defaults/concretizer.yaml b/etc/spack/defaults/concretizer.yaml index edefa552cee227..5bbf580bcf826a 100644 --- a/etc/spack/defaults/concretizer.yaml +++ b/etc/spack/defaults/concretizer.yaml @@ -15,7 +15,7 @@ concretizer: # as possible, rather than building. If `false`, we'll always give you a fresh # concretization. If `dependencies`, we'll only reuse dependencies but # give you a fresh concretization for your root specs. - reuse: dependencies + reuse: true # Options that tune which targets are considered for concretization. The # concretization process is very sensitive to the number targets, and the time # needed to reach a solution increases noticeably with the number of targets @@ -42,3 +42,8 @@ concretizer: # "minimal": allows the duplication of 'build-tools' nodes only (e.g. py-setuptools, cmake etc.) # "full" (experimental): allows separation of the entire build-tool stack (e.g. the entire "cmake" subDAG) strategy: minimal + # Option to specify compatiblity between operating systems for reuse of compilers and packages + # Specified as a key: [list] where the key is the os that is being targeted, and the list contains the OS's + # it can reuse. Note this is a directional compatibility so mutual compatibility between two OS's + # requires two entries i.e. os_compatible: {sonoma: [monterey], monterey: [sonoma]} + os_compatible: {} diff --git a/etc/spack/defaults/config.yaml b/etc/spack/defaults/config.yaml index 018e8deb55ba17..532e3db270cf86 100644 --- a/etc/spack/defaults/config.yaml +++ b/etc/spack/defaults/config.yaml @@ -101,6 +101,12 @@ config: verify_ssl: true + # This is where custom certs for proxy/firewall are stored. + # It can be a path or environment variable. To match ssl env configuration + # the default is the environment variable SSL_CERT_FILE + ssl_certs: $SSL_CERT_FILE + + # Suppress gpg warnings from binary package verification # Only suppresses warnings, gpg failure will still fail the install # Potential rationale to set True: users have already explicitly trusted the diff --git a/etc/spack/defaults/cray/modules.yaml b/etc/spack/defaults/cray/modules.yaml deleted file mode 100644 index a80f87b16ab400..00000000000000 --- a/etc/spack/defaults/cray/modules.yaml +++ /dev/null @@ -1,16 +0,0 @@ -# ------------------------------------------------------------------------- -# This is the default configuration for Spack's module file generation. -# -# Settings here are versioned with Spack and are intended to provide -# sensible defaults out of the box. Spack maintainers should edit this -# file to keep it current. -# -# Users can override these settings by editing the following files. -# -# Per-spack-instance settings (overrides defaults): -# $SPACK_ROOT/etc/spack/modules.yaml -# -# Per-user settings (overrides default and site settings): -# ~/.spack/modules.yaml -# ------------------------------------------------------------------------- -modules: {} diff --git a/etc/spack/defaults/darwin/packages.yaml b/etc/spack/defaults/darwin/packages.yaml index 9fd54f2e6e0991..6aba11f2738adb 100644 --- a/etc/spack/defaults/darwin/packages.yaml +++ b/etc/spack/defaults/darwin/packages.yaml @@ -19,7 +19,6 @@ packages: - apple-clang - clang - gcc - - intel providers: elf: [libelf] fuse: [macfuse] diff --git a/etc/spack/defaults/packages.yaml b/etc/spack/defaults/packages.yaml index 24d19ac4cbbd73..581b01e1f6153d 100644 --- a/etc/spack/defaults/packages.yaml +++ b/etc/spack/defaults/packages.yaml @@ -15,15 +15,17 @@ # ------------------------------------------------------------------------- packages: all: - compiler: [gcc, intel, pgi, clang, xl, nag, fj, aocc] + compiler: [gcc, clang, oneapi, xl, nag, fj, aocc] providers: awk: [gawk] + armci: [armcimpi] blas: [openblas, amdblis] D: [ldc] daal: [intel-oneapi-daal] elf: [elfutils] fftw-api: [fftw, amdfftw] flame: [libflame, amdlibflame] + fortran-rt: [gcc-runtime, intel-oneapi-runtime] fuse: [libfuse] gl: [glx, osmesa] glu: [mesa-glu, openglu] @@ -34,9 +36,11 @@ packages: java: [openjdk, jdk, ibm-java] jpeg: [libjpeg-turbo, libjpeg] lapack: [openblas, amdlibflame] - libglx: [mesa+glx, mesa18+glx] + libc: [glibc, musl] + libgfortran: [ gcc-runtime ] + libglx: [mesa+glx] + libifcore: [ intel-oneapi-runtime ] libllvm: [llvm] - libosmesa: [mesa+osmesa, mesa18+osmesa] lua-lang: [lua, lua-luajit-openresty, lua-luajit] luajit: [lua-luajit-openresty, lua-luajit] mariadb-client: [mariadb-c-client, mariadb] diff --git a/lib/spack/docs/_templates/layout.html b/lib/spack/docs/_templates/layout.html new file mode 100644 index 00000000000000..393cb1ebc16639 --- /dev/null +++ b/lib/spack/docs/_templates/layout.html @@ -0,0 +1,12 @@ +{% extends "!layout.html" %} + +{%- block extrahead %} + + + +{% endblock %} diff --git a/lib/spack/docs/basic_usage.rst b/lib/spack/docs/basic_usage.rst index 5a8d9668f3a1d7..69cbefc083db4d 100644 --- a/lib/spack/docs/basic_usage.rst +++ b/lib/spack/docs/basic_usage.rst @@ -865,7 +865,7 @@ There are several different ways to use Spack packages once you have installed them. As you've seen, spack packages are installed into long paths with hashes, and you need a way to get them into your path. The easiest way is to use :ref:`spack load `, which is -described in the next section. +described in this section. Some more advanced ways to use Spack packages include: @@ -959,7 +959,86 @@ use ``spack find --loaded``. You can also use ``spack load --list`` to get the same output, but it does not have the full set of query options that ``spack find`` offers. -We'll learn more about Spack's spec syntax in the next section. +We'll learn more about Spack's spec syntax in :ref:`a later section `. + + +.. _extensions: + +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +Python packages and virtual environments +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +Spack can install a large number of Python packages. Their names are +typically prefixed with ``py-``. Installing and using them is no +different from any other package: + +.. code-block:: console + + $ spack install py-numpy + $ spack load py-numpy + $ python3 + >>> import numpy + +The ``spack load`` command sets the ``PATH`` variable so that the right Python +executable is used, and makes sure that ``numpy`` and its dependencies can be +located in the ``PYTHONPATH``. + +Spack is different from other Python package managers in that it installs +every package into its *own* prefix. This is in contrast to ``pip``, which +installs all packages into the same prefix, be it in a virtual environment +or not. + +For many users, **virtual environments** are more convenient than repeated +``spack load`` commands, particularly when working with multiple Python +packages. Fortunately Spack supports environments itself, which together +with a view are no different from Python virtual environments. + +The recommended way of working with Python extensions such as ``py-numpy`` +is through :ref:`Environments `. The following example creates +a Spack environment with ``numpy`` in the current working directory. It also +puts a filesystem view in ``./view``, which is a more traditional combined +prefix for all packages in the environment. + +.. code-block:: console + + $ spack env create --with-view view --dir . + $ spack -e . add py-numpy + $ spack -e . concretize + $ spack -e . install + +Now you can activate the environment and start using the packages: + +.. code-block:: console + + $ spack env activate . + $ python3 + >>> import numpy + +The environment view is also a virtual environment, which is useful if you are +sharing the environment with others who are unfamiliar with Spack. They can +either use the Python executable directly: + +.. code-block:: console + + $ ./view/bin/python3 + >>> import numpy + +or use the activation script: + +.. code-block:: console + + $ source ./view/bin/activate + $ python3 + >>> import numpy + +In general, there should not be much difference between ``spack env activate`` +and using the virtual environment. The main advantage of ``spack env activate`` +is that it knows about more packages than just Python packages, and it may set +additional runtime variables that are not covered by the virtual environment +activation script. + +See :ref:`environments` for a more in-depth description of Spack +environments and customizations to views. .. _sec-specs: @@ -1119,6 +1198,9 @@ and ``3.4.2``. Similarly, ``@4.2:`` means any version above and including ``4.2``. As a short-hand, ``@3`` is equivalent to the range ``@3:3`` and includes any version with major version ``3``. +Versions are ordered lexicograpically by its components. For more details +on the order, see :ref:`the packaging guide `. + Notice that you can distinguish between the specific version ``@=3.2`` and the range ``@3.2``. This is useful for packages that follow a versioning scheme that omits the zero patch version number: ``3.2``, ``3.2.1``, @@ -1351,22 +1433,12 @@ the reserved keywords ``platform``, ``os`` and ``target``: $ spack install libelf os=ubuntu18.04 $ spack install libelf target=broadwell -or together by using the reserved keyword ``arch``: - -.. code-block:: console - - $ spack install libelf arch=cray-CNL10-haswell - Normally users don't have to bother specifying the architecture if they are installing software for their current host, as in that case the values will be detected automatically. If you need fine-grained control over which packages use which targets (or over *all* packages' default target), see :ref:`package-preferences`. -.. admonition:: Cray machines - - The situation is a little bit different for Cray machines and a detailed - explanation on how the architecture can be set on them can be found at :ref:`cray-support` .. _support-for-microarchitectures: @@ -1702,165 +1774,6 @@ check only local packages (as opposed to those used transparently from ``upstream`` spack instances) and the ``-j,--json`` option to output machine-readable json data for any errors. - -.. _extensions: - ---------------------------- -Extensions & Python support ---------------------------- - -Spack's installation model assumes that each package will live in its -own install prefix. However, certain packages are typically installed -*within* the directory hierarchy of other packages. For example, -`Python `_ packages are typically installed in the -``$prefix/lib/python-2.7/site-packages`` directory. - -In Spack, installation prefixes are immutable, so this type of installation -is not directly supported. However, it is possible to create views that -allow you to merge install prefixes of multiple packages into a single new prefix. -Views are a convenient way to get a more traditional filesystem structure. -Using *extensions*, you can ensure that Python packages always share the -same prefix in the view as Python itself. Suppose you have -Python installed like so: - -.. code-block:: console - - $ spack find python - ==> 1 installed packages. - -- linux-debian7-x86_64 / gcc@4.4.7 -------------------------------- - python@2.7.8 - -.. _cmd-spack-extensions: - -^^^^^^^^^^^^^^^^^^^^ -``spack extensions`` -^^^^^^^^^^^^^^^^^^^^ - -You can find extensions for your Python installation like this: - -.. code-block:: console - - $ spack extensions python - ==> python@2.7.8%gcc@4.4.7 arch=linux-debian7-x86_64-703c7a96 - ==> 36 extensions: - geos py-ipython py-pexpect py-pyside py-sip - py-basemap py-libxml2 py-pil py-pytz py-six - py-biopython py-mako py-pmw py-rpy2 py-sympy - py-cython py-matplotlib py-pychecker py-scientificpython py-virtualenv - py-dateutil py-mpi4py py-pygments py-scikit-learn - py-epydoc py-mx py-pylint py-scipy - py-gnuplot py-nose py-pyparsing py-setuptools - py-h5py py-numpy py-pyqt py-shiboken - - ==> 12 installed: - -- linux-debian7-x86_64 / gcc@4.4.7 -------------------------------- - py-dateutil@2.4.0 py-nose@1.3.4 py-pyside@1.2.2 - py-dateutil@2.4.0 py-numpy@1.9.1 py-pytz@2014.10 - py-ipython@2.3.1 py-pygments@2.0.1 py-setuptools@11.3.1 - py-matplotlib@1.4.2 py-pyparsing@2.0.3 py-six@1.9.0 - -The extensions are a subset of what's returned by ``spack list``, and -they are packages like any other. They are installed into their own -prefixes, and you can see this with ``spack find --paths``: - -.. code-block:: console - - $ spack find --paths py-numpy - ==> 1 installed packages. - -- linux-debian7-x86_64 / gcc@4.4.7 -------------------------------- - py-numpy@1.9.1 ~/spack/opt/linux-debian7-x86_64/gcc@4.4.7/py-numpy@1.9.1-66733244 - -However, even though this package is installed, you cannot use it -directly when you run ``python``: - -.. code-block:: console - - $ spack load python - $ python - Python 2.7.8 (default, Feb 17 2015, 01:35:25) - [GCC 4.4.7 20120313 (Red Hat 4.4.7-11)] on linux2 - Type "help", "copyright", "credits" or "license" for more information. - >>> import numpy - Traceback (most recent call last): - File "", line 1, in - ImportError: No module named numpy - >>> - -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -Using Extensions in Environments -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - -The recommended way of working with extensions such as ``py-numpy`` -above is through :ref:`Environments `. For example, -the following creates an environment in the current working directory -with a filesystem view in the ``./view`` directory: - -.. code-block:: console - - $ spack env create --with-view view --dir . - $ spack -e . add py-numpy - $ spack -e . concretize - $ spack -e . install - -We recommend environments for two reasons. Firstly, environments -can be activated (requires :ref:`shell-support`): - -.. code-block:: console - - $ spack env activate . - -which sets all the right environment variables such as ``PATH`` and -``PYTHONPATH``. This ensures that - -.. code-block:: console - - $ python - >>> import numpy - -works. Secondly, even without shell support, the view ensures -that Python can locate its extensions: - -.. code-block:: console - - $ ./view/bin/python - >>> import numpy - -See :ref:`environments` for a more in-depth description of Spack -environments and customizations to views. - -^^^^^^^^^^^^^^^^^^^^ -Using ``spack load`` -^^^^^^^^^^^^^^^^^^^^ - -A more traditional way of using Spack and extensions is ``spack load`` -(requires :ref:`shell-support`). This will add the extension to ``PYTHONPATH`` -in your current shell, and Python itself will be available in the ``PATH``: - -.. code-block:: console - - $ spack load py-numpy - $ python - >>> import numpy - -The loaded packages can be checked using ``spack find --loaded`` - -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -Loading Extensions via Modules -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - -Apart from ``spack env activate`` and ``spack load``, you can load numpy -through your environment modules (using ``environment-modules`` or -``lmod``). This will also add the extension to the ``PYTHONPATH`` in -your current shell. - -.. code-block:: console - - $ module load - -If you do not know the name of the specific numpy module you wish to -load, you can use the ``spack module tcl|lmod loads`` command to get -the name of the module from the Spack spec. - ----------------------- Filesystem requirements ----------------------- diff --git a/lib/spack/docs/binary_caches.rst b/lib/spack/docs/binary_caches.rst index 918ca786d72bd4..2b6d8e7d639fa8 100644 --- a/lib/spack/docs/binary_caches.rst +++ b/lib/spack/docs/binary_caches.rst @@ -345,6 +345,40 @@ section of the configuration: .. _binary_caches_oci: +--------------------------------- +Automatic push to a build cache +--------------------------------- + +Sometimes it is convenient to push packages to a build cache as soon as they are installed. Spack can do this by setting autopush flag when adding a mirror: + +.. code-block:: console + + $ spack mirror add --autopush + +Or the autopush flag can be set for an existing mirror: + +.. code-block:: console + + $ spack mirror set --autopush # enable automatic push for an existing mirror + $ spack mirror set --no-autopush # disable automatic push for an existing mirror + +Then after installing a package it is automatically pushed to all mirrors with ``autopush: true``. The command + +.. code-block:: console + + $ spack install + +will have the same effect as + +.. code-block:: console + + $ spack install + $ spack buildcache push # for all caches with autopush: true + +.. note:: + + Packages are automatically pushed to a build cache only if they are built from source. + ----------------------------------------- OCI / Docker V2 registries as build cache ----------------------------------------- diff --git a/lib/spack/docs/build_settings.rst b/lib/spack/docs/build_settings.rst index f58c9f4c9772e7..d545c70d18dcb3 100644 --- a/lib/spack/docs/build_settings.rst +++ b/lib/spack/docs/build_settings.rst @@ -21,23 +21,86 @@ is the following: Reuse already installed packages -------------------------------- -The ``reuse`` attribute controls whether Spack will prefer to use installed packages (``true``), or -whether it will do a "fresh" installation and prefer the latest settings from -``package.py`` files and ``packages.yaml`` (``false``). -You can use: +The ``reuse`` attribute controls how aggressively Spack reuses binary packages during concretization. The +attribute can either be a single value, or an object for more complex configurations. + +In the former case ("single value") it allows Spack to: + +1. Reuse installed packages and buildcaches for all the specs to be concretized, when ``true`` +2. Reuse installed packages and buildcaches only for the dependencies of the root specs, when ``dependencies`` +3. Disregard reusing installed packages and buildcaches, when ``false`` + +In case a finer control over which specs are reused is needed, then the value of this attribute can be +an object, with the following keys: + +1. ``roots``: if ``true`` root specs are reused, if ``false`` only dependencies of root specs are reused +2. ``from``: list of sources from which reused specs are taken + +Each source in ``from`` is itself an object: + +.. list-table:: Attributes for a source or reusable specs + :header-rows: 1 + + * - Attribute name + - Description + * - type (mandatory, string) + - Can be ``local``, ``buildcache``, or ``external`` + * - include (optional, list of specs) + - If present, reusable specs must match at least one of the constraint in the list + * - exclude (optional, list of specs) + - If present, reusable specs must not match any of the constraint in the list. + +For instance, the following configuration: + +.. code-block:: yaml + + concretizer: + reuse: + roots: true + from: + - type: local + include: + - "%gcc" + - "%clang" + +tells the concretizer to reuse all specs compiled with either ``gcc`` or ``clang``, that are installed +in the local store. Any spec from remote buildcaches is disregarded. + +To reduce the boilerplate in configuration files, default values for the ``include`` and +``exclude`` options can be pushed up one level: + +.. code-block:: yaml + + concretizer: + reuse: + roots: true + include: + - "%gcc" + from: + - type: local + - type: buildcache + - type: local + include: + - "foo %oneapi" + +In the example above we reuse all specs compiled with ``gcc`` from the local store +and remote buildcaches, and we also reuse ``foo %oneapi``. Note that the last source of +specs override the default ``include`` attribute. + +For one-off concretizations, the are command line arguments for each of the simple "single value" +configurations. This means a user can: .. code-block:: console % spack install --reuse -to enable reuse for a single installation, and you can use: +to enable reuse for a single installation, or: .. code-block:: console spack install --fresh to do a fresh install if ``reuse`` is enabled by default. -``reuse: dependencies`` is the default. .. seealso:: diff --git a/lib/spack/docs/build_systems/autotoolspackage.rst b/lib/spack/docs/build_systems/autotoolspackage.rst index c0adcda178bb42..392feb3ed48c8a 100644 --- a/lib/spack/docs/build_systems/autotoolspackage.rst +++ b/lib/spack/docs/build_systems/autotoolspackage.rst @@ -147,6 +147,15 @@ example, the ``bash`` shell is used to run the ``autogen.sh`` script. def autoreconf(self, spec, prefix): which("bash")("autogen.sh") +If the ``package.py`` has build instructions in a separate +:ref:`builder class `, the signature for a phase changes slightly: + +.. code-block:: python + + class AutotoolsBuilder(AutotoolsBuilder): + def autoreconf(self, pkg, spec, prefix): + which("bash")("autogen.sh") + """"""""""""""""""""""""""""""""""""""" patching configure or Makefile.in files """"""""""""""""""""""""""""""""""""""" diff --git a/lib/spack/docs/build_systems/inteloneapipackage.rst b/lib/spack/docs/build_systems/inteloneapipackage.rst index feae03a280d24d..ea1882eaf7052c 100644 --- a/lib/spack/docs/build_systems/inteloneapipackage.rst +++ b/lib/spack/docs/build_systems/inteloneapipackage.rst @@ -25,7 +25,7 @@ use Spack to build packages with the tools. The Spack Python class ``IntelOneapiPackage`` is a base class that is used by ``IntelOneapiCompilers``, ``IntelOneapiMkl``, ``IntelOneapiTbb`` and other classes to implement the oneAPI -packages. Search for ``oneAPI`` at ``_ for the full +packages. Search for ``oneAPI`` at `packages.spack.io `_ for the full list of available oneAPI packages, or use:: spack list -d oneAPI diff --git a/lib/spack/docs/build_systems/pythonpackage.rst b/lib/spack/docs/build_systems/pythonpackage.rst index 372d4ad47c5ce7..9512b08885dc14 100644 --- a/lib/spack/docs/build_systems/pythonpackage.rst +++ b/lib/spack/docs/build_systems/pythonpackage.rst @@ -718,23 +718,45 @@ command-line tool, or C/C++/Fortran program with optional Python modules? The former should be prepended with ``py-``, while the latter should not. -"""""""""""""""""""""" -extends vs. depends_on -"""""""""""""""""""""" +"""""""""""""""""""""""""""""" +``extends`` vs. ``depends_on`` +"""""""""""""""""""""""""""""" -This is very similar to the naming dilemma above, with a slight twist. As mentioned in the :ref:`Packaging Guide `, ``extends`` and ``depends_on`` are very similar, but ``extends`` ensures that the extension and extendee share the same prefix in views. This allows the user to import a Python module without having to add that module to ``PYTHONPATH``. -When deciding between ``extends`` and ``depends_on``, the best rule of -thumb is to check the installation prefix. If Python libraries are -installed to ``/lib/pythonX.Y/site-packages``, then you -should use ``extends``. If Python libraries are installed elsewhere -or the only files that get installed reside in ``/bin``, then -don't use ``extends``. +Additionally, ``extends("python")`` adds a dependency on the package +``python-venv``. This improves isolation from the system, whether +it's during the build or at runtime: user and system site packages +cannot accidentally be used by any package that ``extends("python")``. + +As a rule of thumb: if a package does not install any Python modules +of its own, and merely puts a Python script in the ``bin`` directory, +then there is no need for ``extends``. If the package installs modules +in the ``site-packages`` directory, it requires ``extends``. + +""""""""""""""""""""""""""""""""""""" +Executing ``python`` during the build +""""""""""""""""""""""""""""""""""""" + +Whenever you need to execute a Python command or pass the path of the +Python interpreter to the build system, it is best to use the global +variable ``python`` directly. For example: + +.. code-block:: python + + @run_before("install") + def recythonize(self): + python("setup.py", "clean") # use the `python` global + +As mentioned in the previous section, ``extends("python")`` adds an +automatic dependency on ``python-venv``, which is a virtual environment +that guarantees build isolation. The ``python`` global always refers to +the correct Python interpreter, whether the package uses ``extends("python")`` +or ``depends_on("python")``. ^^^^^^^^^^^^^^^^^^^^^ Alternatives to Spack diff --git a/lib/spack/docs/chain.rst b/lib/spack/docs/chain.rst index e4a275df662f47..bd0241c8bb81fc 100644 --- a/lib/spack/docs/chain.rst +++ b/lib/spack/docs/chain.rst @@ -11,7 +11,8 @@ Chaining Spack Installations You can point your Spack installation to another installation to use any packages that are installed there. To register the other Spack instance, -you can add it as an entry to ``upstreams.yaml``: +you can add it as an entry to ``upstreams.yaml`` at any of the +:ref:`configuration-scopes`: .. code-block:: yaml @@ -22,7 +23,8 @@ you can add it as an entry to ``upstreams.yaml``: install_tree: /path/to/another/spack/opt/spack ``install_tree`` must point to the ``opt/spack`` directory inside of the -Spack base directory. +Spack base directory, or the location of the ``install_tree`` defined +in :ref:`config.yaml `. Once the upstream Spack instance has been added, ``spack find`` will automatically check the upstream instance when querying installed packages, diff --git a/lib/spack/docs/config_yaml.rst b/lib/spack/docs/config_yaml.rst index 4781597d1a49a4..92ae421571d256 100644 --- a/lib/spack/docs/config_yaml.rst +++ b/lib/spack/docs/config_yaml.rst @@ -145,6 +145,25 @@ hosts when making ``ssl`` connections. Set to ``false`` to disable, and tools like ``curl`` will use their ``--insecure`` options. Disabling this can expose you to attacks. Use at your own risk. +-------------------- +``ssl_certs`` +-------------------- + +Path to custom certificats for SSL verification. The value can be a +filesytem path, or an environment variable that expands to an absolute file path. +The default value is set to the environment variable ``SSL_CERT_FILE`` +to use the same syntax used by many other applications that automatically +detect custom certificates. +When ``url_fetch_method:curl`` the ``config:ssl_certs`` should resolve to +a single file. Spack will then set the environment variable ``CURL_CA_BUNDLE`` +in the subprocess calling ``curl``. +If ``url_fetch_method:urllib`` then files and directories are supported i.e. +``config:ssl_certs:$SSL_CERT_FILE`` or ``config:ssl_certs:$SSL_CERT_DIR`` +will work. +In all cases the expanded path must be absolute for Spack to use the certificates. +Certificates relative to an environment can be created by prepending the path variable +with the Spack configuration variable``$env``. + -------------------- ``checksum`` -------------------- diff --git a/lib/spack/docs/containers.rst b/lib/spack/docs/containers.rst index 50d96f65370fa1..38a384754902f4 100644 --- a/lib/spack/docs/containers.rst +++ b/lib/spack/docs/containers.rst @@ -194,21 +194,18 @@ The OS that are currently supported are summarized in the table below: * - Operating System - Base Image - Spack Image - * - Ubuntu 18.04 - - ``ubuntu:18.04`` - - ``spack/ubuntu-bionic`` * - Ubuntu 20.04 - ``ubuntu:20.04`` - ``spack/ubuntu-focal`` * - Ubuntu 22.04 - ``ubuntu:22.04`` - ``spack/ubuntu-jammy`` - * - CentOS 7 - - ``centos:7`` - - ``spack/centos7`` - * - CentOS Stream - - ``quay.io/centos/centos:stream`` - - ``spack/centos-stream`` + * - Ubuntu 24.04 + - ``ubuntu:24.04`` + - ``spack/ubuntu-noble`` + * - CentOS Stream9 + - ``quay.io/centos/centos:stream9`` + - ``spack/centos-stream9`` * - openSUSE Leap - ``opensuse/leap`` - ``spack/leap15`` @@ -227,12 +224,12 @@ The OS that are currently supported are summarized in the table below: * - Rocky Linux 9 - ``rockylinux:9`` - ``spack/rockylinux9`` - * - Fedora Linux 37 - - ``fedora:37`` - - ``spack/fedora37`` - * - Fedora Linux 38 - - ``fedora:38`` - - ``spack/fedora38`` + * - Fedora Linux 39 + - ``fedora:39`` + - ``spack/fedora39`` + * - Fedora Linux 40 + - ``fedora:40`` + - ``spack/fedora40`` diff --git a/lib/spack/docs/developer_guide.rst b/lib/spack/docs/developer_guide.rst index af69b219a70a4d..91550f795fd86c 100644 --- a/lib/spack/docs/developer_guide.rst +++ b/lib/spack/docs/developer_guide.rst @@ -552,11 +552,11 @@ With either interpreter you can run a single command: .. code-block:: console - $ spack python -c 'import distro; distro.linux_distribution()' - ('Ubuntu', '18.04', 'Bionic Beaver') + $ spack python -c 'from spack.spec import Spec; Spec("python").concretized()' + ... - $ spack python -i ipython -c 'import distro; distro.linux_distribution()' - Out[1]: ('Ubuntu', '18.04', 'Bionic Beaver') + $ spack python -i ipython -c 'from spack.spec import Spec; Spec("python").concretized()' + Out[1]: ... or a file: @@ -1071,9 +1071,9 @@ Announcing a release We announce releases in all of the major Spack communication channels. Publishing the release takes care of GitHub. The remaining channels are -Twitter, Slack, and the mailing list. Here are the steps: +X, Slack, and the mailing list. Here are the steps: -#. Announce the release on Twitter. +#. Announce the release on X. * Compose the tweet on the ``@spackpm`` account per the ``spack-twitter`` slack channel. diff --git a/lib/spack/docs/environments.rst b/lib/spack/docs/environments.rst index 4104af619f8675..ffa5e5f3c38577 100644 --- a/lib/spack/docs/environments.rst +++ b/lib/spack/docs/environments.rst @@ -142,12 +142,8 @@ user's prompt to begin with the environment name in brackets. $ spack env activate -p myenv [myenv] $ ... -The ``activate`` command can also be used to create a new environment, if it is -not already defined, by adding the ``--create`` flag. Managed and anonymous -environments, anonymous environments are explained in the next section, -can both be created using the same flags that `spack env create` accepts. -If an environment already exists then spack will simply activate it and ignore the -create specific flags. +The ``activate`` command can also be used to create a new environment if it does not already +exist. .. code-block:: console @@ -176,21 +172,36 @@ environment will remove the view from the user environment. Anonymous Environments ^^^^^^^^^^^^^^^^^^^^^^ -Any directory can be treated as an environment if it contains a file -``spack.yaml``. To load an anonymous environment, use: +Apart from managed environments, Spack also supports anonymous environments. + +Anonymous environments can be placed in any directory of choice. + +.. note:: + + When uninstalling packages, Spack asks the user to confirm the removal of packages + that are still used in a managed environment. This is not the case for anonymous + environments. + +To create an anonymous environment, use one of the following commands: + +.. code-block:: console + + $ spack env create --dir my_env + $ spack env create ./my_env + +As a shorthand, you can also create an anonymous environment upon activation if it does not +already exist: .. code-block:: console - $ spack env activate -d /path/to/directory + $ spack env activate --create ./my_env -Anonymous specs can be created in place using the command: +For convenience, Spack can also place an anonymous environment in a temporary directory for you: .. code-block:: console - $ spack env create -d . + $ spack env activate --temp -In this case Spack simply creates a ``spack.yaml`` file in the requested -directory. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Environment Sensitive Commands @@ -449,6 +460,125 @@ Sourcing that file in Bash will make the environment available to the user; and can be included in ``.bashrc`` files, etc. The ``loads`` file may also be copied out of the environment, renamed, etc. + +.. _environment_include_concrete: + +------------------------------ +Included Concrete Environments +------------------------------ + +Spack environments can create an environment based off of information in already +established environments. You can think of it as a combination of existing +environments. It will gather information from the existing environment's +``spack.lock`` and use that during the creation of this included concrete +environment. When an included concrete environment is created it will generate +a ``spack.lock`` file for the newly created environment. + + +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +Creating included environments +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +To create a combined concrete environment, you must have at least one existing +concrete environment. You will use the command ``spack env create`` with the +argument ``--include-concrete`` followed by the name or path of the environment +you'd like to include. Here is an example of how to create a combined environment +from the command line. + +.. code-block:: console + + $ spack env create myenv + $ spack -e myenv add python + $ spack -e myenv concretize + $ spack env create --include-concrete myenv included_env + + +You can also include an environment directly in the ``spack.yaml`` file. It +involves adding the ``include_concrete`` heading in the yaml followed by the +absolute path to the independent environments. + +.. code-block:: yaml + + spack: + specs: [] + concretizer: + unify: true + include_concrete: + - /absolute/path/to/environment1 + - /absolute/path/to/environment2 + + +Once the ``spack.yaml`` has been updated you must concretize the environment to +get the concrete specs from the included environments. + +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +Updating an included environment +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +If changes were made to the base environment and you want that reflected in the +included environment you will need to reconcretize both the base environment and the +included environment for the change to be implemented. For example: + +.. code-block:: console + + $ spack env create myenv + $ spack -e myenv add python + $ spack -e myenv concretize + $ spack env create --include-concrete myenv included_env + + + $ spack -e myenv find + ==> In environment myenv + ==> Root specs + python + + ==> 0 installed packages + + + $ spack -e included_env find + ==> In environment included_env + ==> No root specs + ==> Included specs + python + + ==> 0 installed packages + +Here we see that ``included_env`` has access to the python package through +the ``myenv`` environment. But if we were to add another spec to ``myenv``, +``included_env`` will not be able to access the new information. + +.. code-block:: console + + $ spack -e myenv add perl + $ spack -e myenv concretize + $ spack -e myenv find + ==> In environment myenv + ==> Root specs + perl python + + ==> 0 installed packages + + + $ spack -e included_env find + ==> In environment included_env + ==> No root specs + ==> Included specs + python + + ==> 0 installed packages + +It isn't until you run the ``spack concretize`` command that the combined +environment will get the updated information from the reconcretized base environmennt. + +.. code-block:: console + + $ spack -e included_env concretize + $ spack -e included_env find + ==> In environment included_env + ==> No root specs + ==> Included specs + perl python + + ==> 0 installed packages + .. _environment-configuration: ------------------------ @@ -800,32 +930,85 @@ For example, the following environment has three root packages: This allows for a much-needed reduction in redundancy between packages and constraints. ----------------- -Filesystem Views ----------------- -Spack Environments can define filesystem views, which provide a direct access point -for software similar to the directory hierarchy that might exist under ``/usr/local``. -Filesystem views are updated every time the environment is written out to the lock -file ``spack.lock``, so the concrete environment and the view are always compatible. -The files of the view's installed packages are brought into the view by symbolic or -hard links, referencing the original Spack installation, or by copy. +----------------- +Environment Views +----------------- + +Spack Environments can have an associated filesystem view, which is a directory +with a more traditional structure ``/bin``, ``/lib``, ``/include`` +in which all files of the installed packages are linked. + +By default a view is created for each environment, thanks to the ``view: true`` +option in the ``spack.yaml`` manifest file: + +.. code-block:: yaml + + spack: + specs: [perl, python] + view: true + +The view is created in a hidden directory ``.spack-env/view`` relative to the environment. +If you've used ``spack env activate``, you may have already interacted with this view. Spack +prepends its ``/bin`` dir to ``PATH`` when the environment is activated, so that +you can directly run executables from all installed packages in the environment. + +Views are highly customizable: you can control where they are put, modify their structure, +include and exclude specs, change how files are linked, and you can even generate multiple +views for a single environment. .. _configuring_environment_views: -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -Configuration in ``spack.yaml`` -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +^^^^^^^^^^^^^^^^^^^^^^^^^^ +Minimal view configuration +^^^^^^^^^^^^^^^^^^^^^^^^^^ + +The minimal configuration + +.. code-block:: yaml + + spack: + # ... + view: true + +lets Spack generate a single view with default settings under the +``.spack-env/view`` directory of the environment. + +Another short way to configure a view is to specify just where to put it: + +.. code-block:: yaml + + spack: + # ... + view: /path/to/view -The Spack Environment manifest file has a top-level keyword -``view``. Each entry under that heading is a **view descriptor**, headed -by a name. Any number of views may be defined under the ``view`` heading. -The view descriptor contains the root of the view, and -optionally the projections for the view, ``select`` and -``exclude`` lists for the view and link information via ``link`` and +Views can also be disabled by setting ``view: false``. + +^^^^^^^^^^^^^^^^^^^^^^^^^^^ +Advanced view configuration +^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +One or more **view descriptors** can be defined under ``view``, keyed by a name. +The example from the previous section with ``view: /path/to/view`` is equivalent +to defining a view descriptor named ``default`` with a ``root`` attribute: + +.. code-block:: yaml + + spack: + # ... + view: + default: # name of the view + root: /path/to/view # view descriptor attribute + +The ``default`` view descriptor name is special: when you ``spack env activate`` your +environment, this view will be used to update (among other things) your ``PATH`` +variable. + +View descriptors must contain the root of the view, and optionally projections, +``select`` and ``exclude`` lists and link information via ``link`` and ``link_type``. -For example, in the following manifest +As a more advanced example, in the following manifest file snippet we define a view named ``mpis``, rooted at ``/path/to/view`` in which all projections use the package name, version, and compiler name to determine the path for a given @@ -870,59 +1053,10 @@ of ``hardlink`` or ``copy``. when the environment is not activated, and linked libraries will be located *outside* of the view thanks to rpaths. - -There are two shorthands for environments with a single view. If the -environment at ``/path/to/env`` has a single view, with a root at -``/path/to/env/.spack-env/view``, with default selection and exclusion -and the default projection, we can put ``view: True`` in the -environment manifest. Similarly, if the environment has a view with a -different root, but default selection, exclusion, and projections, the -manifest can say ``view: /path/to/view``. These views are -automatically named ``default``, so that - -.. code-block:: yaml - - spack: - # ... - view: True - -is equivalent to - -.. code-block:: yaml - - spack: - # ... - view: - default: - root: .spack-env/view - -and - -.. code-block:: yaml - - spack: - # ... - view: /path/to/view - -is equivalent to - -.. code-block:: yaml - - spack: - # ... - view: - default: - root: /path/to/view - -By default, Spack environments are configured with ``view: True`` in -the manifest. Environments can be configured without views using -``view: False``. For backwards compatibility reasons, environments -with no ``view`` key are treated the same as ``view: True``. - From the command line, the ``spack env create`` command takes an argument ``--with-view [PATH]`` that sets the path for a single, default view. If no path is specified, the default path is used (``view: -True``). The argument ``--without-view`` can be used to create an +true``). The argument ``--without-view`` can be used to create an environment without any view configured. The ``spack env view`` command can be used to change the manage views @@ -988,11 +1122,18 @@ the projection under ``all`` before reaching those entries. Activating environment views ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -The ``spack env activate`` command will put the default view for the -environment into the user's path, in addition to activating the -environment for Spack commands. The arguments ``-v,--with-view`` and -``-V,--without-view`` can be used to tune this behavior. The default -behavior is to activate with the environment view if there is one. +The ``spack env activate `` has two effects: + +1. It activates the environment so that further Spack commands such + as ``spack install`` will run in the context of the environment. +2. It activates the view so that environment variables such as + ``PATH`` are updated to include the view. + +Without further arguments, the ``default`` view of the environment is +activated. If a view with a different name has to be activated, +``spack env activate --with-view `` can be +used instead. You can also activate the environment without modifying +further environment variables using ``--without-view``. The environment variables affected by the ``spack env activate`` command and the paths that are used to update them are determined by @@ -1015,8 +1156,8 @@ relevant variable if the path exists. For this reason, it is not recommended to use non-default projections with the default view of an environment. -The ``spack env deactivate`` command will remove the default view of -the environment from the user's path. +The ``spack env deactivate`` command will remove the active view of +the Spack environment from the user's environment variables. .. _env-generate-depfile: @@ -1033,7 +1174,7 @@ other targets to depend on the environment installation. A typical workflow is as follows: -.. code:: console +.. code-block:: console spack env create -d . spack -e . add perl @@ -1126,7 +1267,7 @@ its dependencies. This can be useful when certain flags should only apply to dependencies. Below we show a use case where a spec is installed with verbose output (``spack install --verbose``) while its dependencies are installed silently: -.. code:: console +.. code-block:: console $ spack env depfile -o Makefile @@ -1148,7 +1289,7 @@ This can be accomplished through the generated ``[/]SPACK_PACKAGE_IDS`` variable. Assuming we have an active and concrete environment, we generate the associated ``Makefile`` with a prefix ``example``: -.. code:: console +.. code-block:: console $ spack env depfile -o env.mk --make-prefix example @@ -1175,7 +1316,7 @@ index once every package is pushed. Note how this target uses the generated example/push/%: example/install/% @mkdir -p $(dir $@) $(info About to push $(SPEC) to a buildcache) - $(SPACK) -e . buildcache push --allow-root --only=package $(BUILDCACHE_DIR) /$(HASH) + $(SPACK) -e . buildcache push --only=package $(BUILDCACHE_DIR) /$(HASH) @touch $@ push: $(addprefix example/push/,$(example/SPACK_PACKAGE_IDS)) diff --git a/lib/spack/docs/getting_started.rst b/lib/spack/docs/getting_started.rst index ab9c274e0148c1..4cbd1efee7a549 100644 --- a/lib/spack/docs/getting_started.rst +++ b/lib/spack/docs/getting_started.rst @@ -478,6 +478,13 @@ prefix, you can add them to the ``extra_attributes`` field. Similarly, all other fields from the compilers config can be added to the ``extra_attributes`` field for an external representing a compiler. +Note that the format for the ``paths`` field in the +``extra_attributes`` section is different than in the ``compilers`` +config. For compilers configured as external packages, the section is +named ``compilers`` and the dictionary maps language names (``c``, +``cxx``, ``fortran``) to paths, rather than using the names ``cc``, +``fc``, and ``f77``. + .. code-block:: yaml packages: @@ -493,11 +500,10 @@ all other fields from the compilers config can be added to the - spec: llvm+clang@15.0.0 arch=linux-rhel8-skylake prefix: /usr extra_attributes: - paths: - cc: /usr/bin/clang-with-suffix + compilers: + c: /usr/bin/clang-with-suffix cxx: /usr/bin/clang++-with-extra-info - fc: /usr/bin/gfortran - f77: /usr/bin/gfortran + fortran: /usr/bin/gfortran extra_rpaths: - /usr/lib/llvm/ @@ -1358,187 +1364,6 @@ This will write the private key to the file `dinosaur.priv`. or for help on an issue or the Spack slack. -.. _cray-support: - -------------- -Spack on Cray -------------- - -Spack differs slightly when used on a Cray system. The architecture spec -can differentiate between the front-end and back-end processor and operating system. -For example, on Edison at NERSC, the back-end target processor -is "Ivy Bridge", so you can specify to use the back-end this way: - -.. code-block:: console - - $ spack install zlib target=ivybridge - -You can also use the operating system to build against the back-end: - -.. code-block:: console - - $ spack install zlib os=CNL10 - -Notice that the name includes both the operating system name and the major -version number concatenated together. - -Alternatively, if you want to build something for the front-end, -you can specify the front-end target processor. The processor for a login node -on Edison is "Sandy bridge" so we specify on the command line like so: - -.. code-block:: console - - $ spack install zlib target=sandybridge - -And the front-end operating system is: - -.. code-block:: console - - $ spack install zlib os=SuSE11 - -^^^^^^^^^^^^^^^^^^^^^^^ -Cray compiler detection -^^^^^^^^^^^^^^^^^^^^^^^ - -Spack can detect compilers using two methods. For the front-end, we treat -everything the same. The difference lies in back-end compiler detection. -Back-end compiler detection is made via the Tcl module avail command. -Once it detects the compiler it writes the appropriate PrgEnv and compiler -module name to compilers.yaml and sets the paths to each compiler with Cray\'s -compiler wrapper names (i.e. cc, CC, ftn). During build time, Spack will load -the correct PrgEnv and compiler module and will call appropriate wrapper. - -The compilers.yaml config file will also differ. There is a -modules section that is filled with the compiler's Programming Environment -and module name. On other systems, this field is empty []: - -.. code-block:: yaml - - - compiler: - modules: - - PrgEnv-intel - - intel/15.0.109 - -As mentioned earlier, the compiler paths will look different on a Cray system. -Since most compilers are invoked using cc, CC and ftn, the paths for each -compiler are replaced with their respective Cray compiler wrapper names: - -.. code-block:: yaml - - paths: - cc: cc - cxx: CC - f77: ftn - fc: ftn - -As opposed to an explicit path to the compiler executable. This allows Spack -to call the Cray compiler wrappers during build time. - -For more on compiler configuration, check out :ref:`compiler-config`. - -Spack sets the default Cray link type to dynamic, to better match other -other platforms. Individual packages can enable static linking (which is the -default outside of Spack on cray systems) using the ``-static`` flag. - -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -Setting defaults and using Cray modules -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - -If you want to use default compilers for each PrgEnv and also be able -to load cray external modules, you will need to set up a ``packages.yaml``. - -Here's an example of an external configuration for cray modules: - -.. code-block:: yaml - - packages: - mpich: - externals: - - spec: "mpich@7.3.1%gcc@5.2.0 arch=cray_xc-haswell-CNL10" - modules: - - cray-mpich - - spec: "mpich@7.3.1%intel@16.0.0.109 arch=cray_xc-haswell-CNL10" - modules: - - cray-mpich - all: - providers: - mpi: [mpich] - -This tells Spack that for whatever package that depends on mpi, load the -cray-mpich module into the environment. You can then be able to use whatever -environment variables, libraries, etc, that are brought into the environment -via module load. - -.. note:: - - For Cray-provided packages, it is best to use ``modules:`` instead of ``prefix:`` - in ``packages.yaml``, because the Cray Programming Environment heavily relies on - modules (e.g., loading the ``cray-mpich`` module adds MPI libraries to the - compiler wrapper link line). - -You can set the default compiler that Spack can use for each compiler type. -If you want to use the Cray defaults, then set them under ``all:`` in packages.yaml. -In the compiler field, set the compiler specs in your order of preference. -Whenever you build with that compiler type, Spack will concretize to that version. - -Here is an example of a full packages.yaml used at NERSC - -.. code-block:: yaml - - packages: - mpich: - externals: - - spec: "mpich@7.3.1%gcc@5.2.0 arch=cray_xc-CNL10-ivybridge" - modules: - - cray-mpich - - spec: "mpich@7.3.1%intel@16.0.0.109 arch=cray_xc-SuSE11-ivybridge" - modules: - - cray-mpich - buildable: False - netcdf: - externals: - - spec: "netcdf@4.3.3.1%gcc@5.2.0 arch=cray_xc-CNL10-ivybridge" - modules: - - cray-netcdf - - spec: "netcdf@4.3.3.1%intel@16.0.0.109 arch=cray_xc-CNL10-ivybridge" - modules: - - cray-netcdf - buildable: False - hdf5: - externals: - - spec: "hdf5@1.8.14%gcc@5.2.0 arch=cray_xc-CNL10-ivybridge" - modules: - - cray-hdf5 - - spec: "hdf5@1.8.14%intel@16.0.0.109 arch=cray_xc-CNL10-ivybridge" - modules: - - cray-hdf5 - buildable: False - all: - compiler: [gcc@5.2.0, intel@16.0.0.109] - providers: - mpi: [mpich] - -Here we tell spack that whenever we want to build with gcc use version 5.2.0 or -if we want to build with intel compilers, use version 16.0.0.109. We add a spec -for each compiler type for each cray modules. This ensures that for each -compiler on our system we can use that external module. - -For more on external packages check out the section :ref:`sec-external-packages`. - -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -Using Linux containers on Cray machines -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - -Spack uses environment variables particular to the Cray programming -environment to determine which systems are Cray platforms. These -environment variables may be propagated into containers that are not -using the Cray programming environment. - -To ensure that Spack does not autodetect the Cray programming -environment, unset the environment variable ``MODULEPATH``. This -will cause Spack to treat a linux container on a Cray system as a base -linux distro. - .. _windows_support: ---------------- @@ -1572,6 +1397,8 @@ Microsoft Visual Studio """"""""""""""""""""""" Microsoft Visual Studio provides the only Windows C/C++ compiler that is currently supported by Spack. +Spack additionally requires that the Windows SDK (including WGL) to be installed as part of your +visual studio installation as it is required to build many packages from source. We require several specific components to be included in the Visual Studio installation. One is the C/C++ toolset, which can be selected as "Desktop development with C++" or "C++ build tools," @@ -1579,6 +1406,7 @@ depending on installation type (Professional, Build Tools, etc.) The other requ "C++ CMake tools for Windows," which can be selected from among the optional packages. This provides CMake and Ninja for use during Spack configuration. + If you already have Visual Studio installed, you can make sure these components are installed by rerunning the installer. Next to your installation, select "Modify" and look at the "Installation details" pane on the right. diff --git a/lib/spack/docs/packaging_guide.rst b/lib/spack/docs/packaging_guide.rst index 0fa8e4dce31941..629b87e8e0f941 100644 --- a/lib/spack/docs/packaging_guide.rst +++ b/lib/spack/docs/packaging_guide.rst @@ -893,26 +893,50 @@ as an option to the ``version()`` directive. Example situations would be a "snapshot"-like Version Control System (VCS) tag, a VCS branch such as ``v6-16-00-patches``, or a URL specifying a regularly updated snapshot tarball. + +.. _version-comparison: + ^^^^^^^^^^^^^^^^^^ Version comparison ^^^^^^^^^^^^^^^^^^ -Most Spack versions are numeric, a tuple of integers; for example, -``0.1``, ``6.96`` or ``1.2.3.1``. Spack knows how to compare and sort -numeric versions. - -Some Spack versions involve slight extensions of numeric syntax; for -example, ``py-sphinx-rtd-theme@=0.1.10a0``. In this case, numbers are -always considered to be "newer" than letters. This is for consistency -with `RPM `_. - -Spack versions may also be arbitrary non-numeric strings, for example -``develop``, ``master``, ``local``. +Spack imposes a generic total ordering on the set of versions, +independently from the package they are associated with. -The order on versions is defined as follows. A version string is split -into a list of components based on delimiters such as ``.``, ``-`` etc. -Lists are then ordered lexicographically, where components are ordered -as follows: +Most Spack versions are numeric, a tuple of integers; for example, +``0.1``, ``6.96`` or ``1.2.3.1``. In this very basic case, version +comparison is lexicographical on the numeric components: +``1.2 < 1.2.1 < 1.2.2 < 1.10``. + +Spack can also supports string components such as ``1.1.1a`` and +``1.y.0``. String components are considered less than numeric +components, so ``1.y.0 < 1.0``. This is for consistency with +`RPM `_. String +components do not have to be separated by dots or any other delimiter. +So, the contrived version ``1y0`` is identical to ``1.y.0``. + +Pre-release suffixes also contain string parts, but they are handled +in a special way. For example ``1.2.3alpha1`` is parsed as a pre-release +of the version ``1.2.3``. This allows Spack to order it before the +actual release: ``1.2.3alpha1 < 1.2.3``. Spack supports alpha, beta and +release candidate suffixes: ``1.2alpha1 < 1.2beta1 < 1.2rc1 < 1.2``. Any +suffix not recognized as a pre-release is treated as an ordinary +string component, so ``1.2 < 1.2-mysuffix``. + +Finally, there are a few special string components that are considered +"infinity versions". They include ``develop``, ``main``, ``master``, +``head``, ``trunk``, and ``stable``. For example: ``1.2 < develop``. +These are useful for specifying the most recent development version of +a package (often a moving target like a git branch), without assigning +a specific version number. Infinity versions are not automatically used when determining the latest version of a package unless explicitly required by another package or user. + +More formally, the order on versions is defined as follows. A version +string is split into a list of components based on delimiters such as +``.`` and ``-`` and string boundaries. The components are split into +the **release** and a possible **pre-release** (if the last component +is numeric and the second to last is a string ``alpha``, ``beta`` or ``rc``). +The release components are ordered lexicographically, with comparsion +between different types of components as follows: #. The following special strings are considered larger than any other numeric or non-numeric version component, and satisfy the following @@ -925,6 +949,9 @@ as follows: #. All other non-numeric components are less than numeric components, and are ordered alphabetically. +Finally, if the release components are equal, the pre-release components +are used to break the tie, in the obvious way. + The logic behind this sort order is two-fold: #. Non-numeric versions are usually used for special cases while @@ -2317,6 +2344,27 @@ you set ``parallel`` to ``False`` at the package level, then each call to ``make()`` will be sequential by default, but packagers can call ``make(parallel=True)`` to override it. +Note that the ``--jobs`` option works out of the box for all standard +build systems. If you are using a non-standard build system instead, you +can use the variable ``make_jobs`` to extract the number of jobs specified +by the ``--jobs`` option: + +.. code-block:: python + :emphasize-lines: 7, 11 + :linenos: + + class Xios(Package): + ... + def install(self, spec, prefix): + ... + options = [ + ... + '--jobs', str(make_jobs), + ] + ... + make_xios = Executable("./make_xios") + make_xios(*options) + ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Install-level build parallelism ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -5146,12 +5194,6 @@ installed executable. The check is implemented as follows: reframe = Executable(self.prefix.bin.reframe) reframe("-l") -.. warning:: - - The API for adding tests is not yet considered stable and may change - in future releases. - - """""""""""""""""""""""""""""""" Checking build-time test results """""""""""""""""""""""""""""""" @@ -5189,38 +5231,42 @@ be left in the build stage directory as illustrated below: Stand-alone tests ^^^^^^^^^^^^^^^^^ -While build-time tests are integrated with the build process, stand-alone +While build-time tests are integrated with the installation process, stand-alone tests are expected to run days, weeks, even months after the software is installed. The goal is to provide a mechanism for gaining confidence that packages work as installed **and** *continue* to work as the underlying software evolves. Packages can add and inherit stand-alone tests. The -`spack test`` command is used to manage stand-alone testing. +``spack test`` command is used for stand-alone testing. -.. note:: +.. admonition:: Stand-alone test methods should complete within a few minutes. Execution speed is important since these tests are intended to quickly - assess whether installed specs work on the system. Consequently, they - should run relatively quickly -- as in on the order of at most a few - minutes -- while ideally executing all, or at least key aspects of the - installed software. + assess whether installed specs work on the system. Spack cannot spare + resources for more extensive testing of packages included in CI stacks. -.. note:: - - Failing stand-alone tests indicate problems with the installation and, - therefore, there is no reason to proceed with more resource-intensive - tests until those have been investigated. - - Passing stand-alone tests indicate that more thorough testing, such - as running extensive unit or regression tests, or tests that run at - scale can proceed without wasting resources on a problematic installation. + Consequently, stand-alone tests should run relatively quickly -- as in + on the order of at most a few minutes -- while testing at least key aspects + of the installed software. Save more extensive testing for other tools. Tests are defined in the package using methods with names beginning ``test_``. This allows Spack to support multiple independent checks, or parts. Files needed for testing, such as source, data, and expected outputs, may be saved from the build and or stored with the package in the repository. Regardless of origin, these files are automatically copied to the spec's test stage -directory prior to execution of the test method(s). Spack also provides some -helper functions to facilitate processing. +directory prior to execution of the test method(s). Spack also provides helper +functions to facilitate common processing. + +.. tip:: + + **The status of stand-alone tests can be used to guide follow-up testing efforts.** + + Passing stand-alone tests justify performing more thorough testing, such + as running extensive unit or regression tests or tests that run at scale, + when available. These tests are outside of the scope of Spack packaging. + + Failing stand-alone tests indicate problems with the installation and, + therefore, no reason to proceed with more resource-intensive tests until + the failures have been investigated. .. _configure-test-stage: @@ -5228,30 +5274,26 @@ helper functions to facilitate processing. Configuring the test stage directory """""""""""""""""""""""""""""""""""" -Stand-alone tests utilize a test stage directory for building, running, -and tracking results in the same way Spack uses a build stage directory. -The default test stage root directory, ``~/.spack/test``, is defined in -:ref:`etc/spack/defaults/config.yaml `. This location is -customizable by adding or changing the ``test_stage`` path in the high-level -``config`` of the appropriate ``config.yaml`` file such that: +Stand-alone tests utilize a test stage directory to build, run, and track +tests in the same way Spack uses a build stage directory to install software. +The default test stage root directory, ``$HOME/.spack/test``, is defined in +:ref:`config.yaml `. This location is customizable by adding or +changing the ``test_stage`` path such that: .. code-block:: yaml config: test_stage: /path/to/test/stage -Packages can use the ``self.test_suite.stage`` property to access this setting. -Other package properties that provide access to spec-specific subdirectories -and files are described in :ref:`accessing staged files `. +Packages can use the ``self.test_suite.stage`` property to access the path. -.. note:: +.. admonition:: Each spec being tested has its own test stage directory. - The test stage path is the root directory for the **entire suite**. - In other words, it is the root directory for **all specs** being - tested by the ``spack test run`` command. Each spec gets its own - stage subdirectory. Use ``self.test_suite.test_dir_for_spec(self.spec)`` - to access the spec-specific test stage directory. + The ``config:test_stage`` option is the path to the root of a + **test suite**'s stage directories. + Other package properties that provide paths to spec-specific subdirectories + and files are described in :ref:`accessing-files`. .. _adding-standalone-tests: @@ -5264,61 +5306,144 @@ Test recipes are defined in the package using methods with names beginning Each method has access to the information Spack tracks on the package, such as options, compilers, and dependencies, supporting the customization of tests to the build. Standard python ``assert`` statements and other error reporting -mechanisms are available. Such exceptions are automatically caught and reported +mechanisms can be used. These exceptions are automatically caught and reported as test failures. -Each test method is an implicit test part named by the method and whose -purpose is the method's docstring. Providing a purpose gives context for -aiding debugging. A test method may contain embedded test parts. Spack -outputs the test name and purpose prior to running each test method and -any embedded test parts. For example, ``MyPackage`` below provides two basic -examples of installation tests: ``test_always_fails`` and ``test_example``. -As the name indicates, the first always fails. The second simply runs the -installed example. +Each test method is an *implicit test part* named by the method. Its purpose +is the method's docstring. Providing a meaningful purpose for the test gives +context that can aid debugging. Spack outputs both the name and purpose at the +start of test execution so it's also important that the docstring/purpose be +brief. + +.. tip:: + + We recommend naming test methods so it is clear *what* is being tested. + For example, if a test method is building and or running an executable + called ``example``, then call the method ``test_example``. This, together + with a similarly meaningful test purpose, will aid test comprehension, + debugging, and maintainability. + +Stand-alone tests run in an environment that provides access to information +on the installed software, such as build options, dependencies, and compilers. +Build options and dependencies are accessed using the same spec checks used +by build recipes. Examples of checking :ref:`variant settings ` and +:ref:`spec constraints ` can be found at the provided links. + +.. admonition:: Spack automatically sets up the test stage directory and environment. + + Spack automatically creates the test stage directory and copies + relevant files *prior to* running tests. It can also ensure build + dependencies are available **if** necessary. + + The path to the test stage is configurable (see :ref:`configure-test-stage`). + + Files that Spack knows to copy are those saved from the build (see + :ref:`cache_extra_test_sources`) and those added to the package repository + (see :ref:`cache_custom_files`). + + Spack will use the value of the ``test_requires_compiler`` property to + determine whether it needs to also set up build dependencies (see + :ref:`test-build-tests`). + +The ``MyPackage`` package below provides two basic test examples: +``test_example`` and ``test_example2``. The first runs the installed +``example`` and ensures its output contains an expected string. The second +runs ``example2`` without checking output so is only concerned with confirming +the executable runs successfully. If the installed spec is not expected to have +``example2``, then the check at the top of the method will raise a special +``SkipTest`` exception, which is captured to facilitate reporting skipped test +parts to tools like CDash. .. code-block:: python class MyPackage(Package): ... - def test_always_fails(self): - """use assert to always fail""" - assert False - def test_example(self): - """run installed example""" + """ensure installed example works""" + expected = "Done." example = which(self.prefix.bin.example) - example() + + # Capture stdout and stderr from running the Executable + # and check that the expected output was produced. + out = example(output=str.split, error=str.split) + assert expected in out, f"Expected '{expected}' in the output" + + def test_example2(self): + """run installed example2""" + if self.spec.satisfies("@:1.0"): + # Raise SkipTest to ensure flagging the test as skipped for + # test reporting purposes. + raise SkipTest("Test is only available for v1.1 on") + + example2 = which(self.prefix.bin.example2) + example2() Output showing the identification of each test part after running the tests is illustrated below. .. code-block:: console - $ spack test run --alias mypackage mypackage@1.0 + $ spack test run --alias mypackage mypackage@2.0 ==> Spack test mypackage ... $ spack test results -l mypackage ==> Results for test suite 'mypackage': ... - ==> [2023-03-10-16:03:56.625204] test: test_always_fails: use assert to always fail + ==> [2024-03-10-16:03:56.625439] test: test_example: ensure installed example works ... - FAILED - ==> [2023-03-10-16:03:56.625439] test: test_example: run installed example + PASSED: MyPackage::test_example + ==> [2024-03-10-16:03:56.625439] test: test_example2: run installed example2 ... - PASSED + PASSED: MyPackage::test_example2 +.. admonition:: Do NOT implement tests that must run in the installation prefix. -.. note:: + Use of the package spec's installation prefix for building and running + tests is **strongly discouraged**. Doing so causes permission errors for + shared spack instances *and* facilities that install the software in + read-only file systems or directories. + + Instead, start these test methods by explicitly copying the needed files + from the installation prefix to the test stage directory. Note the test + stage directory is the current directory when the test is executed with + the ``spack test run`` command. + +.. admonition:: Test methods for library packages should build test executables. + + Stand-alone tests for library packages *should* build test executables + that utilize the *installed* library. Doing so ensures the tests follow + a similar build process that users of the library would follow. + + For more information on how to do this, see :ref:`test-build-tests`. + +.. tip:: + + If you want to see more examples from packages with stand-alone tests, run + ``spack pkg grep "def\stest" | sed "s/\/package.py.*//g" | sort -u`` + from the command line to get a list of the packages. + +.. _adding-standalone-test-parts: + +""""""""""""""""""""""""""""" +Adding stand-alone test parts +""""""""""""""""""""""""""""" - If ``MyPackage`` were a recipe for a library, the tests should build - an example or test program that is then executed. +Sometimes dependencies between steps of a test lend themselves to being +broken into parts. Tracking the pass/fail status of each part may aid +debugging. Spack provides a ``test_part`` context manager for use within +test methods. -A test method can include test parts using the ``test_part`` context manager. -Each part is treated as an independent check to allow subsequent test parts -to execute even after a test part fails. +Each test part is independently run, tracked, and reported. Test parts are +executed in the order they appear. If one fails, subsequent test parts are +still performed even if they would also fail. This allows tools like CDash +to track and report the status of test parts across runs. The pass/fail status +of the enclosing test is derived from the statuses of the embedded test parts. -.. _test-part: +.. admonition:: Test method and test part names **must** be unique. + + Test results reporting requires that test methods and embedded test parts + within a package have unique names. The signature for ``test_part`` is: @@ -5340,40 +5465,68 @@ where each argument has the following meaning: * ``work_dir`` is the path to the directory in which the test will run. The default of ``None``, or ``"."``, corresponds to the the spec's test - stage (i.e., ``self.test_suite.test_dir_for_spec(self.spec)``. + stage (i.e., ``self.test_suite.test_dir_for_spec(self.spec)``). -.. admonition:: Tests should **not** run under the installation directory. +.. admonition:: Start test part names with the name of the enclosing test. - Use of the package spec's installation directory for building and running - tests is **strongly** discouraged. Doing so causes permission errors for - shared spack instances *and* facilities that install the software in - read-only file systems or directories. + We **highly recommend** starting the names of test parts with the name + of the enclosing test. Doing so helps with the comprehension, readability + and debugging of test results. -Suppose ``MyPackage`` actually installs two examples we want to use for tests. -These checks can be implemented as separate checks or, as illustrated below, -embedded test parts. +Suppose ``MyPackage`` installs multiple executables that need to run in a +specific order since the outputs from one are inputs of others. Further suppose +we want to add an integration test that runs the executables in order. We can +accomplish this goal by implementing a stand-alone test method consisting of +test parts for each executable as follows: .. code-block:: python class MyPackage(Package): ... - def test_example(self): - """run installed examples""" - for example in ["ex1", "ex2"]: - with test_part( - self, - f"test_example_{example}", - purpose=f"run installed {example}", - ): - exe = which(join_path(self.prefix.bin, example)) - exe() - -In this case, there will be an implicit test part for ``test_example`` -and separate sub-parts for ``ex1`` and ``ex2``. The second sub-part -will be executed regardless of whether the first passes. The test -log for a run where the first executable fails and the second passes -is illustrated below. + def test_series(self): + """run setup, perform, and report""" + + with test_part(self, "test_series_setup", purpose="setup operation"): + exe = which(self.prefix.bin.setup)) + exe() + + with test_part(self, "test_series_run", purpose="perform operation"): + exe = which(self.prefix.bin.run)) + exe() + + with test_part(self, "test_series_report", purpose="generate report"): + exe = which(self.prefix.bin.report)) + exe() + +The result is ``test_series`` runs the following executable in order: ``setup``, +``run``, and ``report``. In this case no options are passed to any of the +executables and no outputs from running them are checked. Consequently, the +implementation could be simplified with a for-loop as follows: + +.. code-block:: python + + class MyPackage(Package): + ... + + def test_series(self): + """execute series setup, run, and report""" + + for exe, reason in [ + ("setup", "setup operation"), + ("run", "perform operation"), + ("report", "generate report") + ]: + with test_part(self, f"test_series_{exe}", purpose=reason): + exe = which(self.prefix.bin.join(exe)) + exe() + +In both cases, since we're using a context manager, each test part in +``test_series`` will execute regardless of the status of the other test +parts. + +Now let's look at the output from running the stand-alone tests where +the second test part, ``test_series_run``, fails. .. code-block:: console @@ -5383,50 +5536,68 @@ is illustrated below. $ spack test results -l mypackage ==> Results for test suite 'mypackage': ... - ==> [2023-03-10-16:03:56.625204] test: test_example: run installed examples - ==> [2023-03-10-16:03:56.625439] test: test_example_ex1: run installed ex1 + ==> [2024-03-10-16:03:56.625204] test: test_series: execute series setup, run, and report + ==> [2024-03-10-16:03:56.625439] test: test_series_setup: setup operation ... - FAILED - ==> [2023-03-10-16:03:56.625555] test: test_example_ex2: run installed ex2 + PASSED: MyPackage::test_series_setup + ==> [2024-03-10-16:03:56.625555] test: test_series_run: perform operation ... - PASSED + FAILED: MyPackage::test_series_run + ==> [2024-03-10-16:03:57.003456] test: test_series_report: generate report + ... + FAILED: MyPackage::test_series_report + FAILED: MyPackage::test_series ... -.. warning:: +Since test parts depended on the success of previous parts, we see that the +failure of one results in the failure of subsequent checks and the overall +result of the test method, ``test_series``, is failure. - Test results reporting requires that each test method and embedded - test part for a package have a unique name. +.. tip:: -Stand-alone tests run in an environment that provides access to information -Spack has on how the software was built, such as build options, dependencies, -and compilers. Build options and dependencies are accessed with the normal -spec checks. Examples of checking :ref:`variant settings ` and -:ref:`spec constraints ` can be found at the provided links. -Accessing compilers in stand-alone tests that are used by the build requires -setting a package property as described :ref:`below `. + If you want to see more examples from packages using ``test_part``, run + ``spack pkg grep "test_part(" | sed "s/\/package.py.*//g" | sort -u`` + from the command line to get a list of the packages. + +.. _test-build-tests: +""""""""""""""""""""""""""""""""""""" +Building and running test executables +""""""""""""""""""""""""""""""""""""" -.. _test-compilation: +.. admonition:: Re-use build-time sources and (small) input data sets when possible. -""""""""""""""""""""""""" -Enabling test compilation -""""""""""""""""""""""""" + We **highly recommend** re-using build-time test sources and pared down + input files for testing installed software. These files are easier + to keep synchronized with software capabilities when they reside + within the software's repository. More information on saving files from + the installation process can be found at :ref:`cache_extra_test_sources`. -If you want to build and run binaries in tests, then you'll need to tell -Spack to load the package's compiler configuration. This is accomplished -by setting the package's ``test_requires_compiler`` property to ``True``. + If that is not possible, you can add test-related files to the package + repository (see :ref:`cache_custom_files`). It will be important to + remember to maintain them so they work across listed or supported versions + of the package. -Setting the property to ``True`` ensures access to the compiler through -canonical environment variables (e.g., ``CC``, ``CXX``, ``FC``, ``F77``). -It also gives access to build dependencies like ``cmake`` through their -``spec objects`` (e.g., ``self.spec["cmake"].prefix.bin.cmake``). +Packages that build libraries are good examples of cases where you'll want +to build test executables from the installed software before running them. +Doing so requires you to let Spack know it needs to load the package's +compiler configuration. This is accomplished by setting the package's +``test_requires_compiler`` property to ``True``. -.. note:: +.. admonition:: ``test_requires_compiler = True`` is required to build test executables. - The ``test_requires_compiler`` property should be added at the top of - the package near other attributes, such as the ``homepage`` and ``url``. + Setting the property to ``True`` ensures access to the compiler through + canonical environment variables (e.g., ``CC``, ``CXX``, ``FC``, ``F77``). + It also gives access to build dependencies like ``cmake`` through their + ``spec objects`` (e.g., ``self.spec["cmake"].prefix.bin.cmake`` for the + path or ``self.spec["cmake"].command`` for the ``Executable`` instance). -Below illustrates using this feature to compile an example. + Be sure to add the property at the top of the package class under other + properties like the ``homepage``. + +The example below, which ignores how ``cxx-example.cpp`` is acquired, +illustrates the basic process of compiling a test executable using the +installed library before running it. .. code-block:: python @@ -5450,28 +5621,22 @@ Below illustrates using this feature to compile an example. cxx_example = which(exe) cxx_example() +Typically the files used to build and or run test executables are either +cached from the installation (see :ref:`cache_extra_test_sources`) or added +to the package repository (see :ref:`cache_custom_files`). There is nothing +preventing the use of both. .. _cache_extra_test_sources: -""""""""""""""""""""""" -Saving build-time files -""""""""""""""""""""""" - -.. note:: - - We highly recommend re-using build-time test sources and pared down - input files for testing installed software. These files are easier - to keep synchronized with software capabilities since they reside - within the software's repository. - - If that is not possible, you can add test-related files to the package - repository (see :ref:`adding custom files `). It - will be important to maintain them so they work across listed or supported - versions of the package. +"""""""""""""""""""""""""""""""""""" +Saving build- and install-time files +"""""""""""""""""""""""""""""""""""" -You can use the ``cache_extra_test_sources`` helper to copy directories -and or files from the source build stage directory to the package's -installation directory. +You can use the ``cache_extra_test_sources`` helper routine to copy +directories and or files from the source build stage directory to the +package's installation directory. Spack will automatically copy these +files for you when it sets up the test stage directory and before it +begins running the tests. The signature for ``cache_extra_test_sources`` is: @@ -5486,46 +5651,69 @@ where each argument has the following meaning: * ``srcs`` is a string *or* a list of strings corresponding to the paths of subdirectories and or files needed for stand-alone testing. -The paths must be relative to the staged source directory. Contents of -subdirectories and files are copied to a special test cache subdirectory -of the installation prefix. They are automatically copied to the appropriate -relative paths under the test stage directory prior to executing stand-alone -tests. +.. warning:: + + Paths provided in the ``srcs`` argument **must be relative** to the + staged source directory. They will be copied to the equivalent relative + location under the test stage directory prior to test execution. + +Contents of subdirectories and files are copied to a special test cache +subdirectory of the installation prefix. They are automatically copied to +the appropriate relative paths under the test stage directory prior to +executing stand-alone tests. + +.. tip:: + + *Perform test-related conversions once when copying files.* + + If one or more of the copied files needs to be modified to reference + the installed software, it is recommended that those changes be made + to the cached files **once** in the post-``install`` copy method + **after** the call to ``cache_extra_test_sources``. This will reduce + the amount of unnecessary work in the test method **and** avoid problems + running stand-alone tests in shared instances and facility deployments. + + The ``filter_file`` function can be quite useful for such changes + (see :ref:`file-filtering`). -For example, a package method for copying everything in the ``tests`` -subdirectory plus the ``foo.c`` and ``bar.c`` files from ``examples`` -and using ``foo.c`` in a test method is illustrated below. +Below is a basic example of a test that relies on files from the installation. +This package method re-uses the contents of the ``examples`` subdirectory, +which is assumed to have all of the files implemented to allow ``make`` to +compile and link ``foo.c`` and ``bar.c`` against the package's installed +library. .. code-block:: python - class MyLibPackage(Package): + class MyLibPackage(MakefilePackage): ... @run_after("install") def copy_test_files(self): - srcs = ["tests", - join_path("examples", "foo.c"), - join_path("examples", "bar.c")] - cache_extra_test_sources(self, srcs) - - def test_foo(self): - exe = "foo" - src_dir = self.test_suite.current_test_cache_dir.examples - with working_dir(src_dir): - cc = which(os.environ["CC"]) - cc( - f"-L{self.prefix.lib}", - f"-I{self.prefix.include}", - f"{exe}.c", - "-o", exe - ) - foo = which(exe) - foo() + cache_extra_test_sources(self, "examples") -In this case, the method copies the associated files from the build -stage, **after** the software is installed, to the package's test -cache directory. Then ``test_foo`` builds ``foo`` using ``foo.c`` -before running the program. + def test_example(self): + """build and run the examples""" + examples_dir = self.test_suite.current_test_cache_dir.examples + with working_dir(examples_dir): + make = which("make") + make() + + for program in ["foo", "bar"]: + with test_part( + self, + f"test_example_{program}", + purpose=f"ensure {program} runs" + ): + exe = Executable(program) + exe() + +In this case, ``copy_test_files`` copies the associated files from the +build stage to the package's test cache directory under the installation +prefix. Running ``spack test run`` for the package results in Spack copying +the directory and its contents to the the test stage directory. The +``working_dir`` context manager ensures the commands within it are executed +from the ``examples_dir``. The test builds the software using ``make`` before +running each executable, ``foo`` and ``bar``, as independent test parts. .. note:: @@ -5534,43 +5722,18 @@ before running the program. The key to copying files for stand-alone testing at build time is use of the ``run_after`` directive, which ensures the associated files are - copied **after** the provided build stage where the files **and** - installation prefix are available. - -These paths are **automatically copied** from cache to the test stage -directory prior to the execution of any stand-alone tests. Tests access -the files using the ``self.test_suite.current_test_cache_dir`` property. -In our example above, test methods can use the following paths to reference -the copy of each entry listed in ``srcs``, respectively: - -* ``self.test_suite.current_test_cache_dir.tests`` -* ``join_path(self.test_suite.current_test_cache_dir.examples, "foo.c")`` -* ``join_path(self.test_suite.current_test_cache_dir.examples, "bar.c")`` - -.. admonition:: Library packages should build stand-alone tests - - Library developers will want to build the associated tests - against their **installed** libraries before running them. - -.. note:: - - While source and input files are generally recommended, binaries - **may** also be cached by the build process. Only you, as the package - writer or maintainer, know whether these files would be appropriate - for testing the installed software weeks to months later. - -.. note:: + copied **after** the provided build stage (``install``) when the installation + prefix **and** files are available. - If one or more of the copied files needs to be modified to reference - the installed software, it is recommended that those changes be made - to the cached files **once** in the ``copy_test_sources`` method and - ***after** the call to ``cache_extra_test_sources()``. This will - reduce the amount of unnecessary work in the test method **and** avoid - problems testing in shared instances and facility deployments. + The test method uses the path contained in the package's + ``self.test_suite.current_test_cache_dir`` property for the root directory + of the copied files. In this case, that's the ``examples`` subdirectory. - The ``filter_file`` function can be quite useful for such changes. - See :ref:`file manipulation `. +.. tip:: + If you want to see more examples from packages that cache build files, run + ``spack pkg grep cache_extra_test_sources | sed "s/\/package.py.*//g" | sort -u`` + from the command line to get a list of the packages. .. _cache_custom_files: @@ -5578,8 +5741,9 @@ the copy of each entry listed in ``srcs``, respectively: Adding custom files """"""""""""""""""" -In some cases it can be useful to have files that can be used to build or -check the results of tests. Examples include: +Sometimes it is helpful or necessary to include custom files for building and +or checking the results of tests as part of the package. Examples of the types +of files that might be useful are: - test source files - test input files @@ -5587,17 +5751,15 @@ check the results of tests. Examples include: - expected test outputs While obtaining such files from the software repository is preferred (see -:ref:`adding build-time files `), there are -circumstances where that is not feasible (e.g., the software is not being -actively maintained). When test files can't be obtained from the repository -or as a supplement to files that can, Spack supports the inclusion of -additional files under the ``test`` subdirectory of the package in the -Spack repository. +:ref:`cache_extra_test_sources`), there are circumstances where doing so is not +feasible such as when the software is not being actively maintained. When test +files cannot be obtained from the repository or there is a need to supplement +files that can, Spack supports the inclusion of additional files under the +``test`` subdirectory of the package in the Spack repository. -Spack **automatically copies** the contents of that directory to the -test staging directory prior to running stand-alone tests. Test methods -access those files using the ``self.test_suite.current_test_data_dir`` -property as shown below. +The following example assumes a ``custom-example.c`` is saved in ``MyLibary`` +package's ``test`` subdirectory. It also assumes the program simply needs to +be compiled and linked against the installed ``MyLibrary`` software. .. code-block:: python @@ -5607,17 +5769,29 @@ property as shown below. test_requires_compiler = True ... - def test_example(self): + def test_custom_example(self): """build and run custom-example""" - data_dir = self.test_suite.current_test_data_dir + src_dir = self.test_suite.current_test_data_dir exe = "custom-example" - src = datadir.join(f"{exe}.cpp") - ... - # TODO: Build custom-example using src and exe - ... - custom_example = which(exe) - custom_example() + with working_dir(src_dir): + cc = which(os.environ["CC"]) + cc( + f"-L{self.prefix.lib}", + f"-I{self.prefix.include}", + f"{exe}.cpp", + "-o", exe + ) + + custom_example = Executable(exe) + custom_example() + +In this case, ``spack test run`` for the package results in Spack copying +the contents of the ``test`` subdirectory to the test stage directory path +in ``self.test_suite.current_test_data_dir`` before calling +``test_custom_example``. Use of the ``working_dir`` context manager +ensures the commands to build and run the program are performed from +within the appropriate subdirectory of the test stage. .. _expected_test_output_from_file: @@ -5626,9 +5800,8 @@ Reading expected output from a file """"""""""""""""""""""""""""""""""" The helper function ``get_escaped_text_output`` is available for packages -to retrieve and properly format the text from a file that contains the -expected output from running an executable that may contain special -characters. +to retrieve properly formatted text from a file potentially containing +special characters. The signature for ``get_escaped_text_output`` is: @@ -5638,10 +5811,13 @@ The signature for ``get_escaped_text_output`` is: where ``filename`` is the path to the file containing the expected output. -The ``filename`` for a :ref:`custom file ` can be -accessed by tests using the ``self.test_suite.current_test_data_dir`` -property. The example below illustrates how to read a file that was -added to the package's ``test`` subdirectory. +The path provided to ``filename`` for one of the copied custom files +(:ref:`custom file `) is in the path rooted at +``self.test_suite.current_test_data_dir``. + +The example below shows how to reference both the custom database +(``packages.db``) and expected output (``dump.out``) files Spack copies +to the test stage: .. code-block:: python @@ -5663,8 +5839,9 @@ added to the package's ``test`` subdirectory. for exp in expected: assert re.search(exp, out), f"Expected '{exp}' in output" -If the file was instead copied from the ``tests`` subdirectory of the staged -source code, the path would be obtained as shown below. +If the files were instead cached from installing the software, the paths to the +two files would be found under the ``self.test_suite.current_test_cache_dir`` +directory as shown below: .. code-block:: python @@ -5672,17 +5849,24 @@ source code, the path would be obtained as shown below. """check example table dump""" test_cache_dir = self.test_suite.current_test_cache_dir db_filename = test_cache_dir.join("packages.db") + .. + expected = get_escaped_text_output(test_cache_dir.join("dump.out")) + ... -Alternatively, if the file was copied to the ``share/tests`` subdirectory -as part of the installation process, the test could access the path as -follows: +Alternatively, if both files had been installed by the software into the +``share/tests`` subdirectory of the installation prefix, the paths to the +two files would be referenced as follows: .. code-block:: python def test_example(self): """check example table dump""" - db_filename = join_path(self.prefix.share.tests, "packages.db") - + db_filename = self.prefix.share.tests.join("packages.db") + .. + expected = get_escaped_text_output( + self.prefix.share.tests.join("dump.out") + ) + ... .. _check_outputs: @@ -5690,9 +5874,9 @@ follows: Comparing expected to actual outputs """""""""""""""""""""""""""""""""""" -The helper function ``check_outputs`` is available for packages to ensure -the expected outputs from running an executable are contained within the -actual outputs. +The ``check_outputs`` helper routine is available for packages to ensure +multiple expected outputs from running an executable are contained within +the actual outputs. The signature for ``check_outputs`` is: @@ -5718,11 +5902,17 @@ Invoking the method is the equivalent of: if errors: raise RuntimeError("\n ".join(errors)) +.. tip:: + + If you want to see more examples from packages that use this helper, run + ``spack pkg grep check_outputs | sed "s/\/package.py.*//g" | sort -u`` + from the command line to get a list of the packages. + .. _accessing-files: """"""""""""""""""""""""""""""""""""""""" -Accessing package- and test-related files +Finding package- and test-related files """"""""""""""""""""""""""""""""""""""""" You may need to access files from one or more locations when writing @@ -5731,8 +5921,7 @@ include test source files or includes them but has no way to build the executables using the installed headers and libraries. In these cases you may need to reference the files relative to one or more root directory. The table below lists relevant path properties and provides additional -examples of their use. -:ref:`Reading expected output ` provides +examples of their use. See :ref:`expected_test_output_from_file` for examples of accessing files saved from the software repository, package repository, and installation. @@ -5761,7 +5950,6 @@ repository, and installation. - ``self.test_suite.current_test_data_dir`` - ``join_path(self.test_suite.current_test_data_dir, "hello.f90")`` - .. _inheriting-tests: """""""""""""""""""""""""""" @@ -5804,7 +5992,7 @@ maintainers provide additional stand-alone tests customized to the package. .. warning:: Any package that implements a test method with the same name as an - inherited method overrides the inherited method. If that is not the + inherited method will override the inherited method. If that is not the goal and you are not explicitly calling and adding functionality to the inherited method for the test, then make sure that all test methods and embedded test parts have unique test names. @@ -5969,6 +6157,8 @@ running: This is already part of the boilerplate for packages created with ``spack create``. +.. _file-filtering: + ^^^^^^^^^^^^^^^^^^^ Filtering functions ^^^^^^^^^^^^^^^^^^^ @@ -6408,9 +6598,12 @@ the ``paths`` attribute: echo "Target: x86_64-pc-linux-gnu" echo "Thread model: posix" echo "InstalledDir: /usr/bin" + platforms: ["linux", "darwin"] results: - spec: 'llvm@3.9.1 +clang~lld~lldb' +If the ``platforms`` attribute is present, tests are run only if the current host +matches one of the listed platforms. Each test is performed by first creating a temporary directory structure as specified in the corresponding ``layout`` and by then running package detection and checking that the outcome matches the expected @@ -6444,6 +6637,10 @@ package detection and checking that the outcome matches the expected - A spec that is expected from detection - Any valid spec - Yes + * - ``results:[0]:extra_attributes`` + - Extra attributes expected on the associated Spec + - Nested dictionary with string as keys, and regular expressions as leaf values + - No """"""""""""""""""""""""""""""" Reuse tests from other packages diff --git a/lib/spack/docs/pipelines.rst b/lib/spack/docs/pipelines.rst index 8aeefd116efc2e..0a72793a891d6b 100644 --- a/lib/spack/docs/pipelines.rst +++ b/lib/spack/docs/pipelines.rst @@ -253,17 +253,6 @@ can easily happen if it is not updated frequently, this behavior ensures that spack has a way to know for certain about the status of any concrete spec on the remote mirror, but can slow down pipeline generation significantly. -The ``--optimize`` argument is experimental and runs the generated pipeline -document through a series of optimization passes designed to reduce the size -of the generated file. - -The ``--dependencies`` is also experimental and disables what in Gitlab is -referred to as DAG scheduling, internally using the ``dependencies`` keyword -rather than ``needs`` to list dependency jobs. The drawback of using this option -is that before any job can begin, all jobs in previous stages must first -complete. The benefit is that Gitlab allows more dependencies to be listed -when using ``dependencies`` instead of ``needs``. - The optional ``--output-file`` argument should be an absolute path (including file name) to the generated pipeline, and if not given, the default is ``./.gitlab-ci.yml``. diff --git a/lib/spack/docs/repositories.rst b/lib/spack/docs/repositories.rst index ae8f2929456ff4..3b20c78bfcc97a 100644 --- a/lib/spack/docs/repositories.rst +++ b/lib/spack/docs/repositories.rst @@ -476,9 +476,3 @@ implemented using Python's built-in `sys.path :py:mod:`spack.repo` module implements a custom `Python importer `_. -.. warning:: - - The mechanism for extending packages is not yet extensively tested, - and extending packages across repositories imposes inter-repo - dependencies, which may be hard to manage. Use this feature at your - own risk, but let us know if you have a use case for it. diff --git a/lib/spack/docs/requirements.txt b/lib/spack/docs/requirements.txt index 457fe02f2b5c45..90cae4526b5f4c 100644 --- a/lib/spack/docs/requirements.txt +++ b/lib/spack/docs/requirements.txt @@ -1,13 +1,13 @@ -sphinx==7.2.6 +sphinx==7.4.7 sphinxcontrib-programoutput==0.17 -sphinx_design==0.5.0 +sphinx_design==0.6.0 sphinx-rtd-theme==2.0.0 -python-levenshtein==0.25.0 +python-levenshtein==0.25.1 docutils==0.20.1 -pygments==2.17.2 -urllib3==2.2.1 -pytest==8.1.1 +pygments==2.18.0 +urllib3==2.2.2 +pytest==8.3.1 isort==5.13.2 -black==24.3.0 -flake8==7.0.0 -mypy==1.9.0 +black==24.4.2 +flake8==7.1.0 +mypy==1.11.0 diff --git a/lib/spack/env/cc b/lib/spack/env/cc index f72a6663a37bb3..ffaa9944df2626 100755 --- a/lib/spack/env/cc +++ b/lib/spack/env/cc @@ -47,7 +47,8 @@ SPACK_F77_RPATH_ARG SPACK_FC_RPATH_ARG SPACK_LINKER_ARG SPACK_SHORT_SPEC -SPACK_SYSTEM_DIRS" +SPACK_SYSTEM_DIRS +SPACK_MANAGED_DIRS" # Optional parameters that aren't required to be set @@ -173,22 +174,6 @@ preextend() { unset IFS } -# system_dir PATH -# test whether a path is a system directory -system_dir() { - IFS=':' # SPACK_SYSTEM_DIRS is colon-separated - path="$1" - for sd in $SPACK_SYSTEM_DIRS; do - if [ "${path}" = "${sd}" ] || [ "${path}" = "${sd}/" ]; then - # success if path starts with a system prefix - unset IFS - return 0 - fi - done - unset IFS - return 1 # fail if path starts no system prefix -} - # Fail with a clear message if the input contains any bell characters. if eval "[ \"\${*#*${lsep}}\" != \"\$*\" ]"; then die "Compiler command line contains our separator ('${lsep}'). Cannot parse." @@ -201,6 +186,18 @@ for param in $params; do fi done +# eval this because SPACK_MANAGED_DIRS and SPACK_SYSTEM_DIRS are inputs we don't wanna loop over. +# moving the eval inside the function would eval it every call. +eval "\ +path_order() { +case \"\$1\" in + $SPACK_MANAGED_DIRS) return 0 ;; + $SPACK_SYSTEM_DIRS) return 2 ;; + /*) return 1 ;; +esac +} +" + # Check if optional parameters are defined # If we aren't asking for debug flags, don't add them if [ -z "${SPACK_ADD_DEBUG_FLAGS:-}" ]; then @@ -248,7 +245,7 @@ case "$command" in lang_flags=C debug_flags="-g" ;; - c++|CC|g++|clang++|armclang++|icpc|icpx|dpcpp|pgc++|nvc++|xlc++|xlc++_r|FCC|amdclang++|crayCC) + c++|CC|g++|clang++|armclang++|icpc|icpx|pgc++|nvc++|xlc++|xlc++_r|FCC|amdclang++|crayCC) command="$SPACK_CXX" language="C++" comp="CXX" @@ -420,11 +417,12 @@ input_command="$*" parse_Wl() { while [ $# -ne 0 ]; do if [ "$wl_expect_rpath" = yes ]; then - if system_dir "$1"; then - append return_system_rpath_dirs_list "$1" - else - append return_rpath_dirs_list "$1" - fi + path_order "$1" + case $? in + 0) append return_spack_store_rpath_dirs_list "$1" ;; + 1) append return_rpath_dirs_list "$1" ;; + 2) append return_system_rpath_dirs_list "$1" ;; + esac wl_expect_rpath=no else case "$1" in @@ -432,21 +430,25 @@ parse_Wl() { arg="${1#-rpath=}" if [ -z "$arg" ]; then shift; continue - elif system_dir "$arg"; then - append return_system_rpath_dirs_list "$arg" - else - append return_rpath_dirs_list "$arg" fi + path_order "$arg" + case $? in + 0) append return_spack_store_rpath_dirs_list "$arg" ;; + 1) append return_rpath_dirs_list "$arg" ;; + 2) append return_system_rpath_dirs_list "$arg" ;; + esac ;; --rpath=*) arg="${1#--rpath=}" if [ -z "$arg" ]; then shift; continue - elif system_dir "$arg"; then - append return_system_rpath_dirs_list "$arg" - else - append return_rpath_dirs_list "$arg" fi + path_order "$arg" + case $? in + 0) append return_spack_store_rpath_dirs_list "$arg" ;; + 1) append return_rpath_dirs_list "$arg" ;; + 2) append return_system_rpath_dirs_list "$arg" ;; + esac ;; -rpath|--rpath) wl_expect_rpath=yes @@ -473,12 +475,20 @@ categorize_arguments() { return_other_args_list="" return_isystem_was_used="" + + return_isystem_spack_store_include_dirs_list="" return_isystem_system_include_dirs_list="" return_isystem_include_dirs_list="" + + return_spack_store_include_dirs_list="" return_system_include_dirs_list="" return_include_dirs_list="" + + return_spack_store_lib_dirs_list="" return_system_lib_dirs_list="" return_lib_dirs_list="" + + return_spack_store_rpath_dirs_list="" return_system_rpath_dirs_list="" return_rpath_dirs_list="" @@ -526,7 +536,7 @@ categorize_arguments() { continue fi - replaced="$after$stripped" + replaced="$after$stripped" # it matched, remove it shift @@ -546,29 +556,32 @@ categorize_arguments() { arg="${1#-isystem}" return_isystem_was_used=true if [ -z "$arg" ]; then shift; arg="$1"; fi - if system_dir "$arg"; then - append return_isystem_system_include_dirs_list "$arg" - else - append return_isystem_include_dirs_list "$arg" - fi + path_order "$arg" + case $? in + 0) append return_isystem_spack_store_include_dirs_list "$arg" ;; + 1) append return_isystem_include_dirs_list "$arg" ;; + 2) append return_isystem_system_include_dirs_list "$arg" ;; + esac ;; -I*) arg="${1#-I}" if [ -z "$arg" ]; then shift; arg="$1"; fi - if system_dir "$arg"; then - append return_system_include_dirs_list "$arg" - else - append return_include_dirs_list "$arg" - fi + path_order "$arg" + case $? in + 0) append return_spack_store_include_dirs_list "$arg" ;; + 1) append return_include_dirs_list "$arg" ;; + 2) append return_system_include_dirs_list "$arg" ;; + esac ;; -L*) arg="${1#-L}" if [ -z "$arg" ]; then shift; arg="$1"; fi - if system_dir "$arg"; then - append return_system_lib_dirs_list "$arg" - else - append return_lib_dirs_list "$arg" - fi + path_order "$arg" + case $? in + 0) append return_spack_store_lib_dirs_list "$arg" ;; + 1) append return_lib_dirs_list "$arg" ;; + 2) append return_system_lib_dirs_list "$arg" ;; + esac ;; -l*) # -loopopt=0 is generated erroneously in autoconf <= 2.69, @@ -601,29 +614,32 @@ categorize_arguments() { break elif [ "$xlinker_expect_rpath" = yes ]; then # Register the path of -Xlinker -rpath -Xlinker - if system_dir "$1"; then - append return_system_rpath_dirs_list "$1" - else - append return_rpath_dirs_list "$1" - fi + path_order "$1" + case $? in + 0) append return_spack_store_rpath_dirs_list "$1" ;; + 1) append return_rpath_dirs_list "$1" ;; + 2) append return_system_rpath_dirs_list "$1" ;; + esac xlinker_expect_rpath=no else case "$1" in -rpath=*) arg="${1#-rpath=}" - if system_dir "$arg"; then - append return_system_rpath_dirs_list "$arg" - else - append return_rpath_dirs_list "$arg" - fi + path_order "$arg" + case $? in + 0) append return_spack_store_rpath_dirs_list "$arg" ;; + 1) append return_rpath_dirs_list "$arg" ;; + 2) append return_system_rpath_dirs_list "$arg" ;; + esac ;; --rpath=*) arg="${1#--rpath=}" - if system_dir "$arg"; then - append return_system_rpath_dirs_list "$arg" - else - append return_rpath_dirs_list "$arg" - fi + path_order "$arg" + case $? in + 0) append return_spack_store_rpath_dirs_list "$arg" ;; + 1) append return_rpath_dirs_list "$arg" ;; + 2) append return_system_rpath_dirs_list "$arg" ;; + esac ;; -rpath|--rpath) xlinker_expect_rpath=yes @@ -661,16 +677,25 @@ categorize_arguments() { } categorize_arguments "$@" - include_dirs_list="$return_include_dirs_list" - lib_dirs_list="$return_lib_dirs_list" - rpath_dirs_list="$return_rpath_dirs_list" - system_include_dirs_list="$return_system_include_dirs_list" - system_lib_dirs_list="$return_system_lib_dirs_list" - system_rpath_dirs_list="$return_system_rpath_dirs_list" - isystem_was_used="$return_isystem_was_used" - isystem_system_include_dirs_list="$return_isystem_system_include_dirs_list" - isystem_include_dirs_list="$return_isystem_include_dirs_list" - other_args_list="$return_other_args_list" + +spack_store_include_dirs_list="$return_spack_store_include_dirs_list" +system_include_dirs_list="$return_system_include_dirs_list" +include_dirs_list="$return_include_dirs_list" + +spack_store_lib_dirs_list="$return_spack_store_lib_dirs_list" +system_lib_dirs_list="$return_system_lib_dirs_list" +lib_dirs_list="$return_lib_dirs_list" + +spack_store_rpath_dirs_list="$return_spack_store_rpath_dirs_list" +system_rpath_dirs_list="$return_system_rpath_dirs_list" +rpath_dirs_list="$return_rpath_dirs_list" + +isystem_spack_store_include_dirs_list="$return_isystem_spack_store_include_dirs_list" +isystem_system_include_dirs_list="$return_isystem_system_include_dirs_list" +isystem_include_dirs_list="$return_isystem_include_dirs_list" + +isystem_was_used="$return_isystem_was_used" +other_args_list="$return_other_args_list" # # Add flags from Spack's cppflags, cflags, cxxflags, fcflags, fflags, and @@ -730,7 +755,7 @@ esac # Linker flags case "$mode" in - ld|ccld) + ccld) extend spack_flags_list SPACK_LDFLAGS ;; esac @@ -738,16 +763,25 @@ esac IFS="$lsep" categorize_arguments $spack_flags_list unset IFS - spack_flags_include_dirs_list="$return_include_dirs_list" - spack_flags_lib_dirs_list="$return_lib_dirs_list" - spack_flags_rpath_dirs_list="$return_rpath_dirs_list" - spack_flags_system_include_dirs_list="$return_system_include_dirs_list" - spack_flags_system_lib_dirs_list="$return_system_lib_dirs_list" - spack_flags_system_rpath_dirs_list="$return_system_rpath_dirs_list" - spack_flags_isystem_was_used="$return_isystem_was_used" - spack_flags_isystem_system_include_dirs_list="$return_isystem_system_include_dirs_list" - spack_flags_isystem_include_dirs_list="$return_isystem_include_dirs_list" - spack_flags_other_args_list="$return_other_args_list" + +spack_flags_isystem_spack_store_include_dirs_list="$return_isystem_spack_store_include_dirs_list" +spack_flags_isystem_system_include_dirs_list="$return_isystem_system_include_dirs_list" +spack_flags_isystem_include_dirs_list="$return_isystem_include_dirs_list" + +spack_flags_spack_store_include_dirs_list="$return_spack_store_include_dirs_list" +spack_flags_system_include_dirs_list="$return_system_include_dirs_list" +spack_flags_include_dirs_list="$return_include_dirs_list" + +spack_flags_spack_store_lib_dirs_list="$return_spack_store_lib_dirs_list" +spack_flags_system_lib_dirs_list="$return_system_lib_dirs_list" +spack_flags_lib_dirs_list="$return_lib_dirs_list" + +spack_flags_spack_store_rpath_dirs_list="$return_spack_store_rpath_dirs_list" +spack_flags_system_rpath_dirs_list="$return_system_rpath_dirs_list" +spack_flags_rpath_dirs_list="$return_rpath_dirs_list" + +spack_flags_isystem_was_used="$return_isystem_was_used" +spack_flags_other_args_list="$return_other_args_list" # On macOS insert headerpad_max_install_names linker flag @@ -767,11 +801,13 @@ if [ "$mode" = ccld ] || [ "$mode" = ld ]; then # Append RPATH directories. Note that in the case of the # top-level package these directories may not exist yet. For dependencies # it is assumed that paths have already been confirmed. + extend spack_store_rpath_dirs_list SPACK_STORE_RPATH_DIRS extend rpath_dirs_list SPACK_RPATH_DIRS fi fi if [ "$mode" = ccld ] || [ "$mode" = ld ]; then + extend spack_store_lib_dirs_list SPACK_STORE_LINK_DIRS extend lib_dirs_list SPACK_LINK_DIRS fi @@ -798,38 +834,50 @@ case "$mode" in ;; esac +case "$mode" in + cpp|cc|as|ccld) + if [ "$spack_flags_isystem_was_used" = "true" ] || [ "$isystem_was_used" = "true" ]; then + extend isystem_spack_store_include_dirs_list SPACK_STORE_INCLUDE_DIRS + extend isystem_include_dirs_list SPACK_INCLUDE_DIRS + else + extend spack_store_include_dirs_list SPACK_STORE_INCLUDE_DIRS + extend include_dirs_list SPACK_INCLUDE_DIRS + fi + ;; +esac + # # Finally, reassemble the command line. # args_list="$flags_list" -# Insert include directories just prior to any system include directories +# Include search paths partitioned by (in store, non-sytem, system) # NOTE: adding ${lsep} to the prefix here turns every added element into two -extend args_list spack_flags_include_dirs_list "-I" -extend args_list include_dirs_list "-I" +extend args_list spack_flags_spack_store_include_dirs_list -I +extend args_list spack_store_include_dirs_list -I + +extend args_list spack_flags_include_dirs_list -I +extend args_list include_dirs_list -I + +extend args_list spack_flags_isystem_spack_store_include_dirs_list "-isystem${lsep}" +extend args_list isystem_spack_store_include_dirs_list "-isystem${lsep}" + extend args_list spack_flags_isystem_include_dirs_list "-isystem${lsep}" extend args_list isystem_include_dirs_list "-isystem${lsep}" -case "$mode" in - cpp|cc|as|ccld) - if [ "$spack_flags_isystem_was_used" = "true" ]; then - extend args_list SPACK_INCLUDE_DIRS "-isystem${lsep}" - elif [ "$isystem_was_used" = "true" ]; then - extend args_list SPACK_INCLUDE_DIRS "-isystem${lsep}" - else - extend args_list SPACK_INCLUDE_DIRS "-I" - fi - ;; -esac - extend args_list spack_flags_system_include_dirs_list -I extend args_list system_include_dirs_list -I + extend args_list spack_flags_isystem_system_include_dirs_list "-isystem${lsep}" extend args_list isystem_system_include_dirs_list "-isystem${lsep}" -# Library search paths +# Library search paths partitioned by (in store, non-sytem, system) +extend args_list spack_flags_spack_store_lib_dirs_list "-L" +extend args_list spack_store_lib_dirs_list "-L" + extend args_list spack_flags_lib_dirs_list "-L" extend args_list lib_dirs_list "-L" + extend args_list spack_flags_system_lib_dirs_list "-L" extend args_list system_lib_dirs_list "-L" @@ -839,8 +887,12 @@ case "$mode" in if [ -n "$dtags_to_add" ] ; then append args_list "$linker_arg$dtags_to_add" fi + extend args_list spack_flags_spack_store_rpath_dirs_list "$rpath" + extend args_list spack_store_rpath_dirs_list "$rpath" + extend args_list spack_flags_rpath_dirs_list "$rpath" extend args_list rpath_dirs_list "$rpath" + extend args_list spack_flags_system_rpath_dirs_list "$rpath" extend args_list system_rpath_dirs_list "$rpath" ;; @@ -848,8 +900,12 @@ case "$mode" in if [ -n "$dtags_to_add" ] ; then append args_list "$dtags_to_add" fi + extend args_list spack_flags_spack_store_rpath_dirs_list "-rpath${lsep}" + extend args_list spack_store_rpath_dirs_list "-rpath${lsep}" + extend args_list spack_flags_rpath_dirs_list "-rpath${lsep}" extend args_list rpath_dirs_list "-rpath${lsep}" + extend args_list spack_flags_system_rpath_dirs_list "-rpath${lsep}" extend args_list system_rpath_dirs_list "-rpath${lsep}" ;; @@ -913,4 +969,3 @@ fi # Execute the full command, preserving spaces with IFS set # to the alarm bell separator. IFS="$lsep"; exec $full_command_list - diff --git a/lib/spack/external/__init__.py b/lib/spack/external/__init__.py index 2d96eb3c96bdcf..26ac1f63d00080 100644 --- a/lib/spack/external/__init__.py +++ b/lib/spack/external/__init__.py @@ -18,7 +18,7 @@ * Homepage: https://pypi.python.org/pypi/archspec * Usage: Labeling, comparison and detection of microarchitectures -* Version: 0.2.3 (commit 7b8fe60b69e2861e7dac104bc1c183decfcd3daf) +* Version: 0.2.4 (commit 48b92512b9ce203ded0ebd1ac41b42593e931f7c) astunparse ---------------- diff --git a/lib/spack/external/_vendoring/ruamel/yaml/comments.py b/lib/spack/external/_vendoring/ruamel/yaml/comments.py index 892c868af30bad..1badeda585d729 100644 --- a/lib/spack/external/_vendoring/ruamel/yaml/comments.py +++ b/lib/spack/external/_vendoring/ruamel/yaml/comments.py @@ -497,7 +497,7 @@ def copy_attributes(self, t, memo=None): Tag.attrib, merge_attrib]: if hasattr(self, a): if memo is not None: - setattr(t, a, copy.deepcopy(getattr(self, a, memo))) + setattr(t, a, copy.deepcopy(getattr(self, a), memo)) else: setattr(t, a, getattr(self, a)) # fmt: on diff --git a/lib/spack/external/archspec/__init__.py b/lib/spack/external/archspec/__init__.py index 7568bbd0e90936..2930ad719e4b31 100644 --- a/lib/spack/external/archspec/__init__.py +++ b/lib/spack/external/archspec/__init__.py @@ -1,3 +1,3 @@ """Init file to avoid namespace packages""" -__version__ = "0.2.3" +__version__ = "0.2.4" diff --git a/lib/spack/external/archspec/cpu/__init__.py b/lib/spack/external/archspec/cpu/__init__.py index 5fa60d28748c07..6fbb43b785db83 100644 --- a/lib/spack/external/archspec/cpu/__init__.py +++ b/lib/spack/external/archspec/cpu/__init__.py @@ -5,9 +5,10 @@ """The "cpu" package permits to query and compare different CPU microarchitectures. """ -from .detect import host +from .detect import brand_string, host from .microarchitecture import ( TARGETS, + InvalidCompilerVersion, Microarchitecture, UnsupportedMicroarchitecture, generic_microarchitecture, @@ -15,10 +16,12 @@ ) __all__ = [ + "brand_string", + "host", + "TARGETS", + "InvalidCompilerVersion", "Microarchitecture", "UnsupportedMicroarchitecture", - "TARGETS", "generic_microarchitecture", - "host", "version_components", ] diff --git a/lib/spack/external/archspec/cpu/detect.py b/lib/spack/external/archspec/cpu/detect.py index 179b7a947b1983..d99295d90719bd 100644 --- a/lib/spack/external/archspec/cpu/detect.py +++ b/lib/spack/external/archspec/cpu/detect.py @@ -155,6 +155,31 @@ def _is_bit_set(self, register: int, bit: int) -> bool: mask = 1 << bit return register & mask > 0 + def brand_string(self) -> Optional[str]: + """Returns the brand string, if available.""" + if self.highest_extension_support < 0x80000004: + return None + + r1 = self.cpuid.registers_for(eax=0x80000002, ecx=0) + r2 = self.cpuid.registers_for(eax=0x80000003, ecx=0) + r3 = self.cpuid.registers_for(eax=0x80000004, ecx=0) + result = struct.pack( + "IIIIIIIIIIII", + r1.eax, + r1.ebx, + r1.ecx, + r1.edx, + r2.eax, + r2.ebx, + r2.ecx, + r2.edx, + r3.eax, + r3.ebx, + r3.ecx, + r3.edx, + ).decode("utf-8") + return result.strip("\x00") + @detection(operating_system="Windows") def cpuid_info(): @@ -174,8 +199,8 @@ def _check_output(args, env): WINDOWS_MAPPING = { - "AMD64": "x86_64", - "ARM64": "aarch64", + "AMD64": X86_64, + "ARM64": AARCH64, } @@ -409,3 +434,16 @@ def compatibility_check_for_riscv64(info, target): return (target == arch_root or arch_root in target.ancestors) and ( target.name == info.name or target.vendor == "generic" ) + + +def brand_string() -> Optional[str]: + """Returns the brand string of the host, if detected, or None.""" + if platform.system() == "Darwin": + return _check_output( + ["sysctl", "-n", "machdep.cpu.brand_string"], env=_ensure_bin_usrbin_in_path() + ).strip() + + if host().family == X86_64: + return CpuidInfoCollector().brand_string() + + return None diff --git a/lib/spack/external/archspec/cpu/microarchitecture.py b/lib/spack/external/archspec/cpu/microarchitecture.py index a6526aa9266c3d..7a251b905e26bf 100644 --- a/lib/spack/external/archspec/cpu/microarchitecture.py +++ b/lib/spack/external/archspec/cpu/microarchitecture.py @@ -208,6 +208,8 @@ def optimization_flags(self, compiler, version): """Returns a string containing the optimization flags that needs to be used to produce code optimized for this micro-architecture. + The version is expected to be a string of dot separated digits. + If there is no information on the compiler passed as argument the function returns an empty string. If it is known that the compiler version we want to use does not support this architecture the function @@ -216,6 +218,11 @@ def optimization_flags(self, compiler, version): Args: compiler (str): name of the compiler to be used version (str): version of the compiler to be used + + Raises: + UnsupportedMicroarchitecture: if the requested compiler does not support + this micro-architecture. + ValueError: if the version doesn't match the expected format """ # If we don't have information on compiler at all return an empty string if compiler not in self.family.compilers: @@ -232,6 +239,14 @@ def optimization_flags(self, compiler, version): msg = msg.format(compiler, best_target, best_target.family) raise UnsupportedMicroarchitecture(msg) + # Check that the version matches the expected format + if not re.match(r"^(?:\d+\.)*\d+$", version): + msg = ( + "invalid format for the compiler version argument. " + "Only dot separated digits are allowed." + ) + raise InvalidCompilerVersion(msg) + # If we have information on this compiler we need to check the # version being used compiler_info = self.compilers[compiler] @@ -292,7 +307,7 @@ def generic_microarchitecture(name): Args: name (str): name of the micro-architecture """ - return Microarchitecture(name, parents=[], vendor="generic", features=[], compilers={}) + return Microarchitecture(name, parents=[], vendor="generic", features=set(), compilers={}) def version_components(version): @@ -367,7 +382,15 @@ def fill_target_from_dict(name, data, targets): TARGETS = LazyDictionary(_known_microarchitectures) -class UnsupportedMicroarchitecture(ValueError): +class ArchspecError(Exception): + """Base class for errors within archspec""" + + +class UnsupportedMicroarchitecture(ArchspecError, ValueError): """Raised if a compiler version does not support optimization for a given micro-architecture. """ + + +class InvalidCompilerVersion(ArchspecError, ValueError): + """Raised when an invalid format is used for compiler versions in archspec.""" diff --git a/lib/spack/external/archspec/json/cpu/microarchitectures.json b/lib/spack/external/archspec/json/cpu/microarchitectures.json index 1e77caba4aea00..1e8a8caa35ca77 100644 --- a/lib/spack/external/archspec/json/cpu/microarchitectures.json +++ b/lib/spack/external/archspec/json/cpu/microarchitectures.json @@ -2937,8 +2937,6 @@ "ilrcpc", "flagm", "ssbs", - "paca", - "pacg", "dcpodp", "svei8mm", "svebf16", @@ -3066,8 +3064,6 @@ "flagm", "ssbs", "sb", - "paca", - "pacg", "dcpodp", "sve2", "sveaes", @@ -3081,8 +3077,7 @@ "svebf16", "i8mm", "bf16", - "dgh", - "bti" + "dgh" ], "compilers" : { "gcc": [ diff --git a/lib/spack/external/patches/ruamelyaml.patch b/lib/spack/external/patches/ruamelyaml.patch new file mode 100644 index 00000000000000..24bf17f233d5f7 --- /dev/null +++ b/lib/spack/external/patches/ruamelyaml.patch @@ -0,0 +1,13 @@ +diff --git a/lib/spack/external/_vendoring/ruamel/yaml/comments.py b/lib/spack/external/_vendoring/ruamel/yaml/comments.py +index 1badeda585..892c868af3 100644 +--- a/lib/spack/external/_vendoring/ruamel/yaml/comments.py ++++ b/lib/spack/external/_vendoring/ruamel/yaml/comments.py +@@ -497,7 +497,7 @@ def copy_attributes(self, t, memo=None): + Tag.attrib, merge_attrib]: + if hasattr(self, a): + if memo is not None: +- setattr(t, a, copy.deepcopy(getattr(self, a, memo))) ++ setattr(t, a, copy.deepcopy(getattr(self, a), memo)) + else: + setattr(t, a, getattr(self, a)) + # fmt: on diff --git a/lib/spack/llnl/path.py b/lib/spack/llnl/path.py index 9ef90eec4c03e5..4c5da8472d2710 100644 --- a/lib/spack/llnl/path.py +++ b/lib/spack/llnl/path.py @@ -98,3 +98,10 @@ def path_filter_caller(*args, **kwargs): if _func: return holder_func(_func) return holder_func + + +def sanitize_win_longpath(path: str) -> str: + """Strip Windows extended path prefix from strings + Returns sanitized string. + no-op if extended path prefix is not present""" + return path.lstrip("\\\\?\\") diff --git a/lib/spack/llnl/url.py b/lib/spack/llnl/url.py index 28f3187dd9b459..92acfed38da3ef 100644 --- a/lib/spack/llnl/url.py +++ b/lib/spack/llnl/url.py @@ -12,7 +12,7 @@ # Archive extensions allowed in Spack PREFIX_EXTENSIONS = ("tar", "TAR") EXTENSIONS = ("gz", "bz2", "xz", "Z") -NO_TAR_EXTENSIONS = ("zip", "tgz", "tbz2", "tbz", "txz") +NO_TAR_EXTENSIONS = ("zip", "tgz", "tbz2", "tbz", "txz", "whl") # Add PREFIX_EXTENSIONS and EXTENSIONS last so that .tar.gz is matched *before* .tar or .gz ALLOWED_ARCHIVE_TYPES = ( @@ -357,10 +357,8 @@ def strip_version_suffixes(path_or_url: str) -> str: r"i[36]86", r"ppc64(le)?", r"armv?(7l|6l|64)?", - # PyPI - r"[._-]py[23].*\.whl", - r"[._-]cp[23].*\.whl", - r"[._-]win.*\.exe", + # PyPI wheels + r"-(?:py|cp)[23].*", ] for regex in suffix_regexes: @@ -403,7 +401,7 @@ def expand_contracted_extension_in_path( def compression_ext_from_compressed_archive(extension: str) -> Optional[str]: """Returns compression extension for a compressed archive""" extension = expand_contracted_extension(extension) - for ext in [*EXTENSIONS]: + for ext in EXTENSIONS: if ext in extension: return ext return None diff --git a/lib/spack/llnl/util/filesystem.py b/lib/spack/llnl/util/filesystem.py index 390d1f651e9a5f..6b2ba50c0ec206 100644 --- a/lib/spack/llnl/util/filesystem.py +++ b/lib/spack/llnl/util/filesystem.py @@ -187,26 +187,58 @@ def polite_filename(filename: str) -> str: return _polite_antipattern().sub("_", filename) -def getuid(): +def getuid() -> Union[str, int]: + """Returns os getuid on non Windows + On Windows returns 0 for admin users, login string otherwise + This is in line with behavior from get_owner_uid which + always returns the login string on Windows + """ if sys.platform == "win32": import ctypes + # If not admin, use the string name of the login as a unique ID if ctypes.windll.shell32.IsUserAnAdmin() == 0: - return 1 + return os.getlogin() return 0 else: return os.getuid() +def _win_rename(src, dst): + # os.replace will still fail if on Windows (but not POSIX) if the dst + # is a symlink to a directory (all other cases have parity Windows <-> Posix) + if os.path.islink(dst) and os.path.isdir(os.path.realpath(dst)): + if os.path.samefile(src, dst): + # src and dst are the same + # do nothing and exit early + return + # If dst exists and is a symlink to a directory + # we need to remove dst and then perform rename/replace + # this is safe to do as there's no chance src == dst now + os.remove(dst) + os.replace(src, dst) + + +@system_path_filter +def msdos_escape_parens(path): + """MS-DOS interprets parens as grouping parameters even in a quoted string""" + if sys.platform == "win32": + return path.replace("(", "^(").replace(")", "^)") + else: + return path + + @system_path_filter def rename(src, dst): # On Windows, os.rename will fail if the destination file already exists + # os.replace is the same as os.rename on POSIX and is MoveFileExW w/ + # the MOVEFILE_REPLACE_EXISTING flag on Windows + # Windows invocation is abstracted behind additonal logic handling + # remaining cases of divergent behavior accross platforms if sys.platform == "win32": - # Windows path existence checks will sometimes fail on junctions/links/symlinks - # so check for that case - if os.path.exists(dst) or islink(dst): - os.remove(dst) - os.rename(src, dst) + _win_rename(src, dst) + else: + os.replace(src, dst) @system_path_filter @@ -536,7 +568,13 @@ def exploding_archive_handler(tarball_container, stage): @system_path_filter(arg_slice=slice(1)) -def get_owner_uid(path, err_msg=None): +def get_owner_uid(path, err_msg=None) -> Union[str, int]: + """Returns owner UID of path destination + On non Windows this is the value of st_uid + On Windows this is the login string associated with the + owning user. + + """ if not os.path.exists(path): mkdirp(path, mode=stat.S_IRWXU) @@ -728,7 +766,6 @@ def copy_tree( src: str, dest: str, symlinks: bool = True, - allow_broken_symlinks: bool = sys.platform != "win32", ignore: Optional[Callable[[str], bool]] = None, _permissions: bool = False, ): @@ -751,8 +788,6 @@ def copy_tree( src (str): the directory to copy dest (str): the destination directory symlinks (bool): whether or not to preserve symlinks - allow_broken_symlinks (bool): whether or not to allow broken (dangling) symlinks, - On Windows, setting this to True will raise an exception. Defaults to true on unix. ignore (typing.Callable): function indicating which files to ignore _permissions (bool): for internal use only @@ -760,8 +795,6 @@ def copy_tree( IOError: if *src* does not match any files or directories ValueError: if *src* is a parent directory of *dest* """ - if allow_broken_symlinks and sys.platform == "win32": - raise llnl.util.symlink.SymlinkError("Cannot allow broken symlinks on Windows!") if _permissions: tty.debug("Installing {0} to {1}".format(src, dest)) else: @@ -805,7 +838,7 @@ def copy_tree( if islink(s): link_target = resolve_link_target_relative_to_the_link(s) if symlinks: - target = os.readlink(s) + target = readlink(s) if os.path.isabs(target): def escaped_path(path): @@ -834,16 +867,14 @@ def escaped_path(path): copy_mode(s, d) for target, d, s in links: - symlink(target, d, allow_broken_symlinks=allow_broken_symlinks) + symlink(target, d) if _permissions: set_install_permissions(d) copy_mode(s, d) @system_path_filter -def install_tree( - src, dest, symlinks=True, ignore=None, allow_broken_symlinks=sys.platform != "win32" -): +def install_tree(src, dest, symlinks=True, ignore=None): """Recursively install an entire directory tree rooted at *src*. Same as :py:func:`copy_tree` with the addition of setting proper @@ -854,21 +885,12 @@ def install_tree( dest (str): the destination directory symlinks (bool): whether or not to preserve symlinks ignore (typing.Callable): function indicating which files to ignore - allow_broken_symlinks (bool): whether or not to allow broken (dangling) symlinks, - On Windows, setting this to True will raise an exception. Raises: IOError: if *src* does not match any files or directories ValueError: if *src* is a parent directory of *dest* """ - copy_tree( - src, - dest, - symlinks=symlinks, - allow_broken_symlinks=allow_broken_symlinks, - ignore=ignore, - _permissions=True, - ) + copy_tree(src, dest, symlinks=symlinks, ignore=ignore, _permissions=True) @system_path_filter @@ -1217,10 +1239,12 @@ def windows_sfn(path: os.PathLike): import ctypes k32 = ctypes.WinDLL("kernel32", use_last_error=True) + # Method with null values returns size of short path name + sz = k32.GetShortPathNameW(path, None, 0) # stub Windows types TCHAR[LENGTH] - TCHAR_arr = ctypes.c_wchar * len(path) + TCHAR_arr = ctypes.c_wchar * sz ret_str = TCHAR_arr() - k32.GetShortPathNameW(path, ret_str, len(path)) + k32.GetShortPathNameW(path, ctypes.byref(ret_str), sz) return ret_str.value @@ -2410,9 +2434,10 @@ def add_library_dependent(self, *dest): """ for pth in dest: if os.path.isfile(pth): - self._additional_library_dependents.add(pathlib.Path(pth).parent) + new_pth = pathlib.Path(pth).parent else: - self._additional_library_dependents.add(pathlib.Path(pth)) + new_pth = pathlib.Path(pth) + self._additional_library_dependents.add(new_pth) @property def rpaths(self): @@ -2490,8 +2515,14 @@ def establish_link(self): # for each binary install dir in self.pkg (i.e. pkg.prefix.bin, pkg.prefix.lib) # install a symlink to each dependent library - for library, lib_dir in itertools.product(self.rpaths, self.library_dependents): - self._link(library, lib_dir) + + # do not rpath for system libraries included in the dag + # we should not be modifying libraries managed by the Windows system + # as this will negatively impact linker behavior and can result in permission + # errors if those system libs are not modifiable by Spack + if "windows-system" not in getattr(self.pkg, "tags", []): + for library, lib_dir in itertools.product(self.rpaths, self.library_dependents): + self._link(library, lib_dir) @system_path_filter diff --git a/lib/spack/llnl/util/symlink.py b/lib/spack/llnl/util/symlink.py index ec45787a96668a..be758c4d132866 100644 --- a/lib/spack/llnl/util/symlink.py +++ b/lib/spack/llnl/util/symlink.py @@ -8,100 +8,75 @@ import subprocess import sys import tempfile +from typing import Union from llnl.util import lang, tty -from ..path import system_path_filter +from ..path import sanitize_win_longpath, system_path_filter if sys.platform == "win32": from win32file import CreateHardLink -is_windows = sys.platform == "win32" +def _windows_symlink( + src: str, dst: str, target_is_directory: bool = False, *, dir_fd: Union[int, None] = None +): + """On Windows with System Administrator privileges this will be a normal symbolic link via + os.symlink. On Windows without privledges the link will be a junction for a directory and a + hardlink for a file. On Windows the various link types are: -def symlink(source_path: str, link_path: str, allow_broken_symlinks: bool = not is_windows): - """ - Create a link. - - On non-Windows and Windows with System Administrator - privleges this will be a normal symbolic link via - os.symlink. - - On Windows without privledges the link will be a - junction for a directory and a hardlink for a file. - On Windows the various link types are: - - Symbolic Link: A link to a file or directory on the - same or different volume (drive letter) or even to - a remote file or directory (using UNC in its path). - Need System Administrator privileges to make these. - - Hard Link: A link to a file on the same volume (drive - letter) only. Every file (file's data) has at least 1 - hard link (file's name). But when this method creates - a new hard link there will be 2. Deleting all hard - links effectively deletes the file. Don't need System - Administrator privileges. - - Junction: A link to a directory on the same or different - volume (drive letter) but not to a remote directory. Don't - need System Administrator privileges. - - Parameters: - source_path (str): The real file or directory that the link points to. - Must be absolute OR relative to the link. - link_path (str): The path where the link will exist. - allow_broken_symlinks (bool): On Linux or Mac, don't raise an exception if the source_path - doesn't exist. This will still raise an exception on Windows. - """ - source_path = os.path.normpath(source_path) - win_source_path = source_path - link_path = os.path.normpath(link_path) + Symbolic Link: A link to a file or directory on the same or different volume (drive letter) or + even to a remote file or directory (using UNC in its path). Need System Administrator + privileges to make these. - # Never allow broken links on Windows. - if sys.platform == "win32" and allow_broken_symlinks: - raise ValueError("allow_broken_symlinks parameter cannot be True on Windows.") + Hard Link: A link to a file on the same volume (drive letter) only. Every file (file's data) + has at least 1 hard link (file's name). But when this method creates a new hard link there will + be 2. Deleting all hard links effectively deletes the file. Don't need System Administrator + privileges. - if not allow_broken_symlinks: - # Perform basic checks to make sure symlinking will succeed - if os.path.lexists(link_path): - raise AlreadyExistsError( - f"Link path ({link_path}) already exists. Cannot create link." + Junction: A link to a directory on the same or different volume (drive letter) but not to a + remote directory. Don't need System Administrator privileges.""" + source_path = os.path.normpath(src) + win_source_path = source_path + link_path = os.path.normpath(dst) + + # Perform basic checks to make sure symlinking will succeed + if os.path.lexists(link_path): + raise AlreadyExistsError(f"Link path ({link_path}) already exists. Cannot create link.") + + if not os.path.exists(source_path): + if os.path.isabs(source_path): + # An absolute source path that does not exist will result in a broken link. + raise SymlinkError( + f"Source path ({source_path}) is absolute but does not exist. Resulting " + f"link would be broken so not making link." ) - - if not os.path.exists(source_path): - if os.path.isabs(source_path) and not allow_broken_symlinks: - # An absolute source path that does not exist will result in a broken link. + else: + # os.symlink can create a link when the given source path is relative to + # the link path. Emulate this behavior and check to see if the source exists + # relative to the link path ahead of link creation to prevent broken + # links from being made. + link_parent_dir = os.path.dirname(link_path) + relative_path = os.path.join(link_parent_dir, source_path) + if os.path.exists(relative_path): + # In order to work on windows, the source path needs to be modified to be + # relative because hardlink/junction dont resolve relative paths the same + # way as os.symlink. This is ignored on other operating systems. + win_source_path = relative_path + else: raise SymlinkError( - f"Source path ({source_path}) is absolute but does not exist. Resulting " - f"link would be broken so not making link." + f"The source path ({source_path}) is not relative to the link path " + f"({link_path}). Resulting link would be broken so not making link." ) - else: - # os.symlink can create a link when the given source path is relative to - # the link path. Emulate this behavior and check to see if the source exists - # relative to the link path ahead of link creation to prevent broken - # links from being made. - link_parent_dir = os.path.dirname(link_path) - relative_path = os.path.join(link_parent_dir, source_path) - if os.path.exists(relative_path): - # In order to work on windows, the source path needs to be modified to be - # relative because hardlink/junction dont resolve relative paths the same - # way as os.symlink. This is ignored on other operating systems. - win_source_path = relative_path - elif not allow_broken_symlinks: - raise SymlinkError( - f"The source path ({source_path}) is not relative to the link path " - f"({link_path}). Resulting link would be broken so not making link." - ) # Create the symlink - if sys.platform == "win32" and not _windows_can_symlink(): + if not _windows_can_symlink(): _windows_create_link(win_source_path, link_path) else: os.symlink(source_path, link_path, target_is_directory=os.path.isdir(source_path)) -def islink(path: str) -> bool: +def _windows_islink(path: str) -> bool: """Override os.islink to give correct answer for spack logic. For Non-Windows: a link can be determined with the os.path.islink method. @@ -247,9 +222,9 @@ def _windows_create_junction(source: str, link: str): out, err = proc.communicate() tty.debug(out.decode()) if proc.returncode != 0: - err = err.decode() - tty.error(err) - raise SymlinkError("Make junction command returned a non-zero return code.", err) + err_str = err.decode() + tty.error(err_str) + raise SymlinkError("Make junction command returned a non-zero return code.", err_str) def _windows_create_hard_link(path: str, link: str): @@ -269,14 +244,14 @@ def _windows_create_hard_link(path: str, link: str): CreateHardLink(link, path) -def readlink(path: str): +def _windows_readlink(path: str, *, dir_fd=None): """Spack utility to override of os.readlink method to work cross platform""" if _windows_is_hardlink(path): return _windows_read_hard_link(path) elif _windows_is_junction(path): return _windows_read_junction(path) else: - return os.readlink(path) + return sanitize_win_longpath(os.readlink(path, dir_fd=dir_fd)) def _windows_read_hard_link(link: str) -> str: @@ -338,6 +313,16 @@ def resolve_link_target_relative_to_the_link(link): return os.path.join(link_dir, target) +if sys.platform == "win32": + symlink = _windows_symlink + readlink = _windows_readlink + islink = _windows_islink +else: + symlink = os.symlink + readlink = os.readlink + islink = os.path.islink + + class SymlinkError(RuntimeError): """Exception class for errors raised while creating symlinks, junctions and hard links diff --git a/lib/spack/llnl/util/tty/__init__.py b/lib/spack/llnl/util/tty/__init__.py index 3f3ba1d4624e54..807e50a159335a 100644 --- a/lib/spack/llnl/util/tty/__init__.py +++ b/lib/spack/llnl/util/tty/__init__.py @@ -12,7 +12,7 @@ import traceback from datetime import datetime from sys import platform as _platform -from typing import NoReturn +from typing import Any, NoReturn if _platform != "win32": import fcntl @@ -158,21 +158,22 @@ def get_timestamp(force=False): return "" -def msg(message, *args, **kwargs): +def msg(message: Any, *args: Any, newline: bool = True) -> None: if not msg_enabled(): return if isinstance(message, Exception): - message = "%s: %s" % (message.__class__.__name__, str(message)) + message = f"{message.__class__.__name__}: {message}" + else: + message = str(message) - newline = kwargs.get("newline", True) st_text = "" if _stacktrace: st_text = process_stacktrace(2) - if newline: - cprint("@*b{%s==>} %s%s" % (st_text, get_timestamp(), cescape(_output_filter(message)))) - else: - cwrite("@*b{%s==>} %s%s" % (st_text, get_timestamp(), cescape(_output_filter(message)))) + + nl = "\n" if newline else "" + cwrite(f"@*b{{{st_text}==>}} {get_timestamp()}{cescape(_output_filter(message))}{nl}") + for arg in args: print(indent + _output_filter(str(arg))) diff --git a/lib/spack/llnl/util/tty/colify.py b/lib/spack/llnl/util/tty/colify.py index 719b480e4a0827..a40b8fb1166af4 100644 --- a/lib/spack/llnl/util/tty/colify.py +++ b/lib/spack/llnl/util/tty/colify.py @@ -237,7 +237,6 @@ def transpose(): def colified( elts: List[Any], cols: int = 0, - output: Optional[IO] = None, indent: int = 0, padding: int = 2, tty: Optional[bool] = None, diff --git a/lib/spack/llnl/util/tty/color.py b/lib/spack/llnl/util/tty/color.py index bef7af8e58d968..710196783d57e6 100644 --- a/lib/spack/llnl/util/tty/color.py +++ b/lib/spack/llnl/util/tty/color.py @@ -59,9 +59,11 @@ To output an @, use '@@'. To output a } inside braces, use '}}'. """ +import os import re import sys from contextlib import contextmanager +from typing import Optional class ColorParseError(Exception): @@ -95,14 +97,34 @@ def __init__(self, message): } # white # Regex to be used for color formatting -color_re = r"@(?:@|\.|([*_])?([a-zA-Z])?(?:{((?:[^}]|}})*)})?)" +COLOR_RE = re.compile(r"@(?:(@)|(\.)|([*_])?([a-zA-Z])?(?:{((?:[^}]|}})*)})?)") # Mapping from color arguments to values for tty.set_color color_when_values = {"always": True, "auto": None, "never": False} -# Force color; None: Only color if stdout is a tty -# True: Always colorize output, False: Never colorize output -_force_color = None + +def _color_when_value(when): + """Raise a ValueError for an invalid color setting. + + Valid values are 'always', 'never', and 'auto', or equivalently, + True, False, and None. + """ + if when in color_when_values: + return color_when_values[when] + elif when not in color_when_values.values(): + raise ValueError("Invalid color setting: %s" % when) + return when + + +def _color_from_environ() -> Optional[bool]: + try: + return _color_when_value(os.environ.get("SPACK_COLOR", "auto")) + except ValueError: + return None + + +#: When `None` colorize when stdout is tty, when `True` or `False` always or never colorize resp. +_force_color = _color_from_environ() def try_enable_terminal_color_on_windows(): @@ -163,19 +185,6 @@ def _err_check(result, func, args): debug("Unable to support color on Windows terminal") -def _color_when_value(when): - """Raise a ValueError for an invalid color setting. - - Valid values are 'always', 'never', and 'auto', or equivalently, - True, False, and None. - """ - if when in color_when_values: - return color_when_values[when] - elif when not in color_when_values.values(): - raise ValueError("Invalid color setting: %s" % when) - return when - - def get_color_when(): """Return whether commands should print color or not.""" if _force_color is not None: @@ -203,77 +212,64 @@ def color_when(value): set_color_when(old_value) -class match_to_ansi: - def __init__(self, color=True, enclose=False, zsh=False): - self.color = _color_when_value(color) - self.enclose = enclose - self.zsh = zsh - - def escape(self, s): - """Returns a TTY escape sequence for a color""" - if self.color: - if self.zsh: - result = rf"\e[0;{s}m" - else: - result = f"\033[{s}m" - - if self.enclose: - result = rf"\[{result}\]" - - return result +def _escape(s: str, color: bool, enclose: bool, zsh: bool) -> str: + """Returns a TTY escape sequence for a color""" + if color: + if zsh: + result = rf"\e[0;{s}m" else: - return "" + result = f"\033[{s}m" - def __call__(self, match): - """Convert a match object generated by ``color_re`` into an ansi - color code. This can be used as a handler in ``re.sub``. - """ - style, color, text = match.groups() - m = match.group(0) + if enclose: + result = rf"\[{result}\]" - if m == "@@": - return "@" - elif m == "@.": - return self.escape(0) - elif m == "@": - raise ColorParseError("Incomplete color format: '%s' in %s" % (m, match.string)) - - string = styles[style] - if color: - if color not in colors: - raise ColorParseError( - "Invalid color specifier: '%s' in '%s'" % (color, match.string) - ) - string += ";" + str(colors[color]) + return result + else: + return "" - colored_text = "" - if text: - colored_text = text + self.escape(0) - return self.escape(string) + colored_text - - -def colorize(string, **kwargs): +def colorize( + string: str, color: Optional[bool] = None, enclose: bool = False, zsh: bool = False +) -> str: """Replace all color expressions in a string with ANSI control codes. Args: - string (str): The string to replace + string: The string to replace Returns: - str: The filtered string + The filtered string Keyword Arguments: - color (bool): If False, output will be plain text without control - codes, for output to non-console devices. - enclose (bool): If True, enclose ansi color sequences with + color: If False, output will be plain text without control codes, for output to + non-console devices (default: automatically choose color or not) + enclose: If True, enclose ansi color sequences with square brackets to prevent misestimation of terminal width. - zsh (bool): If True, use zsh ansi codes instead of bash ones (for variables like PS1) + zsh: If True, use zsh ansi codes instead of bash ones (for variables like PS1) """ - color = _color_when_value(kwargs.get("color", get_color_when())) - zsh = kwargs.get("zsh", False) - string = re.sub(color_re, match_to_ansi(color, kwargs.get("enclose")), string, zsh) - string = string.replace("}}", "}") - return string + color = color if color is not None else get_color_when() + + def match_to_ansi(match): + """Convert a match object generated by ``COLOR_RE`` into an ansi + color code. This can be used as a handler in ``re.sub``. + """ + escaped_at, dot, style, color_code, text = match.groups() + + if escaped_at: + return "@" + elif dot: + return _escape(0, color, enclose, zsh) + elif not (style or color_code): + raise ColorParseError( + f"Incomplete color format: '{match.group(0)}' in '{match.string}'" + ) + + ansi_code = _escape(f"{styles[style]};{colors.get(color_code, '')}", color, enclose, zsh) + if text: + return f"{ansi_code}{text}{_escape(0, color, enclose, zsh)}" + else: + return ansi_code + + return COLOR_RE.sub(match_to_ansi, string).replace("}}", "}") def clen(string): @@ -305,7 +301,7 @@ def cprint(string, stream=None, color=None): cwrite(string + "\n", stream, color) -def cescape(string): +def cescape(string: str) -> str: """Escapes special characters needed for color codes. Replaces the following symbols with their equivalent literal forms: @@ -321,10 +317,7 @@ def cescape(string): Returns: (str): the string with color codes escaped """ - string = str(string) - string = string.replace("@", "@@") - string = string.replace("}", "}}") - return string + return string.replace("@", "@@").replace("}", "}}") class ColorStream: diff --git a/lib/spack/llnl/util/tty/log.py b/lib/spack/llnl/util/tty/log.py index 16fe45edfc7267..aeb1114c5af634 100644 --- a/lib/spack/llnl/util/tty/log.py +++ b/lib/spack/llnl/util/tty/log.py @@ -33,8 +33,23 @@ pass +esc, bell, lbracket, bslash, newline = r"\x1b", r"\x07", r"\[", r"\\", r"\n" +# Ansi Control Sequence Introducers (CSI) are a well-defined format +# Standard ECMA-48: Control Functions for Character-Imaging I/O Devices, section 5.4 +# https://www.ecma-international.org/wp-content/uploads/ECMA-48_5th_edition_june_1991.pdf +csi_pre = f"{esc}{lbracket}" +csi_param, csi_inter, csi_post = r"[0-?]", r"[ -/]", r"[@-~]" +ansi_csi = f"{csi_pre}{csi_param}*{csi_inter}*{csi_post}" +# General ansi escape sequences have well-defined prefixes, +# but content and suffixes are less reliable. +# Conservatively assume they end with either "\" or "", +# with no intervening ""/"" keys or newlines +esc_pre = f"{esc}[@-_]" +esc_content = f"[^{esc}{bell}{newline}]" +esc_post = f"(?:{esc}{bslash}|{bell})" +ansi_esc = f"{esc_pre}{esc_content}*{esc_post}" # Use this to strip escape sequences -_escape = re.compile(r"\x1b[^m]*m|\x1b\[?1034h|\x1b\][0-9]+;[^\x07]*\x07") +_escape = re.compile(f"{ansi_csi}|{ansi_esc}") # control characters for enabling/disabling echo # diff --git a/lib/spack/spack/__init__.py b/lib/spack/spack/__init__.py index 2e2342ac803a71..b37c63b5bd955f 100644 --- a/lib/spack/spack/__init__.py +++ b/lib/spack/spack/__init__.py @@ -4,7 +4,7 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) #: PEP440 canonical ... string -__version__ = "0.22.0.dev0" +__version__ = "0.23.0.dev0" spack_version = __version__ diff --git a/lib/spack/spack/audit.py b/lib/spack/spack/audit.py index bbf2ed19dbd24d..faef15393d952b 100644 --- a/lib/spack/spack/audit.py +++ b/lib/spack/spack/audit.py @@ -254,8 +254,8 @@ def _search_duplicate_specs_in_externals(error_cls): @config_packages def _deprecated_preferences(error_cls): - """Search package preferences deprecated in v0.21 (and slated for removal in v0.22)""" - # TODO (v0.22): remove this audit as the attributes will not be allowed in config + """Search package preferences deprecated in v0.21 (and slated for removal in v0.23)""" + # TODO (v0.23): remove this audit as the attributes will not be allowed in config errors = [] packages_yaml = spack.config.CONFIG.get_config("packages") @@ -421,6 +421,10 @@ def _check_patch_urls(pkgs, error_cls): r"^https?://(?:patch-diff\.)?github(?:usercontent)?\.com/" r".+/.+/(?:commit|pull)/[a-fA-F0-9]+\.(?:patch|diff)" ) + github_pull_commits_re = ( + r"^https?://(?:patch-diff\.)?github(?:usercontent)?\.com/" + r".+/.+/pull/\d+/commits/[a-fA-F0-9]+\.(?:patch|diff)" + ) # Only .diff URLs have stable/full hashes: # https://forum.gitlab.com/t/patches-with-full-index/29313 gitlab_patch_url_re = ( @@ -436,14 +440,24 @@ def _check_patch_urls(pkgs, error_cls): if not isinstance(patch, spack.patch.UrlPatch): continue - if re.match(github_patch_url_re, patch.url): + if re.match(github_pull_commits_re, patch.url): + url = re.sub(r"/pull/\d+/commits/", r"/commit/", patch.url) + url = re.sub(r"^(.*)(? to pick a key." - super().__init__(err_msg) - - -class NoVerifyException(spack.error.SpackError): - """ - Raised if file fails signature verification. - """ - - pass - - -class NoChecksumException(spack.error.SpackError): - """ - Raised if file fails checksum verification. - """ - - def __init__(self, path, size, contents, algorithm, expected, computed): - super().__init__( - f"{algorithm} checksum failed for {path}", - f"Expected {expected} but got {computed}. " - f"File size = {size} bytes. Contents = {contents!r}", - ) - - -class NewLayoutException(spack.error.SpackError): - """ - Raised if directory layout is different from buildcache. - """ - - def __init__(self, msg): - super().__init__(msg) - - -class InvalidMetadataFile(spack.error.SpackError): - pass - - -class UnsignedPackageException(spack.error.SpackError): - """ - Raised if installation of unsigned package is attempted without - the use of ``--no-check-signature``. - """ - - def compute_hash(data): if isinstance(data, str): data = data.encode("utf-8") @@ -740,7 +659,7 @@ def get_buildfile_manifest(spec): # 2. paths are used as strings. for rel_path in visitor.symlinks: abs_path = os.path.join(root, rel_path) - link = os.readlink(abs_path) + link = readlink(abs_path) if os.path.isabs(link) and link.startswith(spack.store.STORE.layout.root): data["link_to_relocate"].append(rel_path) @@ -992,15 +911,10 @@ def url_read_method(url): if entry.endswith("spec.json") or entry.endswith("spec.json.sig") ] read_fn = url_read_method - except KeyError as inst: - msg = "No packages at {0}: {1}".format(cache_prefix, inst) - tty.warn(msg) except Exception as err: - # If we got some kind of S3 (access denied or other connection - # error), the first non boto-specific class in the exception - # hierarchy is Exception. Just print a warning and return - msg = "Encountered problem listing packages at {0}: {1}".format(cache_prefix, err) - tty.warn(msg) + # If we got some kind of S3 (access denied or other connection error), the first non + # boto-specific class in the exception is Exception. Just print a warning and return + tty.warn(f"Encountered problem listing packages at {cache_prefix}: {err}") return file_list, read_fn @@ -1047,11 +961,10 @@ def generate_package_index(cache_prefix, concurrency=32): """ try: file_list, read_fn = _spec_files_from_cache(cache_prefix) - except ListMirrorSpecsError as err: - tty.error("Unable to generate package index, {0}".format(err)) - return + except ListMirrorSpecsError as e: + raise GenerateIndexError(f"Unable to generate package index: {e}") from e - tty.debug("Retrieving spec descriptor files from {0} to build index".format(cache_prefix)) + tty.debug(f"Retrieving spec descriptor files from {cache_prefix} to build index") tmpdir = tempfile.mkdtemp() @@ -1061,27 +974,22 @@ def generate_package_index(cache_prefix, concurrency=32): try: _read_specs_and_push_index(file_list, read_fn, cache_prefix, db, db_root_dir, concurrency) - except Exception as err: - msg = "Encountered problem pushing package index to {0}: {1}".format(cache_prefix, err) - tty.warn(msg) - tty.debug("\n" + traceback.format_exc()) + except Exception as e: + raise GenerateIndexError( + f"Encountered problem pushing package index to {cache_prefix}: {e}" + ) from e finally: - shutil.rmtree(tmpdir) + shutil.rmtree(tmpdir, ignore_errors=True) def generate_key_index(key_prefix, tmpdir=None): """Create the key index page. - Creates (or replaces) the "index.json" page at the location given in - key_prefix. This page contains an entry for each key (.pub) under - key_prefix. + Creates (or replaces) the "index.json" page at the location given in key_prefix. This page + contains an entry for each key (.pub) under key_prefix. """ - tty.debug( - " ".join( - ("Retrieving key.pub files from", url_util.format(key_prefix), "to build key index") - ) - ) + tty.debug(f"Retrieving key.pub files from {url_util.format(key_prefix)} to build key index") try: fingerprints = ( @@ -1089,17 +997,8 @@ def generate_key_index(key_prefix, tmpdir=None): for entry in web_util.list_url(key_prefix, recursive=False) if entry.endswith(".pub") ) - except KeyError as inst: - msg = "No keys at {0}: {1}".format(key_prefix, inst) - tty.warn(msg) - return - except Exception as err: - # If we got some kind of S3 (access denied or other connection - # error), the first non boto-specific class in the exception - # hierarchy is Exception. Just print a warning and return - msg = "Encountered problem listing keys at {0}: {1}".format(key_prefix, err) - tty.warn(msg) - return + except Exception as e: + raise CannotListKeys(f"Encountered problem listing keys at {key_prefix}: {e}") from e remove_tmpdir = False @@ -1124,12 +1023,13 @@ def generate_key_index(key_prefix, tmpdir=None): keep_original=False, extra_args={"ContentType": "application/json"}, ) - except Exception as err: - msg = "Encountered problem pushing key index to {0}: {1}".format(key_prefix, err) - tty.warn(msg) + except Exception as e: + raise GenerateIndexError( + f"Encountered problem pushing key index to {key_prefix}: {e}" + ) from e finally: if remove_tmpdir: - shutil.rmtree(tmpdir) + shutil.rmtree(tmpdir, ignore_errors=True) def tarfile_of_spec_prefix(tar: tarfile.TarFile, prefix: str) -> None: @@ -1200,7 +1100,8 @@ def push_or_raise(spec: Spec, out_url: str, options: PushOptions): used at the mirror (following ). This method raises :py:class:`NoOverwriteException` when ``force=False`` and the tarball or - spec.json file already exist in the buildcache. + spec.json file already exist in the buildcache. It raises :py:class:`PushToBuildCacheError` + when the tarball or spec.json file cannot be pushed to the buildcache. """ if not spec.concrete: raise ValueError("spec must be concrete to build tarball") @@ -1278,13 +1179,18 @@ def _build_tarball_in_stage_dir(spec: Spec, out_url: str, stage_dir: str, option key = select_signing_key(options.key) sign_specfile(key, options.force, specfile_path) - # push tarball and signed spec json to remote mirror - web_util.push_to_url(spackfile_path, remote_spackfile_path, keep_original=False) - web_util.push_to_url( - signed_specfile_path if not options.unsigned else specfile_path, - remote_signed_specfile_path if not options.unsigned else remote_specfile_path, - keep_original=False, - ) + try: + # push tarball and signed spec json to remote mirror + web_util.push_to_url(spackfile_path, remote_spackfile_path, keep_original=False) + web_util.push_to_url( + signed_specfile_path if not options.unsigned else specfile_path, + remote_signed_specfile_path if not options.unsigned else remote_specfile_path, + keep_original=False, + ) + except Exception as e: + raise PushToBuildCacheError( + f"Encountered problem pushing binary {remote_spackfile_path}: {e}" + ) from e # push the key to the build cache's _pgp directory so it can be # imported @@ -1296,8 +1202,6 @@ def _build_tarball_in_stage_dir(spec: Spec, out_url: str, stage_dir: str, option if options.regenerate_index: generate_package_index(url_util.join(out_url, os.path.relpath(cache_prefix, stage_dir))) - return None - class NotInstalledError(spack.error.SpackError): """Raised when a spec is not installed but picked to be packaged.""" @@ -1352,28 +1256,6 @@ def specs_to_be_packaged( return [s for s in itertools.chain(roots, deps) if not s.external] -def push(spec: Spec, mirror_url: str, options: PushOptions): - """Create and push binary package for a single spec to the specified - mirror url. - - Args: - spec: Spec to package and push - mirror_url: Desired destination url for binary package - options: - - Returns: - True if package was pushed, False otherwise. - - """ - try: - push_or_raise(spec, mirror_url, options) - except NoOverwriteException as e: - warnings.warn(str(e)) - return False - - return True - - def try_verify(specfile_path): """Utility function to attempt to verify a local file. Assumes the file is a clearsigned signature file. @@ -2120,6 +2002,7 @@ def install_root_node(spec, unsigned=False, force=False, sha256=None): with spack.util.path.filter_padding(): tty.msg('Installing "{0}" from a buildcache'.format(spec.format())) extract_tarball(spec, download_result, force) + spec.package.windows_establish_runtime_linkage() spack.hooks.post_install(spec, False) spack.store.STORE.db.add(spec, spack.store.STORE.layout) @@ -2706,3 +2589,96 @@ def conditional_fetch(self) -> FetchIndexResult: raise FetchIndexError(f"Remote index {url_manifest} is invalid") return FetchIndexResult(etag=None, hash=index_digest.digest, data=result, fresh=False) + + +class NoOverwriteException(spack.error.SpackError): + """Raised when a file would be overwritten""" + + def __init__(self, file_path): + super().__init__(f"Refusing to overwrite the following file: {file_path}") + + +class NoGpgException(spack.error.SpackError): + """ + Raised when gpg2 is not in PATH + """ + + def __init__(self, msg): + super().__init__(msg) + + +class NoKeyException(spack.error.SpackError): + """ + Raised when gpg has no default key added. + """ + + def __init__(self, msg): + super().__init__(msg) + + +class PickKeyException(spack.error.SpackError): + """ + Raised when multiple keys can be used to sign. + """ + + def __init__(self, keys): + err_msg = "Multiple keys available for signing\n%s\n" % keys + err_msg += "Use spack buildcache create -k to pick a key." + super().__init__(err_msg) + + +class NoVerifyException(spack.error.SpackError): + """ + Raised if file fails signature verification. + """ + + pass + + +class NoChecksumException(spack.error.SpackError): + """ + Raised if file fails checksum verification. + """ + + def __init__(self, path, size, contents, algorithm, expected, computed): + super().__init__( + f"{algorithm} checksum failed for {path}", + f"Expected {expected} but got {computed}. " + f"File size = {size} bytes. Contents = {contents!r}", + ) + + +class NewLayoutException(spack.error.SpackError): + """ + Raised if directory layout is different from buildcache. + """ + + def __init__(self, msg): + super().__init__(msg) + + +class InvalidMetadataFile(spack.error.SpackError): + pass + + +class UnsignedPackageException(spack.error.SpackError): + """ + Raised if installation of unsigned package is attempted without + the use of ``--no-check-signature``. + """ + + +class ListMirrorSpecsError(spack.error.SpackError): + """Raised when unable to retrieve list of specs from the mirror""" + + +class GenerateIndexError(spack.error.SpackError): + """Raised when unable to generate key or package index for mirror""" + + +class CannotListKeys(GenerateIndexError): + """Raised when unable to list keys when generating key index""" + + +class PushToBuildCacheError(spack.error.SpackError): + """Raised when unable to push objects to binary mirror""" diff --git a/lib/spack/spack/bootstrap/__init__.py b/lib/spack/spack/bootstrap/__init__.py index d6844ac14d3b2c..85935cd0e021b2 100644 --- a/lib/spack/spack/bootstrap/__init__.py +++ b/lib/spack/spack/bootstrap/__init__.py @@ -5,7 +5,13 @@ """Function and classes needed to bootstrap Spack itself.""" from .config import ensure_bootstrap_configuration, is_bootstrapping, store_path -from .core import all_core_root_specs, ensure_core_dependencies, ensure_patchelf_in_path_or_raise +from .core import ( + all_core_root_specs, + ensure_clingo_importable_or_raise, + ensure_core_dependencies, + ensure_gpg_in_path_or_raise, + ensure_patchelf_in_path_or_raise, +) from .environment import BootstrapEnvironment, ensure_environment_dependencies from .status import status_message @@ -13,6 +19,8 @@ "is_bootstrapping", "ensure_bootstrap_configuration", "ensure_core_dependencies", + "ensure_gpg_in_path_or_raise", + "ensure_clingo_importable_or_raise", "ensure_patchelf_in_path_or_raise", "all_core_root_specs", "ensure_environment_dependencies", diff --git a/lib/spack/spack/bootstrap/_common.py b/lib/spack/spack/bootstrap/_common.py index 2ce53d31652441..2afc6ea17cb273 100644 --- a/lib/spack/spack/bootstrap/_common.py +++ b/lib/spack/spack/bootstrap/_common.py @@ -54,10 +54,14 @@ def _try_import_from_store( installed_specs = spack.store.STORE.db.query(query_spec, installed=True) for candidate_spec in installed_specs: - pkg = candidate_spec["python"].package + # previously bootstrapped specs may not have a python-venv dependency. + if candidate_spec.dependencies("python-venv"): + python, *_ = candidate_spec.dependencies("python-venv") + else: + python, *_ = candidate_spec.dependencies("python") module_paths = [ - os.path.join(candidate_spec.prefix, pkg.purelib), - os.path.join(candidate_spec.prefix, pkg.platlib), + os.path.join(candidate_spec.prefix, python.package.purelib), + os.path.join(candidate_spec.prefix, python.package.platlib), ] path_before = list(sys.path) @@ -209,15 +213,18 @@ def _root_spec(spec_str: str) -> str: Args: spec_str: spec to be bootstrapped. Must be without compiler and target. """ - # Add a compiler requirement to the root spec. + # Add a compiler and platform requirement to the root spec. platform = str(spack.platforms.host()) + if platform == "darwin": spec_str += " %apple-clang" + elif platform == "windows": + spec_str += " %msvc" elif platform == "linux": spec_str += " %gcc" elif platform == "freebsd": spec_str += " %clang" - + spec_str += f" platform={platform}" target = archspec.cpu.host().family spec_str += f" target={target}" diff --git a/lib/spack/spack/bootstrap/config.py b/lib/spack/spack/bootstrap/config.py index 8cba750fc59eda..067e884b503cd6 100644 --- a/lib/spack/spack/bootstrap/config.py +++ b/lib/spack/spack/bootstrap/config.py @@ -129,10 +129,10 @@ def _bootstrap_config_scopes() -> Sequence["spack.config.ConfigScope"]: configuration_paths = (spack.config.CONFIGURATION_DEFAULTS_PATH, ("bootstrap", _config_path())) for name, path in configuration_paths: platform = spack.platforms.host().name - platform_scope = spack.config.ConfigScope( - "/".join([name, platform]), os.path.join(path, platform) + platform_scope = spack.config.DirectoryConfigScope( + f"{name}/{platform}", os.path.join(path, platform) ) - generic_scope = spack.config.ConfigScope(name, path) + generic_scope = spack.config.DirectoryConfigScope(name, path) config_scopes.extend([generic_scope, platform_scope]) msg = "[BOOTSTRAP CONFIG SCOPE] name={0}, path={1}" tty.debug(msg.format(generic_scope.name, generic_scope.path)) diff --git a/lib/spack/spack/bootstrap/core.py b/lib/spack/spack/bootstrap/core.py index 34aff29b556609..e5e0983c24e7bd 100644 --- a/lib/spack/spack/bootstrap/core.py +++ b/lib/spack/spack/bootstrap/core.py @@ -173,35 +173,14 @@ def _read_metadata(self, package_name: str) -> Any: return data def _install_by_hash( - self, - pkg_hash: str, - pkg_sha256: str, - index: List[spack.spec.Spec], - bincache_platform: spack.platforms.Platform, + self, pkg_hash: str, pkg_sha256: str, bincache_platform: spack.platforms.Platform ) -> None: - index_spec = next(x for x in index if x.dag_hash() == pkg_hash) - # Reconstruct the compiler that we need to use for bootstrapping - compiler_entry = { - "modules": [], - "operating_system": str(index_spec.os), - "paths": { - "cc": "/dev/null", - "cxx": "/dev/null", - "f77": "/dev/null", - "fc": "/dev/null", - }, - "spec": str(index_spec.compiler), - "target": str(index_spec.target.family), - } with spack.platforms.use_platform(bincache_platform): - with spack.config.override("compilers", [{"compiler": compiler_entry}]): - spec_str = "/" + pkg_hash - query = spack.binary_distribution.BinaryCacheQuery(all_architectures=True) - matches = spack.store.find([spec_str], multiple=False, query_fn=query) - for match in matches: - spack.binary_distribution.install_root_node( - match, unsigned=True, force=True, sha256=pkg_sha256 - ) + query = spack.binary_distribution.BinaryCacheQuery(all_architectures=True) + for match in spack.store.find([f"/{pkg_hash}"], multiple=False, query_fn=query): + spack.binary_distribution.install_root_node( + match, unsigned=True, force=True, sha256=pkg_sha256 + ) def _install_and_test( self, @@ -232,7 +211,7 @@ def _install_and_test( continue for _, pkg_hash, pkg_sha256 in item["binaries"]: - self._install_by_hash(pkg_hash, pkg_sha256, index, bincache_platform) + self._install_by_hash(pkg_hash, pkg_sha256, bincache_platform) info: ConfigDictionary = {} if test_fn(query_spec=abstract_spec, query_info=info): @@ -291,10 +270,6 @@ def try_import(self, module: str, abstract_spec_str: str) -> bool: with spack_python_interpreter(): # Add hint to use frontend operating system on Cray concrete_spec = spack.spec.Spec(abstract_spec_str + " ^" + spec_for_current_python()) - # This is needed to help the old concretizer taking the `setuptools` dependency - # only when bootstrapping from sources on Python 3.12 - if spec_for_current_python() == "python@3.12": - concrete_spec.constrain("+force_setuptools") if module == "clingo": # TODO: remove when the old concretizer is deprecated # pylint: disable=fixme @@ -559,6 +534,41 @@ def ensure_patchelf_in_path_or_raise() -> spack.util.executable.Executable: ) +def ensure_winsdk_external_or_raise() -> None: + """Ensure the Windows SDK + WGL are available on system + If both of these package are found, the Spack user or bootstrap + configuration (depending on where Spack is running) + will be updated to include all versions and variants detected. + If either the WDK or WSDK are not found, this method will raise + a RuntimeError. + + **NOTE:** This modifies the Spack config in the current scope, + either user or environment depending on the calling context. + This is different from all other current bootstrap dependency + checks. + """ + if set(["win-sdk", "wgl"]).issubset(spack.config.get("packages").keys()): + return + externals = spack.detection.by_path(["win-sdk", "wgl"]) + if not set(["win-sdk", "wgl"]) == externals.keys(): + missing_packages_lst = [] + if "wgl" not in externals: + missing_packages_lst.append("wgl") + if "win-sdk" not in externals: + missing_packages_lst.append("win-sdk") + missing_packages = " & ".join(missing_packages_lst) + raise RuntimeError( + f"Unable to find the {missing_packages}, please install these packages \ +via the Visual Studio installer \ +before proceeding with Spack or provide the path to a non standard install with \ +'spack external find --path'" + ) + # wgl/sdk are not required for bootstrapping Spack, but + # are required for building anything non trivial + # add to user config so they can be used by subsequent Spack ops + spack.detection.update_configuration(externals, buildable=False) + + def ensure_core_dependencies() -> None: """Ensure the presence of all the core dependencies.""" if sys.platform.lower() == "linux": diff --git a/lib/spack/spack/bootstrap/environment.py b/lib/spack/spack/bootstrap/environment.py index f1af8990e80e81..13942ba86f4693 100644 --- a/lib/spack/spack/bootstrap/environment.py +++ b/lib/spack/spack/bootstrap/environment.py @@ -3,13 +3,11 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) """Bootstrap non-core Spack dependencies from an environment.""" -import glob import hashlib import os import pathlib import sys -import warnings -from typing import List +from typing import Iterable, List import archspec.cpu @@ -28,6 +26,16 @@ class BootstrapEnvironment(spack.environment.Environment): """Environment to install dependencies of Spack for a given interpreter and architecture""" + def __init__(self) -> None: + if not self.spack_yaml().exists(): + self._write_spack_yaml_file() + super().__init__(self.environment_root()) + + # Remove python package roots created before python-venv was introduced + for s in self.concrete_roots(): + if "python" in s.package.extendees and not s.dependencies("python-venv"): + self.deconcretize(s) + @classmethod def spack_dev_requirements(cls) -> List[str]: """Spack development requirements""" @@ -59,31 +67,19 @@ def view_root(cls) -> pathlib.Path: return cls.environment_root().joinpath("view") @classmethod - def pythonpaths(cls) -> List[str]: - """Paths to be added to sys.path or PYTHONPATH""" - python_dir_part = f"python{'.'.join(str(x) for x in sys.version_info[:2])}" - glob_expr = str(cls.view_root().joinpath("**", python_dir_part, "**")) - result = glob.glob(glob_expr) - if not result: - msg = f"Cannot find any Python path in {cls.view_root()}" - warnings.warn(msg) - return result - - @classmethod - def bin_dirs(cls) -> List[pathlib.Path]: + def bin_dir(cls) -> pathlib.Path: """Paths to be added to PATH""" - return [cls.view_root().joinpath("bin")] + return cls.view_root().joinpath("bin") + + def python_dirs(self) -> Iterable[pathlib.Path]: + python = next(s for s in self.all_specs_generator() if s.name == "python-venv").package + return {self.view_root().joinpath(p) for p in (python.platlib, python.purelib)} @classmethod def spack_yaml(cls) -> pathlib.Path: """Environment spack.yaml file""" return cls.environment_root().joinpath("spack.yaml") - def __init__(self) -> None: - if not self.spack_yaml().exists(): - self._write_spack_yaml_file() - super().__init__(self.environment_root()) - def update_installations(self) -> None: """Update the installations of this environment.""" log_enabled = tty.is_debug() or tty.is_verbose() @@ -100,21 +96,13 @@ def update_installations(self) -> None: self.install_all() self.write(regenerate=True) - def update_syspath_and_environ(self) -> None: - """Update ``sys.path`` and the PATH, PYTHONPATH environment variables to point to - the environment view. - """ - # Do minimal modifications to sys.path and environment variables. In particular, pay - # attention to have the smallest PYTHONPATH / sys.path possible, since that may impact - # the performance of the current interpreter - sys.path.extend(self.pythonpaths()) - os.environ["PATH"] = os.pathsep.join( - [str(x) for x in self.bin_dirs()] + os.environ.get("PATH", "").split(os.pathsep) - ) - os.environ["PYTHONPATH"] = os.pathsep.join( - os.environ.get("PYTHONPATH", "").split(os.pathsep) - + [str(x) for x in self.pythonpaths()] - ) + def load(self) -> None: + """Update PATH and sys.path.""" + # Make executables available (shouldn't need PYTHONPATH) + os.environ["PATH"] = f"{self.bin_dir()}{os.pathsep}{os.environ.get('PATH', '')}" + + # Spack itself imports pytest + sys.path.extend(str(p) for p in self.python_dirs()) def _write_spack_yaml_file(self) -> None: tty.msg( @@ -164,4 +152,4 @@ def ensure_environment_dependencies() -> None: _add_externals_if_missing() with BootstrapEnvironment() as env: env.update_installations() - env.update_syspath_and_environ() + env.load() diff --git a/lib/spack/spack/build_environment.py b/lib/spack/spack/build_environment.py index 68369cbe059f30..c02c3bc81850b2 100644 --- a/lib/spack/spack/build_environment.py +++ b/lib/spack/spack/build_environment.py @@ -43,7 +43,7 @@ from collections import defaultdict from enum import Flag, auto from itertools import chain -from typing import List, Tuple +from typing import Dict, List, Set, Tuple import llnl.util.tty as tty from llnl.string import plural @@ -57,8 +57,10 @@ import spack.build_systems.meson import spack.build_systems.python import spack.builder +import spack.compilers import spack.config import spack.deptypes as dt +import spack.error import spack.main import spack.package_base import spack.paths @@ -66,9 +68,11 @@ import spack.repo import spack.schema.environment import spack.spec +import spack.stage import spack.store import spack.subprocess_context import spack.user_environment +import spack.util.executable import spack.util.path import spack.util.pattern from spack import traverse @@ -78,7 +82,7 @@ from spack.installer import InstallError from spack.util.cpus import determine_number_of_jobs from spack.util.environment import ( - SYSTEM_DIRS, + SYSTEM_DIR_CASE_ENTRY, EnvironmentModifications, env_flag, filter_system_paths, @@ -88,7 +92,7 @@ ) from spack.util.executable import Executable from spack.util.log_parse import make_log_context, parse_log_events -from spack.util.module_cmd import load_module, module, path_from_modules +from spack.util.module_cmd import load_module, path_from_modules # # This can be set by the user to globally disable parallel builds. @@ -101,9 +105,13 @@ # Spack's compiler wrappers. # SPACK_ENV_PATH = "SPACK_ENV_PATH" +SPACK_MANAGED_DIRS = "SPACK_MANAGED_DIRS" SPACK_INCLUDE_DIRS = "SPACK_INCLUDE_DIRS" SPACK_LINK_DIRS = "SPACK_LINK_DIRS" SPACK_RPATH_DIRS = "SPACK_RPATH_DIRS" +SPACK_STORE_INCLUDE_DIRS = "SPACK_STORE_INCLUDE_DIRS" +SPACK_STORE_LINK_DIRS = "SPACK_STORE_LINK_DIRS" +SPACK_STORE_RPATH_DIRS = "SPACK_STORE_RPATH_DIRS" SPACK_RPATH_DEPS = "SPACK_RPATH_DEPS" SPACK_LINK_DEPS = "SPACK_LINK_DEPS" SPACK_PREFIX = "SPACK_PREFIX" @@ -183,14 +191,6 @@ def __call__(self, *args, **kwargs): return super().__call__(*args, **kwargs) -def _on_cray(): - host_platform = spack.platforms.host() - host_os = host_platform.operating_system("default_os") - on_cray = str(host_platform) == "cray" - using_cnl = re.match(r"cnl\d+", str(host_os)) - return on_cray, using_cnl - - def clean_environment(): # Stuff in here sanitizes the build environment to eliminate # anything the user has set that may interfere. We apply it immediately @@ -234,17 +234,6 @@ def clean_environment(): if varname.endswith("_ROOT") and varname != "SPACK_ROOT": env.unset(varname) - # On Cray "cluster" systems, unset CRAY_LD_LIBRARY_PATH to avoid - # interference with Spack dependencies. - # CNL requires these variables to be set (or at least some of them, - # depending on the CNL version). - on_cray, using_cnl = _on_cray() - if on_cray and not using_cnl: - env.unset("CRAY_LD_LIBRARY_PATH") - for varname in os.environ.keys(): - if "PKGCONF" in varname: - env.unset(varname) - # Unset the following variables because they can affect installation of # Autotools and CMake packages. build_system_vars = [ @@ -374,11 +363,7 @@ def set_compiler_environment_variables(pkg, env): _add_werror_handling(keep_werror, env) # Set the target parameters that the compiler will add - # Don't set on cray platform because the targeting module handles this - if spec.satisfies("platform=cray"): - isa_arg = "" - else: - isa_arg = spec.architecture.target.optimization_flags(compiler) + isa_arg = spec.architecture.target.optimization_flags(compiler) env.set("SPACK_TARGET_ARGS", isa_arg) # Trap spack-tracked compiler flags as appropriate. @@ -416,7 +401,7 @@ def set_compiler_environment_variables(pkg, env): env.set("SPACK_COMPILER_SPEC", str(spec.compiler)) - env.set("SPACK_SYSTEM_DIRS", ":".join(SYSTEM_DIRS)) + env.set("SPACK_SYSTEM_DIRS", SYSTEM_DIR_CASE_ENTRY) compiler.setup_custom_environment(pkg, env) @@ -474,10 +459,7 @@ def set_wrapper_variables(pkg, env): # Find ccache binary and hand it to build environment if spack.config.get("config:ccache"): - ccache = Executable("ccache") - if not ccache: - raise RuntimeError("No ccache binary found in PATH") - env.set(SPACK_CCACHE_BINARY, ccache) + env.set(SPACK_CCACHE_BINARY, spack.util.executable.which_string("ccache", required=True)) # Gather information about various types of dependencies link_deps = set(pkg.spec.traverse(root=False, deptype=("link"))) @@ -544,9 +526,26 @@ def update_compiler_args_for_dep(dep): include_dirs = list(dedupe(filter_system_paths(include_dirs))) rpath_dirs = list(dedupe(filter_system_paths(rpath_dirs))) - env.set(SPACK_LINK_DIRS, ":".join(link_dirs)) - env.set(SPACK_INCLUDE_DIRS, ":".join(include_dirs)) - env.set(SPACK_RPATH_DIRS, ":".join(rpath_dirs)) + # Spack managed directories include the stage, store and upstream stores. We extend this with + # their real paths to make it more robust (e.g. /tmp vs /private/tmp on macOS). + spack_managed_dirs: Set[str] = { + spack.stage.get_stage_root(), + spack.store.STORE.db.root, + *(db.root for db in spack.store.STORE.db.upstream_dbs), + } + spack_managed_dirs.update([os.path.realpath(p) for p in spack_managed_dirs]) + + env.set(SPACK_MANAGED_DIRS, "|".join(f'"{p}/"*' for p in sorted(spack_managed_dirs))) + is_spack_managed = lambda p: any(p.startswith(store) for store in spack_managed_dirs) + link_dirs_spack, link_dirs_system = stable_partition(link_dirs, is_spack_managed) + include_dirs_spack, include_dirs_system = stable_partition(include_dirs, is_spack_managed) + rpath_dirs_spack, rpath_dirs_system = stable_partition(rpath_dirs, is_spack_managed) + env.set(SPACK_LINK_DIRS, ":".join(link_dirs_system)) + env.set(SPACK_INCLUDE_DIRS, ":".join(include_dirs_system)) + env.set(SPACK_RPATH_DIRS, ":".join(rpath_dirs_system)) + env.set(SPACK_STORE_LINK_DIRS, ":".join(link_dirs_spack)) + env.set(SPACK_STORE_INCLUDE_DIRS, ":".join(include_dirs_spack)) + env.set(SPACK_STORE_RPATH_DIRS, ":".join(rpath_dirs_spack)) def set_package_py_globals(pkg, context: Context = Context.BUILD): @@ -583,10 +582,22 @@ def set_package_py_globals(pkg, context: Context = Context.BUILD): # Put spack compiler paths in module scope. (Some packages use it # in setup_run_environment etc, so don't put it context == build) link_dir = spack.paths.build_env_path - module.spack_cc = os.path.join(link_dir, pkg.compiler.link_paths["cc"]) - module.spack_cxx = os.path.join(link_dir, pkg.compiler.link_paths["cxx"]) - module.spack_f77 = os.path.join(link_dir, pkg.compiler.link_paths["f77"]) - module.spack_fc = os.path.join(link_dir, pkg.compiler.link_paths["fc"]) + pkg_compiler = None + try: + pkg_compiler = pkg.compiler + except spack.compilers.NoCompilerForSpecError as e: + tty.debug(f"cannot set 'spack_cc': {str(e)}") + + if pkg_compiler is not None: + module.spack_cc = os.path.join(link_dir, pkg_compiler.link_paths["cc"]) + module.spack_cxx = os.path.join(link_dir, pkg_compiler.link_paths["cxx"]) + module.spack_f77 = os.path.join(link_dir, pkg_compiler.link_paths["f77"]) + module.spack_fc = os.path.join(link_dir, pkg_compiler.link_paths["fc"]) + else: + module.spack_cc = None + module.spack_cxx = None + module.spack_f77 = None + module.spack_fc = None # Useful directories within the prefix are encapsulated in # a Prefix object. @@ -694,12 +705,28 @@ def _static_to_shared_library(arch, compiler, static_lib, shared_lib=None, **kwa return compiler(*compiler_args, output=compiler_output) -def get_rpath_deps(pkg): - """Return immediate or transitive RPATHs depending on the package.""" - if pkg.transitive_rpaths: - return [d for d in pkg.spec.traverse(root=False, deptype=("link"))] - else: - return pkg.spec.dependencies(deptype="link") +def _get_rpath_deps_from_spec( + spec: spack.spec.Spec, transitive_rpaths: bool +) -> List[spack.spec.Spec]: + if not transitive_rpaths: + return spec.dependencies(deptype=dt.LINK) + + by_name: Dict[str, spack.spec.Spec] = {} + + for dep in spec.traverse(root=False, deptype=dt.LINK): + lookup = by_name.get(dep.name) + if lookup is None: + by_name[dep.name] = dep + elif lookup.version < dep.version: + by_name[dep.name] = dep + + return list(by_name.values()) + + +def get_rpath_deps(pkg: spack.package_base.PackageBase) -> List[spack.spec.Spec]: + """Return immediate or transitive dependencies (depending on the package) that need to be + rpath'ed. If a package occurs multiple times, the newest version is kept.""" + return _get_rpath_deps_from_spec(pkg.spec, pkg.transitive_rpaths) def get_rpaths(pkg): @@ -711,7 +738,9 @@ def get_rpaths(pkg): # Second module is our compiler mod name. We use that to get rpaths from # module show output. if pkg.compiler.modules and len(pkg.compiler.modules) > 1: - rpaths.append(path_from_modules([pkg.compiler.modules[1]])) + mod_rpath = path_from_modules([pkg.compiler.modules[1]]) + if mod_rpath: + rpaths.append(mod_rpath) return list(dedupe(filter_system_paths(rpaths))) @@ -781,15 +810,7 @@ def setup_package(pkg, dirty, context: Context = Context.BUILD): for mod in pkg.compiler.modules: load_module(mod) - # kludge to handle cray mpich and libsci being automatically loaded by - # PrgEnv modules on cray platform. Module unload does no damage when - # unnecessary - on_cray, _ = _on_cray() - if on_cray and not dirty: - for mod in ["cray-mpich", "cray-libsci"]: - module("unload", mod) - - if target.module_name: + if target and target.module_name: load_module(target.module_name) load_external_modules(pkg) @@ -1452,7 +1473,7 @@ def long_message(self): out.write(" {0}\n".format(self.log_name)) # Also output the test log path IF it exists - if self.context != "test": + if self.context != "test" and have_log: test_log = join_path(os.path.dirname(self.log_name), spack_install_test_log) if os.path.isfile(test_log): out.write("\nSee test log for details:\n") diff --git a/lib/spack/spack/build_systems/autotools.py b/lib/spack/spack/build_systems/autotools.py index 1f44ebf1373090..ce4d6bc27915fd 100644 --- a/lib/spack/spack/build_systems/autotools.py +++ b/lib/spack/spack/build_systems/autotools.py @@ -434,11 +434,6 @@ def _do_patch_libtool(self): r"crtendS\.o", ]: x.filter(regex=(rehead + o), repl="") - elif self.pkg.compiler.name == "dpcpp": - # Hack to filter out spurious predep_objects when building with Intel dpcpp - # (see https://github.com/spack/spack/issues/32863): - x.filter(regex=r"^(predep_objects=.*)/tmp/conftest-[0-9A-Fa-f]+\.o", repl=r"\1") - x.filter(regex=r"^(predep_objects=.*)/tmp/a-[0-9A-Fa-f]+\.o", repl=r"\1") elif self.pkg.compiler.name == "nag": for tag in ["fc", "f77"]: marker = markers[tag] diff --git a/lib/spack/spack/build_systems/cached_cmake.py b/lib/spack/spack/build_systems/cached_cmake.py index ca9eae52b40400..aff54d7559e746 100644 --- a/lib/spack/spack/build_systems/cached_cmake.py +++ b/lib/spack/spack/build_systems/cached_cmake.py @@ -4,6 +4,7 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) import collections.abc import os +import re from typing import Tuple import llnl.util.filesystem as fs @@ -15,6 +16,12 @@ from .cmake import CMakeBuilder, CMakePackage +def spec_uses_toolchain(spec): + gcc_toolchain_regex = re.compile(".*gcc-toolchain.*") + using_toolchain = list(filter(gcc_toolchain_regex.match, spec.compiler_flags["cxxflags"])) + return using_toolchain + + def cmake_cache_path(name, value, comment="", force=False): """Generate a string for a cmake cache variable""" force_str = " FORCE" if force else "" @@ -155,7 +162,9 @@ def initconfig_compiler_entries(self): ld_flags = " ".join(flags["ldflags"]) ld_format_string = "CMAKE_{0}_LINKER_FLAGS" # CMake has separate linker arguments for types of builds. - for ld_type in ["EXE", "MODULE", "SHARED", "STATIC"]: + # 'ldflags' should not be used with CMAKE_STATIC_LINKER_FLAGS which + # is used by the archiver, so don't include "STATIC" in this loop: + for ld_type in ["EXE", "MODULE", "SHARED"]: ld_string = ld_format_string.format(ld_type) entries.append(cmake_cache_string(ld_string, ld_flags)) @@ -213,7 +222,7 @@ def initconfig_mpi_entries(self): else: # starting with cmake 3.10, FindMPI expects MPIEXEC_EXECUTABLE # vs the older versions which expect MPIEXEC - if self.pkg.spec["cmake"].satisfies("@3.10:"): + if spec["cmake"].satisfies("@3.10:"): entries.append(cmake_cache_path("MPIEXEC_EXECUTABLE", mpiexec)) else: entries.append(cmake_cache_path("MPIEXEC", mpiexec)) @@ -248,12 +257,17 @@ def initconfig_hardware_entries(self): # Include the deprecated CUDA_TOOLKIT_ROOT_DIR for supporting BLT packages entries.append(cmake_cache_path("CUDA_TOOLKIT_ROOT_DIR", cudatoolkitdir)) - archs = spec.variants["cuda_arch"].value - if archs[0] != "none": - arch_str = ";".join(archs) - entries.append( - cmake_cache_string("CMAKE_CUDA_ARCHITECTURES", "{0}".format(arch_str)) - ) + # CUDA_FLAGS + cuda_flags = [] + + if not spec.satisfies("cuda_arch=none"): + cuda_archs = ";".join(spec.variants["cuda_arch"].value) + entries.append(cmake_cache_string("CMAKE_CUDA_ARCHITECTURES", cuda_archs)) + + if spec_uses_toolchain(spec): + cuda_flags.append("-Xcompiler {}".format(spec_uses_toolchain(spec)[0])) + + entries.append(cmake_cache_string("CMAKE_CUDA_FLAGS", " ".join(cuda_flags))) if "+rocm" in spec: entries.append("#------------------{0}".format("-" * 30)) @@ -262,9 +276,6 @@ def initconfig_hardware_entries(self): # Explicitly setting HIP_ROOT_DIR may be a patch that is no longer necessary entries.append(cmake_cache_path("HIP_ROOT_DIR", "{0}".format(spec["hip"].prefix))) - entries.append( - cmake_cache_path("HIP_CXX_COMPILER", "{0}".format(self.spec["hip"].hipcc)) - ) llvm_bin = spec["llvm-amdgpu"].prefix.bin llvm_prefix = spec["llvm-amdgpu"].prefix # Some ROCm systems seem to point to //rocm-/ and @@ -277,11 +288,9 @@ def initconfig_hardware_entries(self): archs = self.spec.variants["amdgpu_target"].value if archs[0] != "none": arch_str = ";".join(archs) - entries.append( - cmake_cache_string("CMAKE_HIP_ARCHITECTURES", "{0}".format(arch_str)) - ) - entries.append(cmake_cache_string("AMDGPU_TARGETS", "{0}".format(arch_str))) - entries.append(cmake_cache_string("GPU_TARGETS", "{0}".format(arch_str))) + entries.append(cmake_cache_string("CMAKE_HIP_ARCHITECTURES", arch_str)) + entries.append(cmake_cache_string("AMDGPU_TARGETS", arch_str)) + entries.append(cmake_cache_string("GPU_TARGETS", arch_str)) return entries diff --git a/lib/spack/spack/build_systems/cargo.py b/lib/spack/spack/build_systems/cargo.py index 0aa31b48555a97..2fd952d8c2fa3d 100644 --- a/lib/spack/spack/build_systems/cargo.py +++ b/lib/spack/spack/build_systems/cargo.py @@ -16,7 +16,7 @@ class CargoPackage(spack.package_base.PackageBase): - """Specialized class for packages built using a Makefiles.""" + """Specialized class for packages built using cargo.""" #: This attribute is used in UI queries that need to know the build #: system base class diff --git a/lib/spack/spack/build_systems/cmake.py b/lib/spack/spack/build_systems/cmake.py index b6e66e136cd230..a64904715e0027 100644 --- a/lib/spack/spack/build_systems/cmake.py +++ b/lib/spack/spack/build_systems/cmake.py @@ -39,16 +39,11 @@ def _maybe_set_python_hints(pkg: spack.package_base.PackageBase, args: List[str] """Set the PYTHON_EXECUTABLE, Python_EXECUTABLE, and Python3_EXECUTABLE CMake variables if the package has Python as build or link dep and ``find_python_hints`` is set to True. See ``find_python_hints`` for context.""" - if not getattr(pkg, "find_python_hints", False): + if not getattr(pkg, "find_python_hints", False) or not pkg.spec.dependencies( + "python", dt.BUILD | dt.LINK + ): return - pythons = pkg.spec.dependencies("python", dt.BUILD | dt.LINK) - if len(pythons) != 1: - return - try: - python_executable = pythons[0].package.command.path - except RuntimeError: - return - + python_executable = pkg.spec["python"].command.path args.extend( [ CMakeBuilder.define("PYTHON_EXECUTABLE", python_executable), diff --git a/lib/spack/spack/build_systems/compiler.py b/lib/spack/spack/build_systems/compiler.py new file mode 100644 index 00000000000000..d441b57b2e88c4 --- /dev/null +++ b/lib/spack/spack/build_systems/compiler.py @@ -0,0 +1,144 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +import itertools +import os +import pathlib +import re +import sys +from typing import Dict, List, Sequence, Tuple, Union + +import llnl.util.tty as tty +from llnl.util.lang import classproperty + +import spack.compiler +import spack.package_base + +# Local "type" for type hints +Path = Union[str, pathlib.Path] + + +class CompilerPackage(spack.package_base.PackageBase): + """A Package mixin for all common logic for packages that implement compilers""" + + # TODO: how do these play nicely with other tags + tags: Sequence[str] = ["compiler"] + + #: Optional suffix regexes for searching for this type of compiler. + #: Suffixes are used by some frameworks, e.g. macports uses an '-mp-X.Y' + #: version suffix for gcc. + compiler_suffixes: List[str] = [r"-.*"] + + #: Optional prefix regexes for searching for this compiler + compiler_prefixes: List[str] = [] + + #: Compiler argument(s) that produces version information + #: If multiple arguments, the earlier arguments must produce errors when invalid + compiler_version_argument: Union[str, Tuple[str]] = "-dumpversion" + + #: Regex used to extract version from compiler's output + compiler_version_regex: str = "(.*)" + + #: Static definition of languages supported by this class + compiler_languages: Sequence[str] = ["c", "cxx", "fortran"] + + def __init__(self, spec: "spack.spec.Spec"): + super().__init__(spec) + msg = f"Supported languages for {spec} are not a subset of possible supported languages" + msg += f" supports: {self.supported_languages}, valid values: {self.compiler_languages}" + assert set(self.supported_languages) <= set(self.compiler_languages), msg + + @property + def supported_languages(self) -> Sequence[str]: + """Dynamic definition of languages supported by this package""" + return self.compiler_languages + + @classproperty + def compiler_names(cls) -> Sequence[str]: + """Construct list of compiler names from per-language names""" + names = [] + for language in cls.compiler_languages: + names.extend(getattr(cls, f"{language}_names")) + return names + + @classproperty + def executables(cls) -> Sequence[str]: + """Construct executables for external detection from names, prefixes, and suffixes.""" + regexp_fmt = r"^({0}){1}({2})$" + prefixes = [""] + cls.compiler_prefixes + suffixes = [""] + cls.compiler_suffixes + if sys.platform == "win32": + ext = r"\.(?:exe|bat)" + suffixes += [suf + ext for suf in suffixes] + return [ + regexp_fmt.format(prefix, re.escape(name), suffix) + for prefix, name, suffix in itertools.product(prefixes, cls.compiler_names, suffixes) + ] + + @classmethod + def determine_version(cls, exe: Path): + version_argument = cls.compiler_version_argument + if isinstance(version_argument, str): + version_argument = (version_argument,) + + for va in version_argument: + try: + output = spack.compiler.get_compiler_version_output(exe, va) + match = re.search(cls.compiler_version_regex, output) + if match: + return ".".join(match.groups()) + except spack.util.executable.ProcessError: + pass + except Exception as e: + tty.debug( + f"[{__file__}] Cannot detect a valid version for the executable " + f"{str(exe)}, for package '{cls.name}': {e}" + ) + + @classmethod + def compiler_bindir(cls, prefix: Path) -> Path: + """Overridable method for the location of the compiler bindir within the preifx""" + return os.path.join(prefix, "bin") + + @classmethod + def determine_compiler_paths(cls, exes: Sequence[Path]) -> Dict[str, Path]: + """Compute the paths to compiler executables associated with this package + + This is a helper method for ``determine_variants`` to compute the ``extra_attributes`` + to include with each spec object.""" + # There are often at least two copies (not symlinks) of each compiler executable in the + # same directory: one with a canonical name, e.g. "gfortran", and another one with the + # target prefix, e.g. "x86_64-pc-linux-gnu-gfortran". There also might be a copy of "gcc" + # with the version suffix, e.g. "x86_64-pc-linux-gnu-gcc-6.3.0". To ensure the consistency + # of values in the "paths" dictionary (i.e. we prefer all of them to reference copies + # with canonical names if possible), we iterate over the executables in the reversed sorted + # order: + # First pass over languages identifies exes that are perfect matches for canonical names + # Second pass checks for names with prefix/suffix + # Second pass is sorted by language name length because longer named languages + # e.g. cxx can often contain the names of shorter named languages + # e.g. c (e.g. clang/clang++) + paths = {} + exes = sorted(exes, reverse=True) + languages = { + lang: getattr(cls, f"{lang}_names") + for lang in sorted(cls.compiler_languages, key=len, reverse=True) + } + for exe in exes: + for lang, names in languages.items(): + if os.path.basename(exe) in names: + paths[lang] = exe + break + else: + for lang, names in languages.items(): + if any(name in os.path.basename(exe) for name in names): + paths[lang] = exe + break + + return paths + + @classmethod + def determine_variants(cls, exes: Sequence[Path], version_str: str) -> Tuple: + # path determination is separated so it can be reused in subclasses + return "", {"compilers": cls.determine_compiler_paths(exes=exes)} diff --git a/lib/spack/spack/build_systems/cuda.py b/lib/spack/spack/build_systems/cuda.py index 4311df3a1746c7..f20677df337105 100644 --- a/lib/spack/spack/build_systems/cuda.py +++ b/lib/spack/spack/build_systems/cuda.py @@ -110,9 +110,8 @@ def cuda_flags(arch_list): # From the NVIDIA install guide we know of conflicts for particular # platforms (linux, darwin), architectures (x86, powerpc) and compilers # (gcc, clang). We don't restrict %gcc and %clang conflicts to - # platform=linux, since they should also apply to platform=cray, and may - # apply to platform=darwin. We currently do not provide conflicts for - # platform=darwin with %apple-clang. + # platform=linux, since they may apply to platform=darwin. We currently + # do not provide conflicts for platform=darwin with %apple-clang. # Linux x86_64 compiler conflicts from here: # https://gist.github.com/ax3l/9489132 @@ -125,6 +124,8 @@ def cuda_flags(arch_list): # minimum supported versions conflicts("%gcc@:4", when="+cuda ^cuda@11.0:") conflicts("%gcc@:5", when="+cuda ^cuda@11.4:") + conflicts("%gcc@:7.2", when="+cuda ^cuda@12.4:") + conflicts("%clang@:6", when="+cuda ^cuda@12.2:") # maximum supported version # NOTE: @@ -137,11 +138,14 @@ def cuda_flags(arch_list): conflicts("%gcc@11.2:", when="+cuda ^cuda@:11.5") conflicts("%gcc@12:", when="+cuda ^cuda@:11.8") conflicts("%gcc@13:", when="+cuda ^cuda@:12.3") + conflicts("%gcc@14:", when="+cuda ^cuda@:12.5") conflicts("%clang@12:", when="+cuda ^cuda@:11.4.0") conflicts("%clang@13:", when="+cuda ^cuda@:11.5") conflicts("%clang@14:", when="+cuda ^cuda@:11.7") conflicts("%clang@15:", when="+cuda ^cuda@:12.0") - conflicts("%clang@16:", when="+cuda ^cuda@:12.3") + conflicts("%clang@16:", when="+cuda ^cuda@:12.1") + conflicts("%clang@17:", when="+cuda ^cuda@:12.3") + conflicts("%clang@18:", when="+cuda ^cuda@:12.5") # https://gist.github.com/ax3l/9489132#gistcomment-3860114 conflicts("%gcc@10", when="+cuda ^cuda@:11.4.0") @@ -209,12 +213,16 @@ def cuda_flags(arch_list): conflicts("%intel@19.0:", when="+cuda ^cuda@:10.0") conflicts("%intel@19.1:", when="+cuda ^cuda@:10.1") conflicts("%intel@19.2:", when="+cuda ^cuda@:11.1.0") + conflicts("%intel@2021:", when="+cuda ^cuda@:11.4.0") # XL is mostly relevant for ppc64le Linux conflicts("%xl@:12,14:", when="+cuda ^cuda@:9.1") conflicts("%xl@:12,14:15,17:", when="+cuda ^cuda@9.2") conflicts("%xl@:12,17:", when="+cuda ^cuda@:11.1.0") + # PowerPC. + conflicts("target=ppc64le", when="+cuda ^cuda@12.5:") + # Darwin. # TODO: add missing conflicts for %apple-clang cuda@:10 - conflicts("platform=darwin", when="+cuda ^cuda@11.0.2: ") + conflicts("platform=darwin", when="+cuda ^cuda@11.0.2:") diff --git a/lib/spack/spack/build_systems/go.py b/lib/spack/spack/build_systems/go.py index 95472642f68695..a22d3922e82c16 100644 --- a/lib/spack/spack/build_systems/go.py +++ b/lib/spack/spack/build_systems/go.py @@ -72,7 +72,7 @@ def build_directory(self): def build_args(self): """Arguments for ``go build``.""" # Pass ldflags -s = --strip-all and -w = --no-warnings by default - return ["-ldflags", "-s -w", "-o", f"{self.pkg.name}"] + return ["-modcacherw", "-ldflags", "-s -w", "-o", f"{self.pkg.name}"] @property def check_args(self): diff --git a/lib/spack/spack/build_systems/intel.py b/lib/spack/spack/build_systems/intel.py index 1a6e0b7acbde52..5695a9dbeb32f9 100644 --- a/lib/spack/spack/build_systems/intel.py +++ b/lib/spack/spack/build_systems/intel.py @@ -846,6 +846,7 @@ def scalapack_libs(self): "^mpich@2:" in spec_root or "^cray-mpich" in spec_root or "^mvapich2" in spec_root + or "^mvapich" in spec_root or "^intel-mpi" in spec_root or "^intel-oneapi-mpi" in spec_root or "^intel-parallel-studio" in spec_root @@ -936,32 +937,15 @@ def mpi_setup_dependent_build_environment(self, env, dependent_spec, compilers_o "I_MPI_ROOT": self.normalize_path("mpi"), } - # CAUTION - SIMILAR code in: - # var/spack/repos/builtin/packages/mpich/package.py - # var/spack/repos/builtin/packages/openmpi/package.py - # var/spack/repos/builtin/packages/mvapich2/package.py - # - # On Cray, the regular compiler wrappers *are* the MPI wrappers. - if "platform=cray" in self.spec: - # TODO: Confirm - wrapper_vars.update( - { - "MPICC": compilers_of_client["CC"], - "MPICXX": compilers_of_client["CXX"], - "MPIF77": compilers_of_client["F77"], - "MPIF90": compilers_of_client["F90"], - } - ) - else: - compiler_wrapper_commands = self.mpi_compiler_wrappers - wrapper_vars.update( - { - "MPICC": compiler_wrapper_commands["MPICC"], - "MPICXX": compiler_wrapper_commands["MPICXX"], - "MPIF77": compiler_wrapper_commands["MPIF77"], - "MPIF90": compiler_wrapper_commands["MPIF90"], - } - ) + compiler_wrapper_commands = self.mpi_compiler_wrappers + wrapper_vars.update( + { + "MPICC": compiler_wrapper_commands["MPICC"], + "MPICXX": compiler_wrapper_commands["MPICXX"], + "MPIF77": compiler_wrapper_commands["MPIF77"], + "MPIF90": compiler_wrapper_commands["MPIF90"], + } + ) # Ensure that the directory containing the compiler wrappers is in the # PATH. Spack packages add `prefix.bin` to their dependents' paths, diff --git a/lib/spack/spack/build_systems/makefile.py b/lib/spack/spack/build_systems/makefile.py index baae2308a2fcbb..915f71d33238bf 100644 --- a/lib/spack/spack/build_systems/makefile.py +++ b/lib/spack/spack/build_systems/makefile.py @@ -21,7 +21,7 @@ class MakefilePackage(spack.package_base.PackageBase): - """Specialized class for packages built using a Makefiles.""" + """Specialized class for packages built using Makefiles.""" #: This attribute is used in UI queries that need to know the build #: system base class diff --git a/lib/spack/spack/build_systems/msbuild.py b/lib/spack/spack/build_systems/msbuild.py index 1520ebc21d0b43..0edc49b880f0c1 100644 --- a/lib/spack/spack/build_systems/msbuild.py +++ b/lib/spack/spack/build_systems/msbuild.py @@ -24,7 +24,6 @@ class MSBuildPackage(spack.package_base.PackageBase): build_system("msbuild") conflicts("platform=linux", when="build_system=msbuild") conflicts("platform=darwin", when="build_system=msbuild") - conflicts("platform=cray", when="build_system=msbuild") @spack.builder.builder("msbuild") diff --git a/lib/spack/spack/build_systems/nmake.py b/lib/spack/spack/build_systems/nmake.py index f8823548dee764..d378d6233640ba 100644 --- a/lib/spack/spack/build_systems/nmake.py +++ b/lib/spack/spack/build_systems/nmake.py @@ -24,7 +24,6 @@ class NMakePackage(spack.package_base.PackageBase): build_system("nmake") conflicts("platform=linux", when="build_system=nmake") conflicts("platform=darwin", when="build_system=nmake") - conflicts("platform=cray", when="build_system=nmake") @spack.builder.builder("nmake") @@ -145,7 +144,7 @@ def install(self, pkg, spec, prefix): opts += self.nmake_install_args() if self.makefile_name: opts.append("/F{}".format(self.makefile_name)) - opts.append(self.define("PREFIX", prefix)) + opts.append(self.define("PREFIX", fs.windows_sfn(prefix))) with fs.working_dir(self.build_directory): inspect.getmodule(self.pkg).nmake( *opts, *self.install_targets, ignore_quotes=self.ignore_quotes diff --git a/lib/spack/spack/build_systems/oneapi.py b/lib/spack/spack/build_systems/oneapi.py index 963873ce3a7ff0..d18845372fe7e6 100644 --- a/lib/spack/spack/build_systems/oneapi.py +++ b/lib/spack/spack/build_systems/oneapi.py @@ -14,7 +14,7 @@ from llnl.util.link_tree import LinkTree from spack.build_environment import dso_suffix -from spack.directives import conflicts, variant +from spack.directives import conflicts, license, redistribute, variant from spack.package_base import InstallError from spack.util.environment import EnvironmentModifications from spack.util.executable import Executable @@ -26,18 +26,18 @@ class IntelOneApiPackage(Package): """Base class for Intel oneAPI packages.""" homepage = "https://software.intel.com/oneapi" + license("https://intel.ly/393CijO") # oneAPI license does not allow mirroring outside of the # organization (e.g. University/Company). - redistribute_source = False + redistribute(source=False, binary=False) for c in [ "target=ppc64:", "target=ppc64le:", "target=aarch64:", - "platform=darwin:", - "platform=cray:", - "platform=windows:", + "platform=darwin", + "platform=windows", ]: conflicts(c, msg="This package in only available for x86_64 and Linux") diff --git a/lib/spack/spack/build_systems/python.py b/lib/spack/spack/build_systems/python.py index a57e9a126635fa..0179997e5a18d4 100644 --- a/lib/spack/spack/build_systems/python.py +++ b/lib/spack/spack/build_systems/python.py @@ -138,16 +138,21 @@ def view_file_conflicts(self, view, merge_map): return conflicts def add_files_to_view(self, view, merge_map, skip_if_exists=True): - # Patch up shebangs to the python linked in the view only if python is built by Spack. - if not self.extendee_spec or self.extendee_spec.external: + # Patch up shebangs if the package extends Python and we put a Python interpreter in the + # view. + if not self.extendee_spec: + return super().add_files_to_view(view, merge_map, skip_if_exists) + + python, *_ = self.spec.dependencies("python-venv") or self.spec.dependencies("python") + + if python.external: return super().add_files_to_view(view, merge_map, skip_if_exists) # We only patch shebangs in the bin directory. copied_files: Dict[Tuple[int, int], str] = {} # File identifier -> source delayed_links: List[Tuple[str, str]] = [] # List of symlinks from merge map - bin_dir = self.spec.prefix.bin - python_prefix = self.extendee_spec.prefix + for src, dst in merge_map.items(): if skip_if_exists and os.path.lexists(dst): continue @@ -168,7 +173,7 @@ def add_files_to_view(self, view, merge_map, skip_if_exists=True): copied_files[(s.st_dev, s.st_ino)] = dst shutil.copy2(src, dst) fs.filter_file( - python_prefix, os.path.abspath(view.get_projection_for_spec(self.spec)), dst + python.prefix, os.path.abspath(view.get_projection_for_spec(self.spec)), dst ) else: view.link(src, dst) @@ -199,14 +204,13 @@ def remove_files_from_view(self, view, merge_map): ignore_namespace = True bin_dir = self.spec.prefix.bin - global_view = self.extendee_spec.prefix == view.get_projection_for_spec(self.spec) to_remove = [] for src, dst in merge_map.items(): if ignore_namespace and namespace_init(dst): continue - if global_view or not fs.path_contains_subdirectory(src, bin_dir): + if not fs.path_contains_subdirectory(src, bin_dir): to_remove.append(dst) else: os.remove(dst) @@ -362,6 +366,12 @@ def list_url(cls) -> Optional[str]: # type: ignore[override] return f"https://pypi.org/simple/{name}/" return None + @property + def python_spec(self): + """Get python-venv if it exists or python otherwise.""" + python, *_ = self.spec.dependencies("python-venv") or self.spec.dependencies("python") + return python + @property def headers(self) -> HeaderList: """Discover header files in platlib.""" @@ -371,8 +381,9 @@ def headers(self) -> HeaderList: # Headers should only be in include or platlib, but no harm in checking purelib too include = self.prefix.join(self.spec["python"].package.include).join(name) - platlib = self.prefix.join(self.spec["python"].package.platlib).join(name) - purelib = self.prefix.join(self.spec["python"].package.purelib).join(name) + python = self.python_spec + platlib = self.prefix.join(python.package.platlib).join(name) + purelib = self.prefix.join(python.package.purelib).join(name) headers_list = map(fs.find_all_headers, [include, platlib, purelib]) headers = functools.reduce(operator.add, headers_list) @@ -391,8 +402,9 @@ def libs(self) -> LibraryList: name = self.spec.name[3:] # Libraries should only be in platlib, but no harm in checking purelib too - platlib = self.prefix.join(self.spec["python"].package.platlib).join(name) - purelib = self.prefix.join(self.spec["python"].package.purelib).join(name) + python = self.python_spec + platlib = self.prefix.join(python.package.platlib).join(name) + purelib = self.prefix.join(python.package.purelib).join(name) find_all_libraries = functools.partial(fs.find_all_libraries, recursive=True) libs_list = map(find_all_libraries, [platlib, purelib]) @@ -549,22 +561,8 @@ def global_options(self, spec: Spec, prefix: Prefix) -> Iterable[str]: def install(self, pkg: PythonPackage, spec: Spec, prefix: Prefix) -> None: """Install everything from build directory.""" - python: Executable = spec["python"].command - # Since we invoke pip with --no-build-isolation, we have to make sure that pip cannot - # execute hooks from user and system site-packages. - if spec["python"].external: - # There are no environment variables to disable the system site-packages, so we use a - # virtual environment instead. The downside of this approach is that pip produces - # incorrect shebangs that refer to the virtual environment, which we have to fix up. - python("-m", "venv", "--without-pip", self._build_venv_path) - pip = self._build_venv_python - else: - # For a Spack managed Python, system site-packages is empty/unused by design, so it - # suffices to disable user site-packages, for which there is an environment variable. - pip = python - pip.add_default_env("PYTHONNOUSERSITE", "1") - pip.add_default_arg("-m") - pip.add_default_arg("pip") + pip = spec["python"].command + pip.add_default_arg("-m", "pip") args = PythonPipBuilder.std_args(pkg) + [f"--prefix={prefix}"] @@ -580,14 +578,6 @@ def install(self, pkg: PythonPackage, spec: Spec, prefix: Prefix) -> None: else: args.append(".") - pip = spec["python"].command - # Hide user packages, since we don't have build isolation. This is - # necessary because pip / setuptools may run hooks from arbitrary - # packages during the build. There is no equivalent variable to hide - # system packages, so this is not reliable for external Python. - pip.add_default_env("PYTHONNOUSERSITE", "1") - pip.add_default_arg("-m") - pip.add_default_arg("pip") with fs.working_dir(self.build_directory): pip(*args) diff --git a/lib/spack/spack/build_systems/rocm.py b/lib/spack/spack/build_systems/rocm.py index a986c5e5b93fc6..8094c90c2e82dd 100644 --- a/lib/spack/spack/build_systems/rocm.py +++ b/lib/spack/spack/build_systems/rocm.py @@ -75,9 +75,12 @@ # does not like its directory structure. # +import os + import spack.variant from spack.directives import conflicts, depends_on, variant from spack.package_base import PackageBase +from spack.util.environment import EnvironmentModifications class ROCmPackage(PackageBase): @@ -154,6 +157,25 @@ def hip_flags(amdgpu_target): archs = ",".join(amdgpu_target) return "--amdgpu-target={0}".format(archs) + def asan_on(self, env: EnvironmentModifications): + llvm_path = self.spec["llvm-amdgpu"].prefix + env.set("CC", llvm_path + "/bin/clang") + env.set("CXX", llvm_path + "/bin/clang++") + env.set("ASAN_OPTIONS", "detect_leaks=0") + + for root, _, files in os.walk(llvm_path): + if "libclang_rt.asan-x86_64.so" in files: + asan_lib_path = root + env.prepend_path("LD_LIBRARY_PATH", asan_lib_path) + if "rhel" in self.spec.os or "sles" in self.spec.os: + SET_DWARF_VERSION_4 = "-gdwarf-5" + else: + SET_DWARF_VERSION_4 = "" + + env.set("CFLAGS", f"-fsanitize=address -shared-libasan -g {SET_DWARF_VERSION_4}") + env.set("CXXFLAGS", f"-fsanitize=address -shared-libasan -g {SET_DWARF_VERSION_4}") + env.set("LDFLAGS", "-Wl,--enable-new-dtags -fuse-ld=lld -fsanitize=address -g -Wl,") + # HIP version vs Architecture # TODO: add a bunch of lines like: diff --git a/lib/spack/spack/caches.py b/lib/spack/spack/caches.py index 19c736748e37e9..14d03a14b36d34 100644 --- a/lib/spack/spack/caches.py +++ b/lib/spack/spack/caches.py @@ -34,6 +34,8 @@ def _misc_cache(): return spack.util.file_cache.FileCache(path) +FileCacheType = Union[spack.util.file_cache.FileCache, llnl.util.lang.Singleton] + #: Spack's cache for small data MISC_CACHE: Union[spack.util.file_cache.FileCache, llnl.util.lang.Singleton] = ( llnl.util.lang.Singleton(_misc_cache) diff --git a/lib/spack/spack/ci.py b/lib/spack/spack/ci.py index 7c2f3f2eb6dbc8..528fa4506356fa 100644 --- a/lib/spack/spack/ci.py +++ b/lib/spack/spack/ci.py @@ -16,12 +16,14 @@ import tempfile import time import zipfile -from collections import namedtuple -from typing import List, Optional +from collections import defaultdict, namedtuple +from typing import Dict, List, Optional, Set, Tuple from urllib.error import HTTPError, URLError from urllib.parse import urlencode from urllib.request import HTTPHandler, Request, build_opener +import ruamel.yaml + import llnl.util.filesystem as fs import llnl.util.tty as tty from llnl.util.lang import memoized @@ -44,6 +46,7 @@ from spack import traverse from spack.error import SpackError from spack.reporters import CDash, CDashConfiguration +from spack.reporters.cdash import SPACK_CDASH_TIMEOUT from spack.reporters.cdash import build_stamp as cdash_build_stamp # See https://docs.gitlab.com/ee/ci/yaml/#retry for descriptions of conditions @@ -70,7 +73,7 @@ JOB_NAME_FORMAT = ( "{name}{@version} {/hash:7} {%compiler.name}{@compiler.version}{arch=architecture}" ) - +IS_WINDOWS = sys.platform == "win32" spack_gpg = spack.main.SpackCommand("gpg") spack_compiler = spack.main.SpackCommand("compiler") @@ -103,7 +106,7 @@ def get_job_name(spec: spack.spec.Spec, build_group: str = ""): job_name = spec.format(JOB_NAME_FORMAT) if build_group: - job_name = "{0} {1}".format(job_name, build_group) + job_name = f"{job_name} {build_group}" return job_name[:255] @@ -113,54 +116,24 @@ def _remove_reserved_tags(tags): return [tag for tag in tags if tag not in SPACK_RESERVED_TAGS] -def _spec_deps_key(s): - return "{0}/{1}".format(s.name, s.dag_hash(7)) - - -def _add_dependency(spec_label, dep_label, deps): - if spec_label == dep_label: - return - if spec_label not in deps: - deps[spec_label] = set() - deps[spec_label].add(dep_label) - - -def _get_spec_dependencies(specs, deps, spec_labels): - spec_deps_obj = _compute_spec_deps(specs) - - if spec_deps_obj: - dependencies = spec_deps_obj["dependencies"] - specs = spec_deps_obj["specs"] +def _spec_ci_label(s): + return f"{s.name}/{s.dag_hash(7)}" - for entry in specs: - spec_labels[entry["label"]] = entry["spec"] - for entry in dependencies: - _add_dependency(entry["spec"], entry["depends"], deps) +PlainNodes = Dict[str, spack.spec.Spec] +PlainEdges = Dict[str, Set[str]] -def stage_spec_jobs(specs): - """Take a set of release specs and generate a list of "stages", where the - jobs in any stage are dependent only on jobs in previous stages. This - allows us to maximize build parallelism within the gitlab-ci framework. +def stage_spec_jobs(specs: List[spack.spec.Spec]) -> Tuple[PlainNodes, PlainEdges, List[Set[str]]]: + """Turn a DAG into a list of stages (set of nodes), the list is ordered topologically, so that + each node in a stage has dependencies only in previous stages. Arguments: - specs (Iterable): Specs to build - - Returns: A tuple of information objects describing the specs, dependencies - and stages: - - spec_labels: A dictionary mapping the spec labels (which are formatted - as pkg-name/hash-prefix) to concrete specs. - - deps: A dictionary where the keys should also have appeared as keys in - the spec_labels dictionary, and the values are the set of - dependencies for that spec. - - stages: An ordered list of sets, each of which contains all the jobs to - built in that stage. The jobs are expressed in the same format as - the keys in the spec_labels and deps objects. + specs: Specs to build + Returns: A tuple (nodes, edges, stages) where ``nodes`` maps labels to specs, ``edges`` maps + labels to a set of labels of dependencies, and ``stages`` is a topologically ordered list + of sets of labels. """ # The convenience method below, "_remove_satisfied_deps()", does not modify @@ -177,17 +150,12 @@ def _remove_satisfied_deps(deps, satisfied_list): return new_deps - deps = {} - spec_labels = {} - - _get_spec_dependencies(specs, deps, spec_labels) + nodes, edges = _extract_dag(specs) - # Save the original deps, as we need to return them at the end of the - # function. In the while loop below, the "dependencies" variable is - # overwritten rather than being modified each time through the loop, - # thus preserving the original value of "deps" saved here. - dependencies = deps - unstaged = set(spec_labels.keys()) + # Save the original edges, as we need to return them at the end of the function. In the loop + # below, the "dependencies" variable is rebound rather than mutated, so "edges" is not mutated. + dependencies = edges + unstaged = set(nodes.keys()) stages = [] while dependencies: @@ -203,7 +171,7 @@ def _remove_satisfied_deps(deps, satisfied_list): if unstaged: stages.append(unstaged.copy()) - return spec_labels, deps, stages + return nodes, edges, stages def _print_staging_summary(spec_labels, stages, mirrors_to_check, rebuild_decisions): @@ -213,7 +181,7 @@ def _print_staging_summary(spec_labels, stages, mirrors_to_check, rebuild_decisi mirrors = spack.mirror.MirrorCollection(mirrors=mirrors_to_check, binary=True) tty.msg("Checked the following mirrors for binaries:") for m in mirrors.values(): - tty.msg(" {0}".format(m.fetch_url)) + tty.msg(f" {m.fetch_url}") tty.msg("Staging summary ([x] means a job needs rebuilding):") for stage_index, stage in enumerate(stages): @@ -235,87 +203,22 @@ def _print_staging_summary(spec_labels, stages, mirrors_to_check, rebuild_decisi tty.msg(msg) -def _compute_spec_deps(spec_list): - """ - Computes all the dependencies for the spec(s) and generates a JSON - object which provides both a list of unique spec names as well as a - comprehensive list of all the edges in the dependency graph. For - example, given a single spec like 'readline@7.0', this function - generates the following JSON object: - - .. code-block:: JSON - - { - "dependencies": [ - { - "depends": "readline/ip6aiun", - "spec": "readline/ip6aiun" - }, - { - "depends": "ncurses/y43rifz", - "spec": "readline/ip6aiun" - }, - { - "depends": "ncurses/y43rifz", - "spec": "readline/ip6aiun" - }, - { - "depends": "pkgconf/eg355zb", - "spec": "ncurses/y43rifz" - }, - { - "depends": "pkgconf/eg355zb", - "spec": "readline/ip6aiun" - } - ], - "specs": [ - { - "spec": "readline@7.0%apple-clang@9.1.0 arch=darwin-highs...", - "label": "readline/ip6aiun" - }, - { - "spec": "ncurses@6.1%apple-clang@9.1.0 arch=darwin-highsi...", - "label": "ncurses/y43rifz" - }, - { - "spec": "pkgconf@1.5.4%apple-clang@9.1.0 arch=darwin-high...", - "label": "pkgconf/eg355zb" - } - ] - } +def _extract_dag(specs: List[spack.spec.Spec]) -> Tuple[PlainNodes, PlainEdges]: + """Extract a sub-DAG as plain old Python objects with external nodes removed.""" + nodes: PlainNodes = {} + edges: PlainEdges = defaultdict(set) - """ - spec_labels = {} + for edge in traverse.traverse_edges(specs, cover="edges"): + if (edge.parent and edge.parent.external) or edge.spec.external: + continue + child_id = _spec_ci_label(edge.spec) + nodes[child_id] = edge.spec + if edge.parent: + parent_id = _spec_ci_label(edge.parent) + nodes[parent_id] = edge.parent + edges[parent_id].add(child_id) - specs = [] - dependencies = [] - - def append_dep(s, d): - dependencies.append({"spec": s, "depends": d}) - - for spec in spec_list: - for s in spec.traverse(deptype="all"): - if s.external: - tty.msg("Will not stage external pkg: {0}".format(s)) - continue - - skey = _spec_deps_key(s) - spec_labels[skey] = s - - for d in s.dependencies(deptype="all"): - dkey = _spec_deps_key(d) - if d.external: - tty.msg("Will not stage external dep: {0}".format(d)) - continue - - append_dep(skey, dkey) - - for spec_label, concrete_spec in spec_labels.items(): - specs.append({"label": spec_label, "spec": concrete_spec}) - - deps_json_obj = {"specs": specs, "dependencies": dependencies} - - return deps_json_obj + return nodes, edges def _spec_matches(spec, match_string): @@ -327,7 +230,7 @@ def _format_job_needs( ): needs_list = [] for dep_job in dep_jobs: - dep_spec_key = _spec_deps_key(dep_job) + dep_spec_key = _spec_ci_label(dep_job) rebuild = rebuild_decisions[dep_spec_key].rebuild if not prune_dag or rebuild: @@ -374,8 +277,8 @@ def get_stack_changed(env_path, rev1="HEAD^", rev2="HEAD"): for path in lines: if ".gitlab-ci.yml" in path or path in env_path: - tty.debug("env represented by {0} changed".format(env_path)) - tty.debug("touched file: {0}".format(path)) + tty.debug(f"env represented by {env_path} changed") + tty.debug(f"touched file: {path}") return True return False @@ -419,7 +322,7 @@ def get_spec_filter_list(env, affected_pkgs, dependent_traverse_depth=None): all_concrete_specs = env.all_specs() tty.debug("All concrete environment specs:") for s in all_concrete_specs: - tty.debug(" {0}/{1}".format(s.name, s.dag_hash()[:7])) + tty.debug(f" {s.name}/{s.dag_hash()[:7]}") affected_pkgs = frozenset(affected_pkgs) env_matches = [s for s in all_concrete_specs if s.name in affected_pkgs] visited = set() @@ -510,7 +413,7 @@ def __is_named(self, section): and if so return the name otherwise return none. """ for _name in self.named_jobs: - keys = ["{0}-job".format(_name), "{0}-job-remove".format(_name)] + keys = [f"{_name}-job", f"{_name}-job-remove"] if any([key for key in keys if key in section]): return _name @@ -525,9 +428,9 @@ def __job_name(name, suffix=""): jname = name if suffix: - jname = "{0}-job{1}".format(name, suffix) + jname = f"{name}-job{suffix}" else: - jname = "{0}-job".format(name) + jname = f"{name}-job" return jname @@ -650,10 +553,9 @@ def generate_gitlab_ci_yaml( env, print_summary, output_file, + *, prune_dag=False, check_index_only=False, - run_optimizer=False, - use_dependencies=False, artifacts_root=None, remote_mirror_override=None, ): @@ -674,12 +576,6 @@ def generate_gitlab_ci_yaml( this mode results in faster yaml generation time). Otherwise, also check each spec directly by url (useful if there is no index or it might be out of date). - run_optimizer (bool): If True, post-process the generated yaml to try - try to reduce the size (attempts to collect repeated configuration - and replace with definitions).) - use_dependencies (bool): If true, use "dependencies" rather than "needs" - ("needs" allows DAG scheduling). Useful if gitlab instance cannot - be configured to handle more than a few "needs" per job. artifacts_root (str): Path where artifacts like logs, environment files (spack.yaml, spack.lock), etc should be written. GitLab requires this to be within the project directory. @@ -739,7 +635,7 @@ def generate_gitlab_ci_yaml( # Requested to prune untouched packages, but assume we won't do that # unless we're actually in a git repo. rev1, rev2 = get_change_revisions() - tty.debug("Got following revisions: rev1={0}, rev2={1}".format(rev1, rev2)) + tty.debug(f"Got following revisions: rev1={rev1}, rev2={rev2}") if rev1 and rev2: # If the stack file itself did not change, proceed with pruning if not get_stack_changed(env.manifest_path, rev1, rev2): @@ -747,13 +643,13 @@ def generate_gitlab_ci_yaml( affected_pkgs = compute_affected_packages(rev1, rev2) tty.debug("affected pkgs:") for p in affected_pkgs: - tty.debug(" {0}".format(p)) + tty.debug(f" {p}") affected_specs = get_spec_filter_list( env, affected_pkgs, dependent_traverse_depth=dependent_depth ) tty.debug("all affected specs:") for s in affected_specs: - tty.debug(" {0}/{1}".format(s.name, s.dag_hash()[:7])) + tty.debug(f" {s.name}/{s.dag_hash()[:7]}") # Allow overriding --prune-dag cli opt with environment variable prune_dag_override = os.environ.get("SPACK_PRUNE_UP_TO_DATE", None) @@ -783,6 +679,22 @@ def generate_gitlab_ci_yaml( "instead.", ) + def ensure_expected_target_path(path): + """Returns passed paths with all Windows path separators exchanged + for posix separators only if copy_only_pipeline is enabled + + This is required as copy_only_pipelines are a unique scenario where + the generate job and child pipelines are run on different platforms. + To make this compatible w/ Windows, we cannot write Windows style path separators + that will be consumed on by the Posix copy job runner. + + TODO (johnwparent): Refactor config + cli read/write to deal only in posix + style paths + """ + if copy_only_pipeline and path: + path = path.replace("\\", "/") + return path + pipeline_mirrors = spack.mirror.MirrorCollection(binary=True) deprecated_mirror_config = False buildcache_destination = None @@ -897,7 +809,8 @@ def generate_gitlab_ci_yaml( cli_scopes = [ os.path.relpath(s.path, concrete_env_dir) for s in cfg.scopes().values() - if isinstance(s, cfg.ImmutableConfigScope) + if not s.writable + and isinstance(s, (cfg.DirectoryConfigScope)) and s.path not in env_includes and os.path.exists(s.path) ] @@ -906,7 +819,7 @@ def generate_gitlab_ci_yaml( if scope not in include_scopes and scope not in env_includes: include_scopes.insert(0, scope) env_includes.extend(include_scopes) - env_yaml_root["spack"]["include"] = env_includes + env_yaml_root["spack"]["include"] = [ensure_expected_target_path(i) for i in env_includes] if "gitlab-ci" in env_yaml_root["spack"] and "ci" not in env_yaml_root["spack"]: env_yaml_root["spack"]["ci"] = env_yaml_root["spack"].pop("gitlab-ci") @@ -978,7 +891,7 @@ def generate_gitlab_ci_yaml( rebuild_decisions = {} for stage_jobs in stages: - stage_name = "stage-{0}".format(stage_id) + stage_name = f"stage-{stage_id}" stage_names.append(stage_name) stage_id += 1 @@ -1009,7 +922,7 @@ def generate_gitlab_ci_yaml( job_object = spack_ci_ir["jobs"][release_spec_dag_hash]["attributes"] if not job_object: - tty.warn("No match found for {0}, skipping it".format(release_spec)) + tty.warn(f"No match found for {release_spec}, skipping it") continue if spack_pipeline_type is not None: @@ -1119,7 +1032,7 @@ def main_script_replacements(cmd): if artifacts_root: job_object["needs"].append( - {"job": generate_job_name, "pipeline": "{0}".format(parent_pipeline_id)} + {"job": generate_job_name, "pipeline": f"{parent_pipeline_id}"} ) # Let downstream jobs know whether the spec needed rebuilding, regardless @@ -1185,19 +1098,17 @@ def main_script_replacements(cmd): if spack_pipeline_type == "spack_pull_request": spack.mirror.remove("ci_shared_pr_mirror", cfg.default_modify_scope()) - tty.debug("{0} build jobs generated in {1} stages".format(job_id, stage_id)) + tty.debug(f"{job_id} build jobs generated in {stage_id} stages") if job_id > 0: - tty.debug( - "The max_needs_job is {0}, with {1} needs".format(max_needs_job, max_length_needs) - ) + tty.debug(f"The max_needs_job is {max_needs_job}, with {max_length_needs} needs") # Use "all_job_names" to populate the build group for this set if cdash_handler and cdash_handler.auth_token: try: cdash_handler.populate_buildgroup(all_job_names) except (SpackError, HTTPError, URLError) as err: - tty.warn("Problem populating buildgroup: {0}".format(err)) + tty.warn(f"Problem populating buildgroup: {err}") else: tty.warn("Unable to populate buildgroup without CDash credentials") @@ -1211,9 +1122,7 @@ def main_script_replacements(cmd): sync_job = copy.deepcopy(spack_ci_ir["jobs"]["copy"]["attributes"]) sync_job["stage"] = "copy" if artifacts_root: - sync_job["needs"] = [ - {"job": generate_job_name, "pipeline": "{0}".format(parent_pipeline_id)} - ] + sync_job["needs"] = [{"job": generate_job_name, "pipeline": f"{parent_pipeline_id}"}] if "variables" not in sync_job: sync_job["variables"] = {} @@ -1230,6 +1139,7 @@ def main_script_replacements(cmd): # TODO: Remove this condition in Spack 0.23 buildcache_source = os.environ.get("SPACK_SOURCE_MIRROR", None) sync_job["variables"]["SPACK_BUILDCACHE_SOURCE"] = buildcache_source + sync_job["dependencies"] = [] output_object["copy"] = sync_job job_id += 1 @@ -1330,6 +1240,9 @@ def main_script_replacements(cmd): "SPACK_REBUILD_EVERYTHING": str(rebuild_everything), "SPACK_REQUIRE_SIGNING": os.environ.get("SPACK_REQUIRE_SIGNING", "False"), } + output_vars = output_object["variables"] + for item, val in output_vars.items(): + output_vars[item] = ensure_expected_target_path(val) # TODO: Remove this block in Spack 0.23 if deprecated_mirror_config and remote_mirror_override: @@ -1348,23 +1261,12 @@ def main_script_replacements(cmd): copy_specs_file = os.path.join( copy_specs_dir, - "copy_{}_specs.json".format(spack_stack_name if spack_stack_name else "rebuilt"), + f"copy_{spack_stack_name if spack_stack_name else 'rebuilt'}_specs.json", ) with open(copy_specs_file, "w") as fd: fd.write(json.dumps(buildcache_copies)) - # TODO(opadron): remove this or refactor - if run_optimizer: - import spack.ci_optimization as ci_opt - - output_object = ci_opt.optimizer(output_object) - - # TODO(opadron): remove this or refactor - if use_dependencies: - import spack.ci_needs_workaround as cinw - - output_object = cinw.needs_to_dependencies(output_object) else: # No jobs were generated noop_job = spack_ci_ir["jobs"]["noop"]["attributes"] @@ -1386,7 +1288,6 @@ def main_script_replacements(cmd): sorted_output = {} for output_key, output_value in sorted(output_object.items()): sorted_output[output_key] = output_value - if known_broken_specs_encountered: tty.error("This pipeline generated hashes known to be broken on develop:") display_broken_spec_messages(broken_specs_url, known_broken_specs_encountered) @@ -1394,8 +1295,11 @@ def main_script_replacements(cmd): if not rebuild_everything: sys.exit(1) - with open(output_file, "w") as outf: - outf.write(syaml.dump(sorted_output, default_flow_style=True)) + # Minimize yaml output size through use of anchors + syaml.anchorify(sorted_output) + + with open(output_file, "w") as f: + ruamel.yaml.YAML().dump(sorted_output, f) def _url_encode_string(input_string): @@ -1440,7 +1344,7 @@ def import_signing_key(base64_signing_key): fd.write(decoded_key) key_import_output = spack_gpg("trust", sign_key_path, output=str) - tty.debug("spack gpg trust {0}".format(sign_key_path)) + tty.debug(f"spack gpg trust {sign_key_path}") tty.debug(key_import_output) # Now print the keys we have for verifying and signing @@ -1466,45 +1370,39 @@ def can_verify_binaries(): return len(gpg_util.public_keys()) >= 1 -def _push_mirror_contents(input_spec, sign_binaries, mirror_url): +def _push_to_build_cache(spec: spack.spec.Spec, sign_binaries: bool, mirror_url: str) -> None: """Unchecked version of the public API, for easier mocking""" - unsigned = not sign_binaries - tty.debug("Creating buildcache ({0})".format("unsigned" if unsigned else "signed")) - push_url = spack.mirror.Mirror.from_url(mirror_url).push_url - return bindist.push(input_spec, push_url, bindist.PushOptions(force=True, unsigned=unsigned)) + bindist.push_or_raise( + spec, + spack.mirror.Mirror.from_url(mirror_url).push_url, + bindist.PushOptions(force=True, unsigned=not sign_binaries), + ) -def push_mirror_contents(input_spec: spack.spec.Spec, mirror_url, sign_binaries): +def push_to_build_cache(spec: spack.spec.Spec, mirror_url: str, sign_binaries: bool) -> bool: """Push one or more binary packages to the mirror. Arguments: - input_spec(spack.spec.Spec): Installed spec to push - mirror_url (str): Base url of target mirror - sign_binaries (bool): If True, spack will attempt to sign binary - package before pushing. + spec: Installed spec to push + mirror_url: URL of target mirror + sign_binaries: If True, spack will attempt to sign binary package before pushing. """ + tty.debug(f"Pushing to build cache ({'signed' if sign_binaries else 'unsigned'})") try: - return _push_mirror_contents(input_spec, sign_binaries, mirror_url) - except Exception as inst: - # If the mirror we're pushing to is on S3 and there's some - # permissions problem, for example, we can't just target - # that exception type here, since users of the - # `spack ci rebuild' may not need or want any dependency - # on boto3. So we use the first non-boto exception type - # in the heirarchy: - # boto3.exceptions.S3UploadFailedError - # boto3.exceptions.Boto3Error - # Exception - # BaseException - # object - err_msg = "Error msg: {0}".format(inst) - if any(x in err_msg for x in ["Access Denied", "InvalidAccessKeyId"]): - tty.msg("Permission problem writing to {0}".format(mirror_url)) - tty.msg(err_msg) + _push_to_build_cache(spec, sign_binaries, mirror_url) + return True + except bindist.PushToBuildCacheError as e: + tty.error(str(e)) + return False + except Exception as e: + # TODO (zackgalbreath): write an adapter for boto3 exceptions so we can catch a specific + # exception instead of parsing str(e)... + msg = str(e) + if any(x in msg for x in ["Access Denied", "InvalidAccessKeyId"]): + tty.error(f"Permission problem writing to {mirror_url}: {msg}") return False - else: - raise inst + raise def remove_other_mirrors(mirrors_to_keep, scope=None): @@ -1531,8 +1429,9 @@ def copy_files_to_artifacts(src, artifacts_dir): try: fs.copy(src, artifacts_dir) except Exception as err: - msg = ("Unable to copy files ({0}) to artifacts {1} due to " "exception: {2}").format( - src, artifacts_dir, str(err) + msg = ( + f"Unable to copy files ({src}) to artifacts {artifacts_dir} due to " + f"exception: {str(err)}" ) tty.warn(msg) @@ -1548,23 +1447,23 @@ def copy_stage_logs_to_artifacts(job_spec: spack.spec.Spec, job_log_dir: str) -> job_spec: spec associated with spack install log job_log_dir: path into which build log should be copied """ - tty.debug("job spec: {0}".format(job_spec)) + tty.debug(f"job spec: {job_spec}") if not job_spec: - msg = "Cannot copy stage logs: job spec ({0}) is required" - tty.error(msg.format(job_spec)) + msg = f"Cannot copy stage logs: job spec ({job_spec}) is required" + tty.error(msg) return try: pkg_cls = spack.repo.PATH.get_pkg_class(job_spec.name) job_pkg = pkg_cls(job_spec) - tty.debug("job package: {0}".format(job_pkg)) + tty.debug(f"job package: {job_pkg}") except AssertionError: - msg = "Cannot copy stage logs: job spec ({0}) must be concrete" - tty.error(msg.format(job_spec)) + msg = f"Cannot copy stage logs: job spec ({job_spec}) must be concrete" + tty.error(msg) return stage_dir = job_pkg.stage.path - tty.debug("stage dir: {0}".format(stage_dir)) + tty.debug(f"stage dir: {stage_dir}") for file in [job_pkg.log_path, job_pkg.env_mods_path, *job_pkg.builder.archive_files]: copy_files_to_artifacts(file, job_log_dir) @@ -1577,15 +1476,21 @@ def copy_test_logs_to_artifacts(test_stage, job_test_dir): test_stage (str): test stage path job_test_dir (str): the destination artifacts test directory """ - tty.debug("test stage: {0}".format(test_stage)) + tty.debug(f"test stage: {test_stage}") if not os.path.exists(test_stage): - msg = "Cannot copy test logs: job test stage ({0}) does not exist" - tty.error(msg.format(test_stage)) + msg = f"Cannot copy test logs: job test stage ({test_stage}) does not exist" + tty.error(msg) return copy_files_to_artifacts(os.path.join(test_stage, "*", "*.txt"), job_test_dir) +def win_quote(quote_str: str) -> str: + if IS_WINDOWS: + quote_str = f'"{quote_str}"' + return quote_str + + def download_and_extract_artifacts(url, work_dir): """Look for gitlab artifacts.zip at the given url, and attempt to download and extract the contents into the given work_dir @@ -1595,7 +1500,7 @@ def download_and_extract_artifacts(url, work_dir): url (str): Complete url to artifacts.zip file work_dir (str): Path to destination where artifacts should be extracted """ - tty.msg("Fetching artifacts from: {0}\n".format(url)) + tty.msg(f"Fetching artifacts from: {url}\n") headers = {"Content-Type": "application/zip"} @@ -1608,11 +1513,11 @@ def download_and_extract_artifacts(url, work_dir): request = Request(url, headers=headers) request.get_method = lambda: "GET" - response = opener.open(request) + response = opener.open(request, timeout=SPACK_CDASH_TIMEOUT) response_code = response.getcode() if response_code != 200: - msg = "Error response code ({0}) in reproduce_ci_job".format(response_code) + msg = f"Error response code ({response_code}) in reproduce_ci_job" raise SpackError(msg) artifacts_zip_path = os.path.join(work_dir, "artifacts.zip") @@ -1642,7 +1547,7 @@ def get_spack_info(): return git_log - return "no git repo, use spack {0}".format(spack.spack_version) + return f"no git repo, use spack {spack.spack_version}" def setup_spack_repro_version(repro_dir, checkout_commit, merge_commit=None): @@ -1665,8 +1570,8 @@ def setup_spack_repro_version(repro_dir, checkout_commit, merge_commit=None): """ # figure out the path to the spack git version being used for the # reproduction - print("checkout_commit: {0}".format(checkout_commit)) - print("merge_commit: {0}".format(merge_commit)) + print(f"checkout_commit: {checkout_commit}") + print(f"merge_commit: {merge_commit}") dot_git_path = os.path.join(spack.paths.prefix, ".git") if not os.path.exists(dot_git_path): @@ -1685,14 +1590,14 @@ def setup_spack_repro_version(repro_dir, checkout_commit, merge_commit=None): git("log", "-1", checkout_commit, output=str, error=os.devnull, fail_on_error=False) if git.returncode != 0: - tty.error("Missing commit: {0}".format(checkout_commit)) + tty.error(f"Missing commit: {checkout_commit}") return False if merge_commit: git("log", "-1", merge_commit, output=str, error=os.devnull, fail_on_error=False) if git.returncode != 0: - tty.error("Missing commit: {0}".format(merge_commit)) + tty.error(f"Missing commit: {merge_commit}") return False # Next attempt to clone your local spack repo into the repro dir @@ -1715,7 +1620,7 @@ def setup_spack_repro_version(repro_dir, checkout_commit, merge_commit=None): ) if git.returncode != 0: - tty.error("Unable to checkout {0}".format(checkout_commit)) + tty.error(f"Unable to checkout {checkout_commit}") tty.msg(co_out) return False @@ -1734,7 +1639,7 @@ def setup_spack_repro_version(repro_dir, checkout_commit, merge_commit=None): ) if git.returncode != 0: - tty.error("Unable to merge {0}".format(merge_commit)) + tty.error(f"Unable to merge {merge_commit}") tty.msg(merge_out) return False @@ -1755,6 +1660,7 @@ def reproduce_ci_job(url, work_dir, autostart, gpg_url, runtime): commands to run to reproduce the build once inside the container. """ work_dir = os.path.realpath(work_dir) + platform_script_ext = "ps1" if IS_WINDOWS else "sh" download_and_extract_artifacts(url, work_dir) gpg_path = None @@ -1765,13 +1671,13 @@ def reproduce_ci_job(url, work_dir, autostart, gpg_url, runtime): lock_file = fs.find(work_dir, "spack.lock")[0] repro_lock_dir = os.path.dirname(lock_file) - tty.debug("Found lock file in: {0}".format(repro_lock_dir)) + tty.debug(f"Found lock file in: {repro_lock_dir}") yaml_files = fs.find(work_dir, ["*.yaml", "*.yml"]) tty.debug("yaml files:") for yaml_file in yaml_files: - tty.debug(" {0}".format(yaml_file)) + tty.debug(f" {yaml_file}") pipeline_yaml = None @@ -1786,10 +1692,10 @@ def reproduce_ci_job(url, work_dir, autostart, gpg_url, runtime): pipeline_yaml = yaml_obj if pipeline_yaml: - tty.debug("\n{0} is likely your pipeline file".format(yf)) + tty.debug(f"\n{yf} is likely your pipeline file") relative_concrete_env_dir = pipeline_yaml["variables"]["SPACK_CONCRETE_ENV_DIR"] - tty.debug("Relative environment path used by cloud job: {0}".format(relative_concrete_env_dir)) + tty.debug(f"Relative environment path used by cloud job: {relative_concrete_env_dir}") # Using the relative concrete environment path found in the generated # pipeline variable above, copy the spack environment files so they'll @@ -1803,10 +1709,11 @@ def reproduce_ci_job(url, work_dir, autostart, gpg_url, runtime): shutil.copyfile(orig_yaml_path, copy_yaml_path) # Find the install script in the unzipped artifacts and make it executable - install_script = fs.find(work_dir, "install.sh")[0] - st = os.stat(install_script) - os.chmod(install_script, st.st_mode | stat.S_IEXEC) - + install_script = fs.find(work_dir, f"install.{platform_script_ext}")[0] + if not IS_WINDOWS: + # pointless on Windows + st = os.stat(install_script) + os.chmod(install_script, st.st_mode | stat.S_IEXEC) # Find the repro details file. This just includes some values we wrote # during `spack ci rebuild` to make reproduction easier. E.g. the job # name is written here so we can easily find the configuration of the @@ -1844,7 +1751,7 @@ def reproduce_ci_job(url, work_dir, autostart, gpg_url, runtime): job_image = job_image_elt["name"] else: job_image = job_image_elt - tty.msg("Job ran with the following image: {0}".format(job_image)) + tty.msg(f"Job ran with the following image: {job_image}") # Because we found this job was run with a docker image, so we will try # to print a "docker run" command that bind-mounts the directory where @@ -1919,65 +1826,75 @@ def reproduce_ci_job(url, work_dir, autostart, gpg_url, runtime): job_tags = None if "tags" in job_yaml: job_tags = job_yaml["tags"] - tty.msg("Job ran with the following tags: {0}".format(job_tags)) + tty.msg(f"Job ran with the following tags: {job_tags}") entrypoint_script = [ ["git", "config", "--global", "--add", "safe.directory", mount_as_dir], - [".", os.path.join(mount_as_dir if job_image else work_dir, "share/spack/setup-env.sh")], + [ + ".", + os.path.join( + mount_as_dir if job_image else work_dir, + f"share/spack/setup-env.{platform_script_ext}", + ), + ], ["spack", "gpg", "trust", mounted_gpg_path if job_image else gpg_path] if gpg_path else [], ["spack", "env", "activate", mounted_env_dir if job_image else repro_dir], - [os.path.join(mounted_repro_dir, "install.sh") if job_image else install_script], + [ + ( + os.path.join(mounted_repro_dir, f"install.{platform_script_ext}") + if job_image + else install_script + ) + ], ] - + entry_script = os.path.join(mounted_workdir, f"entrypoint.{platform_script_ext}") inst_list = [] # Finally, print out some instructions to reproduce the build if job_image: # Allow interactive - entrypoint_script.extend( - [ - [ - "echo", - "Re-run install script using:\n\t{0}".format( - os.path.join(mounted_repro_dir, "install.sh") - if job_image - else install_script - ), - ], - # Allow interactive - ["exec", "$@"], - ] + install_mechanism = ( + os.path.join(mounted_repro_dir, f"install.{platform_script_ext}") + if job_image + else install_script ) + entrypoint_script.append(["echo", f"Re-run install script using:\n\t{install_mechanism}"]) + # Allow interactive + if IS_WINDOWS: + entrypoint_script.append(["&", "($args -Join ' ')", "-NoExit"]) + else: + entrypoint_script.append(["exec", "$@"]) + process_command( "entrypoint", entrypoint_script, work_dir, run=False, exit_on_failure=False ) docker_command = [ - [ - runtime, - "run", - "-i", - "-t", - "--rm", - "--name", - "spack_reproducer", - "-v", - ":".join([work_dir, mounted_workdir, "Z"]), - "-v", - ":".join( - [ - os.path.join(work_dir, "jobs_scratch_dir"), - os.path.join(mount_as_dir, "jobs_scratch_dir"), - "Z", - ] - ), - "-v", - ":".join([os.path.join(work_dir, "spack"), mount_as_dir, "Z"]), - "--entrypoint", - os.path.join(mounted_workdir, "entrypoint.sh"), - job_image, - "bash", - ] + runtime, + "run", + "-i", + "-t", + "--rm", + "--name", + "spack_reproducer", + "-v", + ":".join([work_dir, mounted_workdir, "Z"]), + "-v", + ":".join( + [ + os.path.join(work_dir, "jobs_scratch_dir"), + os.path.join(mount_as_dir, "jobs_scratch_dir"), + "Z", + ] + ), + "-v", + ":".join([os.path.join(work_dir, "spack"), mount_as_dir, "Z"]), + "--entrypoint", ] + if IS_WINDOWS: + docker_command.extend(["powershell.exe", job_image, entry_script, "powershell.exe"]) + else: + docker_command.extend([entry_script, job_image, "bash"]) + docker_command = [docker_command] autostart = autostart and setup_result process_command("start", docker_command, work_dir, run=autostart) @@ -1986,22 +1903,26 @@ def reproduce_ci_job(url, work_dir, autostart, gpg_url, runtime): inst_list.extend( [ " - Start the docker container install", - " $ {0}/start.sh".format(work_dir), + f" $ {work_dir}/start.{platform_script_ext}", ] ) else: - process_command("reproducer", entrypoint_script, work_dir, run=False) + autostart = autostart and setup_result + process_command("reproducer", entrypoint_script, work_dir, run=autostart) inst_list.append("\nOnce on the tagged runner:\n\n") inst_list.extent( - [" - Run the reproducer script", " $ {0}/reproducer.sh".format(work_dir)] + [ + " - Run the reproducer script", + f" $ {work_dir}/reproducer.{platform_script_ext}", + ] ) if not setup_result: inst_list.append("\n - Clone spack and acquire tested commit") - inst_list.append("\n {0}\n".format(spack_info)) + inst_list.append(f"\n {spack_info}\n") inst_list.append("\n") - inst_list.append("\n Path to clone spack: {0}/spack\n\n".format(work_dir)) + inst_list.append(f"\n Path to clone spack: {work_dir}/spack\n\n") tty.msg("".join(inst_list)) @@ -2020,50 +1941,78 @@ def process_command(name, commands, repro_dir, run=True, exit_on_failure=True): Returns: the exit code from processing the command """ - tty.debug("spack {0} arguments: {1}".format(name, commands)) + tty.debug(f"spack {name} arguments: {commands}") if len(commands) == 0 or isinstance(commands[0], str): commands = [commands] - # Create a string [command 1] && [command 2] && ... && [command n] with commands - # quoted using double quotes. - args_to_string = lambda args: " ".join('"{}"'.format(arg) for arg in args) - full_command = " \n ".join(map(args_to_string, commands)) - - # Write the command to a shell script - script = "{0}.sh".format(name) - with open(script, "w") as fd: - fd.write("#!/bin/sh\n\n") - fd.write("\n# spack {0} command\n".format(name)) + def compose_command_err_handling(args): + if not IS_WINDOWS: + args = [f'"{arg}"' for arg in args] + arg_str = " ".join(args) + result = arg_str + "\n" + # ErrorActionPreference will handle PWSH commandlets (Spack calls), + # but we need to handle EXEs (git, etc) ourselves + catch_exe_failure = ( + """ +if ($LASTEXITCODE -ne 0){{ + throw 'Command {} has failed' +}} +""" + if IS_WINDOWS + else "" + ) + if exit_on_failure and catch_exe_failure: + result += catch_exe_failure.format(arg_str) + return result + + # Create a string [command 1] \n [command 2] \n ... \n [command n] with + # commands composed into a platform dependent shell script, pwsh on Windows, + full_command = "\n".join(map(compose_command_err_handling, commands)) + # Write the command to a python script + if IS_WINDOWS: + script = f"{name}.ps1" + script_content = [f"\n# spack {name} command\n"] if exit_on_failure: - fd.write("set -e\n") + script_content.append('$ErrorActionPreference = "Stop"\n') if os.environ.get("SPACK_VERBOSE_SCRIPT"): - fd.write("set -x\n") - fd.write(full_command) - fd.write("\n") + script_content.append("Set-PSDebug -Trace 2\n") + else: + script = f"{name}.sh" + script_content = ["#!/bin/sh\n\n", f"\n# spack {name} command\n"] + if exit_on_failure: + script_content.append("set -e\n") + if os.environ.get("SPACK_VERBOSE_SCRIPT"): + script_content.append("set -x\n") + script_content.append(full_command) + script_content.append("\n") - st = os.stat(script) - os.chmod(script, st.st_mode | stat.S_IEXEC) + with open(script, "w") as fd: + for line in script_content: + fd.write(line) copy_path = os.path.join(repro_dir, script) shutil.copyfile(script, copy_path) - st = os.stat(copy_path) - os.chmod(copy_path, st.st_mode | stat.S_IEXEC) + if not IS_WINDOWS: + st = os.stat(copy_path) + os.chmod(copy_path, st.st_mode | stat.S_IEXEC) - # Run the generated install.sh shell script as if it were being run in + # Run the generated shell script as if it were being run in # a login shell. exit_code = None if run: try: - cmd_process = subprocess.Popen(["/bin/sh", "./{0}".format(script)]) + # We use sh as executor on Linux like platforms, pwsh on Windows + interpreter = "powershell.exe" if IS_WINDOWS else "/bin/sh" + cmd_process = subprocess.Popen([interpreter, f"./{script}"]) cmd_process.wait() exit_code = cmd_process.returncode except (ValueError, subprocess.CalledProcessError, OSError) as err: - tty.error("Encountered error running {0} script".format(name)) + tty.error(f"Encountered error running {name} script") tty.error(err) exit_code = 1 - tty.debug("spack {0} exited {1}".format(name, exit_code)) + tty.debug(f"spack {name} exited {exit_code}") else: # Delete the script, it is copied to the destination dir os.remove(script) @@ -2088,7 +2037,7 @@ def create_buildcache( for mirror_url in destination_mirror_urls: results.append( PushResult( - success=push_mirror_contents(input_spec, mirror_url, sign_binaries), url=mirror_url + success=push_to_build_cache(input_spec, mirror_url, sign_binaries), url=mirror_url ) ) @@ -2122,7 +2071,7 @@ def write_broken_spec(url, pkg_name, stack_name, job_url, pipeline_url, spec_dic # If there is an S3 error (e.g., access denied or connection # error), the first non boto-specific class in the exception # hierarchy is Exception. Just print a warning and return - msg = "Error writing to broken specs list {0}: {1}".format(url, err) + msg = f"Error writing to broken specs list {url}: {err}" tty.warn(msg) finally: shutil.rmtree(tmpdir) @@ -2135,7 +2084,7 @@ def read_broken_spec(broken_spec_url): try: _, _, fs = web_util.read_from_url(broken_spec_url) except (URLError, web_util.SpackWebError, HTTPError): - tty.warn("Unable to read broken spec from {0}".format(broken_spec_url)) + tty.warn(f"Unable to read broken spec from {broken_spec_url}") return None broken_spec_contents = codecs.getreader("utf-8")(fs).read() @@ -2150,14 +2099,14 @@ def display_broken_spec_messages(base_url, hashes): for spec_hash, broken_spec in [tup for tup in broken_specs if tup[1]]: details = broken_spec["broken-spec"] if "job-name" in details: - item_name = "{0}/{1}".format(details["job-name"], spec_hash[:7]) + item_name = f"{details['job-name']}/{spec_hash[:7]}" else: item_name = spec_hash if "job-stack" in details: - item_name = "{0} (in stack {1})".format(item_name, details["job-stack"]) + item_name = f"{item_name} (in stack {details['job-stack']})" - msg = " {0} was reported broken here: {1}".format(item_name, details["job-url"]) + msg = f" {item_name} was reported broken here: {details['job-url']}" tty.msg(msg) @@ -2180,7 +2129,7 @@ def run_standalone_tests(**kwargs): log_file = kwargs.get("log_file") if cdash and log_file: - tty.msg("The test log file {0} option is ignored with CDash reporting".format(log_file)) + tty.msg(f"The test log file {log_file} option is ignored with CDash reporting") log_file = None # Error out but do NOT terminate if there are missing required arguments. @@ -2206,10 +2155,10 @@ def run_standalone_tests(**kwargs): test_args.extend(["--log-file", log_file]) test_args.append(job_spec.name) - tty.debug("Running {0} stand-alone tests".format(job_spec.name)) + tty.debug(f"Running {job_spec.name} stand-alone tests") exit_code = process_command("test", test_args, repro_dir) - tty.debug("spack test exited {0}".format(exit_code)) + tty.debug(f"spack test exited {exit_code}") class CDashHandler: @@ -2232,7 +2181,7 @@ def __init__(self, ci_cdash): # append runner description to the site if available runner = os.environ.get("CI_RUNNER_DESCRIPTION") if runner: - self.site += " ({0})".format(runner) + self.site += f" ({runner})" # track current spec, if any self.current_spec = None @@ -2240,13 +2189,13 @@ def __init__(self, ci_cdash): def args(self): return [ "--cdash-upload-url", - self.upload_url, + win_quote(self.upload_url), "--cdash-build", - self.build_name, + win_quote(self.build_name), "--cdash-site", - self.site, + win_quote(self.site), "--cdash-buildstamp", - self.build_stamp, + win_quote(self.build_stamp), ] @property # type: ignore @@ -2260,21 +2209,13 @@ def build_name(self): Returns: (str) current spec's CDash build name.""" spec = self.current_spec if spec: - build_name = "{0}@{1}%{2} hash={3} arch={4} ({5})".format( - spec.name, - spec.version, - spec.compiler, - spec.dag_hash(), - spec.architecture, - self.build_group, - ) - tty.debug( - "Generated CDash build name ({0}) from the {1}".format(build_name, spec.name) - ) + build_name = f"{spec.name}@{spec.version}%{spec.compiler} \ +hash={spec.dag_hash()} arch={spec.architecture} ({self.build_group})" + tty.debug(f"Generated CDash build name ({build_name}) from the {spec.name}") return build_name build_name = os.environ.get("SPACK_CDASH_BUILD_NAME") - tty.debug("Using CDash build name ({0}) from the environment".format(build_name)) + tty.debug(f"Using CDash build name ({build_name}) from the environment") return build_name @property # type: ignore @@ -2288,25 +2229,25 @@ def build_stamp(self): Returns: (str) current CDash build stamp""" build_stamp = os.environ.get("SPACK_CDASH_BUILD_STAMP") if build_stamp: - tty.debug("Using build stamp ({0}) from the environment".format(build_stamp)) + tty.debug(f"Using build stamp ({build_stamp}) from the environment") return build_stamp build_stamp = cdash_build_stamp(self.build_group, time.time()) - tty.debug("Generated new build stamp ({0})".format(build_stamp)) + tty.debug(f"Generated new build stamp ({build_stamp})") return build_stamp @property # type: ignore @memoized def project_enc(self): - tty.debug("Encoding project ({0}): {1})".format(type(self.project), self.project)) + tty.debug(f"Encoding project ({type(self.project)}): {self.project})") encode = urlencode({"project": self.project}) index = encode.find("=") + 1 return encode[index:] @property def upload_url(self): - url_format = "{0}/submit.php?project={1}" - return url_format.format(self.url, self.project_enc) + url_format = f"{self.url}/submit.php?project={self.project_enc}" + return url_format def copy_test_results(self, source, dest): """Copy test results to artifacts directory.""" @@ -2320,11 +2261,11 @@ def create_buildgroup(self, opener, headers, url, group_name, group_type): request = Request(url, data=enc_data, headers=headers) - response = opener.open(request) + response = opener.open(request, timeout=SPACK_CDASH_TIMEOUT) response_code = response.getcode() if response_code not in [200, 201]: - msg = "Creating buildgroup failed (response code = {0})".format(response_code) + msg = f"Creating buildgroup failed (response code = {response_code})" tty.warn(msg) return None @@ -2335,10 +2276,10 @@ def create_buildgroup(self, opener, headers, url, group_name, group_type): return build_group_id def populate_buildgroup(self, job_names): - url = "{0}/api/v1/buildgroup.php".format(self.url) + url = f"{self.url}/api/v1/buildgroup.php" headers = { - "Authorization": "Bearer {0}".format(self.auth_token), + "Authorization": f"Bearer {self.auth_token}", "Content-Type": "application/json", } @@ -2346,11 +2287,11 @@ def populate_buildgroup(self, job_names): parent_group_id = self.create_buildgroup(opener, headers, url, self.build_group, "Daily") group_id = self.create_buildgroup( - opener, headers, url, "Latest {0}".format(self.build_group), "Latest" + opener, headers, url, f"Latest {self.build_group}", "Latest" ) if not parent_group_id or not group_id: - msg = "Failed to create or retrieve buildgroups for {0}".format(self.build_group) + msg = f"Failed to create or retrieve buildgroups for {self.build_group}" tty.warn(msg) return @@ -2366,11 +2307,11 @@ def populate_buildgroup(self, job_names): request = Request(url, data=enc_data, headers=headers) request.get_method = lambda: "PUT" - response = opener.open(request) + response = opener.open(request, timeout=SPACK_CDASH_TIMEOUT) response_code = response.getcode() if response_code != 200: - msg = "Error response code ({0}) in populate_buildgroup".format(response_code) + msg = f"Error response code ({response_code}) in populate_buildgroup" tty.warn(msg) def report_skipped(self, spec: spack.spec.Spec, report_dir: str, reason: Optional[str]): diff --git a/lib/spack/spack/ci_needs_workaround.py b/lib/spack/spack/ci_needs_workaround.py deleted file mode 100644 index b89de48f8f5290..00000000000000 --- a/lib/spack/spack/ci_needs_workaround.py +++ /dev/null @@ -1,34 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -import collections.abc - -get_job_name = lambda needs_entry: ( - needs_entry.get("job") - if (isinstance(needs_entry, collections.abc.Mapping) and needs_entry.get("artifacts", True)) - else needs_entry if isinstance(needs_entry, str) else None -) - - -def convert_job(job_entry): - if not isinstance(job_entry, collections.abc.Mapping): - return job_entry - - needs = job_entry.get("needs") - if needs is None: - return job_entry - - new_job = {} - new_job.update(job_entry) - del new_job["needs"] - - new_job["dependencies"] = list( - filter((lambda x: x is not None), (get_job_name(needs_entry) for needs_entry in needs)) - ) - - return new_job - - -def needs_to_dependencies(yaml): - return dict((k, convert_job(v)) for k, v in yaml.items()) diff --git a/lib/spack/spack/ci_optimization.py b/lib/spack/spack/ci_optimization.py deleted file mode 100644 index 7d799fc907e172..00000000000000 --- a/lib/spack/spack/ci_optimization.py +++ /dev/null @@ -1,363 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -import collections -import collections.abc -import copy -import hashlib - -import spack.util.spack_yaml as syaml - - -def sort_yaml_obj(obj): - if isinstance(obj, collections.abc.Mapping): - return syaml.syaml_dict( - (k, sort_yaml_obj(v)) for k, v in sorted(obj.items(), key=(lambda item: str(item[0]))) - ) - - if isinstance(obj, collections.abc.Sequence) and not isinstance(obj, str): - return syaml.syaml_list(sort_yaml_obj(x) for x in obj) - - return obj - - -def matches(obj, proto): - """Returns True if the test object "obj" matches the prototype object - "proto". - - If obj and proto are mappings, obj matches proto if (key in obj) and - (obj[key] matches proto[key]) for every key in proto. - - If obj and proto are sequences, obj matches proto if they are of the same - length and (a matches b) for every (a,b) in zip(obj, proto). - - Otherwise, obj matches proto if obj == proto. - - Precondition: proto must not have any reference cycles - """ - if isinstance(obj, collections.abc.Mapping): - if not isinstance(proto, collections.abc.Mapping): - return False - - return all((key in obj and matches(obj[key], val)) for key, val in proto.items()) - - if isinstance(obj, collections.abc.Sequence) and not isinstance(obj, str): - if not (isinstance(proto, collections.abc.Sequence) and not isinstance(proto, str)): - return False - - if len(obj) != len(proto): - return False - - return all(matches(obj[index], val) for index, val in enumerate(proto)) - - return obj == proto - - -def subkeys(obj, proto): - """Returns the test mapping "obj" after factoring out the items it has in - common with the prototype mapping "proto". - - Consider a recursive merge operation, merge(a, b) on mappings a and b, that - returns a mapping, m, whose keys are the union of the keys of a and b, and - for every such key, "k", its corresponding value is: - - - merge(a[key], b[key]) if a[key] and b[key] are mappings, or - - b[key] if (key in b) and not matches(a[key], b[key]), - or - - a[key] otherwise - - - If obj and proto are mappings, the returned object is the smallest object, - "a", such that merge(a, proto) matches obj. - - Otherwise, obj is returned. - """ - if not ( - isinstance(obj, collections.abc.Mapping) and isinstance(proto, collections.abc.Mapping) - ): - return obj - - new_obj = {} - for key, value in obj.items(): - if key not in proto: - new_obj[key] = value - continue - - if matches(value, proto[key]) and matches(proto[key], value): - continue - - if isinstance(value, collections.abc.Mapping): - new_obj[key] = subkeys(value, proto[key]) - continue - - new_obj[key] = value - - return new_obj - - -def add_extends(yaml, key): - """Modifies the given object "yaml" so that it includes an "extends" key - whose value features "key". - - If "extends" is not in yaml, then yaml is modified such that - yaml["extends"] == key. - - If yaml["extends"] is a str, then yaml is modified such that - yaml["extends"] == [yaml["extends"], key] - - If yaml["extends"] is a list that does not include key, then key is - appended to the list. - - Otherwise, yaml is left unchanged. - """ - - has_key = "extends" in yaml - extends = yaml.get("extends") - - if has_key and not isinstance(extends, (str, collections.abc.Sequence)): - return - - if extends is None: - yaml["extends"] = key - return - - if isinstance(extends, str): - if extends != key: - yaml["extends"] = [extends, key] - return - - if key not in extends: - extends.append(key) - - -def common_subobject(yaml, sub): - """Factor prototype object "sub" out of the values of mapping "yaml". - - Consider a modified copy of yaml, "new", where for each key, "key" in yaml: - - - If yaml[key] matches sub, then new[key] = subkeys(yaml[key], sub). - - Otherwise, new[key] = yaml[key]. - - If the above match criteria is not satisfied for any such key, then (yaml, - None) is returned. The yaml object is returned unchanged. - - Otherwise, each matching value in new is modified as in - add_extends(new[key], common_key), and then new[common_key] is set to sub. - The common_key value is chosen such that it does not match any preexisting - key in new. In this case, (new, common_key) is returned. - """ - match_list = set(k for k, v in yaml.items() if matches(v, sub)) - - if not match_list: - return yaml, None - - common_prefix = ".c" - common_index = 0 - - while True: - common_key = "".join((common_prefix, str(common_index))) - if common_key not in yaml: - break - common_index += 1 - - new_yaml = {} - - for key, val in yaml.items(): - new_yaml[key] = copy.deepcopy(val) - - if not matches(val, sub): - continue - - new_yaml[key] = subkeys(new_yaml[key], sub) - add_extends(new_yaml[key], common_key) - - new_yaml[common_key] = sub - - return new_yaml, common_key - - -def print_delta(name, old, new, applied=None): - delta = new - old - reldelta = (1000 * delta) // old - reldelta = (reldelta // 10, reldelta % 10) - - if applied is None: - applied = new <= old - - print( - "\n".join( - ( - "{0} {1}:", - " before: {2: 10d}", - " after : {3: 10d}", - " delta : {4:+10d} ({5:=+3d}.{6}%)", - ) - ).format(name, ("+" if applied else "x"), old, new, delta, reldelta[0], reldelta[1]) - ) - - -def try_optimization_pass(name, yaml, optimization_pass, *args, **kwargs): - """Try applying an optimization pass and return information about the - result - - "name" is a string describing the nature of the pass. If it is a non-empty - string, summary statistics are also printed to stdout. - - "yaml" is the object to apply the pass to. - - "optimization_pass" is the function implementing the pass to be applied. - - "args" and "kwargs" are the additional arguments to pass to optimization - pass. The pass is applied as - - >>> (new_yaml, *other_results) = optimization_pass(yaml, *args, **kwargs) - - The pass's results are greedily rejected if it does not modify the original - yaml document, or if it produces a yaml document that serializes to a - larger string. - - Returns (new_yaml, yaml, applied, other_results) if applied, or - (yaml, new_yaml, applied, other_results) otherwise. - """ - result = optimization_pass(yaml, *args, **kwargs) - new_yaml, other_results = result[0], result[1:] - - if new_yaml is yaml: - # pass was not applied - return (yaml, new_yaml, False, other_results) - - pre_size = len(syaml.dump_config(sort_yaml_obj(yaml), default_flow_style=True)) - post_size = len(syaml.dump_config(sort_yaml_obj(new_yaml), default_flow_style=True)) - - # pass makes the size worse: not applying - applied = post_size <= pre_size - if applied: - yaml, new_yaml = new_yaml, yaml - - if name: - print_delta(name, pre_size, post_size, applied) - - return (yaml, new_yaml, applied, other_results) - - -def build_histogram(iterator, key): - """Builds a histogram of values given an iterable of mappings and a key. - - For each mapping "m" with key "key" in iterator, the value m[key] is - considered. - - Returns a list of tuples (hash, count, proportion, value), where - - - "hash" is a sha1sum hash of the value. - - "count" is the number of occurences of values that hash to "hash". - - "proportion" is the proportion of all values considered above that - hash to "hash". - - "value" is one of the values considered above that hash to "hash". - Which value is chosen when multiple values hash to the same "hash" is - undefined. - - The list is sorted in descending order by count, yielding the most - frequently occuring hashes first. - """ - buckets = collections.defaultdict(int) - values = {} - - num_objects = 0 - for obj in iterator: - num_objects += 1 - - try: - val = obj[key] - except (KeyError, TypeError): - continue - - value_hash = hashlib.sha1() - value_hash.update(syaml.dump_config(sort_yaml_obj(val)).encode()) - value_hash = value_hash.hexdigest() - - buckets[value_hash] += 1 - values[value_hash] = val - - return [ - (h, buckets[h], float(buckets[h]) / num_objects, values[h]) - for h in sorted(buckets.keys(), key=lambda k: -buckets[k]) - ] - - -def optimizer(yaml): - original_size = len(syaml.dump_config(sort_yaml_obj(yaml), default_flow_style=True)) - - # try factoring out commonly repeated portions - common_job = { - "variables": {"SPACK_COMPILER_ACTION": "NONE"}, - "after_script": ['rm -rf "./spack"'], - "artifacts": {"paths": ["jobs_scratch_dir", "cdash_report"], "when": "always"}, - } - - # look for a list of tags that appear frequently - _, count, proportion, tags = next(iter(build_histogram(yaml.values(), "tags")), (None,) * 4) - - # If a list of tags is found, and there are more than one job that uses it, - # *and* the jobs that do use it represent at least 70% of all jobs, then - # add the list to the prototype object. - if tags and count > 1 and proportion >= 0.70: - common_job["tags"] = tags - - # apply common object factorization - yaml, other, applied, rest = try_optimization_pass( - "general common object factorization", yaml, common_subobject, common_job - ) - - # look for a common script, and try factoring that out - _, count, proportion, script = next( - iter(build_histogram(yaml.values(), "script")), (None,) * 4 - ) - - if script and count > 1 and proportion >= 0.70: - yaml, other, applied, rest = try_optimization_pass( - "script factorization", yaml, common_subobject, {"script": script} - ) - - # look for a common before_script, and try factoring that out - _, count, proportion, script = next( - iter(build_histogram(yaml.values(), "before_script")), (None,) * 4 - ) - - if script and count > 1 and proportion >= 0.70: - yaml, other, applied, rest = try_optimization_pass( - "before_script factorization", yaml, common_subobject, {"before_script": script} - ) - - # Look specifically for the SPACK_ROOT_SPEC environment variables. - # Try to factor them out. - h = build_histogram( - (getattr(val, "get", lambda *args: {})("variables") for val in yaml.values()), - "SPACK_ROOT_SPEC", - ) - - # In this case, we try to factor out *all* instances of the SPACK_ROOT_SPEC - # environment variable; not just the one that appears with the greatest - # frequency. We only require that more than 1 job uses a given instance's - # value, because we expect the value to be very large, and so expect even - # few-to-one factorizations to yield large space savings. - counter = 0 - for _, count, proportion, spec in h: - if count <= 1: - continue - - counter += 1 - - yaml, other, applied, rest = try_optimization_pass( - "SPACK_ROOT_SPEC factorization ({count})".format(count=counter), - yaml, - common_subobject, - {"variables": {"SPACK_ROOT_SPEC": spec}}, - ) - - new_size = len(syaml.dump_config(sort_yaml_obj(yaml), default_flow_style=True)) - - print("\n") - print_delta("overall summary", original_size, new_size) - print("\n") - return yaml diff --git a/lib/spack/spack/cmd/__init__.py b/lib/spack/spack/cmd/__init__.py index b30c6360d9fc5f..00e30a551df7e5 100644 --- a/lib/spack/spack/cmd/__init__.py +++ b/lib/spack/spack/cmd/__init__.py @@ -334,9 +334,9 @@ def display_specs(specs, args=None, **kwargs): variants (bool): Show variants with specs indent (int): indent each line this much groups (bool): display specs grouped by arch/compiler (default True) - decorators (dict): dictionary mappng specs to decorators - header_callback (typing.Callable): called at start of arch/compiler groups + decorator (typing.Callable): function to call to decorate specs all_headers (bool): show headers even when arch/compiler aren't defined + status_fn (typing.Callable): if provided, prepend install-status info output (typing.IO): A file object to write to. Default is ``sys.stdout`` """ @@ -360,6 +360,7 @@ def get_arg(name, default=None): groups = get_arg("groups", True) all_headers = get_arg("all_headers", False) output = get_arg("output", sys.stdout) + status_fn = get_arg("status_fn", None) decorator = get_arg("decorator", None) if decorator is None: @@ -384,15 +385,20 @@ def get_arg(name, default=None): vfmt = "{variants}" if variants else "" format_string = nfmt + "{@version}" + ffmt + vfmt - transform = {"package": decorator, "fullpackage": decorator} - def fmt(s, depth=0): """Formatter function for all output specs""" string = "" + + if status_fn: + # This was copied from spec.tree's colorization logic + # then shortened because it seems like status_fn should + # always return an InstallStatus + string += colorize(status_fn(s).value) + if hashes: string += gray_hash(s, hlen) + " " string += depth * " " - string += s.cformat(format_string, transform=transform) + string += decorator(s, s.cformat(format_string)) return string def format_list(specs): @@ -447,11 +453,11 @@ def format_list(specs): def filter_loaded_specs(specs): """Filter a list of specs returning only those that are currently loaded.""" - hashes = os.environ.get(uenv.spack_loaded_hashes_var, "").split(":") + hashes = os.environ.get(uenv.spack_loaded_hashes_var, "").split(os.pathsep) return [x for x in specs if x.dag_hash() in hashes] -def print_how_many_pkgs(specs, pkg_type=""): +def print_how_many_pkgs(specs, pkg_type="", suffix=""): """Given a list of specs, this will print a message about how many specs are in that list. @@ -462,7 +468,7 @@ def print_how_many_pkgs(specs, pkg_type=""): category, e.g. if pkg_type is "installed" then the message would be "3 installed packages" """ - tty.msg("%s" % llnl.string.plural(len(specs), pkg_type + " package")) + tty.msg("%s" % llnl.string.plural(len(specs), pkg_type + " package") + suffix) def spack_is_git_repo(): diff --git a/lib/spack/spack/cmd/audit.py b/lib/spack/spack/cmd/audit.py index c8cef494ef749b..77bbbc5d82b7d4 100644 --- a/lib/spack/spack/cmd/audit.py +++ b/lib/spack/spack/cmd/audit.py @@ -84,7 +84,7 @@ def externals(parser, args): return pkgs = args.name or spack.repo.PATH.all_package_names() - reports = spack.audit.run_group(args.subcommand, pkgs=pkgs) + reports = spack.audit.run_group(args.subcommand, pkgs=pkgs, debug_log=tty.debug) _process_reports(reports) diff --git a/lib/spack/spack/cmd/bootstrap.py b/lib/spack/spack/cmd/bootstrap.py index 5221a980c78b3a..c321b1213093be 100644 --- a/lib/spack/spack/cmd/bootstrap.py +++ b/lib/spack/spack/cmd/bootstrap.py @@ -165,7 +165,7 @@ def _reset(args): if not ok_to_continue: raise RuntimeError("Aborting") - for scope in spack.config.CONFIG.file_scopes: + for scope in spack.config.CONFIG.writable_scopes: # The default scope should stay untouched if scope.name == "defaults": continue diff --git a/lib/spack/spack/cmd/buildcache.py b/lib/spack/spack/cmd/buildcache.py index ac540d7314593c..4464742903eea5 100644 --- a/lib/spack/spack/cmd/buildcache.py +++ b/lib/spack/spack/cmd/buildcache.py @@ -13,7 +13,6 @@ import shutil import sys import tempfile -import urllib.request from typing import Dict, List, Optional, Tuple, Union import llnl.util.tty as tty @@ -54,6 +53,7 @@ from spack.oci.oci import ( copy_missing_layers_with_retry, get_manifest_and_config_with_retry, + list_tags, upload_blob_with_retry, upload_manifest_with_retry, ) @@ -70,12 +70,6 @@ def setup_parser(subparser: argparse.ArgumentParser): push = subparsers.add_parser("push", aliases=["create"], help=push_fn.__doc__) push.add_argument("-f", "--force", action="store_true", help="overwrite tarball if it exists") - push.add_argument( - "--allow-root", - "-a", - action="store_true", - help="allow install root string in binary files after RPATH substitution", - ) push_sign = push.add_mutually_exclusive_group(required=False) push_sign.add_argument( "--unsigned", @@ -133,6 +127,11 @@ def setup_parser(subparser: argparse.ArgumentParser): help="when pushing to an OCI registry, tag an image containing all root specs and their " "runtime dependencies", ) + push.add_argument( + "--private", + action="store_true", + help="for a private mirror, include non-redistributable packages", + ) arguments.add_common_arguments(push, ["specs", "jobs"]) push.set_defaults(func=push_fn) @@ -185,10 +184,6 @@ def setup_parser(subparser: argparse.ArgumentParser): keys.add_argument("-f", "--force", action="store_true", help="force new download of keys") keys.set_defaults(func=keys_fn) - preview = subparsers.add_parser("preview", help=preview_fn.__doc__) - arguments.add_common_arguments(preview, ["installed_specs"]) - preview.set_defaults(func=preview_fn) - # Check if binaries need to be rebuilt on remote mirror check = subparsers.add_parser("check", help=check_fn.__doc__) check.add_argument( @@ -275,23 +270,37 @@ def setup_parser(subparser: argparse.ArgumentParser): # Sync buildcache entries from one mirror to another sync = subparsers.add_parser("sync", help=sync_fn.__doc__) - sync.add_argument( - "--manifest-glob", help="a quoted glob pattern identifying copy manifest files" + + sync_manifest_source = sync.add_argument_group( + "Manifest Source", + "Specify a list of build cache objects to sync using manifest file(s)." + 'This option takes the place of the "source mirror" for synchronization' + 'and optionally takes a "destination mirror" ', ) - sync.add_argument( + sync_manifest_source.add_argument( + "--manifest-glob", help="a quoted glob pattern identifying CI rebuild manifest files" + ) + sync_source_mirror = sync.add_argument_group( + "Named Source", + "Specify a single registered source mirror to synchronize from. This option requires" + "the specification of a destination mirror.", + ) + sync_source_mirror.add_argument( "src_mirror", metavar="source mirror", - type=arguments.mirror_name_or_url, nargs="?", + type=arguments.mirror_name_or_url, help="source mirror name, path, or URL", ) + sync.add_argument( "dest_mirror", metavar="destination mirror", - type=arguments.mirror_name_or_url, nargs="?", + type=arguments.mirror_name_or_url, help="destination mirror name, path, or URL", ) + sync.set_defaults(func=sync_fn) # Update buildcache index without copying any additional packages @@ -353,6 +362,25 @@ def _make_pool() -> MaybePool: return NoPool() +def _skip_no_redistribute_for_public(specs): + remaining_specs = list() + removed_specs = list() + for spec in specs: + if spec.package.redistribute_binary: + remaining_specs.append(spec) + else: + removed_specs.append(spec) + if removed_specs: + colified_output = tty.colify.colified(list(s.name for s in removed_specs), indent=4) + tty.debug( + "The following specs will not be added to the binary cache" + " because they cannot be redistributed:\n" + f"{colified_output}\n" + "You can use `--private` to include them." + ) + return remaining_specs + + def push_fn(args): """create a binary package and push it to a mirror""" if args.spec_file: @@ -366,11 +394,6 @@ def push_fn(args): else: roots = spack.cmd.require_active_env(cmd_name="buildcache push").concrete_roots() - if args.allow_root: - tty.warn( - "The flag `--allow-root` is the default in Spack 0.21, will be removed in Spack 0.22" - ) - mirror: spack.mirror.Mirror = args.mirror # Check if this is an OCI image. @@ -403,6 +426,8 @@ def push_fn(args): root="package" in args.things_to_install, dependencies="dependencies" in args.things_to_install, ) + if not args.private: + specs = _skip_no_redistribute_for_public(specs) url = args.mirror.push_url @@ -818,10 +843,7 @@ def _config_from_tag(image_ref: ImageReference, tag: str) -> Optional[dict]: def _update_index_oci(image_ref: ImageReference, tmpdir: str, pool: MaybePool) -> None: - request = urllib.request.Request(url=image_ref.tags_url()) - response = spack.oci.opener.urlopen(request) - spack.oci.opener.ensure_status(request, response, 200) - tags = json.load(response)["tags"] + tags = list_tags(image_ref) # Fetch all image config files in parallel spec_dicts = pool.starmap( @@ -925,14 +947,6 @@ def keys_fn(args): bindist.get_keys(args.install, args.trust, args.force) -def preview_fn(args): - """analyze an installed spec and reports whether executables and libraries are relocatable""" - tty.warn( - "`spack buildcache preview` is deprecated since `spack buildcache push --allow-root` is " - "now the default. This command will be removed in Spack 0.22" - ) - - def check_fn(args: argparse.Namespace): """check specs against remote binary mirror(s) to see if any need to be rebuilt @@ -1072,7 +1086,17 @@ def sync_fn(args): requires an active environment in order to know which specs to sync """ if args.manifest_glob: - manifest_copy(glob.glob(args.manifest_glob)) + # Passing the args.src_mirror here because it is not possible to + # have the destination be required when specifying a named source + # mirror and optional for the --manifest-glob argument. In the case + # of manifest glob sync, the source mirror positional argument is the + # destination mirror if it is specified. If there are two mirrors + # specified, the second is ignored and the first is the override + # destination. + if args.dest_mirror: + tty.warn(f"Ignoring unused arguemnt: {args.dest_mirror.name}") + + manifest_copy(glob.glob(args.manifest_glob), args.src_mirror) return 0 if args.src_mirror is None or args.dest_mirror is None: @@ -1123,7 +1147,7 @@ def sync_fn(args): shutil.rmtree(tmpdir) -def manifest_copy(manifest_file_list): +def manifest_copy(manifest_file_list, dest_mirror=None): """Read manifest files containing information about specific specs to copy from source to destination, remove duplicates since any binary packge for a given hash should be the same as any other, and copy all files specified @@ -1137,10 +1161,17 @@ def manifest_copy(manifest_file_list): # Last duplicate hash wins deduped_manifest[spec_hash] = copy_list + build_cache_dir = bindist.build_cache_relative_path() for spec_hash, copy_list in deduped_manifest.items(): for copy_file in copy_list: - tty.debug("copying {0} to {1}".format(copy_file["src"], copy_file["dest"])) - copy_buildcache_file(copy_file["src"], copy_file["dest"]) + dest = copy_file["dest"] + if dest_mirror: + src_relative_path = os.path.join( + build_cache_dir, copy_file["src"].rsplit(build_cache_dir, 1)[1].lstrip("/") + ) + dest = url_util.join(dest_mirror.push_url, src_relative_path) + tty.debug("copying {0} to {1}".format(copy_file["src"], dest)) + copy_buildcache_file(copy_file["src"], dest) def update_index(mirror: spack.mirror.Mirror, update_keys=False): @@ -1167,14 +1198,18 @@ def update_index(mirror: spack.mirror.Mirror, update_keys=False): url, bindist.build_cache_relative_path(), bindist.build_cache_keys_relative_path() ) - bindist.generate_key_index(keys_url) + try: + bindist.generate_key_index(keys_url) + except bindist.CannotListKeys as e: + # Do not error out if listing keys went wrong. This usually means that the _gpg path + # does not exist. TODO: distinguish between this and other errors. + tty.warn(f"did not update the key index: {e}") def update_index_fn(args): """update a buildcache index""" - update_index(args.mirror, update_keys=args.keys) + return update_index(args.mirror, update_keys=args.keys) def buildcache(parser, args): - if args.func: - args.func(args) + return args.func(args) diff --git a/lib/spack/spack/cmd/checksum.py b/lib/spack/spack/cmd/checksum.py index 01a1c4caca88e0..e599e4dff6c82e 100644 --- a/lib/spack/spack/cmd/checksum.py +++ b/lib/spack/spack/cmd/checksum.py @@ -189,7 +189,7 @@ def checksum(parser, args): print() if args.add_to_package: - add_versions_to_package(pkg, version_lines) + add_versions_to_package(pkg, version_lines, args.batch) def print_checksum_status(pkg: PackageBase, version_hashes: dict): @@ -235,7 +235,7 @@ def print_checksum_status(pkg: PackageBase, version_hashes: dict): tty.die("Invalid checksums found.") -def add_versions_to_package(pkg: PackageBase, version_lines: str): +def add_versions_to_package(pkg: PackageBase, version_lines: str, is_batch: bool): """ Add checksumed versions to a package's instructions and open a user's editor so they may double check the work of the function. @@ -288,5 +288,5 @@ def add_versions_to_package(pkg: PackageBase, version_lines: str): tty.msg(f"Added {num_versions_added} new versions to {pkg.name}") tty.msg(f"Open {filename} to review the additions.") - if sys.stdout.isatty(): + if sys.stdout.isatty() and not is_batch: editor(filename) diff --git a/lib/spack/spack/cmd/ci.py b/lib/spack/spack/cmd/ci.py index 80aa1634e3e31c..934acc0d4e1bed 100644 --- a/lib/spack/spack/cmd/ci.py +++ b/lib/spack/spack/cmd/ci.py @@ -6,6 +6,7 @@ import json import os import shutil +import warnings from urllib.parse import urlparse, urlunparse import llnl.util.filesystem as fs @@ -14,6 +15,7 @@ import spack.binary_distribution as bindist import spack.ci as spack_ci +import spack.cmd import spack.cmd.buildcache as buildcache import spack.config as cfg import spack.environment as ev @@ -30,14 +32,20 @@ level = "long" SPACK_COMMAND = "spack" -MAKE_COMMAND = "make" INSTALL_FAIL_CODE = 1 +FAILED_CREATE_BUILDCACHE_CODE = 100 def deindent(desc): return desc.replace(" ", "") +def unicode_escape(path: str) -> str: + """Returns transformed path with any unicode + characters replaced with their corresponding escapes""" + return path.encode("unicode-escape").decode("utf-8") + + def setup_parser(subparser): setup_parser.parser = subparser subparsers = subparser.add_subparsers(help="CI sub-commands") @@ -66,7 +74,7 @@ def setup_parser(subparser): "--optimize", action="store_true", default=False, - help="(experimental) optimize the gitlab yaml file for size\n\n" + help="(DEPRECATED) optimize the gitlab yaml file for size\n\n" "run the generated document through a series of optimization passes " "designed to reduce the size of the generated file", ) @@ -74,7 +82,7 @@ def setup_parser(subparser): "--dependencies", action="store_true", default=False, - help="(experimental) disable DAG scheduling (use 'plain' dependencies)", + help="(DEPRECATED) disable DAG scheduling (use 'plain' dependencies)", ) generate.add_argument( "--buildcache-destination", @@ -193,6 +201,18 @@ def ci_generate(args): before invoking this command. the value must be the CDash authorization token needed to create a build group and register all generated jobs under it """ + if args.optimize: + warnings.warn( + "The --optimize option has been deprecated, and currently has no effect. " + "It will be removed in Spack v0.24." + ) + + if args.dependencies: + warnings.warn( + "The --dependencies option has been deprecated, and currently has no effect. " + "It will be removed in Spack v0.24." + ) + env = spack.cmd.require_active_env(cmd_name="ci generate") if args.copy_to: @@ -205,8 +225,6 @@ def ci_generate(args): output_file = args.output_file copy_yaml_to = args.copy_to - run_optimizer = args.optimize - use_dependencies = args.dependencies prune_dag = args.prune_dag index_only = args.index_only artifacts_root = args.artifacts_root @@ -227,8 +245,6 @@ def ci_generate(args): output_file, prune_dag=prune_dag, check_index_only=index_only, - run_optimizer=run_optimizer, - use_dependencies=use_dependencies, artifacts_root=artifacts_root, remote_mirror_override=buildcache_destination, ) @@ -549,75 +565,35 @@ def ci_rebuild(args): # No hash match anywhere means we need to rebuild spec # Start with spack arguments - spack_cmd = [SPACK_COMMAND, "--color=always", "--backtrace", "--verbose"] + spack_cmd = [SPACK_COMMAND, "--color=always", "--backtrace", "--verbose", "install"] config = cfg.get("config") if not config["verify_ssl"]: spack_cmd.append("-k") - install_args = [] + install_args = [f'--use-buildcache={spack_ci.win_quote("package:never,dependencies:only")}'] can_verify = spack_ci.can_verify_binaries() verify_binaries = can_verify and spack_is_pr_pipeline is False if not verify_binaries: install_args.append("--no-check-signature") - slash_hash = "/{}".format(job_spec.dag_hash()) - - # Arguments when installing dependencies from cache - deps_install_args = install_args + slash_hash = spack_ci.win_quote("/" + job_spec.dag_hash()) # Arguments when installing the root from sources - root_install_args = install_args + [ - "--keep-stage", - "--only=package", - "--use-buildcache=package:never,dependencies:only", - ] + deps_install_args = install_args + ["--only=dependencies"] + root_install_args = install_args + ["--keep-stage", "--only=package"] + if cdash_handler: # Add additional arguments to `spack install` for CDash reporting. root_install_args.extend(cdash_handler.args()) - root_install_args.append(slash_hash) - - # ["x", "y"] -> "'x' 'y'" - args_to_string = lambda args: " ".join("'{}'".format(arg) for arg in args) commands = [ # apparently there's a race when spack bootstraps? do it up front once - [SPACK_COMMAND, "-e", env.path, "bootstrap", "now"], - [ - SPACK_COMMAND, - "-e", - env.path, - "env", - "depfile", - "-o", - "Makefile", - "--use-buildcache=package:never,dependencies:only", - slash_hash, # limit to spec we're building - ], - [ - # --output-sync requires GNU make 4.x. - # Old make errors when you pass it a flag it doesn't recognize, - # but it doesn't error or warn when you set unrecognized flags in - # this variable. - "export", - "GNUMAKEFLAGS=--output-sync=recurse", - ], - [ - MAKE_COMMAND, - "SPACK={}".format(args_to_string(spack_cmd)), - "SPACK_COLOR=always", - "SPACK_INSTALL_FLAGS={}".format(args_to_string(deps_install_args)), - "-j$(nproc)", - "install-deps/{}".format( - spack.environment.depfile.MakefileSpec(job_spec).safe_format( - "{name}-{version}-{hash}" - ) - ), - ], - spack_cmd + ["install"] + root_install_args, + [SPACK_COMMAND, "-e", unicode_escape(env.path), "bootstrap", "now"], + spack_cmd + deps_install_args + [slash_hash], + spack_cmd + root_install_args + [slash_hash], ] - tty.debug("Installing {0} from source".format(job_spec.name)) install_exit_code = spack_ci.process_command("install", commands, repro_dir) @@ -705,11 +681,9 @@ def ci_rebuild(args): cdash_handler.report_skipped(job_spec, reports_dir, reason=msg) cdash_handler.copy_test_results(reports_dir, job_test_dir) - # If the install succeeded, create a buildcache entry for this job spec - # and push it to one or more mirrors. If the install did not succeed, - # print out some instructions on how to reproduce this build failure - # outside of the pipeline environment. if install_exit_code == 0: + # If the install succeeded, push it to one or more mirrors. Failure to push to any mirror + # will result in a non-zero exit code. Pushing is best-effort. mirror_urls = [buildcache_mirror_url] # TODO: Remove this block in Spack 0.23 @@ -721,13 +695,12 @@ def ci_rebuild(args): destination_mirror_urls=mirror_urls, sign_binaries=spack_ci.can_sign_binaries(), ): - msg = tty.msg if result.success else tty.warn - msg( - "{} {} to {}".format( - "Pushed" if result.success else "Failed to push", - job_spec.format("{name}{@version}{/hash:7}", color=clr.get_color_when()), - result.url, - ) + if not result.success: + install_exit_code = FAILED_CREATE_BUILDCACHE_CODE + (tty.msg if result.success else tty.error)( + f'{"Pushed" if result.success else "Failed to push"} ' + f'{job_spec.format("{name}{@version}{/hash:7}", color=clr.get_color_when())} ' + f"to {result.url}" ) # If this is a develop pipeline, check if the spec that we just built is @@ -748,22 +721,22 @@ def ci_rebuild(args): tty.warn(msg.format(broken_spec_path, err)) else: + # If the install did not succeed, print out some instructions on how to reproduce this + # build failure outside of the pipeline environment. tty.debug("spack install exited non-zero, will not create buildcache") api_root_url = os.environ.get("CI_API_V4_URL") ci_project_id = os.environ.get("CI_PROJECT_ID") ci_job_id = os.environ.get("CI_JOB_ID") - repro_job_url = "{0}/projects/{1}/jobs/{2}/artifacts".format( - api_root_url, ci_project_id, ci_job_id - ) - + repro_job_url = f"{api_root_url}/projects/{ci_project_id}/jobs/{ci_job_id}/artifacts" # Control characters cause this to be printed in blue so it stands out - reproduce_msg = """ + print( + f""" \033[34mTo reproduce this build locally, run: - spack ci reproduce-build {0} [--working-dir ] [--autostart] + spack ci reproduce-build {repro_job_url} [--working-dir ] [--autostart] If this project does not have public pipelines, you will need to first: @@ -771,12 +744,9 @@ def ci_rebuild(args): ... then follow the printed instructions.\033[0;0m -""".format( - repro_job_url +""" ) - print(reproduce_msg) - rebuild_timer.stop() try: with open("install_timers.json", "w") as timelog: diff --git a/lib/spack/spack/cmd/clean.py b/lib/spack/spack/cmd/clean.py index 3a9a7f32abc546..9dd3efa45992fb 100644 --- a/lib/spack/spack/cmd/clean.py +++ b/lib/spack/spack/cmd/clean.py @@ -106,7 +106,8 @@ def clean(parser, args): # Then do the cleaning falling through the cases if args.specs: - specs = spack.cmd.parse_specs(args.specs, concretize=True) + specs = spack.cmd.parse_specs(args.specs, concretize=False) + specs = list(spack.cmd.matching_spec_from_env(x) for x in specs) for spec in specs: msg = "Cleaning build stage [{0}]" tty.msg(msg.format(spec.short_spec)) diff --git a/lib/spack/spack/cmd/common/arguments.py b/lib/spack/spack/cmd/common/arguments.py index ab9f8939805412..aa652919f84690 100644 --- a/lib/spack/spack/cmd/common/arguments.py +++ b/lib/spack/spack/cmd/common/arguments.py @@ -563,12 +563,13 @@ def add_concretizer_args(subparser): help="reuse installed packages/buildcaches when possible", ) subgroup.add_argument( + "--fresh-roots", "--reuse-deps", action=ConfigSetAction, dest="concretizer:reuse", const="dependencies", default=None, - help="reuse installed dependencies only", + help="concretize with fresh roots and reused dependencies", ) subgroup.add_argument( "--deprecated", diff --git a/lib/spack/spack/cmd/concretize.py b/lib/spack/spack/cmd/concretize.py index e07c0eb18ccfd4..061a03fc4d8c3a 100644 --- a/lib/spack/spack/cmd/concretize.py +++ b/lib/spack/spack/cmd/concretize.py @@ -3,6 +3,9 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import llnl.util.tty as tty +from llnl.string import plural + import spack.cmd import spack.cmd.common.arguments import spack.environment as ev @@ -43,5 +46,9 @@ def concretize(parser, args): with env.write_transaction(): concretized_specs = env.concretize(force=args.force, tests=tests) if not args.quiet: - ev.display_specs(concretized_specs) + if concretized_specs: + tty.msg(f"Concretized {plural(len(concretized_specs), 'spec')}:") + ev.display_specs([concrete for _, concrete in concretized_specs]) + else: + tty.msg("No new specs to concretize.") env.write() diff --git a/lib/spack/spack/cmd/config.py b/lib/spack/spack/cmd/config.py index 61b27bcdfe7f2d..ca68cbbd9d1f62 100644 --- a/lib/spack/spack/cmd/config.py +++ b/lib/spack/spack/cmd/config.py @@ -156,7 +156,7 @@ def print_flattened_configuration(*, blame: bool) -> None: """ env = ev.active_environment() if env is not None: - pristine = env.manifest.pristine_yaml_content + pristine = env.manifest.yaml_content flattened = pristine.copy() flattened[spack.schema.env.TOP_LEVEL_KEY] = pristine[spack.schema.env.TOP_LEVEL_KEY].copy() else: @@ -264,7 +264,9 @@ def config_remove(args): def _can_update_config_file(scope: spack.config.ConfigScope, cfg_file): if isinstance(scope, spack.config.SingleFileScope): return fs.can_access(cfg_file) - return fs.can_write_to_dir(scope.path) and fs.can_access(cfg_file) + elif isinstance(scope, spack.config.DirectoryConfigScope): + return fs.can_write_to_dir(scope.path) and fs.can_access(cfg_file) + return False def _config_change_requires_scope(path, spec, scope, match_spec=None): @@ -362,14 +364,11 @@ def config_change(args): def config_update(args): # Read the configuration files spack.config.CONFIG.get_config(args.section, scope=args.scope) - updates: List[spack.config.ConfigScope] = list( - filter( - lambda s: not isinstance( - s, (spack.config.InternalConfigScope, spack.config.ImmutableConfigScope) - ), - spack.config.CONFIG.format_updates[args.section], - ) - ) + updates: List[spack.config.ConfigScope] = [ + x + for x in spack.config.CONFIG.format_updates[args.section] + if not isinstance(x, spack.config.InternalConfigScope) and x.writable + ] cannot_overwrite, skip_system_scope = [], False for scope in updates: @@ -447,7 +446,7 @@ def _can_revert_update(scope_dir, cfg_file, bkp_file): def config_revert(args): - scopes = [args.scope] if args.scope else [x.name for x in spack.config.CONFIG.file_scopes] + scopes = [args.scope] if args.scope else [x.name for x in spack.config.CONFIG.writable_scopes] # Search for backup files in the configuration scopes Entry = collections.namedtuple("Entry", ["scope", "cfg", "bkp"]) diff --git a/lib/spack/spack/cmd/create.py b/lib/spack/spack/cmd/create.py index 49f4ae217786e5..c3807142970725 100644 --- a/lib/spack/spack/cmd/create.py +++ b/lib/spack/spack/cmd/create.py @@ -2,7 +2,6 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) - import os import re import sys @@ -934,7 +933,7 @@ def get_repository(args, name): # Figure out where the new package should live repo_path = args.repo if repo_path is not None: - repo = spack.repo.Repo(repo_path) + repo = spack.repo.from_path(repo_path) if spec.namespace and spec.namespace != repo.namespace: tty.die( "Can't create package with namespace {0} in repo with " @@ -942,9 +941,7 @@ def get_repository(args, name): ) else: if spec.namespace: - repo = spack.repo.PATH.get_repo(spec.namespace, None) - if not repo: - tty.die("Unknown namespace: '{0}'".format(spec.namespace)) + repo = spack.repo.PATH.get_repo(spec.namespace) else: repo = spack.repo.PATH.first_repo() diff --git a/lib/spack/spack/cmd/dependents.py b/lib/spack/spack/cmd/dependents.py index 4cbb7cdd3cdc51..7c997bad9d5b35 100644 --- a/lib/spack/spack/cmd/dependents.py +++ b/lib/spack/spack/cmd/dependents.py @@ -47,16 +47,6 @@ def inverted_dependencies(): dependents of, e.g., `mpi`, but virtuals are not included as actual dependents. """ - dag = {} - for pkg_cls in spack.repo.PATH.all_package_classes(): - dag.setdefault(pkg_cls.name, set()) - for dep in pkg_cls.dependencies_by_name(): - deps = [dep] - - # expand virtuals if necessary - if spack.repo.PATH.is_virtual(dep): - deps += [s.name for s in spack.repo.PATH.providers_for(dep)] - dag = collections.defaultdict(set) for pkg_cls in spack.repo.PATH.all_package_classes(): for _, deps_by_name in pkg_cls.dependencies.items(): diff --git a/lib/spack/spack/cmd/develop.py b/lib/spack/spack/cmd/develop.py index 0c9db3274c1860..e226c16766553e 100644 --- a/lib/spack/spack/cmd/develop.py +++ b/lib/spack/spack/cmd/develop.py @@ -9,6 +9,8 @@ import spack.cmd import spack.config +import spack.fetch_strategy +import spack.repo import spack.spec import spack.util.path import spack.version @@ -69,13 +71,15 @@ def _retrieve_develop_source(spec, abspath): # We construct a package class ourselves, rather than asking for # Spec.package, since Spec only allows this when it is concrete package = pkg_cls(spec) - if isinstance(package.stage[0].fetcher, spack.fetch_strategy.GitFetchStrategy): - package.stage[0].fetcher.get_full_repo = True + source_stage = package.stage[0] + if isinstance(source_stage.fetcher, spack.fetch_strategy.GitFetchStrategy): + source_stage.fetcher.get_full_repo = True # If we retrieved this version before and cached it, we may have # done so without cloning the full git repo; likewise, any # mirror might store an instance with truncated history. - package.stage[0].disable_mirrors() + source_stage.disable_mirrors() + source_stage.fetcher.set_package(package) package.stage.steal_source(abspath) diff --git a/lib/spack/spack/cmd/edit.py b/lib/spack/spack/cmd/edit.py index 0134a522d82153..9951bb65a3f8e2 100644 --- a/lib/spack/spack/cmd/edit.py +++ b/lib/spack/spack/cmd/edit.py @@ -3,6 +3,7 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import errno import glob import os @@ -11,43 +12,13 @@ import spack.cmd import spack.paths import spack.repo -from spack.spec import Spec -from spack.util.editor import editor +import spack.util.editor description = "open package files in $EDITOR" section = "packaging" level = "short" -def edit_package(name, repo_path, namespace): - """Opens the requested package file in your favorite $EDITOR. - - Args: - name (str): The name of the package - repo_path (str): The path to the repository containing this package - namespace (str): A valid namespace registered with Spack - """ - # Find the location of the package - if repo_path: - repo = spack.repo.Repo(repo_path) - elif namespace: - repo = spack.repo.PATH.get_repo(namespace) - else: - repo = spack.repo.PATH - path = repo.filename_for_package_name(name) - - spec = Spec(name) - if os.path.exists(path): - if not os.path.isfile(path): - tty.die("Something is wrong. '{0}' is not a file!".format(path)) - if not os.access(path, os.R_OK): - tty.die("Insufficient permissions on '%s'!" % path) - else: - raise spack.repo.UnknownPackageError(spec.name) - - editor(path) - - def setup_parser(subparser): excl_args = subparser.add_mutually_exclusive_group() @@ -98,41 +69,67 @@ def setup_parser(subparser): excl_args.add_argument("-r", "--repo", default=None, help="path to repo to edit package in") excl_args.add_argument("-N", "--namespace", default=None, help="namespace of package to edit") - subparser.add_argument("package", nargs="?", default=None, help="package name") + subparser.add_argument("package", nargs="*", default=None, help="package name") -def edit(parser, args): - name = args.package +def locate_package(name: str, repo: spack.repo.Repo) -> str: + path = repo.filename_for_package_name(name) - # By default, edit package files - path = spack.paths.packages_path + try: + with open(path, "r"): + return path + except OSError as e: + if e.errno == errno.ENOENT: + raise spack.repo.UnknownPackageError(name) from e + tty.die(f"Cannot edit package: {e}") + + +def locate_file(name: str, path: str) -> str: + # convert command names to python module name + if path == spack.paths.command_path: + name = spack.cmd.python_name(name) + + file_path = os.path.join(path, name) + + # Try to open direct match. + try: + with open(file_path, "r"): + return file_path + except OSError as e: + if e.errno != errno.ENOENT: + tty.die(f"Cannot edit file: {e}") + pass + + # Otherwise try to find a file that starts with the name + candidates = glob.glob(file_path + "*") + exclude_list = [".pyc", "~"] # exclude binaries and backups + files = [f for f in candidates if not any(f.endswith(ext) for ext in exclude_list)] + if len(files) > 1: + tty.die( + f"Multiple files start with `{name}`:\n" + + "\n".join(f" {os.path.basename(f)}" for f in files) + ) + elif not files: + tty.die(f"No file for '{name}' was found in {path}") + return files[0] + + +def edit(parser, args): + names = args.package # If `--command`, `--test`, or `--module` is chosen, edit those instead if args.path: - path = args.path - if name: - # convert command names to python module name - if path == spack.paths.command_path: - name = spack.cmd.python_name(name) - - path = os.path.join(path, name) - if not os.path.exists(path): - files = glob.glob(path + "*") - exclude_list = [".pyc", "~"] # exclude binaries and backups - files = list(filter(lambda x: all(s not in x for s in exclude_list), files)) - if len(files) > 1: - m = "Multiple files exist with the name {0}.".format(name) - m += " Please specify a suffix. Files are:\n\n" - for f in files: - m += " " + os.path.basename(f) + "\n" - tty.die(m) - if not files: - tty.die("No file for '{0}' was found in {1}".format(name, path)) - path = files[0] # already confirmed only one entry in files - - editor(path) - elif name: - edit_package(name, args.repo, args.namespace) + paths = [locate_file(name, args.path) for name in names] if names else [args.path] + spack.util.editor.editor(*paths) + elif names: + if args.repo: + repo = spack.repo.from_path(args.repo) + elif args.namespace: + repo = spack.repo.PATH.get_repo(args.namespace) + else: + repo = spack.repo.PATH + paths = [locate_package(name, repo) for name in names] + spack.util.editor.editor(*paths) else: # By default open the directory where packages live - editor(path) + spack.util.editor.editor(spack.paths.packages_path) diff --git a/lib/spack/spack/cmd/env.py b/lib/spack/spack/cmd/env.py index ee9d556b6751b1..2ccb88fd1af9a4 100644 --- a/lib/spack/spack/cmd/env.py +++ b/lib/spack/spack/cmd/env.py @@ -9,13 +9,14 @@ import shutil import sys import tempfile -from typing import Optional +from pathlib import Path +from typing import List, Optional import llnl.string as string import llnl.util.filesystem as fs import llnl.util.tty as tty from llnl.util.tty.colify import colify -from llnl.util.tty.color import colorize +from llnl.util.tty.color import cescape, colorize import spack.cmd import spack.cmd.common @@ -44,6 +45,7 @@ "deactivate", "create", ["remove", "rm"], + ["rename", "mv"], ["list", "ls"], ["status", "st"], "loads", @@ -59,14 +61,7 @@ # def env_create_setup_parser(subparser): """create a new environment""" - subparser.add_argument( - "env_name", - metavar="env", - help=( - "name of managed environment or directory of the anonymous env " - "(when using --dir/-d) to activate" - ), - ) + subparser.add_argument("env_name", metavar="env", help="name or directory of environment") subparser.add_argument( "-d", "--dir", action="store_true", help="create an environment in a specific directory" ) @@ -92,6 +87,9 @@ def env_create_setup_parser(subparser): default=None, help="either a lockfile (must end with '.json' or '.lock') or a manifest file", ) + subparser.add_argument( + "--include-concrete", action="append", help="name of old environment to copy specs from" + ) def env_create(args): @@ -109,19 +107,32 @@ def env_create(args): # the environment should not include a view. with_view = None + include_concrete = None + if hasattr(args, "include_concrete"): + include_concrete = args.include_concrete + env = _env_create( args.env_name, init_file=args.envfile, - dir=args.dir, + dir=args.dir or os.path.sep in args.env_name or args.env_name in (".", ".."), with_view=with_view, keep_relative=args.keep_relative, + include_concrete=include_concrete, ) # Generate views, only really useful for environments created from spack.lock files. env.regenerate_views() -def _env_create(name_or_path, *, init_file=None, dir=False, with_view=None, keep_relative=False): +def _env_create( + name_or_path: str, + *, + init_file: Optional[str] = None, + dir: bool = False, + with_view: Optional[str] = None, + keep_relative: bool = False, + include_concrete: Optional[List[str]] = None, +): """Create a new environment, with an optional yaml description. Arguments: @@ -133,22 +144,31 @@ def _env_create(name_or_path, *, init_file=None, dir=False, with_view=None, keep keep_relative (bool): if True, develop paths are copied verbatim into the new environment file, otherwise they may be made absolute if the new environment is in a different location + include_concrete (list): list of the included concrete environments """ if not dir: env = ev.create( - name_or_path, init_file=init_file, with_view=with_view, keep_relative=keep_relative + name_or_path, + init_file=init_file, + with_view=with_view, + keep_relative=keep_relative, + include_concrete=include_concrete, ) - tty.msg("Created environment '%s' in %s" % (name_or_path, env.path)) - tty.msg("You can activate this environment with:") - tty.msg(" spack env activate %s" % (name_or_path)) - return env - - env = ev.create_in_dir( - name_or_path, init_file=init_file, with_view=with_view, keep_relative=keep_relative - ) - tty.msg("Created environment in %s" % env.path) - tty.msg("You can activate this environment with:") - tty.msg(" spack env activate %s" % env.path) + tty.msg( + colorize( + f"Created environment @c{{{cescape(name_or_path)}}} in: @c{{{cescape(env.path)}}}" + ) + ) + else: + env = ev.create_in_dir( + name_or_path, + init_file=init_file, + with_view=with_view, + keep_relative=keep_relative, + include_concrete=include_concrete, + ) + tty.msg(colorize(f"Created independent environment in: @c{{{cescape(env.path)}}}")) + tty.msg(f"Activate with: {colorize(f'@c{{spack env activate {cescape(name_or_path)}}}')}") return env @@ -434,6 +454,12 @@ def env_remove_setup_parser(subparser): """remove an existing environment""" subparser.add_argument("rm_env", metavar="env", nargs="+", help="environment(s) to remove") arguments.add_common_arguments(subparser, ["yes_to_all"]) + subparser.add_argument( + "-f", + "--force", + action="store_true", + help="remove the environment even if it is included in another environment", + ) def env_remove(args): @@ -443,13 +469,35 @@ def env_remove(args): and manifests embedded in repositories should be removed manually. """ read_envs = [] + valid_envs = [] bad_envs = [] - for env_name in args.rm_env: + invalid_envs = [] + + for env_name in ev.all_environment_names(): try: env = ev.read(env_name) - read_envs.append(env) + valid_envs.append(env_name) + + if env_name in args.rm_env: + read_envs.append(env) except (spack.config.ConfigFormatError, ev.SpackEnvironmentConfigError): - bad_envs.append(env_name) + invalid_envs.append(env_name) + + if env_name in args.rm_env: + bad_envs.append(env_name) + + # Check if env is linked to another before trying to remove + for name in valid_envs: + # don't check if environment is included to itself + if name == env_name: + continue + environ = ev.Environment(ev.root(name)) + if ev.root(env_name) in environ.included_concrete_envs: + msg = f'Environment "{env_name}" is being used by environment "{name}"' + if args.force: + tty.warn(msg) + else: + tty.die(msg) if not args.yes_to_all: environments = string.plural(len(args.rm_env), "environment", show_n=False) @@ -472,11 +520,82 @@ def env_remove(args): tty.msg(f"Successfully removed environment '{bad_env_name}'") +# +# env rename +# +def env_rename_setup_parser(subparser): + """rename an existing environment""" + subparser.add_argument( + "mv_from", metavar="from", help="name (or path) of existing environment" + ) + subparser.add_argument( + "mv_to", metavar="to", help="new name (or path) for existing environment" + ) + subparser.add_argument( + "-d", + "--dir", + action="store_true", + help="the specified arguments correspond to directory paths", + ) + subparser.add_argument( + "-f", "--force", action="store_true", help="allow overwriting of an existing environment" + ) + + +def env_rename(args): + """Rename an environment. + + This renames a managed environment or moves an anonymous environment. + """ + + # Directory option has been specified + if args.dir: + if not ev.is_env_dir(args.mv_from): + tty.die("The specified path does not correspond to a valid spack environment") + from_path = Path(args.mv_from) + if not args.force: + if ev.is_env_dir(args.mv_to): + tty.die( + "The new path corresponds to an existing environment;" + " specify the --force flag to overwrite it." + ) + if Path(args.mv_to).exists(): + tty.die("The new path already exists; specify the --force flag to overwrite it.") + to_path = Path(args.mv_to) + + # Name option being used + elif ev.exists(args.mv_from): + from_path = ev.environment.environment_dir_from_name(args.mv_from) + if not args.force and ev.exists(args.mv_to): + tty.die( + "The new name corresponds to an existing environment;" + " specify the --force flag to overwrite it." + ) + to_path = ev.environment.root(args.mv_to) + + # Neither + else: + tty.die("The specified name does not correspond to a managed spack environment") + + # Guard against renaming from or to an active environment + active_env = ev.active_environment() + if active_env: + from_env = ev.Environment(from_path) + if from_env.path == active_env.path: + tty.die("Cannot rename active environment") + if to_path == active_env.path: + tty.die(f"{args.mv_to} is an active environment") + + shutil.rmtree(to_path, ignore_errors=True) + fs.rename(from_path, to_path) + tty.msg(f"Successfully renamed environment {args.mv_from} to {args.mv_to}") + + # # env list # def env_list_setup_parser(subparser): - """list available environments""" + """list managed environments""" def env_list(args): diff --git a/lib/spack/spack/cmd/external.py b/lib/spack/spack/cmd/external.py index 8b6e75093251d8..421685d42a3e30 100644 --- a/lib/spack/spack/cmd/external.py +++ b/lib/spack/spack/cmd/external.py @@ -7,7 +7,7 @@ import os import re import sys -from typing import List, Optional +from typing import List, Optional, Set import llnl.util.tty as tty import llnl.util.tty.colify as colify @@ -19,6 +19,7 @@ import spack.detection import spack.error import spack.repo +import spack.spec import spack.util.environment from spack.cmd.common import arguments @@ -138,14 +139,26 @@ def external_find(args): candidate_packages, path_hints=args.path, max_workers=args.jobs ) - new_entries = spack.detection.update_configuration( + new_specs = spack.detection.update_configuration( detected_packages, scope=args.scope, buildable=not args.not_buildable ) - if new_entries: + + # If the user runs `spack external find --not-buildable mpich` we also mark `mpi` non-buildable + # to avoid that the concretizer picks a different mpi provider. + if new_specs and args.not_buildable: + virtuals: Set[str] = { + virtual.name + for new_spec in new_specs + for virtual_specs in spack.repo.PATH.get_pkg_class(new_spec.name).provided.values() + for virtual in virtual_specs + } + new_virtuals = spack.detection.set_virtuals_nonbuildable(virtuals, scope=args.scope) + new_specs.extend(spack.spec.Spec(name) for name in new_virtuals) + + if new_specs: path = spack.config.CONFIG.get_config_filename(args.scope, "packages") - msg = "The following specs have been detected on this system and added to {0}" - tty.msg(msg.format(path)) - spack.cmd.display_specs(new_entries) + tty.msg(f"The following specs have been detected on this system and added to {path}") + spack.cmd.display_specs(new_specs) else: tty.msg("No new external packages detected") diff --git a/lib/spack/spack/cmd/find.py b/lib/spack/spack/cmd/find.py index 070ac9bd0e7ff9..d09b2d84238553 100644 --- a/lib/spack/spack/cmd/find.py +++ b/lib/spack/spack/cmd/find.py @@ -14,6 +14,7 @@ import spack.cmd as cmd import spack.environment as ev import spack.repo +import spack.store from spack.cmd.common import arguments from spack.database import InstallStatuses @@ -45,6 +46,10 @@ def setup_parser(subparser): help="output specs as machine-readable json records", ) + subparser.add_argument( + "-I", "--install-status", action="store_true", help="show install status of packages" + ) + subparser.add_argument( "-d", "--deps", action="store_true", help="output dependencies along with found specs" ) @@ -69,6 +74,12 @@ def setup_parser(subparser): arguments.add_common_arguments(subparser, ["long", "very_long", "tags", "namespaces"]) + subparser.add_argument( + "-r", + "--only-roots", + action="store_true", + help="don't show full list of installed specs in an environment", + ) subparser.add_argument( "-c", "--show-concretized", @@ -140,6 +151,12 @@ def setup_parser(subparser): subparser.add_argument( "--only-deprecated", action="store_true", help="show only deprecated packages" ) + subparser.add_argument( + "--install-tree", + action="store", + default="all", + help="Install trees to query: 'all' (default), 'local', 'upstream', upstream name or path", + ) subparser.add_argument("--start-date", help="earliest date of installation [YYYY-MM-DD]") subparser.add_argument("--end-date", help="latest date of installation [YYYY-MM-DD]") @@ -168,6 +185,12 @@ def query_arguments(args): q_args = {"installed": installed, "known": known, "explicit": explicit} + install_tree = args.install_tree + upstreams = spack.config.get("upstreams", {}) + if install_tree in upstreams.keys(): + install_tree = upstreams[install_tree]["install_tree"] + q_args["install_tree"] = install_tree + # Time window of installation for attribute in ("start_date", "end_date"): date = getattr(args, attribute) @@ -177,26 +200,22 @@ def query_arguments(args): return q_args -def setup_env(env): +def make_env_decorator(env): """Create a function for decorating specs when in an environment.""" - def strip_build(seq): - return set(s.copy(deps=("link", "run")) for s in seq) - - added = set(strip_build(env.added_specs())) - roots = set(strip_build(env.roots())) - removed = set(strip_build(env.removed_specs())) + roots = set(env.roots()) + removed = set(env.removed_specs()) def decorator(spec, fmt): # add +/-/* to show added/removed/root specs if any(spec.dag_hash() == r.dag_hash() for r in roots): - return color.colorize("@*{%s}" % fmt) + return color.colorize(f"@*{{{fmt}}}") elif spec in removed: - return color.colorize("@K{%s}" % fmt) + return color.colorize(f"@K{{{fmt}}}") else: - return "%s" % fmt + return fmt - return decorator, added, roots, removed + return decorator def display_env(env, args, decorator, results): @@ -211,10 +230,54 @@ def display_env(env, args, decorator, results): """ tty.msg("In environment %s" % env.name) - if not env.user_specs: - tty.msg("No root specs") - else: - tty.msg("Root specs") + num_roots = len(env.user_specs) or "No" + tty.msg(f"{num_roots} root specs") + + concrete_specs = { + root: concrete_root + for root, concrete_root in zip(env.concretized_user_specs, env.concrete_roots()) + } + + def root_decorator(spec, string): + """Decorate root specs with their install status if needed""" + concrete = concrete_specs.get(spec) + if concrete: + status = color.colorize(concrete.install_status().value) + hash = concrete.dag_hash() + else: + status = color.colorize(spack.spec.InstallStatus.absent.value) + hash = "-" * 32 + + # TODO: status has two extra spaces on the end of it, but fixing this and other spec + # TODO: space format idiosyncrasies is complicated. Fix this eventually + status = status[:-2] + + if args.long or args.very_long: + hash = color.colorize(f"@K{{{hash[: 7 if args.long else None]}}}") + return f"{status} {hash} {string}" + else: + return f"{status} {string}" + + with spack.store.STORE.db.read_transaction(): + cmd.display_specs( + env.user_specs, + args, + # these are overrides of CLI args + paths=False, + long=False, + very_long=False, + # these enforce details in the root specs to show what the user asked for + namespaces=True, + show_flags=True, + show_full_compiler=True, + decorator=root_decorator, + variants=True, + ) + + print() + + if env.included_concrete_envs: + tty.msg("Included specs") # Root specs cannot be displayed with prefixes, since those are not # set for abstract specs. Same for hashes @@ -224,36 +287,36 @@ def display_env(env, args, decorator, results): # Roots are displayed with variants, etc. so that we can see # specifically what the user asked for. cmd.display_specs( - env.user_specs, + env.included_user_specs, root_args, decorator=lambda s, f: color.colorize("@*{%s}" % f), - namespaces=True, + namespace=True, show_flags=True, show_full_compiler=True, variants=True, ) print() - if args.show_concretized: - tty.msg("Concretized roots") - cmd.display_specs(env.specs_by_hash.values(), args, decorator=decorator) - print() - - # Display a header for the installed packages section IF there are installed - # packages. If there aren't any, we'll just end up printing "0 installed packages" - # later. - if results: - tty.msg("Installed packages") - def find(parser, args): - q_args = query_arguments(args) - results = args.specs(**q_args) - env = ev.active_environment() - decorator = lambda s, f: f + + if not env and args.only_roots: + tty.die("-r / --only-roots requires an active environment") + if not env and args.show_concretized: + tty.die("-c / --show-concretized requires an active environment") + if env: - decorator, _, roots, _ = setup_env(env) + if args.constraint: + init_specs = spack.cmd.parse_specs(args.constraint) + results = env.all_matching_specs(*init_specs) + else: + results = env.all_specs() + else: + q_args = query_arguments(args) + results = args.specs(**q_args) + + decorator = make_env_decorator(env) if env else lambda s, f: f # use groups by default except with format. if args.groups is None: @@ -272,6 +335,11 @@ def find(parser, args): if args.loaded: results = spack.cmd.filter_loaded_specs(results) + if args.install_status or args.show_concretized: + status_fn = spack.spec.Spec.install_status + else: + status_fn = None + # Display the result if args.json: cmd.display_specs_as_json(results, deps=args.deps) @@ -280,9 +348,34 @@ def find(parser, args): if env: display_env(env, args, decorator, results) - cmd.display_specs(results, args, decorator=decorator, all_headers=True) + if not args.only_roots: + display_results = results + if not args.show_concretized: + display_results = list(x for x in results if x.installed) + cmd.display_specs( + display_results, args, decorator=decorator, all_headers=True, status_fn=status_fn + ) # print number of installed packages last (as the list may be long) if sys.stdout.isatty() and args.groups: + installed_suffix = "" + concretized_suffix = " to be installed" + + if args.only_roots: + installed_suffix += " (not shown)" + concretized_suffix += " (not shown)" + else: + if env and not args.show_concretized: + concretized_suffix += " (show with `spack find -c`)" + pkg_type = "loaded" if args.loaded else "installed" - spack.cmd.print_how_many_pkgs(results, pkg_type) + spack.cmd.print_how_many_pkgs( + list(x for x in results if x.installed), pkg_type, suffix=installed_suffix + ) + + if env: + spack.cmd.print_how_many_pkgs( + list(x for x in results if not x.installed), + "concretized", + suffix=concretized_suffix, + ) diff --git a/lib/spack/spack/cmd/gc.py b/lib/spack/spack/cmd/gc.py index 7e55dc42406f56..c7d023602e3f2d 100644 --- a/lib/spack/spack/cmd/gc.py +++ b/lib/spack/spack/cmd/gc.py @@ -56,7 +56,6 @@ def roots_from_environments(args, active_env): # -e says "also preserve things needed by this particular env" for env_name_or_dir in args.except_environment: - print("HMM", env_name_or_dir) if ev.exists(env_name_or_dir): env = ev.read(env_name_or_dir) elif ev.is_env_dir(env_name_or_dir): diff --git a/lib/spack/spack/cmd/help.py b/lib/spack/spack/cmd/help.py index 05679ff0805e10..9a4023c87a4bb3 100644 --- a/lib/spack/spack/cmd/help.py +++ b/lib/spack/spack/cmd/help.py @@ -50,7 +50,7 @@ @B{++}, @r{--}, @r{~~}, @B{==} propagate variants to package dependencies architecture variants: - @m{platform=platform} linux, darwin, cray, etc. + @m{platform=platform} linux, darwin, freebsd, windows @m{os=operating_system} specific @m{target=target} specific processor @m{arch=platform-os-target} shortcut for all three above diff --git a/lib/spack/spack/cmd/info.py b/lib/spack/spack/cmd/info.py index b007c6051639e8..3075107d078ace 100644 --- a/lib/spack/spack/cmd/info.py +++ b/lib/spack/spack/cmd/info.py @@ -263,8 +263,8 @@ def _fmt_name_and_default(variant): return color.colorize(f"@c{{{variant.name}}} @C{{[{_fmt_value(variant.default)}]}}") -def _fmt_when(when, indent): - return color.colorize(f"{indent * ' '}@B{{when}} {color.cescape(when)}") +def _fmt_when(when: "spack.spec.Spec", indent: int): + return color.colorize(f"{indent * ' '}@B{{when}} {color.cescape(str(when))}") def _fmt_variant_description(variant, width, indent): @@ -441,7 +441,7 @@ def get_url(version): return "No URL" url = get_url(preferred) if pkg.has_code else "" - line = version(" {0}".format(pad(preferred))) + color.cescape(url) + line = version(" {0}".format(pad(preferred))) + color.cescape(str(url)) color.cwrite(line) print() @@ -464,7 +464,7 @@ def get_url(version): continue for v, url in vers: - line = version(" {0}".format(pad(v))) + color.cescape(url) + line = version(" {0}".format(pad(v))) + color.cescape(str(url)) color.cprint(line) @@ -475,10 +475,7 @@ def print_virtuals(pkg, args): color.cprint(section_title("Virtual Packages: ")) if pkg.provided: for when, specs in reversed(sorted(pkg.provided.items())): - line = " %s provides %s" % ( - when.colorized(), - ", ".join(s.colorized() for s in specs), - ) + line = " %s provides %s" % (when.cformat(), ", ".join(s.cformat() for s in specs)) print(line) else: @@ -497,7 +494,9 @@ def print_licenses(pkg, args): pad = padder(pkg.licenses, 4) for when_spec in pkg.licenses: license_identifier = pkg.licenses[when_spec] - line = license(" {0}".format(pad(license_identifier))) + color.cescape(when_spec) + line = license(" {0}".format(pad(license_identifier))) + color.cescape( + str(when_spec) + ) color.cprint(line) diff --git a/lib/spack/spack/cmd/install.py b/lib/spack/spack/cmd/install.py index aa958a682c8530..8458e7ce050439 100644 --- a/lib/spack/spack/cmd/install.py +++ b/lib/spack/spack/cmd/install.py @@ -10,6 +10,7 @@ from typing import List import llnl.util.filesystem as fs +from llnl.string import plural from llnl.util import lang, tty import spack.build_environment @@ -61,7 +62,6 @@ def install_kwargs_from_args(args): "dependencies_use_cache": cache_opt(args.use_cache, dep_use_bc), "dependencies_cache_only": cache_opt(args.cache_only, dep_use_bc), "include_build_deps": args.include_build_deps, - "explicit": True, # Use true as a default for install command "stop_at": args.until, "unsigned": args.unsigned, "install_deps": ("dependencies" in args.things_to_install), @@ -376,7 +376,9 @@ def _maybe_add_and_concretize(args, env, specs): # `spack concretize` tests = compute_tests_install_kwargs(env.user_specs, args.test) concretized_specs = env.concretize(tests=tests) - ev.display_specs(concretized_specs) + if concretized_specs: + tty.msg(f"Concretized {plural(len(concretized_specs), 'spec')}") + ev.display_specs([concrete for _, concrete in concretized_specs]) # save view regeneration for later, so that we only do it # once, as it can be slow. @@ -420,10 +422,9 @@ def install_with_active_env(env: ev.Environment, args, install_kwargs, reporter_ with reporter_factory(specs_to_install): env.install_specs(specs_to_install, **install_kwargs) finally: - # TODO: this is doing way too much to trigger - # views and modules to be generated. - with env.write_transaction(): - env.write(regenerate=True) + if env.views: + with env.write_transaction(): + env.write(regenerate=True) def concrete_specs_from_cli(args, install_kwargs): @@ -474,6 +475,7 @@ def install_without_active_env(args, install_kwargs, reporter_factory): require_user_confirmation_for_overwrite(concrete_specs, args) install_kwargs["overwrite"] = [spec.dag_hash() for spec in concrete_specs] - installs = [(s.package, install_kwargs) for s in concrete_specs] - builder = PackageInstaller(installs) + installs = [s.package for s in concrete_specs] + install_kwargs["explicit"] = [s.dag_hash() for s in concrete_specs] + builder = PackageInstaller(installs, install_kwargs) builder.install() diff --git a/lib/spack/spack/cmd/load.py b/lib/spack/spack/cmd/load.py index a34b72ebb202d8..81f13194844de4 100644 --- a/lib/spack/spack/cmd/load.py +++ b/lib/spack/spack/cmd/load.py @@ -5,8 +5,6 @@ import sys -import llnl.util.tty as tty - import spack.cmd import spack.cmd.find import spack.environment as ev @@ -70,16 +68,6 @@ def setup_parser(subparser): help="load the first match if multiple packages match the spec", ) - subparser.add_argument( - "--only", - default="package,dependencies", - dest="things_to_load", - choices=["package", "dependencies"], - help="select whether to load the package and its dependencies\n\n" - "the default is to load the package and all dependencies. alternatively, " - "one can decide to load only the package or only the dependencies", - ) - subparser.add_argument( "--list", action="store_true", @@ -110,11 +98,6 @@ def load(parser, args): ) return 1 - if args.things_to_load != "package,dependencies": - tty.warn( - "The `--only` flag in spack load is deprecated and will be removed in Spack v0.22" - ) - with spack.store.STORE.db.read_transaction(): env_mod = uenv.environment_modifications_for_specs(*specs) for spec in specs: diff --git a/lib/spack/spack/cmd/mirror.py b/lib/spack/spack/cmd/mirror.py index 0faf3123c7a8e7..d25a9018e88b71 100644 --- a/lib/spack/spack/cmd/mirror.py +++ b/lib/spack/spack/cmd/mirror.py @@ -71,6 +71,11 @@ def setup_parser(subparser): help="the number of versions to fetch for each spec, choose 'all' to" " retrieve all versions of each package", ) + create_parser.add_argument( + "--private", + action="store_true", + help="for a private mirror, include non-redistributable packages", + ) arguments.add_common_arguments(create_parser, ["specs"]) arguments.add_concretizer_args(create_parser) @@ -108,6 +113,11 @@ def setup_parser(subparser): "and source use `--type binary --type source` (default)" ), ) + add_parser.add_argument( + "--autopush", + action="store_true", + help=("set mirror to push automatically after installation"), + ) add_parser_signed = add_parser.add_mutually_exclusive_group(required=False) add_parser_signed.add_argument( "--unsigned", @@ -175,6 +185,21 @@ def setup_parser(subparser): ), ) set_parser.add_argument("--url", help="url of mirror directory from 'spack mirror create'") + set_parser_autopush = set_parser.add_mutually_exclusive_group(required=False) + set_parser_autopush.add_argument( + "--autopush", + help="set mirror to push automatically after installation", + action="store_true", + default=None, + dest="autopush", + ) + set_parser_autopush.add_argument( + "--no-autopush", + help="set mirror to not push automatically after installation", + action="store_false", + default=None, + dest="autopush", + ) set_parser_unsigned = set_parser.add_mutually_exclusive_group(required=False) set_parser_unsigned.add_argument( "--unsigned", @@ -218,6 +243,7 @@ def mirror_add(args): or args.type or args.oci_username or args.oci_password + or args.autopush or args.signed is not None ): connection = {"url": args.url} @@ -234,6 +260,8 @@ def mirror_add(args): if args.type: connection["binary"] = "binary" in args.type connection["source"] = "source" in args.type + if args.autopush: + connection["autopush"] = args.autopush if args.signed is not None: connection["signed"] = args.signed mirror = spack.mirror.Mirror(connection, name=args.name) @@ -270,6 +298,8 @@ def _configure_mirror(args): changes["access_pair"] = [args.oci_username, args.oci_password] if getattr(args, "signed", None) is not None: changes["signed"] = args.signed + if getattr(args, "autopush", None) is not None: + changes["autopush"] = args.autopush # argparse cannot distinguish between --binary and --no-binary when same dest :( # notice that set-url does not have these args, so getattr @@ -334,7 +364,6 @@ def concrete_specs_from_user(args): specs = filter_externals(specs) specs = list(set(specs)) specs.sort(key=lambda s: (s.name, s.version)) - specs, _ = lang.stable_partition(specs, predicate_fn=not_excluded_fn(args)) return specs @@ -379,36 +408,50 @@ def concrete_specs_from_cli_or_file(args): return specs -def not_excluded_fn(args): - """Return a predicate that evaluate to True if a spec was not explicitly - excluded by the user. - """ - exclude_specs = [] - if args.exclude_file: - exclude_specs.extend(specs_from_text_file(args.exclude_file, concretize=False)) - if args.exclude_specs: - exclude_specs.extend(spack.cmd.parse_specs(str(args.exclude_specs).split())) - - def not_excluded(x): - return not any(x.satisfies(y) for y in exclude_specs) +class IncludeFilter: + def __init__(self, args): + self.exclude_specs = [] + if args.exclude_file: + self.exclude_specs.extend(specs_from_text_file(args.exclude_file, concretize=False)) + if args.exclude_specs: + self.exclude_specs.extend(spack.cmd.parse_specs(str(args.exclude_specs).split())) + self.private = args.private + + def __call__(self, x): + return all([self._not_license_excluded(x), self._not_cmdline_excluded(x)]) + + def _not_license_excluded(self, x): + """True if the spec is for a private mirror, or as long as the + package does not explicitly forbid redistributing source.""" + if self.private: + return True + elif x.package_class.redistribute_source(x): + return True + else: + tty.debug( + "Skip adding {0} to mirror: the package.py file" + " indicates that a public mirror should not contain" + " it.".format(x.name) + ) + return False - return not_excluded + def _not_cmdline_excluded(self, x): + """True if a spec was not explicitly excluded by the user.""" + return not any(x.satisfies(y) for y in self.exclude_specs) -def concrete_specs_from_environment(selection_fn): +def concrete_specs_from_environment(): env = ev.active_environment() assert env, "an active environment is required" mirror_specs = env.all_specs() mirror_specs = filter_externals(mirror_specs) - mirror_specs, _ = lang.stable_partition(mirror_specs, predicate_fn=selection_fn) return mirror_specs -def all_specs_with_all_versions(selection_fn): +def all_specs_with_all_versions(): specs = [spack.spec.Spec(n) for n in spack.repo.all_package_names()] mirror_specs = spack.mirror.get_all_versions(specs) mirror_specs.sort(key=lambda s: (s.name, s.version)) - mirror_specs, _ = lang.stable_partition(mirror_specs, predicate_fn=selection_fn) return mirror_specs @@ -429,12 +472,6 @@ def versions_per_spec(args): return num_versions -def create_mirror_for_individual_specs(mirror_specs, path, skip_unstable_versions): - present, mirrored, error = spack.mirror.create(path, mirror_specs, skip_unstable_versions) - tty.msg("Summary for mirror in {}".format(path)) - process_mirror_stats(present, mirrored, error) - - def process_mirror_stats(present, mirrored, error): p, m, e = len(present), len(mirrored), len(error) tty.msg( @@ -480,30 +517,28 @@ def mirror_create(args): # When no directory is provided, the source dir is used path = args.directory or spack.caches.fetch_cache_location() - if args.all and not ev.active_environment(): - create_mirror_for_all_specs( - path=path, - skip_unstable_versions=args.skip_unstable_versions, - selection_fn=not_excluded_fn(args), - ) - return + mirror_specs, mirror_fn = _specs_and_action(args) + mirror_fn(mirror_specs, path=path, skip_unstable_versions=args.skip_unstable_versions) - if args.all and ev.active_environment(): - create_mirror_for_all_specs_inside_environment( - path=path, - skip_unstable_versions=args.skip_unstable_versions, - selection_fn=not_excluded_fn(args), - ) - return - mirror_specs = concrete_specs_from_user(args) - create_mirror_for_individual_specs( - mirror_specs, path=path, skip_unstable_versions=args.skip_unstable_versions - ) +def _specs_and_action(args): + include_fn = IncludeFilter(args) + if args.all and not ev.active_environment(): + mirror_specs = all_specs_with_all_versions() + mirror_fn = create_mirror_for_all_specs + elif args.all and ev.active_environment(): + mirror_specs = concrete_specs_from_environment() + mirror_fn = create_mirror_for_individual_specs + else: + mirror_specs = concrete_specs_from_user(args) + mirror_fn = create_mirror_for_individual_specs + + mirror_specs, _ = lang.stable_partition(mirror_specs, predicate_fn=include_fn) + return mirror_specs, mirror_fn -def create_mirror_for_all_specs(path, skip_unstable_versions, selection_fn): - mirror_specs = all_specs_with_all_versions(selection_fn=selection_fn) + +def create_mirror_for_all_specs(mirror_specs, path, skip_unstable_versions): mirror_cache, mirror_stats = spack.mirror.mirror_cache_and_stats( path, skip_unstable_versions=skip_unstable_versions ) @@ -515,11 +550,10 @@ def create_mirror_for_all_specs(path, skip_unstable_versions, selection_fn): process_mirror_stats(*mirror_stats.stats()) -def create_mirror_for_all_specs_inside_environment(path, skip_unstable_versions, selection_fn): - mirror_specs = concrete_specs_from_environment(selection_fn=selection_fn) - create_mirror_for_individual_specs( - mirror_specs, path=path, skip_unstable_versions=skip_unstable_versions - ) +def create_mirror_for_individual_specs(mirror_specs, path, skip_unstable_versions): + present, mirrored, error = spack.mirror.create(path, mirror_specs, skip_unstable_versions) + tty.msg("Summary for mirror in {}".format(path)) + process_mirror_stats(present, mirrored, error) def mirror_destroy(args): diff --git a/lib/spack/spack/cmd/pkg.py b/lib/spack/spack/cmd/pkg.py index e4e616db563f13..b21313cbc498fb 100644 --- a/lib/spack/spack/cmd/pkg.py +++ b/lib/spack/spack/cmd/pkg.py @@ -169,7 +169,9 @@ def pkg_hash(args): def get_grep(required=False): """Get a grep command to use with ``spack pkg grep``.""" - return exe.which(os.environ.get("SPACK_GREP") or "grep", required=required) + grep = exe.which(os.environ.get("SPACK_GREP") or "grep", required=required) + grep.ignore_quotes = True # allow `spack pkg grep '"quoted string"'` without warning + return grep def pkg_grep(args, unknown_args): diff --git a/lib/spack/spack/cmd/python.py b/lib/spack/spack/cmd/python.py index 71ce88eed6f85a..a4f177fa38263e 100644 --- a/lib/spack/spack/cmd/python.py +++ b/lib/spack/spack/cmd/python.py @@ -116,39 +116,38 @@ def ipython_interpreter(args): def python_interpreter(args): """A python interpreter is the default interpreter""" - # Fake a main python shell by setting __name__ to __main__. - console = code.InteractiveConsole({"__name__": "__main__", "spack": spack}) - if "PYTHONSTARTUP" in os.environ: - startup_file = os.environ["PYTHONSTARTUP"] - if os.path.isfile(startup_file): - with open(startup_file) as startup: - console.runsource(startup.read(), startup_file, "exec") - if args.python_command: - propagate_exceptions_from(console) - console.runsource(args.python_command) - elif args.python_args: - propagate_exceptions_from(console) + if args.python_args and not args.python_command: sys.argv = args.python_args - with open(args.python_args[0]) as file: - console.runsource(file.read(), args.python_args[0], "exec") + runpy.run_path(args.python_args[0], run_name="__main__") else: - # Provides readline support, allowing user to use arrow keys - console.push("import readline") - # Provide tabcompletion - console.push("from rlcompleter import Completer") - console.push("readline.set_completer(Completer(locals()).complete)") - console.push('readline.parse_and_bind("tab: complete")') - - console.interact( - "Spack version %s\nPython %s, %s %s" - % ( - spack.spack_version, - platform.python_version(), - platform.system(), - platform.machine(), + # Fake a main python shell by setting __name__ to __main__. + console = code.InteractiveConsole({"__name__": "__main__", "spack": spack}) + if "PYTHONSTARTUP" in os.environ: + startup_file = os.environ["PYTHONSTARTUP"] + if os.path.isfile(startup_file): + with open(startup_file) as startup: + console.runsource(startup.read(), startup_file, "exec") + if args.python_command: + propagate_exceptions_from(console) + console.runsource(args.python_command) + else: + # Provides readline support, allowing user to use arrow keys + console.push("import readline") + # Provide tabcompletion + console.push("from rlcompleter import Completer") + console.push("readline.set_completer(Completer(locals()).complete)") + console.push('readline.parse_and_bind("tab: complete")') + + console.interact( + "Spack version %s\nPython %s, %s %s" + % ( + spack.spack_version, + platform.python_version(), + platform.system(), + platform.machine(), + ) ) - ) def propagate_exceptions_from(console): diff --git a/lib/spack/spack/cmd/repo.py b/lib/spack/spack/cmd/repo.py index 68af91cd918fc4..e41e21f0a5b17e 100644 --- a/lib/spack/spack/cmd/repo.py +++ b/lib/spack/spack/cmd/repo.py @@ -91,7 +91,7 @@ def repo_add(args): tty.die("Not a Spack repository: %s" % path) # Make sure it's actually a spack repository by constructing it. - repo = spack.repo.Repo(canon_path) + repo = spack.repo.from_path(canon_path) # If that succeeds, finally add it to the configuration. repos = spack.config.get("repos", scope=args.scope) @@ -124,7 +124,7 @@ def repo_remove(args): # If it is a namespace, remove corresponding repo for path in repos: try: - repo = spack.repo.Repo(path) + repo = spack.repo.from_path(path) if repo.namespace == namespace_or_path: repos.remove(path) spack.config.set("repos", repos, args.scope) @@ -142,7 +142,7 @@ def repo_list(args): repos = [] for r in roots: try: - repos.append(spack.repo.Repo(r)) + repos.append(spack.repo.from_path(r)) except spack.repo.RepoError: continue diff --git a/lib/spack/spack/cmd/solve.py b/lib/spack/spack/cmd/solve.py index 3d6968d2d9d171..2d6197f75846ad 100644 --- a/lib/spack/spack/cmd/solve.py +++ b/lib/spack/spack/cmd/solve.py @@ -91,7 +91,6 @@ def setup_parser(subparser): def _process_result(result, show, required_format, kwargs): - result.raise_if_unsat() opt, _, _ = min(result.answers) if ("opt" in show) and (not required_format): tty.msg("Best of %d considered solutions." % result.nmodels) @@ -115,15 +114,16 @@ def _process_result(result, show, required_format, kwargs): # dump the solutions as concretized specs if "solutions" in show: - for spec in result.specs: - # With -y, just print YAML to output. - if required_format == "yaml": - # use write because to_yaml already has a newline. - sys.stdout.write(spec.to_yaml(hash=ht.dag_hash)) - elif required_format == "json": - sys.stdout.write(spec.to_json(hash=ht.dag_hash)) - else: - sys.stdout.write(spec.tree(color=sys.stdout.isatty(), **kwargs)) + if required_format: + for spec in result.specs: + # With -y, just print YAML to output. + if required_format == "yaml": + # use write because to_yaml already has a newline. + sys.stdout.write(spec.to_yaml(hash=ht.dag_hash)) + elif required_format == "json": + sys.stdout.write(spec.to_json(hash=ht.dag_hash)) + else: + sys.stdout.write(spack.spec.tree(result.specs, color=sys.stdout.isatty(), **kwargs)) print() if result.unsolved_specs and "solutions" in show: diff --git a/lib/spack/spack/cmd/spec.py b/lib/spack/spack/cmd/spec.py index e2d5cb10557eff..ae08e1f9779143 100644 --- a/lib/spack/spack/cmd/spec.py +++ b/lib/spack/spack/cmd/spec.py @@ -105,11 +105,19 @@ def spec(parser, args): if env: env.concretize() specs = env.concretized_specs() + + # environments are printed together in a combined tree() invocation, + # except when using --yaml or --json, which we print spec by spec below. + if not args.format: + tree_kwargs["key"] = spack.traverse.by_dag_hash + tree_kwargs["hashes"] = args.long or args.very_long + print(spack.spec.tree([concrete for _, concrete in specs], **tree_kwargs)) + return else: tty.die("spack spec requires at least one spec or an active environment") for input, output in specs: - # With -y, just print YAML to output. + # With --yaml or --json, just print the raw specs to output if args.format: if args.format == "yaml": # use write because to_yaml already has a newline. diff --git a/lib/spack/spack/cmd/tutorial.py b/lib/spack/spack/cmd/tutorial.py index e0c49c831d4356..3dd7746f81b214 100644 --- a/lib/spack/spack/cmd/tutorial.py +++ b/lib/spack/spack/cmd/tutorial.py @@ -23,7 +23,7 @@ # tutorial configuration parameters -tutorial_branch = "releases/v0.21" +tutorial_branch = "releases/v0.22" tutorial_mirror = "file:///mirror" tutorial_key = os.path.join(spack.paths.share_path, "keys", "tutorial.pub") diff --git a/lib/spack/spack/cmd/uninstall.py b/lib/spack/spack/cmd/uninstall.py index 62a7ac1f327e0f..d51a8f8e3bc06e 100644 --- a/lib/spack/spack/cmd/uninstall.py +++ b/lib/spack/spack/cmd/uninstall.py @@ -151,7 +151,8 @@ def is_installed(spec): key=lambda s: s.dag_hash(), ) - return [spec for spec in specs if is_installed(spec)] + with spack.store.STORE.db.read_transaction(): + return [spec for spec in specs if is_installed(spec)] def dependent_environments( @@ -239,6 +240,8 @@ def get_uninstall_list(args, specs: List[spack.spec.Spec], env: Optional[ev.Envi print() tty.info("The following environments still reference these specs:") colify([e.name for e in other_dependent_envs.keys()], indent=4) + if env: + msgs.append("use `spack remove` to remove the spec from the current environment") msgs.append("use `spack env remove` to remove environments") msgs.append("use `spack uninstall --force` to override") print() diff --git a/lib/spack/spack/cmd/unit_test.py b/lib/spack/spack/cmd/unit_test.py index 2931be5e748bc8..c46012d5dc86d3 100644 --- a/lib/spack/spack/cmd/unit_test.py +++ b/lib/spack/spack/cmd/unit_test.py @@ -34,6 +34,13 @@ def setup_parser(subparser): default=False, help="show full pytest help, with advanced options", ) + subparser.add_argument( + "-n", + "--numprocesses", + type=int, + default=1, + help="run tests in parallel up to this wide, default 1 for sequential", + ) # extra spack arguments to list tests list_group = subparser.add_argument_group("listing tests") @@ -207,8 +214,6 @@ def unit_test(parser, args, unknown_args): # Ensure clingo is available before switching to the # mock configuration used by unit tests - # Note: skip on windows here because for the moment, - # clingo is wholly unsupported from bootstrap with spack.bootstrap.ensure_bootstrap_configuration(): spack.bootstrap.ensure_core_dependencies() if pytest is None: @@ -229,6 +234,16 @@ def unit_test(parser, args, unknown_args): if args.extension: pytest_root = spack.extensions.load_extension(args.extension) + if args.numprocesses is not None and args.numprocesses > 1: + pytest_args.extend( + [ + "--dist", + "loadfile", + "--tx", + f"{args.numprocesses}*popen//python=spack-tmpconfig spack python", + ] + ) + # pytest.ini lives in the root of the spack repository. with llnl.util.filesystem.working_dir(pytest_root): if args.list: diff --git a/lib/spack/spack/cmd/unload.py b/lib/spack/spack/cmd/unload.py index 3bafe5e8c62d83..65daabcd468181 100644 --- a/lib/spack/spack/cmd/unload.py +++ b/lib/spack/spack/cmd/unload.py @@ -71,7 +71,7 @@ def unload(parser, args): "Cannot specify specs on command line when unloading all specs with '--all'" ) - hashes = os.environ.get(uenv.spack_loaded_hashes_var, "").split(":") + hashes = os.environ.get(uenv.spack_loaded_hashes_var, "").split(os.pathsep) if args.specs: specs = [ spack.cmd.disambiguate_spec_from_hashes(spec, hashes) diff --git a/lib/spack/spack/cmd/view.py b/lib/spack/spack/cmd/view.py index 586a9c6eb41fca..103a6ffb0ea17f 100644 --- a/lib/spack/spack/cmd/view.py +++ b/lib/spack/spack/cmd/view.py @@ -38,10 +38,10 @@ import spack.cmd import spack.environment as ev +import spack.filesystem_view as fsv import spack.schema.projections import spack.store from spack.config import validate -from spack.filesystem_view import YamlFilesystemView, view_func_parser from spack.util import spack_yaml as s_yaml description = "project packages to a compact naming scheme on the filesystem" @@ -193,17 +193,13 @@ def view(parser, args): ordered_projections = {} # What method are we using for this view - if args.action in actions_link: - link_fn = view_func_parser(args.action) - else: - link_fn = view_func_parser("symlink") - - view = YamlFilesystemView( + link_type = args.action if args.action in actions_link else "symlink" + view = fsv.YamlFilesystemView( path, spack.store.STORE.layout, projections=ordered_projections, ignore_conflicts=getattr(args, "ignore_conflicts", False), - link=link_fn, + link_type=link_type, verbose=args.verbose, ) diff --git a/lib/spack/spack/compiler.py b/lib/spack/spack/compiler.py index 15c11995a7ce45..13049883e7f2bd 100644 --- a/lib/spack/spack/compiler.py +++ b/lib/spack/spack/compiler.py @@ -18,10 +18,11 @@ import llnl.util.tty as tty from llnl.util.filesystem import path_contains_subdirectory, paths_containing_libs -import spack.compilers import spack.error +import spack.schema.environment import spack.spec import spack.util.executable +import spack.util.libc import spack.util.module_cmd import spack.version from spack.util.environment import filter_system_paths @@ -107,7 +108,6 @@ def _parse_link_paths(string): """ lib_search_paths = False raw_link_dirs = [] - tty.debug("parsing implicit link info") for line in string.splitlines(): if lib_search_paths: if line.startswith("\t"): @@ -122,7 +122,7 @@ def _parse_link_paths(string): continue if _LINKER_LINE_IGNORE.match(line): continue - tty.debug("linker line: %s" % line) + tty.debug(f"implicit link dirs: link line: {line}") next_arg = False for arg in line.split(): @@ -138,15 +138,12 @@ def _parse_link_paths(string): link_dir_arg = _LINK_DIR_ARG.match(arg) if link_dir_arg: link_dir = link_dir_arg.group("dir") - tty.debug("linkdir: %s" % link_dir) raw_link_dirs.append(link_dir) link_dir_arg = _LIBPATH_ARG.match(arg) if link_dir_arg: link_dir = link_dir_arg.group("dir") - tty.debug("libpath: %s", link_dir) raw_link_dirs.append(link_dir) - tty.debug("found raw link dirs: %s" % ", ".join(raw_link_dirs)) implicit_link_dirs = list() visited = set() @@ -156,7 +153,7 @@ def _parse_link_paths(string): implicit_link_dirs.append(normalized_path) visited.add(normalized_path) - tty.debug("found link dirs: %s" % ", ".join(implicit_link_dirs)) + tty.debug(f"implicit link dirs: result: {', '.join(implicit_link_dirs)}") return implicit_link_dirs @@ -417,17 +414,35 @@ def real_version(self): self._real_version = self.version return self._real_version - def implicit_rpaths(self): + def implicit_rpaths(self) -> List[str]: if self.enable_implicit_rpaths is False: return [] - # Put CXX first since it has the most linking issues - # And because it has flags that affect linking - link_dirs = self._get_compiler_link_paths() + output = self.compiler_verbose_output + + if not output: + return [] + + link_dirs = _parse_non_system_link_dirs(output) all_required_libs = list(self.required_libs) + Compiler._all_compiler_rpath_libraries return list(paths_containing_libs(link_dirs, all_required_libs)) + @property + def default_libc(self) -> Optional["spack.spec.Spec"]: + """Determine libc targeted by the compiler from link line""" + output = self.compiler_verbose_output + + if not output: + return None + + dynamic_linker = spack.util.libc.parse_dynamic_linker(output) + + if not dynamic_linker: + return None + + return spack.util.libc.libc_from_dynamic_linker(dynamic_linker) + @property def required_libs(self): """For executables created with this compiler, the compiler libraries @@ -436,17 +451,17 @@ def required_libs(self): # By default every compiler returns the empty list return [] - def _get_compiler_link_paths(self): + @property + def compiler_verbose_output(self) -> Optional[str]: + """Verbose output from compiling a dummy C source file. Output is cached.""" + if not hasattr(self, "_compile_c_source_output"): + self._compile_c_source_output = self._compile_dummy_c_source() + return self._compile_c_source_output + + def _compile_dummy_c_source(self) -> Optional[str]: cc = self.cc if self.cc else self.cxx if not cc or not self.verbose_flag: - # Cannot determine implicit link paths without a compiler / verbose flag - return [] - - # What flag types apply to first_compiler, in what order - if cc == self.cc: - flags = ["cflags", "cppflags", "ldflags"] - else: - flags = ["cxxflags", "cppflags", "ldflags"] + return None try: tmpdir = tempfile.mkdtemp(prefix="spack-implicit-link-info") @@ -458,20 +473,19 @@ def _get_compiler_link_paths(self): "int main(int argc, char* argv[]) { (void)argc; (void)argv; return 0; }\n" ) cc_exe = spack.util.executable.Executable(cc) - for flag_type in flags: + for flag_type in ["cflags" if cc == self.cc else "cxxflags", "cppflags", "ldflags"]: cc_exe.add_default_arg(*self.flags.get(flag_type, [])) with self.compiler_environment(): - output = cc_exe(self.verbose_flag, fin, "-o", fout, output=str, error=str) - return _parse_non_system_link_dirs(output) + return cc_exe(self.verbose_flag, fin, "-o", fout, output=str, error=str) except spack.util.executable.ProcessError as pe: tty.debug("ProcessError: Command exited with non-zero status: " + pe.long_message) - return [] + return None finally: shutil.rmtree(tmpdir, ignore_errors=True) @property - def verbose_flag(self): + def verbose_flag(self) -> Optional[str]: """ This property should be overridden in the compiler subclass if a verbose flag is available. @@ -669,8 +683,8 @@ def __str__(self): @contextlib.contextmanager def compiler_environment(self): - # yield immediately if no modules - if not self.modules: + # Avoid modifying os.environ if possible. + if not self.modules and not self.environment: yield return @@ -680,20 +694,12 @@ def compiler_environment(self): try: # load modules and set env variables for module in self.modules: - # On cray, mic-knl module cannot be loaded without cce module - # See: https://github.com/spack/spack/issues/3153 - if os.environ.get("CRAY_CPU_TARGET") == "mic-knl": - spack.util.module_cmd.load_module("cce") spack.util.module_cmd.load_module(module) # apply other compiler environment changes - env = spack.util.environment.EnvironmentModifications() - env.extend(spack.schema.environment.parse(self.environment)) - env.apply_modifications() + spack.schema.environment.parse(self.environment).apply_modifications() yield - except BaseException: - raise finally: # Restore environment regardless of whether inner code succeeded os.environ.clear() diff --git a/lib/spack/spack/compilers/__init__.py b/lib/spack/spack/compilers/__init__.py index 9b73028b127838..9712b63077bdcb 100644 --- a/lib/spack/spack/compilers/__init__.py +++ b/lib/spack/spack/compilers/__init__.py @@ -10,6 +10,7 @@ import itertools import multiprocessing.pool import os +import warnings from typing import Dict, List, Optional, Tuple import archspec.cpu @@ -109,27 +110,33 @@ def _to_dict(compiler): return {"compiler": d} -def get_compiler_config(scope=None, init_config=False): +def get_compiler_config( + configuration: "spack.config.Configuration", + *, + scope: Optional[str] = None, + init_config: bool = False, +) -> List[Dict]: """Return the compiler configuration for the specified architecture.""" - - config = spack.config.get("compilers", scope=scope) or [] + config = configuration.get("compilers", scope=scope) or [] if config or not init_config: return config - merged_config = spack.config.get("compilers") + merged_config = configuration.get("compilers") if merged_config: # Config is empty for this scope # Do not init config because there is a non-empty scope return config - _init_compiler_config(scope=scope) - config = spack.config.get("compilers", scope=scope) + _init_compiler_config(configuration, scope=scope) + config = configuration.get("compilers", scope=scope) return config -def get_compiler_config_from_packages(scope=None): +def get_compiler_config_from_packages( + configuration: "spack.config.Configuration", *, scope: Optional[str] = None +) -> List[Dict]: """Return the compiler configuration from packages.yaml""" - config = spack.config.get("packages", scope=scope) + config = configuration.get("packages", scope=scope) if not config: return [] @@ -157,43 +164,66 @@ def _compiler_config_from_package_config(config): def _compiler_config_from_external(config): + extra_attributes_key = "extra_attributes" + compilers_key = "compilers" + c_key, cxx_key, fortran_key = "c", "cxx", "fortran" + + # Allow `@x.y.z` instead of `@=x.y.z` spec = spack.spec.parse_with_version_concrete(config["spec"]) - # use str(spec.versions) to allow `@x.y.z` instead of `@=x.y.z` + compiler_spec = spack.spec.CompilerSpec( package_name_to_compiler_name.get(spec.name, spec.name), spec.version ) - extra_attributes = config.get("extra_attributes", {}) - prefix = config.get("prefix", None) + err_header = f"The external spec '{spec}' cannot be used as a compiler" - compiler_class = class_for_compiler_name(compiler_spec.name) - paths = extra_attributes.get("paths", {}) - compiler_langs = ["cc", "cxx", "fc", "f77"] - for lang in compiler_langs: - if paths.setdefault(lang, None): - continue - - if not prefix: - continue + # If extra_attributes is not there I might not want to use this entry as a compiler, + # therefore just leave a debug message, but don't be loud with a warning. + if extra_attributes_key not in config: + tty.debug(f"[{__file__}] {err_header}: missing the '{extra_attributes_key}' key") + return None + extra_attributes = config[extra_attributes_key] - # Check for files that satisfy the naming scheme for this compiler - bindir = os.path.join(prefix, "bin") - for f, regex in itertools.product(os.listdir(bindir), compiler_class.search_regexps(lang)): - if regex.match(f): - paths[lang] = os.path.join(bindir, f) + # If I have 'extra_attributes' warn if 'compilers' is missing, or we don't have a C compiler + if compilers_key not in extra_attributes: + warnings.warn( + f"{err_header}: missing the '{compilers_key}' key under '{extra_attributes_key}'" + ) + return None + attribute_compilers = extra_attributes[compilers_key] - if all(v is None for v in paths.values()): + if c_key not in attribute_compilers: + warnings.warn( + f"{err_header}: missing the C compiler path under " + f"'{extra_attributes_key}:{compilers_key}'" + ) return None + c_compiler = attribute_compilers[c_key] + + # C++ and Fortran compilers are not mandatory, so let's just leave a debug trace + if cxx_key not in attribute_compilers: + tty.debug(f"[{__file__}] The external spec {spec} does not have a C++ compiler") + + if fortran_key not in attribute_compilers: + tty.debug(f"[{__file__}] The external spec {spec} does not have a Fortran compiler") + + # compilers format has cc/fc/f77, externals format has "c/fortran" + paths = { + "cc": c_compiler, + "cxx": attribute_compilers.get(cxx_key, None), + "fc": attribute_compilers.get(fortran_key, None), + "f77": attribute_compilers.get(fortran_key, None), + } if not spec.architecture: host_platform = spack.platforms.host() operating_system = host_platform.operating_system("default_os") target = host_platform.target("default_target").microarchitecture else: - target = spec.target + target = spec.architecture.target if not target: - host_platform = spack.platforms.host() - target = host_platform.target("default_target").microarchitecture + target = spack.platforms.host().target("default_target") + target = target.microarchitecture operating_system = spec.os if not operating_system: @@ -216,24 +246,26 @@ def _compiler_config_from_external(config): return compiler_entry -def _init_compiler_config(*, scope): +def _init_compiler_config( + configuration: "spack.config.Configuration", *, scope: Optional[str] +) -> None: """Compiler search used when Spack has no compilers.""" compilers = find_compilers() compilers_dict = [] for compiler in compilers: compilers_dict.append(_to_dict(compiler)) - spack.config.set("compilers", compilers_dict, scope=scope) + configuration.set("compilers", compilers_dict, scope=scope) def compiler_config_files(): config_files = list() config = spack.config.CONFIG - for scope in config.file_scopes: + for scope in config.writable_scopes: name = scope.name compiler_config = config.get("compilers", scope=name) if compiler_config: config_files.append(config.get_config_filename(name, "compilers")) - compiler_config_from_packages = get_compiler_config_from_packages(scope=name) + compiler_config_from_packages = get_compiler_config_from_packages(config, scope=name) if compiler_config_from_packages: config_files.append(config.get_config_filename(name, "packages")) return config_files @@ -246,7 +278,9 @@ def add_compilers_to_config(compilers, scope=None): compilers: a list of Compiler objects. scope: configuration scope to modify. """ - compiler_config = get_compiler_config(scope, init_config=False) + compiler_config = get_compiler_config( + configuration=spack.config.CONFIG, scope=scope, init_config=False + ) for compiler in compilers: if not compiler.cc: tty.debug(f"{compiler.spec} does not have a C compiler") @@ -295,7 +329,9 @@ def _remove_compiler_from_scope(compiler_spec, scope): True if one or more compiler entries were actually removed, False otherwise """ assert scope is not None, "a specific scope is needed when calling this function" - compiler_config = get_compiler_config(scope, init_config=False) + compiler_config = get_compiler_config( + configuration=spack.config.CONFIG, scope=scope, init_config=False + ) filtered_compiler_config = [ compiler_entry for compiler_entry in compiler_config @@ -310,21 +346,28 @@ def _remove_compiler_from_scope(compiler_spec, scope): # We need to preserve the YAML type for comments, hence we are copying the # items in the list that has just been retrieved compiler_config[:] = filtered_compiler_config - spack.config.set("compilers", compiler_config, scope=scope) + spack.config.CONFIG.set("compilers", compiler_config, scope=scope) return True -def all_compilers_config(scope=None, init_config=True): +def all_compilers_config( + configuration: "spack.config.Configuration", + *, + scope: Optional[str] = None, + init_config: bool = True, +) -> List["spack.compiler.Compiler"]: """Return a set of specs for all the compiler versions currently available to build with. These are instances of CompilerSpec. """ - from_packages_yaml = get_compiler_config_from_packages(scope) + from_packages_yaml = get_compiler_config_from_packages(configuration, scope=scope) if from_packages_yaml: init_config = False - from_compilers_yaml = get_compiler_config(scope, init_config) + from_compilers_yaml = get_compiler_config(configuration, scope=scope, init_config=init_config) result = from_compilers_yaml + from_packages_yaml - key = lambda c: _compiler_from_config_entry(c["compiler"]) + # Dedupe entries by the compiler they represent + # If the entry is invalid, treat it as unique for deduplication + key = lambda c: _compiler_from_config_entry(c["compiler"] or id(c)) return list(llnl.util.lang.dedupe(result, key=key)) @@ -332,7 +375,7 @@ def all_compiler_specs(scope=None, init_config=True): # Return compiler specs from the merged config. return [ spack.spec.parse_with_version_concrete(s["compiler"]["spec"], compiler=True) - for s in all_compilers_config(scope, init_config) + for s in all_compilers_config(spack.config.CONFIG, scope=scope, init_config=init_config) ] @@ -445,7 +488,7 @@ def supported_compilers_for_host_platform() -> List[str]: return supported_compilers_for_platform(host_plat) -def supported_compilers_for_platform(platform: spack.platforms.Platform) -> List[str]: +def supported_compilers_for_platform(platform: "spack.platforms.Platform") -> List[str]: """Return a set of compiler class objects supported by Spack that are also supported by the provided platform @@ -492,11 +535,20 @@ def find_specs_by_arch(compiler_spec, arch_spec, scope=None, init_config=True): def all_compilers(scope=None, init_config=True): - config = all_compilers_config(scope, init_config=init_config) - compilers = list() - for items in config: + return all_compilers_from( + configuration=spack.config.CONFIG, scope=scope, init_config=init_config + ) + + +def all_compilers_from(configuration, scope=None, init_config=True): + compilers = [] + for items in all_compilers_config( + configuration=configuration, scope=scope, init_config=init_config + ): items = items["compiler"] - compilers.append(_compiler_from_config_entry(items)) + compiler = _compiler_from_config_entry(items) # can be None in error case + if compiler: + compilers.append(compiler) return compilers @@ -507,7 +559,7 @@ def compilers_for_spec( """This gets all compilers that satisfy the supplied CompilerSpec. Returns an empty list if none are found. """ - config = all_compilers_config(scope, init_config) + config = all_compilers_config(spack.config.CONFIG, scope=scope, init_config=init_config) matches = set(find(compiler_spec, scope, init_config)) compilers = [] @@ -517,7 +569,7 @@ def compilers_for_spec( def compilers_for_arch(arch_spec, scope=None): - config = all_compilers_config(scope) + config = all_compilers_config(spack.config.CONFIG, scope=scope) return list(get_compilers(config, arch_spec=arch_spec)) @@ -603,7 +655,10 @@ def _compiler_from_config_entry(items): compiler = _compiler_cache.get(config_id, None) if compiler is None: - compiler = compiler_from_dict(items) + try: + compiler = compiler_from_dict(items) + except UnknownCompilerError as e: + warnings.warn(e.message) _compiler_cache[config_id] = compiler return compiler @@ -656,7 +711,9 @@ def get_compilers(config, cspec=None, arch_spec=None): raise ValueError(msg) continue - compilers.append(_compiler_from_config_entry(items)) + compiler = _compiler_from_config_entry(items) + if compiler: + compilers.append(compiler) return compilers @@ -933,10 +990,11 @@ def _default_make_compilers(cmp_id, paths): make_mixed_toolchain(flat_compilers) # Finally, create the compiler list - compilers = [] + compilers: List["spack.compiler.Compiler"] = [] for compiler_id, _, compiler in flat_compilers: make_compilers = getattr(compiler_id.os, "make_compilers", _default_make_compilers) - compilers.extend(make_compilers(compiler_id, compiler)) + candidates = make_compilers(compiler_id, compiler) + compilers.extend(x for x in candidates if x.cc is not None) return compilers diff --git a/lib/spack/spack/compilers/clang.py b/lib/spack/spack/compilers/clang.py index 88154a19219987..577586cda110d4 100644 --- a/lib/spack/spack/compilers/clang.py +++ b/lib/spack/spack/compilers/clang.py @@ -38,10 +38,10 @@ class Clang(Compiler): cxx_names = ["clang++"] # Subclasses use possible names of Fortran 77 compiler - f77_names = ["flang"] + f77_names = ["flang-new", "flang"] # Subclasses use possible names of Fortran 90 compiler - fc_names = ["flang"] + fc_names = ["flang-new", "flang"] version_argument = "--version" @@ -96,6 +96,8 @@ def verbose_flag(self): openmp_flag = "-fopenmp" + # C++ flags based on CMake Modules/Compiler/Clang.cmake + @property def cxx11_flag(self): if self.real_version < Version("3.3"): @@ -120,6 +122,24 @@ def cxx17_flag(self): return "-std=c++17" + @property + def cxx20_flag(self): + if self.real_version < Version("5.0"): + raise UnsupportedCompilerFlag(self, "the C++20 standard", "cxx20_flag", "< 5.0") + elif self.real_version < Version("11.0"): + return "-std=c++2a" + else: + return "-std=c++20" + + @property + def cxx23_flag(self): + if self.real_version < Version("12.0"): + raise UnsupportedCompilerFlag(self, "the C++23 standard", "cxx23_flag", "< 12.0") + elif self.real_version < Version("17.0"): + return "-std=c++2b" + else: + return "-std=c++23" + @property def c99_flag(self): return "-std=c99" @@ -142,7 +162,10 @@ def c17_flag(self): def c23_flag(self): if self.real_version < Version("9.0"): raise UnsupportedCompilerFlag(self, "the C23 standard", "c23_flag", "< 9.0") - return "-std=c2x" + elif self.real_version < Version("18.0"): + return "-std=c2x" + else: + return "-std=c23" @property def cc_pic_flag(self): @@ -171,10 +194,11 @@ def extract_version_from_output(cls, output): match = re.search( # Normal clang compiler versions are left as-is - r"clang version ([^ )\n]+)-svn[~.\w\d-]*|" + r"(?:clang|flang-new) version ([^ )\n]+)-svn[~.\w\d-]*|" # Don't include hyphenated patch numbers in the version # (see https://github.com/spack/spack/pull/14365 for details) - r"clang version ([^ )\n]+?)-[~.\w\d-]*|" r"clang version ([^ )\n]+)", + r"(?:clang|flang-new) version ([^ )\n]+?)-[~.\w\d-]*|" + r"(?:clang|flang-new) version ([^ )\n]+)", output, ) if match: diff --git a/lib/spack/spack/compilers/dpcpp.py b/lib/spack/spack/compilers/dpcpp.py deleted file mode 100644 index 392817fd39fc1d..00000000000000 --- a/lib/spack/spack/compilers/dpcpp.py +++ /dev/null @@ -1,34 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -import os - -import spack.compilers.oneapi - - -class Dpcpp(spack.compilers.oneapi.Oneapi): - """This is the same as the oneAPI compiler but uses dpcpp instead of - icpx (for DPC++ source files). It explicitly refers to dpcpp, so that - CMake test files which check the compiler name (e.g. CMAKE_CXX_COMPILER) - detect it as dpcpp. - - Ideally we could switch out icpx for dpcpp where needed in the oneAPI - compiler definition, but two things are needed for that: (a) a way to - tell the compiler that it should be using dpcpp and (b) a way to - customize the link_paths - - See also: https://www.intel.com/content/www/us/en/develop/documentation/oneapi-dpcpp-cpp-compiler-dev-guide-and-reference/top/compiler-setup/using-the-command-line/invoking-the-compiler.html - """ - - # Subclasses use possible names of C++ compiler - cxx_names = ["dpcpp"] - - # Named wrapper links within build_env_path - link_paths = { - "cc": os.path.join("oneapi", "icx"), - "cxx": os.path.join("oneapi", "dpcpp"), - "f77": os.path.join("oneapi", "ifx"), - "fc": os.path.join("oneapi", "ifx"), - } diff --git a/lib/spack/spack/compilers/msvc.py b/lib/spack/spack/compilers/msvc.py index cba2b6e41cc548..9914e5242a624e 100644 --- a/lib/spack/spack/compilers/msvc.py +++ b/lib/spack/spack/compilers/msvc.py @@ -8,7 +8,7 @@ import subprocess import sys import tempfile -from typing import Dict, List, Set +from typing import Dict, List import archspec.cpu @@ -20,15 +20,7 @@ from spack.error import SpackError from spack.version import Version, VersionRange -avail_fc_version: Set[str] = set() -fc_path: Dict[str, str] = dict() - -fortran_mapping = { - "2021.3.0": "19.29.30133", - "2021.2.1": "19.28.29913", - "2021.2.0": "19.28.29334", - "2021.1.0": "19.28.29333", -} +FC_PATH: Dict[str, str] = dict() class CmdCall: @@ -115,15 +107,13 @@ def command_str(self): return f"{script} {self.arch} {self.sdk_ver} {self.vcvars_ver}" -def get_valid_fortran_pth(comp_ver): - cl_ver = str(comp_ver) +def get_valid_fortran_pth(): + """Assign maximum available fortran compiler version""" + # TODO (johnwparent): validate compatibility w/ try compiler + # functionality when added sort_fn = lambda fc_ver: Version(fc_ver) - sort_fc_ver = sorted(list(avail_fc_version), key=sort_fn) - for ver in sort_fc_ver: - if ver in fortran_mapping: - if Version(cl_ver) <= Version(fortran_mapping[ver]): - return fc_path[ver] - return None + sort_fc_ver = sorted(list(FC_PATH.keys()), key=sort_fn) + return FC_PATH[sort_fc_ver[-1]] if sort_fc_ver else None class Msvc(Compiler): @@ -167,11 +157,9 @@ def __init__(self, *args, **kwargs): # This positional argument "paths" is later parsed and process by the base class # via the call to `super` later in this method paths = args[3] - # This positional argument "cspec" is also parsed and handled by the base class - # constructor - cspec = args[0] - new_pth = [pth if pth else get_valid_fortran_pth(cspec.version) for pth in paths] - paths[:] = new_pth + latest_fc = get_valid_fortran_pth() + new_pth = [pth if pth else latest_fc for pth in paths[2:]] + paths[2:] = new_pth # Initialize, deferring to base class but then adding the vcvarsallfile # file based on compiler executable path. super().__init__(*args, **kwargs) @@ -183,7 +171,7 @@ def __init__(self, *args, **kwargs): # and stores their path, but their respective VCVARS # file must be invoked before useage. env_cmds = [] - compiler_root = os.path.join(self.cc, "../../../../../../..") + compiler_root = os.path.join(os.path.dirname(self.cc), "../../../../../..") vcvars_script_path = os.path.join(compiler_root, "Auxiliary", "Build", "vcvars64.bat") # get current platform architecture and format for vcvars argument arch = spack.platforms.real_host().default.lower() @@ -198,11 +186,34 @@ def __init__(self, *args, **kwargs): # paths[2] refers to the fc path and is a generic check # for a fortran compiler if paths[2]: + + def get_oneapi_root(pth: str): + """From within a prefix known to be a oneAPI path + determine the oneAPI root path from arbitrary point + under root + + Args: + pth: path prefixed within oneAPI root + """ + if not pth: + return "" + while os.path.basename(pth) and os.path.basename(pth) != "oneAPI": + pth = os.path.dirname(pth) + return pth + # If this found, it sets all the vars - oneapi_root = os.getenv("ONEAPI_ROOT") + oneapi_root = get_oneapi_root(self.fc) + if not oneapi_root: + raise RuntimeError(f"Non-oneAPI Fortran compiler {self.fc} assigned to MSVC") oneapi_root_setvars = os.path.join(oneapi_root, "setvars.bat") + # some oneAPI exes return a version more precise than their + # install paths specify, so we determine path from + # the install path rather than the fc executable itself + numver = r"\d+\.\d+(?:\.\d+)?" + pattern = f"((?:{numver})|(?:latest))" + version_from_path = re.search(pattern, self.fc).group(1) oneapi_version_setvars = os.path.join( - oneapi_root, "compiler", str(self.ifx_version), "env", "vars.bat" + oneapi_root, "compiler", version_from_path, "env", "vars.bat" ) # order matters here, the specific version env must be invoked first, # otherwise it will be ignored if the root setvars sets up the oneapi @@ -314,23 +325,19 @@ def setup_custom_environment(self, pkg, env): @classmethod def fc_version(cls, fc): - # We're using intel for the Fortran compilers, which exist if - # ONEAPI_ROOT is a meaningful variable if not sys.platform == "win32": return "unknown" fc_ver = cls.default_version(fc) - avail_fc_version.add(fc_ver) - fc_path[fc_ver] = fc - if os.getenv("ONEAPI_ROOT"): - try: - sps = spack.operating_systems.windows_os.WindowsOs().compiler_search_paths - except AttributeError: - raise SpackError("Windows compiler search paths not established") - clp = spack.util.executable.which_string("cl", path=sps) - ver = cls.default_version(clp) - else: - ver = fc_ver - return ver + FC_PATH[fc_ver] = fc + try: + sps = spack.operating_systems.windows_os.WindowsOs().compiler_search_paths + except AttributeError: + raise SpackError( + "Windows compiler search paths not established, " + "please report this behavior to github.com/spack/spack" + ) + clp = spack.util.executable.which_string("cl", path=sps) + return cls.default_version(clp) if clp else fc_ver @classmethod def f77_version(cls, f77): diff --git a/lib/spack/spack/compilers/nag.py b/lib/spack/spack/compilers/nag.py index c12ccec7bfa1b8..6040b74a149ead 100644 --- a/lib/spack/spack/compilers/nag.py +++ b/lib/spack/spack/compilers/nag.py @@ -64,7 +64,7 @@ def verbose_flag(self): # # This way, we at least enable the implicit rpath detection, which is # based on compilation of a C file (see method - # spack.compiler._get_compiler_link_paths): in the case of a mixed + # spack.compiler._compile_dummy_c_source): in the case of a mixed # NAG/GCC toolchain, the flag will be passed to g++ (e.g. # 'g++ -Wl,-v ./main.c'), otherwise, the flag will be passed to nagfor # (e.g. 'nagfor -Wl,-v ./main.c' - note that nagfor recognizes '.c' diff --git a/lib/spack/spack/compilers/oneapi.py b/lib/spack/spack/compilers/oneapi.py index ecba99081a4b95..1baac8382687dd 100644 --- a/lib/spack/spack/compilers/oneapi.py +++ b/lib/spack/spack/compilers/oneapi.py @@ -4,7 +4,7 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) import os -from os.path import dirname +from os.path import dirname, join from llnl.util import tty @@ -135,8 +135,12 @@ def setup_custom_environment(self, pkg, env): # It is located in the same directory as the driver. Error message: # clang++: error: unable to execute command: # Executable "sycl-post-link" doesn't exist! - if self.cxx: + # also ensures that shared objects and libraries required by the compiler, + # e.g. libonnx, can be found succesfully + # due to a fix, this is no longer required for OneAPI versions >= 2024.2 + if self.cxx and pkg.spec.satisfies("%oneapi@:2024.1"): env.prepend_path("PATH", dirname(self.cxx)) + env.prepend_path("LD_LIBRARY_PATH", join(dirname(dirname(self.cxx)), "lib")) # 2024 release bumped the libsycl version because of an ABI # change, 2024 compilers are required. You will see this diff --git a/lib/spack/spack/concretize.py b/lib/spack/spack/concretize.py index 86e1eb9735028f..b311d777f45698 100644 --- a/lib/spack/spack/concretize.py +++ b/lib/spack/spack/concretize.py @@ -74,6 +74,10 @@ class Concretizer: #: during concretization. Used for testing and for mirror creation check_for_compiler_existence = None + #: Packages that the old concretizer cannot deal with correctly, and cannot build anyway. + #: Those will not be considered as providers for virtuals. + non_buildable_packages = {"glibc", "musl"} + def __init__(self, abstract_spec=None): if Concretizer.check_for_compiler_existence is None: Concretizer.check_for_compiler_existence = not spack.config.get( @@ -113,7 +117,11 @@ def _valid_virtuals_and_externals(self, spec): pref_key = lambda spec: 0 # no-op pref key if spec.virtual: - candidates = spack.repo.PATH.providers_for(spec) + candidates = [ + s + for s in spack.repo.PATH.providers_for(spec) + if s.name not in self.non_buildable_packages + ] if not candidates: raise spack.error.UnsatisfiableProviderSpecError(candidates[0], spec) @@ -749,7 +757,6 @@ def _concretize_specs_together_new(*abstract_specs, **kwargs): result = solver.solve( abstract_specs, tests=kwargs.get("tests", False), allow_deprecated=allow_deprecated ) - result.raise_if_unsat() return [s.copy() for s in result.specs] diff --git a/lib/spack/spack/config.py b/lib/spack/spack/config.py index 982b730f16e9bf..8c84af00e832c4 100644 --- a/lib/spack/spack/config.py +++ b/lib/spack/spack/config.py @@ -35,11 +35,10 @@ import os import re import sys -from typing import Any, Callable, Dict, Generator, List, Optional, Tuple, Type, Union +from typing import Any, Callable, Dict, Generator, List, Optional, Tuple, Union from llnl.util import filesystem, lang, tty -import spack.compilers import spack.paths import spack.platforms import spack.schema @@ -107,7 +106,7 @@ #: metavar to use for commands that accept scopes #: this is shorter and more readable than listing all choices -SCOPES_METAVAR = "{defaults,system,site,user}[/PLATFORM] or env:ENVIRONMENT" +SCOPES_METAVAR = "{defaults,system,site,user,command_line}[/PLATFORM] or env:ENVIRONMENT" #: Base name for the (internal) overrides scope. _OVERRIDES_BASE_NAME = "overrides-" @@ -117,21 +116,39 @@ class ConfigScope: - """This class represents a configuration scope. + def __init__(self, name: str) -> None: + self.name = name + self.writable = False + self.sections = syaml.syaml_dict() - A scope is one directory containing named configuration files. - Each file is a config "section" (e.g., mirrors, compilers, etc.). - """ + def get_section_filename(self, section: str) -> str: + raise NotImplementedError - def __init__(self, name, path) -> None: - self.name = name # scope name. - self.path = path # path to directory containing configs. - self.sections = syaml.syaml_dict() # sections read from config files. + def get_section(self, section: str) -> Optional[YamlConfigDict]: + raise NotImplementedError + + def _write_section(self, section: str) -> None: + raise NotImplementedError @property def is_platform_dependent(self) -> bool: - """Returns true if the scope name is platform specific""" - return os.sep in self.name + return False + + def clear(self) -> None: + """Empty cached config information.""" + self.sections = syaml.syaml_dict() + + def __repr__(self) -> str: + return f"" + + +class DirectoryConfigScope(ConfigScope): + """Config scope backed by a directory containing one file per section.""" + + def __init__(self, name: str, path: str, *, writable: bool = True) -> None: + super().__init__(name) + self.path = path + self.writable = writable def get_section_filename(self, section: str) -> str: """Returns the filename associated with a given section""" @@ -148,14 +165,15 @@ def get_section(self, section: str) -> Optional[YamlConfigDict]: return self.sections[section] def _write_section(self, section: str) -> None: + if not self.writable: + raise ConfigError(f"Cannot write to immutable scope {self}") + filename = self.get_section_filename(section) data = self.get_section(section) if data is None: return - # We copy data here to avoid adding defaults at write time - validate_data = copy.deepcopy(data) - validate(validate_data, SECTION_SCHEMAS[section]) + validate(data, SECTION_SCHEMAS[section]) try: filesystem.mkdirp(self.path) @@ -164,19 +182,23 @@ def _write_section(self, section: str) -> None: except (syaml.SpackYAMLError, OSError) as e: raise ConfigFileError(f"cannot write to '{filename}'") from e - def clear(self) -> None: - """Empty cached config information.""" - self.sections = syaml.syaml_dict() - - def __repr__(self) -> str: - return f"" + @property + def is_platform_dependent(self) -> bool: + """Returns true if the scope name is platform specific""" + return "/" in self.name class SingleFileScope(ConfigScope): """This class represents a configuration scope in a single YAML file.""" def __init__( - self, name: str, path: str, schema: YamlConfigDict, yaml_path: Optional[List[str]] = None + self, + name: str, + path: str, + schema: YamlConfigDict, + *, + yaml_path: Optional[List[str]] = None, + writable: bool = True, ) -> None: """Similar to ``ConfigScope`` but can be embedded in another schema. @@ -195,15 +217,13 @@ def __init__( config: install_tree: $spack/opt/spack """ - super().__init__(name, path) + super().__init__(name) self._raw_data: Optional[YamlConfigDict] = None self.schema = schema + self.path = path + self.writable = writable self.yaml_path = yaml_path or [] - @property - def is_platform_dependent(self) -> bool: - return False - def get_section_filename(self, section) -> str: return self.path @@ -257,6 +277,8 @@ def get_section(self, section: str) -> Optional[YamlConfigDict]: return self.sections.get(section, None) def _write_section(self, section: str) -> None: + if not self.writable: + raise ConfigError(f"Cannot write to immutable scope {self}") data_to_write: Optional[YamlConfigDict] = self._raw_data # If there is no existing data, this section SingleFileScope has never @@ -301,19 +323,6 @@ def __repr__(self) -> str: return f"" -class ImmutableConfigScope(ConfigScope): - """A configuration scope that cannot be written to. - - This is used for ConfigScopes passed on the command line. - """ - - def _write_section(self, section) -> None: - raise ConfigError(f"Cannot write to immutable scope {self}") - - def __repr__(self) -> str: - return f"" - - class InternalConfigScope(ConfigScope): """An internal configuration scope that is not persisted to a file. @@ -323,7 +332,7 @@ class InternalConfigScope(ConfigScope): """ def __init__(self, name: str, data: Optional[YamlConfigDict] = None) -> None: - super().__init__(name, None) + super().__init__(name) self.sections = syaml.syaml_dict() if data is not None: @@ -333,9 +342,6 @@ def __init__(self, name: str, data: Optional[YamlConfigDict] = None) -> None: validate({section: dsec}, SECTION_SCHEMAS[section]) self.sections[section] = _mark_internal(syaml.syaml_dict({section: dsec}), name) - def get_section_filename(self, section: str) -> str: - raise NotImplementedError("Cannot get filename for InternalConfigScope.") - def get_section(self, section: str) -> Optional[YamlConfigDict]: """Just reads from an internal dictionary.""" if section not in self.sections: @@ -440,27 +446,21 @@ def remove_scope(self, scope_name: str) -> Optional[ConfigScope]: return scope @property - def file_scopes(self) -> List[ConfigScope]: - """List of writable scopes with an associated file.""" - return [ - s - for s in self.scopes.values() - if (type(s) is ConfigScope or type(s) is SingleFileScope) - ] + def writable_scopes(self) -> Generator[ConfigScope, None, None]: + """Generator of writable scopes with an associated file.""" + return (s for s in self.scopes.values() if s.writable) def highest_precedence_scope(self) -> ConfigScope: - """Non-internal scope with highest precedence.""" - return next(reversed(self.file_scopes)) + """Writable scope with highest precedence.""" + return next(s for s in reversed(self.scopes.values()) if s.writable) # type: ignore def highest_precedence_non_platform_scope(self) -> ConfigScope: - """Non-internal non-platform scope with highest precedence - - Platform-specific scopes are of the form scope/platform""" - generator = reversed(self.file_scopes) - highest = next(generator) - while highest and highest.is_platform_dependent: - highest = next(generator) - return highest + """Writable non-platform scope with highest precedence""" + return next( + s + for s in reversed(self.scopes.values()) # type: ignore + if s.writable and not s.is_platform_dependent + ) def matching_scopes(self, reg_expr) -> List[ConfigScope]: """ @@ -755,13 +755,14 @@ def override( def _add_platform_scope( - cfg: Union[Configuration, lang.Singleton], scope_type: Type[ConfigScope], name: str, path: str + cfg: Union[Configuration, lang.Singleton], name: str, path: str, writable: bool = True ) -> None: """Add a platform-specific subdirectory for the current platform.""" platform = spack.platforms.host().name - plat_name = os.path.join(name, platform) - plat_path = os.path.join(path, platform) - cfg.push_scope(scope_type(plat_name, plat_path)) + scope = DirectoryConfigScope( + f"{name}/{platform}", os.path.join(path, platform), writable=writable + ) + cfg.push_scope(scope) def config_paths_from_entry_points() -> List[Tuple[str, str]]: @@ -792,22 +793,27 @@ def config_paths_from_entry_points() -> List[Tuple[str, str]]: def _add_command_line_scopes( cfg: Union[Configuration, lang.Singleton], command_line_scopes: List[str] ) -> None: - """Add additional scopes from the --config-scope argument. + """Add additional scopes from the --config-scope argument, either envs or dirs.""" + import spack.environment.environment as env # circular import - Command line scopes are named after their position in the arg list. - """ for i, path in enumerate(command_line_scopes): - # We ensure that these scopes exist and are readable, as they are - # provided on the command line by the user. - if not os.path.isdir(path): - raise ConfigError(f"config scope is not a directory: '{path}'") - elif not os.access(path, os.R_OK): - raise ConfigError(f"config scope is not readable: '{path}'") + name = f"cmd_scope_{i}" + + if env.exists(path): # managed environment + manifest = env.EnvironmentManifestFile(env.root(path)) + elif env.is_env_dir(path): # anonymous environment + manifest = env.EnvironmentManifestFile(path) + elif os.path.isdir(path): # directory with config files + cfg.push_scope(DirectoryConfigScope(name, path, writable=False)) + _add_platform_scope(cfg, name, path, writable=False) + continue + else: + raise ConfigError(f"Invalid configuration scope: {path}") - # name based on order on the command line - name = f"cmd_scope_{i:d}" - cfg.push_scope(ImmutableConfigScope(name, path)) - _add_platform_scope(cfg, ImmutableConfigScope, name, path) + for scope in manifest.env_config_scopes: + scope.name = f"{name}:{scope.name}" + scope.writable = False + cfg.push_scope(scope) def create() -> Configuration: @@ -851,10 +857,10 @@ def create() -> Configuration: # add each scope and its platform-specific directory for name, path in configuration_paths: - cfg.push_scope(ConfigScope(name, path)) + cfg.push_scope(DirectoryConfigScope(name, path)) # Each scope can have per-platfom overrides in subdirectories - _add_platform_scope(cfg, ConfigScope, name, path) + _add_platform_scope(cfg, name, path) # add command-line scopes _add_command_line_scopes(cfg, COMMAND_LINE_SCOPES) @@ -969,7 +975,7 @@ def set(path: str, value: Any, scope: Optional[str] = None) -> None: def add_default_platform_scope(platform: str) -> None: plat_name = os.path.join("defaults", platform) plat_path = os.path.join(CONFIGURATION_DEFAULTS_PATH[1], platform) - CONFIG.push_scope(ConfigScope(plat_name, plat_path)) + CONFIG.push_scope(DirectoryConfigScope(plat_name, plat_path)) def scopes() -> Dict[str, ConfigScope]: @@ -978,19 +984,10 @@ def scopes() -> Dict[str, ConfigScope]: def writable_scopes() -> List[ConfigScope]: - """ - Return list of writable scopes. Higher-priority scopes come first in the - list. - """ - return list( - reversed( - list( - x - for x in CONFIG.scopes.values() - if not isinstance(x, (InternalConfigScope, ImmutableConfigScope)) - ) - ) - ) + """Return list of writable scopes. Higher-priority scopes come first in the list.""" + scopes = [x for x in CONFIG.scopes.values() if x.writable] + scopes.reverse() + return scopes def writable_scope_names() -> List[str]: @@ -1080,11 +1077,8 @@ def validate( """ import jsonschema - # Validate a copy to avoid adding defaults - # This allows us to round-trip data without adding to it. - test_data = syaml.deepcopy(data) try: - spack.schema.Validator(schema).validate(test_data) + spack.schema.Validator(schema).validate(data) except jsonschema.ValidationError as e: if hasattr(e.instance, "lc"): line_number = e.instance.lc.line + 1 @@ -1093,7 +1087,7 @@ def validate( raise ConfigFormatError(e, data, filename, line_number) from e # return the validated data so that we can access the raw data # mostly relevant for environments - return test_data + return data def read_config_file( @@ -1562,8 +1556,9 @@ def ensure_latest_format_fn(section: str) -> Callable[[YamlConfigDict], bool]: def use_configuration( *scopes_or_paths: Union[ConfigScope, str] ) -> Generator[Configuration, None, None]: - """Use the configuration scopes passed as arguments within the - context manager. + """Use the configuration scopes passed as arguments within the context manager. + + This function invalidates caches, and is therefore very slow. Args: *scopes_or_paths: scope objects or paths to be used @@ -1598,7 +1593,7 @@ def _config_from(scopes_or_paths: List[Union[ConfigScope, str]]) -> Configuratio path = os.path.normpath(scope_or_path) assert os.path.isdir(path), f'"{path}" must be a directory' name = os.path.basename(path) - scopes.append(ConfigScope(name, path)) + scopes.append(DirectoryConfigScope(name, path)) configuration = Configuration(*scopes) return configuration diff --git a/lib/spack/spack/container/images.json b/lib/spack/spack/container/images.json index b78b180333909c..72029faceafd23 100644 --- a/lib/spack/spack/container/images.json +++ b/lib/spack/spack/container/images.json @@ -12,26 +12,26 @@ }, "os_package_manager": "yum_amazon" }, - "fedora:38": { + "fedora:40": { "bootstrap": { - "template": "container/fedora_38.dockerfile", - "image": "docker.io/fedora:38" + "template": "container/fedora.dockerfile", + "image": "docker.io/fedora:40" }, "os_package_manager": "dnf", - "build": "spack/fedora38", + "build": "spack/fedora40", "final": { - "image": "docker.io/fedora:38" + "image": "docker.io/fedora:40" } }, - "fedora:37": { + "fedora:39": { "bootstrap": { - "template": "container/fedora_37.dockerfile", - "image": "docker.io/fedora:37" + "template": "container/fedora.dockerfile", + "image": "docker.io/fedora:39" }, "os_package_manager": "dnf", - "build": "spack/fedora37", + "build": "spack/fedora39", "final": { - "image": "docker.io/fedora:37" + "image": "docker.io/fedora:39" } }, "rockylinux:9": { @@ -78,24 +78,17 @@ "image": "quay.io/almalinuxorg/almalinux:8" } }, - "centos:stream": { + "centos:stream9": { "bootstrap": { - "template": "container/centos_stream.dockerfile", - "image": "quay.io/centos/centos:stream" + "template": "container/centos_stream9.dockerfile", + "image": "quay.io/centos/centos:stream9" }, "os_package_manager": "dnf_epel", - "build": "spack/centos-stream", + "build": "spack/centos-stream9", "final": { - "image": "quay.io/centos/centos:stream" + "image": "quay.io/centos/centos:stream9" } }, - "centos:7": { - "bootstrap": { - "template": "container/centos_7.dockerfile" - }, - "os_package_manager": "yum", - "build": "spack/centos7" - }, "opensuse/leap:15": { "bootstrap": { "template": "container/leap-15.dockerfile" @@ -116,6 +109,13 @@ }, "os_package_manager": "apt" }, + "ubuntu:24.04": { + "bootstrap": { + "template": "container/ubuntu_2404.dockerfile" + }, + "os_package_manager": "apt", + "build": "spack/ubuntu-noble" + }, "ubuntu:22.04": { "bootstrap": { "template": "container/ubuntu_2204.dockerfile" @@ -129,13 +129,6 @@ }, "build": "spack/ubuntu-focal", "os_package_manager": "apt" - }, - "ubuntu:18.04": { - "bootstrap": { - "template": "container/ubuntu_1804.dockerfile" - }, - "os_package_manager": "apt", - "build": "spack/ubuntu-bionic" } }, "os_package_managers": { diff --git a/lib/spack/spack/database.py b/lib/spack/spack/database.py index c2f0567d22fb05..3c7dff96dbb802 100644 --- a/lib/spack/spack/database.py +++ b/lib/spack/spack/database.py @@ -25,6 +25,7 @@ import socket import sys import time +from json import JSONDecoder from typing import ( Any, Callable, @@ -818,7 +819,8 @@ def _read_from_file(self, filename): """ try: with open(filename, "r") as f: - fdata = sjson.load(f) + # In the future we may use a stream of JSON objects, hence `raw_decode` for compat. + fdata, _ = JSONDecoder().raw_decode(f.read()) except Exception as e: raise CorruptDatabaseError("error parsing database:", str(e)) from e @@ -833,27 +835,24 @@ def check(cond, msg): # High-level file checks db = fdata["database"] - check("installs" in db, "no 'installs' in JSON DB.") check("version" in db, "no 'version' in JSON DB.") - installs = db["installs"] - # TODO: better version checking semantics. version = vn.Version(db["version"]) if version > _DB_VERSION: raise InvalidDatabaseVersionError(self, _DB_VERSION, version) - elif version < _DB_VERSION: - if not any(old == version and new == _DB_VERSION for old, new in _SKIP_REINDEX): - tty.warn( - "Spack database version changed from %s to %s. Upgrading." - % (version, _DB_VERSION) - ) - - self.reindex(spack.store.STORE.layout) - installs = dict( - (k, v.to_dict(include_fields=self._record_fields)) - for k, v in self._data.items() - ) + elif version < _DB_VERSION and not any( + old == version and new == _DB_VERSION for old, new in _SKIP_REINDEX + ): + tty.warn(f"Spack database version changed from {version} to {_DB_VERSION}. Upgrading.") + + self.reindex(spack.store.STORE.layout) + installs = dict( + (k, v.to_dict(include_fields=self._record_fields)) for k, v in self._data.items() + ) + else: + check("installs" in db, "no 'installs' in JSON DB.") + installs = db["installs"] spec_reader = reader(version) @@ -1621,15 +1620,32 @@ def query_local(self, *args, **kwargs): query_local.__doc__ += _QUERY_DOCSTRING def query(self, *args, **kwargs): - """Query the Spack database including all upstream databases.""" + """Query the Spack database including all upstream databases. + + Additional Arguments: + install_tree (str): query 'all' (default), 'local', 'upstream', or upstream path + """ + install_tree = kwargs.pop("install_tree", "all") + valid_trees = ["all", "upstream", "local", self.root] + [u.root for u in self.upstream_dbs] + if install_tree not in valid_trees: + msg = "Invalid install_tree argument to Database.query()\n" + msg += f"Try one of {', '.join(valid_trees)}" + tty.error(msg) + return [] + upstream_results = [] - for upstream_db in self.upstream_dbs: + upstreams = self.upstream_dbs + if install_tree not in ("all", "upstream"): + upstreams = [u for u in self.upstream_dbs if u.root == install_tree] + for upstream_db in upstreams: # queries for upstream DBs need to *not* lock - we may not # have permissions to do this and the upstream DBs won't know about # us anyway (so e.g. they should never uninstall specs) upstream_results.extend(upstream_db._query(*args, **kwargs) or []) - local_results = set(self.query_local(*args, **kwargs)) + local_results = [] + if install_tree in ("all", "local") or self.root == install_tree: + local_results = set(self.query_local(*args, **kwargs)) results = list(local_results) + list(x for x in upstream_results if x not in local_results) diff --git a/lib/spack/spack/detection/__init__.py b/lib/spack/spack/detection/__init__.py index 44225ef0620087..1cff789c26288a 100644 --- a/lib/spack/spack/detection/__init__.py +++ b/lib/spack/spack/detection/__init__.py @@ -2,7 +2,12 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -from .common import DetectedPackage, executable_prefix, update_configuration +from .common import ( + DetectedPackage, + executable_prefix, + set_virtuals_nonbuildable, + update_configuration, +) from .path import by_path, executables_in_path from .test import detection_tests @@ -12,5 +17,6 @@ "executables_in_path", "executable_prefix", "update_configuration", + "set_virtuals_nonbuildable", "detection_tests", ] diff --git a/lib/spack/spack/detection/common.py b/lib/spack/spack/detection/common.py index 516bd11c8d506b..ae3c1927d29049 100644 --- a/lib/spack/spack/detection/common.py +++ b/lib/spack/spack/detection/common.py @@ -252,6 +252,27 @@ def update_configuration( return all_new_specs +def set_virtuals_nonbuildable(virtuals: Set[str], scope: Optional[str] = None) -> List[str]: + """Update packages:virtual:buildable:False for the provided virtual packages, if the property + is not set by the user. Returns the list of virtual packages that have been updated.""" + packages = spack.config.get("packages") + new_config = {} + for virtual in virtuals: + # If the user has set the buildable prop do not override it + if virtual in packages and "buildable" in packages[virtual]: + continue + new_config[virtual] = {"buildable": False} + + # Update the provided scope + spack.config.set( + "packages", + spack.config.merge_yaml(spack.config.get("packages", scope=scope), new_config), + scope=scope, + ) + + return list(new_config.keys()) + + def _windows_drive() -> str: """Return Windows drive string extracted from the PROGRAMFILES environment variable, which is guaranteed to be defined for all logins. diff --git a/lib/spack/spack/detection/path.py b/lib/spack/spack/detection/path.py index 514d1c13e28b47..943de16ee668ba 100644 --- a/lib/spack/spack/detection/path.py +++ b/lib/spack/spack/detection/path.py @@ -12,7 +12,7 @@ import re import sys import warnings -from typing import Dict, List, Optional, Set, Tuple +from typing import Dict, List, Optional, Set, Tuple, Type import llnl.util.filesystem import llnl.util.lang @@ -83,26 +83,15 @@ def executables_in_path(path_hints: List[str]) -> Dict[str, str]: return path_to_dict(search_paths) -def get_elf_compat(path): - """For ELF files, get a triplet (EI_CLASS, EI_DATA, e_machine) and see if - it is host-compatible.""" - # On ELF platforms supporting, we try to be a bit smarter when it comes to shared - # libraries, by dropping those that are not host compatible. - with open(path, "rb") as f: - elf = elf_utils.parse_elf(f, only_header=True) - return (elf.is_64_bit, elf.is_little_endian, elf.elf_hdr.e_machine) - - def accept_elf(path, host_compat): - """Accept an ELF file if the header matches the given compat triplet, - obtained with :py:func:`get_elf_compat`. In case it's not an ELF (e.g. - static library, or some arbitrary file, fall back to is_readable_file).""" + """Accept an ELF file if the header matches the given compat triplet. In case it's not an ELF + (e.g. static library, or some arbitrary file, fall back to is_readable_file).""" # Fast path: assume libraries at least have .so in their basename. # Note: don't replace with splitext, because of libsmth.so.1.2.3 file names. if ".so" not in os.path.basename(path): return llnl.util.filesystem.is_readable_file(path) try: - return host_compat == get_elf_compat(path) + return host_compat == elf_utils.get_elf_compat(path) except (OSError, elf_utils.ElfParsingError): return llnl.util.filesystem.is_readable_file(path) @@ -155,7 +144,7 @@ def libraries_in_ld_and_system_library_path( search_paths = list(llnl.util.lang.dedupe(search_paths, key=file_identifier)) try: - host_compat = get_elf_compat(sys.executable) + host_compat = elf_utils.get_elf_compat(sys.executable) accept = lambda path: accept_elf(path, host_compat) except (OSError, elf_utils.ElfParsingError): accept = llnl.util.filesystem.is_readable_file @@ -211,7 +200,7 @@ class Finder: def default_path_hints(self) -> List[str]: return [] - def search_patterns(self, *, pkg: "spack.package_base.PackageBase") -> List[str]: + def search_patterns(self, *, pkg: Type["spack.package_base.PackageBase"]) -> List[str]: """Returns the list of patterns used to match candidate files. Args: @@ -237,7 +226,7 @@ def prefix_from_path(self, *, path: str) -> str: raise NotImplementedError("must be implemented by derived classes") def detect_specs( - self, *, pkg: "spack.package_base.PackageBase", paths: List[str] + self, *, pkg: Type["spack.package_base.PackageBase"], paths: List[str] ) -> List[DetectedPackage]: """Given a list of files matching the search patterns, returns a list of detected specs. @@ -338,7 +327,7 @@ class ExecutablesFinder(Finder): def default_path_hints(self) -> List[str]: return spack.util.environment.get_path("PATH") - def search_patterns(self, *, pkg: "spack.package_base.PackageBase") -> List[str]: + def search_patterns(self, *, pkg: Type["spack.package_base.PackageBase"]) -> List[str]: result = [] if hasattr(pkg, "executables") and hasattr(pkg, "platform_executables"): result = pkg.platform_executables() @@ -367,7 +356,7 @@ class LibrariesFinder(Finder): DYLD_LIBRARY_PATH, DYLD_FALLBACK_LIBRARY_PATH, and standard system library paths """ - def search_patterns(self, *, pkg: "spack.package_base.PackageBase") -> List[str]: + def search_patterns(self, *, pkg: Type["spack.package_base.PackageBase"]) -> List[str]: result = [] if hasattr(pkg, "libraries"): result = pkg.libraries diff --git a/lib/spack/spack/detection/test.py b/lib/spack/spack/detection/test.py index 657188a38cdb2d..353a0a56602d60 100644 --- a/lib/spack/spack/detection/test.py +++ b/lib/spack/spack/detection/test.py @@ -11,6 +11,7 @@ from llnl.util import filesystem +import spack.platforms import spack.repo import spack.spec from spack.util import spack_yaml @@ -32,6 +33,8 @@ class ExpectedTestResult(NamedTuple): #: Spec to be detected spec: str + #: Attributes expected in the external spec + extra_attributes: Dict[str, str] class DetectionTest(NamedTuple): @@ -100,7 +103,10 @@ def _create_executable_scripts(self, mock_executables: MockExecutables) -> List[ @property def expected_specs(self) -> List[spack.spec.Spec]: - return [spack.spec.Spec(r.spec) for r in self.test.results] + return [ + spack.spec.Spec.from_detection(item.spec, extra_attributes=item.extra_attributes) + for item in self.test.results + ] def detection_tests(pkg_name: str, repository: spack.repo.RepoPath) -> List[Runner]: @@ -117,9 +123,13 @@ def detection_tests(pkg_name: str, repository: spack.repo.RepoPath) -> List[Runn """ result = [] detection_tests_content = read_detection_tests(pkg_name, repository) + current_platform = str(spack.platforms.host()) tests_by_path = detection_tests_content.get("paths", []) for single_test_data in tests_by_path: + if current_platform not in single_test_data.get("platforms", [current_platform]): + continue + mock_executables = [] for layout in single_test_data["layout"]: mock_executables.append( @@ -127,7 +137,11 @@ def detection_tests(pkg_name: str, repository: spack.repo.RepoPath) -> List[Runn ) expected_results = [] for assertion in single_test_data["results"]: - expected_results.append(ExpectedTestResult(spec=assertion["spec"])) + expected_results.append( + ExpectedTestResult( + spec=assertion["spec"], extra_attributes=assertion.get("extra_attributes", {}) + ) + ) current_test = DetectionTest( pkg_name=pkg_name, layout=mock_executables, results=expected_results diff --git a/lib/spack/spack/directives.py b/lib/spack/spack/directives.py index 0d4834ed138c7c..18462fb72670b6 100644 --- a/lib/spack/spack/directives.py +++ b/lib/spack/spack/directives.py @@ -27,6 +27,7 @@ class OpenMpi(Package): * ``variant`` * ``version`` * ``requires`` + * ``redistribute`` """ import collections @@ -63,6 +64,7 @@ class OpenMpi(Package): __all__ = [ "DirectiveError", "DirectiveMeta", + "DisableRedistribute", "version", "conflicts", "depends_on", @@ -75,6 +77,7 @@ class OpenMpi(Package): "resource", "build_system", "requires", + "redistribute", ] #: These are variant names used by Spack internally; packages can't use them @@ -87,13 +90,16 @@ class OpenMpi(Package): _patch_order_index = 0 -SpecType = Union["spack.spec.Spec", str] +SpecType = str DepType = Union[Tuple[str, ...], str] WhenType = Optional[Union["spack.spec.Spec", str, bool]] Patcher = Callable[[Union["spack.package_base.PackageBase", Dependency]], None] PatchesType = Optional[Union[Patcher, str, List[Union[Patcher, str]]]] +SUPPORTED_LANGUAGES = ("fortran", "cxx", "c") + + def _make_when_spec(value: WhenType) -> Optional["spack.spec.Spec"]: """Create a ``Spec`` that indicates when a directive should be applied. @@ -469,7 +475,7 @@ def _execute_version(pkg, ver, **kwargs): def _depends_on( pkg: "spack.package_base.PackageBase", - spec: SpecType, + spec: "spack.spec.Spec", *, when: WhenType = None, type: DepType = dt.DEFAULT_TYPES, @@ -479,11 +485,10 @@ def _depends_on( if not when_spec: return - dep_spec = spack.spec.Spec(spec) - if not dep_spec.name: - raise DependencyError("Invalid dependency specification in package '%s':" % pkg.name, spec) - if pkg.name == dep_spec.name: - raise CircularReferenceError("Package '%s' cannot depend on itself." % pkg.name) + if not spec.name: + raise DependencyError(f"Invalid dependency specification in package '{pkg.name}':", spec) + if pkg.name == spec.name: + raise CircularReferenceError(f"Package '{pkg.name}' cannot depend on itself.") depflag = dt.canonicalize(type) @@ -499,7 +504,7 @@ def _depends_on( # ensure `Spec.virtual` is a valid thing to call in a directive. # For now, we comment out the following check to allow for virtual packages # with package files. - # if patches and dep_spec.virtual: + # if patches and spec.virtual: # raise DependencyPatchError("Cannot patch a virtual dependency.") # ensure patches is a list @@ -514,13 +519,13 @@ def _depends_on( # this is where we actually add the dependency to this package deps_by_name = pkg.dependencies.setdefault(when_spec, {}) - dependency = deps_by_name.get(dep_spec.name) + dependency = deps_by_name.get(spec.name) if not dependency: - dependency = Dependency(pkg, dep_spec, depflag=depflag) - deps_by_name[dep_spec.name] = dependency + dependency = Dependency(pkg, spec, depflag=depflag) + deps_by_name[spec.name] = dependency else: - dependency.spec.constrain(dep_spec, deps=False) + dependency.spec.constrain(spec, deps=False) dependency.depflag |= depflag # apply patches to the dependency @@ -585,33 +590,100 @@ def depends_on( @see The section "Dependency specs" in the Spack Packaging Guide. """ + dep_spec = spack.spec.Spec(spec) + if dep_spec.name in SUPPORTED_LANGUAGES: + assert type == "build", "languages must be of 'build' type" + return _language(lang_spec_str=spec, when=when) def _execute_depends_on(pkg: "spack.package_base.PackageBase"): - _depends_on(pkg, spec, when=when, type=type, patches=patches) + _depends_on(pkg, dep_spec, when=when, type=type, patches=patches) return _execute_depends_on +#: Store whether a given Spec source/binary should not be redistributed. +class DisableRedistribute: + def __init__(self, source, binary): + self.source = source + self.binary = binary + + +@directive("disable_redistribute") +def redistribute(source=None, binary=None, when: WhenType = None): + """Can be used inside a Package definition to declare that + the package source and/or compiled binaries should not be + redistributed. + + By default, Packages allow source/binary distribution (i.e. in + mirrors). Because of this, and because overlapping enable/ + disable specs are not allowed, this directive only allows users + to explicitly disable redistribution for specs. + """ + + return lambda pkg: _execute_redistribute(pkg, source, binary, when) + + +def _execute_redistribute( + pkg: "spack.package_base.PackageBase", source=None, binary=None, when: WhenType = None +): + if source is None and binary is None: + return + elif (source is True) or (binary is True): + raise DirectiveError( + "Source/binary distribution are true by default, they can only " + "be explicitly disabled." + ) + + if source is None: + source = True + if binary is None: + binary = True + + when_spec = _make_when_spec(when) + if not when_spec: + return + if source is False: + max_constraint = spack.spec.Spec(f"{pkg.name}@{when_spec.versions}") + if not max_constraint.satisfies(when_spec): + raise DirectiveError("Source distribution can only be disabled for versions") + + if when_spec in pkg.disable_redistribute: + disable = pkg.disable_redistribute[when_spec] + if not source: + disable.source = True + if not binary: + disable.binary = True + else: + pkg.disable_redistribute[when_spec] = DisableRedistribute( + source=not source, binary=not binary + ) + + @directive(("extendees", "dependencies")) def extends(spec, when=None, type=("build", "run"), patches=None): """Same as depends_on, but also adds this package to the extendee list. + In case of Python, also adds a dependency on python-venv. keyword arguments can be passed to extends() so that extension packages can pass parameters to the extendee's extension - mechanism. - - """ + mechanism.""" def _execute_extends(pkg): when_spec = _make_when_spec(when) if not when_spec: return - _depends_on(pkg, spec, when=when, type=type, patches=patches) - spec_obj = spack.spec.Spec(spec) + dep_spec = spack.spec.Spec(spec) + + _depends_on(pkg, dep_spec, when=when, type=type, patches=patches) + + # When extending python, also add a dependency on python-venv. This is done so that + # Spack environment views are Python virtual environments. + if dep_spec.name == "python" and not pkg.name == "python-venv": + _depends_on(pkg, spack.spec.Spec("python-venv"), when=when, type=("build", "run")) # TODO: the values of the extendees dictionary are not used. Remove in next refactor. - pkg.extendees[spec_obj.name] = (spec_obj, None) + pkg.extendees[dep_spec.name] = (dep_spec, None) return _execute_extends @@ -967,7 +1039,6 @@ def license( checked_by: string or list of strings indicating which github user checked the license (if any). when: A spec specifying when the license applies. - when: A spec specifying when the license applies. """ return lambda pkg: _execute_license(pkg, license_identifier, when) @@ -1014,6 +1085,21 @@ def _execute_requires(pkg: "spack.package_base.PackageBase"): return _execute_requires +@directive("languages") +def _language(lang_spec_str: str, *, when: Optional[Union[str, bool]] = None): + """Temporary implementation of language virtuals, until compilers are proper dependencies.""" + + def _execute_languages(pkg: "spack.package_base.PackageBase"): + when_spec = _make_when_spec(when) + if not when_spec: + return + + languages = pkg.languages.setdefault(when_spec, set()) + languages.add(lang_spec_str) + + return _execute_languages + + class DirectiveError(spack.error.SpackError): """This is raised when something is wrong with a package directive.""" diff --git a/lib/spack/spack/directory_layout.py b/lib/spack/spack/directory_layout.py index b7a9b93431ce00..923e89cf771446 100644 --- a/lib/spack/spack/directory_layout.py +++ b/lib/spack/spack/directory_layout.py @@ -15,6 +15,7 @@ import llnl.util.filesystem as fs import llnl.util.tty as tty +from llnl.util.symlink import readlink import spack.config import spack.hash_types as ht @@ -181,7 +182,7 @@ def deprecated_file_path(self, deprecated_spec, deprecator_spec=None): base_dir = ( self.path_for_spec(deprecator_spec) if deprecator_spec - else os.readlink(deprecated_spec.prefix) + else readlink(deprecated_spec.prefix) ) yaml_path = os.path.join( diff --git a/lib/spack/spack/environment/__init__.py b/lib/spack/spack/environment/__init__.py index e6521aed871bdf..fb083594e00fb5 100644 --- a/lib/spack/spack/environment/__init__.py +++ b/lib/spack/spack/environment/__init__.py @@ -34,6 +34,9 @@ * ``spec``: a string representation of the abstract spec that was concretized 4. ``concrete_specs``: a dictionary containing the specs in the environment. + 5. ``include_concrete`` (dictionary): an optional dictionary that includes the roots + and concrete specs from the included environments, keyed by the path to that + environment Compatibility ------------- @@ -50,26 +53,37 @@ - ``v2`` - ``v3`` - ``v4`` + - ``v5`` * - ``v0.12:0.14`` - ✅ - - - + - * - ``v0.15:0.16`` - ✅ - ✅ - - + - * - ``v0.17`` - ✅ - ✅ - ✅ - + - * - ``v0.18:`` - ✅ - ✅ - ✅ - ✅ + - + * - ``v0.22:`` + - ✅ + - ✅ + - ✅ + - ✅ + - ✅ Version 1 --------- @@ -334,6 +348,118 @@ } } } + + +Version 5 +--------- + +Version 5 doesn't change the top-level lockfile format, but an optional dictionary is +added. The dictionary has the ``root`` and ``concrete_specs`` of the included +environments, which are keyed by the path to that environment. Since this is optional +if the environment does not have any included environments ``include_concrete`` will +not be a part of the lockfile. + +.. code-block:: json + + { + "_meta": { + "file-type": "spack-lockfile", + "lockfile-version": 5, + "specfile-version": 3 + }, + "roots": [ + { + "hash": "", + "spec": "" + }, + { + "hash": "", + "spec": "" + } + ], + "concrete_specs": { + "": { + "... ...": { }, + "dependencies": [ + { + "name": "depname_1", + "hash": "", + "type": ["build", "link"] + }, + { + "name": "depname_2", + "hash": "", + "type": ["build", "link"] + } + ], + "hash": "", + }, + "": { + "... ...": { }, + "dependencies": [ + { + "name": "depname_3", + "hash": "", + "type": ["build", "link"] + }, + { + "name": "depname_4", + "hash": "", + "type": ["build", "link"] + } + ], + "hash": "" + } + } + "include_concrete": { + "": { + "roots": [ + { + "hash": "", + "spec": "" + }, + { + "hash": "", + "spec": "" + } + ], + "concrete_specs": { + "": { + "... ...": { }, + "dependencies": [ + { + "name": "depname_1", + "hash": "", + "type": ["build", "link"] + }, + { + "name": "depname_2", + "hash": "", + "type": ["build", "link"] + } + ], + "hash": "", + }, + "": { + "... ...": { }, + "dependencies": [ + { + "name": "depname_3", + "hash": "", + "type": ["build", "link"] + }, + { + "name": "depname_4", + "hash": "", + "type": ["build", "link"] + } + ], + "hash": "" + } + } + } + } + } """ from .environment import ( diff --git a/lib/spack/spack/environment/environment.py b/lib/spack/spack/environment/environment.py index ed59b5cdf1340c..65a08ff7fa456e 100644 --- a/lib/spack/spack/environment/environment.py +++ b/lib/spack/spack/environment/environment.py @@ -5,7 +5,7 @@ import collections import collections.abc import contextlib -import copy +import errno import os import pathlib import re @@ -16,20 +16,23 @@ import urllib.parse import urllib.request import warnings -from typing import Dict, Iterable, List, Optional, Set, Tuple, Union +from typing import Any, Dict, Iterable, List, Optional, Set, Tuple, Union import llnl.util.filesystem as fs import llnl.util.tty as tty import llnl.util.tty.color as clr from llnl.util.link_tree import ConflictingSpecsError -from llnl.util.symlink import symlink +from llnl.util.symlink import readlink, symlink +import spack.caches +import spack.cmd import spack.compilers import spack.concretize import spack.config import spack.deptypes as dt import spack.error import spack.fetch_strategy +import spack.filesystem_view as fsv import spack.hash_types as ht import spack.hooks import spack.main @@ -52,7 +55,6 @@ import spack.util.url import spack.version from spack import traverse -from spack.filesystem_view import SimpleFilesystemView, inverse_view_func_parser, view_func_parser from spack.installer import PackageInstaller from spack.schema.env import TOP_LEVEL_KEY from spack.spec import Spec @@ -106,17 +108,16 @@ def environment_name(path: Union[str, pathlib.Path]) -> str: return path_str -def check_disallowed_env_config_mods(scopes): +def ensure_no_disallowed_env_config_mods(scopes: List[spack.config.ConfigScope]) -> None: for scope in scopes: - with spack.config.use_configuration(scope): - if spack.config.get("config:environments_root"): - raise SpackEnvironmentError( - "Spack environments are prohibited from modifying 'config:environments_root' " - "because it can make the definition of the environment ill-posed. Please " - "remove from your environment and place it in a permanent scope such as " - "defaults, system, site, etc." - ) - return scopes + config = scope.get_section("config") + if config and "environments_root" in config["config"]: + raise SpackEnvironmentError( + "Spack environments are prohibited from modifying 'config:environments_root' " + "because it can make the definition of the environment ill-posed. Please " + "remove from your environment and place it in a permanent scope such as " + "defaults, system, site, etc." + ) def default_manifest_yaml(): @@ -160,6 +161,8 @@ def default_manifest_yaml(): default_view_name = "default" # Default behavior to link all packages into views (vs. only root packages) default_view_link = "all" +# The name for any included concrete specs +included_concrete_name = "include_concrete" def installed_specs(): @@ -266,9 +269,7 @@ def root(name): def exists(name): """Whether an environment with this name exists or not.""" - if not valid_env_name(name): - return False - return os.path.isdir(root(name)) + return valid_env_name(name) and os.path.isdir(_root(name)) def active(name): @@ -294,6 +295,7 @@ def create( init_file: Optional[Union[str, pathlib.Path]] = None, with_view: Optional[Union[str, pathlib.Path, bool]] = None, keep_relative: bool = False, + include_concrete: Optional[List[str]] = None, ) -> "Environment": """Create a managed environment in Spack and returns it. @@ -310,10 +312,15 @@ def create( string, it specifies the path to the view keep_relative: if True, develop paths are copied verbatim into the new environment file, otherwise they are made absolute + include_concrete: list of concrete environment names/paths to be included """ environment_dir = environment_dir_from_name(name, exists_ok=False) return create_in_dir( - environment_dir, init_file=init_file, with_view=with_view, keep_relative=keep_relative + environment_dir, + init_file=init_file, + with_view=with_view, + keep_relative=keep_relative, + include_concrete=include_concrete, ) @@ -322,6 +329,7 @@ def create_in_dir( init_file: Optional[Union[str, pathlib.Path]] = None, with_view: Optional[Union[str, pathlib.Path, bool]] = None, keep_relative: bool = False, + include_concrete: Optional[List[str]] = None, ) -> "Environment": """Create an environment in the directory passed as input and returns it. @@ -335,6 +343,7 @@ def create_in_dir( string, it specifies the path to the view keep_relative: if True, develop paths are copied verbatim into the new environment file, otherwise they are made absolute + include_concrete: concrete environment names/paths to be included """ initialize_environment_dir(root, envfile=init_file) @@ -347,6 +356,12 @@ def create_in_dir( if with_view is not None: manifest.set_default_view(with_view) + if include_concrete is not None: + set_included_envs_to_env_paths(include_concrete) + validate_included_envs_exists(include_concrete) + validate_included_envs_concrete(include_concrete) + manifest.set_include_concrete(include_concrete) + manifest.flush() except (spack.config.ConfigFormatError, SpackEnvironmentConfigError) as e: @@ -420,6 +435,67 @@ def ensure_env_root_path_exists(): fs.mkdirp(env_root_path()) +def set_included_envs_to_env_paths(include_concrete: List[str]) -> None: + """If the included environment(s) is the environment name + it is replaced by the path to the environment + + Args: + include_concrete: list of env name or path to env""" + + for i, env_name in enumerate(include_concrete): + if is_env_dir(env_name): + include_concrete[i] = env_name + elif exists(env_name): + include_concrete[i] = root(env_name) + + +def validate_included_envs_exists(include_concrete: List[str]) -> None: + """Checks that all of the included environments exist + + Args: + include_concrete: list of already existing concrete environments to include + + Raises: + SpackEnvironmentError: if any of the included environments do not exist + """ + + missing_envs = set() + + for i, env_name in enumerate(include_concrete): + if not is_env_dir(env_name): + missing_envs.add(env_name) + + if missing_envs: + msg = "The following environment(s) are missing: {0}".format(", ".join(missing_envs)) + raise SpackEnvironmentError(msg) + + +def validate_included_envs_concrete(include_concrete: List[str]) -> None: + """Checks that all of the included environments are concrete + + Args: + include_concrete: list of already existing concrete environments to include + + Raises: + SpackEnvironmentError: if any of the included environments are not concrete + """ + + non_concrete_envs = set() + + for env_path in include_concrete: + if not os.path.exists(Environment(env_path).lock_path): + non_concrete_envs.add(Environment(env_path).name) + + if non_concrete_envs: + msg = "The following environment(s) are not concrete: {0}\n" "Please run:".format( + ", ".join(non_concrete_envs) + ) + for env in non_concrete_envs: + msg += f"\n\t`spack -e {env} concretize`" + + raise SpackEnvironmentError(msg) + + def all_environment_names(): """List the names of environments that currently exist.""" # just return empty if the env path does not exist. A read-only @@ -452,8 +528,8 @@ def _read_yaml(str_or_file): ) filename = getattr(str_or_file, "name", None) - default_data = spack.config.validate(data, spack.schema.env.schema, filename) - return data, default_data + spack.config.validate(data, spack.schema.env.schema, filename) + return data def _write_yaml(data, str_or_file): @@ -530,7 +606,7 @@ def __init__( self.projections = projections self.select = select self.exclude = exclude - self.link_type = view_func_parser(link_type) + self.link_type = fsv.canonicalize_link_type(link_type) self.link = link def select_fn(self, spec): @@ -564,7 +640,7 @@ def to_dict(self): if self.exclude: ret["exclude"] = self.exclude if self.link_type: - ret["link_type"] = inverse_view_func_parser(self.link_type) + ret["link_type"] = self.link_type if self.link != default_view_link: ret["link"] = self.link return ret @@ -586,7 +662,7 @@ def _current_root(self): if not os.path.islink(self.root): return None - root = os.readlink(self.root) + root = readlink(self.root) if os.path.isabs(root): return root @@ -614,7 +690,7 @@ def get_projection_for_spec(self, spec): to exist on the filesystem.""" return self._view(self.root).get_projection_for_spec(spec) - def view(self, new: Optional[str] = None) -> SimpleFilesystemView: + def view(self, new: Optional[str] = None) -> fsv.SimpleFilesystemView: """ Returns a view object for the *underlying* view directory. This means that the self.root symlink is followed, and that the view has to exist on the filesystem @@ -634,14 +710,14 @@ def view(self, new: Optional[str] = None) -> SimpleFilesystemView: ) return self._view(path) - def _view(self, root: str) -> SimpleFilesystemView: + def _view(self, root: str) -> fsv.SimpleFilesystemView: """Returns a view object for a given root dir.""" - return SimpleFilesystemView( + return fsv.SimpleFilesystemView( root, spack.store.STORE.layout, ignore_conflicts=True, projections=self.projections, - link=self.link_type, + link_type=self.link_type, ) def __contains__(self, spec): @@ -713,6 +789,23 @@ def regenerate(self, concrete_roots: List[Spec]) -> None: root_dirname = os.path.dirname(self.root) tmp_symlink_name = os.path.join(root_dirname, "._view_link") + # Remove self.root if is it an empty dir, since we need a symlink there. Note that rmdir + # fails if self.root is a symlink. + try: + os.rmdir(self.root) + except (FileNotFoundError, NotADirectoryError): + pass + except OSError as e: + if e.errno == errno.ENOTEMPTY: + msg = "it is a non-empty directory" + elif e.errno == errno.EACCES: + msg = "of insufficient permissions" + else: + raise + raise SpackEnvironmentViewError( + f"The environment view in {self.root} cannot not be created because {msg}." + ) from e + # Create a new view try: fs.mkdirp(new_root) @@ -822,6 +915,18 @@ def __init__(self, manifest_dir: Union[str, pathlib.Path]) -> None: self.specs_by_hash: Dict[str, Spec] = {} #: Repository for this environment (memoized) self._repo = None + + #: Environment paths for concrete (lockfile) included environments + self.included_concrete_envs: List[str] = [] + #: First-level included concretized spec data from/to the lockfile. + self.included_concrete_spec_data: Dict[str, Dict[str, List[str]]] = {} + #: User specs from included environments from the last concretization + self.included_concretized_user_specs: Dict[str, List[Spec]] = {} + #: Roots from included environments with the last concretization, in order + self.included_concretized_order: Dict[str, List[str]] = {} + #: Concretized specs by hash from the included environments + self.included_specs_by_hash: Dict[str, Dict[str, Spec]] = {} + #: Previously active environment self._previous_active = None self._dev_specs = None @@ -832,7 +937,7 @@ def __init__(self, manifest_dir: Union[str, pathlib.Path]) -> None: def _load_manifest_file(self): """Instantiate and load the manifest file contents into memory.""" with lk.ReadTransaction(self.txlock): - self.manifest = EnvironmentManifestFile(self.path) + self.manifest = EnvironmentManifestFile(self.path, self.name) with self.manifest.use_config(): self._read() @@ -859,7 +964,7 @@ def _read(self): if os.path.exists(self.lock_path): with open(self.lock_path) as f: - read_lock_version = self._read_lockfile(f) + read_lock_version = self._read_lockfile(f)["_meta"]["lockfile-version"] if read_lock_version == 1: tty.debug(f"Storing backup of {self.lock_path} at {self._lock_backup_v1_path}") @@ -869,18 +974,25 @@ def write_transaction(self): """Get a write lock context manager for use in a `with` block.""" return lk.WriteTransaction(self.txlock, acquire=self._re_read) - def _process_definition(self, item): + def _process_definition(self, entry): """Process a single spec definition item.""" - entry = copy.deepcopy(item) - when = _eval_conditional(entry.pop("when", "True")) - assert len(entry) == 1 + when_string = entry.get("when") + if when_string is not None: + when = _eval_conditional(when_string) + assert len([x for x in entry if x != "when"]) == 1 + else: + when = True + assert len(entry) == 1 + if when: - name, spec_list = next(iter(entry.items())) - user_specs = SpecList(name, spec_list, self.spec_lists.copy()) - if name in self.spec_lists: - self.spec_lists[name].extend(user_specs) - else: - self.spec_lists[name] = user_specs + for name, spec_list in entry.items(): + if name == "when": + continue + user_specs = SpecList(name, spec_list, self.spec_lists.copy()) + if name in self.spec_lists: + self.spec_lists[name].extend(user_specs) + else: + self.spec_lists[name] = user_specs def _process_view(self, env_view: Optional[Union[bool, str, Dict]]): """Process view option(s), which can be boolean, string, or None. @@ -927,6 +1039,20 @@ def add_view(name, values): if self.views == dict(): self.views[default_view_name] = ViewDescriptor(self.path, self.view_path_default) + def _process_concrete_includes(self): + """Extract and load into memory included concrete spec data.""" + self.included_concrete_envs = self.manifest[TOP_LEVEL_KEY].get(included_concrete_name, []) + + if self.included_concrete_envs: + if os.path.exists(self.lock_path): + with open(self.lock_path) as f: + data = self._read_lockfile(f) + + if included_concrete_name in data: + self.included_concrete_spec_data = data[included_concrete_name] + else: + self.include_concrete_envs() + def _construct_state_from_manifest(self): """Set up user specs and views from the manifest file.""" self.spec_lists = collections.OrderedDict() @@ -943,6 +1069,31 @@ def _construct_state_from_manifest(self): self.spec_lists[user_speclist_name] = user_specs self._process_view(spack.config.get("view", True)) + self._process_concrete_includes() + + def all_concretized_user_specs(self) -> List[Spec]: + """Returns all of the concretized user specs of the environment and + its included environment(s).""" + concretized_user_specs = self.concretized_user_specs[:] + for included_specs in self.included_concretized_user_specs.values(): + for included in included_specs: + # Don't duplicate included spec(s) + if included not in concretized_user_specs: + concretized_user_specs.append(included) + + return concretized_user_specs + + def all_concretized_orders(self) -> List[str]: + """Returns all of the concretized order of the environment and + its included environment(s).""" + concretized_order = self.concretized_order[:] + for included_concretized_order in self.included_concretized_order.values(): + for included in included_concretized_order: + # Don't duplicate included spec(s) + if included not in concretized_order: + concretized_order.append(included) + + return concretized_order @property def user_specs(self): @@ -967,6 +1118,26 @@ def _read_dev_specs(self): dev_specs[name] = local_entry return dev_specs + @property + def included_user_specs(self) -> SpecList: + """Included concrete user (or root) specs from last concretization.""" + spec_list = SpecList() + + if not self.included_concrete_envs: + return spec_list + + def add_root_specs(included_concrete_specs): + # add specs from the include *and* any nested includes it may have + for env, info in included_concrete_specs.items(): + for root_list in info["roots"]: + spec_list.add(root_list["spec"]) + + if "include_concrete" in info: + add_root_specs(info["include_concrete"]) + + add_root_specs(self.included_concrete_spec_data) + return spec_list + def clear(self, re_read=False): """Clear the contents of the environment @@ -978,9 +1149,15 @@ def clear(self, re_read=False): self.spec_lists[user_speclist_name] = SpecList() self._dev_specs = {} - self.concretized_user_specs = [] # user specs from last concretize self.concretized_order = [] # roots of last concretize, in order + self.concretized_user_specs = [] # user specs from last concretize self.specs_by_hash = {} # concretized specs by hash + + self.included_concrete_spec_data = {} # concretized specs from lockfile of included envs + self.included_concretized_order = {} # root specs of the included envs, keyed by env path + self.included_concretized_user_specs = {} # user specs from last concretize's included env + self.included_specs_by_hash = {} # concretized specs by hash from the included envs + self.invalidate_repository_cache() self._previous_active = None # previously active environment if not re_read: @@ -1034,6 +1211,55 @@ def scope_name(self): """Name of the config scope of this environment's manifest file.""" return self.manifest.scope_name + def include_concrete_envs(self): + """Copy and save the included envs' specs internally""" + + lockfile_meta = None + root_hash_seen = set() + concrete_hash_seen = set() + self.included_concrete_spec_data = {} + + for env_path in self.included_concrete_envs: + # Check that environment exists + if not is_env_dir(env_path): + raise SpackEnvironmentError(f"Unable to find env at {env_path}") + + env = Environment(env_path) + + with open(env.lock_path) as f: + lockfile_as_dict = env._read_lockfile(f) + + # Lockfile_meta must match each env and use at least format version 5 + if lockfile_meta is None: + lockfile_meta = lockfile_as_dict["_meta"] + elif lockfile_meta != lockfile_as_dict["_meta"]: + raise SpackEnvironmentError("All lockfile _meta values must match") + elif lockfile_meta["lockfile-version"] < 5: + raise SpackEnvironmentError("The lockfile format must be at version 5 or higher") + + # Copy unique root specs from env + self.included_concrete_spec_data[env_path] = {"roots": []} + for root_dict in lockfile_as_dict["roots"]: + if root_dict["hash"] not in root_hash_seen: + self.included_concrete_spec_data[env_path]["roots"].append(root_dict) + root_hash_seen.add(root_dict["hash"]) + + # Copy unique concrete specs from env + for concrete_spec in lockfile_as_dict["concrete_specs"]: + if concrete_spec not in concrete_hash_seen: + self.included_concrete_spec_data[env_path].update( + {"concrete_specs": lockfile_as_dict["concrete_specs"]} + ) + concrete_hash_seen.add(concrete_spec) + + if "include_concrete" in lockfile_as_dict.keys(): + self.included_concrete_spec_data[env_path]["include_concrete"] = lockfile_as_dict[ + "include_concrete" + ] + + self._read_lockfile_dict(self._to_lockfile_dict()) + self.write() + def destroy(self): """Remove this environment from Spack entirely.""" shutil.rmtree(self.path) @@ -1233,6 +1459,10 @@ def concretize(self, force=False, tests=False): for spec in set(self.concretized_user_specs) - set(self.user_specs): self.deconcretize(spec, concrete=False) + # If a combined env, check updated spec is in the linked envs + if self.included_concrete_envs: + self.include_concrete_envs() + # Pick the right concretization strategy if self.unify == "when_possible": return self._concretize_together_where_possible(tests=tests) @@ -1416,7 +1646,7 @@ def _concretize_separately(self, tests=False): # Ensure we don't try to bootstrap clingo in parallel if spack.config.get("config:concretizer", "clingo") == "clingo": with spack.bootstrap.ensure_bootstrap_configuration(): - spack.bootstrap.ensure_core_dependencies() + spack.bootstrap.ensure_clingo_importable_or_raise() # Ensure all the indexes have been built or updated, since # otherwise the processes in the pool may timeout on waiting @@ -1427,7 +1657,7 @@ def _concretize_separately(self, tests=False): # Ensure we have compilers in compilers.yaml to avoid that # processes try to write the config file in parallel - _ = spack.compilers.get_compiler_config(init_config=True) + _ = spack.compilers.get_compiler_config(spack.config.CONFIG, init_config=True) # Early return if there is nothing to do if len(args) == 0: @@ -1705,8 +1935,14 @@ def _partition_roots_by_install_status(self): of per spec.""" installed, uninstalled = [], [] with spack.store.STORE.db.read_transaction(): - for concretized_hash in self.concretized_order: - spec = self.specs_by_hash[concretized_hash] + for concretized_hash in self.all_concretized_orders(): + if concretized_hash in self.specs_by_hash: + spec = self.specs_by_hash[concretized_hash] + else: + for env_path in self.included_specs_by_hash.keys(): + if concretized_hash in self.included_specs_by_hash[env_path]: + spec = self.included_specs_by_hash[env_path][concretized_hash] + break if not spec.installed or ( spec.satisfies("dev_path=*") or spec.satisfies("^dev_path=*") ): @@ -1736,13 +1972,19 @@ def install_specs(self, specs: Optional[List[Spec]] = None, **install_args): specs = specs if specs is not None else roots # Extend the set of specs to overwrite with modified dev specs and their parents - install_args["overwrite"] = ( - install_args.get("overwrite", []) + self._dev_specs_that_need_overwrite() + overwrite: Set[str] = set() + overwrite.update(install_args.get("overwrite", []), self._dev_specs_that_need_overwrite()) + install_args["overwrite"] = overwrite + + explicit: Set[str] = set() + explicit.update( + install_args.get("explicit", []), + (s.dag_hash() for s in specs), + (s.dag_hash() for s in roots), ) + install_args["explicit"] = explicit - installs = [(spec.package, {**install_args, "explicit": spec in roots}) for spec in specs] - - PackageInstaller(installs).install() + PackageInstaller([spec.package for spec in specs], install_args).install() def all_specs_generator(self) -> Iterable[Spec]: """Returns a generator for all concrete specs""" @@ -1786,8 +2028,14 @@ def added_specs(self): def concretized_specs(self): """Tuples of (user spec, concrete spec) for all concrete specs.""" - for s, h in zip(self.concretized_user_specs, self.concretized_order): - yield (s, self.specs_by_hash[h]) + for s, h in zip(self.all_concretized_user_specs(), self.all_concretized_orders()): + if h in self.specs_by_hash: + yield (s, self.specs_by_hash[h]) + else: + for env_path in self.included_specs_by_hash.keys(): + if h in self.included_specs_by_hash[env_path]: + yield (s, self.included_specs_by_hash[env_path][h]) + break def concrete_roots(self): """Same as concretized_specs, except it returns the list of concrete @@ -1916,8 +2164,7 @@ def _get_environment_specs(self, recurse_dependencies=True): If these specs appear under different user_specs, only one copy is added to the list returned. """ - specs = [self.specs_by_hash[h] for h in self.concretized_order] - + specs = [self.specs_by_hash[h] for h in self.all_concretized_orders()] if recurse_dependencies: specs.extend( traverse.traverse_nodes( @@ -1962,31 +2209,76 @@ def _to_lockfile_dict(self): "concrete_specs": concrete_specs, } + if self.included_concrete_envs: + data[included_concrete_name] = self.included_concrete_spec_data + return data def _read_lockfile(self, file_or_json): """Read a lockfile from a file or from a raw string.""" lockfile_dict = sjson.load(file_or_json) self._read_lockfile_dict(lockfile_dict) - return lockfile_dict["_meta"]["lockfile-version"] + return lockfile_dict + + def set_included_concretized_user_specs( + self, + env_name: str, + env_info: Dict[str, Dict[str, Any]], + included_json_specs_by_hash: Dict[str, Dict[str, Any]], + ) -> Dict[str, Dict[str, Any]]: + """Sets all of the concretized user specs from included environments + to include those from nested included environments. + + Args: + env_name: the name (technically the path) of the included environment + env_info: included concrete environment data + included_json_specs_by_hash: concrete spec data keyed by hash + + Returns: updated specs_by_hash + """ + self.included_concretized_order[env_name] = [] + self.included_concretized_user_specs[env_name] = [] + + def add_specs(name, info, specs_by_hash): + # Add specs from the environment as well as any of its nested + # environments. + for root_info in info["roots"]: + self.included_concretized_order[name].append(root_info["hash"]) + self.included_concretized_user_specs[name].append(Spec(root_info["spec"])) + if "concrete_specs" in info: + specs_by_hash.update(info["concrete_specs"]) + + if included_concrete_name in info: + for included_name, included_info in info[included_concrete_name].items(): + if included_name not in self.included_concretized_order: + self.included_concretized_order[included_name] = [] + self.included_concretized_user_specs[included_name] = [] + add_specs(included_name, included_info, specs_by_hash) + + add_specs(env_name, env_info, included_json_specs_by_hash) + return included_json_specs_by_hash def _read_lockfile_dict(self, d): """Read a lockfile dictionary into this environment.""" self.specs_by_hash = {} + self.included_specs_by_hash = {} + self.included_concretized_user_specs = {} + self.included_concretized_order = {} roots = d["roots"] self.concretized_user_specs = [Spec(r["spec"]) for r in roots] self.concretized_order = [r["hash"] for r in roots] json_specs_by_hash = d["concrete_specs"] + included_json_specs_by_hash = {} - # Track specs by their lockfile key. Currently spack uses the finest - # grained hash as the lockfile key, while older formats used the build - # hash or a previous incarnation of the DAG hash (one that did not - # include build deps or package hash). - specs_by_hash = {} + if included_concrete_name in d: + for env_name, env_info in d[included_concrete_name].items(): + included_json_specs_by_hash.update( + self.set_included_concretized_user_specs( + env_name, env_info, included_json_specs_by_hash + ) + ) - # Track specs by their DAG hash, allows handling DAG hash collisions - first_seen = {} current_lockfile_format = d["_meta"]["lockfile-version"] try: reader = READER_CLS[current_lockfile_format] @@ -1999,6 +2291,39 @@ def _read_lockfile_dict(self, d): msg += " You need to use a newer Spack version." raise SpackEnvironmentError(msg) + first_seen, self.concretized_order = self.filter_specs( + reader, json_specs_by_hash, self.concretized_order + ) + + for spec_dag_hash in self.concretized_order: + self.specs_by_hash[spec_dag_hash] = first_seen[spec_dag_hash] + + if any(self.included_concretized_order.values()): + first_seen = {} + + for env_name, concretized_order in self.included_concretized_order.items(): + filtered_spec, self.included_concretized_order[env_name] = self.filter_specs( + reader, included_json_specs_by_hash, concretized_order + ) + first_seen.update(filtered_spec) + + for env_path, spec_hashes in self.included_concretized_order.items(): + self.included_specs_by_hash[env_path] = {} + for spec_dag_hash in spec_hashes: + self.included_specs_by_hash[env_path].update( + {spec_dag_hash: first_seen[spec_dag_hash]} + ) + + def filter_specs(self, reader, json_specs_by_hash, order_concretized): + # Track specs by their lockfile key. Currently spack uses the finest + # grained hash as the lockfile key, while older formats used the build + # hash or a previous incarnation of the DAG hash (one that did not + # include build deps or package hash). + specs_by_hash = {} + + # Track specs by their DAG hash, allows handling DAG hash collisions + first_seen = {} + # First pass: Put each spec in the map ignoring dependencies for lockfile_key, node_dict in json_specs_by_hash.items(): spec = reader.from_node_dict(node_dict) @@ -2021,7 +2346,8 @@ def _read_lockfile_dict(self, d): # keep. This is only required as long as we support older lockfile # formats where the mapping from DAG hash to lockfile key is possibly # one-to-many. - for lockfile_key in self.concretized_order: + + for lockfile_key in order_concretized: for s in specs_by_hash[lockfile_key].traverse(): if s.dag_hash() not in first_seen: first_seen[s.dag_hash()] = s @@ -2029,12 +2355,10 @@ def _read_lockfile_dict(self, d): # Now make sure concretized_order and our internal specs dict # contains the keys used by modern spack (i.e. the dag_hash # that includes build deps and package hash). - self.concretized_order = [ - specs_by_hash[h_key].dag_hash() for h_key in self.concretized_order - ] - for spec_dag_hash in self.concretized_order: - self.specs_by_hash[spec_dag_hash] = first_seen[spec_dag_hash] + order_concretized = [specs_by_hash[h_key].dag_hash() for h_key in order_concretized] + + return first_seen, order_concretized def write(self, regenerate: bool = True) -> None: """Writes an in-memory environment to its location on disk. @@ -2047,7 +2371,7 @@ def write(self, regenerate: bool = True) -> None: regenerate: regenerate views and run post-write hooks as well as writing if True. """ self.manifest_uptodate_or_warn() - if self.specs_by_hash: + if self.specs_by_hash or self.included_concrete_envs: self.ensure_env_directory_exists(dot_env=True) self.update_environment_repository() self.manifest.flush() @@ -2173,27 +2497,21 @@ def _equiv_dict(first, second): return same_values and same_keys_with_same_overrides -def display_specs(concretized_specs): - """Displays the list of specs returned by `Environment.concretize()`. +def display_specs(specs): + """Displays a list of specs traversed breadth-first, covering nodes, with install status. Args: - concretized_specs (list): list of specs returned by - `Environment.concretize()` + specs (list): list of specs """ - - def _tree_to_display(spec): - return spec.tree( - recurse_dependencies=True, - format=spack.spec.DISPLAY_FORMAT, - status_fn=spack.spec.Spec.install_status, - hashlen=7, - hashes=True, - ) - - for user_spec, concrete_spec in concretized_specs: - tty.msg("Concretized {0}".format(user_spec)) - sys.stdout.write(_tree_to_display(concrete_spec)) - print("") + tree_string = spack.spec.tree( + specs, + format=spack.spec.DISPLAY_FORMAT, + hashes=True, + hashlen=7, + status_fn=spack.spec.Spec.install_status, + key=traverse.by_dag_hash, + ) + print(tree_string) def _concretize_from_constraints(spec_constraints, tests=False): @@ -2247,7 +2565,7 @@ def _concretize_task(packed_arguments) -> Tuple[int, Spec, float]: def make_repo_path(root): """Make a RepoPath from the repo subdirectories in an environment.""" - path = spack.repo.RepoPath() + path = spack.repo.RepoPath(cache=spack.caches.MISC_CACHE) if os.path.isdir(root): for repo_root in os.listdir(root): @@ -2256,7 +2574,7 @@ def make_repo_path(root): if not os.path.isdir(repo_root): continue - repo = spack.repo.Repo(repo_root) + repo = spack.repo.from_path(repo_root) path.put_last(repo) return path @@ -2457,23 +2775,24 @@ def from_lockfile(manifest_dir: Union[pathlib.Path, str]) -> "EnvironmentManifes manifest.flush() return manifest - def __init__(self, manifest_dir: Union[pathlib.Path, str]) -> None: + def __init__(self, manifest_dir: Union[pathlib.Path, str], name: Optional[str] = None) -> None: self.manifest_dir = pathlib.Path(manifest_dir) + self.name = name or str(manifest_dir) self.manifest_file = self.manifest_dir / manifest_name - self.scope_name = f"env:{environment_name(self.manifest_dir)}" + self.scope_name = f"env:{self.name}" self.config_stage_dir = os.path.join(env_subdir_path(manifest_dir), "config") + #: Configuration scopes associated with this environment. Note that these are not + #: invalidated by a re-read of the manifest file. + self._config_scopes: Optional[List[spack.config.ConfigScope]] = None + if not self.manifest_file.exists(): msg = f"cannot find '{manifest_name}' in {self.manifest_dir}" raise SpackEnvironmentError(msg) with self.manifest_file.open() as f: - raw, with_defaults_added = _read_yaml(f) + self.yaml_content = _read_yaml(f) - #: Pristine YAML content, without defaults being added - self.pristine_yaml_content = raw - #: YAML content with defaults added by Spack, if they're missing - self.yaml_content = with_defaults_added self.changed = False def _all_matches(self, user_spec: str) -> List[str]: @@ -2487,7 +2806,7 @@ def _all_matches(self, user_spec: str) -> List[str]: ValueError: if no equivalent match is found """ result = [] - for yaml_spec_str in self.pristine_configuration["specs"]: + for yaml_spec_str in self.configuration["specs"]: if Spec(yaml_spec_str) == Spec(user_spec): result.append(yaml_spec_str) @@ -2502,7 +2821,6 @@ def add_user_spec(self, user_spec: str) -> None: Args: user_spec: user spec to be appended """ - self.pristine_configuration.setdefault("specs", []).append(user_spec) self.configuration.setdefault("specs", []).append(user_spec) self.changed = True @@ -2517,7 +2835,6 @@ def remove_user_spec(self, user_spec: str) -> None: """ try: for key in self._all_matches(user_spec): - self.pristine_configuration["specs"].remove(key) self.configuration["specs"].remove(key) except ValueError as e: msg = f"cannot remove {user_spec} from {self}, no such spec exists" @@ -2535,13 +2852,25 @@ def override_user_spec(self, user_spec: str, idx: int) -> None: SpackEnvironmentError: when the user spec cannot be overridden """ try: - self.pristine_configuration["specs"][idx] = user_spec self.configuration["specs"][idx] = user_spec except ValueError as e: msg = f"cannot override {user_spec} from {self}" raise SpackEnvironmentError(msg) from e self.changed = True + def set_include_concrete(self, include_concrete: List[str]) -> None: + """Sets the included concrete environments in the manifest to the value(s) passed as input. + + Args: + include_concrete: list of already existing concrete environments to include + """ + self.configuration[included_concrete_name] = [] + + for env_path in include_concrete: + self.configuration[included_concrete_name].append(env_path) + + self.changed = True + def add_definition(self, user_spec: str, list_name: str) -> None: """Appends a user spec to the first active definition matching the name passed as argument. @@ -2552,14 +2881,13 @@ def add_definition(self, user_spec: str, list_name: str) -> None: Raises: SpackEnvironmentError: is no valid definition exists already """ - defs = self.pristine_configuration.get("definitions", []) + defs = self.configuration.get("definitions", []) msg = f"cannot add {user_spec} to the '{list_name}' definition, no valid list exists" for idx, item in self._iterate_on_definitions(defs, list_name=list_name, err_msg=msg): item[list_name].append(user_spec) break - self.configuration["definitions"][idx][list_name].append(user_spec) self.changed = True def remove_definition(self, user_spec: str, list_name: str) -> None: @@ -2573,7 +2901,7 @@ def remove_definition(self, user_spec: str, list_name: str) -> None: SpackEnvironmentError: if the user spec cannot be removed from the list, or the list does not exist """ - defs = self.pristine_configuration.get("definitions", []) + defs = self.configuration.get("definitions", []) msg = ( f"cannot remove {user_spec} from the '{list_name}' definition, " f"no valid list exists" @@ -2586,7 +2914,6 @@ def remove_definition(self, user_spec: str, list_name: str) -> None: except ValueError: pass - self.configuration["definitions"][idx][list_name].remove(user_spec) self.changed = True def override_definition(self, user_spec: str, *, override: str, list_name: str) -> None: @@ -2601,7 +2928,7 @@ def override_definition(self, user_spec: str, *, override: str, list_name: str) Raises: SpackEnvironmentError: if the user spec cannot be overridden """ - defs = self.pristine_configuration.get("definitions", []) + defs = self.configuration.get("definitions", []) msg = f"cannot override {user_spec} with {override} in the '{list_name}' definition" for idx, item in self._iterate_on_definitions(defs, list_name=list_name, err_msg=msg): @@ -2612,7 +2939,6 @@ def override_definition(self, user_spec: str, *, override: str, list_name: str) except ValueError: pass - self.configuration["definitions"][idx][list_name][sub_index] = override self.changed = True def _iterate_on_definitions(self, definitions, *, list_name, err_msg): @@ -2644,7 +2970,6 @@ def set_default_view(self, view: Union[bool, str, pathlib.Path, Dict[str, str]]) True the default view is used for the environment, if False there's no view. """ if isinstance(view, dict): - self.pristine_configuration["view"][default_view_name].update(view) self.configuration["view"][default_view_name].update(view) self.changed = True return @@ -2652,15 +2977,13 @@ def set_default_view(self, view: Union[bool, str, pathlib.Path, Dict[str, str]]) if not isinstance(view, bool): view = str(view) - self.pristine_configuration["view"] = view self.configuration["view"] = view self.changed = True def remove_default_view(self) -> None: """Removes the default view from the manifest file""" - view_data = self.pristine_configuration.get("view") + view_data = self.configuration.get("view") if isinstance(view_data, collections.abc.Mapping): - self.pristine_configuration["view"].pop(default_view_name) self.configuration["view"].pop(default_view_name) self.changed = True return @@ -2673,17 +2996,12 @@ def flush(self) -> None: return with fs.write_tmp_and_move(os.path.realpath(self.manifest_file)) as f: - _write_yaml(self.pristine_yaml_content, f) + _write_yaml(self.yaml_content, f) self.changed = False - @property - def pristine_configuration(self): - """Return the dictionaries in the pristine YAML, without the top level attribute""" - return self.pristine_yaml_content[TOP_LEVEL_KEY] - @property def configuration(self): - """Return the dictionaries in the YAML, without the top level attribute""" + """Return the dictionaries in the pristine YAML, without the top level attribute""" return self.yaml_content[TOP_LEVEL_KEY] def __len__(self): @@ -2715,64 +3033,65 @@ def included_config_scopes(self) -> List[spack.config.ConfigScope]: SpackEnvironmentError: if the manifest includes a remote file but no configuration stage directory has been identified """ - scopes = [] + scopes: List[spack.config.ConfigScope] = [] # load config scopes added via 'include:', in reverse so that # highest-precedence scopes are last. includes = self[TOP_LEVEL_KEY].get("include", []) - env_name = environment_name(self.manifest_dir) missing = [] for i, config_path in enumerate(reversed(includes)): # allow paths to contain spack config/environment variables, etc. config_path = substitute_path_variables(config_path) - include_url = urllib.parse.urlparse(config_path) - # Transform file:// URLs to direct includes. - if include_url.scheme == "file": - config_path = urllib.request.url2pathname(include_url.path) - - # Any other URL should be fetched. - elif include_url.scheme in ("http", "https", "ftp"): - # Stage any remote configuration file(s) - staged_configs = ( - os.listdir(self.config_stage_dir) - if os.path.exists(self.config_stage_dir) - else [] - ) - remote_path = urllib.request.url2pathname(include_url.path) - basename = os.path.basename(remote_path) - if basename in staged_configs: - # Do NOT re-stage configuration files over existing - # ones with the same name since there is a risk of - # losing changes (e.g., from 'spack config update'). - tty.warn( - "Will not re-stage configuration from {0} to avoid " - "losing changes to the already staged file of the " - "same name.".format(remote_path) - ) - - # Recognize the configuration stage directory - # is flattened to ensure a single copy of each - # configuration file. - config_path = self.config_stage_dir - if basename.endswith(".yaml"): - config_path = os.path.join(config_path, basename) - else: - staged_path = spack.config.fetch_remote_configs( - config_path, str(self.config_stage_dir), skip_existing=True + # If scheme is not valid, config_path is not a url + # of a type Spack is generally aware + if spack.util.url.validate_scheme(include_url.scheme): + # Transform file:// URLs to direct includes. + if include_url.scheme == "file": + config_path = urllib.request.url2pathname(include_url.path) + + # Any other URL should be fetched. + elif include_url.scheme in ("http", "https", "ftp"): + # Stage any remote configuration file(s) + staged_configs = ( + os.listdir(self.config_stage_dir) + if os.path.exists(self.config_stage_dir) + else [] ) - if not staged_path: - raise SpackEnvironmentError( - "Unable to fetch remote configuration {0}".format(config_path) + remote_path = urllib.request.url2pathname(include_url.path) + basename = os.path.basename(remote_path) + if basename in staged_configs: + # Do NOT re-stage configuration files over existing + # ones with the same name since there is a risk of + # losing changes (e.g., from 'spack config update'). + tty.warn( + "Will not re-stage configuration from {0} to avoid " + "losing changes to the already staged file of the " + "same name.".format(remote_path) ) - config_path = staged_path - elif include_url.scheme: - raise ValueError( - f"Unsupported URL scheme ({include_url.scheme}) for " - f"environment include: {config_path}" - ) + # Recognize the configuration stage directory + # is flattened to ensure a single copy of each + # configuration file. + config_path = self.config_stage_dir + if basename.endswith(".yaml"): + config_path = os.path.join(config_path, basename) + else: + staged_path = spack.config.fetch_remote_configs( + config_path, str(self.config_stage_dir), skip_existing=True + ) + if not staged_path: + raise SpackEnvironmentError( + "Unable to fetch remote configuration {0}".format(config_path) + ) + config_path = staged_path + + elif include_url.scheme: + raise ValueError( + f"Unsupported URL scheme ({include_url.scheme}) for " + f"environment include: {config_path}" + ) # treat relative paths as relative to the environment if not os.path.isabs(config_path): @@ -2781,24 +3100,22 @@ def included_config_scopes(self) -> List[spack.config.ConfigScope]: if os.path.isdir(config_path): # directories are treated as regular ConfigScopes - config_name = "env:%s:%s" % (env_name, os.path.basename(config_path)) - tty.debug("Creating ConfigScope {0} for '{1}'".format(config_name, config_path)) - scope = spack.config.ConfigScope(config_name, config_path) + config_name = f"env:{self.name}:{os.path.basename(config_path)}" + tty.debug(f"Creating DirectoryConfigScope {config_name} for '{config_path}'") + scopes.append(spack.config.DirectoryConfigScope(config_name, config_path)) elif os.path.exists(config_path): # files are assumed to be SingleFileScopes - config_name = "env:%s:%s" % (env_name, config_path) - tty.debug( - "Creating SingleFileScope {0} for '{1}'".format(config_name, config_path) - ) - scope = spack.config.SingleFileScope( - config_name, config_path, spack.schema.merged.schema + config_name = f"env:{self.name}:{config_path}" + tty.debug(f"Creating SingleFileScope {config_name} for '{config_path}'") + scopes.append( + spack.config.SingleFileScope( + config_name, config_path, spack.schema.merged.schema + ) ) else: missing.append(config_path) continue - scopes.append(scope) - if missing: msg = "Detected {0} missing include path(s):".format(len(missing)) msg += "\n {0}".format("\n ".join(missing)) @@ -2808,16 +3125,22 @@ def included_config_scopes(self) -> List[spack.config.ConfigScope]: @property def env_config_scopes(self) -> List[spack.config.ConfigScope]: - """A list of all configuration scopes for the environment manifest. - - Returns: All configuration scopes associated with the environment - """ - config_name = self.scope_name - env_scope = spack.config.SingleFileScope( - config_name, str(self.manifest_file), spack.schema.env.schema, [TOP_LEVEL_KEY] - ) - - return check_disallowed_env_config_mods(self.included_config_scopes + [env_scope]) + """A list of all configuration scopes for the environment manifest. On the first call this + instantiates all the scopes, on subsequent calls it returns the cached list.""" + if self._config_scopes is not None: + return self._config_scopes + scopes: List[spack.config.ConfigScope] = [ + *self.included_config_scopes, + spack.config.SingleFileScope( + self.scope_name, + str(self.manifest_file), + spack.schema.env.schema, + yaml_path=[TOP_LEVEL_KEY], + ), + ] + ensure_no_disallowed_env_config_mods(scopes) + self._config_scopes = scopes + return scopes def prepare_config_scope(self) -> None: """Add the manifest's scopes to the global configuration search path.""" diff --git a/lib/spack/spack/filesystem_view.py b/lib/spack/spack/filesystem_view.py index 21d001fc9f7815..0e508a9bd89c46 100644 --- a/lib/spack/spack/filesystem_view.py +++ b/lib/spack/spack/filesystem_view.py @@ -10,8 +10,9 @@ import shutil import stat import sys -from typing import Optional +from typing import Callable, Dict, Optional +from llnl.string import comma_or from llnl.util import tty from llnl.util.filesystem import ( mkdirp, @@ -49,19 +50,20 @@ _projections_path = ".spack/projections.yaml" -def view_symlink(src, dst, **kwargs): - # keyword arguments are irrelevant - # here to fit required call signature +LinkCallbackType = Callable[[str, str, "FilesystemView", Optional["spack.spec.Spec"]], None] + + +def view_symlink(src: str, dst: str, *args, **kwargs) -> None: symlink(src, dst) -def view_hardlink(src, dst, **kwargs): - # keyword arguments are irrelevant - # here to fit required call signature +def view_hardlink(src: str, dst: str, *args, **kwargs) -> None: os.link(src, dst) -def view_copy(src: str, dst: str, view, spec: Optional[spack.spec.Spec] = None): +def view_copy( + src: str, dst: str, view: "FilesystemView", spec: Optional["spack.spec.Spec"] = None +) -> None: """ Copy a file from src to dst. @@ -104,27 +106,40 @@ def view_copy(src: str, dst: str, view, spec: Optional[spack.spec.Spec] = None): tty.debug(f"Can't change the permissions for {dst}") -def view_func_parser(parsed_name): - # What method are we using for this view - if parsed_name in ("hardlink", "hard"): +#: supported string values for `link_type` in an env, mapped to canonical values +_LINK_TYPES = { + "hardlink": "hardlink", + "hard": "hardlink", + "copy": "copy", + "relocate": "copy", + "add": "symlink", + "symlink": "symlink", + "soft": "symlink", +} + +_VALID_LINK_TYPES = sorted(set(_LINK_TYPES.values())) + + +def canonicalize_link_type(link_type: str) -> str: + """Return canonical""" + canonical = _LINK_TYPES.get(link_type) + if not canonical: + raise ValueError( + f"Invalid link type: '{link_type}. Must be one of {comma_or(_VALID_LINK_TYPES)}'" + ) + return canonical + + +def function_for_link_type(link_type: str) -> LinkCallbackType: + link_type = canonicalize_link_type(link_type) + if link_type == "hardlink": return view_hardlink - elif parsed_name in ("copy", "relocate"): - return view_copy - elif parsed_name in ("add", "symlink", "soft"): + elif link_type == "symlink": return view_symlink - else: - raise ValueError(f"invalid link type for view: '{parsed_name}'") - + elif link_type == "copy": + return view_copy -def inverse_view_func_parser(view_type): - # get string based on view type - if view_type is view_hardlink: - link_name = "hardlink" - elif view_type is view_copy: - link_name = "copy" - else: - link_name = "symlink" - return link_name + assert False, "invalid link type" # need mypy Literal values class FilesystemView: @@ -140,7 +155,16 @@ class FilesystemView: directory structure. """ - def __init__(self, root, layout, **kwargs): + def __init__( + self, + root: str, + layout: "spack.directory_layout.DirectoryLayout", + *, + projections: Optional[Dict] = None, + ignore_conflicts: bool = False, + verbose: bool = False, + link_type: str = "symlink", + ): """ Initialize a filesystem view under the given `root` directory with corresponding directory `layout`. @@ -149,15 +173,14 @@ def __init__(self, root, layout, **kwargs): """ self._root = root self.layout = layout + self.projections = {} if projections is None else projections - self.projections = kwargs.get("projections", {}) - - self.ignore_conflicts = kwargs.get("ignore_conflicts", False) - self.verbose = kwargs.get("verbose", False) + self.ignore_conflicts = ignore_conflicts + self.verbose = verbose # Setup link function to include view - link_func = kwargs.get("link", view_symlink) - self.link = ft.partial(link_func, view=self) + self.link_type = link_type + self.link = ft.partial(function_for_link_type(link_type), view=self) def add_specs(self, *specs, **kwargs): """ @@ -255,8 +278,24 @@ class YamlFilesystemView(FilesystemView): Filesystem view to work with a yaml based directory layout. """ - def __init__(self, root, layout, **kwargs): - super().__init__(root, layout, **kwargs) + def __init__( + self, + root: str, + layout: "spack.directory_layout.DirectoryLayout", + *, + projections: Optional[Dict] = None, + ignore_conflicts: bool = False, + verbose: bool = False, + link_type: str = "symlink", + ): + super().__init__( + root, + layout, + projections=projections, + ignore_conflicts=ignore_conflicts, + verbose=verbose, + link_type=link_type, + ) # Super class gets projections from the kwargs # YAML specific to get projections from YAML file @@ -638,9 +677,6 @@ class SimpleFilesystemView(FilesystemView): """A simple and partial implementation of FilesystemView focused on performance and immutable views, where specs cannot be removed after they were added.""" - def __init__(self, root, layout, **kwargs): - super().__init__(root, layout, **kwargs) - def _sanity_check_view_projection(self, specs): """A very common issue is that we end up with two specs of the same package, that project to the same prefix. We want to catch that as early as possible and give a sensible error to @@ -662,9 +698,6 @@ def add_specs(self, *specs: spack.spec.Spec) -> None: return # Drop externals - for s in specs: - if s.external: - tty.warn("Skipping external package: " + s.short_spec) specs = [s for s in specs if not s.external] self._sanity_check_view_projection(specs) diff --git a/lib/spack/spack/hooks/absolutify_elf_sonames.py b/lib/spack/spack/hooks/absolutify_elf_sonames.py index d203c6d1efb926..5f1c4d0eac1e21 100644 --- a/lib/spack/spack/hooks/absolutify_elf_sonames.py +++ b/lib/spack/spack/hooks/absolutify_elf_sonames.py @@ -13,7 +13,6 @@ import spack.config import spack.relocate from spack.util.elf import ElfParsingError, parse_elf -from spack.util.executable import Executable def is_shared_library_elf(filepath): @@ -141,7 +140,7 @@ def post_install(spec, explicit=None): return # Only enable on platforms using ELF. - if not spec.satisfies("platform=linux") and not spec.satisfies("platform=cray"): + if not spec.satisfies("platform=linux"): return # Disable this hook when bootstrapping, to avoid recursion. @@ -149,10 +148,9 @@ def post_install(spec, explicit=None): return # Should failing to locate patchelf be a hard error? - patchelf_path = spack.relocate._patchelf() - if not patchelf_path: + patchelf = spack.relocate._patchelf() + if not patchelf: return - patchelf = Executable(patchelf_path) fixes = find_and_patch_sonames(spec.prefix, spec.package.non_bindable_shared_objects, patchelf) diff --git a/lib/spack/spack/hooks/autopush.py b/lib/spack/spack/hooks/autopush.py new file mode 100644 index 00000000000000..1974c8d3ab4001 --- /dev/null +++ b/lib/spack/spack/hooks/autopush.py @@ -0,0 +1,31 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import llnl.util.tty as tty + +import spack.binary_distribution as bindist +import spack.mirror + + +def post_install(spec, explicit): + # Push package to all buildcaches with autopush==True + + # Do nothing if spec is an external package + if spec.external: + return + + # Do nothing if package was not installed from source + pkg = spec.package + if pkg.installed_from_binary_cache: + return + + # Push the package to all autopush mirrors + for mirror in spack.mirror.MirrorCollection(binary=True, autopush=True).values(): + bindist.push_or_raise( + spec, + mirror.push_url, + bindist.PushOptions(force=True, regenerate_index=False, unsigned=not mirror.signed), + ) + tty.msg(f"{spec.name}: Pushed to build cache: '{mirror.name}'") diff --git a/lib/spack/spack/hooks/drop_redundant_rpaths.py b/lib/spack/spack/hooks/drop_redundant_rpaths.py index 2577ce18f43fb4..f17355fe78f225 100644 --- a/lib/spack/spack/hooks/drop_redundant_rpaths.py +++ b/lib/spack/spack/hooks/drop_redundant_rpaths.py @@ -117,7 +117,7 @@ def post_install(spec, explicit=None): return # Only enable on platforms using ELF. - if not spec.satisfies("platform=linux") and not spec.satisfies("platform=cray"): + if not spec.satisfies("platform=linux"): return visit_directory_tree(spec.prefix, ElfFilesWithRPathVisitor()) diff --git a/lib/spack/spack/hooks/windows_runtime_linkage.py b/lib/spack/spack/hooks/windows_runtime_linkage.py new file mode 100644 index 00000000000000..5bb37449108121 --- /dev/null +++ b/lib/spack/spack/hooks/windows_runtime_linkage.py @@ -0,0 +1,8 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +def post_install(spec, explicit=None): + spec.package.windows_establish_runtime_linkage() diff --git a/lib/spack/spack/installer.py b/lib/spack/spack/installer.py index 915327e3b49f74..dc94c95926aa1f 100644 --- a/lib/spack/spack/installer.py +++ b/lib/spack/spack/installer.py @@ -119,7 +119,7 @@ def __init__(self, pkg_count: int): self.pkg_ids: Set[str] = set() def next_pkg(self, pkg: "spack.package_base.PackageBase"): - pkg_id = package_id(pkg) + pkg_id = package_id(pkg.spec) if pkg_id not in self.pkg_ids: self.pkg_num += 1 @@ -221,12 +221,12 @@ def _handle_external_and_upstream(pkg: "spack.package_base.PackageBase", explici # consists in module file generation and registration in the DB. if pkg.spec.external: _process_external_package(pkg, explicit) - _print_installed_pkg(f"{pkg.prefix} (external {package_id(pkg)})") + _print_installed_pkg(f"{pkg.prefix} (external {package_id(pkg.spec)})") return True if pkg.spec.installed_upstream: tty.verbose( - f"{package_id(pkg)} is installed in an upstream Spack instance at " + f"{package_id(pkg.spec)} is installed in an upstream Spack instance at " f"{pkg.spec.prefix}" ) _print_installed_pkg(pkg.prefix) @@ -403,7 +403,7 @@ def _install_from_cache( return False t.stop() - pkg_id = package_id(pkg) + pkg_id = package_id(pkg.spec) tty.debug(f"Successfully extracted {pkg_id} from binary cache") _write_timer_json(pkg, t, True) @@ -484,10 +484,14 @@ def _process_binary_cache_tarball( if download_result is None: return False - tty.msg(f"Extracting {package_id(pkg)} from binary cache") + tty.msg(f"Extracting {package_id(pkg.spec)} from binary cache") with timer.measure("install"), spack.util.path.filter_padding(): binary_distribution.extract_tarball(pkg.spec, download_result, force=False, timer=timer) + pkg.windows_establish_runtime_linkage() + + if hasattr(pkg, "_post_buildcache_install_hook"): + pkg._post_buildcache_install_hook() pkg.installed_from_binary_cache = True spack.store.STORE.db.add(pkg.spec, spack.store.STORE.layout, explicit=explicit) @@ -513,7 +517,7 @@ def _try_install_from_binary_cache( if not spack.mirror.MirrorCollection(binary=True): return False - tty.debug(f"Searching for binary cache of {package_id(pkg)}") + tty.debug(f"Searching for binary cache of {package_id(pkg.spec)}") with timer.measure("search"): matches = binary_distribution.get_mirrors_for_spec(pkg.spec, index_only=True) @@ -578,7 +582,7 @@ def dump_packages(spec: "spack.spec.Spec", path: str) -> None: # Create a source repo and get the pkg directory out of it. try: - source_repo = spack.repo.Repo(source_repo_root) + source_repo = spack.repo.from_path(source_repo_root) source_pkg_dir = source_repo.dirname_for_package_name(node.name) except spack.repo.RepoError as err: tty.debug(f"Failed to create source repo for {node.name}: {str(err)}") @@ -589,16 +593,14 @@ def dump_packages(spec: "spack.spec.Spec", path: str) -> None: dest_repo_root = os.path.join(path, node.namespace) if not os.path.exists(dest_repo_root): spack.repo.create_repo(dest_repo_root) - repo = spack.repo.Repo(dest_repo_root) + repo = spack.repo.from_path(dest_repo_root) # Get the location of the package in the dest repo. dest_pkg_dir = repo.dirname_for_package_name(node.name) if node is spec: spack.repo.PATH.dump_provenance(node, dest_pkg_dir) elif source_pkg_dir: - fs.install_tree( - source_pkg_dir, dest_pkg_dir, allow_broken_symlinks=(sys.platform != "win32") - ) + fs.install_tree(source_pkg_dir, dest_pkg_dir) def get_dependent_ids(spec: "spack.spec.Spec") -> List[str]: @@ -610,7 +612,7 @@ def get_dependent_ids(spec: "spack.spec.Spec") -> List[str]: Returns: list of package ids """ - return [package_id(d.package) for d in spec.dependents()] + return [package_id(d) for d in spec.dependents()] def install_msg(name: str, pid: int, install_status: InstallStatus) -> str: @@ -720,7 +722,7 @@ def log(pkg: "spack.package_base.PackageBase") -> None: dump_packages(pkg.spec, packages_dir) -def package_id(pkg: "spack.package_base.PackageBase") -> str: +def package_id(spec: "spack.spec.Spec") -> str: """A "unique" package identifier for installation purposes The identifier is used to track build tasks, locks, install, and @@ -732,10 +734,10 @@ def package_id(pkg: "spack.package_base.PackageBase") -> str: Args: pkg: the package from which the identifier is derived """ - if not pkg.spec.concrete: + if not spec.concrete: raise ValueError("Cannot provide a unique, readable id when the spec is not concretized.") - return f"{pkg.name}-{pkg.version}-{pkg.spec.dag_hash()}" + return f"{spec.name}-{spec.version}-{spec.dag_hash()}" class BuildRequest: @@ -757,15 +759,11 @@ def __init__(self, pkg: "spack.package_base.PackageBase", install_args: dict): if not self.pkg.spec.concrete: raise ValueError(f"{self.pkg.name} must have a concrete spec") - # Cache the package phase options with the explicit package, - # popping the options to ensure installation of associated - # dependencies is NOT affected by these options. - - self.pkg.stop_before_phase = install_args.pop("stop_before", None) # type: ignore[attr-defined] # noqa: E501 - self.pkg.last_phase = install_args.pop("stop_at", None) # type: ignore[attr-defined] + self.pkg.stop_before_phase = install_args.get("stop_before") # type: ignore[attr-defined] # noqa: E501 + self.pkg.last_phase = install_args.get("stop_at") # type: ignore[attr-defined] # Cache the package id for convenience - self.pkg_id = package_id(pkg) + self.pkg_id = package_id(pkg.spec) # Save off the original install arguments plus standard defaults # since they apply to the requested package *and* dependencies. @@ -780,9 +778,9 @@ def __init__(self, pkg: "spack.package_base.PackageBase", install_args: dict): # are not able to return full dependents for all packages across # environment specs. self.dependencies = set( - package_id(d.package) + package_id(d) for d in self.pkg.spec.dependencies(deptype=self.get_depflags(self.pkg)) - if package_id(d.package) != self.pkg_id + if package_id(d) != self.pkg_id ) def __repr__(self) -> str: @@ -832,7 +830,7 @@ def get_depflags(self, pkg: "spack.package_base.PackageBase") -> int: depflag = dt.LINK | dt.RUN include_build_deps = self.install_args.get("include_build_deps") - if self.pkg_id == package_id(pkg): + if self.pkg_id == package_id(pkg.spec): cache_only = self.install_args.get("package_cache_only") else: cache_only = self.install_args.get("dependencies_cache_only") @@ -927,7 +925,7 @@ def __init__( raise ValueError(f"{self.pkg.name} must have a concrete spec") # The "unique" identifier for the task's package - self.pkg_id = package_id(self.pkg) + self.pkg_id = package_id(self.pkg.spec) # The explicit build request associated with the package if not isinstance(request, BuildRequest): @@ -965,9 +963,9 @@ def __init__( # if use traverse for transitive dependencies, then must remove # transitive dependents on failure. self.dependencies = set( - package_id(d.package) + package_id(d) for d in self.pkg.spec.dependencies(deptype=self.request.get_depflags(self.pkg)) - if package_id(d.package) != self.pkg_id + if package_id(d) != self.pkg_id ) # Handle bootstrapped compiler @@ -976,14 +974,18 @@ def __init__( # a dependency of the build task. Here we add it to self.dependencies compiler_spec = self.pkg.spec.compiler arch_spec = self.pkg.spec.architecture - if not spack.compilers.compilers_for_spec(compiler_spec, arch_spec=arch_spec): + strict = spack.concretize.Concretizer().check_for_compiler_existence + if ( + not spack.compilers.compilers_for_spec(compiler_spec, arch_spec=arch_spec) + and not strict + ): # The compiler is in the queue, identify it as dependency dep = spack.compilers.pkg_spec_for_compiler(compiler_spec) dep.constrain(f"platform={str(arch_spec.platform)}") dep.constrain(f"os={str(arch_spec.os)}") dep.constrain(f"target={arch_spec.target.microarchitecture.family.name}:") dep.concretize() - dep_id = package_id(dep.package) + dep_id = package_id(dep) self.dependencies.add(dep_id) # List of uninstalled dependencies, which is used to establish @@ -1068,19 +1070,17 @@ def flag_installed(self, installed: List[str]) -> None: @property def explicit(self) -> bool: - """The package was explicitly requested by the user.""" - return self.is_root and self.request.install_args.get("explicit", True) + return self.pkg.spec.dag_hash() in self.request.install_args.get("explicit", []) @property - def is_root(self) -> bool: - """The package was requested directly, but may or may not be explicit - in an environment.""" + def is_build_request(self) -> bool: + """The package was requested directly""" return self.pkg == self.request.pkg @property def use_cache(self) -> bool: _use_cache = True - if self.is_root: + if self.is_build_request: return self.request.install_args.get("package_use_cache", _use_cache) else: return self.request.install_args.get("dependencies_use_cache", _use_cache) @@ -1088,7 +1088,7 @@ def use_cache(self) -> bool: @property def cache_only(self) -> bool: _cache_only = False - if self.is_root: + if self.is_build_request: return self.request.install_args.get("package_cache_only", _cache_only) else: return self.request.install_args.get("dependencies_cache_only", _cache_only) @@ -1114,24 +1114,17 @@ def priority(self): class PackageInstaller: """ - Class for managing the install process for a Spack instance based on a - bottom-up DAG approach. + Class for managing the install process for a Spack instance based on a bottom-up DAG approach. - This installer can coordinate concurrent batch and interactive, local - and distributed (on a shared file system) builds for the same Spack - instance. + This installer can coordinate concurrent batch and interactive, local and distributed (on a + shared file system) builds for the same Spack instance. """ - def __init__(self, installs: List[Tuple["spack.package_base.PackageBase", dict]] = []) -> None: - """Initialize the installer. - - Args: - installs (list): list of tuples, where each - tuple consists of a package (PackageBase) and its associated - install arguments (dict) - """ + def __init__( + self, packages: List["spack.package_base.PackageBase"], install_args: dict + ) -> None: # List of build requests - self.build_requests = [BuildRequest(pkg, install_args) for pkg, install_args in installs] + self.build_requests = [BuildRequest(pkg, install_args) for pkg in packages] # Priority queue of build tasks self.build_pq: List[Tuple[Tuple[int, int], BuildTask]] = [] @@ -1194,7 +1187,7 @@ def _add_bootstrap_compilers( """ packages = _packages_needed_to_bootstrap_compiler(compiler, architecture, pkgs) for comp_pkg, is_compiler in packages: - pkgid = package_id(comp_pkg) + pkgid = package_id(comp_pkg.spec) if pkgid not in self.build_tasks: self._add_init_task(comp_pkg, request, is_compiler, all_deps) elif is_compiler: @@ -1241,7 +1234,7 @@ def _add_init_task( """ task = BuildTask(pkg, request, is_compiler, 0, 0, STATUS_ADDED, self.installed) for dep_id in task.dependencies: - all_deps[dep_id].add(package_id(pkg)) + all_deps[dep_id].add(package_id(pkg.spec)) self._push_task(task) @@ -1276,7 +1269,7 @@ def _check_deps_status(self, request: BuildRequest) -> None: err = "Cannot proceed with {0}: {1}" for dep in request.traverse_dependencies(): dep_pkg = dep.package - dep_id = package_id(dep_pkg) + dep_id = package_id(dep) # Check for failure since a prefix lock is not required if spack.store.STORE.failure_tracker.has_failed(dep): @@ -1409,7 +1402,7 @@ def _cleanup_task(self, pkg: "spack.package_base.PackageBase") -> None: Args: pkg: the package being installed """ - self._remove_task(package_id(pkg)) + self._remove_task(package_id(pkg.spec)) # Ensure we have a read lock to prevent others from uninstalling the # spec during our installation. @@ -1423,7 +1416,7 @@ def _ensure_install_ready(self, pkg: "spack.package_base.PackageBase") -> None: Args: pkg: the package being locally installed """ - pkg_id = package_id(pkg) + pkg_id = package_id(pkg.spec) pre = f"{pkg_id} cannot be installed locally:" # External packages cannot be installed locally. @@ -1465,7 +1458,7 @@ def _ensure_locked( "write", ], f'"{lock_type}" is not a supported package management lock type' - pkg_id = package_id(pkg) + pkg_id = package_id(pkg.spec) ltype, lock = self.locks.get(pkg_id, (lock_type, None)) if lock and ltype == lock_type: return ltype, lock @@ -1549,17 +1542,6 @@ def _add_tasks(self, request: BuildRequest, all_deps): tty.warn(f"Installation request refused: {str(err)}") return - # Skip out early if the spec is not being installed locally (i.e., if - # external or upstream). - # - # External and upstream packages need to get flagged as installed to - # ensure proper status tracking for environment build. - explicit = request.install_args.get("explicit", True) - not_local = _handle_external_and_upstream(request.pkg, explicit) - if not_local: - self._flag_installed(request.pkg) - return - install_compilers = spack.config.get("config:install_missing_compilers", False) install_deps = request.install_args.get("install_deps") @@ -1601,7 +1583,7 @@ def _add_tasks(self, request: BuildRequest, all_deps): for dep in request.traverse_dependencies(): dep_pkg = dep.package - dep_id = package_id(dep_pkg) + dep_id = package_id(dep) if dep_id not in self.build_tasks: self._add_init_task(dep_pkg, request, False, all_deps) @@ -1675,10 +1657,6 @@ def _install_task(self, task: BuildTask, install_status: InstallStatus) -> None: if not pkg.unit_test_check(): return - # Injecting information to know if this installation request is the root one - # to determine in BuildProcessInstaller whether installation is explicit or not - install_args["is_root"] = task.is_root - try: self._setup_install_dir(pkg) @@ -1691,10 +1669,6 @@ def _install_task(self, task: BuildTask, install_status: InstallStatus) -> None: spack.package_base.PackageBase._verbose = spack.build_environment.start_build_process( pkg, build_process, install_args ) - # Currently this is how RPATH-like behavior is achieved on Windows, after install - # establish runtime linkage via Windows Runtime link object - # Note: this is a no-op on non Windows platforms - pkg.windows_establish_runtime_linkage() # Note: PARENT of the build process adds the new package to # the database, so that we don't need to re-read from file. spack.store.STORE.db.add(pkg.spec, spack.store.STORE.layout, explicit=explicit) @@ -1913,7 +1887,7 @@ def _flag_installed( dependent_ids: set of the package's dependent ids, or None if the dependent ids are limited to those maintained in the package (dependency DAG) """ - pkg_id = package_id(pkg) + pkg_id = package_id(pkg.spec) if pkg_id in self.installed: # Already determined the package has been installed @@ -1994,8 +1968,8 @@ def install(self) -> None: self._init_queue() fail_fast_err = "Terminating after first install failure" - single_explicit_spec = len(self.build_requests) == 1 - failed_explicits = [] + single_requested_spec = len(self.build_requests) == 1 + failed_build_requests = [] install_status = InstallStatus(len(self.build_pq)) @@ -2044,11 +2018,10 @@ def install(self) -> None: # Skip the installation if the spec is not being installed locally # (i.e., if external or upstream) BUT flag it as installed since # some package likely depends on it. - if not task.explicit: - if _handle_external_and_upstream(pkg, False): - term_status.clear() - self._flag_installed(pkg, task.dependents) - continue + if _handle_external_and_upstream(pkg, task.explicit): + term_status.clear() + self._flag_installed(pkg, task.dependents) + continue # Flag a failed spec. Do not need an (install) prefix lock since # assume using a separate (failed) prefix lock file. @@ -2193,14 +2166,11 @@ def install(self) -> None: if self.fail_fast: raise InstallError(f"{fail_fast_err}: {str(exc)}", pkg=pkg) - # Terminate at this point if the single explicit spec has - # failed to install. - if single_explicit_spec and task.explicit: - raise - - # Track explicit spec id and error to summarize when done - if task.explicit: - failed_explicits.append((pkg, pkg_id, str(exc))) + # Terminate when a single build request has failed, or summarize errors later. + if task.is_build_request: + if single_requested_spec: + raise + failed_build_requests.append((pkg, pkg_id, str(exc))) finally: # Remove the install prefix if anything went wrong during @@ -2223,16 +2193,16 @@ def install(self) -> None: if request.install_args.get("install_package") and request.pkg_id not in self.installed ] - if failed_explicits or missing: - for _, pkg_id, err in failed_explicits: + if failed_build_requests or missing: + for _, pkg_id, err in failed_build_requests: tty.error(f"{pkg_id}: {err}") for _, pkg_id in missing: tty.error(f"{pkg_id}: Package was not installed") - if len(failed_explicits) > 0: - pkg = failed_explicits[0][0] - ids = [pkg_id for _, pkg_id, _ in failed_explicits] + if len(failed_build_requests) > 0: + pkg = failed_build_requests[0][0] + ids = [pkg_id for _, pkg_id, _ in failed_build_requests] tty.debug( "Associating installation failure with first failed " f"explicit package ({ids[0]}) from {', '.join(ids)}" @@ -2274,11 +2244,15 @@ def __init__(self, pkg: "spack.package_base.PackageBase", install_args: dict): # whether to install source code with the packag self.install_source = install_args.get("install_source", False) + is_develop = pkg.spec.is_develop # whether to keep the build stage after installation - self.keep_stage = install_args.get("keep_stage", False) - + # Note: user commands do not have an explicit choice to disable + # keeping stages (i.e., we have a --keep-stage option, but not + # a --destroy-stage option), so we can override a default choice + # to destroy + self.keep_stage = is_develop or install_args.get("keep_stage", False) # whether to restage - self.restage = install_args.get("restage", False) + self.restage = (not is_develop) and install_args.get("restage", False) # whether to skip the patch phase self.skip_patch = install_args.get("skip_patch", False) @@ -2287,7 +2261,7 @@ def __init__(self, pkg: "spack.package_base.PackageBase", install_args: dict): self.verbose = bool(install_args.get("verbose", False)) # whether installation was explicitly requested by the user - self.explicit = install_args.get("is_root", False) and install_args.get("explicit", True) + self.explicit = pkg.spec.dag_hash() in install_args.get("explicit", []) # env before starting installation self.unmodified_env = install_args.get("unmodified_env", {}) @@ -2305,7 +2279,7 @@ def __init__(self, pkg: "spack.package_base.PackageBase", install_args: dict): # info/debug information self.pre = _log_prefix(pkg.name) - self.pkg_id = package_id(pkg) + self.pkg_id = package_id(pkg.spec) def run(self) -> bool: """Main entry point from ``build_process`` to kick off install in child.""" @@ -2372,9 +2346,7 @@ def _install_source(self) -> None: src_target = os.path.join(pkg.spec.prefix, "share", pkg.name, "src") tty.debug(f"{self.pre} Copying source to {src_target}") - fs.install_tree( - pkg.stage.source_path, src_target, allow_broken_symlinks=(sys.platform != "win32") - ) + fs.install_tree(pkg.stage.source_path, src_target) def _real_install(self) -> None: import spack.builder diff --git a/lib/spack/spack/main.py b/lib/spack/spack/main.py index bff07ccbfbeee1..78fda27c4628c4 100644 --- a/lib/spack/spack/main.py +++ b/lib/spack/spack/main.py @@ -427,7 +427,7 @@ def make_argument_parser(**kwargs): parser.add_argument( "--color", action="store", - default=os.environ.get("SPACK_COLOR", "auto"), + default=None, choices=("always", "never", "auto"), help="when to colorize output (default: auto)", ) @@ -444,8 +444,9 @@ def make_argument_parser(**kwargs): "--config-scope", dest="config_scopes", action="append", - metavar="DIR", - help="add a custom configuration scope", + metavar="DIR|ENV", + help="add directory or environment as read-only configuration scope, without activating " + "the environment.", ) parser.add_argument( "-d", @@ -622,7 +623,8 @@ def setup_main_options(args): # with color color.try_enable_terminal_color_on_windows() # when to use color (takes always, auto, or never) - color.set_color_when(args.color) + if args.color is not None: + color.set_color_when(args.color) def allows_unknown_args(command): diff --git a/lib/spack/spack/mirror.py b/lib/spack/spack/mirror.py index 2f1b9966ce2155..45681be85395dd 100644 --- a/lib/spack/spack/mirror.py +++ b/lib/spack/spack/mirror.py @@ -137,6 +137,12 @@ def source(self): def signed(self) -> bool: return isinstance(self._data, str) or self._data.get("signed", True) + @property + def autopush(self) -> bool: + if isinstance(self._data, str): + return False + return self._data.get("autopush", False) + @property def fetch_url(self): """Get the valid, canonicalized fetch URL""" @@ -150,7 +156,7 @@ def push_url(self): def _update_connection_dict(self, current_data: dict, new_data: dict, top_level: bool): keys = ["url", "access_pair", "access_token", "profile", "endpoint_url"] if top_level: - keys += ["binary", "source", "signed"] + keys += ["binary", "source", "signed", "autopush"] changed = False for key in keys: if key in new_data and current_data.get(key) != new_data[key]: @@ -286,6 +292,7 @@ def __init__( scope=None, binary: Optional[bool] = None, source: Optional[bool] = None, + autopush: Optional[bool] = None, ): """Initialize a mirror collection. @@ -297,21 +304,27 @@ def __init__( If None, do not filter on binary mirrors. source: If True, only include source mirrors. If False, omit source mirrors. - If None, do not filter on source mirrors.""" - self._mirrors = { - name: Mirror(data=mirror, name=name) - for name, mirror in ( - mirrors.items() - if mirrors is not None - else spack.config.get("mirrors", scope=scope).items() - ) - } - - if source is not None: - self._mirrors = {k: v for k, v in self._mirrors.items() if v.source == source} - - if binary is not None: - self._mirrors = {k: v for k, v in self._mirrors.items() if v.binary == binary} + If None, do not filter on source mirrors. + autopush: If True, only include mirrors that have autopush enabled. + If False, omit mirrors that have autopush enabled. + If None, do not filter on autopush.""" + mirrors_data = ( + mirrors.items() + if mirrors is not None + else spack.config.get("mirrors", scope=scope).items() + ) + mirrors = (Mirror(data=mirror, name=name) for name, mirror in mirrors_data) + + def _filter(m: Mirror): + if source is not None and m.source != source: + return False + if binary is not None and m.binary != binary: + return False + if autopush is not None and m.autopush != autopush: + return False + return True + + self._mirrors = {m.name: m for m in mirrors if _filter(m)} def __eq__(self, other): return self._mirrors == other._mirrors diff --git a/lib/spack/spack/modules/common.py b/lib/spack/spack/modules/common.py index 5f8c83bf4f122f..0f36f6789d8abf 100644 --- a/lib/spack/spack/modules/common.py +++ b/lib/spack/spack/modules/common.py @@ -83,6 +83,17 @@ def configuration(module_set_name): ) +_FORMAT_STRING_RE = re.compile(r"({[^}]*})") + + +def _format_env_var_name(spec, var_name_fmt): + """Format the variable name, but uppercase any formatted fields.""" + fmt_parts = _FORMAT_STRING_RE.split(var_name_fmt) + return "".join( + spec.format(part).upper() if _FORMAT_STRING_RE.match(part) else part for part in fmt_parts + ) + + def _check_tokens_are_valid(format_string, message): """Checks that the tokens used in the format string are valid in the context of module file and environment variable naming. @@ -750,20 +761,12 @@ def environment_modifications(self): exclude = self.conf.exclude_env_vars # We may have tokens to substitute in environment commands - - # Prepare a suitable transformation dictionary for the names - # of the environment variables. This means turn the valid - # tokens uppercase. - transform = {} - for token in _valid_tokens: - transform[token] = lambda s, string: str.upper(string) - for x in env: # Ensure all the tokens are valid in this context msg = "some tokens cannot be expanded in an environment variable name" + _check_tokens_are_valid(x.name, message=msg) - # Transform them - x.name = self.spec.format(x.name, transform=transform) + x.name = _format_env_var_name(self.spec, x.name) if self.modification_needs_formatting(x): try: # Not every command has a value diff --git a/lib/spack/spack/oci/oci.py b/lib/spack/spack/oci/oci.py index fefc66674ec5d3..09e79df347dcd7 100644 --- a/lib/spack/spack/oci/oci.py +++ b/lib/spack/spack/oci/oci.py @@ -11,7 +11,7 @@ import urllib.parse import urllib.request from http.client import HTTPResponse -from typing import NamedTuple, Tuple +from typing import List, NamedTuple, Tuple from urllib.request import Request import llnl.util.tty as tty @@ -27,6 +27,7 @@ import spack.stage import spack.traverse import spack.util.crypto +import spack.util.url from .image import Digest, ImageReference @@ -69,6 +70,42 @@ def with_query_param(url: str, param: str, value: str) -> str: ) +def list_tags(ref: ImageReference, _urlopen: spack.oci.opener.MaybeOpen = None) -> List[str]: + """Retrieves the list of tags associated with an image, handling pagination.""" + _urlopen = _urlopen or spack.oci.opener.urlopen + tags = set() + fetch_url = ref.tags_url() + + while True: + # Fetch tags + request = Request(url=fetch_url) + response = _urlopen(request) + spack.oci.opener.ensure_status(request, response, 200) + tags.update(json.load(response)["tags"]) + + # Check for pagination + link_header = response.headers["Link"] + + if link_header is None: + break + + tty.debug(f"OCI tag pagination: {link_header}") + + rel_next_value = spack.util.url.parse_link_rel_next(link_header) + + if rel_next_value is None: + break + + rel_next = urllib.parse.urlparse(rel_next_value) + + if rel_next.scheme not in ("https", ""): + break + + fetch_url = ref.endpoint(rel_next_value) + + return sorted(tags) + + def upload_blob( ref: ImageReference, file: str, diff --git a/lib/spack/spack/oci/opener.py b/lib/spack/spack/oci/opener.py index 182e60eb94054b..53535b85ed7672 100644 --- a/lib/spack/spack/oci/opener.py +++ b/lib/spack/spack/oci/opener.py @@ -398,7 +398,7 @@ def create_opener(): opener = urllib.request.OpenerDirector() for handler in [ urllib.request.UnknownHandler(), - urllib.request.HTTPSHandler(), + urllib.request.HTTPSHandler(context=spack.util.web.ssl_create_default_context()), spack.util.web.SpackHTTPDefaultErrorHandler(), urllib.request.HTTPRedirectHandler(), urllib.request.HTTPErrorProcessor(), @@ -418,18 +418,27 @@ def ensure_status(request: urllib.request.Request, response: HTTPResponse, statu ) -def default_retry(f, retries: int = 3, sleep=None): +def default_retry(f, retries: int = 5, sleep=None): sleep = sleep or time.sleep def wrapper(*args, **kwargs): for i in range(retries): try: return f(*args, **kwargs) - except urllib.error.HTTPError as e: + except (urllib.error.URLError, TimeoutError) as e: # Retry on internal server errors, and rate limit errors # Potentially this could take into account the Retry-After header # if registries support it - if i + 1 != retries and (500 <= e.code < 600 or e.code == 429): + if i + 1 != retries and ( + ( + isinstance(e, urllib.error.HTTPError) + and (500 <= e.code < 600 or e.code == 429) + ) + or ( + isinstance(e, urllib.error.URLError) and isinstance(e.reason, TimeoutError) + ) + or isinstance(e, TimeoutError) + ): # Exponential backoff sleep(2**i) continue diff --git a/lib/spack/spack/operating_systems/__init__.py b/lib/spack/spack/operating_systems/__init__.py index 22a5ea48e78a14..2b60c62525846a 100644 --- a/lib/spack/spack/operating_systems/__init__.py +++ b/lib/spack/spack/operating_systems/__init__.py @@ -3,22 +3,12 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) from ._operating_system import OperatingSystem -from .cray_backend import CrayBackend -from .cray_frontend import CrayFrontend from .freebsd import FreeBSDOs from .linux_distro import LinuxDistro from .mac_os import MacOs from .windows_os import WindowsOs -__all__ = [ - "OperatingSystem", - "LinuxDistro", - "MacOs", - "CrayFrontend", - "CrayBackend", - "WindowsOs", - "FreeBSDOs", -] +__all__ = ["OperatingSystem", "LinuxDistro", "MacOs", "WindowsOs", "FreeBSDOs"] #: List of all the Operating Systems known to Spack -operating_systems = [LinuxDistro, MacOs, CrayFrontend, CrayBackend, WindowsOs, FreeBSDOs] +operating_systems = [LinuxDistro, MacOs, WindowsOs, FreeBSDOs] diff --git a/lib/spack/spack/operating_systems/cray_backend.py b/lib/spack/spack/operating_systems/cray_backend.py deleted file mode 100644 index 6657020dfffbc3..00000000000000 --- a/lib/spack/spack/operating_systems/cray_backend.py +++ /dev/null @@ -1,172 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -import os -import re - -import llnl.util.tty as tty - -import spack.error -import spack.version -from spack.util.module_cmd import module - -from .linux_distro import LinuxDistro - -#: Possible locations of the Cray CLE release file, -#: which we look at to get the CNL OS version. -_cle_release_file = "/etc/opt/cray/release/cle-release" -_clerelease_file = "/etc/opt/cray/release/clerelease" - - -def read_cle_release_file(): - """Read the CLE release file and return a dict with its attributes. - - This file is present on newer versions of Cray. - - The release file looks something like this:: - - RELEASE=6.0.UP07 - BUILD=6.0.7424 - ... - - The dictionary we produce looks like this:: - - { - "RELEASE": "6.0.UP07", - "BUILD": "6.0.7424", - ... - } - - Returns: - dict: dictionary of release attributes - """ - with open(_cle_release_file) as release_file: - result = {} - for line in release_file: - # use partition instead of split() to ensure we only split on - # the first '=' in the line. - key, _, value = line.partition("=") - result[key] = value.strip() - return result - - -def read_clerelease_file(): - """Read the CLE release file and return the Cray OS version. - - This file is present on older versions of Cray. - - The release file looks something like this:: - - 5.2.UP04 - - Returns: - str: the Cray OS version - """ - with open(_clerelease_file) as release_file: - for line in release_file: - return line.strip() - - -class CrayBackend(LinuxDistro): - """Compute Node Linux (CNL) is the operating system used for the Cray XC - series super computers. It is a very stripped down version of GNU/Linux. - Any compilers found through this operating system will be used with - modules. If updated, user must make sure that version and name are - updated to indicate that OS has been upgraded (or downgraded) - """ - - def __init__(self): - name = "cnl" - version = self._detect_crayos_version() - if version: - # If we found a CrayOS version, we do not want the information - # from LinuxDistro. In order to skip the logic from - # distro.linux_distribution, while still calling __init__ - # methods further up the MRO, we skip LinuxDistro in the MRO and - # call the OperatingSystem superclass __init__ method - super(LinuxDistro, self).__init__(name, version) - else: - super().__init__() - self.modulecmd = module - - def __str__(self): - return self.name + str(self.version) - - @classmethod - def _detect_crayos_version(cls): - if os.path.isfile(_cle_release_file): - release_attrs = read_cle_release_file() - if "RELEASE" not in release_attrs: - # This Cray system uses a base OS not CLE/CNL - return None - v = spack.version.Version(release_attrs["RELEASE"]) - return v[0] - elif os.path.isfile(_clerelease_file): - v = read_clerelease_file() - return spack.version.Version(v)[0] - else: - # Not all Cray systems run CNL on the backend. - # Systems running in what Cray calls "cluster" mode run other - # linux OSs under the Cray PE. - # So if we don't detect any Cray OS version on the system, - # we return None. We can't ever be sure we will get a Cray OS - # version. - # Returning None allows the calling code to test for the value - # being "True-ish" rather than requiring a try/except block. - return None - - def arguments_to_detect_version_fn(self, paths): - import spack.compilers - - command_arguments = [] - for compiler_name in spack.compilers.supported_compilers(): - cmp_cls = spack.compilers.class_for_compiler_name(compiler_name) - - # If the compiler doesn't have a corresponding - # Programming Environment, skip to the next - if cmp_cls.PrgEnv is None: - continue - - if cmp_cls.PrgEnv_compiler is None: - tty.die("Must supply PrgEnv_compiler with PrgEnv") - - compiler_id = spack.compilers.CompilerID(self, compiler_name, None) - detect_version_args = spack.compilers.DetectVersionArgs( - id=compiler_id, variation=(None, None), language="cc", path="cc" - ) - command_arguments.append(detect_version_args) - return command_arguments - - def detect_version(self, detect_version_args): - import spack.compilers - - modulecmd = self.modulecmd - compiler_name = detect_version_args.id.compiler_name - compiler_cls = spack.compilers.class_for_compiler_name(compiler_name) - output = modulecmd("avail", compiler_cls.PrgEnv_compiler) - version_regex = r"({0})/([\d\.]+[\d]-?[\w]*)".format(compiler_cls.PrgEnv_compiler) - matches = re.findall(version_regex, output) - version = tuple(version for _, version in matches if "classic" not in version) - compiler_id = detect_version_args.id - value = detect_version_args._replace(id=compiler_id._replace(version=version)) - return value, None - - def make_compilers(self, compiler_id, paths): - import spack.spec - - name = compiler_id.compiler_name - cmp_cls = spack.compilers.class_for_compiler_name(name) - compilers = [] - for v in compiler_id.version: - comp = cmp_cls( - spack.spec.CompilerSpec(name + "@=" + v), - self, - "any", - ["cc", "CC", "ftn"], - [cmp_cls.PrgEnv, name + "/" + v], - ) - - compilers.append(comp) - return compilers diff --git a/lib/spack/spack/operating_systems/cray_frontend.py b/lib/spack/spack/operating_systems/cray_frontend.py deleted file mode 100644 index d6fa4fd2fae2fd..00000000000000 --- a/lib/spack/spack/operating_systems/cray_frontend.py +++ /dev/null @@ -1,105 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -import contextlib -import os -import re - -import llnl.util.filesystem as fs -import llnl.util.lang -import llnl.util.tty as tty - -from spack.util.environment import get_path -from spack.util.module_cmd import module - -from .linux_distro import LinuxDistro - - -@contextlib.contextmanager -def unload_programming_environment(): - """Context manager that unloads Cray Programming Environments.""" - env_bu = None - - # We rely on the fact that the PrgEnv-* modules set the PE_ENV - # environment variable. - if "PE_ENV" in os.environ: - # Copy environment variables to restore them after the compiler - # detection. We expect that the only thing PrgEnv-* modules do is - # the environment variables modifications. - env_bu = os.environ.copy() - - # Get the name of the module from the environment variable. - prg_env = "PrgEnv-" + os.environ["PE_ENV"].lower() - - # Unload the PrgEnv-* module. By doing this we intentionally - # provoke errors when the Cray's compiler wrappers are executed - # (Error: A PrgEnv-* modulefile must be loaded.) so they will not - # be detected as valid compilers by the overridden method. We also - # expect that the modules that add the actual compilers' binaries - # into the PATH environment variable (i.e. the following modules: - # 'intel', 'cce', 'gcc', etc.) will also be unloaded since they are - # specified as prerequisites in the PrgEnv-* modulefiles. - module("unload", prg_env) - - yield - - # Restore the environment. - if env_bu is not None: - os.environ.clear() - os.environ.update(env_bu) - - -class CrayFrontend(LinuxDistro): - """Represents OS that runs on login and service nodes of the Cray platform. - It acts as a regular Linux without Cray-specific modules and compiler - wrappers.""" - - @property - def compiler_search_paths(self): - """Calls the default function but unloads Cray's programming - environments first. - - This prevents from detecting Cray compiler wrappers and avoids - possible false detections. - """ - import spack.compilers - - with unload_programming_environment(): - search_paths = get_path("PATH") - - extract_path_re = re.compile(r"prepend-path[\s]*PATH[\s]*([/\w\.:-]*)") - - for compiler_cls in spack.compilers.all_compiler_types(): - # Check if the compiler class is supported on Cray - prg_env = getattr(compiler_cls, "PrgEnv", None) - compiler_module = getattr(compiler_cls, "PrgEnv_compiler", None) - if not (prg_env and compiler_module): - continue - - # It is supported, check which versions are available - output = module("avail", compiler_cls.PrgEnv_compiler) - version_regex = r"({0})/([\d\.]+[\d]-?[\w]*)".format(compiler_cls.PrgEnv_compiler) - matches = re.findall(version_regex, output) - versions = tuple(version for _, version in matches if "classic" not in version) - - # Now inspect the modules and add to paths - msg = "[CRAY FE] Detected FE compiler [name={0}, versions={1}]" - tty.debug(msg.format(compiler_module, versions)) - for v in versions: - try: - current_module = compiler_module + "/" + v - out = module("show", current_module) - match = extract_path_re.search(out) - search_paths += match.group(1).split(":") - except Exception as e: - msg = ( - "[CRAY FE] An unexpected error occurred while " - "detecting FE compiler [compiler={0}, " - " version={1}, error={2}]" - ) - tty.debug(msg.format(compiler_cls.name, v, str(e))) - - search_paths = list(llnl.util.lang.dedupe(search_paths)) - return fs.search_paths_for_executables(*search_paths) diff --git a/lib/spack/spack/operating_systems/mac_os.py b/lib/spack/spack/operating_systems/mac_os.py index 799f183d11f391..7b41ee7a13ef70 100644 --- a/lib/spack/spack/operating_systems/mac_os.py +++ b/lib/spack/spack/operating_systems/mac_os.py @@ -143,6 +143,7 @@ def __init__(self): "12": "monterey", "13": "ventura", "14": "sonoma", + "15": "sequoia", } version = macos_version() diff --git a/lib/spack/spack/operating_systems/windows_os.py b/lib/spack/spack/operating_systems/windows_os.py index 6ce25bb8de4c8e..3d3d44175f5e11 100755 --- a/lib/spack/spack/operating_systems/windows_os.py +++ b/lib/spack/spack/operating_systems/windows_os.py @@ -73,17 +73,24 @@ def vs_install_paths(self): def msvc_paths(self): return [os.path.join(path, "VC", "Tools", "MSVC") for path in self.vs_install_paths] + @property + def oneapi_root(self): + root = os.environ.get("ONEAPI_ROOT", "") or os.path.join( + os.environ.get("ProgramFiles(x86)", ""), "Intel", "oneAPI" + ) + if os.path.exists(root): + return root + @property def compiler_search_paths(self): # First Strategy: Find MSVC directories using vswhere _compiler_search_paths = [] for p in self.msvc_paths: _compiler_search_paths.extend(glob.glob(os.path.join(p, "*", "bin", "Hostx64", "x64"))) - if os.getenv("ONEAPI_ROOT"): + oneapi_root = self.oneapi_root + if oneapi_root: _compiler_search_paths.extend( - glob.glob( - os.path.join(str(os.getenv("ONEAPI_ROOT")), "compiler", "*", "windows", "bin") - ) + glob.glob(os.path.join(oneapi_root, "compiler", "**", "bin"), recursive=True) ) # Second strategy: Find MSVC via the registry diff --git a/lib/spack/spack/package.py b/lib/spack/spack/package.py index ac56cf1e1ae0f7..d0b7beda1d6d49 100644 --- a/lib/spack/spack/package.py +++ b/lib/spack/spack/package.py @@ -39,6 +39,7 @@ ) from spack.build_systems.cargo import CargoPackage from spack.build_systems.cmake import CMakePackage, generator +from spack.build_systems.compiler import CompilerPackage from spack.build_systems.cuda import CudaPackage from spack.build_systems.generic import Package from spack.build_systems.gnu import GNUMirrorPackage diff --git a/lib/spack/spack/package_base.py b/lib/spack/spack/package_base.py index 2f8e0ae003756e..6f2d4406bca3e0 100644 --- a/lib/spack/spack/package_base.py +++ b/lib/spack/spack/package_base.py @@ -35,6 +35,7 @@ import spack.compilers import spack.config +import spack.dependency import spack.deptypes as dt import spack.directives import spack.directory_layout @@ -161,7 +162,11 @@ def windows_establish_runtime_linkage(self): Performs symlinking to incorporate rpath dependencies to Windows runtime search paths """ - if sys.platform == "win32": + # If spec is an external, we should not be modifying its bin directory, as we would + # be doing in this method + # Spack should in general not modify things it has not installed + # we can reasonably expect externals to have their link interface properly established + if sys.platform == "win32" and not self.spec.external: self.win_rpath.add_library_dependent(*self.win_add_library_dependent()) self.win_rpath.add_rpath(*self.win_add_rpath()) self.win_rpath.establish_link() @@ -195,10 +200,10 @@ def __init__(cls, name, bases, attr_dict): # assumed to be detectable if hasattr(cls, "executables") or hasattr(cls, "libraries"): # Append a tag to each detectable package, so that finding them is faster - if hasattr(cls, "tags"): - getattr(cls, "tags").append(DetectablePackageMeta.TAG) - else: + if not hasattr(cls, "tags"): setattr(cls, "tags", [DetectablePackageMeta.TAG]) + elif DetectablePackageMeta.TAG not in cls.tags: + cls.tags.append(DetectablePackageMeta.TAG) @classmethod def platform_executables(cls): @@ -468,7 +473,41 @@ def _names(when_indexed_dictionary): return sorted(all_names) -class PackageBase(WindowsRPath, PackageViewMixin, metaclass=PackageMeta): +class RedistributionMixin: + """Logic for determining whether a Package is source/binary + redistributable. + """ + + #: Store whether a given Spec source/binary should not be + #: redistributed. + disable_redistribute: Dict["spack.spec.Spec", "spack.directives.DisableRedistribute"] + + # Source redistribution must be determined before concretization + # (because source mirrors work with un-concretized Specs). + @classmethod + def redistribute_source(cls, spec): + """Whether it should be possible to add the source of this + package to a Spack mirror. + """ + for when_spec, disable_redistribute in cls.disable_redistribute.items(): + if disable_redistribute.source and spec.satisfies(when_spec): + return False + + return True + + @property + def redistribute_binary(self): + """Whether it should be possible to create a binary out of an + installed instance of this package. + """ + for when_spec, disable_redistribute in self.__class__.disable_redistribute.items(): + if disable_redistribute.binary and self.spec.satisfies(when_spec): + return False + + return True + + +class PackageBase(WindowsRPath, PackageViewMixin, RedistributionMixin, metaclass=PackageMeta): """This is the superclass for all spack packages. ***The Package class*** @@ -567,6 +606,7 @@ class PackageBase(WindowsRPath, PackageViewMixin, metaclass=PackageMeta): provided_together: Dict["spack.spec.Spec", List[Set[str]]] patches: Dict["spack.spec.Spec", List["spack.patch.Patch"]] variants: Dict[str, Tuple["spack.variant.Variant", "spack.spec.Spec"]] + languages: Dict["spack.spec.Spec", Set[str]] #: By default, packages are not virtual #: Virtual packages override this attribute @@ -582,10 +622,6 @@ class PackageBase(WindowsRPath, PackageViewMixin, metaclass=PackageMeta): #: By default do not run tests within package's install() run_tests = False - #: Keep -Werror flags, matches config:flags:keep_werror to override config - # NOTE: should be type Optional[Literal['all', 'specific', 'none']] in 3.8+ - keep_werror: Optional[str] = None - #: Most packages are NOT extendable. Set to True if you want extensions. extendable = False @@ -713,11 +749,6 @@ def __init__(self, spec): self._fetch_time = 0.0 self.win_rpath = fsys.WindowsSimulatedRPath(self) - - if self.is_extension: - pkg_cls = spack.repo.PATH.get_pkg_class(self.extendee_spec.name) - pkg_cls(self.extendee_spec)._check_extendable() - super().__init__() @classmethod @@ -891,6 +922,32 @@ def global_license_file(self): self.global_license_dir, self.name, os.path.basename(self.license_files[0]) ) + # NOTE: return type should be Optional[Literal['all', 'specific', 'none']] in + # Python 3.8+, but we still support 3.6. + @property + def keep_werror(self) -> Optional[str]: + """Keep ``-Werror`` flags, matches ``config:flags:keep_werror`` to override config. + + Valid return values are: + * ``"all"``: keep all ``-Werror`` flags. + * ``"specific"``: keep only ``-Werror=specific-warning`` flags. + * ``"none"``: filter out all ``-Werror*`` flags. + * ``None``: respect the user's configuration (``"none"`` by default). + """ + if self.spec.satisfies("%nvhpc@:23.3") or self.spec.satisfies("%pgi"): + # Filtering works by replacing -Werror with -Wno-error, but older nvhpc and + # PGI do not understand -Wno-error, so we disable filtering. + return "all" + + elif self.spec.satisfies("%nvhpc@23.4:"): + # newer nvhpc supports -Wno-error but can't disable specific warnings with + # -Wno-error=warning. Skip -Werror=warning, but still filter -Werror. + return "specific" + + else: + # use -Werror disablement by default for other compilers + return None + @property def version(self): if not self.spec.versions.concrete: @@ -1080,10 +1137,9 @@ def _make_stage(self): if not link_format: link_format = "build-{arch}-{hash:7}" stage_link = self.spec.format_path(link_format) - return DevelopStage(compute_stage_name(self.spec), dev_path, stage_link) - - # To fetch the current version - source_stage = self._make_root_stage(self.fetcher) + source_stage = DevelopStage(compute_stage_name(self.spec), dev_path, stage_link) + else: + source_stage = self._make_root_stage(self.fetcher) # all_stages is source + resources + patches all_stages = StageComposite() @@ -1205,7 +1261,7 @@ def install_test_root(self): """Return the install test root directory.""" tty.warn( "The 'pkg.install_test_root' property is deprecated with removal " - "expected v0.22. Use 'install_test_root(pkg)' instead." + "expected v0.23. Use 'install_test_root(pkg)' instead." ) return install_test_root(self) @@ -1412,10 +1468,8 @@ def do_fetch(self, mirror_only=False): return checksum = spack.config.get("config:checksum") - fetch = self.stage.needs_fetching if ( checksum - and fetch and (self.version not in self.versions) and (not isinstance(self.version, GitVersion)) ): @@ -1522,13 +1576,11 @@ def do_patch(self): tty.debug("Patching failed last time. Restaging.") self.stage.restage() else: - # develop specs/ DIYStages may have patch failures but - # should never be restaged - msg = ( - "A patch failure was detected in %s." % self.name - + " Build errors may occur due to this." + # develop specs may have patch failures but should never be restaged + tty.warn( + f"A patch failure was detected in {self.name}." + " Build errors may occur due to this." ) - tty.warn(msg) return # If this file exists, then we already applied all the patches. @@ -1842,7 +1894,10 @@ def do_install(self, **kwargs): verbose (bool): Display verbose build output (by default, suppresses it) """ - PackageInstaller([(self, kwargs)]).install() + explicit = kwargs.get("explicit", True) + if isinstance(explicit, bool): + kwargs["explicit"] = {self.spec.dag_hash()} if explicit else set() + PackageInstaller([self], kwargs).install() # TODO (post-34236): Update tests and all packages that use this as a # TODO (post-34236): package method to the routine made available to @@ -1863,7 +1918,7 @@ def cache_extra_test_sources(self, srcs): """ msg = ( "'pkg.cache_extra_test_sources(srcs) is deprecated with removal " - "expected in v0.22. Use 'cache_extra_test_sources(pkg, srcs)' " + "expected in v0.23. Use 'cache_extra_test_sources(pkg, srcs)' " "instead." ) warnings.warn(msg) @@ -2329,10 +2384,6 @@ def do_deprecate(self, deprecator, link_fn): PackageBase.uninstall_by_spec(spec, force=True, deprecator=deprecator) link_fn(deprecator.prefix, spec.prefix) - def _check_extendable(self): - if not self.extendable: - raise ValueError("Package %s is not extendable!" % self.name) - def view(self): """Create a view with the prefix of this package as the root. Extensions added to this view will modify the installation prefix of @@ -2411,9 +2462,18 @@ def rpath(self): # on Windows, libraries of runtime interest are typically # stored in the bin directory + # Do not include Windows system libraries in the rpath interface + # these libraries are handled automatically by VS/VCVARS and adding + # Spack derived system libs into the link path or address space of a program + # can result in conflicting versions, which makes Spack packages less useable if sys.platform == "win32": rpaths = [self.prefix.bin] - rpaths.extend(d.prefix.bin for d in deps if os.path.isdir(d.prefix.bin)) + rpaths.extend( + d.prefix.bin + for d in deps + if os.path.isdir(d.prefix.bin) + and "windows-system" not in getattr(d.package, "tags", []) + ) else: rpaths = [self.prefix.lib, self.prefix.lib64] rpaths.extend(d.prefix.lib for d in deps if os.path.isdir(d.prefix.lib)) @@ -2520,7 +2580,12 @@ class PackageStillNeededError(InstallError): """Raised when package is still needed by another on uninstall.""" def __init__(self, spec, dependents): - super().__init__("Cannot uninstall %s" % spec) + spec_fmt = spack.spec.DEFAULT_FORMAT + " /{hash:7}" + dep_fmt = "{name}{@versions} /{hash:7}" + super().__init__( + f"Cannot uninstall {spec.format(spec_fmt)}, " + f"needed by {[dep.format(dep_fmt) for dep in dependents]}" + ) self.spec = spec self.dependents = dependents diff --git a/lib/spack/spack/patch.py b/lib/spack/spack/patch.py index 531445b4f95701..795a274243aae1 100644 --- a/lib/spack/spack/patch.py +++ b/lib/spack/spack/patch.py @@ -9,7 +9,7 @@ import os.path import pathlib import sys -from typing import Any, Dict, Optional, Tuple, Type +from typing import Any, Dict, Optional, Tuple, Type, Union import llnl.util.filesystem from llnl.url import allowed_archive @@ -65,6 +65,9 @@ def apply_patch( patch(*args) +PatchPackageType = Union["spack.package_base.PackageBase", Type["spack.package_base.PackageBase"]] + + class Patch: """Base class for patches. @@ -77,7 +80,7 @@ class Patch: def __init__( self, - pkg: "spack.package_base.PackageBase", + pkg: PatchPackageType, path_or_url: str, level: int, working_dir: str, @@ -159,7 +162,7 @@ class FilePatch(Patch): def __init__( self, - pkg: "spack.package_base.PackageBase", + pkg: PatchPackageType, relative_path: str, level: int, working_dir: str, @@ -183,7 +186,7 @@ def __init__( abs_path: Optional[str] = None # At different times we call FilePatch on instances and classes pkg_cls = pkg if inspect.isclass(pkg) else pkg.__class__ - for cls in inspect.getmro(pkg_cls): + for cls in inspect.getmro(pkg_cls): # type: ignore if not hasattr(cls, "module"): # We've gone too far up the MRO break @@ -242,7 +245,7 @@ class UrlPatch(Patch): def __init__( self, - pkg: "spack.package_base.PackageBase", + pkg: PatchPackageType, url: str, level: int = 1, *, @@ -361,8 +364,9 @@ def from_dict( """ repository = repository or spack.repo.PATH owner = dictionary.get("owner") - if "owner" not in dictionary: - raise ValueError("Invalid patch dictionary: %s" % dictionary) + if owner is None: + raise ValueError(f"Invalid patch dictionary: {dictionary}") + assert isinstance(owner, str) pkg_cls = repository.get_pkg_class(owner) if "url" in dictionary: diff --git a/lib/spack/spack/platforms/__init__.py b/lib/spack/spack/platforms/__init__.py index 54d3e6eae52c63..87566bf87f334d 100644 --- a/lib/spack/spack/platforms/__init__.py +++ b/lib/spack/spack/platforms/__init__.py @@ -6,7 +6,6 @@ from ._functions import _host, by_name, platforms, prevent_cray_detection, reset from ._platform import Platform -from .cray import Cray from .darwin import Darwin from .freebsd import FreeBSD from .linux import Linux @@ -15,7 +14,6 @@ __all__ = [ "Platform", - "Cray", "Darwin", "Linux", "FreeBSD", diff --git a/lib/spack/spack/platforms/_functions.py b/lib/spack/spack/platforms/_functions.py index d04f2587b0cdea..92c8ee800e01bf 100644 --- a/lib/spack/spack/platforms/_functions.py +++ b/lib/spack/spack/platforms/_functions.py @@ -8,7 +8,6 @@ import spack.util.environment -from .cray import Cray from .darwin import Darwin from .freebsd import FreeBSD from .linux import Linux @@ -16,7 +15,7 @@ from .windows import Windows #: List of all the platform classes known to Spack -platforms = [Cray, Darwin, Linux, Windows, FreeBSD, Test] +platforms = [Darwin, Linux, Windows, FreeBSD, Test] @llnl.util.lang.memoized diff --git a/lib/spack/spack/platforms/cray.py b/lib/spack/spack/platforms/cray.py index 180af15435eaf6..8fc69ac12e1d20 100644 --- a/lib/spack/spack/platforms/cray.py +++ b/lib/spack/spack/platforms/cray.py @@ -2,248 +2,10 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import os import os.path -import platform -import re - -import archspec.cpu - -import llnl.util.tty as tty - -import spack.target -import spack.version -from spack.operating_systems.cray_backend import CrayBackend -from spack.operating_systems.cray_frontend import CrayFrontend -from spack.paths import build_env_path -from spack.util.executable import Executable -from spack.util.module_cmd import module - -from ._platform import NoPlatformError, Platform - -_craype_name_to_target_name = { - "x86-cascadelake": "cascadelake", - "x86-naples": "zen", - "x86-rome": "zen2", - "x86-milan": "zen3", - "x86-skylake": "skylake_avx512", - "mic-knl": "mic_knl", - "interlagos": "bulldozer", - "abudhabi": "piledriver", -} - -_ex_craype_dir = "/opt/cray/pe/cpe" -_xc_craype_dir = "/opt/cray/pe/cdt" def slingshot_network(): return os.path.exists("/opt/cray/pe") and ( os.path.exists("/lib64/libcxi.so") or os.path.exists("/usr/lib64/libcxi.so") ) - - -def _target_name_from_craype_target_name(name): - return _craype_name_to_target_name.get(name, name) - - -class Cray(Platform): - priority = 10 - - def __init__(self): - """Create a Cray system platform. - - Target names should use craype target names but not include the - 'craype-' prefix. Uses first viable target from: - self - envars [SPACK_FRONT_END, SPACK_BACK_END] - configuration file "targets.yaml" with keys 'front_end', 'back_end' - scanning /etc/bash/bashrc.local for back_end only - """ - super().__init__("cray") - - # Make all craype targets available. - for target in self._avail_targets(): - name = _target_name_from_craype_target_name(target) - self.add_target(name, spack.target.Target(name, "craype-%s" % target)) - - self.back_end = os.environ.get("SPACK_BACK_END", self._default_target_from_env()) - self.default = self.back_end - if self.back_end not in self.targets: - # We didn't find a target module for the backend - raise NoPlatformError() - - # Setup frontend targets - for name in archspec.cpu.TARGETS: - if name not in self.targets: - self.add_target(name, spack.target.Target(name)) - self.front_end = os.environ.get("SPACK_FRONT_END", archspec.cpu.host().name) - if self.front_end not in self.targets: - self.add_target(self.front_end, spack.target.Target(self.front_end)) - - front_distro = CrayFrontend() - back_distro = CrayBackend() - - self.default_os = str(back_distro) - self.back_os = self.default_os - self.front_os = str(front_distro) - - self.add_operating_system(self.back_os, back_distro) - if self.front_os != self.back_os: - self.add_operating_system(self.front_os, front_distro) - - def setup_platform_environment(self, pkg, env): - """Change the linker to default dynamic to be more - similar to linux/standard linker behavior - """ - # Unload these modules to prevent any silent linking or unnecessary - # I/O profiling in the case of darshan. - modules_to_unload = ["cray-mpich", "darshan", "cray-libsci", "altd"] - for mod in modules_to_unload: - module("unload", mod) - - env.set("CRAYPE_LINK_TYPE", "dynamic") - cray_wrapper_names = os.path.join(build_env_path, "cray") - - if os.path.isdir(cray_wrapper_names): - env.prepend_path("PATH", cray_wrapper_names) - env.prepend_path("SPACK_ENV_PATH", cray_wrapper_names) - - # Makes spack installed pkg-config work on Crays - env.append_path("PKG_CONFIG_PATH", "/usr/lib64/pkgconfig") - env.append_path("PKG_CONFIG_PATH", "/usr/local/lib64/pkgconfig") - - # CRAY_LD_LIBRARY_PATH is used at build time by the cray compiler - # wrappers to augment LD_LIBRARY_PATH. This is to avoid long load - # times at runtime. This behavior is not always respected on cray - # "cluster" systems, so we reproduce it here. - if os.environ.get("CRAY_LD_LIBRARY_PATH"): - env.prepend_path("LD_LIBRARY_PATH", os.environ["CRAY_LD_LIBRARY_PATH"]) - - @classmethod - def craype_type_and_version(cls): - if os.path.isdir(_ex_craype_dir): - craype_dir = _ex_craype_dir - craype_type = "EX" - elif os.path.isdir(_xc_craype_dir): - craype_dir = _xc_craype_dir - craype_type = "XC" - else: - return (None, None) - - # Take the default version from known symlink path - default_path = os.path.join(craype_dir, "default") - if os.path.islink(default_path): - version = spack.version.Version(os.readlink(default_path)) - return (craype_type, version) - - # If no default version, sort available versions and return latest - versions_available = [spack.version.Version(v) for v in os.listdir(craype_dir)] - versions_available.sort(reverse=True) - if not versions_available: - return (craype_type, None) - return (craype_type, versions_available[0]) - - @classmethod - def detect(cls): - """ - Detect whether this system requires CrayPE module support. - - Systems with newer CrayPE (21.10 for EX systems, future work for CS and - XC systems) have compilers and MPI wrappers that can be used directly - by path. These systems are considered ``linux`` platforms. - - For systems running an older CrayPE, we detect the Cray platform based - on the availability through `module` of the Cray programming - environment. If this environment is available, we can use it to find - compilers, target modules, etc. If the Cray programming environment is - not available via modules, then we will treat it as a standard linux - system, as the Cray compiler wrappers and other components of the Cray - programming environment are irrelevant without module support. - """ - craype_type, craype_version = cls.craype_type_and_version() - if craype_type == "EX" and craype_version >= spack.version.Version("21.10"): - return False - return "opt/cray" in os.environ.get("MODULEPATH", "") - - def _default_target_from_env(self): - """Set and return the default CrayPE target loaded in a clean login - session. - - A bash subshell is launched with a wiped environment and the list of - loaded modules is parsed for the first acceptable CrayPE target. - """ - # env -i /bin/bash -lc echo $CRAY_CPU_TARGET 2> /dev/null - if getattr(self, "default", None) is None: - bash = Executable("/bin/bash") - output = bash( - "--norc", - "--noprofile", - "-lc", - "echo $CRAY_CPU_TARGET", - env={"TERM": os.environ.get("TERM", "")}, - output=str, - error=os.devnull, - ) - - default_from_module = "".join(output.split()) # rm all whitespace - if default_from_module: - tty.debug("Found default module:%s" % default_from_module) - return default_from_module - else: - front_end = archspec.cpu.host() - # Look for the frontend architecture or closest ancestor - # available in cray target modules - avail = [_target_name_from_craype_target_name(x) for x in self._avail_targets()] - for front_end_possibility in [front_end] + front_end.ancestors: - if front_end_possibility.name in avail: - tty.debug("using front-end architecture or available ancestor") - return front_end_possibility.name - else: - tty.debug("using platform.machine as default") - return platform.machine() - - def _avail_targets(self): - """Return a list of available CrayPE CPU targets.""" - - def modules_in_output(output): - """Returns a list of valid modules parsed from modulecmd output""" - return [i for i in re.split(r"\s\s+|\n", output)] - - def target_names_from_modules(modules): - # Craype- module prefixes that are not valid CPU targets. - targets = [] - for mod in modules: - if "craype-" in mod: - name = mod[7:] - name = name.split()[0] - _n = name.replace("-", "_") # test for mic-knl/mic_knl - is_target_name = name in archspec.cpu.TARGETS or _n in archspec.cpu.TARGETS - is_cray_target_name = name in _craype_name_to_target_name - if is_target_name or is_cray_target_name: - targets.append(name) - - return targets - - def modules_from_listdir(): - craype_default_path = "/opt/cray/pe/craype/default/modulefiles" - if os.path.isdir(craype_default_path): - return os.listdir(craype_default_path) - return [] - - if getattr(self, "_craype_targets", None) is None: - strategies = [ - lambda: modules_in_output(module("avail", "-t", "craype-")), - modules_from_listdir, - ] - for available_craype_modules in strategies: - craype_modules = available_craype_modules() - craype_targets = target_names_from_modules(craype_modules) - if craype_targets: - self._craype_targets = craype_targets - break - else: - # If nothing is found add platform.machine() - # to avoid Spack erroring out - self._craype_targets = [platform.machine()] - - return self._craype_targets diff --git a/lib/spack/spack/relocate.py b/lib/spack/spack/relocate.py index 0bbbba7ef0facd..357dd92f8499bd 100644 --- a/lib/spack/spack/relocate.py +++ b/lib/spack/spack/relocate.py @@ -16,7 +16,7 @@ import llnl.util.lang import llnl.util.tty as tty from llnl.util.lang import memoized -from llnl.util.symlink import symlink +from llnl.util.symlink import readlink, symlink import spack.paths import spack.platforms @@ -25,6 +25,7 @@ import spack.store import spack.util.elf as elf import spack.util.executable as executable +import spack.util.path from .relocate_text import BinaryFilePrefixReplacer, TextFilePrefixReplacer @@ -565,7 +566,7 @@ def make_link_relative(new_links, orig_links): orig_links (list): original links """ for new_link, orig_link in zip(new_links, orig_links): - target = os.readlink(orig_link) + target = readlink(orig_link) relative_target = os.path.relpath(target, os.path.dirname(orig_link)) os.unlink(new_link) symlink(relative_target, new_link) @@ -613,7 +614,7 @@ def relocate_links(links, prefix_to_prefix): """Relocate links to a new install prefix.""" regex = re.compile("|".join(re.escape(p) for p in prefix_to_prefix.keys())) for link in links: - old_target = os.readlink(link) + old_target = readlink(link) match = regex.match(old_target) # No match. diff --git a/lib/spack/spack/repo.py b/lib/spack/spack/repo.py index b5f7640bafc591..4f42ead467be20 100644 --- a/lib/spack/spack/repo.py +++ b/lib/spack/spack/repo.py @@ -25,7 +25,8 @@ import traceback import types import uuid -from typing import Any, Dict, List, Set, Tuple, Union +import warnings +from typing import Any, Dict, Generator, List, Optional, Set, Tuple, Type, Union import llnl.path import llnl.util.filesystem as fs @@ -126,11 +127,35 @@ def exec_module(self, module): class ReposFinder: - """MetaPathFinder class that loads a Python module corresponding to a Spack package + """MetaPathFinder class that loads a Python module corresponding to a Spack package. - Return a loader based on the inspection of the current global repository list. + Returns a loader based on the inspection of the current repository list. """ + def __init__(self): + self._repo_init = _path + self._repo = None + + @property + def current_repository(self): + if self._repo is None: + self._repo = self._repo_init() + return self._repo + + @current_repository.setter + def current_repository(self, value): + self._repo = value + + @contextlib.contextmanager + def switch_repo(self, substitute: "RepoType"): + """Switch the current repository list for the duration of the context manager.""" + old = self.current_repository + try: + self.current_repository = substitute + yield + finally: + self.current_repository = old + def find_spec(self, fullname, python_path, target=None): # "target" is not None only when calling importlib.reload() if target is not None: @@ -149,9 +174,14 @@ def compute_loader(self, fullname): # namespaces are added to repo, and package modules are leaves. namespace, dot, module_name = fullname.rpartition(".") - # If it's a module in some repo, or if it is the repo's - # namespace, let the repo handle it. - for repo in PATH.repos: + # If it's a module in some repo, or if it is the repo's namespace, let the repo handle it. + is_repo_path = isinstance(self.current_repository, RepoPath) + if is_repo_path: + repos = self.current_repository.repos + else: + repos = [self.current_repository] + + for repo in repos: # We are using the namespace of the repo and the repo contains the package if namespace == repo.full_namespace: # With 2 nested conditionals we can call "repo.real_name" only once @@ -165,7 +195,7 @@ def compute_loader(self, fullname): # No repo provides the namespace, but it is a valid prefix of # something in the RepoPath. - if PATH.by_namespace.is_prefix(fullname): + if is_repo_path and self.current_repository.by_namespace.is_prefix(fullname): return SpackNamespaceLoader() return None @@ -241,7 +271,7 @@ def get_all_package_diffs(type, rev1="HEAD^1", rev2="HEAD"): Arguments: - type (str): String containing one or more of 'A', 'B', 'C' + type (str): String containing one or more of 'A', 'R', 'C' rev1 (str): Revision to compare against, default is 'HEAD^' rev2 (str): Revision to compare to rev1, default is 'HEAD' @@ -264,7 +294,7 @@ def get_all_package_diffs(type, rev1="HEAD^1", rev2="HEAD"): lines = [] if not out else re.split(r"\s+", out) changed = set() for path in lines: - pkg_name, _, _ = path.partition(os.sep) + pkg_name, _, _ = path.partition("/") if pkg_name not in added and pkg_name not in removed: changed.add(pkg_name) @@ -560,7 +590,7 @@ def __init__( self, package_checker: FastPackageChecker, namespace: str, - cache: spack.util.file_cache.FileCache, + cache: "spack.caches.FileCacheType", ): self.checker = package_checker self.packages_path = self.checker.packages_path @@ -645,33 +675,39 @@ class RepoPath: repository. Args: - repos (list): list Repo objects or paths to put in this RepoPath + repos: list Repo objects or paths to put in this RepoPath + cache: file cache associated with this repository + overrides: dict mapping package name to class attribute overrides for that package """ - def __init__(self, *repos, **kwargs): - cache = kwargs.get("cache", spack.caches.MISC_CACHE) - self.repos = [] + def __init__( + self, + *repos: Union[str, "Repo"], + cache: "spack.caches.FileCacheType", + overrides: Optional[Dict[str, Any]] = None, + ) -> None: + self.repos: List[Repo] = [] self.by_namespace = nm.NamespaceTrie() - - self._provider_index = None - self._patch_index = None - self._tag_index = None + self._provider_index: Optional[spack.provider_index.ProviderIndex] = None + self._patch_index: Optional[spack.patch.PatchCache] = None + self._tag_index: Optional[spack.tag.TagIndex] = None # Add each repo to this path. for repo in repos: try: if isinstance(repo, str): - repo = Repo(repo, cache=cache) + repo = Repo(repo, cache=cache, overrides=overrides) + repo.finder(self) self.put_last(repo) except RepoError as e: tty.warn( - "Failed to initialize repository: '%s'." % repo, + f"Failed to initialize repository: '{repo}'.", e.message, "To remove the bad repository, run this command:", - " spack repo rm %s" % repo, + f" spack repo rm {repo}", ) - def put_first(self, repo): + def put_first(self, repo: "Repo") -> None: """Add repo first in the search path.""" if isinstance(repo, RepoPath): for r in reversed(repo.repos): @@ -699,50 +735,34 @@ def remove(self, repo): if repo in self.repos: self.repos.remove(repo) - def get_repo(self, namespace, default=NOT_PROVIDED): - """Get a repository by namespace. - - Arguments: - - namespace: - - Look up this namespace in the RepoPath, and return it if found. - - Optional Arguments: - - default: - - If default is provided, return it when the namespace - isn't found. If not, raise an UnknownNamespaceError. - """ + def get_repo(self, namespace: str) -> "Repo": + """Get a repository by namespace.""" full_namespace = python_package_for_repo(namespace) if full_namespace not in self.by_namespace: - if default == NOT_PROVIDED: - raise UnknownNamespaceError(namespace) - return default + raise UnknownNamespaceError(namespace) return self.by_namespace[full_namespace] - def first_repo(self): + def first_repo(self) -> Optional["Repo"]: """Get the first repo in precedence order.""" return self.repos[0] if self.repos else None @llnl.util.lang.memoized - def _all_package_names(self, include_virtuals): + def _all_package_names_set(self, include_virtuals) -> Set[str]: + return {name for repo in self.repos for name in repo.all_package_names(include_virtuals)} + + @llnl.util.lang.memoized + def _all_package_names(self, include_virtuals: bool) -> List[str]: """Return all unique package names in all repositories.""" - all_pkgs = set() - for repo in self.repos: - for name in repo.all_package_names(include_virtuals): - all_pkgs.add(name) - return sorted(all_pkgs, key=lambda n: n.lower()) + return sorted(self._all_package_names_set(include_virtuals), key=lambda n: n.lower()) - def all_package_names(self, include_virtuals=False): + def all_package_names(self, include_virtuals: bool = False) -> List[str]: return self._all_package_names(include_virtuals) - def package_path(self, name): + def package_path(self, name: str) -> str: """Get path to package.py file for this repo.""" return self.repo_for_pkg(name).package_path(name) - def all_package_paths(self): + def all_package_paths(self) -> Generator[str, None, None]: for name in self.all_package_names(): yield self.package_path(name) @@ -758,49 +778,52 @@ def packages_with_tags(self, *tags: str, full: bool = False) -> Set[str]: for pkg in repo.packages_with_tags(*tags) } - def all_package_classes(self): + def all_package_classes(self) -> Generator[Type["spack.package_base.PackageBase"], None, None]: for name in self.all_package_names(): yield self.get_pkg_class(name) @property - def provider_index(self): + def provider_index(self) -> spack.provider_index.ProviderIndex: """Merged ProviderIndex from all Repos in the RepoPath.""" if self._provider_index is None: self._provider_index = spack.provider_index.ProviderIndex(repository=self) for repo in reversed(self.repos): self._provider_index.merge(repo.provider_index) - return self._provider_index @property - def tag_index(self): + def tag_index(self) -> spack.tag.TagIndex: """Merged TagIndex from all Repos in the RepoPath.""" if self._tag_index is None: self._tag_index = spack.tag.TagIndex(repository=self) for repo in reversed(self.repos): self._tag_index.merge(repo.tag_index) - return self._tag_index @property - def patch_index(self): + def patch_index(self) -> spack.patch.PatchCache: """Merged PatchIndex from all Repos in the RepoPath.""" if self._patch_index is None: self._patch_index = spack.patch.PatchCache(repository=self) for repo in reversed(self.repos): self._patch_index.update(repo.patch_index) - return self._patch_index @autospec - def providers_for(self, vpkg_spec): - providers = self.provider_index.providers_for(vpkg_spec) + def providers_for(self, virtual_spec: "spack.spec.Spec") -> List["spack.spec.Spec"]: + providers = [ + spec + for spec in self.provider_index.providers_for(virtual_spec) + if spec.name in self._all_package_names_set(include_virtuals=False) + ] if not providers: - raise UnknownPackageError(vpkg_spec.fullname) + raise UnknownPackageError(virtual_spec.fullname) return providers @autospec - def extensions_for(self, extendee_spec): + def extensions_for( + self, extendee_spec: "spack.spec.Spec" + ) -> List["spack.package_base.PackageBase"]: return [ pkg_cls(spack.spec.Spec(pkg_cls.name)) for pkg_cls in self.all_package_classes() @@ -811,7 +834,7 @@ def last_mtime(self): """Time a package file in this repo was last updated.""" return max(repo.last_mtime() for repo in self.repos) - def repo_for_pkg(self, spec): + def repo_for_pkg(self, spec: Union[str, "spack.spec.Spec"]) -> "Repo": """Given a spec, get the repository for its package.""" # We don't @_autospec this function b/c it's called very frequently # and we want to avoid parsing str's into Specs unnecessarily. @@ -836,17 +859,20 @@ def repo_for_pkg(self, spec): return repo # If the package isn't in any repo, return the one with - # highest precedence. This is for commands like `spack edit` + # highest precedence. This is for commands like `spack edit` # that can operate on packages that don't exist yet. - return self.first_repo() + selected = self.first_repo() + if selected is None: + raise UnknownPackageError(name) + return selected - def get(self, spec): + def get(self, spec: "spack.spec.Spec") -> "spack.package_base.PackageBase": """Returns the package associated with the supplied spec.""" msg = "RepoPath.get can only be called on concrete specs" assert isinstance(spec, spack.spec.Spec) and spec.concrete, msg return self.repo_for_pkg(spec).get(spec) - def get_pkg_class(self, pkg_name): + def get_pkg_class(self, pkg_name: str) -> Type["spack.package_base.PackageBase"]: """Find a class for the spec's package and return the class object.""" return self.repo_for_pkg(pkg_name).get_pkg_class(pkg_name) @@ -859,26 +885,26 @@ def dump_provenance(self, spec, path): """ return self.repo_for_pkg(spec).dump_provenance(spec, path) - def dirname_for_package_name(self, pkg_name): + def dirname_for_package_name(self, pkg_name: str) -> str: return self.repo_for_pkg(pkg_name).dirname_for_package_name(pkg_name) - def filename_for_package_name(self, pkg_name): + def filename_for_package_name(self, pkg_name: str) -> str: return self.repo_for_pkg(pkg_name).filename_for_package_name(pkg_name) - def exists(self, pkg_name): + def exists(self, pkg_name: str) -> bool: """Whether package with the give name exists in the path's repos. Note that virtual packages do not "exist". """ return any(repo.exists(pkg_name) for repo in self.repos) - def _have_name(self, pkg_name): + def _have_name(self, pkg_name: str) -> bool: have_name = pkg_name is not None if have_name and not isinstance(pkg_name, str): - raise ValueError("is_virtual(): expected package name, got %s" % type(pkg_name)) + raise ValueError(f"is_virtual(): expected package name, got {type(pkg_name)}") return have_name - def is_virtual(self, pkg_name): + def is_virtual(self, pkg_name: str) -> bool: """Return True if the package with this name is virtual, False otherwise. This function use the provider index. If calling from a code block that @@ -890,7 +916,7 @@ def is_virtual(self, pkg_name): have_name = self._have_name(pkg_name) return have_name and pkg_name in self.provider_index - def is_virtual_safe(self, pkg_name): + def is_virtual_safe(self, pkg_name: str) -> bool: """Return True if the package with this name is virtual, False otherwise. This function doesn't use the provider index. @@ -911,18 +937,28 @@ class Repo: Each package repository must have a top-level configuration file called `repo.yaml`. - Currently, `repo.yaml` this must define: + Currently, `repo.yaml` must define: `namespace`: A Python namespace where the repository's packages should live. + `subdirectory`: + An optional subdirectory name where packages are placed """ - def __init__(self, root, cache=None): + def __init__( + self, + root: str, + *, + cache: "spack.caches.FileCacheType", + overrides: Optional[Dict[str, Any]] = None, + ) -> None: """Instantiate a package repository from a filesystem path. Args: root: the root directory of the repository + cache: file cache associated with this repository + overrides: dict mapping package name to class attribute overrides for that package """ # Root directory, containing _repo.yaml and package dirs # Allow roots to by spack-relative by starting with '$spack' @@ -935,20 +971,20 @@ def check(condition, msg): # Validate repository layout. self.config_file = os.path.join(self.root, repo_config_name) - check(os.path.isfile(self.config_file), "No %s found in '%s'" % (repo_config_name, root)) + check(os.path.isfile(self.config_file), f"No {repo_config_name} found in '{root}'") # Read configuration and validate namespace config = self._read_config() check( "namespace" in config, - "%s must define a namespace." % os.path.join(root, repo_config_name), + f"{os.path.join(root, repo_config_name)} must define a namespace.", ) self.namespace = config["namespace"] check( re.match(r"[a-zA-Z][a-zA-Z0-9_.]+", self.namespace), - ("Invalid namespace '%s' in repo '%s'. " % (self.namespace, self.root)) - + "Namespaces must be valid python identifiers separated by '.'", + f"Invalid namespace '{self.namespace}' in repo '{self.root}'. " + "Namespaces must be valid python identifiers separated by '.'", ) # Set up 'full_namespace' to include the super-namespace @@ -960,23 +996,26 @@ def check(condition, msg): packages_dir = config.get("subdirectory", packages_dir_name) self.packages_path = os.path.join(self.root, packages_dir) check( - os.path.isdir(self.packages_path), - "No directory '%s' found in '%s'" % (packages_dir, root), + os.path.isdir(self.packages_path), f"No directory '{packages_dir}' found in '{root}'" ) - # These are internal cache variables. - self._modules = {} - self._classes = {} - self._instances = {} + # Class attribute overrides by package name + self.overrides = overrides or {} + + # Optional reference to a RepoPath to influence module import from spack.pkg + self._finder: Optional[RepoPath] = None # Maps that goes from package name to corresponding file stat - self._fast_package_checker = None + self._fast_package_checker: Optional[FastPackageChecker] = None # Indexes for this repository, computed lazily - self._repo_index = None - self._cache = cache or spack.caches.MISC_CACHE + self._repo_index: Optional[RepoIndex] = None + self._cache = cache - def real_name(self, import_name): + def finder(self, value: RepoPath) -> None: + self._finder = value + + def real_name(self, import_name: str) -> Optional[str]: """Allow users to import Spack packages using Python identifiers. A python identifier might map to many different Spack package @@ -995,18 +1034,21 @@ def real_name(self, import_name): return import_name options = nm.possible_spack_module_names(import_name) - options.remove(import_name) + try: + options.remove(import_name) + except ValueError: + pass for name in options: if name in self: return name return None - def is_prefix(self, fullname): + def is_prefix(self, fullname: str) -> bool: """True if fullname is a prefix of this Repo's namespace.""" parts = fullname.split(".") return self._names[: len(parts)] == parts - def _read_config(self): + def _read_config(self) -> Dict[str, str]: """Check for a YAML config file in this db's root directory.""" try: with open(self.config_file) as reponame_file: @@ -1017,14 +1059,14 @@ def _read_config(self): or "repo" not in yaml_data or not isinstance(yaml_data["repo"], dict) ): - tty.die("Invalid %s in repository %s" % (repo_config_name, self.root)) + tty.die(f"Invalid {repo_config_name} in repository {self.root}") return yaml_data["repo"] except IOError: - tty.die("Error reading %s when opening %s" % (self.config_file, self.root)) + tty.die(f"Error reading {self.config_file} when opening {self.root}") - def get(self, spec): + def get(self, spec: "spack.spec.Spec") -> "spack.package_base.PackageBase": """Returns the package associated with the supplied spec.""" msg = "Repo.get can only be called on concrete specs" assert isinstance(spec, spack.spec.Spec) and spec.concrete, msg @@ -1045,16 +1087,13 @@ def get(self, spec): # pass these through as their error messages will be fine. raise except Exception as e: - tty.debug(e) - # Make sure other errors in constructors hit the error # handler by wrapping them - if spack.config.get("config:debug"): - sys.excepthook(*sys.exc_info()) - raise FailedConstructorError(spec.fullname, *sys.exc_info()) + tty.debug(e) + raise FailedConstructorError(spec.fullname, *sys.exc_info()) from e @autospec - def dump_provenance(self, spec, path): + def dump_provenance(self, spec: "spack.spec.Spec", path: str) -> None: """Dump provenance information for a spec to a particular path. This dumps the package file and any associated patch files. @@ -1062,7 +1101,7 @@ def dump_provenance(self, spec, path): """ if spec.namespace and spec.namespace != self.namespace: raise UnknownPackageError( - "Repository %s does not contain package %s." % (self.namespace, spec.fullname) + f"Repository {self.namespace} does not contain package {spec.fullname}." ) package_path = self.filename_for_package_name(spec.name) @@ -1079,17 +1118,13 @@ def dump_provenance(self, spec, path): if os.path.exists(patch.path): fs.install(patch.path, path) else: - tty.warn("Patch file did not exist: %s" % patch.path) + warnings.warn(f"Patch file did not exist: {patch.path}") # Install the package.py file itself. fs.install(self.filename_for_package_name(spec.name), path) - def purge(self): - """Clear entire package instance cache.""" - self._instances.clear() - @property - def index(self): + def index(self) -> RepoIndex: """Construct the index for this repo lazily.""" if self._repo_index is None: self._repo_index = RepoIndex(self._pkg_checker, self.namespace, cache=self._cache) @@ -1099,42 +1134,40 @@ def index(self): return self._repo_index @property - def provider_index(self): + def provider_index(self) -> spack.provider_index.ProviderIndex: """A provider index with names *specific* to this repo.""" return self.index["providers"] @property - def tag_index(self): + def tag_index(self) -> spack.tag.TagIndex: """Index of tags and which packages they're defined on.""" return self.index["tags"] @property - def patch_index(self): + def patch_index(self) -> spack.patch.PatchCache: """Index of patches and packages they're defined on.""" return self.index["patches"] @autospec - def providers_for(self, vpkg_spec): + def providers_for(self, vpkg_spec: "spack.spec.Spec") -> List["spack.spec.Spec"]: providers = self.provider_index.providers_for(vpkg_spec) if not providers: raise UnknownPackageError(vpkg_spec.fullname) return providers @autospec - def extensions_for(self, extendee_spec): - return [ - pkg_cls(spack.spec.Spec(pkg_cls.name)) - for pkg_cls in self.all_package_classes() - if pkg_cls(spack.spec.Spec(pkg_cls.name)).extends(extendee_spec) - ] - - def dirname_for_package_name(self, pkg_name): - """Get the directory name for a particular package. This is the - directory that contains its package.py file.""" + def extensions_for( + self, extendee_spec: "spack.spec.Spec" + ) -> List["spack.package_base.PackageBase"]: + result = [pkg_cls(spack.spec.Spec(pkg_cls.name)) for pkg_cls in self.all_package_classes()] + return [x for x in result if x.extends(extendee_spec)] + + def dirname_for_package_name(self, pkg_name: str) -> str: + """Given a package name, get the directory containing its package.py file.""" _, unqualified_name = self.partition_package_name(pkg_name) return os.path.join(self.packages_path, unqualified_name) - def filename_for_package_name(self, pkg_name): + def filename_for_package_name(self, pkg_name: str) -> str: """Get the filename for the module we should load for a particular package. Packages for a Repo live in ``$root//package.py`` @@ -1147,23 +1180,23 @@ def filename_for_package_name(self, pkg_name): return os.path.join(pkg_dir, package_file_name) @property - def _pkg_checker(self): + def _pkg_checker(self) -> FastPackageChecker: if self._fast_package_checker is None: self._fast_package_checker = FastPackageChecker(self.packages_path) return self._fast_package_checker - def all_package_names(self, include_virtuals=False): + def all_package_names(self, include_virtuals: bool = False) -> List[str]: """Returns a sorted list of all package names in the Repo.""" names = sorted(self._pkg_checker.keys()) if include_virtuals: return names return [x for x in names if not self.is_virtual(x)] - def package_path(self, name): + def package_path(self, name: str) -> str: """Get path to package.py file for this repo.""" return os.path.join(self.packages_path, name, package_file_name) - def all_package_paths(self): + def all_package_paths(self) -> Generator[str, None, None]: for name in self.all_package_names(): yield self.package_path(name) @@ -1172,7 +1205,7 @@ def packages_with_tags(self, *tags: str) -> Set[str]: v.intersection_update(*(self.tag_index[tag.lower()] for tag in tags)) return v - def all_package_classes(self): + def all_package_classes(self) -> Generator[Type["spack.package_base.PackageBase"], None, None]: """Iterator over all package *classes* in the repository. Use this with care, because loading packages is slow. @@ -1180,7 +1213,7 @@ def all_package_classes(self): for name in self.all_package_names(): yield self.get_pkg_class(name) - def exists(self, pkg_name): + def exists(self, pkg_name: str) -> bool: """Whether a package with the supplied name exists.""" if pkg_name is None: return False @@ -1197,28 +1230,22 @@ def last_mtime(self): """Time a package file in this repo was last updated.""" return self._pkg_checker.last_mtime() - def is_virtual(self, pkg_name): + def is_virtual(self, pkg_name: str) -> bool: """Return True if the package with this name is virtual, False otherwise. This function use the provider index. If calling from a code block that is used to construct the provider index use the ``is_virtual_safe`` function. - - Args: - pkg_name (str): name of the package we want to check """ return pkg_name in self.provider_index - def is_virtual_safe(self, pkg_name): + def is_virtual_safe(self, pkg_name: str) -> bool: """Return True if the package with this name is virtual, False otherwise. This function doesn't use the provider index. - - Args: - pkg_name (str): name of the package we want to check """ return not self.exists(pkg_name) or self.get_pkg_class(pkg_name).virtual - def get_pkg_class(self, pkg_name): + def get_pkg_class(self, pkg_name: str) -> Type["spack.package_base.PackageBase"]: """Get the class for the package out of its module. First loads (or fetches from cache) a module for the @@ -1230,7 +1257,8 @@ def get_pkg_class(self, pkg_name): fullname = f"{self.full_namespace}.{pkg_name}" try: - module = importlib.import_module(fullname) + with REPOS_FINDER.switch_repo(self._finder or self): + module = importlib.import_module(fullname) except ImportError: raise UnknownPackageError(fullname) except Exception as e: @@ -1241,26 +1269,21 @@ def get_pkg_class(self, pkg_name): if not inspect.isclass(cls): tty.die(f"{pkg_name}.{class_name} is not a class") - new_cfg_settings = ( - spack.config.get("packages").get(pkg_name, {}).get("package_attributes", {}) - ) - + # Clear any prior changes to class attributes in case the class was loaded from the + # same repo, but with different overrides overridden_attrs = getattr(cls, "overridden_attrs", {}) attrs_exclusively_from_config = getattr(cls, "attrs_exclusively_from_config", []) - # Clear any prior changes to class attributes in case the config has - # since changed for key, val in overridden_attrs.items(): setattr(cls, key, val) for key in attrs_exclusively_from_config: delattr(cls, key) - # Keep track of every class attribute that is overridden by the config: - # if the config changes between calls to this method, we make sure to - # restore the original config values (in case the new config no longer - # sets attributes that it used to) + # Keep track of every class attribute that is overridden: if different overrides + # dictionaries are used on the same physical repo, we make sure to restore the original + # config values new_overridden_attrs = {} new_attrs_exclusively_from_config = set() - for key, val in new_cfg_settings.items(): + for key, val in self.overrides.get(pkg_name, {}).items(): if hasattr(cls, key): new_overridden_attrs[key] = getattr(cls, key) else: @@ -1287,13 +1310,13 @@ def partition_package_name(self, pkg_name: str) -> Tuple[str, str]: return namespace, pkg_name - def __str__(self): - return "[Repo '%s' at '%s']" % (self.namespace, self.root) + def __str__(self) -> str: + return f"Repo '{self.namespace}' at {self.root}" - def __repr__(self): + def __repr__(self) -> str: return self.__str__() - def __contains__(self, pkg_name): + def __contains__(self, pkg_name: str) -> bool: return self.exists(pkg_name) @@ -1369,12 +1392,17 @@ def create_repo(root, namespace=None, subdir=packages_dir_name): return full_path, namespace +def from_path(path: str) -> "Repo": + """Returns a repository from the path passed as input. Injects the global misc cache.""" + return Repo(path, cache=spack.caches.MISC_CACHE) + + def create_or_construct(path, namespace=None): """Create a repository, or just return a Repo if it already exists.""" if not os.path.exists(path): fs.mkdirp(path) create_repo(path, namespace) - return Repo(path) + return from_path(path) def _path(configuration=None): @@ -1383,7 +1411,9 @@ def _path(configuration=None): return create(configuration=configuration) -def create(configuration): +def create( + configuration: Union["spack.config.Configuration", llnl.util.lang.Singleton] +) -> RepoPath: """Create a RepoPath from a configuration object. Args: @@ -1392,7 +1422,17 @@ def create(configuration): repo_dirs = configuration.get("repos") if not repo_dirs: raise NoRepoConfiguredError("Spack configuration contains no package repositories.") - return RepoPath(*repo_dirs) + + overrides = {} + for pkg_name, data in configuration.get("packages").items(): + if pkg_name == "all": + continue + value = data.get("package_attributes", {}) + if not value: + continue + overrides[pkg_name] = value + + return RepoPath(*repo_dirs, cache=spack.caches.MISC_CACHE, overrides=overrides) #: Singleton repo path instance @@ -1409,20 +1449,20 @@ def all_package_names(include_virtuals=False): @contextlib.contextmanager -def use_repositories(*paths_and_repos, **kwargs): +def use_repositories( + *paths_and_repos: Union[str, Repo], override: bool = True +) -> Generator[RepoPath, None, None]: """Use the repositories passed as arguments within the context manager. Args: *paths_and_repos: paths to the repositories to be used, or already constructed Repo objects - override (bool): if True use only the repositories passed as input, + override: if True use only the repositories passed as input, if False add them to the top of the list of current repositories. Returns: Corresponding RepoPath object """ global PATH - # TODO (Python 2.7): remove this kwargs on deprecation of Python 2.7 support - override = kwargs.get("override", True) paths = [getattr(x, "root", x) for x in paths_and_repos] scope_name = "use-repo-{}".format(uuid.uuid4()) repos_key = "repos:" if override else "repos" @@ -1431,7 +1471,8 @@ def use_repositories(*paths_and_repos, **kwargs): ) PATH, saved = create(configuration=spack.config.CONFIG), PATH try: - yield PATH + with REPOS_FINDER.switch_repo(PATH): # type: ignore + yield PATH finally: spack.config.CONFIG.remove_scope(scope_name=scope_name) PATH = saved @@ -1531,10 +1572,9 @@ class UnknownNamespaceError(UnknownEntityError): """Raised when we encounter an unknown namespace""" def __init__(self, namespace, name=None): - msg, long_msg = "Unknown namespace: {}".format(namespace), None + msg, long_msg = f"Unknown namespace: {namespace}", None if name == "yaml": - long_msg = "Did you mean to specify a filename with './{}.{}'?" - long_msg = long_msg.format(namespace, name) + long_msg = f"Did you mean to specify a filename with './{namespace}.{name}'?" super().__init__(msg, long_msg) diff --git a/lib/spack/spack/reporters/cdash.py b/lib/spack/spack/reporters/cdash.py index c65feb35d8ad4d..0c140a488d67b1 100644 --- a/lib/spack/spack/reporters/cdash.py +++ b/lib/spack/spack/reporters/cdash.py @@ -14,7 +14,7 @@ import xml.sax.saxutils from typing import Dict, Optional from urllib.parse import urlencode -from urllib.request import HTTPHandler, Request, build_opener +from urllib.request import HTTPSHandler, Request, build_opener import llnl.util.tty as tty from llnl.util.filesystem import working_dir @@ -27,6 +27,7 @@ from spack.error import SpackError from spack.util.crypto import checksum from spack.util.log_parse import parse_log_events +from spack.util.web import ssl_create_default_context from .base import Reporter from .extract import extract_test_parts @@ -57,7 +58,8 @@ # Initialize data structures common to each phase's report. CDASH_PHASES = set(MAP_PHASES_TO_CDASH.values()) CDASH_PHASES.add("update") - +# CDash request timeout in seconds +SPACK_CDASH_TIMEOUT = 45 CDashConfiguration = collections.namedtuple( "CDashConfiguration", ["upload_url", "packages", "build", "site", "buildstamp", "track"] @@ -427,7 +429,7 @@ def upload(self, filename): # Compute md5 checksum for the contents of this file. md5sum = checksum(hashlib.md5, filename, block_size=8192) - opener = build_opener(HTTPHandler) + opener = build_opener(HTTPSHandler(context=ssl_create_default_context())) with open(filename, "rb") as f: params_dict = { "build": self.buildname, @@ -446,7 +448,7 @@ def upload(self, filename): # By default, urllib2 only support GET and POST. # CDash expects this file to be uploaded via PUT. request.get_method = lambda: "PUT" - response = opener.open(request) + response = opener.open(request, timeout=SPACK_CDASH_TIMEOUT) if self.current_package_name not in self.buildIds: resp_value = response.read() if isinstance(resp_value, bytes): diff --git a/lib/spack/spack/rewiring.py b/lib/spack/spack/rewiring.py index 297b0bd232ca2f..15d739562cfa1a 100644 --- a/lib/spack/spack/rewiring.py +++ b/lib/spack/spack/rewiring.py @@ -9,7 +9,7 @@ import tempfile from collections import OrderedDict -from llnl.util.symlink import symlink +from llnl.util.symlink import readlink, symlink import spack.binary_distribution as bindist import spack.error @@ -26,7 +26,7 @@ def _relocate_spliced_links(links, orig_prefix, new_prefix): in our case. This still needs to be called after the copy to destination because it expects the new directory structure to be in place.""" for link in links: - link_target = os.readlink(os.path.join(orig_prefix, link)) + link_target = readlink(os.path.join(orig_prefix, link)) link_target = re.sub("^" + orig_prefix, new_prefix, link_target) new_link_path = os.path.join(new_prefix, link) os.unlink(new_link_path) diff --git a/lib/spack/spack/schema/concretizer.py b/lib/spack/spack/schema/concretizer.py index bc9253cb25fd6d..e1c4d64ce1ca07 100644 --- a/lib/spack/spack/schema/concretizer.py +++ b/lib/spack/spack/schema/concretizer.py @@ -9,13 +9,40 @@ """ from typing import Any, Dict +LIST_OF_SPECS = {"type": "array", "items": {"type": "string"}} + properties: Dict[str, Any] = { "concretizer": { "type": "object", "additionalProperties": False, "properties": { "reuse": { - "oneOf": [{"type": "boolean"}, {"type": "string", "enum": ["dependencies"]}] + "oneOf": [ + {"type": "boolean"}, + {"type": "string", "enum": ["dependencies"]}, + { + "type": "object", + "properties": { + "roots": {"type": "boolean"}, + "include": LIST_OF_SPECS, + "exclude": LIST_OF_SPECS, + "from": { + "type": "array", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": ["local", "buildcache", "external"], + }, + "include": LIST_OF_SPECS, + "exclude": LIST_OF_SPECS, + }, + }, + }, + }, + }, + ] }, "enable_node_namespace": {"type": "boolean"}, "targets": { @@ -34,6 +61,7 @@ "strategy": {"type": "string", "enum": ["none", "minimal", "full"]} }, }, + "os_compatible": {"type": "object", "additionalProperties": {"type": "array"}}, }, } } diff --git a/lib/spack/spack/schema/config.py b/lib/spack/spack/schema/config.py index b7fca099385170..fdb57f5b772519 100644 --- a/lib/spack/spack/schema/config.py +++ b/lib/spack/spack/schema/config.py @@ -73,6 +73,7 @@ "environments_root": {"type": "string"}, "connect_timeout": {"type": "integer", "minimum": 0}, "verify_ssl": {"type": "boolean"}, + "ssl_certs": {"type": "string"}, "suppress_gpg_warnings": {"type": "boolean"}, "install_missing_compilers": {"type": "boolean"}, "debug": {"type": "boolean"}, diff --git a/lib/spack/spack/schema/env.py b/lib/spack/spack/schema/env.py index d2df795a3d6af8..8b37f3e236fc68 100644 --- a/lib/spack/spack/schema/env.py +++ b/lib/spack/spack/schema/env.py @@ -35,6 +35,7 @@ { "include": {"type": "array", "default": [], "items": {"type": "string"}}, "specs": spec_list_schema, + "include_concrete": {"type": "array", "default": [], "items": {"type": "string"}}, }, ), } diff --git a/lib/spack/spack/schema/mirrors.py b/lib/spack/spack/schema/mirrors.py index c3959374a774a8..9a56f1a7e28415 100644 --- a/lib/spack/spack/schema/mirrors.py +++ b/lib/spack/spack/schema/mirrors.py @@ -46,6 +46,7 @@ "signed": {"type": "boolean"}, "fetch": fetch_and_push, "push": fetch_and_push, + "autopush": {"type": "boolean"}, **connection, # type: ignore }, } diff --git a/lib/spack/spack/schema/packages.py b/lib/spack/spack/schema/packages.py index 492180f70e8689..847b15d91385fa 100644 --- a/lib/spack/spack/schema/packages.py +++ b/lib/spack/spack/schema/packages.py @@ -141,7 +141,7 @@ "deprecatedProperties": { "properties": ["version"], "message": "setting version preferences in the 'all' section of packages.yaml " - "is deprecated and will be removed in v0.22\n\n\tThese preferences " + "is deprecated and will be removed in v0.23\n\n\tThese preferences " "will be ignored by Spack. You can set them only in package-specific sections " "of the same file.\n", "error": False, @@ -197,7 +197,7 @@ "properties": ["target", "compiler", "providers"], "message": "setting 'compiler:', 'target:' or 'provider:' preferences in " "a package-specific section of packages.yaml is deprecated, and will be " - "removed in v0.22.\n\n\tThese preferences will be ignored by Spack, and " + "removed in v0.23.\n\n\tThese preferences will be ignored by Spack, and " "can be set only in the 'all' section of the same file. " "You can run:\n\n\t\t$ spack audit configs\n\n\tto get better diagnostics, " "including files:lines where the deprecated attributes are used.\n\n" diff --git a/lib/spack/spack/solver/asp.py b/lib/spack/spack/solver/asp.py index c2524b1223c992..c4251bc22018a0 100644 --- a/lib/spack/spack/solver/asp.py +++ b/lib/spack/spack/solver/asp.py @@ -6,6 +6,7 @@ import collections.abc import copy import enum +import functools import itertools import os import pathlib @@ -15,12 +16,14 @@ import types import typing import warnings +from contextlib import contextmanager from typing import Callable, Dict, Iterator, List, NamedTuple, Optional, Set, Tuple, Type, Union import archspec.cpu import llnl.util.lang import llnl.util.tty as tty +from llnl.util.lang import elide_list import spack import spack.binary_distribution @@ -40,6 +43,8 @@ import spack.spec import spack.store import spack.util.crypto +import spack.util.elf +import spack.util.libc import spack.util.path import spack.util.timer import spack.variant @@ -112,6 +117,8 @@ class Provenance(enum.IntEnum): PACKAGE_PY = enum.auto() # An installed spec INSTALLED = enum.auto() + # lower provenance for installed git refs so concretizer prefers StandardVersion installs + INSTALLED_GIT_VERSION = enum.auto() # A runtime injected from another package (e.g. a compiler) RUNTIME = enum.auto() @@ -119,6 +126,17 @@ def __str__(self): return f"{self._name_.lower()}" +@contextmanager +def spec_with_name(spec, name): + """Context manager to temporarily set the name of a spec""" + old_name = spec.name + spec.name = name + try: + yield spec + finally: + spec.name = old_name + + class RequirementKind(enum.Enum): """Purpose / provenance of a requirement""" @@ -267,8 +285,40 @@ def _create_counter(specs: List[spack.spec.Spec], tests: bool): return NoDuplicatesCounter(specs, tests=tests) -def all_compilers_in_config(): - return spack.compilers.all_compilers() +def all_compilers_in_config(configuration): + return spack.compilers.all_compilers_from(configuration) + + +def all_libcs() -> Set[spack.spec.Spec]: + """Return a set of all libc specs targeted by any configured compiler. If none, fall back to + libc determined from the current Python process if dynamically linked.""" + + libcs = { + c.default_libc for c in all_compilers_in_config(spack.config.CONFIG) if c.default_libc + } + + if libcs: + return libcs + + libc = spack.util.libc.libc_from_current_python_process() + return {libc} if libc else set() + + +def libc_is_compatible(lhs: spack.spec.Spec, rhs: spack.spec.Spec) -> List[spack.spec.Spec]: + return ( + lhs.name == rhs.name + and lhs.external_path == rhs.external_path + and lhs.version >= rhs.version + ) + + +def using_libc_compatibility() -> bool: + """Returns True if we are currently using libc compatibility""" + return spack.platforms.host().name == "linux" + + +def c_compiler_runs(compiler: spack.compiler.Compiler) -> bool: + return compiler.compiler_verbose_output is not None def extend_flag_list(flag_list, new_flags): @@ -541,6 +591,7 @@ def _concretization_version_order(version_info: Tuple[GitOrStandardVersion, dict info.get("preferred", False), not info.get("deprecated", False), not version.isdevelop(), + not version.is_prerelease(), version, ) @@ -553,9 +604,27 @@ def _spec_with_default_name(spec_str, name): return spec +def _external_config_with_implicit_externals(configuration): + # Read packages.yaml and normalize it, so that it will not contain entries referring to + # virtual packages. + packages_yaml = _normalize_packages_yaml(configuration.get("packages")) + + # Add externals for libc from compilers on Linux + if not using_libc_compatibility(): + return packages_yaml + + for compiler in all_compilers_in_config(configuration): + libc = compiler.default_libc + if libc: + entry = {"spec": f"{libc} %{compiler.spec}", "prefix": libc.external_path} + packages_yaml.setdefault(libc.name, {}).setdefault("externals", []).append(entry) + return packages_yaml + + class ErrorHandler: - def __init__(self, model): + def __init__(self, model, input_specs: List[spack.spec.Spec]): self.model = model + self.input_specs = input_specs self.full_model = None def multiple_values_error(self, attribute, pkg): @@ -642,12 +711,13 @@ def handle_error(self, msg, *args): return msg def message(self, errors) -> str: - messages = [ - f" {idx+1: 2}. {self.handle_error(msg, *args)}" + input_specs = ", ".join(elide_list([f"`{s}`" for s in self.input_specs], 5)) + header = f"failed to concretize {input_specs} for the following reasons:" + messages = ( + f" {idx+1:2}. {self.handle_error(msg, *args)}" for idx, (_, msg, args) in enumerate(errors) - ] - header = "concretization failed for the following reasons:\n" - return "\n".join([header] + messages) + ) + return "\n".join((header, *messages)) def raise_if_errors(self): initial_error_args = extract_args(self.model, "error") @@ -683,12 +753,13 @@ def on_model(model): f"unexpected error during concretization [{str(e)}]. " f"Please report a bug at https://github.com/spack/spack/issues" ) - raise spack.error.SpackError(msg) + raise spack.error.SpackError(msg) from e raise UnsatisfiableSpecError(msg) -#: Data class to collect information on a requirement class RequirementRule(NamedTuple): + """Data class to collect information on a requirement""" + pkg_name: str policy: str requirements: List["spack.spec.Spec"] @@ -697,6 +768,27 @@ class RequirementRule(NamedTuple): message: Optional[str] +class KnownCompiler(NamedTuple): + """Data class to collect information on compilers""" + + spec: "spack.spec.Spec" + os: str + target: str + available: bool + compiler_obj: Optional["spack.compiler.Compiler"] + + def _key(self): + return self.spec, self.os, self.target + + def __eq__(self, other: object): + if not isinstance(other, KnownCompiler): + return NotImplemented + return self._key() == other._key() + + def __hash__(self): + return hash(self._key()) + + class PyclingoDriver: def __init__(self, cores=True): """Driver for the Python clingo interface. @@ -726,12 +818,22 @@ def solve(self, setup, specs, reuse=None, output=None, control=None, allow_depre A tuple of the solve result, the timer for the different phases of the solve, and the internal statistics from clingo. """ + # avoid circular import + import spack.bootstrap + output = output or DEFAULT_OUTPUT_CONFIGURATION timer = spack.util.timer.Timer() # Initialize the control object for the solver self.control = control or default_clingo_control() + # ensure core deps are present on Windows + # needs to modify active config scope, so cannot be run within + # bootstrap config scope + if sys.platform == "win32": + tty.debug("Ensuring basic dependencies {win-sdk, wgl} available") + spack.bootstrap.core.ensure_winsdk_external_or_raise() + timer.start("setup") asp_problem = setup.setup(specs, reuse=reuse, allow_deprecated=allow_deprecated) if output.out is not None: @@ -747,12 +849,16 @@ def solve(self, setup, specs, reuse=None, output=None, control=None, allow_depre parent_dir = os.path.dirname(__file__) self.control.load(os.path.join(parent_dir, "concretize.lp")) self.control.load(os.path.join(parent_dir, "heuristic.lp")) - if spack.config.CONFIG.get("concretizer:duplicates:strategy", "none") != "none": - self.control.load(os.path.join(parent_dir, "heuristic_separate.lp")) - self.control.load(os.path.join(parent_dir, "os_compatibility.lp")) self.control.load(os.path.join(parent_dir, "display.lp")) if not setup.concretize_everything: self.control.load(os.path.join(parent_dir, "when_possible.lp")) + + # Binary compatibility is based on libc on Linux, and on the os tag elsewhere + if using_libc_compatibility(): + self.control.load(os.path.join(parent_dir, "libc_compatibility.lp")) + else: + self.control.load(os.path.join(parent_dir, "os_compatibility.lp")) + timer.stop("load") # Grounding is the first step in the solve -- it turns our facts @@ -762,7 +868,6 @@ def solve(self, setup, specs, reuse=None, output=None, control=None, allow_depre timer.stop("ground") # With a grounded program, we can run the solve. - result = Result(specs) models = [] # stable models if things go well cores = [] # unsatisfiable cores if they do not @@ -783,6 +888,7 @@ def on_model(model): timer.stop("solve") # once done, construct the solve result + result = Result(specs) result.satisfiable = solve_result.satisfiable if result.satisfiable: @@ -791,7 +897,7 @@ def on_model(model): min_cost, best_model = min(models) # first check for errors - error_handler = ErrorHandler(best_model) + error_handler = ErrorHandler(best_model, specs) error_handler.raise_if_errors() # build specs from spec attributes in the model @@ -823,6 +929,8 @@ def on_model(model): print("Statistics:") pprint.pprint(self.control.statistics) + result.raise_if_unsat() + if result.satisfiable and result.unsolved_specs and setup.concretize_everything: unsolved_str = Result.format_unsolved(result.unsolved_specs) raise InternalConcretizerError( @@ -843,14 +951,26 @@ class ConcreteSpecsByHash(collections.abc.Mapping): def __init__(self) -> None: self.data: Dict[str, spack.spec.Spec] = {} + self.explicit: Set[str] = set() def __getitem__(self, dag_hash: str) -> spack.spec.Spec: return self.data[dag_hash] + def explicit_items(self) -> Iterator[Tuple[str, spack.spec.Spec]]: + """Iterate on items that have been added explicitly, and not just as a dependency + of other nodes. + """ + for h, s in self.items(): + # We need to make an exception for gcc-runtime, until we can splice it. + if h in self.explicit or s.name == "gcc-runtime": + yield h, s + def add(self, spec: spack.spec.Spec) -> bool: """Adds a new concrete spec to the mapping. Returns True if the spec was just added, False if the spec was already in the mapping. + Calling this function marks the spec as added explicitly. + Args: spec: spec to be added @@ -865,6 +985,7 @@ def add(self, spec: spack.spec.Spec) -> bool: raise ValueError(msg) dag_hash = spec.dag_hash() + self.explicit.add(dag_hash) if dag_hash in self.data: return False @@ -947,6 +1068,9 @@ def __init__(self, tests: bool = False): self.pkgs: Set[str] = set() self.explicitly_required_namespaces: Dict[str, str] = {} + # list of unique libc specs targeted by compilers (or an educated guess if no compiler) + self.libcs: List[spack.spec.Spec] = [] + def pkg_version_rules(self, pkg): """Output declared versions of a package. @@ -1039,40 +1163,51 @@ def conflict_rules(self, pkg): ) self.gen.newline() + def package_languages(self, pkg): + for when_spec, languages in pkg.languages.items(): + condition_msg = f"{pkg.name} needs the {', '.join(sorted(languages))} language" + if when_spec != spack.spec.Spec(): + condition_msg += f" when {when_spec}" + condition_id = self.condition(when_spec, name=pkg.name, msg=condition_msg) + for language in sorted(languages): + self.gen.fact(fn.pkg_fact(pkg.name, fn.language(condition_id, language))) + self.gen.newline() + + def config_compatible_os(self): + """Facts about compatible os's specified in configs""" + self.gen.h2("Compatible OS from concretizer config file") + os_data = spack.config.get("concretizer:os_compatible", {}) + for recent, reusable in os_data.items(): + for old in reusable: + self.gen.fact(fn.os_compatible(recent, old)) + self.gen.newline() + def compiler_facts(self): """Facts about available compilers.""" self.gen.h2("Available compilers") - indexed_possible_compilers = list(enumerate(self.possible_compilers)) - for compiler_id, compiler in indexed_possible_compilers: + for compiler_id, compiler in enumerate(self.possible_compilers): self.gen.fact(fn.compiler_id(compiler_id)) self.gen.fact(fn.compiler_name(compiler_id, compiler.spec.name)) self.gen.fact(fn.compiler_version(compiler_id, compiler.spec.version)) - if compiler.operating_system: - self.gen.fact(fn.compiler_os(compiler_id, compiler.operating_system)) - - if compiler.target == "any": - compiler.target = None + if compiler.os: + self.gen.fact(fn.compiler_os(compiler_id, compiler.os)) if compiler.target is not None: self.gen.fact(fn.compiler_target(compiler_id, compiler.target)) - for flag_type, flags in compiler.flags.items(): - for flag in flags: - self.gen.fact(fn.compiler_flag(compiler_id, flag_type, flag)) - - self.gen.newline() + if compiler.compiler_obj is not None: + c = compiler.compiler_obj + for flag_type, flags in c.flags.items(): + for flag in flags: + self.gen.fact(fn.compiler_flag(compiler_id, flag_type, flag)) - # Set compiler defaults, given a list of possible compilers - self.gen.h2("Default compiler preferences (CompilerID, Weight)") + if compiler.available: + self.gen.fact(fn.compiler_available(compiler_id)) - ppk = spack.package_prefs.PackagePrefs("all", "compiler", all=False) - matches = sorted(indexed_possible_compilers, key=lambda x: ppk(x[1].spec)) - - for weight, (compiler_id, cspec) in enumerate(matches): - f = fn.compiler_weight(compiler_id, weight) - self.gen.fact(f) + self.gen.fact(fn.compiler_weight(compiler_id, compiler_id)) + self.gen.newline() def package_requirement_rules(self, pkg): parser = RequirementParser(spack.config.CONFIG) @@ -1088,6 +1223,9 @@ def pkg_rules(self, pkg, tests): self.pkg_version_rules(pkg) self.gen.newline() + # languages + self.package_languages(pkg) + # variants self.variant_rules(pkg) @@ -1114,6 +1252,9 @@ def pkg_rules(self, pkg, tests): def trigger_rules(self): """Flushes all the trigger rules collected so far, and clears the cache.""" + if not self._trigger_cache: + return + self.gen.h2("Trigger conditions") for name in self._trigger_cache: cache = self._trigger_cache[name] @@ -1127,6 +1268,9 @@ def trigger_rules(self): def effect_rules(self): """Flushes all the effect rules collected so far, and clears the cache.""" + if not self._effect_cache: + return + self.gen.h2("Imposed requirements") for name in self._effect_cache: cache = self._effect_cache[name] @@ -1284,33 +1428,37 @@ def condition( Returns: int: id of the condition created by this function """ - named_cond = required_spec.copy() - named_cond.name = named_cond.name or name - if not named_cond.name: - raise ValueError(f"Must provide a name for anonymous condition: '{named_cond}'") + name = required_spec.name or name + if not name: + raise ValueError(f"Must provide a name for anonymous condition: '{required_spec}'") - # Check if we can emit the requirements before updating the condition ID counter. - # In this way, if a condition can't be emitted but the exception is handled in the caller, - # we won't emit partial facts. + with spec_with_name(required_spec, name): + # Check if we can emit the requirements before updating the condition ID counter. + # In this way, if a condition can't be emitted but the exception is handled in the + # caller, we won't emit partial facts. - condition_id = next(self._id_counter) - self.gen.fact(fn.pkg_fact(named_cond.name, fn.condition(condition_id))) - self.gen.fact(fn.condition_reason(condition_id, msg)) + condition_id = next(self._id_counter) + self.gen.fact(fn.pkg_fact(required_spec.name, fn.condition(condition_id))) + self.gen.fact(fn.condition_reason(condition_id, msg)) - trigger_id = self._get_condition_id( - named_cond, cache=self._trigger_cache, body=True, transform=transform_required - ) - self.gen.fact(fn.pkg_fact(named_cond.name, fn.condition_trigger(condition_id, trigger_id))) + trigger_id = self._get_condition_id( + required_spec, cache=self._trigger_cache, body=True, transform=transform_required + ) + self.gen.fact( + fn.pkg_fact(required_spec.name, fn.condition_trigger(condition_id, trigger_id)) + ) - if not imposed_spec: - return condition_id + if not imposed_spec: + return condition_id - effect_id = self._get_condition_id( - imposed_spec, cache=self._effect_cache, body=False, transform=transform_imposed - ) - self.gen.fact(fn.pkg_fact(named_cond.name, fn.condition_effect(condition_id, effect_id))) + effect_id = self._get_condition_id( + imposed_spec, cache=self._effect_cache, body=False, transform=transform_imposed + ) + self.gen.fact( + fn.pkg_fact(required_spec.name, fn.condition_effect(condition_id, effect_id)) + ) - return condition_id + return condition_id def impose(self, condition_id, imposed_spec, node=True, name=None, body=False): imposed_constraints = self.spec_clauses(imposed_spec, body=body, required_from=name) @@ -1498,14 +1646,35 @@ def emit_facts_from_requirement_rules(self, rules: List[RequirementRule]): requirement_weight += 1 def external_packages(self): - """Facts on external packages, as read from packages.yaml""" - # Read packages.yaml and normalize it, so that it - # will not contain entries referring to virtual - # packages. - packages_yaml = spack.config.get("packages") - packages_yaml = _normalize_packages_yaml(packages_yaml) + """Facts on external packages, from packages.yaml and implicit externals.""" + packages_yaml = _external_config_with_implicit_externals(spack.config.CONFIG) self.gen.h1("External packages") + spec_filters = [] + concretizer_yaml = spack.config.get("concretizer") + reuse_yaml = concretizer_yaml.get("reuse") + if isinstance(reuse_yaml, typing.Mapping): + default_include = reuse_yaml.get("include", []) + default_exclude = reuse_yaml.get("exclude", []) + libc_externals = list(all_libcs()) + for source in reuse_yaml.get("from", []): + if source["type"] != "external": + continue + + include = source.get("include", default_include) + if include: + # Since libcs are implicit externals, we need to implicitly include them + include = include + libc_externals + exclude = source.get("exclude", default_exclude) + spec_filters.append( + SpecFilter( + factory=lambda: [], + is_usable=lambda x: True, + include=include, + exclude=exclude, + ) + ) + for pkg_name, data in packages_yaml.items(): if pkg_name == "all": continue @@ -1514,7 +1683,6 @@ def external_packages(self): if pkg_name not in spack.repo.PATH: continue - self.gen.h2("External package: {0}".format(pkg_name)) # Check if the external package is buildable. If it is # not then "external()" is a fact, unless we can # reuse an already installed spec. @@ -1524,7 +1692,17 @@ def external_packages(self): # Read a list of all the specs for this package externals = data.get("externals", []) - external_specs = [spack.spec.parse_with_version_concrete(x["spec"]) for x in externals] + candidate_specs = [ + spack.spec.parse_with_version_concrete(x["spec"]) for x in externals + ] + + external_specs = [] + if spec_filters: + for current_filter in spec_filters: + current_filter.factory = lambda: candidate_specs + external_specs.extend(current_filter.selected_specs()) + else: + external_specs.extend(candidate_specs) # Order the external versions to prefer more recent versions # even if specs in packages.yaml are not ordered that way @@ -1554,6 +1732,7 @@ def external_imposition(input_spec, requirements): self.gen.newline() self.trigger_rules() + self.effect_rules() def preferred_variants(self, pkg_name): """Facts on concretization preferences, as read from packages.yaml""" @@ -1599,23 +1778,6 @@ def target_preferences(self): for i, preferred in enumerate(package_targets): self.gen.fact(fn.target_weight(str(preferred.architecture.target), i)) - def flag_defaults(self): - self.gen.h2("Compiler flag defaults") - - # types of flags that can be on specs - for flag in spack.spec.FlagMap.valid_compiler_flags(): - self.gen.fact(fn.flag_type(flag)) - self.gen.newline() - - # flags from compilers.yaml - compilers = all_compilers_in_config() - for compiler in compilers: - for name, flags in compiler.flags.items(): - for flag in flags: - self.gen.fact( - fn.compiler_version_flag(compiler.name, compiler.version, name, flag) - ) - def spec_clauses( self, spec: spack.spec.Spec, @@ -1721,11 +1883,8 @@ def _spec_clauses( ) clauses.append(f.variant_value(spec.name, vname, value)) - if variant.propagate: - clauses.append( - f.variant_propagation_candidate(spec.name, vname, value, spec.name) - ) + clauses.append(f.propagate(spec.name, fn.variant_value(vname, value))) # Tell the concretizer that this is a possible value for the # variant, to account for things like int/str values where we @@ -1758,9 +1917,12 @@ def _spec_clauses( for flag_type, flags in spec.compiler_flags.items(): for flag in flags: clauses.append(f.node_flag(spec.name, flag_type, flag)) - clauses.append(f.node_flag_source(spec.name, flag_type, spec.name)) if not spec.concrete and flag.propagate is True: - clauses.append(f.node_flag_propagate(spec.name, flag_type)) + clauses.append( + f.propagate( + spec.name, fn.node_flag(flag_type, flag), fn.edge_types("link", "run") + ) + ) # dependencies if spec.concrete: @@ -1780,6 +1942,11 @@ def _spec_clauses( for virtual in virtuals: clauses.append(fn.attr("virtual_on_incoming_edges", spec.name, virtual)) + # If the spec is external and concrete, we allow all the libcs on the system + if spec.external and spec.concrete and using_libc_compatibility(): + for libc in self.libcs: + clauses.append(fn.attr("compatible_libc", spec.name, libc.name, libc.version)) + # add all clauses from dependencies if transitive: # TODO: Eventually distinguish 2 deps on the same pkg (build and link) @@ -1792,6 +1959,16 @@ def _spec_clauses( if dep.name == "gcc-runtime": continue + # libc is also solved again by clingo, but in this case the compatibility + # is not encoded in the parent node - so we need to emit explicit facts + if "libc" in dspec.virtuals: + for libc in self.libcs: + if libc_is_compatible(libc, dep): + clauses.append( + fn.attr("compatible_libc", spec.name, libc.name, libc.version) + ) + continue + # We know dependencies are real for concrete specs. For abstract # specs they just mean the dep is somehow in the DAG. for dtype in dt.ALL_FLAGS: @@ -1898,7 +2075,7 @@ def define_ad_hoc_versions_from_specs( # best possible, so they're guaranteed to be used preferentially. version = s.versions.concrete - if version is None or any(v == version for v in self.possible_versions[s.name]): + if version is None or (any((v == version) for v in self.possible_versions[s.name])): continue if require_checksum and not _is_checksummed_git_version(version): @@ -1924,7 +2101,7 @@ def _supported_targets(self, compiler_name, compiler_version, targets): try: with warnings.catch_warnings(): warnings.simplefilter("ignore") - target.optimization_flags(compiler_name, compiler_version) + target.optimization_flags(compiler_name, str(compiler_version)) supported.append(target) except archspec.cpu.UnsupportedMicroarchitecture: continue @@ -2021,9 +2198,16 @@ def target_defaults(self, specs): candidate_targets.append(ancestor) best_targets = {uarch.family.name} - for compiler_id, compiler in enumerate(self.possible_compilers): + for compiler_id, known_compiler in enumerate(self.possible_compilers): + if not known_compiler.available: + continue + + compiler = known_compiler.compiler_obj # Stub support for cross-compilation, to be expanded later - if compiler.target is not None and compiler.target != str(uarch.family): + if known_compiler.target is not None and compiler.target not in ( + str(uarch.family), + "any", + ): self.gen.fact(fn.compiler_supports_target(compiler_id, compiler.target)) self.gen.newline() continue @@ -2079,58 +2263,6 @@ def virtual_providers(self): self.gen.fact(fn.virtual(vspec)) self.gen.newline() - def generate_possible_compilers(self, specs): - compilers = all_compilers_in_config() - - # Search for compilers which differs only by aspects that are - # not selectable by users using the spec syntax - seen, sanitized_list = set(), [] - for compiler in compilers: - key = compiler.spec, compiler.operating_system, compiler.target - if key in seen: - warnings.warn( - f"duplicate found for {compiler.spec} on " - f"{compiler.operating_system}/{compiler.target}. " - f"Edit your compilers.yaml configuration to remove it." - ) - continue - sanitized_list.append(compiler) - seen.add(key) - - cspecs = set([c.spec for c in compilers]) - - # add compiler specs from the input line to possibilities if we - # don't require compilers to exist. - strict = spack.concretize.Concretizer().check_for_compiler_existence - for s in traverse.traverse_nodes(specs): - # we don't need to validate compilers for already-built specs - if s.concrete or not s.compiler: - continue - - version = s.compiler.versions.concrete - - if not version or any(c.satisfies(s.compiler) for c in cspecs): - continue - - # Error when a compiler is not found and strict mode is enabled - if strict: - raise spack.concretize.UnavailableCompilerVersionError(s.compiler) - - # Make up a compiler matching the input spec. This is for bootstrapping. - compiler_cls = spack.compilers.class_for_compiler_name(s.compiler.name) - compilers.append( - compiler_cls(s.compiler, operating_system=None, target=None, paths=[None] * 4) - ) - self.gen.fact(fn.allow_compiler(s.compiler.name, version)) - - return list( - sorted( - compilers, - key=lambda compiler: (compiler.spec.name, compiler.spec.version), - reverse=True, - ) - ) - def define_version_constraints(self): """Define what version_satisfies(...) means in ASP logic.""" for pkg_name, versions in sorted(self.version_constraints): @@ -2158,7 +2290,7 @@ def versions_for(v): if isinstance(v, vn.StandardVersion): return [v] elif isinstance(v, vn.ClosedOpenRange): - return [v.lo, vn.prev_version(v.hi)] + return [v.lo, vn._prev_version(v.hi)] elif isinstance(v, vn.VersionList): return sum((versions_for(e) for e in v), []) else: @@ -2246,7 +2378,7 @@ def register_concrete_spec(self, spec, possible): def concrete_specs(self): """Emit facts for reusable specs""" - for h, spec in self.reusable_and_possible.items(): + for h, spec in self.reusable_and_possible.explicit_items(): # this indicates that there is a spec like this installed self.gen.fact(fn.installed_hash(spec.name, h)) # this describes what constraints it imposes on the solve @@ -2257,9 +2389,16 @@ def concrete_specs(self): # - Add OS to possible OS's for dep in spec.traverse(): self.possible_versions[dep.name].add(dep.version) - self.declared_versions[dep.name].append( - DeclaredVersion(version=dep.version, idx=0, origin=Provenance.INSTALLED) - ) + if isinstance(dep.version, vn.GitVersion): + self.declared_versions[dep.name].append( + DeclaredVersion( + version=dep.version, idx=0, origin=Provenance.INSTALLED_GIT_VERSION + ) + ) + else: + self.declared_versions[dep.name].append( + DeclaredVersion(version=dep.version, idx=0, origin=Provenance.INSTALLED) + ) self.possible_oses.add(dep.os) def define_concrete_input_specs(self, specs, possible): @@ -2292,8 +2431,7 @@ def setup( node_counter = _create_counter(specs, tests=self.tests) self.possible_virtuals = node_counter.possible_virtuals() self.pkgs = node_counter.possible_dependencies() - - self.pkgs.update(spack.repo.PATH.packages_with_tags("runtime")) + self.libcs = sorted(all_libcs()) # type: ignore[type-var] # Fail if we already know an unreachable node is requested for spec in specs: @@ -2303,11 +2441,16 @@ def setup( if missing_deps: raise spack.spec.InvalidDependencyError(spec.name, missing_deps) - for node in spack.traverse.traverse_nodes(specs): + for node in traverse.traverse_nodes(specs): if node.namespace is not None: self.explicitly_required_namespaces[node.name] = node.namespace self.gen = ProblemInstanceBuilder() + compiler_parser = CompilerParser(configuration=spack.config.CONFIG).with_input_specs(specs) + + if using_libc_compatibility(): + for libc in self.libcs: + self.gen.fact(fn.host_libc(libc.name, libc.version)) if not allow_deprecated: self.gen.fact(fn.deprecated_versions_not_allowed()) @@ -2327,17 +2470,17 @@ def setup( ) specs = tuple(specs) # ensure compatible types to add - # get possible compilers - self.possible_compilers = self.generate_possible_compilers(specs) - self.gen.h1("Reusable concrete specs") self.define_concrete_input_specs(specs, self.pkgs) if reuse: self.gen.fact(fn.optimize_for_reuse()) for reusable_spec in reuse: + compiler_parser.add_compiler_from_concrete_spec(reusable_spec) self.register_concrete_spec(reusable_spec, self.pkgs) self.concrete_specs() + self.possible_compilers = compiler_parser.possible_compilers() + self.gen.h1("Generic statements on possible packages") node_counter.possible_packages_facts(self.gen, fn) @@ -2347,6 +2490,7 @@ def setup( self.gen.newline() self.gen.h1("General Constraints") + self.config_compatible_os() self.compiler_facts() # architecture defaults @@ -2437,15 +2581,42 @@ def visit(node): def define_runtime_constraints(self): """Define the constraints to be imposed on the runtimes""" recorder = RuntimePropertyRecorder(self) + for compiler in self.possible_compilers: - if compiler.name != "gcc": - continue + compiler_with_different_cls_names = { + "oneapi": "intel-oneapi-compilers", + "clang": "llvm", + } + compiler_cls_name = compiler_with_different_cls_names.get( + compiler.spec.name, compiler.spec.name + ) try: - compiler_cls = spack.repo.PATH.get_pkg_class(compiler.name) + compiler_cls = spack.repo.PATH.get_pkg_class(compiler_cls_name) + if hasattr(compiler_cls, "runtime_constraints"): + compiler_cls.runtime_constraints(spec=compiler.spec, pkg=recorder) except spack.repo.UnknownPackageError: + pass + + # Inject libc from available compilers, on Linux + if not compiler.available: continue - if hasattr(compiler_cls, "runtime_constraints"): - compiler_cls.runtime_constraints(compiler=compiler, pkg=recorder) + + current_libc = compiler.compiler_obj.default_libc + # If this is a compiler yet to be built (config:install_missing_compilers:true) + # infer libc from the Python process + if not current_libc and compiler.compiler_obj.cc is None: + current_libc = spack.util.libc.libc_from_current_python_process() + + if using_libc_compatibility() and current_libc: + recorder("*").depends_on( + "libc", when=f"%{compiler.spec}", type="link", description="Add libc" + ) + recorder("*").depends_on( + str(current_libc), + when=f"%{compiler.spec}", + type="link", + description="Add libc", + ) recorder.consume_facts() @@ -2576,9 +2747,7 @@ class _Head: node_compiler = fn.attr("node_compiler_set") node_compiler_version = fn.attr("node_compiler_version_set") node_flag = fn.attr("node_flag_set") - node_flag_source = fn.attr("node_flag_source") - node_flag_propagate = fn.attr("node_flag_propagate") - variant_propagation_candidate = fn.attr("variant_propagation_candidate") + propagate = fn.attr("propagate") class _Body: @@ -2593,9 +2762,7 @@ class _Body: node_compiler = fn.attr("node_compiler") node_compiler_version = fn.attr("node_compiler_version") node_flag = fn.attr("node_flag") - node_flag_source = fn.attr("node_flag_source") - node_flag_propagate = fn.attr("node_flag_propagate") - variant_propagation_candidate = fn.attr("variant_propagation_candidate") + propagate = fn.attr("propagate") class ProblemInstanceBuilder: @@ -2817,6 +2984,104 @@ def reject_requirement_constraint( return False +class CompilerParser: + """Parses configuration files, and builds a list of possible compilers for the solve.""" + + def __init__(self, configuration) -> None: + self.compilers: Set[KnownCompiler] = set() + for c in all_compilers_in_config(configuration): + if using_libc_compatibility() and not c_compiler_runs(c): + tty.debug( + f"the C compiler {c.cc} does not exist, or does not run correctly." + f" The compiler {c.spec} will not be used during concretization." + ) + continue + + if using_libc_compatibility() and not c.default_libc: + warnings.warn( + f"cannot detect libc from {c.spec}. The compiler will not be used " + f"during concretization." + ) + continue + + target = c.target if c.target != "any" else None + candidate = KnownCompiler( + spec=c.spec, os=c.operating_system, target=target, available=True, compiler_obj=c + ) + if candidate in self.compilers: + warnings.warn( + f"duplicate found for {c.spec} on {c.operating_system}/{c.target}. " + f"Edit your compilers.yaml configuration to remove it." + ) + continue + + self.compilers.add(candidate) + + def with_input_specs(self, input_specs: List["spack.spec.Spec"]) -> "CompilerParser": + """Accounts for input specs when building the list of possible compilers. + + Args: + input_specs: specs to be concretized + """ + strict = spack.concretize.Concretizer().check_for_compiler_existence + default_os = str(spack.platforms.host().default_os) + default_target = str(archspec.cpu.host().family) + for s in traverse.traverse_nodes(input_specs): + # we don't need to validate compilers for already-built specs + if s.concrete or not s.compiler: + continue + + version = s.compiler.versions.concrete + + if not version or any(item.spec.satisfies(s.compiler) for item in self.compilers): + continue + + # Error when a compiler is not found and strict mode is enabled + if strict: + raise spack.concretize.UnavailableCompilerVersionError(s.compiler) + + # Make up a compiler matching the input spec. This is for bootstrapping. + compiler_cls = spack.compilers.class_for_compiler_name(s.compiler.name) + compiler_obj = compiler_cls( + s.compiler, operating_system=default_os, target=default_target, paths=[None] * 4 + ) + self.compilers.add( + KnownCompiler( + spec=s.compiler, + os=default_os, + target=default_target, + available=True, + compiler_obj=compiler_obj, + ) + ) + + return self + + def add_compiler_from_concrete_spec(self, spec: "spack.spec.Spec") -> None: + """Account for compilers that are coming from concrete specs, through reuse. + + Args: + spec: concrete spec to be reused + """ + assert spec.concrete, "the spec argument must be concrete" + candidate = KnownCompiler( + spec=spec.compiler, + os=str(spec.architecture.os), + target=str(spec.architecture.target.microarchitecture.family), + available=False, + compiler_obj=None, + ) + self.compilers.add(candidate) + + def possible_compilers(self) -> List[KnownCompiler]: + # Here we have to sort two times, first sort by name and ascending version + result = sorted(self.compilers, key=lambda x: (x.spec.name, x.spec.version), reverse=True) + # Then stable sort to prefer available compilers and account for preferences + ppk = spack.package_prefs.PackagePrefs("all", "compiler", all=False) + result.sort(key=lambda x: (not x.available, ppk(x.spec))) + return result + + class RuntimePropertyRecorder: """An object of this class is injected in callbacks to compilers, to let them declare properties of the runtimes they support and of the runtimes they provide, and to add @@ -2857,13 +3122,24 @@ def reset(self): """Resets the current state.""" self.current_package = None - def depends_on(self, dependency_str: str, *, when: str, type: str, description: str) -> None: + def depends_on( + self, + dependency_str: str, + *, + when: str, + type: str, + description: str, + languages: Optional[List[str]] = None, + ) -> None: """Injects conditional dependencies on packages. + Conditional dependencies can be either "real" packages or virtual dependencies. + Args: dependency_str: the dependency spec to inject when: anonymous condition to be met on a package to have the dependency type: dependency type + languages: languages needed by the package for the dependency to be considered description: human-readable description of the rule for adding the dependency """ # TODO: The API for this function is not final, and is still subject to change. At @@ -2889,26 +3165,45 @@ def depends_on(self, dependency_str: str, *, when: str, type: str, description: f" not external({node_variable}),\n" f" not runtime(Package)" ).replace(f'"{placeholder}"', f"{node_variable}") + if languages: + body_str += ",\n" + for language in languages: + body_str += f' attr("language", {node_variable}, "{language}")' + head_clauses = self._setup.spec_clauses(dependency_spec, body=False) runtime_pkg = dependency_spec.name + + is_virtual = head_clauses[0].args[0] == "virtual_node" main_rule = ( f"% {description}\n" f'1 {{ attr("depends_on", {node_variable}, node(0..X-1, "{runtime_pkg}"), "{type}") :' - f' max_dupes("gcc-runtime", X)}} 1:-\n' + f' max_dupes("{runtime_pkg}", X)}} 1:-\n' f"{body_str}.\n\n" ) + if is_virtual: + main_rule = ( + f"% {description}\n" + f'attr("dependency_holds", {node_variable}, "{runtime_pkg}", "{type}") :-\n' + f"{body_str}.\n\n" + ) + self.rules.append(main_rule) for clause in head_clauses: if clause.args[0] == "node": continue runtime_node = f'node(RuntimeID, "{runtime_pkg}")' head_str = str(clause).replace(f'"{runtime_pkg}"', runtime_node) - rule = ( - f"{head_str} :-\n" + depends_on_constraint = ( f' attr("depends_on", {node_variable}, {runtime_node}, "{type}"),\n' - f"{body_str}.\n\n" ) + if is_virtual: + depends_on_constraint = ( + f' attr("depends_on", {node_variable}, ProviderNode, "{type}"),\n' + f" provider(ProviderNode, {runtime_node}),\n" + ) + + rule = f"{head_str} :-\n" f"{depends_on_constraint}" f"{body_str}.\n\n" self.rules.append(rule) self.reset() @@ -2941,6 +3236,39 @@ def requires(self, impose: str, *, when: str): self.runtime_conditions.add((imposed_spec, when_spec)) self.reset() + def propagate(self, constraint_str: str, *, when: str): + msg = "the 'propagate' method can be called only with pkg('*')" + assert self.current_package == "*", msg + + when_spec = spack.spec.Spec(when) + assert when_spec.name is None, "only anonymous when specs are accepted" + + placeholder = "XXX" + node_variable = "node(ID, Package)" + when_spec.name = placeholder + + body_clauses = self._setup.spec_clauses(when_spec, body=True) + body_str = ( + f" {f',{os.linesep} '.join(str(x) for x in body_clauses)},\n" + f" not external({node_variable}),\n" + f" not runtime(Package)" + ).replace(f'"{placeholder}"', f"{node_variable}") + + constraint_spec = spack.spec.Spec(constraint_str) + assert constraint_spec.name is None, "only anonymous constraint specs are accepted" + + constraint_spec.name = placeholder + constraint_clauses = self._setup.spec_clauses(constraint_spec, body=False) + for clause in constraint_clauses: + if clause.args[0] == "node_compiler_version_satisfies": + self._setup.compiler_version_constraints.add(constraint_spec.compiler) + args = f'"{constraint_spec.compiler.name}", "{constraint_spec.compiler.versions}"' + head_str = f"propagate({node_variable}, node_compiler_version_satisfies({args}))" + rule = f"{head_str} :-\n{body_str}.\n\n" + self.rules.append(rule) + + self.reset() + def consume_facts(self): """Consume the facts collected by this object, and emits rules and facts for the runtimes. @@ -2977,13 +3305,16 @@ class SpecBuilder: r"^.*_propagate$", r"^.*_satisfies$", r"^.*_set$", + r"^compatible_libc$", r"^dependency_holds$", + r"^external_conditions_hold$", r"^node_compiler$", r"^package_hash$", r"^root$", r"^track_dependencies$", r"^variant_default_value_from_cli$", r"^virtual_node$", + r"^virtual_on_incoming_edges$", r"^virtual_root$", ] ) @@ -3017,6 +3348,8 @@ def hash(self, node, h): def node(self, node): if node not in self._specs: self._specs[node] = spack.spec.Spec(node.pkg) + for flag_type in spack.spec.FlagMap.valid_compiler_flags(): + self._specs[node].compiler_flags[flag_type] = [] def _arch(self, node): arch = self._specs[node].architecture @@ -3069,16 +3402,9 @@ def node_flag(self, node, flag_type, flag): def node_flag_source(self, node, flag_type, source): self._flag_sources[(node, flag_type)].add(source) - def no_flags(self, node, flag_type): - self._specs[node].compiler_flags[flag_type] = [] - def external_spec_selected(self, node, idx): - """This means that the external spec and index idx - has been selected for this package. - """ - - packages_yaml = spack.config.get("packages") - packages_yaml = _normalize_packages_yaml(packages_yaml) + """This means that the external spec and index idx has been selected for this package.""" + packages_yaml = _external_config_with_implicit_externals(spack.config.CONFIG) spec_info = packages_yaml[node.pkg]["externals"][int(idx)] self._specs[node].external_path = spec_info.get("prefix", None) self._specs[node].external_modules = spack.spec.Spec._format_module_list( @@ -3126,7 +3452,9 @@ def reorder_flags(self): imposes order afterwards. """ # reverse compilers so we get highest priority compilers that share a spec - compilers = dict((c.spec, c) for c in reversed(all_compilers_in_config())) + compilers = dict( + (c.spec, c) for c in reversed(all_compilers_in_config(spack.config.CONFIG)) + ) cmd_specs = dict((s.name, s) for spec in self._command_line_specs for s in spec.traverse()) for spec in self._specs.values(): @@ -3166,7 +3494,7 @@ def reorder_flags(self): ordered_compiler_flags = list(llnl.util.lang.dedupe(from_compiler + from_sources)) compiler_flags = spec.compiler_flags.get(flag_type, []) - msg = "%s does not equal %s" % (set(compiler_flags), set(ordered_compiler_flags)) + msg = f"{set(compiler_flags)} does not equal {set(ordered_compiler_flags)}" assert set(compiler_flags) == set(ordered_compiler_flags), msg spec.compiler_flags.update({flag_type: ordered_compiler_flags}) @@ -3236,9 +3564,8 @@ def build_specs(self, function_tuples): # do not bother calling actions on it except for node_flag_source, # since node_flag_source is tracking information not in the spec itself spec = self._specs.get(args[0]) - if spec and spec.concrete: - if name != "node_flag_source": - continue + if spec and spec.concrete and name != "node_flag_source": + continue action(*args) @@ -3318,7 +3645,7 @@ def _is_reusable(spec: spack.spec.Spec, packages, local: bool) -> bool: return False if not spec.external: - return True + return _has_runtime_dependencies(spec) # Cray external manifest externals are always reusable if local: @@ -3343,25 +3670,172 @@ def _is_reusable(spec: spack.spec.Spec, packages, local: bool) -> bool: return False +def _has_runtime_dependencies(spec: spack.spec.Spec) -> bool: + if not WITH_RUNTIME: + return True + + if spec.compiler.name == "gcc" and not spec.dependencies("gcc-runtime"): + return False + + if spec.compiler.name == "oneapi" and not spec.dependencies("intel-oneapi-runtime"): + return False + + return True + + +class SpecFilter: + """Given a method to produce a list of specs, this class can filter them according to + different criteria. + """ + + def __init__( + self, + factory: Callable[[], List[spack.spec.Spec]], + is_usable: Callable[[spack.spec.Spec], bool], + include: List[str], + exclude: List[str], + ) -> None: + """ + Args: + factory: factory to produce a list of specs + is_usable: predicate that takes a spec in input and returns False if the spec + should not be considered for this filter, True otherwise. + include: if present, a "good" spec must match at least one entry in the list + exclude: if present, a "good" spec must not match any entry in the list + """ + self.factory = factory + self.is_usable = is_usable + self.include = include + self.exclude = exclude + + def is_selected(self, s: spack.spec.Spec) -> bool: + if not self.is_usable(s): + return False + + if self.include and not any(s.satisfies(c) for c in self.include): + return False + + if self.exclude and any(s.satisfies(c) for c in self.exclude): + return False + + return True + + def selected_specs(self) -> List[spack.spec.Spec]: + return [s for s in self.factory() if self.is_selected(s)] + + @staticmethod + def from_store(configuration, include, exclude) -> "SpecFilter": + """Constructs a filter that takes the specs from the current store.""" + packages = _external_config_with_implicit_externals(configuration) + is_reusable = functools.partial(_is_reusable, packages=packages, local=True) + factory = functools.partial(_specs_from_store, configuration=configuration) + return SpecFilter(factory=factory, is_usable=is_reusable, include=include, exclude=exclude) + + @staticmethod + def from_buildcache(configuration, include, exclude) -> "SpecFilter": + """Constructs a filter that takes the specs from the configured buildcaches.""" + packages = _external_config_with_implicit_externals(configuration) + is_reusable = functools.partial(_is_reusable, packages=packages, local=False) + return SpecFilter( + factory=_specs_from_mirror, is_usable=is_reusable, include=include, exclude=exclude + ) + + +def _specs_from_store(configuration): + store = spack.store.create(configuration) + with store.db.read_transaction(): + return store.db.query(installed=True) + + +def _specs_from_mirror(): + try: + return spack.binary_distribution.update_cache_and_get_specs() + except (spack.binary_distribution.FetchCacheError, IndexError): + # this is raised when no mirrors had indices. + # TODO: update mirror configuration so it can indicate that the + # TODO: source cache (or any mirror really) doesn't have binaries. + return [] + + +class ReuseStrategy(enum.Enum): + ROOTS = enum.auto() + DEPENDENCIES = enum.auto() + NONE = enum.auto() + + +class ReusableSpecsSelector: + """Selects specs that can be reused during concretization.""" + + def __init__(self, configuration: spack.config.Configuration) -> None: + self.configuration = configuration + self.store = spack.store.create(configuration) + self.reuse_strategy = ReuseStrategy.ROOTS + + reuse_yaml = self.configuration.get("concretizer:reuse", False) + self.reuse_sources = [] + if not isinstance(reuse_yaml, typing.Mapping): + if reuse_yaml is False: + self.reuse_strategy = ReuseStrategy.NONE + if reuse_yaml == "dependencies": + self.reuse_strategy = ReuseStrategy.DEPENDENCIES + self.reuse_sources.extend( + [ + SpecFilter.from_store( + configuration=self.configuration, include=[], exclude=[] + ), + SpecFilter.from_buildcache( + configuration=self.configuration, include=[], exclude=[] + ), + ] + ) + else: + roots = reuse_yaml.get("roots", True) + if roots is True: + self.reuse_strategy = ReuseStrategy.ROOTS + else: + self.reuse_strategy = ReuseStrategy.DEPENDENCIES + default_include = reuse_yaml.get("include", []) + default_exclude = reuse_yaml.get("exclude", []) + default_sources = [{"type": "local"}, {"type": "buildcache"}] + for source in reuse_yaml.get("from", default_sources): + include = source.get("include", default_include) + exclude = source.get("exclude", default_exclude) + if source["type"] == "local": + self.reuse_sources.append( + SpecFilter.from_store(self.configuration, include=include, exclude=exclude) + ) + elif source["type"] == "buildcache": + self.reuse_sources.append( + SpecFilter.from_buildcache( + self.configuration, include=include, exclude=exclude + ) + ) + + def reusable_specs(self, specs: List[spack.spec.Spec]) -> List[spack.spec.Spec]: + if self.reuse_strategy == ReuseStrategy.NONE: + return [] + + result = [] + for reuse_source in self.reuse_sources: + result.extend(reuse_source.selected_specs()) + + # If we only want to reuse dependencies, remove the root specs + if self.reuse_strategy == ReuseStrategy.DEPENDENCIES: + result = [spec for spec in result if not any(root in spec for root in specs)] + + return result + + class Solver: """This is the main external interface class for solving. It manages solver configuration and preferences in one place. It sets up the solve and passes the setup method to the driver, as well. - - Properties of interest: - - ``reuse (bool)`` - Whether to try to reuse existing installs/binaries - """ def __init__(self): self.driver = PyclingoDriver() - - # These properties are settable via spack configuration, and overridable - # by setting them directly as properties. - self.reuse = spack.config.get("concretizer:reuse", False) + self.selector = ReusableSpecsSelector(configuration=spack.config.CONFIG) @staticmethod def _check_input_and_extract_concrete_specs(specs): @@ -3375,39 +3849,6 @@ def _check_input_and_extract_concrete_specs(specs): spack.spec.Spec.ensure_valid_variants(s) return reusable - def _reusable_specs(self, specs): - reusable_specs = [] - if self.reuse: - packages = spack.config.get("packages") - # Specs from the local Database - with spack.store.STORE.db.read_transaction(): - reusable_specs.extend( - s - for s in spack.store.STORE.db.query(installed=True) - if _is_reusable(s, packages, local=True) - ) - - # Specs from buildcaches - try: - reusable_specs.extend( - s - for s in spack.binary_distribution.update_cache_and_get_specs() - if _is_reusable(s, packages, local=False) - ) - except (spack.binary_distribution.FetchCacheError, IndexError): - # this is raised when no mirrors had indices. - # TODO: update mirror configuration so it can indicate that the - # TODO: source cache (or any mirror really) doesn't have binaries. - pass - - # If we only want to reuse dependencies, remove the root specs - if self.reuse == "dependencies": - reusable_specs = [ - spec for spec in reusable_specs if not any(root in spec for root in specs) - ] - - return reusable_specs - def solve( self, specs, @@ -3433,7 +3874,7 @@ def solve( # Check upfront that the variants are admissible specs = [s.lookup_hash() for s in specs] reusable_specs = self._check_input_and_extract_concrete_specs(specs) - reusable_specs.extend(self._reusable_specs(specs)) + reusable_specs.extend(self.selector.reusable_specs(specs)) setup = SpackSolverSetup(tests=tests) output = OutputConfiguration(timers=timers, stats=stats, out=out, setup_only=setup_only) result, _, _ = self.driver.solve( @@ -3462,7 +3903,7 @@ def solve_in_rounds( """ specs = [s.lookup_hash() for s in specs] reusable_specs = self._check_input_and_extract_concrete_specs(specs) - reusable_specs.extend(self._reusable_specs(specs)) + reusable_specs.extend(self.selector.reusable_specs(specs)) setup = SpackSolverSetup(tests=tests) # Tell clingo that we don't have to solve all the inputs at once @@ -3484,9 +3925,14 @@ def solve_in_rounds( if not result.unsolved_specs: break - # This means we cannot progress with solving the input - if not result.satisfiable or not result.specs: - break + if not result.specs: + # This is also a problem: no specs were solved for, which + # means we would be in a loop if we tried again + unsolved_str = Result.format_unsolved(result.unsolved_specs) + raise InternalConcretizerError( + "Internal Spack error: a subset of input specs could not" + f" be solved for.\n\t{unsolved_str}" + ) input_specs = list(x for (x, y) in result.unsolved_specs) for spec in result.specs: diff --git a/lib/spack/spack/solver/concretize.lp b/lib/spack/spack/solver/concretize.lp index a186290824c869..ccbe6ed29b0b63 100644 --- a/lib/spack/spack/solver/concretize.lp +++ b/lib/spack/spack/solver/concretize.lp @@ -29,7 +29,6 @@ :- attr("variant_value", PackageNode, _, _), not attr("node", PackageNode). :- attr("node_flag_compiler_default", PackageNode), not attr("node", PackageNode). :- attr("node_flag", PackageNode, _, _), not attr("node", PackageNode). -:- attr("no_flags", PackageNode, _), not attr("node", PackageNode). :- attr("external_spec_selected", PackageNode, _), not attr("node", PackageNode). :- attr("depends_on", ParentNode, _, _), not attr("node", ParentNode). :- attr("depends_on", _, ChildNode, _), not attr("node", ChildNode). @@ -80,6 +79,7 @@ unification_set(SetID, VirtualNode) #defined multiple_unification_sets/1. +#defined runtime/1. %---- % Rules to break symmetry and speed-up searches @@ -126,10 +126,12 @@ trigger_node(TriggerID, Node, Node) :- trigger_condition_holds(TriggerID, Node), literal(TriggerID). -% Since we trigger the existence of literal nodes from a condition, we need to construct -% the condition_set/2 manually below +% Since we trigger the existence of literal nodes from a condition, we need to construct the condition_set/2 mentioned_in_literal(Root, Mentioned) :- mentioned_in_literal(TriggerID, Root, Mentioned), solve_literal(TriggerID). -condition_set(node(min_dupe_id, Root), node(min_dupe_id, Mentioned)) :- mentioned_in_literal(Root, Mentioned). +condition_set(node(min_dupe_id, Root), node(min_dupe_id, Root)) :- mentioned_in_literal(Root, Root). + +1 { condition_set(node(min_dupe_id, Root), node(0..Y-1, Mentioned)) : max_dupes(Mentioned, Y) } 1 :- + mentioned_in_literal(Root, Mentioned), Mentioned != Root. % Discriminate between "roots" that have been explicitly requested, and roots that are deduced from "virtual roots" explicitly_requested_root(node(min_dupe_id, Package)) :- @@ -137,6 +139,20 @@ explicitly_requested_root(node(min_dupe_id, Package)) :- trigger_and_effect(Package, TriggerID, EffectID), imposed_constraint(EffectID, "root", Package). + +% Keep track of which nodes are associated with which root DAG +associated_with_root(RootNode, RootNode) :- attr("root", RootNode). + +associated_with_root(RootNode, ChildNode) :- + depends_on(ParentNode, ChildNode), + associated_with_root(RootNode, ParentNode). + +% We cannot have a node in the root condition set, that is not associated with that root +:- attr("root", RootNode), + condition_set(RootNode, node(X, Package)), + not virtual(Package), + not associated_with_root(RootNode, node(X, Package)). + #defined concretize_everything/0. #defined literal/1. @@ -158,6 +174,14 @@ error(100, multiple_values_error, Attribute, Package) attr_single_value(Attribute), 2 { attr(Attribute, node(ID, Package), Value) }. +%----------------------------------------------------------------------------- +% Languages used +%----------------------------------------------------------------------------- + +attr("language", node(X, Package), Language) :- + condition_holds(ConditionID, node(X, Package)), + pkg_fact(Package,language(ConditionID, Language)). + %----------------------------------------------------------------------------- % Version semantics %----------------------------------------------------------------------------- @@ -231,6 +255,7 @@ possible_version_weight(node(ID, Package), Weight) :- attr("version", node(ID, Package), Version), version_weight(node(ID, Package), Weight), not pkg_fact(Package, version_declared(Version, Weight, "installed")), + not pkg_fact(Package, version_declared(Version, Weight, "installed_git_version")), not build(node(ID, Package)), internal_error("Build version weight used for reused package"). @@ -514,6 +539,12 @@ attr("virtual_on_edge", PackageNode, ProviderNode, Virtual) provider(ProviderNode, node(_, Virtual)), not external(PackageNode). +% If a virtual node is in the answer set, it must be either a virtual root, +% or used somewhere +:- attr("virtual_node", node(_, Virtual)), + not attr("virtual_on_incoming_edges", _, Virtual), + not attr("virtual_root", node(_, Virtual)). + attr("virtual_on_incoming_edges", ProviderNode, Virtual) :- attr("virtual_on_edge", _, ProviderNode, Virtual). @@ -580,25 +611,18 @@ do_not_impose(EffectID, node(X, Package)) % Virtual dependency weights %----------------------------------------------------------------------------- -% A provider may have different possible weights depending on whether it's an external -% or not, or on preferences expressed in packages.yaml etc. This rule ensures that +% A provider has different possible weights depending on its preference. This rule ensures that % we select the weight, among the possible ones, that minimizes the overall objective function. 1 { provider_weight(DependencyNode, VirtualNode, Weight) : possible_provider_weight(DependencyNode, VirtualNode, Weight, _) } 1 :- provider(DependencyNode, VirtualNode), internal_error("Package provider weights must be unique"). -% A provider that is an external can use a weight of 0 -possible_provider_weight(DependencyNode, VirtualNode, 0, "external") - :- provider(DependencyNode, VirtualNode), - external(DependencyNode). - -% A provider mentioned in the default configuration can use a weight -% according to its priority in the list of providers +% Any configured provider has a weight based on index in the preference list possible_provider_weight(node(ProviderID, Provider), node(VirtualID, Virtual), Weight, "default") :- provider(node(ProviderID, Provider), node(VirtualID, Virtual)), default_provider_preference(Virtual, Provider, Weight). -% Any provider can use 100 as a weight, which is very high and discourage its use +% Any non-configured provider has a default weight of 100 possible_provider_weight(node(ProviderID, Provider), VirtualNode, 100, "fallback") :- provider(node(ProviderID, Provider), VirtualNode). @@ -780,37 +804,6 @@ node_has_variant(node(ID, Package), Variant) :- pkg_fact(Package, variant(Variant)), attr("node", node(ID, Package)). -% Variant propagation is forwarded to dependencies -attr("variant_propagation_candidate", PackageNode, Variant, Value, Source) :- - attr("node", PackageNode), - depends_on(ParentNode, PackageNode), - attr("variant_value", node(_, Source), Variant, Value), - attr("variant_propagation_candidate", ParentNode, Variant, _, Source). - -% If the node is a candidate, and it has the variant and value, -% then those variant and value should be propagated -attr("variant_propagate", node(ID, Package), Variant, Value, Source) :- - attr("variant_propagation_candidate", node(ID, Package), Variant, Value, Source), - node_has_variant(node(ID, Package), Variant), - pkg_fact(Package, variant_possible_value(Variant, Value)), - not attr("variant_set", node(ID, Package), Variant). - -% Propagate the value, if there is the corresponding attribute -attr("variant_value", PackageNode, Variant, Value) :- attr("variant_propagate", PackageNode, Variant, Value, _). - -% If a variant is propagated, we cannot have extraneous values (this is for multi valued variants) -variant_is_propagated(PackageNode, Variant) :- attr("variant_propagate", PackageNode, Variant, _, _). -:- variant_is_propagated(PackageNode, Variant), - attr("variant_value", PackageNode, Variant, Value), - not attr("variant_propagate", PackageNode, Variant, Value, _). - -% Cannot receive different values from different sources on the same variant -error(100, "{0} and {1} cannot both propagate variant '{2}' to package {3} with values '{4}' and '{5}'", Source1, Source2, Variant, Package, Value1, Value2) :- - attr("variant_propagate", node(X, Package), Variant, Value1, Source1), - attr("variant_propagate", node(X, Package), Variant, Value2, Source2), - node_has_variant(node(X, Package), Variant), - Value1 < Value2, Source1 < Source2. - % a variant cannot be set if it is not a variant on the package error(100, "Cannot set variant '{0}' for package '{1}' because the variant condition cannot be satisfied for the given spec", Variant, Package) :- attr("variant_set", node(X, Package), Variant), @@ -876,12 +869,8 @@ error(100, "{0} variant '{1}' cannot have values '{2}' and '{3}' as they come fr Set1 < Set2, % see[1] build(node(ID, Package)). -% variant_set is an explicitly set variant value. If it's not 'set', -% we revert to the default value. If it is set, we force the set value -attr("variant_value", PackageNode, Variant, Value) - :- attr("node", PackageNode), - node_has_variant(PackageNode, Variant), - attr("variant_set", PackageNode, Variant, Value). +:- attr("variant_set", node(ID, Package), Variant, Value), + not attr("variant_value", node(ID, Package), Variant, Value). % The rules below allow us to prefer default values for variants % whenever possible. If a variant is set in a spec, or if it is @@ -892,7 +881,7 @@ variant_not_default(node(ID, Package), Variant, Value) % variants set explicitly on the CLI don't count as non-default not attr("variant_set", node(ID, Package), Variant, Value), % variant values forced by propagation don't count as non-default - not attr("variant_propagate", node(ID, Package), Variant, Value, _), + not propagate(node(ID, Package), variant_value(Variant, Value)), % variants set on externals that we could use don't count as non-default % this makes spack prefer to use an external over rebuilding with the % default configuration @@ -905,7 +894,7 @@ variant_default_not_used(node(ID, Package), Variant, Value) :- variant_default_value(Package, Variant, Value), node_has_variant(node(ID, Package), Variant), not attr("variant_value", node(ID, Package), Variant, Value), - not attr("variant_propagate", node(ID, Package), Variant, _, _), + not propagate(node(ID, Package), variant_value(Variant, _)), attr("node", node(ID, Package)). % The variant is set in an external spec @@ -962,18 +951,112 @@ pkg_fact(Package, variant_single_value("dev_path")) #defined variant_default_value/3. #defined variant_default_value_from_packages_yaml/3. +%----------------------------------------------------------------------------- +% Propagation semantics +%----------------------------------------------------------------------------- + +% Propagation roots have a corresponding attr("propagate", ...) +propagate(RootNode, PropagatedAttribute) :- attr("propagate", RootNode, PropagatedAttribute). +propagate(RootNode, PropagatedAttribute, EdgeTypes) :- attr("propagate", RootNode, PropagatedAttribute, EdgeTypes). + + +% Propagate an attribute along edges to child nodes +propagate(ChildNode, PropagatedAttribute) :- + propagate(ParentNode, PropagatedAttribute), + depends_on(ParentNode, ChildNode). + +propagate(ChildNode, PropagatedAttribute, edge_types(DepType1, DepType2)) :- + propagate(ParentNode, PropagatedAttribute, edge_types(DepType1, DepType2)), + depends_on(ParentNode, ChildNode), + 1 { attr("depends_on", ParentNode, ChildNode, DepType1); attr("depends_on", ParentNode, ChildNode, DepType2) }. + +%----------------------------------------------------------------------------- +% Activation of propagated values +%----------------------------------------------------------------------------- + +%---- +% Variants +%---- + +% If a variant is propagated, and can be accepted, set its value +attr("variant_value", node(ID, Package), Variant, Value) :- + propagate(node(ID, Package), variant_value(Variant, Value)), + node_has_variant(node(ID, Package), Variant), + pkg_fact(Package, variant_possible_value(Variant, Value)), + not attr("variant_set", node(ID, Package), Variant). + +% If a variant is propagated, we cannot have extraneous values +variant_is_propagated(PackageNode, Variant) :- + attr("variant_value", PackageNode, Variant, Value), + propagate(PackageNode, variant_value(Variant, Value)), + not attr("variant_set", PackageNode, Variant). + +:- variant_is_propagated(PackageNode, Variant), + attr("variant_value", PackageNode, Variant, Value), + not propagate(PackageNode, variant_value(Variant, Value)). + +%---- +% Flags +%---- + +% A propagated flag implies: +% 1. The same flag type is not set on this node +% 2. This node has the same compiler as the propagation source + +propagated_flag(node(PackageID, Package), node_flag(FlagType, Flag), SourceNode) :- + propagate(node(PackageID, Package), node_flag(FlagType, Flag), _), + not attr("node_flag_set", node(PackageID, Package), FlagType, _), + % Same compiler as propagation source + node_compiler(node(PackageID, Package), CompilerID), + node_compiler(SourceNode, CompilerID), + attr("propagate", SourceNode, node_flag(FlagType, Flag), _), + node(PackageID, Package) != SourceNode, + not runtime(Package). + +attr("node_flag", PackageNode, FlagType, Flag) :- propagated_flag(PackageNode, node_flag(FlagType, Flag), _). +attr("node_flag_source", PackageNode, FlagType, SourceNode) :- propagated_flag(PackageNode, node_flag(FlagType, _), SourceNode). + +% Cannot propagate the same flag from two distinct sources +error(100, "{0} and {1} cannot both propagate compiler flags '{2}' to {3}", Source1, Source2, Package, FlagType) :- + propagated_flag(node(ID, Package), node_flag(FlagType, _), node(_, Source1)), + propagated_flag(node(ID, Package), node_flag(FlagType, _), node(_, Source2)), + Source1 < Source2. + +%---- +% Compiler constraints +%---- + +attr("node_compiler_version_satisfies", node(ID, Package), Compiler, Version) :- + propagate(node(ID, Package), node_compiler_version_satisfies(Compiler, Version)), + node_compiler(node(ID, Package), CompilerID), + compiler_name(CompilerID, Compiler), + not runtime(Package), + not external(Package). + +%----------------------------------------------------------------------------- +% Runtimes +%----------------------------------------------------------------------------- + +% Check whether the DAG has any built package +has_built_packages() :- build(X), not external(X). + +% If we build packages, the runtime nodes must use an available compiler +1 { node_compiler(PackageNode, CompilerID) : build(PackageNode), not external(PackageNode) } :- + has_built_packages(), + runtime(RuntimePackage), + node_compiler(node(_, RuntimePackage), CompilerID). + %----------------------------------------------------------------------------- % Platform semantics %----------------------------------------------------------------------------- -% if no platform is set, fall back to the default -error(100, "platform '{0}' is not allowed on the current host", Platform) - :- attr("node_platform", _, Platform), not allowed_platform(Platform). +% NOTE: Currently we have a single allowed platform per DAG, therefore there is no +% need to have additional optimization criteria. If we ever add cross-platform dags, +% this needs to be changed. +:- 2 { allowed_platform(Platform) }, internal_error("More than one allowed platform detected"). -attr("node_platform", PackageNode, Platform) - :- attr("node", PackageNode), - not attr("node_platform_set", PackageNode), - node_platform_default(Platform). +1 { attr("node_platform", PackageNode, Platform) : allowed_platform(Platform) } 1 + :- attr("node", PackageNode). % setting platform on a node is a hard constraint attr("node_platform", PackageNode, Platform) @@ -997,14 +1080,6 @@ error(100, "Cannot select '{0} os={1}' (operating system '{1}' is not buildable) attr("node_os", node(X, Package), OS), not buildable_os(OS). -% can't have dependencies on incompatible OS's -error(100, "{0} and dependency {1} have incompatible operating systems 'os={2}' and 'os={3}'", Package, Dependency, PackageNodeOS, DependencyOS) - :- depends_on(node(X, Package), node(Y, Dependency)), - attr("node_os", node(X, Package), PackageNodeOS), - attr("node_os", node(Y, Dependency), DependencyOS), - not os_compatible(PackageNodeOS, DependencyOS), - build(node(X, Package)). - % give OS choice weights according to os declarations node_os_weight(PackageNode, Weight) :- attr("node", PackageNode), @@ -1017,13 +1092,6 @@ os_compatible(OS, OS) :- os(OS). % Transitive compatibility among operating systems os_compatible(OS1, OS3) :- os_compatible(OS1, OS2), os_compatible(OS2, OS3). -% We can select only operating systems compatible with the ones -% for which we can build software. We need a cardinality constraint -% since we might have more than one "buildable_os(OS)" fact. -:- not 1 { os_compatible(CurrentOS, ReusedOS) : buildable_os(CurrentOS) }, - attr("node_os", Package, ReusedOS), - internal_error("Reused OS incompatible with build OS"). - % If an OS is set explicitly respect the value attr("node_os", PackageNode, OS) :- attr("node_os_set", PackageNode, OS), attr("node", PackageNode). @@ -1071,15 +1139,26 @@ error(100, "{0} compiler '{2}@{3}' incompatible with 'target={1}'", Package, Tar compiler_version(CompilerID, Version), build(node(X, Package)). +#defined compiler_supports_target/2. +#defined compiler_available/1. + % if a target is set explicitly, respect it attr("node_target", PackageNode, Target) :- attr("node", PackageNode), attr("node_target_set", PackageNode, Target). % each node has the weight of its assigned target -node_target_weight(node(ID, Package), Weight) - :- attr("node", node(ID, Package)), - attr("node_target", node(ID, Package), Target), - target_weight(Target, Weight). +target_weight(Target, 0) + :- attr("node", PackageNode), + attr("node_target", PackageNode, Target), + attr("node_target_set", PackageNode, Target). + +node_target_weight(PackageNode, MinWeight) + :- attr("node", PackageNode), + attr("node_target", PackageNode, Target), + target(Target), + MinWeight = #min { Weight : target_weight(Target, Weight) }. + +:- attr("node_target", PackageNode, Target), not node_target_weight(PackageNode, _). % compatibility rules for targets among nodes node_target_match(ParentNode, DependencyNode) @@ -1101,7 +1180,7 @@ error(100, "'{0} target={1}' is not compatible with this machine", Package, Targ % Compiler semantics %----------------------------------------------------------------------------- % There must be only one compiler set per built node. -{ node_compiler(PackageNode, CompilerID) : compiler_id(CompilerID) } :- +{ node_compiler(PackageNode, CompilerID) : compiler_id(CompilerID), compiler_available(CompilerID) } :- attr("node", PackageNode), build(PackageNode). @@ -1118,6 +1197,7 @@ attr("node_compiler_version", PackageNode, CompilerName, CompilerVersion) :- node_compiler(PackageNode, CompilerID), compiler_name(CompilerID, CompilerName), compiler_version(CompilerID, CompilerVersion), + compiler_available(CompilerID), build(PackageNode). attr("node_compiler", PackageNode, CompilerName) @@ -1140,12 +1220,12 @@ error(10, "No valid compiler for {0} satisfies '%{1}'", Package, Compiler) % If the compiler of a node must satisfy a constraint, then its version % must be chosen among the ones that satisfy said constraint -error(100, "No valid version for '{0}' compiler '{1}' satisfies '@{2}'", Package, Compiler, Constraint) +error(100, "Package {0} cannot satisfy '%{1}@{2}'", Package, Compiler, Constraint) :- attr("node", node(X, Package)), attr("node_compiler_version_satisfies", node(X, Package), Compiler, Constraint), - not compiler_version_satisfies(Compiler, Constraint, _). + not compiler_version_satisfies(Compiler, Constraint, _). -error(100, "No valid version for '{0}' compiler '{1}' satisfies '@{2}'", Package, Compiler, Constraint) +error(100, "Package {0} cannot satisfy '%{1}@{2}'", Package, Compiler, Constraint) :- attr("node", node(X, Package)), attr("node_compiler_version_satisfies", node(X, Package), Compiler, Constraint), not compiler_version_satisfies(Compiler, Constraint, ID), @@ -1178,8 +1258,8 @@ error(100, "{0} compiler '%{1}@{2}' incompatible with 'os={3}'", Package, Compil node_compiler(node(X, Package), CompilerID), compiler_name(CompilerID, Compiler), compiler_version(CompilerID, Version), - not compiler_os(CompilerID, OS), - not allow_compiler(Compiler, Version), + compiler_os(CompilerID, CompilerOS), + not os_compatible(CompilerOS, OS), build(node(X, Package)). % If a package and one of its dependencies don't have the @@ -1200,7 +1280,6 @@ compiler_mismatch_required(PackageNode, DependencyNode) not compiler_match(PackageNode, DependencyNode). #defined compiler_os/3. -#defined allow_compiler/2. % compilers weighted by preference according to packages.yaml node_compiler_weight(node(ID, Package), Weight) @@ -1227,45 +1306,9 @@ error(100, "Compiler {1}@{2} requested for {0} cannot be found. Set install_miss % Compiler flags %----------------------------------------------------------------------------- -% propagate flags when compiler match -can_inherit_flags(PackageNode, DependencyNode, FlagType) - :- same_compiler(PackageNode, DependencyNode), - not attr("node_flag_set", DependencyNode, FlagType, _), - flag_type(FlagType). - -same_compiler(PackageNode, DependencyNode) - :- depends_on(PackageNode, DependencyNode), - node_compiler(PackageNode, CompilerID), - node_compiler(DependencyNode, CompilerID), - compiler_id(CompilerID). - -node_flag_inherited(DependencyNode, FlagType, Flag) - :- attr("node_flag_set", PackageNode, FlagType, Flag), - can_inherit_flags(PackageNode, DependencyNode, FlagType), - attr("node_flag_propagate", PackageNode, FlagType). - -% Ensure propagation -:- node_flag_inherited(PackageNode, FlagType, Flag), - can_inherit_flags(PackageNode, DependencyNode, FlagType), - attr("node_flag_propagate", PackageNode, FlagType). - -error(100, "{0} and {1} cannot both propagate compiler flags '{2}' to {3}", Source1, Source2, Package, FlagType) :- - depends_on(Source1, Package), - depends_on(Source2, Package), - attr("node_flag_propagate", Source1, FlagType), - attr("node_flag_propagate", Source2, FlagType), - can_inherit_flags(Source1, Package, FlagType), - can_inherit_flags(Source2, Package, FlagType), - Source1 < Source2. - % remember where flags came from -attr("node_flag_source", PackageNode, FlagType, PackageNode) - :- attr("node_flag_set", PackageNode, FlagType, _). - -attr("node_flag_source", DependencyNode, FlagType, Q) - :- attr("node_flag_source", PackageNode, FlagType, Q), - node_flag_inherited(DependencyNode, FlagType, _), - attr("node_flag_propagate", PackageNode, FlagType). +attr("node_flag_source", PackageNode, FlagType, PackageNode) :- attr("node_flag_set", PackageNode, FlagType, _). +attr("node_flag_source", PackageNode, FlagType, PackageNode) :- attr("node_flag", PackageNode, FlagType, _), attr("hash", PackageNode, _). % compiler flags from compilers.yaml are put on nodes if compiler matches attr("node_flag", PackageNode, FlagType, Flag) @@ -1285,15 +1328,8 @@ attr("node_flag_compiler_default", PackageNode) compiler_name(CompilerID, CompilerName), compiler_version(CompilerID, Version). -% if a flag is set to something or inherited, it's included +% Flag set to something attr("node_flag", PackageNode, FlagType, Flag) :- attr("node_flag_set", PackageNode, FlagType, Flag). -attr("node_flag", PackageNode, FlagType, Flag) :- node_flag_inherited(PackageNode, FlagType, Flag). - -% if no node flags are set for a type, there are no flags. -attr("no_flags", PackageNode, FlagType) - :- not attr("node_flag", PackageNode, FlagType, _), - attr("node", PackageNode), - flag_type(FlagType). #defined compiler_flag/3. @@ -1331,8 +1367,10 @@ build(PackageNode) :- not attr("hash", PackageNode, _), attr("node", PackageNode % topmost-priority criterion to reuse what is installed. % % The priority ranges are: -% 200+ Shifted priorities for build nodes; correspond to priorities 0 - 99. -% 100 - 199 Unshifted priorities. Currently only includes minimizing #builds. +% 1000+ Optimizations for concretization errors +% 300 - 1000 Highest priority optimizations for valid solutions +% 200 - 299 Shifted priorities for build nodes; correspond to priorities 0 - 99. +% 100 - 199 Unshifted priorities. Currently only includes minimizing #builds and minimizing dupes. % 0 - 99 Priorities for non-built nodes. build_priority(PackageNode, 200) :- build(PackageNode), attr("node", PackageNode). build_priority(PackageNode, 0) :- not build(PackageNode), attr("node", PackageNode). @@ -1380,6 +1418,16 @@ build_priority(PackageNode, 0) :- not build(PackageNode), attr("node", Package % 2. a `#minimize{ 0@2 : #true }.` statement that ensures the criterion % is displayed (clingo doesn't display sums over empty sets by default) +% A condition group specifies one or more specs that must be satisfied. +% Specs declared first are preferred, so we assign increasing weights and +% minimize the weights. +opt_criterion(310, "requirement weight"). +#minimize{ 0@310: #true }. +#minimize { + Weight@310,PackageNode,Group + : requirement_weight(PackageNode, Group, Weight) +}. + % Try hard to reuse installed packages (i.e., minimize the number built) opt_criterion(110, "number of packages to build (vs. reuse)"). #minimize { 0@110: #true }. @@ -1391,18 +1439,6 @@ opt_criterion(100, "number of nodes from the same package"). #minimize { ID@100,Package : attr("virtual_node", node(ID, Package)) }. #defined optimize_for_reuse/0. -% A condition group specifies one or more specs that must be satisfied. -% Specs declared first are preferred, so we assign increasing weights and -% minimize the weights. -opt_criterion(75, "requirement weight"). -#minimize{ 0@275: #true }. -#minimize{ 0@75: #true }. -#minimize { - Weight@75+Priority,PackageNode,Group - : requirement_weight(PackageNode, Group, Weight), - build_priority(PackageNode, Priority) -}. - % Minimize the number of deprecated versions being used opt_criterion(73, "deprecated versions used"). #minimize{ 0@273: #true }. @@ -1410,6 +1446,7 @@ opt_criterion(73, "deprecated versions used"). #minimize{ 1@73+Priority,PackageNode : attr("deprecated", PackageNode, _), + not external(PackageNode), build_priority(PackageNode, Priority) }. @@ -1417,11 +1454,11 @@ opt_criterion(73, "deprecated versions used"). % 1. Version weight % 2. Number of variants with a non default value, if not set % for the root package. -opt_criterion(70, "version weight"). +opt_criterion(70, "version badness (roots)"). #minimize{ 0@270: #true }. #minimize{ 0@70: #true }. #minimize { - Weight@70+Priority + Weight@70+Priority,PackageNode : attr("root", PackageNode), version_weight(PackageNode, Weight), build_priority(PackageNode, Priority) @@ -1481,22 +1518,24 @@ opt_criterion(45, "preferred providers (non-roots)"). }. % Try to minimize the number of compiler mismatches in the DAG. -opt_criterion(40, "compiler mismatches that are not from CLI"). +opt_criterion(40, "compiler mismatches that are not required"). #minimize{ 0@240: #true }. #minimize{ 0@40: #true }. #minimize{ - 1@40+Priority,PackageNode,DependencyNode - : compiler_mismatch(PackageNode, DependencyNode), - build_priority(PackageNode, Priority) + 1@40+Priority,PackageNode,node(ID, Dependency) + : compiler_mismatch(PackageNode, node(ID, Dependency)), + build_priority(node(ID, Dependency), Priority), + not runtime(Dependency) }. -opt_criterion(39, "compiler mismatches that are not from CLI"). +opt_criterion(39, "compiler mismatches that are required"). #minimize{ 0@239: #true }. #minimize{ 0@39: #true }. #minimize{ - 1@39+Priority,PackageNode,DependencyNode - : compiler_mismatch_required(PackageNode, DependencyNode), - build_priority(PackageNode, Priority) + 1@39+Priority,PackageNode,node(ID, Dependency) + : compiler_mismatch_required(PackageNode, node(ID, Dependency)), + build_priority(node(ID, Dependency), Priority), + not runtime(Dependency) }. opt_criterion(30, "non-preferred OS's"). @@ -1509,13 +1548,15 @@ opt_criterion(30, "non-preferred OS's"). }. % Choose more recent versions for nodes -opt_criterion(25, "version badness"). +opt_criterion(25, "version badness (non roots)"). #minimize{ 0@225: #true }. #minimize{ 0@25: #true }. #minimize{ - Weight@25+Priority,PackageNode - : version_weight(PackageNode, Weight), - build_priority(PackageNode, Priority) + Weight@25+Priority,node(X, Package) + : version_weight(node(X, Package), Weight), + build_priority(node(X, Package), Priority), + not attr("root", node(X, Package)), + not runtime(Package) }. % Try to use all the default values of variants @@ -1534,9 +1575,10 @@ opt_criterion(15, "non-preferred compilers"). #minimize{ 0@215: #true }. #minimize{ 0@15: #true }. #minimize{ - Weight@15+Priority,PackageNode - : node_compiler_weight(PackageNode, Weight), - build_priority(PackageNode, Priority) + Weight@15+Priority,node(X, Package) + : node_compiler_weight(node(X, Package), Weight), + build_priority(node(X, Package), Priority), + not runtime(Package) }. % Minimize the number of mismatches for targets in the DAG, try @@ -1545,18 +1587,55 @@ opt_criterion(10, "target mismatches"). #minimize{ 0@210: #true }. #minimize{ 0@10: #true }. #minimize{ - 1@10+Priority,PackageNode,Dependency - : node_target_mismatch(PackageNode, Dependency), - build_priority(PackageNode, Priority) + 1@10+Priority,PackageNode,node(ID, Dependency) + : node_target_mismatch(PackageNode, node(ID, Dependency)), + build_priority(node(ID, Dependency), Priority), + not runtime(Dependency) }. opt_criterion(5, "non-preferred targets"). #minimize{ 0@205: #true }. #minimize{ 0@5: #true }. #minimize{ - Weight@5+Priority,PackageNode - : node_target_weight(PackageNode, Weight), - build_priority(PackageNode, Priority) + Weight@5+Priority,node(X, Package) + : node_target_weight(node(X, Package), Weight), + build_priority(node(X, Package), Priority), + not runtime(Package) +}. + + +% Minimize the number of compiler mismatches for runtimes +opt_criterion(4, "compiler mismatches (runtimes)"). +#minimize{ 0@204: #true }. +#minimize{ 0@4: #true }. +#minimize{ + 1@4,PackageNode,node(ID, Dependency) + : compiler_mismatch(PackageNode, node(ID, Dependency)), runtime(Dependency) +}. +#minimize{ + 1@4,PackageNode,node(ID, Dependency) + : compiler_mismatch_required(PackageNode, node(ID, Dependency)), runtime(Dependency) +}. + + +% Choose more recent versions for runtimes +opt_criterion(3, "version badness (runtimes)"). +#minimize{ 0@203: #true }. +#minimize{ 0@3: #true }. +#minimize{ + Weight@3,node(X, Package) + : version_weight(node(X, Package), Weight), + runtime(Package) +}. + +% Choose best target for runtimes +opt_criterion(2, "non-preferred targets (runtimes)"). +#minimize{ 0@202: #true }. +#minimize{ 0@2: #true }. +#minimize{ + Weight@2,node(X, Package) + : node_target_weight(node(X, Package), Weight), + runtime(Package) }. % Choose more recent versions for nodes diff --git a/lib/spack/spack/solver/core.py b/lib/spack/spack/solver/core.py index 13a3af2cd103b5..896631290c5ce2 100644 --- a/lib/spack/spack/solver/core.py +++ b/lib/spack/spack/solver/core.py @@ -195,7 +195,7 @@ def _bootstrap_clingo() -> ModuleType: import spack.bootstrap with spack.bootstrap.ensure_bootstrap_configuration(): - spack.bootstrap.ensure_core_dependencies() + spack.bootstrap.ensure_clingo_importable_or_raise() clingo_mod = importlib.import_module("clingo") return clingo_mod diff --git a/lib/spack/spack/solver/counter.py b/lib/spack/spack/solver/counter.py index 72bff5f5bf23f4..8da8aa1b4e152e 100644 --- a/lib/spack/spack/solver/counter.py +++ b/lib/spack/spack/solver/counter.py @@ -10,6 +10,7 @@ import spack.deptypes as dt import spack.package_base import spack.repo +import spack.spec PossibleDependencies = Set[str] @@ -24,7 +25,13 @@ class Counter: """ def __init__(self, specs: List["spack.spec.Spec"], tests: bool) -> None: - self.specs = specs + runtime_pkgs = spack.repo.PATH.packages_with_tags("runtime") + runtime_virtuals = set() + for x in runtime_pkgs: + pkg_class = spack.repo.PATH.get_pkg_class(x) + runtime_virtuals.update(pkg_class.provided_virtual_names()) + + self.specs = specs + [spack.spec.Spec(x) for x in runtime_pkgs] self.link_run_types: dt.DepFlag = dt.LINK | dt.RUN | dt.TEST self.all_types: dt.DepFlag = dt.ALL @@ -33,7 +40,9 @@ def __init__(self, specs: List["spack.spec.Spec"], tests: bool) -> None: self.all_types = dt.LINK | dt.RUN | dt.BUILD self._possible_dependencies: PossibleDependencies = set() - self._possible_virtuals: Set[str] = set(x.name for x in specs if x.virtual) + self._possible_virtuals: Set[str] = ( + set(x.name for x in specs if x.virtual) | runtime_virtuals + ) def possible_dependencies(self) -> PossibleDependencies: """Returns the list of possible dependencies""" diff --git a/lib/spack/spack/solver/heuristic.lp b/lib/spack/spack/solver/heuristic.lp index 71ed64b3f88690..a5d6767ff2b1b4 100644 --- a/lib/spack/spack/solver/heuristic.lp +++ b/lib/spack/spack/solver/heuristic.lp @@ -4,21 +4,35 @@ % SPDX-License-Identifier: (Apache-2.0 OR MIT) %============================================================================= -% Heuristic to speed-up solves (node with ID 0) +% Heuristic to speed-up solves %============================================================================= +% No duplicates by default (most of them will be true) +#heuristic attr("node", node(PackageID, Package)). [100, init] +#heuristic attr("node", node(PackageID, Package)). [ 2, factor] +#heuristic attr("virtual_node", node(VirtualID, Virtual)). [100, init] +#heuristic attr("node", node(1..X-1, Package)) : max_dupes(Package, X), not virtual(Package), X > 1. [-1, sign] +#heuristic attr("virtual_node", node(1..X-1, Package)) : max_dupes(Package, X), virtual(Package) , X > 1. [-1, sign] -%----------------- -% Domain heuristic -%----------------- +% Pick preferred version +#heuristic attr("version", node(PackageID, Package), Version) : pkg_fact(Package, version_declared(Version, Weight)), attr("node", node(PackageID, Package)). [40, init] +#heuristic version_weight(node(PackageID, Package), 0) : pkg_fact(Package, version_declared(Version, 0 )), attr("node", node(PackageID, Package)). [ 1, sign] +#heuristic attr("version", node(PackageID, Package), Version) : pkg_fact(Package, version_declared(Version, 0 )), attr("node", node(PackageID, Package)). [ 1, sign] +#heuristic attr("version", node(PackageID, Package), Version) : pkg_fact(Package, version_declared(Version, Weight)), attr("node", node(PackageID, Package)), Weight > 0. [-1, sign] -% Root node -#heuristic attr("version", node(0, Package), Version) : pkg_fact(Package, version_declared(Version, 0)), attr("root", node(0, Package)). [35, true] -#heuristic version_weight(node(0, Package), 0) : pkg_fact(Package, version_declared(Version, 0)), attr("root", node(0, Package)). [35, true] -#heuristic attr("variant_value", node(0, Package), Variant, Value) : variant_default_value(Package, Variant, Value), attr("root", node(0, Package)). [35, true] -#heuristic attr("node_target", node(0, Package), Target) : target_weight(Target, 0), attr("root", node(0, Package)). [35, true] -#heuristic node_target_weight(node(0, Package), 0) : attr("root", node(0, Package)). [35, true] -#heuristic node_compiler(node(0, Package), CompilerID) : compiler_weight(ID, 0), compiler_id(ID), attr("root", node(0, Package)). [35, true] +% Use default variants +#heuristic attr("variant_value", node(PackageID, Package), Variant, Value) : variant_default_value(Package, Variant, Value), attr("node", node(PackageID, Package)). [40, true] +#heuristic attr("variant_value", node(PackageID, Package), Variant, Value) : not variant_default_value(Package, Variant, Value), attr("node", node(PackageID, Package)). [40, false] -% Providers -#heuristic attr("node", node(0, Package)) : default_provider_preference(Virtual, Package, 0), possible_in_link_run(Package). [30, true] +% Use default operating system and platform +#heuristic attr("node_os", node(PackageID, Package), OS) : os(OS, 0), attr("root", node(PackageID, Package)). [40, true] +#heuristic attr("node_platform", node(PackageID, Package), Platform) : allowed_platform(Platform), attr("root", node(PackageID, Package)). [40, true] + +% Use default targets +#heuristic attr("node_target", node(PackageID, Package), Target) : target_weight(Target, Weight), attr("node", node(PackageID, Package)). [30, init] +#heuristic attr("node_target", node(PackageID, Package), Target) : target_weight(Target, Weight), attr("node", node(PackageID, Package)). [ 2, factor] +#heuristic attr("node_target", node(PackageID, Package), Target) : target_weight(Target, 0), attr("node", node(PackageID, Package)). [ 1, sign] +#heuristic attr("node_target", node(PackageID, Package), Target) : target_weight(Target, Weight), attr("node", node(PackageID, Package)), Weight > 0. [-1, sign] + +% Use the default compilers +#heuristic node_compiler(node(PackageID, Package), ID) : compiler_weight(ID, 0), compiler_id(ID), attr("node", node(PackageID, Package)). [30, init] diff --git a/lib/spack/spack/solver/heuristic_separate.lp b/lib/spack/spack/solver/heuristic_separate.lp deleted file mode 100644 index 2b499d07984568..00000000000000 --- a/lib/spack/spack/solver/heuristic_separate.lp +++ /dev/null @@ -1,24 +0,0 @@ -% Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -% Spack Project Developers. See the top-level COPYRIGHT file for details. -% -% SPDX-License-Identifier: (Apache-2.0 OR MIT) - -%============================================================================= -% Heuristic to speed-up solves (node with ID > 0) -%============================================================================= - -% node(ID, _) -#heuristic attr("version", node(ID, Package), Version) : pkg_fact(Package, version_declared(Version, 0)), attr("node", node(ID, Package)), ID > 0. [25-5*ID, true] -#heuristic version_weight(node(ID, Package), 0) : pkg_fact(Package, version_declared(Version, 0)), attr("node", node(ID, Package)), ID > 0. [25-5*ID, true] -#heuristic attr("variant_value", node(ID, Package), Variant, Value) : variant_default_value(Package, Variant, Value), attr("node", node(ID, Package)), ID > 0. [25-5*ID, true] -#heuristic attr("node_target", node(ID, Package), Target) : pkg_fact(Package, target_weight(Target, 0)), attr("node", node(ID, Package)), ID > 0. [25-5*ID, true] -#heuristic node_target_weight(node(ID, Package), 0) : attr("node", node(ID, Package)), ID > 0. [25-5*ID, true] -#heuristic node_compiler(node(ID, Package), CompilerID) : compiler_weight(CompilerID, 0), compiler_id(CompilerID), attr("node", node(ID, Package)), ID > 0. [25-5*ID, true] - -% node(ID, _), split build dependencies -#heuristic attr("version", node(ID, Package), Version) : pkg_fact(Package, version_declared(Version, 0)), attr("node", node(ID, Package)), multiple_unification_sets(Package), ID > 0. [25, true] -#heuristic version_weight(node(ID, Package), 0) : pkg_fact(Package, version_declared(Version, 0)), attr("node", node(ID, Package)), multiple_unification_sets(Package), ID > 0. [25, true] -#heuristic attr("variant_value", node(ID, Package), Variant, Value) : variant_default_value(Package, Variant, Value), attr("node", node(ID, Package)), multiple_unification_sets(Package), ID > 0. [25, true] -#heuristic attr("node_target", node(ID, Package), Target) : pkg_fact(Package, target_weight(Target, 0)), attr("node", node(ID, Package)), multiple_unification_sets(Package), ID > 0. [25, true] -#heuristic node_target_weight(node(ID, Package), 0) : attr("node", node(ID, Package)), multiple_unification_sets(Package), ID > 0. [25, true] -#heuristic node_compiler(node(ID, Package), CompilerID) : compiler_weight(CompilerID, 0), compiler_id(CompilerID), attr("node", node(ID, Package)), multiple_unification_sets(Package), ID > 0. [25, true] diff --git a/lib/spack/spack/solver/libc_compatibility.lp b/lib/spack/spack/solver/libc_compatibility.lp new file mode 100644 index 00000000000000..e9d90c52ac0fb1 --- /dev/null +++ b/lib/spack/spack/solver/libc_compatibility.lp @@ -0,0 +1,43 @@ +% Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +% Spack Project Developers. See the top-level COPYRIGHT file for details. +% +% SPDX-License-Identifier: (Apache-2.0 OR MIT) + +%============================================================================= +% Libc compatibility rules for reusing solves. +% +% These rules are used on Linux +%============================================================================= + +% A package cannot be reused if the libc is not compatible with it +error(100, "Cannot reuse {0} since we cannot determine libc compatibility", ReusedPackage) + :- provider(node(X, LibcPackage), node(0, "libc")), + attr("version", node(X, LibcPackage), LibcVersion), + attr("hash", node(R, ReusedPackage), Hash), + % Libc packages can be reused without the "compatible_libc" attribute + ReusedPackage != LibcPackage, + not attr("compatible_libc", node(R, ReusedPackage), LibcPackage, LibcVersion). + +% A libc is needed in the DAG +:- has_built_packages(), not provider(_, node(0, "libc")). + +% Non-libc reused specs must be host libc compatible. In case we build packages, we get a +% host compatible libc provider from other rules. If nothing is built, there is no libc provider, +% since it's pruned from reusable specs, meaning we have to explicitly impose reused specs are host +% compatible. +:- attr("hash", node(R, ReusedPackage), Hash), + not provider(node(R, ReusedPackage), node(0, "libc")), + not attr("compatible_libc", node(R, ReusedPackage), _, _). + +% The libc provider must be one that a compiler can target +:- has_built_packages(), + provider(node(X, LibcPackage), node(0, "libc")), + attr("node", node(X, LibcPackage)), + attr("version", node(X, LibcPackage), LibcVersion), + not host_libc(LibcPackage, LibcVersion). + +% A built node must depend on libc +:- build(PackageNode), + provider(LibcNode, node(0, "libc")), + not external(PackageNode), + not depends_on(PackageNode, LibcNode). diff --git a/lib/spack/spack/solver/os_compatibility.lp b/lib/spack/spack/solver/os_compatibility.lp index 2ed8a15388ecc8..f711860d7701c4 100644 --- a/lib/spack/spack/solver/os_compatibility.lp +++ b/lib/spack/spack/solver/os_compatibility.lp @@ -7,21 +7,27 @@ % OS compatibility rules for reusing solves. % os_compatible(RecentOS, OlderOS) % OlderOS binaries can be used on RecentOS +% +% These rules are used on every platform, but Linux %============================================================================= % macOS +os_compatible("sequoia", "sonoma"). +os_compatible("sonoma", "ventura"). +os_compatible("ventura", "monterey"). os_compatible("monterey", "bigsur"). os_compatible("bigsur", "catalina"). -% Ubuntu -os_compatible("ubuntu22.04", "ubuntu21.10"). -os_compatible("ubuntu21.10", "ubuntu21.04"). -os_compatible("ubuntu21.04", "ubuntu20.10"). -os_compatible("ubuntu20.10", "ubuntu20.04"). -os_compatible("ubuntu20.04", "ubuntu19.10"). -os_compatible("ubuntu19.10", "ubuntu19.04"). -os_compatible("ubuntu19.04", "ubuntu18.10"). -os_compatible("ubuntu18.10", "ubuntu18.04"). +% can't have dependencies on incompatible OS's +error(100, "{0} and dependency {1} have incompatible operating systems 'os={2}' and 'os={3}'", Package, Dependency, PackageNodeOS, DependencyOS) + :- depends_on(node(X, Package), node(Y, Dependency)), + attr("node_os", node(X, Package), PackageNodeOS), + attr("node_os", node(Y, Dependency), DependencyOS), + not os_compatible(PackageNodeOS, DependencyOS), + build(node(X, Package)). -%EL8 -os_compatible("rhel8", "rocky8"). +% We can select only operating systems compatible with the ones +% for which we can build software. We need a cardinality constraint +% since we might have more than one "buildable_os(OS)" fact. +:- not 1 { os_compatible(CurrentOS, ReusedOS) : buildable_os(CurrentOS) }, + attr("node_os", Package, ReusedOS). diff --git a/lib/spack/spack/spec.py b/lib/spack/spack/spec.py index 53d2dc6b050f60..d35163c638ad87 100644 --- a/lib/spack/spack/spec.py +++ b/lib/spack/spack/spec.py @@ -51,7 +51,6 @@ import collections import collections.abc import enum -import io import itertools import os import pathlib @@ -59,7 +58,7 @@ import re import socket import warnings -from typing import Any, Callable, Dict, List, Optional, Set, Tuple, Union +from typing import Any, Callable, Dict, List, Match, Optional, Set, Tuple, Union import llnl.path import llnl.string @@ -121,36 +120,44 @@ "SpecDeprecatedError", ] + +SPEC_FORMAT_RE = re.compile( + r"(?:" # this is one big or, with matches ordered by priority + # OPTION 1: escaped character (needs to be first to catch opening \{) + # Note that an unterminated \ at the end of a string is left untouched + r"(?:\\(.))" + r"|" # or + # OPTION 2: an actual format string + r"{" # non-escaped open brace { + r"([%@/]|arch=)?" # optional sigil (to print sigil in color) + r"(?:\^([^}\.]+)\.)?" # optional ^depname. (to get attr from dependency) + # after the sigil or depname, we can have a hash expression or another attribute + r"(?:" # one of + r"(hash\b)(?:\:(\d+))?" # hash followed by : + r"|" # or + r"([^}]*)" # another attribute to format + r")" # end one of + r"(})?" # finish format string with non-escaped close brace }, or missing if not present + r"|" + # OPTION 3: mismatched close brace (option 2 would consume a matched open brace) + r"(})" # brace + r")", + re.IGNORECASE, +) + #: Valid pattern for an identifier in Spack IDENTIFIER_RE = r"\w[\w-]*" +# Coloring of specs when using color output. Fields are printed with +# different colors to enhance readability. +# See llnl.util.tty.color for descriptions of the color codes. COMPILER_COLOR = "@g" #: color for highlighting compilers VERSION_COLOR = "@c" #: color for highlighting versions ARCHITECTURE_COLOR = "@m" #: color for highlighting architectures -ENABLED_VARIANT_COLOR = "@B" #: color for highlighting enabled variants -DISABLED_VARIANT_COLOR = "r" #: color for highlighting disabled varaints -DEPENDENCY_COLOR = "@." #: color for highlighting dependencies +VARIANT_COLOR = "@B" #: color for highlighting variants HASH_COLOR = "@K" #: color for highlighting package hashes -#: This map determines the coloring of specs when using color output. -#: We make the fields different colors to enhance readability. -#: See llnl.util.tty.color for descriptions of the color codes. -COLOR_FORMATS = { - "%": COMPILER_COLOR, - "@": VERSION_COLOR, - "=": ARCHITECTURE_COLOR, - "+": ENABLED_VARIANT_COLOR, - "~": DISABLED_VARIANT_COLOR, - "^": DEPENDENCY_COLOR, - "#": HASH_COLOR, -} - -#: Regex used for splitting by spec field separators. -#: These need to be escaped to avoid metacharacters in -#: ``COLOR_FORMATS.keys()``. -_SEPARATORS = "[\\%s]" % "\\".join(COLOR_FORMATS.keys()) - #: Default format for Spec.format(). This format can be round-tripped, so that: #: Spec(Spec("string").format()) == Spec("string)" DEFAULT_FORMAT = ( @@ -193,26 +200,7 @@ class InstallStatus(enum.Enum): missing = "@r{[-]} " -def colorize_spec(spec): - """Returns a spec colorized according to the colors specified in - COLOR_FORMATS.""" - - class insert_color: - def __init__(self): - self.last = None - - def __call__(self, match): - # ignore compiler versions (color same as compiler) - sep = match.group(0) - if self.last == "%" and sep == "@": - return clr.cescape(sep) - self.last = sep - - return "%s%s" % (COLOR_FORMATS[sep], clr.cescape(sep)) - - return clr.colorize(re.sub(_SEPARATORS, insert_color(), str(spec)) + "@.") - - +# regexes used in spec formatting OLD_STYLE_FMT_RE = re.compile(r"\${[A-Z]+}") @@ -911,6 +899,9 @@ def flags(): yield flags def __str__(self): + if not self: + return "" + sorted_items = sorted((k, v) for k, v in self.items() if v) result = "" @@ -1039,16 +1030,13 @@ def clear(self): self.edges.clear() -def _command_default_handler(descriptor, spec, cls): +def _command_default_handler(spec: "Spec"): """Default handler when looking for the 'command' attribute. Tries to search for ``spec.name`` in the ``spec.home.bin`` directory. Parameters: - descriptor (ForwardQueryToPackage): descriptor that triggered the call - spec (Spec): spec that is being queried - cls (type(spec)): type of spec, to match the signature of the - descriptor ``__get__`` method + spec: spec that is being queried Returns: Executable: An executable of the command @@ -1061,22 +1049,17 @@ def _command_default_handler(descriptor, spec, cls): if fs.is_exe(path): return spack.util.executable.Executable(path) - else: - msg = "Unable to locate {0} command in {1}" - raise RuntimeError(msg.format(spec.name, home.bin)) + raise RuntimeError(f"Unable to locate {spec.name} command in {home.bin}") -def _headers_default_handler(descriptor, spec, cls): +def _headers_default_handler(spec: "Spec"): """Default handler when looking for the 'headers' attribute. Tries to search for ``*.h`` files recursively starting from ``spec.package.home.include``. Parameters: - descriptor (ForwardQueryToPackage): descriptor that triggered the call - spec (Spec): spec that is being queried - cls (type(spec)): type of spec, to match the signature of the - descriptor ``__get__`` method + spec: spec that is being queried Returns: HeaderList: The headers in ``prefix.include`` @@ -1089,12 +1072,10 @@ def _headers_default_handler(descriptor, spec, cls): if headers: return headers - else: - msg = "Unable to locate {0} headers in {1}" - raise spack.error.NoHeadersError(msg.format(spec.name, home)) + raise spack.error.NoHeadersError(f"Unable to locate {spec.name} headers in {home}") -def _libs_default_handler(descriptor, spec, cls): +def _libs_default_handler(spec: "Spec"): """Default handler when looking for the 'libs' attribute. Tries to search for ``lib{spec.name}`` recursively starting from @@ -1102,10 +1083,7 @@ def _libs_default_handler(descriptor, spec, cls): ``{spec.name}`` instead. Parameters: - descriptor (ForwardQueryToPackage): descriptor that triggered the call - spec (Spec): spec that is being queried - cls (type(spec)): type of spec, to match the signature of the - descriptor ``__get__`` method + spec: spec that is being queried Returns: LibraryList: The libraries found @@ -1144,27 +1122,33 @@ def _libs_default_handler(descriptor, spec, cls): if libs: return libs - msg = "Unable to recursively locate {0} libraries in {1}" - raise spack.error.NoLibrariesError(msg.format(spec.name, home)) + raise spack.error.NoLibrariesError( + f"Unable to recursively locate {spec.name} libraries in {home}" + ) class ForwardQueryToPackage: """Descriptor used to forward queries from Spec to Package""" - def __init__(self, attribute_name, default_handler=None): + def __init__( + self, + attribute_name: str, + default_handler: Optional[Callable[["Spec"], Any]] = None, + _indirect: bool = False, + ) -> None: """Create a new descriptor. Parameters: - attribute_name (str): name of the attribute to be - searched for in the Package instance - default_handler (callable, optional): default function to be - called if the attribute was not found in the Package - instance + attribute_name: name of the attribute to be searched for in the Package instance + default_handler: default function to be called if the attribute was not found in the + Package instance + _indirect: temporarily added to redirect a query to another package. """ self.attribute_name = attribute_name self.default = default_handler + self.indirect = _indirect - def __get__(self, instance, cls): + def __get__(self, instance: "SpecBuildInterface", cls): """Retrieves the property from Package using a well defined chain of responsibility. @@ -1186,13 +1170,18 @@ def __get__(self, instance, cls): indicating a query failure, e.g. that library files were not found in a 'libs' query. """ - pkg = instance.package + # TODO: this indirection exist solely for `spec["python"].command` to actually return + # spec["python-venv"].command. It should be removed when `python` is a virtual. + if self.indirect and instance.indirect_spec: + pkg = instance.indirect_spec.package + else: + pkg = instance.wrapped_obj.package try: query = instance.last_query except AttributeError: # There has been no query yet: this means # a spec is trying to access its own attributes - _ = instance[instance.name] # NOQA: ignore=F841 + _ = instance.wrapped_obj[instance.wrapped_obj.name] # NOQA: ignore=F841 query = instance.last_query callbacks_chain = [] @@ -1204,7 +1193,8 @@ def __get__(self, instance, cls): callbacks_chain.append(lambda: getattr(pkg, self.attribute_name)) # Final resort : default callback if self.default is not None: - callbacks_chain.append(lambda: self.default(self, instance, cls)) + _default = self.default # make mypy happy + callbacks_chain.append(lambda: _default(instance.wrapped_obj)) # Trigger the callbacks in order, the first one producing a # value wins @@ -1263,25 +1253,33 @@ def __set__(self, instance, value): class SpecBuildInterface(lang.ObjectWrapper): # home is available in the base Package so no default is needed home = ForwardQueryToPackage("home", default_handler=None) - - command = ForwardQueryToPackage("command", default_handler=_command_default_handler) - headers = ForwardQueryToPackage("headers", default_handler=_headers_default_handler) - libs = ForwardQueryToPackage("libs", default_handler=_libs_default_handler) + command = ForwardQueryToPackage( + "command", default_handler=_command_default_handler, _indirect=True + ) - def __init__(self, spec, name, query_parameters): + def __init__(self, spec: "Spec", name: str, query_parameters: List[str], _parent: "Spec"): super().__init__(spec) # Adding new attributes goes after super() call since the ObjectWrapper # resets __dict__ to behave like the passed object original_spec = getattr(spec, "wrapped_obj", spec) self.wrapped_obj = original_spec - self.token = original_spec, name, query_parameters + self.token = original_spec, name, query_parameters, _parent is_virtual = spack.repo.PATH.is_virtual(name) self.last_query = QueryState( name=name, extra_parameters=query_parameters, isvirtual=is_virtual ) + # TODO: this ad-hoc logic makes `spec["python"].command` return + # `spec["python-venv"].command` and should be removed when `python` is a virtual. + self.indirect_spec = None + if spec.name == "python": + python_venvs = _parent.dependencies("python-venv") + if not python_venvs: + return + self.indirect_spec = python_venvs[0] + def __reduce__(self): return SpecBuildInterface, self.token @@ -1289,6 +1287,104 @@ def copy(self, *args, **kwargs): return self.wrapped_obj.copy(*args, **kwargs) +def tree( + specs: List["spack.spec.Spec"], + *, + color: Optional[bool] = None, + depth: bool = False, + hashes: bool = False, + hashlen: Optional[int] = None, + cover: str = "nodes", + indent: int = 0, + format: str = DEFAULT_FORMAT, + deptypes: Union[Tuple[str, ...], str] = "all", + show_types: bool = False, + depth_first: bool = False, + recurse_dependencies: bool = True, + status_fn: Optional[Callable[["Spec"], InstallStatus]] = None, + prefix: Optional[Callable[["Spec"], str]] = None, + key=id, +) -> str: + """Prints out specs and their dependencies, tree-formatted with indentation. + + Status function may either output a boolean or an InstallStatus + + Args: + color: if True, always colorize the tree. If False, don't colorize the tree. If None, + use the default from llnl.tty.color + depth: print the depth from the root + hashes: if True, print the hash of each node + hashlen: length of the hash to be printed + cover: either "nodes" or "edges" + indent: extra indentation for the tree being printed + format: format to be used to print each node + deptypes: dependency types to be represented in the tree + show_types: if True, show the (merged) dependency type of a node + depth_first: if True, traverse the DAG depth first when representing it as a tree + recurse_dependencies: if True, recurse on dependencies + status_fn: optional callable that takes a node as an argument and return its + installation status + prefix: optional callable that takes a node as an argument and return its + installation prefix + """ + out = "" + + if color is None: + color = clr.get_color_when() + + # reduce deptypes over all in-edges when covering nodes + if show_types and cover == "nodes": + deptype_lookup: Dict[str, dt.DepFlag] = collections.defaultdict(dt.DepFlag) + for edge in traverse.traverse_edges(specs, cover="edges", deptype=deptypes, root=False): + deptype_lookup[edge.spec.dag_hash()] |= edge.depflag + + for d, dep_spec in traverse.traverse_tree( + sorted(specs), cover=cover, deptype=deptypes, depth_first=depth_first, key=key + ): + node = dep_spec.spec + + if prefix is not None: + out += prefix(node) + out += " " * indent + + if depth: + out += "%-4d" % d + + if status_fn: + status = status_fn(node) + if status in list(InstallStatus): + out += clr.colorize(status.value, color=color) + elif status: + out += clr.colorize("@g{[+]} ", color=color) + else: + out += clr.colorize("@r{[-]} ", color=color) + + if hashes: + out += clr.colorize("@K{%s} ", color=color) % node.dag_hash(hashlen) + + if show_types: + if cover == "nodes": + depflag = deptype_lookup[dep_spec.spec.dag_hash()] + else: + # when covering edges or paths, we show dependency + # types only for the edge through which we visited + depflag = dep_spec.depflag + + type_chars = dt.flag_to_chars(depflag) + out += "[%s] " % type_chars + + out += " " * d + if d > 0: + out += "^" + out += node.format(format, color=color) + "\n" + + # Check if we wanted just the first line + if not recurse_dependencies: + break + + return out + + @lang.lazy_lexicographic_ordering(set_hash=False) class Spec: #: Cache for spec's prefix, computed lazily in the corresponding property @@ -1408,6 +1504,13 @@ def external_path(self, ext_path): def external(self): return bool(self.external_path) or bool(self.external_modules) + @property + def is_develop(self): + """Return whether the Spec represents a user-developed package + in a Spack ``Environment`` (i.e. using `spack develop`). + """ + return bool(self.variants.get("dev_path", False)) + def clear_dependencies(self): """Trim the dependencies of this spec.""" self._dependencies.clear() @@ -2811,9 +2914,7 @@ def _old_concretize(self, tests=False, deprecation_warning=True): # Check if we can produce an optimized binary (will throw if # there are declared inconsistencies) - # No need on platform=cray because of the targeting modules - if not self.satisfies("platform=cray"): - self.architecture.target.optimization_flags(self.compiler) + self.architecture.target.optimization_flags(self.compiler) def _patches_assigned(self): """Whether patches have been assigned to this spec by the concretizer.""" @@ -2961,7 +3062,6 @@ def _new_concretize(self, tests=False): allow_deprecated = spack.config.get("config:deprecated", False) solver = spack.solver.asp.Solver() result = solver.solve([self], tests=tests, allow_deprecated=allow_deprecated) - result.raise_if_unsat() # take the best answer opt, i, answer = min(result.answers) @@ -3901,9 +4001,13 @@ def satisfies(self, other: Union[str, "Spec"], deps: bool = True) -> bool: if not self._dependencies: return False - # If we arrived here, then rhs is abstract. At the moment we don't care about the edge - # structure of an abstract DAG, so we check if any edge could satisfy the properties - # we ask for. + # If we arrived here, the lhs root node satisfies the rhs root node. Now we need to check + # all the edges that have an abstract parent, and verify that they match some edge in the + # lhs. + # + # It might happen that the rhs brings in concrete sub-DAGs. For those we don't need to + # verify the edge properties, cause everything is encoded in the hash of the nodes that + # will be verified later. lhs_edges: Dict[str, Set[DependencySpec]] = collections.defaultdict(set) for rhs_edge in other.traverse_edges(root=False, cover="edges"): # If we are checking for ^mpi we need to verify if there is any edge @@ -3913,6 +4017,10 @@ def satisfies(self, other: Union[str, "Spec"], deps: bool = True) -> bool: if not rhs_edge.virtuals: continue + # Skip edges from a concrete sub-DAG + if rhs_edge.parent.concrete: + continue + if not lhs_edges: # Construct a map of the link/run subDAG + direct "build" edges, # keyed by dependency name @@ -4132,7 +4240,7 @@ def version(self): raise spack.error.SpecError("Spec version is not concrete: " + str(self)) return self.versions[0] - def __getitem__(self, name): + def __getitem__(self, name: str): """Get a dependency from the spec by its name. This call implicitly sets a query state in the package being retrieved. The behavior of packages may be influenced by additional query parameters that are @@ -4141,7 +4249,7 @@ def __getitem__(self, name): Note that if a virtual package is queried a copy of the Spec is returned while for non-virtual a reference is returned. """ - query_parameters = name.split(":") + query_parameters: List[str] = name.split(":") if len(query_parameters) > 2: raise KeyError("key has more than one ':' symbol. At most one is admitted.") @@ -4152,38 +4260,30 @@ def __getitem__(self, name): csv = query_parameters.pop().strip() query_parameters = re.split(r"\s*,\s*", csv) - # In some cases a package appears multiple times in the same DAG for *distinct* - # specs. For example, a build-type dependency may itself depend on a package - # the current spec depends on, but their specs may differ. Therefore we iterate - # in an order here that prioritizes the build, test and runtime dependencies; - # only when we don't find the package do we consider the full DAG. order = lambda: itertools.chain( - self.traverse(deptype="link"), - self.dependencies(deptype=dt.BUILD | dt.RUN | dt.TEST), - self.traverse(), # fall back to a full search + self.traverse_edges(deptype=dt.LINK, order="breadth", cover="edges"), + self.edges_to_dependencies(depflag=dt.BUILD | dt.RUN | dt.TEST), + self.traverse_edges(deptype=dt.ALL, order="breadth", cover="edges"), ) + # Consider runtime dependencies and direct build/test deps before transitive dependencies, + # and prefer matches closest to the root. try: - value = next( - itertools.chain( - # Regular specs - (x for x in order() if x.name == name), - ( - x - for x in order() - if (not x.virtual) - and any(name in edge.virtuals for edge in x.edges_from_dependents()) - ), - (x for x in order() if (not x.virtual) and x.package.provides(name)), + child: Spec = next( + e.spec + for e in itertools.chain( + (e for e in order() if e.spec.name == name or name in e.virtuals), + # for historical reasons + (e for e in order() if e.spec.concrete and e.spec.package.provides(name)), ) ) except StopIteration: raise KeyError(f"No spec with name {name} in {self}") if self._concrete: - return SpecBuildInterface(value, name, query_parameters) + return SpecBuildInterface(child, name, query_parameters, _parent=self) - return value + return child def __contains__(self, spec): """True if this spec or some dependency satisfies the spec. @@ -4286,10 +4386,7 @@ def deps(): yield deps - def colorized(self): - return colorize_spec(self) - - def format(self, format_string=DEFAULT_FORMAT, **kwargs): + def format(self, format_string: str = DEFAULT_FORMAT, color: Optional[bool] = False) -> str: r"""Prints out particular pieces of a spec, depending on what is in the format string. @@ -4352,79 +4449,65 @@ def format(self, format_string=DEFAULT_FORMAT, **kwargs): literal ``\`` character. Args: - format_string (str): string containing the format to be expanded - - Keyword Args: - color (bool): True if returned string is colored - transform (dict): maps full-string formats to a callable \ - that accepts a string and returns another one - + format_string: string containing the format to be expanded + color: True for colorized result; False for no color; None for auto color. """ ensure_modern_format_string(format_string) - color = kwargs.get("color", False) - transform = kwargs.get("transform", {}) - - out = io.StringIO() - - def write(s, c=None): - f = clr.cescape(s) - if c is not None: - f = COLOR_FORMATS[c] + f + "@." - clr.cwrite(f, stream=out, color=color) - def write_attribute(spec, attribute, color): - attribute = attribute.lower() - - sig = "" - if attribute.startswith(("@", "%", "/")): - # color sigils that are inside braces - sig = attribute[0] - attribute = attribute[1:] - elif attribute.startswith("arch="): - sig = " arch=" # include space as separator - attribute = attribute[5:] - - current = spec - if attribute.startswith("^"): - attribute = attribute[1:] - dep, attribute = attribute.split(".", 1) - current = self[dep] + def safe_color(sigil: str, string: str, color_fmt: Optional[str]) -> str: + # avoid colorizing if there is no color or the string is empty + if (color is False) or not color_fmt or not string: + return sigil + string + # escape and add the sigil here to avoid multiple concatenations + if sigil == "@": + sigil = "@@" + return clr.colorize(f"{color_fmt}{sigil}{clr.cescape(string)}@.", color=color) + + def format_attribute(match_object: Match) -> str: + (esc, sig, dep, hash, hash_len, attribute, close_brace, unmatched_close_brace) = ( + match_object.groups() + ) + if esc: + return esc + elif unmatched_close_brace: + raise SpecFormatStringError(f"Unmatched close brace: '{format_string}'") + elif not close_brace: + raise SpecFormatStringError(f"Missing close brace: '{format_string}'") + + current = self if dep is None else self[dep] + + # Hash attributes can return early. + # NOTE: we currently treat abstract_hash like an attribute and ignore + # any length associated with it. We may want to change that. + if hash: + if sig and sig != "/": + raise SpecFormatSigilError(sig, "DAG hashes", hash) + try: + length = int(hash_len) if hash_len else None + except ValueError: + raise SpecFormatStringError(f"Invalid hash length: '{hash_len}'") + return safe_color(sig or "", current.dag_hash(length), HASH_COLOR) if attribute == "": raise SpecFormatStringError("Format string attributes must be non-empty") + attribute = attribute.lower() parts = attribute.split(".") assert parts # check that the sigil is valid for the attribute. - if sig == "@" and parts[-1] not in ("versions", "version"): + if not sig: + sig = "" + elif sig == "@" and parts[-1] not in ("versions", "version"): raise SpecFormatSigilError(sig, "versions", attribute) elif sig == "%" and attribute not in ("compiler", "compiler.name"): raise SpecFormatSigilError(sig, "compilers", attribute) - elif sig == "/" and not re.match(r"(abstract_)?hash(:\d+)?$", attribute): + elif sig == "/" and attribute != "abstract_hash": raise SpecFormatSigilError(sig, "DAG hashes", attribute) - elif sig == " arch=" and attribute not in ("architecture", "arch"): - raise SpecFormatSigilError(sig, "the architecture", attribute) - - # find the morph function for our attribute - morph = transform.get(attribute, lambda s, x: x) - - # Special cases for non-spec attributes and hashes. - # These must be the only non-dep component of the format attribute - if attribute == "spack_root": - write(morph(spec, spack.paths.spack_root)) - return - elif attribute == "spack_install": - write(morph(spec, spack.store.STORE.layout.root)) - return - elif re.match(r"hash(:\d)?", attribute): - col = "#" - if ":" in attribute: - _, length = attribute.split(":") - write(sig + morph(spec, current.dag_hash(int(length))), col) - else: - write(sig + morph(spec, current.dag_hash()), col) - return + elif sig == "arch=": + if attribute not in ("architecture", "arch"): + raise SpecFormatSigilError(sig, "the architecture", attribute) + sig = " arch=" # include space as separator # Iterate over components using getattr to get next element for idx, part in enumerate(parts): @@ -4433,7 +4516,7 @@ def write_attribute(spec, attribute, color): if part.startswith("_"): raise SpecFormatStringError("Attempted to format private attribute") else: - if isinstance(current, vt.VariantMap): + if part == "variants" and isinstance(current, vt.VariantMap): # subscript instead of getattr for variant names current = current[part] else: @@ -4457,62 +4540,31 @@ def write_attribute(spec, attribute, color): raise SpecFormatStringError(m) if isinstance(current, vn.VersionList): if current == vn.any_version: - # We don't print empty version lists - return + # don't print empty version lists + return "" if callable(current): raise SpecFormatStringError("Attempted to format callable object") + if current is None: - # We're not printing anything - return + # not printing anything + return "" # Set color codes for various attributes - col = None + color = None if "variants" in parts: - col = "+" + color = VARIANT_COLOR elif "architecture" in parts: - col = "=" + color = ARCHITECTURE_COLOR elif "compiler" in parts or "compiler_flags" in parts: - col = "%" + color = COMPILER_COLOR elif "version" in parts or "versions" in parts: - col = "@" - - # Finally, write the output - write(sig + morph(spec, str(current)), col) - - attribute = "" - in_attribute = False - escape = False - - for c in format_string: - if escape: - out.write(c) - escape = False - elif c == "\\": - escape = True - elif in_attribute: - if c == "}": - write_attribute(self, attribute, color) - attribute = "" - in_attribute = False - else: - attribute += c - else: - if c == "}": - raise SpecFormatStringError( - "Encountered closing } before opening { in %s" % format_string - ) - elif c == "{": - in_attribute = True - else: - out.write(c) - if in_attribute: - raise SpecFormatStringError( - "Format string terminated while reading attribute." "Missing terminating }." - ) + color = VERSION_COLOR + + # return colored output + return safe_color(sig, str(current), color) - formatted_spec = out.getvalue() - return formatted_spec.strip() + return SPEC_FORMAT_RE.sub(format_attribute, format_string).strip() def cformat(self, *args, **kwargs): """Same as format, but color defaults to auto instead of False.""" @@ -4520,6 +4572,16 @@ def cformat(self, *args, **kwargs): kwargs.setdefault("color", None) return self.format(*args, **kwargs) + @property + def spack_root(self): + """Special field for using ``{spack_root}`` in Spec.format().""" + return spack.paths.spack_root + + @property + def spack_install(self): + """Special field for using ``{spack_install}`` in Spec.format().""" + return spack.store.STORE.layout.root + def format_path( # self, format_string: str, _path_ctor: Optional[pathlib.PurePath] = None self, @@ -4545,18 +4607,27 @@ def format_path( path_ctor = _path_ctor or pathlib.PurePath format_string_as_path = path_ctor(format_string) - if format_string_as_path.is_absolute(): + if format_string_as_path.is_absolute() or ( + # Paths that begin with a single "\" on windows are relative, but we still + # want to preserve the initial "\\" to be consistent with PureWindowsPath. + # Ensure that this '\' is not passed to polite_filename() so it's not converted to '_' + (os.name == "nt" or path_ctor == pathlib.PureWindowsPath) + and format_string_as_path.parts[0] == "\\" + ): output_path_components = [format_string_as_path.parts[0]] input_path_components = list(format_string_as_path.parts[1:]) else: output_path_components = [] input_path_components = list(format_string_as_path.parts) + output_path_components += [ - fs.polite_filename(self.format(x)) for x in input_path_components + fs.polite_filename(self.format(part)) for part in input_path_components ] return str(path_ctor(*output_path_components)) def __str__(self): + if not self._dependencies: + return self.format() root_str = [self.format()] sorted_dependencies = sorted( self.traverse(root=False), key=lambda x: (x.name, x.abstract_hash) @@ -4579,7 +4650,7 @@ def colored_str(self): spec_str = " ^".join(root_str + sorted_dependencies) return spec_str.strip() - def install_status(self): + def install_status(self) -> InstallStatus: """Helper for tree to print DB install status.""" if not self.concrete: return InstallStatus.absent @@ -4623,13 +4694,14 @@ def tree( recurse_dependencies: bool = True, status_fn: Optional[Callable[["Spec"], InstallStatus]] = None, prefix: Optional[Callable[["Spec"], str]] = None, + key=id, ) -> str: - """Prints out this spec and its dependencies, tree-formatted - with indentation. + """Prints out this spec and its dependencies, tree-formatted with indentation. - Status function may either output a boolean or an InstallStatus + See multi-spec ``spack.spec.tree()`` function for details. Args: + specs: List of specs to format. color: if True, always colorize the tree. If False, don't colorize the tree. If None, use the default from llnl.tty.color depth: print the depth from the root @@ -4647,60 +4719,23 @@ def tree( prefix: optional callable that takes a node as an argument and return its installation prefix """ - out = "" - - if color is None: - color = clr.get_color_when() - - for d, dep_spec in traverse.traverse_tree( - [self], cover=cover, deptype=deptypes, depth_first=depth_first - ): - node = dep_spec.spec - - if prefix is not None: - out += prefix(node) - out += " " * indent - - if depth: - out += "%-4d" % d - - if status_fn: - status = status_fn(node) - if status in list(InstallStatus): - out += clr.colorize(status.value, color=color) - elif status: - out += clr.colorize("@g{[+]} ", color=color) - else: - out += clr.colorize("@r{[-]} ", color=color) - - if hashes: - out += clr.colorize("@K{%s} ", color=color) % node.dag_hash(hashlen) - - if show_types: - if cover == "nodes": - # when only covering nodes, we merge dependency types - # from all dependents before showing them. - depflag = 0 - for ds in node.edges_from_dependents(): - depflag |= ds.depflag - else: - # when covering edges or paths, we show dependency - # types only for the edge through which we visited - depflag = dep_spec.depflag - - type_chars = dt.flag_to_chars(depflag) - out += "[%s] " % type_chars - - out += " " * d - if d > 0: - out += "^" - out += node.format(format, color=color) + "\n" - - # Check if we wanted just the first line - if not recurse_dependencies: - break - - return out + return tree( + [self], + color=color, + depth=depth, + hashes=hashes, + hashlen=hashlen, + cover=cover, + indent=indent, + format=format, + deptypes=deptypes, + show_types=show_types, + depth_first=depth_first, + recurse_dependencies=recurse_dependencies, + status_fn=status_fn, + prefix=prefix, + key=key, + ) def __repr__(self): return str(self) diff --git a/lib/spack/spack/spec_list.py b/lib/spack/spack/spec_list.py index 9779d40fe4b0e2..db844a3e4c1c7c 100644 --- a/lib/spack/spack/spec_list.py +++ b/lib/spack/spack/spec_list.py @@ -212,10 +212,7 @@ def _expand_matrix_constraints(matrix_config): results = [] for combo in itertools.product(*expanded_rows): # Construct a combined spec to test against excludes - flat_combo = [constraint for constraint_list in combo for constraint in constraint_list] - - # Resolve abstract hashes so we can exclude by their concrete properties - flat_combo = [Spec(x).lookup_hash() for x in flat_combo] + flat_combo = [Spec(constraint) for constraints in combo for constraint in constraints] test_spec = flat_combo[0].copy() for constraint in flat_combo[1:]: @@ -231,7 +228,9 @@ def _expand_matrix_constraints(matrix_config): spack.variant.substitute_abstract_variants(test_spec) except spack.variant.UnknownVariantError: pass - if any(test_spec.satisfies(x) for x in excludes): + + # Resolve abstract hashes for exclusion criteria + if any(test_spec.lookup_hash().satisfies(x) for x in excludes): continue if sigil: diff --git a/lib/spack/spack/stage.py b/lib/spack/spack/stage.py index 46848c001661a8..a635d95aeb1a37 100644 --- a/lib/spack/spack/stage.py +++ b/lib/spack/spack/stage.py @@ -346,8 +346,6 @@ class Stage(LockableStagingDir): similar, and are intended to persist for only one run of spack. """ - #: Most staging is managed by Spack. DIYStage is one exception. - needs_fetching = True requires_patch_success = True def __init__( @@ -772,8 +770,6 @@ def __init__(self): "cache_mirror", "steal_source", "disable_mirrors", - "needs_fetching", - "requires_patch_success", ] ) @@ -812,6 +808,10 @@ def path(self): def archive_file(self): return self[0].archive_file + @property + def requires_patch_success(self): + return self[0].requires_patch_success + @property def keep(self): return self[0].keep @@ -822,64 +822,7 @@ def keep(self, value): item.keep = value -class DIYStage: - """ - Simple class that allows any directory to be a spack stage. Consequently, - it does not expect or require that the source path adhere to the standard - directory naming convention. - """ - - needs_fetching = False - requires_patch_success = False - - def __init__(self, path): - if path is None: - raise ValueError("Cannot construct DIYStage without a path.") - elif not os.path.isdir(path): - raise StagePathError("The stage path directory does not exist:", path) - - self.archive_file = None - self.path = path - self.source_path = path - self.created = True - - # DIY stages do nothing as context managers. - def __enter__(self): - pass - - def __exit__(self, exc_type, exc_val, exc_tb): - pass - - def fetch(self, *args, **kwargs): - tty.debug("No need to fetch for DIY.") - - def check(self): - tty.debug("No checksum needed for DIY.") - - def expand_archive(self): - tty.debug("Using source directory: {0}".format(self.source_path)) - - @property - def expanded(self): - """Returns True since the source_path must exist.""" - return True - - def restage(self): - raise RestageError("Cannot restage a DIY stage.") - - def create(self): - self.created = True - - def destroy(self): - # No need to destroy DIY stage. - pass - - def cache_local(self): - tty.debug("Sources for DIY stages are not cached") - - class DevelopStage(LockableStagingDir): - needs_fetching = False requires_patch_success = False def __init__(self, name, dev_path, reference_link): @@ -927,6 +870,10 @@ def destroy(self): shutil.rmtree(self.path) except FileNotFoundError: pass + try: + os.remove(self.reference_link) + except FileNotFoundError: + pass self.created = False def restage(self): diff --git a/lib/spack/spack/store.py b/lib/spack/spack/store.py index dc2d5de54b4372..8509d728aa596b 100644 --- a/lib/spack/spack/store.py +++ b/lib/spack/spack/store.py @@ -371,7 +371,6 @@ def use_store( data.update(extra_data) # Swap the store with the one just constructed and return it - ensure_singleton_created() spack.config.CONFIG.push_scope( spack.config.InternalConfigScope(name=scope_name, data={"config": {"install_tree": data}}) ) diff --git a/lib/spack/spack/subprocess_context.py b/lib/spack/spack/subprocess_context.py index c90dcf84090096..cd0c24676de4e3 100644 --- a/lib/spack/spack/subprocess_context.py +++ b/lib/spack/spack/subprocess_context.py @@ -79,9 +79,11 @@ def restore(self): self.test_state.restore() spack.main.spack_working_dir = self.spack_working_dir env = pickle.load(self.serialized_env) if _SERIALIZE else self.env - pkg = pickle.load(self.serialized_pkg) if _SERIALIZE else self.pkg if env: spack.environment.activate(env) + # Order of operation is important, since the package might be retrieved + # from a repo defined within the environment configuration + pkg = pickle.load(self.serialized_pkg) if _SERIALIZE else self.pkg return pkg diff --git a/lib/spack/spack/target.py b/lib/spack/spack/target.py index 5f1f4f9e5a9b3a..8d0943c28aeb86 100644 --- a/lib/spack/spack/target.py +++ b/lib/spack/spack/target.py @@ -142,7 +142,7 @@ def optimization_flags(self, compiler): # custom spec. compiler_version = compiler.version version_number, suffix = archspec.cpu.version_components(compiler.version) - if not version_number or suffix not in ("", "apple"): + if not version_number or suffix: # Try to deduce the underlying version of the compiler, regardless # of its name in compilers.yaml. Depending on where this function # is called we might get either a CompilerSpec or a fully fledged @@ -155,5 +155,6 @@ def optimization_flags(self, compiler): # log this and just return compiler.version instead tty.debug(str(e)) - compiler_version = compiler_version.dotted.force_numeric - return self.microarchitecture.optimization_flags(compiler.name, str(compiler_version)) + return self.microarchitecture.optimization_flags( + compiler.name, compiler_version.dotted_numeric_string + ) diff --git a/lib/spack/spack/test/architecture.py b/lib/spack/spack/test/architecture.py index f01e43ec906f2c..3e4b0412dc412b 100644 --- a/lib/spack/spack/test/architecture.py +++ b/lib/spack/spack/test/architecture.py @@ -2,19 +2,18 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import os import platform -import sys import pytest -import llnl.util.filesystem as fs +import archspec.cpu +import spack.compilers import spack.concretize import spack.operating_systems import spack.platforms import spack.target -from spack.spec import ArchSpec, CompilerSpec, Spec +from spack.spec import ArchSpec, Spec @pytest.fixture(scope="module") @@ -22,9 +21,8 @@ def current_host_platform(): """Return the platform of the current host as detected by the 'platform' stdlib package. """ - if os.path.exists("/opt/cray/pe"): - current_platform = spack.platforms.Cray() - elif "Linux" in platform.system(): + current_platform = None + if "Linux" in platform.system(): current_platform = spack.platforms.Linux() elif "Darwin" in platform.system(): current_platform = spack.platforms.Darwin() @@ -123,52 +121,60 @@ def test_arch_spec_container_semantic(item, architecture_str): @pytest.mark.parametrize( "compiler_spec,target_name,expected_flags", [ - # Check compilers with version numbers from a single toolchain + # Homogeneous compilers ("gcc@4.7.2", "ivybridge", "-march=core-avx-i -mtune=core-avx-i"), - # Check mixed toolchains - ("clang@8.0.0", "broadwell", ""), ("clang@3.5", "x86_64", "-march=x86-64 -mtune=generic"), - # Check Apple's Clang compilers ("apple-clang@9.1.0", "x86_64", "-march=x86-64"), + # Mixed toolchain + ("clang@8.0.0", "broadwell", ""), ], ) @pytest.mark.filterwarnings("ignore:microarchitecture specific") -def test_optimization_flags(compiler_spec, target_name, expected_flags, config): +def test_optimization_flags(compiler_spec, target_name, expected_flags, compiler_factory): target = spack.target.Target(target_name) - compiler = spack.compilers.compilers_for_spec(compiler_spec).pop() + compiler_dict = compiler_factory(spec=compiler_spec, operating_system="")["compiler"] + if compiler_spec == "clang@8.0.0": + compiler_dict["paths"] = { + "cc": "/path/to/clang-8", + "cxx": "/path/to/clang++-8", + "f77": "/path/to/gfortran-9", + "fc": "/path/to/gfortran-9", + } + compiler = spack.compilers.compiler_from_dict(compiler_dict) + opt_flags = target.optimization_flags(compiler) assert opt_flags == expected_flags @pytest.mark.parametrize( - "compiler,real_version,target_str,expected_flags", + "compiler_str,real_version,target_str,expected_flags", [ - (CompilerSpec("gcc@=9.2.0"), None, "haswell", "-march=haswell -mtune=haswell"), + ("gcc@=9.2.0", None, "haswell", "-march=haswell -mtune=haswell"), # Check that custom string versions are accepted - ( - CompilerSpec("gcc@=10foo"), - "9.2.0", - "icelake", - "-march=icelake-client -mtune=icelake-client", - ), + ("gcc@=10foo", "9.2.0", "icelake", "-march=icelake-client -mtune=icelake-client"), # Check that we run version detection (4.4.0 doesn't support icelake) - ( - CompilerSpec("gcc@=4.4.0-special"), - "9.2.0", - "icelake", - "-march=icelake-client -mtune=icelake-client", - ), + ("gcc@=4.4.0-special", "9.2.0", "icelake", "-march=icelake-client -mtune=icelake-client"), # Check that the special case for Apple's clang is treated correctly # i.e. it won't try to detect the version again - (CompilerSpec("apple-clang@=9.1.0"), None, "x86_64", "-march=x86-64"), + ("apple-clang@=9.1.0", None, "x86_64", "-march=x86-64"), ], ) def test_optimization_flags_with_custom_versions( - compiler, real_version, target_str, expected_flags, monkeypatch, config + compiler_str, + real_version, + target_str, + expected_flags, + monkeypatch, + mutable_config, + compiler_factory, ): target = spack.target.Target(target_str) + compiler_dict = compiler_factory(spec=compiler_str, operating_system="redhat6") + mutable_config.set("compilers", [compiler_dict]) if real_version: monkeypatch.setattr(spack.compiler.Compiler, "get_real_version", lambda x: real_version) + compiler = spack.compilers.compiler_from_dict(compiler_dict["compiler"]) + opt_flags = target.optimization_flags(compiler) assert opt_flags == expected_flags @@ -203,35 +209,13 @@ def test_satisfy_strict_constraint_when_not_concrete(architecture_tuple, constra ) @pytest.mark.usefixtures("mock_packages", "config") @pytest.mark.only_clingo("Fixing the parser broke this test for the original concretizer.") +@pytest.mark.skipif( + str(archspec.cpu.host().family) != "x86_64", reason="tests are for x86_64 uarch ranges" +) def test_concretize_target_ranges(root_target_range, dep_target_range, result, monkeypatch): - # Monkeypatch so that all concretization is done as if the machine is core2 - monkeypatch.setattr(spack.platforms.test.Test, "default", "core2") - spec = Spec(f"a %gcc@10 foobar=bar target={root_target_range} ^b target={dep_target_range}") + spec = Spec( + f"pkg-a %gcc@10 foobar=bar target={root_target_range} ^pkg-b target={dep_target_range}" + ) with spack.concretize.disable_compiler_existence_check(): spec.concretize() - assert spec.target == spec["b"].target == result - - -@pytest.mark.parametrize( - "versions,default,expected", - [ - (["21.11", "21.9"], "21.11", False), - (["21.11", "21.9"], "21.9", True), - (["21.11", "21.9"], None, False), - ], -) -@pytest.mark.skipif(sys.platform == "win32", reason="Cray does not use windows") -def test_cray_platform_detection(versions, default, expected, tmpdir, monkeypatch, working_env): - ex_path = str(tmpdir.join("fake_craype_dir")) - fs.mkdirp(ex_path) - - with fs.working_dir(ex_path): - for version in versions: - fs.touch(version) - if default: - os.symlink(default, "default") - - monkeypatch.setattr(spack.platforms.cray, "_ex_craype_dir", ex_path) - os.environ["MODULEPATH"] = "/opt/cray/pe" - - assert spack.platforms.cray.Cray.detect() == expected + assert spec.target == spec["pkg-b"].target == result diff --git a/lib/spack/spack/test/audit.py b/lib/spack/spack/test/audit.py index 98e6ad83c85555..0d2ca594f1701f 100644 --- a/lib/spack/spack/test/audit.py +++ b/lib/spack/spack/test/audit.py @@ -19,6 +19,8 @@ (["missing-dependency"], ["PKG-DIRECTIVES", "PKG-PROPERTIES"]), # The package use a non existing variant in a depends_on directive (["wrong-variant-in-depends-on"], ["PKG-DIRECTIVES", "PKG-PROPERTIES"]), + # This package has a GitHub pull request commit patch URL + (["invalid-github-pull-commits-patch-url"], ["PKG-DIRECTIVES", "PKG-PROPERTIES"]), # This package has a GitHub patch URL without full_index=1 (["invalid-github-patch-url"], ["PKG-DIRECTIVES", "PKG-PROPERTIES"]), # This package has invalid GitLab patch URLs diff --git a/lib/spack/spack/test/bindist.py b/lib/spack/spack/test/bindist.py index 0f8b0d58ce2f3b..d80ddfe6e5d60e 100644 --- a/lib/spack/spack/test/bindist.py +++ b/lib/spack/spack/test/bindist.py @@ -19,7 +19,10 @@ import py import pytest +import archspec.cpu + from llnl.util.filesystem import join_path, visit_directory_tree +from llnl.util.symlink import readlink import spack.binary_distribution as bindist import spack.caches @@ -34,7 +37,7 @@ import spack.util.spack_yaml as syaml import spack.util.url as url_util import spack.util.web as web_util -from spack.binary_distribution import get_buildfile_manifest +from spack.binary_distribution import CannotListKeys, GenerateIndexError, get_buildfile_manifest from spack.directory_layout import DirectoryLayout from spack.paths import test_path from spack.spec import Spec @@ -102,18 +105,18 @@ def config_directory(tmpdir_factory): @pytest.fixture(scope="function") -def default_config(tmpdir, config_directory, monkeypatch, install_mockery_mutable_config): - # This fixture depends on install_mockery_mutable_config to ensure +def default_config(tmpdir, config_directory, monkeypatch, install_mockery): + # This fixture depends on install_mockery to ensure # there is a clear order of initialization. The substitution of the # config scopes here is done on top of the substitution that comes with - # install_mockery_mutable_config + # install_mockery mutable_dir = tmpdir.mkdir("mutable_config").join("tmp") config_directory.copy(mutable_dir) cfg = spack.config.Configuration( *[ - spack.config.ConfigScope(name, str(mutable_dir)) - for name in ["site/%s" % platform.system().lower(), "site", "user"] + spack.config.DirectoryConfigScope(name, str(mutable_dir)) + for name in [f"site/{platform.system().lower()}", "site", "user"] ] ) @@ -388,16 +391,14 @@ def test_built_spec_cache(mirror_dir): assert any([r["spec"] == s for r in results]) -def fake_dag_hash(spec): +def fake_dag_hash(spec, length=None): # Generate an arbitrary hash that is intended to be different than # whatever a Spec reported before (to test actions that trigger when # the hash changes) - return "tal4c7h4z0gqmixb1eqa92mjoybxn5l6" + return "tal4c7h4z0gqmixb1eqa92mjoybxn5l6"[:length] -@pytest.mark.usefixtures( - "install_mockery_mutable_config", "mock_packages", "mock_fetch", "test_mirror" -) +@pytest.mark.usefixtures("install_mockery", "mock_packages", "mock_fetch", "test_mirror") def test_spec_needs_rebuild(monkeypatch, tmpdir): """Make sure needs_rebuild properly compares remote hash against locally computed one, avoiding unnecessary rebuilds""" @@ -426,7 +427,7 @@ def test_spec_needs_rebuild(monkeypatch, tmpdir): assert rebuild -@pytest.mark.usefixtures("install_mockery_mutable_config", "mock_packages", "mock_fetch") +@pytest.mark.usefixtures("install_mockery", "mock_packages", "mock_fetch") def test_generate_index_missing(monkeypatch, tmpdir, mutable_config): """Ensure spack buildcache index only reports available packages""" @@ -463,50 +464,57 @@ def test_generate_index_missing(monkeypatch, tmpdir, mutable_config): assert "libelf" not in cache_list -def test_generate_indices_key_error(monkeypatch, capfd): +def test_generate_key_index_failure(monkeypatch): + def list_url(url, recursive=False): + if "fails-listing" in url: + raise Exception("Couldn't list the directory") + return ["first.pub", "second.pub"] + + def push_to_url(*args, **kwargs): + raise Exception("Couldn't upload the file") + + monkeypatch.setattr(web_util, "list_url", list_url) + monkeypatch.setattr(web_util, "push_to_url", push_to_url) + + with pytest.raises(CannotListKeys, match="Encountered problem listing keys"): + bindist.generate_key_index("s3://non-existent/fails-listing") + + with pytest.raises(GenerateIndexError, match="problem pushing .* Couldn't upload"): + bindist.generate_key_index("s3://non-existent/fails-uploading") + + +def test_generate_package_index_failure(monkeypatch, capfd): def mock_list_url(url, recursive=False): - print("mocked list_url({0}, {1})".format(url, recursive)) - raise KeyError("Test KeyError handling") + raise Exception("Some HTTP error") monkeypatch.setattr(web_util, "list_url", mock_list_url) test_url = "file:///fake/keys/dir" - # Make sure generate_key_index handles the KeyError - bindist.generate_key_index(test_url) - - err = capfd.readouterr()[1] - assert "Warning: No keys at {0}".format(test_url) in err + with pytest.raises(GenerateIndexError, match="Unable to generate package index"): + bindist.generate_package_index(test_url) - # Make sure generate_package_index handles the KeyError - bindist.generate_package_index(test_url) - - err = capfd.readouterr()[1] - assert "Warning: No packages at {0}".format(test_url) in err + assert ( + f"Warning: Encountered problem listing packages at {test_url}: Some HTTP error" + in capfd.readouterr().err + ) def test_generate_indices_exception(monkeypatch, capfd): def mock_list_url(url, recursive=False): - print("mocked list_url({0}, {1})".format(url, recursive)) raise Exception("Test Exception handling") monkeypatch.setattr(web_util, "list_url", mock_list_url) - test_url = "file:///fake/keys/dir" - - # Make sure generate_key_index handles the Exception - bindist.generate_key_index(test_url) + url = "file:///fake/keys/dir" - err = capfd.readouterr()[1] - expect = "Encountered problem listing keys at {0}".format(test_url) - assert expect in err + with pytest.raises(GenerateIndexError, match=f"Encountered problem listing keys at {url}"): + bindist.generate_key_index(url) - # Make sure generate_package_index handles the Exception - bindist.generate_package_index(test_url) + with pytest.raises(GenerateIndexError, match="Unable to generate package index"): + bindist.generate_package_index(url) - err = capfd.readouterr()[1] - expect = "Encountered problem listing packages at {0}".format(test_url) - assert expect in err + assert f"Encountered problem listing packages at {url}" in capfd.readouterr().err @pytest.mark.usefixtures("mock_fetch", "install_mockery") @@ -573,11 +581,18 @@ def test_update_sbang(tmpdir, test_mirror): uninstall_cmd("-y", "/%s" % new_spec.dag_hash()) -def test_install_legacy_buildcache_layout(install_mockery_mutable_config): +@pytest.mark.skipif( + str(archspec.cpu.host().family) != "x86_64", + reason="test data uses gcc 4.5.0 which does not support aarch64", +) +def test_install_legacy_buildcache_layout(mutable_config, compiler_factory, install_mockery): """Legacy buildcache layout involved a nested archive structure where the .spack file contained a repeated spec.json and another compressed archive file containing the install tree. This test makes sure we can still read that layout.""" + mutable_config.set( + "compilers", [compiler_factory(spec="gcc@4.5.0", operating_system="debian6")] + ) legacy_layout_dir = os.path.join(test_path, "data", "mirrors", "legacy_layout") mirror_url = "file://{0}".format(legacy_layout_dir) filename = ( @@ -1044,10 +1059,10 @@ def test_tarball_common_prefix(dummy_prefix, tmpdir): assert set(os.listdir(os.path.join("prefix2", "share"))) == {"file"} # Relative symlink should still be correct - assert os.readlink(os.path.join("prefix2", "bin", "relative_app_link")) == "app" + assert readlink(os.path.join("prefix2", "bin", "relative_app_link")) == "app" # Absolute symlink should remain absolute -- this is for relocation to fix up. - assert os.readlink(os.path.join("prefix2", "bin", "absolute_app_link")) == os.path.join( + assert readlink(os.path.join("prefix2", "bin", "absolute_app_link")) == os.path.join( dummy_prefix, "bin", "app" ) diff --git a/lib/spack/spack/test/bootstrap.py b/lib/spack/spack/test/bootstrap.py index 5f11e2d381e639..f0d11d41247e4b 100644 --- a/lib/spack/spack/test/bootstrap.py +++ b/lib/spack/spack/test/bootstrap.py @@ -228,3 +228,25 @@ def test_source_is_disabled(mutable_config): spack.config.add("bootstrap:trusted:{0}:{1}".format(conf["name"], False)) with pytest.raises(ValueError): spack.bootstrap.core.source_is_enabled_or_raise(conf) + + +@pytest.mark.regression("45247") +def test_use_store_does_not_try_writing_outside_root(tmp_path, monkeypatch, mutable_config): + """Tests that when we use the 'use_store' context manager, there is no attempt at creating + a Store outside the given root. + """ + initial_store = mutable_config.get("config:install_tree:root") + user_store = tmp_path / "store" + + fn = spack.store.Store.__init__ + + def _checked_init(self, root, *args, **kwargs): + fn(self, root, *args, **kwargs) + assert self.root == str(user_store) + + monkeypatch.setattr(spack.store.Store, "__init__", _checked_init) + + spack.store.reinitialize() + with spack.store.use_store(user_store): + assert spack.config.CONFIG.get("config:install_tree:root") == str(user_store) + assert spack.config.CONFIG.get("config:install_tree:root") == initial_store diff --git a/lib/spack/spack/test/build_environment.py b/lib/spack/spack/test/build_environment.py index 1f2d9e904fd890..a47fb28811222f 100644 --- a/lib/spack/spack/test/build_environment.py +++ b/lib/spack/spack/test/build_environment.py @@ -14,6 +14,7 @@ import spack.build_environment import spack.config +import spack.deptypes as dt import spack.package_base import spack.spec import spack.util.spack_yaml as syaml @@ -63,7 +64,8 @@ def build_environment(working_env): os.environ["SPACK_LINKER_ARG"] = "-Wl," os.environ["SPACK_DTAGS_TO_ADD"] = "--disable-new-dtags" os.environ["SPACK_DTAGS_TO_STRIP"] = "--enable-new-dtags" - os.environ["SPACK_SYSTEM_DIRS"] = "/usr/include /usr/lib" + os.environ["SPACK_SYSTEM_DIRS"] = "/usr/include|/usr/lib" + os.environ["SPACK_MANAGED_DIRS"] = f"{prefix}/opt/spack" os.environ["SPACK_TARGET_ARGS"] = "" if "SPACK_DEPENDENCIES" in os.environ: @@ -175,7 +177,7 @@ def _set_wrong_cc(x): def test_setup_dependent_package_inherited_modules( - config, working_env, mock_packages, install_mockery, mock_fetch + working_env, mock_packages, install_mockery, mock_fetch ): # This will raise on regression s = spack.spec.Spec("cmake-client-inheritor").concretized() @@ -455,14 +457,14 @@ def test_parallel_false_is_not_propagating(default_mock_concretization): # a foobar=bar (parallel = False) # | # b (parallel =True) - s = default_mock_concretization("a foobar=bar") + s = default_mock_concretization("pkg-a foobar=bar") spack.build_environment.set_package_py_globals(s.package, context=Context.BUILD) - assert s["a"].package.module.make_jobs == 1 + assert s["pkg-a"].package.module.make_jobs == 1 - spack.build_environment.set_package_py_globals(s["b"].package, context=Context.BUILD) - assert s["b"].package.module.make_jobs == spack.build_environment.determine_number_of_jobs( - parallel=s["b"].package.parallel + spack.build_environment.set_package_py_globals(s["pkg-b"].package, context=Context.BUILD) + assert s["pkg-b"].package.module.make_jobs == spack.build_environment.determine_number_of_jobs( + parallel=s["pkg-b"].package.parallel ) @@ -554,24 +556,6 @@ def test_build_jobs_defaults(): ) -def test_dirty_disable_module_unload(config, mock_packages, working_env, mock_module_cmd): - """Test that on CRAY platform 'module unload' is not called if the 'dirty' - option is on. - """ - s = spack.spec.Spec("a").concretized() - - # If called with "dirty" we don't unload modules, so no calls to the - # `module` function on Cray - spack.build_environment.setup_package(s.package, dirty=True) - assert not mock_module_cmd.calls - - # If called without "dirty" we unload modules on Cray - spack.build_environment.setup_package(s.package, dirty=False) - assert mock_module_cmd.calls - assert any(("unload", "cray-libsci") == item[0] for item in mock_module_cmd.calls) - assert any(("unload", "cray-mpich") == item[0] for item in mock_module_cmd.calls) - - class TestModuleMonkeyPatcher: def test_getting_attributes(self, default_mock_concretization): s = default_mock_concretization("libelf") @@ -715,3 +699,21 @@ def test_build_system_globals_only_set_on_root_during_build(default_mock_concret for depth, spec in root.traverse(depth=True, root=True): for variable in build_variables: assert hasattr(spec.package.module, variable) == should_be_set(depth) + + +def test_rpath_with_duplicate_link_deps(): + """If we have two instances of one package in the same link sub-dag, only the newest version is + rpath'ed. This is for runtime support without splicing.""" + runtime_1 = spack.spec.Spec("runtime@=1.0") + runtime_2 = spack.spec.Spec("runtime@=2.0") + child = spack.spec.Spec("child@=1.0") + root = spack.spec.Spec("root@=1.0") + + root.add_dependency_edge(child, depflag=dt.LINK, virtuals=()) + root.add_dependency_edge(runtime_2, depflag=dt.LINK, virtuals=()) + child.add_dependency_edge(runtime_1, depflag=dt.LINK, virtuals=()) + + rpath_deps = spack.build_environment._get_rpath_deps_from_spec(root, transitive_rpaths=True) + assert child in rpath_deps + assert runtime_2 in rpath_deps + assert runtime_1 not in rpath_deps diff --git a/lib/spack/spack/test/build_systems.py b/lib/spack/spack/test/build_systems.py index a77dfb090773ca..57516b445c18d0 100644 --- a/lib/spack/spack/test/build_systems.py +++ b/lib/spack/spack/test/build_systems.py @@ -9,6 +9,8 @@ import py.path import pytest +import archspec.cpu + import llnl.util.filesystem as fs import spack.build_systems.autotools @@ -92,10 +94,10 @@ def test_negative_ninja_check(self, input_dir, test_dir, concretize_and_setup): @pytest.mark.not_on_windows("autotools not available on windows") -@pytest.mark.usefixtures("config", "mock_packages") +@pytest.mark.usefixtures("mock_packages") class TestAutotoolsPackage: def test_with_or_without(self, default_mock_concretization): - s = default_mock_concretization("a") + s = default_mock_concretization("pkg-a") options = s.package.with_or_without("foo") # Ensure that values that are not representing a feature @@ -127,7 +129,7 @@ def activate(value): assert "--without-lorem-ipsum" in options def test_none_is_allowed(self, default_mock_concretization): - s = default_mock_concretization("a foo=none") + s = default_mock_concretization("pkg-a foo=none") options = s.package.with_or_without("foo") # Ensure that values that are not representing a feature @@ -137,11 +139,9 @@ def test_none_is_allowed(self, default_mock_concretization): assert "--without-baz" in options assert "--no-fee" in options - def test_libtool_archive_files_are_deleted_by_default( - self, default_mock_concretization, mutable_database - ): + def test_libtool_archive_files_are_deleted_by_default(self, mutable_database): # Install a package that creates a mock libtool archive - s = default_mock_concretization("libtool-deletion") + s = Spec("libtool-deletion").concretized() s.package.do_install(explicit=True) # Assert the libtool archive is not there and we have @@ -152,25 +152,23 @@ def test_libtool_archive_files_are_deleted_by_default( assert libtool_deletion_log def test_libtool_archive_files_might_be_installed_on_demand( - self, mutable_database, monkeypatch, default_mock_concretization + self, mutable_database, monkeypatch ): # Install a package that creates a mock libtool archive, # patch its package to preserve the installation - s = default_mock_concretization("libtool-deletion") + s = Spec("libtool-deletion").concretized() monkeypatch.setattr(type(s.package.builder), "install_libtool_archives", True) s.package.do_install(explicit=True) # Assert libtool archives are installed assert os.path.exists(s.package.builder.libtool_archive_file) - def test_autotools_gnuconfig_replacement(self, default_mock_concretization, mutable_database): + def test_autotools_gnuconfig_replacement(self, mutable_database): """ Tests whether only broken config.sub and config.guess are replaced with files from working alternatives from the gnuconfig package. """ - s = default_mock_concretization( - "autotools-config-replacement +patch_config_files +gnuconfig" - ) + s = Spec("autotools-config-replacement +patch_config_files +gnuconfig").concretized() s.package.do_install() with open(os.path.join(s.prefix.broken, "config.sub")) as f: @@ -185,15 +183,11 @@ def test_autotools_gnuconfig_replacement(self, default_mock_concretization, muta with open(os.path.join(s.prefix.working, "config.guess")) as f: assert "gnuconfig version of config.guess" not in f.read() - def test_autotools_gnuconfig_replacement_disabled( - self, default_mock_concretization, mutable_database - ): + def test_autotools_gnuconfig_replacement_disabled(self, mutable_database): """ Tests whether disabling patch_config_files """ - s = default_mock_concretization( - "autotools-config-replacement ~patch_config_files +gnuconfig" - ) + s = Spec("autotools-config-replacement ~patch_config_files +gnuconfig").concretized() s.package.do_install() with open(os.path.join(s.prefix.broken, "config.sub")) as f: @@ -209,6 +203,9 @@ def test_autotools_gnuconfig_replacement_disabled( assert "gnuconfig version of config.guess" not in f.read() @pytest.mark.disable_clean_stage_check + @pytest.mark.skipif( + str(archspec.cpu.host().family) != "x86_64", reason="test data is specific for x86_64" + ) def test_autotools_gnuconfig_replacement_no_gnuconfig(self, mutable_database, monkeypatch): """ Tests whether a useful error message is shown when patch_config_files is diff --git a/lib/spack/spack/test/buildtask.py b/lib/spack/spack/test/buildtask.py index a571e1dccd1c6a..569bfc56d888d1 100644 --- a/lib/spack/spack/test/buildtask.py +++ b/lib/spack/spack/test/buildtask.py @@ -12,21 +12,21 @@ def test_build_task_errors(install_mockery): with pytest.raises(ValueError, match="must be a package"): - inst.BuildTask("abc", None, False, 0, 0, 0, []) + inst.BuildTask("abc", None, False, 0, 0, 0, set()) spec = spack.spec.Spec("trivial-install-test-package") pkg_cls = spack.repo.PATH.get_pkg_class(spec.name) with pytest.raises(ValueError, match="must have a concrete spec"): - inst.BuildTask(pkg_cls(spec), None, False, 0, 0, 0, []) + inst.BuildTask(pkg_cls(spec), None, False, 0, 0, 0, set()) spec.concretize() assert spec.concrete with pytest.raises(ValueError, match="must have a build request"): - inst.BuildTask(spec.package, None, False, 0, 0, 0, []) + inst.BuildTask(spec.package, None, False, 0, 0, 0, set()) request = inst.BuildRequest(spec.package, {}) with pytest.raises(inst.InstallError, match="Cannot create a build task"): - inst.BuildTask(spec.package, request, False, 0, 0, inst.STATUS_REMOVED, []) + inst.BuildTask(spec.package, request, False, 0, 0, inst.STATUS_REMOVED, set()) def test_build_task_basics(install_mockery): @@ -36,8 +36,8 @@ def test_build_task_basics(install_mockery): # Ensure key properties match expectations request = inst.BuildRequest(spec.package, {}) - task = inst.BuildTask(spec.package, request, False, 0, 0, inst.STATUS_ADDED, []) - assert task.explicit # package was "explicitly" requested + task = inst.BuildTask(spec.package, request, False, 0, 0, inst.STATUS_ADDED, set()) + assert not task.explicit assert task.priority == len(task.uninstalled_deps) assert task.key == (task.priority, task.sequence) @@ -58,7 +58,7 @@ def test_build_task_strings(install_mockery): # Ensure key properties match expectations request = inst.BuildRequest(spec.package, {}) - task = inst.BuildTask(spec.package, request, False, 0, 0, inst.STATUS_ADDED, []) + task = inst.BuildTask(spec.package, request, False, 0, 0, inst.STATUS_ADDED, set()) # Cover __repr__ irep = task.__repr__() diff --git a/lib/spack/spack/test/cc.py b/lib/spack/spack/test/cc.py index 25aab774a7f183..b547641b06f30a 100644 --- a/lib/spack/spack/test/cc.py +++ b/lib/spack/spack/test/cc.py @@ -15,7 +15,7 @@ import spack.config import spack.spec from spack.paths import build_env_path -from spack.util.environment import SYSTEM_DIRS, set_env +from spack.util.environment import SYSTEM_DIR_CASE_ENTRY, set_env from spack.util.executable import Executable, ProcessError # @@ -127,7 +127,7 @@ spack_cflags = ["-Wall"] spack_cxxflags = ["-Werror"] spack_fflags = ["-w"] -spack_ldflags = ["-L", "foo"] +spack_ldflags = ["-Wl,--gc-sections", "-L", "foo"] spack_ldlibs = ["-lfoo"] lheaderpad = ["-Wl,-headerpad_max_install_names"] @@ -159,7 +159,8 @@ def wrapper_environment(working_env): SPACK_DEBUG_LOG_ID="foo-hashabc", SPACK_COMPILER_SPEC="gcc@4.4.7", SPACK_SHORT_SPEC="foo@1.2 arch=linux-rhel6-x86_64 /hashabc", - SPACK_SYSTEM_DIRS=":".join(SYSTEM_DIRS), + SPACK_SYSTEM_DIRS=SYSTEM_DIR_CASE_ENTRY, + SPACK_MANAGED_DIRS="/path/to/spack-1/opt/spack/*|/path/to/spack-2/opt/spack/*", SPACK_CC_RPATH_ARG="-Wl,-rpath,", SPACK_CXX_RPATH_ARG="-Wl,-rpath,", SPACK_F77_RPATH_ARG="-Wl,-rpath,", @@ -278,7 +279,6 @@ def test_ld_flags(wrapper_environment, wrapper_flags): test_args, ["ld"] + test_include_paths - + [spack_ldflags[i] + spack_ldflags[i + 1] for i in range(0, len(spack_ldflags), 2)] + test_library_paths + ["--disable-new-dtags"] + test_rpaths @@ -306,13 +306,14 @@ def test_cc_flags(wrapper_environment, wrapper_flags): [real_cc] + target_args + test_include_paths - + [spack_ldflags[i] + spack_ldflags[i + 1] for i in range(0, len(spack_ldflags), 2)] + + ["-Lfoo"] + test_library_paths + ["-Wl,--disable-new-dtags"] + test_wl_rpaths + test_args_without_paths + spack_cppflags + spack_cflags + + ["-Wl,--gc-sections"] + spack_ldlibs, ) @@ -324,12 +325,13 @@ def test_cxx_flags(wrapper_environment, wrapper_flags): [real_cc] + target_args + test_include_paths - + [spack_ldflags[i] + spack_ldflags[i + 1] for i in range(0, len(spack_ldflags), 2)] + + ["-Lfoo"] + test_library_paths + ["-Wl,--disable-new-dtags"] + test_wl_rpaths + test_args_without_paths + spack_cppflags + + ["-Wl,--gc-sections"] + spack_ldlibs, ) @@ -341,13 +343,14 @@ def test_fc_flags(wrapper_environment, wrapper_flags): [real_cc] + target_args + test_include_paths - + [spack_ldflags[i] + spack_ldflags[i + 1] for i in range(0, len(spack_ldflags), 2)] + + ["-Lfoo"] + test_library_paths + ["-Wl,--disable-new-dtags"] + test_wl_rpaths + test_args_without_paths + spack_fflags + spack_cppflags + + ["-Wl,--gc-sections"] + spack_ldlibs, ) @@ -825,14 +828,14 @@ def test_keep_and_replace(wrapper_environment): ), ( "config:flags:keep_werror:specific", - ["-Werror", "-Werror=specific", "-bah"], - ["-Werror=specific", "-bah"], + ["-Werror", "-Werror=specific", "-Werror-specific2", "-bah"], + ["-Wno-error", "-Werror=specific", "-Werror-specific2", "-bah"], ["-Werror"], ), ( "config:flags:keep_werror:none", ["-Werror", "-Werror=specific", "-bah"], - ["-bah", "-Wno-error", "-Wno-error=specific"], + ["-Wno-error", "-Wno-error=specific", "-bah"], ["-Werror", "-Werror=specific"], ), # check non-standard -Werror opts like -Werror-implicit-function-declaration @@ -845,13 +848,13 @@ def test_keep_and_replace(wrapper_environment): ( "config:flags:keep_werror:specific", ["-Werror", "-Werror-implicit-function-declaration", "-bah"], - ["-Werror-implicit-function-declaration", "-bah", "-Wno-error"], + ["-Wno-error", "-Werror-implicit-function-declaration", "-bah"], ["-Werror"], ), ( "config:flags:keep_werror:none", ["-Werror", "-Werror-implicit-function-declaration", "-bah"], - ["-bah", "-Wno-error=implicit-function-declaration"], + ["-Wno-error", "-bah", "-Wno-error=implicit-function-declaration"], ["-Werror", "-Werror-implicit-function-declaration"], ), ], @@ -907,3 +910,108 @@ def test_linker_strips_loopopt(wrapper_environment, wrapper_flags): result = cc(*(test_args + ["-loopopt=0", "-c", "x.c"]), output=str) result = result.strip().split("\n") assert "-loopopt=0" in result + + +def test_spack_managed_dirs_are_prioritized(wrapper_environment): + # We have two different stores with 5 packages divided over them + pkg1 = "/path/to/spack-1/opt/spack/linux-ubuntu22.04-zen2/gcc-13.2.0/pkg-1.0-abcdef" + pkg2 = "/path/to/spack-1/opt/spack/linux-ubuntu22.04-zen2/gcc-13.2.0/pkg-2.0-abcdef" + pkg3 = "/path/to/spack-2/opt/spack/linux-ubuntu22.04-zen2/gcc-13.2.0/pkg-3.0-abcdef" + pkg4 = "/path/to/spack-2/opt/spack/linux-ubuntu22.04-zen2/gcc-13.2.0/pkg-4.0-abcdef" + pkg5 = "/path/to/spack-2/opt/spack/linux-ubuntu22.04-zen2/gcc-13.2.0/pkg-5.0-abcdef" + + variables = { + # cppflags, ldflags from the command line, config or package.py take highest priority + "SPACK_CPPFLAGS": f"-I/usr/local/include -I/external-1/include -I{pkg1}/include", + "SPACK_LDFLAGS": f"-L/usr/local/lib -L/external-1/lib -L{pkg1}/lib " + f"-Wl,-rpath,/usr/local/lib -Wl,-rpath,/external-1/lib -Wl,-rpath,{pkg1}/lib", + # automatic -L, -Wl,-rpath, -I flags from dependencies -- on the spack side they are + # already partitioned into "spack owned prefixes" and "non-spack owned prefixes" + "SPACK_STORE_LINK_DIRS": f"{pkg4}/lib:{pkg5}/lib", + "SPACK_STORE_RPATH_DIRS": f"{pkg4}/lib:{pkg5}/lib", + "SPACK_STORE_INCLUDE_DIRS": f"{pkg4}/include:{pkg5}/include", + "SPACK_LINK_DIRS": "/external-3/lib:/external-4/lib", + "SPACK_RPATH_DIRS": "/external-3/lib:/external-4/lib", + "SPACK_INCLUDE_DIRS": "/external-3/include:/external-4/include", + } + + with set_env(SPACK_TEST_COMMAND="dump-args", **variables): + effective_call = ( + cc( + # system paths + "-I/usr/include", + "-L/usr/lib", + "-Wl,-rpath,/usr/lib", + # some other externals + "-I/external-2/include", + "-L/external-2/lib", + "-Wl,-rpath,/external-2/lib", + # relative paths are considered "spack managed" since they are in the stage dir + "-I..", + "-L..", + "-Wl,-rpath,..", # pathological but simpler for the test. + # spack store paths + f"-I{pkg2}/include", + f"-I{pkg3}/include", + f"-L{pkg2}/lib", + f"-L{pkg3}/lib", + f"-Wl,-rpath,{pkg2}/lib", + f"-Wl,-rpath,{pkg3}/lib", + "hello.c", + "-o", + "hello", + output=str, + ) + .strip() + .split("\n") + ) + + dash_I = [flag[2:] for flag in effective_call if flag.startswith("-I")] + dash_L = [flag[2:] for flag in effective_call if flag.startswith("-L")] + dash_Wl_rpath = [flag[11:] for flag in effective_call if flag.startswith("-Wl,-rpath")] + + assert dash_I == [ + # spack owned dirs from SPACK_*FLAGS + f"{pkg1}/include", + # spack owned dirs from command line & automatic flags for deps (in that order)] + "..", + f"{pkg2}/include", # from command line + f"{pkg3}/include", # from command line + f"{pkg4}/include", # from SPACK_STORE_INCLUDE_DIRS + f"{pkg5}/include", # from SPACK_STORE_INCLUDE_DIRS + # non-system dirs from SPACK_*FLAGS + "/external-1/include", + # non-system dirs from command line & automatic flags for deps (in that order) + "/external-2/include", # from command line + "/external-3/include", # from SPACK_INCLUDE_DIRS + "/external-4/include", # from SPACK_INCLUDE_DIRS + # system dirs from SPACK_*FLAGS + "/usr/local/include", + # system dirs from command line + "/usr/include", + ] + + assert ( + dash_L + == dash_Wl_rpath + == [ + # spack owned dirs from SPACK_*FLAGS + f"{pkg1}/lib", + # spack owned dirs from command line & automatic flags for deps (in that order) + "..", + f"{pkg2}/lib", # from command line + f"{pkg3}/lib", # from command line + f"{pkg4}/lib", # from SPACK_STORE_LINK_DIRS + f"{pkg5}/lib", # from SPACK_STORE_LINK_DIRS + # non-system dirs from SPACK_*FLAGS + "/external-1/lib", + # non-system dirs from command line & automatic flags for deps (in that order) + "/external-2/lib", # from command line + "/external-3/lib", # from SPACK_LINK_DIRS + "/external-4/lib", # from SPACK_LINK_DIRS + # system dirs from SPACK_*FLAGS + "/usr/local/lib", + # system dirs from command line + "/usr/lib", + ] + ) diff --git a/lib/spack/spack/test/ci.py b/lib/spack/spack/test/ci.py index e01b970c2dabbd..f2cca09c5a43ee 100644 --- a/lib/spack/spack/test/ci.py +++ b/lib/spack/spack/test/ci.py @@ -2,7 +2,6 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import itertools import os import subprocess @@ -11,15 +10,12 @@ import llnl.util.filesystem as fs import spack.ci as ci -import spack.ci_needs_workaround as cinw -import spack.ci_optimization as ci_opt import spack.config import spack.environment as ev import spack.error import spack.paths as spack_paths import spack.util.git import spack.util.gpg -import spack.util.spack_yaml as syaml @pytest.fixture @@ -51,7 +47,7 @@ def __init__(self, response_code=200, content_to_read=[]): self._content = content_to_read self._read = [False for c in content_to_read] - def open(self, request): + def open(self, request, data=None, timeout=object()): return self def getcode(self): @@ -203,165 +199,7 @@ def __call__(self, *args, **kwargs): assert "Unable to merge {0}".format(c1) in err -@pytest.mark.parametrize("obj, proto", [({}, [])]) -def test_ci_opt_argument_checking(obj, proto): - """Check that matches() and subkeys() return False when `proto` is not a dict.""" - assert not ci_opt.matches(obj, proto) - assert not ci_opt.subkeys(obj, proto) - - -@pytest.mark.parametrize("yaml", [{"extends": 1}]) -def test_ci_opt_add_extends_non_sequence(yaml): - """Check that add_extends() exits if 'extends' is not a sequence.""" - yaml_copy = yaml.copy() - ci_opt.add_extends(yaml, None) - assert yaml == yaml_copy - - -def test_ci_workarounds(): - fake_root_spec = "x" * 544 - fake_spack_ref = "x" * 40 - - common_variables = {"SPACK_IS_PR_PIPELINE": "False"} - - common_before_script = [ - 'git clone "https://github.com/spack/spack"', - " && ".join(("pushd ./spack", 'git checkout "{ref}"'.format(ref=fake_spack_ref), "popd")), - '. "./spack/share/spack/setup-env.sh"', - ] - - def make_build_job(name, deps, stage, use_artifact_buildcache, optimize, use_dependencies): - variables = common_variables.copy() - variables["SPACK_JOB_SPEC_PKG_NAME"] = name - - result = { - "stage": stage, - "tags": ["tag-0", "tag-1"], - "artifacts": { - "paths": ["jobs_scratch_dir", "cdash_report", name + ".spec.json", name], - "when": "always", - }, - "retry": {"max": 2, "when": ["always"]}, - "after_script": ['rm -rf "./spack"'], - "script": ["spack ci rebuild"], - "image": {"name": "spack/centos7", "entrypoint": [""]}, - } - - if optimize: - result["extends"] = [".c0", ".c1"] - else: - variables["SPACK_ROOT_SPEC"] = fake_root_spec - result["before_script"] = common_before_script - - result["variables"] = variables - - if use_dependencies: - result["dependencies"] = list(deps) if use_artifact_buildcache else [] - else: - result["needs"] = [{"job": dep, "artifacts": use_artifact_buildcache} for dep in deps] - - return {name: result} - - def make_rebuild_index_job(use_artifact_buildcache, optimize, use_dependencies): - result = { - "stage": "stage-rebuild-index", - "script": "spack buildcache update-index s3://mirror", - "tags": ["tag-0", "tag-1"], - "image": {"name": "spack/centos7", "entrypoint": [""]}, - "after_script": ['rm -rf "./spack"'], - } - - if optimize: - result["extends"] = ".c0" - else: - result["before_script"] = common_before_script - - return {"rebuild-index": result} - - def make_factored_jobs(optimize): - return ( - { - ".c0": {"before_script": common_before_script}, - ".c1": {"variables": {"SPACK_ROOT_SPEC": fake_root_spec}}, - } - if optimize - else {} - ) - - def make_stage_list(num_build_stages): - return { - "stages": ( - ["-".join(("stage", str(i))) for i in range(num_build_stages)] - + ["stage-rebuild-index"] - ) - } - - def make_yaml_obj(use_artifact_buildcache, optimize, use_dependencies): - result = {} - - result.update( - make_build_job( - "pkg-a", [], "stage-0", use_artifact_buildcache, optimize, use_dependencies - ) - ) - - result.update( - make_build_job( - "pkg-b", ["pkg-a"], "stage-1", use_artifact_buildcache, optimize, use_dependencies - ) - ) - - result.update( - make_build_job( - "pkg-c", - ["pkg-a", "pkg-b"], - "stage-2", - use_artifact_buildcache, - optimize, - use_dependencies, - ) - ) - - result.update(make_rebuild_index_job(use_artifact_buildcache, optimize, use_dependencies)) - - result.update(make_factored_jobs(optimize)) - - result.update(make_stage_list(3)) - - return result - - # test every combination of: - # use artifact buildcache: true or false - # run optimization pass: true or false - # convert needs to dependencies: true or false - for use_ab in (False, True): - original = make_yaml_obj( - use_artifact_buildcache=use_ab, optimize=False, use_dependencies=False - ) - - for opt, deps in itertools.product(*(((False, True),) * 2)): - # neither optimizing nor converting needs->dependencies - if not (opt or deps): - # therefore, nothing to test - continue - - predicted = make_yaml_obj( - use_artifact_buildcache=use_ab, optimize=opt, use_dependencies=deps - ) - - actual = original.copy() - if opt: - actual = ci_opt.optimizer(actual) - if deps: - actual = cinw.needs_to_dependencies(actual) - - predicted = syaml.dump_config(ci_opt.sort_yaml_obj(predicted), default_flow_style=True) - actual = syaml.dump_config(ci_opt.sort_yaml_obj(actual), default_flow_style=True) - - assert predicted == actual - - -def test_get_spec_filter_list(mutable_mock_env_path, config, mutable_mock_repo): +def test_get_spec_filter_list(mutable_mock_env_path, mutable_mock_repo): """Test that given an active environment and list of touched pkgs, we get the right list of possibly-changed env specs""" e1 = ev.create("test") @@ -415,7 +253,7 @@ def test_get_spec_filter_list(mutable_mock_env_path, config, mutable_mock_repo): @pytest.mark.regression("29947") -def test_affected_specs_on_first_concretization(mutable_mock_env_path, mock_packages, config): +def test_affected_specs_on_first_concretization(mutable_mock_env_path, mock_packages): e = ev.create("first_concretization") e.add("mpileaks~shared") e.add("mpileaks+shared") @@ -448,7 +286,7 @@ def _fail(self, args): def test_ci_create_buildcache(tmpdir, working_env, config, mock_packages, monkeypatch): """Test that create_buildcache returns a list of objects with the correct keys and types.""" - monkeypatch.setattr(spack.ci, "push_mirror_contents", lambda a, b, c: True) + monkeypatch.setattr(spack.ci, "_push_to_build_cache", lambda a, b, c: True) results = ci.create_buildcache( None, destination_mirror_urls=["file:///fake-url-one", "file:///fake-url-two"] @@ -484,12 +322,12 @@ def test_ci_run_standalone_tests_missing_requirements( @pytest.mark.not_on_windows("Reliance on bash script not supported on Windows") def test_ci_run_standalone_tests_not_installed_junit( - tmp_path, repro_dir, working_env, default_mock_concretization, mock_test_stage, capfd + tmp_path, repro_dir, working_env, mock_test_stage, capfd, mock_packages ): log_file = tmp_path / "junit.xml" args = { "log_file": str(log_file), - "job_spec": default_mock_concretization("printing-package"), + "job_spec": spack.spec.Spec("printing-package").concretized(), "repro_dir": str(repro_dir), "fail_fast": True, } @@ -502,13 +340,13 @@ def test_ci_run_standalone_tests_not_installed_junit( @pytest.mark.not_on_windows("Reliance on bash script not supported on Windows") def test_ci_run_standalone_tests_not_installed_cdash( - tmp_path, repro_dir, working_env, default_mock_concretization, mock_test_stage, capfd + tmp_path, repro_dir, working_env, mock_test_stage, capfd, mock_packages ): """Test run_standalone_tests with cdash and related options.""" log_file = tmp_path / "junit.xml" args = { "log_file": str(log_file), - "job_spec": default_mock_concretization("printing-package"), + "job_spec": spack.spec.Spec("printing-package").concretized(), "repro_dir": str(repro_dir), } diff --git a/lib/spack/spack/test/cmd/buildcache.py b/lib/spack/spack/test/cmd/buildcache.py index 06d0c1d751e6a3..b634e371165dc3 100644 --- a/lib/spack/spack/test/cmd/buildcache.py +++ b/lib/spack/spack/test/cmd/buildcache.py @@ -4,6 +4,7 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) import errno +import json import os import shutil @@ -47,11 +48,6 @@ def mock_get_specs_multiarch(database, monkeypatch): monkeypatch.setattr(spack.binary_distribution, "update_cache_and_get_specs", lambda: specs) -def test_buildcache_preview_just_runs(): - # TODO: remove in Spack 0.21 - buildcache("preview", "mpileaks") - - @pytest.mark.db @pytest.mark.regression("13757") def test_buildcache_list_duplicates(mock_get_specs, capsys): @@ -168,13 +164,27 @@ def test_update_key_index( assert "index.json" in key_dir_list +def test_buildcache_autopush(tmp_path, install_mockery, mock_fetch): + """Test buildcache with autopush""" + mirror_dir = tmp_path / "mirror" + mirror_autopush_dir = tmp_path / "mirror_autopush" + + mirror("add", "--unsigned", "mirror", mirror_dir.as_uri()) + mirror("add", "--autopush", "--unsigned", "mirror-autopush", mirror_autopush_dir.as_uri()) + + s = Spec("libdwarf").concretized() + + # Install and generate build cache index + s.package.do_install() + + metadata_file = spack.binary_distribution.tarball_name(s, ".spec.json") + + assert not (mirror_dir / "build_cache" / metadata_file).exists() + assert (mirror_autopush_dir / "build_cache" / metadata_file).exists() + + def test_buildcache_sync( - mutable_mock_env_path, - install_mockery_mutable_config, - mock_packages, - mock_fetch, - mock_stage, - tmpdir, + mutable_mock_env_path, install_mockery, mock_packages, mock_fetch, mock_stage, tmpdir ): """ Make sure buildcache sync works in an environment-aware manner, ignoring @@ -234,15 +244,76 @@ def verify_mirror_contents(): # Use mirror names to specify mirrors mirror("add", "src", src_mirror_url) mirror("add", "dest", dest_mirror_url) + mirror("add", "ignored", "file:///dummy/io") buildcache("sync", "src", "dest") verify_mirror_contents() + shutil.rmtree(dest_mirror_dir) + + def manifest_insert(manifest, spec, dest_url): + manifest[spec.dag_hash()] = [ + { + "src": spack.util.url.join( + src_mirror_url, + spack.binary_distribution.build_cache_relative_path(), + spack.binary_distribution.tarball_name(spec, ".spec.json"), + ), + "dest": spack.util.url.join( + dest_url, + spack.binary_distribution.build_cache_relative_path(), + spack.binary_distribution.tarball_name(spec, ".spec.json"), + ), + }, + { + "src": spack.util.url.join( + src_mirror_url, + spack.binary_distribution.build_cache_relative_path(), + spack.binary_distribution.tarball_path_name(spec, ".spack"), + ), + "dest": spack.util.url.join( + dest_url, + spack.binary_distribution.build_cache_relative_path(), + spack.binary_distribution.tarball_path_name(spec, ".spack"), + ), + }, + ] + + manifest_file = os.path.join(tmpdir.strpath, "manifest_dest.json") + with open(manifest_file, "w") as fd: + test_env = ev.active_environment() + + manifest = {} + for spec in test_env.specs_by_hash.values(): + manifest_insert(manifest, spec, dest_mirror_url) + json.dump(manifest, fd) + + buildcache("sync", "--manifest-glob", manifest_file) + + verify_mirror_contents() + shutil.rmtree(dest_mirror_dir) + + manifest_file = os.path.join(tmpdir.strpath, "manifest_bad_dest.json") + with open(manifest_file, "w") as fd: + manifest = {} + for spec in test_env.specs_by_hash.values(): + manifest_insert( + manifest, spec, spack.util.url.join(dest_mirror_url, "invalid_path") + ) + json.dump(manifest, fd) + + # Trigger the warning + output = buildcache("sync", "--manifest-glob", manifest_file, "dest", "ignored") + + assert "Ignoring unused arguemnt: ignored" in output + + verify_mirror_contents() + shutil.rmtree(dest_mirror_dir) def test_buildcache_create_install( mutable_mock_env_path, - install_mockery_mutable_config, + install_mockery, mock_packages, mock_fetch, mock_stage, @@ -365,3 +436,10 @@ def test_push_and_install_with_mirror_marked_unsigned_does_not_require_extra_fla spec.package.do_uninstall(force=True) spec.package.do_install(**kwargs) + + +def test_skip_no_redistribute(mock_packages, config): + specs = list(Spec("no-redistribute-dependent").concretized().traverse()) + filtered = spack.cmd.buildcache._skip_no_redistribute_for_public(specs) + assert not any(s.name == "no-redistribute" for s in filtered) + assert any(s.name == "no-redistribute-dependent" for s in filtered) diff --git a/lib/spack/spack/test/cmd/checksum.py b/lib/spack/spack/test/cmd/checksum.py index 308940c268f948..ad63c40ff8ec44 100644 --- a/lib/spack/spack/test/cmd/checksum.py +++ b/lib/spack/spack/test/cmd/checksum.py @@ -83,7 +83,6 @@ def test_checksum_args(arguments, expected): assert check == expected -@pytest.mark.not_on_windows("Not supported on Windows (yet)") @pytest.mark.parametrize( "arguments,expected", [ diff --git a/lib/spack/spack/test/cmd/ci.py b/lib/spack/spack/test/cmd/ci.py index 8209040d878cb2..c1018050323de9 100644 --- a/lib/spack/spack/test/cmd/ci.py +++ b/lib/spack/spack/test/cmd/ci.py @@ -26,6 +26,7 @@ import spack.util.gpg import spack.util.spack_yaml as syaml import spack.util.url as url_util +from spack.cmd.ci import FAILED_CREATE_BUILDCACHE_CODE from spack.schema.buildcache_spec import schema as specfile_schema from spack.schema.ci import schema as ci_schema from spack.schema.database_index import schema as db_idx_schema @@ -47,6 +48,8 @@ @pytest.fixture() def ci_base_environment(working_env, tmpdir): os.environ["CI_PROJECT_DIR"] = tmpdir.strpath + os.environ["CI_PIPELINE_ID"] = "7192" + os.environ["CI_JOB_NAME"] = "mock" @pytest.fixture(scope="function") @@ -103,24 +106,24 @@ def test_specs_staging(config, tmpdir): """ builder = repo.MockRepositoryBuilder(tmpdir) - builder.add_package("g") - builder.add_package("f") - builder.add_package("e") - builder.add_package("d", dependencies=[("f", None, None), ("g", None, None)]) - builder.add_package("c") - builder.add_package("b", dependencies=[("d", None, None), ("e", None, None)]) - builder.add_package("a", dependencies=[("b", None, None), ("c", None, None)]) + builder.add_package("pkg-g") + builder.add_package("pkg-f") + builder.add_package("pkg-e") + builder.add_package("pkg-d", dependencies=[("pkg-f", None, None), ("pkg-g", None, None)]) + builder.add_package("pkg-c") + builder.add_package("pkg-b", dependencies=[("pkg-d", None, None), ("pkg-e", None, None)]) + builder.add_package("pkg-a", dependencies=[("pkg-b", None, None), ("pkg-c", None, None)]) with repo.use_repositories(builder.root): - spec_a = Spec("a").concretized() + spec_a = Spec("pkg-a").concretized() - spec_a_label = ci._spec_deps_key(spec_a) - spec_b_label = ci._spec_deps_key(spec_a["b"]) - spec_c_label = ci._spec_deps_key(spec_a["c"]) - spec_d_label = ci._spec_deps_key(spec_a["d"]) - spec_e_label = ci._spec_deps_key(spec_a["e"]) - spec_f_label = ci._spec_deps_key(spec_a["f"]) - spec_g_label = ci._spec_deps_key(spec_a["g"]) + spec_a_label = ci._spec_ci_label(spec_a) + spec_b_label = ci._spec_ci_label(spec_a["pkg-b"]) + spec_c_label = ci._spec_ci_label(spec_a["pkg-c"]) + spec_d_label = ci._spec_ci_label(spec_a["pkg-d"]) + spec_e_label = ci._spec_ci_label(spec_a["pkg-e"]) + spec_f_label = ci._spec_ci_label(spec_a["pkg-f"]) + spec_g_label = ci._spec_ci_label(spec_a["pkg-g"]) spec_labels, dependencies, stages = ci.stage_spec_jobs([spec_a]) @@ -745,7 +748,7 @@ def test_ci_rebuild_mock_success( tmpdir, working_env, mutable_mock_env_path, - install_mockery_mutable_config, + install_mockery, mock_gnupghome, mock_stage, mock_fetch, @@ -757,7 +760,6 @@ def test_ci_rebuild_mock_success( rebuild_env = create_rebuild_env(tmpdir, pkg_name, broken_tests) monkeypatch.setattr(spack.cmd.ci, "SPACK_COMMAND", "echo") - monkeypatch.setattr(spack.cmd.ci, "MAKE_COMMAND", "echo") with rebuild_env.env_dir.as_cwd(): activate_rebuild_env(tmpdir, pkg_name, rebuild_env) @@ -776,12 +778,49 @@ def test_ci_rebuild_mock_success( assert "Cannot copy test logs" in out +def test_ci_rebuild_mock_failure_to_push( + tmpdir, + working_env, + mutable_mock_env_path, + install_mockery, + mock_gnupghome, + mock_stage, + mock_fetch, + mock_binary_index, + ci_base_environment, + monkeypatch, +): + pkg_name = "trivial-install-test-package" + rebuild_env = create_rebuild_env(tmpdir, pkg_name) + + # Mock the install script succuess + def mock_success(*args, **kwargs): + return 0 + + monkeypatch.setattr(spack.ci, "process_command", mock_success) + + # Mock failure to push to the build cache + def mock_push_or_raise(*args, **kwargs): + raise spack.binary_distribution.PushToBuildCacheError( + "Encountered problem pushing binary : " + ) + + monkeypatch.setattr(spack.binary_distribution, "push_or_raise", mock_push_or_raise) + + with rebuild_env.env_dir.as_cwd(): + activate_rebuild_env(tmpdir, pkg_name, rebuild_env) + + expect = f"Command exited with code {FAILED_CREATE_BUILDCACHE_CODE}" + with pytest.raises(spack.main.SpackCommandError, match=expect): + ci_cmd("rebuild", fail_on_error=True) + + @pytest.mark.skip(reason="fails intermittently and covered by gitlab ci") def test_ci_rebuild( tmpdir, working_env, mutable_mock_env_path, - install_mockery_mutable_config, + install_mockery, mock_packages, monkeypatch, mock_gnupghome, @@ -803,7 +842,6 @@ def test_ci_rebuild( ci_cmd("rebuild", "--tests", fail_on_error=False) monkeypatch.setattr(spack.cmd.ci, "SPACK_COMMAND", "notcommand") - monkeypatch.setattr(spack.cmd.ci, "MAKE_COMMAND", "notcommand") monkeypatch.setattr(spack.cmd.ci, "INSTALL_FAIL_CODE", 127) with rebuild_env.env_dir.as_cwd(): @@ -981,7 +1019,7 @@ def fake_dl_method(spec, *args, **kwargs): def test_ci_generate_mirror_override( tmpdir, mutable_mock_env_path, - install_mockery_mutable_config, + install_mockery, mock_packages, mock_fetch, mock_stage, @@ -1063,10 +1101,10 @@ def test_ci_generate_mirror_override( @pytest.mark.disable_clean_stage_check -def test_push_mirror_contents( +def test_push_to_build_cache( tmpdir, mutable_mock_env_path, - install_mockery_mutable_config, + install_mockery, mock_packages, mock_fetch, mock_stage, @@ -1124,7 +1162,7 @@ def test_push_mirror_contents( install_cmd("--add", "--keep-stage", json_path) for s in concrete_spec.traverse(): - ci.push_mirror_contents(s, mirror_url, True) + ci.push_to_build_cache(s, mirror_url, True) buildcache_path = os.path.join(mirror_dir.strpath, "build_cache") @@ -1217,21 +1255,16 @@ def test_push_mirror_contents( assert len(dl_dir_list) == 2 -def test_push_mirror_contents_exceptions(monkeypatch, capsys): - def failing_access(*args, **kwargs): +def test_push_to_build_cache_exceptions(monkeypatch, tmp_path, capsys): + def _push_to_build_cache(spec, sign_binaries, mirror_url): raise Exception("Error: Access Denied") - monkeypatch.setattr(spack.ci, "_push_mirror_contents", failing_access) - - # Input doesn't matter, as wwe are faking exceptional output - url = "fakejunk" - ci.push_mirror_contents(None, url, None) - - captured = capsys.readouterr() - std_out = captured[0] - expect_msg = "Permission problem writing to {0}".format(url) + monkeypatch.setattr(spack.ci, "_push_to_build_cache", _push_to_build_cache) - assert expect_msg in std_out + # Input doesn't matter, as we are faking exceptional output + url = tmp_path.as_uri() + ci.push_to_build_cache(None, url, None) + assert f"Permission problem writing to {url}" in capsys.readouterr().err @pytest.mark.parametrize("match_behavior", ["first", "merge"]) @@ -1257,7 +1290,7 @@ def test_ci_generate_override_runner_attrs( spack: specs: - flatten-deps - - a + - pkg-a mirrors: some-mirror: https://my.fake.mirror ci: @@ -1274,12 +1307,12 @@ def test_ci_generate_override_runner_attrs( - match: - dependency-install - match: - - a + - pkg-a build-job: tags: - specific-a-2 - match: - - a + - pkg-a build-job-remove: tags: - toplevel2 @@ -1339,8 +1372,8 @@ def test_ci_generate_override_runner_attrs( assert global_vars["SPACK_CHECKOUT_VERSION"] == git_version or "v0.20.0.test0" for ci_key in yaml_contents.keys(): - if ci_key.startswith("a"): - # Make sure a's attributes override variables, and all the + if ci_key.startswith("pkg-a"): + # Make sure pkg-a's attributes override variables, and all the # scripts. Also, make sure the 'toplevel' tag doesn't # appear twice, but that a's specific extra tag does appear the_elt = yaml_contents[ci_key] @@ -1399,55 +1432,6 @@ def test_ci_generate_override_runner_attrs( assert the_elt["after_script"][0] == "post step one" -def test_ci_generate_with_workarounds( - tmpdir, mutable_mock_env_path, install_mockery, mock_packages, monkeypatch, ci_base_environment -): - """Make sure the post-processing cli workarounds do what they should""" - filename = str(tmpdir.join("spack.yaml")) - with open(filename, "w") as f: - f.write( - """\ -spack: - specs: - - callpath%gcc@=9.5 - mirrors: - some-mirror: https://my.fake.mirror - ci: - pipeline-gen: - - submapping: - - match: ['%gcc@9.5'] - build-job: - tags: - - donotcare - image: donotcare - enable-artifacts-buildcache: true -""" - ) - - with tmpdir.as_cwd(): - env_cmd("create", "test", "./spack.yaml") - outputfile = str(tmpdir.join(".gitlab-ci.yml")) - - with ev.read("test"): - ci_cmd("generate", "--output-file", outputfile, "--dependencies") - - with open(outputfile) as f: - contents = f.read() - yaml_contents = syaml.load(contents) - - found_one = False - non_rebuild_keys = ["workflow", "stages", "variables", "rebuild-index"] - - for ci_key in yaml_contents.keys(): - if ci_key not in non_rebuild_keys: - found_one = True - job_obj = yaml_contents[ci_key] - assert "needs" not in job_obj - assert "dependencies" in job_obj - - assert found_one is True - - @pytest.mark.disable_clean_stage_check def test_ci_rebuild_index( tmpdir, @@ -1461,26 +1445,24 @@ def test_ci_rebuild_index( working_dir = tmpdir.join("working_dir") mirror_dir = working_dir.join("mirror") - mirror_url = "file://{0}".format(mirror_dir.strpath) + mirror_url = url_util.path_to_file_url(str(mirror_dir)) - spack_yaml_contents = """ + spack_yaml_contents = f""" spack: - specs: - - callpath - mirrors: - test-mirror: {0} - ci: - pipeline-gen: - - submapping: - - match: - - patchelf - build-job: - tags: - - donotcare - image: donotcare -""".format( - mirror_url - ) + specs: + - callpath + mirrors: + test-mirror: {mirror_url} + ci: + pipeline-gen: + - submapping: + - match: + - patchelf + build-job: + tags: + - donotcare + image: donotcare +""" filename = str(tmpdir.join("spack.yaml")) with open(filename, "w") as f: @@ -1799,7 +1781,7 @@ def test_ci_generate_read_broken_specs_url( tmpdir, mutable_mock_env_path, install_mockery, mock_packages, monkeypatch, ci_base_environment ): """Verify that `broken-specs-url` works as intended""" - spec_a = Spec("a") + spec_a = Spec("pkg-a") spec_a.concretize() a_dag_hash = spec_a.dag_hash() @@ -1825,7 +1807,7 @@ def test_ci_generate_read_broken_specs_url( spack: specs: - flatten-deps - - a + - pkg-a mirrors: some-mirror: https://my.fake.mirror ci: @@ -1833,9 +1815,9 @@ def test_ci_generate_read_broken_specs_url( pipeline-gen: - submapping: - match: - - a + - pkg-a - flatten-deps - - b + - pkg-b - dependency-install build-job: tags: diff --git a/lib/spack/spack/test/cmd/clean.py b/lib/spack/spack/test/cmd/clean.py index 43441c487c3af3..4c3586833398ce 100644 --- a/lib/spack/spack/test/cmd/clean.py +++ b/lib/spack/spack/test/cmd/clean.py @@ -11,6 +11,7 @@ import spack.caches import spack.cmd.clean +import spack.environment as ev import spack.main import spack.package_base import spack.stage @@ -68,6 +69,20 @@ def test_function_calls(command_line, effects, mock_calls_for_clean): assert mock_calls_for_clean[name] == (1 if name in effects else 0) +def test_env_aware_clean(mock_stage, install_mockery, mutable_mock_env_path, monkeypatch): + e = ev.create("test", with_view=False) + e.add("mpileaks") + e.concretize() + + def fail(*args, **kwargs): + raise Exception("This should not have been called") + + monkeypatch.setattr(spack.spec.Spec, "concretize", fail) + + with e: + clean("mpileaks") + + def test_remove_python_cache(tmpdir, monkeypatch): cache_files = ["file1.pyo", "file2.pyc"] source_file = "file1.py" diff --git a/lib/spack/spack/test/cmd/common/arguments.py b/lib/spack/spack/test/cmd/common/arguments.py index c1f75e99f3bdbd..167130816f65b8 100644 --- a/lib/spack/spack/test/cmd/common/arguments.py +++ b/lib/spack/spack/test/cmd/common/arguments.py @@ -72,7 +72,6 @@ def test_parse_spec_flags_with_spaces(specs, cflags, propagation, negated_varian assert "~{0}".format(v) in s -@pytest.mark.usefixtures("config") def test_match_spec_env(mock_packages, mutable_mock_env_path): """ Concretize a spec with non-default options in an environment. Make @@ -81,59 +80,64 @@ def test_match_spec_env(mock_packages, mutable_mock_env_path): """ # Initial sanity check: we are planning on choosing a non-default # value, so make sure that is in fact not the default. - check_defaults = spack.cmd.parse_specs(["a"], concretize=True)[0] + check_defaults = spack.cmd.parse_specs(["pkg-a"], concretize=True)[0] assert not check_defaults.satisfies("foobar=baz") e = ev.create("test") - e.add("a foobar=baz") + e.add("pkg-a foobar=baz") e.concretize() with e: - env_spec = spack.cmd.matching_spec_from_env(spack.cmd.parse_specs(["a"])[0]) + env_spec = spack.cmd.matching_spec_from_env(spack.cmd.parse_specs(["pkg-a"])[0]) assert env_spec.satisfies("foobar=baz") assert env_spec.concrete -@pytest.mark.usefixtures("config") def test_multiple_env_match_raises_error(mock_packages, mutable_mock_env_path): e = ev.create("test") - e.add("a foobar=baz") - e.add("a foobar=fee") + e.add("pkg-a foobar=baz") + e.add("pkg-a foobar=fee") e.concretize() with e: with pytest.raises(ev.SpackEnvironmentError) as exc_info: - spack.cmd.matching_spec_from_env(spack.cmd.parse_specs(["a"])[0]) + spack.cmd.matching_spec_from_env(spack.cmd.parse_specs(["pkg-a"])[0]) assert "matches multiple specs" in exc_info.value.message -@pytest.mark.usefixtures("config") def test_root_and_dep_match_returns_root(mock_packages, mutable_mock_env_path): e = ev.create("test") - e.add("b@0.9") - e.add("a foobar=bar") # Depends on b, should choose b@1.0 + e.add("pkg-b@0.9") + e.add("pkg-a foobar=bar") # Depends on b, should choose b@1.0 e.concretize() with e: # This query matches the root b and b as a dependency of a. In that # case the root instance should be preferred. - env_spec1 = spack.cmd.matching_spec_from_env(spack.cmd.parse_specs(["b"])[0]) + env_spec1 = spack.cmd.matching_spec_from_env(spack.cmd.parse_specs(["pkg-b"])[0]) assert env_spec1.satisfies("@0.9") - env_spec2 = spack.cmd.matching_spec_from_env(spack.cmd.parse_specs(["b@1.0"])[0]) + env_spec2 = spack.cmd.matching_spec_from_env(spack.cmd.parse_specs(["pkg-b@1.0"])[0]) assert env_spec2 @pytest.mark.parametrize( - "arg,config", [("--reuse", True), ("--fresh", False), ("--reuse-deps", "dependencies")] + "arg,conf", + [ + ("--reuse", True), + ("--fresh", False), + ("--reuse-deps", "dependencies"), + ("--fresh-roots", "dependencies"), + ], ) -def test_concretizer_arguments(mutable_config, mock_packages, arg, config): +def test_concretizer_arguments(mutable_config, mock_packages, arg, conf): """Ensure that ConfigSetAction is doing the right thing.""" spec = spack.main.SpackCommand("spec") - assert spack.config.get("concretizer:reuse", None) is None + assert spack.config.get("concretizer:reuse", None, scope="command_line") is None spec(arg, "zlib") - assert spack.config.get("concretizer:reuse", None) == config + assert spack.config.get("concretizer:reuse", None) == conf + assert spack.config.get("concretizer:reuse", None, scope="command_line") == conf def test_use_buildcache_type(): diff --git a/lib/spack/spack/test/cmd/compiler.py b/lib/spack/spack/test/cmd/compiler.py index 849b9e70184e2a..2fde7fbc929d81 100644 --- a/lib/spack/spack/test/cmd/compiler.py +++ b/lib/spack/spack/test/cmd/compiler.py @@ -112,10 +112,10 @@ def test_compiler_find_no_apple_gcc(no_compilers_yaml, working_env, mock_executa @pytest.mark.regression("37996") def test_compiler_remove(mutable_config, mock_packages): """Tests that we can remove a compiler from configuration.""" - assert spack.spec.CompilerSpec("gcc@=4.5.0") in spack.compilers.all_compiler_specs() - args = spack.util.pattern.Bunch(all=True, compiler_spec="gcc@4.5.0", add_paths=[], scope=None) + assert spack.spec.CompilerSpec("gcc@=9.4.0") in spack.compilers.all_compiler_specs() + args = spack.util.pattern.Bunch(all=True, compiler_spec="gcc@9.4.0", add_paths=[], scope=None) spack.cmd.compiler.compiler_remove(args) - assert spack.spec.CompilerSpec("gcc@=4.5.0") not in spack.compilers.all_compiler_specs() + assert spack.spec.CompilerSpec("gcc@=9.4.0") not in spack.compilers.all_compiler_specs() @pytest.mark.regression("37996") @@ -124,10 +124,10 @@ def test_removing_compilers_from_multiple_scopes(mutable_config, mock_packages): site_config = spack.config.get("compilers", scope="site") spack.config.set("compilers", site_config, scope="user") - assert spack.spec.CompilerSpec("gcc@=4.5.0") in spack.compilers.all_compiler_specs() - args = spack.util.pattern.Bunch(all=True, compiler_spec="gcc@4.5.0", add_paths=[], scope=None) + assert spack.spec.CompilerSpec("gcc@=9.4.0") in spack.compilers.all_compiler_specs() + args = spack.util.pattern.Bunch(all=True, compiler_spec="gcc@9.4.0", add_paths=[], scope=None) spack.cmd.compiler.compiler_remove(args) - assert spack.spec.CompilerSpec("gcc@=4.5.0") not in spack.compilers.all_compiler_specs() + assert spack.spec.CompilerSpec("gcc@=9.4.0") not in spack.compilers.all_compiler_specs() @pytest.mark.not_on_windows("Cannot execute bash script on Windows") @@ -175,7 +175,9 @@ def test_compiler_find_mixed_suffixes( assert "clang@11.0.0" in output assert "gcc@8.4.0" in output - config = spack.compilers.get_compiler_config("site", False) + config = spack.compilers.get_compiler_config( + no_compilers_yaml, scope="site", init_config=False + ) clang = next(c["compiler"] for c in config if c["compiler"]["spec"] == "clang@=11.0.0") gcc = next(c["compiler"] for c in config if c["compiler"]["spec"] == "gcc@=8.4.0") @@ -210,7 +212,9 @@ def test_compiler_find_prefer_no_suffix(no_compilers_yaml, working_env, compiler assert "clang@11.0.0" in output assert "gcc@8.4.0" in output - config = spack.compilers.get_compiler_config("site", False) + config = spack.compilers.get_compiler_config( + no_compilers_yaml, scope="site", init_config=False + ) clang = next(c["compiler"] for c in config if c["compiler"]["spec"] == "clang@=11.0.0") assert clang["paths"]["cc"] == str(compilers_dir / "clang") @@ -229,7 +233,9 @@ def test_compiler_find_path_order(no_compilers_yaml, working_env, compilers_dir) compiler("find", "--scope=site") - config = spack.compilers.get_compiler_config("site", False) + config = spack.compilers.get_compiler_config( + no_compilers_yaml, scope="site", init_config=False + ) gcc = next(c["compiler"] for c in config if c["compiler"]["spec"] == "gcc@=8.4.0") assert gcc["paths"] == { "cc": str(new_dir / "gcc-8"), @@ -255,15 +261,14 @@ def test_compiler_list_empty(no_compilers_yaml, working_env, compilers_dir): [ ( { - "spec": "gcc@=7.7.7 os=foobar target=x86_64", + "spec": "gcc@=7.7.7 languages=c,cxx,fortran os=foobar target=x86_64", "prefix": "/path/to/fake", "modules": ["gcc/7.7.7", "foobar"], "extra_attributes": { - "paths": { - "cc": "/path/to/fake/gcc", + "compilers": { + "c": "/path/to/fake/gcc", "cxx": "/path/to/fake/g++", - "fc": "/path/to/fake/gfortran", - "f77": "/path/to/fake/gfortran", + "fortran": "/path/to/fake/gfortran", }, "flags": {"fflags": "-ffree-form"}, }, @@ -279,26 +284,7 @@ def test_compiler_list_empty(no_compilers_yaml, working_env, compilers_dir): \tmodules = ['gcc/7.7.7', 'foobar'] \toperating system = foobar """, - ), - ( - { - "spec": "gcc@7.7.7", - "prefix": "{prefix}", - "modules": ["gcc/7.7.7", "foobar"], - "extra_attributes": {"flags": {"fflags": "-ffree-form"}}, - }, - """gcc@7.7.7: -\tpaths: -\t\tcc = {compilers_dir}{sep}gcc-8{suffix} -\t\tcxx = {compilers_dir}{sep}g++-8{suffix} -\t\tf77 = {compilers_dir}{sep}gfortran-8{suffix} -\t\tfc = {compilers_dir}{sep}gfortran-8{suffix} -\tflags: -\t\tfflags = ['-ffree-form'] -\tmodules = ['gcc/7.7.7', 'foobar'] -\toperating system = debian6 -""", - ), + ) ], ) def test_compilers_shows_packages_yaml( diff --git a/lib/spack/spack/test/cmd/concretize.py b/lib/spack/spack/test/cmd/concretize.py index da3cec034d9d97..806675a07c2685 100644 --- a/lib/spack/spack/test/cmd/concretize.py +++ b/lib/spack/spack/test/cmd/concretize.py @@ -10,7 +10,7 @@ from spack import spack_version from spack.main import SpackCommand -pytestmark = pytest.mark.usefixtures("config", "mutable_mock_repo") +pytestmark = pytest.mark.usefixtures("mutable_config", "mutable_mock_repo") env = SpackCommand("env") add = SpackCommand("add") @@ -51,8 +51,8 @@ def test_concretize_root_test_dependencies_are_concretized(unify, mutable_mock_e with ev.read("test") as e: e.unify = unify - add("a") - add("b") + add("pkg-a") + add("pkg-b") concretize("--test", "root") assert e.matching_spec("test-dependency") diff --git a/lib/spack/spack/test/cmd/config.py b/lib/spack/spack/test/cmd/config.py index 6bc19831a5f2b3..09f6fd167d31a1 100644 --- a/lib/spack/spack/test/cmd/config.py +++ b/lib/spack/spack/test/cmd/config.py @@ -640,4 +640,4 @@ def update_config(data): config("update", "-y", "config") with ev.Environment(str(tmpdir)) as e: - assert not e.manifest.pristine_yaml_content["spack"]["config"]["ccache"] + assert not e.manifest.yaml_content["spack"]["config"]["ccache"] diff --git a/lib/spack/spack/test/cmd/deconcretize.py b/lib/spack/spack/test/cmd/deconcretize.py index 92553b7e535d57..06dbd39458b170 100644 --- a/lib/spack/spack/test/cmd/deconcretize.py +++ b/lib/spack/spack/test/cmd/deconcretize.py @@ -12,29 +12,29 @@ @pytest.fixture(scope="function") -def test_env(mutable_mock_env_path, config, mock_packages): +def test_env(mutable_mock_env_path, mock_packages): ev.create("test") with ev.read("test") as e: - e.add("a@2.0 foobar=bar ^b@1.0") - e.add("a@1.0 foobar=bar ^b@0.9") + e.add("pkg-a@2.0 foobar=bar ^pkg-b@1.0") + e.add("pkg-a@1.0 foobar=bar ^pkg-b@0.9") e.concretize() e.write() def test_deconcretize_dep(test_env): with ev.read("test") as e: - deconcretize("-y", "b@1.0") + deconcretize("-y", "pkg-b@1.0") specs = [s for s, _ in e.concretized_specs()] assert len(specs) == 1 - assert specs[0].satisfies("a@1.0") + assert specs[0].satisfies("pkg-a@1.0") def test_deconcretize_all_dep(test_env): with ev.read("test") as e: with pytest.raises(SpackCommandError): - deconcretize("-y", "b") - deconcretize("-y", "--all", "b") + deconcretize("-y", "pkg-b") + deconcretize("-y", "--all", "pkg-b") specs = [s for s, _ in e.concretized_specs()] assert len(specs) == 0 @@ -42,27 +42,27 @@ def test_deconcretize_all_dep(test_env): def test_deconcretize_root(test_env): with ev.read("test") as e: - output = deconcretize("-y", "--root", "b@1.0") + output = deconcretize("-y", "--root", "pkg-b@1.0") assert "No matching specs to deconcretize" in output assert len(e.concretized_order) == 2 - deconcretize("-y", "--root", "a@2.0") + deconcretize("-y", "--root", "pkg-a@2.0") specs = [s for s, _ in e.concretized_specs()] assert len(specs) == 1 - assert specs[0].satisfies("a@1.0") + assert specs[0].satisfies("pkg-a@1.0") def test_deconcretize_all_root(test_env): with ev.read("test") as e: with pytest.raises(SpackCommandError): - deconcretize("-y", "--root", "a") + deconcretize("-y", "--root", "pkg-a") - output = deconcretize("-y", "--root", "--all", "b") + output = deconcretize("-y", "--root", "--all", "pkg-b") assert "No matching specs to deconcretize" in output assert len(e.concretized_order) == 2 - deconcretize("-y", "--root", "--all", "a") + deconcretize("-y", "--root", "--all", "pkg-a") specs = [s for s, _ in e.concretized_specs()] assert len(specs) == 0 diff --git a/lib/spack/spack/test/cmd/deprecate.py b/lib/spack/spack/test/cmd/deprecate.py index 6669be57fe05af..8306bea023e6a9 100644 --- a/lib/spack/spack/test/cmd/deprecate.py +++ b/lib/spack/spack/test/cmd/deprecate.py @@ -14,8 +14,6 @@ deprecate = SpackCommand("deprecate") find = SpackCommand("find") -pytestmark = pytest.mark.not_on_windows("does not run on windows") - def test_deprecate(mock_packages, mock_archive, mock_fetch, install_mockery): install("libelf@0.8.13") diff --git a/lib/spack/spack/test/cmd/dev_build.py b/lib/spack/spack/test/cmd/dev_build.py index 3e6631cf51ee03..16252b1af7e0a3 100644 --- a/lib/spack/spack/test/cmd/dev_build.py +++ b/lib/spack/spack/test/cmd/dev_build.py @@ -20,7 +20,7 @@ install = SpackCommand("install") env = SpackCommand("env") -pytestmark = pytest.mark.not_on_windows("does not run on windows") +pytestmark = [pytest.mark.disable_clean_stage_check] def test_dev_build_basics(tmpdir, install_mockery): @@ -41,7 +41,6 @@ def test_dev_build_basics(tmpdir, install_mockery): assert os.path.exists(str(tmpdir)) -@pytest.mark.disable_clean_stage_check def test_dev_build_before(tmpdir, install_mockery): spec = spack.spec.Spec(f"dev-build-test-install@0.0.0 dev_path={tmpdir}").concretized() @@ -58,7 +57,6 @@ def test_dev_build_before(tmpdir, install_mockery): assert not os.path.exists(spec.prefix) -@pytest.mark.disable_clean_stage_check def test_dev_build_until(tmpdir, install_mockery): spec = spack.spec.Spec(f"dev-build-test-install@0.0.0 dev_path={tmpdir}").concretized() @@ -76,7 +74,6 @@ def test_dev_build_until(tmpdir, install_mockery): assert not spack.store.STORE.db.query(spec, installed=True) -@pytest.mark.disable_clean_stage_check def test_dev_build_until_last_phase(tmpdir, install_mockery): # Test that we ignore the last_phase argument if it is already last spec = spack.spec.Spec(f"dev-build-test-install@0.0.0 dev_path={tmpdir}").concretized() @@ -96,8 +93,7 @@ def test_dev_build_until_last_phase(tmpdir, install_mockery): assert os.path.exists(str(tmpdir)) -@pytest.mark.disable_clean_stage_check -def test_dev_build_before_until(tmpdir, install_mockery, capsys): +def test_dev_build_before_until(tmpdir, install_mockery): spec = spack.spec.Spec(f"dev-build-test-install@0.0.0 dev_path={tmpdir}").concretized() with tmpdir.as_cwd(): @@ -126,22 +122,11 @@ def print_spack_cc(*args): print(os.environ.get("CC", "")) -# `module unload cray-libsci` in test environment causes failure -# It does not fail for actual installs -# build_environment.py imports module directly, so we monkeypatch it there -# rather than in module_cmd -def mock_module_noop(*args): - pass - - -@pytest.mark.disable_clean_stage_check def test_dev_build_drop_in(tmpdir, mock_packages, monkeypatch, install_mockery, working_env): monkeypatch.setattr(os, "execvp", print_spack_cc) - monkeypatch.setattr(spack.build_environment, "module", mock_module_noop) - with tmpdir.as_cwd(): output = dev_build("-b", "edit", "--drop-in", "sh", "dev-build-test-install@0.0.0") - assert "lib/spack/env" in output + assert os.path.join("lib", "spack", "env") in output def test_dev_build_fails_already_installed(tmpdir, install_mockery): diff --git a/lib/spack/spack/test/cmd/diff.py b/lib/spack/spack/test/cmd/diff.py index 179267425386fa..259f6b871afa7f 100644 --- a/lib/spack/spack/test/cmd/diff.py +++ b/lib/spack/spack/test/cmd/diff.py @@ -181,7 +181,6 @@ def test_diff_cmd(install_mockery, mock_fetch, mock_archive, mock_packages): assert ["hash", "mpileaks %s" % specB.dag_hash()] in c["b_not_a"] -@pytest.mark.not_on_windows("Not supported on Windows (yet)") def test_load_first(install_mockery, mock_fetch, mock_archive, mock_packages): """Test with and without the --first option""" install_cmd("mpileaks") diff --git a/lib/spack/spack/test/cmd/edit.py b/lib/spack/spack/test/cmd/edit.py new file mode 100644 index 00000000000000..93b4bd7949acd3 --- /dev/null +++ b/lib/spack/spack/test/cmd/edit.py @@ -0,0 +1,46 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +import spack.paths +import spack.repo +import spack.util.editor +from spack.build_systems import autotools, cmake +from spack.main import SpackCommand + +edit = SpackCommand("edit") + + +def test_edit_packages(monkeypatch, mock_packages: spack.repo.RepoPath): + """Test spack edit pkg-a pkg-b""" + path_a = mock_packages.filename_for_package_name("pkg-a") + path_b = mock_packages.filename_for_package_name("pkg-b") + called = False + + def editor(*args: str, **kwargs): + nonlocal called + called = True + assert args[0] == path_a + assert args[1] == path_b + + monkeypatch.setattr(spack.util.editor, "editor", editor) + edit("pkg-a", "pkg-b") + assert called + + +def test_edit_files(monkeypatch): + """Test spack edit --build-system autotools cmake""" + called = False + + def editor(*args: str, **kwargs): + nonlocal called + called = True + assert os.path.samefile(args[0], autotools.__file__) + assert os.path.samefile(args[1], cmake.__file__) + + monkeypatch.setattr(spack.util.editor, "editor", editor) + edit("--build-system", "autotools", "cmake") + assert called diff --git a/lib/spack/spack/test/cmd/env.py b/lib/spack/spack/test/cmd/env.py index bec5663e276e8d..e4c5b247805a05 100644 --- a/lib/spack/spack/test/cmd/env.py +++ b/lib/spack/spack/test/cmd/env.py @@ -15,6 +15,7 @@ import llnl.util.filesystem as fs import llnl.util.link_tree import llnl.util.tty as tty +from llnl.util.symlink import readlink import spack.cmd.env import spack.config @@ -27,7 +28,9 @@ import spack.package_base import spack.paths import spack.repo +import spack.store import spack.util.spack_json as sjson +import spack.util.spack_yaml from spack.cmd.env import _env_create from spack.main import SpackCommand, SpackCommandError from spack.spec import Spec @@ -39,7 +42,7 @@ # TODO-27021 # everything here uses the mock_env_path pytestmark = [ - pytest.mark.usefixtures("mutable_mock_env_path", "config", "mutable_mock_repo"), + pytest.mark.usefixtures("mutable_config", "mutable_mock_env_path", "mutable_mock_repo"), pytest.mark.maybeslow, pytest.mark.not_on_windows("Envs unsupported on Window"), ] @@ -60,6 +63,27 @@ sep = os.sep +def setup_combined_multiple_env(): + env("create", "test1") + test1 = ev.read("test1") + with test1: + add("zlib") + test1.concretize() + test1.write() + + env("create", "test2") + test2 = ev.read("test2") + with test2: + add("libelf") + test2.concretize() + test2.write() + + env("create", "--include-concrete", "test1", "--include-concrete", "test2", "combined_env") + combined = ev.read("combined_env") + + return test1, test2, combined + + @pytest.fixture() def environment_from_manifest(tmp_path): """Returns a new environment named 'test' from the content of a manifest file.""" @@ -188,6 +212,127 @@ def test_env_remove(capfd): assert "bar" not in out +def test_env_rename_managed(capfd): + # Need real environment + with pytest.raises(spack.main.SpackCommandError): + env("rename", "foo", "bar") + assert ( + "The specified name does not correspond to a managed spack environment" + in capfd.readouterr()[0] + ) + + env("create", "foo") + + out = env("list") + assert "foo" in out + + out = env("rename", "foo", "bar") + assert "Successfully renamed environment foo to bar" in out + + out = env("list") + assert "foo" not in out + assert "bar" in out + + bar = ev.read("bar") + with bar: + # Cannot rename active environment + with pytest.raises(spack.main.SpackCommandError): + env("rename", "bar", "baz") + assert "Cannot rename active environment" in capfd.readouterr()[0] + + env("create", "qux") + + # Cannot rename to an active environment (even with force flag) + with pytest.raises(spack.main.SpackCommandError): + env("rename", "-f", "qux", "bar") + assert "bar is an active environment" in capfd.readouterr()[0] + + # Can rename inactive environment when another's active + out = env("rename", "qux", "quux") + assert "Successfully renamed environment qux to quux" in out + + out = env("list") + assert "bar" in out + assert "baz" not in out + + env("create", "baz") + + # Cannot rename to existing environment without --force + with pytest.raises(spack.main.SpackCommandError): + env("rename", "bar", "baz") + errmsg = ( + "The new name corresponds to an existing environment;" + " specify the --force flag to overwrite it." + ) + assert errmsg in capfd.readouterr()[0] + + env("rename", "-f", "bar", "baz") + out = env("list") + assert "bar" not in out + assert "baz" in out + + +def test_env_rename_anonymous(capfd, tmpdir): + # Need real environment + with pytest.raises(spack.main.SpackCommandError): + env("rename", "-d", "./non-existing", "./also-non-existing") + assert ( + "The specified path does not correspond to a valid spack environment" + in capfd.readouterr()[0] + ) + + anon_foo = str(tmpdir / "foo") + env("create", "-d", anon_foo) + + anon_bar = str(tmpdir / "bar") + out = env("rename", "-d", anon_foo, anon_bar) + assert f"Successfully renamed environment {anon_foo} to {anon_bar}" in out + assert not ev.is_env_dir(anon_foo) + assert ev.is_env_dir(anon_bar) + + # Cannot rename active environment + anon_baz = str(tmpdir / "baz") + env("activate", "--sh", "-d", anon_bar) + with pytest.raises(spack.main.SpackCommandError): + env("rename", "-d", anon_bar, anon_baz) + assert "Cannot rename active environment" in capfd.readouterr()[0] + env("deactivate", "--sh") + + assert ev.is_env_dir(anon_bar) + assert not ev.is_env_dir(anon_baz) + + # Cannot rename to existing environment without --force + env("create", "-d", anon_baz) + with pytest.raises(spack.main.SpackCommandError): + env("rename", "-d", anon_bar, anon_baz) + errmsg = ( + "The new path corresponds to an existing environment;" + " specify the --force flag to overwrite it." + ) + assert errmsg in capfd.readouterr()[0] + assert ev.is_env_dir(anon_bar) + assert ev.is_env_dir(anon_baz) + + env("rename", "-f", "-d", anon_bar, anon_baz) + assert not ev.is_env_dir(anon_bar) + assert ev.is_env_dir(anon_baz) + + # Cannot rename to existing (non-environment) path without --force + qux = tmpdir / "qux" + qux.mkdir() + anon_qux = str(qux) + assert not ev.is_env_dir(anon_qux) + + with pytest.raises(spack.main.SpackCommandError): + env("rename", "-d", anon_baz, anon_qux) + errmsg = "The new path already exists; specify the --force flag to overwrite it." + assert errmsg in capfd.readouterr()[0] + + env("rename", "-f", "-d", anon_baz, anon_qux) + assert not ev.is_env_dir(anon_baz) + assert ev.is_env_dir(anon_qux) + + def test_concretize(): e = ev.create("test") e.add("mpileaks") @@ -248,6 +393,29 @@ def test_env_install_single_spec(install_mockery, mock_fetch): assert e.specs_by_hash[e.concretized_order[0]].name == "cmake-client" +@pytest.mark.parametrize("unify", [True, False, "when_possible"]) +def test_env_install_include_concrete_env(unify, install_mockery, mock_fetch): + test1, test2, combined = setup_combined_multiple_env() + + combined.concretize() + combined.write() + + combined.unify = unify + + with combined: + install() + + test1_roots = test1.concretized_order + test2_roots = test2.concretized_order + combined_included_roots = combined.included_concretized_order + + for spec in combined.all_specs(): + assert spec.installed + + assert test1_roots == combined_included_roots[test1.path] + assert test2_roots == combined_included_roots[test2.path] + + def test_env_roots_marked_explicit(install_mockery, mock_fetch): install = SpackCommand("install") install("dependent-install") @@ -335,7 +503,7 @@ def test_env_install_two_specs_same_dep(install_mockery, mock_fetch, tmpdir, cap """\ spack: specs: - - a + - pkg-a - depb """ ) @@ -354,8 +522,8 @@ def test_env_install_two_specs_same_dep(install_mockery, mock_fetch, tmpdir, cap depb = spack.store.STORE.db.query_one("depb", installed=True) assert depb, "Expected depb to be installed" - a = spack.store.STORE.db.query_one("a", installed=True) - assert a, "Expected a to be installed" + a = spack.store.STORE.db.query_one("pkg-a", installed=True) + assert a, "Expected pkg-a to be installed" def test_remove_after_concretize(): @@ -436,6 +604,41 @@ def test_remove_command(): assert "mpileaks@" not in find("--show-concretized") +def test_bad_remove_included_env(): + env("create", "test") + test = ev.read("test") + + with test: + add("mpileaks") + + test.concretize() + test.write() + + env("create", "--include-concrete", "test", "combined_env") + + with pytest.raises(SpackCommandError): + env("remove", "test") + + +def test_force_remove_included_env(): + env("create", "test") + test = ev.read("test") + + with test: + add("mpileaks") + + test.concretize() + test.write() + + env("create", "--include-concrete", "test", "combined_env") + + rm_output = env("remove", "-f", "-y", "test") + list_output = env("list") + + assert '"test" is being used by environment "combined_env"' in rm_output + assert "test" not in list_output + + def test_environment_status(capsys, tmpdir): with tmpdir.as_cwd(): with capsys.disabled(): @@ -611,7 +814,6 @@ def test_init_from_yaml(environment_from_manifest): assert not e2.specs_by_hash -@pytest.mark.usefixtures("config") def test_env_view_external_prefix(tmp_path, mutable_database, mock_packages): fake_prefix = tmp_path / "a-prefix" fake_bin = fake_prefix / "bin" @@ -624,7 +826,7 @@ def test_env_view_external_prefix(tmp_path, mutable_database, mock_packages): """\ spack: specs: - - a + - pkg-a view: true """ ) @@ -632,9 +834,9 @@ def test_env_view_external_prefix(tmp_path, mutable_database, mock_packages): external_config = io.StringIO( """\ packages: - a: + pkg-a: externals: - - spec: a@2.0 + - spec: pkg-a@2.0 prefix: {a_prefix} buildable: false """.format( @@ -737,8 +939,7 @@ def test_with_config_bad_include_activate(environment_from_manifest, tmpdir): """ ) - e = ev.Environment(env_root) - with e: + with ev.Environment(env_root) as e: e.concretize() # we've created an environment with some included config files (which do @@ -748,7 +949,7 @@ def test_with_config_bad_include_activate(environment_from_manifest, tmpdir): os.remove(abs_include_path) os.remove(include1) with pytest.raises(spack.config.ConfigFileError) as exc: - ev.activate(e) + ev.activate(ev.Environment(env_root)) err = exc.value.message assert "missing include" in err @@ -856,6 +1057,7 @@ def test_env_with_included_config_file(mutable_mock_env_path, packages_file): assert any(x.satisfies("mpileaks@2.2") for x in e._get_environment_specs()) +@pytest.mark.only_clingo("original concretizer does not support requirements") def test_config_change_existing(mutable_mock_env_path, tmp_path, mock_packages, mutable_config): """Test ``config change`` with config in the ``spack.yaml`` as well as an included file scope. @@ -931,6 +1133,7 @@ def test_config_change_existing(mutable_mock_env_path, tmp_path, mock_packages, spack.spec.Spec("bowtie@1.2.2").concretized() +@pytest.mark.only_clingo("original concretizer does not support requirements") def test_config_change_new(mutable_mock_env_path, tmp_path, mock_packages, mutable_config): spack_yaml = tmp_path / ev.manifest_name spack_yaml.write_text( @@ -940,8 +1143,7 @@ def test_config_change_new(mutable_mock_env_path, tmp_path, mock_packages, mutab """ ) - e = ev.Environment(tmp_path) - with e: + with ev.Environment(tmp_path): config("change", "packages:mpich:require:~debug") with pytest.raises(spack.solver.asp.UnsatisfiableSpecError): spack.spec.Spec("mpich+debug").concretized() @@ -958,7 +1160,7 @@ def test_config_change_new(mutable_mock_env_path, tmp_path, mock_packages, mutab require: "@3.0.3" """ ) - with e: + with ev.Environment(tmp_path): assert spack.spec.Spec("mpich").concretized().satisfies("@3.0.3") with pytest.raises(spack.config.ConfigError, match="not a list"): config("change", "packages:mpich:require:~debug") @@ -1358,7 +1560,6 @@ def test_uninstall_removes_from_env(mock_stage, mock_fetch, install_mockery): assert not test.user_specs -@pytest.mark.usefixtures("config") def test_indirect_build_dep(tmp_path): """Simple case of X->Y->Z where Y is a build/link dep and Z is a build-only dep. Make sure this concrete DAG is preserved when writing the @@ -1386,7 +1587,6 @@ def test_indirect_build_dep(tmp_path): assert x_env_spec == x_concretized -@pytest.mark.usefixtures("config") def test_store_different_build_deps(tmp_path): r"""Ensure that an environment can store two instances of a build-only dependency:: @@ -1515,6 +1715,275 @@ def test_env_without_view_install(tmpdir, mock_stage, mock_fetch, install_mocker check_mpileaks_and_deps_in_view(view_dir) +@pytest.mark.parametrize("env_name", [True, False]) +def test_env_include_concrete_env_yaml(env_name): + env("create", "test") + test = ev.read("test") + + with test: + add("mpileaks") + test.concretize() + test.write() + + environ = "test" if env_name else test.path + + env("create", "--include-concrete", environ, "combined_env") + + combined = ev.read("combined_env") + combined_yaml = combined.manifest["spack"] + + assert "include_concrete" in combined_yaml + assert test.path in combined_yaml["include_concrete"] + + +def test_env_bad_include_concrete_env(): + with pytest.raises(ev.SpackEnvironmentError): + env("create", "--include-concrete", "nonexistant_env", "combined_env") + + +def test_env_not_concrete_include_concrete_env(): + env("create", "test") + test = ev.read("test") + + with test: + add("mpileaks") + + with pytest.raises(ev.SpackEnvironmentError): + env("create", "--include-concrete", "test", "combined_env") + + +def test_env_multiple_include_concrete_envs(): + test1, test2, combined = setup_combined_multiple_env() + + combined_yaml = combined.manifest["spack"] + + assert test1.path in combined_yaml["include_concrete"][0] + assert test2.path in combined_yaml["include_concrete"][1] + + # No local specs in the combined env + assert not combined_yaml["specs"] + + +def test_env_include_concrete_envs_lockfile(): + test1, test2, combined = setup_combined_multiple_env() + + combined_yaml = combined.manifest["spack"] + + assert "include_concrete" in combined_yaml + assert test1.path in combined_yaml["include_concrete"] + + with open(combined.lock_path) as f: + lockfile_as_dict = combined._read_lockfile(f) + + assert set( + entry["hash"] for entry in lockfile_as_dict["include_concrete"][test1.path]["roots"] + ) == set(test1.specs_by_hash) + assert set( + entry["hash"] for entry in lockfile_as_dict["include_concrete"][test2.path]["roots"] + ) == set(test2.specs_by_hash) + + +def test_env_include_concrete_add_env(): + test1, test2, combined = setup_combined_multiple_env() + + # crete new env & crecretize + env("create", "new") + new_env = ev.read("new") + with new_env: + add("mpileaks") + + new_env.concretize() + new_env.write() + + # add new env to combined + combined.included_concrete_envs.append(new_env.path) + + # assert thing haven't changed yet + with open(combined.lock_path) as f: + lockfile_as_dict = combined._read_lockfile(f) + + assert new_env.path not in lockfile_as_dict["include_concrete"].keys() + + # concretize combined env with new env + combined.concretize() + combined.write() + + # assert changes + with open(combined.lock_path) as f: + lockfile_as_dict = combined._read_lockfile(f) + + assert new_env.path in lockfile_as_dict["include_concrete"].keys() + + +def test_env_include_concrete_remove_env(): + test1, test2, combined = setup_combined_multiple_env() + + # remove test2 from combined + combined.included_concrete_envs = [test1.path] + + # assert test2 is still in combined's lockfile + with open(combined.lock_path) as f: + lockfile_as_dict = combined._read_lockfile(f) + + assert test2.path in lockfile_as_dict["include_concrete"].keys() + + # reconcretize combined + combined.concretize() + combined.write() + + # assert test2 is not in combined's lockfile + with open(combined.lock_path) as f: + lockfile_as_dict = combined._read_lockfile(f) + + assert test2.path not in lockfile_as_dict["include_concrete"].keys() + + +@pytest.mark.parametrize("unify", [True, False, "when_possible"]) +def test_env_include_concrete_env_reconcretized(unify): + """Double check to make sure that concrete_specs for the local specs is empty + after recocnretizing. + """ + _, _, combined = setup_combined_multiple_env() + + combined.unify = unify + + with open(combined.lock_path) as f: + lockfile_as_dict = combined._read_lockfile(f) + + assert not lockfile_as_dict["roots"] + assert not lockfile_as_dict["concrete_specs"] + + combined.concretize() + combined.write() + + with open(combined.lock_path) as f: + lockfile_as_dict = combined._read_lockfile(f) + + assert not lockfile_as_dict["roots"] + assert not lockfile_as_dict["concrete_specs"] + + +def test_concretize_include_concrete_env(): + test1, _, combined = setup_combined_multiple_env() + + with test1: + add("mpileaks") + test1.concretize() + test1.write() + + assert Spec("mpileaks") in test1.concretized_user_specs + assert Spec("mpileaks") not in combined.included_concretized_user_specs[test1.path] + + combined.concretize() + combined.write() + + assert Spec("mpileaks") in combined.included_concretized_user_specs[test1.path] + + +def test_concretize_nested_include_concrete_envs(): + env("create", "test1") + test1 = ev.read("test1") + with test1: + add("zlib") + test1.concretize() + test1.write() + + env("create", "--include-concrete", "test1", "test2") + test2 = ev.read("test2") + with test2: + add("libelf") + test2.concretize() + test2.write() + + env("create", "--include-concrete", "test2", "test3") + test3 = ev.read("test3") + + with open(test3.lock_path) as f: + lockfile_as_dict = test3._read_lockfile(f) + + assert test2.path in lockfile_as_dict["include_concrete"] + assert test1.path in lockfile_as_dict["include_concrete"][test2.path]["include_concrete"] + + assert Spec("zlib") in test3.included_concretized_user_specs[test1.path] + + +def test_concretize_nested_included_concrete(): + """Confirm that nested included environments use specs concretized at + environment creation time and change with reconcretization.""" + env("create", "test1") + test1 = ev.read("test1") + with test1: + add("zlib") + test1.concretize() + test1.write() + + # test2 should include test1 with zlib + env("create", "--include-concrete", "test1", "test2") + test2 = ev.read("test2") + with test2: + add("libelf") + test2.concretize() + test2.write() + + assert Spec("zlib") in test2.included_concretized_user_specs[test1.path] + + # Modify/re-concretize test1 to replace zlib with mpileaks + with test1: + remove("zlib") + add("mpileaks") + test1.concretize() + test1.write() + + # test3 should include the latest concretization of test1 + env("create", "--include-concrete", "test1", "test3") + test3 = ev.read("test3") + with test3: + add("callpath") + test3.concretize() + test3.write() + + included_specs = test3.included_concretized_user_specs[test1.path] + assert len(included_specs) == 1 + assert Spec("mpileaks") in included_specs + + # The last concretization of test4's included environments should have test2 + # with the original concretized test1 spec and test3 with the re-concretized + # test1 spec. + env("create", "--include-concrete", "test2", "--include-concrete", "test3", "test4") + test4 = ev.read("test4") + + def included_included_spec(path1, path2): + included_path1 = test4.included_concrete_spec_data[path1] + included_path2 = included_path1["include_concrete"][path2] + return included_path2["roots"][0]["spec"] + + included_test2_test1 = included_included_spec(test2.path, test1.path) + assert "zlib" in included_test2_test1 + + included_test3_test1 = included_included_spec(test3.path, test1.path) + assert "mpileaks" in included_test3_test1 + + # test4's concretized specs should reflect the original concretization. + concrete_specs = [s for s, _ in test4.concretized_specs()] + expected = [Spec(s) for s in ["libelf", "zlib", "mpileaks", "callpath"]] + assert all(s in concrete_specs for s in expected) + + # Re-concretize test2 to reflect the new concretization of included test1 + # to remove zlib and write it out so it can be picked up by test4. + # Re-concretize test4 to reflect the re-concretization of included test2 + # and ensure that its included specs are up-to-date + test2.concretize() + test2.write() + test4.concretize() + + concrete_specs = [s for s, _ in test4.concretized_specs()] + assert Spec("zlib") not in concrete_specs + + # Expecting mpileaks to appear only once + expected = [Spec(s) for s in ["libelf", "mpileaks", "callpath"]] + assert len(concrete_specs) == 3 and all(s in concrete_specs for s in expected) + + def test_env_config_view_default( environment_from_manifest, mock_stage, mock_fetch, install_mockery ): @@ -1858,7 +2327,7 @@ def test_stack_yaml_force_remove_from_matrix(tmpdir): assert mpileaks_spec not in after_conc -def test_stack_concretize_extraneous_deps(tmpdir, config, mock_packages): +def test_stack_concretize_extraneous_deps(tmpdir, mock_packages): # FIXME: The new concretizer doesn't handle yet soft # FIXME: constraints for stacks # FIXME: This now works for statically-determinable invalid deps @@ -1897,7 +2366,7 @@ def test_stack_concretize_extraneous_deps(tmpdir, config, mock_packages): assert concrete.satisfies("^mpi") -def test_stack_concretize_extraneous_variants(tmpdir, config, mock_packages): +def test_stack_concretize_extraneous_variants(tmpdir, mock_packages): filename = str(tmpdir.join("spack.yaml")) with open(filename, "w") as f: f.write( @@ -1929,7 +2398,7 @@ def test_stack_concretize_extraneous_variants(tmpdir, config, mock_packages): assert concrete.variants["shared"].value == user.variants["shared"].value -def test_stack_concretize_extraneous_variants_with_dash(tmpdir, config, mock_packages): +def test_stack_concretize_extraneous_variants_with_dash(tmpdir, mock_packages): filename = str(tmpdir.join("spack.yaml")) with open(filename, "w") as f: f.write( @@ -3038,6 +3507,41 @@ def test_modules_exist_after_env_install( assert spec.prefix in contents +@pytest.mark.disable_clean_stage_check +def test_install_develop_keep_stage( + environment_from_manifest, install_mockery, mock_fetch, monkeypatch, tmpdir +): + """Develop a dependency of a package and make sure that the associated + stage for the package is retained after a successful install. + """ + environment_from_manifest( + """ +spack: + specs: + - mpileaks +""" + ) + + monkeypatch.setattr(spack.stage.DevelopStage, "destroy", _always_fail) + + with ev.read("test") as e: + libelf_dev_path = tmpdir.ensure("libelf-test-dev-path", dir=True) + develop(f"--path={libelf_dev_path}", "libelf@0.8.13") + concretize() + (libelf_spec,) = e.all_matching_specs("libelf") + (mpileaks_spec,) = e.all_matching_specs("mpileaks") + assert not os.path.exists(libelf_spec.package.stage.path) + assert not os.path.exists(mpileaks_spec.package.stage.path) + install() + assert os.path.exists(libelf_spec.package.stage.path) + assert not os.path.exists(mpileaks_spec.package.stage.path) + + +# Helper method for test_install_develop_keep_stage +def _always_fail(cls, *args, **kwargs): + raise Exception("Restage or destruction of dev stage detected during install") + + @pytest.mark.regression("24148") def test_virtual_spec_concretize_together(tmpdir): # An environment should permit to concretize "mpi" @@ -3131,10 +3635,10 @@ def test_create_and_activate_managed(tmp_path): env("deactivate") -def test_create_and_activate_unmanaged(tmp_path): +def test_create_and_activate_anonymous(tmp_path): with fs.working_dir(str(tmp_path)): env_dir = os.path.join(str(tmp_path), "foo") - shell = env("activate", "--without-view", "--create", "--sh", "-d", env_dir) + shell = env("activate", "--without-view", "--create", "--sh", env_dir) active_env_var = next(line for line in shell.splitlines() if ev.spack_env_var in line) assert str(env_dir) in active_env_var assert ev.is_env_dir(env_dir) @@ -3245,7 +3749,7 @@ def test_environment_query_spec_by_hash(mock_stage, mock_fetch, install_mockery) @pytest.mark.parametrize("lockfile", ["v1", "v2", "v3"]) -def test_read_old_lock_and_write_new(config, tmpdir, lockfile): +def test_read_old_lock_and_write_new(tmpdir, lockfile): # v1 lockfiles stored by a coarse DAG hash that did not include build deps. # They could not represent multiple build deps with different build hashes. # @@ -3311,7 +3815,7 @@ def test_read_old_lock_and_write_new(config, tmpdir, lockfile): assert old_hashes == hashes -def test_read_v1_lock_creates_backup(config, tmp_path): +def test_read_v1_lock_creates_backup(tmp_path): """When reading a version-1 lockfile, make sure that a backup of that file is created. """ @@ -3694,7 +4198,7 @@ def test_env_include_packages_url( assert "openmpi" in cfg["all"]["providers"]["mpi"] -def test_relative_view_path_on_command_line_is_made_absolute(tmp_path, config): +def test_relative_view_path_on_command_line_is_made_absolute(tmp_path): with fs.working_dir(str(tmp_path)): env("create", "--with-view", "view", "--dir", "env") environment = ev.Environment(os.path.join(".", "env")) @@ -3910,8 +4414,8 @@ def test_env_view_resolves_identical_file_conflicts(tmp_path, install_mockery, m # view-file/bin/ # x # expect this x to be linked - assert os.readlink(tmp_path / "view" / "bin" / "x") == bottom.bin.x - assert os.readlink(tmp_path / "view" / "bin" / "y") == top.bin.y + assert readlink(tmp_path / "view" / "bin" / "x") == bottom.bin.x + assert readlink(tmp_path / "view" / "bin" / "y") == top.bin.y def test_env_view_ignores_different_file_conflicts(tmp_path, install_mockery, mock_fetch): @@ -3922,4 +4426,4 @@ def test_env_view_ignores_different_file_conflicts(tmp_path, install_mockery, mo install() prefix_dependent = e.matching_spec("view-ignore-conflict").prefix # The dependent's file is linked into the view - assert os.readlink(tmp_path / "view" / "bin" / "x") == prefix_dependent.bin.x + assert readlink(tmp_path / "view" / "bin" / "x") == prefix_dependent.bin.x diff --git a/lib/spack/spack/test/cmd/extensions.py b/lib/spack/spack/test/cmd/extensions.py index 1f6ed95b564469..b97bfa8b06c8b1 100644 --- a/lib/spack/spack/test/cmd/extensions.py +++ b/lib/spack/spack/test/cmd/extensions.py @@ -24,7 +24,7 @@ def python_database(mock_packages, mutable_database): @pytest.mark.not_on_windows("All Fetchers Failed") @pytest.mark.db -def test_extensions(mock_packages, python_database, config, capsys): +def test_extensions(mock_packages, python_database, capsys): ext2 = Spec("py-extension2").concretized() def check_output(ni): @@ -33,21 +33,23 @@ def check_output(ni): packages = extensions("-s", "packages", "python") installed = extensions("-s", "installed", "python") assert "==> python@2.7.11" in output - assert "==> 2 extensions" in output + assert "==> 3 extensions" in output assert "py-extension1" in output assert "py-extension2" in output + assert "python-venv" in output - assert "==> 2 extensions" in packages + assert "==> 3 extensions" in packages assert "py-extension1" in packages assert "py-extension2" in packages + assert "python-venv" in packages assert "installed" not in packages - assert ("%s installed" % (ni if ni else "None")) in output - assert ("%s installed" % (ni if ni else "None")) in installed + assert f"{ni if ni else 'None'} installed" in output + assert f"{ni if ni else 'None'} installed" in installed - check_output(2) + check_output(3) ext2.package.do_uninstall(force=True) - check_output(1) + check_output(2) def test_extensions_no_arguments(mock_packages): diff --git a/lib/spack/spack/test/cmd/external.py b/lib/spack/spack/test/cmd/external.py index e5bb29c6ea8d73..2de6f18b506884 100644 --- a/lib/spack/spack/test/cmd/external.py +++ b/lib/spack/spack/test/cmd/external.py @@ -11,6 +11,7 @@ from llnl.util.filesystem import getuid, touch import spack +import spack.cmd.external import spack.detection import spack.detection.path from spack.main import SpackCommand @@ -311,3 +312,29 @@ def test_failures_in_scanning_do_not_result_in_an_error( assert "cmake" in output assert "3.23.3" in output assert "3.19.1" not in output + + +def test_detect_virtuals(mock_executable, mutable_config, monkeypatch): + """Test whether external find --not-buildable sets virtuals as non-buildable (unless user + config sets them to buildable)""" + mpich = mock_executable("mpichversion", output="echo MPICH Version: 4.0.2") + prefix = os.path.dirname(mpich) + external("find", "--path", prefix, "--not-buildable", "mpich") + + # Check that mpich was correctly detected + mpich = mutable_config.get("packages:mpich") + assert mpich["buildable"] is False + assert Spec(mpich["externals"][0]["spec"]).satisfies("mpich@4.0.2") + + # Check that the virtual package mpi was marked as non-buildable + assert mutable_config.get("packages:mpi:buildable") is False + + # Delete the mpich entry, and set mpi explicitly to buildable + mutable_config.set("packages:mpich", {}) + mutable_config.set("packages:mpi:buildable", True) + + # Run the detection again + external("find", "--path", prefix, "--not-buildable", "mpich") + + # Check that the mpi:buildable entry was not overwritten + assert mutable_config.get("packages:mpi:buildable") is True diff --git a/lib/spack/spack/test/cmd/fetch.py b/lib/spack/spack/test/cmd/fetch.py index cf05f4299d925e..d2ba0f82803c85 100644 --- a/lib/spack/spack/test/cmd/fetch.py +++ b/lib/spack/spack/test/cmd/fetch.py @@ -9,7 +9,9 @@ from spack.main import SpackCommand, SpackCommandError # everything here uses the mock_env_path -pytestmark = pytest.mark.usefixtures("mutable_mock_env_path", "config", "mutable_mock_repo") +pytestmark = pytest.mark.usefixtures( + "mutable_mock_env_path", "mutable_config", "mutable_mock_repo" +) @pytest.mark.disable_clean_stage_check diff --git a/lib/spack/spack/test/cmd/find.py b/lib/spack/spack/test/cmd/find.py index 5d551e6df929eb..46f05ab6e9ca65 100644 --- a/lib/spack/spack/test/cmd/find.py +++ b/lib/spack/spack/test/cmd/find.py @@ -64,6 +64,7 @@ def test_query_arguments(): implicit=False, start_date="2018-02-23", end_date=None, + install_tree="all", ) q_args = query_arguments(args) @@ -75,6 +76,7 @@ def test_query_arguments(): assert q_args["explicit"] is any assert "start_date" in q_args assert "end_date" not in q_args + assert q_args["install_tree"] == "all" # Check that explicit works correctly args.explicit = True @@ -335,7 +337,7 @@ def test_find_command_basic_usage(database): @pytest.mark.not_on_windows("envirnment is not yet supported on windows") @pytest.mark.regression("9875") def test_find_prefix_in_env( - mutable_mock_env_path, install_mockery, mock_fetch, mock_packages, mock_archive, config + mutable_mock_env_path, install_mockery, mock_fetch, mock_packages, mock_archive ): """Test `find` formats requiring concrete specs work in environments.""" env("create", "test") @@ -347,11 +349,90 @@ def test_find_prefix_in_env( # Would throw error on regression +def test_find_specs_include_concrete_env(mutable_mock_env_path, mutable_mock_repo, tmpdir): + path = tmpdir.join("spack.yaml") + + with tmpdir.as_cwd(): + with open(str(path), "w") as f: + f.write( + """\ +spack: + specs: + - mpileaks +""" + ) + env("create", "test1", "spack.yaml") + + test1 = ev.read("test1") + test1.concretize() + test1.write() + + with tmpdir.as_cwd(): + with open(str(path), "w") as f: + f.write( + """\ +spack: + specs: + - libelf +""" + ) + env("create", "test2", "spack.yaml") + + test2 = ev.read("test2") + test2.concretize() + test2.write() + + env("create", "--include-concrete", "test1", "--include-concrete", "test2", "combined_env") + + with ev.read("combined_env"): + output = find() + + assert "No root specs" in output + assert "Included specs" in output + assert "mpileaks" in output + assert "libelf" in output + + +def test_find_specs_nested_include_concrete_env(mutable_mock_env_path, mutable_mock_repo, tmpdir): + path = tmpdir.join("spack.yaml") + + with tmpdir.as_cwd(): + with open(str(path), "w") as f: + f.write( + """\ +spack: + specs: + - mpileaks +""" + ) + env("create", "test1", "spack.yaml") + + test1 = ev.read("test1") + test1.concretize() + test1.write() + + env("create", "--include-concrete", "test1", "test2") + test2 = ev.read("test2") + test2.add("libelf") + test2.concretize() + test2.write() + + env("create", "--include-concrete", "test2", "test3") + + with ev.read("test3"): + output = find() + + assert "No root specs" in output + assert "Included specs" in output + assert "mpileaks" in output + assert "libelf" in output + + def test_find_loaded(database, working_env): output = find("--loaded", "--group") assert output == "" - os.environ[uenv.spack_loaded_hashes_var] = ":".join( + os.environ[uenv.spack_loaded_hashes_var] = os.pathsep.join( [x.dag_hash() for x in spack.store.STORE.db.query()] ) output = find("--loaded") diff --git a/lib/spack/spack/test/cmd/gc.py b/lib/spack/spack/test/cmd/gc.py index 05f7a111adf0a5..e646f8f8d5a43f 100644 --- a/lib/spack/spack/test/cmd/gc.py +++ b/lib/spack/spack/test/cmd/gc.py @@ -20,13 +20,13 @@ @pytest.mark.db -def test_gc_without_build_dependency(config, mutable_database): +def test_gc_without_build_dependency(mutable_database): assert "There are no unused specs." in gc("-yb") assert "There are no unused specs." in gc("-y") @pytest.mark.db -def test_gc_with_build_dependency(config, mutable_database): +def test_gc_with_build_dependency(mutable_database): s = spack.spec.Spec("simple-inheritance") s.concretize() s.package.do_install(fake=True, explicit=True) @@ -37,7 +37,7 @@ def test_gc_with_build_dependency(config, mutable_database): @pytest.mark.db -def test_gc_with_environment(config, mutable_database, mutable_mock_env_path): +def test_gc_with_environment(mutable_database, mutable_mock_env_path): s = spack.spec.Spec("simple-inheritance") s.concretize() s.package.do_install(fake=True, explicit=True) @@ -53,7 +53,7 @@ def test_gc_with_environment(config, mutable_database, mutable_mock_env_path): @pytest.mark.db -def test_gc_with_build_dependency_in_environment(config, mutable_database, mutable_mock_env_path): +def test_gc_with_build_dependency_in_environment(mutable_database, mutable_mock_env_path): s = spack.spec.Spec("simple-inheritance") s.concretize() s.package.do_install(fake=True, explicit=True) @@ -78,7 +78,7 @@ def test_gc_with_build_dependency_in_environment(config, mutable_database, mutab @pytest.mark.db -def test_gc_except_any_environments(config, mutable_database, mutable_mock_env_path): +def test_gc_except_any_environments(mutable_database, mutable_mock_env_path): """Tests whether the garbage collector can remove all specs except those still needed in some environment (needed in the sense of roots + link/run deps).""" assert mutable_database.query_local("zmpi") @@ -105,7 +105,7 @@ def test_gc_except_any_environments(config, mutable_database, mutable_mock_env_p @pytest.mark.db -def test_gc_except_specific_environments(config, mutable_database, mutable_mock_env_path): +def test_gc_except_specific_environments(mutable_database, mutable_mock_env_path): s = spack.spec.Spec("simple-inheritance") s.concretize() s.package.do_install(fake=True, explicit=True) @@ -125,14 +125,14 @@ def test_gc_except_specific_environments(config, mutable_database, mutable_mock_ @pytest.mark.db -def test_gc_except_nonexisting_dir_env(config, mutable_database, mutable_mock_env_path, tmpdir): +def test_gc_except_nonexisting_dir_env(mutable_database, mutable_mock_env_path, tmpdir): output = gc("-ye", tmpdir.strpath, fail_on_error=False) assert "No such environment" in output gc.returncode == 1 @pytest.mark.db -def test_gc_except_specific_dir_env(config, mutable_database, mutable_mock_env_path, tmpdir): +def test_gc_except_specific_dir_env(mutable_database, mutable_mock_env_path, tmpdir): s = spack.spec.Spec("simple-inheritance") s.concretize() s.package.do_install(fake=True, explicit=True) diff --git a/lib/spack/spack/test/cmd/info.py b/lib/spack/spack/test/cmd/info.py index e3d7b383a5e908..a0ea57b03e4cc1 100644 --- a/lib/spack/spack/test/cmd/info.py +++ b/lib/spack/spack/test/cmd/info.py @@ -57,9 +57,9 @@ def test_info_noversion(mock_packages, print_buffer): @pytest.mark.parametrize( - "pkg_query,expected", [("zlib", "False"), ("gcc", "True (version, variants)")] + "pkg_query,expected", [("zlib", "False"), ("find-externals1", "True (version)")] ) -def test_is_externally_detectable(pkg_query, expected, parser, print_buffer): +def test_is_externally_detectable(mock_packages, pkg_query, expected, parser, print_buffer): args = parser.parse_args(["--detectable", pkg_query]) spack.cmd.info.info(parser, args) diff --git a/lib/spack/spack/test/cmd/install.py b/lib/spack/spack/test/cmd/install.py index 17a35b89735029..5f8119f01763d2 100644 --- a/lib/spack/spack/test/cmd/install.py +++ b/lib/spack/spack/test/cmd/install.py @@ -49,7 +49,7 @@ def noop(*args, **kwargs): def test_install_package_and_dependency( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery + tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery ): log = "test" with tmpdir.as_cwd(): @@ -89,11 +89,11 @@ def check(pkg): assert pkg.run_tests monkeypatch.setattr(spack.package_base.PackageBase, "unit_test_check", check) - install("--test=all", "a") + install("--test=all", "pkg-a") def test_install_package_already_installed( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery + tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery ): with tmpdir.as_cwd(): install("libdwarf") @@ -149,7 +149,7 @@ def test_package_output(tmpdir, capsys, install_mockery, mock_fetch): @pytest.mark.disable_clean_stage_check def test_install_output_on_build_error( - mock_packages, mock_archive, mock_fetch, config, install_mockery, capfd + mock_packages, mock_archive, mock_fetch, install_mockery, capfd ): """ This test used to assume receiving full output, but since we've updated @@ -163,9 +163,7 @@ def test_install_output_on_build_error( @pytest.mark.disable_clean_stage_check -def test_install_output_on_python_error( - mock_packages, mock_archive, mock_fetch, config, install_mockery -): +def test_install_output_on_python_error(mock_packages, mock_archive, mock_fetch, install_mockery): out = install("failing-build", fail_on_error=False) assert isinstance(install.error, spack.build_environment.ChildError) assert install.error.name == "InstallError" @@ -173,7 +171,7 @@ def test_install_output_on_python_error( @pytest.mark.disable_clean_stage_check -def test_install_with_source(mock_packages, mock_archive, mock_fetch, config, install_mockery): +def test_install_with_source(mock_packages, mock_archive, mock_fetch, install_mockery): """Verify that source has been copied into place.""" install("--source", "--keep-stage", "trivial-install-test-package") spec = Spec("trivial-install-test-package").concretized() @@ -183,7 +181,7 @@ def test_install_with_source(mock_packages, mock_archive, mock_fetch, config, in ) -def test_install_env_variables(mock_packages, mock_archive, mock_fetch, config, install_mockery): +def test_install_env_variables(mock_packages, mock_archive, mock_fetch, install_mockery): spec = Spec("libdwarf") spec.concretize() install("libdwarf") @@ -191,9 +189,7 @@ def test_install_env_variables(mock_packages, mock_archive, mock_fetch, config, @pytest.mark.disable_clean_stage_check -def test_show_log_on_error( - mock_packages, mock_archive, mock_fetch, config, install_mockery, capfd -): +def test_show_log_on_error(mock_packages, mock_archive, mock_fetch, install_mockery, capfd): """ Make sure --show-log-on-error works. """ @@ -206,7 +202,7 @@ def test_show_log_on_error( assert "See build log for details:" in out -def test_install_overwrite(mock_packages, mock_archive, mock_fetch, config, install_mockery): +def test_install_overwrite(mock_packages, mock_archive, mock_fetch, install_mockery): # Try to install a spec and then to reinstall it. spec = Spec("libdwarf") spec.concretize() @@ -240,9 +236,7 @@ def test_install_overwrite(mock_packages, mock_archive, mock_fetch, config, inst assert fs.hash_directory(spec.prefix, ignore=ignores) != bad_md5 -def test_install_overwrite_not_installed( - mock_packages, mock_archive, mock_fetch, config, install_mockery -): +def test_install_overwrite_not_installed(mock_packages, mock_archive, mock_fetch, install_mockery): # Try to install a spec and then to reinstall it. spec = Spec("libdwarf") spec.concretize() @@ -277,9 +271,7 @@ def test_install_commit(mock_git_version_info, install_mockery, mock_packages, m assert content == "[0]" # contents are weird for another test -def test_install_overwrite_multiple( - mock_packages, mock_archive, mock_fetch, config, install_mockery -): +def test_install_overwrite_multiple(mock_packages, mock_archive, mock_fetch, install_mockery): # Try to install a spec and then to reinstall it. libdwarf = Spec("libdwarf") libdwarf.concretize() @@ -337,18 +329,14 @@ def test_install_overwrite_multiple( assert cm_hash != bad_cmake_md5 -@pytest.mark.usefixtures( - "mock_packages", "mock_archive", "mock_fetch", "config", "install_mockery" -) +@pytest.mark.usefixtures("mock_packages", "mock_archive", "mock_fetch", "install_mockery") def test_install_conflicts(conflict_spec): # Make sure that spec with conflicts raises a SpackError with pytest.raises(SpackError): install(conflict_spec) -@pytest.mark.usefixtures( - "mock_packages", "mock_archive", "mock_fetch", "config", "install_mockery" -) +@pytest.mark.usefixtures("mock_packages", "mock_archive", "mock_fetch", "install_mockery") def test_install_invalid_spec(invalid_spec): # Make sure that invalid specs raise a SpackError with pytest.raises(SpecSyntaxError, match="unexpected tokens"): @@ -390,9 +378,7 @@ def test_install_from_file(spec, concretize, error_code, tmpdir): @pytest.mark.disable_clean_stage_check -@pytest.mark.usefixtures( - "mock_packages", "mock_archive", "mock_fetch", "config", "install_mockery" -) +@pytest.mark.usefixtures("mock_packages", "mock_archive", "mock_fetch", "install_mockery") @pytest.mark.parametrize( "exc_typename,msg", [("RuntimeError", "something weird happened"), ("ValueError", "spec is not concrete")], @@ -448,7 +434,6 @@ def test_junit_output_with_errors( mock_archive, mock_fetch, install_mockery, - config, tmpdir, monkeypatch, ): @@ -509,9 +494,7 @@ def test_install_mix_cli_and_files(clispecs, filespecs, tmpdir): assert install.returncode == 0 -def test_extra_files_are_archived( - mock_packages, mock_archive, mock_fetch, config, install_mockery -): +def test_extra_files_are_archived(mock_packages, mock_archive, mock_fetch, install_mockery): s = Spec("archive-files") s.concretize() @@ -570,100 +553,96 @@ def test_cdash_upload_build_error(tmpdir, mock_fetch, install_mockery, capfd): @pytest.mark.disable_clean_stage_check def test_cdash_upload_clean_build(tmpdir, mock_fetch, install_mockery, capfd): # capfd interferes with Spack's capturing of e.g., Build.xml output - with capfd.disabled(): - with tmpdir.as_cwd(): - install("--log-file=cdash_reports", "--log-format=cdash", "a") - report_dir = tmpdir.join("cdash_reports") - assert report_dir in tmpdir.listdir() - report_file = report_dir.join("a_Build.xml") - assert report_file in report_dir.listdir() - content = report_file.open().read() - assert "" in content - assert "" not in content + with capfd.disabled(), tmpdir.as_cwd(): + install("--log-file=cdash_reports", "--log-format=cdash", "pkg-a") + report_dir = tmpdir.join("cdash_reports") + assert report_dir in tmpdir.listdir() + report_file = report_dir.join("pkg-a_Build.xml") + assert report_file in report_dir.listdir() + content = report_file.open().read() + assert "" in content + assert "" not in content @pytest.mark.disable_clean_stage_check def test_cdash_upload_extra_params(tmpdir, mock_fetch, install_mockery, capfd): # capfd interferes with Spack's capture of e.g., Build.xml output - with capfd.disabled(): - with tmpdir.as_cwd(): - install( - "--log-file=cdash_reports", - "--log-format=cdash", - "--cdash-build=my_custom_build", - "--cdash-site=my_custom_site", - "--cdash-track=my_custom_track", - "a", - ) - report_dir = tmpdir.join("cdash_reports") - assert report_dir in tmpdir.listdir() - report_file = report_dir.join("a_Build.xml") - assert report_file in report_dir.listdir() - content = report_file.open().read() - assert 'Site BuildName="my_custom_build - a"' in content - assert 'Name="my_custom_site"' in content - assert "-my_custom_track" in content + with capfd.disabled(), tmpdir.as_cwd(): + install( + "--log-file=cdash_reports", + "--log-format=cdash", + "--cdash-build=my_custom_build", + "--cdash-site=my_custom_site", + "--cdash-track=my_custom_track", + "pkg-a", + ) + report_dir = tmpdir.join("cdash_reports") + assert report_dir in tmpdir.listdir() + report_file = report_dir.join("pkg-a_Build.xml") + assert report_file in report_dir.listdir() + content = report_file.open().read() + assert 'Site BuildName="my_custom_build - pkg-a"' in content + assert 'Name="my_custom_site"' in content + assert "-my_custom_track" in content @pytest.mark.disable_clean_stage_check def test_cdash_buildstamp_param(tmpdir, mock_fetch, install_mockery, capfd): # capfd interferes with Spack's capture of e.g., Build.xml output - with capfd.disabled(): - with tmpdir.as_cwd(): - cdash_track = "some_mocked_track" - buildstamp_format = "%Y%m%d-%H%M-{0}".format(cdash_track) - buildstamp = time.strftime(buildstamp_format, time.localtime(int(time.time()))) - install( - "--log-file=cdash_reports", - "--log-format=cdash", - "--cdash-buildstamp={0}".format(buildstamp), - "a", - ) - report_dir = tmpdir.join("cdash_reports") - assert report_dir in tmpdir.listdir() - report_file = report_dir.join("a_Build.xml") - assert report_file in report_dir.listdir() - content = report_file.open().read() - assert buildstamp in content + with capfd.disabled(), tmpdir.as_cwd(): + cdash_track = "some_mocked_track" + buildstamp_format = "%Y%m%d-%H%M-{0}".format(cdash_track) + buildstamp = time.strftime(buildstamp_format, time.localtime(int(time.time()))) + install( + "--log-file=cdash_reports", + "--log-format=cdash", + "--cdash-buildstamp={0}".format(buildstamp), + "pkg-a", + ) + report_dir = tmpdir.join("cdash_reports") + assert report_dir in tmpdir.listdir() + report_file = report_dir.join("pkg-a_Build.xml") + assert report_file in report_dir.listdir() + content = report_file.open().read() + assert buildstamp in content @pytest.mark.disable_clean_stage_check def test_cdash_install_from_spec_json( - tmpdir, mock_fetch, install_mockery, capfd, mock_packages, mock_archive, config + tmpdir, mock_fetch, install_mockery, capfd, mock_packages, mock_archive ): # capfd interferes with Spack's capturing - with capfd.disabled(): - with tmpdir.as_cwd(): - spec_json_path = str(tmpdir.join("spec.json")) - - pkg_spec = Spec("a") - pkg_spec.concretize() - - with open(spec_json_path, "w") as fd: - fd.write(pkg_spec.to_json(hash=ht.dag_hash)) - - install( - "--log-format=cdash", - "--log-file=cdash_reports", - "--cdash-build=my_custom_build", - "--cdash-site=my_custom_site", - "--cdash-track=my_custom_track", - "-f", - spec_json_path, - ) + with capfd.disabled(), tmpdir.as_cwd(): + spec_json_path = str(tmpdir.join("spec.json")) - report_dir = tmpdir.join("cdash_reports") - assert report_dir in tmpdir.listdir() - report_file = report_dir.join("a_Configure.xml") - assert report_file in report_dir.listdir() - content = report_file.open().read() - install_command_regex = re.compile( - r"(.+)", re.MULTILINE | re.DOTALL - ) - m = install_command_regex.search(content) - assert m - install_command = m.group(1) - assert "a@" in install_command + pkg_spec = Spec("pkg-a") + pkg_spec.concretize() + + with open(spec_json_path, "w") as fd: + fd.write(pkg_spec.to_json(hash=ht.dag_hash)) + + install( + "--log-format=cdash", + "--log-file=cdash_reports", + "--cdash-build=my_custom_build", + "--cdash-site=my_custom_site", + "--cdash-track=my_custom_track", + "-f", + spec_json_path, + ) + + report_dir = tmpdir.join("cdash_reports") + assert report_dir in tmpdir.listdir() + report_file = report_dir.join("pkg-a_Configure.xml") + assert report_file in report_dir.listdir() + content = report_file.open().read() + install_command_regex = re.compile( + r"(.+)", re.MULTILINE | re.DOTALL + ) + m = install_command_regex.search(content) + assert m + install_command = m.group(1) + assert "pkg-a@" in install_command @pytest.mark.disable_clean_stage_check @@ -795,15 +774,15 @@ def test_install_no_add_in_env(tmpdir, mock_fetch, install_mockery, mutable_mock # ^libdwarf # ^mpich # libelf@0.8.10 - # a~bvv - # ^b - # a - # ^b + # pkg-a~bvv + # ^pkg-b + # pkg-a + # ^pkg-b e = ev.create("test", with_view=False) e.add("mpileaks") e.add("libelf@0.8.10") # so env has both root and dep libelf specs - e.add("a") - e.add("a ~bvv") + e.add("pkg-a") + e.add("pkg-a ~bvv") e.concretize() e.write() env_specs = e.all_specs() @@ -814,9 +793,9 @@ def test_install_no_add_in_env(tmpdir, mock_fetch, install_mockery, mutable_mock # First find and remember some target concrete specs in the environment for e_spec in env_specs: - if e_spec.satisfies(Spec("a ~bvv")): + if e_spec.satisfies(Spec("pkg-a ~bvv")): a_spec = e_spec - elif e_spec.name == "b": + elif e_spec.name == "pkg-b": b_spec = e_spec elif e_spec.satisfies(Spec("mpi")): mpi_spec = e_spec @@ -839,8 +818,8 @@ def test_install_no_add_in_env(tmpdir, mock_fetch, install_mockery, mutable_mock assert "You can add specs to the environment with 'spack add " in inst_out # Without --add, ensure that two packages "a" get installed - inst_out = install("a", output=str) - assert len([x for x in e.all_specs() if x.installed and x.name == "a"]) == 2 + inst_out = install("pkg-a", output=str) + assert len([x for x in e.all_specs() if x.installed and x.name == "pkg-a"]) == 2 # Install an unambiguous dependency spec (that already exists as a dep # in the environment) and make sure it gets installed (w/ deps), @@ -873,7 +852,7 @@ def test_install_no_add_in_env(tmpdir, mock_fetch, install_mockery, mutable_mock # root of the environment as well as installed. assert b_spec not in e.roots() - install("--add", "b") + install("--add", "pkg-b") assert b_spec in e.roots() assert b_spec not in e.uninstalled_specs() @@ -908,7 +887,7 @@ def test_cdash_auth_token(tmpdir, mock_fetch, install_mockery, monkeypatch, capf # capfd interferes with Spack's capturing with tmpdir.as_cwd(), capfd.disabled(): monkeypatch.setenv("SPACK_CDASH_AUTH_TOKEN", "asdf") - out = install("-v", "--log-file=cdash_reports", "--log-format=cdash", "a") + out = install("-v", "--log-file=cdash_reports", "--log-format=cdash", "pkg-a") assert "Using CDash auth token from environment" in out @@ -916,54 +895,42 @@ def test_cdash_auth_token(tmpdir, mock_fetch, install_mockery, monkeypatch, capf @pytest.mark.disable_clean_stage_check def test_cdash_configure_warning(tmpdir, mock_fetch, install_mockery, capfd): # capfd interferes with Spack's capturing of e.g., Build.xml output - with capfd.disabled(): - with tmpdir.as_cwd(): - # Test would fail if install raised an error. - - # Ensure that even on non-x86_64 architectures, there are no - # dependencies installed - spec = spack.spec.Spec("configure-warning").concretized() - spec.clear_dependencies() - specfile = "./spec.json" - with open(specfile, "w") as f: - f.write(spec.to_json()) - - install("--log-file=cdash_reports", "--log-format=cdash", specfile) - # Verify Configure.xml exists with expected contents. - report_dir = tmpdir.join("cdash_reports") - assert report_dir in tmpdir.listdir() - report_file = report_dir.join("Configure.xml") - assert report_file in report_dir.listdir() - content = report_file.open().read() - assert "foo: No such file or directory" in content + with capfd.disabled(), tmpdir.as_cwd(): + # Test would fail if install raised an error. + + # Ensure that even on non-x86_64 architectures, there are no + # dependencies installed + spec = Spec("configure-warning").concretized() + spec.clear_dependencies() + specfile = "./spec.json" + with open(specfile, "w") as f: + f.write(spec.to_json()) + + install("--log-file=cdash_reports", "--log-format=cdash", specfile) + # Verify Configure.xml exists with expected contents. + report_dir = tmpdir.join("cdash_reports") + assert report_dir in tmpdir.listdir() + report_file = report_dir.join("Configure.xml") + assert report_file in report_dir.listdir() + content = report_file.open().read() + assert "foo: No such file or directory" in content @pytest.mark.not_on_windows("ArchSpec gives test platform debian rather than windows") def test_compiler_bootstrap( - install_mockery_mutable_config, - mock_packages, - mock_fetch, - mock_archive, - mutable_config, - monkeypatch, + install_mockery, mock_packages, mock_fetch, mock_archive, mutable_config, monkeypatch ): monkeypatch.setattr(spack.concretize.Concretizer, "check_for_compiler_existence", False) spack.config.set("config:install_missing_compilers", True) assert CompilerSpec("gcc@=12.0") not in compilers.all_compiler_specs() # Test succeeds if it does not raise an error - install("a%gcc@=12.0") + install("pkg-a%gcc@=12.0") @pytest.mark.not_on_windows("Binary mirrors not supported on windows") def test_compiler_bootstrap_from_binary_mirror( - install_mockery_mutable_config, - mock_packages, - mock_fetch, - mock_archive, - mutable_config, - monkeypatch, - tmpdir, + install_mockery, mock_packages, mock_fetch, mock_archive, mutable_config, monkeypatch, tmpdir ): """ Make sure installing compiler from buildcache registers compiler @@ -992,19 +959,14 @@ def test_compiler_bootstrap_from_binary_mirror( # Now make sure that when the compiler is installed from binary mirror, # it also gets configured as a compiler. Test succeeds if it does not # raise an error - install("--no-check-signature", "--cache-only", "--only", "dependencies", "b%gcc@=10.2.0") - install("--no-cache", "--only", "package", "b%gcc@10.2.0") + install("--no-check-signature", "--cache-only", "--only", "dependencies", "pkg-b%gcc@=10.2.0") + install("--no-cache", "--only", "package", "pkg-b%gcc@10.2.0") @pytest.mark.not_on_windows("ArchSpec gives test platform debian rather than windows") @pytest.mark.regression("16221") def test_compiler_bootstrap_already_installed( - install_mockery_mutable_config, - mock_packages, - mock_fetch, - mock_archive, - mutable_config, - monkeypatch, + install_mockery, mock_packages, mock_fetch, mock_archive, mutable_config, monkeypatch ): monkeypatch.setattr(spack.concretize.Concretizer, "check_for_compiler_existence", False) spack.config.set("config:install_missing_compilers", True) @@ -1013,7 +975,7 @@ def test_compiler_bootstrap_already_installed( # Test succeeds if it does not raise an error install("gcc@=12.0") - install("a%gcc@=12.0") + install("pkg-a%gcc@=12.0") def test_install_fails_no_args(tmpdir): @@ -1104,13 +1066,7 @@ def test_installation_fail_tests(install_mockery, mock_fetch, name, method): @pytest.mark.not_on_windows("Buildcache not supported on windows") def test_install_use_buildcache( - capsys, - mock_packages, - mock_fetch, - mock_archive, - mock_binary_index, - tmpdir, - install_mockery_mutable_config, + capsys, mock_packages, mock_fetch, mock_archive, mock_binary_index, tmpdir, install_mockery ): """ Make sure installing with use-buildcache behaves correctly. @@ -1183,19 +1139,19 @@ def install_use_buildcache(opt): @pytest.mark.not_on_windows("Windows logger I/O operation on closed file when install fails") @pytest.mark.regression("34006") @pytest.mark.disable_clean_stage_check -def test_padded_install_runtests_root(install_mockery_mutable_config, mock_fetch): +def test_padded_install_runtests_root(install_mockery, mock_fetch): spack.config.set("config:install_tree:padded_length", 255) output = install("--test=root", "--no-cache", "test-build-callbacks", fail_on_error=False) assert output.count("method not implemented") == 1 @pytest.mark.regression("35337") -def test_report_filename_for_cdash(install_mockery_mutable_config, mock_fetch): +def test_report_filename_for_cdash(install_mockery, mock_fetch): """Test that the temporary file used to write the XML for CDash is not the upload URL""" parser = argparse.ArgumentParser() spack.cmd.install.setup_parser(parser) args = parser.parse_args( - ["--cdash-upload-url", "https://blahblah/submit.php?project=debugging", "a"] + ["--cdash-upload-url", "https://blahblah/submit.php?project=debugging", "pkg-a"] ) specs = spack.cmd.install.concrete_specs_from_cli(args, {}) filename = spack.cmd.install.report_filename(args, specs) diff --git a/lib/spack/spack/test/cmd/load.py b/lib/spack/spack/test/cmd/load.py index e2abe72e0e15d9..73a062ebd41203 100644 --- a/lib/spack/spack/test/cmd/load.py +++ b/lib/spack/spack/test/cmd/load.py @@ -4,6 +4,7 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) import os import re +import sys import pytest @@ -17,101 +18,125 @@ install = SpackCommand("install") location = SpackCommand("location") -pytestmark = pytest.mark.not_on_windows("does not run on windows") - def test_manpath_trailing_colon( install_mockery, mock_fetch, mock_archive, mock_packages, working_env ): + (shell, set_command, commandsep) = ( + ("--bat", 'set "%s=%s"', "\n") + if sys.platform == "win32" + else ("--sh", "export %s=%s", ";") + ) + """Test that the commands generated by load add the MANPATH prefix inspections. Also test that Spack correctly preserves the default/existing manpath search path via a trailing colon""" install("mpileaks") - sh_out = load("--sh", "mpileaks") - lines = sh_out.split("\n") - assert any(re.match(r"export MANPATH=.*:;", ln) for ln in lines) - - os.environ["MANPATH"] = "/tmp/man:" - - sh_out = load("--sh", "mpileaks") - lines = sh_out.split("\n") - assert any(re.match(r"export MANPATH=.*:/tmp/man:;", ln) for ln in lines) - - -def test_load_recursive(install_mockery, mock_fetch, mock_archive, mock_packages, working_env): - """Test that `spack load` applies prefix inspections of its required runtime deps in - topo-order""" - install("mpileaks") - mpileaks_spec = spack.spec.Spec("mpileaks").concretized() - - # Ensure our reference variable is cleed. - os.environ["CMAKE_PREFIX_PATH"] = "/hello:/world" - - sh_out = load("--sh", "mpileaks") - csh_out = load("--csh", "mpileaks") - - def extract_cmake_prefix_path(output, prefix): - return next(cmd for cmd in output.split(";") if cmd.startswith(prefix))[ - len(prefix) : - ].split(":") + sh_out = load(shell, "mpileaks") + lines = [line.strip("\n") for line in sh_out.split(commandsep)] + assert any(re.match(set_command % ("MANPATH", ".*" + os.pathsep), ln) for ln in lines) + os.environ["MANPATH"] = "/tmp/man" + os.pathsep - # Map a prefix found in CMAKE_PREFIX_PATH back to a package name in mpileaks' DAG. - prefix_to_pkg = lambda prefix: next( - s.name for s in mpileaks_spec.traverse() if s.prefix == prefix + sh_out = load(shell, "mpileaks") + lines = [line.strip("\n") for line in sh_out.split(commandsep)] + assert any( + re.match(set_command % ("MANPATH", ".*" + os.pathsep + "/tmp/man" + os.pathsep), ln) + for ln in lines ) - paths_sh = extract_cmake_prefix_path(sh_out, prefix="export CMAKE_PREFIX_PATH=") - paths_csh = extract_cmake_prefix_path(csh_out, prefix="setenv CMAKE_PREFIX_PATH ") - # Shouldn't be a difference between loading csh / sh, so check they're the same. - assert paths_sh == paths_csh - - # We should've prepended new paths, and keep old ones. - assert paths_sh[-2:] == ["/hello", "/world"] - - # All but the last two paths are added by spack load; lookup what packages they're from. - pkgs = [prefix_to_pkg(p) for p in paths_sh[:-2]] - - # Do we have all the runtime packages? - assert set(pkgs) == set( - s.name for s in mpileaks_spec.traverse(deptype=("link", "run"), root=True) - ) - - # Finally, do we list them in topo order? - for i, pkg in enumerate(pkgs): - set(s.name for s in mpileaks_spec[pkg].traverse(direction="parents")) in set(pkgs[:i]) - - # Lastly, do we keep track that mpileaks was loaded? - assert f"export {uenv.spack_loaded_hashes_var}={mpileaks_spec.dag_hash()}" in sh_out - assert f"setenv {uenv.spack_loaded_hashes_var} {mpileaks_spec.dag_hash()}" in csh_out - - -def test_load_includes_run_env(install_mockery, mock_fetch, mock_archive, mock_packages): +def test_load_recursive(install_mockery, mock_fetch, mock_archive, mock_packages, working_env): + def test_load_shell(shell, set_command): + """Test that `spack load` applies prefix inspections of its required runtime deps in + topo-order""" + install("mpileaks") + mpileaks_spec = spack.spec.Spec("mpileaks").concretized() + + # Ensure our reference variable is clean. + os.environ["CMAKE_PREFIX_PATH"] = "/hello" + os.pathsep + "/world" + + shell_out = load(shell, "mpileaks") + + def extract_value(output, variable): + match = re.search(set_command % variable, output, flags=re.MULTILINE) + value = match.group(1) + return value.split(os.pathsep) + + # Map a prefix found in CMAKE_PREFIX_PATH back to a package name in mpileaks' DAG. + prefix_to_pkg = lambda prefix: next( + s.name for s in mpileaks_spec.traverse() if s.prefix == prefix + ) + + paths_shell = extract_value(shell_out, "CMAKE_PREFIX_PATH") + + # We should've prepended new paths, and keep old ones. + assert paths_shell[-2:] == ["/hello", "/world"] + + # All but the last two paths are added by spack load; lookup what packages they're from. + pkgs = [prefix_to_pkg(p) for p in paths_shell[:-2]] + + # Do we have all the runtime packages? + assert set(pkgs) == set( + s.name for s in mpileaks_spec.traverse(deptype=("link", "run"), root=True) + ) + + # Finally, do we list them in topo order? + for i, pkg in enumerate(pkgs): + set(s.name for s in mpileaks_spec[pkg].traverse(direction="parents")) in set(pkgs[:i]) + + # Lastly, do we keep track that mpileaks was loaded? + assert ( + extract_value(shell_out, uenv.spack_loaded_hashes_var)[0] == mpileaks_spec.dag_hash() + ) + return paths_shell + + if sys.platform == "win32": + shell, set_command = ("--bat", r'set "%s=(.*)"') + test_load_shell(shell, set_command) + else: + params = [("--sh", r"export %s=([^;]*)"), ("--csh", r"setenv %s ([^;]*)")] + shell, set_command = params[0] + paths_sh = test_load_shell(shell, set_command) + shell, set_command = params[1] + paths_csh = test_load_shell(shell, set_command) + assert paths_sh == paths_csh + + +@pytest.mark.parametrize( + "shell,set_command", + ( + [("--bat", 'set "%s=%s"')] + if sys.platform == "win32" + else [("--sh", "export %s=%s"), ("--csh", "setenv %s %s")] + ), +) +def test_load_includes_run_env( + shell, set_command, install_mockery, mock_fetch, mock_archive, mock_packages +): """Tests that environment changes from the package's `setup_run_environment` method are added to the user environment in addition to the prefix inspections""" install("mpileaks") - sh_out = load("--sh", "mpileaks") - csh_out = load("--csh", "mpileaks") + shell_out = load(shell, "mpileaks") - assert "export FOOBAR=mpileaks" in sh_out - assert "setenv FOOBAR mpileaks" in csh_out + assert set_command % ("FOOBAR", "mpileaks") in shell_out def test_load_first(install_mockery, mock_fetch, mock_archive, mock_packages): """Test with and without the --first option""" + shell = "--bat" if sys.platform == "win32" else "--sh" install("libelf@0.8.12") install("libelf@0.8.13") # Now there are two versions of libelf, which should cause an error - out = load("--sh", "libelf", fail_on_error=False) + out = load(shell, "libelf", fail_on_error=False) assert "matches multiple packages" in out assert "Use a more specific spec" in out # Using --first should avoid the error condition - load("--sh", "--first", "libelf") + load(shell, "--first", "libelf") def test_load_fails_no_shell(install_mockery, mock_fetch, mock_archive, mock_packages): @@ -122,7 +147,24 @@ def test_load_fails_no_shell(install_mockery, mock_fetch, mock_archive, mock_pac assert "To set up shell support" in out -def test_unload(install_mockery, mock_fetch, mock_archive, mock_packages, working_env): +@pytest.mark.parametrize( + "shell,set_command,unset_command", + ( + [("--bat", 'set "%s=%s"', 'set "%s="')] + if sys.platform == "win32" + else [("--sh", "export %s=%s", "unset %s"), ("--csh", "setenv %s %s", "unsetenv %s")] + ), +) +def test_unload( + shell, + set_command, + unset_command, + install_mockery, + mock_fetch, + mock_archive, + mock_packages, + working_env, +): """Tests that any variables set in the user environment are undone by the unload command""" install("mpileaks") @@ -130,16 +172,16 @@ def test_unload(install_mockery, mock_fetch, mock_archive, mock_packages, workin # Set so unload has something to do os.environ["FOOBAR"] = "mpileaks" - os.environ[uenv.spack_loaded_hashes_var] = "%s:%s" % (mpileaks_spec.dag_hash(), "garbage") + os.environ[uenv.spack_loaded_hashes_var] = ("%s" + os.pathsep + "%s") % ( + mpileaks_spec.dag_hash(), + "garbage", + ) - sh_out = unload("--sh", "mpileaks") - csh_out = unload("--csh", "mpileaks") + shell_out = unload(shell, "mpileaks") - assert "unset FOOBAR" in sh_out - assert "unsetenv FOOBAR" in csh_out + assert (unset_command % "FOOBAR") in shell_out - assert "export %s=garbage" % uenv.spack_loaded_hashes_var in sh_out - assert "setenv %s garbage" % uenv.spack_loaded_hashes_var in csh_out + assert set_command % (uenv.spack_loaded_hashes_var, "garbage") in shell_out def test_unload_fails_no_shell( diff --git a/lib/spack/spack/test/cmd/location.py b/lib/spack/spack/test/cmd/location.py index 25008e8e447b35..9e42a03b021828 100644 --- a/lib/spack/spack/test/cmd/location.py +++ b/lib/spack/spack/test/cmd/location.py @@ -3,7 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import os import shutil import pytest @@ -16,10 +15,8 @@ from spack.main import SpackCommand, SpackCommandError # Everything here uses (or can use) the mock config and database. -pytestmark = [ - pytest.mark.usefixtures("config", "database"), - pytest.mark.not_on_windows("does not run on windows"), -] +pytestmark = [pytest.mark.usefixtures("mutable_config", "mutable_database")] + # location prints out "locations of packages and spack directories" location = SpackCommand("location") env = SpackCommand("env") @@ -65,7 +62,7 @@ def test_location_source_dir_missing(): prefix = "==> Error: " expected = ( "%sSource directory does not exist yet. Run this to create it:" - "%s spack stage %s" % (prefix, os.linesep, spec) + "%s spack stage %s" % (prefix, "\n", spec) ) out = location("--source-dir", spec, fail_on_error=False).strip() assert out == expected @@ -126,6 +123,7 @@ def test_location_env_missing(): @pytest.mark.db +@pytest.mark.not_on_windows("Broken on Windows") def test_location_install_dir(mock_spec): """Tests spack location --install-dir.""" spec, _ = mock_spec diff --git a/lib/spack/spack/test/cmd/maintainers.py b/lib/spack/spack/test/cmd/maintainers.py index 2724d7ec834db6..3928bebff11c09 100644 --- a/lib/spack/spack/test/cmd/maintainers.py +++ b/lib/spack/spack/test/cmd/maintainers.py @@ -121,7 +121,7 @@ def test_maintainers_list_packages(mock_packages, capfd): def test_maintainers_list_fails(mock_packages, capfd): - out = maintainers("a", fail_on_error=False) + out = maintainers("pkg-a", fail_on_error=False) assert not out assert maintainers.returncode == 1 diff --git a/lib/spack/spack/test/cmd/mirror.py b/lib/spack/spack/test/cmd/mirror.py index ca4c0dd8ce6f82..c1e24a9825ea55 100644 --- a/lib/spack/spack/test/cmd/mirror.py +++ b/lib/spack/spack/test/cmd/mirror.py @@ -35,7 +35,7 @@ def test_regression_8083(tmpdir, capfd, mock_packages, mock_fetch, config): @pytest.mark.regression("12345") -def test_mirror_from_env(tmp_path, mock_packages, mock_fetch, config, mutable_mock_env_path): +def test_mirror_from_env(tmp_path, mock_packages, mock_fetch, mutable_mock_env_path): mirror_dir = str(tmp_path / "mirror") env_name = "test" @@ -88,6 +88,7 @@ def __init__( exclude_file=None, exclude_specs=None, directory=None, + private=False, ): self.specs = specs or [] self.all = all @@ -96,6 +97,7 @@ def __init__( self.dependencies = dependencies self.exclude_file = exclude_file self.exclude_specs = exclude_specs + self.private = private self.directory = directory @@ -104,7 +106,7 @@ def test_exclude_specs(mock_packages, config): specs=["mpich"], versions_per_spec="all", exclude_specs="mpich@3.0.1:3.0.2 mpich@1.0" ) - mirror_specs = spack.cmd.mirror.concrete_specs_from_user(args) + mirror_specs, _ = spack.cmd.mirror._specs_and_action(args) expected_include = set( spack.spec.Spec(x).concretized() for x in ["mpich@3.0.3", "mpich@3.0.4", "mpich@3.0"] ) @@ -113,6 +115,19 @@ def test_exclude_specs(mock_packages, config): assert not any(spec.satisfies(y) for spec in mirror_specs for y in expected_exclude) +def test_exclude_specs_public_mirror(mock_packages, config): + args = MockMirrorArgs( + specs=["no-redistribute-dependent"], + versions_per_spec="all", + dependencies=True, + private=False, + ) + + mirror_specs, _ = spack.cmd.mirror._specs_and_action(args) + assert not any(s.name == "no-redistribute" for s in mirror_specs) + assert any(s.name == "no-redistribute-dependent" for s in mirror_specs) + + def test_exclude_file(mock_packages, tmpdir, config): exclude_path = os.path.join(str(tmpdir), "test-exclude.txt") with open(exclude_path, "w") as exclude_file: @@ -125,7 +140,7 @@ def test_exclude_file(mock_packages, tmpdir, config): args = MockMirrorArgs(specs=["mpich"], versions_per_spec="all", exclude_file=exclude_path) - mirror_specs = spack.cmd.mirror.concrete_specs_from_user(args) + mirror_specs, _ = spack.cmd.mirror._specs_and_action(args) expected_include = set( spack.spec.Spec(x).concretized() for x in ["mpich@3.0.3", "mpich@3.0.4", "mpich@3.0"] ) @@ -217,13 +232,7 @@ def test_mirror_name_collision(mutable_config): def test_mirror_destroy( - install_mockery_mutable_config, - mock_packages, - mock_fetch, - mock_archive, - mutable_config, - monkeypatch, - tmpdir, + install_mockery, mock_packages, mock_fetch, mock_archive, mutable_config, monkeypatch, tmpdir ): # Create a temp mirror directory for buildcache usage mirror_dir = tmpdir.join("mirror_dir") @@ -262,11 +271,9 @@ def test_mirror_destroy( class TestMirrorCreate: @pytest.mark.regression("31736", "31985") def test_all_specs_with_all_versions_dont_concretize(self): - args = MockMirrorArgs(exclude_file=None, exclude_specs=None) - specs = spack.cmd.mirror.all_specs_with_all_versions( - selection_fn=spack.cmd.mirror.not_excluded_fn(args) - ) - assert all(not s.concrete for s in specs) + args = MockMirrorArgs(all=True, exclude_file=None, exclude_specs=None) + mirror_specs, _ = spack.cmd.mirror._specs_and_action(args) + assert all(not s.concrete for s in mirror_specs) @pytest.mark.parametrize( "cli_args,error_str", @@ -324,8 +331,8 @@ def test_error_conditions(self, cli_args, error_str): ], ) def test_exclude_specs_from_user(self, cli_args, not_expected, config): - specs = spack.cmd.mirror.concrete_specs_from_user(MockMirrorArgs(**cli_args)) - assert not any(s.satisfies(y) for s in specs for y in not_expected) + mirror_specs, _ = spack.cmd.mirror._specs_and_action(MockMirrorArgs(**cli_args)) + assert not any(s.satisfies(y) for s in mirror_specs for y in not_expected) @pytest.mark.parametrize("abstract_specs", [("bowtie", "callpath")]) def test_specs_from_cli_are_the_same_as_from_file(self, abstract_specs, config, tmpdir): @@ -407,3 +414,27 @@ def test_mirror_add_set_signed(mutable_config): assert spack.config.get("mirrors:example") == {"url": "http://example.com", "signed": False} mirror("set", "--signed", "example") assert spack.config.get("mirrors:example") == {"url": "http://example.com", "signed": True} + + +def test_mirror_add_set_autopush(mutable_config): + # Add mirror without autopush + mirror("add", "example", "http://example.com") + assert spack.config.get("mirrors:example") == "http://example.com" + mirror("set", "--no-autopush", "example") + assert spack.config.get("mirrors:example") == {"url": "http://example.com", "autopush": False} + mirror("set", "--autopush", "example") + assert spack.config.get("mirrors:example") == {"url": "http://example.com", "autopush": True} + mirror("set", "--no-autopush", "example") + assert spack.config.get("mirrors:example") == {"url": "http://example.com", "autopush": False} + mirror("remove", "example") + + # Add mirror with autopush + mirror("add", "--autopush", "example", "http://example.com") + assert spack.config.get("mirrors:example") == {"url": "http://example.com", "autopush": True} + mirror("set", "--autopush", "example") + assert spack.config.get("mirrors:example") == {"url": "http://example.com", "autopush": True} + mirror("set", "--no-autopush", "example") + assert spack.config.get("mirrors:example") == {"url": "http://example.com", "autopush": False} + mirror("set", "--autopush", "example") + assert spack.config.get("mirrors:example") == {"url": "http://example.com", "autopush": True} + mirror("remove", "example") diff --git a/lib/spack/spack/test/cmd/module.py b/lib/spack/spack/test/cmd/module.py index 4c1ea784320504..4b460eb90aead9 100644 --- a/lib/spack/spack/test/cmd/module.py +++ b/lib/spack/spack/test/cmd/module.py @@ -11,6 +11,7 @@ import spack.config import spack.main import spack.modules +import spack.spec import spack.store module = spack.main.SpackCommand("module") @@ -139,7 +140,7 @@ def test_find_recursive(): @pytest.mark.db -def test_find_recursive_excluded(database, module_configuration): +def test_find_recursive_excluded(mutable_database, module_configuration): module_configuration("exclude") module("lmod", "refresh", "-y", "--delete-tree") @@ -147,7 +148,7 @@ def test_find_recursive_excluded(database, module_configuration): @pytest.mark.db -def test_loads_recursive_excluded(database, module_configuration): +def test_loads_recursive_excluded(mutable_database, module_configuration): module_configuration("exclude") module("lmod", "refresh", "-y", "--delete-tree") @@ -178,8 +179,8 @@ def test_setdefault_command(mutable_database, mutable_config): } } spack.config.set("modules", data) - # Install two different versions of a package - other_spec, preferred = "a@1.0", "a@2.0" + # Install two different versions of pkg-a + other_spec, preferred = "pkg-a@1.0", "pkg-a@2.0" spack.spec.Spec(other_spec).concretized().package.do_install(fake=True) spack.spec.Spec(preferred).concretized().package.do_install(fake=True) diff --git a/lib/spack/spack/test/cmd/pkg.py b/lib/spack/spack/test/cmd/pkg.py index 5312b4e6ffa531..cde8390dc4f7f9 100644 --- a/lib/spack/spack/test/cmd/pkg.py +++ b/lib/spack/spack/test/cmd/pkg.py @@ -13,6 +13,7 @@ import spack.cmd.pkg import spack.main import spack.repo +import spack.util.file_cache #: new fake package template pkg_template = """\ @@ -28,19 +29,20 @@ def install(self, spec, prefix): pass """ -abc = set(("pkg-a", "pkg-b", "pkg-c")) -abd = set(("pkg-a", "pkg-b", "pkg-d")) +abc = {"mockpkg-a", "mockpkg-b", "mockpkg-c"} +abd = {"mockpkg-a", "mockpkg-b", "mockpkg-d"} # Force all tests to use a git repository *in* the mock packages repo. @pytest.fixture(scope="module") -def mock_pkg_git_repo(git, tmpdir_factory): +def mock_pkg_git_repo(git, tmp_path_factory): """Copy the builtin.mock repo and make a mutable git repo inside it.""" - tmproot = tmpdir_factory.mktemp("mock_pkg_git_repo") - repo_path = tmproot.join("builtin.mock") + root_dir = tmp_path_factory.mktemp("mock_pkg_git_repo") + repo_dir = root_dir / "builtin.mock" + shutil.copytree(spack.paths.mock_packages_path, str(repo_dir)) - shutil.copytree(spack.paths.mock_packages_path, str(repo_path)) - mock_repo = spack.repo.RepoPath(str(repo_path)) + repo_cache = spack.util.file_cache.FileCache(str(root_dir / "cache")) + mock_repo = spack.repo.RepoPath(str(repo_dir), cache=repo_cache) mock_repo_packages = mock_repo.repos[0].packages_path with working_dir(mock_repo_packages): @@ -53,29 +55,35 @@ def mock_pkg_git_repo(git, tmpdir_factory): git("config", "user.name", "Spack Testing") git("-c", "commit.gpgsign=false", "commit", "-m", "initial mock repo commit") - # add commit with pkg-a, pkg-b, pkg-c packages - mkdirp("pkg-a", "pkg-b", "pkg-c") - with open("pkg-a/package.py", "w") as f: + # add commit with mockpkg-a, mockpkg-b, mockpkg-c packages + mkdirp("mockpkg-a", "mockpkg-b", "mockpkg-c") + with open("mockpkg-a/package.py", "w") as f: f.write(pkg_template.format(name="PkgA")) - with open("pkg-b/package.py", "w") as f: + with open("mockpkg-b/package.py", "w") as f: f.write(pkg_template.format(name="PkgB")) - with open("pkg-c/package.py", "w") as f: + with open("mockpkg-c/package.py", "w") as f: f.write(pkg_template.format(name="PkgC")) - git("add", "pkg-a", "pkg-b", "pkg-c") - git("-c", "commit.gpgsign=false", "commit", "-m", "add pkg-a, pkg-b, pkg-c") - - # remove pkg-c, add pkg-d - with open("pkg-b/package.py", "a") as f: - f.write("\n# change pkg-b") - git("add", "pkg-b") - mkdirp("pkg-d") - with open("pkg-d/package.py", "w") as f: + git("add", "mockpkg-a", "mockpkg-b", "mockpkg-c") + git("-c", "commit.gpgsign=false", "commit", "-m", "add mockpkg-a, mockpkg-b, mockpkg-c") + + # remove mockpkg-c, add mockpkg-d + with open("mockpkg-b/package.py", "a") as f: + f.write("\n# change mockpkg-b") + git("add", "mockpkg-b") + mkdirp("mockpkg-d") + with open("mockpkg-d/package.py", "w") as f: f.write(pkg_template.format(name="PkgD")) - git("add", "pkg-d") - git("rm", "-rf", "pkg-c") - git("-c", "commit.gpgsign=false", "commit", "-m", "change pkg-b, remove pkg-c, add pkg-d") - - with spack.repo.use_repositories(str(repo_path)): + git("add", "mockpkg-d") + git("rm", "-rf", "mockpkg-c") + git( + "-c", + "commit.gpgsign=false", + "commit", + "-m", + "change mockpkg-b, remove mockpkg-c, add mockpkg-d", + ) + + with spack.repo.use_repositories(str(repo_dir)): yield mock_repo_packages @@ -86,12 +94,11 @@ def mock_pkg_names(): # Be sure to include virtual packages since packages with stand-alone # tests may inherit additional tests from the virtuals they provide, # such as packages that implement `mpi`. - names = set( + return { name for name in repo.all_package_names(include_virtuals=True) - if not name.startswith("pkg-") - ) - return names + if not name.startswith("mockpkg-") + } def split(output): @@ -113,17 +120,17 @@ def test_mock_packages_path(mock_packages): def test_pkg_add(git, mock_pkg_git_repo): with working_dir(mock_pkg_git_repo): - mkdirp("pkg-e") - with open("pkg-e/package.py", "w") as f: + mkdirp("mockpkg-e") + with open("mockpkg-e/package.py", "w") as f: f.write(pkg_template.format(name="PkgE")) - pkg("add", "pkg-e") + pkg("add", "mockpkg-e") with working_dir(mock_pkg_git_repo): try: - assert "A pkg-e/package.py" in git("status", "--short", output=str) + assert "A mockpkg-e/package.py" in git("status", "--short", output=str) finally: - shutil.rmtree("pkg-e") + shutil.rmtree("mockpkg-e") # Removing a package mid-run disrupts Spack's caching if spack.repo.PATH.repos[0]._fast_package_checker: spack.repo.PATH.repos[0]._fast_package_checker.invalidate() @@ -138,10 +145,10 @@ def test_pkg_list(mock_pkg_git_repo, mock_pkg_names): assert sorted(mock_pkg_names) == sorted(out) out = split(pkg("list", "HEAD^")) - assert sorted(mock_pkg_names.union(["pkg-a", "pkg-b", "pkg-c"])) == sorted(out) + assert sorted(mock_pkg_names.union(["mockpkg-a", "mockpkg-b", "mockpkg-c"])) == sorted(out) out = split(pkg("list", "HEAD")) - assert sorted(mock_pkg_names.union(["pkg-a", "pkg-b", "pkg-d"])) == sorted(out) + assert sorted(mock_pkg_names.union(["mockpkg-a", "mockpkg-b", "mockpkg-d"])) == sorted(out) # test with three dots to make sure pkg calls `git merge-base` out = split(pkg("list", "HEAD^^...")) @@ -151,25 +158,25 @@ def test_pkg_list(mock_pkg_git_repo, mock_pkg_names): @pytest.mark.not_on_windows("stdout format conflict") def test_pkg_diff(mock_pkg_git_repo, mock_pkg_names): out = split(pkg("diff", "HEAD^^", "HEAD^")) - assert out == ["HEAD^:", "pkg-a", "pkg-b", "pkg-c"] + assert out == ["HEAD^:", "mockpkg-a", "mockpkg-b", "mockpkg-c"] out = split(pkg("diff", "HEAD^^", "HEAD")) - assert out == ["HEAD:", "pkg-a", "pkg-b", "pkg-d"] + assert out == ["HEAD:", "mockpkg-a", "mockpkg-b", "mockpkg-d"] out = split(pkg("diff", "HEAD^", "HEAD")) - assert out == ["HEAD^:", "pkg-c", "HEAD:", "pkg-d"] + assert out == ["HEAD^:", "mockpkg-c", "HEAD:", "mockpkg-d"] @pytest.mark.not_on_windows("stdout format conflict") def test_pkg_added(mock_pkg_git_repo): out = split(pkg("added", "HEAD^^", "HEAD^")) - assert ["pkg-a", "pkg-b", "pkg-c"] == out + assert ["mockpkg-a", "mockpkg-b", "mockpkg-c"] == out out = split(pkg("added", "HEAD^^", "HEAD")) - assert ["pkg-a", "pkg-b", "pkg-d"] == out + assert ["mockpkg-a", "mockpkg-b", "mockpkg-d"] == out out = split(pkg("added", "HEAD^", "HEAD")) - assert ["pkg-d"] == out + assert ["mockpkg-d"] == out out = split(pkg("added", "HEAD", "HEAD")) assert out == [] @@ -184,7 +191,7 @@ def test_pkg_removed(mock_pkg_git_repo): assert out == [] out = split(pkg("removed", "HEAD^", "HEAD")) - assert out == ["pkg-c"] + assert out == ["mockpkg-c"] @pytest.mark.not_on_windows("stdout format conflict") @@ -196,34 +203,34 @@ def test_pkg_changed(mock_pkg_git_repo): assert out == [] out = split(pkg("changed", "--type", "a", "HEAD^^", "HEAD^")) - assert out == ["pkg-a", "pkg-b", "pkg-c"] + assert out == ["mockpkg-a", "mockpkg-b", "mockpkg-c"] out = split(pkg("changed", "--type", "r", "HEAD^^", "HEAD^")) assert out == [] out = split(pkg("changed", "--type", "ar", "HEAD^^", "HEAD^")) - assert out == ["pkg-a", "pkg-b", "pkg-c"] + assert out == ["mockpkg-a", "mockpkg-b", "mockpkg-c"] out = split(pkg("changed", "--type", "arc", "HEAD^^", "HEAD^")) - assert out == ["pkg-a", "pkg-b", "pkg-c"] + assert out == ["mockpkg-a", "mockpkg-b", "mockpkg-c"] out = split(pkg("changed", "HEAD^", "HEAD")) - assert out == ["pkg-b"] + assert out == ["mockpkg-b"] out = split(pkg("changed", "--type", "c", "HEAD^", "HEAD")) - assert out == ["pkg-b"] + assert out == ["mockpkg-b"] out = split(pkg("changed", "--type", "a", "HEAD^", "HEAD")) - assert out == ["pkg-d"] + assert out == ["mockpkg-d"] out = split(pkg("changed", "--type", "r", "HEAD^", "HEAD")) - assert out == ["pkg-c"] + assert out == ["mockpkg-c"] out = split(pkg("changed", "--type", "ar", "HEAD^", "HEAD")) - assert out == ["pkg-c", "pkg-d"] + assert out == ["mockpkg-c", "mockpkg-d"] out = split(pkg("changed", "--type", "arc", "HEAD^", "HEAD")) - assert out == ["pkg-b", "pkg-c", "pkg-d"] + assert out == ["mockpkg-b", "mockpkg-c", "mockpkg-d"] # invalid type argument with pytest.raises(spack.main.SpackCommandError): @@ -289,7 +296,7 @@ def test_pkg_canonical_source(mock_packages): def test_pkg_hash(mock_packages): - output = pkg("hash", "a", "b").strip().split() + output = pkg("hash", "pkg-a", "pkg-b").strip().split() assert len(output) == 2 and all(len(elt) == 32 for elt in output) output = pkg("hash", "multimethod").strip().split() diff --git a/lib/spack/spack/test/cmd/providers.py b/lib/spack/spack/test/cmd/providers.py index e979f2db470f81..25d17ab9af3949 100644 --- a/lib/spack/spack/test/cmd/providers.py +++ b/lib/spack/spack/test/cmd/providers.py @@ -10,8 +10,6 @@ providers = SpackCommand("providers") -pytestmark = pytest.mark.not_on_windows("Providers not currently supported on Windows") - @pytest.mark.parametrize( "pkg", diff --git a/lib/spack/spack/test/cmd/reindex.py b/lib/spack/spack/test/cmd/reindex.py index f8c1d8b0e9eaee..1aceeab197c942 100644 --- a/lib/spack/spack/test/cmd/reindex.py +++ b/lib/spack/spack/test/cmd/reindex.py @@ -4,8 +4,6 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) import os -import pytest - import spack.store from spack.main import SpackCommand @@ -13,8 +11,6 @@ deprecate = SpackCommand("deprecate") reindex = SpackCommand("reindex") -pytestmark = pytest.mark.not_on_windows("does not run on windows") - def test_reindex_basic(mock_packages, mock_archive, mock_fetch, install_mockery): install("libelf@0.8.13") diff --git a/lib/spack/spack/test/cmd/spec.py b/lib/spack/spack/test/cmd/spec.py index 718a5e08d45afa..11d88dbc4c6707 100644 --- a/lib/spack/spack/test/cmd/spec.py +++ b/lib/spack/spack/test/cmd/spec.py @@ -14,7 +14,7 @@ import spack.store from spack.main import SpackCommand, SpackCommandError -pytestmark = pytest.mark.usefixtures("config", "mutable_mock_repo") +pytestmark = pytest.mark.usefixtures("mutable_config", "mutable_mock_repo") spec = SpackCommand("spec") @@ -31,7 +31,7 @@ def test_spec(): @pytest.mark.only_clingo("Known failure of the original concretizer") -def test_spec_concretizer_args(mutable_config, mutable_database): +def test_spec_concretizer_args(mutable_database, do_not_check_runtimes_on_reuse): """End-to-end test of CLI concretizer prefs. It's here to make sure that everything works from CLI @@ -58,7 +58,7 @@ def test_spec_concretizer_args(mutable_config, mutable_database): def test_spec_parse_dependency_variant_value(): """Verify that we can provide multiple key=value variants to multiple separate packages within a spec string.""" - output = spec("multivalue-variant fee=barbaz ^ a foobar=baz") + output = spec("multivalue-variant fee=barbaz ^ pkg-a foobar=baz") assert "fee=barbaz" in output assert "foobar=baz" in output @@ -97,7 +97,7 @@ def test_spec_json(): assert "mpich" in mpileaks -def test_spec_format(database, config): +def test_spec_format(mutable_database): output = spec("--format", "{name}-{^mpi.name}", "mpileaks^mpich") assert output.rstrip("\n") == "mpileaks-mpich" diff --git a/lib/spack/spack/test/cmd/stage.py b/lib/spack/spack/test/cmd/stage.py index cdca18d5e7b432..26e88e4280c38b 100644 --- a/lib/spack/spack/test/cmd/stage.py +++ b/lib/spack/spack/test/cmd/stage.py @@ -22,7 +22,6 @@ pytestmark = pytest.mark.usefixtures("install_mockery", "mock_packages") -@pytest.mark.not_on_windows("not implemented on windows") @pytest.mark.disable_clean_stage_check def test_stage_spec(monkeypatch): """Verify that staging specs works.""" @@ -63,7 +62,6 @@ def test_stage_path_errors_multiple_specs(check_stage_path): stage(f"--path={check_stage_path}", "trivial-install-test-package", "mpileaks") -@pytest.mark.not_on_windows("not implemented on windows") @pytest.mark.disable_clean_stage_check def test_stage_with_env_outside_env(mutable_mock_env_path, monkeypatch): """Verify that stage concretizes specs not in environment instead of erroring.""" @@ -82,7 +80,6 @@ def fake_stage(pkg, mirror_only=False): stage("trivial-install-test-package") -@pytest.mark.not_on_windows("not implemented on windows") @pytest.mark.disable_clean_stage_check def test_stage_with_env_inside_env(mutable_mock_env_path, monkeypatch): """Verify that stage filters specs in environment instead of reconcretizing.""" @@ -101,7 +98,6 @@ def fake_stage(pkg, mirror_only=False): stage("mpileaks") -@pytest.mark.not_on_windows("not implemented on windows") @pytest.mark.disable_clean_stage_check def test_stage_full_env(mutable_mock_env_path, monkeypatch): """Verify that stage filters specs in environment.""" diff --git a/lib/spack/spack/test/cmd/style.py b/lib/spack/spack/test/cmd/style.py index afdb3dbb1fe2e0..560518160444c4 100644 --- a/lib/spack/spack/test/cmd/style.py +++ b/lib/spack/spack/test/cmd/style.py @@ -38,7 +38,7 @@ def flake8_package(tmpdir): change to the ``flake8`` mock package, yields the filename, then undoes the change on cleanup. """ - repo = spack.repo.Repo(spack.paths.mock_packages_path) + repo = spack.repo.from_path(spack.paths.mock_packages_path) filename = repo.filename_for_package_name("flake8") rel_path = os.path.dirname(os.path.relpath(filename, spack.paths.prefix)) tmp = tmpdir / rel_path / "flake8-ci-package.py" @@ -54,7 +54,7 @@ def flake8_package(tmpdir): @pytest.fixture def flake8_package_with_errors(scope="function"): """A flake8 package with errors.""" - repo = spack.repo.Repo(spack.paths.mock_packages_path) + repo = spack.repo.from_path(spack.paths.mock_packages_path) filename = repo.filename_for_package_name("flake8") tmp = filename + ".tmp" @@ -130,7 +130,7 @@ def test_changed_files_all_files(): assert os.path.join(spack.paths.module_path, "spec.py") in files # a mock package - repo = spack.repo.Repo(spack.paths.mock_packages_path) + repo = spack.repo.from_path(spack.paths.mock_packages_path) filename = repo.filename_for_package_name("flake8") assert filename in files diff --git a/lib/spack/spack/test/cmd/test.py b/lib/spack/spack/test/cmd/test.py index 0dab4587394356..3cfaa5b58f28ba 100644 --- a/lib/spack/spack/test/cmd/test.py +++ b/lib/spack/spack/test/cmd/test.py @@ -10,10 +10,14 @@ from llnl.util.filesystem import copy_tree +import spack.cmd.common.arguments import spack.cmd.install +import spack.cmd.test import spack.config +import spack.install_test import spack.package_base import spack.paths +import spack.spec import spack.store from spack.install_test import TestStatus from spack.main import SpackCommand @@ -25,13 +29,7 @@ def test_test_package_not_installed( - tmpdir, - mock_packages, - mock_archive, - mock_fetch, - config, - install_mockery_mutable_config, - mock_test_stage, + tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery, mock_test_stage ): output = spack_test("run", "libdwarf") @@ -54,7 +52,7 @@ def test_test_dirty_flag(arguments, expected): def test_test_dup_alias( - mock_test_stage, mock_packages, mock_archive, mock_fetch, install_mockery_mutable_config, capfd + mock_test_stage, mock_packages, mock_archive, mock_fetch, install_mockery, capfd ): """Ensure re-using an alias fails with suggestion to change.""" install("libdwarf") @@ -69,9 +67,7 @@ def test_test_dup_alias( assert "already exists" in out and "Try another alias" in out -def test_test_output( - mock_test_stage, mock_packages, mock_archive, mock_fetch, install_mockery_mutable_config -): +def test_test_output(mock_test_stage, mock_packages, mock_archive, mock_fetch, install_mockery): """Ensure output printed from pkgs is captured by output redirection.""" install("printing-package") spack_test("run", "--alias", "printpkg", "printing-package") @@ -97,13 +93,7 @@ def test_test_output( "pkg_name,failure", [("test-error", "exited with status 1"), ("test-fail", "not callable")] ) def test_test_output_fails( - mock_packages, - mock_archive, - mock_fetch, - install_mockery_mutable_config, - mock_test_stage, - pkg_name, - failure, + mock_packages, mock_archive, mock_fetch, install_mockery, mock_test_stage, pkg_name, failure ): """Confirm stand-alone test failure with expected outputs.""" install(pkg_name) @@ -117,9 +107,7 @@ def test_test_output_fails( assert "See test log for details" in out -@pytest.mark.usefixtures( - "mock_packages", "mock_archive", "mock_fetch", "install_mockery_mutable_config" -) +@pytest.mark.usefixtures("mock_packages", "mock_archive", "mock_fetch", "install_mockery") @pytest.mark.parametrize( "pkg_name,msgs", [ @@ -153,13 +141,7 @@ def test_junit_output_with_failures(tmpdir, mock_test_stage, pkg_name, msgs): def test_cdash_output_test_error( - tmpdir, - mock_fetch, - install_mockery_mutable_config, - mock_packages, - mock_archive, - mock_test_stage, - capfd, + tmpdir, mock_fetch, install_mockery, mock_packages, mock_archive, mock_test_stage, capfd ): """Confirm stand-alone test error expected outputs in CDash reporting.""" install("test-error") @@ -179,12 +161,7 @@ def test_cdash_output_test_error( def test_cdash_upload_clean_test( - tmpdir, - mock_fetch, - install_mockery_mutable_config, - mock_packages, - mock_archive, - mock_test_stage, + tmpdir, mock_fetch, install_mockery, mock_packages, mock_archive, mock_test_stage ): install("printing-package") with tmpdir.as_cwd(): @@ -233,7 +210,7 @@ def test_test_list_all(mock_packages): ) -def test_test_list(mock_packages, mock_archive, mock_fetch, install_mockery_mutable_config): +def test_test_list(mock_packages, mock_archive, mock_fetch, install_mockery): pkg_with_tests = "printing-package" install(pkg_with_tests) output = spack_test("list") @@ -299,7 +276,7 @@ def test_test_results_status(mock_packages, mock_test_stage, status): @pytest.mark.regression("35337") -def test_report_filename_for_cdash(install_mockery_mutable_config, mock_fetch): +def test_report_filename_for_cdash(install_mockery, mock_fetch): """Test that the temporary file used to write Testing.xml for CDash is not the upload URL""" name = "trivial" spec = spack.spec.Spec("trivial-smoke-test").concretized() @@ -322,7 +299,7 @@ def test_report_filename_for_cdash(install_mockery_mutable_config, mock_fetch): def test_test_output_multiple_specs( - mock_test_stage, mock_packages, mock_archive, mock_fetch, install_mockery_mutable_config + mock_test_stage, mock_packages, mock_archive, mock_fetch, install_mockery ): """Ensure proper reporting for suite with skipped, failing, and passed tests.""" install("test-error", "simple-standalone-test@0.9", "simple-standalone-test@1.0") diff --git a/lib/spack/spack/test/cmd/uninstall.py b/lib/spack/spack/test/cmd/uninstall.py index f3eca94d6501c6..78a5f10d5e62ac 100644 --- a/lib/spack/spack/test/cmd/uninstall.py +++ b/lib/spack/spack/test/cmd/uninstall.py @@ -222,7 +222,7 @@ class TestUninstallFromEnv: @pytest.fixture(scope="function") def environment_setup( - self, mutable_mock_env_path, config, mock_packages, mutable_database, install_mockery + self, mutable_mock_env_path, mock_packages, mutable_database, install_mockery ): TestUninstallFromEnv.env("create", "e1") e1 = spack.environment.read("e1") diff --git a/lib/spack/spack/test/cmd/url.py b/lib/spack/spack/test/cmd/url.py index cea7b34a948da5..e29253299aa336 100644 --- a/lib/spack/spack/test/cmd/url.py +++ b/lib/spack/spack/test/cmd/url.py @@ -3,7 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) import re -import sys import pytest @@ -117,7 +116,6 @@ def test_url_summary(mock_packages): assert out_correct_versions == correct_versions -@pytest.mark.skipif(sys.platform.startswith("win"), reason="Unsupported on Windows for now") def test_url_stats(capfd, mock_packages): with capfd.disabled(): output = url("stats") diff --git a/lib/spack/spack/test/cmd/verify.py b/lib/spack/spack/test/cmd/verify.py index 0ac3c136c0b8db..53b57cd7902b31 100644 --- a/lib/spack/spack/test/cmd/verify.py +++ b/lib/spack/spack/test/cmd/verify.py @@ -63,9 +63,7 @@ def test_single_file_verify_cmd(tmpdir): assert sorted(errors) == sorted(expected) -def test_single_spec_verify_cmd( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery -): +def test_single_spec_verify_cmd(tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery): # Test the verify command interface to verify a single spec install("libelf") s = spack.spec.Spec("libelf").concretized() diff --git a/lib/spack/spack/test/cmd/view.py b/lib/spack/spack/test/cmd/view.py index 530b998a42e3c7..f385a69e8512c1 100644 --- a/lib/spack/spack/test/cmd/view.py +++ b/lib/spack/spack/test/cmd/view.py @@ -28,9 +28,7 @@ def create_projection_file(tmpdir, projection): @pytest.mark.parametrize("cmd", ["hardlink", "symlink", "hard", "add", "copy", "relocate"]) -def test_view_link_type( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery, cmd -): +def test_view_link_type(tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery, cmd): install("libdwarf") viewpath = str(tmpdir.mkdir("view_{0}".format(cmd))) view(cmd, viewpath, "libdwarf") @@ -44,7 +42,7 @@ def test_view_link_type( @pytest.mark.parametrize("add_cmd", ["hardlink", "symlink", "hard", "add", "copy", "relocate"]) def test_view_link_type_remove( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery, add_cmd + tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery, add_cmd ): install("needs-relocation") viewpath = str(tmpdir.mkdir("view_{0}".format(add_cmd))) @@ -57,9 +55,7 @@ def test_view_link_type_remove( @pytest.mark.parametrize("cmd", ["hardlink", "symlink", "hard", "add", "copy", "relocate"]) -def test_view_projections( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery, cmd -): +def test_view_projections(tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery, cmd): install("libdwarf@20130207") viewpath = str(tmpdir.mkdir("view_{0}".format(cmd))) @@ -76,7 +72,7 @@ def test_view_projections( def test_view_multiple_projections( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery + tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery ): install("libdwarf@20130207") install("extendee@1.0%gcc") @@ -96,7 +92,7 @@ def test_view_multiple_projections( def test_view_multiple_projections_all_first( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery + tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery ): install("libdwarf@20130207") install("extendee@1.0%gcc") @@ -115,14 +111,14 @@ def test_view_multiple_projections_all_first( assert os.path.exists(extendee_prefix) -def test_view_external(tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery): +def test_view_external(tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery): install("externaltool") viewpath = str(tmpdir.mkdir("view")) output = view("symlink", viewpath, "externaltool") assert "Skipping external package: externaltool" in output -def test_view_extension(tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery): +def test_view_extension(tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery): install("extendee") install("extension1@1.0") install("extension1@2.0") @@ -136,9 +132,7 @@ def test_view_extension(tmpdir, mock_packages, mock_archive, mock_fetch, config, assert os.path.exists(os.path.join(viewpath, "bin", "extension1")) -def test_view_extension_remove( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery -): +def test_view_extension_remove(tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery): install("extendee") install("extension1@1.0") viewpath = str(tmpdir.mkdir("view")) @@ -149,9 +143,7 @@ def test_view_extension_remove( assert not os.path.exists(os.path.join(viewpath, "bin", "extension1")) -def test_view_extension_conflict( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery -): +def test_view_extension_conflict(tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery): install("extendee") install("extension1@1.0") install("extension1@2.0") @@ -162,7 +154,7 @@ def test_view_extension_conflict( def test_view_extension_conflict_ignored( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery + tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery ): install("extendee") install("extension1@1.0") @@ -184,7 +176,7 @@ def test_view_fails_with_missing_projections_file(tmpdir): @pytest.mark.parametrize("with_projection", [False, True]) @pytest.mark.parametrize("cmd", ["symlink", "copy"]) def test_view_files_not_ignored( - tmpdir, mock_packages, mock_archive, mock_fetch, config, install_mockery, cmd, with_projection + tmpdir, mock_packages, mock_archive, mock_fetch, install_mockery, cmd, with_projection ): spec = Spec("view-not-ignored").concretized() pkg = spec.package diff --git a/lib/spack/spack/test/compilers/basics.py b/lib/spack/spack/test/compilers/basics.py index 60cef60d724c91..0884f9b1a4e051 100644 --- a/lib/spack/spack/test/compilers/basics.py +++ b/lib/spack/spack/test/compilers/basics.py @@ -14,6 +14,7 @@ import spack.compilers import spack.spec import spack.util.environment +import spack.util.module_cmd from spack.compiler import Compiler from spack.util.executable import Executable, ProcessError @@ -62,10 +63,16 @@ def test_multiple_conflicting_compiler_definitions(mutable_config): assert cmp.f77 == "f77" -def test_get_compiler_duplicates(config): +def test_get_compiler_duplicates(mutable_config, compiler_factory): # In this case there is only one instance of the specified compiler in # the test configuration (so it is not actually a duplicate), but the # method behaves the same. + cnl_compiler = compiler_factory(spec="gcc@4.5.0", operating_system="CNL") + # CNL compiler has no target attribute, and this is essential to make detection pass + del cnl_compiler["compiler"]["target"] + mutable_config.set( + "compilers", [compiler_factory(spec="gcc@4.5.0", operating_system="SuSE11"), cnl_compiler] + ) cfg_file_to_duplicates = spack.compilers.get_compiler_duplicates( "gcc@4.5.0", spack.spec.ArchSpec("cray-CNL-xeon") ) @@ -75,13 +82,6 @@ def test_get_compiler_duplicates(config): assert len(duplicates) == 1 -def test_all_compilers(config): - all_compilers = spack.compilers.all_compilers() - filtered = [x for x in all_compilers if str(x.spec) == "clang@=3.3"] - filtered = [x for x in filtered if x.operating_system == "SuSE11"] - assert len(filtered) == 1 - - @pytest.mark.parametrize( "input_version,expected_version,expected_error", [(None, None, "Couldn't get version for compiler /usr/bin/gcc"), ("4.9", "4.9", None)], @@ -138,14 +138,6 @@ def __init__(self): environment={}, ) - def _get_compiler_link_paths(self): - # Mock os.path.isdir so the link paths don't have to exist - old_isdir = os.path.isdir - os.path.isdir = lambda x: True - ret = super()._get_compiler_link_paths() - os.path.isdir = old_isdir - return ret - @property def name(self): return "mockcompiler" @@ -163,34 +155,25 @@ def verbose_flag(self): required_libs = ["libgfortran"] -def test_implicit_rpaths(dirs_with_libfiles, monkeypatch): +@pytest.mark.not_on_windows("Not supported on Windows (yet)") +def test_implicit_rpaths(dirs_with_libfiles): lib_to_dirs, all_dirs = dirs_with_libfiles - - def try_all_dirs(*args): - return all_dirs - - monkeypatch.setattr(MockCompiler, "_get_compiler_link_paths", try_all_dirs) - - expected_rpaths = set(lib_to_dirs["libstdc++"] + lib_to_dirs["libgfortran"]) - compiler = MockCompiler() + compiler._compile_c_source_output = "ld " + " ".join(f"-L{d}" for d in all_dirs) retrieved_rpaths = compiler.implicit_rpaths() - assert set(retrieved_rpaths) == expected_rpaths - + assert set(retrieved_rpaths) == set(lib_to_dirs["libstdc++"] + lib_to_dirs["libgfortran"]) -no_flag_dirs = ["/path/to/first/lib", "/path/to/second/lib64"] -no_flag_output = "ld -L%s -L%s" % tuple(no_flag_dirs) -flag_dirs = ["/path/to/first/with/flag/lib", "/path/to/second/lib64"] -flag_output = "ld -L%s -L%s" % tuple(flag_dirs) +without_flag_output = "ld -L/path/to/first/lib -L/path/to/second/lib64" +with_flag_output = "ld -L/path/to/first/with/flag/lib -L/path/to/second/lib64" def call_compiler(exe, *args, **kwargs): # This method can replace Executable.__call__ to emulate a compiler that # changes libraries depending on a flag. if "--correct-flag" in exe.exe: - return flag_output - return no_flag_output + return with_flag_output + return without_flag_output @pytest.mark.not_on_windows("Not supported on Windows (yet)") @@ -204,8 +187,8 @@ def call_compiler(exe, *args, **kwargs): ("cc", "cppflags"), ], ) -@pytest.mark.enable_compiler_link_paths -def test_get_compiler_link_paths(monkeypatch, exe, flagname): +@pytest.mark.enable_compiler_execution +def test_compile_dummy_c_source_adds_flags(monkeypatch, exe, flagname): # create fake compiler that emits mock verbose output compiler = MockCompiler() monkeypatch.setattr(Executable, "__call__", call_compiler) @@ -222,40 +205,38 @@ def test_get_compiler_link_paths(monkeypatch, exe, flagname): assert False # Test without flags - assert compiler._get_compiler_link_paths() == no_flag_dirs + assert compiler._compile_dummy_c_source() == without_flag_output if flagname: # set flags and test compiler.flags = {flagname: ["--correct-flag"]} - assert compiler._get_compiler_link_paths() == flag_dirs + assert compiler._compile_dummy_c_source() == with_flag_output -def test_get_compiler_link_paths_no_path(): +@pytest.mark.enable_compiler_execution +def test_compile_dummy_c_source_no_path(): compiler = MockCompiler() compiler.cc = None compiler.cxx = None - compiler.f77 = None - compiler.fc = None - assert compiler._get_compiler_link_paths() == [] + assert compiler._compile_dummy_c_source() is None -def test_get_compiler_link_paths_no_verbose_flag(): +@pytest.mark.enable_compiler_execution +def test_compile_dummy_c_source_no_verbose_flag(): compiler = MockCompiler() compiler._verbose_flag = None - assert compiler._get_compiler_link_paths() == [] + assert compiler._compile_dummy_c_source() is None @pytest.mark.not_on_windows("Not supported on Windows (yet)") -@pytest.mark.enable_compiler_link_paths -def test_get_compiler_link_paths_load_env(working_env, monkeypatch, tmpdir): +@pytest.mark.enable_compiler_execution +def test_compile_dummy_c_source_load_env(working_env, monkeypatch, tmpdir): gcc = str(tmpdir.join("gcc")) with open(gcc, "w") as f: f.write( - """#!/bin/sh + f"""#!/bin/sh if [ "$ENV_SET" = "1" ] && [ "$MODULE_LOADED" = "1" ]; then - echo '""" - + no_flag_output - + """' + printf '{without_flag_output}' fi """ ) @@ -275,7 +256,7 @@ def module(*args): compiler.environment = {"set": {"ENV_SET": "1"}} compiler.modules = ["turn_on"] - assert compiler._get_compiler_link_paths() == no_flag_dirs + assert compiler._compile_dummy_c_source() == without_flag_output # Get the desired flag from the specified compiler spec. @@ -403,9 +384,18 @@ def test_clang_flags(): unsupported_flag_test("cxx17_flag", "clang@3.4") supported_flag_test("cxx17_flag", "-std=c++1z", "clang@3.5") supported_flag_test("cxx17_flag", "-std=c++17", "clang@5.0") + unsupported_flag_test("cxx20_flag", "clang@4.0") + supported_flag_test("cxx20_flag", "-std=c++2a", "clang@5.0") + supported_flag_test("cxx20_flag", "-std=c++20", "clang@11.0") + unsupported_flag_test("cxx23_flag", "clang@11.0") + supported_flag_test("cxx23_flag", "-std=c++2b", "clang@12.0") + supported_flag_test("cxx23_flag", "-std=c++23", "clang@17.0") supported_flag_test("c99_flag", "-std=c99", "clang@3.3") unsupported_flag_test("c11_flag", "clang@2.0") supported_flag_test("c11_flag", "-std=c11", "clang@6.1.0") + unsupported_flag_test("c23_flag", "clang@8.0") + supported_flag_test("c23_flag", "-std=c2x", "clang@9.0") + supported_flag_test("c23_flag", "-std=c23", "clang@18.0") supported_flag_test("cc_pic_flag", "-fPIC", "clang@3.3") supported_flag_test("cxx_pic_flag", "-fPIC", "clang@3.3") supported_flag_test("f77_pic_flag", "-fPIC", "clang@3.3") @@ -654,7 +644,25 @@ def test_xl_r_flags(): "compiler_spec,expected_result", [("gcc@4.7.2", False), ("clang@3.3", False), ("clang@8.0.0", True)], ) -def test_detecting_mixed_toolchains(compiler_spec, expected_result, config): +def test_detecting_mixed_toolchains( + compiler_spec, expected_result, mutable_config, compiler_factory +): + mixed_c = compiler_factory(spec="clang@8.0.0", operating_system="debian6") + mixed_c["compiler"]["paths"] = { + "cc": "/path/to/clang-8", + "cxx": "/path/to/clang++-8", + "f77": "/path/to/gfortran-9", + "fc": "/path/to/gfortran-9", + } + mutable_config.set( + "compilers", + [ + compiler_factory(spec="gcc@4.7.2", operating_system="debian6"), + compiler_factory(spec="clang@3.3", operating_system="debian6"), + mixed_c, + ], + ) + compiler = spack.compilers.compilers_for_spec(compiler_spec).pop() assert spack.compilers.is_mixed_toolchain(compiler) is expected_result @@ -683,7 +691,7 @@ def test_raising_if_compiler_target_is_over_specific(config): ] arch_spec = spack.spec.ArchSpec(("linux", "ubuntu18.04", "haswell")) with spack.config.override("compilers", compilers): - cfg = spack.compilers.get_compiler_config() + cfg = spack.compilers.get_compiler_config(config) with pytest.raises(ValueError): spack.compilers.get_compilers(cfg, spack.spec.CompilerSpec("gcc@9.0.1"), arch_spec) @@ -895,3 +903,66 @@ def prepare_executable(name): # Test that null entries don't fail compiler.cc = None compiler.verify_executables() + + +@pytest.mark.parametrize( + "detected_versions,expected_length", + [ + # If we detect a C compiler we expect the result to be valid + ( + [ + spack.compilers.DetectVersionArgs( + id=spack.compilers.CompilerID( + os="ubuntu20.04", compiler_name="clang", version="12.0.0" + ), + variation=spack.compilers.NameVariation(prefix="", suffix="-12"), + language="cc", + path="/usr/bin/clang-12", + ), + spack.compilers.DetectVersionArgs( + id=spack.compilers.CompilerID( + os="ubuntu20.04", compiler_name="clang", version="12.0.0" + ), + variation=spack.compilers.NameVariation(prefix="", suffix="-12"), + language="cxx", + path="/usr/bin/clang++-12", + ), + ], + 1, + ), + # If we detect only a C++ compiler we expect the result to be discarded + ( + [ + spack.compilers.DetectVersionArgs( + id=spack.compilers.CompilerID( + os="ubuntu20.04", compiler_name="clang", version="12.0.0" + ), + variation=spack.compilers.NameVariation(prefix="", suffix="-12"), + language="cxx", + path="/usr/bin/clang++-12", + ) + ], + 0, + ), + ], +) +def test_detection_requires_c_compiler(detected_versions, expected_length): + """Tests that compilers automatically added to the configuration have + at least a C compiler. + """ + result = spack.compilers.make_compiler_list(detected_versions) + assert len(result) == expected_length + + +def test_compiler_environment(working_env): + """Test whether environment modifications from compilers are applied in compiler_environment""" + os.environ.pop("TEST", None) + compiler = Compiler( + "gcc@=13.2.0", + operating_system="ubuntu20.04", + target="x86_64", + paths=["/test/bin/gcc", "/test/bin/g++"], + environment={"set": {"TEST": "yes"}}, + ) + with compiler.compiler_environment(): + assert os.environ["TEST"] == "yes" diff --git a/lib/spack/spack/test/compilers/detection.py b/lib/spack/spack/test/compilers/detection.py index 07b5269fb7eb58..4103b209855436 100644 --- a/lib/spack/spack/test/compilers/detection.py +++ b/lib/spack/spack/test/compilers/detection.py @@ -3,12 +3,8 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) """Test detection of compiler version""" -import os - import pytest -import llnl.util.filesystem as fs - import spack.compilers.aocc import spack.compilers.arm import spack.compilers.cce @@ -23,7 +19,6 @@ import spack.compilers.xl import spack.compilers.xl_r import spack.util.module_cmd -from spack.operating_systems.cray_frontend import CrayFrontend @pytest.mark.parametrize( @@ -413,48 +408,6 @@ def test_xl_version_detection(version_str, expected_version): assert version == expected_version -@pytest.mark.not_on_windows("Not supported on Windows (yet)") -@pytest.mark.parametrize( - "compiler,version", - [ - ("gcc", "8.1.0"), - ("gcc", "1.0.0-foo"), - ("pgi", "19.1"), - ("pgi", "19.1a"), - ("intel", "9.0.0"), - ("intel", "0.0.0-foobar"), - # ('oneapi', '2021.1'), - # ('oneapi', '2021.1-foobar') - ], -) -def test_cray_frontend_compiler_detection(compiler, version, tmpdir, monkeypatch, working_env): - """Test that the Cray frontend properly finds compilers form modules""" - # setup the fake compiler directory - compiler_dir = tmpdir.join(compiler) - compiler_exe = compiler_dir.join("cc").ensure() - fs.set_executable(str(compiler_exe)) - - # mock modules - def _module(cmd, *args): - module_name = "%s/%s" % (compiler, version) - module_contents = "prepend-path PATH %s" % compiler_dir - if cmd == "avail": - return module_name if compiler in args[0] else "" - if cmd == "show": - return module_contents if module_name in args else "" - - monkeypatch.setattr(spack.operating_systems.cray_frontend, "module", _module) - - # remove PATH variable - os.environ.pop("PATH", None) - - # get a CrayFrontend object - cray_fe_os = CrayFrontend() - - paths = cray_fe_os.compiler_search_paths - assert paths == [str(compiler_dir)] - - @pytest.mark.parametrize( "version_str,expected_version", [ diff --git a/lib/spack/spack/test/concretize.py b/lib/spack/spack/test/concretize.py index 0e5278577a4630..1b009d4897537e 100644 --- a/lib/spack/spack/test/concretize.py +++ b/lib/spack/spack/test/concretize.py @@ -13,6 +13,7 @@ import llnl.util.lang +import spack.compiler import spack.compilers import spack.concretize import spack.config @@ -23,11 +24,14 @@ import spack.platforms import spack.repo import spack.solver.asp +import spack.store +import spack.util.file_cache +import spack.util.libc import spack.variant as vt from spack.concretize import find_spec from spack.main import SpackCommand from spack.spec import CompilerSpec, Spec -from spack.version import Version, ver +from spack.version import Version, VersionList, ver def check_spec(abstract, concrete): @@ -68,6 +72,24 @@ def check_concretize(abstract_spec): return concrete +@pytest.fixture(scope="function", autouse=True) +def binary_compatibility(monkeypatch, request): + """Selects whether we use OS compatibility for binaries, or libc compatibility.""" + if spack.platforms.real_host().name != "linux": + return + + if "mock_packages" not in request.fixturenames: + # Only builtin.mock has a mock glibc package + return + + if "database" in request.fixturenames or "mutable_database" in request.fixturenames: + # Databases have been created without glibc support + return + + monkeypatch.setattr(spack.solver.asp, "using_libc_compatibility", lambda: True) + monkeypatch.setattr(spack.compiler.Compiler, "default_libc", Spec("glibc@=2.28")) + + @pytest.fixture( params=[ # no_deps @@ -121,14 +143,16 @@ def current_host(request, monkeypatch): # is_preference is not empty if we want to supply the # preferred target via packages.yaml cpu, _, is_preference = request.param.partition("-") - target = archspec.cpu.TARGETS[cpu] monkeypatch.setattr(spack.platforms.Test, "default", cpu) monkeypatch.setattr(spack.platforms.Test, "front_end", cpu) if not is_preference: + target = archspec.cpu.TARGETS[cpu] monkeypatch.setattr(archspec.cpu, "host", lambda: target) yield target else: + target = archspec.cpu.TARGETS["sapphirerapids"] + monkeypatch.setattr(archspec.cpu, "host", lambda: target) with spack.config.override("packages:all", {"target": [cpu]}): yield target @@ -147,19 +171,18 @@ def reverser(pkg_name): @pytest.fixture() -def repo_with_changing_recipe(tmpdir_factory, mutable_mock_repo): +def repo_with_changing_recipe(tmp_path_factory, mutable_mock_repo): repo_namespace = "changing" - repo_dir = tmpdir_factory.mktemp(repo_namespace) + repo_dir = tmp_path_factory.mktemp(repo_namespace) - repo_dir.join("repo.yaml").write( + (repo_dir / "repo.yaml").write_text( """ repo: namespace: changing -""", - ensure=True, +""" ) - packages_dir = repo_dir.ensure("packages", dir=True) + packages_dir = repo_dir / "packages" root_pkg_str = """ class Root(Package): homepage = "http://www.example.com" @@ -170,7 +193,9 @@ class Root(Package): conflicts("^changing~foo") """ - packages_dir.join("root", "package.py").write(root_pkg_str, ensure=True) + package_py = packages_dir / "root" / "package.py" + package_py.parent.mkdir(parents=True) + package_py.write_text(root_pkg_str) changing_template = """ class Changing(Package): @@ -204,7 +229,9 @@ class _ChangingPackage: def __init__(self, repo_directory): self.repo_dir = repo_directory - self.repo = spack.repo.Repo(str(repo_directory)) + cache_dir = tmp_path_factory.mktemp("cache") + self.repo_cache = spack.util.file_cache.FileCache(str(cache_dir)) + self.repo = spack.repo.Repo(str(repo_directory), cache=self.repo_cache) def change(self, changes=None): changes = changes or {} @@ -225,10 +252,12 @@ def change(self, changes=None): # Change the recipe t = jinja2.Template(changing_template) changing_pkg_str = t.render(**context) - packages_dir.join("changing", "package.py").write(changing_pkg_str, ensure=True) + package_py = packages_dir / "changing" / "package.py" + package_py.parent.mkdir(parents=True, exist_ok=True) + package_py.write_text(changing_pkg_str) # Re-add the repository - self.repo = spack.repo.Repo(str(self.repo_dir)) + self.repo = spack.repo.Repo(str(self.repo_dir), cache=self.repo_cache) repository.put_first(self.repo) _changing_pkg = _ChangingPackage(repo_dir) @@ -238,10 +267,24 @@ def change(self, changes=None): yield _changing_pkg +@pytest.fixture() +def clang12_with_flags(compiler_factory): + c = compiler_factory(spec="clang@12.2.0", operating_system="redhat6") + c["compiler"]["flags"] = {"cflags": "-O3", "cxxflags": "-O3"} + return c + + +@pytest.fixture() +def gcc11_with_flags(compiler_factory): + c = compiler_factory(spec="gcc@11.1.0", operating_system="redhat6") + c["compiler"]["flags"] = {"cflags": "-O0 -g", "cxxflags": "-O0 -g", "fflags": "-O0 -g"} + return c + + # This must use the mutable_config fixture because the test # adjusting_default_target_based_on_compiler uses the current_host fixture, # which changes the config. -@pytest.mark.usefixtures("mutable_config", "mock_packages") +@pytest.mark.usefixtures("mutable_config", "mock_packages", "do_not_check_runtimes_on_reuse") class TestConcretize: def test_concretize(self, spec): check_concretize(spec) @@ -330,18 +373,34 @@ def test_provides_handles_multiple_providers_of_same_version(self): assert Spec("builtin.mock.multi-provider-mpi@1.10.0") in providers assert Spec("builtin.mock.multi-provider-mpi@1.8.8") in providers - def test_different_compilers_get_different_flags(self): + def test_different_compilers_get_different_flags( + self, mutable_config, clang12_with_flags, gcc11_with_flags + ): + """Tests that nodes get the flags of the associated compiler.""" + mutable_config.set("compilers", [clang12_with_flags, gcc11_with_flags]) client = Spec( "cmake-client %gcc@11.1.0 platform=test os=fe target=fe" - + " ^cmake %clang@12.2.0 platform=test os=fe target=fe" - ) - client.concretize() + " ^cmake %clang@12.2.0 platform=test os=fe target=fe" + ).concretized() cmake = client["cmake"] - assert set(client.compiler_flags["cflags"]) == set(["-O0", "-g"]) - assert set(cmake.compiler_flags["cflags"]) == set(["-O3"]) - assert set(client.compiler_flags["fflags"]) == set(["-O0", "-g"]) + assert set(client.compiler_flags["cflags"]) == {"-O0", "-g"} + assert set(cmake.compiler_flags["cflags"]) == {"-O3"} + assert set(client.compiler_flags["fflags"]) == {"-O0", "-g"} assert not set(cmake.compiler_flags["fflags"]) + @pytest.mark.regression("9908") + def test_spec_flags_maintain_order(self, mutable_config, gcc11_with_flags): + """Tests that Spack assembles flags in a consistent way (i.e. with the same ordering), + for successive concretizations. + """ + mutable_config.set("compilers", [gcc11_with_flags]) + spec_str = "libelf %gcc@11.1.0 os=redhat6" + for _ in range(3): + s = Spec(spec_str).concretized() + assert all( + s.compiler_flags[x] == ["-O0", "-g"] for x in ("cflags", "cxxflags", "fflags") + ) + @pytest.mark.xfail(reason="Broken, needs to be fixed") def test_compiler_flags_from_compiler_and_dependent(self): client = Spec("cmake-client %clang@12.2.0 platform=test os=fe target=fe cflags==-g") @@ -350,9 +409,10 @@ def test_compiler_flags_from_compiler_and_dependent(self): for spec in [client, cmake]: assert spec.compiler_flags["cflags"] == ["-O3", "-g"] - def test_compiler_flags_differ_identical_compilers(self): + def test_compiler_flags_differ_identical_compilers(self, mutable_config, clang12_with_flags): + mutable_config.set("compilers", [clang12_with_flags]) # Correct arch to use test compiler that has flags - spec = Spec("a %clang@12.2.0 platform=test os=fe target=fe") + spec = Spec("pkg-a %clang@12.2.0 platform=test os=fe target=fe") # Get the compiler that matches the spec ( compiler = spack.compilers.compiler_for_spec("clang@=12.2.0", spec.architecture) @@ -369,30 +429,38 @@ def test_compiler_flags_differ_identical_compilers(self): @pytest.mark.only_clingo( "Optional compiler propagation isn't deprecated for original concretizer" ) - def test_concretize_compiler_flag_propagate(self): - spec = Spec("hypre cflags=='-g' ^openblas") - spec.concretize() - - assert spec.satisfies("^openblas cflags='-g'") - - @pytest.mark.only_clingo( - "Optional compiler propagation isn't deprecated for original concretizer" + @pytest.mark.parametrize( + "spec_str,expected,not_expected", + [ + # Simple flag propagation from the root + ("hypre cflags=='-g' ^openblas", ["hypre cflags='-g'", "^openblas cflags='-g'"], []), + ( + "hypre cflags='-g' ^openblas", + ["hypre cflags='-g'", "^openblas"], + ["^openblas cflags='-g'"], + ), + # Setting a flag overrides propagation + ( + "hypre cflags=='-g' ^openblas cflags='-O3'", + ["hypre cflags='-g'", "^openblas cflags='-O3'"], + ["^openblas cflags='-g'"], + ), + # Propagation doesn't go across build dependencies + ( + "cmake-client cflags=='-O2 -g'", + ["cmake-client cflags=='-O2 -g'", "^cmake"], + ["cmake cflags=='-O2 -g'"], + ), + ], ) - def test_concretize_compiler_flag_does_not_propagate(self): - spec = Spec("hypre cflags='-g' ^openblas") - spec.concretize() - - assert not spec.satisfies("^openblas cflags='-g'") + def test_compiler_flag_propagation(self, spec_str, expected, not_expected): + root = Spec(spec_str).concretized() - @pytest.mark.only_clingo( - "Optional compiler propagation isn't deprecated for original concretizer" - ) - def test_concretize_propagate_compiler_flag_not_passed_to_dependent(self): - spec = Spec("hypre cflags=='-g' ^openblas cflags='-O3'") - spec.concretize() + for constraint in expected: + assert root.satisfies(constraint) - assert set(spec.compiler_flags["cflags"]) == set(["-g"]) - assert spec.satisfies("^openblas cflags='-O3'") + for constraint in not_expected: + assert not root.satisfies(constraint) def test_mixing_compilers_only_affects_subdag(self): spack.config.set("packages:all:compiler", ["clang", "gcc"]) @@ -405,28 +473,23 @@ def test_compiler_inherited_upwards(self): for dep in spec.traverse(): assert "%clang" in dep - def test_architecture_inheritance(self): - """test_architecture_inheritance is likely to fail with an - UnavailableCompilerVersionError if the architecture is concretized - incorrectly. - """ - spec = Spec("cmake-client %gcc@11.1.0 os=fe ^ cmake") - spec.concretize() - assert spec["cmake"].architecture == spec.architecture - @pytest.mark.only_clingo("Fixing the parser broke this test for the original concretizer") - def test_architecture_deep_inheritance(self, mock_targets): + def test_architecture_deep_inheritance(self, mock_targets, compiler_factory): """Make sure that indirect dependencies receive architecture information from the root even when partial architecture information is provided by an intermediate dependency. """ - spec_str = "mpileaks %gcc@4.5.0 os=CNL target=nocona" " ^dyninst os=CNL ^callpath os=CNL" - spec = Spec(spec_str).concretized() - for s in spec.traverse(root=False): - assert s.architecture.target == spec.architecture.target + cnl_compiler = compiler_factory(spec="gcc@4.5.0", operating_system="CNL") + # CNL compiler has no target attribute, and this is essential to make detection pass + del cnl_compiler["compiler"]["target"] + with spack.config.override("compilers", [cnl_compiler]): + spec_str = "mpileaks %gcc@4.5.0 os=CNL target=nocona ^dyninst os=CNL ^callpath os=CNL" + spec = Spec(spec_str).concretized() + for s in spec.traverse(root=False): + assert s.architecture.target == spec.architecture.target def test_compiler_flags_from_user_are_grouped(self): - spec = Spec('a%gcc cflags="-O -foo-flag foo-val" platform=test') + spec = Spec('pkg-a%gcc cflags="-O -foo-flag foo-val" platform=test') spec.concretize() cflags = spec.compiler_flags["cflags"] assert any(x == "-foo-flag foo-val" for x in cflags) @@ -534,10 +597,10 @@ def test_concretize_propagate_multivalue_variant(self): spec = Spec("multivalue-variant foo==baz,fee") spec.concretize() - assert spec.satisfies("^a foo=baz,fee") - assert spec.satisfies("^b foo=baz,fee") - assert not spec.satisfies("^a foo=bar") - assert not spec.satisfies("^b foo=bar") + assert spec.satisfies("^pkg-a foo=baz,fee") + assert spec.satisfies("^pkg-b foo=baz,fee") + assert not spec.satisfies("^pkg-a foo=bar") + assert not spec.satisfies("^pkg-b foo=bar") @pytest.mark.only_clingo( "Optional compiler propagation isn't deprecated for original concretizer" @@ -555,12 +618,12 @@ def test_concretize_propagate_specified_variant(self): def test_no_matching_compiler_specs(self, mock_low_high_config): # only relevant when not building compilers as needed with spack.concretize.enable_compiler_existence_check(): - s = Spec("a %gcc@=0.0.0") + s = Spec("pkg-a %gcc@=0.0.0") with pytest.raises(spack.concretize.UnavailableCompilerVersionError): s.concretize() def test_no_compilers_for_arch(self): - s = Spec("a arch=linux-rhel0-x86_64") + s = Spec("pkg-a arch=linux-rhel0-x86_64") with pytest.raises(spack.error.SpackError): s.concretize() @@ -602,7 +665,7 @@ def test_my_dep_depends_on_provider_of_my_virtual_dep(self): spec.normalize() spec.concretize() - @pytest.mark.parametrize("compiler_str", ["clang", "gcc", "gcc@10.2.1", "clang@:12.0.0"]) + @pytest.mark.parametrize("compiler_str", ["clang", "gcc", "gcc@10.2.1", "clang@:15.0.0"]) def test_compiler_inheritance(self, compiler_str): spec_str = "mpileaks %{0}".format(compiler_str) spec = Spec(spec_str).concretized() @@ -640,7 +703,8 @@ def test_nobuild_package(self): with pytest.raises(spack.error.SpecError): spec.concretize() - def test_external_and_virtual(self): + def test_external_and_virtual(self, mutable_config): + mutable_config.set("packages:stuff", {"buildable": False}) spec = Spec("externaltest") spec.concretize() assert spec["externaltool"].external_path == os.path.sep + os.path.join( @@ -769,7 +833,7 @@ def test_regression_issue_7941(self): # The string representation of a spec containing # an explicit multi-valued variant and a dependency # might be parsed differently than the originating spec - s = Spec("a foobar=bar ^b") + s = Spec("pkg-a foobar=bar ^pkg-b") t = Spec(str(s)) s.concretize() @@ -862,18 +926,21 @@ def test_concretize_anonymous_dep(self, spec_str): @pytest.mark.parametrize( "spec_str,expected_str", [ - # Unconstrained versions select default compiler (gcc@4.5.0) + # Unconstrained versions select default compiler (gcc@10.2.1) ("bowtie@1.4.0", "%gcc@10.2.1"), # Version with conflicts and no valid gcc select another compiler - ("bowtie@1.3.0", "%clang@12.0.0"), + ("bowtie@1.3.0", "%clang@15.0.0"), # If a higher gcc is available still prefer that ("bowtie@1.2.2 os=redhat6", "%gcc@11.1.0"), ], ) @pytest.mark.only_clingo("Original concretizer cannot work around conflicts") - def test_compiler_conflicts_in_package_py(self, spec_str, expected_str): - s = Spec(spec_str).concretized() - assert s.satisfies(expected_str) + def test_compiler_conflicts_in_package_py( + self, spec_str, expected_str, clang12_with_flags, gcc11_with_flags + ): + with spack.config.override("compilers", [clang12_with_flags, gcc11_with_flags]): + s = Spec(spec_str).concretized() + assert s.satisfies(expected_str) @pytest.mark.parametrize( "spec_str,expected,unexpected", @@ -997,7 +1064,7 @@ def test_working_around_conflicting_defaults(self, spec_str, expected): [("cmake", ["%clang"]), ("cmake %gcc", ["%gcc"]), ("cmake %clang", ["%clang"])], ) @pytest.mark.only_clingo("Use case not supported by the original concretizer") - def test_external_package_and_compiler_preferences(self, spec_str, expected): + def test_external_package_and_compiler_preferences(self, spec_str, expected, mutable_config): packages_yaml = { "all": {"compiler": ["clang", "gcc"]}, "cmake": { @@ -1005,7 +1072,7 @@ def test_external_package_and_compiler_preferences(self, spec_str, expected): "buildable": False, }, } - spack.config.set("packages", packages_yaml) + mutable_config.set("packages", packages_yaml) s = Spec(spec_str).concretized() assert s.external @@ -1119,16 +1186,14 @@ def test_external_that_would_require_a_virtual_dependency(self): assert s.external assert "stuff" not in s - def test_transitive_conditional_virtual_dependency(self): + def test_transitive_conditional_virtual_dependency(self, mutable_config): + """Test that an external is used as provider if the virtual is non-buildable""" + mutable_config.set("packages:stuff", {"buildable": False}) s = Spec("transitive-conditional-virtual-dependency").concretized() - # The default for conditional-virtual-dependency is to have - # +stuff~mpi, so check that these defaults are respected - assert "+stuff" in s["conditional-virtual-dependency"] - assert "~mpi" in s["conditional-virtual-dependency"] - - # 'stuff' is provided by an external package, so check it's present - assert "externalvirtual" in s + # Test that the default +stuff~mpi is maintained, and the right provider is selected + assert s.satisfies("^conditional-virtual-dependency +stuff~mpi") + assert s.satisfies("^[virtuals=stuff] externalvirtual") @pytest.mark.regression("20040") @pytest.mark.only_clingo("Use case not supported by the original concretizer") @@ -1146,14 +1211,14 @@ def test_conditional_provides_or_depends_on(self): [ # Check that True is treated correctly and attaches test deps # to all nodes in the DAG - ("a", True, ["a"], []), - ("a foobar=bar", True, ["a", "b"], []), + ("pkg-a", True, ["pkg-a"], []), + ("pkg-a foobar=bar", True, ["pkg-a", "pkg-b"], []), # Check that a list of names activates the dependency only for # packages in that list - ("a foobar=bar", ["a"], ["a"], ["b"]), - ("a foobar=bar", ["b"], ["b"], ["a"]), + ("pkg-a foobar=bar", ["pkg-a"], ["pkg-a"], ["pkg-b"]), + ("pkg-a foobar=bar", ["pkg-b"], ["pkg-b"], ["pkg-a"]), # Check that False disregard test dependencies - ("a foobar=bar", False, [], ["a", "b"]), + ("pkg-a foobar=bar", False, [], ["pkg-a", "pkg-b"]), ], ) def test_activating_test_dependencies(self, spec_str, tests_arg, with_dep, without_dep): @@ -1171,16 +1236,18 @@ def test_activating_test_dependencies(self, spec_str, tests_arg, with_dep, witho @pytest.mark.regression("20019") @pytest.mark.only_clingo("Use case not supported by the original concretizer") - def test_compiler_match_is_preferred_to_newer_version(self): + def test_compiler_match_is_preferred_to_newer_version(self, compiler_factory): # This spec depends on openblas. Openblas has a conflict # that doesn't allow newer versions with gcc@4.4.0. Check # that an old version of openblas is selected, rather than # a different compiler for just that node. - spec_str = "simple-inheritance+openblas %gcc@10.1.0 os=redhat6" - s = Spec(spec_str).concretized() - - assert "openblas@0.2.15" in s - assert s["openblas"].satisfies("%gcc@10.1.0") + with spack.config.override( + "compilers", [compiler_factory(spec="gcc@10.1.0", operating_system="redhat6")] + ): + spec_str = "simple-inheritance+openblas %gcc@10.1.0 os=redhat6" + s = Spec(spec_str).concretized() + assert "openblas@0.2.15" in s + assert s["openblas"].satisfies("%gcc@10.1.0") @pytest.mark.regression("19981") def test_target_ranges_in_conflicts(self): @@ -1205,8 +1272,12 @@ def test_variant_not_default(self): @pytest.mark.regression("20055") @pytest.mark.only_clingo("Use case not supported by the original concretizer") - def test_custom_compiler_version(self): - s = Spec("a %gcc@10foo os=redhat6").concretized() + def test_custom_compiler_version(self, mutable_config, compiler_factory, monkeypatch): + mutable_config.set( + "compilers", [compiler_factory(spec="gcc@10foo", operating_system="redhat6")] + ) + monkeypatch.setattr(spack.compiler.Compiler, "real_version", "10.2.1") + s = Spec("pkg-a %gcc@10foo os=redhat6").concretized() assert "%gcc@10foo" in s def test_all_patches_applied(self): @@ -1305,6 +1376,9 @@ def mock_fn(*args, **kwargs): def test_reuse_installed_packages_when_package_def_changes( self, context, mutable_database, repo_with_changing_recipe ): + # test applies only with reuse turned off in concretizer + spack.config.set("concretizer:reuse", False) + # Install a spec root = Spec("root").concretized() dependency = root["changing"].copy() @@ -1328,13 +1402,29 @@ def test_reuse_installed_packages_when_package_def_changes( # Structure and package hash will be different without reuse assert root.dag_hash() != new_root_without_reuse.dag_hash() + @pytest.mark.only_clingo("Use case not supported by the original concretizer") + @pytest.mark.regression("43663") + def test_no_reuse_when_variant_condition_does_not_hold(self, mutable_database, mock_packages): + spack.config.set("concretizer:reuse", True) + + # Install a spec for which the `version_based` variant condition does not hold + old = Spec("conditional-variant-pkg @1").concretized() + old.package.do_install(fake=True, explicit=True) + + # Then explicitly require a spec with `+version_based`, which shouldn't reuse previous spec + new1 = Spec("conditional-variant-pkg +version_based").concretized() + assert new1.satisfies("@2 +version_based") + + new2 = Spec("conditional-variant-pkg +two_whens").concretized() + assert new2.satisfies("@2 +two_whens +version_based") + @pytest.mark.only_clingo("Use case not supported by the original concretizer") def test_reuse_with_flags(self, mutable_database, mutable_config): spack.config.set("concretizer:reuse", True) - spec = Spec("a cflags=-g cxxflags=-g").concretized() + spec = Spec("pkg-a cflags=-g cxxflags=-g").concretized() spack.store.STORE.db.add(spec, None) - testspec = Spec("a cflags=-g") + testspec = Spec("pkg-a cflags=-g") testspec.concretize() assert testspec == spec @@ -1405,16 +1495,23 @@ def test_external_with_non_default_variant_as_dependency(self): ("mpileaks%gcc@10.2.1 platform=test os=redhat6", "os=redhat6"), ], ) - def test_os_selection_when_multiple_choices_are_possible(self, spec_str, expected_os): - s = Spec(spec_str).concretized() - - for node in s.traverse(): - assert node.satisfies(expected_os) + def test_os_selection_when_multiple_choices_are_possible( + self, spec_str, expected_os, compiler_factory + ): + # GCC 10.2.1 is defined both for debian and for redhat + with spack.config.override( + "compilers", [compiler_factory(spec="gcc@10.2.1", operating_system="redhat6")] + ): + s = Spec(spec_str).concretized() + for node in s.traverse(): + if node.name == "glibc": + continue + assert node.satisfies(expected_os) @pytest.mark.regression("22718") @pytest.mark.parametrize( "spec_str,expected_compiler", - [("mpileaks", "%gcc@10.2.1"), ("mpileaks ^mpich%clang@12.0.0", "%clang@12.0.0")], + [("mpileaks", "%gcc@10.2.1"), ("mpileaks ^mpich%clang@15.0.0", "%clang@15.0.0")], ) def test_compiler_is_unique(self, spec_str, expected_compiler): s = Spec(spec_str).concretized() @@ -1510,7 +1607,7 @@ def test_non_default_provider_of_multiple_virtuals(self): ) @pytest.mark.only_clingo("Use case not supported by the original concretizer") def test_concrete_specs_are_not_modified_on_reuse( - self, mutable_database, spec_str, expect_installed, config + self, mutable_database, spec_str, expect_installed ): # Test the internal consistency of solve + DAG reconstruction # when reused specs are added to the mix. This prevents things @@ -1670,49 +1767,49 @@ def test_reuse_with_unknown_namespace_dont_raise( self, temporary_store, mock_custom_repository ): with spack.repo.use_repositories(mock_custom_repository, override=False): - s = Spec("c").concretized() + s = Spec("pkg-c").concretized() assert s.namespace != "builtin.mock" s.package.do_install(fake=True, explicit=True) with spack.config.override("concretizer:reuse", True): - s = Spec("c").concretized() + s = Spec("pkg-c").concretized() assert s.namespace == "builtin.mock" @pytest.mark.regression("28259") def test_reuse_with_unknown_package_dont_raise(self, tmpdir, temporary_store, monkeypatch): builder = spack.repo.MockRepositoryBuilder(tmpdir.mkdir("mock.repo"), namespace="myrepo") - builder.add_package("c") + builder.add_package("pkg-c") with spack.repo.use_repositories(builder.root, override=False): - s = Spec("c").concretized() + s = Spec("pkg-c").concretized() assert s.namespace == "myrepo" s.package.do_install(fake=True, explicit=True) - del sys.modules["spack.pkg.myrepo.c"] + del sys.modules["spack.pkg.myrepo.pkg-c"] del sys.modules["spack.pkg.myrepo"] - builder.remove("c") + builder.remove("pkg-c") with spack.repo.use_repositories(builder.root, override=False) as repos: # TODO (INJECT CONFIGURATION): unclear why the cache needs to be invalidated explicitly repos.repos[0]._pkg_checker.invalidate() with spack.config.override("concretizer:reuse", True): - s = Spec("c").concretized() + s = Spec("pkg-c").concretized() assert s.namespace == "builtin.mock" @pytest.mark.parametrize( - "specs,expected", + "specs,expected,libc_offset", [ - (["libelf", "libelf@0.8.10"], 1), - (["libdwarf%gcc", "libelf%clang"], 2), - (["libdwarf%gcc", "libdwarf%clang"], 4), - (["libdwarf^libelf@0.8.12", "libdwarf^libelf@0.8.13"], 4), - (["hdf5", "zmpi"], 3), - (["hdf5", "mpich"], 2), - (["hdf5^zmpi", "mpich"], 4), - (["mpi", "zmpi"], 2), - (["mpi", "mpich"], 1), + (["libelf", "libelf@0.8.10"], 1, 1), + (["libdwarf%gcc", "libelf%clang"], 2, 1), + (["libdwarf%gcc", "libdwarf%clang"], 3, 1), + (["libdwarf^libelf@0.8.12", "libdwarf^libelf@0.8.13"], 4, 1), + (["hdf5", "zmpi"], 3, 1), + (["hdf5", "mpich"], 2, 1), + (["hdf5^zmpi", "mpich"], 4, 1), + (["mpi", "zmpi"], 2, 1), + (["mpi", "mpich"], 1, 1), ], ) @pytest.mark.only_clingo("Original concretizer cannot concretize in rounds") - def test_best_effort_coconcretize(self, specs, expected): + def test_best_effort_coconcretize(self, specs, expected, libc_offset): specs = [Spec(s) for s in specs] solver = spack.solver.asp.Solver() solver.reuse = False @@ -1721,7 +1818,10 @@ def test_best_effort_coconcretize(self, specs, expected): for s in result.specs: concrete_specs.update(s.traverse()) - assert len(concrete_specs) == expected + if not spack.solver.asp.using_libc_compatibility(): + libc_offset = 0 + + assert len(concrete_specs) == expected + libc_offset @pytest.mark.parametrize( "specs,expected_spec,occurances", @@ -1769,6 +1869,22 @@ def test_best_effort_coconcretize_preferences(self, specs, expected_spec, occura counter += 1 assert counter == occurances, concrete_specs + @pytest.mark.only_clingo("Original concretizer cannot concretize in rounds") + def test_solve_in_rounds_all_unsolved(self, monkeypatch, mock_packages): + specs = [Spec(x) for x in ["libdwarf%gcc", "libdwarf%clang"]] + solver = spack.solver.asp.Solver() + solver.reuse = False + + simulate_unsolved_property = list((x, None) for x in specs) + monkeypatch.setattr(spack.solver.asp.Result, "unsolved_specs", simulate_unsolved_property) + monkeypatch.setattr(spack.solver.asp.Result, "specs", list()) + + with pytest.raises( + spack.solver.asp.InternalConcretizerError, + match="a subset of input specs could not be solved for", + ): + list(solver.solve_in_rounds(specs)) + @pytest.mark.only_clingo("Use case not supported by the original concretizer") def test_coconcretize_reuse_and_virtuals(self): reusable_specs = [] @@ -1806,50 +1922,53 @@ def test_misleading_error_message_on_version(self, mutable_database): @pytest.mark.only_clingo("Use case not supported by the original concretizer") def test_version_weight_and_provenance(self): """Test package preferences during coconcretization.""" - reusable_specs = [Spec(spec_str).concretized() for spec_str in ("b@0.9", "b@1.0")] - root_spec = Spec("a foobar=bar") + reusable_specs = [Spec(spec_str).concretized() for spec_str in ("pkg-b@0.9", "pkg-b@1.0")] + root_spec = Spec("pkg-a foobar=bar") with spack.config.override("concretizer:reuse", True): solver = spack.solver.asp.Solver() setup = spack.solver.asp.SpackSolverSetup() result, _, _ = solver.driver.solve(setup, [root_spec], reuse=reusable_specs) - # The result here should have a single spec to build ('a') - # and it should be using b@1.0 with a version badness of 2 + # The result here should have a single spec to build ('pkg-a') + # and it should be using pkg-b@1.0 with a version badness of 2 # The provenance is: - # version_declared("b","1.0",0,"package_py"). - # version_declared("b","0.9",1,"package_py"). - # version_declared("b","1.0",2,"installed"). - # version_declared("b","0.9",3,"installed"). + # version_declared("pkg-b","1.0",0,"package_py"). + # version_declared("pkg-b","0.9",1,"package_py"). + # version_declared("pkg-b","1.0",2,"installed"). + # version_declared("pkg-b","0.9",3,"installed"). # # Depending on the target, it may also use gnuconfig result_spec = result.specs[0] num_specs = len(list(result_spec.traverse())) + libc_offset = 1 if spack.solver.asp.using_libc_compatibility() else 0 criteria = [ - (num_specs - 1, None, "number of packages to build (vs. reuse)"), - (2, 0, "version badness"), + (num_specs - 1 - libc_offset, None, "number of packages to build (vs. reuse)"), + (2, 0, "version badness (non roots)"), ] for criterion in criteria: - assert criterion in result.criteria - assert result_spec.satisfies("^b@1.0") + assert criterion in result.criteria, criterion + assert result_spec.satisfies("^pkg-b@1.0") - @pytest.mark.regression("31169") @pytest.mark.only_clingo("Use case not supported by the original concretizer") - def test_not_reusing_incompatible_os_or_compiler(self): - root_spec = Spec("b") + def test_reuse_succeeds_with_config_compatible_os(self): + root_spec = Spec("pkg-b") s = root_spec.concretized() - wrong_compiler, wrong_os = s.copy(), s.copy() - wrong_compiler.compiler = spack.spec.CompilerSpec("gcc@12.1.0") - wrong_os.architecture = spack.spec.ArchSpec("test-ubuntu2204-x86_64") - reusable_specs = [wrong_compiler, wrong_os] - with spack.config.override("concretizer:reuse", True): + other_os = s.copy() + mock_os = "ubuntu2204" + other_os.architecture = spack.spec.ArchSpec( + "test-{os}-{target}".format(os=mock_os, target=str(s.architecture.target)) + ) + reusable_specs = [other_os] + overrides = {"concretizer": {"reuse": True, "os_compatible": {s.os: [mock_os]}}} + custom_scope = spack.config.InternalConfigScope("concretize_override", overrides) + with spack.config.override(custom_scope): solver = spack.solver.asp.Solver() setup = spack.solver.asp.SpackSolverSetup() result, _, _ = solver.driver.solve(setup, [root_spec], reuse=reusable_specs) concrete_spec = result.specs[0] - assert concrete_spec.satisfies("%{}".format(s.compiler)) - assert concrete_spec.satisfies("os={}".format(s.architecture.os)) + assert concrete_spec.satisfies("os={}".format(other_os.architecture.os)) def test_git_hash_assigned_version_is_preferred(self): hash = "a" * 40 @@ -2036,7 +2155,11 @@ def test_external_python_extension_find_dependency_from_installed(self, monkeypa # install python external python = Spec("python").concretized() - monkeypatch.setattr(spack.store.STORE.db, "query", lambda x: [python]) + + def query(*args, **kwargs): + return [python] + + monkeypatch.setattr(spack.store.STORE.db, "query", query) # ensure that we can't be faking this by getting it from config external_conf.pop("python") @@ -2094,7 +2217,7 @@ def test_external_python_extension_find_unified_python(self): "specs", [ ["mpileaks^ callpath ^dyninst@8.1.1:8 ^mpich2@1.3:1"], - ["multivalue-variant ^a@2:2"], + ["multivalue-variant ^pkg-a@2:2"], ["v1-consumer ^conditional-provider@1:1 +disable-v1"], ], ) @@ -2110,7 +2233,7 @@ def test_result_specs_is_not_empty(self, specs): assert result.specs @pytest.mark.regression("38664") - def test_unsolved_specs_raises_error(self, monkeypatch, mock_packages, config): + def test_unsolved_specs_raises_error(self, monkeypatch, mock_packages): """Check that the solver raises an exception when input specs are not satisfied. """ @@ -2130,12 +2253,12 @@ def test_unsolved_specs_raises_error(self, monkeypatch, mock_packages, config): @pytest.mark.regression("43141") @pytest.mark.only_clingo("Use case not supported by the original concretizer") - def test_clear_error_when_unknown_compiler_requested(self, mock_packages, config): + def test_clear_error_when_unknown_compiler_requested(self, mock_packages): """Tests that the solver can report a case where the compiler cannot be set""" with pytest.raises( - spack.error.UnsatisfiableSpecError, match="Cannot set the required compiler: a%foo" + spack.error.UnsatisfiableSpecError, match="Cannot set the required compiler: pkg-a%foo" ): - Spec("a %foo").concretized() + Spec("pkg-a %foo").concretized() @pytest.mark.regression("36339") def test_compiler_match_constraints_when_selected(self): @@ -2171,7 +2294,7 @@ def test_compiler_match_constraints_when_selected(self): }, ] spack.config.set("compilers", compiler_configuration) - s = Spec("a %gcc@:11").concretized() + s = Spec("pkg-a %gcc@:11").concretized() assert s.compiler.version == ver("=11.1.0"), s @pytest.mark.regression("36339") @@ -2192,7 +2315,7 @@ def test_compiler_with_custom_non_numeric_version(self, mock_executable): } ] spack.config.set("compilers", compiler_configuration) - s = Spec("a %gcc@foo").concretized() + s = Spec("pkg-a %gcc@foo").concretized() assert s.compiler.version == ver("=foo") @pytest.mark.regression("36628") @@ -2218,13 +2341,13 @@ def test_concretization_with_compilers_supporting_target_any(self): ] with spack.config.override("compilers", compiler_configuration): - s = spack.spec.Spec("a").concretized() + s = Spec("pkg-a").concretized() assert s.satisfies("%gcc@12.1.0") @pytest.mark.parametrize("spec_str", ["mpileaks", "mpileaks ^mpich"]) - def test_virtuals_are_annotated_on_edges(self, spec_str, default_mock_concretization): + def test_virtuals_are_annotated_on_edges(self, spec_str): """Tests that information on virtuals is annotated on DAG edges""" - spec = default_mock_concretization(spec_str) + spec = Spec(spec_str).concretized() mpi_provider = spec["mpi"].name edges = spec.edges_to_dependencies(name=mpi_provider) @@ -2238,7 +2361,7 @@ def test_virtuals_are_annotated_on_edges(self, spec_str, default_mock_concretiza "spec_str,mpi_name", [("mpileaks", "mpich"), ("mpileaks ^mpich2", "mpich2"), ("mpileaks ^zmpi", "zmpi")], ) - def test_virtuals_are_reconstructed_on_reuse(self, spec_str, mpi_name, database): + def test_virtuals_are_reconstructed_on_reuse(self, spec_str, mpi_name, mutable_database): """Tests that when we reuse a spec, virtual on edges are reconstructed correctly""" with spack.config.override("concretizer:reuse", True): spec = Spec(spec_str).concretized() @@ -2253,7 +2376,7 @@ def test_dont_define_new_version_from_input_if_checksum_required(self, working_e with pytest.raises(spack.error.UnsatisfiableSpecError): # normally spack concretizes to @=3.0 if it's not defined in package.py, except # when checksums are required - Spec("a@=3.0").concretized() + Spec("pkg-a@=3.0").concretized() @pytest.mark.regression("39570") @pytest.mark.db @@ -2300,6 +2423,206 @@ def test_select_lower_priority_package_from_repository_stack( assert s[name].concrete assert s[name].namespace == namespace + @pytest.mark.only_clingo("Old concretizer cannot reuse") + def test_reuse_specs_from_non_available_compilers(self, mutable_config, mutable_database): + """Tests that we can reuse specs with compilers that are not configured locally.""" + # All the specs in the mutable DB have been compiled with %gcc@=10.2.1 + specs = mutable_database.query_local() + assert all(s.satisfies("%gcc@=10.2.1") for s in specs) + + spack.compilers.remove_compiler_from_config("gcc@=10.2.1") + assert not spack.compilers.compilers_for_spec("gcc@=10.2.1") + mutable_config.set("concretizer:reuse", True) + + # mpileaks is in the database, it will be reused with gcc@=10.2.1 + root = Spec("mpileaks").concretized() + for s in root.traverse(): + assert s.satisfies("%gcc@10.2.1") + + # fftw is not in the database, therefore the root will be compiled with gcc@=9.4.0, + # while the mpi is reused from the database and is compiled with gcc@=10.2.1 + root = Spec("fftw").concretized() + assert root.satisfies("%gcc@=9.4.0") + for s in root.traverse(root=False): + assert s.satisfies("%gcc@10.2.1") + + @pytest.mark.regression("43406") + def test_externals_with_platform_explicitly_set(self, tmp_path): + """Tests that users can specify platform=xxx in an external spec""" + external_conf = { + "mpich": { + "buildable": False, + "externals": [{"spec": "mpich@=2.0.0 platform=test", "prefix": str(tmp_path)}], + } + } + spack.config.set("packages", external_conf) + s = Spec("mpich").concretized() + assert s.external + + @pytest.mark.regression("43875") + def test_concretize_missing_compiler(self, mutable_config, monkeypatch): + """Tests that Spack can concretize a spec with a missing compiler when the + option is active. + """ + + def _default_libc(self): + if self.cc is None: + return None + return Spec("glibc@=2.28") + + monkeypatch.setattr(spack.concretize.Concretizer, "check_for_compiler_existence", False) + monkeypatch.setattr(spack.compiler.Compiler, "default_libc", property(_default_libc)) + monkeypatch.setattr( + spack.util.libc, "libc_from_current_python_process", lambda: Spec("glibc@=2.28") + ) + mutable_config.set("config:install_missing_compilers", True) + s = Spec("pkg-a %gcc@=13.2.0").concretized() + assert s.satisfies("%gcc@13.2.0") + + @pytest.mark.regression("43267") + def test_spec_with_build_dep_from_json(self, tmp_path): + """Tests that we can correctly concretize a spec, when we express its dependency as a + concrete spec to be read from JSON. + + The bug was triggered by missing virtuals on edges that were trimmed from pure build + dependencies. + """ + build_dep = Spec("dttop").concretized() + json_file = tmp_path / "build.json" + json_file.write_text(build_dep.to_json()) + s = Spec(f"dtuse ^{str(json_file)}").concretized() + assert s["dttop"].dag_hash() == build_dep.dag_hash() + + @pytest.mark.regression("44040") + @pytest.mark.only_clingo("Use case not supported by the original concretizer") + def test_exclude_specs_from_reuse(self, monkeypatch): + """Tests that we can exclude a spec from reuse when concretizing, and that the spec + is not added back to the solve as a dependency of another reusable spec. + + The expected spec is: + + o callpath@1.0 + |\ + | |\ + o | | mpich@3.0.4 + |/ / + | o dyninst@8.2 + |/| + | |\ + | | o libdwarf@20130729 + | |/| + |/|/ + | o libelf@0.8.13 + |/ + o glibc@2.31 + """ + # Prepare a mock mirror that returns an old version of dyninst + request_str = "callpath ^mpich" + reused = Spec(f"{request_str} ^dyninst@8.1.1").concretized() + monkeypatch.setattr(spack.solver.asp, "_specs_from_mirror", lambda: [reused]) + + # Exclude dyninst from reuse, so we expect that the old version is not taken into account + with spack.config.override( + "concretizer:reuse", {"from": [{"type": "buildcache", "exclude": ["dyninst"]}]} + ): + result = Spec(request_str).concretized() + + assert result.dag_hash() != reused.dag_hash() + assert result["mpich"].dag_hash() == reused["mpich"].dag_hash() + assert result["dyninst"].dag_hash() != reused["dyninst"].dag_hash() + assert result["dyninst"].satisfies("@=8.2") + for dep in result["dyninst"].traverse(root=False): + assert dep.dag_hash() == reused[dep.name].dag_hash() + + @pytest.mark.regression("44091") + @pytest.mark.parametrize( + "included_externals", + [ + ["deprecated-versions"], + # Try the empty list, to ensure that in that case everything will be included + # since filtering should happen only when the list is non-empty + [], + ], + ) + @pytest.mark.only_clingo("Use case not supported by the original concretizer") + def test_include_specs_from_externals_and_libcs( + self, included_externals, mutable_config, tmp_path + ): + """Tests that when we include specs from externals, we always include libcs.""" + mutable_config.set( + "packages", + { + "deprecated-versions": { + "externals": [{"spec": "deprecated-versions@1.1.0", "prefix": str(tmp_path)}] + } + }, + ) + request_str = "deprecated-client" + + # When using the external the version is selected even if deprecated + with spack.config.override( + "concretizer:reuse", {"from": [{"type": "external", "include": included_externals}]} + ): + result = Spec(request_str).concretized() + + assert result["deprecated-versions"].satisfies("@1.1.0") + + # When excluding it, we pick the non-deprecated version + with spack.config.override( + "concretizer:reuse", + {"from": [{"type": "external", "exclude": ["deprecated-versions"]}]}, + ): + result = Spec(request_str).concretized() + + assert result["deprecated-versions"].satisfies("@1.0.0") + + @pytest.mark.regression("44085") + @pytest.mark.only_clingo("Use case not supported by the original concretizer") + def test_can_reuse_concrete_externals_for_dependents(self, mutable_config, tmp_path): + """Test that external specs that are in the DB can be reused. This means they are + preferred to concretizing another external from packages.yaml + """ + packages_yaml = { + "externaltool": {"externals": [{"spec": "externaltool@2.0", "prefix": "/fake/path"}]} + } + mutable_config.set("packages", packages_yaml) + # Concretize with gcc@9 to get a suboptimal spec, since we have gcc@10 available + external_spec = Spec("externaltool@2 %gcc@9").concretized() + assert external_spec.external + + root_specs = [Spec("sombrero")] + with spack.config.override("concretizer:reuse", True): + solver = spack.solver.asp.Solver() + setup = spack.solver.asp.SpackSolverSetup() + result, _, _ = solver.driver.solve(setup, root_specs, reuse=[external_spec]) + + assert len(result.specs) == 1 + sombrero = result.specs[0] + assert sombrero["externaltool"].dag_hash() == external_spec.dag_hash() + + @pytest.mark.only_clingo("Original concretizer cannot reuse") + def test_cannot_reuse_host_incompatible_libc(self): + """Test whether reuse concretization correctly fails to reuse a spec with a host + incompatible libc.""" + if not spack.solver.asp.using_libc_compatibility(): + pytest.skip("This test requires libc nodes") + + # We install b@1 ^glibc@2.30, and b@0 ^glibc@2.28. The former is not host compatible, the + # latter is. + fst = Spec("pkg-b@1").concretized() + fst._mark_concrete(False) + fst.dependencies("glibc")[0].versions = VersionList(["=2.30"]) + fst._mark_concrete(True) + snd = Spec("pkg-b@0").concretized() + + # The spec b@1 ^glibc@2.30 is "more optimal" than b@0 ^glibc@2.28, but due to glibc + # incompatibility, it should not be reused. + solver = spack.solver.asp.Solver() + setup = spack.solver.asp.SpackSolverSetup() + result, _, _ = solver.driver.solve(setup, [Spec("pkg-b")], reuse=[fst, snd]) + assert len(result.specs) == 1 + assert result.specs[0] == snd + @pytest.fixture() def duplicates_test_repository(): @@ -2438,6 +2761,29 @@ def test_no_multiple_solutions_with_different_edges_same_nodes(self): assert len(edges) == 1 assert edges[0].spec.satisfies("@=60") + @pytest.mark.regression("43647") + def test_specifying_different_versions_build_deps(self): + """Tests that we can concretize a spec with nodes using the same build + dependency pinned at different versions, when the constraint is specified + in the root spec. + + o hdf5@1.0 + |\ + o | pinned-gmake@1.0 + o | gmake@3.0 + / + o gmake@4.1 + + """ + hdf5_str = "hdf5@1.0 ^gmake@4.1" + pinned_str = "pinned-gmake@1.0 ^gmake@3.0" + input_specs = [Spec(hdf5_str), Spec(pinned_str)] + solver = spack.solver.asp.Solver() + result = solver.solve(input_specs) + + assert any(x.satisfies(hdf5_str) for x in result.specs) + assert any(x.satisfies(pinned_str) for x in result.specs) + @pytest.mark.parametrize( "v_str,v_opts,checksummed", @@ -2478,7 +2824,9 @@ def test_drop_moving_targets(v_str, v_opts, checksummed): class TestConcreteSpecsByHash: """Tests the container of concrete specs""" - @pytest.mark.parametrize("input_specs", [["a"], ["a foobar=bar", "b"], ["a foobar=baz", "b"]]) + @pytest.mark.parametrize( + "input_specs", [["pkg-a"], ["pkg-a foobar=bar", "pkg-b"], ["pkg-a foobar=baz", "pkg-b"]] + ) def test_adding_specs(self, input_specs, default_mock_concretization): """Tests that concrete specs in the container are equivalent, but stored as different objects in memory. @@ -2627,3 +2975,143 @@ def test_reusable_externals_different_spec(mock_packages, tmpdir): {"mpich": {"externals": [{"spec": "mpich@4.1 +debug", "prefix": tmpdir.strpath}]}}, local=False, ) + + +def test_concretization_version_order(): + versions = [ + (Version("develop"), {}), + (Version("1.0"), {}), + (Version("2.0"), {"deprecated": True}), + (Version("1.1"), {}), + (Version("1.1alpha1"), {}), + (Version("0.9"), {"preferred": True}), + ] + result = [ + v + for v, _ in sorted( + versions, key=spack.solver.asp._concretization_version_order, reverse=True + ) + ] + assert result == [ + Version("0.9"), # preferred + Version("1.1"), # latest non-deprecated final version + Version("1.0"), # latest non-deprecated final version + Version("1.1alpha1"), # prereleases + Version("develop"), # likely development version + Version("2.0"), # deprecated + ] + + +@pytest.mark.only_clingo("Original concretizer cannot reuse specs") +@pytest.mark.parametrize( + "roots,reuse_yaml,expected,not_expected,expected_length", + [ + ( + ["mpileaks"], + {"roots": True, "include": ["^mpich"]}, + ["^mpich"], + ["^mpich2", "^zmpi"], + 2, + ), + ( + ["mpileaks"], + {"roots": True, "include": ["externaltest"]}, + ["externaltest"], + ["^mpich", "^mpich2", "^zmpi"], + 1, + ), + ], +) +@pytest.mark.usefixtures("mutable_database", "mock_store") +@pytest.mark.not_on_windows("Expected length is different on Windows") +def test_filtering_reused_specs( + roots, reuse_yaml, expected, not_expected, expected_length, mutable_config, monkeypatch +): + """Tests that we can select which specs are to be reused, using constraints as filters""" + # Assume all specs have a runtime dependency + monkeypatch.setattr(spack.solver.asp, "_has_runtime_dependencies", lambda x: True) + mutable_config.set("concretizer:reuse", reuse_yaml) + selector = spack.solver.asp.ReusableSpecsSelector(mutable_config) + specs = selector.reusable_specs(roots) + + assert len(specs) == expected_length + + for constraint in expected: + assert all(x.satisfies(constraint) for x in specs) + + for constraint in not_expected: + assert all(not x.satisfies(constraint) for x in specs) + + +@pytest.mark.usefixtures("mutable_database", "mock_store") +@pytest.mark.parametrize( + "reuse_yaml,expected_length", + [({"from": [{"type": "local"}]}, 17), ({"from": [{"type": "buildcache"}]}, 0)], +) +@pytest.mark.not_on_windows("Expected length is different on Windows") +def test_selecting_reused_sources(reuse_yaml, expected_length, mutable_config, monkeypatch): + """Tests that we can turn on/off sources of reusable specs""" + # Assume all specs have a runtime dependency + monkeypatch.setattr(spack.solver.asp, "_has_runtime_dependencies", lambda x: True) + mutable_config.set("concretizer:reuse", reuse_yaml) + selector = spack.solver.asp.ReusableSpecsSelector(mutable_config) + specs = selector.reusable_specs(["mpileaks"]) + assert len(specs) == expected_length + + +@pytest.mark.parametrize( + "specs,include,exclude,expected", + [ + # "foo" discarded by include rules (everything compiled with GCC) + (["cmake@3.27.9 %gcc", "foo %clang"], ["%gcc"], [], ["cmake@3.27.9 %gcc"]), + # "cmake" discarded by exclude rules (everything compiled with GCC but cmake) + (["cmake@3.27.9 %gcc", "foo %gcc"], ["%gcc"], ["cmake"], ["foo %gcc"]), + ], +) +def test_spec_filters(specs, include, exclude, expected): + specs = [Spec(x) for x in specs] + expected = [Spec(x) for x in expected] + f = spack.solver.asp.SpecFilter( + factory=lambda: specs, is_usable=lambda x: True, include=include, exclude=exclude + ) + assert f.selected_specs() == expected + + +@pytest.mark.only_clingo("clingo only reuse feature being tested") +@pytest.mark.regression("38484") +def test_git_ref_version_can_be_reused(install_mockery, do_not_check_runtimes_on_reuse): + first_spec = spack.spec.Spec("git-ref-package@git.2.1.5=2.1.5~opt").concretized() + first_spec.package.do_install(fake=True, explicit=True) + + with spack.config.override("concretizer:reuse", True): + # reproducer of the issue is that spack will solve when there is a change to the base spec + second_spec = spack.spec.Spec("git-ref-package@git.2.1.5=2.1.5+opt").concretized() + assert second_spec.dag_hash() != first_spec.dag_hash() + # we also want to confirm that reuse actually works so leave variant off to + # let solver reuse + third_spec = spack.spec.Spec("git-ref-package@git.2.1.5=2.1.5") + assert first_spec.satisfies(third_spec) + third_spec.concretize() + assert third_spec.dag_hash() == first_spec.dag_hash() + + +@pytest.mark.only_clingo("clingo only reuse feature being tested") +@pytest.mark.parametrize("standard_version", ["2.0.0", "2.1.5", "2.1.6"]) +def test_reuse_prefers_standard_over_git_versions( + standard_version, install_mockery, do_not_check_runtimes_on_reuse +): + """ + order matters in this test. typically reuse would pick the highest versioned installed match + but we want to prefer the standard version over git ref based versions + so install git ref last and ensure it is not picked up by reuse + """ + standard_spec = spack.spec.Spec(f"git-ref-package@{standard_version}").concretized() + standard_spec.package.do_install(fake=True, explicit=True) + + git_spec = spack.spec.Spec("git-ref-package@git.2.1.5=2.1.5").concretized() + git_spec.package.do_install(fake=True, explicit=True) + + with spack.config.override("concretizer:reuse", True): + test_spec = spack.spec.Spec("git-ref-package@2").concretized() + assert git_spec.dag_hash() != test_spec.dag_hash() + assert standard_spec.dag_hash() == test_spec.dag_hash() diff --git a/lib/spack/spack/test/concretize_compiler_runtimes.py b/lib/spack/spack/test/concretize_compiler_runtimes.py index 12c9b2454d69d4..5b7968ed20788f 100644 --- a/lib/spack/spack/test/concretize_compiler_runtimes.py +++ b/lib/spack/spack/test/concretize_compiler_runtimes.py @@ -7,6 +7,9 @@ import pytest +import archspec.cpu + +import spack.config import spack.paths import spack.repo import spack.solver.asp @@ -24,15 +27,13 @@ def _concretize_with_reuse(*, root_str, reused_str): reused_spec = spack.spec.Spec(reused_str).concretized() setup = spack.solver.asp.SpackSolverSetup(tests=False) driver = spack.solver.asp.PyclingoDriver() - result, _, _ = driver.solve( - setup, [spack.spec.Spec(f"{root_str} ^{reused_str}")], reuse=[reused_spec] - ) + result, _, _ = driver.solve(setup, [spack.spec.Spec(f"{root_str}")], reuse=[reused_spec]) root = result.specs[0] return root, reused_spec @pytest.fixture -def runtime_repo(config): +def runtime_repo(mutable_config): repo = os.path.join(spack.paths.repos_path, "compiler_runtime.test") with spack.repo.use_repositories(repo) as mock_repo: yield mock_repo @@ -47,8 +48,8 @@ def enable_runtimes(): def test_correct_gcc_runtime_is_injected_as_dependency(runtime_repo): - s = spack.spec.Spec("a%gcc@10.2.1 ^b%gcc@4.5.0").concretized() - a, b = s["a"], s["b"] + s = spack.spec.Spec("pkg-a%gcc@10.2.1 ^pkg-b%gcc@9.4.0").concretized() + a, b = s["pkg-a"], s["pkg-b"] # Both a and b should depend on the same gcc-runtime directly assert a.dependencies("gcc-runtime") == b.dependencies("gcc-runtime") @@ -61,16 +62,16 @@ def test_correct_gcc_runtime_is_injected_as_dependency(runtime_repo): def test_external_nodes_do_not_have_runtimes(runtime_repo, mutable_config, tmp_path): """Tests that external nodes don't have runtime dependencies.""" - packages_yaml = {"b": {"externals": [{"spec": "b@1.0", "prefix": f"{str(tmp_path)}"}]}} + packages_yaml = {"pkg-b": {"externals": [{"spec": "pkg-b@1.0", "prefix": f"{str(tmp_path)}"}]}} spack.config.set("packages", packages_yaml) - s = spack.spec.Spec("a%gcc@10.2.1").concretized() + s = spack.spec.Spec("pkg-a%gcc@10.2.1").concretized() - a, b = s["a"], s["b"] + a, b = s["pkg-a"], s["pkg-b"] # Since b is an external, it doesn't depend on gcc-runtime assert a.dependencies("gcc-runtime") - assert a.dependencies("b") + assert a.dependencies("pkg-b") assert not b.dependencies("gcc-runtime") @@ -78,22 +79,56 @@ def test_external_nodes_do_not_have_runtimes(runtime_repo, mutable_config, tmp_p "root_str,reused_str,expected,nruntime", [ # The reused runtime is older than we need, thus we'll add a more recent one for a - ("a%gcc@10.2.1", "b%gcc@4.5.0", {"a": "gcc-runtime@10.2.1", "b": "gcc-runtime@4.5.0"}, 2), - # The root is compiled with an older compiler, thus we'll reuse the runtime from b - ("a%gcc@4.5.0", "b%gcc@10.2.1", {"a": "gcc-runtime@10.2.1", "b": "gcc-runtime@10.2.1"}, 1), + ( + "pkg-a%gcc@10.2.1", + "pkg-b%gcc@9.4.0", + {"pkg-a": "gcc-runtime@10.2.1", "pkg-b": "gcc-runtime@9.4.0"}, + 2, + ), + # The root is compiled with an older compiler, thus we'll NOT reuse the runtime from b + ( + "pkg-a%gcc@9.4.0", + "pkg-b%gcc@10.2.1", + {"pkg-a": "gcc-runtime@9.4.0", "pkg-b": "gcc-runtime@9.4.0"}, + 1, + ), + # Same as before, but tests that we can reuse from a more generic target + pytest.param( + "pkg-a%gcc@9.4.0", + "pkg-b%gcc@10.2.1 target=x86_64", + {"pkg-a": "gcc-runtime@9.4.0", "pkg-b": "gcc-runtime@9.4.0"}, + 1, + marks=pytest.mark.skipif( + str(archspec.cpu.host().family) != "x86_64", reason="test data is x86_64 specific" + ), + ), + pytest.param( + "pkg-a%gcc@10.2.1", + "pkg-b%gcc@9.4.0 target=x86_64", + { + "pkg-a": "gcc-runtime@10.2.1 target=x86_64", + "pkg-b": "gcc-runtime@9.4.0 target=x86_64", + }, + 2, + marks=pytest.mark.skipif( + str(archspec.cpu.host().family) != "x86_64", reason="test data is x86_64 specific" + ), + ), ], ) +@pytest.mark.regression("44444") def test_reusing_specs_with_gcc_runtime(root_str, reused_str, expected, nruntime, runtime_repo): """Tests that we can reuse specs with a "gcc-runtime" leaf node. In particular, checks that the semantic for gcc-runtimes versions accounts for reused packages too. + + Reusable runtime versions should be lower, or equal, to that of parent nodes. """ root, reused_spec = _concretize_with_reuse(root_str=root_str, reused_str=reused_str) - assert f"{expected['b']}" in reused_spec runtime_a = root.dependencies("gcc-runtime")[0] - assert runtime_a.satisfies(expected["a"]) - runtime_b = root["b"].dependencies("gcc-runtime")[0] - assert runtime_b.satisfies(expected["b"]) + assert runtime_a.satisfies(expected["pkg-a"]) + runtime_b = root["pkg-b"].dependencies("gcc-runtime")[0] + assert runtime_b.satisfies(expected["pkg-b"]) runtimes = [x for x in root.traverse() if x.name == "gcc-runtime"] assert len(runtimes) == nruntime @@ -104,8 +139,7 @@ def test_reusing_specs_with_gcc_runtime(root_str, reused_str, expected, nruntime [ # Ensure that, whether we have multiple runtimes in the DAG or not, # we always link only the latest version - ("a%gcc@10.2.1", "b%gcc@4.5.0", ["gcc-runtime@10.2.1"], ["gcc-runtime@4.5.0"]), - ("a%gcc@4.5.0", "b%gcc@10.2.1", ["gcc-runtime@10.2.1"], ["gcc-runtime@4.5.0"]), + ("pkg-a%gcc@10.2.1", "pkg-b%gcc@9.4.0", ["gcc-runtime@10.2.1"], ["gcc-runtime@9.4.0"]) ], ) def test_views_can_handle_duplicate_runtime_nodes( diff --git a/lib/spack/spack/test/concretize_preferences.py b/lib/spack/spack/test/concretize_preferences.py index 74549599afbdf3..d0ecc8f5994ed9 100644 --- a/lib/spack/spack/test/concretize_preferences.py +++ b/lib/spack/spack/test/concretize_preferences.py @@ -105,7 +105,7 @@ def test_preferred_variants_from_wildcard(self): @pytest.mark.parametrize( "compiler_str,spec_str", - [("gcc@=4.5.0", "mpileaks"), ("clang@=12.0.0", "mpileaks"), ("gcc@=4.5.0", "openmpi")], + [("gcc@=9.4.0", "mpileaks"), ("clang@=15.0.0", "mpileaks"), ("gcc@=9.4.0", "openmpi")], ) def test_preferred_compilers(self, compiler_str, spec_str): """Test preferred compilers are applied correctly""" @@ -161,21 +161,24 @@ def test_preferred_providers(self): spec = concretize("mpileaks") assert "zmpi" in spec - def test_config_set_pkg_property_url(self, mutable_mock_repo): + @pytest.mark.parametrize( + "update,expected", + [ + ( + {"url": "http://www.somewhereelse.com/mpileaks-1.0.tar.gz"}, + "http://www.somewhereelse.com/mpileaks-2.3.tar.gz", + ), + ({}, "http://www.llnl.gov/mpileaks-2.3.tar.gz"), + ], + ) + def test_config_set_pkg_property_url(self, update, expected, mock_repo_path): """Test setting an existing attribute in the package class""" - update_packages( - "mpileaks", - "package_attributes", - {"url": "http://www.somewhereelse.com/mpileaks-1.0.tar.gz"}, - ) - spec = concretize("mpileaks") - assert spec.package.fetcher.url == "http://www.somewhereelse.com/mpileaks-2.3.tar.gz" - - update_packages("mpileaks", "package_attributes", {}) - spec = concretize("mpileaks") - assert spec.package.fetcher.url == "http://www.llnl.gov/mpileaks-2.3.tar.gz" + update_packages("mpileaks", "package_attributes", update) + with spack.repo.use_repositories(mock_repo_path): + spec = concretize("mpileaks") + assert spec.package.fetcher.url == expected - def test_config_set_pkg_property_new(self, mutable_mock_repo): + def test_config_set_pkg_property_new(self, mock_repo_path): """Test that you can set arbitrary attributes on the Package class""" conf = syaml.load_config( """\ @@ -194,19 +197,20 @@ def test_config_set_pkg_property_new(self, mutable_mock_repo): """ ) spack.config.set("packages", conf, scope="concretize") - - spec = concretize("mpileaks") - assert spec.package.v1 == 1 - assert spec.package.v2 is True - assert spec.package.v3 == "yesterday" - assert spec.package.v4 == "true" - assert dict(spec.package.v5) == {"x": 1, "y": 2} - assert list(spec.package.v6) == [1, 2] + with spack.repo.use_repositories(mock_repo_path): + spec = concretize("mpileaks") + assert spec.package.v1 == 1 + assert spec.package.v2 is True + assert spec.package.v3 == "yesterday" + assert spec.package.v4 == "true" + assert dict(spec.package.v5) == {"x": 1, "y": 2} + assert list(spec.package.v6) == [1, 2] update_packages("mpileaks", "package_attributes", {}) - spec = concretize("mpileaks") - with pytest.raises(AttributeError): - spec.package.v1 + with spack.repo.use_repositories(mock_repo_path): + spec = concretize("mpileaks") + with pytest.raises(AttributeError): + spec.package.v1 def test_preferred(self): """ "Test packages with some version marked as preferred=True""" @@ -512,5 +516,5 @@ def test_default_preference_variant_different_type_does_not_error(self): packages.yaml doesn't fail with an error. """ with spack.config.override("packages:all", {"variants": "+foo"}): - s = Spec("a").concretized() + s = Spec("pkg-a").concretized() assert s.satisfies("foo=bar") diff --git a/lib/spack/spack/test/concretize_requirements.py b/lib/spack/spack/test/concretize_requirements.py index ea1dc526df01c6..3ec086d962a570 100644 --- a/lib/spack/spack/test/concretize_requirements.py +++ b/lib/spack/spack/test/concretize_requirements.py @@ -103,23 +103,6 @@ def test_repo(_create_test_repo, monkeypatch, mock_stage): yield mock_repo_path -class MakeStage: - def __init__(self, stage): - self.stage = stage - - def __call__(self, *args, **kwargs): - return self.stage - - -@pytest.fixture -def fake_installs(monkeypatch, tmpdir): - stage_path = str(tmpdir.ensure("fake-stage", dir=True)) - universal_unused_stage = spack.stage.DIYStage(stage_path) - monkeypatch.setattr( - spack.build_systems.generic.Package, "_make_stage", MakeStage(universal_unused_stage) - ) - - def test_one_package_multiple_reqs(concretize_scope, test_repo): conf_str = """\ packages: @@ -514,7 +497,7 @@ def test_oneof_ordering(concretize_scope, test_repo): assert s2.satisfies("@2.5") -def test_reuse_oneof(concretize_scope, _create_test_repo, mutable_database, fake_installs): +def test_reuse_oneof(concretize_scope, _create_test_repo, mutable_database, mock_fetch): conf_str = """\ packages: y: @@ -944,9 +927,9 @@ def test_default_requirements_semantic(packages_yaml, concretize_scope, mock_pac Spec("zlib ~shared").concretized() # A spec without the shared variant still concretize - s = Spec("a").concretized() - assert not s.satisfies("a +shared") - assert not s.satisfies("a ~shared") + s = Spec("pkg-a").concretized() + assert not s.satisfies("pkg-a +shared") + assert not s.satisfies("pkg-a ~shared") @pytest.mark.parametrize( @@ -1176,3 +1159,46 @@ def test_forward_multi_valued_variant_using_requires( for constraint in not_expected: assert not s.satisfies(constraint) + + +def test_strong_preferences_higher_priority_than_reuse(concretize_scope, mock_packages): + """Tests that strong preferences have a higher priority than reusing specs.""" + reused_spec = Spec("adios2~bzip2").concretized() + reuse_nodes = list(reused_spec.traverse()) + root_specs = [Spec("ascent+adios2")] + + # Check that without further configuration adios2 is reused + with spack.config.override("concretizer:reuse", True): + solver = spack.solver.asp.Solver() + setup = spack.solver.asp.SpackSolverSetup() + result, _, _ = solver.driver.solve(setup, root_specs, reuse=reuse_nodes) + ascent = result.specs[0] + assert ascent["adios2"].dag_hash() == reused_spec.dag_hash(), ascent + + # If we stick a preference, adios2 is not reused + update_packages_config( + """ + packages: + adios2: + prefer: + - "+bzip2" +""" + ) + with spack.config.override("concretizer:reuse", True): + solver = spack.solver.asp.Solver() + setup = spack.solver.asp.SpackSolverSetup() + result, _, _ = solver.driver.solve(setup, root_specs, reuse=reuse_nodes) + ascent = result.specs[0] + + assert ascent["adios2"].dag_hash() != reused_spec.dag_hash() + assert ascent["adios2"].satisfies("+bzip2") + + # A preference is still preference, so we can override from input + with spack.config.override("concretizer:reuse", True): + solver = spack.solver.asp.Solver() + setup = spack.solver.asp.SpackSolverSetup() + result, _, _ = solver.driver.solve( + setup, [Spec("ascent+adios2 ^adios2~bzip2")], reuse=reuse_nodes + ) + ascent = result.specs[0] + assert ascent["adios2"].dag_hash() == reused_spec.dag_hash(), ascent diff --git a/lib/spack/spack/test/config.py b/lib/spack/spack/test/config.py index 83a652cd41444b..b0cf6bac651eaa 100644 --- a/lib/spack/spack/test/config.py +++ b/lib/spack/spack/test/config.py @@ -13,7 +13,7 @@ import pytest import llnl.util.tty as tty -from llnl.util.filesystem import getuid, join_path, mkdirp, touch, touchp +from llnl.util.filesystem import join_path, touch, touchp import spack.config import spack.directory_layout @@ -492,7 +492,7 @@ def test_substitute_date(mock_low_high_config): ], ) def test_parse_install_tree(config_settings, expected, mutable_config): - expected_root = expected[0] or spack.store.DEFAULT_INSTALL_TREE_ROOT + expected_root = expected[0] or mutable_config.get("config:install_tree:root") expected_unpadded_root = expected[1] or expected_root expected_proj = expected[2] or spack.directory_layout.default_projections @@ -575,7 +575,7 @@ def change_fn(self, section): ], ) def test_parse_install_tree_padded(config_settings, expected, mutable_config): - expected_root = expected[0] or spack.store.DEFAULT_INSTALL_TREE_ROOT + expected_root = expected[0] or mutable_config.get("config:install_tree:root") expected_unpadded_root = expected[1] or expected_root expected_proj = expected[2] or spack.directory_layout.default_projections @@ -761,25 +761,20 @@ def test_internal_config_from_data(): assert config.get("config:checksum", scope="higher") is True -def test_keys_are_ordered(): +def test_keys_are_ordered(configuration_dir): """Test that keys in Spack YAML files retain their order from the file.""" expected_order = ( - "bin", - "man", - "share/man", - "share/aclocal", - "lib", - "lib64", - "include", - "lib/pkgconfig", - "lib64/pkgconfig", - "share/pkgconfig", - "", + "./bin", + "./man", + "./share/man", + "./share/aclocal", + "./lib/pkgconfig", + "./lib64/pkgconfig", + "./share/pkgconfig", + "./", ) - config_scope = spack.config.ConfigScope( - "modules", os.path.join(spack.paths.test_path, "data", "config") - ) + config_scope = spack.config.DirectoryConfigScope("modules", configuration_dir.join("site")) data = config_scope.get_section("modules") @@ -869,26 +864,18 @@ def test_bad_config_section(mock_low_high_config): spack.config.get("foobar") -@pytest.mark.not_on_windows("chmod not supported on Windows") -@pytest.mark.skipif(getuid() == 0, reason="user is root") -def test_bad_command_line_scopes(tmpdir, config): +def test_bad_command_line_scopes(tmp_path, config): cfg = spack.config.Configuration() + file_path = tmp_path / "file_instead_of_dir" + non_existing_path = tmp_path / "non_existing_dir" - with tmpdir.as_cwd(): - with pytest.raises(spack.config.ConfigError): - spack.config._add_command_line_scopes(cfg, ["bad_path"]) + file_path.write_text("") - touch("unreadable_file") - with pytest.raises(spack.config.ConfigError): - spack.config._add_command_line_scopes(cfg, ["unreadable_file"]) + with pytest.raises(spack.config.ConfigError): + spack.config._add_command_line_scopes(cfg, [str(file_path)]) - mkdirp("unreadable_dir") - with pytest.raises(spack.config.ConfigError): - try: - os.chmod("unreadable_dir", 0) - spack.config._add_command_line_scopes(cfg, ["unreadable_dir"]) - finally: - os.chmod("unreadable_dir", 0o700) # so tmpdir can be removed + with pytest.raises(spack.config.ConfigError): + spack.config._add_command_line_scopes(cfg, [str(non_existing_path)]) def test_add_command_line_scopes(tmpdir, mutable_config): @@ -903,6 +890,45 @@ def test_add_command_line_scopes(tmpdir, mutable_config): ) spack.config._add_command_line_scopes(mutable_config, [str(tmpdir)]) + assert mutable_config.get("config:verify_ssl") is False + assert mutable_config.get("config:dirty") is False + + +def test_add_command_line_scope_env(tmp_path, mutable_mock_env_path): + """Test whether --config-scope works, either by name or path.""" + managed_env = ev.create("example").manifest_path + + with open(managed_env, "w") as f: + f.write( + """\ +spack: + config: + install_tree: + root: /tmp/first +""" + ) + + with open(tmp_path / "spack.yaml", "w") as f: + f.write( + """\ +spack: + config: + install_tree: + root: /tmp/second +""" + ) + + config = spack.config.Configuration() + spack.config._add_command_line_scopes(config, ["example", str(tmp_path)]) + assert len(config.scopes) == 2 + assert config.get("config:install_tree:root") == "/tmp/second" + + config = spack.config.Configuration() + spack.config._add_command_line_scopes(config, [str(tmp_path), "example"]) + assert len(config.scopes) == 2 + assert config.get("config:install_tree:root") == "/tmp/first" + + assert ev.active_environment() is None # shouldn't cause an environment to be activated def test_nested_override(): @@ -961,7 +987,7 @@ def test_immutable_scope(tmpdir): root: dummy_tree_value """ ) - scope = spack.config.ImmutableConfigScope("test", str(tmpdir)) + scope = spack.config.DirectoryConfigScope("test", str(tmpdir), writable=False) data = scope.get_section("config") assert data["config"]["install_tree"] == {"root": "dummy_tree_value"} @@ -971,13 +997,15 @@ def test_immutable_scope(tmpdir): def test_single_file_scope(config, env_yaml): - scope = spack.config.SingleFileScope("env", env_yaml, spack.schema.env.schema, ["spack"]) + scope = spack.config.SingleFileScope( + "env", env_yaml, spack.schema.env.schema, yaml_path=["spack"] + ) with spack.config.override(scope): # from the single-file config assert spack.config.get("config:verify_ssl") is False assert spack.config.get("config:dirty") is False - assert spack.config.get("packages:all:compiler") == ["gcc@4.5.3"] + assert spack.config.get("packages:all:compiler") == ["gcc@4.5.3", "gcc", "clang"] # from the lower config scopes assert spack.config.get("config:checksum") is True @@ -1007,7 +1035,9 @@ def test_single_file_scope_section_override(tmpdir, config): """ ) - scope = spack.config.SingleFileScope("env", env_yaml, spack.schema.env.schema, ["spack"]) + scope = spack.config.SingleFileScope( + "env", env_yaml, spack.schema.env.schema, yaml_path=["spack"] + ) with spack.config.override(scope): # from the single-file config @@ -1023,7 +1053,7 @@ def test_single_file_scope_section_override(tmpdir, config): def test_write_empty_single_file_scope(tmpdir): env_schema = spack.schema.env.schema scope = spack.config.SingleFileScope( - "test", str(tmpdir.ensure("config.yaml")), env_schema, ["spack"] + "test", str(tmpdir.ensure("config.yaml")), env_schema, yaml_path=["spack"] ) scope._write_section("config") # confirm we can write empty config @@ -1211,18 +1241,20 @@ def test_license_dir_config(mutable_config, mock_packages): expected_dir = spack.paths.default_license_dir assert spack.config.get("config:license_dir") == expected_dir assert spack.package_base.PackageBase.global_license_dir == expected_dir - assert spack.repo.PATH.get_pkg_class("a").global_license_dir == expected_dir + assert spack.repo.PATH.get_pkg_class("pkg-a").global_license_dir == expected_dir rel_path = os.path.join(os.path.sep, "foo", "bar", "baz") spack.config.set("config:license_dir", rel_path) assert spack.config.get("config:license_dir") == rel_path assert spack.package_base.PackageBase.global_license_dir == rel_path - assert spack.repo.PATH.get_pkg_class("a").global_license_dir == rel_path + assert spack.repo.PATH.get_pkg_class("pkg-a").global_license_dir == rel_path @pytest.mark.regression("22547") def test_single_file_scope_cache_clearing(env_yaml): - scope = spack.config.SingleFileScope("env", env_yaml, spack.schema.env.schema, ["spack"]) + scope = spack.config.SingleFileScope( + "env", env_yaml, spack.schema.env.schema, yaml_path=["spack"] + ) # Check that we can retrieve data from the single file scope before = scope.get_section("config") assert before @@ -1276,7 +1308,7 @@ def test_user_config_path_is_default_when_env_var_is_empty(working_env): def test_default_install_tree(monkeypatch, default_config): s = spack.spec.Spec("nonexistent@x.y.z %none@a.b.c arch=foo-bar-baz") - monkeypatch.setattr(s, "dag_hash", lambda: "abc123") + monkeypatch.setattr(s, "dag_hash", lambda length: "abc123") _, _, projections = spack.store.parse_install_tree(spack.config.get("config")) assert s.format(projections["all"]) == "foo-bar-baz/none-a.b.c/nonexistent-x.y.z-abc123" diff --git a/lib/spack/spack/test/conftest.py b/lib/spack/spack/test/conftest.py index 0fa9b5f12743a3..37fabe3f0bc1c8 100644 --- a/lib/spack/spack/test/conftest.py +++ b/lib/spack/spack/test/conftest.py @@ -12,6 +12,7 @@ import json import os import os.path +import pathlib import re import shutil import stat @@ -22,6 +23,7 @@ import py import pytest +import archspec.cpu import archspec.cpu.microarchitecture import archspec.cpu.schema @@ -31,8 +33,10 @@ from llnl.util.filesystem import copy_tree, mkdirp, remove_linked_tree, touchp, working_dir import spack.binary_distribution +import spack.bootstrap.core import spack.caches import spack.cmd.buildcache +import spack.compiler import spack.compilers import spack.config import spack.database @@ -54,10 +58,17 @@ import spack.util.gpg import spack.util.spack_yaml as syaml import spack.util.url as url_util +import spack.version from spack.fetch_strategy import URLFetchStrategy from spack.util.pattern import Bunch +@pytest.fixture(autouse=True) +def check_config_fixture(request): + if "config" in request.fixturenames and "mutable_config" in request.fixturenames: + raise RuntimeError("'config' and 'mutable_config' are both requested") + + def ensure_configuration_fixture_run_before(request): """Ensure that fixture mutating the configuration run before the one where the function is called. @@ -267,10 +278,6 @@ def clean_test_environment(): ev.deactivate() -def _verify_executables_noop(*args): - return None - - def _host(): """Mock archspec host so there is no inconsistency on the Windows platform This function cannot be local as it needs to be pickleable""" @@ -296,9 +303,7 @@ def mock_compiler_executable_verification(request, monkeypatch): If a test is marked in that way this is a no-op.""" if "enable_compiler_verification" not in request.keywords: - monkeypatch.setattr( - spack.compiler.Compiler, "verify_executables", _verify_executables_noop - ) + monkeypatch.setattr(spack.compiler.Compiler, "verify_executables", _return_none) # Hooks to add command line options or set other custom behaviors. @@ -562,7 +567,7 @@ def _use_test_platform(test_platform): # @pytest.fixture(scope="session") def mock_repo_path(): - yield spack.repo.Repo(spack.paths.mock_packages_path) + yield spack.repo.from_path(spack.paths.mock_packages_path) def _pkg_install_fn(pkg, spec, prefix): @@ -589,7 +594,7 @@ def mock_packages(mock_repo_path, mock_pkg_install, request): def mutable_mock_repo(mock_repo_path, request): """Function-scoped mock packages, for tests that need to modify them.""" ensure_configuration_fixture_run_before(request) - mock_repo = spack.repo.Repo(spack.paths.mock_packages_path) + mock_repo = spack.repo.from_path(spack.paths.mock_packages_path) with spack.repo.use_repositories(mock_repo) as mock_repo_path: yield mock_repo_path @@ -598,7 +603,7 @@ def mutable_mock_repo(mock_repo_path, request): def mock_custom_repository(tmpdir, mutable_mock_repo): """Create a custom repository with a single package "c" and return its path.""" builder = spack.repo.MockRepositoryBuilder(tmpdir.mkdir("myrepo")) - builder.add_package("c") + builder.add_package("pkg-c") return builder.root @@ -685,34 +690,34 @@ def configuration_dir(tmpdir_factory, linux_os): directory path. """ tmpdir = tmpdir_factory.mktemp("configurations") + install_tree_root = tmpdir_factory.mktemp("opt") + modules_root = tmpdir_factory.mktemp("share") + tcl_root = modules_root.ensure("modules", dir=True) + lmod_root = modules_root.ensure("lmod", dir=True) # /data/config has mock config yaml files in it # copy these to the site config. - test_config = py.path.local(spack.paths.test_path).join("data", "config") - test_config.copy(tmpdir.join("site")) + test_config = pathlib.Path(spack.paths.test_path) / "data" / "config" + shutil.copytree(test_config, tmpdir.join("site")) # Create temporary 'defaults', 'site' and 'user' folders tmpdir.ensure("user", dir=True) - # Slightly modify config.yaml and compilers.yaml - if sys.platform == "win32": - locks = False - else: - locks = True - + # Fill out config.yaml, compilers.yaml and modules.yaml templates. solver = os.environ.get("SPACK_TEST_SOLVER", "clingo") - config_yaml = test_config.join("config.yaml") - modules_root = tmpdir_factory.mktemp("share") - tcl_root = modules_root.ensure("modules", dir=True) - lmod_root = modules_root.ensure("lmod", dir=True) - content = "".join(config_yaml.read()).format(solver, locks, str(tcl_root), str(lmod_root)) - t = tmpdir.join("site", "config.yaml") - t.write(content) - - compilers_yaml = test_config.join("compilers.yaml") - content = "".join(compilers_yaml.read()).format(linux_os) - t = tmpdir.join("site", "compilers.yaml") - t.write(content) + locks = sys.platform != "win32" + config = tmpdir.join("site", "config.yaml") + config_template = test_config / "config.yaml" + config.write(config_template.read_text().format(install_tree_root, solver, locks)) + + target = str(archspec.cpu.host().family) + compilers = tmpdir.join("site", "compilers.yaml") + compilers_template = test_config / "compilers.yaml" + compilers.write(compilers_template.read_text().format(linux_os=linux_os, target=target)) + + modules = tmpdir.join("site", "modules.yaml") + modules_template = test_config / "modules.yaml" + modules.write(modules_template.read_text().format(tcl_root, lmod_root)) yield tmpdir @@ -720,9 +725,9 @@ def _create_mock_configuration_scopes(configuration_dir): """Create the configuration scopes used in `config` and `mutable_config`.""" return [ spack.config.InternalConfigScope("_builtin", spack.config.CONFIG_DEFAULTS), - spack.config.ConfigScope("site", str(configuration_dir.join("site"))), - spack.config.ConfigScope("system", str(configuration_dir.join("system"))), - spack.config.ConfigScope("user", str(configuration_dir.join("user"))), + spack.config.DirectoryConfigScope("site", str(configuration_dir.join("site"))), + spack.config.DirectoryConfigScope("system", str(configuration_dir.join("system"))), + spack.config.DirectoryConfigScope("user", str(configuration_dir.join("user"))), spack.config.InternalConfigScope("command_line"), ] @@ -756,7 +761,7 @@ def mutable_empty_config(tmpdir_factory, configuration_dir): """Empty configuration that can be modified by the tests.""" mutable_dir = tmpdir_factory.mktemp("mutable_config").join("tmp") scopes = [ - spack.config.ConfigScope(name, str(mutable_dir.join(name))) + spack.config.DirectoryConfigScope(name, str(mutable_dir.join(name))) for name in ["site", "system", "user"] ] @@ -764,12 +769,34 @@ def mutable_empty_config(tmpdir_factory, configuration_dir): yield cfg +# From https://github.com/pytest-dev/pytest/issues/363#issuecomment-1335631998 +# Current suggested implementation from issue compatible with pytest >= 6.2 +# this may be subject to change as new versions of Pytest are released +# and update the suggested solution +@pytest.fixture(scope="session") +def monkeypatch_session(): + with pytest.MonkeyPatch.context() as monkeypatch: + yield monkeypatch + + +@pytest.fixture(scope="session", autouse=True) +def mock_wsdk_externals(monkeypatch_session): + """Skip check for required external packages on Windows during testing + Note: In general this should cover this behavior for all tests, + however any session scoped fixture involving concretization should + include this fixture + """ + monkeypatch_session.setattr( + spack.bootstrap.core, "ensure_winsdk_external_or_raise", _return_none + ) + + @pytest.fixture(scope="function") def concretize_scope(mutable_config, tmpdir): """Adds a scope for concretization preferences""" tmpdir.ensure_dir("concretize") mutable_config.push_scope( - spack.config.ConfigScope("concretize", str(tmpdir.join("concretize"))) + spack.config.DirectoryConfigScope("concretize", str(tmpdir.join("concretize"))) ) yield str(tmpdir.join("concretize")) @@ -781,18 +808,21 @@ def concretize_scope(mutable_config, tmpdir): @pytest.fixture def no_compilers_yaml(mutable_config): """Creates a temporary configuration without compilers.yaml""" - for scope, local_config in mutable_config.scopes.items(): - if not local_config.path: # skip internal scopes + for local_config in mutable_config.scopes.values(): + if not isinstance(local_config, spack.config.DirectoryConfigScope): continue - compilers_yaml = os.path.join(local_config.path, "compilers.yaml") + compilers_yaml = local_config.get_section_filename("compilers") if os.path.exists(compilers_yaml): os.remove(compilers_yaml) + return mutable_config @pytest.fixture() def mock_low_high_config(tmpdir): """Mocks two configuration scopes: 'low' and 'high'.""" - scopes = [spack.config.ConfigScope(name, str(tmpdir.join(name))) for name in ["low", "high"]] + scopes = [ + spack.config.DirectoryConfigScope(name, str(tmpdir.join(name))) for name in ["low", "high"] + ] with spack.config.use_configuration(*scopes) as config: yield config @@ -827,7 +857,7 @@ def _install(spec): _install("mpileaks ^mpich") _install("mpileaks ^mpich2") _install("mpileaks ^zmpi") - _install("externaltest") + _install("externaltest ^externalvirtual") _install("trivial-smoke-test") @@ -842,7 +872,13 @@ def _store_dir_and_cache(tmpdir_factory): @pytest.fixture(scope="session") -def mock_store(tmpdir_factory, mock_repo_path, mock_configuration_scopes, _store_dir_and_cache): +def mock_store( + tmpdir_factory, + mock_wsdk_externals, + mock_repo_path, + mock_configuration_scopes, + _store_dir_and_cache, +): """Creates a read-only mock database with some packages installed note that the ref count for dyninst here will be 3, as it's recycled across each install. @@ -929,26 +965,16 @@ def dirs_with_libfiles(tmpdir_factory): yield lib_to_dirs, all_dirs -def _compiler_link_paths_noop(*args): - return [] +def _return_none(*args): + return None @pytest.fixture(scope="function", autouse=True) def disable_compiler_execution(monkeypatch, request): - """ - This fixture can be disabled for tests of the compiler link path - functionality by:: - - @pytest.mark.enable_compiler_link_paths - - If a test is marked in that way this is a no-op.""" - if "enable_compiler_link_paths" not in request.keywords: - # Compiler.determine_implicit_rpaths actually runs the compiler. So - # replace that function with a noop that simulates finding no implicit - # RPATHs - monkeypatch.setattr( - spack.compiler.Compiler, "_get_compiler_link_paths", _compiler_link_paths_noop - ) + """Disable compiler execution to determine implicit link paths and libc flavor and version. + To re-enable use `@pytest.mark.enable_compiler_execution`""" + if "enable_compiler_execution" not in request.keywords: + monkeypatch.setattr(spack.compiler.Compiler, "_compile_dummy_c_source", _return_none) @pytest.fixture(scope="function") @@ -972,19 +998,6 @@ def temporary_store(tmpdir, request): temporary_store_path.remove() -@pytest.fixture(scope="function") -def install_mockery_mutable_config(temporary_store, mutable_config, mock_packages): - """Hooks a fake install directory, DB, and stage directory into Spack. - - This is specifically for tests which want to use 'install_mockery' but - also need to modify configuration (and hence would want to use - 'mutable config'): 'install_mockery' does not support this. - """ - # We use a fake package, so temporarily disable checksumming - with spack.config.override("config:checksum", False): - yield - - @pytest.fixture() def mock_fetch(mock_archive, monkeypatch): """Fake the URL for a package so it downloads from a file.""" @@ -1436,6 +1449,15 @@ def mock_git_repository(git, tmpdir_factory): yield t +@pytest.fixture(scope="function") +def mock_git_test_package(mock_git_repository, mutable_mock_repo, monkeypatch): + # install a fake git version in the package class + pkg_class = spack.repo.PATH.get_pkg_class("git-test") + monkeypatch.delattr(pkg_class, "git") + monkeypatch.setitem(pkg_class.versions, spack.version.Version("git"), mock_git_repository.url) + return pkg_class + + @pytest.fixture(scope="session") def mock_hg_repository(tmpdir_factory): """Creates a very simple hg repository with two commits.""" @@ -1667,7 +1689,7 @@ def mock_executable(tmp_path): """Factory to create a mock executable in a temporary directory that output a custom string when run. """ - shebang = "#!/bin/sh\n" if sys.platform != "win32" else "@ECHO OFF" + shebang = "#!/bin/sh\n" if sys.platform != "win32" else "@ECHO OFF\n" def _factory(name, output, subdir=("bin",)): executable_dir = tmp_path.joinpath(*subdir) @@ -1675,7 +1697,7 @@ def _factory(name, output, subdir=("bin",)): executable_path = executable_dir / name if sys.platform == "win32": executable_path = executable_dir / (name + ".bat") - executable_path.write_text(f"{ shebang }{ output }\n") + executable_path.write_text(f"{shebang}{output}\n") executable_path.chmod(0o755) return executable_path @@ -1967,17 +1989,24 @@ def mock_modules_root(tmp_path, monkeypatch): monkeypatch.setattr(spack.modules.common, "root_path", fn) +_repo_name_id = 0 + + def create_test_repo(tmpdir, pkg_name_content_tuples): + global _repo_name_id + repo_path = str(tmpdir) repo_yaml = tmpdir.join("repo.yaml") with open(str(repo_yaml), "w") as f: f.write( - """\ + f"""\ repo: - namespace: testcfgrequirements + namespace: testrepo{str(_repo_name_id)} """ ) + _repo_name_id += 1 + packages_dir = tmpdir.join("packages") for pkg_name, pkg_str in pkg_name_content_tuples: pkg_dir = packages_dir.ensure(pkg_name, dir=True) @@ -1985,4 +2014,53 @@ def create_test_repo(tmpdir, pkg_name_content_tuples): with open(str(pkg_file), "w") as f: f.write(pkg_str) - return spack.repo.Repo(repo_path) + repo_cache = spack.util.file_cache.FileCache(str(tmpdir.join("cache"))) + return spack.repo.Repo(repo_path, cache=repo_cache) + + +@pytest.fixture() +def compiler_factory(): + """Factory for a compiler dict, taking a spec and an OS as arguments.""" + + def _factory(*, spec, operating_system): + return { + "compiler": { + "spec": spec, + "operating_system": operating_system, + "paths": {"cc": "/path/to/cc", "cxx": "/path/to/cxx", "f77": None, "fc": None}, + "modules": [], + "target": str(archspec.cpu.host().family), + } + } + + return _factory + + +@pytest.fixture() +def host_architecture_str(): + """Returns the broad architecture family (x86_64, aarch64, etc.)""" + return str(archspec.cpu.host().family) + + +def _true(x): + return True + + +@pytest.fixture() +def do_not_check_runtimes_on_reuse(monkeypatch): + monkeypatch.setattr(spack.solver.asp, "_has_runtime_dependencies", _true) + + +@pytest.fixture(autouse=True, scope="session") +def _c_compiler_always_exists(): + fn = spack.solver.asp.c_compiler_runs + spack.solver.asp.c_compiler_runs = _true + yield + spack.solver.asp.c_compiler_runs = fn + + +@pytest.fixture(scope="session") +def mock_test_cache(tmp_path_factory): + cache_dir = tmp_path_factory.mktemp("cache") + print(cache_dir) + return spack.util.file_cache.FileCache(str(cache_dir)) diff --git a/lib/spack/spack/test/container/cli.py b/lib/spack/spack/test/container/cli.py index bbd111b81eb258..3cb4ed05a8b8bc 100644 --- a/lib/spack/spack/test/container/cli.py +++ b/lib/spack/spack/test/container/cli.py @@ -17,7 +17,7 @@ def test_command(default_config, container_config_dir, capsys): with capsys.disabled(): with fs.working_dir(container_config_dir): output = containerize() - assert "FROM spack/ubuntu-bionic" in output + assert "FROM spack/ubuntu-jammy" in output def test_listing_possible_os(): diff --git a/lib/spack/spack/test/container/conftest.py b/lib/spack/spack/test/container/conftest.py index 974fe4438bf382..95782365a9594c 100644 --- a/lib/spack/spack/test/container/conftest.py +++ b/lib/spack/spack/test/container/conftest.py @@ -14,7 +14,7 @@ def minimal_configuration(): "specs": ["gromacs", "mpich", "fftw precision=float"], "container": { "format": "docker", - "images": {"os": "ubuntu:18.04", "spack": "develop"}, + "images": {"os": "ubuntu:22.04", "spack": "develop"}, }, } } diff --git a/lib/spack/spack/test/container/docker.py b/lib/spack/spack/test/container/docker.py index 220605b568eb7a..e631f6b486827d 100644 --- a/lib/spack/spack/test/container/docker.py +++ b/lib/spack/spack/test/container/docker.py @@ -21,11 +21,11 @@ def test_build_and_run_images(minimal_configuration): # Test the output of run property run = writer.run - assert run.image == "ubuntu:18.04" + assert run.image == "ubuntu:22.04" # Test the output of the build property build = writer.build - assert build.image == "spack/ubuntu-bionic:develop" + assert build.image == "spack/ubuntu-jammy:develop" def test_packages(minimal_configuration): diff --git a/lib/spack/spack/test/container/images.py b/lib/spack/spack/test/container/images.py index 7f5d8feb897f53..faac9d0c8e8747 100644 --- a/lib/spack/spack/test/container/images.py +++ b/lib/spack/spack/test/container/images.py @@ -12,8 +12,8 @@ @pytest.mark.parametrize( "image,spack_version,expected", [ - ("ubuntu:18.04", "develop", ("spack/ubuntu-bionic", "develop")), - ("ubuntu:18.04", "0.14.0", ("spack/ubuntu-bionic", "0.14.0")), + ("ubuntu:22.04", "develop", ("spack/ubuntu-jammy", "develop")), + ("ubuntu:22.04", "0.14.0", ("spack/ubuntu-jammy", "0.14.0")), ], ) def test_build_info(image, spack_version, expected): @@ -21,7 +21,7 @@ def test_build_info(image, spack_version, expected): assert output == expected -@pytest.mark.parametrize("image", ["ubuntu:18.04"]) +@pytest.mark.parametrize("image", ["ubuntu:22.04"]) def test_package_info(image): pkg_manager = spack.container.images.os_package_manager_for(image) update, install, clean = spack.container.images.commands_for(pkg_manager) diff --git a/lib/spack/spack/test/data/config/compilers.yaml b/lib/spack/spack/test/data/config/compilers.yaml index 6f36c13b59348f..0d5345130ac577 100644 --- a/lib/spack/spack/test/data/config/compilers.yaml +++ b/lib/spack/spack/test/data/config/compilers.yaml @@ -1,353 +1,41 @@ compilers: - compiler: - spec: clang@3.3 - operating_system: {0.name}{0.version} - paths: - cc: /path/to/clang - cxx: /path/to/clang++ - f77: None - fc: None - modules: 'None' - target: x86_64 -- compiler: - spec: gcc@4.5.0 - operating_system: {0.name}{0.version} - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: None - fc: None - modules: 'None' - target: x86_64 -- compiler: - spec: gcc@4.5.0 - operating_system: redhat6 - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: None - fc: None - modules: 'None' - target: x86_64 -- compiler: - spec: clang@3.3 - operating_system: CNL - paths: - cc: /path/to/clang - cxx: /path/to/clang++ - f77: None - fc: None - modules: 'None' -- compiler: - spec: clang@3.3 - operating_system: SuSE11 - paths: - cc: /path/to/clang - cxx: /path/to/clang++ - f77: None - fc: None - modules: 'None' - target: x86_64 -- compiler: - spec: clang@3.3 - operating_system: yosemite - paths: - cc: /path/to/clang - cxx: /path/to/clang++ - f77: None - fc: None - modules: 'None' - target: x86_64 -- compiler: - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: /path/to/gfortran - fc: /path/to/gfortran - operating_system: CNL - spec: gcc@4.5.0 - modules: 'None' -- compiler: - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: /path/to/gfortran - fc: /path/to/gfortran - operating_system: SuSE11 - spec: gcc@4.5.0 - modules: 'None' - target: x86_64 -- compiler: - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: /path/to/gfortran - fc: /path/to/gfortran - operating_system: yosemite - spec: gcc@4.5.0 - modules: 'None' - target: x86_64 -- compiler: - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: /path/to/gfortran - fc: /path/to/gfortran - operating_system: elcapitan - spec: gcc@4.5.0 - modules: 'None' - target: x86_64 -- compiler: - spec: clang@3.3 - operating_system: elcapitan - paths: - cc: /path/to/clang - cxx: /path/to/clang++ - f77: None - fc: None - modules: 'None' - target: x86_64 -- compiler: - spec: gcc@4.7.2 - operating_system: redhat6 - paths: - cc: /path/to/gcc472 - cxx: /path/to/g++472 - f77: /path/to/gfortran472 - fc: /path/to/gfortran472 - flags: - cflags: -O0 -g - cxxflags: -O0 -g - fflags: -O0 -g - modules: 'None' - target: x86_64 -- compiler: - spec: gcc@4.4.0 - operating_system: redhat6 - paths: - cc: /path/to/gcc440 - cxx: /path/to/g++440 - f77: /path/to/gfortran440 - fc: /path/to/gfortran440 - modules: 'None' - target: x86_64 -- compiler: - spec: clang@3.5 - operating_system: redhat6 - paths: - cc: /path/to/clang35 - cxx: /path/to/clang++35 - f77: None - fc: None - flags: - cflags: -O3 - cxxflags: -O3 - modules: 'None' - target: x86_64 -- compiler: - spec: clang@8.0.0 - operating_system: redhat7 - paths: - cc: /path/to/clang-8 - cxx: /path/to/clang++-8 - f77: /path/to/gfortran-9 - fc: /path/to/gfortran-9 - flags: - cflags: -O3 - cxxflags: -O3 - modules: 'None' - target: x86_64 -- compiler: - spec: apple-clang@9.1.0 - operating_system: elcapitan - paths: - cc: /path/to/clang - cxx: /path/to/clang++ - f77: None - fc: None - modules: 'None' - target: x86_64 -- compiler: - spec: gcc@10foo - operating_system: redhat6 - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: /path/to/gfortran - fc: /path/to/gfortran - modules: 'None' - target: x86_64 -- compiler: - spec: gcc@4.4.0-special - operating_system: redhat6 - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: /path/to/gfortran - fc: /path/to/gfortran - modules: 'None' - target: x86_64 -- compiler: - spec: clang@12.0.0 - operating_system: {0.name}{0.version} - paths: - cc: /path/to/clang - cxx: /path/to/clang++ - f77: None - fc: None - modules: 'None' - target: aarch64 -- compiler: - spec: gcc@10.2.1 - operating_system: {0.name}{0.version} - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: None - fc: None - modules: 'None' - target: aarch64 -- compiler: - spec: clang@12.0.0 - operating_system: redhat6 - paths: - cc: /path/to/clang - cxx: /path/to/clang++ - f77: None - fc: None - modules: 'None' - target: aarch64 -- compiler: - spec: gcc@10.2.1 - operating_system: redhat6 - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: None - fc: None - modules: 'None' - target: aarch64 -- compiler: - spec: gcc@10.1.0 - operating_system: redhat6 + spec: gcc@=9.4.0 + operating_system: {linux_os.name}{linux_os.version} paths: cc: /path/to/gcc cxx: /path/to/g++ f77: None fc: None - modules: 'None' - target: aarch64 + modules: [] + target: {target} - compiler: - spec: gcc@11.1.0 + spec: gcc@=9.4.0 operating_system: redhat6 paths: cc: /path/to/gcc cxx: /path/to/g++ f77: None fc: None - flags: - cflags: -O0 -g - cxxflags: -O0 -g - fflags: -O0 -g - modules: 'None' - target: aarch64 + modules: [] + target: {target} - compiler: - spec: clang@12.2.0 - operating_system: redhat6 - paths: - cc: /path/to/clang35 - cxx: /path/to/clang++35 - f77: None - fc: None - flags: - cflags: -O3 - cxxflags: -O3 - modules: 'None' - target: aarch64 -- compiler: - spec: gcc@10foo - operating_system: redhat6 - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: /path/to/gfortran - fc: /path/to/gfortran - modules: 'None' - target: aarch64 -- compiler: - spec: clang@12.0.0 - operating_system: {0.name}{0.version} - paths: - cc: /path/to/clang - cxx: /path/to/clang++ - f77: None - fc: None - modules: 'None' - target: x86_64 -- compiler: - spec: gcc@10.2.1 - operating_system: {0.name}{0.version} - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: None - fc: None - modules: 'None' - target: x86_64 -- compiler: - spec: clang@12.0.0 - operating_system: redhat6 + spec: clang@=15.0.0 + operating_system: {linux_os.name}{linux_os.version} paths: cc: /path/to/clang cxx: /path/to/clang++ f77: None fc: None - modules: 'None' - target: x86_64 + modules: [] + target: {target} - compiler: - spec: gcc@10.2.1 - operating_system: redhat6 + spec: gcc@=10.2.1 + operating_system: {linux_os.name}{linux_os.version} paths: cc: /path/to/gcc cxx: /path/to/g++ f77: None fc: None - modules: 'None' - target: x86_64 -- compiler: - spec: gcc@10.1.0 - operating_system: redhat6 - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: None - fc: None - modules: 'None' - target: x86_64 -- compiler: - spec: gcc@11.1.0 - operating_system: redhat6 - paths: - cc: /path/to/gcc - cxx: /path/to/g++ - f77: None - fc: None - flags: - cflags: -O0 -g - cxxflags: -O0 -g - fflags: -O0 -g - modules: 'None' - target: x86_64 -- compiler: - spec: clang@12.2.0 - operating_system: redhat6 - paths: - cc: /path/to/clang35 - cxx: /path/to/clang++35 - f77: None - fc: None - flags: - cflags: -O3 - cxxflags: -O3 - modules: 'None' - target: x86_64 + modules: [] + target: {target} diff --git a/lib/spack/spack/test/data/config/concretizer.yaml b/lib/spack/spack/test/data/config/concretizer.yaml index 0dd810163dd77a..a89a42a90660d0 100644 --- a/lib/spack/spack/test/data/config/concretizer.yaml +++ b/lib/spack/spack/test/data/config/concretizer.yaml @@ -1,5 +1,5 @@ concretizer: - # reuse is missing on purpose, see "test_concretizer_arguments" + reuse: true targets: granularity: microarchitectures host_compatible: false diff --git a/lib/spack/spack/test/data/config/config.yaml b/lib/spack/spack/test/data/config/config.yaml index 0ae86957dbb3e2..4a8da4e25f61da 100644 --- a/lib/spack/spack/test/data/config/config.yaml +++ b/lib/spack/spack/test/data/config/config.yaml @@ -1,6 +1,6 @@ config: install_tree: - root: $spack/opt/spack + root: {0} template_dirs: - $spack/share/spack/templates - $spack/lib/spack/spack/test/data/templates @@ -10,7 +10,8 @@ config: source_cache: $user_cache_path/source misc_cache: $user_cache_path/cache verify_ssl: true + ssl_certs: $SSL_CERT_FILE checksum: true dirty: false - concretizer: {0} - locks: {1} + concretizer: {1} + locks: {2} diff --git a/lib/spack/spack/test/data/config/modules.yaml b/lib/spack/spack/test/data/config/modules.yaml index f217dd7eaf3379..bd19ca066aa627 100644 --- a/lib/spack/spack/test/data/config/modules.yaml +++ b/lib/spack/spack/test/data/config/modules.yaml @@ -14,29 +14,25 @@ # ~/.spack/modules.yaml # ------------------------------------------------------------------------- modules: - default: {} prefix_inspections: - bin: - - PATH - man: - - MANPATH - share/man: - - MANPATH - share/aclocal: - - ACLOCAL_PATH - lib: - - LIBRARY_PATH - - LD_LIBRARY_PATH - lib64: - - LIBRARY_PATH - - LD_LIBRARY_PATH - include: - - CPATH - lib/pkgconfig: - - PKG_CONFIG_PATH - lib64/pkgconfig: - - PKG_CONFIG_PATH - share/pkgconfig: - - PKG_CONFIG_PATH - '': - - CMAKE_PREFIX_PATH + ./bin: [PATH] + ./man: [MANPATH] + ./share/man: [MANPATH] + ./share/aclocal: [ACLOCAL_PATH] + ./lib/pkgconfig: [PKG_CONFIG_PATH] + ./lib64/pkgconfig: [PKG_CONFIG_PATH] + ./share/pkgconfig: [PKG_CONFIG_PATH] + ./: [CMAKE_PREFIX_PATH] + default: + roots: + tcl: {0} + lmod: {1} + enable: [] + tcl: + all: + autoload: direct + lmod: + all: + autoload: direct + hierarchy: + - mpi diff --git a/lib/spack/spack/test/data/config/packages.yaml b/lib/spack/spack/test/data/config/packages.yaml index c6ff731a7e5bda..25fbe888c5e300 100644 --- a/lib/spack/spack/test/data/config/packages.yaml +++ b/lib/spack/spack/test/data/config/packages.yaml @@ -1,5 +1,6 @@ packages: all: + compiler: [gcc, clang] providers: mpi: [openmpi, mpich, zmpi] lapack: [openblas-with-lapack] @@ -16,7 +17,7 @@ packages: externalvirtual: buildable: False externals: - - spec: externalvirtual@2.0%clang@12.0.0 + - spec: externalvirtual@2.0%clang@15.0.0 prefix: /path/to/external_virtual_clang - spec: externalvirtual@1.0%gcc@10.2.1 prefix: /path/to/external_virtual_gcc diff --git a/lib/spack/spack/test/data/modules/lmod/complex_hierarchy.yaml b/lib/spack/spack/test/data/modules/lmod/complex_hierarchy.yaml index 39515b3856014b..91adfd92e63e73 100644 --- a/lib/spack/spack/test/data/modules/lmod/complex_hierarchy.yaml +++ b/lib/spack/spack/test/data/modules/lmod/complex_hierarchy.yaml @@ -4,7 +4,7 @@ lmod: hash_length: 0 core_compilers: - - 'clang@12.0.0' + - 'clang@15.0.0' core_specs: - 'mpich@3.0.1' diff --git a/lib/spack/spack/test/data/modules/lmod/core_compilers.yaml b/lib/spack/spack/test/data/modules/lmod/core_compilers.yaml index 60d461d10af1eb..0070f42bec5ba4 100644 --- a/lib/spack/spack/test/data/modules/lmod/core_compilers.yaml +++ b/lib/spack/spack/test/data/modules/lmod/core_compilers.yaml @@ -2,4 +2,4 @@ enable: - lmod lmod: core_compilers: - - 'clang@12.0.0' + - 'clang@15.0.0' diff --git a/lib/spack/spack/test/data/modules/lmod/core_compilers_at_equal.yaml b/lib/spack/spack/test/data/modules/lmod/core_compilers_at_equal.yaml index d4b22dccf13929..5a69c98bb5e035 100644 --- a/lib/spack/spack/test/data/modules/lmod/core_compilers_at_equal.yaml +++ b/lib/spack/spack/test/data/modules/lmod/core_compilers_at_equal.yaml @@ -2,4 +2,4 @@ enable: - lmod lmod: core_compilers: - - 'clang@=12.0.0' + - 'clang@=15.0.0' diff --git a/lib/spack/spack/test/database.py b/lib/spack/spack/test/database.py index e02f5495321ab4..91eab857f41b41 100644 --- a/lib/spack/spack/test/database.py +++ b/lib/spack/spack/test/database.py @@ -56,17 +56,43 @@ def upstream_and_downstream_db(tmpdir, gen_mock_layout): yield upstream_write_db, upstream_db, upstream_layout, downstream_db, downstream_layout +@pytest.mark.parametrize( + "install_tree,result", + [ + ("all", ["pkg-b", "pkg-c"]), + ("upstream", ["pkg-c"]), + ("local", ["pkg-b"]), + ("{u}", ["pkg-c"]), + ("{d}", ["pkg-b"]), + ], +) +def test_query_by_install_tree( + install_tree, result, upstream_and_downstream_db, mock_packages, monkeypatch, config +): + up_write_db, up_db, up_layout, down_db, down_layout = upstream_and_downstream_db + + # Set the upstream DB to contain "pkg-c" and downstream to contain "pkg-b") + b = spack.spec.Spec("pkg-b").concretized() + c = spack.spec.Spec("pkg-c").concretized() + up_write_db.add(c, up_layout) + up_db._read() + down_db.add(b, down_layout) + + specs = down_db.query(install_tree=install_tree.format(u=up_db.root, d=down_db.root)) + assert [s.name for s in specs] == result + + def test_spec_installed_upstream( upstream_and_downstream_db, mock_custom_repository, config, monkeypatch ): """Test whether Spec.installed_upstream() works.""" - (upstream_write_db, upstream_db, upstream_layout, downstream_db, downstream_layout) = ( + upstream_write_db, upstream_db, upstream_layout, downstream_db, downstream_layout = ( upstream_and_downstream_db ) # a known installed spec should say that it's installed with spack.repo.use_repositories(mock_custom_repository): - spec = spack.spec.Spec("c").concretized() + spec = spack.spec.Spec("pkg-c").concretized() assert not spec.installed assert not spec.installed_upstream @@ -86,7 +112,7 @@ def test_spec_installed_upstream( @pytest.mark.usefixtures("config") def test_installed_upstream(upstream_and_downstream_db, tmpdir): - (upstream_write_db, upstream_db, upstream_layout, downstream_db, downstream_layout) = ( + upstream_write_db, upstream_db, upstream_layout, downstream_db, downstream_layout = ( upstream_and_downstream_db ) @@ -124,7 +150,7 @@ def test_installed_upstream(upstream_and_downstream_db, tmpdir): @pytest.mark.usefixtures("config") def test_removed_upstream_dep(upstream_and_downstream_db, tmpdir): - (upstream_write_db, upstream_db, upstream_layout, downstream_db, downstream_layout) = ( + upstream_write_db, upstream_db, upstream_layout, downstream_db, downstream_layout = ( upstream_and_downstream_db ) @@ -156,7 +182,7 @@ def test_add_to_upstream_after_downstream(upstream_and_downstream_db, tmpdir): DB. When a package is recorded as installed in both, the results should refer to the downstream DB. """ - (upstream_write_db, upstream_db, upstream_layout, downstream_db, downstream_layout) = ( + upstream_write_db, upstream_db, upstream_layout, downstream_db, downstream_layout = ( upstream_and_downstream_db ) @@ -828,7 +854,7 @@ def test_query_virtual_spec(database): def test_failed_spec_path_error(database): """Ensure spec not concrete check is covered.""" - s = spack.spec.Spec("a") + s = spack.spec.Spec("pkg-a") with pytest.raises(AssertionError, match="concrete spec required"): spack.store.STORE.failure_tracker.mark(s) @@ -843,14 +869,14 @@ def _is(self, spec): # Pretend the spec has been failure locked monkeypatch.setattr(spack.database.FailureTracker, "lock_taken", _is) - s = spack.spec.Spec("a").concretized() + s = spack.spec.Spec("pkg-a").concretized() spack.store.STORE.failure_tracker.clear(s) out = capfd.readouterr()[0] assert "Retaining failure marking" in out @pytest.mark.db -def test_clear_failure_forced(default_mock_concretization, mutable_database, monkeypatch, capfd): +def test_clear_failure_forced(mutable_database, monkeypatch, capfd): """Add test coverage for clear_failure operation when force.""" def _is(self, spec): @@ -861,7 +887,7 @@ def _is(self, spec): # Ensure raise OSError when try to remove the non-existent marking monkeypatch.setattr(spack.database.FailureTracker, "persistent_mark", _is) - s = default_mock_concretization("a") + s = spack.spec.Spec("pkg-a").concretized() spack.store.STORE.failure_tracker.clear(s, force=True) out = capfd.readouterr()[1] assert "Removing failure marking despite lock" in out @@ -869,30 +895,30 @@ def _is(self, spec): @pytest.mark.db -def test_mark_failed(default_mock_concretization, mutable_database, monkeypatch, tmpdir, capsys): +def test_mark_failed(mutable_database, monkeypatch, tmpdir, capsys): """Add coverage to mark_failed.""" def _raise_exc(lock): raise lk.LockTimeoutError("write", "/mock-lock", 1.234, 10) - # Ensure attempt to acquire write lock on the mark raises the exception - monkeypatch.setattr(lk.Lock, "acquire_write", _raise_exc) - with tmpdir.as_cwd(): - s = default_mock_concretization("a") - spack.store.STORE.failure_tracker.mark(s) + s = spack.spec.Spec("pkg-a").concretized() + + # Ensure attempt to acquire write lock on the mark raises the exception + monkeypatch.setattr(lk.Lock, "acquire_write", _raise_exc) + spack.store.STORE.failure_tracker.mark(s) out = str(capsys.readouterr()[1]) - assert "Unable to mark a as failed" in out + assert "Unable to mark pkg-a as failed" in out spack.store.STORE.failure_tracker.clear_all() @pytest.mark.db -def test_prefix_failed(default_mock_concretization, mutable_database, monkeypatch): +def test_prefix_failed(mutable_database, monkeypatch): """Add coverage to failed operation.""" - s = default_mock_concretization("a") + s = spack.spec.Spec("pkg-a").concretized() # Confirm the spec is not already marked as failed assert not spack.store.STORE.failure_tracker.has_failed(s) @@ -910,13 +936,13 @@ def test_prefix_failed(default_mock_concretization, mutable_database, monkeypatc assert spack.store.STORE.failure_tracker.has_failed(s) -def test_prefix_write_lock_error(default_mock_concretization, mutable_database, monkeypatch): +def test_prefix_write_lock_error(mutable_database, monkeypatch): """Cover the prefix write lock exception.""" def _raise(db, spec): raise lk.LockError("Mock lock error") - s = default_mock_concretization("a") + s = spack.spec.Spec("pkg-a").concretized() # Ensure subsequent lock operations fail monkeypatch.setattr(lk.Lock, "acquire_write", _raise) @@ -1086,3 +1112,31 @@ def test_database_construction_doesnt_use_globals(tmpdir, config, nullify_global lock_cfg = lock_cfg or spack.database.lock_configuration(config) db = spack.database.Database(str(tmpdir), lock_cfg=lock_cfg) assert os.path.exists(db.database_directory) + + +def test_database_read_works_with_trailing_data(tmp_path, default_mock_concretization): + # Populate a database + root = str(tmp_path) + db = spack.database.Database(root) + spec = default_mock_concretization("pkg-a") + db.add(spec, directory_layout=None) + specs_in_db = db.query_local() + assert spec in specs_in_db + + # Append anything to the end of the database file + with open(db._index_path, "a") as f: + f.write(json.dumps({"hello": "world"})) + + # Read the database and check that it ignores the trailing data + assert spack.database.Database(root).query_local() == specs_in_db + + +def test_database_errors_with_just_a_version_key(tmp_path): + root = str(tmp_path) + db = spack.database.Database(root) + next_version = f"{spack.database._DB_VERSION}.next" + with open(db._index_path, "w") as f: + f.write(json.dumps({"database": {"version": next_version}})) + + with pytest.raises(spack.database.InvalidDatabaseVersionError): + spack.database.Database(root).query_local() diff --git a/lib/spack/spack/test/directives.py b/lib/spack/spack/test/directives.py index ca7b3b7c7ac882..c941a60049680c 100644 --- a/lib/spack/spack/test/directives.py +++ b/lib/spack/spack/test/directives.py @@ -10,6 +10,7 @@ import spack.repo import spack.spec import spack.version +from spack.test.conftest import create_test_repo def test_false_directives_do_not_exist(mock_packages): @@ -30,7 +31,7 @@ def test_true_directives_exist(mock_packages): assert cls.dependencies assert "extendee" in cls.dependencies[spack.spec.Spec()] - assert "b" in cls.dependencies[spack.spec.Spec()] + assert "pkg-b" in cls.dependencies[spack.spec.Spec()] assert cls.resources assert spack.spec.Spec() in cls.resources @@ -43,7 +44,7 @@ def test_constraints_from_context(mock_packages): pkg_cls = spack.repo.PATH.get_pkg_class("with-constraint-met") assert pkg_cls.dependencies - assert "b" in pkg_cls.dependencies[spack.spec.Spec("@1.0")] + assert "pkg-b" in pkg_cls.dependencies[spack.spec.Spec("@1.0")] assert pkg_cls.conflicts assert (spack.spec.Spec("%gcc"), None) in pkg_cls.conflicts[spack.spec.Spec("+foo@1.0")] @@ -54,7 +55,7 @@ def test_constraints_from_context_are_merged(mock_packages): pkg_cls = spack.repo.PATH.get_pkg_class("with-constraint-met") assert pkg_cls.dependencies - assert "c" in pkg_cls.dependencies[spack.spec.Spec("@0.14:15 ^b@3.8:4.0")] + assert "pkg-c" in pkg_cls.dependencies[spack.spec.Spec("@0.14:15 ^pkg-b@3.8:4.0")] @pytest.mark.regression("27754") @@ -68,9 +69,9 @@ def test_extends_spec(config, mock_packages): @pytest.mark.regression("34368") def test_error_on_anonymous_dependency(config, mock_packages): - pkg = spack.repo.PATH.get_pkg_class("a") + pkg = spack.repo.PATH.get_pkg_class("pkg-a") with pytest.raises(spack.directives.DependencyError): - spack.directives._depends_on(pkg, "@4.5") + spack.directives._depends_on(pkg, spack.spec.Spec("@4.5")) @pytest.mark.regression("34879") @@ -142,3 +143,86 @@ def test_version_type_validation(): # Try passing a bogus type; it's just that we want a nice error message with pytest.raises(spack.version.VersionError, match=msg): spack.directives._execute_version(package(name="python"), {}) + + +_pkgx = ( + "x", + """\ +class X(Package): + version("1.3") + version("1.2") + version("1.1") + version("1.0") + + variant("foo", default=False) + + redistribute(binary=False, when="@1.1") + redistribute(binary=False, when="@1.0:1.2+foo") + redistribute(source=False, when="@1.0:1.2") +""", +) + + +_pkgy = ( + "y", + """\ +class Y(Package): + version("2.1") + version("2.0") + + variant("bar", default=False) + + redistribute(binary=False, source=False) +""", +) + + +@pytest.fixture +def _create_test_repo(tmpdir, mutable_config): + yield create_test_repo(tmpdir, [_pkgx, _pkgy]) + + +@pytest.fixture +def test_repo(_create_test_repo, monkeypatch, mock_stage): + with spack.repo.use_repositories(_create_test_repo) as mock_repo_path: + yield mock_repo_path + + +@pytest.mark.parametrize( + "spec_str,distribute_src,distribute_bin", + [ + ("x@1.1~foo", False, False), + ("x@1.2+foo", False, False), + ("x@1.2~foo", False, True), + ("x@1.0~foo", False, True), + ("x@1.3+foo", True, True), + ("y@2.0", False, False), + ("y@2.1+bar", False, False), + ], +) +def test_redistribute_directive(test_repo, spec_str, distribute_src, distribute_bin): + spec = spack.spec.Spec(spec_str) + assert spec.package_class.redistribute_source(spec) == distribute_src + concretized_spec = spec.concretized() + assert concretized_spec.package.redistribute_binary == distribute_bin + + +def test_redistribute_override_when(): + """Allow a user to call `redistribute` twice to separately disable + source and binary distribution for the same when spec. + + The second call should not undo the effect of the first. + """ + + class MockPackage: + name = "mock" + disable_redistribute = {} + + cls = MockPackage + spack.directives._execute_redistribute(cls, source=False, when="@1.0") + spec_key = spack.directives._make_when_spec("@1.0") + assert not cls.disable_redistribute[spec_key].binary + assert cls.disable_redistribute[spec_key].source + spack.directives._execute_redistribute(cls, binary=False, when="@1.0") + assert cls.disable_redistribute[spec_key].binary + assert cls.disable_redistribute[spec_key].source diff --git a/lib/spack/spack/test/directory_layout.py b/lib/spack/spack/test/directory_layout.py index 6f422818276239..da51de415ea412 100644 --- a/lib/spack/spack/test/directory_layout.py +++ b/lib/spack/spack/test/directory_layout.py @@ -146,7 +146,7 @@ def test_read_and_write_spec(temporary_store, config, mock_packages): assert not os.path.exists(install_dir) -def test_handle_unknown_package(temporary_store, config, mock_packages): +def test_handle_unknown_package(temporary_store, config, mock_packages, tmp_path): """This test ensures that spack can at least do *some* operations with packages that are installed but that it does not know about. This is actually not such an uncommon @@ -158,7 +158,9 @@ def test_handle_unknown_package(temporary_store, config, mock_packages): or query them again if the package goes away. """ layout = temporary_store.layout - mock_db = spack.repo.RepoPath(spack.paths.mock_packages_path) + + repo_cache = spack.util.file_cache.FileCache(str(tmp_path / "cache")) + mock_db = spack.repo.RepoPath(spack.paths.mock_packages_path, cache=repo_cache) not_in_mock = set.difference( set(spack.repo.all_package_names()), set(mock_db.all_package_names()) diff --git a/lib/spack/spack/test/env.py b/lib/spack/spack/test/env.py index 54ac9a3732d58c..46be9ca66c864b 100644 --- a/lib/spack/spack/test/env.py +++ b/lib/spack/spack/test/env.py @@ -96,7 +96,7 @@ def test_env_change_spec(tmp_path, mock_packages, config): """ -def test_env_change_spec_in_definition(tmp_path, mock_packages, config, mutable_mock_env_path): +def test_env_change_spec_in_definition(tmp_path, mock_packages, mutable_mock_env_path): manifest_file = tmp_path / ev.manifest_name manifest_file.write_text(_test_matrix_yaml) e = ev.create("test", manifest_file) @@ -118,9 +118,7 @@ def test_env_change_spec_in_definition(tmp_path, mock_packages, config, mutable_ assert not any(x.intersects("mpileaks@2.1%gcc") for x in e.user_specs) -def test_env_change_spec_in_matrix_raises_error( - tmp_path, mock_packages, config, mutable_mock_env_path -): +def test_env_change_spec_in_matrix_raises_error(tmp_path, mock_packages, mutable_mock_env_path): manifest_file = tmp_path / ev.manifest_name manifest_file.write_text(_test_matrix_yaml) e = ev.create("test", manifest_file) @@ -255,7 +253,7 @@ def test_update_default_view(init_view, update_value, tmp_path, mock_packages, c if isinstance(init_view, str) and update_value is True: expected_value = init_view - assert env.manifest.pristine_yaml_content["spack"]["view"] == expected_value + assert env.manifest.yaml_content["spack"]["view"] == expected_value @pytest.mark.parametrize( @@ -383,10 +381,10 @@ def test_can_add_specs_to_environment_without_specs_attribute(tmp_path, mock_pac """ ) env = ev.Environment(tmp_path) - env.add("a") + env.add("pkg-a") assert len(env.user_specs) == 1 - assert env.manifest.pristine_yaml_content["spack"]["specs"] == ["a"] + assert env.manifest.yaml_content["spack"]["specs"] == ["pkg-a"] @pytest.mark.parametrize( @@ -584,7 +582,7 @@ def test_conflicts_with_packages_that_are_not_dependencies( spack: specs: - {spec_str} - - b + - pkg-b concretizer: unify: true """ @@ -712,7 +710,7 @@ def test_variant_propagation_with_unify_false(tmp_path, mock_packages, config): spack: specs: - parent-foo ++foo - - c + - pkg-c concretizer: unify: false """ @@ -797,10 +795,10 @@ def test_deconcretize_then_concretize_does_not_error(mutable_mock_env_path, mock """spack: specs: # These two specs concretize to the same hash - - c - - c@1.0 + - pkg-c + - pkg-c@1.0 # Spec used to trigger the bug - - a + - pkg-a concretizer: unify: true """ @@ -808,8 +806,63 @@ def test_deconcretize_then_concretize_does_not_error(mutable_mock_env_path, mock e = ev.Environment(mutable_mock_env_path) with e: e.concretize() - e.deconcretize(spack.spec.Spec("a"), concrete=False) + e.deconcretize(spack.spec.Spec("pkg-a"), concrete=False) e.concretize() assert len(e.concrete_roots()) == 3 - all_root_hashes = set(x.dag_hash() for x in e.concrete_roots()) + all_root_hashes = {x.dag_hash() for x in e.concrete_roots()} assert len(all_root_hashes) == 2 + + +@pytest.mark.regression("44216") +@pytest.mark.only_clingo() +def test_root_version_weights_for_old_versions(mutable_mock_env_path, mock_packages): + """Tests that, when we select two old versions of root specs that have the same version + optimization penalty, both are considered. + """ + mutable_mock_env_path.mkdir() + spack_yaml = mutable_mock_env_path / ev.manifest_name + spack_yaml.write_text( + """spack: + specs: + # allow any version, but the most recent + - bowtie@:1.3 + # allows only the third most recent, so penalty is 2 + - gcc@1 + concretizer: + unify: true + """ + ) + e = ev.Environment(mutable_mock_env_path) + with e: + e.concretize() + + bowtie = [x for x in e.concrete_roots() if x.name == "bowtie"][0] + gcc = [x for x in e.concrete_roots() if x.name == "gcc"][0] + + assert bowtie.satisfies("@=1.3.0") + assert gcc.satisfies("@=1.0") + + +def test_env_view_on_empty_dir_is_fine(tmp_path, config, mock_packages, temporary_store): + """Tests that creating a view pointing to an empty dir is not an error.""" + view_dir = tmp_path / "view" + view_dir.mkdir() + env = ev.create_in_dir(tmp_path, with_view="view") + env.add("mpileaks") + env.concretize() + env.install_all(fake=True) + env.regenerate_views() + assert view_dir.is_symlink() + + +def test_env_view_on_non_empty_dir_errors(tmp_path, config, mock_packages, temporary_store): + """Tests that creating a view pointing to a non-empty dir errors.""" + view_dir = tmp_path / "view" + view_dir.mkdir() + (view_dir / "file").write_text("") + env = ev.create_in_dir(tmp_path, with_view="view") + env.add("mpileaks") + env.concretize() + env.install_all(fake=True) + with pytest.raises(ev.SpackEnvironmentError, match="because it is a non-empty dir"): + env.regenerate_views() diff --git a/lib/spack/spack/test/installer.py b/lib/spack/spack/test/installer.py index ebe5ec0e0021ae..1ca3982dd6ca5d 100644 --- a/lib/spack/spack/test/installer.py +++ b/lib/spack/spack/test/installer.py @@ -7,10 +7,13 @@ import os import shutil import sys +from typing import List, Optional, Union import py import pytest +import archspec.cpu + import llnl.util.filesystem as fs import llnl.util.lock as ulk import llnl.util.tty as tty @@ -42,12 +45,10 @@ def _mock_repo(root, namespace): repodir.ensure(spack.repo.packages_dir_name, dir=True) yaml = repodir.join("repo.yaml") yaml.write( - """ + f""" repo: - namespace: {0} -""".format( - namespace - ) + namespace: {namespace} +""" ) @@ -71,53 +72,21 @@ def _true(*args, **kwargs): return True -def create_build_task(pkg, install_args={}): - """ - Create a built task for the given (concretized) package - - Args: - pkg (spack.package_base.PackageBase): concretized package associated with - the task - install_args (dict): dictionary of kwargs (or install args) - - Return: - (BuildTask) A basic package build task - """ - request = inst.BuildRequest(pkg, install_args) - return inst.BuildTask(pkg, request, False, 0, 0, inst.STATUS_ADDED, []) - - -def create_installer(installer_args): - """ - Create an installer using the concretized spec for each arg - - Args: - installer_args (list): the list of (spec name, kwargs) tuples - - Return: - spack.installer.PackageInstaller: the associated package installer - """ - const_arg = [(spec.package, kwargs) for spec, kwargs in installer_args] - return inst.PackageInstaller(const_arg) - - -def installer_args(spec_names, kwargs={}): - """Return a the installer argument with each spec paired with kwargs +def create_build_task( + pkg: spack.package_base.PackageBase, install_args: Optional[dict] = None +) -> inst.BuildTask: + request = inst.BuildRequest(pkg, {} if install_args is None else install_args) + return inst.BuildTask(pkg, request, False, 0, 0, inst.STATUS_ADDED, set()) - Args: - spec_names (list): list of spec names - kwargs (dict or None): install arguments to apply to all of the specs - Returns: - list: list of (spec, kwargs), the installer constructor argument - """ - arg = [] - for name in spec_names: - spec = spack.spec.Spec(name) - spec.concretize() - assert spec.concrete - arg.append((spec, kwargs)) - return arg +def create_installer( + specs: Union[List[str], List[spack.spec.Spec]], install_args: Optional[dict] = None +) -> inst.PackageInstaller: + """Create an installer instance for a list of specs or package names that will be + concretized.""" + _specs = [spack.spec.Spec(s).concretized() if isinstance(s, str) else s for s in specs] + _install_args = {} if install_args is None else install_args + return inst.PackageInstaller([spec.package for spec in _specs], _install_args) @pytest.mark.parametrize( @@ -130,11 +99,11 @@ def test_hms(sec, result): def test_get_dependent_ids(install_mockery, mock_packages): # Concretize the parent package, which handle dependency too - spec = spack.spec.Spec("a") + spec = spack.spec.Spec("pkg-a") spec.concretize() assert spec.concrete - pkg_id = inst.package_id(spec.package) + pkg_id = inst.package_id(spec) # Grab the sole dependency of 'a', which is 'b' dep = spec.dependencies()[0] @@ -221,11 +190,11 @@ def _spec(spec, unsigned=False, mirrors_for_spec=None): # Skip database updates monkeypatch.setattr(spack.database.Database, "add", _noop) - spec = spack.spec.Spec("a").concretized() + spec = spack.spec.Spec("pkg-a").concretized() assert inst._process_binary_cache_tarball(spec.package, explicit=False, unsigned=False) out = capfd.readouterr()[0] - assert "Extracting a" in out + assert "Extracting pkg-a" in out assert "from binary cache" in out @@ -238,8 +207,7 @@ def test_try_install_from_binary_cache(install_mockery, mock_packages, monkeypat def test_installer_repr(install_mockery): - const_arg = installer_args(["trivial-install-test-package"], {}) - installer = create_installer(const_arg) + installer = create_installer(["trivial-install-test-package"]) irep = installer.__repr__() assert irep.startswith(installer.__class__.__name__) @@ -248,8 +216,7 @@ def test_installer_repr(install_mockery): def test_installer_str(install_mockery): - const_arg = installer_args(["trivial-install-test-package"], {}) - installer = create_installer(const_arg) + installer = create_installer(["trivial-install-test-package"]) istr = str(installer) assert "#tasks=0" in istr @@ -276,7 +243,7 @@ def test_installer_prune_built_build_deps(install_mockery, monkeypatch, tmpdir): @property def _mock_installed(self): - return self.name in ["c"] + return self.name == "pkg-c" # Mock the installed property to say that (b) is installed monkeypatch.setattr(spack.spec.Spec, "installed", _mock_installed) @@ -284,24 +251,24 @@ def _mock_installed(self): # Create mock repository with packages (a), (b), (c), (d), and (e) builder = spack.repo.MockRepositoryBuilder(tmpdir.mkdir("mock-repo")) - builder.add_package("a", dependencies=[("b", "build", None), ("c", "build", None)]) - builder.add_package("b", dependencies=[("d", "build", None)]) + builder.add_package("pkg-a", dependencies=[("pkg-b", "build", None), ("pkg-c", "build", None)]) + builder.add_package("pkg-b", dependencies=[("pkg-d", "build", None)]) builder.add_package( - "c", dependencies=[("d", "build", None), ("e", "all", None), ("f", "build", None)] + "pkg-c", + dependencies=[("pkg-d", "build", None), ("pkg-e", "all", None), ("pkg-f", "build", None)], ) - builder.add_package("d") - builder.add_package("e") - builder.add_package("f") + builder.add_package("pkg-d") + builder.add_package("pkg-e") + builder.add_package("pkg-f") with spack.repo.use_repositories(builder.root): - const_arg = installer_args(["a"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"]) installer._init_queue() # Assert that (c) is not in the build_pq - result = set([task.pkg_id[0] for _, task in installer.build_pq]) - expected = set(["a", "b", "c", "d", "e"]) + result = {task.pkg_id[:5] for _, task in installer.build_pq} + expected = {"pkg-a", "pkg-b", "pkg-c", "pkg-d", "pkg-e"} assert result == expected @@ -329,8 +296,7 @@ def test_check_last_phase_error(install_mockery): def test_installer_ensure_ready_errors(install_mockery, monkeypatch): - const_arg = installer_args(["trivial-install-test-package"], {}) - installer = create_installer(const_arg) + installer = create_installer(["trivial-install-test-package"]) spec = installer.build_requests[0].pkg.spec fmt = r"cannot be installed locally.*{0}" @@ -364,8 +330,7 @@ def test_ensure_locked_err(install_mockery, monkeypatch, tmpdir, capsys): def _raise(lock, timeout=None): raise RuntimeError(mock_err_msg) - const_arg = installer_args(["trivial-install-test-package"], {}) - installer = create_installer(const_arg) + installer = create_installer(["trivial-install-test-package"]) spec = installer.build_requests[0].pkg.spec monkeypatch.setattr(ulk.Lock, "acquire_read", _raise) @@ -380,10 +345,9 @@ def _raise(lock, timeout=None): def test_ensure_locked_have(install_mockery, tmpdir, capsys): """Test _ensure_locked when already have lock.""" - const_arg = installer_args(["trivial-install-test-package"], {}) - installer = create_installer(const_arg) + installer = create_installer(["trivial-install-test-package"], {}) spec = installer.build_requests[0].pkg.spec - pkg_id = inst.package_id(spec.package) + pkg_id = inst.package_id(spec) with tmpdir.as_cwd(): # Test "downgrade" of a read lock (to a read lock) @@ -416,9 +380,7 @@ def test_ensure_locked_have(install_mockery, tmpdir, capsys): @pytest.mark.parametrize("lock_type,reads,writes", [("read", 1, 0), ("write", 0, 1)]) def test_ensure_locked_new_lock(install_mockery, tmpdir, lock_type, reads, writes): - pkg_id = "a" - const_arg = installer_args([pkg_id], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {}) spec = installer.build_requests[0].pkg.spec with tmpdir.as_cwd(): ltype, lock = installer._ensure_locked(lock_type, spec.package) @@ -436,9 +398,7 @@ def _pl(db, spec, timeout): lock.default_timeout = 1e-9 if timeout is None else None return lock - pkg_id = "a" - const_arg = installer_args([pkg_id], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {}) spec = installer.build_requests[0].pkg.spec monkeypatch.setattr(spack.database.SpecLocker, "lock", _pl) @@ -454,17 +414,15 @@ def _pl(db, spec, timeout): def test_package_id_err(install_mockery): s = spack.spec.Spec("trivial-install-test-package") - pkg_cls = spack.repo.PATH.get_pkg_class(s.name) with pytest.raises(ValueError, match="spec is not concretized"): - inst.package_id(pkg_cls(s)) + inst.package_id(s) def test_package_id_ok(install_mockery): spec = spack.spec.Spec("trivial-install-test-package") spec.concretize() assert spec.concrete - pkg = spec.package - assert pkg.name in inst.package_id(pkg) + assert spec.name in inst.package_id(spec) def test_fake_install(install_mockery): @@ -494,7 +452,7 @@ def test_packages_needed_to_bootstrap_compiler_packages(install_mockery, monkeyp spec.concretize() def _conc_spec(compiler): - return spack.spec.Spec("a").concretized() + return spack.spec.Spec("pkg-a").concretized() # Ensure we can get past functions that are precluding obtaining # packages. @@ -510,7 +468,7 @@ def _conc_spec(compiler): def test_update_tasks_for_compiler_packages_as_compiler(mock_packages, config, monkeypatch): spec = spack.spec.Spec("trivial-install-test-package").concretized() - installer = inst.PackageInstaller([(spec.package, {})]) + installer = inst.PackageInstaller([spec.package], {}) # Add a task to the queue installer._add_init_task(spec.package, installer.build_requests[0], False, {}) @@ -528,6 +486,10 @@ def fake_package_list(compiler, architecture, pkgs): assert installer.build_pq[0][1].compiler +@pytest.mark.skipif( + str(archspec.cpu.host().family) != "x86_64", + reason="OneAPI compiler is not supported on other architectures", +) def test_bootstrapping_compilers_with_different_names_from_spec( install_mockery, mutable_config, mock_fetch, archspec_host_is_spack_test_host ): @@ -598,7 +560,7 @@ def test_clear_failures_success(tmpdir): """Test the clear_failures happy path.""" failures = spack.database.FailureTracker(str(tmpdir), default_timeout=0.1) - spec = spack.spec.Spec("a") + spec = spack.spec.Spec("pkg-a") spec._mark_concrete() # Set up a test prefix failure lock @@ -624,7 +586,7 @@ def test_clear_failures_success(tmpdir): def test_clear_failures_errs(tmpdir, capsys): """Test the clear_failures exception paths.""" failures = spack.database.FailureTracker(str(tmpdir), default_timeout=0.1) - spec = spack.spec.Spec("a") + spec = spack.spec.Spec("pkg-a") spec._mark_concrete() failures.mark(spec) @@ -686,12 +648,11 @@ def test_check_deps_status_install_failure(install_mockery): """Tests that checking the dependency status on a request to install 'a' fails, if we mark the dependency as failed. """ - s = spack.spec.Spec("a").concretized() + s = spack.spec.Spec("pkg-a").concretized() for dep in s.traverse(root=False): spack.store.STORE.failure_tracker.mark(dep) - const_arg = installer_args(["a"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {}) request = installer.build_requests[0] with pytest.raises(inst.InstallError, match="install failure"): @@ -699,8 +660,7 @@ def test_check_deps_status_install_failure(install_mockery): def test_check_deps_status_write_locked(install_mockery, monkeypatch): - const_arg = installer_args(["a"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {}) request = installer.build_requests[0] # Ensure the lock is not acquired @@ -711,8 +671,7 @@ def test_check_deps_status_write_locked(install_mockery, monkeypatch): def test_check_deps_status_external(install_mockery, monkeypatch): - const_arg = installer_args(["a"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {}) request = installer.build_requests[0] # Mock the dependencies as external so assumed to be installed @@ -720,12 +679,11 @@ def test_check_deps_status_external(install_mockery, monkeypatch): installer._check_deps_status(request) for dep in request.spec.traverse(root=False): - assert inst.package_id(dep.package) in installer.installed + assert inst.package_id(dep) in installer.installed def test_check_deps_status_upstream(install_mockery, monkeypatch): - const_arg = installer_args(["a"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {}) request = installer.build_requests[0] # Mock the known dependencies as installed upstream @@ -733,7 +691,7 @@ def test_check_deps_status_upstream(install_mockery, monkeypatch): installer._check_deps_status(request) for dep in request.spec.traverse(root=False): - assert inst.package_id(dep.package) in installer.installed + assert inst.package_id(dep) in installer.installed def test_add_bootstrap_compilers(install_mockery, monkeypatch): @@ -743,8 +701,7 @@ def _pkgs(compiler, architecture, pkgs): spec = spack.spec.Spec("mpi").concretized() return [(spec.package, True)] - const_arg = installer_args(["trivial-install-test-package"], {}) - installer = create_installer(const_arg) + installer = create_installer(["trivial-install-test-package"], {}) request = installer.build_requests[0] all_deps = defaultdict(set) @@ -759,8 +716,7 @@ def _pkgs(compiler, architecture, pkgs): def test_prepare_for_install_on_installed(install_mockery, monkeypatch): """Test of _prepare_for_install's early return for installed task path.""" - const_arg = installer_args(["dependent-install"], {}) - installer = create_installer(const_arg) + installer = create_installer(["dependent-install"], {}) request = installer.build_requests[0] install_args = {"keep_prefix": True, "keep_stage": True, "restage": False} @@ -775,8 +731,7 @@ def test_installer_init_requests(install_mockery): """Test of installer initial requests.""" spec_name = "dependent-install" with spack.config.override("config:install_missing_compilers", True): - const_arg = installer_args([spec_name], {}) - installer = create_installer(const_arg) + installer = create_installer([spec_name], {}) # There is only one explicit request in this case assert len(installer.build_requests) == 1 @@ -785,8 +740,7 @@ def test_installer_init_requests(install_mockery): def test_install_task_use_cache(install_mockery, monkeypatch): - const_arg = installer_args(["trivial-install-test-package"], {}) - installer = create_installer(const_arg) + installer = create_installer(["trivial-install-test-package"], {}) request = installer.build_requests[0] task = create_build_task(request.pkg) @@ -801,8 +755,7 @@ def test_install_task_add_compiler(install_mockery, monkeypatch, capfd): def _add(_compilers): tty.msg(config_msg) - const_arg = installer_args(["a"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {}) task = create_build_task(installer.build_requests[0].pkg) task.compiler = True @@ -821,8 +774,7 @@ def _add(_compilers): def test_release_lock_write_n_exception(install_mockery, tmpdir, capsys): """Test _release_lock for supposed write lock with exception.""" - const_arg = installer_args(["trivial-install-test-package"], {}) - installer = create_installer(const_arg) + installer = create_installer(["trivial-install-test-package"], {}) pkg_id = "test" with tmpdir.as_cwd(): @@ -839,8 +791,7 @@ def test_release_lock_write_n_exception(install_mockery, tmpdir, capsys): @pytest.mark.parametrize("installed", [True, False]) def test_push_task_skip_processed(install_mockery, installed): """Test to ensure skip re-queueing a processed package.""" - const_arg = installer_args(["a"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {}) assert len(list(installer.build_tasks)) == 0 # Mark the package as installed OR failed @@ -857,8 +808,7 @@ def test_push_task_skip_processed(install_mockery, installed): def test_requeue_task(install_mockery, capfd): """Test to ensure cover _requeue_task.""" - const_arg = installer_args(["a"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {}) task = create_build_task(installer.build_requests[0].pkg) # temporarily set tty debug messages on so we can test output @@ -875,7 +825,7 @@ def test_requeue_task(install_mockery, capfd): assert qtask.attempts == task.attempts + 1 out = capfd.readouterr()[1] - assert "Installing a" in out + assert "Installing pkg-a" in out assert " in progress by another process" in out @@ -888,17 +838,16 @@ def _mktask(pkg): def _rmtask(installer, pkg_id): raise RuntimeError("Raise an exception to test except path") - const_arg = installer_args(["a"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {}) spec = installer.build_requests[0].pkg.spec # Cover task removal happy path - installer.build_tasks["a"] = _mktask(spec.package) + installer.build_tasks["pkg-a"] = _mktask(spec.package) installer._cleanup_all_tasks() assert len(installer.build_tasks) == 0 # Cover task removal exception path - installer.build_tasks["a"] = _mktask(spec.package) + installer.build_tasks["pkg-a"] = _mktask(spec.package) monkeypatch.setattr(inst.PackageInstaller, "_remove_task", _rmtask) installer._cleanup_all_tasks() assert len(installer.build_tasks) == 1 @@ -918,8 +867,7 @@ def _chgrp(path, group, follow_symlinks=True): monkeypatch.setattr(prefs, "get_package_group", _get_group) monkeypatch.setattr(fs, "chgrp", _chgrp) - const_arg = installer_args(["trivial-install-test-package"], {}) - installer = create_installer(const_arg) + installer = create_installer(["trivial-install-test-package"], {}) spec = installer.build_requests[0].pkg.spec fs.touchp(spec.prefix) @@ -945,8 +893,7 @@ def test_cleanup_failed_err(install_mockery, tmpdir, monkeypatch, capsys): def _raise_except(lock): raise RuntimeError(msg) - const_arg = installer_args(["trivial-install-test-package"], {}) - installer = create_installer(const_arg) + installer = create_installer(["trivial-install-test-package"], {}) monkeypatch.setattr(lk.Lock, "release_write", _raise_except) pkg_id = "test" @@ -962,8 +909,7 @@ def _raise_except(lock): def test_update_failed_no_dependent_task(install_mockery): """Test _update_failed with missing dependent build tasks.""" - const_arg = installer_args(["dependent-install"], {}) - installer = create_installer(const_arg) + installer = create_installer(["dependent-install"], {}) spec = installer.build_requests[0].pkg.spec for dep in spec.traverse(root=False): @@ -974,8 +920,7 @@ def test_update_failed_no_dependent_task(install_mockery): def test_install_uninstalled_deps(install_mockery, monkeypatch, capsys): """Test install with uninstalled dependencies.""" - const_arg = installer_args(["dependent-install"], {}) - installer = create_installer(const_arg) + installer = create_installer(["dependent-install"], {}) # Skip the actual installation and any status updates monkeypatch.setattr(inst.PackageInstaller, "_install_task", _noop) @@ -992,8 +937,7 @@ def test_install_uninstalled_deps(install_mockery, monkeypatch, capsys): def test_install_failed(install_mockery, monkeypatch, capsys): """Test install with failed install.""" - const_arg = installer_args(["b"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-b"], {}) # Make sure the package is identified as failed monkeypatch.setattr(spack.database.FailureTracker, "has_failed", _true) @@ -1008,8 +952,7 @@ def test_install_failed(install_mockery, monkeypatch, capsys): def test_install_failed_not_fast(install_mockery, monkeypatch, capsys): """Test install with failed install.""" - const_arg = installer_args(["a"], {"fail_fast": False}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {"fail_fast": False}) # Make sure the package is identified as failed monkeypatch.setattr(spack.database.FailureTracker, "has_failed", _true) @@ -1019,12 +962,12 @@ def test_install_failed_not_fast(install_mockery, monkeypatch, capsys): out = str(capsys.readouterr()) assert "failed to install" in out - assert "Skipping build of a" in out + assert "Skipping build of pkg-a" in out def test_install_fail_on_interrupt(install_mockery, monkeypatch): """Test ctrl-c interrupted install.""" - spec_name = "a" + spec_name = "pkg-a" err_msg = "mock keyboard interrupt for {0}".format(spec_name) def _interrupt(installer, task, install_status, **kwargs): @@ -1033,8 +976,7 @@ def _interrupt(installer, task, install_status, **kwargs): else: installer.installed.add(task.pkg.name) - const_arg = installer_args([spec_name], {}) - installer = create_installer(const_arg) + installer = create_installer([spec_name], {}) # Raise a KeyboardInterrupt error to trigger early termination monkeypatch.setattr(inst.PackageInstaller, "_install_task", _interrupt) @@ -1042,13 +984,13 @@ def _interrupt(installer, task, install_status, **kwargs): with pytest.raises(KeyboardInterrupt, match=err_msg): installer.install() - assert "b" in installer.installed # ensure dependency of a is 'installed' + assert "pkg-b" in installer.installed # ensure dependency of pkg-a is 'installed' assert spec_name not in installer.installed def test_install_fail_single(install_mockery, monkeypatch): """Test expected results for failure of single package.""" - spec_name = "a" + spec_name = "pkg-a" err_msg = "mock internal package build error for {0}".format(spec_name) class MyBuildException(Exception): @@ -1060,8 +1002,7 @@ def _install(installer, task, install_status, **kwargs): else: installer.installed.add(task.pkg.name) - const_arg = installer_args([spec_name], {}) - installer = create_installer(const_arg) + installer = create_installer([spec_name], {}) # Raise a KeyboardInterrupt error to trigger early termination monkeypatch.setattr(inst.PackageInstaller, "_install_task", _install) @@ -1069,13 +1010,13 @@ def _install(installer, task, install_status, **kwargs): with pytest.raises(MyBuildException, match=err_msg): installer.install() - assert "b" in installer.installed # ensure dependency of a is 'installed' + assert "pkg-b" in installer.installed # ensure dependency of a is 'installed' assert spec_name not in installer.installed def test_install_fail_multi(install_mockery, monkeypatch): """Test expected results for failure of multiple packages.""" - spec_name = "c" + spec_name = "pkg-c" err_msg = "mock internal package build error" class MyBuildException(Exception): @@ -1087,8 +1028,7 @@ def _install(installer, task, install_status, **kwargs): else: installer.installed.add(task.pkg.name) - const_arg = installer_args([spec_name, "a"], {}) - installer = create_installer(const_arg) + installer = create_installer([spec_name, "pkg-a"], {}) # Raise a KeyboardInterrupt error to trigger early termination monkeypatch.setattr(inst.PackageInstaller, "_install_task", _install) @@ -1096,31 +1036,27 @@ def _install(installer, task, install_status, **kwargs): with pytest.raises(inst.InstallError, match="Installation request failed"): installer.install() - assert "a" in installer.installed # ensure the the second spec installed + assert "pkg-a" in installer.installed # ensure the the second spec installed assert spec_name not in installer.installed def test_install_fail_fast_on_detect(install_mockery, monkeypatch, capsys): """Test fail_fast install when an install failure is detected.""" - const_arg = installer_args(["b"], {"fail_fast": False}) - const_arg.extend(installer_args(["c"], {"fail_fast": True})) - installer = create_installer(const_arg) - pkg_ids = [inst.package_id(spec.package) for spec, _ in const_arg] + b, c = spack.spec.Spec("pkg-b").concretized(), spack.spec.Spec("pkg-c").concretized() + b_id, c_id = inst.package_id(b), inst.package_id(c) + + installer = create_installer([b, c], {"fail_fast": True}) # Make sure all packages are identified as failed - # - # This will prevent b from installing, which will cause the build of a - # to be skipped. + # This will prevent b from installing, which will cause the build of c to be skipped. monkeypatch.setattr(spack.database.FailureTracker, "has_failed", _true) with pytest.raises(inst.InstallError, match="after first install failure"): installer.install() - assert pkg_ids[0] in installer.failed, "Expected b to be marked as failed" - assert pkg_ids[1] not in installer.failed, "Expected no attempt to install c" - - out = capsys.readouterr()[1] - assert "{0} failed to install".format(pkg_ids[0]) in out + assert b_id in installer.failed, "Expected b to be marked as failed" + assert c_id not in installer.failed, "Expected no attempt to install pkg-c" + assert f"{b_id} failed to install" in capsys.readouterr().err def _test_install_fail_fast_on_except_patch(installer, **kwargs): @@ -1133,8 +1069,7 @@ def _test_install_fail_fast_on_except_patch(installer, **kwargs): @pytest.mark.disable_clean_stage_check def test_install_fail_fast_on_except(install_mockery, monkeypatch, capsys): """Test fail_fast install when an install failure results from an error.""" - const_arg = installer_args(["a"], {"fail_fast": True}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-a"], {"fail_fast": True}) # Raise a non-KeyboardInterrupt exception to trigger fast failure. # @@ -1148,7 +1083,7 @@ def test_install_fail_fast_on_except(install_mockery, monkeypatch, capsys): installer.install() out = str(capsys.readouterr()) - assert "Skipping build of a" in out + assert "Skipping build of pkg-a" in out def test_install_lock_failures(install_mockery, monkeypatch, capfd): @@ -1157,8 +1092,7 @@ def test_install_lock_failures(install_mockery, monkeypatch, capfd): def _requeued(installer, task, install_status): tty.msg("requeued {0}".format(task.pkg.spec.name)) - const_arg = installer_args(["b"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-b"], {}) # Ensure never acquire a lock monkeypatch.setattr(inst.PackageInstaller, "_ensure_locked", _not_locked) @@ -1177,20 +1111,19 @@ def _requeued(installer, task, install_status): def test_install_lock_installed_requeue(install_mockery, monkeypatch, capfd): """Cover basic install handling for installed package.""" - const_arg = installer_args(["b"], {}) - b, _ = const_arg[0] - installer = create_installer(const_arg) - b_pkg_id = inst.package_id(b.package) + b = spack.spec.Spec("pkg-b").concretized() + b_pkg_id = inst.package_id(b) + installer = create_installer([b]) def _prep(installer, task): installer.installed.add(b_pkg_id) - tty.msg("{0} is installed".format(b_pkg_id)) + tty.msg(f"{b_pkg_id} is installed") # also do not allow the package to be locked again monkeypatch.setattr(inst.PackageInstaller, "_ensure_locked", _not_locked) def _requeued(installer, task, install_status): - tty.msg("requeued {0}".format(inst.package_id(task.pkg))) + tty.msg(f"requeued {inst.package_id(task.pkg.spec)}") # Flag the package as installed monkeypatch.setattr(inst.PackageInstaller, "_prepare_for_install", _prep) @@ -1203,9 +1136,8 @@ def _requeued(installer, task, install_status): assert b_pkg_id not in installer.installed - out = capfd.readouterr()[0] expected = ["is installed", "read locked", "requeued"] - for exp, ln in zip(expected, out.split("\n")): + for exp, ln in zip(expected, capfd.readouterr().out.splitlines()): assert exp in ln @@ -1233,8 +1165,7 @@ def _requeued(installer, task, install_status): # Ensure don't continually requeue the task monkeypatch.setattr(inst.PackageInstaller, "_requeue_task", _requeued) - const_arg = installer_args(["b"], {}) - installer = create_installer(const_arg) + installer = create_installer(["pkg-b"], {}) with pytest.raises(inst.InstallError, match="request failed"): installer.install() @@ -1249,25 +1180,19 @@ def _requeued(installer, task, install_status): def test_install_skip_patch(install_mockery, mock_fetch): """Test the path skip_patch install path.""" - spec_name = "b" - const_arg = installer_args([spec_name], {"fake": False, "skip_patch": True}) - installer = create_installer(const_arg) - + installer = create_installer(["pkg-b"], {"fake": False, "skip_patch": True}) installer.install() - - spec, install_args = const_arg[0] - assert inst.package_id(spec.package) in installer.installed + assert inst.package_id(installer.build_requests[0].pkg.spec) in installer.installed def test_install_implicit(install_mockery, mock_fetch): """Test the path skip_patch install path.""" spec_name = "trivial-install-test-package" - const_arg = installer_args([spec_name], {"fake": False}) - installer = create_installer(const_arg) + installer = create_installer([spec_name], {"fake": False}) pkg = installer.build_requests[0].pkg - assert not create_build_task(pkg, {"explicit": False}).explicit - assert create_build_task(pkg, {"explicit": True}).explicit - assert create_build_task(pkg).explicit + assert not create_build_task(pkg, {"explicit": []}).explicit + assert create_build_task(pkg, {"explicit": [pkg.spec.dag_hash()]}).explicit + assert not create_build_task(pkg).explicit def test_overwrite_install_backup_success(temporary_store, config, mock_packages, tmpdir): @@ -1276,8 +1201,7 @@ def test_overwrite_install_backup_success(temporary_store, config, mock_packages of the original prefix, and leave the original spec marked installed. """ # Get a build task. TODO: refactor this to avoid calling internal methods - const_arg = installer_args(["b"]) - installer = create_installer(const_arg) + installer = create_installer(["pkg-b"]) installer._init_queue() task = installer._pop_task() @@ -1337,8 +1261,7 @@ def remove(self, spec): self.called = True # Get a build task. TODO: refactor this to avoid calling internal methods - const_arg = installer_args(["b"]) - installer = create_installer(const_arg) + installer = create_installer(["pkg-b"]) installer._init_queue() task = installer._pop_task() @@ -1366,27 +1289,25 @@ def test_term_status_line(): # accept that. `with log_output(buf)` doesn't really work because it trims output # and we actually want to test for escape sequences etc. x = inst.TermStatusLine(enabled=True) - x.add("a") - x.add("b") + x.add("pkg-a") + x.add("pkg-b") x.clear() -@pytest.mark.parametrize( - "explicit_args,is_explicit", - [({"explicit": False}, False), ({"explicit": True}, True), ({}, True)], -) -def test_single_external_implicit_install(install_mockery, explicit_args, is_explicit): +@pytest.mark.parametrize("explicit", [True, False]) +def test_single_external_implicit_install(install_mockery, explicit): pkg = "trivial-install-test-package" s = spack.spec.Spec(pkg).concretized() s.external_path = "/usr" - create_installer([(s, explicit_args)]).install() - assert spack.store.STORE.db.get_record(pkg).explicit == is_explicit + args = {"explicit": [s.dag_hash()] if explicit else []} + create_installer([s], args).install() + assert spack.store.STORE.db.get_record(pkg).explicit == explicit def test_overwrite_install_does_install_build_deps(install_mockery, mock_fetch): """When overwrite installing something from sources, build deps should be installed.""" s = spack.spec.Spec("dtrun3").concretized() - create_installer([(s, {})]).install() + create_installer([s]).install() # Verify there is a pure build dep edge = s.edges_to_dependencies(name="dtbuild3").pop() @@ -1397,7 +1318,7 @@ def test_overwrite_install_does_install_build_deps(install_mockery, mock_fetch): build_dep.package.do_uninstall() # Overwrite install the root dtrun3 - create_installer([(s, {"overwrite": [s.dag_hash()]})]).install() + create_installer([s], {"overwrite": [s.dag_hash()]}).install() # Verify that the build dep was also installed. assert build_dep.installed diff --git a/lib/spack/spack/test/llnl/url.py b/lib/spack/spack/test/llnl/url.py index 1afee9c05cd342..ffe344fee28a4b 100644 --- a/lib/spack/spack/test/llnl/url.py +++ b/lib/spack/spack/test/llnl/url.py @@ -84,14 +84,15 @@ def test_get_bad_extension(): ("astyle_1.23_macosx", "astyle_1.23"), ("haxe-2.08-osx", "haxe-2.08"), # PyPI - wheel - ("entrypoints-0.2.2-py2.py3-none-any.whl", "entrypoints-0.2.2"), + ("wheel-1.2.3-py3-none-any", "wheel-1.2.3"), + ("wheel-1.2.3-py2.py3-none-any", "wheel-1.2.3"), + ("wheel-1.2.3-cp38-abi3-macosx_10_12_x86_64", "wheel-1.2.3"), + ("entrypoints-0.2.2-py2.py3-none-any", "entrypoints-0.2.2"), ( "numpy-1.12.0-cp27-cp27m-macosx_10_6_intel.macosx_10_9_intel." - "macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", + "macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64", "numpy-1.12.0", ), - # PyPI - exe - ("PyYAML-3.12.win-amd64-py3.5.exe", "PyYAML-3.12"), # Combinations of multiple patterns - bin, release ("rocketmq-all-4.5.2-bin-release", "rocketmq-all-4.5.2"), # Combinations of multiple patterns - all @@ -148,6 +149,8 @@ def test_strip_compression_extension(archive_and_expected): assert stripped == "Foo.zip" stripped = llnl.url.strip_compression_extension(archive, "zip") assert stripped == "Foo" + elif extension == "whl": + assert stripped == "Foo.whl" elif ( extension.lower() == "tar" or extension in llnl.url.CONTRACTION_MAP diff --git a/lib/spack/spack/test/llnl/util/filesystem.py b/lib/spack/spack/test/llnl/util/filesystem.py index d3b229112bd1e3..d9e34d50096094 100644 --- a/lib/spack/spack/test/llnl/util/filesystem.py +++ b/lib/spack/spack/test/llnl/util/filesystem.py @@ -9,11 +9,12 @@ import shutil import stat import sys +from contextlib import contextmanager import pytest import llnl.util.filesystem as fs -from llnl.util.symlink import islink, symlink +from llnl.util.symlink import islink, readlink, symlink import spack.paths @@ -180,7 +181,7 @@ def test_symlinks_true(self, stage): assert os.path.exists("dest/a/b2") with fs.working_dir("dest/a"): - assert os.path.exists(os.readlink("b2")) + assert os.path.exists(readlink("b2")) assert os.path.realpath("dest/f/2") == os.path.abspath("dest/a/b/2") assert os.path.realpath("dest/2") == os.path.abspath("dest/1") @@ -277,10 +278,10 @@ def test_symlinks_false(self, stage): def test_allow_broken_symlinks(self, stage): """Test installing with a broken symlink.""" with fs.working_dir(str(stage)): - symlink("nonexistant.txt", "source/broken", allow_broken_symlinks=True) - fs.install_tree("source", "dest", symlinks=True, allow_broken_symlinks=True) + symlink("nonexistant.txt", "source/broken") + fs.install_tree("source", "dest", symlinks=True) assert os.path.islink("dest/broken") - assert not os.path.exists(os.readlink("dest/broken")) + assert not os.path.exists(readlink("dest/broken")) def test_glob_src(self, stage): """Test using a glob as the source.""" @@ -908,3 +909,129 @@ def test_find_first_file(tmpdir, bfs_depth): # Should find first dir assert os.path.samefile(fs.find_first(root, "a", bfs_depth=bfs_depth), os.path.join(root, "a")) + + +def test_rename_dest_exists(tmpdir): + @contextmanager + def setup_test_files(): + a = tmpdir.join("a", "file1") + b = tmpdir.join("a", "file2") + fs.touchp(a) + fs.touchp(b) + with open(a, "w") as oa, open(b, "w") as ob: + oa.write("I am A") + ob.write("I am B") + yield a, b + shutil.rmtree(tmpdir.join("a")) + + @contextmanager + def setup_test_dirs(): + a = tmpdir.join("d", "a") + b = tmpdir.join("d", "b") + fs.mkdirp(a) + fs.mkdirp(b) + yield a, b + shutil.rmtree(tmpdir.join("d")) + + # test standard behavior of rename + # smoke test + with setup_test_files() as files: + a, b = files + fs.rename(str(a), str(b)) + assert os.path.exists(b) + assert not os.path.exists(a) + with open(b, "r") as ob: + content = ob.read() + assert content == "I am A" + + # test relatitve paths + # another sanity check/smoke test + with setup_test_files() as files: + a, b = files + with fs.working_dir(str(tmpdir)): + fs.rename(os.path.join("a", "file1"), os.path.join("a", "file2")) + assert os.path.exists(b) + assert not os.path.exists(a) + with open(b, "r") as ob: + content = ob.read() + assert content == "I am A" + + # Test rename symlinks to same file + c = tmpdir.join("a", "file1") + a = tmpdir.join("a", "link1") + b = tmpdir.join("a", "link2") + fs.touchp(c) + symlink(c, a) + symlink(c, b) + fs.rename(str(a), str(b)) + assert os.path.exists(b) + assert not os.path.exists(a) + assert os.path.realpath(b) == c + shutil.rmtree(tmpdir.join("a")) + + # test rename onto itself + a = tmpdir.join("a", "file1") + b = a + fs.touchp(a) + with open(a, "w") as oa: + oa.write("I am A") + fs.rename(str(a), str(b)) + # check a, or b, doesn't matter, same file + assert os.path.exists(a) + # ensure original file was not duplicated + assert len(os.listdir(tmpdir.join("a"))) == 1 + with open(a, "r") as oa: + assert oa.read() + shutil.rmtree(tmpdir.join("a")) + + # test rename onto symlink + # to directory from symlink to directory + # (this is something spack does when regenerating views) + with setup_test_dirs() as dirs: + a, b = dirs + link1 = tmpdir.join("f", "link1") + link2 = tmpdir.join("f", "link2") + fs.mkdirp(tmpdir.join("f")) + symlink(a, link1) + symlink(b, link2) + fs.rename(str(link1), str(link2)) + assert os.path.exists(link2) + assert os.path.realpath(link2) == a + shutil.rmtree(tmpdir.join("f")) + + +@pytest.mark.skipif(sys.platform != "win32", reason="No-op on non Windows") +def test_windows_sfn(tmpdir): + # first check some standard Windows locations + # we know require sfn names + # this is basically a smoke test + # ensure spaces are replaced + path abbreviated + assert fs.windows_sfn("C:\\Program Files (x86)") == "C:\\PROGRA~2" + # ensure path without spaces is still properly shortened + assert fs.windows_sfn("C:\\ProgramData") == "C:\\PROGRA~3" + + # test user created paths + # ensure longer path with spaces is properly abbreviated + a = tmpdir.join("d", "this is a test", "a", "still test") + # ensure longer path is properly abbreviated + b = tmpdir.join("d", "long_path_with_no_spaces", "more_long_path") + # ensure path not in need of abbreviation is properly roundtripped + c = tmpdir.join("d", "this", "is", "short") + # ensure paths that are the same in the first six letters + # are incremented post tilde + d = tmpdir.join("d", "longerpath1") + e = tmpdir.join("d", "longerpath2") + fs.mkdirp(a) + fs.mkdirp(b) + fs.mkdirp(c) + fs.mkdirp(d) + fs.mkdirp(e) + # check only for path of path we can control, + # pytest prefix may or may not be mangled by windows_sfn + # based on user/pytest config + assert "d\\THISIS~1\\a\\STILLT~1" in fs.windows_sfn(a) + assert "d\\LONG_P~1\\MORE_L~1" in fs.windows_sfn(b) + assert "d\\this\\is\\short" in fs.windows_sfn(c) + assert "d\\LONGER~1" in fs.windows_sfn(d) + assert "d\\LONGER~2" in fs.windows_sfn(e) + shutil.rmtree(tmpdir.join("d")) diff --git a/lib/spack/spack/test/llnl/util/symlink.py b/lib/spack/spack/test/llnl/util/symlink.py index 6e34c97fc4f142..73a9d05e972250 100644 --- a/lib/spack/spack/test/llnl/util/symlink.py +++ b/lib/spack/spack/test/llnl/util/symlink.py @@ -20,7 +20,7 @@ def test_symlink_file(tmpdir): fd, real_file = tempfile.mkstemp(prefix="real", suffix=".txt", dir=test_dir) link_file = str(tmpdir.join("link.txt")) assert os.path.exists(link_file) is False - symlink.symlink(source_path=real_file, link_path=link_file) + symlink.symlink(real_file, link_file) assert os.path.exists(link_file) assert symlink.islink(link_file) @@ -32,11 +32,12 @@ def test_symlink_dir(tmpdir): real_dir = os.path.join(test_dir, "real_dir") link_dir = os.path.join(test_dir, "link_dir") os.mkdir(real_dir) - symlink.symlink(source_path=real_dir, link_path=link_dir) + symlink.symlink(real_dir, link_dir) assert os.path.exists(link_dir) assert symlink.islink(link_dir) +@pytest.mark.skipif(sys.platform != "win32", reason="Test is only for Windows") def test_symlink_source_not_exists(tmpdir): """Test the symlink.symlink method for the case where a source path does not exist""" with tmpdir.as_cwd(): @@ -44,7 +45,7 @@ def test_symlink_source_not_exists(tmpdir): real_dir = os.path.join(test_dir, "real_dir") link_dir = os.path.join(test_dir, "link_dir") with pytest.raises(symlink.SymlinkError): - symlink.symlink(source_path=real_dir, link_path=link_dir, allow_broken_symlinks=False) + symlink._windows_symlink(real_dir, link_dir) def test_symlink_src_relative_to_link(tmpdir): @@ -61,18 +62,16 @@ def test_symlink_src_relative_to_link(tmpdir): fd, real_file = tempfile.mkstemp(prefix="real", suffix=".txt", dir=subdir_2) link_file = os.path.join(subdir_1, "link.txt") - symlink.symlink( - source_path=f"b/{os.path.basename(real_file)}", - link_path=f"a/{os.path.basename(link_file)}", - ) + symlink.symlink(f"b/{os.path.basename(real_file)}", f"a/{os.path.basename(link_file)}") assert os.path.exists(link_file) assert symlink.islink(link_file) # Check dirs assert not os.path.lexists(link_dir) - symlink.symlink(source_path="b", link_path="a/c") + symlink.symlink("b", "a/c") assert os.path.lexists(link_dir) +@pytest.mark.skipif(sys.platform != "win32", reason="Test is only for Windows") def test_symlink_src_not_relative_to_link(tmpdir): """Test the symlink.symlink functionality where the source value does not exist relative to the link and not relative to the cwd. NOTE that this symlink api call is EXPECTED to raise @@ -88,19 +87,18 @@ def test_symlink_src_not_relative_to_link(tmpdir): link_file = str(tmpdir.join("link.txt")) # Expected SymlinkError because source path does not exist relative to link path with pytest.raises(symlink.SymlinkError): - symlink.symlink( - source_path=f"d/{os.path.basename(real_file)}", - link_path=f"a/{os.path.basename(link_file)}", - allow_broken_symlinks=False, + symlink._windows_symlink( + f"d/{os.path.basename(real_file)}", f"a/{os.path.basename(link_file)}" ) assert not os.path.exists(link_file) # Check dirs assert not os.path.lexists(link_dir) with pytest.raises(symlink.SymlinkError): - symlink.symlink(source_path="d", link_path="a/c", allow_broken_symlinks=False) + symlink._windows_symlink("d", "a/c") assert not os.path.lexists(link_dir) +@pytest.mark.skipif(sys.platform != "win32", reason="Test is only for Windows") def test_symlink_link_already_exists(tmpdir): """Test the symlink.symlink method for the case where a link already exists""" with tmpdir.as_cwd(): @@ -108,10 +106,10 @@ def test_symlink_link_already_exists(tmpdir): real_dir = os.path.join(test_dir, "real_dir") link_dir = os.path.join(test_dir, "link_dir") os.mkdir(real_dir) - symlink.symlink(real_dir, link_dir, allow_broken_symlinks=False) + symlink._windows_symlink(real_dir, link_dir) assert os.path.exists(link_dir) with pytest.raises(symlink.SymlinkError): - symlink.symlink(source_path=real_dir, link_path=link_dir, allow_broken_symlinks=False) + symlink._windows_symlink(real_dir, link_dir) @pytest.mark.skipif(not symlink._windows_can_symlink(), reason="Test requires elevated privileges") @@ -122,7 +120,7 @@ def test_symlink_win_file(tmpdir): test_dir = str(tmpdir) fd, real_file = tempfile.mkstemp(prefix="real", suffix=".txt", dir=test_dir) link_file = str(tmpdir.join("link.txt")) - symlink.symlink(source_path=real_file, link_path=link_file) + symlink.symlink(real_file, link_file) # Verify that all expected conditions are met assert os.path.exists(link_file) assert symlink.islink(link_file) @@ -140,7 +138,7 @@ def test_symlink_win_dir(tmpdir): real_dir = os.path.join(test_dir, "real") link_dir = os.path.join(test_dir, "link") os.mkdir(real_dir) - symlink.symlink(source_path=real_dir, link_path=link_dir) + symlink.symlink(real_dir, link_dir) # Verify that all expected conditions are met assert os.path.exists(link_dir) assert symlink.islink(link_dir) diff --git a/lib/spack/spack/test/llnl/util/tty/log.py b/lib/spack/spack/test/llnl/util/tty/log.py index b2f8cd8a9eb0f5..3ff3ee995c165b 100644 --- a/lib/spack/spack/test/llnl/util/tty/log.py +++ b/lib/spack/spack/test/llnl/util/tty/log.py @@ -93,6 +93,21 @@ def test_log_python_output_and_echo_output(capfd, tmpdir): assert capfd.readouterr()[0] == "force echo\n" +def test_log_output_with_control_codes(capfd, tmpdir): + with tmpdir.as_cwd(): + with log.log_output("foo.txt"): + # Print a sample of formatted GCC error output + # Line obtained from the file generated by running gcc on a nonexistent file: + # gcc -fdiagnostics-color=always ./test.cpp 2>test.log + csi = "\x1b[" + print( + f"{csi}01m{csi}Kgcc:{csi}m{csi}K {csi}01;31m{csi}Kerror: {csi}m{csi}K./test.cpp:" + ) + + with open("foo.txt") as f: + assert f.read() == "gcc: error: ./test.cpp:\n" + + def _log_filter_fn(string): return string.replace("foo", "bar") diff --git a/lib/spack/spack/test/mirror.py b/lib/spack/spack/test/mirror.py index 5e855be00aee43..1379ad92cf9661 100644 --- a/lib/spack/spack/test/mirror.py +++ b/lib/spack/spack/test/mirror.py @@ -200,13 +200,13 @@ def test_invalid_json_mirror_collection(invalid_json, error_message): assert error_message in exc_msg -def test_mirror_archive_paths_no_version(mock_packages, config, mock_archive): +def test_mirror_archive_paths_no_version(mock_packages, mock_archive): spec = Spec("trivial-install-test-package@=nonexistingversion").concretized() fetcher = spack.fetch_strategy.URLFetchStrategy(mock_archive.url) spack.mirror.mirror_archive_paths(fetcher, "per-package-ref", spec) -def test_mirror_with_url_patches(mock_packages, config, monkeypatch): +def test_mirror_with_url_patches(mock_packages, monkeypatch): spec = Spec("patch-several-dependencies") spec.concretize() @@ -289,8 +289,8 @@ def test_mirror_cache_symlinks(tmpdir): @pytest.mark.parametrize( "specs,expected_specs", [ - (["a"], ["a@=1.0", "a@=2.0"]), - (["a", "brillig"], ["a@=1.0", "a@=2.0", "brillig@=1.0.0", "brillig@=2.0.0"]), + (["pkg-a"], ["pkg-a@=1.0", "pkg-a@=2.0"]), + (["pkg-a", "brillig"], ["pkg-a@=1.0", "pkg-a@=2.0", "brillig@=1.0.0", "brillig@=2.0.0"]), ], ) def test_get_all_versions(specs, expected_specs): diff --git a/lib/spack/spack/test/modules/common.py b/lib/spack/spack/test/modules/common.py index 7586728a8bc126..f6688963460f74 100644 --- a/lib/spack/spack/test/modules/common.py +++ b/lib/spack/spack/test/modules/common.py @@ -7,6 +7,8 @@ import pytest +from llnl.util.symlink import readlink + import spack.cmd.modules import spack.config import spack.error @@ -78,7 +80,7 @@ def test_modules_default_symlink( link_path = os.path.join(os.path.dirname(mock_module_filename), "default") assert os.path.islink(link_path) - assert os.readlink(link_path) == mock_module_filename + assert readlink(link_path) == mock_module_filename generator.remove() assert not os.path.lexists(link_path) diff --git a/lib/spack/spack/test/modules/lmod.py b/lib/spack/spack/test/modules/lmod.py index c6cf91cb668053..43ee11ec492c3f 100644 --- a/lib/spack/spack/test/modules/lmod.py +++ b/lib/spack/spack/test/modules/lmod.py @@ -7,6 +7,8 @@ import pytest +import archspec.cpu + import spack.environment as ev import spack.main import spack.modules.lmod @@ -27,7 +29,7 @@ ] -@pytest.fixture(params=["clang@=12.0.0", "gcc@=10.2.1"]) +@pytest.fixture(params=["clang@=15.0.0", "gcc@=10.2.1"]) def compiler(request): return request.param @@ -46,7 +48,7 @@ def provider(request): return request.param -@pytest.mark.usefixtures("config", "mock_packages") +@pytest.mark.usefixtures("mutable_config", "mock_packages") class TestLmod: @pytest.mark.regression("37788") @pytest.mark.parametrize("modules_config", ["core_compilers", "core_compilers_at_equal"]) @@ -57,7 +59,7 @@ def test_layout_for_specs_compiled_with_core_compilers( we can use both ``compiler@version`` and ``compiler@=version`` to specify a core compiler. """ module_configuration(modules_config) - module, spec = factory("libelf%clang@12.0.0") + module, spec = factory("libelf%clang@15.0.0") assert "Core" in module.layout.available_path_parts def test_file_layout(self, compiler, provider, factory, module_configuration): @@ -76,7 +78,7 @@ def test_file_layout(self, compiler, provider, factory, module_configuration): # is transformed to r"Core" if the compiler is listed among core # compilers # Check that specs listed as core_specs are transformed to "Core" - if compiler == "clang@=12.0.0" or spec_string == "mpich@3.0.1": + if compiler == "clang@=15.0.0" or spec_string == "mpich@3.0.1": assert "Core" in layout.available_path_parts else: assert compiler.replace("@=", "/") in layout.available_path_parts @@ -103,14 +105,19 @@ def test_file_layout(self, compiler, provider, factory, module_configuration): else: assert repetitions == 1 - def test_compilers_provided_different_name(self, factory, module_configuration): - module_configuration("complex_hierarchy") - module, spec = factory("intel-oneapi-compilers%clang@3.3") + def test_compilers_provided_different_name( + self, factory, module_configuration, compiler_factory + ): + with spack.config.override( + "compilers", [compiler_factory(spec="clang@3.3", operating_system="debian6")] + ): + module_configuration("complex_hierarchy") + module, spec = factory("intel-oneapi-compilers%clang@3.3") - provides = module.conf.provides + provides = module.conf.provides - assert "compiler" in provides - assert provides["compiler"] == spack.spec.CompilerSpec("oneapi@=3.0") + assert "compiler" in provides + assert provides["compiler"] == spack.spec.CompilerSpec("oneapi@=3.0") def test_simple_case(self, modulefile_content, module_configuration): """Tests the generation of a simple Lua module file.""" @@ -210,6 +217,9 @@ def test_setenv_raw_value(self, modulefile_content, module_configuration): assert len([x for x in content if 'setenv("FOO", "{{name}}, {name}, {{}}, {}")' in x]) == 1 + @pytest.mark.skipif( + str(archspec.cpu.host().family) != "x86_64", reason="test data is specific for x86_64" + ) def test_help_message(self, modulefile_content, module_configuration): """Tests the generation of module help message.""" @@ -333,17 +343,18 @@ def test_override_template_in_package(self, modulefile_content, module_configura assert "Override successful!" in content - def test_override_template_in_modules_yaml(self, modulefile_content, module_configuration): + def test_override_template_in_modules_yaml( + self, modulefile_content, module_configuration, host_architecture_str + ): """Tests overriding a template from `modules.yaml`""" module_configuration("override_template") content = modulefile_content("override-module-templates") assert "Override even better!" in content - content = modulefile_content("mpileaks target=x86_64") + content = modulefile_content(f"mpileaks target={host_architecture_str}") assert "Override even better!" in content - @pytest.mark.usefixtures("config") def test_external_configure_args(self, factory): # If this package is detected as an external, its configure option line # in the module file starts with 'unknown' diff --git a/lib/spack/spack/test/modules/tcl.py b/lib/spack/spack/test/modules/tcl.py index 441e3f6e64a65c..12cc770a89f088 100644 --- a/lib/spack/spack/test/modules/tcl.py +++ b/lib/spack/spack/test/modules/tcl.py @@ -7,6 +7,8 @@ import pytest +import archspec.cpu + import spack.modules.common import spack.modules.tcl import spack.spec @@ -24,7 +26,7 @@ ] -@pytest.mark.usefixtures("config", "mock_packages", "mock_module_filename") +@pytest.mark.usefixtures("mutable_config", "mock_packages", "mock_module_filename") class TestTcl: def test_simple_case(self, modulefile_content, module_configuration): """Tests the generation of a simple Tcl module file.""" @@ -92,19 +94,23 @@ def test_autoload_all(self, modulefile_content, module_configuration): assert len([x for x in content if "depends-on " in x]) == 2 assert len([x for x in content if "module load " in x]) == 2 - def test_prerequisites_direct(self, modulefile_content, module_configuration): + def test_prerequisites_direct( + self, modulefile_content, module_configuration, host_architecture_str + ): """Tests asking direct dependencies as prerequisites.""" module_configuration("prerequisites_direct") - content = modulefile_content("mpileaks target=x86_64") + content = modulefile_content(f"mpileaks target={host_architecture_str}") assert len([x for x in content if "prereq" in x]) == 2 - def test_prerequisites_all(self, modulefile_content, module_configuration): + def test_prerequisites_all( + self, modulefile_content, module_configuration, host_architecture_str + ): """Tests asking all dependencies as prerequisites.""" module_configuration("prerequisites_all") - content = modulefile_content("mpileaks target=x86_64") + content = modulefile_content(f"mpileaks target={host_architecture_str}") assert len([x for x in content if "prereq" in x]) == 5 @@ -180,6 +186,9 @@ def test_setenv_raw_value(self, modulefile_content, module_configuration): assert len([x for x in content if "setenv FOO {{{name}}, {name}, {{}}, {}}" in x]) == 1 + @pytest.mark.skipif( + str(archspec.cpu.host().family) != "x86_64", reason="test data is specific for x86_64" + ) def test_help_message(self, modulefile_content, module_configuration): """Tests the generation of module help message.""" @@ -222,7 +231,7 @@ def test_help_message(self, modulefile_content, module_configuration): ) assert help_msg in "".join(content) - def test_exclude(self, modulefile_content, module_configuration): + def test_exclude(self, modulefile_content, module_configuration, host_architecture_str): """Tests excluding the generation of selected modules.""" module_configuration("exclude") @@ -234,9 +243,9 @@ def test_exclude(self, modulefile_content, module_configuration): # and IOError on Python 2 or common bases like EnvironmentError # which are not officially documented with pytest.raises(Exception): - modulefile_content("callpath target=x86_64") + modulefile_content(f"callpath target={host_architecture_str}") - content = modulefile_content("zmpi target=x86_64") + content = modulefile_content(f"zmpi target={host_architecture_str}") assert len([x for x in content if "module load " in x]) == 1 @@ -406,14 +415,16 @@ def test_override_template_in_package(self, modulefile_content, module_configura assert "Override successful!" in content - def test_override_template_in_modules_yaml(self, modulefile_content, module_configuration): + def test_override_template_in_modules_yaml( + self, modulefile_content, module_configuration, host_architecture_str + ): """Tests overriding a template from `modules.yaml`""" module_configuration("override_template") content = modulefile_content("override-module-templates") assert "Override even better!" in content - content = modulefile_content("mpileaks target=x86_64") + content = modulefile_content(f"mpileaks target={host_architecture_str}") assert "Override even better!" in content def test_extend_context(self, modulefile_content, module_configuration): @@ -428,19 +439,19 @@ def test_extend_context(self, modulefile_content, module_configuration): @pytest.mark.regression("4400") @pytest.mark.db - def test_hide_implicits_no_arg(self, module_configuration, database): + def test_hide_implicits_no_arg(self, module_configuration, mutable_database): module_configuration("exclude_implicits") # mpileaks has been installed explicitly when setting up # the tests database - mpileaks_specs = database.query("mpileaks") + mpileaks_specs = mutable_database.query("mpileaks") for item in mpileaks_specs: writer = writer_cls(item, "default") assert not writer.conf.excluded # callpath is a dependency of mpileaks, and has been pulled # in implicitly - callpath_specs = database.query("callpath") + callpath_specs = mutable_database.query("callpath") for item in callpath_specs: writer = writer_cls(item, "default") assert writer.conf.excluded @@ -462,8 +473,7 @@ def test_hide_implicits_with_arg(self, module_configuration): assert writer.conf.excluded @pytest.mark.regression("9624") - @pytest.mark.db - def test_autoload_with_constraints(self, modulefile_content, module_configuration, database): + def test_autoload_with_constraints(self, modulefile_content, module_configuration): """Tests the automatic loading of direct dependencies.""" module_configuration("autoload_with_constraints") diff --git a/lib/spack/spack/test/multimethod.py b/lib/spack/spack/test/multimethod.py index e4546c5139204f..0ab26060c69a41 100644 --- a/lib/spack/spack/test/multimethod.py +++ b/lib/spack/spack/test/multimethod.py @@ -69,9 +69,15 @@ def test_no_version_match(pkg_name): ("", "boolean_false_first", "True"), ], ) -def test_multimethod_calls(pkg_name, constraint_str, method_name, expected_result): - s = spack.spec.Spec(pkg_name + constraint_str).concretized() - msg = "Method {0} from {1} is giving a wrong result".format(method_name, s) +def test_multimethod_calls( + pkg_name, constraint_str, method_name, expected_result, compiler_factory +): + # Add apple-clang, as it is required by one of the tests + with spack.config.override( + "compilers", [compiler_factory(spec="apple-clang@9.1.0", operating_system="elcapitan")] + ): + s = spack.spec.Spec(pkg_name + constraint_str).concretized() + msg = f"Method {method_name} from {s} is giving a wrong result" assert getattr(s.package, method_name)() == expected_result, msg diff --git a/lib/spack/spack/test/oci/mock_registry.py b/lib/spack/spack/test/oci/mock_registry.py index cc39904f3c2616..288598089d7052 100644 --- a/lib/spack/spack/test/oci/mock_registry.py +++ b/lib/spack/spack/test/oci/mock_registry.py @@ -151,7 +151,9 @@ class InMemoryOCIRegistry(DummyServer): A third option is to use the chunked upload, but this is not implemented here, because it's typically a major performance hit in upload speed, so we're not using it in Spack.""" - def __init__(self, domain: str, allow_single_post: bool = True) -> None: + def __init__( + self, domain: str, allow_single_post: bool = True, tags_per_page: int = 100 + ) -> None: super().__init__(domain) self.router.register("GET", r"/v2/", self.index) self.router.register("HEAD", r"/v2/(?P.+)/blobs/(?P.+)", self.head_blob) @@ -165,6 +167,9 @@ def __init__(self, domain: str, allow_single_post: bool = True) -> None: # If True, allow single POST upload, not all registries support this self.allow_single_post = allow_single_post + # How many tags are returned in a single request + self.tags_per_page = tags_per_page + # Used for POST + PUT upload. This is a map from session ID to image name self.sessions: Dict[str, str] = {} @@ -280,10 +285,34 @@ def handle_upload(self, req: Request, name: str, digest: Digest): return MockHTTPResponse(201, "Created", headers={"Location": f"/v2/{name}/blobs/{digest}"}) def list_tags(self, req: Request, name: str): + # Paginate using Link headers, this was added to the spec in the following commit: + # https://github.com/opencontainers/distribution-spec/commit/2ed79d930ecec11dd755dc8190409a3b10f01ca9 + # List all tags, exclude digests. - tags = [_tag for _name, _tag in self.manifests.keys() if _name == name and ":" not in _tag] - tags.sort() - return MockHTTPResponse.with_json(200, "OK", body={"tags": tags}) + all_tags = sorted( + _tag for _name, _tag in self.manifests.keys() if _name == name and ":" not in _tag + ) + + query = urllib.parse.parse_qs(urllib.parse.urlparse(req.full_url).query) + + n = int(query["n"][0]) if "n" in query else self.tags_per_page + + if "last" in query: + try: + offset = all_tags.index(query["last"][0]) + 1 + except ValueError: + return MockHTTPResponse(404, "Not found") + else: + offset = 0 + + tags = all_tags[offset : offset + n] + + if offset + n < len(all_tags): + headers = {"Link": f'; rel="next"'} + else: + headers = None + + return MockHTTPResponse.with_json(200, "OK", headers=headers, body={"tags": tags}) class DummyServerUrllibHandler(urllib.request.BaseHandler): diff --git a/lib/spack/spack/test/oci/urlopen.py b/lib/spack/spack/test/oci/urlopen.py index 78d713f7e84af2..efc3f3c2b06fb4 100644 --- a/lib/spack/spack/test/oci/urlopen.py +++ b/lib/spack/spack/test/oci/urlopen.py @@ -6,6 +6,7 @@ import hashlib import json +import random import urllib.error import urllib.parse import urllib.request @@ -19,6 +20,7 @@ copy_missing_layers, get_manifest_and_config, image_from_mirror, + list_tags, upload_blob, upload_manifest, ) @@ -670,3 +672,31 @@ def test_retry(url, max_retries, expect_failure, expect_requests): assert len(server.requests) == expect_requests assert sleep_time == [2**i for i in range(expect_requests - 1)] + + +def test_list_tags(): + # Follows a relatively new rewording of the OCI distribution spec, which is not yet tagged. + # https://github.com/opencontainers/distribution-spec/commit/2ed79d930ecec11dd755dc8190409a3b10f01ca9 + N = 20 + urlopen = create_opener(InMemoryOCIRegistry("example.com", tags_per_page=5)).open + image = ImageReference.from_string("example.com/image") + to_tag = lambda i: f"tag-{i:02}" + + # Create N tags in arbitrary order + _tags_to_create = [to_tag(i) for i in range(N)] + random.shuffle(_tags_to_create) + for tag in _tags_to_create: + upload_manifest(image.with_tag(tag), default_manifest(), tag=True, _urlopen=urlopen) + + # list_tags should return all tags from all pages in order + tags = list_tags(image, urlopen) + assert len(tags) == N + assert [to_tag(i) for i in range(N)] == tags + + # Test a single request, which should give the first 5 tags + assert json.loads(urlopen(image.tags_url()).read())["tags"] == [to_tag(i) for i in range(5)] + + # Test response at an offset, which should exclude the `last` tag. + assert json.loads(urlopen(image.tags_url() + f"?last={to_tag(N - 3)}").read())["tags"] == [ + to_tag(i) for i in range(N - 2, N) + ] diff --git a/lib/spack/spack/test/operating_system.py b/lib/spack/spack/test/operating_system.py deleted file mode 100644 index 79c7e828dada2f..00000000000000 --- a/lib/spack/spack/test/operating_system.py +++ /dev/null @@ -1,77 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -import spack.operating_systems.cray_backend as cray_backend - - -def test_read_cle_release_file(tmpdir, monkeypatch): - """test reading the Cray cle-release file""" - cle_release_path = tmpdir.join("cle-release") - with cle_release_path.open("w") as f: - f.write( - """\ -RELEASE=6.0.UP07 -BUILD=6.0.7424 -DATE=20190611 -ARCH=noarch -NETWORK=ari -PATCHSET=35-201906112304 -DUMMY=foo=bar -""" - ) - - monkeypatch.setattr(cray_backend, "_cle_release_file", str(cle_release_path)) - attrs = cray_backend.read_cle_release_file() - - assert attrs["RELEASE"] == "6.0.UP07" - assert attrs["BUILD"] == "6.0.7424" - assert attrs["DATE"] == "20190611" - assert attrs["ARCH"] == "noarch" - assert attrs["NETWORK"] == "ari" - assert attrs["PATCHSET"] == "35-201906112304" - assert attrs["DUMMY"] == "foo=bar" - - assert cray_backend.CrayBackend._detect_crayos_version() == 6 - - -def test_read_clerelease_file(tmpdir, monkeypatch): - """test reading the Cray clerelease file""" - clerelease_path = tmpdir.join("clerelease") - with clerelease_path.open("w") as f: - f.write("5.2.UP04\n") - - monkeypatch.setattr(cray_backend, "_clerelease_file", str(clerelease_path)) - v = cray_backend.read_clerelease_file() - - assert v == "5.2.UP04" - - assert cray_backend.CrayBackend._detect_crayos_version() == 5 - - -def test_cle_release_precedence(tmpdir, monkeypatch): - """test that cle-release file takes precedence over clerelease file.""" - cle_release_path = tmpdir.join("cle-release") - clerelease_path = tmpdir.join("clerelease") - - with cle_release_path.open("w") as f: - f.write( - """\ -RELEASE=6.0.UP07 -BUILD=6.0.7424 -DATE=20190611 -ARCH=noarch -NETWORK=ari -PATCHSET=35-201906112304 -DUMMY=foo=bar -""" - ) - - with clerelease_path.open("w") as f: - f.write("5.2.UP04\n") - - monkeypatch.setattr(cray_backend, "_clerelease_file", str(clerelease_path)) - monkeypatch.setattr(cray_backend, "_cle_release_file", str(cle_release_path)) - - assert cray_backend.CrayBackend._detect_crayos_version() == 6 diff --git a/lib/spack/spack/test/optional_deps.py b/lib/spack/spack/test/optional_deps.py index 8d1c7e37e813ca..bc3596220d30c5 100644 --- a/lib/spack/spack/test/optional_deps.py +++ b/lib/spack/spack/test/optional_deps.py @@ -13,28 +13,44 @@ # Normalize simple conditionals ("optional-dep-test", {"optional-dep-test": None}), ("optional-dep-test~a", {"optional-dep-test~a": None}), - ("optional-dep-test+a", {"optional-dep-test+a": {"a": None}}), - ("optional-dep-test a=true", {"optional-dep-test a=true": {"a": None}}), - ("optional-dep-test a=true", {"optional-dep-test+a": {"a": None}}), - ("optional-dep-test@1.1", {"optional-dep-test@1.1": {"b": None}}), - ("optional-dep-test%intel", {"optional-dep-test%intel": {"c": None}}), - ("optional-dep-test%intel@64.1", {"optional-dep-test%intel@64.1": {"c": None, "d": None}}), + ("optional-dep-test+a", {"optional-dep-test+a": {"pkg-a": None}}), + ("optional-dep-test a=true", {"optional-dep-test a=true": {"pkg-a": None}}), + ("optional-dep-test a=true", {"optional-dep-test+a": {"pkg-a": None}}), + ("optional-dep-test@1.1", {"optional-dep-test@1.1": {"pkg-b": None}}), + ("optional-dep-test%intel", {"optional-dep-test%intel": {"pkg-c": None}}), + ( + "optional-dep-test%intel@64.1", + {"optional-dep-test%intel@64.1": {"pkg-c": None, "pkg-d": None}}, + ), ( "optional-dep-test%intel@64.1.2", - {"optional-dep-test%intel@64.1.2": {"c": None, "d": None}}, + {"optional-dep-test%intel@64.1.2": {"pkg-c": None, "pkg-d": None}}, ), - ("optional-dep-test%clang@35", {"optional-dep-test%clang@35": {"e": None}}), + ("optional-dep-test%clang@35", {"optional-dep-test%clang@35": {"pkg-e": None}}), # Normalize multiple conditionals - ("optional-dep-test+a@1.1", {"optional-dep-test+a@1.1": {"a": None, "b": None}}), - ("optional-dep-test+a%intel", {"optional-dep-test+a%intel": {"a": None, "c": None}}), - ("optional-dep-test@1.1%intel", {"optional-dep-test@1.1%intel": {"b": None, "c": None}}), + ("optional-dep-test+a@1.1", {"optional-dep-test+a@1.1": {"pkg-a": None, "pkg-b": None}}), + ( + "optional-dep-test+a%intel", + {"optional-dep-test+a%intel": {"pkg-a": None, "pkg-c": None}}, + ), + ( + "optional-dep-test@1.1%intel", + {"optional-dep-test@1.1%intel": {"pkg-b": None, "pkg-c": None}}, + ), ( "optional-dep-test@1.1%intel@64.1.2+a", - {"optional-dep-test@1.1%intel@64.1.2+a": {"a": None, "b": None, "c": None, "d": None}}, + { + "optional-dep-test@1.1%intel@64.1.2+a": { + "pkg-a": None, + "pkg-b": None, + "pkg-c": None, + "pkg-d": None, + } + }, ), ( "optional-dep-test@1.1%clang@36.5+a", - {"optional-dep-test@1.1%clang@36.5+a": {"b": None, "a": None, "e": None}}, + {"optional-dep-test@1.1%clang@36.5+a": {"pkg-b": None, "pkg-a": None, "pkg-e": None}}, ), # Chained MPI ( @@ -44,7 +60,10 @@ # Each of these dependencies comes from a conditional # dependency on another. This requires iterating to evaluate # the whole chain. - ("optional-dep-test+f", {"optional-dep-test+f": {"f": None, "g": None, "mpi": None}}), + ( + "optional-dep-test+f", + {"optional-dep-test+f": {"pkg-f": None, "pkg-g": None, "mpi": None}}, + ), ] ) def spec_and_expected(request): @@ -63,12 +82,12 @@ def test_normalize(spec_and_expected, config, mock_packages): def test_default_variant(config, mock_packages): spec = Spec("optional-dep-test-3") spec.concretize() - assert "a" in spec + assert "pkg-a" in spec spec = Spec("optional-dep-test-3~var") spec.concretize() - assert "a" in spec + assert "pkg-a" in spec spec = Spec("optional-dep-test-3+var") spec.concretize() - assert "b" in spec + assert "pkg-b" in spec diff --git a/lib/spack/spack/test/package_class.py b/lib/spack/spack/test/package_class.py index 915a53400d2da7..07a82c5358564e 100644 --- a/lib/spack/spack/test/package_class.py +++ b/lib/spack/spack/test/package_class.py @@ -21,6 +21,7 @@ import spack.install_test import spack.package_base import spack.repo +import spack.spec from spack.build_systems.generic import Package from spack.installer import InstallError @@ -142,19 +143,19 @@ def setup_install_test(source_paths, test_root): "spec,sources,extras,expect", [ ( - "a", + "pkg-a", ["example/a.c"], # Source(s) ["example/a.c"], # Extra test source ["example/a.c"], ), # Test install dir source(s) ( - "b", + "pkg-b", ["test/b.cpp", "test/b.hpp", "example/b.txt"], # Source(s) ["test"], # Extra test source ["test/b.cpp", "test/b.hpp"], ), # Test install dir source ( - "c", + "pkg-c", ["examples/a.py", "examples/b.py", "examples/c.py", "tests/d.py"], ["examples/b.py", "tests"], ["examples/b.py", "tests/d.py"], @@ -202,7 +203,7 @@ def test_cache_extra_sources(install_mockery, spec, sources, extras, expect): def test_cache_extra_sources_fails(install_mockery): - s = spack.spec.Spec("a").concretized() + s = spack.spec.Spec("pkg-a").concretized() s.package.spec.concretize() with pytest.raises(InstallError) as exc_info: @@ -226,7 +227,7 @@ class URLsPackage(spack.package.Package): url = "https://www.example.com/url-package-1.0.tgz" urls = ["https://www.example.com/archive"] - s = spack.spec.Spec("a") + s = spack.spec.Spec("pkg-a") with pytest.raises(ValueError, match="defines both"): URLsPackage(s) @@ -236,7 +237,7 @@ class LicensedPackage(spack.package.Package): extendees = None # currently a required attribute for is_extension() license_files = None - s = spack.spec.Spec("a") + s = spack.spec.Spec("pkg-a") pkg = LicensedPackage(s) assert pkg.global_license_file is None @@ -249,21 +250,21 @@ class BaseTestPackage(Package): def test_package_version_fails(): - s = spack.spec.Spec("a") + s = spack.spec.Spec("pkg-a") pkg = BaseTestPackage(s) with pytest.raises(ValueError, match="does not have a concrete version"): pkg.version() def test_package_tester_fails(): - s = spack.spec.Spec("a") + s = spack.spec.Spec("pkg-a") pkg = BaseTestPackage(s) with pytest.raises(ValueError, match="without concrete version"): pkg.tester() def test_package_fetcher_fails(): - s = spack.spec.Spec("a") + s = spack.spec.Spec("pkg-a") pkg = BaseTestPackage(s) with pytest.raises(ValueError, match="without concrete version"): pkg.fetcher @@ -275,7 +276,7 @@ def compilers(compiler, arch_spec): monkeypatch.setattr(spack.compilers, "compilers_for_spec", compilers) - s = spack.spec.Spec("a") + s = spack.spec.Spec("pkg-a") pkg = BaseTestPackage(s) pkg.test_requires_compiler = True pkg.do_test() @@ -293,7 +294,7 @@ def compilers(compiler, arch_spec): ], ) def test_package_run_test_install( - install_mockery_mutable_config, mock_fetch, capfd, msg, installed, purpose, expected + install_mockery, mock_fetch, capfd, msg, installed, purpose, expected ): """Confirm expected outputs from run_test for installed/not installed exe.""" s = spack.spec.Spec("trivial-smoke-test").concretized() @@ -314,9 +315,7 @@ def test_package_run_test_install( (False, 1, str(spack.install_test.TestStatus.FAILED)), ], ) -def test_package_run_test_missing( - install_mockery_mutable_config, mock_fetch, capfd, skip, failures, status -): +def test_package_run_test_missing(install_mockery, mock_fetch, capfd, skip, failures, status): """Confirm expected results from run_test for missing exe when skip or not.""" s = spack.spec.Spec("trivial-smoke-test").concretized() pkg = s.package @@ -328,7 +327,7 @@ def test_package_run_test_missing( # TODO (post-34236): Remove when remove deprecated run_test(), etc. -def test_package_run_test_fail_fast(install_mockery_mutable_config, mock_fetch): +def test_package_run_test_fail_fast(install_mockery, mock_fetch): """Confirm expected exception when run_test with fail_fast enabled.""" s = spack.spec.Spec("trivial-smoke-test").concretized() pkg = s.package diff --git a/lib/spack/spack/test/packages.py b/lib/spack/spack/test/packages.py index f2507ee57e1a17..d00db3ed0cffa1 100644 --- a/lib/spack/spack/test/packages.py +++ b/lib/spack/spack/test/packages.py @@ -32,12 +32,12 @@ def test_package_name(self): assert pkg_cls.name == "mpich" def test_package_filename(self): - repo = spack.repo.Repo(mock_packages_path) + repo = spack.repo.from_path(mock_packages_path) filename = repo.filename_for_package_name("mpich") assert filename == os.path.join(mock_packages_path, "packages", "mpich", "package.py") def test_nonexisting_package_filename(self): - repo = spack.repo.Repo(mock_packages_path) + repo = spack.repo.from_path(mock_packages_path) filename = repo.filename_for_package_name("some-nonexisting-package") assert filename == os.path.join( mock_packages_path, "packages", "some-nonexisting-package", "package.py" diff --git a/lib/spack/spack/test/packaging.py b/lib/spack/spack/test/packaging.py index 92ff4f6961d6d6..aa1e50468a59b8 100644 --- a/lib/spack/spack/test/packaging.py +++ b/lib/spack/spack/test/packaging.py @@ -16,7 +16,7 @@ import pytest from llnl.util import filesystem as fs -from llnl.util.symlink import symlink +from llnl.util.symlink import readlink, symlink import spack.binary_distribution as bindist import spack.cmd.buildcache as buildcache @@ -181,12 +181,12 @@ def test_relocate_links(tmpdir): relocate_links(["to_self", "to_dependency", "to_system"], prefix_to_prefix) # These two are relocated - assert os.readlink("to_self") == str(tmpdir.join("new_prefix_a", "file")) - assert os.readlink("to_dependency") == str(tmpdir.join("new_prefix_b", "file")) + assert readlink("to_self") == str(tmpdir.join("new_prefix_a", "file")) + assert readlink("to_dependency") == str(tmpdir.join("new_prefix_b", "file")) # These two are not. - assert os.readlink("to_system") == system_path - assert os.readlink("to_self_but_relative") == "relative" + assert readlink("to_system") == system_path + assert readlink("to_self_but_relative") == "relative" def test_needs_relocation(): @@ -506,9 +506,7 @@ def fake_fn(self): "manual,instr", [(False, False), (False, True), (True, False), (True, True)] ) @pytest.mark.disable_clean_stage_check -def test_manual_download( - install_mockery, mock_download, default_mock_concretization, monkeypatch, manual, instr -): +def test_manual_download(mock_download, default_mock_concretization, monkeypatch, manual, instr): """ Ensure expected fetcher fail message based on manual download and instr. """ @@ -517,7 +515,7 @@ def test_manual_download( def _instr(pkg): return f"Download instructions for {pkg.spec.name}" - spec = default_mock_concretization("a") + spec = default_mock_concretization("pkg-a") spec.package.manual_download = manual if instr: monkeypatch.setattr(spack.package_base.PackageBase, "download_instr", _instr) @@ -539,20 +537,16 @@ def fetch(self): monkeypatch.setattr(spack.package_base.PackageBase, "fetcher", FetchingNotAllowed()) -def test_fetch_without_code_is_noop( - default_mock_concretization, install_mockery, fetching_not_allowed -): +def test_fetch_without_code_is_noop(default_mock_concretization, fetching_not_allowed): """do_fetch for packages without code should be a no-op""" - pkg = default_mock_concretization("a").package + pkg = default_mock_concretization("pkg-a").package pkg.has_code = False pkg.do_fetch() -def test_fetch_external_package_is_noop( - default_mock_concretization, install_mockery, fetching_not_allowed -): +def test_fetch_external_package_is_noop(default_mock_concretization, fetching_not_allowed): """do_fetch for packages without code should be a no-op""" - spec = default_mock_concretization("a") + spec = default_mock_concretization("pkg-a") spec.external_path = "/some/where" assert spec.external spec.package.do_fetch() diff --git a/lib/spack/spack/test/patch.py b/lib/spack/spack/test/patch.py index 3710c58303560a..4ec4cec7e79d67 100644 --- a/lib/spack/spack/test/patch.py +++ b/lib/spack/spack/test/patch.py @@ -229,7 +229,7 @@ def test_nested_directives(mock_packages): @pytest.mark.not_on_windows("Test requires Autotools") -def test_patched_dependency(mock_packages, config, install_mockery, mock_fetch): +def test_patched_dependency(mock_packages, install_mockery, mock_fetch): """Test whether patched dependencies work.""" spec = Spec("patch-a-dependency") spec.concretize() @@ -268,14 +268,11 @@ def trigger_bad_patch(pkg): def test_patch_failure_develop_spec_exits_gracefully( - mock_packages, config, install_mockery, mock_fetch, tmpdir, mock_stage + mock_packages, install_mockery, mock_fetch, tmpdir, mock_stage ): - """ - ensure that a failing patch does not trigger exceptions - for develop specs - """ + """ensure that a failing patch does not trigger exceptions for develop specs""" - spec = Spec("patch-a-dependency " "^libelf dev_path=%s" % str(tmpdir)) + spec = Spec(f"patch-a-dependency ^libelf dev_path={tmpdir}") spec.concretize() libelf = spec["libelf"] assert "patches" in list(libelf.variants.keys()) @@ -287,7 +284,7 @@ def test_patch_failure_develop_spec_exits_gracefully( # success if no exceptions raised -def test_patch_failure_restages(mock_packages, config, install_mockery, mock_fetch): +def test_patch_failure_restages(mock_packages, install_mockery, mock_fetch): """ ensure that a failing patch does not trigger exceptions for non-develop specs and the source gets restaged diff --git a/lib/spack/spack/test/relocate.py b/lib/spack/spack/test/relocate.py index 0ed6af59e28d3b..e02bc9ae3ac855 100644 --- a/lib/spack/spack/test/relocate.py +++ b/lib/spack/spack/test/relocate.py @@ -283,6 +283,14 @@ def test_relocate_text_bin_raise_if_new_prefix_is_longer(tmpdir): @pytest.mark.requires_executables("install_name_tool", "file", "cc") def test_fixup_macos_rpaths(make_dylib, make_object_file): + compiler_cls = spack.repo.PATH.get_pkg_class("apple-clang") + compiler_version = compiler_cls.determine_version("cc") + try: + # See https://forums.swift.org/t/xcode-ships-llvm-15-but-swift-builds-llvm-16/67377 + xcode_major_version = int(compiler_version.split(".")[0]) + except IndexError: + pytest.xfail("cannot determine the major version of XCode") + # For each of these tests except for the "correct" case, the first fixup # should make changes, and the second fixup should be a null-op. fixup_rpath = spack.relocate.fixup_macos_rpath @@ -293,7 +301,9 @@ def test_fixup_macos_rpaths(make_dylib, make_object_file): # Non-relocatable library id and duplicate rpaths (root, filename) = make_dylib("abs", duplicate_rpaths) - assert fixup_rpath(root, filename) + # XCode 15 ships a new linker that takes care of deduplication + if xcode_major_version < 15: + assert fixup_rpath(root, filename) assert not fixup_rpath(root, filename) # Hardcoded but relocatable library id (but we do NOT relocate) @@ -302,7 +312,9 @@ def test_fixup_macos_rpaths(make_dylib, make_object_file): # Library id uses rpath but there are extra duplicate rpaths (root, filename) = make_dylib("rpath", duplicate_rpaths) - assert fixup_rpath(root, filename) + # XCode 15 ships a new linker that takes care of deduplication + if xcode_major_version < 15: + assert fixup_rpath(root, filename) assert not fixup_rpath(root, filename) # Shared library was constructed with relocatable id from the get-go @@ -325,7 +337,9 @@ def test_fixup_macos_rpaths(make_dylib, make_object_file): # Duplicate nonexistent rpath will need *two* passes (root, filename) = make_dylib("rpath", bad_rpath * 2) assert fixup_rpath(root, filename) - assert fixup_rpath(root, filename) + # XCode 15 ships a new linker that takes care of deduplication + if xcode_major_version < 15: + assert fixup_rpath(root, filename) assert not fixup_rpath(root, filename) # Test on an object file, which *also* has type 'application/x-mach-binary' diff --git a/lib/spack/spack/test/repo.py b/lib/spack/spack/test/repo.py index 877b4af243ac50..e08d14828976a3 100644 --- a/lib/spack/spack/test/repo.py +++ b/lib/spack/spack/test/repo.py @@ -3,52 +3,62 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) import os +import pathlib import pytest import spack.package_base import spack.paths import spack.repo +import spack.spec +import spack.util.file_cache @pytest.fixture(params=["packages", "", "foo"]) -def extra_repo(tmpdir_factory, request): +def extra_repo(tmp_path_factory, request): repo_namespace = "extra_test_repo" - repo_dir = tmpdir_factory.mktemp(repo_namespace) - repo_dir.ensure(request.param, dir=True) - - with open(str(repo_dir.join("repo.yaml")), "w") as f: - f.write( + repo_dir = tmp_path_factory.mktemp(repo_namespace) + cache_dir = tmp_path_factory.mktemp("cache") + (repo_dir / request.param).mkdir(parents=True, exist_ok=True) + if request.param == "packages": + (repo_dir / "repo.yaml").write_text( """ repo: namespace: extra_test_repo """ ) - if request.param != "packages": - f.write(f" subdirectory: '{request.param}'") - return (spack.repo.Repo(str(repo_dir)), request.param) + else: + (repo_dir / "repo.yaml").write_text( + f""" +repo: + namespace: extra_test_repo + subdirectory: '{request.param}' +""" + ) + repo_cache = spack.util.file_cache.FileCache(str(cache_dir)) + return spack.repo.Repo(str(repo_dir), cache=repo_cache), request.param def test_repo_getpkg(mutable_mock_repo): - mutable_mock_repo.get_pkg_class("a") - mutable_mock_repo.get_pkg_class("builtin.mock.a") + mutable_mock_repo.get_pkg_class("pkg-a") + mutable_mock_repo.get_pkg_class("builtin.mock.pkg-a") def test_repo_multi_getpkg(mutable_mock_repo, extra_repo): mutable_mock_repo.put_first(extra_repo[0]) - mutable_mock_repo.get_pkg_class("a") - mutable_mock_repo.get_pkg_class("builtin.mock.a") + mutable_mock_repo.get_pkg_class("pkg-a") + mutable_mock_repo.get_pkg_class("builtin.mock.pkg-a") def test_repo_multi_getpkgclass(mutable_mock_repo, extra_repo): mutable_mock_repo.put_first(extra_repo[0]) - mutable_mock_repo.get_pkg_class("a") - mutable_mock_repo.get_pkg_class("builtin.mock.a") + mutable_mock_repo.get_pkg_class("pkg-a") + mutable_mock_repo.get_pkg_class("builtin.mock.pkg-a") def test_repo_pkg_with_unknown_namespace(mutable_mock_repo): with pytest.raises(spack.repo.UnknownNamespaceError): - mutable_mock_repo.get_pkg_class("unknown.a") + mutable_mock_repo.get_pkg_class("unknown.pkg-a") def test_repo_unknown_pkg(mutable_mock_repo): @@ -142,14 +152,14 @@ def test_get_all_mock_packages(mock_packages): def test_repo_path_handles_package_removal(tmpdir, mock_packages): builder = spack.repo.MockRepositoryBuilder(tmpdir, namespace="removal") - builder.add_package("c") + builder.add_package("pkg-c") with spack.repo.use_repositories(builder.root, override=False) as repos: - r = repos.repo_for_pkg("c") + r = repos.repo_for_pkg("pkg-c") assert r.namespace == "removal" - builder.remove("c") + builder.remove("pkg-c") with spack.repo.use_repositories(builder.root, override=False) as repos: - r = repos.repo_for_pkg("c") + r = repos.repo_for_pkg("pkg-c") assert r.namespace == "builtin.mock" @@ -177,8 +187,11 @@ def test_repo_dump_virtuals(tmpdir, mutable_mock_repo, mock_packages, ensure_deb ([spack.paths.mock_packages_path, spack.paths.packages_path], ["builtin.mock", "builtin"]), ], ) -def test_repository_construction_doesnt_use_globals(nullify_globals, repo_paths, namespaces): - repo_path = spack.repo.RepoPath(*repo_paths) +def test_repository_construction_doesnt_use_globals( + nullify_globals, tmp_path, repo_paths, namespaces +): + repo_cache = spack.util.file_cache.FileCache(str(tmp_path / "cache")) + repo_path = spack.repo.RepoPath(*repo_paths, cache=repo_cache) assert len(repo_path.repos) == len(namespaces) assert [x.namespace for x in repo_path.repos] == namespaces @@ -188,8 +201,117 @@ def test_path_computation_with_names(method_name, mock_repo_path): """Tests that repositories can compute the correct paths when using both fully qualified names and unqualified names. """ - repo_path = spack.repo.RepoPath(mock_repo_path) + repo_path = spack.repo.RepoPath(mock_repo_path, cache=None) method = getattr(repo_path, method_name) unqualified = method("mpileaks") qualified = method("builtin.mock.mpileaks") assert qualified == unqualified + + +def test_use_repositories_and_import(): + """Tests that use_repositories changes the import search too""" + import spack.paths + + repo_dir = pathlib.Path(spack.paths.repos_path) + with spack.repo.use_repositories(str(repo_dir / "compiler_runtime.test")): + import spack.pkg.compiler_runtime.test.gcc_runtime + + with spack.repo.use_repositories(str(repo_dir / "builtin.mock")): + import spack.pkg.builtin.mock.cmake + + +@pytest.mark.usefixtures("nullify_globals") +class TestRepo: + """Test that the Repo class work correctly, and does not depend on globals, + except the REPOS_FINDER. + """ + + def test_creation(self, mock_test_cache): + repo = spack.repo.Repo(spack.paths.mock_packages_path, cache=mock_test_cache) + assert repo.config_file.endswith("repo.yaml") + assert repo.namespace == "builtin.mock" + + @pytest.mark.parametrize( + "name,expected", [("mpi", True), ("mpich", False), ("mpileaks", False)] + ) + @pytest.mark.parametrize("repo_cls", [spack.repo.Repo, spack.repo.RepoPath]) + def test_is_virtual(self, repo_cls, name, expected, mock_test_cache): + repo = repo_cls(spack.paths.mock_packages_path, cache=mock_test_cache) + assert repo.is_virtual(name) is expected + assert repo.is_virtual_safe(name) is expected + + @pytest.mark.parametrize( + "module_name,expected", + [ + ("dla_future", "dla-future"), + ("num7zip", "7zip"), + # If no package is there, None is returned + ("unknown", None), + ], + ) + def test_real_name(self, module_name, expected, mock_test_cache): + """Test that we can correctly compute the 'real' name of a package, from the one + used to import the Python module. + """ + repo = spack.repo.Repo(spack.paths.mock_packages_path, cache=mock_test_cache) + assert repo.real_name(module_name) == expected + + @pytest.mark.parametrize("name", ["mpileaks", "7zip", "dla-future"]) + def test_get(self, name, mock_test_cache): + repo = spack.repo.Repo(spack.paths.mock_packages_path, cache=mock_test_cache) + mock_spec = spack.spec.Spec(name) + mock_spec._mark_concrete() + pkg = repo.get(mock_spec) + assert pkg.__class__ == repo.get_pkg_class(name) + + @pytest.mark.parametrize("virtual_name,expected", [("mpi", ["mpich", "zmpi"])]) + def test_providers(self, virtual_name, expected, mock_test_cache): + repo = spack.repo.Repo(spack.paths.mock_packages_path, cache=mock_test_cache) + provider_names = {x.name for x in repo.providers_for(virtual_name)} + assert provider_names.issuperset(expected) + + @pytest.mark.parametrize( + "extended,expected", + [("python", ["py-extension1", "python-venv"]), ("perl", ["perl-extension"])], + ) + @pytest.mark.parametrize("repo_cls", [spack.repo.Repo, spack.repo.RepoPath]) + def test_extensions(self, repo_cls, extended, expected, mock_test_cache): + repo = repo_cls(spack.paths.mock_packages_path, cache=mock_test_cache) + provider_names = {x.name for x in repo.extensions_for(extended)} + assert provider_names.issuperset(expected) + + @pytest.mark.parametrize("repo_cls", [spack.repo.Repo, spack.repo.RepoPath]) + def test_all_package_names(self, repo_cls, mock_test_cache): + repo = repo_cls(spack.paths.mock_packages_path, cache=mock_test_cache) + all_names = repo.all_package_names(include_virtuals=True) + real_names = repo.all_package_names(include_virtuals=False) + assert set(all_names).issuperset(real_names) + for name in set(all_names) - set(real_names): + assert repo.is_virtual(name) + assert repo.is_virtual_safe(name) + + @pytest.mark.parametrize("repo_cls", [spack.repo.Repo, spack.repo.RepoPath]) + def test_packages_with_tags(self, repo_cls, mock_test_cache): + repo = repo_cls(spack.paths.mock_packages_path, cache=mock_test_cache) + r1 = repo.packages_with_tags("tag1") + r2 = repo.packages_with_tags("tag1", "tag2") + assert "mpich" in r1 and "mpich" in r2 + assert "mpich2" in r1 and "mpich2" not in r2 + assert set(r2).issubset(r1) + + +@pytest.mark.usefixtures("nullify_globals") +class TestRepoPath: + def test_creation_from_string(self, mock_test_cache): + repo = spack.repo.RepoPath(spack.paths.mock_packages_path, cache=mock_test_cache) + assert len(repo.repos) == 1 + assert repo.repos[0]._finder is repo + assert repo.by_namespace["spack.pkg.builtin.mock"] is repo.repos[0] + + def test_get_repo(self, mock_test_cache): + repo = spack.repo.RepoPath(spack.paths.mock_packages_path, cache=mock_test_cache) + # builtin.mock is there + assert repo.get_repo("builtin.mock") is repo.repos[0] + # foo is not there, raise + with pytest.raises(spack.repo.UnknownNamespaceError): + repo.get_repo("foo") diff --git a/lib/spack/spack/test/solver/intermediate.py b/lib/spack/spack/test/solver/intermediate.py new file mode 100644 index 00000000000000..42fdb316aa1bc9 --- /dev/null +++ b/lib/spack/spack/test/solver/intermediate.py @@ -0,0 +1,51 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +"""Unit tests for objects turning configuration into an intermediate format used by the solver.""" +import pytest + +import spack.compilers +import spack.config +import spack.spec +from spack.concretize import UnavailableCompilerVersionError +from spack.solver import asp + + +class TestCompilerParser: + def test_expected_order_mock_config(self, config): + """Tests the expected preference order in the mock compiler configuration""" + parser = asp.CompilerParser(config) + expected_order = ["gcc@=10.2.1", "gcc@=9.4.0", "gcc@=9.4.0", "clang@=15.0.0"] + for c, expected in zip(parser.possible_compilers(), expected_order): + assert c.spec.satisfies(expected) + + @pytest.mark.parametrize("spec_str", ["a %gcc@=13.2.0", "a ^b %gcc@=13.2.0"]) + def test_compiler_from_input_raise(self, spec_str, config): + """Tests that having an unknown compiler in the input spec raises an exception, if we + don't allow bootstrapping missing compilers. + """ + spec = spack.spec.Spec(spec_str) + with pytest.raises(UnavailableCompilerVersionError): + asp.CompilerParser(config).with_input_specs([spec]) + + def test_compilers_inferred_from_concrete_specs(self, mutable_config, mutable_database): + """Test that compilers inferred from concrete specs, that are not in the local + configuration too, are last in the preference order. + """ + spack.compilers.remove_compiler_from_config("gcc@=10.2.1") + assert not spack.compilers.compilers_for_spec("gcc@=10.2.1") + + parser = asp.CompilerParser(mutable_config) + for reuse_spec in mutable_database.query(): + parser.add_compiler_from_concrete_spec(reuse_spec) + + expected_order = [ + ("gcc@=9.4.0", True), + ("gcc@=9.4.0", True), + ("clang@=15.0.0", True), + ("gcc@=10.2.1", False), + ] + for c, (expected, available) in zip(parser.possible_compilers(), expected_order): + assert c.spec.satisfies(expected) + assert c.available is available diff --git a/lib/spack/spack/test/spec_dag.py b/lib/spack/spack/test/spec_dag.py index da85be6d1c7e90..398741a6cfa318 100644 --- a/lib/spack/spack/test/spec_dag.py +++ b/lib/spack/spack/test/spec_dag.py @@ -138,19 +138,19 @@ def test_specify_preinstalled_dep(tmpdir, monkeypatch): transitive dependency that is only supplied by the preinstalled package. """ builder = spack.repo.MockRepositoryBuilder(tmpdir) - builder.add_package("c") - builder.add_package("b", dependencies=[("c", None, None)]) - builder.add_package("a", dependencies=[("b", None, None)]) + builder.add_package("pkg-c") + builder.add_package("pkg-b", dependencies=[("pkg-c", None, None)]) + builder.add_package("pkg-a", dependencies=[("pkg-b", None, None)]) with spack.repo.use_repositories(builder.root): - b_spec = Spec("b").concretized() - monkeypatch.setattr(Spec, "installed", property(lambda x: x.name != "a")) + b_spec = Spec("pkg-b").concretized() + monkeypatch.setattr(Spec, "installed", property(lambda x: x.name != "pkg-a")) - a_spec = Spec("a") + a_spec = Spec("pkg-a") a_spec._add_dependency(b_spec, depflag=dt.BUILD | dt.LINK, virtuals=()) a_spec.concretize() - assert set(x.name for x in a_spec.traverse()) == set(["a", "b", "c"]) + assert {x.name for x in a_spec.traverse()} == {"pkg-a", "pkg-b", "pkg-c"} @pytest.mark.usefixtures("config") @@ -978,19 +978,44 @@ def test_spec_tree_respect_deptypes(self): assert "version-test-pkg" not in out +def test_tree_cover_nodes_reduce_deptype(): + """Test that tree output with deptypes sticks to the sub-dag of interest, instead of looking + at in-edges from nodes not reachable from the root.""" + a, b, c, d = Spec("a"), Spec("b"), Spec("c"), Spec("d") + a.add_dependency_edge(d, depflag=dt.BUILD, virtuals=()) + a.add_dependency_edge(b, depflag=dt.LINK, virtuals=()) + b.add_dependency_edge(d, depflag=dt.LINK, virtuals=()) + c.add_dependency_edge(d, depflag=dt.RUN | dt.TEST, virtuals=()) + assert ( + a.tree(cover="nodes", show_types=True) + == """\ +[ ] a +[ l ] ^b +[bl ] ^d +""" + ) + assert ( + c.tree(cover="nodes", show_types=True) + == """\ +[ ] c +[ rt] ^d +""" + ) + + def test_synthetic_construction_of_split_dependencies_from_same_package(mock_packages, config): # Construct in a synthetic way (i.e. without using the solver) # the following spec: # - # b + # pkg-b # build / \ link,run - # c@2.0 c@1.0 + # pkg-c@2.0 pkg-c@1.0 # # To demonstrate that a spec can now hold two direct # dependencies from the same package - root = Spec("b").concretized() - link_run_spec = Spec("c@=1.0").concretized() - build_spec = Spec("c@=2.0").concretized() + root = Spec("pkg-b").concretized() + link_run_spec = Spec("pkg-c@=1.0").concretized() + build_spec = Spec("pkg-c@=2.0").concretized() root.add_dependency_edge(link_run_spec, depflag=dt.LINK, virtuals=()) root.add_dependency_edge(link_run_spec, depflag=dt.RUN, virtuals=()) @@ -998,10 +1023,10 @@ def test_synthetic_construction_of_split_dependencies_from_same_package(mock_pac # Check dependencies from the perspective of root assert len(root.dependencies()) == 2 - assert all(x.name == "c" for x in root.dependencies()) + assert all(x.name == "pkg-c" for x in root.dependencies()) - assert "@2.0" in root.dependencies(name="c", deptype=dt.BUILD)[0] - assert "@1.0" in root.dependencies(name="c", deptype=dt.LINK | dt.RUN)[0] + assert "@2.0" in root.dependencies(name="pkg-c", deptype=dt.BUILD)[0] + assert "@1.0" in root.dependencies(name="pkg-c", deptype=dt.LINK | dt.RUN)[0] # Check parent from the perspective of the dependencies assert len(build_spec.dependents()) == 1 @@ -1013,30 +1038,30 @@ def test_synthetic_construction_of_split_dependencies_from_same_package(mock_pac def test_synthetic_construction_bootstrapping(mock_packages, config): # Construct the following spec: # - # b@2.0 + # pkg-b@2.0 # | build - # b@1.0 + # pkg-b@1.0 # - root = Spec("b@=2.0").concretized() - bootstrap = Spec("b@=1.0").concretized() + root = Spec("pkg-b@=2.0").concretized() + bootstrap = Spec("pkg-b@=1.0").concretized() root.add_dependency_edge(bootstrap, depflag=dt.BUILD, virtuals=()) assert len(root.dependencies()) == 1 - assert root.dependencies()[0].name == "b" - assert root.name == "b" + assert root.dependencies()[0].name == "pkg-b" + assert root.name == "pkg-b" def test_addition_of_different_deptypes_in_multiple_calls(mock_packages, config): # Construct the following spec: # - # b@2.0 + # pkg-b@2.0 # | build,link,run - # b@1.0 + # pkg-b@1.0 # # with three calls and check we always have a single edge - root = Spec("b@=2.0").concretized() - bootstrap = Spec("b@=1.0").concretized() + root = Spec("pkg-b@=2.0").concretized() + bootstrap = Spec("pkg-b@=1.0").concretized() for current_depflag in (dt.BUILD, dt.LINK, dt.RUN): root.add_dependency_edge(bootstrap, depflag=current_depflag, virtuals=()) @@ -1063,9 +1088,9 @@ def test_addition_of_different_deptypes_in_multiple_calls(mock_packages, config) def test_adding_same_deptype_with_the_same_name_raises( mock_packages, config, c1_depflag, c2_depflag ): - p = Spec("b@=2.0").concretized() - c1 = Spec("b@=1.0").concretized() - c2 = Spec("b@=2.0").concretized() + p = Spec("pkg-b@=2.0").concretized() + c1 = Spec("pkg-b@=1.0").concretized() + c2 = Spec("pkg-b@=2.0").concretized() p.add_dependency_edge(c1, depflag=c1_depflag, virtuals=()) with pytest.raises(spack.error.SpackError): @@ -1105,3 +1130,23 @@ def test_indexing_prefers_direct_or_transitive_link_deps(): # Ensure that the full DAG is still searched assert root["a2"] + + +def test_getitem_sticks_to_subdag(): + """Test that indexing on Spec by virtual does not traverse outside the dag, which happens in + the unlikely case someone would rewrite __getitem__ in terms of edges_from_dependents instead + of edges_to_dependencies.""" + x, y, z = Spec("x"), Spec("y"), Spec("z") + x.add_dependency_edge(z, depflag=dt.LINK, virtuals=("virtual",)) + y.add_dependency_edge(z, depflag=dt.LINK, virtuals=()) + assert x["virtual"].name == "z" + with pytest.raises(KeyError): + y["virtual"] + + +def test_getitem_finds_transitive_virtual(): + x, y, z = Spec("x"), Spec("y"), Spec("z") + x.add_dependency_edge(z, depflag=dt.LINK, virtuals=()) + x.add_dependency_edge(y, depflag=dt.LINK, virtuals=()) + y.add_dependency_edge(z, depflag=dt.LINK, virtuals=("virtual",)) + assert x["virtual"].name == "z" diff --git a/lib/spack/spack/test/spec_list.py b/lib/spack/spack/test/spec_list.py index db31146df7cc9a..98f0f8b312a786 100644 --- a/lib/spack/spack/test/spec_list.py +++ b/lib/spack/spack/test/spec_list.py @@ -196,21 +196,29 @@ def test_spec_list_matrix_exclude(self, mock_packages): speclist = SpecList("specs", matrix) assert len(speclist.specs) == 1 - @pytest.mark.regression("22991") - def test_spec_list_constraints_with_structure( - self, mock_packages, mock_fetch, install_mockery - ): - # Setup by getting hash and installing package with dep - libdwarf_spec = Spec("libdwarf").concretized() - libdwarf_spec.package.do_install() - - # Create matrix - matrix = { - "matrix": [["mpileaks"], ["^callpath"], ["^libdwarf/%s" % libdwarf_spec.dag_hash()]] - } + def test_spec_list_exclude_with_abstract_hashes(self, mock_packages, install_mockery): + # Put mpich in the database so it can be referred to by hash. + mpich_1 = Spec("mpich+debug").concretized() + mpich_2 = Spec("mpich~debug").concretized() + mpich_1.package.do_install(fake=True) + mpich_2.package.do_install(fake=True) + + # Create matrix and exclude +debug, which excludes the first mpich after its abstract hash + # is resolved. + speclist = SpecList( + "specs", + [ + { + "matrix": [ + ["mpileaks"], + ["^callpath"], + [f"^mpich/{mpich_1.dag_hash(5)}", f"^mpich/{mpich_2.dag_hash(5)}"], + ], + "exclude": ["^mpich+debug"], + } + ], + ) - # ensure the concrete spec was retained in the matrix entry of which - # it is a dependency - speclist = SpecList("specs", [matrix]) + # Ensure that only mpich~debug is selected, and that the assembled spec remains abstract. assert len(speclist.specs) == 1 - assert libdwarf_spec in speclist.specs[0] + assert speclist.specs[0] == Spec(f"mpileaks ^callpath ^mpich/{mpich_2.dag_hash(5)}") diff --git a/lib/spack/spack/test/spec_semantics.py b/lib/spack/spack/test/spec_semantics.py index 8421f9bed81d5f..12fa28a2db9972 100644 --- a/lib/spack/spack/test/spec_semantics.py +++ b/lib/spack/spack/test/spec_semantics.py @@ -373,7 +373,7 @@ def test_satisfies_single_valued_variant(self): https://github.com/spack/spack/pull/2386#issuecomment-282147639 is handled correctly. """ - a = Spec("a foobar=bar") + a = Spec("pkg-a foobar=bar") a.concretize() assert a.satisfies("foobar=bar") @@ -390,21 +390,21 @@ def test_satisfies_single_valued_variant(self): assert "foo=bar" in a # Check that conditional dependencies are treated correctly - assert "^b" in a + assert "^pkg-b" in a def test_unsatisfied_single_valued_variant(self): - a = Spec("a foobar=baz") + a = Spec("pkg-a foobar=baz") a.concretize() - assert "^b" not in a + assert "^pkg-b" not in a mv = Spec("multivalue-variant") mv.concretize() - assert "a@1.0" not in mv + assert "pkg-a@1.0" not in mv def test_indirect_unsatisfied_single_valued_variant(self): spec = Spec("singlevalue-variant-dependent") spec.concretize() - assert "a@1.0" not in spec + assert "pkg-a@1.0" not in spec def test_unsatisfiable_multi_value_variant(self, default_mock_concretization): # Semantics for a multi-valued variant is different @@ -703,22 +703,25 @@ def check_prop(check_spec, fmt_str, prop, getter): actual = spec.format(named_str) assert expected == actual - def test_spec_formatting_escapes(self, default_mock_concretization): - spec = default_mock_concretization("multivalue-variant cflags=-O2") - - sigil_mismatches = [ + @pytest.mark.parametrize( + "fmt_str", + [ "{@name}", "{@version.concrete}", "{%compiler.version}", "{/hashd}", "{arch=architecture.os}", - ] + ], + ) + def test_spec_formatting_sigil_mismatches(self, default_mock_concretization, fmt_str): + spec = default_mock_concretization("multivalue-variant cflags=-O2") - for fmt_str in sigil_mismatches: - with pytest.raises(SpecFormatSigilError): - spec.format(fmt_str) + with pytest.raises(SpecFormatSigilError): + spec.format(fmt_str) - bad_formats = [ + @pytest.mark.parametrize( + "fmt_str", + [ r"{}", r"name}", r"\{name}", @@ -728,23 +731,12 @@ def test_spec_formatting_escapes(self, default_mock_concretization): r"{dag_hash}", r"{foo}", r"{+variants.debug}", - ] - - for fmt_str in bad_formats: - with pytest.raises(SpecFormatStringError): - spec.format(fmt_str) - - @pytest.mark.regression("9908") - def test_spec_flags_maintain_order(self): - # Spack was assembling flags in a manner that could result in - # different orderings for repeated concretizations of the same - # spec and config - spec_str = "libelf %gcc@11.1.0 os=redhat6" - for _ in range(3): - s = Spec(spec_str).concretized() - assert all( - s.compiler_flags[x] == ["-O0", "-g"] for x in ("cflags", "cxxflags", "fflags") - ) + ], + ) + def test_spec_formatting_bad_formats(self, default_mock_concretization, fmt_str): + spec = default_mock_concretization("multivalue-variant cflags=-O2") + with pytest.raises(SpecFormatStringError): + spec.format(fmt_str) def test_combination_of_wildcard_or_none(self): # Test that using 'none' and another value raises @@ -994,8 +986,8 @@ def test_splice_swap_names_mismatch_virtuals(self, default_mock_concretization, spec.splice(dep, transitive) def test_spec_override(self): - init_spec = Spec("a foo=baz foobar=baz cflags=-O3 cxxflags=-O1") - change_spec = Spec("a foo=fee cflags=-O2") + init_spec = Spec("pkg-a foo=baz foobar=baz cflags=-O3 cxxflags=-O1") + change_spec = Spec("pkg-a foo=fee cflags=-O2") new_spec = Spec.override(init_spec, change_spec) new_spec.concretize() assert "foo=fee" in new_spec @@ -1108,22 +1100,22 @@ def test_unsatisfiable_virtual_deps_bindings(self, spec_str): @pytest.mark.parametrize( "spec_str,format_str,expected", [ - ("zlib@git.foo/bar", "{name}-{version}", str(pathlib.Path("zlib-git.foo_bar"))), - ("zlib@git.foo/bar", "{name}-{version}-{/hash}", None), - ("zlib@git.foo/bar", "{name}/{version}", str(pathlib.Path("zlib", "git.foo_bar"))), + ("git-test@git.foo/bar", "{name}-{version}", str(pathlib.Path("git-test-git.foo_bar"))), + ("git-test@git.foo/bar", "{name}-{version}-{/hash}", None), + ("git-test@git.foo/bar", "{name}/{version}", str(pathlib.Path("git-test", "git.foo_bar"))), ( - "zlib@{0}=1.0%gcc".format("a" * 40), + "git-test@{0}=1.0%gcc".format("a" * 40), "{name}/{version}/{compiler}", - str(pathlib.Path("zlib", "{0}_1.0".format("a" * 40), "gcc")), + str(pathlib.Path("git-test", "{0}_1.0".format("a" * 40), "gcc")), ), ( - "zlib@git.foo/bar=1.0%gcc", + "git-test@git.foo/bar=1.0%gcc", "{name}/{version}/{compiler}", - str(pathlib.Path("zlib", "git.foo_bar_1.0", "gcc")), + str(pathlib.Path("git-test", "git.foo_bar_1.0", "gcc")), ), ], ) -def test_spec_format_path(spec_str, format_str, expected): +def test_spec_format_path(spec_str, format_str, expected, mock_git_test_package): _check_spec_format_path(spec_str, format_str, expected) @@ -1141,45 +1133,57 @@ def _check_spec_format_path(spec_str, format_str, expected, path_ctor=None): "spec_str,format_str,expected", [ ( - "zlib@git.foo/bar", + "git-test@git.foo/bar", r"C:\\installroot\{name}\{version}", - r"C:\installroot\zlib\git.foo_bar", + r"C:\installroot\git-test\git.foo_bar", ), ( - "zlib@git.foo/bar", + "git-test@git.foo/bar", r"\\hostname\sharename\{name}\{version}", - r"\\hostname\sharename\zlib\git.foo_bar", + r"\\hostname\sharename\git-test\git.foo_bar", + ), + # leading '/' is preserved on windows but converted to '\' + # note that it's still not "absolute" -- absolute windows paths start with a drive. + ( + "git-test@git.foo/bar", + r"/installroot/{name}/{version}", + r"\installroot\git-test\git.foo_bar", ), - # Windows doesn't attribute any significance to a leading - # "/" so it is discarded - ("zlib@git.foo/bar", r"/installroot/{name}/{version}", r"installroot\zlib\git.foo_bar"), ], ) -def test_spec_format_path_windows(spec_str, format_str, expected): +def test_spec_format_path_windows(spec_str, format_str, expected, mock_git_test_package): _check_spec_format_path(spec_str, format_str, expected, path_ctor=pathlib.PureWindowsPath) @pytest.mark.parametrize( "spec_str,format_str,expected", [ - ("zlib@git.foo/bar", r"/installroot/{name}/{version}", "/installroot/zlib/git.foo_bar"), - ("zlib@git.foo/bar", r"//installroot/{name}/{version}", "//installroot/zlib/git.foo_bar"), + ( + "git-test@git.foo/bar", + r"/installroot/{name}/{version}", + "/installroot/git-test/git.foo_bar", + ), + ( + "git-test@git.foo/bar", + r"//installroot/{name}/{version}", + "//installroot/git-test/git.foo_bar", + ), # This is likely unintentional on Linux: Firstly, "\" is not a # path separator for POSIX, so this is treated as a single path # component (containing literal "\" characters); secondly, # Spec.format treats "\" as an escape character, so is # discarded (unless directly following another "\") ( - "zlib@git.foo/bar", + "git-test@git.foo/bar", r"C:\\installroot\package-{name}-{version}", - r"C__installrootpackage-zlib-git.foo_bar", + r"C__installrootpackage-git-test-git.foo_bar", ), # "\" is not a POSIX separator, and Spec.format treats "\{" as a literal # "{", which means that the resulting format string is invalid - ("zlib@git.foo/bar", r"package\{name}\{version}", None), + ("git-test@git.foo/bar", r"package\{name}\{version}", None), ], ) -def test_spec_format_path_posix(spec_str, format_str, expected): +def test_spec_format_path_posix(spec_str, format_str, expected, mock_git_test_package): _check_spec_format_path(spec_str, format_str, expected, path_ctor=pathlib.PurePosixPath) @@ -1343,15 +1347,15 @@ def test_spec_installed(default_mock_concretization, database): spec = Spec("not-a-real-package") assert not spec.installed - # 'a' is not in the mock DB and is not installed - spec = default_mock_concretization("a") + # pkg-a is not in the mock DB and is not installed + spec = default_mock_concretization("pkg-a") assert not spec.installed @pytest.mark.regression("30678") def test_call_dag_hash_on_old_dag_hash_spec(mock_packages, default_mock_concretization): # create a concrete spec - a = default_mock_concretization("a") + a = default_mock_concretization("pkg-a") dag_hashes = {spec.name: spec.dag_hash() for spec in a.traverse()} # make it look like an old DAG hash spec with no package hash on the spec. @@ -1410,8 +1414,8 @@ def test_unsupported_compiler(): def test_package_hash_affects_dunder_and_dag_hash(mock_packages, default_mock_concretization): - a1 = default_mock_concretization("a") - a2 = default_mock_concretization("a") + a1 = default_mock_concretization("pkg-a") + a2 = default_mock_concretization("pkg-a") assert hash(a1) == hash(a2) assert a1.dag_hash() == a2.dag_hash() @@ -1435,8 +1439,8 @@ def test_intersects_and_satisfies_on_concretized_spec(default_mock_concretizatio """Test that a spec obtained by concretizing an abstract spec, satisfies the abstract spec but not vice-versa. """ - a1 = default_mock_concretization("a@1.0") - a2 = Spec("a@1.0") + a1 = default_mock_concretization("pkg-a@1.0") + a2 = Spec("pkg-a@1.0") assert a1.intersects(a2) assert a2.intersects(a1) @@ -1562,17 +1566,17 @@ def test_constrain(factory, lhs_str, rhs_str, result, constrained_str): def test_abstract_hash_intersects_and_satisfies(default_mock_concretization): - concrete: Spec = default_mock_concretization("a") + concrete: Spec = default_mock_concretization("pkg-a") hash = concrete.dag_hash() hash_5 = hash[:5] hash_6 = hash[:6] # abstract hash that doesn't have a common prefix with the others. hash_other = f"{'a' if hash_5[0] == 'b' else 'b'}{hash_5[1:]}" - abstract_5 = Spec(f"a/{hash_5}") - abstract_6 = Spec(f"a/{hash_6}") - abstract_none = Spec(f"a/{hash_other}") - abstract = Spec("a") + abstract_5 = Spec(f"pkg-a/{hash_5}") + abstract_6 = Spec(f"pkg-a/{hash_6}") + abstract_none = Spec(f"pkg-a/{hash_other}") + abstract = Spec("pkg-a") def assert_subset(a: Spec, b: Spec): assert a.intersects(b) and b.intersects(a) and a.satisfies(b) and not b.satisfies(a) @@ -1609,6 +1613,6 @@ def test_edge_equality_does_not_depend_on_virtual_order(): def test_old_format_strings_trigger_error(default_mock_concretization): - s = Spec("a").concretized() + s = Spec("pkg-a").concretized() with pytest.raises(SpecFormatStringError): s.format("${PACKAGE}-${VERSION}-${HASH}") diff --git a/lib/spack/spack/test/spec_syntax.py b/lib/spack/spack/test/spec_syntax.py index 49f6de3b65ee58..e17ed724a4feca 100644 --- a/lib/spack/spack/test/spec_syntax.py +++ b/lib/spack/spack/test/spec_syntax.py @@ -551,12 +551,12 @@ def _specfile_for(spec_str, filename): "^[deptypes=build,link] zlib", ), ( - "zlib@git.foo/bar", + "git-test@git.foo/bar", [ - Token(TokenType.UNQUALIFIED_PACKAGE_NAME, "zlib"), + Token(TokenType.UNQUALIFIED_PACKAGE_NAME, "git-test"), Token(TokenType.GIT_VERSION, "@git.foo/bar"), ], - "zlib@git.foo/bar", + "git-test@git.foo/bar", ), # Variant propagation ( @@ -585,7 +585,7 @@ def _specfile_for(spec_str, filename): ), ], ) -def test_parse_single_spec(spec_str, tokens, expected_roundtrip): +def test_parse_single_spec(spec_str, tokens, expected_roundtrip, mock_git_test_package): parser = SpecParser(spec_str) assert tokens == parser.tokens() assert expected_roundtrip == str(parser.next_spec()) @@ -759,7 +759,7 @@ def test_spec_by_hash_tokens(text, tokens): @pytest.mark.db def test_spec_by_hash(database, monkeypatch, config): mpileaks = database.query_one("mpileaks ^zmpi") - b = spack.spec.Spec("b").concretized() + b = spack.spec.Spec("pkg-b").concretized() monkeypatch.setattr(spack.binary_distribution, "update_cache_and_get_specs", lambda: [b]) hash_str = f"/{mpileaks.dag_hash()}" @@ -851,12 +851,12 @@ def test_multiple_specs_with_hash(database, config): @pytest.mark.db -def test_ambiguous_hash(mutable_database, default_mock_concretization, config): +def test_ambiguous_hash(mutable_database): """Test that abstract hash ambiguity is delayed until concretization. In the past this ambiguity error would happen during parse time.""" # This is a very sketchy as manually setting hashes easily breaks invariants - x1 = default_mock_concretization("a") + x1 = spack.spec.Spec("pkg-a").concretized() x2 = x1.copy() x1._hash = "xyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy" x1._process_hash = "xyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy" @@ -874,7 +874,7 @@ def test_ambiguous_hash(mutable_database, default_mock_concretization, config): s1.lookup_hash() # ambiguity in first hash character AND spec name - s2 = SpecParser("a/x").next_spec() + s2 = SpecParser("pkg-a/x").next_spec() with pytest.raises(spack.spec.AmbiguousHashError): s2.lookup_hash() diff --git a/lib/spack/spack/test/spec_yaml.py b/lib/spack/spack/test/spec_yaml.py index 5dd854628af9ad..3f20e5626eee10 100644 --- a/lib/spack/spack/test/spec_yaml.py +++ b/lib/spack/spack/test/spec_yaml.py @@ -13,10 +13,12 @@ import collections.abc import gzip import inspect +import io import json import os import pytest +import ruamel.yaml import spack.hash_types as ht import spack.paths @@ -314,23 +316,23 @@ def test_save_dependency_spec_jsons_subset(tmpdir, config): output_path = str(tmpdir.mkdir("spec_jsons")) builder = spack.repo.MockRepositoryBuilder(tmpdir.mkdir("mock-repo")) - builder.add_package("g") - builder.add_package("f") - builder.add_package("e") - builder.add_package("d", dependencies=[("f", None, None), ("g", None, None)]) - builder.add_package("c") - builder.add_package("b", dependencies=[("d", None, None), ("e", None, None)]) - builder.add_package("a", dependencies=[("b", None, None), ("c", None, None)]) + builder.add_package("pkg-g") + builder.add_package("pkg-f") + builder.add_package("pkg-e") + builder.add_package("pkg-d", dependencies=[("pkg-f", None, None), ("pkg-g", None, None)]) + builder.add_package("pkg-c") + builder.add_package("pkg-b", dependencies=[("pkg-d", None, None), ("pkg-e", None, None)]) + builder.add_package("pkg-a", dependencies=[("pkg-b", None, None), ("pkg-c", None, None)]) with spack.repo.use_repositories(builder.root): - spec_a = Spec("a").concretized() - b_spec = spec_a["b"] - c_spec = spec_a["c"] + spec_a = Spec("pkg-a").concretized() + b_spec = spec_a["pkg-b"] + c_spec = spec_a["pkg-c"] - save_dependency_specfiles(spec_a, output_path, [Spec("b"), Spec("c")]) + save_dependency_specfiles(spec_a, output_path, [Spec("pkg-b"), Spec("pkg-c")]) - assert check_specs_equal(b_spec, os.path.join(output_path, "b.json")) - assert check_specs_equal(c_spec, os.path.join(output_path, "c.json")) + assert check_specs_equal(b_spec, os.path.join(output_path, "pkg-b.json")) + assert check_specs_equal(c_spec, os.path.join(output_path, "pkg-c.json")) def test_legacy_yaml(tmpdir, install_mockery, mock_packages): @@ -505,3 +507,50 @@ def test_load_json_specfiles(specfile, expected_hash, reader_cls): # JSON or YAML file, not a list for edge in s2.traverse_edges(): assert isinstance(edge.virtuals, tuple), edge + + +def test_anchorify_1(): + """Test that anchorify replaces duplicate values with references to a single instance, and + that that results in anchors in the output YAML.""" + before = {"a": [1, 2, 3], "b": [1, 2, 3]} + after = {"a": [1, 2, 3], "b": [1, 2, 3]} + syaml.anchorify(after) + assert before == after + assert after["a"] is after["b"] + + # Check if anchors are used + out = io.StringIO() + ruamel.yaml.YAML().dump(after, out) + assert ( + out.getvalue() + == """\ +a: &id001 +- 1 +- 2 +- 3 +b: *id001 +""" + ) + + +def test_anchorify_2(): + before = {"a": {"b": {"c": True}}, "d": {"b": {"c": True}}, "e": {"c": True}} + after = {"a": {"b": {"c": True}}, "d": {"b": {"c": True}}, "e": {"c": True}} + syaml.anchorify(after) + assert before == after + assert after["a"] is after["d"] + assert after["a"]["b"] is after["e"] + + # Check if anchors are used + out = io.StringIO() + ruamel.yaml.YAML().dump(after, out) + assert ( + out.getvalue() + == """\ +a: &id001 + b: &id002 + c: true +d: *id001 +e: *id002 +""" + ) diff --git a/lib/spack/spack/test/stage.py b/lib/spack/spack/test/stage.py index 37e8fd455929d9..7bb7f3753ac25c 100644 --- a/lib/spack/spack/test/stage.py +++ b/lib/spack/spack/test/stage.py @@ -15,6 +15,7 @@ import pytest from llnl.util.filesystem import getuid, mkdirp, partition_path, touch, working_dir +from llnl.util.symlink import readlink import spack.error import spack.paths @@ -22,7 +23,7 @@ import spack.util.executable import spack.util.url as url_util from spack.resource import Resource -from spack.stage import DevelopStage, DIYStage, ResourceStage, Stage, StageComposite +from spack.stage import DevelopStage, ResourceStage, Stage, StageComposite from spack.util.path import canonicalize_path # The following values are used for common fetch and stage mocking fixtures: @@ -145,9 +146,8 @@ def check_destroy(stage, stage_name): assert not os.path.exists(stage_path) # tmp stage needs to remove tmp dir too. - if not isinstance(stage, DIYStage): - target = os.path.realpath(stage_path) - assert not os.path.exists(target) + target = os.path.realpath(stage_path) + assert not os.path.exists(target) def check_setup(stage, stage_name, archive): @@ -800,62 +800,6 @@ def test_stage_constructor_with_path(self, tmpdir): with Stage("file:///does-not-exist", path=testpath) as stage: assert stage.path == testpath - def test_diystage_path_none(self): - """Ensure DIYStage for path=None behaves as expected.""" - with pytest.raises(ValueError): - DIYStage(None) - - def test_diystage_path_invalid(self): - """Ensure DIYStage for an invalid path behaves as expected.""" - with pytest.raises(spack.stage.StagePathError): - DIYStage("/path/does/not/exist") - - def test_diystage_path_valid(self, tmpdir): - """Ensure DIYStage for a valid path behaves as expected.""" - path = str(tmpdir) - stage = DIYStage(path) - assert stage.path == path - assert stage.source_path == path - - # Order doesn't really matter for DIYStage since they are - # basically NOOPs; however, call each since they are part - # of the normal stage usage and to ensure full test coverage. - stage.create() # Only sets the flag value - assert stage.created - - stage.cache_local() # Only outputs a message - stage.fetch() # Only outputs a message - stage.check() # Only outputs a message - stage.expand_archive() # Only outputs a message - - assert stage.expanded # The path/source_path does exist - - with pytest.raises(spack.stage.RestageError): - stage.restage() - - stage.destroy() # A no-op - assert stage.path == path # Ensure can still access attributes - assert os.path.exists(stage.source_path) # Ensure path still exists - - def test_diystage_preserve_file(self, tmpdir): - """Ensure DIYStage preserves an existing file.""" - # Write a file to the temporary directory - fn = tmpdir.join(_readme_fn) - fn.write(_readme_contents) - - # Instantiate the DIYStage and ensure the above file is unchanged. - path = str(tmpdir) - stage = DIYStage(path) - assert os.path.isdir(path) - assert os.path.isfile(str(fn)) - - stage.create() # Only sets the flag value - - readmefn = str(fn) - assert os.path.isfile(readmefn) - with open(readmefn) as _file: - _file.read() == _readme_contents - def _create_files_from_tree(base, tree): for name, content in tree.items(): @@ -872,7 +816,7 @@ def _create_files_from_tree(base, tree): def _create_tree_from_dir_recursive(path): if os.path.islink(path): - return os.readlink(path) + return readlink(path) elif os.path.isdir(path): tree = {} for name in os.listdir(path): @@ -909,18 +853,20 @@ def test_develop_stage(self, develop_path, tmp_build_stage_dir): """ devtree, srcdir = develop_path stage = DevelopStage("test-stage", srcdir, reference_link="link-to-stage") + assert not os.path.exists(stage.reference_link) stage.create() + assert os.path.exists(stage.reference_link) srctree1 = _create_tree_from_dir_recursive(stage.source_path) assert os.path.samefile(srctree1["link-to-stage"], stage.path) del srctree1["link-to-stage"] assert srctree1 == devtree stage.destroy() + assert not os.path.exists(stage.reference_link) # Make sure destroying the stage doesn't change anything # about the path assert not os.path.exists(stage.path) srctree2 = _create_tree_from_dir_recursive(srcdir) - del srctree2["link-to-stage"] # Note the symlink persists but is broken assert srctree2 == devtree diff --git a/lib/spack/spack/test/test_suite.py b/lib/spack/spack/test/test_suite.py index 6af98b6f2f1bc3..8820abe602e070 100644 --- a/lib/spack/spack/test/test_suite.py +++ b/lib/spack/spack/test/test_suite.py @@ -291,7 +291,7 @@ def test_process_test_parts(mock_packages): assert "test suite is missing" in str(exc_info) -def test_test_part_fail(tmpdir, install_mockery_mutable_config, mock_fetch, mock_test_stage): +def test_test_part_fail(tmpdir, install_mockery, mock_fetch, mock_test_stage): """Confirm test_part with a ProcessError results in FAILED status.""" s = spack.spec.Spec("trivial-smoke-test").concretized() pkg = s.package @@ -307,7 +307,7 @@ def test_test_part_fail(tmpdir, install_mockery_mutable_config, mock_fetch, mock assert status == TestStatus.FAILED -def test_test_part_pass(install_mockery_mutable_config, mock_fetch, mock_test_stage): +def test_test_part_pass(install_mockery, mock_fetch, mock_test_stage): """Confirm test_part that succeeds results in PASSED status.""" s = spack.spec.Spec("trivial-smoke-test").concretized() pkg = s.package @@ -323,7 +323,7 @@ def test_test_part_pass(install_mockery_mutable_config, mock_fetch, mock_test_st assert status == TestStatus.PASSED -def test_test_part_skip(install_mockery_mutable_config, mock_fetch, mock_test_stage): +def test_test_part_skip(install_mockery, mock_fetch, mock_test_stage): """Confirm test_part that raises SkipTest results in test status SKIPPED.""" s = spack.spec.Spec("trivial-smoke-test").concretized() pkg = s.package @@ -337,9 +337,7 @@ def test_test_part_skip(install_mockery_mutable_config, mock_fetch, mock_test_st assert status == TestStatus.SKIPPED -def test_test_part_missing_exe_fail_fast( - tmpdir, install_mockery_mutable_config, mock_fetch, mock_test_stage -): +def test_test_part_missing_exe_fail_fast(tmpdir, install_mockery, mock_fetch, mock_test_stage): """Confirm test_part with fail fast enabled raises exception.""" s = spack.spec.Spec("trivial-smoke-test").concretized() pkg = s.package @@ -360,9 +358,7 @@ def test_test_part_missing_exe_fail_fast( assert status == TestStatus.FAILED -def test_test_part_missing_exe( - tmpdir, install_mockery_mutable_config, mock_fetch, mock_test_stage -): +def test_test_part_missing_exe(tmpdir, install_mockery, mock_fetch, mock_test_stage): """Confirm test_part with missing executable fails.""" s = spack.spec.Spec("trivial-smoke-test").concretized() pkg = s.package @@ -396,7 +392,7 @@ def test_test_part_missing_exe( ], ) def test_embedded_test_part_status( - install_mockery_mutable_config, mock_fetch, mock_test_stage, current, substatuses, expected + install_mockery, mock_fetch, mock_test_stage, current, substatuses, expected ): """Check to ensure the status of the enclosing test part reflects summary of embedded parts.""" @@ -424,7 +420,7 @@ def test_embedded_test_part_status( ], ) def test_write_tested_status( - tmpdir, install_mockery_mutable_config, mock_fetch, mock_test_stage, statuses, expected + tmpdir, install_mockery, mock_fetch, mock_test_stage, statuses, expected ): """Check to ensure the status of the enclosing test part reflects summary of embedded parts.""" s = spack.spec.Spec("trivial-smoke-test").concretized() @@ -441,9 +437,7 @@ def test_write_tested_status( @pytest.mark.regression("37840") -def test_write_tested_status_no_repeats( - tmpdir, install_mockery_mutable_config, mock_fetch, mock_test_stage -): +def test_write_tested_status_no_repeats(tmpdir, install_mockery, mock_fetch, mock_test_stage): """Emulate re-running the same stand-alone tests a second time.""" s = spack.spec.Spec("trivial-smoke-test").concretized() pkg = s.package @@ -519,7 +513,7 @@ def test_find_required_file(tmpdir): def test_packagetest_fails(mock_packages): MyPackage = collections.namedtuple("MyPackage", ["spec"]) - s = spack.spec.Spec("a") + s = spack.spec.Spec("pkg-a") pkg = MyPackage(s) with pytest.raises(ValueError, match="require a concrete package"): spack.install_test.PackageTest(pkg) diff --git a/lib/spack/spack/test/traverse.py b/lib/spack/spack/test/traverse.py index 0876c65cc229a4..79e05c0b2c369c 100644 --- a/lib/spack/spack/test/traverse.py +++ b/lib/spack/spack/test/traverse.py @@ -272,6 +272,29 @@ def test_breadth_first_versus_depth_first_tree(abstract_specs_chain): ] +@pytest.mark.parametrize("cover", ["nodes", "edges"]) +@pytest.mark.parametrize("depth_first", [True, False]) +def test_tree_traversal_with_key(cover, depth_first, abstract_specs_chain): + """Compare two multisource traversals of the same DAG. In one case the DAG consists of unique + Spec instances, in the second case there are identical copies of nodes and edges. Traversal + should be equivalent when nodes are identified by dag_hash.""" + a = abstract_specs_chain["chain-a"] + c = abstract_specs_chain["chain-c"] + kwargs = {"cover": cover, "depth_first": depth_first} + dag_hash = lambda s: s.dag_hash() + + # Traverse DAG spanned by a unique set of Spec instances + first = traverse.traverse_tree([a, c], key=id, **kwargs) + + # Traverse equivalent DAG with copies of Spec instances included, keyed by dag hash. + second = traverse.traverse_tree([a, c.copy()], key=dag_hash, **kwargs) + + # Check that the same nodes are discovered at the same depth + node_at_depth_first = [(depth, dag_hash(edge.spec)) for (depth, edge) in first] + node_at_depth_second = [(depth, dag_hash(edge.spec)) for (depth, edge) in second] + assert node_at_depth_first == node_at_depth_second + + def test_breadth_first_versus_depth_first_printing(abstract_specs_chain): """Test breadth-first versus depth-first tree printing.""" s = abstract_specs_chain["chain-a"] diff --git a/lib/spack/spack/test/url_fetch.py b/lib/spack/spack/test/url_fetch.py index 406344ebfb8863..dadac0944e1803 100644 --- a/lib/spack/spack/test/url_fetch.py +++ b/lib/spack/spack/test/url_fetch.py @@ -173,8 +173,6 @@ def test_fetch( assert "echo Building..." in contents -# TODO-27021 -@pytest.mark.not_on_windows("Not supported on Windows (yet)") @pytest.mark.parametrize( "spec,url,digest", [ @@ -205,21 +203,14 @@ def test_from_list_url(mock_packages, config, spec, url, digest, _fetch_method): assert fetch_strategy.extra_options == {"timeout": 60} -@pytest.mark.not_on_windows("Not supported on Windows (yet)") @pytest.mark.parametrize("_fetch_method", ["curl", "urllib"]) @pytest.mark.parametrize( "requested_version,tarball,digest", [ - # This version is in the web data path (test/data/web/4.html), but not in the + # These versions are in the web data path (test/data/web/4.html), but not in the # url-list-test package. We expect Spack to generate a URL with the new version. ("=4.5.0", "foo-4.5.0.tar.gz", None), - # This version is in web data path and not in the package file, BUT the 2.0.0b2 - # version in the package file satisfies 2.0.0, so Spack will use the known version. - # TODO: this is *probably* not what the user wants, but it's here as an example - # TODO: for that reason. We can't express "exactly 2.0.0" right now, and we don't - # TODO: have special cases that would make 2.0.0b2 less than 2.0.0. We should - # TODO: probably revisit this in our versioning scheme. - ("2.0.0", "foo-2.0.0b2.tar.gz", "000000000000000000000000000200b2"), + ("=2.0.0", "foo-2.0.0.tar.gz", None), ], ) @pytest.mark.only_clingo("Original concretizer doesn't resolve concrete versions to known ones") @@ -228,7 +219,7 @@ def test_new_version_from_list_url( ): """Test non-specific URLs from the url-list-test package.""" with spack.config.override("config:url_fetch_method", _fetch_method): - s = Spec("url-list-test @%s" % requested_version).concretized() + s = Spec(f"url-list-test @{requested_version}").concretized() fetch_strategy = fs.from_list_url(s.package) assert isinstance(fetch_strategy, fs.URLFetchStrategy) diff --git a/lib/spack/spack/test/url_parse.py b/lib/spack/spack/test/url_parse.py index 2a3e3e7e727617..00591b2f37fe1d 100644 --- a/lib/spack/spack/test/url_parse.py +++ b/lib/spack/spack/test/url_parse.py @@ -87,6 +87,13 @@ def test_url_strip_name_suffixes(url, version, expected): 59, "https://github.com/nextflow-io/nextflow/releases/download/v0.20.1/nextflow", ), + ( + "hpcviewer", + 30, + "2024.02", + 51, + "https://gitlab.com/hpctoolkit/hpcviewer/-/releases/2024.02/downloads/hpcviewer.tgz", + ), # Version in stem ("zlib", 24, "1.2.10", 29, "http://zlib.net/fossils/zlib-1.2.10.tar.gz"), ( diff --git a/lib/spack/spack/test/util/compression.py b/lib/spack/spack/test/util/compression.py index ab38da78ac1387..f3660e4ddab4d6 100644 --- a/lib/spack/spack/test/util/compression.py +++ b/lib/spack/spack/test/util/compression.py @@ -29,7 +29,9 @@ ] # Spack does not use Python native handling for tarballs or zip # Don't test tarballs or zip in native test -native_archive_list = [key for key in ext_archive.keys() if "tar" not in key and "zip" not in key] +native_archive_list = [ + key for key in ext_archive.keys() if "tar" not in key and "zip" not in key and "whl" not in key +] @pytest.fixture @@ -71,7 +73,9 @@ def test_native_unpacking(tmpdir_factory, archive_file_and_extension): @pytest.mark.not_on_windows("Only Python unpacking available on Windows") @pytest.mark.parametrize( - "archive_file_and_extension", [(ext, True) for ext in ext_archive.keys()], indirect=True + "archive_file_and_extension", + [(ext, True) for ext in ext_archive.keys() if "whl" not in ext], + indirect=True, ) def test_system_unpacking(tmpdir_factory, archive_file_and_extension, compr_support_check): # actually run test diff --git a/lib/spack/spack/test/util/libc.py b/lib/spack/spack/test/util/libc.py new file mode 100644 index 00000000000000..f0ccc27a513936 --- /dev/null +++ b/lib/spack/spack/test/util/libc.py @@ -0,0 +1,26 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +import pytest + +from spack.util import libc + + +@pytest.mark.parametrize( + "libc_prefix,startfile_prefix,expected", + [ + # Ubuntu + ("/usr", "/usr/lib/x86_64-linux-gnu", "/usr/include/x86_64-linux-gnu"), + ("/usr", "/usr/lib/x86_64-linux-musl", "/usr/include/x86_64-linux-musl"), + ("/usr", "/usr/lib/aarch64-linux-gnu", "/usr/include/aarch64-linux-gnu"), + ("/usr", "/usr/lib/aarch64-linux-musl", "/usr/include/aarch64-linux-musl"), + # rhel-like + ("/usr", "/usr/lib64", "/usr/include"), + ("/usr", "/usr/lib", "/usr/include"), + ], +) +@pytest.mark.not_on_windows("The unit test deals with unix-like paths") +def test_header_dir_computation(libc_prefix, startfile_prefix, expected): + """Tests that we compute the correct header directory from the prefix of the libc startfiles""" + assert libc.libc_include_dir_from_startfile_prefix(libc_prefix, startfile_prefix) == expected diff --git a/lib/spack/spack/test/util/util_url.py b/lib/spack/spack/test/util/util_url.py index e2b403f82e2f29..befaaef1cd0620 100644 --- a/lib/spack/spack/test/util/util_url.py +++ b/lib/spack/spack/test/util/util_url.py @@ -207,3 +207,29 @@ def test_default_download_name_dot_dot(): assert url_util.default_download_filename("https://example.com/.") == "_" assert url_util.default_download_filename("https://example.com/..") == "_." assert url_util.default_download_filename("https://example.com/.abcdef") == "_abcdef" + + +def test_parse_link_rel_next(): + parse = url_util.parse_link_rel_next + assert parse(r'; rel="next"') == "/abc" + assert parse(r'; x=y; rel="next", ; x=y; rel="prev"') == "/abc" + assert parse(r'; rel="prev"; x=y, ; x=y; rel="next"') == "/def" + + # example from RFC5988 + assert ( + parse( + r"""; title*=UTF-8'de'letztes%20Kapitel; rel="previous",""" + r"""; title*=UTF-8'de'n%c3%a4chstes%20Kapitel; rel="next" """ + ) + == "/TheBook/chapter4" + ) + + assert ( + parse(r"""; key=";a=b, ; e=f"; rel="next" """) + == "https://example.com/example" + ) + + assert parse("https://example.com/example") is None + assert parse(" str: return destination_abspath +def _do_nothing(archive_file: str) -> None: + return None + + def _unzip(archive_file: str) -> str: """Returns path to extracted zip archive. Extract Zipfile, searching for unzip system executable. If unavailable, search for 'tar' executable on system and use instead. @@ -283,7 +287,7 @@ def decompressor_for(path: str, extension: Optional[str] = None): return decompressor_for_nix(extension) -def decompressor_for_nix(extension: str) -> Callable[[str], str]: +def decompressor_for_nix(extension: str) -> Callable[[str], Any]: """Returns a function pointer to appropriate decompression algorithm based on extension type and unix specific considerations i.e. a reasonable expectation system utils like gzip, bzip2, and xz are available @@ -291,18 +295,19 @@ def decompressor_for_nix(extension: str) -> Callable[[str], str]: Args: extension: path of the archive file requiring decompression """ - extension_to_decompressor: Dict[str, Callable[[str], str]] = { + extension_to_decompressor: Dict[str, Callable[[str], Any]] = { "zip": _unzip, "gz": _gunzip, "bz2": _bunzip2, "Z": _system_unZ, # no builtin support for .Z files "xz": _lzma_decomp, + "whl": _do_nothing, } return extension_to_decompressor.get(extension, _system_untar) -def _determine_py_decomp_archive_strategy(extension: str) -> Optional[Callable[[str], str]]: +def _determine_py_decomp_archive_strategy(extension: str) -> Optional[Callable[[str], Any]]: """Returns appropriate python based decompression strategy based on extension type""" extension_to_decompressor: Dict[str, Callable[[str], str]] = { @@ -313,7 +318,7 @@ def _determine_py_decomp_archive_strategy(extension: str) -> Optional[Callable[[ return extension_to_decompressor.get(extension, None) -def decompressor_for_win(extension: str) -> Callable[[str], str]: +def decompressor_for_win(extension: str) -> Callable[[str], Any]: """Returns a function pointer to appropriate decompression algorithm based on extension type and Windows specific considerations @@ -323,7 +328,7 @@ def decompressor_for_win(extension: str) -> Callable[[str], str]: and files as Python does not provide support for the UNIX compress algorithm """ extension = llnl.url.expand_contracted_extension(extension) - extension_to_decompressor: Dict[str, Callable[[str], str]] = { + extension_to_decompressor: Dict[str, Callable[[str], Any]] = { # Windows native tar can handle .zip extensions, use standard unzip method "zip": _unzip, # if extension is standard tarball, invoke Windows native tar @@ -333,6 +338,7 @@ def decompressor_for_win(extension: str) -> Callable[[str], str]: # detected "Z": _system_unZ, "xz": _lzma_decomp, + "whl": _do_nothing, } decompressor = extension_to_decompressor.get(extension) diff --git a/lib/spack/spack/util/elf.py b/lib/spack/spack/util/elf.py index 6047c2f4daddc0..f0fda0778718aa 100644 --- a/lib/spack/spack/util/elf.py +++ b/lib/spack/spack/util/elf.py @@ -641,6 +641,30 @@ def substitute_rpath_and_pt_interp_in_place_or_raise( return False +def pt_interp(path: str) -> Optional[str]: + """Retrieve the interpreter of an executable at `path`.""" + try: + with open(path, "rb") as f: + elf = parse_elf(f, interpreter=True) + except (OSError, ElfParsingError): + return None + + if not elf.has_pt_interp: + return None + + return elf.pt_interp_str.decode("utf-8") + + +def get_elf_compat(path): + """Get a triplet (EI_CLASS, EI_DATA, e_machine) from an ELF file, which can be used to see if + two ELF files are compatible.""" + # On ELF platforms supporting, we try to be a bit smarter when it comes to shared + # libraries, by dropping those that are not host compatible. + with open(path, "rb") as f: + elf = parse_elf(f, only_header=True) + return (elf.is_64_bit, elf.is_little_endian, elf.elf_hdr.e_machine) + + class ElfCStringUpdatesFailed(Exception): def __init__( self, rpath: Optional[UpdateCStringAction], pt_interp: Optional[UpdateCStringAction] diff --git a/lib/spack/spack/util/environment.py b/lib/spack/spack/util/environment.py index d2f56dd4a7688d..0c5ac769c03f03 100644 --- a/lib/spack/spack/util/environment.py +++ b/lib/spack/spack/util/environment.py @@ -36,6 +36,8 @@ SYSTEM_DIRS = [os.path.join(p, s) for s in SUFFIXES for p in SYSTEM_PATHS] + SYSTEM_PATHS +#: used in the compiler wrapper's `/usr/lib|/usr/lib64|...)` case entry +SYSTEM_DIR_CASE_ENTRY = "|".join(sorted(f'"{d}{suff}"' for d in SYSTEM_DIRS for suff in ("", "/"))) _SHELL_SET_STRINGS = { "sh": "export {0}={1};\n", @@ -642,8 +644,8 @@ def reversed(self) -> "EnvironmentModifications": elif isinstance(envmod, AppendFlagsEnv): rev.remove_flags(envmod.name, envmod.value) else: - tty.warn( - f"Skipping reversal of unreversable operation {type(envmod)} {envmod.name}" + tty.debug( + f"Skipping reversal of irreversible operation {type(envmod)} {envmod.name}" ) return rev @@ -677,8 +679,8 @@ def shell_modifications( for modifier in actions: modifier.execute(new_env) - if "MANPATH" in new_env and not new_env["MANPATH"].endswith(":"): - new_env["MANPATH"] += ":" + if "MANPATH" in new_env and not new_env["MANPATH"].endswith(os.pathsep): + new_env["MANPATH"] += os.pathsep cmds = "" @@ -716,9 +718,9 @@ def from_sourcing_file( (default: ``&> /dev/null``) concatenate_on_success (str): operator used to execute a command only when the previous command succeeds (default: ``&&``) - exclude ([str or re]): ignore any modifications of these + exclude ([str or re.Pattern[str]]): ignore any modifications of these variables (default: []) - include ([str or re]): always respect modifications of these + include ([str or re.Pattern[str]]): always respect modifications of these variables (default: []). Supersedes any excluded variables. clean (bool): in addition to removing empty entries, also remove duplicate entries (default: False). diff --git a/lib/spack/spack/util/executable.py b/lib/spack/spack/util/executable.py index f160051674609c..b4974fc9b575ae 100644 --- a/lib/spack/spack/util/executable.py +++ b/lib/spack/spack/util/executable.py @@ -31,6 +31,7 @@ def __init__(self, name): self.default_envmod = EnvironmentModifications() self.returncode = None + self.ignore_quotes = False if not self.exe: raise ProcessError("Cannot construct executable for '%s'" % name) @@ -39,6 +40,20 @@ def add_default_arg(self, *args): """Add default argument(s) to the command.""" self.exe.extend(args) + def with_default_args(self, *args): + """Same as add_default_arg, but returns a copy of the executable.""" + new = self.copy() + new.add_default_arg(*args) + return new + + def copy(self): + """Return a copy of this Executable.""" + new = Executable(self.exe[0]) + new.exe[:] = self.exe + new.default_env.update(self.default_env) + new.default_envmod.extend(self.default_envmod) + return new + def add_default_env(self, key, value): """Set an environment variable when the command is run. @@ -174,7 +189,7 @@ def process_cmd_output(out, err): fail_on_error = kwargs.pop("fail_on_error", True) ignore_errors = kwargs.pop("ignore_errors", ()) - ignore_quotes = kwargs.pop("ignore_quotes", False) + ignore_quotes = kwargs.pop("ignore_quotes", self.ignore_quotes) timeout = kwargs.pop("timeout", None) # If they just want to ignore one error code, make it a tuple. diff --git a/lib/spack/spack/util/format.py b/lib/spack/spack/util/format.py index c42597a8c3f161..acbf6f7a2437d0 100644 --- a/lib/spack/spack/util/format.py +++ b/lib/spack/spack/util/format.py @@ -21,16 +21,6 @@ def get_version_lines(version_hashes_dict: dict, url_dict: Optional[dict] = None version_lines = [] for v, h in version_hashes_dict.items(): - expand_arg = "" - - # Extract the url for a version if url_dict is provided. - url = "" - if url_dict is not None and v in url_dict: - url = url_dict[v] - - # Add expand_arg since wheels should not be expanded during stanging - if url.endswith(".whl") or ".whl#" in url: - expand_arg = ", expand=False" - version_lines.append(f' version("{v}", sha256="{h}"{expand_arg})') + version_lines.append(f' version("{v}", sha256="{h}")') return "\n".join(version_lines) diff --git a/lib/spack/spack/util/gpg.py b/lib/spack/spack/util/gpg.py index beae7f707b91c1..7c5218e23622f1 100644 --- a/lib/spack/spack/util/gpg.py +++ b/lib/spack/spack/util/gpg.py @@ -8,6 +8,8 @@ import os import re +import llnl.util.filesystem + import spack.error import spack.paths import spack.util.executable @@ -60,7 +62,7 @@ def init(gnupghome=None, force=False): # Set the executable objects for "gpg" and "gpgconf" with spack.bootstrap.ensure_bootstrap_configuration(): - spack.bootstrap.ensure_core_dependencies() + spack.bootstrap.ensure_gpg_in_path_or_raise() GPG, GPGCONF = _gpg(), _gpgconf() GPG.add_default_env("GNUPGHOME", GNUPGHOME) @@ -385,7 +387,7 @@ def _socket_dir(gpgconf): os.mkdir(var_run_user) os.chmod(var_run_user, 0o777) - user_dir = os.path.join(var_run_user, str(os.getuid())) + user_dir = os.path.join(var_run_user, str(llnl.util.filesystem.getuid())) if not os.path.exists(user_dir): os.mkdir(user_dir) diff --git a/lib/spack/spack/util/libc.py b/lib/spack/spack/util/libc.py new file mode 100644 index 00000000000000..402bf6f2444131 --- /dev/null +++ b/lib/spack/spack/util/libc.py @@ -0,0 +1,176 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os +import os.path +import re +import shlex +import sys +from subprocess import PIPE, run +from typing import Optional + +import spack.spec +import spack.util.elf + + +def _libc_from_ldd(ldd: str) -> Optional["spack.spec.Spec"]: + try: + result = run([ldd, "--version"], stdout=PIPE, stderr=PIPE, check=False) + stdout = result.stdout.decode("utf-8") + except Exception: + return None + + if not re.search(r"\bFree Software Foundation\b", stdout): + return None + + version_str = re.match(r".+\(.+\) (.+)", stdout) + if not version_str: + return None + try: + return spack.spec.Spec(f"glibc@={version_str.group(1)}") + except Exception: + return None + + +def libc_from_dynamic_linker(dynamic_linker: str) -> Optional["spack.spec.Spec"]: + if not os.path.exists(dynamic_linker): + return None + + # The dynamic linker is usually installed in the same /lib(64)?/ld-*.so path across all + # distros. The rest of libc is elsewhere, e.g. /usr. Typically the dynamic linker is then + # a symlink into /usr/lib, which we use to for determining the actual install prefix of + # libc. + realpath = os.path.realpath(dynamic_linker) + + prefix = os.path.dirname(realpath) + # Remove the multiarch suffix if it exists + if os.path.basename(prefix) not in ("lib", "lib64"): + prefix = os.path.dirname(prefix) + + # Non-standard install layout -- just bail. + if os.path.basename(prefix) not in ("lib", "lib64"): + return None + + prefix = os.path.dirname(prefix) + + # Now try to figure out if glibc or musl, which is the only ones we support. + # In recent glibc we can simply execute the dynamic loader. In musl that's always the case. + try: + result = run([dynamic_linker, "--version"], stdout=PIPE, stderr=PIPE, check=False) + stdout = result.stdout.decode("utf-8") + stderr = result.stderr.decode("utf-8") + except Exception: + return None + + # musl prints to stderr + if stderr.startswith("musl libc"): + version_str = re.search(r"^Version (.+)$", stderr, re.MULTILINE) + if not version_str: + return None + try: + spec = spack.spec.Spec(f"musl@={version_str.group(1)}") + spec.external_path = prefix + return spec + except Exception: + return None + elif re.search(r"\bFree Software Foundation\b", stdout): + # output is like "ld.so (...) stable release version 2.33." + match = re.search(r"version (\d+\.\d+(?:\.\d+)?)", stdout) + if not match: + return None + try: + version = match.group(1) + spec = spack.spec.Spec(f"glibc@={version}") + spec.external_path = prefix + return spec + except Exception: + return None + else: + # Could not get the version by running the dynamic linker directly. Instead locate `ldd` + # relative to the dynamic linker. + ldd = os.path.join(prefix, "bin", "ldd") + if not os.path.exists(ldd): + # If `/lib64/ld.so` was not a symlink to `/usr/lib/ld.so` we can try to use /usr as + # prefix. This is the case on ubuntu 18.04 where /lib != /usr/lib. + if prefix != "/": + return None + prefix = "/usr" + ldd = os.path.join(prefix, "bin", "ldd") + if not os.path.exists(ldd): + return None + maybe_spec = _libc_from_ldd(ldd) + if not maybe_spec: + return None + maybe_spec.external_path = prefix + return maybe_spec + + +def libc_from_current_python_process() -> Optional["spack.spec.Spec"]: + if not sys.executable: + return None + + dynamic_linker = spack.util.elf.pt_interp(sys.executable) + + if not dynamic_linker: + return None + + return libc_from_dynamic_linker(dynamic_linker) + + +def startfile_prefix(prefix: str, compatible_with: str = sys.executable) -> Optional[str]: + # Search for crt1.o at max depth 2 compatible with the ELF file provided in compatible_with. + # This is useful for finding external libc startfiles on a multiarch system. + try: + compat = spack.util.elf.get_elf_compat(compatible_with) + accept = lambda path: spack.util.elf.get_elf_compat(path) == compat + except Exception: + accept = lambda path: True + + stack = [(0, prefix)] + while stack: + depth, path = stack.pop() + try: + iterator = os.scandir(path) + except OSError: + continue + with iterator: + for entry in iterator: + try: + if entry.is_dir(follow_symlinks=True): + if depth < 2: + stack.append((depth + 1, entry.path)) + elif entry.name == "crt1.o" and accept(entry.path): + return path + except Exception: + continue + return None + + +def parse_dynamic_linker(output: str): + """Parse -dynamic-linker /path/to/ld.so from compiler output""" + for line in reversed(output.splitlines()): + if "-dynamic-linker" not in line: + continue + args = shlex.split(line) + + for idx in reversed(range(1, len(args))): + arg = args[idx] + if arg == "-dynamic-linker" or args == "--dynamic-linker": + return args[idx + 1] + elif arg.startswith("--dynamic-linker=") or arg.startswith("-dynamic-linker="): + return arg.split("=", 1)[1] + + +def libc_include_dir_from_startfile_prefix( + libc_prefix: str, startfile_prefix: str +) -> Optional[str]: + """Heuristic to determine the glibc include directory from the startfile prefix. Replaces + $libc_prefix/lib*/ with $libc_prefix/include/. This function does not + check if the include directory actually exists or is correct.""" + parts = os.path.relpath(startfile_prefix, libc_prefix).split(os.path.sep) + if parts[0] not in ("lib", "lib64", "libx32", "lib32"): + return None + parts[0] = "include" + return os.path.join(libc_prefix, *parts) diff --git a/lib/spack/spack/util/spack_yaml.py b/lib/spack/spack/util/spack_yaml.py index f4bec63f5cc64b..b3326d29591a8a 100644 --- a/lib/spack/spack/util/spack_yaml.py +++ b/lib/spack/spack/util/spack_yaml.py @@ -20,7 +20,7 @@ import functools import io import re -from typing import IO, List, Optional +from typing import IO, Any, Callable, Dict, List, Optional, Union import ruamel.yaml from ruamel.yaml import comments, constructor, emitter, error, representer @@ -233,8 +233,8 @@ def wrapper(data, stream=None, **kwargs): @return_string_when_no_stream def dump(data, stream=None, default_flow_style=False): handler = ConfigYAML(yaml_type=YAMLType.GENERIC_YAML) - handler.default_flow_style = default_flow_style - handler.width = maxint + handler.yaml.default_flow_style = default_flow_style + handler.yaml.width = maxint return handler.dump(data, stream=stream) @@ -296,8 +296,8 @@ def process_scalar(self): if marked(self.event.value): self.saved = self.event.value - def write_line_break(self): - super().write_line_break() + def write_line_break(self, data=None): + super().write_line_break(data) if self.saved is None: _ANNOTATIONS.append(colorize("@K{---}")) return @@ -493,6 +493,29 @@ def name_mark(name): return error.StringMark(name, None, None, None, None, None) +def anchorify(data: Union[dict, list], identifier: Callable[[Any], str] = repr) -> None: + """Replace identical dict/list branches in tree with references to earlier instances. The YAML + serializer generate anchors for them, resulting in small yaml files.""" + anchors: Dict[str, Union[dict, list]] = {} + stack: List[Union[dict, list]] = [data] + + while stack: + item = stack.pop() + + for key, value in item.items() if isinstance(item, dict) else enumerate(item): + if not isinstance(value, (dict, list)): + continue + + id = identifier(value) + anchor = anchors.get(id) + + if anchor is None: + anchors[id] = value + stack.append(value) + else: + item[key] = anchor # replace with reference + + class SpackYAMLError(spack.error.SpackError): """Raised when there are issues with YAML parsing.""" diff --git a/lib/spack/spack/util/unparse/unparser.py b/lib/spack/spack/util/unparse/unparser.py index 8ca4cd57a3eaa8..13da43aa98f535 100644 --- a/lib/spack/spack/util/unparse/unparser.py +++ b/lib/spack/spack/util/unparse/unparser.py @@ -554,9 +554,7 @@ def visit_FormattedValue(self, node): def _fstring_JoinedStr(self, node, write): for value in node.values: - print(" ", value) meth = getattr(self, "_fstring_" + type(value).__name__) - print(meth) meth(value, write) def _fstring_Str(self, node, write): diff --git a/lib/spack/spack/util/url.py b/lib/spack/spack/util/url.py index db84b03c3fcfc3..64671f1d95dfff 100644 --- a/lib/spack/spack/util/url.py +++ b/lib/spack/spack/util/url.py @@ -10,9 +10,11 @@ import itertools import os import posixpath +import re import sys import urllib.parse import urllib.request +from typing import Optional from llnl.path import convert_to_posix_path @@ -76,14 +78,7 @@ def is_path_instead_of_url(path_or_url): """Historically some config files and spack commands used paths where urls should be used. This utility can be used to validate and promote paths to urls.""" - scheme = urllib.parse.urlparse(path_or_url).scheme - - # On non-Windows, no scheme means it's likely a path - if not sys.platform == "win32": - return not scheme - - # On Windows, we may have drive letters. - return "A" <= scheme <= "Z" + return not validate_scheme(urllib.parse.urlparse(path_or_url).scheme) def format(parsed_url): @@ -261,3 +256,43 @@ def default_download_filename(url: str) -> str: valid_name = "_" + valid_name[1:] return valid_name + + +def parse_link_rel_next(link_value: str) -> Optional[str]: + """Return the next link from a Link header value, if any.""" + + # Relaxed version of RFC5988 + uri = re.compile(r"\s*<([^>]+)>\s*") + param_key = r"[^;=\s]+" + quoted_string = r"\"([^\"]+)\"" + unquoted_param_value = r"([^;,\s]+)" + param = re.compile(rf";\s*({param_key})\s*=\s*(?:{quoted_string}|{unquoted_param_value})\s*") + + data = link_value + + # Parse a list of ; key=value; key=value, ; key=value; key=value, ... links. + while True: + uri_match = re.match(uri, data) + if not uri_match: + break + uri_reference = uri_match.group(1) + data = data[uri_match.end() :] + + # Parse parameter list + while True: + param_match = re.match(param, data) + if not param_match: + break + key, quoted_value, unquoted_value = param_match.groups() + value = quoted_value or unquoted_value + data = data[param_match.end() :] + + if key == "rel" and value == "next": + return uri_reference + + if not data.startswith(","): + break + + data = data[1:] + + return None diff --git a/lib/spack/spack/util/web.py b/lib/spack/spack/util/web.py index d56078a28ed14b..8c843c534617c4 100644 --- a/lib/spack/spack/util/web.py +++ b/lib/spack/spack/util/web.py @@ -12,12 +12,13 @@ import re import shutil import ssl +import stat import sys import traceback import urllib.parse from html.parser import HTMLParser from pathlib import Path, PurePosixPath -from typing import IO, Dict, Iterable, List, Optional, Set, Union +from typing import IO, Dict, Iterable, List, Optional, Set, Tuple, Union from urllib.error import HTTPError, URLError from urllib.request import HTTPSHandler, Request, build_opener @@ -27,9 +28,10 @@ import spack.config import spack.error +import spack.util.path import spack.util.url as url_util -from .executable import CommandNotFoundError, which +from .executable import CommandNotFoundError, Executable, which from .gcs import GCSBlob, GCSBucket, GCSHandler from .s3 import UrllibS3Handler, get_s3_session @@ -59,6 +61,58 @@ def http_error_default(self, req, fp, code, msg, hdrs): raise DetailedHTTPError(req, code, msg, hdrs, fp) +def custom_ssl_certs() -> Optional[Tuple[bool, str]]: + """Returns a tuple (is_file, path) if custom SSL certifates are configured and valid.""" + ssl_certs = spack.config.get("config:ssl_certs") + if not ssl_certs: + return None + path = spack.util.path.substitute_path_variables(ssl_certs) + if not os.path.isabs(path): + tty.debug(f"certs: relative path not allowed: {path}") + return None + try: + st = os.stat(path) + except OSError as e: + tty.debug(f"certs: error checking path {path}: {e}") + return None + + file_type = stat.S_IFMT(st.st_mode) + + if file_type != stat.S_IFREG and file_type != stat.S_IFDIR: + tty.debug(f"certs: not a file or directory: {path}") + return None + + return (file_type == stat.S_IFREG, path) + + +def ssl_create_default_context(): + """Create the default SSL context for urllib with custom certificates if configured.""" + certs = custom_ssl_certs() + if certs is None: + return ssl.create_default_context() + is_file, path = certs + if is_file: + tty.debug(f"urllib: certs: using cafile {path}") + return ssl.create_default_context(cafile=path) + else: + tty.debug(f"urllib: certs: using capath {path}") + return ssl.create_default_context(capath=path) + + +def set_curl_env_for_ssl_certs(curl: Executable) -> None: + """configure curl to use custom certs in a file at runtime. See: + https://curl.se/docs/sslcerts.html item 4""" + certs = custom_ssl_certs() + if certs is None: + return + is_file, path = certs + if not is_file: + tty.debug(f"curl: {path} is not a file: default certs will be used.") + return + tty.debug(f"curl: using CURL_CA_BUNDLE={path}") + curl.add_default_env("CURL_CA_BUNDLE", path) + + def _urlopen(): s3 = UrllibS3Handler() gcs = GCSHandler() @@ -66,7 +120,7 @@ def _urlopen(): # One opener with HTTPS ssl enabled with_ssl = build_opener( - s3, gcs, HTTPSHandler(context=ssl.create_default_context()), error_handler + s3, gcs, HTTPSHandler(context=ssl_create_default_context()), error_handler ) # One opener with HTTPS ssl disabled @@ -206,9 +260,7 @@ def push_to_url(local_file_path, remote_path, keep_original=True, extra_args=Non os.remove(local_file_path) else: - raise NotImplementedError( - "Unrecognized URL scheme: {SCHEME}".format(SCHEME=remote_url.scheme) - ) + raise NotImplementedError(f"Unrecognized URL scheme: {remote_url.scheme}") def base_curl_fetch_args(url, timeout=0): @@ -289,6 +341,7 @@ def _curl(curl=None): except CommandNotFoundError as exc: tty.error(str(exc)) raise spack.error.FetchError("Missing required curl fetch method") + set_curl_env_for_ssl_certs(curl) return curl @@ -535,7 +588,7 @@ def list_url(url, recursive=False): if local_path: if recursive: # convert backslash to forward slash as required for URLs - return [str(PurePosixPath(Path(p))) for p in list(_iter_local_prefix(local_path))] + return [str(PurePosixPath(Path(p))) for p in _iter_local_prefix(local_path)] return [ subpath for subpath in os.listdir(local_path) @@ -647,6 +700,7 @@ def _spider(url: urllib.parse.ParseResult, collect_nested: bool, _visited: Set[s raw_link = metadata_parser.fragments.pop() abs_link = url_util.join(response_url, raw_link.strip(), resolve_href=True) + fragment_response_url = None try: # This seems to be text/html, though text/fragment+html is also used fragment_response_url, _, fragment_response = read_from_url(abs_link, "text/html") diff --git a/lib/spack/spack/variant.py b/lib/spack/spack/variant.py index 7964ca09291a30..2e287f28f23999 100644 --- a/lib/spack/spack/variant.py +++ b/lib/spack/spack/variant.py @@ -638,6 +638,9 @@ def copy(self): return clone def __str__(self): + if not self: + return "" + # print keys in order sorted_keys = sorted(self.keys()) diff --git a/lib/spack/spack/verify.py b/lib/spack/spack/verify.py index 10d6f91da0f3a5..7125481c6d6b8c 100644 --- a/lib/spack/spack/verify.py +++ b/lib/spack/spack/verify.py @@ -9,6 +9,7 @@ from typing import Any, Dict import llnl.util.tty as tty +from llnl.util.symlink import readlink import spack.filesystem_view import spack.store @@ -38,7 +39,7 @@ def create_manifest_entry(path: str) -> Dict[str, Any]: data: Dict[str, Any] = {"mode": s.st_mode, "owner": s.st_uid, "group": s.st_gid} if stat.S_ISLNK(s.st_mode): - data["dest"] = os.readlink(path) + data["dest"] = readlink(path) elif stat.S_ISREG(s.st_mode): data["hash"] = compute_hash(path) @@ -90,7 +91,7 @@ def check_entry(path, data): # instead of `lstat(...).st_mode`. So, ignore mode errors for symlinks. if not stat.S_ISLNK(s.st_mode) and s.st_mode != data["mode"]: res.add_error(path, "mode") - elif stat.S_ISLNK(s.st_mode) and os.readlink(path) != data.get("dest"): + elif stat.S_ISLNK(s.st_mode) and readlink(path) != data.get("dest"): res.add_error(path, "link") elif stat.S_ISREG(s.st_mode): # Check file contents against hash and listed as file diff --git a/lib/spack/spack/version/__init__.py b/lib/spack/spack/version/__init__.py index 30dd71ea622fab..18d739ae0c2f77 100644 --- a/lib/spack/spack/version/__init__.py +++ b/lib/spack/spack/version/__init__.py @@ -30,9 +30,9 @@ Version, VersionList, VersionRange, + _next_version, + _prev_version, from_string, - next_version, - prev_version, ver, ) @@ -46,8 +46,8 @@ "from_string", "is_git_version", "infinity_versions", - "prev_version", - "next_version", + "_prev_version", + "_next_version", "VersionList", "ClosedOpenRange", "StandardVersion", diff --git a/lib/spack/spack/version/common.py b/lib/spack/spack/version/common.py index 3afa218d4dd6ae..89434d393013c9 100644 --- a/lib/spack/spack/version/common.py +++ b/lib/spack/spack/version/common.py @@ -15,6 +15,14 @@ iv_min_len = min(len(s) for s in infinity_versions) +ALPHA = 0 +BETA = 1 +RC = 2 +FINAL = 3 + +PRERELEASE_TO_STRING = ["alpha", "beta", "rc"] +STRING_TO_PRERELEASE = {"alpha": ALPHA, "beta": BETA, "rc": RC, "final": FINAL} + def is_git_version(string: str) -> bool: return ( diff --git a/lib/spack/spack/version/version_types.py b/lib/spack/spack/version/version_types.py index 3e403256ea893a..f35192192d80bd 100644 --- a/lib/spack/spack/version/version_types.py +++ b/lib/spack/spack/version/version_types.py @@ -11,7 +11,11 @@ from spack.util.spack_yaml import syaml_dict from .common import ( + ALPHA, COMMIT_VERSION, + FINAL, + PRERELEASE_TO_STRING, + STRING_TO_PRERELEASE, EmptyRangeError, VersionLookupError, infinity_versions, @@ -88,21 +92,50 @@ def parse_string_components(string: str) -> Tuple[tuple, tuple]: raise ValueError("Bad characters in version string: %s" % string) segments = SEGMENT_REGEX.findall(string) - version = tuple(int(m[0]) if m[0] else VersionStrComponent.from_string(m[1]) for m in segments) separators = tuple(m[2] for m in segments) - return version, separators + prerelease: Tuple[int, ...] + + # (alpha|beta|rc) + if len(segments) >= 3 and segments[-2][1] in STRING_TO_PRERELEASE and segments[-1][0]: + prerelease = (STRING_TO_PRERELEASE[segments[-2][1]], int(segments[-1][0])) + segments = segments[:-2] + + # (alpha|beta|rc) + elif len(segments) >= 2 and segments[-1][1] in STRING_TO_PRERELEASE: + prerelease = (STRING_TO_PRERELEASE[segments[-1][1]],) + segments = segments[:-1] + + # + else: + prerelease = (FINAL,) + + release = tuple(int(m[0]) if m[0] else VersionStrComponent.from_string(m[1]) for m in segments) + + return (release, prerelease), separators class ConcreteVersion: pass +def _stringify_version(versions: Tuple[tuple, tuple], separators: tuple) -> str: + release, prerelease = versions + string = "" + for i in range(len(release)): + string += f"{release[i]}{separators[i]}" + if prerelease[0] != FINAL: + string += f"{PRERELEASE_TO_STRING[prerelease[0]]}{separators[len(release)]}" + if len(prerelease) > 1: + string += str(prerelease[1]) + return string + + class StandardVersion(ConcreteVersion): """Class to represent versions""" __slots__ = ["version", "string", "separators"] - def __init__(self, string: Optional[str], version: tuple, separators: tuple): + def __init__(self, string: Optional[str], version: Tuple[tuple, tuple], separators: tuple): self.string = string self.version = version self.separators = separators @@ -113,11 +146,11 @@ def from_string(string: str): @staticmethod def typemin(): - return StandardVersion("", (), ()) + return _STANDARD_VERSION_TYPEMIN @staticmethod def typemax(): - return StandardVersion("infinity", (VersionStrComponent(len(infinity_versions)),), ()) + return _STANDARD_VERSION_TYPEMAX def __bool__(self): return True @@ -164,21 +197,23 @@ def __gt__(self, other): return NotImplemented def __iter__(self): - return iter(self.version) + return iter(self.version[0]) def __len__(self): - return len(self.version) + return len(self.version[0]) def __getitem__(self, idx): cls = type(self) + release = self.version[0] + if isinstance(idx, numbers.Integral): - return self.version[idx] + return release[idx] elif isinstance(idx, slice): string_arg = [] - pairs = zip(self.version[idx], self.separators[idx]) + pairs = zip(release[idx], self.separators[idx]) for token, sep in pairs: string_arg.append(str(token)) string_arg.append(str(sep)) @@ -193,22 +228,16 @@ def __getitem__(self, idx): message = "{cls.__name__} indices must be integers" raise TypeError(message.format(cls=cls)) - def _stringify(self): - string = "" - for index in range(len(self.version)): - string += str(self.version[index]) - string += str(self.separators[index]) - return string - def __str__(self): - return self.string or self._stringify() + return self.string or _stringify_version(self.version, self.separators) def __repr__(self) -> str: # Print indirect repr through Version(...) return f'Version("{str(self)}")' def __hash__(self): - return hash(self.version) + # If this is a final release, do not hash the prerelease part for backward compat. + return hash(self.version if self.is_prerelease() else self.version[0]) def __contains__(rhs, lhs): # We should probably get rid of `x in y` for versions, since @@ -257,23 +286,22 @@ def intersection(self, other: Union["ClosedOpenRange", "StandardVersion"]): def isdevelop(self): """Triggers on the special case of the `@develop-like` version.""" return any( - isinstance(p, VersionStrComponent) and isinstance(p.data, int) for p in self.version + isinstance(p, VersionStrComponent) and isinstance(p.data, int) for p in self.version[0] ) + def is_prerelease(self) -> bool: + return self.version[1][0] != FINAL + @property - def force_numeric(self): - """Replaces all non-numeric components of the version with 0 + def dotted_numeric_string(self) -> str: + """Replaces all non-numeric components of the version with 0. This can be used to pass Spack versions to libraries that have stricter version schema. """ - numeric = tuple(0 if isinstance(v, VersionStrComponent) else v for v in self.version) - # null separators except the final one have to be converted to avoid concatenating ints - # default to '.' as most common delimiter for versions - separators = tuple( - "." if s == "" and i != len(self.separators) - 1 else s - for i, s in enumerate(self.separators) - ) - return type(self)(None, numeric, separators) + numeric = tuple(0 if isinstance(v, VersionStrComponent) else v for v in self.version[0]) + if self.is_prerelease(): + numeric += (0, *self.version[1][1:]) + return ".".join(str(v) for v in numeric) @property def dotted(self): @@ -360,6 +388,13 @@ def up_to(self, index): return self[:index] +_STANDARD_VERSION_TYPEMIN = StandardVersion("", ((), (ALPHA,)), ("",)) + +_STANDARD_VERSION_TYPEMAX = StandardVersion( + "infinity", ((VersionStrComponent(len(infinity_versions)),), (FINAL,)), ("",) +) + + class GitVersion(ConcreteVersion): """Class to represent versions interpreted from git refs. @@ -591,6 +626,9 @@ def __getitem__(self, idx): def isdevelop(self): return self.ref_version.isdevelop() + def is_prerelease(self) -> bool: + return self.ref_version.is_prerelease() + @property def dotted(self) -> StandardVersion: return self.ref_version.dotted @@ -622,14 +660,14 @@ def __init__(self, lo: StandardVersion, hi: StandardVersion): def from_version_range(cls, lo: StandardVersion, hi: StandardVersion): """Construct ClosedOpenRange from lo:hi range.""" try: - return ClosedOpenRange(lo, next_version(hi)) + return ClosedOpenRange(lo, _next_version(hi)) except EmptyRangeError as e: raise EmptyRangeError(f"{lo}:{hi} is an empty range") from e def __str__(self): # This simplifies 3.1:<3.2 to 3.1:3.1 to 3.1 # 3:3 -> 3 - hi_prev = prev_version(self.hi) + hi_prev = _prev_version(self.hi) if self.lo != StandardVersion.typemin() and self.lo == hi_prev: return str(self.lo) lhs = "" if self.lo == StandardVersion.typemin() else str(self.lo) @@ -641,7 +679,7 @@ def __repr__(self): def __hash__(self): # prev_version for backward compat. - return hash((self.lo, prev_version(self.hi))) + return hash((self.lo, _prev_version(self.hi))) def __eq__(self, other): if isinstance(other, StandardVersion): @@ -823,7 +861,7 @@ def concrete_range_as_version(self) -> Optional[ConcreteVersion]: v = self[0] if isinstance(v, ConcreteVersion): return v - if isinstance(v, ClosedOpenRange) and next_version(v.lo) == v.hi: + if isinstance(v, ClosedOpenRange) and _next_version(v.lo) == v.hi: return v.lo return None @@ -986,6 +1024,9 @@ def __hash__(self): return hash(tuple(self.versions)) def __str__(self): + if not self.versions: + return "" + return ",".join( f"={v}" if isinstance(v, StandardVersion) else str(v) for v in self.versions ) @@ -994,7 +1035,7 @@ def __repr__(self): return str(self.versions) -def next_str(s: str) -> str: +def _next_str(s: str) -> str: """Produce the next string of A-Z and a-z characters""" return ( (s + "A") @@ -1003,7 +1044,7 @@ def next_str(s: str) -> str: ) -def prev_str(s: str) -> str: +def _prev_str(s: str) -> str: """Produce the previous string of A-Z and a-z characters""" return ( s[:-1] @@ -1012,7 +1053,7 @@ def prev_str(s: str) -> str: ) -def next_version_str_component(v: VersionStrComponent) -> VersionStrComponent: +def _next_version_str_component(v: VersionStrComponent) -> VersionStrComponent: """ Produce the next VersionStrComponent, where masteq -> mastes @@ -1025,14 +1066,14 @@ def next_version_str_component(v: VersionStrComponent) -> VersionStrComponent: # Find the next non-infinity string. while True: - data = next_str(data) + data = _next_str(data) if data not in infinity_versions: break return VersionStrComponent(data) -def prev_version_str_component(v: VersionStrComponent) -> VersionStrComponent: +def _prev_version_str_component(v: VersionStrComponent) -> VersionStrComponent: """ Produce the previous VersionStrComponent, where mastes -> masteq @@ -1045,47 +1086,58 @@ def prev_version_str_component(v: VersionStrComponent) -> VersionStrComponent: # Find the next string. while True: - data = prev_str(data) + data = _prev_str(data) if data not in infinity_versions: break return VersionStrComponent(data) -def next_version(v: StandardVersion) -> StandardVersion: - if len(v.version) == 0: - nxt = VersionStrComponent("A") - elif isinstance(v.version[-1], VersionStrComponent): - nxt = next_version_str_component(v.version[-1]) +def _next_version(v: StandardVersion) -> StandardVersion: + release, prerelease = v.version + separators = v.separators + prerelease_type = prerelease[0] + if prerelease_type != FINAL: + prerelease = (prerelease_type, prerelease[1] + 1 if len(prerelease) > 1 else 0) + elif len(release) == 0: + release = (VersionStrComponent("A"),) + separators = ("",) + elif isinstance(release[-1], VersionStrComponent): + release = release[:-1] + (_next_version_str_component(release[-1]),) else: - nxt = v.version[-1] + 1 - - # Construct a string-version for printing - string_components = [] - for part, sep in zip(v.version[:-1], v.separators): - string_components.append(str(part)) - string_components.append(str(sep)) - string_components.append(str(nxt)) - - return StandardVersion("".join(string_components), v.version[:-1] + (nxt,), v.separators) - - -def prev_version(v: StandardVersion) -> StandardVersion: - if len(v.version) == 0: + release = release[:-1] + (release[-1] + 1,) + components = [""] * (2 * len(release)) + components[::2] = release + components[1::2] = separators[: len(release)] + if prerelease_type != FINAL: + components.extend((PRERELEASE_TO_STRING[prerelease_type], prerelease[1])) + return StandardVersion("".join(str(c) for c in components), (release, prerelease), separators) + + +def _prev_version(v: StandardVersion) -> StandardVersion: + # this function does not deal with underflow, because it's always called as + # _prev_version(_next_version(v)). + release, prerelease = v.version + separators = v.separators + prerelease_type = prerelease[0] + if prerelease_type != FINAL: + prerelease = ( + (prerelease_type,) if prerelease[1] == 0 else (prerelease_type, prerelease[1] - 1) + ) + elif len(release) == 0: return v - elif isinstance(v.version[-1], VersionStrComponent): - prev = prev_version_str_component(v.version[-1]) + elif isinstance(release[-1], VersionStrComponent): + release = release[:-1] + (_prev_version_str_component(release[-1]),) else: - prev = v.version[-1] - 1 - - # Construct a string-version for printing - string_components = [] - for part, sep in zip(v.version[:-1], v.separators): - string_components.append(str(part)) - string_components.append(str(sep)) - string_components.append(str(prev)) - - return StandardVersion("".join(string_components), v.version[:-1] + (prev,), v.separators) + release = release[:-1] + (release[-1] - 1,) + components = [""] * (2 * len(release)) + components[::2] = release + components[1::2] = separators[: len(release)] + if prerelease_type != FINAL: + components.extend((PRERELEASE_TO_STRING[prerelease_type], *prerelease[1:])) + + # this is only used for comparison functions, so don't bother making a string + return StandardVersion(None, (release, prerelease), separators) def Version(string: Union[str, int]) -> Union[GitVersion, StandardVersion]: diff --git a/pytest.ini b/pytest.ini index 617881d77b905d..2a3152da3d9ada 100644 --- a/pytest.ini +++ b/pytest.ini @@ -12,7 +12,7 @@ markers = requires_executables: tests that requires certain executables in PATH to run nomockstage: use a stage area specifically created for this test, instead of relying on a common mock stage enable_compiler_verification: enable compiler verification within unit tests - enable_compiler_link_paths: verifies compiler link paths within unit tests + enable_compiler_execution: enable compiler execution to detect link paths and libc disable_clean_stage_check: avoid failing tests if there are leftover files in the stage area only_clingo: mark unit tests that run only with clingo only_original: mark unit tests that are specific to the original concretizer diff --git a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml index d080a73f6f84c1..c9359e188ddc4c 100644 --- a/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml +++ b/share/spack/gitlab/cloud_pipelines/.gitlab-ci.yml @@ -1,4 +1,4 @@ -stages: [ "generate", "build", "publish" ] +stages: [ "generate", "build" ] variables: SPACK_DISABLE_LOCAL_CONFIG: "1" @@ -39,20 +39,10 @@ default: SPACK_TARGET_PLATFORM: "linux" SPACK_TARGET_ARCH: "x86_64_v3" -.linux_skylake: +.linux_x86_64_v4: variables: SPACK_TARGET_PLATFORM: "linux" - SPACK_TARGET_ARCH: "skylake_avx512" - -.linux_icelake: - variables: - SPACK_TARGET_PLATFORM: "linux" - SPACK_TARGET_ARCH: "icelake" - -.linux_neoverse_n1: - variables: - SPACK_TARGET_PLATFORM: "linux" - SPACK_TARGET_ARCH: "neoverse_n1" + SPACK_TARGET_ARCH: "x86_64_v4" .linux_neoverse_v1: variables: @@ -74,6 +64,11 @@ default: SPACK_TARGET_PLATFORM: "linux" SPACK_TARGET_ARCH: "ppc64le" +.win64-msvc2019: + variables: + SPACK_TARGET_PLATFORM: "win64" + SPACK_TARGET_ARCH: "x86_64" + ######################################## # Job templates ######################################## @@ -82,30 +77,22 @@ default: PIPELINE_MIRROR_TEMPLATE: "single-src-protected-mirrors.yaml.in" # TODO: We can remove this when we drop the "deprecated" stack PUSH_BUILDCACHE_DEPRECATED: "${PROTECTED_MIRROR_PUSH_DOMAIN}/${CI_COMMIT_REF_NAME}/${SPACK_CI_STACK_NAME}" + SPACK_CI_CONFIG_ROOT: "${CI_PROJECT_DIR}/share/spack/gitlab/cloud_pipelines/configs" + SPACK_CI_SCRIPTS_ROOT: "${CI_PROJECT_DIR}/share/spack/gitlab/cloud_pipelines/scripts" rules: - if: $SPACK_CI_DISABLE_STACKS =~ /.+/ && $SPACK_CI_STACK_NAME =~ $SPACK_CI_DISABLE_STACKS when: never - if: $SPACK_CI_ENABLE_STACKS =~ /.+/ && $SPACK_CI_STACK_NAME !~ $SPACK_CI_ENABLE_STACKS when: never - - if: $CI_COMMIT_REF_NAME == "develop" - # Pipelines on develop only rebuild what is missing from the mirror + - if: $CI_COMMIT_REF_NAME == "develop" || $CI_COMMIT_REF_NAME =~ /^releases\/v.*/ + # Pipelines on develop/release branches only rebuild what is missing from the mirror when: always variables: SPACK_PIPELINE_TYPE: "spack_protected_branch" SPACK_COPY_BUILDCACHE: "${PROTECTED_MIRROR_PUSH_DOMAIN}/${CI_COMMIT_REF_NAME}" SPACK_REQUIRE_SIGNING: "True" OIDC_TOKEN_AUDIENCE: "protected_binary_mirror" - - if: $CI_COMMIT_REF_NAME =~ /^releases\/v.*/ - # Pipelines on release branches always rebuild everything - when: always - variables: - SPACK_PIPELINE_TYPE: "spack_protected_branch" - SPACK_COPY_BUILDCACHE: "${PROTECTED_MIRROR_PUSH_DOMAIN}/${CI_COMMIT_REF_NAME}" - SPACK_PRUNE_UNTOUCHED: "False" - SPACK_PRUNE_UP_TO_DATE: "False" - SPACK_REQUIRE_SIGNING: "True" - OIDC_TOKEN_AUDIENCE: "protected_binary_mirror" - if: $CI_COMMIT_TAG =~ /^develop-[\d]{4}-[\d]{2}-[\d]{2}$/ || $CI_COMMIT_TAG =~ /^v.*/ # Pipelines on tags (release or dev snapshots) only copy binaries from one mirror to another when: always @@ -134,16 +121,8 @@ default: .generate-common: stage: generate script: - - uname -a || true - - grep -E 'vendor|model name' /proc/cpuinfo 2>/dev/null | sort -u || head -n10 /proc/cpuinfo 2>/dev/null || true - - nproc || true - - cat /proc/loadavg || true - - cat /proc/meminfo | grep 'MemTotal\|MemFree' || true - - . "./share/spack/setup-env.sh" - spack --version - - cd share/spack/gitlab/cloud_pipelines/stacks/${SPACK_CI_STACK_NAME} - - spack env activate --without-view . - - export SPACK_CI_CONFIG_ROOT="${SPACK_ROOT}/share/spack/gitlab/cloud_pipelines/configs" + - spack env activate --without-view share/spack/gitlab/cloud_pipelines/stacks/${SPACK_CI_STACK_NAME} - spack --config-scope "${SPACK_CI_CONFIG_ROOT}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}" @@ -154,41 +133,31 @@ default: --config-scope "${SPACK_CI_CONFIG_ROOT}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}/${SPACK_TARGET_ARCH}" - ${CI_STACK_CONFIG_SCOPES} audit configs - - spack python -c "import os,sys; print(os.path.expandvars(sys.stdin.read()))" - < "${SPACK_CI_CONFIG_ROOT}/${PIPELINE_MIRROR_TEMPLATE}" > "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" - - spack config add -f "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" - - spack -v --color=always - --config-scope "${SPACK_CI_CONFIG_ROOT}" - --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}" - --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}/${SPACK_TARGET_ARCH}" - ${CI_STACK_CONFIG_SCOPES} - compiler find - - spack python -c "import os,sys; print(os.path.expandvars(sys.stdin.read()))" - < "${SPACK_CI_CONFIG_ROOT}/${PIPELINE_MIRROR_TEMPLATE}" > "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" + # Command below needs to be `spack python` due to naming differences accross platforms + - spack python ${SPACK_CI_SCRIPTS_ROOT}/common/expand_vars.py + "${SPACK_CI_CONFIG_ROOT}/${PIPELINE_MIRROR_TEMPLATE}" + "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" - spack config add -f "${SPACK_CI_CONFIG_ROOT}/mirrors.yaml" - mkdir -p "${CI_PROJECT_DIR}/jobs_scratch_dir" - spack --config-scope "${SPACK_CI_CONFIG_ROOT}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}/${SPACK_TARGET_ARCH}" - ${CI_STACK_CONFIG_SCOPES} config blame > "${CI_PROJECT_DIR}/jobs_scratch_dir/spack.yaml.blame" - spack -v --color=always --config-scope "${SPACK_CI_CONFIG_ROOT}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}" --config-scope "${SPACK_CI_CONFIG_ROOT}/${SPACK_TARGET_PLATFORM}/${SPACK_TARGET_ARCH}" - ${CI_STACK_CONFIG_SCOPES} ci generate --check-index-only --artifacts-root "${CI_PROJECT_DIR}/jobs_scratch_dir" --output-file "${CI_PROJECT_DIR}/jobs_scratch_dir/cloud-ci-pipeline.yml" - after_script: - - cat /proc/loadavg || true - - cat /proc/meminfo | grep 'MemTotal\|MemFree' || true artifacts: paths: - "${CI_PROJECT_DIR}/jobs_scratch_dir" + - "${CI_PROJECT_DIR}/tmp/_user_cache/cache/patches" + - "${CI_PROJECT_DIR}/tmp/_user_cache/cache/providers" + - "${CI_PROJECT_DIR}/tmp/_user_cache/cache/tags" variables: KUBERNETES_CPU_REQUEST: 4000m KUBERNETES_MEMORY_REQUEST: 16G @@ -205,10 +174,20 @@ default: # Generate without tags for cases using external runners .generate-base: extends: [ ".base-job", ".generate-common" ] + before_script: + - uname -a || true + - grep -E 'vendor|model name' /proc/cpuinfo 2>/dev/null | sort -u || head -n10 /proc/cpuinfo 2>/dev/null || true + - nproc || true + - cat /proc/loadavg || true + - cat /proc/meminfo | grep 'MemTotal\|MemFree' || true + - . "./share/spack/setup-env.sh" + after_script: + - cat /proc/loadavg || true + - cat /proc/meminfo | grep 'MemTotal\|MemFree' || true .generate-x86_64: extends: [ ".generate-base" ] - tags: ["spack", "public", "medium", "x86_64"] + tags: ["spack", "public", "medium", "x86_64_v3"] .generate-aarch64: extends: [ ".generate-base" ] @@ -222,6 +201,25 @@ default: extends: [ ".generate-base" ] tags: ["spack", "public", "medium", "neoverse_v2"] +.generate-win64: + extends: [ ".base-job", ".generate-common" ] + before_script: + - $ErrorActionOld=$ErrorActionPreference + - $ErrorActionPreference="SilentlyContinue" + - python -c"import psutil;print(psutil.getloadavg())" + - (Get-WmiObject Win32_PhysicalMemory | measure-object Capacity -sum).sum/1kb + - $ErrorActionPreference=$ErrorActionOld + - . .\share\spack\setup-env.ps1 + after_script: + - $ErrorActionOld=$ErrorActionPreference + - $ErrorActionPreference="SilentlyContinue" + - python -c"import psutil;print(psutil.getloadavg())" + - (Get-WmiObject Win32_PhysicalMemory | measure-object Capacity -sum).sum/1kb + - $ErrorActionPreference=$ErrorActionOld + + tags: ["spack", "public", "medium", "x86_64-win"] + image: "ghcr.io/johnwparent/windows-server21h2:sha-c749cf3" + .generate-deprecated: extends: [ ".base-job" ] stage: generate @@ -261,36 +259,6 @@ default: extends: [ ".base-job" ] stage: build -protected-publish: - # Copy binaries from stack-specific mirrors to a root mirror - stage: publish - only: - - /^develop$/ - - /^releases\/v.*/ - - /^v.*/ - - /^develop-[\d]{4}-[\d]{2}-[\d]{2}$/ - image: "ghcr.io/spack/python-aws-bash:0.0.1" - tags: ["spack", "public", "medium", "aws", "x86_64"] - retry: - max: 2 - when: ["runner_system_failure", "stuck_or_timeout_failure"] - variables: - SPACK_COPY_BUILDCACHE: "${PROTECTED_MIRROR_PUSH_DOMAIN}/${CI_COMMIT_REF_NAME}" - SPACK_PIPELINE_TYPE: "spack_protected_branch" - KUBERNETES_CPU_REQUEST: 4000m - KUBERNETES_MEMORY_REQUEST: 16G - script: - - . "./share/spack/setup-env.sh" - - spack --version - - export COPY_SPECS_DIR=${CI_PROJECT_DIR}/jobs_scratch_dir/specs_to_copy - - spack buildcache sync --manifest-glob "${COPY_SPECS_DIR}/*.json" - - curl -fLsS https://spack.github.io/keys/spack-public-binary-key.pub -o /tmp/spack-public-binary-key.pub - - aws s3 cp /tmp/spack-public-binary-key.pub "${SPACK_COPY_BUILDCACHE}/build_cache/_pgp/spack-public-binary-key.pub" - - spack buildcache update-index --keys "${SPACK_COPY_BUILDCACHE}" - id_tokens: - GITLAB_OIDC_TOKEN: - aud: "protected_binary_mirror" - ######################################## # TEMPLATE FOR ADDING ANOTHER PIPELINE ######################################## @@ -408,7 +376,7 @@ e4s-neoverse_v1-build: e4s-rocm-external-generate: extends: [ ".e4s-rocm-external", ".generate-x86_64"] - image: ecpe4s/ubuntu22.04-runner-amd64-gcc-11.4-rocm5.7.1:2024.03.01 + image: ecpe4s/ubuntu22.04-runner-amd64-gcc-11.4-rocm6.1.2:2024.07.22 e4s-rocm-external-build: extends: [ ".e4s-rocm-external", ".build" ] @@ -454,7 +422,7 @@ e4s-rocm-external-build: e4s-oneapi-generate: extends: [ ".e4s-oneapi", ".generate-x86_64"] - image: ghcr.io/spack/ubuntu22.04-runner-amd64-oneapi-2024.0.0:2024.01.16b + image: ecpe4s/ubuntu22.04-runner-amd64-oneapi-2024.2:2024.06.21 e4s-oneapi-build: extends: [ ".e4s-oneapi", ".build" ] @@ -517,25 +485,27 @@ build_systems-build: ########################################### # Build tests for different developer tools +# manylinux2014 ########################################### -.developer-tools: +.developer-tools-manylinux2014: extends: [ ".linux_x86_64_v3" ] variables: - SPACK_CI_STACK_NAME: developer-tools + SPACK_CI_STACK_NAME: developer-tools-manylinux2014 -developer-tools-generate: - extends: [ ".developer-tools", ".generate-x86_64"] +developer-tools-manylinux2014-generate: + extends: [ ".developer-tools-manylinux2014", ".generate-x86_64"] + image: ecpe4s/manylinux2014:2024.03.28 -developer-tools-build: - extends: [ ".developer-tools", ".build" ] +developer-tools-manylinux2014-build: + extends: [ ".developer-tools-manylinux2014", ".build" ] trigger: include: - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml - job: developer-tools-generate + job: developer-tools-manylinux2014-generate strategy: depend needs: - artifacts: True - job: developer-tools-generate + job: developer-tools-manylinux2014-generate ######################################### # RADIUSS @@ -720,7 +690,7 @@ tutorial-build: ml-linux-x86_64-cpu-generate: extends: [ ".generate-x86_64", .ml-linux-x86_64-cpu, ".tags-x86_64_v4" ] - image: ghcr.io/spack/linux-ubuntu22.04-x86_64_v2:v2024-01-29 + image: ghcr.io/spack/ubuntu-22.04:v2024-05-07 ml-linux-x86_64-cpu-build: extends: [ ".build", ".ml-linux-x86_64-cpu" ] @@ -743,7 +713,7 @@ ml-linux-x86_64-cpu-build: ml-linux-x86_64-cuda-generate: extends: [ ".generate-x86_64", .ml-linux-x86_64-cuda, ".tags-x86_64_v4" ] - image: ghcr.io/spack/linux-ubuntu22.04-x86_64_v2:v2024-01-29 + image: ghcr.io/spack/ubuntu-22.04:v2024-05-07 ml-linux-x86_64-cuda-build: extends: [ ".build", ".ml-linux-x86_64-cuda" ] @@ -766,7 +736,7 @@ ml-linux-x86_64-cuda-build: ml-linux-x86_64-rocm-generate: extends: [ ".generate-x86_64", .ml-linux-x86_64-rocm, ".tags-x86_64_v4" ] - image: ghcr.io/spack/linux-ubuntu22.04-x86_64_v2:v2024-01-29 + image: ghcr.io/spack/ubuntu-22.04:v2024-05-07 ml-linux-x86_64-rocm-build: extends: [ ".build", ".ml-linux-x86_64-rocm" ] @@ -779,9 +749,9 @@ ml-linux-x86_64-rocm-build: - artifacts: True job: ml-linux-x86_64-rocm-generate -######################################## +######################################### # Machine Learning - Darwin aarch64 (MPS) -######################################## +######################################### .ml-darwin-aarch64-mps: extends: [".darwin_aarch64"] variables: @@ -824,104 +794,58 @@ deprecated-ci-build: job: deprecated-ci-generate ######################################## -# AWS PCLUSTER +# AWS ParallelCluster ######################################## -.aws-pcluster-generate-image: - image: { "name": "ghcr.io/spack/pcluster-amazonlinux-2:v2023-05-25", "entrypoint": [""] } - .aws-pcluster-generate: + image: { "name": "ghcr.io/spack/pcluster-amazonlinux-2:v2024-01-29", "entrypoint": [""] } before_script: - # Use gcc from local container buildcache + # Use gcc from pre-installed spack store - - . "./share/spack/setup-env.sh" - - . /etc/profile.d/modules.sh - - spack buildcache rebuild-index /bootstrap/local-cache/ - - spack mirror add local-cache /bootstrap/local-cache - - spack gpg trust /bootstrap/public-key - - cd "${CI_PROJECT_DIR}" && curl -sOL https://raw.githubusercontent.com/spack/spack-configs/main/AWS/parallelcluster/postinstall.sh - - sed -i -e "s/spack arch -t/echo ${SPACK_TARGET_ARCH}/g" postinstall.sh - - sed -i.bkp s/"spack install gcc"/"spack install --cache-only --reuse gcc"/ postinstall.sh - - diff postinstall.sh postinstall.sh.bkp || echo Done - - /bin/bash postinstall.sh -fg - - spack config --scope site add "packages:all:target:[${SPACK_TARGET_ARCH}]" - after_script: - - - mv "${CI_PROJECT_DIR}/postinstall.sh" "${CI_PROJECT_DIR}/jobs_scratch_dir/" + - . "/etc/profile.d/modules.sh" + - diff -q "/bootstrap/cloud_pipelines-config.yaml" "share/spack/gitlab/cloud_pipelines/configs/config.yaml" || echo "WARNING Install tree might have changed. You need to rebuild the pcluster-amazonlinux-2 container in spack/gitlab-runners." + - cp "share/spack/gitlab/cloud_pipelines/configs/config.yaml" "etc/spack/" + - /bin/bash "${SPACK_ROOT}/share/spack/gitlab/cloud_pipelines/scripts/pcluster/setup-pcluster.sh" + - rm "etc/spack/config.yaml" -# Icelake (one pipeline per target) -.aws-pcluster-icelake: +# X86_64_V4 (one pipeline per target) +.aws-pcluster-x86_64_v4: variables: - SPACK_CI_STACK_NAME: aws-pcluster-icelake + SPACK_CI_STACK_NAME: aws-pcluster-x86_64_v4 -# aws-pcluster-generate-icelake: -# extends: [ ".linux_icelake", ".aws-pcluster-icelake", ".generate-x86_64", ".tags-x86_64_v4", ".aws-pcluster-generate", ".aws-pcluster-generate-image" ] +aws-pcluster-generate-x86_64_v4: + extends: [ ".linux_x86_64_v4", ".aws-pcluster-x86_64_v4", ".generate-base", ".tags-x86_64_v4", ".aws-pcluster-generate"] -# aws-pcluster-build-icelake: -# extends: [ ".linux_icelake", ".aws-pcluster-icelake", ".build" ] -# trigger: -# include: -# - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml -# job: aws-pcluster-generate-icelake -# strategy: depend -# needs: -# - artifacts: True -# job: aws-pcluster-generate-icelake - -# Skylake_avx512 (one pipeline per target) -.aws-pcluster-skylake: - variables: - SPACK_CI_STACK_NAME: aws-pcluster-skylake - -# aws-pcluster-generate-skylake: -# extends: [ ".linux_skylake", ".aws-pcluster-skylake", ".generate-x86_64", ".tags-x86_64_v4", ".aws-pcluster-generate", ".aws-pcluster-generate-image" ] - -# aws-pcluster-build-skylake: -# extends: [ ".linux_skylake", ".aws-pcluster-skylake", ".build" ] -# trigger: -# include: -# - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml -# job: aws-pcluster-generate-skylake -# strategy: depend -# needs: -# - artifacts: True -# job: aws-pcluster-generate-skylake - -# Neoverse_n1 (one pipeline per target) -.aws-pcluster-neoverse_n1: - variables: - SPACK_CI_STACK_NAME: aws-pcluster-neoverse_n1 - -# aws-pcluster-generate-neoverse_n1: -# extends: [ ".linux_neoverse_n1", ".aws-pcluster-neoverse_n1", ".generate-aarch64", ".aws-pcluster-generate", ".aws-pcluster-generate-image" ] - -# aws-pcluster-build-neoverse_n1: -# extends: [ ".linux_neoverse_n1", ".aws-pcluster-neoverse_n1", ".build" ] -# trigger: -# include: -# - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml -# job: aws-pcluster-generate-neoverse_n1 -# strategy: depend -# needs: -# - artifacts: True -# job: aws-pcluster-generate-neoverse_n1 +aws-pcluster-build-x86_64_v4: + extends: [ ".linux_x86_64_v4", ".aws-pcluster-x86_64_v4", ".build" ] + trigger: + include: + - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml + job: aws-pcluster-generate-x86_64_v4 + strategy: depend + needs: + - artifacts: True + job: aws-pcluster-generate-x86_64_v4 # Neoverse_v1 (one pipeline per target) .aws-pcluster-neoverse_v1: variables: SPACK_CI_STACK_NAME: aws-pcluster-neoverse_v1 -# aws-pcluster-generate-neoverse_v1: -# extends: [ ".linux_neoverse_v1", ".aws-pcluster-neoverse_v1", ".generate-aarch64", ".aws-pcluster-generate", ".aws-pcluster-generate-image" ] +aws-pcluster-generate-neoverse_v1: + # TODO: Use updated runner tags: https://github.com/spack/spack-infrastructure/pull/694/files + extends: [ ".linux_neoverse_v1", ".aws-pcluster-neoverse_v1", ".generate-neoverse_v1", ".aws-pcluster-generate"] -# aws-pcluster-build-neoverse_v1: -# extends: [ ".linux_neoverse_v1", ".aws-pcluster-neoverse_v1", ".build" ] -# trigger: -# include: -# - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml -# job: aws-pcluster-generate-neoverse_v1 -# strategy: depend -# needs: -# - artifacts: True -# job: aws-pcluster-generate-neoverse_v1 +aws-pcluster-build-neoverse_v1: + extends: [ ".linux_neoverse_v1", ".aws-pcluster-neoverse_v1", ".build" ] + trigger: + include: + - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml + job: aws-pcluster-generate-neoverse_v1 + strategy: depend + needs: + - artifacts: True + job: aws-pcluster-generate-neoverse_v1 # Cray definitions .generate-cray: @@ -930,6 +854,15 @@ deprecated-ci-build: - echo $PATH - module avail - module list + - uname -a || true + - grep -E 'vendor|model name' /proc/cpuinfo 2>/dev/null | sort -u || head -n10 /proc/cpuinfo 2>/dev/null || true + - nproc || true + - cat /proc/loadavg || true + - cat /proc/meminfo | grep 'MemTotal\|MemFree' || true + - . "./share/spack/setup-env.sh" + after_script: + - cat /proc/loadavg || true + - cat /proc/meminfo | grep 'MemTotal\|MemFree' || true .generate-cray-rhel: tags: [ "cray-rhel-zen4", "public" ] @@ -983,3 +916,25 @@ e4s-cray-sles-build: needs: - artifacts: True job: e4s-cray-sles-generate + +####################################### +# Windows Visualization Tools +####################################### +.windows-vis: + extends: [".win64-msvc2019"] + variables: + SPACK_CI_STACK_NAME: windows-vis + +windows-vis-generate: + extends: [ ".generate-win64", ".windows-vis" ] + +windows-vis-build: + extends: [ ".build", ".windows-vis"] + trigger: + include: + - artifact: jobs_scratch_dir/cloud-ci-pipeline.yml + job: windows-vis-generate + strategy: depend + needs: + - artifacts: True + job: windows-vis-generate diff --git a/share/spack/gitlab/cloud_pipelines/configs/ci.yaml b/share/spack/gitlab/cloud_pipelines/configs/ci.yaml index 2d1e18836d77c1..5f34beb2c58fee 100644 --- a/share/spack/gitlab/cloud_pipelines/configs/ci.yaml +++ b/share/spack/gitlab/cloud_pipelines/configs/ci.yaml @@ -13,7 +13,7 @@ ci: before_script-: - - cat /proc/loadavg || true - cat /proc/meminfo | grep 'MemTotal\|MemFree' || true - - - spack list --count # ensure that spack's cache is populated + - - touch ${SPACK_USER_CACHE_PATH}/cache/*/* # bump mtime of cache so it is not invalidated - - spack env activate --without-view ${SPACK_CONCRETE_ENV_DIR} - spack compiler list - if [ -n "$SPACK_BUILD_JOBS" ]; then spack config add "config:build_jobs:$SPACK_BUILD_JOBS"; fi @@ -27,12 +27,12 @@ ci: - - spack config blame mirrors - spack --color=always --backtrace ci rebuild --tests > >(tee ${SPACK_ARTIFACTS_ROOT}/user_data/pipeline_out.txt) 2> >(tee ${SPACK_ARTIFACTS_ROOT}/user_data/pipeline_err.txt >&2) after_script: - - - ./bin/spack python ${CI_PROJECT_DIR}/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py - --prefix /home/software/spack:${CI_PROJECT_DIR}/opt/spack - --log install_times.json - ${SPACK_ARTIFACTS_ROOT}/user_data/install_times.json - - cat /proc/loadavg || true - cat /proc/meminfo | grep 'MemTotal\|MemFree' || true + - - time ./bin/spack python ${CI_PROJECT_DIR}/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py + --prefix /home/software/spack:${CI_PROJECT_DIR}/opt/spack + --log install_times.json + ${SPACK_ARTIFACTS_ROOT}/user_data/install_times.json || true variables: CI_JOB_SIZE: "default" CI_GPG_KEY_ROOT: /mnt/key @@ -119,7 +119,7 @@ ci: # Disable local configs to avoid issues on shell runners SPACK_DISABLE_LOCAL_CONFIG: "1" before_script: - - - export SPACK_USER_CACHE_PATH="${CI_PROJECT_DIR}/_user_cache/" + - - export SPACK_USER_CACHE_PATH="${CI_PROJECT_DIR}/tmp/_user_cache/" - - uname -a || true - grep -E "vendor|model name" /proc/cpuinfo 2>/dev/null | sort -u || head -n10 /proc/cpuinfo 2>/dev/null || true - nproc || true diff --git a/share/spack/gitlab/cloud_pipelines/configs/darwin/ci.yaml b/share/spack/gitlab/cloud_pipelines/configs/darwin/ci.yaml index 8dfb169a3e83ea..c826c0ea3dbd3c 100644 --- a/share/spack/gitlab/cloud_pipelines/configs/darwin/ci.yaml +++ b/share/spack/gitlab/cloud_pipelines/configs/darwin/ci.yaml @@ -1,4 +1,4 @@ ci: pipeline-gen: - build-job-remove: - image: macos-run-on-metal + image:: macos-run-on-metal diff --git a/share/spack/gitlab/cloud_pipelines/configs/linux/ci.yaml b/share/spack/gitlab/cloud_pipelines/configs/linux/ci.yaml index 5e57687d2a9da4..923e9a400da323 100644 --- a/share/spack/gitlab/cloud_pipelines/configs/linux/ci.yaml +++ b/share/spack/gitlab/cloud_pipelines/configs/linux/ci.yaml @@ -71,7 +71,6 @@ ci: - match: - dealii - - mxnet - rocblas build-job: tags: [ "spack", "huge" ] @@ -242,7 +241,6 @@ ci: - mvapich2 - netlib-scalapack - omega-h - - openblas - openjpeg - openmpi - openpmd-api @@ -395,7 +393,6 @@ ci: - ncurses - ninja - numactl - - openblas - openjdk - openssh - openssl diff --git a/share/spack/gitlab/cloud_pipelines/configs/linux/neoverse_n1/ci.yaml b/share/spack/gitlab/cloud_pipelines/configs/linux/neoverse_n1/ci.yaml deleted file mode 100644 index 9ba2680702bc07..00000000000000 --- a/share/spack/gitlab/cloud_pipelines/configs/linux/neoverse_n1/ci.yaml +++ /dev/null @@ -1,7 +0,0 @@ -ci: - pipeline-gen: - - any-job: - variables: - SPACK_TARGET_ARCH: neoverse_n1 - - build-job: - tags: ["aarch64", "graviton2"] diff --git a/share/spack/gitlab/cloud_pipelines/configs/linux/neoverse_v1/ci.yaml b/share/spack/gitlab/cloud_pipelines/configs/linux/neoverse_v1/ci.yaml index e874fc6522fb27..82aa1eae7bfc0d 100644 --- a/share/spack/gitlab/cloud_pipelines/configs/linux/neoverse_v1/ci.yaml +++ b/share/spack/gitlab/cloud_pipelines/configs/linux/neoverse_v1/ci.yaml @@ -1,7 +1,4 @@ ci: pipeline-gen: - - any-job: - variables: - SPACK_TARGET_ARCH: neoverse_v1 - build-job: tags: ["aarch64", "graviton3"] diff --git a/share/spack/gitlab/cloud_pipelines/configs/linux/skylake_avx512/ci.yaml b/share/spack/gitlab/cloud_pipelines/configs/linux/skylake_avx512/ci.yaml deleted file mode 100644 index 0a7bbb6f19d186..00000000000000 --- a/share/spack/gitlab/cloud_pipelines/configs/linux/skylake_avx512/ci.yaml +++ /dev/null @@ -1,11 +0,0 @@ -ci: - pipeline-gen: - - any-job: - variables: - SPACK_TARGET_ARCH: skylake_avx512 - - build-job: - before_script: - - - curl -LfsS "https://github.com/JuliaBinaryWrappers/GNUMake_jll.jl/releases/download/GNUMake-v4.3.0+1/GNUMake.v4.3.0.x86_64-linux-gnu.tar.gz" -o gmake.tar.gz - - printf "fef1f59e56d2d11e6d700ba22d3444b6e583c663d6883fd0a4f63ab8bd280f0f gmake.tar.gz" | sha256sum --check --strict --quiet - - tar -xzf gmake.tar.gz -C /usr bin/make 2> /dev/null - tags: ["x86_64_v4"] diff --git a/share/spack/gitlab/cloud_pipelines/configs/linux/icelake/ci.yaml b/share/spack/gitlab/cloud_pipelines/configs/linux/x86_64_v4/ci.yaml similarity index 87% rename from share/spack/gitlab/cloud_pipelines/configs/linux/icelake/ci.yaml rename to share/spack/gitlab/cloud_pipelines/configs/linux/x86_64_v4/ci.yaml index 036a4419464304..ae14967dd5a04c 100644 --- a/share/spack/gitlab/cloud_pipelines/configs/linux/icelake/ci.yaml +++ b/share/spack/gitlab/cloud_pipelines/configs/linux/x86_64_v4/ci.yaml @@ -1,8 +1,5 @@ ci: pipeline-gen: - - any-job: - variables: - SPACK_TARGET_ARCH: icelake - build-job: before_script: - - curl -LfsS "https://github.com/JuliaBinaryWrappers/GNUMake_jll.jl/releases/download/GNUMake-v4.3.0+1/GNUMake.v4.3.0.x86_64-linux-gnu.tar.gz" -o gmake.tar.gz diff --git a/share/spack/gitlab/cloud_pipelines/configs/win64/ci.yaml b/share/spack/gitlab/cloud_pipelines/configs/win64/ci.yaml new file mode 100644 index 00000000000000..834c640fc36218 --- /dev/null +++ b/share/spack/gitlab/cloud_pipelines/configs/win64/ci.yaml @@ -0,0 +1,18 @@ +ci: + pipeline-gen: + - build-job: + after_script:: + - Write-Output "Done" + + before_script:: + - fsutil 8dot3name set C:\ 0 + - . .\share\spack\setup-env.ps1 + - If (Test-Path -path C:\\key\intermediate_ci_signing_key.gpg) { spack.ps1 gpg trust C:\\key\intermediate_ci_signing_key.gpg } + - If (Test-Path -path C:\\key\spack_public_key.gpg) { spack.ps1 gpg trust C:\\key\spack_public_key.gpg } + + script:: + - spack.ps1 env activate --without-view ${SPACK_CONCRETE_ENV_DIR} + - spack.ps1 config add "config:install_tree:projections:${SPACK_JOB_SPEC_PKG_NAME}:'morepadding/{hash}'" + - mkdir ${SPACK_ARTIFACTS_ROOT}/user_data + - spack.ps1 --backtrace ci rebuild | Tee-Object -FilePath "${env:SPACK_ARTIFACTS_ROOT}/user_data/pipeline_out.txt" 2>&1 | Tee-Object -FilePath "${env:SPACK_ARTIFACTS_ROOT}/user_data/pipeline_err.txt" + image: "ghcr.io/johnwparent/windows-server21h2:sha-c749cf3" diff --git a/share/spack/gitlab/cloud_pipelines/configs/win64/config.yaml b/share/spack/gitlab/cloud_pipelines/configs/win64/config.yaml new file mode 100644 index 00000000000000..dcabcb2c8ae75e --- /dev/null +++ b/share/spack/gitlab/cloud_pipelines/configs/win64/config.yaml @@ -0,0 +1,10 @@ +config: + build_stage:: + - 'C:/spack stage' + install_tree: + root: "C:/spack install" + # Path lengths on windows doesn't support much padding + padded_length: 0 + # Reduce the projections to only including the hash to avoid path length issues + projections: + all: '{hash}' diff --git a/share/spack/gitlab/cloud_pipelines/configs/win64/packages.yaml b/share/spack/gitlab/cloud_pipelines/configs/win64/packages.yaml new file mode 100644 index 00000000000000..b6d0089c5ac2a0 --- /dev/null +++ b/share/spack/gitlab/cloud_pipelines/configs/win64/packages.yaml @@ -0,0 +1,25 @@ +packages: + all: + target: [x86_64] + tbb: + require: "intel-tbb" + cmake: + externals: + - spec: cmake@3.28.0-msvc1 + prefix: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\Common7\\IDE\\CommonExtensions\\Microsoft\\CMake\\CMake" + buildable: False + ninja: + externals: + - spec: ninja@1.11.0 + prefix: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\Common7\\IDE\\CommonExtensions\\Microsoft\\CMake\\Ninja" + buildable: False + wgl: + externals: + - spec: wgl@10.0.22621 plat=x64 + prefix: "C:\\Program Files (x86)\\Windows Kits\\10" + buildable: False + win-sdk: + externals: + - spec: win-sdk@10.0.22621 plat=x64 + prefix: "C:\\Program Files (x86)\\Windows Kits\\10" + buildable: False diff --git a/share/spack/gitlab/cloud_pipelines/configs/win64/x86_64/ci.yaml b/share/spack/gitlab/cloud_pipelines/configs/win64/x86_64/ci.yaml new file mode 100644 index 00000000000000..8e3b45c336a2f2 --- /dev/null +++ b/share/spack/gitlab/cloud_pipelines/configs/win64/x86_64/ci.yaml @@ -0,0 +1,4 @@ +ci: + pipeline-gen: + - build-job: + tags: [x86_64-win] diff --git a/share/spack/gitlab/cloud_pipelines/configs/win64/x86_64/packages.yaml b/share/spack/gitlab/cloud_pipelines/configs/win64/x86_64/packages.yaml new file mode 100644 index 00000000000000..a08b7cdcfb7181 --- /dev/null +++ b/share/spack/gitlab/cloud_pipelines/configs/win64/x86_64/packages.yaml @@ -0,0 +1,3 @@ +packages: + all: + target: [x86_64] diff --git a/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py b/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py index ec40c4c230ce3f..d27d1656ba20f7 100644 --- a/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py +++ b/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py @@ -37,10 +37,14 @@ def find_logs(prefix, filename): # Look in the list of prefixes for logs for prefix in prefixes: - logs = find_logs(prefix, args.log) + print(f"Walking {prefix}") + logs = [log for log in find_logs(prefix, args.log)] + print(f" * found {len(logs)} logs") for log in logs: + print(f" * appending data for {log}") with open(log) as fd: data.append(json.load(fd)) + print(f"Writing {args.output_file}") with open(args.output_file, "w") as fd: json.dump(data, fd) diff --git a/share/spack/gitlab/cloud_pipelines/scripts/common/expand_vars.py b/share/spack/gitlab/cloud_pipelines/scripts/common/expand_vars.py new file mode 100644 index 00000000000000..7806e10201095e --- /dev/null +++ b/share/spack/gitlab/cloud_pipelines/scripts/common/expand_vars.py @@ -0,0 +1,10 @@ +import argparse +import os + +parser = argparse.ArgumentParser() +parser.add_argument("input", type=argparse.FileType("r")) +parser.add_argument("out", type=argparse.FileType("w")) + +args = parser.parse_args() + +args.out.write(os.path.expandvars(args.input.read())) diff --git a/share/spack/gitlab/cloud_pipelines/scripts/pcluster/setup-pcluster.sh b/share/spack/gitlab/cloud_pipelines/scripts/pcluster/setup-pcluster.sh new file mode 100755 index 00000000000000..484be10f06137a --- /dev/null +++ b/share/spack/gitlab/cloud_pipelines/scripts/pcluster/setup-pcluster.sh @@ -0,0 +1,130 @@ +#!/usr/bin/env bash +# +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +set -e + +# Intel compiler needs to be installed from a specific spack git commit. +# The best solution would be to have the compilers hash (or packages contents) be part of the +# individual packages hashes. I don't see this at the moment. +# Set to the latest tag including a recent oneapi compiler. +# NOTE: If we update this spack version in the future make sure the compiler version also updates. +spack_intel_compiler_commit="develop-2023-08-06" + +set_pcluster_defaults() { + # Set versions of pre-installed software in packages.yaml + [ -z "${SLURM_VERSION}" ] && SLURM_VERSION=$(strings /opt/slurm/lib/libslurm.so | grep -e '^VERSION' | awk '{print $2}' | sed -e 's?"??g') + [ -z "${LIBFABRIC_VERSION}" ] && LIBFABRIC_VERSION=$(awk '/Version:/{print $2}' "$(find /opt/amazon/efa/ -name libfabric.pc | head -n1)" | sed -e 's?~??g' -e 's?amzn.*??g') + export SLURM_VERSION LIBFABRIC_VERSION + + envsubst < "${SPACK_ROOT}/share/spack/gitlab/cloud_pipelines/stacks/${SPACK_CI_STACK_NAME}/packages.yaml" > "${SPACK_ROOT}"/etc/spack/packages.yaml +} + +setup_spack() { + spack compiler add --scope site + # Do not add autotools/buildtools packages. These versions need to be managed by spack or it will + # eventually end up in a version mismatch (e.g. when compiling gmp). + spack external find --scope site --tag core-packages +} + +patch_compilers_yaml() { + # Graceful exit if package not found by spack + set -o pipefail + compilers_yaml="${SPACK_ROOT}/etc/spack/compilers.yaml" + [ -f "${compilers_yaml}" ] || { + echo "Cannot find ${compilers_yaml}, compiler setup might now be optimal." + return + } + + # System ld is too old for amzn linux2 + spack_gcc_version=$(spack find --format '{version}' gcc) + binutils_path=$(spack find -p binutils | awk '/binutils/ {print $2}' | head -n1) + if [ -d "${binutils_path}" ] && [ -n "${spack_gcc_version}" ]; then python3 <:0:0: loop not unroll-and-jammed: the optimizer was unable to perform the requested transformation; the transformation might be disabled or specified as part of an unsupported transformation ordering + # - swig@4.0.2-fortran # ? # - tau +mpi +python +syscall # pdt: pdbType.cc:193:21: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] + # - upcxx # upcxx: /opt/intel/oneapi/mpi/2021.10.0//libfabric/bin/fi_info: error while loading shared libraries: libfabric.so.1: cannot open shared object file: No such file or directory # PYTHON PACKAGES - opencv +python3 - py-jupyterlab + - py-mpi4py - py-notebook + - py-numba - py-numpy - py-openai - py-pandas @@ -208,8 +211,6 @@ spack: - py-scikit-learn - py-scipy - py-seaborn - - py-mpi4py - - py-numba # - py-horovod # error # - py-jax # error # - py-matplotlib # error @@ -217,31 +218,28 @@ spack: # - py-torch # error # GPU + - aml +ze - amrex +sycl + - arborx +sycl ^kokkos +sycl +openmp cxxstd=17 +examples + - cabana +sycl ^kokkos +sycl +openmp cxxstd=17 +examples + - ginkgo +sycl + - heffte +sycl + - kokkos +sycl +openmp cxxstd=17 +examples + - kokkos-kernels build_type=Release %oneapi ^kokkos +sycl +openmp cxxstd=17 +examples + - petsc +sycl + - sundials +sycl cxxstd=17 +examples-install - tau +mpi +opencl +level_zero ~pdt +syscall # requires libdrm.so to be installed - upcxx +level_zero # -- - # - hpctoolkit +level_zero # dyninst@12.3.0%gcc: /usr/bin/ld: libiberty/./d-demangle.c:142: undefined reference to `_intel_fast_memcpy'; can't mix intel-tbb@%oneapi with dyninst%gcc - # - warpx compute=sycl # warpx: spack-build-wzp6vvo/_deps/fetchedamrex-src/Src/Base/AMReX_RandomEngine.H:18:10: fatal error: 'oneapi/mkl/rng/device.hpp' file not found - # -- - - aml # aml: /opt/intel/oneapi/compiler/2024.0/bin/sycl-post-link: error while loading shared libraries: libonnxruntime.1.12.22.721.so: cannot open shared object file: No such file or directory - - aml +ze # aml: /opt/intel/oneapi/compiler/2024.0/bin/sycl-post-link: error while loading shared libraries: libonnxruntime.1.12.22.721.so: cannot open shared object file: No such file or directory - - arborx +sycl ^kokkos +sycl +openmp cxxstd=17 +examples # kokkos@4.2.00: CMake Error at cmake/Modules/FindTPLONEDPL.cmake:31 (FIND_PACKAGE): - - cabana +sycl ^kokkos +sycl +openmp cxxstd=17 +examples # kokkos@4.2.00: CMake Error at cmake/Modules/FindTPLONEDPL.cmake:31 (FIND_PACKAGE): - - ginkgo +sycl # ginkgo: Could NOT find PAPI (missing: PAPI_LIBRARY PAPI_INCLUDE_DIR sde) (Required is at least version "7.0.1.0") SYCL feature test compile failed! compile output is: CMake Error at /opt/intel/oneapi/compiler/2024.0/lib/cmake/IntelSYCL/IntelSYCLConfig.cmake:282 (SYCL_FEATURE_TEST_EXTRACT): SYCL_FEATURE_TEST_EXTRACT Function invoked with incorrect arguments for - - heffte +sycl # heffte: /opt/intel/oneapi/compiler/2024.0/bin/sycl-post-link: error while loading shared libraries: libonnxruntime.1.12.22.721.so: cannot open shared object file: No such file or directory - - kokkos +sycl +openmp cxxstd=17 +examples # kokkos@4.2.00: CMake Error at cmake/Modules/FindTPLONEDPL.cmake:31 (FIND_PACKAGE): - - kokkos-kernels build_type=Release %oneapi ^kokkos +sycl +openmp cxxstd=17 +examples # kokkos@4.0.00: tpls/desul/include/desul/atomics/Adapt_SYCL.hpp:83:7: error: no template named 'sycl_memory_scope' - - petsc +sycl # kokkos@4.0.00: tpls/desul/include/desul/atomics/Adapt_SYCL.hpp:83:7: error: no template named 'sycl_memory_scope' + # - hpctoolkit +level_zero # dyninst@12.3.0%gcc: /usr/bin/ld: libiberty/./d-demangle.c:142: undefined reference to `_intel_fast_memcpy'; can't mix intel-tbb@%oneapi with dyninst%gcc # - slate +sycl # blaspp: CMake Error at CMakeLists.txt:313 (find_package): ... set MKL_FOUND to FALSE so package "MKL" is considered to be NOT FOUND. - - sundials +sycl cxxstd=17 +examples-install # sundials@6.6.2 /cakfnxs: CMake: could NOT find MPI_CXX (missing: MPI_CXX_WORKS) (Required is at least version "2.0.0") + # - warpx compute=sycl # warpx: spack-build-wzp6vvo/_deps/fetchedamrex-src/Src/Base/AMReX_RandomEngine.H:18:10: fatal error: 'oneapi/mkl/rng/device.hpp' file not found - - py-scipy ci: pipeline-gen: - build-job: - image: ghcr.io/spack/ubuntu22.04-runner-amd64-oneapi-2024.0.0:2024.01.16b + image: ecpe4s/ubuntu22.04-runner-amd64-oneapi-2024.2:2024.06.21 cdash: build-group: E4S OneAPI diff --git a/share/spack/gitlab/cloud_pipelines/stacks/e4s-power/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/e4s-power/spack.yaml index bc08f000212ab2..8bd991cbbb6eac 100644 --- a/share/spack/gitlab/cloud_pipelines/stacks/e4s-power/spack.yaml +++ b/share/spack/gitlab/cloud_pipelines/stacks/e4s-power/spack.yaml @@ -35,19 +35,21 @@ spack: mpi: require: mpich mpich: - require: '~wrapperrpath ~hwloc' + require: '~wrapperrpath ~hwloc %gcc@9.4.0 target=ppc64le' ncurses: - require: '@6.3 +termlib' + require: '@6.3 +termlib %gcc@9.4.0 target=ppc64le' faodel: - require: "~tcmalloc" + require: "~tcmalloc %gcc@9.4.0 target=ppc64le" tbb: require: intel-tbb libffi: - require: "@3.4.4" + require: "@3.4.4 %gcc@9.4.0 target=ppc64le" vtk-m: - require: "+examples" + require: "+examples %gcc@9.4.0 target=ppc64le" cuda: - require: "@11.4.4" + require: "@11.4.4 %gcc@9.4.0 target=ppc64le" + paraview: + require: "+examples %gcc@9.4.0 target=ppc64le" specs: @@ -65,7 +67,7 @@ spack: - butterflypack - cabana - caliper - - chai ~benchmarks ~tests + - chai - charliecloud - conduit - cp2k +mpi @@ -129,6 +131,7 @@ spack: - precice - pruners-ninja - pumi + - py-amrex - py-h5py - py-jupyterhub - py-libensemble @@ -157,7 +160,6 @@ spack: - upcxx - wannier90 - xyce +mpi +shared +pymi +pymi_static_tpls - # - ecp-data-vis-sdk ~cuda ~rocm +adios2 +ascent +cinema +darshan +faodel +hdf5 ~paraview +pnetcdf +sz +unifyfs +veloc ~visit +vtkm +zfp # +visit: libext, libxkbfile, libxrender, libxt, silo (https://github.com/spack/spack/issues/39538), cairo # INCLUDED IN ECP DAV CPU - adios2 - ascent @@ -167,7 +169,6 @@ spack: - hdf5 - libcatalyst - parallel-netcdf - - paraview - py-cinemasci - sz - unifyfs @@ -175,6 +176,7 @@ spack: # - visit # libext, libxkbfile, libxrender, libxt, silo (https://github.com/spack/spack/issues/39538), cairo - vtk-m - zfp + # - ecp-data-vis-sdk ~cuda ~rocm +adios2 +ascent +cinema +darshan +faodel +hdf5 ~paraview +pnetcdf +sz +unifyfs +veloc ~visit +vtkm +zfp # +visit: libext, libxkbfile, libxrender, libxt, silo (https://github.com/spack/spack/issues/39538), cairo # -- # - dealii # fltk: https://github.com/spack/spack/issues/38791 # - geopm # geopm: https://github.com/spack/spack/issues/38798 @@ -210,7 +212,7 @@ spack: - flux-core +cuda - hpctoolkit +cuda - papi +cuda - - tau +mpi +cuda # tau: has issue with `spack env depfile` build + - tau +mpi +cuda # -- # - legion +cuda # legion: needs NVIDIA driver @@ -218,8 +220,7 @@ spack: - amrex +cuda cuda_arch=70 - arborx +cuda cuda_arch=70 ^kokkos +wrapper - caliper +cuda cuda_arch=70 - - chai ~benchmarks ~tests +cuda cuda_arch=70 ^umpire ~shared - # - cp2k +mpi +cuda cuda_arch=70 # dbcsr + - chai +cuda cuda_arch=70 ^umpire ~shared - ecp-data-vis-sdk ~rocm +adios2 ~ascent +hdf5 +vtkm +zfp ~paraview +cuda cuda_arch=70 - exago +mpi +python +raja +hiop ~rocm +cuda cuda_arch=70 ~ipopt ^hiop@1.0.0 ~sparse +mpi +raja ~rocm +cuda cuda_arch=70 #^raja@0.14.0 - flecsi +cuda cuda_arch=70 @@ -252,6 +253,7 @@ spack: - zfp +cuda cuda_arch=70 # -- # - axom +cuda cuda_arch=70 # axom: https://github.com/spack/spack/issues/29520 + # - cp2k +mpi +cuda cuda_arch=70 # dbcsr # - cusz +cuda cuda_arch=70 # cusz: https://github.com/spack/spack/issues/38787 # - dealii +cuda cuda_arch=70 # fltk: https://github.com/spack/spack/issues/38791 # - lammps +cuda cuda_arch=70 # lammps: needs NVIDIA driver diff --git a/share/spack/gitlab/cloud_pipelines/stacks/e4s-rocm-external/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/e4s-rocm-external/spack.yaml index e0e20b0afdffdc..4ed973ac03e3d9 100644 --- a/share/spack/gitlab/cloud_pipelines/stacks/e4s-rocm-external/spack.yaml +++ b/share/spack/gitlab/cloud_pipelines/stacks/e4s-rocm-external/spack.yaml @@ -16,208 +16,210 @@ spack: mpi: require: mpich mpich: - require: '~wrapperrpath ~hwloc' + require: '~wrapperrpath ~hwloc %gcc target=x86_64_v3' openblas: variants: threads=openmp paraview: # Don't build GUI support or GLX rendering for HPC/container deployments - require: "@5.11 ~qt+osmesa" + require: "@5.11 +examples ~qt ^[virtuals=gl] osmesa %gcc target=x86_64_v3" - # ROCm 5.4.3 + # ROCm comgr: buildable: false externals: - - spec: comgr@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: comgr@6.1.2 + prefix: /opt/rocm-6.1.2/ hip-rocclr: buildable: false externals: - - spec: hip-rocclr@5.7.1 - prefix: /opt/rocm-5.7.1/hip + - spec: hip-rocclr@6.1.2 + prefix: /opt/rocm-6.1.2/hip hipblas: buildable: false externals: - - spec: hipblas@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: hipblas@6.1.2 + prefix: /opt/rocm-6.1.2/ hipcub: buildable: false externals: - - spec: hipcub@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: hipcub@6.1.2 + prefix: /opt/rocm-6.1.2/ hipfft: buildable: false externals: - - spec: hipfft@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: hipfft@6.1.2 + prefix: /opt/rocm-6.1.2/ hipsparse: buildable: false externals: - - spec: hipsparse@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: hipsparse@6.1.2 + prefix: /opt/rocm-6.1.2/ miopen-hip: buildable: false externals: - - spec: miopen-hip@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: miopen-hip@6.1.2 + prefix: /opt/rocm-6.1.2/ miopengemm: buildable: false externals: - - spec: miopengemm@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: miopengemm@6.1.2 + prefix: /opt/rocm-6.1.2/ rccl: buildable: false externals: - - spec: rccl@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: rccl@6.1.2 + prefix: /opt/rocm-6.1.2/ rocblas: buildable: false externals: - - spec: rocblas@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: rocblas@6.1.2 + prefix: /opt/rocm-6.1.2/ rocfft: buildable: false externals: - - spec: rocfft@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: rocfft@6.1.2 + prefix: /opt/rocm-6.1.2/ rocm-clang-ocl: buildable: false externals: - - spec: rocm-clang-ocl@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: rocm-clang-ocl@6.1.2 + prefix: /opt/rocm-6.1.2/ rocm-cmake: buildable: false externals: - - spec: rocm-cmake@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: rocm-cmake@6.1.2 + prefix: /opt/rocm-6.1.2/ rocm-dbgapi: buildable: false externals: - - spec: rocm-dbgapi@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: rocm-dbgapi@6.1.2 + prefix: /opt/rocm-6.1.2/ rocm-debug-agent: buildable: false externals: - - spec: rocm-debug-agent@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: rocm-debug-agent@6.1.2 + prefix: /opt/rocm-6.1.2/ rocm-device-libs: buildable: false externals: - - spec: rocm-device-libs@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: rocm-device-libs@6.1.2 + prefix: /opt/rocm-6.1.2/ rocm-gdb: buildable: false externals: - - spec: rocm-gdb@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: rocm-gdb@6.1.2 + prefix: /opt/rocm-6.1.2/ rocm-opencl: buildable: false externals: - - spec: rocm-opencl@5.7.1 - prefix: /opt/rocm-5.7.1/opencl + - spec: rocm-opencl@6.1.2 + prefix: /opt/rocm-6.1.2/opencl rocm-smi-lib: buildable: false externals: - - spec: rocm-smi-lib@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: rocm-smi-lib@6.1.2 + prefix: /opt/rocm-6.1.2/ hip: buildable: false externals: - - spec: hip@5.7.1 - prefix: /opt/rocm-5.7.1 + - spec: hip@6.1.2 + prefix: /opt/rocm-6.1.2 extra_attributes: compilers: - c: /opt/rocm-5.7.1/llvm/bin/clang++ - c++: /opt/rocm-5.7.1/llvm/bin/clang++ - hip: /opt/rocm-5.7.1/hip/bin/hipcc + c: /opt/rocm-6.1.2/llvm/bin/clang++ + c++: /opt/rocm-6.1.2/llvm/bin/clang++ + hip: /opt/rocm-6.1.2/hip/bin/hipcc hipify-clang: buildable: false externals: - - spec: hipify-clang@5.7.1 - prefix: /opt/rocm-5.7.1 + - spec: hipify-clang@6.1.2 + prefix: /opt/rocm-6.1.2 llvm-amdgpu: buildable: false externals: - - spec: llvm-amdgpu@5.7.1 - prefix: /opt/rocm-5.7.1/llvm + - spec: llvm-amdgpu@6.1.2 + prefix: /opt/rocm-6.1.2/llvm extra_attributes: compilers: - c: /opt/rocm-5.7.1/llvm/bin/clang++ - cxx: /opt/rocm-5.7.1/llvm/bin/clang++ + c: /opt/rocm-6.1.2/llvm/bin/clang++ + cxx: /opt/rocm-6.1.2/llvm/bin/clang++ hsakmt-roct: buildable: false externals: - - spec: hsakmt-roct@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: hsakmt-roct@6.1.2 + prefix: /opt/rocm-6.1.2/ hsa-rocr-dev: buildable: false externals: - - spec: hsa-rocr-dev@5.7.1 - prefix: /opt/rocm-5.7.1/ + - spec: hsa-rocr-dev@6.1.2 + prefix: /opt/rocm-6.1.2/ extra_atributes: compilers: - c: /opt/rocm-5.7.1/llvm/bin/clang++ - cxx: /opt/rocm-5.7.1/llvm/bin/clang++ + c: /opt/rocm-6.1.2/llvm/bin/clang++ + cxx: /opt/rocm-6.1.2/llvm/bin/clang++ roctracer-dev-api: buildable: false externals: - - spec: roctracer-dev-api@5.7.1 - prefix: /opt/rocm-5.7.1 + - spec: roctracer-dev-api@6.1.2 + prefix: /opt/rocm-6.1.2 roctracer-dev: buildable: false externals: - spec: roctracer-dev@4.5.3 - prefix: /opt/rocm-5.7.1 + prefix: /opt/rocm-6.1.2 rocprim: buildable: false externals: - - spec: rocprim@5.7.1 - prefix: /opt/rocm-5.7.1 + - spec: rocprim@6.1.2 + prefix: /opt/rocm-6.1.2 rocrand: buildable: false externals: - - spec: rocrand@5.7.1 - prefix: /opt/rocm-5.7.1 + - spec: rocrand@6.1.2 + prefix: /opt/rocm-6.1.2 hipsolver: buildable: false externals: - - spec: hipsolver@5.7.1 - prefix: /opt/rocm-5.7.1 + - spec: hipsolver@6.1.2 + prefix: /opt/rocm-6.1.2 rocsolver: buildable: false externals: - - spec: rocsolver@5.7.1 - prefix: /opt/rocm-5.7.1 + - spec: rocsolver@6.1.2 + prefix: /opt/rocm-6.1.2 rocsparse: buildable: false externals: - - spec: rocsparse@5.7.1 - prefix: /opt/rocm-5.7.1 + - spec: rocsparse@6.1.2 + prefix: /opt/rocm-6.1.2 rocthrust: buildable: false externals: - - spec: rocthrust@5.7.1 - prefix: /opt/rocm-5.7.1 + - spec: rocthrust@6.1.2 + prefix: /opt/rocm-6.1.2 rocprofiler-dev: buildable: false externals: - - spec: rocprofiler-dev@5.7.1 - prefix: /opt/rocm-5.7.1 + - spec: rocprofiler-dev@6.1.2 + prefix: /opt/rocm-6.1.2 + rocm-core: + buildable: false + externals: + - spec: rocm-core@6.1.2 + prefix: /opt/rocm-6.1.2 specs: # ROCM NOARCH - hpctoolkit +rocm - - tau +mpi +rocm +syscall # tau: has issue with `spack env depfile` build + - tau +mpi +rocm +syscall # ROCM 908 - - adios2 +kokkos +rocm amdgpu_target=gfx908 - amrex +rocm amdgpu_target=gfx908 - arborx +rocm amdgpu_target=gfx908 - cabana +rocm amdgpu_target=gfx908 - caliper +rocm amdgpu_target=gfx908 - - chai ~benchmarks +rocm amdgpu_target=gfx908 - # - cp2k +mpi +rocm amdgpu_target=gfx908 # cp2k: Error: KeyError: 'No spec with name rocm in... "-L{}".format(spec["rocm"].libs.directories[0]), + - chai +rocm amdgpu_target=gfx908 - ecp-data-vis-sdk +paraview +vtkm +rocm amdgpu_target=gfx908 - - exago +mpi +python +raja +hiop +rocm amdgpu_target=gfx908 ~ipopt cxxflags="-Wno-error=non-pod-varargs" ^hiop@1.0.0 ~sparse +mpi +raja +rocm amdgpu_target=gfx908 - gasnet +rocm amdgpu_target=gfx908 - ginkgo +rocm amdgpu_target=gfx908 - heffte +rocm amdgpu_target=gfx908 @@ -227,12 +229,8 @@ spack: - legion +rocm amdgpu_target=gfx908 - magma ~cuda +rocm amdgpu_target=gfx908 - mfem +rocm amdgpu_target=gfx908 - - petsc +rocm amdgpu_target=gfx908 - raja ~openmp +rocm amdgpu_target=gfx908 - # - slate +rocm amdgpu_target=gfx908 # slate: hip/device_gescale_row_col.hip.cc:58:49: error: use of overloaded operator '*' is ambiguous (with operand types 'HIP_vector_type' and 'const HIP_vector_type') - - slepc +rocm amdgpu_target=gfx908 ^petsc +rocm amdgpu_target=gfx908 - strumpack ~slate +rocm amdgpu_target=gfx908 - - sundials +rocm amdgpu_target=gfx908 - superlu-dist +rocm amdgpu_target=gfx908 - tasmanian ~openmp +rocm amdgpu_target=gfx908 - trilinos +amesos +amesos2 +anasazi +aztec +belos +boost +epetra +epetraext +ifpack ~ifpack2 +intrepid +intrepid2 +isorropia +kokkos +ml +minitensor +muelu +nox +piro +phalanx +rol +rythmos +sacado +stk +shards +shylu ~stokhos +stratimikos +teko +tempus +tpetra +trilinoscouplings +zoltan +zoltan2 +superlu-dist gotype=long_long +rocm amdgpu_target=gfx908 @@ -244,22 +242,26 @@ spack: # - hdf5-vol-cache # - hdf5-vol-log # - libcatalyst - - paraview +rocm amdgpu_target=gfx908 + # - paraview +rocm amdgpu_target=gfx908 # mesa: https://github.com/spack/spack/issues/44745 # - vtk-m ~openmp +rocm amdgpu_target=gfx908 # vtk-m: https://github.com/spack/spack/issues/40268 # -- + - adios2 +kokkos +rocm amdgpu_target=gfx908 # adios2:https://github.com/spack/spack/issues/44594 + # - cp2k +mpi +rocm amdgpu_target=gfx908 # cp2k: Error: KeyError: 'No spec with name rocm in... "-L{}".format(spec["rocm"].libs.directories[0]), + # - exago +mpi +python +raja +hiop +rocm amdgpu_target=gfx908 ~ipopt cxxflags="-Wno-error=non-pod-varargs" ^hiop@1.0.0 ~sparse +mpi +raja +rocm amdgpu_target=gfx908 # raja: https://github.com/spack/spack/issues/44593 # - lbann ~cuda +rocm amdgpu_target=gfx908 # aluminum: https://github.com/spack/spack/issues/38807 # - papi +rocm amdgpu_target=gfx908 # papi: https://github.com/spack/spack/issues/27898 + # - petsc +rocm amdgpu_target=gfx908 # petsc: https://github.com/spack/spack/issues/44600 + # - slate +rocm amdgpu_target=gfx908 # slate: hip/device_gescale_row_col.hip.cc:58:49: error: use of overloaded operator '*' is ambiguous (with operand types 'HIP_vector_type' and 'const HIP_vector_type') + # - slepc +rocm amdgpu_target=gfx908 ^petsc +rocm amdgpu_target=gfx908 # petsc: https://github.com/spack/spack/issues/44600 + # - sundials +rocm amdgpu_target=gfx908 # sundials: https://github.com/spack/spack/issues/44601 # ROCM 90a - - adios2 +kokkos +rocm amdgpu_target=gfx90a - amrex +rocm amdgpu_target=gfx90a - arborx +rocm amdgpu_target=gfx90a - cabana +rocm amdgpu_target=gfx90a - caliper +rocm amdgpu_target=gfx90a - - chai ~benchmarks +rocm amdgpu_target=gfx90a - # - cp2k +mpi +rocm amdgpu_target=gfx90a # cp2k: Error: KeyError: 'No spec with name rocm in... "-L{}".format(spec["rocm"].libs.directories[0]), + - chai +rocm amdgpu_target=gfx90a - ecp-data-vis-sdk +paraview +vtkm +rocm amdgpu_target=gfx90a - - exago +mpi +python +raja +hiop +rocm amdgpu_target=gfx90a ~ipopt cxxflags="-Wno-error=non-pod-varargs" ^hiop@1.0.0 ~sparse +mpi +raja +rocm amdgpu_target=gfx90a - gasnet +rocm amdgpu_target=gfx90a - ginkgo +rocm amdgpu_target=gfx90a - heffte +rocm amdgpu_target=gfx90a @@ -269,12 +271,8 @@ spack: - legion +rocm amdgpu_target=gfx90a - magma ~cuda +rocm amdgpu_target=gfx90a - mfem +rocm amdgpu_target=gfx90a - - petsc +rocm amdgpu_target=gfx90a - raja ~openmp +rocm amdgpu_target=gfx90a - # - slate +rocm amdgpu_target=gfx90a # slate: hip/device_gescale_row_col.hip.cc:58:49: error: use of overloaded operator '*' is ambiguous (with operand types 'HIP_vector_type' and 'const HIP_vector_type') - - slepc +rocm amdgpu_target=gfx90a ^petsc +rocm amdgpu_target=gfx90a - strumpack ~slate +rocm amdgpu_target=gfx90a - - sundials +rocm amdgpu_target=gfx90a - superlu-dist +rocm amdgpu_target=gfx90a - tasmanian ~openmp +rocm amdgpu_target=gfx90a - trilinos +amesos +amesos2 +anasazi +aztec +belos +boost +epetra +epetraext +ifpack ~ifpack2 +intrepid +intrepid2 +isorropia +kokkos +ml +minitensor +muelu +nox +piro +phalanx +rol +rythmos +sacado +stk +shards +shylu ~stokhos +stratimikos +teko +tempus +tpetra +trilinoscouplings +zoltan +zoltan2 +superlu-dist gotype=long_long +rocm amdgpu_target=gfx90a @@ -286,16 +284,23 @@ spack: # - hdf5-vol-cache # - hdf5-vol-log # - libcatalyst - - paraview +rocm amdgpu_target=gfx90a + # - paraview +rocm amdgpu_target=gfx90a # mesa: https://github.com/spack/spack/issues/44745 # - vtk-m ~openmp +rocm amdgpu_target=gfx90a # vtk-m: https://github.com/spack/spack/issues/40268 # -- + - adios2 +kokkos +rocm amdgpu_target=gfx90a # adios2: https://github.com/spack/spack/issues/44594 + # - cp2k +mpi +rocm amdgpu_target=gfx90a # cp2k: Error: KeyError: 'No spec with name rocm in... "-L{}".format(spec["rocm"].libs.directories[0]), + # - exago +mpi +python +raja +hiop +rocm amdgpu_target=gfx90a ~ipopt cxxflags="-Wno-error=non-pod-varargs" ^hiop@1.0.0 ~sparse +mpi +raja +rocm amdgpu_target=gfx90a # raja: https://github.com/spack/spack/issues/44593 # - lbann ~cuda +rocm amdgpu_target=gfx90a # aluminum: https://github.com/spack/spack/issues/38807 # - papi +rocm amdgpu_target=gfx90a # papi: https://github.com/spack/spack/issues/27898 + # - petsc +rocm amdgpu_target=gfx90a # petsc: https://github.com/spack/spack/issues/44600 + # - slate +rocm amdgpu_target=gfx90a # slate: hip/device_gescale_row_col.hip.cc:58:49: error: use of overloaded operator '*' is ambiguous (with operand types 'HIP_vector_type' and 'const HIP_vector_type') + # - slepc +rocm amdgpu_target=gfx90a ^petsc +rocm amdgpu_target=gfx90a # petsc: https://github.com/spack/spack/issues/44600 + # - sundials +rocm amdgpu_target=gfx90a # sundials: https://github.com/spack/spack/issues/44601 ci: pipeline-gen: - build-job: - image: ecpe4s/ubuntu22.04-runner-amd64-gcc-11.4-rocm5.7.1:2024.03.01 + image: ecpe4s/ubuntu22.04-runner-amd64-gcc-11.4-rocm6.1.2:2024.07.22 cdash: build-group: E4S ROCm External diff --git a/share/spack/gitlab/cloud_pipelines/stacks/e4s/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/e4s/spack.yaml index afd2058c9ad69c..5d25864371695e 100644 --- a/share/spack/gitlab/cloud_pipelines/stacks/e4s/spack.yaml +++ b/share/spack/gitlab/cloud_pipelines/stacks/e4s/spack.yaml @@ -52,7 +52,7 @@ spack: version: [11.8.0] paraview: # Don't build GUI support or GLX rendering for HPC/container deployments - require: "@5.11 ~qt+osmesa" + require: "@5.11 +examples ~qt ^[virtuals=gl] osmesa" specs: # CPU @@ -69,7 +69,7 @@ spack: - butterflypack - cabana - caliper - - chai ~benchmarks ~tests + - chai - charliecloud - conduit - cp2k +mpi @@ -78,12 +78,14 @@ spack: - drishti - dxt-explorer - dyninst - - ecp-data-vis-sdk ~cuda ~rocm +adios2 +ascent +cinema +darshan +faodel +hdf5 +paraview +pnetcdf +sz +unifyfs +veloc +visit +vtkm +zfp # adios2~cuda, ascent~cuda, darshan-runtime, darshan-util, faodel, hdf5, libcatalyst, parallel-netcdf, paraview~cuda, py-cinemasci, sz, unifyfs, veloc, visit, vtk-m, zfp + - e4s-cl + - ecp-data-vis-sdk ~cuda ~rocm +adios2 +ascent +cinema +darshan +faodel +hdf5 +paraview +pnetcdf +sz +unifyfs +veloc +visit +vtkm +zfp # adios2~cuda, ascent~cuda, darshan-runtime, darshan-util, faodel, hdf5, libcatalyst, parallel-netcdf, paraview~cuda, py-cinemasci, sz, unifyfs, veloc, visit, vtk-m, zfp - exaworks - flecsi - flit - flux-core - fortrilinos + - fpm - gasnet - ginkgo - globalarrays @@ -103,7 +105,7 @@ spack: - kokkos +openmp - kokkos-kernels +openmp - laghos - - lammps + - lammps +amoeba +asphere +bocs +body +bpm +brownian +cg-dna +cg-spica +class2 +colloid +colvars +compress +coreshell +dielectric +diffraction +dipole +dpd-basic +dpd-meso +dpd-react +dpd-smooth +drude +eff +electrode +extra-compute +extra-dump +extra-fix +extra-molecule +extra-pair +fep +granular +interlayer +kspace +lepton +machdyn +manybody +mc +meam +mesont +misc +ml-iap +ml-pod +ml-snap +mofff +molecule +openmp-package +opt +orient +peri +phonon +plugin +poems +qeq +reaction +reaxff +replica +rigid +shock +sph +spin +srd +tally +uef +voronoi +yaff - lbann - legion - libnrm @@ -119,6 +121,8 @@ spack: - mpifileutils ~xattr - nccmp - nco + - nekbone +mpi + - netcdf-fortran - netlib-scalapack - nrm - nvhpc @@ -137,6 +141,7 @@ spack: - precice - pruners-ninja - pumi + - py-amrex - py-h5py - py-jupyterhub - py-libensemble @@ -180,12 +185,13 @@ spack: - sz - unifyfs - veloc - # - visit # silo: https://github.com/spack/spack/issues/39538 + - visit # silo: https://github.com/spack/spack/issues/39538 - vtk-m - zfp # -- # - geopm # geopm: https://github.com/spack/spack/issues/38795 - # - glvis # glvis: https://github.com/spack/spack/issues/42839 + - glvis # glvis: https://github.com/spack/spack/issues/42839 + # - nek5000 +mpi +visit # nek5000: Error: AttributeError: 'str' object has no attribute 'propagate': 'VISIT_INSTALL="' + spec["visit"].prefix.bin + '"', # PYTHON PACKAGES - opencv +python3 @@ -207,199 +213,159 @@ spack: - py-seaborn - py-tensorflow - py-torch + - py-deephyper - # # CUDA NOARCH - # - bricks +cuda - # - flux-core +cuda - # - hpctoolkit +cuda - # - papi +cuda - # - tau +mpi +cuda +syscall - # # -- - # # - legion +cuda # legion: needs NVIDIA driver - - # # CUDA 80 - # - amrex +cuda cuda_arch=80 - # - arborx +cuda cuda_arch=80 ^kokkos +wrapper - # - cabana +cuda cuda_arch=80 ^kokkos +wrapper +cuda_lambda +cuda cuda_arch=80 - # - caliper +cuda cuda_arch=80 - # - chai ~benchmarks ~tests +cuda cuda_arch=80 ^umpire ~shared - # - cusz +cuda cuda_arch=80 - # - dealii +cuda cuda_arch=80 - # - ecp-data-vis-sdk ~rocm +adios2 ~ascent +hdf5 +vtkm +zfp +paraview +cuda cuda_arch=80 # +ascent fails because fides fetch error - # - exago +mpi +python +raja +hiop ~rocm +cuda cuda_arch=80 ~ipopt ^hiop@1.0.0 ~sparse +mpi +raja ~rocm +cuda cuda_arch=80 #^raja@0.14.0 - # - flecsi +cuda cuda_arch=80 - # - ginkgo +cuda cuda_arch=80 - # - gromacs +cuda cuda_arch=80 - # - heffte +cuda cuda_arch=80 - # - hpx +cuda cuda_arch=80 - # - hypre +cuda cuda_arch=80 - # - kokkos +wrapper +cuda cuda_arch=80 - # - kokkos-kernels +cuda cuda_arch=80 ^kokkos +wrapper +cuda cuda_arch=80 - # - libpressio +bitgrooming +bzip2 +fpzip +hdf5 +libdistributed +lua +openmp +python +sz +sz3 +unix +zfp +json +remote +netcdf +cusz +mgard +cuda cuda_arch=80 ^cusz +cuda cuda_arch=80 - # - magma +cuda cuda_arch=80 - # - mfem +cuda cuda_arch=80 - # - mgard +serial +openmp +timing +unstructured +cuda cuda_arch=80 - # - omega-h +cuda cuda_arch=80 - # - parsec +cuda cuda_arch=80 - # - petsc +cuda cuda_arch=80 - # - py-torch +cuda cuda_arch=80 - # - raja +cuda cuda_arch=80 - # - slate +cuda cuda_arch=80 - # - slepc +cuda cuda_arch=80 - # - strumpack ~slate +cuda cuda_arch=80 - # - sundials +cuda cuda_arch=80 - # - superlu-dist +cuda cuda_arch=80 - # - tasmanian +cuda cuda_arch=80 - # - trilinos +cuda cuda_arch=80 - # - umpire ~shared +cuda cuda_arch=80 - # # INCLUDED IN ECP DAV CUDA - # # - adios2 +cuda cuda_arch=80 - # # - ascent +cuda cuda_arch=80 # ascent: https://github.com/spack/spack/issues/38045 - # # - paraview +cuda cuda_arch=80 - # # - vtk-m +cuda cuda_arch=80 - # # - zfp +cuda cuda_arch=80 - # # -- - # # - lammps +cuda cuda_arch=80 # lammps: needs NVIDIA driver - # # - upcxx +cuda cuda_arch=80 # upcxx: needs NVIDIA driver - # # - axom +cuda cuda_arch=80 # axom: https://github.com/spack/spack/issues/29520 - # # - lbann +cuda cuda_arch=80 # lbann: https://github.com/spack/spack/issues/38788 + # CUDA NOARCH + - bricks +cuda + - flux-core +cuda + - hpctoolkit +cuda + - papi +cuda + - tau +mpi +cuda +syscall + # -- + # - legion +cuda # legion: needs NVIDIA driver - # # CUDA 90 - # - amrex +cuda cuda_arch=90 - # - arborx +cuda cuda_arch=90 ^kokkos +wrapper - # - cabana +cuda cuda_arch=90 ^kokkos +wrapper +cuda_lambda +cuda cuda_arch=90 - # - caliper +cuda cuda_arch=90 - # - chai ~benchmarks ~tests +cuda cuda_arch=90 ^umpire ~shared - # - cusz +cuda cuda_arch=90 - # - flecsi +cuda cuda_arch=90 - # - ginkgo +cuda cuda_arch=90 - # - gromacs +cuda cuda_arch=90 - # - heffte +cuda cuda_arch=90 - # - hpx +cuda cuda_arch=90 - # - kokkos +wrapper +cuda cuda_arch=90 - # - kokkos-kernels +cuda cuda_arch=90 ^kokkos +wrapper +cuda cuda_arch=90 - # - libpressio +bitgrooming +bzip2 +fpzip +hdf5 +libdistributed +lua +openmp +python +sz +sz3 +unix +zfp +json +remote +netcdf +cusz +mgard +cuda cuda_arch=90 ^cusz +cuda cuda_arch=90 - # - magma +cuda cuda_arch=90 - # - mfem +cuda cuda_arch=90 - # - mgard +serial +openmp +timing +unstructured +cuda cuda_arch=90 - # - parsec +cuda cuda_arch=90 - # - petsc +cuda cuda_arch=90 - # - py-torch +cuda cuda_arch=90 - # - raja +cuda cuda_arch=90 - # - slate +cuda cuda_arch=90 - # - slepc +cuda cuda_arch=90 - # - strumpack ~slate +cuda cuda_arch=90 - # - sundials +cuda cuda_arch=90 - # - superlu-dist +cuda cuda_arch=90 - # - trilinos +cuda cuda_arch=90 - # - umpire ~shared +cuda cuda_arch=90 - # # INCLUDED IN ECP DAV CUDA - # - adios2 +cuda cuda_arch=90 - # # - ascent +cuda cuda_arch=90 # ascent: https://github.com/spack/spack/issues/38045 - # # - paraview +cuda cuda_arch=90 # paraview: InstallError: Incompatible cuda_arch=90 - # - vtk-m +cuda cuda_arch=90 - # - zfp +cuda cuda_arch=90 - # # -- - # # - axom +cuda cuda_arch=90 # axom: https://github.com/spack/spack/issues/29520 - # # - dealii +cuda cuda_arch=90 # dealii: https://github.com/spack/spack/issues/39532 - # # - ecp-data-vis-sdk ~rocm +adios2 +ascent +hdf5 +vtkm +zfp +paraview +cuda cuda_arch=90 # paraview: incompatible cuda_arch; vtk-m: CMake Error at CMake/VTKmWrappers.cmake:413 (message): vtkm_cont needs to be built STATIC as CUDA doesn't support virtual methods across dynamic library boundaries. You need to set the CMake opt ion BUILD_SHARED_LIBS to `OFF` or (better) turn VTKm_NO_DEPRECATED_VIRTUAL to `ON`. - # # - hypre +cuda cuda_arch=90 # concretizer: hypre +cuda requires cuda@:11, but cuda_arch=90 requires cuda@12: - # # - lammps +cuda cuda_arch=90 # lammps: needs NVIDIA driver - # # - lbann +cuda cuda_arch=90 # concretizer: Cannot select a single "version" for package "lbann" - # # - omega-h +cuda cuda_arch=90 # omega-h: https://github.com/spack/spack/issues/39535 - # # - tasmanian +cuda cuda_arch=90 # tasmanian: conflicts with cuda@12 - # # - upcxx +cuda cuda_arch=90 # upcxx: needs NVIDIA driver + # CUDA 80 + - amrex +cuda cuda_arch=80 + - arborx +cuda cuda_arch=80 ^kokkos +wrapper + - axom +cuda cuda_arch=80 + - cabana +cuda cuda_arch=80 ^kokkos +wrapper +cuda_lambda +cuda cuda_arch=80 + - caliper +cuda cuda_arch=80 + - chai +cuda cuda_arch=80 ^umpire ~shared + - cusz +cuda cuda_arch=80 + - ecp-data-vis-sdk ~rocm +adios2 ~ascent +hdf5 +vtkm +zfp +paraview +cuda cuda_arch=80 # +ascent fails because fides fetch error + - exago +mpi +python +raja +hiop ~rocm +cuda cuda_arch=80 ~ipopt ^hiop@1.0.0 ~sparse +mpi +raja ~rocm +cuda cuda_arch=80 #^raja@0.14.0 + - flecsi +cuda cuda_arch=80 + - ginkgo +cuda cuda_arch=80 + - gromacs +cuda cuda_arch=80 + - heffte +cuda cuda_arch=80 + - hpx +cuda cuda_arch=80 + - hypre +cuda cuda_arch=80 + - kokkos +wrapper +cuda cuda_arch=80 + - kokkos-kernels +cuda cuda_arch=80 ^kokkos +wrapper +cuda cuda_arch=80 + - libpressio +bitgrooming +bzip2 +fpzip +hdf5 +libdistributed +lua +openmp +python +sz +sz3 +unix +zfp +json +remote +netcdf +cusz +mgard +cuda cuda_arch=80 ^cusz +cuda cuda_arch=80 + - magma +cuda cuda_arch=80 + - mfem +cuda cuda_arch=80 + - omega-h +cuda cuda_arch=80 + - parsec +cuda cuda_arch=80 + - petsc +cuda cuda_arch=80 + - py-torch +cuda cuda_arch=80 + - raja +cuda cuda_arch=80 + - slate +cuda cuda_arch=80 + - slepc +cuda cuda_arch=80 + - strumpack ~slate +cuda cuda_arch=80 + - sundials +cuda cuda_arch=80 + - superlu-dist +cuda cuda_arch=80 + - tasmanian +cuda cuda_arch=80 + - trilinos +cuda cuda_arch=80 + - umpire ~shared +cuda cuda_arch=80 + # INCLUDED IN ECP DAV CUDA + - adios2 +cuda cuda_arch=80 + # - ascent +cuda cuda_arch=80 # ascent: https://github.com/spack/spack/issues/38045 + - paraview +cuda cuda_arch=80 + - vtk-m +cuda cuda_arch=80 + - zfp +cuda cuda_arch=80 + # -- + # - dealii +cuda cuda_arch=80 # dealii: conflicts with '+cuda ^cuda@12:' + # - lammps +cuda cuda_arch=80 # lammps: needs NVIDIA driver + # - lbann +cuda cuda_arch=80 # lbann: layers/transform/cereal_registration/../permute/cutensor_support.hpp:95:18: error: 'cutensorInit' was not declared in this scope; did you mean 'cutensorPlan_t'? + # - mgard +serial +openmp +timing +unstructured +cuda cuda_arch=80 # mgard: https://github.com/spack/spack/issues/44833 + # - upcxx +cuda cuda_arch=80 # upcxx: needs NVIDIA driver - # # ROCM NOARCH - # - hpctoolkit +rocm - # - tau +mpi +rocm +syscall # tau: has issue with `spack env depfile` build + # CUDA 90 + - amrex +cuda cuda_arch=90 + - arborx +cuda cuda_arch=90 ^kokkos +wrapper + - axom +cuda cuda_arch=90 + - cabana +cuda cuda_arch=90 ^kokkos +wrapper +cuda_lambda +cuda cuda_arch=90 + - caliper +cuda cuda_arch=90 + - chai +cuda cuda_arch=90 ^umpire ~shared + - flecsi +cuda cuda_arch=90 + - ginkgo +cuda cuda_arch=90 + - gromacs +cuda cuda_arch=90 + - heffte +cuda cuda_arch=90 + - hpx +cuda cuda_arch=90 + - hypre +cuda cuda_arch=90 + - kokkos +wrapper +cuda cuda_arch=90 + - kokkos-kernels +cuda cuda_arch=90 ^kokkos +wrapper +cuda cuda_arch=90 + - magma +cuda cuda_arch=90 + - mfem +cuda cuda_arch=90 + - mgard +serial +openmp +timing +unstructured +cuda cuda_arch=90 + - parsec +cuda cuda_arch=90 + - petsc +cuda cuda_arch=90 + - raja +cuda cuda_arch=90 + - slate +cuda cuda_arch=90 + - slepc +cuda cuda_arch=90 + - strumpack ~slate +cuda cuda_arch=90 + - sundials +cuda cuda_arch=90 + - superlu-dist +cuda cuda_arch=90 + - tasmanian +cuda cuda_arch=90 + - trilinos +cuda cuda_arch=90 + - umpire ~shared +cuda cuda_arch=90 + # INCLUDED IN ECP DAV CUDA + - adios2 +cuda cuda_arch=90 + # - ascent +cuda cuda_arch=90 # ascent: https://github.com/spack/spack/issues/38045 + # - paraview +cuda cuda_arch=90 # paraview: InstallError: Incompatible cuda_arch=90 + - vtk-m +cuda cuda_arch=90 + - zfp +cuda cuda_arch=90 + # -- + # - cusz +cuda cuda_arch=90 # cusz: cuda-12.5.0-ndrzb7undvancjdj3fi6bhthdxdo7gr5/targets/x86_64-linux/include/cub/util_device.cuh:202:50: error: 'blockDim' was not declared in this scope + # - dealii +cuda cuda_arch=90 # dealii: conflicts with '+cuda ^cuda@12:'; dealii: https://github.com/spack/spack/issues/39532 + # - ecp-data-vis-sdk ~rocm +adios2 +ascent +hdf5 +vtkm +zfp +paraview +cuda cuda_arch=90 # +ascent: # ascent: https://github.com/spack/spack/issues/38045; +paraview: VTK/ThirdParty/vtkm/vtkvtkm/vtk-m/vtkm/exec/cuda/internal/ExecutionPolicy.h(121): error: namespace "thrust" has no member "sort" + # - lammps +cuda cuda_arch=90 # lammps: needs NVIDIA driver + # - lbann +cuda cuda_arch=90 # aluminum: /usr/include/c++/11/bits/basic_string.h:1260: multiple definition of `cub::CUB_200400___CUDA_ARCH_LIST___NS::Debug(cudaError, char const*, int)'; + # - libpressio +bitgrooming +bzip2 +fpzip +hdf5 +libdistributed +lua +openmp +python +sz +sz3 +unix +zfp +json +remote +netcdf +cusz +mgard +cuda cuda_arch=90 ^cusz +cuda cuda_arch=90 # cusz: cuda-12.5.0-e3rny44pq5z5x3nnoljynbsq5on5fnl3/targets/x86_64-linux/include/cub/util_device.cuh:202:50: error: 'blockDim' was not declared in this scope + # - omega-h +cuda cuda_arch=90 # omega-h: https://github.com/spack/spack/issues/39535 + # - py-torch +cuda cuda_arch=90 # py-torch: FAILED: caffe2/CMakeFiles/torch_cuda.dir/__/aten/src/ATen/native/transformers/cuda/flash_attn/kernels/flash_bwd_hdim256_bf16_sm80.cu.o + # - upcxx +cuda cuda_arch=90 # upcxx: needs NVIDIA driver - # # ROCM 908 - # - adios2 +kokkos +rocm amdgpu_target=gfx908 - # - amrex +rocm amdgpu_target=gfx908 - # - arborx +rocm amdgpu_target=gfx908 - # - cabana +rocm amdgpu_target=gfx908 - # - caliper +rocm amdgpu_target=gfx908 - # - chai ~benchmarks +rocm amdgpu_target=gfx908 - # - ecp-data-vis-sdk +paraview +vtkm +rocm amdgpu_target=gfx908 - # - gasnet +rocm amdgpu_target=gfx908 - # - ginkgo +rocm amdgpu_target=gfx908 - # - heffte +rocm amdgpu_target=gfx908 - # - hpx +rocm amdgpu_target=gfx908 - # - hypre +rocm amdgpu_target=gfx908 - # - kokkos +rocm amdgpu_target=gfx908 - # - legion +rocm amdgpu_target=gfx908 - # - magma ~cuda +rocm amdgpu_target=gfx908 - # - mfem +rocm amdgpu_target=gfx908 - # - petsc +rocm amdgpu_target=gfx908 - # - raja ~openmp +rocm amdgpu_target=gfx908 - # - slate +rocm amdgpu_target=gfx908 - # - slepc +rocm amdgpu_target=gfx908 ^petsc +rocm amdgpu_target=gfx908 - # - strumpack ~slate +rocm amdgpu_target=gfx908 - # - sundials +rocm amdgpu_target=gfx908 - # - superlu-dist +rocm amdgpu_target=gfx908 - # - tasmanian ~openmp +rocm amdgpu_target=gfx908 - # - trilinos +amesos +amesos2 +anasazi +aztec +belos +boost +epetra +epetraext +ifpack ~ifpack2 +intrepid +intrepid2 +isorropia +kokkos +ml +minitensor +muelu +nox +piro +phalanx +rol +rythmos +sacado +stk +shards +shylu ~stokhos +stratimikos +teko +tempus +tpetra +trilinoscouplings +zoltan +zoltan2 +superlu-dist gotype=long_long +rocm amdgpu_target=gfx908 - # - umpire +rocm amdgpu_target=gfx908 - # - upcxx +rocm amdgpu_target=gfx908 - # # INCLUDED IN ECP DAV ROCM - # # - hdf5 - # # - hdf5-vol-async - # # - hdf5-vol-cache - # # - hdf5-vol-log - # # - libcatalyst - # - paraview +rocm amdgpu_target=gfx908 - # # - vtk-m ~openmp +rocm amdgpu_target=gfx908 # vtk-m: https://github.com/spack/spack/issues/40268 - # # -- - # # - exago +mpi +python +raja +hiop +rocm amdgpu_target=gfx908 ~ipopt cxxflags="-Wno-error=non-pod-varargs" ^hiop@1.0.0 ~sparse +mpi +raja +rocm amdgpu_target=gfx908 # hiop: CMake Error at cmake/FindHiopHipLibraries.cmake:23 (find_package) - # # - lbann ~cuda +rocm amdgpu_target=gfx908 # aluminum: https://github.com/spack/spack/issues/38807 - # # - papi +rocm amdgpu_target=gfx908 # papi: https://github.com/spack/spack/issues/27898 + # ROCM NOARCH + - hpctoolkit +rocm + - tau +mpi +rocm +syscall # tau: has issue with `spack env depfile` build - # # ROCM 90a - # - adios2 +kokkos +rocm amdgpu_target=gfx90a - # - amrex +rocm amdgpu_target=gfx90a - # - arborx +rocm amdgpu_target=gfx90a - # - cabana +rocm amdgpu_target=gfx90a - # - caliper +rocm amdgpu_target=gfx90a - # - chai ~benchmarks +rocm amdgpu_target=gfx90a - # - ecp-data-vis-sdk +paraview +vtkm +rocm amdgpu_target=gfx90a - # - gasnet +rocm amdgpu_target=gfx90a - # - ginkgo +rocm amdgpu_target=gfx90a - # - heffte +rocm amdgpu_target=gfx90a - # - hpx +rocm amdgpu_target=gfx90a - # - hypre +rocm amdgpu_target=gfx90a - # - kokkos +rocm amdgpu_target=gfx90a - # - legion +rocm amdgpu_target=gfx90a - # - magma ~cuda +rocm amdgpu_target=gfx90a - # - mfem +rocm amdgpu_target=gfx90a - # - petsc +rocm amdgpu_target=gfx90a - # - raja ~openmp +rocm amdgpu_target=gfx90a - # - slate +rocm amdgpu_target=gfx90a - # - slepc +rocm amdgpu_target=gfx90a ^petsc +rocm amdgpu_target=gfx90a - # - strumpack ~slate +rocm amdgpu_target=gfx90a - # - sundials +rocm amdgpu_target=gfx90a - # - superlu-dist +rocm amdgpu_target=gfx90a - # - tasmanian ~openmp +rocm amdgpu_target=gfx90a - # - trilinos +amesos +amesos2 +anasazi +aztec +belos +boost +epetra +epetraext +ifpack ~ifpack2 +intrepid +intrepid2 +isorropia +kokkos +ml +minitensor +muelu +nox +piro +phalanx +rol +rythmos +sacado +stk +shards +shylu ~stokhos +stratimikos +teko +tempus +tpetra +trilinoscouplings +zoltan +zoltan2 +superlu-dist gotype=long_long +rocm amdgpu_target=gfx90a - # - umpire +rocm amdgpu_target=gfx90a - # - upcxx +rocm amdgpu_target=gfx90a - # # INCLUDED IN ECP DAV ROCM - # # - hdf5 - # # - hdf5-vol-async - # # - hdf5-vol-cache - # # - hdf5-vol-log - # # - libcatalyst - # - paraview +rocm amdgpu_target=gfx90a - # # - vtk-m ~openmp +rocm amdgpu_target=gfx90a # vtk-m: https://github.com/spack/spack/issues/40268 - # # -- - # # - exago +mpi +python +raja +hiop +rocm amdgpu_target=gfx90a ~ipopt cxxflags="-Wno-error=non-pod-varargs" ^hiop@1.0.0 ~sparse +mpi +raja +rocm amdgpu_target=gfx90a # hiop: CMake Error at cmake/FindHiopHipLibraries.cmake:23 (find_package) - # # - lbann ~cuda +rocm amdgpu_target=gfx90a # aluminum: https://github.com/spack/spack/issues/38807 - # # - papi +rocm amdgpu_target=gfx90a # papi: https://github.com/spack/spack/issues/27898 + # ROCM 90a + - amrex +rocm amdgpu_target=gfx90a + - caliper +rocm amdgpu_target=gfx90a + - chai +rocm amdgpu_target=gfx90a + - ecp-data-vis-sdk +paraview +vtkm +rocm amdgpu_target=gfx90a + - gasnet +rocm amdgpu_target=gfx90a + - ginkgo +rocm amdgpu_target=gfx90a + - heffte +rocm amdgpu_target=gfx90a + - hpx +rocm amdgpu_target=gfx90a + - hypre +rocm amdgpu_target=gfx90a + - magma ~cuda +rocm amdgpu_target=gfx90a + - mfem +rocm amdgpu_target=gfx90a + - raja ~openmp +rocm amdgpu_target=gfx90a + - slate +rocm amdgpu_target=gfx90a + - strumpack ~slate +rocm amdgpu_target=gfx90a + - sundials +rocm amdgpu_target=gfx90a + - superlu-dist +rocm amdgpu_target=gfx90a + - tasmanian ~openmp +rocm amdgpu_target=gfx90a + - trilinos +amesos +amesos2 +anasazi +aztec +belos +boost +epetra +epetraext +ifpack ~ifpack2 +intrepid +intrepid2 +isorropia +kokkos +ml +minitensor +muelu +nox +piro +phalanx +rol +rythmos +sacado +stk +shards +shylu ~stokhos +stratimikos +teko +tempus +tpetra +trilinoscouplings +zoltan +zoltan2 +superlu-dist gotype=long_long +rocm amdgpu_target=gfx90a + - umpire +rocm amdgpu_target=gfx90a + - upcxx +rocm amdgpu_target=gfx90a + # INCLUDED IN ECP DAV ROCM + # - hdf5 + # - hdf5-vol-async + # - hdf5-vol-cache + # - hdf5-vol-log + # - libcatalyst + - paraview +rocm amdgpu_target=gfx90a + # - vtk-m ~openmp +rocm amdgpu_target=gfx90a # vtk-m: https://github.com/spack/spack/issues/40268 + # -- + # - adios2 +kokkos +rocm amdgpu_target=gfx90a # +kokkos: https://github.com/spack/spack/issues/44832 + # - arborx +rocm amdgpu_target=gfx90a # kokkos: https://github.com/spack/spack/issues/44832 + # - cabana +rocm amdgpu_target=gfx90a # kokkos: https://github.com/spack/spack/issues/44832 + # - exago +mpi +python +raja +hiop +rocm amdgpu_target=gfx90a ~ipopt cxxflags="-Wno-error=non-pod-varargs" ^hiop@1.0.0 ~sparse +mpi +raja +rocm amdgpu_target=gfx90a # hiop: CMake Error at cmake/FindHiopHipLibraries.cmake:23 (find_package) + # - kokkos +rocm amdgpu_target=gfx90a # kokkos: https://github.com/spack/spack/issues/44832 + # - lbann ~cuda +rocm amdgpu_target=gfx90a # aluminum: https://github.com/spack/spack/issues/38807 + # - legion +rocm amdgpu_target=gfx90a # kokkos: https://github.com/spack/spack/issues/44832 + # - papi +rocm amdgpu_target=gfx90a # papi: https://github.com/spack/spack/issues/27898 + # - petsc +rocm amdgpu_target=gfx90a # petsc: https://github.com/spack/spack/issues/44600 + # - slepc +rocm amdgpu_target=gfx90a ^petsc +rocm amdgpu_target=gfx90a # petsc: https://github.com/spack/spack/issues/44600 - # - cp2k +mpi +cuda cuda_arch=80 # cp2k: spack-stage-libxsmm-1.17-ml4asr3rsb5biw34x6m764cbrp3zrwyk/spack-src/./src/libxsmm_gemm.c:223: undefined reference to `dgemv_' - # - cp2k +mpi +cuda cuda_arch=90 # cp2k: cp2k only supports cuda_arch ('35', '37', '60', '70', '80') - # - cp2k +mpi +rocm amdgpu_target=gfx908 # cp2k: Error: KeyError: 'No spec with name rocm in... "-L{}".format(spec["rocm"].libs.directories[0]), - # - cp2k +mpi +rocm amdgpu_target=gfx90a # cp2k: Error: KeyError: 'No spec with name rocm in... "-L{}".format(spec["rocm"].libs.directories[0]), + # - cp2k +mpi +cuda cuda_arch=80 # cp2k: spack-stage-libxsmm-1.17-r2zqxa24bhufaj5i3ili5se25cw7tioo/spack-src/./src/libxsmm_gemm.c:238: undefined reference to `sgemv_' + # - cp2k +mpi +cuda cuda_arch=90 # cp2k: cp2k only supports cuda_arch ('35', '37', '60', '70', '80') + # - cp2k +mpi +rocm amdgpu_target=gfx908 # cp2k: "-L{}".format(spec["rocm"].libs.directories[0]), + # - cp2k +mpi +rocm amdgpu_target=gfx90a # cp2k: "-L{}".format(spec["rocm"].libs.directories[0]), ci: pipeline-gen: diff --git a/share/spack/gitlab/cloud_pipelines/stacks/gpu-tests/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/gpu-tests/spack.yaml index 263d8e29b30578..addccd7bd21a83 100644 --- a/share/spack/gitlab/cloud_pipelines/stacks/gpu-tests/spack.yaml +++ b/share/spack/gitlab/cloud_pipelines/stacks/gpu-tests/spack.yaml @@ -31,7 +31,7 @@ spack: variants: threads=openmp paraview: # Don't build GUI support or GLX rendering for HPC/container deployments - require: "@5.11 ~qt+osmesa" + require: "@5.11 ~qt ^[virtuals=gl] osmesa" trilinos: require: +amesos +amesos2 +anasazi +aztec +boost +epetra +epetraext +ifpack +intrepid +intrepid2 +isorropia +kokkos +ml +minitensor +muelu diff --git a/share/spack/gitlab/cloud_pipelines/stacks/ml-darwin-aarch64-mps/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/ml-darwin-aarch64-mps/spack.yaml index 94211f6cdeebe0..d3eb74a36637f7 100644 --- a/share/spack/gitlab/cloud_pipelines/stacks/ml-darwin-aarch64-mps/spack.yaml +++ b/share/spack/gitlab/cloud_pipelines/stacks/ml-darwin-aarch64-mps/spack.yaml @@ -34,9 +34,6 @@ spack: - py-keras-preprocessing - py-keras2onnx - # MXNet not supported on darwin aarch64 yet - # - mxnet - # PyTorch - py-botorch - py-efficientnet-pytorch @@ -84,8 +81,6 @@ spack: # XGBoost - py-xgboost - # - r-xgboost - - xgboost ci: pipeline-gen: diff --git a/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-cpu/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-cpu/spack.yaml index fd22335885a970..5656455adf5471 100644 --- a/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-cpu/spack.yaml +++ b/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-cpu/spack.yaml @@ -28,9 +28,6 @@ spack: - py-keras-preprocessing - py-keras2onnx - # MXNet - - mxnet - # PyTorch - py-botorch - py-efficientnet-pytorch @@ -77,14 +74,12 @@ spack: # XGBoost - py-xgboost - # - r-xgboost - - xgboost ci: pipeline-gen: - build-job: image: - name: ghcr.io/spack/linux-ubuntu22.04-x86_64_v2:v2024-01-29 + name: ghcr.io/spack/ubuntu-22.04:v2024-05-07 entrypoint: [''] cdash: diff --git a/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-cuda/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-cuda/spack.yaml index 5053f28fd34e6e..ef7234fd55ed57 100644 --- a/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-cuda/spack.yaml +++ b/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-cuda/spack.yaml @@ -32,9 +32,6 @@ spack: - py-keras-preprocessing - py-keras2onnx - # MXNet - - mxnet - # PyTorch - py-botorch - py-efficientnet-pytorch @@ -81,14 +78,12 @@ spack: # XGBoost - py-xgboost - # - r-xgboost - - xgboost ci: pipeline-gen: - build-job: image: - name: ghcr.io/spack/linux-ubuntu22.04-x86_64_v2:v2024-01-29 + name: ghcr.io/spack/ubuntu-22.04:v2024-05-07 entrypoint: [''] cdash: diff --git a/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-rocm/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-rocm/spack.yaml index 4fb9e0eddf0131..7a236b136df636 100644 --- a/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-rocm/spack.yaml +++ b/share/spack/gitlab/cloud_pipelines/stacks/ml-linux-x86_64-rocm/spack.yaml @@ -9,59 +9,55 @@ spack: - amdgpu_target=gfx90a gl: require: "osmesa" - py-torch: - # Does not yet support Spack-installed ROCm - require: ~rocm mpi: require: openmpi specs: # Horovod - - py-horovod + # - py-horovod # Hugging Face - py-transformers # JAX - - py-jax - - py-jaxlib + # Does not yet support Spack-installed ROCm + # - py-jax + # - py-jaxlib # Keras - # - py-keras backend=tensorflow - - py-keras backend=jax - - py-keras backend=torch + - py-keras backend=tensorflow + # - py-keras backend=jax + # - py-keras backend=torch - py-keras-applications - py-keras-preprocessing - py-keras2onnx - # MXNet - - mxnet - # PyTorch - - py-botorch - - py-efficientnet-pytorch - - py-gpytorch - - py-kornia - - py-lightning - - py-pytorch-gradual-warmup-lr - - py-pytorch-lightning - - py-segmentation-models-pytorch - - py-timm - - py-torch - - py-torch-cluster - - py-torch-geometric - - py-torch-nvidia-apex - - py-torch-scatter - - py-torch-sparse - - py-torch-spline-conv - - py-torchaudio - - py-torchdata - - py-torchfile - - py-torchgeo - - py-torchmetrics - - py-torchtext - - py-torchvision - - py-vector-quantize-pytorch + # Does not yet support Spack-installed ROCm + # - py-botorch + # - py-efficientnet-pytorch + # - py-gpytorch + # - py-kornia + # - py-lightning + # - py-pytorch-gradual-warmup-lr + # - py-pytorch-lightning + # - py-segmentation-models-pytorch + # - py-timm + # - py-torch + # - py-torch-cluster + # - py-torch-geometric + # - py-torch-nvidia-apex + # - py-torch-scatter + # - py-torch-sparse + # - py-torch-spline-conv + # - py-torchaudio + # - py-torchdata + # - py-torchfile + # - py-torchgeo + # - py-torchmetrics + # - py-torchtext + # - py-torchvision + # - py-vector-quantize-pytorch # scikit-learn - py-scikit-learn @@ -74,24 +70,23 @@ spack: - py-tensorboardx # TensorFlow - # Does not yet support Spack-installed ROCm - # - py-tensorflow - # - py-tensorflow-datasets + - py-tensorflow + - py-tensorflow-datasets + # version 2.16 is not available # - py-tensorflow-estimator - # - py-tensorflow-hub - # - py-tensorflow-metadata - # - py-tensorflow-probability + - py-tensorflow-hub + - py-tensorflow-metadata + - py-tensorflow-probability # XGBoost - - py-xgboost - # - r-xgboost - - xgboost + # Does not yet support Spack-installed ROCm + # - py-xgboost ci: pipeline-gen: - build-job: image: - name: ghcr.io/spack/linux-ubuntu22.04-x86_64_v2:v2024-01-29 + name: ghcr.io/spack/ubuntu-22.04:v2024-05-07 entrypoint: [''] cdash: diff --git a/share/spack/gitlab/cloud_pipelines/stacks/radiuss/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/radiuss/spack.yaml index ca8e1a990519db..a8b064535b5102 100644 --- a/share/spack/gitlab/cloud_pipelines/stacks/radiuss/spack.yaml +++ b/share/spack/gitlab/cloud_pipelines/stacks/radiuss/spack.yaml @@ -18,11 +18,10 @@ spack: - blt - caliper #- care ## ~benchmarks ~examples ~tests - #- chai ## ~benchmarks ~examples ~tests + #- chai ## ~examples - conduit # ^hdf5+shared - flux-core #- flux-sched - #- glvis # ^mesa-glu@9.0.0 ^mesa18~llvm # same issue w/chai - hypre - lbann - lvarray ~tests # per Spack issue #23192 # ~examples diff --git a/share/spack/gitlab/cloud_pipelines/stacks/tutorial/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/tutorial/spack.yaml index c320442cbe0f84..9917841db5250b 100644 --- a/share/spack/gitlab/cloud_pipelines/stacks/tutorial/spack.yaml +++ b/share/spack/gitlab/cloud_pipelines/stacks/tutorial/spack.yaml @@ -23,6 +23,8 @@ spack: - lmod@8.7.18 - environment-modules - macsio@1.1+scr ^scr@2.0.0~fortran ^silo~fortran ^hdf5~fortran + - julia@1.9 ^llvm ~clang ~gold ~lldb ~lua ~polly compiler-rt=none libcxx=none libunwind=none targets=x86 ^openblas threads=openmp + - vim - ['%gcc@11'] - gcc_old_packages: - zlib-ng%gcc@10 diff --git a/share/spack/gitlab/cloud_pipelines/stacks/windows-vis/spack.yaml b/share/spack/gitlab/cloud_pipelines/stacks/windows-vis/spack.yaml new file mode 100644 index 00000000000000..498c054d8b3525 --- /dev/null +++ b/share/spack/gitlab/cloud_pipelines/stacks/windows-vis/spack.yaml @@ -0,0 +1,12 @@ +# Windows Visualization Stack +# maintainers: +# - John Parent (@johnwparent) +# - Ryan Krattiger (@kwryankrattiger) + +spack: + view: false + specs: + - vtk + + cdash: + build-group: Windows Visualization (Kitware) diff --git a/share/spack/gitlab/nersc_pipeline.yml b/share/spack/gitlab/nersc_pipeline.yml deleted file mode 100644 index 5edcb70c78ff51..00000000000000 --- a/share/spack/gitlab/nersc_pipeline.yml +++ /dev/null @@ -1,9 +0,0 @@ -merge_pipeline: - only: - - develop - variables: - SPACK_REPO: ${CI_PROJECT_URL} - SPACK_REF: ${CI_COMMIT_SHA} - trigger: - project: ecp/e4s/e4s - strategy: depend diff --git a/share/spack/qa/validate_last_exit.ps1 b/share/spack/qa/validate_last_exit.ps1 index c8a9f7f5be7912..565968b2b1d73f 100644 --- a/share/spack/qa/validate_last_exit.ps1 +++ b/share/spack/qa/validate_last_exit.ps1 @@ -1,3 +1,3 @@ if ($LASTEXITCODE -ne 0){ - throw "Unit Tests have failed" + throw "Tests have failed" } \ No newline at end of file diff --git a/share/spack/spack-completion.bash b/share/spack/spack-completion.bash index 90d17c5f484717..7a33021f4c4522 100755 --- a/share/spack/spack-completion.bash +++ b/share/spack/spack-completion.bash @@ -553,7 +553,7 @@ _spack_bootstrap_mirror() { _spack_build_env() { if $list_options then - SPACK_COMPREPLY="-h --help --clean --dirty -U --fresh --reuse --reuse-deps --deprecated --dump --pickle" + SPACK_COMPREPLY="-h --help --clean --dirty -U --fresh --reuse --fresh-roots --reuse-deps --deprecated --dump --pickle" else _all_packages fi @@ -564,14 +564,14 @@ _spack_buildcache() { then SPACK_COMPREPLY="-h --help" else - SPACK_COMPREPLY="push create install list keys preview check download get-buildcache-name save-specfile sync update-index rebuild-index" + SPACK_COMPREPLY="push create install list keys check download get-buildcache-name save-specfile sync update-index rebuild-index" fi } _spack_buildcache_push() { if $list_options then - SPACK_COMPREPLY="-h --help -f --force --allow-root -a --unsigned -u --signed --key -k --update-index --rebuild-index --spec-file --only --fail-fast --base-image --tag -t -j --jobs" + SPACK_COMPREPLY="-h --help -f --force --unsigned -u --signed --key -k --update-index --rebuild-index --spec-file --only --fail-fast --base-image --tag -t --private -j --jobs" else _mirrors fi @@ -580,7 +580,7 @@ _spack_buildcache_push() { _spack_buildcache_create() { if $list_options then - SPACK_COMPREPLY="-h --help -f --force --allow-root -a --unsigned -u --signed --key -k --update-index --rebuild-index --spec-file --only --fail-fast --base-image --tag -t -j --jobs" + SPACK_COMPREPLY="-h --help -f --force --unsigned -u --signed --key -k --update-index --rebuild-index --spec-file --only --fail-fast --base-image --tag -t --private -j --jobs" else _mirrors fi @@ -608,15 +608,6 @@ _spack_buildcache_keys() { SPACK_COMPREPLY="-h --help -i --install -t --trust -f --force" } -_spack_buildcache_preview() { - if $list_options - then - SPACK_COMPREPLY="-h --help" - else - _installed_packages - fi -} - _spack_buildcache_check() { if $list_options then @@ -812,11 +803,11 @@ _spack_compilers() { } _spack_concretize() { - SPACK_COMPREPLY="-h --help -f --force --test -q --quiet -U --fresh --reuse --reuse-deps --deprecated -j --jobs" + SPACK_COMPREPLY="-h --help -f --force --test -q --quiet -U --fresh --reuse --fresh-roots --reuse-deps --deprecated -j --jobs" } _spack_concretise() { - SPACK_COMPREPLY="-h --help -f --force --test -q --quiet -U --fresh --reuse --reuse-deps --deprecated -j --jobs" + SPACK_COMPREPLY="-h --help -f --force --test -q --quiet -U --fresh --reuse --fresh-roots --reuse-deps --deprecated -j --jobs" } _spack_config() { @@ -990,7 +981,7 @@ _spack_deprecate() { _spack_dev_build() { if $list_options then - SPACK_COMPREPLY="-h --help -j --jobs -n --no-checksum -d --source-path -i --ignore-dependencies --keep-prefix --skip-patch -q --quiet --drop-in --test -b --before -u --until --clean --dirty -U --fresh --reuse --reuse-deps --deprecated" + SPACK_COMPREPLY="-h --help -j --jobs -n --no-checksum -d --source-path -i --ignore-dependencies --keep-prefix --skip-patch -q --quiet --drop-in --test -b --before -u --until --clean --dirty -U --fresh --reuse --fresh-roots --reuse-deps --deprecated" else _all_packages fi @@ -1032,7 +1023,7 @@ _spack_env() { then SPACK_COMPREPLY="-h --help" else - SPACK_COMPREPLY="activate deactivate create remove rm list ls status st loads view update revert depfile" + SPACK_COMPREPLY="activate deactivate create remove rm rename mv list ls status st loads view update revert depfile" fi } @@ -1052,7 +1043,7 @@ _spack_env_deactivate() { _spack_env_create() { if $list_options then - SPACK_COMPREPLY="-h --help -d --dir --keep-relative --without-view --with-view" + SPACK_COMPREPLY="-h --help -d --dir --keep-relative --without-view --with-view --include-concrete" else _environments fi @@ -1061,7 +1052,7 @@ _spack_env_create() { _spack_env_remove() { if $list_options then - SPACK_COMPREPLY="-h --help -y --yes-to-all" + SPACK_COMPREPLY="-h --help -y --yes-to-all -f --force" else _environments fi @@ -1070,12 +1061,30 @@ _spack_env_remove() { _spack_env_rm() { if $list_options then - SPACK_COMPREPLY="-h --help -y --yes-to-all" + SPACK_COMPREPLY="-h --help -y --yes-to-all -f --force" else _environments fi } +_spack_env_rename() { + if $list_options + then + SPACK_COMPREPLY="-h --help -d --dir -f --force" + else + SPACK_COMPREPLY="" + fi +} + +_spack_env_mv() { + if $list_options + then + SPACK_COMPREPLY="-h --help -d --dir -f --force" + else + SPACK_COMPREPLY="" + fi +} + _spack_env_list() { SPACK_COMPREPLY="-h --help" } @@ -1170,7 +1179,7 @@ _spack_external_read_cray_manifest() { _spack_fetch() { if $list_options then - SPACK_COMPREPLY="-h --help -n --no-checksum -m --missing -D --dependencies -U --fresh --reuse --reuse-deps --deprecated" + SPACK_COMPREPLY="-h --help -n --no-checksum -m --missing -D --dependencies -U --fresh --reuse --fresh-roots --reuse-deps --deprecated" else _all_packages fi @@ -1179,7 +1188,7 @@ _spack_fetch() { _spack_find() { if $list_options then - SPACK_COMPREPLY="-h --help --format -H --hashes --json -d --deps -p --paths --groups --no-groups -l --long -L --very-long -t --tag -N --namespaces -c --show-concretized -f --show-flags --show-full-compiler -x --explicit -X --implicit -u --unknown -m --missing -v --variants --loaded -M --only-missing --deprecated --only-deprecated --start-date --end-date" + SPACK_COMPREPLY="-h --help --format -H --hashes --json -I --install-status -d --deps -p --paths --groups --no-groups -l --long -L --very-long -t --tag -N --namespaces -r --only-roots -c --show-concretized -f --show-flags --show-full-compiler -x --explicit -X --implicit -u --unknown -m --missing -v --variants --loaded -M --only-missing --deprecated --only-deprecated --install-tree --start-date --end-date" else _installed_packages fi @@ -1299,7 +1308,7 @@ _spack_info() { _spack_install() { if $list_options then - SPACK_COMPREPLY="-h --help --only -u --until -j --jobs --overwrite --fail-fast --keep-prefix --keep-stage --dont-restage --use-cache --no-cache --cache-only --use-buildcache --include-build-deps --no-check-signature --show-log-on-error --source -n --no-checksum -v --verbose --fake --only-concrete --add --no-add -f --file --clean --dirty --test --log-format --log-file --help-cdash --cdash-upload-url --cdash-build --cdash-site --cdash-track --cdash-buildstamp -y --yes-to-all -U --fresh --reuse --reuse-deps --deprecated" + SPACK_COMPREPLY="-h --help --only -u --until -j --jobs --overwrite --fail-fast --keep-prefix --keep-stage --dont-restage --use-cache --no-cache --cache-only --use-buildcache --include-build-deps --no-check-signature --show-log-on-error --source -n --no-checksum -v --verbose --fake --only-concrete --add --no-add -f --file --clean --dirty --test --log-format --log-file --help-cdash --cdash-upload-url --cdash-build --cdash-site --cdash-track --cdash-buildstamp -y --yes-to-all -U --fresh --reuse --fresh-roots --reuse-deps --deprecated" else _all_packages fi @@ -1338,7 +1347,7 @@ _spack_list() { _spack_load() { if $list_options then - SPACK_COMPREPLY="-h --help --sh --csh --fish --bat --pwsh --first --only --list" + SPACK_COMPREPLY="-h --help --sh --csh --fish --bat --pwsh --first --list" else _installed_packages fi @@ -1410,7 +1419,7 @@ _spack_mirror() { _spack_mirror_create() { if $list_options then - SPACK_COMPREPLY="-h --help -d --directory -a --all -f --file --exclude-file --exclude-specs --skip-unstable-versions -D --dependencies -n --versions-per-spec -U --fresh --reuse --reuse-deps --deprecated" + SPACK_COMPREPLY="-h --help -d --directory -a --all -f --file --exclude-file --exclude-specs --skip-unstable-versions -D --dependencies -n --versions-per-spec --private -U --fresh --reuse --fresh-roots --reuse-deps --deprecated" else _all_packages fi @@ -1423,7 +1432,7 @@ _spack_mirror_destroy() { _spack_mirror_add() { if $list_options then - SPACK_COMPREPLY="-h --help --scope --type --unsigned --signed --s3-access-key-id --s3-access-key-secret --s3-access-token --s3-profile --s3-endpoint-url --oci-username --oci-password" + SPACK_COMPREPLY="-h --help --scope --type --autopush --unsigned --signed --s3-access-key-id --s3-access-key-secret --s3-access-token --s3-profile --s3-endpoint-url --oci-username --oci-password" else _mirrors fi @@ -1459,7 +1468,7 @@ _spack_mirror_set_url() { _spack_mirror_set() { if $list_options then - SPACK_COMPREPLY="-h --help --push --fetch --type --url --unsigned --signed --scope --s3-access-key-id --s3-access-key-secret --s3-access-token --s3-profile --s3-endpoint-url --oci-username --oci-password" + SPACK_COMPREPLY="-h --help --push --fetch --type --url --autopush --no-autopush --unsigned --signed --scope --s3-access-key-id --s3-access-key-secret --s3-access-token --s3-profile --s3-endpoint-url --oci-username --oci-password" else _mirrors fi @@ -1589,7 +1598,7 @@ _spack_module_tcl_setdefault() { _spack_patch() { if $list_options then - SPACK_COMPREPLY="-h --help -n --no-checksum -U --fresh --reuse --reuse-deps --deprecated" + SPACK_COMPREPLY="-h --help -n --no-checksum -U --fresh --reuse --fresh-roots --reuse-deps --deprecated" else _all_packages fi @@ -1817,7 +1826,7 @@ _spack_restage() { _spack_solve() { if $list_options then - SPACK_COMPREPLY="-h --help --show -l --long -L --very-long -N --namespaces -I --install-status --no-install-status -y --yaml -j --json -c --cover -t --types --timers --stats -U --fresh --reuse --reuse-deps --deprecated" + SPACK_COMPREPLY="-h --help --show -l --long -L --very-long -N --namespaces -I --install-status --no-install-status -y --yaml -j --json -c --cover -t --types --timers --stats -U --fresh --reuse --fresh-roots --reuse-deps --deprecated" else _all_packages fi @@ -1826,7 +1835,7 @@ _spack_solve() { _spack_spec() { if $list_options then - SPACK_COMPREPLY="-h --help -l --long -L --very-long -N --namespaces -I --install-status --no-install-status -y --yaml -j --json --format -c --cover -t --types -U --fresh --reuse --reuse-deps --deprecated" + SPACK_COMPREPLY="-h --help -l --long -L --very-long -N --namespaces -I --install-status --no-install-status -y --yaml -j --json --format -c --cover -t --types -U --fresh --reuse --fresh-roots --reuse-deps --deprecated" else _all_packages fi @@ -1835,7 +1844,7 @@ _spack_spec() { _spack_stage() { if $list_options then - SPACK_COMPREPLY="-h --help -n --no-checksum -p --path -U --fresh --reuse --reuse-deps --deprecated" + SPACK_COMPREPLY="-h --help -n --no-checksum -p --path -U --fresh --reuse --fresh-roots --reuse-deps --deprecated" else _all_packages fi @@ -1925,7 +1934,7 @@ _spack_test_remove() { _spack_test_env() { if $list_options then - SPACK_COMPREPLY="-h --help --clean --dirty -U --fresh --reuse --reuse-deps --deprecated --dump --pickle" + SPACK_COMPREPLY="-h --help --clean --dirty -U --fresh --reuse --fresh-roots --reuse-deps --deprecated --dump --pickle" else _all_packages fi @@ -1956,7 +1965,7 @@ _spack_uninstall() { _spack_unit_test() { if $list_options then - SPACK_COMPREPLY="-h --help -H --pytest-help -l --list -L --list-long -N --list-names --extension -s -k --showlocals" + SPACK_COMPREPLY="-h --help -H --pytest-help -n --numprocesses -l --list -L --list-long -N --list-names --extension -s -k --showlocals" else _unit_tests fi diff --git a/share/spack/spack-completion.fish b/share/spack/spack-completion.fish index 84e1a4721e9b2c..a2ffebda7ca80c 100755 --- a/share/spack/spack-completion.fish +++ b/share/spack/spack-completion.fish @@ -438,7 +438,7 @@ complete -c spack -n '__fish_spack_using_command ' -l color -r -d 'when to color complete -c spack -n '__fish_spack_using_command ' -s c -l config -r -f -a config_vars complete -c spack -n '__fish_spack_using_command ' -s c -l config -r -d 'add one or more custom, one off config settings' complete -c spack -n '__fish_spack_using_command ' -s C -l config-scope -r -f -a config_scopes -complete -c spack -n '__fish_spack_using_command ' -s C -l config-scope -r -d 'add a custom configuration scope' +complete -c spack -n '__fish_spack_using_command ' -s C -l config-scope -r -d 'add directory or environment as read-only configuration scope, without activating the environment.' complete -c spack -n '__fish_spack_using_command ' -s d -l debug -f -a debug complete -c spack -n '__fish_spack_using_command ' -s d -l debug -d 'write out debug messages' complete -c spack -n '__fish_spack_using_command ' -l timestamp -f -a timestamp @@ -660,7 +660,7 @@ complete -c spack -n '__fish_spack_using_command bootstrap mirror' -l dev -f -a complete -c spack -n '__fish_spack_using_command bootstrap mirror' -l dev -d 'download dev dependencies too' # spack build-env -set -g __fish_spack_optspecs_spack_build_env h/help clean dirty U/fresh reuse reuse-deps deprecated dump= pickle= +set -g __fish_spack_optspecs_spack_build_env h/help clean dirty U/fresh reuse fresh-roots deprecated dump= pickle= complete -c spack -n '__fish_spack_using_command_pos_remainder 0 build-env' -f -a '(__fish_spack_build_env_spec)' complete -c spack -n '__fish_spack_using_command build-env' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command build-env' -s h -l help -d 'show this help message and exit' @@ -672,8 +672,8 @@ complete -c spack -n '__fish_spack_using_command build-env' -s U -l fresh -f -a complete -c spack -n '__fish_spack_using_command build-env' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command build-env' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command build-env' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command build-env' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command build-env' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command build-env' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command build-env' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command build-env' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command build-env' -l deprecated -d 'allow concretizer to select deprecated versions' complete -c spack -n '__fish_spack_using_command build-env' -l dump -r -f -a dump @@ -688,7 +688,6 @@ complete -c spack -n '__fish_spack_using_command_pos 0 buildcache' -f -a create complete -c spack -n '__fish_spack_using_command_pos 0 buildcache' -f -a install -d 'install from a binary package' complete -c spack -n '__fish_spack_using_command_pos 0 buildcache' -f -a list -d 'list binary packages available from mirrors' complete -c spack -n '__fish_spack_using_command_pos 0 buildcache' -f -a keys -d 'get public keys available on mirrors' -complete -c spack -n '__fish_spack_using_command_pos 0 buildcache' -f -a preview -d 'analyze an installed spec and reports whether executables and libraries are relocatable' complete -c spack -n '__fish_spack_using_command_pos 0 buildcache' -f -a check -d 'check specs against remote binary mirror(s) to see if any need to be rebuilt' complete -c spack -n '__fish_spack_using_command_pos 0 buildcache' -f -a download -d 'download buildcache entry from a remote mirror to local folder' complete -c spack -n '__fish_spack_using_command_pos 0 buildcache' -f -a get-buildcache-name -d 'get name (prefix) of buildcache entries for this spec' @@ -700,14 +699,12 @@ complete -c spack -n '__fish_spack_using_command buildcache' -s h -l help -f -a complete -c spack -n '__fish_spack_using_command buildcache' -s h -l help -d 'show this help message and exit' # spack buildcache push -set -g __fish_spack_optspecs_spack_buildcache_push h/help f/force a/allow-root u/unsigned signed k/key= update-index spec-file= only= fail-fast base-image= t/tag= j/jobs= +set -g __fish_spack_optspecs_spack_buildcache_push h/help f/force u/unsigned signed k/key= update-index spec-file= only= fail-fast base-image= t/tag= private j/jobs= complete -c spack -n '__fish_spack_using_command_pos_remainder 1 buildcache push' -f -k -a '(__fish_spack_specs)' complete -c spack -n '__fish_spack_using_command buildcache push' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command buildcache push' -s h -l help -d 'show this help message and exit' complete -c spack -n '__fish_spack_using_command buildcache push' -s f -l force -f -a force complete -c spack -n '__fish_spack_using_command buildcache push' -s f -l force -d 'overwrite tarball if it exists' -complete -c spack -n '__fish_spack_using_command buildcache push' -l allow-root -s a -f -a allow_root -complete -c spack -n '__fish_spack_using_command buildcache push' -l allow-root -s a -d 'allow install root string in binary files after RPATH substitution' complete -c spack -n '__fish_spack_using_command buildcache push' -l unsigned -s u -f -a signed complete -c spack -n '__fish_spack_using_command buildcache push' -l unsigned -s u -d 'push unsigned buildcache tarballs' complete -c spack -n '__fish_spack_using_command buildcache push' -l signed -f -a signed @@ -726,18 +723,18 @@ complete -c spack -n '__fish_spack_using_command buildcache push' -l base-image complete -c spack -n '__fish_spack_using_command buildcache push' -l base-image -r -d 'specify the base image for the buildcache' complete -c spack -n '__fish_spack_using_command buildcache push' -l tag -s t -r -f -a tag complete -c spack -n '__fish_spack_using_command buildcache push' -l tag -s t -r -d 'when pushing to an OCI registry, tag an image containing all root specs and their runtime dependencies' +complete -c spack -n '__fish_spack_using_command buildcache push' -l private -f -a private +complete -c spack -n '__fish_spack_using_command buildcache push' -l private -d 'for a private mirror, include non-redistributable packages' complete -c spack -n '__fish_spack_using_command buildcache push' -s j -l jobs -r -f -a jobs complete -c spack -n '__fish_spack_using_command buildcache push' -s j -l jobs -r -d 'explicitly set number of parallel jobs' # spack buildcache create -set -g __fish_spack_optspecs_spack_buildcache_create h/help f/force a/allow-root u/unsigned signed k/key= update-index spec-file= only= fail-fast base-image= t/tag= j/jobs= +set -g __fish_spack_optspecs_spack_buildcache_create h/help f/force u/unsigned signed k/key= update-index spec-file= only= fail-fast base-image= t/tag= private j/jobs= complete -c spack -n '__fish_spack_using_command_pos_remainder 1 buildcache create' -f -k -a '(__fish_spack_specs)' complete -c spack -n '__fish_spack_using_command buildcache create' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command buildcache create' -s h -l help -d 'show this help message and exit' complete -c spack -n '__fish_spack_using_command buildcache create' -s f -l force -f -a force complete -c spack -n '__fish_spack_using_command buildcache create' -s f -l force -d 'overwrite tarball if it exists' -complete -c spack -n '__fish_spack_using_command buildcache create' -l allow-root -s a -f -a allow_root -complete -c spack -n '__fish_spack_using_command buildcache create' -l allow-root -s a -d 'allow install root string in binary files after RPATH substitution' complete -c spack -n '__fish_spack_using_command buildcache create' -l unsigned -s u -f -a signed complete -c spack -n '__fish_spack_using_command buildcache create' -l unsigned -s u -d 'push unsigned buildcache tarballs' complete -c spack -n '__fish_spack_using_command buildcache create' -l signed -f -a signed @@ -756,6 +753,8 @@ complete -c spack -n '__fish_spack_using_command buildcache create' -l base-imag complete -c spack -n '__fish_spack_using_command buildcache create' -l base-image -r -d 'specify the base image for the buildcache' complete -c spack -n '__fish_spack_using_command buildcache create' -l tag -s t -r -f -a tag complete -c spack -n '__fish_spack_using_command buildcache create' -l tag -s t -r -d 'when pushing to an OCI registry, tag an image containing all root specs and their runtime dependencies' +complete -c spack -n '__fish_spack_using_command buildcache create' -l private -f -a private +complete -c spack -n '__fish_spack_using_command buildcache create' -l private -d 'for a private mirror, include non-redistributable packages' complete -c spack -n '__fish_spack_using_command buildcache create' -s j -l jobs -r -f -a jobs complete -c spack -n '__fish_spack_using_command buildcache create' -s j -l jobs -r -d 'explicitly set number of parallel jobs' @@ -800,12 +799,6 @@ complete -c spack -n '__fish_spack_using_command buildcache keys' -s t -l trust complete -c spack -n '__fish_spack_using_command buildcache keys' -s f -l force -f -a force complete -c spack -n '__fish_spack_using_command buildcache keys' -s f -l force -d 'force new download of keys' -# spack buildcache preview -set -g __fish_spack_optspecs_spack_buildcache_preview h/help -complete -c spack -n '__fish_spack_using_command_pos_remainder 0 buildcache preview' -f -a '(__fish_spack_installed_specs)' -complete -c spack -n '__fish_spack_using_command buildcache preview' -s h -l help -f -a help -complete -c spack -n '__fish_spack_using_command buildcache preview' -s h -l help -d 'show this help message and exit' - # spack buildcache check set -g __fish_spack_optspecs_spack_buildcache_check h/help m/mirror-url= o/output-file= scope= s/spec= spec-file= complete -c spack -n '__fish_spack_using_command_pos_remainder 0 buildcache check' -f -k -a '(__fish_spack_specs)' @@ -861,7 +854,7 @@ set -g __fish_spack_optspecs_spack_buildcache_sync h/help manifest-glob= complete -c spack -n '__fish_spack_using_command buildcache sync' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command buildcache sync' -s h -l help -d 'show this help message and exit' complete -c spack -n '__fish_spack_using_command buildcache sync' -l manifest-glob -r -f -a manifest_glob -complete -c spack -n '__fish_spack_using_command buildcache sync' -l manifest-glob -r -d 'a quoted glob pattern identifying copy manifest files' +complete -c spack -n '__fish_spack_using_command buildcache sync' -l manifest-glob -r -d 'a quoted glob pattern identifying CI rebuild manifest files' # spack buildcache update-index set -g __fish_spack_optspecs_spack_buildcache_update_index h/help k/keys @@ -958,9 +951,9 @@ complete -c spack -n '__fish_spack_using_command ci generate' -l output-file -r complete -c spack -n '__fish_spack_using_command ci generate' -l copy-to -r -f -a copy_to complete -c spack -n '__fish_spack_using_command ci generate' -l copy-to -r -d 'path to additional directory for job files' complete -c spack -n '__fish_spack_using_command ci generate' -l optimize -f -a optimize -complete -c spack -n '__fish_spack_using_command ci generate' -l optimize -d '(experimental) optimize the gitlab yaml file for size' +complete -c spack -n '__fish_spack_using_command ci generate' -l optimize -d '(DEPRECATED) optimize the gitlab yaml file for size' complete -c spack -n '__fish_spack_using_command ci generate' -l dependencies -f -a dependencies -complete -c spack -n '__fish_spack_using_command ci generate' -l dependencies -d '(experimental) disable DAG scheduling (use \'plain\' dependencies)' +complete -c spack -n '__fish_spack_using_command ci generate' -l dependencies -d '(DEPRECATED) disable DAG scheduling (use \'plain\' dependencies)' complete -c spack -n '__fish_spack_using_command ci generate' -l buildcache-destination -r -f -a buildcache_destination complete -c spack -n '__fish_spack_using_command ci generate' -l buildcache-destination -r -d 'override the mirror configured in the environment' complete -c spack -n '__fish_spack_using_command ci generate' -l prune-dag -f -a prune_dag @@ -1124,7 +1117,7 @@ complete -c spack -n '__fish_spack_using_command compilers' -l scope -r -f -a '_ complete -c spack -n '__fish_spack_using_command compilers' -l scope -r -d 'configuration scope to read/modify' # spack concretize -set -g __fish_spack_optspecs_spack_concretize h/help f/force test= q/quiet U/fresh reuse reuse-deps deprecated j/jobs= +set -g __fish_spack_optspecs_spack_concretize h/help f/force test= q/quiet U/fresh reuse fresh-roots deprecated j/jobs= complete -c spack -n '__fish_spack_using_command concretize' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command concretize' -s h -l help -d 'show this help message and exit' complete -c spack -n '__fish_spack_using_command concretize' -s f -l force -f -a force @@ -1137,15 +1130,15 @@ complete -c spack -n '__fish_spack_using_command concretize' -s U -l fresh -f -a complete -c spack -n '__fish_spack_using_command concretize' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command concretize' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command concretize' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command concretize' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command concretize' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command concretize' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command concretize' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command concretize' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command concretize' -l deprecated -d 'allow concretizer to select deprecated versions' complete -c spack -n '__fish_spack_using_command concretize' -s j -l jobs -r -f -a jobs complete -c spack -n '__fish_spack_using_command concretize' -s j -l jobs -r -d 'explicitly set number of parallel jobs' # spack concretise -set -g __fish_spack_optspecs_spack_concretise h/help f/force test= q/quiet U/fresh reuse reuse-deps deprecated j/jobs= +set -g __fish_spack_optspecs_spack_concretise h/help f/force test= q/quiet U/fresh reuse fresh-roots deprecated j/jobs= complete -c spack -n '__fish_spack_using_command concretise' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command concretise' -s h -l help -d 'show this help message and exit' complete -c spack -n '__fish_spack_using_command concretise' -s f -l force -f -a force @@ -1158,8 +1151,8 @@ complete -c spack -n '__fish_spack_using_command concretise' -s U -l fresh -f -a complete -c spack -n '__fish_spack_using_command concretise' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command concretise' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command concretise' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command concretise' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command concretise' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command concretise' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command concretise' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command concretise' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command concretise' -l deprecated -d 'allow concretizer to select deprecated versions' complete -c spack -n '__fish_spack_using_command concretise' -s j -l jobs -r -f -a jobs @@ -1371,7 +1364,7 @@ complete -c spack -n '__fish_spack_using_command deprecate' -s l -l link-type -r complete -c spack -n '__fish_spack_using_command deprecate' -s l -l link-type -r -d 'type of filesystem link to use for deprecation (default soft)' # spack dev-build -set -g __fish_spack_optspecs_spack_dev_build h/help j/jobs= n/no-checksum d/source-path= i/ignore-dependencies keep-prefix skip-patch q/quiet drop-in= test= b/before= u/until= clean dirty U/fresh reuse reuse-deps deprecated +set -g __fish_spack_optspecs_spack_dev_build h/help j/jobs= n/no-checksum d/source-path= i/ignore-dependencies keep-prefix skip-patch q/quiet drop-in= test= b/before= u/until= clean dirty U/fresh reuse fresh-roots deprecated complete -c spack -n '__fish_spack_using_command_pos_remainder 0 dev-build' -f -k -a '(__fish_spack_specs)' complete -c spack -n '__fish_spack_using_command dev-build' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command dev-build' -s h -l help -d 'show this help message and exit' @@ -1405,8 +1398,8 @@ complete -c spack -n '__fish_spack_using_command dev-build' -s U -l fresh -f -a complete -c spack -n '__fish_spack_using_command dev-build' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command dev-build' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command dev-build' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command dev-build' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command dev-build' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command dev-build' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command dev-build' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command dev-build' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command dev-build' -l deprecated -d 'allow concretizer to select deprecated versions' @@ -1447,7 +1440,7 @@ complete -c spack -n '__fish_spack_using_command docs' -s h -l help -d 'show thi # spack edit set -g __fish_spack_optspecs_spack_edit h/help b/build-system c/command d/docs t/test m/module r/repo= N/namespace= -complete -c spack -n '__fish_spack_using_command_pos 0 edit' -f -a '(__fish_spack_packages)' +complete -c spack -n '__fish_spack_using_command_pos_remainder 0 edit' -f -a '(__fish_spack_packages)' complete -c spack -n '__fish_spack_using_command edit' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command edit' -s h -l help -d 'show this help message and exit' complete -c spack -n '__fish_spack_using_command edit' -s b -l build-system -f -a path @@ -1472,8 +1465,10 @@ complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a deactivate -d complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a create -d 'create a new environment' complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a remove -d 'remove an existing environment' complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a rm -d 'remove an existing environment' -complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a list -d 'list available environments' -complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a ls -d 'list available environments' +complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a rename -d 'rename an existing environment' +complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a mv -d 'rename an existing environment' +complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a list -d 'list managed environments' +complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a ls -d 'list managed environments' complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a status -d 'print whether there is an active environment' complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a st -d 'print whether there is an active environment' complete -c spack -n '__fish_spack_using_command_pos 0 env' -f -a loads -d 'list modules for an installed environment \'(see spack module loads)\'' @@ -1532,7 +1527,7 @@ complete -c spack -n '__fish_spack_using_command env deactivate' -l pwsh -f -a s complete -c spack -n '__fish_spack_using_command env deactivate' -l pwsh -d 'print pwsh commands to activate the environment' # spack env create -set -g __fish_spack_optspecs_spack_env_create h/help d/dir keep-relative without-view with-view= +set -g __fish_spack_optspecs_spack_env_create h/help d/dir keep-relative without-view with-view= include-concrete= complete -c spack -n '__fish_spack_using_command_pos 0 env create' -f -a '(__fish_spack_environments)' complete -c spack -n '__fish_spack_using_command env create' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command env create' -s h -l help -d 'show this help message and exit' @@ -1544,22 +1539,48 @@ complete -c spack -n '__fish_spack_using_command env create' -l without-view -f complete -c spack -n '__fish_spack_using_command env create' -l without-view -d 'do not maintain a view for this environment' complete -c spack -n '__fish_spack_using_command env create' -l with-view -r -f -a with_view complete -c spack -n '__fish_spack_using_command env create' -l with-view -r -d 'specify that this environment should maintain a view at the specified path (by default the view is maintained in the environment directory)' +complete -c spack -n '__fish_spack_using_command env create' -l include-concrete -r -f -a include_concrete +complete -c spack -n '__fish_spack_using_command env create' -l include-concrete -r -d 'name of old environment to copy specs from' # spack env remove -set -g __fish_spack_optspecs_spack_env_remove h/help y/yes-to-all +set -g __fish_spack_optspecs_spack_env_remove h/help y/yes-to-all f/force complete -c spack -n '__fish_spack_using_command_pos_remainder 0 env remove' -f -a '(__fish_spack_environments)' complete -c spack -n '__fish_spack_using_command env remove' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command env remove' -s h -l help -d 'show this help message and exit' complete -c spack -n '__fish_spack_using_command env remove' -s y -l yes-to-all -f -a yes_to_all complete -c spack -n '__fish_spack_using_command env remove' -s y -l yes-to-all -d 'assume "yes" is the answer to every confirmation request' +complete -c spack -n '__fish_spack_using_command env remove' -s f -l force -f -a force +complete -c spack -n '__fish_spack_using_command env remove' -s f -l force -d 'remove the environment even if it is included in another environment' # spack env rm -set -g __fish_spack_optspecs_spack_env_rm h/help y/yes-to-all +set -g __fish_spack_optspecs_spack_env_rm h/help y/yes-to-all f/force complete -c spack -n '__fish_spack_using_command_pos_remainder 0 env rm' -f -a '(__fish_spack_environments)' complete -c spack -n '__fish_spack_using_command env rm' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command env rm' -s h -l help -d 'show this help message and exit' complete -c spack -n '__fish_spack_using_command env rm' -s y -l yes-to-all -f -a yes_to_all complete -c spack -n '__fish_spack_using_command env rm' -s y -l yes-to-all -d 'assume "yes" is the answer to every confirmation request' +complete -c spack -n '__fish_spack_using_command env rm' -s f -l force -f -a force +complete -c spack -n '__fish_spack_using_command env rm' -s f -l force -d 'remove the environment even if it is included in another environment' + +# spack env rename +set -g __fish_spack_optspecs_spack_env_rename h/help d/dir f/force + +complete -c spack -n '__fish_spack_using_command env rename' -s h -l help -f -a help +complete -c spack -n '__fish_spack_using_command env rename' -s h -l help -d 'show this help message and exit' +complete -c spack -n '__fish_spack_using_command env rename' -s d -l dir -f -a dir +complete -c spack -n '__fish_spack_using_command env rename' -s d -l dir -d 'the specified arguments correspond to directory paths' +complete -c spack -n '__fish_spack_using_command env rename' -s f -l force -f -a force +complete -c spack -n '__fish_spack_using_command env rename' -s f -l force -d 'allow overwriting of an existing environment' + +# spack env mv +set -g __fish_spack_optspecs_spack_env_mv h/help d/dir f/force + +complete -c spack -n '__fish_spack_using_command env mv' -s h -l help -f -a help +complete -c spack -n '__fish_spack_using_command env mv' -s h -l help -d 'show this help message and exit' +complete -c spack -n '__fish_spack_using_command env mv' -s d -l dir -f -a dir +complete -c spack -n '__fish_spack_using_command env mv' -s d -l dir -d 'the specified arguments correspond to directory paths' +complete -c spack -n '__fish_spack_using_command env mv' -s f -l force -f -a force +complete -c spack -n '__fish_spack_using_command env mv' -s f -l force -d 'allow overwriting of an existing environment' # spack env list set -g __fish_spack_optspecs_spack_env_list h/help @@ -1701,7 +1722,7 @@ complete -c spack -n '__fish_spack_using_command external read-cray-manifest' -l complete -c spack -n '__fish_spack_using_command external read-cray-manifest' -l fail-on-error -d 'if a manifest file cannot be parsed, fail and report the full stack trace' # spack fetch -set -g __fish_spack_optspecs_spack_fetch h/help n/no-checksum m/missing D/dependencies U/fresh reuse reuse-deps deprecated +set -g __fish_spack_optspecs_spack_fetch h/help n/no-checksum m/missing D/dependencies U/fresh reuse fresh-roots deprecated complete -c spack -n '__fish_spack_using_command_pos_remainder 0 fetch' -f -k -a '(__fish_spack_specs)' complete -c spack -n '__fish_spack_using_command fetch' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command fetch' -s h -l help -d 'show this help message and exit' @@ -1715,13 +1736,13 @@ complete -c spack -n '__fish_spack_using_command fetch' -s U -l fresh -f -a conc complete -c spack -n '__fish_spack_using_command fetch' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command fetch' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command fetch' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command fetch' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command fetch' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command fetch' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command fetch' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command fetch' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command fetch' -l deprecated -d 'allow concretizer to select deprecated versions' # spack find -set -g __fish_spack_optspecs_spack_find h/help format= H/hashes json d/deps p/paths groups no-groups l/long L/very-long t/tag= N/namespaces c/show-concretized f/show-flags show-full-compiler x/explicit X/implicit u/unknown m/missing v/variants loaded M/only-missing deprecated only-deprecated start-date= end-date= +set -g __fish_spack_optspecs_spack_find h/help format= H/hashes json I/install-status d/deps p/paths groups no-groups l/long L/very-long t/tag= N/namespaces r/only-roots c/show-concretized f/show-flags show-full-compiler x/explicit X/implicit u/unknown m/missing v/variants loaded M/only-missing deprecated only-deprecated install-tree= start-date= end-date= complete -c spack -n '__fish_spack_using_command_pos_remainder 0 find' -f -a '(__fish_spack_installed_specs)' complete -c spack -n '__fish_spack_using_command find' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command find' -s h -l help -d 'show this help message and exit' @@ -1731,6 +1752,8 @@ complete -c spack -n '__fish_spack_using_command find' -s H -l hashes -f -a form complete -c spack -n '__fish_spack_using_command find' -s H -l hashes -d 'same as \'--format {/hash}\'; use with xargs or $()' complete -c spack -n '__fish_spack_using_command find' -l json -f -a json complete -c spack -n '__fish_spack_using_command find' -l json -d 'output specs as machine-readable json records' +complete -c spack -n '__fish_spack_using_command find' -s I -l install-status -f -a install_status +complete -c spack -n '__fish_spack_using_command find' -s I -l install-status -d 'show install status of packages' complete -c spack -n '__fish_spack_using_command find' -s d -l deps -f -a deps complete -c spack -n '__fish_spack_using_command find' -s d -l deps -d 'output dependencies along with found specs' complete -c spack -n '__fish_spack_using_command find' -s p -l paths -f -a paths @@ -1747,6 +1770,8 @@ complete -c spack -n '__fish_spack_using_command find' -s t -l tag -r -f -a tags complete -c spack -n '__fish_spack_using_command find' -s t -l tag -r -d 'filter a package query by tag (multiple use allowed)' complete -c spack -n '__fish_spack_using_command find' -s N -l namespaces -f -a namespaces complete -c spack -n '__fish_spack_using_command find' -s N -l namespaces -d 'show fully qualified package names' +complete -c spack -n '__fish_spack_using_command find' -s r -l only-roots -f -a only_roots +complete -c spack -n '__fish_spack_using_command find' -s r -l only-roots -d 'don\'t show full list of installed specs in an environment' complete -c spack -n '__fish_spack_using_command find' -s c -l show-concretized -f -a show_concretized complete -c spack -n '__fish_spack_using_command find' -s c -l show-concretized -d 'show concretized specs in an environment' complete -c spack -n '__fish_spack_using_command find' -s f -l show-flags -f -a show_flags @@ -1771,6 +1796,8 @@ complete -c spack -n '__fish_spack_using_command find' -l deprecated -f -a depre complete -c spack -n '__fish_spack_using_command find' -l deprecated -d 'show deprecated packages as well as installed specs' complete -c spack -n '__fish_spack_using_command find' -l only-deprecated -f -a only_deprecated complete -c spack -n '__fish_spack_using_command find' -l only-deprecated -d 'show only deprecated packages' +complete -c spack -n '__fish_spack_using_command find' -l install-tree -r -f -a install_tree +complete -c spack -n '__fish_spack_using_command find' -l install-tree -r -d 'Install trees to query: \'all\' (default), \'local\', \'upstream\', upstream name or path' complete -c spack -n '__fish_spack_using_command find' -l start-date -r -f -a start_date complete -c spack -n '__fish_spack_using_command find' -l start-date -r -d 'earliest date of installation [YYYY-MM-DD]' complete -c spack -n '__fish_spack_using_command find' -l end-date -r -f -a end_date @@ -1943,7 +1970,7 @@ complete -c spack -n '__fish_spack_using_command info' -l variants-by-name -f -a complete -c spack -n '__fish_spack_using_command info' -l variants-by-name -d 'list variants in strict name order; don\'t group by condition' # spack install -set -g __fish_spack_optspecs_spack_install h/help only= u/until= j/jobs= overwrite fail-fast keep-prefix keep-stage dont-restage use-cache no-cache cache-only use-buildcache= include-build-deps no-check-signature show-log-on-error source n/no-checksum v/verbose fake only-concrete add no-add f/file= clean dirty test= log-format= log-file= help-cdash cdash-upload-url= cdash-build= cdash-site= cdash-track= cdash-buildstamp= y/yes-to-all U/fresh reuse reuse-deps deprecated +set -g __fish_spack_optspecs_spack_install h/help only= u/until= j/jobs= overwrite fail-fast keep-prefix keep-stage dont-restage use-cache no-cache cache-only use-buildcache= include-build-deps no-check-signature show-log-on-error source n/no-checksum v/verbose fake only-concrete add no-add f/file= clean dirty test= log-format= log-file= help-cdash cdash-upload-url= cdash-build= cdash-site= cdash-track= cdash-buildstamp= y/yes-to-all U/fresh reuse fresh-roots deprecated complete -c spack -n '__fish_spack_using_command_pos_remainder 0 install' -f -k -a '(__fish_spack_specs)' complete -c spack -n '__fish_spack_using_command install' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command install' -s h -l help -d 'show this help message and exit' @@ -2016,8 +2043,8 @@ complete -c spack -n '__fish_spack_using_command install' -s U -l fresh -f -a co complete -c spack -n '__fish_spack_using_command install' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command install' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command install' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command install' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command install' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command install' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command install' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command install' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command install' -l deprecated -d 'allow concretizer to select deprecated versions' @@ -2067,7 +2094,7 @@ complete -c spack -n '__fish_spack_using_command list' -l update -r -f -a update complete -c spack -n '__fish_spack_using_command list' -l update -r -d 'write output to the specified file, if any package is newer' # spack load -set -g __fish_spack_optspecs_spack_load h/help sh csh fish bat pwsh first only= list +set -g __fish_spack_optspecs_spack_load h/help sh csh fish bat pwsh first list complete -c spack -n '__fish_spack_using_command_pos_remainder 0 load' -f -a '(__fish_spack_installed_specs)' complete -c spack -n '__fish_spack_using_command load' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command load' -s h -l help -d 'show this help message and exit' @@ -2083,8 +2110,6 @@ complete -c spack -n '__fish_spack_using_command load' -l pwsh -f -a shell complete -c spack -n '__fish_spack_using_command load' -l pwsh -d 'print pwsh commands to load the package' complete -c spack -n '__fish_spack_using_command load' -l first -f -a load_first complete -c spack -n '__fish_spack_using_command load' -l first -d 'load the first match if multiple packages match the spec' -complete -c spack -n '__fish_spack_using_command load' -l only -r -f -a 'package dependencies' -complete -c spack -n '__fish_spack_using_command load' -l only -r -d 'select whether to load the package and its dependencies' complete -c spack -n '__fish_spack_using_command load' -l list -f -a list complete -c spack -n '__fish_spack_using_command load' -l list -d 'show loaded packages: same as `spack find --loaded`' @@ -2192,7 +2217,7 @@ complete -c spack -n '__fish_spack_using_command mirror' -s n -l no-checksum -f complete -c spack -n '__fish_spack_using_command mirror' -s n -l no-checksum -d 'do not use checksums to verify downloaded files (unsafe)' # spack mirror create -set -g __fish_spack_optspecs_spack_mirror_create h/help d/directory= a/all f/file= exclude-file= exclude-specs= skip-unstable-versions D/dependencies n/versions-per-spec= U/fresh reuse reuse-deps deprecated +set -g __fish_spack_optspecs_spack_mirror_create h/help d/directory= a/all f/file= exclude-file= exclude-specs= skip-unstable-versions D/dependencies n/versions-per-spec= private U/fresh reuse fresh-roots deprecated complete -c spack -n '__fish_spack_using_command_pos_remainder 0 mirror create' -f -k -a '(__fish_spack_specs)' complete -c spack -n '__fish_spack_using_command mirror create' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command mirror create' -s h -l help -d 'show this help message and exit' @@ -2212,12 +2237,14 @@ complete -c spack -n '__fish_spack_using_command mirror create' -s D -l dependen complete -c spack -n '__fish_spack_using_command mirror create' -s D -l dependencies -d 'also fetch all dependencies' complete -c spack -n '__fish_spack_using_command mirror create' -s n -l versions-per-spec -r -f -a versions_per_spec complete -c spack -n '__fish_spack_using_command mirror create' -s n -l versions-per-spec -r -d 'the number of versions to fetch for each spec, choose \'all\' to retrieve all versions of each package' +complete -c spack -n '__fish_spack_using_command mirror create' -l private -f -a private +complete -c spack -n '__fish_spack_using_command mirror create' -l private -d 'for a private mirror, include non-redistributable packages' complete -c spack -n '__fish_spack_using_command mirror create' -s U -l fresh -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command mirror create' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command mirror create' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command mirror create' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command mirror create' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command mirror create' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command mirror create' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command mirror create' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command mirror create' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command mirror create' -l deprecated -d 'allow concretizer to select deprecated versions' @@ -2231,7 +2258,7 @@ complete -c spack -n '__fish_spack_using_command mirror destroy' -l mirror-url - complete -c spack -n '__fish_spack_using_command mirror destroy' -l mirror-url -r -d 'find mirror to destroy by url' # spack mirror add -set -g __fish_spack_optspecs_spack_mirror_add h/help scope= type= unsigned signed s3-access-key-id= s3-access-key-secret= s3-access-token= s3-profile= s3-endpoint-url= oci-username= oci-password= +set -g __fish_spack_optspecs_spack_mirror_add h/help scope= type= autopush unsigned signed s3-access-key-id= s3-access-key-secret= s3-access-token= s3-profile= s3-endpoint-url= oci-username= oci-password= complete -c spack -n '__fish_spack_using_command_pos 0 mirror add' -f complete -c spack -n '__fish_spack_using_command mirror add' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command mirror add' -s h -l help -d 'show this help message and exit' @@ -2239,6 +2266,8 @@ complete -c spack -n '__fish_spack_using_command mirror add' -l scope -r -f -a ' complete -c spack -n '__fish_spack_using_command mirror add' -l scope -r -d 'configuration scope to modify' complete -c spack -n '__fish_spack_using_command mirror add' -l type -r -f -a 'binary source' complete -c spack -n '__fish_spack_using_command mirror add' -l type -r -d 'specify the mirror type: for both binary and source use `--type binary --type source` (default)' +complete -c spack -n '__fish_spack_using_command mirror add' -l autopush -f -a autopush +complete -c spack -n '__fish_spack_using_command mirror add' -l autopush -d 'set mirror to push automatically after installation' complete -c spack -n '__fish_spack_using_command mirror add' -l unsigned -f -a signed complete -c spack -n '__fish_spack_using_command mirror add' -l unsigned -d 'do not require signing and signature verification when pushing and installing from this build cache' complete -c spack -n '__fish_spack_using_command mirror add' -l signed -f -a signed @@ -2301,7 +2330,7 @@ complete -c spack -n '__fish_spack_using_command mirror set-url' -l oci-password complete -c spack -n '__fish_spack_using_command mirror set-url' -l oci-password -r -d 'password to use to connect to this OCI mirror' # spack mirror set -set -g __fish_spack_optspecs_spack_mirror_set h/help push fetch type= url= unsigned signed scope= s3-access-key-id= s3-access-key-secret= s3-access-token= s3-profile= s3-endpoint-url= oci-username= oci-password= +set -g __fish_spack_optspecs_spack_mirror_set h/help push fetch type= url= autopush no-autopush unsigned signed scope= s3-access-key-id= s3-access-key-secret= s3-access-token= s3-profile= s3-endpoint-url= oci-username= oci-password= complete -c spack -n '__fish_spack_using_command_pos 0 mirror set' -f -a '(__fish_spack_mirrors)' complete -c spack -n '__fish_spack_using_command mirror set' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command mirror set' -s h -l help -d 'show this help message and exit' @@ -2313,6 +2342,10 @@ complete -c spack -n '__fish_spack_using_command mirror set' -l type -r -f -a 'b complete -c spack -n '__fish_spack_using_command mirror set' -l type -r -d 'specify the mirror type: for both binary and source use `--type binary --type source`' complete -c spack -n '__fish_spack_using_command mirror set' -l url -r -f -a url complete -c spack -n '__fish_spack_using_command mirror set' -l url -r -d 'url of mirror directory from \'spack mirror create\'' +complete -c spack -n '__fish_spack_using_command mirror set' -l autopush -f -a autopush +complete -c spack -n '__fish_spack_using_command mirror set' -l autopush -d 'set mirror to push automatically after installation' +complete -c spack -n '__fish_spack_using_command mirror set' -l no-autopush -f -a autopush +complete -c spack -n '__fish_spack_using_command mirror set' -l no-autopush -d 'set mirror to not push automatically after installation' complete -c spack -n '__fish_spack_using_command mirror set' -l unsigned -f -a signed complete -c spack -n '__fish_spack_using_command mirror set' -l unsigned -d 'do not require signing and signature verification when pushing and installing from this build cache' complete -c spack -n '__fish_spack_using_command mirror set' -l signed -f -a signed @@ -2473,7 +2506,7 @@ complete -c spack -n '__fish_spack_using_command module tcl setdefault' -s h -l complete -c spack -n '__fish_spack_using_command module tcl setdefault' -s h -l help -d 'show this help message and exit' # spack patch -set -g __fish_spack_optspecs_spack_patch h/help n/no-checksum U/fresh reuse reuse-deps deprecated +set -g __fish_spack_optspecs_spack_patch h/help n/no-checksum U/fresh reuse fresh-roots deprecated complete -c spack -n '__fish_spack_using_command_pos_remainder 0 patch' -f -k -a '(__fish_spack_specs)' complete -c spack -n '__fish_spack_using_command patch' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command patch' -s h -l help -d 'show this help message and exit' @@ -2483,8 +2516,8 @@ complete -c spack -n '__fish_spack_using_command patch' -s U -l fresh -f -a conc complete -c spack -n '__fish_spack_using_command patch' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command patch' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command patch' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command patch' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command patch' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command patch' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command patch' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command patch' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command patch' -l deprecated -d 'allow concretizer to select deprecated versions' @@ -2699,7 +2732,7 @@ complete -c spack -n '__fish_spack_using_command restage' -s h -l help -f -a hel complete -c spack -n '__fish_spack_using_command restage' -s h -l help -d 'show this help message and exit' # spack solve -set -g __fish_spack_optspecs_spack_solve h/help show= l/long L/very-long N/namespaces I/install-status no-install-status y/yaml j/json c/cover= t/types timers stats U/fresh reuse reuse-deps deprecated +set -g __fish_spack_optspecs_spack_solve h/help show= l/long L/very-long N/namespaces I/install-status no-install-status y/yaml j/json c/cover= t/types timers stats U/fresh reuse fresh-roots deprecated complete -c spack -n '__fish_spack_using_command_pos_remainder 0 solve' -f -k -a '(__fish_spack_specs_or_id)' complete -c spack -n '__fish_spack_using_command solve' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command solve' -s h -l help -d 'show this help message and exit' @@ -2731,13 +2764,13 @@ complete -c spack -n '__fish_spack_using_command solve' -s U -l fresh -f -a conc complete -c spack -n '__fish_spack_using_command solve' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command solve' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command solve' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command solve' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command solve' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command solve' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command solve' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command solve' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command solve' -l deprecated -d 'allow concretizer to select deprecated versions' # spack spec -set -g __fish_spack_optspecs_spack_spec h/help l/long L/very-long N/namespaces I/install-status no-install-status y/yaml j/json format= c/cover= t/types U/fresh reuse reuse-deps deprecated +set -g __fish_spack_optspecs_spack_spec h/help l/long L/very-long N/namespaces I/install-status no-install-status y/yaml j/json format= c/cover= t/types U/fresh reuse fresh-roots deprecated complete -c spack -n '__fish_spack_using_command_pos_remainder 0 spec' -f -k -a '(__fish_spack_specs_or_id)' complete -c spack -n '__fish_spack_using_command spec' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command spec' -s h -l help -d 'show this help message and exit' @@ -2765,13 +2798,13 @@ complete -c spack -n '__fish_spack_using_command spec' -s U -l fresh -f -a concr complete -c spack -n '__fish_spack_using_command spec' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command spec' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command spec' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command spec' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command spec' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command spec' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command spec' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command spec' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command spec' -l deprecated -d 'allow concretizer to select deprecated versions' # spack stage -set -g __fish_spack_optspecs_spack_stage h/help n/no-checksum p/path= U/fresh reuse reuse-deps deprecated +set -g __fish_spack_optspecs_spack_stage h/help n/no-checksum p/path= U/fresh reuse fresh-roots deprecated complete -c spack -n '__fish_spack_using_command_pos_remainder 0 stage' -f -k -a '(__fish_spack_specs_or_id)' complete -c spack -n '__fish_spack_using_command stage' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command stage' -s h -l help -d 'show this help message and exit' @@ -2783,8 +2816,8 @@ complete -c spack -n '__fish_spack_using_command stage' -s U -l fresh -f -a conc complete -c spack -n '__fish_spack_using_command stage' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command stage' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command stage' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command stage' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command stage' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command stage' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command stage' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command stage' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command stage' -l deprecated -d 'allow concretizer to select deprecated versions' @@ -2903,7 +2936,7 @@ complete -c spack -n '__fish_spack_using_command test remove' -s y -l yes-to-all complete -c spack -n '__fish_spack_using_command test remove' -s y -l yes-to-all -d 'assume "yes" is the answer to every confirmation request' # spack test-env -set -g __fish_spack_optspecs_spack_test_env h/help clean dirty U/fresh reuse reuse-deps deprecated dump= pickle= +set -g __fish_spack_optspecs_spack_test_env h/help clean dirty U/fresh reuse fresh-roots deprecated dump= pickle= complete -c spack -n '__fish_spack_using_command_pos_remainder 0 test-env' -f -a '(__fish_spack_build_env_spec)' complete -c spack -n '__fish_spack_using_command test-env' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command test-env' -s h -l help -d 'show this help message and exit' @@ -2915,8 +2948,8 @@ complete -c spack -n '__fish_spack_using_command test-env' -s U -l fresh -f -a c complete -c spack -n '__fish_spack_using_command test-env' -s U -l fresh -d 'do not reuse installed deps; build newest configuration' complete -c spack -n '__fish_spack_using_command test-env' -l reuse -f -a concretizer_reuse complete -c spack -n '__fish_spack_using_command test-env' -l reuse -d 'reuse installed packages/buildcaches when possible' -complete -c spack -n '__fish_spack_using_command test-env' -l reuse-deps -f -a concretizer_reuse -complete -c spack -n '__fish_spack_using_command test-env' -l reuse-deps -d 'reuse installed dependencies only' +complete -c spack -n '__fish_spack_using_command test-env' -l fresh-roots -l reuse-deps -f -a concretizer_reuse +complete -c spack -n '__fish_spack_using_command test-env' -l fresh-roots -l reuse-deps -d 'concretize with fresh roots and reused dependencies' complete -c spack -n '__fish_spack_using_command test-env' -l deprecated -f -a config_deprecated complete -c spack -n '__fish_spack_using_command test-env' -l deprecated -d 'allow concretizer to select deprecated versions' complete -c spack -n '__fish_spack_using_command test-env' -l dump -r -f -a dump @@ -2958,12 +2991,14 @@ complete -c spack -n '__fish_spack_using_command uninstall' -l origin -r -f -a o complete -c spack -n '__fish_spack_using_command uninstall' -l origin -r -d 'only remove DB records with the specified origin' # spack unit-test -set -g __fish_spack_optspecs_spack_unit_test h/help H/pytest-help l/list L/list-long N/list-names extension= s/ k/= showlocals +set -g __fish_spack_optspecs_spack_unit_test h/help H/pytest-help n/numprocesses= l/list L/list-long N/list-names extension= s/ k/= showlocals complete -c spack -n '__fish_spack_using_command_pos_remainder 0 unit-test' -f -a '(__fish_spack_unit_tests)' complete -c spack -n '__fish_spack_using_command unit-test' -s h -l help -f -a help complete -c spack -n '__fish_spack_using_command unit-test' -s h -l help -d 'show this help message and exit' complete -c spack -n '__fish_spack_using_command unit-test' -s H -l pytest-help -f -a pytest_help complete -c spack -n '__fish_spack_using_command unit-test' -s H -l pytest-help -d 'show full pytest help, with advanced options' +complete -c spack -n '__fish_spack_using_command unit-test' -s n -l numprocesses -r -f -a numprocesses +complete -c spack -n '__fish_spack_using_command unit-test' -s n -l numprocesses -r -d 'run tests in parallel up to this wide, default 1 for sequential' complete -c spack -n '__fish_spack_using_command unit-test' -s l -l list -f -a list complete -c spack -n '__fish_spack_using_command unit-test' -s l -l list -d 'list test filenames' complete -c spack -n '__fish_spack_using_command unit-test' -s L -l list-long -f -a list diff --git a/share/spack/templates/container/Dockerfile b/share/spack/templates/container/Dockerfile index 2f7aae901ca0ba..35dc270a221579 100644 --- a/share/spack/templates/container/Dockerfile +++ b/share/spack/templates/container/Dockerfile @@ -4,7 +4,7 @@ {% endif %} {% if render_phase.build %} # Build stage with Spack pre-installed and ready to be used -FROM {{ build.image }} as builder +FROM {{ build.image }} AS builder {% block build_stage %} {% if os_packages_build %} diff --git a/share/spack/templates/container/bootstrap-base.dockerfile b/share/spack/templates/container/bootstrap-base.dockerfile index 38de6c88494ac2..a8310a982a4f3a 100644 --- a/share/spack/templates/container/bootstrap-base.dockerfile +++ b/share/spack/templates/container/bootstrap-base.dockerfile @@ -1,4 +1,4 @@ -FROM {{ bootstrap.image }} as bootstrap +FROM {{ bootstrap.image }} AS bootstrap {% block env_vars %} ENV SPACK_ROOT=/opt/spack \ diff --git a/share/spack/templates/container/centos_7.dockerfile b/share/spack/templates/container/centos_7.dockerfile deleted file mode 100644 index 2d99ecad91586a..00000000000000 --- a/share/spack/templates/container/centos_7.dockerfile +++ /dev/null @@ -1,28 +0,0 @@ -{% extends "container/bootstrap-base.dockerfile" %} -{% block install_os_packages %} -RUN yum update -y \ - && yum install -y epel-release \ - && yum update -y \ - && yum --enablerepo epel groupinstall -y "Development Tools" \ - && yum --enablerepo epel install -y \ - curl \ - findutils \ - gcc-c++ \ - gcc \ - gcc-gfortran \ - git \ - gnupg2 \ - hostname \ - hg \ - iproute \ - make \ - patch \ - python3 \ - python3-pip \ - python3-setuptools \ - unzip \ - zstd \ - && pip3 install boto3 \ - && rm -rf /var/cache/yum \ - && yum clean all -{% endblock %} diff --git a/share/spack/templates/container/centos_stream.dockerfile b/share/spack/templates/container/centos_stream9.dockerfile similarity index 83% rename from share/spack/templates/container/centos_stream.dockerfile rename to share/spack/templates/container/centos_stream9.dockerfile index c11a658fc7d960..e62c64364f79d1 100644 --- a/share/spack/templates/container/centos_stream.dockerfile +++ b/share/spack/templates/container/centos_stream9.dockerfile @@ -1,14 +1,14 @@ {% extends "container/bootstrap-base.dockerfile" %} {% block install_os_packages %} RUN dnf update -y \ - # See https://fedoraproject.org/wiki/EPEL#Quickstart for powertools + # See https://fedoraproject.org/wiki/EPEL#Quickstart for crb && dnf install -y dnf-plugins-core \ - && dnf config-manager --set-enabled powertools \ + && dnf config-manager --set-enabled crb \ && dnf install -y epel-release \ && dnf update -y \ && dnf --enablerepo epel groupinstall -y "Development Tools" \ && dnf --enablerepo epel install -y \ - curl \ + curl-minimal \ findutils \ gcc-c++ \ gcc \ diff --git a/share/spack/templates/container/fedora_38.dockerfile b/share/spack/templates/container/fedora.dockerfile similarity index 100% rename from share/spack/templates/container/fedora_38.dockerfile rename to share/spack/templates/container/fedora.dockerfile diff --git a/share/spack/templates/container/fedora_37.dockerfile b/share/spack/templates/container/fedora_37.dockerfile deleted file mode 100644 index 6cea1e0cd35181..00000000000000 --- a/share/spack/templates/container/fedora_37.dockerfile +++ /dev/null @@ -1,29 +0,0 @@ -{% extends "container/bootstrap-base.dockerfile" %} -{% block install_os_packages %} -RUN dnf update -y \ - && dnf install -y \ - bzip2 \ - curl \ - file \ - findutils \ - gcc-c++ \ - gcc \ - gcc-gfortran \ - git \ - gnupg2 \ - hg \ - hostname \ - iproute \ - make \ - patch \ - python3 \ - python3-pip \ - python3-setuptools \ - svn \ - unzip \ - zstd \ - xz \ - && pip3 install boto3 \ - && rm -rf /var/cache/dnf \ - && dnf clean all -{% endblock %} diff --git a/share/spack/templates/container/ubuntu_2404.dockerfile b/share/spack/templates/container/ubuntu_2404.dockerfile new file mode 100644 index 00000000000000..1cf4cfb101613d --- /dev/null +++ b/share/spack/templates/container/ubuntu_2404.dockerfile @@ -0,0 +1,33 @@ +{% extends "container/bootstrap-base.dockerfile" %} +{% block env_vars %} +{{ super() }} +ENV DEBIAN_FRONTEND=noninteractive \ + LANGUAGE=en_US.UTF-8 \ + LANG=en_US.UTF-8 \ + LC_ALL=en_US.UTF-8 +{% endblock %} +{% block install_os_packages %} +RUN apt-get -yqq update \ + && apt-get -yqq upgrade \ + && apt-get -yqq install --no-install-recommends \ + build-essential \ + ca-certificates \ + curl \ + file \ + g++ \ + gcc \ + gfortran \ + git \ + gnupg2 \ + iproute2 \ + locales \ + make \ + mercurial \ + subversion \ + python3 \ + python3-boto3 \ + unzip \ + zstd \ + && locale-gen en_US.UTF-8 \ + && rm -rf /var/lib/apt/lists/* +{% endblock %} diff --git a/var/spack/repos/builtin.mock/packages/7zip/package.py b/var/spack/repos/builtin.mock/packages/7zip/package.py new file mode 100644 index 00000000000000..e052e02b93716b --- /dev/null +++ b/var/spack/repos/builtin.mock/packages/7zip/package.py @@ -0,0 +1,14 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class _7zip(AutotoolsPackage): + """Simple package with a name starting with a digit""" + + homepage = "http://www.example.com" + url = "http://www.example.com/a-1.0.tar.gz" + + version("1.0", md5="0123456789abcdef0123456789abcdef") diff --git a/var/spack/repos/builtin.mock/packages/depb/package.py b/var/spack/repos/builtin.mock/packages/depb/package.py index 7022e3472b408e..82661560b4029d 100644 --- a/var/spack/repos/builtin.mock/packages/depb/package.py +++ b/var/spack/repos/builtin.mock/packages/depb/package.py @@ -14,7 +14,7 @@ class Depb(AutotoolsPackage): version("1.0", md5="0123456789abcdef0123456789abcdef") - depends_on("b") + depends_on("pkg-b") def install(self, spec, prefix): # sanity_check_prefix requires something in the install directory diff --git a/var/spack/repos/builtin.mock/packages/deprecated-client/package.py b/var/spack/repos/builtin.mock/packages/deprecated-client/package.py new file mode 100644 index 00000000000000..9806871d8133df --- /dev/null +++ b/var/spack/repos/builtin.mock/packages/deprecated-client/package.py @@ -0,0 +1,16 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class DeprecatedClient(Package): + """A package depending on another which has deprecated versions.""" + + homepage = "http://www.example.com" + url = "http://www.example.com/c-1.0.tar.gz" + + version("1.1.0", sha256="abcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890") + + depends_on("deprecated-versions") diff --git a/var/spack/repos/builtin.mock/packages/dtbuild1/package.py b/var/spack/repos/builtin.mock/packages/dtbuild1/package.py index 0f9c6e2e99ebfc..cb83bbc9f16e0f 100644 --- a/var/spack/repos/builtin.mock/packages/dtbuild1/package.py +++ b/var/spack/repos/builtin.mock/packages/dtbuild1/package.py @@ -16,6 +16,6 @@ class Dtbuild1(Package): version("1.0", md5="0123456789abcdef0123456789abcdef") version("0.5", md5="fedcba9876543210fedcba9876543210") - depends_on("dtbuild2", type="build") + depends_on("vdtbuild2", type="build") depends_on("dtlink2") depends_on("dtrun2", type="run") diff --git a/var/spack/repos/builtin.mock/packages/dtbuild2/package.py b/var/spack/repos/builtin.mock/packages/dtbuild2/package.py index 7aae2109ceb570..59316434f87275 100644 --- a/var/spack/repos/builtin.mock/packages/dtbuild2/package.py +++ b/var/spack/repos/builtin.mock/packages/dtbuild2/package.py @@ -13,3 +13,5 @@ class Dtbuild2(Package): url = "http://www.example.com/dtbuild2-1.0.tar.gz" version("1.0", md5="0123456789abcdef0123456789abcdef") + + provides("vdtbuild2") diff --git a/var/spack/repos/builtin.mock/packages/external-buildable-with-variant/package.py b/var/spack/repos/builtin.mock/packages/external-buildable-with-variant/package.py index 1ec1561a679c9a..28421bad1ad14b 100644 --- a/var/spack/repos/builtin.mock/packages/external-buildable-with-variant/package.py +++ b/var/spack/repos/builtin.mock/packages/external-buildable-with-variant/package.py @@ -15,4 +15,4 @@ class ExternalBuildableWithVariant(Package): variant("baz", default=False, description="nope") - depends_on("c@1.0", when="@0.9") + depends_on("pkg-c@1.0", when="@0.9") diff --git a/var/spack/repos/builtin.mock/packages/find-externals1/package.py b/var/spack/repos/builtin.mock/packages/find-externals1/package.py index 2a82fad9b552ae..07d16a8f221a67 100644 --- a/var/spack/repos/builtin.mock/packages/find-externals1/package.py +++ b/var/spack/repos/builtin.mock/packages/find-externals1/package.py @@ -16,6 +16,10 @@ class FindExternals1(AutotoolsPackage): version("1.0", md5="abcdef1234567890abcdef1234567890") + @classmethod + def determine_version(cls, exe): + return "1.0" + @classmethod def determine_spec_details(cls, prefix, exes_in_prefix): exe_to_path = dict((os.path.basename(p), p) for p in exes_in_prefix) diff --git a/var/spack/repos/builtin.mock/packages/git-ref-package/package.py b/var/spack/repos/builtin.mock/packages/git-ref-package/package.py new file mode 100644 index 00000000000000..21fe10e818a9fe --- /dev/null +++ b/var/spack/repos/builtin.mock/packages/git-ref-package/package.py @@ -0,0 +1,41 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class GitRefPackage(AutotoolsPackage): + """ + dummy package copied from zlib-ng + """ + + homepage = "https://github.com/dummy/dummy" + url = "https://github.com/dummy/dummy/archive/2.0.0.tar.gz" + git = "https://github.com/dummy/dummy.git" + + version("2.1.6", sha256="a5d504c0d52e2e2721e7e7d86988dec2e290d723ced2307145dedd06aeb6fef2") + version("2.1.5", sha256="3f6576971397b379d4205ae5451ff5a68edf6c103b2f03c4188ed7075fbb5f04") + version("2.1.4", sha256="a0293475e6a44a3f6c045229fe50f69dc0eebc62a42405a51f19d46a5541e77a") + version( + "2.1.3", + sha256="d20e55f89d71991c59f1c5ad1ef944815e5850526c0d9cd8e504eaed5b24491a", + deprecated=True, + ) + version( + "2.1.2", + sha256="383560d6b00697c04e8878e26c0187b480971a8bce90ffd26a5a7b0f7ecf1a33", + deprecated=True, + ) + version("2.0.7", sha256="6c0853bb27738b811f2b4d4af095323c3d5ce36ceed6b50e5f773204fb8f7200") + version("2.0.0", sha256="86993903527d9b12fc543335c19c1d33a93797b3d4d37648b5addae83679ecd8") + + variant("compat", default=True, description="Enable compatibility API") + variant("opt", default=True, description="Enable optimizations") + variant("shared", default=True, description="Build shared library") + variant("pic", default=True, description="Enable position-independent code (PIC)") + + conflicts("+shared~pic") + + variant("new_strategies", default=True, description="Enable new deflate strategies") diff --git a/var/spack/repos/builtin.mock/packages/glibc/package.py b/var/spack/repos/builtin.mock/packages/glibc/package.py new file mode 100644 index 00000000000000..17c5087dc70a14 --- /dev/null +++ b/var/spack/repos/builtin.mock/packages/glibc/package.py @@ -0,0 +1,21 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class Glibc(AutotoolsPackage, GNUMirrorPackage): + """The GNU C Library provides many of the low-level components used + directly by programs written in the C or C++ languages. + """ + + homepage = "https://www.gnu.org/software/libc/" + gnu_mirror_path = "libc/glibc-2.33.tar.gz" + git = "https://sourceware.org/git/glibc.git" + + tags = ["runtime"] + + provides("libc") + + version("2.39", sha256="97f84f3b7588cd54093a6f6389b0c1a81e70d99708d74963a2e3eab7c7dc942d") diff --git a/var/spack/repos/builtin.mock/packages/invalid-github-pull-commits-patch-url/package.py b/var/spack/repos/builtin.mock/packages/invalid-github-pull-commits-patch-url/package.py new file mode 100644 index 00000000000000..6038864c37b5ee --- /dev/null +++ b/var/spack/repos/builtin.mock/packages/invalid-github-pull-commits-patch-url/package.py @@ -0,0 +1,20 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class InvalidGithubPullCommitsPatchUrl(Package): + """Package that has a GitHub pull request commit patch URL that fails auditing.""" + + homepage = "http://www.example.com" + url = "http://www.example.com/patch-1.0.tar.gz" + + version("1.0", md5="0123456789abcdef0123456789abcdef") + + patch( + "https://github.com/spack/spack/pull/1/commits/b4da28f71e2cef84c6e289afe89aa4bdf7936048.patch?full_index=1", + sha256="eae9035b832792549fac00680db5f180a88ff79feb7d7a535b4fd71f9d885e73", + ) diff --git a/var/spack/repos/builtin.mock/packages/missing-dependency/package.py b/var/spack/repos/builtin.mock/packages/missing-dependency/package.py index 043ab7981366da..630e32927f3e9d 100644 --- a/var/spack/repos/builtin.mock/packages/missing-dependency/package.py +++ b/var/spack/repos/builtin.mock/packages/missing-dependency/package.py @@ -18,4 +18,4 @@ class MissingDependency(Package): depends_on("this-is-a-missing-dependency") # this one is a "real" mock dependency - depends_on("a") + depends_on("pkg-a") diff --git a/var/spack/repos/builtin.mock/packages/multivalue-variant/package.py b/var/spack/repos/builtin.mock/packages/multivalue-variant/package.py index 1921cfd810f32b..70ab8306a304ad 100644 --- a/var/spack/repos/builtin.mock/packages/multivalue-variant/package.py +++ b/var/spack/repos/builtin.mock/packages/multivalue-variant/package.py @@ -40,5 +40,5 @@ class MultivalueVariant(Package): depends_on("mpi") depends_on("callpath") - depends_on("a") - depends_on("a@1.0", when="fee=barbaz") + depends_on("pkg-a") + depends_on("pkg-a@1.0", when="fee=barbaz") diff --git a/var/spack/repos/builtin.mock/packages/no-redistribute-dependent/package.py b/var/spack/repos/builtin.mock/packages/no-redistribute-dependent/package.py new file mode 100644 index 00000000000000..a362b84ab88b77 --- /dev/null +++ b/var/spack/repos/builtin.mock/packages/no-redistribute-dependent/package.py @@ -0,0 +1,23 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class NoRedistributeDependent(AutotoolsPackage): + """Package with one dependency on a package that should not be + redistributed""" + + homepage = "http://www.example.com" + url = "http://www.example.com/no-redistribute-dependent-1.0.tar.gz" + + version("1.0", "0123456789abcdef0123456789abcdef") + + depends_on("no-redistribute") + + def install(self, spec, prefix): + # sanity_check_prefix requires something in the install directory + # Test requires overriding the one provided by `AutotoolsPackage` + mkdirp(prefix.bin) diff --git a/var/spack/repos/builtin.mock/packages/no-redistribute/package.py b/var/spack/repos/builtin.mock/packages/no-redistribute/package.py new file mode 100644 index 00000000000000..b9dfd5fae3645a --- /dev/null +++ b/var/spack/repos/builtin.mock/packages/no-redistribute/package.py @@ -0,0 +1,23 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class NoRedistribute(Package): + """Package which has source code that should not be added to a public + mirror""" + + homepage = "http://www.example.com" + url = "http://www.example.com/no-redistribute-1.0.tar.gz" + + redistribute(source=False, binary=False) + + version("1.0", "0123456789abcdef0123456789abcdef") + + def install(self, spec, prefix): + # sanity_check_prefix requires something in the install directory + # Test requires overriding the one provided by `AutotoolsPackage` + mkdirp(prefix.bin) diff --git a/var/spack/repos/builtin.mock/packages/optional-dep-test-3/package.py b/var/spack/repos/builtin.mock/packages/optional-dep-test-3/package.py index 48fa846fdde9fe..1e77b601f0706a 100644 --- a/var/spack/repos/builtin.mock/packages/optional-dep-test-3/package.py +++ b/var/spack/repos/builtin.mock/packages/optional-dep-test-3/package.py @@ -16,5 +16,5 @@ class OptionalDepTest3(Package): variant("var", default=False) - depends_on("a", when="~var") - depends_on("b", when="+var") + depends_on("pkg-a", when="~var") + depends_on("pkg-b", when="+var") diff --git a/var/spack/repos/builtin.mock/packages/optional-dep-test/package.py b/var/spack/repos/builtin.mock/packages/optional-dep-test/package.py index ae807650461ddd..b7f87f490f62b2 100644 --- a/var/spack/repos/builtin.mock/packages/optional-dep-test/package.py +++ b/var/spack/repos/builtin.mock/packages/optional-dep-test/package.py @@ -19,14 +19,14 @@ class OptionalDepTest(Package): variant("f", default=False) variant("mpi", default=False) - depends_on("a", when="+a") - depends_on("b", when="@1.1") - depends_on("c", when="%intel") - depends_on("d", when="%intel@64.1") - depends_on("e", when="%clang@34:40") - - depends_on("f", when="+f") - depends_on("g", when="^f") - depends_on("mpi", when="^g") + depends_on("pkg-a", when="+a") + depends_on("pkg-b", when="@1.1") + depends_on("pkg-c", when="%intel") + depends_on("pkg-d", when="%intel@64.1") + depends_on("pkg-e", when="%clang@34:40") + + depends_on("pkg-f", when="+f") + depends_on("pkg-g", when="^pkg-f") + depends_on("mpi", when="^pkg-g") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin.mock/packages/a/package.py b/var/spack/repos/builtin.mock/packages/pkg-a/package.py similarity index 95% rename from var/spack/repos/builtin.mock/packages/a/package.py rename to var/spack/repos/builtin.mock/packages/pkg-a/package.py index 3cc214461074c5..d1ecba835dfc20 100644 --- a/var/spack/repos/builtin.mock/packages/a/package.py +++ b/var/spack/repos/builtin.mock/packages/pkg-a/package.py @@ -6,7 +6,7 @@ from spack.package import * -class A(AutotoolsPackage): +class PkgA(AutotoolsPackage): """Simple package with one optional dependency""" homepage = "http://www.example.com" @@ -25,7 +25,7 @@ class A(AutotoolsPackage): variant("bvv", default=True, description="The good old BV variant") - depends_on("b", when="foobar=bar") + depends_on("pkg-b", when="foobar=bar") depends_on("test-dependency", type="test") parallel = False diff --git a/var/spack/repos/builtin.mock/packages/b/package.py b/var/spack/repos/builtin.mock/packages/pkg-b/package.py similarity index 96% rename from var/spack/repos/builtin.mock/packages/b/package.py rename to var/spack/repos/builtin.mock/packages/pkg-b/package.py index f5d212d3d439ed..bc20950ebc528b 100644 --- a/var/spack/repos/builtin.mock/packages/b/package.py +++ b/var/spack/repos/builtin.mock/packages/pkg-b/package.py @@ -6,7 +6,7 @@ from spack.package import * -class B(Package): +class PkgB(Package): """Simple package with no dependencies""" homepage = "http://www.example.com" diff --git a/var/spack/repos/builtin.mock/packages/c/package.py b/var/spack/repos/builtin.mock/packages/pkg-c/package.py similarity index 95% rename from var/spack/repos/builtin.mock/packages/c/package.py rename to var/spack/repos/builtin.mock/packages/pkg-c/package.py index 2e066242af60e5..2c76f1ea5184c7 100644 --- a/var/spack/repos/builtin.mock/packages/c/package.py +++ b/var/spack/repos/builtin.mock/packages/pkg-c/package.py @@ -6,7 +6,7 @@ from spack.package import * -class C(Package): +class PkgC(Package): """Simple package with no dependencies""" homepage = "http://www.example.com" diff --git a/var/spack/repos/builtin.mock/packages/e/package.py b/var/spack/repos/builtin.mock/packages/pkg-e/package.py similarity index 95% rename from var/spack/repos/builtin.mock/packages/e/package.py rename to var/spack/repos/builtin.mock/packages/pkg-e/package.py index eb0fb0e2ce8a98..d49de9e6fbe075 100644 --- a/var/spack/repos/builtin.mock/packages/e/package.py +++ b/var/spack/repos/builtin.mock/packages/pkg-e/package.py @@ -6,7 +6,7 @@ from spack.package import * -class E(Package): +class PkgE(Package): """Simple package with no dependencies""" homepage = "http://www.example.com" diff --git a/var/spack/repos/builtin.mock/packages/python-venv/package.py b/var/spack/repos/builtin.mock/packages/python-venv/package.py new file mode 100644 index 00000000000000..741fc3c627bfb2 --- /dev/null +++ b/var/spack/repos/builtin.mock/packages/python-venv/package.py @@ -0,0 +1,21 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class PythonVenv(Package): + """A Spack managed Python virtual environment""" + + homepage = "https://docs.python.org/3/library/venv.html" + has_code = False + + version("1.0") + + extends("python") + + def install(self, spec, prefix): + pass diff --git a/var/spack/repos/builtin.mock/packages/sombrero/package.py b/var/spack/repos/builtin.mock/packages/sombrero/package.py new file mode 100644 index 00000000000000..452274cb9c97d7 --- /dev/null +++ b/var/spack/repos/builtin.mock/packages/sombrero/package.py @@ -0,0 +1,16 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Sombrero(Package): + """Simple package with a dependency on an external spec.""" + + homepage = "http://www.example.com" + url = "http://www.example.com/b-1.0.tar.gz" + + version("1.0", md5="0123456789abcdef0123456789abcdef") + depends_on("externaltool") diff --git a/var/spack/repos/builtin.mock/packages/test-dep-with-imposed-conditions/package.py b/var/spack/repos/builtin.mock/packages/test-dep-with-imposed-conditions/package.py index bcea98c52920ef..a34e504bab59ed 100644 --- a/var/spack/repos/builtin.mock/packages/test-dep-with-imposed-conditions/package.py +++ b/var/spack/repos/builtin.mock/packages/test-dep-with-imposed-conditions/package.py @@ -14,4 +14,4 @@ class TestDepWithImposedConditions(Package): version("1.0", md5="0123456789abcdef0123456789abcdef") - depends_on("c@1.0", type="test") + depends_on("pkg-c@1.0", type="test") diff --git a/var/spack/repos/builtin.mock/packages/url-list-test/package.py b/var/spack/repos/builtin.mock/packages/url-list-test/package.py index 0beae47abcb0ca..416451293fab83 100644 --- a/var/spack/repos/builtin.mock/packages/url-list-test/package.py +++ b/var/spack/repos/builtin.mock/packages/url-list-test/package.py @@ -5,6 +5,7 @@ import spack.paths from spack.package import * +from spack.util.url import path_to_file_url class UrlListTest(Package): @@ -13,8 +14,8 @@ class UrlListTest(Package): homepage = "http://www.url-list-example.com" web_data_path = join_path(spack.paths.test_path, "data", "web") - url = "file://" + web_data_path + "/foo-0.0.0.tar.gz" - list_url = "file://" + web_data_path + "/index.html" + url = path_to_file_url(join_path(spack.paths.test_path, "data", "web") + "/foo-0.0.0.tar.gz") + list_url = path_to_file_url(join_path(spack.paths.test_path, "data", "web") + "/index.html") list_depth = 3 version("0.0.0", md5="00000000000000000000000000000000") diff --git a/var/spack/repos/builtin.mock/packages/vendorsb/package.py b/var/spack/repos/builtin.mock/packages/vendorsb/package.py index ebf9c92e5590eb..4ad440a10ed921 100644 --- a/var/spack/repos/builtin.mock/packages/vendorsb/package.py +++ b/var/spack/repos/builtin.mock/packages/vendorsb/package.py @@ -15,5 +15,5 @@ class Vendorsb(Package): version("1.1", md5="0123456789abcdef0123456789abcdef") version("1.0", md5="0123456789abcdef0123456789abcdef") - # b is not a dependency - conflicts("b", when="@=1.1") + # pkg-b is not a dependency + conflicts("pkg-b", when="@=1.1") diff --git a/var/spack/repos/builtin.mock/packages/when-directives-false/package.py b/var/spack/repos/builtin.mock/packages/when-directives-false/package.py index d29d9d83a7b605..5f094b3da91013 100644 --- a/var/spack/repos/builtin.mock/packages/when-directives-false/package.py +++ b/var/spack/repos/builtin.mock/packages/when-directives-false/package.py @@ -20,7 +20,7 @@ class WhenDirectivesFalse(Package): when=False, ) extends("extendee", when=False) - depends_on("b", when=False) + depends_on("pkg-b", when=False) conflicts("@1.0", when=False) resource( url="http://www.example.com/example-1.0-resource.tar.gz", diff --git a/var/spack/repos/builtin.mock/packages/when-directives-true/package.py b/var/spack/repos/builtin.mock/packages/when-directives-true/package.py index 3681b02687ef57..83119b912466a4 100644 --- a/var/spack/repos/builtin.mock/packages/when-directives-true/package.py +++ b/var/spack/repos/builtin.mock/packages/when-directives-true/package.py @@ -20,7 +20,7 @@ class WhenDirectivesTrue(Package): when=True, ) extends("extendee", when=True) - depends_on("b", when=True) + depends_on("pkg-b", when=True) conflicts("@1.0", when=True) resource( url="http://www.example.com/example-1.0-resource.tar.gz", diff --git a/var/spack/repos/builtin.mock/packages/with-constraint-met/package.py b/var/spack/repos/builtin.mock/packages/with-constraint-met/package.py index a4f6e916bb2dbd..e300a0fd366d67 100644 --- a/var/spack/repos/builtin.mock/packages/with-constraint-met/package.py +++ b/var/spack/repos/builtin.mock/packages/with-constraint-met/package.py @@ -16,8 +16,8 @@ class WithConstraintMet(Package): version("1.0", md5="0123456789abcdef0123456789abcdef") with when("@1.0"): - depends_on("b") + depends_on("pkg-b") conflicts("%gcc", when="+foo") - with when("@0.14: ^b@:4.0"): - depends_on("c", when="@:15 ^b@3.8:") + with when("@0.14: ^pkg-b@:4.0"): + depends_on("pkg-c", when="@:15 ^pkg-b@3.8:") diff --git a/var/spack/repos/builtin.mock/packages/wrong-variant-in-depends-on/package.py b/var/spack/repos/builtin.mock/packages/wrong-variant-in-depends-on/package.py index cef5aafe472b5f..98fb4a95c087b4 100644 --- a/var/spack/repos/builtin.mock/packages/wrong-variant-in-depends-on/package.py +++ b/var/spack/repos/builtin.mock/packages/wrong-variant-in-depends-on/package.py @@ -13,4 +13,4 @@ class WrongVariantInDependsOn(Package): version("1.0", md5="0123456789abcdef0123456789abcdef") - depends_on("b+doesnotexist") + depends_on("pkg-b+doesnotexist") diff --git a/var/spack/repos/builtin/packages/3proxy/package.py b/var/spack/repos/builtin/packages/3proxy/package.py index ed6f19609493f1..a8750657715c31 100644 --- a/var/spack/repos/builtin/packages/3proxy/package.py +++ b/var/spack/repos/builtin/packages/3proxy/package.py @@ -18,6 +18,8 @@ class _3proxy(MakefilePackage): version("0.8.12", sha256="c2ad3798b4f0df06cfcc7b49f658304e451d60e4834e2705ef83ddb85a03f849") version("0.8.11", sha256="fc4295e1a462baa61977fcc21747db7861c4e3d0dcca86cbaa3e06017e5c66c9") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/7zip/package.py b/var/spack/repos/builtin/packages/7zip/package.py index d404510a3f9297..089e8f54e6ce22 100644 --- a/var/spack/repos/builtin/packages/7zip/package.py +++ b/var/spack/repos/builtin/packages/7zip/package.py @@ -25,6 +25,9 @@ class _7zip(SourceforgePackage, Package): version("21.07", sha256="213d594407cb8efcba36610b152ca4921eda14163310b43903d13e68313e1e39") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "link_type", default="shared", @@ -37,7 +40,6 @@ class _7zip(SourceforgePackage, Package): conflicts("platform=linux") conflicts("platform=darwin") - conflicts("platform=cray") # TODO: Patch on WinSDK version 10.0.20348.0 when SDK is introduced to Spack # This patch solves a known bug in that SDK version on the 7zip side diff --git a/var/spack/repos/builtin/packages/abacus/package.py b/var/spack/repos/builtin/packages/abacus/package.py index 68cfbfea75ff49..7ba2ee206ab2c0 100644 --- a/var/spack/repos/builtin/packages/abacus/package.py +++ b/var/spack/repos/builtin/packages/abacus/package.py @@ -29,6 +29,9 @@ class Abacus(MakefilePackage): version("2.2.1", sha256="14feca1d8d1ce025d3f263b85ebfbebc1a1efff704b6490e95b07603c55c1d63") version("2.2.0", sha256="09d4a2508d903121d29813a85791eeb3a905acbe1c5664b8a88903f8eda64b8f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Enable OpenMP support") depends_on("elpa+openmp", when="+openmp") diff --git a/var/spack/repos/builtin/packages/abduco/package.py b/var/spack/repos/builtin/packages/abduco/package.py index 21a075e0f513e8..dc4a1b9c3b1316 100644 --- a/var/spack/repos/builtin/packages/abduco/package.py +++ b/var/spack/repos/builtin/packages/abduco/package.py @@ -22,5 +22,7 @@ class Abduco(MakefilePackage): version("0.5", sha256="bf22226a4488355a7001a5dabbd1e8e3b7e7645efd1519274b956fcb8bcff086") version("0.4", sha256="bda3729df116ce41f9a087188d71d934da2693ffb1ebcf33b803055eb478bcbb") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make(f"PREFIX={prefix}", "install") diff --git a/var/spack/repos/builtin/packages/abinit/package.py b/var/spack/repos/builtin/packages/abinit/package.py index 47c69fc4024217..67abe078f6d280 100644 --- a/var/spack/repos/builtin/packages/abinit/package.py +++ b/var/spack/repos/builtin/packages/abinit/package.py @@ -25,10 +25,11 @@ class Abinit(AutotoolsPackage): """ homepage = "https://www.abinit.org/" - url = "https://www.abinit.org/sites/default/files/packages/abinit-8.6.3.tar.gz" + url = "https://www.abinit.org/sites/default/files/packages/abinit-10.0.7.tar.gz" license("Apache-2.0") maintainers("downloadico") + version("10.0.7", sha256="a9fc044b33861b7defd50fafd19a73eb6f225e18ae30b23bc731d9c8009c881c") version("9.10.5", sha256="a9e0f0e058baa6088ea93d26ada369ccf0fe52dc9d4a865b1c38c20620148cd5") version("9.10.3", sha256="3f2a9aebbf1fee9855a09dd687f88d2317b8b8e04f97b2628ab96fb898dce49b") version("9.8.4", sha256="a086d5045f0093b432e6a044d5f71f7edf5a41a62d67b3677cb0751d330c564a") @@ -43,6 +44,10 @@ class Abinit(AutotoolsPackage): # Versions before 8.0.8b are not supported. version("8.0.8b", sha256="37ad5f0f215d2a36e596383cb6e54de3313842a0390ce8d6b48a423d3ee25af2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Builds with MPI support. Requires MPI2+") variant("openmp", default=False, description="Enables OpenMP threads. Use threaded FFTW3") variant("scalapack", default=False, description="Enables scalapack support. Requires MPI") @@ -126,7 +131,7 @@ class Abinit(AutotoolsPackage): ) patch("rm_march_settings.patch", when="@:8") - patch("rm_march_settings_v9.patch", when="@9:") + patch("rm_march_settings_v9.patch", when="@9") # Fix detection of Fujitsu compiler # Fix configure not to collect the option that causes an error @@ -316,6 +321,16 @@ def check(self): if "~mpi" in self.spec: make("tests_in") + # Abinit assumes the *old* behavior of HDF5 where the library flags to link + # to the library were stored in the lib/libhdf5.settings file. + # Spack already knows how to link to HDF5, disable this check in configure + def patch(self): + filter_file( + r"sd_hdf5_libs_extra=.*", + "sd_hdf5_libs_extra=%s" % self.spec["hdf5"].libs.ld_flags, + "configure", + ) + def install(self, spec, prefix): make("install") if "+install-tests" in spec: diff --git a/var/spack/repos/builtin/packages/abseil-cpp/package.py b/var/spack/repos/builtin/packages/abseil-cpp/package.py index 118e035e5a113d..1eac4a1544ea22 100644 --- a/var/spack/repos/builtin/packages/abseil-cpp/package.py +++ b/var/spack/repos/builtin/packages/abseil-cpp/package.py @@ -17,6 +17,9 @@ class AbseilCpp(CMakePackage): license("Apache-2.0") + version( + "20240116.2", sha256="733726b8c3a6d39a4120d7e45ea8b41a434cdacde401cba500f14236c49b39dc" + ) version( "20240116.1", sha256="3c743204df78366ad2eaf236d6631d83f6bc928d1705dd0000b872e53b73dc6a" ) @@ -63,6 +66,15 @@ class AbseilCpp(CMakePackage): version("20181200", sha256="e2b53bfb685f5d4130b84c4f3050c81bf48c497614dc85d91dbd3ed9129bce6d") version("20180600", sha256="794d483dd9a19c43dc1fbbe284ce8956eb7f2600ef350dac4c602f9b4eb26e90") + depends_on("cxx", type="build") # generated + + # Avoid export of testonly target absl::test_allocator in CMake builds + patch( + "https://github.com/abseil/abseil-cpp/commit/779a3565ac6c5b69dd1ab9183e500a27633117d5.patch?full_index=1", + sha256="14ad7abbc20b10d57e00d0940e8338f69fd69f58d8285214848998e8687688cc", + when="@20240116", + ) + variant("shared", default=True, description="Build shared instead of static libraries") conflicts("+shared", when="@:20190808") diff --git a/var/spack/repos/builtin/packages/abyss/package.py b/var/spack/repos/builtin/packages/abyss/package.py index 1e7f8d185e96a8..5d52353b10e7c1 100644 --- a/var/spack/repos/builtin/packages/abyss/package.py +++ b/var/spack/repos/builtin/packages/abyss/package.py @@ -36,6 +36,9 @@ class Abyss(AutotoolsPackage): version("2.0.2", sha256="d87b76edeac3a6fb48f24a1d63f243d8278a324c9a5eb29027b640f7089422df") version("1.5.2", sha256="8a52387f963afb7b63db4c9b81c053ed83956ea0a3981edcad554a895adf84b1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "maxk", default=128, values=is_multiple_32, description="set the maximum k-mer length." ) diff --git a/var/spack/repos/builtin/packages/accfft/package.py b/var/spack/repos/builtin/packages/accfft/package.py index d3a4b91c035239..b38e074119b3d4 100644 --- a/var/spack/repos/builtin/packages/accfft/package.py +++ b/var/spack/repos/builtin/packages/accfft/package.py @@ -18,6 +18,8 @@ class Accfft(CMakePackage, CudaPackage): version("develop", branch="master") + depends_on("cxx", type="build") # generated + variant("pnetcdf", default=True, description="Add support for parallel NetCDF") variant("shared", default=True, description="Enables the build of shared libraries") diff --git a/var/spack/repos/builtin/packages/acct/package.py b/var/spack/repos/builtin/packages/acct/package.py index 2f0181bd085114..906f9b34f30cdf 100644 --- a/var/spack/repos/builtin/packages/acct/package.py +++ b/var/spack/repos/builtin/packages/acct/package.py @@ -18,6 +18,9 @@ class Acct(AutotoolsPackage): version("6.6.3", sha256="5eae79323bf1ce403704d2b70483c46e7c853276ee7b5ad561ec3ccae9fca093") version("6.6.2", sha256="8ed47b2f893b08f0d67720880adbb48b835a826c314fa52fd52af1cee6870101") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def setup_run_environment(self, env): env.prepend_path("PATH", self.prefix.sbin) diff --git a/var/spack/repos/builtin/packages/accumulo/package.py b/var/spack/repos/builtin/packages/accumulo/package.py index dea471e673d70c..6b1a915271d95e 100644 --- a/var/spack/repos/builtin/packages/accumulo/package.py +++ b/var/spack/repos/builtin/packages/accumulo/package.py @@ -21,5 +21,8 @@ class Accumulo(MavenPackage): version("1.9.3", sha256="d9548d5b9cf9f494f027f0fe59d5d6d45d09064359d7761cade62991ce2a5d0c") version("1.9.2", sha256="11ab028143ad6313cd5fc701b36b4c35e46a4a3fa2ce663869860b9f6bf5ee4d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("java@8:", type=("build", "run")) depends_on("maven@3.5.0:", type="build") diff --git a/var/spack/repos/builtin/packages/ace/package.py b/var/spack/repos/builtin/packages/ace/package.py index 0b18d4f0da50b4..89a2158420fdc9 100644 --- a/var/spack/repos/builtin/packages/ace/package.py +++ b/var/spack/repos/builtin/packages/ace/package.py @@ -18,6 +18,7 @@ class Ace(MakefilePackage): license("DOC") + version("7.1.4", sha256="a2bc358401178dd8175f4d826e60d23d901bfe38bc2fa0ac9275d01d7fda34bc") version("7.1.3", sha256="4cb82d8daf83f3abe50ac460b4fac9a8da2512f08d8efb4d327dcacd0b3929b3") version("7.1.0", sha256="d78d9f3f2dee6ccb46a8c296367369349054fd475dff3c5b36e2dff3dee0bf8f") version("6.5.12", sha256="de96c68a6262d6b9ba76b5057c02c7e6964c070b1328a63bf70259e9530a7996") @@ -25,6 +26,9 @@ class Ace(MakefilePackage): version("6.5.1", sha256="1f318adadb19da23c9be570a9c600a330056b18950fe0bf0eb1cf5cac8b72a32") version("6.5.0", sha256="b6f9ec922fbdcecb4348e16d851d0d1f135df1836dfe77d2e0b64295ddb83066") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def edit(self, spec, prefix): # Dictionary mapping: compiler-name : ACE config-label supported = {"intel": "_icc", "gcc": ""} diff --git a/var/spack/repos/builtin/packages/acfl/detection_test.yaml b/var/spack/repos/builtin/packages/acfl/detection_test.yaml new file mode 100644 index 00000000000000..23fc1930f228b3 --- /dev/null +++ b/var/spack/repos/builtin/packages/acfl/detection_test.yaml @@ -0,0 +1,83 @@ +paths: +- layout: + - executables: + - "bin/armclang" + - "bin/armclang++" + - "bin/armflang" + script: | + echo "Arm C/C++/Fortran Compiler version 19.0 (build number 73) (based on LLVM 7.0.2)" + echo "Target: aarch64--linux-gnu" + echo "Thread model: posix" + echo "InstalledDir:" + echo "/opt/arm/arm-hpc-compiler-19.0_Generic-AArch64_RHEL-7_aarch64-linux/bin" + platforms: [linux] + results: + - spec: acfl@19.0 + extra_attributes: + compilers: + c: ".*/bin/armclang" + cxx: ".*/bin/armclang[+][+]" + fortran: ".*/bin/armflang" +- layout: + - executables: + - "bin/armclang" + - "bin/armclang++" + script: | + echo "Arm C/C++/Fortran Compiler version 19.0 (build number 73) (based on LLVM 7.0.2)" + echo "Target: aarch64--linux-gnu" + echo "Thread model: posix" + echo "InstalledDir:" + echo "/opt/arm/arm-hpc-compiler-19.0_Generic-AArch64_RHEL-7_aarch64-linux/bin" + platforms: [linux] + results: + - spec: acfl@19.0 + extra_attributes: + compilers: + c: ".*/bin/armclang" + cxx: ".*/bin/armclang[+][+]" +- layout: + - executables: + - "bin/armclang" + - "bin/armclang++" + - "bin/armflang" + script: | + echo "Arm C/C++/Fortran Compiler version 19.3.1 (build number 75) (based on LLVM 7.0.2)" + echo "Target: aarch64--linux-gnu" + echo "Thread model: posix" + echo "InstalledDir:" + echo "/opt/arm/arm-hpc-compiler-19.3.5_Generic-AArch64_RHEL-7_aarch64-linux/bin" + - executables: + - "bin/armclang-18" + - "bin/armclang++-18" + - "bin/armflang-18" + script: | + echo "Arm C/C++/Fortran Compiler version 18.0 (build number 27) (based on LLVM 7.0.0)" + echo "Target: aarch64--linux-gnu" + echo "Thread model: posix" + echo "InstalledDir:" + echo "/opt/arm/arm-hpc-compiler-19_Generic-AArch64_RHEL-7_aarch64-linux/bin" + platforms: [linux] + results: + - spec: acfl@19.3.1 + extra_attributes: + compilers: + c: ".*/bin/armclang$" + cxx: ".*/bin/armclang[+][+]$" + fortran: ".*/bin/armflang$" + - spec: acfl@18.0 + extra_attributes: + compilers: + c: ".*/bin/armclang-18" + cxx: ".*/bin/armclang[+][+]-18" + fortran: ".*/bin/armflang-18" +- layout: # does not detect upstream clang + - executables: + - "bin/clang" + - "bin/clang++" + script: | + echo "clang version 8.0.0 (tags/RELEASE_800/final" + echo "Target: x86_64-unknown-linux-gnu\n" + echo "Thread model: posix\n" + echo "InstalledDir: /usr/bin" + platforms: [linux] + results: [] diff --git a/var/spack/repos/builtin/packages/acfl/package.py b/var/spack/repos/builtin/packages/acfl/package.py index fefab9b5742275..42a750da51eaf1 100644 --- a/var/spack/repos/builtin/packages/acfl/package.py +++ b/var/spack/repos/builtin/packages/acfl/package.py @@ -3,7 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) import os -import re from spack.package import * @@ -37,6 +36,40 @@ } _versions = { + "24.04": { + "RHEL-7": ( + "064c3ecfd71cba3d8bf639448e899388f58eb7faef4b38f3c1aace625ace8b1e", + "https://developer.arm.com/-/media/Files/downloads/hpc/arm-compiler-for-linux/24-04/arm-compiler-for-linux_24.04_RHEL-7_aarch64.tar", + ), + "RHEL-8": ( + "38f46a3549667d0fbccd947653d3a1a56b630d3bbb1251888c674c463f00dac3", + "https://developer.arm.com/-/media/Files/downloads/hpc/arm-compiler-for-linux/24-04/arm-compiler-for-linux_24.04_RHEL-8_aarch64.tar", + ), + "RHEL-9": ( + "d335db82c8310e1d79c96dc09a19e4d509c5ab17eb6027214bb79cfc75d8229e", + "https://developer.arm.com/-/media/Files/downloads/hpc/arm-compiler-for-linux/24-04/arm-compiler-for-linux_24.04_RHEL-9_aarch64.tar", + ), + "SLES-15": ( + "6f2e090efcd8da2cbeaf63272fac5917f637713f1e86d73cde2ad7268e3a05a2", + "https://developer.arm.com/-/media/Files/downloads/hpc/arm-compiler-for-linux/24-04/arm-compiler-for-linux_24.04_SLES-15_aarch64.tar", + ), + "Ubuntu-20.04": ( + "0d782e6a69a11f90bf3b392313c885a2376c5761f227bf2f68e34e9848ec8e97", + "https://developer.arm.com/-/media/Files/downloads/hpc/arm-compiler-for-linux/24-04/arm-compiler-for-linux_24.04_Ubuntu-20.04_aarch64.tar", + ), + "Ubuntu-22.04": ( + "0bab2e89f0a2359746f89a01251dca763305c5b0dee95cf47b0968dd1cb5f6f6", + "https://developer.arm.com/-/media/Files/downloads/hpc/arm-compiler-for-linux/24-04/arm-compiler-for-linux_24.04_Ubuntu-22.04_aarch64.tar", + ), + "AmazonLinux-2": ( + "cf0bebe2d7123749c919a5f4e36100ad21f08ffbad3b53e477205c08ae973a2d", + "https://developer.arm.com/-/media/Files/downloads/hpc/arm-compiler-for-linux/24-04/arm-compiler-for-linux_24.04_AmazonLinux-2_aarch64.tar", + ), + "AmazonLinux-2023": ( + "035dae8c41a1ac86c8885837978cb712306aa75dc5d26d17aca843b84eaee9f4", + "https://developer.arm.com/-/media/Files/downloads/hpc/arm-compiler-for-linux/24-04/arm-compiler-for-linux_24.04_AmazonLinux-2023_aarch64.tar", + ), + }, "23.10": { "RHEL-7": ( "c3bd4df3e5f6c97369237b0067e0a421dceb9c167d73f22f3da87f5025258314", @@ -193,34 +226,22 @@ def get_armpl_version_to_3(spec): def get_armpl_prefix(spec): + ver = get_armpl_version_to_3(spec) + os = get_os(spec.version.string) if spec.version.string.startswith("22."): - return join_path( - spec.prefix, - "armpl-{}_AArch64_{}_arm-linux-compiler_aarch64-linux".format( - get_armpl_version_to_3(spec), get_os(spec.version.string) - ), - ) + return join_path(spec.prefix, f"armpl-{ver}_AArch64_{os}_arm-linux-compiler_aarch64-linux") else: - return join_path( - spec.prefix, - "armpl-{}_{}_arm-linux-compiler".format( - get_armpl_version_to_3(spec), get_os(spec.version.string) - ), - ) + return join_path(spec.prefix, f"armpl-{ver}_{os}_arm-linux-compiler") def get_acfl_prefix(spec): + os = get_os(spec.version.string) if spec.version.string.startswith("22."): return join_path( - spec.prefix, - "arm-linux-compiler-{0}_Generic-AArch64_{1}_aarch64-linux".format( - spec.version, get_os(spec.version.string) - ), + spec.prefix, f"arm-linux-compiler-{spec.version}_Generic-AArch64_{os}_aarch64-linux" ) else: - return join_path( - spec.prefix, f"arm-linux-compiler-{spec.version}_{get_os(spec.version.string)}" - ) + return join_path(spec.prefix, f"arm-linux-compiler-{spec.version}_{os}") def get_gcc_prefix(spec): @@ -228,7 +249,17 @@ def get_gcc_prefix(spec): return join_path(spec.prefix, next(dir for dir in dirlist if dir.startswith("gcc"))) -class Acfl(Package): +def get_armpl_suffix(spec): + suffix = "" + if spec.satisfies("@24:"): + suffix += "_ilp64" if spec.satisfies("+ilp64") else "_lp64" + else: + suffix += "_ilp64" if spec.satisfies("+ilp64") else "" + suffix += "_mp" if spec.satisfies("threads=openmp") else "" + return suffix + + +class Acfl(Package, CompilerPackage): """Arm Compiler combines the optimized tools and libraries from Arm with a modern LLVM-based compiler framework. """ @@ -236,7 +267,7 @@ class Acfl(Package): homepage = "https://developer.arm.com/Tools%20and%20Software/Arm%20Compiler%20for%20Linux" url = "https://developer.arm.com/-/media/Files/downloads/hpc/arm-compiler-for-linux/23-10/arm-compiler-for-linux_23.10_Ubuntu-22.04_aarch64.tar" - maintainers("annop-w") + maintainers("paolotricerri") # Build Versions for ver, packages in _versions.items(): @@ -275,33 +306,15 @@ def install(self, spec, prefix): ) exe("--accept", "--force", "--install-to", prefix) - @classmethod - def determine_version(cls, exe): - regex_str = r"Arm C\/C\+\+\/Fortran Compiler version ([\d\.]+) " r"\(build number (\d+)\) " - version_regex = re.compile(regex_str) - try: - output = spack.compiler.get_compiler_version_output(exe, "--version") - match = version_regex.search(output) - if match: - if match.group(1).count(".") == 1: - return match.group(1) + ".0." + match.group(2) - return match.group(1) + "." + match.group(2) - except spack.util.executable.ProcessError: - pass - except Exception as e: - tty.debug(e) - - @classmethod - def determine_variants(cls, exes, version_str): - compilers = {} - for exe in exes: - if "armclang" in exe: - compilers["c"] = exe - if "armclang++" in exe: - compilers["cxx"] = exe - if "armflang" in exe: - compilers["fortran"] = exe - return "", {"compilers": compilers} + compiler_languages = ["c", "cxx", "fortran"] + c_names = ["armclang"] + cxx_names = ["armclang++"] + fortran_names = ["armflang"] + + compiler_version_argument = "--version" + compiler_version_regex = ( + r"Arm C\/C\+\+\/Fortran Compiler version ([\d\.]+) \(build number \d+\) " + ) @property def cc(self): @@ -329,10 +342,7 @@ def fortran(self): @property def lib_suffix(self): - suffix = "" - suffix += "_ilp64" if self.spec.satisfies("+ilp64") else "" - suffix += "_mp" if self.spec.satisfies("threads=openmp") else "" - return suffix + return get_armpl_suffix(self.spec) @property def blas_libs(self): @@ -368,7 +378,10 @@ def libs(self): def headers(self): armpl_dir = get_armpl_prefix(self.spec) - suffix = "include" + self.lib_suffix + if self.spec.satisfies("@24:"): + suffix = "include" + else: + suffix = "include" + self.lib_suffix incdir = join_path(armpl_dir, suffix) @@ -408,8 +421,9 @@ def setup_run_environment(self, env): def check_install(self): arm_dir = get_acfl_prefix(self.spec) armpl_dir = get_armpl_prefix(self.spec) + suffix = get_armpl_suffix(self.spec) gcc_dir = get_gcc_prefix(self.spec) - armpl_example_dir = join_path(armpl_dir, "examples") + armpl_example_dir = join_path(armpl_dir, f"examples{suffix}") # run example makefile make( "-C", @@ -418,6 +432,7 @@ def check_install(self): "F90=" + self.fortran, "CPATH=" + join_path(arm_dir, "include"), "COMPILER_PATH=" + gcc_dir, + "ARMPL_DIR=" + armpl_dir, ) # clean up make("-C", armpl_example_dir, "clean") diff --git a/var/spack/repos/builtin/packages/acl/package.py b/var/spack/repos/builtin/packages/acl/package.py index ba30afbf22548a..c15e07a0c00e24 100644 --- a/var/spack/repos/builtin/packages/acl/package.py +++ b/var/spack/repos/builtin/packages/acl/package.py @@ -21,6 +21,8 @@ class Acl(AutotoolsPackage): version("2.2.49", sha256="c6e01460cac4e47673dd60a7f57b970b49f6998bb564eff141cca129aa8940d1") version("2.2.48", sha256="877eaeccc1500baec58391935b46ac7dfc5ffd8c54fbc0385ccd8b2b18ac3fa6") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/acpica-tools/package.py b/var/spack/repos/builtin/packages/acpica-tools/package.py index 5c0dc148470de1..090ccd70e111bd 100644 --- a/var/spack/repos/builtin/packages/acpica-tools/package.py +++ b/var/spack/repos/builtin/packages/acpica-tools/package.py @@ -15,6 +15,8 @@ class AcpicaTools(MakefilePackage): version("20200528", sha256="07cd3e370b695ab787d25a7165e37eb7b150dca7908f047a6a6486d216cf05a8") version("20200430", sha256="e3118583bf6e4bb4745d642a863cce1b4fcfdf67558e4ae53df367b7e26b89ac") + depends_on("c", type="build") # generated + depends_on("flex", type="build") depends_on("bison", type="build") diff --git a/var/spack/repos/builtin/packages/acpid/package.py b/var/spack/repos/builtin/packages/acpid/package.py index 00af2a543ee051..3e224a39c623f6 100644 --- a/var/spack/repos/builtin/packages/acpid/package.py +++ b/var/spack/repos/builtin/packages/acpid/package.py @@ -24,6 +24,8 @@ class Acpid(AutotoolsPackage): version("2.0.25", sha256="947d2e4f9b2d61a728ce5d6139901f1b666dcef5e2a48833cb33d82895e261cf") version("2.0.24", sha256="05903901369c4ebea1d24e445b4a1d516dd3b07e7864cc752a2d09b4147e1985") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/activemq/package.py b/var/spack/repos/builtin/packages/activemq/package.py index 7b1add648ad08c..c003cfae517b86 100644 --- a/var/spack/repos/builtin/packages/activemq/package.py +++ b/var/spack/repos/builtin/packages/activemq/package.py @@ -26,6 +26,8 @@ class Activemq(Package): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("java") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/acts-algebra-plugins/package.py b/var/spack/repos/builtin/packages/acts-algebra-plugins/package.py new file mode 100644 index 00000000000000..0e12d5e25cefcf --- /dev/null +++ b/var/spack/repos/builtin/packages/acts-algebra-plugins/package.py @@ -0,0 +1,68 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class ActsAlgebraPlugins(CMakePackage): + """A portable linear algebra library with multiple backends that is part of + the Acts ecosystem.""" + + homepage = "https://github.com/acts-project/algebra-plugins" + url = "https://github.com/acts-project/algebra-plugins/archive/refs/tags/v0.24.0.tar.gz" + + maintainers("stephenswat", "wdconinc") + + license("MPL-2.0", checked_by="stephenswat") + + version("0.24.0", sha256="f44753e62b1ba29c28ab86b282ab67ac6028a0f9fe41e599b7fc6fc50b586b62") + + depends_on("cxx", type="build") # generated + + variant( + "cxxstd", + default="17", + values=("17", "20", "23"), + multi=False, + description="C++ standard used", + ) + variant("eigen", default=False, description="Enables the Eigen plugin") + variant("smatrix", default=False, description="Enables the SMatrix plugin") + variant("vecmem", default=False, description="Enables the vecmem plugin") + variant("vc", default=False, description="Enables the Vc plugin") + variant("fastor", default=False, description="Enables the Fastor plugin") + + depends_on("cmake@3.14:", type="build") + depends_on("vecmem@1.5.0:", when="+vecmem") + depends_on("eigen@3.4.0:", when="+eigen") + depends_on("vc@1.4.3:", when="+vc") + depends_on("root@6.18.0:", when="+smatrix") + depends_on("fastor@0.6.4:", when="+fastor") + + with when("+smatrix"): + depends_on("root cxxstd=17", when="cxxstd=17") + depends_on("root cxxstd=20", when="cxxstd=20") + conflicts("cxxstd=23") + + def cmake_args(self): + args = [ + self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), + self.define("ALGEBRA_PLUGINS_USE_SYSTEM_LIBS", True), + self.define_from_variant("ALGEBRA_PLUGINS_INCLUDE_EIGEN", "eigen"), + self.define_from_variant("ALGEBRA_PLUGINS_SETUP_EIGEN3", "eigen"), + self.define_from_variant("ALGEBRA_PLUGINS_INCLUDE_SMATRIX", "smatrix"), + self.define_from_variant("ALGEBRA_PLUGINS_INCLUDE_VC", "vc"), + self.define_from_variant("ALGEBRA_PLUGINS_SETUP_VC", "vc"), + self.define_from_variant("ALGEBRA_PLUGINS_INCLUDE_VECMEM", "vecmem"), + self.define_from_variant("ALGEBRA_PLUGINS_SETUP_VECMEM", "vecmem"), + self.define_from_variant("ALGEBRA_PLUGINS_INCLUDE_FASTOR", "fastor"), + self.define_from_variant("ALGEBRA_PLUGINS_SETUP_FASTOR", "fastor"), + self.define("ALGEBRA_PLUGINS_BUILD_TESTING", False), + self.define("ALGEBRA_PLUGINS_SETUP_GOOGLETEST", False), + self.define("ALGEBRA_PLUGINS_SETUP_BENCHMARK", False), + self.define("ALGEBRA_PLUGINS_BUILD_BENCHMARKS", False), + ] + + return args diff --git a/var/spack/repos/builtin/packages/acts-dd4hep/package.py b/var/spack/repos/builtin/packages/acts-dd4hep/package.py index 5aa29c7c20c0b1..173a9f283e7b8e 100644 --- a/var/spack/repos/builtin/packages/acts-dd4hep/package.py +++ b/var/spack/repos/builtin/packages/acts-dd4hep/package.py @@ -12,9 +12,11 @@ class ActsDd4hep(CMakePackage): homepage = "https://github.com/acts-project/acts-dd4hep" url = "https://github.com/acts-project/acts-dd4hep/archive/refs/tags/v1.0.0.tar.gz" - maintainers("HadrienG2", "wdconinc") + maintainers("wdconinc") version("1.0.1", sha256="e40f34ebc30b3c33a6802c9d94136e65072d8dcee0b7db57a645f08a64ea5334") version("1.0.0", sha256="991f996944c88efa837880f919239e50d12c5c9361e220bc9422438dd608308c") + depends_on("cxx", type="build") # generated + depends_on("dd4hep@1.11: +dddetectors") diff --git a/var/spack/repos/builtin/packages/acts/package.py b/var/spack/repos/builtin/packages/acts/package.py index cc0f54363e83a5..735b4b8736fc67 100644 --- a/var/spack/repos/builtin/packages/acts/package.py +++ b/var/spack/repos/builtin/packages/acts/package.py @@ -33,7 +33,7 @@ class Acts(CMakePackage, CudaPackage): homepage = "https://acts.web.cern.ch/ACTS/" git = "https://github.com/acts-project/acts.git" list_url = "https://github.com/acts-project/acts/releases/" - maintainers("HadrienG2") + maintainers("wdconinc") tags = ["hep"] @@ -42,6 +42,16 @@ class Acts(CMakePackage, CudaPackage): # Supported Acts versions version("main", branch="main") version("master", branch="main", deprecated=True) # For compatibility + version("35.2.0", commit="b3b09f46d064c43050dd3d21cdf51d7a412134fc", submodules=True) + version("35.1.0", commit="9dfb47b8edeb8b9c75115462079bcb003dd3f031", submodules=True) + version("35.0.0", commit="352b423ec31934f825deb9897780246d60ffc44e", submodules=True) + version("34.1.0", commit="8e1b7a659d912cd98db9d700906ff59e708da574", submodules=True) + version("34.0.0", commit="daafd83adf0ce50f9667f3c9d4791a459e39fd1b", submodules=True) + version("33.1.0", commit="00591a593a648430820e980b031301d25c18f1c7", submodules=True) + version("33.0.0", commit="f6ed9013e76120137ae456583a04b554d88d9452", submodules=True) + version("32.1.0", commit="5333c67b49b4bfcd45558090e4ba37b4f86b82db", submodules=True) + version("32.0.2", commit="3d23e16a2d0ba68ce5a596ced16883f90de1fae4", submodules=True) + version("32.0.1", commit="6317634ec16eb40e52ca85445a014e378c9a4829", submodules=True) version("32.0.0", commit="9385e36691bb2687437c39ad02ddb2ac21acccdc", submodules=True) version("31.2.0", commit="1d2e90f534ff2c9bf1c40914980b426f4b5d3096", submodules=True) version("31.1.0", commit="95c3ceef79a7b68fcfc7fd558c3134d0c7529dac", submodules=True) @@ -170,6 +180,8 @@ class Acts(CMakePackage, CudaPackage): version("0.08.1", commit="289bdcc320f0b3ff1d792e29e462ec2d3ea15df6") version("0.08.0", commit="99eedb38f305e3a1cd99d9b4473241b7cd641fa9") + depends_on("cxx", type="build") # generated + # Variants that affect the core Acts library variant( "benchmarks", default=False, description="Build the performance benchmarks", when="@0.16:" @@ -192,7 +204,13 @@ class Acts(CMakePackage, CudaPackage): "examples", default=False, description="Build the examples", - when="@17: +fatras +identification +json +tgeo", + when="@17:34 +fatras +identification +json +tgeo", + ) + variant( + "examples", + default=False, + description="Build the examples", + when="@35: +fatras +json +tgeo", ) variant("integration_tests", default=False, description="Build the integration tests") variant("unit_tests", default=False, description="Build the unit tests") @@ -208,7 +226,7 @@ class Acts(CMakePackage, CudaPackage): "autodiff", default=False, description="Build the auto-differentiation plugin", - when="@1.2:", + when="@1.2:32", ) variant("dd4hep", default=False, description="Build the DD4hep plugin", when="+tgeo") variant( @@ -226,7 +244,10 @@ class Acts(CMakePackage, CudaPackage): when="@0.16:", ) variant("fatras_geant4", default=False, description="Build Geant4 Fatras package") - variant("identification", default=False, description="Build the Identification plugin") + variant("geomodel", default=False, description="Build GeoModel plugin", when="@33:") + variant( + "identification", default=False, description="Build the Identification plugin", when="@:34" + ) variant("json", default=False, description="Build the Json plugin") variant("legacy", default=False, description="Build the Legacy package") variant("mlpack", default=False, description="Build MLpack plugin", when="@25:31") @@ -245,12 +266,18 @@ class Acts(CMakePackage, CudaPackage): description="Enable memory profiling using gperftools", when="@19.3:", ) - variant("sycl", default=False, description="Build the SyCL plugin", when="@1:") - variant("tgeo", default=False, description="Build the TGeo plugin", when="+identification") + variant("sycl", default=False, description="Build the SyCL plugin", when="@1:34") + variant( + "tgeo", default=False, description="Build the TGeo plugin", when="@:34 +identification" + ) + variant("tgeo", default=False, description="Build the TGeo plugin", when="@35:") # Variants that only affect Acts examples for now variant( - "binaries", default=False, description="Build the examples binaries", when="@23: +examples" + "binaries", + default=False, + description="Build the examples binaries", + when="@23:32 +examples", ) variant( "edm4hep", @@ -301,6 +328,7 @@ class Acts(CMakePackage, CudaPackage): depends_on("actsvg@0.4.33:", when="@25:27") depends_on("actsvg@0.4.35:", when="@28:") depends_on("actsvg@0.4.39:", when="@32:") + depends_on("actsvg@0.4.40:", when="@32.1:") depends_on("autodiff @0.6:", when="@17: +autodiff") depends_on("autodiff @0.5.11:0.5.99", when="@1.2:16 +autodiff") depends_on("boost @1.62:1.69 +program_options +test", when="@:0.10.3") @@ -331,10 +359,7 @@ class Acts(CMakePackage, CudaPackage): depends_on("python@3.8:", when="+python @19.11:19") depends_on("python@3.8:", when="+python @21:") depends_on("py-onnxruntime@:1.12", when="+onnx @:23.2") - # FIXME py-onnxruntime@1.12: required but not yet available - # Ref: https://github.com/spack/spack/pull/37064 - # depends_on("py-onnxruntime@1.12:", when="+onnx @23.3:") - conflicts("+onnx", when="@23.3:", msg="py-onnxruntime@1.12: required but not yet available") + depends_on("py-onnxruntime@1.12:", when="+onnx @23.3:") depends_on("py-pybind11 @2.6.2:", when="+python @18:") depends_on("py-pytest", when="+python +unit_tests") @@ -416,6 +441,7 @@ def plugin_cmake_variant(plugin_name, spack_variant): cmake_variant("FATRAS_GEANT4", "fatras_geant4"), example_cmake_variant("GEANT4", "geant4"), plugin_cmake_variant("GEANT4", "geant4"), + plugin_cmake_variant("GEOMODEL", "geomodel"), example_cmake_variant("HEPMC3", "hepmc3"), plugin_cmake_variant("IDENTIFICATION", "identification"), cmake_variant(integration_tests_label, "integration_tests"), @@ -469,6 +495,8 @@ def plugin_cmake_variant(plugin_name, spack_variant): cuda_arch = spec.variants["cuda_arch"].value if cuda_arch != "none": args.append(f"-DCUDA_FLAGS=-arch=sm_{cuda_arch[0]}") + arch_str = ";".join(self.spec.variants["cuda_arch"].value) + args.append(self.define("CMAKE_CUDA_ARCHITECTURES", arch_str)) args.append(self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd")) diff --git a/var/spack/repos/builtin/packages/actsvg/package.py b/var/spack/repos/builtin/packages/actsvg/package.py index 78eaa5597aeb73..f0e8bc66cdf783 100644 --- a/var/spack/repos/builtin/packages/actsvg/package.py +++ b/var/spack/repos/builtin/packages/actsvg/package.py @@ -16,10 +16,15 @@ class Actsvg(CMakePackage): list_url = "https://github.com/acts-project/actsvg/tags" git = "https://github.com/acts-project/actsvg.git" - maintainers("HadrienG2", "wdconinc") + maintainers("wdconinc", "stephenswat") license("MPL-2.0") + version("0.4.44", sha256="6eda7306b8b863e1860e090f328ac6e7982dc2d3b3d674db2799c13007ffd07f") + version("0.4.43", sha256="e2aef32185db37cfdc023282b25c003e63dc974a11118ab2040bd30b2d346147") + version("0.4.42", sha256="a8439d50b469ccc4428973507db1adf56aa68b34900ce0c6077ddb92a133a4f2") + version("0.4.41", sha256="c675795e74efcf42c3015d6efc8d7a1848b677f1d4efe6dcaa4fb490b46268ff") + version("0.4.40", sha256="e24f51e70cff57c74d3b5f51c08f6ea1f409ef85ef7b4bad4a29520ecda032a6") version("0.4.39", sha256="2d9605ecf8c9975d600cafb6d076969d77c634fa92844bd9586c38066da31739") version("0.4.35", sha256="693a4cc0e702842072a478c913895ed3596350ffdfa87f5d296ddd6ea36b61c6") version("0.4.33", sha256="25c93b8382bdb1864b4d8de64b146fe8ea86eec84048d594c375700d2fff1d1d") diff --git a/var/spack/repos/builtin/packages/additivefoam/package.py b/var/spack/repos/builtin/packages/additivefoam/package.py index 7e7d3735ef6b43..3fed737361fb82 100644 --- a/var/spack/repos/builtin/packages/additivefoam/package.py +++ b/var/spack/repos/builtin/packages/additivefoam/package.py @@ -25,6 +25,8 @@ class Additivefoam(Package): version("main", branch="main") version("1.0.0", sha256="abbdf1b0230cd2f26f526be76e973f508978611f404fe8ec4ecdd7d5df88724c") + depends_on("cxx", type="build") # generated + depends_on("openfoam-org@10") common = ["spack-derived-Allwmake"] diff --git a/var/spack/repos/builtin/packages/addrwatch/package.py b/var/spack/repos/builtin/packages/addrwatch/package.py index e04575b2e2a4f7..1db0d0af4aac49 100644 --- a/var/spack/repos/builtin/packages/addrwatch/package.py +++ b/var/spack/repos/builtin/packages/addrwatch/package.py @@ -18,5 +18,7 @@ class Addrwatch(AutotoolsPackage): version("1.0.2", sha256="f04e143da881cd63c299125b592cfb85e4812abbd146f419a1894c00f2ae6208") version("1.0.1", sha256="f772b62b1c6570b577473e7c98614dad1124352b377324cbebb36360d8f4ce5a") + depends_on("c", type="build") # generated + depends_on("libevent") depends_on("libpcap") diff --git a/var/spack/repos/builtin/packages/adept-utils/package.py b/var/spack/repos/builtin/packages/adept-utils/package.py index 5a542e3ab81d73..921b09076b517b 100644 --- a/var/spack/repos/builtin/packages/adept-utils/package.py +++ b/var/spack/repos/builtin/packages/adept-utils/package.py @@ -15,6 +15,9 @@ class AdeptUtils(CMakePackage): version("1.0.1", sha256="259f777aeb368ede3583d3617bb779f0fde778319bf2122fdd216bdf223c015e") version("1.0", sha256="fed29366c9bcf5f3799220ae3b351d2cb338e2aa42133d61584ea650aa8d6ff7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost@:1.72.0") depends_on("mpi") depends_on("cmake@2.8:", type="build") diff --git a/var/spack/repos/builtin/packages/adiak/package.py b/var/spack/repos/builtin/packages/adiak/package.py index c9640c586e6e95..e1ad9344c17153 100644 --- a/var/spack/repos/builtin/packages/adiak/package.py +++ b/var/spack/repos/builtin/packages/adiak/package.py @@ -34,6 +34,10 @@ class Adiak(CMakePackage): version("0.2.1", commit="950e3bfb91519ecb7b7ee7fa3063bfab23c0e2c9", submodules=True) version("0.1.1", sha256="438e4652e15e206cd0019423d829fd4f2329323ff0c8861d9586bae051d9624b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi", when="+mpi") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/adios/package.py b/var/spack/repos/builtin/packages/adios/package.py index 3b5e3bcbe19072..88536258c713ad 100644 --- a/var/spack/repos/builtin/packages/adios/package.py +++ b/var/spack/repos/builtin/packages/adios/package.py @@ -28,6 +28,10 @@ class Adios(AutotoolsPackage): version("1.10.0", sha256="6713069259ee7bfd4d03f47640bf841874e9114bab24e7b0c58e310c42a0ec48") version("1.9.0", sha256="23b2bb70540d51ab0855af0b205ca484fd1bd963c39580c29e3133f9e6fffd46") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Builds a shared version of the library") variant("fortran", default=False, description="Enable Fortran bindings support") diff --git a/var/spack/repos/builtin/packages/adios2/2.10-enable-rocm6.patch b/var/spack/repos/builtin/packages/adios2/2.10-enable-rocm6.patch new file mode 100644 index 00000000000000..abd69a9d99f7e2 --- /dev/null +++ b/var/spack/repos/builtin/packages/adios2/2.10-enable-rocm6.patch @@ -0,0 +1,28 @@ +From c718e99a9e226b7327ab41396823873999206e38 Mon Sep 17 00:00:00 2001 +From: Vicente Adolfo Bolea Sanchez +Date: Thu, 27 Jun 2024 18:25:58 -0400 +Subject: [PATCH] kokkos: support ROCM >=6 + +--- + source/adios2/helper/kokkos/adiosKokkos.cpp | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/source/adios2/helper/kokkos/adiosKokkos.cpp b/source/adios2/helper/kokkos/adiosKokkos.cpp +index e0599944e..d2619f0d4 100644 +--- a/source/adios2/helper/kokkos/adiosKokkos.cpp ++++ b/source/adios2/helper/kokkos/adiosKokkos.cpp +@@ -85,7 +85,11 @@ bool IsGPUbuffer(const void *ptr) + hipError_t ret; + hipPointerAttribute_t attr; + ret = hipPointerGetAttributes(&attr, ptr); ++#if defined(ROCM_VERSION_MAJOR) && ROCM_VERSION_MAJOR < 6 + if (ret == hipSuccess && attr.memoryType == hipMemoryTypeDevice) ++#else ++ if (ret == hipSuccess && attr.type == hipMemoryTypeDevice) ++#endif + { + return true; + } +-- +2.35.3 + diff --git a/var/spack/repos/builtin/packages/adios2/2.7-fix-missing-cstdint-include.patch b/var/spack/repos/builtin/packages/adios2/2.7-fix-missing-cstdint-include.patch new file mode 100644 index 00000000000000..6b90d21005d318 --- /dev/null +++ b/var/spack/repos/builtin/packages/adios2/2.7-fix-missing-cstdint-include.patch @@ -0,0 +1,24 @@ +From abbe0f81d78403a62444b1a76222b9a226fd17c6 Mon Sep 17 00:00:00 2001 +From: Vicente Adolfo Bolea Sanchez +Date: Mon, 22 Apr 2024 20:52:49 -0700 +Subject: [PATCH] fix py11bind stdint dep + +--- + thirdparty/pybind11/pybind11/include/pybind11/pybind11.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/thirdparty/pybind11/pybind11/include/pybind11/pybind11.h b/thirdparty/pybind11/pybind11/include/pybind11/pybind11.h +index fa98f7c18..6992c3d55 100644 +--- a/thirdparty/pybind11/pybind11/include/pybind11/pybind11.h ++++ b/thirdparty/pybind11/pybind11/include/pybind11/pybind11.h +@@ -47,6 +47,7 @@ + #include "detail/class.h" + #include "detail/init.h" + ++#include + #include + #include + #include +-- +2.35.3 + diff --git a/var/spack/repos/builtin/packages/adios2/package.py b/var/spack/repos/builtin/packages/adios2/package.py index 567c08dc6a5c1d..7a263b5a1c9d2d 100644 --- a/var/spack/repos/builtin/packages/adios2/package.py +++ b/var/spack/repos/builtin/packages/adios2/package.py @@ -26,13 +26,12 @@ class Adios2(CMakePackage, CudaPackage, ROCmPackage): version("master", branch="master") version( - "2.10.0-rc1", sha256="8b72142bd5aabfb80c7963f524df11b8721c09ef20caea6df5fb00c31a7747c0" - ) - version( - "2.9.2", - sha256="78309297c82a95ee38ed3224c98b93d330128c753a43893f63bbe969320e4979", + "2.10.1", + sha256="ce776f3a451994f4979c6bd6d946917a749290a37b7433c0254759b02695ad85", preferred=True, ) + version("2.10.0", sha256="e5984de488bda546553dd2f46f047e539333891e63b9fe73944782ba6c2d95e4") + version("2.9.2", sha256="78309297c82a95ee38ed3224c98b93d330128c753a43893f63bbe969320e4979") version("2.9.1", sha256="ddfa32c14494250ee8a48ef1c97a1bf6442c15484bbbd4669228a0f90242f4f9") version("2.9.0", sha256="69f98ef58c818bb5410133e1891ac192653b0ec96eb9468590140f2552b6e5d1") version("2.8.3", sha256="4906ab1899721c41dd918dddb039ba2848a1fb0cf84f3a563a1179b9d6ee0d9f") @@ -46,6 +45,10 @@ class Adios2(CMakePackage, CudaPackage, ROCmPackage): version("2.4.0", sha256="50ecea04b1e41c88835b4b3fd4e7bf0a0a2a3129855c9cc4ba6cf6a1575106e2") version("2.3.1", sha256="3bf81ccc20a7f2715935349336a76ba4c8402355e1dc3848fcd6f4c3c5931893") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # There's not really any consistency about how static and shared libs are # implemented across spack. What we're trying to support is specifically three # library build types: @@ -84,6 +87,7 @@ class Adios2(CMakePackage, CudaPackage, ROCmPackage): when="+shared", description="Enable the DataMan engine for WAN transports", ) + variant("campaign", default=False, when="@2.10:", description="Enable campaign management") variant("dataspaces", default=False, when="@2.5:", description="Enable support for DATASPACES") variant("ssc", default=True, when="@:2.7", description="Enable the SSC staging engine") variant("hdf5", default=False, description="Enable the HDF5 engine") @@ -149,7 +153,7 @@ class Adios2(CMakePackage, CudaPackage, ROCmPackage): conflicts("+rocm", when="~kokkos", msg="ADIOS2 does not support HIP without Kokkos") conflicts("+sycl", when="~kokkos", msg="ADIOS2 does not support SYCL without Kokkos") - for _platform in ["linux", "darwin", "cray"]: + for _platform in ["linux", "darwin"]: depends_on("pkgconfig", type="build", when=f"platform={_platform}") variant( "pic", @@ -175,6 +179,8 @@ class Adios2(CMakePackage, CudaPackage, ROCmPackage): depends_on("hdf5~mpi", when="+hdf5~mpi") depends_on("hdf5+mpi", when="+hdf5+mpi") + depends_on("sqlite@3", when="+campaign") + depends_on("libpressio", when="+libpressio") depends_on("c-blosc", when="+blosc") depends_on("c-blosc2", when="+blosc2") @@ -211,6 +217,9 @@ class Adios2(CMakePackage, CudaPackage, ROCmPackage): # See https://github.com/ornladios/ADIOS2/pull/2714 patch("2.6-fix-gcc10-symbols.patch", when="@2.6.0") + # add missing include + patch("2.7-fix-missing-cstdint-include.patch", when="@2.7") + # Add missing include # https://github.com/ornladios/adios2/pull/2710 patch( @@ -225,7 +234,11 @@ class Adios2(CMakePackage, CudaPackage, ROCmPackage): # cmake: find threads package first # https://github.com/ornladios/ADIOS2/pull/3893 - patch("2.9.2-cmake-find-threads-package-first.patch", when="@2.9.2:") + patch("2.9.2-cmake-find-threads-package-first.patch", when="@2.9") + + # ROCM: enable support for rocm >= 6 + # https://github.com/ornladios/ADIOS2/pull/4214 + patch("2.10-enable-rocm6.patch", when="@2.9.1:") @when("%fj") def patch(self): @@ -253,6 +266,7 @@ def cmake_args(self): from_variant("ADIOS2_USE_Blosc", "blosc"), from_variant("ADIOS2_USE_Blosc2", "blosc2"), from_variant("ADIOS2_USE_BZip2", "bzip2"), + from_variant("ADIOS2_USE_Campaign", "campaign"), from_variant("ADIOS2_USE_DataMan", "dataman"), from_variant("ADIOS2_USE_DataSpaces", "dataspaces"), from_variant("ADIOS2_USE_Fortran", "fortran"), diff --git a/var/spack/repos/builtin/packages/adlbx/package.py b/var/spack/repos/builtin/packages/adlbx/package.py index 8e8bddbfd80793..b8d45aa5868cd1 100644 --- a/var/spack/repos/builtin/packages/adlbx/package.py +++ b/var/spack/repos/builtin/packages/adlbx/package.py @@ -19,6 +19,8 @@ class Adlbx(AutotoolsPackage): version("0.9.2", sha256="524902d648001b689a98492402d754a607b8c1d0734699154063c1a4f3410d4a") version("0.9.1", sha256="8913493fe0c097ff13c721ab057514e5bdb55f6318d4e3512692ab739c3190b3") + depends_on("c", type="build") # generated + depends_on("exmcutils@master", when="@master") depends_on("exmcutils@:0.5.7", when="@:0.9.2") depends_on("exmcutils", when="@0.9.1:") diff --git a/var/spack/repos/builtin/packages/admixtools/package.py b/var/spack/repos/builtin/packages/admixtools/package.py index 434ee26ecf3f35..396c5539770b32 100644 --- a/var/spack/repos/builtin/packages/admixtools/package.py +++ b/var/spack/repos/builtin/packages/admixtools/package.py @@ -23,6 +23,8 @@ class Admixtools(MakefilePackage): version("1.0.1", sha256="ef3afff161e6a24c0857678373138edb1251c24d7b5308a07f10bdb0dedd44d0") version("1.0", sha256="cf0d6950285e801e8a99c2a0b3dbbbc941a78e867af1767b1d002ec3f5803c4b") + depends_on("c", type="build") # generated + depends_on("lapack") depends_on("gsl") diff --git a/var/spack/repos/builtin/packages/adms/package.py b/var/spack/repos/builtin/packages/adms/package.py index fac47fa602c0eb..e76aac4aa70e72 100644 --- a/var/spack/repos/builtin/packages/adms/package.py +++ b/var/spack/repos/builtin/packages/adms/package.py @@ -23,6 +23,8 @@ class Adms(AutotoolsPackage): version("master", branch="master") version("2.3.7", sha256="3a78e1283ecdc3f356410474b3ff44c4dcc82cb89772087fd3bbde8a1038ce08") + depends_on("c", type="build") # generated + depends_on("bison@2.5:", type="build") depends_on("flex", type="build") depends_on("perl-xml-libxml", type="build") diff --git a/var/spack/repos/builtin/packages/adol-c/package.py b/var/spack/repos/builtin/packages/adol-c/package.py index 749adc5e3ed98e..44567d936b93bd 100644 --- a/var/spack/repos/builtin/packages/adol-c/package.py +++ b/var/spack/repos/builtin/packages/adol-c/package.py @@ -30,6 +30,9 @@ class AdolC(AutotoolsPackage): version("2.5.1", sha256="dedb93c3bb291366d799014b04b6d1ec63ca4e7216edf16167776c07961e3b4a") version("2.5.0", sha256="9d51c426d831884aac8f418be410c001eb62f3a11cb8f30c66af0b842edffb96") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "advanced_branching", default=False, diff --git a/var/spack/repos/builtin/packages/advancecomp/package.py b/var/spack/repos/builtin/packages/advancecomp/package.py index e9d2b348d60937..7d28e0bd2cd9a0 100644 --- a/var/spack/repos/builtin/packages/advancecomp/package.py +++ b/var/spack/repos/builtin/packages/advancecomp/package.py @@ -22,6 +22,9 @@ class Advancecomp(AutotoolsPackage): version("1.23", sha256="fe89d6ab382efc6b6be536b8d58113f36b83d82783d5215c261c14374cba800a") version("1.22", sha256="b8c482027a5f78d9a7f871cbba19cc896ed61653d1d93034c9dbe55484952605") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/aegean/package.py b/var/spack/repos/builtin/packages/aegean/package.py index c466ec07cf27fe..3ba9b902331b73 100644 --- a/var/spack/repos/builtin/packages/aegean/package.py +++ b/var/spack/repos/builtin/packages/aegean/package.py @@ -20,6 +20,8 @@ class Aegean(MakefilePackage): version("0.16.0", sha256="c6303ec58289f6c7bc4dd0edcd0e6c0bce4d95b21e25386f314f2b5e2f835812") version("0.15.2", sha256="734c9dd23ab3415c3966083bfde5fb72c81e6ace84e08ee3fe0d4c338331d975") + depends_on("c", type="build") # generated + depends_on("genometools") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/aeskeyfind/package.py b/var/spack/repos/builtin/packages/aeskeyfind/package.py index 5b8912c52d7e28..a0d6373792f764 100644 --- a/var/spack/repos/builtin/packages/aeskeyfind/package.py +++ b/var/spack/repos/builtin/packages/aeskeyfind/package.py @@ -15,6 +15,8 @@ class Aeskeyfind(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("aeskeyfind", prefix.bin) diff --git a/var/spack/repos/builtin/packages/aespipe/package.py b/var/spack/repos/builtin/packages/aespipe/package.py index 66580750f04d2f..9edfa7aba46b21 100644 --- a/var/spack/repos/builtin/packages/aespipe/package.py +++ b/var/spack/repos/builtin/packages/aespipe/package.py @@ -22,3 +22,5 @@ class Aespipe(AutotoolsPackage): version("2.4b", sha256="4f08611966998f66266f03d40d0597f94096164393c8f303b2dfd565e9d9b59d") version("2.3e", sha256="4e63a5709fdd0bffdb555582f9fd7a0bd1842e429420159accaf7f60c5d3c70f") version("2.3d", sha256="70330cd0710446c9ddf8148a7713fd73f1dc5e0b13fc4d3c75590305b2e3f008") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/agile/package.py b/var/spack/repos/builtin/packages/agile/package.py index e2f31ed2a4d4ce..25fb024eca94db 100644 --- a/var/spack/repos/builtin/packages/agile/package.py +++ b/var/spack/repos/builtin/packages/agile/package.py @@ -21,6 +21,10 @@ class Agile(AutotoolsPackage): version("1.5.1", sha256="e38536300060e4b845ccaaed824c7495944f9117a0d7e4ee74a18bf278e2012f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("hepmc") depends_on("boost") diff --git a/var/spack/repos/builtin/packages/agrep/package.py b/var/spack/repos/builtin/packages/agrep/package.py index 505a248f11edce..ef8711831388c6 100644 --- a/var/spack/repos/builtin/packages/agrep/package.py +++ b/var/spack/repos/builtin/packages/agrep/package.py @@ -20,6 +20,8 @@ class Agrep(MakefilePackage): version("3.41", sha256="0508eafaf9725fc67cc955eb6d32ba4f50138443a4fea4275508d2c3f67a234e") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("agrep", prefix.bin) diff --git a/var/spack/repos/builtin/packages/akantu/package.py b/var/spack/repos/builtin/packages/akantu/package.py index 46ebb5cec19aac..51addfaa1097bb 100644 --- a/var/spack/repos/builtin/packages/akantu/package.py +++ b/var/spack/repos/builtin/packages/akantu/package.py @@ -26,6 +26,9 @@ class Akantu(CMakePackage): version("master", branch="master") version("3.0.0", sha256="7e8f64e25956eba44def1b2d891f6db8ba824e4a82ff0d51d6b585b60ab465db") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "external_solvers", values=any_combination_of("mumps", "petsc"), diff --git a/var/spack/repos/builtin/packages/albany/package.py b/var/spack/repos/builtin/packages/albany/package.py index db7e3dbb02a45a..cfe0aaab7dc915 100644 --- a/var/spack/repos/builtin/packages/albany/package.py +++ b/var/spack/repos/builtin/packages/albany/package.py @@ -21,6 +21,8 @@ class Albany(CMakePackage): version("develop", branch="master") + depends_on("cxx", type="build") # generated + variant("lcm", default=True, description="Enable LCM") variant("aeras", default=False, description="Enable AERAS") variant("qcad", default=False, description="Enable QCAD") diff --git a/var/spack/repos/builtin/packages/albert/package.py b/var/spack/repos/builtin/packages/albert/package.py index 796a45fdf3fb24..9d27edeb6ff72a 100644 --- a/var/spack/repos/builtin/packages/albert/package.py +++ b/var/spack/repos/builtin/packages/albert/package.py @@ -16,6 +16,8 @@ class Albert(MakefilePackage): version("4.0a_opt4", sha256="80b9ee774789c9cd123072523cfb693c443c3624708a58a5af177a51f36b2c79") version("4.0a", sha256="caf49e24fb9bf2a09053d9bf022c4737ffe61d62ce9c6bc32aa03dded2a14913") + depends_on("cxx", type="build") # generated + depends_on("readline") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/alembic/package.py b/var/spack/repos/builtin/packages/alembic/package.py index b0f9ee6ac66b08..fd1ff6fe78f873 100644 --- a/var/spack/repos/builtin/packages/alembic/package.py +++ b/var/spack/repos/builtin/packages/alembic/package.py @@ -21,6 +21,8 @@ class Alembic(CMakePackage): version("1.8.5", sha256="180a12f08d391cd89f021f279dbe3b5423b1db751a9898540c8059a45825c2e9") version("1.7.16", sha256="2529586c89459af34d27a36ab114ad1d43dafd44061e65cfcfc73b7457379e7c") + depends_on("cxx", type="build") # generated + variant("python", default=False, description="Python support") variant("hdf5", default=False, description="HDF5 support") diff --git a/var/spack/repos/builtin/packages/alglib/package.py b/var/spack/repos/builtin/packages/alglib/package.py index 784dbfb73f1e2c..5d830bf43a0efd 100644 --- a/var/spack/repos/builtin/packages/alglib/package.py +++ b/var/spack/repos/builtin/packages/alglib/package.py @@ -21,6 +21,8 @@ class Alglib(MakefilePackage): version("3.20.0", sha256="e7357f0f894313ff1b640ec9cb5e8b63f06d2d3411c2143a374aa0e9740da8a9") version("3.11.0", sha256="34e391594aac89fb354bdaf58c42849489cd1199197398ba98bb69961f42bdb0") + depends_on("cxx", type="build") # generated + build_directory = "src" def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/allpaths-lg/package.py b/var/spack/repos/builtin/packages/allpaths-lg/package.py index f3be71e7a1e4b9..2a325cd3b7f5af 100644 --- a/var/spack/repos/builtin/packages/allpaths-lg/package.py +++ b/var/spack/repos/builtin/packages/allpaths-lg/package.py @@ -15,6 +15,8 @@ class AllpathsLg(AutotoolsPackage): version("52488", sha256="035b49cb21b871a6b111976757d7aee9c2513dd51af04678f33375e620998542") + depends_on("cxx", type="build") # generated + # compiles with gcc 4.7.0 to 4.9.4) conflicts("%gcc@:4.6.4,5.1.0:") conflicts("%cce") diff --git a/var/spack/repos/builtin/packages/alpaka/package.py b/var/spack/repos/builtin/packages/alpaka/package.py index 7a4b22c42065c8..e8e06fd4a9990e 100644 --- a/var/spack/repos/builtin/packages/alpaka/package.py +++ b/var/spack/repos/builtin/packages/alpaka/package.py @@ -25,6 +25,8 @@ class Alpaka(CMakePackage, CudaPackage): version("0.5.0", sha256="0ba08ea19961dd986160219ba00d6162fe7758980d88a606eff6494d7b3a6cd1") version("0.4.0", sha256="ad7905b13c22abcee4344ba225a65078e3f452ad45a9eda907e7d27c08315e46") + depends_on("cxx", type="build") # generated + variant( "backend", multi=True, diff --git a/var/spack/repos/builtin/packages/alquimia/package.py b/var/spack/repos/builtin/packages/alquimia/package.py index 5fb67270a82f61..c5ae05ac32e9f5 100644 --- a/var/spack/repos/builtin/packages/alquimia/package.py +++ b/var/spack/repos/builtin/packages/alquimia/package.py @@ -24,6 +24,10 @@ class Alquimia(CMakePackage): version("xsdk-0.6.0", commit="9a0aedd3a927d4d5e837f8fd18b74ad5a78c3821") version("xsdk-0.5.0", commit="8397c3b00a09534c5473ff3ab21f0e32bb159380") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/alsa-lib/package.py b/var/spack/repos/builtin/packages/alsa-lib/package.py index d9624e0dd46465..e13b3c30d17fbd 100644 --- a/var/spack/repos/builtin/packages/alsa-lib/package.py +++ b/var/spack/repos/builtin/packages/alsa-lib/package.py @@ -20,6 +20,8 @@ class AlsaLib(AutotoolsPackage): version("1.2.2", sha256="d8e853d8805574777bbe40937812ad1419c9ea7210e176f0def3e6ed255ab3ec") version("1.1.4.1", sha256="91bb870c14d1c7c269213285eeed874fa3d28112077db061a3af8010d0885b76") + depends_on("c", type="build") # generated + variant("python", default=False, description="enable python") patch("python.patch", when="@1.1.4:1.1.5 +python") diff --git a/var/spack/repos/builtin/packages/aluminum/package.py b/var/spack/repos/builtin/packages/aluminum/package.py index 63275c66ed9c5f..5c1fb482a3871e 100644 --- a/var/spack/repos/builtin/packages/aluminum/package.py +++ b/var/spack/repos/builtin/packages/aluminum/package.py @@ -33,6 +33,8 @@ class Aluminum(CachedCMakePackage, CudaPackage, ROCmPackage): version("1.3.0", sha256="d0442efbebfdfb89eec793ae65eceb8f1ba65afa9f2e48df009f81985a4c27e3") version("1.2.3", sha256="9b214bdf30f9b7e8e017f83e6615db6be2631f5be3dd186205dbe3aa62f4018a") + depends_on("cxx", type="build") # generated + # Library capabilities variant( "cuda_rma", diff --git a/var/spack/repos/builtin/packages/amber/package.py b/var/spack/repos/builtin/packages/amber/package.py index f72ce9bc4da690..88c830977a7b44 100644 --- a/var/spack/repos/builtin/packages/amber/package.py +++ b/var/spack/repos/builtin/packages/amber/package.py @@ -143,7 +143,6 @@ class Amber(Package, CudaPackage): depends_on("cuda@7.5.18", when="@:16+cuda") # conflicts - conflicts("+x11", when="platform=cray", msg="x11 amber applications not available for cray") conflicts("+openmp", when="%clang", msg="OpenMP not available for the clang compiler") conflicts( "+openmp", when="%apple-clang", msg="OpenMP not available for the Apple clang compiler" diff --git a/var/spack/repos/builtin/packages/amdblis/package.py b/var/spack/repos/builtin/packages/amdblis/package.py index bf78a22b44a65c..27e713845fbb59 100644 --- a/var/spack/repos/builtin/packages/amdblis/package.py +++ b/var/spack/repos/builtin/packages/amdblis/package.py @@ -51,10 +51,17 @@ class Amdblis(BlisBase): version("3.0", sha256="ac848c040cd6c3550fe49148dbdf109216cad72d3235763ee7ee8134e1528517") version("2.2", sha256="e1feb60ac919cf6d233c43c424f6a8a11eab2c62c2c6e3f2652c15ee9063c0c9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("ilp64", default=False, when="@3.0.1:", description="ILP64 support") variant("aocl_gemm", default=False, when="@4.1:", description="aocl_gemm support") variant("suphandling", default=True, description="Small Unpacked Kernel handling") + variant("logging", default=False, description="Enable AOCL DTL Logging") + variant("tracing", default=False, description="Enable AOCL DTL Tracing") + def configure_args(self): spec = self.spec args = super().configure_args() @@ -95,6 +102,20 @@ def configure_args(self): if spec.satisfies("@3.1:"): args.append("--disable-aocl-dynamic") + if spec.satisfies("+logging"): + filter_file( + "#define AOCL_DTL_LOG_ENABLE 0", + "#define AOCL_DTL_LOG_ENABLE 1", + f"{self.stage.source_path}/aocl_dtl/aocldtlcf.h", + ) + + if spec.satisfies("+tracing"): + filter_file( + "#define AOCL_DTL_TRACE_ENABLE 0", + "#define AOCL_DTL_TRACE_ENABLE 1", + f"{self.stage.source_path}/aocl_dtl/aocldtlcf.h", + ) + return args @run_after("install") diff --git a/var/spack/repos/builtin/packages/amdfftw/package.py b/var/spack/repos/builtin/packages/amdfftw/package.py index 56dcd091451543..3d5891c46e161b 100644 --- a/var/spack/repos/builtin/packages/amdfftw/package.py +++ b/var/spack/repos/builtin/packages/amdfftw/package.py @@ -54,6 +54,9 @@ class Amdfftw(FftwBase): version("3.0", sha256="a69deaf45478a59a69f77c4f7e9872967f1cfe996592dd12beb6318f18ea0bcd") version("2.2", sha256="de9d777236fb290c335860b458131678f75aa0799c641490c644c843f0e246f8") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Builds a shared version of the library") variant("openmp", default=True, description="Enable OpenMP support") variant("threads", default=False, description="Enable SMP threads support") diff --git a/var/spack/repos/builtin/packages/amdlibflame/package.py b/var/spack/repos/builtin/packages/amdlibflame/package.py index d63d7c57e864f8..2fed863a23bbfd 100644 --- a/var/spack/repos/builtin/packages/amdlibflame/package.py +++ b/var/spack/repos/builtin/packages/amdlibflame/package.py @@ -62,6 +62,10 @@ class Amdlibflame(CMakePackage, LibflameBase): version("3.0", sha256="d94e08b688539748571e6d4c1ec1ce42732eac18bd75de989234983c33f01ced") version("2.2", sha256="12b9c1f92d2c2fa637305aaa15cf706652406f210eaa5cbc17aaea9fcfa576dc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("ilp64", default=False, when="@3.0.1: ", description="Build with ILP64 support") variant( "enable-aocl-blas", @@ -79,6 +83,9 @@ class Amdlibflame(CMakePackage, LibflameBase): description="Use hardware vectorization support", ) + variant("logging", default="False", description="Enable AOCL DTL Logging") + variant("tracing", default="False", description="Enable AOCL DTL Tracing") + # Build system build_system( conditional("cmake", when="@4.2:"), conditional("autotools", when="@:4.1"), default="cmake" @@ -215,6 +222,20 @@ def configure_args(self): aocl_utils_lib_path = spec["aocl-utils"].libs args.append("LIBAOCLUTILS_LIBRARY_PATH={0}".format(aocl_utils_lib_path)) + if spec.satisfies("+tracing"): + filter_file( + "#define AOCL_DTL_TRACE_ENABLE 0", + "#define AOCL_DTL_TRACE_ENABLE 1", + f"{self.stage.source_path}/aocl_dtl/aocldtlcf.h", + ) + + if spec.satisfies("+logging"): + filter_file( + "#define AOCL_DTL_LOG_ENABLE 0", + "#define AOCL_DTL_LOG_ENABLE 1", + f"{self.stage.source_path}/aocl_dtl/aocldtlcf.h", + ) + return args @when("@4.1:") diff --git a/var/spack/repos/builtin/packages/amdlibm/libm-ose-SconsSpack.patch b/var/spack/repos/builtin/packages/amdlibm/libm-ose-SconsSpack.patch new file mode 100644 index 00000000000000..e90653d491a94b --- /dev/null +++ b/var/spack/repos/builtin/packages/amdlibm/libm-ose-SconsSpack.patch @@ -0,0 +1,10 @@ +--- a/scripts/site_scons/alm/env.py 2024-04-30 14:30:40.936684295 -0500 ++++ b/scripts/site_scons/alm/env.py 2024-04-30 14:31:10.901423863 -0500 +@@ -72,6 +72,7 @@ + 'SPACK_LINKER_ARG', + 'SPACK_SHORT_SPEC', + 'SPACK_SYSTEM_DIRS', ++ 'SPACK_MANAGED_DIRS', + ] + + # add these keys to mydict if they exist in environ diff --git a/var/spack/repos/builtin/packages/amdlibm/package.py b/var/spack/repos/builtin/packages/amdlibm/package.py index e0e0a36aaabb04..00fb03d94e270c 100644 --- a/var/spack/repos/builtin/packages/amdlibm/package.py +++ b/var/spack/repos/builtin/packages/amdlibm/package.py @@ -46,6 +46,9 @@ class Amdlibm(SConsPackage): version("3.0", sha256="eb26b5e174f43ce083928d0d8748a6d6d74853333bba37d50057aac2bef7c7aa") version("2.2", commit="4033e022da428125747e118ccd6fdd9cee21c470") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("verbose", default=False, description="Building with verbosity", when="@:4.1") # Mandatory dependencies @@ -58,6 +61,10 @@ class Amdlibm(SConsPackage): patch("0001-libm-ose-Scripts-cleanup-pyc-files.patch", when="@2.2") patch("0002-libm-ose-prevent-log-v3.c-from-building.patch", when="@2.2") + # Patch to update the SCons environment with + # the newly introduced 'SPACK_MANAGED_DIRS' + # build environment variable. + patch("libm-ose-SconsSpack.patch", when="@3.1:4.2") conflicts("%gcc@:9.1.0", msg="Minimum supported GCC version is 9.2.0") conflicts("%gcc@13.2.0:", msg="Maximum supported GCC version is 13.1.0") diff --git a/var/spack/repos/builtin/packages/amdscalapack/package.py b/var/spack/repos/builtin/packages/amdscalapack/package.py index aaa489a057b523..5f25811f6f451e 100644 --- a/var/spack/repos/builtin/packages/amdscalapack/package.py +++ b/var/spack/repos/builtin/packages/amdscalapack/package.py @@ -45,6 +45,9 @@ class Amdscalapack(ScalapackBase): version("3.0", sha256="6e6f3578f44a8e64518d276e7580530599ecfa8729f568303ed2590688e7096f") version("2.2", sha256="2d64926864fc6d12157b86e3f88eb1a5205e7fc157bf67e7577d0f18b9a7484c") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("ilp64", default=False, description="Build with ILP64 support") conflicts("+ilp64", when="@:3.0", msg="ILP64 is supported from 3.1 onwards") diff --git a/var/spack/repos/builtin/packages/amdsmi/package.py b/var/spack/repos/builtin/packages/amdsmi/package.py index 637e3e7a90e372..8185f27a0b0405 100644 --- a/var/spack/repos/builtin/packages/amdsmi/package.py +++ b/var/spack/repos/builtin/packages/amdsmi/package.py @@ -13,13 +13,16 @@ class Amdsmi(CMakePackage): applications to monitor and control AMD device.""" homepage = "https://github.com/ROCm/amdsmi" - url = "https://github.com/ROCm/amdsmi/archive/refs/tags/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/amdsmi/archive/refs/tags/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") libraries = ["libamd_smi"] license("MIT") + version("6.1.2", sha256="4583ea9bc71d55e987db4a42f9b3b730def22892953d30bca64ca29ac844e058") + version("6.1.1", sha256="10ece6b1ca8bb36ab3ae987fc512838f30a92ab788a2200410e9c1707fe0166b") + version("6.1.0", sha256="5bd1f150a2191b1703ff2670e40f6fed730f59f155623d6e43b7f64c39ae0967") version("6.0.2", sha256="aeadf07750def0325a0eaa29e767530b2ec94f3d45dc3b7452fd7a2493769428") version("6.0.0", sha256="2626e3af9d60dec245c61af255525a0c0841a73fb7ec2836477c0ce5793de39c") version("5.7.0", sha256="144391d537710dafa9ef69571dd76203e56db6142ab61a1375346b5733137e23") @@ -27,10 +30,11 @@ class Amdsmi(CMakePackage): version("5.5.1", sha256="b794c7fd562fd92f2c9f2bbdc2d5dded7486101fcd4598f2e8c3484c9a939281") version("5.5.0", sha256="dcfbd96e93afcf86b1261464e008e9ef7e521670871a1885e6eaffc7cdc8f555") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.11:") depends_on("python@3.6:") depends_on("py-virtualenv") - depends_on("llvm@14:") depends_on("pkgconfig") depends_on("libdrm") depends_on("py-pyyaml") diff --git a/var/spack/repos/builtin/packages/amduprof/package.py b/var/spack/repos/builtin/packages/amduprof/package.py index 8bd08ffb9f4ddb..ffd9ba5ccadba8 100644 --- a/var/spack/repos/builtin/packages/amduprof/package.py +++ b/var/spack/repos/builtin/packages/amduprof/package.py @@ -3,28 +3,31 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os + from spack.package import * class Amduprof(Package): - """AMD uProf ("MICRO-prof") is a software profiling analysis tool for - x86 applications running on Windows, Linux and FreeBSD operating systems - and provides event information unique to the AMD "Zen"-based processors - and AMD Instinct(tm) MI Series accelerators. - """ + """AMD uProf ("MICRO-prof") is a software profiling analysis tool for x86 + applications running on Windows, Linux and FreeBSD operating systems and + provides event information unique to the AMD "Zen"-based processors and AMD + Instinct(tm) MI Series accelerators. AMD uProf enables the developer to better + understand the limiters of application performance and evaluate + improvements.""" homepage = "https://developer.amd.com/amd-uprof/" - url = "https://download.amd.com/developer/eula/uprof/AMDuProf_Linux_x64_4.2.850.tar.bz2" + url = f"file://{os.getcwd()}/AMDuProf_Linux_x64_4.2.850.tar.bz2" + manual_download = True - maintainers("zzzoom") + maintainers("amd-toolchain-support") version("4.2.850", sha256="f2d7c4eb9ec9c32845ff8f19874c1e6bcb0fa8ab2c12e73addcbf23a6d1bd623") - # TODO: build Power Profiling driver on Linux - # TODO: ROCm for GPU tracing and profiling - # TODO: BCC and eBPF for OS tracing + depends_on("binutils@2.27:", type="run") conflicts("platform=darwin") + requires("target=x86_64:", msg="AMD uProf available only on x86_64") def install(self, spec, prefix): install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/amg2013/package.py b/var/spack/repos/builtin/packages/amg2013/package.py index dbb5ded532cbfd..adbe89e12f135d 100644 --- a/var/spack/repos/builtin/packages/amg2013/package.py +++ b/var/spack/repos/builtin/packages/amg2013/package.py @@ -24,6 +24,8 @@ class Amg2013(MakefilePackage): version("1.1", tag="1.1", commit="09fe8a78baf6ba5eaef7d2804f7b653885d60fee") version("1.0", tag="1.0", commit="f5b864708ca3ef48a86e1e46fcb812cbbfa80c51") + depends_on("c", type="build") # generated + variant("openmp", default=True, description="Build with OpenMP support") variant("optflags", default=False, description="Additional optimizations") variant("int64", default=False, description="Use 64-bit integers for global variables") diff --git a/var/spack/repos/builtin/packages/amg2023/package.py b/var/spack/repos/builtin/packages/amg2023/package.py index 60bf0f337d04f5..cb46c9df3f66a4 100644 --- a/var/spack/repos/builtin/packages/amg2023/package.py +++ b/var/spack/repos/builtin/packages/amg2023/package.py @@ -21,6 +21,8 @@ class Amg2023(CMakePackage, CudaPackage, ROCmPackage): version("develop", branch="main") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("openmp", default=False, description="Enable OpenMP support") variant("caliper", default=False, description="Enable Caliper monitoring") diff --git a/var/spack/repos/builtin/packages/amgx/package.py b/var/spack/repos/builtin/packages/amgx/package.py index 1e91250708515e..332cc3cd9ed850 100644 --- a/var/spack/repos/builtin/packages/amgx/package.py +++ b/var/spack/repos/builtin/packages/amgx/package.py @@ -29,6 +29,9 @@ class Amgx(CMakePackage, CudaPackage): version("2.0.1", sha256="6f9991f1836fbf4ba2114ce9f49febd0edc069a24f533bd94fd9aa9be72435a7") version("2.0.0", sha256="8ec7ea8412be3de216fcf7243c4e2a8bcf76878e6865468e4238630a082a431b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cuda", default=True, description="Build with CUDA") variant("mpi", default=True, description="Enable MPI support") variant("mkl", default=False, description="Enable MKL support") diff --git a/var/spack/repos/builtin/packages/aml/package.py b/var/spack/repos/builtin/packages/aml/package.py index dee1c1ca0e8dd9..3974d2689a6e58 100644 --- a/var/spack/repos/builtin/packages/aml/package.py +++ b/var/spack/repos/builtin/packages/aml/package.py @@ -41,6 +41,8 @@ class Aml(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + # Generate possible variants. ############################# diff --git a/var/spack/repos/builtin/packages/ampliconnoise/package.py b/var/spack/repos/builtin/packages/ampliconnoise/package.py index 0bc5e2cc190c1b..5984a13b28289b 100644 --- a/var/spack/repos/builtin/packages/ampliconnoise/package.py +++ b/var/spack/repos/builtin/packages/ampliconnoise/package.py @@ -17,6 +17,8 @@ class Ampliconnoise(MakefilePackage): version("1.29", sha256="0bf946806d77ecaf0994ad8ebf9a5e98ad33c809f6def5c9340a16c367918167") + depends_on("c", type="build") # generated + depends_on("mpi@2:") depends_on("gsl") diff --git a/var/spack/repos/builtin/packages/amqp-cpp/package.py b/var/spack/repos/builtin/packages/amqp-cpp/package.py index 714169e1d61275..4123c2fab97d8f 100644 --- a/var/spack/repos/builtin/packages/amqp-cpp/package.py +++ b/var/spack/repos/builtin/packages/amqp-cpp/package.py @@ -22,6 +22,8 @@ class AmqpCpp(CMakePackage): version("4.3.24", sha256="c3312f8af813cacabf6c257dfaf41bf9e66606bbf7d62d085a9b7da695355245") version("4.3.19", sha256="ca29bb349c498948576a4604bed5fd3c27d87240b271a4441ccf04ba3797b31d") + depends_on("cxx", type="build") # generated + variant( "tcp", default=False, diff --git a/var/spack/repos/builtin/packages/amr-wind/package.py b/var/spack/repos/builtin/packages/amr-wind/package.py index cdd01679469ae2..b3875753bcf2ee 100644 --- a/var/spack/repos/builtin/packages/amr-wind/package.py +++ b/var/spack/repos/builtin/packages/amr-wind/package.py @@ -11,6 +11,7 @@ class AmrWind(CMakePackage, CudaPackage, ROCmPackage): incompressible flow sover for wind turbine and wind farm simulations.""" homepage = "https://github.com/Exawind/amr-wind" + url = "https://github.com/Exawind/amr-wind/archive/refs/tags/v1.3.0.tar.gz" git = "https://github.com/Exawind/amr-wind.git" maintainers("jrood-nrel", "psakievich") @@ -20,50 +21,109 @@ class AmrWind(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("main", branch="main", submodules=True) - - variant("hypre", default=True, description="Enable Hypre integration") + version( + "2.1.0", tag="v2.1.0", commit="bc787f21deca9239928182e27400133934c62658", submodules=True + ) + version( + "2.0.0", tag="v2.0.0", commit="ea448365033fc6bc9ee0febeb369b377f4fd8240", submodules=True + ) + version( + "1.4.0", tag="v1.4.0", commit="bdddf133e41a9b7b4c8ce28f1ea1bebec47678f5", submodules=True + ) + version( + "1.3.1", tag="v1.3.1", commit="63692889143599de57232e64a9c7e4af8f0a2e1e", submodules=True + ) + version( + "1.3.0", tag="v1.3.0", commit="f74d7b3801f0492e586d440fac729d9dec595a8b", submodules=True + ) + version( + "1.2.1", tag="v1.2.1", commit="7291737434ca339ecc765355eab88ddd529ff68f", submodules=True + ) + version( + "1.2.0", tag="v1.2.0", commit="db9add5c1c68583a9019cb7ba6776bd580b0ab3e", submodules=True + ) + version( + "1.1.0", tag="v1.1.0", commit="30396bf70f0bd5ac65dd0f7b29757b0e02b22459", submodules=True + ) + version( + "1.0.1", tag="v1.0.1", commit="aa9b7e8e63833e6ac1cc3f60fcba5140416cc139", submodules=True + ) + version( + "1.0.0", tag="v1.0.0", commit="885f4137ce7b9e6c60f48aa5e4c1a54f1418ea9e", submodules=True + ) + version( + "0.9.0", tag="v0.9.0", commit="cf66ebe31fd5f27b76a83451cd22f346e7a67160", submodules=True + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("hypre", default=False, description="Enable Hypre integration") variant("ascent", default=False, description="Enable Ascent integration") variant("masa", default=False, description="Enable MASA integration") variant("mpi", default=True, description="Enable MPI support") - variant("netcdf", default=True, description="Enable NetCDF support") + variant("netcdf", default=False, description="Enable NetCDF support") variant("openfast", default=False, description="Enable OpenFAST integration") variant("openmp", default=False, description="Enable OpenMP for CPU builds") variant("shared", default=True, description="Build shared libraries") variant("tests", default=True, description="Activate regression tests") variant("tiny_profile", default=False, description="Activate tiny profile") + variant("hdf5", default=False, description="Enable HDF5 plots with ZFP compression") + variant("umpire", default=False, description="Enable UMPIRE memory pooling") + variant("sycl", default=False, description="Enable SYCL backend") + variant("gpu-aware-mpi", default=False, description="Enable GPU aware MPI") + variant("helics", default=False, description="Enable HELICS support for control interface") + variant( + "waves2amr", default=False, description="Enable Waves2AMR support for ocean wave input" + ) + depends_on("mpi", when="+mpi") + depends_on("hdf5~mpi", when="+hdf5~mpi") + depends_on("hdf5+mpi", when="+hdf5+mpi") + depends_on("h5z-zfp", when="+hdf5") + depends_on("zfp", when="+hdf5") depends_on("hypre~int64@2.20.0:", when="+hypre") depends_on("hypre+mpi", when="+hypre+mpi") + depends_on("hypre+umpire", when="+hypre+umpire") + depends_on("hypre+sycl", when="+hypre+sycl") + depends_on("hypre+gpu-aware-mpi", when="+hypre+gpu-aware-mpi") + depends_on("hypre@2.29.0:", when="@0.9.0:+hypre") + depends_on("masa", when="+masa") + depends_on("ascent~mpi", when="+ascent~mpi") + depends_on("ascent+mpi", when="+ascent+mpi") + depends_on("netcdf-c", when="+netcdf") + depends_on("py-matplotlib", when="+masa") + depends_on("py-pandas", when="+masa") + depends_on("openfast+cxx", when="+openfast") + depends_on("openfast+netcdf", when="+openfast+netcdf") + depends_on("openfast@2.6.0:3.4.1", when="@0.9.0:1 +openfast") + depends_on("openfast@3.5:", when="@2: +openfast") + depends_on("helics@:3.3.2", when="+helics") + depends_on("helics@:3.3.2+mpi", when="+helics+mpi") + depends_on("fftw", when="@2.1: +waves2amr") + for arch in CudaPackage.cuda_arch_values: depends_on("hypre+cuda cuda_arch=%s" % arch, when="+cuda+hypre cuda_arch=%s" % arch) for arch in ROCmPackage.amdgpu_targets: depends_on( "hypre+rocm amdgpu_target=%s" % arch, when="+rocm+hypre amdgpu_target=%s" % arch ) - depends_on("masa", when="+masa") - - # propagate variants to ascent - depends_on("ascent~mpi", when="+ascent~mpi") - depends_on("ascent+mpi", when="+ascent+mpi") for arch in CudaPackage.cuda_arch_values: depends_on("ascent+cuda cuda_arch=%s" % arch, when="+ascent+cuda cuda_arch=%s" % arch) - depends_on("mpi", when="+mpi") - depends_on("netcdf-c", when="+netcdf") - depends_on("openfast+cxx@2.6.0:", when="+openfast") - depends_on("py-matplotlib", when="+masa") - depends_on("py-pandas", when="+masa") - conflicts("+openmp", when="+cuda") conflicts("+shared", when="+cuda") + conflicts("@:2.0", when="+waves2amr") def setup_build_environment(self, env): # Avoid compile errors with Intel interprocedural optimization - if "%intel" in self.spec: + if self.spec.satisfies("%intel"): env.append_flags("CXXFLAGS", "-no-ipo") def cmake_args(self): define = self.define + spec = self.spec vs = [ "mpi", @@ -85,19 +145,50 @@ def cmake_args(self): self.define_from_variant("BUILD_SHARED_LIBS", "shared"), ] - if "+mpi" in self.spec: - args.append(define("MPI_HOME", self.spec["mpi"].prefix)) + if spec.satisfies("+mpi"): + args.append(define("MPI_HOME", spec["mpi"].prefix)) - if "+cuda" in self.spec: + if spec.satisfies("+hdf5"): + args.append(define("AMR_WIND_ENABLE_HDF5", True)) + args.append(define("AMR_WIND_ENABLE_HDF5_ZFP", True)) + # Help AMReX understand if HDF5 is parallel or not. + # Building HDF5 with CMake as Spack does, causes this inspection to break. + args.append(define("HDF5_IS_PARALLEL", spec.satisfies("+mpi"))) + + if spec.satisfies("+cuda"): amrex_arch = [ - "{0:.1f}".format(float(i) / 10.0) for i in self.spec.variants["cuda_arch"].value + "{0:.1f}".format(float(i) / 10.0) for i in spec.variants["cuda_arch"].value ] if amrex_arch: args.append(define("AMReX_CUDA_ARCH", amrex_arch)) - if "+rocm" in self.spec: - args.append(define("CMAKE_CXX_COMPILER", self.spec["hip"].hipcc)) - targets = self.spec.variants["amdgpu_target"].value + if spec.satisfies("+rocm"): + args.append(define("CMAKE_CXX_COMPILER", spec["hip"].hipcc)) + targets = spec.variants["amdgpu_target"].value args.append("-DAMReX_AMD_ARCH=" + ";".join(str(x) for x in targets)) + if spec.satisfies("+umpire"): + args.append(self.define_from_variant("AMR_WIND_ENABLE_UMPIRE", "umpire")) + args.append(define("UMPIRE_DIR", spec["umpire"].prefix)) + + if spec.satisfies("+helics"): + args.append(self.define_from_variant("AMR_WIND_ENABLE_HELICS", "helics")) + args.append(define("HELICS_DIR", spec["helics"].prefix)) + + if spec.satisfies("+waves2amr"): + args.append(self.define_from_variant("AMR_WIND_ENABLE_W2A", "waves2amr")) + args.append(define("FFTW_DIR", spec["fftw"].prefix)) + + if spec.satisfies("+sycl"): + args.append(define("AMR_WIND_ENABLE_SYCL", True)) + requires( + "%dpcpp", + "%oneapi", + policy="one_of", + msg=( + "AMReX's SYCL GPU Backend requires DPC++ (dpcpp) " + "or the oneAPI CXX (icpx) compiler." + ), + ) + return args diff --git a/var/spack/repos/builtin/packages/amrex/package.py b/var/spack/repos/builtin/packages/amrex/package.py index ec976c8adb130f..62813b5681906a 100644 --- a/var/spack/repos/builtin/packages/amrex/package.py +++ b/var/spack/repos/builtin/packages/amrex/package.py @@ -26,6 +26,10 @@ class Amrex(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("develop", branch="development") + version("24.07", sha256="6baf76c1377d765e94020a9bd89dd1bf1485d0440d41cce2ba35d4dfee562580") + version("24.06", sha256="103a97163d81716165fcff1af56df61741608b56f90730a725e9e4eb797bebf0") + version("24.05", sha256="f3db5ea2b81973e3e244c5cf39d5a5383a98f297f56ed91c8dcdd2e24f7b750e") + version("24.04", sha256="77a91e75ad0106324a44ca514e1e8abc54f2fc2d453406441c871075726a8167") version("24.03", sha256="024876fe65838d1021fcbf8530b992bff8d9be1d3f08a1723c4e2e5f7c28b427") version("24.02", sha256="286cc3ca29daa69c8eafc1cd7a572662dec9eb78631ac3d33a1260868fdc6996") version("24.01", sha256="83dbd4dad6dc51fa4a80aad0347b15ee5a6d816cf4abcd87f7b0e2987d8131b7") @@ -83,6 +87,10 @@ class Amrex(CMakePackage, CudaPackage, ROCmPackage): version("18.10", sha256="298eba03ef03d617c346079433af1089d38076d6fab2c34476c687740c1f4234") version("18.09.1", sha256="a065ee4d1d98324b6c492ae20ea63ba12a4a4e23432bf5b3fe9788d44aa4398e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Config options variant( "dimensions", @@ -300,11 +308,10 @@ def cmake_args(self): if "+sycl" in self.spec: args.append("-DAMReX_GPU_BACKEND=SYCL") # SYCL GPU backend only supported with Intel's oneAPI or DPC++ compilers - sycl_compatible_compilers = ["dpcpp", "icpx"] + sycl_compatible_compilers = ["icpx"] if not (os.path.basename(self.compiler.cxx) in sycl_compatible_compilers): raise InstallError( - "AMReX's SYCL GPU Backend requires DPC++ (dpcpp)" - + " or the oneAPI CXX (icpx) compiler." + "AMReX's SYCL GPU Backend requires the oneAPI CXX (icpx) compiler." ) return args diff --git a/var/spack/repos/builtin/packages/amrfinder/package.py b/var/spack/repos/builtin/packages/amrfinder/package.py index 6d5f8cda84b4b1..091e57753ce99e 100644 --- a/var/spack/repos/builtin/packages/amrfinder/package.py +++ b/var/spack/repos/builtin/packages/amrfinder/package.py @@ -24,6 +24,8 @@ class Amrfinder(MakefilePackage): version("3.10.30", sha256="2f1e30b86935a27cee740bd7229a41fbce278f2f60b33b8e51592bab8bdf23f1") version("3.10.24", sha256="fce299c980cda740dcc4f53f9b2dc9061c856213e5bdbc2c339185a5fb7dcf6a") + depends_on("cxx", type="build") # generated + depends_on("blast-plus") depends_on("hmmer") depends_on("curl") diff --git a/var/spack/repos/builtin/packages/amrvis/package.py b/var/spack/repos/builtin/packages/amrvis/package.py index 16bfd5a732c0f2..8732d860015f7e 100644 --- a/var/spack/repos/builtin/packages/amrvis/package.py +++ b/var/spack/repos/builtin/packages/amrvis/package.py @@ -20,6 +20,8 @@ class Amrvis(MakefilePackage): version("main", branch="main") + depends_on("cxx", type="build") # generated + variant( "dims", default="3", diff --git a/var/spack/repos/builtin/packages/ams/package.py b/var/spack/repos/builtin/packages/ams/package.py index 4cf123a848eed0..b59d6e00c3bc97 100644 --- a/var/spack/repos/builtin/packages/ams/package.py +++ b/var/spack/repos/builtin/packages/ams/package.py @@ -10,7 +10,7 @@ class Ams(CMakePackage, CudaPackage): """AMS Autonomous Multiscale Framework.""" homepage = "https://github.com/LLNL/AMS" - git = "git@github.com:LLNL/AMS.git" + git = "https://github.com/LLNL/AMS.git" maintainers("koparasy", "lpottier") @@ -28,6 +28,9 @@ class Ams(CMakePackage, CudaPackage): submodules=False, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "faiss", default=False, diff --git a/var/spack/repos/builtin/packages/andi/package.py b/var/spack/repos/builtin/packages/andi/package.py index e7a2052c75fe5b..ce8956db292c91 100644 --- a/var/spack/repos/builtin/packages/andi/package.py +++ b/var/spack/repos/builtin/packages/andi/package.py @@ -19,6 +19,9 @@ class Andi(AutotoolsPackage): version("0.14", sha256="2c9e11524f38e74fe3f981e6acd9527c1a1ca30994a30c5e86808ba5165a25b7") version("0.10", sha256="1ff371de0b6db4080e402ded2687947dc2d6913e28626edec21dcf5149489ee8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("m4", type="build") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/angsd/package.py b/var/spack/repos/builtin/packages/angsd/package.py index a682aaf4dcb84e..98ce30c1bacea2 100644 --- a/var/spack/repos/builtin/packages/angsd/package.py +++ b/var/spack/repos/builtin/packages/angsd/package.py @@ -22,6 +22,9 @@ class Angsd(MakefilePackage): version("0.921", sha256="8892d279ce1804f9e17fe2fc65a47e5498e78fc1c1cb84d2ca2527fd5c198772") version("0.919", sha256="c2ea718ca5a5427109f4c3415e963dcb4da9afa1b856034e25c59c003d21822a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("r", default=True, description="Enable R dependency") depends_on("htslib") diff --git a/var/spack/repos/builtin/packages/antlr/package.py b/var/spack/repos/builtin/packages/antlr/package.py index 87cab3ca5b8e4c..8f10a2f0980579 100644 --- a/var/spack/repos/builtin/packages/antlr/package.py +++ b/var/spack/repos/builtin/packages/antlr/package.py @@ -20,6 +20,9 @@ class Antlr(AutotoolsPackage): version("2.7.7", sha256="853aeb021aef7586bda29e74a6b03006bcb565a755c86b66032d8ec31b67dbb9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Fixes build with recent versions of GCC patch("gcc.patch") diff --git a/var/spack/repos/builtin/packages/antlr4-cpp-runtime/package.py b/var/spack/repos/builtin/packages/antlr4-cpp-runtime/package.py index d8a30eaf03d9b4..e8b12cc36c779b 100644 --- a/var/spack/repos/builtin/packages/antlr4-cpp-runtime/package.py +++ b/var/spack/repos/builtin/packages/antlr4-cpp-runtime/package.py @@ -26,7 +26,7 @@ class Antlr4CppRuntime(CMakePackage): "clanglibcpp", default=False, description="Compile with clang libc++ instead of libstdc++" ) - depends_on("libuuid", type=["build", "link"], when="@:4.10.1") + depends_on("uuid", type=["build", "link"], when="@:4.10.1") depends_on("git", type=["build"]) depends_on("pkgconfig", type=["build"]) diff --git a/var/spack/repos/builtin/packages/ants/package.py b/var/spack/repos/builtin/packages/ants/package.py index b125a6e3327c34..6dcded9621c81a 100644 --- a/var/spack/repos/builtin/packages/ants/package.py +++ b/var/spack/repos/builtin/packages/ants/package.py @@ -26,6 +26,8 @@ class Ants(CMakePackage): version("2.3.5", sha256="2fddfd5f274a47f1c383e734a7e763b627c4a8383d2d3b9971561f335016bb0a") version("2.2.0", sha256="62f8f9ae141cb45025f4bb59277c053acf658d4a3ba868c9e0f609af72e66b4a") + depends_on("cxx", type="build") # generated + depends_on("zlib-api", type="link") variant("minc", default=True, description="Build ITK with MINC support") diff --git a/var/spack/repos/builtin/packages/aocc/detection_test.yaml b/var/spack/repos/builtin/packages/aocc/detection_test.yaml new file mode 100644 index 00000000000000..331ba0ba4a3315 --- /dev/null +++ b/var/spack/repos/builtin/packages/aocc/detection_test.yaml @@ -0,0 +1,75 @@ +paths: +- layout: + - executables: + - "bin/clang" + - "bin/clang++" + - "bin/flang" + script: | + echo "AMD clang version 12.0.0 (CLANG: AOCC_3_1_0-Build#126 2021_06_07)(based on LLVM Mirror.Version.12.0.0)\n" + echo "Target: x86_64-unknown-linux-gnu\n" + echo "Thread model: posix\n" + platforms: [linux] + results: + - spec: aocc@3.1.0 + extra_attributes: + compilers: + c: ".*/bin/clang" + cxx: ".*/bin/clang[+][+]" + fortran: ".*/bin/flang" +- layout: + - executables: + - "bin/clang" + - "bin/clang++" + script: | + echo "AMD clang version 12.0.0 (CLANG: AOCC_3_1_0-Build#126 2021_06_07)(based on LLVM Mirror.Version.12.0.0)\n" + echo "Target: x86_64-unknown-linux-gnu\n" + echo "Thread model: posix\n" + platforms: [linux] + results: + - spec: aocc@3.1.0 + extra_attributes: + compilers: + c: ".*/bin/clang" + cxx: ".*/bin/clang[+][+]" +- layout: + - executables: + - "bin/clang" + - "bin/clang++" + - "bin/flang" + script: | + echo "AMD clang version 12.0.0 (CLANG: AOCC_3_0_0-Build#78 2020_12_10)(based on LLVM Mirror.Version.12.0.0)\n" + echo "Target: x86_64-unknown-linux-gnu\n" + echo "Thread model: posix\n" + - executables: + - "bin/clang-11" + - "bin/clang++-11" + - "bin/flang-11" + script: | + echo "AMD clang version 11.0.0 (CLANG: AOCC_2_3_0-Build#85 2020_11_10)(based on LLVM Mirror.Version.11.0.0)\n" + echo "Target: x86_64-unknown-linux-gnu\n" + echo "Thread model: posix\n" + platforms: [linux] + results: + - spec: aocc@3.0.0 + extra_attributes: + compilers: + c: ".*/bin/clang$" + cxx: ".*/bin/clang[+][+]$" + fortran: ".*/bin/flang$" + - spec: aocc@2.3.0 + extra_attributes: + compilers: + c: ".*/bin/clang-11" + cxx: ".*/bin/clang[+][+]-11" + fortran: ".*/bin/flang-11" +- layout: + - executables: + - "bin/clang" + - "bin/clang++" + script: | + echo "clang version 8.0.0 (tags/RELEASE_800/final" + echo "Target: x86_64-unknown-linux-gnu\n" + echo "Thread model: posix\n" + echo "InstalledDir: /usr/bin" + platforms: [linux] + results: [] diff --git a/var/spack/repos/builtin/packages/aocc/package.py b/var/spack/repos/builtin/packages/aocc/package.py index 7129cd869742d1..db3d1d3755bbdb 100644 --- a/var/spack/repos/builtin/packages/aocc/package.py +++ b/var/spack/repos/builtin/packages/aocc/package.py @@ -8,7 +8,7 @@ from spack.package import * -class Aocc(Package): +class Aocc(Package, CompilerPackage): """ The AOCC compiler system is a high performance, production quality code generation tool. The AOCC environment provides various options to developers @@ -28,7 +28,6 @@ class Aocc(Package): """ _name = "aocc" - family = "compiler" homepage = "https://www.amd.com/en/developer/aocc.html" maintainers("amd-toolchain-support") @@ -54,6 +53,8 @@ class Aocc(Package): url="https://download.amd.com/developer/eula/aocc-compiler/aocc-compiler-3.2.0.tar", ) + depends_on("c", type="build") # generated + # Licensing license_url = "https://www.amd.com/en/developer/aocc/aocc-compiler/eula.html" @@ -105,3 +106,9 @@ def cfg_files(self): for compiler in ["clang", "clang++"]: with open(join_path(self.prefix.bin, "{}.cfg".format(compiler)), "w") as f: f.write(compiler_options) + + compiler_version_argument = "--version" + compiler_version_regex = r"AOCC_(\d+[._]\d+[._]\d+)" + c_names = ["clang"] + cxx_names = ["clang++"] + fortran_names = ["flang"] diff --git a/var/spack/repos/builtin/packages/aocl-compression/package.py b/var/spack/repos/builtin/packages/aocl-compression/package.py index 133c92b8f4f78c..70ce6a6fdfcac9 100644 --- a/var/spack/repos/builtin/packages/aocl-compression/package.py +++ b/var/spack/repos/builtin/packages/aocl-compression/package.py @@ -51,6 +51,9 @@ class AoclCompression(CMakePackage): preferred=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared library") variant("zlib", default=True, description="Build zlib library") variant("bzip2", default=True, description="Build bzip2 library") diff --git a/var/spack/repos/builtin/packages/aocl-crypto/package.py b/var/spack/repos/builtin/packages/aocl-crypto/package.py index 908117655a1316..65a687cb27c82f 100644 --- a/var/spack/repos/builtin/packages/aocl-crypto/package.py +++ b/var/spack/repos/builtin/packages/aocl-crypto/package.py @@ -44,6 +44,9 @@ class AoclCrypto(CMakePackage): sha256="2bdbedd8ab1b28632cadff237f4abd776e809940ad3633ad90fc52ce225911fe", preferred=True, ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated variant("examples", default=False, description="Build examples") depends_on("cmake@3.15:", type="build") diff --git a/var/spack/repos/builtin/packages/aocl-libmem/package.py b/var/spack/repos/builtin/packages/aocl-libmem/package.py index 323a04c0cf97c1..c01365db7dd717 100644 --- a/var/spack/repos/builtin/packages/aocl-libmem/package.py +++ b/var/spack/repos/builtin/packages/aocl-libmem/package.py @@ -41,6 +41,9 @@ class AoclLibmem(CMakePackage): preferred=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("logging", default=False, description="Enable/Disable logger") variant("tunables", default=False, description="Enable/Disable user input") variant("shared", default=True, description="build shared library") diff --git a/var/spack/repos/builtin/packages/aocl-sparse/package.py b/var/spack/repos/builtin/packages/aocl-sparse/package.py index 765bc0e3215d2c..84ac6781422687 100644 --- a/var/spack/repos/builtin/packages/aocl-sparse/package.py +++ b/var/spack/repos/builtin/packages/aocl-sparse/package.py @@ -44,6 +44,9 @@ class AoclSparse(CMakePackage): version("3.0", sha256="1d04ba16e04c065051af916b1ed9afce50296edfa9b1513211a7378e1d6b952e") version("2.2", sha256="33c2ed6622cda61d2613ee63ff12c116a6cd209c62e54307b8fde986cd65f664") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared library") variant("ilp64", default=False, description="Build with ILP64 support") variant("examples", default=False, description="Build sparse examples") diff --git a/var/spack/repos/builtin/packages/aocl-utils/package.py b/var/spack/repos/builtin/packages/aocl-utils/package.py index d32477c7814e77..693228ba9adec3 100644 --- a/var/spack/repos/builtin/packages/aocl-utils/package.py +++ b/var/spack/repos/builtin/packages/aocl-utils/package.py @@ -44,6 +44,8 @@ class AoclUtils(CMakePackage): ) version("4.1", sha256="660746e7770dd195059ec25e124759b126ee9f060f43302d13354560ca76c02c") + depends_on("cxx", type="build") # generated + variant("doc", default=False, description="enable documentation") variant("tests", default=False, description="enable testing") variant("shared", default=True, when="@4.2:", description="build shared library") diff --git a/var/spack/repos/builtin/packages/aoflagger/package.py b/var/spack/repos/builtin/packages/aoflagger/package.py index 66309bf9fd9589..5dfc09e72203c2 100644 --- a/var/spack/repos/builtin/packages/aoflagger/package.py +++ b/var/spack/repos/builtin/packages/aoflagger/package.py @@ -18,6 +18,8 @@ class Aoflagger(CMakePackage): version("2.10.0", sha256="3ec1188d37101acf2029575ebc09c50b19c158c88a12b55ac5d25a96bd8fc18d") + depends_on("cxx", type="build") # generated + depends_on("casacore+python~fftpack@1.10:") depends_on("fftw~mpi@3.0:") depends_on("boost+python@:1.66.99") diff --git a/var/spack/repos/builtin/packages/aom/package.py b/var/spack/repos/builtin/packages/aom/package.py index 2862b40edca617..55c78e9f35f5c1 100644 --- a/var/spack/repos/builtin/packages/aom/package.py +++ b/var/spack/repos/builtin/packages/aom/package.py @@ -15,6 +15,9 @@ class Aom(CMakePackage): license("BSD-2-Clause AND AOM-Patent-License-1.0", checked_by="tgamblin") version("v1.0.0-errata1", commit="29d8ce4836630df5cc7ab58f1afc4836765fc212") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("yasm") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/apachetop/package.py b/var/spack/repos/builtin/packages/apachetop/package.py index 060c5e1f878c1c..b1e72cee7a8de2 100644 --- a/var/spack/repos/builtin/packages/apachetop/package.py +++ b/var/spack/repos/builtin/packages/apachetop/package.py @@ -21,6 +21,8 @@ class Apachetop(AutotoolsPackage): version("0.17.4", sha256="892ed3b83b45eb38811e74d068089b1e8c34707787f240ce133d8c93198d7ff0") version("0.15.6", sha256="7343caeb1adab795439b7be9cf47ce6049751ae948537d5f27251c075264801a") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/apcomp/package.py b/var/spack/repos/builtin/packages/apcomp/package.py index b98f324b77e692..dd2abe442c603a 100644 --- a/var/spack/repos/builtin/packages/apcomp/package.py +++ b/var/spack/repos/builtin/packages/apcomp/package.py @@ -36,11 +36,15 @@ class Apcomp(Package): maintainers("cyrush") - version("master", branch="master", submodules="True") - version("0.0.4", sha256="061876dd55e443de91a40d10662496f6bb58b0a3835aec78f5710f5a737d0494") - version("0.0.3", sha256="07e8c1d6a23205f4cc66d0a030e65a69e8344545f4d56213d968b67a410adc6e") - version("0.0.2", sha256="cb2e2c4524889408de2dd3d29665512c99763db13e6f5e35c3b55e52948c649c") - version("0.0.1", sha256="cbf85fe58d5d5bc2f468d081386cc8b79861046b3bb7e966edfa3f8e95b998b2") + with default_args(deprecated=True): # part of ascent + version("master", branch="master", submodules="True") + version("0.0.4", sha256="061876dd55e443de91a40d10662496f6bb58b0a3835aec78f5710f5a737d0494") + version("0.0.3", sha256="07e8c1d6a23205f4cc66d0a030e65a69e8344545f4d56213d968b67a410adc6e") + version("0.0.2", sha256="cb2e2c4524889408de2dd3d29665512c99763db13e6f5e35c3b55e52948c649c") + version("0.0.1", sha256="cbf85fe58d5d5bc2f468d081386cc8b79861046b3bb7e966edfa3f8e95b998b2") + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant("openmp", default=True, description="Build with openmp support") variant("mpi", default=True, description="Build with MPI support") @@ -60,19 +64,8 @@ def install(self, spec, prefix): """ with working_dir("spack-build", create=True): host_cfg_fname = self.create_host_config(spec, prefix) - cmake_args = [] - # if we have a static build, we need to avoid any of - # spack's default cmake settings related to rpaths - # (see: https://github.com/LLNL/spack/issues/2658) - if "+shared" in spec: - cmake_args.extend(std_cmake_args) - else: - for arg in std_cmake_args: - if arg.count("RPATH") == 0: - cmake_args.append(arg) - cmake_args.extend(["-C", host_cfg_fname, "../src"]) print("Configuring APComp...") - cmake(*cmake_args) + cmake(*std_cmake_args, "-C", host_cfg_fname, "../src") print("Building APComp...") make() print("Installing APComp...") diff --git a/var/spack/repos/builtin/packages/apex/package.py b/var/spack/repos/builtin/packages/apex/package.py index 6576f5d9a0474b..0660ccbc6c7ead 100644 --- a/var/spack/repos/builtin/packages/apex/package.py +++ b/var/spack/repos/builtin/packages/apex/package.py @@ -65,6 +65,10 @@ class Apex(CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Disable some default dependencies on Darwin/OSX darwin_default = False if sys.platform != "darwin": @@ -125,6 +129,11 @@ class Apex(CMakePackage): # https://github.com/UO-OACISS/apex/pull/177#issuecomment-1726322959 conflicts("+openmp", when="%gcc") + # Up to 2.6.3 Kokkos support is always enabled. In 2.6.4 and 2.6.5 there is + # a CMake option to disable Kokkos support but it doesn't work: + # https://github.com/UO-OACISS/apex/issues/180. + conflicts("~kokkos", when="@:2.6.5") + # Patches # This patch ensures that the missing dependency_tree.hpp header is @@ -154,6 +163,7 @@ def cmake_args(self): args.append(self.define_from_variant(prefix + "_LM_SENSORS", "lmsensors")) args.append(self.define_from_variant(prefix + "_TCMALLOC", "gperftools")) args.append(self.define_from_variant(prefix + "_JEMALLOC", "jemalloc")) + args.append(self.define_from_variant(prefix + "_KOKKOS", "kokkos")) args.append(self.define_from_variant(test_prefix + "BUILD_TESTS", "tests")) args.append(self.define_from_variant(test_prefix + "BUILD_EXAMPLES", "examples")) diff --git a/var/spack/repos/builtin/packages/apfel/package.py b/var/spack/repos/builtin/packages/apfel/package.py index e5a797024e3451..29fe90c04b8554 100644 --- a/var/spack/repos/builtin/packages/apfel/package.py +++ b/var/spack/repos/builtin/packages/apfel/package.py @@ -22,6 +22,9 @@ class Apfel(AutotoolsPackage): version("3.0.6", sha256="7063c9eee457e030b97926ac166cdaedd84625b31397e1dfd01ae47371fb9f61") version("3.0.4", sha256="c7bfae7fe2dc0185981850f2fe6ae4842749339d064c25bf525b4ef412bbb224") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("swig", when="+python") depends_on("python", type=("build", "run")) depends_on("lhapdf", when="+lhapdf", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/apple-clang/detection_test.yaml b/var/spack/repos/builtin/packages/apple-clang/detection_test.yaml index dc5b7106ec50f4..1e5232911612e9 100644 --- a/var/spack/repos/builtin/packages/apple-clang/detection_test.yaml +++ b/var/spack/repos/builtin/packages/apple-clang/detection_test.yaml @@ -1,35 +1,48 @@ paths: - # Apple Clang on MacBook Pro (Catalina) - - layout: - - executables: - - "bin/clang" - - "bin/clang++" - script: | - echo "Apple clang version 11.0.0 (clang-1100.0.33.8)" - echo "Target: x86_64-apple-darwin19.5.0" - echo "Thread model: posix" - echo "InstalledDir: /Library/Developer/CommandLineTools/usr/bin" - results: - - spec: 'apple-clang@11.0.0' - # Apple Clang on Apple M1 (Ventura) - - layout: - - executables: - - "bin/clang" - - "bin/clang++" - script: | - echo "Apple clang version 15.0.0 (clang-1500.0.40.1)" - echo "Target: arm64-apple-darwin22.6.0" - echo "Thread model: posix" - echo "InstalledDir: /Library/Developer/CommandLineTools/usr/bin" - results: - - spec: 'apple-clang@15.0.0' - # Test that missing a compiler prevents the package from being detected - - layout: - - executables: - - "bin/clang" - script: | - echo "Apple clang version 11.0.0 (clang-1100.0.33.8)" - echo "Target: x86_64-apple-darwin19.5.0" - echo "Thread model: posix" - echo "InstalledDir: /Library/Developer/CommandLineTools/usr/bin" - results: [ ] +# Apple Clang on MacBook Pro (Catalina) +- layout: + - executables: + - "bin/clang" + - "bin/clang++" + script: | + echo "Apple clang version 11.0.0 (clang-1100.0.33.8)" + echo "Target: x86_64-apple-darwin19.5.0" + echo "Thread model: posix" + echo "InstalledDir: /Library/Developer/CommandLineTools/usr/bin" + platforms: ["darwin"] + results: + - spec: 'apple-clang@11.0.0' + extra_attributes: + compilers: + c: ".*/bin/clang" + cxx: ".*/bin/clang[+][+]" + +# Apple Clang on Apple M1 (Ventura) +- layout: + - executables: + - "bin/clang" + - "bin/clang++" + script: | + echo "Apple clang version 15.0.0 (clang-1500.0.40.1)" + echo "Target: arm64-apple-darwin22.6.0" + echo "Thread model: posix" + echo "InstalledDir: /Library/Developer/CommandLineTools/usr/bin" + platforms: ["darwin"] + results: + - spec: 'apple-clang@15.0.0' + extra_attributes: + compilers: + c: ".*/bin/clang" + cxx: ".*/bin/clang[+][+]" + +# Test that missing a compiler prevents the package from being detected +- layout: + - executables: + - "bin/clang" + script: | + echo "Apple clang version 11.0.0 (clang-1100.0.33.8)" + echo "Target: x86_64-apple-darwin19.5.0" + echo "Thread model: posix" + echo "InstalledDir: /Library/Developer/CommandLineTools/usr/bin" + platforms: ["darwin"] + results: [] diff --git a/var/spack/repos/builtin/packages/apple-clang/package.py b/var/spack/repos/builtin/packages/apple-clang/package.py index 634aedf4ebc812..95c3eb54c01a37 100644 --- a/var/spack/repos/builtin/packages/apple-clang/package.py +++ b/var/spack/repos/builtin/packages/apple-clang/package.py @@ -2,12 +2,10 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import re - from spack.package import * -class AppleClang(BundlePackage): +class AppleClang(BundlePackage, CompilerPackage): """Apple's Clang compiler""" homepage = "https://developer.apple.com/videos/developer-tools/compiler-and-llvm" @@ -15,44 +13,12 @@ class AppleClang(BundlePackage): maintainers("alalazo") - executables = ["^clang$", r"^clang\+\+$", "^ld.lld$", "^lldb$"] - - @classmethod - def determine_version(cls, exe): - version_regex = re.compile( - # Apple's LLVM compiler has its own versions, which are - # different from vanilla LLVM - r"^Apple (?:LLVM|clang) version ([^ )]+)", - # Multi-line, since 'Apple clang' may not be on the first line - # in particular, when run as gcc, it seems to output - # "Configured with: --prefix=..." as the first line - re.M, - ) - try: - compiler = Executable(exe) - output = compiler("--version", output=str, error=str) - match = version_regex.search(output) - if match: - return match.group(match.lastindex) - except Exception: - pass - - return None - - @classmethod - def determine_variants(cls, exes, version_str): - compilers = {} - for exe in exes: - if "clang++" in exe: - compilers["cxx"] = exe - elif "clang" in exe: - compilers["c"] = exe - elif "ld.lld" in exe: - compilers["ld"] = exe - elif "lldb" in exe: - compilers["lldb"] = exe + compiler_languages = ["c", "cxx"] + c_names = ["clang"] + cxx_names = ["clang++"] - return "", {"compilers": compilers} + compiler_version_regex = r"^Apple (?:LLVM|clang) version ([^ )]+)" + compiler_version_argument = "--version" @classmethod def validate_detected_spec(cls, spec, extra_attributes): diff --git a/var/spack/repos/builtin/packages/apple-gl/package.py b/var/spack/repos/builtin/packages/apple-gl/package.py index f0140bc2d74c30..61e7076f5d5364 100644 --- a/var/spack/repos/builtin/packages/apple-gl/package.py +++ b/var/spack/repos/builtin/packages/apple-gl/package.py @@ -2,34 +2,14 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) - - from spack.package import * -class AppleGl(Package): - """Shim package for the core OpenGL library from Apple""" - +class AppleGlBase(BundlePackage): homepage = "https://developer.apple.com/library/archive/documentation/GraphicsImaging/Conceptual/OpenGL-MacProgGuide/opengl_intro/opengl_intro.html" maintainers("aphecetche") - has_code = False - - version("4.1.0") - - provides("gl@4.1") - - # Only supported on 'platform=darwin' and compiler=apple-clang - conflicts("platform=linux") - conflicts("platform=cray") - conflicts("platform=windows") - conflicts("%gcc") - conflicts("%clang") - conflicts("%msvc") - - phases = [] - def setup_dependent_build_environment(self, env, dependent_spec): # we try to setup a build environment with enough hints # for the build system to pick up on the Apple framework version @@ -50,3 +30,16 @@ def headers(self): @property def libs(self): return LibraryList(join_path(self.prefix, "System/Library/Frameworks/OpenGL.framework")) + + +class AppleGl(AppleGlBase): + """Shim package for the core OpenGL library from Apple""" + + version("4.1.0") + + provides("gl@4.1") + + requires( + "%apple-clang platform=darwin", + msg="Apple-GL is only available on Darwin, when using Apple Clang", + ) diff --git a/var/spack/repos/builtin/packages/apple-glu/package.py b/var/spack/repos/builtin/packages/apple-glu/package.py index 2ccf686cf9ef80..f94fba66646ba4 100644 --- a/var/spack/repos/builtin/packages/apple-glu/package.py +++ b/var/spack/repos/builtin/packages/apple-glu/package.py @@ -2,49 +2,18 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) - - from spack.package import * +from spack.pkg.builtin.apple_gl import AppleGlBase -class AppleGlu(Package): +class AppleGlu(AppleGlBase): """Shim package for Apple implementation of OpenGL Utility Libray (GLU)""" - homepage = "https://developer.apple.com/library/archive/documentation/GraphicsImaging/Conceptual/OpenGL-MacProgGuide/opengl_intro/opengl_intro.html" - - maintainers("aphecetche") - - has_code = False - version("1.3.0") provides("glu@1.3") - # Only supported on 'platform=darwin' and compiler=apple-clang - conflicts("platform=linux") - conflicts("platform=cray") - conflicts("%gcc") - conflicts("%clang") - - phases = [] - - def setup_dependent_build_environment(self, env, dependent_spec): - # we try to setup a build environment with enough hints - # for the build system to pick up on the Apple framework version - # of OpenGL. - # - for a cmake build we actually needs nothing at all as - # find_package(OpenGL) will do the right thing - # - for the rest of the build systems we'll assume that - # setting the C_INCLUDE_PATH will be enough for the compilation phase - # and *** for the link phase. - env.prepend_path("C_INCLUDE_PATH", self.prefix[:-4]) - - @property - def headers(self): - return HeaderList( - join_path(self.prefix, "System/Library/Frameworks/OpenGL.framework/Headers") - ) - - @property - def libs(self): - return LibraryList(join_path(self.prefix, "System/Library/Frameworks/OpenGL.framework")) + requires( + "%apple-clang platform=darwin", + msg="Apple-GLU is only available on Darwin, when using Apple Clang", + ) diff --git a/var/spack/repos/builtin/packages/apple-libunwind/package.py b/var/spack/repos/builtin/packages/apple-libunwind/package.py index d549ddab36232e..1c989ad9846cd4 100644 --- a/var/spack/repos/builtin/packages/apple-libunwind/package.py +++ b/var/spack/repos/builtin/packages/apple-libunwind/package.py @@ -19,7 +19,6 @@ class AppleLibunwind(Package): # Darwin must be expressed by listing a conflict with every # platform that isn't Darwin/macOS conflicts("platform=linux") - conflicts("platform=cray") # Override the fetcher method to throw a useful error message; # avoids GitHub issue (#7061) in which the opengl placeholder diff --git a/var/spack/repos/builtin/packages/apple-libuuid/package.py b/var/spack/repos/builtin/packages/apple-libuuid/package.py index 612f1c6f42bf27..94e42bc0ee5b9e 100644 --- a/var/spack/repos/builtin/packages/apple-libuuid/package.py +++ b/var/spack/repos/builtin/packages/apple-libuuid/package.py @@ -17,7 +17,6 @@ class AppleLibuuid(BundlePackage): # Only supported on 'platform=darwin' conflicts("platform=linux") - conflicts("platform=cray") conflicts("platform=windows") @property diff --git a/var/spack/repos/builtin/packages/appres/package.py b/var/spack/repos/builtin/packages/appres/package.py index 588af73fbb15c6..29fb85c0f4d5a4 100644 --- a/var/spack/repos/builtin/packages/appres/package.py +++ b/var/spack/repos/builtin/packages/appres/package.py @@ -18,6 +18,8 @@ class Appres(AutotoolsPackage, XorgPackage): version("1.0.6", sha256="848f383ff429612fb9df840d79e97dc193dc72dbbf53d3217a8d1e90a5aa1e26") version("1.0.4", sha256="22cb6f639c891ffdbb5371bc50a88278185789eae6907d05e9e0bd1086a80803") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/apptainer/package.py b/var/spack/repos/builtin/packages/apptainer/package.py index 2fbe795b7702ea..45a05af31ac3b3 100644 --- a/var/spack/repos/builtin/packages/apptainer/package.py +++ b/var/spack/repos/builtin/packages/apptainer/package.py @@ -4,6 +4,9 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) +from glob import glob +from os.path import basename + from spack.package import * from spack.pkg.builtin.singularityce import SingularityBase @@ -33,6 +36,8 @@ class Apptainer(SingularityBase): ) version("main", branch="main") + version("1.3.1", sha256="6956c689c4a8f148789c5c34b33c15ad8f3460b4cee3f48022119fd872eacee9") + version("1.2.5", sha256="606b67ef97683e1420401718687d258b1034fdf2edae72eeacd0828dffbfc2c2") version("1.1.9", sha256="c615777539154288542cf393d3fd44c04ccb3260bc6330dc324d4e4ebe902bfa") version("1.1.7", sha256="e6d3956a26c3965703402e17f153ba07f59bf710068806462b314d2d04e825e7") version("1.1.6", sha256="5f32d305279a51ce8bdbe69e733c4ac12b1efdcb77758fab8ec9463e96a8fd82") @@ -41,8 +46,17 @@ class Apptainer(SingularityBase): version("1.1.3", sha256="c7bf7f4d5955e1868739627928238d02f94ca9fd0caf110b0243d65548427899") version("1.0.2", sha256="2d7a9d0a76d5574459d249c3415e21423980d9154ce85e8c34b0600782a7dfd3") + depends_on("c", type="build") # generated + + depends_on("e2fsprogs@1.47:+fuse2fs", type="run") depends_on("go@1.17.5:", when="@1.1.0:") + depends_on("go@1.19:", when="@1.2:") + depends_on("go@1.20:", when="@1.3:") + depends_on("gocryptfs@2.4:", type="run", when="@1.3:") depends_on("squashfuse", type="run") + depends_on("squashfuse@0.5.1:", type="run", when="@1.3:") + depends_on("fuse-overlayfs", type="run") + depends_on("fuse-overlayfs@1.13:", type="run", when="@1.3:") singularity_org = "apptainer" singularity_name = "apptainer" @@ -64,3 +78,19 @@ def flag_handler(self, name, flags): # Certain go modules this build pulls in cannot be built with anything # other than -O0. Best to just discard any injected flags. return (None, flags, None) + + # They started vendoring the fuse bits and assume they'll be in the + # libexec/apptainer prefix as a result. When singularity is run with + # suid it doesn't search the user's $PATH for security reasons. + # Since we don't use the vendored deps and instead install them in + # their own prefixes they are not found by default. + # This is likely only relevant for 1.3:, but it should be fine everywhere + @run_after("install") + def fix_binary_path(self): + for i in [ + s for s in ["e2fsprogs", "gocryptfs", "squashfuse", "fuse-overlayfs"] if s in self.spec + ]: + for binary in glob(join_path(self.spec[i].prefix.bin, "*")): + symlink( + binary, join_path(self.spec.prefix.libexec.apptainer.bin, basename(binary)) + ) diff --git a/var/spack/repos/builtin/packages/apr-util/package.py b/var/spack/repos/builtin/packages/apr-util/package.py index 8638f880c0085e..bcc127be85638d 100644 --- a/var/spack/repos/builtin/packages/apr-util/package.py +++ b/var/spack/repos/builtin/packages/apr-util/package.py @@ -19,6 +19,8 @@ class AprUtil(AutotoolsPackage): version("1.6.0", sha256="483ef4d59e6ac9a36c7d3fd87ad7b9db7ad8ae29c06b9dd8ff22dda1cc416389") version("1.5.4", sha256="976a12a59bc286d634a21d7be0841cc74289ea9077aa1af46be19d1a6e844c19") + depends_on("c", type="build") # generated + variant("crypto", default=True, description="Enable crypto support") variant("gdbm", default=False, description="Enable GDBM support") variant("pgsql", default=False, description="Enable PostgreSQL support") diff --git a/var/spack/repos/builtin/packages/apr/package.py b/var/spack/repos/builtin/packages/apr/package.py index c56f4eb7a143a0..27ac0eb8d3f528 100644 --- a/var/spack/repos/builtin/packages/apr/package.py +++ b/var/spack/repos/builtin/packages/apr/package.py @@ -21,6 +21,8 @@ class Apr(AutotoolsPackage): version("1.6.2", sha256="4fc24506c968c5faf57614f5d0aebe0e9d0b90afa47a883e1a1ca94f15f4a42e") version("1.5.2", sha256="1af06e1720a58851d90694a984af18355b65bb0d047be03ec7d659c746d6dbdb") + depends_on("c", type="build") # generated + patch("missing_includes.patch", when="@1.7.0") depends_on("uuid", type="link") diff --git a/var/spack/repos/builtin/packages/aqlprofile/package.py b/var/spack/repos/builtin/packages/aqlprofile/package.py new file mode 100644 index 00000000000000..9fae0246a5290b --- /dev/null +++ b/var/spack/repos/builtin/packages/aqlprofile/package.py @@ -0,0 +1,203 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + +_versions = { + "6.1.2": { + "apt": ( + "93faa8a0d702bc1623d2346e07a9a1c9134d99c0d3f9de62903e7394e0eedf47", + "https://repo.radeon.com/rocm/apt/6.1.2/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.60102.60102-119~20.04_amd64.deb", + ), + "yum": ( + "b8c6a8c8fad6b07c87f99a95126b982aeb39a3e4943d05df090d2221f4aef779", + "https://repo.radeon.com/rocm/yum/6.1.2/main/hsa-amd-aqlprofile-1.0.0.60102.60102-119.el7.x86_64.rpm", + ), + "zyp": ( + "132dde13aa550376ac39d57a51b42b803574cd0c57d2bd1346f36bf8d7efa4c4", + "https://repo.radeon.com/rocm/zyp/6.1.2/main/hsa-amd-aqlprofile-1.0.0.60102.60102-sles154.119.x86_64.rpm", + ), + }, + "6.1.1": { + "apt": ( + "faa5dae914fc63f0c8d0c2be28b7ec502db487004bdff0fe88dd15432efc5401", + "https://repo.radeon.com/rocm/apt/6.1.1/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.60101.60101-90~20.04_amd64.deb", + ), + "yum": ( + "cc247e15ceff625c94d6c7104ffea3990a4acbcd2f9114914ab7ab829fae4aeb", + "https://repo.radeon.com/rocm/yum/6.1.1/main/hsa-amd-aqlprofile-1.0.0.60101.60101-90.el7.x86_64.rpm", + ), + "zyp": ( + "9af82841be1765d6334b06a463583570653b6a36d0de29cfc00c5c4b6560b956", + "https://repo.radeon.com/rocm/zyp/6.1.1/main/hsa-amd-aqlprofile-1.0.0.60101.60101-sles154.90.x86_64.rpm", + ), + }, + "6.1.0": { + "apt": ( + "0ef862503245f12721384443f8347528f3d5c2c7762289c770521f3235ba36c9", + "https://repo.radeon.com/rocm/apt/6.1/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.60100.60100-82~20.04_amd64.deb", + ), + "yum": ( + "bb08ec49987ef821278e24b9669ccea613a1475af4aedfcc3ac77146e6fbf229", + "https://repo.radeon.com/rocm/yum/6.1/main/hsa-amd-aqlprofile-1.0.0.60100.60100-82.el7.x86_64.rpm", + ), + "zyp": ( + "6a20c8933a878dc3476fa5a45936d3d230d5c2c417e914a6460c2f576a3d6e35", + "https://repo.radeon.com/rocm/zyp/6.1/main/hsa-amd-aqlprofile-1.0.0.60100.60100-sles154.82.x86_64.rpm", + ), + }, + "6.0.2": { + "apt": ( + "57efc4e8380d941fc9e3ba8353bc724913cd5b5be2c53fed016e92da63e31b2f", + "https://repo.radeon.com/rocm/apt/6.0.2/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.60002.60002-115~20.04_amd64.deb", + ), + "yum": ( + "eb9099e86c3574124dfeec257217781b716f72c51cc5c11ed857d16cb0924467", + "https://repo.radeon.com/rocm/yum/6.0.2/main/hsa-amd-aqlprofile-1.0.0.60002.60002-115.el7.x86_64.rpm", + ), + "zyp": ( + "b752eb18eed98226bf0cffa492363d452b318432fd5ae01ad86172c4ce132bef", + "https://repo.radeon.com/rocm/zyp/6.0.2/main/hsa-amd-aqlprofile-1.0.0.60002.60002-sles154.115.x86_64.rpm", + ), + }, + "6.0.0": { + "apt": ( + "e120268933eab5eff25d1b7d0646b0785a13a9fb2dce2bdaca7ac2a19482339c", + "https://repo.radeon.com/rocm/apt/6.0/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.60000.60000-91~20.04_amd64.deb", + ), + "yum": ( + "431be1e9996a465e1305a312e238e9bc7de3991fa2488968a36195108ed7f7b5", + "https://repo.radeon.com/rocm/yum/6.0/main/hsa-amd-aqlprofile-1.0.0.60000.60000-91.el7.x86_64.rpm", + ), + "zyp": ( + "e64f3c0642b209753e2ede374eee80c36827db9de348c754a4385139f7203487", + "https://repo.radeon.com/rocm/zyp/6.0/main/hsa-amd-aqlprofile-1.0.0.60000.60000-sles154.91.x86_64.rpm", + ), + }, + "5.7.1": { + "apt": ( + "9f00713062005624231dac5fd3e92481b8d1547b3301c3b8a07298d4548037b8", + "https://repo.radeon.com/rocm/apt/5.7.1/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.50701.50701-98~20.04_amd64.deb", + ), + "yum": ( + "ea69d9deb604fdc0415070a9e3d8dbe90feecfc71533b92dd7507e2b8d2770de", + "https://repo.radeon.com/rocm/yum/5.7.1/main/hsa-amd-aqlprofile-1.0.0.50701.50701-98.el7.x86_64.rpm", + ), + "zyp": ( + "d83ca93e280764afc20e2eca01b8cc1c047e2a4db0131b4df58ec19f0ddc2a07", + "https://repo.radeon.com/rocm/zyp/5.7.1/main/hsa-amd-aqlprofile-1.0.0.50701.50701-sles154.98.x86_64.rpm", + ), + }, + "5.7.0": { + "apt": ( + "131e2d699eb24ff19cba54a9721b83c362196c91a8380b5e4b4ba3583311df21", + "https://repo.radeon.com/rocm/apt/5.7/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.50700.50700-63~20.04_amd64.deb", + ), + "yum": ( + "4f6eef63bb586c290b22234b3d849b382bcb4ddc0f28ed93b3232ca7f6914759", + "https://repo.radeon.com/rocm/yum/5.7/main/hsa-amd-aqlprofile-1.0.0.50700.50700-63.el7.x86_64.rpm", + ), + "zyp": ( + "61b7ba9022cdf2903dd476811d39f294cdb0fd4bd385785bcba9abe575e9b63c", + "https://repo.radeon.com/rocm/zyp/5.7/main/hsa-amd-aqlprofile-1.0.0.50700.50700-sles154.63.x86_64.rpm", + ), + }, + "5.6.1": { + "apt": ( + "ddb231dc4c8ca45e586ba68cae86273c3bc109f5ec172855815fce1ea6aff172", + "https://repo.radeon.com/rocm/apt/5.6.1/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.50601-93~20.04_amd64.deb", + ), + "yum": ( + "3c67b2e3cfbe71441d4c504dee2c55c9010a15ad7c973f1f858a052fb60524a6", + "https://repo.radeon.com/rocm/yum/5.6.1/main/hsa-amd-aqlprofile-1.0.0.50601-93.el7.x86_64.rpm", + ), + "zyp": ( + "956382a085356211a35cb24210764c4f5575ce4d3d842439e39cc94287004176", + "https://repo.radeon.com/rocm/zyp/5.6.1/main/hsa-amd-aqlprofile-1.0.0.50601-sles154.93.x86_64.rpm", + ), + }, + "5.6.0": { + "apt": ( + "67273e8513c0efdef6d52fb211a0cf4b7e117b1c5e737f8763946699324a9d7d", + "https://repo.radeon.com/rocm/apt/5.6/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.50600-67~20.04_amd64.deb", + ), + "yum": ( + "0aefd5f0eca5c1bcb55f5c80e946e252685533cbb3c936417abd44fe94c1f28e", + "https://repo.radeon.com/rocm/yum/5.6/main/hsa-amd-aqlprofile-1.0.0.50600-67.el7.x86_64.rpm", + ), + "zyp": ( + "b752eb18eed98226bf0cffa492363d452b318432fd5ae01ad86172c4ce132bef", + "https://repo.radeon.com/rocm/zyp/5.6/main/hsa-amd-aqlprofile-1.0.0.50600-sles154.67.x86_64.rpm", + ), + }, + "5.5.1": { + "apt": ( + "67b957abe5ea872abd3ec6b98eb83ef66fe07668001392e695dd77ab1b6d8890", + "https://repo.radeon.com/rocm/apt/5.5.1/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.50501-74~20.04_amd64.deb", + ), + "yum": ( + "2e6ae5a417d3a14a6b522b2daccbccea0a192ffe689b5e1817300ec2b65b60c2", + "https://repo.radeon.com/rocm/yum/5.5.1/main/hsa-amd-aqlprofile-1.0.0.50501-74.el7.x86_64.rpm", + ), + "zyp": ( + "3ad17b1628c308396d39f61c12f7403800468f54eb3f7b3ed4b47e076ea1b821", + "https://repo.radeon.com/rocm/zyp/5.5.1/main/hsa-amd-aqlprofile-1.0.0.50501-sles153.74.x86_64.rpm", + ), + }, + "5.5.0": { + "apt": ( + "fbe08a39a36499959198fa7678338cf2d7888dc2aafb4694072d1f37b24e599f", + "https://repo.radeon.com/rocm/apt/5.5/pool/main/h/hsa-amd-aqlprofile/hsa-amd-aqlprofile_1.0.0.50500-63~20.04_amd64.deb", + ), + "yum": ( + "fde2d38174d25af9d780ef2a1e91eb75b0de5943711f20930367b9f28f77a8bd", + "https://repo.radeon.com/rocm/yum/5.5/main/hsa-amd-aqlprofile-1.0.0.50500-63.el7.x86_64.rpm", + ), + "zyp": ( + "eec9dc39ddbb0fc1f18e0b62a238252b3e0968152792c5b4948b3d001b07a53f", + "https://repo.radeon.com/rocm/zyp/5.5/main/hsa-amd-aqlprofile-1.0.0.50500-sles153.63.x86_64.rpm", + ), + }, +} + + +class Aqlprofile(Package): + """ + HSA extension AMD AQL profile library. + Provides AQL packets helper methods for perfcounters (PMC) and SQ threadtraces (SQTT). + """ + + maintainers("afzpatel", "srekolam", "renjithravindrankannath") + + spack_os = spack.platforms.host().default_os + if "rhel" in spack_os or "centos" in spack_os: + pkg_type = "yum" + elif "sles" in spack_os: + pkg_type = "zyp" + else: + pkg_type = "apt" + + for ver, packages in _versions.items(): + pkg = packages.get(pkg_type) + if pkg: + version(ver, sha256=pkg[0], url=pkg[1], expand=False) + + depends_on("cpio") + + def install(self, spec, prefix): + # find deb or rpm pkg and extract files + for file in os.listdir("."): + if file.endswith(".rpm"): + os.system(f"rpm2cpio {file} | cpio -idmv") + break + if file.endswith(".deb"): + os.system(f"ar vx {file}") + os.system("tar xvf data.tar.gz") + break + + install_tree(f"opt/rocm-{spec.version}/share/", prefix.share) + install_tree(f"opt/rocm-{spec.version}/lib/", prefix.lib) diff --git a/var/spack/repos/builtin/packages/arbor/package.py b/var/spack/repos/builtin/packages/arbor/package.py index ca3651e4b3d833..c172ee9590f811 100644 --- a/var/spack/repos/builtin/packages/arbor/package.py +++ b/var/spack/repos/builtin/packages/arbor/package.py @@ -50,6 +50,9 @@ class Arbor(CMakePackage, CudaPackage): url="https://github.com/arbor-sim/arbor/releases/download/v0.5.2/arbor-v0.5.2-full.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("assertions", default=False, description="Enable arb_assert() assertions in code.") variant("doc", default=False, description="Build documentation.") variant("mpi", default=False, description="Enable MPI support") @@ -120,9 +123,7 @@ def cmake_args(self): # query spack for the architecture-specific compiler flags set by its wrapper args.append("-DARB_ARCH=none") - opt_flags = self.spec.target.optimization_flags( - self.spec.compiler.name, self.spec.compiler.version - ) + opt_flags = self.spec.architecture.target.optimization_flags(self.spec.compiler) args.append("-DARB_CXX_FLAGS_TARGET=" + opt_flags) return args diff --git a/var/spack/repos/builtin/packages/arborx/package.py b/var/spack/repos/builtin/packages/arborx/package.py index f65b6e92b0b5ae..86615c0b37396b 100644 --- a/var/spack/repos/builtin/packages/arborx/package.py +++ b/var/spack/repos/builtin/packages/arborx/package.py @@ -23,6 +23,7 @@ class Arborx(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("master", branch="master") + version("1.6", sha256="c2230de185d62f1999d36c6b8b92825f19ab9fbf30bdae90595cab04e76561a4") version("1.5", sha256="c26f23c17e749ccf3e2d353a68969aa54d31b8e720dbfdbc2cef16c5d8477e9e") version("1.4.1", sha256="2ca828ef6615859654b233a7df17017e7cfd904982b80026ec7409eb46b77a95") version("1.4", sha256="803a1018a6305cf3fea161172b3ada49537f59261279d91c2abbcce9492ee7af") @@ -36,6 +37,8 @@ class Arborx(CMakePackage, CudaPackage, ROCmPackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + # Allowed C++ standard variant( "cxxstd", @@ -65,6 +68,7 @@ class Arborx(CMakePackage, CudaPackage, ROCmPackage): depends_on("cmake@3.16:", type="build", when="@1.0:") depends_on("mpi", when="+mpi") depends_on("rocthrust", when="+rocm") + patch("0001-update-major-version-required-for-rocm-6.0.patch", when="@:1.5+rocm ^hip@6.0:") # Standalone Kokkos depends_on("kokkos@3.1.00:", when="~trilinos") @@ -72,6 +76,7 @@ class Arborx(CMakePackage, CudaPackage, ROCmPackage): depends_on("kokkos@3.6.00:", when="@1.3~trilinos") depends_on("kokkos@3.7.01:", when="@1.4:~trilinos") depends_on("kokkos@4.0.00:", when="@1.5:~trilinos") + depends_on("kokkos@4.1.00:", when="@1.6:~trilinos") for backend in kokkos_backends: depends_on("kokkos+%s" % backend.lower(), when="~trilinos+%s" % backend.lower()) @@ -95,8 +100,9 @@ class Arborx(CMakePackage, CudaPackage, ROCmPackage): depends_on("trilinos@13.2.0:", when="@1.2+trilinos") depends_on("trilinos@13.4.0:", when="@1.3+trilinos") depends_on("trilinos@14.0.0:", when="@1.4:+trilinos") + depends_on("trilinos@14.2.0:", when="@1.5:+trilinos") + depends_on("trilinos@14.4.0:", when="@1.6:+trilinos") patch("trilinos14.0-kokkos-major-version.patch", when="@1.4+trilinos ^trilinos@14.0.0") - patch("0001-update-major-version-required-for-rocm-6.0.patch", when="+rocm ^hip@6.0:") conflicts("~serial", when="+trilinos") conflicts("+cuda", when="+trilinos") @@ -132,12 +138,6 @@ def cached_tests_work_dir(self): def test_run_ctest(self): """run ctest tests on the installed package""" - - arborx_dir = self.spec["arborx"].prefix - cmake_prefix_path = f"-DCMAKE_PREFIX_PATH={arborx_dir}" - if "+mpi" in self.spec: - cmake_prefix_path += f";{self.spec['mpi'].prefix}" - cmake_args = [ ".", cmake_prefix_path, @@ -150,7 +150,10 @@ def test_run_ctest(self): else self.spec["trilinos"].prefix ), ), + self.define("ArborX_ROOT", self.spec["arborx".prefix]), ] + if "+mpi" in self.spec: + cmake_args.append(self.define("MPI_HOME", self.spec["mpi"].prefix)) cmake = which(self.spec["cmake"].prefix.bin.cmake) make = which("make") ctest = which("ctest") diff --git a/var/spack/repos/builtin/packages/arc/package.py b/var/spack/repos/builtin/packages/arc/package.py index afcad0a0beedd3..b14e81ca13ecdf 100644 --- a/var/spack/repos/builtin/packages/arc/package.py +++ b/var/spack/repos/builtin/packages/arc/package.py @@ -23,6 +23,8 @@ class Arc(CMakePackage): version("master", branch="master") version("2021-12-01", commit="49d4a5df53a082f15a6959aef434224fd7b9beac") + depends_on("c", type="build") # generated + depends_on("libpressio+sz+zfp", when="+examples") variant("examples", description="build examples", default=False) diff --git a/var/spack/repos/builtin/packages/archer/package.py b/var/spack/repos/builtin/packages/archer/package.py index 731d318365d310..d414ce5cdd7253 100644 --- a/var/spack/repos/builtin/packages/archer/package.py +++ b/var/spack/repos/builtin/packages/archer/package.py @@ -21,6 +21,9 @@ class Archer(CMakePackage): version("2.0.0", sha256="3241cadb0078403368b69166b27f815e12c350486d4ceb3fb33147895b9ebde8") version("1.0.0", sha256="df814a475606b83c659932caa30a68bed1c62e713386b375c1b78eb8d60e0d15") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.4.3:", type="build") depends_on("llvm@:8.0.0") depends_on("ninja@1.5:", type="build") diff --git a/var/spack/repos/builtin/packages/argobots/package.py b/var/spack/repos/builtin/packages/argobots/package.py index 7fc669553065b8..95af52ede50270 100644 --- a/var/spack/repos/builtin/packages/argobots/package.py +++ b/var/spack/repos/builtin/packages/argobots/package.py @@ -16,17 +16,20 @@ class Argobots(AutotoolsPackage): execution model and a memory model.""" homepage = "https://www.argobots.org/" - url = "https://github.com/pmodels/argobots/releases/download/v1.0b1/argobots-1.0b1.tar.gz" + url = "https://github.com/pmodels/argobots/releases/download/v1.2/argobots-1.2.tar.gz" git = "https://github.com/pmodels/argobots.git" - maintainers("shintaro-iwasaki") + maintainers("yfguo") tags = ["e4s"] version("main", branch="main") + version("1.2", sha256="1c056429d9c0a27c041d4734f6318b801fc2ec671854e42c35251c4c7d0d43e1") version("1.1", sha256="f0f971196fc8354881681c2282a2f2adb6d48ff5e84cf820ca657daad1549005") version("1.0.1", sha256="fa05a02d7f8f74d845647636609219ee02f6adf628ebcbf40393f829987d9036") version("1.0", sha256="36a0815f7bf99900a9c9c1eef61ef9b3b76aa2cfc4594a304f6c8c3296da8def") + depends_on("c", type="build") # generated + variant("perf", default=True, description="Add performance optimization flags") variant("valgrind", default=False, description="Enable Valgrind") variant("debug", default=False, description="Compiled with debugging symbols") diff --git a/var/spack/repos/builtin/packages/argon2/package.py b/var/spack/repos/builtin/packages/argon2/package.py index 4484e1eb52a4c9..f9227c9957e4d3 100644 --- a/var/spack/repos/builtin/packages/argon2/package.py +++ b/var/spack/repos/builtin/packages/argon2/package.py @@ -21,5 +21,7 @@ class Argon2(MakefilePackage): version("20171227", sha256="eaea0172c1f4ee4550d1b6c9ce01aab8d1ab66b4207776aa67991eb5872fdcd8") version("20161029", sha256="fe0049728b946b58b94cc6db89b34e2d050c62325d16316a534d2bedd78cd5e7") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make(f"PREFIX={prefix}", "install", "LIBRARY_REL=lib") diff --git a/var/spack/repos/builtin/packages/argp-standalone/package.py b/var/spack/repos/builtin/packages/argp-standalone/package.py index 9cdfdc81384458..3b5fe1efdcd077 100644 --- a/var/spack/repos/builtin/packages/argp-standalone/package.py +++ b/var/spack/repos/builtin/packages/argp-standalone/package.py @@ -18,6 +18,8 @@ class ArgpStandalone(AutotoolsPackage): version("1.3", sha256="dec79694da1319acd2238ce95df57f3680fea2482096e483323fddf3d818d8be") + depends_on("c", type="build") # generated + # Homebrew (https://github.com/Homebrew/homebrew-core) patches # argp-standalone to work on Darwin; the patchfile below was taken # from diff --git a/var/spack/repos/builtin/packages/args/package.py b/var/spack/repos/builtin/packages/args/package.py index 27c739b1684536..907cdb9370ea23 100644 --- a/var/spack/repos/builtin/packages/args/package.py +++ b/var/spack/repos/builtin/packages/args/package.py @@ -21,3 +21,5 @@ class Args(CMakePackage): version("6.2.3", sha256="c202d15fc4b30519a08bae7df9e6f4fdc40ac2434ba65d83a108ebbf6e4822c2") version("6.2.2", sha256="8016fb0fc079d746433be3df9cf662e3e931e730aaf9f69f2287eac79ac643c1") version("6.2.1", sha256="699b91fae4509b09974274838e2038612da24eeae89e62d0bc580457a9e261b0") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/argtable/package.py b/var/spack/repos/builtin/packages/argtable/package.py index 88604bbe50af3e..4da15c45a9bc83 100644 --- a/var/spack/repos/builtin/packages/argtable/package.py +++ b/var/spack/repos/builtin/packages/argtable/package.py @@ -17,3 +17,5 @@ class Argtable(AutotoolsPackage): license("LGPL-2.0-or-later") version("2-13", sha256="8f77e8a7ced5301af6e22f47302fdbc3b1ff41f2b83c43c77ae5ca041771ddbf") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/aria2/package.py b/var/spack/repos/builtin/packages/aria2/package.py index cdc82973200164..83bc44605a0d1e 100644 --- a/var/spack/repos/builtin/packages/aria2/package.py +++ b/var/spack/repos/builtin/packages/aria2/package.py @@ -20,6 +20,9 @@ class Aria2(AutotoolsPackage): version("1.35.0", sha256="fd85589416f8246cefc4e6ba2fa52da54fdf11fd5602a2db4b6749f7c33b5b2d") version("1.34.0", sha256="ec4866985760b506aa36dc9021dbdc69551c1a647823cae328c30a4f3affaa6c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libxml2") depends_on("libssh2") depends_on("libgcrypt") diff --git a/var/spack/repos/builtin/packages/arm-forge/package.py b/var/spack/repos/builtin/packages/arm-forge/package.py index 74dbbe5563c462..6d205f220949c9 100644 --- a/var/spack/repos/builtin/packages/arm-forge/package.py +++ b/var/spack/repos/builtin/packages/arm-forge/package.py @@ -22,6 +22,8 @@ class ArmForge(Package): # TODO: this mess should be fixed as soon as a way to parametrize/constrain # versions (and checksums) based on the target platform shows up + skip_version_audit = ["platform=windows"] + if platform.machine() in ["aarch64", "arm64"]: version( "22.1.3", sha256="131884f998b82673e885a7b42cc883210e3a0229b50af374092140cdfd42a408" diff --git a/var/spack/repos/builtin/packages/armadillo/package.py b/var/spack/repos/builtin/packages/armadillo/package.py index 3d33b0d38141c9..d22297cdd303d4 100644 --- a/var/spack/repos/builtin/packages/armadillo/package.py +++ b/var/spack/repos/builtin/packages/armadillo/package.py @@ -16,6 +16,8 @@ class Armadillo(CMakePackage): license("Apache-2.0") + version("12.8.3", sha256="2922589f6387796504b340da6bb954bef3d87574c298515893289edd2d890151") + version("12.8.2", sha256="03b62f8c09e4f5d74643b478520741b8e27b55e7e4525978fcae2f5d791ac3bf") version("12.8.1", sha256="2781dd3a6cc5f9a49c91a4519dde2b1c24335a5bfe0cc1c9881b6363142452b4") version("12.4.0", sha256="9905282781ced3f99769b0e45a705ecb50192ca1622300707b3302ea167dc883") version("12.2.0", sha256="b0dce042297e865add3351dad77f78c2c7638d6632f58357b015e50edcbd2186") @@ -25,6 +27,8 @@ class Armadillo(CMakePackage): version("8.100.1", sha256="54773f7d828bd3885c598f90122b530ded65d9b195c9034e082baea737cd138d") version("7.950.1", sha256="a32da32a0ea420b8397a53e4b40ed279c1a5fc791dd492a2ced81ffb14ad0d1b") + depends_on("cxx", type="build") # generated + variant("hdf5", default=False, description="Include HDF5 support") depends_on("cmake@2.8.12:", type="build") @@ -40,6 +44,14 @@ class Armadillo(CMakePackage): # platform's compiler is adding `#define linux 1`. patch("undef_linux.patch", when="platform=linux") + def flag_handler(self, name, flags): + spec = self.spec + if name == "ldflags": + if spec.satisfies("%apple-clang@15:"): + flags.append("-Wl,-ld_classic") + + return (flags, None, None) + def patch(self): # Do not include Find{BLAS_type} because we are specifying the # BLAS/LAPACK libraries explicitly. diff --git a/var/spack/repos/builtin/packages/armcimpi/package.py b/var/spack/repos/builtin/packages/armcimpi/package.py new file mode 100644 index 00000000000000..eed186a5ceb5b8 --- /dev/null +++ b/var/spack/repos/builtin/packages/armcimpi/package.py @@ -0,0 +1,51 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Armcimpi(AutotoolsPackage): + """ARMCI-MPI is an implementation of the ARMCI library used by Global Arrays. + MPI-3 one-sided communication is used to implement ARMCI. + """ + + homepage = "https://github.com/pmodels/armci-mpi" + url = "https://github.com/pmodels/armci-mpi/archive/refs/tags/v0.4.tar.gz" + + maintainers("jeffhammond") + + license("BSD-3-Clause", checked_by="jeffhammond") + + version("0.4", sha256="bcc3bb189b23bf653dcc69bc469eb86eae5ebc5ad94ab5f83e52ddbdbbebf1b1") + version( + "0.3.1-beta", sha256="f3eaa8f365fb55123ecd9ced401086b0732e37e4df592b27916d71a67ab34fe9" + ) + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("shared", default=True, description="Builds a shared version of the library") + variant("progress", default=False, description="Enable asynchronous progress") + + provides("armci") + + depends_on("autoconf", type="build") + depends_on("automake", type="build") + depends_on("libtool", type="build") + depends_on("m4", type="build") + + depends_on("mpi") + + def autoreconf(self, spec, prefix): + autoreconf("--install", "--verbose", "--force") + + def configure_args(self): + args = ["--enable-g"] + args.extend(self.enable_or_disable("shared")) + args.extend(self.with_or_without("progress")) + return args + + def setup_dependent_build_environment(self, env, dependent_spec): + env.set("ARMCIMPI_DIR", self.prefix) diff --git a/var/spack/repos/builtin/packages/armpl-gcc/package.py b/var/spack/repos/builtin/packages/armpl-gcc/package.py index 880f1267d7550d..d9629d786ffbef 100644 --- a/var/spack/repos/builtin/packages/armpl-gcc/package.py +++ b/var/spack/repos/builtin/packages/armpl-gcc/package.py @@ -21,7 +21,7 @@ "amzn2023": "RHEL-7", } -_os_map = { +_os_map_before_24 = { "ubuntu20.04": "Ubuntu-20.04", "ubuntu22.04": "Ubuntu-22.04", "sles15": "SLES-15", @@ -36,7 +36,27 @@ "amzn2023": "AmazonLinux-2023", } +_os_pkg_map = { + "ubuntu20.04": "deb", + "ubuntu22.04": "deb", + "sles15": "rpm", + "centos7": "rpm", + "centos8": "rpm", + "rhel7": "rpm", + "rhel8": "rpm", + "rhel9": "rpm", + "rocky8": "rpm", + "rocky9": "rpm", + "amzn2": "rpm", + "amzn2023": "rpm", +} + _versions = { + "24.04": { + "deb": ("a323074cd08af82f4d79988cc66088b18e47dea4b93323b1b8a0f994f769f2f0"), + "macOS": ("228bf3a2c25dbd45c2f89c78f455ee3c7dfb25e121c20d2765138b5174e688dc"), + "rpm": ("d3917523034cf5a35e4f31f9a8bf4e53e7cc97892e89739d5757cb65ce40dc2e"), + }, "23.10_gcc-12.2": { "RHEL-7": ("e5e2c69ad281a676f2a06c835fbf31d4f9fdf46aa3f3f7c8aafff46985f64902"), "RHEL-8": ("cc0f3572ead93d1e31797b7a39a40cff3414878df9bd24a452bf4877dc35ca4c"), @@ -227,28 +247,32 @@ } -def get_os(ver): +def get_os_or_pkg_manager(ver): platform = spack.platforms.host() if platform.name == "darwin": return "macOS" if ver.startswith("22."): return _os_map_before_23.get(platform.default_os, "") + elif ver.startswith("23."): + return _os_map_before_24.get(platform.default_os, "RHEL-7") else: - return _os_map.get(platform.default_os, "RHEL-7") + return _os_pkg_map.get(platform.default_os, "rpm") -def get_package_url(version): - base_url = "https://developer.arm.com/-/media/Files/downloads/hpc/arm-performance-libraries/" +def get_package_url_before_24(base_url, version): armpl_version = version.split("_")[0] armpl_version_dashed = armpl_version.replace(".", "-") compiler_version = version.split("_", 1)[1] - os = get_os(armpl_version) + os = get_os_or_pkg_manager(armpl_version) if os == "macOS": if armpl_version.startswith("23.06"): - return f"{base_url}{armpl_version_dashed}/armpl_{armpl_version}_{compiler_version}.dmg" + return ( + f"{base_url}/{armpl_version_dashed}/" + + f"armpl_{armpl_version}_{compiler_version}.dmg" + ) else: filename = f"arm-performance-libraries_{armpl_version}_macOS.dmg" - return f"{base_url}{armpl_version_dashed}/macos/{filename}" + return f"{base_url}/{armpl_version_dashed}/macos/{filename}" filename = f"arm-performance-libraries_{armpl_version}_{os}_{compiler_version}.tar" os_short = "" if armpl_version.startswith("22.0."): @@ -257,11 +281,51 @@ def get_package_url(version): os_short = os.split(".")[0].lower() if "amazonlinux" in os_short: os_short = os_short.replace("amazonlinux", "al") - return f"{base_url}{armpl_version_dashed}/{os_short}/{filename}" + return f"{base_url}/{armpl_version_dashed}/{os_short}/{filename}" + + +def get_package_url_from_24(base, version): + pkg_system = get_os_or_pkg_manager(version) + os = "macOS" if pkg_system == "macOS" else "linux" + + extension = "tgz" if pkg_system == "macOS" else "tar" + + full_name_library = f"arm-performance-libraries_{version}_{pkg_system}" + + if pkg_system != "macOS": + full_name_library = f"{full_name_library}_gcc" + file_name = f"{full_name_library}.{extension}" + + vn = version.replace(".", "-") + url_parts = f"{base}/{vn}/{os}/{file_name}" + return url_parts + + +def get_package_url(version): + base_url = "https://developer.arm.com/-/media/Files/downloads/hpc/arm-performance-libraries" + if version[:2] >= "24": + return get_package_url_from_24(base_url, version) + else: + return get_package_url_before_24(base_url, version) def get_armpl_prefix(spec): - return os.path.join(spec.prefix, "armpl_" + spec.version.string) + armpl_dir = [ + d + for d in os.listdir(spec.prefix) + if os.path.isdir(os.path.join(spec.prefix, d)) and d.startswith("armpl_") + ][0] + return os.path.join(spec.prefix, armpl_dir) + + +def get_armpl_suffix(spec): + suffix = "" + if spec.satisfies("@24:"): + suffix += "_ilp64" if spec.satisfies("+ilp64") else "_lp64" + else: + suffix += "_ilp64" if spec.satisfies("+ilp64") else "" + suffix += "_mp" if spec.satisfies("threads=openmp") else "" + return suffix class ArmplGcc(Package): @@ -269,12 +333,12 @@ class ArmplGcc(Package): high-performance computing applications on Arm processors.""" homepage = "https://developer.arm.com/tools-and-software/server-and-hpc/downloads/arm-performance-libraries" - url = "https://developer.arm.com/-/media/Files/downloads/hpc/arm-performance-libraries/23-04-1/ubuntu-22/arm-performance-libraries_23.04.1_Ubuntu-22.04_gcc-12.2.tar" + url = "https://developer.arm.com/-/media/Files/downloads/hpc/arm-performance-libraries/24-04/linux/arm-performance-libraries_24.04_deb_gcc.tar" - maintainers("annop-w") + maintainers("paolotricerri") for ver, packages in _versions.items(): - key = get_os(ver) + key = get_os_or_pkg_manager(ver) sha256sum = packages.get(key) url = get_package_url(ver) if sha256sum: @@ -319,6 +383,8 @@ class ArmplGcc(Package): conflicts("%gcc@:7", when="@22.0.1_gcc-8.2") conflicts("%gcc@:6", when="@22.0.1_gcc-7.5") + conflicts("%msvc", msg="Not compatible with MSVC compiler.") + variant("ilp64", default=False, description="use ilp64 specific Armpl library") variant("shared", default=True, description="enable shared libs") variant( @@ -339,10 +405,17 @@ def install(self, spec, prefix): hdiutil = which("hdiutil") # Mount image mountpoint = os.path.join(self.stage.path, "mount") - hdiutil("attach", "-mountpoint", mountpoint, self.stage.archive_file) + if spec.satisfies("@:23"): + dmg_file = self.stage.archive_file + else: + # The archive file only extracts to one .dmg file + dmg_file = os.path.join( + self.stage.source_path, os.listdir(self.stage.source_path)[0] + ) + hdiutil("attach", "-mountpoint", mountpoint, dmg_file) try: # Run installer - exe_name = f"armpl_{spec.version.string}_install.sh" + exe_name = [f for f in os.listdir(mountpoint) if f.endswith(".sh")][0] installer = Executable(os.path.join(mountpoint, exe_name)) installer("-y", f"--install_dir={prefix}") finally: @@ -357,15 +430,21 @@ def install(self, spec, prefix): with when("@23:"): armpl_version = spec.version.string.split("_")[0] - exe = Executable(f"./arm-performance-libraries_{armpl_version}_{get_os(armpl_version)}.sh") + if spec.satisfies("@:23"): + exe = Executable( + f"./arm-performance-libraries_{armpl_version}_" + + f"{get_os_or_pkg_manager(armpl_version)}.sh" + ) + else: + package_type = ( + "deb" if spack.platforms.host().default_os.startswith("ubuntu") else "rpm" + ) + exe = Executable(f"./arm-performance-libraries_{armpl_version}_{package_type}.sh") exe("--accept", "--force", "--install-to", prefix) @property def lib_suffix(self): - suffix = "" - suffix += "_ilp64" if self.spec.satisfies("+ilp64") else "" - suffix += "_mp" if self.spec.satisfies("threads=openmp") else "" - return suffix + return get_armpl_suffix(self.spec) @property def blas_libs(self): @@ -401,7 +480,10 @@ def libs(self): def headers(self): armpl_dir = get_armpl_prefix(self.spec) - suffix = "include" + self.lib_suffix + if self.spec.satisfies("@24:"): + suffix = "include" + else: + suffix = "include" + self.lib_suffix incdir = join_path(armpl_dir, suffix) @@ -419,7 +501,9 @@ def setup_run_environment(self, env): @run_after("install") def check_install(self): armpl_dir = get_armpl_prefix(self.spec) - armpl_example_dir = join_path(armpl_dir, "examples") + suffix = get_armpl_suffix(self.spec) + armpl_example_dir = join_path(armpl_dir, f"examples{suffix}") + # run example makefile if self.spec.platform == "darwin": # Fortran examples on MacOS requires flang-new which is diff --git a/var/spack/repos/builtin/packages/arpack-ng/package.py b/var/spack/repos/builtin/packages/arpack-ng/package.py index df345e65a75d1d..4036f6f8a660be 100644 --- a/var/spack/repos/builtin/packages/arpack-ng/package.py +++ b/var/spack/repos/builtin/packages/arpack-ng/package.py @@ -56,6 +56,10 @@ class ArpackNg(CMakePackage, AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") variant("mpi", default=True, description="Activates MPI support") variant("icb", default=False, when="@3.6:", description="Activates iso_c_binding support") diff --git a/var/spack/repos/builtin/packages/arrayfire/package.py b/var/spack/repos/builtin/packages/arrayfire/package.py index 23f7ad63e8e2e3..d934ae78a0718b 100644 --- a/var/spack/repos/builtin/packages/arrayfire/package.py +++ b/var/spack/repos/builtin/packages/arrayfire/package.py @@ -29,6 +29,9 @@ class Arrayfire(CMakePackage, CudaPackage): "3.7.0", commit="fbea2aeb6f7f2d277dcb0ab425a77bb18ed22291", submodules=True, tag="v3.7.0" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("forge", default=False, description="Enable graphics library") variant("opencl", default=False, description="Enable OpenCL backend") diff --git a/var/spack/repos/builtin/packages/arrow/package.py b/var/spack/repos/builtin/packages/arrow/package.py index 19e4cf1baaf6f7..7089454b67e78d 100644 --- a/var/spack/repos/builtin/packages/arrow/package.py +++ b/var/spack/repos/builtin/packages/arrow/package.py @@ -17,6 +17,8 @@ class Arrow(CMakePackage, CudaPackage): license("Apache-2.0") + version("16.1.0", sha256="9762d9ecc13d09de2a03f9c625a74db0d645cb012de1e9a10dfed0b4ddc09524") + version("15.0.2", sha256="4735b349845bff1fe95ed11abbfed204eb092cabc37523aa13a80cb830fe5b5e") version("14.0.2", sha256="07cdb4da6795487c800526b2865c150ab7d80b8512a31793e6a7147c8ccd270f") version("14.0.1", sha256="a48e54a09d58168bc04d86b13e7dab04f0aaba18a6f7e4dadf3e9c7bb835c8f1") version("14.0.0", sha256="39e3388bbaba23faa7a5e8a82ebba7fe4c38ace2c394d6a3f26559715b30f401") @@ -39,9 +41,13 @@ class Arrow(CMakePackage, CudaPackage): version("0.9.0", sha256="65f89a3910b6df02ac71e4d4283db9b02c5b3f1e627346c7b6a5982ae994af91") version("0.8.0", sha256="c61a60c298c30546fc0b418a35be66ef330fb81b06c49928acca7f1a34671d54") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost@1.60: +filesystem +system") depends_on("cmake@3.2.0:", type="build") depends_on("flatbuffers") + conflicts("%gcc@14", when="@:15.0.1") # https://github.com/apache/arrow/issues/40009 depends_on("llvm@:11 +clang", when="+gandiva @:3", type="build") depends_on("llvm@:12 +clang", when="+gandiva @:4", type="build") depends_on("llvm@:13 +clang", when="+gandiva @:7", type="build") diff --git a/var/spack/repos/builtin/packages/asagi/package.py b/var/spack/repos/builtin/packages/asagi/package.py index 603cd0ad198a59..17080d61031c35 100644 --- a/var/spack/repos/builtin/packages/asagi/package.py +++ b/var/spack/repos/builtin/packages/asagi/package.py @@ -24,6 +24,10 @@ class Asagi(CMakePackage): # is preferred to satisfy internal-dependencies version("1.0", commit="f67250798b435c308b9a1e7516f916f7855534ec", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "link_type", default="shared", diff --git a/var/spack/repos/builtin/packages/ascent/package.py b/var/spack/repos/builtin/packages/ascent/package.py index 40e030494ca329..32fd20a20a515f 100644 --- a/var/spack/repos/builtin/packages/ascent/package.py +++ b/var/spack/repos/builtin/packages/ascent/package.py @@ -55,13 +55,17 @@ class Ascent(CMakePackage, CudaPackage): version("develop", branch="develop", submodules=True) version( - "0.9.2", - tag="v0.9.2", - commit="b842516d12640e4a0d9433a18c7249440ef6fc3d", + "0.9.3", + tag="v0.9.3", + commit="e69d6ec77938846caae8fea7ed988b1151ac9b81", submodules=True, preferred=True, ) + version( + "0.9.2", tag="v0.9.2", commit="b842516d12640e4a0d9433a18c7249440ef6fc3d", submodules=True + ) + version( "0.9.1", tag="v0.9.1", commit="027a2fe184f65a4923817a8cdfed0b0c61c2c75a", submodules=True ) @@ -86,6 +90,10 @@ class Ascent(CMakePackage, CudaPackage): "0.6.0", tag="v0.6.0", commit="9ade37b0a9ea495e45adb25cda7498c0bf9465c5", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + ########################################################################### # package variants ########################################################################### @@ -155,6 +163,7 @@ class Ascent(CMakePackage, CudaPackage): depends_on("conduit@:0.7.2", when="@:0.7.1") depends_on("conduit@0.8.2:", when="@0.8:") depends_on("conduit@0.8.6:", when="@0.9:") + depends_on("conduit@0.9.1:", when="@0.9.3:") depends_on("conduit+python", when="+python") depends_on("conduit~python", when="~python") depends_on("conduit+mpi", when="+mpi") @@ -183,9 +192,18 @@ class Ascent(CMakePackage, CudaPackage): ####################### # RAJA and Umpire + # Note: Let RAJA/Umpire handle the Camp version constraints ####################### - depends_on("raja", when="+raja") - depends_on("umpire", when="+umpire") + with when("+raja"): + depends_on("raja") + depends_on("raja@2024.02.1:", when="@0.9.3:") + depends_on("raja+openmp", when="+openmp") + depends_on("raja~openmp", when="~openmp") + + with when("+umpire"): + depends_on("umpire") + depends_on("umpire@:2023.06.0", when="@:0.9.2") + depends_on("umpire@2024.02.1:", when="@0.9.3:") ####################### # BabelFlow @@ -212,6 +230,7 @@ class Ascent(CMakePackage, CudaPackage): depends_on("vtk-m~shared+fpic", when="@0.8.0: ~shared") # Ascent defaults to C++11 depends_on("kokkos cxxstd=11", when="+vtkh ^vtk-m +kokkos") + depends_on("kokkos@3.7.02", when="@0.9.3: +vtkh ^vtk-m +kokkos") ####################### # VTK-h @@ -492,7 +511,7 @@ def hostconfig(self): cfg.write("# Enable python module builds\n") cfg.write(cmake_cache_entry("ENABLE_PYTHON", "ON")) cfg.write("# python from spack \n") - cfg.write(cmake_cache_entry("PYTHON_EXECUTABLE", spec["python"].command.path)) + cfg.write(cmake_cache_entry("PYTHON_EXECUTABLE", python.path)) try: cfg.write("# python module install dir\n") cfg.write(cmake_cache_entry("PYTHON_MODULE_INSTALL_PREFIX", python_platlib)) diff --git a/var/spack/repos/builtin/packages/asciidoc/package.py b/var/spack/repos/builtin/packages/asciidoc/package.py index 2492052f570e5c..80f8e6bd97cb4b 100644 --- a/var/spack/repos/builtin/packages/asciidoc/package.py +++ b/var/spack/repos/builtin/packages/asciidoc/package.py @@ -6,7 +6,7 @@ from spack.package import * -class Asciidoc(AutotoolsPackage): +class Asciidoc(AutotoolsPackage, PythonPackage): """A presentable text document format for writing articles, UNIX man pages and other small to medium sized documents.""" @@ -17,7 +17,14 @@ class Asciidoc(AutotoolsPackage): license("GPL-2.0-only", checked_by="tgamblin") + build_system( + conditional("autotools", when="@:9"), + conditional("python_pip", when="@10:"), + default="python_pip", + ) + version("master", branch="master") + version("10.2.0", sha256="684ea53c1f5b71d6d1ac6086bbc96906b1f709ecc7ab536615b0f0c9e1baa3cc") version("9.1.0", sha256="5056c20157349f8dc74f005b6e88ccbf1078c4e26068876f13ca3d1d7d045fe7") version("9.0.5", sha256="edc8328c3682a8568172656f6fc309b189f65219a49517966c7ea144cb25f8b2") version("9.0.4", sha256="fb0e683ae6a4baf34a8969c3af764ca729526196576729ee9275b9f39fd8b79c") @@ -30,6 +37,9 @@ class Asciidoc(AutotoolsPackage): depends_on("docbook-xml", type=("build", "run")) depends_on("docbook-xsl", type=("build", "run")) depends_on("python@3.5:", type=("build", "run")) - depends_on("autoconf", type="build") - depends_on("automake", type="build") - depends_on("libtool", type="build") + with when("build_system=python_pip"): + depends_on("py-setuptools", type="build") + with when("build_system=autotools"): + depends_on("autoconf", type="build") + depends_on("automake", type="build") + depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/asdcplib/package.py b/var/spack/repos/builtin/packages/asdcplib/package.py index d0c37005d13e35..1379229232d3a6 100644 --- a/var/spack/repos/builtin/packages/asdcplib/package.py +++ b/var/spack/repos/builtin/packages/asdcplib/package.py @@ -20,6 +20,9 @@ class Asdcplib(AutotoolsPackage): version("2_10_33", sha256="16fafb5da3d46b0f44570ef9780c85dd82cca60106a9e005e538809ea1a95373") version("2_10_32", sha256="fe5123c49980ee3fa25dea876286f2ac974d203bfcc6c77fc288a59025dee3ee") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/asdf-cxx/package.py b/var/spack/repos/builtin/packages/asdf-cxx/package.py index b2d15a98142c78..069d3c7635c8e7 100644 --- a/var/spack/repos/builtin/packages/asdf-cxx/package.py +++ b/var/spack/repos/builtin/packages/asdf-cxx/package.py @@ -38,6 +38,8 @@ class AsdfCxx(CMakePackage): version("1.1.0", sha256="3e23b9cd16254f5adbf878145e320f56b4d3ad75de23d2c761eb7f04150926c5") version("1.0.0", sha256="0b63594a1dec27cc85d25adbf900b6e936b5015f579b9b892b983151bec96775") + depends_on("cxx", type="build") # generated + variant("python", default=True, description="Enable Python support") depends_on("bzip2") diff --git a/var/spack/repos/builtin/packages/asio/package.py b/var/spack/repos/builtin/packages/asio/package.py index 8a7a1c65209645..27d1acb3e79a4c 100644 --- a/var/spack/repos/builtin/packages/asio/package.py +++ b/var/spack/repos/builtin/packages/asio/package.py @@ -19,6 +19,9 @@ class Asio(AutotoolsPackage): license("BSL-1.0") # As uneven minor versions of asio are not considered stable, they wont be added anymore + version("1.30.2", sha256="755bd7f85a4b269c67ae0ea254907c078d408cce8e1a352ad2ed664d233780e8") + version("1.30.1", sha256="94b121cc2016680f2314ef58eadf169c2d34fff97fba01df325a192d502d3a58") + version("1.30.0", sha256="df6674bd790842b3a7422e9cc4c5d3212ac268cebdb5d38f3e783e4918313c7b") version("1.28.2", sha256="5705a0e403017eba276625107160498518838064a6dd7fd8b00b2e30c0ffbdee") version("1.28.1", sha256="5ff6111ec8cbe73a168d997c547f562713aa7bd004c5c02326f0e9d579a5f2ce") version("1.28.0", sha256="226438b0798099ad2a202563a83571ce06dd13b570d8fded4840dbc1f97fa328") @@ -59,6 +62,8 @@ class Asio(AutotoolsPackage): version("1.16.1", sha256="e40bbd531530f08318b7c7d7e84e457176d8eae6f5ad2e3714dc27b9131ecd35") version("1.16.0", sha256="c87410ea62de6245aa239b9ed2057edf01d7f66acc3f5e50add9a29343c87512") + depends_on("cxx", type="build") + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("m4", type="build") diff --git a/var/spack/repos/builtin/packages/aspa/package.py b/var/spack/repos/builtin/packages/aspa/package.py index 2356a09bd6b538..0e56447380c481 100644 --- a/var/spack/repos/builtin/packages/aspa/package.py +++ b/var/spack/repos/builtin/packages/aspa/package.py @@ -21,6 +21,8 @@ class Aspa(MakefilePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Build with MPI Support") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/aspcud/package.py b/var/spack/repos/builtin/packages/aspcud/package.py index fcd2675ac3bf36..6d6d50546a38c6 100644 --- a/var/spack/repos/builtin/packages/aspcud/package.py +++ b/var/spack/repos/builtin/packages/aspcud/package.py @@ -24,6 +24,9 @@ class Aspcud(CMakePackage): version("1.9.5", sha256="9cd3a9490d377163d87b16fa1a10cc7254bc2dbb9f60e846961ac8233f3835cf") version("1.9.4", sha256="3645f08b079e1cc80e24cd2d7ae5172a52476d84e3ec5e6a6c0034492a6ea885") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost@1.74:+exception+serialization+container", type=("build"), when="@1.9.5:") depends_on("cmake", type=("build")) depends_on("re2c", type=("build")) diff --git a/var/spack/repos/builtin/packages/aspect/package.py b/var/spack/repos/builtin/packages/aspect/package.py index 914869a2e5e2ed..1f627498732042 100644 --- a/var/spack/repos/builtin/packages/aspect/package.py +++ b/var/spack/repos/builtin/packages/aspect/package.py @@ -25,6 +25,10 @@ class Aspect(CMakePackage): version("2.0.1", sha256="0bf5600c42afce9d39c1d285b0654ecfdeb0f30e9f3421651c95f54ca01ac165") version("2.0.0", sha256="d485c07f54248e824bdfa35f3eec8971b65e8b7114552ffa2c771bc0dede8cc0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "build_type", default="Release", diff --git a/var/spack/repos/builtin/packages/aspell/package.py b/var/spack/repos/builtin/packages/aspell/package.py index 2cda1b9ac045de..affaa1c10260d9 100644 --- a/var/spack/repos/builtin/packages/aspell/package.py +++ b/var/spack/repos/builtin/packages/aspell/package.py @@ -21,5 +21,8 @@ class Aspell(AutotoolsPackage, GNUMirrorPackage): version("0.60.8", sha256="f9b77e515334a751b2e60daab5db23499e26c9209f5e7b7443b05235ad0226f2") version("0.60.6.1", sha256="f52583a83a63633701c5f71db3dc40aab87b7f76b29723aeb27941eff42df6e1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("fix_cpp.patch") patch("issue-519.patch", when="@:0.60.6.1") diff --git a/var/spack/repos/builtin/packages/assimp/package.py b/var/spack/repos/builtin/packages/assimp/package.py index d8eb67bc57f544..9fd69d85b4fb18 100644 --- a/var/spack/repos/builtin/packages/assimp/package.py +++ b/var/spack/repos/builtin/packages/assimp/package.py @@ -19,6 +19,8 @@ class Assimp(CMakePackage): license("BSD-3-Clause") version("master", branch="master") + version("5.4.2", sha256="7414861a7b038e407b510e8b8c9e58d5bf8ca76c9dfe07a01d20af388ec5086a") + version("5.4.0", sha256="a90f77b0269addb2f381b00c09ad47710f2aab6b1d904f5e9a29953c30104d3f") version("5.3.1", sha256="a07666be71afe1ad4bc008c2336b7c688aca391271188eb9108d0c6db1be53f1") version("5.2.5", sha256="b5219e63ae31d895d60d98001ee5bb809fb2c7b2de1e7f78ceeb600063641e1a") version("5.2.4", sha256="6a4ff75dc727821f75ef529cea1c4fc0a7b5fc2e0a0b2ff2f6b7993fe6cb54ba") @@ -30,6 +32,9 @@ class Assimp(CMakePackage): version("5.0.1", sha256="11310ec1f2ad2cd46b95ba88faca8f7aaa1efe9aa12605c55e3de2b977b3dbfc") version("4.0.1", sha256="60080d8ab4daaab309f65b3cffd99f19eb1af8d05623fff469b9b652818e286e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch( "https://patch-diff.githubusercontent.com/raw/assimp/assimp/pull/4203.patch?full_index=1", sha256="24135e88bcef205e118f7a3f99948851c78d3f3e16684104dc603439dd790d74", @@ -38,6 +43,9 @@ class Assimp(CMakePackage): variant("shared", default=True, description="Enables the build of shared libraries") + depends_on("cmake@3.10:", type="build", when="@5.1:") + depends_on("cmake@3.22:", type="build", when="@5.4:") + depends_on("pkgconfig", type="build") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/astral/package.py b/var/spack/repos/builtin/packages/astral/package.py index 4a06d3658a0eca..a430bda03cf82b 100644 --- a/var/spack/repos/builtin/packages/astral/package.py +++ b/var/spack/repos/builtin/packages/astral/package.py @@ -25,7 +25,7 @@ class Astral(Package): ) version("4.10.7", sha256="314b49e0129ec06a7c78a1b60d590259ede6a5e75253407031e108d8048fcc79") - depends_on("java", type=("build", "run")) + depends_on("java@11", type=("build", "run")) depends_on("zip", type="build") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/astyle/package.py b/var/spack/repos/builtin/packages/astyle/package.py index 716a5f7c1e6529..202b0af22102b8 100644 --- a/var/spack/repos/builtin/packages/astyle/package.py +++ b/var/spack/repos/builtin/packages/astyle/package.py @@ -30,6 +30,8 @@ class Astyle(CMakePackage, MakefilePackage): version("2.05.1", sha256="fbdfc6f1966a972d19a215927266c76d4183eee235ed1e2bd7ec551c2a270eac") version("2.04", sha256="70b37f4853c418d1e2632612967eebf1bdb93dfbe558c51d7d013c9b4e116b60") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.8.0:", type="build", when="@3.2.0:") build_system(conditional("cmake", when="@3.2.0:"), "makefile", default="cmake") diff --git a/var/spack/repos/builtin/packages/at-spi2-atk/package.py b/var/spack/repos/builtin/packages/at-spi2-atk/package.py index 5d421477584255..85233ec111fcf1 100644 --- a/var/spack/repos/builtin/packages/at-spi2-atk/package.py +++ b/var/spack/repos/builtin/packages/at-spi2-atk/package.py @@ -22,6 +22,8 @@ class AtSpi2Atk(MesonPackage): version("2.26.2", sha256="61891f0abae1689f6617a963105a3f1dcdab5970c4a36ded9c79a7a544b16a6e") version("2.26.1", sha256="b4f0c27b61dbffba7a5b5ba2ff88c8cee10ff8dac774fa5b79ce906853623b75") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("at-spi2-core@2.28.0:") depends_on("atk@2.28.1:") diff --git a/var/spack/repos/builtin/packages/at-spi2-core/package.py b/var/spack/repos/builtin/packages/at-spi2-core/package.py index cc8911a29c36a1..8be998302e4f8d 100644 --- a/var/spack/repos/builtin/packages/at-spi2-core/package.py +++ b/var/spack/repos/builtin/packages/at-spi2-core/package.py @@ -27,6 +27,8 @@ class AtSpi2Core(MesonPackage): version("2.36.0", sha256="88da57de0a7e3c60bc341a974a80fdba091612db3547c410d6deab039ca5c05a") version("2.28.0", sha256="42a2487ab11ce43c288e73b2668ef8b1ab40a0e2b4f94e80fca04ad27b6f1c87") + depends_on("c", type="build") # generated + depends_on("meson@0.46.0:", type="build") depends_on("glib@2.56.1:") depends_on("glib@2.68.1:", when="@2.51.91:") diff --git a/var/spack/repos/builtin/packages/atf/package.py b/var/spack/repos/builtin/packages/atf/package.py index a0916aec82a495..979211cab3b864 100644 --- a/var/spack/repos/builtin/packages/atf/package.py +++ b/var/spack/repos/builtin/packages/atf/package.py @@ -19,6 +19,9 @@ class Atf(AutotoolsPackage): version("0.20", sha256="3677cf957d7f574835b8bdd385984ba928d5695b3ff28f958e4227f810483ab7") version("0.19", sha256="f9b1d76dad7c34ae61a75638edc517fc05b10fa4c8f97b1d13d739bffee79b16") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/athena/package.py b/var/spack/repos/builtin/packages/athena/package.py index cf4da42d09283a..a49982a0b405a4 100644 --- a/var/spack/repos/builtin/packages/athena/package.py +++ b/var/spack/repos/builtin/packages/athena/package.py @@ -18,6 +18,8 @@ class Athena(AutotoolsPackage): version("master", branch="master") version("4.2", sha256="6334848d7f1325aa44859418feac8ce223b56793ae8907103000af5b27f50e7e") + depends_on("c", type="build") # generated + # PHYSICS "packages": variant( "problem", diff --git a/var/spack/repos/builtin/packages/atk/package.py b/var/spack/repos/builtin/packages/atk/package.py index bcb6425b081521..6bebc59054cc2f 100644 --- a/var/spack/repos/builtin/packages/atk/package.py +++ b/var/spack/repos/builtin/packages/atk/package.py @@ -34,6 +34,8 @@ class Atk(Package): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("meson@0.40.1:", type="build", when="@2.28:") depends_on("meson@0.46.0:", type="build", when="@2.29:") depends_on("glib") diff --git a/var/spack/repos/builtin/packages/atlas/package.py b/var/spack/repos/builtin/packages/atlas/package.py index 89e65bc878f6f1..026cf000d68b0f 100644 --- a/var/spack/repos/builtin/packages/atlas/package.py +++ b/var/spack/repos/builtin/packages/atlas/package.py @@ -34,6 +34,9 @@ class Atlas(Package): ) version("3.10.2", sha256="3aab139b118bf3fcdb4956fbd71676158d713ab0d3bccb2ae1dc3769db22102f") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # not all packages (e.g. Trilinos@12.6.3) stopped using deprecated in 3.6.0 # Lapack routines. Stick with 3.5.0 until this is fixed. resource( @@ -61,6 +64,12 @@ class Atlas(Package): description="Number of threads to tune to, " "-1 for autodetect, 0 for no threading", ) + conflicts( + "platform=windows", + msg="Atlas requires cygwin to build on Windows, which is unsupported by Spack. " + "See https://math-atlas.sourceforge.net/atlas_install/node55.html", + ) + provides("blas") provides("lapack") provides("lapack@3.6.1") diff --git a/var/spack/repos/builtin/packages/atmi/package.py b/var/spack/repos/builtin/packages/atmi/package.py index 07c9e9fe4397b0..439f2c27796e4e 100644 --- a/var/spack/repos/builtin/packages/atmi/package.py +++ b/var/spack/repos/builtin/packages/atmi/package.py @@ -23,33 +23,18 @@ class Atmi(CMakePackage): maintainers("srekolam", "renjithravindrankannath") version("5.5.1", sha256="6b3ee68433506315b55d093a4b47463916874fb6f3f602098eaff2ec283e69ab") version("5.5.0", sha256="b8bfd32e5c386f5169da62172964343f9b7fad207e0e74dd1093c7acf06d9811") - version("5.4.3", sha256="243aae6614e5bd136a099102957a6d65a01434b620291349613ad63701868ef8") - version("5.4.0", sha256="b5cce10d7099fecbb40a0d9c2f29a7675315471fe145212b375e37e4c8ba5618") - version("5.3.3", sha256="cc1144e4939cea2944f6c72a21406b9dc5b56d933696494074c280df7469834a") - version("5.3.0", sha256="dffc0eb0bc1617843e7f728dbd6c8b12326c5c8baa34369aa267aab40f5deb6a") with default_args(deprecated=True): - version("5.2.3", sha256="5f66c59e668cf968e86b556a0a52ee0202d1b370d8406e291a874cbfd200ee17") - version("5.2.1", sha256="6b33445aa67444c038cd756f855a58a72dd35db57e7b63da37fe78a8585b982b") - version("5.2.0", sha256="33e77905a607734157d46c736c924c7c50b6b13f2b2ddbf711cb08e37f2efa4f") - version("5.1.3", sha256="a43448d77705b2b07e1758ffe8035aa6ba146abc2167984e8cb0f1615797b341") - version("5.1.0", sha256="6a758f5a8332e6774cd8e14a4e5ce05e43b1e05298d817b4068c35fa1793d333") + version("5.4.3", sha256="243aae6614e5bd136a099102957a6d65a01434b620291349613ad63701868ef8") + version("5.4.0", sha256="b5cce10d7099fecbb40a0d9c2f29a7675315471fe145212b375e37e4c8ba5618") + version("5.3.3", sha256="cc1144e4939cea2944f6c72a21406b9dc5b56d933696494074c280df7469834a") + version("5.3.0", sha256="dffc0eb0bc1617843e7f728dbd6c8b12326c5c8baa34369aa267aab40f5deb6a") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("cmake@3:", type="build") depends_on("rsync") - - for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", - "5.3.0", - "5.3.3", - "5.4.0", - "5.4.3", - "5.5.0", - "5.5.1", - ]: + for ver in ["5.3.0", "5.3.3", "5.4.0", "5.4.3", "5.5.0", "5.5.1"]: depends_on(f"comgr@{ver}", type="link", when=f"@{ver}") depends_on(f"hsa-rocr-dev@{ver}", type="link", when=f"@{ver}") depends_on("elf", type="link", when=f"@{ver}") @@ -59,8 +44,6 @@ class Atmi(CMakePackage): root_cmakelists_dir = "src" - # Reset the installation path and remove direct reference to rsync. - patch("0002-Remove-usr-bin-rsync-reference-5.2.0.patch", when="@5.0.2:5.2.0") # Remove direct reference to /usr/bin/rsync path for rsync command patch( "0002-Remove-direct-reference-to-usr-bin-rysnc-for-rsync-cmd-5.2.1.patch", when="@5.2.1:" diff --git a/var/spack/repos/builtin/packages/atompaw/package.py b/var/spack/repos/builtin/packages/atompaw/package.py index c056dedccba596..cf062ef3aeebfc 100644 --- a/var/spack/repos/builtin/packages/atompaw/package.py +++ b/var/spack/repos/builtin/packages/atompaw/package.py @@ -29,6 +29,10 @@ class Atompaw(AutotoolsPackage): version("4.0.0.13", sha256="cbd73f11f3e9cc3ff2e5f3ec87498aeaf439555903d0b95a72f3b0a021902020") version("3.1.0.3", sha256="15fe9a0369bdcc366370a0ecaa67e803ae54534b479ad63c4c7494a04fa3ea78") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("lapack") depends_on("blas") diff --git a/var/spack/repos/builtin/packages/atop/package.py b/var/spack/repos/builtin/packages/atop/package.py index f87d6c0c6ada94..1136b5741bdb01 100644 --- a/var/spack/repos/builtin/packages/atop/package.py +++ b/var/spack/repos/builtin/packages/atop/package.py @@ -20,6 +20,8 @@ class Atop(Package): version("2.2.6", sha256="d0386840ee4df36e5d0ad55f144661b434d9ad35d94deadc0405b514485db615") version("2.2-3", sha256="c785b8a2355be28b3de6b58a8ea4c4fcab8fadeaa57a99afeb03c66fac8e055d") + depends_on("c", type="build") # generated + depends_on("zlib-api") depends_on("ncurses") diff --git a/var/spack/repos/builtin/packages/attr/package.py b/var/spack/repos/builtin/packages/attr/package.py index 3ab1244986fcc2..d8659708493611 100644 --- a/var/spack/repos/builtin/packages/attr/package.py +++ b/var/spack/repos/builtin/packages/attr/package.py @@ -18,6 +18,8 @@ class Attr(AutotoolsPackage): version("2.4.47", sha256="25772f653ac5b2e3ceeb89df50e4688891e21f723c460636548971652af0a859") version("2.4.46", sha256="dcd69bdca7ff166bc45141eddbcf21967999a6b66b0544be12a1cc2fd6340e1f") + depends_on("c", type="build") # generated + def url_for_version(self, version): if version >= Version("2.4.48"): url = "http://download.savannah.gnu.org/releases/attr/attr-{0}.tar.gz" diff --git a/var/spack/repos/builtin/packages/audacious/package.py b/var/spack/repos/builtin/packages/audacious/package.py index d6737186f5ee1c..2ee953de775767 100644 --- a/var/spack/repos/builtin/packages/audacious/package.py +++ b/var/spack/repos/builtin/packages/audacious/package.py @@ -19,6 +19,9 @@ class Audacious(AutotoolsPackage): version("3.10.1", sha256="c478939b4bcf6704c26eee87d48cab26547e92a83741f437711178c433373fa1") version("3.10", sha256="82710d6ac90931c2cc4a0f0fcb6380ac21ed42a7a50856d16a67d3179a96e9ae") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/audacity/package.py b/var/spack/repos/builtin/packages/audacity/package.py index 9e3332032ceaf9..9e97c93a7f344a 100644 --- a/var/spack/repos/builtin/packages/audacity/package.py +++ b/var/spack/repos/builtin/packages/audacity/package.py @@ -22,4 +22,7 @@ class Audacity(CMakePackage): version("2.4.1", sha256="50240f07471373a7e5c2df65cc26eeeaaced9a0850ad1f95cb795f171ea3009f") version("2.4.0", sha256="5d1c096d7b04ff8d5dbca3dca5b9d9f8e62093b5ea6e57ae5f821ae3132dc88f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("wxwidgets") diff --git a/var/spack/repos/builtin/packages/audit-userspace/package.py b/var/spack/repos/builtin/packages/audit-userspace/package.py index b38e3aee291578..1c719a9753990a 100644 --- a/var/spack/repos/builtin/packages/audit-userspace/package.py +++ b/var/spack/repos/builtin/packages/audit-userspace/package.py @@ -14,12 +14,15 @@ class AuditUserspace(AutotoolsPackage): license("LGPL-2.1-or-later") + version("4.0.1", sha256="f964610dc0c1e68075d5ae4b14d6280d1164b6eca3a4a13721d1a711681403d9") version("3.1.1", sha256="6a97cc472920639d736e9927353be05e323f351067fcf6e5d34439cafa0e9006") version("2.8.5", sha256="835ffdd65056ba0c26509dbf48882713b00dbe70e1d8cf25d538501136c2e3e9") version("2.8.4", sha256="089dfdceb38edf056202a6de4892fd0c9aaa964c08bd7806c5d0c7c33f09e18d") version("2.8.3", sha256="c239e3813b84bc264aaf2f796c131c1fe02960244f789ec2bd8d88aad4561b29") version("2.8.2", sha256="0a312a8487190d97715d46abb30aa2abd464b55f21d5c2d24428baa320ee4ce2") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/augustus/package.py b/var/spack/repos/builtin/packages/augustus/package.py index a80de62d02f479..6a28651cee4d00 100644 --- a/var/spack/repos/builtin/packages/augustus/package.py +++ b/var/spack/repos/builtin/packages/augustus/package.py @@ -38,6 +38,9 @@ class Augustus(MakefilePackage): url="https://bioinf.uni-greifswald.de/augustus/binaries/old/augustus-3.2.3.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl", type=("build", "run")) depends_on("python", when="@3.3.1:", type=("build", "run")) depends_on("bamtools") diff --git a/var/spack/repos/builtin/packages/authd/package.py b/var/spack/repos/builtin/packages/authd/package.py index 230d32196ef88e..fa02a85c18c533 100644 --- a/var/spack/repos/builtin/packages/authd/package.py +++ b/var/spack/repos/builtin/packages/authd/package.py @@ -18,6 +18,8 @@ class Authd(MakefilePackage): version("1.4.4", sha256="71ee3d1c3e107c93e082148f75ee460c949b203c861dd20d48f7c5cfdc272bf8") + depends_on("c", type="build") # generated + def setup_run_environment(self, env): env.prepend_path("PATH", self.prefix.sbin) diff --git a/var/spack/repos/builtin/packages/authselect/package.py b/var/spack/repos/builtin/packages/authselect/package.py index fb61a06610ece3..9bdd979206af47 100644 --- a/var/spack/repos/builtin/packages/authselect/package.py +++ b/var/spack/repos/builtin/packages/authselect/package.py @@ -18,6 +18,8 @@ class Authselect(AutotoolsPackage): version("1.2", sha256="c354c87a0115612cb51b09b5157f151569e16384cdd69f32b8515209036531b4") version("1.1", sha256="39b888575980c1ecac7022dfe5a5452eef59cef850b8544ed5f928e2e8a335dd") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/autoconf/package.py b/var/spack/repos/builtin/packages/autoconf/package.py index b202e604602c1a..94489a1194b159 100644 --- a/var/spack/repos/builtin/packages/autoconf/package.py +++ b/var/spack/repos/builtin/packages/autoconf/package.py @@ -52,8 +52,8 @@ class Autoconf(AutotoolsPackage, GNUMirrorPackage): # Note: m4 is not a pure build-time dependency of autoconf. m4 is # needed when autoconf runs, not only when autoconf is built. - depends_on("m4@1.4.8:", type=("build", "run"), when="@1.72:") - depends_on("m4@1.4.6:", type=("build", "run"), when="@:1.71") + depends_on("m4@1.4.8:", type=("build", "run"), when="@2.72:") + depends_on("m4@1.4.6:", type=("build", "run"), when="@:2.71") depends_on("perl", type=("build", "run")) build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/autodiff/package.py b/var/spack/repos/builtin/packages/autodiff/package.py index ac7b50477e43be..78dca3bc183b93 100644 --- a/var/spack/repos/builtin/packages/autodiff/package.py +++ b/var/spack/repos/builtin/packages/autodiff/package.py @@ -14,7 +14,7 @@ class Autodiff(CMakePackage): list_url = "https://github.com/autodiff/autodiff/tags" git = "https://github.com/autodiff/autodiff.git" - maintainers("wdconinc", "HadrienG2") + maintainers("wdconinc") license("MIT") @@ -31,6 +31,8 @@ class Autodiff(CMakePackage): version("0.6.4", sha256="cfe0bb7c0de10979caff9d9bfdad7e6267faea2b8d875027397486b47a7edd75") version("0.5.13", sha256="a73dc571bcaad6b44f74865fed51af375f5a877db44321b5568d94a4358b77a1") + depends_on("cxx", type="build") # generated + variant("python", default=False, description="Enable the compilation of the python bindings.") variant("examples", default=False, description="Enable the compilation of the example files.") diff --git a/var/spack/repos/builtin/packages/autodock-gpu/package.py b/var/spack/repos/builtin/packages/autodock-gpu/package.py index e687cfd4ce73b3..f37859b13f581c 100644 --- a/var/spack/repos/builtin/packages/autodock-gpu/package.py +++ b/var/spack/repos/builtin/packages/autodock-gpu/package.py @@ -22,6 +22,8 @@ class AutodockGpu(MakefilePackage, CudaPackage): version("develop", branch="develop") + depends_on("cxx", type="build") # generated + variant( "device", default="cuda", diff --git a/var/spack/repos/builtin/packages/autodock-vina/package.py b/var/spack/repos/builtin/packages/autodock-vina/package.py index f1cfa5694c303e..b4104e99377712 100644 --- a/var/spack/repos/builtin/packages/autodock-vina/package.py +++ b/var/spack/repos/builtin/packages/autodock-vina/package.py @@ -27,6 +27,8 @@ class AutodockVina(MakefilePackage): url="https://github.com/ccsb-scripps/AutoDock-Vina/archive/refs/tags/v1.1.2-boost-new.tar.gz", ) + depends_on("cxx", type="build") # generated + depends_on( "boost@1.50.0:1.75.0 +filesystem +program_options +serialization +system +thread", when="@1.1.2", diff --git a/var/spack/repos/builtin/packages/autogen/package.py b/var/spack/repos/builtin/packages/autogen/package.py index 895970b374eb66..215e3793452d29 100644 --- a/var/spack/repos/builtin/packages/autogen/package.py +++ b/var/spack/repos/builtin/packages/autogen/package.py @@ -21,6 +21,8 @@ class Autogen(AutotoolsPackage, GNUMirrorPackage): version("5.18.12", sha256="805c20182f3cb0ebf1571d3b01972851c56fb34348dfdc38799fd0ec3b2badbe") + depends_on("c", type="build") # generated + variant("xml", default=True, description="Enable XML support") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/automaded/package.py b/var/spack/repos/builtin/packages/automaded/package.py index bd488830d08934..4006fbaf888b70 100644 --- a/var/spack/repos/builtin/packages/automaded/package.py +++ b/var/spack/repos/builtin/packages/automaded/package.py @@ -24,6 +24,8 @@ class Automaded(CMakePackage): version("1.0", sha256="600740cdd594cc6968c7bcb285d0829eb0ddbd5597c32c06c6ae5d9929a2625d") + depends_on("cxx", type="build") # generated + depends_on("mpi") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/automake/package.py b/var/spack/repos/builtin/packages/automake/package.py index d0ae1456edcacf..3e5d07085a9c2d 100644 --- a/var/spack/repos/builtin/packages/automake/package.py +++ b/var/spack/repos/builtin/packages/automake/package.py @@ -25,6 +25,8 @@ class Automake(AutotoolsPackage, GNUMirrorPackage): version("1.13.4", sha256="4c93abc0bff54b296f41f92dd3aa1e73e554265a6f719df465574983ef6f878c") version("1.11.6", sha256="53dbf1945401c43f4ce19c1971baecdbf8bc32e0f37fa3f49fe7b6992d0d2030") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("perl+threads", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/aws-ofi-nccl/package.py b/var/spack/repos/builtin/packages/aws-ofi-nccl/package.py index d064393199db5d..adb7474869c4f3 100644 --- a/var/spack/repos/builtin/packages/aws-ofi-nccl/package.py +++ b/var/spack/repos/builtin/packages/aws-ofi-nccl/package.py @@ -12,12 +12,21 @@ class AwsOfiNccl(AutotoolsPackage): applications.""" homepage = "https://github.com/aws/aws-ofi-nccl" + url = "https://github.com/aws/aws-ofi-nccl/archive/v0.0.0.tar.gz" git = "https://github.com/aws/aws-ofi-nccl.git" - url = "https://github.com/aws/aws-ofi-nccl.git" maintainers("bvanessen") version("master", branch="master") + version("1.8.1", sha256="beb59959be0f60b891f9549f4df51b394e97e739416c88c3436e75516fe067c8") + version("1.8.0", sha256="a2f1750d4908924985335e513186353d0c4d9a5d27b1a759f6aa31a10e74c06d") + version("1.7.4", sha256="472bbc977ce37d0cf9239b8e366f4f247226a984eb8c487aadd884af53f00e13") + version("1.7.3", sha256="7a49b530eb0fa5e262c1fcf3412289bc1d538c15290435c579d5e7f08d806fd4") + version("1.7.2", sha256="c89bbe5fa49a7036eb873c01c8fdc5693238ae010ddcaf10b10fdc88aec6e56a") + version("1.7.1", sha256="d50a160c7aba76445e5c895fba0f3dbfdec51f702d218168a5e5017806cf0fb0") + version("1.6.0", sha256="19a6fc91afe9a317fd3154c897fa219eab48fcdddefa66d881f1843c1165f7ee") + + depends_on("c", type="build") # generated variant("trace", default=False, description="Enable printing trace messages") variant("tests", default=False, description="Build tests") @@ -26,10 +35,17 @@ class AwsOfiNccl(AutotoolsPackage): depends_on("cuda") depends_on("nccl") depends_on("mpi") + depends_on("hwloc", when="@1.7:") depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") + def url_for_version(self, version): + if version < Version("1.7.0"): + return super().url_for_version(version) + url_fmt = "https://github.com/aws/aws-ofi-nccl/archive/v{0}-aws.tar.gz" + return url_fmt.format(version) + # To enable this plug-in to work with NCCL add it to the LD_LIBRARY_PATH def setup_run_environment(self, env): aws_ofi_nccl_home = self.spec.prefix @@ -54,6 +70,8 @@ def configure_args(self): "--with-mpi={0}".format(spec["mpi"].prefix), ] ) + if spec.satisfies("@1.7:"): + args.extend(["--with-hwloc={0}".format(spec["hwloc"].prefix)]) args.extend(self.enable_or_disable("trace")) args.extend(self.enable_or_disable("tests")) diff --git a/var/spack/repos/builtin/packages/aws-ofi-rccl/package.py b/var/spack/repos/builtin/packages/aws-ofi-rccl/package.py index f831c885375434..abb83477a423c5 100644 --- a/var/spack/repos/builtin/packages/aws-ofi-rccl/package.py +++ b/var/spack/repos/builtin/packages/aws-ofi-rccl/package.py @@ -23,6 +23,8 @@ class AwsOfiRccl(AutotoolsPackage): version("cxi", branch="cxi", preferred=True) version("master", branch="master") + depends_on("c", type="build") # generated + variant("trace", default=False, description="Enable printing trace messages") variant("tests", default=False, description="Build tests") diff --git a/var/spack/repos/builtin/packages/aws-sdk-cpp/package.py b/var/spack/repos/builtin/packages/aws-sdk-cpp/package.py index cdea77da7e8ef4..82227f0a6f7788 100644 --- a/var/spack/repos/builtin/packages/aws-sdk-cpp/package.py +++ b/var/spack/repos/builtin/packages/aws-sdk-cpp/package.py @@ -51,6 +51,9 @@ class AwsSdkCpp(CMakePackage): submodules=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build") depends_on("zlib-api") depends_on("curl") diff --git a/var/spack/repos/builtin/packages/awscli-v2/package.py b/var/spack/repos/builtin/packages/awscli-v2/package.py index dfa354430aa70c..15dad8150a3bbc 100644 --- a/var/spack/repos/builtin/packages/awscli-v2/package.py +++ b/var/spack/repos/builtin/packages/awscli-v2/package.py @@ -11,29 +11,32 @@ class AwscliV2(PythonPackage): homepage = "https://docs.aws.amazon.com/cli" url = "https://github.com/aws/aws-cli/archive/refs/tags/2.13.22.tar.gz" + list_url = "https://github.com/aws/aws-cli/tags" - maintainers("climbfuji") + maintainers("climbfuji", "teaguesterling") + version("2.15.53", sha256="a4f5fd4e09b8f2fb3d2049d0610c7b0993f9aafaf427f299439f05643b25eb4b") version("2.13.22", sha256="dd731a2ba5973f3219f24c8b332a223a29d959493c8a8e93746d65877d02afc1") - depends_on("python@3.8:", type=("build", "run")) - depends_on("py-flit-core@3.7.1:3.8.0", type=("build")) - depends_on("py-colorama@0.2.5:0.4.6", type=("build", "run")) - depends_on("py-docutils@0.10:0.19", type=("build", "run")) - depends_on("py-cryptography@3.3.2:40.0.1", type=("build", "run")) - depends_on("py-ruamel-yaml@0.15:0.17.21", type=("build", "run")) - depends_on("py-ruamel-yaml-clib@0.2:0.2.7", type=("build", "run")) - depends_on("py-prompt-toolkit@3.0.24:3.0.38", type=("build", "run")) - depends_on("py-distro@1.5:1.8", type=("build", "run")) - depends_on("py-awscrt@0.16.4:0.16.16", type=("build", "run")) - depends_on("py-python-dateutil@2.1:2", type=("build", "run")) - depends_on("py-jmespath@0.7.1:1.0", type=("build", "run")) - depends_on("py-urllib3@1.25.4:1.26", type=("build", "run")) + with default_args(type=("build", "run")): + depends_on("python@3.8:") + depends_on("py-flit-core@3.7.1:3.8.0") + depends_on("py-colorama@0.2.5:0.4.6") + depends_on("py-docutils@0.10:0.19") + depends_on("py-cryptography@3.3.2:40.0.1") + depends_on("py-ruamel-yaml@0.15:0.17.21") + depends_on("py-ruamel-yaml-clib@0.2:0.2.7", when="^python@:3.9") + depends_on("py-prompt-toolkit@3.0.24:3.0.38") + depends_on("py-distro@1.5:1.8") + depends_on("py-awscrt@0.16.4:0.16.16", when="@2.13") + depends_on("py-awscrt@0.19.18:0.19.19", when="@2.15") + depends_on("py-python-dateutil@2.1:2.8.2") + depends_on("py-jmespath@0.7.1:1.0") + depends_on("py-urllib3@1.25.4:1.26") variant("examples", default=True, description="Install code examples") - @run_after("install") - @when("~examples") + @run_after("install", when="~examples") def post_install(self): examples_dir = join_path(python_purelib, "awscli", "examples") remove_directory_contents(examples_dir) diff --git a/var/spack/repos/builtin/packages/axel/package.py b/var/spack/repos/builtin/packages/axel/package.py index 75990f4f940ca4..93cf39625345ec 100644 --- a/var/spack/repos/builtin/packages/axel/package.py +++ b/var/spack/repos/builtin/packages/axel/package.py @@ -14,14 +14,23 @@ class Axel(AutotoolsPackage): license("GPL-2.0-or-later WITH OpenSSL-Exception") + version("2.17.14", sha256="73f3aeafcb00b8101b212fcf47969a4962e7a1b50843306178b527a9942d8785") version("2.17.13", sha256="aedd5e0f22d6eda23eece483ce89be4adfdf1e16ba18d54fd6b743da9d49911b") version("2.17.10", sha256="c0d26eba6b94945cd98c5b69ca6df2744639d17bfd49047ef51a8a48f067de10") version("2.16.1", sha256="763066efc61e4f7be2eb59afa049bdbc520837e01c95a78f403e542ad82f2719") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") + # For systems not providing libintl APU in the system libc (glibc integrated it) depends_on("gettext") depends_on("openssl") - def installcheck(self): - Executable(self.prefix.bin.axel)("--version") + # check if we can run axel + @run_after("install") + @on_package_attributes(run_tests=True) + def check_version(self): + with working_dir(self.stage.source_path): + axel = Executable(self.prefix.bin.axel) + axel("--version") diff --git a/var/spack/repos/builtin/packages/axl/package.py b/var/spack/repos/builtin/packages/axl/package.py index 381d47578b06a6..998cdc8cd184d2 100644 --- a/var/spack/repos/builtin/packages/axl/package.py +++ b/var/spack/repos/builtin/packages/axl/package.py @@ -45,6 +45,8 @@ class Axl(CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("kvtree") depends_on("zlib-api", type="link") @@ -100,9 +102,6 @@ def cmake_args(self): args.append(self.define_from_variant("ENABLE_IBM_BBAPI", "bbapi")) args.append(self.define_from_variant("ENABLE_CRAY_DW", "dw")) args.append(self.define_from_variant("BUILD_SHARED_LIBS", "shared")) - else: - if spec.satisfies("platform=cray"): - args.append(self.define("AXL_LINK_STATIC", True)) if spec.satisfies("@0.6.0:"): args.append(self.define_from_variant("ENABLE_PTHREADS", "pthreads")) diff --git a/var/spack/repos/builtin/packages/axom/package.py b/var/spack/repos/builtin/packages/axom/package.py index 6d1efb4c94240f..9e658373d3ff29 100644 --- a/var/spack/repos/builtin/packages/axom/package.py +++ b/var/spack/repos/builtin/packages/axom/package.py @@ -3,7 +3,9 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import glob import os +import shutil import socket from os.path import join as pjoin @@ -43,6 +45,7 @@ class Axom(CachedCMakePackage, CudaPackage, ROCmPackage): version("main", branch="main") version("develop", branch="develop") + version("0.9.0", tag="v0.9.0", commit="5f531595d941d16fa3b8583bfc347a845d9feb6d") version("0.8.1", tag="v0.8.1", commit="0da8a5b1be596887158ac2fcd321524ba5259e15") version("0.8.0", tag="v0.8.0", commit="71fab3262eb7e1aa44a04c21d072b77f06362f7b") version("0.7.0", tag="v0.7.0", commit="ea5158191181c137117ae37959879bdc8b107f35") @@ -56,6 +59,10 @@ class Axom(CachedCMakePackage, CudaPackage, ROCmPackage): version("0.3.0", tag="v0.3.0", commit="20068ccab4b4f70055918b4f17960ec3ed6dbce8") version("0.2.9", tag="v0.2.9", commit="9e9a54ede3326817c05f35922738516e43b5ec3d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # https://github.com/spack/spack/issues/31829 patch("examples-oneapi.patch", when="@0.6.1 +examples %oneapi") @@ -82,6 +89,13 @@ class Axom(CachedCMakePackage, CudaPackage, ROCmPackage): variant("mpi", default=True, description="Build MPI support") variant("openmp", default=True, description="Turn on OpenMP support.") + variant( + "profiling", + default=False, + when="@develop", + description="Build with hooks for Adiak/Caliper performance analysis", + ) + variant("mfem", default=False, description="Build with mfem") variant("hdf5", default=True, description="Build with hdf5") variant("lua", default=True, description="Build with Lua") @@ -102,7 +116,8 @@ class Axom(CachedCMakePackage, CudaPackage, ROCmPackage): depends_on("cmake@3.21:", type="build", when="+rocm") depends_on("blt", type="build") - depends_on("blt@0.5.1:", type="build", when="@0.6.1:") + depends_on("blt@0.5.1:0.5.3", type="build", when="@0.6.1:0.8") + depends_on("blt@0.6.2:", type="build", when="@0.9:") depends_on("mpi", when="+mpi") @@ -120,29 +135,49 @@ class Axom(CachedCMakePackage, CudaPackage, ROCmPackage): depends_on("scr~fortran", when="+scr~fortran") with when("+umpire"): - depends_on("umpire@2022.03.0:", when="@0.7.0:") + depends_on("umpire") + depends_on("umpire@2024.02.0:", when="@0.9:") + depends_on("umpire@2022.03.0:2023.06", when="@0.7.0:0.8") depends_on("umpire@6.0.0", when="@0.6.0") depends_on("umpire@5:5.0.1", when="@:0.5.0") - depends_on("umpire +openmp", when="+openmp") + depends_on("umpire+openmp", when="+openmp") with when("+raja"): - depends_on("raja@2022.03.0:", when="@0.7.0:") + depends_on("raja") + depends_on("raja@2024.02.0:", when="@0.9:") + depends_on("raja@2022.03.0:2023.06", when="@0.7.0:0.8") depends_on("raja@0.14.0", when="@0.6.0") depends_on("raja@:0.13.0", when="@:0.5.0") depends_on("raja~openmp", when="~openmp") depends_on("raja+openmp", when="+openmp") + with when("+profiling"): + depends_on("adiak") + depends_on("caliper+adiak~papi") + + depends_on("caliper+cuda", when="+cuda") + depends_on("caliper~cuda", when="~cuda") + + depends_on("caliper+rocm", when="+rocm") + depends_on("caliper~rocm", when="~rocm") + + for dep in ["adiak", "caliper"]: + depends_on(f"{dep}+mpi", when="+mpi") + depends_on(f"{dep}~mpi", when="~mpi") + depends_on(f"{dep}+shared", when="+shared") + depends_on(f"{dep}~shared", when="~shared") + for val in CudaPackage.cuda_arch_values: - raja_cuda = "raja +cuda cuda_arch={0}".format(val) - umpire_cuda = "umpire +cuda cuda_arch={0}".format(val) - depends_on(raja_cuda, when="+{0}".format(raja_cuda)) - depends_on(umpire_cuda, when="+{0}".format(umpire_cuda)) + ext_cuda_dep = f"+cuda cuda_arch={val}" + depends_on(f"raja {ext_cuda_dep}", when=f"+raja {ext_cuda_dep}") + depends_on(f"umpire {ext_cuda_dep}", when=f"+umpire {ext_cuda_dep}") + depends_on(f"caliper {ext_cuda_dep}", when=f"+profiling {ext_cuda_dep}") for val in ROCmPackage.amdgpu_targets: - raja_rocm = "raja +rocm amdgpu_target={0}".format(val) - umpire_rocm = "umpire +rocm amdgpu_target={0}".format(val) - depends_on(raja_rocm, when="+{0}".format(raja_rocm)) - depends_on(umpire_rocm, when="+{0}".format(umpire_rocm)) + ext_rocm_dep = f"+rocm amdgpu_target={val}" + depends_on(f"raja {ext_rocm_dep}", when=f"+raja {ext_rocm_dep}") + depends_on(f"umpire {ext_rocm_dep}", when=f"+umpire {ext_rocm_dep}") + depends_on(f"caliper {ext_rocm_dep}", when=f"+profiling {ext_rocm_dep}") depends_on("rocprim", when="+rocm") @@ -154,15 +189,19 @@ class Axom(CachedCMakePackage, CudaPackage, ROCmPackage): depends_on("python", when="+python") # Devtools - depends_on("cppcheck", when="+devtools") - depends_on("doxygen", when="+devtools") - depends_on("graphviz", when="+devtools") - depends_on("python", when="+devtools") - depends_on("py-sphinx", when="+devtools") - depends_on("py-shroud", when="+devtools") - depends_on("py-jsonschema", when="+devtools") - depends_on("llvm+clang@10.0.0", when="+devtools", type="build") + with when("+devtools"): + depends_on("cppcheck") + depends_on("doxygen") + depends_on("graphviz") + depends_on("python") + depends_on("py-sphinx") + depends_on("py-shroud") + depends_on("py-jsonschema") + depends_on("llvm+clang@10.0.0", type="build") + # ----------------------------------------------------------------------- + # Conflicts + # ----------------------------------------------------------------------- # Hard requirement after Axom 0.6.1 conflicts("~cpp14", when="@0.6.2:") @@ -242,11 +281,9 @@ def initconfig_compiler_entries(self): if "+cpp14" in spec and spec.satisfies("@:0.6.1"): entries.append(cmake_cache_string("BLT_CXX_STD", "c++14", "")) - # Add optimization flag workaround for Debug builds with - # cray compiler or newer HIP + # Add optimization flag workaround for Debug builds with cray compiler or newer HIP if "+rocm" in spec: - if spec.satisfies("%cce") or spec.satisfies("%clang@16"): - entries.append(cmake_cache_string("CMAKE_CXX_FLAGS_DEBUG", "-O1 -g -DNDEBUG")) + entries.append(cmake_cache_string("CMAKE_CXX_FLAGS_DEBUG", "-O1 -g -DNDEBUG")) return entries @@ -258,28 +295,20 @@ def initconfig_hardware_entries(self): entries.append(cmake_cache_option("ENABLE_CUDA", True)) entries.append(cmake_cache_option("CMAKE_CUDA_SEPARABLE_COMPILATION", True)) - entries.append(cmake_cache_option("AXOM_ENABLE_ANNOTATIONS", True)) - # CUDA_FLAGS - cudaflags = "-restrict --expt-extended-lambda " + cudaflags = "${CMAKE_CUDA_FLAGS} -restrict --expt-extended-lambda " # Pass through any cxxflags to the host compiler via nvcc's Xcompiler flag host_cxx_flags = spec.compiler_flags["cxxflags"] cudaflags += " ".join(["-Xcompiler=%s " % flag for flag in host_cxx_flags]) - if not spec.satisfies("cuda_arch=none"): - cuda_arch = spec.variants["cuda_arch"].value[0] - entries.append(cmake_cache_string("CMAKE_CUDA_ARCHITECTURES", cuda_arch)) - else: - entries.append("# cuda_arch could not be determined\n\n") - if spec.satisfies("^blt@:0.5.1"): # This is handled internally by BLT now if "+cpp14" in spec: cudaflags += " -std=c++14" else: cudaflags += " -std=c++11" - entries.append(cmake_cache_string("CMAKE_CUDA_FLAGS", cudaflags)) + entries.append(cmake_cache_string("CMAKE_CUDA_FLAGS", cudaflags, force=True)) entries.append("# nvcc does not like gtest's 'pthreads' flag\n") entries.append(cmake_cache_option("gtest_disable_pthreads", True)) @@ -467,6 +496,13 @@ def initconfig_package_entries(self): else: entries.append("# %s not built\n" % dep.upper()) + if "+profiling" in spec: + dep_dir = get_spec_path(spec, "adiak", path_replacements) + entries.append(cmake_cache_path("ADIAK_DIR", dep_dir)) + + dep_dir = get_spec_path(spec, "caliper", path_replacements) + entries.append(cmake_cache_path("CALIPER_DIR", dep_dir)) + if "+umpire" in spec and spec.satisfies("^camp"): dep_dir = get_spec_path(spec, "camp", path_replacements) entries.append(cmake_cache_path("CAMP_DIR", dep_dir)) @@ -574,3 +610,44 @@ def patch(self): 'PROPERTIES LINKER_LANGUAGE CXX \n LINK_FLAGS "-fopenmp"', "src/axom/quest/examples/CMakeLists.txt", ) + + @run_after("build") + @on_package_attributes(run_tests=True) + def build_test(self): + with working_dir(self.build_directory): + print("Running Axom Unit Tests...") + make("test") + + @run_after("install") + @on_package_attributes(run_tests=True) + def check_install(self): + """ + Checks the spack install of axom using axom's + using-with-cmake example + """ + + print("Checking Axom installation...") + spec = self.spec + install_prefix = spec.prefix + example_src_dir = join_path(install_prefix, "examples", "axom", "using-with-cmake") + example_build_dir = join_path(example_src_dir, "build") + print("Checking using-with-cmake example...") + with working_dir(example_build_dir, create=True): + cmake_args = ["-C ../host-config.cmake", example_src_dir] + cmake(*cmake_args) + make() + example = Executable("./example") + example() + print("Checking using-with-make example...") + example_src_dir = join_path(install_prefix, "examples", "axom", "using-with-make") + example_build_dir = join_path(example_src_dir, "build") + example_files = glob.glob(join_path(example_src_dir, "*")) + with working_dir(example_build_dir, create=True): + for example_file in example_files: + shutil.copy(example_file, ".") + make("AXOM_DIR={0}".format(install_prefix)) + example = Executable("./example") + example() + + def test_install(self): + self.check_install() diff --git a/var/spack/repos/builtin/packages/babelflow/package.py b/var/spack/repos/builtin/packages/babelflow/package.py index 7be4ce4d726c22..ccaacb0421024e 100644 --- a/var/spack/repos/builtin/packages/babelflow/package.py +++ b/var/spack/repos/builtin/packages/babelflow/package.py @@ -23,6 +23,8 @@ class Babelflow(CMakePackage): version("1.0.1", sha256="b7817870b7a1d7ae7ae2eff1a1acec2824675fb856f666d5dc95c41ce453ae91") version("1.0.0", sha256="4c4d7ddf60e25e8d3550c07875dba3e46e7c9e61b309cc47a409461b7ffa405e") + depends_on("cxx", type="build") # generated + depends_on("mpi") variant("shared", default=True, description="Build Babelflow as shared libs") diff --git a/var/spack/repos/builtin/packages/babelstream/package.py b/var/spack/repos/builtin/packages/babelstream/package.py index 4b2a1c58571eb0..f7e6d6fbd5db4c 100644 --- a/var/spack/repos/builtin/packages/babelstream/package.py +++ b/var/spack/repos/builtin/packages/babelstream/package.py @@ -26,6 +26,8 @@ class Babelstream(CMakePackage, CudaPackage, ROCmPackage): version("main", branch="main") version("develop", branch="develop") + depends_on("cxx", type="build") # generated + maintainers("tomdeakin", "kaanolgu", "tom91136", "robj0nes") # Languages diff --git a/var/spack/repos/builtin/packages/babeltrace/package.py b/var/spack/repos/builtin/packages/babeltrace/package.py index af0552d6a01f90..3677c2b4292b77 100644 --- a/var/spack/repos/builtin/packages/babeltrace/package.py +++ b/var/spack/repos/builtin/packages/babeltrace/package.py @@ -18,6 +18,8 @@ class Babeltrace(AutotoolsPackage): version("1.2.4", sha256="666e3a1ad2dc7d5703059963056e7800f0eab59c8eeb6be2efe4f3acc5209eb1") + depends_on("c", type="build") # generated + depends_on("glib@2.22:", type=("build", "link")) depends_on("uuid") depends_on("popt") diff --git a/var/spack/repos/builtin/packages/babl/package.py b/var/spack/repos/builtin/packages/babl/package.py index dc9b480eaed07a..d100f204d4a385 100644 --- a/var/spack/repos/builtin/packages/babl/package.py +++ b/var/spack/repos/builtin/packages/babl/package.py @@ -29,6 +29,8 @@ class Babl(MesonPackage): version("0.1.92", sha256="f667735028944b6375ad18f160a64ceb93f5c7dccaa9d8751de359777488a2c1") version("0.1.90", sha256="6e2ebb636f37581588e3d02499b3d2f69f9ac73e34a262f42911d7f5906a9243") + depends_on("c", type="build") # generated + depends_on("cmake@3.4:", type="build") depends_on("lcms") depends_on("gobject-introspection") diff --git a/var/spack/repos/builtin/packages/bacio/package.py b/var/spack/repos/builtin/packages/bacio/package.py index fba81bb1189dc4..1bf0e9f842e030 100644 --- a/var/spack/repos/builtin/packages/bacio/package.py +++ b/var/spack/repos/builtin/packages/bacio/package.py @@ -20,16 +20,10 @@ class Bacio(CMakePackage): version("develop", branch="develop") version("2.6.0", sha256="03fef581e1bd3710fb8d2f2659a6c3e01a0437c1350ba53958d2ff1ffef47bcb") version("2.5.0", sha256="540a0ed73941d70dbf5d7b21d5d0a441e76fad2bfe37dfdfea0db3e98fc0fbfb") + version("2.4.1", sha256="7b9b6ba0a288f438bfba6a08b6e47f8133f7dba472a74ac56a5454e2260a7200") - # Prefer version 2.4.1 because the library and include directory - # names changed in verion 2.5.0 (dropping the "_4" they used to - # contain.) We need some time to let all the using packages adjust - # to the new names. - version( - "2.4.1", - sha256="7b9b6ba0a288f438bfba6a08b6e47f8133f7dba472a74ac56a5454e2260a7200", - preferred=True, - ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated variant("pic", default=True, description="Build with position-independent-code") variant("shared", default=False, description="Build shared library", when="@2.6.0:") @@ -43,3 +37,7 @@ def cmake_args(self): def patch(self): if self.spec.satisfies("@2.4.1"): filter_file(".+", "2.4.1", "VERSION") + + def check(self): + with working_dir(self.builder.build_directory): + make("test") diff --git a/var/spack/repos/builtin/packages/backward-cpp/package.py b/var/spack/repos/builtin/packages/backward-cpp/package.py index 05e7a5ae32324c..7905f6682a618d 100644 --- a/var/spack/repos/builtin/packages/backward-cpp/package.py +++ b/var/spack/repos/builtin/packages/backward-cpp/package.py @@ -24,6 +24,8 @@ class BackwardCpp(CMakePackage): version("1.2", sha256="0a44fdad126cf2c53f93c33fd6418abaf99672048c98a5a57e2a2e43a38d5f84") version("1.1", sha256="36139e98b8b6a8ff84b28c50fd6443054ccee93cf63231fdd1db0036093553c4") + depends_on("cxx", type="build") # generated + variant("dwarf", default=False, description="Use libdwarf/libelf to read debug info") depends_on("libdwarf", when="+dwarf") diff --git a/var/spack/repos/builtin/packages/bam-readcount/package.py b/var/spack/repos/builtin/packages/bam-readcount/package.py index 3a5bb85905da8d..e7373d4cdcd2bb 100644 --- a/var/spack/repos/builtin/packages/bam-readcount/package.py +++ b/var/spack/repos/builtin/packages/bam-readcount/package.py @@ -17,5 +17,7 @@ class BamReadcount(CMakePackage): version("1.0.1", sha256="8ebf84d9efee0f2d3b43f0452dbf16b27337c960e25128f6a7173119e62588b8") version("0.8.0", sha256="4f4dd558e3c6bfb24d6a57ec441568f7524be6639b24f13ea6f2bb350c7ea65f") + depends_on("cxx", type="build") # generated + def setup_build_environment(self, env): env.append_flags("CFLAGS", self.compiler.cc_pic_flag) diff --git a/var/spack/repos/builtin/packages/bamaddrg/package.py b/var/spack/repos/builtin/packages/bamaddrg/package.py index ae30012e3ab737..fe0f4c518491c7 100644 --- a/var/spack/repos/builtin/packages/bamaddrg/package.py +++ b/var/spack/repos/builtin/packages/bamaddrg/package.py @@ -16,6 +16,8 @@ class Bamaddrg(MakefilePackage): version("0.1", sha256="725a689d8326d72f865837b231005a9211d6c70a25b7a3a754df4f90d2996355") + depends_on("cxx", type="build") # generated + depends_on("bamtools", type="build") def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/bamdst/package.py b/var/spack/repos/builtin/packages/bamdst/package.py index 9080d471e20c98..e89438222ac32a 100644 --- a/var/spack/repos/builtin/packages/bamdst/package.py +++ b/var/spack/repos/builtin/packages/bamdst/package.py @@ -14,6 +14,8 @@ class Bamdst(MakefilePackage): version("master", git="https://github.com/shiquan/bamdst.git") + depends_on("c", type="build") # generated + depends_on("zlib-api") parallel = False diff --git a/var/spack/repos/builtin/packages/bamtools/package.py b/var/spack/repos/builtin/packages/bamtools/package.py index f6007ae761f816..cb26f3b6867c69 100644 --- a/var/spack/repos/builtin/packages/bamtools/package.py +++ b/var/spack/repos/builtin/packages/bamtools/package.py @@ -24,6 +24,8 @@ class Bamtools(CMakePackage): version("2.3.0", sha256="288046e6d5d41afdc5fce8608c5641cf2b8e670644587c1315b90bbe92f039af") version("2.2.3", sha256="92ddef44801a1f8f01ce1a397f83e0f8b5e1ae8ad92c620f2dafaaf8d54cf178") + depends_on("cxx", type="build") # generated + depends_on("zlib-api", type="link") depends_on("jsoncpp") diff --git a/var/spack/repos/builtin/packages/bamutil/package.py b/var/spack/repos/builtin/packages/bamutil/package.py index b568cb8385d554..975bf3252911a8 100644 --- a/var/spack/repos/builtin/packages/bamutil/package.py +++ b/var/spack/repos/builtin/packages/bamutil/package.py @@ -24,6 +24,8 @@ class Bamutil(MakefilePackage): url="https://genome.sph.umich.edu/w/images/7/70/BamUtilLibStatGen.1.0.13.tgz", ) + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("git", type="build", when="@1.0.15:") diff --git a/var/spack/repos/builtin/packages/banner/package.py b/var/spack/repos/builtin/packages/banner/package.py index c997b5a18c7ff6..fa230b1e355fe4 100644 --- a/var/spack/repos/builtin/packages/banner/package.py +++ b/var/spack/repos/builtin/packages/banner/package.py @@ -21,6 +21,8 @@ class Banner(AutotoolsPackage): version("1.3.5", sha256="fb21c42620a0a668334b5732a6216b23b3990ca5d87cf3b15f0689dc617e7fdc") + depends_on("c", type="build") # generated + def url_for_version(self, version): return "https://github.com/pronovic/banner/archive/refs/tags/BANNER_V{0}.tar.gz".format( version diff --git a/var/spack/repos/builtin/packages/bannergrab/package.py b/var/spack/repos/builtin/packages/bannergrab/package.py index 7bd7abbb4d12b3..7a60ff04e6ec48 100644 --- a/var/spack/repos/builtin/packages/bannergrab/package.py +++ b/var/spack/repos/builtin/packages/bannergrab/package.py @@ -19,6 +19,8 @@ class Bannergrab(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) mkdirp(prefix.man1) diff --git a/var/spack/repos/builtin/packages/bart/package.py b/var/spack/repos/builtin/packages/bart/package.py index d3920734349605..5bb8a2c6d240f6 100644 --- a/var/spack/repos/builtin/packages/bart/package.py +++ b/var/spack/repos/builtin/packages/bart/package.py @@ -18,6 +18,9 @@ class Bart(MakefilePackage, CudaPackage): version("0.6.00", sha256="dbbd33d1e3ed3324fe21f90a3b62cb51765fe369f21df100b46a32004928f18d") version("0.5.00", sha256="30eedcda0f0ef3808157542e0d67df5be49ee41e4f41487af5c850632788f643") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # patch to fix build with MKL patch( "https://github.com/mrirecon/bart/commit/b62ca4972d5ac41a44217a5c27123c15daae74db.patch?full_index=1", diff --git a/var/spack/repos/builtin/packages/bash-completion/package.py b/var/spack/repos/builtin/packages/bash-completion/package.py index 245be3d518be33..5d835d2aa44bf0 100644 --- a/var/spack/repos/builtin/packages/bash-completion/package.py +++ b/var/spack/repos/builtin/packages/bash-completion/package.py @@ -20,6 +20,8 @@ class BashCompletion(AutotoolsPackage): version("2.7", sha256="dba2b88c363178622b61258f35d82df64dc8d279359f599e3b93eac0375a416c") version("2.3", sha256="d92fcef5f6e3bbc68a84f0a7b063a1cd07b4000cc6e275cd1ff83863ab3b322a") + depends_on("c", type="build") # generated + # Build dependencies depends_on("automake", type="build") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/bash/package.py b/var/spack/repos/builtin/packages/bash/package.py index 52a55e26bf70dc..3e520521062ef6 100644 --- a/var/spack/repos/builtin/packages/bash/package.py +++ b/var/spack/repos/builtin/packages/bash/package.py @@ -6,7 +6,6 @@ import re from spack.package import * -from spack.util.environment import is_system_path class Bash(AutotoolsPackage, GNUMirrorPackage): @@ -23,6 +22,8 @@ class Bash(AutotoolsPackage, GNUMirrorPackage): version("4.4", sha256="d86b3392c1202e8ff5a423b302e6284db7f8f435ea9f39b5b1b20fd3ac36dfcb") version("4.3", sha256="afc687a28e0e24dc21b988fa159ff9dbcf6b7caa92ade8645cc6d5605cd024d4") + depends_on("c", type="build") # generated + depends_on("ncurses") depends_on("readline@8.2:", when="@5.2:") depends_on("readline@5.0:") @@ -45,6 +46,17 @@ class Bash(AutotoolsPackage, GNUMirrorPackage): ("5.2", "013", "094b4fd81bc488a26febba5d799689b64d52a5505b63e8ee854f48d356bc7ce6"), ("5.2", "014", "3ef9246f2906ef1e487a0a3f4c647ae1c289cbd8459caa7db5ce118ef136e624"), ("5.2", "015", "ef73905169db67399a728e238a9413e0d689462cb9b72ab17a05dba51221358a"), + ("5.2", "016", "155853bc5bd10e40a9bea369fb6f50a203a7d0358e9e32321be0d9fa21585915"), + ("5.2", "017", "1c48cecbc9b7b4217990580203b7e1de19c4979d0bd2c0e310167df748df2c89"), + ("5.2", "018", "4641dd49dd923b454dd0a346277907090410f5d60a29a2de3b82c98e49aaaa80"), + ("5.2", "019", "325c26860ad4bba8558356c4ab914ac57e7b415dac6f5aae86b9b05ccb7ed282"), + ("5.2", "020", "b6fc252aeb95ce67c9b017d29d81e8a5e285db4bf20d4ec8cdca35892be5c01d"), + ("5.2", "021", "8334b88117ad047598f23581aeb0c66c0248cdd77abc3b4e259133aa307650cd"), + ("5.2", "022", "78b5230a49594ec30811e72dcd0f56d1089710ec7828621022d08507aa57e470"), + ("5.2", "023", "af905502e2106c8510ba2085aa2b56e64830fc0fdf6ee67ebb459ac11696dcd3"), + ("5.2", "024", "971534490117eb05d97d7fd81f5f9d8daf927b4d581231844ffae485651b02c3"), + ("5.2", "025", "5138f487e7cf71a6323dc81d22419906f1535b89835cc2ff68847e1a35613075"), + ("5.2", "026", "96ee1f549aa0b530521e36bdc0ba7661602cfaee409f7023cac744dd42852eac"), ("5.1", "001", "ebb07b3dbadd98598f078125d0ae0d699295978a5cdaef6282fe19adef45b5fa"), ("5.1", "002", "15ea6121a801e48e658ceee712ea9b88d4ded022046a6147550790caf04f5dbe"), ("5.1", "003", "22f2cc262f056b22966281babf4b0a2f84cb7dd2223422e5dcd013c3dcbab6b1"), @@ -187,10 +199,10 @@ def configure_args(self): "--enable-readline", "--with-installed-readline", ] - if spec["iconv"].name == "libc": + if spec["iconv"].name == "libiconv": + args.append(f"--with-libiconv-prefix={spec['iconv'].prefix}") + else: args.append("--without-libiconv-prefix") - elif not is_system_path(spec["iconv"].prefix): - args.append("--with-libiconv-prefix={0}".format(spec["iconv"].prefix)) return args def check(self): diff --git a/var/spack/repos/builtin/packages/bat/package.py b/var/spack/repos/builtin/packages/bat/package.py index 1718b778c6d2a2..2af4dd2eee8a96 100644 --- a/var/spack/repos/builtin/packages/bat/package.py +++ b/var/spack/repos/builtin/packages/bat/package.py @@ -19,3 +19,7 @@ class Bat(CargoPackage): version("0.21.0", sha256="3dff1e52d577d0a105f4afe3fe7722a4a2b8bb2eb3e7a6a5284ac7add586a3ee") version("0.13.0", sha256="f4aee370013e2a3bc84c405738ed0ab6e334d3a9f22c18031a7ea008cd5abd2a") version("0.12.1", sha256="1dd184ddc9e5228ba94d19afc0b8b440bfc1819fef8133fe331e2c0ec9e3f8e2") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/batchedblas/package.py b/var/spack/repos/builtin/packages/batchedblas/package.py index 283e7e23a37857..fa3e79a2a98c6b 100644 --- a/var/spack/repos/builtin/packages/batchedblas/package.py +++ b/var/spack/repos/builtin/packages/batchedblas/package.py @@ -18,6 +18,8 @@ class Batchedblas(MakefilePackage): version("1.0", sha256="798ae4e7cc4ad5c3d5f3479f3d001da566d7d5205779103aaf10cd5b956ba433") + depends_on("c", type="build") # generated + depends_on("blas") patch("AVX2.patch") diff --git a/var/spack/repos/builtin/packages/batctl/package.py b/var/spack/repos/builtin/packages/batctl/package.py index 84a5cb3aa310e0..5c69f5263b6dd8 100644 --- a/var/spack/repos/builtin/packages/batctl/package.py +++ b/var/spack/repos/builtin/packages/batctl/package.py @@ -19,6 +19,8 @@ class Batctl(MakefilePackage): version("2019.3", sha256="2bd93fa14925a8dc63a67e64266c8ccd2fa3ac44b10253d93e6f8a630350070c") version("2019.2", sha256="fb656208ff7d4cd8b1b422f60c9e6d8747302a347cbf6c199d7afa9b80f80ea3") + depends_on("c", type="build") # generated + depends_on("libnl") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/baurmc/package.py b/var/spack/repos/builtin/packages/baurmc/package.py index 3fff20bcb00d11..a3a711ac0e412a 100644 --- a/var/spack/repos/builtin/packages/baurmc/package.py +++ b/var/spack/repos/builtin/packages/baurmc/package.py @@ -22,6 +22,8 @@ class Baurmc(AutotoolsPackage): version("1.0", sha256="de5027ed2e66028bed890760bee9d869e1e330ac7f7112ee5cb25868cea5c35b") + depends_on("fortran", type="build") # generated + @property def configure_directory(self): return os.path.join(self.stage.source_path, str(self.spec.version)) diff --git a/var/spack/repos/builtin/packages/bazel/package.py b/var/spack/repos/builtin/packages/bazel/package.py index fd8ac98b2a8bf8..52ba8f74bf1ca6 100644 --- a/var/spack/repos/builtin/packages/bazel/package.py +++ b/var/spack/repos/builtin/packages/bazel/package.py @@ -131,6 +131,8 @@ class Bazel(Package): # Bazel-4.0.0 does not compile with gcc-11 # Newer versions of grpc and abseil dependencies are needed but are not in bazel-4.0.0 conflicts("@4.0.0", when="%gcc@11:") + # https://github.com/bazelbuild/bazel/issues/18642 + conflicts("@:6", when="%gcc@13:") executables = ["^bazel$"] diff --git a/var/spack/repos/builtin/packages/bbmap/package.py b/var/spack/repos/builtin/packages/bbmap/package.py index f45c473e023eda..4404eb725666e2 100644 --- a/var/spack/repos/builtin/packages/bbmap/package.py +++ b/var/spack/repos/builtin/packages/bbmap/package.py @@ -19,6 +19,8 @@ class Bbmap(Package, SourceforgePackage): version("37.78", sha256="f2da19f64d2bfb7db4c0392212668b425c96a27c77bd9d88d8f0aea90a193509") version("37.36", sha256="befe76d7d6f3d0f0cd79b8a01004a2283bdc0b5ab21b0743e9dbde7c7d79e8a9") + depends_on("c", type="build") # generated + depends_on("java") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/bc/package.py b/var/spack/repos/builtin/packages/bc/package.py index 7ab944d91ea140..a756baa783580f 100644 --- a/var/spack/repos/builtin/packages/bc/package.py +++ b/var/spack/repos/builtin/packages/bc/package.py @@ -19,6 +19,8 @@ class Bc(AutotoolsPackage, GNUMirrorPackage): version("1.07.1", sha256="62adfca89b0a1c0164c2cdca59ca210c1d44c3ffc46daf9931cf4942664cb02a") version("1.07", sha256="55cf1fc33a728d7c3d386cc7b0cb556eb5bacf8e0cb5a3fcca7f109fc61205ad") + depends_on("c", type="build") # generated + depends_on("ed", type="build") depends_on("texinfo", type="build") diff --git a/var/spack/repos/builtin/packages/bcache/package.py b/var/spack/repos/builtin/packages/bcache/package.py index 598c50f09ef076..21d850f04005d7 100644 --- a/var/spack/repos/builtin/packages/bcache/package.py +++ b/var/spack/repos/builtin/packages/bcache/package.py @@ -21,6 +21,8 @@ class Bcache(MakefilePackage): version("1.0.5", sha256="1449294ef545b3dc6f715f7b063bc2c8656984ad73bcd81a0dc048cbba416ea9") version("1.0.4", sha256="102ffc3a8389180f4b491188c3520f8a4b1a84e5a7ca26d2bd6de1821f4d913d") + depends_on("c", type="build") # generated + depends_on("uuid") depends_on("util-linux") depends_on("gettext") diff --git a/var/spack/repos/builtin/packages/bcftools/package.py b/var/spack/repos/builtin/packages/bcftools/package.py index e1867c3cebaa80..05cf578bf9603b 100644 --- a/var/spack/repos/builtin/packages/bcftools/package.py +++ b/var/spack/repos/builtin/packages/bcftools/package.py @@ -37,6 +37,9 @@ class Bcftools(AutotoolsPackage): version("1.3.1", sha256="12c37a4054cbf1980223e2b3a80a7fdb3fd850324a4ba6832e38fdba91f1b924") version("1.2", sha256="53c628339020dd45334a007c9cefdaf1cba3f1032492ec813b116379fa684fd6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "libgsl", default=False, diff --git a/var/spack/repos/builtin/packages/bdftopcf/package.py b/var/spack/repos/builtin/packages/bdftopcf/package.py index bd190c5e46a644..30ee505a4dfaf2 100644 --- a/var/spack/repos/builtin/packages/bdftopcf/package.py +++ b/var/spack/repos/builtin/packages/bdftopcf/package.py @@ -22,6 +22,8 @@ class Bdftopcf(AutotoolsPackage, XorgPackage): version("1.1", sha256="699d1a62012035b1461c7f8e3f05a51c8bd6f28f348983249fb89bbff7309b47") version("1.0.5", sha256="78a5ec945de1d33e6812167b1383554fda36e38576849e74a9039dc7364ff2c3") + depends_on("c", type="build") # generated + depends_on("libxfont") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/bdsim/package.py b/var/spack/repos/builtin/packages/bdsim/package.py index 656fde32ce026f..cf007073b44698 100644 --- a/var/spack/repos/builtin/packages/bdsim/package.py +++ b/var/spack/repos/builtin/packages/bdsim/package.py @@ -27,6 +27,8 @@ class Bdsim(CMakePackage): version("1.7.0", sha256="713ce3c9d94f340ca774ce1803e0c4f992b904dbc28ce4129713abe883e98683") version("1.6.0", sha256="e3241d2d097cb4e22249e315c1474da9b3657b9c6893232d9f9e543a5323f717") + depends_on("cxx", type="build") # generated + depends_on("cmake") depends_on("geant4") depends_on("geant4@:10.7.3", when="@:1.6.0") diff --git a/var/spack/repos/builtin/packages/bdw-gc/package.py b/var/spack/repos/builtin/packages/bdw-gc/package.py index 5f9943691bac16..25434ffac83c2f 100644 --- a/var/spack/repos/builtin/packages/bdw-gc/package.py +++ b/var/spack/repos/builtin/packages/bdw-gc/package.py @@ -31,6 +31,9 @@ class BdwGc(AutotoolsPackage): url="http://www.hboehm.info/gc/gc_source/gc-7.4.4.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("libatomic-ops", default=True, description="Use external libatomic-ops") variant( "threads", diff --git a/var/spack/repos/builtin/packages/bear/package.py b/var/spack/repos/builtin/packages/bear/package.py index e7389a4f4cc367..b58df4beab0596 100644 --- a/var/spack/repos/builtin/packages/bear/package.py +++ b/var/spack/repos/builtin/packages/bear/package.py @@ -31,6 +31,9 @@ class Bear(CMakePackage): version("2.2.0", sha256="6bd61a6d64a24a61eab17e7f2950e688820c72635e1cf7ea8ea7bf9482f3b612") version("2.0.4", sha256="33ea117b09068aa2cd59c0f0f7535ad82c5ee473133779f1cc20f6f99793a63e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pkgconfig", when="@3:") depends_on("fmt@8", when="@3.0.0:") depends_on("grpc +shared", when="@3.0.0:") diff --git a/var/spack/repos/builtin/packages/beast-tracer/package.py b/var/spack/repos/builtin/packages/beast-tracer/package.py index 1ed549a8a0ff55..bb3c6d0aa6b617 100644 --- a/var/spack/repos/builtin/packages/beast-tracer/package.py +++ b/var/spack/repos/builtin/packages/beast-tracer/package.py @@ -18,6 +18,8 @@ class BeastTracer(Package): version("1.7.2", sha256="fd891e2244445fef71ab8010d8fab924abff2e5436e035bb335834e7c2e6d83b") version("1.7.1", sha256="947d51c5afa52354099b9b182ba6036e352356bd62df94031f33cdcb7e8effd3") + depends_on("c", type="build") # generated + depends_on("ant", type="build") depends_on("java", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/beast1/package.py b/var/spack/repos/builtin/packages/beast1/package.py index 9e557fde3abe9f..ba4c933122d87e 100644 --- a/var/spack/repos/builtin/packages/beast1/package.py +++ b/var/spack/repos/builtin/packages/beast1/package.py @@ -15,6 +15,8 @@ class Beast1(Package): version("1.10.4", sha256="be652c4d55953f7c6c7a9d3eb3de203c77dc380e81ad81cfe0492408990c36a8") version("1.8.4", sha256="c14e93976008463108aefa34ecc23287ab70703caccf4962e36e295207120d78") + depends_on("c", type="build") # generated + variant("beagle", default=True, description="Build with libbeagle support") depends_on("java", type="run") diff --git a/var/spack/repos/builtin/packages/beatnik/package.py b/var/spack/repos/builtin/packages/beatnik/package.py index d16ec01a24af58..2000a7a80a843e 100644 --- a/var/spack/repos/builtin/packages/beatnik/package.py +++ b/var/spack/repos/builtin/packages/beatnik/package.py @@ -20,6 +20,8 @@ class Beatnik(CMakePackage, CudaPackage, ROCmPackage): version("develop", branch="develop") version("main", branch="main") + depends_on("cxx", type="build") # generated + # Variants are primarily backends to build on GPU systems and pass the right # informtion to the packages we depend on variant("cuda", default=False, description="Use CUDA support from subpackages") diff --git a/var/spack/repos/builtin/packages/bedops/package.py b/var/spack/repos/builtin/packages/bedops/package.py index 9d49dfd649b51e..a1e29fa2f4ada3 100644 --- a/var/spack/repos/builtin/packages/bedops/package.py +++ b/var/spack/repos/builtin/packages/bedops/package.py @@ -26,6 +26,9 @@ class Bedops(MakefilePackage): version("2.4.34", sha256="533a62a403130c048d3378e6a975b73ea88d156d4869556a6b6f58d90c52ed95") version("2.4.30", sha256="218e0e367aa79747b2f90341d640776eea17befc0fdc35b0cec3c6184098d462") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + @property def build_targets(self): # avoid static linking with glibc for all invocations diff --git a/var/spack/repos/builtin/packages/bedtools2/package.py b/var/spack/repos/builtin/packages/bedtools2/package.py index 045c6b1dd6a7df..7a13dc7641f445 100644 --- a/var/spack/repos/builtin/packages/bedtools2/package.py +++ b/var/spack/repos/builtin/packages/bedtools2/package.py @@ -27,6 +27,9 @@ class Bedtools2(Package): version("2.25.0", sha256="159122afb9978015f7ec85d7b17739b01415a5738086b20a48147eeefcf08cfb") version("2.23.0", sha256="9dacaa561d11ce9835d1d51e5aeb092bcbe117b7119663ec9a671abac6a36056") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("bzip2", when="@2.29:") depends_on("xz", when="@2.29:") diff --git a/var/spack/repos/builtin/packages/beforelight/package.py b/var/spack/repos/builtin/packages/beforelight/package.py index 321805e4b652d2..ac5e68ea95a9c3 100644 --- a/var/spack/repos/builtin/packages/beforelight/package.py +++ b/var/spack/repos/builtin/packages/beforelight/package.py @@ -20,6 +20,8 @@ class Beforelight(AutotoolsPackage, XorgPackage): version("1.0.6", sha256="735579a7671a9f9de16b7211cf0ba39027183bdc3e82a937fbccfdd893e64a2e") version("1.0.5", sha256="93bb3c457d6d5e8def3180fdee07bc84d1b7f0e5378a95812e2193cd51455cdc") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxscrnsaver") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/benchmark/package.py b/var/spack/repos/builtin/packages/benchmark/package.py index 0e8fe590198ebb..7300c40e8c47d3 100644 --- a/var/spack/repos/builtin/packages/benchmark/package.py +++ b/var/spack/repos/builtin/packages/benchmark/package.py @@ -18,6 +18,7 @@ class Benchmark(CMakePackage): # first properly installed CMake config packages in # 1.2.0 release: https://github.com/google/benchmark/issues/363 version("main", branch="main") + version("1.8.4", sha256="3e7059b6b11fb1bbe28e33e02519398ca94c1818874ebed18e504dc6f709be45") version("1.8.3", sha256="6bc180a57d23d4d9515519f92b0c83d61b05b5bab188961f36ac7b06b0d9e9ce") version("1.8.2", sha256="2aab2980d0376137f969d92848fbb68216abb07633034534fc8c65cc4e7a0e93") version("1.8.1", sha256="e9ff65cecfed4f60c893a1e8a1ba94221fad3b27075f2f80f47eb424b0f8c9bd") @@ -38,6 +39,8 @@ class Benchmark(CMakePackage): version("1.1.0", sha256="e7334dd254434c6668e33a54c8f839194c7c61840d52f4b6258eee28e9f3b20e") version("1.0.0", sha256="d2206c263fc1a7803d4b10e164e0c225f6bcf0d5e5f20b87929f137dee247b54") + depends_on("cxx", type="build") # generated + variant( "build_type", default="RelWithDebInfo", diff --git a/var/spack/repos/builtin/packages/berkeley-db/package.py b/var/spack/repos/builtin/packages/berkeley-db/package.py index c549ed24b99cb7..acce6ce336ec72 100644 --- a/var/spack/repos/builtin/packages/berkeley-db/package.py +++ b/var/spack/repos/builtin/packages/berkeley-db/package.py @@ -34,6 +34,9 @@ class BerkeleyDb(AutotoolsPackage): ) version("5.3.28", sha256="e0a992d740709892e81f9d93f06daf305cf73fb81b545afe72478043172c3628") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("docs", default=False, description="Build documentation") variant("cxx", default=True, description="Build with C++ API") variant("stl", default=True, description="Build with C++ STL API") diff --git a/var/spack/repos/builtin/packages/berkeleygw/package.py b/var/spack/repos/builtin/packages/berkeleygw/package.py index dbd1ea7fc70c5c..a6003995bdc80f 100644 --- a/var/spack/repos/builtin/packages/berkeleygw/package.py +++ b/var/spack/repos/builtin/packages/berkeleygw/package.py @@ -16,6 +16,12 @@ class Berkeleygw(MakefilePackage): maintainers("migueldiascosta") + version( + "4.0", + sha256="1a85b03b83b339056f65124bfa96832ca61152236d9bb1cb372e3040fc686a49", + url="https://app.box.com/shared/static/22edl07muvhfnd900tnctsjjftbtcqc4.gz", + expand=False, + ) version( "3.1.0", sha256="7e890a5faa5a6bb601aa665c73903b3af30df7bdd13ee09362b69793bbefa6d2", @@ -41,6 +47,10 @@ class Berkeleygw(MakefilePackage): expand=False, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # For parallel computing support, enable +mpi. It uses MPI and ScaLAPACK # which are inter-dependent in the berkeleygw code(they need each other): # https://github.com/spack/spack/pull/33948#issuecomment-1323805817 @@ -147,12 +157,21 @@ def edit(self, spec, prefix): if self.version >= Version("3.0"): si_epm_tests.append("Si_hdf5") for test in si_epm_tests: + filter_file( + "Precision : 5e-12", + "Precision : 6e-12", + join_path("testsuite", "Si-EPM", test + ".test"), + ) filter_file( "Precision : 6e-15", "Precision : 7e-15", join_path("testsuite", "Si-EPM", test + ".test"), ) - for test in ["Si_subspace", "Si_subspace_cplx", "Si_subspace_cplx_spin"]: + + si_epm_subspace_tests = ["Si_subspace", "Si_subspace_cplx_spin"] + if self.version < Version("4.0"): + si_epm_subspace_tests.append("Si_subspace_cplx") + for test in si_epm_subspace_tests: filter_file( "Precision : 6e-15", "Precision : 7e-15", @@ -160,6 +179,12 @@ def edit(self, spec, prefix): ) filter_file("Precision : 8e-15", "Precision : 9e-15", "testsuite/GaAs-EPM/GaAs.test") + if self.version < Version("3.1.0"): + # np.int alias was removed from numpy + filter_file( + r"astype\(np.int\)", "astype(int)", "testsuite/Si2-SAPO/analyze_dotproduct.py" + ) + def build(self, spec, prefix): buildopts = [] paraflags = [] diff --git a/var/spack/repos/builtin/packages/bertini/package.py b/var/spack/repos/builtin/packages/bertini/package.py index 68b52246a882d5..d74608455c68d1 100644 --- a/var/spack/repos/builtin/packages/bertini/package.py +++ b/var/spack/repos/builtin/packages/bertini/package.py @@ -18,6 +18,8 @@ class Bertini(AutotoolsPackage): version("1.5", sha256="a9a68a96e180fe6a93ba1bc1d61f522784c9a053b049b2cbd98008b5b6deec3c") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Compile in parallel") depends_on("flex", type="build") diff --git a/var/spack/repos/builtin/packages/bfs/package.py b/var/spack/repos/builtin/packages/bfs/package.py index d517b5ed90bed9..36476092bb144d 100644 --- a/var/spack/repos/builtin/packages/bfs/package.py +++ b/var/spack/repos/builtin/packages/bfs/package.py @@ -22,6 +22,8 @@ class Bfs(MakefilePackage): version("3.0.2", sha256="d3456a9aeecc031064db0dbe012e55a11eb97be88d0ab33a90e570fe66457f92") version("3.0.1", sha256="a38bb704201ed29f4e0b989fb2ab3791ca51c3eff90acfc31fff424579bbf962") + depends_on("c", type="build") # generated + depends_on("acl", when="platform=linux") depends_on("attr", when="platform=linux") depends_on("libcap", when="platform=linux") diff --git a/var/spack/repos/builtin/packages/bgen/package.py b/var/spack/repos/builtin/packages/bgen/package.py new file mode 100644 index 00000000000000..f71d04d47278e9 --- /dev/null +++ b/var/spack/repos/builtin/packages/bgen/package.py @@ -0,0 +1,30 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Bgen(WafPackage): + """This repository contains a reference implementation of the BGEN format, written + in C++. The library can be used as the basis for BGEN support in other software, + or as a reference for developers writing their own implementations of the BGEN format. + + If you make use of the BGEN library, its tools or example programs, please cite: + + Band, G. and Marchini, J., "BGEN: a binary file format for imputed genotype and + haplotype data", bioArxiv 308296; doi: https://doi.org/10.1101/308296.""" + + homepage = "https://enkre.net/cgi-bin/code/bgen" + + license("BSL-1.0") + + version( + "1.1.7", + sha256="121f5956f04ad174bc410fa7deed59e2ebff0ec818a3c66cf5d667357dddfb62", + url="https://enkre.net/cgi-bin/code/bgen/tarball/6ac2d582f9/BGEN-6ac2d582f9.tar.gz", + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/bgpdump/package.py b/var/spack/repos/builtin/packages/bgpdump/package.py index 334769aca16f92..c83bded26376b0 100644 --- a/var/spack/repos/builtin/packages/bgpdump/package.py +++ b/var/spack/repos/builtin/packages/bgpdump/package.py @@ -14,6 +14,8 @@ class Bgpdump(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/bigdft-atlab/package.py b/var/spack/repos/builtin/packages/bigdft-atlab/package.py index fca44cf20f7f13..08792adde4fc09 100644 --- a/var/spack/repos/builtin/packages/bigdft-atlab/package.py +++ b/var/spack/repos/builtin/packages/bigdft-atlab/package.py @@ -20,6 +20,10 @@ class BigdftAtlab(AutotoolsPackage): version("1.9.1", sha256="3c334da26d2a201b572579fc1a7f8caad1cbf971e848a3e10d83bc4dc8c82e41") version("1.9.0", sha256="4500e505f5a29d213f678a91d00a10fef9dc00860ea4b3edf9280f33ed0d1ac8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("openmp", default=True, description="Enable OpenMP support") variant("openbabel", default=False, description="Enable detection of openbabel compilation") diff --git a/var/spack/repos/builtin/packages/bigdft-chess/package.py b/var/spack/repos/builtin/packages/bigdft-chess/package.py index dc5ba9362a37e5..54664c8f73ad19 100644 --- a/var/spack/repos/builtin/packages/bigdft-chess/package.py +++ b/var/spack/repos/builtin/packages/bigdft-chess/package.py @@ -19,6 +19,10 @@ class BigdftChess(AutotoolsPackage, CudaPackage): version("1.9.1", sha256="3c334da26d2a201b572579fc1a7f8caad1cbf971e848a3e10d83bc4dc8c82e41") version("1.9.0", sha256="4500e505f5a29d213f678a91d00a10fef9dc00860ea4b3edf9280f33ed0d1ac8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("openmp", default=True, description="Enable OpenMP support") variant("scalapack", default=True, description="Enable SCALAPACK support") diff --git a/var/spack/repos/builtin/packages/bigdft-core/package.py b/var/spack/repos/builtin/packages/bigdft-core/package.py index 834b65f3777c24..5b9b61aa368eba 100644 --- a/var/spack/repos/builtin/packages/bigdft-core/package.py +++ b/var/spack/repos/builtin/packages/bigdft-core/package.py @@ -19,6 +19,10 @@ class BigdftCore(AutotoolsPackage, CudaPackage): version("1.9.1", sha256="3c334da26d2a201b572579fc1a7f8caad1cbf971e848a3e10d83bc4dc8c82e41") version("1.9.0", sha256="4500e505f5a29d213f678a91d00a10fef9dc00860ea4b3edf9280f33ed0d1ac8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("openmp", default=True, description="Enable OpenMP support") variant("scalapack", default=True, description="Enable SCALAPACK support") diff --git a/var/spack/repos/builtin/packages/bigdft-futile/package.py b/var/spack/repos/builtin/packages/bigdft-futile/package.py index 8f9218d3835a3c..ca65dc29a9cf54 100644 --- a/var/spack/repos/builtin/packages/bigdft-futile/package.py +++ b/var/spack/repos/builtin/packages/bigdft-futile/package.py @@ -24,6 +24,10 @@ class BigdftFutile(AutotoolsPackage, CudaPackage): version("1.9.1", sha256="3c334da26d2a201b572579fc1a7f8caad1cbf971e848a3e10d83bc4dc8c82e41") version("1.9.0", sha256="4500e505f5a29d213f678a91d00a10fef9dc00860ea4b3edf9280f33ed0d1ac8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("openmp", default=True, description="Enable OpenMP support") variant( diff --git a/var/spack/repos/builtin/packages/bigdft-libabinit/package.py b/var/spack/repos/builtin/packages/bigdft-libabinit/package.py index c88763946b2aaa..451e72065655ac 100644 --- a/var/spack/repos/builtin/packages/bigdft-libabinit/package.py +++ b/var/spack/repos/builtin/packages/bigdft-libabinit/package.py @@ -21,6 +21,10 @@ class BigdftLibabinit(AutotoolsPackage): version("1.9.1", sha256="3c334da26d2a201b572579fc1a7f8caad1cbf971e848a3e10d83bc4dc8c82e41") version("1.9.0", sha256="4500e505f5a29d213f678a91d00a10fef9dc00860ea4b3edf9280f33ed0d1ac8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/bigdft-psolver/package.py b/var/spack/repos/builtin/packages/bigdft-psolver/package.py index 95a2ea73ca5a7e..7557b28b45becc 100644 --- a/var/spack/repos/builtin/packages/bigdft-psolver/package.py +++ b/var/spack/repos/builtin/packages/bigdft-psolver/package.py @@ -22,6 +22,10 @@ class BigdftPsolver(AutotoolsPackage, CudaPackage): version("1.9.1", sha256="3c334da26d2a201b572579fc1a7f8caad1cbf971e848a3e10d83bc4dc8c82e41") version("1.9.0", sha256="4500e505f5a29d213f678a91d00a10fef9dc00860ea4b3edf9280f33ed0d1ac8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("openmp", default=True, description="Enable OpenMP support") variant("scalapack", default=True, description="Enable SCALAPACK support") diff --git a/var/spack/repos/builtin/packages/bigdft-spred/package.py b/var/spack/repos/builtin/packages/bigdft-spred/package.py index 14215c3f7fe47a..f468e67a9217ed 100644 --- a/var/spack/repos/builtin/packages/bigdft-spred/package.py +++ b/var/spack/repos/builtin/packages/bigdft-spred/package.py @@ -19,6 +19,10 @@ class BigdftSpred(AutotoolsPackage): version("1.9.1", sha256="3c334da26d2a201b572579fc1a7f8caad1cbf971e848a3e10d83bc4dc8c82e41") version("1.9.0", sha256="4500e505f5a29d213f678a91d00a10fef9dc00860ea4b3edf9280f33ed0d1ac8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/binder/llvm_dir.patch b/var/spack/repos/builtin/packages/binder/llvm_dir.patch new file mode 100644 index 00000000000000..dbd38b2e806b1c --- /dev/null +++ b/var/spack/repos/builtin/packages/binder/llvm_dir.patch @@ -0,0 +1,12 @@ +diff --git a/source/CMakeLists.txt b/source/CMakeLists.txt +index 06a0353..32678eb 100644 +--- a/source/CMakeLists.txt ++++ b/source/CMakeLists.txt +@@ -107,7 +107,6 @@ if(USE_EXTERNAL_LLVM) + else() + target_link_libraries(binder + PRIVATE +- ${lib_llvm_path} + clang + clang-cpp + ) diff --git a/var/spack/repos/builtin/packages/binder/package.py b/var/spack/repos/builtin/packages/binder/package.py index 0b08dd0c290d2e..34bd72518006e5 100644 --- a/var/spack/repos/builtin/packages/binder/package.py +++ b/var/spack/repos/builtin/packages/binder/package.py @@ -24,13 +24,19 @@ class Binder(CMakePackage): license("MIT") version("master", branch="master") + version("1.4.2", tag="v1.4.2", commit="b9f309e0513e745a7465571321e87595fa33d195") version("1.3.0", tag="v1.3.0", commit="e9b55985af297ca161d615058e4a5da07c22bc77") version("1.2.0", tag="v1.2.0", commit="90cf5b31b6f4ecad3fe87518ca2b949dc9e8ed1a") version("1.1.0", tag="v1.0.0", commit="3de7949343197295250f988716d511a264b21324") version("1.0.0", tag="v1.0.0", commit="3de7949343197295250f988716d511a264b21324") + depends_on("cxx", type="build") # generated + # Add dependencies - depends_on("llvm+clang+llvm_dylib@7.0:9") + depends_on("llvm+clang+llvm_dylib@7.0:9", when="@:1.3.0") + depends_on("llvm+clang+llvm_dylib@7.0:", when="@1.4.2:") + + patch("llvm_dir.patch", when="@1.4.2:") def cmake_args(self): spec = self.spec diff --git a/var/spack/repos/builtin/packages/binutils/gold-gcc4.patch b/var/spack/repos/builtin/packages/binutils/gold-gcc4.patch new file mode 100644 index 00000000000000..b11a5fe8c8e493 --- /dev/null +++ b/var/spack/repos/builtin/packages/binutils/gold-gcc4.patch @@ -0,0 +1,12 @@ +diff --git a/gold/merge.cc b/gold/merge.cc +index ca15149..a270bc0 100644 +--- a/gold/merge.cc ++++ b/gold/merge.cc +@@ -24,6 +24,7 @@ + + #include + #include ++#include + + #include "merge.h" + #include "compressed_output.h" diff --git a/var/spack/repos/builtin/packages/binutils/package.py b/var/spack/repos/builtin/packages/binutils/package.py index e396b49e1600f1..637ccca6c2d203 100644 --- a/var/spack/repos/builtin/packages/binutils/package.py +++ b/var/spack/repos/builtin/packages/binutils/package.py @@ -3,6 +3,7 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) import os +import pathlib import re import spack.build_systems.autotools @@ -87,6 +88,9 @@ class Binutils(AutotoolsPackage, GNUMirrorPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("plugins", default=True, description="enable plugins, needed for gold linker") # When you build ld.gold you automatically get ld, even when you add the # --disable-ld flag @@ -126,6 +130,7 @@ class Binutils(AutotoolsPackage, GNUMirrorPackage): # 2.36 is missing some dependencies, this patch allows a parallel build. # https://sourceware.org/bugzilla/show_bug.cgi?id=27482 patch("parallel-build-2.36.patch", when="@2.36") + patch("gold-gcc4.patch", when="@2.42 %gcc@:4.8.5") # compression libs for debug symbols. # pkg-config is used to find zstd in gas/configure @@ -176,6 +181,20 @@ def determine_version(cls, exe): match = re.search(r"GNU (nm|readelf).* (\S+)", output) return Version(match.group(2)).dotted.up_to(3) if match else None + @classmethod + def determine_variants(cls, exes, version_str): + bin_dir = pathlib.Path(exes[0]).parent + include_dir = bin_dir.parent / "include" + plugin_h = include_dir / "plugin-api.h" + + variants = "+gold" if find(str(bin_dir), "gold", recursive=False) else "~gold" + if find(str(include_dir), str(plugin_h), recursive=False): + variants += "+headers" + else: + variants += "~headers" + + return variants + def flag_handler(self, name, flags): spec = self.spec @@ -237,7 +256,7 @@ def test_binaries(self): class AutotoolsBuilder(spack.build_systems.autotools.AutotoolsBuilder): def configure_args(self): known_targets = {"x86_64": "x86_64", "aarch64": "aarch64", "ppc64le": "powerpc"} - known_platforms = {"linux": "linux-gnu", "cray": "linux-gnu", "darwin": "apple-darwin"} + known_platforms = {"linux": "linux-gnu", "darwin": "apple-darwin"} family = str(self.spec.target.family) platform = self.spec.platform diff --git a/var/spack/repos/builtin/packages/biobambam2/package.py b/var/spack/repos/builtin/packages/biobambam2/package.py index 83f0293a2d5c8b..c50f11c47ac435 100644 --- a/var/spack/repos/builtin/packages/biobambam2/package.py +++ b/var/spack/repos/builtin/packages/biobambam2/package.py @@ -18,6 +18,8 @@ class Biobambam2(AutotoolsPackage): url="https://gitlab.com/german.tischler/biobambam2/-/archive/2.0.177-release-20201112105453/biobambam2-2.0.177-release-20201112105453.tar.gz", ) + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") @@ -27,7 +29,7 @@ class Biobambam2(AutotoolsPackage): test_src_dir = "test" def configure_args(self): - args = ["--with-libmaus2={0}".format(self.spec["libmaus2"].prefix)] + args = [f"--with-libmaus2={self.spec['libmaus2'].prefix}"] return args @run_after("install") diff --git a/var/spack/repos/builtin/packages/biobloom/package.py b/var/spack/repos/builtin/packages/biobloom/package.py index e89488f9ef99eb..8559f7504a3e8a 100644 --- a/var/spack/repos/builtin/packages/biobloom/package.py +++ b/var/spack/repos/builtin/packages/biobloom/package.py @@ -16,6 +16,9 @@ class Biobloom(AutotoolsPackage): version("2.3.5", sha256="03fbc0d0fc867f76d64f756d556598e5fe5f015363df8f97fbed4cfd541c6749") version("2.2.0", sha256="5d09f8690f0b6402f967ac09c5b0f769961f3fe3791000f8f73af6af7324f02c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost+exception+math+serialization+container") depends_on("sdsl-lite") depends_on("sparsehash") diff --git a/var/spack/repos/builtin/packages/biopieces/package.py b/var/spack/repos/builtin/packages/biopieces/package.py index 3b36ee0b5862fc..d84bce1f094909 100644 --- a/var/spack/repos/builtin/packages/biopieces/package.py +++ b/var/spack/repos/builtin/packages/biopieces/package.py @@ -18,6 +18,8 @@ class Biopieces(Package): version("2016-04-12", commit="982f80f7c55e2cae67737d80fe35a4e784762856", submodules=True) + depends_on("c", type="build") # generated + depends_on("perl", type=("build", "run")) depends_on("perl-module-build", type=("build", "run")) depends_on("perl-bit-vector", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/bison/package.py b/var/spack/repos/builtin/packages/bison/package.py index 709e8905678511..7226ae8be4d9d7 100644 --- a/var/spack/repos/builtin/packages/bison/package.py +++ b/var/spack/repos/builtin/packages/bison/package.py @@ -50,6 +50,9 @@ class Bison(AutotoolsPackage, GNUMirrorPackage): version("3.0.4", sha256="b67fd2daae7a64b5ba862c66c07c1addb9e6b1b05c5f2049392cfd8a2172952e") version("2.7", sha256="19bbe7374fd602f7a6654c131c21a15aebdc06cc89493e8ff250cb7f9ed0a831") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("color", default=False, description="Enable experimental colored output", when="@3.4:") # https://lists.gnu.org/archive/html/bug-bison/2019-08/msg00008.html @@ -59,6 +62,7 @@ class Bison(AutotoolsPackage, GNUMirrorPackage): depends_on("gettext", when="+color") depends_on("m4@1.4.6:", type=("build", "run")) + depends_on("diffutils", type="build") patch("pgi.patch", when="@3.0.4") # The NVIDIA compilers do not currently support some GNU builtins. diff --git a/var/spack/repos/builtin/packages/bitgroomingz/package.py b/var/spack/repos/builtin/packages/bitgroomingz/package.py index ec6fdfd17f844e..57727803d57e88 100644 --- a/var/spack/repos/builtin/packages/bitgroomingz/package.py +++ b/var/spack/repos/builtin/packages/bitgroomingz/package.py @@ -17,6 +17,8 @@ class Bitgroomingz(CMakePackage): version("master", branch="master") version("2022-10-14", commit="a018b20cca9f7d6a5396ab36230e4be6ae1cb25b") + depends_on("c", type="build") # generated + variant("shared", default=True, description="build shared libs") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/bitlbee/package.py b/var/spack/repos/builtin/packages/bitlbee/package.py index 1ffdd1b9b5babb..56f5e9d5bfcceb 100644 --- a/var/spack/repos/builtin/packages/bitlbee/package.py +++ b/var/spack/repos/builtin/packages/bitlbee/package.py @@ -18,6 +18,8 @@ class Bitlbee(AutotoolsPackage): version("3.6", sha256="6ec3a1054eaa98eaaabe6159cb4912cfd6286f71adcfa970419b273b38fdfe0c") version("3.5-2", sha256="cdcf3ed829d1905b73687b6aa189bbfaf9194f886d9fc7156646827dc0384fdb") + depends_on("c", type="build") # generated + depends_on("glib") depends_on("gnutls") depends_on("libgcrypt") diff --git a/var/spack/repos/builtin/packages/bitmap/package.py b/var/spack/repos/builtin/packages/bitmap/package.py index fc2e3940badd20..c99c8001647c39 100644 --- a/var/spack/repos/builtin/packages/bitmap/package.py +++ b/var/spack/repos/builtin/packages/bitmap/package.py @@ -16,6 +16,8 @@ class Bitmap(AutotoolsPackage, XorgPackage): version("1.1.0", sha256="60ca941e8e38e1f8f9c61d3e86c098878113fd11eac4e07177c111f0bf00779e") version("1.0.8", sha256="1a2fbd10a2ca5cd93f7b77bbb0555b86d8b35e0fc18d036b1607c761755006fc") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxmu") depends_on("libxaw") diff --git a/var/spack/repos/builtin/packages/bitsery/package.py b/var/spack/repos/builtin/packages/bitsery/package.py index f3695651b61d91..078fe1fcb1dabf 100644 --- a/var/spack/repos/builtin/packages/bitsery/package.py +++ b/var/spack/repos/builtin/packages/bitsery/package.py @@ -16,3 +16,5 @@ class Bitsery(CMakePackage): license("MIT") version("5.1.0", sha256="8f46667db5d0b62fdaab33612108498bcbcbe9cfa48d2cd220b2129734440a8d") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/blackhat/package.py b/var/spack/repos/builtin/packages/blackhat/package.py index 6ed4a4a42c84e9..5d6563cf516ec3 100644 --- a/var/spack/repos/builtin/packages/blackhat/package.py +++ b/var/spack/repos/builtin/packages/blackhat/package.py @@ -14,6 +14,9 @@ class Blackhat(AutotoolsPackage): version("0.9.9", branch="cms/v0.9.9") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("qd") depends_on("python") extends("python") diff --git a/var/spack/repos/builtin/packages/blake3/package.py b/var/spack/repos/builtin/packages/blake3/package.py new file mode 100644 index 00000000000000..923d5a0fcd69ee --- /dev/null +++ b/var/spack/repos/builtin/packages/blake3/package.py @@ -0,0 +1,23 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Blake3(CMakePackage): + """BLAKE3 is a cryptographic hash function""" + + homepage = "https://github.com/BLAKE3-team/BLAKE3" + url = "https://github.com/BLAKE3-team/BLAKE3/archive/refs/tags/1.5.1.tar.gz" + + root_cmakelists_dir = "c" + + maintainers("haampie") + + version("1.5.1", sha256="822cd37f70152e5985433d2c50c8f6b2ec83aaf11aa31be9fe71486a91744f37") + + depends_on("c", type="build") # generated + + depends_on("cmake@3.9:", type="build") diff --git a/var/spack/repos/builtin/packages/blaspp/package.py b/var/spack/repos/builtin/packages/blaspp/package.py index 0fda353caae526..b6ba591ed6cf5f 100644 --- a/var/spack/repos/builtin/packages/blaspp/package.py +++ b/var/spack/repos/builtin/packages/blaspp/package.py @@ -21,6 +21,9 @@ class Blaspp(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("master", branch="master") + version( + "2024.05.31", sha256="24f325d2e1c2cc4275324bd88406555688379480877d19553656a0328287927a" + ) version( "2023.11.05", sha256="62dfc03ec07c0826e0466dc2c204b460caa929d53ad4f050cb132d92670be7ce" ) @@ -49,6 +52,8 @@ class Blaspp(CMakePackage, CudaPackage, ROCmPackage): "2020.10.00", sha256="ce148cfe397428d507c72d7d9eba5e9d3f55ad4cd842e6e873c670183dcb7795" ) + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Use OpenMP internally.") variant("shared", default=True, description="Build shared libraries") variant("sycl", default=False, description="Build support for the SYCL backend") diff --git a/var/spack/repos/builtin/packages/blast-legacy/package.py b/var/spack/repos/builtin/packages/blast-legacy/package.py index bad9bdd26995d1..f85bdac5808230 100644 --- a/var/spack/repos/builtin/packages/blast-legacy/package.py +++ b/var/spack/repos/builtin/packages/blast-legacy/package.py @@ -21,6 +21,9 @@ class BlastLegacy(Package): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("tcsh", type="build") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/blast-plus/package.py b/var/spack/repos/builtin/packages/blast-plus/package.py index 0506a4188316e6..2ab6ca28c718f6 100644 --- a/var/spack/repos/builtin/packages/blast-plus/package.py +++ b/var/spack/repos/builtin/packages/blast-plus/package.py @@ -24,6 +24,9 @@ class BlastPlus(AutotoolsPackage): version("2.6.0", sha256="0510e1d607d0fb4389eca50d434d5a0be787423b6850b3a4f315abc2ef19c996") version("2.2.30", sha256="26f72d51c81b9497f33b7274109565c36692572faef4d72377f79b7e59910e40") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # homebrew sez: Fixed upstream in future version > 2.6 # But this bug sez that it will be fixed in 2.6 # https://github.com/Homebrew/homebrew-science/pull/4740 diff --git a/var/spack/repos/builtin/packages/blat/package.py b/var/spack/repos/builtin/packages/blat/package.py index 5246c0eee7c927..4f258d206a83db 100644 --- a/var/spack/repos/builtin/packages/blat/package.py +++ b/var/spack/repos/builtin/packages/blat/package.py @@ -18,7 +18,7 @@ class Blat(Package): version("35", sha256="06d9bcf114ec4a4b21fef0540a0532556b6602322a5a2b33f159dc939ae53620") depends_on("libpng") - depends_on("libuuid", when="@37:") + depends_on("uuid", when="@37:") depends_on("mysql-client", when="@37:") @when("@37") diff --git a/var/spack/repos/builtin/packages/blaze/package.py b/var/spack/repos/builtin/packages/blaze/package.py index e2762147f5c0e4..3826610462afea 100644 --- a/var/spack/repos/builtin/packages/blaze/package.py +++ b/var/spack/repos/builtin/packages/blaze/package.py @@ -22,6 +22,8 @@ class Blaze(CMakePackage): maintainers("nilsvu") version("master", branch="master") + version("3.8.2", sha256="4c4e1915971efbedab95790e4c5cf017d8448057fa8f8c62c46e1643bf72cbb1") + version("3.8.1", sha256="a084c6d1acc75e742a1cdcddf93d0cda0d9e3cc4014c246d997a064fa2196d39") version("3.8", sha256="dfaae1a3a9fea0b3cc92e78c9858dcc6c93301d59f67de5d388a3a41c8a629ae") version("3.7", sha256="ef3cbc5db7d62dcdde0af88d3c951051254afd750d26773406fddb6afc5ad890") version("3.6", sha256="2ebbadacaf3f066e27352c1e413ead127b7ced8a3b202ae45f39c8f5f12324cc") @@ -45,6 +47,8 @@ class Blaze(CMakePackage): version("1.1", sha256="6add20eb9c176ea9f8091c49b101f46d1a1a6bd9c31553a6eff5e53603f0527f") version("1.0", sha256="ee13cfd467c1a4b0fe7cc58b61b846eae862167a90dd2e60559626a30418b5a3") + depends_on("cxx", type="build") # generated + # These configuration options set defaults for dependent packages and # control Blaze dependencies. They can also be enabled or disabled with # compiler flags later by dependent packages, since Blaze is a header-only diff --git a/var/spack/repos/builtin/packages/blis/package.py b/var/spack/repos/builtin/packages/blis/package.py index da25f4e2c33a0a..e298ca6a69c666 100644 --- a/var/spack/repos/builtin/packages/blis/package.py +++ b/var/spack/repos/builtin/packages/blis/package.py @@ -16,6 +16,8 @@ class BlisBase(MakefilePackage): of the library in the 'amdblis' package. """ + maintainers("jeffhammond") + depends_on("python@2.7:2.8,3.4:", type=("build", "run")) variant( @@ -26,6 +28,7 @@ class BlisBase(MakefilePackage): multi=False, ) + variant("ilp64", default=False, description="Force 64-bit Fortran native integers") variant("blas", default=True, description="BLAS compatibility") variant("cblas", default=True, description="CBLAS compatibility") variant( @@ -52,6 +55,11 @@ def configure_args(self): spec = self.spec config_args = ["--enable-threading={0}".format(spec.variants["threads"].value)] + if "+ilp64" in spec: + config_args.append("--blas-int-size=64") + else: + config_args.append("--blas-int-size=32") + if "+cblas" in spec: config_args.append("--enable-cblas") else: @@ -116,6 +124,7 @@ class Blis(BlisBase): license("BSD-3-Clause") version("master", branch="master") + version("1.0", sha256="9c12972aa1e50f64ca61684eba6828f2f3dd509384b1e41a1e8a9aedea4b16a6") version("0.9.0", sha256="1135f664be7355427b91025075562805cdc6cc730d3173f83533b2c5dcc2f308") version("0.8.1", sha256="729694128719801e82fae7b5f2489ab73e4a467f46271beff09588c9265a697b") version("0.8.0", sha256="5e05868c4a6cf5032a7492f8861653e939a8f907a4fa524bbb6e14394e170a3d") @@ -129,6 +138,10 @@ class Blis(BlisBase): version("0.3.0", sha256="d34d17df7bdc2be8771fe0b7f867109fd10437ac91e2a29000a4a23164c7f0da") version("0.2.2", sha256="4a7ecb56034fb20e9d1d8b16e2ef587abbc3d30cb728e70629ca7e795a7998e8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Problems with permissions on installed libraries: # https://github.com/flame/blis/issues/343 patch("Makefile_0.6.0.patch", when="@0.4.0:0.6.0") diff --git a/var/spack/repos/builtin/packages/blitz/package.py b/var/spack/repos/builtin/packages/blitz/package.py index 2ef254bd1c12bc..617af332dbe75f 100644 --- a/var/spack/repos/builtin/packages/blitz/package.py +++ b/var/spack/repos/builtin/packages/blitz/package.py @@ -6,7 +6,7 @@ from spack.package import * -class Blitz(AutotoolsPackage): +class Blitz(CMakePackage): """N-dimensional arrays for C++""" homepage = "https://github.com/blitzpp/blitz" @@ -16,17 +16,10 @@ class Blitz(AutotoolsPackage): version("1.0.2", sha256="500db9c3b2617e1f03d0e548977aec10d36811ba1c43bb5ef250c0e3853ae1c2") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("python@3:", type="build") - depends_on("m4", type="build") - depends_on("autoconf", type="build") - depends_on("automake", type="build") - depends_on("libtool", type="build") # Fix makefile and include to build with Fujitsu compiler patch("fujitsu_compiler_specfic_header.patch", when="%fj") - - build_targets = ["lib"] - - def check(self): - make("check-testsuite") - make("check-examples") diff --git a/var/spack/repos/builtin/packages/blktrace/package.py b/var/spack/repos/builtin/packages/blktrace/package.py index 99cbdd772543a4..f6ef57e5d584f1 100644 --- a/var/spack/repos/builtin/packages/blktrace/package.py +++ b/var/spack/repos/builtin/packages/blktrace/package.py @@ -28,6 +28,8 @@ class Blktrace(MakefilePackage): version("1.0.3", sha256="78c6825212fe6700039fab77d53bc02e6b324e712caea718fff190e4e034cfa8") version("1.0.2", sha256="15f01e2a952919ba3c7b90f8bd891d1a98c454626501094030df632666786343") + depends_on("c", type="build") # generated + depends_on("libaio") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/bloaty/package.py b/var/spack/repos/builtin/packages/bloaty/package.py index ed940950b27b00..0774b107fe8dbb 100644 --- a/var/spack/repos/builtin/packages/bloaty/package.py +++ b/var/spack/repos/builtin/packages/bloaty/package.py @@ -17,3 +17,6 @@ class Bloaty(CMakePackage): license("Apache-2.0") version("1.1", sha256="a308d8369d5812aba45982e55e7c3db2ea4780b7496a5455792fb3dcba9abd6f") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/blogbench/package.py b/var/spack/repos/builtin/packages/blogbench/package.py index 3f03391b157290..e827a2ca7d196c 100644 --- a/var/spack/repos/builtin/packages/blogbench/package.py +++ b/var/spack/repos/builtin/packages/blogbench/package.py @@ -15,3 +15,5 @@ class Blogbench(AutotoolsPackage): version("1.2", sha256="1eabdb1ac0ad8ff6f5b9de36b2ef9b684a35b6e40aea0424e3dd4d6cd923c1af") version("1.1", sha256="8cded059bfdbccb7be35bb6a2272ecfdbe3fbea43d53c92ba5572ac24f26c4df") version("1.0", sha256="dc29261a19064a8fb64d39b27607f19d3b33ce3795908e717404167687ef33be") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/blt/package.py b/var/spack/repos/builtin/packages/blt/package.py index c338e794f96509..4202ca559c9893 100644 --- a/var/spack/repos/builtin/packages/blt/package.py +++ b/var/spack/repos/builtin/packages/blt/package.py @@ -3,9 +3,57 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os +import re + from spack.package import * +def spec_uses_toolchain(spec): + gcc_toolchain_regex = re.compile(".*gcc-toolchain.*") + using_toolchain = list(filter(gcc_toolchain_regex.match, spec.compiler_flags["cxxflags"])) + return using_toolchain + + +def spec_uses_gccname(spec): + gcc_name_regex = re.compile(".*gcc-name.*") + using_gcc_name = list(filter(gcc_name_regex.match, spec.compiler_flags["cxxflags"])) + return using_gcc_name + + +def llnl_link_helpers(options, spec, compiler): + # From local package: + if compiler.fc: + fortran_compilers = ["gfortran", "xlf"] + if any(f_comp in compiler.fc for f_comp in fortran_compilers) and ( + "clang" in compiler.cxx + ): + # Pass fortran compiler lib as rpath to find missing libstdc++ + libdir = os.path.join(os.path.dirname(os.path.dirname(compiler.fc)), "lib") + flags = "" + for _libpath in [libdir, libdir + "64"]: + if os.path.exists(_libpath): + flags += " -Wl,-rpath,{0}".format(_libpath) + description = "Adds a missing libstdc++ rpath" + if flags: + options.append(cmake_cache_string("BLT_EXE_LINKER_FLAGS", flags, description)) + + if "cce" in compiler.cxx: + description = "Adds a missing rpath for libraries " "associated with the fortran compiler" + # Here is where to find libs that work for fortran + libdir = "/opt/cray/pe/cce/{0}/cce-clang/x86_64/lib".format(compiler.version) + linker_flags = "${{BLT_EXE_LINKER_FLAGS}} -Wl,-rpath,{0}".format(libdir) + + version = "{0}".format(compiler.version) + + if version == "16.0.0" or version == "16.0.1": + # Here is another directory added by cce@16.0.0 and cce@16.0.1 + libdir = os.path.join(libdir, "x86_64-unknown-linux-gnu") + linker_flags += " -Wl,-rpath,{0}".format(libdir) + + options.append(cmake_cache_string("BLT_EXE_LINKER_FLAGS", linker_flags, description)) + + class Blt(Package): """BLT is a streamlined CMake-based foundation for Building, Linking and Testing large-scale high performance computing (HPC) applications.""" @@ -25,6 +73,7 @@ class Blt(Package): # if you export targets this could cause problems in downstream # projects if not handled properly. More info here: # https://llnl-blt.readthedocs.io/en/develop/tutorial/exporting_targets.html + version("0.6.2", sha256="84b663162957c1fe0e896ac8e94cbf2b6def4a152ccfa12a293db14fb25191c8") version("0.6.1", sha256="205540b704b8da5a967475be9e8f2d1a5e77009b950e7fbf01c0edabc4315906") version("0.6.0", sha256="ede355e85f7b11d7c8442b51e4f7871c152093818606e00b1e1cf30f67ebdb23") version("0.5.3", sha256="75d17caac98e78432ce25371c50d45ad3e7053820976bc5ed210bbef998f1732") @@ -39,6 +88,10 @@ class Blt(Package): version("0.2.5", sha256="3a000f60194e47b3e5623cc528cbcaf88f7fea4d9620b3c7446ff6658dc582a5") version("0.2.0", sha256="c0cadf1269c2feb189e398a356e3c49170bc832df95e5564e32bdbb1eb0fa1b3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake", type="run") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/bmake/package.py b/var/spack/repos/builtin/packages/bmake/package.py index 95558244604d34..3ae19ae9a72c7c 100644 --- a/var/spack/repos/builtin/packages/bmake/package.py +++ b/var/spack/repos/builtin/packages/bmake/package.py @@ -20,6 +20,8 @@ class Bmake(Package): version("20180512", sha256="ac3cd262065fcc20c1dec7c95f06306c8138b3e17025b949343a06a8980a5508") version("20171207", sha256="1703667e53a0498c0903b20612ebcbb41b886a94b238624cfeadd91a4111d39a") + depends_on("c", type="build") # generated + def patch(self): # Do not pre-roff cat pages filter_file("MANTARGET?", "MANTARGET", "mk/man.mk", string=True) diff --git a/var/spack/repos/builtin/packages/bmi/package.py b/var/spack/repos/builtin/packages/bmi/package.py index 5ae430148c2c09..ff2be55bf51f6e 100644 --- a/var/spack/repos/builtin/packages/bmi/package.py +++ b/var/spack/repos/builtin/packages/bmi/package.py @@ -20,6 +20,8 @@ class Bmi(AutotoolsPackage): version("main", branch="main") version("2.8.1", sha256="28aa4341f0456cf20ee762f712d7c749ab8f864003329f9327c18ea03fc7ffdb") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/bml/package.py b/var/spack/repos/builtin/packages/bml/package.py index 2822968fc63e5d..a2f7eecb0d4e90 100644 --- a/var/spack/repos/builtin/packages/bml/package.py +++ b/var/spack/repos/builtin/packages/bml/package.py @@ -32,6 +32,10 @@ class Bml(CMakePackage): version("1.2.2", sha256="babc2fd0229397e418be00f3691277e86f549b5a23cadbcee66078595e9176a0") version("1.1.0", sha256="a90ede19d80ed870f0bf1588875a9f371484d89006a7296010d8d791da3eac33") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Build shared libs") variant("mpi", default=True, description="Build with MPI Support") diff --git a/var/spack/repos/builtin/packages/bohrium/package.py b/var/spack/repos/builtin/packages/bohrium/package.py index 64ad8c100e0acc..c9f01ae431423d 100644 --- a/var/spack/repos/builtin/packages/bohrium/package.py +++ b/var/spack/repos/builtin/packages/bohrium/package.py @@ -30,6 +30,9 @@ class Bohrium(CMakePackage, CudaPackage): version("0.9.1", sha256="a8675db35ea4587ef12d5885a1aa19b59fd9c3f1366e239059de8b0f3cf51e04") version("0.9.0", sha256="6f6379f1555de5a6a19138beac891a470df7df1fc9594e2b9404cf01b6e17d93") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # # Variants # @@ -256,10 +259,6 @@ def check_install(self): cxx("-o", "test_cxxadd", file_cxxadd, *cxx_flags) test_cxxadd = Executable("./test_cxxadd") - # Build python test commandline - file_pyadd = join_path(os.path.dirname(self.module.__file__), "pyadd.py") - test_pyadd = Executable(spec["python"].command.path + " " + file_pyadd) - # Run tests for each available stack for bh_stack in stacks: tty.info("Testing with bohrium stack '" + bh_stack + "'") @@ -270,5 +269,6 @@ def check_install(self): # Python test (if +python) if "+python" in spec: - py_output = test_pyadd(output=str, env=test_env) + file_pyadd = join_path(os.path.dirname(self.module.__file__), "pyadd.py") + py_output = python(file_pyadd, output=str, env=test_env) compare_output(py_output, "Success!\n") diff --git a/var/spack/repos/builtin/packages/boinc-client/package.py b/var/spack/repos/builtin/packages/boinc-client/package.py index 4b4ec8d7c369d8..5e120eeccf2776 100644 --- a/var/spack/repos/builtin/packages/boinc-client/package.py +++ b/var/spack/repos/builtin/packages/boinc-client/package.py @@ -21,6 +21,9 @@ class BoincClient(AutotoolsPackage): version("7.16.5", sha256="33db60991b253e717c6124cce4750ae7729eaab4e54ec718b9e37f87012d668a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("manager", default=False, description="Builds the client manager") variant("graphics", default=False, description="Graphic apps support") diff --git a/var/spack/repos/builtin/packages/bolt/package.py b/var/spack/repos/builtin/packages/bolt/package.py index 0c37acc5538656..a5486cb1a756a6 100644 --- a/var/spack/repos/builtin/packages/bolt/package.py +++ b/var/spack/repos/builtin/packages/bolt/package.py @@ -35,6 +35,9 @@ class Bolt(CMakePackage): version("1.0.1", sha256="769e30dfc4042cee7ebbdadd23cf08796c03bcd8b335f516dc8cbc3f8adfa597") version("1.0", sha256="1c0d2f75597485ca36335d313a73736594e75c8a36123c5a6f54d01b5ba5c384") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("argobots") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/bonniepp/package.py b/var/spack/repos/builtin/packages/bonniepp/package.py index 55dba48278ae5e..ae4a2817da99c8 100644 --- a/var/spack/repos/builtin/packages/bonniepp/package.py +++ b/var/spack/repos/builtin/packages/bonniepp/package.py @@ -15,6 +15,8 @@ class Bonniepp(AutotoolsPackage): version("1.98", sha256="6e0bcbc08b78856fd998dd7bcb352d4615a99c26c2dc83d5b8345b102bad0b04") + depends_on("cxx", type="build") # generated + def configure_args(self): configure_args = [] configure_args.append("--enable-debug") diff --git a/var/spack/repos/builtin/packages/bookleaf-cpp/package.py b/var/spack/repos/builtin/packages/bookleaf-cpp/package.py index 6a145c30de43bf..b9d9df610c8ebc 100644 --- a/var/spack/repos/builtin/packages/bookleaf-cpp/package.py +++ b/var/spack/repos/builtin/packages/bookleaf-cpp/package.py @@ -21,6 +21,8 @@ class BookleafCpp(CMakePackage): version("2.0.1", sha256="1286f916f59d1f3bf325041854e8c203894e293c5e26d5b19b9362ee02082983") version("2.0", sha256="3c14344c31385bec9e089f9babf815566c4fcf98a47822f663afa2cefb0e90e1") + depends_on("cxx", type="build") # generated + variant("typhon", default=True, description="Use Typhon") variant("parmetis", default=False, description="Use ParMETIS") variant("silo", default=False, description="Use Silo") diff --git a/var/spack/repos/builtin/packages/boost/bootstrap-path.patch b/var/spack/repos/builtin/packages/boost/bootstrap-path.patch deleted file mode 100644 index 06cebe0d1ed3d5..00000000000000 --- a/var/spack/repos/builtin/packages/boost/bootstrap-path.patch +++ /dev/null @@ -1,33 +0,0 @@ -Remove the spack wrapper directories from PATH for the bootstrap step. -This was breaking the build for Cray (and other cross-compile) because -bjam was built for the BE and died on SIGILL on the FE. See issue -#9613. - -This only affects building bjam. The boost libraries are still built -the normal spack way with the spack wrappers. - - -diff -Naurb boost_1_66_0.orig/bootstrap.sh boost_1_66_0/bootstrap.sh ---- boost_1_66_0.orig/bootstrap.sh 2017-12-13 17:56:35.000000000 -0600 -+++ boost_1_66_0/bootstrap.sh 2019-01-09 13:51:56.407553214 -0600 -@@ -7,6 +7,20 @@ - - # boostinspect:notab - Tabs are required for the Makefile. - -+NEWPATH= -+OLDIFS="$IFS" -+IFS=: -+ -+for dir in $PATH ; do -+ case "x$dir" in -+ *lib*spack*env* ) ;; -+ * ) NEWPATH="${NEWPATH}:${dir}" ;; -+ esac -+done -+ -+IFS="$OLDIFS" -+PATH="$NEWPATH" -+ - BJAM="" - TOOLSET="" - BJAM_CONFIG="" diff --git a/var/spack/repos/builtin/packages/boost/package.py b/var/spack/repos/builtin/packages/boost/package.py index 55b9934b3f650f..0447cee7bd413c 100644 --- a/var/spack/repos/builtin/packages/boost/package.py +++ b/var/spack/repos/builtin/packages/boost/package.py @@ -29,8 +29,9 @@ class Boost(Package): license("BSL-1.0") version("develop", branch="develop", submodules=True) - version("1.83.0", sha256="6478edfe2f3305127cffe8caf73ea0176c53769f4bf1585be237eb30798c3b8e") + version("1.85.0", sha256="7009fe1faa1697476bdc7027703a2badb84e849b7b0baad5086b087b971f8617") version("1.84.0", sha256="cc4b893acf645c9d4b698e9a0f08ca8846aa5d6c68275c14c3e7949c24109454") + version("1.83.0", sha256="6478edfe2f3305127cffe8caf73ea0176c53769f4bf1585be237eb30798c3b8e") version("1.82.0", sha256="a6e1ab9b0860e6a2881dd7b21fe9f737a095e5f33a3a874afc6a345228597ee6") version("1.81.0", sha256="71feeed900fbccca04a3b4f2f84a7c217186f28a940ed8b7ed4725986baf99fa") version("1.80.0", sha256="1e19565d82e43bc59209a168f5ac899d3ba471d55c7610c677d4ccf2c9c500c0") @@ -78,6 +79,9 @@ class Boost(Package): version("1.40.0", sha256="36cf4a239b587067a4923fdf6e290525a14c3af29829524fa73f3dec6841530c") version("1.39.0", sha256="44785eae8c6cce61a29a8a51f9b737e57b34d66baa7c0bcd4af188832b8018fd") + depends_on("c", type="build") + depends_on("cxx", type="build") + with_default_variants = "boost" + "".join( [ "+atomic", @@ -244,6 +248,8 @@ def libs(self): depends_on("zstd", when="+iostreams") depends_on("xz", when="+iostreams") depends_on("py-numpy", when="+numpy", type=("build", "run")) + # https://github.com/boostorg/python/issues/431 + depends_on("py-numpy@:1", when="@:1.85+numpy", type=("build", "run")) # Improve the error message when the context-impl variant is conflicting conflicts("context-impl=fcontext", when="@:1.65.0") @@ -287,6 +293,13 @@ def libs(self): # (https://github.com/spack/spack/pull/32879#issuecomment-1265933265) conflicts("%oneapi", when="@1.80") + # Boost 1.85.0 stacktrace added a hard compilation error that has to + # explicitly be suppressed on some platforms: + # https://github.com/boostorg/stacktrace/pull/150. This conflict could be + # turned into a variant that allows users to opt-in when they know it is + # safe to do so on affected platforms. + conflicts("+clanglibcpp", when="@1.85: +stacktrace") + # Patch fix from https://svn.boost.org/trac/boost/ticket/11856 patch("boost_11856.patch", when="@1.60.0%gcc@4.4.7") @@ -334,9 +347,6 @@ def libs(self): # Patch: https://github.com/boostorg/process/commit/6a4d2ff72114ef47c7afaf92e1042aca3dfa41b0.patch patch("1.72_boost_process.patch", level=2, when="@1.72.0") - # Fix the bootstrap/bjam build for Cray - patch("bootstrap-path.patch", when="@1.39.0: platform=cray") - # Patch fix for warnings from commits 2d37749, af1dc84, c705bab, and # 0134441 on https://github.com/boostorg/system. patch("system-non-virtual-dtor-include.patch", when="@1.69.0", level=2) @@ -438,7 +448,7 @@ def patch(self): def url_for_version(self, version): if version >= Version("1.63.0"): - url = "https://boostorg.jfrog.io/artifactory/main/release/{0}/source/boost_{1}.tar.bz2" + url = "https://archives.boost.io/release/{0}/source/boost_{1}.tar.bz2" else: url = "http://downloads.sourceforge.net/project/boost/boost/{0}/boost_{1}.tar.bz2" @@ -520,10 +530,6 @@ def determine_bootstrap_options(self, spec, with_libs, options): # wrappers. Since Boost doesn't use the MPI C++ bindings, # that can be used as a compiler option instead. mpi_line = "using mpi : %s" % spec["mpi"].mpicxx - - if "platform=cray" in spec: - mpi_line += " : MPICH_SKIP_MPICXX" - f.write(mpi_line + " ;\n") if "+python" in spec: @@ -636,6 +642,13 @@ def determine_b2_options(self, spec, options): if spec.variants["cxxstd"].value == "11": cxxflags.append("-std=c++11") + # See conflict above and + # https://github.com/boostorg/stacktrace/pull/150. This suppresses a + # compilation error that must be explicitly suppressed. Because of the + # conflict we can suppress the error without input from a user. + if spec.satisfies("@1.85: +stacktrace"): + cxxflags.append("-DBOOST_STACKTRACE_LIBCXX_RUNTIME_MAY_CAUSE_MEMORY_LEAK") + if cxxflags: options.append('cxxflags="{0}"'.format(" ".join(cxxflags))) diff --git a/var/spack/repos/builtin/packages/boostmplcartesianproduct/package.py b/var/spack/repos/builtin/packages/boostmplcartesianproduct/package.py index e940d648b3bb7f..c66b1ca6a59cbf 100644 --- a/var/spack/repos/builtin/packages/boostmplcartesianproduct/package.py +++ b/var/spack/repos/builtin/packages/boostmplcartesianproduct/package.py @@ -17,5 +17,7 @@ class Boostmplcartesianproduct(Package): version("20161205", sha256="1fa8e367e4dc545b34016bf57d802858ce38baf40aff20f7c93b329895a18572") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): install_tree("boost/mpl", join_path(prefix.include, "boost", "mpl")) diff --git a/var/spack/repos/builtin/packages/botan/package.py b/var/spack/repos/builtin/packages/botan/package.py index 922d89b28d76cc..9a16a46547abd4 100644 --- a/var/spack/repos/builtin/packages/botan/package.py +++ b/var/spack/repos/builtin/packages/botan/package.py @@ -16,6 +16,7 @@ class Botan(MakefilePackage): license("BSD-2-Clause") + version("3.4.0", sha256="71843afcc0a2c585f8f33fa304f0b58ae4b9c5d8306f894667b3746044277557") version("3.3.0", sha256="368f11f426f1205aedb9e9e32368a16535dc11bd60351066e6f6664ec36b85b9") version("3.2.0", sha256="049c847835fcf6ef3a9e206b33de05dd38999c325e247482772a5598d9e5ece3") version("3.1.1", sha256="30c84fe919936a98fef5331f246c62aa2c0e4d2085b2d4511207f6a20afa3a6b") @@ -41,6 +42,8 @@ class Botan(MakefilePackage): version("2.12.0", sha256="1eaefd459d52f27de1805cff8c68792e0610919648ee98e101980e94edb90a63") version("2.11.0", sha256="f7874da2aeb8c018fd77df40b2137879bf90b66f5589490c991e83fb3e8094be") + depends_on("cxx", type="build") # generated + variant("doc", default=False, description="Build documentation") executables = ["^botan$"] diff --git a/var/spack/repos/builtin/packages/bowtie/package.py b/var/spack/repos/builtin/packages/bowtie/package.py index 2df76062168e41..cabf35d67dc5f0 100644 --- a/var/spack/repos/builtin/packages/bowtie/package.py +++ b/var/spack/repos/builtin/packages/bowtie/package.py @@ -42,6 +42,9 @@ class Bowtie(MakefilePackage): url="https://downloads.sourceforge.net/project/bowtie-bio/bowtie/1.2.0/bowtie-1.2-source.zip", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # 1.2.2 and 1.2.2_p1 fail to build with %gcc@8.3.0 # with and without issue-87 patch conflicts("%gcc@8:", when="@1.2.2") diff --git a/var/spack/repos/builtin/packages/boxlib/package.py b/var/spack/repos/builtin/packages/boxlib/package.py index 4d67b338e21f7a..2fc461baecfdba 100644 --- a/var/spack/repos/builtin/packages/boxlib/package.py +++ b/var/spack/repos/builtin/packages/boxlib/package.py @@ -17,6 +17,10 @@ class Boxlib(CMakePackage): version("16.12.2", sha256="e87faeccfcb14b3436d36c45fcd9f46ea20f65298d35c6db2a80d6332b036dd2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") variant( diff --git a/var/spack/repos/builtin/packages/bpp-core/package.py b/var/spack/repos/builtin/packages/bpp-core/package.py index c1bd5c19d9f8a7..c56ce4afa85303 100644 --- a/var/spack/repos/builtin/packages/bpp-core/package.py +++ b/var/spack/repos/builtin/packages/bpp-core/package.py @@ -23,6 +23,8 @@ class BppCore(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("cmake@2.6:", type="build") # Clarify isnan's namespace, because Fujitsu compiler can't diff --git a/var/spack/repos/builtin/packages/bpp-phyl-omics/package.py b/var/spack/repos/builtin/packages/bpp-phyl-omics/package.py index bdcd4c186bba8e..f5ae9825ac0890 100644 --- a/var/spack/repos/builtin/packages/bpp-phyl-omics/package.py +++ b/var/spack/repos/builtin/packages/bpp-phyl-omics/package.py @@ -20,6 +20,8 @@ class BppPhylOmics(CMakePackage): version("2.3.1", sha256="f4853b99bf0baacf96c9ba567a5875242283cba5fb6f066d74716c6f7d84bd34") version("2.3.0", sha256="c4dc3aa39826c50bd8fe7ee4c56a92c8eb9922edc143864a0e2da34481036009") + depends_on("cxx", type="build") # generated + depends_on("cmake@2.6:", type="build") depends_on("bpp-core") depends_on("bpp-phyl") diff --git a/var/spack/repos/builtin/packages/bpp-phyl/package.py b/var/spack/repos/builtin/packages/bpp-phyl/package.py index 78c9d3aab95d36..c078bd520a1414 100644 --- a/var/spack/repos/builtin/packages/bpp-phyl/package.py +++ b/var/spack/repos/builtin/packages/bpp-phyl/package.py @@ -23,6 +23,8 @@ class BppPhyl(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("cmake@2.6:", type="build") depends_on("bpp-core") depends_on("bpp-seq") diff --git a/var/spack/repos/builtin/packages/bpp-popgen/package.py b/var/spack/repos/builtin/packages/bpp-popgen/package.py index 6aa6a9a2ca7a80..ffd4a73c8bab05 100644 --- a/var/spack/repos/builtin/packages/bpp-popgen/package.py +++ b/var/spack/repos/builtin/packages/bpp-popgen/package.py @@ -18,4 +18,6 @@ class BppPopgen(CMakePackage): version("2.4.1", sha256="03b57d71a63c8fa7f11c085e531d0d691fc1d40d4ea541070dabde0ab3baf413") + depends_on("cxx", type="build") # generated + depends_on("bpp-seq") diff --git a/var/spack/repos/builtin/packages/bpp-seq-omics/package.py b/var/spack/repos/builtin/packages/bpp-seq-omics/package.py index 5051043206154b..c1b10ce51c3ab6 100644 --- a/var/spack/repos/builtin/packages/bpp-seq-omics/package.py +++ b/var/spack/repos/builtin/packages/bpp-seq-omics/package.py @@ -20,5 +20,7 @@ class BppSeqOmics(CMakePackage): version("2.3.1", sha256="3217b35fa98e94824e19e5e2765f4561cb5d5ec0f93f5f4e7fc213e6b5b59e83") version("2.3.0", sha256="be0c8c593e48cd94a2a878e8635609788dfa806179f7844ecf8243e548bfe0fa") + depends_on("cxx", type="build") # generated + depends_on("bpp-core") depends_on("bpp-seq") diff --git a/var/spack/repos/builtin/packages/bpp-seq/package.py b/var/spack/repos/builtin/packages/bpp-seq/package.py index 9d6351508e1ec3..880b0360790570 100644 --- a/var/spack/repos/builtin/packages/bpp-seq/package.py +++ b/var/spack/repos/builtin/packages/bpp-seq/package.py @@ -23,6 +23,8 @@ class BppSeq(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("cmake@2.6:", type="build") depends_on("bpp-core") diff --git a/var/spack/repos/builtin/packages/bpp-suite/package.py b/var/spack/repos/builtin/packages/bpp-suite/package.py index 81e213fd050aa8..7c9d2c69a002e1 100644 --- a/var/spack/repos/builtin/packages/bpp-suite/package.py +++ b/var/spack/repos/builtin/packages/bpp-suite/package.py @@ -24,6 +24,8 @@ class BppSuite(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("cmake@2.6:", type="build") depends_on("texinfo", type="build") depends_on("bpp-core") diff --git a/var/spack/repos/builtin/packages/bracken/package.py b/var/spack/repos/builtin/packages/bracken/package.py index b62f82e638354f..7f18cafec16cf7 100644 --- a/var/spack/repos/builtin/packages/bracken/package.py +++ b/var/spack/repos/builtin/packages/bracken/package.py @@ -22,6 +22,8 @@ class Bracken(Package): version("2.8", sha256="b0c8a803cc020b7d1cbca47b53e71e874d9688b836911e4a4b71b0e4b826b61a") version("2.7", sha256="1795ecd9f9e5582f37549795ba68854780936110a2f6f285c3e626d448cd1532") + depends_on("cxx", type="build") # generated + depends_on("python", type="run") depends_on("kraken2", type="run") diff --git a/var/spack/repos/builtin/packages/brahma/package.py b/var/spack/repos/builtin/packages/brahma/package.py index 303a6b4e0c8110..224e4e1108b7a5 100644 --- a/var/spack/repos/builtin/packages/brahma/package.py +++ b/var/spack/repos/builtin/packages/brahma/package.py @@ -15,19 +15,29 @@ class Brahma(CMakePackage): license("MIT") - version("develop", branch="dev") + version("develop", branch="develop") version("master", branch="master") + version("0.0.5", tag="v0.0.5", commit="219198c653cc4add845a644872e7b963a8de0fe2") + version("0.0.4", tag="v0.0.4", commit="8f41cc885dd8e31a1f134cbbcbaaab7e5d84331e") + version("0.0.3", tag="v0.0.3", commit="fd201c653e8fa00d4ba6197a56a513f740e3014e") version("0.0.2", tag="v0.0.2", commit="4a36d5c08787d41c939fa1b987344b69d9ef97a6") version("0.0.1", tag="v0.0.1", commit="15156036f14e36511dfc3f3751dc953540526a2b") + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Enable MPI support") depends_on("cpp-logger@0.0.1", when="@:0.0.1") - depends_on("cpp-logger@0.0.2", when="@0.0.2:") + depends_on("cpp-logger@0.0.2", when="@0.0.2:0.0.3") + depends_on("cpp-logger@0.0.3", when="@0.0.4") + depends_on("cpp-logger@0.0.4", when="@0.0.5:") depends_on("gotcha@1.0.4", when="@:0.0.1") - depends_on("gotcha@1.0.5", when="@0.0.2:") - depends_on("catch2@3.0.1") + depends_on("gotcha@1.0.5", when="@0.0.2:0.0.3") + depends_on("gotcha@1.0.6", when="@0.0.4") + depends_on("gotcha@1.0.7", when="@0.0.5:") + depends_on("catch2@3.0.1:") depends_on("mpi", when="+mpi") def cmake_args(self): - return [self.define_from_variant("BUILD_WITH_MPI", "mpi")] + prefix = "BRAHMA_" if self.spec.satisfies("@0.0.4:") else "" + return [self.define_from_variant(f"{prefix}BUILD_WITH_MPI", "mpi")] diff --git a/var/spack/repos/builtin/packages/branson/package.py b/var/spack/repos/builtin/packages/branson/package.py index dd52874eea9677..70f4ad0b90a5ce 100644 --- a/var/spack/repos/builtin/packages/branson/package.py +++ b/var/spack/repos/builtin/packages/branson/package.py @@ -31,6 +31,8 @@ class Branson(CMakePackage): version("0.81", sha256="493f720904791f06b49ff48c17a681532c6a4d9fa59636522cf3f9700e77efe4") version("0.8", sha256="85ffee110f89be00c37798700508b66b0d15de1d98c54328b6d02a9eb2cf1cb8") + depends_on("cxx", type="build") # generated + depends_on("mpi@2:") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/breakdancer/package.py b/var/spack/repos/builtin/packages/breakdancer/package.py index 3b5d4147260973..4686129c3353bc 100644 --- a/var/spack/repos/builtin/packages/breakdancer/package.py +++ b/var/spack/repos/builtin/packages/breakdancer/package.py @@ -28,6 +28,8 @@ class Breakdancer(CMakePackage): preferred=True, ) + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("ncurses", type="link") diff --git a/var/spack/repos/builtin/packages/breseq/package.py b/var/spack/repos/builtin/packages/breseq/package.py index acf0bb71bc7e2b..397a60dc206b68 100644 --- a/var/spack/repos/builtin/packages/breseq/package.py +++ b/var/spack/repos/builtin/packages/breseq/package.py @@ -21,6 +21,9 @@ class Breseq(AutotoolsPackage): version("0.33.1", sha256="e24a50e254ad026c519747313b9e42bbeb32bd766a6a06ed369bd5b9dc50e84d") version("0.31.1", sha256="ffc8a7f40a5ad918234e465e9d4cdf74be02fd29091b13720c2cab1dc238cf5c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/bricks/package.py b/var/spack/repos/builtin/packages/bricks/package.py index 037802de682746..adef4b41c25eb3 100644 --- a/var/spack/repos/builtin/packages/bricks/package.py +++ b/var/spack/repos/builtin/packages/bricks/package.py @@ -27,6 +27,9 @@ class Bricks(CMakePackage): version("r0.1", branch="r0.1") version("2023.08.25", commit="d81725055c117c4b63a1b3835c6b634768b5bea7") # no official release + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cuda", default=False, description="Build bricks with CUDA enabled") # Building a variant of cmake without openssl is to match how the diff --git a/var/spack/repos/builtin/packages/bridger/package.py b/var/spack/repos/builtin/packages/bridger/package.py index d1c607238f741e..47077a7393ae39 100644 --- a/var/spack/repos/builtin/packages/bridger/package.py +++ b/var/spack/repos/builtin/packages/bridger/package.py @@ -20,6 +20,9 @@ class Bridger(MakefilePackage, SourceforgePackage): version( "2014-12-01", sha256="8fbec8603ea8ad2162cbd0c658e4e0a4af6453bdb53310b4b7e0d112e40b5737" ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("boost + exception + filesystem + system + serialization + graph") depends_on("ncurses~termlib") depends_on("perl", type="run") diff --git a/var/spack/repos/builtin/packages/brigand/package.py b/var/spack/repos/builtin/packages/brigand/package.py index 0bb8f27abfa63d..50c91a3c527caa 100644 --- a/var/spack/repos/builtin/packages/brigand/package.py +++ b/var/spack/repos/builtin/packages/brigand/package.py @@ -24,6 +24,8 @@ class Brigand(CMakePackage): version("1.1.0", sha256="afdcc6909ebff6994269d3039c31698c2b511a70280072f73382b26855221f64") version("1.0.0", sha256="8daf7686ff39792f851ef1977323808b80aab31c5f38ef0ba4e6a8faae491f8d") + depends_on("cxx", type="build") # generated + def cmake_args(self): args = [self.define("BUILD_TESTING", self.run_tests)] return args diff --git a/var/spack/repos/builtin/packages/brltty/package.py b/var/spack/repos/builtin/packages/brltty/package.py index 4e94ef3651afc5..40c74e58c3a3c8 100644 --- a/var/spack/repos/builtin/packages/brltty/package.py +++ b/var/spack/repos/builtin/packages/brltty/package.py @@ -21,6 +21,8 @@ class Brltty(AutotoolsPackage): version("5.5", sha256="cd80a0d225f13779791dc3a72d7f137c06c48e5f2c9600e80a565d2378422207") version("5.4", sha256="9ad5a540d29438a755f8b8f1f1534e0eba601c604f3d8223fa00b802959ec636") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/brotli/package.py b/var/spack/repos/builtin/packages/brotli/package.py index 1dc4c93352151b..799f8133bb5ce6 100644 --- a/var/spack/repos/builtin/packages/brotli/package.py +++ b/var/spack/repos/builtin/packages/brotli/package.py @@ -18,6 +18,8 @@ class Brotli(CMakePackage): version("1.0.9", sha256="f9e8d81d0405ba66d181529af42a3354f838c939095ff99930da6aa9cdf6fe46") version("1.0.7", sha256="4c61bfb0faca87219ea587326c467b95acb25555b53d1a421ffa3c8a9296ee2c") + depends_on("c", type="build") # generated + @run_after("install") def darwin_fix(self): # The shared library is not installed correctly on Darwin; fix this diff --git a/var/spack/repos/builtin/packages/brpc/package.py b/var/spack/repos/builtin/packages/brpc/package.py index 299622b7df7f54..3d7f00c922fd8c 100644 --- a/var/spack/repos/builtin/packages/brpc/package.py +++ b/var/spack/repos/builtin/packages/brpc/package.py @@ -17,10 +17,14 @@ class Brpc(CMakePackage): license("BSL-1.0") + version("1.9.0", sha256="85856da0216773e1296834116f69f9e80007b7ff421db3be5c9d1890ecfaea74") version("0.9.7", sha256="722cd342baf3b05189ca78ecf6c56ea6ffec22e62fc2938335e4e5bab545a49c") version("0.9.6", sha256="b872ca844999e0ba768acd823b409761f126590fb34cb0183da915a595161446") version("0.9.5", sha256="11ca8942242a4c542c11345b7463a4aea33a11ca33e91d9a2f64f126df8c70e9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gflags") depends_on("protobuf") depends_on("leveldb") diff --git a/var/spack/repos/builtin/packages/brunsli/package.py b/var/spack/repos/builtin/packages/brunsli/package.py index c0ce3de05d65a3..528ebc70ef9b2d 100644 --- a/var/spack/repos/builtin/packages/brunsli/package.py +++ b/var/spack/repos/builtin/packages/brunsli/package.py @@ -16,6 +16,9 @@ class Brunsli(CMakePackage): version("0.1", tag="v0.1", commit="8a0e9b8ca2e3e089731c95a1da7ce8a3180e667c", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build") @property diff --git a/var/spack/repos/builtin/packages/brynet/package.py b/var/spack/repos/builtin/packages/brynet/package.py index a6a81363b5e44d..be055a7db42016 100644 --- a/var/spack/repos/builtin/packages/brynet/package.py +++ b/var/spack/repos/builtin/packages/brynet/package.py @@ -21,6 +21,8 @@ class Brynet(CMakePackage): version("1.0.7", sha256="60116fccff108d03f3ff0a3d5c1fb5ad442bad7ef155bf1a3c7819ffc9d57524") version("1.0.6", sha256="5e94b5b64fbdfbcb4e33b11fb7832cf0ca3898ab6b6461867182598bab7ca65f") + depends_on("cxx", type="build") # generated + def cmake_args(self): args = [] args.append("-Dbrynet_BUILD_EXAMPLES=ON") diff --git a/var/spack/repos/builtin/packages/btop/package.py b/var/spack/repos/builtin/packages/btop/package.py index 2e76633ccea247..b388a6daacee62 100644 --- a/var/spack/repos/builtin/packages/btop/package.py +++ b/var/spack/repos/builtin/packages/btop/package.py @@ -22,6 +22,8 @@ class Btop(MakefilePackage, CMakePackage): version("1.3.0", sha256="375e078ce2091969f0cd14030620bd1a94987451cf7a73859127a786006a32cf") version("1.2.13", sha256="668dc4782432564c35ad0d32748f972248cc5c5448c9009faeb3445282920e02") + depends_on("cxx", type="build") # generated + build_system("makefile", conditional("cmake", when="@1.3.0:"), default="cmake") variant("gpu", default=False, description="Enable GPU support", when="build_system=cmake") diff --git a/var/spack/repos/builtin/packages/bubblewrap/package.py b/var/spack/repos/builtin/packages/bubblewrap/package.py index 5925aee4de499c..6811eda3beae89 100644 --- a/var/spack/repos/builtin/packages/bubblewrap/package.py +++ b/var/spack/repos/builtin/packages/bubblewrap/package.py @@ -28,6 +28,8 @@ class Bubblewrap(AutotoolsPackage): version("0.3.3", sha256="c6a45f51794a908b76833b132471397a7413f07620af08e76c273d9f7b364dff") version("0.3.1", sha256="deca6b608c54df4be0669b8bb6d254858924588e9f86e116eb04656a3b6d4bf8") + depends_on("c", type="build") # generated + def configure_args(self): return ["--disable-sudo", "--disable-man", "--without-bash-completion-dir"] diff --git a/var/spack/repos/builtin/packages/buddy/package.py b/var/spack/repos/builtin/packages/buddy/package.py index 3a9a6982f27a25..49b77e8e2dd9fa 100644 --- a/var/spack/repos/builtin/packages/buddy/package.py +++ b/var/spack/repos/builtin/packages/buddy/package.py @@ -18,6 +18,9 @@ class Buddy(AutotoolsPackage): version("2.4", sha256="d3df80a6a669d9ae408cb46012ff17bd33d855529d20f3a7e563d0d913358836") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def configure_args(self): if platform.machine() == "aarch64": config_args = ["--build=aarch64-unknown-linux-gnu"] diff --git a/var/spack/repos/builtin/packages/bueno/package.py b/var/spack/repos/builtin/packages/bueno/package.py index f08d719ef8ecf2..f571fd69380812 100644 --- a/var/spack/repos/builtin/packages/bueno/package.py +++ b/var/spack/repos/builtin/packages/bueno/package.py @@ -19,6 +19,8 @@ class Bueno(PythonPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("python@3.7:", type=("build", "run")) depends_on("py-pyyaml", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/bufr/package.py b/var/spack/repos/builtin/packages/bufr/package.py index 6339c727dfa7f7..76cd7909ae5565 100644 --- a/var/spack/repos/builtin/packages/bufr/package.py +++ b/var/spack/repos/builtin/packages/bufr/package.py @@ -31,6 +31,9 @@ class Bufr(CMakePackage): version("11.5.0", sha256="d154839e29ef1fe82e58cf20232e9f8a4f0610f0e8b6a394b7ca052e58f97f43") version("11.4.0", sha256="946482405e675b99e8e0c221d137768f246076f5e9ba92eed6cae47fb68b7a26") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # Patch to not add "-c" to ranlib flags when using llvm-ranlib on Apple systems patch("cmakelists-apple-llvm-ranlib.patch", when="@11.5.0:11.6.0") # C test does not explicity link to -lm causing DSO error when building shared libs diff --git a/var/spack/repos/builtin/packages/busybox/package.py b/var/spack/repos/builtin/packages/busybox/package.py index ccecdc8d555605..e7d36937fba351 100644 --- a/var/spack/repos/builtin/packages/busybox/package.py +++ b/var/spack/repos/builtin/packages/busybox/package.py @@ -23,6 +23,9 @@ class Busybox(MakefilePackage): version("1.30.1", sha256="3d1d04a4dbd34048f4794815a5c48ebb9eb53c5277e09ffffc060323b95dfbdc") version("1.30.0", sha256="9553da068c0a30b1b8b72479908c1ba58672e2be7b535363a88de5e0f7bc04ce") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def build(self, spec, prefix): make("defconfig") make(f"CC={spack_cc}") diff --git a/var/spack/repos/builtin/packages/butterflypack/package.py b/var/spack/repos/builtin/packages/butterflypack/package.py index 048b0a02431eca..3d2e8db6b3b4f9 100644 --- a/var/spack/repos/builtin/packages/butterflypack/package.py +++ b/var/spack/repos/builtin/packages/butterflypack/package.py @@ -3,8 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -from platform import machine - from spack.package import * @@ -44,6 +42,10 @@ class Butterflypack(CMakePackage): version("1.0.1", sha256="e8ada37466a19f49e13456b150700d4c3afaad2ddbe3678f4e933f9d556a24a5") version("1.0.0", sha256="86c5eb09a18522367d63ce2bacf67ca1c9813ef351a1443baaab3c53f0d77232") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("openmp", default=True, description="add OpenMP support") @@ -79,7 +81,13 @@ def cmake_args(self): args.append("-Denable_openmp=%s" % ("ON" if "+openmp" in spec else "OFF")) if "%cce" in spec: # Assume the proper Cray CCE module (cce) is loaded: - craylibs_path = env["CRAYLIBS_" + machine().upper()] + craylibs_var = "CRAYLIBS_" + str(spec.target.family).upper() + craylibs_path = env.get(craylibs_var, None) + if not craylibs_path: + raise InstallError( + f"The environment variable {craylibs_var} is not defined.\n" + "\tMake sure the 'cce' module is in the compiler spec." + ) env.setdefault("LDFLAGS", "") env["LDFLAGS"] += " -Wl,-rpath," + craylibs_path diff --git a/var/spack/repos/builtin/packages/bwa/package.py b/var/spack/repos/builtin/packages/bwa/package.py index ad003282995649..1c1aea92682529 100644 --- a/var/spack/repos/builtin/packages/bwa/package.py +++ b/var/spack/repos/builtin/packages/bwa/package.py @@ -25,6 +25,8 @@ class Bwa(Package): url="https://github.com/lh3/bwa/archive/0.7.12.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("zlib-api") depends_on("sse2neon", when="target=aarch64:") diff --git a/var/spack/repos/builtin/packages/bwtool/package.py b/var/spack/repos/builtin/packages/bwtool/package.py index a966b41a34a33b..a9b249070e8421 100644 --- a/var/spack/repos/builtin/packages/bwtool/package.py +++ b/var/spack/repos/builtin/packages/bwtool/package.py @@ -14,4 +14,6 @@ class Bwtool(AutotoolsPackage): version("1.0", sha256="2e177573602c129e1d37e07288bdc04bef14d2c25c39636aea8c9a359400594a") + depends_on("c", type="build") # generated + depends_on("libbeato") diff --git a/var/spack/repos/builtin/packages/byfl/package.py b/var/spack/repos/builtin/packages/byfl/package.py index ac79bc85f0d906..ac8275f24c7f83 100644 --- a/var/spack/repos/builtin/packages/byfl/package.py +++ b/var/spack/repos/builtin/packages/byfl/package.py @@ -18,4 +18,9 @@ class Byfl(CMakePackage): version("1.8.0", sha256="45a9640ba2d77153a425c72349c18b124754123b30c411707b71abd217bbfce0") - depends_on("llvm@:13.9999") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + # llvm-13 builds, but doesn’t work + depends_on("llvm@:12.9999") diff --git a/var/spack/repos/builtin/packages/byte-unixbench/package.py b/var/spack/repos/builtin/packages/byte-unixbench/package.py index f9332bf853cae3..6dc0b50d93debe 100644 --- a/var/spack/repos/builtin/packages/byte-unixbench/package.py +++ b/var/spack/repos/builtin/packages/byte-unixbench/package.py @@ -14,6 +14,8 @@ class ByteUnixbench(MakefilePackage): version("5.1.3", sha256="3a6bb00f270a5329682dff20fd2c1ab5332ef046eb54a96a0d7bd371005d31a3") + depends_on("c", type="build") # generated + build_directory = "UnixBench" @property diff --git a/var/spack/repos/builtin/packages/bzip2/package.py b/var/spack/repos/builtin/packages/bzip2/package.py index e9d56f124f49da..1a60cd030c6ea6 100644 --- a/var/spack/repos/builtin/packages/bzip2/package.py +++ b/var/spack/repos/builtin/packages/bzip2/package.py @@ -28,6 +28,8 @@ class Bzip2(Package, SourcewarePackage): version("1.0.7", sha256="e768a87c5b1a79511499beb41500bcc4caf203726fff46a6f5f9ad27fe08ab2b") version("1.0.6", sha256="a2848f34fcd5d6cf47def00461fcb528a0484d8edef8208d6d2e2909dc61d9cd") + depends_on("c", type="build") # generated + variant( "shared", default=(sys.platform != "win32"), @@ -47,7 +49,6 @@ class Bzip2(Package, SourcewarePackage): depends_on("diffutils", type="build") depends_on("gmake", type="build", when="platform=linux") - depends_on("gmake", type="build", when="platform=cray") depends_on("gmake", type="build", when="platform=darwin") @classmethod diff --git a/var/spack/repos/builtin/packages/c-ares/package.py b/var/spack/repos/builtin/packages/c-ares/package.py index 34beec24bab5cd..51fb1dc9da2bce 100644 --- a/var/spack/repos/builtin/packages/c-ares/package.py +++ b/var/spack/repos/builtin/packages/c-ares/package.py @@ -16,10 +16,14 @@ class CAres(CMakePackage): license("MIT") version("master", branch="master") + version("1.28.1", sha256="e520d971415e48e607819c2f4b377b0aa69044ef6619160bb41bdba15ab4d545") version("1.27.0", sha256="de6a839d47b93174ba260187a084027ea681a91ffe12f2d5f20645652eae246c") version("1.15.0", sha256="7deb7872cbd876c29036d5f37e30c4cbc3cc068d59d8b749ef85bb0736649f04") version("1.13.0", sha256="7c48c57706a38691041920e705d2a04426ad9c68d40edd600685323f214b2d57") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): url = "https://github.com/c-ares/c-ares/archive/cares-{0}.tar.gz" return url.format(version.underscored) diff --git a/var/spack/repos/builtin/packages/c-blosc/package.py b/var/spack/repos/builtin/packages/c-blosc/package.py index ba6381f31786d6..fe16bcb62078a5 100644 --- a/var/spack/repos/builtin/packages/c-blosc/package.py +++ b/var/spack/repos/builtin/packages/c-blosc/package.py @@ -33,6 +33,9 @@ class CBlosc(CMakePackage): version("1.8.1", sha256="1abf048634c37aeca53eeb6a9248ea235074077028d12b3560eccf1dff7143b8") version("1.8.0", sha256="e0f8b9e12e86776a1b037385826c55006da6e2ae4973dac5b5ad3cfcf01e9043") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("avx2", default=True, description="Enable AVX2 support") depends_on("cmake@2.8.10:", type="build") diff --git a/var/spack/repos/builtin/packages/c-blosc2/package.py b/var/spack/repos/builtin/packages/c-blosc2/package.py index 0bbbecefaf79af..c899c16e997982 100644 --- a/var/spack/repos/builtin/packages/c-blosc2/package.py +++ b/var/spack/repos/builtin/packages/c-blosc2/package.py @@ -34,6 +34,8 @@ class CBlosc2(CMakePackage): version("2.0.2", sha256="fba51ba601610441eea6046e384284b2d8d7884922060cf15369d01d713b9b77") version("2.0.1", sha256="35b93dfed479b1dfd9372d41d7843b60254ed1d71792577b95e489c28705874f") + depends_on("c", type="build") # generated + variant("avx2", default=True, description="Enable AVX2 support") variant("lizard", default=True, description="support for LIZARD (LZ5)") diff --git a/var/spack/repos/builtin/packages/c-lime/package.py b/var/spack/repos/builtin/packages/c-lime/package.py index b4b2ee31ada224..cb0d8b6cf53e1a 100644 --- a/var/spack/repos/builtin/packages/c-lime/package.py +++ b/var/spack/repos/builtin/packages/c-lime/package.py @@ -18,3 +18,5 @@ class CLime(AutotoolsPackage): license("GPL-2.0-or-later") version("2-3-9", sha256="7b9aeadd4dfec50e24da3e7e729f56abf95c9192612c41515fe27b2158773aac") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/c-raft/package.py b/var/spack/repos/builtin/packages/c-raft/package.py index 4e4480ba9c79c9..e9f5238313959a 100644 --- a/var/spack/repos/builtin/packages/c-raft/package.py +++ b/var/spack/repos/builtin/packages/c-raft/package.py @@ -19,6 +19,8 @@ class CRaft(AutotoolsPackage): version("master", branch="master") version("0.17.1", sha256="e31c7fafbdd5f94913161c5d64341a203364e512524b47295c97a91e83c4198b") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/c3d/package.py b/var/spack/repos/builtin/packages/c3d/package.py index ab4b2872ec8252..e69588e7ba6114 100644 --- a/var/spack/repos/builtin/packages/c3d/package.py +++ b/var/spack/repos/builtin/packages/c3d/package.py @@ -17,6 +17,9 @@ class C3d(CMakePackage): version("1.3.0", sha256="bd45482247fa4ac5ab98b3a775b5438390671e3e224a42f73967904b3895050d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("itk") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/cabana/package.py b/var/spack/repos/builtin/packages/cabana/package.py index 2327939bbbe7ff..556d2ae2cf6744 100644 --- a/var/spack/repos/builtin/packages/cabana/package.py +++ b/var/spack/repos/builtin/packages/cabana/package.py @@ -27,6 +27,8 @@ class Cabana(CMakePackage, CudaPackage, ROCmPackage): version("0.1.0", sha256="3280712facf6932b9d1aff375b24c932abb9f60a8addb0c0a1950afd0cb9b9cf") version("0.1.0-rc0", sha256="73754d38aaa0c2a1e012be6959787108fec142294774c23f70292f59c1bdc6c5") + depends_on("cxx", type="build") # generated + _kokkos_backends = Kokkos.devices_variants for _backend in _kokkos_backends: _deflt, _descr = _kokkos_backends[_backend] diff --git a/var/spack/repos/builtin/packages/cachefilesd/package.py b/var/spack/repos/builtin/packages/cachefilesd/package.py index d92ae8d6803936..9f193722c1e22a 100644 --- a/var/spack/repos/builtin/packages/cachefilesd/package.py +++ b/var/spack/repos/builtin/packages/cachefilesd/package.py @@ -20,6 +20,8 @@ class Cachefilesd(MakefilePackage): version("0.10.6", sha256="aaaaea887a5850c6fa01d09c80946e987411f6b550261f83967c671c65af959d") version("0.10.5", sha256="125ea4f6aef4bf8e936a7cc747b59e074537a8aed74cd1bab3f05d7fbc47287f") + depends_on("c", type="build") # generated + @when("target=aarch64:") def edit(self, spec, prefix): makefile = FileFilter("Makefile") diff --git a/var/spack/repos/builtin/packages/caffe/package.py b/var/spack/repos/builtin/packages/caffe/package.py index 5103368b1fa848..fc0b3db426ca3c 100644 --- a/var/spack/repos/builtin/packages/caffe/package.py +++ b/var/spack/repos/builtin/packages/caffe/package.py @@ -23,6 +23,8 @@ class Caffe(CMakePackage, CudaPackage): version("rc3", sha256="0884207bfba0fbc8b263b87d30f9304f7094eec3a48f975177d142f8c72b6e3b") version("rc2", sha256="55c9c20870b30ce398e19e4f1a62ade1eff08fce51e28fa5604035b711978eec") + depends_on("cxx", type="build") # generated + variant("cuda", default=False, description="Builds with support for GPUs via CUDA and cuDNN") variant("opencv", default=True, description="Build with OpenCV support") variant("leveldb", default=True, description="Build with levelDB") diff --git a/var/spack/repos/builtin/packages/cairo/package.py b/var/spack/repos/builtin/packages/cairo/package.py index 20cd0c8fbf070b..6d220d2027c77f 100644 --- a/var/spack/repos/builtin/packages/cairo/package.py +++ b/var/spack/repos/builtin/packages/cairo/package.py @@ -35,13 +35,16 @@ class Cairo(AutotoolsPackage): version("1.14.8", sha256="d1f2d98ae9a4111564f6de4e013d639cf77155baf2556582295a0f00a9bc5e20") version("1.14.0", sha256="2cf5f81432e77ea4359af9dcd0f4faf37d015934501391c311bfd2d19a0134b7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("X", default=False, description="Build with X11 support") variant("pdf", default=False, description="Enable cairo's PDF surface backend feature") variant("gobject", default=False, description="Enable cairo's gobject functions feature") variant("ft", default=False, description="Enable cairo's FreeType font backend feature") variant("fc", default=False, description="Enable cairo's Fontconfig font backend feature") variant("png", default=False, description="Enable cairo's PNG functions feature") - variant("svg", default=False, description="Enable cairo's SVN functions feature") + variant("svg", default=False, description="Enable cairo's SVG functions feature") variant("shared", default=True, description="Build shared libraries") variant("pic", default=True, description="Enable position-independent code (PIC)") @@ -51,7 +54,6 @@ class Cairo(AutotoolsPackage): depends_on("libxcb", when="+X") depends_on("python", when="+X", type="build") depends_on("libpng", when="+png") - depends_on("librsvg", when="+svg") depends_on("glib") depends_on("pixman@0.36.0:", when="@1.17.2:") depends_on("pixman") @@ -59,7 +61,7 @@ class Cairo(AutotoolsPackage): depends_on("autoconf", type="build") depends_on("libtool", type="build") depends_on("m4", type="build") - depends_on("freetype", when="+ft") + depends_on("freetype build_system=autotools", when="+ft") depends_on("pkgconfig", type="build") depends_on("fontconfig@2.10.91:", when="+fc") # Require newer version of fontconfig. depends_on("which", type="build") diff --git a/var/spack/repos/builtin/packages/cairomm/package.py b/var/spack/repos/builtin/packages/cairomm/package.py index 8812da63e61e58..c4d9f0c8c01f2d 100644 --- a/var/spack/repos/builtin/packages/cairomm/package.py +++ b/var/spack/repos/builtin/packages/cairomm/package.py @@ -17,6 +17,8 @@ class Cairomm(AutotoolsPackage): version("1.6.4", sha256="3cb2c898d0ceb94ad2deb722b50a3a6ee46abdda741ecd6e5a40517c85ecea4c") version("1.6.2", sha256="068edc1743d92ff1d102141ba7597ba02a47379f9cb97799b0c3310848b56eff") + depends_on("cxx", type="build") # generated + depends_on("cairo") depends_on("libsigcpp") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/caliper/package.py b/var/spack/repos/builtin/packages/caliper/package.py index b0ed25dfe92689..904e808de11790 100644 --- a/var/spack/repos/builtin/packages/caliper/package.py +++ b/var/spack/repos/builtin/packages/caliper/package.py @@ -18,7 +18,7 @@ class Caliper(CMakePackage, CudaPackage, ROCmPackage): homepage = "https://github.com/LLNL/Caliper" git = "https://github.com/LLNL/Caliper.git" - url = "https://github.com/LLNL/Caliper/archive/v2.10.0.tar.gz" + url = "https://github.com/LLNL/Caliper/archive/v2.11.0.tar.gz" tags = ["e4s", "radiuss"] maintainers("daboehme") @@ -28,6 +28,7 @@ class Caliper(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("master", branch="master") + version("2.11.0", sha256="b86b733cbb73495d5f3fe06e6a9885ec77365c8aa9195e7654581180adc2217c") version("2.10.0", sha256="14c4fb5edd5e67808d581523b4f8f05ace8549698c0e90d84b53171a77f58565") version("2.9.1", sha256="4771d630de505eff9227e0ec498d0da33ae6f9c34df23cb201b56181b8759e9e") version("2.9.0", sha256="507ea74be64a2dfd111b292c24c4f55f459257528ba51a5242313fa50978371f") @@ -75,10 +76,14 @@ class Caliper(CMakePackage, CudaPackage, ROCmPackage): "1.7.0", tag="v1.7.0", commit="898277c93d884d4e7ca1ffcf3bbea81d22364f26", deprecated=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + is_linux = sys.platform.startswith("linux") variant("shared", default=True, description="Build shared libraries") variant("adiak", default=True, description="Enable Adiak support") - variant("mpi", default=True, description="Enable MPI wrappers") + variant("mpi", default=True, description="Enable MPI support") # libunwind has some issues on Mac variant( "libunwind", default=sys.platform != "darwin", description="Enable stack unwind support" @@ -93,9 +98,12 @@ class Caliper(CMakePackage, CudaPackage, ROCmPackage): variant("sosflow", default=False, description="Enable SOSflow support") variant("fortran", default=False, description="Enable Fortran support") variant("variorum", default=False, description="Enable Variorum support") + variant("vtune", default=False, description="Enable Intel Vtune support") variant("kokkos", default=True, when="@2.3.0:", description="Enable Kokkos profiling support") + variant("tests", default=False, description="Enable tests") - depends_on("adiak@0.1:0", when="@2.2: +adiak") + depends_on("adiak@0.1:0", when="@2.2:2.10 +adiak") + depends_on("adiak@0.4:0", when="@2.11: +adiak") depends_on("papi@5.3:5", when="@:2.2 +papi") depends_on("papi@5.3:", when="@2.3: +papi") @@ -106,6 +114,7 @@ class Caliper(CMakePackage, CudaPackage, ROCmPackage): depends_on("unwind@1.2:1", when="+libunwind") depends_on("elfutils", when="+libdw") depends_on("variorum", when="+variorum") + depends_on("intel-oneapi-vtune", when="+vtune") depends_on("sosflow@spack", when="@1.0:1+sosflow") @@ -113,7 +122,7 @@ class Caliper(CMakePackage, CudaPackage, ROCmPackage): depends_on("python", type="build") # sosflow support not yet in 2.0 - conflicts("+sosflow", "@2.0.0:2.9") + conflicts("+sosflow", "@2.0.0:2.11") conflicts("+adiak", "@:2.1") conflicts("+libdw", "@:2.4") conflicts("+rocm", "@:2.7") @@ -146,6 +155,7 @@ def cmake_args(self): self.define_from_variant("WITH_ROCTRACER", "rocm"), self.define_from_variant("WITH_ROCTX", "rocm"), self.define_from_variant("WITH_VARIORUM", "variorum"), + self.define_from_variant("WITH_VTUNE", "vtune"), self.define_from_variant("WITH_KOKKOS", "kokkos"), ] @@ -178,6 +188,10 @@ def cmake_args(self): # ${CUDA_TOOLKIT_ROOT_DIR}/extras/CUPTI args.append("-DCUPTI_PREFIX=%s" % spec["cuda"].prefix) + if "+vtune" in spec: + itt_dir = join_path(spec["intel-oneapi-vtune"].prefix, "vtune", "latest") + args.append("-DITT_PREFIX=%s" % itt_dir) + if "+rocm" in spec: args.append("-DCMAKE_CXX_COMPILER={0}".format(spec["hip"].hipcc)) args.append("-DROCM_PREFIX=%s" % spec["hsa-rocr-dev"].prefix) diff --git a/var/spack/repos/builtin/packages/callpath/package.py b/var/spack/repos/builtin/packages/callpath/package.py index 29566c512f3f64..3b36222c97e6fc 100644 --- a/var/spack/repos/builtin/packages/callpath/package.py +++ b/var/spack/repos/builtin/packages/callpath/package.py @@ -17,6 +17,8 @@ class Callpath(CMakePackage): version("1.0.2", sha256="cbe42bba8b9dda259dcbe7e16ebd7ecd005eabf7e9ccf169535b03110df75c84") version("1.0.1", sha256="9bd9723126f80d0b518c28e5298ad0fa8d8dbc6a3f03fee5ae5449cf4c9a550f") + depends_on("cxx", type="build") # generated + depends_on("elf", type="link") depends_on("libdwarf") depends_on("dyninst") diff --git a/var/spack/repos/builtin/packages/camellia/package.py b/var/spack/repos/builtin/packages/camellia/package.py index e9a80de93bc11a..1ae82413474d10 100644 --- a/var/spack/repos/builtin/packages/camellia/package.py +++ b/var/spack/repos/builtin/packages/camellia/package.py @@ -18,6 +18,8 @@ class Camellia(CMakePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + variant( "moab", default=True, diff --git a/var/spack/repos/builtin/packages/camp/camp-rocm6.patch b/var/spack/repos/builtin/packages/camp/camp-rocm6.patch new file mode 100644 index 00000000000000..dbb3fa022071b3 --- /dev/null +++ b/var/spack/repos/builtin/packages/camp/camp-rocm6.patch @@ -0,0 +1,15 @@ +diff -ruN spack-src/include/camp/resource/hip.hpp spack-src-patched/include/camp/resource/hip.hpp +--- spack-src/include/camp/resource/hip.hpp 2021-08-20 23:38:39.000000000 +0000 ++++ spack-src-patched/include/camp/resource/hip.hpp 2024-06-06 21:34:25.174477941 +0000 +@@ -111,7 +111,11 @@ + hipPointerAttribute_t a; + hipError_t status = hipPointerGetAttributes(&a, p); + if (status == hipSuccess) { ++#if (HIP_VERSION_MAJOR >= 6) ++ switch (a.type) { ++#else + switch (a.memoryType) { ++#endif + case hipMemoryTypeHost: + return MemoryAccess::Pinned; + case hipMemoryTypeDevice: diff --git a/var/spack/repos/builtin/packages/camp/package.py b/var/spack/repos/builtin/packages/camp/package.py index c6c262cf91c7c1..324a075ecb59a5 100644 --- a/var/spack/repos/builtin/packages/camp/package.py +++ b/var/spack/repos/builtin/packages/camp/package.py @@ -3,29 +3,9 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import glob - from spack.package import * -def hip_repair_options(options, spec): - # there is only one dir like this, but the version component is unknown - options.append( - "-DHIP_CLANG_INCLUDE_PATH=" - + glob.glob("{}/lib/clang/*/include".format(spec["llvm-amdgpu"].prefix))[0] - ) - - -def hip_repair_cache(options, spec): - # there is only one dir like this, but the version component is unknown - options.append( - cmake_cache_path( - "HIP_CLANG_INCLUDE_PATH", - glob.glob("{}/lib/clang/*/include".format(spec["llvm-amdgpu"].prefix))[0], - ) - ) - - class Camp(CMakePackage, CudaPackage, ROCmPackage): """ Compiler agnostic metaprogramming library providing concepts, @@ -36,12 +16,31 @@ class Camp(CMakePackage, CudaPackage, ROCmPackage): git = "https://github.com/LLNL/camp.git" url = "https://github.com/LLNL/camp/archive/v0.1.0.tar.gz" - maintainers("trws") + maintainers("trws", "adrienbernede") license("BSD-3-Clause") - version("main", branch="main", submodules="True") + version("main", branch="main", submodules=False) + version( + "2024.02.1", + tag="v2024.02.", + commit="79c320fa09db987923b56884afdc9f82f4b70fc4", + submodules=False, + ) + version( + "2024.02.0", + tag="v2024.02.0", + commit="03c80a6c6ab4f97e76a52639563daec71435a277", + submodules=False, + ) + version( + "2023.06.0", + tag="v2023.06.0", + commit="ac34c25b722a06b138bc045d38bfa5e8fa3ec9c5", + submodules=False, + ) version("2022.10.1", sha256="2d12f1a46f5a6d01880fc075cfbd332e2cf296816a7c1aa12d4ee5644d386f02") + version("2022.10.0", sha256="3561c3ef00bbcb61fe3183c53d49b110e54910f47e7fc689ad9ccce57e55d6b8") version("2022.03.2", sha256="bc4aaeacfe8f2912e28f7a36fc731ab9e481bee15f2c6daf0cb208eed3f201eb") version("2022.03.0", sha256="e9090d5ee191ea3a8e36b47a8fe78f3ac95d51804f1d986d931e85b8f8dad721") version("0.3.0", sha256="129431a049ca5825443038ad5a37a86ba6d09b2618d5fe65d35f83136575afdb") @@ -49,17 +48,23 @@ class Camp(CMakePackage, CudaPackage, ROCmPackage): version("0.2.2", sha256="194d38b57e50e3494482a7f94940b27f37a2bee8291f2574d64db342b981d819") version("0.1.0", sha256="fd4f0f2a60b82a12a1d9f943f8893dc6fe770db493f8fae5ef6f7d0c439bebcc") + depends_on("cxx", type="build") # generated + # TODO: figure out gtest dependency and then set this default True. variant("tests", default=False, description="Build tests") - variant("openmp", default=False, description="Build OpenMP support") + variant("openmp", default=False, description="Build with OpenMP support") depends_on("cub", when="+cuda") depends_on("blt", type="build") - depends_on("blt@0.5.0:0.5.3", type="build", when="@2022.03.0:") + depends_on("blt@0.6.2:", type="build", when="@2024.02.1:") + depends_on("blt@0.6.1:", type="build", when="@2024.02.0:") + depends_on("blt@0.5.0:0.5.3", type="build", when="@2022.03.0:2023.06.0") patch("libstdc++-13-missing-header.patch", when="@:2022.10") + patch("camp-rocm6.patch", when="@0.2.3 +rocm ^hip@6:") + conflicts("^blt@:0.3.6", when="+rocm") def cmake_args(self): @@ -69,11 +74,9 @@ def cmake_args(self): options.append("-DBLT_SOURCE_DIR={0}".format(spec["blt"].prefix)) - options.append("-DENABLE_OPENMP=" + ("On" if "+openmp" in spec else "Off")) + options.append(self.define_from_variant("ENABLE_CUDA", "cuda")) if "+cuda" in spec: - options.extend( - ["-DENABLE_CUDA=ON", "-DCUDA_TOOLKIT_ROOT_DIR=%s" % (spec["cuda"].prefix)] - ) + options.append("-DCUDA_TOOLKIT_ROOT_DIR={0}".format(spec["cuda"].prefix)) if not spec.satisfies("cuda_arch=none"): cuda_arch = spec.variants["cuda_arch"].value @@ -81,21 +84,17 @@ def cmake_args(self): options.append("-DCUDA_ARCH=sm_{0}".format(cuda_arch[0])) flag = "-arch sm_{0}".format(cuda_arch[0]) options.append("-DCMAKE_CUDA_FLAGS:STRING={0}".format(flag)) - else: - options.append("-DENABLE_CUDA=OFF") + options.append(self.define_from_variant("ENABLE_HIP", "rocm")) if "+rocm" in spec: - options.extend(["-DENABLE_HIP=ON", "-DHIP_ROOT_DIR={0}".format(spec["hip"].prefix)]) - - hip_repair_options(options, spec) + options.append("-DHIP_ROOT_DIR={0}".format(spec["hip"].prefix)) archs = self.spec.variants["amdgpu_target"].value - if archs != "none": - arch_str = ",".join(archs) - options.append("-DHIP_HIPCC_FLAGS=--amdgpu-target={0}".format(arch_str)) - else: - options.append("-DENABLE_HIP=OFF") + options.append("-DCMAKE_HIP_ARCHITECTURES={0}".format(archs)) + options.append("-DGPU_TARGETS={0}".format(archs)) + options.append("-DAMDGPU_TARGETS={0}".format(archs)) + options.append(self.define_from_variant("ENABLE_OPENMP", "openmp")) options.append(self.define_from_variant("ENABLE_TESTS", "tests")) return options diff --git a/var/spack/repos/builtin/packages/candle-benchmarks/package.py b/var/spack/repos/builtin/packages/candle-benchmarks/package.py deleted file mode 100644 index a002f6b5b31464..00000000000000 --- a/var/spack/repos/builtin/packages/candle-benchmarks/package.py +++ /dev/null @@ -1,43 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -from spack.package import * - - -class CandleBenchmarks(Package): - """ECP-CANDLE Benchmarks""" - - homepage = "https://github.com/ECP-CANDLE/Benchmarks" - url = "https://github.com/ECP-CANDLE/Benchmarks/archive/v0.1.tar.gz" - - tags = ["proxy-app", "ecp-proxy-app"] - - license("MIT") - - version("0.5.1", sha256="3d8c4f5a8304ee238e93e88e871a8b4d47d6b377159c048ac6d3ed01b6ffc245") - version("0.1", sha256="767f74f43ee3a5d4e0f26750f2a96b8433e25a9cd4f2d29938ac8acf263ab58d") - version("0.0", sha256="faa0d24355071de0e375d72ed1a39dcf30006602210cf8cf09db568b5d0b679f") - - variant("mpi", default=True, description="Build with MPI support") - - extends("python") - depends_on("python@2.7:") - depends_on("py-theano +cuda", type=("build", "run")) - depends_on("py-keras", type=("build", "run")) - depends_on("py-matplotlib +image@:2.2.3", type=("build", "run")) - depends_on("py-tqdm", type=("build", "run")) - depends_on("py-scikit-learn", type=("build", "run")) - depends_on("opencv@3.2.0: +highgui +imgproc +jpeg +png +tiff ~dnn ~eigen ~gtk") - depends_on("py-mdanalysis", type=("build", "run")) - depends_on("py-mpi4py", when="+mpi", type=("build", "run")) - depends_on("py-h5py~mpi", when="~mpi", type=("build", "run")) - depends_on("py-h5py+mpi", when="+mpi", type=("build", "run")) - depends_on("py-requests", type=("build", "run")) - - # see #3244, but use external for now - # depends_on('tensorflow') - - def install(self, spec, prefix): - install_tree(self.stage.source_path, prefix.bin) diff --git a/var/spack/repos/builtin/packages/cans/package.py b/var/spack/repos/builtin/packages/cans/package.py index 8827ff9d6a87ea..8279910a085f55 100644 --- a/var/spack/repos/builtin/packages/cans/package.py +++ b/var/spack/repos/builtin/packages/cans/package.py @@ -27,6 +27,8 @@ class Cans(MakefilePackage): version("1.1.2", sha256="31c8d6c1f619fb60b7919922c7a3a64dd614a1a2f89f38560184f75ed0526171") version("1.1.0", sha256="e3fd84902e18715c6476fe780e2395ca04db9e6b0c830b55a7aa9204b1fd0886") + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("fftw") diff --git a/var/spack/repos/builtin/packages/cantera/package.py b/var/spack/repos/builtin/packages/cantera/package.py index efb9d7fcbe225d..94a8c4c1fbbd36 100644 --- a/var/spack/repos/builtin/packages/cantera/package.py +++ b/var/spack/repos/builtin/packages/cantera/package.py @@ -21,6 +21,10 @@ class Cantera(SConsPackage): version("2.3.0", sha256="06624f0f06bdd2acc9c0dba13443d945323ba40f68a9d422d95247c02e539b57") version("2.2.1", sha256="c7bca241848f541466f56e479402521c618410168e8983e2b54ae48888480e1e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("python", default=False, description="Build the Cantera Python module") variant("matlab", default=False, description="Build the Cantera Matlab toolbox") variant("sundials", default=True, description="Build with Sundials") @@ -134,13 +138,9 @@ def build_args(self, spec, prefix): # Python module if "+python" in spec: - args.extend( - ["python_package=full", "python_cmd={0}".format(spec["python"].command.path)] - ) + args.extend(["python_package=full", "python_cmd={0}".format(python.path)]) if spec["python"].satisfies("@3:"): - args.extend( - ["python3_package=y", "python3_cmd={0}".format(spec["python"].command.path)] - ) + args.extend(["python3_package=y", "python3_cmd={0}".format(python.path)]) else: args.append("python3_package=n") else: diff --git a/var/spack/repos/builtin/packages/canu/package.py b/var/spack/repos/builtin/packages/canu/package.py index 75094e70f0de8f..a6f18fcde7b477 100644 --- a/var/spack/repos/builtin/packages/canu/package.py +++ b/var/spack/repos/builtin/packages/canu/package.py @@ -26,6 +26,9 @@ class Canu(MakefilePackage): version("1.7", sha256="c5be54b0ad20729093413e7e722a19637d32e966dc8ecd2b579ba3e4958d378a") version("1.5", sha256="06e2c6d7b9f6d325b3b468e9c1a5de65e4689aed41154f2cee5ccd2cef0d5cf6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("git@2.12:", type="build", when="@2.2:") depends_on("gnuplot", type="run") depends_on("java", type="run") diff --git a/var/spack/repos/builtin/packages/capnproto/package.py b/var/spack/repos/builtin/packages/capnproto/package.py index 8552fbd9b4f5c5..f590f876c2d341 100644 --- a/var/spack/repos/builtin/packages/capnproto/package.py +++ b/var/spack/repos/builtin/packages/capnproto/package.py @@ -36,6 +36,8 @@ class Capnproto(AutotoolsPackage): version("0.5.1.1", sha256="caf308e92683b278bc6c568d4fb5558eca78180cac1eb4a3db15d435bf25116f") version("0.4.1.2", sha256="6376c1910e9bc9d09dc46d53b063c5bdcb5cdf066a8210e9fffe299fb863f0d9") + depends_on("cxx", type="build") # generated + depends_on("zlib-api", when="+zlib") depends_on("openssl", when="+tls") diff --git a/var/spack/repos/builtin/packages/capstone/package.py b/var/spack/repos/builtin/packages/capstone/package.py index 491a488edcf465..d64ea3d4712c4a 100644 --- a/var/spack/repos/builtin/packages/capstone/package.py +++ b/var/spack/repos/builtin/packages/capstone/package.py @@ -20,3 +20,9 @@ class Capstone(CMakePackage): version("5.0.1", sha256="2b9c66915923fdc42e0e32e2a9d7d83d3534a45bb235e163a70047951890c01a") version("4.0.2", sha256="7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a") version("4.0.1", sha256="79bbea8dbe466bd7d051e037db5961fdb34f67c9fac5c3471dd105cfb1e05dc7") + + depends_on("c", type="build") + depends_on("cxx", type="build") + + def cmake_args(self): + return ["-DCMAKE_POSITION_INDEPENDENT_CODE:BOOL=TRUE"] diff --git a/var/spack/repos/builtin/packages/cardioid/package.py b/var/spack/repos/builtin/packages/cardioid/package.py index f14aa1c9c4d55f..de91899e2b2b08 100644 --- a/var/spack/repos/builtin/packages/cardioid/package.py +++ b/var/spack/repos/builtin/packages/cardioid/package.py @@ -18,6 +18,10 @@ class Cardioid(CMakePackage): version("develop", branch="master") version("elecfem", branch="elec-fem") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("cuda", default=False, description="Build with cuda support") variant("mfem", default=False, description="Build with mfem support") diff --git a/var/spack/repos/builtin/packages/care/package.py b/var/spack/repos/builtin/packages/care/package.py index 01b11ed3ac0e97..68583088d6c6ea 100644 --- a/var/spack/repos/builtin/packages/care/package.py +++ b/var/spack/repos/builtin/packages/care/package.py @@ -17,8 +17,28 @@ class Care(CMakePackage, CudaPackage, ROCmPackage): license("GPL-2.0-or-later") + maintainers("adayton1") + version("develop", branch="develop", submodules="True") version("master", branch="main", submodules="True") + version( + "0.13.1", + tag="v0.13.1", + commit="0fd0d47aaaa57076f26caad88e667fbc01ff7214", + submodules="True", + ) + version( + "0.13.0", + tag="v0.13.0", + commit="2b288e2c557c3b14befeebc8e14a7d48348bd857", + submodules="True", + ) + version( + "0.12.0", + tag="v0.12.0", + commit="a9978083035eb00a090451bd36d7987bc935204d", + submodules="True", + ) version( "0.3.0", tag="v0.3.0", commit="5e2b69b2836c9f2215207ca9a36a690cb77eea33", submodules="True" ) @@ -26,6 +46,10 @@ class Care(CMakePackage, CudaPackage, ROCmPackage): "0.2.0", tag="v0.2.0", commit="30135e03b14b1dc753634e9147dafede0663906f", submodules="True" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=False, description="Build Shared Libs") variant( "implicit_conversions", @@ -38,22 +62,42 @@ class Care(CMakePackage, CudaPackage, ROCmPackage): variant("tests", default=False, description="Build tests") variant("loop_fuser", default=False, description="Enable loop fusion capability") + depends_on("cmake@3.8:", type="build") + depends_on("cmake@3.9:", type="build", when="+cuda") + depends_on("cmake@3.18:", type="build", when="@0.12.0:") + depends_on("cmake@3.21:", type="build", when="@0.12.0:+rocm") + + depends_on("blt") + depends_on("blt@0.6.2:", type="build", when="@0.13.0:") + depends_on("blt@0.6.1:", type="build", when="@0.12.0:") depends_on("blt@0.4.0:", type="build", when="@0.3.1:") depends_on("blt@:0.3.6", type="build", when="@:0.3.0") conflicts("^blt@:0.3.6", when="+rocm") - depends_on("camp") - depends_on("umpire@develop") - depends_on("raja@develop") - depends_on("chai@develop+enable_pick~benchmarks") + depends_on("camp", when="@:0.11.1") + + depends_on("umpire") + depends_on("umpire@2024.02.1:", when="@0.13.0:") + depends_on("umpire@2024.02.0:", when="@0.12.0:") + + depends_on("raja") + depends_on("raja@2024.02.2:", when="@0.13.1:") + depends_on("raja@2024.02.1:", when="@0.13.0:") + depends_on("raja@2024.02.0:", when="@0.12.0:") + depends_on("chai+enable_pick+raja") + depends_on("chai@2024.02.2:", when="@0.13.1:") + depends_on("chai@2024.02.1:", when="@0.13.0:") + depends_on("chai@2024.02.0:", when="@0.12.0:") + + # pass on +cuda variants # WARNING: this package currently only supports an internal cub # package. This will cause a race condition if compiled with another # package that uses cub. TODO: have all packages point to the same external # cub package. + depends_on("cub", when="+cuda") depends_on("camp+cuda", when="+cuda") depends_on("umpire+cuda~shared", when="+cuda") - depends_on("cub", when="+cuda") depends_on("raja+cuda~openmp", when="+cuda") depends_on("chai+cuda~shared", when="+cuda") diff --git a/var/spack/repos/builtin/packages/cargs/package.py b/var/spack/repos/builtin/packages/cargs/package.py index 504914b197c950..45a3a7a9f5426e 100644 --- a/var/spack/repos/builtin/packages/cargs/package.py +++ b/var/spack/repos/builtin/packages/cargs/package.py @@ -20,4 +20,6 @@ class Cargs(CMakePackage): version("1.1.0", sha256="87e7da5b539f574d48529870cb0620ef5a244a5ee2eac73cc7559dedc04128ca") version("1.0.3", sha256="ddba25bd35e9c6c75bc706c126001b8ce8e084d40ef37050e6aa6963e836eb8b") + depends_on("c", type="build") # generated + depends_on("cmake@3.14.7:", type=("build")) diff --git a/var/spack/repos/builtin/packages/casacore/package.py b/var/spack/repos/builtin/packages/casacore/package.py index 870146b258a69e..37bf1dc025d8d4 100644 --- a/var/spack/repos/builtin/packages/casacore/package.py +++ b/var/spack/repos/builtin/packages/casacore/package.py @@ -28,6 +28,10 @@ class Casacore(CMakePackage): version("3.0.0", sha256="6f0e68fd77b5c96299f7583a03a53a90980ec347bff9dfb4c0abb0e2933e6bcb") version("2.4.1", sha256="58eccc875053b2c6fe44fe53b6463030ef169597ec29926936f18d27b5087d63") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.7.1:", type="build") variant("adios2", default=False, description="Build ADIOS2 support") diff --git a/var/spack/repos/builtin/packages/casper/package.py b/var/spack/repos/builtin/packages/casper/package.py index ff4c4e7f129183..9d2bd90237cfd8 100644 --- a/var/spack/repos/builtin/packages/casper/package.py +++ b/var/spack/repos/builtin/packages/casper/package.py @@ -23,6 +23,8 @@ class Casper(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("jellyfish@2.2.3:") depends_on("boost+exception") diff --git a/var/spack/repos/builtin/packages/castep/package.py b/var/spack/repos/builtin/packages/castep/package.py new file mode 100644 index 00000000000000..66689fb48c32e8 --- /dev/null +++ b/var/spack/repos/builtin/packages/castep/package.py @@ -0,0 +1,95 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + + +class Castep(MakefilePackage): + """ + CASTEP is a leading code for calculating the + properties of materials from first principles. + Using density functional theory, it can simulate + a wide range of properties of materials + proprieties including energetics, structure at + the atomic level, vibrational properties, + electronic response properties etc. + """ + + homepage = "http://castep.org" + url = f"file://{os.getcwd()}/CASTEP-21.11.tar.gz" + manual_download = True + + version("21.11", sha256="d909936a51dd3dff7a0847c2597175b05c8d0018d5afe416737499408914728f") + version( + "19.1.1.rc2", sha256="1fce21dc604774e11b5194d5f30df8a0510afddc16daf3f8b9bbb3f62748f86a" + ) + + variant("mpi", default=True, description="Enable MPI build") + depends_on("rsync", type="build") + depends_on("blas") + depends_on("lapack") + depends_on("fftw-api") + depends_on("mpi", type=("build", "link", "run"), when="+mpi") + + parallel = True + + def edit(self, spec, prefix): + if spec.satisfies("%gcc"): + dlmakefile = FileFilter("LibSource/dl_mg-2.0.3/platforms/castep.inc") + dlmakefile.filter(r"MPIFLAGS = -DMPI", "MPIFLAGS = -fallow-argument-mismatch -DMPI") + if self.spec.satisfies("@20:"): + platfile = FileFilter("obj/platforms/linux_x86_64_gfortran.mk") + else: + platfile = FileFilter("obj/platforms/linux_x86_64_gfortran9.0.mk") + platfile.filter(r"^\s*OPT_CPU\s*=.*", "OPT_CPU = ") + platfile.filter(r"^\s*FFLAGS_E\s*=.*", "FFLAGS_E = -fallow-argument-mismatch ") + elif spec.satisfies("%intel"): + if self.spec.satisfies("@20:"): + platfile = FileFilter("obj/platforms/linux_x86_64_ifort.mk") + else: + platfile = FileFilter("obj/platforms/linux_x86_64_ifort19.mk") + platfile.filter(r"^\s*OPT_CPU\s*=.*", "OPT_CPU = ") + + @property + def build_targets(self): + spec = self.spec + targetlist = [f"PWD={self.stage.source_path}"] + + if "+mpi" in spec: + targetlist.append("COMMS_ARCH=mpi") + + targetlist.append(f"FFTLIBDIR={spec['fftw-api'].prefix.lib}") + targetlist.append(f"MATHLIBDIR={spec['blas'].prefix.lib}") + + if "^mkl" in spec: + targetlist.append("FFT=mkl") + if self.spec.satisfies("@20:"): + targetlist.append("MATHLIBS=mkl") + else: + targetlist.append("MATHLIBS=mkl10") + else: + targetlist.append("FFT=fftw3") + targetlist.append("MATHLIBS=openblas") + + if spec.satisfies("target=x86_64:"): + if spec.satisfies("platform=linux"): + if spec.satisfies("%gcc"): + if self.spec.satisfies("@20:"): + targetlist.append("ARCH=linux_x86_64_gfortran") + else: + targetlist.append("ARCH=linux_x86_64_gfortran9.0") + if spec.satisfies("%intel"): + if self.spec.satisfies("@20:"): + targetlist.append("ARCH=linux_x86_64_ifort") + else: + targetlist.append("ARCH=linux_x86_64_ifort19") + + return targetlist + + def install(self, spec, prefix): + mkdirp(prefix.bin) + make("install", "install-tools", *self.build_targets, "INSTALL_DIR={0}".format(prefix.bin)) diff --git a/var/spack/repos/builtin/packages/catch2/package.py b/var/spack/repos/builtin/packages/catch2/package.py index 9ec5e961b2ec5a..7645a2fd9af2fd 100644 --- a/var/spack/repos/builtin/packages/catch2/package.py +++ b/var/spack/repos/builtin/packages/catch2/package.py @@ -108,6 +108,8 @@ class Catch2(CMakePackage): version("1.3.5", sha256="f15730d81b4173fb860ce3561768de7d41bbefb67dc031d7d1f5ae2c07f0a472") version("1.3.0", sha256="245f6ee73e2fea66311afa1da59e5087ddab8b37ce64994ad88506e8af28c6ac") + depends_on("cxx", type="build") # generated + variant( "cxxstd", when="@3:", diff --git a/var/spack/repos/builtin/packages/cbc/package.py b/var/spack/repos/builtin/packages/cbc/package.py index ee4685c8bf788f..79c1e48fcd0b68 100644 --- a/var/spack/repos/builtin/packages/cbc/package.py +++ b/var/spack/repos/builtin/packages/cbc/package.py @@ -21,6 +21,9 @@ class Cbc(AutotoolsPackage): version("2.10.8", sha256="8525abb541ee1b8e6ff03b00411b66e98bbc58f95be1aefd49d2bca571be2eaf") version("2.10.5", sha256="cc44c1950ff4615e7791d7e03ea34318ca001d3cac6dc3f7f5ee392459ce6719") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("coinutils") depends_on("osi") depends_on("cgl") diff --git a/var/spack/repos/builtin/packages/cbench/package.py b/var/spack/repos/builtin/packages/cbench/package.py index 609e5bba5416ad..ad598b6bb7a318 100644 --- a/var/spack/repos/builtin/packages/cbench/package.py +++ b/var/spack/repos/builtin/packages/cbench/package.py @@ -19,6 +19,10 @@ class Cbench(MakefilePackage): version("1.3.0", sha256="b40fdafd14869b86819e5906a107b0735290a1e58bae229d8166514a72f58732") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("blas") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/cbflib/package.py b/var/spack/repos/builtin/packages/cbflib/package.py index 7e313acece0698..d883fdcd5eeef8 100644 --- a/var/spack/repos/builtin/packages/cbflib/package.py +++ b/var/spack/repos/builtin/packages/cbflib/package.py @@ -22,6 +22,10 @@ class Cbflib(MakefilePackage): version("0.9.2", sha256="367e37e1908a65d5472e921150291332823a751206804866e752b793bca17afc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("m4", type="build") patch("cbf_f16.patch") diff --git a/var/spack/repos/builtin/packages/cblas/package.py b/var/spack/repos/builtin/packages/cblas/package.py index 86b50b7c5e2fe9..d3d563453550ef 100644 --- a/var/spack/repos/builtin/packages/cblas/package.py +++ b/var/spack/repos/builtin/packages/cblas/package.py @@ -20,6 +20,9 @@ class Cblas(Package): url="https://www.netlib.org/blas/blast-forum/cblas.tgz", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("blas") parallel = False diff --git a/var/spack/repos/builtin/packages/cbtf-argonavis-gui/package.py b/var/spack/repos/builtin/packages/cbtf-argonavis-gui/package.py index 36549c6063000f..841a61e0fe5ae8 100644 --- a/var/spack/repos/builtin/packages/cbtf-argonavis-gui/package.py +++ b/var/spack/repos/builtin/packages/cbtf-argonavis-gui/package.py @@ -22,6 +22,8 @@ class CbtfArgonavisGui(QMakePackage): version("develop", branch="master") version("1.3.0.0", branch="1.3.0.0") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.0.2:", type="build") depends_on("qt@5.10.0:") diff --git a/var/spack/repos/builtin/packages/cbtf-argonavis/package.py b/var/spack/repos/builtin/packages/cbtf-argonavis/package.py index 96b3679b18bc8a..a4d1ae654344be 100644 --- a/var/spack/repos/builtin/packages/cbtf-argonavis/package.py +++ b/var/spack/repos/builtin/packages/cbtf-argonavis/package.py @@ -22,6 +22,9 @@ class CbtfArgonavis(CMakePackage): version("1.9.4", branch="1.9.4") version("1.9.3", branch="1.9.3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "crayfe", default=False, diff --git a/var/spack/repos/builtin/packages/cbtf-krell/package.py b/var/spack/repos/builtin/packages/cbtf-krell/package.py index 3196840a934d54..4c731a1e8d51f8 100644 --- a/var/spack/repos/builtin/packages/cbtf-krell/package.py +++ b/var/spack/repos/builtin/packages/cbtf-krell/package.py @@ -25,6 +25,9 @@ class CbtfKrell(CMakePackage): version("1.9.4", branch="1.9.4") version("1.9.3", branch="1.9.3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # MPI variants variant( "openmpi", default=False, description="Build mpi experiment collector for openmpi MPI.." diff --git a/var/spack/repos/builtin/packages/cbtf-lanl/package.py b/var/spack/repos/builtin/packages/cbtf-lanl/package.py index 371c1dd63889b6..69882e9b2a90f6 100644 --- a/var/spack/repos/builtin/packages/cbtf-lanl/package.py +++ b/var/spack/repos/builtin/packages/cbtf-lanl/package.py @@ -20,6 +20,8 @@ class CbtfLanl(CMakePackage): version("1.9.4", branch="1.9.4") version("1.9.3", branch="1.9.3") + depends_on("cxx", type="build") # generated + variant( "build_type", default="RelWithDebInfo", diff --git a/var/spack/repos/builtin/packages/cbtf/package.py b/var/spack/repos/builtin/packages/cbtf/package.py index 92166c5286e8eb..dcd00bb0f9f392 100644 --- a/var/spack/repos/builtin/packages/cbtf/package.py +++ b/var/spack/repos/builtin/packages/cbtf/package.py @@ -27,6 +27,8 @@ class Cbtf(CMakePackage): version("1.9.4", branch="1.9.4") version("1.9.3", branch="1.9.3") + depends_on("cxx", type="build") # generated + variant( "runtime", default=False, description="build only the runtime libraries and collectors." ) diff --git a/var/spack/repos/builtin/packages/cc65/package.py b/var/spack/repos/builtin/packages/cc65/package.py index 1f4998ed545742..cebbf6a3d4f399 100644 --- a/var/spack/repos/builtin/packages/cc65/package.py +++ b/var/spack/repos/builtin/packages/cc65/package.py @@ -22,5 +22,7 @@ class Cc65(MakefilePackage): version("2.15", sha256="adeac1a4b04183dd77fba1d69e56bbf4a6d358e0b253ee43ef4cac2391ba848a") version("2.14", sha256="128bda63490eb43ad25fd3615adee4c819c0b7da4b9b8f1801df36bd19e3bdf8") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make("PREFIX={0}".format(prefix), "install") diff --git a/var/spack/repos/builtin/packages/ccache/package.py b/var/spack/repos/builtin/packages/ccache/package.py index c785ca663c0cda..5566e348c6540a 100644 --- a/var/spack/repos/builtin/packages/ccache/package.py +++ b/var/spack/repos/builtin/packages/ccache/package.py @@ -23,6 +23,8 @@ class Ccache(CMakePackage): license("GPL-3.0-or-later") + version("4.9.1", sha256="12834ecaaaf2db069dda1d1d991f91c19e3274cc04a471af5b64195def17e90f") + version("4.8.3", sha256="d59dd569ad2bbc826c0bc335c8ebd73e78ed0f2f40ba6b30069347e63585d9ef") version("4.8.2", sha256="75eef15b8b9da48db9c91e1d0ff58b3645fc70c0e4ca2ef1b6825a12f21f217d") version("4.8.1", sha256="869903c1891beb8bee87f1ec94d8a0dad18c2add4072c456acbc85cdfc23ca63") version("4.8", sha256="ac4b01748fd59cfe07e070c34432b91bdd0fd8640e1e653a80b01d6a523186b0") @@ -54,6 +56,9 @@ class Ccache(CMakePackage): version("3.3", sha256="b220fce435fe3d86b8b90097e986a17f6c1f971e0841283dd816adb238c5fd6a") version("3.2.9", sha256="1e13961b83a3d215c4013469c149414a79312a22d3c7bf9f946abac9ee33e63f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("redis", default=True, description="Enable Redis secondary storage") depends_on("cmake@3.15:", when="@4.7:", type="build") @@ -74,7 +79,7 @@ class Ccache(CMakePackage): conflicts("%clang@:7", when="@4.7:") conflicts("%clang@:4", when="@4.4:") - patch("fix-gcc-12.patch", when="%gcc@12") + patch("fix-gcc-12.patch", when="@4.8:4.8.2 %gcc@12") def cmake_args(self): return [ diff --git a/var/spack/repos/builtin/packages/cce/detection_test.yaml b/var/spack/repos/builtin/packages/cce/detection_test.yaml new file mode 100644 index 00000000000000..b425ab439a6bd3 --- /dev/null +++ b/var/spack/repos/builtin/packages/cce/detection_test.yaml @@ -0,0 +1,44 @@ +paths: +- layout: + - executables: + - "bin/craycc" + script: | + echo "Cray C : Version 8.4.6 Mon Apr 15, 2019 12:13:39" + - executables: + - "bin/crayCC" + script: | + echo "Cray C++ : Version 8.4.6 Mon Apr 15, 2019 12:13:39" + - executables: + - "bin/crayftn" + script: | + echo "Cray Fortran : Version 8.4.6 Mon Apr 15, 2019 12:13:39" + platforms: [linux] + results: + - spec: cce@8.4.6 + extra_attributes: + compilers: + c: ".*/bin/craycc" + cxx: ".*/bin/crayCC" + fortran: ".*/bin/crayftn" +- layout: + - executables: + - "bin/craycc" + - "bin/crayCC" + script: | + echo "Cray clang version 17.0.1 (5ec9405551a8c8845cf14e81dc28bff7aa3935cb)" + echo "Target: x86_64-unknown-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /opt/cray/pe/cce/17.0.1/cce-clang/x86_64/share/../bin" + echo "Configuration file: /opt/cray/pe/cce/17.0.1/cce-clang/x86_64/bin/clang.cfg" + - executables: + - "bin/crayftn" + script: | + echo "Cray Fortran : Version 17.0.1" + platforms: [linux] + results: + - spec: cce@17.0.1 + extra_attributes: + compilers: + c: ".*/bin/craycc" + cxx: ".*/bin/crayCC" + fortran: ".*/bin/crayftn" diff --git a/var/spack/repos/builtin/packages/cce/package.py b/var/spack/repos/builtin/packages/cce/package.py new file mode 100644 index 00000000000000..0772be6ab1d82e --- /dev/null +++ b/var/spack/repos/builtin/packages/cce/package.py @@ -0,0 +1,30 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class Cce(Package, CompilerPackage): + """Stub package for external detection of the Cray compiler package.""" + + homepage = "https://cpe.ext.hpe.com/docs/cce/index.html" + url = "https://cpe.ext.hpe.com/docs/cce/index.html" + + compiler_languages = ["c", "cxx", "fortran"] + c_names = ["craycc"] + cxx_names = ["crayCC"] + fortran_names = ["crayftn"] + + compiler_version_argument = "--version" + compiler_version_regex = ( + r"[Cc]ray (?:clang|C :|C\+\+ :|Fortran :) [Vv]ersion.*?(\d+(?:\.\d+)+)" + ) + + # notify when the package is updated. + maintainers("becker33") + + version("16.0.0") + + def install(self, spec, prefix): + raise NotImplementedError("cray compiler must be configured as external") diff --git a/var/spack/repos/builtin/packages/ccfits/package.py b/var/spack/repos/builtin/packages/ccfits/package.py index 1b2a98f8686680..13e2701a69c86e 100644 --- a/var/spack/repos/builtin/packages/ccfits/package.py +++ b/var/spack/repos/builtin/packages/ccfits/package.py @@ -20,4 +20,6 @@ class Ccfits(AutotoolsPackage): version("2.5", sha256="938ecd25239e65f519b8d2b50702416edc723de5f0a5387cceea8c4004a44740") version("2.4", sha256="ba6c5012b260adf7633f92581279ea582e331343d8c973981aa7de07242bd7f8") + depends_on("cxx", type="build") # generated + depends_on("cfitsio") diff --git a/var/spack/repos/builtin/packages/ccls/package.py b/var/spack/repos/builtin/packages/ccls/package.py index 08f5a5059ad05c..7d05aa4e808b2c 100644 --- a/var/spack/repos/builtin/packages/ccls/package.py +++ b/var/spack/repos/builtin/packages/ccls/package.py @@ -17,6 +17,12 @@ class Ccls(CMakePackage): license("Apache-2.0") + version( + "0.20240202", sha256="355ff7f5eb5f24d278dda05cccd9157e89583272d0559d6b382630171f142d86" + ) + version( + "0.20230717", sha256="118e84cc17172b1deef0f9c50767b7a2015198fd44adac7966614eb399867af8" + ) version( "0.20220729", sha256="af19be36597c2a38b526ce7138c72a64c7fb63827830c4cff92256151fc7a6f4" ) @@ -27,6 +33,8 @@ class Ccls(CMakePackage): "0.20201025", sha256="1470797b2c1a466e2d8a069efd807aac6fefdef8a556e1edf2d44f370c949221" ) + depends_on("cxx", type="build") # generated + depends_on("cmake@3.8:", type="build") depends_on("llvm@7:") depends_on("rapidjson") diff --git a/var/spack/repos/builtin/packages/ccs-qcd/package.py b/var/spack/repos/builtin/packages/ccs-qcd/package.py index bd404445ccd823..1c437a63594b7b 100644 --- a/var/spack/repos/builtin/packages/ccs-qcd/package.py +++ b/var/spack/repos/builtin/packages/ccs-qcd/package.py @@ -40,6 +40,10 @@ class CcsQcd(MakefilePackage): version("master", branch="master") version("1.2.1", commit="d7c6b6923f35a824e997ba8db5bd12dc20dda45c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "class", default=1, diff --git a/var/spack/repos/builtin/packages/cctools/package.py b/var/spack/repos/builtin/packages/cctools/package.py index d3244d76b61fca..85f35f7b8c6906 100644 --- a/var/spack/repos/builtin/packages/cctools/package.py +++ b/var/spack/repos/builtin/packages/cctools/package.py @@ -32,6 +32,9 @@ class Cctools(AutotoolsPackage): version("7.0.18", sha256="5b6f3c87ae68dd247534a5c073eb68cb1a60176a7f04d82699fbc05e649a91c2") version("6.1.1", sha256="97f073350c970d6157f80891b3bf6d4f3eedb5f031fea386dc33e22f22b8af9d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("openssl") depends_on("perl+shared", type=("build", "run")) depends_on("python", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/cdbfasta/package.py b/var/spack/repos/builtin/packages/cdbfasta/package.py index 24ab2790e6723b..bb4fb47a1f5b05 100644 --- a/var/spack/repos/builtin/packages/cdbfasta/package.py +++ b/var/spack/repos/builtin/packages/cdbfasta/package.py @@ -16,6 +16,8 @@ class Cdbfasta(MakefilePackage): version("2017-03-16", commit="b3e481fe02dfbc767a3842bcb1b687c60376a5e8") + depends_on("cxx", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/cdd/package.py b/var/spack/repos/builtin/packages/cdd/package.py index 8a1940261f56ed..e061ceff6b8aa1 100644 --- a/var/spack/repos/builtin/packages/cdd/package.py +++ b/var/spack/repos/builtin/packages/cdd/package.py @@ -21,6 +21,8 @@ class Cdd(Package): version("0.61a", sha256="637a1909bbd8aa4d32667da08f9e9ac687bf7d3ef1b8af5bd227e91a3cd4019b") + depends_on("c", type="build") # generated + depends_on("libtool", type="build") patch("Makefile.spack.patch") @@ -31,6 +33,6 @@ def url_for_version(self, version): def install(self, spec, prefix): # The Makefile isn't portable; use our own instead - makeargs = ["-f", "Makefile.spack", "PREFIX=%s" % prefix] + makeargs = ["-f", "Makefile.spack", f"PREFIX={prefix}"] make(*makeargs) make("install", *makeargs) diff --git a/var/spack/repos/builtin/packages/cddlib/package.py b/var/spack/repos/builtin/packages/cddlib/package.py index fbf3e0b33b141c..ef8cdb560f49ef 100644 --- a/var/spack/repos/builtin/packages/cddlib/package.py +++ b/var/spack/repos/builtin/packages/cddlib/package.py @@ -22,6 +22,8 @@ class Cddlib(AutotoolsPackage): version("0.94m", sha256="70dffdb3369b8704dc75428a1b3c42ab9047b81ce039f12f427e2eb2b1b0dee2") version("0.94h", sha256="7382782c3834214b022c8b2898ed775a7bf915f2cb2acb73fa045d6fd9a3de33") + depends_on("c", type="build") # generated + depends_on("gmp", when="@0.94h") def url_for_version(self, version): diff --git a/var/spack/repos/builtin/packages/cdecimal/package.py b/var/spack/repos/builtin/packages/cdecimal/package.py index a725b726ca0881..a02ec04244c5c4 100644 --- a/var/spack/repos/builtin/packages/cdecimal/package.py +++ b/var/spack/repos/builtin/packages/cdecimal/package.py @@ -17,4 +17,6 @@ class Cdecimal(AutotoolsPackage): version("2.3", sha256="d737cbe43ed1f6ad9874fb86c3db1e9bbe20c0c750868fde5be3f379ade83d8b") + depends_on("c", type="build") # generated + patch("darwin_install_name.patch", when="platform=darwin") diff --git a/var/spack/repos/builtin/packages/cdhit/package.py b/var/spack/repos/builtin/packages/cdhit/package.py index 1d6bdf304b5668..15923d966fabe0 100644 --- a/var/spack/repos/builtin/packages/cdhit/package.py +++ b/var/spack/repos/builtin/packages/cdhit/package.py @@ -20,6 +20,8 @@ class Cdhit(MakefilePackage): version("4.8.1", sha256="f8bc3cdd7aebb432fcd35eed0093e7a6413f1e36bbd2a837ebc06e57cdb20b70") version("4.6.8", sha256="37d685e4aa849314401805fe4d4db707e1d06070368475e313d6f3cb8fb65949") + depends_on("cxx", type="build") # generated + maintainers("snehring") variant("openmp", default=True, description="Compile with multi-threading support") diff --git a/var/spack/repos/builtin/packages/cdo/package.py b/var/spack/repos/builtin/packages/cdo/package.py index 929eaaebfc6379..af1b14fc4814b1 100644 --- a/var/spack/repos/builtin/packages/cdo/package.py +++ b/var/spack/repos/builtin/packages/cdo/package.py @@ -151,6 +151,10 @@ class Cdo(AutotoolsPackage): url="https://code.mpimet.mpg.de/attachments/download/12760/cdo-1.7.2.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("netcdf", default=True, description="Enable NetCDF support") variant( "grib2", diff --git a/var/spack/repos/builtin/packages/cdt/package.py b/var/spack/repos/builtin/packages/cdt/package.py index 4e73a052863391..01730fdcda5d69 100644 --- a/var/spack/repos/builtin/packages/cdt/package.py +++ b/var/spack/repos/builtin/packages/cdt/package.py @@ -16,10 +16,13 @@ class Cdt(CMakePackage): license("MPL-2.0-no-copyleft-exception") + version("1.4.1", sha256="86df99eb5f02a73eeb8c6ea45765eed0d7f206e8d4d9f6479f77e3c590ae5bb3") version("1.4.0", sha256="cb5a95a39b417f5a4d170c7ebe97232d0ed36ea64069339b14964dd52dea95ab") version("1.3.6", sha256="15881e4c451f3b7cceade9b11884b3813ff674dff3edae4fb7c440634f8d4c33") version("1.3.0", sha256="7e8feadf9534cf79f9bf188365510fd6bc68ea997758e1c68d1569f98da924da") + depends_on("cxx", type="build") # generated + variant( "boost", default=False, diff --git a/var/spack/repos/builtin/packages/celeritas/package.py b/var/spack/repos/builtin/packages/celeritas/package.py index 13822afb6a6692..729be79cd28bb9 100644 --- a/var/spack/repos/builtin/packages/celeritas/package.py +++ b/var/spack/repos/builtin/packages/celeritas/package.py @@ -19,6 +19,8 @@ class Celeritas(CMakePackage, CudaPackage, ROCmPackage): license("Apache-2.0") + version("0.4.4", sha256="8b5ae63aa2d50c2ecf48d752424e4a33c50c07d9f0f5ca5448246de3286fd836") + version("0.4.3", sha256="b4f603dce1dc9c4894ea4c86f6574026ea8536714982e7dc6dff7472c925c892") version("0.4.2", sha256="eeca9705413f5e16e0fb81154e042600c8df125af7049912757feb01d43730e2") version("0.4.1", sha256="24e5c15eb9eec45f52d94a6719ae3505388b49d409cb7e26c875c70ac409bd2c") version( @@ -75,6 +77,8 @@ class Celeritas(CMakePackage, CudaPackage, ROCmPackage): deprecated=True, ) + depends_on("cxx", type="build") + _cxxstd_values = ("14", "17") # Note: cuda and rocm variants are defined by mixin classes diff --git a/var/spack/repos/builtin/packages/cellranger/package.py b/var/spack/repos/builtin/packages/cellranger/package.py new file mode 100644 index 00000000000000..31dded75e8d4f8 --- /dev/null +++ b/var/spack/repos/builtin/packages/cellranger/package.py @@ -0,0 +1,38 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + + +class Cellranger(Package): + """Cellranger is a set of analysis pipelines that process Chromium single cell data to + align reads, generate feature-barcode matrices, perform clustering and other secondary + analysis, and more. + + This package requires the user to accept a license and to download the tarball manually. + Once downloaded, the file should be placed within a manual mirror or within the current + directory. For instructions on making a manual mirror, see + https://spack.readthedocs.io/en/latest/mirrors.html""" + + homepage = "https://www.10xgenomics.com/support/software/cell-ranger/latest" + manual_download = True + license_url = "support.10xgenomics.com/license" + + version("7.2.0", sha256="b092bd4e3ab585ad051a231fbdd8f3f0f5cbcd10f657eeab86bec98cd594502c") + version("7.1.0", sha256="5c4f9b142e3c30ad10ae15d25868df2b4fd05bdb3bbd47da0c83a7cc649b577e") + + # cellranger is distributed as precompiled binaries that are not compatible with + # processors without the avx instruction set ... + conflicts("target=:k10") # last AMD processor not to support avx + conflicts("target=:westmere") # last Intel processor not to support avx + conflicts("target=:x86_64_v2") # last generic architecture not to support avx + + def url_for_version(self, version): + return "file://{0}/cellranger-{1}.tar.gz".format(os.getcwd(), version) + + def install(self, spec, prefix): + install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/centrifuge/package.py b/var/spack/repos/builtin/packages/centrifuge/package.py index 2b1cf86d3a850b..ce7fea5f4a1fb7 100644 --- a/var/spack/repos/builtin/packages/centrifuge/package.py +++ b/var/spack/repos/builtin/packages/centrifuge/package.py @@ -12,8 +12,11 @@ class Centrifuge(MakefilePackage): homepage = "https://ccb.jhu.edu/software/centrifuge/index.shtml" url = "https://github.com/DaehwanKimLab/centrifuge/archive/refs/tags/v1.0.4.tar.gz" + version("1.0.4.1", sha256="638cc6701688bfdf81173d65fa95332139e11b215b2d25c030f8ae873c34e5cc") version("1.0.4", sha256="929daed0f84739f7636cc1ea2757527e83373f107107ffeb5937a403ba5201bc") + depends_on("cxx", type="build") # generated + def build(self, spec, prefix): make() diff --git a/var/spack/repos/builtin/packages/cepgen/package.py b/var/spack/repos/builtin/packages/cepgen/package.py index c6a79f3fcb4377..061cfab7e556cb 100644 --- a/var/spack/repos/builtin/packages/cepgen/package.py +++ b/var/spack/repos/builtin/packages/cepgen/package.py @@ -21,6 +21,9 @@ class Cepgen(CMakePackage): "1.0.2patch1", sha256="333bba0cb1965a98dec127e00c150eab1a515cd348a90f7b1d66d5cd8d206d21" ) + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + generator("ninja") depends_on("cmake@3.5:", type="build", when="@1.0:") diff --git a/var/spack/repos/builtin/packages/cereal/package.py b/var/spack/repos/builtin/packages/cereal/package.py index d7a5cc9aa17c30..a53ddb79cedb0b 100644 --- a/var/spack/repos/builtin/packages/cereal/package.py +++ b/var/spack/repos/builtin/packages/cereal/package.py @@ -33,6 +33,8 @@ class Cereal(CMakePackage): version("1.0.0", sha256="51c31c84d4c9e410e56d8bfc3424076b3234f11aa349ac8cda3db9f18118c125") version("0.9.1", sha256="2a99722df9c3d0f75267f732808a4d7e564cb5a35318a3d1c00086e2ef139385") + depends_on("cxx", type="build") # generated + patch("Boost.patch", when="@:1.3.0") patch("Boost2.patch", when="@1.2.2:1.3.0") patch("pointers.patch") diff --git a/var/spack/repos/builtin/packages/ceres-solver/package.py b/var/spack/repos/builtin/packages/ceres-solver/package.py index 5a8ac5db62d000..b70deaab6afd75 100644 --- a/var/spack/repos/builtin/packages/ceres-solver/package.py +++ b/var/spack/repos/builtin/packages/ceres-solver/package.py @@ -24,6 +24,9 @@ class CeresSolver(CMakePackage): version("1.14.0", sha256="4744005fc3b902fed886ea418df70690caa8e2ff6b5a90f3dd88a3d291ef8e8e") version("1.12.0", sha256="745bfed55111e086954126b748eb9efe20e30be5b825c6dec3c525cf20afc895") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("suitesparse", default=False, description="Build with SuiteSparse") variant("shared", default=True, description="Build shared libraries") variant("examples", default=False, description="Build examples") diff --git a/var/spack/repos/builtin/packages/cernlib/package.py b/var/spack/repos/builtin/packages/cernlib/package.py index 8e69d753c762f9..8e7b812929d201 100644 --- a/var/spack/repos/builtin/packages/cernlib/package.py +++ b/var/spack/repos/builtin/packages/cernlib/package.py @@ -11,14 +11,21 @@ class Cernlib(CMakePackage): """CERN Library""" homepage = "https://cernlib.web.cern.ch" - url = "https://cernlib.web.cern.ch/cernlib/download/2022_source/tar/cernlib-2022.11.08.0-free.tar.gz" + url = "https://cernlib.web.cern.ch/download/2023_source/tar/cernlib-2023.08.14.0-free.tar.gz" maintainers("andriish") - version( "2022.11.08.0-free", sha256="733d148415ef78012ff81f21922d3bf641be7514b0242348dd0200cf1b003e46", ) + version( + "2023.08.14.0-free", + sha256="7006475d9c38254cb94ce75e556a319fea3b3155087780ea522003103771474e", + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant("shared", default=True, description="Build shared libraries") @@ -30,11 +37,17 @@ class Cernlib(CMakePackage): depends_on("libxt") depends_on("libxcrypt") + depends_on("xbae", when="@2023:") + depends_on("openssl", when="platform=linux") - @when("@2022.11.08.0-free") def patch(self): - filter_file("crypto", "crypt", "packlib/CMakeLists.txt") + if self.spec.satisfies("@:2023.08.14.0-free"): + filter_file("crypto", "crypt", "packlib/CMakeLists.txt") + if self.spec.satisfies("@2023.08.14.0-free"): + filter_file( + r"\${MOTIF_LIBRARIES} \${Xbae}", "${Xbae} ${MOTIF_LIBRARIES}", "CMakeLists.txt" + ) def cmake_args(self): args = [self.define_from_variant("CERNLIB_BUILD_SHARED", "shared")] diff --git a/var/spack/repos/builtin/packages/cfitsio/package.py b/var/spack/repos/builtin/packages/cfitsio/package.py index e8d89e46ae7cbf..46422d4be02492 100644 --- a/var/spack/repos/builtin/packages/cfitsio/package.py +++ b/var/spack/repos/builtin/packages/cfitsio/package.py @@ -16,6 +16,7 @@ class Cfitsio(AutotoolsPackage): license("custom") + version("4.4.0", sha256="95900cf95ae760839e7cb9678a7b2fad0858d6ac12234f934bd1cb6bfc246ba9") version("4.3.0", sha256="fdadc01d09cf9f54253802c5ec87eb10de51ce4130411415ae88c30940621b8b") version("4.2.0", sha256="eba53d1b3f6e345632bb09a7b752ec7ced3d63ec5153a848380f3880c5d61889") version("4.1.0", sha256="b367c695d2831958e7166921c3b356d5dfa51b1ecee505b97416ba39d1b6c17a") @@ -28,6 +29,9 @@ class Cfitsio(AutotoolsPackage): version("3.41", sha256="a556ac7ea1965545dcb4d41cfef8e4915eeb8c0faa1b52f7ff70870f8bb5734c") version("3.37", sha256="092897c6dae4dfe42d91d35a738e45e8236aa3d8f9b3ffc7f0e6545b8319c63a") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("bzip2", default=True, description="Enable bzip2 support") variant("shared", default=True, description="Build shared libraries") @@ -45,7 +49,7 @@ def configure_args(self): spec = self.spec extra_args = [] if "+bzip2" in spec: - extra_args.append("--with-bzip2=%s" % spec["bzip2"].prefix), + extra_args.append(f"--with-bzip2={spec['bzip2'].prefix}"), return extra_args @property diff --git a/var/spack/repos/builtin/packages/cgal/package.py b/var/spack/repos/builtin/packages/cgal/package.py index dccceb27322d5e..daa2a48f06dfdd 100644 --- a/var/spack/repos/builtin/packages/cgal/package.py +++ b/var/spack/repos/builtin/packages/cgal/package.py @@ -33,6 +33,8 @@ class Cgal(CMakePackage): version("4.7", sha256="50bd0a1cad7a8957b09012f831eebaf7d670e2a3467e8f365ec0c71fa5436369") version("4.6.3", sha256="e338027b8767c0a7a6e4fd8679182d1b83b5b1a0da0a1fe4546e7c0ca094fc21") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") variant( "build_type", diff --git a/var/spack/repos/builtin/packages/cgdb/package.py b/var/spack/repos/builtin/packages/cgdb/package.py index 73a8ff07eaf68e..0118b6d6ec6543 100644 --- a/var/spack/repos/builtin/packages/cgdb/package.py +++ b/var/spack/repos/builtin/packages/cgdb/package.py @@ -20,6 +20,9 @@ class Cgdb(AutotoolsPackage): version("0.7.1", sha256="bb723be58ec68cb59a598b8e24a31d10ef31e0e9c277a4de07b2f457fe7de198") version("0.7.0", sha256="bf7a9264668db3f9342591b08b2cc3bbb08e235ba2372877b4650b70c6fb5423") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Required dependency depends_on("gdb", type="run") depends_on("ncurses") diff --git a/var/spack/repos/builtin/packages/cgdcbxd/package.py b/var/spack/repos/builtin/packages/cgdcbxd/package.py index c372afeed1b8f9..e86d1e3bdb874c 100644 --- a/var/spack/repos/builtin/packages/cgdcbxd/package.py +++ b/var/spack/repos/builtin/packages/cgdcbxd/package.py @@ -19,6 +19,8 @@ class Cgdcbxd(AutotoolsPackage): version("1.0.2", sha256="ef626c60e27005d3cae1e19a60d0133be0d1f0a012b695f7f1f6ad5a2afa4166") version("1.0.1", sha256="663b87a5ab4a760e2446e479fec36f6300d53e6113af1408efc156325219900c") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/cgl/package.py b/var/spack/repos/builtin/packages/cgl/package.py index 4aa3e02be2c6c4..5e417aa77a9a9d 100644 --- a/var/spack/repos/builtin/packages/cgl/package.py +++ b/var/spack/repos/builtin/packages/cgl/package.py @@ -24,6 +24,8 @@ class Cgl(AutotoolsPackage): version("0.60.6", sha256="9e2c51ffad816ab408763d6b931e2a3060482ee4bf1983148969de96d4b2c9ce") version("0.60.3", sha256="cfeeedd68feab7c0ce377eb9c7b61715120478f12c4dd0064b05ad640e20f3fb") + depends_on("cxx", type="build") # generated + depends_on("coinutils") depends_on("osi") depends_on("clp") diff --git a/var/spack/repos/builtin/packages/cgm/package.py b/var/spack/repos/builtin/packages/cgm/package.py index 88d9335db698bb..1d81247db3e985 100644 --- a/var/spack/repos/builtin/packages/cgm/package.py +++ b/var/spack/repos/builtin/packages/cgm/package.py @@ -19,6 +19,8 @@ class Cgm(AutotoolsPackage): version("13.1.0", sha256="c81bead4b919bd0cea9dbc61b219e316718d940bd3dc70825c58efbf0a0acdc3") version("13.1", sha256="985aa6c5db4257999af6f2bdfcb24f2bce74191cdcd98e937700db7fd9f6b549") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="enable mpi support") variant("oce", default=False, description="enable oce geometry kernel") variant("debug", default=False, description="enable debug symbols") diff --git a/var/spack/repos/builtin/packages/cgns/gcc14.patch b/var/spack/repos/builtin/packages/cgns/gcc14.patch new file mode 100644 index 00000000000000..62f9bd2e1f7d63 --- /dev/null +++ b/var/spack/repos/builtin/packages/cgns/gcc14.patch @@ -0,0 +1,50 @@ +From: Mickael Philit +Date: Sun, 3 Mar 2024 20:54:39 +0100 +Subject: [PATCH] backport gcc14 fedora patch + +--- + src/cgnstools/tkogl/gencyl.c | 4 ++-- + src/cgnstools/tkogl/tkogl.c | 8 +++++++- + 2 files changed, 9 insertions(+), 3 deletions(-) + +diff --git a/src/cgnstools/tkogl/gencyl.c b/src/cgnstools/tkogl/gencyl.c +index cc36c4ba6..b64d777f4 100644 +--- a/src/cgnstools/tkogl/gencyl.c ++++ b/src/cgnstools/tkogl/gencyl.c +@@ -682,8 +682,8 @@ RenderModel (Model* model) + Vector normal; + GLdouble v [3]; + obj = gluNewTess(); +- gluTessCallback(obj, GLU_BEGIN, glBegin); +- gluTessCallback(obj, GLU_VERTEX, glVertex3fv); ++ gluTessCallback(obj, GLU_BEGIN, (_GLUfuncptr)glBegin); ++ gluTessCallback(obj, GLU_VERTEX, (_GLUfuncptr)glVertex3fv); + gluTessCallback(obj, GLU_END, glEnd); + if (flags&CLOSE_FIRST) { + CrossSection *a = model->cross [0]; +diff --git a/src/cgnstools/tkogl/tkogl.c b/src/cgnstools/tkogl/tkogl.c +index e697e735e..506599d54 100644 +--- a/src/cgnstools/tkogl/tkogl.c ++++ b/src/cgnstools/tkogl/tkogl.c +@@ -22,6 +22,12 @@ + #include "printstr.h" + #include "feedback.h" + ++#if ! defined(__WIN32__) && ! defined(_WIN32) ++/* For TkWmAddToColormapWindows. */ ++#define _TKPORT /* Typical installations cannot find tkPort.h. */ ++#include ++#endif ++ + #ifndef CONST + # define CONST + #endif +@@ -599,7 +605,7 @@ OGLwinCmd(clientData, interp, argc, argv) + + if ((Tk_Parent(tkwin) != NULL) && + (Tk_Colormap(tkwin) != Tk_Colormap (Tk_Parent(tkwin)))) { +- TkWmAddToColormapWindows(tkwin); ++ TkWmAddToColormapWindows((TkWindow *)tkwin); + } + + /* See if this window will share display lists with another */ diff --git a/var/spack/repos/builtin/packages/cgns/package.py b/var/spack/repos/builtin/packages/cgns/package.py index 4ac08f89d491b3..d6abd25088bd2c 100644 --- a/var/spack/repos/builtin/packages/cgns/package.py +++ b/var/spack/repos/builtin/packages/cgns/package.py @@ -38,6 +38,9 @@ class Cgns(CMakePackage): version("3.3.1", sha256="81093693b2e21a99c5640b82b267a495625b663d7b8125d5f1e9e7aaa1f8d469") version("3.3.0", sha256="8422c67994f8dc6a2f201523a14f6c7d7e16313bdd404c460c16079dbeafc662") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("hdf5", default=True, description="Enable HDF5 interface") variant("fortran", default=False, description="Enable Fortran interface") variant("base_scope", default=False, description="Enable base scope") @@ -73,6 +76,11 @@ class Cgns(CMakePackage): # https://bugs.gentoo.org/662210 patch("no-matherr.patch", when="@:3.3.1 +tools") + # patch for gcc14 due to using internal tk type/function, + # copied from https://github.com/CGNS/CGNS/pull/757 + # (adjusted an include from tk-private/generic/tkInt.h to tkInt.h) + patch("gcc14.patch", when="@:4.4.0 %gcc@14:") + def cmake_args(self): spec = self.spec options = [] diff --git a/var/spack/repos/builtin/packages/chaco/package.py b/var/spack/repos/builtin/packages/chaco/package.py index 08f4ade01309b5..e1b76a7ce00c5a 100644 --- a/var/spack/repos/builtin/packages/chaco/package.py +++ b/var/spack/repos/builtin/packages/chaco/package.py @@ -19,6 +19,9 @@ class Chaco(CMakePackage): version("develop", branch="truchas") version("2020-07-16", commit="92a877b381933d12b02507413897f696d81b4682", preferred=True) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="build shared library") depends_on("cmake@3.16:", type="build") diff --git a/var/spack/repos/builtin/packages/chai/change_mpi_target_name_umpire_patch.patch b/var/spack/repos/builtin/packages/chai/change_mpi_target_name_umpire_patch.patch new file mode 100644 index 00000000000000..ca866408aa54a1 --- /dev/null +++ b/var/spack/repos/builtin/packages/chai/change_mpi_target_name_umpire_patch.patch @@ -0,0 +1,13 @@ +diff --git a/cmake/thirdparty/SetupChaiThirdparty.cmake b/cmake/thirdparty/SetupChaiThirdparty.cmake +index d0be864..a8b33f0 100644 +--- a/cmake/thirdparty/SetupChaiThirdparty.cmake ++++ b/cmake/thirdparty/SetupChaiThirdparty.cmake +@@ -12,7 +12,7 @@ if (NOT TARGET umpire) + find_package(umpire REQUIRED) + + if (ENABLE_MPI) +- set(UMPIRE_DEPENDS mpi) ++ set(UMPIRE_DEPENDS MPI::MPI_CXX) + else() + set(UMPIRE_DEPENDS) + endif() diff --git a/var/spack/repos/builtin/packages/chai/package.py b/var/spack/repos/builtin/packages/chai/package.py index 2c07aee32cd698..877b42fe4a5f74 100644 --- a/var/spack/repos/builtin/packages/chai/package.py +++ b/var/spack/repos/builtin/packages/chai/package.py @@ -7,6 +7,8 @@ from spack.package import * +from .blt import llnl_link_helpers + class Chai(CachedCMakePackage, CudaPackage, ROCmPackage): """ @@ -17,12 +19,41 @@ class Chai(CachedCMakePackage, CudaPackage, ROCmPackage): git = "https://github.com/LLNL/CHAI.git" tags = ["ecp", "e4s", "radiuss"] - maintainers("davidbeckingsale") + maintainers("davidbeckingsale", "adayton1") license("BSD-3-Clause") version("develop", branch="develop", submodules=False) - version("main", branch="main", submodules=False) + version( + "2024.02.2", + tag="v2024.02.2", + commit="5ba0944d862513f600432c34b009824875df27e5", + submodules=False, + ) + version( + "2024.02.1", + tag="v2024.02.1", + commit="7597134729bd3a38b45b67b4dfbf7f199d8106f3", + submodules=False, + ) + version( + "2024.02.0", + tag="v2024.02.0", + commit="31773a2f0d30f3f64c82939f60fc4da32cf33261", + submodules=False, + ) + version( + "2023.06.0", + tag="v2023.06.0", + commit="6fe3470ad020303530af2f3dbbfe18826bd3319b", + submodules=False, + ) + version( + "2022.10.0", + tag="v2022.10.0", + commit="9510efd33b06e4443b15447eebb7dad761822654", + submodules=False, + ) version( "2022.03.0", tag="v2022.03.0", @@ -61,6 +92,12 @@ class Chai(CachedCMakePackage, CudaPackage, ROCmPackage): ) version("1.0", tag="v1.0", commit="501a098ad879dc8deb4a74fcfe8c08c283a10627", submodules=True) + depends_on("cxx", type="build") # generated + + # Patching Umpire for dual BLT targets import changed MPI target name in Umpire link interface + # We propagate the patch here. + patch("change_mpi_target_name_umpire_patch.patch", when="@2022.10.0:2023.06.0") + variant("enable_pick", default=False, description="Enable pick method") variant( "separable_compilation", @@ -68,29 +105,45 @@ class Chai(CachedCMakePackage, CudaPackage, ROCmPackage): description="Build with CUDA_SEPARABLE_COMPILATION flag on ", ) variant("shared", default=True, description="Build Shared Libs") + variant("mpi", default=False, description="Enable MPI support") variant("raja", default=False, description="Build plugin for RAJA") - variant("benchmarks", default=False, description="Build benchmarks.") variant("examples", default=True, description="Build examples.") variant("openmp", default=False, description="Build using OpenMP") # TODO: figure out gtest dependency and then set this default True # and remove the +tests conflict below. - variant("tests", default=False, description="Build tests") + variant( + "tests", + default="none", + values=("none", "basic", "benchmarks"), + multi=False, + description="Tests to run", + ) depends_on("cmake@3.8:", type="build") depends_on("cmake@3.9:", type="build", when="+cuda") - depends_on("cmake@3.14:", when="@2022.03.0:") + depends_on("cmake@3.14:", type="build", when="@2022.03.0:") - depends_on("blt@0.5.0:", type="build", when="@2022.03.0:") - depends_on("blt@0.4.1:", type="build", when="@2.4.0:") - depends_on("blt@0.4.0:", type="build", when="@2.3.0") - depends_on("blt@0.3.6:", type="build", when="@:2.2.2") + depends_on("blt") + depends_on("blt@0.6.2:", type="build", when="@2024.02.1:") + depends_on("blt@0.6.1:", type="build", when="@2024.02.0:") + depends_on("blt@0.5.3", type="build", when="@2023.06.0") + depends_on("blt@0.5.2:0.5.3", type="build", when="@2022.10.0") + depends_on("blt@0.5.0:0.5.3", type="build", when="@2022.03.0") + depends_on("blt@0.4.1:0.5.3", type="build", when="@2.4.0") + depends_on("blt@0.4.0:0.5.3", type="build", when="@2.3.0") + depends_on("blt@0.3.6:0.5.3", type="build", when="@:2.2.2") conflicts("^blt@:0.3.6", when="+rocm") depends_on("umpire") - depends_on("umpire@2022.03.0:", when="@2022.03.0:") + depends_on("umpire@2024.02.1:", when="@2024.02.1:") + depends_on("umpire@2024.02.0:", when="@2024.02.0:") + depends_on("umpire@2023.06.0", when="@2023.06.0") + depends_on("umpire@2022.10.0:2023.06.0", when="@2022.10.0") + depends_on("umpire@2022.03.0:2023.06.0", when="@2022.03.0") depends_on("umpire@6.0.0", when="@2.4.0") depends_on("umpire@4.1.2", when="@2.2.0:2.3.0") - depends_on("umpire@main", when="@main") + + depends_on("umpire+mpi", when="+mpi") with when("+cuda"): depends_on("umpire+cuda") @@ -107,11 +160,15 @@ class Chai(CachedCMakePackage, CudaPackage, ROCmPackage): with when("+raja"): depends_on("raja~openmp", when="~openmp") depends_on("raja+openmp", when="+openmp") - depends_on("raja@0.14.0", when="@2.4.0") - depends_on("raja@0.13.0", when="@2.3.0") + depends_on("raja@2024.02.2:", when="@2024.02.2:") + depends_on("raja@2024.02.1:", when="@2024.02.1:") + depends_on("raja@2024.02.0:", when="@2024.02.0:") + depends_on("raja@2023.06.0", when="@2023.06.0") + depends_on("raja@2022.10.0:2023.06.0", when="@2022.10.0") + depends_on("raja@2022.03.0:2023.06.0", when="@2022.03.0") depends_on("raja@0.12.0", when="@2.2.0:2.2.2") - depends_on("raja@2022.03.0:", when="@2022.03.0:") - depends_on("raja@main", when="@main") + depends_on("raja@0.13.0", when="@2.3.0") + depends_on("raja@0.14.0", when="@2.4.0") with when("+cuda"): depends_on("raja+cuda") @@ -125,7 +182,7 @@ class Chai(CachedCMakePackage, CudaPackage, ROCmPackage): when="amdgpu_target={0}".format(arch), ) - conflicts("+benchmarks", when="~tests") + depends_on("mpi", when="+mpi") def _get_sys_type(self, spec): sys_type = spec.architecture @@ -138,25 +195,34 @@ def cache_name(self): hostname = socket.gethostname() if "SYS_TYPE" in env: hostname = hostname.rstrip("1234567890") - return "{0}-{1}-{2}@{3}.cmake".format( + return "{0}-{1}-{2}@{3}-{4}.cmake".format( hostname, self._get_sys_type(self.spec), self.spec.compiler.name, self.spec.compiler.version, + self.spec.dag_hash(8), ) def initconfig_compiler_entries(self): spec = self.spec + compiler = self.compiler + # Default entries are already defined in CachedCMakePackage, inherit them: entries = super().initconfig_compiler_entries() + if "+rocm" in spec: entries.insert(0, cmake_cache_path("CMAKE_CXX_COMPILER", spec["hip"].hipcc)) + + llnl_link_helpers(entries, spec, compiler) + return entries def initconfig_hardware_entries(self): spec = self.spec entries = super().initconfig_hardware_entries() - entries.append(cmake_cache_option("ENABLE_OPENMP", "+openmp" in spec)) + entries.append("#------------------{0}".format("-" * 30)) + entries.append("# Package custom hardware settings") + entries.append("#------------------{0}\n".format("-" * 30)) if "+cuda" in spec: entries.append(cmake_cache_option("ENABLE_CUDA", True)) @@ -164,54 +230,67 @@ def initconfig_hardware_entries(self): entries.append(cmake_cache_option("CMAKE_CUDA_SEPARABLE_COMPILATION", True)) entries.append(cmake_cache_option("CUDA_SEPARABLE_COMPILATION", True)) - if not spec.satisfies("cuda_arch=none"): - cuda_arch = spec.variants["cuda_arch"].value - entries.append(cmake_cache_string("CUDA_ARCH", "sm_{0}".format(cuda_arch[0]))) - entries.append( - cmake_cache_string("CMAKE_CUDA_ARCHITECTURES", "{0}".format(cuda_arch[0])) - ) - flag = "-arch sm_{0}".format(cuda_arch[0]) - entries.append(cmake_cache_string("CMAKE_CUDA_FLAGS", "{0}".format(flag))) else: entries.append(cmake_cache_option("ENABLE_CUDA", False)) if "+rocm" in spec: entries.append(cmake_cache_option("ENABLE_HIP", True)) - entries.append(cmake_cache_path("HIP_ROOT_DIR", "{0}".format(spec["hip"].prefix))) - archs = self.spec.variants["amdgpu_target"].value - if archs != "none": - arch_str = ",".join(archs) - entries.append( - cmake_cache_string("HIP_HIPCC_FLAGS", "--amdgpu-target={0}".format(arch_str)) - ) else: entries.append(cmake_cache_option("ENABLE_HIP", False)) return entries + def initconfig_mpi_entries(self): + spec = self.spec + + entries = super(Chai, self).initconfig_mpi_entries() + entries.append(cmake_cache_option("ENABLE_MPI", "+mpi" in spec)) + + return entries + def initconfig_package_entries(self): spec = self.spec entries = [] option_prefix = "CHAI_" if spec.satisfies("@2022.03.0:") else "" + # TPL locations + entries.append("#------------------{0}".format("-" * 60)) + entries.append("# TPLs") + entries.append("#------------------{0}\n".format("-" * 60)) + entries.append(cmake_cache_path("BLT_SOURCE_DIR", spec["blt"].prefix)) if "+raja" in spec: entries.append(cmake_cache_option("{}ENABLE_RAJA_PLUGIN".format(option_prefix), True)) entries.append(cmake_cache_path("RAJA_DIR", spec["raja"].prefix)) + entries.append(cmake_cache_path("umpire_DIR", spec["umpire"].prefix)) + + # Build options + entries.append("#------------------{0}".format("-" * 60)) + entries.append("# Build Options") + entries.append("#------------------{0}\n".format("-" * 60)) + + # Build options + entries.append(cmake_cache_string("CMAKE_BUILD_TYPE", spec.variants["build_type"].value)) + entries.append(cmake_cache_option("BUILD_SHARED_LIBS", "+shared" in spec)) + + # Generic options that have a prefixed equivalent in CHAI CMake + entries.append(cmake_cache_option("ENABLE_OPENMP", "+openmp" in spec)) + entries.append(cmake_cache_option("ENABLE_EXAMPLES", "+examples" in spec)) + entries.append(cmake_cache_option("ENABLE_DOCS", False)) + if "tests=benchmarks" in spec: + # BLT requires ENABLE_TESTS=True to enable benchmarks + entries.append(cmake_cache_option("ENABLE_BENCHMARKS", True)) + entries.append(cmake_cache_option("ENABLE_TESTS", True)) + else: + entries.append(cmake_cache_option("ENABLE_TESTS", "tests=none" not in spec)) + + # Prefixed options that used to be name without one entries.append( cmake_cache_option("{}ENABLE_PICK".format(option_prefix), "+enable_pick" in spec) ) - entries.append(cmake_cache_path("umpire_DIR", spec["umpire"].prefix.share.umpire.cmake)) - entries.append(cmake_cache_option("ENABLE_TESTS", "+tests" in spec)) - entries.append(cmake_cache_option("ENABLE_BENCHMARKS", "+benchmarks" in spec)) - entries.append( - cmake_cache_option("{}ENABLE_EXAMPLES".format(option_prefix), "+examples" in spec) - ) - entries.append(cmake_cache_option("BUILD_SHARED_LIBS", "+shared" in spec)) return entries def cmake_args(self): - options = [] - return options + return [] diff --git a/var/spack/repos/builtin/packages/chameleon/package.py b/var/spack/repos/builtin/packages/chameleon/package.py index 5f9c8451ab32b2..8a600cdb8d9449 100644 --- a/var/spack/repos/builtin/packages/chameleon/package.py +++ b/var/spack/repos/builtin/packages/chameleon/package.py @@ -19,6 +19,10 @@ class Chameleon(CMakePackage, CudaPackage): version("1.2.0", sha256="b8988ecbff19c603ae9f61441653c21bba18d040bee9bb83f7fc9077043e50b4") version("1.1.0", sha256="e64d0438dfaf5effb3740e53f3ab017d12744b85a138b2ef702a81df559126df") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # cmake's specific variant("shared", default=True, description="Build chameleon as a shared library") diff --git a/var/spack/repos/builtin/packages/changa/package.py b/var/spack/repos/builtin/packages/changa/package.py index 43b55a6a85c2bf..ac44bc2a936555 100644 --- a/var/spack/repos/builtin/packages/changa/package.py +++ b/var/spack/repos/builtin/packages/changa/package.py @@ -24,6 +24,9 @@ class Changa(AutotoolsPackage): version("master", branch="master") version("3.4", sha256="c2bceb6ac00025dfd704bb6960bc17c6df7c746872185845d1e75f47e6ce2a94") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated patch("fix_configure_path.patch") resource( diff --git a/var/spack/repos/builtin/packages/channelflow/package.py b/var/spack/repos/builtin/packages/channelflow/package.py index 1f0cb9fa898bd6..bd8352c7102ad5 100644 --- a/var/spack/repos/builtin/packages/channelflow/package.py +++ b/var/spack/repos/builtin/packages/channelflow/package.py @@ -19,6 +19,8 @@ class Channelflow(CMakePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libs") variant("mpi", default=True, description="Enable MPI parallelism") variant("hdf5", default=True, description="Enable support for HDF5 I/O") diff --git a/var/spack/repos/builtin/packages/chaparral/package.py b/var/spack/repos/builtin/packages/chaparral/package.py index 050ca651d4f5d7..ff55533b118b14 100644 --- a/var/spack/repos/builtin/packages/chaparral/package.py +++ b/var/spack/repos/builtin/packages/chaparral/package.py @@ -19,6 +19,8 @@ class Chaparral(CMakePackage): version("develop", branch="truchas") version("2020-08-28", commit="c8a190bb74ef33ad8b2f7b67d20590f393fde32a", preferred=True) + depends_on("c", type="build") # generated + variant("shared", default=True, description="Build shared library") variant("mpi", default=True, description="Build parallel library") diff --git a/var/spack/repos/builtin/packages/chapel/fix_spack_cc_wrapper_in_cray_prgenv.patch b/var/spack/repos/builtin/packages/chapel/fix_spack_cc_wrapper_in_cray_prgenv.patch new file mode 100644 index 00000000000000..b53b7f2c26064c --- /dev/null +++ b/var/spack/repos/builtin/packages/chapel/fix_spack_cc_wrapper_in_cray_prgenv.patch @@ -0,0 +1,22 @@ +diff --git a/util/chplenv/chpl_llvm.py b/util/chplenv/chpl_llvm.py +index f0fd495f28..95dc9c3f67 100755 +--- a/util/chplenv/chpl_llvm.py ++++ b/util/chplenv/chpl_llvm.py +@@ -866,13 +866,14 @@ def get_clang_prgenv_args(): + os.environ['PE_CHAPEL_PKGCONFIG_LIBS'] = gather_pe_chpl_pkgconfig_libs() + + # Use cc --cray-print-opts=... to get arguments from compiler driver +- ++ # find the actual cc in case something like spack has wrapped it ++ real_cc = os.path.join(os.environ["CRAYPE_DIR"], "bin", "cc") + # Get compilation arguments +- opts = run_command(['cc', '--cray-print-opts=cflags']) ++ opts = run_command([real_cc, '--cray-print-opts=cflags']) + comp_args.extend(opts.split()) + + # Get link arguments +- opts = run_command(['cc', '--cray-print-opts=libs']) ++ opts = run_command([real_cc, '--cray-print-opts=libs']) + link_args.extend(opts.split()) + + return (comp_args, link_args) diff --git a/var/spack/repos/builtin/packages/chapel/package.py b/var/spack/repos/builtin/packages/chapel/package.py index feedd735d15e27..3d530d7a99ee79 100644 --- a/var/spack/repos/builtin/packages/chapel/package.py +++ b/var/spack/repos/builtin/packages/chapel/package.py @@ -3,24 +3,822 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os +import subprocess + from spack.package import * +from spack.util.environment import is_system_path, set_env + + +@llnl.util.lang.memoized +def is_CrayEX(): + # Credit to upcxx package for this hpe-cray-ex detection function + if spack.platforms.host().name == "linux": + target = os.environ.get("CRAYPE_NETWORK_TARGET") + if target in ["ofi", "ucx"]: # normal case + return True + elif target is None: # but some systems lack Cray PrgEnv + fi_info = which("fi_info") + if ( + fi_info + and fi_info("-l", output=str, error=str, fail_on_error=False).find("cxi") >= 0 + ): + return True + return False -class Chapel(AutotoolsPackage): +class Chapel(AutotoolsPackage, CudaPackage, ROCmPackage): """Chapel is a modern programming language that is parallel, productive, - portable, scalable and open-source.""" + portable, scalable and open-source. The Chapel package comes with many + options in the form of variants, most of which can be left unset to allow + Chapel's built-in scripts to determine the proper values based on the environment.""" homepage = "https://chapel-lang.org/" - url = "https://github.com/chapel-lang/chapel/releases/download/1.24.1/chapel-1.24.1.tar.gz" + url = "https://github.com/chapel-lang/chapel/archive/refs/tags/2.1.0.tar.gz" + git = "https://github.com/chapel-lang/chapel.git" + + test_requires_compiler = True + + # TODO: Re-enable these once we add determine_version and determine_variants + # executables = ["^chpl$", "^chpldoc$"] + + # A list of GitHub accounts to notify when the package is updated. + # TODO: add chapel-project github account + maintainers("arezaii", "bonachea") + + # See https://spdx.org/licenses/ for a list. license("Apache-2.0") - version("1.24.1", sha256="f898f266fccaa34d937b38730a361d42efb20753ba43a95e5682816e008ce5e4") - version("1.24.0", sha256="77c6087f3e0837268470915f2ad260d49cf7ac4adf16f5b44862ae624c1be801") - version("1.23.0", sha256="7ae2c8f17a7b98ac68378e94a842cf16d4ab0bcfeabc0fee5ab4aaa07b205661") - version("1.22.1", sha256="8235eb0869c9b04256f2e5ce3ac4f9eff558401582fba0eba05f254449a24989") - version("1.22.0", sha256="57ba6ee5dfc36efcd66854ecb4307e1c054700ea201eff73012bd8b4572c2ce6") - version("1.21.0", sha256="886f7ba0e0e86c86dba99417e3165f90b1d3eca59c8cd5a7f645ce28cb5d82a0") - version("1.20.0", sha256="08bc86df13e4ad56d0447f52628b0f8e36b0476db4e19a90eeb2bd5f260baece") - version("1.19.0", sha256="c2b68a20d87cc382c2f73dd1ecc6a4f42fb2f590b0b10fbc577382dd35c9e9bd") - version("1.18.0", sha256="68471e1f398b074edcc28cae0be26a481078adc3edea4df663f01c6bd3b6ae0d") + version("main", branch="main") + + version("2.1.0", sha256="8e164d9a9e705e6b816857e84833b0922ce0bde6a36a9f3a29734830aac168ef") + version("2.0.1", sha256="47e1f3789478ea870bd4ecdf52acbe469d171b89b663309325431f3da7c75008") + version("2.0.0", sha256="a8cab99fd034c7b7229be8d4626ec95cf02072646fb148c74b4f48c460c6059c") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + patch("fix_spack_cc_wrapper_in_cray_prgenv.patch", when="@2.0.0:") + + launcher_names = ( + "amudprun", + "aprun", + "gasnetrun_ibv", + "gasnetrun_mpi", + "mpirun4ofi", + "lsf-gasnetrun_ibv", + "pals", + "pbs-aprun", + "pbs-gasnetrun_ibv", + "slurm-gasnetrun_ibv", + "slurm-gasnetrun_mpi", + "slurm-gasnetrun_ofi", + "slurm-srun", + "smp", + "none", + "unset", + ) + + # TODO: revise this list of mappings, probably need more logic for cce, see upc++ + compiler_map = { + "aocc": "clang", + "apple-clang": "clang", + "arm": "clang", + "clang": "clang", + "cce": "cray-prgenv-cray", + "dpcpp": "intel", + "gcc": "gnu", + "intel": "intel", + "llvm": "llvm", + "oneapi": "intel", + "pgi": "pgi", + "rocmcc": "clang", + "unset": "unset", + } + + cpu_options = ( + "native", + "none", + "unknown", + "unset", + "aarch64", + "barcelona", + "bdver1", + "bdver2", + "bdver3", + "bdver4", + "broadwell", + "core2", + "haswell", + "ivybridge", + "k8", + "k8sse3", + "nehalem", + "sandybridge", + "skylake", + "thunderx", + "thunderx2t99", + "westmere", + ) + + # TODO: add other package dependencies + package_module_dict = { + "curl": "curl", + "hdf5": "hdf5+hl~mpi", + "libevent": "libevent", + "protobuf": "py-protobuf", + "ssl": "openssl", + "yaml": "libyaml@0.1", + "zmq": "libzmq", + } + + platform_opts = ( + "cray-cs", + "cray-xc", + "cygwin32", + "cygwin64", + "darwin", + "hpe-apollo", + "hpe-cray-ex", + "linux32", + "linux64", + "netbsd32", + "netbsd64", + "pwr6", + "unset", + ) + + variant( + "atomics", + values=("unset", "cstdlib", "intrinsics", "locks"), + default="unset", + description="Select atomics implementation", + multi=False, + ) + + # TODO: refactor this somehow, this is a separate documentation tool, not a variant of chapel + variant("chpldoc", default=False, description="Build chpldoc in addition to chpl") + + variant("developer", default=False, description="Enable Chapel developer mode") + + variant( + "comm", + default="none", + description="Build Chapel with multi-locale support", + values=("gasnet", "none", "ofi", "ugni"), + ) + + variant( + "comm_substrate", + default="unset", + description="Build Chapel with GASNet multi-locale support using the " + "supplied CHPL_COMM_SUBSTRATE", + values=("ibv", "ofi", "udp", "smp", "unset"), + multi=False, + sticky=True, # never allow the concretizer to choose this + ) + + # Chapel depends on GASNet whenever comm=gasnet. + # The default (and recommendation) is to use the embedded copy of GASNet. + # This variant allows overriding with a particular version of GASNet sources, + # although this is not officially supported and some combinations might be rejected. + variant( + "gasnet", + description="Control the GASNet library version used", + default="bundled", + values=("bundled", "spack"), + multi=False, + ) + + variant( + "gasnet_segment", + default="unset", + description="Build Chapel with multi-locale support using the " + "supplied CHPL_GASNET_SEGMENT", + values=("everything", "fast", "large", "unset"), + multi=False, + ) + + variant( + "gmp", + description="Build with gmp support", + default="spack", + values=("bundled", "none", "spack"), + multi=False, + ) + + variant( + "gpu_mem_strategy", + description="The memory allocation strategy for GPU data", + values=("array_on_device", "unified_memory"), + default="array_on_device", + multi=False, + ) + + variant( + "host_arch", + description="Host architecture of the build machine", + values=("x86_64", "aarch64", "arm64", "unset"), + default="unset", + multi=False, + ) + + variant( + "host_jemalloc", + values=("bundled", "none", "spack", "unset"), + default="unset", + multi=False, + description="Selects between no jemalloc, bundled jemalloc, or spack supplied jemalloc", + ) + + variant( + "host_mem", + values=("cstdlib", "jemalloc"), + default="jemalloc", + description="Memory management layer for the chpl compiler", + multi=False, + ) + + variant( + "host_platform", + description="Host platform", + default="unset", + values=platform_opts, + multi=False, + ) + + variant( + "hwloc", + description="Build with hwloc support", + default="bundled", + values=( + "bundled", + "none", + # CHPL_HWLOC=system existed back to at least 2017, + # but it was buggy and unsupported until version 2.1 + conditional("spack", when="@2.1:"), + ), + multi=False, + ) + + variant( + "launcher", + values=launcher_names, + default="unset", + description="Launcher to use for running Chapel programs", + multi=False, + ) + + variant( + "lib_pic", + values=("none", "pic"), + default="none", + description="Build position-independent code suitable for shared libraries", + ) + + variant( + "libfabric", + default="unset", + description="When building with ofi support, specify libfabric option", + values=("bundled", "spack", "unset"), + multi=False, + ) + + variant( + "llvm", + default="spack", + description="LLVM backend type. The 'spack' value can use an external " + "source of LLVM or let spack build a version if no LLVM installs were " + "previously detected by 'spack external find'", + values=("bundled", "none", "spack"), + ) + + variant( + "re2", + description="Build with re2 support", + default="bundled", + values=("bundled", "none"), + multi=False, + ) + + variant( + "target_arch", + description="Target architecture for cross compilation", + default="unset", + values=("x86_64", "aarch64", "arm64", "unset"), + multi=False, + ) + + variant( + "target_cpu", + values=cpu_options, + description="Indicate that the target executable should be specialized " + "to the given architecture when using --specialize (and --fast).", + default="unset", + multi=False, + ) + + variant( + "target_platform", + description="Target platform for cross compilation", + default="unset", + values=platform_opts, + multi=False, + ) + + variant( + "tasks", + description="Select tasking layer for intra-locale parallelism", + default="qthreads", + values=("fifo", "qthreads"), + multi=False, + ) + + variant( + "timers", + description="Select timers implementation", + default="unset", + values=("generic", "unset"), + multi=False, + ) + + variant( + "unwind", + description="Build with unwind library for stack tracing", + default="none", + values=("bundled", "none", "spack"), + multi=False, + ) + + # Add dependencies for package modules + for variant_name, dep in package_module_dict.items(): + variant( + variant_name, + description="Build with support for the Chapel {0} package module".format( + variant_name + ), + default=True, + ) + depends_on(dep, when="+{0}".format(variant_name)) + + # TODO: for CHPL_X_CC and CHPL_X_CXX, can we capture an arbitrary path, possibly + # with arguments? + chpl_env_vars = [ + "CHPL_ATOMICS", + "CHPL_AUX_FILESYS", + "CHPL_COMM", + "CHPL_COMM_SUBSTRATE", + "CHPL_DEVELOPER", + "CHPL_GASNET_SEGMENT", + "CHPL_GMP", + "CHPL_GPU", + "CHPL_GPU_ARCH", + "CHPL_GPU_MEM_STRATEGY", + "CHPL_HOST_ARCH", + # "CHPL_HOST_CC", + "CHPL_HOST_COMPILER", + # "CHPL_HOST_CXX", + "CHPL_HOST_JEMALLOC", + "CHPL_HOST_MEM", + "CHPL_HOST_PLATFORM", + "CHPL_HWLOC", + "CHPL_LAUNCHER", + "CHPL_LIB_PIC", + "CHPL_LIBFABRIC", + "CHPL_LLVM", + "CHPL_LLVM_CONFIG", + "CHPL_LLVM_SUPPORT", + "CHPL_LLVM_VERSION", + "CHPL_LOCALE_MODEL", + "CHPL_MEM", + "CHPL_RE2", + "CHPL_SANITIZE", + "CHPL_SANITIZE_EXE", + "CHPL_TARGET_ARCH", + # "CHPL_TARGET_CC", + "CHPL_TARGET_COMPILER", + "CHPL_TARGET_CPU", + # "CHPL_TARGET_CXX", + "CHPL_TARGET_PLATFORM", + "CHPL_TASKS", + "CHPL_TIMERS", + "CHPL_UNWIND", + ] + + conflicts("platform=windows") # Support for windows is through WSL only + + conflicts("+rocm", when="+cuda", msg="Chapel must be built with either CUDA or ROCm, not both") + conflicts("+rocm", when="@:2.0.0", msg="ROCm support in spack requires Chapel 2.0.0 or later") + + conflicts( + "comm_substrate=unset", + when="comm=gasnet", + msg="comm=gasnet requires you to also set comm_substrate= to the appropriate network", + ) + + conflicts( + "^python@3.12:", + when="@:2.1.0", + msg="Chapel versions prior to 2.1.0 may produce SyntaxWarnings with Python >= 3.12", + ) + + conflicts( + "host_jemalloc=spack", + when="platform=linux", + msg="Only bundled jemalloc may be used on Linux systems, see " + "https://chapel-lang.org/docs/usingchapel/chplenv.html#chpl-host-jemalloc", + ) + + conflicts( + "host_jemalloc=bundled", + when="platform=darwin", + msg="Only system jemalloc may be used on Darwin (MacOS) systems, see " + "https://chapel-lang.org/docs/usingchapel/chplenv.html#chpl-host-jemalloc", + ) + + with when("llvm=none"): + conflicts("+cuda", msg="Cuda support requires building with LLVM") + conflicts("+rocm", msg="ROCm support requires building with LLVM") + + # Add dependencies + + depends_on("doxygen@1.8.17:", when="+chpldoc") + + # TODO: keep up to date with util/chplenv/chpl_llvm.py + with when("llvm=spack"): + depends_on("llvm@11:17", when="@:2.0.1") + depends_on("llvm@11:18", when="@2.1.0:") + + # Based on docs https://chapel-lang.org/docs/technotes/gpu.html#requirements + depends_on("llvm@16:", when="llvm=spack ^cuda@12:") + requires( + "^llvm targets=all", + msg="llvm=spack +cuda requires LLVM support the nvptx target", + when="llvm=spack +cuda", + ) + + depends_on("cuda@11:", when="+cuda", type=("build", "link", "run", "test")) + + # This is because certain systems have binutils installed as a system package + # but do not include the headers. Spack incorrectly supplies those external + # packages as proper dependencies for LLVM, but then LLVM will fail to build + # with an error about missing plugin-api.h + depends_on("binutils+gold+ld+plugins+headers", when="llvm=bundled") + + depends_on("m4") + + depends_on("gmp", when="gmp=spack", type=("build", "link", "run", "test")) + depends_on("hwloc", when="hwloc=spack", type=("build", "link", "run", "test")) + depends_on("libfabric", when="libfabric=spack", type=("build", "link", "run", "test")) + depends_on("libunwind", when="unwind=spack", type=("build", "link", "run", "test")) + depends_on("jemalloc", when="host_jemalloc=spack", type=("build", "link", "run", "test")) + + depends_on("gasnet conduits=none", when="gasnet=spack") + depends_on("gasnet@2024.5.0: conduits=none", when="@2.1.0: gasnet=spack") + + depends_on("python@3.7:") + depends_on("cmake@3.16:") + + # ensure we can map the spack compiler name to one of the ones we recognize + requires( + "%aocc", + "%apple-clang", + "%arm", + "%clang", + "%cce", + "%cray-prgenv-cray", + "%cray-prgenv-gnu", + "%cray-prgenv-intel", + "%cray-prgenv-pgi", + "%dpcpp", + "%gcc", + "%intel", + "%llvm", + "%oneapi", + "%pgi", + "%rocmcc", + policy="one_of", + ) + + def unset_chpl_env_vars(self, env): + # Clean the environment from any pre-set CHPL_ variables that affect the build + for var in self.chpl_env_vars: + env.unset(var) + + def build(self, spec, prefix): + make() + if spec.variants["chpldoc"].value: + make("chpldoc") + + def setup_chpl_platform(self, env): + if self.spec.variants["host_platform"].value == "unset": + if is_CrayEX(): + env.set("CHPL_HOST_PLATFORM", "hpe-cray-ex") + + def setup_chpl_compilers(self, env): + env.set("CHPL_HOST_COMPILER", self.compiler_map[self.spec.compiler.name]) + env.set("CHPL_TARGET_COMPILER", self.compiler_map[self.spec.compiler.name]) + + # Undo spack compiler wrappers: + # the C/C++ compilers must work post-install + if self.spec.satisfies("+cuda") or self.spec.satisfies("+rocm"): + env.set("CHPL_TARGET_COMPILER", "llvm") + real_cc = join_path(self.spec["llvm"].prefix, "bin", "clang") + real_cxx = join_path(self.spec["llvm"].prefix, "bin", "clang++") + elif is_CrayEX() and os.environ.get("CRAYPE_DIR"): + real_cc = join_path(os.environ["CRAYPE_DIR"], "bin", "cc") + real_cxx = join_path(os.environ["CRAYPE_DIR"], "bin", "CC") + else: + real_cc = self.compiler.cc + real_cxx = self.compiler.cxx + env.set("CHPL_TARGET_CC", real_cc) + env.set("CHPL_TARGET_CXX", real_cxx) + + def setup_chpl_comm(self, env, spec): + env.set("CHPL_COMM", spec.variants["comm"].value) + + @run_before("configure", when="gasnet=spack") + def setup_gasnet(self): + dst = join_path(self.stage.source_path, "third-party", "gasnet", "gasnet-src") + remove_directory_contents(dst) + os.rmdir(dst) + symlink(self.spec["gasnet"].prefix.src, dst) + + def setup_chpl_llvm(self, env): + if self.spec.variants["llvm"].value == "spack": + env.set( + "CHPL_LLVM_CONFIG", "{0}/{1}".format(self.spec["llvm"].prefix, "bin/llvm-config") + ) + + def setup_if_not_unset(self, env, var, value): + if value != "unset": + if value == "spack": + value = "system" + env.set(var, value) + + def prepend_cpath_include(self, env, prefix): + if not is_system_path(prefix): + env.prepend_path("CPATH", prefix.include) + + def setup_env_vars(self, env): + # variants that appear unused by Spack typically correspond directly to + # a CHPL_ variable which will be used by the Chapel build system + for v in self.spec.variants.keys(): + self.setup_if_not_unset(env, "CHPL_" + v.upper(), self.spec.variants[v].value) + self.setup_chpl_llvm(env) + self.setup_chpl_compilers(env) + self.setup_chpl_platform(env) + + # TODO: a function to set defaults for things where we removed variants + # We'll set to GPU later if +rocm or +cuda requested + env.set("CHPL_LOCALE_MODEL", "flat") + + if self.spec.satisfies("+developer"): + env.set("CHPL_DEVELOPER", "true") + + if self.spec.variants["gmp"].value == "spack": + # TODO: why must we add to CPATH to find gmp.h + # TODO: why must we add to LIBRARY_PATH to find lgmp + self.prepend_cpath_include(env, self.spec["gmp"].prefix) + env.prepend_path("LIBRARY_PATH", self.spec["gmp"].prefix.lib) + # Need this for the test env, where it does not appear automatic: + env.prepend_path("PKG_CONFIG_PATH", self.spec["gmp"].prefix.lib.pkgconfig) + + if self.spec.variants["hwloc"].value == "spack": + env.prepend_path("LD_LIBRARY_PATH", self.spec["hwloc"].prefix.lib) + # Need this for the test env, where it does not appear automatic: + env.prepend_path("PKG_CONFIG_PATH", self.spec["hwloc"].prefix.lib.pkgconfig) + env.prepend_path("PKG_CONFIG_PATH", self.spec["libpciaccess"].prefix.lib.pkgconfig) + + if self.spec.variants["unwind"].value == "spack": + # chapel package would not build without cpath, missing libunwind.h + self.prepend_cpath_include(env, self.spec["libunwind"].prefix) + env.prepend_path("LD_LIBRARY_PATH", self.spec["libunwind"].prefix.lib) + + if self.spec.satisfies("+yaml"): + env.prepend_path("PKG_CONFIG_PATH", self.spec["libyaml"].prefix.lib.pkgconfig) + self.prepend_cpath_include(env, self.spec["libyaml"].prefix) + # could not compile test/library/packages/Yaml/writeAndParse.chpl without this + env.prepend_path("LIBRARY_PATH", self.spec["libyaml"].prefix.lib) + + if self.spec.satisfies("+zmq"): + self.prepend_cpath_include(env, self.spec["libzmq"].prefix) + # could not compile test/library/packages/ZMQ/hello.chpl without this + env.prepend_path("LIBRARY_PATH", self.spec["libzmq"].prefix.lib) + env.prepend_path("LD_LIBRARY_PATH", self.spec["libzmq"].prefix.lib) + # could not compile test/library/packages/ZMQ/hello.chpl without this + env.prepend_path("LIBRARY_PATH", self.spec["libzmq"].prefix.lib) + env.prepend_path("PKG_CONFIG_PATH", self.spec["libzmq"].prefix.lib.pkgconfig) + env.prepend_path("PKG_CONFIG_PATH", self.spec["libsodium"].prefix.lib.pkgconfig) + + if self.spec.satisfies("+curl"): + self.prepend_cpath_include(env, self.spec["curl"].prefix) + # could not compile test/library/packages/Curl/check-http.chpl without this + env.prepend_path("LIBRARY_PATH", self.spec["curl"].prefix.lib) + env.prepend_path("LD_LIBRARY_PATH", self.spec["curl"].prefix.lib) + env.prepend_path("PKG_CONFIG_PATH", self.spec["curl"].prefix.lib.pkgconfig) + + if self.spec.satisfies("+cuda"): + # TODO: why must we add to LD_LIBRARY_PATH to find libcudart? + env.prepend_path("LD_LIBRARY_PATH", self.spec["cuda"].prefix.lib64) + env.set("CHPL_LOCALE_MODEL", "gpu") + env.set("CHPL_GPU", "nvidia") + + if self.spec.satisfies("+rocm"): + env.set("CHPL_LOCALE_MODEL", "gpu") + env.set("CHPL_GPU", "amd") + env.set("CHPL_HOST_COMPILER", "llvm") + env.set("CHPL_GPU_ARCH", self.spec.variants["amdgpu_target"].value[0]) + env.set( + "CHPL_LLVM_CONFIG", + "{0}/{1}".format(self.spec["llvm-amdgpu"].prefix, "bin/llvm-config"), + ) + self.prepend_cpath_include(env, self.spec["hip"].prefix) + env.set("CHPL_ROCM_PATH", self.spec["llvm-amdgpu"].prefix) + env.prepend_path("LIBRARY_PATH", self.spec["hip"].prefix.lib) + env.prepend_path("LIBRARY_PATH", self.spec["hsa-rocr-dev"].prefix.lib) + env.prepend_path("LD_LIBRARY_PATH", self.spec["hip"].prefix.lib) + env.prepend_path("LD_LIBRARY_PATH", self.spec["hsa-rocr-dev"].prefix.lib) + self.setup_chpl_comm(env, self.spec) + + def setup_build_environment(self, env): + self.unset_chpl_env_vars(env) + self.setup_env_vars(env) + + def setup_run_environment(self, env): + self.setup_env_vars(env) + env.prepend_path( + "PATH", join_path(self.prefix.share, "chapel", self._output_version_short, "util") + ) + + @property + @llnl.util.lang.memoized + def _output_version_long(self): + if str(self.spec.version).lower() == "main": + return "2.2.0" + spec_vers_str = str(self.spec.version.up_to(3)) + return spec_vers_str + + @property + @llnl.util.lang.memoized + def _output_version_short(self): + if str(self.spec.version).lower() == "main": + return "2.2" + spec_vers_str = str(self.spec.version.up_to(2)) + return spec_vers_str + + def test_version(self): + """Perform version checks on selected installed package binaries.""" + expected = f"version {self._output_version_long}" + exes = ["chpl"] + + if self.spec.satisfies("+chpldoc"): + exes.append("chpldoc") + + for exe in exes: + reason = f"ensure version of {exe} is {self._output_version_long}" + with test_part(self, f"test_version_{exe}", purpose=reason): + path = join_path(self.prefix.bin, exe) + if not os.path.isfile(path): + raise SkipTest(f"{path} is not installed") + prog = which(path) + if prog is None: + raise RuntimeError(f"Could not find {path}") + output = prog("--version", output=str.split, error=str.split) + assert expected in output + + def check(self): + # TODO: we skip the self-check because it's ran by default but: + # - make check doesn't work at build time b/c the PATH isn't yet updated + # - make test is a long running operation + pass + + def check_chpl_install_gasnet(self): + """Setup env to run self-test after installing the package with gasnet""" + with set_env( + GASNET_SPAWNFN="L", + GASNET_QUIET="yes", + GASNET_ROUTE_OUTPUT="0", + QT_AFFINITY="no", + CHPL_QTHREAD_ENABLE_OVERSUBSCRIPTION="1", + CHPL_RT_MASTERIP="127.0.0.1", + CHPL_RT_WORKERIP="127.0.0.0", + CHPL_LAUNCHER="", + ): + return subprocess.run(["util/test/checkChplInstall"]) + + def check_chpl_install(self): + if self.spec.variants["comm"].value != "none": + return self.check_chpl_install_gasnet() + else: + return subprocess.run(["util/test/checkChplInstall"]) + + def test_hello(self): + """Run the hello world test""" + with working_dir(self.test_suite.current_test_cache_dir): + with set_env(CHPL_CHECK_HOME=self.test_suite.current_test_cache_dir): + with test_part(self, "test_hello", purpose="test hello world"): + if self.spec.satisfies("+cuda") or self.spec.satisfies("+rocm"): + with set_env(COMP_FLAGS="--no-checks --no-compiler-driver"): + res = self.check_chpl_install() + assert res and res.returncode == 0 + else: + res = self.check_chpl_install() + assert res and res.returncode == 0 + + # TODO: This is a pain because the checkChplDoc script doesn't have the same + # support for CHPL_CHECK_HOME and chpldoc is finicky about CHPL_HOME + def test_chpldoc(self): + """Run the chpldoc test""" + if not self.spec.satisfies("+chpldoc"): + print("Skipping chpldoc test as chpldoc variant is not set") + return + with working_dir(self.test_suite.current_test_cache_dir): + with set_env(CHPL_HOME=self.test_suite.current_test_cache_dir): + with test_part(self, "test_chpldoc", purpose="test chpldoc"): + res = subprocess.run(["util/test/checkChplDoc"]) + assert res.returncode == 0 + + # TODO: In order to run these tests, there's a lot of infrastructure to copy + # from the Chapel test suite and there are conflicts with CHPL_HOME needing + # to match the compiler's directory and the test suite's directory + # def test_package_modules(self): + # """Test that the package modules are available""" + # # if not self.spec.satisfies("+module_tests"): + # # print("Skipping module tests as module_tests variant is not set") + # # return + # tests_to_run = [] + # with working_dir(self.test_suite.current_test_cache_dir): + # with set_env(CHPL_HOME=join_path(self.spec.prefix.share, + # "chapel", self._output_version_short)): + # with test_part(self, "test_package_modules", purpose="test package modules"): + # if self.spec.satisfies("+yaml"): + # tests_to_run.append("test/library/packages/Yaml/writeAndParse.chpl") + # if self.spec.satisfies("+zmq"): + # tests_to_run.append("test/library/packages/ZMQ/weather.chpl") + # if self.spec.satisfies("+ssl"): + # tests_to_run.append("test/library/packages/Crypto/") + # # TODO: These tests fail with llvm, unable to find C variable CURLPAUSE_CONT + # if ( + # self.spec.satisfies("+curl") + # and self.spec.variants["llvm"].value == "none" + # ): + # with set_env(CHPL_NIGHTLY_TEST_CONFIG_NAME="networking-packages"): + # print("Running package module test for package 'curl'") + # res = subprocess.run( + # ["util/start_test", "test/library/packages/Curl/"] + # ) + # assert res.returncode == 0 + # print("Running package module test for package 'url'") + # res = subprocess.run(["util/start_test", + # "test/library/packages/URL/"]) + # assert res.returncode == 0 + # if self.spec.satisfies("+hdf5"): + # tests_to_run.append("test/library/packages/HDF5/") + # if self.spec.satisfies("+protobuf"): + # tests_to_run.append("test/library/packages/ProtobufProtocolSupport/") + # if len(tests_to_run) > 0: + # with set_env(CHPL_HOME=self.test_suite.current_test_cache_dir): + # compiler = join_path(self.spec.prefix.bin,'chpl') + # print("Running package module tests for packages...") + # print(f" command to run: util/start_test --compiler {compiler}") + # tests_to_run.insert(0, "util/start_test") + # tests_to_run.insert(1, "--compiler") + # tests_to_run.insert(2, compiler) + # res = subprocess.run([t for t in tests_to_run]) + # assert res.returncode == 0 + + @run_after("install") + def copy_test_files(self): + """Copy test files to the install directory""" + test_files = [ + "test/release/examples", + "util/start_test", + "util/test", + "util/chplenv", + "util/config", + # "test/library/packages/Curl", + # "test/library/packages/URL/", + # "test/library/packages/ProtobufProtocolSupport/", + # "test/library/packages/Crypto/", + # "test/library/packages/Yaml/", + # "test/library/packages/ZMQ/", + # "test/library/packages/HDF5/", + "chplconfig", + "make", + "third-party/chpl-venv/", + ] + cache_extra_test_sources(self, test_files) + + # @run_after("install") + # @on_package_attributes(run_tests=True) + # def self_check(self): + # """Run the self-check after installing the package""" + # path_put_first("PATH", [self.prefix.bin]) + # self.test_version() + # self.test_hello() + # if self.spec.satisfies("+chpldoc"): + # make("check-chpldoc") + # self.test_package_modules() diff --git a/var/spack/repos/builtin/packages/chaplin/package.py b/var/spack/repos/builtin/packages/chaplin/package.py index 78244802438992..32a4f3629bb918 100644 --- a/var/spack/repos/builtin/packages/chaplin/package.py +++ b/var/spack/repos/builtin/packages/chaplin/package.py @@ -20,3 +20,5 @@ class Chaplin(AutotoolsPackage): maintainers("vvolkl") version("1.2", sha256="f17c2d985fd4e4ce36cede945450416d3fa940af68945c91fa5d3ca1d76d4b49") + + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/charliecloud/package.py b/var/spack/repos/builtin/packages/charliecloud/package.py index 0e8f9835454d97..0bc1f030c5d993 100644 --- a/var/spack/repos/builtin/packages/charliecloud/package.py +++ b/var/spack/repos/builtin/packages/charliecloud/package.py @@ -19,6 +19,8 @@ class Charliecloud(AutotoolsPackage): license("Apache-2.0") version("master", branch="master") + version("0.37", sha256="1fd8e7cd1dd09a001aead5e105e3234792c1a1e9e30417f495ab3f422ade7397") + version("0.36", sha256="b6b1a085d8ff82abc6d625ab990af3925c84fa08ec837828b383f329bd0b8e72") version("0.35", sha256="042f5be5ed8eda95f45230b4647510780142a50adb4e748be57e8dd8926b310e") version( "0.34", @@ -100,8 +102,10 @@ class Charliecloud(AutotoolsPackage): deprecated=True, sha256="15ce63353afe1fc6bcc10979496a54fcd5628f997cb13c827c9fc7afb795bdc5", ) + + depends_on("c", type="build") # generated variant("docs", default=False, description="Build man pages and html docs") - variant("squashfuse", default=False, description="Build with squashfuse support") + variant("squashfuse", default=True, description="Build with squashfuse support", when="@0.32:") # Autoconf. depends_on("m4", type="build") @@ -109,6 +113,9 @@ class Charliecloud(AutotoolsPackage): depends_on("automake", type="build") depends_on("libtool", type="build") + # pkg-config is required for 0.36 regardless of variant. + depends_on("pkgconfig", type="build", when="@0.36") + # Image manipulation. depends_on("python@3.6:", type="run") depends_on("py-requests", type="run") @@ -121,7 +128,8 @@ class Charliecloud(AutotoolsPackage): depends_on("py-sphinx-rtd-theme", type="build", when="+docs") # Bash automated testing harness (bats). - depends_on("bats@0.4.0", type="test") + depends_on("bats@0.4.0", when="@:0.32") + depends_on("bats@1.10.0:", when="@0.33:") # Require pip and wheel for git checkout builds (master). depends_on("py-pip@21.1.2:", type="build", when="@master") @@ -130,9 +138,20 @@ class Charliecloud(AutotoolsPackage): # See https://github.com/spack/spack/pull/16049. conflicts("platform=darwin", msg="This package does not build on macOS") - # Squashfuse support - depends_on("squashfuse@0.1.105:", when="+squashfuse") - depends_on("squashfs", type="run", when="+squashfuse") + # Squashfuse support. For why this is so messy, see: + # https://github.com/hpc/charliecloud/issues/1696 + # https://github.com/hpc/charliecloud/pull/1697 + # https://github.com/hpc/charliecloud/pull/1784 + # + # FIXME: the current variant and dependencies reflect + # Charliecloud's automatic mount/un-mounting requirements. A more manual + # approach with squashfuse could implemented in a different variant. + with when("+squashfuse"): + depends_on("libfuse@3:", type=("build", "run", "link"), when="@0.32:") + depends_on("pkgconfig", type="build", when="@0.37:") + depends_on("squashfuse@0.1.105:0.2.0,0.4.0:", type="build", when="@0.36:") + depends_on("squashfuse@0.1.105:0.2.0,0.4.0", type="build", when="@0.35") + depends_on("squashfuse@0.1.105", type="build", when="@0.32:0.34") def autoreconf(self, spec, prefix): which("bash")("autogen.sh") diff --git a/var/spack/repos/builtin/packages/charmpp/ofi-crayshasta-arm.patch b/var/spack/repos/builtin/packages/charmpp/ofi-crayshasta-arm.patch new file mode 100644 index 00000000000000..ce21509fb585db --- /dev/null +++ b/var/spack/repos/builtin/packages/charmpp/ofi-crayshasta-arm.patch @@ -0,0 +1,13 @@ +diff --git a/src/arch/ofi-crayshasta/conv-mach.h b/src/arch/ofi-crayshasta/conv-mach.h +index 61d295df3..9e15fd2a9 100644 +--- a/src/arch/ofi-crayshasta/conv-mach.h ++++ b/src/arch/ofi-crayshasta/conv-mach.h +@@ -74,7 +74,7 @@ + #define CMK_LBDB_ON 1 + + #define CMK_64BIT 1 +-#define CMK_AMD64 1 ++#define CMK_ARM 1 + + /* Other possible definitions: + diff --git a/var/spack/repos/builtin/packages/charmpp/package.py b/var/spack/repos/builtin/packages/charmpp/package.py index 637b111dac7a21..5d0e230d68607f 100644 --- a/var/spack/repos/builtin/packages/charmpp/package.py +++ b/var/spack/repos/builtin/packages/charmpp/package.py @@ -26,6 +26,11 @@ class Charmpp(Package): version("main", branch="main") + version( + "8.0.0", + sha256="e30fc1e921e5cbf3406e792d5b0ca5f211c5d8ffbfc56e56d5501d8118abcaf6", + url="https://github.com/charmplusplus/charm/archive/refs/tags/v8.0.0.tar.gz", + ) version("7.0.0", sha256="9c247b421bb157bdf9bc0ced3e25738c7a1dc1f7ec57b7943a7faf97f7e4fb2e") version("6.10.2", sha256="7abb4cace8aebdfbb8006eac03eb766897c009cfb919da0d0a33f74c3b4e6deb") version("6.10.1", sha256="ab96198105daabbb8c8bdf370f87b0523521ce502c656cb6cd5b89f69a2c70a8") @@ -40,6 +45,10 @@ class Charmpp(Package): version("6.6.0", sha256="c916010f2d4cc2c6bd30ea19764839d0298fb56d1696d8ff08d9fa9a61dfb1c9") version("6.5.1", sha256="68aa43e2a6e476e116a7e80e385c25c6ac6497807348025505ba8bfa256ed34a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Support OpenMPI; see # # Patch is no longer needed in versions 6.8.0+ @@ -58,6 +67,9 @@ class Charmpp(Package): # Ignore compiler warnings while configuring patch("strictpass.patch", when="@:6.8.2") + # Support Cray Shasta with ARM + patch("ofi-crayshasta-arm.patch", when="backend=ofi pmi=cray-pmi target=aarch64:") + # Build targets # "target" is reserved, so we have to use something else. variant( @@ -86,7 +98,7 @@ class Charmpp(Package): variant( "pmi", default="none", - values=("none", "simplepmi", "slurmpmi", "slurmpmi2", "pmix"), + values=("none", "simplepmi", "slurmpmi", "slurmpmi2", "pmix", "cray-pmi"), description="The ucx/ofi/gni backends need PMI to run!", ) @@ -112,6 +124,7 @@ class Charmpp(Package): depends_on("cuda", when="+cuda") depends_on("ucx", when="backend=ucx") + depends_on("libfabric", when="backend=ofi") depends_on("slurm@:17-11-9-2", when="pmi=slurmpmi") depends_on("slurm@17-11-9-2:", when="pmi=slurmpmi2") @@ -123,6 +136,7 @@ class Charmpp(Package): depends_on("mpi", when="pmi=simplepmi") depends_on("mpi", when="pmi=slurmpmi") depends_on("mpi", when="pmi=slurmpmi2") + depends_on("cray-mpich", when="pmi=cray-pmi") # Git versions of Charm++ require automake and autoconf depends_on("automake", when="@develop") @@ -180,7 +194,6 @@ def charmarch(self): ("linux", "x86_64", "netlrts"): "netlrts-linux-x86_64", ("linux", "x86_64", "verbs"): "verbs-linux-x86_64", ("linux", "x86_64", "ofi"): "ofi-linux-x86_64", - ("linux", "x86_64", "ucx"): "ucx-linux-x86_64", ("linux", "ppc", "mpi"): "mpi-linux-ppc", ("linux", "ppc", "multicore"): "multicore-linux-ppc", ("linux", "ppc", "netlrts"): "netlrts-linux-ppc", @@ -195,29 +208,56 @@ def charmarch(self): ("cnl", "x86_64", "mpi"): "mpi-crayxc", } + if self.spec.satisfies("@6.10:"): + versions.update( + { + ("linux", "x86_64", "ucx"): "ucx-linux-x86_64", + ("linux", "aarch64", "ucx"): "ucx-linux-arm8", + } + ) + # Some versions were renamed/removed in 6.11 if self.spec.version < Version("6.11.0"): - versions.update({("linux", "i386", "mpi"): "mpi-linux"}) - versions.update({("linux", "i386", "multicore"): "multicore-linux"}) - versions.update({("linux", "i386", "netlrts"): "netlrts-linux"}) - versions.update({("linux", "i386", "uth"): "uth-linux"}) versions.update( { + ("linux", "i386", "mpi"): "mpi-linux", + ("linux", "i386", "multicore"): "multicore-linux", + ("linux", "i386", "netlrts"): "netlrts-linux", + ("linux", "i386", "uth"): "uth-linux", ("linux", "arm", "multicore"): "multicore-arm7", ("linux", "aarch64", "multicore"): "multicore-arm8", } ) else: - versions.update({("linux", "i386", "mpi"): "mpi-linux-i386"}) - versions.update({("linux", "i386", "multicore"): "multicore-linux-i386"}) - versions.update({("linux", "i386", "netlrts"): "netlrts-linux-i386"}) versions.update( { + ("linux", "i386", "mpi"): "mpi-linux-i386", + ("linux", "i386", "multicore"): "multicore-linux-i386", + ("linux", "i386", "netlrts"): "netlrts-linux-i386", ("linux", "arm", "multicore"): "multicore-linux-arm7", ("linux", "aarch64", "multicore"): "multicore-linux-arm8", } ) + if self.spec.satisfies("@7:"): + versions.update( + { + ("linux", "arm", "mpi"): "mpi-linux-arm7", + ("linux", "aarch64", "mpi"): "mpi-linux-arm8", + ("darwin", "arm", "multicore"): "multicore-darwin-arm8", + ("darwin", "arm", "netlrts"): "netlrts-darwin-arm8", + ("darwin", "arm", "mpi"): "mpi-darwin-arm8", + } + ) + + if self.spec.satisfies("backend=ofi pmi=cray-pmi"): + versions.update( + { + ("linux", "x86_64", "ofi"): "ofi-crayshasta", + ("linux", "aarch64", "ofi"): "ofi-crayshasta", + } + ) + if (plat, mach, comm) not in versions: raise InstallError( "The communication mechanism %s is not supported " @@ -394,4 +434,4 @@ def setup_dependent_package(self, module, dependent_spec): self.spec.mpicxx = self.prefix.bin.ampicxx self.spec.mpifc = self.prefix.bin.ampif90 self.spec.mpif77 = self.prefix.bin.ampif77 - self.spec.charmarch = self.charmarch + self.spec.charmarch = self.charmarch + "-smp" if self.spec.satisfies("+smp") else "" diff --git a/var/spack/repos/builtin/packages/chatterbug/package.py b/var/spack/repos/builtin/packages/chatterbug/package.py index eddb9e3a9b8964..b7fff4fc1c2314 100644 --- a/var/spack/repos/builtin/packages/chatterbug/package.py +++ b/var/spack/repos/builtin/packages/chatterbug/package.py @@ -23,6 +23,8 @@ class Chatterbug(MakefilePackage): version("develop", branch="master") version("1.0", tag="v1.0", commit="ee1b13c634943dbe32ac22f5e2154b00eab8c574") + depends_on("cxx", type="build") # generated + variant("scorep", default=False, description="Build with Score-P tracing") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/check/package.py b/var/spack/repos/builtin/packages/check/package.py index b2c2900fd7600b..e256b0008a7742 100644 --- a/var/spack/repos/builtin/packages/check/package.py +++ b/var/spack/repos/builtin/packages/check/package.py @@ -23,3 +23,5 @@ class Check(AutotoolsPackage): version("0.12.0", sha256="464201098bee00e90f5c4bdfa94a5d3ead8d641f9025b560a27755a83b824234") version("0.11.0", sha256="24f7a48aae6b74755bcbe964ce8bc7240f6ced2141f8d9cf480bc3b3de0d5616") version("0.10.0", sha256="f5f50766aa6f8fe5a2df752666ca01a950add45079aa06416b83765b1cf71052") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/chemfiles/package.py b/var/spack/repos/builtin/packages/chemfiles/package.py index 148e806d6a456a..e098a4f2d1f6fc 100644 --- a/var/spack/repos/builtin/packages/chemfiles/package.py +++ b/var/spack/repos/builtin/packages/chemfiles/package.py @@ -21,6 +21,9 @@ class Chemfiles(CMakePackage): version("0.10.4", sha256="b8232ddaae2953538274982838aa6c2df87d300f7e2f80e92c171581e06325ba") version("0.10.3", sha256="5f53d87a668a85bebf04e0e8ace0f1db984573de1c54891ba7d37d31cced0408") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=False, description="Build shared libraries") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/chgcentre/package.py b/var/spack/repos/builtin/packages/chgcentre/package.py index 4ad3cbffa3801c..19da180caed8fe 100644 --- a/var/spack/repos/builtin/packages/chgcentre/package.py +++ b/var/spack/repos/builtin/packages/chgcentre/package.py @@ -16,6 +16,8 @@ class Chgcentre(CMakePackage): version("1.6", sha256="5b14f9f56b900072c42dab2a8217cd399fb1bb50aae20f9e3b6ff30ec5b12008") + depends_on("cxx", type="build") # generated + depends_on("casacore") depends_on("gsl") diff --git a/var/spack/repos/builtin/packages/chombo/package.py b/var/spack/repos/builtin/packages/chombo/package.py index f28606aad3b02d..73a03560b242b7 100644 --- a/var/spack/repos/builtin/packages/chombo/package.py +++ b/var/spack/repos/builtin/packages/chombo/package.py @@ -25,6 +25,10 @@ class Chombo(MakefilePackage): version("3.2", commit="71d856c2f469e96755a606db1e5151067da0f54a") version("develop", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI parallel support") variant("hdf5", default=True, description="Enable HDF5 support") variant( diff --git a/var/spack/repos/builtin/packages/chrony/package.py b/var/spack/repos/builtin/packages/chrony/package.py index 1219b0c0cbc83f..c50f87a2b2f694 100644 --- a/var/spack/repos/builtin/packages/chrony/package.py +++ b/var/spack/repos/builtin/packages/chrony/package.py @@ -22,6 +22,8 @@ class Chrony(AutotoolsPackage): version("3.4", sha256="85fbe433f5a3ee961a20c47a72367760b074448587a9e2d3a6788a95750ed77e") version("3.3", sha256="0dd7323b5ed9e3208236c1b39fcabf2ad03469fa07ac516ba9c682206133f66d") + depends_on("c", type="build") # generated + depends_on("ruby-asciidoctor") depends_on("bison", type="build") diff --git a/var/spack/repos/builtin/packages/chrpath/package.py b/var/spack/repos/builtin/packages/chrpath/package.py index fe0c081d7faa6e..0010c2377d98ee 100644 --- a/var/spack/repos/builtin/packages/chrpath/package.py +++ b/var/spack/repos/builtin/packages/chrpath/package.py @@ -16,3 +16,5 @@ class Chrpath(AutotoolsPackage): license("GPL-2.0-or-later") version("0.16", sha256="bb0d4c54bac2990e1bdf8132f2c9477ae752859d523e141e72b3b11a12c26e7b") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/circe2/package.py b/var/spack/repos/builtin/packages/circe2/package.py index 5b42f60d607e15..eb7067e0b3866d 100644 --- a/var/spack/repos/builtin/packages/circe2/package.py +++ b/var/spack/repos/builtin/packages/circe2/package.py @@ -24,6 +24,8 @@ class Circe2(AutotoolsPackage): version("3.1.2.1", sha256="8bb09e6f566adefcf7b5b1cf9d9fe4536dd3dd11ed3674861de29e177ee0bb04") + depends_on("fortran", type="build") # generated + variant("doc", default=False, description="Create the latex documentation") depends_on("ocaml@4.05:") diff --git a/var/spack/repos/builtin/packages/citcoms/package.py b/var/spack/repos/builtin/packages/citcoms/package.py index 0e83ec33cd644b..ae71db7661a662 100644 --- a/var/spack/repos/builtin/packages/citcoms/package.py +++ b/var/spack/repos/builtin/packages/citcoms/package.py @@ -22,6 +22,9 @@ class Citcoms(AutotoolsPackage): version("3.3.1", sha256="e3520e0a933e4699d31e86fe309b8c154ea6ecb0f42a1cf6f25e8d13d825a4b3") version("3.2.0", sha256="773a14d91ecbb4a4d1e04317635fab79819d83c57b47f19380ff30b9b19cb07a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("ggrd", default=False, description="use GGRD file support") variant("cuda", default=False, description="use CUDA") variant("hdf5", default=False, description="add HDF5 support") diff --git a/var/spack/repos/builtin/packages/cityhash/package.py b/var/spack/repos/builtin/packages/cityhash/package.py index 2929bf09771c11..efa2b2227d50db 100644 --- a/var/spack/repos/builtin/packages/cityhash/package.py +++ b/var/spack/repos/builtin/packages/cityhash/package.py @@ -15,5 +15,7 @@ class Cityhash(AutotoolsPackage): version("master", branch="master") version("2013-07-31", commit="8af9b8c2b889d80c22d6bc26ba0df1afb79a30db") + depends_on("cxx", type="build") # generated + def configure_args(self): return ["--enable-sse4.2"] diff --git a/var/spack/repos/builtin/packages/cjson/package.py b/var/spack/repos/builtin/packages/cjson/package.py index 937044baa5c470..589a3f4762f288 100644 --- a/var/spack/repos/builtin/packages/cjson/package.py +++ b/var/spack/repos/builtin/packages/cjson/package.py @@ -15,4 +15,6 @@ class Cjson(CMakePackage): license("MIT") + version("1.7.18", sha256="cc6d93cc3b659037c34193ecc7be5a874a18c2ac67b24efe82db6a759b486b5d") + version("1.7.17", sha256="51f3b07aece8d1786e74b951fd92556506586cb36670741b6bfb79bf5d484216") version("1.7.15", sha256="c55519316d940757ef93a779f1db1ca809dbf979c551861f339d35aaea1c907c") diff --git a/var/spack/repos/builtin/packages/clamav/package.py b/var/spack/repos/builtin/packages/clamav/package.py index 14e3b0c11b159d..337152762ea8b6 100644 --- a/var/spack/repos/builtin/packages/clamav/package.py +++ b/var/spack/repos/builtin/packages/clamav/package.py @@ -17,6 +17,9 @@ class Clamav(AutotoolsPackage): version("0.101.2", sha256="0a12ebdf6ff7a74c0bde2bdc2b55cae33449e6dd953ec90824a9e01291277634") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("json-c") depends_on("openssl") diff --git a/var/spack/repos/builtin/packages/clamr/package.py b/var/spack/repos/builtin/packages/clamr/package.py index cba0c2cab81a52..b879eeeef3b397 100644 --- a/var/spack/repos/builtin/packages/clamr/package.py +++ b/var/spack/repos/builtin/packages/clamr/package.py @@ -20,6 +20,10 @@ class Clamr(CMakePackage): version("master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "graphics", default="opengl", diff --git a/var/spack/repos/builtin/packages/clapack/package.py b/var/spack/repos/builtin/packages/clapack/package.py index 10e1ce2652656a..84f5500161e17c 100644 --- a/var/spack/repos/builtin/packages/clapack/package.py +++ b/var/spack/repos/builtin/packages/clapack/package.py @@ -22,6 +22,8 @@ class Clapack(MakefilePackage): version("3.2.1", sha256="6dc4c382164beec8aaed8fd2acc36ad24232c406eda6db462bd4c41d5e455fac") + depends_on("c", type="build") # generated + variant("external-blas", default=True, description="Build with external BLAS (ATLAS here).") depends_on("atlas", when="+external-blas") diff --git a/var/spack/repos/builtin/packages/clara/package.py b/var/spack/repos/builtin/packages/clara/package.py index 812ec40305e7b4..fd021efff6b1a6 100644 --- a/var/spack/repos/builtin/packages/clara/package.py +++ b/var/spack/repos/builtin/packages/clara/package.py @@ -33,6 +33,8 @@ class Clara(CMakePackage, Package): version("1.1.1", sha256="10915a49a94d371f05af360d40e9cc9615ab86f200d261edf196a8ddd7efa7f8") version("1.1.0", sha256="29ca29d843150aabad702356f79009f5b30dda05ac9674a064362b7edcba5477") + depends_on("cxx", type="build") # generated + class GenericBuilder(spack.build_systems.generic.GenericBuilder): def install(self, pkg, spec, prefix): diff --git a/var/spack/repos/builtin/packages/claw/package.py b/var/spack/repos/builtin/packages/claw/package.py index 025f216a44b954..913b1b82f6a077 100644 --- a/var/spack/repos/builtin/packages/claw/package.py +++ b/var/spack/repos/builtin/packages/claw/package.py @@ -45,6 +45,10 @@ class Claw(CMakePackage): "1.1.0", tag="v1.1.0", commit="16b165a443b11b025a77cad830b1280b8c9bcf01", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.0:", type="build") depends_on("ant@1.9:", type="build") depends_on("bison", type="build") diff --git a/var/spack/repos/builtin/packages/cleverleaf/package.py b/var/spack/repos/builtin/packages/cleverleaf/package.py index 8f16ba94d24f83..1f0b821b94317e 100644 --- a/var/spack/repos/builtin/packages/cleverleaf/package.py +++ b/var/spack/repos/builtin/packages/cleverleaf/package.py @@ -22,6 +22,9 @@ class Cleverleaf(CMakePackage): version("develop", branch="develop") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("samrai@3.8.0:") depends_on("hdf5+mpi") diff --git a/var/spack/repos/builtin/packages/clfft/package.py b/var/spack/repos/builtin/packages/clfft/package.py index a51360a6085e96..c9cdbb03c75945 100644 --- a/var/spack/repos/builtin/packages/clfft/package.py +++ b/var/spack/repos/builtin/packages/clfft/package.py @@ -17,6 +17,9 @@ class Clfft(CMakePackage): version("2.12.2", sha256="e7348c146ad48c6a3e6997b7702202ad3ee3b5df99edf7ef00bbacc21e897b12") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("client", default=True, description="build client and callback client") depends_on("opencl@1.2:") diff --git a/var/spack/repos/builtin/packages/clhep/package.py b/var/spack/repos/builtin/packages/clhep/package.py index 56796d9433ce24..6328b09c67873e 100644 --- a/var/spack/repos/builtin/packages/clhep/package.py +++ b/var/spack/repos/builtin/packages/clhep/package.py @@ -53,6 +53,8 @@ class Clhep(CMakePackage): version("2.2.0.4", sha256="9bf7fcd9892313c8d1436bc4a4a285a016c4f8e81e1fc65bdf6783207ae57550") version("2.1.2.3", sha256="4353231be09c134507092161cd3ced27a065ca0ebb31ee0256e60a8163c47c3b") + depends_on("cxx", type="build") # generated + variant( "cxxstd", default="11", diff --git a/var/spack/repos/builtin/packages/cli11/package.py b/var/spack/repos/builtin/packages/cli11/package.py index f909bd0e5874b9..8f51db6d1f036f 100644 --- a/var/spack/repos/builtin/packages/cli11/package.py +++ b/var/spack/repos/builtin/packages/cli11/package.py @@ -14,8 +14,9 @@ class Cli11(CMakePackage): url = "https://github.com/CLIUtils/CLI11/archive/v1.9.1.tar.gz" maintainers("nightlark") - license("BitTorrent-1.0") + license("BSD-3-Clause") + version("2.4.1", sha256="73b7ec52261ce8fe980a29df6b4ceb66243bb0b779451dbd3d014cfec9fdbb58") version("2.3.2", sha256="aac0ab42108131ac5d3344a9db0fdf25c4db652296641955720a4fbe52334e22") version("2.3.1", sha256="378da73d2d1d9a7b82ad6ed2b5bda3e7bc7093c4034a1d680a2e009eb067e7b2") version("2.1.1", sha256="d69023d1d0ab6a22be86b4f59d449422bc5efd9121868f4e284d6042e52f682e") @@ -23,8 +24,15 @@ class Cli11(CMakePackage): version("2.0.0", sha256="2c672f17bf56e8e6223a3bfb74055a946fa7b1ff376510371902adb9cb0ab6a3") version("1.9.1", sha256="c780cf8cf3ba5ec2648a7eeb20a47e274493258f38a9b417628e0576f473a50b") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.4:", type="build") def cmake_args(self): - args = ["-DCLI11_BUILD_EXAMPLES=OFF", "-DCLI11_BUILD_DOCS=OFF", "-DCLI11_BUILD_TESTS=OFF"] + args = [ + self.define("CLI11_BUILD_EXAMPLES", False), + self.define("CLI11_BUILD_DOCS", False), + self.define("CLI11_BUILD_TESTS", False), + self.define("CLI11_PRECOMPILED", True), + ] return args diff --git a/var/spack/repos/builtin/packages/clinfo/package.py b/var/spack/repos/builtin/packages/clinfo/package.py index 8dc7876d0f4a96..9fc026a1f07a4c 100644 --- a/var/spack/repos/builtin/packages/clinfo/package.py +++ b/var/spack/repos/builtin/packages/clinfo/package.py @@ -28,6 +28,8 @@ class Clinfo(MakefilePackage): "2.2.18.04.06", sha256="f77021a57b3afcdebc73107e2254b95780026a9df9aa4f8db6aff11c03f0ec6c" ) + depends_on("c", type="build") # generated + depends_on("opencl") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/clingo-bootstrap/package.py b/var/spack/repos/builtin/packages/clingo-bootstrap/package.py index a11ff0a0484146..1b56df15901a55 100644 --- a/var/spack/repos/builtin/packages/clingo-bootstrap/package.py +++ b/var/spack/repos/builtin/packages/clingo-bootstrap/package.py @@ -32,13 +32,6 @@ class ClingoBootstrap(Clingo): description="Enable a series of Spack-specific optimizations (PGO, LTO, mimalloc)", ) - variant( - "force_setuptools", - default=False, - description="Force a dependency on setuptools to help the old concretizer", - ) - depends_on("py-setuptools", type="build", when="+force_setuptools") - # Enable LTO conflicts("~ipo", when="+optimized") @@ -65,12 +58,6 @@ class ClingoBootstrap(Clingo): when="platform=linux", msg="GCC or clang are required to bootstrap clingo on Linux", ) - requires( - "%gcc", - "%clang", - when="platform=cray", - msg="GCC or clang are required to bootstrap clingo on Cray", - ) conflicts("%gcc@:5", msg="C++14 support is required to bootstrap clingo") # On Darwin we bootstrap with Apple Clang @@ -127,9 +114,7 @@ def pgo_train(self): ) python_runtime_env.unset("SPACK_ENV") python_runtime_env.unset("SPACK_PYTHON") - self.spec["python"].command( - spack.paths.spack_script, "solve", "--fresh", "hdf5", extra_env=python_runtime_env - ) + python(spack.paths.spack_script, "solve", "--fresh", "hdf5", extra_env=python_runtime_env) # Clean the build dir. rmtree(self.build_directory, ignore_errors=True) diff --git a/var/spack/repos/builtin/packages/clingo/package.py b/var/spack/repos/builtin/packages/clingo/package.py index 83178781d8f32e..eb3951695e53e5 100644 --- a/var/spack/repos/builtin/packages/clingo/package.py +++ b/var/spack/repos/builtin/packages/clingo/package.py @@ -3,8 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import os - from spack.compiler import UnsupportedCompilerFlag from spack.package import * @@ -41,13 +39,15 @@ class Clingo(CMakePackage): version("5.3.0", sha256="b0d406d2809352caef7fccf69e8864d55e81ee84f4888b0744894977f703f976") version("5.2.2", sha256="da1ef8142e75c5a6f23c9403b90d4f40b9f862969ba71e2aaee9a257d058bfcf") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("docs", default=False, description="build documentation with Doxygen") variant("python", default=True, description="build with python bindings") # See https://github.com/potassco/clingo/blob/v5.5.2/INSTALL.md depends_on("cmake@3.1:", type="build") depends_on("cmake@3.18:", type="build", when="@5.5:") - depends_on("py-setuptools", when="@5.6.2:", type="build") depends_on("doxygen", type="build", when="+docs") @@ -56,7 +56,6 @@ class Clingo(CMakePackage): depends_on("bison@2.5:", type="build", when="platform=linux") depends_on("bison@2.5:", type="build", when="platform=darwin") depends_on("bison@2.5:", type="build", when="platform=freebsd") - depends_on("bison@2.5:", type="build", when="platform=cray") with when("platform=windows"): depends_on("re2c@0.13:", type="build") @@ -70,7 +69,6 @@ class Clingo(CMakePackage): depends_on("py-cffi", type=("build", "run"), when="@5.5.0: platform=linux") depends_on("py-cffi", type=("build", "run"), when="@5.5.0: platform=darwin") depends_on("py-cffi", type=("build", "run"), when="@5.5.0: platform=freebsd") - depends_on("py-cffi", type=("build", "run"), when="@5.5.0: platform=cray") patch("python38.patch", when="@5.3:5.4.0") patch("size-t.patch", when="%msvc") @@ -83,12 +81,6 @@ class Clingo(CMakePackage): patch("setuptools-2.patch") depends_on("py-setuptools", type="build") - # TODO: Simplify this after Spack 0.21 release. The old concretizer has problems with - # py-setuptools ^python@3.6, so we only apply the distutils -> setuptools patch for Python 3.12 - with when("@:5.6.1 ^python@3.12:"): - patch("setuptools.patch") - depends_on("py-setuptools", type="build") - def patch(self): # Doxygen is optional but can't be disabled with a -D, so patch # it out if it's really supposed to be disabled @@ -110,28 +102,30 @@ def cmake_args(self): except UnsupportedCompilerFlag: InstallError("clingo requires a C++14-compliant C++ compiler") - args = ["-DCLINGO_BUILD_WITH_LUA=OFF"] + args = [self.define("CLINGO_BUILD_WITH_LUA", False)] if "+python" in self.spec: + suffix = python( + "-c", "import sysconfig; print(sysconfig.get_config_var('EXT_SUFFIX'))", output=str + ).strip() args += [ - "-DCLINGO_REQUIRE_PYTHON=ON", - "-DCLINGO_BUILD_WITH_PYTHON=ON", - "-DPYCLINGO_USER_INSTALL=OFF", - "-DPYCLINGO_USE_INSTALL_PREFIX=ON", + self.define("CLINGO_REQUIRE_PYTHON", True), + self.define("CLINGO_BUILD_WITH_PYTHON", True), + self.define("PYCLINGO_USER_INSTALL", False), + self.define("PYCLINGO_USE_INSTALL_PREFIX", True), + self.define("PYCLINGO_INSTALL_DIR", python_platlib), + self.define("PYCLINGO_SUFFIX", suffix), self.cmake_py_shared, ] else: - args += ["-DCLINGO_BUILD_WITH_PYTHON=OFF"] + args += [self.define("CLINGO_BUILD_WITH_PYTHON", False)] # Use LTO also for non-Intel compilers please. This can be removed when they # bump cmake_minimum_required to VERSION 3.9. if "+ipo" in self.spec: - args.append("-DCMAKE_POLICY_DEFAULT_CMP0069=NEW") + args.append(self.define("CMAKE_POLICY_DEFAULT_CMP0069", "NEW")) return args def win_add_library_dependent(self): - if "+python" in self.spec: - return [os.path.join(self.prefix, self.spec["python"].package.platlib)] - else: - return [] + return [python_platlib] if "+python" in self.spec else [] diff --git a/var/spack/repos/builtin/packages/clingo/setuptools-2.patch b/var/spack/repos/builtin/packages/clingo/setuptools-2.patch deleted file mode 100644 index 6c6377936fb420..00000000000000 --- a/var/spack/repos/builtin/packages/clingo/setuptools-2.patch +++ /dev/null @@ -1,8 +0,0 @@ -diff --git a/cmake/python-site.py b/cmake/python-site.py ---- a/cmake/python-site.py -+++ b/cmake/python-site.py -@@ -1,3 +1,4 @@ -+import setuptools # makes import distutils work - from distutils.sysconfig import get_python_lib, get_config_vars - import sys - if sys.argv[1] == "prefix": \ No newline at end of file diff --git a/var/spack/repos/builtin/packages/cln/package.py b/var/spack/repos/builtin/packages/cln/package.py index b5ce6793e9340a..f5a61e1148ef19 100644 --- a/var/spack/repos/builtin/packages/cln/package.py +++ b/var/spack/repos/builtin/packages/cln/package.py @@ -33,6 +33,9 @@ class Cln(AutotoolsPackage): version("1.2.1", commit="567378ab4cbfd443c3d82d810599860c769251fe") version("1.2.0", commit="679a0a8927f011fb32411f8a31070c77a9901094") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("gmp", default=True, description="Enable GMP multiprecision library") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/cloc/package.py b/var/spack/repos/builtin/packages/cloc/package.py index 1a3d557823003c..ce99e6b8803fbe 100644 --- a/var/spack/repos/builtin/packages/cloc/package.py +++ b/var/spack/repos/builtin/packages/cloc/package.py @@ -23,6 +23,10 @@ class Cloc(Package): version("1.80", sha256="082f53530eee3f9ee84ec449eca59a77ff114250cd7daf9519679537b5b21d67") version("1.74", sha256="55ac423d5766c74236700a47838ed66bea47ba42e1d594fdd894074ba3eb0567") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("perl") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/cloog/package.py b/var/spack/repos/builtin/packages/cloog/package.py index f18ba78ebc0b8c..191ea89fe53718 100644 --- a/var/spack/repos/builtin/packages/cloog/package.py +++ b/var/spack/repos/builtin/packages/cloog/package.py @@ -21,6 +21,9 @@ class Cloog(Package): version("0.18.0", sha256="1c4aa8dde7886be9cbe0f9069c334843b21028f61d344a2d685f88cb1dcf2228") version("0.17.0", sha256="f265f5069830c03d2919a7673c0963495437d6d79a8cbd3474cde2d4e3291e04") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("gmp") depends_on("isl") diff --git a/var/spack/repos/builtin/packages/cloverleaf-ref/package.py b/var/spack/repos/builtin/packages/cloverleaf-ref/package.py index 77456edb165562..a2b7ce586882cc 100644 --- a/var/spack/repos/builtin/packages/cloverleaf-ref/package.py +++ b/var/spack/repos/builtin/packages/cloverleaf-ref/package.py @@ -26,6 +26,9 @@ class CloverleafRef(MakefilePackage): "1.1", sha256="0ac87accf81d85b959e5da839e6b0659afb3a2840a13f5da113a1c34eeb87942" ) # commit "5667c3a" + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "ieee", default=False, description="Build with IEEE754 compliant floating point operations" ) diff --git a/var/spack/repos/builtin/packages/cloverleaf/package.py b/var/spack/repos/builtin/packages/cloverleaf/package.py index 4848130837c1b9..2fa6a9a2c744b1 100644 --- a/var/spack/repos/builtin/packages/cloverleaf/package.py +++ b/var/spack/repos/builtin/packages/cloverleaf/package.py @@ -24,6 +24,10 @@ class Cloverleaf(MakefilePackage): version("master", branch="master", submodules=True) version("1.1", sha256="de87f7ee6b917e6b3d243ccbbe620370c62df890e3ef7bdbab46569b57be132f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "build", default="ref", diff --git a/var/spack/repos/builtin/packages/cloverleaf3d/package.py b/var/spack/repos/builtin/packages/cloverleaf3d/package.py index 5eb8bcef88046a..9b7ba8a2c751a5 100644 --- a/var/spack/repos/builtin/packages/cloverleaf3d/package.py +++ b/var/spack/repos/builtin/packages/cloverleaf3d/package.py @@ -25,6 +25,10 @@ class Cloverleaf3d(MakefilePackage): version("1.0", sha256="78d591728c61bdfd6175b3930df7652e09ed04fbcd01b3fc86fb2aa0f237a8ef") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("opencl", default=False, description="Enable OpenCL Support") variant("openacc", default=False, description="Enable OpenACC Support") diff --git a/var/spack/repos/builtin/packages/clp/package.py b/var/spack/repos/builtin/packages/clp/package.py index f245a386571113..a60c6e56b53922 100644 --- a/var/spack/repos/builtin/packages/clp/package.py +++ b/var/spack/repos/builtin/packages/clp/package.py @@ -13,16 +13,20 @@ class Clp(AutotoolsPackage): homepage = "https://projects.coin-or.org/Clp" url = "https://github.com/coin-or/Clp/archive/releases/1.17.6.tar.gz" - depends_on("pkgconfig", type="build") - depends_on("coinutils") - depends_on("osi") - depends_on("pkgconfig", type="build") - license("EPL-2.0") + version("1.17.9", sha256="b02109be54e2c9c6babc9480c242b2c3c7499368cfca8c0430f74782a694a49f") version("1.17.7", sha256="c4c2c0e014220ce8b6294f3be0f3a595a37bef58a14bf9bac406016e9e73b0f5") version("1.17.6", sha256="afff465b1620cfcbb7b7c17b5d331d412039650ff471c4160c7eb24ae01284c9") version("1.17.4", sha256="ef412cde00cb1313d9041115a700d8d59d4b8b8b5e4dde43e9deb5108fcfbea8") version("1.16.11", sha256="b525451423a9a09a043e6a13d9436e13e3ee7a7049f558ad41a110742fa65f39") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + depends_on("pkgconfig", type="build") + depends_on("coinutils") + depends_on("osi") + depends_on("pkgconfig", type="build") + build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/clustal-omega/package.py b/var/spack/repos/builtin/packages/clustal-omega/package.py index 3cafd307e6c13d..caf7e1e6e5aa14 100644 --- a/var/spack/repos/builtin/packages/clustal-omega/package.py +++ b/var/spack/repos/builtin/packages/clustal-omega/package.py @@ -16,4 +16,7 @@ class ClustalOmega(AutotoolsPackage): version("1.2.4", sha256="8683d2286d663a46412c12a0c789e755e7fd77088fb3bc0342bb71667f05a3ee") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("argtable") diff --git a/var/spack/repos/builtin/packages/clustalw/package.py b/var/spack/repos/builtin/packages/clustalw/package.py index ece7896b687db4..adf5b8d79b626d 100644 --- a/var/spack/repos/builtin/packages/clustalw/package.py +++ b/var/spack/repos/builtin/packages/clustalw/package.py @@ -15,3 +15,5 @@ class Clustalw(AutotoolsPackage): license("LGPL-3.0-only") version("2.1", sha256="e052059b87abfd8c9e695c280bfba86a65899138c82abccd5b00478a80f49486") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/cmake/mr-9623.patch b/var/spack/repos/builtin/packages/cmake/mr-9623.patch new file mode 100644 index 00000000000000..c36e22c59f4315 --- /dev/null +++ b/var/spack/repos/builtin/packages/cmake/mr-9623.patch @@ -0,0 +1,67 @@ +diff --git a/Source/cmELF.cxx b/Source/cmELF.cxx +index a71e5f1280..003f47b439 100644 +--- a/Source/cmELF.cxx ++++ b/Source/cmELF.cxx +@@ -112,6 +112,9 @@ public: + virtual bool IsMips() const = 0; + virtual void PrintInfo(std::ostream& os) const = 0; + ++ /** Returns true if the ELF file has a dynamic section **/ ++ bool HasDynamicSection() const { return this->DynamicSectionIndex >= 0; } ++ + // Lookup the SONAME in the DYNAMIC section. + StringEntry const* GetSOName() + { +@@ -461,7 +464,7 @@ template + bool cmELFInternalImpl::LoadDynamicSection() + { + // If there is no dynamic section we are done. +- if (this->DynamicSectionIndex < 0) { ++ if (!this->HasDynamicSection()) { + return false; + } + +@@ -772,6 +775,11 @@ std::vector cmELF::EncodeDynamicEntries( + return std::vector(); + } + ++bool cmELF::HasDynamicSection() const ++{ ++ return this->Valid() && this->Internal->HasDynamicSection(); ++} ++ + bool cmELF::GetSOName(std::string& soname) + { + if (StringEntry const* se = this->GetSOName()) { +diff --git a/Source/cmELF.h b/Source/cmELF.h +index ce8bd7fb92..dd37c65302 100644 +--- a/Source/cmELF.h ++++ b/Source/cmELF.h +@@ -88,6 +88,9 @@ public: + std::vector EncodeDynamicEntries( + const DynamicEntryList& entries) const; + ++ /** Returns true if the ELF file has a dynamic section **/ ++ bool HasDynamicSection() const; ++ + /** Get the SONAME field if any. */ + bool GetSOName(std::string& soname); + StringEntry const* GetSOName(); +diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx +index 093a18b82b..3affef0394 100644 +--- a/Source/cmSystemTools.cxx ++++ b/Source/cmSystemTools.cxx +@@ -2817,6 +2817,10 @@ cm::optional AdjustRPathELF(std::string const& file, + return cm::nullopt; // Not a valid ELF file. + } + ++ if (!elf.HasDynamicSection()) { ++ return true; // No dynamic section to update. ++ } ++ + // Get the RPATH and RUNPATH entries from it. + int se_count = 0; + cmELF::StringEntry const* se[2] = { nullptr, nullptr }; +-- +2.40.1 + diff --git a/var/spack/repos/builtin/packages/cmake/package.py b/var/spack/repos/builtin/packages/cmake/package.py index ab2366982d3270..b8b3c424c8f422 100644 --- a/var/spack/repos/builtin/packages/cmake/package.py +++ b/var/spack/repos/builtin/packages/cmake/package.py @@ -29,6 +29,10 @@ class Cmake(Package): license("BSD-3-Clause") version("master", branch="master") + version("3.29.6", sha256="1391313003b83d48e2ab115a8b525a557f78d8c1544618b48d1d90184a10f0af") + version("3.29.5", sha256="dd63da7d763c0db455ca232f2c443f5234fe0b11f8bd6958a81d29cc987dfd6e") + version("3.29.4", sha256="b1b48d7100bdff0b46e8c8f6a3c86476dbe872c8df39c42b8d104298b3d56a2c") + version("3.28.6", sha256="c39c733900affc4eb0e9688b4d1a45435a732105d9bf9cc1e75dd2b9b81a36bb") version("3.27.9", sha256="609a9b98572a6a5ea477f912cffb973109ed4d0a6a6b3f9e2353d2cdc048708e") version("3.26.6", sha256="070b9a2422e666d2c1437e2dab239a236e8a63622d0a8d0ffe9e389613d2b76a") version("3.25.3", sha256="cc995701d590ca6debc4245e9989939099ca52827dd46b5d3592f093afe1901c") @@ -60,321 +64,45 @@ class Cmake(Package): with default_args(deprecated=True): version( - "3.27.8", sha256="fece24563f697870fbb982ea8bf17482c9d5f855d8c9bf0b82463d76c9e8d0cc" + "3.29.3", sha256="252aee1448d49caa04954fd5e27d189dd51570557313e7b281636716a238bccb" ) version( - "3.27.7", sha256="08f71a106036bf051f692760ef9558c0577c42ac39e96ba097e7662bd4158d8e" + "3.29.2", sha256="36db4b6926aab741ba6e4b2ea2d99c9193222132308b4dc824d4123cb730352e" ) version( - "3.27.6", sha256="ef3056df528569e0e8956f6cf38806879347ac6de6a4ff7e4105dc4578732cfb" + "3.29.1", sha256="7fb02e8f57b62b39aa6b4cf71e820148ba1a23724888494735021e32ab0eefcc" ) version( - "3.27.4", sha256="0a905ca8635ca81aa152e123bdde7e54cbe764fdd9a70d62af44cad8b92967af" + "3.29.0", sha256="a0669630aae7baa4a8228048bf30b622f9e9fd8ee8cedb941754e9e38686c778" ) version( - "3.27.3", sha256="66afdc0f181461b70b6fedcde9ecc4226c5cd184e7203617c83b7d8e47f49521" + "3.28.4", sha256="eb9c787e078848dc493f4f83f8a4bbec857cd1f38ab6425ce8d2776a9f6aa6fb" ) version( - "3.27.2", sha256="798e50085d423816fe96c9ef8bee5e50002c9eca09fed13e300de8a91d35c211" + "3.28.3", sha256="72b7570e5c8593de6ac4ab433b73eab18c5fb328880460c86ce32608141ad5c1" ) version( - "3.27.1", sha256="b1a6b0135fa11b94476e90f5b32c4c8fad480bf91cf22d0ded98ce22c5132004" + "3.28.2", sha256="1466f872dc1c226f373cf8fba4230ed216a8f108bd54b477b5ccdfd9ea2d124a" ) version( - "3.27.0", sha256="aaeddb6b28b993d0a6e32c88123d728a17561336ab90e0bf45032383564d3cb8" + "3.28.1", sha256="15e94f83e647f7d620a140a7a5da76349fc47a1bfed66d0f5cdee8e7344079ad" ) version( - "3.26.5", sha256="c0970b1e44a7fbca4322997ce05dac521b04748fe424922152faf22d20782bf9" - ) - version( - "3.26.4", sha256="313b6880c291bd4fe31c0aa51d6e62659282a521e695f30d5cc0d25abbd5c208" - ) - version( - "3.26.3", sha256="bbd8d39217509d163cb544a40d6428ac666ddc83e22905d3e52c925781f0f659" - ) - version( - "3.26.2", sha256="d54f25707300064308ef01d4d21b0f98f508f52dda5d527d882b9d88379f89a8" - ) - version( - "3.26.1", sha256="f29964290ad3ced782a1e58ca9fda394a82406a647e24d6afd4e6c32e42c412f" - ) - version( - "3.26.0", sha256="4256613188857e95700621f7cdaaeb954f3546a9249e942bc2f9b3c26e381365" - ) - version( - "3.25.2", sha256="c026f22cb931dd532f648f087d587f07a1843c6e66a3dfca4fb0ea21944ed33c" - ) - version( - "3.25.1", sha256="1c511d09516af493694ed9baf13c55947a36389674d657a2d5e0ccedc6b291d8" - ) - version( - "3.25.0", sha256="306463f541555da0942e6f5a0736560f70c487178b9d94a5ae7f34d0538cdd48" - ) - version( - "3.24.3", sha256="b53aa10fa82bff84ccdb59065927b72d3bee49f4d86261249fc0984b3b367291" - ) - version( - "3.24.2", sha256="0d9020f06f3ddf17fb537dc228e1a56c927ee506b486f55fe2dc19f69bf0c8db" - ) - version( - "3.24.1", sha256="4931e277a4db1a805f13baa7013a7757a0cbfe5b7932882925c7061d9d1fa82b" - ) - version( - "3.24.0", sha256="c2b61f7cdecb1576cad25f918a8f42b8685d88a832fd4b62b9e0fa32e915a658" - ) - version( - "3.23.4", sha256="aa8b6c17a5adf04de06e42c06adc7e25b21e4fe8378f44f703a861e5f6ac59c7" - ) - version( - "3.23.3", sha256="06fefaf0ad94989724b56f733093c2623f6f84356e5beb955957f9ce3ee28809" - ) - version( - "3.23.2", sha256="f316b40053466f9a416adf981efda41b160ca859e97f6a484b447ea299ff26aa" - ) - version( - "3.23.1", sha256="33fd10a8ec687a4d0d5b42473f10459bb92b3ae7def2b745dc10b192760869f3" - ) - version( - "3.23.0", sha256="5ab0a12f702f44013be7e19534cd9094d65cc9fe7b2cd0f8c9e5318e0fe4ac82" - ) - version( - "3.22.5", sha256="d3987c3f7759fa0a401c5fcd5076be44a19613bfaa8baee1b5d1835750dc5375" - ) - version( - "3.22.4", sha256="5c55d0b0bc4c191549e3502b8f99a4fe892077611df22b4178cc020626e22a47" - ) - version( - "3.22.3", sha256="9f8469166f94553b6978a16ee29227ec49a2eb5ceb608275dec40d8ae0d1b5a0" + "3.28.0", sha256="e1dcf9c817ae306e73a45c2ba6d280c65cf4ec00dd958eb144adaf117fb58e71" ) + # used in py-cmake, to be removed in Spack 0.23 version( "3.22.2", sha256="3c1c478b9650b107d452c5bd545c72e2fad4e37c09b89a1984b9a2f46df6aced" ) - version( - "3.22.1", sha256="0e998229549d7b3f368703d20e248e7ee1f853910d42704aa87918c213ea82c0" - ) - version( - "3.22.0", sha256="998c7ba34778d2dfdb3df8a695469e24b11e2bfa21fbe41b361a3f45e1c9345e" - ) - version( - "3.21.6", sha256="b7c3ac35ca7ed3cce8c192c9c873e6061aaecc8b2bc564290e629b10bff59f3c" - ) - version( - "3.21.5", sha256="c73587b5ab827d56c09f0a1e256b12743ff200495e31fc9686f2b9dc8a28897f" - ) version( "3.21.4", sha256="d9570a95c215f4c9886dd0f0564ca4ef8d18c30750f157238ea12669c2985978" ) - version( - "3.21.3", sha256="d14d06df4265134ee42c4d50f5a60cb8b471b7b6a47da8e5d914d49dd783794f" - ) - version( - "3.21.2", sha256="94275e0b61c84bb42710f5320a23c6dcb2c6ee032ae7d2a616f53f68b3d21659" - ) - version( - "3.21.1", sha256="fac3915171d4dff25913975d712f76e69aef44bf738ba7b976793a458b4cfed4" - ) - version( - "3.21.0", sha256="4a42d56449a51f4d3809ab4d3b61fd4a96a469e56266e896ce1009b5768bd2ab" - ) - version( - "3.20.5", sha256="12c8040ef5c6f1bc5b8868cede16bb7926c18980f59779e299ab52cbc6f15bb0" - ) - version( - "3.20.4", sha256="87a4060298f2c6bb09d479de1400bc78195a5b55a65622a7dceeb3d1090a1b16" - ) - version( - "3.20.3", sha256="4d008ac3461e271fcfac26a05936f77fc7ab64402156fb371d41284851a651b8" - ) - version( - "3.20.2", sha256="aecf6ecb975179eb3bb6a4a50cae192d41e92b9372b02300f9e8f1d5f559544e" - ) - version( - "3.20.1", sha256="3f1808b9b00281df06c91dd7a021d7f52f724101000da7985a401678dfe035b0" - ) - version( - "3.20.0", sha256="9c06b2ddf7c337e31d8201f6ebcd3bba86a9a033976a9aee207fe0c6971f4755" - ) - version( - "3.19.7", sha256="58a15f0d56a0afccc3cc5371234fce73fcc6c8f9dbd775d898e510b83175588e" - ) - version( - "3.19.6", sha256="ec87ab67c45f47c4285f204280c5cde48e1c920cfcfed1555b27fb3b1a1d20ba" - ) - version( - "3.19.5", sha256="c432296eb5dec6d71eae15d140f6297d63df44e9ffe3e453628d1dc8fc4201ce" - ) - version( - "3.19.4", sha256="7d0232b9f1c57e8de81f38071ef8203e6820fe7eec8ae46a1df125d88dbcc2e1" - ) - version( - "3.19.3", sha256="3faca7c131494a1e34d66e9f8972ff5369e48d419ea8ceaa3dc15b4c11367732" - ) - version( - "3.19.2", sha256="e3e0fd3b23b7fb13e1a856581078e0776ffa2df4e9d3164039c36d3315e0c7f0" - ) - version( - "3.19.1", sha256="1d266ea3a76ef650cdcf16c782a317cb4a7aa461617ee941e389cb48738a3aba" - ) - version( - "3.19.0", sha256="fdda688155aa7e72b7c63ef6f559fca4b6c07382ea6dca0beb5f45aececaf493" - ) - version( - "3.18.5", sha256="080bf24b0f73f4bf3ec368d2be1aa59369b9bb1cd693deeb6f18fe553ca74ab4" - ) - version( - "3.18.4", sha256="597c61358e6a92ecbfad42a9b5321ddd801fc7e7eca08441307c9138382d4f77" - ) - version( - "3.18.3", sha256="2c89f4e30af4914fd6fb5d00f863629812ada848eee4e2d29ec7e456d7fa32e5" - ) - version( - "3.18.2", sha256="5d4e40fc775d3d828c72e5c45906b4d9b59003c9433ff1b36a1cb552bbd51d7e" - ) - version( - "3.18.1", sha256="c0e3338bd37e67155b9d1e9526fec326b5c541f74857771b7ffed0c46ad62508" - ) version( "3.18.0", sha256="83b4ffcb9482a73961521d2bafe4a16df0168f03f56e6624c419c461e5317e29" ) - version( - "3.17.4", sha256="86985d73d0a63ec99c236aab5287316e252164f33d7c4cb160954a980c71f36f" - ) - version( - "3.17.3", sha256="0bd60d512275dc9f6ef2a2865426a184642ceb3761794e6b65bff233b91d8c40" - ) - version( - "3.17.1", sha256="3aa9114485da39cbd9665a0bfe986894a282d5f0882b1dea960a739496620727" - ) - version( - "3.17.0", sha256="b74c05b55115eacc4fa2b77a814981dbda05cdc95a53e279fe16b7b272f00847" - ) - version( - "3.16.8", sha256="177434021132686cb901fea7db9fa2345efe48d566b998961594d5cc346ac588" - ) - version( - "3.16.7", sha256="5f49c95a2933b1800f14840f3a389f4cef0b19093985a35053b43f38ec21358f" - ) - version( - "3.16.6", sha256="6f6ff1a197851b0fa8412ff5de602e6717a4eb9509b2c385b08589c4e7a16b62" - ) - version( - "3.16.5", sha256="5f760b50b8ecc9c0c37135fae5fbf00a2fef617059aa9d61c1bb91653e5a8bfc" - ) - version( - "3.16.4", sha256="9bcc8c114d9da603af9512083ed7d4a39911d16105466beba165ba8fe939ac2c" - ) - version( - "3.16.3", sha256="e54f16df9b53dac30fd626415833a6e75b0e47915393843da1825b096ee60668" - ) - version( - "3.16.2", sha256="8c09786ec60ca2be354c29829072c38113de9184f29928eb9da8446a5f2ce6a9" - ) - version( - "3.16.1", sha256="a275b3168fa8626eca4465da7bb159ff07c8c6cb0fb7179be59e12cbdfa725fd" - ) - version( - "3.16.0", sha256="6da56556c63cab6e9a3e1656e8763ed4a841ac9859fefb63cbe79472e67e8c5f" - ) - version( - "3.15.6", sha256="3fa17992ac97d3fc856ffba5d3b10578744ea5b4736818f01e6067f0253b2db5" - ) - version( - "3.15.5", sha256="fbdd7cef15c0ced06bb13024bfda0ecc0dedbcaaaa6b8a5d368c75255243beb4" - ) - version( - "3.15.4", sha256="8a211589ea21374e49b25fc1fc170e2d5c7462b795f1b29c84dd0e984301ed7a" - ) - version( - "3.15.3", sha256="13958243a01365b05652fa01b21d40fa834f70a9e30efa69c02604e64f58b8f5" - ) - version( - "3.15.2", sha256="539088cb29a68e6d6a8fba5c00951e5e5b1a92c68fa38a83e1ed2f355933f768" - ) - version( - "3.15.1", sha256="18dec548d8f8b04d53c60f9cedcebaa6762f8425339d1e2c889c383d3ccdd7f7" - ) - version( - "3.15.0", sha256="0678d74a45832cacaea053d85a5685f3ed8352475e6ddf9fcb742ffca00199b5" - ) - version( - "3.14.6", sha256="4e8ea11cabe459308671b476469eace1622e770317a15951d7b55a82ccaaccb9" - ) - version( - "3.14.5", sha256="505ae49ebe3c63c595fa5f814975d8b72848447ee13b6613b0f8b96ebda18c06" - ) - version( - "3.14.4", sha256="00b4dc9b0066079d10f16eed32ec592963a44e7967371d2f5077fd1670ff36d9" - ) - version( - "3.14.3", sha256="215d0b64e81307182b29b63e562edf30b3875b834efdad09b3fcb5a7d2f4b632" - ) - version( - "3.14.2", sha256="a3cbf562b99270c0ff192f692139e98c605f292bfdbc04d70da0309a5358e71e" - ) - version( - "3.14.1", sha256="7321be640406338fc12590609c42b0fae7ea12980855c1be363d25dcd76bb25f" - ) - version( - "3.14.0", sha256="aa76ba67b3c2af1946701f847073f4652af5cbd9f141f221c97af99127e75502" - ) - version( - "3.13.4", sha256="fdd928fee35f472920071d1c7f1a6a2b72c9b25e04f7a37b409349aef3f20e9b" - ) - version( - "3.13.3", sha256="665f905036b1f731a2a16f83fb298b1fb9d0f98c382625d023097151ad016b25" - ) - version( - "3.13.2", sha256="c925e7d2c5ba511a69f43543ed7b4182a7d446c274c7480d0e42cd933076ae25" - ) - version( - "3.13.1", sha256="befe1ce6d672f2881350e94d4e3cc809697dd2c09e5b708b76c1dae74e1b2210" - ) - version( - "3.13.0", sha256="4058b2f1a53c026564e8936698d56c3b352d90df067b195cb749a97a3d273c90" - ) - version( - "3.12.3", sha256="acbf13af31a741794106b76e5d22448b004a66485fc99f6d7df4d22e99da164a" - ) - version( - "3.12.2", sha256="0f97485799e51a7070cc11494f3e02349b0fc3a24cc12b082e737bf67a0581a4" - ) - version( - "3.12.1", sha256="c53d5c2ce81d7a957ee83e3e635c8cda5dfe20c9d501a4828ee28e1615e57ab2" - ) - version( - "3.12.0", sha256="d0781a90f6cdb9049d104ac16a150f9350b693498b9dea8a0331e799db6b9d69" - ) - version( - "3.11.3", sha256="287135b6beb7ffc1ccd02707271080bbf14c21d80c067ae2c0040e5f3508c39a" - ) - version( - "3.11.2", sha256="5ebc22bbcf2b4c7a20c4190d42c084cf38680a85b1a7980a2f1d5b4a52bf5248" - ) - version( - "3.11.1", sha256="57bebc6ca4d1d42c6385249d148d9216087e0fda57a47dc5c858790a70217d0c" - ) - version( - "3.11.0", sha256="c313bee371d4d255be2b4e96fd59b11d58bc550a7c78c021444ae565709a656b" - ) - version( - "3.10.2", sha256="80d0faad4ab56de07aa21a7fc692c88c4ce6156d42b0579c6962004a70a3218b" - ) - version( - "3.10.1", sha256="7be36ee24b0f5928251b644d29f5ff268330a916944ef4a75e23ba01e7573284" - ) - version( - "3.10.0", sha256="b3345c17609ea0f039960ef470aa099de9942135990930a57c14575aae884987" - ) - version("3.9.4", sha256="b5d86f12ae0072db520fdbdad67405f799eb728b610ed66043c20a92b4906ca1") - version("3.9.2", sha256="954a5801a456ee48e76f01107c9a4961677dd0f3e115275bbd18410dc22ba3c1") - version("3.9.0", sha256="167701525183dbb722b9ffe69fb525aa2b81798cf12f5ce1c020c93394dfae0f") - version("3.8.1", sha256="ce5d9161396e06501b00e52933783150a87c33080d4bdcef461b5b7fd24ac228") - version("3.8.0", sha256="cab99162e648257343a20f61bcd0b287f5e88e36fcb2f1d77959da60b7f35969") - version("3.7.1", sha256="449a5bce64dbd4d5b9517ebd1a1248ed197add6ad27934478976fd5f1f9330e1") - version("3.6.0", sha256="fd05ed40cc40ef9ef99fac7b0ece2e0b871858a82feade48546f5d2940147670") - version("3.5.1", sha256="93d651a754bcf6f0124669646391dd5774c0fc4d407c384e3ae76ef9a60477e8") - version("3.5.0", sha256="92c83ad8a4fd6224cf6319a60b399854f55b38ebe9d297c942408b792b1a9efa") - version("3.4.0", sha256="a5b82bf6ace6c481cdb911fd5d372a302740cbefd387e05297cb37f7468d1cea") + + depends_on("c", type="build") + depends_on("cxx", type="build") variant( "build_type", @@ -399,10 +127,13 @@ class Cmake(Package): when="@3.15.5", ) + # Statically linked binaries error on install when CMAKE_INSTALL_RPATH is set + # https://gitlab.kitware.com/cmake/cmake/-/merge_requests/9623 + patch("mr-9623.patch", when="@3.22.0:3.30") + depends_on("ninja", when="platform=windows") depends_on("gmake", when="platform=linux") depends_on("gmake", when="platform=darwin") - depends_on("gmake", when="platform=cray") depends_on("gmake", when="platform=freebsd") # We default ownlibs to true because it greatly speeds up the CMake @@ -449,7 +180,7 @@ class Cmake(Package): with when("~ownlibs"): depends_on("expat") # expat/zlib are used in CMake/CTest, so why not require them in libarchive. - for plat in ["darwin", "cray", "linux"]: + for plat in ["darwin", "linux"]: with when("platform=%s" % plat): depends_on("libarchive@3.1.0: xar=expat compression=zlib") depends_on("libarchive@3.3.3:", when="@3.15.0:") diff --git a/var/spack/repos/builtin/packages/cmaq/package.py b/var/spack/repos/builtin/packages/cmaq/package.py index 911fa288943842..fe53a9f446bc77 100644 --- a/var/spack/repos/builtin/packages/cmaq/package.py +++ b/var/spack/repos/builtin/packages/cmaq/package.py @@ -26,5 +26,8 @@ class Cmaq(Package): url="https://github.com/USEPA/CMAQ/archive/CMAQv5.3_27Aug2019.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + def install(self, spec, prefix): install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/cmark/package.py b/var/spack/repos/builtin/packages/cmark/package.py index dbfed121ba741c..80bd320351dfb6 100644 --- a/var/spack/repos/builtin/packages/cmark/package.py +++ b/var/spack/repos/builtin/packages/cmark/package.py @@ -15,9 +15,13 @@ class Cmark(CMakePackage): license("BSD-2-Clause") + version("0.31.0", sha256="bbcb8f8c03b5af33fcfcf11a74e9499f20a9043200b8552f78a6e8ba76e04d11") version("0.29.0", sha256="2558ace3cbeff85610de3bda32858f722b359acdadf0c4691851865bb84924a6") version("0.28.3", sha256="acc98685d3c1b515ff787ac7c994188dadaf28a2d700c10c1221da4199bae1fc") version("0.28.2", sha256="fe4b04fcccb2dc72641096de02a8eefb53059e85f9dd904f0386dc86326cc414") version("0.28.1", sha256="dda7b8b5974815b7cbc8f12f509ad419250571f258ee697db2efe3deae01aaf8") version("0.28.0", sha256="68cf191f4a78494a43b7e1663506635e370f0ba4c67c9ee9518e295685bbfe0e") version("0.27.1", sha256="669b4c19355e8cb90139fdd03b02283b97130e92ea99a104552a2976751446b5") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/cmdlime/package.py b/var/spack/repos/builtin/packages/cmdlime/package.py index 853d997b8049ae..16718fdd66c041 100644 --- a/var/spack/repos/builtin/packages/cmdlime/package.py +++ b/var/spack/repos/builtin/packages/cmdlime/package.py @@ -16,3 +16,5 @@ class Cmdlime(CMakePackage): license("MS-PL") version("2.5.0", sha256="d5188d7f075142fcb546099a4ee2a967f8248109c0bee8c084e0e00f37603481") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/cmdstan/package.py b/var/spack/repos/builtin/packages/cmdstan/package.py index ad2e799d21874c..db56241565961b 100644 --- a/var/spack/repos/builtin/packages/cmdstan/package.py +++ b/var/spack/repos/builtin/packages/cmdstan/package.py @@ -16,6 +16,10 @@ class Cmdstan(MakefilePackage): version("2.30.1", sha256="bab76dcefa7f4c955595c0bf0496770507fc6ab0df5896e8cf8c2db0a17eedb9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("threads", default=True, description="enable thread support") variant("opencl", default=False, description="enable OpenCl support") variant("mpi", default=False, description="enable MPI support") diff --git a/var/spack/repos/builtin/packages/cminpack/package.py b/var/spack/repos/builtin/packages/cminpack/package.py index 735a39fbea8d93..ac9d099f888d2d 100644 --- a/var/spack/repos/builtin/packages/cminpack/package.py +++ b/var/spack/repos/builtin/packages/cminpack/package.py @@ -19,6 +19,9 @@ class Cminpack(CMakePackage): version("master", branch="master") version("1.3.6", sha256="3c07fd21308c96477a2c900032e21d937739c233ee273b4347a0d4a84a32d09f") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=False, description="Build shared libraries") variant("blas", default=True, description="Compile with BLAS") diff --git a/var/spack/repos/builtin/packages/cmocka/package.py b/var/spack/repos/builtin/packages/cmocka/package.py index 2046ada5d72f06..a7fd47b85a3032 100644 --- a/var/spack/repos/builtin/packages/cmocka/package.py +++ b/var/spack/repos/builtin/packages/cmocka/package.py @@ -18,6 +18,8 @@ class Cmocka(CMakePackage): version("1.1.1", sha256="f02ef48a7039aa77191d525c5b1aee3f13286b77a13615d11bc1148753fc0389") version("1.1.0", sha256="e960d3bf1be618634a4b924f18bb4d6f20a825c109a8ad6d1af03913ba421330") + depends_on("c", type="build") # generated + depends_on("cmake@2.6.0:", type="build") parallel = False diff --git a/var/spack/repos/builtin/packages/cmockery/package.py b/var/spack/repos/builtin/packages/cmockery/package.py index 55c531a9800f2c..cae17ca932337b 100644 --- a/var/spack/repos/builtin/packages/cmockery/package.py +++ b/var/spack/repos/builtin/packages/cmockery/package.py @@ -19,6 +19,8 @@ class Cmockery(AutotoolsPackage): version("0.1.1", sha256="a801d17976f781fff6dc49042ff109e55ca4ebe8efb13757fa1a511ca52316be") version("0.1.0", sha256="9e017d48e56ab9d2ebcf5286fa54e37d42fe308d3c01fbc367793da2b9ad95e7") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/cmor/package.py b/var/spack/repos/builtin/packages/cmor/package.py index bb6e6b9689e84d..56db33761540be 100644 --- a/var/spack/repos/builtin/packages/cmor/package.py +++ b/var/spack/repos/builtin/packages/cmor/package.py @@ -17,6 +17,7 @@ class Cmor(AutotoolsPackage): license("BSD-3-Clause") + version("3.8.0", sha256="5f5a44e660104916dd0a3d0d942234db375d2a4ffb4f4113ec88cfdd93f99ef4") version("3.7.2", sha256="5e19a9be8e6a8bd18a2035772732c34b87b3448319bf0b8fa12ccd4a351b8e86") version("3.6.1", sha256="991035a41424f72ea6f0f85653fc13730eb035e63c7dff6ca740aa7a70976fb4") version("3.6.0", sha256="1608904a35106e83d365f27522209c325bd4bfc19d022b1a8abfb12cdf85fe20") @@ -26,6 +27,9 @@ class Cmor(AutotoolsPackage): version("3.2.0", sha256="8d49899549dd4c08197739300d507e6fc2b4a5cfe2bfd3e6b44e8e3eaf79b132") version("3.1.2", sha256="ee58b6d405f081e4e0633af931b7992f1a570953b71ece17c01ab9e15889211a") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=True, description="Enable Fortran API") variant("python", default=False, description="Enable PYTHON support", when="@3.4:") @@ -46,22 +50,23 @@ class Cmor(AutotoolsPackage): @run_before("configure") def validate(self): - if "+fortran" in self.spec and not self.compiler.fc: + if self.spec.satisfies("+fortran") and not self.compiler.fc: msg = "cannot build a fortran variant without a fortran compiler" raise RuntimeError(msg) def configure_args(self): - extra_args = ["--disable-debug"] + spec = self.spec + args = ["--disable-debug"] - if "+fortran" in self.spec: - extra_args.append("--enable-fortran") + if spec.satisfies("+fortran"): + args.append("--enable-fortran") else: - extra_args.append("--disable-fortran") + args.append("--disable-fortran") - if "+python" in self.spec: - extra_args.append("--with-python={0}".format(self.spec["python"].prefix)) + if spec.satisfies("+python"): + args.append(f"--with-python={self.spec['python'].prefix}") - return extra_args + return args def check(self): """tests need downloaded files, testcases have manual instructions for that.""" @@ -70,6 +75,6 @@ def check(self): def install(self, spec, prefix): make("install") - if "+python" in spec: + if spec.satisfies("+python"): args = std_pip_args + ["--prefix=" + prefix, "."] pip(*args) diff --git a/var/spack/repos/builtin/packages/cni-plugins/package.py b/var/spack/repos/builtin/packages/cni-plugins/package.py index baaec3a7a73eeb..e6236b0c85ec9f 100644 --- a/var/spack/repos/builtin/packages/cni-plugins/package.py +++ b/var/spack/repos/builtin/packages/cni-plugins/package.py @@ -20,6 +20,8 @@ class CniPlugins(Package): version("1.1.1", sha256="c86c44877c47f69cd23611e22029ab26b613f620195b76b3ec20f589367a7962") version("1.0.1", sha256="2ba3cd9f341a7190885b60d363f6f23c6d20d975a7a0ab579dd516f8c6117619") + depends_on("c", type="build") # generated + depends_on("go", type="build") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/cnmem/package.py b/var/spack/repos/builtin/packages/cnmem/package.py index 16d2066fc55166..42adb5e100d6a5 100644 --- a/var/spack/repos/builtin/packages/cnmem/package.py +++ b/var/spack/repos/builtin/packages/cnmem/package.py @@ -16,4 +16,6 @@ class Cnmem(CMakePackage): version("git", branch="master") + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.8:", type="build") diff --git a/var/spack/repos/builtin/packages/cnpy/package.py b/var/spack/repos/builtin/packages/cnpy/package.py index b49556c659718e..860755f22b35a1 100644 --- a/var/spack/repos/builtin/packages/cnpy/package.py +++ b/var/spack/repos/builtin/packages/cnpy/package.py @@ -18,6 +18,8 @@ class Cnpy(CMakePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + depends_on("zlib-api", type="link") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/cntk/package.py b/var/spack/repos/builtin/packages/cntk/package.py index 03130fa0b4f634..8d243e7d42f972 100644 --- a/var/spack/repos/builtin/packages/cntk/package.py +++ b/var/spack/repos/builtin/packages/cntk/package.py @@ -22,6 +22,8 @@ class Cntk(Package): version("master", branch="master") version("2.0", sha256="3adee17f166e2a682dfb551ca017ae5c3836ca9772c0af14215a7e76254f201c") + depends_on("cxx", type="build") # generated + variant("opencv", default=False, description="Enable OpenCV support.") variant("kaldi", default=False, description="Enable Kaldi support.") variant("asgd", default=True, description="Enable DataParallelASGD powered by Multiverso.") diff --git a/var/spack/repos/builtin/packages/cnvnator/package.py b/var/spack/repos/builtin/packages/cnvnator/package.py index e4348104db4c02..55081c0d0d1303 100644 --- a/var/spack/repos/builtin/packages/cnvnator/package.py +++ b/var/spack/repos/builtin/packages/cnvnator/package.py @@ -15,6 +15,8 @@ class Cnvnator(MakefilePackage): version("0.3.3", sha256="58c5acf61f9a1e5febf546c196f8917a5e084b729e5c4cfd3eba83471b3fe5c1") + depends_on("cxx", type="build") # generated + depends_on("samtools@:1.13") depends_on("htslib") depends_on("root") diff --git a/var/spack/repos/builtin/packages/codar-cheetah/package.py b/var/spack/repos/builtin/packages/codar-cheetah/package.py index f1a97d842b398a..5cbdd9d3842a93 100644 --- a/var/spack/repos/builtin/packages/codar-cheetah/package.py +++ b/var/spack/repos/builtin/packages/codar-cheetah/package.py @@ -22,5 +22,7 @@ class CodarCheetah(PythonPackage): version("1.0.0", sha256="1f935fbc1475a654f3b6d2140d8b2a6079a65c8701655e544ba1fab3a7c1bc19") version("0.5", sha256="f37a554741eff4bb8407a68f799dd042dfc4df525e84896cad70fccbd6aca6ee") + depends_on("cxx", type="build") # generated + depends_on("python@3.5:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/code-server/package.py b/var/spack/repos/builtin/packages/code-server/package.py index e208405387efeb..bc7da6afcc396f 100644 --- a/var/spack/repos/builtin/packages/code-server/package.py +++ b/var/spack/repos/builtin/packages/code-server/package.py @@ -52,6 +52,9 @@ class CodeServer(Package): version("3.1.0", sha256="5ef85c8f280ce781a176a8b77386b333efe892755a5c325a1782e4eac6016e59") version("3.0.2", sha256="04367cfeb23991f3dc3f1ef8e3dfe5e9d683bb50c9e1fa69e3c21757facfd7ee") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): if version <= Version("3.2.0"): return "https://github.com/coder/code-server/releases/download/{0}/code-server-{0}-linux-x86_64.tar.gz".format( diff --git a/var/spack/repos/builtin/packages/codipack/package.py b/var/spack/repos/builtin/packages/codipack/package.py index 6d6577f6a82d17..2347df15ce3ccf 100644 --- a/var/spack/repos/builtin/packages/codipack/package.py +++ b/var/spack/repos/builtin/packages/codipack/package.py @@ -22,6 +22,8 @@ class Codipack(CMakePackage, Package): version("1.9.3", sha256="27dd92d0b5132de37b431989c0c3d5bd829821a6a2e31e0529137e427421f06e") version("openmp", branch="experimentalOpenMPSupport") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.12:", type="build", when="@2.1.0:") build_system( diff --git a/var/spack/repos/builtin/packages/coevp/package.py b/var/spack/repos/builtin/packages/coevp/package.py index 589a9253a32c38..b0a695e14f257e 100644 --- a/var/spack/repos/builtin/packages/coevp/package.py +++ b/var/spack/repos/builtin/packages/coevp/package.py @@ -24,6 +24,10 @@ class Coevp(MakefilePackage): version("develop", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Build with MPI Support") variant("silo", default=False, description="Build with silo Support") variant("flann", default=False, description="Build with flann Support") diff --git a/var/spack/repos/builtin/packages/cohmm/package.py b/var/spack/repos/builtin/packages/cohmm/package.py index feb7881e3f0981..49bec4f075441d 100644 --- a/var/spack/repos/builtin/packages/cohmm/package.py +++ b/var/spack/repos/builtin/packages/cohmm/package.py @@ -21,6 +21,8 @@ class Cohmm(MakefilePackage): version("develop", branch="sad") + depends_on("c", type="build") # generated + variant("openmp", default=True, description="Build with OpenMP Support") variant("gnuplot", default=False, description="Enable gnu plot Support") depends_on("gnuplot", when="+gnuplot") diff --git a/var/spack/repos/builtin/packages/coin3d/package.py b/var/spack/repos/builtin/packages/coin3d/package.py index a184e68e2c8e2e..6cffab95cbd7c4 100644 --- a/var/spack/repos/builtin/packages/coin3d/package.py +++ b/var/spack/repos/builtin/packages/coin3d/package.py @@ -21,6 +21,9 @@ class Coin3d(AutotoolsPackage, CMakePackage): version("3.0.0", sha256="d5c2eb0ecaa5c83d93daf0e9e275e58a6a8dfadc74c873d51b0c939011f81bfa") version("2.0.0", sha256="6d26435aa962d085b7accd306a0b478069a7de1bc5ca24e22344971852dd097c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_system( conditional("cmake", when="@4.0.0:"), conditional("autotools", when="@:3.1.0"), diff --git a/var/spack/repos/builtin/packages/coinhsl/package.py b/var/spack/repos/builtin/packages/coinhsl/package.py index 9c2706318165c0..0fe8da7c2e5cdc 100644 --- a/var/spack/repos/builtin/packages/coinhsl/package.py +++ b/var/spack/repos/builtin/packages/coinhsl/package.py @@ -8,7 +8,7 @@ from spack.package import * -class Coinhsl(AutotoolsPackage): +class Coinhsl(MesonPackage, AutotoolsPackage): """CoinHSL is a collection of linear algebra libraries (KB22, MA27, MA28, MA54, MA57, MA64, MA77, MA86, MA97, MC19, MC34, MC64, MC68, MC69, MC78, MC80, OF01, ZB01, ZB11) bundled for use with IPOPT and @@ -21,60 +21,85 @@ class Coinhsl(AutotoolsPackage): that Spack can find it. For instructions on how to set up a mirror, see https://spack.readthedocs.io/en/latest/mirrors.html""" - # NOTE(oxberry1@llnl.gov): an HTTPS version of the URL below does not - # exist + build_system( + conditional("autotools", when="@b:2019.05.21"), + conditional("meson", when="@2023:,:b"), + default="meson", + ) + homepage = "https://www.hsl.rl.ac.uk/ipopt/" - url = "file://{0}/coinhsl-archive-2014.01.17.tar.gz".format(os.getcwd()) + url = f"file://{os.getcwd()}/coinhsl-2023.11.17.tar.gz" manual_download = True - # CoinHSL has a few versions that vary with respect to stability/features - # and licensing terms. + maintainers("AndrewLister-STFC") - # Version 2019.05.21 is a full-featured "release candidate" - # version available via an "academic license" that can be used for - # personal teaching and research purposes only. For a full list of - # conditions, see https://www.hsl.rl.ac.uk/academic.html. + # Meson builds version( - "2019.05.21", sha256="95ce1160f0b013151a3e25d40337775c760a8f3a79d801a1d190598bf4e4c0c3" + "2024.05.15", + sha256="2534807b4f6a4a69661c82dc0da7094f685f0fce6443a9147ee90a21caba9e63", + preferred=True, ) - - # Version 2015.06.23 is a full-featured "stable" - # version available via an "academic license" that can be used for - # personal teaching and research purposes only. For a full list of - # conditions, see https://www.hsl.rl.ac.uk/academic.html. version( - "2015.06.23", - sha256="3e955a2072f669b8f357ae746531b37aea921552e415dc219a5dd13577575fb3", - preferred=True, + "archive-2024.05.15", + sha256="1d907ce5d84331ce8f78125d5fc766184f0fce9a7b340db7f3c4821a7f4b7c4c", ) - # Version 2014.01.17 is a full-featured "stable" version available - # via an "academic license" that can be used for personal teaching - # and research purposes only. + with when("build_system=meson @2023:"): + depends_on("blas") + depends_on("lapack") + variant("metis", default=True, description="Build with Metis support.") + depends_on("metis", when="+metis") + + def meson_args(self): + spec = self.spec + args = [] + if spec.satisfies("@:b"): + return [] + + blas = spec["blas"].libs.names[0] + blas_paths = [sf[2:] for sf in spec["blas"].libs.search_flags.split()] + lapack = spec["lapack"].libs.names[0] + lapack_paths = [sf[2:] for sf in spec["lapack"].libs.search_flags.split()] + args.append(f"-Dlibblas={blas}") + args.extend([f"-Dlibblas_path={p}" for p in blas_paths]) + args.append(f"-Dliblapack={lapack}") + args.extend([f"-Dlibblas_path={p}" for p in lapack_paths]) + if spec.satisfies("+metis"): + metis = spec["metis"] + if metis.satisfies("@5"): + args.append("-Dlibmetis_version=5") + else: + args.append("-Dlibmetis_version=4") + args.extend( + [ + f"-Dlibmetis_include={metis.prefix.include}", + f"-Dlibmetis_path={metis.prefix.lib}", + ] + ) + return args + + # Autotools builds + version( + "2019.05.21", sha256="95ce1160f0b013151a3e25d40337775c760a8f3a79d801a1d190598bf4e4c0c3" + ) + version( + "2015.06.23", sha256="3e955a2072f669b8f357ae746531b37aea921552e415dc219a5dd13577575fb3" + ) version( "2014.01.17", sha256="ed49fea62692c5d2f928d4007988930da9ff9a2e944e4c559d028671d122437b" ) - - # Version 2014.01.10 only has MA27, MA28, and MC19, and is - # available as a "personal license" that is free to all, and - # permits commercial use, but *not redistribution* (emphasis from - # original source). version( "2014.01.10", sha256="7c2be60a3913b406904c66ee83acdbd0709f229b652c4e39ee5d0876f6b2e907" ) - # CoinHSL fails to build in parallel - parallel = False - - variant("blas", default=False, description="Link to external BLAS library") - - depends_on("blas", when="+blas") + with when("build_system=autotools"): + parallel = False + variant("blas", default=False, description="Link to external BLAS library") + depends_on("blas", when="+blas") def configure_args(self): spec = self.spec args = [] - if spec.satisfies("+blas"): - args.append("--with-blas={0}".format(spec["blas"].libs.ld_flags)) - + args.append(f"--with-blas={spec['blas'].libs.ld_flags}") return args diff --git a/var/spack/repos/builtin/packages/coinutils/package.py b/var/spack/repos/builtin/packages/coinutils/package.py index 27d248862cb49f..b7295633ee8579 100644 --- a/var/spack/repos/builtin/packages/coinutils/package.py +++ b/var/spack/repos/builtin/packages/coinutils/package.py @@ -21,4 +21,6 @@ class Coinutils(AutotoolsPackage): version("2.11.6", sha256="6ea31d5214f7eb27fa3ffb2bdad7ec96499dd2aaaeb4a7d0abd90ef852fc79ca") version("2.11.4", sha256="d4effff4452e73356eed9f889efd9c44fe9cd68bd37b608a5ebb2c58bd45ef81") + depends_on("cxx", type="build") # generated + build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/collectd/package.py b/var/spack/repos/builtin/packages/collectd/package.py index 50c4b1fa512891..1365bb8404cbb7 100644 --- a/var/spack/repos/builtin/packages/collectd/package.py +++ b/var/spack/repos/builtin/packages/collectd/package.py @@ -18,4 +18,7 @@ class Collectd(AutotoolsPackage): version("5.11.0", sha256="37b10a806e34aa8570c1cafa6006c604796fae13cc2e1b3e630d33dcba9e5db2") version("5.10.0", sha256="a03359f563023e744c2dc743008a00a848f4cd506e072621d86b6d8313c0375b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("valgrind", type="test") diff --git a/var/spack/repos/builtin/packages/collier/package.py b/var/spack/repos/builtin/packages/collier/package.py index a15ee75b9c13ec..3475d40f4bf780 100644 --- a/var/spack/repos/builtin/packages/collier/package.py +++ b/var/spack/repos/builtin/packages/collier/package.py @@ -32,6 +32,8 @@ class Collier(CMakePackage): version("1.1", sha256="80fd54e2c30029d3d7d646738ae9469ad3a6f5ea7aa1179b951030df048e36bc") version("1.0", sha256="54f40c1ed07a6829230af400abfe48791e74e56eac2709c0947cec3410a4473d") + depends_on("fortran", type="build") # generated + @property def parallel(self): return not self.spec.satisfies("@:1.2.4") diff --git a/var/spack/repos/builtin/packages/colm/package.py b/var/spack/repos/builtin/packages/colm/package.py index 500337d3bd120f..dcea9ae1524b1e 100644 --- a/var/spack/repos/builtin/packages/colm/package.py +++ b/var/spack/repos/builtin/packages/colm/package.py @@ -19,3 +19,6 @@ class Colm(AutotoolsPackage): license("GPL-2.0-only") version("0.12.0", sha256="7b545d74bd139f5c622975d243c575310af1e4985059a1427b6fdbb1fb8d6e4d") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/comd/package.py b/var/spack/repos/builtin/packages/comd/package.py index f6c846325942f0..af109ac1f44b94 100644 --- a/var/spack/repos/builtin/packages/comd/package.py +++ b/var/spack/repos/builtin/packages/comd/package.py @@ -25,6 +25,8 @@ class Comd(MakefilePackage): version("develop", branch="master") version("1.1", sha256="4e85f86f043681a1ef72940fc24a4c71356a36afa45446f7cfe776abad6aa252") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Build with MPI support") variant("openmp", default=False, description="Build with OpenMP support") variant("precision", default=True, description="Toggle Precesion Options") diff --git a/var/spack/repos/builtin/packages/comgr/package.py b/var/spack/repos/builtin/packages/comgr/package.py index 789dfc50b7a2c1..b0c0723f8fa397 100644 --- a/var/spack/repos/builtin/packages/comgr/package.py +++ b/var/spack/repos/builtin/packages/comgr/package.py @@ -14,7 +14,14 @@ class Comgr(CMakePackage): homepage = "https://github.com/ROCm/ROCm-CompilerSupport" git = "https://github.com/ROCm/ROCm-CompilerSupport.git" - url = "https://github.com/ROCm/ROCm-CompilerSupport/archive/rocm-6.0.0.tar.gz" + + def url_for_version(self, version): + if version <= Version("6.0.2"): + url = "https://github.com/ROCm/ROCm-CompilerSupport/archive/rocm-{0}.tar.gz" + else: + url = "https://github.com/ROCm/llvm-project/archive/rocm-{0}.tar.gz" + return url.format(version) + tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath", "haampie") @@ -23,6 +30,9 @@ class Comgr(CMakePackage): license("NCSA") version("master", branch="amd-stg-open") + version("6.1.2", sha256="300e9d6a137dcd91b18d5809a316fddb615e0e7f982dc7ef1bb56876dff6e097") + version("6.1.1", sha256="f1a67efb49f76a9b262e9735d3f75ad21e3bd6a05338c9b15c01e6c625c4460d") + version("6.1.0", sha256="6bd9912441de6caf6b26d1323e1c899ecd14ff2431874a2f5883d3bc5212db34") version("6.0.2", sha256="737b110d9402509db200ee413fb139a78369cf517453395b96bda52d0aa362b9") version("6.0.0", sha256="04353d27a512642a5e5339532a39d0aabe44e0964985de37b150a2550385800a") version("5.7.1", sha256="3b9433b4a0527167c3e9dfc37a3c54e0550744b8d4a8e1be298c8d4bcedfee7c") @@ -31,16 +41,17 @@ class Comgr(CMakePackage): version("5.6.0", sha256="9396a7238b547ee68146c669b10b9d5de8f1d76527c649133c75d8076a185a72") version("5.5.1", sha256="0fbb15fe5a95c2e141ccd360bc413e1feda283334781540a6e5095ab27fd8019") version("5.5.0", sha256="97dfff03226ce0902b9d5d1c8c7bebb7a15978a81b6e9c750bf2d2473890bd42") - version("5.4.3", sha256="8af18035550977fe0aa9cca8dfacbe65fe292e971de5a0e160710bafda05a81f") - version("5.4.0", sha256="f4b83b27ff6195679d695c3f41fa25456e9c50bae6d978f46d3541b472aef757") - version("5.3.3", sha256="6a4ef69e672a077b5909977248445f0eedf5e124af9812993a4d444be030c78b") - version("5.3.0", sha256="072f849d79476d87d31d62b962e368762368d540a9da02ee2675963dc4942b2c") with default_args(deprecated=True): - version("5.2.3", sha256="36d67dbe791d08ad0a02f0f3aedd46059848a0a232c5f999670103b0410c89dc") - version("5.2.1", sha256="ebeaea8e653fc2b9d67d3271be44690ac7876ee679baa01d47863e75362b8c85") - version("5.2.0", sha256="5f63fa93739ee9230756ef93c53019474b6cdddea3b588492d785dae1b08c087") - version("5.1.3", sha256="3078c10e9a852fe8357712a263ad775b15944e083f93a879935c877511066ac9") - version("5.1.0", sha256="1cdcfe5acb768ef50fb0026d4ee7ba01e615251ad3c27bb2593cdcf8c070a894") + version("5.4.3", sha256="8af18035550977fe0aa9cca8dfacbe65fe292e971de5a0e160710bafda05a81f") + version("5.4.0", sha256="f4b83b27ff6195679d695c3f41fa25456e9c50bae6d978f46d3541b472aef757") + version("5.3.3", sha256="6a4ef69e672a077b5909977248445f0eedf5e124af9812993a4d444be030c78b") + version("5.3.0", sha256="072f849d79476d87d31d62b962e368762368d540a9da02ee2675963dc4942b2c") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") # Disable the hip compile tests. Spack should not be using # /opt/rocm, and this breaks the build when /opt/rocm exists. @@ -55,11 +66,6 @@ class Comgr(CMakePackage): depends_on("rocm-cmake@3.5.0:", type="build") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -72,6 +78,9 @@ class Comgr(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", ]: # llvm libs are linked statically, so this *could* be a build dep @@ -81,15 +90,34 @@ class Comgr(CMakePackage): # that a conditional dependency depends_on(f"rocm-device-libs@{ver}", when=f"@{ver} ^llvm-amdgpu ~rocm-device-libs") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") - root_cmakelists_dir = join_path("lib", "comgr") + @property + def root_cmakelists_dir(self): + if self.spec.satisfies("@:6.0"): + return join_path("lib", "comgr") + else: + return join_path("amd", "comgr") def cmake_args(self): args = [self.define("BUILD_TESTING", self.run_tests)] if self.spec.satisfies("@5.4.3:"): args.append("-DCMAKE_INSTALL_LIBDIR=lib") + if self.spec.satisfies("@5.7:"): + args.append(self.define_from_variant("ADDRESS_SANITIZER", "asan")) return args @classmethod diff --git a/var/spack/repos/builtin/packages/commons-lang3/package.py b/var/spack/repos/builtin/packages/commons-lang3/package.py index ef05a2e8546608..0b3d0ba2fb2410 100644 --- a/var/spack/repos/builtin/packages/commons-lang3/package.py +++ b/var/spack/repos/builtin/packages/commons-lang3/package.py @@ -23,6 +23,7 @@ class CommonsLang3(Package): license("Apache-2.0") + version("3.14.0", sha256="317c3e3fcd5fcca3781a7996ff1e0c50c13244ee961e94e5f6f6d84b84733b16") version("3.12.0", sha256="33012465dfcb7f790aca333e09ebf105e2a5fb95c2c638b3df790d3efa908e28") version("3.7", sha256="94dc8289ce90b77b507d9257784d9a43b402786de40c164f6e3990e221a2a4d2") @@ -30,4 +31,4 @@ class CommonsLang3(Package): depends_on("java@7:", type="run") def install(self, spec, prefix): - install("commons-lang3-{0}.jar".format(self.version), prefix) + install(f"commons-lang3-{self.version}.jar", prefix) diff --git a/var/spack/repos/builtin/packages/compadre/package.py b/var/spack/repos/builtin/packages/compadre/package.py index 9897f7958aea80..801f0d8b865096 100644 --- a/var/spack/repos/builtin/packages/compadre/package.py +++ b/var/spack/repos/builtin/packages/compadre/package.py @@ -25,12 +25,18 @@ class Compadre(CMakePackage): version("1.4.1", sha256="2e1e7d8e30953f76b6dc3a4c86ec8103d4b29447194cb5d5abb74b8e4099bdd9") version("1.3.0", sha256="f711a840fd921e84660451ded408023ec3bcfc98fd0a7dc4a299bfae6ab489c2") - depends_on("kokkos-kernels@3.3.01:3.6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + depends_on("kokkos-kernels@3.3.01:4") depends_on("cmake@3.13:", type="build") variant("mpi", default=False, description="Enable MPI support") depends_on("mpi", when="+mpi") + variant("tests", default=True, description="Enable tests and examples") + # fixes duplicate symbol issue with static library build patch( "https://patch-diff.githubusercontent.com/raw/sandialabs/Compadre/pull/286.patch?full_index=1", @@ -56,6 +62,10 @@ def cmake_args(self): if "+mpi" in spec: options.append("-DCompadre_USE_MPI:BOOL=ON") + if "~tests" in spec: + options.append("-DCompadre_EXAMPLES:BOOL=OFF") + options.append("-DCompadre_TESTS:BOOL=OFF") + if "+shared" in spec: options.append("-DBUILD_SHARED_LIBS:BOOL=ON") else: diff --git a/var/spack/repos/builtin/packages/compiz/package.py b/var/spack/repos/builtin/packages/compiz/package.py index a6805d07487ebb..08a26f9dd535fa 100644 --- a/var/spack/repos/builtin/packages/compiz/package.py +++ b/var/spack/repos/builtin/packages/compiz/package.py @@ -21,6 +21,9 @@ class Compiz(AutotoolsPackage, XorgPackage): version("0.7.8", sha256="b46f52b776cc78e85357a07688d04b36ec19c65eadeaf6f6cfcca7b8515e6503") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libxcb") depends_on("libxcomposite") depends_on("libxfixes") diff --git a/var/spack/repos/builtin/packages/composable-kernel/package.py b/var/spack/repos/builtin/packages/composable-kernel/package.py index 1ac7f930eceaa8..e56bdd63fdbbb9 100644 --- a/var/spack/repos/builtin/packages/composable-kernel/package.py +++ b/var/spack/repos/builtin/packages/composable-kernel/package.py @@ -13,12 +13,15 @@ class ComposableKernel(CMakePackage): homepage = "https://github.com/ROCm/composable_kernel" git = "https://github.com/ROCm/composable_kernel.git" - url = "https://github.com/ROCm/composable_kernel/archive/refs/tags/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/composable_kernel/archive/refs/tags/rocm-6.1.2.tar.gz" maintainers("srekolam", "afzpatel") license("MIT") version("master", branch="develop") + version("6.1.2", sha256="54db801e1c14239f574cf94dd764a2f986b4abcc223393d55c49e4b276e738c9") + version("6.1.1", sha256="f55643c6eee0878e8f2d14a382c33c8b84af0bdf8f31b37b6092b377f7a9c6b5") + version("6.1.0", sha256="355a4514b96b56aa9edf78198a3e22067e7397857cfe29d9a64d9c5557b9f83d") version("6.0.2", sha256="f648a99388045948b7d5fbf8eb8da6a1803c79008b54d406830b7f9119e1dcf6") version("6.0.0", sha256="a8f736f2f2a8afa4cddd06301205be27774d85f545429049b4a2bbbe6fcd67df") version("5.7.1", sha256="75f66e023c2e31948e91fa26366eaeac72d871fc2e5188361d4465179f13876e") @@ -27,8 +30,11 @@ class ComposableKernel(CMakePackage): version("5.6.0", commit="f5ec04f091fa5c48c67d7bacec36a414d0be06a5") version("5.5.1", commit="ac9e01e2cc3721be24619807adc444e1f59a9d25") version("5.5.0", commit="8b76b832420a3d69708401de6607a033163edcce") - version("5.4.3", commit="bb3d9546f186e39cefedc3e7f01d88924ba20168") - version("5.4.0", commit="236bd148b98c7f1ec61ee850fcc0c5d433576305") + with default_args(deprecated=True): + version("5.4.3", commit="bb3d9546f186e39cefedc3e7f01d88924ba20168") + version("5.4.0", commit="236bd148b98c7f1ec61ee850fcc0c5d433576305") + + depends_on("cxx", type="build") # generated amdgpu_targets = ROCmPackage.amdgpu_targets variant( @@ -50,6 +56,9 @@ class ComposableKernel(CMakePackage): for ver in [ "master", + "6.1.2", + "6.1.1", + "6.1.0", "6.0.2", "6.0.0", "5.7.1", @@ -80,7 +89,10 @@ def cmake_args(self): if "auto" not in self.spec.variants["amdgpu_target"]: args.append(self.define_from_variant("GPU_TARGETS", "amdgpu_target")) if self.spec.satisfies("@5.6.0:"): - args.append(self.define("INSTANCES_ONLY", "ON")) + if self.run_tests: + args.append(self.define("BUILD_TESTING", "ON")) + else: + args.append(self.define("INSTANCES_ONLY", "ON")) args.append(self.define("CK_BUILD_JIT_LIB", "ON")) args.append(self.define("CMAKE_POSITION_INDEPENDENT_CODE", "ON")) if self.spec.satisfies("@:5.7"): diff --git a/var/spack/repos/builtin/packages/maphyspp/package.py b/var/spack/repos/builtin/packages/composyx/package.py similarity index 54% rename from var/spack/repos/builtin/packages/maphyspp/package.py rename to var/spack/repos/builtin/packages/composyx/package.py index fb440cad5ae799..d177bee5b25d21 100644 --- a/var/spack/repos/builtin/packages/maphyspp/package.py +++ b/var/spack/repos/builtin/packages/composyx/package.py @@ -7,16 +7,20 @@ from spack.package import * -class Maphyspp(CMakePackage): +class Composyx(CMakePackage): """a Massively Parallel Hybrid Solver in C++""" - homepage = "https://gitlab.inria.fr/solverstack/maphys/maphyspp" - git = "https://gitlab.inria.fr/solverstack/maphys/maphyspp.git" - url = "https://gitlab.inria.fr/api/v4/projects/6194/packages/generic/source/v1.1.9/maphyspp-1.1.9.tar.gz" + homepage = "https://gitlab.inria.fr/composyx/composyx" + git = "https://gitlab.inria.fr/composyx/composyx.git" + url = "https://gitlab.inria.fr/api/v4/projects/52455/packages/generic/source/v1.0.1/composyx-1.0.1.tar.gz" maintainers("fpruvost") - version("master", branch="master", submodules=True) - version("1.1.9", sha256="472deef05f69c26337a6f8e769cf36cbe0a50e6ec096757389ed10286a0d7e04") + version("main", branch="main", submodules=True) + version("1.0.1", sha256="d97936e3b297fde435c165cbe29cb39e5d88ae368be451b1c45b8ee51486782c") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated # User options variant("armadillo", default=False, description="Enable Armadillo interface") @@ -47,20 +51,20 @@ class Maphyspp(CMakePackage): def cmake_args(self): args = [ self.define("BUILD_SHARED_LIBS", True), - self.define("MAPHYSPP_C_DRIVER", True), - self.define("MAPHYSPP_Fortran_DRIVER", True), - self.define("MAPHYSPP_COMPILE_BENCH", False), - self.define("MAPHYSPP_USE_MUMPS", False), - self.define("MAPHYSPP_USE_QRMUMPS", False), - self.define("MAPHYSPP_USE_SZ_COMPRESSOR", False), - self.define_from_variant("MAPHYSPP_COMPILE_EXAMPLES", "examples"), - self.define_from_variant("MAPHYSPP_COMPILE_TESTS", "tests"), - self.define_from_variant("MAPHYSPP_USE_ARMADILLO", "armadillo"), - self.define_from_variant("MAPHYSPP_USE_ARPACK", "arpack-ng"), - self.define_from_variant("MAPHYSPP_USE_EIGEN", "eigen"), - self.define_from_variant("MAPHYSPP_USE_FABULOUS", "fabulous"), - self.define_from_variant("MAPHYSPP_USE_PADDLE", "paddle"), - self.define_from_variant("MAPHYSPP_USE_PASTIX", "pastix"), + self.define("COMPOSYX_C_DRIVER", True), + self.define("COMPOSYX_Fortran_DRIVER", True), + self.define("COMPOSYX_COMPILE_BENCH", False), + self.define("COMPOSYX_USE_MUMPS", False), + self.define("COMPOSYX_USE_QRMUMPS", False), + self.define("COMPOSYX_USE_SZ_COMPRESSOR", False), + self.define_from_variant("COMPOSYX_COMPILE_EXAMPLES", "examples"), + self.define_from_variant("COMPOSYX_COMPILE_TESTS", "tests"), + self.define_from_variant("COMPOSYX_USE_ARMADILLO", "armadillo"), + self.define_from_variant("COMPOSYX_USE_ARPACK", "arpack-ng"), + self.define_from_variant("COMPOSYX_USE_EIGEN", "eigen"), + self.define_from_variant("COMPOSYX_USE_FABULOUS", "fabulous"), + self.define_from_variant("COMPOSYX_USE_PADDLE", "paddle"), + self.define_from_variant("COMPOSYX_USE_PASTIX", "pastix"), ] return args diff --git a/var/spack/repos/builtin/packages/conduit/package.py b/var/spack/repos/builtin/packages/conduit/package.py index c1066ce7524c03..ebf372fefac447 100644 --- a/var/spack/repos/builtin/packages/conduit/package.py +++ b/var/spack/repos/builtin/packages/conduit/package.py @@ -45,6 +45,7 @@ class Conduit(CMakePackage): # is to bridge any spack dependencies that are still using the name master version("master", branch="develop", submodules=True) # note: 2021-05-05 latest tagged release is now preferred instead of develop + version("0.9.2", sha256="45d5a4eccd0fc978d153d29c440c53c483b8f29dfcf78ddcc9aa15c59b257177") version("0.9.1", sha256="a3f1168738dcf72f8ebf83299850301aaf56e803f40618fc1230a755d0d05363") version("0.9.0", sha256="844e012400ab820967eef6cec15e1aa9a68cb05119d0c1f292d3c01630111a58") version("0.8.8", sha256="99811e9c464b6f841f52fcd47e982ae47cbb01cba334cff43eabe13eea58c0df") @@ -69,6 +70,10 @@ class Conduit(CMakePackage): version("0.2.1", sha256="796576b9c69717c52f0035542c260eb7567aa351ee892d3fbe3521c38f1520c4") version("0.2.0", sha256="31eff8dbc654a4b235cfcbc326a319e1752728684296721535c7ca1c9b463061") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + maintainers("cyrush") ########################################################################### @@ -443,7 +448,7 @@ def hostconfig(self): cfg.write("# Enable python module builds\n") cfg.write(cmake_cache_entry("ENABLE_PYTHON", "ON")) cfg.write("# python from spack \n") - cfg.write(cmake_cache_entry("PYTHON_EXECUTABLE", spec["python"].command.path)) + cfg.write(cmake_cache_entry("PYTHON_EXECUTABLE", python.path)) try: cfg.write("# python module install dir\n") cfg.write(cmake_cache_entry("PYTHON_MODULE_INSTALL_PREFIX", python_platlib)) diff --git a/var/spack/repos/builtin/packages/conmon/package.py b/var/spack/repos/builtin/packages/conmon/package.py index f15f3affbd6045..f7bac7bbdcedd6 100644 --- a/var/spack/repos/builtin/packages/conmon/package.py +++ b/var/spack/repos/builtin/packages/conmon/package.py @@ -15,10 +15,13 @@ class Conmon(MakefilePackage): license("Apache-2.0") + version("2.1.12", sha256="842f0b5614281f7e35eec2a4e35f9f7b9834819aa58ecdad8d0ff6a84f6796a6") version("2.1.7", sha256="7d0f9a2f7cb8a76c51990128ac837aaf0cc89950b6ef9972e94417aa9cf901fe") version("2.1.5", sha256="ee3179ee2b9a9107acec00eb546062cf7deb847f135a3b81503d22b0d226b3ed") version("2.0.30", sha256="4b0a98fbe8a63c42f60edac25c19aa6606caa7b1e4fe7846fc7f7de0b566ba25") + depends_on("c", type="build") # generated + depends_on("go", type="build") depends_on("go-md2man", type="build") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/conquest/package.py b/var/spack/repos/builtin/packages/conquest/package.py index 32ab7d77792f4c..56ed26c11b96ed 100644 --- a/var/spack/repos/builtin/packages/conquest/package.py +++ b/var/spack/repos/builtin/packages/conquest/package.py @@ -24,6 +24,8 @@ class Conquest(MakefilePackage): version("master", branch="master") version("develop", branch="develop") + depends_on("fortran", type="build") # generated + depends_on("blas") depends_on("lapack") depends_on("scalapack") diff --git a/var/spack/repos/builtin/packages/conserver/package.py b/var/spack/repos/builtin/packages/conserver/package.py index 599104957ca3b6..0b3d75d9f143c6 100644 --- a/var/spack/repos/builtin/packages/conserver/package.py +++ b/var/spack/repos/builtin/packages/conserver/package.py @@ -22,5 +22,7 @@ class Conserver(AutotoolsPackage): version("8.2.2", sha256="05ea1693bf92b42ad2f0a9389c60352ccd35c2ea93c8fc8e618d0153362a7d81") version("8.2.1", sha256="251ae01997e8f3ee75106a5b84ec6f2a8eb5ff2f8092438eba34384a615153d0") + depends_on("c", type="build") # generated + def setup_run_environment(self, env): env.prepend_path("PATH", self.prefix.sbin) diff --git a/var/spack/repos/builtin/packages/console-bridge/package.py b/var/spack/repos/builtin/packages/console-bridge/package.py index bff4b72b4ed9a7..a6b17ed44fe737 100644 --- a/var/spack/repos/builtin/packages/console-bridge/package.py +++ b/var/spack/repos/builtin/packages/console-bridge/package.py @@ -24,3 +24,5 @@ class ConsoleBridge(CMakePackage): version("0.5.0", sha256="1cecdf232b1eb883b41cc50d1d38443b2163fdc0497072dc1aa6e7ba30696060") version("0.4.4", sha256="1147af6ad6477fcfd640c543684e17ee540e434aa70d6f31c1d137bc86fb937c") version("0.4.3", sha256="9f024a38f0947ed9fa67f58829980c2d90d84740e6de20d75cb00866f07a7a0b") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/constype/package.py b/var/spack/repos/builtin/packages/constype/package.py index 0ed38e823589d0..2f11a8cae01ec9 100644 --- a/var/spack/repos/builtin/packages/constype/package.py +++ b/var/spack/repos/builtin/packages/constype/package.py @@ -19,5 +19,7 @@ class Constype(AutotoolsPackage, XorgPackage): version("1.0.5", sha256="ec7d07204dd5abf8d21d0a89408be17ab316a017838c88b087b127082f02c051") version("1.0.4", sha256="ec09aff369cf1d527fd5b8075fb4dd0ecf89d905190cf1a0a0145d5e523f913d") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") diff --git a/var/spack/repos/builtin/packages/cool/package.py b/var/spack/repos/builtin/packages/cool/package.py index c849e48149d617..07a1ebae6ebccf 100644 --- a/var/spack/repos/builtin/packages/cool/package.py +++ b/var/spack/repos/builtin/packages/cool/package.py @@ -21,6 +21,8 @@ class Cool(CMakePackage): version("3.3.4", tag="COOL_3_3_4", commit="c3f9f780e0949fc78277c05d21d06fd7ddc6ea48") version("3.3.3", tag="COOL_3_3_3", commit="42137f0ecd5028c41a46a99f0b95b56e105ef4e3") + depends_on("cxx", type="build") # generated + # Spack-specific patches: # * Create python/PyCool/_internal directory # (only necessary for Spack builds, for some reason) diff --git a/var/spack/repos/builtin/packages/coordgen/package.py b/var/spack/repos/builtin/packages/coordgen/package.py index b0a6f70675296e..45fc4c08a5258e 100644 --- a/var/spack/repos/builtin/packages/coordgen/package.py +++ b/var/spack/repos/builtin/packages/coordgen/package.py @@ -18,6 +18,8 @@ class Coordgen(CMakePackage): version("3.0.2", sha256="f67697434f7fec03bca150a6d84ea0e8409f6ec49d5aab43badc5833098ff4e3") + depends_on("cxx", type="build") # generated + variant("maeparser", default=True, description="Use MAE parser") variant("example", default=False, description="Build sample executable") variant("shared", default=True, description="Build as shared library") diff --git a/var/spack/repos/builtin/packages/coral/package.py b/var/spack/repos/builtin/packages/coral/package.py index 56e20a06391704..7d55cfbc88e5c6 100644 --- a/var/spack/repos/builtin/packages/coral/package.py +++ b/var/spack/repos/builtin/packages/coral/package.py @@ -18,6 +18,8 @@ class Coral(CMakePackage): version("3.3.10", tag="CORAL_3_3_10", commit="d79c4d94f74e8eaf518841e70c70c1d9b2f816fe") version("3.3.3", tag="CORAL_3_3_3", commit="1c0393b2aa8d03748208ce564070d96f1bbd0c29") + + depends_on("cxx", type="build") # generated variant("binary_tag", default="auto", description="Build type") depends_on("ninja") diff --git a/var/spack/repos/builtin/packages/coreutils/package.py b/var/spack/repos/builtin/packages/coreutils/package.py index e5122166dab37a..aaf868e1c3534c 100644 --- a/var/spack/repos/builtin/packages/coreutils/package.py +++ b/var/spack/repos/builtin/packages/coreutils/package.py @@ -24,6 +24,7 @@ class Coreutils(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-or-later") + version("9.5", sha256="cd328edeac92f6a665de9f323c93b712af1858bc2e0d88f3f7100469470a1b8a") version("9.4", sha256="ea613a4cf44612326e917201bbbcdfbd301de21ffc3b59b6e5c07e040b275e52") version("9.3", sha256="adbcfcfe899235b71e8768dcf07cd532520b7f54f9a8064843f8d199a904bbaa") version("9.2", sha256="6885ff47b9cdb211de47d368c17853f406daaf98b148aaecdf10de29cc04b0b3") @@ -36,6 +37,8 @@ class Coreutils(AutotoolsPackage, GNUMirrorPackage): version("8.26", sha256="155e94d748f8e2bc327c66e0cbebdb8d6ab265d2f37c3c928f7bf6c3beba9a8e") version("8.23", sha256="ec43ca5bcfc62242accb46b7f121f6b684ee21ecd7d075059bf650ff9e37b82d") + depends_on("c", type="build") # generated + variant( "gprefix", default=False, diff --git a/var/spack/repos/builtin/packages/cosign/package.py b/var/spack/repos/builtin/packages/cosign/package.py index 5320ab9fb013ef..ef834f703d3047 100644 --- a/var/spack/repos/builtin/packages/cosign/package.py +++ b/var/spack/repos/builtin/packages/cosign/package.py @@ -21,6 +21,7 @@ class Cosign(Package): license("Apache-2.0") version("main", branch="main") + version("2.2.4", sha256="2e31e8638de1869514cb0478796d2b55b455552fbd03c3b7ba0edf27b0b5b944") version("1.3.1", sha256="7f7e0af52ee8d795440e66dcc1a7a25783e22d30935f4f957779628b348f38af") depends_on("go", type="build") diff --git a/var/spack/repos/builtin/packages/cosma/package.py b/var/spack/repos/builtin/packages/cosma/package.py index 77a9ba7b69a1c4..3bc12ac1b8e2b8 100644 --- a/var/spack/repos/builtin/packages/cosma/package.py +++ b/var/spack/repos/builtin/packages/cosma/package.py @@ -36,6 +36,8 @@ class Cosma(CMakePackage): version("2.0.7", sha256="8d70bfcbda6239b6a8fbeaca138790bbe58c0c3aa576879480d2632d4936cf7e") version("2.0.2", sha256="4f3354828bc718f3eef2f0098c3bdca3499297497a220da32db1acd57920c68d") + depends_on("cxx", type="build") # generated + # We just need the libraries of cuda and rocm, so no need to extend # CudaPackage or ROCmPackage. variant("cuda", default=False, description="Build with cuBLAS support") diff --git a/var/spack/repos/builtin/packages/cosmomc/package.py b/var/spack/repos/builtin/packages/cosmomc/package.py index 9e66b8938af2d8..6bb14da1c4c7e7 100644 --- a/var/spack/repos/builtin/packages/cosmomc/package.py +++ b/var/spack/repos/builtin/packages/cosmomc/package.py @@ -23,6 +23,9 @@ class Cosmomc(Package): version("2016.11", sha256="b83edbf043ff83a4dde9bc14c56a09737dbc41ffe247a8e9c9a26892ed8745ba") version("2016.06", sha256="23fa23eef40846c17d3740be63a7fefde13880cbb81545a44d14034277d9ffc0") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + def url_for_version(self, version): names = {"2016.11": "Nov2016", "2016.06": "June2016"} return "https://github.com/cmbant/CosmoMC/archive/%s.tar.gz" % names[str(version)] diff --git a/var/spack/repos/builtin/packages/cosp2/package.py b/var/spack/repos/builtin/packages/cosp2/package.py index d16466bad6bf48..d66a22f09c3d4e 100644 --- a/var/spack/repos/builtin/packages/cosp2/package.py +++ b/var/spack/repos/builtin/packages/cosp2/package.py @@ -21,6 +21,8 @@ class Cosp2(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + variant("double", default=True, description="Build with double precision.") variant("mpi", default=True, description="Build with MPI Support") diff --git a/var/spack/repos/builtin/packages/costa/package.py b/var/spack/repos/builtin/packages/costa/package.py index 4e85387a88580a..3070e78a42effd 100644 --- a/var/spack/repos/builtin/packages/costa/package.py +++ b/var/spack/repos/builtin/packages/costa/package.py @@ -28,6 +28,8 @@ class Costa(CMakePackage): version("2.1", sha256="c1e86452415083f7470b292d93ec60708b7c8dbafc2bac383636bb4b28135866") version("2.0", sha256="de250197f31f7d23226c6956a687c3ff46fb0ff6c621a932428236c3f7925fe4") + depends_on("cxx", type="build") # generated + variant("scalapack", default=False, description="Build with ScaLAPACK API") variant("shared", default=True, description="Build shared libraries") variant("profiling", default=False, description="Enable profiling") diff --git a/var/spack/repos/builtin/packages/cotter/package.py b/var/spack/repos/builtin/packages/cotter/package.py index c38d5352e70e8b..f1ab277344174c 100644 --- a/var/spack/repos/builtin/packages/cotter/package.py +++ b/var/spack/repos/builtin/packages/cotter/package.py @@ -15,6 +15,8 @@ class Cotter(CMakePackage): version("master", branch="master") version("20190205", commit="b7b07f3298a8d57b9dfff0b72fc21e68b23a42da") + depends_on("cxx", type="build") # generated + depends_on("erfa") depends_on("pal") depends_on("aoflagger") diff --git a/var/spack/repos/builtin/packages/countdown/package.py b/var/spack/repos/builtin/packages/countdown/package.py index b2ba2aab72e163..c3aa9a9db1438a 100644 --- a/var/spack/repos/builtin/packages/countdown/package.py +++ b/var/spack/repos/builtin/packages/countdown/package.py @@ -21,6 +21,8 @@ class Countdown(CMakePackage, CudaPackage): version("1.1.1", sha256="ee7f00ffc047f000a21a7a71f6ea6f4049afb1a8407608adc04993929ceba917") + depends_on("c", type="build") # generated + variant( "acc_mpi", default=True, diff --git a/var/spack/repos/builtin/packages/covfie/package.py b/var/spack/repos/builtin/packages/covfie/package.py new file mode 100644 index 00000000000000..2b88af03d117e7 --- /dev/null +++ b/var/spack/repos/builtin/packages/covfie/package.py @@ -0,0 +1,39 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Covfie(CMakePackage, CudaPackage): + """ + Covfie is a library for compositional descriptions of storage methods for + vector fields and other structured multi-dimensional data. + """ + + homepage = "https://github.com/acts-project/covfie" + url = "https://github.com/acts-project/covfie/archive/refs/tags/v0.1.0.tar.gz" + list_url = "https://github.com/acts-project/covfie/tags" + + license("MPL-2.0") + + maintainers("stephenswat") + + version("0.10.0", sha256="d44142b302ffc193ad2229f1d2cc6d8d720dd9da8c37989ada4f23018f86c964") + + depends_on("cxx", type="build") # generated + + variant("concepts", default=False, description="Enforce C++20 concepts") + + depends_on("cmake@3.18:", type="build") + + def cmake_args(self): + args = [ + self.define("COVFIE_PLATFORM_CPU", True), + self.define_from_variant("COVFIE_PLATFORM_CUDA", "cuda"), + self.define_from_variant("COVFIE_REQUIRE_CXX20", "concepts"), + self.define("COVFIE_QUIET", True), + ] + + return args diff --git a/var/spack/repos/builtin/packages/cp2k/package.py b/var/spack/repos/builtin/packages/cp2k/package.py index 8e626999043f18..014b2243122e79 100644 --- a/var/spack/repos/builtin/packages/cp2k/package.py +++ b/var/spack/repos/builtin/packages/cp2k/package.py @@ -56,6 +56,10 @@ class Cp2k(MakefilePackage, CMakePackage, CudaPackage, ROCmPackage): version("7.1", sha256="ccd711a09a426145440e666310dd01cc5772ab103493c4ae6a3470898cd0addb") version("master", branch="master", submodules="True") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("openmp", default=True, description="Enable OpenMP support") variant( @@ -169,14 +173,14 @@ class Cp2k(MakefilePackage, CMakePackage, CudaPackage, ROCmPackage): depends_on("cray-libsci+openmp", when="^[virtuals=blas] cray-libsci") with when("smm=libxsmm"): - depends_on("libxsmm@1.17:~header-only", when="@9.1:") + depends_on("libxsmm~header-only") # require libxsmm-1.11+ since 1.10 can leak file descriptors in Fortran - depends_on("libxsmm@1.11:~header-only", when="@:8.9") + depends_on("libxsmm@1.11:") + depends_on("libxsmm@1.17:", when="@9.1:") + # build needs to be fixed for libxsmm@2 once it is released + depends_on("libxsmm@:1") # use pkg-config (support added in libxsmm-1.10) to link to libxsmm depends_on("pkgconfig", type="build") - # please set variants: smm=blas by configuring packages.yaml or install - # cp2k with option smm=blas on aarch64 - conflicts("target=aarch64:", msg="libxsmm is not available on arm") with when("+libint"): depends_on("pkgconfig", type="build", when="@7.0:") @@ -224,11 +228,23 @@ class Cp2k(MakefilePackage, CMakePackage, CudaPackage, ROCmPackage): depends_on("elpa@2023.05.001:", when="@2023.2:") with when("+dlaf"): - depends_on("dla-future@0.2.1: +scalapack") - depends_on("dla-future ~cuda", when="~cuda") - depends_on("dla-future ~rocm", when="~rocm") - depends_on("dla-future +cuda", when="+cuda") - depends_on("dla-future +rocm", when="+rocm") + with when("@:2024.1"): + depends_on("dla-future@0.2.1: +scalapack") + depends_on("dla-future ~cuda", when="~cuda") + depends_on("dla-future ~rocm", when="~rocm") + depends_on("dla-future +cuda", when="+cuda") + depends_on("dla-future +rocm", when="+rocm") + + with when("@master"): + depends_on("dla-future-fortran@0.1.0:") + + # Use a direct dependency on dla-future so that constraints can be expressed + # WARN: In the concretizer output, dla-future will appear as dependency of CP2K + # instead of dla-future-fortran + depends_on("dla-future ~cuda", when="~cuda") + depends_on("dla-future ~rocm", when="~rocm") + depends_on("dla-future +cuda", when="+cuda") + depends_on("dla-future +rocm", when="+rocm") with when("+plumed"): depends_on("plumed+shared") @@ -276,6 +292,8 @@ class Cp2k(MakefilePackage, CMakePackage, CudaPackage, ROCmPackage): depends_on("dbcsr+mpi", when="+mpi") depends_on("dbcsr+cuda", when="+cuda") depends_on("dbcsr+rocm", when="+rocm") + depends_on("dbcsr smm=libxsmm", when="smm=libxsmm") + depends_on("dbcsr smm=blas", when="smm=blas") with when("@2022: +rocm"): depends_on("hipblas") @@ -460,78 +478,6 @@ def edit(self, pkg, spec, prefix): if "superlu-dist@4.3" in spec: ldflags.insert(0, "-Wl,--allow-multiple-definition") - if "+plumed" in spec: - dflags.extend(["-D__PLUMED2"]) - cppflags.extend(["-D__PLUMED2"]) - libs.extend([join_path(spec["plumed"].prefix.lib, "libplumed.{0}".format(dso_suffix))]) - - cc = spack_cc if "~mpi" in spec else spec["mpi"].mpicc - cxx = spack_cxx if "~mpi" in spec else spec["mpi"].mpicxx - fc = spack_fc if "~mpi" in spec else spec["mpi"].mpifc - - # Intel - if "%intel" in spec: - cppflags.extend(["-D__INTEL", "-D__HAS_ISO_C_BINDING", "-D__USE_CP2K_TRACE"]) - fcflags.extend(["-diag-disable 8290,8291,10010,10212,11060", "-free", "-fpp"]) - - # FFTW, LAPACK, BLAS - lapack = spec["lapack"].libs - blas = spec["blas"].libs - ldflags.append((lapack + blas).search_flags) - libs.extend([str(x) for x in (fftw.libs, lapack, blas)]) - - if spec.satisfies("platform=darwin"): - cppflags.extend(["-D__NO_STATM_ACCESS"]) - - if spec["blas"].name in ("intel-mkl", "intel-parallel-studio", "intel-oneapi-mkl"): - cppflags += ["-D__MKL"] - elif spec["blas"].name == "accelerate": - cppflags += ["-D__ACCELERATE"] - - if "+cosma" in spec: - # add before ScaLAPACK to override the p?gemm symbols - cosma = spec["cosma"].libs - ldflags.append(cosma.search_flags) - libs.extend(cosma) - - # MPI - if "+mpi" in spec: - cppflags.extend(["-D__parallel", "-D__SCALAPACK"]) - - if spec["mpi"].name == "intel-oneapi-mpi": - mpi = [join_path(spec["intel-oneapi-mpi"].libs.directories[0], "libmpi.so")] - else: - mpi = spec["mpi:cxx"].libs - - # while intel-mkl has a mpi variant and adds the scalapack - # libs to its libs, intel-oneapi-mkl does not. - if spec["scalapack"].name == "intel-oneapi-mkl": - mpi_impl = "openmpi" if spec["mpi"].name in ["openmpi", "hpcx-mpi"] else "intelmpi" - scalapack = [ - join_path( - spec["intel-oneapi-mkl"].libs.directories[0], "libmkl_scalapack_lp64.so" - ), - join_path( - spec["intel-oneapi-mkl"].libs.directories[0], - "libmkl_blacs_{0}_lp64.so".format(mpi_impl), - ), - ] - else: - scalapack = spec["scalapack"].libs - ldflags.append(scalapack.search_flags) - - libs.extend(scalapack) - libs.extend(mpi) - libs.extend(pkg.compiler.stdcxx_libs) - - if "+mpi_f08" in spec: - cppflags.append("-D__MPI_F08") - - if "wannier90" in spec: - cppflags.append("-D__WANNIER90") - wannier = join_path(spec["wannier90"].libs.directories[0], "libwannier.a") - libs.append(wannier) - if "+libint" in spec: cppflags += ["-D__LIBINT"] @@ -632,6 +578,91 @@ def edit(self, pkg, spec, prefix): fcflags += ["-I{0}".format(sirius.prefix.include.sirius)] libs += list(sirius.libs) + if "+plumed" in spec: + dflags.extend(["-D__PLUMED2"]) + cppflags.extend(["-D__PLUMED2"]) + libs.extend([join_path(spec["plumed"].prefix.lib, "libplumed.{0}".format(dso_suffix))]) + + if "+libvori" in spec: + cppflags += ["-D__LIBVORI"] + libvori = spec["libvori"].libs + ldflags += [libvori.search_flags] + libs += libvori + libs += ["-lstdc++"] + + if "+spglib" in spec: + cppflags += ["-D__SPGLIB"] + spglib = spec["spglib"].libs + ldflags += [spglib.search_flags] + libs += spglib + + cc = spack_cc if "~mpi" in spec else spec["mpi"].mpicc + cxx = spack_cxx if "~mpi" in spec else spec["mpi"].mpicxx + fc = spack_fc if "~mpi" in spec else spec["mpi"].mpifc + + # Intel + if "%intel" in spec: + cppflags.extend(["-D__INTEL", "-D__HAS_ISO_C_BINDING", "-D__USE_CP2K_TRACE"]) + fcflags.extend(["-diag-disable 8290,8291,10010,10212,11060", "-free", "-fpp"]) + + # FFTW, LAPACK, BLAS + lapack = spec["lapack"].libs + blas = spec["blas"].libs + ldflags.append((lapack + blas).search_flags) + libs.extend([str(x) for x in (fftw.libs, lapack, blas)]) + + if spec.satisfies("platform=darwin"): + cppflags.extend(["-D__NO_STATM_ACCESS"]) + + if spec["blas"].name in ("intel-mkl", "intel-parallel-studio", "intel-oneapi-mkl"): + cppflags += ["-D__MKL"] + elif spec["blas"].name == "accelerate": + cppflags += ["-D__ACCELERATE"] + + if "+cosma" in spec: + # add before ScaLAPACK to override the p?gemm symbols + cosma = spec["cosma"].libs + ldflags.append(cosma.search_flags) + libs.extend(cosma) + + # MPI + if "+mpi" in spec: + cppflags.extend(["-D__parallel", "-D__SCALAPACK"]) + + if spec["mpi"].name == "intel-oneapi-mpi": + mpi = [join_path(spec["intel-oneapi-mpi"].libs.directories[0], "libmpi.so")] + else: + mpi = spec["mpi:cxx"].libs + + # while intel-mkl has a mpi variant and adds the scalapack + # libs to its libs, intel-oneapi-mkl does not. + if spec["scalapack"].name == "intel-oneapi-mkl": + mpi_impl = "openmpi" if spec["mpi"].name in ["openmpi", "hpcx-mpi"] else "intelmpi" + scalapack = [ + join_path( + spec["intel-oneapi-mkl"].libs.directories[0], "libmkl_scalapack_lp64.so" + ), + join_path( + spec["intel-oneapi-mkl"].libs.directories[0], + "libmkl_blacs_{0}_lp64.so".format(mpi_impl), + ), + ] + else: + scalapack = spec["scalapack"].libs + ldflags.append(scalapack.search_flags) + + libs.extend(scalapack) + libs.extend(mpi) + libs.extend(pkg.compiler.stdcxx_libs) + + if "+mpi_f08" in spec: + cppflags.append("-D__MPI_F08") + + if "wannier90" in spec: + cppflags.append("-D__WANNIER90") + wannier = join_path(spec["wannier90"].libs.directories[0], "libwannier.a") + libs.append(wannier) + gpuver = "" if spec.satisfies("+cuda"): libs += [ @@ -719,19 +750,6 @@ def edit(self, pkg, spec, prefix): fcflags += pkgconf("--cflags-only-I", "libxsmmf", output=str).split() libs += pkgconf("--libs", "libxsmmf", output=str).split() - if "+libvori" in spec: - cppflags += ["-D__LIBVORI"] - libvori = spec["libvori"].libs - ldflags += [libvori.search_flags] - libs += libvori - libs += ["-lstdc++"] - - if "+spglib" in spec: - cppflags += ["-D__SPGLIB"] - spglib = spec["spglib"].libs - ldflags += [spglib.search_flags] - libs += spglib - dflags.extend(cppflags) cflags.extend(cppflags) cxxflags.extend(cppflags) diff --git a/var/spack/repos/builtin/packages/cpio/package.py b/var/spack/repos/builtin/packages/cpio/package.py index 0ae7ac02204072..5b743a829849be 100644 --- a/var/spack/repos/builtin/packages/cpio/package.py +++ b/var/spack/repos/builtin/packages/cpio/package.py @@ -20,9 +20,12 @@ class Cpio(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-or-later") + version("2.15", sha256="efa50ef983137eefc0a02fdb51509d624b5e3295c980aa127ceee4183455499e") version("2.14", sha256="145a340fd9d55f0b84779a44a12d5f79d77c99663967f8cfa168d7905ca52454") version("2.13", sha256="e87470d9c984317f658567c03bfefb6b0c829ff17dbf6b0de48d71a4c8f3db88") + depends_on("c", type="build") # generated + build_directory = "spack-build" def patch(self): diff --git a/var/spack/repos/builtin/packages/cpmd/package.py b/var/spack/repos/builtin/packages/cpmd/package.py index 61977a370669a7..8bc10da0c50ae0 100644 --- a/var/spack/repos/builtin/packages/cpmd/package.py +++ b/var/spack/repos/builtin/packages/cpmd/package.py @@ -18,6 +18,9 @@ class Cpmd(MakefilePackage): version("4.3", sha256="e0290f9da0d255f90a612e60662b14a97ca53003f89073c6af84fa7bc8739f65") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("omp", description="Enables the use of OMP instructions", default=False) variant("mpi", description="Build with MPI support", default=False) diff --git a/var/spack/repos/builtin/packages/cpp-argparse/package.py b/var/spack/repos/builtin/packages/cpp-argparse/package.py index 509724a3fc661f..5241608a8ad118 100644 --- a/var/spack/repos/builtin/packages/cpp-argparse/package.py +++ b/var/spack/repos/builtin/packages/cpp-argparse/package.py @@ -18,3 +18,5 @@ class CppArgparse(CMakePackage): version("2.9", sha256="cd563293580b9dc592254df35b49cf8a19b4870ff5f611c7584cf967d9e6031e") version("2.2", sha256="f0fc6ab7e70ac24856c160f44ebb0dd79dc1f7f4a614ee2810d42bb73799872b") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/cpp-httplib/package.py b/var/spack/repos/builtin/packages/cpp-httplib/package.py index 04874b3a9e62e3..1fa77baa286c18 100644 --- a/var/spack/repos/builtin/packages/cpp-httplib/package.py +++ b/var/spack/repos/builtin/packages/cpp-httplib/package.py @@ -14,6 +14,7 @@ class CppHttplib(CMakePackage): license("MIT") + version("0.15.3", sha256="2121bbf38871bb2aafb5f7f2b9b94705366170909f434428352187cb0216124e") version("0.12.5", sha256="b488f3fa9c6bf35608c3d9a5b69be52e016bbf2fbfe67e5ee684eadb2655493e") version("0.12.3", sha256="175ced3c9cdaf221e9edf210297568d8f7d402a41d6db01254ac9e0b25487c54") version("0.5.9", sha256="c9e7aef3b0d4e80ee533d10413508d8a6e09a67d0d59646c43111f3993de006e") @@ -29,3 +30,5 @@ class CppHttplib(CMakePackage): version("0.3.3", sha256="476471c6fcd4b39fc79a5dd6ad343a2428cb69b4d528557abb6a0b7bf8186e34") version("0.2.6", sha256="8678afc0e69bc198edcb8fe0066e46a87373221232ebabde2d78c237f31d3c3d") version("0.2.1", sha256="94a6ddd25088b66b7b9e57b9d0ea138c984967e91b21395401642027bf279438") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/cpp-logger/package.py b/var/spack/repos/builtin/packages/cpp-logger/package.py index 2784ea219eef35..eb79d36a3520cb 100644 --- a/var/spack/repos/builtin/packages/cpp-logger/package.py +++ b/var/spack/repos/builtin/packages/cpp-logger/package.py @@ -17,5 +17,9 @@ class CppLogger(CMakePackage): version("develop", branch="develop") version("master", branch="master") - version("0.0.1", tag="v0.0.1", commit="d48b38ab14477bb7c53f8189b8b4be2ea214c28a") + version("0.0.4", tag="v0.0.4", commit="2231deee4b74fb1ddae3dae0618baaead4fecf75") + version("0.0.3", tag="v0.0.3", commit="398e6fa1eb4442cba94d46ecacfa47a426474387") version("0.0.2", tag="v0.0.2", commit="329a48401033d2d2a1f1196141763cab029220ae") + version("0.0.1", tag="v0.0.1", commit="d48b38ab14477bb7c53f8189b8b4be2ea214c28a") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/cpp-termcolor/package.py b/var/spack/repos/builtin/packages/cpp-termcolor/package.py index 93954c23c997f1..c99e233fc113fa 100644 --- a/var/spack/repos/builtin/packages/cpp-termcolor/package.py +++ b/var/spack/repos/builtin/packages/cpp-termcolor/package.py @@ -19,6 +19,8 @@ class CppTermcolor(CMakePackage): version("2.0.0", sha256="4a73a77053822ca1ed6d4a2af416d31028ec992fb0ffa794af95bd6216bb6a20") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.0:", type="build") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/cppad/package.py b/var/spack/repos/builtin/packages/cppad/package.py index dcc9e14cf9cbc5..6ca15a825e4850 100644 --- a/var/spack/repos/builtin/packages/cppad/package.py +++ b/var/spack/repos/builtin/packages/cppad/package.py @@ -9,14 +9,42 @@ class Cppad(CMakePackage): """A Package for Differentiation of C++ Algorithms.""" - homepage = "https://www.coin-or.org/CppAD/" - url = "http://www.coin-or.org/download/source/CppAD/cppad-20170114.gpl.tgz" + homepage = "https://github.com/coin-or/CppAD" + url = "https://github.com/coin-or/CppAD/archive/refs/tags/20240000.4.tar.gz" git = "https://github.com/coin-or/CppAD.git" - version("develop", branch="master") - version("20170114", sha256="fa3980a882be2a668a7522146273a1b4f1d8dabe66ad4aafa8964c8c1fd6f957") + maintainers("whart222") + + version("master", branch="master") + version( + "20240000.4", sha256="0dfc1e30b32d5dd3086ee3adb6d2746a019e9d670b644c4d5ec1df3c35dd1fe5" + ) + version( + "20220000.5", sha256="9fb4562f6169855eadcd86ac4671593d1c0edf97bb6ce7cbb28e19af2bfc165e" + ) + version( + "20180000.0", + sha256="a5226e4c5aa2ad6d95668f987b39939315bf134a0a793231984e6d42d6488cca", + deprecated=True, + ) + version( + "20170114", + sha256="fa3980a882be2a668a7522146273a1b4f1d8dabe66ad4aafa8964c8c1fd6f957", + deprecated=True, + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated def cmake_args(self): - # This package does not obey CMAKE_INSTALL_PREFIX - args = ["-Dcppad_prefix=%s" % (self.prefix), "-Dcmake_install_docdir=share/cppad/doc"] + # NOTE: This package does not obey CMAKE_INSTALL_PREFIX + args = [ + self.define("cppad_prefix", self.prefix), + self.define("CMAKE_BUILD_TYPE", "Release"), + # + # Installing documents sometimes fails. + # + # self.define("cmake_install_docdir", "share/cppad/doc"), + ] + return args diff --git a/var/spack/repos/builtin/packages/cppcheck/package.py b/var/spack/repos/builtin/packages/cppcheck/package.py index fbda439345b37c..0874acd21a2864 100644 --- a/var/spack/repos/builtin/packages/cppcheck/package.py +++ b/var/spack/repos/builtin/packages/cppcheck/package.py @@ -30,6 +30,9 @@ class Cppcheck(CMakePackage): version("1.72", sha256="9460b184ff2d8dd15344f3e2f42f634c86e4dd3303e1e9b3f13dc67536aab420") version("1.68", sha256="add6e5e12b05ca02b356cd0ec7420ae0dcafddeaef183b4dfbdef59c617349b1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("rules", default=False, description="Enable rules (requires PCRE)") variant("htmlreport", default=False, description="Install cppcheck-htmlreport") diff --git a/var/spack/repos/builtin/packages/cppcodec/package.py b/var/spack/repos/builtin/packages/cppcodec/package.py index 1cee1f9ad1e93f..29f342bd95ff54 100644 --- a/var/spack/repos/builtin/packages/cppcodec/package.py +++ b/var/spack/repos/builtin/packages/cppcodec/package.py @@ -19,4 +19,6 @@ class Cppcodec(CMakePackage): version("0.2", sha256="0edaea2a9d9709d456aa99a1c3e17812ed130f9ef2b5c2d152c230a5cbc5c482") + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8:", type="build") diff --git a/var/spack/repos/builtin/packages/cppcoro/package.py b/var/spack/repos/builtin/packages/cppcoro/package.py index ac998ace01c62e..f928c954d8ffcd 100644 --- a/var/spack/repos/builtin/packages/cppcoro/package.py +++ b/var/spack/repos/builtin/packages/cppcoro/package.py @@ -19,4 +19,6 @@ class Cppcoro(CMakePackage): version("develop", branch="master") version("2021-01-13", commit="7cc9433436fe8f2482138019cfaafce8e1d7a896") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.12:", type="build") diff --git a/var/spack/repos/builtin/packages/cppgsl/package.py b/var/spack/repos/builtin/packages/cppgsl/package.py index a797e6eefc0cb7..9f63fbb1320ab2 100644 --- a/var/spack/repos/builtin/packages/cppgsl/package.py +++ b/var/spack/repos/builtin/packages/cppgsl/package.py @@ -22,6 +22,8 @@ class Cppgsl(CMakePackage): version("2.0.0", sha256="6cce6fb16b651e62711a4f58e484931013c33979b795d1b1f7646f640cfa9c8e") version("1.0.0", sha256="9694b04cd78e5b1a769868f19fdd9eea2002de3d4c3a81a1b769209364543c36") + depends_on("cxx", type="build") # generated + variant( "cxxstd", default="14", diff --git a/var/spack/repos/builtin/packages/cpprestsdk/package.py b/var/spack/repos/builtin/packages/cpprestsdk/package.py index 403e8bc42e98b5..94ac694297652b 100644 --- a/var/spack/repos/builtin/packages/cpprestsdk/package.py +++ b/var/spack/repos/builtin/packages/cpprestsdk/package.py @@ -25,6 +25,9 @@ class Cpprestsdk(CMakePackage): ) version("2.9.1", sha256="537358760acd782f4d2ed3a85d92247b4fc423aff9c85347dc31dbb0ab9bab16") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on( "boost@1.69.0: +random+chrono+locale+filesystem+system+exception+regex+thread+date_time" ) diff --git a/var/spack/repos/builtin/packages/cppunit/package.py b/var/spack/repos/builtin/packages/cppunit/package.py index 1fdba0c399cb54..016b6b67f468e9 100644 --- a/var/spack/repos/builtin/packages/cppunit/package.py +++ b/var/spack/repos/builtin/packages/cppunit/package.py @@ -24,6 +24,8 @@ class Cppunit(AutotoolsPackage): ) version("1.13.2", sha256="3f47d246e3346f2ba4d7c9e882db3ad9ebd3fcbd2e8b732f946e0e3eeb9f429f") + depends_on("cxx", type="build") # generated + # https://github.com/cms-sw/cmsdist/blob/IB/CMSSW_12_6_X/master/cppunit-1.14-defaulted-function-deleted.patch patch("cppunit-1.14-defaulted-function-deleted.patch", when="@1.15:") diff --git a/var/spack/repos/builtin/packages/cppzmq/package.py b/var/spack/repos/builtin/packages/cppzmq/package.py index 84ebbcf5359612..669a95e707417f 100644 --- a/var/spack/repos/builtin/packages/cppzmq/package.py +++ b/var/spack/repos/builtin/packages/cppzmq/package.py @@ -18,6 +18,7 @@ class Cppzmq(CMakePackage): license("MIT") version("master", branch="master") + version("4.10.0", sha256="c81c81bba8a7644c84932225f018b5088743a22999c6d82a2b5f5cd1e6942b74") version("4.9.0", sha256="3fdf5b100206953f674c94d40599bdb3ea255244dcc42fab0d75855ee3645581") version("4.8.1", sha256="7a23639a45f3a0049e11a188e29aaedd10b2f4845f0000cf3e22d6774ebde0af") version("4.7.1", sha256="9853e0437d834cbed5d3c223bf1d755cadee70e7c964c6e42c4c6783dee5d02c") @@ -29,6 +30,8 @@ class Cppzmq(CMakePackage): version("4.2.3", sha256="3e6b57bf49115f4ae893b1ff7848ead7267013087dc7be1ab27636a97144d373") version("4.2.2", sha256="3ef50070ac5877c06c6bb25091028465020e181bbfd08f110294ed6bc419737d") + depends_on("cxx", type="build") # generated + variant("drafts", default=False, description="Build and install draft classes and methods") depends_on("cmake@3.0.0:", type="build") diff --git a/var/spack/repos/builtin/packages/cpr/package.py b/var/spack/repos/builtin/packages/cpr/package.py index 93cff509b40a2e..9c5e7d82c6e35b 100644 --- a/var/spack/repos/builtin/packages/cpr/package.py +++ b/var/spack/repos/builtin/packages/cpr/package.py @@ -19,6 +19,8 @@ class Cpr(CMakePackage): version("1.10.4", sha256="88462d059cd3df22c4d39ae04483ed50dfd2c808b3effddb65ac3b9aa60b542d") version("1.9.2", sha256="3bfbffb22c51f322780d10d3ca8f79424190d7ac4b5ad6ad896de08dbd06bf31") + depends_on("cxx", type="build") # generated + depends_on("curl") depends_on("git", type="build") diff --git a/var/spack/repos/builtin/packages/cprnc/package.py b/var/spack/repos/builtin/packages/cprnc/package.py index 9e4282879e05fd..c719c107155cc5 100644 --- a/var/spack/repos/builtin/packages/cprnc/package.py +++ b/var/spack/repos/builtin/packages/cprnc/package.py @@ -20,6 +20,8 @@ class Cprnc(CMakePackage): version("1.0.1", sha256="b8a8fd4ad7e2716968dfa60f677217c55636580807b1309276f4c062ee432ccd") version("1.0.0", sha256="70ff75bbf01a0cef885db3074c78f39a8890949ca505530c0407398b8803552c") + depends_on("fortran", type="build") # generated + depends_on("netcdf-fortran") depends_on("cmake@3:", type="build") diff --git a/var/spack/repos/builtin/packages/cpu-features/package.py b/var/spack/repos/builtin/packages/cpu-features/package.py index 0ec7b1969560a9..1e4e0c246f6b5e 100644 --- a/var/spack/repos/builtin/packages/cpu-features/package.py +++ b/var/spack/repos/builtin/packages/cpu-features/package.py @@ -20,6 +20,9 @@ class CpuFeatures(CMakePackage): version("0.9.0", sha256="bdb3484de8297c49b59955c3b22dba834401bc2df984ef5cfc17acbe69c5018e") version("0.7.0", sha256="df80d9439abf741c7d2fdcdfd2d26528b136e6c52976be8bd0cd5e45a27262c0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", description="Build shared libraries", default=False) depends_on("cmake@3.0.0:", type="build") diff --git a/var/spack/repos/builtin/packages/cpuinfo/package.py b/var/spack/repos/builtin/packages/cpuinfo/package.py index bfae3aa4946dde..fd990da38af3bd 100644 --- a/var/spack/repos/builtin/packages/cpuinfo/package.py +++ b/var/spack/repos/builtin/packages/cpuinfo/package.py @@ -3,6 +3,8 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import sys + from spack.package import * @@ -17,7 +19,9 @@ class Cpuinfo(CMakePackage): license("BSD-2-Clause") version("main", branch="main") - version("2022-08-19", commit="8ec7bd91ad0470e61cf38f618cc1f270dede599c") # py-torch@1.13 + version("2023-11-04", commit="d6860c477c99f1fce9e28eb206891af3c0e1a1d7") # py-torch@2.3: + version("2023-01-13", commit="6481e8bef08f606ddd627e4d3be89f64d62e1b8a") # py-torch@2.1:2.2 + version("2022-08-19", commit="8ec7bd91ad0470e61cf38f618cc1f270dede599c") # py-torch@1.13:2.0 version("2020-12-17", commit="5916273f79a21551890fd3d56fc5375a78d1598d") # py-torch@1.8:1.12 version("2020-06-11", commit="63b254577ed77a8004a9be6ac707f3dccc4e1fd9") # py-torch@1.6:1.7 version("2020-01-21", commit="0e6bde92b343c5fbcfe34ecd41abf9515d54b4a7") # py-torch@1.5 @@ -26,13 +30,23 @@ class Cpuinfo(CMakePackage): version("2018-05-13", commit="1e6c8c99d27f2b5eb9d2e6231055c6a4115b85e5") # py-torch@0.4.1 version("2018-04-04", commit="831dc28341b5f20d13e840caf87eaba644d82643") # py-torch@:0.4.0 + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@3.5:", type="build") def cmake_args(self): + # cpuinfo cannot produce a shared build with MSVC because it does not export + # any symbols + # cpuinfo CI builds "default" on Windows platform + build_type = "default" if sys.platform == "win32" else "shared" + # https://salsa.debian.org/deeplearning-team/cpuinfo/-/blob/master/debian/rules return [ - self.define("BUILD_SHARED_LIBS", True), self.define("CPUINFO_BUILD_UNIT_TESTS", False), self.define("CPUINFO_BUILD_MOCK_TESTS", False), self.define("CPUINFO_BUILD_BENCHMARKS", False), + self.define("CPUINFO_LIBRARY_TYPE", build_type), + self.define("CPUINFO_LOG_LEVEL", "error"), + self.define("CMAKE_SKIP_RPATH", True), ] diff --git a/var/spack/repos/builtin/packages/cqrlib/package.py b/var/spack/repos/builtin/packages/cqrlib/package.py index aaaf2264792381..e9a187d4caf969 100644 --- a/var/spack/repos/builtin/packages/cqrlib/package.py +++ b/var/spack/repos/builtin/packages/cqrlib/package.py @@ -18,6 +18,9 @@ class Cqrlib(MakefilePackage): version("1.1.2", sha256="af3cf2402974579f3c6efc6a6174a5da52786db4bfee9d38d504d93bc42410fd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libtool", type="build") patch("cqr.patch") diff --git a/var/spack/repos/builtin/packages/cquery/package.py b/var/spack/repos/builtin/packages/cquery/package.py index a00e3ea62ce639..58c918c6fcbfb6 100644 --- a/var/spack/repos/builtin/packages/cquery/package.py +++ b/var/spack/repos/builtin/packages/cquery/package.py @@ -16,6 +16,9 @@ class Cquery(CMakePackage): version("2018-08-23", commit="70c755b2e390d3edfb594a84a7531beb26b2bc07", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("llvm") # trivial patch (missing header) by mueller@kip.uni-heidelberg.de diff --git a/var/spack/repos/builtin/packages/cracklib/package.py b/var/spack/repos/builtin/packages/cracklib/package.py index 0042b18de8c8a8..564ae8a0f37536 100644 --- a/var/spack/repos/builtin/packages/cracklib/package.py +++ b/var/spack/repos/builtin/packages/cracklib/package.py @@ -22,6 +22,8 @@ class Cracklib(AutotoolsPackage): version("2.9.6", sha256="7cd2c01365f199c466b490ad2585beccbe0108ccd606c1bcc6c1e52800e627fe") version("2.9.5", sha256="b3fcf3fba2f4566f8eb2b79502d1a66198a71c557d2ab1011c78001489f0fe26") + depends_on("c", type="build") # generated + depends_on("python", type=("build", "run")) depends_on("gettext") depends_on("fmt") diff --git a/var/spack/repos/builtin/packages/cram/package.py b/var/spack/repos/builtin/packages/cram/package.py index 2aceaad214a891..0869adb08d09ed 100644 --- a/var/spack/repos/builtin/packages/cram/package.py +++ b/var/spack/repos/builtin/packages/cram/package.py @@ -14,6 +14,9 @@ class Cram(CMakePackage): version("1.0.1", sha256="985888018f6481c3e9ab4f1d1788e25725d8b92a1cf52b1366ee93793614709a") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + extends("python") depends_on("python@2.7:") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/cray-libsci/package.py b/var/spack/repos/builtin/packages/cray-libsci/package.py index e653aadc52f367..438cad5b356131 100644 --- a/var/spack/repos/builtin/packages/cray-libsci/package.py +++ b/var/spack/repos/builtin/packages/cray-libsci/package.py @@ -25,6 +25,9 @@ class CrayLibsci(Package): version("16.06.1") version("16.03.1") + conflicts("platform=windows") + conflicts("platform=darwin") + variant("shared", default=True, description="enable shared libs") variant("openmp", default=False, description="link with openmp") variant("mpi", default=False, description="link with mpi libs") diff --git a/var/spack/repos/builtin/packages/cray-mpich/package.py b/var/spack/repos/builtin/packages/cray-mpich/package.py index fb7405f44332fc..4b422bf38e2b97 100644 --- a/var/spack/repos/builtin/packages/cray-mpich/package.py +++ b/var/spack/repos/builtin/packages/cray-mpich/package.py @@ -70,18 +70,19 @@ def setup_run_environment(self, env): env.set("MPICXX", join_path(self.prefix.bin, "mpicxx")) env.set("MPIF77", join_path(self.prefix.bin, "mpif77")) env.set("MPIF90", join_path(self.prefix.bin, "mpif90")) - else: + elif spack_cc is not None: env.set("MPICC", spack_cc) env.set("MPICXX", spack_cxx) env.set("MPIF77", spack_fc) env.set("MPIF90", spack_fc) def setup_dependent_build_environment(self, env, dependent_spec): - env.set("MPICH_CC", spack_cc) - env.set("MPICH_CXX", spack_cxx) - env.set("MPICH_F77", spack_f77) - env.set("MPICH_F90", spack_fc) - env.set("MPICH_FC", spack_fc) + dependent_module = dependent_spec.package.module + env.set("MPICH_CC", dependent_module.spack_cc) + env.set("MPICH_CXX", dependent_module.spack_cxx) + env.set("MPICH_F77", dependent_module.spack_f77) + env.set("MPICH_F90", dependent_module.spack_fc) + env.set("MPICH_FC", dependent_module.spack_fc) def setup_dependent_package(self, module, dependent_spec): spec = self.spec @@ -90,7 +91,7 @@ def setup_dependent_package(self, module, dependent_spec): spec.mpicxx = join_path(self.prefix.bin, "mpicxx") spec.mpifc = join_path(self.prefix.bin, "mpif90") spec.mpif77 = join_path(self.prefix.bin, "mpif77") - else: + elif spack_cc is not None: spec.mpicc = spack_cc spec.mpicxx = spack_cxx spec.mpifc = spack_fc diff --git a/var/spack/repos/builtin/packages/cray-mvapich2/package.py b/var/spack/repos/builtin/packages/cray-mvapich2/package.py index 88615093d29016..b76d583c2b3d36 100644 --- a/var/spack/repos/builtin/packages/cray-mvapich2/package.py +++ b/var/spack/repos/builtin/packages/cray-mvapich2/package.py @@ -27,24 +27,29 @@ class CrayMvapich2(Package): provides("mpi@3") def setup_run_environment(self, env): + if spack_cc is None: + return + env.set("MPICC", spack_cc) env.set("MPICXX", spack_cxx) env.set("MPIF77", spack_fc) env.set("MPIF90", spack_fc) def setup_dependent_build_environment(self, env, dependent_spec): - env.set("MPICH_CC", spack_cc) - env.set("MPICH_CXX", spack_cxx) - env.set("MPICH_F77", spack_f77) - env.set("MPICH_F90", spack_fc) - env.set("MPICH_FC", spack_fc) + dependent_module = dependent_spec.package.module + env.set("MPICH_CC", dependent_module.spack_cc) + env.set("MPICH_CXX", dependent_module.spack_cxx) + env.set("MPICH_F77", dependent_module.spack_f77) + env.set("MPICH_F90", dependent_module.spack_fc) + env.set("MPICH_FC", dependent_module.spack_fc) def setup_dependent_package(self, module, dependent_spec): spec = self.spec - spec.mpicc = spack_cc - spec.mpicxx = spack_cxx - spec.mpifc = spack_fc - spec.mpif77 = spack_f77 + dependent_module = dependent_spec.package.module + spec.mpicc = dependent_module.spack_cc + spec.mpicxx = dependent_module.spack_cxx + spec.mpifc = dependent_module.spack_fc + spec.mpif77 = dependent_module.spack_f77 spec.mpicxx_shared_libs = [ join_path(self.prefix.lib, "libmpicxx.{0}".format(dso_suffix)), diff --git a/var/spack/repos/builtin/packages/creduce/package.py b/var/spack/repos/builtin/packages/creduce/package.py index d06a171995fb8b..cac9da7e6dc1eb 100644 --- a/var/spack/repos/builtin/packages/creduce/package.py +++ b/var/spack/repos/builtin/packages/creduce/package.py @@ -20,6 +20,9 @@ class Creduce(CMakePackage): version("develop", branch="master") version("2.10.0", tag="creduce-2.10.0", commit="fb91843c547794f165e5764a003166191e6c6643") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("flex") depends_on("libxml2") depends_on("llvm") diff --git a/var/spack/repos/builtin/packages/crmc/package.py b/var/spack/repos/builtin/packages/crmc/package.py index 0edb7bf18b53eb..3f4d4b77675164 100644 --- a/var/spack/repos/builtin/packages/crmc/package.py +++ b/var/spack/repos/builtin/packages/crmc/package.py @@ -23,6 +23,10 @@ class Crmc(CMakePackage): version("1.5.7", sha256="ec7456c08b60a40665e9ff31d6029e0151b0cdf2ca98bd09a8b570b1e33f6053") version("1.5.6", sha256="a546a9352dcbdb8a1df3d63530eacf16f8b64a190e224b72afd434f78388a8a0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("hepmc") depends_on("boost+filesystem+iostreams+system+program_options") depends_on("root") diff --git a/var/spack/repos/builtin/packages/cronie/package.py b/var/spack/repos/builtin/packages/cronie/package.py index 72ddb7c57f3a47..d9ac89f90cb65e 100644 --- a/var/spack/repos/builtin/packages/cronie/package.py +++ b/var/spack/repos/builtin/packages/cronie/package.py @@ -19,6 +19,8 @@ class Cronie(AutotoolsPackage): version("1.6.1", sha256="1ddbc8f8d07dfe1d45998b0a0cbd9a216cd4d7bc64d1626b2bc8b3a69e4641d1") version("1.5.5", sha256="22c2a2b22577c0f776c1268d0e0f305c5c041e10155022a345b43b665da0ffe9") + depends_on("c", type="build") # generated + def autoreconf(self, spec, prefix): bash = which("bash") bash("./autogen.sh") diff --git a/var/spack/repos/builtin/packages/crosstool-ng/package.py b/var/spack/repos/builtin/packages/crosstool-ng/package.py index 4c9865b35906f4..bb5c0b3f128e17 100644 --- a/var/spack/repos/builtin/packages/crosstool-ng/package.py +++ b/var/spack/repos/builtin/packages/crosstool-ng/package.py @@ -20,6 +20,8 @@ class CrosstoolNg(AutotoolsPackage): version("1.26.0", sha256="e8ce69c5c8ca8d904e6923ccf86c53576761b9cf219e2e69235b139c8e1b74fc") version("1.25.0", sha256="68162f342243cd4189ed7c1f4e3bb1302caa3f2cbbf8331879bd01fe06c60cd3") + depends_on("c", type="build") # generated + depends_on("ncurses") depends_on("bash", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/crtm-fix/package.py b/var/spack/repos/builtin/packages/crtm-fix/package.py index ef46e99df00eaf..ca8cb421c0fe45 100644 --- a/var/spack/repos/builtin/packages/crtm-fix/package.py +++ b/var/spack/repos/builtin/packages/crtm-fix/package.py @@ -18,6 +18,9 @@ class CrtmFix(Package): "BenjaminTJohnson", "edwardhartnett", "AlexanderRichert-NOAA", "Hang-Lei-NOAA", "climbfuji" ) + version( + "2.4.0.1_emc", sha256="6e4005b780435c8e280d6bfa23808d8f12609dfd72f77717d046d4795cac0457" + ) version("2.4.0_emc", sha256="d0f1b2ae2905457f4c3731746892aaa8f6b84ee0691f6228dfbe48917df1e85e") version("2.3.0_emc", sha256="1452af2d1d11d57ef3c57b6b861646541e7042a9b0f3c230f9a82854d7e90924") @@ -28,8 +31,11 @@ class CrtmFix(Package): conflicts("+big_endian", when="+little_endian", msg="big_endian and little_endian conflict") def url_for_version(self, version): - url = "ftp://ftp.ssec.wisc.edu/pub/s4/CRTM/fix_REL-{}.tgz" - return url.format(version) + if version == Version("2.4.0.1_emc"): + url = "ftp://ftp.ssec.wisc.edu/pub/s4/CRTM/fix_REL-2.4.0_emc_07112023.tgz" + else: + url = f"ftp://ftp.ssec.wisc.edu/pub/s4/CRTM/fix_REL-{version}.tgz" + return url def install(self, spec, prefix): spec = self.spec @@ -52,23 +58,27 @@ def install(self, spec, prefix): # Little_Endian amsua_metop-c_v2.SpcCoeff.bin is what it's supposed to be. # Remove the incorrect file, and install it as noACC,, then install # correct file under new name. - if "+big_endian" in spec and spec.version == Version("2.4.0_emc"): - remove_path = join_path( - os.getcwd(), "fix", "SpcCoeff", "Big_Endian", "amsua_metop-c.SpcCoeff.bin" + if "+big_endian" in spec and ( + spec.version in [Version("2.4.0_emc"), Version("2.4.0.1_emc")] + ): + amc_sc_path = join_path("SpcCoeff", "Big_Endian", "amsua_metop-c.SpcCoeff.bin") + amc_sc_v2_path = join_path( + "SpcCoeff", "Little_Endian", "amsua_metop-c_v2.SpcCoeff.bin" ) + # In 2.4.0_emc, the path is prefixed by 'fix/' + if spec.version == Version("2.4.0_emc"): + amc_sc_path = join_path("fix", amc_sc_path) + amc_sc_v2_path = join_path("fix", amc_sc_v2_path) + + remove_path = join_path(os.getcwd(), amc_sc_path) + fix_files.remove(remove_path) # This file is incorrect, install it as a different name. - install( - join_path("fix", "SpcCoeff", "Big_Endian", "amsua_metop-c.SpcCoeff.bin"), - join_path(self.prefix.fix, "amsua_metop-c.SpcCoeff.noACC.bin"), - ) + install(amc_sc_path, join_path(self.prefix.fix, "amsua_metop-c.SpcCoeff.noACC.bin")) # This "Little_Endian" file is actually the correct one. - install( - join_path("fix", "SpcCoeff", "Little_Endian", "amsua_metop-c_v2.SpcCoeff.bin"), - join_path(self.prefix.fix, "amsua_metop-c.SpcCoeff.bin"), - ) + install(amc_sc_v2_path, join_path(self.prefix.fix, "amsua_metop-c.SpcCoeff.bin")) for f in fix_files: install(f, self.prefix.fix) diff --git a/var/spack/repos/builtin/packages/crtm/package.py b/var/spack/repos/builtin/packages/crtm/package.py index c4626d09a23d9a..d876a245dd034c 100644 --- a/var/spack/repos/builtin/packages/crtm/package.py +++ b/var/spack/repos/builtin/packages/crtm/package.py @@ -28,33 +28,71 @@ class Crtm(CMakePackage): variant( "fix", default=False, description='Download CRTM coeffecient or "fix" files (several GBs).' ) - depends_on("cmake@3.15:") + + depends_on("cmake@3.15:", type="build") depends_on("git-lfs") depends_on("netcdf-fortran", when="@2.4.0:") depends_on("netcdf-fortran", when="@v2.3-jedi.4") depends_on("netcdf-fortran", when="@v2.4-jedi.1") depends_on("netcdf-fortran", when="@v2.4-jedi.2") + depends_on("netcdf-fortran", when="@v2.4.1-jedi") + depends_on("netcdf-fortran", when="@v3") depends_on("crtm-fix@2.3.0_emc", when="@2.3.0 +fix") - depends_on("crtm-fix@2.4.0_emc", when="@2.4.0 +fix") + depends_on("crtm-fix@2.4.0_emc", when="@=2.4.0 +fix") + depends_on("crtm-fix@2.4.0.1_emc", when="@2.4.0.1 +fix") depends_on("ecbuild", type=("build"), when="@v2.3-jedi.4") depends_on("ecbuild", type=("build"), when="@v2.4-jedi.1") depends_on("ecbuild", type=("build"), when="@v2.4-jedi.2") - - # ecbuild release v2.4.0 is broken - # add ecbuild dependency for next release with fix - # depends_on("ecbuild", when="@2.4.0:", type=("build")) + depends_on("ecbuild", type=("build"), when="@v2.4.1-jedi") + depends_on("ecbuild", type=("build"), when="@v3.0") + depends_on("ecbuild", type=("build"), when="@v3.1.0-skylabv7") license("CC0-1.0") + version( + "v3.1.0-skylabv8", + sha256="a475c8a444072aef1e8c2babba3d12f13ab0fb6c7ecab88edad57130839e29ff", + ) + version( + "v3.1.0-skylabv7", + sha256="3ac45c49562ab41c3baf443ce382e3a6bcb7226831b54146d9f73995be165ec7", + ) + version( + "v3.0.0-skylabv6", + sha256="780fbc4e0f3b0414fbade4b595832bb35d9c5d3e7c3b25ad128ca94f71bea2b8", + ) + version( + "v3.0.0-skylabv5", + sha256="4fa5dd2d65b4d4ff77d50992e8e0c02a59584b35599f424085fccdc2174d7bd2", + ) + version( + "v2.4.1-jedi", sha256="fd8bf4db4f2a3b420b4186de84483ba2a36660519dffcb1e0ff14bfe8c6f6a14" + ) + version("v2.4-jedi.2", commit="62831cbb6c1ffcbb219eeec60e1b1c422526f597") + version("v2.4-jedi.1", commit="82223419fdb479d76c2f2109c2b704e1d9618f22") + version("2.4.0.1", tag="v2.4.0_emc.3", commit="7ecad4866c400d7d0db1413348ee225cfa99ff36") # REL-2.4.0_emc (v2.4.0 ecbuild does not work) version("2.4.0", commit="5ddd0d6b0138284764065feda73b5adf599082a2") # Uses the tip of REL-2.3.0_emc branch version("2.3.0", commit="99760e693ce3b90a3b3b0e97d80972b4dfb61196") - # JEDI applications so far use these versions - # Branch release/crtm_jedi - version("v2.3-jedi.4", commit="bfede42adc6149213f28f58bf4e02fa8f7cb0198") - # Branch release/crtm_jedi_v2.4.0 - version("v2.4-jedi.1", commit="82223419fdb479d76c2f2109c2b704e1d9618f22") - version("v2.4-jedi.2", commit="62831cbb6c1ffcbb219eeec60e1b1c422526f597") + + depends_on("fortran", type="build") # generated + + def url_for_version(self, version): + if self.spec.satisfies("@v3") or version >= Version("3.0.0"): + return f"https://github.com/JCSDA/crtmv3/archive/refs/tags/{version}.tar.gz" + else: + return f"https://github.com/JCSDA/crtm/archive/refs/tags/{version}.tar.gz" + + # https://github.com/JCSDA/spack-stack/issues/1088 + patch("v3.1.0-skylabv8.installprefix.patch", when="@v3.1.0-skylabv8") + + @when("@2.4.0.1") + def patch(self): + if self.compiler.name in ["gcc", "clang", "apple-clang"]: + # Line lengths in RSS_Emissivity_Model.f90 are too long for gfortran default limit + filter_file( + "-fbacktrace", "-fbacktrace -ffree-line-length-none", "libsrc/CMakeLists.txt" + ) diff --git a/var/spack/repos/builtin/packages/crtm/v3.1.0-skylabv8.installprefix.patch b/var/spack/repos/builtin/packages/crtm/v3.1.0-skylabv8.installprefix.patch new file mode 100644 index 00000000000000..a1116de6d45923 --- /dev/null +++ b/var/spack/repos/builtin/packages/crtm/v3.1.0-skylabv8.installprefix.patch @@ -0,0 +1,14 @@ +--- a/CMakeLists.txt 2024-04-22 08:25:42.000000000 -0600 ++++ b/CMakeLists.txt 2024-04-22 08:25:54.000000000 -0600 +@@ -6,8 +6,9 @@ + + list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake) + set(CMAKE_DIRECTORY_LABELS ${PROJECT_NAME}) +-set(CMAKE_INSTALL_PREFIX ${CMAKE_CURRENT_BINARY_DIR} CACHE PATH "default install path" FORCE) +-message("CMAKE_INSTALL_PREFIX set to ${CMAKE_INSTALL_PREFIX}") ++# https://github.com/JCSDA/spack-stack/issues/1088 ++#set(CMAKE_INSTALL_PREFIX ${CMAKE_CURRENT_BINARY_DIR} CACHE PATH "default install path" FORCE) ++#message("CMAKE_INSTALL_PREFIX set to ${CMAKE_INSTALL_PREFIX}") + + ## Configuration options + include(${PROJECT_NAME}_compiler_flags) diff --git a/var/spack/repos/builtin/packages/crunch/package.py b/var/spack/repos/builtin/packages/crunch/package.py index 35c0195ef5a6bf..bc9406bdd75cad 100644 --- a/var/spack/repos/builtin/packages/crunch/package.py +++ b/var/spack/repos/builtin/packages/crunch/package.py @@ -21,6 +21,8 @@ class Crunch(CMakePackage): # No stable releases since 2012 version("master", branch="build_fixes") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.5:", type="build") conflicts("platform=darwin") diff --git a/var/spack/repos/builtin/packages/cryptopp/package.py b/var/spack/repos/builtin/packages/cryptopp/package.py index b0654740381ec4..8be5b473753f9f 100644 --- a/var/spack/repos/builtin/packages/cryptopp/package.py +++ b/var/spack/repos/builtin/packages/cryptopp/package.py @@ -18,6 +18,7 @@ class Cryptopp(MakefilePackage): license("BSL-1.0") + version("8.9.0", sha256="4cc0ccc324625b80b695fcd3dee63a66f1a460d3e51b71640cdbfc4cd1a3779c") version("8.7.0", sha256="d0d3a28fcb5a1f6ed66b3adf57ecfaed234a7e194e42be465c2ba70c744538dd") version("7.0.0", sha256="a4bc939910edd3d29fb819a6fc0dfdc293f686fa62326f61c56d72d0a366ceb0") version("6.1.0", sha256="21289d2511101a9350c87c8eb1f4982d4a266e8037b19dab79a32cc13ea108c7") @@ -39,7 +40,7 @@ def url_for_version(self, version): def build(self, spec, prefix): cxx_flags = [] - if "+shared" in spec: + if spec.satisfies("+shared"): cxx_flags.append(self.compiler.cxx_pic_flag) target = self.spec.target @@ -51,7 +52,7 @@ def build(self, spec, prefix): cxx_flags.append("-DCRYPTOPP_DISABLE_SSE2") make_target = "dynamic" if "+shared" in spec else "static" - make(make_target, "CXXFLAGS={0}".format(" ".join(cxx_flags))) + make(make_target, f"CXXFLAGS={' '.join(cxx_flags)}") def install(self, spec, prefix): - make("install", "PREFIX={0}".format(prefix)) + make("install", f"PREFIX={prefix}") diff --git a/var/spack/repos/builtin/packages/cryptsetup/package.py b/var/spack/repos/builtin/packages/cryptsetup/package.py index 223726dc1ebfff..7c6a7bc814b809 100644 --- a/var/spack/repos/builtin/packages/cryptsetup/package.py +++ b/var/spack/repos/builtin/packages/cryptsetup/package.py @@ -23,6 +23,8 @@ class Cryptsetup(AutotoolsPackage): version("2.2.2", sha256="2af0ec9551ab9c870074cae9d3f68d82cab004f4095fa89db0e4413713424a46") version("2.2.1", sha256="94e79a31ed38bdb0acd9af7ccca1605a2ac62ca850ed640202876b1ee11c1c61") + depends_on("c", type="build") # generated + depends_on("uuid", type=("build", "link")) depends_on("lvm2", type=("build", "link")) depends_on("popt", type=("build", "link")) diff --git a/var/spack/repos/builtin/packages/csa-c/package.py b/var/spack/repos/builtin/packages/csa-c/package.py index ec189e26f9c011..f5fd07a95979fa 100644 --- a/var/spack/repos/builtin/packages/csa-c/package.py +++ b/var/spack/repos/builtin/packages/csa-c/package.py @@ -16,4 +16,6 @@ class CsaC(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + configure_directory = "csa" diff --git a/var/spack/repos/builtin/packages/cscope/package.py b/var/spack/repos/builtin/packages/cscope/package.py index 6b6ebfd0f5dee0..0c43bf4fc37f95 100644 --- a/var/spack/repos/builtin/packages/cscope/package.py +++ b/var/spack/repos/builtin/packages/cscope/package.py @@ -17,6 +17,8 @@ class Cscope(AutotoolsPackage): version("15.9", sha256="c5505ae075a871a9cd8d9801859b0ff1c09782075df281c72c23e72115d9f159") version("15.8b", sha256="4889d091f05aa0845384b1e4965aa31d2b20911fb2c001b2cdcffbcb7212d3af") + depends_on("c", type="build") # generated + depends_on("ncurses") depends_on("flex", type="build") diff --git a/var/spack/repos/builtin/packages/csdp/package.py b/var/spack/repos/builtin/packages/csdp/package.py index 22333049dd5b5c..128f6977c14082 100644 --- a/var/spack/repos/builtin/packages/csdp/package.py +++ b/var/spack/repos/builtin/packages/csdp/package.py @@ -18,6 +18,8 @@ class Csdp(MakefilePackage): version("6.1.1", sha256="0558a46ac534e846bf866b76a9a44e8a854d84558efa50988ffc092f99a138b9") + depends_on("c", type="build") # generated + depends_on("atlas") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/ctffind/package.py b/var/spack/repos/builtin/packages/ctffind/package.py index 0cf000dfa22418..03199ede884968 100644 --- a/var/spack/repos/builtin/packages/ctffind/package.py +++ b/var/spack/repos/builtin/packages/ctffind/package.py @@ -25,6 +25,8 @@ class Ctffind(AutotoolsPackage): extension="tar.gz", ) + depends_on("cxx", type="build") # generated + def url_for_version(self, version): url = "https://grigoriefflab.umassmed.edu/system/tdf?path=ctffind-{0}.tar.gz&file=1&type=node&id=26" return url.format(version) diff --git a/var/spack/repos/builtin/packages/ctpl/package.py b/var/spack/repos/builtin/packages/ctpl/package.py index 0971f1decbda21..d44984013b80d6 100644 --- a/var/spack/repos/builtin/packages/ctpl/package.py +++ b/var/spack/repos/builtin/packages/ctpl/package.py @@ -17,6 +17,8 @@ class Ctpl(AutotoolsPackage): version("0.3", sha256="034875ba8e1ce87b7ee85bc7146a6a2b2a6ac0518482b36d65eb67dd09c03d0a") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/ctre/package.py b/var/spack/repos/builtin/packages/ctre/package.py index 81c8feab684c26..7c1760fdd8ded3 100644 --- a/var/spack/repos/builtin/packages/ctre/package.py +++ b/var/spack/repos/builtin/packages/ctre/package.py @@ -26,3 +26,5 @@ class Ctre(CMakePackage): version("2.6.3", sha256="bdf668b02f0b986dfc0fbc6066f446e2d0a9faa3347f00f53b19131297c84c4a") version("2.6.2", sha256="e82c87aeb0fc3f21ae8a2d3ffce2b1ef970fbea9c3e846ef1a6e5f81790f2946") version("2.6.1", sha256="58c623d9ea1cb7890aaa63c1a87f1a60a8acf31dbd4061ab672bea287ed689ac") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/cuba/package.py b/var/spack/repos/builtin/packages/cuba/package.py index b70f294614b7db..04a03e30870d25 100644 --- a/var/spack/repos/builtin/packages/cuba/package.py +++ b/var/spack/repos/builtin/packages/cuba/package.py @@ -20,4 +20,8 @@ class Cuba(AutotoolsPackage): version("4.2.2", sha256="8d9f532fd2b9561da2272c156ef7be5f3960953e4519c638759f1b52fe03ed52") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + parallel = False diff --git a/var/spack/repos/builtin/packages/cube-blade/package.py b/var/spack/repos/builtin/packages/cube-blade/package.py index 7e1c8ae00caee0..910148019a78a9 100644 --- a/var/spack/repos/builtin/packages/cube-blade/package.py +++ b/var/spack/repos/builtin/packages/cube-blade/package.py @@ -16,6 +16,8 @@ class CubeBlade(AutotoolsPackage): version("0.2", sha256="ab3c5bbca79e2ec599166e75b3c96a8f6a18b3064414fc39e56f78aaae9c165c") + depends_on("cxx", type="build") # generated + depends_on("cube@4.5:") depends_on("cubelib@4.5:") depends_on("qt@5.9.1:") diff --git a/var/spack/repos/builtin/packages/cube/package.py b/var/spack/repos/builtin/packages/cube/package.py index be571342821ed1..6b1f619db3232c 100644 --- a/var/spack/repos/builtin/packages/cube/package.py +++ b/var/spack/repos/builtin/packages/cube/package.py @@ -34,6 +34,9 @@ class Cube(AutotoolsPackage): version("4.3.3", sha256="ce8e1bff5a208fe5700a0194170be85bbd8f554e1aa1514b4afc5129326c7f83") version("4.2.3", sha256="b30c6998bcc54f795bcd6de3cfbef9c3cec094f782820174b533f628b0e60765") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("gui", default=True, description="Build Cube GUI") patch("qt-version.patch", when="@4.3.0:4.3 +gui") diff --git a/var/spack/repos/builtin/packages/cubelib/package.py b/var/spack/repos/builtin/packages/cubelib/package.py index c3c4734153fa53..059f03c5320d36 100644 --- a/var/spack/repos/builtin/packages/cubelib/package.py +++ b/var/spack/repos/builtin/packages/cubelib/package.py @@ -46,6 +46,9 @@ class Cubelib(AutotoolsPackage): deprecated="true", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/cubew/package.py b/var/spack/repos/builtin/packages/cubew/package.py index a358aacd6ffd2b..0fe52ca9752ff5 100644 --- a/var/spack/repos/builtin/packages/cubew/package.py +++ b/var/spack/repos/builtin/packages/cubew/package.py @@ -46,6 +46,9 @@ class Cubew(AutotoolsPackage): deprecated="true", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/cubist/package.py b/var/spack/repos/builtin/packages/cubist/package.py index bd6fbc94bbf4ec..cbc74c64360448 100644 --- a/var/spack/repos/builtin/packages/cubist/package.py +++ b/var/spack/repos/builtin/packages/cubist/package.py @@ -23,6 +23,8 @@ class Cubist(MakefilePackage): version("2.07", sha256="f2b20807cd3275e775c42263a4efd3f50df6e495a8b6dc8989ea2d41b973ac1a") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): makefile = FileFilter("Makefile") makefile.filter("SHELL .*", "SHELL = /bin/bash") diff --git a/var/spack/repos/builtin/packages/cuda-memtest/package.py b/var/spack/repos/builtin/packages/cuda-memtest/package.py index 90e218b126b5b0..5bc671c6610a89 100644 --- a/var/spack/repos/builtin/packages/cuda-memtest/package.py +++ b/var/spack/repos/builtin/packages/cuda-memtest/package.py @@ -24,6 +24,8 @@ class CudaMemtest(CMakePackage): version("master", branch="dev") + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.5:", type="build") # depends_on('nvml', when='+nvml') depends_on("cuda@5.0:") diff --git a/var/spack/repos/builtin/packages/cuda/package.py b/var/spack/repos/builtin/packages/cuda/package.py index fbb99d47ad306a..dce84006cf45d1 100644 --- a/var/spack/repos/builtin/packages/cuda/package.py +++ b/var/spack/repos/builtin/packages/cuda/package.py @@ -25,6 +25,82 @@ preferred_ver = "11.8.0" _versions = { + "12.5.1": { + "Linux-aarch64": ( + "353e8abc52ca80adf05002b775c7b3a2d2feefcf1c25ae13f8757f9a11efba3e", + "https://developer.download.nvidia.com/compute/cuda/12.5.1/local_installers/cuda_12.5.1_555.42.06_linux_sbsa.run", + ), + "Linux-x86_64": ( + "b5e0a779e089c86610051141c4cf498beef431858ec63398107391727ecbdb04", + "https://developer.download.nvidia.com/compute/cuda/12.5.1/local_installers/cuda_12.5.1_555.42.06_linux.run", + ), + }, + "12.5.0": { + "Linux-aarch64": ( + "e7b864c9ae27cef77cafc78614ec33cbb0a27606af9375deffa09c4269a07f04", + "https://developer.download.nvidia.com/compute/cuda/12.5.0/local_installers/cuda_12.5.0_555.42.02_linux_sbsa.run", + ), + "Linux-x86_64": ( + "90fcc7df48226434065ff12a4372136b40b9a4cbf0c8602bb763b745f22b7a99", + "https://developer.download.nvidia.com/compute/cuda/12.5.0/local_installers/cuda_12.5.0_555.42.02_linux.run", + ), + }, + "12.4.1": { + "Linux-aarch64": ( + "b0fbc77effa225498974625b6b08b3f6eff4a37e379f5b60f1d3827b215ad19b", + "https://developer.download.nvidia.com/compute/cuda/12.4.1/local_installers/cuda_12.4.1_550.54.15_linux_sbsa.run", + ), + "Linux-x86_64": ( + "367d2299b3a4588ab487a6d27276ca5d9ead6e394904f18bccb9e12433b9c4fb", + "https://developer.download.nvidia.com/compute/cuda/12.4.1/local_installers/cuda_12.4.1_550.54.15_linux.run", + ), + "Linux-ppc64le": ( + "677f44da10dd81396cb53a32c4e26eccdc24912063cb2e3beb3bbcb1658ef451", + "https://developer.download.nvidia.com/compute/cuda/12.4.1/local_installers/cuda_12.4.1_550.54.15_linux_ppc64le.run", + ), + }, + "12.4.0": { + "Linux-aarch64": ( + "b12bfe6c36d32ecf009a6efb0024325c5fc389fca1143f5f377ae2555936e803", + "https://developer.download.nvidia.com/compute/cuda/12.4.0/local_installers/cuda_12.4.0_550.54.14_linux_sbsa.run", + ), + "Linux-x86_64": ( + "e6a842f4eca9490575cdb68b6b1bb78d47b95a897de48dee292c431892e57d17", + "https://developer.download.nvidia.com/compute/cuda/12.4.0/local_installers/cuda_12.4.0_550.54.14_linux.run", + ), + "Linux-ppc64le": ( + "ef9a712daccf2805b4422f2301ff0eaa5c3ad41ef5d64b8626773bce7d1f41fe", + "https://developer.download.nvidia.com/compute/cuda/12.4.0/local_installers/cuda_12.4.0_550.54.14_linux_ppc64le.run", + ), + }, + "12.3.2": { + "Linux-aarch64": ( + "761b84e292b94c4d330f445d36326dfff90a418e909fb0baf3d6f03e24106d08", + "https://developer.download.nvidia.com/compute/cuda/12.3.2/local_installers/cuda_12.3.2_545.23.08_linux_sbsa.run", + ), + "Linux-x86_64": ( + "24b2afc9f770d8cf43d6fa7adc2ebfd47c4084db01bdda1ce3ce0a4d493ba65b", + "https://developer.download.nvidia.com/compute/cuda/12.3.2/local_installers/cuda_12.3.2_545.23.08_linux.run", + ), + "Linux-ppc64le": ( + "b876936fc80de10653523eadd846065db346b38ba6296f2d365772259cb2f198", + "https://developer.download.nvidia.com/compute/cuda/12.3.2/local_installers/cuda_12.3.2_545.23.08_linux_ppc64le.run", + ), + }, + "12.3.1": { + "Linux-aarch64": ( + "bce6bb8b293c33c3ed0c1b65120c70587cc29e1b94ea8679ebb14c32b3858b5e", + "https://developer.download.nvidia.com/compute/cuda/12.3.1/local_installers/cuda_12.3.1_545.23.08_linux_sbsa.run", + ), + "Linux-x86_64": ( + "b73d18ccd5ff85bbae32b425dfb82729612ede65b07a37cd5e2b574190614038", + "https://developer.download.nvidia.com/compute/cuda/12.3.1/local_installers/cuda_12.3.1_545.23.08_linux.run", + ), + "Linux-ppc64le": ( + "9da7e6e2beadc933aab73de79a84e133ddf03226371d3d7af83502748a978568", + "https://developer.download.nvidia.com/compute/cuda/12.3.1/local_installers/cuda_12.3.1_545.23.08_linux_ppc64le.run", + ), + }, "12.3.0": { "Linux-aarch64": ( "9a8fb8acf46b88faf0d711bda3149e1706efbbae02fcb40ab72addfd0e9ce5df", @@ -39,6 +115,20 @@ "https://developer.download.nvidia.com/compute/cuda/12.3.0/local_installers/cuda_12.3.0_545.23.06_linux_ppc64le.run", ), }, + "12.2.2": { + "Linux-aarch64": ( + "4113a15e6b27a02638c72edeb5f89de4c9ea312febba12fc4cefff2edc882268", + "https://developer.download.nvidia.com/compute/cuda/12.2.2/local_installers/cuda_12.2.2_535.104.05_linux_sbsa.run", + ), + "Linux-x86_64": ( + "2b39aae3e7618d9f59a3c8fa1f1bc61f29c0b0e0df75fb05076badb352952ef2", + "https://developer.download.nvidia.com/compute/cuda/12.2.2/local_installers/cuda_12.2.2_535.104.05_linux.run", + ), + "Linux-ppc64le": ( + "18848278e7f2bd4b4481f5665633d7e3d46e9a562d175d5ff278218188b01342", + "https://developer.download.nvidia.com/compute/cuda/12.2.2/local_installers/cuda_12.2.2_535.104.05_linux_ppc64le.run", + ), + }, "12.2.1": { "Linux-aarch64": ( "a9ae6bd02684c7acfb229484368bf2691d592767ce1aed10ae9aed92c81b9f09", @@ -533,10 +623,10 @@ class Cuda(Package): homepage = "https://developer.nvidia.com/cuda-zone" - maintainers("ax3l", "Rombur") + maintainers("ax3l", "Rombur", "pauleonix") executables = ["^nvcc$"] - skip_version_audit = ["platform=darwin"] + skip_version_audit = ["platform=darwin", "platform=windows"] for ver, packages in _versions.items(): key = "{0}-{1}".format(platform.system(), platform.machine()) diff --git a/var/spack/repos/builtin/packages/cudd/package.py b/var/spack/repos/builtin/packages/cudd/package.py index 8c89391f65c054..c060514c476a5b 100644 --- a/var/spack/repos/builtin/packages/cudd/package.py +++ b/var/spack/repos/builtin/packages/cudd/package.py @@ -19,3 +19,6 @@ class Cudd(AutotoolsPackage): maintainers("davekeeshan") version("3.0.0", sha256="b8e966b4562c96a03e7fbea239729587d7b395d53cadcc39a7203b49cf7eeb69") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/cudnn/package.py b/var/spack/repos/builtin/packages/cudnn/package.py index b042529a6ed441..38dc8c88a3a0e0 100644 --- a/var/spack/repos/builtin/packages/cudnn/package.py +++ b/var/spack/repos/builtin/packages/cudnn/package.py @@ -9,6 +9,14 @@ from spack.package import * _versions = { + # cuDNN 9.2.0 + "9.2.0.82-12": { + "Linux-x86_64": "1362b4d437e37e92c9814c3b4065db5106c2e03268e22275a5869e968cee7aa8", + "Linux-aarch64": "24cc2a0308dfe412c02c7d41d4b07ec12dacb021ebf8c719de38eb77d22f68c1", + }, + "9.2.0.82-11": { + "Linux-x86_64": "99dcb3fa2bf7eed7f35b0f8e58e7d1f04d9a52e01e382efc1de16fed230d3b26" + }, # cuDNN 8.9.7 "8.9.7.29-12": { "Linux-x86_64": "475333625c7e42a7af3ca0b2f7506a106e30c93b1aa0081cd9c13efb6e21e3bb", @@ -298,7 +306,7 @@ class Cudnn(Package): # need to use modified URLs like in url_for_version. maintainers("adamjstewart", "bvanessen") - skip_version_audit = ["platform=darwin"] + skip_version_audit = ["platform=darwin", "platform=windows"] license("MIT") diff --git a/var/spack/repos/builtin/packages/cunit/package.py b/var/spack/repos/builtin/packages/cunit/package.py index c1e7eec160e791..ab75d9f13c5b58 100644 --- a/var/spack/repos/builtin/packages/cunit/package.py +++ b/var/spack/repos/builtin/packages/cunit/package.py @@ -16,6 +16,9 @@ class Cunit(AutotoolsPackage): version("2.1-3", sha256="f5b29137f845bb08b77ec60584fdb728b4e58f1023e6f249a464efa49a40f214") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/cupla/package.py b/var/spack/repos/builtin/packages/cupla/package.py index abfd480d5f7126..b9db779b010fb6 100644 --- a/var/spack/repos/builtin/packages/cupla/package.py +++ b/var/spack/repos/builtin/packages/cupla/package.py @@ -20,6 +20,8 @@ class Cupla(Package): version("master", branch="master") version("0.3.0", sha256="035512517167967697e73544c788453de5e3f0bc4e8d4864b41b2e287365cbaf") + depends_on("cxx", type="build") # generated + depends_on("alpaka@0.6.0:0.7") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/cups/package.py b/var/spack/repos/builtin/packages/cups/package.py index 6d4bf76626876e..22ce987f83992a 100644 --- a/var/spack/repos/builtin/packages/cups/package.py +++ b/var/spack/repos/builtin/packages/cups/package.py @@ -21,6 +21,9 @@ class Cups(AutotoolsPackage): version("2.3.3", sha256="261fd948bce8647b6d5cb2a1784f0c24cc52b5c4e827b71d726020bcc502f3ee") version("2.2.3", sha256="66701fe15838f2c892052c913bde1ba106bbee2e0a953c955a62ecacce76885f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gnutls") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/curl/package.py b/var/spack/repos/builtin/packages/curl/package.py index 37314813dc807a..fa8316e9286a9c 100644 --- a/var/spack/repos/builtin/packages/curl/package.py +++ b/var/spack/repos/builtin/packages/curl/package.py @@ -32,11 +32,11 @@ class Curl(NMakePackage, AutotoolsPackage): license("curl") + version("8.7.1", sha256="05bbd2b698e9cfbab477c33aa5e99b4975501835a41b7ca6ca71de03d8849e76") version("8.6.0", sha256="b4785f2d8877fa92c0e45d7155cf8cc6750dbda961f4b1a45bcbec990cf2fa9b") version("8.4.0", sha256="e5250581a9c032b1b6ed3cf2f9c114c811fc41881069e9892d115cc73f9e88c6") # Deprecated versions due to CVEs - # CVE-2023-38545 version( "8.1.2", sha256="b54974d32fd610acace92e3df1f643144015ac65847f0a041fdc17db6f43f243", @@ -47,204 +47,21 @@ class Curl(NMakePackage, AutotoolsPackage): sha256="9b6b1e96b748d04b968786b6bdf407aa5c75ab53a3d37c1c8c81cdb736555ccf", deprecated=True, ) + # needed by r@:4.2 version( "7.88.1", sha256="8224b45cce12abde039c12dc0711b7ea85b104b9ad534d6e4c5b4e188a61c907", deprecated=True, ) - # https://nvd.nist.gov/vuln/detail/CVE-2022-43551 - version( - "7.87.0", - sha256="5d6e128761b7110946d1276aff6f0f266f2b726f5e619f7e0a057a474155f307", - deprecated=True, - ) - # https://nvd.nist.gov/vuln/detail/CVE-2022-32221 - version( - "7.86.0", - sha256="f5ca69db03eea17fa8705bdfb1a9f58d76a46c9010518109bb38f313137e0a28", - deprecated=True, - ) - version( - "7.85.0", - sha256="21a7e83628ee96164ac2b36ff6bf99d467c7b0b621c1f7e317d8f0d96011539c", - deprecated=True, - ) - version( - "7.84.0", - sha256="702fb26e73190a3bd77071aa146f507b9817cc4dfce218d2ab87f00cd3bc059d", - deprecated=True, - ) - # https://nvd.nist.gov/vuln/detail/CVE-2022-32206 - version( - "7.83.0", - sha256="247c7ec7521c4258e65634e529270d214fe32969971cccb72845e7aa46831f96", - deprecated=True, - ) - version( - "7.82.0", - sha256="46d9a0400a33408fd992770b04a44a7434b3036f2e8089ac28b57573d59d371f", - deprecated=True, - ) - version( - "7.81.0", - sha256="1e7a38d7018ec060f1f16df839854f0889e94e122c4cfa5d3a37c2dc56f1e258", - deprecated=True, - ) - version( - "7.80.0", - sha256="dd0d150e49cd950aff35e16b628edf04927f0289df42883750cf952bb858189c", - deprecated=True, - ) - version( - "7.79.1", - sha256="de62c4ab9a9316393962e8b94777a570bb9f71feb580fb4475e412f2f9387851", - deprecated=True, - ) - version( - "7.79.0", - sha256="d607a677f473f79f96c964100327125a6204a39d835dc00dab7fc0129b959f42", - deprecated=True, - ) - version( - "7.78.0", - sha256="98530b317dc95ccb324bbe4f834f07bb642fbc393b794ddf3434f246a71ea44a", - deprecated=True, - ) - version( - "7.77.0", - sha256="6c0c28868cb82593859fc43b9c8fdb769314c855c05cf1b56b023acf855df8ea", - deprecated=True, - ) - version( - "7.76.1", - sha256="7a8e184d7d31312c4ebf6a8cb59cd757e61b2b2833a9ed4f9bf708066e7695e9", - deprecated=True, - ) - version( - "7.76.0", - sha256="e29bfe3633701590d75b0071bbb649ee5ca4ca73f00649268bd389639531c49a", - deprecated=True, - ) - version( - "7.75.0", - sha256="50552d4501c178e4cc68baaecc487f466a3d6d19bbf4e50a01869effb316d026", - deprecated=True, - ) - version( - "7.74.0", - sha256="0f4d63e6681636539dc88fa8e929f934cd3a840c46e0bf28c73be11e521b77a5", - deprecated=True, - ) - version( - "7.73.0", - sha256="cf34fe0b07b800f1c01a499a6e8b2af548f6d0e044dca4a29d88a4bee146d131", - deprecated=True, - ) - version( - "7.72.0", - sha256="ad91970864102a59765e20ce16216efc9d6ad381471f7accceceab7d905703ef", - deprecated=True, - ) - version( - "7.71.0", - sha256="600f00ac2481a89548a4141ddf983fd9386165e1960bac91d0a1c81dca5dd341", - deprecated=True, - ) - version( - "7.68.0", - sha256="207f54917dd6a2dc733065ccf18d61bb5bebeaceb5df49cd9445483e8623eeb9", - deprecated=True, - ) - version( - "7.64.0", - sha256="d573ba1c2d1cf9d8533fadcce480d778417964e8d04ccddcc76e591d544cf2eb", - deprecated=True, - ) + # needed by old r-curl version( "7.63.0", sha256="9bab7ed4ecff77020a312d84cc5fb7eb02d58419d218f267477a724a17fd8dd8", deprecated=True, ) - version( - "7.60.0", - sha256="897dfb2204bd99be328279f88f55b7c61592216b0542fcbe995c60aa92871e9b", - deprecated=True, - ) - version( - "7.59.0", - sha256="b5920ffd6a8c95585fb95070e0ced38322790cb335c39d0dab852d12e157b5a0", - deprecated=True, - ) - version( - "7.56.0", - sha256="de60a4725a3d461c70aa571d7d69c788f1816d9d1a8a2ef05f864ce8f01279df", - deprecated=True, - ) - version( - "7.54.0", - sha256="f50ebaf43c507fa7cc32be4b8108fa8bbd0f5022e90794388f3c7694a302ff06", - deprecated=True, - ) - version( - "7.53.1", - sha256="1c7207c06d75e9136a944a2e0528337ce76f15b9ec9ae4bb30d703b59bf530e8", - deprecated=True, - ) - version( - "7.52.1", - sha256="d16185a767cb2c1ba3d5b9096ec54e5ec198b213f45864a38b3bda4bbf87389b", - deprecated=True, - ) - version( - "7.50.3", - sha256="7b7347d976661d02c84a1f4d6daf40dee377efdc45b9e2c77dedb8acf140d8ec", - deprecated=True, - ) - version( - "7.50.2", - sha256="0c72105df4e9575d68bcf43aea1751056c1d29b1040df6194a49c5ac08f8e233", - deprecated=True, - ) - version( - "7.50.1", - sha256="3c12c5f54ccaa1d40abc65d672107dcc75d3e1fcb38c267484334280096e5156", - deprecated=True, - ) - version( - "7.49.1", - sha256="eb63cec4bef692eab9db459033f409533e6d10e20942f4b060b32819e81885f1", - deprecated=True, - ) - version( - "7.47.1", - sha256="ddc643ab9382e24bbe4747d43df189a0a6ce38fcb33df041b9cb0b3cd47ae98f", - deprecated=True, - ) - version( - "7.46.0", - sha256="b7d726cdd8ed4b6db0fa1b474a3c59ebbbe4dcd4c61ac5e7ade0e0270d3195ad", - deprecated=True, - ) - version( - "7.45.0", - sha256="65154e66b9f8a442b57c436904639507b4ac37ec13d6f8a48248f1b4012b98ea", - deprecated=True, - ) - version( - "7.44.0", - sha256="1e2541bae6582bb697c0fbae49e1d3e6fad5d05d5aa80dbd6f072e0a44341814", - deprecated=True, - ) - version( - "7.43.0", - sha256="baa654a1122530483ccc1c58cc112fec3724a82c11c6a389f1e6a37dc8858df9", - deprecated=True, - ) - version( - "7.42.1", - sha256="e2905973391ec2dfd7743a8034ad10eeb58dab8b3a297e7892a41a7999cac887", - deprecated=True, - ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated default_tls = "openssl" if sys.platform == "darwin": @@ -280,10 +97,6 @@ class Curl(NMakePackage, AutotoolsPackage): variant("librtmp", default=False, description="enable Rtmp support") variant("ldap", default=False, description="enable ldap support") variant("libidn2", default=False, description="enable libidn2 support") - for plat in ["darwin", "cray", "linux"]: - with when("platform=%s" % plat): - # curl queries pkgconfig for openssl compilation flags - depends_on("pkgconfig", type="build") variant( "libs", default="shared,static" if not is_windows else "shared", @@ -292,9 +105,12 @@ class Curl(NMakePackage, AutotoolsPackage): description="Build shared libs, static libs or both", ) - conflicts("platform=cray", when="tls=secure_transport", msg="Only supported on macOS") conflicts("platform=linux", when="tls=secure_transport", msg="Only supported on macOS") + depends_on("pkgconfig", type="build", when="platform=darwin") + depends_on("pkgconfig", type="build", when="platform=linux") + depends_on("pkgconfig", type="build", when="platform=freebsd") + depends_on("gnutls", when="tls=gnutls") depends_on("mbedtls@2: +pic", when="@7.79: tls=mbedtls") depends_on("mbedtls@:2 +pic", when="@:7.78 tls=mbedtls") @@ -314,6 +130,10 @@ class Curl(NMakePackage, AutotoolsPackage): depends_on("krb5", when="+gssapi") depends_on("rtmpdump", when="+librtmp") + # https://github.com/curl/curl/issues/12832 + # https://github.com/curl/curl/issues/13508 + depends_on("perl", type="build", when="@8.6:8.7.1") + # https://github.com/curl/curl/pull/9054 patch("easy-lock-sched-header.patch", when="@7.84.0") diff --git a/var/spack/repos/builtin/packages/cusz/package.py b/var/spack/repos/builtin/packages/cusz/package.py index 666aec3f33df7c..c6a939d1868268 100644 --- a/var/spack/repos/builtin/packages/cusz/package.py +++ b/var/spack/repos/builtin/packages/cusz/package.py @@ -20,9 +20,13 @@ class Cusz(CMakePackage, CudaPackage): conflicts("cuda_arch=none", when="+cuda") version("develop", branch="develop") + version("0.6.0", commit="cafed521dc338fe2159ebb5b09a36fc318524bf7") version("0.3.1", commit="02be3cbd07db467decaf45ec9eb593ba6173c809") version("0.3", sha256="0feb4f7fd64879fe147624dd5ad164adf3983f79b2e0383d35724f8d185dcb11") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # these version of Cuda provide the CUB headers, but not CUB cmake configuration that we use. conflicts("^cuda@11.0.2:11.2.2") diff --git a/var/spack/repos/builtin/packages/cutensor/package.py b/var/spack/repos/builtin/packages/cutensor/package.py index d80a8df332be64..bebfb509fd6070 100644 --- a/var/spack/repos/builtin/packages/cutensor/package.py +++ b/var/spack/repos/builtin/packages/cutensor/package.py @@ -13,7 +13,11 @@ "Linux-x86_64": "4fdebe94f0ba3933a422cff3dd05a0ef7a18552ca274dd12564056993f55471d", "Linux-ppc64le": "ad736acc94e88673b04a3156d7d3a408937cac32d083acdfbd8435582cbe15db", "Linux-aarch64": "5b9ac479b1dadaf40464ff3076e45f2ec92581c07df1258a155b5bcd142f6090", - } + }, + "2.0.1.2": { + "Linux-x86_64": "ededa12ca622baad706ea0a500a358ea51146535466afabd96e558265dc586a2", + "Linux-ppc64le": "7176083a4dad44cb0176771be6efb3775748ad30a39292bf7b4584510f1dd811", + }, } @@ -27,7 +31,7 @@ class Cutensor(Package): maintainers("bvanessen") url = "cutensor" - skip_version_audit = ["platform=darwin"] + skip_version_audit = ["platform=darwin", "platform=windows"] for ver, packages in _versions.items(): key = "{0}-{1}".format(platform.system(), platform.machine()) diff --git a/var/spack/repos/builtin/packages/cutlang/package.py b/var/spack/repos/builtin/packages/cutlang/package.py deleted file mode 100644 index 4a675143ad4af2..00000000000000 --- a/var/spack/repos/builtin/packages/cutlang/package.py +++ /dev/null @@ -1,40 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -# ---------------------------------------------------------------------------- - -from spack.package import * - - -class Cutlang(Package): - """CutLang is a domain specific language that aims to provide a clear, - human readable way to define analyses in high energy particle physics (HEP) - along with an interpretation framework of that language.""" - - homepage = "https://github.com/unelg/CutLang" - url = "https://github.com/unelg/CutLang/archive/refs/tags/v2.12.10.tar.gz" - maintainers("unelg", "ssekmen", "sabrivatansever") - - version( - "2.12.10", - sha256="999a2b9fdb4b7d241a6fc21c03d92deadf80ad4682f8ce677ee0fa3b24169bfd", - preferred=True, - ) - version("2.12.9", sha256="56bfb16f8ed683775fbadbca306cc09bbd65f58f42fa16d98f6d6868e8585b45") - version("2.12.8", sha256="d776198fca3c2dcb612cf3bd98f27c069187aa970b80594fdb6681e0643f5e91") - version("2.12.7", sha256="f20704abf0f4e04891eb0651f059782eb0f2652661c2c66c70c1bb6d58900380") - version("2.12.6", sha256="0fb787457466610d37d1a3f047b68e73ace81e708bd2db76eb84af5a1406377e") - version("2.12.5", sha256="eeb31be584551364569bdef8567b4910fd20be4c00bf7dcf07c8c8cbdaa2419c") - version("2.12.4", sha256="cc941c358772ada5f66bc768f71bf7841ba2c495dd2bdf132df72a509d5ccb8b") - version("2.12.3", sha256="a181fc739d13a7b187a94555b12f0b064e900b1cb69b880c69a9f2877bc5de4c") - version("2.12.2", sha256="c2dc8b841bddd58b4e41b104c72c31bb00c750f7fe07672a30c15746dea6734c") - version("2.12.1", sha256="7bd7d2e894fdc8465c89970d0011aeaaeae6ec02b4c45d6e2b9111b278ca18a9") - depends_on("root", type="build") - depends_on("flex", type="build") - depends_on("bison", type="build") - - def install(self, spec, prefix): - cmake("..", *std_cmake_args) - make() - make("install") diff --git a/var/spack/repos/builtin/packages/cutlass/package.py b/var/spack/repos/builtin/packages/cutlass/package.py index f7e67a6a582757..28f38b9517455e 100644 --- a/var/spack/repos/builtin/packages/cutlass/package.py +++ b/var/spack/repos/builtin/packages/cutlass/package.py @@ -44,6 +44,8 @@ class Cutlass(CMakePackage, CudaPackage): version("1.1.0", sha256="7ae0da2257efa7f4ad9c224bce0d10cb1a5580df6b7010d832cf0a11def4627d") version("1.0.1", sha256="2adec90497141893ca53ac945b88d5881610ed3347166b36be4f72449b5342a0") version("1.0.0", sha256="c7a16d349e11d85891cb91ece97d5bdbc4b140f614a0265732c2dc81a806bd98") + + depends_on("cxx", type="build") # generated variant("cuda", default=True, description="Build with CUDA") conflicts("~cuda", msg="Cutlass requires CUDA") conflicts( diff --git a/var/spack/repos/builtin/packages/cvector/package.py b/var/spack/repos/builtin/packages/cvector/package.py index 9a65d39edf257e..71bf37c1b8efcd 100644 --- a/var/spack/repos/builtin/packages/cvector/package.py +++ b/var/spack/repos/builtin/packages/cvector/package.py @@ -16,6 +16,8 @@ class Cvector(MakefilePackage): version("1.0.3", sha256="d3fa92de3cd5ba8697abdbb52080248b2c252a81cf40a8ec639be301518d0ce3") + depends_on("c", type="build") # generated + depends_on("libtool", type="build") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/cvise/package.py b/var/spack/repos/builtin/packages/cvise/package.py index 48def2cf00ae40..3b04c5d61f5c3f 100644 --- a/var/spack/repos/builtin/packages/cvise/package.py +++ b/var/spack/repos/builtin/packages/cvise/package.py @@ -17,12 +17,17 @@ class Cvise(CMakePackage): license("NCSA") version("master", branch="master") + version("2.10.0", tag="v2.10.0", commit="c8606497e354ddab273745cf823823bdd3e86bd8") version("2.7.0", tag="v2.7.0", commit="d9e4a50514d9931b2a1293755a7e96e0f9520032") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("pytest", default=False, description="Add py-pytest as dependency") variant("colordiff", default=False, description="Add colordiff support") - depends_on("cmake", type="build") + depends_on("cmake@2.8.12:", type="build") + depends_on("cmake@3.14:", when="@2.9:", type="build") depends_on("flex", type=("build", "run")) depends_on("llvm@9.0.0:", type=("build", "run")) depends_on("python@3.6:", type=("build", "run")) @@ -33,3 +38,8 @@ class Cvise(CMakePackage): depends_on("py-pytest", when="+pytest", type=("build", "run")) depends_on("colordiff", when="+colordiff", type=("build", "run")) + + # C-Vise doesn't directly depend on ncurses, but LLVM does. However, LLVM + # doesn't provide correctly export terminfo CMake targets that it depends on + # and C-Vise fails during configuration with ncurses +termlib. + depends_on("ncurses ~termlib", when="^llvm +lldb") diff --git a/var/spack/repos/builtin/packages/cvs/package.py b/var/spack/repos/builtin/packages/cvs/package.py index 867da627895f17..1e4da0d450548a 100644 --- a/var/spack/repos/builtin/packages/cvs/package.py +++ b/var/spack/repos/builtin/packages/cvs/package.py @@ -18,6 +18,9 @@ class Cvs(AutotoolsPackage, GNUMirrorPackage): version("1.12.13", sha256="78853613b9a6873a30e1cc2417f738c330e75f887afdaf7b3d0800cb19ca515e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # To avoid the problem: The use of %n in format strings in writable memory # may crash the program on glibc2 systems from 2004-10-18 or newer. patch( diff --git a/var/spack/repos/builtin/packages/cxxopts/package.py b/var/spack/repos/builtin/packages/cxxopts/package.py index be93b9631f1152..2f9bb7ba0de7c5 100644 --- a/var/spack/repos/builtin/packages/cxxopts/package.py +++ b/var/spack/repos/builtin/packages/cxxopts/package.py @@ -15,6 +15,7 @@ class Cxxopts(CMakePackage): license("MIT") + version("3.2.0", sha256="9f43fa972532e5df6c5fd5ad0f5bac606cdec541ccaf1732463d8070bbb7f03b") version("3.1.1", sha256="523175f792eb0ff04f9e653c90746c12655f10cb70f1d5e6d6d9491420298a08") version("3.0.0", sha256="36f41fa2a46b3c1466613b63f3fa73dc24d912bc90d667147f1e43215a8c6d00") version("2.2.1", sha256="984aa3c8917d649b14d7f6277104ce38dd142ce378a9198ec926f03302399681") @@ -29,6 +30,8 @@ class Cxxopts(CMakePackage): version("1.4.1", sha256="c5ccfe99bd3db0604d077c968b39a42d61333a64d171fe84d7037d6c0dcc996d") version("1.4.0", sha256="60d4a482ec603ef4efa2603978596716884b33e24d39af6ddca52b4a30f7107b") + depends_on("cxx", type="build") # generated + variant("unicode", default=False, description="Enables unicode support using the ICU library.") depends_on("cmake@3.1.0:", type="build") diff --git a/var/spack/repos/builtin/packages/cxxtest/package.py b/var/spack/repos/builtin/packages/cxxtest/package.py index 162d85432656df..386894276a6a6c 100644 --- a/var/spack/repos/builtin/packages/cxxtest/package.py +++ b/var/spack/repos/builtin/packages/cxxtest/package.py @@ -16,5 +16,8 @@ class Cxxtest(Package): version("4.4", sha256="1c154fef91c65dbf1cd4519af7ade70a61d85a923b6e0c0b007dc7f4895cf7d8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): install_tree(self.stage.source_path, prefix) diff --git a/var/spack/repos/builtin/packages/cyrus-sasl/package.py b/var/spack/repos/builtin/packages/cyrus-sasl/package.py index a464055d49aa68..f4f92d0a6dc73e 100644 --- a/var/spack/repos/builtin/packages/cyrus-sasl/package.py +++ b/var/spack/repos/builtin/packages/cyrus-sasl/package.py @@ -23,6 +23,8 @@ class CyrusSasl(AutotoolsPackage): version("2.1.24", sha256="1df15c492f7ecb90be49531a347b3df21b041c2e0325dcc4fc5a6e98384c40dd") version("2.1.23", sha256="b1ec43f62d68446a6a5879925c63d94e26089c5a46cd83e061dd685d014c7d1f") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/czmq/package.py b/var/spack/repos/builtin/packages/czmq/package.py index 13c79ac8e0b6f7..9f8805bed9e8f4 100644 --- a/var/spack/repos/builtin/packages/czmq/package.py +++ b/var/spack/repos/builtin/packages/czmq/package.py @@ -19,6 +19,9 @@ class Czmq(AutotoolsPackage): version("4.0.2", sha256="794f80af7392ec8d361ad69646fc20aaa284d23fef92951334009771a732c810") version("3.0.2", sha256="e56f8498daf70310b31c42669b2f9b753c5e747eafaff6d4fdac26d72a474b27") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libtool", type="build") depends_on("automake", type="build") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/daemonize/package.py b/var/spack/repos/builtin/packages/daemonize/package.py index 05aefdc1e6b394..bee632b9f824c1 100644 --- a/var/spack/repos/builtin/packages/daemonize/package.py +++ b/var/spack/repos/builtin/packages/daemonize/package.py @@ -18,6 +18,8 @@ class Daemonize(Package): version("master", branch="master") version("1.7.8", sha256="20c4fc9925371d1ddf1b57947f8fb93e2036eb9ccc3b43a1e3678ea8471c4c60") + depends_on("c", type="build") # generated + def install(self, spec, prefix): configure("--prefix={0}".format(prefix)) make() diff --git a/var/spack/repos/builtin/packages/dakota/package.py b/var/spack/repos/builtin/packages/dakota/package.py index a4666412681109..860ca0f528d915 100644 --- a/var/spack/repos/builtin/packages/dakota/package.py +++ b/var/spack/repos/builtin/packages/dakota/package.py @@ -58,6 +58,10 @@ class Dakota(CMakePackage): version("6.9", sha256="989b689278964b96496e3058b8ef5c2724d74bcd232f898fe450c51eba7fe0c2") version("6.3", sha256="0fbc310105860d77bb5c96de0e8813d75441fca1a5e6dfaf732aa095c4488d52") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") variant("mpi", default=True, description="Activates MPI support") variant("python", default=True, description="Add Python dependency for dakota.interfacing API") diff --git a/var/spack/repos/builtin/packages/daligner/package.py b/var/spack/repos/builtin/packages/daligner/package.py index d7763a0a0c013e..1f4ff5ddbdb5fb 100644 --- a/var/spack/repos/builtin/packages/daligner/package.py +++ b/var/spack/repos/builtin/packages/daligner/package.py @@ -14,6 +14,8 @@ class Daligner(MakefilePackage): version("1.0", sha256="2fb03616f0d60df767fbba7c8f0021ec940c8d822ab2011cf58bd56a8b9fb414") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): makefile = FileFilter("Makefile") kwargs = {"ignore_absent": False, "backup": False, "string": True} diff --git a/var/spack/repos/builtin/packages/dalton/package.py b/var/spack/repos/builtin/packages/dalton/package.py index a911d5e18c286f..5b658f865b589c 100644 --- a/var/spack/repos/builtin/packages/dalton/package.py +++ b/var/spack/repos/builtin/packages/dalton/package.py @@ -27,6 +27,10 @@ class Dalton(CMakePackage): "2018.2", tag="2018.2", commit="4aa945ecd235fbf67ed0c1609617c553ef40be89", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "build_type", default="Release", diff --git a/var/spack/repos/builtin/packages/damaris/package.py b/var/spack/repos/builtin/packages/damaris/package.py index f85d1df76c75f8..3d1221dd50215a 100644 --- a/var/spack/repos/builtin/packages/damaris/package.py +++ b/var/spack/repos/builtin/packages/damaris/package.py @@ -18,6 +18,8 @@ class Damaris(CMakePackage): license("LGPL-3.0-or-later") version("master", branch="master") + version("1.11.0", tag="v1.11.0", commit="1aee2a8971584712d81323d77f9805448fe54947") + version("1.10.0", tag="v1.10.0", commit="4e6b2641be1f7ded379312a8e7f4644ebe009ec9") version("1.9.2", tag="v1.9.2", commit="22c146b4b4ca047d4d36fd904d248e0280b3c0ea") version("1.9.1", tag="v1.9.1", commit="2fe83f587837b7ad0b5c187b8ff453f7d3ad2c18") version("1.9.0", tag="v1.9.0", commit="23cac3a8ade9f9c20499081a8ed10b3e51801428") @@ -42,6 +44,10 @@ class Damaris(CMakePackage): "1.3.1", tag="v1.3.1", commit="6cee3690fa7d387acc8f5f650a7b019e13b90284", deprecated=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=True, description="Enables Fortran support") variant("hdf5", default=False, description="Enables the HDF5 storage plugin") variant("static", default=False, description="Builds a static version of the library") diff --git a/var/spack/repos/builtin/packages/damask-grid/package.py b/var/spack/repos/builtin/packages/damask-grid/package.py index 1335c01215741e..db73d936b1cb0e 100644 --- a/var/spack/repos/builtin/packages/damask-grid/package.py +++ b/var/spack/repos/builtin/packages/damask-grid/package.py @@ -36,6 +36,9 @@ class DamaskGrid(CMakePackage): "3.0.0-alpha4", sha256="0bb8bde43b27d852b1fb6e359a7157354544557ad83d87987b03f5d629ce5493" ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("petsc@3.20.3:3.21", when="@3.0.0-beta") depends_on("petsc@3.20.2:3.21", when="@3.0.0-alpha8") depends_on("petsc@3.17.1:3.18", when="@3.0.0-alpha7") diff --git a/var/spack/repos/builtin/packages/damask-mesh/package.py b/var/spack/repos/builtin/packages/damask-mesh/package.py index f39f30de148326..b30ed5a0533439 100644 --- a/var/spack/repos/builtin/packages/damask-mesh/package.py +++ b/var/spack/repos/builtin/packages/damask-mesh/package.py @@ -36,6 +36,9 @@ class DamaskMesh(CMakePackage): "3.0.0-alpha4", sha256="0bb8bde43b27d852b1fb6e359a7157354544557ad83d87987b03f5d629ce5493" ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("petsc@3.20.3:3.21", when="@3.0.0-beta") depends_on("petsc@3.20.2:3.21", when="@3.0.0-alpha8") depends_on("petsc@3.17.1:3.18", when="@3.0.0-alpha7") diff --git a/var/spack/repos/builtin/packages/damselfly/package.py b/var/spack/repos/builtin/packages/damselfly/package.py index 74b8a078ad95e0..bccbeda6c83a79 100644 --- a/var/spack/repos/builtin/packages/damselfly/package.py +++ b/var/spack/repos/builtin/packages/damselfly/package.py @@ -14,5 +14,8 @@ class Damselfly(CMakePackage): version("1.0", sha256="560e1b800c9036766396a1033c00914bd8d181b911e87140c3ac8879baf6545a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@2.6:", type="build") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/daos/package.py b/var/spack/repos/builtin/packages/daos/package.py index 87bbfe86622247..ca9ce746fd2ccd 100644 --- a/var/spack/repos/builtin/packages/daos/package.py +++ b/var/spack/repos/builtin/packages/daos/package.py @@ -21,6 +21,9 @@ class Daos(SConsPackage): version( "2.2.0", tag="v2.2.0", commit="d2a1f2790c946659c9398926254e6203fd957b7c", submodules=True ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated variant( "debug", default=False, description="Enable debugging info and strict compile warnings" ) @@ -36,7 +39,7 @@ class Daos(SConsPackage): depends_on("isa-l-crypto@2.23.0:") depends_on("libfabric@1.15.1:") depends_on("libfuse@3.6.1:") - depends_on("libuuid") + depends_on("uuid") depends_on("libunwind") depends_on("libyaml") depends_on("mercury@2.2.0:+boostsys") diff --git a/var/spack/repos/builtin/packages/darshan-runtime/package.py b/var/spack/repos/builtin/packages/darshan-runtime/package.py index 5fee8c6801009b..54d65cf7474481 100644 --- a/var/spack/repos/builtin/packages/darshan-runtime/package.py +++ b/var/spack/repos/builtin/packages/darshan-runtime/package.py @@ -16,7 +16,7 @@ class DarshanRuntime(AutotoolsPackage): systems where you intend to instrument MPI applications.""" homepage = "https://www.mcs.anl.gov/research/projects/darshan/" - url = "https://ftp.mcs.anl.gov/pub/darshan/releases/darshan-3.1.0.tar.gz" + url = "https://web.cels.anl.gov/projects/darshan/releases/darshan-3.4.0.tar.gz" git = "https://github.com/darshan-hpc/darshan.git" maintainers("shanedsnyder", "carns") @@ -25,6 +25,7 @@ class DarshanRuntime(AutotoolsPackage): test_requires_compiler = True version("main", branch="main", submodules=True) + version("3.4.5", sha256="1c017ac635fab5ee0e87a6b52c5c7273962813569495cb1dd3b7cfa6e19f6ed0") version("3.4.4", sha256="d9c9df5aca94dc5ca3d56fd763bec2f74771d35126d61cb897373d2166ccd867") version("3.4.3", sha256="dca5f9f9b0ead55a8724b218071ecbb5c4f2ef6027eaade3a6477256930ccc2c") version("3.4.2", sha256="b095c3b7c059a8eba4beb03ec092b60708780a3cae3fc830424f6f9ada811c6b") @@ -49,6 +50,10 @@ class DarshanRuntime(AutotoolsPackage): version("3.1.0", sha256="b847047c76759054577823fbe21075cfabb478cdafad341d480274fb1cef861c") version("3.0.0", sha256="95232710f5631bbf665964c0650df729c48104494e887442596128d189da43e0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi", when="+mpi") depends_on("zlib-api") depends_on("hdf5", when="+hdf5") diff --git a/var/spack/repos/builtin/packages/darshan-util/package.py b/var/spack/repos/builtin/packages/darshan-util/package.py index d83cbd2fbbe1dd..53899df259b10c 100644 --- a/var/spack/repos/builtin/packages/darshan-util/package.py +++ b/var/spack/repos/builtin/packages/darshan-util/package.py @@ -13,7 +13,7 @@ class DarshanUtil(AutotoolsPackage): log files produced by Darshan (runtime).""" homepage = "https://www.mcs.anl.gov/research/projects/darshan/" - url = "https://ftp.mcs.anl.gov/pub/darshan/releases/darshan-3.1.0.tar.gz" + url = "https://web.cels.anl.gov/projects/darshan/releases/darshan-3.4.0.tar.gz" git = "https://github.com/darshan-hpc/darshan.git" maintainers("shanedsnyder", "carns") @@ -21,6 +21,7 @@ class DarshanUtil(AutotoolsPackage): tags = ["e4s"] version("main", branch="main", submodules="True") + version("3.4.5", sha256="1c017ac635fab5ee0e87a6b52c5c7273962813569495cb1dd3b7cfa6e19f6ed0") version("3.4.4", sha256="d9c9df5aca94dc5ca3d56fd763bec2f74771d35126d61cb897373d2166ccd867") version("3.4.3", sha256="dca5f9f9b0ead55a8724b218071ecbb5c4f2ef6027eaade3a6477256930ccc2c") version("3.4.2", sha256="b095c3b7c059a8eba4beb03ec092b60708780a3cae3fc830424f6f9ada811c6b") @@ -45,6 +46,10 @@ class DarshanUtil(AutotoolsPackage): version("3.1.0", sha256="b847047c76759054577823fbe21075cfabb478cdafad341d480274fb1cef861c") version("3.0.0", sha256="95232710f5631bbf665964c0650df729c48104494e887442596128d189da43e0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("bzip2", default=False, description="Enable bzip2 compression") variant( "apmpi", diff --git a/var/spack/repos/builtin/packages/dash/package.py b/var/spack/repos/builtin/packages/dash/package.py index b5fe8a7cd19830..791bfc7f7582a3 100644 --- a/var/spack/repos/builtin/packages/dash/package.py +++ b/var/spack/repos/builtin/packages/dash/package.py @@ -18,6 +18,8 @@ class Dash(AutotoolsPackage): version("0.5.12", sha256="0d632f6b945058d84809cac7805326775bd60cb4a316907d0bd4228ff7107154") version("0.5.9.1", sha256="3f747013a20a3a9d2932be1a6dd1b002ca5649849b649be0af8a8da80bd8a918") + depends_on("c", type="build") # generated + depends_on("libedit", type="link") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/datamash/package.py b/var/spack/repos/builtin/packages/datamash/package.py index c36f9e83e6a104..dec03d20f2f291 100644 --- a/var/spack/repos/builtin/packages/datamash/package.py +++ b/var/spack/repos/builtin/packages/datamash/package.py @@ -23,4 +23,6 @@ class Datamash(AutotoolsPackage, GNUMirrorPackage): version("1.0.6", sha256="0154c25c45b5506b6d618ca8e18d0ef093dac47946ac0df464fb21e77b504118") version("1.0.5", sha256="cb7c0b7bf654eea5bb80f10c1710c8dffab8106549fd6b4341cba140e15a9938") + depends_on("c", type="build") # generated + build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/datatransferkit/package.py b/var/spack/repos/builtin/packages/datatransferkit/package.py index 3142f6140f3a5f..cd68df4ede6e97 100644 --- a/var/spack/repos/builtin/packages/datatransferkit/package.py +++ b/var/spack/repos/builtin/packages/datatransferkit/package.py @@ -26,6 +26,10 @@ class Datatransferkit(CMakePackage): version("3.1-rc3", commit="691d5a1540f7cd42141a3b3d2a7c8370cbc3560a", submodules=True) version("3.1-rc2", commit="1abc1a43b33dffc7a16d7497b4185d09d865e36a", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "external-arborx", default=False, @@ -43,7 +47,7 @@ class Datatransferkit(CMakePackage): depends_on("trilinos+openmp", when="+openmp") depends_on("trilinos+stratimikos+belos", when="@master") depends_on("trilinos@13:13.4.1", when="@3.1-rc2:3.1-rc3") - depends_on("trilinos@14:", when="@3.1.0:") + depends_on("trilinos@14.2:", when="@3.1.0:") def cmake_args(self): spec = self.spec diff --git a/var/spack/repos/builtin/packages/dateutils/package.py b/var/spack/repos/builtin/packages/dateutils/package.py index 64606671c0a9e7..2da01bf79f31d6 100644 --- a/var/spack/repos/builtin/packages/dateutils/package.py +++ b/var/spack/repos/builtin/packages/dateutils/package.py @@ -20,4 +20,6 @@ class Dateutils(AutotoolsPackage): version("0.4.6", sha256="26a071317ae5710f226a3e6ba9a54d3764cd9efe3965aecc18e75372088757cd") version("0.4.5", sha256="16d6a0fe7b7d49ddbb303f33538dd7304a0d4af5a0369bcbf275db6a5060cbde") + depends_on("c", type="build") # generated + build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/dbcsr/package.py b/var/spack/repos/builtin/packages/dbcsr/package.py index 8f207fb99b0c0c..0e0ff823a26392 100644 --- a/var/spack/repos/builtin/packages/dbcsr/package.py +++ b/var/spack/repos/builtin/packages/dbcsr/package.py @@ -28,6 +28,10 @@ class Dbcsr(CMakePackage, CudaPackage, ROCmPackage): version("2.1.0", sha256="9e58fd998f224632f356e479d18b5032570d00d87b86736b6a6ac2d03f8d4b3c") version("2.0.1", sha256="61d5531b661e1dab043353a1d67939ddcde3893d3dc7b0ab3d05074d448b485c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Compile with MPI") variant("openmp", default=False, description="Build with OpenMP support") variant("shared", default=True, description="Build shared library") @@ -54,7 +58,10 @@ class Dbcsr(CMakePackage, CudaPackage, ROCmPackage): depends_on("blas") depends_on("lapack") depends_on("mpi", when="+mpi") - depends_on("libxsmm@1.11:~header-only", when="smm=libxsmm") + + with when("smm=libxsmm"): + depends_on("libxsmm~header-only") + depends_on("libxsmm@1.11:1") depends_on("cmake@3.10:", type="build") depends_on("cmake@3.12:", type="build", when="@2.1:") diff --git a/var/spack/repos/builtin/packages/dbow2/package.py b/var/spack/repos/builtin/packages/dbow2/package.py index 08af93657bb317..ab9bdaa0cb8aed 100644 --- a/var/spack/repos/builtin/packages/dbow2/package.py +++ b/var/spack/repos/builtin/packages/dbow2/package.py @@ -18,6 +18,8 @@ class Dbow2(CMakePackage): version("master", branch="master") version("shinsumicco", git="https://github.com/shinsumicco/DBoW2.git", branch="master") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.0:", type="build") # TODO: replace this with an explicit list of components of Boost, # for instance depends_on('boost +filesystem') diff --git a/var/spack/repos/builtin/packages/dbus-glib/package.py b/var/spack/repos/builtin/packages/dbus-glib/package.py index cbee80b7ed8482..d9086972b89712 100644 --- a/var/spack/repos/builtin/packages/dbus-glib/package.py +++ b/var/spack/repos/builtin/packages/dbus-glib/package.py @@ -18,6 +18,8 @@ class DbusGlib(AutotoolsPackage): version("0.112", sha256="7d550dccdfcd286e33895501829ed971eeb65c614e73aadb4a08aeef719b143a") version("0.110", sha256="7ce4760cf66c69148f6bd6c92feaabb8812dee30846b24cd0f7395c436d7e825") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("expat") depends_on("glib") diff --git a/var/spack/repos/builtin/packages/dbus/package.py b/var/spack/repos/builtin/packages/dbus/package.py index 1d7ec8fc8e07a4..7c59223d99bfdc 100644 --- a/var/spack/repos/builtin/packages/dbus/package.py +++ b/var/spack/repos/builtin/packages/dbus/package.py @@ -30,6 +30,9 @@ class Dbus(AutotoolsPackage): version("1.8.4", sha256="3ef63dc8d0111042071ee7f7bafa0650c6ce2d7be957ef0b7ec269495a651ff8") version("1.8.2", sha256="5689f7411165adc953f37974e276a3028db94447c76e8dd92efe910c6d3bae08") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("xml_docs", default=False, description="Build XML documentation") variant("system-socket", default="default", description="Location for the DBus system socket") diff --git a/var/spack/repos/builtin/packages/dbxtool/package.py b/var/spack/repos/builtin/packages/dbxtool/package.py index 94e9cb8b4de691..6d361a1e5de128 100644 --- a/var/spack/repos/builtin/packages/dbxtool/package.py +++ b/var/spack/repos/builtin/packages/dbxtool/package.py @@ -17,6 +17,8 @@ class Dbxtool(MakefilePackage): version("8", sha256="196d9475f7cf3aa52d8e0c29c20affb7c903512e13895edb6296caf02d4a983b") version("7", sha256="486b8a7cf4e149ab9630783e5259d6af70a7022209e1e48fbee9b54c48535c5e") + depends_on("c", type="build") # generated + depends_on("efivar") depends_on("popt") diff --git a/var/spack/repos/builtin/packages/dcap/package.py b/var/spack/repos/builtin/packages/dcap/package.py index 87c25a443dc886..735f74c01d38af 100644 --- a/var/spack/repos/builtin/packages/dcap/package.py +++ b/var/spack/repos/builtin/packages/dcap/package.py @@ -16,6 +16,8 @@ class Dcap(AutotoolsPackage): version("2.47.12", sha256="050a8d20c241abf358d5d72586f9abc43940e61d9ec9480040ac7da52ec804ac") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/dcm2niix/package.py b/var/spack/repos/builtin/packages/dcm2niix/package.py index 97bf5a422e2140..530a58678ead90 100644 --- a/var/spack/repos/builtin/packages/dcm2niix/package.py +++ b/var/spack/repos/builtin/packages/dcm2niix/package.py @@ -15,9 +15,15 @@ class Dcm2niix(CMakePackage): license("Zlib") + version( + "1.0.20240202", sha256="ad8e4a5b97a682c32ef1d88283c15c7cb767c4092cb1754119f8e8b3d940fe91" + ) version( "1.0.20220720", sha256="a095545d6d70c5ce2efd90dcd58aebe536f135410c12165a9f231532ddab8991" ) version( "1.0.20210317", sha256="42fb22458ebfe44036c3d6145dacc6c1dc577ebbb067bedc190ed06f546ee05a" ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/dcmtk/package.py b/var/spack/repos/builtin/packages/dcmtk/package.py index f6c14c642ed6e7..94fdd48b680c59 100644 --- a/var/spack/repos/builtin/packages/dcmtk/package.py +++ b/var/spack/repos/builtin/packages/dcmtk/package.py @@ -22,6 +22,9 @@ class Dcmtk(CMakePackage): version("3.6.3", sha256="57f4f71ee4af9114be6408ff6fcafc441c349e4c2954e17c9c22c8ce0fb065bf") version("3.6.2", sha256="e9bf6e8805bbcf8a25274566541798785fd4e73bd046045ef27a0109ab520924") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("ssl", default=True, description="Suuport DICOM Security Enhancements one") depends_on("openssl", type=("build", "link"), when="+ssl") @@ -50,6 +53,8 @@ class Dcmtk(CMakePackage): conflicts("platform=darwin target=aarch64:", when="@:3.6.6") + patch("tiff-3.6.7.patch", when="@3.6.7") + def patch(self): # Backport 3.6.4 if self.spec.satisfies("@:3.6.3 %fj"): diff --git a/var/spack/repos/builtin/packages/dcmtk/tiff-3.6.7.patch b/var/spack/repos/builtin/packages/dcmtk/tiff-3.6.7.patch new file mode 100644 index 00000000000000..53df4e75eb4c33 --- /dev/null +++ b/var/spack/repos/builtin/packages/dcmtk/tiff-3.6.7.patch @@ -0,0 +1,12 @@ +diff --color=auto --color=never -Naur a/CMake/3rdparty.cmake b/CMake/3rdparty.cmake +--- a/CMake/3rdparty.cmake 2022-04-28 15:47:25 ++++ b/CMake/3rdparty.cmake 2024-07-12 15:04:19 +@@ -38,7 +38,7 @@ + message(STATUS "Info: DCMTK TIFF support will be enabled") + include_directories(${TIFF_INCLUDE_DIR} ${JPEG_INCLUDE_DIR}) + endif() +- set(LIBTIFF_LIBS ${TIFF_LIBRARY} ${TIFF_EXTRA_LIBS_STATIC} ${JPEG_LIBRARY}) ++ set(LIBTIFF_LIBS ${TIFF_LIBRARIES} ${TIFF_EXTRA_LIBS_STATIC} ${JPEG_LIBRARIES}) + endif() + endif() + diff --git a/var/spack/repos/builtin/packages/dctz/package.py b/var/spack/repos/builtin/packages/dctz/package.py new file mode 100755 index 00000000000000..df77705d628dd8 --- /dev/null +++ b/var/spack/repos/builtin/packages/dctz/package.py @@ -0,0 +1,39 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Dctz(CMakePackage): + """DCTZ is a compressor based on FFTs""" + + homepage = "https://github.com/swson/DCTZ" + url = "https://github.com/robertu94/DCTZ/archive/refs/tags/0.2.2.tar.gz" + git = "https://github.com/robertu94/DCTZ" + + maintainers("robertu94") + + license("MIT", checked_by="robertu94") + + version("0.2.2", sha256="5d270199b93e81704292ad87787ce961b458865c6a60ef7da59d5073513f6cff") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant("shared", description="build a shared library", default=True) + variant("libpressio", description="use libpressio support", default=True) + + depends_on("pkgconfig", type="build") + depends_on("zlib") + depends_on("fftw@3:") + depends_on("libpressio@0.0.99:", when="+libpressio") + depends_on("libstdcompat@0.0.21:", when="+libpressio") + + def cmake_args(self): + args = [ + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + self.define_from_variant("DCTZ_HAVE_LIBPRESSIO", "libpressio"), + ] + return args diff --git a/var/spack/repos/builtin/packages/dd4hep/package.py b/var/spack/repos/builtin/packages/dd4hep/package.py index 25647bcc21d83b..c6c45d9cfc838a 100644 --- a/var/spack/repos/builtin/packages/dd4hep/package.py +++ b/var/spack/repos/builtin/packages/dd4hep/package.py @@ -26,6 +26,7 @@ class Dd4hep(CMakePackage): license("LGPL-3.0-or-later") version("master", branch="master") + version("1.29", sha256="435d25a7ef093d8bf660f288b5a89b98556b4c1c293c55b93bf641fb4cba77e9") version("1.28", sha256="b28d671eda0154073873a044a384486e66f1f200065deca99537aa84f07328ad") version("1.27.2", sha256="09d8acd743d010274562b856d39e2a88aeaf89cf287a4148f52223b0cd960ab2") version("1.27.1", sha256="e66ae726c0a9a55e5603024a7f8a48ffbc5613ea36e5f892e9a90d87833f92e0") @@ -44,76 +45,11 @@ class Dd4hep(CMakePackage): version("1.18", sha256="1e909a42b969dfd966224fa8ab1eca5aa05136baf3c00a140f2f6d812b497152") version("1.17", sha256="036a9908aaf1e13eaf5f2f43b6f5f4a8bdda8183ddc5befa77a4448dbb485826") version("1.16.1", sha256="c8b1312aa88283986f89cc008d317b3476027fd146fdb586f9f1fbbb47763f1a") - # versions older than 1.16.1 are no longer supported - # (they need several patches like https://github.com/AIDASoft/DD4hep/pull/796) - version( - "1.16", - sha256="ea9755cd255cf1b058e0e3cd743101ca9ca5ff79f4c60be89f9ba72b1ae5ec69", - deprecated=True, - ) - version( - "1.15", - sha256="992a24bd4b3dfaffecec9d1c09e8cde2c7f89d38756879a47b23208242f4e352", - deprecated=True, - ) - version( - "1.14.1", - sha256="5b5742f1e23c2b36d3174cca95f810ce909c0eb66f3d6d7acb0ba657819e6717", - deprecated=True, - ) - version( - "1.14", - sha256="b603aa3c0db8dda392253aa71fa4a0f0c3c9715d47df0b895d45c1e8849f4895", - deprecated=True, - ) - version( - "1.13.1", - sha256="83fa70cd74ce93b2f52f098388dff58d179f05ace5b50aea3f408bb8abf7cb73", - deprecated=True, - ) - version( - "1.13", - sha256="0b1f9d902ebe21a9178c1e41204c066b29f68c8836fd1d03a9ce979811ddb295", - deprecated=True, - ) - version( - "1.12.1", - sha256="85e8c775ec03c499ce10911e228342e757c81ce9ef2a9195cb253b85175a2e93", - deprecated=True, - ) - # these version won't build with +ddcad as the subpackage doesn't exit yet - version( - "1.12", - sha256="133a1fb8ce0466d2482f3ebb03e60b3bebb9b2d3e33d14ba15c8fbb91706b398", - deprecated=True, - ) - version( - "1.11.2", - sha256="96a53dd26cb8df11c6dae54669fbc9cc3c90dd47c67e07b24be9a1341c95abc4", - deprecated=True, - ) - version( - "1.11.1", - sha256="d7902dd7f6744bbda92f6e303ad5a3410eec4a0d2195cdc86f6c1167e72893f0", - deprecated=True, - ) - version( - "1.11", - sha256="25643296f15f9d11ad4ad550b7c3b92e8974fc56f1ee8e4455501010789ae7b6", - deprecated=True, - ) - version( - "1.10", - sha256="1d6b5d1c368dc8bcedd9c61b7c7e1a44bad427f8bd34932516aff47c88a31d95", - deprecated=True, - ) + + depends_on("cxx", type="build") # generated generator("ninja") - # Workarounds for various TBB issues in DD4hep v1.11 - # See https://github.com/AIDASoft/DD4hep/pull/613 . - patch("tbb-workarounds.patch", when="@1.11") - patch("tbb2.patch", when="@1.12.1") # Workaround for failing build file generation in some cases # See https://github.com/spack/spack/issues/24232 patch("cmake_language.patch", when="@:1.17") @@ -161,10 +97,13 @@ class Dd4hep(CMakePackage): depends_on("boost +iostreams", when="+ddg4") depends_on("boost +system +filesystem", when="%gcc@:7") depends_on("root @6.08: +gdml +math +python") + depends_on("root @6.12.2: +root7", when="@1.26:") # DDCoreGraphics needs ROOT::ROOTHistDraw with when("+ddeve"): depends_on("root @6.08: +x +opengl") depends_on("root @:6.27", when="@:1.23") conflicts("^root ~webgui", when="^root@6.28:") + # For DD4hep >= 1.24, DDEve_Interface needs ROOT::ROOTGeomViewer only if ROOT >= 6.27 + requires("^root +root7 +webgui", when="@1.24: ^root @6.27:") depends_on("root @6.08: +gdml +math +python +x +opengl", when="+utilityapps") extends("python") @@ -189,7 +128,7 @@ class Dd4hep(CMakePackage): # See https://github.com/AIDASoft/DD4hep/pull/771 and https://github.com/AIDASoft/DD4hep/pull/876 conflicts( "^cmake@3.16:3.17.2", - when="@1.15:1.18", + when="@:1.18", msg="cmake version with buggy FindPython breaks dd4hep cmake config", ) conflicts("~ddrec+dddetectors", msg="Need to enable +ddrec to build +dddetectors.") diff --git a/var/spack/repos/builtin/packages/dd4hep/tbb-workarounds.patch b/var/spack/repos/builtin/packages/dd4hep/tbb-workarounds.patch deleted file mode 100644 index 6592329774349d..00000000000000 --- a/var/spack/repos/builtin/packages/dd4hep/tbb-workarounds.patch +++ /dev/null @@ -1,41 +0,0 @@ -diff --git a/DDDigi/CMakeLists.txt b/DDDigi/CMakeLists.txt -index e6fb1096..88eb5c92 100644 ---- a/DDDigi/CMakeLists.txt -+++ b/DDDigi/CMakeLists.txt -@@ -34,12 +34,10 @@ target_include_directories(DDDigi - - FIND_PACKAGE(TBB QUIET) - if(TBB_FOUND) -- dd4hep_print( "|++> TBB_INCLUDE_DIR --> ${TBB_INCLUDE_DIR}") -- dd4hep_print( "|++> TBB_LIBRARY --> ${TBB_LIBRARY}") -+ dd4hep_print( "|++> TBB_IMPORTED_TARGETS --> ${TBB_IMPORTED_TARGETS}") - dd4hep_print( "|++> TBB found. DDDigi will run multi threaded.") - target_compile_definitions(DDDigi PUBLIC DD4HEP_USE_TBB) -- target_link_libraries(DDDigi ${TBB_LIBRARY}) -- target_include_directories(DDDigi ${TBB_INCLUDE_DIRS}) -+ target_link_libraries(DDDigi PUBLIC ${TBB_IMPORTED_TARGETS}) - else() - dd4hep_print( "|++> TBB not found. DDDigi will only work single threaded.") - endif() -diff --git a/DDDigi/src/DigiKernel.cpp b/DDDigi/src/DigiKernel.cpp -index d62c6694..f2c2e86c 100644 ---- a/DDDigi/src/DigiKernel.cpp -+++ b/DDDigi/src/DigiKernel.cpp -@@ -91,7 +91,7 @@ public: - DigiEventAction* action = 0; - Wrapper(DigiContext& c, DigiEventAction* a) - : context(c), action(a) {} -- Wrapper(Wrapper&& copy) = delete; -+ Wrapper(Wrapper&& copy) = default; - Wrapper(const Wrapper& copy) = default; - Wrapper& operator=(Wrapper&& copy) = delete; - Wrapper& operator=(const Wrapper& copy) = delete; -@@ -111,7 +111,7 @@ class DigiKernel::Processor { - DigiKernel& kernel; - public: - Processor(DigiKernel& k) : kernel(k) {} -- Processor(Processor&& l) = delete; -+ Processor(Processor&& l) = default; - Processor(const Processor& l) = default; - void operator()() const { - int todo = 1; diff --git a/var/spack/repos/builtin/packages/dd4hep/tbb2.patch b/var/spack/repos/builtin/packages/dd4hep/tbb2.patch deleted file mode 100644 index 932458001c211c..00000000000000 --- a/var/spack/repos/builtin/packages/dd4hep/tbb2.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff --git a/DDDigi/src/DigiKernel.cpp b/DDDigi/src/DigiKernel.cpp -index f2c2e86c..f168ef9b 100644 ---- a/DDDigi/src/DigiKernel.cpp -+++ b/DDDigi/src/DigiKernel.cpp -@@ -273,7 +273,7 @@ void DigiKernel::submit(const DigiAction::Actors& actions, Digi - if ( parallel ) { - tbb::task_group que; - for ( auto* i : actions ) -- que.run(Wrapper(context, *i)); -+ que.run(Wrapper(context, i)); - que.wait(); - goto print_stamp; - } - diff --git a/var/spack/repos/builtin/packages/dealii-parameter-gui/package.py b/var/spack/repos/builtin/packages/dealii-parameter-gui/package.py index fd5ebcf4e0d5c1..7e3b90521b5518 100644 --- a/var/spack/repos/builtin/packages/dealii-parameter-gui/package.py +++ b/var/spack/repos/builtin/packages/dealii-parameter-gui/package.py @@ -17,6 +17,8 @@ class DealiiParameterGui(CMakePackage): version("develop", branch="master") + depends_on("cxx", type="build") # generated + depends_on("qt") def setup_run_environment(self, env): diff --git a/var/spack/repos/builtin/packages/dealii/package.py b/var/spack/repos/builtin/packages/dealii/package.py index f9ec14adf3ad64..6ea7f851d6cabf 100644 --- a/var/spack/repos/builtin/packages/dealii/package.py +++ b/var/spack/repos/builtin/packages/dealii/package.py @@ -51,6 +51,10 @@ class Dealii(CMakePackage, CudaPackage): version("8.2.1", sha256="d75674e45fe63cd9fa294460fe45228904d51a68f744dbb99cd7b60720f3b2a0") version("8.1.0", sha256="d666bbda2a17b41b80221d7029468246f2658051b8c00d9c5907cd6434c4df99") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Configuration variants variant( "build_type", @@ -177,6 +181,7 @@ class Dealii(CMakePackage, CudaPackage): depends_on("arpack-ng+mpi", when="+arpack+mpi") depends_on("assimp", when="@9.0:+assimp") depends_on("cgal", when="@9.4:+cgal") + depends_on("cgal@5:", when="@9.5:+cgal") depends_on("doxygen+graphviz", when="+doc") depends_on("graphviz", when="+doc") depends_on("ginkgo", when="@9.1:+ginkgo") @@ -206,7 +211,7 @@ class Dealii(CMakePackage, CudaPackage): depends_on("slepc~arpack", when="+slepc+petsc+mpi+int64") depends_on("sundials@:3~pthread", when="@9.0:9.2+sundials") depends_on("sundials@5:5.8", when="@9.3:9.3.3+sundials") - depends_on("sundials@5:", when="@9.3.4:+sundials") + depends_on("sundials@5:6.7", when="@9.3.4:+sundials") depends_on("taskflow@3.4:", when="@9.6:+taskflow") depends_on("trilinos gotype=int", when="+trilinos@12.18.1:") # TODO: next line fixes concretization with trilinos and adol-c @@ -289,6 +294,9 @@ class Dealii(CMakePackage, CudaPackage): when="@:9.4 +ginkgo ^ginkgo@1.5.0:", ) + # deal.II's own CUDA backend does not support CUDA version 12.0 or newer. + conflicts("+cuda ^cuda@12:") + # Check for sufficiently modern versions conflicts("cxxstd=11", when="@9.3:") diff --git a/var/spack/repos/builtin/packages/debugedit/package.py b/var/spack/repos/builtin/packages/debugedit/package.py index 1c258d9fcef998..5bfa199736290b 100644 --- a/var/spack/repos/builtin/packages/debugedit/package.py +++ b/var/spack/repos/builtin/packages/debugedit/package.py @@ -23,6 +23,8 @@ class Debugedit(AutotoolsPackage): version("develop", branch="main") version("0.2", sha256="b78258240bb7ec5bbff109495092dcc111aa0393f135f2d2a4b43887ba26a942") + depends_on("c", type="build") # generated + depends_on("help2man", type="build") depends_on("pkgconfig", type="build") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/decentralized-internet/package.py b/var/spack/repos/builtin/packages/decentralized-internet/package.py index 63eace559fd4ad..395a9929673845 100644 --- a/var/spack/repos/builtin/packages/decentralized-internet/package.py +++ b/var/spack/repos/builtin/packages/decentralized-internet/package.py @@ -16,3 +16,5 @@ class DecentralizedInternet(MakefilePackage): maintainers("Lonero-Team", "Mentors4edu") version("4.2.3", sha256="2922b9128b411ece2f04d07942a453f1e772548aa27b3936c9f9bcfbc0737058") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/deconseq-standalone/package.py b/var/spack/repos/builtin/packages/deconseq-standalone/package.py index 47314ef952136b..d5bd5bcf1e37a5 100644 --- a/var/spack/repos/builtin/packages/deconseq-standalone/package.py +++ b/var/spack/repos/builtin/packages/deconseq-standalone/package.py @@ -17,6 +17,8 @@ class DeconseqStandalone(Package): version("0.4.3", sha256="fb4050418c26a5203220f6396263da554326657590cffd65053eb8adc465ac65") + depends_on("c", type="build") # generated + depends_on("perl@5:") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/dedisp/package.py b/var/spack/repos/builtin/packages/dedisp/package.py new file mode 100644 index 00000000000000..7634ba306c0680 --- /dev/null +++ b/var/spack/repos/builtin/packages/dedisp/package.py @@ -0,0 +1,45 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Dedisp(MakefilePackage, CudaPackage): + """GPU-based dedispersion package.""" + + homepage = "https://github.com/ajameson/dedisp" + git = "https://github.com/ajameson/dedisp.git" + + maintainers("aweaver1fandm") + + version("master", branch="master", preferred=True) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + conflicts("~cuda", msg="You must specify +cuda") + conflicts("cuda@11.8") + conflicts("cuda_arch=none", msg="You must specify the CUDA architecture") + + depends_on("cuda", type="build") + + def edit(self, spec, prefix): + # Build process required some edits to Makefile.inc instead of using command-line flags + makefile = FileFilter("Makefile.inc") + + makefile.filter(r"^\s*CUDA_PATH\s*\?=.*", "CUDA_PATH ?= " + spec["cuda"].prefix) + makefile.filter( + r"^\s*GPU_ARCH\s*\?=.*", "GPU_ARCH ?= sm_" + spec.variants["cuda_arch"].value[0] + ) + makefile.filter(r"^\s*INSTALL_DIR\s*\?=.*", "INSTALL_DIR ?= " + prefix) + + @run_before("install") + def preinstall(self): + # The $PREFIX/dedisp/include and $PREFIX/dedisp/lib directories don't seem + # to be created automatically by the software's Makefile so manually create them + libdir = join_path(self.prefix, "lib") + incdir = join_path(self.prefix, "include") + mkdirp(libdir) + mkdirp(incdir) diff --git a/var/spack/repos/builtin/packages/dejagnu/package.py b/var/spack/repos/builtin/packages/dejagnu/package.py index 94d808fd36faca..5f9baa0fb2e900 100644 --- a/var/spack/repos/builtin/packages/dejagnu/package.py +++ b/var/spack/repos/builtin/packages/dejagnu/package.py @@ -19,6 +19,9 @@ class Dejagnu(AutotoolsPackage, GNUMirrorPackage): version("1.6", sha256="00b64a618e2b6b581b16eb9131ee80f721baa2669fa0cdee93c500d1a652d763") version("1.4.4", sha256="d0fbedef20fb0843318d60551023631176b27ceb1e11de7468a971770d0e048d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("expect", type=("run", "link", "build")) # DejaGnu 1.4.4 cannot be built in parallel diff --git a/var/spack/repos/builtin/packages/delly2/package.py b/var/spack/repos/builtin/packages/delly2/package.py index 24296810e0d28b..58af5910767d78 100644 --- a/var/spack/repos/builtin/packages/delly2/package.py +++ b/var/spack/repos/builtin/packages/delly2/package.py @@ -25,6 +25,8 @@ class Delly2(MakefilePackage): version("0.9.1", tag="v0.9.1", commit="ef1cd626a85cfd1c1b7acfca2b5fd5957f2a05f1") version("2017-08-03", commit="e32a9cd55c7e3df5a6ae4a91f31a0deb354529fc", deprecated=True) + depends_on("cxx", type="build") # generated + variant("openmp", default=False, description="Build with openmp support") depends_on("htslib", type=("build", "link")) diff --git a/var/spack/repos/builtin/packages/delphes/package.py b/var/spack/repos/builtin/packages/delphes/package.py index ccc1258c550cfe..a35a6784053839 100644 --- a/var/spack/repos/builtin/packages/delphes/package.py +++ b/var/spack/repos/builtin/packages/delphes/package.py @@ -43,6 +43,9 @@ class Delphes(CMakePackage): version("3.0.6", sha256="9e225731d57d2a76d35886841f8eff121bb3a45560b16077bd8c351151581d88") version("3.0.5", sha256="ab64ec6d2476fbfa40562e7edb510a8ab4c4fe5be77a4353ebf315c2af181a80") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("pythia8", default=True, description="build with pythia8") depends_on("cmake", type="build") diff --git a/var/spack/repos/builtin/packages/demuxlet/package.py b/var/spack/repos/builtin/packages/demuxlet/package.py index d0724e204ef6ee..6c98a2ca010f65 100644 --- a/var/spack/repos/builtin/packages/demuxlet/package.py +++ b/var/spack/repos/builtin/packages/demuxlet/package.py @@ -19,6 +19,8 @@ class Demuxlet(AutotoolsPackage): version("20210211", commit="f5044eb9ed5c6678aa3a80a8f2be7db7748ee732") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/denovogear/package.py b/var/spack/repos/builtin/packages/denovogear/package.py index b679b51cb06fc9..e378af69a43d85 100644 --- a/var/spack/repos/builtin/packages/denovogear/package.py +++ b/var/spack/repos/builtin/packages/denovogear/package.py @@ -20,6 +20,9 @@ class Denovogear(CMakePackage): version("1.1.1", sha256="799fe99193e9cf12320893cf020a3251022f60a49de8677a1c5a18c578fe4be2") version("1.1.0", sha256="f818f80cd67183294c8aae312cad8311e6a9abede1f687567bb079d29f79c005") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type=("build")) depends_on( "boost@1.47:1.60" diff --git a/var/spack/repos/builtin/packages/detray/package.py b/var/spack/repos/builtin/packages/detray/package.py new file mode 100644 index 00000000000000..85d0c57531195d --- /dev/null +++ b/var/spack/repos/builtin/packages/detray/package.py @@ -0,0 +1,83 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Detray(CMakePackage): + """Detray is a description library for high energy physics experiments that + works entirely without polymorphism, making it exceptionally suitable for + use on GPU platforms.""" + + homepage = "https://github.com/acts-project/detray" + url = "https://github.com/acts-project/detray/archive/refs/tags/v0.67.0.tar.gz" + + tags = ["hep"] + + maintainers("stephenswat") + + license("MPL-2.0", checked_by="stephenswat") + + version("0.69.1", sha256="7100ec86a47458a35f5943cd6c7da07c68b8c1c2f62d36d13b8bb50568d0abe5") + version("0.68.0", sha256="6d57835f22ced9243fbcc29b84ea4c01878a46bfa5910e320c933e9bf8e96612") + version("0.67.0", sha256="87b1b29f333c955ea6160f9dda89628490d85a9e5186c2f35f57b322bbe27e18") + + variant("csv", default=True, description="Enable the CSV IO plugin") + variant( + "cxxstd", + default="17", + values=("17", "20", "23"), + multi=False, + description="C++ standard used", + ) + variant("json", default=True, description="Enable the JSON IO plugin") + variant( + "scalar", + default="float", + values=("float", "double"), + multi=False, + description="Scalar type to use by default", + ) + variant("eigen", default=True, description="Enable the Eigen math plugin") + variant("smatrix", default=False, description="Enable the SMatrix math plugin") + variant("vc", default=True, description="Enable the Vc math plugin") + + depends_on("cmake@3.11:", type="build") + depends_on("vecmem@1.6.0:") + depends_on("covfie@0.10.0:") + depends_on("nlohmann-json@3.11.0:", when="+json") + depends_on("dfelibs@20211029:") + depends_on("acts-algebra-plugins@0.18.0: +vecmem") + depends_on("acts-algebra-plugins +vc", when="+vc") + depends_on("acts-algebra-plugins +eigen", when="+eigen") + depends_on("acts-algebra-plugins +smatrix", when="+smatrix") + + with when("+smatrix"): + depends_on("acts-algebra-plugins cxxstd=17", when="cxxstd=17") + depends_on("acts-algebra-plugins cxxstd=20", when="cxxstd=20") + depends_on("acts-algebra-plugins cxxstd=23", when="cxxstd=23") + + depends_on("actsvg +meta") + + def cmake_args(self): + args = [ + self.define("DETRAY_USE_SYSTEM_LIBS", True), + self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), + self.define_from_variant("CMAKE_CUDA_STANDARD", "cxxstd"), + self.define_from_variant("CMAKE_SYCL_STANDARD", "cxxstd"), + self.define_from_variant("DETRAY_CUSTOM_SCALARTYPE", "scalar"), + self.define_from_variant("DETRAY_EIGEN_PLUGIN", "eigen"), + self.define_from_variant("DETRAY_SMATRIX_PLUGIN", "smatrix"), + self.define_from_variant("DETRAY_IO_CSV", "csv"), + self.define_from_variant("DETRAY_IO_JSON", "json"), + self.define("DETRAY_SVG_DISPLAY", True), + self.define("DETRAY_SETUP_ACTSVG", True), + self.define("DETRAY_BUILD_TESTING", False), + self.define("DETRAY_SETUP_GOOGLETEST", False), + self.define("DETRAY_SETUP_BENCHMARK", False), + self.define("DETRAY_BUILD_TUTORIALS", False), + ] + + return args diff --git a/var/spack/repos/builtin/packages/dfelibs/package.py b/var/spack/repos/builtin/packages/dfelibs/package.py new file mode 100644 index 00000000000000..c2ec7d65acbd31 --- /dev/null +++ b/var/spack/repos/builtin/packages/dfelibs/package.py @@ -0,0 +1,33 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Dfelibs(CMakePackage): + """Acts fork of dfelibs, a header-only utility library for C++.""" + + homepage = "https://github.com/acts-project/dfelibs" + url = "https://github.com/acts-project/dfelibs/archive/refs/tags/v20211029.tar.gz" + + maintainers("stephenswat", "wdconinc") + + license("MIT", checked_by="stephenswat") + + version("20231012", sha256="7127069858c2e3ce663e66f45e3f7e02ede8bbca23d90f6c89f43f5b05c44dcb") + version("20211029", sha256="65b8d536b06b550e38822905dea06d193beb703fe0e4442791f43dc087c5cbfb") + + depends_on("cxx", type="build") # generated + + depends_on("cmake@3.8:", type="build") + depends_on("boost@1.59:", type="test") + + def cmake_args(self): + args = [ + self.define("dfelibs_BUILD_EXAMPLES", False), + self.define("dfelibs_BUILD_UNITTESTS", self.run_tests), + ] + + return args diff --git a/var/spack/repos/builtin/packages/dftbplus/package.py b/var/spack/repos/builtin/packages/dftbplus/package.py index 1efaf68aa4ad3f..fbd6a9fd46b781 100644 --- a/var/spack/repos/builtin/packages/dftbplus/package.py +++ b/var/spack/repos/builtin/packages/dftbplus/package.py @@ -27,6 +27,7 @@ class Dftbplus(CMakePackage, MakefilePackage): license("CC-BY-SA-4.0") version("main", branch="main") + version("24.1", sha256="3bc405d1ab834b6b145ca671fb44565ec50a6f576e9e18e7a1ae2c613a311321") version("23.1", sha256="e2d0471c2fd3aaf174a9aac44fd8e7de2668d182201779626d6e62754adc4cf9") version("22.2", sha256="0140f5f2e24d3071e5e7aede2ed6216a6f46d55216b0d69da17af917c62e98ed") version("22.1", sha256="02daca6f4c6372656598f3ba0311110c8e473c87c8d934d7bb276feaa4cc1c82") @@ -41,6 +42,10 @@ class Dftbplus(CMakePackage, MakefilePackage): sha256="78f45ef0571c78cf732a5493d32830455a832fa05ebcad43098895e46ad8d220", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "api", default=True, diff --git a/var/spack/repos/builtin/packages/dftd3-lib/package.py b/var/spack/repos/builtin/packages/dftd3-lib/package.py index ff42d16ab86310..b28c0509802495 100644 --- a/var/spack/repos/builtin/packages/dftd3-lib/package.py +++ b/var/spack/repos/builtin/packages/dftd3-lib/package.py @@ -13,8 +13,11 @@ class Dftd3Lib(MakefilePackage): homepage = "https://www.chemie.uni-bonn.de/pctc/mulliken-center/software/dft-d3/dft-d3" url = "https://github.com/dftbplus/dftd3-lib/archive/0.9.2.tar.gz" + version("0.10", sha256="db61bc6c7c699628e8c5bf2018ea38de03a53eac38014e06845829d765caf6bb") version("0.9.2", sha256="4178f3cf2f3e7e982a7084ec66bac92b4fdf164537d9fc0ada840a11b784f0e0") + depends_on("fortran", type="build") # generated + # This fixes a concurrency bug, where make would try to start compiling # the dftd3 target before the lib target ended. # Since the library is small, disabling causes not much harm diff --git a/var/spack/repos/builtin/packages/dftd4/package.py b/var/spack/repos/builtin/packages/dftd4/package.py index 8c2d5c62889f02..a55cc34d4eff66 100644 --- a/var/spack/repos/builtin/packages/dftd4/package.py +++ b/var/spack/repos/builtin/packages/dftd4/package.py @@ -25,6 +25,9 @@ class Dftd4(MesonPackage): version("3.1.0", sha256="b652aa7cbf8d087c91bcf80f2d5801459ecf89c5d4176ebb39e963ee740ed54b") version("3.0.0", sha256="a7539d68d48d851bf37b79e37ea907c9da5eee908d0aa58a0a7dc15f04f8bc35") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=True, description="Use OpenMP parallelisation") variant("python", default=False, description="Build Python extension module") diff --git a/var/spack/repos/builtin/packages/dftfe/package.py b/var/spack/repos/builtin/packages/dftfe/package.py index a4423d68197dbc..7e6973257e48ab 100644 --- a/var/spack/repos/builtin/packages/dftfe/package.py +++ b/var/spack/repos/builtin/packages/dftfe/package.py @@ -20,6 +20,8 @@ class Dftfe(CMakePackage): version("0.5.1", sha256="e47272d3783cf675dcd8bc31da07765695164110bfebbbab29f5815531f148c1") version("0.5.0", sha256="9aadb9a9b059f98f88c7756b417423dc67d02f1cdd2ed7472ba395fcfafc6dcb") + depends_on("cxx", type="build") # generated + variant( "scalapack", default=True, diff --git a/var/spack/repos/builtin/packages/dhtest/package.py b/var/spack/repos/builtin/packages/dhtest/package.py index e673ef2d4de572..60d42644982ccc 100644 --- a/var/spack/repos/builtin/packages/dhtest/package.py +++ b/var/spack/repos/builtin/packages/dhtest/package.py @@ -19,6 +19,8 @@ class Dhtest(MakefilePackage): version("1.5", sha256="df66150429a59a3b6cea9b29e2687707d04ab10db5dfe1c893ba3e0b0531b151") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("dhtest", prefix.bin) diff --git a/var/spack/repos/builtin/packages/dia/package.py b/var/spack/repos/builtin/packages/dia/package.py index 9fe94c845255fe..258d5773f3658e 100644 --- a/var/spack/repos/builtin/packages/dia/package.py +++ b/var/spack/repos/builtin/packages/dia/package.py @@ -16,6 +16,9 @@ class Dia(Package): version("0.97.3", sha256="22914e48ef48f894bb5143c5efc3d01ab96e0a0cde80de11058d3b4301377d34") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("intltool", type="build") depends_on("gettext", type="build") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/dialign/package.py b/var/spack/repos/builtin/packages/dialign/package.py index 7617794128d574..a7c86efb8e36e7 100644 --- a/var/spack/repos/builtin/packages/dialign/package.py +++ b/var/spack/repos/builtin/packages/dialign/package.py @@ -17,6 +17,8 @@ class Dialign(MakefilePackage): version("2.2.1", sha256="046361bb4ca6e4ab2ac5e634cfcd673f964a887006c09c1b8bd3310fac86f519") + depends_on("c", type="build") # generated + build_directory = "src" def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/diamond/package.py b/var/spack/repos/builtin/packages/diamond/package.py index c0ea26edd5fba9..62a7c101ddcb88 100644 --- a/var/spack/repos/builtin/packages/diamond/package.py +++ b/var/spack/repos/builtin/packages/diamond/package.py @@ -16,6 +16,8 @@ class Diamond(CMakePackage): license("GPL-3.0-only") + version("2.1.9", sha256="4cde9df78c63e8aef9df1e3265cd06a93ce1b047d6dba513a1437719b70e9d88") + version("2.1.8", sha256="b6088259f2bc92d1f9dc4add44590cff68321bcbf91eefbc295a3525118b9415") version("2.1.7", sha256="2dcaba0e79ecb02c3d2a6816d317e714767118a9a056721643abff4c586ca95b") version("2.1.6", sha256="852d27c7535d53f1ce59db0625ff23ac3bf17e57f7a3b1c46c08718f77e19c54") version("2.0.15", sha256="cc8e1f3fd357d286cf6585b21321bd25af69aae16ae1a8f605ea603c1886ffa4") @@ -34,6 +36,9 @@ class Diamond(CMakePackage): version("0.8.38", sha256="582a7932f3aa73b0eac2275dd773818665f0b067b32a79ff5a13b0e3ca375f60") version("0.8.26", sha256="00d2be32dad76511a767ab8e917962c0ecc572bc808080be60dec028df45439f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") conflicts("target=aarch64:", when="@:0.9.25") diff --git a/var/spack/repos/builtin/packages/dicom3tools/package.py b/var/spack/repos/builtin/packages/dicom3tools/package.py index b49547f0b7c427..d5c2f315a43d25 100644 --- a/var/spack/repos/builtin/packages/dicom3tools/package.py +++ b/var/spack/repos/builtin/packages/dicom3tools/package.py @@ -20,6 +20,8 @@ class Dicom3tools(MakefilePackage): sha256="3cc2d6056e349e0ac6a093d231d8f4dd7a77e26ed29c1ebaca945dd5e56c1520", ) + depends_on("cxx", type="build") # generated + variant( "uid_root", default="0.0.0.0", diff --git a/var/spack/repos/builtin/packages/diffmark/package.py b/var/spack/repos/builtin/packages/diffmark/package.py index 73f405bf96e037..5d61f9551f4bbe 100644 --- a/var/spack/repos/builtin/packages/diffmark/package.py +++ b/var/spack/repos/builtin/packages/diffmark/package.py @@ -16,6 +16,8 @@ class Diffmark(AutotoolsPackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/diffsplice/package.py b/var/spack/repos/builtin/packages/diffsplice/package.py index 128663a98991a6..5246249d7ba731 100644 --- a/var/spack/repos/builtin/packages/diffsplice/package.py +++ b/var/spack/repos/builtin/packages/diffsplice/package.py @@ -19,6 +19,8 @@ class Diffsplice(MakefilePackage): version("0.1.2beta", sha256="cc06dcb9f8d98b2184f0dd5863b79bdd6a8cd33b9418e6549b7ea63e90ee1aa6") version("0.1.1", sha256="9740426692b0e5f92b943b127014c1d9815bed2938b5dd9e9d0c5b64abbb5da6") + depends_on("cxx", type="build") # generated + def edit(self, spec, prefix): if spec.target.family == "aarch64": makefile = FileFilter(join_path(self.build_directory, "Makefile")) diff --git a/var/spack/repos/builtin/packages/diffutils/package.py b/var/spack/repos/builtin/packages/diffutils/package.py index b24852f7af2b30..18468f662f3099 100644 --- a/var/spack/repos/builtin/packages/diffutils/package.py +++ b/var/spack/repos/builtin/packages/diffutils/package.py @@ -27,6 +27,8 @@ class Diffutils(AutotoolsPackage, GNUMirrorPackage): version("3.7", sha256="b3a7a6221c3dc916085f0d205abf6b8e1ba443d4dd965118da364a1dc1cb3a26") version("3.6", sha256="d621e8bdd4b573918c8145f7ae61817d1be9deb4c8d2328a65cea8e11d783bd6") + depends_on("c", type="build") # generated + build_directory = "spack-build" patch("nvhpc.patch", when="@3.7 %nvhpc") diff --git a/var/spack/repos/builtin/packages/digitrounding/package.py b/var/spack/repos/builtin/packages/digitrounding/package.py index 3697955ff66d58..c61687a2cb07e1 100644 --- a/var/spack/repos/builtin/packages/digitrounding/package.py +++ b/var/spack/repos/builtin/packages/digitrounding/package.py @@ -19,6 +19,8 @@ class Digitrounding(CMakePackage): version("master", branch="master") version("2020-02-27", commit="7b18679aded7a85e6f221f7f5cd4f080f322bc33") + depends_on("c", type="build") # generated + depends_on("zlib-api") variant("shared", default=True, description="build shared libraries") diff --git a/var/spack/repos/builtin/packages/dihydrogen/package.py b/var/spack/repos/builtin/packages/dihydrogen/package.py index ea48ff48fe91a6..1b8834fafe0472 100644 --- a/var/spack/repos/builtin/packages/dihydrogen/package.py +++ b/var/spack/repos/builtin/packages/dihydrogen/package.py @@ -61,6 +61,8 @@ class Dihydrogen(CachedCMakePackage, CudaPackage, ROCmPackage): version("0.3.0", sha256="8dd143441a28e0c7662cd92694e9a4894b61fd48508ac1d77435f342bc226dcf") + depends_on("cxx", type="build") # generated + # Primary features variant("dace", default=False, sticky=True, description="Enable DaCe backend.") @@ -257,13 +259,6 @@ def initconfig_compiler_entries(self): entries.append(cmake_cache_string("CMAKE_CXX_STANDARD", "17")) entries.append(cmake_cache_option("BUILD_SHARED_LIBS", "+shared" in spec)) entries.append(cmake_cache_option("CMAKE_EXPORT_COMPILE_COMMANDS", True)) - - # It's possible this should have a `if "platform=cray" in - # spec:` in front of it, but it's not clear to me when this is - # set. In particular, I don't actually see this blurb showing - # up on Tioga builds. Which is causing the obvious problem - # (namely, the one this was added to supposedly solve in the - # first place. entries.append(cmake_cache_option("MPI_ASSUME_NO_BUILTIN_MPI", True)) if spec.satisfies("%clang +distconv platform=darwin"): diff --git a/var/spack/repos/builtin/packages/dimemas/package.py b/var/spack/repos/builtin/packages/dimemas/package.py index 8c5751fbc53377..2c41548e82ee50 100644 --- a/var/spack/repos/builtin/packages/dimemas/package.py +++ b/var/spack/repos/builtin/packages/dimemas/package.py @@ -16,6 +16,9 @@ class Dimemas(AutotoolsPackage): version("5.4.1", sha256="10ddca3745a56ebab5c1ba180f6f4bce5832c4deac50c1b1dc08271db5c7cafa") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/ding-libs/package.py b/var/spack/repos/builtin/packages/ding-libs/package.py index f8714e2f01ee40..c7c322279e7a34 100644 --- a/var/spack/repos/builtin/packages/ding-libs/package.py +++ b/var/spack/repos/builtin/packages/ding-libs/package.py @@ -16,3 +16,5 @@ class DingLibs(AutotoolsPackage): version("0.6.1", sha256="a319a327deb81f2dfab9ce4a4926e80e1dac5dcfc89f4c7e548cec2645af27c1") version("0.6.0", sha256="764a211f40cbcf2c9a613fc7ce0d77799d5ee469221b8b6739972e76f09e9fad") version("0.5.0", sha256="dab937537a05d7a7cbe605fdb9b3809080d67b124ac97eb321255b35f5b172fd") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/dire/package.py b/var/spack/repos/builtin/packages/dire/package.py index 1d7630754a7c58..b819f019e794cc 100644 --- a/var/spack/repos/builtin/packages/dire/package.py +++ b/var/spack/repos/builtin/packages/dire/package.py @@ -23,6 +23,8 @@ class Dire(Package): version("2.004", sha256="8cc1213b58fec744fdaa50834560a14b141de99efb2c3e3d3d47f3d6d84b179f") + depends_on("cxx", type="build") # generated + depends_on("zlib-api") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/discotec/package.py b/var/spack/repos/builtin/packages/discotec/package.py index aa876aa1cd34a0..cc41090c452676 100644 --- a/var/spack/repos/builtin/packages/discotec/package.py +++ b/var/spack/repos/builtin/packages/discotec/package.py @@ -20,6 +20,8 @@ class Discotec(CMakePackage): version("main", branch="main") + depends_on("cxx", type="build") # generated + variant("compression", default=False, description="Write sparse grid files compressed") variant("ft", default=False, description="DisCoTec with algorithm-based fault tolerance") variant("gene", default=False, description="Build for GENE (as task library)") diff --git a/var/spack/repos/builtin/packages/discovar/package.py b/var/spack/repos/builtin/packages/discovar/package.py index 95c5bcdb1c530b..474546aae9c448 100644 --- a/var/spack/repos/builtin/packages/discovar/package.py +++ b/var/spack/repos/builtin/packages/discovar/package.py @@ -16,4 +16,6 @@ class Discovar(AutotoolsPackage): version("52488", sha256="c46e8f5727b3c8116d715c02e20a83e6261c762e8964d00709abfb322a501d4e") + depends_on("cxx", type="build") # generated + conflicts("%gcc@6:") diff --git a/var/spack/repos/builtin/packages/discovardenovo/package.py b/var/spack/repos/builtin/packages/discovardenovo/package.py index a84709eba6ba63..e5e09a455b0c24 100644 --- a/var/spack/repos/builtin/packages/discovardenovo/package.py +++ b/var/spack/repos/builtin/packages/discovardenovo/package.py @@ -19,6 +19,8 @@ class Discovardenovo(AutotoolsPackage): version("52488", sha256="445445a3b75e17e276a6119434f13784a5a661a9c7277f5e10f3b6b3b8ac5771") + depends_on("cxx", type="build") # generated + # lots of compiler errors with GCC7, works with 4.8.5 # and devs claim it works with 4.7 so I'm assuming 4.7-4.8'll work conflicts("%gcc@5:") diff --git a/var/spack/repos/builtin/packages/disktype/package.py b/var/spack/repos/builtin/packages/disktype/package.py index 3ca4692da967f6..90eb8b86821e01 100644 --- a/var/spack/repos/builtin/packages/disktype/package.py +++ b/var/spack/repos/builtin/packages/disktype/package.py @@ -16,6 +16,8 @@ class Disktype(MakefilePackage): version("9.2.1", sha256="fb274d6ce6b69c0d36eb23fcc9f01db3c32c3996b404900d46bb743ce4fa8154") + depends_on("c", type="build") # generated + build_directory = "src" def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/distbench/package.py b/var/spack/repos/builtin/packages/distbench/package.py index 02daf6b841b262..fe4dc758f01ec0 100644 --- a/var/spack/repos/builtin/packages/distbench/package.py +++ b/var/spack/repos/builtin/packages/distbench/package.py @@ -17,6 +17,8 @@ class Distbench(MakefilePackage): version("1.0rc4", sha256="adc8da85890219800207d0d4cd7ffd63193d2c4007dba7c44cf545cc13675ff7") + depends_on("cxx", type="build") # generated + depends_on("bazel", type="build") def patch(self): diff --git a/var/spack/repos/builtin/packages/distcc/package.py b/var/spack/repos/builtin/packages/distcc/package.py index 629cd3fc0ace1c..95d817301bd0e1 100644 --- a/var/spack/repos/builtin/packages/distcc/package.py +++ b/var/spack/repos/builtin/packages/distcc/package.py @@ -15,9 +15,12 @@ class Distcc(AutotoolsPackage): license("GPL-2.0-or-later") + version("3.4", sha256="37a34c9555498a1168fea026b292ab07e7bb394715d87d8403e0c33b16d2d008") version("3.3.5", sha256="13a4b3ce49dfc853a3de550f6ccac583413946b3a2fa778ddf503a9edc8059b0") version("3.3.3", sha256="b7f37d314704fbaf006d747514ff6e4d0d722102ef7d2aea132f97cf170f5169") + depends_on("c", type="build") # generated + depends_on("popt") depends_on("libiberty") diff --git a/var/spack/repos/builtin/packages/diy/package.py b/var/spack/repos/builtin/packages/diy/package.py index bca8f759cf4fc6..7b2311d37c0976 100644 --- a/var/spack/repos/builtin/packages/diy/package.py +++ b/var/spack/repos/builtin/packages/diy/package.py @@ -19,6 +19,8 @@ class Diy(CMakePackage): version("3.6.0", sha256="d12eb7dabe3a8a66cd406d34aabdb43c1ec178b7ed40cf1dff10016643bbf149") version("3.5.0", sha256="b3b5490441d521b6e9b33471c782948194bf95c7c3df3eb97bc5cf4530b91576") + depends_on("cxx", type="build") # generated + depends_on("mpi") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/dla-future-fortran/package.py b/var/spack/repos/builtin/packages/dla-future-fortran/package.py new file mode 100644 index 00000000000000..ea6a50c7425626 --- /dev/null +++ b/var/spack/repos/builtin/packages/dla-future-fortran/package.py @@ -0,0 +1,52 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +# dlaf-no-license-check +from spack.package import * + + +class DlaFutureFortran(CMakePackage): + """ + Fortran interface to the DLA-Future library. + """ + + homepage = "https://github.com/eth-cscs/DLA-Future-Fortran" + url = "https://github.com/eth-cscs/DLA-Future-Fortran/archive/v0.0.0.tar.gz" + git = "https://github.com/eth-cscs/DLA-Future-Fortran.git" + + maintainers("RMeli", "rasolca", "aurianer") + + license("BSD-3-Clause") + + version("main", branch="main") + version("0.2.0", sha256="7fd3e1779c111b35f0d2701a024398b4f6e8dea4af523b6c8617d28c0b7ae61a") + version("0.1.0", sha256="9fd8a105cbb2f3e1daf8a49910f98fce68ca0b954773dba98a91464cf2e7c1da") + + depends_on("fortran", type="build") # generated + + variant("shared", default=True, description="Build shared libraries.") + variant("test", default=False, description="Build tests.") + + generator("ninja") + depends_on("cmake@3.22:", type="build") + + depends_on("dla-future@0.4.1:0.5 +scalapack", when="@0.1.0") + depends_on("dla-future@0.6.0: +scalapack", when="@0.2.0:") + depends_on("dla-future +shared", when="+shared") + + depends_on("mpi", when="+test") + depends_on("py-fypp", when="+test", type="build") + + def cmake_args(self): + args = [] + + args.append(self.define_from_variant("BUILD_SHARED_LIBS", "shared")) + + if self.spec.satisfies("+test"): + args.append(self.define("DLAF_FORTRAN_BUILD_TESTING", True)) + # Tests run with 6 MPI ranks + args.append(self.define("MPIEXEC_MAX_NUMPROCS", 6)) + + return args diff --git a/var/spack/repos/builtin/packages/dla-future/package.py b/var/spack/repos/builtin/packages/dla-future/package.py index ef931e9927dece..935f726c6998f4 100644 --- a/var/spack/repos/builtin/packages/dla-future/package.py +++ b/var/spack/repos/builtin/packages/dla-future/package.py @@ -16,6 +16,9 @@ class DlaFuture(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") + version("0.6.0", sha256="85dfcee36ff28fa44da3134408c40ebd611bccff8a295982a7c78eaf982524d9") + version("0.5.0", sha256="f964ee2a96bb58b3f0ee4563ae65fcd136e409a7c0e66beda33f926fc9515a8e") + version("0.4.1", sha256="ba95f26475ad68da1f3a24d091dc1b925525e269e4c83c1eaf1d37d29b526666") version("0.4.0", sha256="34fd0da0d1a72b6981bed0bba029ba0947e0d0d99beb3e0aad0a478095c9527d") version("0.3.1", sha256="350a7fd216790182aa52639a3d574990a9d57843e02b92d87b854912f4812bfe") version("0.3.0", sha256="9887ac0b466ca03d704a8738bc89e68550ed33509578c576390e98e76b64911b") @@ -24,6 +27,9 @@ class DlaFuture(CMakePackage, CudaPackage, ROCmPackage): version("0.1.0", sha256="f7ffcde22edabb3dc24a624e2888f98829ee526da384cd752b2b271c731ca9b1") version("master", branch="master") + depends_on("c", type="build") + depends_on("cxx", type="build") + variant("shared", default=True, description="Build shared libraries.") variant( @@ -44,6 +50,18 @@ class DlaFuture(CMakePackage, CudaPackage, ROCmPackage): description="Build C API compatible with ScaLAPACK", ) + variant("mpi_gpu_aware", default=False, when="@0.5.0:", description="Use GPU-aware MPI.") + conflicts("+mpi_gpu_aware", when="~cuda ~rocm", msg="GPU-aware MPI requires +cuda or +rocm") + + variant( + "mpi_gpu_force_contiguous", + default=True, + when="@0.5.0: +mpi_gpu_aware", + description="Force GPU communication buffers to be contiguous before communicating.", + ) + + generator("ninja") + depends_on("cmake@3.22:", type="build") depends_on("pkgconfig", type="build") depends_on("doxygen", type="build", when="+doc") @@ -125,8 +143,8 @@ class DlaFuture(CMakePackage, CudaPackage, ROCmPackage): depends_on(f"umpire cuda_arch={arch}", when=f"cuda_arch={arch}") patch( - "https://github.com/eth-cscs/DLA-Future/pull/1063/commits/efc9c176a7a8c512b3f37d079dec8c25ac1b7389.patch?full_index=1", - sha256="7f382c872d89f22da1ad499e85ffe9881cc7404c8465e42877a210a09382e2ea", + "https://github.com/eth-cscs/DLA-Future/commit/efc9c176a7a8c512b3f37d079dec8c25ac1b7389.patch?full_index=1", + sha256="f40e4a734650f56c39379717a682d00d6400a7a102d90821542652824a8f64cd", when="@:0.3 %gcc@13:", ) # https://github.com/spack/spack/issues/41511 @@ -139,7 +157,7 @@ def cmake_args(self): args.append(self.define_from_variant("BUILD_SHARED_LIBS", "shared")) # BLAS/LAPACK - if spec["lapack"].name in INTEL_MATH_LIBRARIES: + if spec.version <= Version("0.4") and spec["lapack"].name in INTEL_MATH_LIBRARIES: mkl_provider = spec["lapack"].name vmap = { @@ -203,7 +221,7 @@ def cmake_args(self): ) ) else: - args.append(self.define("DLAF_WITH_MKL", False)) + args.append(self.define("DLAF_WITH_MKL", spec["lapack"].name in INTEL_MATH_LIBRARIES)) args.append( self.define( "LAPACK_LIBRARY", @@ -215,6 +233,13 @@ def cmake_args(self): args.append(self.define_from_variant("DLAF_WITH_SCALAPACK", "scalapack")) + args.append(self.define_from_variant("DLAF_WITH_MPI_GPU_AWARE", "mpi_gpu_aware")) + args.append( + self.define_from_variant( + "DLAF_WITH_MPI_GPU_FORCE_CONTIGUOUS", "mpi_gpu_force_contiguous" + ) + ) + # CUDA/HIP args.append(self.define_from_variant("DLAF_WITH_CUDA", "cuda")) args.append(self.define_from_variant("DLAF_WITH_HIP", "rocm")) diff --git a/var/spack/repos/builtin/packages/dlb/package.py b/var/spack/repos/builtin/packages/dlb/package.py index 2f4968019e2625..a1442e07c9d32c 100644 --- a/var/spack/repos/builtin/packages/dlb/package.py +++ b/var/spack/repos/builtin/packages/dlb/package.py @@ -31,6 +31,9 @@ class Dlb(AutotoolsPackage): version("3.0.1", sha256="04f8a7aa269d02fc8561d0a61d64786aa18850367ce4f95d086ca12ab3eb7d24") version("3.0", sha256="e3fc1d51e9ded6d4d40d37f8568da4c4d72d1a8996bdeff2dfbbd86c9b96e36a") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("debug", default=False, description="Builds additional debug libraries") variant("mpi", default=False, description="Builds MPI libraries") diff --git a/var/spack/repos/builtin/packages/dlib/package.py b/var/spack/repos/builtin/packages/dlib/package.py index 355d793656e9b8..26a2399112c93c 100644 --- a/var/spack/repos/builtin/packages/dlib/package.py +++ b/var/spack/repos/builtin/packages/dlib/package.py @@ -5,7 +5,7 @@ from spack.package import * -class Dlib(CMakePackage): +class Dlib(CMakePackage, CudaPackage): """toolkit containing machine learning algorithms and tools for creating complex software in C++ to solve real world problems""" @@ -13,28 +13,72 @@ class Dlib(CMakePackage): url = "https://github.com/davisking/dlib/archive/v19.19.tar.gz" git = "https://github.com/davisking/dlib" - maintainer = ["robertu94"] + maintainers("robertu94") license("BSL-1.0") version("master", branch="master") + version("19.24.4", sha256="d881911d68972d11563bb9db692b8fcea0ac1b3fd2e3f03fa0b94fde6c739e43") version("19.22", sha256="5f44b67f762691b92f3e41dcf9c95dd0f4525b59cacb478094e511fdacb5c096") version("19.21", sha256="116f52e58be04b47dab52057eaad4b5c4d5c3032d927fe23d55b0741fc4107a0") version("19.20", sha256="fc3f0986350e8e53aceadf95a71d2f413f1eedc469abda99a462cb528741d411") version("19.19", sha256="7af455bb422d3ae5ef369c51ee64e98fa68c39435b0fa23be2e5d593a3d45b87") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("ffmpeg", default=False, description="build ffmpeg image support") + variant("gif", default=False, description="build gif image support") + variant("gui", default=False, description="build dlib graphical support") + variant("jpeg", default=False, description="build jpeg image support") + variant("jxl", default=False, description="build jxl image support") + variant("png", default=False, description="build png image support") variant("shared", default=True, description="build the shared libraries") + variant("sqlite", default=False, description="build sqlite3 support") + variant("webp", default=False, description="build webp image support") + variant("blas", default=True, description="build blas image support") + variant("lapack", default=True, description="build lapack image support") depends_on("zlib-api") - depends_on("libpng") - depends_on("libjpeg") - depends_on("blas") - depends_on("lapack") - depends_on("libsm") - depends_on("libx11") + depends_on("ffmpeg", when="+ffmpeg") + depends_on("libjxl@0.10.2:", when="+jxl") + depends_on("giflib", when="+gif") + depends_on("libpng", when="+png") + depends_on("libwebp", when="+webp") + depends_on("libjpeg", when="+jpeg") + depends_on("sqlite", when="+sqlite") + depends_on("blas", when="+blas") + depends_on("lapack", when="+lapack") + depends_on("libsm", when="+gui") + depends_on("libx11", when="+gui") + depends_on("cuda@7.5:", when="+cuda") + depends_on("cudnn", when="+cuda") + # depends on the deprecated FindCUDA module dependency as of 19.24.4 + # when cuda is enabled + depends_on("cmake@:3.26", when="+cuda") def cmake_args(self): - args = [] - if "+shared" in self.spec: - args.append("-DBUILD_SHARED_LIBS=ON") + spec = self.spec + args = [ + self.define_from_variant("DLIB_USE_BLAS", "blas"), + self.define_from_variant("DLIB_USE_LAPACK", "lapack"), + self.define_from_variant("DLIB_USE_FFMPEG", "ffmpeg"), + self.define_from_variant("DLIB_GIF_SUPPORT", "gif"), + self.define("DLIB_NO_GUI_SUPPORT", spec.satisfies("~gui")), + self.define_from_variant("DLIB_JPEG_SUPPORT", "jpeg"), + self.define_from_variant("DLIB_JXL_SUPPORT", "jxl"), + self.define_from_variant("DLIB_PNG_SUPPORT", "png"), + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + self.define_from_variant("DLIB_LINK_WITH_SQLITE3", "sqlite"), + self.define_from_variant("DLIB_WEBP_SUPPORT", "webp"), + self.define_from_variant("DLIB_USE_CUDA", "cuda"), + ] + if spec.satisfies("+cuda"): + args.append( + self.define( + "DLIB_USE_CUDA_COMPUTE_CAPABILITIES", self.spec.variants["cuda_arch"].value + ) + ) + return args diff --git a/var/spack/repos/builtin/packages/dlpack/package.py b/var/spack/repos/builtin/packages/dlpack/package.py index eadfcf781ca8d2..efe5c6b4f5fed4 100644 --- a/var/spack/repos/builtin/packages/dlpack/package.py +++ b/var/spack/repos/builtin/packages/dlpack/package.py @@ -24,5 +24,8 @@ class Dlpack(Package): version("0.2", sha256="419f76ef723d21b72b704b2c4bf718dcd9d2ecd44cd28c8a71798389b7932ae5") version("0.1", sha256="c69b06bfe03711e9d9d3f4d3f307d6dfd7e21d4864a053cca26296d5d05c175c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): install_tree("include", prefix.include) diff --git a/var/spack/repos/builtin/packages/dmd/package.py b/var/spack/repos/builtin/packages/dmd/package.py index d6672d6baae778..9c7d8e211d4e40 100644 --- a/var/spack/repos/builtin/packages/dmd/package.py +++ b/var/spack/repos/builtin/packages/dmd/package.py @@ -19,6 +19,9 @@ class Dmd(MakefilePackage): version("2.081.1", sha256="14f3aafe1c93c86646aaeb3ed7361a5fc5a24374cf25c8848c81942bfd9fae1a") version("2.081.0", sha256="29b9882ed424b744df83ac73182d4ae952251029ebd16117d18f9cc1e83542e2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("openssl") depends_on("curl") diff --git a/var/spack/repos/builtin/packages/dmidecode/package.py b/var/spack/repos/builtin/packages/dmidecode/package.py index 37f964655e66b9..1eb0db8b6bb453 100644 --- a/var/spack/repos/builtin/packages/dmidecode/package.py +++ b/var/spack/repos/builtin/packages/dmidecode/package.py @@ -17,6 +17,8 @@ class Dmidecode(MakefilePackage): version("3-2", sha256="489d840d076785617a432649603aafa6358327f4376694c062b69dfa359bcc2d") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("dmidecode", prefix.bin) diff --git a/var/spack/repos/builtin/packages/dmlc-core/package.py b/var/spack/repos/builtin/packages/dmlc-core/package.py index 60cc32da43ecd3..18f443e9e7e339 100644 --- a/var/spack/repos/builtin/packages/dmlc-core/package.py +++ b/var/spack/repos/builtin/packages/dmlc-core/package.py @@ -19,6 +19,8 @@ class DmlcCore(CMakePackage): version("master") version("20170508", commit="a6c5701219e635fea808d264aefc5b03c3aec314") + depends_on("cxx", type="build") # generated + variant("openmp", default=False, description="Enable OpenMP support") patch("cmake.patch") diff --git a/var/spack/repos/builtin/packages/dmtcp/package.py b/var/spack/repos/builtin/packages/dmtcp/package.py index ee31dcadc35ed3..282038b6b71105 100644 --- a/var/spack/repos/builtin/packages/dmtcp/package.py +++ b/var/spack/repos/builtin/packages/dmtcp/package.py @@ -22,4 +22,7 @@ class Dmtcp(AutotoolsPackage): version("3.0.0", sha256="2c7e95e1dbc55db33433bfee48a65f274298e98f246a36ab6dad1e0694750d37") version("2.6.0", sha256="3ed62a86dd0cb9c828b93ee8c7c852d6f9c96a0efa48bcfe867521adf7bced68") version("2.5.2", sha256="0e3e5e15bd401b7b6937f2b678cd7d6a252eab0a143d5740b89cc3bebb4282be") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated patch("for_aarch64.patch", when="@2.6.0 target=aarch64:") diff --git a/var/spack/repos/builtin/packages/dnsmap/package.py b/var/spack/repos/builtin/packages/dnsmap/package.py index f5e8ca90d02e9d..8b15753a5cd769 100644 --- a/var/spack/repos/builtin/packages/dnsmap/package.py +++ b/var/spack/repos/builtin/packages/dnsmap/package.py @@ -17,6 +17,8 @@ class Dnsmap(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("dnsmap", prefix.bin) diff --git a/var/spack/repos/builtin/packages/dnsmasq/package.py b/var/spack/repos/builtin/packages/dnsmasq/package.py index 4149405f2f7e4c..0c0108320e2771 100644 --- a/var/spack/repos/builtin/packages/dnsmasq/package.py +++ b/var/spack/repos/builtin/packages/dnsmasq/package.py @@ -14,6 +14,7 @@ class Dnsmasq(MakefilePackage): license("GPL-2.0-or-later") + version("2.90", sha256="8f6666b542403b5ee7ccce66ea73a4a51cf19dd49392aaccd37231a2c51b303b") version("2.89", sha256="8651373d000cae23776256e83dcaa6723dee72c06a39362700344e0c12c4e7e4") version("2.81", sha256="3c28c68c6c2967c3a96e9b432c0c046a5df17a426d3a43cffe9e693cf05804d0") version("2.80", sha256="9e4a58f816ce0033ce383c549b7d4058ad9b823968d352d2b76614f83ea39adc") @@ -28,6 +29,8 @@ class Dnsmasq(MakefilePackage): version("2.71", sha256="7d8c64f66a396442e01b639df3ea6b4e02ba88cbe206c80be8de68b6841634c4") version("2.70", sha256="8eb7bf53688d6aaede5c90cfd2afcce04803a4efbddfbeecc6297180749e98af") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("./src/dnsmasq", prefix.bin) diff --git a/var/spack/repos/builtin/packages/dnstop/package.py b/var/spack/repos/builtin/packages/dnstop/package.py index 088eb6aadf2db2..2ea5086d3f002a 100644 --- a/var/spack/repos/builtin/packages/dnstop/package.py +++ b/var/spack/repos/builtin/packages/dnstop/package.py @@ -16,6 +16,8 @@ class Dnstop(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("libpcap") depends_on("ncurses") diff --git a/var/spack/repos/builtin/packages/dnstracer/package.py b/var/spack/repos/builtin/packages/dnstracer/package.py index c88435d527ff74..e393f959ee164f 100644 --- a/var/spack/repos/builtin/packages/dnstracer/package.py +++ b/var/spack/repos/builtin/packages/dnstracer/package.py @@ -19,6 +19,8 @@ class Dnstracer(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): configure = Executable("./configure.sh") configure("--prefix={0}".format(prefix)) diff --git a/var/spack/repos/builtin/packages/docbook-xml/package.py b/var/spack/repos/builtin/packages/docbook-xml/package.py index cc0c8027481e92..d299dbabe64f6d 100644 --- a/var/spack/repos/builtin/packages/docbook-xml/package.py +++ b/var/spack/repos/builtin/packages/docbook-xml/package.py @@ -44,16 +44,16 @@ def config_docbook(self): "--noout", "--add", "public", - "-//OASIS//DTD DocBook XML CALS Table Model " "V{0}//EN".format(version), - "file://{0}/calstblx.dtd".format(prefix), + f"-//OASIS//DTD DocBook XML CALS Table Model V{version}//EN", + f"file://{prefix}/calstblx.dtd", docbook, ) xmlcatalog( "--noout", "--add", "public", - "-//OASIS//DTD DocBook XML V{0}//EN".format(version), - "file://{0}/docbookx.dtd".format(prefix), + f"-//OASIS//DTD DocBook XML V{version}//EN", + f"file://{prefix}/docbookx.dtd", docbook, ) xmlcatalog( @@ -61,15 +61,15 @@ def config_docbook(self): "--add", "public", "-//OASIS//DTD XML Exchange Table Model 19990315//EN", - "file://{0}/soextblx.dtd".format(prefix), + f"file://{prefix}/soextblx.dtd", docbook, ) xmlcatalog( "--noout", "--add", "public", - "-//OASIS//ENTITIES DocBook XML Character Entities " "V{0}//EN".format(version), - "file://{0}/dbcentx.mod".format(prefix), + f"-//OASIS//ENTITIES DocBook XML Character Entities V{version}//EN", + f"file://{prefix}/dbcentx.mod", docbook, ) xmlcatalog( @@ -78,39 +78,39 @@ def config_docbook(self): "public", "-//OASIS//ENTITIES DocBook XML Additional General Entities " "V{0}//EN".format(version), - "file://{0}/dbgenent.mod".format(prefix), + f"file://{prefix}/dbgenent.mod", docbook, ) xmlcatalog( "--noout", "--add", "public", - "-//OASIS//ELEMENTS DocBook XML Document Hierarchy " "V{0}//EN".format(version), - "file://{0}/dbhierx.mod".format(prefix), + f"-//OASIS//ELEMENTS DocBook XML Document Hierarchy V{version}//EN", + f"file://{prefix}/dbhierx.mod", docbook, ) xmlcatalog( "--noout", "--add", "public", - "-//OASIS//ENTITIES DocBook XML Notations " "V{0}//EN".format(version), - "file://{0}/dbnotnx.mod".format(prefix), + f"-//OASIS//ENTITIES DocBook XML Notations V{version}//EN", + f"file://{prefix}/dbnotnx.mod", docbook, ) xmlcatalog( "--noout", "--add", "public", - "-//OASIS//ELEMENTS DocBook XML Information Pool " "V{0}//EN".format(version), - "file://{0}/dbpoolx.mod".format(prefix), + f"-//OASIS//ELEMENTS DocBook XML Information Pool V{version}//EN", + f"file://{prefix}/dbpoolx.mod", docbook, ) xmlcatalog( "--noout", "--add", "public", - "-//OASIS//ELEMENTS DocBook XML HTML Tables " "V{0}//EN".format(version), - "file://{0}/htmltblx.mod".format(prefix), + f"-//OASIS//ELEMENTS DocBook XML HTML Tables V{version}//EN", + f"file://{prefix}/htmltblx.mod", docbook, ) xmlcatalog( @@ -118,7 +118,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Added Math Symbols: Arrow " "Relations//EN", - "file://{0}/isoamsa.ent".format(ent_dir), + f"file://{ent_dir}/isoamsa.ent", docbook, ) xmlcatalog( @@ -126,7 +126,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Added Math Symbols: Binary " "Operators//EN", - "file://{0}/isoamsb.ent".format(ent_dir), + f"file://{ent_dir}/isoamsb.ent", docbook, ) xmlcatalog( @@ -134,7 +134,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Added Math Symbols: Delimiters//EN", - "file://{0}/isoamsc.ent".format(ent_dir), + f"file://{ent_dir}/isoamsc.ent", docbook, ) xmlcatalog( @@ -142,7 +142,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Added Math Symbols: " "Negated Relations//EN", - "file://{0}/isoamsn.ent".format(ent_dir), + f"file://{ent_dir}/isoamsn.ent", docbook, ) xmlcatalog( @@ -150,7 +150,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Added Math Symbols: Ordinary//EN", - "file://{0}/isoamso.ent".format(ent_dir), + f"file://{ent_dir}/isoamso.ent", docbook, ) xmlcatalog( @@ -158,7 +158,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Added Math Symbols: Relations//EN", - "file://{0}/isoamsr.ent".format(ent_dir), + f"file://{ent_dir}/isoamsr.ent", docbook, ) xmlcatalog( @@ -166,7 +166,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Box and Line Drawing//EN", - "file://{0}/isobox.ent".format(ent_dir), + f"file://{ent_dir}/isobox.ent", docbook, ) xmlcatalog( @@ -174,7 +174,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Russian Cyrillic//EN", - "file://{0}/isocyr1.ent".format(ent_dir), + f"file://{ent_dir}/isocyr1.ent", docbook, ) xmlcatalog( @@ -182,7 +182,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Non-Russian Cyrillic//EN", - "file://{0}/isocyr2.ent".format(ent_dir), + f"file://{ent_dir}/isocyr2.ent", docbook, ) xmlcatalog( @@ -190,7 +190,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Diacritical Marks//EN", - "file://{0}/isodia.ent".format(ent_dir), + f"file://{ent_dir}/isodia.ent", docbook, ) xmlcatalog( @@ -198,7 +198,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Greek Letters//EN", - "file://{0}/isogrk1.ent".format(ent_dir), + f"file://{ent_dir}/isogrk1.ent", docbook, ) xmlcatalog( @@ -206,7 +206,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Monotoniko Greek//EN", - "file://{0}/isogrk2.ent".format(ent_dir), + f"file://{ent_dir}/isogrk2.ent", docbook, ) xmlcatalog( @@ -214,7 +214,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Greek Symbols//EN", - "file://{0}/isogrk3.ent".format(ent_dir), + f"file://{ent_dir}/isogrk3.ent", docbook, ) xmlcatalog( @@ -222,7 +222,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Alternative Greek Symbols//EN", - "file://{0}/isogrk4.ent".format(ent_dir), + f"file://{ent_dir}/isogrk4.ent", docbook, ) xmlcatalog( @@ -230,7 +230,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Added Latin 1//EN", - "file://{0}/isolat1.ent".format(ent_dir), + f"file://{ent_dir}/isolat1.ent", docbook, ) xmlcatalog( @@ -238,7 +238,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Added Latin 2//EN", - "file://{0}/isolat2.ent".format(ent_dir), + f"file://{ent_dir}/isolat2.ent", docbook, ) xmlcatalog( @@ -246,7 +246,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Numeric and Special Graphic//EN", - "file://{0}/isonum.ent".format(ent_dir), + f"file://{ent_dir}/isonum.ent", docbook, ) xmlcatalog( @@ -254,7 +254,7 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES Publishing//EN", - "file://{0}/isopub.ent".format(ent_dir), + f"file://{ent_dir}/isopub.ent", docbook, ) xmlcatalog( @@ -262,23 +262,23 @@ def config_docbook(self): "--add", "public", "ISO 8879:1986//ENTITIES General Technical//EN", - "file://{0}/isotech.ent".format(ent_dir), + f"file://{ent_dir}/isotech.ent", docbook, ) xmlcatalog( "--noout", "--add", "rewriteSystem", - "https://www.oasis-open.org/docbook/xml/{0}".format(version), - "file://{0}".format(prefix), + f"https://www.oasis-open.org/docbook/xml/{version}", + f"file://{prefix}", docbook, ) xmlcatalog( "--noout", "--add", "rewriteURI", - "https://www.oasis-open.org/docbook/xml/{0}".format(version), - "file://{0}".format(prefix), + f"https://www.oasis-open.org/docbook/xml/{version}", + f"file://{prefix}", docbook, ) xmlcatalog( @@ -286,7 +286,7 @@ def config_docbook(self): "--add", "rewriteSystem", "https://www.oasis-open.org/docbook/xml/current", - "file://{0}".format(prefix), + f"file://{prefix}", docbook, ) xmlcatalog( @@ -294,7 +294,7 @@ def config_docbook(self): "--add", "rewriteURI", "https://www.oasis-open.org/docbook/xml/current", - "file://{0}".format(prefix), + f"file://{prefix}", docbook, ) @@ -305,7 +305,7 @@ def config_docbook(self): "--add", "delegatePublic", "-//OASIS//ENTITIES DocBook XML", - "file://{0}".format(docbook), + f"file://{docbook}", catalog, ) xmlcatalog( @@ -313,23 +313,18 @@ def config_docbook(self): "--add", "delegatePublic", "-//OASIS//DTD DocBook XML", - "file://{0}".format(docbook), + f"file://{docbook}", catalog, ) xmlcatalog( - "--noout", - "--add", - "delegatePublic", - "ISO 8879:1986", - "file://{0}".format(docbook), - catalog, + "--noout", "--add", "delegatePublic", "ISO 8879:1986", f"file://{docbook}", catalog ) xmlcatalog( "--noout", "--add", "delegateSystem", "https://www.oasis-open.org/docbook/", - "file://{0}".format(docbook), + f"file://{docbook}", catalog, ) xmlcatalog( @@ -337,7 +332,7 @@ def config_docbook(self): "--add", "delegateURI", "https://www.oasis-open.org/docbook/", - "file://{0}".format(docbook), + f"file://{docbook}", catalog, ) @@ -348,40 +343,40 @@ def config_docbook(self): "--noout", "--add", "public", - "-//OASIS//DTD DocBook XML V{0}//EN".format(dtversion), - "http://www.oasis-open.org/docbook/xml/{0}/docbookx.dtd".format(dtversion), + f"-//OASIS//DTD DocBook XML V{dtversion}//EN", + f"http://www.oasis-open.org/docbook/xml/{dtversion}/docbookx.dtd", docbook, ) xmlcatalog( "--noout", "--add", "rewriteSystem", - "http://www.oasis-open.org/docbook/xml/{0}".format(dtversion), - "file://{0}".format(prefix), + f"http://www.oasis-open.org/docbook/xml/{dtversion}", + f"file://{prefix}", docbook, ) xmlcatalog( "--noout", "--add", "rewriteURI", - "http://www.oasis-open.org/docbook/xml/{0}".format(dtversion), - "file://{0}".format(prefix), + f"http://www.oasis-open.org/docbook/xml/{dtversion}", + f"file://{prefix}", docbook, ) xmlcatalog( "--noout", "--add", "delegateSystem", - "http://www.oasis-open.org/docbook/xml/{0}".format(dtversion), - "file://{0}".format(docbook), + f"http://www.oasis-open.org/docbook/xml/{dtversion}", + f"file://{docbook}", catalog, ) xmlcatalog( "--noout", "--add", "delegateURI", - "http://www.oasis-open.org/docbook/xml/{0}".format(dtversion), - "file://{0}".format(docbook), + f"http://www.oasis-open.org/docbook/xml/{dtversion}", + f"file://{docbook}", catalog, ) diff --git a/var/spack/repos/builtin/packages/dorado/package.py b/var/spack/repos/builtin/packages/dorado/package.py index 70e3c49879bcb7..a56d355c625dc8 100644 --- a/var/spack/repos/builtin/packages/dorado/package.py +++ b/var/spack/repos/builtin/packages/dorado/package.py @@ -16,8 +16,12 @@ class Dorado(CMakePackage, CudaPackage): maintainers("snehring") + version("0.5.3", commit="d9af343c0097e0e60503231e036d69e6eda2f19a", submodules=True) version("0.5.1", commit="a7fb3e3d4afa7a11cb52422e7eecb1a2cdb7860f", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("git", type="build") @@ -30,6 +34,9 @@ class Dorado(CMakePackage, CudaPackage): depends_on("libdeflate") depends_on("zlib-api") + conflicts("%gcc@:8", msg="Dorado requires at least gcc@9 to compile.") + conflicts("%gcc@13:", msg="Dorado will not build with gcc@13 and newer.") + patch("cmake-htslib.patch") def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/dorian3d-dlib/package.py b/var/spack/repos/builtin/packages/dorian3d-dlib/package.py index 74951a4a921e7e..d68366dd08f85d 100644 --- a/var/spack/repos/builtin/packages/dorian3d-dlib/package.py +++ b/var/spack/repos/builtin/packages/dorian3d-dlib/package.py @@ -17,5 +17,7 @@ class Dorian3dDlib(CMakePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.0:", type="build") depends_on("opencv+calib3d+features2d+highgui+imgproc+imgcodecs+flann") diff --git a/var/spack/repos/builtin/packages/dos2unix/package.py b/var/spack/repos/builtin/packages/dos2unix/package.py index 29465bff033dc0..cc90aae1b7ed9e 100644 --- a/var/spack/repos/builtin/packages/dos2unix/package.py +++ b/var/spack/repos/builtin/packages/dos2unix/package.py @@ -22,6 +22,8 @@ class Dos2unix(MakefilePackage): version("7.4.2", sha256="6035c58df6ea2832e868b599dfa0d60ad41ca3ecc8aa27822c4b7a9789d3ae01") version("7.3.4", sha256="8ccda7bbc5a2f903dafd95900abb5bf5e77a769b572ef25150fde4056c5f30c5") + depends_on("c", type="build") # generated + depends_on("gettext") executables = [r"^dos2unix$"] diff --git a/var/spack/repos/builtin/packages/dosfstools/package.py b/var/spack/repos/builtin/packages/dosfstools/package.py index 6d89720b87d2f6..db158d6e79caaf 100644 --- a/var/spack/repos/builtin/packages/dosfstools/package.py +++ b/var/spack/repos/builtin/packages/dosfstools/package.py @@ -18,6 +18,8 @@ class Dosfstools(AutotoolsPackage): version("4.1", sha256="8ff9c2dcc01551fe9de8888cb41eb1051fd58bdf1ab3a93d3d88916f0a4ffd1b") version("4.0", sha256="77975e289e695cb8c984a3c0a15a3bbf3af90be83c26983d43abcde9ec48eea5") + depends_on("c", type="build") # generated + depends_on("automake", type="build") depends_on("autoconf", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/dotconf/package.py b/var/spack/repos/builtin/packages/dotconf/package.py index 43ddf559246700..d0d30b9ba308f3 100644 --- a/var/spack/repos/builtin/packages/dotconf/package.py +++ b/var/spack/repos/builtin/packages/dotconf/package.py @@ -16,6 +16,8 @@ class Dotconf(AutotoolsPackage): version("1.3", sha256="7f1ecf40de1ad002a065a321582ed34f8c14242309c3547ad59710ae3c805653") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/dotnet-core-sdk/package.py b/var/spack/repos/builtin/packages/dotnet-core-sdk/package.py index 93f9e0c91f6067..6f74fe3d5dc72c 100644 --- a/var/spack/repos/builtin/packages/dotnet-core-sdk/package.py +++ b/var/spack/repos/builtin/packages/dotnet-core-sdk/package.py @@ -18,11 +18,23 @@ class DotnetCoreSdk(Package): license("MIT") if platform.system() == "Linux" and platform.machine() == "x86_64": + version( + "8.0.4", + url="https://download.visualstudio.microsoft.com/download/pr/0a1b3cbd-b4af-4d0d-9ed7-0054f0e200b4/4bcc533c66379caaa91770236667aacb/dotnet-sdk-8.0.204-linux-x64.tar.gz", + sha256="0ec834dc0f11a994057cd05d84c6250db726457f2fe308091d50543a5285dd15", + preferred=True, + ) + + version( + "7.0.18", + url="https://download.visualstudio.microsoft.com/download/pr/a256265b-0ec6-4b63-b943-bc27bcfc98c0/47c8bbd54d7f6dbfe0ca4985c410282e/dotnet-sdk-7.0.408-linux-x64.tar.gz", + sha256="e72beb77f59d5c55de46f52cce01b68f244e28058f646f1ea4ecf8a35b177e58", + ) + version( "6.0.25", url="https://download.visualstudio.microsoft.com/download/pr/1cac4d08-3025-4c00-972d-5c7ea446d1d7/a83bc5cbedf8b90495802ccfedaeb2e6/dotnet-sdk-6.0.417-linux-x64.tar.gz", sha256="1b7c5ea04ccb817e1a411c9e1f89d7a4e54c0842b01b457e141bbc254ce97ba2", - preferred=True, ) version( @@ -53,18 +65,30 @@ class DotnetCoreSdk(Package): deprecated=True, ) elif platform.system() == "Linux" and platform.machine() == "aarch64": + version( + "8.0.4", + url="https://download.visualstudio.microsoft.com/download/pr/1e449990-2934-47ee-97fb-b78f0e587c98/1c92c33593932f7a86efa5aff18960ed/dotnet-sdk-8.0.204-linux-arm64.tar.gz", + sha256="c6ecb0c1897e217e8d20153a0119276ee1091c0600aecf2aca8e674c3575942e", + preferred=True, + ) + + version( + "7.0.18", + url="https://download.visualstudio.microsoft.com/download/pr/460f951f-0944-442b-8474-555e20394ca8/5fcf6b1845d87d772f919737b3dd5f55/dotnet-sdk-7.0.408-linux-arm64.tar.gz", + sha256="dd9a8794561a8b9c658a2ba832328449a34b0dd0cdcb79e31d6efc2d0c9a8efc", + ) + version( "6.0.25", url="https://download.visualstudio.microsoft.com/download/pr/03972b46-ddcd-4529-b8e0-df5c1264cd98/285a1f545020e3ddc47d15cf95ca7a33/dotnet-sdk-6.0.417-linux-arm64.tar.gz", sha256="c071e936442b90b80a941ab177b8c7851bc5377cf842cc1e61922b3d7fefeb0e", - preferred=True, ) variant("telemetry", default=False, description="allow collection of telemetry data") - def setup_build_environment(self, env): - if "-telemetry" in self.spec: - env.set("DOTNET_CLI_TELEMETRY_OPTOUT", 1) + def setup_run_environment(self, env): + if "~telemetry" in self.spec: + env.set("DOTNET_CLI_TELEMETRY_OPTOUT", "1") def install(self, spec, prefix): mkdirp("bin") diff --git a/var/spack/repos/builtin/packages/double-batched-fft-library/package.py b/var/spack/repos/builtin/packages/double-batched-fft-library/package.py index c420275d544201..168e51eb91aeeb 100644 --- a/var/spack/repos/builtin/packages/double-batched-fft-library/package.py +++ b/var/spack/repos/builtin/packages/double-batched-fft-library/package.py @@ -23,10 +23,13 @@ class DoubleBatchedFftLibrary(CMakePackage): version("main", branch="main") version("develop", branch="develop") + version("0.5.1", sha256="3651b982b6b5649d2bf95a3391a0a28d6637c51c642379d9708de88ad8d45f61") version("0.5.0", sha256="cbd2ecf039cc40830e57a8af8295abf2083ce3b1a333279a8c17762f41131fff") version("0.4.0", sha256="f3518012b632c92c2a933d70a040d6b0eee2d631ab6b1881a192a8d1624f242d") version("0.3.6", sha256="ff163251d77d3c686563141e871c702bf4997c0302d53616add55d6cf9b02d28") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Shared library") variant("sycl", default=True, description="Build bbfft-sycl") variant("level-zero", default=True, when="~sycl", description="Build bbfft-level-zero") @@ -41,10 +44,8 @@ class DoubleBatchedFftLibrary(CMakePackage): def cmake_args(self): cxx_compiler = os.path.basename(self.compiler.cxx) - if self.spec.satisfies("+sycl") and cxx_compiler not in ["icpx", "dpcpp"]: - raise InstallError( - "The Double-Batched FFT Library requires the oneapi DPC++/C++ Compiler" - ) + if self.spec.satisfies("+sycl") and cxx_compiler not in ["icpx"]: + raise InstallError("The Double-Batched FFT Library requires the oneapi C++ Compiler") return [ self.define_from_variant("BUILD_SHARED_LIBS", "shared"), diff --git a/var/spack/repos/builtin/packages/doxygen/package.py b/var/spack/repos/builtin/packages/doxygen/package.py index e6c099cb57f821..50e16c3bfdadc2 100644 --- a/var/spack/repos/builtin/packages/doxygen/package.py +++ b/var/spack/repos/builtin/packages/doxygen/package.py @@ -20,6 +20,8 @@ class Doxygen(CMakePackage): license("GPL-2.0-or-later") + version("1.11.0", sha256="1fea49c69e51fec3dd2599947f6d48d9b1268bd5115b1bb08dffefc1fd5d19ee") + version("1.10.0", sha256="795692a53136ca9bb9a6cd72656968af7858a78be7d6d011e12ab1dce6b9533c") version("1.9.8", sha256="77371e8a58d22d5e03c52729844d1043e9cbf8d0005ec5112ffa4c8f509ddde8") version("1.9.7", sha256="691777992a7240ed1f822a5c2ff2c4273b57c1cf9fc143553d87f91a0c5970ee") version("1.9.6", sha256="2a3ee47f7276b759f74bac7614c05a1296a5b028d3f6a79a88e4c213db78e7dc") @@ -39,6 +41,10 @@ class Doxygen(CMakePackage): version("1.8.11", sha256="86263cb4ce1caa41937465f73f644651bd73128d685d35f18dea3046c7c42c12") version("1.8.10", sha256="0ac08900e5dc3ab5b65976991bf197623a7cc33ec3b32fe29360fb55d0c16b60") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # graphviz appears to be a run-time optional dependency variant("graphviz", default=False, description="Build with dot command support from Graphviz.") @@ -76,6 +82,11 @@ def determine_variants(cls, exes, version_str): return variants depends_on("cmake@2.8.12:", type="build") + depends_on("cmake@3.2:", type="build", when="@1.8.16:") + depends_on("cmake@3.3:", type="build", when="@1.8.18:") + depends_on("cmake@3.12:", type="build", when="@1.9.8:") + depends_on("cmake@3.14:", type="build", when="@1.10:") + depends_on("python", type="build") # 2 or 3 OK; used in CMake build depends_on("iconv") depends_on("flex", type="build") @@ -85,6 +96,10 @@ def determine_variants(cls, exes, version_str): depends_on("flex@2.5.39", type="build", when="@1.8.10") depends_on("bison@2.7:", type="build", when="@1.8.10:") + # originally bundled dependencies + depends_on("spdlog", when="@1.9.8:") + depends_on("sqlite", when="@1.10:") + # optional dependencies depends_on("graphviz", when="+graphviz", type="run") depends_on("mscgen", when="+mscgen", type="run") @@ -108,11 +123,18 @@ def determine_variants(cls, exes, version_str): when="@1.9.4 %gcc@12:", ) + # https://github.com/doxygen/doxygen/pull/10896: use correct option name with system sqlite3 + patch( + "https://github.com/doxygen/doxygen/commit/83de58c5f4f685a129127c2501f4fccd9557f6c4.patch?full_index=1", + sha256="8b46b763b3f0a2726f765141cbfa3eb6efd746531a4d689531e42ff56fc334e2", + when="@1.10:1.11.0", + ) + # Some GCC 7.x get stuck in an infinite loop conflicts("%gcc@7.0:7.9", when="@1.9:") def patch(self): - if self.spec["iconv"].name == "libc": + if self.spec["iconv"].name != "libiconv": return # On Linux systems, iconv is provided by libc. Since CMake finds the # symbol in libc, it does not look for libiconv, which leads to linker @@ -124,3 +146,9 @@ def patch(self): join_path("cmake", "FindIconv.cmake"), string=True, ) + + def cmake_args(self): + return [ + self.define("use_sys_spdlog", self.spec.satisfies("@1.9.8:")), + self.define("use_sys_sqlite3", self.spec.satisfies("@1.10:")), + ] diff --git a/var/spack/repos/builtin/packages/dpcpp/package.py b/var/spack/repos/builtin/packages/dpcpp/package.py deleted file mode 100644 index 4fa5a00abb8ecd..00000000000000 --- a/var/spack/repos/builtin/packages/dpcpp/package.py +++ /dev/null @@ -1,166 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - - -import os - -from spack.package import * - - -class Dpcpp(CMakePackage): - """Data Parallel C++ compiler: Intel's implementation of SYCL programming model""" - - homepage = "https://intel.github.io/llvm-docs/" - git = "https://github.com/intel/llvm.git" - - license("Apache-2.0") - - version("develop", branch="sycl") - version("2021.09", commit="bd68232bb96386bf7649345c0557ba520e73c02d") - version("2021.12", commit="27f59d8906fcc8aece7ff6aa570ccdee52168c2d") - - maintainers("ravil-mobile") - variant("cuda", default=False, description="switch from OpenCL to CUDA") - variant("rocm", default=False, description="switch from OpenCL to ROCm") - variant( - "rocm-platform", - default="AMD", - values=("AMD", "NVIDIA"), - multi=False, - description="choose ROCm backend", - ) - variant("openmp", default=False, description="build with OpenMP without target offloading") - variant("esimd-cpu", default=False, description="build with ESIMD_CPU support") - variant("assertions", default=False, description="build with assertions") - variant("docs", default=False, description="build Doxygen documentation") - variant("werror", default=False, description="treat warnings as errors") - variant("shared", default=False, description="build shared libraries") - variant("remangle_libclc", default=True, description="remangle libclc gen. variants") - variant("lld", default=False, description="use LLD linker for build") - - depends_on("cmake@3.16.2:", type="build") - depends_on("ninja@1.10.0:", type="build") - - depends_on("cuda@10.2.0:11.4.999", when="+cuda") - - # NOTE: AMD HIP needs to be tested; it will be done in the next update - # depends_on('cuda@10.2.0:10.2.999', when='rocm-platform=NVIDIA', type='build') - # depends_on('hip@4.0.0:', when='+rocm', type='build') - - root_cmakelists_dir = "llvm" - - def cmake_args(self): - llvm_external_projects = "sycl;llvm-spirv;opencl;libdevice;xpti;xptifw" - - if "+openmp" in self.spec: - llvm_external_projects += ";openmp" - - sycl_dir = os.path.join(self.stage.source_path, "sycl") - spirv_dir = os.path.join(self.stage.source_path, "llvm-spirv") - xpti_dir = os.path.join(self.stage.source_path, "xpti") - xptifw_dir = os.path.join(self.stage.source_path, "xptifw") - libdevice_dir = os.path.join(self.stage.source_path, "libdevice") - llvm_enable_projects = "clang;" + llvm_external_projects - libclc_targets_to_build = "" - sycl_build_pi_rocm_platform = self.spec.variants["rocm-platform"].value - - if self.spec.satisfies("target=x86_64:"): - llvm_targets_to_build = "X86" - elif self.spec.satisfies("target=aarch64:"): - llvm_targets_to_build = "ARM;AArch64" - else: - raise InstallError( - "target is not supported. " "This package only works on x86_64 or aarch64" - ) - - is_cuda = "+cuda" in self.spec - is_rocm = "+rocm" in self.spec - - if is_cuda or is_rocm: - llvm_enable_projects += ";libclc" - - if is_cuda: - llvm_targets_to_build += ";NVPTX" - libclc_targets_to_build = "nvptx64--;nvptx64--nvidiacl" - - if is_rocm: - if sycl_build_pi_rocm_platform == "AMD": - llvm_targets_to_build += ";AMDGPU" - libclc_targets_to_build += ";amdgcn--;amdgcn--amdhsa" - elif sycl_build_pi_rocm_platform and not is_cuda: - llvm_targets_to_build += ";NVPTX" - libclc_targets_to_build += ";nvptx64--;nvptx64--nvidiacl" - - args = [ - self.define_from_variant("LLVM_ENABLE_ASSERTIONS", "assertions"), - self.define("LLVM_TARGETS_TO_BUILD", llvm_targets_to_build), - self.define("LLVM_EXTERNAL_PROJECTS", llvm_external_projects), - self.define("LLVM_EXTERNAL_SYCL_SOURCE_DIR", sycl_dir), - self.define("LLVM_EXTERNAL_LLVM_SPIRV_SOURCE_DIR", spirv_dir), - self.define("LLVM_EXTERNAL_XPTI_SOURCE_DIR", xpti_dir), - self.define("XPTI_SOURCE_DIR", xpti_dir), - self.define("LLVM_EXTERNAL_XPTIFW_SOURCE_DIR", xptifw_dir), - self.define("LLVM_EXTERNAL_LIBDEVICE_SOURCE_DIR", libdevice_dir), - self.define("LLVM_ENABLE_PROJECTS", llvm_enable_projects), - self.define("LIBCLC_TARGETS_TO_BUILD", libclc_targets_to_build), - self.define_from_variant("SYCL_BUILD_PI_CUDA", "cuda"), - self.define_from_variant("SYCL_BUILD_PI_ROCM", "rocm"), - self.define("SYCL_BUILD_PI_ROCM_PLATFORM", sycl_build_pi_rocm_platform), - self.define("LLVM_BUILD_TOOLS", True), - self.define_from_variant("SYCL_ENABLE_WERROR", "werror"), - self.define("SYCL_INCLUDE_TESTS", True), - self.define_from_variant("LIBCLC_GENERATE_REMANGLED_VARIANTS", "remangle_libclc"), - self.define_from_variant("LLVM_ENABLE_DOXYGEN", "docs"), - self.define_from_variant("LLVM_ENABLE_SPHINX", "docs"), - self.define_from_variant("BUILD_SHARED_LIBS", "shared"), - self.define("SYCL_ENABLE_XPTI_TRACING", "ON"), - self.define_from_variant("LLVM_ENABLE_LLD", "lld"), - self.define_from_variant("SYCL_BUILD_PI_ESIMD_CPU", "esimd-cpu"), - ] - - if is_cuda or (is_rocm and sycl_build_pi_rocm_platform == "NVIDIA"): - args.append(self.define("CUDA_TOOLKIT_ROOT_DIR", self.spec["cuda"].prefix)) - - if "+openmp" in self.spec: - omp_dir = os.path.join(self.stage.source_path, "openmp") - args.extend( - [ - self.define("LLVM_EXTERNAL_OPENMP_SOURCE_DIR", omp_dir), - self.define("OPENMP_ENABLE_LIBOMPTARGET", False), - ] - ) - - if self.compiler.name == "gcc": - gcc_prefix = ancestor(self.compiler.cc, 2) - args.append(self.define("GCC_INSTALL_PREFIX", gcc_prefix)) - - return args - - def setup_build_environment(self, env): - if "+cuda" in self.spec: - env.set("CUDA_LIB_PATH", "{0}/lib64/stubs".format(self.spec["cuda"].prefix)) - - @run_after("install") - def post_install(self): - clang_cpp_path = os.path.join(self.spec.prefix.bin, "clang++") - dpcpp_path = os.path.join(self.spec.prefix.bin, "dpcpp") - - real_clang_cpp_path = os.path.realpath(clang_cpp_path) - os.symlink(real_clang_cpp_path, dpcpp_path) - - def setup_run_environment(self, env): - bin_path = self.spec.prefix.bin - for env_var_name, compiler in zip(["CC", "CXX"], ["clang", "clang++"]): - env.set(env_var_name, os.path.join(bin_path, compiler)) - - include_env_vars = ["C_INCLUDE_PATH", "CPLUS_INCLUDE_PATH", "INCLUDE"] - for var in include_env_vars: - env.prepend_path(var, self.prefix.include) - env.prepend_path(var, self.prefix.include.sycl) - - sycl_build_pi_rocm_platform = self.spec.variants["rocm-platform"].value - if "+cuda" in self.spec or sycl_build_pi_rocm_platform == "NVIDIA": - env.prepend_path("PATH", self.spec["cuda"].prefix.bin) - env.set("CUDA_TOOLKIT_ROOT_DIR", self.spec["cuda"].prefix) diff --git a/var/spack/repos/builtin/packages/dpdk/package.py b/var/spack/repos/builtin/packages/dpdk/package.py index 590fe54ef49aaf..2d86cf2178143b 100644 --- a/var/spack/repos/builtin/packages/dpdk/package.py +++ b/var/spack/repos/builtin/packages/dpdk/package.py @@ -29,6 +29,9 @@ class Dpdk(MakefilePackage, MesonPackage): version("19.05", sha256="5fea95cb726e6adaa506dab330e79563ccd4dacf03f126c826aabdced605d32b") version("19.02", sha256="04885d32c86fff5aefcfffdb8257fed405233602dbcd22f8298be13c2e285a50") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + conflicts("target=aarch64:", msg="DPDK is not supported on aarch64.") # Build system diff --git a/var/spack/repos/builtin/packages/draco/package.py b/var/spack/repos/builtin/packages/draco/package.py index fd045639ab10e9..c645c9391f9373 100644 --- a/var/spack/repos/builtin/packages/draco/package.py +++ b/var/spack/repos/builtin/packages/draco/package.py @@ -20,6 +20,7 @@ class Draco(CMakePackage): license("BSD-3-Clause-Open-MPI") version("develop", branch="develop") + version("7.18.0", sha256="b210e202a06ffdaf149193b5cba164411fd508e20e573e1dfc46d1f56e3fffaa") version("7.14.1", sha256="b05c75f1b8ea1d4fac4900d897fb1c948b470826b174ed8b97b32c6da9f030bf") version("7.14.0", sha256="c8abf293d81c1b8020907557c20d8d2f2edf9ac7ae60a534eab052a8c3b7f99d") version("7.13.0", sha256="07a443df71d8d3720ced98f86821f714d2bfaa9f17a177c7f0465a59a1e9e719") diff --git a/var/spack/repos/builtin/packages/dracut/package.py b/var/spack/repos/builtin/packages/dracut/package.py index 0129222109664b..7152ee96b291fe 100644 --- a/var/spack/repos/builtin/packages/dracut/package.py +++ b/var/spack/repos/builtin/packages/dracut/package.py @@ -19,4 +19,6 @@ class Dracut(AutotoolsPackage): version("059", sha256="eabf0bb685420c1e1d5475b6855ef787104508f0135ff570312845256e0fcecf") version("050", sha256="f9dbf18597e5929221365964293212c8c9ffb7d84529c5a338c834ecab06e333") + depends_on("c", type="build") # generated + depends_on("kmod") diff --git a/var/spack/repos/builtin/packages/dramsim2/package.py b/var/spack/repos/builtin/packages/dramsim2/package.py index 3a896ffcd68092..fe31b2bb460cf6 100644 --- a/var/spack/repos/builtin/packages/dramsim2/package.py +++ b/var/spack/repos/builtin/packages/dramsim2/package.py @@ -20,6 +20,8 @@ class Dramsim2(MakefilePackage): version("2.2.2", sha256="96d0257eafb41e38ffa4f13e3ef3759567bdde7fa3329403f324abd0ddf8d015") + depends_on("cxx", type="build") # generated + def build(self, spec, prefix): if spec.satisfies("platform=darwin"): make("libdramsim.dylib") diff --git a/var/spack/repos/builtin/packages/dramsim3/package.py b/var/spack/repos/builtin/packages/dramsim3/package.py index 85668f3e9e76e3..a96546d041a424 100644 --- a/var/spack/repos/builtin/packages/dramsim3/package.py +++ b/var/spack/repos/builtin/packages/dramsim3/package.py @@ -23,6 +23,9 @@ class Dramsim3(Package): version("1.0.0", sha256="064b732256f3bec9b553e00bcbc9a1d82172ec194f2b69c8797f585200b12566") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake", type="build") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/dray/package.py b/var/spack/repos/builtin/packages/dray/package.py index e7567908be2e63..0815c310c83bf7 100644 --- a/var/spack/repos/builtin/packages/dray/package.py +++ b/var/spack/repos/builtin/packages/dray/package.py @@ -45,16 +45,20 @@ class Dray(Package, CudaPackage): license("BSD-3-Clause") - version("develop", branch="develop", submodules="True") - version("0.1.8", sha256="ae78ca6a5a31f06f6400a4a1ff6fc1d75347c8b41027a80662179f5b877eee30") - version("0.1.7", sha256="11ea794c1a24d7ed0d76bad7209d62bafc033ec40a2ea3a00e68fe598c6aa46d") - version("0.1.6", sha256="43f39039599e3493cbbaeaf5621b611bef301ff504bed6e32c98f30bb2179e92") - version("0.1.5", sha256="aaf0975561a8e7910b9353e2dc30bd78abf9f01c306ec042422b7da223d3a8b8") - version("0.1.4", sha256="e763a3aa537b23486a4788f9d68db0a3eb545f6a2e617cd7c8a876682ca2d0a0") - version("0.1.3", sha256="b2f624a072463189997343b1ed911cc34c9bb1b6c7f0c3e48efeb40c05dd0d92") - version("0.1.2", sha256="46937f20124b28dc78a634e8e063a3e7a3bbfd9f424ce2680b08417010c376da") - version("0.1.1", sha256="e5daa49ee3367c087f5028dc5a08655298beb318014c6f3f65ef4a08fcbe346c") - version("0.1.0", sha256="8b341138e1069361351e0a94478608c5af479cca76e2f97d556229aed45c0169") + with default_args(deprecated=True): # part of ascent + version("develop", branch="develop", submodules="True") + version("0.1.8", sha256="ae78ca6a5a31f06f6400a4a1ff6fc1d75347c8b41027a80662179f5b877eee30") + version("0.1.7", sha256="11ea794c1a24d7ed0d76bad7209d62bafc033ec40a2ea3a00e68fe598c6aa46d") + version("0.1.6", sha256="43f39039599e3493cbbaeaf5621b611bef301ff504bed6e32c98f30bb2179e92") + version("0.1.5", sha256="aaf0975561a8e7910b9353e2dc30bd78abf9f01c306ec042422b7da223d3a8b8") + version("0.1.4", sha256="e763a3aa537b23486a4788f9d68db0a3eb545f6a2e617cd7c8a876682ca2d0a0") + version("0.1.3", sha256="b2f624a072463189997343b1ed911cc34c9bb1b6c7f0c3e48efeb40c05dd0d92") + version("0.1.2", sha256="46937f20124b28dc78a634e8e063a3e7a3bbfd9f424ce2680b08417010c376da") + version("0.1.1", sha256="e5daa49ee3367c087f5028dc5a08655298beb318014c6f3f65ef4a08fcbe346c") + version("0.1.0", sha256="8b341138e1069361351e0a94478608c5af479cca76e2f97d556229aed45c0169") + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant("openmp", default=True, description="Build OpenMP backend") variant("shared", default=True, description="Build as shared libs") @@ -81,9 +85,10 @@ class Dray(Package, CudaPackage): depends_on("apcomp~shared", when="~shared") depends_on("apcomp+shared", when="+shared") - depends_on("raja@0.12.0:") + depends_on("raja@0.14.0:0.14", when="@0.1.8:") depends_on("raja@:0.14", when="@0.1.7:") depends_on("raja@:0.13", when="@:0.1.6") + depends_on("raja@0.12.0:") depends_on("raja~cuda", when="~cuda") depends_on("raja+cuda", when="+cuda") propagate_cuda_arch("raja") @@ -114,19 +119,8 @@ def install(self, spec, prefix): """ with working_dir("spack-build", create=True): host_cfg_fname = self.create_host_config(spec, prefix) - cmake_args = [] - # if we have a static build, we need to avoid any of - # spack's default cmake settings related to rpaths - # (see: https://github.com/LLNL/spack/issues/2658) - if "+shared" in spec: - cmake_args.extend(std_cmake_args) - else: - for arg in std_cmake_args: - if arg.count("RPATH") == 0: - cmake_args.append(arg) - cmake_args.extend(["-C", host_cfg_fname, "../src"]) print("Configuring Devil Ray...") - cmake(*cmake_args) + cmake(*std_cmake_args, "-C", host_cfg_fname, "../src") print("Building Devil Ray...") make() # run unit tests if requested diff --git a/var/spack/repos/builtin/packages/drishti/package.py b/var/spack/repos/builtin/packages/drishti/package.py index 8ea7d53d3bb85d..65e7bca88c15e2 100644 --- a/var/spack/repos/builtin/packages/drishti/package.py +++ b/var/spack/repos/builtin/packages/drishti/package.py @@ -24,6 +24,8 @@ class Drishti(PythonPackage): version("0.4", sha256="bbbb272b4f6f44ae762f6cba28a2c589e15608691c559af0cc2f552590335d7b") + depends_on("c", type="build") # generated + depends_on("darshan-util", type=("run")) depends_on("python@3.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/dropwatch/package.py b/var/spack/repos/builtin/packages/dropwatch/package.py index e003c5602d95b5..1d43a943eec4dd 100644 --- a/var/spack/repos/builtin/packages/dropwatch/package.py +++ b/var/spack/repos/builtin/packages/dropwatch/package.py @@ -20,6 +20,8 @@ class Dropwatch(AutotoolsPackage): version("1.5.4", sha256="8c43d0c15d0cb9ce179fa1fb0610611723689a6f551b23c70a7ddc1cf068e8d2") version("1.5.3", sha256="b748b66a816c1f94531446c0451da5461a4a31b0949244bb867d741c6ac0148b") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/dsdp/package.py b/var/spack/repos/builtin/packages/dsdp/package.py index 381dba628e7d04..a913c197c47a8b 100644 --- a/var/spack/repos/builtin/packages/dsdp/package.py +++ b/var/spack/repos/builtin/packages/dsdp/package.py @@ -23,6 +23,8 @@ class Dsdp(MakefilePackage): version("5.8", sha256="26aa624525a636de272c0b329e2dfd01a0d5b7827f1c1c76f393d71e37dead70") + depends_on("c", type="build") # generated + depends_on("blas") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/dsfmt/package.py b/var/spack/repos/builtin/packages/dsfmt/package.py index 5486455f9daedb..1c44116a31efed 100644 --- a/var/spack/repos/builtin/packages/dsfmt/package.py +++ b/var/spack/repos/builtin/packages/dsfmt/package.py @@ -23,6 +23,9 @@ class Dsfmt(MakefilePackage): version("2.2.5", sha256="b7bc498cd140b4808963b1ff9f33b42a491870f54775c1060ecad0e02bcaffb4") version("2.2.4", sha256="39682961ecfba621a98dbb6610b6ae2b7d6add450d4f08d8d4edd0e10abd8174") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + @property def libs(self): return find_libraries("libdSFMT", root=self.prefix, recursive=True) diff --git a/var/spack/repos/builtin/packages/dsqss/package.py b/var/spack/repos/builtin/packages/dsqss/package.py index 72e5f5961f381c..1fb90c9ab04a1f 100644 --- a/var/spack/repos/builtin/packages/dsqss/package.py +++ b/var/spack/repos/builtin/packages/dsqss/package.py @@ -21,6 +21,8 @@ class Dsqss(CMakePackage): version("2.0.3", sha256="11255dd1f1317fb4ac2d6ae95535f027d627d03f5470717cd277dd9ab94496e0") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="build mpi support") depends_on("mpi", when="+mpi") @@ -58,7 +60,6 @@ def test_dla(self): copy(join_path(test01, "std.toml"), ".") # prepare - python = self.spec["python"].command opts = [self.spec.prefix.bin.dla_pre, "std.toml"] with test_part(self, "test_dla_pre", purpose="prepare dla"): python(*opts) diff --git a/var/spack/repos/builtin/packages/dsrc/package.py b/var/spack/repos/builtin/packages/dsrc/package.py index 4baa53b74bd552..d7a98f398c43d0 100644 --- a/var/spack/repos/builtin/packages/dsrc/package.py +++ b/var/spack/repos/builtin/packages/dsrc/package.py @@ -17,6 +17,8 @@ class Dsrc(MakefilePackage): version("2.0.2", sha256="6d7abe0d72a501054a2115ccafff2e85e6383de627ec3e94ff4f03b7bb96a806") + depends_on("cxx", type="build") # generated + parallel = False def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/dssp/package.py b/var/spack/repos/builtin/packages/dssp/package.py index a5a20a4be59688..cfd40cc00822f6 100644 --- a/var/spack/repos/builtin/packages/dssp/package.py +++ b/var/spack/repos/builtin/packages/dssp/package.py @@ -18,6 +18,8 @@ class Dssp(AutotoolsPackage): version("3.1.4", sha256="496282b4b5defc55d111190ab9f1b615a9574a2f090e7cf5444521c747b272d4") version("2.3.0", sha256="4c95976d86dc64949cb0807fbd58c7bee5393df0001999405863dc90f05846c6") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/dtc/package.py b/var/spack/repos/builtin/packages/dtc/package.py index a775a98803f8c7..541041d5322d2b 100644 --- a/var/spack/repos/builtin/packages/dtc/package.py +++ b/var/spack/repos/builtin/packages/dtc/package.py @@ -18,6 +18,8 @@ class Dtc(MakefilePackage): version("1.6.1", sha256="6401c9a0f577a270df4632bf0f3e5454ccc7a5ca3caefa67a3e1c29c9c6b8c60") + depends_on("c", type="build") # generated + depends_on("bison", type="build") # Build error with flex 2.6.3 # (convert-dtsv0-lexer.lex.c:398: error: "yywrap" redefined) diff --git a/var/spack/repos/builtin/packages/dtcmp/package.py b/var/spack/repos/builtin/packages/dtcmp/package.py index 992b2bf646a4d0..1fa7c28e1dc143 100644 --- a/var/spack/repos/builtin/packages/dtcmp/package.py +++ b/var/spack/repos/builtin/packages/dtcmp/package.py @@ -24,6 +24,8 @@ class Dtcmp(AutotoolsPackage): version("1.1.0", sha256="fd2c4485eee560a029f62c8f227df4acdb1edc9340907f4ae2dbee59f05f057d") version("1.0.3", sha256="1327368e2808043ad5f245cd16f0da19543de50eae02a4e22b8a1c2e0eff8f35") + depends_on("c", type="build") # generated + depends_on("mpi") depends_on("lwgrp") diff --git a/var/spack/repos/builtin/packages/dtf/package.py b/var/spack/repos/builtin/packages/dtf/package.py index 97e057717b4f88..a11ef8b7a2009a 100644 --- a/var/spack/repos/builtin/packages/dtf/package.py +++ b/var/spack/repos/builtin/packages/dtf/package.py @@ -21,6 +21,10 @@ class Dtf(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("cxx", default=True, description="Build pnetcdf the C++ Interface") variant("fortran", default=True, description="Build pnetcdf the Fortran Interface") diff --git a/var/spack/repos/builtin/packages/duckdb/package.py b/var/spack/repos/builtin/packages/duckdb/package.py index 3d8d7aad69b409..0f45b68428a40b 100644 --- a/var/spack/repos/builtin/packages/duckdb/package.py +++ b/var/spack/repos/builtin/packages/duckdb/package.py @@ -18,6 +18,9 @@ class Duckdb(MakefilePackage): maintainers("glentner", "teaguesterling") version("master", branch="master") + version("1.0.0", sha256="04e472e646f5cadd0a3f877a143610674b0d2bcf9f4102203ac3c3d02f1c5f26") + version("0.10.3", sha256="7855587b3491dd488993287caee28720bee43ae28e92e8f41ea4631e9afcbf88") + version("0.10.2", sha256="662a0ba5c35d678ab6870db8f65ffa1c72e6096ad525a35b41b275139684cea6") version("0.10.0", sha256="5a925b8607d00a97c1a3ffe6df05c0a62a4df063abd022ada82ac1e917792013") version( "0.9.2", @@ -50,6 +53,9 @@ class Duckdb(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.7:") depends_on("cmake", type="build") depends_on("gmake", type="build") @@ -82,6 +88,13 @@ class Duckdb(MakefilePackage): variant("odbc", default=False, description="Build with ODBC driver (may not work)") variant("python", default=False, description="Build with Python driver (may not work)") + # Observed failure in an AVX2-specific codeblock on x86_64_v4 target + conflicts( + "@1.0.0", + when="target=x86_64_v3:", + msg="See: https://github.com/duckdb/duckdb/issues/12362", + ) + def setup_build_environment(self, env): if "+ninjabuild" in self.spec: env.set("GEN", "ninja") @@ -106,6 +119,8 @@ def setup_build_environment(self, env): env.set(make_flag, "1") elif "~" + flag in self.spec: env.set(make_flag, "0") + if self.spec.satisfies("@0.10.2:"): + env.set("OVERRIDE_GIT_DESCRIBE", f"v{self.spec.version}") def url_for_version(self, version): return "https://github.com/duckdb/duckdb/archive/refs/tags/v{0}.tar.gz".format(version) @@ -114,9 +129,11 @@ def patch(self): # DuckDB pulls its version from a git tag, which it can't find in the tarball # and thus defaults to something arbitrary and breaks extensions. # We use the Spack version to inject it in the right place during the build + # Patching is not needed for versions from 0.10.2 onward as we can + # set OVERRIDE_GIT_DESCRIBE to force the version when not building from a repo. version = self.spec.version - if not self.spec.satisfies("@0.10.0:"): + if self.spec.satisfies("@:0.9.2"): # Prior to version 0.10.0, this was sufficient filter_file( r'(message\(STATUS "git hash \$\{GIT_COMMIT_HASH\}, ' @@ -124,7 +141,7 @@ def patch(self): 'set(DUCKDB_VERSION "v{0}")\n\\1'.format(version), "CMakeLists.txt", ) - else: + elif not self.spec.satisfies("@0.10.0"): # Override the fallback values that are set when GIT_COMMIT_HASH doesn't work for i, n in enumerate(["MAJOR", "MINOR", "PATCH"]): filter_file( diff --git a/var/spack/repos/builtin/packages/duperemove/package.py b/var/spack/repos/builtin/packages/duperemove/package.py index 340abe8a47cc7c..71834aecd9df25 100644 --- a/var/spack/repos/builtin/packages/duperemove/package.py +++ b/var/spack/repos/builtin/packages/duperemove/package.py @@ -17,6 +17,8 @@ class Duperemove(MakefilePackage): version("0.11.1", sha256="75c3c91baf7e5195acad62eab73a7afc3d0b88cbfccefac3e3412eba06a42ac8") + depends_on("c", type="build") # generated + depends_on("glib") depends_on("sqlite") diff --git a/var/spack/repos/builtin/packages/dwz/package.py b/var/spack/repos/builtin/packages/dwz/package.py index 85afeedbb6e73c..b85f84e78a6bae 100644 --- a/var/spack/repos/builtin/packages/dwz/package.py +++ b/var/spack/repos/builtin/packages/dwz/package.py @@ -22,6 +22,9 @@ class Dwz(MakefilePackage, SourcewarePackage): preferred=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("dwz", prefix.bin) diff --git a/var/spack/repos/builtin/packages/dyninst/package.py b/var/spack/repos/builtin/packages/dyninst/package.py index f9a89ad0b5ec3e..06b10b1911a3eb 100644 --- a/var/spack/repos/builtin/packages/dyninst/package.py +++ b/var/spack/repos/builtin/packages/dyninst/package.py @@ -51,6 +51,9 @@ class Dyninst(CMakePackage): "8.2.1", tag="v8.2.1", commit="939afcbad1a8273636a3686a31b51dae4f1f0c11", deprecated=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "openmp", default=True, @@ -108,7 +111,7 @@ class Dyninst(CMakePackage): patch("v9.3.2-auto.patch", when="@9.3.2 %gcc@:4.7") patch("tribool.patch", when="@9.3.0:10.0.0 ^boost@1.69:") - requires("%gcc", msg="dyninst builds only with GCC") + requires("%gcc", when="@:13.0.0", msg="dyninst builds only with GCC") # No Mac support (including apple-clang) conflicts("platform=darwin", msg="macOS is not supported") diff --git a/var/spack/repos/builtin/packages/dysco/package.py b/var/spack/repos/builtin/packages/dysco/package.py index 4dbf4f438b1757..cf80d6ae6a70d6 100644 --- a/var/spack/repos/builtin/packages/dysco/package.py +++ b/var/spack/repos/builtin/packages/dysco/package.py @@ -17,6 +17,8 @@ class Dysco(CMakePackage): version("1.3", sha256="02cb53cc0a95a17a04fbaa6063b39641725b81f279b08e85761b01e8f186609f") version("1.2", sha256="dd992c5a13df67173aa1d3f6dc5df9b51b0bea2fe77bc08f5be7a839be741269") + depends_on("cxx", type="build") # generated + depends_on("casacore") depends_on("gsl") depends_on("boost+date_time+python+container+exception") diff --git a/var/spack/repos/builtin/packages/e2fsprogs/package.py b/var/spack/repos/builtin/packages/e2fsprogs/package.py index 5560a5348df4af..2d988bafeabdc0 100644 --- a/var/spack/repos/builtin/packages/e2fsprogs/package.py +++ b/var/spack/repos/builtin/packages/e2fsprogs/package.py @@ -15,14 +15,41 @@ class E2fsprogs(AutotoolsPackage): license("GPL-2.0-or-later AND LGPL-2.0-or-later AND BSD-3-Clause AND MIT") + version("1.47.1", sha256="db95ff1cb6ef741c9aa8875d9f3f52a34168360febba765b6377b80bada09a8c") + version("1.47.0", sha256="74c8ea97c73294edc6c11dc5e7fbb4324f86c28efd66ad0ba50be4eec8a48be2") version("1.45.6", sha256="d785164a2977cd88758cb0cac5c29add3fe491562a60040cfb193abcd0f9609b") version("1.45.5", sha256="0fd76e55c1196c1d97a2c01f2e84f463b8e99484541b43ff4197f5a695159fd3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant("fuse2fs", default=False, description="Build fuse2fs") + depends_on("texinfo", type="build") + depends_on("fuse", when="+fuse2fs") + + # fuse3 support is in the yet unreleased 1.47.1 + patch( + "https://github.com/tytso/e2fsprogs/commit/5598a96.patch?full_index=1", + sha256="72b28eb4599dbae45a01a1518ab6b8b6fc23db4f67381b49f63d3a3d45822340", + when="@:1.47.0 +fuse2fs", + ) + patch( + "https://github.com/tytso/e2fsprogs/commit/1ac0061.patch?full_index=1", + sha256="c5fbcd4e6d7f29d083d923b33998d916e2059b8f108c8cc20e8b5c928186eef2", + when="@:1.47.0 +fuse2fs", + ) + patch( + "https://github.com/tytso/e2fsprogs/commit/448a3f8.patch?full_index=1", + sha256="fb45c3af229b49fab19c70c00c33b9f3579a9455025aedb8049ff411b1cf3a96", + when="@:1.47.0 +fuse2fs", + ) def setup_run_environment(self, env): env.prepend_path("PATH", self.prefix.sbin) def configure_args(self): # avoid installing things in /etc - return ["--without-udev-rules-dir", "--without-crond-dir", "--without-systemd-unit-dir"] + args = ["--without-udev-rules-dir", "--without-crond-dir", "--without-systemd-unit-dir"] + args.extend(self.enable_or_disable("fuse2fs")) + return args diff --git a/var/spack/repos/builtin/packages/e3sm-kernels/package.py b/var/spack/repos/builtin/packages/e3sm-kernels/package.py index 8000d18ae71381..a4564dcc71d512 100644 --- a/var/spack/repos/builtin/packages/e3sm-kernels/package.py +++ b/var/spack/repos/builtin/packages/e3sm-kernels/package.py @@ -23,6 +23,8 @@ class E3smKernels(MakefilePackage): version("master", branch="master") version("1.0", sha256="358249785ba9f95616feecbb6f37f7694646568499c11b2094c9233999c6cc95") + depends_on("fortran", type="build") # generated + variant( "kernel", default="atmosphere", diff --git a/var/spack/repos/builtin/packages/e3sm-scorpio/package.py b/var/spack/repos/builtin/packages/e3sm-scorpio/package.py index 66c8600096aa42..078a57a7d5f241 100644 --- a/var/spack/repos/builtin/packages/e3sm-scorpio/package.py +++ b/var/spack/repos/builtin/packages/e3sm-scorpio/package.py @@ -16,6 +16,10 @@ class E3smScorpio(CMakePackage): version("1.4.1", sha256="7cb4589410080d7e547ef17ddabe68f749e6af019c1d0e6ee9f11554f3ff6b1a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("timing", default=False, description="Enable timing") variant("mpi", default=True, description="Enable MPI") diff --git a/var/spack/repos/builtin/packages/e4s-alc/package.py b/var/spack/repos/builtin/packages/e4s-alc/package.py new file mode 100644 index 00000000000000..9557d6554cbe05 --- /dev/null +++ b/var/spack/repos/builtin/packages/e4s-alc/package.py @@ -0,0 +1,29 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class E4sAlc(PythonPackage): + """Container file creator, facilitating the generation of + Dockerfiles and Singularity definition files infused with OS packages, + spack packages and custom commands""" + + maintainers("FrederickDeny", "PlatinumCD") + homepage = "https://github.com/E4S-Project/e4s-alc" + git = "https://github.com/E4S-Project/e4s-alc" + + tags = ["e4s"] + + license("MIT") + + version("main", branch="main") + version("1.0.2", commit="9eddfc61659ecab3c0253b2eac020ddb6e610b49") + version("1.0.1", commit="262298128a4991ffc773b1bd835687fb6493311e") + + depends_on("python@3.7:", type=("build", "run")) + depends_on("py-setuptools", type="build") + + depends_on("py-pyyaml@6.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/e4s-cl/package.py b/var/spack/repos/builtin/packages/e4s-cl/package.py index 258471c0108f70..4208a2e7e2f2e0 100644 --- a/var/spack/repos/builtin/packages/e4s-cl/package.py +++ b/var/spack/repos/builtin/packages/e4s-cl/package.py @@ -22,6 +22,7 @@ class E4sCl(PythonPackage): license("MIT") version("master", branch="master") + version("1.0.3", commit="1b34fa7964273675ce18b9cd3006b4b87dda1ef2") version("1.0.1", commit="b2c92993e0c7cb42de07f0f7cc02da3a06816192") version("1.0.0", commit="410bb2e6601d9b90243a487ad7f7d2dabd8ba04c") diff --git a/var/spack/repos/builtin/packages/ea-utils/package.py b/var/spack/repos/builtin/packages/ea-utils/package.py index b57c30ecb1e39a..8a90b61af38613 100644 --- a/var/spack/repos/builtin/packages/ea-utils/package.py +++ b/var/spack/repos/builtin/packages/ea-utils/package.py @@ -25,6 +25,9 @@ class EaUtils(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("sparsehash") depends_on("zlib-api") depends_on("gsl") diff --git a/var/spack/repos/builtin/packages/eagle/package.py b/var/spack/repos/builtin/packages/eagle/package.py index 3a68066d11b59c..3abe19fb37102b 100644 --- a/var/spack/repos/builtin/packages/eagle/package.py +++ b/var/spack/repos/builtin/packages/eagle/package.py @@ -18,6 +18,8 @@ class Eagle(MakefilePackage): version("1.1.3", sha256="bd510b8eef2de14898cbf417e1c7a30b97ddaba24e5e2834da7b02767362fe3c") version("1.1.2", sha256="afe967560d1f8fdbd0caf4b93b5f2a86830e9e4d399fee4a526140431343045e") + depends_on("c", type="build") # generated + depends_on("curl") depends_on("zlib-api") depends_on("lzma") diff --git a/var/spack/repos/builtin/packages/earlyoom/package.py b/var/spack/repos/builtin/packages/earlyoom/package.py index 09cc0d1fad6fae..a79c520a6e3c65 100644 --- a/var/spack/repos/builtin/packages/earlyoom/package.py +++ b/var/spack/repos/builtin/packages/earlyoom/package.py @@ -14,9 +14,12 @@ class Earlyoom(MakefilePackage): license("MIT") + version("1.8", sha256="bbb050a2294e60dafc0b129fcec705ef95d9d27f4c9dae1d3b4f25e4f698ae41") version("1.6.1", sha256="bcd3fab4da5e1dddec952a0974c866ec90c5f9159c995f9162c45488c4d03340") version("1.6", sha256="b81804fc4470f996014d52252a87a1cf3b43d3d8754140035b10dcee349302b8") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("earlyoom", prefix.bin) diff --git a/var/spack/repos/builtin/packages/easi/package.py b/var/spack/repos/builtin/packages/easi/package.py index ea5a113ed185cb..c32354d7ea4b09 100644 --- a/var/spack/repos/builtin/packages/easi/package.py +++ b/var/spack/repos/builtin/packages/easi/package.py @@ -3,6 +3,8 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os + from spack.package import * @@ -14,14 +16,21 @@ class Easi(CMakePackage): homepage = "https://easyinit.readthedocs.io" git = "https://github.com/SeisSol/easi.git" - maintainers("ravil-mobile", "Thomas-Ulrich", "krenzland", "ThrudPrimrose", "davschneller") + maintainers("Thomas-Ulrich", "davschneller", "vikaskurapati") license("BSD-3-Clause") - version("develop", branch="master") + version("master", branch="master") + version("1.3.0", tag="v1.3.0", commit="99309a0fa78bf11d668c599b3ee469224f04d55b") version("1.2.0", tag="v1.2.0", commit="305a119338116a0ceac6b68b36841a50250d05b1") version("1.1.2", tag="v1.1.2", commit="4c87ef3b3dca9415d116ef102cb8de750ef7e1a0") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("python", default=True, description="Install python bindings") + extends("python", when="+python") + variant("asagi", default=True, description="build with ASAGI support") variant( "jit", @@ -38,6 +47,8 @@ class Easi(CMakePackage): depends_on("lua@5.3.2", when="jit=lua") depends_on("impalajit@main", when="jit=impalajit") + depends_on("py-pybind11@2.6.2:", type="build", when="+python") + conflicts("jit=impalajit", when="jit=impalajit-llvm") conflicts("jit=impalajit-llvm", when="jit=impalajit") @@ -49,6 +60,8 @@ class Easi(CMakePackage): def cmake_args(self): args = [] args.append(self.define_from_variant("ASAGI", "asagi")) + args.append(self.define_from_variant("PYTHON_BINDINGS", "python")) + self.define("PYBIND11_USE_FETCHCONTENT", False) spec = self.spec if "jit=impalajit" in spec or "jit=impalajit-llvm" in spec: args.append(self.define("IMPALAJIT", True)) @@ -60,4 +73,12 @@ def cmake_args(self): if "jit=lua" in spec: args.append(self.define("LUA", True)) + if "+python" in spec: + args += [self.define("easi_INSTALL_PYTHONDIR", python_platlib)] + return args + + def setup_run_environment(self, env): + if "+python" in self.spec: + full_path = os.path.join(python_platlib, "easilib/cmake/easi/python_wrapper") + env.prepend_path("PYTHONPATH", full_path) diff --git a/var/spack/repos/builtin/packages/easyloggingpp/package.py b/var/spack/repos/builtin/packages/easyloggingpp/package.py index c1fba765e8d3d7..a46b625b712e18 100644 --- a/var/spack/repos/builtin/packages/easyloggingpp/package.py +++ b/var/spack/repos/builtin/packages/easyloggingpp/package.py @@ -14,3 +14,5 @@ class Easyloggingpp(CMakePackage): version("9.97.0", sha256="9110638e21ef02428254af8688bf9e766483db8cc2624144aa3c59006907ce22") version("9.96.7", sha256="237c80072b9b480a9f2942b903b4b0179f65e146e5dcc64864dc91792dedd722") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/ebms/package.py b/var/spack/repos/builtin/packages/ebms/package.py index f92a83e3592a7e..b253837d78a9d8 100644 --- a/var/spack/repos/builtin/packages/ebms/package.py +++ b/var/spack/repos/builtin/packages/ebms/package.py @@ -24,6 +24,8 @@ class Ebms(MakefilePackage): version("develop") + depends_on("c", type="build") # generated + depends_on("mpi@2:") tags = ["proxy-app"] diff --git a/var/spack/repos/builtin/packages/ecbuild/package.py b/var/spack/repos/builtin/packages/ecbuild/package.py index d4882131a7a285..9e4cdf6c92adbe 100644 --- a/var/spack/repos/builtin/packages/ecbuild/package.py +++ b/var/spack/repos/builtin/packages/ecbuild/package.py @@ -21,6 +21,10 @@ class Ecbuild(CMakePackage): version("3.6.5", sha256="98bff3d3c269f973f4bfbe29b4de834cd1d43f15b1c8d1941ee2bfe15e3d4f7f") version("3.6.1", sha256="796ccceeb7af01938c2f74eab0724b228e9bf1978e32484aa3e227510f69ac59") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.11:", type=("build", "run")) # See https://github.com/ecmwf/ecbuild/issues/35 diff --git a/var/spack/repos/builtin/packages/eccodes/package.py b/var/spack/repos/builtin/packages/eccodes/package.py index eb4184cfeafd73..7d25600ed44275 100644 --- a/var/spack/repos/builtin/packages/eccodes/package.py +++ b/var/spack/repos/builtin/packages/eccodes/package.py @@ -67,6 +67,10 @@ class Eccodes(CMakePackage): version("2.5.0", sha256="18ab44bc444168fd324d07f7dea94f89e056f5c5cd973e818c8783f952702e4e") version("2.2.0", sha256="1a4112196497b8421480e2a0a1164071221e467853486577c4f07627a702f4c3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("tools", default=False, description="Build the command line tools") variant("netcdf", default=False, description="Enable GRIB to NetCDF conversion tool") variant( diff --git a/var/spack/repos/builtin/packages/ecdsautils/package.py b/var/spack/repos/builtin/packages/ecdsautils/package.py index 2c9602eb7353a1..1404c947e21c87 100644 --- a/var/spack/repos/builtin/packages/ecdsautils/package.py +++ b/var/spack/repos/builtin/packages/ecdsautils/package.py @@ -15,4 +15,6 @@ class Ecdsautils(CMakePackage): version("0.3.2", sha256="a828417c985ccfc623bb613e92ccc8af6c6f24a5bcab8b112b90c033a816204f") version("0.3.1", sha256="4b6efe7802a089e8d64194c954a8f9981ff516b922b40d51e6c7ba565274a87a") + depends_on("c", type="build") # generated + depends_on("libuecc", type="build") diff --git a/var/spack/repos/builtin/packages/ecflow/package.py b/var/spack/repos/builtin/packages/ecflow/package.py index bfef706a3f98b8..7616e64e8db11c 100644 --- a/var/spack/repos/builtin/packages/ecflow/package.py +++ b/var/spack/repos/builtin/packages/ecflow/package.py @@ -30,6 +30,10 @@ class Ecflow(CMakePackage): version("4.12.0", sha256="566b797e8d78e3eb93946b923ef540ac61f50d4a17c9203d263c4fd5c39ab1d1") version("4.11.1", sha256="b3bcc1255939f87b9ba18d802940e08c0cf6379ca6aeec1fef7bd169b0085d6c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("ssl", default=True, description="Enable SSL") variant( "static_boost", default=False, description="Use also static boost libraries when compiling" @@ -52,7 +56,8 @@ class Ecflow(CMakePackage): # See https://github.com/spack/spack/pull/22303 for reference depends_on(Boost.with_default_variants, when="@:4") - # Use newer boost with v5 + # Use newer boost with v5 up to 1.84.0 - https://github.com/spack/spack/issues/44116 + conflicts("boost@1.85:", when="@:5.11.4") depends_on( "boost@1.72:+chrono+date_time+exception+filesystem+program_options+python+regex+serialization+system+test+thread+timer", # noqa when="@5:", diff --git a/var/spack/repos/builtin/packages/eckit/package.py b/var/spack/repos/builtin/packages/eckit/package.py index 5badc2b643cb91..5b24350f4ac3ae 100644 --- a/var/spack/repos/builtin/packages/eckit/package.py +++ b/var/spack/repos/builtin/packages/eckit/package.py @@ -31,6 +31,9 @@ class Eckit(CMakePackage): version("1.16.3", sha256="d2aae7d8030e2ce39e5d04e36dd6aa739f3c8dfffe32c61c2a3127c36b573485") version("1.16.0", sha256="9e09161ea6955df693d3c9ac70131985eaf7cf24a9fa4d6263661c6814ebbaf1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "build_type", default="RelWithDebInfo", diff --git a/var/spack/repos/builtin/packages/ecmwf-atlas/package.py b/var/spack/repos/builtin/packages/ecmwf-atlas/package.py index e14429104a0f8a..900eb13fc20d47 100644 --- a/var/spack/repos/builtin/packages/ecmwf-atlas/package.py +++ b/var/spack/repos/builtin/packages/ecmwf-atlas/package.py @@ -31,6 +31,10 @@ class EcmwfAtlas(CMakePackage): version("0.31.1", sha256="fa9274c74c40c2115b9c6120a7040e357b0c7f37b20b601b684d2a83a479cdfb") version("0.31.0", sha256="fa4ff8665544b8e19f79d171c540a9ca8bfc4127f52a3c4d4d618a2fe23354d7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("ecbuild", type=("build")) depends_on("ecbuild@3.4:", type=("build"), when="@0.36.0:") depends_on("eckit@:1.23", when="@:0.33") diff --git a/var/spack/repos/builtin/packages/ecos/package.py b/var/spack/repos/builtin/packages/ecos/package.py index b393e2636cccd4..9f0ad1f0c7f6dc 100644 --- a/var/spack/repos/builtin/packages/ecos/package.py +++ b/var/spack/repos/builtin/packages/ecos/package.py @@ -17,6 +17,8 @@ class Ecos(MakefilePackage): version("2.0.7", sha256="bdb6a84f7d150820459bd0a796cb64ffbb019afb95dc456d22acc2dafb2e70e0") + depends_on("c", type="build") # generated + build_targets = ["all", "shared"] def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/ecoslim/package.py b/var/spack/repos/builtin/packages/ecoslim/package.py index 61b2fcdfec9b4f..22704c2fe766de 100644 --- a/var/spack/repos/builtin/packages/ecoslim/package.py +++ b/var/spack/repos/builtin/packages/ecoslim/package.py @@ -22,6 +22,8 @@ class Ecoslim(CMakePackage): version("1.3", sha256="b532e570b4767e4fa84123d8773732150679e8e3d7fecd5c6e99fb1d4dc57b84") version("master", branch="master") + depends_on("fortran", type="build") # generated + def cmake_args(self): """Populate cmake arguments for EcoSLIM.""" return [] diff --git a/var/spack/repos/builtin/packages/ecp-proxy-apps/package.py b/var/spack/repos/builtin/packages/ecp-proxy-apps/package.py index b2f124e68ee14d..833d5b9e524f77 100644 --- a/var/spack/repos/builtin/packages/ecp-proxy-apps/package.py +++ b/var/spack/repos/builtin/packages/ecp-proxy-apps/package.py @@ -53,7 +53,6 @@ class EcpProxyApps(BundlePackage): depends_on("picsarlite@0.1", when="@2.0:") depends_on("thornado-mini@1.0", when="@2.0:") - depends_on("candle-benchmarks@0.1", when="+candle @2.0:2.1") depends_on("laghos@2.0", when="@2.0:2.1") depends_on("macsio@1.1", when="@2.0:") depends_on("sw4lite@1.1", when="@2.0:") @@ -71,7 +70,6 @@ class EcpProxyApps(BundlePackage): # Dependencies for versions 1.0:1.1 depends_on("amg2013@1.0", when="@1.0:1.1") - depends_on("candle-benchmarks@0.0", when="+candle @1.0:1.1") depends_on("laghos@1.0", when="@1.0:1.1") depends_on("macsio@1.0", when="@1.0:1.1") depends_on("miniamr@1.4.0", when="@1.0:1.1") diff --git a/var/spack/repos/builtin/packages/ectrans/package.py b/var/spack/repos/builtin/packages/ectrans/package.py index e4e7ac65beb700..0199acb8b836ca 100644 --- a/var/spack/repos/builtin/packages/ectrans/package.py +++ b/var/spack/repos/builtin/packages/ectrans/package.py @@ -26,6 +26,9 @@ class Ectrans(CMakePackage): version("1.2.0", sha256="2ee6dccc8bbfcc23faada1d957d141f24e41bb077c1821a7bc2b812148dd336c") version("1.1.0", sha256="3c9848bb65033fbe6d791084ee347b3adf71d5dfe6d3c11385000017b6469a3e") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "build_type", default="RelWithDebInfo", diff --git a/var/spack/repos/builtin/packages/ed/package.py b/var/spack/repos/builtin/packages/ed/package.py index df2c77d0ab396a..36e5d5171fe139 100644 --- a/var/spack/repos/builtin/packages/ed/package.py +++ b/var/spack/repos/builtin/packages/ed/package.py @@ -18,4 +18,6 @@ class Ed(AutotoolsPackage, GNUMirrorPackage): version("1.4", sha256="db36da85ee1a9d8bafb4b041bd4c8c11becba0c43ec446353b67045de1634fda") + depends_on("c", type="build") # generated + parallel = False diff --git a/var/spack/repos/builtin/packages/editline/package.py b/var/spack/repos/builtin/packages/editline/package.py index 4d6f8024f6b512..5cfe0db26f3118 100644 --- a/var/spack/repos/builtin/packages/editline/package.py +++ b/var/spack/repos/builtin/packages/editline/package.py @@ -17,6 +17,8 @@ class Editline(AutotoolsPackage): version("1.17.1", sha256="d65c5739c8ca388fa71feabc5aae506d052e1a6d288ee4e7fcab7efb07a3be74") version("1.16.0", sha256="33421a1569d025f332a87054bfea28e2c757bdb573f1437bc22c34b798b6383c") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/editorconfig/package.py b/var/spack/repos/builtin/packages/editorconfig/package.py new file mode 100644 index 00000000000000..6ded3f667b93a2 --- /dev/null +++ b/var/spack/repos/builtin/packages/editorconfig/package.py @@ -0,0 +1,24 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Editorconfig(CMakePackage): + """ + EditorConfig helps maintain consistent coding styles for multiple + developers working on the same project across various editors and IDEs. + """ + + homepage = "https://editorconfig.org/" + url = "https://github.com/editorconfig/editorconfig-core-c/archive/refs/tags/v0.12.7.tar.gz" + + license("BSD-2-Clause", checked_by="taliaferro") + + version("0.12.7", sha256="f89d2e144fd67bdf0d7acfb2ac7618c6f087e1b3f2c3a707656b4180df422195") + + depends_on("c", type="build") # generated + + depends_on("pcre2") diff --git a/var/spack/repos/builtin/packages/editres/package.py b/var/spack/repos/builtin/packages/editres/package.py index 16053f9e3bfdee..352cc81919e866 100644 --- a/var/spack/repos/builtin/packages/editres/package.py +++ b/var/spack/repos/builtin/packages/editres/package.py @@ -15,6 +15,8 @@ class Editres(AutotoolsPackage, XorgPackage): version("1.0.8", sha256="2d56d6077bc767afa7e030feb2c372fe6be893fec4029a23f45a1d559fd846ae") version("1.0.6", sha256="85f4664ca582effb01ee972d006124569b757b9a08ae6608c3f45fc36b3b7b1a") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libx11") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/edm4hep/package.py b/var/spack/repos/builtin/packages/edm4hep/package.py index 414eacdca76308..a908c0dd4d7b6a 100644 --- a/var/spack/repos/builtin/packages/edm4hep/package.py +++ b/var/spack/repos/builtin/packages/edm4hep/package.py @@ -31,73 +31,8 @@ class Edm4hep(CMakePackage): version("0.10.2", sha256="c22c5c2f0fd1d09da9b734c1fa7ee546675fd2b047406db6ab8266e7657486d2") version("0.10.1", sha256="28a3bd4df899309b14ec0d441f8b6ed0065206a08a0018113bb490e9d008caed") version("0.10", sha256="a95c917c19793cfad6b0959854a653c5ce698c965598cabd649d544da07712c0") - version( - "0.9", - sha256="170ef84822761c4b02da9047f2b4d0dd0f48ed1c027b10171d4207b1542fbd5c", - deprecated=True, - ) - version( - "0.8", - sha256="102d57167885eba3bea79f6b6647e5303ad8732c5784590abdcdd816b2411c79", - deprecated=True, - ) - version( - "0.7.2", - sha256="e289280d5de2c0a3b542bf9dfe04b9f6471b0a0fcf33f5c8101ea7252e2a7643", - deprecated=True, - ) - version( - "0.7.1", - sha256="82e215a532f548a73a6f6094eaa8b436c553994e135f6d63a674543dc89a9f1b", - deprecated=True, - ) - version( - "0.7", - sha256="0cef3f06d86c13e87e3343ac9d5db0b3087c421e8bda4bd2623858acb1af60c9", - deprecated=True, - ) - version( - "0.6", - sha256="625a5a939cb8d7a0a6ab5874a3e076d7dd5338446be3921b0cbc09de4d96b315", - deprecated=True, - ) - version( - "0.5", - sha256="aae4f001412d57585751d858999fe78e004755aa0303a503d503a325ef97d7e0", - deprecated=True, - ) - version( - "0.4.2", - sha256="5f2ff3a14729cbd4da370c7c768c2a09eb9f68f814d61690b1cc99c4248994f4", - deprecated=True, - ) - version( - "0.4.1", - sha256="122987fd5969b0f1639afa9668ac5181203746d00617ddb3bf8a2a9842758a63", - deprecated=True, - ) - version( - "0.4", - sha256="bcb729cd4a6f5917b8f073364fc950788111e178dd16b7e5218361f459c92a24", - deprecated=True, - ) - version( - "0.3.2", - sha256="b6a28649a4ba9ec1c4423bd1397b0a810ca97374305c4856186b506e4c00f769", - deprecated=True, - ) - version( - "0.3.1", - sha256="eeec38fe7d72d2a72f07a63dca0a34ca7203727f67869c0abf6bef014b8b319b", - deprecated=True, - ) - version( - "0.3", - sha256="d0ad8a486c3ed1659ea97d47b268fe56718fdb389b5935f23ba93804e4d5fbc5", - deprecated=True, - ) - patch("test-deps.patch", when="@:0.3.2") + depends_on("cxx", type="build") # generated _cxxstd_values = ("17", "20") variant( @@ -113,22 +48,21 @@ class Edm4hep(CMakePackage): depends_on("python", type="build") depends_on("root@6.08:") - depends_on("nlohmann-json@3.10:", when="@0.7.1:") - depends_on("podio@0.15:", when="@0.6:") - depends_on("podio@0.14.1:", when="@0.4.1:") - depends_on("podio@0.14", when="@0.4") - depends_on("podio@0.13.0:0.13", when="@:0.3") + depends_on("nlohmann-json@3.10:") + depends_on("podio@0.15:") for _std in _cxxstd_values: depends_on("podio cxxstd=" + _std, when="cxxstd=" + _std) depends_on("py-jinja2", type="build") depends_on("py-pyyaml", type="build") - depends_on("hepmc@:2", type="test", when="@:0.4.0") - depends_on("hepmc3", type="test", when="@0.4.1:") + depends_on("hepmc3", type="test") depends_on("heppdt", type="test") depends_on("catch2@3.0.1:", type="test") + # Corresponding changes in EDM4hep landed with https://github.com/key4hep/EDM4hep/pull/314 + extends("python", when="@0.10.6:") + def cmake_args(self): args = [] # C++ Standard @@ -138,7 +72,8 @@ def cmake_args(self): def setup_run_environment(self, env): env.prepend_path("LD_LIBRARY_PATH", self.spec["edm4hep"].libs.directories[0]) - env.prepend_path("PYTHONPATH", self.prefix.python) + if self.spec.satisfies("@:0.10.5"): + env.prepend_path("PYTHONPATH", self.prefix.python) def url_for_version(self, version): """Translate version numbers to ilcsoft conventions. diff --git a/var/spack/repos/builtin/packages/edm4hep/test-deps.patch b/var/spack/repos/builtin/packages/edm4hep/test-deps.patch deleted file mode 100644 index 53d4bddacb0220..00000000000000 --- a/var/spack/repos/builtin/packages/edm4hep/test-deps.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt -index 6413c03..11325a4 100644 ---- a/test/CMakeLists.txt -+++ b/test/CMakeLists.txt -@@ -54,6 +54,7 @@ IF(TARGET ROOT::ROOTDataFrame) - add_test(NAME test_rdf COMMAND test_rdf) - set_tests_properties(test_rdf PROPERTIES - ENVIRONMENT LD_LIBRARY_PATH=$:$:$ENV{LD_LIBRARY_PATH} -+ DEPENDS write_events - ) - endif() - diff --git a/var/spack/repos/builtin/packages/eem/package.py b/var/spack/repos/builtin/packages/eem/package.py index 4b41e8cefd845d..9aecdb89f85f9e 100644 --- a/var/spack/repos/builtin/packages/eem/package.py +++ b/var/spack/repos/builtin/packages/eem/package.py @@ -15,6 +15,8 @@ class Eem(MakefilePackage): version("1.0.1", sha256="f617ea7350fce3b2581c814f70bda4427cbab83aac54a2dcadb36e8193f300bb") + depends_on("cxx", type="build") # generated + variant("K", default=False, description="Build for K computer") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/efivar/package.py b/var/spack/repos/builtin/packages/efivar/package.py index 1ef249380af2a2..9bfa06da51a9e8 100644 --- a/var/spack/repos/builtin/packages/efivar/package.py +++ b/var/spack/repos/builtin/packages/efivar/package.py @@ -18,5 +18,7 @@ class Efivar(MakefilePackage): version("36", sha256="24ed0cafbaf6d913e8f60e5da3cbbac1a1578e16cf5c95b21f2eb6753c13173f") version("35", sha256="747bc4d97b4bd74979e5356c44a172534a8a07184f130349fd201742e683d292") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make("PREFIX={0}".format(prefix), "install") diff --git a/var/spack/repos/builtin/packages/eigen/package.py b/var/spack/repos/builtin/packages/eigen/package.py index 6301084fa3506b..e1fda7e9f72936 100644 --- a/var/spack/repos/builtin/packages/eigen/package.py +++ b/var/spack/repos/builtin/packages/eigen/package.py @@ -36,6 +36,10 @@ class Eigen(CMakePackage): version("3.2.6", sha256="e097b8dcc5ad30d40af4ad72d7052e3f78639469baf83cffaadc045459cda21f") version("3.2.5", sha256="8068bd528a2ff3885eb55225c27237cf5cda834355599f05c2c85345db8338b4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # there is a bug that provokes bad parsing of nvhpc version patch( "https://gitlab.com/libeigen/eigen/-/commit/001a57519a7aa909d3bf0cd8c6ec8a9cd19d9c70.diff", diff --git a/var/spack/repos/builtin/packages/eigenexa/package.py b/var/spack/repos/builtin/packages/eigenexa/package.py index 46b76b958c7e0d..44d7b939d846f6 100644 --- a/var/spack/repos/builtin/packages/eigenexa/package.py +++ b/var/spack/repos/builtin/packages/eigenexa/package.py @@ -23,6 +23,9 @@ class Eigenexa(AutotoolsPackage): url="https://www.r-ccs.riken.jp/labs/lpnctrt/projects/eigenexa/EigenExa-2.6.tgz", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/elbencho/package.py b/var/spack/repos/builtin/packages/elbencho/package.py index 4088b11d282bfc..3a65df8b172cac 100644 --- a/var/spack/repos/builtin/packages/elbencho/package.py +++ b/var/spack/repos/builtin/packages/elbencho/package.py @@ -33,6 +33,9 @@ class Elbencho(MakefilePackage): version("2.0-9", sha256="fe0f67fbb7dd7c743f8b3e0a92358f7393f2950da456474d4adb38690fab1878") version("2.0-7", sha256="a2e49cb2cf1ae99e46e9fa95b42ece250cb58fbadb4c393f9776b40204e8b2c0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("s3", default=False, description="Enable support for s3 api") variant("cuda", default=True, description="Enable CUDA support", when="+cufile") variant("cuda", default=False, description="Enable CUDA support") @@ -56,7 +59,7 @@ class Elbencho(MakefilePackage): depends_on("curl", when="+s3") depends_on("libarchive", when="+s3") depends_on("openssl", when="+s3") - depends_on("libuuid", when="+s3") + depends_on("uuid", when="+s3") depends_on("zlib", when="+s3") depends_on("cmake", when="+s3") diff --git a/var/spack/repos/builtin/packages/elemental/package.py b/var/spack/repos/builtin/packages/elemental/package.py index 49306457d6a81a..f3d8589d1abdfa 100644 --- a/var/spack/repos/builtin/packages/elemental/package.py +++ b/var/spack/repos/builtin/packages/elemental/package.py @@ -23,6 +23,9 @@ class Elemental(CMakePackage): version("0.87.7", sha256="7becfdbc223e9c72e65ae876d842c48d2037d13f83e9f41cea285e21b840d7d9") version("0.87.6", sha256="b597987c99ddd3462e0619524c5b7f711177ae8ae541b1b961e11d96e15afc64") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") variant("hybrid", default=True, description="Make use of OpenMP within MPI packing/unpacking") variant( diff --git a/var/spack/repos/builtin/packages/elfio/package.py b/var/spack/repos/builtin/packages/elfio/package.py index 9205da948129b7..c38246216af7f9 100644 --- a/var/spack/repos/builtin/packages/elfio/package.py +++ b/var/spack/repos/builtin/packages/elfio/package.py @@ -25,6 +25,9 @@ class Elfio(CMakePackage): version("3.8", sha256="9553ce2b8d8aa2fb43f0e9be9bcbd10cd52f40b385110ea54173889c982f9ac4") version("3.7", sha256="0af2452214c32639f8dbe520b31e03802be184581ab5ad65e99ed745274dbd5d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # note, 3.10 is required on master it seems depends_on("cmake@3.12:", when="@3.8:", type="build") depends_on("cmake@3.12.4:", when="@3.7", type="build") diff --git a/var/spack/repos/builtin/packages/elfutils/package.py b/var/spack/repos/builtin/packages/elfutils/package.py index 7ebea92c432a71..46ec84f4d4ae6e 100644 --- a/var/spack/repos/builtin/packages/elfutils/package.py +++ b/var/spack/repos/builtin/packages/elfutils/package.py @@ -27,6 +27,7 @@ class Elfutils(AutotoolsPackage, SourcewarePackage): license("GPL-3.0-or-later AND ( GPL-2.0-or-later OR LGPL-3.0-or-later )") + version("0.191", sha256="df76db71366d1d708365fc7a6c60ca48398f14367eb2b8954efc8897147ad871") version("0.190", sha256="8e00a3a9b5f04bc1dc273ae86281d2d26ed412020b391ffcc23198f10231d692") version("0.189", sha256="39bd8f1a338e2b7cd4abc3ff11a0eddc6e690f69578a57478d8179b4148708c8") version("0.188", sha256="fb8b0e8d0802005b9a309c60c1d8de32dd2951b56f0c3a3cb56d21ce01595dff") @@ -49,6 +50,9 @@ class Elfutils(AutotoolsPackage, SourcewarePackage): version("0.168", sha256="b88d07893ba1373c7dd69a7855974706d05377766568a7d9002706d5de72c276") version("0.163", sha256="7c774f1eef329309f3b05e730bdac50013155d437518a2ec0e24871d312f2e23") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Native language support from libintl. variant("nls", default=True, description="Enable Native Language Support.") variant("exeprefix", default=True, description="Add a prefix to generated executables.") @@ -128,10 +132,10 @@ def configure_args(self): args.append("--with-zstd=%s" % spec["zstd"].prefix) if spec.satisfies("@0.183:"): - if spec["iconv"].name == "libc": + if spec["iconv"].name == "libiconv": + args.append(f"--with-libiconv-prefix={spec['iconv'].prefix}") + else: args.append("--without-libiconv-prefix") - elif not is_system_path(spec["iconv"].prefix): - args.append("--with-libiconv-prefix=" + format(spec["iconv"].prefix)) if "+nls" in spec: # Prior to 0.183, only msgfmt is used from gettext. diff --git a/var/spack/repos/builtin/packages/elk/package.py b/var/spack/repos/builtin/packages/elk/package.py index 96dda40d5ee5ad..4323aec7795414 100644 --- a/var/spack/repos/builtin/packages/elk/package.py +++ b/var/spack/repos/builtin/packages/elk/package.py @@ -25,6 +25,9 @@ class Elk(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # what linear algebra packages to use? the choices are # internal - use internal libraries # generic - use spack-provided blas and lapack diff --git a/var/spack/repos/builtin/packages/elmerfem/package.py b/var/spack/repos/builtin/packages/elmerfem/package.py index 3d8863054a56ba..6ddb0e642b4368 100644 --- a/var/spack/repos/builtin/packages/elmerfem/package.py +++ b/var/spack/repos/builtin/packages/elmerfem/package.py @@ -21,6 +21,10 @@ class Elmerfem(CMakePackage): version("9.0", sha256="08c5bf261e87ff37456c1aa0372db3c83efabe4473ea3ea0b8ec66f5944d1aa0") version("8.4", sha256="cc3ce807d76798361592cc14952cdc3db1ad8f9bac038017514033ce9badc5b3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("gui", default=False, description="Enable GUI support.") variant("mpi", default=True, description="Enable MPI support.") variant("openmp", default=True, description="Enable OpenMP support.") diff --git a/var/spack/repos/builtin/packages/elpa/package.py b/var/spack/repos/builtin/packages/elpa/package.py index 6965fe11177c5b..4088e3f2984a65 100644 --- a/var/spack/repos/builtin/packages/elpa/package.py +++ b/var/spack/repos/builtin/packages/elpa/package.py @@ -24,6 +24,9 @@ class Elpa(AutotoolsPackage, CudaPackage, ROCmPackage): version("master", branch="master") + version( + "2024.03.001", sha256="41c6cbf56d2dac26443faaba8a77307d261bf511682a64b96e24def77c813622" + ) version( "2023.11.001-patched", sha256="62ee109afc06539507f459c08b958dc4db65b757dbd77f927678c77f7687415e", @@ -46,12 +49,24 @@ class Elpa(AutotoolsPackage, CudaPackage, ROCmPackage): "2021.05.001", sha256="a4f1a4e3964f2473a5f8177f2091a9da5c6b5ef9280b8272dfefcbc3aad44d41" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=True, description="Activates OpenMP support") variant("mpi", default=True, description="Activates MPI support") + with when("@2021.11.001:"): + variant( + "autotune", default=False, description="Enables autotuning for matrix restribution" + ) + variant( + "gpu_streams", default=True, when="+cuda", description="Activates GPU streams support" + ) + patch("fujitsu.patch", when="%fj") - depends_on("autoconf", type="build", when="@master") + depends_on("autoconf@2.71:", type="build", when="@master") depends_on("automake", type="build", when="@master") depends_on("blas") @@ -61,12 +76,20 @@ class Elpa(AutotoolsPackage, CudaPackage, ROCmPackage): depends_on("rocblas", when="+rocm") depends_on("libtool", type="build") depends_on("python@3:", type="build") - - with when("@2021.11.01:"): - variant( - "autotune", default=False, description="Enables autotuning for matrix restribution" + depends_on("scalapack", when="+autotune") + + # Force openmp propagation on some providers of blas/lapack, as adviced by docs + # https://gitlab.mpcdf.mpg.de/elpa/elpa/-/blob/master/documentation/PERFORMANCE_TUNING.md?ref_type=heads#builds-with-openmp-enabled + with when("+openmp"): + requires("^openblas threads=openmp", when="^[virtuals=blas,lapack] openblas") + requires("^intel-mkl threads=openmp", when="^[virtuals=blas,lapack] intel-mkl") + requires( + "^intel-oneapi-mkl threads=openmp", when="^[virtuals=blas,lapack] intel-oneapi-mkl" + ) + requires( + "^intel-parallel-studio threads=openmp", + when="^[virtuals=blas,lapack] intel-parallel-studio", ) - depends_on("scalapack", when="+autotune") # fails to build due to broken type-bound procedures in OMP parallel regions conflicts( @@ -75,6 +98,11 @@ class Elpa(AutotoolsPackage, CudaPackage, ROCmPackage): msg="ELPA-2021.05.001+ requires GCC-8+ for OpenMP support", ) conflicts("+mpi", when="+rocm", msg="ROCm support and MPI are not yet compatible") + conflicts( + "+gpu_streams", + when="@:2023.11.001-patched +openmp", + msg="GPU streams currently not supported in combination with OpenMP", + ) def url_for_version(self, version): return "https://elpa.mpcdf.mpg.de/software/tarball-archive/Releases/{0}/elpa-{0}.tar.gz".format( @@ -115,6 +143,9 @@ def configure_args(self): options += self.with_or_without("mpi") + # New options use the "-kernels" suffix + kernels = "-kernels" if spec.satisfies("@2023.11:") else "" + # TODO: --disable-sse-assembly, --enable-sparc64, --enable-neon-arch64 # Don't include vsx; as of 2022.05 it fails (reported upstream). # Altivec SSE intrinsics are used anyway. @@ -122,7 +153,7 @@ def configure_args(self): for feature in simd_features: msg = "--enable-{0}" if feature in spec.target else "--disable-{0}" - options.append(msg.format(feature)) + options.append(msg.format(feature + kernels)) if spec.target.family != "x86_64": options.append("--disable-sse-assembly") @@ -133,7 +164,7 @@ def configure_args(self): # If no features are found, enable the generic ones if not any(f in spec.target for f in simd_features): - options.append("--enable-generic") + options.append("--enable-generic" + kernels) if self.compiler.name == "gcc": options.extend(["CFLAGS=-O3", "FCFLAGS=-O3 -ffree-line-length-none"]) @@ -150,10 +181,15 @@ def configure_args(self): cuda_flag = "nvidia-gpu" if "+cuda" in spec: prefix = spec["cuda"].prefix - options.append("--enable-{0}".format(cuda_flag)) + # Can't yet be changed to the new option --enable-nvidia-gpu-kernels + # https://github.com/marekandreas/elpa/issues/55 + options.append(f"--enable-{cuda_flag}") options.append("--with-cuda-path={0}".format(prefix)) options.append("--with-cuda-sdk-path={0}".format(prefix)) + if spec.satisfies("+gpu_streams"): + options.append("--enable-gpu-streams=nvidia") + cuda_arch = spec.variants["cuda_arch"].value[0] if cuda_arch != "none": @@ -161,25 +197,26 @@ def configure_args(self): "--with-{0}-compute-capability=sm_{1}".format(cuda_flag.upper(), cuda_arch) ) else: - options.append("--disable-{0}".format(cuda_flag)) + options.append(f"--disable-{cuda_flag}" + kernels) if "+rocm" in spec: + # Can't yet be changed to the new option --enable-amd-gpu-kernels + # https://github.com/marekandreas/elpa/issues/55 options.append("--enable-amd-gpu") options.append("CXX={0}".format(self.spec["hip"].hipcc)) + + if spec.satisfies("+gpu_streams"): + options.append("--enable-gpu-streams=amd") + elif "@2021.05.001:" in self.spec: - options.append("--disable-amd-gpu") + options.append("--disable-amd-gpu" + kernels) options += self.enable_or_disable("openmp") # Additional linker search paths and link libs - ldflags = [spec["blas"].libs.search_flags, spec["lapack"].libs.search_flags] + ldflags = [spec["blas"].libs.search_flags, spec["lapack"].libs.search_flags, "-lstdc++"] libs = [spec["lapack"].libs.link_flags, spec["blas"].libs.link_flags] - # If using blas with openmp support, link with openmp - # Needed for Spack-provided OneAPI MKL and for many externals - if self.spec["blas"].satisfies("threads=openmp"): - ldflags.append(self.compiler.openmp_flag) - options += [f'LDFLAGS={" ".join(ldflags)}', f'LIBS={" ".join(libs)}'] if "+mpi" in self.spec: diff --git a/var/spack/repos/builtin/packages/elsd/package.py b/var/spack/repos/builtin/packages/elsd/package.py index 1e2c68116d9f72..14ec21867828bf 100644 --- a/var/spack/repos/builtin/packages/elsd/package.py +++ b/var/spack/repos/builtin/packages/elsd/package.py @@ -16,6 +16,8 @@ class Elsd(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("blas") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/elsdc/package.py b/var/spack/repos/builtin/packages/elsdc/package.py index 2edb0fddf65076..fe26f1cec3f6e5 100644 --- a/var/spack/repos/builtin/packages/elsdc/package.py +++ b/var/spack/repos/builtin/packages/elsdc/package.py @@ -16,6 +16,8 @@ class Elsdc(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("blas") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/elsi/package.py b/var/spack/repos/builtin/packages/elsi/package.py index 5c6da3eef68fa9..25b87e28293210 100644 --- a/var/spack/repos/builtin/packages/elsi/package.py +++ b/var/spack/repos/builtin/packages/elsi/package.py @@ -4,21 +4,38 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) import os.path +from spack.error import NoHeadersError from spack.package import * -class Elsi(CMakePackage): +class Elsi(CMakePackage, CudaPackage): """ELSI provides a unified interface for electronic structure codes to a variety of eigenvalue solvers.""" homepage = "https://wordpress.elsi-interchange.org/" - url = "https://wordpress.elsi-interchange.org/wp-content/uploads/2019/03/elsi-2.2.1.tar.gz" + url = "https://gitlab.com/elsi_project/elsi_interface/-/archive/v2.10.1/elsi_interface-v2.10.1.tar.gz" + git = "https://gitlab.com/elsi_project/elsi_interface.git" license("BSD-3-Clause") - version("2.2.1", sha256="5b4b2e8fa4b3b68131fe02cc1803a884039b89a1b1138af474af66453bec0b4d") + version("2.10.1", sha256="b3c7526d46a9139a26680787172a3df15bc648715a35bdf384053231e94ab829") + version( + "2.2.1", + sha256="5b4b2e8fa4b3b68131fe02cc1803a884039b89a1b1138af474af66453bec0b4d", + deprecated=True, + ) + version("master", branch="master") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated - variant("add_underscore", default=True, description="Suffix C functions with an underscore") + variant( + "add_underscore", + default=True, + description="Suffix C functions with an underscore", + when="@2.2.1", + ) variant( "elpa2_kernel", default="none", @@ -28,29 +45,93 @@ class Elsi(CMakePackage): ) variant("enable_pexsi", default=False, description="Enable PEXSI support") variant("enable_sips", default=False, description="Enable SLEPc-SIPs support") - variant("use_external_elpa", default=False, description="Build ELPA using SPACK") - variant("use_external_ntpoly", default=False, description="Build NTPoly using SPACK") - variant("use_external_omm", default=False, description="Use external libOMM and MatrixSwitch") - variant("use_external_superlu", default=False, description="Use external SuperLU DIST") + variant("use_external_elpa", default=True, description="Build ELPA using SPACK") + variant("use_external_ntpoly", default=True, description="Build NTPoly using SPACK") + variant( + "use_external_superlu", default=True, description="Use external SuperLU DIST", when="@:2.2" + ) variant( - "use_mpi_iallgather", default=True, description="Use non-blocking collective MPI functions" + "use_external_pexsi", + default=True, + description="Use external PEXSI", + when="@2.3: +enable_pexsi", + ) + variant("use_external_omm", default=True, description="Use external libOMM") + variant( + "use_mpi_iallgather", + default=True, + description="Use non-blocking collective MPI functions", + when="@:2.5", + ) + variant( + "internal_elpa_version", + default="2024", + values=("2024", "2023_11", "2023", "2021", "2020"), + description="Internal ELPA version", + multi=False, ) # Basic dependencies depends_on("blas", type="link") depends_on("lapack", type="link") - depends_on("cmake", type="build") - depends_on("mpi") depends_on("scalapack", type="link") + depends_on("mpi") # Library dependencies - depends_on("elpa", when="+use_external_elpa") depends_on("ntpoly", when="+use_external_ntpoly") - depends_on("slepc", when="+enable_sips") - depends_on("petsc", when="+enable_sips") - depends_on("superlu-dist", when="+use_external_superlu") + with when("+use_external_elpa"): + depends_on("elpa+cuda", when="+cuda") + depends_on("elpa~cuda", when="~cuda") + with when("+enable_sips"): + depends_on("slepc+cuda", when="+cuda") + depends_on("slepc~cuda", when="~cuda") + depends_on("petsc+cuda", when="+cuda") + depends_on("petsc~cuda", when="~cuda") + with when("+use_external_superlu"): + depends_on("superlu-dist+cuda", when="+cuda") + depends_on("superlu-dist~cuda", when="~cuda") + with when("+enable_pexsi +use_external_pexsi"): + depends_on("pexsi+fortran") + depends_on("superlu-dist+cuda", when="+cuda") + depends_on("superlu-dist~cuda", when="~cuda") + with when("+use_external_omm"): + depends_on("omm") + depends_on("matrix-switch") # Direct dependency def cmake_args(self): + libs_names = ["scalapack", "lapack", "blas"] + + # External libraries + if self.spec.satisfies("+use_external_elpa"): + libs_names.append("elpa") + if self.spec.satisfies("+use_external_ntpoly"): + libs_names.append("ntpoly") + if self.spec.satisfies("+use_external_superlu"): + libs_names.append("superlu-dist") + if self.spec.satisfies("+use_external_pexsi"): + libs_names.append("superlu-dist") + libs_names.append("pexsi") + if self.spec.satisfies("+use_external_omm"): + libs_names.append("omm") + libs_names.append("matrix-switch") + + lib_paths, inc_paths, libs = [], [], [] + for lib in libs_names: + lib_paths.extend(self.spec[lib].libs.directories) + libs.extend(self.spec[lib].libs.names) + + try: + inc_paths.extend(self.spec[lib].headers.directories) + + # Deal with Fortran modules + for path in self.spec[lib].headers: + # Add path to .mod files + # headers.directories only add path up to include/ + if path.endswith(".mod"): + inc_paths.append(os.path.dirname(path)) + except NoHeadersError: + pass + args = [ # Compiler Information (ELSI wants these explicitly set) self.define("CMAKE_Fortran_COMPILER", self.spec["mpi"].mpifc), @@ -63,15 +144,24 @@ def cmake_args(self): self.define_from_variant("USE_EXTERNAL_NTPOLY", "use_external_ntpoly"), self.define_from_variant("USE_EXTERNAL_OMM", "use_external_omm"), self.define_from_variant("USE_EXTERNAL_SUPERLU", "use_external_superlu"), + self.define_from_variant("USE_EXTERNAL_PEXSI", "use_external_pexsi"), self.define_from_variant("USE_MPI_IALLGATHER", "use_mpi_iallgather"), + self.define("ENABLE_TESTS", self.run_tests), + self.define("ENABLE_C_TESTS", self.run_tests), + self.define_from_variant("USE_GPU_CUDA", "cuda"), + self.define("LIB_PATHS", ";".join(set(lib_paths))), + self.define("LIBS", ";".join(set(libs))), ] + if not self.spec.satisfies("+use_external_elpa"): + args.append( + self.define(f"USE_ELPA_{self.spec.variants['internal_elpa_version'].value}", True) + ) + if self.spec.variants["elpa2_kernel"].value != "none": args.append(self.define_from_variant("ELPA2_KERNEL", "elpa2_kernel")) - if self.spec.satisfies("+use_external_elpa"): - elpa_module = find(self.spec["elpa"].prefix, "elpa.mod") - args.append(self.define("INC_PATHS", os.path.dirname(elpa_module[0]))) + args.append(self.define("INC_PATHS", ";".join(set(inc_paths)))) # Only when using fujitsu compiler if self.spec.satisfies("%fj"): diff --git a/var/spack/repos/builtin/packages/emacs/package.py b/var/spack/repos/builtin/packages/emacs/package.py index 765bd6a7040f9a..993f08428a1846 100644 --- a/var/spack/repos/builtin/packages/emacs/package.py +++ b/var/spack/repos/builtin/packages/emacs/package.py @@ -21,6 +21,7 @@ class Emacs(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-or-later") version("master", branch="master") + version("29.3", sha256="2de8df5cab8ac697c69a1c46690772b0cf58fe7529f1d1999582c67d927d22e4") version("29.2", sha256="ac8773eb17d8b3c0c4a3bccbb478f7c359266b458563f9a5e2c23c53c05e4e59") version("29.1", sha256="5b80e0475b0e619d2ad395ef5bc481b7cb9f13894ed23c301210572040e4b5b1") version("28.2", sha256="a6912b14ef4abb1edab7f88191bfd61c3edd7085e084de960a4f86485cb7cad8") @@ -35,6 +36,10 @@ class Emacs(AutotoolsPackage, GNUMirrorPackage): version("25.1", sha256="763344b90db4d40e9fe90c5d14748a9dbd201ce544e2cf0835ab48a0aa4a1c67") version("24.5", sha256="2737a6622fb2d9982e9c47fb6f2fb297bda42674e09db40fc9bcc0db4297c3b6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("X", default=False, description="Enable an X toolkit") variant( "toolkit", @@ -42,6 +47,7 @@ class Emacs(AutotoolsPackage, GNUMirrorPackage): values=("gtk", "athena"), description="Select an X toolkit (gtk, athena)", ) + variant("gui", default=False, description="Enable GUI build on Mac") variant("tls", default=True, description="Build Emacs with gnutls") variant("native", default=False, when="@28:", description="enable native compilation of elisp") variant("treesitter", default=False, when="@29:", description="Build with tree-sitter support") @@ -90,10 +96,13 @@ def configure_args(self): else: args = ["--without-x"] - # On OS X/macOS, do not build "nextstep/Emacs.app", because - # doing so throws an error at build-time if sys.platform == "darwin": - args.append("--without-ns") + if spec.satisfies("+gui"): + # Do not build the self-contained "nextstep/Emacs.app" + args.append("--disable-ns-self-contained") + else: + # Do not build "nextstep/Emacs.app" at all + args.append("--without-ns") args += self.with_or_without("native-compilation", variant="native") args += self.with_or_without("gnutls", variant="tls") @@ -102,6 +111,15 @@ def configure_args(self): return args + @run_after("install") + def move_macos_app(self): + """Move the Emacs.app build on MacOS to /Applications. + From there users can move it or link it in ~/Applications.""" + if sys.platform == "darwin" and "+gui" in self.spec: + apps_dir = join_path(self.prefix, "Applications") + mkdir(apps_dir) + move("nextstep/Emacs.app", apps_dir) + def run_version_check(self, bin): """Runs and checks output of the installed binary.""" exe_path = join_path(self.prefix.bin, bin) diff --git a/var/spack/repos/builtin/packages/ember/package.py b/var/spack/repos/builtin/packages/ember/package.py index 3f3bf23dcfd18f..a010792a6353f7 100644 --- a/var/spack/repos/builtin/packages/ember/package.py +++ b/var/spack/repos/builtin/packages/ember/package.py @@ -24,6 +24,8 @@ class Ember(MakefilePackage): version("1.0.0", sha256="5b2a6b8055b46ab3ea2c7baabaf4d280d837bb7c21eba0c9f59e092c6fc1c4a6") + depends_on("c", type="build") # generated + depends_on("mpi") # TODO: shmem variant disabled due to lack of shmem spackage diff --git a/var/spack/repos/builtin/packages/emboss/package.py b/var/spack/repos/builtin/packages/emboss/package.py index 387e4f34646c67..a02570a1dea788 100644 --- a/var/spack/repos/builtin/packages/emboss/package.py +++ b/var/spack/repos/builtin/packages/emboss/package.py @@ -18,6 +18,8 @@ class Emboss(AutotoolsPackage): version("6.6.0", sha256="7184a763d39ad96bb598bfd531628a34aa53e474db9e7cac4416c2a40ab10c6e") + depends_on("c", type="build") # generated + depends_on("libxpm") depends_on("libgd") depends_on("postgresql") diff --git a/var/spack/repos/builtin/packages/embree/package.py b/var/spack/repos/builtin/packages/embree/package.py index eea9a804ac06f9..2ad0c8bd77ffff 100644 --- a/var/spack/repos/builtin/packages/embree/package.py +++ b/var/spack/repos/builtin/packages/embree/package.py @@ -36,6 +36,9 @@ class Embree(CMakePackage): version("3.8.0", sha256="40cbc90640f63c318e109365d29aea00003e4bd14aaba8bb654fc1010ea5753a") version("3.7.0", sha256="2b6300ebe30bb3d2c6e5f23112b4e21a25a384a49c5e3c35440aa6f3c8d9fe84") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("ispc", default=True, description="Enable ISPC support") depends_on("ispc", when="+ispc", type="build") diff --git a/var/spack/repos/builtin/packages/enca/package.py b/var/spack/repos/builtin/packages/enca/package.py index 8d3d67ca8e69d9..f784a79af25759 100644 --- a/var/spack/repos/builtin/packages/enca/package.py +++ b/var/spack/repos/builtin/packages/enca/package.py @@ -19,6 +19,8 @@ class Enca(AutotoolsPackage): version("1.17", sha256="b20372440c500e6463bd61dab0e68131cdfe857c6b7ca139b5c6cbf01e24fdc7") version("1.16", sha256="14457b185c77b947ca2f8e09a2c3ec66940d97a2ccea28b8e61a6e0f3a0033f6") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/enchant/package.py b/var/spack/repos/builtin/packages/enchant/package.py index b32545e730bd1e..ca045bb5f80594 100644 --- a/var/spack/repos/builtin/packages/enchant/package.py +++ b/var/spack/repos/builtin/packages/enchant/package.py @@ -30,6 +30,9 @@ class Enchant(AutotoolsPackage): version("2.1.1", sha256="5fad0a1e82ddfed91647e93da5955fc76249760fd51865648a36074dc97d526c") version("2.1.0", sha256="2cdda2d9edb62ad895c34be35c598d56ac5b9b9298f3dfdaa2b40a1914d1db7e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("hunspell", default=True, description="Enables hunspell backend") depends_on("glib") diff --git a/var/spack/repos/builtin/packages/energyplus/package.py b/var/spack/repos/builtin/packages/energyplus/package.py index c0c1774edc0f2b..efae17adbf76d9 100644 --- a/var/spack/repos/builtin/packages/energyplus/package.py +++ b/var/spack/repos/builtin/packages/energyplus/package.py @@ -34,6 +34,9 @@ class Energyplus(Package): url="https://github.com/NREL/EnergyPlus/releases/download/v8.9.0-WithIDDFixes/EnergyPlus-8.9.0-eba93e8e1b-Linux-x86_64.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): # binary distribution, we just unpack to lib/energyplus # and then symlink the appropriate targets diff --git a/var/spack/repos/builtin/packages/ensmallen/package.py b/var/spack/repos/builtin/packages/ensmallen/package.py index 606bf98b7c0c5c..921c97535a5d9e 100644 --- a/var/spack/repos/builtin/packages/ensmallen/package.py +++ b/var/spack/repos/builtin/packages/ensmallen/package.py @@ -24,6 +24,8 @@ class Ensmallen(CMakePackage): version("2.21.1", sha256="820eee4d8aa32662ff6a7d883a1bcaf4e9bf9ca0a3171d94c5398fe745008750") version("2.19.1", sha256="f36ad7f08b0688d2a8152e1c73dd437c56ed7a5af5facf65db6ffd977b275b2e") + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Use OpenMP for parallelization") depends_on("cmake@3.3.2:") diff --git a/var/spack/repos/builtin/packages/entt/package.py b/var/spack/repos/builtin/packages/entt/package.py index 073626ca959fb3..1ebfab0249a9c5 100644 --- a/var/spack/repos/builtin/packages/entt/package.py +++ b/var/spack/repos/builtin/packages/entt/package.py @@ -16,10 +16,13 @@ class Entt(CMakePackage): license("MIT") + version("3.13.2", sha256="cb556aa543d01177b62de41321759e02d96078948dda72705b3d7fe68af88489") version("3.13.1", sha256="a4f290b601a70333126abd2cec7b0c232c74a4f85dcf1e04d969e8122dae8652") version("3.11.1", sha256="0ac010f232d3089200c5e545bcbd6480cf68b705de6930d8ff7cdb0a29f5b47b") version("3.5.2", sha256="f9271293c44518386c402c9a2188627819748f66302df48af4f6d08e30661036") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.7.0:", type="build") depends_on("doxygen@1.8.0:", type="build") @@ -30,4 +33,4 @@ class Entt(CMakePackage): conflicts("%gcc@:7.1", msg=compiler_warning) def cmake_args(self): - return ["-DBUILD_DOCS=ON"] + return [self.define("BUILD_DOCS", "ON")] diff --git a/var/spack/repos/builtin/packages/environment-modules/package.py b/var/spack/repos/builtin/packages/environment-modules/package.py index 351191187874d1..3bd8426794234e 100644 --- a/var/spack/repos/builtin/packages/environment-modules/package.py +++ b/var/spack/repos/builtin/packages/environment-modules/package.py @@ -58,6 +58,8 @@ class EnvironmentModules(Package): url="http://prdownloads.sourceforge.net/modules/modules-3.2.10.tar.gz", ) + depends_on("c", type="build") # generated + variant("X", default=True, description="Build with X functionality") depends_on("less", type=("build", "run"), when="@4.1:") diff --git a/var/spack/repos/builtin/packages/enzo/package.py b/var/spack/repos/builtin/packages/enzo/package.py index b8498d08626432..fa4c5fd8bcaf9f 100644 --- a/var/spack/repos/builtin/packages/enzo/package.py +++ b/var/spack/repos/builtin/packages/enzo/package.py @@ -17,6 +17,10 @@ class Enzo(MakefilePackage): version("master", branch="main", deprecated=True) version("2.6.1", sha256="280270accfc1ddb60e92cc98ca538a3e5787e8cc93ed58fb5c3ab75db8c4b048") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("hdf5~mpi") depends_on("sse2neon", when="target=aarch64:") diff --git a/var/spack/repos/builtin/packages/enzyme/package.py b/var/spack/repos/builtin/packages/enzyme/package.py index ab1db23e04ba0b..c793e1edddb7b2 100644 --- a/var/spack/repos/builtin/packages/enzyme/package.py +++ b/var/spack/repos/builtin/packages/enzyme/package.py @@ -24,6 +24,7 @@ class Enzyme(CMakePackage): root_cmakelists_dir = "enzyme" version("main", branch="main") + version("0.0.135", sha256="49c798534faec7ba524a3ed053dd4352d690a44d3cad5a14915c9398dc9b175b") version("0.0.100", sha256="fbc53ec02adc0303ff200d7699afface2d9fbc7350664e6c6d4c527ef11c2e82") version("0.0.81", sha256="4c17d0c28f0572a3ab97a60f1e56bbc045ed5dd64c2daac53ae34371ca5e8b34") version("0.0.69", sha256="144d964187551700fdf0a4807961ceab1480d4e4cd0bb0fc7bbfab48fe053aa2") @@ -33,6 +34,10 @@ class Enzyme(CMakePackage): version("0.0.14", sha256="740641eeeeadaf47942ac88cc52e62ddc0e8c25767a501bed36ec241cf258b8d") version("0.0.13", sha256="d4a53964ec1f763772db2c56e6734269b7656c8b2ecd41fa7a41315bcd896b5a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("llvm@7:12", when="@0.0.13:0.0.15") depends_on("llvm@7:14", when="@0.0.32:0.0.47") depends_on("llvm@7:14", when="@0.0.48:0.0.68") diff --git a/var/spack/repos/builtin/packages/eospac/package.py b/var/spack/repos/builtin/packages/eospac/package.py index e21b62f109f273..bcf8f62a713504 100644 --- a/var/spack/repos/builtin/packages/eospac/package.py +++ b/var/spack/repos/builtin/packages/eospac/package.py @@ -23,8 +23,18 @@ class Eospac(Package): # - alpha and beta versions are marked with 'deprecated=True' to help # spack's version comparison. version( - "6.5.7", + "6.5.9", preferred=True, + sha256="54df29b1dc3b35c654ef2ebfbfa42d960a230cfb2d3c04a75ba93d3a789a312a", + url="https://laws.lanl.gov/projects/data/eos/get_file.php?package=eospac&filename=eospac_v6.5.9_4c633156bacc7b721bdd2735e40e09984a4d60a3.tgz", + ) + version( + "6.5.8", + sha256="4e2c5db150bf7f45b5615c034848b9256f8659bcde95f097e446c226c70c6d96", + url="https://laws.lanl.gov/projects/data/eos/get_file.php?package=eospac&filename=eospac_v6.5.8_052127ccd65148632bd1258764f455c692a4dfc1.tgz", + ) + version( + "6.5.7", sha256="e59bd449bf97ce977309c6fc8a54fa30f4db9b2ca3e21f996095d78e23799e42", url="https://laws.lanl.gov/projects/data/eos/get_file.php?package=eospac&filename=eospac_v6.5.7_9a867a15ae4137d22e1b52199d6a46b486fc4376.tgz", ) @@ -118,6 +128,10 @@ class Eospac(Package): url="http://laws.lanl.gov/projects/data/eos/get_file.php?package=eospac&filename=eospac_v6.3.1_r20161202150449.tgz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # This patch allows the use of spack's compile wrapper 'flang' patch("flang.patch", when="@:6.4.0beta.2%clang") patch("frt.patch", when="%fj") diff --git a/var/spack/repos/builtin/packages/epics-base/package.py b/var/spack/repos/builtin/packages/epics-base/package.py index 2509eab83eb850..b08a31b7328f90 100644 --- a/var/spack/repos/builtin/packages/epics-base/package.py +++ b/var/spack/repos/builtin/packages/epics-base/package.py @@ -20,6 +20,9 @@ class EpicsBase(MakefilePackage): version("7.0.6.1", sha256="8ff318f25e2b70df466f933636a2da85e4b0c841504b9e89857652a4786b6387") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("readline") depends_on("perl", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/epics-ca-gateway/package.py b/var/spack/repos/builtin/packages/epics-ca-gateway/package.py index fbaf1dc9613343..8b6ba207834d1f 100644 --- a/var/spack/repos/builtin/packages/epics-ca-gateway/package.py +++ b/var/spack/repos/builtin/packages/epics-ca-gateway/package.py @@ -21,6 +21,8 @@ class EpicsCaGateway(MakefilePackage): version("2.1.3", sha256="f6e9dba46951a168d3208fc57054138759d56ebd8a7c07b496e8f5b8a56027d7") + depends_on("cxx", type="build") # generated + depends_on("epics-base") depends_on("epics-pcas") diff --git a/var/spack/repos/builtin/packages/epics-pcas/package.py b/var/spack/repos/builtin/packages/epics-pcas/package.py index 14e02f0a09f5d8..f745369ed35f30 100644 --- a/var/spack/repos/builtin/packages/epics-pcas/package.py +++ b/var/spack/repos/builtin/packages/epics-pcas/package.py @@ -18,6 +18,9 @@ class EpicsPcas(MakefilePackage): version("4.13.3", sha256="5004e39339c8e592fcb9b4275c84143635c6e688c0fbe01f17dafe19850398a0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("epics-base", type=("build", "link", "run")) @property diff --git a/var/spack/repos/builtin/packages/eprosima-fastcdr/package.py b/var/spack/repos/builtin/packages/eprosima-fastcdr/package.py index d5b096e49089d7..8cdb0d4f7f0d9f 100644 --- a/var/spack/repos/builtin/packages/eprosima-fastcdr/package.py +++ b/var/spack/repos/builtin/packages/eprosima-fastcdr/package.py @@ -16,5 +16,8 @@ class EprosimaFastcdr(CMakePackage): license("Apache-2.0") + version("2.2.1", sha256="11079a534cda791a8fc28d93ecb518bbd3804c0d4e9ca340ab24dcc21ad69a04") version("2.2.0", sha256="8a75ee3aed59f495e95208050920d2c2146df92f073809505a3bd29011c21f20") version("1.0.27", sha256="a9bc8fd31a2c2b95e6d2fb46e6ce1ad733e86dc4442f733479e33ed9cdc54bf6") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/eprosima-fastdds/package.py b/var/spack/repos/builtin/packages/eprosima-fastdds/package.py index 3af859c1fffa40..bf139fb5e7b3a6 100644 --- a/var/spack/repos/builtin/packages/eprosima-fastdds/package.py +++ b/var/spack/repos/builtin/packages/eprosima-fastdds/package.py @@ -20,6 +20,9 @@ class EprosimaFastdds(CMakePackage): version("2.10.1", sha256="2cc2682db5dc7e87684b7f23166e2f32faf8d5c4b4a8c94c6c21211a8a38f553") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("asio") depends_on("tinyxml2") depends_on("openssl") diff --git a/var/spack/repos/builtin/packages/epsic/package.py b/var/spack/repos/builtin/packages/epsic/package.py index 16144c585d1bf9..65cd58256b9bc4 100644 --- a/var/spack/repos/builtin/packages/epsic/package.py +++ b/var/spack/repos/builtin/packages/epsic/package.py @@ -19,6 +19,8 @@ class Epsic(AutotoolsPackage): # https://github.com/lwa-project/pulsar/blob/master/SoftwareStack.md # last updated 10/17/2020 version("LWA-10-17-2020", commit="5315cc634f6539ea0a34e403e492472b97e0f086") + + depends_on("cxx", type="build") # generated depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("yacc", when="@develop", type="build") diff --git a/var/spack/repos/builtin/packages/eq-r/package.py b/var/spack/repos/builtin/packages/eq-r/package.py index 81670ed8db7347..077a13db46dd11 100644 --- a/var/spack/repos/builtin/packages/eq-r/package.py +++ b/var/spack/repos/builtin/packages/eq-r/package.py @@ -22,6 +22,8 @@ class EqR(AutotoolsPackage): version("1.0", sha256="68047cb0edf088eaaefc5e36cefda9818292e5c832593e10a1dd9c73c27661b6") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/er/package.py b/var/spack/repos/builtin/packages/er/package.py index 6fed09c5e6bdc1..499091390e7c7f 100644 --- a/var/spack/repos/builtin/packages/er/package.py +++ b/var/spack/repos/builtin/packages/er/package.py @@ -26,6 +26,8 @@ class Er(CMakePackage): version("0.0.4", sha256="c456d34719bb57774adf6d7bc2fa9917ecb4a9de442091023c931a2cb83dfd37") version("0.0.3", sha256="243b2b46ea274e17417ef5873c3ed7ba16dacdfdaf7053d1de5434e300de796b") + depends_on("c", type="build") # generated + depends_on("mpi") depends_on("kvtree+mpi") depends_on("rankstr", when="@0.0.4:") @@ -65,8 +67,5 @@ def cmake_args(self): if spec.satisfies("@0.1.0:"): args.append(self.define_from_variant("BUILD_SHARED_LIBS", "shared")) - else: - if spec.satisfies("platform=cray"): - args.append(self.define("ER_LINK_STATIC", True)) return args diff --git a/var/spack/repos/builtin/packages/erfa/package.py b/var/spack/repos/builtin/packages/erfa/package.py index b1132258d41dc0..d5105430566b07 100644 --- a/var/spack/repos/builtin/packages/erfa/package.py +++ b/var/spack/repos/builtin/packages/erfa/package.py @@ -16,3 +16,5 @@ class Erfa(AutotoolsPackage): version("2.0.0", sha256="75cb0a2cc1561d24203d9d0e67c21f105e45a70181d57f158e64a46a50ccd515") version("1.7.0", sha256="f0787e30e848750c0cbfc14827de6fc7f69a2d5ef0fc653504e74b8967a764e0") version("1.4.0", sha256="035b7f0ad05c1191b8588191ba4b19ba0f31afa57ad561d33bd5417d9f23e460") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/erlang/package.py b/var/spack/repos/builtin/packages/erlang/package.py index e21d2d736d6917..7a6b4b1db579fd 100644 --- a/var/spack/repos/builtin/packages/erlang/package.py +++ b/var/spack/repos/builtin/packages/erlang/package.py @@ -31,6 +31,8 @@ class Erlang(AutotoolsPackage): version("21.3", sha256="69a743c4f23b2243e06170b1937558122142e47c8ebe652be143199bfafad6e4") version("21.2", sha256="f6b07bf8e6705915679a63363ce80faaa6b7c231e7236cde443d6445f7430334") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("m4", type="build") diff --git a/var/spack/repos/builtin/packages/erne/package.py b/var/spack/repos/builtin/packages/erne/package.py index dee89bebb8af5e..385cf0876eb36c 100644 --- a/var/spack/repos/builtin/packages/erne/package.py +++ b/var/spack/repos/builtin/packages/erne/package.py @@ -16,6 +16,9 @@ class Erne(AutotoolsPackage): version("2.1.1", sha256="f32ab48481fd6c129b0a0246ab02b6e3a2a9da84024e1349510a59c15425d983") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Build with OpenMPI support") depends_on( diff --git a/var/spack/repos/builtin/packages/es-shell/package.py b/var/spack/repos/builtin/packages/es-shell/package.py index 79c23768054417..ca7a8104e0178c 100644 --- a/var/spack/repos/builtin/packages/es-shell/package.py +++ b/var/spack/repos/builtin/packages/es-shell/package.py @@ -20,5 +20,7 @@ class EsShell(AutotoolsPackage): version("0.9.1", sha256="b0b41fce99b122a173a06b899a4d92e5bd3cc48b227b2736159f596a58fff4ba") + depends_on("c", type="build") # generated + depends_on("readline") depends_on("yacc") diff --git a/var/spack/repos/builtin/packages/esmf/package.py b/var/spack/repos/builtin/packages/esmf/package.py index 8de04de89bbea2..42ef7a52b2ca62 100644 --- a/var/spack/repos/builtin/packages/esmf/package.py +++ b/var/spack/repos/builtin/packages/esmf/package.py @@ -29,6 +29,7 @@ class Esmf(MakefilePackage): # Develop is a special name for spack and is always considered the newest version version("develop", branch="develop") # generate chksum with 'spack checksum esmf@x.y.z' + version("8.6.1", sha256="dc270dcba1c0b317f5c9c6a32ab334cb79468dda283d1e395d98ed2a22866364") version("8.6.0", sha256="ed057eaddb158a3cce2afc0712b49353b7038b45b29aee86180f381457c0ebe7") version("8.5.0", sha256="acd0b2641587007cc3ca318427f47b9cae5bfd2da8d2a16ea778f637107c29c4") version("8.4.2", sha256="969304efa518c7859567fa6e65efd960df2b4f6d72dbf2c3f29e39e4ab5ae594") @@ -64,6 +65,10 @@ class Esmf(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Build with MPI support") variant("external-lapack", default=False, description="Build with external LAPACK library") variant("netcdf", default=True, description="Build with NetCDF support") @@ -329,9 +334,8 @@ def setup_build_environment(self, env): # ESMF code. env.set("ESMF_LAPACK", "system") - # FIXME: determine whether or not we need to set this # Specifies the path where the LAPACK library is located. - # env.set("ESMF_LAPACK_LIBPATH", spec["lapack"].prefix.lib) + env.set("ESMF_LAPACK_LIBPATH", spec["lapack"].prefix.lib) # Specifies the linker directive needed to link the LAPACK library # to the application. diff --git a/var/spack/repos/builtin/packages/esys-particle/package.py b/var/spack/repos/builtin/packages/esys-particle/package.py index 0475d965d8fa85..7021384dd9d75e 100644 --- a/var/spack/repos/builtin/packages/esys-particle/package.py +++ b/var/spack/repos/builtin/packages/esys-particle/package.py @@ -21,6 +21,8 @@ class EsysParticle(CMakePackage): version("3.0-alpha", sha256="4fba856a95c93991cacb904e6a54a7ded93558f7adc8c3e6da99bc347843a434") + depends_on("cxx", type="build") # generated + depends_on("mpi") depends_on("boost@1.71.0+python") depends_on("python@3.6:") diff --git a/var/spack/repos/builtin/packages/ethminer/package.py b/var/spack/repos/builtin/packages/ethminer/package.py index ae28904c544981..35a564e6ff10aa 100644 --- a/var/spack/repos/builtin/packages/ethminer/package.py +++ b/var/spack/repos/builtin/packages/ethminer/package.py @@ -17,6 +17,9 @@ class Ethminer(CMakePackage): version("0.12.0", sha256="71122c8aa1be2c29e46d7f07961fa760b1eb390e4d9a2a21cf900f6482a8755a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("opencl", default=True, description="Enable OpenCL mining.") variant("cuda", default=False, description="Enable CUDA mining.") variant("stratum", default=True, description="Build with Stratum protocol support.") diff --git a/var/spack/repos/builtin/packages/ethtool/package.py b/var/spack/repos/builtin/packages/ethtool/package.py index da8800471b0704..04f9bcddda9730 100644 --- a/var/spack/repos/builtin/packages/ethtool/package.py +++ b/var/spack/repos/builtin/packages/ethtool/package.py @@ -17,6 +17,8 @@ class Ethtool(AutotoolsPackage): version("4.8", sha256="e4443c612b01b6c4891e21f55a59aa2d6da1c9915edcf067bb66a0855590e143") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/etsf-io/package.py b/var/spack/repos/builtin/packages/etsf-io/package.py index df30e5e257a594..6cd2476ec34d68 100644 --- a/var/spack/repos/builtin/packages/etsf-io/package.py +++ b/var/spack/repos/builtin/packages/etsf-io/package.py @@ -22,6 +22,8 @@ class EtsfIo(Package): version("1.0.4", sha256="3140c2cde17f578a0e6b63acb27a5f6e9352257a1371a17b9c15c3d0ef078fa4") + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Add MPI support") depends_on("netcdf-fortran") diff --git a/var/spack/repos/builtin/packages/eve/package.py b/var/spack/repos/builtin/packages/eve/package.py index aa0da87e422ca9..76dcd756322cb6 100644 --- a/var/spack/repos/builtin/packages/eve/package.py +++ b/var/spack/repos/builtin/packages/eve/package.py @@ -24,3 +24,5 @@ class Eve(CMakePackage): version("2022.09.0", sha256="53a4e1944a1080c67380a6d7f4fb42998f1c1db35e2370e02d7853c3ac1e0a33") version("2022.03.0", sha256="8bf9faea516806e7dd468e778dcedc81c51f0b2c6a70b9c75987ce12bb759911") version("2021.10.0", sha256="580c40a8244039a700b93ea49fb0affc1c8d3c100eb6dc66368e101753f51e5c") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/everytrace-example/package.py b/var/spack/repos/builtin/packages/everytrace-example/package.py index 4ea4c237b67c31..28529bd9108dd1 100644 --- a/var/spack/repos/builtin/packages/everytrace-example/package.py +++ b/var/spack/repos/builtin/packages/everytrace-example/package.py @@ -16,6 +16,8 @@ class EverytraceExample(CMakePackage): version("develop", branch="develop") + depends_on("cxx", type="build") # generated + depends_on("everytrace+mpi+fortran") # Currently the only MPI this everytrace works with. diff --git a/var/spack/repos/builtin/packages/everytrace/package.py b/var/spack/repos/builtin/packages/everytrace/package.py index 3e5c1d9c88ee4b..9ab3a30868735f 100644 --- a/var/spack/repos/builtin/packages/everytrace/package.py +++ b/var/spack/repos/builtin/packages/everytrace/package.py @@ -20,6 +20,10 @@ class Everytrace(CMakePackage): version("develop", branch="develop") version("0.2.2", sha256="0487276bb24e648388862d8e1d8cfe56b529f7e3d840df3fcb5b3a3dad4016e1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enables MPI parallelism") variant("fortran", default=True, description="Enable use with Fortran programs") variant("cxx", default=True, description="Enable C++ Exception-based features") diff --git a/var/spack/repos/builtin/packages/evtgen/package.py b/var/spack/repos/builtin/packages/evtgen/package.py index 51b12f1111869e..093f029ab88afd 100644 --- a/var/spack/repos/builtin/packages/evtgen/package.py +++ b/var/spack/repos/builtin/packages/evtgen/package.py @@ -27,6 +27,8 @@ class Evtgen(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + variant("pythia8", default=True, description="Build with pythia8") variant("tauola", default=False, description="Build with tauola") variant("photos", default=False, description="Build with photos") diff --git a/var/spack/repos/builtin/packages/exabayes/package.py b/var/spack/repos/builtin/packages/exabayes/package.py index ce1937dc1f8ae7..3ffb5122fa3a38 100644 --- a/var/spack/repos/builtin/packages/exabayes/package.py +++ b/var/spack/repos/builtin/packages/exabayes/package.py @@ -19,6 +19,9 @@ class Exabayes(AutotoolsPackage): version("1.5.1", sha256="f75ce8d5cee4d241cadacd0f5f5612d783b9e9babff2a99c7e0c3819a94bbca9") version("1.5", sha256="e401f1b4645e67e8879d296807131d0ab79bba81a1cd5afea14d7c3838b095a2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Enable MPI parallel support") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin/packages/exaca/package.py b/var/spack/repos/builtin/packages/exaca/package.py index b1fd6416b9fdf3..ce79d0ad6bd46e 100644 --- a/var/spack/repos/builtin/packages/exaca/package.py +++ b/var/spack/repos/builtin/packages/exaca/package.py @@ -25,6 +25,8 @@ class Exaca(CMakePackage): version("1.1.0", sha256="10106fb1836964a19bc5bab3f374baa24188ba786c768e554442ab896b31ff24") version("1.0.0", sha256="48556233360a5e15e1fc20849e57dd60739c1991c7dfc7e6b2956af06688b96a") + depends_on("cxx", type="build") # generated + _kokkos_backends = Kokkos.devices_variants for _backend in _kokkos_backends: _deflt, _descr = _kokkos_backends[_backend] diff --git a/var/spack/repos/builtin/packages/exago/package.py b/var/spack/repos/builtin/packages/exago/package.py index 796138b4c5e0fd..44680143067002 100644 --- a/var/spack/repos/builtin/packages/exago/package.py +++ b/var/spack/repos/builtin/packages/exago/package.py @@ -60,6 +60,10 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): ) version("kpp2", tag="kpp2", commit="1da764d80a2db793f4c43ca50e50981f7ed3880a", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Progrmming model options variant("mpi", default=True, description="Enable/Disable MPI") variant("raja", default=False, description="Enable/Disable RAJA") @@ -156,7 +160,7 @@ class Exago(CMakePackage, CudaPackage, ROCmPackage): # This is duplicated from HiOp # RAJA > 0.14 and Umpire > 6.0 require c++ std 14 # We are working on supporting newer Umpire/RAJA versions - depends_on("raja@0.14.0:0.14", when="@1.1.0:+raja") + depends_on("raja@0.14.0:0.14 +shared", when="@1.1.0:+raja") depends_on("umpire@6.0.0:6", when="@1.1.0:+raja") depends_on("camp@0.2.3:0.2", when="@1.1.0:+raja") # This is no longer a requirement in RAJA > 0.14 diff --git a/var/spack/repos/builtin/packages/examl/package.py b/var/spack/repos/builtin/packages/examl/package.py index 1747eb95ea7439..958b8095872ba8 100644 --- a/var/spack/repos/builtin/packages/examl/package.py +++ b/var/spack/repos/builtin/packages/examl/package.py @@ -31,6 +31,8 @@ class Examl(MakefilePackage): version("3.0.14", sha256="698b538996946ae23a2d6fa1e230c210832e59080da33679ff7d6b342a9e6180") version("3.0.13", sha256="893aecb5545798235a17975aa07268693d3526d0aee0ed59a2d6e791248791ed") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Enable MPI parallel support") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin/packages/exampm/package.py b/var/spack/repos/builtin/packages/exampm/package.py index 5c3a4280229ec0..0da28676d39fac 100644 --- a/var/spack/repos/builtin/packages/exampm/package.py +++ b/var/spack/repos/builtin/packages/exampm/package.py @@ -20,6 +20,8 @@ class Exampm(CMakePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/exasp2/package.py b/var/spack/repos/builtin/packages/exasp2/package.py index e19cb8d201427e..2b13d5a59e2fae 100644 --- a/var/spack/repos/builtin/packages/exasp2/package.py +++ b/var/spack/repos/builtin/packages/exasp2/package.py @@ -32,6 +32,8 @@ class Exasp2(MakefilePackage): version("develop", branch="master") version("1.0", sha256="59986ea70391a1b382d2ed22d5cf013f46c0c15e44ed95dcd875a917adfc6211") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Build With MPI Support") depends_on("bml") diff --git a/var/spack/repos/builtin/packages/exawind/package.py b/var/spack/repos/builtin/packages/exawind/package.py index b7ba5e378d4aff..79791711b77aa9 100644 --- a/var/spack/repos/builtin/packages/exawind/package.py +++ b/var/spack/repos/builtin/packages/exawind/package.py @@ -6,37 +6,124 @@ from spack.package import * -class Exawind(CMakePackage): +class Exawind(CMakePackage, CudaPackage, ROCmPackage): """Multi-application driver for Exawind project.""" homepage = "https://github.com/Exawind/exawind-driver" git = "https://github.com/Exawind/exawind-driver.git" - maintainers("jrood-nrel", "psakievich") + maintainers("jrood-nrel") tags = ["ecp", "ecp-apps"] license("Apache-2.0") - version("master", branch="main") + version("master", branch="main", submodules=True, preferred=True) + version("1.0.0", tag="v1.0.0", submodules=True) - depends_on("trilinos+stk") - depends_on("tioga+shared~nodegid") - depends_on("nalu-wind+hypre+openfast+tioga+wind-utils") - depends_on("amr-wind+hypre+mpi+netcdf+openfast") - depends_on("openfast+cxx+shared@2.6.0:") + depends_on("cxx", type="build") # generated + + variant("amr_wind_gpu", default=False, description="Enable AMR-Wind on the GPU") + variant("nalu_wind_gpu", default=False, description="Enable Nalu-Wind on the GPU") + variant("sycl", default=False, description="Enable SYCL backend for AMR-Wind") + variant("gpu-aware-mpi", default=False, description="gpu-aware-mpi") + + for arch in CudaPackage.cuda_arch_values: + depends_on( + "amr-wind+cuda cuda_arch=%s" % arch, when="+amr_wind_gpu+cuda cuda_arch=%s" % arch + ) + depends_on( + "nalu-wind+cuda cuda_arch=%s" % arch, when="+nalu_wind_gpu+cuda cuda_arch=%s" % arch + ) + depends_on( + "trilinos+cuda cuda_arch=%s" % arch, when="+nalu_wind_gpu+cuda cuda_arch=%s" % arch + ) + + for arch in ROCmPackage.amdgpu_targets: + depends_on( + "amr-wind+rocm amdgpu_target=%s" % arch, + when="+amr_wind_gpu+rocm amdgpu_target=%s" % arch, + ) + depends_on( + "nalu-wind+rocm amdgpu_target=%s" % arch, + when="+nalu_wind_gpu+rocm amdgpu_target=%s" % arch, + ) + depends_on( + "trilinos+rocm amdgpu_target=%s" % arch, + when="+nalu_wind_gpu+rocm amdgpu_target=%s" % arch, + ) + + depends_on("nalu-wind+hypre+fsi+openfast+tioga") + depends_on("amr-wind+netcdf+mpi+tiny_profile") + depends_on("trilinos") depends_on("yaml-cpp@0.6:") + depends_on("tioga~nodegid") + depends_on("openfast+cxx@2.6.0:") + depends_on("amr-wind+sycl", when="+amr_wind_gpu+sycl") + depends_on("kokkos-nvcc-wrapper", type="build", when="+cuda") + depends_on("mpi") + depends_on("nalu-wind+gpu-aware-mpi", when="+gpu-aware-mpi") + depends_on("amr-wind+gpu-aware-mpi", when="+gpu-aware-mpi") + depends_on("nalu-wind@2.0.0:", when="@1.0.0:") + depends_on("amr-wind@0.9.0:", when="@1.0.0:") + depends_on("tioga@1.0.0:", when="@1.0.0:") + + with when("~amr_wind_gpu~nalu_wind_gpu"): + conflicts("+cuda") + conflicts("+rocm") + conflicts("+sycl") + with when("~nalu_wind_gpu"): + conflicts("^nalu-wind+cuda") + conflicts("^nalu-wind+rocm") + with when("~amr_wind_gpu"): + conflicts("^amr-wind+cuda") + conflicts("^amr-wind+rocm") + conflicts("^amr-wind+sycl") + conflicts("+amr_wind_gpu", when="~cuda~rocm~sycl") + conflicts("+nalu_wind_gpu", when="~cuda~rocm") + conflicts("+nalu_wind_gpu", when="+sycl") + conflicts("^amr-wind+hypre", when="~amr_wind_gpu+nalu_wind_gpu") + conflicts("^amr-wind+hypre", when="+amr_wind_gpu~nalu_wind_gpu") + conflicts("+sycl", when="+cuda") + conflicts("+rocm", when="+cuda") + conflicts("+sycl", when="+rocm") def cmake_args(self): spec = self.spec - args = [ - self.define("Trilinos_DIR", spec["trilinos"].prefix), - self.define("TIOGA_DIR", spec["tioga"].prefix), - self.define("Nalu-Wind_DIR", spec["nalu-wind"].prefix), - self.define("AMR-Wind_DIR", spec["amr-wind"].prefix), - self.define("OpenFAST_DIR", spec["openfast"].prefix), - self.define("YAML-CPP_DIR", spec["yaml-cpp"].prefix), - ] + args = [self.define("MPI_HOME", spec["mpi"].prefix)] + + if spec.satisfies("+cuda"): + args.append(self.define("CMAKE_CXX_COMPILER", spec["mpi"].mpicxx)) + args.append(self.define("CMAKE_C_COMPILER", spec["mpi"].mpicc)) + args.append(self.define("EXAWIND_ENABLE_CUDA", True)) + args.append(self.define("CUDAToolkit_ROOT", self.spec["cuda"].prefix)) + args.append(self.define("EXAWIND_CUDA_ARCH", self.spec.variants["cuda_arch"].value)) + + if spec.satisfies("+rocm"): + targets = self.spec.variants["amdgpu_target"].value + args.append(self.define("EXAWIND_ENABLE_ROCM", True)) + args.append(self.define("CMAKE_CXX_COMPILER", self.spec["hip"].hipcc)) + # Optimization to only build one specific target architecture: + args.append(self.define("CMAKE_HIP_ARCHITECTURES", ";".join(str(x) for x in targets))) + args.append(self.define("AMDGPU_TARGETS", ";".join(str(x) for x in targets))) + args.append(self.define("GPU_TARGETS", ";".join(str(x) for x in targets))) + + if spec.satisfies("^amr-wind+hdf5"): + args.append(self.define("H5Z_ZFP_USE_STATIC_LIBS", True)) return args + + def setup_build_environment(self, env): + env.append_flags("CXXFLAGS", "-DUSE_STK_SIMD_NONE") + if "+rocm+amr_wind_gpu~nalu_wind_gpu" in self.spec: + # Manually turn off device self.defines to solve Kokkos issues in Nalu-Wind headers + env.append_flags("CXXFLAGS", "-U__HIP_DEVICE_COMPILE__ -DDESUL_HIP_RDC") + if "+cuda" in self.spec: + env.set("OMPI_CXX", self.spec["kokkos-nvcc-wrapper"].kokkos_cxx) + env.set("MPICH_CXX", self.spec["kokkos-nvcc-wrapper"].kokkos_cxx) + env.set("MPICXX_CXX", self.spec["kokkos-nvcc-wrapper"].kokkos_cxx) + if "+rocm" in self.spec: + env.set("OMPI_CXX", self.spec["hip"].hipcc) + env.set("MPICH_CXX", self.spec["hip"].hipcc) + env.set("MPICXX_CXX", self.spec["hip"].hipcc) diff --git a/var/spack/repos/builtin/packages/exciting/package.py b/var/spack/repos/builtin/packages/exciting/package.py index 72e9c2f82be1b2..c47b27536aacfa 100644 --- a/var/spack/repos/builtin/packages/exciting/package.py +++ b/var/spack/repos/builtin/packages/exciting/package.py @@ -24,6 +24,10 @@ class Exciting(MakefilePackage): version("oxygen", branch="oxygen_release", preferred=True) version("14", sha256="a7feaffdc23881d6c0737d2f79f94d9bf073e85ea358a57196d7f7618a0a3eff") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # as-of-yet unpublished fix to version 14 patch("dfgather.patch", when="@14", working_dir="src/src_xs", level=0) # Patch to add aarch64 in config.guess diff --git a/var/spack/repos/builtin/packages/exempi/package.py b/var/spack/repos/builtin/packages/exempi/package.py index f720a3a56b4ce9..2e3a2e126fe225 100644 --- a/var/spack/repos/builtin/packages/exempi/package.py +++ b/var/spack/repos/builtin/packages/exempi/package.py @@ -22,6 +22,8 @@ class Exempi(AutotoolsPackage): version("2.6.1", sha256="072451ac1e0dc97ed69a2e5bfc235fd94fe093d837f65584d0e3581af5db18cd") version("2.5.2", sha256="52f54314aefd45945d47a6ecf4bd21f362e6467fa5d0538b0d45a06bc6eaaed5") + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("iconv") # needs +test variant to prevent following error: diff --git a/var/spack/repos/builtin/packages/exiv2/package.py b/var/spack/repos/builtin/packages/exiv2/package.py index 937576b4ae9721..181f0c3e0bfbc4 100644 --- a/var/spack/repos/builtin/packages/exiv2/package.py +++ b/var/spack/repos/builtin/packages/exiv2/package.py @@ -22,5 +22,7 @@ class Exiv2(CMakePackage): version("0.27.3", sha256="6398bc743c32b85b2cb2a604273b8c90aa4eb0fd7c1700bf66cbb2712b4f00c1") version("0.27.2", sha256="3dbcaf01fbc5b98d42f091d1ff0d4b6cd9750dc724de3d9c0d113948570b2934") + depends_on("cxx", type="build") # generated + depends_on("zlib-api", type="link") depends_on("expat@2.2.6:", type="link") diff --git a/var/spack/repos/builtin/packages/exmcutils/package.py b/var/spack/repos/builtin/packages/exmcutils/package.py index 8cd81156133fe0..6629a68a693219 100644 --- a/var/spack/repos/builtin/packages/exmcutils/package.py +++ b/var/spack/repos/builtin/packages/exmcutils/package.py @@ -19,6 +19,8 @@ class Exmcutils(AutotoolsPackage): version("0.5.7", sha256="6b84f43e8928d835dbd68c735ece6a9b7c648a1a4488ec2b1d2f3c4ceec508e8") version("0.5.6", sha256="296ba85cc828bd816c7c4de9453f589da37f32854a58ffda3586b6f371a23abf") + depends_on("c", type="build") # generated + @property def configure_directory(self): if self.version == Version("master"): diff --git a/var/spack/repos/builtin/packages/exodusii/Fix-ioss-tpl.patch b/var/spack/repos/builtin/packages/exodusii/Fix-ioss-tpl.patch new file mode 100644 index 00000000000000..587d73a8855630 --- /dev/null +++ b/var/spack/repos/builtin/packages/exodusii/Fix-ioss-tpl.patch @@ -0,0 +1,25 @@ +From 4d3884f65a6a4df08ee8dd68ddaee5449f1dd378 Mon Sep 17 00:00:00 2001 +From: Greg Sjaardema +Date: Tue, 26 Mar 2024 12:42:08 -0600 +Subject: [PATCH] Remove ioss as required library + +--- + packages/seacas/cmake/Dependencies.cmake | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/packages/seacas/cmake/Dependencies.cmake b/packages/seacas/cmake/Dependencies.cmake +index 3b1b3d6598..e75f5073f2 100644 +--- a/packages/seacas/cmake/Dependencies.cmake ++++ b/packages/seacas/cmake/Dependencies.cmake +@@ -4,7 +4,7 @@ TRIBITS_PACKAGE_DEFINE_DEPENDENCIES( + Exodus_for libraries/exodus_for PT OPTIONAL + ExoIIv2for32 libraries/exoIIv2for32 PT OPTIONAL + Nemesis libraries/nemesis PT OPTIONAL +- Ioss libraries/ioss PT REQUIRED ++ Ioss libraries/ioss PT OPTIONAL + Chaco libraries/chaco PT OPTIONAL + Aprepro_lib libraries/aprepro_lib PT OPTIONAL + Supes libraries/supes PT OPTIONAL +-- +2.39.3 (Apple Git-145) + diff --git a/var/spack/repos/builtin/packages/exodusii/package.py b/var/spack/repos/builtin/packages/exodusii/package.py index 1a755b39653053..1b25757c3fbde1 100644 --- a/var/spack/repos/builtin/packages/exodusii/package.py +++ b/var/spack/repos/builtin/packages/exodusii/package.py @@ -3,10 +3,12 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import sys + +from spack.operating_systems.mac_os import macos_version from spack.package import * -# TODO: Add support for a C++11 enabled installation that filters out the -# TODO: "C++11-Disabled" flag (but only if the spec compiler supports C++11). +is_windows = sys.platform == "win32" class Exodusii(CMakePackage): @@ -15,101 +17,186 @@ class Exodusii(CMakePackage): (problem definition), postprocessing (results visualization), and data transfer between codes. An Exodus II data file is a random access, machine independent, binary file that is written and read - via C, C++, or Fortran API routines. + via C, C++, or Fortran API routines. This package *only* installs + the C and optionally Fortran library for exodus. If you want the full + suite of exodus-releated tools including the IOSS library, install + the seacas package instead of this package. """ - homepage = "https://github.com/gsjaardema/seacas" - git = "https://github.com/gsjaardema/seacas.git" - url = "https://github.com/gsjaardema/seacas/archive/refs/tags/v2021-04-05.zip" + homepage = "https://sandialabs.github.io/seacas/" + git = "https://github.com/sandialabs/seacas.git" + url = "https://github.com/sandialabs/seacas/archive/refs/tags/v2019-08-20.zip" + maintainers("gsjaardema") - license("X11") + license("BSD-3-Clause") + version("master", branch="master") version( - "2021-04-05", sha256="f40d318674753287b8b28d2b4e5cca872cd772d4c7383af4a8f3eeb48fcc7ec0" + "2024-04-03", sha256="72b095bae64b2b6c232630f79de763c6ade00c9b1199fc6980800891b2ab3751" ) version( - "2021-04-02", sha256="811037a68eaff0daf9f34bd31b2ab1c9b8f028dfcb998ab01fbcb80d9458257c" + "2024-03-11", sha256="5d417aa652e4ec8d66e27714c63b8cb5a7f878fb7b2ec55f629636fcff7c0f00" ) version( - "2021-01-20", sha256="6ff7c3f0651138f2e2305b5270108ca45f96346a739b35a126a0a260c91cbe64" + "2023-11-27", sha256="00c444b2def2c9cf5694bee5bb0284ce289e83f7c84ac28c6701c746cfde9a4c" ) version( - "2021-01-06", sha256="69cafef17d8e624c2d9871f3a281ff3690116a6f82162fe5c1507bb4ecd6a32a" + "2023-05-30", sha256="d2cbd43596ed3ad77186f865fe8aa81a2efe389ff345b24622ac76c16614b532" ) version( - "2020-08-13", sha256="5b128a8ad9b0a69cff4fe937828d6d1702f1fe8aa80d4751e6522939afe62957" + "2022-10-14", sha256="a96f29de3b69e7e3f5f344396c8cf791fe277dab0217fc0b90b02e38e75bbdc1" ) version( - "2020-05-12", sha256="0402facf6cf23d903d878fb924b5d57e9f279dead5b92cf986953a6b91a6e81f" + "2022-08-01", sha256="c12a677ba2178cf5161d63fef3b1da4d3888622199cea3e611f59649085681dc" ) version( - "2020-03-16", sha256="ed1d42c8c657931ecd45367a465cf9c00255772d9cd0811fc9baacdb67fc71fa" + "2022-05-16", sha256="80f6b0dee91766ab207a366b8eea546cc1afa33cea24deebaa6583f283d80fab" ) version( - "2020-01-16", sha256="db69dca25595e88a40c00db0ccf2afed1ecd6008ba30bb478a4e1c5dd61998b8" + "2022-03-04", sha256="b2e09f0f64d75634b7d3f9844c2cea7acbc877c4ceebb6b91e8e494bb3653166" ) version( - "2019-12-18", sha256="88a71de836aa26fd63756cf3ffbf3978612edc5b6c61fa8de32fe9d638007774" + "2022-02-16", sha256="e1907f6831d9a0dd2c65879ca5746b9a0ef57d7ccce0036d55c0c6c5628ac981" ) version( - "2019-10-14", sha256="f143d90e8a7516d25979d1416e580dea638332db723f26ae94a712dfe4052e8f" + "2022-01-27", sha256="d21c14b9b30f773cef8e2029773f3cc35da021eebe9060298231f95021eb814f" ) - version("2016-08-09", commit="2ffeb1bd39454ad5aa230e12969ce976f3d1c92b") - version("master", branch="master") + version( + "2021-10-11", + sha256="5c04d252e1c4a10b037aa352b89487e581ec6b52bdb46e9e85f101bbdcd9c388", + deprecated=True, + ) + version( + "2021-04-05", + sha256="f40d318674753287b8b28d2b4e5cca872cd772d4c7383af4a8f3eeb48fcc7ec0", + deprecated=True, + ) + version( + "2021-04-02", + sha256="811037a68eaff0daf9f34bd31b2ab1c9b8f028dfcb998ab01fbcb80d9458257c", + deprecated=True, + ) + version( + "2021-01-20", + sha256="6ff7c3f0651138f2e2305b5270108ca45f96346a739b35a126a0a260c91cbe64", + deprecated=True, + ) + version( + "2021-01-06", + sha256="69cafef17d8e624c2d9871f3a281ff3690116a6f82162fe5c1507bb4ecd6a32a", + deprecated=True, + ) + version( + "2020-08-13", + sha256="5b128a8ad9b0a69cff4fe937828d6d1702f1fe8aa80d4751e6522939afe62957", + deprecated=True, + ) + version( + "2020-05-12", + sha256="0402facf6cf23d903d878fb924b5d57e9f279dead5b92cf986953a6b91a6e81f", + deprecated=True, + ) + version( + "2020-03-16", + sha256="ed1d42c8c657931ecd45367a465cf9c00255772d9cd0811fc9baacdb67fc71fa", + deprecated=True, + ) + version( + "2020-01-16", + sha256="db69dca25595e88a40c00db0ccf2afed1ecd6008ba30bb478a4e1c5dd61998b8", + deprecated=True, + ) + version( + "2019-12-18", + sha256="88a71de836aa26fd63756cf3ffbf3978612edc5b6c61fa8de32fe9d638007774", + deprecated=True, + ) + version( + "2019-10-14", + sha256="f143d90e8a7516d25979d1416e580dea638332db723f26ae94a712dfe4052e8f", + deprecated=True, + ) + version("2016-08-09", commit="2ffeb1bd39454ad5aa230e12969ce976f3d1c92b", deprecated=True) + patch("Fix-ioss-tpl.patch", when="@2021-10-11:") + + # Build options + variant("fortran", default=False, description="Compile with Fortran support") + variant("shared", default=True, description="Enables the build of shared libraries") variant("mpi", default=True, description="Enables MPI parallelism.") - variant("fortran", default=False, description="Build Fortran wrapper libraries.") + variant("thread_safe", default=False, description="Enable thread-safe exodus library") - depends_on("cmake@2.8.11:", type="build") + depends_on("cmake@3.22:", when="@2023-10-24:", type="build") + depends_on("cmake@3.17:", when="@:2023-05-30", type="build") depends_on("mpi", when="+mpi") - # https://github.com/gsjaardema/seacas/blob/master/NetCDF-Mapping.md - depends_on("netcdf-c@4.6.1:+mpi", when="+mpi") - depends_on("netcdf-c@4.6.1:~mpi", when="~mpi") + # Always depends on netcdf-c + depends_on("netcdf-c@4.8.0:+mpi+parallel-netcdf", when="+mpi") + depends_on("netcdf-c@4.8.0:~mpi", when="~mpi") + depends_on("hdf5+hl~mpi", when="~mpi") + depends_on("hdf5+hl+mpi", when="+mpi") + + depends_on("python@3.0:") + conflicts("+shared", when="platform=windows") - depends_on("python@2.7:") + def setup_run_environment(self, env): + env.prepend_path("PYTHONPATH", self.prefix.lib) def cmake_args(self): spec = self.spec + from_variant = self.define_from_variant + define = self.define + + if self.spec.satisfies("@2022-10-14:"): + project_name_base = "Seacas" + else: + project_name_base = "SEACASProj" - cc_path = spec["mpi"].mpicc if "+mpi" in spec else self.compiler.cc - cxx_path = spec["mpi"].mpicxx if "+mpi" in spec else self.compiler.cxx - - options = [ - # General Flags # - "-DSEACASProj_ENABLE_SEACASExodus=ON", - "-DSEACASProj_ENABLE_TESTS=ON", - "-DBUILD_SHARED_LIBS:BOOL=ON", - "-DTPL_ENABLE_Netcdf:BOOL=ON", - "-DHDF5_NO_SYSTEM_PATHS=ON", - "-DSEACASProj_SKIP_FORTRANCINTERFACE_VERIFY_TEST:BOOL=ON", - "-DSEACASProj_ENABLE_CXX11:BOOL=OFF", - "-DSEACASProj_ENABLE_Zoltan:BOOL=OFF", - "-DNetCDF_DIR:PATH={0}".format(spec["netcdf-c"].prefix), - # MPI Flags # - "-DTPL_ENABLE_MPI={0}".format("ON" if "+mpi" in spec else "OFF"), - "-DCMAKE_C_COMPILER={0}".format(cc_path), - "-DCMAKE_CXX_COMPILER={0}".format(cxx_path), - ] - if "+fortran" in spec: - fc_path = spec["mpi"].mpifc if "+mpi" in spec else self.compiler.f90 + options = [] + + # #################### Base Settings ####################### + # Only want to enable the Exodus library. If want anything else, use the seacas package. + options.extend( + [ + define(project_name_base + "_ENABLE_ALL_PACKAGES", False), + define(project_name_base + "_ENABLE_ALL_OPTIONAL_PACKAGES", False), + define(project_name_base + "_ENABLE_SECONDARY_TESTED_CODE", False), + define(project_name_base + "_ENABLE_SEACASExodus", True), + from_variant(project_name_base + "_ENABLE_SEACASExodus_for", "fortran"), + from_variant(project_name_base + "_ENABLE_SEACASExoIIv2for32", "fortran"), + define(project_name_base + "_HIDE_DEPRECATED_CODE", False), + from_variant("CMAKE_INSTALL_RPATH_USE_LINK_PATH", "shared"), + from_variant("BUILD_SHARED_LIBS", "shared"), + from_variant("SEACASExodus_ENABLE_THREADSAFE", "thread_safe"), + from_variant("TPL_ENABLE_Pthread", "thread_safe"), + from_variant(project_name_base + "_ENABLE_Fortran", "fortran"), + ] + ) + if "~shared" in self.spec and not is_windows: + options.append(self.define(project_name_base + "_EXTRA_LINK_FLAGS", "z;dl")) + options.append(from_variant("TPL_ENABLE_MPI", "mpi")) + if "+mpi" in spec and not is_windows: options.extend( [ - "-DSEACASProj_ENABLE_Fortran:BOOL=ON", - "-DCMAKE_Fortran_COMPILER={0}".format(fc_path), - "-DSEACASProj_ENABLE_SEACASExodus_for:BOOL=ON", - "-DSEACASProj_ENABLE_SEACASExoIIv2for32:BOOL=ON", + define("CMAKE_C_COMPILER", spec["mpi"].mpicc), + define("CMAKE_CXX_COMPILER", spec["mpi"].mpicxx), + define("MPI_BASE_DIR", spec["mpi"].prefix), ] ) - # Python # - # Handle v2016 separately because of older tribits - if spec.satisfies("@:2016-08-09"): - options.append( - "-DPYTHON_EXECUTABLE={0}".format( - join_path(self.spec["python"].prefix.bin, "python") - ) - ) + if "+fortran" in self.spec: + options.append(define("CMAKE_Fortran_COMPILER", spec["mpi"].mpifc)) + + # ##################### Dependencies ########################## + # Always need NetCDF-C + options.extend( + [define("TPL_ENABLE_Netcdf", True), define("NetCDF_ROOT", spec["netcdf-c"].prefix)] + ) + + # ################# RPath Handling ###################### + if sys.platform == "darwin" and macos_version() >= Version("10.12"): + # use @rpath on Sierra due to limit of dynamic loader + options.append(define("CMAKE_MACOSX_RPATH", True)) else: - options.append("-DPython_ROOT={0}".format(spec["python"].prefix)) + options.append(define("CMAKE_INSTALL_NAME_DIR", self.prefix.lib)) return options diff --git a/var/spack/repos/builtin/packages/exonerate-gff3/package.py b/var/spack/repos/builtin/packages/exonerate-gff3/package.py index 3d7fac832ccce0..eb5c6234bdde38 100644 --- a/var/spack/repos/builtin/packages/exonerate-gff3/package.py +++ b/var/spack/repos/builtin/packages/exonerate-gff3/package.py @@ -18,6 +18,8 @@ class ExonerateGff3(AutotoolsPackage): version("2.3.0", sha256="eeab7ea8bc815fc4a37d4c3b89c625167a9a60a4a833b5cc96e32dc313eafd1f") + depends_on("c", type="build") # generated + depends_on("glib") # parallel builds fail occasionally diff --git a/var/spack/repos/builtin/packages/exonerate/package.py b/var/spack/repos/builtin/packages/exonerate/package.py index 0eac5a46059404..1453cf9074765f 100644 --- a/var/spack/repos/builtin/packages/exonerate/package.py +++ b/var/spack/repos/builtin/packages/exonerate/package.py @@ -16,6 +16,8 @@ class Exonerate(AutotoolsPackage): version("2.4.0", sha256="f849261dc7c97ef1f15f222e955b0d3daf994ec13c9db7766f1ac7e77baa4042") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("glib") diff --git a/var/spack/repos/builtin/packages/expat/package.py b/var/spack/repos/builtin/packages/expat/package.py index 36d79c06c76c1e..38d9b3ab038db8 100644 --- a/var/spack/repos/builtin/packages/expat/package.py +++ b/var/spack/repos/builtin/packages/expat/package.py @@ -139,6 +139,9 @@ class Expat(AutotoolsPackage, CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_system("autotools", "cmake", default="autotools") # Version 2.2.2 introduced a requirement for a high quality diff --git a/var/spack/repos/builtin/packages/expect/package.py b/var/spack/repos/builtin/packages/expect/package.py index 372817b8d660df..33f79fe2d9ba18 100644 --- a/var/spack/repos/builtin/packages/expect/package.py +++ b/var/spack/repos/builtin/packages/expect/package.py @@ -24,6 +24,8 @@ class Expect(AutotoolsPackage): version("5.45.3", sha256="c520717b7195944a69ce1492ec82ca0ac3f3baf060804e6c5ee6d505ea512be9") version("5.45", sha256="b28dca90428a3b30e650525cdc16255d76bb6ccd65d448be53e620d95d5cc040") + depends_on("c", type="build") # generated + depends_on("tcl") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/extrae/package.py b/var/spack/repos/builtin/packages/extrae/package.py index a800bc309f9b11..69d04447c4263e 100644 --- a/var/spack/repos/builtin/packages/extrae/package.py +++ b/var/spack/repos/builtin/packages/extrae/package.py @@ -42,6 +42,7 @@ class Extrae(AutotoolsPackage): license("LGPL-2.1-or-later") + version("4.1.2", sha256="adbc1d3aefde7649262426d471237dc96f070b93be850a6f15280ed86fd0b952") version("4.0.6", sha256="b5060336cac57f1345faa09009b1940edf1e6991aae05cc10d0b714d31360a92") version("4.0.5", sha256="8f5eefa95f2e94a3b5f9b7f7cbaaed523862f190575ee797113b1e97deff1586") version("4.0.4", sha256="003bede870de6d88b705c1a13eabe63b6beb928d8f389f5dd70ca5db8450a1f9") @@ -50,6 +51,10 @@ class Extrae(AutotoolsPackage): version("3.7.1", sha256="c83ddd18a380c9414d64ee5de263efc6f7bac5fe362d5b8374170c7f18360378") version("3.4.1", sha256="77bfec16d6b5eee061fbaa879949dcef4cad28395d6a546b1ae1b9246f142725") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/exuberant-ctags/package.py b/var/spack/repos/builtin/packages/exuberant-ctags/package.py index 41452896fad6ef..55ad28002993fc 100644 --- a/var/spack/repos/builtin/packages/exuberant-ctags/package.py +++ b/var/spack/repos/builtin/packages/exuberant-ctags/package.py @@ -16,4 +16,6 @@ class ExuberantCtags(AutotoolsPackage): version("5.8", sha256="0e44b45dcabe969e0bbbb11e30c246f81abe5d32012db37395eb57d66e9e99c7") + depends_on("c", type="build") # generated + patch("ctags-5.8-gcc-unused-attribute.patch", when="@5.8") diff --git a/var/spack/repos/builtin/packages/eztrace/package.py b/var/spack/repos/builtin/packages/eztrace/package.py index 2a119e960e5d66..82c3678f7dbee7 100644 --- a/var/spack/repos/builtin/packages/eztrace/package.py +++ b/var/spack/repos/builtin/packages/eztrace/package.py @@ -3,17 +3,17 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.build_systems import autotools, cmake from spack.package import * -class Eztrace(Package): - """EZTrace is a tool to automatically generate execution traces - of HPC applications.""" +class Eztrace(CMakePackage, AutotoolsPackage, CudaPackage): + """EZTrace is a tool to automatically generate execution traces of HPC applications.""" homepage = "https://gitlab.com/eztrace" - maintainers("trahay") git = "https://gitlab.com/eztrace/eztrace.git" + maintainers("trahay") license("CECILL-B") version("master", branch="master") @@ -22,80 +22,50 @@ class Eztrace(Package): version("1.1-13", sha256="6144d04fb62b3ccad41af0268cd921161f168d0cca3f6c210c448bb0b07be7e0") version("1.1-10", sha256="63d1af2db38b04efa817614574f381e7536e12db06a2c75375d1795adda3d1d8") - # dependencies for eztrace 1.x and 2.x + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("starpu", default=False, description="Enable StarPU support", when="@2.1:") + variant("netcdf", default=False, description="Enable NetCDF support", when="@2.1:") + variant("pnetcdf", default=False, description="Enable PNetCDF support", when="@2.1:") + + build_system( + conditional("cmake", when="@2:"), conditional("autotools", when="@:1"), default="cmake" + ) + depends_on("mpi") depends_on("opari2") depends_on("binutils") + depends_on("otf2", when="@2:") - # eztrace 1.x dependencies - depends_on("autoconf@2.71", type="build", when="@:1") - depends_on("automake", type="build", when="@:1") - depends_on("libtool", type="build", when="@:1") - # Does not work on Darwin due to MAP_POPULATE - conflicts("platform=darwin", when="@:1") + with when("build_system=autotools"): + depends_on("autoconf", type="build") + depends_on("automake", type="build") + depends_on("libtool", type="build") - # eztrace 2.x dependencies - depends_on("cmake@3.1:", type="build", when="@2.0:") - depends_on("otf2", when="@2.0:") + with when("build_system=cmake"): + depends_on("cmake@3.1:", type="build") - variant("starpu", default=False, description="Enable StarPU support", when="@2.1:") - depends_on("starpu", when="@2.1:+starpu") - variant("cuda", default=False, description="Enable CUDA support", when="@2.1:") - depends_on("cuda", when="@2.1:+cuda") - variant("netcdf", default=False, description="Enable NetCDF support", when="@2.1:") - depends_on("netcdf-c", when="@2.1:+netcdf") - variant("pnetcdf", default=False, description="Enable PNetCDF support", when="@2.1:") - depends_on("parallel-netcdf", when="@2.1:+pnetcdf") + depends_on("starpu", when="+starpu") + depends_on("cuda", when="+cuda") + depends_on("netcdf-c", when="+netcdf") + depends_on("parallel-netcdf", when="+pnetcdf") - def url_for_version(self, version): - url = "https://gitlab.com/eztrace/eztrace/-/archive/{0}/eztrace-{1}.tar.gz" - return url.format(version, version) + patch( + "https://gitlab.com/eztrace/eztrace/-/commit/3aafa74b12bc2c7e0687f2dbcfc35a699487eb10.diff", + sha256="45321b0fd15db84840280c34a91ab877d0ceec6eb825f699f08a7bd135be3d79", + when="@:1", + ) - @when("@2.0:") - def install(self, spec, prefix): - # Since eztrace 2.0, the build system uses CMake - spec = self.spec - args = [ - "-DCMAKE_INSTALL_PREFIX=$prefix", - "-DEZTRACE_ENABLE_MEMORY=ON", - "-DEZTRACE_ENABLE_MPI=ON", - "-DEZTRACE_ENABLE_OPENMP=ON", - "-DEZTRACE_ENABLE_POSIXIO=ON", - "-DEZTRACE_ENABLE_PTHREAD=ON", - "-DOTF2_INCLUDE_PATH=%s" % spec["otf2"].prefix.include, - "-DOTF2_LIBRARY_PATH=%s" % spec["otf2"].libs, - ] + # Does not work on Darwin due to MAP_POPULATE + conflicts("platform=darwin", when="@:1") - if spec.satisfies("@2.1:"): - if spec.satisfies("%llvm-openmp-ompt"): - args.extend(["-DEZTRACE_ENABLE_OMPT=ON"]) - if "+starpu" in spec: - args.extend(["-DEZTRACE_ENABLE_STARPU=ON"]) - if "+cuda" in spec: - args.extend(["-DEZTRACE_ENABLE_CUDA=ON"]) - if "+netcdf" in spec: - args.extend(["-DEZTRACE_ENABLE_NETCDF=ON"]) - if "+pnetcdf" in spec: - args.extend(["-DEZTRACE_ENABLE_PNETCDF=ON"]) - - args.extend(std_cmake_args) - - with working_dir("spack-build", create=True): - cmake("..", *args) - make() - make("install") - - # Until eztrace 2.0, the build system uses autoconf - @when("@:1") - def install(self, spec, prefix): - if self.spec.satisfies("%fj"): - env.set("LDFLAGS", "--linkfortran") - self.patch() - which("bash")("bootstrap") - configure("--prefix=" + prefix, "--with-mpi={0}".format(self.spec["mpi"].prefix)) - self.fix_libtool() - make() - make("install") + # CUDA support from 2.1 + conflicts("+cuda", when="@:2.0") + + def url_for_version(self, version): + return f"https://gitlab.com/eztrace/eztrace/-/archive/{version}/eztrace-{version}.tar.gz" @when("@:1") def patch(self): @@ -106,9 +76,40 @@ def patch(self): string=True, ) - @when("@:1") - def fix_libtool(self): - if self.spec.satisfies("%fj"): - libtools = ["extlib/gtg/libtool", "extlib/opari2/build-frontend/libtool"] - for f in libtools: - filter_file('wl=""', 'wl="-Wl,"', f, string=True) + +class CMakeBuilder(cmake.CMakeBuilder): + def cmake_args(self): + spec = self.spec + args = [ + self.define("EZTRACE_ENABLE_MEMORY", True), + self.define("EZTRACE_ENABLE_MPI", True), + self.define("EZTRACE_ENABLE_OPENMP", True), + self.define("EZTRACE_ENABLE_POSIXIO", True), + self.define("EZTRACE_ENABLE_PTHREAD", True), + self.define("OTF2_INCLUDE_PATH", spec["otf2"].prefix.include), + self.define("OTF2_LIBRARY_PATH", spec["otf2"].libs), + ] + + if spec.satisfies("@2.1: %llvm-openmp-ompt"): + args.append(self.define("EZTRACE_ENABLE_OMPT", True)) + if "+starpu" in spec: + args.append(self.define("EZTRACE_ENABLE_STARPU", True)) + if "+cuda" in spec: + args.append(self.define("EZTRACE_ENABLE_CUDA", True)) + if "+netcdf" in spec: + args.append(self.define("EZTRACE_ENABLE_NETCDF", True)) + if "+pnetcdf" in spec: + args.append(self.define("EZTRACE_ENABLE_PNETCDF", True)) + + return args + + +class AutotoolsBuilder(autotools.AutotoolsBuilder): + def setup_build_environment(self, env): + env.set("LDFLAGS", "--linkfortran") + + def autoreconf(self, pkg, spec, prefix): + Executable("/bin/sh")("./bootstrap") + + def configure_args(self): + return [f"--with-mpi={self.spec['mpi'].prefix}"] diff --git a/var/spack/repos/builtin/packages/f2c/package.py b/var/spack/repos/builtin/packages/f2c/package.py index be2d921a1acd93..6e8bc62d11f149 100644 --- a/var/spack/repos/builtin/packages/f2c/package.py +++ b/var/spack/repos/builtin/packages/f2c/package.py @@ -14,6 +14,8 @@ class F2c(MakefilePackage): version("master", sha256="d4847456aa91c74e5e61e2097780ca6ac3b20869fae8864bfa8dcc66f6721d35") + depends_on("c", type="build") # generated + def url_for_version(self, version): url = "https://www.netlib.org/f2c/src.tgz" return url diff --git a/var/spack/repos/builtin/packages/f3d/package.py b/var/spack/repos/builtin/packages/f3d/package.py index 760cfbbb6f0ddb..fee8a91208bad8 100644 --- a/var/spack/repos/builtin/packages/f3d/package.py +++ b/var/spack/repos/builtin/packages/f3d/package.py @@ -17,4 +17,6 @@ class F3d(CMakePackage): version("2.0.0", sha256="5b335de78a9f68903d7023d947090d4b36fa15b9e165749906a82153e0f56d05") version("1.1.1", sha256="68bdbe3a90f2cd553d5e090a95d3c847e2a2f06abbe225ffecd47d3d29978b0a") + depends_on("cxx", type="build") # generated + depends_on("vtk@9:", type="link") diff --git a/var/spack/repos/builtin/packages/f77-zmq/package.py b/var/spack/repos/builtin/packages/f77-zmq/package.py index 645126b67d8ce8..0d180c933802c6 100644 --- a/var/spack/repos/builtin/packages/f77-zmq/package.py +++ b/var/spack/repos/builtin/packages/f77-zmq/package.py @@ -21,6 +21,9 @@ class F77Zmq(MakefilePackage): version("4.3.2", sha256="f1fb7544d38d9bb7235f98c96f241875ddcb0d37ed950618c23d4e4d666a73ca") version("4.3.1", sha256="a15d72d93022d3e095528d2808c7767cece974a2dc0e2dd95e4c122f60fcf0a8") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("libzmq") depends_on("python@3:", type="build", when="@:4.3.1") depends_on("python", type="build", when="@4.3.2:") diff --git a/var/spack/repos/builtin/packages/f90cache/package.py b/var/spack/repos/builtin/packages/f90cache/package.py index 29e3fc0f67f6e7..9013fbc1bd38f2 100644 --- a/var/spack/repos/builtin/packages/f90cache/package.py +++ b/var/spack/repos/builtin/packages/f90cache/package.py @@ -23,3 +23,5 @@ class F90cache(AutotoolsPackage): sha256="be3fe77b676bc784dd45b3f65b4a5db34d858ed29156b29d8da38b24585bda7d", url="http://distfiles.exherbo.org/distfiles/f90cache-0.99.tar.bz2", ) + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/fabtests/package.py b/var/spack/repos/builtin/packages/fabtests/package.py index 4c8aef39d8a503..041f1be910d435 100644 --- a/var/spack/repos/builtin/packages/fabtests/package.py +++ b/var/spack/repos/builtin/packages/fabtests/package.py @@ -16,7 +16,11 @@ class Fabtests(AutotoolsPackage): license("GPL-2.0-only") + version("1.21.0", sha256="d022a186d37bd6ccb52303e0588c28e29f0f56c25a384c37acb16c881ba99e64") + version("1.20.2", sha256="624beb02ffc8e325834545810566330f2a1204d5c6ad015ba095303121cb8ae6") + version("1.20.1", sha256="687884b6fd3046f46e2f878e19e76e4506b50950bd2f59a731618b89d02a5436") version("1.20.0", sha256="61d483452163b39d81dcb9f578e5d9007817e0496235bc2aac1e82b7737fd65e") + version("1.19.1", sha256="57b11f2e0e3cd77b104d63f0ecb453161fa8a17bc4f7ca2d7a17a7a34f7fb85c") version("1.19.0", sha256="82d714020df9258cfdd659c51f2be8f4507cbe157c7f03c992c70fc528d8d837") version("1.18.2", sha256="3d85486ff80151defdb66414a851a9a9a2d4adc6cf696e2b8e4bb3ce340512c2") version("1.18.1", sha256="fe9864acc0e17a5b0157b1cc996bb3c578cfa32c87bd43bc17b5e31e24ef63b5") @@ -37,8 +41,14 @@ class Fabtests(AutotoolsPackage): version("1.5.0", sha256="1dddd446c3f1df346899f9a8636f1b4265de5b863103ae24876e9f0c1e40a69d") version("1.4.2", sha256="3b78d0ca1b223ff21b7f5b3627e67e358e3c18b700f86b017e2233fee7e88c2e") + depends_on("c", type="build") # generated + versions = [ + "1.21.0", + "1.20.2", + "1.20.1", "1.20.0", + "1.19.1", "1.19.0", "1.18.2", "1.18.1", diff --git a/var/spack/repos/builtin/packages/fabulous/package.py b/var/spack/repos/builtin/packages/fabulous/package.py index 96427c3e2a4877..caa3285b4e617f 100644 --- a/var/spack/repos/builtin/packages/fabulous/package.py +++ b/var/spack/repos/builtin/packages/fabulous/package.py @@ -19,6 +19,10 @@ class Fabulous(CMakePackage): version("master", branch="master", submodules=True) version("1.1.3", sha256="a75a5461984360286c26b104c1d01ac6cf7c3151bfaa42d8e980eb072981f3ef") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("blasmt", default=False, description="use multi-threaded blas and lapack kernels") variant("examples", default=False, description="build examples and tests") diff --git a/var/spack/repos/builtin/packages/fairlogger/package.py b/var/spack/repos/builtin/packages/fairlogger/package.py index 83570639b9726b..a60fb497a4c335 100644 --- a/var/spack/repos/builtin/packages/fairlogger/package.py +++ b/var/spack/repos/builtin/packages/fairlogger/package.py @@ -81,6 +81,8 @@ class Fairlogger(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + generator("make", "ninja", default="ninja") variant( diff --git a/var/spack/repos/builtin/packages/fairmq/package.py b/var/spack/repos/builtin/packages/fairmq/package.py index bb21f841ca2896..18e5bcf60aac63 100644 --- a/var/spack/repos/builtin/packages/fairmq/package.py +++ b/var/spack/repos/builtin/packages/fairmq/package.py @@ -26,6 +26,8 @@ class Fairmq(CMakePackage): version("1.6.0", tag="v1.6.0", commit="42d27af20fb5cbbbc0b0fdfef1c981d51a8baf87") version("1.5.0", tag="v1.5.0", commit="c8fde17b6a10a467035590fd800bb693f50c4826") + depends_on("cxx", type="build") # generated + variant( "autobind", default=True, when="@1.7:", description="Override the channel autoBind default" ) diff --git a/var/spack/repos/builtin/packages/faiss/package.py b/var/spack/repos/builtin/packages/faiss/package.py index 8f4b6acb69af20..a7e415a6df92eb 100644 --- a/var/spack/repos/builtin/packages/faiss/package.py +++ b/var/spack/repos/builtin/packages/faiss/package.py @@ -35,6 +35,9 @@ class Faiss(AutotoolsPackage, CMakePackage, CudaPackage): version("1.6.3", sha256="e1a41c159f0b896975fbb133e0240a233af5c9286c09a28fde6aefff5336e542") version("1.5.3", sha256="b24d347b0285d01c2ed663ccc7596cd0ea95071f3dd5ebb573ccfc28f15f043b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("python", default=False, description="Build Python bindings") variant("shared", default=False, description="Build shared library") variant("tests", default=False, description="Build Tests") diff --git a/var/spack/repos/builtin/packages/fakechroot/package.py b/var/spack/repos/builtin/packages/fakechroot/package.py index c74d7597b1aec7..8ffb4b930a111a 100644 --- a/var/spack/repos/builtin/packages/fakechroot/package.py +++ b/var/spack/repos/builtin/packages/fakechroot/package.py @@ -21,3 +21,5 @@ class Fakechroot(AutotoolsPackage): version("2.20.1", sha256="5abd04323c9ddae06b5dcaa56b2da07728de3fe21007b08bd88a17b2409b32aa") version("2.20", sha256="5da99358d2a49ddd3dd54ba2ff401d93a8fa641e3754cd058bdf53adb4b7e100") version("2.19", sha256="39ffbbbe3a823be7450928b8e3b99ae4cb339c47213b2f1d8ff903e0246f2e15") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/fakexrandr/package.py b/var/spack/repos/builtin/packages/fakexrandr/package.py index e314fd3ebd5e12..4f7380281b41d2 100644 --- a/var/spack/repos/builtin/packages/fakexrandr/package.py +++ b/var/spack/repos/builtin/packages/fakexrandr/package.py @@ -15,6 +15,8 @@ class Fakexrandr(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("libxrandr") depends_on("libxinerama") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/falco/package.py b/var/spack/repos/builtin/packages/falco/package.py index 3b6c4268c8dcfc..d61d090123efd0 100644 --- a/var/spack/repos/builtin/packages/falco/package.py +++ b/var/spack/repos/builtin/packages/falco/package.py @@ -16,6 +16,8 @@ class Falco(AutotoolsPackage): version("1.2.1", sha256="33de8aafac45c7aea055ed7ab837d0a39d12dcf782816cea8a6c648acb911057") + depends_on("cxx", type="build") # generated + variant("htslib", default=False, description="Add support for BAM files") depends_on("gmake", type="build") diff --git a/var/spack/repos/builtin/packages/falcon/package.py b/var/spack/repos/builtin/packages/falcon/package.py index 898e13354ab0c7..8df968456fa9db 100644 --- a/var/spack/repos/builtin/packages/falcon/package.py +++ b/var/spack/repos/builtin/packages/falcon/package.py @@ -21,6 +21,8 @@ class Falcon(PythonPackage): version("2017-05-30", commit="86cec6157291679095ea6080b0cde6561eccc041") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="run") depends_on("py-pypeflow", type="run") depends_on("py-networkx@1.7:1.10", type=["build", "run"]) diff --git a/var/spack/repos/builtin/packages/fann/package.py b/var/spack/repos/builtin/packages/fann/package.py index ca48172e31661e..8ee6368055f58c 100644 --- a/var/spack/repos/builtin/packages/fann/package.py +++ b/var/spack/repos/builtin/packages/fann/package.py @@ -26,3 +26,6 @@ class Fann(CMakePackage): license("LGPL-2.0-or-later") version("2.2.0", sha256="f31c92c1589996f97d855939b37293478ac03d24b4e1c08ff21e0bd093449c3c") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/faodel/package.py b/var/spack/repos/builtin/packages/faodel/package.py index b4b600d299e6aa..8d91fe59b2295c 100644 --- a/var/spack/repos/builtin/packages/faodel/package.py +++ b/var/spack/repos/builtin/packages/faodel/package.py @@ -27,6 +27,9 @@ class Faodel(CMakePackage): version("1.1811.1", sha256="8e95ee99b8c136ff687eb07a2481ee04560cb1526408eb22ab56cd9c60206916") version("1.1803.1", sha256="70ce7125c02601e14abe5985243d67adf677ed9e7a4dd6d3eaef8a97cf281a16") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build Faodel as shared libs") variant("mpi", default=True, description="Enable MPI") diff --git a/var/spack/repos/builtin/packages/fargparse/package.py b/var/spack/repos/builtin/packages/fargparse/package.py index 232f949901effc..09b1ee0ca11668 100644 --- a/var/spack/repos/builtin/packages/fargparse/package.py +++ b/var/spack/repos/builtin/packages/fargparse/package.py @@ -30,6 +30,8 @@ class Fargparse(CMakePackage): version("1.2.0", sha256="4d14584d2bd5406267e3eacd35b50548dd9e408526465e89514690774217da70") version("1.1.2", sha256="89f63f181ccf183ca6212aee7ed7e39d510e3df938b0b16d487897ac9a61647f") + depends_on("fortran", type="build") # generated + depends_on("gftl-shared") depends_on("gftl") depends_on("cmake@3.12:", type="build") diff --git a/var/spack/repos/builtin/packages/fast-global-file-status/package.py b/var/spack/repos/builtin/packages/fast-global-file-status/package.py index 916bcab19334c5..cf5ceec34442dc 100644 --- a/var/spack/repos/builtin/packages/fast-global-file-status/package.py +++ b/var/spack/repos/builtin/packages/fast-global-file-status/package.py @@ -23,6 +23,9 @@ class FastGlobalFileStatus(AutotoolsPackage): ) version("1.1", sha256="e6fba4a0b7f055899fa0e05d93a435c7f1f2ec1158b9a6647dc8d2bcf9c2e164") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("mrnet") # we depend on mpa@master for bug fixes since mpa 1.1 depends_on("mount-point-attributes@1.1.1:") diff --git a/var/spack/repos/builtin/packages/fasta/package.py b/var/spack/repos/builtin/packages/fasta/package.py index 412fb7b28d2c25..c7c6ae641f2806 100644 --- a/var/spack/repos/builtin/packages/fasta/package.py +++ b/var/spack/repos/builtin/packages/fasta/package.py @@ -28,6 +28,8 @@ class Fasta(MakefilePackage): url="https://github.com/wrpearson/fasta36/archive/refs/tags/v36.3.8h_04-May-2020.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("zlib-api") # The src tree includes a plethora of variant Makefiles and the diff --git a/var/spack/repos/builtin/packages/fastani/package.py b/var/spack/repos/builtin/packages/fastani/package.py index fe8a3ee2d5bc11..9658e3b40e2f8c 100644 --- a/var/spack/repos/builtin/packages/fastani/package.py +++ b/var/spack/repos/builtin/packages/fastani/package.py @@ -19,6 +19,8 @@ class Fastani(CMakePackage, AutotoolsPackage): version("1.34", sha256="dc185cf29b9fa40cdcc2c83bb48150db46835e49b9b64a3dbff8bc4d0f631cb1") version("1.33", sha256="0b18b3074094722fb1b2247c1a1c4eb96295fff369b837f422e05072740e0013") + depends_on("cxx", type="build") # generated + build_system(conditional("cmake", when="@1.34:"), "autotools", default="cmake") depends_on("autoconf", type="build", when="build_system=autotools") diff --git a/var/spack/repos/builtin/packages/fastdb/package.py b/var/spack/repos/builtin/packages/fastdb/package.py index a99b515fde7fa0..38404ad9f121f9 100644 --- a/var/spack/repos/builtin/packages/fastdb/package.py +++ b/var/spack/repos/builtin/packages/fastdb/package.py @@ -16,6 +16,9 @@ class Fastdb(MakefilePackage): version("3.75", sha256="eeafdb2ad01664c29e2d4053a305493bdedc8e91612ab25f1d36ad2f95b0dad6") version("3.74", sha256="4d0c9a165a1031860d4853d7084b8fe4627f0004861e6070927d3b6c594af889") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("fastdb-fmax-fmin.patch") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/fastdfs/package.py b/var/spack/repos/builtin/packages/fastdfs/package.py index 0192f7cc19295f..954680a11bc15b 100644 --- a/var/spack/repos/builtin/packages/fastdfs/package.py +++ b/var/spack/repos/builtin/packages/fastdfs/package.py @@ -27,6 +27,8 @@ class Fastdfs(Package): version("6.02", sha256="b1801f80da9ebce1d84e7e05356c4614190651cb6a5cb4f5662d9196fe243e21") version("6.01", sha256="b72f4ff6beb21a83af59aeba9f1904e727fa2c1e960e0a9c2b969138d2804148") + depends_on("c", type="build") # generated + depends_on("perl", type="build") depends_on("libfastcommon", type="build") diff --git a/var/spack/repos/builtin/packages/fastjar/package.py b/var/spack/repos/builtin/packages/fastjar/package.py index 1a124ff62d3984..6bc2164d99741c 100644 --- a/var/spack/repos/builtin/packages/fastjar/package.py +++ b/var/spack/repos/builtin/packages/fastjar/package.py @@ -16,4 +16,6 @@ class Fastjar(AutotoolsPackage): version("0.98", sha256="f156abc5de8658f22ee8f08d7a72c88f9409ebd8c7933e9466b0842afeb2f145") + depends_on("c", type="build") # generated + depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/fastjet/package.py b/var/spack/repos/builtin/packages/fastjet/package.py index d39e12cc2504ac..e5b83176a7d454 100644 --- a/var/spack/repos/builtin/packages/fastjet/package.py +++ b/var/spack/repos/builtin/packages/fastjet/package.py @@ -58,6 +58,9 @@ class Fastjet(AutotoolsPackage): version("2.3.2", sha256="ba8b17fcc8edae16faa74608e8da53e87a8c574aa21a28c985ea0dfedcb95210") version("2.3.1", sha256="16c32b420e1aa7d0b6fecddd980ea0f2b7e3c2c66585e06f0eb3142677ab6ccf") version("2.3.0", sha256="e452fe4a9716627bcdb726cfb0917f46a7ac31f6006330a6ccc1abc43d9c2d53") + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated # older version use .tar instead of .tar.gz extension, to be added variant("shared", default=True, description="Builds a shared version of the library") @@ -72,6 +75,36 @@ class Fastjet(AutotoolsPackage): ) variant("atlas", default=False, description="Patch to make random generator thread_local") + variant( + "cxxstd", + default="11", + values=("11", "17", "20", "23"), + multi=False, + description="Use the specified C++ standard when building", + ) + + available_plugins = ( + conditional("atlascone", when="@2.4.0:"), + conditional("cdfcones", when="@2.1.0:"), + conditional("cmsiterativecone", when="@2.4.0:"), + conditional("d0runicone", when="@3.0.0:"), + conditional("d0runiicone", when="@2.4.0:"), + conditional("eecambridge", when="@2.4.0:"), + conditional("gridjet", when="@3.0.0:"), + conditional("jade", when="@2.4.0:"), + conditional("nesteddefs", when="@2.4.0:"), + conditional("pxcone", when="@2.1.0:"), + conditional("siscone", when="@2.1.0:"), + conditional("trackjet", when="@2.4.0:"), + ) + variant( + "plugins", + multi=True, + values=("all", "cxx") + available_plugins, + default="all", + description="List of plugins to enable, or 'cxx' or 'all'", + ) + patch("atlas.patch", when="@:3.3 +atlas", level=0) patch( "https://gitlab.cern.ch/sft/lcgcmake/-/raw/23c82f269b8e5df0190e20b7fbe06db16b24d667/externals/patches/fastjet-3.4.1.patch", @@ -81,7 +114,21 @@ class Fastjet(AutotoolsPackage): ) def configure_args(self): - extra_args = ["--enable-allplugins"] + extra_args = [] + plugins = self.spec.variants["plugins"].value + if "all" in plugins: + extra_args += ["--enable-allplugins"] + elif "cxx" in plugins: + extra_args += ["--enable-allcxxplugins"] + else: + for plugin in self.available_plugins: + # conditional returns an iterable _ConditionalVariantValues + for v in plugin: + # this version does not support this plugin + if not self.spec.satisfies(v.when): + continue + enabled = v.value in plugins + extra_args += [f"--{'enable' if enabled else 'disable'}-{v.value}"] extra_args += self.enable_or_disable("shared") extra_args += self.enable_or_disable("auto-ptr") if self.spec.variants["thread-safety"].value == "limited": @@ -90,3 +137,8 @@ def configure_args(self): extra_args += ["--enable-thread-safety"] return extra_args + + def flag_handler(self, name, flags): + if name == "cxxflags": + flags.append(f"-std=c++{self.spec.variants['cxxstd'].value}") + return (None, flags, None) diff --git a/var/spack/repos/builtin/packages/fastor/package.py b/var/spack/repos/builtin/packages/fastor/package.py new file mode 100644 index 00000000000000..c6ff4fa6f9585d --- /dev/null +++ b/var/spack/repos/builtin/packages/fastor/package.py @@ -0,0 +1,27 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Fastor(CMakePackage): + """Fastor is a lightweight high performance tensor algebra framework + for modern C++.""" + + homepage = "https://github.com/romeric/Fastor" + url = "https://github.com/romeric/Fastor/archive/refs/tags/V0.6.4.tar.gz" + + maintainers("wdconinc") + + license("MIT", checked_by="wdconinc") + + version("0.6.4", sha256="c97a3b9dbb92413be90689af9d942cddee12a74733cf42f1a8014965553a11f8") + + depends_on("cxx", type="build") # generated + + depends_on("cmake@3.20:", type="build") + + def cmake_args(self): + return [self.define("BUILD_TESTING", self.run_tests)] diff --git a/var/spack/repos/builtin/packages/fastp/package.py b/var/spack/repos/builtin/packages/fastp/package.py index 422b0294bd1f04..03ff52e50ec01b 100644 --- a/var/spack/repos/builtin/packages/fastp/package.py +++ b/var/spack/repos/builtin/packages/fastp/package.py @@ -19,6 +19,8 @@ class Fastp(MakefilePackage): version("0.23.3", sha256="a37ee4b5dcf836a5a19baec645657b71d9dcd69ee843998f41f921e9b67350e3") version("0.20.0", sha256="8d751d2746db11ff233032fc49e3bcc8b53758dd4596fdcf4b4099a4d702ac22") + depends_on("cxx", type="build") # generated + depends_on("libisal", type=("build", "link"), when="@0.23:") depends_on("libdeflate", type=("build", "link"), when="@0.23:") diff --git a/var/spack/repos/builtin/packages/fastqvalidator/package.py b/var/spack/repos/builtin/packages/fastqvalidator/package.py index 588597d359b770..07a31ad7115860 100644 --- a/var/spack/repos/builtin/packages/fastqvalidator/package.py +++ b/var/spack/repos/builtin/packages/fastqvalidator/package.py @@ -14,6 +14,8 @@ class Fastqvalidator(MakefilePackage): version("2017-01-10", commit="6d619a34749e9d33c34ef0d3e0e87324ca77f320") + depends_on("cxx", type="build") # generated + resource( name="libStatGen", git="https://github.com/statgen/libStatGen.git", diff --git a/var/spack/repos/builtin/packages/fasttext/package.py b/var/spack/repos/builtin/packages/fasttext/package.py index 3efd1c347d7d0c..1fc57b12ab3aa4 100644 --- a/var/spack/repos/builtin/packages/fasttext/package.py +++ b/var/spack/repos/builtin/packages/fasttext/package.py @@ -19,3 +19,5 @@ class Fasttext(CMakePackage): version("0.9.1", sha256="254ace2fc8dc3bea0fc6ad4897a221eb85c1e9adfa61d130b43398193ca1f061") version("0.2.0", sha256="71d24ffec9fcc4364554ecac2b3308d834178c903d16d090aa6be9ea6b8e480c") version("0.1.0", sha256="d6b4932b18d2c8b3d50905028671aadcd212b7aa31cbc6dd6cac66db2eff1397") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/fasttransforms/package.py b/var/spack/repos/builtin/packages/fasttransforms/package.py index 5c35700bdbd159..63e90ee45cc790 100644 --- a/var/spack/repos/builtin/packages/fasttransforms/package.py +++ b/var/spack/repos/builtin/packages/fasttransforms/package.py @@ -22,6 +22,8 @@ class Fasttransforms(MakefilePackage): version("0.5.0", sha256="9556d0037bd5348a33f15ad6100e32053b6e22cab16a97c504f30d6c52fd0efd") version("0.3.4", sha256="a5c8b5aedbdb40218521d061a7df65ef32ce153d4e19d232957db7e3e63c7e9b") + depends_on("c", type="build") # generated + variant("quadmath", default=False, description="Support 128-bit floats") depends_on("blas") diff --git a/var/spack/repos/builtin/packages/fastx-toolkit/package.py b/var/spack/repos/builtin/packages/fastx-toolkit/package.py index 651cc94255ddbf..3279c83915f56d 100644 --- a/var/spack/repos/builtin/packages/fastx-toolkit/package.py +++ b/var/spack/repos/builtin/packages/fastx-toolkit/package.py @@ -17,6 +17,9 @@ class FastxToolkit(AutotoolsPackage): version("0.0.14", sha256="9e1f00c4c9f286be59ac0e07ddb7504f3b6433c93c5c7941d6e3208306ff5806") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libgtextutils") # patch implicit fallthrough diff --git a/var/spack/repos/builtin/packages/faust/package.py b/var/spack/repos/builtin/packages/faust/package.py index f2268f2573453f..4649a9cfc05d7b 100644 --- a/var/spack/repos/builtin/packages/faust/package.py +++ b/var/spack/repos/builtin/packages/faust/package.py @@ -16,11 +16,15 @@ class Faust(MakefilePackage): license("GPL-2.0-or-later") + version("2.72.14", sha256="f0c82b7e72b663c29c226e5a56f6c43595b7d02c3d63eca0103cd327df4f33cd") version("2.70.3", sha256="644484f95167fe63014eac3db410f50c58810289fea228a2221e07d27da50eec") version("2.54.9", sha256="14648f020d77874e6f7411d7ff605820015645bbd4b891b24bee3d3a898e48d2") version("2.27.2", sha256="3367a868a93b63582bae29ab8783f1df7a10f4084a2bc1d2258ebf3d6a8c31d7") version("2.27.1", sha256="b3e93ca573025b231931e5eb92efc1a1e7f7720902aa3b285061519600a8c417") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake", type="build") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/fbgemm/package.py b/var/spack/repos/builtin/packages/fbgemm/package.py index 39893255ed4e6b..e0a6c5cfa05a91 100644 --- a/var/spack/repos/builtin/packages/fbgemm/package.py +++ b/var/spack/repos/builtin/packages/fbgemm/package.py @@ -56,6 +56,9 @@ class Fbgemm(CMakePackage): "2018-12-04", commit="0d5a159b944252e70a677236b570f291943e0543", submodules=True ) # py-torch@1.0.0 + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@3.5:", type="build") depends_on("python", type="build") diff --git a/var/spack/repos/builtin/packages/fcgi/package.py b/var/spack/repos/builtin/packages/fcgi/package.py index 0f1f88f8708f27..97f6b462281df5 100644 --- a/var/spack/repos/builtin/packages/fcgi/package.py +++ b/var/spack/repos/builtin/packages/fcgi/package.py @@ -28,4 +28,7 @@ class Fcgi(AutotoolsPackage): url="https://github.com/FastCGI-Archives/FastCGI.com/raw/master/original_snapshot/fcgi-2.4.1-SNAP-0910052249.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + parallel = False diff --git a/var/spack/repos/builtin/packages/fckit/package.py b/var/spack/repos/builtin/packages/fckit/package.py index 5822e13344fdb6..ddea92b5064d73 100644 --- a/var/spack/repos/builtin/packages/fckit/package.py +++ b/var/spack/repos/builtin/packages/fckit/package.py @@ -27,6 +27,9 @@ class Fckit(CMakePackage): version("0.10.0", sha256="f16829f63a01cdef5e158ed2a51f6d4200b3fe6dce8f251af158141a1afe482b") version("0.9.5", sha256="183cd78e66d3283d9e6e8e9888d3145f453690a4509fb701b28d1ac6757db5de") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("python") depends_on("ecbuild", type=("build")) @@ -74,7 +77,12 @@ def cmake_args(self): # See comment above (conflicts for finalize_ddts) args.append("-DENABLE_FINAL=OFF") - if self.spec.satisfies("%intel") or self.spec.satisfies("%gcc"): + if ( + self.spec.satisfies("%intel") + or self.spec.satisfies("%oneapi") + or self.spec.satisfies("%gcc") + or self.spec.satisfies("%nvhpc") + ): cxxlib = "stdc++" elif self.spec.satisfies("%clang") or self.spec.satisfies("%apple-clang"): cxxlib = "c++" diff --git a/var/spack/repos/builtin/packages/fd/package.py b/var/spack/repos/builtin/packages/fd/package.py index 47f0d13eac6a67..4f4887c1a24ae9 100644 --- a/var/spack/repos/builtin/packages/fd/package.py +++ b/var/spack/repos/builtin/packages/fd/package.py @@ -16,6 +16,7 @@ class Fd(CargoPackage): license("Apache-2.0 OR MIT") + version("10.1.0", sha256="ee4b2403388344ff60125c79ff25b7895a170e7960f243ba2b5d51d2c3712d97") version("9.0.0", sha256="306d7662994e06e23d25587246fa3fb1f528579e42a84f5128e75feec635a370") version("8.7.0", sha256="13da15f3197d58a54768aaad0099c80ad2e9756dd1b0c7df68c413ad2d5238c9") version("8.4.0", sha256="d0c2fc7ddbe74e3fd88bf5bb02e0f69078ee6d2aeea3d8df42f508543c9db05d") diff --git a/var/spack/repos/builtin/packages/fdb/package.py b/var/spack/repos/builtin/packages/fdb/package.py index 547f5bdbc120a5..74994b9ff10f44 100644 --- a/var/spack/repos/builtin/packages/fdb/package.py +++ b/var/spack/repos/builtin/packages/fdb/package.py @@ -24,6 +24,9 @@ class Fdb(CMakePackage): version("5.10.8", sha256="6a0db8f98e13c035098dd6ea2d7559f883664cbf9cba8143749539122ac46099") version("5.7.8", sha256="6adac23c0d1de54aafb3c663d077b85d0f804724596623b381ff15ea4a835f60") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("tools", default=True, description="Build the command line tools") variant( "backends", diff --git a/var/spack/repos/builtin/packages/fds/package.py b/var/spack/repos/builtin/packages/fds/package.py index 0b08921af187e6..e4707f92076a00 100644 --- a/var/spack/repos/builtin/packages/fds/package.py +++ b/var/spack/repos/builtin/packages/fds/package.py @@ -23,6 +23,8 @@ class Fds(MakefilePackage): version("6.8.0", commit="886e0096535519b7358a3c4393c91da3caee5072") + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("mkl") diff --git a/var/spack/repos/builtin/packages/fdupes/package.py b/var/spack/repos/builtin/packages/fdupes/package.py index fcb2010409a887..80174e0c0c865d 100644 --- a/var/spack/repos/builtin/packages/fdupes/package.py +++ b/var/spack/repos/builtin/packages/fdupes/package.py @@ -20,6 +20,8 @@ class Fdupes(AutotoolsPackage): version("2.2.1", sha256="846bb79ca3f0157856aa93ed50b49217feb68e1b35226193b6bc578be0c5698d") version("2.1.2", sha256="cd5cb53b6d898cf20f19b57b81114a5b263cc1149cd0da3104578b083b2837bd") + depends_on("c", type="build") # generated + variant("ncurses", default=True, description="ncurses support") depends_on("ncurses", when="+ncurses") diff --git a/var/spack/repos/builtin/packages/feh/package.py b/var/spack/repos/builtin/packages/feh/package.py index e41ba4e1bb948e..5e7c3657a921ad 100644 --- a/var/spack/repos/builtin/packages/feh/package.py +++ b/var/spack/repos/builtin/packages/feh/package.py @@ -25,6 +25,8 @@ class Feh(MakefilePackage): version("3.3", sha256="f3959958258111d5f7c9fbe2e165c52b9d5987f07fd1f37540a4abf9f9638811") version("3.1.1", sha256="61d0242e3644cf7c5db74e644f0e8a8d9be49b7bd01034265cc1ebb2b3f9c8eb") + depends_on("c", type="build") # generated + depends_on("imlib2") depends_on("curl") depends_on("libxinerama") diff --git a/var/spack/repos/builtin/packages/fenics-basix/package.py b/var/spack/repos/builtin/packages/fenics-basix/package.py index 5dfb0e9cc0413c..c42092c2f1a30a 100644 --- a/var/spack/repos/builtin/packages/fenics-basix/package.py +++ b/var/spack/repos/builtin/packages/fenics-basix/package.py @@ -17,33 +17,17 @@ class FenicsBasix(CMakePackage): license("MIT") version("main", branch="main") + version("0.8.0", sha256="b299af82daf8fa3e4845e17f202491fe71b313bf6ab64c767a5287190b3dd7fe") version("0.7.0", sha256="9bee81b396ee452eec8d9735f278cb44cb6994c6bc30aec8ed9bb4b12d83fa7f") version("0.6.0", sha256="687ae53153c98facac4080dcdc7081701db1dcea8c5e7ae3feb72aec17f83304") - version( - "0.5.1", - sha256="69133476ac35f0bd0deccb480676030378c341d7dfb2adaca22cd16b7e1dc1cb", - deprecated=True, - ) - version( - "0.4.2", - sha256="a54f5e442b7cbf3dbb6319c682f9161272557bd7f42e2b8b8ccef88bc1b7a22f", - deprecated=True, - ) + + depends_on("cxx", type="build") # generated depends_on("cmake@3.19:", type="build") depends_on("blas") depends_on("lapack") - depends_on("xtensor@0.23.10:", when="@:0.4") - depends_on("xtl@0.7.2:", when="@:0.4") - - conflicts( - "%gcc@:9.10", when="@0.5.0:", msg="fenics-basix requires GCC-10 or newer for C++20 support" - ) - conflicts( - "%clang@:9.10", - when="@0.5.0:", - msg="fenics-basix requires Clang-10 or newer for C++20 support", - ) + conflicts("%gcc@:9.10", msg="fenics-basix requires GCC-10 or newer for C++20 support") + conflicts("%clang@:9.10", msg="fenics-basix requires Clang-10 or newer for C++20 support") root_cmakelists_dir = "cpp" diff --git a/var/spack/repos/builtin/packages/fenics-dolfinx/package.py b/var/spack/repos/builtin/packages/fenics-dolfinx/package.py index 4255cf3a45f300..ba871cd731b1db 100644 --- a/var/spack/repos/builtin/packages/fenics-dolfinx/package.py +++ b/var/spack/repos/builtin/packages/fenics-dolfinx/package.py @@ -17,34 +17,11 @@ class FenicsDolfinx(CMakePackage): license("LGPL-3.0-or-later") version("main", branch="main") + version("0.8.0", sha256="acf3104d9ecc0380677a6faf69eabfafc58d0cce43f7777e1307b95701c7cad9") version("0.7.2", sha256="7d9ce1338ce66580593b376327f23ac464a4ce89ef63c105efc1a38e5eae5c0b") version("0.6.0", sha256="eb8ac2bb2f032b0d393977993e1ab6b4101a84d54023a67206e3eac1a8d79b80") - version( - "0.5.1", - sha256="a570e3f6ed8e7c570e7e61d0e6fd44fa9dad2c5f8f1f48a6dc9ad22bacfbc973", - deprecated=True, - ) - version( - "0.5.0", - sha256="503c70c01a44d1ffe48e052ca987693a49f8d201877652cabbe2a44eb3b7c040", - deprecated=True, - ) - version( - "0.4.1", - sha256="68dcf29a26c750fcea5e02d8d58411e3b054313c3bf6fcbc1d0f08dd2851117f", - deprecated=True, - ) - conflicts( - "%gcc@:9.10", - when="@0.5.0:", - msg="fenics-dolfinx requires GCC-10 or newer for C++20 support", - ) - conflicts( - "%clang@:9.10", - when="@0.5.0:", - msg="fenics-dolfinx requires Clang-10 or newer for C++20 support", - ) + depends_on("cxx", type="build") # generated # Graph partitioner variants variant( @@ -56,8 +33,7 @@ class FenicsDolfinx(CMakePackage): ) # Graph partitioner dependencies - depends_on("kahip@3.12:", when="partitioners=kahip @0.5.0:") - depends_on("kahip@3.11", when="partitioners=kahip @:0.4.1") + depends_on("kahip@3.12:", when="partitioners=kahip") depends_on("parmetis", when="partitioners=parmetis") depends_on("scotch+mpi", when="partitioners=scotch") @@ -69,39 +45,26 @@ class FenicsDolfinx(CMakePackage): depends_on("mpi") depends_on("hdf5+mpi") depends_on("boost@1.7.0:+filesystem+program_options+timer") + depends_on("pugixml") + depends_on("spdlog", when="@0.9:") depends_on("petsc+mpi+shared") - depends_on("xtensor@0.23.10:", when="@:0.5") - depends_on("xtl@0.7.2:", when="@:0.5") - depends_on("slepc", when="+slepc") depends_on("adios2+mpi", when="+adios2") - depends_on("pugixml", when="@0.5.0:") depends_on("fenics-ufcx@main", when="@main") + depends_on("fenics-ufcx@0.8", when="@0.8") depends_on("fenics-ufcx@0.7", when="@0.7") - depends_on("fenics-ufcx@0.6.0:0.6", when="@0.6.0:0.6") - depends_on("fenics-ufcx@0.5.0", when="@0.5.1:0.5") - depends_on("fenics-ufcx@0.4.2", when="@0.4.1") + depends_on("fenics-ufcx@0.6", when="@0.6") depends_on("fenics-basix@main", when="@main") + depends_on("fenics-basix@0.8", when="@0.8") depends_on("fenics-basix@0.7", when="@0.7") - depends_on("fenics-basix@0.6.0:0.6", when="@0.6.0:0.6") - depends_on("fenics-basix@0.5.1:0.5", when="@0.5.0:0.5") - depends_on("fenics-basix@0.4.2", when="@0.4.1") - - conflicts( - "%gcc@:9.10", - when="@0.5.0:", - msg="fenics-dolfinx requires GCC-10 or newer for C++20 support", - ) - conflicts( - "%clang@:9.10", - when="@0.5.0:", - msg="fenics-dolfinx requires Clang-10 or newer for C++20 support", - ) - conflicts("%gcc@:8", msg="fenics-dolfinx requires GCC-9 or newer for improved C++17 support") + depends_on("fenics-basix@0.6", when="@0.6") + + conflicts("%gcc@:9.10", msg="fenics-dolfinx requires GCC-10 or newer for C++20 support") + conflicts("%clang@:9.10", msg="fenics-dolfinx requires Clang-10 or newer for C++20 support") root_cmakelists_dir = "cpp" diff --git a/var/spack/repos/builtin/packages/fenics-ufcx/package.py b/var/spack/repos/builtin/packages/fenics-ufcx/package.py index 93657bb9d03510..fdbc09cbc5bf52 100644 --- a/var/spack/repos/builtin/packages/fenics-ufcx/package.py +++ b/var/spack/repos/builtin/packages/fenics-ufcx/package.py @@ -14,28 +14,14 @@ class FenicsUfcx(CMakePackage): homepage = "https://github.com/FEniCS/ffcx" git = "https://github.com/FEniCS/ffcx.git" url = "https://github.com/FEniCS/ffcx/archive/v0.4.2.tar.gz" - maintainers("ma595", "jhale") + maintainers("ma595", "jhale", "garth-wells", "chrisrichardson") license("LGPL-3.0-or-later") version("main", branch="main") + version("0.8.0", sha256="8a854782dbd119ec1c23c4522a2134d5281e7f1bd2f37d64489f75da055282e3") version("0.7.0", sha256="7f3c3ca91d63ce7831d37799cc19d0551bdcd275bdfa4c099711679533dd1c71") version("0.6.0", sha256="076fad61d406afffd41019ae1abf6da3f76406c035c772abad2156127667980e") - version( - "0.5.0.post0", - sha256="039908c9998b51ba53e5deb3a97016062c262f0a4285218644304f7d3cd35882", - deprecated=True, - ) - version( - "0.5.0", - sha256="3413409e5885e41e220f99e0f95cc817e94c4931143d1f700c6e0c5e1bfad1f6", - deprecated=True, - ) - version( - "0.4.2", - sha256="3be6eef064d6ef907245db5b6cc15d4e603762e68b76e53e099935ca91ef1ee4", - deprecated=True, - ) depends_on("cmake@3.19:", type="build") diff --git a/var/spack/repos/builtin/packages/fenics/package.py b/var/spack/repos/builtin/packages/fenics/package.py index ae8336aa39e74c..0cd60596fbf656 100644 --- a/var/spack/repos/builtin/packages/fenics/package.py +++ b/var/spack/repos/builtin/packages/fenics/package.py @@ -40,6 +40,8 @@ class Fenics(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + dolfin_versions = ["2019.1.0", "2018.1.0", "2017.2.0", "2016.2.0"] variant("python", default=True, description="Compile with Python interface") @@ -156,7 +158,7 @@ class Fenics(CMakePackage): depends_on("py-sphinx@1.0.1:", when="+doc", type="build") def cmake_args(self): - args = [ + return [ self.define_from_variant("BUILD_SHARED_LIBS", "shared"), self.define("DOLFIN_SKIP_BUILD_TESTS", True), self.define_from_variant("DOLFIN_ENABLE_OPENMP", "openmp"), @@ -180,11 +182,6 @@ def cmake_args(self): self.define_from_variant("DOLFIN_ENABLE_ZLIB", "zlib"), ] - if "+python" in self.spec: - args.append(self.define("PYTHON_EXECUTABLE", self.spec["python"].command.path)) - - return args - # set environment for bulding python interface def setup_build_environment(self, env): env.set("DOLFIN_DIR", self.prefix) diff --git a/var/spack/repos/builtin/packages/feq-parse/package.py b/var/spack/repos/builtin/packages/feq-parse/package.py index f470cab980928d..fd55780e677c74 100644 --- a/var/spack/repos/builtin/packages/feq-parse/package.py +++ b/var/spack/repos/builtin/packages/feq-parse/package.py @@ -11,19 +11,24 @@ class FeqParse(CMakePackage): is used to interpret and evaluate functions provided as strings.""" - homepage = "https://github.com/FluidNumerics/feq-parse" + homepage = "https://feqparse.fluidnumerics.com" url = "https://github.com/FluidNumerics/feq-parse/archive/v2.0.1.tar.gz" maintainers("fluidnumerics-joe") - license("Apache-2.0") + license("3-Clause BSD") + version("2.2.2", sha256="cfbf6142186c2e61b373237dd94d68013c1e8202a2b14dfd7aa6b8befbe330eb") + version("2.2.1", sha256="d25f81c0e514cf9fad77190d9edf994b94eaebd414cf639cfaa690a9a1cc9cbf") + version("2.2.0", sha256="962fca2de745bc3b436cb2299c917184ce2d9ac5edf95aad3c103efb63ed311a") version("2.1.0", sha256="f3fd51c24c563fe1d0dcb880bc16a62c9e08fe0cdd6f58df08f0db0ed34c289a") version("2.0.3", sha256="a1c42507801adc55a63a9a904807058079d54e002e10f2b29a916b06fc815f80") version("2.0.1", sha256="08dd08bd100a0a2eb672a5b2792ad56a337df575c634aac0d7a300d7e484b21c") version("1.1.0", sha256="d33a4fd6904939bb70780e8f25f37c1291c4f24fd207feb4ffc0f8d89637d1e3") version("1.0.2", sha256="1cd1db7562908ea16fc65dc5268b654405d0b3d9dcfe11f409949c431b48a3e8") + depends_on("fortran", type="build") # generated + depends_on("cmake@3.0.2:", type="build") parallel = False diff --git a/var/spack/repos/builtin/packages/fermikit/package.py b/var/spack/repos/builtin/packages/fermikit/package.py index 9bc92d4a285d9d..583d20681829a0 100644 --- a/var/spack/repos/builtin/packages/fermikit/package.py +++ b/var/spack/repos/builtin/packages/fermikit/package.py @@ -15,6 +15,8 @@ class Fermikit(MakefilePackage): version("2017-11-7", commit="bf9c7112221577ba110665bddca8f1987250bdc7", submodules=True) + depends_on("c", type="build") # generated + depends_on("zlib-api") depends_on("sse2neon", when="target=aarch64:") diff --git a/var/spack/repos/builtin/packages/fermisciencetools/package.py b/var/spack/repos/builtin/packages/fermisciencetools/package.py index 739bd4c4eaa723..019845322060ef 100644 --- a/var/spack/repos/builtin/packages/fermisciencetools/package.py +++ b/var/spack/repos/builtin/packages/fermisciencetools/package.py @@ -21,5 +21,9 @@ class Fermisciencetools(Package): # can figure it out and we can use the source distribution instead. version("11r5p3", sha256="2f4fc32a0b2e5c0f1ddb220a0560f67e66052b7907c72dba181908dc9269ffe8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + def install(self, spec, prefix): install_tree("x86_64-unknown-linux-gnu-libc2.17", prefix) diff --git a/var/spack/repos/builtin/packages/ferret/package.py b/var/spack/repos/builtin/packages/ferret/package.py index 56494e0b0932bc..dea3a7fbb634f0 100644 --- a/var/spack/repos/builtin/packages/ferret/package.py +++ b/var/spack/repos/builtin/packages/ferret/package.py @@ -28,6 +28,9 @@ class Ferret(Package): version("7.2", sha256="21c339b1bafa6939fc869428d906451f130f7e77e828c532ab9488d51cf43095") version("6.96", sha256="7eb87156aa586cfe838ab83f08b2102598f9ab62062d540a5da8c9123816331a") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("datasets", default=False, description="Install Ferret standard datasets") depends_on("hdf5+hl") diff --git a/var/spack/repos/builtin/packages/feynhiggs/package.py b/var/spack/repos/builtin/packages/feynhiggs/package.py index 0a3afb7c10bbcf..9e6875dd36efa2 100644 --- a/var/spack/repos/builtin/packages/feynhiggs/package.py +++ b/var/spack/repos/builtin/packages/feynhiggs/package.py @@ -22,5 +22,9 @@ class Feynhiggs(AutotoolsPackage): version("2.18.1", sha256="3aba89cac6397d7e1a8a9d9dcfeed9fb32eeeee98768b0c0c9f444c2cc125ab9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + def configure_args(self): return ["FFLAGS=-fPIC", "CFLAGS=-fPIC"] diff --git a/var/spack/repos/builtin/packages/ffmpeg/package.py b/var/spack/repos/builtin/packages/ffmpeg/package.py index ce88037520b07b..19ee7f2eb4dfb4 100644 --- a/var/spack/repos/builtin/packages/ffmpeg/package.py +++ b/var/spack/repos/builtin/packages/ffmpeg/package.py @@ -12,26 +12,41 @@ class Ffmpeg(AutotoolsPackage): homepage = "https://ffmpeg.org" url = "https://ffmpeg.org/releases/ffmpeg-4.1.1.tar.bz2" + git = "https://git.ffmpeg.org/ffmpeg.git" maintainers("xjrc") license("GPL-2.0-or-later AND LGPL-2.1-or-later") + version("master", branch="master") + version("7.0", sha256="a24d9074bf5523a65aaa9e7bd02afe4109ce79d69bd77d104fed3dab4b934d7a") + version( + "6.1.1", + sha256="5e3133939a61ef64ac9b47ffd29a5ea6e337a4023ef0ad972094b4da844e3a20", + preferred=True, + ) version("6.0", sha256="47d062731c9f66a78380e35a19aac77cebceccd1c7cc309b9c82343ffc430c3d") + version("5.1.4", sha256="c3c1e316bf91468738dd0aff6eb1faab409f1edcd34fd1a4213626439bc5d743") version("5.1.3", sha256="5d5bef6a11f0c500588f9870ec965a30acc0d54d8b1e535da6554a32902d236d") version("5.1.2", sha256="39a0bcc8d98549f16c570624678246a6ac736c066cebdb409f9502e915b22f2b") + version("4.4.4", sha256="47b1fbf70a2c090d9c0fae5910da11c6406ca92408bb69d8c935cd46c622c7ce") version("4.4.1", sha256="8fc9f20ac5ed95115a9e285647add0eedd5cc1a98a039ada14c132452f98ac42") version("4.3.2", sha256="ab3a6d6a70358ba0a5f67f37f91f6656b7302b02e98e5b8c846c16763c99913a") version("4.2.2", sha256="b620d187c26f76ca19e74210a0336c3b8380b97730df5cdf45f3e69e89000e5c") version("4.1.1", sha256="0cb40e3b8acaccd0ecb38aa863f66f0c6e02406246556c2992f67bf650fab058") version("4.1", sha256="b684fb43244a5c4caae652af9022ed5d85ce15210835bce054a33fb26033a1a5") + version("3.4.13", sha256="f640aa6f92323558ee31314b773cf2e935def620474754b929e815f8f1ec933f") version("3.4.12", sha256="08e400330c70b567116addebd1a70279e0d41b0f8742085e32527f2a4eef9ca3") version("3.2.19", sha256="87a61fa3b20819b71633aa90b55ee6411614e4a0ff7908cf35236b465de5e602") version("3.2.4", sha256="c0fa3593a2e9e96ace3c1757900094437ad96d1d6ca19f057c378b5f394496a4") + version("2.8.22", sha256="c56534d2862d2690b28875e142e0364ab86d784a22775449f04bf995efbc7064") version("2.8.21", sha256="782c3af1a1ee8945be0800edc39b1d1199ee6a8f31c74b65230795f11911b0d8") version("2.8.15", sha256="35647f6c1f6d4a1719bc20b76bf4c26e4ccd665f46b5676c0e91c5a04622ee21") version("1.0.10", sha256="1dbde434c3b5c573d3b2ffc1babe3814f781c10c4bc66193a4132a44c9715176") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Licensing variant( "gpl", @@ -88,6 +103,8 @@ class Ffmpeg(AutotoolsPackage): depends_on("yasm@1.2.0:") depends_on("zlib-api") + depends_on("pkgconfig", type="build") + depends_on("aom", when="+libaom") depends_on("bzip2", when="+bzlib") depends_on("fontconfig", when="+drawtext") @@ -115,6 +132,13 @@ class Ffmpeg(AutotoolsPackage): conflicts("%nvhpc") + # Solve build failure against vulkan headers 1.3.279 + patch( + "https://git.ffmpeg.org/gitweb/ffmpeg.git/commitdiff_plain/fef22c87ada4", + sha256="856bdc2b6e2a7066cf683a235193b9025d4d73dd7686eda2fbcf83e7e65f8bf9", + when="@6.1.1", + ) + # Patch solving a build failure when vulkan is enabled patch( "https://git.ffmpeg.org/gitweb/ffmpeg.git/commitdiff_plain/eb0455d64690", @@ -126,14 +150,25 @@ class Ffmpeg(AutotoolsPackage): patch( "https://git.ffmpeg.org/gitweb/ffmpeg.git/commitdiff_plain/effadce6c756247ea8bae32dc13bb3e6f464f0eb", sha256="f070ac16be68b4d32b1b5b885d146eb36eb508daa928b6f0f78256c3482f9f0e", - when="@:6.0", + when="@6:6.0", + ) + # Patch fixing a build failure with binutils 2.41.0, already in @5.1.4 + patch( + "https://git.ffmpeg.org/gitweb/ffmpeg.git/commitdiff_plain/effadce6c756247ea8bae32dc13bb3e6f464f0eb", + sha256="f070ac16be68b4d32b1b5b885d146eb36eb508daa928b6f0f78256c3482f9f0e", + when="@:5.1.3", ) # fix incompatibility with texinfo@7, especially @7.1: patch( "https://git.ffmpeg.org/gitweb/ffmpeg.git/commitdiff_plain/f01fdedb69e4accb1d1555106d8f682ff1f1ddc7", sha256="416751f41cfbf086c28b4bbf01ace4c08e5651e59911dca6240292bb1b5c6b53", - when="@5:6.0", + when="@6.0", + ) + patch( + "https://git.ffmpeg.org/gitweb/ffmpeg.git/commitdiff_plain/f01fdedb69e4accb1d1555106d8f682ff1f1ddc7", + sha256="416751f41cfbf086c28b4bbf01ace4c08e5651e59911dca6240292bb1b5c6b53", + when="@5:5.1.3", ) @property @@ -149,6 +184,8 @@ def headers(self): @when("@:6.0 %apple-clang@15:") def setup_build_environment(self, env): env.append_flags("LDFLAGS", "-Wl,-ld_classic") + if self.spec.satisfies("@:3"): + env.append_flags("CFLAGS", "-Wno-error=incompatible-function-pointer-types") def enable_or_disable_meta(self, variant, options): switch = "enable" if "+{0}".format(variant) in self.spec else "disable" diff --git a/var/spack/repos/builtin/packages/ffsb/package.py b/var/spack/repos/builtin/packages/ffsb/package.py index 7000586d8ac175..8ca9c3c3ff27fc 100644 --- a/var/spack/repos/builtin/packages/ffsb/package.py +++ b/var/spack/repos/builtin/packages/ffsb/package.py @@ -18,3 +18,5 @@ class Ffsb(AutotoolsPackage): version("5.2.1", sha256="36ccda8ff04f837e20bb8b2cc9edb8c6fc923fdcdbb8060d9448dc49234b968d") version("5.1.1", sha256="e25aef255d8bfe54f29ac88c7af8237fa5a8c2e1716fdef1946cf0ecd9166d1f") version("5.1", sha256="4d7da7eba46c824ebdc23b3d32532b006aeb5b6697a3ada314c75785ab25cb97") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/ffte/package.py b/var/spack/repos/builtin/packages/ffte/package.py index 98f870f545821b..e9b479be0ef6b2 100644 --- a/var/spack/repos/builtin/packages/ffte/package.py +++ b/var/spack/repos/builtin/packages/ffte/package.py @@ -26,6 +26,8 @@ class Ffte(Package): version("2.0", sha256="f5cf1d1f880288e359f4d517191980ffca4420f817ecaa2d754ca5c5421271e3") version("1.0", sha256="35171e3324019018c25575b2807a6513fa85badad040f30f238fff03d4b4d1ab") + depends_on("fortran", type="build") # generated + variant("mpi", default=False, description="Build MPI library") variant("cuda", default=False, description="Use CUDA Fortran") variant("vector", default=False, description="Use vectorized FFT") diff --git a/var/spack/repos/builtin/packages/fftw/package.py b/var/spack/repos/builtin/packages/fftw/package.py index 7a4ac28eb73047..3c20fac5663334 100644 --- a/var/spack/repos/builtin/packages/fftw/package.py +++ b/var/spack/repos/builtin/packages/fftw/package.py @@ -25,6 +25,7 @@ class FftwBase(AutotoolsPackage): ) variant("openmp", default=False, description="Enable OpenMP support.") variant("mpi", default=True, description="Activate MPI support") + variant("shared", default=True, description="Build shared libraries") depends_on("mpi", when="+mpi") depends_on("llvm-openmp", when="%apple-clang +openmp") @@ -104,7 +105,9 @@ def setup_build_environment(self, env): def configure(self, spec, prefix): # Base options - options = ["--prefix={0}".format(prefix), "--enable-shared", "--enable-threads"] + options = ["--prefix={0}".format(prefix), "--enable-threads"] + options.extend(self.enable_or_disable("shared")) + if not self.compiler.f77 or not self.compiler.fc: options.append("--disable-fortran") if spec.satisfies("@:2"): @@ -227,6 +230,9 @@ class Fftw(FftwBase): version("3.3.4", sha256="8f0cde90929bc05587c3368d2f15cd0530a60b8a9912a8e2979a72dbe5af0982") version("2.1.5", sha256="f8057fae1c7df8b99116783ef3e94a6a44518d49c72e2e630c24b689c6022630") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "pfft_patches", default=False, diff --git a/var/spack/repos/builtin/packages/fftw/pfft-3.3.9.patch b/var/spack/repos/builtin/packages/fftw/pfft-3.3.9.patch index a4f0e6adc61673..31108f76afc9e3 100644 --- a/var/spack/repos/builtin/packages/fftw/pfft-3.3.9.patch +++ b/var/spack/repos/builtin/packages/fftw/pfft-3.3.9.patch @@ -21,6 +21,21 @@ RDFT_SRC = rdft-serial.c rdft-rank-geq2.c rdft-rank-geq2-transposed.c rdft-rank1-bigvec.c rdft-problem.c rdft-solve.c mpi-rdft.h RDFT2_SRC = rdft2-serial.c rdft2-rank-geq2.c rdft2-rank-geq2-transposed.c rdft2-problem.c rdft2-solve.c mpi-rdft2.h +--- mpi/mpi-transpose.h ++++ mpi/mpi-transpose.h +@@ -55,6 +55,11 @@ int XM(mkplans_posttranspose)(const problem_mpi_transpose *p, planner *plnr, + R *I, R *O, int my_pe, + plan **cld2, plan **cld2rest, plan **cld3, + INT *rest_Ioff, INT *rest_Ooff); ++/* transpose-pairwise-transposed.c: */ ++int XM(mkplans_pretranspose)(const problem_mpi_transpose *p, planner *plnr, ++ R *I, R *O, int my_pe, ++ plan **cld2, plan **cld2rest, plan **cld3, ++ INT *rest_Ioff, INT *rest_Ooff); + /* various solvers */ + void XM(transpose_pairwise_register)(planner *p); + void XM(transpose_alltoall_register)(planner *p); + --- mpi/mpi-transpose.h 2020-12-10 12:02:44.000000000 +0000 +++ mpi/mpi-transpose.h 2021-04-06 09:06:12.144841002 +0000 @@ -59,3 +59,5 @@ diff --git a/var/spack/repos/builtin/packages/fftx/package.py b/var/spack/repos/builtin/packages/fftx/package.py index fa4052cf01a8c7..b131288a471ae9 100644 --- a/var/spack/repos/builtin/packages/fftx/package.py +++ b/var/spack/repos/builtin/packages/fftx/package.py @@ -30,6 +30,8 @@ class Fftx(CMakePackage, CudaPackage, ROCmPackage): version("1.1.0", sha256="a6f95605abc11460bbf51839727a456a31488e27e12a970fc29a1b8c42f4e3b5") version("1.0.3", sha256="b5ff275facce4a2fbabd0aecc65dd55b744794f2e07cd8cfa91363001c664896") + depends_on("cxx", type="build") # generated + depends_on("spiral-software+fftx+simt+jit+mpi") # depend only on spiral-software, but spiral-software must be installed with variants: # +fftx +simt +mpi +jit diff --git a/var/spack/repos/builtin/packages/fgsl/package.py b/var/spack/repos/builtin/packages/fgsl/package.py index 3f16008ff49e6f..8711d91200aaf7 100644 --- a/var/spack/repos/builtin/packages/fgsl/package.py +++ b/var/spack/repos/builtin/packages/fgsl/package.py @@ -28,6 +28,9 @@ class Fgsl(AutotoolsPackage): version("1.2.0", sha256="e5a4ac08eb744c963e95a46a51d76c56593836077c5ad8c47e240cae57027002") version("1.1.0", sha256="a5adce3c3b279d2dacc05b74c598ff89be7ef3ae3ec59b3ec1355750c1bb4832") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/fiat/package.py b/var/spack/repos/builtin/packages/fiat/package.py index 488ecf450d85a4..e84b06000cf319 100644 --- a/var/spack/repos/builtin/packages/fiat/package.py +++ b/var/spack/repos/builtin/packages/fiat/package.py @@ -23,6 +23,10 @@ class Fiat(CMakePackage): version("1.1.0", sha256="58354e60d29a1b710bfcea9b87a72c0d89c39182cb2c9523ead76a142c695f82") version("1.0.0", sha256="45afe86117142831fdd61771cf59f31131f2b97f52a2bd04ac5eae9b2ab746b8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "build_type", default="RelWithDebInfo", diff --git a/var/spack/repos/builtin/packages/fides/package.py b/var/spack/repos/builtin/packages/fides/package.py index 29c5ea00c525a3..c7463005f75321 100644 --- a/var/spack/repos/builtin/packages/fides/package.py +++ b/var/spack/repos/builtin/packages/fides/package.py @@ -19,6 +19,8 @@ class Fides(CMakePackage): version("1.2.0", sha256="12be939d75c765dab9241f9ed2b64af01cce2b10281de402f64fb685e6ccd7df") version("1.1.0", sha256="40d2e08b8d5cfdfc809eae6ed2ae0731108ce3b1383485f4934a5ec8aaa9425e") version("1.0.0", sha256="c355fdb4ca3790c1fa9a4491a0d294b8f883b6946c540ad9e5633c9fd8c8c3aa") + + depends_on("cxx", type="build") # generated variant("mpi", default=True, description="build mpi support") # Certain CMake versions have been found to break for our use cases diff --git a/var/spack/repos/builtin/packages/figcone/package.py b/var/spack/repos/builtin/packages/figcone/package.py index 3b1135f6c32579..be38b281ed5e96 100644 --- a/var/spack/repos/builtin/packages/figcone/package.py +++ b/var/spack/repos/builtin/packages/figcone/package.py @@ -17,3 +17,5 @@ class Figcone(CMakePackage): version("3.0.0", sha256="24ed65c2dabc93b205c3adfdb5d7d0523286a956a0257dc5f15de91c5b828aea") version("2.4.9", sha256="735399e849621a4923e71a50d5e2ba928d5dfa3b01e54d56e0bac8e5102b7697") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/figlet/package.py b/var/spack/repos/builtin/packages/figlet/package.py index 2037a2de715196..bfefd211f7a50c 100644 --- a/var/spack/repos/builtin/packages/figlet/package.py +++ b/var/spack/repos/builtin/packages/figlet/package.py @@ -19,6 +19,8 @@ class Figlet(MakefilePackage): version("2.2.4", sha256="970a18a2a32cca736ff11a5b77e26a54f31a0e08606b85d21d3d5c666937e03d") version("2.2.3", sha256="168fa3c7a5888d6f796708780d3006f0e1871d83f32c4a10a84596b90ac35999") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) bins = ["figlet", "chkfont", "figlist", "showfigfonts"] diff --git a/var/spack/repos/builtin/packages/file/package.py b/var/spack/repos/builtin/packages/file/package.py index d2bc55cb710200..c79acb62b53db0 100644 --- a/var/spack/repos/builtin/packages/file/package.py +++ b/var/spack/repos/builtin/packages/file/package.py @@ -19,6 +19,7 @@ class File(AutotoolsPackage): license("BSD-2-Clause") + version("5.45", sha256="fc97f51029bb0e2c9f4e3bffefdaf678f0e039ee872b9de5c002a6d09c784d82") version("5.44", sha256="3751c7fba8dbc831cb8d7cc8aff21035459b8ce5155ef8b0880a27d028475f3b") version("5.43", sha256="8c8015e91ae0e8d0321d94c78239892ef9dbc70c4ade0008c0e95894abfb1991") version("5.42", sha256="c076fb4d029c74073f15c43361ef572cfb868407d347190ba834af3b1639b0e4") @@ -28,6 +29,8 @@ class File(AutotoolsPackage): version("5.38", sha256="593c2ffc2ab349c5aea0f55fedfe4d681737b6b62376a9b3ad1e77b2cc19fa34") version("5.37", sha256="e9c13967f7dd339a3c241b7710ba093560b9a33013491318e88e6b8b57bae07f") + depends_on("c", type="build") # generated + executables = ["^file$"] variant("static", default=True, description="Also build static libraries") diff --git a/var/spack/repos/builtin/packages/filebench/package.py b/var/spack/repos/builtin/packages/filebench/package.py index 4b1efcfad3a4fb..cc8d23badbcbd4 100644 --- a/var/spack/repos/builtin/packages/filebench/package.py +++ b/var/spack/repos/builtin/packages/filebench/package.py @@ -26,6 +26,9 @@ class Filebench(AutotoolsPackage): version("1.4.9.1", sha256="77ae91b83c828ded1219550aec74fbbd6975dce02cb5ab13c3b99ac2154e5c2e") version("1.4.9", sha256="61b8a838c1450b51a4ce61481a19a1bf0d6e3993180c524ff4051f7c18bd9c6a") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/filo/package.py b/var/spack/repos/builtin/packages/filo/package.py index fc778210cdeb36..ec349a006d4681 100644 --- a/var/spack/repos/builtin/packages/filo/package.py +++ b/var/spack/repos/builtin/packages/filo/package.py @@ -18,6 +18,8 @@ class Filo(CMakePackage): version("main", branch="main") + depends_on("c", type="build") # generated + depends_on("mpi") depends_on("axl") depends_on("kvtree") @@ -26,8 +28,6 @@ class Filo(CMakePackage): def cmake_args(self): args = [] args.append("-DMPI_C_COMPILER=%s" % self.spec["mpi"].mpicc) - if self.spec.satisfies("platform=cray"): - args.append("-DFILO_LINK_STATIC=ON") args.append("-DWITH_AXL_PREFIX=%s" % self.spec["axl"].prefix) args.append("-DWITH_KVTREE_PREFIX=%s" % self.spec["kvtree"].prefix) args.append("-DWITH_SPATH_PREFIX=%s" % self.spec["spath"].prefix) diff --git a/var/spack/repos/builtin/packages/filtlong/package.py b/var/spack/repos/builtin/packages/filtlong/package.py index ceb344bec17c6d..06038deda12a26 100644 --- a/var/spack/repos/builtin/packages/filtlong/package.py +++ b/var/spack/repos/builtin/packages/filtlong/package.py @@ -19,6 +19,8 @@ class Filtlong(MakefilePackage): version("0.2.0", sha256="a4afb925d7ced8d083be12ca58911bb16d5348754e7c2f6431127138338ee02a") version("0.1.1", sha256="ddae7a5850efeb64424965a443540b1ced34286fbefad9230ab71f4af314081b") + depends_on("cxx", type="build") # generated + depends_on("zlib-api") # %gcc@13: requires std libraries be manually added - add an include for `cstdint` diff --git a/var/spack/repos/builtin/packages/findutils/package.py b/var/spack/repos/builtin/packages/findutils/package.py index 6ff1decade2eba..92c8640c4a12e7 100644 --- a/var/spack/repos/builtin/packages/findutils/package.py +++ b/var/spack/repos/builtin/packages/findutils/package.py @@ -51,6 +51,8 @@ def url_for_version(self, version): version("4.1.20", sha256="8c5dd50a5ca54367fa186f6294b81ec7a365e36d670d9feac62227cb513e63ab") version("4.1", sha256="487ecc0a6c8c90634a11158f360977e5ce0a9a6701502da6cb96a5a7ec143fac") + depends_on("c", type="build") # generated + # The NVIDIA compilers do not currently support some GNU builtins. # Detect this case and use the fallback path. patch("nvhpc.patch", when="@4.6.0 %nvhpc") diff --git a/var/spack/repos/builtin/packages/fio/package.py b/var/spack/repos/builtin/packages/fio/package.py index ba5f513726c6f4..d9875f4039fd34 100644 --- a/var/spack/repos/builtin/packages/fio/package.py +++ b/var/spack/repos/builtin/packages/fio/package.py @@ -21,6 +21,7 @@ class Fio(AutotoolsPackage): license("GPL-2.0-only") + version("3.37", sha256="b59099d42d5c62a8171974e54466a688c8da6720bf74a7f16bf24fb0e51ff92d") version("3.36", sha256="b34b8f3c5cd074c09ea487ffe3f444e95565c214b34a73042f35b00cbaab0e17") version("3.34", sha256="42ea28c78d269c4cc111b7516213f4d4b32986797a710b0ff364232cc7a3a0b7") version("3.33", sha256="f48b2547313ffd1799c58c6a170175176131bbd42bc847b5650784eaf6d914b3") @@ -30,6 +31,8 @@ class Fio(AutotoolsPackage): version("3.16", sha256="c7731a9e831581bab7104da9ea60c9f44e594438dbe95dff26726ca0285e7b93") version("2.19", sha256="61fb03a18703269b781aaf195cb0d7931493bbb5bfcc8eb746d5d66d04ed77f7") + depends_on("c", type="build") # generated + variant("gui", default=False, description="Enable building of gtk gfio") variant("doc", default=False, description="Generate documentation") variant("libaio", default=False, description="Enable libaio engine") @@ -46,8 +49,9 @@ class Fio(AutotoolsPackage): def configure_args(self): config_args = [] + spec = self.spec - if "+gui" in self.spec: + if spec.satisfies("+gui"): config_args.append("--enable-gfio") return config_args diff --git a/var/spack/repos/builtin/packages/fipscheck/package.py b/var/spack/repos/builtin/packages/fipscheck/package.py index bd8039e9e6130d..03d86c820119e9 100644 --- a/var/spack/repos/builtin/packages/fipscheck/package.py +++ b/var/spack/repos/builtin/packages/fipscheck/package.py @@ -17,6 +17,8 @@ class Fipscheck(AutotoolsPackage): version("7.0.0.397", sha256="6bce42faabf372d08b6f8fadb4fa9e65671bebf6c0c91eab8c59ae96b1e7d600") version("7.0.0.396", sha256="058aafac78f3c0c5b65107686538b09eeb52cbb9b7ede688f3502df7d69c1209") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/fish/package.py b/var/spack/repos/builtin/packages/fish/package.py index cca14b84bdad15..e01b7f0307c998 100644 --- a/var/spack/repos/builtin/packages/fish/package.py +++ b/var/spack/repos/builtin/packages/fish/package.py @@ -22,6 +22,11 @@ class Fish(CMakePackage): license("GPL-2.0-only") version("master", branch="master") + version("3.7.1", sha256="614c9f5643cd0799df391395fa6bbc3649427bb839722ce3b114d3bbc1a3b250") + version("3.7.0", sha256="df1b7378b714f0690b285ed9e4e58afe270ac98dbc9ca5839589c1afcca33ab1") + version("3.6.4", sha256="0f3f610e580de092fbe882c8aa76623ecf91bb16fdf0543241e6e90d5d4bc393") + version("3.6.3", sha256="55520128c8ef515908a3821423b430db9258527a6c6acb61c7cb95626b5a48d5") + version("3.6.2", sha256="a21a6c986f1f80273895ba7e905fa80ad7e1a262ddb3d979efa443367eaf4863") version("3.6.1", sha256="55402bb47ca6739d8aba25e41780905b5ce1bce0a5e0dd17dca908b5bc0b49b2") version("3.6.0", sha256="97044d57773ee7ca15634f693d917ed1c3dc0fa7fde1017f1626d60b83ea6181") version("3.5.1", sha256="a6d45b3dc5a45dd31772e7f8dfdfecabc063986e8f67d60bd7ca60cc81db6928") @@ -31,6 +36,8 @@ class Fish(CMakePackage): version("3.1.0", sha256="e5db1e6839685c56f172e1000c138e290add4aa521f187df4cd79d4eab294368") version("3.0.0", sha256="ea9dd3614bb0346829ce7319437c6a93e3e1dfde3b7f6a469b543b0d2c68f2cf") + depends_on("cxx", type="build") # generated + variant("docs", default=False, description="Build documentation") # https://github.com/fish-shell/fish-shell#dependencies-1 diff --git a/var/spack/repos/builtin/packages/fj/detection_test.yaml b/var/spack/repos/builtin/packages/fj/detection_test.yaml new file mode 100644 index 00000000000000..9159d20d914386 --- /dev/null +++ b/var/spack/repos/builtin/packages/fj/detection_test.yaml @@ -0,0 +1,27 @@ +paths: +- layout: + - executables: + - "bin/fcc" + script: | + echo "fcc (FCC) 4.0.0a 20190314" + echo "simulating gcc version 6.1" + echo "Copyright FUJITSU LIMITED 2019" + - executables: + - "bin/FCC" + script: | + echo "FCC (FCC) 4.0.0a 20190314" + echo "simulating gcc version 6.1" + echo "Copyright FUJITSU LIMITED 2019" + - executables: + - "bin/frt" + script: | + echo "frt (FRT) 4.0.0a 20190314" + echo "Copyright FUJITSU LIMITED 2019" + platforms: [linux] + results: + - spec: fj@4.0.0a + extra_attributes: + compilers: + c: ".*/bin/fcc" + cxx: ".*/bin/FCC" + fortran: ".*/bin/frt" diff --git a/var/spack/repos/builtin/packages/fj/package.py b/var/spack/repos/builtin/packages/fj/package.py index 899f85aa78e77c..9ebcecab2ef30a 100644 --- a/var/spack/repos/builtin/packages/fj/package.py +++ b/var/spack/repos/builtin/packages/fj/package.py @@ -2,16 +2,10 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import re - -import llnl.util.tty as tty - -import spack.compiler -import spack.util.executable from spack.package import * -class Fj(Package): +class Fj(Package, CompilerPackage): """The Fujitsu compiler system is a high performance, production quality code generation tool designed for high performance parallel computing workloads. @@ -27,29 +21,9 @@ def install(self, spec, prefix): "detected on a system where they are supplied by vendor" ) - executables = ["^fcc", "^FCC", "^frt"] - - @classmethod - def determine_version(cls, exe): - version_regex = re.compile(r"\((?:FCC|FRT)\) ([a-z\d.]+)") - try: - output = spack.compiler.get_compiler_version_output(exe, "--version") - match = version_regex.search(output) - if match: - return match.group(1) - except spack.util.executable.ProcessError: - pass - except Exception as e: - tty.debug(e) - - @classmethod - def determine_variants(cls, exes, version_str): - compilers = {} - for exe in exes: - if "fcc" in exe: - compilers["c"] = exe - if "FCC" in exe: - compilers["cxx"] = exe - if "frt" in exe: - compilers["fortran"] = exe - return "", {"compilers": compilers} + compiler_languages = ["c", "cxx", "fortran"] + c_names = ["fcc"] + cxx_names = ["FCC"] + fortran_names = ["frt"] + compiler_version_regex = r"\((?:FCC|FRT)\) ([a-z\d.]+)" + compiler_version_argument = "--version" diff --git a/var/spack/repos/builtin/packages/fjcontrib/package.py b/var/spack/repos/builtin/packages/fjcontrib/package.py index a8cb05b4ab865e..a7acaa64c0fc66 100644 --- a/var/spack/repos/builtin/packages/fjcontrib/package.py +++ b/var/spack/repos/builtin/packages/fjcontrib/package.py @@ -70,6 +70,8 @@ class Fjcontrib(AutotoolsPackage): version("0.001", sha256="51f24ad55e28fb1f9d698270602e5077c920fcf58d8ccfd274efbe829d7dd821") version("0.000", sha256="9486b11201e6b6e181b8a3abecd929403ae9aa67de0eb8b7353fb82ab4b89f41") + depends_on("cxx", type="build") # generated + depends_on("fastjet") build_targets = ["all", "fragile-shared"] diff --git a/var/spack/repos/builtin/packages/flac/package.py b/var/spack/repos/builtin/packages/flac/package.py index 8ec66a154d4671..80b18f12938820 100644 --- a/var/spack/repos/builtin/packages/flac/package.py +++ b/var/spack/repos/builtin/packages/flac/package.py @@ -14,10 +14,17 @@ class Flac(AutotoolsPackage): license("BSD-3-Clause AND GPL-2.0-or-later") + version("1.4.3", sha256="6c58e69cd22348f441b861092b825e591d0b822e106de6eb0ee4d05d27205b70") version("1.4.2", sha256="e322d58a1f48d23d9dd38f432672865f6f79e73a6f9cc5a5f57fcaa83eb5a8e4") + version("1.4.1", sha256="91303c3e5dfde52c3e94e75976c0ab3ee14ced278ab8f60033a3a12db9209ae6") + version("1.4.0", sha256="af41c0733c93c237c3e52f64dd87e3b0d9af38259f1c7d11e8cbf583c48c2506") + version("1.3.4", sha256="8ff0607e75a322dd7cd6ec48f4f225471404ae2730d0ea945127b1355155e737") version("1.3.3", sha256="213e82bd716c9de6db2f98bcadbc4c24c7e2efe8c75939a1a84e28539c4e1748") version("1.3.2", sha256="91cfc3ed61dc40f47f050a109b08610667d73477af6ef36dcad31c31a4a8d53f") version("1.3.1", sha256="4773c0099dba767d963fd92143263be338c48702172e8754b9bc5103efe1c56c") version("1.3.0", sha256="fa2d64aac1f77e31dfbb270aeb08f5b32e27036a52ad15e69a77e309528010dc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libogg@1.1.2:") diff --git a/var/spack/repos/builtin/packages/flann/package.py b/var/spack/repos/builtin/packages/flann/package.py index 301d1d88f5d4a6..e6a8239dd5afa9 100644 --- a/var/spack/repos/builtin/packages/flann/package.py +++ b/var/spack/repos/builtin/packages/flann/package.py @@ -30,6 +30,9 @@ class Flann(CMakePackage): version("1.8.1", sha256="82ff80709ca25365bca3367e87ffb4e0395fab068487314d02271bc3034591c1") version("1.8.0", sha256="8a3eef79512870dec20b3a3e481e5e5e6da00d524b810a22ee186f13732f0fa1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): if version > Version("1.8.1"): return "https://github.com/mariusmuja/flann/archive/{0}.tar.gz".format(version) diff --git a/var/spack/repos/builtin/packages/flap/package.py b/var/spack/repos/builtin/packages/flap/package.py index 082ff297e6d7a2..fc2d9013930b03 100644 --- a/var/spack/repos/builtin/packages/flap/package.py +++ b/var/spack/repos/builtin/packages/flap/package.py @@ -19,6 +19,8 @@ class Flap(CMakePackage): version("master", branch="master", submodules=True) + depends_on("fortran", type="build") # generated + def flag_handler(self, name, flags): if name in ["cflags", "cxxflags", "cppflags"]: return (None, flags, None) diff --git a/var/spack/repos/builtin/packages/flash/package.py b/var/spack/repos/builtin/packages/flash/package.py index 8cd9e98f5afc8b..67ca048eb002f0 100644 --- a/var/spack/repos/builtin/packages/flash/package.py +++ b/var/spack/repos/builtin/packages/flash/package.py @@ -18,6 +18,8 @@ class Flash(MakefilePackage): version("1.2.11", sha256="685ca6f7fedda07434d8ee03c536f4763385671c4509c5bb48beb3055fd236ac") + depends_on("c", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/flashdimmsim/package.py b/var/spack/repos/builtin/packages/flashdimmsim/package.py index 9f2bc1574ae6ff..77c6ddb9793928 100644 --- a/var/spack/repos/builtin/packages/flashdimmsim/package.py +++ b/var/spack/repos/builtin/packages/flashdimmsim/package.py @@ -14,6 +14,8 @@ class Flashdimmsim(Package): version("master", branch="master") + depends_on("cxx", type="build") # generated + build_directory = "src" def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/flatbuffers/package.py b/var/spack/repos/builtin/packages/flatbuffers/package.py index 486d2c95e9ea38..7d1ca90e2f0c2f 100644 --- a/var/spack/repos/builtin/packages/flatbuffers/package.py +++ b/var/spack/repos/builtin/packages/flatbuffers/package.py @@ -14,6 +14,7 @@ class Flatbuffers(CMakePackage): license("Apache-2.0") + version("24.3.25", sha256="4157c5cacdb59737c5d627e47ac26b140e9ee28b1102f812b36068aab728c1ed") version("24.3.7", sha256="bfff9d2150fcff88f844e8c608b02b2a0e94c92aea39b04c0624783464304784") version("2.0.6", sha256="e2dc24985a85b278dd06313481a9ca051d048f9474e0f199e372fea3ea4248c9") version("2.0.0", sha256="9ddb9031798f4f8754d00fca2f1a68ecf9d0f83dfac7239af1311e4fd9a565c4") @@ -23,6 +24,8 @@ class Flatbuffers(CMakePackage): version("1.9.0", sha256="5ca5491e4260cacae30f1a5786d109230db3f3a6e5a0eb45d0d0608293d247e3") version("1.8.0", sha256="c45029c0a0f1a88d416af143e34de96b3091642722aa2d8c090916c6d1498c2e") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared instead of static libraries") variant("python", default=False, description="Build with python support") diff --git a/var/spack/repos/builtin/packages/flatcc/package.py b/var/spack/repos/builtin/packages/flatcc/package.py index ae0fdd2fca0574..f9c054a5a679e4 100644 --- a/var/spack/repos/builtin/packages/flatcc/package.py +++ b/var/spack/repos/builtin/packages/flatcc/package.py @@ -21,6 +21,7 @@ class Flatcc(CMakePackage): license("Apache-2.0") + version("0.6.1", sha256="2533c2f1061498499f15acc7e0937dcf35bc68e685d237325124ae0d6c600c2b") version("0.5.3", sha256="d7519a97569ebdc9d12b162be0f9861fdc2724244f68595264a411ac48e4e983") version("0.5.2", sha256="02dac93d3daf8d0a290aa8711a9b8a53f047436ec5331adb1972389061ec6615") version("0.5.1", sha256="8c4560ca32e3c555716d9363bed469e2c60e0f443ec32bc08e7abfe681e25ca9") @@ -30,6 +31,9 @@ class Flatcc(CMakePackage): version("0.4.1", sha256="de9f668e5555b24c0885f8dc4f4098cc8065c1f428f8209097624035aee487df") version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libs") depends_on("cmake@2.8:", type="build") @@ -42,7 +46,7 @@ def cmake_args(self): # allow flatcc to be built with more compilers args.append("-DFLATCC_ALLOW_WERROR=OFF") - if "+shared" in spec: + if spec.satisfies("+shared"): args.append("-DBUILD_SHARED_LIBS=ON") args.append("-DFLATCC_INSTALL=ON") else: diff --git a/var/spack/repos/builtin/packages/flcl/package.py b/var/spack/repos/builtin/packages/flcl/package.py index dad907c1f7b9cc..be0e0b514d2727 100644 --- a/var/spack/repos/builtin/packages/flcl/package.py +++ b/var/spack/repos/builtin/packages/flcl/package.py @@ -23,6 +23,9 @@ class Flcl(CMakePackage): version("0.4.0", sha256="0fe327906a991262866b126a7d58098eb48297148f117fd59a2dbcc14e76f394") version("0.3", sha256="fc18c8fa3ae33db61203b647ad9025d894612b0faaf7fe07426aaa8bbfa9e703") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("kokkos") depends_on("cmake@3.17:", type="build", when="@:0.4.0") depends_on("cmake@3.19:", type="build", when="@0.5.0:") diff --git a/var/spack/repos/builtin/packages/flecsale/package.py b/var/spack/repos/builtin/packages/flecsale/package.py deleted file mode 100644 index ef09c6a29f8450..00000000000000 --- a/var/spack/repos/builtin/packages/flecsale/package.py +++ /dev/null @@ -1,45 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - - -from spack.package import * -from spack.pkg.builtin.boost import Boost - - -class Flecsale(CMakePackage): - """Flecsale is an ALE code based on FleCSI""" - - homepage = "https://github.com/laristra/flecsale" - git = "https://github.com/laristra/flecsale.git" - - license("Unlicense") - - version("develop", branch="master", submodules=True) - - variant("mpi", default=True, description="Build on top of mpi conduit for mpi inoperability") - - depends_on("pkgconfig", type="build") - depends_on("cmake@3.1:", type="build") - depends_on("flecsi backend=serial", when="~mpi") - conflicts("^flecsi backend=serial", when="+mpi") - depends_on("python") - depends_on("openssl") - depends_on("boost~mpi", when="~mpi") - depends_on("boost+mpi", when="+mpi") - - # TODO: replace this with an explicit list of components of Boost, - # for instance depends_on('boost +filesystem') - # See https://github.com/spack/spack/pull/22303 for reference - depends_on(Boost.with_default_variants) - depends_on("exodusii~mpi", when="~mpi") - depends_on("exodusii+mpi", when="+mpi") - - def cmake_args(self): - options = ["-DENABLE_UNIT_TESTS=ON" "-DENABLE_OPENSSL=ON" "-DENABLE_PYTHON=ON"] - - if "+mpi" in self.spec: - options.extend(["-DENABLE_MPI=ON", "-DFLECSI_RUNTIME_MODEL=legion"]) - - return options diff --git a/var/spack/repos/builtin/packages/flecsi/package.py b/var/spack/repos/builtin/packages/flecsi/package.py index 49a80488026ec8..12d6d9df81debb 100644 --- a/var/spack/repos/builtin/packages/flecsi/package.py +++ b/var/spack/repos/builtin/packages/flecsi/package.py @@ -17,29 +17,23 @@ class Flecsi(CMakePackage, CudaPackage, ROCmPackage): homepage = "http://flecsi.org/" git = "https://github.com/flecsi/flecsi.git" - maintainers("ktsai7", "rbberger") + maintainers("rbberger", "opensdh") tags = ["e4s"] - version("develop", branch="develop") - version( - "2.2.1", tag="v2.2.1", commit="84b5b232aebab40610f57387778db80f6c8c84c5", preferred=True - ) + version("develop", branch="develop", deprecated=True) + version("2.3.0", tag="v2.3.0", commit="90bc8267fceb02060e54646f73b45d4252aef491") + version("2.2.1", tag="v2.2.1", commit="84b5b232aebab40610f57387778db80f6c8c84c5") version("2.2.0", tag="v2.2.0", commit="dd531ac16c5df124d76e385c6ebe9b9589c2d3ad") version("2.1.0", tag="v2.1.0", commit="533df139c267e2a93c268dfe68f9aec55de11cf0") version("2.0.0", tag="v2.0.0", commit="5ceebadf75d1c98999ea9e9446926722d061ec22") - version( - "1.4.1", - tag="v1.4.1", - commit="ab974c3164056e6c406917c8ca771ffd43c5a031", - submodules=True, - deprecated=True, - ) + + depends_on("cxx", type="build") # generated variant( "backend", default="mpi", - values=("serial", "mpi", "legion", "hpx", "charmpp"), + values=("mpi", "legion", "hpx"), description="Backend to use for distributed memory", multi=False, ) @@ -58,24 +52,9 @@ class Flecsi(CMakePackage, CudaPackage, ROCmPackage): variant("kokkos", default=False, description="Enable Kokkos Support") variant("openmp", default=False, description="Enable OpenMP Support") - # legacy variants - variant("coverage", default=False, description="Enable coverage build", when="@:1") - variant( - "debug_backend", default=False, description="Build Backend with Debug Mode", when="@:1" - ) - variant("disable_metis", default=False, description="Disable FindPackageMetis", when="@:1") - variant("doxygen", default=False, description="Enable doxygen", when="@:1") - variant("tutorial", default=False, description="Build FleCSI Tutorials", when="@:1") - variant("flecstan", default=False, description="Build FleCSI Static Analyzer", when="@:1") - variant("external_cinch", default=False, description="Enable External Cinch", when="@:1") - variant("unit_tests", default=False, description="Build with Unit Tests Enabled", when="@:1") - # All Current FleCSI Releases for level in ("low", "medium", "high"): - depends_on("caliper@2.0.1~adiak~libdw", when="@:1 caliper_detail=%s" % level) - depends_on("caliper", when="@2.0: caliper_detail=%s" % level) - conflicts("^caliper@2.6", when="@2.0: caliper_detail=%s" % level) - conflicts("^caliper@2.7", when="@2.0: caliper_detail=%s" % level) + depends_on("caliper@:2.5,2.8:", when=f"caliper_detail={level}") depends_on("graphviz", when="+graphviz") depends_on("hdf5+hl+mpi", when="+hdf5") @@ -83,90 +62,56 @@ class Flecsi(CMakePackage, CudaPackage, ROCmPackage): depends_on("parmetis@4.0.3:") depends_on("boost@1.70.0: cxxstd=17 +program_options +stacktrace") - # FleCSI@1.x - depends_on("cmake@3.12:", when="@:1") - # Requires cinch > 1.0 due to cinchlog installation issue - depends_on("cinch@1.01:", type="build", when="+external_cinch @:1") - depends_on("mpi", when="backend=mpi @:1") - depends_on("mpi", when="backend=legion @:1") - depends_on("mpi", when="backend=hpx @:1") - depends_on("legion+shared", when="backend=legion @:1") - depends_on("legion+hdf5", when="backend=legion +hdf5 @:1") - depends_on("legion build_type=Debug", when="backend=legion +debug_backend") - depends_on("legion@master", when="backend=legion @:1") - depends_on("hpx@1.4.1 cxxstd=17 malloc=system max_cpu_count=128", when="backend=hpx @:1") - depends_on("hpx build_type=Debug", when="backend=hpx +debug_backend") - depends_on("googletest@1.8.1+gmock", when="@:1") - depends_on("python@3.0:", when="+tutorial @:1") - depends_on("doxygen", when="+doxygen @:1") - depends_on("llvm", when="+flecstan @:1") - depends_on("pfunit@3.0:3", when="@:1") - depends_on("py-gcovr", when="+coverage @:1") - depends_on("openmpi+legacylaunchers", when="+unit_tests ^[virtuals=mpi] openmpi") - - # FleCSI@2.x - depends_on("cmake@3.15:", when="@2.0:") + depends_on("cmake@3.15:") depends_on("cmake@3.19:", when="@2.2:") - depends_on("boost +atomic +filesystem +regex +system", when="@2.0:2.2.1") + depends_on("cmake@3.23:", when="@2.3:") + depends_on("boost +atomic +filesystem +regex +system", when="@:2.2.1") depends_on("boost@1.79.0:", when="@2.2:") - depends_on("kokkos@3.2.00:", when="+kokkos @2.0:") - depends_on("kokkos +cuda +cuda_constexpr +cuda_lambda", when="+kokkos +cuda @2.0:") - depends_on("kokkos +rocm", when="+kokkos +rocm @2.0:") - depends_on("kokkos +openmp", when="+kokkos +openmp @2.0:") - depends_on("legion@master", when="backend=legion @2.0:") - depends_on("legion+shared", when="backend=legion +shared @2.0:") - depends_on("legion+hdf5", when="backend=legion +hdf5 @2.0:") - depends_on("legion+kokkos", when="backend=legion +kokkos @2.0:") - depends_on("legion+openmp", when="backend=legion +openmp @2.0:") - depends_on("legion+cuda", when="backend=legion +cuda @2.0:") - depends_on("legion+rocm", when="backend=legion +rocm @2.0:") - depends_on("hdf5@1.10.7:", when="backend=legion +hdf5 @2.0:") - depends_on("hpx@1.9.1: cxxstd=17 malloc=system", when="backend=hpx @2.0:") - depends_on("mpi", when="@2.0:") - depends_on("mpich@3.4.1:", when="@2.0: ^[virtuals=mpi] mpich") - depends_on("openmpi@4.1.0:", when="@2.0: ^[virtuals=mpi] openmpi") + depends_on("kokkos@3.2.00:", when="+kokkos") + depends_on("kokkos@3.7:", when="+kokkos @2.3:") + depends_on("kokkos +cuda +cuda_constexpr +cuda_lambda", when="+kokkos +cuda") + depends_on("kokkos +rocm", when="+kokkos +rocm") + depends_on("kokkos +openmp", when="+kokkos +openmp") + depends_on("legion@cr-20210122", when="backend=legion @2.0:2.2.1") + depends_on("legion@cr-20230307", when="backend=legion @2.2.0:2.2.1") + depends_on("legion@24.03.0:", when="backend=legion @2.2.2:") + depends_on("legion+shared", when="backend=legion +shared") + depends_on("legion+hdf5", when="backend=legion +hdf5") + depends_on("legion+kokkos", when="backend=legion +kokkos") + depends_on("legion+openmp", when="backend=legion +openmp") + depends_on("legion+cuda", when="backend=legion +cuda") + depends_on("legion+rocm", when="backend=legion +rocm") + depends_on("hdf5@1.10.7:", when="backend=legion +hdf5") + depends_on("hpx@1.10.0: cxxstd=17 malloc=system", when="backend=hpx") + depends_on("mpi") + depends_on("mpich@3.4.1:", when="^[virtuals=mpi] mpich") + depends_on("openmpi@4.1.0:", when="^[virtuals=mpi] openmpi") + depends_on("graphviz@2.49.0:", when="+graphviz @2.3:") # FleCSI 2.2+ documentation dependencies depends_on("py-sphinx", when="+doc") depends_on("py-sphinx-rtd-theme", when="+doc") - depends_on("py-recommonmark", when="+doc") + depends_on("py-recommonmark", when="@:2.2 +doc") depends_on("doxygen", when="+doc") depends_on("graphviz", when="+doc") # Propagate cuda_arch requirement to dependencies for _flag in CudaPackage.cuda_arch_values: - depends_on("kokkos cuda_arch=" + _flag, when="+cuda+kokkos cuda_arch=" + _flag + " @2.0:") - depends_on( - "legion cuda_arch=" + _flag, when="backend=legion +cuda cuda_arch=" + _flag + " @2.0:" - ) + depends_on(f"kokkos cuda_arch={_flag}", when=f"+cuda+kokkos cuda_arch={_flag}") + depends_on(f"legion cuda_arch={_flag}", when=f"backend=legion +cuda cuda_arch={_flag}") # Propagate amdgpu_target requirement to dependencies for _flag in ROCmPackage.amdgpu_targets: - depends_on("kokkos amdgpu_target=" + _flag, when="+kokkos +rocm amdgpu_target=" + _flag) + depends_on(f"kokkos amdgpu_target={_flag}", when=f"+kokkos +rocm amdgpu_target={_flag}") depends_on( - "legion amdgpu_target=" + _flag, - when="backend=legion +rocm amdgpu_target=" + _flag + " @2.0:", + f"legion amdgpu_target={_flag}", when=f"backend=legion +rocm amdgpu_target={_flag}" ) - requires("%gcc@9:", when="@2: %gcc", msg="Version 9 or newer of GNU compilers required!") - - conflicts("+tutorial", when="backend=hpx") - # FleCSI@2: no longer supports serial or charmpp backends - conflicts("backend=serial", when="@2.0:") - conflicts("backend=charmpp", when="@2.0:") - # FleCSI@:1.4 releases do not support kokkos, omp, cuda, or rocm - conflicts("+kokkos", when="@:1.4") - conflicts("+openmp", when="@:1.4") - conflicts("+cuda", when="@:1.4") - conflicts("+rocm", when="@:1.4") - # Unit tests require flog support - conflicts("+unit_tests", when="~flog") + requires("%gcc@9:", when="%gcc", msg="Version 9 or newer of GNU compilers required!") + # Disallow conduit=none when using legion as a backend conflicts("^legion conduit=none", when="backend=legion") - # Due to overhauls of Legion and Gasnet spackages - # flecsi@:1.4 can no longer be built with a usable legion - conflicts("backend=legion", when="@:1.4") - conflicts("+hdf5", when="@2: backend=hpx", msg="HPX backend doesn't support HDF5") + conflicts("+hdf5", when="backend=hpx", msg="HPX backend doesn't support HDF5") def cmake_args(self): spec = self.spec @@ -202,29 +147,14 @@ def cmake_args(self): self.define_from_variant("ENABLE_GRAPHVIZ", "graphviz"), self.define_from_variant("ENABLE_KOKKOS", "kokkos"), self.define_from_variant("ENABLE_OPENMP", "openmp"), - self.define_from_variant("ENABLE_DOXYGEN", "doxygen"), - self.define_from_variant("ENABLE_COVERAGE_BUILD", "coverage"), + self.define_from_variant("ENABLE_DOXYGEN", "doc"), self.define_from_variant("ENABLE_FLOG", "flog"), - self.define_from_variant("ENABLE_FLECSIT", "tutorial"), - self.define_from_variant("ENABLE_FLECSI_TUTORIAL", "tutorial"), - self.define_from_variant("ENABLE_FLECSTAN", "flecstan"), - self.define("ENABLE_MPI", spec.variants["backend"].value != "serial"), - self.define("ENABLE_UNIT_TESTS", self.run_tests or "+unit_tests" in spec), + self.define("ENABLE_MPI", True), + self.define("ENABLE_UNIT_TESTS", self.run_tests), self.define_from_variant("ENABLE_HDF5", "hdf5"), ] - if "+external_cinch" in spec: - options.append(self.define("CINCH_SOURCE_DIR", spec["cinch"].prefix)) - if spec.variants["backend"].value == "hpx": options.append(self.define("HPX_IGNORE_CMAKE_BUILD_TYPE_COMPATIBILITY", True)) - if spec.satisfies("@:1"): - options.append( - self.define("ENABLE_CALIPER", spec.variants["caliper_detail"].value != "none") - ) - options.append( - self.define_from_variant("CMAKE_DISABLE_FIND_PACKAGE_METIS", "disable_metis") - ) - return options diff --git a/var/spack/repos/builtin/packages/flecsph/package.py b/var/spack/repos/builtin/packages/flecsph/package.py index 0e47ba5ea3794e..ca875c8ade1196 100644 --- a/var/spack/repos/builtin/packages/flecsph/package.py +++ b/var/spack/repos/builtin/packages/flecsph/package.py @@ -20,6 +20,8 @@ class Flecsph(CMakePackage): maintainers("JulienLoiseau") version("master", branch="master", submodules=True, preferred=True) + depends_on("cxx", type="build") # generated + variant("debug_tree", default=False, description="Enable debug for Ntree") depends_on("cmake@3.15:", type="build") diff --git a/var/spack/repos/builtin/packages/fleur/package.py b/var/spack/repos/builtin/packages/fleur/package.py index ec6c271ad44166..cd665cc14b8558 100644 --- a/var/spack/repos/builtin/packages/fleur/package.py +++ b/var/spack/repos/builtin/packages/fleur/package.py @@ -22,6 +22,10 @@ class Fleur(Package): version("4.0", tag="MaX-R4", commit="ea0db7877451e6240124e960c5546318c9ab3953") version("3.1", tag="MaX-R3.1", commit="f6288a0699604ad9e11efbfcde824b96db429404") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("hdf5", default=False, description="Enable HDF5 support") variant("scalapack", default=False, description="Enable SCALAPACK") diff --git a/var/spack/repos/builtin/packages/flex/package.py b/var/spack/repos/builtin/packages/flex/package.py index c887e3580b3ccf..3b2bf4f1ebf368 100644 --- a/var/spack/repos/builtin/packages/flex/package.py +++ b/var/spack/repos/builtin/packages/flex/package.py @@ -33,6 +33,9 @@ class Flex(AutotoolsPackage): version("2.6.0", sha256="cde6e46064a941a3810f7bbc612a2c39cb3aa29ce7eb775089c2515d0adfa7e9") version("2.5.39", sha256="258d3c9c38cae05932fb470db58b6a288a361c448399e6bda2694ef72a76e7cd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("nls", default=False, description="Enable native language support") variant("lex", default=True, description="Provide symlinks for lex and libl") diff --git a/var/spack/repos/builtin/packages/flexi/package.py b/var/spack/repos/builtin/packages/flexi/package.py index 36e1a6296854b7..80359b1ced88bc 100644 --- a/var/spack/repos/builtin/packages/flexi/package.py +++ b/var/spack/repos/builtin/packages/flexi/package.py @@ -18,6 +18,10 @@ class Flexi(CMakePackage): version("master", preferred=True) version("21.03.0", tag="v21.03.0", commit="d061978e5d96cfc96c06edc1bae9d92cbe540c18") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + patch("for_aarch64.patch", when="target=aarch64:") variant("mpi", default=True, description="Enable MPI") diff --git a/var/spack/repos/builtin/packages/flexiblas/package.py b/var/spack/repos/builtin/packages/flexiblas/package.py index a332fd4218ffb3..97024d4d6c5f96 100644 --- a/var/spack/repos/builtin/packages/flexiblas/package.py +++ b/var/spack/repos/builtin/packages/flexiblas/package.py @@ -22,6 +22,10 @@ class Flexiblas(CMakePackage): version("3.0.4", sha256="50a88f2e88994dda91b2a2621850afd9654b3b84820e737e335687a46751be5c") version("3.0.3", sha256="926ab31cf56f0618aec34da85314f3b48b6deb661b4e9d6e6a99dc37872b5341") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # virtual dependency provides("blas") provides("lapack") diff --git a/var/spack/repos/builtin/packages/flibcpp/package.py b/var/spack/repos/builtin/packages/flibcpp/package.py index 72e52395444e1f..7e439a3bce2259 100644 --- a/var/spack/repos/builtin/packages/flibcpp/package.py +++ b/var/spack/repos/builtin/packages/flibcpp/package.py @@ -26,6 +26,9 @@ class Flibcpp(CMakePackage): version("0.4.0", sha256="ccb0acf58a4480977fdb3c62a0bd267297c1dfa687a142ea8822474c38aa322b") version("0.3.1", sha256="871570124122c18018478275d5040b4b787d1966e50ee95b634b0b5e0cd27e91") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("doc", default=False, description="Build and install documentation") variant("shared", default=True, description="Build shared libraries") variant("swig", default=False, description="Regenerate source files using SWIG") diff --git a/var/spack/repos/builtin/packages/flint/package.py b/var/spack/repos/builtin/packages/flint/package.py index 0c3560fb320c50..2d49648e508f77 100644 --- a/var/spack/repos/builtin/packages/flint/package.py +++ b/var/spack/repos/builtin/packages/flint/package.py @@ -6,47 +6,35 @@ from spack.package import * -class Flint(Package): +class Flint(AutotoolsPackage): """FLINT (Fast Library for Number Theory).""" - homepage = "https://www.flintlib.org" - url = "https://mirrors.mit.edu/sage/spkg/upstream/flint/flint-2.5.2.tar.gz" - git = "https://github.com/wbhart/flint2.git" + homepage = "https://flintlib.org" + url = "https://flintlib.org/flint-3.1.2.tar.gz" + git = "https://github.com/flintlib/flint.git" + list_url = "https://flintlib.org/downloads.html" + list_depth = 0 license("LGPL-2.1-or-later") - version("develop", branch="trunk") + version("main", branch="main") + version("3.1.2", sha256="fdb3a431a37464834acff3bdc145f4fe8d0f951dd5327c4c6f93f4cbac5c2700") + version("3.0.1", sha256="7b311a00503a863881eb8177dbeb84322f29399f3d7d72f3b1a4c9ba1d5794b4") version("2.5.2", sha256="cbf1fe0034533c53c5c41761017065f85207a1b770483e98b2392315f6575e87") version("2.4.5", sha256="e489354df00f0d84976ccdd0477028693977c87ccd14f3924a89f848bb0e01e3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Overlap in functionality between gmp and mpir # All other dependencies must also be built with # one or the other # variant('mpir', default=False, # description='Compile with the MPIR library') - # Build dependencies - depends_on("autoconf", type="build") - - # Other dependencies depends_on("gmp") # mpir is a drop-in replacement for this depends_on("mpfr") # Could also be built against mpir - def install(self, spec, prefix): - options = [] - options = [ - "--prefix=%s" % prefix, - "--with-gmp=%s" % spec["gmp"].prefix, - "--with-mpfr=%s" % spec["mpfr"].prefix, - ] - - # if '+mpir' in spec: - # options.extend([ - # "--with-mpir=%s" % spec['mpir'].prefix - # ]) - - configure(*options) - make() - if self.run_tests: - make("check") - make("install") + def configure_args(self): + spec = self.spec + return [f"--with-gmp={spec['gmp'].prefix}", f"--with-mpfr={spec['mpfr'].prefix}"] diff --git a/var/spack/repos/builtin/packages/flit/package.py b/var/spack/repos/builtin/packages/flit/package.py index 8aaad29b0098c6..30c86cfe034517 100644 --- a/var/spack/repos/builtin/packages/flit/package.py +++ b/var/spack/repos/builtin/packages/flit/package.py @@ -21,6 +21,8 @@ class Flit(MakefilePackage): version("develop", branch="devel") version("2.1.0", sha256="b31ffa02fda1ab0f5555acdc6edc353d93d53ae8ef85e099f83bcf1c83e70885") + depends_on("cxx", type="build") # generated + maintainers("mikebentley15") # Add dependencies diff --git a/var/spack/repos/builtin/packages/fltk/package.py b/var/spack/repos/builtin/packages/fltk/package.py index f860c05cc5ab0f..50f2b68c57a0ce 100644 --- a/var/spack/repos/builtin/packages/fltk/package.py +++ b/var/spack/repos/builtin/packages/fltk/package.py @@ -27,6 +27,9 @@ class Fltk(Package): version("1.3.7", sha256="5d2ccb7ad94e595d3d97509c7a931554e059dd970b7b29e6fd84cb70fd5491c6") version("1.3.3", sha256="f8398d98d7221d40e77bc7b19e761adaf2f1ef8bb0c30eceb7beb4f2273d0d97") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libx11") patch("font.patch", when="@1.3.3") diff --git a/var/spack/repos/builtin/packages/flux-core/package.py b/var/spack/repos/builtin/packages/flux-core/package.py index e5377ccb2a1e4f..3d0e128ee43146 100644 --- a/var/spack/repos/builtin/packages/flux-core/package.py +++ b/var/spack/repos/builtin/packages/flux-core/package.py @@ -22,6 +22,12 @@ class FluxCore(AutotoolsPackage): license("LGPL-3.0-only") version("master", branch="master") + version("0.64.0", sha256="0334d6191915f1b89b70cdbf14f24200f8899da31090df5f502020533b304bb3") + version("0.63.0", sha256="f0fd339f0e24cb26331ad55062d3c1e1c7c81df41c0d7f8727aa0700c7baa1ae") + version("0.62.0", sha256="54a227741901ca758236c024296b8cd53718eea0050fc6363d2b2979aa0bf1e9") + version("0.61.2", sha256="06f38143723e3f8331f55893ad8f74d43eb0588078f91abb603690c3e5f5112c") + version("0.61.1", sha256="59cc730b34b732a1d00355bb5589bf2d26bf522b4a31ebfabff70ddb3afb51d6") + version("0.61.0", sha256="02cedc6abb12816cbb01f2195c1acf7b6552c1d8b9029f899148df48a7cd05e2") version("0.60.0", sha256="f96025204a20f94c2821db47fe010b2c19e076ef93281ac7d308e82853e135ff") version("0.59.0", sha256="465d24294b92962d156ad49768ea804ff848d5c0b3470d80e07ebf24cd255f2d") version("0.58.0", sha256="3125ace7d4d3c99b362290344f97db74c06c37b5510cfcb746e1bf48e1dc1389") @@ -55,71 +61,8 @@ class FluxCore(AutotoolsPackage): version("0.30.0", sha256="e51fde4464140367ae4bc1b44f960675ea0a6f58eede3a561cacd8a11ca3e776") version("0.29.0", sha256="c13b40e82d66356e75208a689a495ca01f0a013e2e45ac8ea202ed8224987323") version("0.28.0", sha256="9a784def7186b0036091bd8d6d8fe5bc3425ab2927e1465e1c9ad266631c285d") - version( - "0.27.0", - sha256="abd46d38081ba6b501adb1c111374b39d6ae72ac1aec9fbbf31943a856541d3a", - deprecated=True, - ) - version( - "0.26.0", - sha256="58bfd4742c59364b13cd83214e8f70735952d01793800b149cae056fddfeeff1", - deprecated=True, - ) - version( - "0.25.0", - sha256="3c97e21eaec51e8aa0eaee6aa8eb23246650d102a6b6a5c9943cd69e3c8e1008", - deprecated=True, - ) - version( - "0.24.0", - sha256="fb7e0f9a44d84144a8eaf8f42a5d7e64a4a847861d0ddc2ad8fc4908b5a9190e", - deprecated=True, - ) - version( - "0.23.0", - sha256="918b181be4e27c32f02d5036230212cd9235dc78dc2bde249c3651d6f75866c7", - deprecated=True, - ) - version( - "0.22.0", - sha256="1dd0b737199b8a40f245e6a4e1b3b28770f0ecf2f483d284232080b8b252521f", - deprecated=True, - ) - version( - "0.21.0", - sha256="cc1b7a46d7c1c1a3e99e8861bba0dde89a97351eabd6f1b264788bd76e64c329", - deprecated=True, - ) - version( - "0.20.0", - sha256="2970b9b1c389fc4a381f9e605921ce0eb6aa9339387ea741978bcffb4bd81b6f", - deprecated=True, - ) - version( - "0.19.0", - sha256="f45328a37d989c308c46639a9ed771f47b11184422cf5604249919fbd320d6f5", - deprecated=True, - ) - version( - "0.18.0", - sha256="9784bbca94177a32dbbc99728e8925bf894f3aebaa316961d6ea85df32d59545", - deprecated=True, - ) - version( - "0.17.0", - sha256="3f8c6cb72982028f86a96c0098cacd3a6e9de359fa1cf077380c835a20e7b7f7", - deprecated=True, - ) - version( - "0.16.0", - sha256="1582f7fb4d2313127418c34de7c9ce4f5fef00622d19cedca7bed929f4709f10", - deprecated=True, - ) - version( - "0.15.0", - sha256="51bc2eae69501f802459fc82f191eb5e8ae0b4f7e9e77ac18543a850cc8445f5", - deprecated=True, - ) + + depends_on("c", type="build") # generated # Avoid the infinite symlink issue # This workaround is documented in PR #3543 @@ -137,27 +80,22 @@ class FluxCore(AutotoolsPackage): depends_on("ncurses@6.2:", when="@0.32.0:") depends_on("libzmq@4.0.4:") depends_on("czmq@3.0.1:", when="@:0.54.0") - depends_on("hwloc@1.11.1:1", when="@:0.17.0") - depends_on("hwloc@1.11.1:", when="@0.17.0:") + depends_on("hwloc@1.11.1:") depends_on("hwloc +cuda", when="+cuda") # Provide version hints for lua so that the concretizer succeeds when no # explicit flux-core version is given. See issue #10000 for details depends_on("lua", type=("build", "run", "link")) - depends_on("lua@5.1:5.2", when="@:0.17.0") - depends_on("lua@5.1:5.3", when="@0.18.0:") + depends_on("lua@5.1:5.3") depends_on("lua-luaposix") # `link` dependency on python due to Flux's `pymod` module - depends_on("python@3.6:", when="@0.17:", type=("build", "link", "run")) - depends_on("python@2.7:", type=("build", "link", "run")) + depends_on("python@3.6:", type=("build", "link", "run")) # Use of distutils in configure script dropped in v0.55 depends_on("python@:3.11", when="@:0.54", type=("build", "link", "run")) depends_on("py-cffi@1.1:", type=("build", "run")) - depends_on("py-six@1.9:", when="@:0.24", type=("build", "run")) depends_on("py-pyyaml@3.10:", type=("build", "run")) depends_on("py-jsonschema@2.3:", type=("build", "run"), when="@:0.58.0") depends_on("py-ply", type=("build", "run"), when="@0.46.1:") - depends_on("jansson") - depends_on("jansson@2.10:", when="@0.21.0:") + depends_on("jansson@2.10:") depends_on("pkgconfig") depends_on("lz4") depends_on("sqlite") @@ -282,4 +220,4 @@ def flag_handler(self, name, flags): flags = [] flags.append("-Wno-error=maybe-uninitialized") - return (flags, None, None) + return flags, None, None diff --git a/var/spack/repos/builtin/packages/flux-pmix/package.py b/var/spack/repos/builtin/packages/flux-pmix/package.py index a94bb4c4f7b625..7b6dafc750b84c 100644 --- a/var/spack/repos/builtin/packages/flux-pmix/package.py +++ b/var/spack/repos/builtin/packages/flux-pmix/package.py @@ -23,6 +23,8 @@ class FluxPmix(AutotoolsPackage): version("0.3.0", sha256="88edb2afaeb6058b56ff915105a36972acc0d83204cff7f4a4d2f65a5dee9d34") version("0.2.0", sha256="d09f1fe6ffe54f83be4677e1e727640521d8110090515d94013eba0f58216934") + depends_on("c", type="build") # generated + depends_on("flux-core@0.49:", when="@0.3:") depends_on("flux-core@0.30.0:") depends_on("pmix@v4.1.0:") diff --git a/var/spack/repos/builtin/packages/flux-sched/package.py b/var/spack/repos/builtin/packages/flux-sched/package.py index 54c54624e1a02e..3f97fb0d769d55 100644 --- a/var/spack/repos/builtin/packages/flux-sched/package.py +++ b/var/spack/repos/builtin/packages/flux-sched/package.py @@ -24,6 +24,10 @@ class FluxSched(CMakePackage, AutotoolsPackage): license("LGPL-3.0-only") version("master", branch="master") + version("0.36.0", sha256="c20814eae65b6eb9f2c919dbcc216dd4b87f038a341cf99510cca88d43631c41") + version("0.35.0", sha256="38fde51464f4e34ecbd1e4fbbf00267f96b639db5987257a7ad07f811e2f09d2") + version("0.34.0", sha256="10c03d78fa2302de7ddf9599ea59fb7a2dc7ccf6f526fd9fbfc9e3ff6ba39713") + version("0.33.1", sha256="d0a1e504226d69fa8a247e9090d94ccc5e5f5fb028aab805f9cd95379bd8b1b3") version("0.33.0", sha256="d2e97121aed29bb1c6bfac602d890edb2f0a18d5303205b266a33c66fff1d61c") version("0.32.0", sha256="f0b88881f0154057de3dd5485a3e1cfc0b9b64c98052bda7d5fed7c05b5e02f3") version("0.31.0", sha256="4440156b7f2d43e3db2cbfa0dbc43671074c397525f6b97e3748c3d96a035cdb") @@ -42,20 +46,15 @@ class FluxSched(CMakePackage, AutotoolsPackage): version("0.19.0", sha256="8dffa8eaec95a81286f621639ef851c52dc4c562d365971233bbd91100c31ed2") version("0.18.0", sha256="a4d8a6444fdb7b857b26f47fdea57992b486c9522f4ff92d5a6f547d95b586ae") version("0.17.0", sha256="5acfcb757e2294a92eaa91be58ba9b42736b88b42d2937de4a78f4642b1c4933") - version("0.16.0", sha256="08313976161c141b9b34e2d44d5a08d1b11302e22d60aeaf878eef84d4bd2884") - version("0.15.0", sha256="ff24d26997f91af415f98734b8117291f5a5001e86dac865b56b3d72980c80c8") - version("0.14.0", sha256="2808f42032b917823d69cd26103c9238694416e2f30c6d39c11c670927ed232a") - version("0.13.0", sha256="ba17fc0451239fe31a1524b6a270741873f59a5057514d2524fd3e9215c47a82") - version("0.12.0", sha256="b41ecaebba254abfb5a7995fd9100bd45a59d4ad0a79bdca8b3db02785d97b1d") - version("0.11.0", sha256="6a0e3c0678f85da8724e5399b02be9686311c835617f6036235ef54b489cc336") - version("0.10.0", sha256="5944927774709b5f52ddf64a0e825d9b0f24c9dea890b5504b87a8576d217cf6") - version("0.9.0", sha256="0e1eb408a937c2843bdaaed915d4d7e2ea763b98c31e7b849a96a74758d66a21") - version("0.8.0", sha256="45bc3cefb453d19c0cb289f03692fba600a39045846568d258e4b896ca19ca0d") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated # Avoid the infinite symlink issue # This workaround is documented in PR #3543 build_directory = "spack-build" + variant("docs", default=False, description="Build flux manpages and docs") variant("cuda", default=False, description="Build dependencies with support for CUDA") # Needs to be seen if tis is needed once we remove the default variants @@ -71,14 +70,11 @@ class FluxSched(CMakePackage, AutotoolsPackage): depends_on("yaml-cpp@0.6.3") depends_on("uuid") depends_on("pkgconfig") + conflicts("%gcc@:9.3", when="@0.34:") + depends_on("py-sphinx@1.6.3:", when="+docs", type="build") depends_on("flux-core", type=("build", "link", "run")) depends_on("flux-core+cuda", when="+cuda", type=("build", "run", "link")) - depends_on("flux-core@0.16.0:0.16", when="@0.8.0", type=("build", "run", "link")) - depends_on("flux-core@0.22.0", when="@0.14.0", type=("build", "run", "link")) - depends_on("flux-core@0.23.0:0.25", when="@0.15.0", type=("build", "run", "link")) - depends_on("flux-core@0.26.0:", when="@0.16.0", type=("build", "run", "link")) - depends_on("flux-core@0.28.0:", when="@0.17.0", type=("build", "run", "link")) depends_on("flux-core@0.29.0:", when="@0.18.0", type=("build", "run", "link")) depends_on("flux-core@0.30.0:", when="@0.19.0", type=("build", "run", "link")) depends_on("flux-core@0.31.0:", when="@0.19.0", type=("build", "run", "link")) @@ -179,13 +175,27 @@ def setup_run_environment(self, env): env.prepend_path("FLUX_MODULE_PATH", self.prefix.lib.flux.modules) env.prepend_path("FLUX_MODULE_PATH", self.prefix.lib.flux.modules.sched) + # On some systems modules are in lib64 and lib + env.prepend_path("FLUX_MODULE_PATH", self.prefix.lib64.flux.modules) + env.prepend_path("FLUX_MODULE_PATH", self.prefix.lib64.flux.modules.sched) env.prepend_path("FLUX_EXEC_PATH", self.prefix.libexec.flux.cmd) env.prepend_path("FLUX_RC_EXTRA", self.prefix.etc.flux) class CMakeBuilder(CMakeBuilder): def cmake_args(self): - return [] + args = [] + ver_in_src = os.path.exists(os.path.join(self.stage.source_path, "flux-sched.ver")) + # flux-sched before v0.33 does not correctly set the version even when the file is present. + if self.spec.satisfies("@:0.33") or not ver_in_src: + # ref_version only exists on git versions + try: + ver = self.spec.version.ref_version + except AttributeError: + ver = self.spec.version + args.append(self.define("FLUX_SCHED_VER", ver)) + args.append(self.define_from_variant("ENABLE_DOCS", "docs")) + return args class AutotoolsBuilder(AutotoolsBuilder): diff --git a/var/spack/repos/builtin/packages/flux-security/package.py b/var/spack/repos/builtin/packages/flux-security/package.py index 1d108f8449ba55..23183c6d3b5076 100644 --- a/var/spack/repos/builtin/packages/flux-security/package.py +++ b/var/spack/repos/builtin/packages/flux-security/package.py @@ -27,6 +27,8 @@ class FluxSecurity(AutotoolsPackage): version("0.9.0", sha256="2258120c6f32ca0b5b13b166bae56d9bd82a44c6eeaa6bc6187e4a4419bdbcc0") version("0.8.0", sha256="9963628063b4abdff6bece03208444c8f23fbfda33c20544c48b21e9f4819ce2") + depends_on("c", type="build") # generated + # Need autotools when building on master: depends_on("autoconf", type="build", when="@master") depends_on("automake", type="build", when="@master") @@ -35,7 +37,7 @@ class FluxSecurity(AutotoolsPackage): depends_on("pkgconfig") depends_on("libsodium@1.0.14:") depends_on("jansson") - depends_on("libuuid") + depends_on("uuid") depends_on("munge") depends_on("libpam") diff --git a/var/spack/repos/builtin/packages/fluxbox/package.py b/var/spack/repos/builtin/packages/fluxbox/package.py index 4559ad9c80f619..3a5ae980d86321 100644 --- a/var/spack/repos/builtin/packages/fluxbox/package.py +++ b/var/spack/repos/builtin/packages/fluxbox/package.py @@ -20,6 +20,8 @@ class Fluxbox(AutotoolsPackage): version("1.3.7", sha256="c99e2baa06fff1e96342b20415059d12ff1fa2917ade0173c75b2fa570295b9f") + depends_on("cxx", type="build") # generated + # Referenced:https://sourceforge.net/p/fluxbox/bugs/1171/ patch("fix_zero_comparison.patch") diff --git a/var/spack/repos/builtin/packages/fms/package.py b/var/spack/repos/builtin/packages/fms/package.py index 10cbf09a2212b6..f1004c375a56b5 100644 --- a/var/spack/repos/builtin/packages/fms/package.py +++ b/var/spack/repos/builtin/packages/fms/package.py @@ -19,7 +19,15 @@ class Fms(CMakePackage): license("LGPL-3.0-or-later") maintainers("AlexanderRichert-NOAA", "Hang-Lei-NOAA", "edwardhartnett", "rem1776", "climbfuji") + version( + "2024.01.01", sha256="41c8686bad2b1aed76275e35cbe1af855f7dfce9b6d8907744ea2e8174758f6a" + ) + version("2024.01", sha256="29ac23a5a2a4765ae66d218bb261cb04f7ad44618205ab0924c4e66c9ef8fa38") version("2023.04", sha256="feb895ea2b3269ca66df296199a36af335f0dc281e2dab2f1bfebb19fd9c22c4") + version("2023.03", sha256="008a9ff394efe6a8adbcf37dd45ca103e00ae25748fc2960b7bc54f2f3b08d85") + version( + "2023.02.01", sha256="1597f7a485d02e401ce76444b2401060d74bd032cbb060cef917f001b4ff14bc" + ) version("2023.02", sha256="dc029ffadfd82c334f104268bedd8635c77976485f202f0966ae4cf06d2374be") version( "2023.01.01", sha256="f83e2814a1e3ba439ab847ec8bb251f3889d5ca14fb20849507590adbbe8e899" @@ -46,6 +54,9 @@ class Fms(CMakePackage): "2020.04.01", sha256="2c409242de7dea0cf29f8dbf7495698b6bcac1eeb5c4599a728bdea172ffe37c" ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "precision", values=("32", "64"), @@ -85,11 +96,18 @@ class Fms(CMakePackage): description="Compiles with support for deprecated io modules fms_io and mpp_io", when="@2023.02:", ) + variant("large_file", default=False, description="Enable compiler definition -Duse_LARGEFILE.") + variant( + "internal_file_nml", + default=True, + description="Enable compiler definition -DINTERNAL_FILE_NML.", + ) depends_on("netcdf-c") depends_on("netcdf-fortran") depends_on("mpi") depends_on("libyaml", when="+yaml") + depends_on("llvm-openmp", when="+openmp %apple-clang", type=("build", "run")) def cmake_args(self): args = [ @@ -98,14 +116,12 @@ def cmake_args(self): self.define_from_variant("ENABLE_QUAD_PRECISION", "quad_precision"), self.define_from_variant("WITH_YAML", "yaml"), self.define_from_variant("CONSTANTS"), + self.define_from_variant("LARGEFILE", "large_file"), + self.define_from_variant("INTERNAL_FILE_NML"), self.define("32BIT", "precision=32" in self.spec), self.define("64BIT", "precision=64" in self.spec), self.define_from_variant("FPIC", "pic"), self.define_from_variant("USE_DEPRECATED_IO", "deprecated_io"), ] - args.append(self.define("CMAKE_C_COMPILER", self.spec["mpi"].mpicc)) - args.append(self.define("CMAKE_CXX_COMPILER", self.spec["mpi"].mpicxx)) - args.append(self.define("CMAKE_Fortran_COMPILER", self.spec["mpi"].mpifc)) - return args diff --git a/var/spack/repos/builtin/packages/fmt/fmt-no-variable-initialize_10.0.0.patch b/var/spack/repos/builtin/packages/fmt/fmt-no-variable-initialize_10.0.0.patch new file mode 100644 index 00000000000000..483f2ff676d16c --- /dev/null +++ b/var/spack/repos/builtin/packages/fmt/fmt-no-variable-initialize_10.0.0.patch @@ -0,0 +1,22 @@ +diff --git a/include/fmt/format.h b/include/fmt/format.h +index 7637c8a0..c9d7b6cc 100644 +--- a/include/fmt/format.h ++++ b/include/fmt/format.h +@@ -1332,7 +1332,7 @@ template format_decimal_result { + // Buffer is large enough to hold all digits (digits10 + 1). +- Char buffer[digits10() + 1] = {}; ++ Char buffer[digits10() + 1]; + auto end = format_decimal(buffer, value, size).end; + return {out, detail::copy_str_noinline(buffer, end, out)}; + } +@@ -1359,7 +1359,7 @@ FMT_CONSTEXPR inline auto format_uint(It out, UInt value, int num_digits, + return out; + } + // Buffer should be large enough to hold all digits (digits / BASE_BITS + 1). +- char buffer[num_bits() / BASE_BITS + 1] = {}; ++ char buffer[num_bits() / BASE_BITS + 1]; + format_uint(buffer, value, num_digits, upper); + return detail::copy_str_noinline(buffer, buffer + num_digits, out); + } diff --git a/var/spack/repos/builtin/packages/fmt/package.py b/var/spack/repos/builtin/packages/fmt/package.py index e129d0e84f4473..f9aa83dcbec154 100644 --- a/var/spack/repos/builtin/packages/fmt/package.py +++ b/var/spack/repos/builtin/packages/fmt/package.py @@ -18,6 +18,9 @@ class Fmt(CMakePackage): license("MIT") + version("11.0.2", sha256="40fc58bebcf38c759e11a7bd8fdc163507d2423ef5058bba7f26280c5b9c5465") + version("11.0.1", sha256="62ca45531814109b5d6cef0cf2fd17db92c32a30dd23012976e768c685534814") + version("11.0.0", sha256="583ce480ef07fad76ef86e1e2a639fc231c3daa86c4aa6bcba524ce908f30699") version("10.2.1", sha256="312151a2d13c8327f5c9c586ac6cf7cddc1658e8f53edae0ec56509c8fa516c9") version("10.2.0", sha256="8a942861a94f8461a280f823041cde8f620a6d8b0e0aacc98c15bb5a9dd92399") version("10.1.1", sha256="b84e58a310c9b50196cda48d5678d5fa0849bca19e5fdba6b684f0ee93ed9d1b") @@ -44,6 +47,8 @@ class Fmt(CMakePackage): version("3.0.0", sha256="1b050b66fa31b74f1d75a14f15e99e728ab79572f176a53b2f8ad7c201c30ceb") version("master", branch="master") + depends_on("cxx", type="build") + variant( "cxxstd", default="11", @@ -94,6 +99,14 @@ class Fmt(CMakePackage): when="@10.0.0:10.1.1", ) + # Fix 'variable "buffer" may not be initialized' compiler error + patch( + "fmt-no-variable-initialize_10.0.0.patch", when="@10.0.0:10.2.1%clang@12.0.1.ibm.gcc.8.3.1" + ) + patch( + "fmt-no-variable-initialize_10.0.0.patch", when="@10.0.0:10.2.1%clang@14.0.5.ibm.gcc.8.3.1" + ) + def cmake_args(self): spec = self.spec args = [] diff --git a/var/spack/repos/builtin/packages/foam-extend/package.py b/var/spack/repos/builtin/packages/foam-extend/package.py index a9a333dde88b96..550a3ce69e7947 100644 --- a/var/spack/repos/builtin/packages/foam-extend/package.py +++ b/var/spack/repos/builtin/packages/foam-extend/package.py @@ -64,6 +64,10 @@ class FoamExtend(Package): version("3.1", git="http://git.code.sf.net/p/foam-extend/foam-extend-3.1.git", deprecated=True) version("3.0", git="http://git.code.sf.net/p/foam-extend/foam-extend-3.0.git", deprecated=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # variant('int64', default=False, # description='Compile with 64-bit label') variant("float32", default=False, description="Compile with 32-bit scalar (single-precision)") diff --git a/var/spack/repos/builtin/packages/foldseek/package.py b/var/spack/repos/builtin/packages/foldseek/package.py index de5e65211e52c0..018a5cdaf23c26 100644 --- a/var/spack/repos/builtin/packages/foldseek/package.py +++ b/var/spack/repos/builtin/packages/foldseek/package.py @@ -17,6 +17,9 @@ class Foldseek(CMakePackage): version("8-ef4e960", sha256="c74d02c4924d20275cc567783b56fff10e76ed67f3d642f53c283f67c4180a1e") version("7-04e0ec8", sha256="009d722d600248a680b9e1e9dcb3bf799f8be8de41e80a598b7f39a5ced54191") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("bzip2") depends_on("openmpi") diff --git a/var/spack/repos/builtin/packages/folly/package.py b/var/spack/repos/builtin/packages/folly/package.py index f621fe475c0ce6..72fa97883fc967 100644 --- a/var/spack/repos/builtin/packages/folly/package.py +++ b/var/spack/repos/builtin/packages/folly/package.py @@ -26,6 +26,9 @@ class Folly(CMakePackage): "2021.05.24.00", sha256="9d308adefe4670637f5c7d96309b3b394ac3fa129bc954f5dfbdd8b741c02aad" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # CMakePackage Dependency depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/font-util/package.py b/var/spack/repos/builtin/packages/font-util/package.py index 8dddef8645b34f..5ef6c416ffe290 100644 --- a/var/spack/repos/builtin/packages/font-util/package.py +++ b/var/spack/repos/builtin/packages/font-util/package.py @@ -14,10 +14,13 @@ class FontUtil(AutotoolsPackage, XorgPackage): license("custom") + version("1.4.1", sha256="f029ae80cdd75d89bee7f7af61c21e07982adfb9f72344a158b99f91f77ef5ed") version("1.4.0", sha256="30b90fe52347916be9b08f95f717f17c9c1f58bef8cabb49014d0fdd2b0df643") version("1.3.2", sha256="f115a3735604de1e852a4bf669be0269d8ce8f21f8e0e74ec5934b31dadc1e76") version("1.3.1", sha256="34ebb0c9c14e0a392cdd5ea055c92489ad88d55ae148b2f1cfded0f3f63f2b5b") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") @@ -220,7 +223,6 @@ class FontUtil(AutotoolsPackage, XorgPackage): when="fonts=" + f, ) - conflicts("fonts=font-bh-ttf", when="platform=cray") conflicts("fonts=font-bh-ttf", when="arch=linux-rhel7-broadwell") if f != "font-bh-ttf": @@ -244,9 +246,9 @@ def setup_build_environment(self, env): def font_install(self): autoconf_args = ["-ifv"] p = join_path(self.spec["util-macros"].prefix, "share", "aclocal") - autoconf_args.append("--include={0}".format(p)) + autoconf_args.append(f"--include={p}") p = join_path(self.spec.prefix, "share", "aclocal") - autoconf_args.append("--include={0}".format(p)) + autoconf_args.append(f"--include={p}") fonts = self.spec.variants["fonts"].value autoreconf = which("autoreconf") @@ -255,5 +257,5 @@ def font_install(self): with working_dir(fontroot[0]): autoreconf(*autoconf_args) configure = Executable("./configure") - configure("--prefix={0}".format(self.prefix)) + configure(f"--prefix={self.prefix}") make("install") diff --git a/var/spack/repos/builtin/packages/fontconfig/package.py b/var/spack/repos/builtin/packages/fontconfig/package.py index c0cb9fecbe969d..e96e1772877dd6 100644 --- a/var/spack/repos/builtin/packages/fontconfig/package.py +++ b/var/spack/repos/builtin/packages/fontconfig/package.py @@ -23,14 +23,20 @@ class Fontconfig(AutotoolsPackage): version("2.12.1", sha256="a9f42d03949f948a3a4f762287dbc16e53a927c91a07ee64207ebd90a9e5e292") version("2.11.1", sha256="b6b066c7dce3f436fdc0dfbae9d36122b38094f4f53bd8dffd45e195b0540d8d") + depends_on("c", type="build") # generated + + # freetype2 21.0.15+ provided by freetype 2.8.1+ + depends_on("freetype@2.8.1:", when="@2.13:") depends_on("freetype") - depends_on("gperf", type="build", when="@2.12.2:") - depends_on("libxml2") - depends_on("pkgconfig", type="build") + depends_on("gperf", type="build", when="@2.11.1:") + depends_on("libxml2@2.6:") + depends_on("pkgconfig@0.9:", type="build") depends_on("font-util") depends_on("uuid", when="@2.13.1:") depends_on("python@3:", type="build", when="@2.13.93:") + variant("pic", default=False, description="Enable position-independent code (PIC)") + def patch(self): """Make test/run-test.sh compatible with dash""" filter_file("SIGINT SIGTERM SIGABRT EXIT", "2 15 6 0", "test/run-test.sh") @@ -43,8 +49,29 @@ def _rm_offending_header(self): def configure_args(self): font_path = join_path(self.spec["font-util"].prefix, "share", "fonts") + args = ["--enable-libxml2", "--disable-docs", f"--with-default-fonts={font_path}"] + ldflags = [] + libs = [] + deps = [] + if self.spec["bzip2"].satisfies("~shared"): + deps.append("bzip2") + if not self.spec["libpng"].satisfies("libs=shared"): + deps.append("libpng") + if self.spec["libxml2"].satisfies("~shared"): + deps.append("libxml-2.0") + if deps: + pc = which("pkg-config") + for lib in deps: + ldflags.append(pc(lib, "--static", "--libs-only-L", output=str).strip()) + libs.append(pc(lib, "--static", "--libs-only-l", output=str).strip()) + args.append("LDFLAGS=%s" % " ".join(ldflags)) + args.append("LIBS=%s" % " ".join(libs)) + + if self.spec.satisfies("+pic"): + args.append(f"CFLAGS={self.compiler.cc_pic_flag}") + args.append(f"FFLAGS={self.compiler.f77_pic_flag}") - return ["--enable-libxml2", "--disable-docs", f"--with-default-fonts={font_path}"] + return args @run_after("install") def system_fonts(self): diff --git a/var/spack/repos/builtin/packages/fonttosfnt/package.py b/var/spack/repos/builtin/packages/fonttosfnt/package.py index 52b0de7ba824c0..f58227e1c003e5 100644 --- a/var/spack/repos/builtin/packages/fonttosfnt/package.py +++ b/var/spack/repos/builtin/packages/fonttosfnt/package.py @@ -18,6 +18,8 @@ class Fonttosfnt(AutotoolsPackage, XorgPackage): version("1.2.2", sha256="8111317c38f63aff08c717595e65381af7ebfc54ccc23511c2042ef1cd86c648") version("1.0.4", sha256="3873636be5b3b8e4160070e8f9a7a9221b5bd5efbf740d7abaa9092e10732673") + depends_on("c", type="build") # generated + depends_on("freetype") depends_on("libfontenc") diff --git a/var/spack/repos/builtin/packages/foonathan-memory/package.py b/var/spack/repos/builtin/packages/foonathan-memory/package.py index 4c288031bd4638..6a99d02d03db13 100644 --- a/var/spack/repos/builtin/packages/foonathan-memory/package.py +++ b/var/spack/repos/builtin/packages/foonathan-memory/package.py @@ -18,5 +18,7 @@ class FoonathanMemory(CMakePackage): version("0.7-3", sha256="4203d15db22a94a3978eeb1afb59a37d35c57c0f148733f0f1a53a6281cb74dd") version("0.7", sha256="01a7cc5a5ebddbd71bec69c89562a4a2ecd7c29334c0a29d38d83e7f7f66eb53") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.14:", when="@0.7-3:", type="build") depends_on("cmake@3.1:", type="build") diff --git a/var/spack/repos/builtin/packages/form/package.py b/var/spack/repos/builtin/packages/form/package.py index 0cd7a1a85d174d..3597348f920529 100644 --- a/var/spack/repos/builtin/packages/form/package.py +++ b/var/spack/repos/builtin/packages/form/package.py @@ -24,6 +24,9 @@ class Form(AutotoolsPackage): url="https://github.com/vermaseren/form/releases/download/v4.1-20131025/form-4.1.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gmp", type="link", when="+gmp") depends_on("zlib-api", type="link", when="+zlib") depends_on("mpi", type="link", when="+parform") diff --git a/var/spack/repos/builtin/packages/formetis/package.py b/var/spack/repos/builtin/packages/formetis/package.py index 747eaa9eaf7636..ce0239f6ef6182 100644 --- a/var/spack/repos/builtin/packages/formetis/package.py +++ b/var/spack/repos/builtin/packages/formetis/package.py @@ -20,6 +20,9 @@ class Formetis(CMakePackage): version("0.0.2", sha256="0067c03ca822f4a3955751acb470f21eed489256e2ec5ff24741eb2b638592f1") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=False, description="Enable ParMETIS support") variant("shared", default=True, description="Build shared libraries") variant("swig", default=False, description="Regenerate source files using SWIG") diff --git a/var/spack/repos/builtin/packages/fortrilinos/package.py b/var/spack/repos/builtin/packages/fortrilinos/package.py index a90a954f6f20af..738937cbdf9c4c 100644 --- a/var/spack/repos/builtin/packages/fortrilinos/package.py +++ b/var/spack/repos/builtin/packages/fortrilinos/package.py @@ -49,6 +49,9 @@ class Fortrilinos(CMakePackage): ) version("master", branch="master") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("hl", default=True, description="Build high-level Trilinos wrappers") variant("shared", default=True, description="Build shared libraries") diff --git a/var/spack/repos/builtin/packages/fossil/package.py b/var/spack/repos/builtin/packages/fossil/package.py index 6c62b5b4a526fc..8d09c815ebe2c3 100644 --- a/var/spack/repos/builtin/packages/fossil/package.py +++ b/var/spack/repos/builtin/packages/fossil/package.py @@ -26,4 +26,7 @@ class Fossil(AutotoolsPackage): sha256="300c1d5cdd6224ec6e8c88ab3f38d50f80e4071b503731b75bd61274cf310733", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("openssl") diff --git a/var/spack/repos/builtin/packages/foundationdb/package.py b/var/spack/repos/builtin/packages/foundationdb/package.py index 710bdde1504958..08cbec0b49d7c8 100644 --- a/var/spack/repos/builtin/packages/foundationdb/package.py +++ b/var/spack/repos/builtin/packages/foundationdb/package.py @@ -25,6 +25,9 @@ class Foundationdb(CMakePackage): version("6.3.0", sha256="307f99014fe0bb8fbb05399c303f5a7a5007ceee207810857a7b5e6a7df7c8e8") version("6.2.24", sha256="9225316e43691ff344224824384acfdf16ff2aac5468d6d810e38846051d5db8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.13.0:", type="build") depends_on("mono") diff --git a/var/spack/repos/builtin/packages/fox/package.py b/var/spack/repos/builtin/packages/fox/package.py index 98e44974736447..bcd88f7f6c7b21 100644 --- a/var/spack/repos/builtin/packages/fox/package.py +++ b/var/spack/repos/builtin/packages/fox/package.py @@ -19,6 +19,8 @@ class Fox(AutotoolsPackage): license("LGPL-3.0-or-later") + # Stable releases (even numbers, preferred) + version("1.7.84", sha256="bdb1fe785605488b58addc95f6091a75873e8a3bea7b83caecfb7f4b0827b34e") version("1.7.67", sha256="7e511685119ef096fa90d334da46f0e50cfed8d414df32d80a7850442052f57d") version( "1.6.57", @@ -26,6 +28,8 @@ class Fox(AutotoolsPackage): sha256="65ef15de9e0f3a396dc36d9ea29c158b78fad47f7184780357b929c94d458923", ) + depends_on("cxx", type="build") # generated + patch("no_rexdebug.patch", when="@1.7.67") variant("opengl", default=False, description="opengl support") @@ -48,6 +52,6 @@ class Fox(AutotoolsPackage): def configure_args(self): # Make the png link flags explicit or it will try to pick up libpng15 # from system - args = ["LDFLAGS={0}".format(self.spec["libpng"].libs.search_flags)] + args = [f"LDFLAGS={self.spec['libpng'].libs.search_flags}"] args += self.with_or_without("opengl") return args diff --git a/var/spack/repos/builtin/packages/fp16/package.py b/var/spack/repos/builtin/packages/fp16/package.py index d971dc6a1ebf18..a0e49e0da168b9 100644 --- a/var/spack/repos/builtin/packages/fp16/package.py +++ b/var/spack/repos/builtin/packages/fp16/package.py @@ -21,6 +21,8 @@ class Fp16(CMakePackage): version("2018-10-10", commit="34d4bf01bbf7376f2baa71b8fa148b18524d45cf") # py-torch@1.0 version("2018-02-25", commit="43d6d17df48ebf622587e7ed9472ea76573799b9") # py-torch@:0.4 + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@2.8.12:", type="build") diff --git a/var/spack/repos/builtin/packages/fpart/package.py b/var/spack/repos/builtin/packages/fpart/package.py index e0da5fae0134d0..86fe178a4db8d3 100644 --- a/var/spack/repos/builtin/packages/fpart/package.py +++ b/var/spack/repos/builtin/packages/fpart/package.py @@ -23,6 +23,8 @@ class Fpart(AutotoolsPackage): version("1.6.0", sha256="ed1fac2853fc421071b72e4c5d8455a231bc30e50034db14af8b0485ece6e097") version("1.5.1", sha256="c353a28f48e4c08f597304cb4ebb88b382f66b7fabfc8d0328ccbb0ceae9220c") + depends_on("c", type="build") # generated + variant("embfts", default=False, description="Build with embedded fts functions") variant("static", default=False, description="Build static binary") variant("debug", default=False, description="Build with debugging support") diff --git a/var/spack/repos/builtin/packages/fpchecker/package.py b/var/spack/repos/builtin/packages/fpchecker/package.py index 0607838e56c6d9..d4f29c354cd044 100644 --- a/var/spack/repos/builtin/packages/fpchecker/package.py +++ b/var/spack/repos/builtin/packages/fpchecker/package.py @@ -25,6 +25,10 @@ class Fpchecker(CMakePackage): version("0.3.5", sha256="ed7277318af8e0a22b05c5655c9acc99e1d3036af41095ec2f1b1ada4d6e90f6") version("0.3.4", sha256="ecea778dcddc8347da86b02069e12d574a3ba27a4f7c6224bf492fbff6cd162a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("llvm@12.0.1") depends_on("cmake@3.4:", type="build") depends_on("python@3:", type="run") diff --git a/var/spack/repos/builtin/packages/fping/package.py b/var/spack/repos/builtin/packages/fping/package.py index 5a243a48082036..335624b2db2009 100644 --- a/var/spack/repos/builtin/packages/fping/package.py +++ b/var/spack/repos/builtin/packages/fping/package.py @@ -19,6 +19,8 @@ class Fping(AutotoolsPackage): version("4.1", sha256="1da45b1d8c2d38b52bebd4f8b1617ddfae678e9f6436dafa6f62e97b8ecfc93c") version("4.0", sha256="8c9eac7aeadb5be0daa978cdac5f68ae44b749af0f643e8252b5e3dd4ce32e6a") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/fplll/package.py b/var/spack/repos/builtin/packages/fplll/package.py index 4186175b510905..f629bb1bfdcd70 100644 --- a/var/spack/repos/builtin/packages/fplll/package.py +++ b/var/spack/repos/builtin/packages/fplll/package.py @@ -28,6 +28,8 @@ class Fplll(AutotoolsPackage): version("5.1.0", sha256="58175c54cc92752576a64361c73e4ea7797fc18fb703b3f22c7570a09075486f") version("5.0.3", sha256="d2b11b7dcb26c30ac1aab9ff75aca9b3dd6e0b0b40c382af16017a717dfe05c2") + depends_on("cxx", type="build") # generated + depends_on("gmp") depends_on("mpfr") diff --git a/var/spack/repos/builtin/packages/fpocket/package.py b/var/spack/repos/builtin/packages/fpocket/package.py index 3b50ee68832398..833bf24fffe228 100644 --- a/var/spack/repos/builtin/packages/fpocket/package.py +++ b/var/spack/repos/builtin/packages/fpocket/package.py @@ -17,7 +17,11 @@ class Fpocket(MakefilePackage): license("MIT") - version("4.1", "1a2af2d3f2df42de67301996db3b93c7eaff0375f866443c0468dcf4b1750688") + version("4.2", sha256="8aea4ccdf4243606110c8f6978b13dd90f9cae092660eca4c6970206011de4aa") + version("4.1", sha256="1a2af2d3f2df42de67301996db3b93c7eaff0375f866443c0468dcf4b1750688") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("netcdf-c") depends_on("netcdf-cxx") diff --git a/var/spack/repos/builtin/packages/fpzip/package.py b/var/spack/repos/builtin/packages/fpzip/package.py index 7a5c011b196eda..6c4da7cb87dbf2 100644 --- a/var/spack/repos/builtin/packages/fpzip/package.py +++ b/var/spack/repos/builtin/packages/fpzip/package.py @@ -19,3 +19,6 @@ class Fpzip(CMakePackage): version("master", branch="master") version("1.3.0", sha256="248df7d84259e3feaa4c4797956b2a77c3fcd734e8f8fdc51ce171dcf4f0136c") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/fqtrim/package.py b/var/spack/repos/builtin/packages/fqtrim/package.py index 88d80ee3459344..95321c2432bb1d 100644 --- a/var/spack/repos/builtin/packages/fqtrim/package.py +++ b/var/spack/repos/builtin/packages/fqtrim/package.py @@ -19,6 +19,8 @@ class Fqtrim(MakefilePackage): version("0.9.7", sha256="4951538f69dde14a23fc4841ff020434d26eb9622c4e06b43c068c702aa3d0d6") + depends_on("cxx", type="build") # generated + def build(self, spec, prefix): make("release") diff --git a/var/spack/repos/builtin/packages/fraggenescan/package.py b/var/spack/repos/builtin/packages/fraggenescan/package.py index 89aab4e7368b40..32e42333de05c0 100644 --- a/var/spack/repos/builtin/packages/fraggenescan/package.py +++ b/var/spack/repos/builtin/packages/fraggenescan/package.py @@ -17,6 +17,8 @@ class Fraggenescan(MakefilePackage): version("1.31", sha256="cd3212d0f148218eb3b17d24fcd1fc897fb9fee9b2c902682edde29f895f426c") version("1.30", sha256="f2d7f0dfa4a5f4bbea295ed865dcbfedf16c954ea1534c2a879ebdcfb8650d95") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): filter_file("gcc", spack_cc, "Makefile", string=True) diff --git a/var/spack/repos/builtin/packages/freebayes/package.py b/var/spack/repos/builtin/packages/freebayes/package.py index 003a652cd7528d..1931c5e33f38ce 100644 --- a/var/spack/repos/builtin/packages/freebayes/package.py +++ b/var/spack/repos/builtin/packages/freebayes/package.py @@ -25,6 +25,9 @@ class Freebayes(MesonPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake", type="build") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/freecad/package.py b/var/spack/repos/builtin/packages/freecad/package.py index 1a395a5dad3d3a..3d5af4172978f8 100644 --- a/var/spack/repos/builtin/packages/freecad/package.py +++ b/var/spack/repos/builtin/packages/freecad/package.py @@ -21,6 +21,10 @@ class Freecad(CMakePackage): version("0.20.2", sha256="46922f3a477e742e1a89cd5346692d63aebb2b67af887b3e463e094a4ae055da") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("opencascade") depends_on("xerces-c") depends_on("vtk") diff --git a/var/spack/repos/builtin/packages/freefem/package.py b/var/spack/repos/builtin/packages/freefem/package.py index 712a1b9b96baf5..4412a0c4f675fa 100644 --- a/var/spack/repos/builtin/packages/freefem/package.py +++ b/var/spack/repos/builtin/packages/freefem/package.py @@ -27,6 +27,10 @@ class Freefem(AutotoolsPackage): version("4.6", sha256="6c09af8e189fc02214b0e664b679b49832c134e29cf1ede3cab29cf754f6078f") version("4.5", sha256="5b2d4125c312da8fbedd49a72e742f18f35e0ae100c82fb493067dfad5d51432") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=False, description="Activate MPI support") variant("petsc", default=False, description="Compile with PETSc/SLEPc") diff --git a/var/spack/repos/builtin/packages/freeglut/package.py b/var/spack/repos/builtin/packages/freeglut/package.py index 993f4dc29e26f0..2cf9c5965d31c2 100644 --- a/var/spack/repos/builtin/packages/freeglut/package.py +++ b/var/spack/repos/builtin/packages/freeglut/package.py @@ -19,6 +19,9 @@ class Freeglut(CMakePackage, SourceforgePackage): version("3.2.1", sha256="d4000e02102acaf259998c870e25214739d1f16f67f99cb35e4f46841399da68") version("3.0.0", sha256="2a43be8515b01ea82bcfa17d29ae0d40bd128342f0930cd1f375f1ff999f76a2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libs instead of static") depends_on("gl") @@ -27,16 +30,12 @@ class Freeglut(CMakePackage, SourceforgePackage): # FreeGLUT does not support OSMesa conflicts("^osmesa") - # FreeGLUT only works with GLX on linux (cray is also linux) + # FreeGLUT only works with GLX on linux with when("platform=linux"): depends_on("glx") depends_on("libx11") depends_on("libxi") depends_on("libxxf86vm") - with when("platform=cray"): - depends_on("glx") - depends_on("libx11") - depends_on("libxi") # freeglut 3.2.1 fails to build with -fno-common (default with newer compilers) # see https://bugs.gentoo.org/705840 and https://github.com/dcnieho/FreeGLUT/pull/76 diff --git a/var/spack/repos/builtin/packages/freeipmi/package.py b/var/spack/repos/builtin/packages/freeipmi/package.py index 2e2b23a614415e..443bed5176042b 100644 --- a/var/spack/repos/builtin/packages/freeipmi/package.py +++ b/var/spack/repos/builtin/packages/freeipmi/package.py @@ -28,6 +28,8 @@ class Freeipmi(AutotoolsPackage): version("1.6.9", sha256="f25e1c35f3d0f1b5a99cc31ecc2353ca83ed46a15163842fba870127dc9c8206") version("1.6.4", sha256="65dfbb95a30438ba247f01a58498862a37d2e71c8c950bcfcee459d079241a3c") + depends_on("c", type="build") # generated + depends_on("libgcrypt") parallel = False diff --git a/var/spack/repos/builtin/packages/freetype/package.py b/var/spack/repos/builtin/packages/freetype/package.py index 0ebfaa811386bb..d1ce23d7cee5d5 100644 --- a/var/spack/repos/builtin/packages/freetype/package.py +++ b/var/spack/repos/builtin/packages/freetype/package.py @@ -16,11 +16,17 @@ class Freetype(AutotoolsPackage, CMakePackage): homepage = "https://www.freetype.org/index.html" url = "https://download.savannah.gnu.org/releases/freetype/freetype-2.10.1.tar.gz" + list_url = "https://download.savannah.gnu.org/releases/freetype/freetype-old/" maintainers("michaelkuhn") license("FTL OR GPL-2.0-or-later") + version("2.13.2", sha256="1ac27e16c134a7f2ccea177faba19801131116fd682efc1f5737037c5db224b5") + version("2.13.1", sha256="0b109c59914f25b4411a8de2a506fdd18fa8457eb86eca6c7b15c19110a92fa5") + version("2.13.0", sha256="a7aca0e532a276ea8d85bd31149f0a74c33d19c8d287116ef8f5f8357b4f1f80") + version("2.12.1", sha256="efe71fd4b8246f1b0b1b9bfca13cfff1c9ad85930340c27df469733bbb620938") + version("2.12.0", sha256="7940a46eeb0255baaa87c553d72778c4f8daa2b8888c8e2a05766a2a8686740c") version("2.11.1", sha256="f8db94d307e9c54961b39a1cc799a67d46681480696ed72ecf78d4473770f09b") version("2.11.0", sha256="a45c6b403413abd5706f3582f04c8339d26397c4304b78fa552f2215df64101f") version("2.10.4", sha256="5eab795ebb23ac77001cfb68b7d4d50b5d6c7469247b0b01b2c953269f658dac") @@ -30,13 +36,17 @@ class Freetype(AutotoolsPackage, CMakePackage): version("2.9.1", sha256="ec391504e55498adceb30baceebd147a6e963f636eb617424bcfc47a169898ce") version("2.7.1", sha256="162ef25aa64480b1189cdb261228e6c5c44f212aac4b4621e28cf2157efb59f5") version("2.7", sha256="7b657d5f872b0ab56461f3bd310bd1c5ec64619bd15f0d8e08282d494d9cfea4") + version("2.6.1", sha256="0a3c7dfbda6da1e8fce29232e8e96d987ababbbf71ebc8c75659e4132c367014") version("2.5.3", sha256="41217f800d3f40d78ef4eb99d6a35fd85235b64f81bc56e4812d7672fca7b806") + depends_on("c", type="build") # generated + + # CMake build does not install freetype-config, which is needed by most packages build_system("cmake", "autotools", default="autotools") depends_on("bzip2") depends_on("libpng") - for plat in ["linux", "darwin", "cray"]: + for plat in ["linux", "darwin"]: depends_on("pkgconfig", type="build", when="platform=%s" % plat) conflicts( @@ -53,6 +63,14 @@ class Freetype(AutotoolsPackage, CMakePackage): patch("windows.patch", when="@2.9.1") + def url_for_version(self, version): + url = "https://download.savannah.gnu.org/releases/{}/freetype-{}.tar.gz" + if version >= Version("2.7"): + directory = "freetype" + else: + directory = "freetype/freetype-old" + return url.format(directory, version) + @property def headers(self): headers = find_headers("*", self.prefix.include, recursive=True) @@ -61,6 +79,8 @@ def headers(self): class AutotoolsBuilder(AutotoolsBuilder): + build_directory = "builds/unix" + def configure_args(self): args = [ "--with-brotli=no", diff --git a/var/spack/repos/builtin/packages/freexl/package.py b/var/spack/repos/builtin/packages/freexl/package.py index c74e29146fa581..41f593df26e75c 100644 --- a/var/spack/repos/builtin/packages/freexl/package.py +++ b/var/spack/repos/builtin/packages/freexl/package.py @@ -17,4 +17,6 @@ class Freexl(AutotoolsPackage): version("1.0.6", sha256="3de8b57a3d130cb2881ea52d3aa9ce1feedb1b57b7daa4eb37f751404f90fc22") version("1.0.5", sha256="3dc9b150d218b0e280a3d6a41d93c1e45f4d7155829d75f1e5bf3e0b0de6750d") + depends_on("c", type="build") # generated + depends_on("minizip", when="@2:") diff --git a/var/spack/repos/builtin/packages/fribidi/package.py b/var/spack/repos/builtin/packages/fribidi/package.py index beea8647cbd4ba..b657b2dceb1b13 100644 --- a/var/spack/repos/builtin/packages/fribidi/package.py +++ b/var/spack/repos/builtin/packages/fribidi/package.py @@ -20,6 +20,8 @@ class Fribidi(AutotoolsPackage): version("1.0.8", sha256="94c7b68d86ad2a9613b4dcffe7bbeb03523d63b5b37918bdf2e4ef34195c1e6c") version("1.0.5", sha256="6a64f2a687f5c4f203a46fa659f43dd43d1f8b845df8d723107e8a7e6158e4ce") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/frontier-client/package.py b/var/spack/repos/builtin/packages/frontier-client/package.py index 2c9d9f03a71a1b..1ffafa9adacbdc 100644 --- a/var/spack/repos/builtin/packages/frontier-client/package.py +++ b/var/spack/repos/builtin/packages/frontier-client/package.py @@ -20,6 +20,9 @@ class FrontierClient(MakefilePackage): version("2_8_21", sha256="7df9ba61c3e1778aca75c5da6e45ee4d00b5c061d3f7162208e2fbd2ec266a9e") version("2_8_20", sha256="81b0f45762d96a33f156e0238631a60eef910a176644e95c6c19a36824bef7e1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pacparser") depends_on("expat") depends_on("openssl") diff --git a/var/spack/repos/builtin/packages/frontistr/package.py b/var/spack/repos/builtin/packages/frontistr/package.py index 0691a409352523..d383f96cc57bcf 100644 --- a/var/spack/repos/builtin/packages/frontistr/package.py +++ b/var/spack/repos/builtin/packages/frontistr/package.py @@ -58,3 +58,7 @@ class Frontistr(FrontistrBase): version("5.1", tag="v5.1", commit="f3fe347a8fd83cd45983476521d43061c8528da0") version("5.0", tag="v5.0", commit="39b83f057a2639af4b5083fb911e0726f0972b75") version("master", tag="master") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/fslsfonts/package.py b/var/spack/repos/builtin/packages/fslsfonts/package.py index d08250cc2f9eb8..8f7f331cdea95c 100644 --- a/var/spack/repos/builtin/packages/fslsfonts/package.py +++ b/var/spack/repos/builtin/packages/fslsfonts/package.py @@ -15,6 +15,8 @@ class Fslsfonts(AutotoolsPackage, XorgPackage): version("1.0.6", sha256="17179e32cfc4588da9e8aa1aa21f862af265d673de64fe5e3a8556921caccb28") version("1.0.5", sha256="27e58d2313835ce0f08cf47c59a43798b122f605a55f54b170db27b57a492007") + depends_on("c", type="build") # generated + depends_on("libfs") depends_on("xproto@7.0.25:") diff --git a/var/spack/repos/builtin/packages/fstobdf/package.py b/var/spack/repos/builtin/packages/fstobdf/package.py index 2d316b44743d55..ca3bd1f51fa32d 100644 --- a/var/spack/repos/builtin/packages/fstobdf/package.py +++ b/var/spack/repos/builtin/packages/fstobdf/package.py @@ -18,6 +18,8 @@ class Fstobdf(AutotoolsPackage, XorgPackage): version("1.0.7", sha256="5cf1f697415dc5f66df24d7495471dbd5bc3812580773e4c700ead5db27503cf") version("1.0.6", sha256="bb903ae76cbcb0a08a71f06762b64db7d5c2064f6e88e8dc3a604e76d0bcb93d") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libfs") diff --git a/var/spack/repos/builtin/packages/fstrack/package.py b/var/spack/repos/builtin/packages/fstrack/package.py index 4a0da90af87e3e..30c32470e089c3 100644 --- a/var/spack/repos/builtin/packages/fstrack/package.py +++ b/var/spack/repos/builtin/packages/fstrack/package.py @@ -21,6 +21,9 @@ class Fstrack(MakefilePackage): "0.5.3.092918", sha256="34b31687fdfa207b9659425238b805eaacf0b0209e7e3343c1a3cb4c9e62345d" ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("flow", default=True, description="Build the flow tracker") depends_on("gmt@4.0:4", when="+flow") diff --git a/var/spack/repos/builtin/packages/ftgl/package.py b/var/spack/repos/builtin/packages/ftgl/package.py index d9ac0dba6dbb65..c3a6bc60122f47 100644 --- a/var/spack/repos/builtin/packages/ftgl/package.py +++ b/var/spack/repos/builtin/packages/ftgl/package.py @@ -18,6 +18,9 @@ class Ftgl(CMakePackage): version("2.4.0", commit="483639219095ad080538e07ceb5996de901d4e74") version("2.3.1", commit="3c0fdf367824b6381f29df3d8b4590240db62ab7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # FIXME: Doc generation is broken in upstream build system # variant('doc', default=False, description='Build the documentation') variant("shared", default=True, description="Build as a shared library") diff --git a/var/spack/repos/builtin/packages/ftjam/package.py b/var/spack/repos/builtin/packages/ftjam/package.py index c54a9427e0ebbb..df26fa71b64578 100644 --- a/var/spack/repos/builtin/packages/ftjam/package.py +++ b/var/spack/repos/builtin/packages/ftjam/package.py @@ -15,4 +15,6 @@ class Ftjam(AutotoolsPackage): version("2.5.2", sha256="a5d456f65477d77936e1726f5f803a2e6def18a6c6fccf5ea8528926c136abc8") + depends_on("c", type="build") # generated + depends_on("bison") diff --git a/var/spack/repos/builtin/packages/ftk/package.py b/var/spack/repos/builtin/packages/ftk/package.py index 44276329c4f26d..c53450588ada50 100644 --- a/var/spack/repos/builtin/packages/ftk/package.py +++ b/var/spack/repos/builtin/packages/ftk/package.py @@ -29,6 +29,9 @@ class Ftk(CMakePackage): version("0.0.5", sha256="9d5c84a73b7761b9fc7dac62d4296df9f3052b722ec1b06518b2b8f51a8d3440") version("0.0.4", sha256="1674904da8d88dbd4c7d2b6a2629883f0444e70aefc99b48d285735d394897fa") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # variants variant("adios2", default=False, description="Use ADIOS2") variant("cuda", default=False, description="Use CUDA") diff --git a/var/spack/repos/builtin/packages/ftobjectlibrary/package.py b/var/spack/repos/builtin/packages/ftobjectlibrary/package.py index fe0e6c62d2cec2..ea544bd2f9e897 100644 --- a/var/spack/repos/builtin/packages/ftobjectlibrary/package.py +++ b/var/spack/repos/builtin/packages/ftobjectlibrary/package.py @@ -19,3 +19,5 @@ class Ftobjectlibrary(CMakePackage): license("MIT") version("main", branch="main") + + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/ftxui/package.py b/var/spack/repos/builtin/packages/ftxui/package.py index 92b72c0c26c84e..c572f4132ab1c4 100644 --- a/var/spack/repos/builtin/packages/ftxui/package.py +++ b/var/spack/repos/builtin/packages/ftxui/package.py @@ -15,6 +15,9 @@ class Ftxui(CMakePackage): license("MIT") + version("5.0.0", sha256="a2991cb222c944aee14397965d9f6b050245da849d8c5da7c72d112de2786b5b") version("4.1.1", sha256="9009d093e48b3189487d67fc3e375a57c7b354c0e43fc554ad31bec74a4bc2dd") version("4.0.0", sha256="7276e4117429ebf8e34ea371c3ea4e66eb99e0f234cb4c5c85fca17174a53dfa") version("2.0.0", sha256="d891695ef22176f0c09f8261a37af9ad5b262dd670a81e6b83661a23abc2c54f") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/fujitsu-fftw/package.py b/var/spack/repos/builtin/packages/fujitsu-fftw/package.py index 29ea363b1d7d56..f4f3619d2e6243 100644 --- a/var/spack/repos/builtin/packages/fujitsu-fftw/package.py +++ b/var/spack/repos/builtin/packages/fujitsu-fftw/package.py @@ -36,6 +36,9 @@ class FujitsuFftw(FftwBase): version("1.1.0", sha256="47b01a20846802041a9533a115f816b973cc9b15b3e827a2f0caffaae34a6c9d") version("1.0.0", sha256="b5931e352355d8d1ffeb215922f4b96de11b8585c423fceeaffbf3d5436f6f2f") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Builds a shared version of the library") variant("openmp", default=True, description="Enable OpenMP support") variant("debug", default=False, description="Builds a debug version of the library") diff --git a/var/spack/repos/builtin/packages/fujitsu-frontistr/package.py b/var/spack/repos/builtin/packages/fujitsu-frontistr/package.py index 06e184f296973d..618927ebc83875 100644 --- a/var/spack/repos/builtin/packages/fujitsu-frontistr/package.py +++ b/var/spack/repos/builtin/packages/fujitsu-frontistr/package.py @@ -23,6 +23,10 @@ class FujitsuFrontistr(FrontistrBase): version("5.2", sha256="ebf73a96c33ae7c9e616c99f9ce07ec90d802764dbf6abf627b0083c3bbd2b2e") version("5.0", sha256="7a3a2dd0f834048fb71cc254c9da6c2637fb23110e79b5efaf208d6f69a5b30a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("static", default=True, description="Build with static linkage") depends_on("metis ~shared", when="+static") depends_on("mumps ~shared", when="+static") diff --git a/var/spack/repos/builtin/packages/fujitsu-mpi/package.py b/var/spack/repos/builtin/packages/fujitsu-mpi/package.py index 91ba765750e7ac..c57782b00ceb9c 100644 --- a/var/spack/repos/builtin/packages/fujitsu-mpi/package.py +++ b/var/spack/repos/builtin/packages/fujitsu-mpi/package.py @@ -53,6 +53,22 @@ def setup_dependent_package(self, module, dependent_spec): self.spec.mpif77 = self.prefix.bin.mpifrt self.spec.mpifc = self.prefix.bin.mpifrt + def setup_dependent_build_environment(self, env, dependent_spec): + # Use the spack compiler wrappers under MPI + dependent_module = dependent_spec.package.module + env.set("OMPI_CC", dependent_module.spack_cc) + env.set("OMPI_CXX", dependent_module.spack_cxx) + env.set("OMPI_FC", dependent_module.spack_fc) + env.set("OMPI_F77", dependent_module.spack_f77) + if self.spec.satisfies("%gcc"): + env.set("MPI_C_COMPILER", self.prefix.bin.mpicc) + env.set("MPI_CXX_COMPILER", self.prefix.bin.mpicxx) + env.set("MPI_Fortran_COMPILER", self.prefix.bin.mpifort) + else: + env.set("MPI_C_COMPILER", self.prefix.bin.mpifcc) + env.set("MPI_CXX_COMPILER", self.prefix.bin.mpiFCC) + env.set("MPI_Fortran_COMPILER", self.prefix.bin.mpifrt) + def setup_run_environment(self, env): # Because MPI are both compilers and runtimes, we set up the compilers # as part of run environment diff --git a/var/spack/repos/builtin/packages/fullock/package.py b/var/spack/repos/builtin/packages/fullock/package.py index ad627247567121..487e29dce1c1ea 100644 --- a/var/spack/repos/builtin/packages/fullock/package.py +++ b/var/spack/repos/builtin/packages/fullock/package.py @@ -25,6 +25,8 @@ class Fullock(AutotoolsPackage): version("1.0.33", sha256="31a292e50553abf71058b47277dbca37d25a772cf99c0f99c85e56dfcd11edb2") version("1.0.32", sha256="57d4ca06e5b88a98745062f55ee5ce37c88a49d59d58d09c5178fa1eee4d8353") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/funhpc/package.py b/var/spack/repos/builtin/packages/funhpc/package.py index f9745c18c79b3c..a11977116ce58b 100644 --- a/var/spack/repos/builtin/packages/funhpc/package.py +++ b/var/spack/repos/builtin/packages/funhpc/package.py @@ -17,6 +17,8 @@ class Funhpc(CMakePackage): version("develop", branch="master") version("1.3.0", sha256="140e60f55a307f21117bd43fa16db35d60c0df5ef37e17a4da1cb3f5da5e29c1") + depends_on("cxx", type="build") # generated + variant("pic", default=True, description="Produce position-independent code") depends_on("cereal") diff --git a/var/spack/repos/builtin/packages/funwave/package.py b/var/spack/repos/builtin/packages/funwave/package.py index f4b4023dd8018c..1594093df90e90 100644 --- a/var/spack/repos/builtin/packages/funwave/package.py +++ b/var/spack/repos/builtin/packages/funwave/package.py @@ -28,6 +28,8 @@ class Funwave(MakefilePackage): version("3.1", tag="v3.1", commit="d99502f9288380e0c823f7cc619c6c7c1897f2b9") version("3.0", tag="v3.0", commit="b569dfe08ab379d7ec375c71304ff95bd6f5ddb6") + depends_on("fortran", type="build") # generated + depends_on("mpi") parallel = False diff --git a/var/spack/repos/builtin/packages/fuse-overlayfs/package.py b/var/spack/repos/builtin/packages/fuse-overlayfs/package.py index 18112758dc998c..927c216c996ec6 100644 --- a/var/spack/repos/builtin/packages/fuse-overlayfs/package.py +++ b/var/spack/repos/builtin/packages/fuse-overlayfs/package.py @@ -15,6 +15,7 @@ class FuseOverlayfs(AutotoolsPackage): license("GPL-2.0-or-later") + version("1.13", sha256="96d10344921d5796bcba7a38580ae14a53c4e60399bb90b238ac5a10b3bb65b2") version("1.10", sha256="4351eaed7cf26a5012c14c6e0fc883ef65a7b5dcc95ba129ce485904106c25a9") version("1.7.1", sha256="fe2c076aed7b8669e7970301a99c0b197759b611035d8199de4c0add7d2fb2b4") version("1.7", sha256="e4d9a794d270e237a38e7ced95af95ad15268e0584eab981ed7c7b3758b95995") @@ -27,9 +28,12 @@ class FuseOverlayfs(AutotoolsPackage): version("1.1.1", sha256="9a1c4221a82059fd9686dd8b519d432bae126c08f9d891fb722bcb51ba4933ec") version("1.1.0", sha256="060168c2d5a8c6cc768b4542eba9953b7ff4a31f94bfb2e05b3d1051390838b1") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") depends_on("m4", type="build") depends_on("pkgconfig", type="build") depends_on("fuse") + depends_on("libfuse@3.2.1:", when="^[virtuals=fuse] libfuse") diff --git a/var/spack/repos/builtin/packages/fxdiv/package.py b/var/spack/repos/builtin/packages/fxdiv/package.py index f9349661692d0a..4bd936ca302b41 100644 --- a/var/spack/repos/builtin/packages/fxdiv/package.py +++ b/var/spack/repos/builtin/packages/fxdiv/package.py @@ -19,6 +19,8 @@ class Fxdiv(CMakePackage): version("2018-11-16", commit="b742d1143724d646cd0f914646f1240eacf5bd73") # py-torch@1.0:1.5 version("2018-02-24", commit="811b482bcd9e8d98ad80c6c78d5302bb830184b0") # py-torch@0.4 + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@3.5:", type="build") depends_on("python", type="build") diff --git a/var/spack/repos/builtin/packages/fxt/package.py b/var/spack/repos/builtin/packages/fxt/package.py index d8039a53dacc81..c80edd1c4dea11 100644 --- a/var/spack/repos/builtin/packages/fxt/package.py +++ b/var/spack/repos/builtin/packages/fxt/package.py @@ -28,6 +28,8 @@ class Fxt(AutotoolsPackage): version("0.3.4", sha256="fcd35a5278ac0f10eba12fed4fa436dce79559897fde5b8176d5eee9081970f7") version("0.3.3", sha256="3f6fea5211cc242a54496e6242365c99522a5039916789cdbe25a58d05d6a626") + depends_on("c", type="build") # generated + variant( "moreparams", default=False, diff --git a/var/spack/repos/builtin/packages/fyba/package.py b/var/spack/repos/builtin/packages/fyba/package.py index 37653cf3a8a7e1..572c3525d93737 100644 --- a/var/spack/repos/builtin/packages/fyba/package.py +++ b/var/spack/repos/builtin/packages/fyba/package.py @@ -18,6 +18,8 @@ class Fyba(AutotoolsPackage): version("4.1.1", sha256="99f658d52e8fd8997118bb6207b9c121500700996d9481a736683474e2534179") + depends_on("cxx", type="build") # generated + # configure: error: cannot find install-sh or install.sh force_autoreconf = True diff --git a/var/spack/repos/builtin/packages/g2/package.py b/var/spack/repos/builtin/packages/g2/package.py index dcff7662890f9e..ce746bf705ab3f 100644 --- a/var/spack/repos/builtin/packages/g2/package.py +++ b/var/spack/repos/builtin/packages/g2/package.py @@ -20,12 +20,16 @@ class G2(CMakePackage): maintainers("AlexanderRichert-NOAA", "Hang-Lei-NOAA", "edwardhartnett") version("develop", branch="develop") + version("3.4.9", sha256="6edc33091f6bd2acb191182831499c226a1c3992c3acc104d6363528b12dfbae") version("3.4.8", sha256="071a6f799c4c4fdfd5d0478152a0cbb9d668d12d71c78d5bda71845fc5580a7f") version("3.4.7", sha256="d6530611e3a515122f11ed4aeede7641f6f8932ef9ee0d4828786572767304dc") version("3.4.6", sha256="c4b03946365ce0bacf1e10e8412a5debd72d8671d1696aa4fb3f3adb119175fe") version("3.4.5", sha256="c18e991c56964953d778632e2d74da13c4e78da35e8d04cb742a2ca4f52737b6") version("3.4.3", sha256="679ea99b225f08b168cbf10f4b29f529b5b011232f298a5442ce037ea84de17c") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("pic", default=True, description="Build with position-independent-code") variant( "precision", diff --git a/var/spack/repos/builtin/packages/g2c/package.py b/var/spack/repos/builtin/packages/g2c/package.py index 2443f816d416b9..28ce23efd1230c 100644 --- a/var/spack/repos/builtin/packages/g2c/package.py +++ b/var/spack/repos/builtin/packages/g2c/package.py @@ -18,11 +18,14 @@ class G2c(CMakePackage): maintainers("AlexanderRichert-NOAA", "Hang-Lei-NOAA", "edwardhartnett") version("develop", branch="develop") + version("1.9.0", sha256="5554276e18bdcddf387a08c2dd23f9da310c6598905df6a2a244516c22ded9aa") version("1.8.0", sha256="4ce9f5a7cb0950699fe08ebc5a463ab4d09ef550c050391a319308a2494f971f") version("1.7.0", sha256="73afba9da382fed73ed8692d77fa037bb313280879cd4012a5e5697dccf55175") version("1.6.4", sha256="5129a772572a358296b05fbe846bd390c6a501254588c6a223623649aefacb9d") version("1.6.2", sha256="b5384b48e108293d7f764cdad458ac8ce436f26be330b02c69c2a75bb7eb9a2c") + depends_on("c", type="build") # generated + variant("aec", default=True, description="Use AEC library") variant("png", default=True, description="Use PNG library") variant("jasper", default=True, description="Use Jasper library") diff --git a/var/spack/repos/builtin/packages/g2o/package.py b/var/spack/repos/builtin/packages/g2o/package.py index effc4b3c7c5d19..e3c8f04621f69c 100644 --- a/var/spack/repos/builtin/packages/g2o/package.py +++ b/var/spack/repos/builtin/packages/g2o/package.py @@ -25,6 +25,9 @@ class G2o(CMakePackage): "20200410_git", sha256="b79eb1407ae7f2a9e6a002bb4b41d65402c185855db41a9ef4a6e3b42abaec4c" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build") depends_on("eigen@2.91.0:", type="link") depends_on("ceres-solver") diff --git a/var/spack/repos/builtin/packages/g2tmpl/package.py b/var/spack/repos/builtin/packages/g2tmpl/package.py index a231fc2bf05a56..312c68b3d83208 100644 --- a/var/spack/repos/builtin/packages/g2tmpl/package.py +++ b/var/spack/repos/builtin/packages/g2tmpl/package.py @@ -18,6 +18,24 @@ class G2tmpl(CMakePackage): maintainers("edwardhartnett", "AlexanderRichert-NOAA", "Hang-Lei-NOAA") version("develop", branch="develop") + version("1.12.0", sha256="44272be7bde8da05565255a8ecdbd080c659d7f0669e356e1c8fef6bac05e723") + version("1.11.0", sha256="00fde3b37c6b4d1f0eaf60f230159298ffcb47349a076c3bd6afa20c7ed791a9") version("1.10.2", sha256="4063361369f3691f75288c801fa9d1a2414908b7d6c07bbf69d4165802e2a7fc") version("1.10.1", sha256="0be425e5128fabb89915a92261aa75c27a46a3e115e00c686fc311321e5d1e2a") version("1.10.0", sha256="dcc0e40b8952f91d518c59df7af64e099131c17d85d910075bfa474c8822649d") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("shared", default=False, description="Build shared library") + + def cmake_args(self): + args = [ + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + self.define("BUILD_TESTING", self.run_tests), + ] + return args + + def check(self): + with working_dir(self.builder.build_directory): + make("test") diff --git a/var/spack/repos/builtin/packages/g4emlow/package.py b/var/spack/repos/builtin/packages/g4emlow/package.py index d2f220dd2b6457..87c25b950b6121 100644 --- a/var/spack/repos/builtin/packages/g4emlow/package.py +++ b/var/spack/repos/builtin/packages/g4emlow/package.py @@ -18,6 +18,7 @@ class G4emlow(Package): maintainers("drbenmorgan") # Only versions relevant to Geant4 releases built by spack are added + version("8.6", sha256="fb7abed0d1db1d8b9ea364279b95e228d7bf3e3a5dc8d449b81665cada4a1a9e") version("8.5", sha256="66baca49ac5d45e2ac10c125b4fb266225e511803e66981909ce9cd3e9bcef73") version("8.4", sha256="d87de4d2a364cb0a1e1846560525ffc3f735ccdeea8bc426d61775179aebbe8e") version("8.2", sha256="3d7768264ff5a53bcb96087604bbe11c60b7fea90aaac8f7d1252183e1a8e427") @@ -30,6 +31,8 @@ class G4emlow(Package): version("6.50", sha256="c97be73fece5fb4f73c43e11c146b43f651c6991edd0edf8619c9452f8ab1236") version("6.35", sha256="1564045a0acad344c8d432cd48c2c3bb2e051a81ab3099a84e0f56ba0fe82cec") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(join_path(prefix.share, "data")) install_path = join_path(prefix.share, "data", "G4EMLOW{0}".format(self.version)) diff --git a/var/spack/repos/builtin/packages/g4ndl/package.py b/var/spack/repos/builtin/packages/g4ndl/package.py index be9f298c2f8154..a8c8f688985555 100644 --- a/var/spack/repos/builtin/packages/g4ndl/package.py +++ b/var/spack/repos/builtin/packages/g4ndl/package.py @@ -17,6 +17,7 @@ class G4ndl(Package): maintainers("drbenmorgan") + version("4.7.1", sha256="d3acae48622118d2579de24a54d533fb2416bf0da9dd288f1724df1485a46c7c") version("4.7", sha256="7e7d3d2621102dc614f753ad928730a290d19660eed96304a9d24b453d670309") version("4.6", sha256="9d287cf2ae0fb887a2adce801ee74fb9be21b0d166dab49bcbee9408a5145408") version("4.5", sha256="cba928a520a788f2bc8229c7ef57f83d0934bb0c6a18c31ef05ef4865edcdf8e") diff --git a/var/spack/repos/builtin/packages/g4nudexlib/package.py b/var/spack/repos/builtin/packages/g4nudexlib/package.py new file mode 100644 index 00000000000000..073aebcc7f8fc4 --- /dev/null +++ b/var/spack/repos/builtin/packages/g4nudexlib/package.py @@ -0,0 +1,35 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class G4nudexlib(Package): + """Geant4 data for evaluated particle cross-sections on + natural composition of elements""" + + homepage = "https://geant4.web.cern.ch" + url = "https://geant4-data.web.cern.ch/geant4-data/datasets/G4NUDEXLIB.1.0.tar.gz" + + tags = ["hep"] + + maintainers("drbenmorgan") + + # Only versions relevant to Geant4 releases built by spack are added + version("1.0", sha256="cac7d65e9c5af8edba2b2667d5822e16aaf99065c95f805e76de4cc86395f415") + + def install(self, spec, prefix): + mkdirp(join_path(prefix.share, "data")) + install_path = join_path(prefix.share, "data", "G4NUDEXLIB{0}".format(self.version)) + install_tree(self.stage.source_path, install_path) + + def setup_dependent_run_environment(self, env, dependent_spec): + install_path = join_path(self.prefix.share, "data", "G4NUDEXLIB{0}".format(self.version)) + env.set("G4NUDEXLIBDATA", install_path) + + def url_for_version(self, version): + """Handle version string.""" + return "http://geant4-data.web.cern.ch/geant4-data/datasets/G4NUDEXLIB.%s.tar.gz" % version diff --git a/var/spack/repos/builtin/packages/g4particlexs/package.py b/var/spack/repos/builtin/packages/g4particlexs/package.py index 93c53fb277a266..fb86575b466cf1 100644 --- a/var/spack/repos/builtin/packages/g4particlexs/package.py +++ b/var/spack/repos/builtin/packages/g4particlexs/package.py @@ -19,6 +19,7 @@ class G4particlexs(Package): maintainers("drbenmorgan") # Only versions relevant to Geant4 releases built by spack are added + version("4.1", sha256="07ae1e048e9ac8e7f91f6696497dd55bd50ccc822d97af1a0b9e923212a6d7d1") version("4.0", sha256="9381039703c3f2b0fd36ab4999362a2c8b4ff9080c322f90b4e319281133ca95") version("3.1.1", sha256="66c17edd6cb6967375d0497add84c2201907a25e33db782ebc26051d38f2afda") version("3.1", sha256="404da84ead165e5cccc0bb795222f6270c9bf491ef4a0fd65195128b27f0e9cd") diff --git a/var/spack/repos/builtin/packages/g4urrpt/package.py b/var/spack/repos/builtin/packages/g4urrpt/package.py new file mode 100644 index 00000000000000..e9ff5df2840c3b --- /dev/null +++ b/var/spack/repos/builtin/packages/g4urrpt/package.py @@ -0,0 +1,35 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class G4urrpt(Package): + """Geant4 data for evaluated particle cross-sections on + natural composition of elements""" + + homepage = "https://geant4.web.cern.ch" + url = "https://geant4-data.web.cern.ch/geant4-data/datasets/G4URRPT.1.0.tar.gz" + + tags = ["hep"] + + maintainers("drbenmorgan") + + # Only versions relevant to Geant4 releases built by spack are added + version("1.0", sha256="278eb6c4086e919d2c2a718eb44d4897b7e06d2a32909f6ed48eb8590b3f9977") + + def install(self, spec, prefix): + mkdirp(join_path(prefix.share, "data")) + install_path = join_path(prefix.share, "data", "G4URRPT{0}".format(self.version)) + install_tree(self.stage.source_path, install_path) + + def setup_dependent_run_environment(self, env, dependent_spec): + install_path = join_path(self.prefix.share, "data", "G4URRPT{0}".format(self.version)) + env.set("G4URRPTDATA", install_path) + + def url_for_version(self, version): + """Handle version string.""" + return "http://geant4-data.web.cern.ch/geant4-data/datasets/G4URRPT.%s.tar.gz" % version diff --git a/var/spack/repos/builtin/packages/gadap/package.py b/var/spack/repos/builtin/packages/gadap/package.py index 6c50abe4a59c41..1c43350ea97d1d 100644 --- a/var/spack/repos/builtin/packages/gadap/package.py +++ b/var/spack/repos/builtin/packages/gadap/package.py @@ -18,6 +18,8 @@ class Gadap(AutotoolsPackage): version("2.0", sha256="ae9a989ca00ec29fb40616383d170883f07c022456db338399982a8a94ec0100") + depends_on("cxx", type="build") # generated + depends_on("curl@7.18.0:") depends_on("libdap4") depends_on("libxml2") diff --git a/var/spack/repos/builtin/packages/gamess-ri-mp2-miniapp/package.py b/var/spack/repos/builtin/packages/gamess-ri-mp2-miniapp/package.py index 230da6450511c7..7f7b06ff2c5b88 100644 --- a/var/spack/repos/builtin/packages/gamess-ri-mp2-miniapp/package.py +++ b/var/spack/repos/builtin/packages/gamess-ri-mp2-miniapp/package.py @@ -18,6 +18,8 @@ class GamessRiMp2Miniapp(MakefilePackage): version("1.5", sha256="0ff4e8e556caa99ce1ab85c53e78932a32d2e2fa3c5d883fa321d5000f8a731e") + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/gapbs/package.py b/var/spack/repos/builtin/packages/gapbs/package.py index 34a96c284a650b..19dfa2bfa4cfcd 100644 --- a/var/spack/repos/builtin/packages/gapbs/package.py +++ b/var/spack/repos/builtin/packages/gapbs/package.py @@ -25,6 +25,8 @@ class Gapbs(MakefilePackage): version("1.4", sha256="d91ecfe364e8c307e9e5535d730ef8ef8554b71d33891b70d0c4665cc11178bb") version("1.0", sha256="a7516998c4994592053c7aa0c76282760a8e009865a6b7a1c7c40968be1ca55d") + depends_on("cxx", type="build") # generated + variant("serial", default=False, description="Version with no parallelism") def build(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/garfieldpp/package.py b/var/spack/repos/builtin/packages/garfieldpp/package.py index f1e72b89d168c8..9ea5be344cc927 100644 --- a/var/spack/repos/builtin/packages/garfieldpp/package.py +++ b/var/spack/repos/builtin/packages/garfieldpp/package.py @@ -30,6 +30,10 @@ class Garfieldpp(CMakePackage): version("4.0", sha256="82bc1f0395213bd30a7cd854426e6757d0b4155e99ffd4405355c9648fa5ada3") version("3.0", sha256="c1282427a784658bc38b71c8e8cfc8c9f5202b185f0854d85f7c9c5a747c5406") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("root") depends_on("gsl") depends_on("geant4", when="+examples") diff --git a/var/spack/repos/builtin/packages/gasnet/package.py b/var/spack/repos/builtin/packages/gasnet/package.py index 74e6061918e218..6267730ef128b1 100644 --- a/var/spack/repos/builtin/packages/gasnet/package.py +++ b/var/spack/repos/builtin/packages/gasnet/package.py @@ -37,11 +37,16 @@ class Gasnet(Package, CudaPackage, ROCmPackage): version("main", branch="stable") version("master", branch="master") + version("2024.5.0", sha256="f945e80f71d340664766b66290496d230e021df5e5cd88f404d101258446daa9") version("2023.9.0", sha256="2d9f15a794e10683579ce494cd458b0dd97e2d3327c4d17e1fea79bd95576ce6") version("2023.3.0", sha256="e1fa783d38a503cf2efa7662be591ca5c2bb98d19ac72a9bc6da457329a9a14f") version("2022.9.2", sha256="2352d52f395a9aa14cc57d82957d9f1ebd928d0a0021fd26c5f1382a06cd6f1d") version("2022.9.0", sha256="6873ff4ad8ebee49da4378f2d78095a6ccc31333d6ae4cd739b9f772af11f936") - version("2022.3.0", sha256="91b59aa84c0680c807e00d3d1d8fa7c33c1aed50b86d1616f93e499620a9ba09") + version( + "2022.3.0", + deprecated=True, + sha256="91b59aa84c0680c807e00d3d1d8fa7c33c1aed50b86d1616f93e499620a9ba09", + ) version( "2021.9.0", deprecated=True, @@ -67,6 +72,9 @@ class Gasnet(Package, CudaPackage, ROCmPackage): deprecated=True, sha256="117f5fdb16e53d0fa8a47a1e28cccab1d8020ed4f6e50163d985dc90226aaa2c", ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated # Do NOT add older versions here. # GASNet-EX releases over 2 years old are not supported. @@ -75,12 +83,12 @@ class Gasnet(Package, CudaPackage, ROCmPackage): "conduits", values=any_combination_of("smp", "mpi", "ibv", "udp", "ofi", "ucx").with_default("smp"), description="The hardware-dependent network backends to enable.\n" - + "(smp) = SMP conduit for single-node operation ;\n" - + "(ibv) = Native InfiniBand verbs conduit ;\n" - + "(ofi) = OFI conduit over libfabric, for HPE Cray Slingshot and Intel Omni-Path ;\n" - + "(udp) = Portable UDP conduit, for Ethernet networks ;\n" - + "(mpi) = Low-performance/portable MPI conduit ;\n" - + "(ucx) = EXPERIMENTAL UCX conduit for Mellanox IB/RoCE ConnectX-5+ ;\n" + + "(smp) = SMP conduit for single-node operation\n" + + "(ibv) = Native InfiniBand verbs conduit\n" + + "(ofi) = OFI conduit over libfabric, for HPE Cray Slingshot and Intel Omni-Path\n" + + "(udp) = Portable UDP conduit, for Ethernet networks\n" + + "(mpi) = Low-performance/portable MPI conduit\n" + + "(ucx) = EXPERIMENTAL UCX conduit for Mellanox IB/RoCE ConnectX-5+\n" + "For detailed recommendations, consult https://gasnet.lbl.gov", ) @@ -118,12 +126,15 @@ class Gasnet(Package, CudaPackage, ROCmPackage): ) depends_on("mpi", when="conduits=mpi") + depends_on("libfabric", when="conduits=ofi") depends_on("autoconf@2.69", type="build", when="@master:") depends_on("automake@1.16:", type="build", when="@master:") conflicts("^hip@:4.4.0", when="+rocm") + conflicts("^hip@6:", when="@:2024.4+rocm") # Bug 4686 + depends_on("oneapi-level-zero@1.8.0:", when="+level_zero") def install(self, spec, prefix): @@ -157,9 +168,11 @@ def install(self, spec, prefix): if "+cuda" in spec: options.append("--enable-kind-cuda-uva") + options.append("--with-cuda-home=" + spec["cuda"].prefix) if "+rocm" in spec: options.append("--enable-kind-hip") + options.append("--with-hip-home=" + spec["hip"].prefix) if "+level_zero" in spec: options.append("--enable-kind-ze") diff --git a/var/spack/repos/builtin/packages/gatb-core/package.py b/var/spack/repos/builtin/packages/gatb-core/package.py index f37117d84476b5..9931d15bb2c85f 100644 --- a/var/spack/repos/builtin/packages/gatb-core/package.py +++ b/var/spack/repos/builtin/packages/gatb-core/package.py @@ -17,4 +17,7 @@ class GatbCore(CMakePackage): version("1.4.2", tag="v1.4.2", commit="99f573a465beb30acc22ab20be458d2ea0277684") version("1.4.1", tag="v1.4.1", commit="b45a6c213597b23f8f5221902e2b86b4009c11d9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + root_cmakelists_dir = "gatb-core" diff --git a/var/spack/repos/builtin/packages/gate/package.py b/var/spack/repos/builtin/packages/gate/package.py index 9a77788ef7a45e..89fdeb74e793b8 100644 --- a/var/spack/repos/builtin/packages/gate/package.py +++ b/var/spack/repos/builtin/packages/gate/package.py @@ -31,6 +31,9 @@ class Gate(CMakePackage): version("9.1", sha256="aaab874198500b81d45b27cc6d6a51e72cca9519910b893a5c85c8e6d3ffa4fc") version("9.0", sha256="8354f392facc0b7ae2ddf0eed61cc43136195b198ba399df25e874886b8b69cb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("rtk", default=False, description="build support for the Reconstruction Toolkit") variant( "default_platform", diff --git a/var/spack/repos/builtin/packages/gatepet2stir/package.py b/var/spack/repos/builtin/packages/gatepet2stir/package.py index 08caa8ed0f52e3..5c84bfb53f4914 100644 --- a/var/spack/repos/builtin/packages/gatepet2stir/package.py +++ b/var/spack/repos/builtin/packages/gatepet2stir/package.py @@ -14,6 +14,8 @@ class Gatepet2stir(QMakePackage): version("1.3.2", sha256="c53b990e47b5856d47466cff62763d0a3bfdc12538b6842cce45271badb7a387") + depends_on("cxx", type="build") # generated + depends_on("gperftools") depends_on("ncurses") depends_on("qt@:4") diff --git a/var/spack/repos/builtin/packages/gaudi/package.py b/var/spack/repos/builtin/packages/gaudi/package.py index fded9262f2377d..13a6d67a01b9b4 100644 --- a/var/spack/repos/builtin/packages/gaudi/package.py +++ b/var/spack/repos/builtin/packages/gaudi/package.py @@ -17,6 +17,8 @@ class Gaudi(CMakePackage): tags = ["hep"] version("master", branch="master") + version("38.1", sha256="79d42833edcebc2099f91badb6f72708640c05f678cc4521a86e857f112486dc") + version("38.0", sha256="52f2733fa0af760c079b3438bb9c7e36b28ea704f78b0085458e1918c11e1653") version("37.2", sha256="9b866caab46e182de98b59eddbde80d6fa0e670fe4a35906f1518b04bd99b2d2") version("37.1", sha256="1d7038fd5dfb5f2517ce57623cf8090549ffe2ea8f0171d534e5c1ca20bd009a") version("37.0", sha256="823f3821a4f498ddd2dd123fbb8a3787b361ddfd818f4ab13572076fc9afdfe4") @@ -37,12 +39,15 @@ class Gaudi(CMakePackage): version("36.0", sha256="8a0458cef5b616532f9db7cca9fa0e892e602b64c9e93dc0cc6d972e03034830") version("35.0", sha256="c01b822f9592a7bf875b9997cbeb3c94dea97cb13d523c12649dbbf5d69b5fa6") + depends_on("cxx", type="build") # generated + maintainers("drbenmorgan", "vvolkl", "jmcarcell") variant("aida", default=False, description="Build AIDA interfaces support") variant("cppunit", default=False, description="Build with CppUnit unit testing") variant("docs", default=False, description="Build documentation with Doxygen") variant("examples", default=False, description="Build examples") + variant("gaudialg", default=False, description="Build GaudiAlg support", when="@37.0:") variant("gperftools", default=False, description="Build with Google PerfTools support") variant("heppdt", default=False, description="Build with HEP Particle Data Table support") variant("jemalloc", default=False, description="Build with jemalloc allocator support") @@ -62,6 +67,12 @@ class Gaudi(CMakePackage): sha256="b05f6b7c1efb8c3af291c8d81fd1627e58af7c5f9a78a0098c6e3bfd7ec80c15", when="@37.1 ^catch2@3.1:", ) + # add missing include for newer compilers + patch( + "https://gitlab.cern.ch/gaudi/Gaudi/-/commit/54b727f08a685606420703098131b387d3026637.diff", + sha256="41aa1587a3e59d49e0fa9659577073c091871c2eca1b8b237c177ab98fbacf3f", + when="@:38.1", + ) # These dependencies are needed for a minimal Gaudi build depends_on("aida") @@ -80,7 +91,7 @@ class Gaudi(CMakePackage): depends_on("tbb", when="@37.1:") depends_on("uuid") depends_on("nlohmann-json") - depends_on("python", type=("build", "run")) + depends_on("python +dbm", type=("build", "run")) depends_on("py-networkx", type=("build", "run")) depends_on("py-six", type=("build", "run")) depends_on("py-pyyaml", type=("build", "run", "test")) @@ -116,6 +127,7 @@ def cmake_args(self): self.define("BUILD_TESTING", self.run_tests or self.spec.satisfies("+examples")), self.define_from_variant("GAUDI_USE_AIDA", "aida"), self.define_from_variant("GAUDI_USE_CPPUNIT", "cppunit"), + self.define_from_variant("GAUDI_ENABLE_GAUDIALG", "gaudialg"), self.define_from_variant("GAUDI_USE_GPERFTOOLS", "gperftools"), self.define_from_variant("GAUDI_USE_HEPPDT", "heppdt"), self.define_from_variant("GAUDI_USE_JEMALLOC", "jemalloc"), diff --git a/var/spack/repos/builtin/packages/gaussian-src/package.py b/var/spack/repos/builtin/packages/gaussian-src/package.py index 51d771efada76f..8f34198a81ebb9 100644 --- a/var/spack/repos/builtin/packages/gaussian-src/package.py +++ b/var/spack/repos/builtin/packages/gaussian-src/package.py @@ -129,7 +129,7 @@ def caveats(self): If you have to give others access, please customize the group membership of the package files as documented here: - https://spack.readthedocs.io/en/latest/build_settings.html#package-permissions""".format( + https://spack.readthedocs.io/en/latest/packages_yaml.html#package-permissions""".format( perm_script_path ) ) diff --git a/var/spack/repos/builtin/packages/gaussian-view/package.py b/var/spack/repos/builtin/packages/gaussian-view/package.py index b092719a45b00e..985de8e0498c9b 100644 --- a/var/spack/repos/builtin/packages/gaussian-view/package.py +++ b/var/spack/repos/builtin/packages/gaussian-view/package.py @@ -102,7 +102,7 @@ def caveats(self): If you have to give others access, please customize the group membership of the package files as documented here: - https://spack.readthedocs.io/en/latest/build_settings.html#package-permissions""".format( + https://spack.readthedocs.io/en/latest/packages_yaml.html#package-permissions""".format( perm_script_path ) ) diff --git a/var/spack/repos/builtin/packages/gawk/package.py b/var/spack/repos/builtin/packages/gawk/package.py index 51d52619d471ea..f0e745448776c6 100644 --- a/var/spack/repos/builtin/packages/gawk/package.py +++ b/var/spack/repos/builtin/packages/gawk/package.py @@ -38,6 +38,8 @@ class Gawk(AutotoolsPackage, GNUMirrorPackage): version("5.0.1", sha256="8e4e86f04ed789648b66f757329743a0d6dfb5294c3b91b756a474f1ce05a794") version("4.1.4", sha256="53e184e2d0f90def9207860531802456322be091c7b48f23fdc79cda65adc266") + depends_on("c", type="build") # generated + variant("nls", default=False, description="Enable Native Language Support") depends_on("gettext", when="+nls") diff --git a/var/spack/repos/builtin/packages/gbl/package.py b/var/spack/repos/builtin/packages/gbl/package.py index 89388076ba695f..a77623f279e4a7 100644 --- a/var/spack/repos/builtin/packages/gbl/package.py +++ b/var/spack/repos/builtin/packages/gbl/package.py @@ -17,6 +17,9 @@ class Gbl(CMakePackage): version("V02-04-01", commit="1061b643c6656fbf7ceba579997eb43f0a9e9d3c") version("V02-01-03", commit="8acaade19c20e9ef23d1244a555fead6ef149c33") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("root", default=True, description="Support ROOT for user I/O") depends_on("eigen", type=("build", "link")) depends_on("root", type=("build", "link"), when="+root") diff --git a/var/spack/repos/builtin/packages/gcc-runtime/package.py b/var/spack/repos/builtin/packages/gcc-runtime/package.py index 085042b8ceb02c..7046b8ff099f1d 100644 --- a/var/spack/repos/builtin/packages/gcc-runtime/package.py +++ b/var/spack/repos/builtin/packages/gcc-runtime/package.py @@ -22,6 +22,9 @@ class GccRuntime(Package): tags = ["runtime"] + # gcc-runtime versions are declared dynamically + skip_version_audit = ["platform=linux", "platform=darwin", "platform=windows"] + maintainers("haampie") license("GPL-3.0-or-later WITH GCC-exception-3.1") @@ -44,9 +47,17 @@ class GccRuntime(Package): "ubsan", ] + # libgfortran ABI + provides("fortran-rt", "libgfortran") + provides("libgfortran@3", when="%gcc@:6") + provides("libgfortran@4", when="%gcc@7") + provides("libgfortran@5", when="%gcc@8:") + + depends_on("libc", type="link", when="platform=linux") + def install(self, spec, prefix): - if spec.platform in ["linux", "cray", "freebsd"]: - libraries = self._get_libraries_elf() + if spec.platform in ["linux", "freebsd"]: + libraries = get_elf_libraries(compiler=self.compiler, libraries=self.LIBRARIES) elif spec.platform == "darwin": libraries = self._get_libraries_macho() else: @@ -61,47 +72,6 @@ def install(self, spec, prefix): for path, name in libraries: install(path, os.path.join(prefix.lib, name)) - def _get_libraries_elf(self): - """Get the GCC runtime libraries for ELF binaries""" - cc = Executable(self.compiler.cc) - lib_regex = re.compile(rb"\blib[a-z-_]+\.so\.\d+\b") - path_and_install_name = [] - - for name in self.LIBRARIES: - # Look for the dynamic library that gcc would use to link, - # that is with .so extension and without abi suffix. - path = cc(f"-print-file-name=lib{name}.so", output=str).strip() - - # gcc reports an absolute path on success - if not os.path.isabs(path): - continue - - # Now there are two options: - # 1. the file is an ELF file - # 2. the file is a linker script referencing the actual library - with open(path, "rb") as f: - try: - # Try to parse as an ELF file - soname = parse_elf(f, dynamic_section=True).dt_soname_str.decode("utf-8") - except Exception: - # On failure try to "parse" as ld script; the actual - # library needs to be mentioned by filename. - f.seek(0) - script_matches = lib_regex.findall(f.read()) - if len(script_matches) != 1: - continue - soname = script_matches[0].decode("utf-8") - - # Now locate and install the runtime library - runtime_path = cc(f"-print-file-name={soname}", output=str).strip() - - if not os.path.isabs(runtime_path): - continue - - path_and_install_name.append((runtime_path, soname)) - - return path_and_install_name - def _get_libraries_macho(self): """Same as _get_libraries_elf but for Mach-O binaries""" cc = Executable(self.compiler.cc) @@ -152,3 +122,45 @@ def libs(self): @property def headers(self): return HeaderList([]) + + +def get_elf_libraries(compiler, libraries): + """Get the GCC runtime libraries for ELF binaries""" + cc = Executable(compiler.cc) + lib_regex = re.compile(rb"\blib[a-z-_]+\.so\.\d+\b") + path_and_install_name = [] + + for name in libraries: + # Look for the dynamic library that gcc would use to link, + # that is with .so extension and without abi suffix. + path = cc(f"-print-file-name=lib{name}.so", output=str).strip() + + # gcc reports an absolute path on success + if not os.path.isabs(path): + continue + + # Now there are two options: + # 1. the file is an ELF file + # 2. the file is a linker script referencing the actual library + with open(path, "rb") as f: + try: + # Try to parse as an ELF file + soname = parse_elf(f, dynamic_section=True).dt_soname_str.decode("utf-8") + except Exception: + # On failure try to "parse" as ld script; the actual + # library needs to be mentioned by filename. + f.seek(0) + script_matches = lib_regex.findall(f.read()) + if len(script_matches) != 1: + continue + soname = script_matches[0].decode("utf-8") + + # Now locate and install the runtime library + runtime_path = cc(f"-print-file-name={soname}", output=str).strip() + + if not os.path.isabs(runtime_path): + continue + + path_and_install_name.append((runtime_path, soname)) + + return path_and_install_name diff --git a/var/spack/repos/builtin/packages/gcc/detection_test.yaml b/var/spack/repos/builtin/packages/gcc/detection_test.yaml index 0930f82d936568..7269c0301c1740 100644 --- a/var/spack/repos/builtin/packages/gcc/detection_test.yaml +++ b/var/spack/repos/builtin/packages/gcc/detection_test.yaml @@ -1,38 +1,96 @@ paths: - # Ubuntu 18.04, system compilers without Fortran - - layout: - - executables: - - "bin/gcc" - - "bin/g++" - script: "echo 7.5.0" - results: - - spec: "gcc@7.5.0 languages=c,c++" - # Mock a version < 7 of GCC that requires -dumpversion and - # errors with -dumpfullversion - - layout: - - executables: - - "bin/gcc-5" - - "bin/g++-5" - - "bin/gfortran-5" - script: | - if [[ "$1" == "-dumpversion" ]] ; then - echo "5.5.0" - else - echo "gcc-5: fatal error: no input files" - echo "compilation terminated." - exit 1 - fi - results: - - spec: "gcc@5.5.0 languages=c,c++,fortran" - # Multiple compilers present at the same time - - layout: - - executables: - - "bin/x86_64-linux-gnu-gcc-6" - script: 'echo 6.5.0' - - executables: - - "bin/x86_64-linux-gnu-gcc-10" - - "bin/x86_64-linux-gnu-g++-10" - script: "echo 10.1.0" - results: - - spec: "gcc@6.5.0 languages=c" - - spec: "gcc@10.1.0 languages=c,c++" +# Ubuntu 20.04, system compilers without Fortran. This +# test also covers which flags are expected to be used +# during the detection of gcc. +- layout: + - executables: + - "bin/gcc" + - "bin/g++" + script: | + if [ "$1" = "-dumpversion" ] ; then + echo "9" + elif [ "$1" = "-dumpfullversion" ] ; then + echo "9.4.0" + elif [ "$1" = "--version" ] ; then + echo "gcc (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" + echo "Copyright (C) 2019 Free Software Foundation, Inc." + echo "This is free software; see the source for copying conditions. There is NO" + echo "warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." + else + echo "mock executable got an unexpected flag: $1" + exit 1 + fi + platforms: ["darwin", "linux"] + results: + - spec: "gcc@9.4.0 languages=c,c++" + extra_attributes: + compilers: + c: ".*/bin/gcc" + cxx: ".*/bin/g++" + +# Mock a version < 7 of GCC that requires -dumpversion and +# errors with -dumpfullversion +- layout: + - executables: + - "bin/gcc-5" + - "bin/g++-5" + - "bin/gfortran-5" + script: | + if [ "$1" = "-dumpversion" ] ; then + echo "5.5.0" + else + echo "gcc-5: fatal error: no input files" + echo "compilation terminated." + exit 1 + fi + platforms: ["darwin", "linux"] + results: + - spec: "gcc@5.5.0 languages=c,c++,fortran" + extra_attributes: + compilers: + c: ".*/bin/gcc-5$" + cxx: ".*/bin/g[+][+]-5$" + fortran: ".*/bin/gfortran-5$" + +# Multiple compilers present at the same time +- layout: + - executables: + - "bin/x86_64-linux-gnu-gcc-6" + script: 'echo 6.5.0' + - executables: + - "bin/x86_64-linux-gnu-gcc-10" + - "bin/x86_64-linux-gnu-g++-10" + script: "echo 10.1.0" + platforms: [darwin, linux] + results: + - spec: "gcc@6.5.0 languages=c" + extra_attributes: + compilers: + c: ".*/bin/x86_64-linux-gnu-gcc-6$" + - spec: "gcc@10.1.0 languages=c,c++" + extra_attributes: + compilers: + c: ".*/bin/x86_64-linux-gnu-gcc-10$" + cxx: ".*/bin/x86_64-linux-gnu-g[+][+]-10$" + +# Apple clang under disguise as gcc should not be detected +- layout: + - executables: + - "bin/gcc" + script: | + if [ "$1" = "-dumpversion" ] ; then + echo "15.0.0" + elif [ "$1" = "-dumpfullversion" ] ; then + echo "clang: error: no input files" >&2 + exit 1 + elif [ "$1" = "--version" ] ; then + echo "Apple clang version 15.0.0 (clang-1500.3.9.4)" + echo "Target: x86_64-apple-darwin23.4.0" + echo "Thread model: posix" + echo "InstalledDir: /Library/Developer/CommandLineTools/usr/bin" + else + echo "mock executable got an unexpected flag: $1" + exit 1 + fi + platforms: ["darwin"] + results: [] diff --git a/var/spack/repos/builtin/packages/gcc/package.py b/var/spack/repos/builtin/packages/gcc/package.py index ea11cba15a8e97..a17060b147931c 100644 --- a/var/spack/repos/builtin/packages/gcc/package.py +++ b/var/spack/repos/builtin/packages/gcc/package.py @@ -5,23 +5,21 @@ import glob import itertools import os -import re import sys from archspec.cpu import UnsupportedMicroarchitecture import llnl.util.tty as tty -from llnl.util.lang import classproperty from llnl.util.symlink import readlink import spack.platforms import spack.util.executable -from spack.build_environment import dso_suffix +import spack.util.libc from spack.operating_systems.mac_os import macos_sdk_path, macos_version from spack.package import * -class Gcc(AutotoolsPackage, GNUMirrorPackage): +class Gcc(AutotoolsPackage, GNUMirrorPackage, CompilerPackage): """The GNU Compiler Collection includes front ends for C, C++, Objective-C, Fortran, Ada, and Go, as well as libraries for these languages.""" @@ -38,9 +36,13 @@ class Gcc(AutotoolsPackage, GNUMirrorPackage): version("master", branch="master") + version("14.1.0", sha256="e283c654987afe3de9d8080bc0bd79534b5ca0d681a73a11ff2b5d3767426840") + + version("13.3.0", sha256="0845e9621c9543a13f484e94584a49ffc0129970e9914624235fc1d061a0c083") version("13.2.0", sha256="e275e76442a6067341a27f04c5c6b83d8613144004c0413528863dc6b5c743da") version("13.1.0", sha256="61d684f0aa5e76ac6585ad8898a2427aade8979ed5e7f85492286c4dfc13ee86") + version("12.4.0", sha256="704f652604ccbccb14bdabf3478c9511c89788b12cb3bbffded37341916a9175") version("12.3.0", sha256="949a5d4f99e786421a93b532b22ffab5578de7321369975b91aec97adfda8c3b") version("12.2.0", sha256="e549cf9cf3594a00e27b6589d4322d70e0720cdd213f39beb4181e06926230ff") version("12.1.0", sha256="62fd634889f31c02b64af2c468f064b47ad1ca78411c45abe6ac4b5f8dd19c7b") @@ -96,6 +98,10 @@ class Gcc(AutotoolsPackage, GNUMirrorPackage): version("4.6.4", sha256="35af16afa0b67af9b8eb15cafb76d2bc5f568540552522f5dc2c88dd45d977e8") version("4.5.4", sha256="eef3f0456db8c3d992cbb51d5d32558190bc14f3bc19383dd93acc27acc6befc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # We specifically do not add 'all' variant here because: # (i) Ada, D, Go, Jit, and Objective-C++ are not default languages. # In that respect, the name 'all' is rather misleading. @@ -129,6 +135,7 @@ class Gcc(AutotoolsPackage, GNUMirrorPackage): description="Compilers and runtime libraries to build", ) variant("binutils", default=False, description="Build via binutils") + variant("mold", default=False, description="Use mold as the linker by default", when="@12:") variant( "piclibs", default=False, description="Build PIC versions of libgfortran.a and libstdc++.a" ) @@ -193,6 +200,7 @@ class Gcc(AutotoolsPackage, GNUMirrorPackage): depends_on( "binutils+gas+ld+plugins~libiberty", when="+binutils", type=("build", "link", "run") ) + depends_on("mold", when="+mold") depends_on("zip", type="build", when="languages=java") # The server is sometimes a bit slow to respond @@ -422,6 +430,11 @@ class Gcc(AutotoolsPackage, GNUMirrorPackage): sha256="2df7ef067871a30b2531a2013b3db661ec9e61037341977bfc451e30bf2c1035", when="@13.2.0 target=aarch64:", ) + patch( + "https://raw.githubusercontent.com/Homebrew/formula-patches/82b5c1cd38826ab67ac7fc498a8fe74376a40f4a/gcc/gcc-14.1.0.diff", + sha256="1529cff128792fe197ede301a81b02036c8168cb0338df21e4bc7aafe755305a", + when="@14.1.0 target=aarch64:", + ) conflicts("+bootstrap", when="@11.3.0,13.1: target=aarch64:") # Use -headerpad_max_install_names in the build, @@ -503,11 +516,36 @@ class Gcc(AutotoolsPackage, GNUMirrorPackage): build_directory = "spack-build" - @classproperty - def executables(cls): - names = [r"gcc", r"[^\w]?g\+\+", r"gfortran", r"gdc", r"gccgo"] - suffixes = [r"", r"-mp-\d+\.\d", r"-\d+\.\d", r"-\d+", r"\d\d"] - return [r"".join(x) for x in itertools.product(names, suffixes)] + compiler_languages = ["c", "cxx", "fortran", "d", "go"] + + @property + def supported_languages(self): + # This weirdness is because it could be called on an abstract spec + if "languages" not in self.spec.variants: + return self.compiler_languages + return [x for x in self.compiler_languages if x in self.spec.variants["languages"].value] + + c_names = ["gcc"] + cxx_names = ["g++"] + fortran_names = ["gfortran"] + d_names = ["gdc"] + go_names = ["gccgo"] + compiler_prefixes = [r"\w+-\w+-\w+-"] + compiler_suffixes = [r"-mp-\d+(?:\.\d+)?", r"-\d+(?:\.\d+)?", r"\d\d"] + compiler_version_regex = r"(?/bin.""" if not self.spec_dir: - tty.warn( - "Could not install specs for {0}.".format(self.spec.format("{name}{@version}")) - ) + tty.warn(f"Could not install specs for {self.spec.format('{name}{@version}')}.") return - gcc = self.spec["gcc"].command - lines = gcc("-dumpspecs", output=str).splitlines(True) + # Find which directories have shared libraries + for dir in ["lib64", "lib"]: + libdir = join_path(self.prefix, dir) + if glob.glob(join_path(libdir, "libgcc_s.*")): + rpath_dir = libdir + break + else: + tty.warn("No dynamic libraries found in lib/lib64") + rpath_dir = None + specs_file = join_path(self.spec_dir, "specs") + with open(specs_file, "w") as f: + # can't extend the builtins without dumping them first + f.write(self.spec["gcc"].command("-dumpspecs", output=str, error=os.devnull).strip()) - # Save a backup - with open(specs_file + ".orig", "w") as out: - out.writelines(lines) + f.write("\n\n# Generated by Spack\n\n") - # Find which directories have shared libraries - rpath_libdirs = [] - for dir in ["lib", "lib64"]: - libdir = join_path(self.prefix, dir) - if glob.glob(join_path(libdir, "*." + dso_suffix)): - rpath_libdirs.append(libdir) + # rpath + if rpath_dir: + f.write(f"*link_libgcc:\n+ -rpath {rpath_dir}\n\n") - if not rpath_libdirs: - # No shared libraries - tty.warn("No dynamic libraries found in lib/lib64") - return + # programs search path + if self.spec.satisfies("+binutils"): + f.write(f"*self_spec:\n+ -B{self.spec['binutils'].prefix.bin}\n\n") + + # set -fuse-ld=mold as the default linker when +mold + if self.spec.satisfies("+mold"): + f.write( + f"*self_spec:\n+ -B{self.spec['mold'].prefix.bin} " + "%{!fuse-ld*:-fuse-ld=mold}\n\n" + ) - # Overwrite the specs file - with open(specs_file, "w") as out: - for line in lines: - out.write(line) - if line.startswith("*link_libgcc:"): - # Insert at start of line following link_libgcc, which gets - # inserted into every call to the linker - out.write("%(link_libgcc_rpath) ") - - # Add easily-overridable rpath string at the end - out.write("*link_libgcc_rpath:\n") - out.write(" ".join("-rpath " + lib for lib in rpath_libdirs)) - out.write("\n") set_install_permissions(specs_file) - tty.info("Wrote new spec file to {0}".format(specs_file)) + tty.info(f"Wrote new spec file to {specs_file}") def setup_run_environment(self, env): # Search prefix directory for possibly modified compiler names @@ -1144,7 +1108,7 @@ def detect_gdc(self): ) @classmethod - def runtime_constraints(cls, *, compiler, pkg): + def runtime_constraints(cls, *, spec, pkg): """Callback function to inject runtime-related rules into the solver. Rule-injection is obtained through method calls of the ``pkg`` argument. @@ -1153,7 +1117,7 @@ def runtime_constraints(cls, *, compiler, pkg): we'll document the behavior at https://spack.readthedocs.io/en/latest/ Args: - compiler: compiler object (node attribute) currently considered + spec: spec that will inject runtime dependencies pkg: object used to forward information to the solver """ pkg("*").depends_on( @@ -1163,11 +1127,89 @@ def runtime_constraints(cls, *, compiler, pkg): description="If any package uses %gcc, it depends on gcc-runtime", ) pkg("*").depends_on( - f"gcc-runtime@{str(compiler.version)}:", - when=f"%{str(compiler.spec)}", + f"gcc-runtime@{str(spec.version)}:", + when=f"%{str(spec)}", type="link", - description=f"If any package uses %{str(compiler.spec)}, " - f"it depends on gcc-runtime@{str(compiler.version)}:", + description=f"If any package uses %{str(spec)}, " + f"it depends on gcc-runtime@{str(spec.version)}:", ) + + gfortran_str = "libgfortran@5" + if spec.satisfies("gcc@:6"): + gfortran_str = "libgfortran@3" + elif spec.satisfies("gcc@7"): + gfortran_str = "libgfortran@4" + + for fortran_virtual in ("fortran-rt", gfortran_str): + pkg("*").depends_on( + fortran_virtual, + when=f"%{str(spec)}", + languages=["fortran"], + type="link", + description=f"Add a dependency on '{gfortran_str}' for nodes compiled with " + f"{str(spec)} and using the 'fortran' language", + ) # The version of gcc-runtime is the same as the %gcc used to "compile" it - pkg("gcc-runtime").requires(f"@={str(compiler.version)}", when=f"%{str(compiler.spec)}") + pkg("gcc-runtime").requires(f"@={str(spec.version)}", when=f"%{str(spec)}") + + # If a node used %gcc@X.Y its dependencies must use gcc-runtime@:X.Y + # (technically @:X is broader than ... <= @=X but this should work in practice) + pkg("*").propagate(f"%gcc@:{str(spec.version)}", when=f"%{str(spec)}") + + def _post_buildcache_install_hook(self): + if not self.spec.satisfies("platform=linux"): + return + + # Setting up the runtime environment shouldn't be necessary here. + relocation_args = [] + gcc = self.spec["gcc"].command + specs_file = os.path.join(self.spec_dir, "specs") + dryrun = gcc("test.c", "-###", output=os.devnull, error=str).strip() + if not dryrun: + tty.warn(f"Cannot relocate {specs_file}, compiler might not be working properly") + return + dynamic_linker = spack.util.libc.parse_dynamic_linker(dryrun) + if not dynamic_linker: + tty.warn(f"Cannot relocate {specs_file}, compiler might not be working properly") + return + + libc = spack.util.libc.libc_from_dynamic_linker(dynamic_linker) + + # We search for crt1.o ourselves because `gcc -print-prile-name=crt1.o` can give a rather + # convoluted relative path from a different prefix. + startfile_prefix = spack.util.libc.startfile_prefix(libc.external_path, dynamic_linker) + + gcc_can_locate = lambda p: os.path.isabs( + gcc(f"-print-file-name={p}", output=str, error=os.devnull).strip() + ) + + if not gcc_can_locate("crt1.o"): + relocation_args.append(f"-B{startfile_prefix}") + + # libc headers may also be in a multiarch subdir. + header_dir = spack.util.libc.libc_include_dir_from_startfile_prefix( + libc.external_path, startfile_prefix + ) + if header_dir and all( + os.path.exists(os.path.join(header_dir, h)) + for h in libc.package_class.representative_headers + ): + relocation_args.append(f"-idirafter {header_dir}") + else: + tty.warn( + f"Cannot relocate {specs_file} include directories, " + f"compiler might not be working properly" + ) + + # Delete current spec files. + try: + os.unlink(specs_file) + except OSError: + pass + + # Write a new one and append flags for libc + self.write_specs_file() + + if relocation_args: + with open(specs_file, "a") as f: + f.write(f"*self_spec:\n+ {' '.join(relocation_args)}\n\n") diff --git a/var/spack/repos/builtin/packages/gccxml/package.py b/var/spack/repos/builtin/packages/gccxml/package.py index 2b492412a25301..fba71f1f27ac6d 100644 --- a/var/spack/repos/builtin/packages/gccxml/package.py +++ b/var/spack/repos/builtin/packages/gccxml/package.py @@ -16,6 +16,9 @@ class Gccxml(CMakePackage): version("develop", branch="master") version("latest", commit="3afa8ba5be6866e603dcabe80aff79856b558e24", preferred=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("darwin-gcc.patch", when="%gcc platform=darwin") # taken from https://github.com/gccxml/gccxml/issues/11#issuecomment-140334118 patch("gcc-5.patch", when="%gcc@5:") diff --git a/var/spack/repos/builtin/packages/gchp/package.py b/var/spack/repos/builtin/packages/gchp/package.py index 3c1b892fc59dee..837f54bc90c3cf 100644 --- a/var/spack/repos/builtin/packages/gchp/package.py +++ b/var/spack/repos/builtin/packages/gchp/package.py @@ -29,6 +29,10 @@ class Gchp(CMakePackage): version("13.0.0", commit="1f5a5c5630c5d066ff8306cbb8b83e267ca7c265", submodules=True) version("dev", branch="dev", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + patch("for_aarch64.patch", when="target=aarch64:") depends_on("esmf@8.0.1", when="@13.0.0:") diff --git a/var/spack/repos/builtin/packages/gconf/package.py b/var/spack/repos/builtin/packages/gconf/package.py index 3b6098b1139e54..072c44606cdfbd 100644 --- a/var/spack/repos/builtin/packages/gconf/package.py +++ b/var/spack/repos/builtin/packages/gconf/package.py @@ -22,6 +22,8 @@ class Gconf(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("gettext", type="build") depends_on("intltool", type="build") diff --git a/var/spack/repos/builtin/packages/gcta/package.py b/var/spack/repos/builtin/packages/gcta/package.py index 19b89f45e33ede..d3a2e218e181f4 100644 --- a/var/spack/repos/builtin/packages/gcta/package.py +++ b/var/spack/repos/builtin/packages/gcta/package.py @@ -21,6 +21,9 @@ class Gcta(CMakePackage): version("1.94.0beta", commit="746e3975ddb463fc7bd15b03c6cc64b023eca497", submodules=True) version("1.91.2", sha256="0609d0fba856599a2acc66adefe87725304117acc226360ec2aabf8a0ac64e85") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + conflicts("target=aarch64:", when="@:1.91.2", msg="aarch64 support added in 1.94.0") depends_on("cmake@3.1:", type="build") diff --git a/var/spack/repos/builtin/packages/gdal/package.py b/var/spack/repos/builtin/packages/gdal/package.py index 53d9162f9d592e..54e098e5509611 100644 --- a/var/spack/repos/builtin/packages/gdal/package.py +++ b/var/spack/repos/builtin/packages/gdal/package.py @@ -9,7 +9,7 @@ from spack.build_systems.autotools import AutotoolsBuilder from spack.build_systems.cmake import CMakeBuilder from spack.package import * -from spack.util.environment import filter_system_paths, is_system_path +from spack.util.environment import filter_system_paths class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): @@ -32,6 +32,9 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): license("MIT") + version("3.9.1", sha256="aff3086fee75f5773e33a5598df98d8a4d10be411f777d3ce23584b21d8171ca") + version("3.9.0", sha256="577f80e9d14ff7c90b6bfbc34201652b4546700c01543efb4f4c3050e0b3fda2") + version("3.8.5", sha256="e8b4df2a8a7d25272f867455c0c230459545972f81f0eff2ddbf6a6f60dcb1e4") version("3.8.4", sha256="0c53ced95d29474236487202709b49015854f8e02e35e44ed0f4f4e12a7966ce") version("3.8.3", sha256="ae2d160f65016e208eca34ff14490ec4511f1fa03fd386ac130449d15e82929d") version("3.8.2", sha256="dc2921ee1cf7a5c0498e94d15fb9ab9c9689c296363a1d021fc3293dd242b4db") @@ -72,29 +75,33 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): version("3.0.2", sha256="c3765371ce391715c8f28bd6defbc70b57aa43341f6e94605f04fe3c92468983") version("3.0.1", sha256="45b4ae25dbd87282d589eca76481c426f72132d7a599556470d5c38263b09266") version("3.0.0", sha256="ad316fa052d94d9606e90b20a514b92b2dd64e3142dfdbd8f10981a5fcd5c43e") - version("2.4.4", sha256="a383bd3cf555d6e1169666b01b5b3025b2722ed39e834f1b65090f604405dcd8") - version("2.4.3", sha256="d52dc3e0cff3af3e898d887c4151442989f416e839948e73f0994f0224bbff60") - version("2.4.2", sha256="dcc132e469c5eb76fa4aaff238d32e45a5d947dc5b6c801a123b70045b618e0c") - version("2.4.1", sha256="fd51b4900b2fc49b98d8714f55fc8a78ebfd07218357f93fb796791115a5a1ad") - version("2.4.0", sha256="c3791dcc6d37e59f6efa86e2df2a55a4485237b0a48e330ae08949f0cdf00f27") - version("2.3.3", sha256="c3635e41766a648f945d235b922e3c5306e26a2ee5bbd730d2181e242f5f46fe") - version("2.3.2", sha256="3f6d78fe8807d1d6afb7bed27394f19467840a82bc36d65e66316fa0aa9d32a4") - version("2.3.1", sha256="9c4625c45a3ee7e49a604ef221778983dd9fd8104922a87f20b99d9bedb7725a") - version("2.3.0", sha256="6f75e49aa30de140525ccb58688667efe3a2d770576feb7fbc91023b7f552aa2") - version("2.2.4", sha256="441eb1d1acb35238ca43a1a0a649493fc91fdcbab231d0747e9d462eea192278") - version("2.2.3", sha256="a328d63d476b3653f5a25b5f7971e87a15cdf8860ab0729d4b1157ba988b8d0b") - version("2.2.2", sha256="eb25d6ee85f4f5ac1d5581958f8c6eed9b1d50746f82866fe92e507541def35b") - version("2.2.1", sha256="927098d54083ac919a497f787b835b099e9a194f2e5444dbff901f7426b86066") - version("2.2.0", sha256="0d4c326862e0f118e17418c042c2bcd037b25abd3fb198e1fc5d40b11a9fc8ea") - version("2.1.4", sha256="e06a7ae4c4ed2fd678cd045ff50a10ff5002f3b81cdfcd8ab03c39ce962d9b63") - version("2.1.3", sha256="b489793627e6cb8d2ff8d7737b61daf58382fe189fae4c581ddfd48c04b49005") - version("2.1.2", sha256="b597f36bd29a2b4368998ddd32b28c8cdf3c8192237a81b99af83cc17d7fa374") - version("2.1.1", sha256="87ce516ce757ad1edf1e21f007fbe232ed2e932af422e9893f40199711c41f92") - version("2.1.0", sha256="568b43441955b306364fcf97fb47d4c1512ac6f2f5f76b2ec39a890d2418ee03") - version("2.0.3", sha256="3c6c5ade299c7a52fc9c5d2111110c97032e1f0c2593ce6091c364b1a43b442a") - version("2.0.2", sha256="90f838853cc1c07e55893483faa7e923e4b4b1659c6bc9df3538366030a7e622") - version("2.0.1", sha256="2564c91ed8ed36274ee31002a25798f5babc4221e879cb5013867733d80f9920") - version("2.0.0", sha256="91704fafeea2349c5e268dc1e2d03921b3aae64b05ee01d59fdfc1a6b0ffc061") + with default_args(deprecated=True): + version("2.4.4", sha256="a383bd3cf555d6e1169666b01b5b3025b2722ed39e834f1b65090f604405dcd8") + version("2.4.3", sha256="d52dc3e0cff3af3e898d887c4151442989f416e839948e73f0994f0224bbff60") + version("2.4.2", sha256="dcc132e469c5eb76fa4aaff238d32e45a5d947dc5b6c801a123b70045b618e0c") + version("2.4.1", sha256="fd51b4900b2fc49b98d8714f55fc8a78ebfd07218357f93fb796791115a5a1ad") + version("2.4.0", sha256="c3791dcc6d37e59f6efa86e2df2a55a4485237b0a48e330ae08949f0cdf00f27") + version("2.3.3", sha256="c3635e41766a648f945d235b922e3c5306e26a2ee5bbd730d2181e242f5f46fe") + version("2.3.2", sha256="3f6d78fe8807d1d6afb7bed27394f19467840a82bc36d65e66316fa0aa9d32a4") + version("2.3.1", sha256="9c4625c45a3ee7e49a604ef221778983dd9fd8104922a87f20b99d9bedb7725a") + version("2.3.0", sha256="6f75e49aa30de140525ccb58688667efe3a2d770576feb7fbc91023b7f552aa2") + version("2.2.4", sha256="441eb1d1acb35238ca43a1a0a649493fc91fdcbab231d0747e9d462eea192278") + version("2.2.3", sha256="a328d63d476b3653f5a25b5f7971e87a15cdf8860ab0729d4b1157ba988b8d0b") + version("2.2.2", sha256="eb25d6ee85f4f5ac1d5581958f8c6eed9b1d50746f82866fe92e507541def35b") + version("2.2.1", sha256="927098d54083ac919a497f787b835b099e9a194f2e5444dbff901f7426b86066") + version("2.2.0", sha256="0d4c326862e0f118e17418c042c2bcd037b25abd3fb198e1fc5d40b11a9fc8ea") + version("2.1.4", sha256="e06a7ae4c4ed2fd678cd045ff50a10ff5002f3b81cdfcd8ab03c39ce962d9b63") + version("2.1.3", sha256="b489793627e6cb8d2ff8d7737b61daf58382fe189fae4c581ddfd48c04b49005") + version("2.1.2", sha256="b597f36bd29a2b4368998ddd32b28c8cdf3c8192237a81b99af83cc17d7fa374") + version("2.1.1", sha256="87ce516ce757ad1edf1e21f007fbe232ed2e932af422e9893f40199711c41f92") + version("2.1.0", sha256="568b43441955b306364fcf97fb47d4c1512ac6f2f5f76b2ec39a890d2418ee03") + version("2.0.3", sha256="3c6c5ade299c7a52fc9c5d2111110c97032e1f0c2593ce6091c364b1a43b442a") + version("2.0.2", sha256="90f838853cc1c07e55893483faa7e923e4b4b1659c6bc9df3538366030a7e622") + version("2.0.1", sha256="2564c91ed8ed36274ee31002a25798f5babc4221e879cb5013867733d80f9920") + version("2.0.0", sha256="91704fafeea2349c5e268dc1e2d03921b3aae64b05ee01d59fdfc1a6b0ffc061") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated # Optional dependencies variant("archive", default=False, when="@3.7:", description="Optional for vsi7z VFS driver") @@ -250,18 +257,22 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): with when("build_system=cmake"): generator("ninja") + depends_on("cmake@3.16:", type="build", when="@3.9:") depends_on("cmake@3.9:", type="build") with when("build_system=autotools"): depends_on("gmake", type="build") # Required dependencies + # Versions come from gdal_check_package in cmake/helpers/CheckDependentLibraries.cmake depends_on("pkgconfig@0.25:", type="build") + depends_on("proj@6.3.1:", when="@3.9:") depends_on("proj@6:", when="@3:") depends_on("proj@:6", when="@2.5:2") depends_on("proj@:5", when="@2.4") depends_on("proj@:4", when="@:2.3") depends_on("zlib-api") + depends_on("libtiff@4.1:", when="@3.9:") depends_on("libtiff@4:", when="@3:") depends_on("libtiff@3.6.0:") # 3.9.0+ needed to pass testsuite depends_on("libgeotiff@1.5:", when="@3:") @@ -282,6 +293,7 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): # depends_on('bsb', when='+bsb') depends_on("cfitsio", when="+cfitsio") depends_on("crunch", when="+crnlib") + depends_on("curl@7.68:", when="@3.9:+curl") depends_on("curl", when="+curl") depends_on("cryptopp", when="+cryptopp") depends_on("libdeflate", when="+deflate") @@ -293,6 +305,7 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): # depends_on('fme', when='+fme') depends_on("freexl", when="+freexl") depends_on("fyba", when="+fyba") + depends_on("geos@3.8:", when="@3.9:+geos") depends_on("geos@3.1:", when="+geos") depends_on("giflib", when="+gif") depends_on("grass@5.7:", when="+grass") @@ -300,9 +313,11 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): depends_on("libgta", when="+gta") depends_on("libheif@1.1:", when="+heif") depends_on("hdf", when="+hdf4") - depends_on("hdf5+cxx", when="+hdf5") - depends_on("hdf5@:1.13", when="@:3.5 +hdf5") - depends_on("hdf5@:1.12", when="@:3.4 +hdf5") + depends_on("hdf5@1.10:", when="@3.9:+hdf5") + depends_on("hdf5@:1.13", when="@:3.5+hdf5") + depends_on("hdf5@:1.12", when="@:3.4+hdf5") + depends_on("hdf5+cxx", when="@3.8:+hdf5+kea") + depends_on("hdf5+cxx", when="@:3.7+hdf5") depends_on("hadoop", when="+hdfs") depends_on("iconv", when="+iconv") # depends_on('idb', when='+idb') @@ -317,6 +332,7 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): # depends_on('libcsf', when='+libcsf') depends_on("libkml@1.3:", when="+libkml") depends_on("xz", when="+liblzma") + depends_on("qb3", when="+libqb3") depends_on("libxml2", when="+libxml2") # depends_on('luratech', when='+luratech') depends_on("lz4", when="+lz4") @@ -329,6 +345,7 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): # depends_on('mssql_ncli', when='+mssql_ncli') # depends_on('mssql_odbc', when='+mssql_odbc') depends_on("mysql", when="+mysql") + depends_on("netcdf-c@4.7:", when="@3.9:+netcdf") depends_on("netcdf-c", when="+netcdf") depends_on("unixodbc", when="+odbc") # depends_on('odbc-cpp-wrapper', when='+odbccpp') @@ -336,6 +353,7 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): # depends_on('lib-opencad', when='+opencad') depends_on("opencl", when="+opencl") depends_on("openexr@2.2:", when="+openexr") + depends_on("openjpeg@2.3.1:", when="@3.9:+openjpeg") depends_on("openjpeg", when="+openjpeg") depends_on("openssl", when="+openssl") depends_on("oracle-instant-client", when="+oracle") @@ -344,26 +362,32 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): depends_on("pcre2", when="@3.5:+pcre2") depends_on("pcre", when="@:3.4+pcre2") # depends_on('pdfium', when='+pdfium') + depends_on("libpng@1.6:", when="@3.9:+png") depends_on("libpng", when="+png") # depends_on('podofo', when='+podofo') + depends_on("poppler@0.86:", when="@3.9:+poppler") + depends_on("poppler@0.24:", when="@3:+poppler") + depends_on("poppler@:0.63", when="@:2.3+poppler") + depends_on("poppler@:0.71", when="@:2.4+poppler") + depends_on("poppler@:21", when="@:3.4.1+poppler") depends_on("poppler", when="+poppler") - depends_on("poppler@0.24:", when="@3: +poppler") - depends_on("poppler@:0.63", when="@:2.3 +poppler") - depends_on("poppler@:0.71", when="@:2.4 +poppler") - depends_on("poppler@:21", when="@:3.4.1 +poppler") depends_on("postgresql", when="+postgresql") - depends_on("qb3", when="+libqb3") depends_on("qhull", when="+qhull") depends_on("qhull@2015:", when="@3.5:+qhull") depends_on("qhull@:2020.1", when="@:3.3+qhull") # depends_on('rasdaman', when='+rasdaman') - # depends_on('rasterlite2@1.1:', when='+rasterlite2') + # depends_on('rasterlite2@1.1:', when='@3.7:+rasterlite2') + # depends_on('rasterlite2', when='+rasterlite2') # depends_on('rdblib', when='+rdb') # depends_on('sde', when='+sde') depends_on("sfcgal", when="+sfcgal") + depends_on("libspatialite@4.1.2:", when="@3.7:+spatialite") depends_on("libspatialite", when="+spatialite") + depends_on("sqlite@3.31:", when="@3.9:+sqlite3") depends_on("sqlite@3:", when="+sqlite3") # depends_on('teigha', when='+teigha') + # depends_on('tiledb@2.15:', when='@3.9:+tiledb') + # depends_on('tiledb@2.7:', when='@3.7:+tiledb') # depends_on('tiledb', when='+tiledb') depends_on("libwebp", when="+webp") depends_on("xerces-c@3.1:", when="+xercesc") @@ -376,17 +400,20 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): # extends('openjdk', when='+java') # extends('perl', when='+perl') - # see gdal_version_and_min_supported_python_version - # in swig/python/osgeo/__init__.py - depends_on("python@3.6:", type=("build", "link", "run"), when="@3.3:+python") - depends_on("python@2.0:", type=("build", "link", "run"), when="@3.2:+python") + # swig/python/pyproject.toml (3.9+) + # swig/python/setup.py.in (3.5-3.8) + # swig/python/osgeo/__init__.py (3.4-) depends_on("python", type=("build", "link", "run"), when="+python") # Uses distutils depends_on("python@:3.11", type=("build", "link", "run"), when="@:3.4+python") - # swig/python/setup.py + # swig/python/pyproject.toml (3.9+) + # swig/python/setup.py (3.8-) + depends_on("py-setuptools@67:", type="build", when="@3.9:+python") depends_on("py-setuptools@:57", type="build", when="@:3.2+python") # needs 2to3 depends_on("py-setuptools", type="build", when="+python") depends_on("py-numpy@1.0.0:", type=("build", "run"), when="+python") + # https://github.com/OSGeo/gdal/issues/9751 + depends_on("py-numpy@:1", when="@:3.8+python", type=("build", "run")) depends_on("swig", type="build", when="+python") depends_on("java@7:", type=("build", "link", "run"), when="@3.2:+java") depends_on("java@6:", type=("build", "link", "run"), when="@2.4:+java") @@ -402,13 +429,17 @@ class Gdal(CMakePackage, AutotoolsPackage, PythonExtension): # https://gdal.org/development/rfc/rfc88_googletest.html depends_on("googletest@1.10:", type="test") - # https://trac.osgeo.org/gdal/wiki/SupportedCompilers + # https://gdal.org/development/rfc/rfc98_build_requirements_gdal_3_9.html + msg = "GDAL requires C++17 support" + conflicts("%gcc@:7", msg=msg) + conflicts("%clang@:4", msg=msg) + conflicts("%msvc@:19.14", msg=msg) + + # https://gdal.org/development/rfc/rfc68_cplusplus11.html msg = "GDAL requires C++11 support" conflicts("%gcc@:4.8.0", msg=msg) conflicts("%clang@:3.2", msg=msg) - conflicts("%intel@:12", msg=msg) - conflicts("%xl@:13.0", msg=msg) - conflicts("%xl_r@:13.0", msg=msg) + conflicts("%msvc@:13", msg=msg) # https://github.com/OSGeo/gdal/issues/5994 conflicts("~png", when="@3:3.5.0") @@ -490,6 +521,7 @@ def setup_run_environment(self, env): def patch(self): if "+java platform=darwin" in self.spec: filter_file("linux", "darwin", "swig/java/java.opt", string=True) + filter_file("-lazy-ljvm", "-ljvm", "configure", string=True) class CMakeBuilder(CMakeBuilder): @@ -716,10 +748,10 @@ def configure_args(self): self.with_or_without("php"), ] if "+iconv" in self.spec: - if self.spec["iconv"].name == "libc": + if self.spec["iconv"].name == "libiconv": + args.append(f"--with-libiconv-prefix={self.spec['iconv'].prefix}") + else: args.append("--without-libiconv-prefix") - elif not is_system_path(self.spec["iconv"].prefix): - args.append("--with-libiconv-prefix=" + self.spec["iconv"].prefix) # Renamed or modified flags if self.spec.satisfies("@3:"): @@ -753,7 +785,7 @@ def configure_args(self): if "+hdf4" in self.spec: hdf4 = self.spec["hdf"] - if "+external-xdr" in hdf4 and hdf4["rpc"].name != "libc": + if "+external-xdr" in hdf4 and hdf4["rpc"].name == "libtirpc": args.append("LIBS=" + hdf4["rpc"].libs.link_flags) # Remove empty strings diff --git a/var/spack/repos/builtin/packages/gdb/package.py b/var/spack/repos/builtin/packages/gdb/package.py index 85bfeaade8c166..6367736ba96307 100644 --- a/var/spack/repos/builtin/packages/gdb/package.py +++ b/var/spack/repos/builtin/packages/gdb/package.py @@ -21,6 +21,7 @@ class Gdb(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-or-later AND LGPL-3.0-or-later") + version("14.2", sha256="2de5174762e959a5e529e20c20d88a04735469d8fffd98f61664e70b341dc47c") version("14.1", sha256="683e63182fb72bd5d8db32ab388143796370a8e3e71c26bc264effb487db7927") version("13.2", sha256="7ead13d9e19fa0c57bb19104e1a5f67eefa9fc79f2e6360de491e8fddeda1e30") version("13.1", sha256="4cc3d7143d6d54d289d227b1e7289dbc0fa4cbd46131ab87136e1ea831cf46d4") @@ -42,6 +43,10 @@ class Gdb(AutotoolsPackage, GNUMirrorPackage): version("7.11.1", sha256="57e9e9aa3172ee16aa1e9c66fef08b4393b51872cc153e3f1ffdf18a57440586") version("7.10.1", sha256="ff14f8050e6484508c73cbfa63731e57901478490ca1672dc0b5e2b03f6af622") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("python", default=True, description="Compile with Python support", when="@8.2:") variant("xz", default=True, description="Compile with lzma support") variant("source-highlight", default=False, description="Compile with source-highlight support") @@ -85,6 +90,7 @@ class Gdb(AutotoolsPackage, GNUMirrorPackage): depends_on("xz", when="+xz") depends_on("zlib-api") depends_on("zstd", when="@13.1:") + depends_on("pkgconfig", type="build", when="@13.1:") depends_on("source-highlight", when="+source-highlight") depends_on("ncurses", when="+tui") depends_on("gmp", when="@11.1:") diff --git a/var/spack/repos/builtin/packages/gdbm/package.py b/var/spack/repos/builtin/packages/gdbm/package.py index e2efcf9683a650..cd64cbc38db2de 100644 --- a/var/spack/repos/builtin/packages/gdbm/package.py +++ b/var/spack/repos/builtin/packages/gdbm/package.py @@ -31,6 +31,8 @@ class Gdbm(AutotoolsPackage, GNUMirrorPackage): version("1.9.1", sha256="6025852637772b0699f2294b5f14fd4a084bca3c8161d29d64d1f30d6d1a9aed") version("1.9", sha256="f85324d7de3777db167581fd5d3493d2daa3e85e195a8ae9afc05b34551b6e57") + depends_on("c", type="build") # generated + depends_on("readline") patch("macOS.patch", when="@1.21 platform=darwin") diff --git a/var/spack/repos/builtin/packages/gdk-pixbuf/package.py b/var/spack/repos/builtin/packages/gdk-pixbuf/package.py index 97a57b6ce44fec..1dfe19f152164e 100644 --- a/var/spack/repos/builtin/packages/gdk-pixbuf/package.py +++ b/var/spack/repos/builtin/packages/gdk-pixbuf/package.py @@ -46,7 +46,9 @@ class GdkPixbuf(Package): deprecated=True, ) - variant("x11", default=False, description="Enable X11 support") + depends_on("c", type="build") # generated + + variant("x11", default=False, description="Enable X11 support", when="@:2.41") variant("tiff", default=False, description="Enable TIFF support(partially broken)") # Man page creation was getting docbook errors, see issue #18853 variant("man", default=False, description="Enable man page creation") @@ -56,7 +58,6 @@ class GdkPixbuf(Package): depends_on("meson@0.45.0:", type="build", when="@2.37.0:") depends_on("ninja", type="build", when="@2.37.0:") depends_on("shared-mime-info", when="@2.36.8: platform=linux") - depends_on("shared-mime-info", when="@2.36.8: platform=cray") depends_on("pkgconfig", type="build") # Building the man pages requires libxslt and the Docbook stylesheets depends_on("libxslt", type="build", when="+man") diff --git a/var/spack/repos/builtin/packages/gdl/package.py b/var/spack/repos/builtin/packages/gdl/package.py index b81062260df03c..fb95e6f63e0d92 100644 --- a/var/spack/repos/builtin/packages/gdl/package.py +++ b/var/spack/repos/builtin/packages/gdl/package.py @@ -20,6 +20,10 @@ class Gdl(CMakePackage): version("0.9.9", sha256="ad5de3fec095a5c58b46338dcc7367d2565c093794ab1bbcf180bba1a712cf14") version("0.9.8", sha256="0e22df7314feaf18a76ae39ee57eea2ac8c3633bc095acbc25e1e07277d7c98b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("graphicsmagick", default=False, description="Enable GraphicsMagick") variant("hdf4", default=False, description="Enable HDF4") diff --git a/var/spack/repos/builtin/packages/gdrcopy/package.py b/var/spack/repos/builtin/packages/gdrcopy/package.py index e5a98dbd5fb390..75ab32b9dff684 100644 --- a/var/spack/repos/builtin/packages/gdrcopy/package.py +++ b/var/spack/repos/builtin/packages/gdrcopy/package.py @@ -25,6 +25,9 @@ class Gdrcopy(MakefilePackage, CudaPackage): version("2.0", sha256="98320e6e980a7134ebc4eedd6cf23647104f2b3c557f2eaf0d31a02609f5f2b0") version("1.3", sha256="f11cdfe389b685f6636b80b4a3312dc014a385ad7220179c1318c60e2e28af3a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Don't call ldconfig: https://github.com/NVIDIA/gdrcopy/pull/229 patch("ldconfig.patch", when="@2.0:2.3") diff --git a/var/spack/repos/builtin/packages/geant3/package.py b/var/spack/repos/builtin/packages/geant3/package.py index cef0167b3b60ea..966f9fd58692e7 100644 --- a/var/spack/repos/builtin/packages/geant3/package.py +++ b/var/spack/repos/builtin/packages/geant3/package.py @@ -20,6 +20,10 @@ class Geant3(CMakePackage): version("3-5", sha256="5bec0b442bbb3456d5cd1751ac9f90f1da48df0fcb7f6bf0a86c566bfc408261") version("3-4", sha256="c7b487ab4fb4e6479c652b9b11dcafb686edf35e2f2048045c501e4f5597d62c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("root~vmc") depends_on("vmc") diff --git a/var/spack/repos/builtin/packages/geant4-data/package.py b/var/spack/repos/builtin/packages/geant4-data/package.py index c4134e356a9453..201d2e8d88f79a 100644 --- a/var/spack/repos/builtin/packages/geant4-data/package.py +++ b/var/spack/repos/builtin/packages/geant4-data/package.py @@ -18,6 +18,8 @@ class Geant4Data(BundlePackage): tags = ["hep"] + version("11.3.0") + version("11.2.2") version("11.2.0") version("11.1.0") version("11.0.0") @@ -43,8 +45,36 @@ class Geant4Data(BundlePackage): # they generally don't change on the patch level # Can move to declaring on a dataset basis if needed _datasets = { - "11.2.0:11.2": [ - "g4ndl@4.7", + "11.3.0:11.3": [ + "g4ndl@4.7.1", + "g4emlow@8.6", + "g4photonevaporation@5.7", + "g4radioactivedecay@5.6", + "g4particlexs@4.1", + "g4pii@1.3", + "g4realsurface@2.2", + "g4saiddata@2.0", + "g4abla@3.3", + "g4incl@1.2", + "g4ensdfstate@2.3", + "g4nudexlib@1.0", + "g4urrpt@1.0", + ], + "11.2.2:11.2": [ + "g4ndl@4.7.1", + "g4emlow@8.5", + "g4photonevaporation@5.7", + "g4radioactivedecay@5.6", + "g4particlexs@4.0", + "g4pii@1.3", + "g4realsurface@2.2", + "g4saiddata@2.0", + "g4abla@3.3", + "g4incl@1.2", + "g4ensdfstate@2.3", + ], + "11.2.0:11.2.1": [ + "g4ndl@=4.7", "g4emlow@8.5", "g4photonevaporation@5.7", "g4radioactivedecay@5.6", diff --git a/var/spack/repos/builtin/packages/geant4-vmc/package.py b/var/spack/repos/builtin/packages/geant4-vmc/package.py index 60e4bb866b412f..89bf862c534d43 100644 --- a/var/spack/repos/builtin/packages/geant4-vmc/package.py +++ b/var/spack/repos/builtin/packages/geant4-vmc/package.py @@ -35,6 +35,8 @@ class Geant4Vmc(CMakePackage): version("4-0-p2", sha256="cdd73c499cd296f13b6c0d37e161e7d94343f85617b2a7577ded8312248f9b9b") version("3-6-p6", sha256="e62a62ff7075ff9afb2ffe420610374f62136094a447bbbc5f739a2238ddb0f0") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.3:", type="build") depends_on("geant4") depends_on("vmc") diff --git a/var/spack/repos/builtin/packages/geant4/package.py b/var/spack/repos/builtin/packages/geant4/package.py index 2acab80fa21f16..2de7ab7b861665 100644 --- a/var/spack/repos/builtin/packages/geant4/package.py +++ b/var/spack/repos/builtin/packages/geant4/package.py @@ -21,7 +21,16 @@ class Geant4(CMakePackage): executables = ["^geant4-config$"] maintainers("drbenmorgan", "sethrj") - + version( + "11.3.0.beta", + sha256="572ba1570ca3b5b6f2a28ccbffa459901f6a986b79da1ebfdbf2f6f3dc5e14bf", + deprecated=True, + ) + version( + "11.2.2", + sha256="3a8d98c63fc52578f6ebf166d7dffaec36256a186d57f2520c39790367700c8d", + preferred=True, + ) version("11.2.1", sha256="76c9093b01128ee2b45a6f4020a1bcb64d2a8141386dea4674b5ae28bcd23293") version("11.2.0", sha256="9ff544739b243a24dac8f29a4e7aab4274fc0124fd4e1c4972018213dc6991ee") version("11.1.3", sha256="5d9a05d4ccf8b975649eab1d615fc1b8dce5937e01ab9e795bffd04149240db6") @@ -48,6 +57,8 @@ class Geant4(CMakePackage): version("10.3.3", sha256="bcd36a453da44de9368d1d61b0144031a58e4b43a6d2d875e19085f2700a89d8") version("10.0.4", sha256="97f3744366b00143d1eed52f8786823034bbe523f45998106f798af61d83f863") + depends_on("cxx", type="build") + _cxxstd_values = ( conditional("11", "14", when="@:10"), conditional("17", when="@10.4.1:"), @@ -93,7 +104,9 @@ class Geant4(CMakePackage): "10.7.4", "11.0", "11.1", - "11.2:", + "11.2.0:11.2.1", + "11.2.2:11.2", + "11.3:", ]: depends_on("geant4-data@" + _vers, type="run", when="@" + _vers) @@ -109,6 +122,7 @@ class Geant4(CMakePackage): extends("python", when="+python") # CLHEP version requirements to be reviewed + depends_on("clhep@2.4.7.1:", when="@11.3:") depends_on("clhep@2.4.6.0:", when="@11.1:") depends_on("clhep@2.4.5.1:", when="@11.0.0:") depends_on("clhep@2.4.4.0:", when="@10.7.0:") @@ -117,6 +131,7 @@ class Geant4(CMakePackage): # Vecgeom specific versions for each Geant4 version with when("+vecgeom"): + depends_on("vecgeom@1.2.8:", when="@11.3:") depends_on("vecgeom@1.2.6:", when="@11.2:") depends_on("vecgeom@1.2.0:", when="@11.1") depends_on("vecgeom@1.1.18:1.1", when="@11.0.0:11.0") @@ -151,8 +166,13 @@ def std_when(values): depends_on("libxmu", when="+x11") depends_on("motif", when="+motif") with when("+qt"): - depends_on("qt@5: +opengl") - depends_on("qt@5.9:", when="@11.2:") + depends_on("qmake") + with when("^[virtuals=qmake] qt-base"): + depends_on("qt-base +accessibility +gui +opengl") + with when("^[virtuals=qmake] qt"): + depends_on("qt@5: +opengl") + depends_on("qt@5.9:", when="@11.2:") + conflicts("@:11.1 ^[virtuals=qmake] qt-base", msg="Qt6 not supported before 11.2") # As released, 10.0.4 has inconsistently capitalised filenames # in the cmake files; this patch also enables cxxstd 14 @@ -162,7 +182,7 @@ def std_when(values): patch("CLHEP-10.03.03.patch", level=1, when="@10.3") # Build failure on clang 15, ubuntu 22: see Geant4 problem report #2444 # fixed by ascii-V10-07-03 - patch("geant4-10.6.patch", level=1, when="@10.5:10.6") + patch("geant4-10.6.patch", level=1, when="@10.0:10.6") # These patches can be applied independent of the cxxstd value? patch("cxx17.patch", when="@10.3 cxxstd=17") patch("cxx17_geant4_10_0.patch", level=1, when="@10.4.0 cxxstd=17") @@ -292,7 +312,9 @@ def cmake_args(self): if "+qt" in spec: options.append(self.define("GEANT4_USE_QT", True)) - options.append(self.define("QT_QMAKE_EXECUTABLE", spec["qt"].prefix.bin.qmake)) + if "^[virtuals=qmake] qt-base" in spec: + options.append(self.define("GEANT4_USE_QT_QT6", True)) + options.append(self.define("QT_QMAKE_EXECUTABLE", spec["qmake"].prefix.bin.qmake)) options.append(self.define_from_variant("GEANT4_USE_VTK", "vtk")) diff --git a/var/spack/repos/builtin/packages/gearshifft/package.py b/var/spack/repos/builtin/packages/gearshifft/package.py index c9cc7b7586dc90..3f25b066f5a21c 100644 --- a/var/spack/repos/builtin/packages/gearshifft/package.py +++ b/var/spack/repos/builtin/packages/gearshifft/package.py @@ -18,6 +18,8 @@ class Gearshifft(CMakePackage): version("0.4.0", sha256="15b9e4bfa1d9b4fe4ae316f289c67b7be0774cdada5bd7310df4d0e026d9d227") + depends_on("cxx", type="build") # generated + # gearshifft used the variable name `CMAKE_DEFAULT_BUILD_TYPE` which was # later introduced by CMake leading to an error in newer CMake versions. # This patch renames the variable to `GEARSHIFFT_DEFAULT_BUILD_TYPE`. diff --git a/var/spack/repos/builtin/packages/gegelati/package.py b/var/spack/repos/builtin/packages/gegelati/package.py index 4558126bb12674..6f5226a325bfef 100644 --- a/var/spack/repos/builtin/packages/gegelati/package.py +++ b/var/spack/repos/builtin/packages/gegelati/package.py @@ -19,6 +19,9 @@ class Gegelati(CMakePackage): version("1.2.0", sha256="039997c7d6cb394f910f6c40620165b32094e0c85c170be01eb74b55488a1d4c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("sdl2") depends_on("doxygen") diff --git a/var/spack/repos/builtin/packages/gegl/package.py b/var/spack/repos/builtin/packages/gegl/package.py index 7005968e7d671a..d969ef3ceabd21 100644 --- a/var/spack/repos/builtin/packages/gegl/package.py +++ b/var/spack/repos/builtin/packages/gegl/package.py @@ -28,6 +28,9 @@ class Gegl(MesonPackage): version("0.4.34", sha256="ef63f0bca5b431c6119addd834ca7fbb507c900c4861c57b3667b6f4ccfcaaaa") version("0.4.32", sha256="668e3c6b9faf75fb00512701c36274ab6f22a8ba05ec62dbf187d34b8d298fa1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("cmake@3.4:", type="build") depends_on("babl") diff --git a/var/spack/repos/builtin/packages/gemma/package.py b/var/spack/repos/builtin/packages/gemma/package.py index 6a43842e0fd930..c144364d9e068a 100644 --- a/var/spack/repos/builtin/packages/gemma/package.py +++ b/var/spack/repos/builtin/packages/gemma/package.py @@ -20,6 +20,8 @@ class Gemma(MakefilePackage): version("0.98.5", sha256="3ed336deee29e370f96ec8f1a240f7b62550e57dcd1694245ce7ec8f42241677") + depends_on("cxx", type="build") # generated + depends_on("zlib-api") # openblas is the default # other lapack implementors can be made to work diff --git a/var/spack/repos/builtin/packages/gemmlowp/package.py b/var/spack/repos/builtin/packages/gemmlowp/package.py index cb56090e2e332a..e77e689b980149 100644 --- a/var/spack/repos/builtin/packages/gemmlowp/package.py +++ b/var/spack/repos/builtin/packages/gemmlowp/package.py @@ -16,6 +16,8 @@ class Gemmlowp(Package): version("a6f29d9ac", commit="a6f29d8ac48d63293f845f2253eccbf86bc28321") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): header_directories = ( "eight_bit_int_gemm", diff --git a/var/spack/repos/builtin/packages/generate-ninja/package.py b/var/spack/repos/builtin/packages/generate-ninja/package.py new file mode 100644 index 00000000000000..408152abc0a37d --- /dev/null +++ b/var/spack/repos/builtin/packages/generate-ninja/package.py @@ -0,0 +1,50 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class GenerateNinja(Package): + """ + A meta-build system that generates build files for Ninja. + This is a fork of the Google GN package with some minor features and bug fixes + """ + + homepage = "https://github.com/o-lim/generate-ninja" + url = "https://github.com/o-lim/generate-ninja/archive/refs/tags/v0.4.1.tar.gz" + + license("BSD", checked_by="teaguesterling") + + version("0.4.1", sha256="1b2bec9dd18602a4af9dc8782ca809e44305f1435d43c55f35ec9eec50ca7e9a") + version("0.4.0", sha256="3575ed41eec49fe756dbd2c402f70cd80ba2952cc59ce2091d0a82b7bd3ce8a0") + version("0.3.2", sha256="82e949c3970d77b28c9df7cf3f3df409798b65848e05ff415009e7e2118460a8") + version("0.3.1", sha256="ed0112b434b80c322fcc9203646eaef17c306a804bf2ff5e5df91677c4e58678") + version("0.3.0", sha256="e6091d34cfc6bc625bfad4bbdc001e10ed951651d0ae98785b509bdfadad6822") + version("0.2.2", sha256="3146bdef1db9dfdc2d48bb5ee5e8e4ef9642ebea7cf39c432681685db8a11c86") + version("0.2.1", sha256="bf27ddde69bd0791ce86bd3ab9ead51dcfb00d3f202168057b721fdc39d417c5") + version("0.2.0", sha256="6cfd6f4a2f6d656e8d5f64d7f03a575a569b2c0f662d1d828ee790c9d9c2be25") + version("0.1.0", sha256="eb94e0bb170416010d3efa296fce63e7fec19f1e3e9b5988b2418166ec068896") + + depends_on("ninja") + depends_on("python", type="build") + depends_on("llvm+clang", type="build") + + def setup_build_environment(self, env): + env.set("DEPLOY", "1") + env.set("CC", self.spec["llvm"].home.bin.clang) + env.set("CXX", self.spec["llvm"].home.bin.join("clang++")) + + phases = ["configure", "build", "install"] + # build_targets = ["bootstrap", "gn"] + out_dir = "out" + + def configure(self, spec, prefix): + python("build/gen.py") + + def build(self, spec, prefix): + ninja("-C", self.out_dir) + + def install(self, spec, prefix): + mkdir(prefix.bin) + install(join_path(self.out_dir, "gn"), prefix.bin.gn) diff --git a/var/spack/repos/builtin/packages/generax/package.py b/var/spack/repos/builtin/packages/generax/package.py index ef52f73e5b884b..74e0b1ec2efa66 100644 --- a/var/spack/repos/builtin/packages/generax/package.py +++ b/var/spack/repos/builtin/packages/generax/package.py @@ -24,6 +24,9 @@ class Generax(CMakePackage): version("2.0.4", commit="e4fab40f407bdd3b588d3d69a449f8c1be56f9fa", submodules=True) version("2.0.1", commit="0623dae55dd602a60faae63e9991fa8d41782456", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.0.1:", type="build") depends_on("mpi", when="+mpi") depends_on("bison") diff --git a/var/spack/repos/builtin/packages/genesis/package.py b/var/spack/repos/builtin/packages/genesis/package.py index 485693084f50c0..4ff56e4be14324 100644 --- a/var/spack/repos/builtin/packages/genesis/package.py +++ b/var/spack/repos/builtin/packages/genesis/package.py @@ -30,6 +30,9 @@ class Genesis(AutotoolsPackage, CudaPackage): url="https://www.r-ccs.riken.jp/labs/cbrt/wp-content/uploads/2020/09/genesis-1.5.1.tar.bz2", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + resource( when="@1.6.0", name="user_guide", diff --git a/var/spack/repos/builtin/packages/genfit/package.py b/var/spack/repos/builtin/packages/genfit/package.py index c4e7f4b4417f01..dad4a85e7b7d1b 100644 --- a/var/spack/repos/builtin/packages/genfit/package.py +++ b/var/spack/repos/builtin/packages/genfit/package.py @@ -30,6 +30,8 @@ class Genfit(CMakePackage): # Untagged version from 2017-06-23 known to work with root@6.16.00 version("b496504a", sha256="e1582b35782118ade08498adc03f3fda01979ff8bed61e0520edae46d7bfe477") + depends_on("cxx", type="build") # generated + depends_on("root") depends_on("root@:6.16.00", when="@b496504a") depends_on("eigen") diff --git a/var/spack/repos/builtin/packages/gengeo/package.py b/var/spack/repos/builtin/packages/gengeo/package.py index 6c0f3c6be25338..a580a7aa90c5e5 100644 --- a/var/spack/repos/builtin/packages/gengeo/package.py +++ b/var/spack/repos/builtin/packages/gengeo/package.py @@ -23,6 +23,8 @@ class Gengeo(AutotoolsPackage): version("163", sha256="9c896d430d8f315a45379d2b82e7d374f36259af66a745bfdee4c022a080d34d") + depends_on("cxx", type="build") # generated + extends("python") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/gengetopt/package.py b/var/spack/repos/builtin/packages/gengetopt/package.py index b445d8b23aafab..ed184b6d5b6e31 100644 --- a/var/spack/repos/builtin/packages/gengetopt/package.py +++ b/var/spack/repos/builtin/packages/gengetopt/package.py @@ -27,6 +27,9 @@ class Gengetopt(AutotoolsPackage): version("2.21", sha256="355a32310b2fee5e7289d6d6e89eddd13275a7c85a243dc5dd293a6cb5bb047e") version("2.20", sha256="4c8b3b42cecff579f5f9de5ccad47e0849e0245e325a04ff5985c248141af1a4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("texinfo", type="build") parallel = False diff --git a/var/spack/repos/builtin/packages/genie/package.py b/var/spack/repos/builtin/packages/genie/package.py index e7abda341b103c..a962862707ee0a 100644 --- a/var/spack/repos/builtin/packages/genie/package.py +++ b/var/spack/repos/builtin/packages/genie/package.py @@ -43,6 +43,8 @@ class Genie(Package): version("2.9.0", sha256="8229beb73f65f5af86a77bf141acfbe4a8b68cba9d797aae083a929906f6f2a2") version("2.8.6", sha256="310dc8e0d17a65e6b9773e398250703a3a6f94ceafe94f599ae0f7b3fecf7e6c") + depends_on("cxx", type="build") # generated + depends_on("root+pythia6") depends_on("pythia6") depends_on("lhapdf", when="@3:") diff --git a/var/spack/repos/builtin/packages/genometools/package.py b/var/spack/repos/builtin/packages/genometools/package.py index 7a3d299e2aee5d..69cbd3cea323f5 100644 --- a/var/spack/repos/builtin/packages/genometools/package.py +++ b/var/spack/repos/builtin/packages/genometools/package.py @@ -15,10 +15,14 @@ class Genometools(MakefilePackage): license("BSD-2-Clause") + version("1.6.5", sha256="f71b95c84761847223cd52a17d30ad9e6d55854448c2139fcd0aac437f73fbbe") version("1.6.2", sha256="974825ddc42602bdce3d5fbe2b6e2726e7a35e81b532a0dc236f6e375d18adac") version("1.6.1", sha256="528ca143a7f1d42af8614d60ea1e5518012913a23526d82e434f0dad2e2d863f") version("1.5.9", sha256="bba8e043f097e7c72e823f73cb0efbd20bbd60f1ce797a0e4c0ab632b170c909") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl", type=("build", "run")) depends_on("cairo+pdf") depends_on("pango") @@ -29,7 +33,7 @@ class Genometools(MakefilePackage): patch("signed.patch", when="%fj") def install(self, spec, prefix): - make("install", "prefix=%s" % prefix) + make("install", f"prefix={prefix}") def setup_dependent_build_environment(self, env, dependent_spec): env.set("CPATH", self.prefix.include.genometools) diff --git a/var/spack/repos/builtin/packages/genomeworks/package.py b/var/spack/repos/builtin/packages/genomeworks/package.py index 59622cd79cdd38..5c8263440d64df 100644 --- a/var/spack/repos/builtin/packages/genomeworks/package.py +++ b/var/spack/repos/builtin/packages/genomeworks/package.py @@ -43,6 +43,9 @@ class Genomeworks(CMakePackage, CudaPackage): "0.2.0", tag="v0.2.0", commit="416af9f1817a4a70745b3f7cdb7418125159f75c", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.10.2:", type=("build")) depends_on("cuda@11:", type=("build", "run")) depends_on("python@3.6.7:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/genrich/package.py b/var/spack/repos/builtin/packages/genrich/package.py index b36c194c921d61..6ddee5019d3ac9 100644 --- a/var/spack/repos/builtin/packages/genrich/package.py +++ b/var/spack/repos/builtin/packages/genrich/package.py @@ -17,6 +17,8 @@ class Genrich(MakefilePackage): version("0.6.1", sha256="2c70239e1caf33519b9e99142470bb4dd2f4c69e71f68cee33d6d6a1032d0e33") version("0.6", sha256="4c87aca8b7789f28b0c5c2c0ccea75668f19fa6a4cb38cd3c06d80ffd98d396f") + depends_on("c", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/geoip-api-c/package.py b/var/spack/repos/builtin/packages/geoip-api-c/package.py index d7d1dc52934b36..b971d4be00b98e 100644 --- a/var/spack/repos/builtin/packages/geoip-api-c/package.py +++ b/var/spack/repos/builtin/packages/geoip-api-c/package.py @@ -19,6 +19,8 @@ class GeoipApiC(AutotoolsPackage): version("1.6.11", sha256="b0e5a92200b5ab540d118983f7b7191caf4faf1ae879c44afa3ff2a2abcdb0f5") version("1.6.10", sha256="cb44e0d0dbc45efe2e399e695864e58237ce00026fba8a74b31d85888c89c67a") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/geoip/package.py b/var/spack/repos/builtin/packages/geoip/package.py index 2e3b02833882b3..525ad60cbf7743 100644 --- a/var/spack/repos/builtin/packages/geoip/package.py +++ b/var/spack/repos/builtin/packages/geoip/package.py @@ -18,3 +18,5 @@ class Geoip(AutotoolsPackage): version("1.6.12", sha256="1dfb748003c5e4b7fd56ba8c4cd786633d5d6f409547584f6910398389636f80") version("1.6.11", sha256="b0e5a92200b5ab540d118983f7b7191caf4faf1ae879c44afa3ff2a2abcdb0f5") version("1.6.10", sha256="cb44e0d0dbc45efe2e399e695864e58237ce00026fba8a74b31d85888c89c67a") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/geomodel/package.py b/var/spack/repos/builtin/packages/geomodel/package.py new file mode 100644 index 00000000000000..80027510041f17 --- /dev/null +++ b/var/spack/repos/builtin/packages/geomodel/package.py @@ -0,0 +1,77 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Geomodel(CMakePackage): + """GeoModel is a user-friendly C++ Toolkit and Suite for + HEP Detector Description with minimal dependencies.""" + + homepage = "https://gitlab.cern.ch/GeoModelDev/GeoModel" + url = "https://gitlab.cern.ch/GeoModelDev/GeoModel/-/archive/4.6.0/GeoModel-4.6.0.tar.bz2" + git = "https://gitlab.cern.ch/GeoModelDev/GeoModel" + + maintainers("wdconinc") + + license("Apache-2.0", checked_by="wdconinc") + + version("4.6.0", sha256="d827dc79a5555fd7b09d1b670fc6f01f91476d0edf98ccd644c624f18fb729ca") + + depends_on("cxx", type="build") # generated + + variant( + "visualization", default=False, description="Enable the build of GeoModelVisualization" + ) + variant("geomodelg4", default=False, description="Enable the build of GeoModelG4") + variant("fullsimlight", default=False, description="Enable the build of FullSimLight") + variant("fsl", default=False, description="Enable the build of FSL and FullSimLight") + variant("examples", default=False, description="Enable the build of GeoModelExamples") + variant("tools", default=False, description="Enable the build of GeoModelTools") + variant( + "hepmc3", + default=False, + description="Build GeoModel tools with support for the HepMC3 exchange format", + when="+fullsimlight", + ) + variant( + "pythia", + default=False, + description="Build GeoModel tools with support for the Pythia event generator", + when="+fullsimlight", + ) + + conflicts("+fullsimlight", when="+fsl", msg="FSL triggers the build of the FullSimLight") + + depends_on("cmake@3.16:", type="build") + + depends_on("eigen@3.2.9:") + depends_on("nlohmann-json@3.6.1:") + depends_on("sqlite@3.7.17:") + depends_on("xerces-c@3.2.3:") + + depends_on("geant4", when="+geomodelg4") + depends_on("geant4", when="+fullsimlight") + depends_on("hepmc3", when="+hepmc3") + depends_on("pythia8", when="+pythia") + with when("+visualization"): + depends_on("hdf5") + depends_on("qt-base +gui +opengl +sql +widgets") + depends_on("opengl") + + def cmake_args(self): + def cmake_variant(cmake_label, spack_variant): + enabled = spec.satisfies("+" + spack_variant) + return f"-DGEOMODEL_BUILD_{cmake_label}={enabled}" + + args = [ + cmake_variant("VISUALIZATION", "visualization"), + cmake_variant("GEOMODELG4", "geomodelg4"), + cmake_variant("FULLSIMLIGHT", "fullsimlight"), + cmake_variant("FSL", "fsl"), + cmake_variant("EXAMPLES", "examples"), + cmake_variant("TOOLS", "tools"), + ] + return args diff --git a/var/spack/repos/builtin/packages/geopm-runtime/package.py b/var/spack/repos/builtin/packages/geopm-runtime/package.py new file mode 100644 index 00000000000000..974daed7d04737 --- /dev/null +++ b/var/spack/repos/builtin/packages/geopm-runtime/package.py @@ -0,0 +1,167 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + + +class GeopmRuntime(AutotoolsPackage): + """The Global Extensible Open Power Manager (GEOPM) Runtime is designed to + enhance energy efficiency of applications through active hardware + configuration.""" + + homepage = "https://geopm.github.io" + git = "https://github.com/geopm/geopm.git" + url = "https://github.com/geopm/geopm/tarball/v3.1.0" + + maintainers("bgeltz", "cmcantalupo") + license("BSD-3-Clause") + tags = ["e4s"] + + version("develop", branch="dev", get_full_repo=True) + version("3.1.0", sha256="2d890cad906fd2008dc57f4e06537695d4a027e1dc1ed92feed4d81bb1a1449e") + version("3.0.1", sha256="32ba1948de58815ee055470dcdea64593d1113a6cad70ce00ab0286c127f8234") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("debug", default=False, description="Enable debug") + variant("docs", default=False, when="@3.0.1", description="Create man pages with Sphinx") + variant("overhead", default=False, description="Track time spent in GEOPM API calls") + variant("beta", default=False, description="Enable beta features") + variant("mpi", default=True, description="Enable MPI dependent components") + variant("fortran", default=True, description="Build fortran interface") + variant("openmp", default=True, description="Build with OpenMP") + variant("ompt", default=True, description="Use OpenMP Tools Interface") + variant("gnu-ld", default=False, description="Assume C compiler uses gnu-ld") + variant("intel-mkl", default=True, description="Build with Intel MKL support") + variant( + "checkprogs", + default=False, + description='Build tests (use with "devbuild" or "install --keep-stage")', + ) + + conflicts("%gcc@:7.2", msg="Requires C++17 support") + conflicts("%clang@:4", msg="Requires C++17 support") + conflicts("%gcc", when="+ompt") + + conflicts("platform=darwin", msg="Darwin is not supported") + conflicts("platform=windows", msg="Windows is not supported") + + conflicts("target=aarch64:", msg="Only available on x86_64", when="@3.0.1") + conflicts("target=ppc64:", msg="Only available on x86_64", when="@3.0.1") + conflicts("target=ppc64le:", msg="Only available on x86_64", when="@3.0.1") + + # Autotools dependencies + depends_on("automake", type="build") + depends_on("libtool", type="build") + depends_on("file") + + with when("@3.0.1"): + # Docs dependencies + # Moved to python3-geopm-doc as of v3.1 + depends_on("doxygen", type="build", when="+docs") + depends_on("py-sphinx", type="build", when="+docs") + depends_on("py-sphinx-rtd-theme@1:", type="build", when="+docs") + depends_on("py-sphinxemoji@0.2.0:", type="build", when="+docs") + depends_on("py-sphinx-tabs@3.3.1:", type="build", when="+docs") + depends_on("py-pygments@2.13.0:", type="build", when="+docs") + + # Other Python dependencies - from scripts/setup.py + # Moved to python3-geopmdpy as of v3.1 + depends_on("python@3.6:3", type=("build", "run")) + depends_on("py-setuptools@53.0.0:", type="build") + depends_on("py-cffi@1.14.5:", type="run") + depends_on("py-natsort@8.2.0:", type="run") + depends_on("py-numpy@1.19.5:", type="run") + depends_on("py-pandas@1.1.5:", type="run") + depends_on("py-tables@3.7.0:", type="run") + depends_on("py-psutil@5.8.0:", type="run") + depends_on("py-pyyaml@6.0:", type="run") + depends_on("py-docutils@0.18:", type="run", when="+checkprogs") + + # Other dependencies + for ver in ["3.0.1", "3.1.0", "develop"]: + depends_on(f"geopm-service@{ver}", type=("build", "run"), when=f"@{ver}") + depends_on(f"py-geopmdpy@{ver}", type="run", when=f"@{ver}") + if ver != "3.0.1": # geopmpy integrated into autotools build until 3.1 + depends_on(f"py-geopmpy@{ver}", type="run", when=f"@{ver}") + depends_on("py-setuptools-scm@7.0.3:", when="@3.1:", type="build") + depends_on("bash-completion") + depends_on("unzip") + depends_on("mpi@2.2:", when="+mpi") + depends_on("libelf") + depends_on("numactl", type="run", when="+checkprogs") + depends_on("stress-ng", type="run", when="+checkprogs") + + # Intel dependencies + depends_on("intel-oneapi-mkl%oneapi", when="+intel-mkl") + + extends("python") + + @property + def configure_directory(self): + if self.version == Version("3.0.1"): + return "." + else: + return "libgeopm" + + @property + def install_targets(self): + target = ["install"] + if "+checkprogs" in self.spec: + target += ["checkprogs"] + return target + + def autoreconf(self, spec, prefix): + bash = which("bash") + with working_dir(self.configure_directory): + if not spec.version.isdevelop(): + if self.version == Version("3.0.1"): + version_file = "VERSION_OVERRIDE" + else: + version_file = "VERSION" + # Required to workaround missing VERSION files + # from GitHub generated source tarballs + with open(version_file, "w") as fd: + fd.write(f"{spec.version}") + bash("./autogen.sh") + + def configure_args(self): + + with when("@3.0.1"): + args = [ + "--with-bash-completion-dir=" + + join_path(self.spec.prefix, "share", "bash-completion", "completions") + ] + args += ["--disable-geopmd-local", f"--with-geopmd={self.spec['geopm-service'].prefix}"] + + args += self.enable_or_disable("debug") + args += self.enable_or_disable("docs") + args += self.enable_or_disable("overhead") + args += self.enable_or_disable("beta") + args += self.enable_or_disable("mpi") + args += self.enable_or_disable("fortran") + args += self.enable_or_disable("openmp") + args += self.enable_or_disable("ompt") + args += self.with_or_without("gnu-ld") + + return args + + def setup_run_environment(self, env): + # Required to ensure libgeopm.so + # can be used with LD_PRELOAD + if os.path.isdir(self.prefix.lib64): + lib_dir = self.prefix.lib64 + else: + lib_dir = self.prefix.lib + env.prepend_path("LD_LIBRARY_PATH", lib_dir) + + if "+checkprogs" in self.spec: + env.set("GEOPM_SOURCE", self.stage.source_path) + env.prepend_path("PYTHONPATH", self.stage.source_path) + env.set("GEOPM_INSTALL", self.prefix) diff --git a/var/spack/repos/builtin/packages/geopm-service/package.py b/var/spack/repos/builtin/packages/geopm-service/package.py index 78945ef536e704..54aa00e6b14494 100644 --- a/var/spack/repos/builtin/packages/geopm-service/package.py +++ b/var/spack/repos/builtin/packages/geopm-service/package.py @@ -9,14 +9,8 @@ class GeopmService(AutotoolsPackage): - """The Global Extensible Open Power Manager (GEOPM) is a framework for - exploring power and energy optimizations targeting heterogeneous platforms. - The GEOPM package provides many built-in features. A simple use case is - reading hardware counters and setting hardware controls with platform - independent syntax using a command line tool on a particular compute node. - An advanced use case is dynamically coordinating hardware settings across - all compute nodes used by a distributed application is response to the - application's behavior and requests from the resource manager. + """The Global Extensible Open Power Manager (GEOPM) Service provides a + user interface for accessing hardware telemetry and settings securely. Note: GEOPM interfaces with hardware using Model Specific Registers (MSRs). For proper usage make sure MSRs are made available via the msr or @@ -24,22 +18,23 @@ class GeopmService(AutotoolsPackage): homepage = "https://geopm.github.io" git = "https://github.com/geopm/geopm.git" - url = "https://github.com/geopm/geopm/tarball/v3.0.1" + url = "https://github.com/geopm/geopm/tarball/v3.1.0" maintainers("bgeltz", "cmcantalupo") license("BSD-3-Clause") tags = ["e4s"] version("develop", branch="dev", get_full_repo=True) + version("3.1.0", sha256="2d890cad906fd2008dc57f4e06537695d4a027e1dc1ed92feed4d81bb1a1449e") version("3.0.1", sha256="32ba1948de58815ee055470dcdea64593d1113a6cad70ce00ab0286c127f8234") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("debug", default=False, description="Enable debug") - variant("docs", default=True, description="Create man pages with Sphinx") - variant( - "systemd", - default=False, - description="Enable use of systemd (systemd development libraries required)", - ) + variant("docs", default=True, when="@3.0.1", description="Create man pages with Sphinx") + variant("systemd", default=True, description="Enable use of systemd/DBus") variant("liburing", default=True, description="Enables the use of liburing for batch I/O") variant( "libcap", default=True, description="Enables the use of libcap to do capabilities checks" @@ -64,9 +59,9 @@ class GeopmService(AutotoolsPackage): conflicts("platform=darwin", msg="Darwin is not supported") conflicts("platform=windows", msg="Windows is not supported") - conflicts("target=aarch64:", msg="Only available on x86_64") - conflicts("target=ppc64:", msg="Only available on x86_64") - conflicts("target=ppc64le:", msg="Only available on x86_64") + conflicts("target=aarch64:", msg="Only available on x86_64", when="@3.0.1") + conflicts("target=ppc64:", msg="Only available on x86_64", when="@3.0.1") + conflicts("target=ppc64le:", msg="Only available on x86_64", when="@3.0.1") patch("0001-Support-NVML-via-CUDA-installation.patch", when="+nvml") @@ -75,26 +70,33 @@ class GeopmService(AutotoolsPackage): depends_on("libtool", type="build") depends_on("file") - # Docs dependencies - depends_on("doxygen", type="build", when="+docs") - depends_on("py-docstring-parser@0.13.0:", type="build", when="+docs") - depends_on("py-sphinx@4.5:", type="build", when="+docs") - depends_on("py-sphinx-rtd-theme@1:", type="build", when="+docs") - depends_on("py-sphinxemoji@0.2.0:", type="build", when="+docs") - depends_on("py-sphinx-tabs@3.3.1:", type="build", when="+docs") - depends_on("py-pygments@2.13.0:", type="build", when="+docs") - - # Other Python dependencies - from service/setup.py - depends_on("py-dasbus@1.6.0:", type=("build", "run")) - depends_on("py-cffi@1.14.5:", type="run") - depends_on("py-psutil@5.8.0:", type="run") - depends_on("py-jsonschema@3.2.0:", type="run") - depends_on("py-pyyaml@6.0:", type="run") - depends_on("py-setuptools@53.0.0:", type="build") + with when("@3.0.1"): + # Docs dependencies + # Moved to python3-geopm-doc as of v3.1 + depends_on("doxygen", type="build", when="+docs") + depends_on("py-docstring-parser@0.13.0:", type="build", when="+docs") + depends_on("py-sphinx", type="build", when="+docs") + depends_on("py-sphinx-rtd-theme@1:", type="build", when="+docs") + depends_on("py-sphinxemoji@0.2.0:", type="build", when="+docs") + depends_on("py-sphinx-tabs@3.3.1:", type="build", when="+docs") + depends_on("py-pygments@2.13.0:", type="build", when="+docs") + + # Other Python dependencies - from service/setup.py + # Moved to python3-geopmdpy as of v3.1 + depends_on("py-setuptools@53.0.0:", type="build") + depends_on("py-dasbus@1.6.0:", type=("build", "run")) + depends_on("py-psutil@5.8.0:", type=("build", "run")) + depends_on("py-jsonschema@3.2.0:", type=("build", "run")) + depends_on("py-pyyaml@6.0:", type=("build", "run")) + depends_on("py-cffi@1.14.5:", type="run") # Other dependencies + for ver in ["3.1.0", "develop"]: + depends_on(f"py-geopmdpy@{ver}", type="run", when=f"@{ver}") + depends_on("py-setuptools-scm@7.0.3:", when="@3.1:", type="build") depends_on("bash-completion") depends_on("unzip") + depends_on("systemd", when="+systemd") depends_on("libcap", when="+libcap") depends_on("liburing", when="+liburing") depends_on("oneapi-level-zero", when="+levelzero") @@ -102,15 +104,24 @@ class GeopmService(AutotoolsPackage): extends("python") - configure_directory = "service" + @property + def configure_directory(self): + if self.version == Version("3.0.1"): + return "service" + else: + return "libgeopmd" def autoreconf(self, spec, prefix): bash = which("bash") - with working_dir("service"): + with working_dir(self.configure_directory): if not spec.version.isdevelop(): + if self.version == Version("3.0.1"): + version_file = "VERSION_OVERRIDE" + else: + version_file = "VERSION" # Required to workaround missing VERSION files # from GitHub generated source tarballs - with open("VERSION_OVERRIDE", "w") as fd: + with open(version_file, "w") as fd: fd.write(f"{spec.version}") bash("./autogen.sh") @@ -132,10 +143,16 @@ def configure_args(self): args += self.enable_or_disable("nvml") if "+nvml" in self.spec: args += [ - "--with-nvml=" + join_path(self.spec["cuda"].prefix, "targets", "x86_64-linux") + "--with-nvml=" + + join_path( + self.spec["cuda"].prefix, "targets", f"{self.spec.target.family}-linux" + ) ] args += self.enable_or_disable("rawmsr") + with when("@develop"): + if self.spec.target.family != "x86_64": + args += ["--disable-cpuid"] return args def setup_run_environment(self, env): diff --git a/var/spack/repos/builtin/packages/geopm/package.py b/var/spack/repos/builtin/packages/geopm/package.py deleted file mode 100644 index 75e19e2f5da8e3..00000000000000 --- a/var/spack/repos/builtin/packages/geopm/package.py +++ /dev/null @@ -1,142 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -from spack.package import * - - -class Geopm(AutotoolsPackage): - """GEOPM is an extensible power management framework targeting HPC. - The GEOPM package provides libgeopm, libgeopmpolicy and applications - geopmctl and geopmpolicy, as well as tools for postprocessing. - GEOPM is designed to be extended for new control algorithms and new - hardware power management features via its plugin infrastructure. - - Note: GEOPM interfaces with hardware using Model Specific Registers (MSRs). - For propper usage make sure MSRs are made available directly or via the - msr-safe kernel module by your administrator.""" - - homepage = "https://geopm.github.io" - url = "https://github.com/geopm/geopm/releases/download/v1.0.0/geopm-1.0.0.tar.gz" - git = "https://github.com/geopm/geopm.git" - - tags = ["e4s"] - - license("BSD-3-Clause") - - # Add additional proper versions and checksums here. "spack checksum geopm" - version("develop", branch="dev", deprecated=True) - version("master", branch="master", deprecated=True) - version( - "1.1.0", - sha256="5f9a4df37ef0d64c53d64829d46736803c9fe614afd8d2c70fe7a5ebea09f88e", - deprecated=True, - ) - version( - "1.0.0", - sha256="24fe72265a7e44d62bdfe49467c49f0b7a649131ddda402d763c00a49765e1cb", - deprecated=True, - ) - version( - "0.6.1", - sha256="0ca42853f90885bf213df190c3462b8675c143cc843aee0d8b8a0e30802b55a9", - deprecated=True, - ) - version( - "0.6.0", - sha256="95ccf256c2b7cb35838978152479569d154347c3065af1639ed17be1399182d3", - deprecated=True, - ) - version( - "0.5.1", - sha256="db247af55f7000b6e4628af099956349b68a637500b9d4fe8d8fb13687124d53", - deprecated=True, - ) - version( - "0.5.0", - sha256="cdc123ea68b6d918dcc578a39a7a38275a5d711104364eb889abed15029f4060", - deprecated=True, - ) - version( - "0.4.0", - sha256="7d165f5a5fe0f19ca586bd81a4631202effb542e9d762cc9cc86ad6ef7afcad9", - deprecated=True, - ) - version( - "0.3.0", - sha256="73b45d36e7d2431d308038fc8c50a521a1d214c5ce105a17fba440f28509d907", - deprecated=True, - ) - - # Variants reflecting most ./configure --help options - variant("debug", default=False, description="Enable debug.") - variant( - "coverage", - default=False, - description="Enable test coverage support, enables debug by default.", - ) - variant( - "overhead", - default=False, - description="Enable GEOPM to calculate and display time spent in GEOPM API calls.", - ) - variant( - "procfs", default=True, description="Enable procfs (disable for OSes not using procfs)." - ) - variant("mpi", default=True, description="Enable MPI dependent components.") - variant("fortran", default=True, description="Build fortran interface.") - variant("doc", default=True, description="Create man pages with ruby-ronn.") - variant("openmp", default=True, description="Build with OpenMP.") - variant("ompt", default=False, description="Use OpenMP Tools Interface.") - variant("gnu-ld", default=False, description="Assume C compiler uses gnu-ld.") - - # Added dependencies. - depends_on("ruby-ronn", type="build", when="+doc") - depends_on("doxygen", type="build", when="+doc") - depends_on("mpi@2.2:", when="+mpi") - - depends_on("m4", type="build") - depends_on("autoconf", type="build") - depends_on("automake", type="build") - depends_on("libtool", type="build") - depends_on("ruby-ronn", type="build", when="+doc") - depends_on("doxygen", type="build", when="+doc") - depends_on("numactl", when="@:1.0.0-rc2") - depends_on("mpi", when="+mpi") - depends_on("hwloc@1.11.9", when="@:0.5.1") - depends_on("json-c", when="@:0.9.9") - depends_on("py-cycler@0.10.0:", when="@1.0.0:", type=("build", "run")) - depends_on("py-pandas@0.22.0:", type=("build", "run")) - depends_on("py-tables@3.4.3:", when="@1.0.0:", type=("build", "run")) - depends_on("py-cffi@1.6.0:", when="@1.1.0:", type=("build", "run")) - depends_on("py-pyyaml@5.1.0:", when="@1.1.0:", type=("build", "run")) - depends_on("py-mock@3.0.0:", when="@1.1.0:", type=("build", "run")) - depends_on("py-future@0.17.1:", when="@1.1.0:", type=("build", "run")) - depends_on("py-numpy@1.14.3:", type=("build", "run")) - depends_on("py-setuptools@39.2.0:", when="@1.0.0:", type="build") - depends_on("py-natsort@5.3.2:", type=("build", "run")) - depends_on("py-psutil@5.4.8:", when="@1.0.0:", type=("build", "run")) - depends_on("py-pylint@1.9.5:", when="@1.1.0:", type=("build", "run")) - depends_on("py-matplotlib@2.2.3", when="@:1.0.0-rc2", type=("build", "run")) - depends_on("py-matplotlib@2.2.3:", when="@1.1.0:", type=("build", "run")) - - parallel = False - - def autoreconf(self, spec, prefix): - bash = which("bash") - bash("./autogen.sh") - - def configure_args(self): - args = [] - args.extend(self.enable_or_disable("debug")) - args.extend(self.enable_or_disable("coverage")) - args.extend(self.enable_or_disable("overhead")) - args.extend(self.enable_or_disable("procfs")) - args.extend(self.enable_or_disable("mpi")) - args.extend(self.enable_or_disable("fortran")) - args.extend(self.enable_or_disable("doc")) - args.extend(self.enable_or_disable("openmp")) - args.extend(self.enable_or_disable("ompt")) - args.extend(self.with_or_without("gnu-ld")) - - return args diff --git a/var/spack/repos/builtin/packages/geos/package.py b/var/spack/repos/builtin/packages/geos/package.py index ae859c85b079fd..d84f45d3c2798d 100644 --- a/var/spack/repos/builtin/packages/geos/package.py +++ b/var/spack/repos/builtin/packages/geos/package.py @@ -19,12 +19,13 @@ class Geos(CMakePackage): url = "https://download.osgeo.org/geos/geos-3.8.1.tar.bz2" git = "https://github.com/libgeos/geos.git" - maintainers("adamjstewart") - license("LGPL-2.1-or-later") + maintainers("adamjstewart") + version("3.12.2", sha256="34c7770bf0090ee88488af98767d08e779f124fa33437e0aabec8abd4609fec6") version("3.12.1", sha256="d6ea7e492224b51193e8244fe3ec17c4d44d0777f3c32ca4fb171140549a0d03") version("3.12.0", sha256="d96db96011259178a35555a0f6d6e75a739e52a495a6b2aa5efb3d75390fbc39") + version("3.11.4", sha256="364c88ccfc38aa50cf65c700e7b2ae4706ed103326128493dbf750c78d136d2c") version("3.11.3", sha256="80d60a2bbc0cde7745a3366b9eb8c0d65a142b03e063ea0a52c364758cd5ee89") version("3.11.2", sha256="b1f077669481c5a3e62affc49e96eb06f281987a5d36fdab225217e5b825e4cc") version("3.11.1", sha256="6d0eb3cfa9f92d947731cc75f1750356b3bdfc07ea020553daf6af1c768e0be2") @@ -65,6 +66,9 @@ class Geos(CMakePackage): version("3.3.4", sha256="cd5400aa5f3fe32246dfed5d238c5017e1808162c865c016480b3e6c07271904") version("3.3.3", sha256="dfcf4bd70ab212a5b7bad21d01b84748f101a545092b56dafdc3882ef3bddec9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@3.13:", when="@3.10:", type="build") depends_on("cmake@3.8:", type="build") diff --git a/var/spack/repos/builtin/packages/gettext/package.py b/var/spack/repos/builtin/packages/gettext/package.py index 0c600821dcb77a..c6c8da89a89586 100644 --- a/var/spack/repos/builtin/packages/gettext/package.py +++ b/var/spack/repos/builtin/packages/gettext/package.py @@ -6,7 +6,6 @@ import re from spack.package import * -from spack.util.environment import is_system_path class Gettext(AutotoolsPackage, GNUMirrorPackage): @@ -22,6 +21,7 @@ class Gettext(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-or-later AND LGPL-2.1-or-later AND MIT") + version("0.22.5", sha256="fe10c37353213d78a5b83d48af231e005c4da84db5ce88037d88355938259640") version("0.22.4", sha256="29217f1816ee2e777fa9a01f9956a14139c0c23cc1b20368f06b2888e8a34116") version("0.22.3", sha256="b838228b3f8823a6c1eddf07297197c4db13f7e1b173b9ef93f3f945a63080b6") version("0.21.1", sha256="50dbc8f39797950aa2c98e939947c527e5ac9ebd2c1b99dd7b06ba33a6767ae6") @@ -31,6 +31,9 @@ class Gettext(AutotoolsPackage, GNUMirrorPackage): version("0.19.8.1", sha256="105556dbc5c3fbbc2aa0edb46d22d055748b6f5c7cd7a8d99f8e7eb84e938be4") version("0.19.7", sha256="378fa86a091cec3acdece3c961bb8d8c0689906287809a8daa79dc0c6398d934") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Recommended variants variant("curses", default=True, description="Use libncurses") variant("libxml2", default=True, description="Use libxml2") @@ -50,7 +53,7 @@ class Gettext(AutotoolsPackage, GNUMirrorPackage): depends_on("libxml2", when="+libxml2") # Java runtime and compiler (e.g. GNU gcj or kaffe) # C# runtime and compiler (e.g. pnet or mono) - depends_on("tar", when="+tar") + depends_on("tar", when="+tar", type="run") # depends_on('gzip', when='+gzip') depends_on("bzip2", when="+bzip2") depends_on("xz", when="+xz", type=("build", "link", "run")) @@ -62,18 +65,37 @@ class Gettext(AutotoolsPackage, GNUMirrorPackage): # depends_on('cvs') conflicts("+shared~pic") + # https://savannah.gnu.org/bugs/?65811 + conflicts("%gcc@:5", when="@0.22:") patch("test-verify-parallel-make-check.patch", when="@:0.19.8.1") patch("nvhpc-builtin.patch", when="@:0.21.0 %nvhpc") patch("nvhpc-export-symbols.patch", when="%nvhpc") patch("nvhpc-long-width.patch", when="%nvhpc") - # Apply this only where we know that the system libc is glibc, be very careful: - @when("@:0.21.0 target=ppc64le:") def patch(self): - for fn in ("gettext-tools/gnulib-lib/cdefs.h", "gettext-tools/libgrep/cdefs.h"): - with open(fn, "w") as f: - f.write("#include \n") + # Apply this only where we know that the system libc is glibc, be very careful: + if self.spec.satisfies("@:0.21.0 target=ppc64le"): + for fn in ("gettext-tools/gnulib-lib/cdefs.h", "gettext-tools/libgrep/cdefs.h"): + with open(fn, "w") as f: + f.write("#include \n") + + # From the configure script: "we don't want to use an external libxml, because its + # dependencies and their dynamic relocations have an impact on the startup time", well, + # *we* do. + if self.spec.satisfies("@0.20:"): # libtextstyle/configure not present prior + filter_file( + "gl_cv_libxml_force_included=yes", + "gl_cv_libxml_force_included=no", + "libtextstyle/configure", + string=True, + ) + + def flag_handler(self, name, flags): + # this goes together with gl_cv_libxml_force_included=no + if name == "ldflags": + flags.append("-lxml2") + return (flags, None, None) @classmethod def determine_version(cls, exe): @@ -98,10 +120,10 @@ def configure_args(self): config_args.extend(self.enable_or_disable("shared")) - if self.spec["iconv"].name == "libc": + if self.spec["iconv"].name == "libiconv": + config_args.append(f"--with-libiconv-prefix={self.spec['iconv'].prefix}") + else: config_args.append("--without-libiconv-prefix") - elif not is_system_path(self.spec["iconv"].prefix): - config_args.append("--with-libiconv-prefix=" + self.spec["iconv"].prefix) if "+curses" in spec: config_args.append("--with-ncurses-prefix={0}".format(spec["ncurses"].prefix)) diff --git a/var/spack/repos/builtin/packages/gexiv2/package.py b/var/spack/repos/builtin/packages/gexiv2/package.py index fc88a05935eb71..585fa110f20610 100644 --- a/var/spack/repos/builtin/packages/gexiv2/package.py +++ b/var/spack/repos/builtin/packages/gexiv2/package.py @@ -24,6 +24,9 @@ class Gexiv2(MesonPackage): version("0.12.1", sha256="8aeafd59653ea88f6b78cb03780ee9fd61a2f993070c5f0d0976bed93ac2bd77") version("0.12.0", sha256="58f539b0386f36300b76f3afea3a508de4914b27e78f58ee4d142486a42f926a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("cmake@3.4:", type="build") depends_on("ninja@1.8.2:", type="build") diff --git a/var/spack/repos/builtin/packages/gffcompare/package.py b/var/spack/repos/builtin/packages/gffcompare/package.py index 88c66316cae13c..6b057b4d1c3414 100644 --- a/var/spack/repos/builtin/packages/gffcompare/package.py +++ b/var/spack/repos/builtin/packages/gffcompare/package.py @@ -19,6 +19,8 @@ class Gffcompare(MakefilePackage): version("0.12.6", sha256="0e713bc9177d874c935802d11669776da5e9377a8c4d031153b48a783d3391d0") + depends_on("cxx", type="build") # generated + def build(self, spec, prefix): make("release") diff --git a/var/spack/repos/builtin/packages/gffread/package.py b/var/spack/repos/builtin/packages/gffread/package.py index 58896451b2e340..98ba8aef1a6bbf 100644 --- a/var/spack/repos/builtin/packages/gffread/package.py +++ b/var/spack/repos/builtin/packages/gffread/package.py @@ -17,6 +17,8 @@ class Gffread(MakefilePackage): version("0.12.7", sha256="bfde1c857495e578f5b3af3c007a9aa40593e69450eafcc6a42c3e8ef08ed1f5") + depends_on("cxx", type="build") # generated + def build(self, spec, prefix): make("release") diff --git a/var/spack/repos/builtin/packages/gflags/package.py b/var/spack/repos/builtin/packages/gflags/package.py index fbc0e846d98779..67f90a2654d2c3 100644 --- a/var/spack/repos/builtin/packages/gflags/package.py +++ b/var/spack/repos/builtin/packages/gflags/package.py @@ -21,6 +21,8 @@ class Gflags(CMakePackage): version("2.2.2", sha256="34af2f15cf7367513b352bdcd2493ab14ce43692d2dcd9dfc499492966c64dcf") version("2.1.2", sha256="d8331bd0f7367c8afd5fcb5f5e85e96868a00fd24b7276fa5fcee1e5575c2662") + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.12:", type="build") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/gfsio/package.py b/var/spack/repos/builtin/packages/gfsio/package.py index a5dc64a92cf039..f78b623269dceb 100644 --- a/var/spack/repos/builtin/packages/gfsio/package.py +++ b/var/spack/repos/builtin/packages/gfsio/package.py @@ -21,6 +21,8 @@ class Gfsio(CMakePackage): version("develop", branch="develop") version("1.4.1", sha256="eab106302f520600decc4f9665d7c6a55e7b4901fab6d9ef40f29702b89b69b1") + depends_on("fortran", type="build") # generated + def setup_run_environment(self, env): lib = find_libraries("libgfsio", root=self.prefix, shared=False, recursive=True) # Only one library version, but still need to set _4 to make NCO happy diff --git a/var/spack/repos/builtin/packages/gftl-shared/package.py b/var/spack/repos/builtin/packages/gftl-shared/package.py index 22bedeb13299aa..d03d0dac2665e2 100644 --- a/var/spack/repos/builtin/packages/gftl-shared/package.py +++ b/var/spack/repos/builtin/packages/gftl-shared/package.py @@ -41,6 +41,8 @@ class GftlShared(CMakePackage): version("1.3.1", sha256="a71e164108847f32f37da505f604fc2a50f392a4fcdf9a7cfe8eaf775bed64d4") version("1.3.0", sha256="979b00c4d531e701bf4346f662e3e4cc865124a97ca958637a53201d66d4ee43") + depends_on("fortran", type="build") # generated + depends_on("m4", type=("build", "run")) depends_on("cmake@3.12:", type="build") depends_on("gftl") diff --git a/var/spack/repos/builtin/packages/gftl/package.py b/var/spack/repos/builtin/packages/gftl/package.py index 69e36ff61350e8..888b39094c3dc4 100644 --- a/var/spack/repos/builtin/packages/gftl/package.py +++ b/var/spack/repos/builtin/packages/gftl/package.py @@ -39,6 +39,7 @@ class Gftl(CMakePackage): version("develop", branch="develop") version("main", branch="main") + version("1.13.0", sha256="d8ef4bca5fb67e63dcd69e5377a0cef8336b00178a97450e79010552000d0a52") version("1.12.0", sha256="b50e17cb2109372819b3ee676e6e61fd3a517dc4c1ea293937c8a83f03b0cbd6") version("1.11.0", sha256="b28935bc077749823b1505ad8c1208360a5ba7e961d7593c17a33b11455a32a4") version("1.10.0", sha256="d6086e8cba2497bacdae66d301f7cdacaed9138a0055f33f8ca1b778a0cf0dc5") @@ -55,6 +56,8 @@ class Gftl(CMakePackage): version("1.5.5", sha256="67ff8210f08e9f2ee6ba23c8c26336f948420db5db7fc054c3a662e9017f18a3") version("1.5.4", sha256="4c53e932ba8d82616b65500f403a33a14957b9266b5e931e2448f1f005990750") + depends_on("fortran", type="build") # generated + depends_on("cmake@3.12:", type="build") depends_on("m4", type="build") diff --git a/var/spack/repos/builtin/packages/gh/package.py b/var/spack/repos/builtin/packages/gh/package.py index e72132e16f0f3f..90f40c6313812b 100644 --- a/var/spack/repos/builtin/packages/gh/package.py +++ b/var/spack/repos/builtin/packages/gh/package.py @@ -6,7 +6,7 @@ from spack.package import * -class Gh(Package): +class Gh(GoPackage): """GitHub's official command line tool.""" homepage = "https://github.com/cli/cli" @@ -16,6 +16,8 @@ class Gh(Package): license("MIT") + version("2.50.0", sha256="683d0dee90e1d24a6673d13680e0d41963ddc6dd88580ab5119acec790d1b4d7") + version("2.49.2", sha256="e839ea302ad99b70ce3efcb903f938ecbbb919798e49bc2f2034ad506ae0b0f5") version("2.43.1", sha256="1ea3f451fb7002c1fb95a7fab21e9ab16591058492628fe264c5878e79ec7c90") version("2.32.1", sha256="1d569dc82eb6520e6a8959568c2db84fea3bbaab2604c8dd5901849d320e1eae") version("2.28.0", sha256="cf3c0fb7f601d717d8b5177707a197c49fd426f5dc3c9aa52a932e96ba7166af") @@ -39,15 +41,12 @@ class Gh(Package): depends_on("go@1.18:", type="build", when="@2.10.0:") depends_on("go@1.19:", type="build", when="@2.21.0:") depends_on("go@1.21:", type="build", when="@2.33.0:") + depends_on("go@1.22:", type="build", when="@2.47.0:") - phases = ["build", "install"] - def setup_build_environment(self, env): - # Point GOPATH at the top of the staging dir for the build step. - env.prepend_path("GOPATH", self.stage.path) - - def build(self, spec, prefix): - make() - - def install(self, spec, prefix): - make("install", "prefix=" + prefix) +class GoBuilder(spack.build_systems.go.GoBuilder): + @property + def build_args(self): + args = super().build_args + args.extend(["-trimpath", "./cmd/gh"]) + return args diff --git a/var/spack/repos/builtin/packages/ghost/package.py b/var/spack/repos/builtin/packages/ghost/package.py index 030edfe45b411f..ce99f529a17d94 100644 --- a/var/spack/repos/builtin/packages/ghost/package.py +++ b/var/spack/repos/builtin/packages/ghost/package.py @@ -24,6 +24,9 @@ class Ghost(CMakePackage, CudaPackage): version("develop", branch="devel") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") variant("mpi", default=True, description="enable/disable MPI") variant("scotch", default=False, description="enable/disable matrix reordering with PT-SCOTCH") diff --git a/var/spack/repos/builtin/packages/ghostscript/package.py b/var/spack/repos/builtin/packages/ghostscript/package.py index 9384b1e16fca07..619264271e1a0a 100644 --- a/var/spack/repos/builtin/packages/ghostscript/package.py +++ b/var/spack/repos/builtin/packages/ghostscript/package.py @@ -29,6 +29,9 @@ class Ghostscript(AutotoolsPackage): version("9.21", sha256="02bceadbc4dddeb6f2eec9c8b1623d945d355ca11b8b4df035332b217d58ce85") version("9.18", sha256="5fc93079749a250be5404c465943850e3ed5ffbc0d5c07e10c7c5ee8afbbdb1b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # https://www.ghostscript.com/ocr.html variant("tesseract", default=False, description="Use the Tesseract library for OCR") diff --git a/var/spack/repos/builtin/packages/giflib/package.py b/var/spack/repos/builtin/packages/giflib/package.py index b28aed78931423..f794c16519f6b9 100644 --- a/var/spack/repos/builtin/packages/giflib/package.py +++ b/var/spack/repos/builtin/packages/giflib/package.py @@ -15,6 +15,7 @@ class Giflib(MakefilePackage, SourceforgePackage): license("MIT") + version("5.2.2", sha256="be7ffbd057cadebe2aa144542fd90c6838c6a083b5e8a9048b8ee3b66b29d5fb") version("5.2.1", sha256="31da5562f44c5f15d63340a09a4fd62b48c45620cd302f77a6d9acf0077879bd") version("5.2.0", sha256="dc7257487c767137602d86c17098ec97065a718ff568a61cfcf1a9466f197b1f") version( @@ -23,6 +24,8 @@ class Giflib(MakefilePackage, SourceforgePackage): extension="tar.bz2", ) + depends_on("c", type="build") # generated + depends_on("automake", type="build", when="@:5.2.0") depends_on("autoconf", type="build", when="@:5.2.0") depends_on("m4", type="build", when="@:5.2.0") @@ -72,3 +75,6 @@ def edit(self, spec, prefix): if spec.satisfies("@:5.2.0"): configure = Executable("./configure") configure("--prefix={0}".format(prefix)) + # remove call to convert in doc makefile + with working_dir("doc"): + filter_file("^.*convert.*-resize.*$", "", "Makefile") diff --git a/var/spack/repos/builtin/packages/gimp/package.py b/var/spack/repos/builtin/packages/gimp/package.py index e823df76d8f26e..d3c01af6697efb 100644 --- a/var/spack/repos/builtin/packages/gimp/package.py +++ b/var/spack/repos/builtin/packages/gimp/package.py @@ -31,6 +31,9 @@ class Gimp(AutotoolsPackage): version("2.10.26", sha256="5ddbccf1db462a41df9a26197fcb0d24c7152753a36b3c8b8a9506b4136395f7") version("2.10.24", sha256="bd1bb762368c0dd3175cf05006812dd676949c3707e21f4e6857435cb435989e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("doc", default=True, description="Build documentation with gtk-doc") variant("ghostscript", default=True, description="Build with ghostscript support") variant("jpegxl", default=True, description="Build with JPEG XL image format support") diff --git a/var/spack/repos/builtin/packages/ginkgo/1.4.0_dpcpp_use_old_standard.patch b/var/spack/repos/builtin/packages/ginkgo/1.4.0_dpcpp_use_old_standard.patch deleted file mode 100644 index 54ed07c22dfcc3..00000000000000 --- a/var/spack/repos/builtin/packages/ginkgo/1.4.0_dpcpp_use_old_standard.patch +++ /dev/null @@ -1,70 +0,0 @@ -commit 83164570f0d3511d114114bcc2b02ad23b753ed0 -Author: Yuhsiang M. Tsai -Date: Wed Oct 6 16:33:16 2021 +0200 - - syclstd 1.2.1 in new release to propagate subgroup - remove 64 subgroup in dense to avoid conj_trans issue on cpu temporarily - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index ceb269b1cb..b47388a596 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -67,7 +67,8 @@ if(MSVC) - elseif(GINKGO_BUILD_DPCPP OR CMAKE_CXX_COMPILER MATCHES "dpcpp") - # For now always use `-ffp-model=precise` with DPC++. This can be removed when - # the floating point issues are fixed. -- set(GINKGO_COMPILER_FLAGS "-Wpedantic;-ffp-model=precise" CACHE STRING -+ # -sycl-std=1.2.1 (or -sycl-std=2017) is temporary workaround after 2021.4 to propagate subgroup setting correctly -+ set(GINKGO_COMPILER_FLAGS "-Wpedantic;-ffp-model=precise;-sycl-std=1.2.1" CACHE STRING - "Set the required CXX compiler flags, mainly used for warnings. Current default is `-Wpedantic;-ffp-model=precise`") - else() - set(GINKGO_COMPILER_FLAGS "-Wpedantic" CACHE STRING -diff --git a/cmake/create_test.cmake b/cmake/create_test.cmake -index 9d22406f9a..dcc452b293 100644 ---- a/cmake/create_test.cmake -+++ b/cmake/create_test.cmake -@@ -40,6 +40,7 @@ function(ginkgo_create_dpcpp_test test_name) - add_executable(${test_target_name} ${test_name}.dp.cpp) - target_compile_features(${test_target_name} PUBLIC cxx_std_17) - target_compile_options(${test_target_name} PRIVATE "${GINKGO_DPCPP_FLAGS}") -+ target_compile_options(${test_target_name} PRIVATE "${GINKGO_COMPILER_FLAGS}") - target_link_options(${test_target_name} PRIVATE -fsycl-device-code-split=per_kernel) - ginkgo_set_test_target_properties(${test_name} ${test_target_name}) - # Note: MKL_ENV is empty on linux. Maybe need to apply MKL_ENV to all test. -diff --git a/dpcpp/CMakeLists.txt b/dpcpp/CMakeLists.txt -index fee9ec3639..ce71fd5d3c 100644 ---- a/dpcpp/CMakeLists.txt -+++ b/dpcpp/CMakeLists.txt -@@ -68,6 +68,7 @@ target_compile_definitions(ginkgo_dpcpp PRIVATE GKO_COMPILING_DPCPP) - - set(GINKGO_DPCPP_FLAGS ${GINKGO_DPCPP_FLAGS} PARENT_SCOPE) - target_compile_options(ginkgo_dpcpp PRIVATE "${GINKGO_DPCPP_FLAGS}") -+target_compile_options(ginkgo_dpcpp PRIVATE "${GINKGO_COMPILER_FLAGS}") - # Note: add MKL as PRIVATE not PUBLIC (MKL example shows) to avoid propagating - # find_package(MKL) everywhere when linking ginkgo (see the MKL example - # https://software.intel.com/content/www/us/en/develop/documentation/onemkl-windows-developer-guide/top/getting-started/cmake-config-for-onemkl.html) -diff --git a/dpcpp/matrix/dense_kernels.dp.cpp b/dpcpp/matrix/dense_kernels.dp.cpp -index 0c89530d1d..9a86ab9cd1 100644 ---- a/dpcpp/matrix/dense_kernels.dp.cpp -+++ b/dpcpp/matrix/dense_kernels.dp.cpp -@@ -69,14 +69,14 @@ namespace dpcpp { - namespace dense { - - -+// Disable the 64 subgroup. CPU supports 64 now, but conj_transpose will -+// lead CL_OUT_OF_RESOURCES. TODO: investigate this issue. - using KCFG_1D = ConfigSet<11, 7>; - constexpr auto kcfg_1d_list = -- syn::value_list(); --constexpr auto subgroup_list = -- syn::value_list(); -+ syn::value_list(); -+constexpr auto subgroup_list = syn::value_list(); - constexpr auto kcfg_1d_array = syn::as_array(kcfg_1d_list); - constexpr int default_block_size = 256; - diff --git a/var/spack/repos/builtin/packages/ginkgo/ginkgo-dpcpp-intrinsincs-oneapi-2024.1.patch b/var/spack/repos/builtin/packages/ginkgo/ginkgo-dpcpp-intrinsincs-oneapi-2024.1.patch new file mode 100644 index 00000000000000..437f89dab334d4 --- /dev/null +++ b/var/spack/repos/builtin/packages/ginkgo/ginkgo-dpcpp-intrinsincs-oneapi-2024.1.patch @@ -0,0 +1,19 @@ +diff -ruN spack-src/dpcpp/components/intrinsics.dp.hpp spack-src-patched/dpcpp/components/intrinsics.dp.hpp +--- spack-src/dpcpp/components/intrinsics.dp.hpp 2024-04-03 18:53:42.724032846 +0000 ++++ spack-src-patched/dpcpp/components/intrinsics.dp.hpp 2024-04-03 18:55:01.744543032 +0000 +@@ -67,13 +67,13 @@ + */ + __dpct_inline__ int ffs(uint32 mask) + { +- return (mask == 0) ? 0 : (sycl::ext::intel::ctz(mask) + 1); ++ return (mask == 0) ? 0 : (sycl::ctz(mask) + 1); + } + + /** @copydoc ffs */ + __dpct_inline__ int ffs(uint64 mask) + { +- return (mask == 0) ? 0 : (sycl::ext::intel::ctz(mask) + 1); ++ return (mask == 0) ? 0 : (sycl::ctz(mask) + 1); + } + + diff --git a/var/spack/repos/builtin/packages/ginkgo/package.py b/var/spack/repos/builtin/packages/ginkgo/package.py index 78b47e6e0bc5b5..998573ce62aa4c 100644 --- a/var/spack/repos/builtin/packages/ginkgo/package.py +++ b/var/spack/repos/builtin/packages/ginkgo/package.py @@ -41,6 +41,9 @@ class Ginkgo(CMakePackage, CudaPackage, ROCmPackage): version("1.1.0", commit="b9bec8225442b3eb2a85a870efa112ab767a17fb") # v1.1.0 version("1.0.0", commit="45244641e0c2b19ba33aecd25153c0bddbcbe1a0") # v1.0.0 + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("full_optimizations", default=False, description="Compile with all optimizations") variant("openmp", default=sys.platform != "darwin", description="Build with OpenMP") @@ -100,9 +103,15 @@ class Ginkgo(CMakePackage, CudaPackage, ROCmPackage): "+sycl", when="@:1.4.0", msg="For SYCL support, please use Ginkgo version 1.4.0 and newer." ) + # Probably fixed in NVIDIA/cccl#1528 which hopefully comes with the next CUDA release + conflicts("^cuda@12.4", when="+cuda", msg="CCCL 2.3 bug causes build failure.") + # https://github.com/ginkgo-project/ginkgo/pull/1524 patch("ginkgo-sycl-pr1524.patch", when="@1.7.0 +sycl %oneapi@2024:") + # https://github.com/ginkgo-project/ginkgo/pull/1585 + patch("ginkgo-dpcpp-intrinsincs-oneapi-2024.1.patch", when="@1.7.0 +sycl %oneapi@2024.1:") + # Skip smoke tests if compatible hardware isn't found patch("1.4.0_skip_invalid_smoke_tests.patch", when="@1.4.0") @@ -115,7 +124,7 @@ def setup_build_environment(self, env): env.set("MKLROOT", join_path(spec["intel-oneapi-mkl"].prefix, "mkl", "latest")) env.set("DPL_ROOT", join_path(spec["intel-oneapi-dpl"].prefix, "dpl", "latest")) # The `IntelSYCLConfig.cmake` is broken with spack. By default, it - # relies on the CMAKE_CXX_COMPILER being the real ipcx/dpcpp + # relies on the CMAKE_CXX_COMPILER being the real ipcx # compiler. If not, the variable SYCL_COMPILER of that script is # broken, and all the SYCL detection mechanism is wrong. We fix it # by giving hint environment variables. @@ -194,9 +203,9 @@ def cmake_args(self): ) if "+sycl" in self.spec: - sycl_compatible_compilers = ["dpcpp", "icpx"] + sycl_compatible_compilers = ["icpx"] if not (os.path.basename(self.compiler.cxx) in sycl_compatible_compilers): - raise InstallError("ginkgo +sycl requires DPC++ (dpcpp) or icpx compiler.") + raise InstallError("ginkgo +sycl requires icpx compiler.") return args @property diff --git a/var/spack/repos/builtin/packages/git-annex/package.py b/var/spack/repos/builtin/packages/git-annex/package.py index be50387287245d..62df61d23e0fb0 100644 --- a/var/spack/repos/builtin/packages/git-annex/package.py +++ b/var/spack/repos/builtin/packages/git-annex/package.py @@ -47,7 +47,7 @@ class GitAnnex(Package): # - $ git annex whereis git-annex/linux/current/git-annex-standalone-arm64.tar.gz # -> gives web url - skip_version_audit = ["platform=darwin"] + skip_version_audit = ["platform=darwin", "platform=windows"] license("AGPL-3.0-or-later") diff --git a/var/spack/repos/builtin/packages/git-lfs/package.py b/var/spack/repos/builtin/packages/git-lfs/package.py index e2e9ffe793f960..5e22601b80bab9 100644 --- a/var/spack/repos/builtin/packages/git-lfs/package.py +++ b/var/spack/repos/builtin/packages/git-lfs/package.py @@ -26,6 +26,8 @@ class GitLfs(MakefilePackage): license("MIT") + version("3.5.1", sha256="d682a12c0bc48d08d28834dd0d575c91d53dd6c6db63c45c2db7c3dd2fb69ea4") + version("3.4.1", sha256="2a36239d7968ae18e1ba2820dc664c4ef753f10bf424f98bccaf44d527f19a17") version("3.3.0", sha256="d5eeb9ee33188d3dd6a391f8a39b96d271f10295129789e5b3a1ac0e9f5114f5") version("3.1.2", sha256="5c9bc449068d0104ea124c25f596af16da85e7b5bf256bc544d8ce5f4fe231f2") version("2.13.3", sha256="f8bd7a06e61e47417eb54c3a0db809ea864a9322629b5544b78661edab17b950") @@ -39,6 +41,10 @@ class GitLfs(MakefilePackage): version("2.7.0", sha256="1c829ddd163be2206a44edb366bd7f6d84c5afae3496687405ca9d2a5f3af07b") version("2.6.1", sha256="e17cd9d4e66d1116be32f7ddc7e660c7f8fabbf510bc01b01ec15a22dd934ead") + depends_on("go@1.21:", type="build", when="@3.5:") + depends_on("go@1.20:", type="build", when="@3.4:") + depends_on("go@1.19:", type="build", when="@3.3:") + depends_on("go@1.18:", type="build", when="@3.2:") depends_on("go@1.17:", type="build", when="@2.13:") depends_on("go@1.5:", type="build", when="@:2.12") depends_on("git@1.8.2:", type="run") diff --git a/var/spack/repos/builtin/packages/git/package.py b/var/spack/repos/builtin/packages/git/package.py index 3dfe1d6cc2243e..f4ebee09221d49 100644 --- a/var/spack/repos/builtin/packages/git/package.py +++ b/var/spack/repos/builtin/packages/git/package.py @@ -29,165 +29,101 @@ class Git(AutotoolsPackage): # Every new git release comes with a corresponding manpage resource: # https://www.kernel.org/pub/software/scm/git/git-manpages-{version}.tar.gz # https://mirrors.edge.kernel.org/pub/software/scm/git/sha256sums.asc - version("2.42.0", sha256="34aedd54210d7216a55d642bbb4cfb22695b7610719a106bf0ddef4c82a8beed") - version("2.41.0", sha256="c4a6a3dd1827895a80cbd824e14d94811796ae54037549e0da93f7b84cb45b9f") - version("2.40.1", sha256="55511f10f3b1cdf5db4e0e3dea61819dfb67661b0507a5a2b061c70e4f87e14c") - version("2.39.3", sha256="2f9aa93c548941cc5aff641cedc24add15b912ad8c9b36ff5a41b1a9dcad783e") - version("2.38.5", sha256="09392caf6ff296341022595a175d8b075bc98b6a82f6227d3bd21e36a2a812c3") - version("2.37.7", sha256="2108fa57b74add4300b8960e9404e0ed3e5f0efda7470450c67c67e8ab7616d5") - version("2.36.6", sha256="a8c09f46d5d16a8d8f19e8089aeb408d95d8097af03de297061e83a2c74890dd") - version("2.35.8", sha256="3a675e0128a7153e1492bbe14d08195d44b5916e6b8879addf94b1f4add77dca") - version("2.34.8", sha256="10a6c233471d7d4439cd4004961a3f4ff7e6de308645a1074ec3522b8ea52c83") - version("2.33.8", sha256="eafd10da9fdf86be0a79beb67c3537eead114f91836c685d5b9c969c961516ae") - version("2.32.7", sha256="f09904d13a9bfca5fcb228c3caba1d4c17426dec0000bf67672af257b8a73db4") - version("2.31.8", sha256="d2443e368b1394858a1040bd74dacfba46bce2cf3410ef3bc5089a703fc91e9a") - version("2.30.9", sha256="b14b5f4ce1fe23ed78839664c7ba888fb5cedba3dd98d9f5a499a36fa3a4a2d8") - - # Deprecated versions + version("2.45.2", sha256="98b26090ed667099a3691b93698d1e213e1ded73d36a2fde7e9125fce28ba234") + version("2.44.2", sha256="f0655e81c5ecfeef7440aa4fcffa1c1a77eaccf764d6fe29579e9a06eac2cd04") + version("2.43.5", sha256="324c3b85d668e6afe571b3502035848e4b349dead35188e2b8ab1b96c0cd45ff") + version("2.42.3", sha256="f42a8e8f6c0add4516f9e4607554c8ad698161b7d721b82073fe315a59621961") + version("2.41.2", sha256="481aa0a15aa37802880a6245b96c1570d7337c44700d5d888344cd6d43d85306") + version("2.40.3", sha256="b3dc96b20edcdbe6bea7736ea55bb80babf683d126cc7f353ed4e3bc304cd7da") + version("2.39.5", sha256="ca0ec03fb2696f552f37135a56a0242fa062bd350cb243dc4a15c86f1cafbc99") + + # Deprecated versions (https://groups.google.com/g/git-packagers/c/x6-nKLV20aE) version( - "2.40.0", - sha256="ab37c343c0ad097282fd311ab9ca521ab3da836e5c4ed2093994f1b7f8575b09", + "2.45.1", + sha256="10acb581993061e616be9c5674469335922025a666318e0748cb8306079fef24", deprecated=True, ) version( - "2.39.2", - sha256="fb6807d1eb4094bb2349ab97d203fe1e6c3eb28af73ea391decfbd3a03c02e85", + "2.44.1", + sha256="118214bb8d7ba971a62741416e757562b8f5451cefc087a407e91857897c92cc", deprecated=True, ) version( - "2.39.1", - sha256="ae8d3427e4ccd677abc931f16183c0ec953e3bfcd866493601351e04a2b97398", + "2.43.4", + sha256="bfd717dc31922f718232a25a929d199e26146df5e876fdf0ff90a7cc95fa06e2", deprecated=True, ) version( - "2.38.3", - sha256="ba8f1c56763cfde0433657b045629a4c55047c243eb3091d39dea6f281c8d8e1", + "2.42.2", + sha256="3b24b712fa6e9a3da5b7d3e68b1854466905aadb93a43088a38816bcc3b9d043", deprecated=True, ) version( - "2.38.1", - sha256="620ed3df572a34e782a2be4c7d958d443469b2665eac4ae33f27da554d88b270", + "2.41.1", + sha256="06d2a681aa7f1bdb6e7f7101631407e7412faa534e1fa0eb6fdcb9975d867d31", deprecated=True, ) version( - "2.37.5", - sha256="5c11f90652afee6c77ef7ddfc672facd4bc6f2596d9627df2f1780664b058b9a", + "2.40.2", + sha256="1dcdfbb4eeb3ef2c2d9154f888d4a6f0cf19f19acad76f0d32e725e7bc147753", deprecated=True, ) version( - "2.37.4", - sha256="a638c9bf9e45e8d48592076266adaa9b7aa272a99ee2aee2e166a649a9ba8a03", - deprecated=True, - ) - version( - "2.36.3", - sha256="0c831b88b0534f08051d1287505dfe45c367108ee043de6f1c0502711a7aa3a6", - deprecated=True, - ) - version( - "2.35.6", - sha256="6bd51e0487028543ba40fe3d5b33bd124526a7f7109824aa7f022e79edf93bd1", - deprecated=True, - ) - version( - "2.35.5", - sha256="2cca63fe7bebb5b4bf8efea7b46b12bb89c16ff9711b6b6d845928501d00d0a3", - deprecated=True, - ) - version( - "2.34.6", - sha256="01c0ae4161a07ffeb89cfb8bda564eb2dcb83b45b678cf2930cdbdd8e81784d0", - deprecated=True, - ) - version( - "2.34.5", - sha256="26831c5e48a8c2bf6a4fede1b38e1e51ffd6dad85952cf69ac520ebd81a5ae82", - deprecated=True, - ) - version( - "2.33.6", - sha256="76f6a64a198bec38e83044f97fb5a2dfa8404091df5a905404615d2a4c5ebfb7", - deprecated=True, - ) - version( - "2.33.5", - sha256="d061ed97f890befaef18b4aad80a37b40db90bcf24113c42765fee157a69c7de", - deprecated=True, - ) - version( - "2.32.5", - sha256="9982e17209cf4a385ce4a6167863cdd29f68e425d4249aac186434dc3536fe5f", - deprecated=True, - ) - version( - "2.32.4", - sha256="4c791b8e1d96948c9772efc21373ab9b3187af42cdebc3bcbb1a06d794d4e494", + "2.39.4", + sha256="b895ed2b5d98fd3dcfde5807f16d5fb17c4f83044e7d08e597ae13de222f0d26", deprecated=True, ) + + # Deprecated versions (see https://github.blog/2024-05-14-securing-git-addressing-5-new-vulnerabilities/). version( - "2.31.6", - sha256="73971208dccdd6d87639abe50ee3405421ec4ba05dec9f8aa90b4e7f1985e15c", + "2.42.0", + sha256="34aedd54210d7216a55d642bbb4cfb22695b7610719a106bf0ddef4c82a8beed", deprecated=True, ) version( - "2.31.5", - sha256="2d4197660322937cc44cab5742deef727ba519ef7405455e33100912e3b019f2", + "2.41.0", + sha256="c4a6a3dd1827895a80cbd824e14d94811796ae54037549e0da93f7b84cb45b9f", deprecated=True, ) version( - "2.30.7", - sha256="c98bf38a296f23ad5619a097df928044b31859df8f89b3ae5a8ea109d3ebd88e", + "2.40.1", + sha256="55511f10f3b1cdf5db4e0e3dea61819dfb67661b0507a5a2b061c70e4f87e14c", deprecated=True, ) version( - "2.30.6", - sha256="a6130b38843a5c80e80fb4f7ac4864d361cbf103d262b64e267264e49440d24a", + "2.39.3", + sha256="2f9aa93c548941cc5aff641cedc24add15b912ad8c9b36ff5a41b1a9dcad783e", deprecated=True, ) + depends_on("c", type="build") # generated + for _version, _sha256_manpage in { + "2.45.2": "48c1e2e3ecbb2ce9faa020a19fcdbc6ce64ea25692111b5930686bc0bb4f0e7f", + "2.45.1": "d9098fd93a3c0ef242814fc856a99886ce31dae2ba457afc416ba4e92af8f8f5", + "2.44.2": "ee6a7238d5ede18fe21c0cc2131c7fbff1f871c25e2848892ee864d40baf7218", + "2.44.1": "8d80359e44cbcce256c1eb1389cb8e15ccfcd267fbb8df567d5ce19ce006eb42", + "2.43.5": "df3c3d0f0834959aa33005e6f8134c1e56ab01f34d1497ceb34b2dd8ec7d4de4", + "2.43.4": "99d3a0394a6093237123237fd6c0d3de1041d5ceaedc3bfc016807914275d3e2", + "2.42.3": "3c8c55dcbc3f59560c63e6ced400f7251e9a00d876d365cb4fe9be6b3c3e3713", + "2.42.2": "2ddfa2187fdaf9ab2b27c0ab043e46793127c26c82a824ffe980f006be049286", "2.42.0": "51643c53d70ce15dde83b6da2bad76ba0c7bbcd4f944d7c378f03a15b9f2e1de", + "2.41.2": "a758988c81478a942e1593ecf11568b962506bff1119061bad04bd4149b40c2c", + "2.41.1": "7093ef7dacfa8cdb3c4689d8bc1f06186d9b2420bec49087a3a6a4dee26ddcec", "2.41.0": "7b77c646b36d33c5c0f62677a147142011093270d6fd628ca38c42d5301f3888", + "2.40.3": "fa9b837e1e161ebdbbbfde27a883a90fe5f603ce1618086a384bccda59c47de5", + "2.40.2": "2c71f3f3e4801176f97708f2093756bce672ef260c6d95c255046e6727b3a031", "2.40.1": "6bbde434121bd0bf8aa574c60fd9a162388383679bd5ddd99921505149ffd4c2", - "2.40.0": "fda16047e9c1dd07d9585cc26bbf4002ebf8462ada54cb72b97a0e48135fd435", + "2.39.5": "16aac22749bd55d845c422068702781a9c89e6cdde7de1c3aa1dd0fb41aeae39", + "2.39.4": "fedd01dd22a15b84bcbcad68c1b37113ba2c64381c19b6c9f3aa9b2818e126dc", "2.39.3": "c8377b5a3ff497d7e6377363c270931496e982509ff27a1e46956d6637671642", - "2.39.2": "fd92e67fb750ceb2279dcee967a21303f2f8117834a21c1e0c9f312ebab6d254", - "2.39.1": "b2d1b2c6cba2343934792c4409a370a8c684add1b3c0f9b757e71189b1a2e80e", - "2.38.5": "648f2b89c9a173c3a687b99629208222170a398c7b14ed92de128656123c73cd", - "2.38.3": "9e5c924f6f1c961e09d1a8926c2775a158a0375a3311205d7a6176a3ed522272", - "2.38.1": "fcb27484406b64419a9f9890e95ef29af08e1f911d9d368546eddc59a18e245d", - "2.37.7": "475a894584ecc8b278d592a2d99c5c4a4a863485f5126508bcef686cba4a4ac0", - "2.37.5": "9fab559197891fc1b499cb57513effce7462383f861ac6a7791a46f5348dd7fe", - "2.37.4": "06ed920949e717f3ab13c98327ee63cae5e3020ac657d14513ef8f843109b638", - "2.36.6": "08bded34c0ff49b7e8d5d0778511a07f191751c6edb98aaf2cee4c96962cc94c", - "2.36.3": "c5f5385c2b46270a8ce062a9c510bfa4288d9cca54efe0dff48a12ca969cfc6f", - "2.35.8": "f85e549d37936df744fd78c1ce670c1682bdd2f35d1f072883b82babe66e484a", - "2.35.6": "5e44e05a97f49d7a170a7303f795063b19bc78560acd7458274882f19b631187", - "2.35.5": "6cbd4d2185c7a757db21f873973fa1efb81069d8b8b8cc350ca6735cb98f45c5", - "2.34.8": "e43e75edb8d339ceed4990b5054eb2302efc857d0feab690598e14dbdb9bcccc", - "2.34.6": "70c784ced9c5ccbd4137d676b032e2ccffeea8aef3094626c2b44d6c843547df", - "2.34.5": "897941be5b223b9d32217adb64ea8747db2ba57be5f68be598c44d747d1061b2", - "2.33.8": "9b49f931e58001d818b2cba7eb6d0242965cfb1eaa5194271b88fcc4529b4987", - "2.33.6": "d7b9170dc7d6f461e00731cf5cf6e4b589e90c8d4eac440fd3e8b5e3d11f0b8f", - "2.33.5": "34648ede9ac2869190083ee826065c36165e54d9e2906b10680261b243d89890", - "2.32.7": "dcce6d701f99190e081f74b539389cdf4674ddbcd4af143631034354a5db39fc", - "2.32.5": "99b236824f1677e15b21514e310d7a0954586d031ffc3a873a4e2138ed073f15", - "2.32.4": "fa73d0eac384e594efdd4c21343545e407267ab64e970a6b395c7f1874ddb0bf", - "2.31.8": "73722b9487456d7605beec65a9fa9415410faa8b9f8a5fd209d75be47bf1a968", - "2.31.6": "2e2f921d8ef8a839e05ba3a1cea8f864a49b04648378bf0253213a5d4f1642fe", - "2.31.5": "18850fc8f1c34e51a0a98b9f974b8356a5d63a53c96fb9fe3dc2880ee84746ab", - "2.30.9": "a3f61fe08453dd88fdd84a28ee6d4c9fbd710a7b1ead7ce5c976146656714ece", - "2.30.7": "4fc6063c229453de244a88c71f688a2508f30b80ebd47353cc68d730ea1b82aa", - "2.30.6": "6c20ab10be233e8ff7838351fa5210e972c08005ec541a5241f626cfd4adebfe", }.items(): resource( name="git-manpages", - url="https://www.kernel.org/pub/software/scm/git/git-manpages-{0}.tar.gz".format( - _version - ), + url=f"https://www.kernel.org/pub/software/scm/git/git-manpages-{_version}.tar.gz", sha256=_sha256_manpage, placement="git-manpages", - when="@{0} +man".format(_version), + when=f"@{_version} +man", ) variant("tcltk", default=False, description="Gitk: provide Tcl/Tk in the run environment") @@ -207,8 +143,7 @@ class Git(AutotoolsPackage): depends_on("iconv") depends_on("libidn2") depends_on("openssl") - depends_on("pcre", when="@:2.13") - depends_on("pcre2", when="@2.14:") + depends_on("pcre2") depends_on("perl", when="+perl") depends_on("zlib-api") depends_on("openssh", type="run") @@ -278,12 +213,8 @@ def configure_args(self): "--with-zlib={0}".format(spec["zlib-api"].prefix), ] - if not self.spec["iconv"].name == "libc": - configure_args.append( - "--with-iconv={0}".format( - "yes" if is_system_path(spec["iconv"].prefix) else spec["iconv"].prefix - ) - ) + if self.spec["iconv"].name == "libiconv": + configure_args.append(f"--with-iconv={self.spec['iconv'].prefix}") if "+perl" in self.spec: configure_args.append("--with-perl={0}".format(spec["perl"].command.path)) diff --git a/var/spack/repos/builtin/packages/gitconddb/package.py b/var/spack/repos/builtin/packages/gitconddb/package.py index f42822459d0387..4499def68f4646 100644 --- a/var/spack/repos/builtin/packages/gitconddb/package.py +++ b/var/spack/repos/builtin/packages/gitconddb/package.py @@ -24,6 +24,8 @@ class Gitconddb(CMakePackage): version("0.1.2", sha256="121ac34d8afffbd97b052cbb10f15e78cef962fe25ded85d88ab26e1677b72b5") version("0.1.1", sha256="024a6867722a3a622ed4327ea7d15641dd48e4e8411bdcc21915e406b3c479a2") + depends_on("cxx", type="build") # generated + # Add the cxxstd variant for forward compatibility, though we require 17 _cxxstd_values = ("17",) variant( diff --git a/var/spack/repos/builtin/packages/gl2ps/package.py b/var/spack/repos/builtin/packages/gl2ps/package.py index da229fbb7c921c..af24489a976a9e 100644 --- a/var/spack/repos/builtin/packages/gl2ps/package.py +++ b/var/spack/repos/builtin/packages/gl2ps/package.py @@ -19,6 +19,8 @@ class Gl2ps(CMakePackage): version("1.4.0", sha256="03cb5e6dfcd87183f3b9ba3b22f04cd155096af81e52988cc37d8d8efe6cf1e2") version("1.3.9", sha256="8a680bff120df8bcd78afac276cdc38041fed617f2721bade01213362bcc3640") + depends_on("c", type="build") # generated + variant("png", default=True, description="Enable PNG support") variant("zlib", default=True, description="Enable compression using ZLIB") variant("doc", default=False, description="Generate documentation using pdflatex") diff --git a/var/spack/repos/builtin/packages/glew/package.py b/var/spack/repos/builtin/packages/glew/package.py index 22ec0dbb684b11..8bc88fd1c84186 100644 --- a/var/spack/repos/builtin/packages/glew/package.py +++ b/var/spack/repos/builtin/packages/glew/package.py @@ -2,9 +2,6 @@ # 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 * @@ -23,29 +20,11 @@ class Glew(CMakePackage): version("2.1.0", sha256="04de91e7e6763039bc11940095cd9c7f880baba82196a7765f727ac05a993c95") version("2.0.0", sha256="c572c30a4e64689c342ba1624130ac98936d7af90c3103f9ce12b8a0c5736764") - variant( - "gl", - default="glx" if sys.platform.startswith("linux") else "other", - values=("glx", "osmesa", "egl", "other"), - multi=False, - description="The OpenGL provider to use", - ) - conflicts("^osmesa", when="gl=glx") - conflicts("^osmesa", when="gl=egl") - conflicts("^osmesa", when="gl=other") - conflicts("^glx", when="gl=osmesa") - conflicts("^glx", when="gl=other") - conflicts("^glx", when="gl=egl") - conflicts("^egl", when="gl=glx") - conflicts("^egl", when="gl=osmesa") - conflicts("^egl", when="gl=other") + depends_on("c", type="build") # generated depends_on("gl") - depends_on("osmesa", when="gl=osmesa") - depends_on("glx", when="gl=glx") - depends_on("libx11", when="gl=glx") - depends_on("xproto", when="gl=glx") - depends_on("egl", when="gl=egl") + depends_on("libx11", when="^[virtuals=gl] glx") + depends_on("xproto", when="^[virtuals=gl] glx") # glu is already forcibly disabled in the CMakeLists.txt. This prevents # it from showing up in the .pc file @@ -56,18 +35,15 @@ def cmake_args(self): args = [ self.define("BUILD_UTILS", True), self.define("GLEW_REGAL", False), - self.define("GLEW_EGL", "gl=egl" in spec), - self.define("OpenGL_GL_PREFERENCE", "LEGACY"), + self.define("GLEW_EGL", spec.satisfies("^[virtuals=gl] egl")), self.define("OPENGL_INCLUDE_DIR", spec["gl"].headers.directories[0]), self.define("OPENGL_gl_LIBRARY", spec["gl"].libs[0]), self.define("OPENGL_opengl_LIBRARY", "IGNORE"), self.define("OPENGL_glx_LIBRARY", "IGNORE"), self.define("OPENGL_glu_LIBRARY", "IGNORE"), - self.define("GLEW_OSMESA", "gl=osmesa" in spec), - self.define("GLEW_X11", "gl=glx" in spec), - self.define("CMAKE_DISABLE_FIND_PACKAGE_X11", "gl=glx" not in spec), + self.define("GLEW_OSMESA", spec.satisfies("^[virtuals=gl] osmesa")), ] - if "gl=egl" in spec: + if spec.satisfies("^[virtuals=gl] egl"): args.append( self.define("OPENGL_egl_LIBRARY", [spec["egl"].libs[0], spec["egl"].libs[1]]) ) @@ -75,3 +51,8 @@ def cmake_args(self): args.append(self.define("OPENGL_egl_LIBRARY", "IGNORE")) return args + + def flag_handler(self, name, flags): + if name == "ldflags" and self.spec.satisfies("platform=darwin ^apple-gl"): + flags.append("-framework OpenGL") + return flags, None, None diff --git a/var/spack/repos/builtin/packages/glfmultiples/package.py b/var/spack/repos/builtin/packages/glfmultiples/package.py index 4ed24a057343a8..ca2be8bdbb2f23 100644 --- a/var/spack/repos/builtin/packages/glfmultiples/package.py +++ b/var/spack/repos/builtin/packages/glfmultiples/package.py @@ -21,6 +21,8 @@ class Glfmultiples(MakefilePackage): "2010-06-16", sha256="f7abef6f6b043e9052fb408bb2aae6d0d97d907aedc1b3e02dd0db08eb81b979" ) + depends_on("cxx", type="build") # generated + depends_on("zlib-api") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/glfw/package.py b/var/spack/repos/builtin/packages/glfw/package.py index bdaadb3cfd915f..ba005f779c8fb0 100644 --- a/var/spack/repos/builtin/packages/glfw/package.py +++ b/var/spack/repos/builtin/packages/glfw/package.py @@ -29,6 +29,8 @@ class Glfw(CMakePackage): version("3.0.4", sha256="a4e7c57db2086803de4fc853bd472ff8b6d2639b9aa16e6ac6b19ffb53958caf") version("3.0.3", sha256="7a182047ba6b1fdcda778b79aac249bb2328b6d141188cb5df29560715d01693") + depends_on("c", type="build") # generated + variant("doc", default=False, description="Build documentation") variant("shared", default=False, description="Builds a shared version of the library") diff --git a/var/spack/repos/builtin/packages/glib-networking/package.py b/var/spack/repos/builtin/packages/glib-networking/package.py index 998c0d7beed17e..0d08df0c3b5bf4 100644 --- a/var/spack/repos/builtin/packages/glib-networking/package.py +++ b/var/spack/repos/builtin/packages/glib-networking/package.py @@ -18,6 +18,8 @@ class GlibNetworking(MesonPackage): version("2.65.90", sha256="91b35c5d7472d10229b0b01c0631ac171903e96f84a6fb22c4126a40528c09e2") version("2.65.1", sha256="d06311004f7dda4561c210f286a3678b631fb7187cb3b90616c5ba39307cc91f") + depends_on("c", type="build") # generated + depends_on("gettext", type="build") depends_on("glib") depends_on("gnutls") diff --git a/var/spack/repos/builtin/packages/glib/package.py b/var/spack/repos/builtin/packages/glib/package.py index f09a32a3cf02e7..43367172b48c9d 100644 --- a/var/spack/repos/builtin/packages/glib/package.py +++ b/var/spack/repos/builtin/packages/glib/package.py @@ -120,6 +120,9 @@ class Glib(MesonPackage, AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("libmount", default=False, description="Build with libmount support") variant( "tracing", @@ -317,13 +320,13 @@ def meson_args(self): if self.spec.satisfies("@:2.72"): args.append("-Dgettext=external") if self.spec.satisfies("@:2.74"): - if self.spec["iconv"].name == "libc": - args.append("-Diconv=libc") - else: + if self.spec["iconv"].name == "libiconv": if self.spec.satisfies("@2.61.0:"): args.append("-Diconv=external") else: args.append("-Diconv=gnu") + else: + args.append("-Diconv=libc") return args @@ -338,10 +341,10 @@ def configure_args(self): args.append( "--with-python={0}".format(os.path.basename(self.spec["python"].command.path)) ) - if self.spec["iconv"].name == "libc": - args.append("--with-libiconv=maybe") - else: + if self.spec["iconv"].name == "libiconv": args.append("--with-libiconv=gnu") + else: + args.append("--with-libiconv=maybe") if self.spec.satisfies("@2.56:"): for value in ("dtrace", "systemtap"): if ("tracing=" + value) in self.spec: diff --git a/var/spack/repos/builtin/packages/glibc/package.py b/var/spack/repos/builtin/packages/glibc/package.py index 471eb0345dfd88..db4dce7ec695c8 100644 --- a/var/spack/repos/builtin/packages/glibc/package.py +++ b/var/spack/repos/builtin/packages/glibc/package.py @@ -20,10 +20,19 @@ class Glibc(AutotoolsPackage, GNUMirrorPackage): maintainers("haampie") build_directory = "build" + tags = ["runtime"] + + # This is used when the package is external and we need to find the actual default include path + # which may be in a multiarch subdir. + representative_headers = ["ieee754.h"] license("LGPL-2.1-or-later") + provides("libc") + provides("iconv") + version("master", branch="master") + version("2.39", sha256="97f84f3b7588cd54093a6f6389b0c1a81e70d99708d74963a2e3eab7c7dc942d") version("2.38", sha256="16e51e0455e288f03380b436e41d5927c60945abd86d0c9852b84be57dd6ed5e") version("2.37", sha256="e3a790c2f84eed5c5d569ed6172c253c607dd3962135437da413aa39aa4fd352") version("2.36", sha256="02efa6ffbbaf3e10e88f16818a862608d04b0ef838c66f6025ae120530792c9c") @@ -59,6 +68,9 @@ class Glibc(AutotoolsPackage, GNUMirrorPackage): version("2.6.1", sha256="6be7639ccad715d25eef560ce9d1637ef206fb9a162714f6ab8167fc0d971cae") version("2.5", sha256="16d3ac4e86eed75d85d80f1f214a6bd58d27f13590966b5ad0cc181df85a3493") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Fix for newer GCC, related to -fno-common patch("locs.patch", when="@2.23:2.25") patch("locs-2.22.patch", when="@:2.22") @@ -165,6 +177,8 @@ def patch(self): # See 2d7ed98add14f75041499ac189696c9bd3d757fe depends_on("gmake@:4.3", type="build", when="@:2.36") + # Since f2873d2da0ac9802e0b570e8e0b9e7e04a82bf55 + depends_on("gmake@4.0:", type="build", when="@2.28:") # From 2.29: generates locale/C-translit.h # before that it's a test dependency. @@ -192,3 +206,11 @@ def build(self, spec, prefix): make("-C", "..", f"objdir={os.getcwd()}", "lib") delete_rpath(join_path("elf", "ld.so")) make() + + @property + def libs(self): + return LibraryList([]) + + @property + def headers(self): + return HeaderList([]) diff --git a/var/spack/repos/builtin/packages/glibmm/package.py b/var/spack/repos/builtin/packages/glibmm/package.py index 25b0ba95eae427..3e533d3551ef06 100644 --- a/var/spack/repos/builtin/packages/glibmm/package.py +++ b/var/spack/repos/builtin/packages/glibmm/package.py @@ -19,6 +19,8 @@ class Glibmm(AutotoolsPackage): version("2.16.0", sha256="99795b9c6e58e490df740a113408092bf47a928427cbf178d77c35adcb6a57a3") version("2.4.8", sha256="78b97bfa1d001cc7b398f76bf09005ba55b45ae20780b297947a1a71c4f07e1f") + depends_on("cxx", type="build") # generated + depends_on("libsigcpp") # https://libsigcplusplus.github.io/libsigcplusplus/index.html # sigc++-2.0 and sigc++-3.0 are different parallel-installable ABIs: diff --git a/var/spack/repos/builtin/packages/glimmer/package.py b/var/spack/repos/builtin/packages/glimmer/package.py index f16453f198d79d..85df3c25ed7663 100644 --- a/var/spack/repos/builtin/packages/glimmer/package.py +++ b/var/spack/repos/builtin/packages/glimmer/package.py @@ -16,6 +16,8 @@ class Glimmer(MakefilePackage): version("3.02b", sha256="ecf28e03d0a675aed7360ca34ca7f19993f5c3ea889273e657ced9fa7d1e2bf6") + depends_on("cxx", type="build") # generated + build_directory = "src" def url_for_version(self, version): diff --git a/var/spack/repos/builtin/packages/glm/package.py b/var/spack/repos/builtin/packages/glm/package.py index bd5921c61bc82e..8b78d03c82e541 100644 --- a/var/spack/repos/builtin/packages/glm/package.py +++ b/var/spack/repos/builtin/packages/glm/package.py @@ -19,12 +19,16 @@ class Glm(CMakePackage): license("MIT") version("develop", branch="master") + version("1.0.1", sha256="9f3174561fd26904b23f0db5e560971cbf9b3cbda0b280f04d5c379d03bf234c") version("0.9.9.8", sha256="7d508ab72cb5d43227a3711420f06ff99b0a0cb63ee2f93631b162bfe1fe9592") version("0.9.9.3", sha256="fba9fd177073a36c5a7798c74b28e79ba6deb8f4bb0d2dbfc0e207c27da7e12c") version("0.9.7.1", sha256="285a0dc8f762b4e523c8710fbd97accaace0c61f45bc8be2bdb0deed07b0e6f3") + depends_on("cxx", type="build") # generated + depends_on("cmake@2.6:", type="build") depends_on("cmake@3.2:", type="build", when="@0.9.9.0:") + depends_on("cmake@3.6:", type="build", when="@1:") # CMake install target was removed in version 0.9.9.6 @when("@0.9.9.6:0.9.9.8") diff --git a/var/spack/repos/builtin/packages/globalarrays/package.py b/var/spack/repos/builtin/packages/globalarrays/package.py index 54f740cac9054c..82ad9080f602a1 100644 --- a/var/spack/repos/builtin/packages/globalarrays/package.py +++ b/var/spack/repos/builtin/packages/globalarrays/package.py @@ -35,6 +35,10 @@ class Globalarrays(AutotoolsPackage): version("5.6.1", sha256="b324deed49f930f55203e1d18294ce07dd02680b9ac0728ebc54f94a12557ebc") version("5.6", sha256="a228dfbae9a6cfaae34694d7e56f589ac758e959b58f4bc49e6ef44058096767") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("scalapack", default=False, description="Enable SCALAPACK") variant( "armci", @@ -47,6 +51,9 @@ class Globalarrays(AutotoolsPackage): depends_on("blas") depends_on("lapack") + depends_on("libfabric", when="armci=ofi") + depends_on("rdma-core", when="armci=openib") + depends_on("scalapack", when="+scalapack") # See release https://github.com/GlobalArrays/ga/releases/tag/v5.7.1 diff --git a/var/spack/repos/builtin/packages/glog/package.py b/var/spack/repos/builtin/packages/glog/package.py index eea294f4f85495..b38537f499936c 100644 --- a/var/spack/repos/builtin/packages/glog/package.py +++ b/var/spack/repos/builtin/packages/glog/package.py @@ -6,7 +6,7 @@ from spack.package import * -class Glog(Package): +class Glog(CMakePackage): """C++ implementation of the Google logging module.""" homepage = "https://github.com/google/glog" @@ -14,35 +14,19 @@ class Glog(Package): license("BSD-3-Clause") + version("0.7.1", sha256="00e4a87e87b7e7612f519a41e491f16623b12423620006f59f5688bfd8d13b08") version("0.7.0", sha256="375106b5976231b92e66879c1a92ce062923b9ae573c42b56ba28b112ee4cc11") version("0.6.0", sha256="8a83bf982f37bb70825df71a9709fa90ea9f4447fb3c099e1d720a439d88bad6") version("0.4.0", sha256="f28359aeba12f30d73d9e4711ef356dc842886968112162bc73002645139c39c") version("0.3.5", sha256="7580e408a2c0b5a89ca214739978ce6ff480b5e7d8d7698a2aa92fadc484d1e0") - version( - "0.3.4", - sha256="ce99d58dce74458f7656a68935d7a0c048fa7b4626566a71b7f4e545920ceb10", - deprecated=True, - ) - version( - "0.3.3", - sha256="544e178644bd9b454768c2c91716c3b8365cc5d47adfbdbaecd8cf3fa17adfcb", - deprecated=True, - ) + + depends_on("cxx", type="build") # generated depends_on("gflags") - depends_on("cmake", when="@0.3.5:", type="build") - - def install(self, spec, prefix): - configure(f"--prefix={prefix}") - make() - make("install") - - @when("@0.3.5:") - def install(self, spec, prefix): - cmake_args = ["-DBUILD_SHARED_LIBS=TRUE"] - cmake_args.extend(std_cmake_args) - - with working_dir("spack-build", create=True): - cmake("..", *cmake_args) - make() - make("install") + + depends_on("cmake@3:", type="build") + depends_on("cmake@3.16:", type="build", when="@0.6.0:") + depends_on("cmake@3.22:", type="build", when="@0.7.0:") + + def cmake_args(self): + return [self.define("BUILD_SHARED_LIBS", True)] diff --git a/var/spack/repos/builtin/packages/gloo/package.py b/var/spack/repos/builtin/packages/gloo/package.py index dcf9a7e3cebd4f..b554d5c30138ab 100644 --- a/var/spack/repos/builtin/packages/gloo/package.py +++ b/var/spack/repos/builtin/packages/gloo/package.py @@ -15,7 +15,8 @@ class Gloo(CMakePackage, CudaPackage): license("BSD-3-Clause") version("master", branch="master") - version("2023-05-19", commit="597accfd79f5b0f9d57b228dec088ca996686475") # py-torch@2.1: + version("2023-12-03", commit="5354032ea08eadd7fc4456477f7f7c6308818509") # py-torch@2.3: + version("2023-05-19", commit="597accfd79f5b0f9d57b228dec088ca996686475") # py-torch@2.1:2.2 version("2023-01-17", commit="10909297fedab0a680799211a299203e53515032") # py-torch@2.0 version("2022-05-18", commit="5b143513263133af2b95547e97c07cebeb72bf72") # py-torch@1.13 version("2021-05-21", commit="c22a5cfba94edf8ea4f53a174d38aa0c629d070f") # py-torch@1.10:1.12 @@ -30,6 +31,8 @@ class Gloo(CMakePackage, CudaPackage): version("2018-05-29", commit="69eef748cc1dfbe0fefed69b34e6545495f67ac5") # py-torch@0.4.1 version("2018-04-06", commit="aad0002fb40612e991390d8e807f247ed23f13c5") # py-torch@:0.4.0 + depends_on("cxx", type="build") # generated + # Gloo does not build on Linux >=6.0.3 (fixed in master) # See: https://github.com/facebookincubator/gloo/issues/345 patch( diff --git a/var/spack/repos/builtin/packages/glpk/package.py b/var/spack/repos/builtin/packages/glpk/package.py index 2cd7426f7102cf..0c93cdcd7ecd44 100644 --- a/var/spack/repos/builtin/packages/glpk/package.py +++ b/var/spack/repos/builtin/packages/glpk/package.py @@ -23,6 +23,9 @@ class Glpk(AutotoolsPackage, GNUMirrorPackage): version("4.61", sha256="9866de41777782d4ce21da11b88573b66bb7858574f89c28be6967ac22dfaba9") version("4.57", sha256="7323b2a7cc1f13e45fc845f0fdca74f4daea2af716f5ad2d4d55b41e8394275c") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("gmp", default=False, description="Activates support for GMP library") depends_on("gmp", when="+gmp") diff --git a/var/spack/repos/builtin/packages/gluegen/package.py b/var/spack/repos/builtin/packages/gluegen/package.py index 5112cee7c66dd5..01834d01edde65 100644 --- a/var/spack/repos/builtin/packages/gluegen/package.py +++ b/var/spack/repos/builtin/packages/gluegen/package.py @@ -19,6 +19,8 @@ class Gluegen(Package): version("java-11-fixes", branch="java-11-fixes", submodules=True) + depends_on("c", type="build") # generated + # ant optional jar file to execute antlr tasks resource( name="ant-optional", diff --git a/var/spack/repos/builtin/packages/glusterfs/package.py b/var/spack/repos/builtin/packages/glusterfs/package.py index 0df17e464a5d24..e104e4dea36e70 100644 --- a/var/spack/repos/builtin/packages/glusterfs/package.py +++ b/var/spack/repos/builtin/packages/glusterfs/package.py @@ -25,6 +25,8 @@ class Glusterfs(AutotoolsPackage): version("6.8", sha256="41e855bdc456759c8c15ef494c636a25cc7b62c55ad132ecd55bec05df64793f") version("6.7", sha256="e237dd59a2d5b73e156b0b71df49ff64a143b3aaf8f0a65daaf369bb40f5e923") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/glvis/package.py b/var/spack/repos/builtin/packages/glvis/package.py index 310c9695b5ed11..872be1a028fa06 100644 --- a/var/spack/repos/builtin/packages/glvis/package.py +++ b/var/spack/repos/builtin/packages/glvis/package.py @@ -93,6 +93,9 @@ class Glvis(MakefilePackage): extension="tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "screenshots", default="png", @@ -154,6 +157,9 @@ def common_args(self): "CONFIG_MK={0}".format(self.spec["mfem"].package.config_mk), ] + # https://github.com/spack/spack/issues/42839 + result.append("CPPFLAGS=-DGLEW_NO_GLU") + if self.spec.satisfies("@4.0:"): # Spack will inject the necessary include dirs and link paths via # its compiler wrapper, so we can skip them: diff --git a/var/spack/repos/builtin/packages/gmake/package.py b/var/spack/repos/builtin/packages/gmake/package.py index fd91ab8405ece4..2e52b7e5ea9746 100644 --- a/var/spack/repos/builtin/packages/gmake/package.py +++ b/var/spack/repos/builtin/packages/gmake/package.py @@ -24,7 +24,14 @@ class Gmake(Package, GNUMirrorPackage): version("4.4", sha256="581f4d4e872da74b3941c874215898a7d35802f03732bdccee1d4a7979105d18") version("4.3", sha256="e05fdde47c5f7ca45cb697e973894ff4f5d79e13b750ed57d7b66d8defc78e19") version("4.2.1", sha256="e40b8f018c1da64edd1cc9a6fce5fa63b2e707e404e20cad91fbae337c98a5b7") - version("4.0", sha256="fc42139fb0d4b4291929788ebaf77e2a4de7eaca95e31f3634ef7d4932051f69") + version("4.1", sha256="9fc7a9783d3d2ea002aa1348f851875a2636116c433677453cc1d1acc3fc4d55") + version( + "4.0", + deprecated=True, + sha256="fc42139fb0d4b4291929788ebaf77e2a4de7eaca95e31f3634ef7d4932051f69", + ) + + depends_on("c", type="build") # generated variant("guile", default=False, description="Support GNU Guile for embedded scripting") @@ -33,9 +40,6 @@ class Gmake(Package, GNUMirrorPackage): depends_on("guile@:3.0") depends_on("pkgconfig", type="build") - # build.sh requires it in 4.0 (SV 40254) - conflicts("~guile", when="@4.0") - patch( "https://src.fedoraproject.org/rpms/make/raw/519a7c5bcbead22e6ea2d2c2341d981ef9e25c0d/f/make-4.2.1-glob-fix-2.patch", level=1, @@ -75,10 +79,18 @@ def configure_args(self): def install(self, spec, prefix): configure = Executable(join_path(self.stage.source_path, "configure")) - build_sh = Executable(join_path(self.stage.source_path, "build.sh")) with working_dir(self.build_directory, create=True): configure(f"--prefix={prefix}", *self.configure_args()) - build_sh() + if spec.satisfies("@:4.2.1"): # generated files in build dir + build_sh = join_path(".", "build.sh") + config_h = join_path(".", "config.h") + else: # generated files in source dir + build_sh = join_path(self.stage.source_path, "build.sh") + config_h = join_path("src", "config.h") + # The default CXX value should be generic, not CXX from the current build as it points + # to the compiler wrapper by absolute path. + filter_file(r"^#define MAKE_CXX .*$", "#undef MAKE_CXX", config_h) + Executable(build_sh)() os.mkdir(prefix.bin) install("make", prefix.bin) os.symlink("make", prefix.bin.gmake) diff --git a/var/spack/repos/builtin/packages/gmap-gsnap/package.py b/var/spack/repos/builtin/packages/gmap-gsnap/package.py index 739e76f5fea51d..0ba006aa2ff102 100644 --- a/var/spack/repos/builtin/packages/gmap-gsnap/package.py +++ b/var/spack/repos/builtin/packages/gmap-gsnap/package.py @@ -61,6 +61,8 @@ class GmapGsnap(AutotoolsPackage): "2014-12-28", sha256="108433f3e3ea89b8117c8bb36d396913225caf1261d46ce6d89709ff1b44025d" ) + depends_on("c", type="build") # generated + depends_on("zlib-api") depends_on("bzip2") depends_on("perl", type="run") diff --git a/var/spack/repos/builtin/packages/gmime/package.py b/var/spack/repos/builtin/packages/gmime/package.py index c10f374153d419..6641aab7e5b7c2 100644 --- a/var/spack/repos/builtin/packages/gmime/package.py +++ b/var/spack/repos/builtin/packages/gmime/package.py @@ -18,5 +18,7 @@ class Gmime(AutotoolsPackage): version("2.6.23", sha256="7149686a71ca42a1390869b6074815106b061aaeaaa8f2ef8c12c191d9a79f6a") + depends_on("c", type="build") # generated + depends_on("glib@2.18.0:") depends_on("libgpg-error") diff --git a/var/spack/repos/builtin/packages/gmodel/package.py b/var/spack/repos/builtin/packages/gmodel/package.py index c65558e0cca0c2..1fc0d934a6ddf3 100644 --- a/var/spack/repos/builtin/packages/gmodel/package.py +++ b/var/spack/repos/builtin/packages/gmodel/package.py @@ -22,6 +22,8 @@ class Gmodel(CMakePackage): version("2.1.0", sha256="80df0c6dc413a9ffa0f0e7b65118b05b643ba3e1bfcac28fb91d2d3ad017fda0") + depends_on("cxx", type="build") # generated + # fix error [-Werror,-Wzero-as-null-pointer-constant] # fix error [-Werror,-Wunused-template] # Ref: https://github.com/ibaned/gmodel/commit/6b81ec190cf2ce9a6554a99cb6d759b023393cdd diff --git a/var/spack/repos/builtin/packages/gmp/package.py b/var/spack/repos/builtin/packages/gmp/package.py index d385de6a303233..dd87a3d2175366 100644 --- a/var/spack/repos/builtin/packages/gmp/package.py +++ b/var/spack/repos/builtin/packages/gmp/package.py @@ -15,6 +15,7 @@ class Gmp(AutotoolsPackage, GNUMirrorPackage): license("LGPL-3.0-or-later OR GPL-2.0-or-later") + version("6.3.0", sha256="ac28211a7cfb609bae2e2c8d6058d66c8fe96434f740cf6fe2e47b000d1c20cb") version("6.2.1", sha256="eae9326beb4158c386e39a356818031bd28f3124cf915f8c5b1dc4c7a36b4d7c") version("6.2.0", sha256="f51c99cb114deb21a60075ffb494c1a210eb9d7cb729ed042ddb7de9534451ea") version("6.1.2", sha256="5275bb04f4863a13516b2f39392ac5e272f5e1bb8057b18aec1c9b79d73d8fb2") @@ -25,6 +26,10 @@ class Gmp(AutotoolsPackage, GNUMirrorPackage): # Old version needed for a binary package in ghc-bootstrap version("4.3.2", sha256="936162c0312886c21581002b79932829aa048cfaf9937c6265aeaa14f1cd1775") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/gmsh/package.py b/var/spack/repos/builtin/packages/gmsh/package.py index 7049cd2772db9e..636abe009602b4 100644 --- a/var/spack/repos/builtin/packages/gmsh/package.py +++ b/var/spack/repos/builtin/packages/gmsh/package.py @@ -20,11 +20,16 @@ class Gmsh(CMakePackage): url = "https://gmsh.info/src/gmsh-4.4.1-source.tgz" git = "https://gitlab.onelab.info/gmsh/gmsh.git" + maintainers("fspiga") + license("GPL-2.0-or-later") version("master", branch="master") + version("4.13.1", sha256="77972145f431726026d50596a6a44fb3c1c95c21255218d66955806b86edbe8d") + version("4.13.0", sha256="c85f056ee549a433e814a61c385c97952bbfe514b442b999f6149fffb1e54f64") version("4.12.2", sha256="13e09d9ca8102e5c40171d6ee150c668742b98c3a6ca57f837f7b64e1e2af48f") version("4.12.0", sha256="2a6007872ba85abd9901914826f6986a2437ab7104f564ccefa1b7a3de742c17") + version("4.11.1", sha256="c5fe1b7cbd403888a814929f2fd0f5d69e27600222a18c786db5b76e8005b365") version("4.10.3", sha256="a87d59ccea596d493d375b0d6bc380079a5e5a4baebf0d3383018b0cd6bd8e33") version("4.8.4", sha256="760dbdc072eaa3c82d066c5ba3b06eacdd3304eb2a97373fe4ada9509f0b6ace") version("4.7.1", sha256="c984c295116c757ed165d77149bd5fdd1068cbd7835e9bcd077358b503891c6a") @@ -41,6 +46,10 @@ class Gmsh(CMakePackage): version("2.16.0", sha256="e829eaf32ea02350a385202cc749341f2a3217c464719384b18f653edd028eea") version("2.15.0", sha256="992a4b580454105f719f5bc05441d3d392ab0b4b80d4ea07b61ca3bdc974070a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "external", default=False, @@ -141,37 +150,37 @@ def cmake_args(self): ] # Use system versions of contrib libraries, when possible: - if "+external" in spec: + if spec.satisfies("+external"): options.append(self.define("ENABLE_SYSTEM_CONTRIB", True)) # Make sure native file dialogs are used options.append("-DENABLE_NATIVE_FILE_CHOOSER=ON") - options.append("-DCMAKE_INSTALL_NAME_DIR:PATH=%s" % self.prefix.lib) + options.append(f"-DCMAKE_INSTALL_NAME_DIR:PATH={self.prefix.lib}") # Prevent GMsh from using its own strange directory structure on OSX options.append("-DENABLE_OS_SPECIFIC_INSTALL=OFF") # Make sure GMSH picks up correct BlasLapack by providing linker flags - if "~eigen" in spec: + if spec.satisfies("~eigen"): options.append("-DENABLE_BLAS_LAPACK=ON") blas_lapack = spec["lapack"].libs + spec["blas"].libs - options.append("-DBLAS_LAPACK_LIBRARIES={0}".format(blas_lapack.ld_flags)) + options.append(f"-DBLAS_LAPACK_LIBRARIES={blas_lapack.ld_flags}") - if "+oce" in spec: + if spec.satisfies("+oce"): options.append("-DENABLE_OCC=ON") - elif "+opencascade" in spec: + elif spec.satisfies("+opencascade"): options.append("-DENABLE_OCC=ON") else: options.append("-DENABLE_OCC=OFF") - if "@:3.0.6" in spec: + if spec.satisfies("@:3.0.6"): options.append(self.define_from_variant("ENABLE_TETGEN", "tetgen")) - if "@:4.6" in spec: + if spec.satisfies("@:4.6"): options.append(self.define_from_variant("ENABLE_MMG3D", "mmg")) - if "+shared" in spec: + if spec.satisfies("+shared"): # Builds dynamic executable and installs shared library options.append(self.define("ENABLE_BUILD_SHARED", True)) options.append(self.define("ENABLE_BUILD_DYNAMIC", True)) @@ -179,7 +188,7 @@ def cmake_args(self): # Builds and installs static library options.append(self.define("ENABLE_BUILD_LIB", True)) - if "+compression" in spec: + if spec.satisfies("+compression"): options.append(self.define("ENABLE_COMPRESSED_IO", True)) return options diff --git a/var/spack/repos/builtin/packages/gmt/package.py b/var/spack/repos/builtin/packages/gmt/package.py index 02e3d1973e383c..6d207642eee753 100644 --- a/var/spack/repos/builtin/packages/gmt/package.py +++ b/var/spack/repos/builtin/packages/gmt/package.py @@ -38,6 +38,9 @@ class Gmt(CMakePackage, AutotoolsPackage): url="ftp://ftp.soest.hawaii.edu/gmt/gmt-4.5.18-src.tar.bz2", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "ghostscript", default=False, diff --git a/var/spack/repos/builtin/packages/gmtsar/package.py b/var/spack/repos/builtin/packages/gmtsar/package.py index 40de8de678a907..45495d1f11064a 100644 --- a/var/spack/repos/builtin/packages/gmtsar/package.py +++ b/var/spack/repos/builtin/packages/gmtsar/package.py @@ -17,4 +17,6 @@ class Gmtsar(CMakePackage): version("5.6", sha256="0f7326f46aedf1e8e4dc80dd03f1ae8681f52a8253dc4a00a943aec14562994b") + depends_on("c", type="build") # generated + depends_on("gmt") diff --git a/var/spack/repos/builtin/packages/gnds/package.py b/var/spack/repos/builtin/packages/gnds/package.py index f413ab30f7eb0e..2ffbc670472ebd 100644 --- a/var/spack/repos/builtin/packages/gnds/package.py +++ b/var/spack/repos/builtin/packages/gnds/package.py @@ -19,6 +19,8 @@ class Gnds(CMakePackage): version("0.0.1", sha256="4c8faaa01a3e6fb08ec3e8e126a76f75b5442509a46b993e325ec79dd9f04879") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") depends_on("pugixml") diff --git a/var/spack/repos/builtin/packages/gnina/package.py b/var/spack/repos/builtin/packages/gnina/package.py index dcfa07c259e7d2..38d91e32c85718 100644 --- a/var/spack/repos/builtin/packages/gnina/package.py +++ b/var/spack/repos/builtin/packages/gnina/package.py @@ -21,6 +21,8 @@ class Gnina(CMakePackage, CudaPackage): version("1.1", sha256="114570b0f84a545ce0fea5b2da87bc116c134cef64bf90e6e58e8f84e175a0fa") version("1.0.3", sha256="4274429f38293d79c7d22ab08aca91109e327e9ce3f682cd329a8f9c6ef429da") + depends_on("cxx", type="build") # generated + variant("cudnn", default=True, description="Build with cuDNN") variant("gninavis", default=False, description="Build gninavis") diff --git a/var/spack/repos/builtin/packages/gnupg/package.py b/var/spack/repos/builtin/packages/gnupg/package.py index 9babe48a85476a..859389b8503219 100644 --- a/var/spack/repos/builtin/packages/gnupg/package.py +++ b/var/spack/repos/builtin/packages/gnupg/package.py @@ -6,7 +6,6 @@ import re from spack.package import * -from spack.util.environment import is_system_path class Gnupg(AutotoolsPackage): @@ -36,16 +35,23 @@ class Gnupg(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("npth@1.2:", when="@2:") depends_on("libgpg-error@1.24:", when="@2:") depends_on("libgpg-error@1.41:", when="@2.3:") + depends_on("libgpg-error@1.46:", when="@2.4:") depends_on("libgcrypt@1.7.0:", when="@2:") depends_on("libgcrypt@1.9.1:", when="@2.3:") - depends_on("libksba@1.3.4:", when="@2.0.0:") + depends_on("libksba@1.3.4:", when="@2:") + depends_on("libksba@1.6.3:", when="@2.4:") + depends_on("libassuan@2.5:", when="@2.2.15:") + depends_on("libassuan@:2", when="@:2.4.3") + depends_on("pinentry", type="run", when="@2:") depends_on("iconv", when="@2:") depends_on("zlib-api") @@ -95,10 +101,10 @@ def configure_args(self): f"--with-npth-prefix={self.spec['npth'].prefix}", ] ) - if self.spec["iconv"].name == "libc": - args.append("--without-libiconv-prefix") - elif not is_system_path(self.spec["iconv"].prefix): + if self.spec["iconv"].name == "libiconv": args.append(f"--with-libiconv-prefix={self.spec['iconv'].prefix}") + else: + args.append("--without-libiconv-prefix") if self.spec.satisfies("@:1"): args.extend( diff --git a/var/spack/repos/builtin/packages/gnuplot/package.py b/var/spack/repos/builtin/packages/gnuplot/package.py index 908f6812569de2..7c29fe1bb37efd 100644 --- a/var/spack/repos/builtin/packages/gnuplot/package.py +++ b/var/spack/repos/builtin/packages/gnuplot/package.py @@ -44,6 +44,9 @@ class Gnuplot(AutotoolsPackage): version("5.0.5", sha256="25f3e0bf192e01115c580f278c3725d7a569eb848786e12b455a3fda70312053") version("5.0.1", sha256="7cbc557e71df581ea520123fb439dea5f073adcc9010a2885dc80d4ed28b3c47") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("wx", default=False, description="Activates wxWidgets terminal") variant("gd", default=True, description="Activates gd based terminal") variant("cairo", default=True, description="Activates cairo based terminal") diff --git a/var/spack/repos/builtin/packages/gnuradio/package.py b/var/spack/repos/builtin/packages/gnuradio/package.py index cb4f86c7a8e264..515d765389d07f 100644 --- a/var/spack/repos/builtin/packages/gnuradio/package.py +++ b/var/spack/repos/builtin/packages/gnuradio/package.py @@ -26,6 +26,10 @@ class Gnuradio(CMakePackage): version("3.8.2.0", sha256="ddda12b55e3e1d925eefb24afb9d604bca7c9bbe0a431707aa48a2eed53eec2f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("gui", default=False, description="Build with gui support") depends_on("cmake@3.5.1:", type="build") @@ -42,6 +46,8 @@ class Gnuradio(CMakePackage): # See https://github.com/spack/spack/pull/22303 for reference depends_on(Boost.with_default_variants) depends_on("py-numpy", type=("build", "run")) + # https://github.com/gnuradio/gnuradio/issues/7378 + depends_on("py-numpy@:1", when="@:3.10.10.0", type=("build", "run")) depends_on("py-click", type=("build", "run")) depends_on("py-pyyaml", type=("build", "run")) depends_on("py-click-plugins", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/gnutls/package.py b/var/spack/repos/builtin/packages/gnutls/package.py index 562866a2630a1a..71db94256c71d2 100644 --- a/var/spack/repos/builtin/packages/gnutls/package.py +++ b/var/spack/repos/builtin/packages/gnutls/package.py @@ -33,6 +33,9 @@ class Gnutls(AutotoolsPackage): version("3.5.9", sha256="82b10f0c4ef18f4e64ad8cef5dbaf14be732f5095a41cf366b4ecb4050382951") version("3.3.9", sha256="39166de5293a9d30ef1cd0a4d97f01fdeed7d7dbf8db95392e309256edcb13c1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("zlib", default=True, description="Enable zlib compression support") variant("guile", default=False, description="Enable Guile bindings") diff --git a/var/spack/repos/builtin/packages/go-bootstrap/package.py b/var/spack/repos/builtin/packages/go-bootstrap/package.py index 27784763adb36c..108c8542524669 100644 --- a/var/spack/repos/builtin/packages/go-bootstrap/package.py +++ b/var/spack/repos/builtin/packages/go-bootstrap/package.py @@ -25,8 +25,6 @@ class GoBootstrap(Package): maintainers("alecbcs") - depends_on("git", type=("build", "link", "run")) - executables = ["^go$"] # List binary go releases for multiple operating systems and architectures. diff --git a/var/spack/repos/builtin/packages/go-md2man/package.py b/var/spack/repos/builtin/packages/go-md2man/package.py index ba0eb166c5b47f..48656e6810b647 100644 --- a/var/spack/repos/builtin/packages/go-md2man/package.py +++ b/var/spack/repos/builtin/packages/go-md2man/package.py @@ -14,6 +14,7 @@ class GoMd2man(GoPackage): license("MIT") + version("2.0.4", sha256="b0a4c7c077ede56967deef6ab7e7696c0f46124b0b3360fd05564ec5a536f11f") version("2.0.3", sha256="7ca3a04bb4ab83387538235decc42a535097a05d2fb9f2266d0c47b33119501f") version("2.0.2", sha256="2f52e37101ea2734b02f2b54a53c74305b95b3a9a27792fdac962b5354aa3e4a") version("1.0.10", sha256="76aa56849123b99b95fcea2b15502fd886dead9a5c35be7f78bdc2bad6be8d99") diff --git a/var/spack/repos/builtin/packages/go/package.py b/var/spack/repos/builtin/packages/go/package.py index 9e8b2b37335d8f..25d53308c3a375 100644 --- a/var/spack/repos/builtin/packages/go/package.py +++ b/var/spack/repos/builtin/packages/go/package.py @@ -41,64 +41,18 @@ class Go(Package): license("BSD-3-Clause") + version("1.22.4", sha256="fed720678e728a7ca30ba8d1ded1caafe27d16028fab0232b8ba8e22008fb784") + version("1.22.2", sha256="374ea82b289ec738e968267cac59c7d5ff180f9492250254784b2044e90df5a9") + version("1.22.1", sha256="79c9b91d7f109515a25fc3ecdaad125d67e6bdb54f6d4d98580f46799caea321") version("1.22.0", sha256="4d196c3d41a0d6c1dfc64d04e3cc1f608b0c436bd87b7060ce3e23234e1f4d5c") version("1.21.6", sha256="124926a62e45f78daabbaedb9c011d97633186a33c238ffc1e25320c02046248") version("1.21.5", sha256="285cbbdf4b6e6e62ed58f370f3f6d8c30825d6e56c5853c66d3c23bcdb09db19") - # Deprecated Versions - # https://nvd.nist.gov/vuln/detail/CVE-2023-44487 - version( - "1.21.3", - sha256="186f2b6f8c8b704e696821b09ab2041a5c1ee13dcbc3156a13adcf75931ee488", - deprecated=True, - ) - # https://nvd.nist.gov/vuln/detail/CVE-2023-39533 - version( - "1.20.6", - sha256="62ee5bc6fb55b8bae8f705e0cb8df86d6453626b4ecf93279e2867092e0b7f70", - deprecated=True, - ) - # https://nvd.nist.gov/vuln/detail/CVE-2023-29405 - version( - "1.20.4", - sha256="9f34ace128764b7a3a4b238b805856cc1b2184304df9e5690825b0710f4202d6", - deprecated=True, - ) - version( - "1.20.3", - sha256="e447b498cde50215c4f7619e5124b0fc4e25fb5d16ea47271c47f278e7aa763a", - deprecated=True, - ) - version( - "1.19.11", - sha256="e25c9ab72d811142b7f41ff6da5165fec2d1be5feec3ef2c66bc0bdecb431489", - deprecated=True, - ) - version( - "1.19.9", - sha256="131190a4697a70c5b1d232df5d3f55a3f9ec0e78e40516196ffb3f09ae6a5744", - deprecated=True, - ) - version( - "1.19.8", - sha256="1d7a67929dccafeaf8a29e55985bc2b789e0499cb1a17100039f084e3238da2f", - deprecated=True, - ) - # https://nvd.nist.gov/vuln/detail/CVE-2023-24538 - version( - "1.20.2", - sha256="4d0e2850d197b4ddad3bdb0196300179d095bb3aefd4dfbc3b36702c3728f8ab", - deprecated=True, - ) - version( - "1.19.7", - sha256="775bdf285ceaba940da8a2fe20122500efd7a0b65dbcee85247854a8d7402633", - deprecated=True, - ) - provides("golang") - depends_on("git", type="run") + depends_on("bash", type="build") + depends_on("sed", type="build") + depends_on("grep", type="build") depends_on("go-or-gccgo-bootstrap", type="build") depends_on("go-or-gccgo-bootstrap@1.17.13:", type="build", when="@1.20:") depends_on("go-or-gccgo-bootstrap@1.20.6:", type="build", when="@1.22:") @@ -115,7 +69,7 @@ def determine_version(cls, exe): return match.group(1) if match else None def setup_build_environment(self, env): - env.set("GOROOT_FINAL", self.spec.prefix) + env.set("GOROOT_FINAL", self.spec.prefix.go) # We need to set CC/CXX_FOR_TARGET, otherwise cgo will use the # internal Spack wrappers and fail. env.set("CC_FOR_TARGET", self.compiler.cc) @@ -123,13 +77,15 @@ def setup_build_environment(self, env): env.set("GOMAXPROCS", make_jobs) def build(self, spec, prefix): + # Build script depend on bash bash = which("bash") with working_dir("src"): bash(f"{'all' if self.run_tests else 'make'}.bash") def install(self, spec, prefix): - install_tree(".", prefix) + install_tree(".", prefix.go) + os.symlink(prefix.go.bin, prefix.bin) def setup_dependent_package(self, module, dependent_spec): """Called before go modules' build(), install() methods. diff --git a/var/spack/repos/builtin/packages/gobject-introspection/package.py b/var/spack/repos/builtin/packages/gobject-introspection/package.py index 9a91bcf087fa5c..9ac9aa32e650cb 100644 --- a/var/spack/repos/builtin/packages/gobject-introspection/package.py +++ b/var/spack/repos/builtin/packages/gobject-introspection/package.py @@ -24,10 +24,13 @@ class GobjectIntrospection(MesonPackage, AutotoolsPackage): version("1.76.1", sha256="196178bf64345501dcdc4d8469b36aa6fe80489354efe71cb7cb8ab82a3738bf") version("1.72.1", sha256="012e313186e3186cf0fde6decb57d970adf90e6b1fac5612fe69cbb5ba99543a") version("1.72.0", sha256="02fe8e590861d88f83060dd39cda5ccaa60b2da1d21d0f95499301b186beaabc") + version("1.60.2", sha256="ffdfe2368fb2e34a547898b01aac0520d52d8627fdeb1c306559bcb503ab5e9c") version("1.56.1", sha256="5b2875ccff99ff7baab63a34b67f8c920def240e178ff50add809e267d9ea24b") version("1.49.2", sha256="73d59470ba1a546b293f54d023fd09cca03a951005745d86d586b9e3a8dde9ac") version("1.48.0", sha256="fa275aaccdbfc91ec0bc9a6fd0562051acdba731e7d584b64a277fec60e75877") + depends_on("c", type="build") # generated + build_system( conditional("autotools", when="@:1.60"), conditional("meson", when="@1.61:"), @@ -44,9 +47,9 @@ class GobjectIntrospection(MesonPackage, AutotoolsPackage): depends_on("cairo+gobject") depends_on("glib@2.78:", when="@1.78") depends_on("glib@2.76:", when="@1.76") - depends_on("glib@2.72:", when="@1.72") + depends_on("glib@2.58:", when="@1.60:1.72") depends_on("glib@2.56:", when="@1.56") - depends_on("glib@2.49.2:", when="@1.49.2:") + depends_on("glib@2.49.2:", when="@1.49.2") depends_on("glib@2.48.1", when="@1.48.0") depends_on("libffi") @@ -74,7 +77,10 @@ class GobjectIntrospection(MesonPackage, AutotoolsPackage): # extra sed expression in its TOOL_SUBSTITUTION that results in # an `#!/bin/bash /path/to/spack/bin/sbang` unconditionally being # inserted into the scripts as they're generated. - patch("sbang.patch", when="@:1.60") + patch("sbang.patch", when="@:1.56") + # The TOOL_SUBSITUTION line changed after 1.58 to include /usr/bin/env in + # the Python substituion more explicitly. The Makefile.am was removed in 1.61. + patch("sbang-1.60.2.patch", when="@1.58:1.60") # Drop deprecated xml.etree.ElementTree.Element.getchildren() which leads # to compilation issues with Python 3.9. @@ -86,6 +92,12 @@ class GobjectIntrospection(MesonPackage, AutotoolsPackage): when="@:1.63.1", ) + conflicts( + "^python@3.11:", + when="@:1.60", + msg="giscannermodule.c in <=v1.60 uses syntax incompatible with Python >=3.11", + ) + def url_for_version(self, version): url = "https://download.gnome.org/sources/gobject-introspection/{0}/gobject-introspection-{1}.tar.xz" return url.format(version.up_to(2), version) diff --git a/var/spack/repos/builtin/packages/gobject-introspection/sbang-1.60.2.patch b/var/spack/repos/builtin/packages/gobject-introspection/sbang-1.60.2.patch new file mode 100644 index 00000000000000..c4d4985d644ab1 --- /dev/null +++ b/var/spack/repos/builtin/packages/gobject-introspection/sbang-1.60.2.patch @@ -0,0 +1,11 @@ +--- a/Makefile.in 2016-09-13 01:23:59.000000000 -0700 ++++ b/Makefile.in 2017-02-22 10:26:31.824509512 -0800 +@@ -1475,7 +1475,7 @@ + gir_DATA = $(STATIC_GIRSOURCES) $(SUBSTITUTED_GIRSOURCES) $(BUILT_GIRSOURCES) + typelibsdir = $(libdir)/girepository-1.0 + typelibs_DATA = $(gir_DATA:.gir=.typelib) +-TOOL_SUBSTITUTIONS = -e s,@libdir\@,$(libdir), -e s,@datarootdir\@,$(datarootdir), -e s,@PYTHON_CMD\@,\/usr\/bin\/env\ $(PYTHON), -e s,@GIR_DIR\@,$(GIR_DIR),g ++TOOL_SUBSTITUTIONS = -e s,@libdir\@,$(libdir), -e s,@datarootdir\@,$(datarootdir), -e s,@PYTHON_CMD\@,\/usr\/bin\/env\ $(PYTHON), -e s,@GIR_DIR\@,$(GIR_DIR),g -e "1i\#!/bin/bash $(SPACK_SBANG)" + g_ir_compiler_SOURCES = tools/compiler.c + g_ir_compiler_CPPFLAGS = -DGIREPO_DEFAULT_SEARCH_PATH="\"$(libdir)\"" \ + -I$(top_srcdir)/girepository diff --git a/var/spack/repos/builtin/packages/gocryptfs/package.py b/var/spack/repos/builtin/packages/gocryptfs/package.py new file mode 100644 index 00000000000000..c9b1dc6f22eab6 --- /dev/null +++ b/var/spack/repos/builtin/packages/gocryptfs/package.py @@ -0,0 +1,26 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Gocryptfs(GoPackage): + """Encrypted overlay filesystem written in Go""" + + homepage = "https://nuetzlich.net/gocryptfs/" + url = ( + "https://github.com/rfjakob/gocryptfs/releases/download/v2.4.0/gocryptfs_v2.4.0_src.tar.gz" + ) + + maintainers("snehring") + + license("MIT", checked_by="snehring") + + version("2.4.0", sha256="26a93456588506f4078f192b70e7816b6a4042a14b748b28a50d2b6c9b10e2ec") + + depends_on("c", type="build") # generated + + depends_on("openssl") + depends_on("pkg-config", type="build") diff --git a/var/spack/repos/builtin/packages/goma/package.py b/var/spack/repos/builtin/packages/goma/package.py index aa468cb1d106e0..2bcb29e9141c59 100644 --- a/var/spack/repos/builtin/packages/goma/package.py +++ b/var/spack/repos/builtin/packages/goma/package.py @@ -18,6 +18,7 @@ class Goma(CMakePackage): license("GPL-2.0-or-later") + version("7.6.1", commit="c799e935009b85e00979fa8b248952194f6ade7a") version("7.4.3", commit="bb0cf8030f9e8d61066d052ea6fad67fe49651f8") version("7.3.0", commit="415f442953e2171afae1f8ad55868052c6f511ce") version("7.2.0", commit="814f433aa5674c07274fffd4a619d80cd31f71ab") @@ -28,6 +29,10 @@ class Goma(CMakePackage): version("release", branch="release") version("main", branch="main") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Problem size variants variant( "max_conc", diff --git a/var/spack/repos/builtin/packages/google-cloud-cli/package.py b/var/spack/repos/builtin/packages/google-cloud-cli/package.py index a40a09e66c6094..18b66dc957c98a 100644 --- a/var/spack/repos/builtin/packages/google-cloud-cli/package.py +++ b/var/spack/repos/builtin/packages/google-cloud-cli/package.py @@ -49,6 +49,8 @@ class GoogleCloudCli(Package): if system in versions[ver] and machine in versions[ver][system]: version(ver, sha256=versions[ver][system][machine]) + depends_on("c", type="build") # generated + depends_on("python", type=("build", "run")) def url_for_version(self, version): @@ -58,7 +60,7 @@ def setup_build_environment(self, env): # https://cloud.google.com/sdk/gcloud/reference/topic/startup env.set("CLOUDSDK_PYTHON", self.spec["python"].command.path) # ~70 dependencies with no hints as to what versions are supported, just use bundled deps - env.set("CLOUDSDK_PYTHON_SITEPACKAGES", 0) + env.set("CLOUDSDK_PYTHON_SITEPACKAGES", "0") def setup_run_environment(self, env): self.setup_build_environment(env) diff --git a/var/spack/repos/builtin/packages/google-crc32c/package.py b/var/spack/repos/builtin/packages/google-crc32c/package.py index 0cfd5075bfb5a9..5f73a46e80c0f2 100644 --- a/var/spack/repos/builtin/packages/google-crc32c/package.py +++ b/var/spack/repos/builtin/packages/google-crc32c/package.py @@ -18,6 +18,9 @@ class GoogleCrc32c(CMakePackage): version("1.1.2", sha256="ac07840513072b7fcebda6e821068aa04889018f24e10e46181068fb214d7e56") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/googletest/package.py b/var/spack/repos/builtin/packages/googletest/package.py index f1b1424f73aa42..47b6b6d2d1f945 100644 --- a/var/spack/repos/builtin/packages/googletest/package.py +++ b/var/spack/repos/builtin/packages/googletest/package.py @@ -27,6 +27,8 @@ class Googletest(CMakePackage): version("1.7.0", sha256="f73a6546fdf9fce9ff93a5015e0333a8af3062a152a9ad6bcb772c96687016cc") version("1.6.0", sha256="5fbc058e5b662b9c86d93ac76fefb58eec89cbf26144b49669a38ecb62758447") + depends_on("cxx", type="build") # generated + variant("gmock", default=True, when="@1.8:", description="Build with gmock") variant("pthreads", default=True, description="Build multithreaded version with pthreads") variant("shared", default=True, description="Build shared libraries (DLLs)") @@ -44,10 +46,10 @@ class Googletest(CMakePackage): def cmake_args(self): spec = self.spec args = [ - self.define_from_variant("gtest_disable_pthreads", "pthreads"), self.define_from_variant("BUILD_SHARED_LIBS", "shared"), self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] + args.append(self.define("gtest_disable_pthreads", not spec.satisfies("+pthreads"))) if spec.satisfies("@1.8:"): # New style (contains both Google Mock and Google Test) args.append(self.define("BUILD_GTEST", True)) diff --git a/var/spack/repos/builtin/packages/gosam-contrib/package.py b/var/spack/repos/builtin/packages/gosam-contrib/package.py index ab60938f497270..fe6accd3816318 100644 --- a/var/spack/repos/builtin/packages/gosam-contrib/package.py +++ b/var/spack/repos/builtin/packages/gosam-contrib/package.py @@ -17,6 +17,12 @@ class GosamContrib(AutotoolsPackage): version("2.0", sha256="c05beceea74324eb51c1049773095e2cb0c09c8c909093ee913d8b0da659048d") version("1.0", sha256="a29d4232d9190710246abc2ed97fdcd8790ce83580f56a360f3456b0377c40ec") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + # whizard checks for .la files ( but does not use them ) + install_libtool_archives = True + variant( "libs", default="shared,static", @@ -26,6 +32,11 @@ class GosamContrib(AutotoolsPackage): ) variant("pic", default=False, description="Build position-independent code") + def patch(self): + # remove spack compiler wrapper path + mf = FileFilter("gosam.conf.in") + mf.filter("^fc.bin=.*", "fc.bin=" + self.compiler.fc) + def flag_handler(self, name, flags): if name in ["cflags", "cxxflags", "cppflags"]: if "+pic" in self.spec: diff --git a/var/spack/repos/builtin/packages/gotcha/package.py b/var/spack/repos/builtin/packages/gotcha/package.py index a743f844743f1f..a8a75078835c47 100644 --- a/var/spack/repos/builtin/packages/gotcha/package.py +++ b/var/spack/repos/builtin/packages/gotcha/package.py @@ -17,12 +17,17 @@ class Gotcha(CMakePackage): version("develop", branch="develop") version("master", branch="master") + version("1.0.7", tag="1.0.7", commit="ae053b77e6b2800188e2c4ddd17057c9b15f4adb") + version("1.0.6", tag="1.0.6", commit="81401b939c23562728a27d7678505090463e5c03") version("1.0.5", tag="1.0.5", commit="e28f10c45a0cda0e1ec225eaea6abfe72c8353aa") version("1.0.4", tag="1.0.4", commit="46f2aaedc885f140a3f31a17b9b9a9d171f3d6f0") version("1.0.3", tag="1.0.3", commit="1aafd1e30d46ce4e6555c8a4ea5f5edf6a5eade5") version("1.0.2", tag="1.0.2", commit="bed1b7c716ebb0604b3e063121649b5611640f25") version("0.0.2", tag="0.0.2", commit="c82f74778f7cae958a1bf21926d34fc910613d19") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("test", default=False, description="Build tests for Gotcha") patch( "https://github.com/LLNL/GOTCHA/commit/e82b4a1ecb634075d8f5334b796c888c86da0427.patch?full_index=1", diff --git a/var/spack/repos/builtin/packages/gource/package.py b/var/spack/repos/builtin/packages/gource/package.py index e410159ff99d76..c957010155fc94 100644 --- a/var/spack/repos/builtin/packages/gource/package.py +++ b/var/spack/repos/builtin/packages/gource/package.py @@ -17,6 +17,8 @@ class Gource(AutotoolsPackage): version("0.44", sha256="2604ca4442305ffdc5bb1a7bac07e223d59c846f93567be067e8dfe2f42f097c") + depends_on("cxx", type="build") # generated + depends_on("automake", type="build") depends_on("autoconf", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/gpcnet/package.py b/var/spack/repos/builtin/packages/gpcnet/package.py index 37c6eac63c224d..dbc49b8fcb0757 100644 --- a/var/spack/repos/builtin/packages/gpcnet/package.py +++ b/var/spack/repos/builtin/packages/gpcnet/package.py @@ -17,6 +17,8 @@ class Gpcnet(MakefilePackage): version("master") + depends_on("c", type="build") # generated + depends_on("mpi", type=("build", "run")) @property diff --git a/var/spack/repos/builtin/packages/gperf/package.py b/var/spack/repos/builtin/packages/gperf/package.py index dbb1b2c3256aae..d69af609cce5b1 100644 --- a/var/spack/repos/builtin/packages/gperf/package.py +++ b/var/spack/repos/builtin/packages/gperf/package.py @@ -22,6 +22,9 @@ class Gperf(AutotoolsPackage, GNUMirrorPackage): version("3.1", sha256="588546b945bba4b70b6a3a616e80b4ab466e3f33024a352fc2198112cdbb3ae2") version("3.0.4", sha256="767112a204407e62dbc3106647cf839ed544f3cf5d0f0523aaa2508623aad63e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # This patch removes all instances of the register keyword within gperf # which is necessary to build gperf with recent compilers that default to # c++17 where using the register keyword results in a compile-time error. diff --git a/var/spack/repos/builtin/packages/gperftools/package.py b/var/spack/repos/builtin/packages/gperftools/package.py index 42c07707a3d464..f6630aedebd679 100644 --- a/var/spack/repos/builtin/packages/gperftools/package.py +++ b/var/spack/repos/builtin/packages/gperftools/package.py @@ -3,10 +3,11 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.build_systems import autotools, cmake from spack.package import * -class Gperftools(AutotoolsPackage): +class Gperftools(AutotoolsPackage, CMakePackage): """Google's fast malloc/free implementation, especially for multi-threaded applications. Contains tcmalloc, heap-checker, heap-profiler, and cpu-profiler. @@ -19,6 +20,8 @@ class Gperftools(AutotoolsPackage): license("BSD-3-Clause") + build_system(conditional("cmake", when="@2.8.1:"), "autotools", default="cmake") + version("2.15", sha256="c69fef855628c81ef56f12e3c58f2b7ce1f326c0a1fe783e5cae0b88cbbe9a80") version("2.14", sha256="6b561baf304b53d0a25311bd2e29bc993bed76b7c562380949e7cb5e3846b299") version("2.13", sha256="4882c5ece69f8691e51ffd6486df7d79dbf43b0c909d84d3c0883e30d27323e7") @@ -31,6 +34,9 @@ class Gperftools(AutotoolsPackage): version("2.4", sha256="982a37226eb42f40714e26b8076815d5ea677a422fb52ff8bfca3704d9c30a2d") version("2.3", sha256="093452ad45d639093c144b4ec732a3417e8ee1f3744f2b0f8d45c996223385ce") + depends_on("c", type="build") + depends_on("cxx", type="build") + variant("sized_delete", default=False, description="Build sized delete operator") variant( "dynamic_sized_delete_support", @@ -43,21 +49,40 @@ class Gperftools(AutotoolsPackage): ) depends_on("unwind", when="+libunwind") + depends_on("cmake@3.12:", type="build", when="build_system=cmake") # Linker error: src/base/dynamic_annotations.cc:46: undefined reference to # `TCMallocGetenvSafe' conflicts("target=ppc64:", when="@2.14") conflicts("target=ppc64le:", when="@2.14") + # the autotools build system creates an explicit list of -L flags that end up + # before the -L flags, which causes the system libunwind to be linked instead of + # the spack libunwind. This is a workaround to fix that. + conflicts("+libunwind", when="build_system=autotools") + + +class CMakeBuilder(cmake.CMakeBuilder): + def cmake_args(self): + return [ + self.define_from_variant("gperftools_sized_delete", "sized_delete"), + self.define_from_variant( + "gperftools_dynamic_sized_delete_support", "dynamic_sized_delete_support" + ), + self.define_from_variant("GPERFTOOLS_BUILD_DEBUGALLOC", "debugalloc"), + self.define_from_variant("gperftools_enable_libunwind", "libunwind"), + self.define("gperftools_build_benchmark", False), + self.define("BUILD_TESTING", False), + ] + + +class AutotooolsBuilder(autotools.AutotoolsBuilder): def configure_args(self): - args = [] - args += self.enable_or_disable("sized-delete", variant="sized_delete") - args += self.enable_or_disable( - "dynamic-sized-delete-support", variant="dynamic_sized_delete_support" - ) - args += self.enable_or_disable("debugalloc") - args += self.enable_or_disable("libunwind") - if self.spec.satisfies("+libunwind"): - args += ["LDFLAGS=-lunwind"] - - return args + return [ + *self.enable_or_disable("sized-delete", variant="sized_delete"), + *self.enable_or_disable( + "dynamic-sized-delete-support", variant="dynamic_sized_delete_support" + ), + *self.enable_or_disable("debugalloc"), + *self.enable_or_disable("libunwind"), + ] diff --git a/var/spack/repos/builtin/packages/gpgme/package.py b/var/spack/repos/builtin/packages/gpgme/package.py index 6707d1fc3e1b24..b6e8dde011b411 100644 --- a/var/spack/repos/builtin/packages/gpgme/package.py +++ b/var/spack/repos/builtin/packages/gpgme/package.py @@ -21,6 +21,9 @@ class Gpgme(AutotoolsPackage): version("1.16.0", sha256="6c8cc4aedb10d5d4c905894ba1d850544619ee765606ac43df7405865de29ed0") version("1.12.0", sha256="b4dc951c3743a60e2e120a77892e9e864fb936b2e58e7c77e8581f4d050e8cd8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # https://dev.gnupg.org/T5509 - New test t-edit-sign test crashes with GCC 11.1.0 patch( "https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gpgme.git;a=commitdiff_plain;h=81a33ea5e1b86d586b956e893a5b25c4cd41c969;hp=e8e055e682f8994d62012574e1c8d862ca72a35d", diff --git a/var/spack/repos/builtin/packages/gpi-2/package.py b/var/spack/repos/builtin/packages/gpi-2/package.py index 16167b43d01e54..b4bb3fbe0389dd 100644 --- a/var/spack/repos/builtin/packages/gpi-2/package.py +++ b/var/spack/repos/builtin/packages/gpi-2/package.py @@ -37,6 +37,10 @@ class Gpi2(AutotoolsPackage): version("1.0.2", sha256="b03b4ac9f0715279b2a5e064fd85047cb640a85c2361d732930307f8bbf2aeb8") version("1.0.1", sha256="b1341bb39e7e70334d7acf831fe7f2061376e7516b44d18b31797748c2a169a3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=False, description="Enable Fortran modules") variant("mpi", default=False, description="Enable MPI support") variant( diff --git a/var/spack/repos/builtin/packages/gpi-space/package.py b/var/spack/repos/builtin/packages/gpi-space/package.py index 166e20c458c6bd..02e24a5052e1a0 100644 --- a/var/spack/repos/builtin/packages/gpi-space/package.py +++ b/var/spack/repos/builtin/packages/gpi-space/package.py @@ -35,6 +35,9 @@ class GpiSpace(CMakePackage): version("21.12", sha256="51794e2b593b8d1dc7d6310e17744842919bf44205b2cb7a79de2f2bbac3352a") version("21.09", sha256="7f3861c2bfec15a4da46378ea38b304e1462ed315cd315b81ab2c2a8ba50dd3e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "monitor", default=True, diff --git a/var/spack/repos/builtin/packages/gprofng-gui/package.py b/var/spack/repos/builtin/packages/gprofng-gui/package.py new file mode 100644 index 00000000000000..f1ba0823527f78 --- /dev/null +++ b/var/spack/repos/builtin/packages/gprofng-gui/package.py @@ -0,0 +1,29 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class GprofngGui(AutotoolsPackage): + """A graphical environment to analyze the performance data generated by the gprofng""" + + homepage = "https://sourceware.org/binutils/wiki/gprofng" + url = "https://ftp.gnu.org/gnu/gprofng-gui/gprofng-gui-1.1.tar.gz" + git = "https://git.savannah.gnu.org/git/gprofng-gui.git" + + maintainers("pramodk") + + license("GPL-3.0-only", checked_by="pramodk") + + version("develop", branch="master") + version("1.1", sha256="94fa577b856f00b89a2832771a265e221818b88dc0b36d8bca365efe6f08e12a") + version("1.0", sha256="c88da8ec91a9943636301fb7da9d337fe0851d874f8f7a4d2169bd859ee72dbc") + + depends_on("autoconf", type="build", when="@develop") + depends_on("automake", type="build", when="@develop") + depends_on("libtool", type="build", when="@develop") + + depends_on("java", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/gprolog/package.py b/var/spack/repos/builtin/packages/gprolog/package.py index 099e9b1af839ba..f8f9e5ec326d11 100644 --- a/var/spack/repos/builtin/packages/gprolog/package.py +++ b/var/spack/repos/builtin/packages/gprolog/package.py @@ -17,6 +17,8 @@ class Gprolog(Package): version("1.5.0", sha256="670642b43c0faa27ebd68961efb17ebe707688f91b6809566ddd606139512c01") version("1.4.5", sha256="bfdcf00e051e0628b4f9af9d6638d4fde6ad793401e58a5619d1cc6105618c7c") + depends_on("c", type="build") # generated + parallel = False def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/gptl/package.py b/var/spack/repos/builtin/packages/gptl/package.py index 76e89e1e643a1e..6fc1f2a6d24344 100644 --- a/var/spack/repos/builtin/packages/gptl/package.py +++ b/var/spack/repos/builtin/packages/gptl/package.py @@ -22,6 +22,9 @@ class Gptl(AutotoolsPackage): version("8.0.3", sha256="334979c6fe78d4ed1b491ec57fb61df7a910c58fd39a3658d03ad89f077a4db6") version("8.0.2", sha256="011f153084ebfb52b6bf8f190835d4bae6f6b5c0ad320331356aa47a547bf2b4") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("pmpi", default=False, description="Build with PMPI support to auto-profile MPI calls") variant("papi", default=False, description="Enable built-in support for papi library") variant("nestedomp", default=False, description="Build with nested OMP capability") diff --git a/var/spack/repos/builtin/packages/gptune/package.py b/var/spack/repos/builtin/packages/gptune/package.py index f7647367b21823..672cd3ab814bf9 100644 --- a/var/spack/repos/builtin/packages/gptune/package.py +++ b/var/spack/repos/builtin/packages/gptune/package.py @@ -24,6 +24,10 @@ class Gptune(CMakePackage): version("3.0.0", sha256="e19bfc3033fff11ff8c20cae65b88b7ca005d2c4e4db047f9f23226126ec92fa") version("2.1.0", sha256="737e0a1d83f66531098beafa73dd479f12def576be83b1c7b8ea5f1615d60a53") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("superlu", default=False, description="Build the SuperLU_DIST example") variant("hypre", default=False, description="Build the Hypre example") variant("mpispawn", default=True, description="MPI spawning-based interface") diff --git a/var/spack/repos/builtin/packages/gpu-burn/package.py b/var/spack/repos/builtin/packages/gpu-burn/package.py index b673b851a80a30..c53ff6707ef0e9 100644 --- a/var/spack/repos/builtin/packages/gpu-burn/package.py +++ b/var/spack/repos/builtin/packages/gpu-burn/package.py @@ -18,6 +18,8 @@ class GpuBurn(MakefilePackage, CudaPackage): version("1.1", sha256="9876dbf7ab17b3072e9bc657034ab39bdedb219478f57c4e93314c78ae2d6376") version("1.0", sha256="d55994f0bee8dabf021966dbe574ef52be1e43386faeee91318dd4ebb36aa74a") + depends_on("cxx", type="build") # generated + # This package uses CudaPackage to pick up the cuda_arch variant. A side # effect is that it also picks up the cuda variant, but cuda is required # for gpu-burn so is not really a variant. diff --git a/var/spack/repos/builtin/packages/gpuscout/package.py b/var/spack/repos/builtin/packages/gpuscout/package.py index 72fd4e6e8976f0..a4478cb9892e75 100644 --- a/var/spack/repos/builtin/packages/gpuscout/package.py +++ b/var/spack/repos/builtin/packages/gpuscout/package.py @@ -24,5 +24,7 @@ class Gpuscout(CMakePackage, CudaPackage): ) version("master", branch="master") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.27:", type="build") depends_on("cuda@12:") diff --git a/var/spack/repos/builtin/packages/gqrx/package.py b/var/spack/repos/builtin/packages/gqrx/package.py index cd47d34469a972..224f45f1ed99c7 100644 --- a/var/spack/repos/builtin/packages/gqrx/package.py +++ b/var/spack/repos/builtin/packages/gqrx/package.py @@ -26,6 +26,9 @@ class Gqrx(CMakePackage): license("GPL-3.0-or-later") version("2.13.1", sha256="08b7b930bed00c6ac79330695c24919a9d779112e1a3dd37d22cc9ee38561e82") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("cmake@3.2.0:", type="build") depends_on("gnuradio") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/gr-osmosdr/package.py b/var/spack/repos/builtin/packages/gr-osmosdr/package.py index 93b5389646743b..96618a67855595 100644 --- a/var/spack/repos/builtin/packages/gr-osmosdr/package.py +++ b/var/spack/repos/builtin/packages/gr-osmosdr/package.py @@ -37,6 +37,8 @@ class GrOsmosdr(CMakePackage): version("0.2.2", sha256="5a7ce7afee38a56191b5d16cb4a91c92476729ff16ed09cbba5a3851ac619713") + depends_on("cxx", type="build") # generated + depends_on("gnuradio") depends_on("swig", type="build") depends_on("hackrf-host", when="+hackrf") diff --git a/var/spack/repos/builtin/packages/grabix/package.py b/var/spack/repos/builtin/packages/grabix/package.py index 31f6d661eb293b..9d8b996d2aa849 100644 --- a/var/spack/repos/builtin/packages/grabix/package.py +++ b/var/spack/repos/builtin/packages/grabix/package.py @@ -23,6 +23,9 @@ class Grabix(MakefilePackage): version("0.1.7", sha256="d90735c55c0985a4d751858d7ce9e36ad534fff4103257e8e981e34d5c915b28") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + conflicts("%gcc@7:", msg="grabix cannot be compiled with newer versions of GCC") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/grace/package.py b/var/spack/repos/builtin/packages/grace/package.py index 5d36086c23874d..3da2aa95c9d100 100644 --- a/var/spack/repos/builtin/packages/grace/package.py +++ b/var/spack/repos/builtin/packages/grace/package.py @@ -20,6 +20,9 @@ class Grace(AutotoolsPackage): version("5.1.25", sha256="751ab9917ed0f6232073c193aba74046037e185d73b77bab0f5af3e3ff1da2ac") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("libx11") depends_on("libxext") depends_on("libxmu") diff --git a/var/spack/repos/builtin/packages/grads/package.py b/var/spack/repos/builtin/packages/grads/package.py index 70146e672095a9..a864ca1005dbf1 100644 --- a/var/spack/repos/builtin/packages/grads/package.py +++ b/var/spack/repos/builtin/packages/grads/package.py @@ -24,6 +24,8 @@ class Grads(AutotoolsPackage): version("2.2.2", sha256="1b5a600d4d407ffcf2fbbbba42037a6e1ebfdb8246ba56b93c628e3c472b4ded") version("2.2.1", sha256="695e2066d7d131720d598bac0beb61ac3ae5578240a5437401dc0ffbbe516206") + depends_on("c", type="build") # generated + variant("geotiff", default=True, description="Enable GeoTIFF support") variant("shapefile", default=True, description="Enable Shapefile support") variant("grib2", default=True, description="Enable GRIB2 support") @@ -63,10 +65,14 @@ def url_for_version(self, version): return url.format(version.up_to(2), version) # Name of grib2 C library has changed in recent versions - with when("+grib2"): + def patch(self): + if self.spec.satisfies("@:2.2.2"): + filter_file("png15", "png", "configure") - def patch(self): + if self.spec.satisfies("+grib2"): filter_file("grib2c", "g2c", "configure") + if self.spec.satisfies("^g2c@1.8.0:"): + filter_file("G2_VERSION", "G2C_VERSION", "src/gacfg.c") def setup_build_environment(self, env): env.set("SUPPLIBS", "/") diff --git a/var/spack/repos/builtin/packages/grafana/package.py b/var/spack/repos/builtin/packages/grafana/package.py index 37f3b730640439..49f1ee7784d2c8 100644 --- a/var/spack/repos/builtin/packages/grafana/package.py +++ b/var/spack/repos/builtin/packages/grafana/package.py @@ -21,6 +21,8 @@ class Grafana(Package): version("6.7.0", sha256="7f4e3f0d42b8188a334e97062c3bf63ff43af273095ba10147b299e3c1c5a7b7") version("6.6.2", sha256="e11e5971d08e45e277b55e060c0ce3cf25ca0ba144367c53b4836f2d133ed9b8") + depends_on("c", type="build") # generated + depends_on("go", type="build") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/grandr/package.py b/var/spack/repos/builtin/packages/grandr/package.py index 46cd8962fa1d03..af22fdce798fe5 100644 --- a/var/spack/repos/builtin/packages/grandr/package.py +++ b/var/spack/repos/builtin/packages/grandr/package.py @@ -14,6 +14,8 @@ class Grandr(AutotoolsPackage, XorgPackage): version("0.1", sha256="67a049c8dccdb48897efbd86c2b1d3b0ff5ce3c7859c46b0297d64c881b36d24") + depends_on("c", type="build") # generated + depends_on("gtkplus@2.0.0:") depends_on("gconf") depends_on("xrandr@1.2:") diff --git a/var/spack/repos/builtin/packages/graph500/package.py b/var/spack/repos/builtin/packages/graph500/package.py index e1a6131e885d24..c50344ff645edf 100644 --- a/var/spack/repos/builtin/packages/graph500/package.py +++ b/var/spack/repos/builtin/packages/graph500/package.py @@ -16,6 +16,8 @@ class Graph500(MakefilePackage): version("3.0.0", sha256="887dcff56999987fba4953c1c5696d50e52265fe61b6ffa8bb14cc69ff27e8a0") + depends_on("c", type="build") # generated + depends_on("mpi@2.0:") build_directory = "src" diff --git a/var/spack/repos/builtin/packages/graphblast/package.py b/var/spack/repos/builtin/packages/graphblast/package.py index e67fd0b906a26d..1144bc3b1d406e 100644 --- a/var/spack/repos/builtin/packages/graphblast/package.py +++ b/var/spack/repos/builtin/packages/graphblast/package.py @@ -23,6 +23,8 @@ class Graphblast(MakefilePackage, CudaPackage): preferred=True, ) + depends_on("cxx", type="build") # generated + variant("cuda", default=True, description="Build with Cuda support") depends_on("boost +program_options") diff --git a/var/spack/repos/builtin/packages/graphicsmagick/package.py b/var/spack/repos/builtin/packages/graphicsmagick/package.py index c84bde89b9b6e0..60a5e2123db093 100644 --- a/var/spack/repos/builtin/packages/graphicsmagick/package.py +++ b/var/spack/repos/builtin/packages/graphicsmagick/package.py @@ -20,6 +20,7 @@ class Graphicsmagick(AutotoolsPackage): license("MIT") + version("1.3.43", sha256="2b88580732cd7e409d9e22c6116238bef4ae06fcda11451bf33d259f9cbf399f") version("1.3.34", sha256="df009d5173ed0d6a0c6457234256c5a8aeaace782afa1cbab015d5a12bd4f7a4") version("1.3.33", sha256="130cb330a633580b5124eba5c125bbcbc484298423a97b9bed37ccd50d6dc778") version("1.3.32", sha256="b842a5a0d6c84fd6c5f161b5cd8e02bbd210b0c0b6728dd762b7c53062ba94e1") @@ -27,6 +28,9 @@ class Graphicsmagick(AutotoolsPackage): version("1.3.30", sha256="d965e5c6559f55eec76c20231c095d4ae682ea0cbdd8453249ae8771405659f1") version("1.3.29", sha256="e18df46a6934c8c12bfe274d09f28b822f291877f9c81bd9a506f879a7610cd4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("bzip2") depends_on("ghostscript") depends_on("ghostscript-fonts") diff --git a/var/spack/repos/builtin/packages/graphite2/package.py b/var/spack/repos/builtin/packages/graphite2/package.py index 10af88d825de9a..a1b69f5f49e498 100644 --- a/var/spack/repos/builtin/packages/graphite2/package.py +++ b/var/spack/repos/builtin/packages/graphite2/package.py @@ -22,6 +22,9 @@ class Graphite2(CMakePackage): version("1.3.14", sha256="f99d1c13aa5fa296898a181dff9b82fb25f6cc0933dbaa7a475d8109bd54209d") version("1.3.13", sha256="dd63e169b0d3cf954b397c122551ab9343e0696fb2045e1b326db0202d875f06") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.6:", type="test") depends_on("freetype") diff --git a/var/spack/repos/builtin/packages/graphlib/package.py b/var/spack/repos/builtin/packages/graphlib/package.py index 3f8026b0488ab3..4aef29a5249068 100644 --- a/var/spack/repos/builtin/packages/graphlib/package.py +++ b/var/spack/repos/builtin/packages/graphlib/package.py @@ -16,4 +16,6 @@ class Graphlib(CMakePackage): version("2.0.0", sha256="4f4aa1193167c41c8491dec3cf22b1e52a8f0842faab88b7945972f02d2adbcd") version("3.0.0", sha256="c3d889f7bc25b9662426605e52f14cd16f9c05b034738a343890707f5f5681f1") + depends_on("c", type="build") # generated + depends_on("cmake@2.6:", type="build") diff --git a/var/spack/repos/builtin/packages/graphmap/package.py b/var/spack/repos/builtin/packages/graphmap/package.py index 0d9ad07e81fc6a..1e572833c88406 100644 --- a/var/spack/repos/builtin/packages/graphmap/package.py +++ b/var/spack/repos/builtin/packages/graphmap/package.py @@ -16,6 +16,8 @@ class Graphmap(MakefilePackage): version("0.3.0", commit="eb8c75d68b03be95464318afa69b645a59f8f6b7") + depends_on("cxx", type="build") # generated + depends_on("zlib-api", type="link") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/graphviz/package.py b/var/spack/repos/builtin/packages/graphviz/package.py index 110746d9110359..7dc85e89815ec2 100644 --- a/var/spack/repos/builtin/packages/graphviz/package.py +++ b/var/spack/repos/builtin/packages/graphviz/package.py @@ -36,6 +36,9 @@ class Graphviz(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Language bindings language_bindings = ["java"] diff --git a/var/spack/repos/builtin/packages/grass/package.py b/var/spack/repos/builtin/packages/grass/package.py index 01adc4587bcddd..aa1414ea190263 100644 --- a/var/spack/repos/builtin/packages/grass/package.py +++ b/var/spack/repos/builtin/packages/grass/package.py @@ -28,6 +28,9 @@ class Grass(AutotoolsPackage): version("7.8.1", sha256="6ae578fd67afcce7abec4ba4505dcc55b3d2dfe0ca46b99d966cb148c654abb3") version("7.8.0", sha256="4b1192294e959ffd962282344e4ff325c4472f73abe605e246a1da3beda7ccfa") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cxx", default=True, description="Support C++ functionality") variant("tiff", default=False, description="Support TIFF functionality") variant("png", default=False, description="Support PNG functionality") diff --git a/var/spack/repos/builtin/packages/grep/package.py b/var/spack/repos/builtin/packages/grep/package.py index 5a08cad458257c..caeeb0bec89d29 100644 --- a/var/spack/repos/builtin/packages/grep/package.py +++ b/var/spack/repos/builtin/packages/grep/package.py @@ -20,6 +20,8 @@ class Grep(AutotoolsPackage): version("3.7", sha256="5c10da312460aec721984d5d83246d24520ec438dd48d7ab5a05dbc0d6d6823c") version("3.3", sha256="b960541c499619efd6afe1fa795402e4733c8e11ebf9fafccc0bb4bccdc5b514") + depends_on("c", type="build") # generated + variant("pcre", default=False, description="Enable Perl Compatible Regular Expression support") build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/grib-util/package.py b/var/spack/repos/builtin/packages/grib-util/package.py index 655c93d0a80aab..17b6cd32cb7bfc 100644 --- a/var/spack/repos/builtin/packages/grib-util/package.py +++ b/var/spack/repos/builtin/packages/grib-util/package.py @@ -18,10 +18,16 @@ class GribUtil(CMakePackage): maintainers("AlexanderRichert-NOAA", "Hang-Lei-NOAA", "edwardhartnett") version("develop", branch="develop") + version("1.4.0", tag="v1.4.0", commit="eeacc9ec93dfe6379f576191883c84a4a1202cc8") + version("1.3.0", commit="9d3c68a") version("1.2.4", sha256="f021d6df3186890b0b1781616dabf953581d71db63e7c2913360336985ccaec7") version("1.2.3", sha256="b17b08e12360bb8ad01298e615f1b4198e304b0443b6db35fe990a817e648ad5") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=False, description="Use OpenMP multithreading") + variant("tests", default=False, description="Enable this variant when installing with --test") depends_on("jasper") depends_on("libpng") @@ -30,15 +36,20 @@ class GribUtil(CMakePackage): requires("^w3emc precision=4,d", when="^w3emc@2.10:") depends_on("w3nco", when="@:1.2.3") depends_on("g2") + depends_on("g2@3.4.9:", when="@1.4:") + depends_on("g2c@1.8: +utils", when="+tests") depends_on("bacio") depends_on("ip") - depends_on("ip@:3.3.3", when="@:1.2.4") - depends_on("sp") + requires("^ip precision=d", when="^ip@4.1:") + depends_on("ip@:3.3.3", when="@:1.2") + depends_on("sp", when="^ip@:4") + requires("^sp precision=d", when="^ip@:4 ^sp@2.4:") def cmake_args(self): args = [ self.define_from_variant("OPENMP", "openmp"), self.define("BUILD_TESTING", self.run_tests), + self.define("G2C_COMPARE", self.run_tests), ] return args diff --git a/var/spack/repos/builtin/packages/grid/package.py b/var/spack/repos/builtin/packages/grid/package.py index 952d741b683676..ad782b35726701 100644 --- a/var/spack/repos/builtin/packages/grid/package.py +++ b/var/spack/repos/builtin/packages/grid/package.py @@ -19,6 +19,8 @@ class Grid(AutotoolsPackage): version("develop", branch="develop") + depends_on("cxx", type="build") # generated + variant( "comms", default="mpi", diff --git a/var/spack/repos/builtin/packages/gridlab-d/package.py b/var/spack/repos/builtin/packages/gridlab-d/package.py index aa3ecdcbd1f102..6f18648920d19e 100644 --- a/var/spack/repos/builtin/packages/gridlab-d/package.py +++ b/var/spack/repos/builtin/packages/gridlab-d/package.py @@ -24,6 +24,9 @@ class GridlabD(AutotoolsPackage): # Using only develop as other branches and releases did not build properly. version("develop", branch="develop") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mysql", default=False, description="Enable MySQL support for Gridlab-D.") variant("helics", default=False, description="Enable Helics support for Gridlab-D.") diff --git a/var/spack/repos/builtin/packages/groff/package.py b/var/spack/repos/builtin/packages/groff/package.py index c648b7e16be876..252bfe7e576ebc 100644 --- a/var/spack/repos/builtin/packages/groff/package.py +++ b/var/spack/repos/builtin/packages/groff/package.py @@ -6,7 +6,6 @@ import re from spack.package import * -from spack.util.environment import is_system_path class Groff(AutotoolsPackage, GNUMirrorPackage): @@ -22,9 +21,13 @@ class Groff(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-or-later") + version("1.23.0", sha256="6b9757f592b7518b4902eb6af7e54570bdccba37a871fddb2d30ae3863511c13") version("1.22.4", sha256="e78e7b4cb7dec310849004fa88847c44701e8d133b5d4c13057d876c1bad0293") version("1.22.3", sha256="3a48a9d6c97750bfbd535feeb5be0111db6406ddb7bb79fc680809cda6d828a5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # TODO: add html variant, spack doesn't have netpbm and its too # complicated for me to find out at this point in time. # See brew scripts for groff for guidance: @@ -80,10 +83,10 @@ def configure_args(self): args.extend(self.with_or_without("x")) if "@1.22.4:" in self.spec: args.extend(self.with_or_without("uchardet")) - if self.spec["iconv"].name == "libc": + if self.spec["iconv"].name == "libiconv": + args.append(f"--with-libiconv-prefix={self.spec['iconv'].prefix}") + else: args.append("--without-libiconv-prefix") - elif not is_system_path(self.spec["iconv"].prefix): - args.append("--with-libiconv-prefix={0}".format(self.spec["iconv"].prefix)) return args def setup_run_environment(self, env): diff --git a/var/spack/repos/builtin/packages/gromacs/package.py b/var/spack/repos/builtin/packages/gromacs/package.py index ed0e07b126d6cc..a8ede744d7c713 100644 --- a/var/spack/repos/builtin/packages/gromacs/package.py +++ b/var/spack/repos/builtin/packages/gromacs/package.py @@ -26,12 +26,17 @@ class Gromacs(CMakePackage, CudaPackage): url = "https://ftp.gromacs.org/gromacs/gromacs-2022.2.tar.gz" list_url = "https://ftp.gromacs.org/gromacs" git = "https://gitlab.com/gromacs/gromacs.git" - maintainers("danielahlin", "eirrgang", "junghans") + maintainers("mabraham", "eirrgang", "junghans") - license("BSD-2-Clause") + license("GPL-2.0-or-later", when="@:4.5") + license("LGPL-2.1-or-later", when="@4.6:") version("main", branch="main") version("master", branch="main", deprecated=True) + version("2024.2", sha256="802a7e335f2e895770f57b159e4ec368ebb0ff2ce6daccf706c6e8025c36852b") + version("2024.1", sha256="937d8f12a36fffbf2af7add71adbb5aa5c5537892d46c9a76afbecab1aa0aac7") + version("2024", sha256="04d226d52066a8bc3a42e00d6213de737b4ec292e26703065924ff01956801e2") + version("2023.5", sha256="9cc491d3601a5fe0ec0de727e4432c34877f596fe8a463d4cf0f0f53fb34d08b") version("2023.4", sha256="e5d6c4d9e7ccacfaccb0888619bd21b5ea8911f82b410e68d6db5d40f695f231") version("2023.3", sha256="4ec8f8d0c7af76b13f8fd16db8e2c120e749de439ae9554d9f653f812d78d1cb") version("2023.2", sha256="bce1480727e4b2bb900413b75d99a3266f3507877da4f5b2d491df798f9fcdae") @@ -84,6 +89,10 @@ class Gromacs(CMakePackage, CudaPackage): version("4.6.7", sha256="6afb1837e363192043de34b188ca3cf83db6bd189601f2001a1fc5b0b2a214d9") version("4.5.5", sha256="e0605e4810b0d552a8761fef5540c545beeaf85893f4a6e21df9905a33f871ba") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "mpi", default=True, description="Activate MPI support (disable for Thread-MPI support)" ) @@ -158,7 +167,7 @@ class Gromacs(CMakePackage, CudaPackage): "sve", default=True, description="Enable SVE on aarch64 if available", - when="target=neoverse_v1", + when="target=neoverse_v1:,neoverse_v2:", ) variant( "sve", default=True, description="Enable SVE on aarch64 if available", when="target=a64fx" @@ -222,15 +231,20 @@ class Gromacs(CMakePackage, CudaPackage): # Above dependencies can be verified, and new versions added, by going to # https://github.com/plumed/plumed2/tree/v2.9.0/patches # and switching tags. + + # Versions without minor release number, such as `2023` and `2021`, + # require exact specifcation using `@=`, starting from Spack v0.20.0, + # see https://github.com/spack/spack/releases/tag/v0.20.0 + plumed_patches = { - "2023": "2.9.0", + "=2023": "2.9.0", "2022.5": "2.8.2:2.9.0", "2022.3": "2.8.1", "2021.7": "2.8.2:2.9.0", "2021.6": "2.8.1", "2021.5": "2.7.5:2.7.6", "2021.4": "2.7.3:2.8.0", - "2021": "2.7.1:2.7.2", + "=2021": "2.7.1:2.7.2", "2020.7": "2.8.1:2.9.0", "2020.6": "2.7.2:2.8.0", "2020.5": "2.7.1", diff --git a/var/spack/repos/builtin/packages/grpc/package.py b/var/spack/repos/builtin/packages/grpc/package.py index 03bdb71303133f..ae6fb4ece2c47e 100644 --- a/var/spack/repos/builtin/packages/grpc/package.py +++ b/var/spack/repos/builtin/packages/grpc/package.py @@ -8,13 +8,16 @@ class Grpc(CMakePackage): """A high performance, open-source universal RPC framework.""" - maintainers("nazavode") - homepage = "https://grpc.io" - url = "https://github.com/grpc/grpc/archive/v1.39.0.tar.gz" + url = "https://github.com/grpc/grpc/archive/v1.59.1.tar.gz" license("Apache-2.0 AND BSD-3-Clause AND MIT") + version("1.64.0", sha256="d5509e40fb24f6390deeef8a88668124f4ec77d2ebb3b1a957b235a2f08b70c0") + version("1.63.0", sha256="493d9905aa09124c2f44268b66205dd013f3925a7e82995f36745974e97af609") + version("1.62.2", sha256="e5d5e0dd96fe9452fe24cc8c827381dca484c54d171fb512a198025fec81a3c8") + version("1.61.2", sha256="86f8773434c4b8a4b64c67c91a19a90991f0da0ba054bbeb299dc1bc95fad1e9") + version("1.59.1", sha256="916f88a34f06b56432611aaa8c55befee96d0a7b7d7457733b9deeacbc016f99") version("1.55.0", sha256="9cf1a69a921534ac0b760dcbefb900f3c2f735f56070bf0536506913bb5bfd74") version("1.50.0", sha256="76900ab068da86378395a8e125b5cc43dfae671e09ff6462ddfef18676e2165a") version("1.47.0", sha256="271bdc890bf329a8de5b65819f0f9590a5381402429bca37625b63546ed19e54") @@ -43,6 +46,9 @@ class Grpc(CMakePackage): version("1.24.3", sha256="c84b3fa140fcd6cce79b3f9de6357c5733a0071e04ca4e65ba5f8d306f10f033") version("1.23.1", sha256="dd7da002b15641e4841f20a1f3eb1e359edb69d5ccf8ac64c362823b05f523d9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=False, description="Build shared instead of static libraries") variant( "codegen", @@ -61,7 +67,12 @@ class Grpc(CMakePackage): depends_on("openssl") depends_on("zlib-api") depends_on("c-ares") - depends_on("abseil-cpp", when="@1.27:") + + with when("@1.27:"): + depends_on("abseil-cpp") + # missing includes: https://github.com/grpc/grpc/commit/bc044174401a0842b36b8682936fc93b5041cf88 + depends_on("abseil-cpp@:20230802", when="@:1.61") + depends_on("re2+pic@2023-09-01", when="@1.33.1:") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/gsettings-desktop-schemas/package.py b/var/spack/repos/builtin/packages/gsettings-desktop-schemas/package.py index 1056f36a105c64..53844022699f83 100644 --- a/var/spack/repos/builtin/packages/gsettings-desktop-schemas/package.py +++ b/var/spack/repos/builtin/packages/gsettings-desktop-schemas/package.py @@ -19,6 +19,8 @@ class GsettingsDesktopSchemas(MesonPackage): version("3.37.92", sha256="5f5dd0421ed2f3746674b8bb6e0c652784915133c7f2d133339bf5e4140d8d1d") version("3.37.2", sha256="1dacdfeecfc57468da7c598a01b635f82ecd088e1d78d5aa840e47256026654d") + depends_on("c", type="build") # generated + depends_on("glib") depends_on("gobject-introspection", type="build") depends_on("gettext", type="build") diff --git a/var/spack/repos/builtin/packages/gsi-ncdiag/package.py b/var/spack/repos/builtin/packages/gsi-ncdiag/package.py index f25498a04acfbd..ac183664409ede 100644 --- a/var/spack/repos/builtin/packages/gsi-ncdiag/package.py +++ b/var/spack/repos/builtin/packages/gsi-ncdiag/package.py @@ -19,6 +19,8 @@ class GsiNcdiag(CMakePackage): version("1.1.0", sha256="9195801301209d6f93890944d58ffee4e24a4e35502ab27560a8c440ee53df4c") version("1.0.0", sha256="7251d6139c2bc1580db5f7f019e10a4c73d188ddd52ccf21ecc9e39d50a6af51") + depends_on("fortran", type="build") # generated + variant("serial", default=True, description="Enable Serial NetCDF diagnostics") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/gsibec/package.py b/var/spack/repos/builtin/packages/gsibec/package.py index 9028bc315aa2a1..3a83af239965d4 100644 --- a/var/spack/repos/builtin/packages/gsibec/package.py +++ b/var/spack/repos/builtin/packages/gsibec/package.py @@ -20,6 +20,7 @@ class Gsibec(CMakePackage): license("Apache-2.0") version("develop", branch="develop") + version("1.2.1", sha256="83bf12ad6603d66e2e48b50cfcb57b7acd64e0d428a597a842db978a3277baf6") version("1.1.3", sha256="9cac000562250487c16608e8245d97457cc1663b1793b3833be5a76ebccb4b47") version("1.1.2", sha256="8bdcdf1663e6071b6ad9e893a76307abc70a6de744fb75a13986e70242993ada") version("1.0.7", sha256="53912f1f19d46f4941b377803cc2fce89a2b50d2ece7562f8fd65215a8908158") @@ -29,6 +30,8 @@ class Gsibec(CMakePackage): version("1.0.3", sha256="f104daf55705c5093a3d984073f082017bc9166f51ded36c7f7bb8adf233c916") version("1.0.2", sha256="7dc02f1f499e0d9f2843440f517d6c8e5d10ea084cbb2567ec198ba06816bc8b") + depends_on("fortran", type="build") # generated + depends_on("mpi", type=("build", "run")) depends_on("netcdf-c +mpi", type=("build", "run")) depends_on("netcdf-fortran", type=("build", "run")) @@ -43,6 +46,6 @@ def cmake_args(self): args = [] mkl_providers = ["intel-mkl", "intel-oneapi-mkl", "intel-parallel-studio"] - args.append(self.define("ENABLE_MKL", spec["lapack"].name in mkl_providers)) + args.append(self.define("ENABLE_MKL", self.spec["lapack"].name in mkl_providers)) return args diff --git a/var/spack/repos/builtin/packages/gsl-lite/package.py b/var/spack/repos/builtin/packages/gsl-lite/package.py index a4084e84347bc0..38df082f16e98d 100644 --- a/var/spack/repos/builtin/packages/gsl-lite/package.py +++ b/var/spack/repos/builtin/packages/gsl-lite/package.py @@ -28,6 +28,8 @@ class GslLite(CMakePackage): version("0.36.0", sha256="c052cc4547b33cedee6f000393a7005915c45c6c06b35518d203db117f75c71c") version("0.34.0", sha256="a7d5b2672b78704ca03df9ef65bc274d8f8cacad3ca950365eef9e25b50324c5") + depends_on("cxx", type="build") # generated + variant("tests", default=False, description="Build and perform gsl-lite tests") variant("cuda_tests", default=False, description="Build and perform gsl-lite CUDA tests") variant("examples", default=False, description="Build gsl-lite examples") diff --git a/var/spack/repos/builtin/packages/gsl/package.py b/var/spack/repos/builtin/packages/gsl/package.py index 1c4732e1604588..2a9b83c80a17d9 100644 --- a/var/spack/repos/builtin/packages/gsl/package.py +++ b/var/spack/repos/builtin/packages/gsl/package.py @@ -30,6 +30,8 @@ class Gsl(AutotoolsPackage, GNUMirrorPackage): version("2.0", sha256="e361f0b19199b5e6c21922e9f16adf7eca8dd860842802424906d0f83485ca2d") version("1.16", sha256="73bc2f51b90d2a780e6d266d43e487b3dbd78945dd0b04b14ca5980fe28d2f53") + depends_on("c", type="build") # generated + variant("external-cblas", default=False, description="Build against external blas") variant("shared", default=True, description="Build shared library") variant("pic", default=True, description="Enable position-independent code (PIC)") diff --git a/var/spack/repos/builtin/packages/gslib/package.py b/var/spack/repos/builtin/packages/gslib/package.py index b8658064445fcf..65d9e9fdbbf9f1 100644 --- a/var/spack/repos/builtin/packages/gslib/package.py +++ b/var/spack/repos/builtin/packages/gslib/package.py @@ -22,6 +22,9 @@ class Gslib(Package): version("1.0.1", tag="v1.0.1", commit="d16685f24551b7efd69e58d96dc76aec75239ea3") version("1.0.0", tag="v1.0.0", commit="9533e652320a3b26a72c36487ae265b02072cd48") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Build with MPI") variant("mpiio", default=True, description="Build with MPI I/O") variant("blas", default=False, description="Build with BLAS") diff --git a/var/spack/repos/builtin/packages/gtfsort/package.py b/var/spack/repos/builtin/packages/gtfsort/package.py new file mode 100644 index 00000000000000..e74a3ae772e3d3 --- /dev/null +++ b/var/spack/repos/builtin/packages/gtfsort/package.py @@ -0,0 +1,17 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Gtfsort(CargoPackage): + """A chr/pos/feature GTF sorter that uses a lexicographically-based index ordering algorithm""" + + homepage = "https://github.com/alejandrogzi/gtfsort" + url = "https://github.com/alejandrogzi/gtfsort/archive/refs/tags/v.0.2.2.tar.gz" + + license("MIT", checked_by="A_N_Other") + + version("0.2.2", sha256="d22a8ef32e30111ad2dd08d1da0e0914ac62a728483b8e39a4ef8ea4e6133b4f") diff --git a/var/spack/repos/builtin/packages/gtk-doc/package.py b/var/spack/repos/builtin/packages/gtk-doc/package.py index 470836b317ce4c..014cb2780589dd 100644 --- a/var/spack/repos/builtin/packages/gtk-doc/package.py +++ b/var/spack/repos/builtin/packages/gtk-doc/package.py @@ -22,6 +22,8 @@ class GtkDoc(AutotoolsPackage): version("1.33.2", sha256="2d1b0cbd26edfcb54694b2339106a02a81d630a7dedc357461aeb186874cc7c0") version("1.32", sha256="0890c1f00d4817279be51602e67c4805daf264092adc58f9c04338566e8225ba") + depends_on("c", type="build") # generated + # Commented out until package dblatex has been created # variant('pdf', default=False, description='Adds PDF support') diff --git a/var/spack/repos/builtin/packages/gtkmm/package.py b/var/spack/repos/builtin/packages/gtkmm/package.py index eeddcc70e59e6f..924334c9cb3e45 100644 --- a/var/spack/repos/builtin/packages/gtkmm/package.py +++ b/var/spack/repos/builtin/packages/gtkmm/package.py @@ -23,6 +23,8 @@ class Gtkmm(AutotoolsPackage): version("2.16.0", sha256="7b2cccda794531ecfa65c01e57614ecba526153ad2a29d580c6e8df028d56ec4") version("2.4.11", sha256="0754187a5bcf3795cd7c959de303e6a19a130b0c5927bff1504baa3524bee8c1") + depends_on("cxx", type="build") # generated + depends_on("glibmm") depends_on("atk") depends_on("gtkplus") diff --git a/var/spack/repos/builtin/packages/gtkorvo-atl/package.py b/var/spack/repos/builtin/packages/gtkorvo-atl/package.py index a748baf9b9bef5..2c5363e735514f 100644 --- a/var/spack/repos/builtin/packages/gtkorvo-atl/package.py +++ b/var/spack/repos/builtin/packages/gtkorvo-atl/package.py @@ -15,10 +15,14 @@ class GtkorvoAtl(CMakePackage): url = "https://github.com/GTkorvo/atl/archive/v2.1.tar.gz" git = "https://github.com/GTkorvo/atl.git" - version("develop", branch="master") + version("master", branch="master") + version("develop", branch="master", deprecated=True) + version("2.2.1", sha256="7ff2dca93702ed56e3bbfd8eb52da3bb5f0e7bef5006f3ca29aaa468cab89037") version("2.2", sha256="d88b6eaa3926e499317973bfb2ae469c584bb064da198217ea5fede6d919e160") version("2.1", sha256="379b493ba867b76d76eabfe5bfeec85239606e821509c31e8eb93c2dc238e4a8") + depends_on("c", type="build") # generated + depends_on("gtkorvo-cercs-env") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/gtkorvo-cercs-env/package.py b/var/spack/repos/builtin/packages/gtkorvo-cercs-env/package.py index 638202b428e0c3..9b0a5fafaa7d6b 100644 --- a/var/spack/repos/builtin/packages/gtkorvo-cercs-env/package.py +++ b/var/spack/repos/builtin/packages/gtkorvo-cercs-env/package.py @@ -16,6 +16,8 @@ class GtkorvoCercsEnv(CMakePackage): version("develop", branch="master") version("1.0", sha256="e4080a98c1af5003a038361c8bb343843665cac428101ac7d721bad8ba7d244e") + depends_on("c", type="build") # generated + def cmake_args(self): args = ["-DENABLE_TESTING=0", "-DENABLE_SHARED_STATIC=STATIC"] return args diff --git a/var/spack/repos/builtin/packages/gtkorvo-dill/package.py b/var/spack/repos/builtin/packages/gtkorvo-dill/package.py index 0cd813d6e250dd..07095b70de8dc2 100644 --- a/var/spack/repos/builtin/packages/gtkorvo-dill/package.py +++ b/var/spack/repos/builtin/packages/gtkorvo-dill/package.py @@ -20,6 +20,9 @@ class GtkorvoDill(CMakePackage): version("2.4", sha256="ed7745d13e8c6a556f324dcc0e48a807fc993bdd5bb1daa94c1df116cb7e81fa") version("2.1", sha256="7671e1f3c25ac6a4ec2320cec2c342a2f668efb170e3dba186718ed17d2cf084") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Ref: https://github.com/GTkorvo/dill/commit/dac6dfcc7fdaceeb4c157f9ecdf5ecc28f20477f patch("2.4-fix-clear_cache.patch", when="@2.4") patch("2.1-fix-clear_cache.patch", when="@2.1") diff --git a/var/spack/repos/builtin/packages/gtkorvo-enet/package.py b/var/spack/repos/builtin/packages/gtkorvo-enet/package.py index 640479d6d5526a..c805aa0dc3b8e3 100644 --- a/var/spack/repos/builtin/packages/gtkorvo-enet/package.py +++ b/var/spack/repos/builtin/packages/gtkorvo-enet/package.py @@ -20,3 +20,5 @@ class GtkorvoEnet(AutotoolsPackage): version("1.3.14", sha256="d1fda051bdee46ad8cce7c3bb36fb6b7a7a443945f27a280ac104753c29465b0") version("1.3.13", sha256="ede6e4f03e4cb0c3d93044ace9e8c1818ef4d3ced4aaa70384155769b3c436dc") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/gtkplus/package.py b/var/spack/repos/builtin/packages/gtkplus/package.py index 846ed52df833f7..4c7bd0fdd1b105 100644 --- a/var/spack/repos/builtin/packages/gtkplus/package.py +++ b/var/spack/repos/builtin/packages/gtkplus/package.py @@ -39,6 +39,9 @@ class Gtkplus(MesonPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cups", default=False, description="enable cups support") # See meson.build for version requirements diff --git a/var/spack/repos/builtin/packages/gtksourceview/package.py b/var/spack/repos/builtin/packages/gtksourceview/package.py index d9607d34a5263d..14d60531a12dc1 100644 --- a/var/spack/repos/builtin/packages/gtksourceview/package.py +++ b/var/spack/repos/builtin/packages/gtksourceview/package.py @@ -23,6 +23,10 @@ class Gtksourceview(AutotoolsPackage): version("4.2.0", sha256="c431eb234dc83c7819e58f77dd2af973252c7750da1c9d125ddc94268f94f675") version("3.24.11", sha256="691b074a37b2a307f7f48edc5b8c7afa7301709be56378ccf9cc9735909077fd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/gts/package.py b/var/spack/repos/builtin/packages/gts/package.py index a5883016d9b5d7..490e85d00dd599 100644 --- a/var/spack/repos/builtin/packages/gts/package.py +++ b/var/spack/repos/builtin/packages/gts/package.py @@ -28,5 +28,7 @@ class Gts(AutotoolsPackage): version("121130", sha256="c23f72ab74bbf65599f8c0b599d6336fabe1ec2a09c19b70544eeefdc069b73b") + depends_on("c", type="build") # generated + depends_on("glib") depends_on("pkgconfig", type=("build")) diff --git a/var/spack/repos/builtin/packages/guacamole-server/package.py b/var/spack/repos/builtin/packages/guacamole-server/package.py index 39f0e19bebb84e..42ac61c9256a40 100644 --- a/var/spack/repos/builtin/packages/guacamole-server/package.py +++ b/var/spack/repos/builtin/packages/guacamole-server/package.py @@ -18,6 +18,8 @@ class GuacamoleServer(AutotoolsPackage): version("1.1.0", sha256="d0f0c66ebfa7a4fd6689ae5240f21797b5177945a042388b691b15b8bd5c81a8") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/guile/package.py b/var/spack/repos/builtin/packages/guile/package.py index 2103145fef9362..24b73341fbac6e 100644 --- a/var/spack/repos/builtin/packages/guile/package.py +++ b/var/spack/repos/builtin/packages/guile/package.py @@ -25,6 +25,8 @@ class Guile(AutotoolsPackage, GNUMirrorPackage): version("2.0.14", sha256="8aeb2f353881282fe01694cce76bb72f7ffdd296a12c7a1a39255c27b0dfe5f1") version("2.0.11", sha256="e6786c934346fa2e38e46d8d81a622bb1c16d130153523f6129fcd79ef1fb040") + depends_on("c", type="build") # generated + variant("readline", default=True, description="Use the readline library") variant( "threads", diff --git a/var/spack/repos/builtin/packages/gunrock/package.py b/var/spack/repos/builtin/packages/gunrock/package.py index 19813e6d199fb1..5cdfa5f3a247f2 100644 --- a/var/spack/repos/builtin/packages/gunrock/package.py +++ b/var/spack/repos/builtin/packages/gunrock/package.py @@ -33,6 +33,9 @@ class Gunrock(CMakePackage, CudaPackage): version("0.2", submodules=True, tag="v0.2", commit="f9d85343ee68c65567184d74021b9483cd142ea0") version("0.1", submodules=True, tag="v0.1", commit="4c00284f6b7d490a83fa7afe5cdff60923316448") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cuda", default=True, description="Build with Cuda support") variant("lib", default=True, description="Build main gunrock library") diff --git a/var/spack/repos/builtin/packages/gurobi/package.py b/var/spack/repos/builtin/packages/gurobi/package.py index c0fa33639df9f2..d9dd35c2ed75ed 100644 --- a/var/spack/repos/builtin/packages/gurobi/package.py +++ b/var/spack/repos/builtin/packages/gurobi/package.py @@ -57,5 +57,4 @@ def install(self, spec, prefix): @run_after("install") def gurobipy(self): with working_dir("linux64"): - python = which("python") python("setup.py", "install", "--prefix={0}".format(self.prefix)) diff --git a/var/spack/repos/builtin/packages/gxsview/package.py b/var/spack/repos/builtin/packages/gxsview/package.py index ea45246d1c6f6a..a0418477527625 100644 --- a/var/spack/repos/builtin/packages/gxsview/package.py +++ b/var/spack/repos/builtin/packages/gxsview/package.py @@ -3,6 +3,8 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os + from spack.package import * @@ -51,11 +53,25 @@ def qmake_args(self): vtk_suffix = self.spec["vtk"].version.up_to(2) vtk_lib_dir = self.spec["vtk"].prefix.lib vtk_include_dir = join_path(self.spec["vtk"].prefix.include, "vtk-{0}".format(vtk_suffix)) - args = [ - "VTK_LIB_DIR={0}".format(vtk_lib_dir), - "VTK_INC_DIR={0}".format(vtk_include_dir), - "VTK_MAJOR_VER={0}".format(str(vtk_suffix)), - ] + args = [] + if not os.path.exists(vtk_include_dir): + vtk_include_dir = join_path(self.spec["vtk"].prefix.include, "vtk") + args.append("VTK_NO_VER_SUFFIX=ON") + args.extend( + [ + "VTK_LIB_DIR={0}".format(vtk_lib_dir), + "VTK_INC_DIR={0}".format(vtk_include_dir), + "VTK_MAJOR_VER={0}".format(str(vtk_suffix)), + ] + ) + # Below to avoid undefined reference to `std::filesystem::__cxx11::path::_M_split_cmpts()' + if self.spec.satisfies("%gcc@8.0:8.9") or self.spec.satisfies("%fj"): + if "^vtk@9:" in self.spec: + fic = "vtk9.pri" + else: + fic = "vtk8.pri" + with open(fic, "a") as fh: + fh.write("-lstdc++fs\n") return args def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/gzip/package.py b/var/spack/repos/builtin/packages/gzip/package.py index 11d8f898450531..2a8978907604a3 100644 --- a/var/spack/repos/builtin/packages/gzip/package.py +++ b/var/spack/repos/builtin/packages/gzip/package.py @@ -31,5 +31,7 @@ class Gzip(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + # Gzip makes a recursive symlink if built in-source build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/h5bench/package.py b/var/spack/repos/builtin/packages/h5bench/package.py index c367bbaf8ebae7..0c1b9568ba4e42 100644 --- a/var/spack/repos/builtin/packages/h5bench/package.py +++ b/var/spack/repos/builtin/packages/h5bench/package.py @@ -33,6 +33,10 @@ class H5bench(CMakePackage): "1.0", commit="9d3438c1bc66c5976279ef203bd11a8d48ade724", submodules=True, deprecated=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("metadata", default=False, when="@1.2:", description="Enables metadata benchmark") variant("amrex", default=False, when="@1.2:", description="Enables AMReX benchmark") variant("exerciser", default=False, when="@1.2:", description="Enables exerciser benchmark") diff --git a/var/spack/repos/builtin/packages/h5cpp/package.py b/var/spack/repos/builtin/packages/h5cpp/package.py index 9d793f32ebf367..5e299f062a804a 100644 --- a/var/spack/repos/builtin/packages/h5cpp/package.py +++ b/var/spack/repos/builtin/packages/h5cpp/package.py @@ -21,6 +21,9 @@ class H5cpp(CMakePackage): version("1.10.4-6", sha256="4fbc8e777dc78a37ec2fe8c7b6a47114080ffe587f083e83a2046b5e794aef93") version("1.10.4-5", sha256="661ccc4d76e081afc73df71ef11d027837d92dd1089185f3650afcaec9d418ec") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Include MPI support") depends_on("cmake @3.10:", type="build") diff --git a/var/spack/repos/builtin/packages/h5hut/package.py b/var/spack/repos/builtin/packages/h5hut/package.py index 35aa847b0f4642..cfef678975db2f 100644 --- a/var/spack/repos/builtin/packages/h5hut/package.py +++ b/var/spack/repos/builtin/packages/h5hut/package.py @@ -19,6 +19,10 @@ class H5hut(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=True, description="Enable Fortran support") variant("mpi", default=True, description="Enable MPI support") diff --git a/var/spack/repos/builtin/packages/h5utils/package.py b/var/spack/repos/builtin/packages/h5utils/package.py index 93a38c3c8e5659..7818d5bfb50817 100644 --- a/var/spack/repos/builtin/packages/h5utils/package.py +++ b/var/spack/repos/builtin/packages/h5utils/package.py @@ -23,6 +23,9 @@ class H5utils(AutotoolsPackage): url="https://github.com/NanoComp/h5utils/archive/refs/tags/1.12.1.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("png", default=True, description="Enable PNG support") variant("vis5d", default=False, description="Enable Vis5d support") variant("octave", default=False, description="Enable GNU Octave support") diff --git a/var/spack/repos/builtin/packages/h5z-zfp/package.py b/var/spack/repos/builtin/packages/h5z-zfp/package.py index a9c1f86974b19f..237137b7c8e6bf 100644 --- a/var/spack/repos/builtin/packages/h5z-zfp/package.py +++ b/var/spack/repos/builtin/packages/h5z-zfp/package.py @@ -20,6 +20,9 @@ class H5zZfp(CMakePackage): version("1.1.1", sha256="921af7b9d1c8c46c036b46544f2785f69d405c0701abe1c1ce3aca2bd5899171") version("1.1.0", sha256="48a81e69d1f3b61d9a1eb07e868164fadf3b88690ec930efd849f5889681a893") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=True, description="Enable Fortran support") depends_on("hdf5+fortran", when="+fortran") diff --git a/var/spack/repos/builtin/packages/haccabana/package.py b/var/spack/repos/builtin/packages/haccabana/package.py index bce59ef2ba663c..df24131f5de97b 100644 --- a/var/spack/repos/builtin/packages/haccabana/package.py +++ b/var/spack/repos/builtin/packages/haccabana/package.py @@ -23,6 +23,8 @@ class Haccabana(CMakePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") depends_on("cmake@3.9:", type="build") diff --git a/var/spack/repos/builtin/packages/hacckernels/package.py b/var/spack/repos/builtin/packages/hacckernels/package.py index 01bae2a3866593..5f0c02b4cb6d25 100644 --- a/var/spack/repos/builtin/packages/hacckernels/package.py +++ b/var/spack/repos/builtin/packages/hacckernels/package.py @@ -22,6 +22,8 @@ class Hacckernels(CMakePackage): version("develop", branch="master") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("README", prefix) diff --git a/var/spack/repos/builtin/packages/hackrf-host/package.py b/var/spack/repos/builtin/packages/hackrf-host/package.py index 6a02fa73a262a6..319bcb0c1677ff 100644 --- a/var/spack/repos/builtin/packages/hackrf-host/package.py +++ b/var/spack/repos/builtin/packages/hackrf-host/package.py @@ -22,6 +22,8 @@ class HackrfHost(CMakePackage): version("2018.01.1", sha256="84dbb5536d3aa5bd6b25d50df78d591e6c3431d752de051a17f4cb87b7963ec3") + depends_on("c", type="build") # generated + depends_on("cmake@2.8.12:", type="build") depends_on("libusb@1.0.18:") depends_on("fftw@3.3.5:") diff --git a/var/spack/repos/builtin/packages/hadoop-xrootd/package.py b/var/spack/repos/builtin/packages/hadoop-xrootd/package.py index 439301c38ecf87..fe15a4acedec66 100644 --- a/var/spack/repos/builtin/packages/hadoop-xrootd/package.py +++ b/var/spack/repos/builtin/packages/hadoop-xrootd/package.py @@ -18,6 +18,8 @@ class HadoopXrootd(MavenPackage): version("1.0.7", sha256="9a129dc14b3dc139aa4da7543f6392a5c80b41fea6bb9f6cd27db5acf6f5471f") + depends_on("cxx", type="build") # generated + depends_on("hadoop") depends_on("xrootd") conflicts("%clang") diff --git a/var/spack/repos/builtin/packages/hadoop/package.py b/var/spack/repos/builtin/packages/hadoop/package.py index d3d1212f45a0dd..6d34ce298fd9bc 100644 --- a/var/spack/repos/builtin/packages/hadoop/package.py +++ b/var/spack/repos/builtin/packages/hadoop/package.py @@ -29,6 +29,8 @@ class Hadoop(Package): version("2.7.7", sha256="d129d08a2c9dafec32855a376cbd2ab90c6a42790898cabbac6be4d29f9c2026") version("2.7.5", sha256="0bfc4d9b04be919be2fdf36f67fa3b4526cdbd406c512a7a1f5f1b715661f831") + depends_on("cxx", type="build") # generated + depends_on("java", type="run") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/hal/package.py b/var/spack/repos/builtin/packages/hal/package.py index 06461380fb5b73..8fc8ec46039e41 100644 --- a/var/spack/repos/builtin/packages/hal/package.py +++ b/var/spack/repos/builtin/packages/hal/package.py @@ -21,6 +21,9 @@ class Hal(MakefilePackage): version("2.1", sha256="540255be1af55abf390359fe034b82d7e61bdf6c3277df3cc01259cd450994e5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + maintainers("ilbiondo") # HAL expects to be compiled alongside sonlib so we need both the diff --git a/var/spack/repos/builtin/packages/halide/package.py b/var/spack/repos/builtin/packages/halide/package.py index 282fda87331a8e..2a4f1448ec2ddf 100644 --- a/var/spack/repos/builtin/packages/halide/package.py +++ b/var/spack/repos/builtin/packages/halide/package.py @@ -19,6 +19,12 @@ class Halide(CMakePackage, PythonExtension): version("main", branch="main") version("15.0.0", sha256="6680424f80c5731a85d977c06327096afe5af31da3667e91d4d36a25fabdda15") version("14.0.0", sha256="f9fc9765217cbd10e3a3e3883a60fc8f2dbbeaac634b45c789577a8a87999a01") + version("16.0.0", sha256="a0cccee762681ea697124b8172dd65595856d0fa5bd4d1af7933046b4a085b04") + version("17.0.0", sha256="7e5a526b4074887b528d25b0265ddfa92c0a6d8bfdfbbba536313ecddf352da3") + version("17.0.1", sha256="beb18331d9e4b6f69943bcc75fb9d923a250ae689f09f6940a01636243289727") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated variant( "build_type", default="Release", @@ -58,8 +64,10 @@ class Halide(CMakePackage, PythonExtension): depends_on("cmake@3.22:", type="build") depends_on("llvm+clang+lld build_type=Release", type=("link", "run")) - depends_on("llvm@13.0.0:15", type=("link", "run"), when="@14.0.0") - depends_on("llvm@14.0.0:16", type=("link", "run"), when="@15.0.0:") + depends_on("llvm@14.0.0:14", type=("link", "run"), when="@14.0.0:14") + depends_on("llvm@15.0.0:15", type=("link", "run"), when="@15.0.0:15") + depends_on("llvm@16.0.0:16", type=("link", "run"), when="@16.0.0:16") + depends_on("llvm@17.0.0:17", type=("link", "run"), when="@17.0.0:17") for v in _values: depends_on( "llvm targets={0}".format(v), type=("link", "run"), when="targets={0}".format(v) diff --git a/var/spack/repos/builtin/packages/hapcut2/package.py b/var/spack/repos/builtin/packages/hapcut2/package.py index 620f297cd66185..c9a5635761b077 100644 --- a/var/spack/repos/builtin/packages/hapcut2/package.py +++ b/var/spack/repos/builtin/packages/hapcut2/package.py @@ -25,6 +25,8 @@ class Hapcut2(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("htslib@1.3:") depends_on("curl") depends_on("openssl") diff --git a/var/spack/repos/builtin/packages/haproxy/package.py b/var/spack/repos/builtin/packages/haproxy/package.py index b887c3d090e8e2..23ad029ae8c50c 100644 --- a/var/spack/repos/builtin/packages/haproxy/package.py +++ b/var/spack/repos/builtin/packages/haproxy/package.py @@ -15,9 +15,12 @@ class Haproxy(MakefilePackage): homepage = "https://www.haproxy.org" url = "https://www.haproxy.org/download/2.1/src/haproxy-2.1.0.tar.gz" + version("2.1.12", sha256="acebbf932f2703ee287d6e945bd845cde8c9db9a13f7cbb2a99671499c558056") version("2.1.1", sha256="57e75c1a380fc6f6aa7033f71384370899443c7f4e8a4ba289b5d4350bc76d1a") version("2.1.0", sha256="f268efb360a0e925137b4b8ed431f2f8f3b68327efb2c418b266e535d8e335a0") + depends_on("c", type="build") # generated + def url_for_version(self, version): url = "https://www.haproxy.org/download/{0}/src/haproxy-{1}.tar.gz" return url.format(version.up_to(2), version) diff --git a/var/spack/repos/builtin/packages/hardlink/package.py b/var/spack/repos/builtin/packages/hardlink/package.py index 66e0cbbf0b3b09..a84b18e9795b2a 100644 --- a/var/spack/repos/builtin/packages/hardlink/package.py +++ b/var/spack/repos/builtin/packages/hardlink/package.py @@ -15,5 +15,7 @@ class Hardlink(MakefilePackage): version("0.1.1", sha256="5876554e6dafb6627a94670ac33e750a7efeb3a5fbde5ede3e145cdb5131d1ba") version("0.1", sha256="72f8a07b0dfe30a77da576b8dff5998c5f7e054052382fd61ac46157a5e039db") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make("PREFIX={0}".format(prefix), "install-homebrew") diff --git a/var/spack/repos/builtin/packages/harfbuzz/package.py b/var/spack/repos/builtin/packages/harfbuzz/package.py index e0b6e3914129c4..d5d2a068365b0f 100644 --- a/var/spack/repos/builtin/packages/harfbuzz/package.py +++ b/var/spack/repos/builtin/packages/harfbuzz/package.py @@ -20,6 +20,9 @@ class Harfbuzz(MesonPackage, AutotoolsPackage): license("MIT") + version("9.0.0", sha256="a41b272ceeb920c57263ec851604542d9ec85ee3030506d94662067c7b6ab89e") + version("8.5.0", sha256="77e4f7f98f3d86bf8788b53e6832fb96279956e1c3961988ea3d4b7ca41ddc27") + version("8.4.0", sha256="af4ea73e25ab748c8c063b78c2f88e48833db9b2ac369e29bd115702e789755e") version("8.3.0", sha256="109501eaeb8bde3eadb25fab4164e993fbace29c3d775bcaa1c1e58e2f15f847") version("7.3.0", sha256="20770789749ac9ba846df33983dbda22db836c70d9f5d050cb9aa5347094a8fb") version("7.2.0", sha256="fc5560c807eae0efd5f95b5aa4c65800c7a8eed6642008a6b1e7e3ffff7873cc") @@ -69,6 +72,9 @@ class Harfbuzz(MesonPackage, AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("graphite2", default=False, description="enable support for graphite2 font engine") variant( "coretext", @@ -91,7 +97,7 @@ class Harfbuzz(MesonPackage, AutotoolsPackage): ) def url_for_version(self, version): - if version > Version("2.3.1"): + if self.spec.satisfies("@2.3.2:"): url = "https://github.com/harfbuzz/harfbuzz/releases/download/{0}/harfbuzz-{0}.tar.xz" else: url = "http://www.freedesktop.org/software/harfbuzz/release/harfbuzz-{0}.tar.bz2" @@ -115,6 +121,7 @@ def setup_dependent_run_environment(self, env, dependent_spec): env.prepend_path("XDG_DATA_DIRS", self.prefix.share) env.prepend_path("GI_TYPELIB_PATH", join_path(self.prefix.lib, "girepository-1.0")) + @when("@:8") def patch(self): change_sed_delimiter("@", ";", "src/Makefile.in") diff --git a/var/spack/repos/builtin/packages/harminv/package.py b/var/spack/repos/builtin/packages/harminv/package.py index 3bff34a9197da9..dcd2bfa7256efc 100644 --- a/var/spack/repos/builtin/packages/harminv/package.py +++ b/var/spack/repos/builtin/packages/harminv/package.py @@ -21,6 +21,8 @@ class Harminv(AutotoolsPackage): version("1.4.2", sha256="5a9a1bf710972442f065d0d62c62d0c4ec3da4a3696d7160a35602c9470bc7a2") version("1.4.1", sha256="e1b923c508a565f230aac04e3feea23b888b47d8e19b08816a97ee4444233670") + depends_on("c", type="build") # generated + depends_on("blas") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/hashcat/package.py b/var/spack/repos/builtin/packages/hashcat/package.py index 56d615a9cca9a8..9cb2c3f9b91662 100644 --- a/var/spack/repos/builtin/packages/hashcat/package.py +++ b/var/spack/repos/builtin/packages/hashcat/package.py @@ -25,5 +25,8 @@ class Hashcat(MakefilePackage): version("5.1.0", sha256="283beaa68e1eab41de080a58bb92349c8e47a2bb1b93d10f36ea30f418f1e338") version("5.0.0", sha256="7092d98cf0d8b29bd6efe2cf94802442dd8d7283982e9439eafbdef62b0db08f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): make("SHARED=1", "PREFIX={0}".format(prefix), "install") diff --git a/var/spack/repos/builtin/packages/haveged/package.py b/var/spack/repos/builtin/packages/haveged/package.py index 5c806639799e9a..8b0c9922a2c60e 100644 --- a/var/spack/repos/builtin/packages/haveged/package.py +++ b/var/spack/repos/builtin/packages/haveged/package.py @@ -15,3 +15,5 @@ class Haveged(AutotoolsPackage): license("GPL-3.0-or-later") version("1.9.13", sha256="d17bd22fa1745daca5ac72e014ed3b0fe5720da4c115953124b1bf2a0aa2b04b") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/hazelcast/package.py b/var/spack/repos/builtin/packages/hazelcast/package.py index 60eb0b1018463e..53511bd5d20e3b 100644 --- a/var/spack/repos/builtin/packages/hazelcast/package.py +++ b/var/spack/repos/builtin/packages/hazelcast/package.py @@ -24,4 +24,6 @@ class Hazelcast(MavenPackage): version("3.12.7", sha256="0747de968082bc50202f825b4010be28a3885b3dbcee4b83cbe21b2f8b26a7e0") version("3.11.7", sha256="c9f636b8813027d4cc24459bd27740549f89b4f11f62a868079bcb5b41d9b2bb") + depends_on("c", type="build") # generated + depends_on("java@8:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/hbm-dramsim2/package.py b/var/spack/repos/builtin/packages/hbm-dramsim2/package.py index 5fff62e4c0ee25..2c3aa4fdca898f 100644 --- a/var/spack/repos/builtin/packages/hbm-dramsim2/package.py +++ b/var/spack/repos/builtin/packages/hbm-dramsim2/package.py @@ -19,5 +19,7 @@ class HbmDramsim2(MakefilePackage): version("1.0.0", sha256="0efad11c58197edb47ad1359f8f93fb45d882c6bebcf9f2143e0df7a719689a0") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/hdf-eos2/package.py b/var/spack/repos/builtin/packages/hdf-eos2/package.py index 3eb9b7477b7540..1b41abbf6509dc 100644 --- a/var/spack/repos/builtin/packages/hdf-eos2/package.py +++ b/var/spack/repos/builtin/packages/hdf-eos2/package.py @@ -120,9 +120,11 @@ def fix_configure(self): filter_file("CC=./\\$SZIP_CC", "", "configure") def flag_handler(self, name, flags): - if self.spec.compiler.name == "apple-clang": - if name == "cflags": + if name == "cflags": + flags.append(self.compiler.cc_pic_flag) + if self.spec.compiler.name in ["apple-clang", "oneapi"]: flags.append("-Wno-error=implicit-function-declaration") + flags.append("-Wno-error=implicit-int") return flags, None, None @@ -130,8 +132,8 @@ def setup_build_environment(self, env): # Add flags to LDFLAGS for any dependencies that need it extra_ldflags = [] # hdf might have link dependency on rpc, if so need to add flags - if "rpc" in self.spec: - tmp = self.spec["rpc"].libs.ld_flags + if self.spec.satisfies("^libtirpc"): + tmp = self.spec["libtirpc"].libs.ld_flags extra_ldflags.append(tmp) # Set LDFLAGS env.set("LDFLAGS", " ".join(extra_ldflags)) diff --git a/var/spack/repos/builtin/packages/hdf/package.py b/var/spack/repos/builtin/packages/hdf/package.py index d352e2f6b54810..75e1ee3a2fd6cc 100644 --- a/var/spack/repos/builtin/packages/hdf/package.py +++ b/var/spack/repos/builtin/packages/hdf/package.py @@ -25,6 +25,10 @@ class Hdf(AutotoolsPackage): version("4.2.12", sha256="dd419c55e85d1a0e13f3ea5ed35d00710033ccb16c85df088eb7925d486e040c") version("4.2.11", sha256="c3f7753b2fb9b27d09eced4d2164605f111f270c9a60b37a578f7de02de86d24") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("szip", default=False, description="Enable szip support") variant( "external-xdr", default=sys.platform != "darwin", description="Use an external XDR backend" @@ -132,7 +136,7 @@ def libs(self): libs += self.spec["zlib:transitive"].libs if "+szip" in self.spec: libs += self.spec["szip:transitive"].libs - if "+external-xdr" in self.spec and self.spec["rpc"].name != "libc": + if "+external-xdr" in self.spec and self.spec["rpc"].name == "libtirpc": libs += self.spec["rpc:transitive"].libs return libs @@ -146,10 +150,14 @@ def flag_handler(self, name, flags): if name == "cflags": # https://forum.hdfgroup.org/t/help-building-hdf4-with-clang-error-implicit-declaration-of-function-test-mgr-szip-is-invalid-in-c99/7680 - if self.spec.satisfies("@:4.2.15 %apple-clang") or self.spec.satisfies("%clang@16:"): + if ( + self.spec.satisfies("@:4.2.15 %apple-clang") + or self.spec.satisfies("%clang@16:") + or self.spec.satisfies("%oneapi") + ): flags.append("-Wno-error=implicit-function-declaration") - if self.spec.satisfies("%clang@16:"): + if self.spec.satisfies("%clang@16:") or self.spec.satisfies("%apple-clang@15:"): flags.append("-Wno-error=implicit-int") return flags, None, None @@ -174,7 +182,7 @@ def configure_args(self): if "~external-xdr" in self.spec: config_args.append("--enable-hdf4-xdr") - elif self.spec["rpc"].name != "libc": + elif self.spec["rpc"].name == "libtirpc": # We should not specify '--disable-hdf4-xdr' due to a bug in the # configure script. config_args.append("LIBS=%s" % self.spec["rpc"].libs.link_flags) diff --git a/var/spack/repos/builtin/packages/hdf5-blosc/package.py b/var/spack/repos/builtin/packages/hdf5-blosc/package.py index d99e9bbd3aebb5..d7002e66313e29 100644 --- a/var/spack/repos/builtin/packages/hdf5-blosc/package.py +++ b/var/spack/repos/builtin/packages/hdf5-blosc/package.py @@ -36,6 +36,8 @@ class Hdf5Blosc(Package): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("c-blosc") depends_on("hdf5") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/hdf5-vfd-gds/package.py b/var/spack/repos/builtin/packages/hdf5-vfd-gds/package.py index 28ab546bd4773c..17da8e1206fa12 100644 --- a/var/spack/repos/builtin/packages/hdf5-vfd-gds/package.py +++ b/var/spack/repos/builtin/packages/hdf5-vfd-gds/package.py @@ -23,6 +23,8 @@ class Hdf5VfdGds(CMakePackage, CudaPackage): version("1.0.1", sha256="00e125fd149561be991f41e883824de826d8add604aebccf103a4fb82d5faac2") version("1.0.0", sha256="6b16105c7c49f13fc05784ee69b78d45fb159270c78d760689f9cd21e230ddd2") + depends_on("c", type="build") # generated + # Dependencies conflicts("~cuda") # Although cuFILE predates 11.7.0, it is not installed in a location the build diff --git a/var/spack/repos/builtin/packages/hdf5-vol-async/package.py b/var/spack/repos/builtin/packages/hdf5-vol-async/package.py index fd94f588d587d8..1fb1ff16cca642 100644 --- a/var/spack/repos/builtin/packages/hdf5-vol-async/package.py +++ b/var/spack/repos/builtin/packages/hdf5-vol-async/package.py @@ -30,6 +30,8 @@ class Hdf5VolAsync(CMakePackage): version("1.6", tag="v1.6", commit="f3406d62ec055cdcfe077979a1068bd102c598a5") version("1.5", tag="v1.5", commit="b917713ffcb207d9799c6d6863cf805ee54ccfea") + depends_on("c", type="build") # generated + variant("memcpy", default=False, description="Enable buffer copy for dataset write") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/hdf5-vol-cache/package.py b/var/spack/repos/builtin/packages/hdf5-vol-cache/package.py index e5f086b88a7f1c..d6882f3d281c92 100644 --- a/var/spack/repos/builtin/packages/hdf5-vol-cache/package.py +++ b/var/spack/repos/builtin/packages/hdf5-vol-cache/package.py @@ -19,6 +19,9 @@ class Hdf5VolCache(CMakePackage): version("v1.1", tag="v1.1", commit="d886a17a381990b5949d95f5299461c39d7ac2bc") version("v1.0", tag="v1.0", commit="a9b9704e74fa24af50b2a3bd0d63a40a69bde8fe") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("hdf5@1.14: +mpi +threadsafe") depends_on("hdf5-vol-async") diff --git a/var/spack/repos/builtin/packages/hdf5-vol-daos/package.py b/var/spack/repos/builtin/packages/hdf5-vol-daos/package.py index 6fe945bb024187..284ac473e865a9 100644 --- a/var/spack/repos/builtin/packages/hdf5-vol-daos/package.py +++ b/var/spack/repos/builtin/packages/hdf5-vol-daos/package.py @@ -22,6 +22,9 @@ class Hdf5VolDaos(CMakePackage): version("master", branch="master", submodules=True) version("1.2.0", sha256="669c1443605068f24c033783ef72619afcec4844902b3e0bffa19ddeea39779f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.12.2:", type="build") depends_on("daos@2.2.0:") depends_on("hdf5@1.14.0:+hl+mpi+map") diff --git a/var/spack/repos/builtin/packages/hdf5-vol-external-passthrough/package.py b/var/spack/repos/builtin/packages/hdf5-vol-external-passthrough/package.py index e7892a705d37fa..9e97f6e58defd7 100644 --- a/var/spack/repos/builtin/packages/hdf5-vol-external-passthrough/package.py +++ b/var/spack/repos/builtin/packages/hdf5-vol-external-passthrough/package.py @@ -16,6 +16,8 @@ class Hdf5VolExternalPassthrough(CMakePackage): version("develop", branch="develop") version("1.1", sha256="9f1a7fba4958fe0f46b4451253b9b1d7a4cfb30a0ce4183f5f756ceaddbbf2c3") + + depends_on("c", type="build") # generated depends_on("hdf5@1.14.0:") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/hdf5-vol-log/package.py b/var/spack/repos/builtin/packages/hdf5-vol-log/package.py index 3864e6ec3c5a5f..0f5a7dbb639488 100644 --- a/var/spack/repos/builtin/packages/hdf5-vol-log/package.py +++ b/var/spack/repos/builtin/packages/hdf5-vol-log/package.py @@ -19,6 +19,9 @@ class Hdf5VolLog(AutotoolsPackage): version("1.4.0", tag="logvol.1.4.0", commit="786d2cc4da8b4a0827ee00b1b0ab3968ef942f99") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("hdf5@1.14.0:", when="@1.4.0:") depends_on("mpi") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/hdf5/hdf5_1_14_3_fpe.patch b/var/spack/repos/builtin/packages/hdf5/hdf5_1_14_3_fpe.patch new file mode 100644 index 00000000000000..90ab32a0f4b24a --- /dev/null +++ b/var/spack/repos/builtin/packages/hdf5/hdf5_1_14_3_fpe.patch @@ -0,0 +1,203 @@ +diff --git a/config/linux-gnulibc1 b/config/linux-gnulibc1 +index 328f8d3cec..079f08d96c 100644 +--- a/config/linux-gnulibc1 ++++ b/config/linux-gnulibc1 +@@ -173,10 +173,7 @@ case $FC_BASENAME in + nagfor) + + F9XSUFFIXFLAG="" +- # NOTE: The default is -ieee=stop, which will cause problems +- # when the H5T module performs floating-point type +- # introspection +- AM_FCFLAGS="$AM_FCFLAGS -ieee=full" ++ AM_FCFLAGS="$AM_FCFLAGS" + FSEARCH_DIRS="" + + # Production +diff --git a/release_docs/RELEASE.txt b/release_docs/RELEASE.txt +index 200576332b..0aa139761d 100644 +--- a/release_docs/RELEASE.txt ++++ b/release_docs/RELEASE.txt +@@ -246,6 +246,27 @@ Support for new platforms, languages and compilers + - + + ++Patches applied since the HDF5-1.14.3 release ++============================================= ++ Library ++ ------- ++ - Suppressed floating-point exceptions in H5T init code ++ ++ The floating-point datatype initialization code in H5Tinit_float.c ++ could raise FE_INVALID exceptions while munging bits and performing ++ comparisons that might involve NaN. This was not a problem when the ++ initialization code was executed in H5detect at compile time (prior ++ to 1.14.3), but now that the code is executed at library startup ++ (1.14.3+), these exceptions can be caught by user code, as is the ++ default in the NAG Fortran compiler. ++ ++ Starting in 1.14.4, we now suppress floating-point exceptions while ++ initializing the floating-point types and clear FE_INVALID before ++ restoring the original environment. ++ ++ Fixes GitHub #3831 ++ ++ + Bug Fixes since HDF5-1.14.2 release + =================================== + Library +@@ -619,12 +640,6 @@ Known Problems + this release with link errors. As a result, Windows binaries for this release + will not include Fortran. The problem will be addressed in HDF5 1.14.4. + +- IEEE standard arithmetic enables software to raise exceptions such as overflow, +- division by zero, and other illegal operations without interrupting or halting +- the program flow. The HDF5 C library intentionally performs these exceptions. +- Therefore, the "-ieee=full" nagfor switch is necessary when compiling a program +- to avoid stopping on an exception. +- + CMake files do not behave correctly with paths containing spaces. + Do not use spaces in paths because the required escaping for handling spaces + results in very complex and fragile build files. +diff --git a/src/H5Tinit_float.c b/src/H5Tinit_float.c +index 3b9e127fe4..02bb3bad77 100644 +--- a/src/H5Tinit_float.c ++++ b/src/H5Tinit_float.c +@@ -51,19 +51,23 @@ + * Function: DETECT_F + * + * Purpose: This macro takes a floating point type like `double' and +- * a base name like `natd' and detects byte order, mantissa +- * location, exponent location, sign bit location, presence or +- * absence of implicit mantissa bit, and exponent bias and +- * initializes a detected_t structure with those properties. ++ * detects byte order, mantissa location, exponent location, ++ * sign bit location, presence or absence of implicit mantissa ++ * bit, and exponent bias and initializes a detected_t structure ++ * with those properties. ++ * ++ * Note that these operations can raise floating-point ++ * exceptions and building with some compiler options ++ * (especially Fortran) can cause problems. + *------------------------------------------------------------------------- + */ +-#define DETECT_F(TYPE, VAR, INFO) \ ++#define DETECT_F(TYPE, INFO) \ + do { \ +- TYPE _v1, _v2, _v3; \ +- unsigned char _buf1[sizeof(TYPE)], _buf3[sizeof(TYPE)]; \ +- unsigned char _pad_mask[sizeof(TYPE)]; \ +- unsigned char _byte_mask; \ +- int _i, _j, _last = (-1); \ ++ TYPE _v1, _v2, _v3; \ ++ uint8_t _buf1[sizeof(TYPE)], _buf3[sizeof(TYPE)]; \ ++ uint8_t _pad_mask[sizeof(TYPE)]; \ ++ uint8_t _byte_mask; \ ++ int _i, _j, _last = -1; \ + \ + memset(&INFO, 0, sizeof(INFO)); \ + INFO.size = sizeof(TYPE); \ +@@ -81,7 +85,7 @@ + _v1 = (TYPE)4.0L; \ + H5MM_memcpy(_buf1, (const void *)&_v1, sizeof(TYPE)); \ + for (_i = 0; _i < (int)sizeof(TYPE); _i++) \ +- for (_byte_mask = (unsigned char)1; _byte_mask; _byte_mask = (unsigned char)(_byte_mask << 1)) { \ ++ for (_byte_mask = (uint8_t)1; _byte_mask; _byte_mask = (uint8_t)(_byte_mask << 1)) { \ + _buf1[_i] ^= _byte_mask; \ + H5MM_memcpy((void *)&_v2, (const void *)_buf1, sizeof(TYPE)); \ + H5_GCC_CLANG_DIAG_OFF("float-equal") \ +@@ -118,7 +122,7 @@ + _v1 = (TYPE)1.0L; \ + _v2 = (TYPE)-1.0L; \ + if (H5T__bit_cmp(sizeof(TYPE), INFO.perm, &_v1, &_v2, _pad_mask, &(INFO.sign)) < 0) \ +- HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "failed to detect byte order"); \ ++ HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "failed to determine sign bit"); \ + \ + /* Mantissa */ \ + INFO.mpos = 0; \ +@@ -126,12 +130,11 @@ + _v1 = (TYPE)1.0L; \ + _v2 = (TYPE)1.5L; \ + if (H5T__bit_cmp(sizeof(TYPE), INFO.perm, &_v1, &_v2, _pad_mask, &(INFO.msize)) < 0) \ +- HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "failed to detect byte order"); \ ++ HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "failed to determine mantissa"); \ + INFO.msize += 1 + (unsigned)(INFO.imp ? 0 : 1) - INFO.mpos; \ + \ + /* Exponent */ \ +- INFO.epos = INFO.mpos + INFO.msize; \ +- \ ++ INFO.epos = INFO.mpos + INFO.msize; \ + INFO.esize = INFO.sign - INFO.epos; \ + \ + _v1 = (TYPE)1.0L; \ +@@ -456,17 +459,24 @@ H5T__set_precision(H5T_fpoint_det_t *d) + herr_t H5_NO_UBSAN + H5T__init_native_float_types(void) + { ++ fenv_t saved_fenv; + H5T_fpoint_det_t det; + H5T_t *dt = NULL; + herr_t ret_value = SUCCEED; + + FUNC_ENTER_PACKAGE + ++ /* Turn off floating-point exceptions while initializing to avoid ++ * tripping over signaling NaNs while looking at "don't care" bits. ++ */ ++ if (feholdexcept(&saved_fenv) != 0) ++ HSYS_GOTO_ERROR(H5E_DATATYPE, H5E_CANTSET, FAIL, "can't save floating-point environment"); ++ + /* H5T_NATIVE_FLOAT */ + + /* Get the type's characteristics */ + memset(&det, 0, sizeof(H5T_fpoint_det_t)); +- DETECT_F(float, FLOAT, det); ++ DETECT_F(float, det); + + /* Allocate and fill type structure */ + if (NULL == (dt = H5T__alloc())) +@@ -497,7 +507,7 @@ H5T__init_native_float_types(void) + + /* Get the type's characteristics */ + memset(&det, 0, sizeof(H5T_fpoint_det_t)); +- DETECT_F(double, DOUBLE, det); ++ DETECT_F(double, det); + + /* Allocate and fill type structure */ + if (NULL == (dt = H5T__alloc())) +@@ -528,7 +538,7 @@ H5T__init_native_float_types(void) + + /* Get the type's characteristics */ + memset(&det, 0, sizeof(H5T_fpoint_det_t)); +- DETECT_F(long double, LDOUBLE, det); ++ DETECT_F(long double, det); + + /* Allocate and fill type structure */ + if (NULL == (dt = H5T__alloc())) +@@ -561,6 +571,14 @@ H5T__init_native_float_types(void) + H5T_native_order_g = det.order; + + done: ++ /* Clear any FE_INVALID exceptions from NaN handling */ ++ if (feclearexcept(FE_INVALID) != 0) ++ HSYS_GOTO_ERROR(H5E_DATATYPE, H5E_CANTSET, FAIL, "can't clear floating-point exceptions"); ++ ++ /* Restore the original environment */ ++ if (feupdateenv(&saved_fenv) != 0) ++ HSYS_GOTO_ERROR(H5E_DATATYPE, H5E_CANTSET, FAIL, "can't restore floating-point environment"); ++ + if (ret_value < 0) { + if (dt != NULL) { + dt->shared = H5FL_FREE(H5T_shared_t, dt->shared); +diff --git a/src/H5private.h b/src/H5private.h +index 14a0ac3225..3aaa0d5245 100644 +--- a/src/H5private.h ++++ b/src/H5private.h +@@ -26,6 +26,7 @@ + #include + #include + #include ++#include + #include + #include + #include diff --git a/var/spack/repos/builtin/packages/hdf5/package.py b/var/spack/repos/builtin/packages/hdf5/package.py index a7f267d8109670..8a8c1a207c3c00 100644 --- a/var/spack/repos/builtin/packages/hdf5/package.py +++ b/var/spack/repos/builtin/packages/hdf5/package.py @@ -6,6 +6,7 @@ import os import re import shutil +import sys import llnl.util.lang import llnl.util.tty as tty @@ -33,6 +34,9 @@ class Hdf5(CMakePackage): license("custom") + depends_on("cxx", type="build", when="+cxx") + depends_on("fortran", type="build", when="+fortran") + # The 'develop' version is renamed so that we could uninstall (or patch) it # without affecting other develop version. version("develop-1.15", branch="develop") @@ -83,6 +87,10 @@ class Hdf5(CMakePackage): version("1.8.12", sha256="b5cccea850096962b5fd9e96f22c4f47d2379224bb41130d9bc038bb6c37dfcb") version("1.8.10", sha256="4813b79c5fb8701a625b9924b8203bc7154a77f9b826ad4e034144b4056a160a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Builds a shared version of the library") variant("hl", default=False, description="Enable the high-level library") @@ -109,14 +117,17 @@ class Hdf5(CMakePackage): depends_on("cmake@3.12:", type="build") depends_on("cmake@3.18:", type="build", when="@1.13:") - depends_on("mpi", when="+mpi") + with when("+mpi"): + depends_on("mpi") + depends_on("mpich+fortran", when="+fortran ^[virtuals=mpi] mpich") + depends_on("java", type=("build", "run"), when="+java") depends_on("szip", when="+szip") depends_on("zlib-api") # The compiler wrappers (h5cc, h5fc, etc.) run 'pkg-config'. # Skip this on Windows since pkgconfig is autotools - for plat in ["cray", "darwin", "linux"]: + for plat in ["darwin", "linux"]: depends_on("pkgconfig", when=f"platform={plat}", type="run") conflicts("+mpi", "^mpich@4.0:4.0.3") @@ -170,6 +181,15 @@ class Hdf5(CMakePackage): # described in #2 we allow for such combination. # conflicts('+mpi+cxx') + # Patch needed for HDF5 1.14.3 to fix signaling FPE checks from triggering + # at dynamic type system initialization. The type system's builtin types + # were refactored in 1.14.3 and switched from compile-time to run-time + # initialization. This patch suppresses floating point exception checks + # that would otherwise be triggered by this code. Later HDF5 versions + # will include the patch code changes. + # See https://github.com/HDFGroup/hdf5/pull/3837 + patch("hdf5_1_14_3_fpe.patch", when="@1.14.3") + # There are known build failures with intel@18.0.1. This issue is # discussed and patch is provided at # https://software.intel.com/en-us/forums/intel-fortran-compiler-for-linux-and-mac-os-x/topic/747951. @@ -261,16 +281,10 @@ def patch(self): # compiler wrappers and do not need to be changed. # These do not exist on Windows. # Enable only for supported target platforms. - for spack_spec_target_platform in ["linux", "darwin", "cray"]: + + if sys.platform != "win32": filter_compiler_wrappers( - "h5cc", - "h5hlcc", - "h5fc", - "h5hlfc", - "h5c++", - "h5hlc++", - relative_root="bin", - when=f"platform={spack_spec_target_platform}", + "h5cc", "h5hlcc", "h5fc", "h5hlfc", "h5c++", "h5hlc++", relative_root="bin" ) def url_for_version(self, version): @@ -611,6 +625,18 @@ def link_debug_libs(self): libname = os.path.split(lib)[1] os.symlink(libname, libname.replace("_debug", "")) + @run_after("install") + def symlink_to_h5hl_wrappers(self): + if self.spec.satisfies("+hl"): + with working_dir(self.prefix.bin): + # CMake's FindHDF5 relies only on h5cc so it doesn't find the HL + # component unless it uses h5hlcc so we symlink h5cc to h5hlcc etc + symlink_files = {"h5cc": "h5hlcc", "h5c++": "h5hlc++"} + for old, new in symlink_files.items(): + if os.path.isfile(old): + os.remove(old) + symlink(new, old) + @property @llnl.util.lang.memoized def _output_version(self): diff --git a/var/spack/repos/builtin/packages/heaptrack/package.py b/var/spack/repos/builtin/packages/heaptrack/package.py index e24689594327d1..305bd289772fbe 100644 --- a/var/spack/repos/builtin/packages/heaptrack/package.py +++ b/var/spack/repos/builtin/packages/heaptrack/package.py @@ -18,6 +18,9 @@ class Heaptrack(CMakePackage): version("1.3.0", sha256="794b067772f4e4219bb7b6ff1bc1b2134b1b242e748a2cc5c47626040c631956") version("1.1.0", sha256="bd247ac67d1ecf023ec7e2a2888764bfc03e2f8b24876928ca6aa0cdb3a07309") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost@1.41: +program_options+exception+filesystem+system+iostreams+container") depends_on("cmake@2.8.9:", type="build") depends_on("elfutils") diff --git a/var/spack/repos/builtin/packages/heasoft/package.py b/var/spack/repos/builtin/packages/heasoft/package.py index 76073a2e3b03f4..eaa0135ebf3093 100644 --- a/var/spack/repos/builtin/packages/heasoft/package.py +++ b/var/spack/repos/builtin/packages/heasoft/package.py @@ -29,6 +29,10 @@ class Heasoft(AutotoolsPackage): version("6.30", sha256="7f828f6050809653319f94d715c1b6815fbc09adfdcb61f2f0f1d7a6af10684a") version("6.29", sha256="534fec04baa2586326fd7240805f2606620f3b7d7078a80fdd95c9c1177c9e68") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("X", default=True, description="Enable X11 support") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/heffte/package.py b/var/spack/repos/builtin/packages/heffte/package.py index d106f92bc937eb..dc20db8a4fe40a 100644 --- a/var/spack/repos/builtin/packages/heffte/package.py +++ b/var/spack/repos/builtin/packages/heffte/package.py @@ -31,6 +31,10 @@ class Heffte(CMakePackage, CudaPackage, ROCmPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + patch("cmake-magma-v230.patch", when="@2.3.0") patch("fortran200.patch", when="@2.0.0") diff --git a/var/spack/repos/builtin/packages/heimdall/package.py b/var/spack/repos/builtin/packages/heimdall/package.py new file mode 100644 index 00000000000000..dce08369e461b9 --- /dev/null +++ b/var/spack/repos/builtin/packages/heimdall/package.py @@ -0,0 +1,49 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Heimdall(AutotoolsPackage, CudaPackage): + """GPU accelerated transient detection pipeline""" + + homepage = "https://sourceforge.net/projects/heimdall-astro/" + git = "https://git.code.sf.net/p/heimdall-astro/code" + + maintainers("aweaver1fandm") + + version("master", branch="master", preferred=True) + + depends_on("cxx", type="build") # generated + + conflicts("~cuda", msg="You must specify +cuda") + conflicts("cuda@11.8") + conflicts("cuda_arch=none", msg="You must specify the CUDA architecture") + + depends_on("autoconf", type="build") + depends_on("automake", type="build") + depends_on("libtool", type="build") + depends_on("cuda") + + # Pass the cuda architecture to DEDISP and PSRDADA for building + for arch in CudaPackage.cuda_arch_values: + depends_on(f"dedisp cuda_arch={arch}", when=f"cuda_arch={arch}") + + depends_on(f"psrdada cuda_arch={arch}", when=f"cuda_arch={arch}") + + def setup_run_environment(self, env): + env.prepend_path("PATH", self.spec["psrdada"].prefix.bin) + env.prepend_path("PATH", self.prefix.bin) + env.prepend_path("LD_LIBRARY_PATH", self.spec["dedisp"].prefix.lib) + env.prepend_path("LD_LIBRARY_PATH", self.spec["cuda"].prefix.lib) + + def configure_args(self): + # Required flags for configure + args = [ + f"--with-psrdada-dir={self.spec['psrdada'].prefix}", + f"--with-dedisp-dir={self.spec['dedisp'].prefix}", + f"--with-cuda-dir={self.spec['cuda'].prefix}", + ] + return args diff --git a/var/spack/repos/builtin/packages/helib/package.py b/var/spack/repos/builtin/packages/helib/package.py index 040b828cca7686..5129bd1bc3dfbe 100644 --- a/var/spack/repos/builtin/packages/helib/package.py +++ b/var/spack/repos/builtin/packages/helib/package.py @@ -39,6 +39,9 @@ class Helib(CMakePackage): version("1.1.0", sha256="77a912ed3c86f8bde31b7d476321d0c2d810570c04a60fa95c4bd32a1955b5cf") version("1.0.2", sha256="b907eaa8381af3d001d7fb8383273f4c652415b3320c11d5be2ad8f19757c998") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=False, description="Build shared library.") depends_on("gmp@6.2.1:") depends_on("ntl@11.5.1:") diff --git a/var/spack/repos/builtin/packages/helics/package.py b/var/spack/repos/builtin/packages/helics/package.py index 956db9ae48ae87..3f3da4d106fd1c 100644 --- a/var/spack/repos/builtin/packages/helics/package.py +++ b/var/spack/repos/builtin/packages/helics/package.py @@ -23,6 +23,9 @@ class Helics(CMakePackage): version("develop", branch="develop", submodules=True) version("main", branch="main", submodules=True) version("master", branch="main", submodules=True) + version("3.5.3", sha256="f9ace240510b18caf642f55d08f9009a9babb203fbc032ec7d7d8aa6fd5e1553") + version("3.5.2", sha256="c2604694698a1e33c4a68f3d1c5ab0a228ef2bfca1b0d3bae94801dbd3b11048") + version("3.5.1", sha256="546fc6e6a85de6ba841e4bd547b811cc81a67a22be5e212ccb54be139d740555") version("3.5.0", sha256="0c02ebaecf3d4ead7911e13325b26706f1e4b316ca51ec609e969e18ec584b78") version("3.4.0", sha256="88877a3767de9aed9f1cddea7b6455a2be060a00b959bb7e94994d1fd20878f8") version("3.3.2", sha256="b04013969fc02dc36c697c328e6f50a0ac8dbdaf3d3e69870cd6e6ebeb374286") @@ -47,6 +50,9 @@ class Helics(CMakePackage): version("2.4.2", sha256="957856f06ed6d622f05dfe53df7768bba8fe2336d841252f5fac8345070fa5cb") version("2.4.1", sha256="ac077e9efe466881ea366721cb31fb37ea0e72a881a717323ba4f3cdda338be4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("apps", default=True, description="Install the HELICS apps executables") variant("apps_lib", default=True, description="Install the HELICS apps library") variant("benchmarks", default=False, description="Install the HELICS benchmarks") diff --git a/var/spack/repos/builtin/packages/help2man/package.py b/var/spack/repos/builtin/packages/help2man/package.py index f5b41627f9b510..3688260cb15318 100644 --- a/var/spack/repos/builtin/packages/help2man/package.py +++ b/var/spack/repos/builtin/packages/help2man/package.py @@ -21,4 +21,6 @@ class Help2man(AutotoolsPackage, GNUMirrorPackage): version("1.47.8", sha256="528f6a81ad34cbc76aa7dce5a82f8b3d2078ef065271ab81fda033842018a8dc") version("1.47.4", sha256="d4ecf697d13f14dd1a78c5995f06459bff706fd1ce593d1c02d81667c0207753") + depends_on("c", type="build") # generated + depends_on("perl", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/henson/package.py b/var/spack/repos/builtin/packages/henson/package.py index d1be8ba2cd234e..4b7eb9bb63a950 100644 --- a/var/spack/repos/builtin/packages/henson/package.py +++ b/var/spack/repos/builtin/packages/henson/package.py @@ -16,6 +16,9 @@ class Henson(CMakePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + maintainers("mrzv") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/hepmc/package.py b/var/spack/repos/builtin/packages/hepmc/package.py index a1194a79381fc0..161220d85476f4 100644 --- a/var/spack/repos/builtin/packages/hepmc/package.py +++ b/var/spack/repos/builtin/packages/hepmc/package.py @@ -26,6 +26,9 @@ class Hepmc(CMakePackage): version("2.06.06", sha256="8cdff26c10783ed4248220a84a43b7e1f9b59cc2c9a29bd634d024ca469db125") version("2.06.05", sha256="4c411077cc97522c03b74f973264b8d9fd2b6ccec0efc7ceced2645371c73618") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("length", default="MM", values=("CM", "MM"), multi=False, description="Unit of length") variant( "momentum", diff --git a/var/spack/repos/builtin/packages/hepmc3/package.py b/var/spack/repos/builtin/packages/hepmc3/package.py index a3f96d95c5c51b..b7d13f03c7838b 100644 --- a/var/spack/repos/builtin/packages/hepmc3/package.py +++ b/var/spack/repos/builtin/packages/hepmc3/package.py @@ -31,6 +31,10 @@ class Hepmc3(CMakePackage): version("3.1.2", sha256="4133074b3928252877982f3d4b4c6c750bb7a324eb6c7bb2afc6fa256da3ecc7") version("3.1.1", sha256="2fcbc9964d6f9f7776289d65f9c73033f85c15bf5f0df00c429a6a1d8b8248bb") version("3.1.0", sha256="cd37eed619d58369041018b8627274ad790020a4714b54ac05ad1ebc1a6e7f8a") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated # note that version 3.0.0 is not supported # conflicts with cmake configuration @@ -44,7 +48,9 @@ class Hepmc3(CMakePackage): ) depends_on("cmake@2.8.9:", type="build") - depends_on("root", when="+rootio") + with when("+rootio"): + depends_on("root") + depends_on("root cxxstd=11", when="@:3.2.3") depends_on("protobuf", when="+protobuf") depends_on("python", when="+python") @@ -62,7 +68,7 @@ def cmake_args(self): self.define("HEPMC3_ENABLE_TEST", self.run_tests), ] - if "+python" in spec: + if spec.satisfies("+python"): py_ver = spec["python"].version.up_to(2) args.extend( [ @@ -71,7 +77,11 @@ def cmake_args(self): ] ) - if "+rootio" in spec: + if spec.satisfies("+rootio"): args.append(self.define("ROOT_DIR", spec["root"].prefix)) + if spec.satisfies("@3.2.4:"): + args.append( + self.define("HEPMC3_CXX_STANDARD", spec["root"].variants["cxxstd"].value) + ) return args diff --git a/var/spack/repos/builtin/packages/hepmcanalysis/package.py b/var/spack/repos/builtin/packages/hepmcanalysis/package.py index 2b66581b9c5883..e23a30323bba36 100644 --- a/var/spack/repos/builtin/packages/hepmcanalysis/package.py +++ b/var/spack/repos/builtin/packages/hepmcanalysis/package.py @@ -15,6 +15,9 @@ class Hepmcanalysis(MakefilePackage): version("3.4.13", sha256="be9937c6de493a5671258919493b0caa0cecca77853a2075f5cecce1071e0029") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + tags = ["hep"] depends_on("hepmc") diff --git a/var/spack/repos/builtin/packages/heppdt/package.py b/var/spack/repos/builtin/packages/heppdt/package.py index 5f066f44d3ddb6..fe7164905f6eed 100644 --- a/var/spack/repos/builtin/packages/heppdt/package.py +++ b/var/spack/repos/builtin/packages/heppdt/package.py @@ -28,3 +28,6 @@ class Heppdt(AutotoolsPackage): sha256="12a1b6ffdd626603fa3b4d70f44f6e95a36f8f3b6d4fd614bac14880467a2c2e", preferred=True, ) + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/hermes/package.py b/var/spack/repos/builtin/packages/hermes/package.py index ef33ea207b2bec..7072524c53a9a7 100644 --- a/var/spack/repos/builtin/packages/hermes/package.py +++ b/var/spack/repos/builtin/packages/hermes/package.py @@ -25,6 +25,9 @@ class Hermes(CMakePackage): sha256="abf258a52fa79729dfeb28559957abf8945f3ad37cadefb3bc685227c5f057a8", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("vfd", default=False, description="Enable HDF5 VFD") depends_on("mochi-thallium~cereal@0.8:") diff --git a/var/spack/repos/builtin/packages/herwig3/package.py b/var/spack/repos/builtin/packages/herwig3/package.py index 960656ee6b59f6..bac7b7c4e4c3fc 100644 --- a/var/spack/repos/builtin/packages/herwig3/package.py +++ b/var/spack/repos/builtin/packages/herwig3/package.py @@ -20,6 +20,10 @@ class Herwig3(AutotoolsPackage): version("7.2.2", sha256="53e06b386df5bc20fe268b6c8ba50f1e62b6744e577d383ec836ea3fc672c383") version("7.2.1", sha256="d4fff32f21c5c08a4b2e563c476b079859c2c8e3b78d853a8a60da96d5eea686") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/herwigpp/package.py b/var/spack/repos/builtin/packages/herwigpp/package.py index b1d2cd12eb4e61..85c42af5c4c56a 100644 --- a/var/spack/repos/builtin/packages/herwigpp/package.py +++ b/var/spack/repos/builtin/packages/herwigpp/package.py @@ -19,6 +19,10 @@ class Herwigpp(AutotoolsPackage): license("GPL-2.0-only") version("2.7.1", sha256="80a189376bb65f5ec4e64f42e76c00ea9102d8224010563a424fc11e619a6ad6") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated patch("herwig++-2.7.1.patch", when="@2.7.1", level=0) depends_on("gsl") diff --git a/var/spack/repos/builtin/packages/hevea/package.py b/var/spack/repos/builtin/packages/hevea/package.py index b29903e95e5f3a..9e4dcfa2ecc2d5 100644 --- a/var/spack/repos/builtin/packages/hevea/package.py +++ b/var/spack/repos/builtin/packages/hevea/package.py @@ -23,6 +23,8 @@ class Hevea(MakefilePackage): version("2.33", sha256="122f9023f9cfe8b41dd8965b7d9669df21bf41e419bcf5e9de5314f428380d0f") version("2.32", sha256="f0c12ee3936364a3aa26da384e3d2ad2344be0091f04f9531f04ecb1dca98aca") + depends_on("c", type="build") # generated + # Dependency demands ocamlbuild depends_on("ocaml") depends_on("ocamlbuild") diff --git a/var/spack/repos/builtin/packages/heyoka/package.py b/var/spack/repos/builtin/packages/heyoka/package.py index 25dd1851faecc2..9472f184f63b53 100644 --- a/var/spack/repos/builtin/packages/heyoka/package.py +++ b/var/spack/repos/builtin/packages/heyoka/package.py @@ -18,6 +18,11 @@ class Heyoka(CMakePackage): # SPDX identifier of the project's license. license("MPL-2.0") + version("5.0.0", sha256="e9a4b5683a08706addc1b448e232f1e269d78586859fe3f4d93d4c5eee3bc8ae") + version("4.0.3", sha256="47608e785607782d896ae2347a29a143cdb7e5c602f48f5ea795cf682051dbee") + version("4.0.2", sha256="8eba8fe0626c3d48affad3055e490e5d21430a420af867d7d52c18ed6b602ae0") + version("4.0.1", sha256="25ad39a716c5d548260d505225a13b7fa86534761b6e3d3de991d9d097ec615f") + version("4.0.0", sha256="bc375271773993bd89d604a269c4931e54fb8508c8235397d47f0b60b78f3cdf") version("3.2.0", sha256="37db24fbaf0e65d740ffb20f76ac1c8ab9fbd6893dc87dfd483c965b71dbf465") version("3.1.0", sha256="7eecab47f44a9fff022cf24f226763dab8b075a9fdaa543a42f64bb2634b3ad8") version("3.0.0", sha256="03ccb6fb015ad43877781763c0f2f49bd6db64c8b9493174e589c970ef00d7f2") @@ -29,6 +34,8 @@ class Heyoka(CMakePackage): version("0.19.0", sha256="7a7634379233be778fd6b15090df287787cc429314ec521d0336cdc1ae26642a") version("0.18.0", sha256="2a14a988d973d9a76424df05d38f89ae64f7a1e1c12131022e338fe2de2dcb94") + depends_on("cxx", type="build") # generated + # Define variants of the package variant("mppp", default=False, description="enable features relying on the mp++ library") variant("sleef", default=False, description="enable features relying on the SLEEF library") @@ -47,7 +54,8 @@ class Heyoka(CMakePackage): depends_on("cmake@3.18:", type="build") # Required dependencies - depends_on("llvm@13:17") + depends_on("llvm@13:17", when="@:4") + depends_on("llvm@13:18", when="@5") depends_on("boost@1.69: +serialization") depends_on("fmt@9:10") depends_on("spdlog") diff --git a/var/spack/repos/builtin/packages/hh-suite/package.py b/var/spack/repos/builtin/packages/hh-suite/package.py index 1283c8472b0b41..4735ddd9f42e72 100644 --- a/var/spack/repos/builtin/packages/hh-suite/package.py +++ b/var/spack/repos/builtin/packages/hh-suite/package.py @@ -21,6 +21,9 @@ class HhSuite(CMakePackage): version("3.3.0", sha256="dd67f7f3bf601e48c9c0bc4cf1fbe3b946f787a808bde765e9436a48d27b0964") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") depends_on("cmake@2.8.12:", type="build") diff --git a/var/spack/repos/builtin/packages/hicops/package.py b/var/spack/repos/builtin/packages/hicops/package.py index 7cfd6c36728344..c599dbec39946c 100644 --- a/var/spack/repos/builtin/packages/hicops/package.py +++ b/var/spack/repos/builtin/packages/hicops/package.py @@ -20,6 +20,8 @@ class Hicops(CMakePackage): version("release", branch="release") version("develop", branch="develop") + depends_on("cxx", type="build") # generated + # Build Options variant("mpi", default=True, description="Enable MPI support.") variant( diff --git a/var/spack/repos/builtin/packages/highfive/package.py b/var/spack/repos/builtin/packages/highfive/package.py index e1af063055ee36..e7f73bdf419538 100644 --- a/var/spack/repos/builtin/packages/highfive/package.py +++ b/var/spack/repos/builtin/packages/highfive/package.py @@ -41,6 +41,8 @@ class Highfive(CMakePackage): version("1.1", sha256="430fc312fc1961605ffadbfad82b9753a5e59482e9fbc64425fb2c184123d395") version("1.0", sha256="d867fe73d00817f686d286f3c69a23731c962c3e2496ca1657ea7302cd0bb944") + depends_on("cxx", type="build") # generated + variant("boost", default=False, description="Support Boost") variant("mpi", default=True, description="Support MPI") diff --git a/var/spack/repos/builtin/packages/highway/package.py b/var/spack/repos/builtin/packages/highway/package.py index 3c7fd5ff578790..bb14ce3287739c 100644 --- a/var/spack/repos/builtin/packages/highway/package.py +++ b/var/spack/repos/builtin/packages/highway/package.py @@ -24,11 +24,16 @@ class Highway(CMakePackage): version("1.0.1", sha256="7ca6af7dc2e3e054de9e17b9dfd88609a7fd202812b1c216f43cc41647c97311") version("1.0.0", sha256="ab4f5f864932268356f9f6aa86f612fa4430a7db3c8de0391076750197e876b8") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.10:", type="build") depends_on("googletest", type="test") def cmake_args(self): - args = [] + args = [ + self.define("HWY_ENABLE_TESTS", self.run_tests), + self.define("BUILD_TESTING", self.run_tests), + ] if self.run_tests: args.append(self.define("HWY_SYSTEM_GTEST", True)) return args diff --git a/var/spack/repos/builtin/packages/highwayhash/package.py b/var/spack/repos/builtin/packages/highwayhash/package.py index 8dad7acc99c662..e86c65a62c3270 100644 --- a/var/spack/repos/builtin/packages/highwayhash/package.py +++ b/var/spack/repos/builtin/packages/highwayhash/package.py @@ -21,6 +21,8 @@ class Highwayhash(MakefilePackage): version("dfcb97", commit="dfcb97ca4fe9277bf9dc1802dd979b071896453b") + depends_on("cxx", type="build") # generated + build_targets = ["all", "libhighwayhash.a"] def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/hiop/package.py b/var/spack/repos/builtin/packages/hiop/package.py index 4364d0eeb303f8..ae00e6643caafc 100644 --- a/var/spack/repos/builtin/packages/hiop/package.py +++ b/var/spack/repos/builtin/packages/hiop/package.py @@ -5,8 +5,6 @@ import os -import llnl.util.tty as tty - from spack.package import * @@ -72,10 +70,14 @@ class Hiop(CMakePackage, CudaPackage, ROCmPackage): version("master", branch="master") version("develop", branch="develop") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("jsrun", default=False, description="Enable/Disable jsrun command for testing") variant("shared", default=False, description="Enable/Disable shared libraries") variant("mpi", default=True, description="Enable/Disable MPI") - variant("raja", default=False, description="Enable/Disable RAJA") + variant("raja", default=False, when="@0.3.99:", description="Enable/Disable RAJA") variant("kron", default=False, description="Enable/Disable Kron reduction") variant("sparse", default=False, description="Enable/Disable Sparse linear algebra") variant( @@ -124,7 +126,11 @@ class Hiop(CMakePackage, CudaPackage, ROCmPackage): # 1.0.2 fixes bug with cuda 12 compatibility # hiop@0.6.0 requires cusolver API in cuda@11 depends_on("cuda@11:11.9", when="@0.6.0:1.0.1+cuda") - depends_on("cuda@11:", when="@develop:+cuda") + # Version v0.7.0 of HiOp is the earliest version that uses + # cusparseSpGEMMreuse_workEstimation + # which appears for the first time in the cuSPARSE version shipped with + # CUDA 11.3.1, at least according to the CUDA online documentation. + depends_on("cuda@11.3.1:", when="@0.7:+cuda") # Before hiop@0.6.0 only cuda requirement was magma depends_on("cuda", when="@:0.5.4+cuda") @@ -134,9 +140,11 @@ class Hiop(CMakePackage, CudaPackage, ROCmPackage): # RAJA > 0.14 and Umpire > 6.0 require c++ std 14 # We are working on supporting newer Umpire/RAJA versions - depends_on("raja@0.14.0:0.14", when="@0.5.0:+raja") - depends_on("umpire@6.0.0:6", when="@0.5.0:+raja") - depends_on("camp@0.2.3:0.2", when="@0.5.0:+raja") + depends_on("raja@0.14", when="@0.5:+raja") + depends_on("raja@:0.13", when="@0.3.99:0.4+raja") + depends_on("umpire@6", when="@0.5:+raja") + depends_on("umpire@:5", when="@0.3.99:0.4+raja") + depends_on("camp@0.2.3:0.2", when="@0.3.99:+raja") # This is no longer a requirement in RAJA > 0.14 depends_on("umpire+cuda~shared", when="+raja+cuda ^raja@:0.14") @@ -149,8 +157,10 @@ class Hiop(CMakePackage, CudaPackage, ROCmPackage): # We rely on RAJA / Umpire utilities when supporting CUDA backend conflicts("~raja", when="+cuda", msg="RAJA is required for CUDA support") + conflicts("~raja", when="+rocm", msg="RAJA is required for ROCm support") depends_on("hip", when="+rocm") + depends_on("hiprand", when="+rocm") depends_on("hipblas", when="+rocm") depends_on("hipsparse", when="+rocm") @@ -266,37 +276,35 @@ def cmake_args(self): # # export SPACK_USER_CACHE_PATH=/tmp/spack # export SPACK_DISABLE_LOCAL_CONFIG=true - def test(self): - if not self.spec.satisfies("@develop") or not os.path.isdir(self.prefix.bin): - tty.info("Skipping: checks not installed in bin for v{0}".format(self.version)) - return - - tests = [ - ["NlpMdsEx1.exe", "400", "100", "0", "-selfcheck"], - ["NlpMdsEx1.exe", "400", "100", "1", "-selfcheck"], - ["NlpMdsEx1.exe", "400", "100", "0", "-empty_sp_row", "-selfcheck"], + + def run_hiop(self, raja): + if raja: + exName = "NlpMdsEx1Raja.exe" + else: + exName = "NlpMdsEx1.exe" + + exe = os.path.join(self.prefix.bin, exName) + if not os.path.exists(exe): + raise SkipTest(f"{exName} does not exist in version {self.version}") + + options = [ + ["400", "100", "0", "-selfcheck"], + ["400", "100", "1", "-selfcheck"], + ["400", "100", "0", "-empty_sp_row", "-selfcheck"], ] - if "+raja" in self.spec: - tests.extend( - [ - ["NlpMdsEx1Raja.exe", "400", "100", "0", "-selfcheck"], - ["NlpMdsEx1Raja.exe", "400", "100", "1", "-selfcheck"], - ["NlpMdsEx1Raja.exe", "400", "100", "0", "-empty_sp_row", "-selfcheck"], - ] - ) + exe = which(exe) - for i, test in enumerate(tests): - exe = os.path.join(self.prefix.bin, test[0]) - args = test[1:] - reason = 'test {0}: "{1}"'.format(i, " ".join(test)) - self.run_test( - exe, - args, - [], - 0, - installed=False, - purpose=reason, - skip_missing=True, - work_dir=self.prefix.bin, - ) + for i, args in enumerate(options): + with test_part(self, f"test_{exName}_{i+1}", purpose=" ".join(args)): + exe(*args) + + def test_NlpMdsEx1(self): + """Test NlpMdsEx1""" + self.run_hiop(False) + + def test_NlpMdsEx1Raja(self): + """Test NlpMdsEx1 with +raja""" + if "+raja" not in self.spec: + raise SkipTest("Package must be installed with +raja") + self.run_hiop(True) diff --git a/var/spack/repos/builtin/packages/hip-examples/package.py b/var/spack/repos/builtin/packages/hip-examples/package.py index 22f5705389649a..279ecb4ddde96f 100644 --- a/var/spack/repos/builtin/packages/hip-examples/package.py +++ b/var/spack/repos/builtin/packages/hip-examples/package.py @@ -24,6 +24,10 @@ class HipExamples(Package): version("5.5.0", sha256="bea8a4155bbfbdb3bc1f83c22e4bd1214b1b4e1840b58dc7d37704620de5b103") version("5.4.3", sha256="053b8b7892e2929e3f90bd978d8bb1c9801e4803eadd7d97fc6692ce60af1d47") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + patch("0001-add-inc-and-lib-paths-to-openmp-helloworld.patch") patch("0002-add-fpic-compile-to-add4.patch") diff --git a/var/spack/repos/builtin/packages/hip-rocclr/package.py b/var/spack/repos/builtin/packages/hip-rocclr/package.py index cd9f409da9e400..420e3954becf88 100644 --- a/var/spack/repos/builtin/packages/hip-rocclr/package.py +++ b/var/spack/repos/builtin/packages/hip-rocclr/package.py @@ -28,37 +28,24 @@ class HipRocclr(CMakePackage): version("5.6.0", sha256="864f87323e793e60b16905284fba381a7182b960dd4a37fb67420c174442c03c") version("5.5.1", sha256="1375fc7723cfaa0ae22a78682186d4804188b0a54990bfd9c0b8eb421b85e37e") version("5.5.0", sha256="efbae9a1ef2ab3de5ca44091e9bb78522e76759c43524c1349114f9596cc61d1") - version("5.4.3", sha256="71d9668619ab57ec8a4564d11860438c5aad5bd161a3e58fbc49555fbd59182d") - version("5.4.0", sha256="46a1579310b3ab9dc8948d0fb5bed4c6b312f158ca76967af7ab69e328d43138") - version("5.3.3", sha256="f8133a5934f9c53b253d324876d74f08a19e2f5b073bc94a62fe64b0d2183a18") - version("5.3.0", sha256="2bf14116b5e2270928265f5d417b3d0f0f2e13cbc8ec5eb8c80d4d4a58ff7e94") with default_args(deprecated=True): + version("5.4.3", sha256="71d9668619ab57ec8a4564d11860438c5aad5bd161a3e58fbc49555fbd59182d") + version("5.4.0", sha256="46a1579310b3ab9dc8948d0fb5bed4c6b312f158ca76967af7ab69e328d43138") + version("5.3.3", sha256="f8133a5934f9c53b253d324876d74f08a19e2f5b073bc94a62fe64b0d2183a18") + version("5.3.0", sha256="2bf14116b5e2270928265f5d417b3d0f0f2e13cbc8ec5eb8c80d4d4a58ff7e94") version("5.2.3", sha256="0493c414d4db1af8e1eb30a651d9512044644244488ebb13478c2138a7612998") version("5.2.1", sha256="465ca9fa16869cd89dab8c2d66d9b9e3c14f744bbedaa1d215b0746d77a500ba") version("5.2.0", sha256="37f5fce04348183bce2ece8bac1117f6ef7e710ca68371ff82ab08e93368bafb") version("5.1.3", sha256="ddee63cdc6515c90bab89572b13e1627b145916cb8ede075ef8446cbb83f0a48") version("5.1.0", sha256="f4f265604b534795a275af902b2c814f416434d9c9e16db81b3ed5d062187dfa") + depends_on("cxx", type="build") # generated + depends_on("cmake@3:", type="build") depends_on("gl@4.5:", type="link") depends_on("numactl", type="link") - for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", - "5.3.0", - "5.3.3", - "5.4.0", - "5.4.3", - "5.5.0", - "5.5.1", - "5.6.0", - "5.6.1", - "master", - ]: + for ver in ["5.3.0", "5.3.3", "5.4.0", "5.4.3", "5.5.0", "5.5.1", "5.6.0", "5.6.1", "master"]: depends_on(f"hsakmt-roct@{ver}", when=f"@{ver}") depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") depends_on(f"comgr@{ver}", when=f"@{ver}") @@ -73,11 +60,6 @@ class HipRocclr(CMakePackage): ("5.4.0", "a294639478e76c75dac0e094b418f9bd309309b07faf6af126cdfad9aab3c5c7"), ("5.3.3", "cab394e6ef16c35bab8de29a66b96a7dc0e7d1297aaacba3718fa1d369233c9f"), ("5.3.0", "d251e2efe95dc12f536ce119b2587bed64bbda013969fa72be58062788044a9e"), - ("5.2.3", "932ea3cd268410010c0830d977a30ef9c14b8c37617d3572a062b5d4595e2b94"), - ("5.2.1", "eb4ff433f8894ca659802f81792646034f8088b47aca6ad999292bcb8d6381d5"), - ("5.2.0", "80f73387effdcd987a150978775a87049a976aa74f5770d4420847b004dd59f0"), - ("5.1.3", "44a7fac721abcd93470e1a7e466bdea0c668c253dee93e4f1ea9a72dbce4ba31"), - ("5.1.0", "362d81303048cf7ed5d2f69fb65ed65425bc3da4734fff83e3b8fbdda51b0927"), ]: resource( name="opencl-on-vdi", diff --git a/var/spack/repos/builtin/packages/hip-tensor/package.py b/var/spack/repos/builtin/packages/hip-tensor/package.py index bddebe34e15533..9d0c887726647c 100644 --- a/var/spack/repos/builtin/packages/hip-tensor/package.py +++ b/var/spack/repos/builtin/packages/hip-tensor/package.py @@ -11,20 +11,35 @@ class HipTensor(CMakePackage, ROCmPackage): homepage = "https://github.com/ROCm/hipTensor" git = "https://github.com/ROCm/hipTensor.git" - url = "https://github.com/ROCm/hipTensor/archive/refs/tags/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/hipTensor/archive/refs/tags/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "afzpatel") version("master", branch="master") + version("6.1.2", sha256="ac0e07a3019bcce4a0a98aafa4922d5fc9e953bed07084abef5306c851717783") + version("6.1.1", sha256="09bcdbf6b1d20dc4d75932abd335a9a534b16a8343858121daa5813a38f5ad3a") + version("6.1.0", sha256="9cc43b1b3394383f22f30e194d8753ca6ff1887c83ec1de5823cb2e94976eeed") version("6.0.2", sha256="6e6e7530eabbd1fb28b83efa5a49c19a6642d40e1554224ebb1e0a5999045e27") version("6.0.0", sha256="268d7f114784b7e824f89c21c65c2efedbb5486f09a356a56dca1b89bde1ef7a") version("5.7.1", sha256="96743d4e695fe865aef4097ae31d9b4e42a2d5a92135a005b0d187d9c0b17645") version("5.7.0", sha256="4b17f6d43b17fe2dc1d0c61e9663d4752006f7898cc94231206444a1663eb252") - for ver in ["5.7.0", "5.7.1", "6.0.0", "6.0.2", "master"]: + depends_on("cxx", type="build") # generated + + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") + + for ver in ["5.7.0", "5.7.1", "6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2", "master"]: depends_on(f"composable-kernel@{ver}", when=f"@{ver}") depends_on(f"rocm-cmake@{ver}", when=f"@{ver}") + for ver in ["6.1.0", "6.1.1", "6.1.2"]: + depends_on(f"hipcc@{ver}", when=f"@{ver}") + def setup_build_environment(self, env): - env.set("CXX", self.spec["hip"].hipcc) + if self.spec.satisfies("@6.1"): + env.set("CXX", self.spec["hipcc"].prefix.bin.hipcc) + else: + env.set("CXX", self.spec["hip"].hipcc) + if self.spec.satisfies("+asan"): + self.asan_on(env) diff --git a/var/spack/repos/builtin/packages/hip/0011-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.0.2.patch b/var/spack/repos/builtin/packages/hip/0011-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.0.2.patch deleted file mode 100644 index 9308e8635c534d..00000000000000 --- a/var/spack/repos/builtin/packages/hip/0011-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.0.2.patch +++ /dev/null @@ -1,78 +0,0 @@ -diff --git a/bin/hipcc.pl b/bin/hipcc.pl -index 7b84067..9acccc0 100755 ---- a/bin/hipcc.pl -+++ b/bin/hipcc.pl -@@ -605,7 +605,8 @@ if($HIP_PLATFORM eq "amd"){ - $targetsStr = $ENV{HCC_AMDGPU_TARGET}; - } elsif (not $isWindows) { - # Else try using rocm_agent_enumerator -- $ROCM_AGENT_ENUM = "${ROCM_PATH}/bin/rocm_agent_enumerator"; -+ $ROCMINFO_PATH = $ENV{'ROCMINFO_PATH'} // $ROCM_PATH; -+ $ROCM_AGENT_ENUM = "${ROCMINFO_PATH}/bin/rocm_agent_enumerator"; - $targetsStr = `${ROCM_AGENT_ENUM} -t GPU`; - $targetsStr =~ s/\n/,/g; - } -diff --git a/hipamd/CMakeLists.txt b/hipamd/CMakeLists.txt -index 20b45aa..d463d1a 100755 ---- a/hipamd/CMakeLists.txt -+++ b/hipamd/CMakeLists.txt -@@ -90,7 +90,18 @@ string(REPLACE "-" ";" VERSION_LIST ${HIP_VERSION_PATCH_GITHASH}) - list(GET VERSION_LIST 0 HIP_VERSION_PATCH) - set(HIP_VERSION_GITDATE 0) - --find_package(Git) -+if (IS_DIRECTORY "${PROJECT_SOURCE_DIR}/.git") -+ find_package(Git) -+endif() -+ -+set(HIP_PACKAGING_VERSION_PATCH "0") -+set(HIP_VERSION_GITDATE "0") -+set(HIP_VERSION_PATCH "0") -+set(HIP_VERSION_GITHASH "0") -+set(HIP_VERSION_PATCH_GITHASH "0") -+set (HIP_LIB_VERSION_PATCH "0") -+set(HIP_VERSION_BUILD_ID 0) -+set(HIP_VERSION_BUILD_NAME "") - - # FIXME: Two different version strings used. - # Below we use UNIX commands, not compatible with Windows. -@@ -138,9 +149,6 @@ if(GIT_FOUND) - else() - set(HIP_PACKAGING_VERSION_PATCH ${HIP_VERSION_PATCH}-${HIP_VERSION_GITHASH}) - endif() --else() -- # FIXME: Some parts depend on this being set. -- set(HIP_PACKAGING_VERSION_PATCH "0") - endif() - - ## Debian package specific variables -@@ -183,7 +191,7 @@ set (HIP_LIB_VERSION_MINOR ${HIP_VERSION_MINOR}) - if (${ROCM_PATCH_VERSION} ) - set (HIP_LIB_VERSION_PATCH ${ROCM_PATCH_VERSION}) - else () -- set (HIP_LIB_VERSION_PATCH ${HIP_VERSION_PATCH}-${HIP_VERSION_GITHASH}) -+ set (HIP_LIB_VERSION_PATCH "0") - endif () - set (HIP_LIB_VERSION_STRING "${HIP_LIB_VERSION_MAJOR}.${HIP_LIB_VERSION_MINOR}.${HIP_LIB_VERSION_PATCH}") - if (DEFINED ENV{ROCM_RPATH}) -diff --git a/hipamd/hip-config.cmake.in b/hipamd/hip-config.cmake.in -index 274e3f1..2d024a8 100755 ---- a/hipamd/hip-config.cmake.in -+++ b/hipamd/hip-config.cmake.in -@@ -215,7 +215,7 @@ if(HIP_RUNTIME MATCHES "rocclr") - - if(NOT WIN32) - set_target_properties(hip::device PROPERTIES -- INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/../include" -+ INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include" - INTERFACE_SYSTEM_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/../include" - ) - endif() -@@ -286,7 +286,6 @@ if(HIP_COMPILER STREQUAL "clang") - if(CLANGRT_BUILTINS-NOTFOUND) - message(FATAL_ERROR "clangrt builtins lib not found") - else() -- set_property(TARGET hip::host APPEND PROPERTY INTERFACE_LINK_LIBRARIES "${CLANGRT_BUILTINS}") - set_property(TARGET hip::device APPEND PROPERTY INTERFACE_LINK_LIBRARIES "${CLANGRT_BUILTINS}") - endif() - endif() diff --git a/var/spack/repos/builtin/packages/hip/0012-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.2.0.patch b/var/spack/repos/builtin/packages/hip/0012-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.2.0.patch deleted file mode 100644 index 3c44a29bbd7298..00000000000000 --- a/var/spack/repos/builtin/packages/hip/0012-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.2.0.patch +++ /dev/null @@ -1,78 +0,0 @@ -From d3d2b2b69ac04ac1d1ead30f546fb4884fb93e27 Mon Sep 17 00:00:00 2001 -From: Renjith Ravindran -Date: Mon, 8 Aug 2022 22:26:13 +0000 -Subject: [PATCH] Improve compilation without git repo and remove compiler rt - linkage for host and correction in CMake target path variable - ---- - bin/hipcc.pl | 3 ++- - hipamd/CMakeLists.txt | 12 +++++++++--- - hipamd/hip-config.cmake.in | 1 - - 3 files changed, 11 insertions(+), 5 deletions(-) - -diff --git a/bin/hipcc.pl b/bin/hipcc.pl -index 1ef3a90..995abe5 100755 ---- a/bin/hipcc.pl -+++ b/bin/hipcc.pl -@@ -605,7 +605,8 @@ if($HIP_PLATFORM eq "amd"){ - $targetsStr = $ENV{HCC_AMDGPU_TARGET}; - } elsif (not $isWindows) { - # Else try using rocm_agent_enumerator -- $ROCM_AGENT_ENUM = "${ROCM_PATH}/bin/rocm_agent_enumerator"; -+ $ROCMINFO_PATH = $ENV{'ROCMINFO_PATH'} // $ROCM_PATH; -+ $ROCM_AGENT_ENUM = "${ROCMINFO_PATH}/bin/rocm_agent_enumerator"; - $targetsStr = `${ROCM_AGENT_ENUM} -t GPU`; - $targetsStr =~ s/\n/,/g; - } -diff --git a/hipamd/CMakeLists.txt b/hipamd/CMakeLists.txt -index 9591924..4f50c2a 100755 ---- a/hipamd/CMakeLists.txt -+++ b/hipamd/CMakeLists.txt -@@ -91,7 +91,13 @@ string(REPLACE "-" ";" VERSION_LIST ${HIP_VERSION_PATCH_GITHASH}) - list(GET VERSION_LIST 0 HIP_VERSION_PATCH) - set(HIP_VERSION_GITDATE 0) - --find_package(Git) -+if (IS_DIRECTORY "${PROJECT_SOURCE_DIR}/.git") -+ find_package(Git) -+endif() -+set(HIP_VERSION_GITDATE "0") -+set(HIP_VERSION_GITHASH "0") -+set(HIP_VERSION_BUILD_ID 0) -+set(HIP_VERSION_BUILD_NAME "") - - # FIXME: Two different version strings used. - # Below we use UNIX commands, not compatible with Windows. -@@ -183,7 +189,7 @@ set (HIP_LIB_VERSION_MINOR ${HIP_VERSION_MINOR}) - if (${ROCM_PATCH_VERSION} ) - set (HIP_LIB_VERSION_PATCH ${ROCM_PATCH_VERSION}) - else () -- set (HIP_LIB_VERSION_PATCH ${HIP_VERSION_PATCH}-${HIP_VERSION_GITHASH}) -+ set (HIP_LIB_VERSION_PATCH "0") - endif () - set (HIP_LIB_VERSION_STRING "${HIP_LIB_VERSION_MAJOR}.${HIP_LIB_VERSION_MINOR}.${HIP_LIB_VERSION_PATCH}") - if (DEFINED ENV{ROCM_RPATH}) -@@ -395,7 +401,7 @@ if(NOT ${INSTALL_SOURCE} EQUAL 0) - if(WIN32) - install(DIRECTORY ${HIP_COMMON_DIR}/cmake DESTINATION .) - else() -- install(DIRECTORY ${HIP_COMMON_DIR}/cmake/ DESTINATION CONFIG_PACKAGE_INSTALL_DIR) -+ install(DIRECTORY ${HIP_COMMON_DIR}/cmake/ DESTINATION ${CONFIG_PACKAGE_INSTALL_DIR}) - endif() - endif() - -diff --git a/hipamd/hip-config.cmake.in b/hipamd/hip-config.cmake.in -index ba3e75c..02dd586 100755 ---- a/hipamd/hip-config.cmake.in -+++ b/hipamd/hip-config.cmake.in -@@ -290,7 +290,6 @@ if(HIP_COMPILER STREQUAL "clang") - if(CLANGRT_BUILTINS-NOTFOUND) - message(FATAL_ERROR "clangrt builtins lib not found") - else() -- set_property(TARGET hip::host APPEND PROPERTY INTERFACE_LINK_LIBRARIES "${CLANGRT_BUILTINS}") - set_property(TARGET hip::device APPEND PROPERTY INTERFACE_LINK_LIBRARIES "${CLANGRT_BUILTINS}") - endif() - endif() --- -2.25.1 - diff --git a/var/spack/repos/builtin/packages/hip/0012-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.2.1.patch b/var/spack/repos/builtin/packages/hip/0012-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.2.1.patch deleted file mode 100644 index e332f90ee4e6d0..00000000000000 --- a/var/spack/repos/builtin/packages/hip/0012-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host.5.2.1.patch +++ /dev/null @@ -1,71 +0,0 @@ -From 526da7995578ef12908a297ae6fef4db0488253e Mon Sep 17 00:00:00 2001 -From: sreenivasa murthy kolam -Date: Tue, 16 Aug 2022 04:09:46 +0000 -Subject: [PATCH] Improve compilation without git repo and remove compiler rt - linkage-for-host - ---- - bin/hipcc.pl | 3 ++- - hipamd/CMakeLists.txt | 11 ++++++++--- - hipamd/hip-config.cmake.in | 1 - - 3 files changed, 10 insertions(+), 5 deletions(-) - -diff --git a/bin/hipcc.pl b/bin/hipcc.pl -index 1ef3a90..995abe5 100755 ---- a/bin/hipcc.pl -+++ b/bin/hipcc.pl -@@ -605,7 +605,8 @@ if($HIP_PLATFORM eq "amd"){ - $targetsStr = $ENV{HCC_AMDGPU_TARGET}; - } elsif (not $isWindows) { - # Else try using rocm_agent_enumerator -- $ROCM_AGENT_ENUM = "${ROCM_PATH}/bin/rocm_agent_enumerator"; -+ $ROCMINFO_PATH = $ENV{'ROCMINFO_PATH'} // $ROCM_PATH; -+ $ROCM_AGENT_ENUM = "${ROCMINFO_PATH}/bin/rocm_agent_enumerator"; - $targetsStr = `${ROCM_AGENT_ENUM} -t GPU`; - $targetsStr =~ s/\n/,/g; - } -diff --git a/hipamd/CMakeLists.txt b/hipamd/CMakeLists.txt -index f425504..831b192 100755 ---- a/hipamd/CMakeLists.txt -+++ b/hipamd/CMakeLists.txt -@@ -89,9 +89,14 @@ list(GET VERSION_LIST 1 HIP_VERSION_MINOR) - list(GET VERSION_LIST 2 HIP_VERSION_PATCH_GITHASH) - string(REPLACE "-" ";" VERSION_LIST ${HIP_VERSION_PATCH_GITHASH}) - list(GET VERSION_LIST 0 HIP_VERSION_PATCH) --set(HIP_VERSION_GITDATE 0) -+if (IS_DIRECTORY "${PROJECT_SOURCE_DIR}/.git") -+ find_package(Git) -+endif() -+set(HIP_VERSION_GITDATE "0") -+set(HIP_VERSION_GITHASH "0") -+set(HIP_VERSION_BUILD_ID 0) -+set(HIP_VERSION_BUILD_NAME "") - --find_package(Git) - - # FIXME: Two different version strings used. - # Below we use UNIX commands, not compatible with Windows. -@@ -183,7 +188,7 @@ set (HIP_LIB_VERSION_MINOR ${HIP_VERSION_MINOR}) - if (${ROCM_PATCH_VERSION} ) - set (HIP_LIB_VERSION_PATCH ${ROCM_PATCH_VERSION}) - else () -- set (HIP_LIB_VERSION_PATCH ${HIP_VERSION_PATCH}-${HIP_VERSION_GITHASH}) -+ set (HIP_LIB_VERSION_PATCH ${HIP_VERSION_PATCH}) - endif () - set (HIP_LIB_VERSION_STRING "${HIP_LIB_VERSION_MAJOR}.${HIP_LIB_VERSION_MINOR}.${HIP_LIB_VERSION_PATCH}") - if (DEFINED ENV{ROCM_RPATH}) -diff --git a/hipamd/hip-config.cmake.in b/hipamd/hip-config.cmake.in -index ba3e75c..02dd586 100755 ---- a/hipamd/hip-config.cmake.in -+++ b/hipamd/hip-config.cmake.in -@@ -290,7 +290,6 @@ if(HIP_COMPILER STREQUAL "clang") - if(CLANGRT_BUILTINS-NOTFOUND) - message(FATAL_ERROR "clangrt builtins lib not found") - else() -- set_property(TARGET hip::host APPEND PROPERTY INTERFACE_LINK_LIBRARIES "${CLANGRT_BUILTINS}") - set_property(TARGET hip::device APPEND PROPERTY INTERFACE_LINK_LIBRARIES "${CLANGRT_BUILTINS}") - endif() - endif() --- -2.18.4 - diff --git a/var/spack/repos/builtin/packages/hip/0014-remove-compiler-rt-linkage-for-host.6.0.patch b/var/spack/repos/builtin/packages/hip/0014-remove-compiler-rt-linkage-for-host.6.0.patch index 597baa2e5d1a63..3dc0e6ac0c85b7 100644 --- a/var/spack/repos/builtin/packages/hip/0014-remove-compiler-rt-linkage-for-host.6.0.patch +++ b/var/spack/repos/builtin/packages/hip/0014-remove-compiler-rt-linkage-for-host.6.0.patch @@ -28,34 +28,3 @@ index 7ad3001..aaf6ad0 100755 endif() ############################# -diff --git a/hipcc/bin/hipcc.pl b/hipcc/bin/hipcc.pl -index 513a427..cd2d6ac 100755 ---- a/hipcc/bin/hipcc.pl -+++ b/hipcc/bin/hipcc.pl -@@ -160,11 +160,14 @@ if ($HIP_PLATFORM eq "amd") { - if($isWindows) { - $execExtension = ".exe"; - } -- $HIPCC=get_normalized_path("$HIP_CLANG_PATH/clang++" . $execExtension); -+ # llvm_path is set inside the hip recipe -+ $LLVM_PATH= $ENV{'LLVM_PATH'}; -+ $HIPCC="${LLVM_PATH}/bin/clang++" . $execExtension; - - # If $HIPCC clang++ is not compiled, use clang instead - if ( ! -e $HIPCC ) { -- $HIPCC=get_normalized_path("$HIP_CLANG_PATH/clang" . $execExtension); -+ $LLVM_PATH= $ENV{'LLVM_PATH'}; -+ $HIPCC="${LLVM_PATH}/bin/clang" . $execExtension; - $HIPLDFLAGS = "--driver-mode=g++"; - } - # to avoid using dk linker or MSVC linker -@@ -484,7 +487,8 @@ if($HIP_PLATFORM eq "amd"){ - $targetsStr = $ENV{HCC_AMDGPU_TARGET}; - } elsif (not $isWindows) { - # Else try using rocm_agent_enumerator -- $ROCM_AGENT_ENUM = "${ROCM_PATH}/bin/rocm_agent_enumerator"; -+ $ROCMINFO_PATH = $ENV{'ROCMINFO_PATH'} // $ROCMINFO_PATH; -+ $ROCM_AGENT_ENUM = "${ROCMINFO_PATH}/bin/rocm_agent_enumerator"; - $targetsStr = `${ROCM_AGENT_ENUM} -t GPU`; - $targetsStr =~ s/\n/,/g; - } diff --git a/var/spack/repos/builtin/packages/hip/0014-remove-compiler-rt-linkage-for-host.6.1.patch b/var/spack/repos/builtin/packages/hip/0014-remove-compiler-rt-linkage-for-host.6.1.patch new file mode 100644 index 00000000000000..d8ef3a558b484c --- /dev/null +++ b/var/spack/repos/builtin/packages/hip/0014-remove-compiler-rt-linkage-for-host.6.1.patch @@ -0,0 +1,21 @@ +diff --git a/clr/hipamd/CMakeLists.txt b/clr/hipamd/CMakeLists.txt +index ccfbcee..8c3752f 100755 +--- a/clr/hipamd/CMakeLists.txt ++++ b/clr/hipamd/CMakeLists.txt +@@ -300,16 +300,6 @@ if(HIP_RUNTIME STREQUAL "rocclr") + add_subdirectory(src) + endif() + +-# Download libamdhip64.so.5 +-if(HIP_PLATFORM STREQUAL "amd") +- if(NOT WIN32) +- execute_process(COMMAND sh -c "${CMAKE_CURRENT_SOURCE_DIR}/download_libamhip64_v5.sh" WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND_ECHO STDERR RESULT_VARIABLE DWLD_HIP_SO_RC) +- if (DWLD_HIP_SO_RC AND NOT DWLD_HIP_SO_RC EQUAL 0) +- message(FATAL_ERROR "Failed to download libamdhip64.so.5") +- endif() +- endif() +-endif() +- + # Build doxygen documentation + find_program(DOXYGEN_EXE doxygen) + if(DOXYGEN_EXE) diff --git a/var/spack/repos/builtin/packages/hip/package.py b/var/spack/repos/builtin/packages/hip/package.py index d972fa4d76435a..7bd920a6b8d886 100644 --- a/var/spack/repos/builtin/packages/hip/package.py +++ b/var/spack/repos/builtin/packages/hip/package.py @@ -18,7 +18,7 @@ class Hip(CMakePackage): homepage = "https://github.com/ROCm/HIP" git = "https://github.com/ROCm/HIP.git" - url = "https://github.com/ROCm/HIP/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/HIP/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath", "haampie") @@ -27,6 +27,9 @@ class Hip(CMakePackage): license("MIT") version("master", branch="master") + version("6.1.2", sha256="9ba5f70a553b48b2cea25c7e16b97ad49320750c0152763b173b63b9f151e783") + version("6.1.1", sha256="09e8013b8071fca2cf914758001bbd1dccaa237e798e945970e4356cb9b90050") + version("6.1.0", sha256="6fd57910a16d0b54df822807e67b6207146233a2de5a46c6a05b940a21e2c4d7") version("6.0.2", sha256="b47178db94f2acc106e1a88ceb029844805266ebaba11ef63744e90d224b11be") version("6.0.0", sha256="0d575788e0b731124a8489a36652014a165b9ebab92d5456ec3c976e062f3a82") version("5.7.1", sha256="eaa0e14a9ae45c58ed37863797b683a7778b3cbbf92f5b6529ec65fd61d61f3e") @@ -35,16 +38,11 @@ class Hip(CMakePackage): version("5.6.0", sha256="a8237768c1ae70029d972376f8d279f4de18a1e6106fff6215d1e16847bc375e") version("5.5.1", sha256="1f5f6bb72d8d64335ccc8242ef2e2ea8efeb380cce2997f475b1ee77528d9fb4") version("5.5.0", sha256="5b0d0253e62f85cc21d043513f7c11c64e4a4ec416159668f0b160d732d09a3c") - version("5.4.3", sha256="23e51d3af517cd63019f8d199e46b84d5a18251d148e727f3985e8d99ccb0e58") - version("5.4.0", sha256="e290f835d69ef23e8b5833a7e616b0a989ff89ada4412d9742430819546efc6c") - version("5.3.3", sha256="51d4049dc37d261afb9e1270e60e112708ff06b470721ff21023e16e040e4403") - version("5.3.0", sha256="05225832fb5a4d24f49a773ac27e315239943a6f24291a50d184e2913f2cdbe0") with default_args(deprecated=True): - version("5.2.3", sha256="5b83d1513ea4003bfad5fe8fa741434104e3e49a87e1d7fad49e5a8c1d06e57b") - version("5.2.1", sha256="7d4686a2f8a9124bb21f7f3958e451c57019f48a0cbb42ffdc56ed02860a46c3") - version("5.2.0", sha256="a6e0515d4d25865c037b546035df9c51f0882cd2700e759c266ff7e199f37c3a") - version("5.1.3", sha256="ce755ee6e407904eba3f6b3c9efcdd48eb4f58a26b06e1892166d05f19a75973") - version("5.1.0", sha256="47e542183699f4005c48631d96f6a1fbdf27e07ad3402ccd7b5f707c2c602266") + version("5.4.3", sha256="23e51d3af517cd63019f8d199e46b84d5a18251d148e727f3985e8d99ccb0e58") + version("5.4.0", sha256="e290f835d69ef23e8b5833a7e616b0a989ff89ada4412d9742430819546efc6c") + version("5.3.3", sha256="51d4049dc37d261afb9e1270e60e112708ff06b470721ff21023e16e040e4403") + version("5.3.0", sha256="05225832fb5a4d24f49a773ac27e315239943a6f24291a50d184e2913f2cdbe0") variant("rocm", default=True, description="Enable ROCm support") variant("cuda", default=False, description="Build with CUDA") @@ -54,6 +52,7 @@ class Hip(CMakePackage): depends_on("cuda", when="+cuda") depends_on("cmake@3.16.8:", type="build") + depends_on("libedit", type="build") depends_on("perl@5.10:", type=("build", "run")) test_requires_compiler = True @@ -62,11 +61,6 @@ class Hip(CMakePackage): depends_on("gl@4.5:") depends_on("py-cppheaderparser", type="build", when="@5.3.3:") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -79,6 +73,9 @@ class Hip(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hsakmt-roct@{ver}", when=f"@{ver}") depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") @@ -98,15 +95,33 @@ class Hip(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: - depends_on("hipify-clang", when=f"@{ver}") + depends_on(f"hipify-clang@{ver}", when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") # hipcc likes to add `-lnuma` by default :( # ref https://github.com/ROCm/HIP/pull/2202 depends_on("numactl", when="@3.7.0:") + for ver in ["6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: + depends_on(f"hipcc@{ver}", when=f"@{ver}") + # roc-obj-ls requirements depends_on("perl-file-which") depends_on("perl-uri-encode") @@ -119,11 +134,6 @@ class Hip(CMakePackage): ("5.4.0", "c4b79738eb6e669160382b6c47d738ac59bd493fc681ca400ff012a2e8212955"), ("5.3.3", "36acce92af39b0fa06002e164f5a7f5a9c7daa19bf96645361325775a325499d"), ("5.3.0", "81e9bd5209a7b400c986f9bf1d7079bcf7169bbcb06fc4fe843644559a4d612e"), - ("5.2.3", "5031d07554ce07620e24e44d482cbc269fa972e3e35377e935d2694061ff7c04"), - ("5.2.1", "4feaa3883cbc54ddcd5d2d5becbe0f3fe3edd5b3b468dc73b5104893029eefac"), - ("5.2.0", "8774958bebc29a4b7eb9dc2d38808d79d9a24bf9c1f44e801ff99d2d5ba82240"), - ("5.1.3", "707f2217f0e7aeb62d7b76830a271056d665542bf5f7a54e40adf4d5f299ca93"), - ("5.1.0", "77984854bfe00f938353fe4c7604d09967eaf5c609d05f1e6423d3c3dea86e61"), ]: resource( name="hipamd", @@ -142,11 +152,6 @@ class Hip(CMakePackage): ("5.4.0", "a294639478e76c75dac0e094b418f9bd309309b07faf6af126cdfad9aab3c5c7"), ("5.3.3", "cab394e6ef16c35bab8de29a66b96a7dc0e7d1297aaacba3718fa1d369233c9f"), ("5.3.0", "d251e2efe95dc12f536ce119b2587bed64bbda013969fa72be58062788044a9e"), - ("5.2.3", "932ea3cd268410010c0830d977a30ef9c14b8c37617d3572a062b5d4595e2b94"), - ("5.2.1", "eb4ff433f8894ca659802f81792646034f8088b47aca6ad999292bcb8d6381d5"), - ("5.2.0", "80f73387effdcd987a150978775a87049a976aa74f5770d4420847b004dd59f0"), - ("5.1.3", "44a7fac721abcd93470e1a7e466bdea0c668c253dee93e4f1ea9a72dbce4ba31"), - ("5.1.0", "362d81303048cf7ed5d2f69fb65ed65425bc3da4734fff83e3b8fbdda51b0927"), ]: resource( name="opencl", @@ -164,11 +169,6 @@ class Hip(CMakePackage): ("5.4.0", "46a1579310b3ab9dc8948d0fb5bed4c6b312f158ca76967af7ab69e328d43138"), ("5.3.3", "f8133a5934f9c53b253d324876d74f08a19e2f5b073bc94a62fe64b0d2183a18"), ("5.3.0", "2bf14116b5e2270928265f5d417b3d0f0f2e13cbc8ec5eb8c80d4d4a58ff7e94"), - ("5.2.3", "0493c414d4db1af8e1eb30a651d9512044644244488ebb13478c2138a7612998"), - ("5.2.1", "465ca9fa16869cd89dab8c2d66d9b9e3c14f744bbedaa1d215b0746d77a500ba"), - ("5.2.0", "37f5fce04348183bce2ece8bac1117f6ef7e710ca68371ff82ab08e93368bafb"), - ("5.1.3", "ddee63cdc6515c90bab89572b13e1627b145916cb8ede075ef8446cbb83f0a48"), - ("5.1.0", "f4f265604b534795a275af902b2c814f416434d9c9e16db81b3ed5d062187dfa"), ]: resource( name="rocclr", @@ -181,6 +181,9 @@ class Hip(CMakePackage): ) # Add hip-clr sources thru the below for d_version, d_shasum in [ + ("6.1.2", "1a1e21640035d957991559723cd093f0c7e202874423667d2ba0c7662b01fea4"), + ("6.1.1", "2db02f335c9d6fa69befcf7c56278e5cecfe3db0b457eaaa41206c2585ef8256"), + ("6.1.0", "49b23eef621f4e8e528bb4de8478a17436f42053a2f7fde21ff221aa683205c7"), ("6.0.2", "cb8ac610c8d4041b74fb3129c084f1e7b817ce1a5a9943feca1fa7531dc7bdcc"), ("6.0.0", "798b55b5b5fb90dd19db54f136d8d8e1da9ae1e408d5b12b896101d635f97e50"), ("5.7.1", "c78490335233a11b4d8a5426ace7417c555f5e2325de10422df06c0f0f00f7eb"), @@ -204,19 +207,17 @@ class Hip(CMakePackage): "https://github.com/ROCm/clr/commit/c4f773db0b4ccbbeed4e3d6c0f6bff299c2aa3f0.patch?full_index=1", sha256="5bb9b0e08888830ccf3a0a658529fe25f4ee62b5b8890f349bf2cc914236eb2f", working_dir="clr", - when="@5.7:", + when="@5.7:6.0", ) patch( "https://github.com/ROCm/clr/commit/7868876db742fb4d44483892856a66d2993add03.patch?full_index=1", sha256="7668b2a710baf4cb063e6b00280fb75c4c3e0511575e8298a9c7ae5143f60b33", working_dir="clr", - when="@5.7:", + when="@5.7:6.0", ) # Add hipcc sources thru the below for d_version, d_shasum in [ - ("6.0.2", "d6209b14fccdd00d7231dec4b4f962aa23914b9dde389ba961370e8ba918bde5"), - ("6.0.0", "e9cfaaecaf0e6ed363946439197f340c115e8e1189f96dbd716cf20245c29255"), ("5.7.1", "d47d27ef2b5de7f49cdfd8547832ac9b437a32e6fc6f0e9c1646f4b704c90aee"), ("5.7.0", "9f839bf7226e5e26f3150f8ba6eca507ab9a668e68b207736301b3bb9040c973"), ("5.6.1", "5800fac92b841ef6f52acda78d9bf86f83970bec0fb848a6265d239bdb7eb51a"), @@ -231,8 +232,29 @@ class Hip(CMakePackage): placement="hipcc", when=f"@{d_version}", ) + # Add hipother sources thru the below + for d_version, d_shasum in [ + ("6.1.2", "2740d1e3dcf1f2d07d2a8db6acf4c972941ae392172b83fd8ddcfe8706a40d0b"), + ("6.1.1", "8b975623c8ed1db53feea2cfd5d29f2a615e890aee1157d0d17adeb97200643f"), + ("6.1.0", "43a48ccc82f705a15852392ee7419e648d913716bfc04063a53d2d17979b1b46"), + ("6.0.2", "0bebb3774debcecc0b29a0cc5aa98e373a3ee7acf161503d0d9c9d0ecc8b8010"), + ("6.0.0", "d3bf62cc17c3c44fea52b34bcbf725e7af1afc3542c2884cefcd41f65371f552"), + ]: + resource( + name="hipother", + url=f"https://github.com/ROCm/hipother/archive/refs/tags/rocm-{d_version}.tar.gz", + sha256=d_shasum, + expand=True, + destination="", + placement="hipother", + when=f"@{d_version} +cuda", + ) + # Add hiptests sources thru the below for d_version, d_shasum in [ + ("6.1.2", "5b14e4a30d8d8fb56c43e262009646ba9188eac1c8ff882d9a606a4bec69b56b"), + ("6.1.1", "10c96ee72adf4580056292ab17cfd858a2fd7bc07abeb41c6780bd147b47f7af"), + ("6.1.0", "cf3a6a7c43116032d933cc3bc88bfc4b17a4ee1513c978e751755ca11a5ed381"), ("6.0.2", "740ca064f4909c20d83226a63c2f164f7555783ec5f5f70be5bc23d3587ad829"), ("6.0.0", "e8f92a0f5d1f6093ca1fb24ff1b7140128900fcdc6e9f01f153d6907e5c2d807"), ("5.7.1", "28fbdf49f405adfee903bc0f05a43ac392c55b34c514c3582dfb7d6d67e79985"), @@ -249,35 +271,20 @@ class Hip(CMakePackage): placement="hip-tests", when=f"@{d_version}", ) - patch( - "0011-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host" - ".5.0.2.patch", - when="@5.0.2:5.1.3", - ) # Improve compilation without git repo and remove compiler rt linkage # for host and correction in CMake target path variable and # correcting the CMake path variable. - patch( - "0012-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host" - ".5.2.0.patch", - when="@5.2.0", - ) - patch( - "0012-Improve-compilation-without-git-repo-and-remove-compiler-rt-linkage-for-host" - ".5.2.1.patch", - when="@5.2.1:5.2.3", - ) patch("0013-remove-compiler-rt-linkage-for-host.5.3.0.patch", when="@5.3.0:5.4") - patch("0014-hip-test-file-reorg-5.4.0.patch", when="@5.4.0:5.5") patch("0016-hip-sample-fix-hipMalloc-call.patch", when="@5.4.3:5.5") patch("0014-remove-compiler-rt-linkage-for-host.5.5.0.patch", when="@5.5") patch("0014-remove-compiler-rt-linkage-for-host.5.6.0.patch", when="@5.6.0:5.6") patch("0014-Remove-compiler-rt-linkage-for-host-for-5.7.0.patch", when="@5.7.0:5.7") - patch("0014-remove-compiler-rt-linkage-for-host.6.0.patch", when="@6.0:") + patch("0014-remove-compiler-rt-linkage-for-host.6.0.patch", when="@6.0") + patch("0014-remove-compiler-rt-linkage-for-host.6.1.patch", when="@6.1") patch("0015-reverting-operator-mixup-fix-for-slate.patch", when="@5.6:6.0") - patch("0018-reverting-hipMemoryType-with-memoryType.patch", when="@6.0") + patch("0018-reverting-hipMemoryType-with-memoryType.patch", when="@6.0:") # See https://github.com/ROCm/HIP/pull/3206 patch( @@ -339,11 +346,9 @@ def get_paths(self): "rocminfo": rocm_prefix, "comgr": rocm_prefix, "rocm-device-libs": rocm_prefix, + "hipify-clang": rocm_prefix, } - if self.spec.satisfies("@5.4:"): - paths["hipify-clang"] = rocm_prefix - if self.spec.satisfies("@5.7:"): paths["hip-path"] = rocm_prefix else: @@ -355,14 +360,9 @@ def get_paths(self): "rocminfo": self.spec["rocminfo"].prefix, "comgr": self.spec["comgr"].prefix, "rocm-device-libs": self.spec["llvm-amdgpu"].prefix, + "hipify-clang": self.spec["hipify-clang"].prefix, } - - if self.spec.satisfies("@5.4:"): - paths["hipify-clang"] = self.spec["hipify-clang"].prefix - if "@:3.8.0" in self.spec: - paths["bitcode"] = paths["rocm-device-libs"].lib - else: - paths["bitcode"] = paths["rocm-device-libs"].amdgcn.bitcode + paths["bitcode"] = paths["rocm-device-libs"].amdgcn.bitcode return paths @@ -388,6 +388,8 @@ def set_variables(self, env): env.set("ROCM_PATH", paths["rocm-path"]) if self.spec.satisfies("@5.4:"): env.set("HIPIFY_CLANG_PATH", paths["hipify-clang"]) + if self.spec.satisfies("@6.1:"): + env.prepend_path("LD_LIBRARY_PATH", paths["hsa-rocr-dev"].lib) # hipcc recognizes HIP_PLATFORM == hcc and HIP_COMPILER == clang, even # though below we specified HIP_PLATFORM=rocclr and HIP_COMPILER=clang @@ -415,7 +417,9 @@ def set_variables(self, env): env.set("HIP_DEVICE_LIB_PATH", paths["bitcode"]) # Just the prefix of hip (used in hipcc) - env.set("HIP_PATH", paths["hip-path"]) + # Deprecated in 5.1.0 and breaks hipcc in 5.5.1+ + if self.spec.satisfies("@:5.4"): + env.set("HIP_PATH", paths["hip-path"]) # Used in comgr and seems necessary when using the JIT compiler, e.g. # hiprtcCreateProgram: @@ -500,6 +504,7 @@ def patch(self): if self.spec.satisfies("@5.6:"): with working_dir("clr/hipamd/bin"): filter_file("^#!/usr/bin/perl", f"#!{perl}", "roc-obj-extract", "roc-obj-ls") + if self.spec.satisfies("@5.6:5.7"): with working_dir("hipcc/bin"): filter_shebang("hipconfig") @@ -508,7 +513,7 @@ def patch(self): if self.spec.satisfies("@:5.5"): with working_dir("bin"): filter_file(" -lnuma", f" -L{numactl} -lnuma", "hipcc") - elif self.spec.satisfies("@5.6:"): + elif self.spec.satisfies("@5.6:5.7"): with working_dir("hipcc/src"): filter_file(" -lnuma", f" -L{numactl} -lnuma", "hipBin_amd.h") @@ -525,8 +530,12 @@ def cmake_args(self): ) args.append(self.define("HIP_RUNTIME", "rocclr")) args.append(self.define("HIP_PLATFORM", "amd")) + if self.spec.satisfies("@5.6.0:"): + args.append(self.define("HIP_LLVM_ROOT", self.spec["llvm-amdgpu"].prefix)) + if self.spec.satisfies("+cuda"): args.append(self.define("HIP_PLATFORM", "nvidia")) + args.append(self.define("HIPNV_DIR", self.stage.source_path + "/hipother/hipnv")) args.append(self.define("HIP_COMMON_DIR", self.stage.source_path)) args.append(self.define("HIP_CATCH_TEST", "OFF")) @@ -538,10 +547,12 @@ def cmake_args(self): if "@5.6.0:" in self.spec: args.append(self.define("ROCCLR_PATH", self.stage.source_path + "/clr/rocclr")) args.append(self.define("AMD_OPENCL_PATH", self.stage.source_path + "/clr/opencl")) - args.append(self.define("HIPCC_BIN_DIR", self.stage.source_path + "/hipcc/bin")), args.append(self.define("CLR_BUILD_HIP", True)), args.append(self.define("CLR_BUILD_OCL", False)), - args.append(self.define("HIP_LLVM_ROOT", self.spec["llvm-amdgpu"].prefix)) + if "@5.6:5.7" in self.spec: + args.append(self.define("HIPCC_BIN_DIR", self.stage.source_path + "/hipcc/bin")), + if "@6.0:" in self.spec: + args.append(self.define("HIPCC_BIN_DIR", self.spec["hipcc"].prefix.bin)), return args test_src_dir_old = "samples" @@ -556,18 +567,14 @@ def install_samples(self): def cache_test_sources(self): """Copy the tests source files after the package is installed to an install test subdirectory for use during `spack test run`.""" - if self.spec.satisfies("@:5.1.0"): - return - elif self.spec.satisfies("@5.1:5.5"): + if self.spec.satisfies("@5.1:5.5"): self.cache_extra_test_sources([self.test_src_dir_old]) elif self.spec.satisfies("@5.6:"): self.cache_extra_test_sources([self.test_src_dir]) def test_samples(self): # configure, build and run all hip samples - if self.spec.satisfies("@:5.1.0"): - raise SkipTest("Test is only available for specs after version 5.1.0") - elif self.spec.satisfies("@5.1:5.5"): + if self.spec.satisfies("@5.1:5.5"): test_dir = join_path(self.test_suite.current_test_cache_dir, self.test_src_dir_old) elif self.spec.satisfies("@5.6:"): test_dir = join_path(self.test_suite.current_test_cache_dir, self.test_src_dir) diff --git a/var/spack/repos/builtin/packages/hipace/package.py b/var/spack/repos/builtin/packages/hipace/package.py index 70ca72c6215a9c..8b805fd47485db 100644 --- a/var/spack/repos/builtin/packages/hipace/package.py +++ b/var/spack/repos/builtin/packages/hipace/package.py @@ -24,6 +24,8 @@ class Hipace(CMakePackage): version("23.05", sha256="33a15cfeada3ca16c2a3af1538caa7ff731df13b48b884045a0fe7974382fcd1") version("21.09", sha256="5d27824fe6aac47ce26ca69759140ab4d7844f9042e436c343c03ea4852825f1") + depends_on("cxx", type="build") # generated + variant( "compute", default="noacc", diff --git a/var/spack/repos/builtin/packages/hipblas/package.py b/var/spack/repos/builtin/packages/hipblas/package.py index 7a58fc9d5748da..6563a804a69e24 100644 --- a/var/spack/repos/builtin/packages/hipblas/package.py +++ b/var/spack/repos/builtin/packages/hipblas/package.py @@ -24,6 +24,9 @@ class Hipblas(CMakePackage, CudaPackage, ROCmPackage): version("develop", branch="develop") version("master", branch="master") + version("6.1.2", sha256="73699892855775a67f48c38beae78169a516078c17f1ed5d67c80abe5d308502") + version("6.1.1", sha256="087ea82dff13c8162bf93343b174b18f1d58681711bce4fb7c8dc7212020c099") + version("6.1.0", sha256="5f8193c4ef0508967e608a8adf86d63066a984c5803a4d05dd617021d6298091") version("6.0.2", sha256="10c1b6c1deb0f225c0fb6b2bb88398a32cd0d32d3ffce9b5c8df9db2cf88d25c") version("6.0.0", sha256="8fbd0c244fe82eded866e06d2399b1d91ab5d43d2ebcb73382c7ce1ae48d9cb3") version("5.7.1", sha256="794e9298f48ffbe3bd1c1ab87a5c2c2b953713500155fdec9ef8cbb11f81fc8a") @@ -32,16 +35,15 @@ class Hipblas(CMakePackage, CudaPackage, ROCmPackage): version("5.6.0", sha256="9453a31324e10ba528f8f4755d2c270d0ed9baa33e980d8f8383204d8e28a563") version("5.5.1", sha256="5920c9a9c83cf7e2b42d1f99f5d5091cac7f6c0a040a737e869e57b92d7045a9") version("5.5.0", sha256="b080c25cb61531228d26badcdca856c46c640035c058bfc1c9f63de65f418cd5") - version("5.4.3", sha256="5acac147aafc15c249c2f24c19459135ed68b506403aa92e602b67cfc10c38b7") - version("5.4.0", sha256="341d61adff8d08cbf70aa07bd11a088bcd0687fc6156870a1aee9eff74f3eb4f") - version("5.3.3", sha256="1ce093fc6bc021ad4fe0b0b93f9501038a7a5a16b0fd4fc485d65cbd220a195e") - version("5.3.0", sha256="873d55749479873994679840906c4257316dfb09a6200411204ad4a8c2480565") with default_args(deprecated=True): - version("5.2.3", sha256="4d66db9b000b6207b5270d90556b724bfdb08ebbfcc675f014287e0be7ee6344") - version("5.2.1", sha256="ccae36b118b7a1eb4b2f7d65fb163f54ab9c5cf774dbe2ec60971d4f78ae8308") - version("5.2.0", sha256="5e9091dc4ef83896f5c3bc5ade1cb5db8e1a6afc451dbba4da19d8a7ec2b6f29") - version("5.1.3", sha256="f0fdaa851971b41b48ec2e7d640746fbd6f9f433da2020c5fd95c91a7473d9e1") - version("5.1.0", sha256="22faba3828e50a4c4e22f569a7d6441c797a11db1d472619c01d3515a3275e92") + version("5.4.3", sha256="5acac147aafc15c249c2f24c19459135ed68b506403aa92e602b67cfc10c38b7") + version("5.4.0", sha256="341d61adff8d08cbf70aa07bd11a088bcd0687fc6156870a1aee9eff74f3eb4f") + version("5.3.3", sha256="1ce093fc6bc021ad4fe0b0b93f9501038a7a5a16b0fd4fc485d65cbd220a195e") + version("5.3.0", sha256="873d55749479873994679840906c4257316dfb09a6200411204ad4a8c2480565") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated # default to an 'auto' variant until amdgpu_targets can be given a better default than 'none' amdgpu_targets = ROCmPackage.amdgpu_targets @@ -57,6 +59,7 @@ class Hipblas(CMakePackage, CudaPackage, ROCmPackage): sticky=True, ) variant("rocm", default=True, description="Enable ROCm support") + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") conflicts("+cuda +rocm", msg="CUDA and ROCm support are mutually exclusive") conflicts("~cuda ~rocm", msg="CUDA or ROCm support is required") @@ -65,23 +68,20 @@ class Hipblas(CMakePackage, CudaPackage, ROCmPackage): depends_on("googletest@1.10.0:", type="test") depends_on("netlib-lapack@3.7.1:", type="test") depends_on("boost@1.64.0:1.76.0 +program_options cxxstd=14", type="test") + depends_on("py-pyaml", type="test", when="@6.1:") patch("remove-hipblas-clients-file-installation.patch", when="@5.5:5.7.1") patch("remove-hipblas-clients-file-installation-6.0.patch", when="@6.0:") depends_on("rocm-cmake@5.2.0:", type="build", when="@5.2.0:5.7") depends_on("rocm-cmake@4.5.0:", type="build") - for ver in ["6.0.0", "6.0.2"]: + for ver in ["6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: depends_on(f"rocm-cmake@{ver}", when=f"+rocm @{ver}") + depends_on(f"rocm-openmp-extras@{ver}", type="test", when=f"+rocm @{ver}") depends_on("hip +cuda", when="+cuda") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -94,6 +94,9 @@ class Hipblas(CMakePackage, CudaPackage, ROCmPackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", "develop", ]: @@ -114,6 +117,10 @@ def determine_version(cls, lib): ver = None return ver + def setup_build_environment(self, env): + if self.spec.satisfies("+asan"): + self.asan_on(env) + def cmake_args(self): args = [ self.define("BUILD_CLIENTS_SAMPLES", "OFF"), @@ -123,22 +130,18 @@ def cmake_args(self): # FindHIP.cmake is still used for +cuda if self.spec.satisfies("+cuda"): - if self.spec["hip"].satisfies("@:5.1"): - args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.cmake)) - else: - args.append( - self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.lib.cmake.hip) - ) - + args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.lib.cmake.hip)) if self.spec.satisfies("@5.2.0:"): args.append(self.define("BUILD_FILE_REORG_BACKWARD_COMPATIBILITY", True)) if self.spec.satisfies("@5.3.0:"): args.append("-DCMAKE_INSTALL_LIBDIR=lib") + if self.spec.satisfies("@6.1:") and self.run_tests: + args.append(self.define("LINK_BLIS", "OFF")) return args - @run_after("build") - @on_package_attributes(run_tests=True) - def check_build(self): - exe = Executable(join_path(self.build_directory, "clients", "staging", "hipblas-test")) + def check(self): + exe = Executable( + join_path(self.builder.build_directory, "clients", "staging", "hipblas-test") + ) exe("--gtest_filter=-*known_bug*") diff --git a/var/spack/repos/builtin/packages/hipblaslt/0001-Set-LLVM_Path-Add-Hiblas-Include-to-CmakeLists-6.1.Patch b/var/spack/repos/builtin/packages/hipblaslt/0001-Set-LLVM_Path-Add-Hiblas-Include-to-CmakeLists-6.1.Patch new file mode 100644 index 00000000000000..33b2e797872c83 --- /dev/null +++ b/var/spack/repos/builtin/packages/hipblaslt/0001-Set-LLVM_Path-Add-Hiblas-Include-to-CmakeLists-6.1.Patch @@ -0,0 +1,88 @@ +From 085d965e11cda1830cf325e0d12db3faf61a94d0 Mon Sep 17 00:00:00 2001 +From: sreenivasa murthy kolam +Date: Thu, 23 May 2024 05:49:34 +0000 +Subject: [PATCH] Add hipblas include dir in CMakeLists.txt and Modify the LLVM + Path in the Tensile code for Spack + +--- + clients/gtest/CMakeLists.txt | 1 + + library/CMakeLists.txt | 2 ++ + tensilelite/Tensile/Common.py | 7 ++++--- + tensilelite/Tensile/Ops/gen_assembly.sh | 2 +- + 4 files changed, 8 insertions(+), 4 deletions(-) + +diff --git a/clients/gtest/CMakeLists.txt b/clients/gtest/CMakeLists.txt +index 825bdca..f817e12 100644 +--- a/clients/gtest/CMakeLists.txt ++++ b/clients/gtest/CMakeLists.txt +@@ -53,6 +53,7 @@ target_include_directories( hipblaslt-test + $ + $ # may be blank if not used + $ ++ $ + ) + message("BLIS_INCLUDE_DIR=" ${BLIS_INCLUDE_DIR}) + target_link_libraries( hipblaslt-test PRIVATE ${BLAS_LIBRARY} ${GTEST_BOTH_LIBRARIES} roc::hipblaslt ) +diff --git a/library/CMakeLists.txt b/library/CMakeLists.txt +index 3252da0..1b8d628 100644 +--- a/library/CMakeLists.txt ++++ b/library/CMakeLists.txt +@@ -72,6 +72,8 @@ include(src/CMakeLists.txt) + # Create hipBLASLt library + add_library(hipblaslt ${hipblaslt_source} ${hipblaslt_headers_public}) + add_library(roc::hipblaslt ALIAS hipblaslt) ++target_include_directories( hipblaslt PRIVATE ${HIPBLAS_INCLUDE_DIRS} ) ++target_include_directories( hipblaslt PRIVATE ${MSGPACK_DIR}/include ) + + # Target compile definitions + if(NOT BUILD_CUDA) +diff --git a/tensilelite/Tensile/Common.py b/tensilelite/Tensile/Common.py +index 8ee6373..52d6a97 100644 +--- a/tensilelite/Tensile/Common.py ++++ b/tensilelite/Tensile/Common.py +@@ -273,6 +273,7 @@ globalParameters["LazyLibraryLoading"] = False # Load library and code object fi + globalParameters["UseUserArgs"] = False + + globalParameters["RotatingBufferSize"] = 0 # Size in MB ++globalParameters["LLVMPath"] = os.environ.get("LLVM_PATH") + + # Save a copy - since pytest doesn't re-run this initialization code and YAML files can override global settings - odd things can happen + defaultGlobalParameters = deepcopy(globalParameters) +@@ -1488,10 +1489,10 @@ def assignGlobalParameters( config ): + if os.name == "nt": + globalParameters["AssemblerPath"] = locateExe(globalParameters["ROCmBinPath"], "clang++.exe") + else: +- globalParameters["AssemblerPath"] = locateExe(os.path.join(globalParameters["ROCmPath"], "llvm/bin"), "clang++") ++ globalParameters["AssemblerPath"] = locateExe(os.path.join(globalParameters["LLVMPath"], "bin"), "clang++") + + globalParameters["ROCmSMIPath"] = locateExe(globalParameters["ROCmBinPath"], "rocm-smi") +- globalParameters["ROCmLdPath"] = locateExe(os.path.join(globalParameters["ROCmPath"], "llvm/bin"), "ld.lld") ++ globalParameters["ROCmLdPath"] = locateExe(os.path.join(globalParameters["LLVMPath"], "bin"), "ld.lld") + + globalParameters["ExtractKernelPath"] = locateExe(os.path.join(globalParameters["ROCmPath"], "hip/bin"), "extractkernel") + +@@ -1501,7 +1502,7 @@ def assignGlobalParameters( config ): + if os.name == "nt": + globalParameters["ClangOffloadBundlerPath"] = locateExe(globalParameters["ROCmBinPath"], "clang-offload-bundler.exe") + else: +- globalParameters["ClangOffloadBundlerPath"] = locateExe(os.path.join(globalParameters["ROCmPath"], "llvm/bin"), "clang-offload-bundler") ++ globalParameters["ClangOffloadBundlerPath"] = locateExe(os.path.join(globalParameters["LLVMPath"], "bin"), "clang-offload-bundler") + + if "ROCmAgentEnumeratorPath" in config: + globalParameters["ROCmAgentEnumeratorPath"] = config["ROCmAgentEnumeratorPath"] +diff --git a/tensilelite/Tensile/Ops/gen_assembly.sh b/tensilelite/Tensile/Ops/gen_assembly.sh +index 230c446..9f7dc6d 100644 +--- a/tensilelite/Tensile/Ops/gen_assembly.sh ++++ b/tensilelite/Tensile/Ops/gen_assembly.sh +@@ -32,7 +32,7 @@ if ! [ -z ${ROCM_PATH+x} ]; then + rocm_path=${ROCM_PATH} + fi + +-toolchain=${rocm_path}/llvm/bin/clang++ ++toolchain=${LLVM_PATH}/bin/clang++ + + . ${venv}/bin/activate + +-- +2.39.3 + diff --git a/var/spack/repos/builtin/packages/hipblaslt/001_Set_LLVM_Paths_And_Add_Includes.patch b/var/spack/repos/builtin/packages/hipblaslt/001_Set_LLVM_Paths_And_Add_Includes.patch new file mode 100644 index 00000000000000..27eb39effd6282 --- /dev/null +++ b/var/spack/repos/builtin/packages/hipblaslt/001_Set_LLVM_Paths_And_Add_Includes.patch @@ -0,0 +1,70 @@ +diff --git a/clients/gtest/CMakeLists.txt b/clients/gtest/CMakeLists.txt +index 825bdca..f817e12 100644 +--- a/clients/gtest/CMakeLists.txt ++++ b/clients/gtest/CMakeLists.txt +@@ -53,6 +53,7 @@ target_include_directories( hipblaslt-test + $ + $ # may be blank if not used + $ ++ $ + ) + message("BLIS_INCLUDE_DIR=" ${BLIS_INCLUDE_DIR}) + target_link_libraries( hipblaslt-test PRIVATE ${BLAS_LIBRARY} ${GTEST_BOTH_LIBRARIES} roc::hipblaslt ) +diff --git a/library/CMakeLists.txt b/library/CMakeLists.txt +index 3252da0..1b8d628 100644 +--- a/library/CMakeLists.txt ++++ b/library/CMakeLists.txt +@@ -72,6 +72,8 @@ include(src/CMakeLists.txt) + # Create hipBLASLt library + add_library(hipblaslt ${hipblaslt_source} ${hipblaslt_headers_public}) + add_library(roc::hipblaslt ALIAS hipblaslt) ++target_include_directories( hipblaslt PRIVATE ${HIPBLAS_INCLUDE_DIRS} ) ++target_include_directories( hipblaslt PRIVATE ${MSGPACK_DIR}/include ) + + # Target compile definitions + if(NOT BUILD_CUDA) +diff --git a/tensilelite/Tensile/Common.py b/tensilelite/Tensile/Common.py +index 0f862b8..0baeb55 100644 +--- a/tensilelite/Tensile/Common.py ++++ b/tensilelite/Tensile/Common.py +@@ -270,6 +270,8 @@ globalParameters["LazyLibraryLoading"] = False # Load library and code object fi + + globalParameters["UseUserArgs"] = False + ++globalParameters["LLVMPath"] = os.environ.get("LLVM_PATH") ++ + # Save a copy - since pytest doesn't re-run this initialization code and YAML files can override global settings - odd things can happen + defaultGlobalParameters = deepcopy(globalParameters) + +@@ -1471,7 +1473,7 @@ def assignGlobalParameters( config ): + if os.name == "nt": + globalParameters["AssemblerPath"] = locateExe(globalParameters["ROCmBinPath"], "clang++.exe") + else: +- globalParameters["AssemblerPath"] = locateExe(os.path.join(globalParameters["ROCmPath"], "llvm/bin"), "clang++") ++ globalParameters["AssemblerPath"] = locateExe(os.path.join(globalParameters["LLVMPath"], "bin"), "clang++") + + globalParameters["ROCmSMIPath"] = locateExe(globalParameters["ROCmBinPath"], "rocm-smi") + +@@ -1483,7 +1485,7 @@ def assignGlobalParameters( config ): + if os.name == "nt": + globalParameters["ClangOffloadBundlerPath"] = locateExe(globalParameters["ROCmBinPath"], "clang-offload-bundler.exe") + else: +- globalParameters["ClangOffloadBundlerPath"] = locateExe(os.path.join(globalParameters["ROCmPath"], "llvm/bin"), "clang-offload-bundler") ++ globalParameters["ClangOffloadBundlerPath"] = locateExe(os.path.join(globalParameters["LLVMPath"], "bin"), "clang-offload-bundler") + + if "ROCmAgentEnumeratorPath" in config: + globalParameters["ROCmAgentEnumeratorPath"] = config["ROCmAgentEnumeratorPath"] +diff --git a/tensilelite/Tensile/Ops/gen_assembly.sh b/tensilelite/Tensile/Ops/gen_assembly.sh +index 7b16069..1392cab 100644 +--- a/tensilelite/Tensile/Ops/gen_assembly.sh ++++ b/tensilelite/Tensile/Ops/gen_assembly.sh +@@ -32,7 +32,9 @@ if ! [ -z ${ROCM_PATH+x} ]; then + rocm_path=${ROCM_PATH} + fi + +-toolchain=${rocm_path}/llvm/bin/clang++ ++$LLVM_PATH=$ENV{'LLVM_PATH'}; ++ ++toolchain=${LLVM_PATH}/bin/clang++ + + . ${venv}/bin/activate diff --git a/var/spack/repos/builtin/packages/hipblaslt/package.py b/var/spack/repos/builtin/packages/hipblaslt/package.py new file mode 100644 index 00000000000000..d7a9a5c141b289 --- /dev/null +++ b/var/spack/repos/builtin/packages/hipblaslt/package.py @@ -0,0 +1,72 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Hipblaslt(CMakePackage): + """hipBLASLt is a library that provides general matrix-matrix operations with a flexible API + and extends functionalities beyond a traditional BLAS library""" + + homepage = "https://github.com/ROCm/hipBLASLt" + url = "https://github.com/ROCm/hipBLASLt/archive/refs/tags/rocm-6.1.2.tar.gz" + git = "https://github.com/ROCm/hipBLASLt.git" + + maintainers("srekolam", "afzpatel", "renjithravindrankannath") + + license("MIT") + version("6.1.2", sha256="fcfe950f7b87c421565abe090b2de6f463afc1549841002f105ecca7bbbf59e5") + version("6.1.1", sha256="1e21730ade59b5e32432fa0981383f689a380b1ffc92fe950822722da9521a72") + version("6.1.0", sha256="90fc2f2c9e11c87e0529e824e4b0561dbc850f8ffa21be6932ae63cbaa27cdf0") + version("6.0.2", sha256="e281a1a7760fab8c3e0baafe17950cf43c422184e3226e3c14eb06e50c69d421") + version("6.0.0", sha256="6451b6fdf7f24787628190bbe8f2208c929546b68b692d8355d2f18bea7ca7db") + + depends_on("cxx", type="build") # generated + + amdgpu_targets = ROCmPackage.amdgpu_targets + + variant( + "amdgpu_target", + description="AMD GPU architecture", + values=auto_or_any_combination_of(*amdgpu_targets), + sticky=True, + ) + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") + + for ver in ["6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: + depends_on(f"hip@{ver}", when=f"@{ver}") + depends_on(f"hipblas@{ver}", when=f"@{ver}") + depends_on(f"rocm-openmp-extras@{ver}", type="test", when=f"@{ver}") + + depends_on("msgpack-c") + depends_on("py-joblib") + depends_on("googletest@1.10.0:", type="test") + depends_on("netlib-lapack@3.7.1:", type="test") + depends_on("py-pyyaml", type="test") + + # Sets the proper for clang++ and clang-offload-blunder. + # Also adds hipblas and msgpack include directories + patch("001_Set_LLVM_Paths_And_Add_Includes.patch", when="@6.0") + # Below patch sets the proper path for clang++ and clang-offload-blunder. + # Also adds hipblas and msgpack include directories for 6.1.0 release. + patch("0001-Set-LLVM_Path-Add-Hiblas-Include-to-CmakeLists-6.1.Patch", when="@6.1") + + def setup_build_environment(self, env): + env.set("CXX", self.spec["hip"].hipcc) + + def cmake_args(self): + args = [ + self.define("Tensile_CODE_OBJECT_VERSION", "default"), + self.define("MSGPACK_DIR", self.spec["msgpack-c"].prefix), + self.define_from_variant("ADDRESS_SANITIZER", "asan"), + self.define("BUILD_CLIENTS_TESTS", self.run_tests), + ] + if "auto" not in self.spec.variants["amdgpu_target"]: + args.append(self.define_from_variant("AMDGPU_TARGETS", "amdgpu_target")) + if self.run_tests: + args.append( + self.define("ROCM_OPENMP_EXTRAS_DIR", self.spec["rocm-openmp-extras"].prefix) + ) + return args diff --git a/var/spack/repos/builtin/packages/hipcc/0014-remove-compiler-rt-linkage-for-host.6.0.patch b/var/spack/repos/builtin/packages/hipcc/0014-remove-compiler-rt-linkage-for-host.6.0.patch new file mode 100644 index 00000000000000..74b90fafe03745 --- /dev/null +++ b/var/spack/repos/builtin/packages/hipcc/0014-remove-compiler-rt-linkage-for-host.6.0.patch @@ -0,0 +1,30 @@ +diff --git a/bin/hipcc.pl b/bin/hipcc.pl +index 513a427..780dc5c 100755 +--- a/bin/hipcc.pl ++++ b/bin/hipcc.pl +@@ -160,11 +160,13 @@ if ($HIP_PLATFORM eq "amd") { + if($isWindows) { + $execExtension = ".exe"; + } +- $HIPCC=get_normalized_path("$HIP_CLANG_PATH/clang++" . $execExtension); ++ # llvm_path is set inside the hip recipe ++ $HIP_CLANG_PATH= $ENV{'HIP_CLANG_PATH'}; ++ $HIPCC="${HIP_CLANG_PATH}/clang++" . $execExtension; + + # If $HIPCC clang++ is not compiled, use clang instead + if ( ! -e $HIPCC ) { +- $HIPCC=get_normalized_path("$HIP_CLANG_PATH/clang" . $execExtension); ++ $HIPCC="${HIP_CLANG_PATH}/clang" . $execExtension; + $HIPLDFLAGS = "--driver-mode=g++"; + } + # to avoid using dk linker or MSVC linker +@@ -484,7 +486,8 @@ if($HIP_PLATFORM eq "amd"){ + $targetsStr = $ENV{HCC_AMDGPU_TARGET}; + } elsif (not $isWindows) { + # Else try using rocm_agent_enumerator +- $ROCM_AGENT_ENUM = "${ROCM_PATH}/bin/rocm_agent_enumerator"; ++ $ROCMINFO_PATH = $ENV{'ROCMINFO_PATH'} // $ROCMINFO_PATH; ++ $ROCM_AGENT_ENUM = "${ROCMINFO_PATH}/bin/rocm_agent_enumerator"; + $targetsStr = `${ROCM_AGENT_ENUM} -t GPU`; + $targetsStr =~ s/\n/,/g; + } diff --git a/var/spack/repos/builtin/packages/hipcc/0014-remove-compiler-rt-linkage-for-host.6.1.patch b/var/spack/repos/builtin/packages/hipcc/0014-remove-compiler-rt-linkage-for-host.6.1.patch new file mode 100644 index 00000000000000..5bd44f33b88958 --- /dev/null +++ b/var/spack/repos/builtin/packages/hipcc/0014-remove-compiler-rt-linkage-for-host.6.1.patch @@ -0,0 +1,30 @@ +diff --git a/amd/hipcc/bin/hipcc.pl b/amd/hipcc/bin/hipcc.pl +index 513a427..780dc5c 100755 +--- a/amd/hipcc/bin/hipcc.pl ++++ b/amd/hipcc/bin/hipcc.pl +@@ -160,11 +160,13 @@ if ($HIP_PLATFORM eq "amd") { + if($isWindows) { + $execExtension = ".exe"; + } +- $HIPCC=get_normalized_path("$HIP_CLANG_PATH/clang++" . $execExtension); ++ # hip_clang_path is set inside the hip recipe ++ $HIP_CLANG_PATH= $ENV{'HIP_CLANG_PATH'}; ++ $HIPCC="${HIP_CLANG_PATH}/clang++" . $execExtension; + + # If $HIPCC clang++ is not compiled, use clang instead + if ( ! -e $HIPCC ) { +- $HIPCC=get_normalized_path("$HIP_CLANG_PATH/clang" . $execExtension); ++ $HIPCC="${HIP_CLANG_PATH}/clang" . $execExtension; + $HIPLDFLAGS = "--driver-mode=g++"; + } + # to avoid using dk linker or MSVC linker +@@ -484,7 +486,8 @@ if($HIP_PLATFORM eq "amd"){ + $targetsStr = $ENV{HCC_AMDGPU_TARGET}; + } elsif (not $isWindows) { + # Else try using rocm_agent_enumerator +- $ROCM_AGENT_ENUM = "${ROCM_PATH}/bin/rocm_agent_enumerator"; ++ $ROCMINFO_PATH = $ENV{'ROCMINFO_PATH'} // $ROCMINFO_PATH; ++ $ROCM_AGENT_ENUM = "${ROCMINFO_PATH}/bin/rocm_agent_enumerator"; + $targetsStr = `${ROCM_AGENT_ENUM} -t GPU`; + $targetsStr =~ s/\n/,/g; + } diff --git a/var/spack/repos/builtin/packages/hipcc/package.py b/var/spack/repos/builtin/packages/hipcc/package.py new file mode 100644 index 00000000000000..d94ce19e0c57d6 --- /dev/null +++ b/var/spack/repos/builtin/packages/hipcc/package.py @@ -0,0 +1,65 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.hooks.sbang import filter_shebang +from spack.package import * + + +class Hipcc(CMakePackage): + """HIPCC: HIP compiler driver""" + + homepage = "https://github.com/ROCm/hipcc" + git = "https://github.com/ROCm/hipcc.git" + + def url_for_version(self, version): + if version <= Version("6.0.2"): + url = "https://github.com/ROCm/HIPCC/archive/rocm-{0}.tar.gz" + else: + url = "https://github.com/ROCm/llvm-project/archive/rocm-{0}.tar.gz" + return url.format(version) + + maintainers("srekolam", "renjithravindrankannath", "afzpatel") + + license("MIT") + version("6.1.2", sha256="300e9d6a137dcd91b18d5809a316fddb615e0e7f982dc7ef1bb56876dff6e097") + version("6.1.1", sha256="f1a67efb49f76a9b262e9735d3f75ad21e3bd6a05338c9b15c01e6c625c4460d") + version("6.1.0", sha256="6bd9912441de6caf6b26d1323e1c899ecd14ff2431874a2f5883d3bc5212db34") + version("6.0.2", sha256="d6209b14fccdd00d7231dec4b4f962aa23914b9dde389ba961370e8ba918bde5") + version("6.0.0", sha256="e9cfaaecaf0e6ed363946439197f340c115e8e1189f96dbd716cf20245c29255") + version("5.7.1", sha256="d47d27ef2b5de7f49cdfd8547832ac9b437a32e6fc6f0e9c1646f4b704c90aee") + version("5.7.0", sha256="9f839bf7226e5e26f3150f8ba6eca507ab9a668e68b207736301b3bb9040c973") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + depends_on("numactl") + + patch("0014-remove-compiler-rt-linkage-for-host.6.0.patch", when="@6.0") + patch("0014-remove-compiler-rt-linkage-for-host.6.1.patch", when="@6.1:") + + @property + def root_cmakelists_dir(self): + if self.spec.satisfies("@:6.0"): + return "." + else: + return join_path("amd", "hipcc") + + def patch(self): + numactl = self.spec["numactl"].prefix.lib + if self.spec.satisfies("@:6.0"): + with working_dir("bin"): + filter_shebang("hipconfig") + else: + with working_dir("amd/hipcc/bin"): + filter_shebang("hipconfig") + + if self.spec.satisfies("@:6.0"): + with working_dir("src"): + filter_file(" -lnuma", f" -L{numactl} -lnuma", "hipBin_amd.h") + else: + with working_dir("amd/hipcc/src"): + filter_file(" -lnuma", f" -L{numactl} -lnuma", "hipBin_amd.h") diff --git a/var/spack/repos/builtin/packages/hipcub/find-hip-cuda-rocm-5.1.patch b/var/spack/repos/builtin/packages/hipcub/find-hip-cuda-rocm-5.1.patch deleted file mode 100644 index eacfcc645d9edf..00000000000000 --- a/var/spack/repos/builtin/packages/hipcub/find-hip-cuda-rocm-5.1.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/cmake/VerifyCompiler.cmake b/cmake/VerifyCompiler.cmake -index ca4d646..0256683 100644 ---- a/cmake/VerifyCompiler.cmake -+++ b/cmake/VerifyCompiler.cmake -@@ -22,8 +22,6 @@ - - list(APPEND CMAKE_PREFIX_PATH /opt/rocm /opt/rocm/hip) - if(CMAKE_CXX_COMPILER MATCHES ".*/nvcc$" OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") -- list(APPEND CMAKE_MODULE_PATH /opt/rocm/hip/cmake) -- find_package(hip QUIET CONFIG PATHS /opt/rocm) - if(NOT hip_FOUND) - find_package(HIP REQUIRED) - endif() diff --git a/var/spack/repos/builtin/packages/hipcub/package.py b/var/spack/repos/builtin/packages/hipcub/package.py index 870d9f299cfbd6..686645f8425d8e 100644 --- a/var/spack/repos/builtin/packages/hipcub/package.py +++ b/var/spack/repos/builtin/packages/hipcub/package.py @@ -11,12 +11,15 @@ class Hipcub(CMakePackage, CudaPackage, ROCmPackage): homepage = "https://github.com/ROCm/hipCUB" git = "https://github.com/ROCm/hipCUB.git" - url = "https://github.com/ROCm/hipCUB/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/hipCUB/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] license("BSD-3-Clause") maintainers("srekolam", "renjithravindrankannath") + version("6.1.2", sha256="830a0f3231e07fcc6cd6261c4e1af2d7d0ac4862c606ecdc80c2635557ca3d9f") + version("6.1.1", sha256="967716d67e4270c599a60b770d543ea9148948edb907a0fa4d8be3a1785c2058") + version("6.1.0", sha256="39ac03053ecf35f1faf212e5b197b03c0104b74b0833f7cce5cf625c273ba71c") version("6.0.2", sha256="3f912a23dc34510cf18d9097f6eda37e01d01724975c8149c92a64c92415968c") version("6.0.0", sha256="8d9f6e1e3f8433a2ceae1b0efd6727c21383980077e264725d00d5fee165bd30") version("5.7.1", sha256="9b23a58408bc4c549d3c754196cb3e2c1a50e177ab0a286101cbea2f7f173945") @@ -25,16 +28,13 @@ class Hipcub(CMakePackage, CudaPackage, ROCmPackage): version("5.6.0", sha256="5e74ddbf833f39836bf9ec6c6750348c7386a85ca67aaf9bb54d16c9e1959031") version("5.5.1", sha256="ad83f3f1ed85ead9e3012906957c125a896168be913f6fb6af298228fc571480") version("5.5.0", sha256="3eec838119326a67eb4cc006c706e328f3a51a01e98bbfb518df8fe4a4707e13") - version("5.4.3", sha256="cf528d9acb4f9b9c3aad439ae76bfc3d02be6e7a74d96099544e5d54e1a23675") - version("5.4.0", sha256="78db2c2ea466a4c5d84beedc000ae934f6d0ff1793eae90bb8d02b2dbff8932c") - version("5.3.3", sha256="b4fc3c05892729873dc098f111c31f83af7d33da572bdb7d87de100d4c238e6d") - version("5.3.0", sha256="4016cfc240b3cc1a97b549ecc4a5b76369610d46247661834630846391e5fad2") with default_args(deprecated=True): - version("5.2.3", sha256="cab929f10c649f8fd76df989a16d0cd9301bc6aaad91cd2f84498c831378d559") - version("5.2.1", sha256="07b34d8cdf885838dde264c2a70044505e7b9632cb6efbdb52e2569f95112970") - version("5.2.0", sha256="ac4dc2310f0eb657e1337c93d8cc4a5d8396f9544a7336eeceb455678a1f9139") - version("5.1.3", sha256="dc75640689b6a5e15dd3acea643266bdf114ea63efc60be8272f484cf8f04494") - version("5.1.0", sha256="b30d51fc5fca2584f0c9a6fa8dafc9fbdda96a3acff30288e49b397f8842f705") + version("5.4.3", sha256="cf528d9acb4f9b9c3aad439ae76bfc3d02be6e7a74d96099544e5d54e1a23675") + version("5.4.0", sha256="78db2c2ea466a4c5d84beedc000ae934f6d0ff1793eae90bb8d02b2dbff8932c") + version("5.3.3", sha256="b4fc3c05892729873dc098f111c31f83af7d33da572bdb7d87de100d4c238e6d") + version("5.3.0", sha256="4016cfc240b3cc1a97b549ecc4a5b76369610d46247661834630846391e5fad2") + + depends_on("cxx", type="build") # generated # default to an 'auto' variant until amdgpu_targets can be given a better default than 'none' amdgpu_targets = ROCmPackage.amdgpu_targets @@ -50,21 +50,15 @@ class Hipcub(CMakePackage, CudaPackage, ROCmPackage): sticky=True, ) variant("rocm", default=True, description="Enable ROCm support") + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") conflicts("+cuda +rocm", msg="CUDA and ROCm support are mutually exclusive") conflicts("~cuda ~rocm", msg="CUDA or ROCm support is required") depends_on("cmake@3.10.2:", type="build") - depends_on("hip +cuda", when="+cuda") - depends_on("googletest@1.10.0:", type="test") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -77,17 +71,22 @@ class Hipcub(CMakePackage, CudaPackage, ROCmPackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"rocprim@{ver}", when=f"+rocm @{ver}") depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") + depends_on(f"hip +cuda@{ver}", when=f"+cuda @{ver}") # fix hardcoded search in /opt/rocm and broken config mode search - patch("find-hip-cuda-rocm-5.1.patch", when="@5.1:5.2 +cuda") patch("find-hip-cuda-rocm-5.3.patch", when="@5.3: +cuda") def setup_build_environment(self, env): if self.spec.satisfies("+rocm"): env.set("CXX", self.spec["hip"].hipcc) + if self.spec.satisfies("+asan"): + self.asan_on(env) def cmake_args(self): args = [self.define("BUILD_TEST", self.run_tests)] @@ -97,13 +96,7 @@ def cmake_args(self): # FindHIP.cmake is still used for +cuda if self.spec.satisfies("+cuda"): - if self.spec["hip"].satisfies("@:5.1"): - args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.cmake)) - else: - args.append( - self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.lib.cmake.hip) - ) - + args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.lib.cmake.hip)) if self.spec.satisfies("@5.2.0:"): args.append(self.define("BUILD_FILE_REORG_BACKWARD_COMPATIBILITY", True)) diff --git a/var/spack/repos/builtin/packages/hipfft/package.py b/var/spack/repos/builtin/packages/hipfft/package.py index 695c2e21c769aa..bb9024dd9e78db 100644 --- a/var/spack/repos/builtin/packages/hipfft/package.py +++ b/var/spack/repos/builtin/packages/hipfft/package.py @@ -16,7 +16,7 @@ class Hipfft(CMakePackage, CudaPackage, ROCmPackage): homepage = "https://github.com/ROCm/hipFFT" git = "https://github.com/ROCm/hipFFT.git" - url = "https://github.com/ROCm/hipfft/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/hipfft/archive/rocm-6.1.0.tar.gz" tags = ["rocm"] maintainers("renjithravindrankannath", "srekolam") @@ -24,6 +24,9 @@ class Hipfft(CMakePackage, CudaPackage, ROCmPackage): license("MIT") version("master", branch="master") + version("6.1.2", sha256="6753e45d9c671d58e68bed2b0c1bfcd40fad9d690dba3fe6011e67e51dbe3cc6") + version("6.1.1", sha256="df84e488098d457a7411f6b459537fa5c5ee160027efc3a9a076980bbe57c4d3") + version("6.1.0", sha256="1a9cf598a932192f7f12b8987d96477f09186f9a95c5a28742f9caeb81640c95") version("6.0.2", sha256="c0a4bac5fa9a757a19a4995fa9571328b6ee0a71e93c66a880069794d65d284a") version("6.0.0", sha256="44f328b7862c066459089dfe62833cb7d626c6ceb71c57d8c7d6bba45dad491e") version("5.7.1", sha256="33452576649df479f084076c47d0b30f6f1da34864094bce767dd9bf609f04aa") @@ -32,16 +35,13 @@ class Hipfft(CMakePackage, CudaPackage, ROCmPackage): version("5.6.0", sha256="c7f425b693caf9371b42226d86392335d993a117d23219b6ba1fd13523cb8261") version("5.5.1", sha256="3addd15a459752ad657e84c2a7b6b6289600d1d0a5f90d6e0946ba11e8148fc0") version("5.5.0", sha256="47ec6f7da7346c312b80daaa8f763e86c7bdc33ac8617cfa3344068e5b20dd9e") - version("5.4.3", sha256="ae37f40b6019a11f10646ef193716836f366d269eab3c5cc2ed09af85355b945") - version("5.4.0", sha256="d0a8e790182928b3d19774b8db1eece9b881a422f6a7055c051b12739fded624") - version("5.3.3", sha256="fd1662cd5b1e1bce9db53b320c0fe614179cd196251efc2ef3365d38922b5cdc") - version("5.3.0", sha256="ebbe2009b86b688809b6b4d5c3929fc589db455218d54a37790f21339147c5df") with default_args(deprecated=True): - version("5.2.3", sha256="10be731fe91ede5e9f254f6eb3bc00b4dbeab449477f3cac03de358a7d0a6fa1") - version("5.2.1", sha256="6c8fbace2864ca992b2fca9dc8d0bb4488aef62045acdfcf249d53dd005ebd35") - version("5.2.0", sha256="ec37edcd61837281c403802ccc1cb01ec3fa3ba135b5ab16617961b66d4cc3e2") - version("5.1.3", sha256="c26fa64499293b25d0686bed04feb61378c878a4bb4a6d559e6cb7be1f6bf2ec") - version("5.1.0", sha256="1bac7761c055355216cd262cdc0450aabb383addcb739b56ba849b2e6e013fa5") + version("5.4.3", sha256="ae37f40b6019a11f10646ef193716836f366d269eab3c5cc2ed09af85355b945") + version("5.4.0", sha256="d0a8e790182928b3d19774b8db1eece9b881a422f6a7055c051b12739fded624") + version("5.3.3", sha256="fd1662cd5b1e1bce9db53b320c0fe614179cd196251efc2ef3365d38922b5cdc") + version("5.3.0", sha256="ebbe2009b86b688809b6b4d5c3929fc589db455218d54a37790f21339147c5df") + + depends_on("cxx", type="build") # generated # default to an 'auto' variant until amdgpu_targets can be given a better default than 'none' amdgpu_targets = ROCmPackage.amdgpu_targets @@ -59,17 +59,13 @@ class Hipfft(CMakePackage, CudaPackage, ROCmPackage): variant("rocm", default=True, description="Enable ROCm support") conflicts("+cuda +rocm", msg="CUDA and ROCm support are mutually exclusive") conflicts("~cuda ~rocm", msg="CUDA or ROCm support is required") + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") depends_on("cmake@3.5:", type="build") depends_on("hip +cuda", when="+cuda") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -82,6 +78,9 @@ class Hipfft(CMakePackage, CudaPackage, ROCmPackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") depends_on(f"rocfft@{ver}", when=f"+rocm @{ver}") @@ -91,6 +90,10 @@ class Hipfft(CMakePackage, CudaPackage, ROCmPackage): # https://github.com/ROCm/rocFFT/pull/85) patch("001-remove-submodule-and-sync-shared-files-from-rocFFT.patch", when="@6.0.0") + def setup_build_environment(self, env): + if self.spec.satisfies("+asan"): + self.asan_on(env) + def cmake_args(self): args = [self.define("BUILD_CLIENTS_SAMPLES", "OFF")] @@ -100,9 +103,7 @@ def cmake_args(self): args.append(self.define("BUILD_WITH_LIB", "CUDA")) # FindHIP.cmake is still used for both +rocm and +cuda - if self.spec["hip"].satisfies("@:5.1"): - args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.cmake)) - else: + if self.spec["hip"].satisfies("@5.2:"): args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.lib.cmake.hip)) if self.spec.satisfies("@5.2.0:"): diff --git a/var/spack/repos/builtin/packages/hipfort/package.py b/var/spack/repos/builtin/packages/hipfort/package.py index 356a317a11d7e3..a4823db0e24442 100644 --- a/var/spack/repos/builtin/packages/hipfort/package.py +++ b/var/spack/repos/builtin/packages/hipfort/package.py @@ -11,12 +11,15 @@ class Hipfort(CMakePackage): homepage = "https://github.com/ROCm/hipfort" git = "https://github.com/ROCm/hipfort.git" - url = "https://github.com/ROCm/hipfort/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/hipfort/archive/rocm-6.1.1.tar.gz" tags = ["rocm"] license("MIT") maintainers("cgmb", "srekolam", "renjithravindrankannath") + version("6.1.2", sha256="f60d07fa3e5b09246c8908b2876addf175a91e91c8b0fac85b000f88b6743c7c") + version("6.1.1", sha256="646f7077399db7a70d7102fda8307d0a11039f616399a4a06a64fd824336419f") + version("6.1.0", sha256="70d3ccc9f3536f62686e73934f5972ed011c4df7654ed1f8e6d2d42c4289f47e") version("6.0.2", sha256="b60ada7474b71c1d82c700b0159bc0756dbb2808375054903710280b1677f199") version("6.0.0", sha256="151cf11648885db799aade0d00a7882589e7195643b02beaa251f1b2a43aceed") version("5.7.1", sha256="859fac509e195f3ab97c555b5f63afea325a61aae0f281cb19a970a1b533dead") @@ -25,16 +28,14 @@ class Hipfort(CMakePackage): version("5.6.0", sha256="03176a099bc81e212ad1bf9d86f35561f8f2d21a2f126732d7620e1ea59888d5") version("5.5.1", sha256="abc59f7b81cbefbe3555cbf1bf0d80e8aa65901c70799748c40870fe6f3fea60") version("5.5.0", sha256="cae75ffeac129639cabebfe2f95f254c83d6c0a6cffd98142ea3537a132e42bb") - version("5.4.3", sha256="1954a1cba351d566872ced5549b2ced7ab6332221e2b98dba3c07180dce8f173") - version("5.4.0", sha256="a781bc6d1dbb508a4bd6cc3df931696fac6c6361d4fd35efb12c9a04a72e112c") - version("5.3.3", sha256="593be86502578b68215ffe767c26849fd27d4dbd92c8e76762275805f99e64f5") - version("5.3.0", sha256="9e2aa142de45b2d2c29449d6f82293fb62844d511fbf51fa597845ba05c700fa") with default_args(deprecated=True): - version("5.2.3", sha256="6648350ca4edc8757f0ae51d73a05a9a536808f19ad45f5b5ab84d420c72c9ec") - version("5.2.1", sha256="ed53c9914d326124482751b81c4a353c6e64e87c1111124169a33513a3c49b42") - version("5.2.0", sha256="a0af1fe62757993600a41af6bb6c4b8c6cfdfba650389645ac1f995f7623785c") - version("5.1.3", sha256="8f8849d8d0972366bafa41be35cf6a7a59480ed584d1ddff39768cb14247e9d4") - version("5.1.0", sha256="1ddd46c00bb6bcd539a921d6a94d858f4e4408a35cb6910186c7517f375ae8ab") + version("5.4.3", sha256="1954a1cba351d566872ced5549b2ced7ab6332221e2b98dba3c07180dce8f173") + version("5.4.0", sha256="a781bc6d1dbb508a4bd6cc3df931696fac6c6361d4fd35efb12c9a04a72e112c") + version("5.3.3", sha256="593be86502578b68215ffe767c26849fd27d4dbd92c8e76762275805f99e64f5") + version("5.3.0", sha256="9e2aa142de45b2d2c29449d6f82293fb62844d511fbf51fa597845ba05c700fa") + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated depends_on("cmake@3.0.2:", type="build") @@ -43,11 +44,6 @@ class Hipfort(CMakePackage): depends_on("binutils", when="%cce") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -60,6 +56,9 @@ class Hipfort(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hip@{ver}", type="build", when=f"@{ver}") @@ -79,5 +78,8 @@ def cmake_args(self): "-DHIPFORT_RANLIB=" + join_path(self.spec["binutils"].prefix.bin, "ranlib") ) args.append("-DHIPFORT_COMPILER_FLAGS='-ffree -eT'") + elif self.spec.satisfies("%gcc"): + args.append("-DHIPFORT_COMPILER={}".format(spack_fc)) + args.append("-DHIPFORT_COMPILER_FLAGS='-ffree-form -cpp -ffree-line-length-none'") return args diff --git a/var/spack/repos/builtin/packages/hipify-clang/0003-install-hipify-clang-in-bin-dir-and-llvm-clangs-head.patch b/var/spack/repos/builtin/packages/hipify-clang/0003-install-hipify-clang-in-bin-dir-and-llvm-clangs-head.patch new file mode 100644 index 00000000000000..363bff874e274f --- /dev/null +++ b/var/spack/repos/builtin/packages/hipify-clang/0003-install-hipify-clang-in-bin-dir-and-llvm-clangs-head.patch @@ -0,0 +1,22 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 02df74d..a645aa4 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -184,7 +184,7 @@ if (NOT HIPIFY_CLANG_TESTS_ONLY) + # Install all folders under clang/version/ in CMAKE_INSTALL_PREFIX path. + install( + DIRECTORY ${LLVM_DIR}/../../clang/${LIB_CLANG_RES}/ +- DESTINATION . ++ DESTINATION ${CMAKE_INSTALL_PREFIX}/include + COMPONENT clang-resource-headers + FILES_MATCHING + PATTERN "*.h" +@@ -199,7 +199,7 @@ if (NOT HIPIFY_CLANG_TESTS_ONLY) + # install all folders under clang/version/ in CMAKE_INSTALL_PREFIX path + install( + DIRECTORY ${LLVM_DIR}/../../clang/${LLVM_VERSION_MAJOR}.${LLVM_VERSION_MINOR}.${LLVM_VERSION_PATCH}/ +- DESTINATION . ++ DESTINATION ${CMAKE_INSTALL_PREFIX}/include + COMPONENT clang-resource-headers + FILES_MATCHING + PATTERN "*.h" diff --git a/var/spack/repos/builtin/packages/hipify-clang/package.py b/var/spack/repos/builtin/packages/hipify-clang/package.py index 2414dbf31ae664..df63043cca3882 100644 --- a/var/spack/repos/builtin/packages/hipify-clang/package.py +++ b/var/spack/repos/builtin/packages/hipify-clang/package.py @@ -12,7 +12,7 @@ class HipifyClang(CMakePackage): homepage = "https://github.com/ROCm/HIPIFY" git = "https://github.com/ROCm/HIPIFY.git" - url = "https://github.com/ROCm/HIPIFY/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/HIPIFY/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") @@ -20,6 +20,9 @@ class HipifyClang(CMakePackage): license("MIT") version("master", branch="master") + version("6.1.2", sha256="7cc1e3fd7690a3e1d99cd07f2bd62ee73682cceeb4a46918226fc70f8092eb68") + version("6.1.1", sha256="240b83ccbe1b6514a6af6c2261e306948ce6c2b1c4d1056e830bbaebddeabd82") + version("6.1.0", sha256="dc61b476081750130c62c7540fce49ee3a45a2b74e185d20049382574c1842d1") version("6.0.2", sha256="21e46276677ec8c00e61c0cbf5fa42185517f6af0d4845ea877fd40eb35198c4") version("6.0.0", sha256="91bed2b72a6684a04e078e50b12b36b93f64ff96523283f4e5d9a33c11e6b967") version("5.7.1", sha256="43121e62233dab010ab686d6805bc2d3163f0dc5e89cc503d50c4bcd59eeb394") @@ -28,30 +31,25 @@ class HipifyClang(CMakePackage): version("5.6.0", sha256="a2572037a7d3bd0813bd6819a5e6c0e911678db5fd3ab15a65370601df91891b") version("5.5.1", sha256="35b9c07a7afaf9cf6f3bbe9dd147fa81b1b297af3e5e26e60c55629e83feaa48") version("5.5.0", sha256="1b75c702799ac93027337f8fb61d7c27ba960e8ece60d907fc8c5ab3f15c3fe9") - version("5.4.3", sha256="79e27bd6c0a28e6a62b02dccc0b5d88a81f69fe58487e83f3b7ab47d6b64341b") - version("5.4.0", sha256="9f51eb280671ae7f7e14eb593ee3ef099899221c4bdccfbdb7a78681ad17f37f") - version("5.3.3", sha256="9d08e2896e52c10a0a189a5407567043f2510adc7bf618591c97a22a23699691") - version("5.3.0", sha256="7674900d2b9319d91fa8f469252c5acb5bedf339142417cdcb64f33ee8482e00") with default_args(deprecated=True): - version("5.2.3", sha256="1314a37ab544b68fd51858b77d2d4b30ecff82ef3f90de6e80891a95f6749849") - version("5.2.1", sha256="4d658d00b219f7ef40e832da3680852aeb4c258c0a114f1779fa4cda99ee23b1") - version("5.2.0", sha256="dcd5f44daceb984bb654a209e78debf81e1cdeaf9202444a1e110b45ad6c3f4f") - version("5.1.3", sha256="6354b08b8ab2f4c481398fb768652bae00bb78c4cec7a11d5f6c7e4cb831ddf1") - version("5.1.0", sha256="ba792294cbdcc880e0f02e38ee352dff8d4a2c183430e13d1c5ed176bd46cfc5") + version("5.4.3", sha256="79e27bd6c0a28e6a62b02dccc0b5d88a81f69fe58487e83f3b7ab47d6b64341b") + version("5.4.0", sha256="9f51eb280671ae7f7e14eb593ee3ef099899221c4bdccfbdb7a78681ad17f37f") + version("5.3.3", sha256="9d08e2896e52c10a0a189a5407567043f2510adc7bf618591c97a22a23699691") + version("5.3.0", sha256="7674900d2b9319d91fa8f469252c5acb5bedf339142417cdcb64f33ee8482e00") + + depends_on("cxx", type="build") # generated + + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") # the patch was added to install the targets in the correct directory structure # this will fix the issue https://github.com/spack/spack/issues/30711 patch("0001-install-hipify-clang-in-bin-dir-and-llvm-clangs-head.patch", when="@5.1.0:5.5") - patch("0002-install-hipify-clang-in-bin-dir-and-llvm-clangs-head.patch", when="@5.6:") + patch("0002-install-hipify-clang-in-bin-dir-and-llvm-clangs-head.patch", when="@5.6:6.0") + patch("0003-install-hipify-clang-in-bin-dir-and-llvm-clangs-head.patch", when="@6.1:") depends_on("cmake@3.5:", type="build") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -64,11 +62,26 @@ class HipifyClang(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", ]: depends_on(f"llvm-amdgpu@{ver}", when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") def setup_run_environment(self, env): @@ -80,4 +93,6 @@ def cmake_args(self): args = [] if self.spec.satisfies("@5.5"): args.append(self.define("SWDEV_375013", "ON")) + if self.spec.satisfies("@5.7.0:"): + args.append(self.define_from_variant("ADDRESS_SANITIZER", "asan")) return args diff --git a/var/spack/repos/builtin/packages/hiprand/package.py b/var/spack/repos/builtin/packages/hiprand/package.py index 79022d5a5e9d73..3a639126545b9c 100644 --- a/var/spack/repos/builtin/packages/hiprand/package.py +++ b/var/spack/repos/builtin/packages/hiprand/package.py @@ -14,7 +14,7 @@ class Hiprand(CMakePackage, CudaPackage, ROCmPackage): homepage = "https://github.com/ROCm/hipRAND" git = "https://github.com/ROCm/hipRAND.git" - url = "https://github.com/ROCm/hipRAND/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/hipRAND/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("cgmb", "srekolam", "renjithravindrankannath") @@ -24,6 +24,9 @@ class Hiprand(CMakePackage, CudaPackage, ROCmPackage): version("develop", branch="develop") version("master", branch="master") + version("6.1.2", sha256="f0f129811c144dd711e967305c7af283cefb94bfdbcd2a11296b92a9e966be2c") + version("6.1.1", sha256="dde1526fb6cde17b18bc9ee6daa719056fc468dfbda5801b9a61260daf2b4498") + version("6.1.0", sha256="f9d71af23092f8faa888d2c14713ee4d4d350454818ca9331d422c81c2587c1f") version("6.0.2", sha256="cb6ff8f58c024b60b3914271921f58f0ab3bdbc9889a53795b40c99c9de0bcd4") version("6.0.0", sha256="7e06c98f9da7c0b20b55b2106cf3a48b9ef6577a79549a455667ae97bd15b61d") version("5.7.1", sha256="81a9f5f0960dce125ce1ab1c7eb58bb07c8756346f9e46a1cc65aa61d5a114f8") @@ -32,16 +35,14 @@ class Hiprand(CMakePackage, CudaPackage, ROCmPackage): version("5.6.0", sha256="8c214e2f90337a5317a69950026bf337b1e567d43bb9ae64f2a802af2228c313") version("5.5.1", sha256="5df9d78eae0991be5ec9f60e8d3530fabc23793d9f9cf274b075d689675db04e") version("5.5.0", sha256="7c7dde7b989d5da9c0b0251233245f955b477c090462c7d34e3e0284c5fca761") - version("5.4.3", sha256="7d3d04476880ec90c088dff81f69aac8699eaef972476000e5c4726584ffa98f") - version("5.4.0", sha256="9456d4b4d5fd5c0b728f4aa4f8c224f829fe6fbf08e397848475293f71029a22") - version("5.3.3", sha256="f72626b00d61ed2925b3124b7f094ccfaf7750f02bee6bac6b79317e1c5576ef") - version("5.3.0", sha256="6fd9b3a719bf4c228657cb2a0ff283eb7d777ba31bfffe5a26589d588f89a279") with default_args(deprecated=True): - version("5.2.3", sha256="56d62a94c8ce6e2fc55fff57f3d0931b6332654333d1ad5dee854aefb1548f66") - version("5.2.1", sha256="27b00e15ca1f6608a5625a246b55f3128ce32fdca605eb727f66c6322b77bf42") - version("5.2.0", sha256="3d179aa928446471651ef2f308779b5946b3ba9bbc1643689b0abc56e6ec2f5e") - version("5.1.3", sha256="6965e30a6ec0bef4ee251d144785a4dda55dff32aed27e12dc1b4dc0c4bbc094") - version("5.1.0", sha256="a3dd384439047bdad60864f0aff7fcf855a6a601458b05770d054b53c1a7cae2") + version("5.4.3", sha256="7d3d04476880ec90c088dff81f69aac8699eaef972476000e5c4726584ffa98f") + version("5.4.0", sha256="9456d4b4d5fd5c0b728f4aa4f8c224f829fe6fbf08e397848475293f71029a22") + version("5.3.3", sha256="f72626b00d61ed2925b3124b7f094ccfaf7750f02bee6bac6b79317e1c5576ef") + version("5.3.0", sha256="6fd9b3a719bf4c228657cb2a0ff283eb7d777ba31bfffe5a26589d588f89a279") + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated # default to an 'auto' variant until amdgpu_targets can be given a better default than 'none' amdgpu_targets = ROCmPackage.amdgpu_targets @@ -65,6 +66,7 @@ class Hiprand(CMakePackage, CudaPackage, ROCmPackage): values=("Release", "Debug", "RelWithDebInfo"), description="CMake build type", ) + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") depends_on("cmake@3.10.2:", type="build") @@ -76,11 +78,6 @@ class Hiprand(CMakePackage, CudaPackage, ROCmPackage): depends_on("googletest@1.10.0:", type="test") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -93,6 +90,9 @@ class Hiprand(CMakePackage, CudaPackage, ROCmPackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", "develop", ]: @@ -106,6 +106,8 @@ class Hiprand(CMakePackage, CudaPackage, ROCmPackage): def setup_build_environment(self, env): env.set("CXX", self.spec["hip"].hipcc) + if self.spec.satisfies("+asan"): + self.asan_on(env) @classmethod def determine_version(cls, lib): diff --git a/var/spack/repos/builtin/packages/hipsolver/0001-suite-sparse-include-path-6.1.1.patch b/var/spack/repos/builtin/packages/hipsolver/0001-suite-sparse-include-path-6.1.1.patch new file mode 100644 index 00000000000000..79f1713a0475b1 --- /dev/null +++ b/var/spack/repos/builtin/packages/hipsolver/0001-suite-sparse-include-path-6.1.1.patch @@ -0,0 +1,38 @@ +From 329ee96fa7004c6fb0a8f93375e9081ef717fbab Mon Sep 17 00:00:00 2001 +From: Renjith Ravindran +Date: Fri, 31 May 2024 19:51:49 +0000 +Subject: [PATCH] suite-sparse include and library path 6.1.1 + +--- + CMakeLists.txt | 1 + + library/src/CMakeLists.txt | 2 +- + 2 files changed, 2 insertions(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 52a059a..fddda0b 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -88,6 +88,7 @@ include( ROCMPackageConfigHelpers ) + include( ROCMInstallSymlinks ) + include( ROCMClients ) + include( ROCMHeaderWrapper ) ++include_directories(${SUITE_SPARSE_PATH}/include) + + set ( VERSION_STRING "2.1.1" ) + rocm_setup_version( VERSION ${VERSION_STRING} ) +diff --git a/library/src/CMakeLists.txt b/library/src/CMakeLists.txt +index ec708df..7b0e414 100644 +--- a/library/src/CMakeLists.txt ++++ b/library/src/CMakeLists.txt +@@ -135,7 +135,7 @@ if( NOT USE_CUDA ) + endif( ) + endif( ) + +- target_link_libraries( hipsolver PRIVATE roc::rocsparse suitesparseconfig cholmod ) ++ target_link_libraries( hipsolver PRIVATE roc::rocsparse ${SUITE_SPARSE_LIBDIR}/libsuitesparseconfig.so ${SUITE_SPARSE_LIBDIR}/libcholmod.so ) + set_source_files_properties(${hipsolver_source} + PROPERTIES + COMPILE_DEFINITIONS HAVE_ROCSPARSE +-- +2.17.1 + diff --git a/var/spack/repos/builtin/packages/hipsolver/001-suite-sparse-include-path.patch b/var/spack/repos/builtin/packages/hipsolver/001-suite-sparse-include-path.patch new file mode 100644 index 00000000000000..5a33b969e792eb --- /dev/null +++ b/var/spack/repos/builtin/packages/hipsolver/001-suite-sparse-include-path.patch @@ -0,0 +1,38 @@ +From 90c1913a29f6ee097aea18a66deb0a4fb0bc0066 Mon Sep 17 00:00:00 2001 +From: Renjith Ravindran +Date: Sat, 8 Jun 2024 00:46:22 +0000 +Subject: [PATCH] add SUITE_SPARSE_PATH to the CMakeLists.txt + +--- + CMakeLists.txt | 1 + + library/src/CMakeLists.txt | 2 +- + 2 files changed, 2 insertions(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 95a2393..b403f57 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -88,6 +88,7 @@ include( ROCMPackageConfigHelpers ) + include( ROCMInstallSymlinks ) + include( ROCMClients ) + include( ROCMHeaderWrapper ) ++include_directories(${SUITE_SPARSE_PATH}/include/suitesparse) + + set ( VERSION_STRING "2.1.0" ) + rocm_setup_version( VERSION ${VERSION_STRING} ) +diff --git a/library/src/CMakeLists.txt b/library/src/CMakeLists.txt +index ab448f4..f3d759e 100644 +--- a/library/src/CMakeLists.txt ++++ b/library/src/CMakeLists.txt +@@ -135,7 +135,7 @@ if( NOT USE_CUDA ) + endif( ) + endif( ) + +- target_link_libraries( hipsolver PRIVATE roc::rocsparse suitesparseconfig cholmod ) ++ target_link_libraries( hipsolver PRIVATE roc::rocsparse ${SUITE_SPARSE_LIBDIR}/libsuitesparseconfig.so ${SUITE_SPARSE_LIBDIR}/libcholmod.so ) + target_include_directories( hipsolver + SYSTEM PRIVATE + $ +-- +2.27.0 + diff --git a/var/spack/repos/builtin/packages/hipsolver/package.py b/var/spack/repos/builtin/packages/hipsolver/package.py index cefe8644b229dd..26ab14eb0c02d9 100644 --- a/var/spack/repos/builtin/packages/hipsolver/package.py +++ b/var/spack/repos/builtin/packages/hipsolver/package.py @@ -3,6 +3,7 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os import re from spack.package import * @@ -18,7 +19,7 @@ class Hipsolver(CMakePackage, CudaPackage, ROCmPackage): homepage = "https://github.com/ROCm/hipSOLVER" git = "https://github.com/ROCm/hipSOLVER.git" - url = "https://github.com/ROCm/hipSOLVER/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/hipSOLVER/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("cgmb", "srekolam", "renjithravindrankannath") @@ -28,6 +29,9 @@ class Hipsolver(CMakePackage, CudaPackage, ROCmPackage): version("develop", branch="develop") version("master", branch="master") + version("6.1.2", sha256="406a8e5b82daae2fc03e0a738b5a054ade01bb41785cee4afb9e21c7ec91d492") + version("6.1.1", sha256="01d4553458f417824807c069cacfc65d23f6cac79536158473b4356986c8fafd") + version("6.1.0", sha256="3cb89ca486cdbdfcb1a07c35ee65f60219ef7bc62a5b0f94ca1a3206a0106495") version("6.0.2", sha256="8215e55c3a5bc9c7eeb141cefdc6a6eeba94d8bc3aeae9e685ab7904965040d4") version("6.0.0", sha256="385849db02189d5e62096457e52ae899ae5c1ae7d409dc1da61f904d8861b48c") version("5.7.1", sha256="5592e965c0dc5722931302289643d1ece370220af2c7afc58af97b3395295658") @@ -36,16 +40,15 @@ class Hipsolver(CMakePackage, CudaPackage, ROCmPackage): version("5.6.0", sha256="11fa51d210853d93d24d55b20367738e49711793412f58e8d7689710b92ae16c") version("5.5.1", sha256="826bd64a4887176595bb7319d9a3612e7327602efe1f42aa3f2ad0e783d1a180") version("5.5.0", sha256="0f45be0f90907381ae3e82424599e2ca2112d6411b4a64c72558d63f00409b83") - version("5.4.3", sha256="02a1bffecc494393f49f97174db7d2c101db557d32404923a44520876e682e3a") - version("5.4.0", sha256="d53d81c55b458ba5e6ea0ec6bd24bcc79ab06789730391da82d8c33b936339d9") - version("5.3.3", sha256="f5a487a1c7225ab748996ac4d837ac7ab26b43618c4ed97a124f8fac1d67786e") - version("5.3.0", sha256="6e920a59ddeefd52c9a6d164c33bc097726529e1ede3c417c711697956655b15") with default_args(deprecated=True): - version("5.2.3", sha256="a57d883fdd09c6c7f9856fcfcabee6fa7ff9beed33d2f1a465bf28d38ea6f364") - version("5.2.1", sha256="e000b08cf7bfb5f8f6d65d163ebeeb3274172b9f474228b810bde5e6f87f2b37") - version("5.2.0", sha256="96927410e0a2cc0f50172604ef6437e15d2cf4b62d22b2035f13aae21f43dc82") - version("5.1.3", sha256="96faa799a2db8078b72f9c3b5c199179875a7c20dc1064371b22a6a63397c145") - version("5.1.0", sha256="697ba2b2814e7ac6f79680e6455b4b5e0def1bee2014b6940f47be7d13c0ae74") + version("5.4.3", sha256="02a1bffecc494393f49f97174db7d2c101db557d32404923a44520876e682e3a") + version("5.4.0", sha256="d53d81c55b458ba5e6ea0ec6bd24bcc79ab06789730391da82d8c33b936339d9") + version("5.3.3", sha256="f5a487a1c7225ab748996ac4d837ac7ab26b43618c4ed97a124f8fac1d67786e") + version("5.3.0", sha256="6e920a59ddeefd52c9a6d164c33bc097726529e1ede3c417c711697956655b15") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated # default to an 'auto' variant until amdgpu_targets can be given a better default than 'none' amdgpu_targets = ROCmPackage.amdgpu_targets @@ -70,8 +73,10 @@ class Hipsolver(CMakePackage, CudaPackage, ROCmPackage): values=("Release", "Debug", "RelWithDebInfo"), description="CMake build type", ) + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") depends_on("cmake@3.5:", type="build") + depends_on("suite-sparse", type="build") depends_on("rocm-cmake@5.2.0:", type="build", when="@5.2.0:") depends_on("rocm-cmake@4.5.0:", type="build") @@ -79,11 +84,6 @@ class Hipsolver(CMakePackage, CudaPackage, ROCmPackage): depends_on("hip +cuda", when="+cuda") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -96,6 +96,9 @@ class Hipsolver(CMakePackage, CudaPackage, ROCmPackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", "develop", ]: @@ -108,6 +111,8 @@ class Hipsolver(CMakePackage, CudaPackage, ROCmPackage): depends_on("googletest@1.10.0:", type="test") depends_on("netlib-lapack@3.7.1:", type="test") + patch("001-suite-sparse-include-path.patch", when="@6.1.0") + patch("0001-suite-sparse-include-path-6.1.1.patch", when="@6.1.1:") def check(self): exe = join_path(self.build_directory, "clients", "staging", "hipsolver-test") @@ -124,19 +129,23 @@ def determine_version(cls, lib): ver = None return ver + def setup_build_environment(self, env): + if self.spec.satisfies("+asan"): + self.asan_on(env) + def cmake_args(self): args = [ self.define("BUILD_CLIENTS_SAMPLES", "OFF"), self.define("BUILD_CLIENTS_TESTS", self.run_tests), + self.define("SUITE_SPARSE_PATH", self.spec["suite-sparse"].prefix), + self.define("ROCBLAS_PATH", self.spec["rocblas"].prefix), ] args.append(self.define_from_variant("USE_CUDA", "cuda")) # FindHIP.cmake is still used for +cuda if self.spec.satisfies("+cuda"): - if self.spec["hip"].satisfies("@:5.1"): - args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.cmake)) - else: + if self.spec["hip"].satisfies("@5.2:"): args.append( self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.lib.cmake.hip) ) @@ -145,5 +154,8 @@ def cmake_args(self): args.append(self.define("BUILD_FILE_REORG_BACKWARD_COMPATIBILITY", True)) if self.spec.satisfies("@5.3.0:"): args.append(self.define("CMAKE_INSTALL_LIBDIR", "lib")) - + libloc = self.spec["suite-sparse"].prefix.lib64 + if not os.path.isdir(libloc): + libloc = self.spec["suite-sparse"].prefix.lib + args.append(self.define("SUITE_SPARSE_LIBDIR", libloc)) return args diff --git a/var/spack/repos/builtin/packages/hipsparse/package.py b/var/spack/repos/builtin/packages/hipsparse/package.py index c3f06ba94c2c3f..57db492ea414db 100644 --- a/var/spack/repos/builtin/packages/hipsparse/package.py +++ b/var/spack/repos/builtin/packages/hipsparse/package.py @@ -14,13 +14,16 @@ class Hipsparse(CMakePackage, CudaPackage, ROCmPackage): homepage = "https://github.com/ROCm/hipSPARSE" git = "https://github.com/ROCm/hipSPARSE.git" - url = "https://github.com/ROCm/hipSPARSE/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/hipSPARSE/archive/rocm-6.1.1.tar.gz" tags = ["rocm"] maintainers("cgmb", "srekolam", "renjithravindrankannath", "haampie") libraries = ["libhipsparse"] license("MIT") + version("6.1.2", sha256="dd44f9b6000b3b0ac0fa238037a80f79d6745a689d4a6755f2d595643be1ef6d") + version("6.1.1", sha256="307cff012f0465942dd6666cb00ae60c35941699677c4b26b08e4832bc499059") + version("6.1.0", sha256="1d9277a11f71474ea4a9f8419a7a2c37170a86969584e5724e385ec74241e565") version("6.0.2", sha256="40c1d2493f87c686d9afd84a00321ad10ca0d0d80d6dcfeee8e51858dd1bd8c1") version("6.0.0", sha256="718a5f03b6a579c0542a60d00f5688bec53a181b429b7ee8ce3c8b6c4a78d754") version("5.7.1", sha256="16c3818260611226c3576d8d55ad8f51e0890d2473503edf2c9313250ae65ca7") @@ -29,16 +32,14 @@ class Hipsparse(CMakePackage, CudaPackage, ROCmPackage): version("5.6.0", sha256="3a6931b744ebaa4469a4c50d059a008403e4dc2a4f04dd69c3c6d20916b4a491") version("5.5.1", sha256="3d291e4fe2c611d555e54de66149b204fe7ac59f5dd00a9ad93bc6dca0528880") version("5.5.0", sha256="8122c8f17d899385de83efb7ac0d8a4fabfcd2aa21bbed63e63ea7adf0d22df6") - version("5.4.3", sha256="b373eccd03679a13fab4e740fc780da25cbd598abca3a1e5e3613ae14954f9db") - version("5.4.0", sha256="47420d38483c8124813b744971e428a0352c83d9b62a5a50f74ffa8f9b785b20") - version("5.3.3", sha256="d96d0e47594ab12e8c380da2300704c105736a0771940d7d2fae666f2869e457") - version("5.3.0", sha256="691b32b916952ed9af008aa29f60cc190322b73cfc098bb2eda3ff68c89c7b35") with default_args(deprecated=True): - version("5.2.3", sha256="f70d3deff13188adc4105ef3ead53510e4b54075b9ffcfe3d3355d90d4b6eadd") - version("5.2.1", sha256="7b8e4ff264285ae5aabb3c5c2b38bf28f90b2af44efb0398fcf13ffc24bc000a") - version("5.2.0", sha256="4fdab6ec953c6d2d000687c5979077deafd37208cd722554b5a6ede1e5ba170c") - version("5.1.3", sha256="6e6a0752654f0d391533df8cedf4b630a78ad34c99087741520c582963ce1602") - version("5.1.0", sha256="f41329534f2ff477a0db6b7f77a72bb062f117800970c122d676db8b207ce80b") + version("5.4.3", sha256="b373eccd03679a13fab4e740fc780da25cbd598abca3a1e5e3613ae14954f9db") + version("5.4.0", sha256="47420d38483c8124813b744971e428a0352c83d9b62a5a50f74ffa8f9b785b20") + version("5.3.3", sha256="d96d0e47594ab12e8c380da2300704c105736a0771940d7d2fae666f2869e457") + version("5.3.0", sha256="691b32b916952ed9af008aa29f60cc190322b73cfc098bb2eda3ff68c89c7b35") + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated # default to an 'auto' variant until amdgpu_targets can be given a better default than 'none' amdgpu_targets = ROCmPackage.amdgpu_targets @@ -54,6 +55,7 @@ class Hipsparse(CMakePackage, CudaPackage, ROCmPackage): sticky=True, ) variant("rocm", default=True, description="Enable ROCm support") + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") conflicts("+cuda +rocm", msg="CUDA and ROCm support are mutually exclusive") conflicts("~cuda ~rocm", msg="CUDA or ROCm support is required") @@ -63,11 +65,6 @@ class Hipsparse(CMakePackage, CudaPackage, ROCmPackage): depends_on("git", type="build") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -80,6 +77,9 @@ class Hipsparse(CMakePackage, CudaPackage, ROCmPackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") depends_on(f"rocsparse@{ver}", when=f"+rocm @{ver}") @@ -100,6 +100,10 @@ def determine_version(cls, lib): ver = None return ver + def setup_build_environment(self, env): + if self.spec.satisfies("+asan"): + self.asan_on(env) + def cmake_args(self): args = [ self.define("CMAKE_CXX_STANDARD", "14"), @@ -111,13 +115,7 @@ def cmake_args(self): # FindHIP.cmake is still used for +cuda if self.spec.satisfies("+cuda"): - if self.spec["hip"].satisfies("@:5.1"): - args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.cmake)) - else: - args.append( - self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.lib.cmake.hip) - ) - + args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.lib.cmake.hip)) if self.spec.satisfies("@5.2.0:"): args.append(self.define("BUILD_FILE_REORG_BACKWARD_COMPATIBILITY", True)) diff --git a/var/spack/repos/builtin/packages/hipsparselt/0001-update-llvm-path-add-hipsparse-include-dir-for-spack-6.1.patch b/var/spack/repos/builtin/packages/hipsparselt/0001-update-llvm-path-add-hipsparse-include-dir-for-spack-6.1.patch new file mode 100644 index 00000000000000..bd07d5af37cd06 --- /dev/null +++ b/var/spack/repos/builtin/packages/hipsparselt/0001-update-llvm-path-add-hipsparse-include-dir-for-spack-6.1.patch @@ -0,0 +1,77 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index e10585c..a29bc63 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -185,7 +185,7 @@ else() + set( tensile_fork "ROCmSoftwarePlatform" CACHE STRING "Tensile fork to use" ) + file (STRINGS "tensilelite_tag.txt" read_tensile_tag) + set( tensile_tag ${read_tensile_tag} CACHE STRING "Tensile tag to download" ) +- virtualenv_install("git+https://github.com/${tensile_fork}/hipBLASLt.git@${tensile_tag}#subdirectory=tensilelite") ++ virtualenv_install("git+https://github.com/ROCm/hipBLASLt.git@modify-tensilelite-spack#subdirectory=tensilelite") + + message (STATUS "using GIT Tensile fork=${tensile_fork} from branch=${tensile_tag}") + endif() +diff --git a/clients/gtest/CMakeLists.txt b/clients/gtest/CMakeLists.txt +index 2057db0..6085133 100644 +--- a/clients/gtest/CMakeLists.txt ++++ b/clients/gtest/CMakeLists.txt +@@ -53,6 +53,7 @@ target_include_directories( hipsparselt-test + $ + $ # may be blank if not used + $ ++ $ + ) + message("BLIS_INCLUDE_DIR=" ${BLIS_INCLUDE_DIR}) + target_link_libraries( hipsparselt-test PRIVATE ${BLAS_LIBRARY} ${GTEST_BOTH_LIBRARIES} roc::hipsparselt ) +diff --git a/clients/samples/CMakeLists.txt b/clients/samples/CMakeLists.txt +index 6b303d5..c6d608c 100644 +--- a/clients/samples/CMakeLists.txt ++++ b/clients/samples/CMakeLists.txt +@@ -50,6 +50,11 @@ foreach( exe ${sample_list_all} ) + $ + ) + ++ target_include_directories( ${exe} ++ SYSTEM PRIVATE ++ $ ++ ) ++ + if( CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang") + # GCC or hip-clang needs specific flags to turn on f16c intrinsics + target_compile_options( ${exe} PRIVATE -mf16c ) +diff --git a/library/CMakeLists.txt b/library/CMakeLists.txt +index aac8506..e282268 100644 +--- a/library/CMakeLists.txt ++++ b/library/CMakeLists.txt +@@ -58,6 +58,9 @@ include(src/CMakeLists.txt) + # Create hipSPARSELt library + add_library(hipsparselt ${hipsparselt_source} ${hipsparselt_headers_public}) + add_library(roc::hipsparselt ALIAS hipsparselt) ++target_include_directories( hipsparselt PRIVATE ${HIPSPARSE_INCLUDE_DIRS} ) ++target_include_directories( hipsparselt PRIVATE ${MSGPACK_DIR}/include ) ++ + + # Target compile definitions + if(NOT BUILD_CUDA) +diff --git a/library/src/CMakeLists.txt b/library/src/CMakeLists.txt +index 85f7cde..4c52b34 100755 +--- a/library/src/CMakeLists.txt ++++ b/library/src/CMakeLists.txt +@@ -61,7 +61,7 @@ if(NOT BUILD_CUDA) + if(Tensile_CPU_THREADS MATCHES "^[0-9]+$") + # only including threads argument if number + TensileCreateLibraryFiles( +- "${CMAKE_CURRENT_SOURCE_DIR}/src/hcc_detail/rocsparselt/src/spmm/Tensile/Logic/${Tensile_LOGIC}" ++ "${CMAKE_CURRENT_SOURCE_DIR}/src/hcc_detail/rocsparselt/src/spmm/Tensile/Logic" + "${PROJECT_BINARY_DIR}/Tensile" + ARCHITECTURE ${Tensile_ARCHITECTURE} + CODE_OBJECT_VERSION ${Tensile_CODE_OBJECT_VERSION} +@@ -72,7 +72,7 @@ if(NOT BUILD_CUDA) + ) + else() + TensileCreateLibraryFiles( +- "${CMAKE_CURRENT_SOURCE_DIR}/src/hcc_detail/rocsparselt/src/spmm/Tensile/Logic/${Tensile_LOGIC}" ++ "${CMAKE_CURRENT_SOURCE_DIR}/src/hcc_detail/rocsparselt/src/spmm/Tensile/Logic" + "${PROJECT_BINARY_DIR}/Tensile" + ARCHITECTURE ${Tensile_ARCHITECTURE} + CODE_OBJECT_VERSION ${Tensile_CODE_OBJECT_VERSION} diff --git a/var/spack/repos/builtin/packages/hipsparselt/0001-update-llvm-path-add-hipsparse-include-dir-for-spack.patch b/var/spack/repos/builtin/packages/hipsparselt/0001-update-llvm-path-add-hipsparse-include-dir-for-spack.patch new file mode 100644 index 00000000000000..1ad1b289ad7091 --- /dev/null +++ b/var/spack/repos/builtin/packages/hipsparselt/0001-update-llvm-path-add-hipsparse-include-dir-for-spack.patch @@ -0,0 +1,92 @@ +From c0ffe6cb718325634c353dec2894ac90ad6ea5e4 Mon Sep 17 00:00:00 2001 +From: sreenivasa murthy kolam +Date: Wed, 8 May 2024 10:25:43 +0000 +Subject: [PATCH] changes to find the llvm_path for spack and add + hipsparse_include_dirs + +--- + CMakeLists.txt | 2 +- + clients/gtest/CMakeLists.txt | 1 + + clients/samples/CMakeLists.txt | 4 ++++ + library/CMakeLists.txt | 2 ++ + library/src/CMakeLists.txt | 4 ++-- + 5 files changed, 10 insertions(+), 3 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 050826e..4cc2ee9 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -185,7 +185,7 @@ else() + set( tensile_fork "ROCmSoftwarePlatform" CACHE STRING "Tensile fork to use" ) + file (STRINGS "tensilelite_tag.txt" read_tensile_tag) + set( tensile_tag ${read_tensile_tag} CACHE STRING "Tensile tag to download" ) +- virtualenv_install("git+https://github.com/${tensile_fork}/hipBLASLt.git@${tensile_tag}#subdirectory=tensilelite") ++ virtualenv_install("git+https://github.com/ROCm/hipBLASLt.git@spack-change-tensilelite#subdirectory=tensilelite") + + message (STATUS "using GIT Tensile fork=${tensile_fork} from branch=${tensile_tag}") + endif() +diff --git a/clients/gtest/CMakeLists.txt b/clients/gtest/CMakeLists.txt +index 2057db0..6085133 100644 +--- a/clients/gtest/CMakeLists.txt ++++ b/clients/gtest/CMakeLists.txt +@@ -53,6 +53,7 @@ target_include_directories( hipsparselt-test + $ + $ # may be blank if not used + $ ++ $ + ) + message("BLIS_INCLUDE_DIR=" ${BLIS_INCLUDE_DIR}) + target_link_libraries( hipsparselt-test PRIVATE ${BLAS_LIBRARY} ${GTEST_BOTH_LIBRARIES} roc::hipsparselt ) +diff --git a/clients/samples/CMakeLists.txt b/clients/samples/CMakeLists.txt +index 6b303d5..a06fdc2 100644 +--- a/clients/samples/CMakeLists.txt ++++ b/clients/samples/CMakeLists.txt +@@ -50,6 +50,10 @@ foreach( exe ${sample_list_all} ) + $ + ) + ++ target_include_directories( ${exe} ++ SYSTEM PRIVATE ++ $ ++ ) + if( CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang") + # GCC or hip-clang needs specific flags to turn on f16c intrinsics + target_compile_options( ${exe} PRIVATE -mf16c ) +diff --git a/library/CMakeLists.txt b/library/CMakeLists.txt +index aac8506..bc13d51 100644 +--- a/library/CMakeLists.txt ++++ b/library/CMakeLists.txt +@@ -58,6 +58,8 @@ include(src/CMakeLists.txt) + # Create hipSPARSELt library + add_library(hipsparselt ${hipsparselt_source} ${hipsparselt_headers_public}) + add_library(roc::hipsparselt ALIAS hipsparselt) ++target_include_directories( hipsparselt PRIVATE ${HIPSPARSE_INCLUDE_DIRS} ) ++target_include_directories( hipsparselt PRIVATE ${MSGPACK_DIR}/include ) + + # Target compile definitions + if(NOT BUILD_CUDA) +diff --git a/library/src/CMakeLists.txt b/library/src/CMakeLists.txt +index 85f7cde..94d2274 100755 +--- a/library/src/CMakeLists.txt ++++ b/library/src/CMakeLists.txt +@@ -61,7 +61,7 @@ if(NOT BUILD_CUDA) + if(Tensile_CPU_THREADS MATCHES "^[0-9]+$") + # only including threads argument if number + TensileCreateLibraryFiles( +- "${CMAKE_CURRENT_SOURCE_DIR}/src/hcc_detail/rocsparselt/src/spmm/Tensile/Logic/${Tensile_LOGIC}" ++ "${CMAKE_CURRENT_SOURCE_DIR}/src/hcc_detail/rocsparselt/src/spmm/Tensile/Logic" + "${PROJECT_BINARY_DIR}/Tensile" + ARCHITECTURE ${Tensile_ARCHITECTURE} + CODE_OBJECT_VERSION ${Tensile_CODE_OBJECT_VERSION} +@@ -72,7 +72,7 @@ if(NOT BUILD_CUDA) + ) + else() + TensileCreateLibraryFiles( +- "${CMAKE_CURRENT_SOURCE_DIR}/src/hcc_detail/rocsparselt/src/spmm/Tensile/Logic/${Tensile_LOGIC}" ++ "${CMAKE_CURRENT_SOURCE_DIR}/src/hcc_detail/rocsparselt/src/spmm/Tensile/Logic" + "${PROJECT_BINARY_DIR}/Tensile" + ARCHITECTURE ${Tensile_ARCHITECTURE} + CODE_OBJECT_VERSION ${Tensile_CODE_OBJECT_VERSION} +-- +2.39.3 + diff --git a/var/spack/repos/builtin/packages/hipsparselt/package.py b/var/spack/repos/builtin/packages/hipsparselt/package.py new file mode 100644 index 00000000000000..72a0a904c57602 --- /dev/null +++ b/var/spack/repos/builtin/packages/hipsparselt/package.py @@ -0,0 +1,86 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class Hipsparselt(CMakePackage, ROCmPackage): + """hipSPARSELt is a SPARSE marshalling library, with multiple supported backends. + It sits between the application and a 'worker' SPARSE library, marshalling inputs into + the backend library and marshalling results back to the application. hipSPARSELt exports + an interface that does not require the client to change, regardless of the chosen backend. + Currently, hipSPARSELt supports rocSPARSELt and cuSPARSELt v0.4 as backends.""" + + homepage = "https://github.com/ROCm/hipsparselt" + url = "https://github.com/ROCm/hipSPARSELt/archive/refs/tags/rocm-6.1.2.tar.gz" + git = "https://github.com/ROCm/hipsparseLt.git" + + maintainers("srekolam", "afzpatel", "renjithravindrankannath") + + license("MIT") + version("6.1.2", sha256="a5a01fec7bc6e1f4792ccd5c8eaee7b42deac315c54298a7ce5265e5551e8640") + version("6.1.1", sha256="ca6da099d9e385ffce2b68404f395a93b199af1592037cf52c620f9148a6a78d") + version("6.1.0", sha256="66ade6de4fd19d144cab27214352faf5b00bbe12afe59472efb441b16d090265") + version("6.0.2", sha256="bdbceeae515f737131f0391ee3b7d2f7b655e3cf446e4303d93f083c59053587") + version("6.0.0", sha256="cc4c7970601edbaa7f630b7ea24ae85beaeae466ef3e5ba63e11eab52465c157") + + depends_on("cxx", type="build") # generated + + amdgpu_targets = ROCmPackage.amdgpu_targets + variant( + "amdgpu_target", + description="AMD GPU architecture", + values=spack.variant.DisjointSetsOfValues(("auto",), ("none",), amdgpu_targets) + .with_default("auto") + .with_error( + "the values 'auto' and 'none' are mutually exclusive with any of the other values" + ) + .with_non_feature_values("auto", "none"), + sticky=True, + ) + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") + + for ver in ["6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: + depends_on(f"hip@{ver}", when=f"@{ver}") + depends_on(f"hipsparse@{ver}", when=f"@{ver}") + depends_on(f"rocm-openmp-extras@{ver}", when=f"@{ver}", type="test") + + depends_on("cmake@3.5:", type="build") + depends_on("msgpack-c@3:") + depends_on("python@3.6:") + depends_on("py-virtualenv") + depends_on("py-wheel") + depends_on("py-pip") + depends_on("py-pyyaml", type="test") + depends_on("py-joblib") + depends_on("googletest@1.10.0:", type="test") + depends_on("netlib-lapack@3.7.1:", type="test") + + patch("0001-update-llvm-path-add-hipsparse-include-dir-for-spack.patch", when="@6.0") + # Below patch sets the proper path for clang++,lld and clang-offload-blunder inside the + # tensorlite subdir of hipblas . Also adds hipsparse and msgpack include directories + # for 6.1.0 release. + patch("0001-update-llvm-path-add-hipsparse-include-dir-for-spack-6.1.patch", when="@6.1") + + def setup_build_environment(self, env): + env.set("CXX", self.spec["hip"].hipcc) + + def cmake_args(self): + args = [ + self.define("Tensile_CODE_OBJECT_VERSION", "default"), + self.define("MSGPACK_DIR", self.spec["msgpack-c"].prefix), + self.define_from_variant("BUILD_ADDRESS_SANITIZER", "asan"), + self.define("BUILD_CLIENTS_TESTS", self.run_tests), + self.define("BUILD_SHARED_LIBS", "ON"), + self.define("BUILD_CLIENTS_SAMPLES", "OFF"), + ] + if "auto" not in self.spec.variants["amdgpu_target"]: + args.append(self.define_from_variant("AMDGPU_TARGETS", "amdgpu_target")) + if self.run_tests: + args.append( + self.define("ROCM_OPENMP_EXTRAS_DIR", self.spec["rocm-openmp-extras"].prefix) + ) + return args diff --git a/var/spack/repos/builtin/packages/hipsycl/package.py b/var/spack/repos/builtin/packages/hipsycl/package.py index 98a2b8cb19af33..1be98ca586eab7 100644 --- a/var/spack/repos/builtin/packages/hipsycl/package.py +++ b/var/spack/repos/builtin/packages/hipsycl/package.py @@ -35,6 +35,8 @@ class Hipsycl(CMakePackage): version("0.8.0", commit="2daf8407e49dd32ebd1c266e8e944e390d28b22a", submodules=True) version("develop", branch="develop", submodules=True) + depends_on("cxx", type="build") # generated + variant("cuda", default=False, description="Enable CUDA backend for SYCL kernels") depends_on("cmake@3.5:", type="build") diff --git a/var/spack/repos/builtin/packages/hiptt/package.py b/var/spack/repos/builtin/packages/hiptt/package.py index 2e3c4704c27384..69d02a1ee3b0a1 100644 --- a/var/spack/repos/builtin/packages/hiptt/package.py +++ b/var/spack/repos/builtin/packages/hiptt/package.py @@ -20,6 +20,8 @@ class Hiptt(MakefilePackage, ROCmPackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + patch("bugfix_make.patch") # To enable this package add it to the LD_LIBRARY_PATH diff --git a/var/spack/repos/builtin/packages/hiredis/package.py b/var/spack/repos/builtin/packages/hiredis/package.py index c54f214367f8d0..be1d469c8900f7 100644 --- a/var/spack/repos/builtin/packages/hiredis/package.py +++ b/var/spack/repos/builtin/packages/hiredis/package.py @@ -26,6 +26,9 @@ class Hiredis(MakefilePackage, CMakePackage): version("0.13.3", sha256="717e6fc8dc2819bef522deaca516de9e51b9dfa68fe393b7db5c3b6079196f78") version("0.13.2", sha256="b0cf73ebe039fe25ecaaa881acdda8bdc393ed997e049b04fc20865835953694") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_system( conditional("cmake", when="@1:"), conditional("makefile", when="@:0"), default="cmake" ) diff --git a/var/spack/repos/builtin/packages/hisat2/package.py b/var/spack/repos/builtin/packages/hisat2/package.py index f4f2886fc7ea33..6821930bb184bd 100644 --- a/var/spack/repos/builtin/packages/hisat2/package.py +++ b/var/spack/repos/builtin/packages/hisat2/package.py @@ -31,7 +31,12 @@ class Hisat2(MakefilePackage): url="https://cloud.biohpc.swmed.edu/index.php/s/hisat2-220-source/download", extension="zip", ) - version("2.1.0", sha256="89a276eed1fc07414b1601947bc9466bdeb50e8f148ad42074186fe39a1ee781") + version( + "2.1.0", + sha256="89a276eed1fc07414b1601947bc9466bdeb50e8f148ad42074186fe39a1ee781", + url="ftp://ftp.ccb.jhu.edu/pub/infphilo/hisat2/downloads/hisat2-2.1.0-source.zip", + extension="zip", + ) variant("sra", default=False, description="Add SRA (Sequence Read Archive) support") @@ -48,8 +53,8 @@ class Hisat2(MakefilePackage): def build(self, spec, prefix): make( "USE_SRA=1", - "NCBI_NGS_DIR={0}".format(spec["sra-tools"].prefix), - "NCBI_VDB_DIR={0}".format(spec["ncbi-vdb"].prefix), + f"NCBI_NGS_DIR={spec['sra-tools'].prefix}", + f"NCBI_VDB_DIR={spec['ncbi-vdb'].prefix}", ) def install(self, spec, prefix): @@ -59,7 +64,7 @@ def install(self, spec, prefix): install_tree("example", prefix.example) install_tree("scripts", prefix.scripts) - if "@:2.2.0" in spec: + if spec.satisfies("@:2.2.0"): install_tree("hisatgenotype_modules", prefix.hisatgenotype_modules) install_tree("hisatgenotype_scripts", prefix.hisatgenotype_scripts) @@ -75,33 +80,33 @@ def install(self, spec, prefix): install("hisat2-inspect-l", prefix.bin) install("*.py", prefix.bin) - if "@2.2:" in spec: + if spec.satisfies("@2.2:"): install("hisat2-repeat", prefix.bin) @run_after("install") def filter_sbang(self): with working_dir(self.prefix.bin): pattern = "^#!.*/usr/bin/env python" - repl = "#!{0}".format(self.spec["python"].command.path) + repl = f"#!{self.spec['python'].command.path}" files = ["hisat2-build", "hisat2-inspect"] for file in files: filter_file(pattern, repl, *files, backup=False) pattern = "^#!.*/usr/bin/env perl" - repl = "#!{0}".format(self.spec["perl"].command.path) + repl = f"#!{self.spec['perl'].command.path}" files = ["hisat2"] for file in files: filter_file(pattern, repl, *files, backup=False) pattern = "^#!.*/usr/bin/env python3" - repl = "#!{0}".format(self.spec["python"].command.path) + repl = f"#!{self.spec['python'].command.path}" files = glob.glob("*.py") for file in files: filter_file(pattern, repl, *files, backup=False) with working_dir(self.prefix.scripts): pattern = "^#!.*/usr/bin/perl" - repl = "#!{0}".format(self.spec["perl"].command.path) + repl = f"#!{self.spec['perl'].command.path}" files = glob.glob("*.pl") for file in files: filter_file(pattern, repl, *files, backup=False) diff --git a/var/spack/repos/builtin/packages/hisea/package.py b/var/spack/repos/builtin/packages/hisea/package.py index ff08e1d90cc03d..5fc33ae1a7f938 100644 --- a/var/spack/repos/builtin/packages/hisea/package.py +++ b/var/spack/repos/builtin/packages/hisea/package.py @@ -22,6 +22,8 @@ class Hisea(MakefilePackage): url="https://github.com/lucian-ilie/HISEA/tarball/39e01e98caa0f2101da806ca59306296effe789c", ) + depends_on("cxx", type="build") # generated + # TODO: replace this with an explicit list of components of Boost, # for instance depends_on('boost +filesystem') # See https://github.com/spack/spack/pull/22303 for reference diff --git a/var/spack/repos/builtin/packages/hivex/package.py b/var/spack/repos/builtin/packages/hivex/package.py index 9a231f270eae46..c44d5a509d3bb7 100644 --- a/var/spack/repos/builtin/packages/hivex/package.py +++ b/var/spack/repos/builtin/packages/hivex/package.py @@ -19,4 +19,6 @@ class Hivex(AutotoolsPackage): version("1.3.18", sha256="8a1e788fd9ea9b6e8a99705ebd0ff8a65b1bdee28e319c89c4a965430d0a7445") version("1.3.17", sha256="13cb4b87ab72d74d9e83e56ae0f77152312f33ee772dc84fdd86b2cb9e8c52db") + depends_on("c", type="build") # generated + depends_on("perl") diff --git a/var/spack/repos/builtin/packages/hmmer/package.py b/var/spack/repos/builtin/packages/hmmer/package.py index 0df0c49501a8fa..9a35cd76ecef05 100644 --- a/var/spack/repos/builtin/packages/hmmer/package.py +++ b/var/spack/repos/builtin/packages/hmmer/package.py @@ -25,6 +25,8 @@ class Hmmer(Package): version("2.3.2", sha256="d20e1779fcdff34ab4e986ea74a6c4ac5c5f01da2993b14e92c94d2f076828b4") version("2.3.1", sha256="3956d53af8de5bb99eec18cba0628e86924c6543639d290293b6677a9224ea3f") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Compile with MPI") variant("gsl", default=False, description="Compile with GSL") diff --git a/var/spack/repos/builtin/packages/hohqmesh/package.py b/var/spack/repos/builtin/packages/hohqmesh/package.py index d5bd80bf16b8e5..15af8fb92611c2 100644 --- a/var/spack/repos/builtin/packages/hohqmesh/package.py +++ b/var/spack/repos/builtin/packages/hohqmesh/package.py @@ -17,12 +17,19 @@ class Hohqmesh(CMakePackage): license("MIT") + version("1.5.0", sha256="e2a8ff604b93b49dbab101edd6f031e5032535ec96a84ea58906a326be1c8f04") + version("1.4.2", sha256="656c149b510b6d3e914d1794c27b4802699c9fd209afff8aec3a219a9e7f86ff") + version("1.4.1", sha256="bbfecdba3899bf124bdac2bf91f1262a8e2f224ba699d55bdf8546073fc62b21") + version("1.4.0", sha256="f3a8ca4906d86360260b55cf79f66ba7e35f8c3c293ae6d83361d9edf5f70e6d") version("1.3.0", sha256="31ea80de15ece886df0dd1b941714d86ec06a9ed02c1415308b4ba23d8314eff") version("1.2.1", sha256="b1b13a680c3ef6b8d6a8d05406f68c1ff641c26f69c468ccf2d7bed8d556dd7e") + version("1.2.0", sha256="39387276a2f145618b1ec3486426f181fc3f3fe1e85519505735a44f0b480967") version("1.1.0", sha256="5fdb75157d9dc29bba55e6ae9dc2be71294754204f4f0912795532ae66aada10") version("1.0.1", sha256="8435f13c96d714a287f3c24392330047e2131d53fafe251a77eba365bd2b3141") version("1.0.0", sha256="3800e63975d0a61945508f13fb76d5e2145c0260440484252b6b81aa0bfe076d") + depends_on("fortran", type="build") # generated + depends_on("ftobjectlibrary") parallel = False diff --git a/var/spack/repos/builtin/packages/hoomd-blue/package.py b/var/spack/repos/builtin/packages/hoomd-blue/package.py index 54afb419c15888..e5e3a96fa7cf1d 100644 --- a/var/spack/repos/builtin/packages/hoomd-blue/package.py +++ b/var/spack/repos/builtin/packages/hoomd-blue/package.py @@ -35,6 +35,9 @@ class HoomdBlue(CMakePackage): "2.1.6", tag="v2.1.6", commit="aa650aaf13721f2abf945e868f65b806fcc54fea", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Compile with MPI enabled") variant("cuda", default=True, description="Compile with CUDA Toolkit") variant("doc", default=False, description="Generate documentation") diff --git a/var/spack/repos/builtin/packages/hoppet/package.py b/var/spack/repos/builtin/packages/hoppet/package.py index e2cade0a732c69..54b663d15af2d5 100644 --- a/var/spack/repos/builtin/packages/hoppet/package.py +++ b/var/spack/repos/builtin/packages/hoppet/package.py @@ -17,3 +17,6 @@ class Hoppet(AutotoolsPackage): maintainers("haralmha") version("1.2.0", sha256="6e00eb56a4f922d03dfceba7b389a3aaf51f277afa46d7b634d661e0797e8898") + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/hotspot/package.py b/var/spack/repos/builtin/packages/hotspot/package.py index 2d9d0a0cf6465b..f7eae01e183148 100644 --- a/var/spack/repos/builtin/packages/hotspot/package.py +++ b/var/spack/repos/builtin/packages/hotspot/package.py @@ -15,6 +15,8 @@ class Hotspot(MakefilePackage): version("6.0", commit="a7a3286e368867c26381e0a23e36b3e273bdeda9") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdir(prefix.bin) install("hotspot", prefix.bin) diff --git a/var/spack/repos/builtin/packages/hpcc/package.py b/var/spack/repos/builtin/packages/hpcc/package.py index 08c620c00d97a0..0a6c77863f9a53 100644 --- a/var/spack/repos/builtin/packages/hpcc/package.py +++ b/var/spack/repos/builtin/packages/hpcc/package.py @@ -40,6 +40,8 @@ class Hpcc(MakefilePackage): version("develop", branch="main") version("1.5.0", sha256="0a6fef7ab9f3347e549fed65ebb98234feea9ee18aea0c8f59baefbe3cf7ffb8") + depends_on("c", type="build") # generated + variant( "fft", default="internal", @@ -54,7 +56,7 @@ class Hpcc(MakefilePackage): depends_on("fftw@2+mpi", when="fft=fftw2") depends_on("mkl", when="fft=mkl") - arch = "{0}-{1}".format(platform.system(), platform.processor()) + arch = f"{platform.system()}-{platform.processor()}" config = { "@SHELL@": "/bin/sh", @@ -94,7 +96,7 @@ def _write_make_arch(self, spec, prefix): """write make.arch file""" with working_dir("hpl"): # copy template make.arch file - make_arch_filename = "Make.{0}".format(self.arch) + make_arch_filename = f"Make.{self.arch}" copy(join_path("setup", "Make.UNKNOWN.in"), make_arch_filename) # fill template with values @@ -123,7 +125,7 @@ def edit(self, spec, prefix): and spec["fftw-api"].name in INTEL_MATH_LIBRARIES ): mklroot = env["MKLROOT"] - self.config["@LAINC@"] += " -I{0}".format(join_path(mklroot, "include/fftw")) + self.config["@LAINC@"] += f" -I{join_path(mklroot, 'include/fftw')}" libfftw2x_cdft = join_path( mklroot, "lib", "intel64", "libfftw2x_cdft_DOUBLE_ilp64.a" ) @@ -153,19 +155,19 @@ def edit(self, spec, prefix): self.config["@LALIB@"] = " ".join(lin_alg_libs) # Compilers / linkers - Optimization flags - self.config["@CC@"] = "{0}".format(spec["mpi"].mpicc) + self.config["@CC@"] = f"{spec['mpi'].mpicc}" # Compiler flags for CPU architecture optimizations if spec.satisfies("%intel"): # with intel-parallel-studio+mpi the '-march' arguments # are not passed to icc - arch_opt = spec.target.optimization_flags(spec.compiler.name, spec.compiler.version) - self.config["@CCFLAGS@"] = "-O3 -restrict -ansi-alias -ip {0}".format(arch_opt) + arch_opt = spec.architecture.target.optimization_flags(spec.compiler) + self.config["@CCFLAGS@"] = f"-O3 -restrict -ansi-alias -ip {arch_opt}" self.config["@CCNOOPT@"] = "-restrict" self._write_make_arch(spec, prefix) def build(self, spec, prefix): - make("arch={0}".format(self.arch)) + make(f"arch={self.arch}") def check(self): """Simple check that compiled binary is working: diff --git a/var/spack/repos/builtin/packages/hpccg/package.py b/var/spack/repos/builtin/packages/hpccg/package.py index eca4f30b26ae6b..676bf9764d0781 100644 --- a/var/spack/repos/builtin/packages/hpccg/package.py +++ b/var/spack/repos/builtin/packages/hpccg/package.py @@ -19,6 +19,8 @@ class Hpccg(MakefilePackage): version("1.0", sha256="5be1b8cc3246811bfc9d6d7072be29455777d61b585675512ae52043ea64cefc") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Build with MPI support") variant("openmp", default=True, description="Build with OpenMP support") diff --git a/var/spack/repos/builtin/packages/hpcg/package.py b/var/spack/repos/builtin/packages/hpcg/package.py index 2f261b5836091e..52da05d90699a1 100644 --- a/var/spack/repos/builtin/packages/hpcg/package.py +++ b/var/spack/repos/builtin/packages/hpcg/package.py @@ -21,6 +21,8 @@ class Hpcg(AutotoolsPackage): version("develop", branch="master") version("3.1", sha256="33a434e716b79e59e745f77ff72639c32623e7f928eeb7977655ffcaade0f4a4") + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Enable OpenMP support") patch( @@ -48,6 +50,11 @@ class Hpcg(AutotoolsPackage): sha256="722c13837b287e979442f8372274aa5910a290aa39f1ed1ff646116be08dcae9", when="%intel", ) + patch( + "https://github.com/hpcg-benchmark/hpcg/commit/e9e0b7e6cae23e1f30dd983c2ce2d3bd34d56f75.patch?full_index=1", + sha256="722c13837b287e979442f8372274aa5910a290aa39f1ed1ff646116be08dcae9", + when="%clang", + ) depends_on("mpi@1.1:") @@ -62,6 +69,7 @@ def configure(self, spec, prefix): and not spec.satisfies("%arm") and not spec.satisfies("%intel") and not spec.satisfies("%oneapi") + and not spec.satisfies("%clang") ): CXXFLAGS += " -ftree-vectorizer-verbose=0 " if spec.satisfies("%cce"): diff --git a/var/spack/repos/builtin/packages/hpctoolkit/correcting-hsa-include-path.patch b/var/spack/repos/builtin/packages/hpctoolkit/correcting-hsa-include-path.patch new file mode 100644 index 00000000000000..3d9a73db2fd628 --- /dev/null +++ b/var/spack/repos/builtin/packages/hpctoolkit/correcting-hsa-include-path.patch @@ -0,0 +1,13 @@ +diff --git a/configure.ac b/configure.ac +index 34b2613..8fa980d 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -4861,7 +4861,7 @@ case "$ROCM_HSA" in + found=yes + elif test -f "$ROCM_HSA/include/hsa/hsa.h" ; then + AC_MSG_NOTICE([found $ROCM_HSA/include/hsa/hsa.h]) +- ROCM_HSA_IFLAGS="-I$ROCM_HSA/include/hsa" ++ ROCM_HSA_IFLAGS="-I$ROCM_HSA/include/hsa -I$ROCM_HSA/include" + ROCM_HSA_INC_MESG="$ROCM_HSA" + found=yes + fi diff --git a/var/spack/repos/builtin/packages/hpctoolkit/package.py b/var/spack/repos/builtin/packages/hpctoolkit/package.py index fa91153eb24a04..e947d25cb31b48 100644 --- a/var/spack/repos/builtin/packages/hpctoolkit/package.py +++ b/var/spack/repos/builtin/packages/hpctoolkit/package.py @@ -32,16 +32,17 @@ class Hpctoolkit(AutotoolsPackage, MesonPackage): version("develop", branch="develop") version("2024.01.stable", branch="release/2024.01") + version("2024.01.1", tag="2024.01.1", commit="0672b9a9a2a1e3846c5e2059fb73a07a129f22cd") version("2023.08.stable", branch="release/2023.08") version("2023.08.1", tag="2023.08.1", commit="753a72affd584a5e72fe153d1e8c47a394a3886e") version("2023.03.stable", branch="release/2023.03") version("2023.03.01", commit="9e0daf2ad169f6c7f6c60408475b3c2f71baebbf") version("2022.10.01", commit="e8a5cc87e8f5ddfd14338459a4106f8e0d162c83") - version("2022.05.15", commit="8ac72d9963c4ed7b7f56acb65feb02fbce353479") - version("2022.04.15", commit="a92fdad29fc180cc522a9087bba9554a829ee002") - version("2022.01.15", commit="0238e9a052a696707e4e65b2269f342baad728ae") - version("2021.10.15", commit="a8f289e4dc87ff98e05cfc105978c09eb2f5ea16") - version("2021.05.15", commit="004ea0c2aea6a261e7d5d216c24f8a703fc6c408") + version("2022.05.15", commit="8ac72d9963c4ed7b7f56acb65feb02fbce353479", deprecated=True) + version("2022.04.15", commit="a92fdad29fc180cc522a9087bba9554a829ee002", deprecated=True) + version("2022.01.15", commit="0238e9a052a696707e4e65b2269f342baad728ae", deprecated=True) + version("2021.10.15", commit="a8f289e4dc87ff98e05cfc105978c09eb2f5ea16", deprecated=True) + version("2021.05.15", commit="004ea0c2aea6a261e7d5d216c24f8a703fc6c408", deprecated=True) version("2021.03.01", commit="68a051044c952f0f4dac459d9941875c700039e7", deprecated=True) version("2020.08.03", commit="d9d13c705d81e5de38e624254cf0875cce6add9a", deprecated=True) version("2020.07.21", commit="4e56c780cffc53875aca67d6472a2fb3678970eb", deprecated=True) @@ -49,8 +50,9 @@ class Hpctoolkit(AutotoolsPackage, MesonPackage): version("2020.03.01", commit="94ede4e6fa1e05e6f080be8dc388240ea027f769", deprecated=True) version("2019.12.28", commit="b4e1877ff96069fd8ed0fdf0e36283a5b4b62240", deprecated=True) version("2019.08.14", commit="6ea44ed3f93ede2d0a48937f288a2d41188a277c", deprecated=True) - version("2018.12.28", commit="8dbf0d543171ffa9885344f32f23cc6f7f6e39bc", deprecated=True) - version("2018.11.05", commit="d0c43e39020e67095b1f1d8bb89b75f22b12aee9", deprecated=True) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated # Options for MPI and hpcprof-mpi. We always support profiling # MPI applications. These options add hpcprof-mpi, the MPI @@ -142,7 +144,7 @@ class Hpctoolkit(AutotoolsPackage, MesonPackage): depends_on("libtool", type="build") with when("@2024.02:"): - depends_on("pkgconf", type="build") + depends_on("pkgconfig", type="build") depends_on("cmake", type="build") boost_libs = ( @@ -150,8 +152,8 @@ class Hpctoolkit(AutotoolsPackage, MesonPackage): " +graph +regex +shared +multithreaded visibility=global" ) - depends_on("binutils +libiberty", type="link", when="@2021:2022.06") - depends_on("binutils +libiberty~nls", type="link", when="@2020.04:2020") + depends_on("binutils@:2.39 +libiberty", type="link", when="@2021:2022.06") + depends_on("binutils@:2.39 +libiberty~nls", type="link", when="@2020.04:2020") depends_on("binutils@:2.33.1 +libiberty~nls", type="link", when="@:2020.03") depends_on("boost" + boost_libs) depends_on("bzip2+shared", type="link") @@ -165,10 +167,10 @@ class Hpctoolkit(AutotoolsPackage, MesonPackage): depends_on("intel-tbb+shared", when="^[virtuals=tbb] intel-tbb") depends_on("libdwarf", when="@:2022.06") depends_on("libiberty+pic", when="@2022.10:") - depends_on("libmonitor+hpctoolkit~dlopen", when="@2021.00:") + depends_on("libmonitor+hpctoolkit~dlopen", when="@2021.00:2024") depends_on("libmonitor+hpctoolkit+dlopen", when="@:2020") - depends_on("libmonitor@2023.02.13:", when="@2023.01:") - depends_on("libmonitor@2021.11.08:", when="@2022.01:") + depends_on("libmonitor@2023.02.13:", when="@2023.01:2024") + depends_on("libmonitor@2021.11.08:", when="@2022.01:2024") depends_on("libunwind@1.4: +xz") depends_on("libunwind +pic libs=static", when="@:2023.08") depends_on("mbedtls+pic", when="@:2022.03") @@ -212,6 +214,12 @@ class Hpctoolkit(AutotoolsPackage, MesonPackage): conflicts("^xz@5.2.7:5.2.8", msg="avoid xz 5.2.7:5.2.8 (broken symbol versions)") conflicts("^intel-xed@2023.08:", when="@:2023.09") + # https://gitlab.com/hpctoolkit/hpctoolkit/-/issues/831 + conflicts( + "^elfutils@0.191:", + msg="avoid elfutils 0.191 (known critical errors in hpcstruct for CUDA binaries)", + ) + conflicts("+cray", when="@2022.10.01", msg="hpcprof-mpi is not available in 2022.10.01") conflicts("+mpi", when="@2022.10.01", msg="hpcprof-mpi is not available in 2022.10.01") @@ -219,6 +227,8 @@ class Hpctoolkit(AutotoolsPackage, MesonPackage): "^hip@5.3:", when="@:2022.12", msg="rocm 5.3 requires hpctoolkit 2023.03.01 or later" ) + conflicts("^hip@6:", when="@:2023", msg="rocm 6.0 requires hpctoolkit 2024.01.1 or later") + # Fix the build for old revs with gcc 10.x and 11.x. patch("gcc10-enum.patch", when="@2020.01.01:2020.08 %gcc@10.0:") patch("511afd95b01d743edc5940c84e0079f462b2c23e.patch", when="@2019.08.01:2021.03 %gcc@11.0:") @@ -228,8 +238,12 @@ class Hpctoolkit(AutotoolsPackage, MesonPackage): depends_on("python@3.4:", type="build", when="@2020.03:2020.08") patch("python3.patch", when="@2020.03:2020.08") + # hsa include path is hsa-rocr-dev-prefix-path/include + patch("correcting-hsa-include-path.patch", when="@2024.01 ^hip@6.0:") + # Fix a bug where make would mistakenly overwrite hpcrun-fmt.h. # https://gitlab.com/hpctoolkit/hpctoolkit/-/merge_requests/751 + @when("@:2022") def patch(self): with working_dir(join_path("src", "lib", "prof-lean")): if os.access("hpcrun-fmt.txt", os.F_OK): diff --git a/var/spack/repos/builtin/packages/hpcviewer/package.py b/var/spack/repos/builtin/packages/hpcviewer/package.py index 7bf6916a52cd53..495c7650839ba6 100644 --- a/var/spack/repos/builtin/packages/hpcviewer/package.py +++ b/var/spack/repos/builtin/packages/hpcviewer/package.py @@ -10,29 +10,6 @@ from spack.package import * -# The viewer and trace viewer tar files and sha256sum depend on the -# version and machine type. Starting with 2019.08, the name of the -# tar file contains the version number. -def viewer_url(ver, mach): - ver2 = ("-" + ver) if ver >= "2019.08" else "" - return ("http://hpctoolkit.org/download/hpcviewer/{0}/hpcviewer{1}-linux.gtk.{2}.tgz").format( - ver, ver2, mach - ) - - -def trace_url(ver, mach): - ver2 = ("-" + ver) if ver >= "2019.08" else "" - return ( - "http://hpctoolkit.org/download/hpcviewer/{0}/hpctraceviewer{1}-linux.gtk.{2}.tgz" - ).format(ver, ver2, mach) - - -def darwin_url(ver, mach): - return ( - "http://hpctoolkit.org/download/hpcviewer/{0}/hpcviewer-{0}-macosx.cocoa.{1}.zip" - ).format(ver, mach) - - class Hpcviewer(Package): """Binary distribution of hpcviewer and integrated hpctraceviewer for the Rice HPCToolkit (Linux x86_64, ppc64le and aarch64, and MacOSX @@ -43,9 +20,11 @@ class Hpcviewer(Package): run hpcrun and hpcviewer on different machines. """ - homepage = "http://hpctoolkit.org" + homepage = "https://hpctoolkit.org" maintainers("mwkrentel") + skip_version_audit = ["platform=windows"] + darwin_sha = { ("2024.02", "aarch64"): "0f2bf2f89b7b9656b1b249efc8b24763f7865e8ddae5b22a3c21cc79fda49ce9", ("2024.02", "x86_64"): "7f61166155f326179e309aa18568b44d98a2219973a323cd4713123b5bf6fd54", @@ -127,27 +106,6 @@ class Hpcviewer(Package): ("2020.02", "x86_64"): "af1f514547a9325aee30eb891b31e38c7ea3f33d2d1978b44f83e7daa3d5de6b", ("2020.02", "ppc64"): "7bb4926202db663aedd5a6830778c5f73f6b08a65d56861824ea95ba83b1f59c", ("2020.02", "ppc64le"): "cfcebb7ba301affd6d21d2afd43c540e6dd4c5bc39b0d20e8bd1e4fed6aa3481", - ("2020.01", "x86_64"): "3cd5a2a382cec1d64c8bd0abaf2b1461dcd4092a4b4074ddbdc1b96d2a0b4220", - ("2020.01", "ppc64"): "814394a5f410033cc1019526c268ef98b5b381e311fcd39ae8b2bde6c6ff017c", - ("2020.01", "ppc64le"): "e830e956b8088c415fb25ef44a8aca16ebcb27bcd34536866612343217e3f9e4", - ("2019.12", "x86_64"): "6ba149c8d23d9913291655602894f7a91f9c838e69ae5682fd7b605467255c2d", - ("2019.12", "ppc64"): "787257272381fac26401e1013952bea94635172503e7abf8063081fe03f08384", - ("2019.12", "ppc64le"): "fd20891fdae6dd5c2313cdd98e53c52023a0cf146a1121d0c889ebedc08a8bb9", - ("2019.09", "x86_64"): "40982a43880fe646b7f9d03ac4911b55f8a4464510eb8c7304ffaf4d4205ecc6", - ("2019.09", "ppc64"): "3972d604bd160c058185b6f8f3f3a63c4031046734b29cc386c24e40831e6798", - ("2019.09", "ppc64le"): "c348f442b7415aadb94ead06bd35e96442a49a9768fd8c972ca707d77d61e0c3", - ("2019.08", "x86_64"): "249aae6a23dca19286ee15909afbeba5e515388f1c1ad87f572454534fccb9f2", - ("2019.08", "ppc64"): "f91b4772c92c05a4a35c88eec094604f3c233c7233adeede97acba38592da379", - ("2019.08", "ppc64le"): "b1bd5c76b37f225a01631193e0a62524bd41a54b3354a658fdfd0f66c444cc28", - ("2019.07", "x86_64"): "e999781d6a7d178cb1db5b549650024fa9b19891e933bac8b0441d24e7bf015c", - ("2019.07", "ppc64"): "057ce0e2d6be5639639f762fb43b116fe31fb855745abaf4ea26bd281cffaab1", - ("2019.07", "ppc64le"): "40d6928e0761568168f3ce34f3ed320916ea60bda830dd74513897ef77386b28", - ("2019.04", "x86_64"): "c524498ef235171e298c8142b7e73b0a1f7c433f9c471fb692d31f0685e53aa4", - ("2019.04", "ppc64"): "dc9daee886ba72c0615db909860ee1aed0979f12c0d113efbe721ddabdf55199", - ("2019.04", "ppc64le"): "dddabccef156996d390653639096ad3e27b7384a5754f42084f50c4a50a9009b", - ("2019.02", "x86_64"): "e24368a3ec27b82736a781971a8371abfe7744b2a4f68b7b41d76f84af306b83", - ("2019.02", "ppc64"): "72c1ef1a5682c3273e900bb248f126428a02dfe728af0c49c7ee8381938d1e18", - ("2019.02", "ppc64le"): "02aaf27bb5b0f72d5b5738289bce60f6ef0ef7327ca96a890892509a09adc946", } trace_sha = { @@ -163,27 +121,6 @@ class Hpcviewer(Package): ("2020.02", "x86_64"): "b7b634e91108aa50a2e8647ac6bac87df775ae38aff078545efaa84735e0a666", ("2020.02", "ppc64"): "a3e845901689e1b32bc6ab2826c6ac6ed352df4839090fa530b20f747e6e0957", ("2020.02", "ppc64le"): "a64a283f61e706d988952a7cede9fac0328b09d2d0b64e4c08acc54e38781c98", - ("2020.01", "x86_64"): "9459177a2445e85d648384e2ccee20524592e91a74d615262f32d0876831cd7c", - ("2020.01", "ppc64"): "02366a2ba30b9b2450d50cf44933288f04fae5bf9868eef7bb2ae1b49d4f454e", - ("2020.01", "ppc64le"): "39970e84e397ed96bc994e7b8db3b7b3aab4e3155fa7ca8e68b9274bb58115f0", - ("2019.12", "x86_64"): "6339b36e655e2c2b07af4cb40946f325acc46da3ec590d36069661e69b046a92", - ("2019.12", "ppc64"): "fe4ee5af22a983fa0ddbfbd97fa6676f07492400536e900188455f21e489c59b", - ("2019.12", "ppc64le"): "2688ea834c546b9e2c6e9d69d271a62dd00f6bc7ff4cb874563ba8d0ae5824e3", - ("2019.09", "x86_64"): "8d7ce0710570bb8cd424d88cc4b5bfe821330f24fef84bbbbb370fa291b60a14", - ("2019.09", "ppc64"): "dfb3fe8283cbaeaa1653e8c8bf68267a3f25886bc452309b10f88a7b1e713ec6", - ("2019.09", "ppc64le"): "c1b6ab4f6c91e3a226e8629de62e718c92318ffd83d03db3c40678d578b99b20", - ("2019.08", "x86_64"): "6cefed6a397298ab31cadd10831f5d5533d3f634a4a76bb93f686e603a42c5ed", - ("2019.08", "ppc64"): "64ca5605c89dd3065cacaeee4a8e2ac14b47953530711ed9e04666c8435e44e8", - ("2019.08", "ppc64le"): "bee03b5cb2de7e8556cf1249f98ece7848c13a0de6b8ba71786c430da68f7bcc", - ("2019.07", "x86_64"): "267052cf742d12bbe900bc03bc7c47c8e1704fbaad0e1a3fc77b73dc506d5a68", - ("2019.07", "ppc64"): "5ae63d8e2f2edf5c3b982d3663311e4d55f9b378f512926b3ebadab27ba72e22", - ("2019.07", "ppc64le"): "c2883714cbafa5252432c52d1d32ab5f34554b33a9bad20dcd2c0632388fbee5", - ("2019.04", "x86_64"): "f5f908c0e52c97a72af1af8519f4b191298fe52bd811dd06a051b68cd7bcce27", - ("2019.04", "ppc64"): "221683c992e4fe2cd9079ad2ebb531d99d04a3cbb3a8860f795b276b1eaeab19", - ("2019.04", "ppc64le"): "fe539c6a165a72bba6ea7bdb34a90d862d427c4d55095c97794d54e6dd9d3075", - ("2019.02", "x86_64"): "5ff11317a638318295821204ffcb1276e9da1684cd5f298410ae2bf78ce88b6b", - ("2019.02", "ppc64"): "95b2a7d848ecb924591c248f5e47c641646ef90a071db48237ddb96c4b71a8fb", - ("2019.02", "ppc64le"): "01a159306e7810efe07157ec823ac6ca7570ec2014c95db599a3f90eee33355c", } system = platform.system().lower() @@ -193,31 +130,38 @@ class Hpcviewer(Package): # Versions for MacOSX / Darwin if system == "darwin": - for key in darwin_sha.keys(): - if key[1] == machine: - version(key[0], url=darwin_url(*key), sha256=darwin_sha[key]) + for (ver, arch), sha in darwin_sha.items(): + if arch == machine: + version( + ver, + url=f"https://gitlab.com/hpctoolkit/hpcviewer/-/releases/{ver}/downloads/hpcviewer-macosx.cocoa.{arch}.zip", + sha256=sha, + # Versions before 2022.01 are dead links + deprecated=(ver < "2022.01"), + ) # Versions for Linux and Cray front-end if system == "linux": - for key in viewer_sha.keys(): - if key[1] == machine: + for (ver, arch), sha in viewer_sha.items(): + if arch == machine: version( - key[0], - url=viewer_url(*key), - sha256=viewer_sha[key], - deprecated=(key[0] <= "2020.99"), + ver, + url=f"https://gitlab.com/hpctoolkit/hpcviewer/-/releases/{ver}/downloads/hpcviewer-linux.gtk.{arch}.tgz", + sha256=sha, + # Versions before 2022.01 are dead links + deprecated=(ver < "2022.01"), ) # Current versions include the viewer and trace viewer in # one tar file. Before 2020.07, the trace viewer was a # separate tar file (resource). - if key in trace_sha: + if (ver, arch) in trace_sha: resource( name="hpctraceviewer", - url=trace_url(*key), - sha256=trace_sha[key], + url=f"https://gitlab.com/hpctoolkit/hpcviewer/-/releases/{ver}/downloads/hpctraceviewer-linux.gtk.{arch}.tgz", + sha256=trace_sha[ver, arch], placement="TRACE", - when="@{0}".format(key[0]), + when=f"@{ver}", ) depends_on("java@11:", type=("build", "run"), when="@2021.0:") @@ -244,11 +188,6 @@ def install(self, spec, prefix): file.write("open " + app_dir + "\n") os.chmod(viewer_file, 0o755) - # Install for Cray front-end is the same as Linux. - @when("platform=cray") - def install(self, spec, prefix): - self.linux_install(spec, prefix) - @when("platform=linux") def install(self, spec, prefix): self.linux_install(spec, prefix) diff --git a/var/spack/repos/builtin/packages/hpddm/package.py b/var/spack/repos/builtin/packages/hpddm/package.py index df75297679ea6b..f34f6496cf2671 100644 --- a/var/spack/repos/builtin/packages/hpddm/package.py +++ b/var/spack/repos/builtin/packages/hpddm/package.py @@ -26,6 +26,10 @@ class Hpddm(Package): version("2.1.3", commit="32025e4ee75a16fa67399d26dd86910c03910dba") version("2.1.2", commit="e58205623814f59bf2aec2e2bab8eafcfbd22466") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("blas") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/hpgmg/package.py b/var/spack/repos/builtin/packages/hpgmg/package.py index 75a79367c9bc42..8045f7297362aa 100644 --- a/var/spack/repos/builtin/packages/hpgmg/package.py +++ b/var/spack/repos/builtin/packages/hpgmg/package.py @@ -32,6 +32,8 @@ class Hpgmg(MakefilePackage): ) version("0.3", sha256="12a65da216fec91daea78594ae4b5a069c8f1a700f1ba21eed9f45a79a68c793") + depends_on("c", type="build") # generated + variant("fe", default=False, description="Build finite element solver") variant( "fv", diff --git a/var/spack/repos/builtin/packages/hping/package.py b/var/spack/repos/builtin/packages/hping/package.py index 187c5630c6bb54..3aa211ce089ac2 100644 --- a/var/spack/repos/builtin/packages/hping/package.py +++ b/var/spack/repos/builtin/packages/hping/package.py @@ -16,6 +16,8 @@ class Hping(AutotoolsPackage): version("master", commit="3547c7691742c6eaa31f8402e0ccbb81387c1b99") + depends_on("c", type="build") # generated + patch("bpf.patch", sha256="99b9f91a308ffca306f69ccdb285e289ee3d280ec47ec7229e3a7669cca512f2") depends_on("libpcap") diff --git a/var/spack/repos/builtin/packages/hpl/package.py b/var/spack/repos/builtin/packages/hpl/package.py index 8865405f21a81e..184fe6c2b7e298 100644 --- a/var/spack/repos/builtin/packages/hpl/package.py +++ b/var/spack/repos/builtin/packages/hpl/package.py @@ -23,6 +23,8 @@ class Hpl(AutotoolsPackage): version("2.3", sha256="32c5c17d22330e6f2337b681aded51637fb6008d3f0eb7c277b163fadd612830") version("2.2", sha256="ac7534163a09e21a5fa763e4e16dfc119bc84043f6e6a807aba666518f8df440") + depends_on("c", type="build") # generated + variant("openmp", default=False, description="Enable OpenMP support") depends_on("mpi@1.1:") @@ -103,27 +105,30 @@ def configure(self, spec, prefix): def configure_args(self): filter_file(r"^libs10=.*", "libs10=%s" % self.spec["blas"].libs.ld_flags, "configure") + cflags, ldflags = ["-O3"], [] if "+openmp" in self.spec: - config = ["CFLAGS=-O3 " + self.compiler.openmp_flag] - else: - config = ["CFLAGS=-O3"] + cflags.append(self.compiler.openmp_flag) if ( self.spec.satisfies("^intel-mkl") or self.spec.satisfies("^intel-oneapi-mkl") or self.spec.satisfies("^intel-parallel-studio+mkl") ): - config.append("LDFLAGS={0}".format(self.spec["blas"].libs.ld_flags)) + ldflags.append(self.spec["blas"].libs.ld_flags) if "%aocc" in self.spec: - amd_ldflags = " " if "%aocc@3:" in self.spec: - amd_ldflags += "-lamdlibm -lm " + ldflags.extend(["-lamdlibm", "-lm"]) if "%aocc@4:" in self.spec: - amd_ldflags += "-lamdalloc " - config.append("LDFLAGS=" + amd_ldflags) + ldflags.append("-lamdalloc") + + if self.spec["blas"].name == "fujitsu-ssl2" and ( + self.spec.satisfies("%fj") or self.spec.satisfies("%clang@17:") + ): + cflags.append("-SSL2BLAMP") + ldflags.append("-SSL2BLAMP") - return config + return ["CFLAGS={0}".format(" ".join(cflags)), "LDFLAGS={0}".format(" ".join(ldflags))] @when("@:2.2") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/hpx-kokkos/package.py b/var/spack/repos/builtin/packages/hpx-kokkos/package.py index 83e13413ed4f54..f2ea7b1d61a53d 100644 --- a/var/spack/repos/builtin/packages/hpx-kokkos/package.py +++ b/var/spack/repos/builtin/packages/hpx-kokkos/package.py @@ -24,6 +24,8 @@ class HpxKokkos(CMakePackage, CudaPackage, ROCmPackage): version("0.2.0", sha256="289b711cea26afe80be002fc521234c9194cd0e8f69863f3b08b654674dbe5d5") version("0.1.0", sha256="24edb817d0969f4aea1b68eab4984c2ea9a58f4760a9b8395e20f85b178f0850") + depends_on("cxx", type="build") + cxxstds = ("14", "17", "20") variant( "cxxstd", diff --git a/var/spack/repos/builtin/packages/hpx/package.py b/var/spack/repos/builtin/packages/hpx/package.py index 5e8e3b45367a76..910d20b6b5e2f3 100644 --- a/var/spack/repos/builtin/packages/hpx/package.py +++ b/var/spack/repos/builtin/packages/hpx/package.py @@ -16,7 +16,7 @@ class Hpx(CMakePackage, CudaPackage, ROCmPackage): homepage = "https://hpx.stellar-group.org/" url = "https://github.com/STEllAR-GROUP/hpx/archive/v0.0.0.tar.gz" git = "https://github.com/STEllAR-GROUP/hpx.git" - maintainers("msimberg", "albestro", "teonnik", "hkaiser") + maintainers("msimberg", "albestro", "teonnik", "hkaiser", "diehlpk") license("BSL-1.0") @@ -24,6 +24,7 @@ class Hpx(CMakePackage, CudaPackage, ROCmPackage): version("master", branch="master") version("stable", tag="stable", commit="103a7b8e3719a0db948d1abde29de0ff91e070be") + version("1.10.0", sha256="5720ed7d2460fa0b57bd8cb74fa4f70593fe8675463897678160340526ec3c19") version("1.9.1", sha256="1adae9d408388a723277290ddb33c699aa9ea72defadf3f12d4acc913a0ff22d") version("1.9.0", sha256="2a8dca78172fbb15eae5a5e9facf26ab021c845f9c09e61b1912e6cf9e72915a") version("1.8.1", sha256="2fc4c10f55e2e6bcdc6f6ff950e26c6d8e218e138fdbd885ee71ccf5c5549054") @@ -40,6 +41,8 @@ class Hpx(CMakePackage, CudaPackage, ROCmPackage): version("1.2.0", sha256="20942314bd90064d9775f63b0e58a8ea146af5260a4c84d0854f9f968077c170") version("1.1.0", sha256="1f28bbe58d8f0da600d60c3a74a644d75ac777b20a018a5c1c6030a470e8a1c9") + depends_on("cxx", type="build") + generator("ninja") map_cxxstd = lambda cxxstd: "2a" if cxxstd == "20" else cxxstd @@ -60,12 +63,12 @@ class Hpx(CMakePackage, CudaPackage, ROCmPackage): variant( "max_cpu_count", - default="64", + default="auto", description="Max number of OS-threads for HPX applications", - values=lambda x: isinstance(x, str) and x.isdigit(), + values=lambda x: isinstance(x, str) and (x.isdigit() or x == "auto"), ) - instrumentation_values = ("apex", "google_perftools", "papi", "valgrind") + instrumentation_values = ("apex", "google_perftools", "papi", "valgrind", "thread_debug") variant( "instrumentation", values=any_combination_of(*instrumentation_values), @@ -224,6 +227,9 @@ def instrumentation_args(self): def cmake_args(self): spec, args = self.spec, [] + format_max_cpu_count = lambda max_cpu_count: ( + "" if max_cpu_count == "auto" else max_cpu_count + ) args += [ self.define("HPX_WITH_CXX{0}".format(spec.variants["cxxstd"].value), True), self.define_from_variant("HPX_WITH_MALLOC", "malloc"), @@ -237,7 +243,10 @@ def cmake_args(self): self.define("HPX_WITH_NETWORKING", "networking=none" not in spec), self.define("HPX_WITH_PARCELPORT_TCP", "networking=tcp" in spec), self.define("HPX_WITH_PARCELPORT_MPI", "networking=mpi" in spec), - self.define_from_variant("HPX_WITH_MAX_CPU_COUNT", "max_cpu_count"), + self.define( + "HPX_WITH_MAX_CPU_COUNT", + format_max_cpu_count(spec.variants["max_cpu_count"].value), + ), self.define_from_variant("HPX_WITH_GENERIC_CONTEXT_COROUTINES", "generic_coroutines"), self.define("BOOST_ROOT", spec["boost"].prefix), self.define("HWLOC_ROOT", spec["hwloc"].prefix), @@ -259,6 +268,12 @@ def cmake_args(self): # Instrumentation args += self.instrumentation_args() + if "instrumentation=thread_debug" in spec: + args += [ + self.define("HPX_WITH_THREAD_DEBUG_INFO", True), + self.define("HPX_WITH_LOGGING", True), + ] + if "instrumentation=apex" in spec: args += [ self.define("APEX_WITH_OTF2", True), diff --git a/var/spack/repos/builtin/packages/hpx5/package.py b/var/spack/repos/builtin/packages/hpx5/package.py index 147101cc2039d3..a0f4cc27c11920 100644 --- a/var/spack/repos/builtin/packages/hpx5/package.py +++ b/var/spack/repos/builtin/packages/hpx5/package.py @@ -29,6 +29,9 @@ class Hpx5(AutotoolsPackage): version("2.1.0", sha256="675826f669eeb3eab40947715af8c8495e2b3d299223372431dc01c1f7d5d616") version("2.0.0", sha256="0278728557b6684aeb86228f44d548ac809302f05a0b9c8b433cdd157629e384") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Don't second-guess what compiler we are using on Cray patch("configure.patch", when="@4.0.0") diff --git a/var/spack/repos/builtin/packages/hsa-rocr-dev/package.py b/var/spack/repos/builtin/packages/hsa-rocr-dev/package.py index ea25289a913731..a0825f64e774b9 100644 --- a/var/spack/repos/builtin/packages/hsa-rocr-dev/package.py +++ b/var/spack/repos/builtin/packages/hsa-rocr-dev/package.py @@ -24,6 +24,9 @@ class HsaRocrDev(CMakePackage): libraries = ["libhsa-runtime64"] version("master", branch="master") + version("6.1.2", sha256="6eb7a02e5f1e5e3499206b9e74c9ccdd644abaafa2609dea0993124637617866") + version("6.1.1", sha256="72841f112f953c16619938273370eb8727ddf6c2e00312856c9fca54db583b99") + version("6.1.0", sha256="50386ebcb7ff24449afa2a10c76a059597464f877225c582ba3e097632a43f9c") version("6.0.2", sha256="e7ff4d7ac35a2dd8aad1cb40b96511a77a9c23fe4d1607902328e53728e05c28") version("6.0.0", sha256="99e8fa1af52d0bf382f28468e1a345af1ff3452c35914a6a7b5eeaf69fc568db") version("5.7.1", sha256="655e9bfef4b0b6ad3f9b89c934dc0a8377273bb0bccbda6c399ac5d5d2c1c04c") @@ -32,37 +35,29 @@ class HsaRocrDev(CMakePackage): version("5.6.0", sha256="30875d440df9d8481ffb24d87755eae20a0efc1114849a72619ea954f1e9206c") version("5.5.1", sha256="53d84ad5ba5086ed4ad67ad892c52c0e4eba8ddfa85c2dd341bf825f4d5fe4ee") version("5.5.0", sha256="8dbc776b56f93ddaa2ca38bf3b88299b8091de7c1b3f2e481064896cf6808e6c") - version("5.4.3", sha256="a600eed848d47a7578c60da7e64eb92f29bbce2ec67932b251eafd4c2974cb67") - version("5.4.0", sha256="476cd18500cc227d01f6b44c00c7adc8574eb8234b6b4daefc219650183fa090") - version("5.3.3", sha256="aca88d90f169f35bd65ce3366b8670c7cdbe3abc0a2056eab805d0192cfd7130") - version("5.3.0", sha256="b51dbedbe73390e0be748b92158839c82d7fa0e514fede60aa7696dc498facf0") with default_args(deprecated=True): - version("5.2.3", sha256="978de85d3455207bb82bef2254a4624e9116b1258a8c164d7a7e21a644eff12f") - version("5.2.1", sha256="448a7409bdc6618332a42b9503122996f26b91768140b710ba99bff8a8c03dd9") - version("5.2.0", sha256="529e49693dd9f6459586dd0a26f14dd77dbdf8c0b45fb54830b294eba7babd27") - version("5.1.3", sha256="479340ec34cdffbbdb1002c85a47d1fccd23e8394631a1f001ef6130be08287d") - version("5.1.0", sha256="a5f7245059c3d28dbc037e1e6fa3f09084e29147096dd61f7ce5560291ab330f") + version("5.4.3", sha256="a600eed848d47a7578c60da7e64eb92f29bbce2ec67932b251eafd4c2974cb67") + version("5.4.0", sha256="476cd18500cc227d01f6b44c00c7adc8574eb8234b6b4daefc219650183fa090") + version("5.3.3", sha256="aca88d90f169f35bd65ce3366b8670c7cdbe3abc0a2056eab805d0192cfd7130") + version("5.3.0", sha256="b51dbedbe73390e0be748b92158839c82d7fa0e514fede60aa7696dc498facf0") + + depends_on("cxx", type="build") # generated variant("shared", default=True, description="Build shared or static library") variant("image", default=True, description="build with or without image support") variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") depends_on("cmake@3:", type="build") - depends_on("pkgconfig", type="build", when="@5.3.0:") + depends_on("pkgconfig", type="build") # Note, technically only necessary when='@3.7: +image', but added to all # to work around https://github.com/spack/spack/issues/23951 depends_on("xxd", when="+image", type="build") depends_on("elf", type="link") depends_on("numactl") - depends_on("pkgconfig", type="build", when="@5.3.0:") + depends_on("pkgconfig") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -75,6 +70,9 @@ class HsaRocrDev(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", ]: depends_on(f"hsakmt-roct@{ver}", when=f"@{ver}") @@ -82,7 +80,19 @@ class HsaRocrDev(CMakePackage): # allow standalone rocm-device-libs (useful for aomp) depends_on(f"rocm-device-libs@{ver}", when=f"@{ver} ^llvm-amdgpu ~rocm-device-libs") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") patch("0002-Remove-explicit-RPATH-again.patch", when="@3.7.0:5.6") @@ -125,7 +135,11 @@ def cmake_args(self): if self.spec.satisfies("@5.6:"): args.append("-DCMAKE_INSTALL_LIBDIR=lib") - if self.spec.satisfies("@6.0:"): + if self.spec.satisfies("@6.0"): args.append(self.define("ROCM_PATCH_VERSION", "60000")) + if self.spec.satisfies("@6.1"): + args.append(self.define("ROCM_PATCH_VERSION", "60100")) + if self.spec.satisfies("@5.7.0:"): + args.append(self.define_from_variant("ADDRESS_SANITIZER", "asan")) return args diff --git a/var/spack/repos/builtin/packages/hsakmt-roct/0001-Remove-compiler-support-libraries-and-libudev-as-req.patch b/var/spack/repos/builtin/packages/hsakmt-roct/0001-Remove-compiler-support-libraries-and-libudev-as-req.patch deleted file mode 100644 index b0a04e3e84278f..00000000000000 --- a/var/spack/repos/builtin/packages/hsakmt-roct/0001-Remove-compiler-support-libraries-and-libudev-as-req.patch +++ /dev/null @@ -1,34 +0,0 @@ -From 423bfb21eee3f75c5a116a88f7903a7dfb9ff89c Mon Sep 17 00:00:00 2001 -From: Harmen Stoppels -Date: Thu, 10 Feb 2022 13:50:55 +0100 -Subject: [PATCH] Remove compiler support libraries and libudev as required - dependencies - ---- - CMakeLists.txt | 10 ---------- - 1 file changed, 10 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 077ab51..0af642e 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -187,16 +187,6 @@ target_link_libraries ( ${HSAKMT_TARGET} - ) - - target_compile_options(${HSAKMT_TARGET} PRIVATE ${DRM_CFLAGS} ${HSAKMT_C_FLAGS}) --if(NOT DISTRO_ID MATCHES "ubuntu") -- find_library(LIBGCC NAMES libgcc_s.so.1 REQUIRED) -- message(STATUS "LIBGCC:" ${LIBGCC}) -- target_link_libraries( ${HSAKMT_TARGET} PRIVATE ${LIBGCC} ) --else() -- find_library(UDEV NAMES libudev.so libudev.a REQUIRED) -- message(STATUS "UDEV:" ${UDEV}) -- find_package(ZLIB REQUIRED) -- target_link_libraries( ${HSAKMT_TARGET} PRIVATE ${ZLIB} ${UDEV} ) --endif() - - ## Define default paths and packages. - if( CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT ) --- -2.25.1 - diff --git a/var/spack/repos/builtin/packages/hsakmt-roct/package.py b/var/spack/repos/builtin/packages/hsakmt-roct/package.py index 2ced193df6c7d0..fe256e862550ae 100644 --- a/var/spack/repos/builtin/packages/hsakmt-roct/package.py +++ b/var/spack/repos/builtin/packages/hsakmt-roct/package.py @@ -16,12 +16,15 @@ class HsakmtRoct(CMakePackage): homepage = "https://github.com/ROCm/ROCT-Thunk-Interface" git = "https://github.com/ROCm/ROCT-Thunk-Interface.git" - url = "https://github.com/ROCm/ROCT-Thunk-Interface/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/ROCT-Thunk-Interface/archive/rocm-6.1.0.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") version("master", branch="master") + version("6.1.2", sha256="097a5b7eb136300667b36bd35bf55e4a283a1ed04e614cf24dddca0a65c86389") + version("6.1.1", sha256="c586d8a04fbd9a7bc0a15e0a6a161a07f88f654402bb11694bd8aebc343c00f0") + version("6.1.0", sha256="1085055068420821f7a7adb816692412b5fb38f89d67b9edb9995198f39e2f31") version("6.0.2", sha256="5354bda9382f80edad834463f2c684289841770a4f7b13f0f40bd8271cc4c71d") version("6.0.0", sha256="9f4e80bd0a714ce45326941b906a62298c62025eff186dc6c48282ce84c787c7") version("5.7.1", sha256="38bc3732886a52ca9cd477ec6fcde3ab17a0ba5dc8e2f7ac34c4de597bd00e8b") @@ -30,35 +33,44 @@ class HsakmtRoct(CMakePackage): version("5.6.0", sha256="cd009c5c09f664f046c428ba9843582ab468f7b88d560747eb949d8d7f8c5567") version("5.5.1", sha256="4ffde3fc1f91f24cdbf09263fd8e012a3995ad10854f4c1d866beab7b9f36bf4") version("5.5.0", sha256="2b11fd8937c2b06cd4ddea2c3699fbf3d1651892c4c5957d38553b993dd9af18") - version("5.4.3", sha256="3799abbe7177fbff3b304e2a363e2b39e8864f8650ae569b2b88b9291f9a710c") - version("5.4.0", sha256="690a78a6e67ae2b3f518dbc4a1e267237d6a342e1063b31eef297f4a04d780f8") - version("5.3.3", sha256="b5350de915997ed48072b37a21c2c44438028255f6cc147c25a196ad383c52e7") - version("5.3.0", sha256="c150be3958fd46e57bfc9db187819ec34b1db8f0cf9b69f8c3f8915001800ab8") with default_args(deprecated=True): - version("5.2.3", sha256="8d313b8fd945a8d7248c00a2de9a2ee896fe77e464430a91b63400a986ec0bf0") - version("5.2.1", sha256="13c4a6748c4ae70f87869f10fda101d67c9dbaecf040687f7f5d9bb8b6d0506c") - version("5.2.0", sha256="3797cb0eafbec3fd3d4a2b53f789eb8cdbab30729f13dbcca0a10bc1bafd2187") - version("5.1.3", sha256="3c66b1aa7451571ce8bee10e601d34b93c9416b9be476610ee5685dbad81034a") - version("5.1.0", sha256="032717e80b1aefed59f11399e575564ee86ee7c125e889f7c79c2afdfab1eb93") + version("5.4.3", sha256="3799abbe7177fbff3b304e2a363e2b39e8864f8650ae569b2b88b9291f9a710c") + version("5.4.0", sha256="690a78a6e67ae2b3f518dbc4a1e267237d6a342e1063b31eef297f4a04d780f8") + version("5.3.3", sha256="b5350de915997ed48072b37a21c2c44438028255f6cc147c25a196ad383c52e7") + version("5.3.0", sha256="c150be3958fd46e57bfc9db187819ec34b1db8f0cf9b69f8c3f8915001800ab8") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated variant("shared", default=True, description="Build shared or static library") variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") - depends_on("pkgconfig", type="build", when="@4.5.0:") + depends_on("pkgconfig", type="build") depends_on("cmake@3:", type="build") depends_on("numactl") - depends_on("libdrm", when="@4.5.0:") + depends_on("libdrm") for ver in ["5.3.0", "5.4.0", "5.4.3"]: depends_on(f"llvm-amdgpu@{ver}", type="test", when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.0", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") depends_on(f"llvm-amdgpu@{ver}", type="test", when=f"@{ver}") # See https://github.com/ROCm/ROCT-Thunk-Interface/issues/72 # and https://github.com/spack/spack/issues/28398 - patch("0001-Remove-compiler-support-libraries-and-libudev-as-req.patch", when="@4.5.0:5.2") patch("0002-Remove-compiler-support-libraries-and-libudev-as-req-5.3.patch", when="@5.3.0:5.4") def cmake_args(self): @@ -77,9 +89,6 @@ def cmake_args(self): @run_after("install") @on_package_attributes(run_tests=True) def check_install(self): - if self.spec.satisfies("@:5.3.0"): - print("Skipping: stand-alone tests") - return test_dir = "tests/kfdtest" with working_dir(test_dir, create=True): cmake_bin = join_path(self.spec["cmake"].prefix.bin, "cmake") diff --git a/var/spack/repos/builtin/packages/hsakmt/package.py b/var/spack/repos/builtin/packages/hsakmt/package.py index 2a88f1fd486404..d26dc9a8495087 100644 --- a/var/spack/repos/builtin/packages/hsakmt/package.py +++ b/var/spack/repos/builtin/packages/hsakmt/package.py @@ -16,3 +16,5 @@ class Hsakmt(AutotoolsPackage, XorgPackage): license("MIT") version("1.0.0", sha256="3d46af85c27091937618f5e92f7446cff3e9e6378888645e6e238806461e5b77") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/hssp/package.py b/var/spack/repos/builtin/packages/hssp/package.py index 151644e4e84706..f32f34a6d88fc9 100644 --- a/var/spack/repos/builtin/packages/hssp/package.py +++ b/var/spack/repos/builtin/packages/hssp/package.py @@ -33,6 +33,8 @@ class Hssp(AutotoolsPackage): version("3.0.2", sha256="76b4275c8cde120509d7920609fca983f2b04249a649d0aa802c69fd09e5f8cf") version("3.0.1", sha256="62a703d15bdfec82fdbd2a4275e1973b6a1ac6ccd4dbec75036f16faacaa9dce") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/hstr/package.py b/var/spack/repos/builtin/packages/hstr/package.py index 8ad7f1c9734e68..28400a7ddd3908 100644 --- a/var/spack/repos/builtin/packages/hstr/package.py +++ b/var/spack/repos/builtin/packages/hstr/package.py @@ -18,6 +18,8 @@ class Hstr(AutotoolsPackage): version("1.22", sha256="384fee04e4c80a1964dcf443131c1da4a20dd474fb48132a51d3de0a946ba996") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/htop/package.py b/var/spack/repos/builtin/packages/htop/package.py index d3d2e9b1cdfd39..23c8a6034ead28 100644 --- a/var/spack/repos/builtin/packages/htop/package.py +++ b/var/spack/repos/builtin/packages/htop/package.py @@ -15,6 +15,7 @@ class Htop(AutotoolsPackage): license("GPL-2.0-or-later") + version("3.3.0", sha256="1e5cc328eee2bd1acff89f860e3179ea24b85df3ac483433f92a29977b14b045") version("3.2.2", sha256="3829c742a835a0426db41bb039d1b976420c21ec65e93b35cd9bfd2d57f44ac8") version("3.2.1", sha256="b5ffac1949a8daaabcffa659c0964360b5008782aae4dfa7702d2323cfb4f438") version("3.2.0", sha256="1a1dd174cc828521fe5fd0e052cff8c30aa50809cf80d3ce3a481c37d476ac54") @@ -32,6 +33,8 @@ class Htop(AutotoolsPackage): url="https://hisham.hm/htop/releases/2.0.2/htop-2.0.2.tar.gz", ) + depends_on("c", type="build") # generated + variant("unicode", default=True, description="Enable Unicode support dependency") variant("hwloc", default=False, description="Enable hwloc support for CPU affinity") variant("debug", default=False, description="Enable asserts and internal sanity checks") diff --git a/var/spack/repos/builtin/packages/htslib/package.py b/var/spack/repos/builtin/packages/htslib/package.py index 3da320625bb495..9e43771b2f62db 100644 --- a/var/spack/repos/builtin/packages/htslib/package.py +++ b/var/spack/repos/builtin/packages/htslib/package.py @@ -16,6 +16,7 @@ class Htslib(AutotoolsPackage): license("MIT AND BSD-3-Clause-Modification") + version("1.20", sha256="e52d95b14da68e0cfd7d27faf56fef2f88c2eaf32a2be51c72e146e3aa928544") version("1.19.1", sha256="222d74d3574fb67b158c6988c980eeaaba8a0656f5e4ffb76b5fa57f035933ec") version("1.19", sha256="8751c40c4fa7d1f23a6864c5b20a73744f8be68239535ae7729c5f7d394d0736") version("1.18", sha256="f1ab53a593a2320a1bfadf4ef915dae784006c5b5c922c8a8174d7530a9af18f") @@ -37,22 +38,30 @@ class Htslib(AutotoolsPackage): version("1.3.1", sha256="49d53a2395b8cef7d1d11270a09de888df8ba06f70fe68282e8235ee04124ae6") version("1.2", sha256="125c01421d5131afb4c3fd2bc9c7da6f4f1cd9ab5fc285c076080b9aca24bffc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "libcurl", default=True, description="Enable libcurl-based support for http/https/etc URLs," - " for versions >= 1.3. This also enables S3 and GCS support.", + " for versions >= 1.3. This also enables S3 and GCS support by default.", ) variant( "libdeflate", default=True, description="use libdeflate for faster crc and deflate algorithms", ) + variant("gcs", default=True, description="enable gcs url support", when="@1.5:+libcurl") + variant("s3", default=True, description="enable s3 url support", when="@1.5:+libcurl") + variant("plugins", default=False, description="enable support for separately compiled plugins") + variant("pic", default=True, description="Compile with PIC support") depends_on("zlib-api") depends_on("bzip2", when="@1.4:") depends_on("xz", when="@1.4:") depends_on("curl", when="@1.3:+libcurl") + depends_on("openssl", when="+s3") depends_on("libdeflate", when="@1.8:+libdeflate") depends_on("m4", when="@1.2") @@ -60,6 +69,8 @@ class Htslib(AutotoolsPackage): depends_on("automake", when="@1.2") depends_on("libtool", when="@1.2") + conflicts("zlib-ng", when="@:1.12") # https://github.com/samtools/htslib/issues/1257 + @property def libs(self): return find_libraries("libhts", root=self.prefix, recursive=True) @@ -73,6 +84,11 @@ def url_for_version(self, version): url = "https://github.com/samtools/htslib/releases/download/{0}/htslib-{0}.tar.bz2" return url.format(version.dotted) + def flag_handler(self, name, flags): + if name == "cflags" and self.spec.satisfies("+pic"): + flags.append(self.compiler.cc_pic_flag) + return (flags, None, None) + def configure_args(self): spec = self.spec args = [] @@ -80,6 +96,11 @@ def configure_args(self): if spec.satisfies("@1.3:"): args.extend(self.enable_or_disable("libcurl")) + if spec.satisfies("@1.5:"): + args.extend(self.enable_or_disable("s3")) + args.extend(self.enable_or_disable("gcs")) + args.extend(self.enable_or_disable("plugins")) + if spec.satisfies("@1.8:"): args.extend(self.enable_or_disable("libdeflate")) diff --git a/var/spack/repos/builtin/packages/http-get/package.py b/var/spack/repos/builtin/packages/http-get/package.py index 380522ab4a18d1..7300665b04130b 100644 --- a/var/spack/repos/builtin/packages/http-get/package.py +++ b/var/spack/repos/builtin/packages/http-get/package.py @@ -20,6 +20,8 @@ class HttpGet(MakefilePackage): "2018-05-23", sha256="f04e9d911fbc0cdb7c4ebe91dae1cc951ea14b657f48309c3952dcc938bb2e0d" ) + depends_on("c", type="build") # generated + def url_for_version(self, version): ver = datetime.datetime.strptime(str(version), "%Y-%m-%d").date() verstr = datetime.datetime.strftime(ver, "%d%b%Y") diff --git a/var/spack/repos/builtin/packages/http-load/package.py b/var/spack/repos/builtin/packages/http-load/package.py index 736c7988a400f8..2c6739a6095ec6 100644 --- a/var/spack/repos/builtin/packages/http-load/package.py +++ b/var/spack/repos/builtin/packages/http-load/package.py @@ -18,6 +18,8 @@ class HttpLoad(MakefilePackage): "2016-03-09", sha256="5a7b00688680e3fca8726dc836fd3f94f403fde831c71d73d9a1537f215b4587" ) + depends_on("c", type="build") # generated + def url_for_version(self, version): ver = datetime.datetime.strptime(str(version), "%Y-%m-%d").date() verstr = datetime.datetime.strftime(ver, "%d%b%Y") diff --git a/var/spack/repos/builtin/packages/http-parser/package.py b/var/spack/repos/builtin/packages/http-parser/package.py index 61af488281cb54..03bb080b6fd867 100644 --- a/var/spack/repos/builtin/packages/http-parser/package.py +++ b/var/spack/repos/builtin/packages/http-parser/package.py @@ -19,5 +19,7 @@ class HttpParser(MakefilePackage): version("2.9.2", sha256="5199500e352584852c95c13423edc5f0cb329297c81dd69c3c8f52a75496da08") version("2.9.1", sha256="33220771208bcacecd970b6de03bebe239374a8e9cf3baeda79b4f3920bede21") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make("install", "DESTDIR=%s" % prefix, "PREFIX=") diff --git a/var/spack/repos/builtin/packages/http-ping/package.py b/var/spack/repos/builtin/packages/http-ping/package.py index 5e403a91b2fab3..765dea676d9503 100644 --- a/var/spack/repos/builtin/packages/http-ping/package.py +++ b/var/spack/repos/builtin/packages/http-ping/package.py @@ -19,6 +19,8 @@ class HttpPing(MakefilePackage): "2016-03-09", sha256="f8b95773aaed09839a44a1927f979a62752d57aace79da3846bfb73e6c9805e9" ) + depends_on("c", type="build") # generated + def url_for_version(self, version): ver = datetime.datetime.strptime(str(version), "%Y-%m-%d").date() verstr = datetime.datetime.strftime(ver, "%d%b%Y") diff --git a/var/spack/repos/builtin/packages/http-post/package.py b/var/spack/repos/builtin/packages/http-post/package.py index 6429398c6ab3ed..a244a44277fe53 100644 --- a/var/spack/repos/builtin/packages/http-post/package.py +++ b/var/spack/repos/builtin/packages/http-post/package.py @@ -20,6 +20,8 @@ class HttpPost(MakefilePackage): "2018-05-18", sha256="6607faa91aea410efb9b86ae0b1b64541b55318831cf6bb3fdee5d68f8adab31" ) + depends_on("c", type="build") # generated + def url_for_version(self, version): ver = datetime.datetime.strptime(str(version), "%Y-%m-%d").date() verstr = datetime.datetime.strftime(ver, "%d%b%Y") diff --git a/var/spack/repos/builtin/packages/httpd/package.py b/var/spack/repos/builtin/packages/httpd/package.py index 435c504b1ad74f..cf4ac9e99ccc55 100644 --- a/var/spack/repos/builtin/packages/httpd/package.py +++ b/var/spack/repos/builtin/packages/httpd/package.py @@ -15,6 +15,7 @@ class Httpd(AutotoolsPackage): license("Apache-2.0") + version("2.4.59", sha256="ec51501ec480284ff52f637258135d333230a7d229c3afa6f6c2f9040e321323") version("2.4.55", sha256="11d6ba19e36c0b93ca62e47e6ffc2d2f2884942694bce0f23f39c71bdc5f69ac") # https://nvd.nist.gov/vuln/detail/CVE-2022-31813 @@ -39,6 +40,8 @@ class Httpd(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") @@ -50,7 +53,7 @@ class Httpd(AutotoolsPackage): def configure_args(self): spec = self.spec config_args = [ - "--with-apr={0}".format(spec["apr"].prefix), - "--with-apr-util={0}".format(spec["apr-util"].prefix), + f"--with-apr={spec['apr'].prefix}", + f"--with-apr-util={spec['apr-util'].prefix}", ] return config_args diff --git a/var/spack/repos/builtin/packages/httperf/package.py b/var/spack/repos/builtin/packages/httperf/package.py index e6a9fc2aa63473..8f4e0b5102cce4 100644 --- a/var/spack/repos/builtin/packages/httperf/package.py +++ b/var/spack/repos/builtin/packages/httperf/package.py @@ -16,6 +16,8 @@ class Httperf(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/hub/package.py b/var/spack/repos/builtin/packages/hub/package.py index 0e636a072e2030..646b1a13c1d328 100644 --- a/var/spack/repos/builtin/packages/hub/package.py +++ b/var/spack/repos/builtin/packages/hub/package.py @@ -40,6 +40,8 @@ class Hub(Package): deprecated=True, ) + depends_on("c", type="build") # generated + extends("go") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/hugo/package.py b/var/spack/repos/builtin/packages/hugo/package.py index 2bb87852b1ebaa..5bb339e8010602 100644 --- a/var/spack/repos/builtin/packages/hugo/package.py +++ b/var/spack/repos/builtin/packages/hugo/package.py @@ -20,6 +20,8 @@ class Hugo(Package): license("Apache-2.0") + version("0.127.0", sha256="549c7ebdf2ee6b3107ea10a9fbd9932a91bb3f30f7e8839245f6d8e318aca88c") + version("0.126.3", sha256="2a1d65b09884e3c57a8705db99487404856c947dd847cf7bb845e0e1825b33ec") version("0.118.2", sha256="915d7dcb44fba949c80858f9c2a55a11256162ba28a9067752f808cfe8faedaa") version("0.112.7", sha256="d706e52c74f0fb00000caf4e95b98e9d62c3536a134d5e26b433b1fa1e2a74aa") version("0.111.3", sha256="b6eeb13d9ed2e5d5c6895bae56480bf0fec24a564ad9d17c90ede14a7b240999") @@ -31,27 +33,11 @@ class Hugo(Package): version("0.107.0", sha256="31d959a3c1633087d338147782d03bdef65323b67ff3efcec7b40241413e270a") version("0.106.0", sha256="9219434beb51466487b9f8518edcbc671027c1998e5a5820d76d517e1dfbd96a") - # https://nvd.nist.gov/vuln/detail/CVE-2020-26284 - version( - "0.74.3", - sha256="9b296fa0396c20956fa6a1f7afadaa78739af62c277b6c0cfae79a91b0fe823f", - deprecated=True, - ) - version( - "0.68.3", - sha256="38e743605e45e3aafd9563feb9e78477e72d79535ce83b56b243ff991d3a2b6e", - deprecated=True, - ) - version( - "0.53", - sha256="48e65a33d3b10527101d13c354538379d9df698e5c38f60f4660386f4232e65c", - deprecated=True, - ) - # Uses go modules. # See https://gohugo.io/getting-started/installing/#fetch-from-github depends_on("go@1.11:", when="@0.48:", type="build") depends_on("go@1.18:", when="@0.106:", type="build") + depends_on("go@1.20:", when="@0.123:", type="build") variant("extended", default=False, description="Enable extended features") diff --git a/var/spack/repos/builtin/packages/hunspell/package.py b/var/spack/repos/builtin/packages/hunspell/package.py index 5b471af7a323da..5916ea1dc1a5dc 100644 --- a/var/spack/repos/builtin/packages/hunspell/package.py +++ b/var/spack/repos/builtin/packages/hunspell/package.py @@ -18,6 +18,8 @@ class Hunspell(AutotoolsPackage): version("1.7.0", sha256="bb27b86eb910a8285407cf3ca33b62643a02798cf2eef468c0a74f6c3ee6bc8a") version("1.6.0", sha256="512e7d2ee69dad0b35ca011076405e56e0f10963a02d4859dbcc4faf53ca68e2") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/hw-probe/package.py b/var/spack/repos/builtin/packages/hw-probe/package.py index bbbff9af15c1b2..5a740bedc94103 100644 --- a/var/spack/repos/builtin/packages/hw-probe/package.py +++ b/var/spack/repos/builtin/packages/hw-probe/package.py @@ -14,9 +14,10 @@ class HwProbe(MakefilePackage): license("LGPL-2.1-or-later OR BSD-4-Clause") + version("1.6", sha256="de048be6aef357d3142c9e2327d6f79d205a42aa3396ad381ed319115d1c9a22") version("1.5", sha256="8bb7d6ff272c1412e26fcfd86e9df5c3e34e1584552404b930c281b8498b25ea") version("1.4", sha256="90f3ea83bf641348b209e4a2a910f65d836ae7828c0be0f660236ea413bc46bb") version("1.3", sha256="820ada4f16cb827e0990eb918e75423845fef54a863fdd88aa5bd23127354229") def install(self, spec, prefix): - make("install", "prefix={0}".format(prefix)) + make("install", f"prefix={prefix}") diff --git a/var/spack/repos/builtin/packages/hwloc/package.py b/var/spack/repos/builtin/packages/hwloc/package.py index 94a146fc90126e..4643d86ec6d648 100644 --- a/var/spack/repos/builtin/packages/hwloc/package.py +++ b/var/spack/repos/builtin/packages/hwloc/package.py @@ -2,6 +2,7 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) + import re import sys @@ -29,11 +30,19 @@ class Hwloc(AutotoolsPackage, CudaPackage, ROCmPackage): git = "https://github.com/open-mpi/hwloc.git" maintainers("bgoglin") - executables = ["^hwloc-bind$"] license("BSD-3-Clause") + executables = ["^hwloc-bind$"] + version("master", branch="master") + version("2.10.0", sha256="c7fd8a1404a9719c76aadc642864b9f77aed1dc1fc8882d6af861a9260ba240d") + version( + "2.9.3", + sha256="5985db3a30bbe51234c2cd26ebe4ae9b4c3352ab788b1a464c40c0483bf4de59", + preferred=True, + ) + version("2.9.2", sha256="ffb554d5735e0e0a19d1fd4b2b86e771d3b58b2d97f257eedacae67ade5054b3") version("2.9.1", sha256="a440e2299f7451dc10a57ddbfa3f116c2a6c4be1bb97c663edd3b9c7b3b3b4cf") version("2.9.0", sha256="9d7d3450e0a5fea4cb80ca07dc8db939abb7ab62e2a7bb27f9376447658738ec") version("2.8.0", sha256="20b2bd4df436827d8e50f7afeafb6f967259f2fb374ce7330244f8d0ed2dde6f") @@ -66,10 +75,13 @@ class Hwloc(AutotoolsPackage, CudaPackage, ROCmPackage): version("1.11.1", sha256="b41f877d79b6026640943d57ef25311299378450f2995d507a5e633da711be61") version("1.9", sha256="9fb572daef35a1c8608d1a6232a4a9f56846bab2854c50562dfb9a7be294f4e8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("nvml", default=False, description="Support NVML device discovery") variant("gl", default=False, description="Support GL device discovery") variant("libxml2", default=True, description="Build with libxml2") - variant("libudev", default=False, description="Build with libudev") + variant("libudev", default=False, when="@1.11.0:", description="Build with libudev") variant( "pci", default=(sys.platform != "darwin"), @@ -85,19 +97,15 @@ class Hwloc(AutotoolsPackage, CudaPackage, ROCmPackage): variant( "cairo", default=False, description="Enable the Cairo back-end of hwloc's lstopo command" ) - variant("netloc", default=False, description="Enable netloc [requires MPI]") + variant( + "netloc", default=False, when="@2.0.0:2.9.3", description="Enable netloc [requires MPI]" + ) variant("opencl", default=False, description="Support an OpenCL library at run time") variant("rocm", default=False, description="Support ROCm devices") variant( "oneapi-level-zero", default=False, description="Support Intel OneAPI Level Zero devices" ) - # netloc isn't available until version 2.0.0 - conflicts("+netloc", when="@:1") - - # libudev isn't available until version 1.11.0 - conflicts("+libudev", when="@:1.10") - depends_on("pkgconfig", type="build") depends_on("m4", type="build", when="@master") depends_on("autoconf", type="build", when="@master") diff --git a/var/spack/repos/builtin/packages/hybpiper/package.py b/var/spack/repos/builtin/packages/hybpiper/package.py index db890c6f73b4b0..d1b6e1a96b9bde 100644 --- a/var/spack/repos/builtin/packages/hybpiper/package.py +++ b/var/spack/repos/builtin/packages/hybpiper/package.py @@ -7,7 +7,7 @@ from spack.package import * -class Hybpiper(Package): +class Hybpiper(PythonPackage, Package): """HybPiper was designed for targeted sequence capture, in which DNA sequencing libraries are enriched for gene regions of interest, especially for phylogenetics. HybPiper is a suite of Python scripts @@ -17,24 +17,51 @@ class Hybpiper(Package): homepage = "https://github.com/mossmatters/HybPiper" url = "https://github.com/mossmatters/HybPiper/archive/v1.2.0.tar.gz" git = "https://github.com/mossmatters/HybPiper/HybPiper.git" + maintainers("snehring") license("GPL-3.0-or-later") + version("2.1.8", sha256="ff358a560d6dbbec4fdac67457451cb4e6ca21b8661044c43902aa013d805e47") version("1.3.1", sha256="7ca07a9390d1ca52c72721774fa220546f18d3fa3b58500f68f3b2d89dbc0ecf") version("1.2.0", sha256="34c7b324e9bcacb6ccfe87dc50615d6f93866433b61a59291707efa858b6df57") + build_system( + conditional("python_pip", when="@2.1:"), + conditional("generic", when="@:1.3.1"), + default="python_pip", + ) + depends_on("python@2.7:", type=("build", "run")) + depends_on("python@3.9:", type=("build", "run"), when="@2.1:") + depends_on("py-biopython", type=("build", "run")) + depends_on("py-biopython@1.80:", type=("build", "run"), when="@2.1:") + depends_on("py-matplotlib", type=("build", "run"), when="@2.1:") + depends_on("py-pandas", type=("build", "run"), when="@2.1:") + depends_on("py-pebble", type=("build", "run"), when="@2.1:") + depends_on("py-progressbar2", type=("build", "run"), when="@2.1:") + depends_on("py-psutil", type=("build", "run"), when="@2.1:") + depends_on("py-scipy", type=("build", "run"), when="@2.1:") + depends_on("py-seaborn", type=("build", "run"), when="@2.1:") + depends_on("exonerate") + depends_on("exonerate@2.4:", when="@2.1:") + depends_on("bbmap", when="@2.1:") depends_on("blast-plus") - depends_on("spades") - depends_on("parallel") + depends_on("blast-plus@2.9.0:", when="@2.1:") depends_on("bwa") + depends_on("diamond", when="@2.1:") + depends_on("mafft", when="@2.1:") + depends_on("parallel") depends_on("samtools") + depends_on("samtools@1.14", when="@2.1:") + depends_on("spades") + depends_on("spades@3.15.4:", when="@2.1:") def setup_run_environment(self, env): env.set("HYBPIPER_HOME", self.prefix) + @when("@:1.3.1") def install(self, spec, prefix): mkdirp(prefix.bin) install("*.py", prefix.bin) diff --git a/var/spack/repos/builtin/packages/hybrid-lambda/package.py b/var/spack/repos/builtin/packages/hybrid-lambda/package.py index dcd5b6893b8bcb..4b31318b1fe477 100644 --- a/var/spack/repos/builtin/packages/hybrid-lambda/package.py +++ b/var/spack/repos/builtin/packages/hybrid-lambda/package.py @@ -26,6 +26,8 @@ class HybridLambda(AutotoolsPackage): version("develop", submodules=True) + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/hybridsim/package.py b/var/spack/repos/builtin/packages/hybridsim/package.py index 3d1d0a8e020def..c1ed72491bccfa 100644 --- a/var/spack/repos/builtin/packages/hybridsim/package.py +++ b/var/spack/repos/builtin/packages/hybridsim/package.py @@ -21,6 +21,9 @@ class Hybridsim(MakefilePackage): version("2.0.1", sha256="57b82ac929acd36de84525e4d61358f1ab6532f5b635ca3f560e563479921937") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("dramsim2") depends_on("nvdimmsim") patch("makefile.patch", when="@2.0.1") diff --git a/var/spack/repos/builtin/packages/hydra/package.py b/var/spack/repos/builtin/packages/hydra/package.py index e02c54a110ba05..6df93d1f7ea671 100644 --- a/var/spack/repos/builtin/packages/hydra/package.py +++ b/var/spack/repos/builtin/packages/hydra/package.py @@ -19,6 +19,9 @@ class Hydra(AutotoolsPackage): license("AGPL-3.0-or-later") + version("4.2.1", sha256="eb0f33f702aaf1ba54a4892a67b344cd815e0c51d1767327a675824490ab4b51") version("4.2.0", sha256="d7159353d9d0576effba632668a3e6defde2067530ac5db4bae0a85a23dfda5a") version("4.1.1", sha256="d4b915ccab426cd8368bbb2ee9d933fe07bea01493901fb56880b338a7f0b97e") version("3.2", sha256="f7a67ec91a773d95cbbd479a80e926d44bee1ff9fc70a8d1df075ea53ea33889") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/hydrogen/package.py b/var/spack/repos/builtin/packages/hydrogen/package.py index 2847431ef9df4b..582204c140b825 100644 --- a/var/spack/repos/builtin/packages/hydrogen/package.py +++ b/var/spack/repos/builtin/packages/hydrogen/package.py @@ -31,6 +31,9 @@ class Hydrogen(CachedCMakePackage, CudaPackage, ROCmPackage): version("1.5.3", sha256="faefbe738bd364d0e26ce9ad079a11c93a18c6f075719a365fd4fa5f1f7a989a") version("1.5.2", sha256="a902cad3962471216cfa278ba0561c18751d415cd4d6b2417c02a43b0ab2ea33") version("1.5.1", sha256="447da564278f98366906d561d9c8bc4d31678c56d761679c2ff3e59ee7a2895c") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated # Older versions are no longer supported. variant("shared", default=True, description="Enables the build of shared libraries.") diff --git a/var/spack/repos/builtin/packages/hyperscan/package.py b/var/spack/repos/builtin/packages/hyperscan/package.py index 622601384f0ad9..6c7ae9306903a7 100644 --- a/var/spack/repos/builtin/packages/hyperscan/package.py +++ b/var/spack/repos/builtin/packages/hyperscan/package.py @@ -35,6 +35,9 @@ class Hyperscan(CMakePackage): if pkg: version(ver, sha256=pkg[0], url=pkg[1]) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost+exception+serialization+random+graph+container") depends_on("pcre") depends_on("ragel", type="build") diff --git a/var/spack/repos/builtin/packages/hyphen/package.py b/var/spack/repos/builtin/packages/hyphen/package.py index 607f4e5beacd37..d1f5b97a86f29d 100644 --- a/var/spack/repos/builtin/packages/hyphen/package.py +++ b/var/spack/repos/builtin/packages/hyphen/package.py @@ -16,6 +16,8 @@ class Hyphen(AutotoolsPackage): version("master", branch="master") version("2.8.8", sha256="304636d4eccd81a14b6914d07b84c79ebb815288c76fe027b9ebff6ff24d5705") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/hyphy/package.py b/var/spack/repos/builtin/packages/hyphy/package.py index c63e67b50f3ed5..a6e2f74ac3ee2f 100644 --- a/var/spack/repos/builtin/packages/hyphy/package.py +++ b/var/spack/repos/builtin/packages/hyphy/package.py @@ -15,6 +15,9 @@ class Hyphy(CMakePackage): version("2.5.51hf", sha256="403a5d07a4e7e67d3d8136fa83649713ad28223a2519e5fba3aa82697a03375f") version("2.3.14", sha256="9e6c817cb649986e3fe944bcaf88be3533e7e62968b9a486c719e951e5ed1cf6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("openmpi", type="build", when="@2.4:") depends_on("cmake@3.12:", type="build", when="@2.4:") depends_on("cmake@3.0:", type="build", when="@:2.3") diff --git a/var/spack/repos/builtin/packages/hypre-cmake/package.py b/var/spack/repos/builtin/packages/hypre-cmake/package.py index 8d6ad9bed8d5cf..c65fa30fc2785f 100644 --- a/var/spack/repos/builtin/packages/hypre-cmake/package.py +++ b/var/spack/repos/builtin/packages/hypre-cmake/package.py @@ -26,6 +26,10 @@ class HypreCmake(CMakePackage, CudaPackage): version("develop", branch="master") version("2.22.0", sha256="2c786eb5d3e722d8d7b40254f138bef4565b2d4724041e56a8fa073bda5cfbb5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "shared", default=(sys.platform != "darwin"), diff --git a/var/spack/repos/builtin/packages/hypre/hypre-precision-fix.patch b/var/spack/repos/builtin/packages/hypre/hypre-precision-fix.patch new file mode 100644 index 00000000000000..d40b705820b5f0 --- /dev/null +++ b/var/spack/repos/builtin/packages/hypre/hypre-precision-fix.patch @@ -0,0 +1,27 @@ +diff --git a/src/distributed_ls/ParaSails/ConjGrad.c b/src/distributed_ls/ParaSails/ConjGrad.c +index 0ef71b36f..7abbc38aa 100644 +--- a/src/distributed_ls/ParaSails/ConjGrad.c ++++ b/src/distributed_ls/ParaSails/ConjGrad.c +@@ -33,19 +33,19 @@ static HYPRE_Real InnerProd(HYPRE_Int n, HYPRE_Real *x, HYPRE_Real *y, MPI_Comm + static void CopyVector(HYPRE_Int n, HYPRE_Real *x, HYPRE_Real *y) + { + HYPRE_Int one = 1; +- hypre_F90_NAME_BLAS(dcopy, DCOPY)(&n, x, &one, y, &one); ++ hypre_dcopy(&n, x, &one, y, &one); + } + + static void ScaleVector(HYPRE_Int n, HYPRE_Real alpha, HYPRE_Real *x) + { + HYPRE_Int one = 1; +- hypre_F90_NAME_BLAS(dscal, DSCAL)(&n, &alpha, x, &one); ++ hypre_dscal(&n, &alpha, x, &one); + } + + static void Axpy(HYPRE_Int n, HYPRE_Real alpha, HYPRE_Real *x, HYPRE_Real *y) + { + HYPRE_Int one = 1; +- hypre_F90_NAME_BLAS(daxpy, DAXPY)(&n, &alpha, x, &one, y, &one); ++ hypre_daxpy(&n, &alpha, x, &one, y, &one); + } + + diff --git a/var/spack/repos/builtin/packages/hypre/package.py b/var/spack/repos/builtin/packages/hypre/package.py index e0e28f374b1650..86ff57b274b50b 100644 --- a/var/spack/repos/builtin/packages/hypre/package.py +++ b/var/spack/repos/builtin/packages/hypre/package.py @@ -55,6 +55,10 @@ class Hypre(AutotoolsPackage, CudaPackage, ROCmPackage): version("2.10.1", sha256="a4a9df645ebdc11e86221b794b276d1e17974887ead161d5050aaf0b43bb183a") version("2.10.0b", sha256="b55dbdc692afe5a00490d1ea1c38dd908dae244f7bdd7faaf711680059824c11") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Versions 2.13.0 and later can be patched to build shared # libraries on Darwin; the patch for this capability does not # apply to version 2.12.1 and earlier due to changes in the build system @@ -72,6 +76,7 @@ class Hypre(AutotoolsPackage, CudaPackage, ROCmPackage): variant("int64", default=False, description="Use 64bit integers") variant("mixedint", default=False, description="Use 64bit integers while reducing memory use") variant("complex", default=False, description="Use complex values") + variant("gpu-aware-mpi", default=False, description="Use gpu-aware mpi") variant("mpi", default=True, description="Enable MPI support") variant("openmp", default=False, description="Enable OpenMP support") variant("debug", default=False, description="Build debug instead of optimized version") @@ -82,6 +87,16 @@ class Hypre(AutotoolsPackage, CudaPackage, ROCmPackage): variant("sycl", default=False, description="Enable SYCL support") variant("magma", default=False, description="Enable MAGMA interface") variant("caliper", default=False, description="Enable Caliper support") + variant("rocblas", default=False, description="Enable rocBLAS") + variant("cublas", default=False, description="Enable cuBLAS") + variant( + "precision", + default="double", + values=("single", "double", "longdouble"), + multi=False, + description="Floating point precision", + when="@2.12.1:", + ) # Patch to add gptune hookup codes patch("ij_gptune.patch", when="+gptune@2.19.0") @@ -97,6 +112,10 @@ class Hypre(AutotoolsPackage, CudaPackage, ROCmPackage): patch("hypre21800-compat.patch", when="@2.18.0") # Patch to get config flags right patch("detect-compiler.patch", when="@2.15.0:2.20.0") + # The following patch may not work for all versions, so apply it only when + # it is needed: + patch("hypre-precision-fix.patch", when="precision=single") + patch("hypre-precision-fix.patch", when="precision=longdouble") @when("@2.26.0") def patch(self): # fix sequential compilation in 'src/seq_mv' @@ -113,6 +132,8 @@ def patch(self): # fix sequential compilation in 'src/seq_mv' depends_on("rocprim", when="+rocm") depends_on("hipblas", when="+rocm +superlu-dist") depends_on("umpire", when="+umpire") + depends_on("umpire+rocm", when="+umpire+rocm") + depends_on("umpire+cuda", when="+umpire+cuda") depends_on("caliper", when="+caliper") gpu_pkgs = ["magma", "umpire"] @@ -165,6 +186,9 @@ def patch(self): # fix sequential compilation in 'src/seq_mv' # Option added in v2.29.0 conflicts("+magma", when="@:2.28") + conflicts("+cublas", when="~cuda", msg="cuBLAS requires CUDA to be enabled") + conflicts("+rocblas", when="~rocm", msg="rocBLAS requires ROCm to be enabled") + configure_directory = "src" def url_for_version(self, version): @@ -212,6 +236,11 @@ def configure_args(self): configure_args.extend(self.enable_or_disable("complex")) + if spec.satisfies("precision=single"): + configure_args.append("--enable-single") + elif spec.satisfies("precision=longdouble"): + configure_args.append("--enable-longdouble") + if spec.satisfies("+shared"): configure_args.append("--enable-shared") @@ -256,6 +285,8 @@ def configure_args(self): configure_args.append("--with-cuda-home={0}".format(spec["cuda"].prefix)) else: configure_args.append("--enable-cub") + if spec.satisfies("+cublas"): + configure_args.append("--enable-cublas") else: configure_args.extend(["--without-cuda", "--disable-curand", "--disable-cusparse"]) if spec.satisfies("@:2.20.99"): @@ -281,16 +312,17 @@ def configure_args(self): rocm_arch_sorted = list(sorted(rocm_arch_vals, reverse=True)) rocm_arch = rocm_arch_sorted[0] configure_args.append("--with-gpu-arch={0}".format(rocm_arch)) + if spec.satisfies("+rocblas"): + configure_args.append("--enable-rocblas") else: configure_args.extend(["--without-hip", "--disable-rocrand", "--disable-rocsparse"]) if spec.satisfies("+sycl"): configure_args.append("--with-sycl") - sycl_compatible_compilers = ["dpcpp", "icpx"] + sycl_compatible_compilers = ["icpx"] if not (os.path.basename(self.compiler.cxx) in sycl_compatible_compilers): raise InstallError( - "Hypre's SYCL GPU Backend requires DPC++ (dpcpp)" - + " or the oneAPI CXX (icpx) compiler." + "Hypre's SYCL GPU Backend requires the oneAPI CXX (icpx) compiler." ) if spec.satisfies("+unified-memory"): @@ -301,6 +333,9 @@ def configure_args(self): configure_args.append("--with-magma-lib=%s" % spec["magma"].libs) configure_args.append("--with-magma") + if "+gpu-aware-mpi" in spec: + configure_args.append("--enable-gpu-aware-mpi") + configure_args.extend(self.enable_or_disable("fortran")) return configure_args diff --git a/var/spack/repos/builtin/packages/hztool/package.py b/var/spack/repos/builtin/packages/hztool/package.py index 60e2a60f3e645f..39276be305ac07 100644 --- a/var/spack/repos/builtin/packages/hztool/package.py +++ b/var/spack/repos/builtin/packages/hztool/package.py @@ -27,6 +27,8 @@ class Hztool(AutotoolsPackage): version("4.1", sha256="a24b5d483d1dacaa991958956e838601a426133c74885b3aa2fc27c98b42d22a") version("4.0", sha256="e6f6955159da46156bf9182f61754a59dd14e407d40c2448e3f821d55bf963a0") + depends_on("fortran", type="build") # generated + def patch(self): filter_file("-fno-automatic", "-fno-automatic -fallow-argument-mismatch", "configure.ac") diff --git a/var/spack/repos/builtin/packages/i3/package.py b/var/spack/repos/builtin/packages/i3/package.py index 53d0ad53eb47af..2224ad4a8f272a 100644 --- a/var/spack/repos/builtin/packages/i3/package.py +++ b/var/spack/repos/builtin/packages/i3/package.py @@ -19,6 +19,8 @@ class I3(AutotoolsPackage): version("4.14.1", sha256="28d8102d656f17445a6e1523b12c1a730cc3925a520add1f75b56b9c842932f9") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/ibm-databroker/package.py b/var/spack/repos/builtin/packages/ibm-databroker/package.py index 745240354b00ee..422a9edf9a205a 100644 --- a/var/spack/repos/builtin/packages/ibm-databroker/package.py +++ b/var/spack/repos/builtin/packages/ibm-databroker/package.py @@ -28,6 +28,9 @@ class IbmDatabroker(CMakePackage, PythonExtension): version("0.6.1", sha256="2c7d6c6a269d4ae97aad4d770533e742f367da84758130c283733f25df83e535") version("0.6.0", sha256="5856209d965c923548ebb69119344f1fc596d4c0631121b230448cc91bac4290") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("python", default=False, description="Build Python bindings") depends_on("cmake@2.8:", type="build") diff --git a/var/spack/repos/builtin/packages/ibm-java/package.py b/var/spack/repos/builtin/packages/ibm-java/package.py index 97d63d65c8a8d0..376233effde382 100644 --- a/var/spack/repos/builtin/packages/ibm-java/package.py +++ b/var/spack/repos/builtin/packages/ibm-java/package.py @@ -6,6 +6,8 @@ import os import platform +from llnl.util.symlink import readlink + from spack.package import * @@ -94,7 +96,7 @@ def install(self, spec, prefix): # The archive.bin file is quite fussy and doesn't work as a # symlink. if os.path.islink(archive): - targ = os.readlink(archive) + targ = readlink(archive) os.unlink(archive) copy(targ, archive) diff --git a/var/spack/repos/builtin/packages/ibmisc/package.py b/var/spack/repos/builtin/packages/ibmisc/package.py index bb21460e04c43f..7a4b3ec9e01aa6 100644 --- a/var/spack/repos/builtin/packages/ibmisc/package.py +++ b/var/spack/repos/builtin/packages/ibmisc/package.py @@ -19,6 +19,9 @@ class Ibmisc(CMakePackage): version("0.1.0", sha256="38481a8680aad4b40eca6723b2898b344cf0ef891ebc3581f5e99fbe420fa0d8") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("everytrace", default=False, description="Report errors through Everytrace") variant("proj", default=True, description="Compile utilities for PROJ.4 library") variant("blitz", default=True, description="Compile utilities for Blitz library") diff --git a/var/spack/repos/builtin/packages/icarus/package.py b/var/spack/repos/builtin/packages/icarus/package.py index b652f7a6dabbee..1cc72168e1aedc 100644 --- a/var/spack/repos/builtin/packages/icarus/package.py +++ b/var/spack/repos/builtin/packages/icarus/package.py @@ -22,6 +22,9 @@ class Icarus(AutotoolsPackage): version("11_0", sha256="6327fb900e66b46803d928b7ca439409a0dc32731d82143b20387be0833f1c95") version("10_3", commit="453c5465895eaca4a792d18b75e9ec14db6ea50e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("bison", type="build") depends_on("flex", type="build") diff --git a/var/spack/repos/builtin/packages/iceauth/package.py b/var/spack/repos/builtin/packages/iceauth/package.py index 051e9527eb5495..67ebf0f1d3c566 100644 --- a/var/spack/repos/builtin/packages/iceauth/package.py +++ b/var/spack/repos/builtin/packages/iceauth/package.py @@ -16,9 +16,12 @@ class Iceauth(AutotoolsPackage, XorgPackage): license("MIT") + version("1.0.10", sha256="f17f373c6e7bfef9cfa4c688f165dfebec7642ad7c6304c5bb3c9bc2bfcde747") version("1.0.9", sha256="5ca274cf210453e7d7cf5c827a2fbc92149df83824f99a27cde17e1f20324dc6") version("1.0.7", sha256="6c9706cce276609876e768759ed4ee3b447cd17af4a61f9b5a374c7dda9696d8") + depends_on("c", type="build") # generated + depends_on("libice") depends_on("xproto@7.0.22:") diff --git a/var/spack/repos/builtin/packages/icedtea/package.py b/var/spack/repos/builtin/packages/icedtea/package.py index b1dfc2dd166a12..d98e6c59d53696 100644 --- a/var/spack/repos/builtin/packages/icedtea/package.py +++ b/var/spack/repos/builtin/packages/icedtea/package.py @@ -27,6 +27,9 @@ class Icedtea(AutotoolsPackage): version("3.5.0", sha256="2c92e18fa70edaf73517fcf91bc2a7cc2ec2aa8ffdf22bb974fa6f9bc3065f30") version("3.4.0", sha256="2b606bbbf4ca5bcf2c8e811ea9060da30744860f3d63e1b3149fb5550a90b92b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("X", default=False, description="Build with GUI support.") variant( "shenandoah", @@ -37,7 +40,7 @@ class Icedtea(AutotoolsPackage): depends_on("pkgconfig", type="build") depends_on("gmake", type="build") depends_on("cups") - depends_on("jdk", type="build") + depends_on("java", type="build") # X11 deps required for building even when headless depends_on("libx11", when="~X", type="build") depends_on("xproto", when="~X", type="build") diff --git a/var/spack/repos/builtin/packages/icet/package.py b/var/spack/repos/builtin/packages/icet/package.py index 72efff0787738c..6d6b145fc31936 100644 --- a/var/spack/repos/builtin/packages/icet/package.py +++ b/var/spack/repos/builtin/packages/icet/package.py @@ -17,6 +17,8 @@ class Icet(CMakePackage): version("develop", branch="master") version("2.1.1", sha256="04cc5b7aa5b3ec95b255febdcfc2312e553ce3db5ca305526803d5737561ec32") + depends_on("c", type="build") # generated + variant("opengl", default=False, description="Use opengl") variant("shared", default=True, description="Enable shared library") diff --git a/var/spack/repos/builtin/packages/ico/package.py b/var/spack/repos/builtin/packages/ico/package.py index 4afb834fadd619..00d8782755e977 100644 --- a/var/spack/repos/builtin/packages/ico/package.py +++ b/var/spack/repos/builtin/packages/ico/package.py @@ -18,6 +18,8 @@ class Ico(AutotoolsPackage, XorgPackage): version("1.0.6", sha256="dc59589044d71e3ef4dacf5a62a7b0f69b543386d2a12fb8b5558caee5b1e22f") version("1.0.4", sha256="eb8609c3b43dc2e575272f2702590525fe13229e022c4aff8b9a0cc2a3f3205d") + depends_on("c", type="build") # generated + depends_on("libx11@0.99.1:") depends_on("xproto@7.0.22:") diff --git a/var/spack/repos/builtin/packages/icon/package.py b/var/spack/repos/builtin/packages/icon/package.py index ec5a832935b551..a1ab0d0745c13c 100644 --- a/var/spack/repos/builtin/packages/icon/package.py +++ b/var/spack/repos/builtin/packages/icon/package.py @@ -20,8 +20,13 @@ class Icon(AutotoolsPackage): license("BSD-3-Clause", checked_by="skosukhin") + version("2024.01-1", sha256="3e57608b7e1e3cf2f4cb318cfe2fdb39678bd53ca093955d99570bd6d7544184") version("2024.01", sha256="d9408fdd6a9ebf5990298e9a09c826e8c15b1e79b45be228f7a5670a3091a613") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Model Features: variant("atmo", default=True, description="Enable the atmosphere component") variant("les", default=True, description="Enable the Large-Eddy Simulation component") @@ -204,7 +209,6 @@ def configure_args(self): args.append("--disable-gpu") if self.compiler.name == "gcc": - flags["CFLAGS"].append("-g") flags["ICON_CFLAGS"].append("-O3") flags["ICON_BUNDLED_CFLAGS"].append("-O2") @@ -217,7 +221,6 @@ def configure_args(self): ) elif self.compiler.name in ["intel", "oneapi"]: - args.append("--enable-intel-consistency") flags["CFLAGS"].extend(["-g", "-ftz", "-fma", "-ip", "-qno-opt-dynamic-align"]) @@ -254,7 +257,6 @@ def configure_args(self): flags["ICON_ECRAD_FCFLAGS"].extend(["-qno-opt-dynamic-align", "-no-fma", "-fpe0"]) elif self.compiler.name == "nvhpc": - flags["CFLAGS"].extend(["-g", "-O2"]) flags["FCFLAGS"].extend( ["-g", "-O2", "-Mrecursive", "-Mallocatable=03", "-Mstack_arrays"] diff --git a/var/spack/repos/builtin/packages/icu4c/package.py b/var/spack/repos/builtin/packages/icu4c/package.py index fc5dbb21011ba2..3dddb270105619 100644 --- a/var/spack/repos/builtin/packages/icu4c/package.py +++ b/var/spack/repos/builtin/packages/icu4c/package.py @@ -16,6 +16,7 @@ class Icu4c(AutotoolsPackage): license("Unicode-TOU") + version("74.2", sha256="68db082212a96d6f53e35d60f47d38b962e9f9d207a74cfac78029ae8ff5e08c") version("67.1", sha256="94a80cd6f251a53bd2a997f6f1b5ac6653fe791dfab66e1eb0227740fb86d5dc") version("66.1", sha256="52a3f2209ab95559c1cf0a14f24338001f389615bf00e2585ef3dbc43ecf0a2e") version("65.1", sha256="53e37466b3d6d6d01ead029e3567d873a43a5d1c668ed2278e253b683136d948") @@ -27,6 +28,9 @@ class Icu4c(AutotoolsPackage): version("57.2", sha256="623f04b921827a041f42d52495a6f8eee6565a9b7557051ac68e099123ff28dc") version("57.1", sha256="ff8c67cb65949b1e7808f2359f2b80f722697048e90e7cfc382ec1fe229e9581") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "cxxstd", default="11", @@ -61,9 +65,7 @@ def flag_handler(self, name, flags): if name == "cxxflags": # Control of the C++ Standard is via adding the required "-std" # flag to CXXFLAGS in env - flags.append( - getattr(self.compiler, "cxx{0}_flag".format(self.spec.variants["cxxstd"].value)) - ) + flags.append(getattr(self.compiler, f"cxx{self.spec.variants['cxxstd'].value}_flag")) return (None, flags, None) # Need to make sure that locale is UTF-8 in order to process source @@ -75,14 +77,14 @@ def setup_build_environment(self, env): def configure_args(self): args = [] - if "python" in self.spec: + if self.spec.satisfies("^python"): # Make sure configure uses Spack's python package # Without this, configure could pick a broken global installation - args.append("PYTHON={0}".format(self.spec["python"].command)) + args.append(f"PYTHON={self.spec['python'].command}") # The --enable-rpath option is only needed on MacOS, and it # breaks the build for xerces-c on Linux. - if "platform=darwin" in self.spec: + if self.spec.satisfies("platform=darwin"): args.append("--enable-rpath") return args diff --git a/var/spack/repos/builtin/packages/id3lib/package.py b/var/spack/repos/builtin/packages/id3lib/package.py index 660897260ca1a0..39b78311f8f0d6 100644 --- a/var/spack/repos/builtin/packages/id3lib/package.py +++ b/var/spack/repos/builtin/packages/id3lib/package.py @@ -16,6 +16,9 @@ class Id3lib(AutotoolsPackage): version("3.8.3", sha256="2749cc3c0cd7280b299518b1ddf5a5bcfe2d1100614519b68702230e26c7d079") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") # http://connie.slackware.com/~alien/slackbuilds/id3lib/build/id3lib-3.8.3_gcc4.diff diff --git a/var/spack/repos/builtin/packages/idba/package.py b/var/spack/repos/builtin/packages/idba/package.py index 3213d2838f400d..ae200693416203 100644 --- a/var/spack/repos/builtin/packages/idba/package.py +++ b/var/spack/repos/builtin/packages/idba/package.py @@ -15,6 +15,8 @@ class Idba(AutotoolsPackage): version("1.1.3", sha256="6b1746a29884f4fa17b110d94d9ead677ab5557c084a93b16b6a043dbb148709") + depends_on("cxx", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/idg/package.py b/var/spack/repos/builtin/packages/idg/package.py index 42621b4ca9f7d0..74e6b0637bbd8d 100644 --- a/var/spack/repos/builtin/packages/idg/package.py +++ b/var/spack/repos/builtin/packages/idg/package.py @@ -25,6 +25,9 @@ class Idg(CMakePackage): version("1.0.0", commit="3322756fb8b6e3bb1fe5293f3e07e40623ff8486") version("0.8.1", commit="a09f3c85094c592f9304fff4c31e920c7592c3c3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost") depends_on("fftw-api@3") depends_on("blas") diff --git a/var/spack/repos/builtin/packages/igprof/package.py b/var/spack/repos/builtin/packages/igprof/package.py index 97e80795d1b959..eb4d92ca3da278 100644 --- a/var/spack/repos/builtin/packages/igprof/package.py +++ b/var/spack/repos/builtin/packages/igprof/package.py @@ -16,8 +16,12 @@ class Igprof(CMakePackage): homepage = "https://igprof.org/" url = "https://github.com/igprof/igprof/archive/v5.9.16.tar.gz" + version("5.9.18", sha256="f3e378a358469cd269aa5cb3312adc4f5ca89b90c0de89dc070d803c6b68f7b5") version("5.9.16", sha256="cc977466b310f47bbc2967a0bb6ecd49d7437089598346e3f1d8aaf9a7555d96") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libunwind") # Three patches in one: C++11 compatibility (src/analyse.cc), diff --git a/var/spack/repos/builtin/packages/igraph/package.py b/var/spack/repos/builtin/packages/igraph/package.py index ec5051d0540c78..f201aa97ab6592 100644 --- a/var/spack/repos/builtin/packages/igraph/package.py +++ b/var/spack/repos/builtin/packages/igraph/package.py @@ -14,9 +14,14 @@ class Igraph(CMakePackage, AutotoolsPackage): license("GPL-2.0-or-later") + version("0.10.13", sha256="c6dc44324f61f52c098bedb81f6a602365d39d692d5068ca4fc3734b2a15e64c") version("0.10.6", sha256="99bf91ee90febeeb9a201f3e0c1d323c09214f0b5f37a4290dc3b63f52839d6d") version("0.7.1", sha256="d978030e27369bf698f3816ab70aa9141e9baf81c56cc4f55efbe5489b46b0df") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=False, description="Enable shared build") build_system( diff --git a/var/spack/repos/builtin/packages/ike-scan/package.py b/var/spack/repos/builtin/packages/ike-scan/package.py index b6aef8a42d6c3f..fa2aa4c30b18cd 100644 --- a/var/spack/repos/builtin/packages/ike-scan/package.py +++ b/var/spack/repos/builtin/packages/ike-scan/package.py @@ -15,3 +15,5 @@ class IkeScan(AutotoolsPackage): license("GPL-2.0-or-later") version("1.9", sha256="05d15c7172034935d1e46b01dacf1101a293ae0d06c0e14025a4507656f1a7b6") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/ilmbase/package.py b/var/spack/repos/builtin/packages/ilmbase/package.py index e3d47d3e30a126..7ee9bfc2fea58b 100644 --- a/var/spack/repos/builtin/packages/ilmbase/package.py +++ b/var/spack/repos/builtin/packages/ilmbase/package.py @@ -34,3 +34,5 @@ class Ilmbase(AutotoolsPackage): sha256="c134e47206d0e22ff0be96fa95391a13b635b6ad42668673e293f835fbd176b1", url="http://download.savannah.nongnu.org/releases/openexr/ilmbase-0.9.0.tar.gz", ) + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/ima-evm-utils/package.py b/var/spack/repos/builtin/packages/ima-evm-utils/package.py index 11728627b91094..1bb470496adb90 100644 --- a/var/spack/repos/builtin/packages/ima-evm-utils/package.py +++ b/var/spack/repos/builtin/packages/ima-evm-utils/package.py @@ -21,6 +21,8 @@ class ImaEvmUtils(AutotoolsPackage): version("1.3", sha256="62e90e8dc6b131a4f34a356114cdcb5bef844f110abbdd5d8b53c449aecc609f") version("1.2.1", sha256="ad8471b58c4df29abd51c80d74b1501cfe3289b60d32d1b318618a8fd26c0c0a") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/imagemagick/package.py b/var/spack/repos/builtin/packages/imagemagick/package.py index f1e7a3ad8a84cc..3d74e7546bab78 100644 --- a/var/spack/repos/builtin/packages/imagemagick/package.py +++ b/var/spack/repos/builtin/packages/imagemagick/package.py @@ -27,6 +27,9 @@ class Imagemagick(AutotoolsPackage): version("7.0.2-7", sha256="f2f18a97f861c1668befdaff0cc3aaafb2111847aab028a88b4c2cb017acfbaa") version("7.0.2-6", sha256="7d49ca8030f895c683cae69c52d8edfc4876de651f5b8bfdbea907e222480bd3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("ghostscript", default=False, description="Compile with Ghostscript support") variant("rsvg", default=False, description="Enable RSVG support") diff --git a/var/spack/repos/builtin/packages/imake/package.py b/var/spack/repos/builtin/packages/imake/package.py index f209554cd30937..5e350232736ca1 100644 --- a/var/spack/repos/builtin/packages/imake/package.py +++ b/var/spack/repos/builtin/packages/imake/package.py @@ -14,9 +14,13 @@ class Imake(AutotoolsPackage, XorgPackage): license("custom") + version("1.0.10", sha256="9bbe76b6bb39caf34a437f50010f58a13d7dd6d512e00e765a2b7883e6ae613c") version("1.0.9", sha256="ca53ad18c683091490596d72fee8dbee4c6ddb7693709e25f26da140d29687c1") version("1.0.7", sha256="6bda266a07eb33445d513f1e3c82a61e4822ccb94d420643d58e1be5f881e5cb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("xproto") depends_on("xorg-cf-files", type="run") depends_on("pkgconfig", type="build") @@ -24,5 +28,5 @@ class Imake(AutotoolsPackage, XorgPackage): def configure_args(self): args = [] cfgdir = self.spec["xorg-cf-files"].prefix.lib.X11.config - args.append("--with-config-dir={0}".format(cfgdir)) + args.append(f"--with-config-dir={cfgdir}") return args diff --git a/var/spack/repos/builtin/packages/imath/package.py b/var/spack/repos/builtin/packages/imath/package.py index 1937e754fa8f95..b61a2db6814b74 100644 --- a/var/spack/repos/builtin/packages/imath/package.py +++ b/var/spack/repos/builtin/packages/imath/package.py @@ -17,8 +17,12 @@ class Imath(CMakePackage): license("BSD-3-Clause") + version("3.1.11", sha256="9057849585e49b8b85abe7cc1e76e22963b01bfdc3b6d83eac90c499cd760063") version("3.1.9", sha256="f1d8aacd46afed958babfced3190d2d3c8209b66da451f556abd6da94c165cf3") version("3.1.7", sha256="bff1fa140f4af0e7f02c6cb78d41b9a7d5508e6bcdfda3a583e35460eb6d4b47") version("3.1.5", sha256="1e9c7c94797cf7b7e61908aed1f80a331088cc7d8873318f70376e4aed5f25fb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.12:", type="build") diff --git a/var/spack/repos/builtin/packages/imgui/package.py b/var/spack/repos/builtin/packages/imgui/package.py index c233e4abe90332..4824937cdd8fff 100644 --- a/var/spack/repos/builtin/packages/imgui/package.py +++ b/var/spack/repos/builtin/packages/imgui/package.py @@ -18,8 +18,12 @@ class Imgui(Package): license("MIT") + version("1.90.6", sha256="70b4b05ac0938e82b4d5b8d59480d3e2ca63ca570dfb88c55023831f387237ad") version("1.85", sha256="7ed49d1f4573004fa725a70642aaddd3e06bb57fcfe1c1a49ac6574a3e895a77") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): # No specific build process is required. # You can add the .cpp files to your existing project. diff --git a/var/spack/repos/builtin/packages/imlib2/package.py b/var/spack/repos/builtin/packages/imlib2/package.py index d77907c81bdecd..60530a35aa3e47 100644 --- a/var/spack/repos/builtin/packages/imlib2/package.py +++ b/var/spack/repos/builtin/packages/imlib2/package.py @@ -24,6 +24,8 @@ class Imlib2(AutotoolsPackage, SourceforgePackage): version("1.6.0", sha256="cfc440ddfaed5fc85ba2572ad8d87a87cd77a5bffb33ebca882c42cefcd8691d") version("1.5.1", sha256="fa4e57452b8843f4a70f70fd435c746ae2ace813250f8c65f977db5d7914baae") + depends_on("c", type="build") # generated + depends_on("libtiff") depends_on("giflib") depends_on("bzip2") diff --git a/var/spack/repos/builtin/packages/imp/package.py b/var/spack/repos/builtin/packages/imp/package.py index e8af0247af5401..9a78845cc67d6e 100644 --- a/var/spack/repos/builtin/packages/imp/package.py +++ b/var/spack/repos/builtin/packages/imp/package.py @@ -17,6 +17,9 @@ class Imp(CMakePackage): version("2.8.0", sha256="0b46b8988febd7cdfc5838849007f9a547493ed4b6c752fe54571467eeb1acd2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@2.7:") depends_on("swig") depends_on("boost@1.40:") diff --git a/var/spack/repos/builtin/packages/impalajit/package.py b/var/spack/repos/builtin/packages/impalajit/package.py index ad823160d10577..c61f3c301ea90e 100644 --- a/var/spack/repos/builtin/packages/impalajit/package.py +++ b/var/spack/repos/builtin/packages/impalajit/package.py @@ -27,6 +27,10 @@ class Impalajit(CMakePackage): version("llvm", git="https://github.com/ravil-mobile/ImpalaJIT.git", branch="dev") version("llvm-1.0.0", git="https://github.com/ravil-mobile/ImpalaJIT.git", tag="v1.0.0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + maintainers("ravil-mobile", "Thomas-Ulrich") variant("shared", default=True, description="build as a shared library") diff --git a/var/spack/repos/builtin/packages/improved-rdock/package.py b/var/spack/repos/builtin/packages/improved-rdock/package.py index 3f78946a2435e0..1adef52b675ecd 100644 --- a/var/spack/repos/builtin/packages/improved-rdock/package.py +++ b/var/spack/repos/builtin/packages/improved-rdock/package.py @@ -23,6 +23,8 @@ class ImprovedRdock(MakefilePackage): version("main", branch="main") + depends_on("cxx", type="build") # generated + depends_on("popt") depends_on("cppunit") depends_on("openbabel @3.0.0: +python", type="run") @@ -61,33 +63,41 @@ def install(self, spec, prefix): def setup_run_environment(self, env): env.set("RBT_ROOT", self.prefix) - def test(self): + def test_rdock(self): + """improved-rdock test suite""" copy(join_path(self.prefix.example, "1sj0", "*"), ".") - opts = ["-r", "1sj0_rdock.prm", "-was"] - self.run_test("rbcavity", options=opts) - - mpiexe = self.spec["mpi"].prefix.bin.mpirun - opts = [ - self.prefix.bin.rbdock, - "-r", - "1sj0_rdock.prm", - "-p", - "dock.prm", - "-n", - "100", - "-i", - "1sj0_ligand.sd", - "-o", - "1sj0_docking_out", - "-s", - "1", - ] - self.run_test(str(mpiexe), options=opts) - - opts = [join_path(self.test_suite.current_test_data_dir, "test.sh")] - self.run_test("bash", options=opts) - - pythonexe = self.spec["python"].command.path - opts = [self.spec.prefix.bin.sdrmsd, "1sj0_ligand.sd", "1sj0_docking_out_sorted.sd"] - expected = ["1\t0.55", "100\t7.91"] - self.run_test(pythonexe, options=opts, expected=expected) + + with test_part(self, "test_rdock_rbcavity", purpose="Check rbcavity"): + rbcavity = which("rbcavity") + rbcavity("-r", "1sj0_rdock.prm", "-was") + + with test_part(self, "test_rdock_rbdock", purpose="Use mpirun to run rbdock in parallel"): + mpiexe = which(str(self.spec["mpi"].prefix.bin.mpirun)) + opts = [ + self.prefix.bin.rbdock, + "-r", + "1sj0_rdock.prm", + "-p", + "dock.prm", + "-n", + "100", + "-i", + "1sj0_ligand.sd", + "-o", + "1sj0_docking_out", + "-s", + "1", + ] + mpiexe(*opts) + + with test_part(self, "test_rdock_test_sh", purpose="Sort the output"): + bash = which("bash") + opts = [join_path(self.test_suite.current_test_data_dir, "test.sh")] + bash(*opts) + + with test_part(self, "test_rdock_sdrmsd", purpose="Check sdrmsd calculations"): + pythonexe = which(str(self.spec["python"].command.path)) + opts = [self.spec.prefix.bin.sdrmsd, "1sj0_ligand.sd", "1sj0_docking_out_sorted.sd"] + expected = ["1\t0.55", "100\t7.91"] + out = pythonexe(*opts, out=str.split, error=str.split) + check_outputs(expected, out) diff --git a/var/spack/repos/builtin/packages/infernal/package.py b/var/spack/repos/builtin/packages/infernal/package.py index a69ca987b20e11..a3ac6998c57395 100644 --- a/var/spack/repos/builtin/packages/infernal/package.py +++ b/var/spack/repos/builtin/packages/infernal/package.py @@ -19,6 +19,8 @@ class Infernal(AutotoolsPackage): version("1.1.3", sha256="3b98a6a3a0e7b01aa077a0caf1e958223c4d8f80a69a4eb602ca59a3475da85e") version("1.1.2", sha256="ac8c24f484205cfb7124c38d6dc638a28f2b9035b9433efec5dc753c7e84226b") + depends_on("c", type="build") # generated + variant("mpi", default=False, description="Enable MPI parallel support") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin/packages/iniparser/package.py b/var/spack/repos/builtin/packages/iniparser/package.py index ba99ed31bcca17..b5be9e4e681682 100644 --- a/var/spack/repos/builtin/packages/iniparser/package.py +++ b/var/spack/repos/builtin/packages/iniparser/package.py @@ -15,11 +15,14 @@ class Iniparser(MakefilePackage): license("MIT") + version("4.2", sha256="dbcbaf3aedb4f88a9fc0df4b315737ddd10e6c37918e3d89f0ecc475333bde4d") version("4.1", sha256="960daa800dd31d70ba1bacf3ea2d22e8ddfc2906534bf328319495966443f3ae") version("4.0", sha256="e0bbd664bb3f0d64c21ac2d67a843b1c7a3a9710e96393344d170ab8b33e92ba") version("3.2", sha256="4a60b8e29d33d24b458749404e1ff2bcbfedd53ad800757daeed7955599fdce4") version("3.1", sha256="73b88632dc16c2839f5d9ac7e6ec7a41415a68e590f75d0580b302af4a5d821d") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.include) mkdirp(prefix.lib) diff --git a/var/spack/repos/builtin/packages/intel-daal/package.py b/var/spack/repos/builtin/packages/intel-daal/package.py deleted file mode 100644 index 30e8af51413084..00000000000000 --- a/var/spack/repos/builtin/packages/intel-daal/package.py +++ /dev/null @@ -1,141 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -from spack.package import * - - -@IntelOneApiPackage.update_description -class IntelDaal(IntelPackage): - """Intel Data Analytics Acceleration Library. This package has been - replace by intel-oneapi-dal. - - """ - - maintainers("rscohn2") - - homepage = "https://software.intel.com/en-us/daal" - - version( - "2020.2.254", - sha256="08528bc150dad312ff2ae88ce12d6078ed8ba2f378f4bf3daf0fbbb9657dce1e", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/16822/l_daal_2020.2.254.tgz", - deprecated=True, - ) - version( - "2020.1.217", - sha256="3f84dea0ce1038ac1b9c25b3e2c02e9fac440fa36cc8adfce69edfc06fe0edda", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/16536/l_daal_2020.1.217.tgz", - deprecated=True, - ) - version( - "2020.0.166", - sha256="695166c9ab32ac5d3006d6d35162db3c98734210507144e315ed7c3b7dbca9c1", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/16234/l_daal_2020.0.166.tgz", - deprecated=True, - ) - version( - "2019.5.281", - sha256="e92aaedbe35c9daf1c9483260cb2363da8a85fa1aa5566eb38cf4b1f410bc368", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/15818/l_daal_2019.5.281.tgz", - deprecated=True, - ) - version( - "2019.4.243", - sha256="c74486a555ca5636c2ac1b060d5424726c022468f3ee0898bb46e333cda6f7b8", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/15552/l_daal_2019.4.243.tgz", - deprecated=True, - ) - version( - "2019.3.199", - sha256="1f7d9cdecc1091b03f1ee6303fc7566179d1e3f1813a98ef7a6239f7d456b8ef", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/15277/l_daal_2019.3.199.tgz", - deprecated=True, - ) - version( - "2019.2.187", - sha256="2982886347e9376e892a5c4e22fa1d4b7b843e1ae988a107dd2d0a639f257765", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/15097/l_daal_2019.2.187.tgz", - deprecated=True, - ) - version( - "2019.1.144", - sha256="1672afac568c93e185283cf7e044d511381092ebc95d7204c4dccb83cc493197", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/14869/l_daal_2019.1.144.tgz", - deprecated=True, - ) - version( - "2019.0.117", - sha256="85ac8e983bc9b9cc635e87cb4ec775ffd3695e44275d20fdaf53c19ed280d69f", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/13577/l_daal_2019.0.117.tgz", - deprecated=True, - ) - version( - "2018.3.222", - sha256="378fec529a36508dd97529037e1164ff98e0e062a9a47ede99ccf9e91493d1e2", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/13007/l_daal_2018.3.222.tgz", - deprecated=True, - ) - version( - "2018.2.199", - sha256="cee30299b3ffaea515f5a9609f4df0f644579c8a1ba2b61747b390f6caf85b14", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/12727/l_daal_2018.2.199.tgz", - deprecated=True, - ) - version( - "2018.1.163", - sha256="ac96b5a6c137cda18817d9b3505975863f8f53347225ebb6ccdaaf4bdb8dc349", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/12414/l_daal_2018.1.163.tgz", - deprecated=True, - ) - version( - "2018.0.128", - sha256="d13a7cd1b6779971f2ba46797447de9409c98a4d2f0eb0dc9622d9d63ac8990f", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/12072/l_daal_2018.0.128.tgz", - deprecated=True, - ) - version( - "2017.4.239", - sha256="cc4b608f59f3b2fafee16389102a763d27c46f6d136a6cfa89847418a8ea7460", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/12148/l_daal_2017.4.239.tgz", - deprecated=True, - ) - version( - "2017.3.196", - sha256="cfa863f342dd1c5fe8f1c7b6fd69589140370fc92742a19d82c8594e4e1e46ce", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/11546/l_daal_2017.3.196.tgz", - deprecated=True, - ) - version( - "2017.2.174", - sha256="5ee838b08d4cda7fc3e006e1deeed41671cbd7cfd11b64ec3b762c94dfc2b660", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/11308/l_daal_2017.2.174.tgz", - deprecated=True, - ) - version( - "2017.1.132", - sha256="6281105d3947fc2860e67401ea0218198cc4753fd2d4b513528a89143248e4f3", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/10983/l_daal_2017.1.132.tgz", - deprecated=True, - ) - version( - "2017.0.098", - sha256="a7064425653b4f5f0fe51e25358d267d8ae023179eece61e08da891b67d79fe5", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/9664/l_daal_2017.0.098.tgz", - deprecated=True, - ) - version( - "2016.3.210", - sha256="367eaef21ea0143c11ae3fd56cd2a05315768c059e14caa15894bcf96853687c", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/9099/l_daal_2016.3.210.tgz", - deprecated=True, - ) - version( - "2016.2.181", - sha256="afdb65768957784d28ac537b4933a86eb4193c68a636157caed17b29ccdbfacb", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/8687/l_daal_2016.2.181.tgz", - deprecated=True, - ) - - provides("daal") diff --git a/var/spack/repos/builtin/packages/intel-gpu-tools/package.py b/var/spack/repos/builtin/packages/intel-gpu-tools/package.py index afef3bc25f1b67..efb78e156342af 100644 --- a/var/spack/repos/builtin/packages/intel-gpu-tools/package.py +++ b/var/spack/repos/builtin/packages/intel-gpu-tools/package.py @@ -24,6 +24,8 @@ class IntelGpuTools(AutotoolsPackage, XorgPackage): version("1.20", sha256="c6ee992301e43ec14ef810ef532e2601ecf7399315f942207ae0dd568fd9c2b7") version("1.16", sha256="4874e6e7704c8d315deaf5b44cc9467ea5e502c7f816470a4a28827fcb34643f") + depends_on("c", type="build") # generated + depends_on("libdrm@2.4.64:") depends_on("libpciaccess@0.10:", when=(sys.platform != "darwin")) depends_on("libunwind") diff --git a/var/spack/repos/builtin/packages/intel-gtpin/package.py b/var/spack/repos/builtin/packages/intel-gtpin/package.py index 71c22ca4799eb5..d082e4fb1781bf 100644 --- a/var/spack/repos/builtin/packages/intel-gtpin/package.py +++ b/var/spack/repos/builtin/packages/intel-gtpin/package.py @@ -90,10 +90,13 @@ class IntelGtpin(Package): url="https://downloadmirror.intel.com/682779/external-gtpin-2.11.4-linux.tar.bz2", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("patchelf", type="build") - # Gtpin only runs on linux/cray x86_64. - conflicts("platform=darwin", msg="intel-gtpin only runs on linux/cray") + # Gtpin only runs on linux x86_64. + conflicts("platform=darwin", msg="intel-gtpin only runs on linux") conflicts("target=ppc64:", msg="intel-gtpin only runs on x86_64") conflicts("target=ppc64le:", msg="intel-gtpin only runs on x86_64") conflicts("target=aarch64:", msg="intel-gtpin only runs on x86_64") diff --git a/var/spack/repos/builtin/packages/intel-ipp/package.py b/var/spack/repos/builtin/packages/intel-ipp/package.py deleted file mode 100644 index d06afa06961e70..00000000000000 --- a/var/spack/repos/builtin/packages/intel-ipp/package.py +++ /dev/null @@ -1,130 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -from spack.package import * - - -@IntelOneApiPackage.update_description -class IntelIpp(IntelPackage): - """Intel Integrated Performance Primitives. This package has been - replaced by intel-oneapi-ipp. - - """ - - maintainers("rscohn2") - - homepage = "https://software.intel.com/en-us/intel-ipp" - - version( - "2020.2.254", - sha256="18266ad1eec9b5b17e76da24f1aa9a9147300e5bd345e6bdad58d7187392fa77", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/16846/l_ipp_2020.2.254.tgz", - deprecated=True, - ) - version( - "2020.1.217", - sha256="0bf8ac7e635e7e602cf201063a1a7dea3779b093104563fdb15e6b7ecf2f00a7", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/16534/l_ipp_2020.1.217.tgz", - deprecated=True, - ) - version( - "2020.0.166", - sha256="6844007892ba524e828f245355cee44e8149f4c233abbbea16f7bb55a7d6ecff", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/16233/l_ipp_2020.0.166.tgz", - deprecated=True, - ) - version( - "2019.5.281", - sha256="61d1e1da1a4a50f1cf02a3ed44e87eed05e94d58b64ef1e67a3bdec363bee713", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/15817/l_ipp_2019.5.281.tgz", - deprecated=True, - ) - version( - "2019.4.243", - sha256="d4f4232323e66b010d8440c75189aeb6a3249966e05035242b21982238a7a7f2", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/15541/l_ipp_2019.4.243.tgz", - deprecated=True, - ) - version( - "2019.3.199", - sha256="02545383206c1ae4dd66bfa6a38e2e14480ba11932eeed632df8ab798aa15ccd", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/15276/l_ipp_2019.3.199.tgz", - deprecated=True, - ) - version( - "2019.2.187", - sha256="280e9081278a0db3892fe82474c1201ec780a6f7c8d1f896494867f4b3bd8421", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/15096/l_ipp_2019.2.187.tgz", - deprecated=True, - ) - version( - "2019.1.144", - sha256="1eb7cd0fba74615aeafa4e314c645414497eb73f1705200c524fe78f00620db3", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/14887/l_ipp_2019.1.144.tgz", - deprecated=True, - ) - version( - "2019.0.117", - sha256="d552ba49fba58f0e94da2048176f21c5dfd490dca7c5ce666dfc2d18db7fd551", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/13576/l_ipp_2019.0.117.tgz", - deprecated=True, - ) - version( - "2018.4.274", - sha256="bdc6082c65410c98ccf6daf239e0a6625d15ec5e0ddc1c0563aad42b6ba9063c", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/13726/l_ipp_2018.4.274.tgz", - deprecated=True, - ) - version( - "2018.3.222", - sha256="bb783c5e6220e240f19136ae598cd1c1d647496495139ce680de58d3d5496934", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/13006/l_ipp_2018.3.222.tgz", - deprecated=True, - ) - version( - "2018.2.199", - sha256="55cb5c910b2c1e2bd798163fb5019b992b1259a0692e328bb9054778cf01562b", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/12726/l_ipp_2018.2.199.tgz", - deprecated=True, - ) - version( - "2018.0.128", - sha256="da568ceec1b7acbcc8f666b73d4092788b037b1b03c0436974b82155056ed166", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/12071/l_ipp_2018.0.128.tgz", - deprecated=True, - ) - version( - "2017.3.196", - sha256="50d49a1000a88a8a58bd610466e90ae28d07a70993a78cbbf85d44d27c4232b6", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/11545/l_ipp_2017.3.196.tgz", - deprecated=True, - ) - version( - "2017.2.174", - sha256="92f866c9dce8503d7e04223ec35f281cfeb0b81cf94208c3becb11aacfda7b99", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/11307/l_ipp_2017.2.174.tgz", - deprecated=True, - ) - version( - "2017.1.132", - sha256="2908bdeab3057d4ebcaa0b8ff5b00eb47425d35961a96f14780be68554d95376", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/11031/l_ipp_2017.1.132.tgz", - deprecated=True, - ) - version( - "2017.0.098", - sha256="7633d16e2578be64533892336c8a15c905139147b0f74eaf9f281358ad7cdcba", - url="http://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/9663/l_ipp_2017.0.098.tgz", - deprecated=True, - ) - # built from parallel_studio_xe_2016.3.067 - version( - "9.0.3.210", - sha256="8ce7bf17f4a0bbf8c441063de26be7f6e0f6179789e23f24eaa8b712632b3cdd", - url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/tec/9067/l_ipp_9.0.3.210.tgz", - deprecated=True, - ) - - provides("ipp") diff --git a/var/spack/repos/builtin/packages/intel-llvm/package.py b/var/spack/repos/builtin/packages/intel-llvm/package.py index 630e2df9960610..5c5fbe17d8c1e0 100644 --- a/var/spack/repos/builtin/packages/intel-llvm/package.py +++ b/var/spack/repos/builtin/packages/intel-llvm/package.py @@ -14,12 +14,14 @@ class IntelLlvm(CMakePackage): homepage = "https://github.com/intel/llvm" git = "https://github.com/intel/llvm.git" - family = "compiler" - license("Apache-2.0") version("sycl", branch="sycl") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.4.3:", type="build") # It doesn't seem possible to use != in a conflicts statement diff --git a/var/spack/repos/builtin/packages/intel-mpi-benchmarks/package.py b/var/spack/repos/builtin/packages/intel-mpi-benchmarks/package.py index 764394ea1f9bb7..5ef9e675a9450c 100644 --- a/var/spack/repos/builtin/packages/intel-mpi-benchmarks/package.py +++ b/var/spack/repos/builtin/packages/intel-mpi-benchmarks/package.py @@ -40,6 +40,9 @@ class IntelMpiBenchmarks(MakefilePackage): version("2018.1", sha256="718a4eb155f18cf15a736f6496332407b5837cf1f19831723d4cfe5266c43507") version("2018.0", sha256="2e60a9894a686a95791be2227bc569bf81ca3875421b5307df7d83f885b1de88") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("mpi", when="@2019:") depends_on("intel-mpi", when="@2018") depends_on("gmake", type="build", when="@2018") diff --git a/var/spack/repos/builtin/packages/intel-mpi/package.py b/var/spack/repos/builtin/packages/intel-mpi/package.py index aa1ae55752bf87..3e8ce47e9d1cd3 100644 --- a/var/spack/repos/builtin/packages/intel-mpi/package.py +++ b/var/spack/repos/builtin/packages/intel-mpi/package.py @@ -150,19 +150,21 @@ class IntelMpi(IntelPackage): depends_on("libfabric", when="+external-libfabric", type=("build", "link", "run")) depends_on("cpio", type="build") - def setup_dependent_build_environment(self, *args): + def setup_dependent_build_environment(self, env, dependent_spec): # Handle in callback, conveying client's compilers in additional arg. # CAUTION - DUP code in: # ../intel-mpi/package.py # ../intel-parallel-studio/package.py + dependent_module = dependent_spec.package.module self._setup_dependent_env_callback( - *args, + env, + dependent_spec, compilers_of_client={ - "CC": spack_cc, - "CXX": spack_cxx, - "F77": spack_f77, - "F90": spack_fc, - "FC": spack_fc, + "CC": dependent_module.spack_cc, + "CXX": dependent_module.spack_cxx, + "F77": dependent_module.spack_f77, + "F90": dependent_module.spack_fc, + "FC": dependent_module.spack_fc, }, ) diff --git a/var/spack/repos/builtin/packages/intel-oneapi-advisor/package.py b/var/spack/repos/builtin/packages/intel-oneapi-advisor/package.py index cff72a86873169..d973e105b71e1d 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-advisor/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-advisor/package.py @@ -24,6 +24,18 @@ class IntelOneapiAdvisor(IntelOneApiLibraryPackageWithSdk): "https://software.intel.com/content/www/us/en/develop/tools/oneapi/components/advisor.html" ) + version( + "2024.2.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/a4c8046c-6abf-4f53-a33c-4a587cd80fc1/l_oneapi_advisor_p_2024.2.0.683_offline.sh", + sha256="8a6a8ced2456ea7c538aad01b4e6e0bd41244bcb438f76d4b87af5f63f94a733", + expand=False, + ) + version( + "2024.1.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/414cea14-4f3c-45f0-b854-44fb6cf9f34b/l_oneapi_advisor_p_2024.1.0.500_offline.sh", + sha256="1c327777a34a7e70e5840b9555ebf44615bf0295fcf3c673576d36a9a8979090", + expand=False, + ) version( "2024.0.1", url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/2d6b30ed-c7ea-4ad1-b138-91614f8242e8/l_oneapi_advisor_p_2024.0.1.17_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-ccl/package.py b/var/spack/repos/builtin/packages/intel-oneapi-ccl/package.py index c31d9b38872993..98f14a66273d34 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-ccl/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-ccl/package.py @@ -27,6 +27,18 @@ class IntelOneapiCcl(IntelOneApiLibraryPackage): depends_on("intel-oneapi-mpi") + version( + "2021.13.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/2413acba-2216-4a35-9c74-82694a20d176/l_oneapi_ccl_p_2021.13.0.300_offline.sh", + sha256="0cb848fb86b2eec6ed53910f961211c43bab628ada47e5b3d401bfff59942c02", + expand=False, + ) + version( + "2021.12.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/cad4b3be-a272-4ed0-b67a-3871e495cb28/l_oneapi_ccl_p_2021.12.0.311_offline.sh", + sha256="77b60a56d02c3700182370698b760cb17c66be700ca98bda1f30b39b9948e375", + expand=False, + ) version( "2021.11.2", url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/7a2bbe23-9cf2-47a3-945f-fc160b9d868a/l_oneapi_ccl_p_2021.11.2.7_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-compilers-classic/detection_test.yaml b/var/spack/repos/builtin/packages/intel-oneapi-compilers-classic/detection_test.yaml new file mode 100644 index 00000000000000..06845074248055 --- /dev/null +++ b/var/spack/repos/builtin/packages/intel-oneapi-compilers-classic/detection_test.yaml @@ -0,0 +1,89 @@ +paths: +- layout: + - executables: + - "bin/intel64/icc" + script: | + echo "icc (ICC) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + - executables: + - "bin/intel64/icpc" + script: | + echo "icpc (ICC) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + - executables: + - "bin/intel64/ifort" + script: | + echo "ifort (IFORT) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + platforms: [linux] + results: + - spec: 'intel-oneapi-compilers-classic@18.0.5' + extra_attributes: + compilers: + c: ".*/bin/intel64/icc" + cxx: ".*/bin/intel64/icpc" + fortran: ".*/bin/intel64/ifort" +- layout: + - executables: + - "bin/icc" + script: | + echo "icc (ICC) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + - executables: + - "bin/icpc" + script: | + echo "icpc (ICC) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + - executables: + - "bin/ifort" + script: | + echo "ifort (IFORT) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + platforms: [linux] + results: + - spec: 'intel-oneapi-compilers-classic@18.0.5' + extra_attributes: + compilers: + c: ".*/bin/icc" + cxx: ".*/bin/icpc" + fortran: ".*/bin/ifort" +- layout: + - executables: + - "compiler/18.0.5/linux/bin/intel64/icc" + script: | + echo "icc (ICC) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + - executables: + - "compiler/18.0.5/linux/bin/intel64/icpc" + script: | + echo "icpc (ICC) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + - executables: + - "compiler/18.0.5/linux/bin/intel64/ifort" + script: | + echo "ifort (IFORT) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + platforms: [linux] + results: + - spec: 'intel-oneapi-compilers-classic@18.0.5' + extra_attributes: + compilers: + c: ".*compiler/18.0.5/linux/bin/intel64/icc" + cxx: ".*compiler/18.0.5/linux/bin/intel64/icpc" + fortran: ".*compiler/18.0.5/linux/bin/intel64/ifort" +- layout: # oneapi compiler is not detected as classic + - executables: + - "compiler/18.0.5/linux/bin/icx" + - "compiler/18.0.5/linux/bin/icpx" + script: | + echo "Intel(R) oneAPI DPC++ Compiler 2021.2.0 (2021.2.0.20210317)" + echo "Target: x86_64-unknown-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /made/up/path", + - executables: + - "compiler/18.0.5/linux/bin/ifx" + script: | + echo "ifx (IFORT) 2021.1.2 Beta 20201214" + echo "Copyright (C) 1985-2020 Intel Corporation. All rights reserved." + platforms: [linux] + results: [] diff --git a/var/spack/repos/builtin/packages/intel-oneapi-compilers-classic/package.py b/var/spack/repos/builtin/packages/intel-oneapi-compilers-classic/package.py index aefec971976697..71de26ed340a91 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-compilers-classic/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-compilers-classic/package.py @@ -3,14 +3,16 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) import os +import sys +from llnl.util.lang import classproperty from llnl.util.link_tree import LinkTree from spack.package import * @IntelOneApiPackage.update_description -class IntelOneapiCompilersClassic(Package): +class IntelOneapiCompilersClassic(Package, CompilerPackage): """Relies on intel-oneapi-compilers to install the compilers, and configures modules for icc/icpc/ifort. @@ -22,6 +24,23 @@ class IntelOneapiCompilersClassic(Package): has_code = False + compiler_languages = ["c", "cxx", "fortran"] + c_names = ["icc"] + cxx_names = ["icpc"] + fortran_names = ["ifort"] + + @classproperty + def compiler_version_argument(self): + if sys.platform == "win32": + return "/QV" + return "--version" + + @classproperty + def compiler_version_regex(self): + if sys.platform == "win32": + return r"([1-9][0-9]*\.[0-9]*\.[0-9]*)" + return r"\((?:IFORT|ICC)\) ([^ ]+)" + # Versions before 2021 are in the `intel` package # intel-oneapi versions before 2022 use intel@19.0.4 for ver, oneapi_ver in { diff --git a/var/spack/repos/builtin/packages/intel-oneapi-compilers/detection_test.yaml b/var/spack/repos/builtin/packages/intel-oneapi-compilers/detection_test.yaml new file mode 100644 index 00000000000000..d1e0c2252ed775 --- /dev/null +++ b/var/spack/repos/builtin/packages/intel-oneapi-compilers/detection_test.yaml @@ -0,0 +1,23 @@ +paths: +- layout: + - executables: + - "compiler/2021.2.0/linux/bin/icx" + - "compiler/2021.2.0/linux/bin/icpx" + script: | + echo "Intel(R) oneAPI DPC++ Compiler 2021.2.0 (2021.2.0.20210317)" + echo "Target: x86_64-unknown-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /made/up/path", + - executables: + - "compiler/2021.2.0/linux/bin/ifx" + script: | + echo "ifx (IFORT) 2021.2.0 Beta 20201214" + echo "Copyright (C) 1985-2020 Intel Corporation. All rights reserved." + platforms: [linux] + results: + - spec: intel-oneapi-compilers@2021.2.0 + extra_attributes: + compilers: + c: ".*/compiler/2021.2.0/linux/bin/icx" + cxx: ".*/compiler/2021.2.0/linux/bin/icpx" + fortran: ".*/compiler/2021.2.0/linux/bin/ifx" diff --git a/var/spack/repos/builtin/packages/intel-oneapi-compilers/package.py b/var/spack/repos/builtin/packages/intel-oneapi-compilers/package.py index 44a52b8d28ecf1..f0fece125b44c0 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-compilers/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-compilers/package.py @@ -9,6 +9,28 @@ from spack.package import * versions = [ + { + "version": "2024.2.0", + "cpp": { + "url": "https://registrationcenter-download.intel.com/akdlm/IRC_NAS/6780ac84-6256-4b59-a647-330eb65f32b6/l_dpcpp-cpp-compiler_p_2024.2.0.495_offline.sh", + "sha256": "9463aa979314d2acc51472d414ffcee032e9869ca85ac6ff4c71d39500e5173d", + }, + "ftn": { + "url": "https://registrationcenter-download.intel.com/akdlm/IRC_NAS/801143de-6c01-4181-9911-57e00fe40181/l_fortran-compiler_p_2024.2.0.426_offline.sh", + "sha256": "fd19a302662b2f86f76fc115ef53a69f16488080278dba4c573cc705f3a52ffa", + }, + }, + { + "version": "2024.1.0", + "cpp": { + "url": "https://registrationcenter-download.intel.com/akdlm/IRC_NAS/2e562b6e-5d0f-4001-8121-350a828332fb/l_dpcpp-cpp-compiler_p_2024.1.0.468_offline.sh", + "sha256": "534ecc6e4b690c9011d7765cbe178f520aa8f49c0eb4ea80ea1415e48e5d7cf7", + }, + "ftn": { + "url": "https://registrationcenter-download.intel.com/akdlm/IRC_NAS/fd9342bd-7d50-442c-a3e4-f41974e14396/l_fortran-compiler_p_2024.1.0.465_offline.sh", + "sha256": "30a02bad9a96a543c60f3bfa4238dfe07c2d26d76fc22ba9aa9b7c603e11f1b9", + }, + }, { "version": "2024.0.2", "cpp": { @@ -211,18 +233,24 @@ @IntelOneApiPackage.update_description -class IntelOneapiCompilers(IntelOneApiPackage): - """Intel oneAPI Compilers. Includes: icc, icpc, ifort, icx, icpx, ifx, - and dpcpp. - - """ +class IntelOneapiCompilers(IntelOneApiPackage, CompilerPackage): + """Intel oneAPI Compilers. Includes: icc, icpc, ifort, icx, icpx, and ifx.""" maintainers("rscohn2") homepage = "https://software.intel.com/content/www/us/en/develop/tools/oneapi.html" + compiler_languages = ["c", "cxx", "fortran"] + c_names = ["icx"] + cxx_names = ["icpx"] + fortran_names = ["ifx"] + compiler_version_argument = "--version" + compiler_version_regex = ( + r"(?:(?:oneAPI DPC\+\+(?:\/C\+\+)? Compiler)|(?:\(IFORT\))|(?:\(IFX\))) (\S+)" + ) + # See https://github.com/spack/spack/issues/39252 - depends_on("patchelf@:0.17", type="build") + depends_on("patchelf@:0.17", type="build", when="@:2024.1") # TODO: effectively gcc is a direct dependency of intel-oneapi-compilers, but we # cannot express that properly. For now, add conflicts for non-gcc compilers @@ -310,6 +338,12 @@ def inject_rpaths(self): # issues. I am using the 2024 release as a milestone to stop # patching everything and just patching the binaries that have # a problem. + + # 2024.2 no longer needs patching + if self.spec.satisfies("@2024.2:"): + return + + # 2024 fixed all but these 2 patchelf = which("patchelf") if self.spec.satisfies("@2024:"): patchelf.add_default_arg("--set-rpath", self.component_prefix.lib) @@ -330,7 +364,7 @@ def write_config_file(self, flags, path, compilers): # Tolerate missing compilers. # Initially, we installed icx/ifx/icc/ifort into a single prefix. # Starting in 2024, there is no icc. 2023.2.3 does not have an ifx. - if os.path.exists(compiler): + if os.path.exists(path.join(compiler)): p = path.join(compiler + ".cfg") with open(p, "w") as f: f.write(" ".join(flags)) @@ -388,3 +422,31 @@ def _ld_library_path(self): p = join_path(self.component_prefix.linux, d) if find(p, "*." + dso_suffix, recursive=False): yield p + + @classmethod + def runtime_constraints(cls, *, spec, pkg): + pkg("*").depends_on( + "intel-oneapi-runtime", + when="%oneapi", + type="link", + description="If any package uses %oneapi, it depends on intel-oneapi-runtime", + ) + pkg("*").depends_on( + f"intel-oneapi-runtime@{str(spec.version)}:", + when=f"%{str(spec)}", + type="link", + description=f"If any package uses %{str(spec)}, " + f"it depends on intel-oneapi-runtime@{str(spec.version)}:", + ) + + for fortran_virtual in ("fortran-rt", "libifcore@5"): + pkg("*").depends_on( + fortran_virtual, + when=f"%{str(spec)}", + languages=["fortran"], + type="link", + description=f"Add a dependency on 'libifcore' for nodes compiled with " + f"{str(spec)} and using the 'fortran' language", + ) + # The version of intel-oneapi-runtime is the same as the %oneapi used to "compile" it + pkg("intel-oneapi-runtime").requires(f"@={str(spec.version)}", when=f"%{str(spec)}") diff --git a/var/spack/repos/builtin/packages/intel-oneapi-dal/package.py b/var/spack/repos/builtin/packages/intel-oneapi-dal/package.py index d90db4ea6496cf..fcc6c97240cea1 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-dal/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-dal/package.py @@ -26,6 +26,18 @@ class IntelOneapiDal(IntelOneApiLibraryPackage): "https://software.intel.com/content/www/us/en/develop/tools/oneapi/components/onedal.html" ) + version( + "2024.5.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/6ca2d1a8-b7c7-4a70-9c38-2b437dacae1a/l_daal_oneapi_p_2024.5.0.284_offline.sh", + sha256="65d437f8841fd4872e35708f3c989bc00022fe041e750e8c35dee010bd87db9d", + expand=False, + ) + version( + "2024.2.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/3cee4c6c-b7d1-42ce-8bbb-d829a700952f/l_daal_oneapi_p_2024.2.0.280_offline.sh", + sha256="921dbbf200096166d58ab5b8baeb93a8c85ad8a98cc43e178ae0c2f29af02212", + expand=False, + ) version( "2024.0.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/37364086-b3cd-4a54-8736-7893732c1a86/l_daal_oneapi_p_2024.0.0.49569_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-dnn/package.py b/var/spack/repos/builtin/packages/intel-oneapi-dnn/package.py index 37066aac2b026d..d27f0c6931376d 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-dnn/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-dnn/package.py @@ -26,6 +26,24 @@ class IntelOneapiDnn(IntelOneApiLibraryPackage): "https://software.intel.com/content/www/us/en/develop/tools/oneapi/components/onednn.html" ) + version( + "2024.2.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/6f830f51-56cd-4ea6-ade7-0f066c9b1939/l_onednn_p_2024.2.0.571_offline.sh", + sha256="9bc74f8e48758c0ce7dda4c9f8f961a26f48c25e5ad5335c6e7ecbd7ece38c97", + expand=False, + ) + version( + "2024.1.1", + url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/5f6d82fa-2580-4bb1-83bb-cce7a52d1d34/l_onednn_p_2024.1.1.16_offline.sh", + sha256="a67a387bc0d30a5ca1bd0ed3d551ed13df7dba7939b208fd0c81a24425e6e90a", + expand=False, + ) + version( + "2024.1.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/759e8b2a-cbff-4b4f-ad88-08deb7730e73/l_onednn_p_2024.1.0.571_offline.sh", + sha256="580cb133e08b522945172a396dec9c83dd6e951602c4f36a6c346b25ab2e48c5", + expand=False, + ) version( "2024.0.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/dc309221-d210-4f3a-9406-d897df8deab8/l_onednn_p_2024.0.0.49548_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-dpct/package.py b/var/spack/repos/builtin/packages/intel-oneapi-dpct/package.py index 283076bd71c882..801512ad13f3a6 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-dpct/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-dpct/package.py @@ -19,6 +19,18 @@ class IntelOneapiDpct(IntelOneApiPackage): homepage = "https://www.intel.com/content/www/us/en/developer/tools/oneapi/dpc-compatibility-tool.html#gs.2p8km6" + version( + "2024.2.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/6b83dabd-75cf-4371-b4cd-91160175d5ff/l_dpcpp-ct_p_2024.2.0.424_offline.sh", + sha256="43a6c5fa646291ea4f8ee94e2e711ee42bbd6aff7901bda1694e1ea99e6852e2", + expand=False, + ) + version( + "2024.1.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/997fe522-cedf-46da-a54d-be4f22992fa1/l_dpcpp-ct_p_2024.1.0.378_offline.sh", + sha256="f4855ef768b9067476f0e216140c65777e301c9b32be45d9e644d54b6dc21e1b", + expand=False, + ) version( "2024.0.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/6633bc4b-5356-471a-9aae-d5e63e7acd95/l_dpcpp-ct_p_2024.0.0.49394_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-dpl/package.py b/var/spack/repos/builtin/packages/intel-oneapi-dpl/package.py index f89e33b7207eae..215f464294d2bd 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-dpl/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-dpl/package.py @@ -22,6 +22,18 @@ class IntelOneapiDpl(IntelOneApiLibraryPackage): homepage = "https://github.com/oneapi-src/oneDPL" + version( + "2022.6.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/65565430-3eb6-49ad-ae51-e35314cc6f08/l_oneDPL_p_2022.6.0.560_offline.sh", + sha256="540c79d2cea77c009fd7d49d65323418aded1235afd30d91192257a2f14a366f", + expand=False, + ) + version( + "2022.5.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/d0be9e37-532e-4fde-9ac2-32c3ec5a2029/l_oneDPL_p_2022.5.0.219_offline.sh", + sha256="41a96db8adc2de60f2e8dc8b01a6f93f39dad568a46ab1699f3b4200d0acf834", + expand=False, + ) version( "2022.3.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/be027095-148a-4433-aff4-c6e8582da3ca/l_oneDPL_p_2022.3.0.49386_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-inspector/package.py b/var/spack/repos/builtin/packages/intel-oneapi-inspector/package.py index da5eb9fb77926c..42a2dbbae43e8b 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-inspector/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-inspector/package.py @@ -24,6 +24,12 @@ class IntelOneapiInspector(IntelOneApiLibraryPackageWithSdk): homepage = "https://software.intel.com/content/www/us/en/develop/tools/oneapi/components/inspector.html" + version( + "2024.1.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/891acaab-a5b4-4a3c-9f36-60dca629e410/l_inspector_oneapi_p_2024.1.0.158_offline.sh", + sha256="b4e4e2e395ad98ce025a6bf26950fc39c2f54c905a1a9c88cb129109a5dd0936", + expand=False, + ) version( "2024.0.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/44ae6846-719c-49bd-b196-b16ce5835a1e/l_inspector_oneapi_p_2024.0.0.49433_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-ipp/package.py b/var/spack/repos/builtin/packages/intel-oneapi-ipp/package.py index f6968277f5e580..aac8357a45ecbd 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-ipp/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-ipp/package.py @@ -27,6 +27,18 @@ class IntelOneapiIpp(IntelOneApiLibraryPackage): "https://software.intel.com/content/www/us/en/develop/tools/oneapi/components/ipp.html" ) + version( + "2021.12.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/ecc315bf-9e5a-4a23-b0ca-f58aea109e39/l_ipp_oneapi_p_2021.12.0.559_offline.sh", + sha256="84e4dfba142c3c629424012ad5e8e5f78d2a05983bf03cdc7e3ec6b530142d0e", + expand=False, + ) + version( + "2021.11.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/c8d09493-ca9b-45b1-b720-12b8719b4136/l_ipp_oneapi_p_2021.11.0.532_offline.sh", + sha256="42bfaf593184e3293c10e06ccc9e9781427d86a8a88e3d09f6921ffd7de24ee6", + expand=False, + ) version( "2021.10.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/2d48c7d9-e716-4c73-8fe5-77a9599a405f/l_ipp_oneapi_p_2021.10.0.670_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-ippcp/package.py b/var/spack/repos/builtin/packages/intel-oneapi-ippcp/package.py index 0772b7d087bab6..0c8f9c65999753 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-ippcp/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-ippcp/package.py @@ -28,6 +28,18 @@ class IntelOneapiIppcp(IntelOneApiLibraryPackage): "https://software.intel.com/content/www/us/en/develop/tools/oneapi/components/ipp.html" ) + version( + "2021.12.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/16cce450-2d08-474f-a783-da6061bd8de9/l_ippcp_oneapi_p_2021.12.0.472_offline.sh", + sha256="4a27c6209481b7f4b52f75660c243f0fc9884c18bda34fe8bf8493b9cfb00daa", + expand=False, + ) + version( + "2021.11.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/a28fefdf-f67e-43a9-8e42-fcccd9da1fff/l_ippcp_oneapi_p_2021.11.0.37_offline.sh", + sha256="58c2cee4bacb6a706173e0e59153f96d6686b35b7f124638a7b66c08674226ee", + expand=False, + ) version( "2021.9.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/6792a758-2d69-4ff3-ad24-233fb3bf56e4/l_ippcp_oneapi_p_2021.9.0.533_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-itac/package.py b/var/spack/repos/builtin/packages/intel-oneapi-itac/package.py index 525a8fc0480f0c..70125f5264d83e 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-itac/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-itac/package.py @@ -27,6 +27,12 @@ class IntelOneapiItac(IntelOneApiPackage): maintainers("rscohn2") + version( + "2022.1.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/644eec67-83d9-4bdd-be0d-d90587ec72ed/l_itac_oneapi_p_2022.1.0.158_offline.sh", + sha256="2a1f4be6b349d1629006ee72087b361a5f3e714bddd1ef932045d0c03c0b20e8", + expand=False, + ) version( "2022.0.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/e83526f5-7e0f-4708-9e0d-47f1e65f29aa/l_itac_oneapi_p_2022.0.0.49690_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-mkl/package.py b/var/spack/repos/builtin/packages/intel-oneapi-mkl/package.py index 48839e727dfbf9..986b584766b3f8 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-mkl/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-mkl/package.py @@ -25,6 +25,18 @@ class IntelOneapiMkl(IntelOneApiLibraryPackage): "https://software.intel.com/content/www/us/en/develop/tools/oneapi/components/onemkl.html" ) + version( + "2024.2.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/cdff21a5-6ac7-4b41-a7ec-351b5f9ce8fd/l_onemkl_p_2024.2.0.664_offline.sh", + sha256="f1f46f5352c197a9840e08fc191a879dad79ebf742fe782e386ba8006f262f7a", + expand=False, + ) + version( + "2024.1.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/2f3a5785-1c41-4f65-a2f9-ddf9e0db3ea0/l_onemkl_p_2024.1.0.695_offline.sh", + sha256="b121bc70d3493ef1fbd05f077b1cd27ac4eb2fd1099f44e9f4b8a1366995fb92", + expand=False, + ) version( "2024.0.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/86d6a4c1-c998-4c6b-9fff-ca004e9f7455/l_onemkl_p_2024.0.0.49673_offline.sh", @@ -104,6 +116,8 @@ class IntelOneapiMkl(IntelOneApiLibraryPackage): expand=False, ) + variant("gfortran", default=False, description="Compatibility with GNU Fortran") + variant("shared", default=True, description="Builds shared library") variant("ilp64", default=False, description="Build with ILP64 support") variant( @@ -139,6 +153,18 @@ class IntelOneapiMkl(IntelOneApiLibraryPackage): # cluster libraries need mpi depends_on("mpi", when="+cluster") + # If a +cluster then mpi_family must be set + with when("+cluster"): + conflicts("mpi_family=none") + requires("mpi_family=mpich", when="^intel-oneapi-mpi") + requires("mpi_family=mpich", when="^intel-mpi") + requires("mpi_family=mpich", when="^mpich") + requires("mpi_family=mpich", when="^mvapich") + requires("mpi_family=mpich", when="^mvapich2") + requires("mpi_family=mpich", when="^cray-mpich") + requires("mpi_family=openmpi", when="^openmpi") + requires("mpi_family=openmpi", when="^hpcx-mpi") + provides("fftw-api@3") provides("scalapack", when="+cluster") provides("mkl") @@ -193,7 +219,17 @@ def _find_mkl_libs(self, shared): if self.spec.satisfies("+cluster"): libs.extend([self._xlp64_lib("libmkl_scalapack"), "libmkl_cdft_core"]) - libs.append(self._xlp64_lib("libmkl_intel")) + # Explicit variant for compatibility with gfortran, otherwise + # support intel fortran. Be aware that some dependencies may + # be using this logic and other dependencies might be using + # cmake for the library list and they have to be consistent. + # https://github.com/spack/spack/pull/43673 for discussion + if self.spec.satisfies("+gfortran"): + depends_on("fortran", type="build") + libs.append(self._xlp64_lib("libmkl_gf")) + else: + libs.append(self._xlp64_lib("libmkl_intel")) + if self.spec.satisfies("threads=tbb"): libs.append("libmkl_tbb_thread") elif self.spec.satisfies("threads=openmp"): @@ -207,29 +243,10 @@ def _find_mkl_libs(self, shared): libs.append("libmkl_core") if self.spec.satisfies("+cluster"): - if any( - self.spec.satisfies(m) - for m in [ - "^intel-oneapi-mpi", - "^intel-mpi", - "^mpich", - "^cray-mpich", - "mpi_family=mpich", - ] - ): + if self.spec.satisfies("mpi_family=mpich"): libs.append(self._xlp64_lib("libmkl_blacs_intelmpi")) - elif any( - self.spec.satisfies(m) for m in ["^openmpi", "^hpcx-mpi", "mpi_family=openmpi"] - ): + elif self.spec.satisfies("mpi_family=openmpi"): libs.append(self._xlp64_lib("libmkl_blacs_openmpi")) - else: - raise RuntimeError( - ( - "intel-oneapi-mkl +cluster requires one of ^intel-oneapi-mpi, " - "^intel-mpi, ^mpich, ^cray-mpich, mpi_family=mpich, ^openmpi, " - "^hpcx-mpi, or mpi_family=openmpi" - ) - ) lib_path = ( self.component_prefix.lib if self.v2_layout else self.component_prefix.lib.intel64 diff --git a/var/spack/repos/builtin/packages/intel-oneapi-mpi/package.py b/var/spack/repos/builtin/packages/intel-oneapi-mpi/package.py index c60250f0cce3c9..867fb1440a4606 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-mpi/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-mpi/package.py @@ -21,6 +21,24 @@ class IntelOneapiMpi(IntelOneApiLibraryPackage): homepage = "https://software.intel.com/content/www/us/en/develop/tools/oneapi/components/mpi-library.html" + version( + "2021.13.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/9f84e1e8-11b2-4bd1-8512-3e3343585956/l_mpi_oneapi_p_2021.13.0.719_offline.sh", + sha256="5e23cf495c919e17032577e3059438f632297ee63f2cdb906a2547298823cc64", + expand=False, + ) + version( + "2021.12.1", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/56b2dd0e-954d-4330-b0a7-b22992f7e6b7/l_mpi_oneapi_p_2021.12.1.8_offline.sh", + sha256="6a4cd82ff1c64eac2a7ac3784ea2dc3a0e32740fb7e7bc6a1aa48740d5011b2f", + expand=False, + ) + version( + "2021.12.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/749f02a5-acb8-4bbb-91db-501ff80d3f56/l_mpi_oneapi_p_2021.12.0.538_offline.sh", + sha256="6ccfc35784ec86d898f4c1cedf82c4f71926123a12db64111f67e7d0286bbb2d", + expand=False, + ) version( "2021.11.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/2c45ede0-623c-4c8e-9e09-bed27d70fa33/l_mpi_oneapi_p_2021.11.0.49513_offline.sh", @@ -104,7 +122,12 @@ class IntelOneapiMpi(IntelOneApiLibraryPackage): variant( "generic-names", default=False, - description="Use generic names, e.g mpicc instead of mpiicc", + description="Use generic names, e.g mpicc instead of mpiicx", + ) + variant( + "classic-names", + default=False, + description="Use classic compiler names, e.g mpiicc instead of mpiicx", ) variant( "external-libfabric", default=False, description="Enable external libfabric dependency" @@ -112,6 +135,7 @@ class IntelOneapiMpi(IntelOneApiLibraryPackage): depends_on("libfabric", when="+external-libfabric", type=("link", "run")) provides("mpi@:3.1") + conflicts("+generic-names +classic-names") @property def mpiexec(self): @@ -132,38 +156,40 @@ def env_script_args(self): else: return () - def setup_dependent_package(self, module, dep_spec): + def wrapper_names(self): if "+generic-names" in self.spec: - self.spec.mpicc = join_path(self.component_prefix.bin, "mpicc") - self.spec.mpicxx = join_path(self.component_prefix.bin, "mpicxx") - self.spec.mpif77 = join_path(self.component_prefix.bin, "mpif77") - self.spec.mpifc = join_path(self.component_prefix.bin, "mpifc") + return ["mpicc", "mpicxx", "mpif77", "mpif90", "mpifc"] + elif "+classic-names" in self.spec: + return ["mpiicc", "mpiicpc", "mpiifort", "mpiifort", "mpiifort"] else: - self.spec.mpicc = join_path(self.component_prefix.bin, "mpiicc") - self.spec.mpicxx = join_path(self.component_prefix.bin, "mpiicpc") - self.spec.mpif77 = join_path(self.component_prefix.bin, "mpiifort") - self.spec.mpifc = join_path(self.component_prefix.bin, "mpiifort") + return ["mpiicx", "mpiicpx", "mpiifx", "mpiifx", "mpiifx"] + + def wrapper_paths(self): + return [self.component_prefix.bin.join(name) for name in self.wrapper_names()] + + def setup_dependent_package(self, module, dep_spec): + wrappers = self.wrapper_paths() + self.spec.mpicc = wrappers[0] + self.spec.mpicxx = wrappers[1] + self.spec.mpif77 = wrappers[2] + # no self.spec.mpif90 + self.spec.mpifc = wrappers[4] def setup_dependent_build_environment(self, env, dependent_spec): - env.set("I_MPI_CC", spack_cc) - env.set("I_MPI_CXX", spack_cxx) - env.set("I_MPI_F77", spack_f77) - env.set("I_MPI_F90", spack_fc) - env.set("I_MPI_FC", spack_fc) + dependent_module = dependent_spec.package.module + env.set("I_MPI_CC", dependent_module.spack_cc) + env.set("I_MPI_CXX", dependent_module.spack_cxx) + env.set("I_MPI_F77", dependent_module.spack_f77) + env.set("I_MPI_F90", dependent_module.spack_fc) + env.set("I_MPI_FC", dependent_module.spack_fc) # Set compiler wrappers for dependent build stage - if "+generic-names" in self.spec: - env.set("MPICC", join_path(self.component_prefix.bin, "mpicc")) - env.set("MPICXX", join_path(self.component_prefix.bin, "mpicxx")) - env.set("MPIF77", join_path(self.component_prefix.bin, "mpif77")) - env.set("MPIF90", join_path(self.component_prefix.bin, "mpif90")) - env.set("MPIFC", join_path(self.component_prefix.bin, "mpifc")) - else: - env.set("MPICC", join_path(self.component_prefix.bin, "mpiicc")) - env.set("MPICXX", join_path(self.component_prefix.bin, "mpiicpc")) - env.set("MPIF77", join_path(self.component_prefix.bin, "mpiifort")) - env.set("MPIF90", join_path(self.component_prefix.bin, "mpiifort")) - env.set("MPIFC", join_path(self.component_prefix.bin, "mpiifort")) + wrappers = self.wrapper_paths() + env.set("MPICC", wrappers[0]) + env.set("MPICXX", wrappers[1]) + env.set("MPIF77", wrappers[2]) + env.set("MPIF90", wrappers[3]) + env.set("MPIFC", wrappers[4]) env.set("I_MPI_ROOT", self.component_prefix) diff --git a/var/spack/repos/builtin/packages/intel-oneapi-runtime/package.py b/var/spack/repos/builtin/packages/intel-oneapi-runtime/package.py new file mode 100644 index 00000000000000..88e119e6979e84 --- /dev/null +++ b/var/spack/repos/builtin/packages/intel-oneapi-runtime/package.py @@ -0,0 +1,67 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os + +from llnl.util import tty + +from spack.package import * +from spack.pkg.builtin.gcc_runtime import get_elf_libraries + + +@IntelOneApiPackage.update_description +class IntelOneapiRuntime(Package): + """Package for OneAPI compiler runtime libraries redistributables.""" + + homepage = "https://software.intel.com/content/www/us/en/develop/tools/oneapi.html" + has_code = False + license("https://intel.ly/393CijO") + + maintainers("rscohn2") + + tags = ["runtime"] + + requires("%oneapi") + + depends_on("gcc-runtime", type="link") + + LIBRARIES = [ + "imf", + "intlc", + "irng", + "svml", + "ifcore", # Fortran + "ifcoremt", # Fortran + "ifport", # Fortran + "iomp5", + "sycl", + ] + + # libifcore ABI + provides("fortran-rt", "libifcore@5", when="%oneapi@2021:") + provides("sycl") + + conflicts("platform=windows", msg="IntelOneAPI can only be installed on Linux, and FreeBSD") + conflicts("platform=darwin", msg="IntelOneAPI can only be installed on Linux, and FreeBSD") + + depends_on("libc", type="link", when="platform=linux") + + def install(self, spec, prefix): + libraries = get_elf_libraries(compiler=self.compiler, libraries=self.LIBRARIES) + mkdir(prefix.lib) + + if not libraries: + tty.warn("Could not detect any shared OneAPI runtime libraries") + return + + for path, name in libraries: + install(path, os.path.join(prefix.lib, name)) + + @property + def libs(self): + return LibraryList([]) + + @property + def headers(self): + return HeaderList([]) diff --git a/var/spack/repos/builtin/packages/intel-oneapi-tbb/package.py b/var/spack/repos/builtin/packages/intel-oneapi-tbb/package.py index 15e1861b4d7cec..5fbba70f83b35a 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-tbb/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-tbb/package.py @@ -22,6 +22,18 @@ class IntelOneapiTbb(IntelOneApiLibraryPackage): "https://software.intel.com/content/www/us/en/develop/tools/oneapi/components/onetbb.html" ) + version( + "2021.13.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/d6b5327e-f2fd-4c90-966a-d7a0e1376686/l_tbb_oneapi_p_2021.13.0.629_offline.sh", + sha256="f16586e5d8c479d05662359c95c6720445e95a21443f3979c9321d154947ca99", + expand=False, + ) + version( + "2021.12.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/b31f6b79-10aa-4119-a437-48fe2775633b/l_tbb_oneapi_p_2021.12.0.499_offline.sh", + sha256="13e981cb4d9d3f72058cc136f8cdedf6ba9af225ae317f91b59e2050b0d49e43", + expand=False, + ) version( "2021.11.0", url="https://registrationcenter-download.intel.com/akdlm//IRC_NAS/af3ad519-4c87-4534-87cb-5c7bda12754e/l_tbb_oneapi_p_2021.11.0.49527_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-oneapi-vtune/package.py b/var/spack/repos/builtin/packages/intel-oneapi-vtune/package.py index 66646c7d606b59..69df769849172b 100644 --- a/var/spack/repos/builtin/packages/intel-oneapi-vtune/package.py +++ b/var/spack/repos/builtin/packages/intel-oneapi-vtune/package.py @@ -25,6 +25,18 @@ class IntelOneapiVtune(IntelOneApiLibraryPackageWithSdk): homepage = "https://software.intel.com/content/www/us/en/develop/tools/oneapi/components/vtune-profiler.html" + version( + "2024.2.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/3ffac886-6281-46d7-8704-7aab66705926/l_oneapi_vtune_p_2024.2.0.708_offline.sh", + sha256="a0b6be945d54ec5b8f3f4edf3ca9d0027df3fd1f139c266f29f8d2c6f1608562", + expand=False, + ) + version( + "2024.1.0", + url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/671388a1-607e-463c-8d91-db4eebc2e8d2/l_oneapi_vtune_p_2024.1.0.519_offline.sh", + sha256="d92fa6eb8470f8f8a262ae6f825f1a2a80bd11591bde40c1ebe7fb92affbc682", + expand=False, + ) version( "2024.0.1", url="https://registrationcenter-download.intel.com/akdlm/IRC_NAS/56d0db2b-1ff1-4abe-857a-72ca9be22bd3/l_oneapi_vtune_p_2024.0.1.14_offline.sh", diff --git a/var/spack/repos/builtin/packages/intel-parallel-studio/package.py b/var/spack/repos/builtin/packages/intel-parallel-studio/package.py index b6ab4e405e094f..5a64a758202808 100644 --- a/var/spack/repos/builtin/packages/intel-parallel-studio/package.py +++ b/var/spack/repos/builtin/packages/intel-parallel-studio/package.py @@ -666,19 +666,21 @@ class IntelParallelStudio(IntelPackage): msg="SSE3 is not supported on MacOS x86_64", ) - def setup_dependent_build_environment(self, *args): + def setup_dependent_build_environment(self, env, dependent_spec): # Handle in callback, conveying client's compilers in additional arg. # CAUTION - DUP code in: # ../intel-mpi/package.py # ../intel-parallel-studio/package.py + dependent_module = dependent_spec.package.module self._setup_dependent_env_callback( - *args, + env, + dependent_spec, compilers_of_client={ - "CC": spack_cc, - "CXX": spack_cxx, - "F77": spack_f77, - "F90": spack_fc, - "FC": spack_fc, + "CC": dependent_module.spack_cc, + "CXX": dependent_module.spack_cxx, + "F77": dependent_module.spack_f77, + "F90": dependent_module.spack_fc, + "FC": dependent_module.spack_fc, }, ) diff --git a/var/spack/repos/builtin/packages/intel-pin/package.py b/var/spack/repos/builtin/packages/intel-pin/package.py index 6cf07b72579dca..c884312358427f 100644 --- a/var/spack/repos/builtin/packages/intel-pin/package.py +++ b/var/spack/repos/builtin/packages/intel-pin/package.py @@ -114,6 +114,9 @@ class IntelPin(Package): url="https://software.intel.com/sites/landingpage/pintool/downloads/pin-2.14-71313-gcc.4.4.7-linux.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): install_tree(".", prefix) mkdir(prefix.bin) diff --git a/var/spack/repos/builtin/packages/intel-tbb/package.py b/var/spack/repos/builtin/packages/intel-tbb/package.py index deda008f6b70f2..7e1bff25abb04a 100644 --- a/var/spack/repos/builtin/packages/intel-tbb/package.py +++ b/var/spack/repos/builtin/packages/intel-tbb/package.py @@ -33,6 +33,9 @@ class IntelTbb(CMakePackage, MakefilePackage): license("Apache-2.0") version("master", branch="master") + version("2021.12.0", sha256="c7bb7aa69c254d91b8f0041a71c5bcc3936acb64408a1719aec0b2b7639dd84f") + version("2021.11.0", sha256="782ce0cab62df9ea125cdea253a50534862b563f1d85d4cda7ad4e77550ac363") + version("2021.10.0", sha256="487023a955e5a3cc6d3a0d5f89179f9b6c0ae7222613a7185b0227ba0c83700b") version("2021.9.0", sha256="1ce48f34dada7837f510735ff1172f6e2c261b09460e3bf773b49791d247d24e") version("2021.8.0", sha256="eee380323bb7ce864355ed9431f85c43955faaae9e9bce35c62b372d7ffd9f8b") version("2021.7.0", sha256="2cae2a80cda7d45dc7c072e4295c675fff5ad8316691f26f40539f7e7e54c0cc") @@ -80,6 +83,9 @@ class IntelTbb(CMakePackage, MakefilePackage): version("4.4.1", sha256="05737bf6dd220b31aad63d77ca59c742271f81b4cc6643aa6f93d37450ae32b5") version("4.4", sha256="93c74b6054c69c86fa49d0fce7c50061fc907cb198a7237b8dd058298fd40c0e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_system( conditional("makefile", when="@:2020.3"), conditional("cmake", when="@2021:"), @@ -127,7 +133,7 @@ class IntelTbb(CMakePackage, MakefilePackage): patch("gcc_generic-pedantic-4.4.patch", level=1, when="@:2019.0") # Patch and conflicts for GCC 13 support (#1031). - patch("gcc_13-2021-v2.patch", when="@2021.1:") + patch("gcc_13-2021-v2.patch", when="@2021.1:2021.9") conflicts("%gcc@13", when="@:2021.3") # Patch cmakeConfig.cmake.in to find the libraries where we install them. @@ -199,8 +205,9 @@ def cmake_args(self): options = [ self.define("CMAKE_HWLOC_2_INCLUDE_PATH", spec["hwloc"].prefix.include), self.define("CMAKE_HWLOC_2_LIBRARY_PATH", spec["hwloc"].libs), - self.define("-DTBB_CPF", True), + self.define("TBB_CPF", True), self.define("TBB_STRICT", False), + self.define("TBB_TEST", False), ] if spec.variants["cxxstd"].value != "default": options.append(self.define("CMAKE_CXX_STANDARD", spec.variants["cxxstd"].value)) diff --git a/var/spack/repos/builtin/packages/intel-xed/package.py b/var/spack/repos/builtin/packages/intel-xed/package.py index 3e21a6e28dc9dc..7ed44861534956 100644 --- a/var/spack/repos/builtin/packages/intel-xed/package.py +++ b/var/spack/repos/builtin/packages/intel-xed/package.py @@ -35,6 +35,9 @@ class IntelXed(Package): # The old 2019.03.01 version (before there were tags). version("10.2019.03", commit="b7231de4c808db821d64f4018d15412640c34113", deprecated=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # XED wants the mbuild directory adjacent to xed in the same directory. mdir = join_path("..", "mbuild") diff --git a/var/spack/repos/builtin/packages/intel/detection_test.yaml b/var/spack/repos/builtin/packages/intel/detection_test.yaml index 076bfeaabac3bd..dfff8fa4a133b1 100644 --- a/var/spack/repos/builtin/packages/intel/detection_test.yaml +++ b/var/spack/repos/builtin/packages/intel/detection_test.yaml @@ -1,19 +1,25 @@ paths: - - layout: - - executables: - - "bin/intel64/icc" - script: | - echo "icc (ICC) 18.0.5 20180823" - echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." - - executables: - - "bin/intel64/icpc" - script: | - echo "icpc (ICC) 18.0.5 20180823" - echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." - - executables: - - "bin/intel64/ifort" - script: | - echo "ifort (IFORT) 18.0.5 20180823" - echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." - results: - - spec: 'intel@18.0.5' +- layout: + - executables: + - "bin/intel64/icc" + script: | + echo "icc (ICC) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + - executables: + - "bin/intel64/icpc" + script: | + echo "icpc (ICC) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + - executables: + - "bin/intel64/ifort" + script: | + echo "ifort (IFORT) 18.0.5 20180823" + echo "Copyright (C) 1985-2018 Intel Corporation. All rights reserved." + platforms: ["darwin", "linux"] + results: + - spec: 'intel@18.0.5' + extra_attributes: + compilers: + c: ".*/bin/intel64/icc" + cxx: ".*/bin/intel64/icpc" + fortran: ".*/bin/intel64/ifort" diff --git a/var/spack/repos/builtin/packages/interproscan/package.py b/var/spack/repos/builtin/packages/interproscan/package.py index 2af5c6e4016191..6088b12c38dff9 100644 --- a/var/spack/repos/builtin/packages/interproscan/package.py +++ b/var/spack/repos/builtin/packages/interproscan/package.py @@ -32,6 +32,9 @@ class Interproscan(Package): url="ftp://ftp.ebi.ac.uk/pub/software/unix/iprscan/4/RELEASE/4.8/iprscan_v4.8.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + resource( when="@5.63-95.0 +databases", name="databases", diff --git a/var/spack/repos/builtin/packages/ioapi/package.py b/var/spack/repos/builtin/packages/ioapi/package.py index fcc640734ecfd0..2f7398075afc46 100644 --- a/var/spack/repos/builtin/packages/ioapi/package.py +++ b/var/spack/repos/builtin/packages/ioapi/package.py @@ -20,6 +20,9 @@ class Ioapi(MakefilePackage): # source tarball (#28247). This also means that one must test for breaking # changes when updating the checksum and avoid #22633. version("3.2", sha256="0a3cbf236ffbd9fb5f6509e35308c3353f1f53096efe0c51b84883d2da86924b") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated depends_on("netcdf-c@4:") depends_on("netcdf-fortran@4:") depends_on("sed", type="build") diff --git a/var/spack/repos/builtin/packages/ior/package.py b/var/spack/repos/builtin/packages/ior/package.py index 66fbd5701b515e..d8bb3f97e968d8 100644 --- a/var/spack/repos/builtin/packages/ior/package.py +++ b/var/spack/repos/builtin/packages/ior/package.py @@ -25,6 +25,8 @@ class Ior(AutotoolsPackage): version("3.2.0", sha256="91a766fb9c34b5780705d0997b71b236a1120da46652763ba11d9a8c44251852") version("3.0.1", sha256="0cbefbcdb02fb13ba364e102f9e7cc2dcf761698533dac25de446a3a3e81390d") + depends_on("c", type="build") # generated + variant("hdf5", default=False, description="support IO with HDF5 backend") variant("ncmpi", default=False, description="support IO with NCMPI backend") variant("lustre", default=False, description="support configurable Lustre striping values") diff --git a/var/spack/repos/builtin/packages/iozone/package.py b/var/spack/repos/builtin/packages/iozone/package.py index 86b31db056a584..25b557095fc850 100644 --- a/var/spack/repos/builtin/packages/iozone/package.py +++ b/var/spack/repos/builtin/packages/iozone/package.py @@ -22,6 +22,8 @@ class Iozone(MakefilePackage): version("3_491", sha256="2cc4842d382e46a585d1df9ae1e255695480dcc0fc05c3b1cb32ef3493d0ec9a") version("3_465", sha256="2e3d72916e7d7340a7c505fc0c3d28553fcc5ff2daf41d811368e55bd4e6a293") + depends_on("c", type="build") # generated + # TODO: Add support for other architectures as necessary build_targets = ["linux-AMD64"] diff --git a/var/spack/repos/builtin/packages/ip/package.py b/var/spack/repos/builtin/packages/ip/package.py index b0b9c844ff3f6a..8e309ae3a7316d 100644 --- a/var/spack/repos/builtin/packages/ip/package.py +++ b/var/spack/repos/builtin/packages/ip/package.py @@ -32,6 +32,9 @@ class Ip(CMakePackage): preferred=True, ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", description="Enable OpenMP threading", default=True) variant("pic", default=True, description="Build with position-independent-code") variant("shared", default=False, description="Build shared library", when="@4.1:") diff --git a/var/spack/repos/builtin/packages/ip2/package.py b/var/spack/repos/builtin/packages/ip2/package.py index 92640926706500..7b7bd68ed4e5c6 100644 --- a/var/spack/repos/builtin/packages/ip2/package.py +++ b/var/spack/repos/builtin/packages/ip2/package.py @@ -19,9 +19,17 @@ class Ip2(CMakePackage): maintainers("t-brown", "AlexanderRichert-NOAA", "Hang-Lei-NOAA", "edwardhartnett") - version("1.1.2", sha256="73c6beec8fd463ec7ccba3633d8c5d53d385c43d507367efde918c2db0af42ab") + version( + "1.1.2", + sha256="73c6beec8fd463ec7ccba3633d8c5d53d385c43d507367efde918c2db0af42ab", + deprecated=True, + ) + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated depends_on("sp") + requires("^sp precision=4,8,d", when="^sp@2.4:") def setup_run_environment(self, env): for suffix in ("4", "8", "d"): diff --git a/var/spack/repos/builtin/packages/ipcalc/package.py b/var/spack/repos/builtin/packages/ipcalc/package.py index 06fa24b10abc9f..0e8fbadd3052a7 100644 --- a/var/spack/repos/builtin/packages/ipcalc/package.py +++ b/var/spack/repos/builtin/packages/ipcalc/package.py @@ -21,6 +21,8 @@ class Ipcalc(MakefilePackage): version("0.2.2", sha256="bf1b95eca219e564c85fa4233fe65342963cf3e8a303a7e10b4dd7269c864794") version("0.2.0", sha256="c965c1296172a6acc50d54dfe81f7e5d589f9762b5d9ae459eee00349675336b") + depends_on("c", type="build") # generated + depends_on("geoip-api-c") def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/iperf2/package.py b/var/spack/repos/builtin/packages/iperf2/package.py index 81970527e4dbfc..6d7379ee50a7f2 100644 --- a/var/spack/repos/builtin/packages/iperf2/package.py +++ b/var/spack/repos/builtin/packages/iperf2/package.py @@ -18,3 +18,6 @@ class Iperf2(AutotoolsPackage, SourceforgePackage): version("2.1.8", sha256="8e2cf2fbc9d0d4d1cf9d109b1e328459f9622993dc9a4c5a7dc8a2088fb7beaf") version("2.1.7", sha256="1aba2e1d7aa43641ef841951ed88e16cffba898460e0c51e6b2806f3ff20e9d4") version("2.0.12", sha256="367f651fb1264b13f6518e41b8a7e08ce3e41b2a1c80e99ff0347561eed32646") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/iperf3/package.py b/var/spack/repos/builtin/packages/iperf3/package.py index aaaf24f5456296..a1f8991ca57458 100644 --- a/var/spack/repos/builtin/packages/iperf3/package.py +++ b/var/spack/repos/builtin/packages/iperf3/package.py @@ -12,8 +12,16 @@ class Iperf3(AutotoolsPackage): maintained project.""" homepage = "https://software.es.net/iperf/" - url = "https://github.com/esnet/iperf/archive/3.6.tar.gz" + url = "https://downloads.es.net/pub/iperf/iperf-3.17.tar.gz" license("BSD-3-Clause-LBNL") - version("3.6", sha256="1ad23f70a8eb4b892a3cbb247cafa956e0f5c7d8b8601b1d9c8031c2a806f23f") + version("3.17.1", sha256="84404ca8431b595e86c473d8f23d8bb102810001f15feaf610effd3b318788aa") + version("3.17", sha256="077ede831b11b733ecf8b273abd97f9630fd7448d3ec1eaa789f396d82c8c943") + version("3.16", sha256="cc740c6bbea104398cc3e466befc515a25896ec85e44a662d5f4a767b9cf713e") + version("3.14", sha256="723fcc430a027bc6952628fa2a3ac77584a1d0bd328275e573fc9b206c155004") + version("3.12", sha256="72034ecfb6a7d6d67e384e19fb6efff3236ca4f7ed4c518d7db649c447e1ffd6") + version("3.9", sha256="24b63a26382325f759f11d421779a937b63ca1bc17c44587d2fcfedab60ac038") + version("3.6", sha256="de5d51e46dc460cc590fb4d44f95e7cad54b74fea1eba7d6ebd6f8887d75946e") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/ipm/package.py b/var/spack/repos/builtin/packages/ipm/package.py index 1c8a18ea59293b..f522fb7296963c 100644 --- a/var/spack/repos/builtin/packages/ipm/package.py +++ b/var/spack/repos/builtin/packages/ipm/package.py @@ -23,6 +23,10 @@ class Ipm(AutotoolsPackage): version("master", branch="master", preferred=True) version("2.0.6", tag="2.0.6", commit="b008141ee16d39b33e20bffde615564afa107575") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("papi", default=False, description="Enable PAPI") variant("cuda", default=False, description="Enable CUDA") variant("libunwind", default=False, description="Enable libunwind") diff --git a/var/spack/repos/builtin/packages/ipopt/package.py b/var/spack/repos/builtin/packages/ipopt/package.py index b5fc7b0cc7ef8d..39f63123bef358 100644 --- a/var/spack/repos/builtin/packages/ipopt/package.py +++ b/var/spack/repos/builtin/packages/ipopt/package.py @@ -43,6 +43,10 @@ class Ipopt(AutotoolsPackage): version("3.12.1", sha256="bde8c415136bb38d5a3c5935757399760c6cabf67e9362702e59ab6027f030ec") version("3.12.0", sha256="b42f44eb53540205ede4584cced5d88a7b3ec2f1fac6e173a105496307e273a0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("coinhsl", default=False, description="Build with Coin Harwell Subroutine Libraries") variant("metis", default=False, description="Build with METIS partitioning support") variant("debug", default=False, description="Build debug instead of optimized version") diff --git a/var/spack/repos/builtin/packages/iproute2/package.py b/var/spack/repos/builtin/packages/iproute2/package.py index 98430a131aef8e..3232bee99d2874 100644 --- a/var/spack/repos/builtin/packages/iproute2/package.py +++ b/var/spack/repos/builtin/packages/iproute2/package.py @@ -26,6 +26,8 @@ class Iproute2(AutotoolsPackage): version("5.6.0", sha256="be41c35eddb02e736a2040b66ccfacee41fe7ee454580588f8959568d8a3c5b3") version("5.5.0", sha256="5bc88876a3140f640e3318453382be5be4c673ccc17a518c05a5ce2ef9aa9a7f") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make("install", "DESTDIR={0}".format(prefix), "PREFIX=") diff --git a/var/spack/repos/builtin/packages/iptraf-ng/package.py b/var/spack/repos/builtin/packages/iptraf-ng/package.py index 4f1bb59cb0b7db..c3288c02ac79dd 100644 --- a/var/spack/repos/builtin/packages/iptraf-ng/package.py +++ b/var/spack/repos/builtin/packages/iptraf-ng/package.py @@ -18,6 +18,8 @@ class IptrafNg(MakefilePackage): version("1.2.0", sha256="9725115e501d083674d50a7686029d3a08f920abd35c9a2d4a28b5ddb782417f") version("1.1.4", sha256="16b9b05bf5d3725d86409b901696639ad46944d02de6def87b1ceae5310dd35c") + depends_on("c", type="build") # generated + depends_on("ncurses") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/iq-tree/package.py b/var/spack/repos/builtin/packages/iq-tree/package.py index 4a5bb01c25338c..15ac27772a7b40 100644 --- a/var/spack/repos/builtin/packages/iq-tree/package.py +++ b/var/spack/repos/builtin/packages/iq-tree/package.py @@ -16,6 +16,12 @@ class IqTree(CMakePackage): license("GPL-2.0-or-later") + version( + "2.3.2", tag="v2.3.1", commit="60f1aa68646ab84cc96b55a7548707adde15f47a", submodules=True + ) + version( + "2.3.1", tag="v2.3.1", commit="2914a2f7aac0a1a3c4fadde42c83e5dee315186d", submodules=True + ) version( "2.2.2.7", tag="v2.2.2.7", @@ -30,6 +36,9 @@ class IqTree(CMakePackage): ) version("1.6.12", sha256="9614092de7a157de82c9cc402b19cc8bfa0cb0ffc93b91817875c2b4bb46a284") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Enable OpenMP support.") variant("mpi", default=False, description="Enable MPI support.") variant("lsd2", default=True, description="Activate Least Squares Dating.") diff --git a/var/spack/repos/builtin/packages/iqtree2/package.py b/var/spack/repos/builtin/packages/iqtree2/package.py deleted file mode 100644 index 36b28af74f1f82..00000000000000 --- a/var/spack/repos/builtin/packages/iqtree2/package.py +++ /dev/null @@ -1,43 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - - -from spack.package import * - - -class Iqtree2(CMakePackage): - """Efficient and versatile phylogenomic software by maximum likelihood""" - - homepage = "http://www.iqtree.org" - url = "https://github.com/iqtree/iqtree2/archive/refs/tags/v2.1.2.tar.gz" - - license("GPL-2.0-or-later") - - version("2.2.2.7", sha256="407a1a56d352ba9c2152a1d708cd29db872a41c252fbdc7acd8e0de0da8af008") - version("2.2.2", sha256="2e9ce79427b140bca5f48b31fb098f394a21a7c5116bbbada1e3eabdd6efe982") - version("2.1.2", sha256="3aaf5ac7f60d852ac8b733fb82832c049ca48b7203a6a865e99c5af359fcca5a") - - variant("lsd2", default=False, description="Build with LSD2 support") - - depends_on("boost", type="link") - depends_on("eigen", type="link") - depends_on("zlib-api", type="link") - - resource( - name="lsd2-rsrc", - url="https://github.com/tothuhien/lsd2/archive/refs/tags/v.2.4.1.tar.gz", - sha256="3d0921c96edb8f30498dc8a27878a76d785516043fbede4a72eefd84b5955458", - destination="lsd2-rsrc", - when="+lsd2", - ) - - @run_before("cmake") - def expand_resource(self): - copy_tree(join_path("lsd2-rsrc", "*"), "lsd2") - - def cmake_cargs(self): - args = [self.define_from_variant("USE_LSD2", variant="lsd2")] - - return args diff --git a/var/spack/repos/builtin/packages/irep/package.py b/var/spack/repos/builtin/packages/irep/package.py index 2210f7bac5cdec..357eb3009d953f 100644 --- a/var/spack/repos/builtin/packages/irep/package.py +++ b/var/spack/repos/builtin/packages/irep/package.py @@ -20,4 +20,8 @@ class Irep(CMakePackage): version("1.0.0", sha256="b84203ac92de824dbdc672de45cfdb9609373791c4ee84a5201fa6e4ccecc1a4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("lua-lang") diff --git a/var/spack/repos/builtin/packages/isa-l-crypto/package.py b/var/spack/repos/builtin/packages/isa-l-crypto/package.py index f6aa7e762d8eae..e02d07cfa25cac 100644 --- a/var/spack/repos/builtin/packages/isa-l-crypto/package.py +++ b/var/spack/repos/builtin/packages/isa-l-crypto/package.py @@ -35,6 +35,8 @@ class IsaLCrypto(AutotoolsPackage): version("2.23.0", sha256="4827bc3e281d19a434deaa17a172f22f38c113ffc65f5df4348062165cb89eb8") version("2.22.0", sha256="c6503b455bdf0efcad74fdae4e9b30465e0e208cff2b0b34fd8f471553455527") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/isa-l/package.py b/var/spack/repos/builtin/packages/isa-l/package.py index 2d56fbcebb3cbd..3acf9c98798fca 100644 --- a/var/spack/repos/builtin/packages/isa-l/package.py +++ b/var/spack/repos/builtin/packages/isa-l/package.py @@ -38,6 +38,8 @@ class IsaL(AutotoolsPackage): version("2.26.0", sha256="938ccce1764ed8fb65a13b02295be5af9a5e0d91686efb7474bde666214153b3") version("2.25.0", sha256="302bb38bf76be632dbd338ab97efe1c84d47dbe6265ff7af8cb373f256c84b48") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/isaac-server/package.py b/var/spack/repos/builtin/packages/isaac-server/package.py index 16fc1c6b547f1c..8dcc67b2546d89 100644 --- a/var/spack/repos/builtin/packages/isaac-server/package.py +++ b/var/spack/repos/builtin/packages/isaac-server/package.py @@ -28,6 +28,8 @@ class IsaacServer(CMakePackage): version("1.3.1", sha256="7dead8f3d5467cbd2cde8187e7b860a4ab7796348895d18291f97a76e28757cf") version("1.3.0", sha256="fcf10f4738e7790ef6604e1e2cdd052a129ba4e53a439deaafa9fb2a70585574") + depends_on("cxx", type="build") # generated + # variant('gstreamer', default=False, description= \ # 'Support for RTP streams, e.g. to Twitch or Youtube') diff --git a/var/spack/repos/builtin/packages/isaac/package.py b/var/spack/repos/builtin/packages/isaac/package.py index 36e13abbe36843..8bc42c1e9401c9 100644 --- a/var/spack/repos/builtin/packages/isaac/package.py +++ b/var/spack/repos/builtin/packages/isaac/package.py @@ -28,6 +28,8 @@ class Isaac(CMakePackage): version("1.3.1", sha256="7dead8f3d5467cbd2cde8187e7b860a4ab7796348895d18291f97a76e28757cf") version("1.3.0", sha256="fcf10f4738e7790ef6604e1e2cdd052a129ba4e53a439deaafa9fb2a70585574") + depends_on("cxx", type="build") # generated + variant("cuda", default=True, description="Generate CUDA kernels for Nvidia GPUs") # variant('alpaka', default=False, # description='Generate kernels via Alpaka, for CPUs or GPUs') diff --git a/var/spack/repos/builtin/packages/isc-dhcp/package.py b/var/spack/repos/builtin/packages/isc-dhcp/package.py index 23e223acb560d2..9cfe0c22ac60a0 100644 --- a/var/spack/repos/builtin/packages/isc-dhcp/package.py +++ b/var/spack/repos/builtin/packages/isc-dhcp/package.py @@ -27,6 +27,9 @@ class IscDhcp(AutotoolsPackage): version("4.3.6", sha256="a41eaf6364f1377fe065d35671d9cf82bbbc8f21207819b2b9f33f652aec6f1b") version("4.3.5", sha256="eb95936bf15d2393c55dd505bc527d1d4408289cec5a9fa8abb99f7577e7f954") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/isescan/package.py b/var/spack/repos/builtin/packages/isescan/package.py index ea130c0e591772..d598c24b6f916e 100644 --- a/var/spack/repos/builtin/packages/isescan/package.py +++ b/var/spack/repos/builtin/packages/isescan/package.py @@ -18,6 +18,8 @@ class Isescan(Package): version("1.7.2.3", sha256="90ef6bc660e471347f65864bd3563f769ed4b79b1a932195f353c5e86351ab05") version("1.7.2.1", sha256="b971a3e86a8cddaa4bcd520ba9e75425bbe93190466f81a3791ae0cb4baf5e5d") + depends_on("c", type="build") # generated + depends_on("python@3.3.3:", type="run") depends_on("py-numpy@1.8.0:", type="run") depends_on("py-scipy@0.13.1:", type="run") diff --git a/var/spack/repos/builtin/packages/isl/package.py b/var/spack/repos/builtin/packages/isl/package.py index 22ee03755cfcab..53862f40adf5a4 100644 --- a/var/spack/repos/builtin/packages/isl/package.py +++ b/var/spack/repos/builtin/packages/isl/package.py @@ -25,6 +25,9 @@ class Isl(AutotoolsPackage): version("0.15", sha256="8ceebbf4d9a81afa2b4449113cee4b7cb14a687d7a549a963deb5e2a41458b6b") version("0.14", sha256="7e3c02ff52f8540f6a85534f54158968417fd676001651c8289c705bd0228f36") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gmp") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/iso-codes/package.py b/var/spack/repos/builtin/packages/iso-codes/package.py index 7cc06fcc2f913b..baba46db33acdb 100644 --- a/var/spack/repos/builtin/packages/iso-codes/package.py +++ b/var/spack/repos/builtin/packages/iso-codes/package.py @@ -15,6 +15,7 @@ class IsoCodes(AutotoolsPackage): license("LGPL-2.1-or-later") + version("4.16.0", sha256="d37ff1b2b76e63926e8043b42e0ff806bb4e41e2a57d93c9d4ec99c06b409530") version("4.15.0", sha256="3d50750bf1d62d83b6085f5815ceb8392df34266a15f16bcf8d4cf7eb15d245c") version("4.13.0", sha256="2d4d0e5c02327f52cf7c029202da72f2074348472c26904b7104d2be3e0750ef") version("4.3", sha256="643eb83b2d714e8650ed7112706968d057bf5b101ba71c8ef219e20f1737b141") diff --git a/var/spack/repos/builtin/packages/ispc/package.py b/var/spack/repos/builtin/packages/ispc/package.py index b2a51bed81ab7c..b15ced302a766d 100644 --- a/var/spack/repos/builtin/packages/ispc/package.py +++ b/var/spack/repos/builtin/packages/ispc/package.py @@ -43,6 +43,9 @@ class Ispc(CMakePackage): version("1.14.0", sha256="1ed72542f56738c632bb02fb0dd56ad8aec3e2487839ebbc0def8334f305a4c7") version("1.13.0", sha256="aca595508b51dd1ff065c406a3fd7c93822320c510077dd4d97a2b98a23f097a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python", type="build") depends_on("bison", type="build") depends_on("flex", type="build") diff --git a/var/spack/repos/builtin/packages/itensor/package.py b/var/spack/repos/builtin/packages/itensor/package.py index 037050af2c87e1..4efc48948abc7c 100644 --- a/var/spack/repos/builtin/packages/itensor/package.py +++ b/var/spack/repos/builtin/packages/itensor/package.py @@ -17,6 +17,7 @@ class Itensor(MakefilePackage): license("Apache-2.0") + version("3.2.0", sha256="cb2b041514857639cf9e7c326bfeef152d45228b26243dbb9d1a0f82189f1014") version("3.1.11", sha256="bc6c48d34c4d4281d15116d7d95d7e6e2b6878b9a60ce33372b8967a96826e95") version("3.1.10", sha256="68c149e23a1ab936ef8175ea11fedc0ec64031c3686ede93c3a5ab0c893774f6") version("3.1.9", sha256="4dd71b251b63fb7775ef854212df6f1d5d3ac4d6d1905dc03b1e6d2a0a620a17") @@ -33,6 +34,8 @@ class Itensor(MakefilePackage): version("3.0.0", sha256="1d249a3a6442188a9f7829b32238c1025457c2930566d134a785994b1f7c54a9") version("2.1.1", sha256="b91a67af66ed0fa7678494f3895b5d5ae7f1dc1026540689f9625f515cb7791c") + depends_on("cxx", type="build") # generated + variant("openmp", default=False, description="Enable OpenMP support.") variant("hdf5", default=False, description="Build rockstar with HDF5 support.") variant("shared", default=False, description="Also build dynamic libraries.") @@ -62,7 +65,7 @@ def edit(self, spec, prefix): copy("options.mk.sample", mf) # 1.CCCOM - ccopts = "CCCOM={0}{1}".format(spack_cxx, self.getcopts(spec)) + ccopts = f"CCCOM={spack_cxx}{self.getcopts(spec)}" filter_file(r"^CCCOM.+", ccopts, mf) # 2.BLAS/LAPACK @@ -90,7 +93,7 @@ def edit(self, spec, prefix): # 3.HDF5 if "+hdf5" in spec: - hdf5p = "HDF5_PREFIX={0}".format(spec["hdf5"].prefix.lib) + hdf5p = f"HDF5_PREFIX={spec['hdf5'].prefix.lib}" filter_file("^#HDF5.+", hdf5p, mf) # 4.openmp @@ -99,7 +102,7 @@ def edit(self, spec, prefix): filter_file("-fopenmp", self.compiler.openmp_flag, mf) # 5.prefix - filter_file(r"^PREFIX.+", "PREFIX={0}".format(os.getcwd()), mf) + filter_file(r"^PREFIX.+", f"PREFIX={os.getcwd()}", mf) # 5.shared if "+shared" in spec: @@ -111,7 +114,7 @@ def install(self, spec, prefix): copy(mf, "options.mk.build") # 1.CCCOM - ccopts = "CCCOM={0}".format(self.compiler.cxx) + ccopts = f"CCCOM={self.compiler.cxx}" ccopts += " " + " ".join(spec.compiler_flags["cxxflags"]) if spec.satisfies("%fj"): ccopts += " " + env["FCC_ENV"] @@ -125,10 +128,10 @@ def install(self, spec, prefix): filter_file(r"^BLAS_LAPACK_LIBFLAGS=", vlib, mf) # 3.prefix - filter_file(r"^PREFIX.+", "PREFIX={0}".format(prefix), mf) + filter_file(r"^PREFIX.+", f"PREFIX={prefix}", mf) # tutorial/project_template/Makefile mf2 = join_path("tutorial", "project_template", "Makefile") - filter_file(r"^LIBRARY_DIR.+", "LIBRARY_DIR={0}".format(prefix), mf2) + filter_file(r"^LIBRARY_DIR.+", f"LIBRARY_DIR={prefix}", mf2) install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/itk/package.py b/var/spack/repos/builtin/packages/itk/package.py index f5f46daa7fa853..dd3ac52049ef96 100644 --- a/var/spack/repos/builtin/packages/itk/package.py +++ b/var/spack/repos/builtin/packages/itk/package.py @@ -35,6 +35,10 @@ class Itk(CMakePackage): version("5.1.2", sha256="f1e5a78e11125348f68f655c6b89b617c3a8b2c09f710081f621054811a70c98") version("5.1.1", sha256="39e2a63840054361b728878a35b21bbe38374682ffb4b5c4f8f8f7514dedb58e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("review", default=False, description="enable modules under review") variant("rtk", default=False, description="build the RTK (Reconstruction Toolkit module") variant("minc", default=False, description="enable support for MINC files") diff --git a/var/spack/repos/builtin/packages/iwyu/package.py b/var/spack/repos/builtin/packages/iwyu/package.py index 1c28fb9e805d70..b455810bfea3b9 100644 --- a/var/spack/repos/builtin/packages/iwyu/package.py +++ b/var/spack/repos/builtin/packages/iwyu/package.py @@ -37,6 +37,9 @@ class Iwyu(CMakePackage): version("0.12", sha256="a5892fb0abccb820c394e4e245c00ef30fc94e4ae58a048b23f94047c0816025") version("0.11", sha256="2d2877726c4aed9518cbb37673ffbc2b7da9c239bf8fe29432da35c1c0ec367a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("iwyu-013-cmake.patch", when="@0.13:0.14") depends_on("llvm+clang@17.0:17", when="@0.21") diff --git a/var/spack/repos/builtin/packages/jags/package.py b/var/spack/repos/builtin/packages/jags/package.py index 8a10604d8d3963..e584ebd264588c 100644 --- a/var/spack/repos/builtin/packages/jags/package.py +++ b/var/spack/repos/builtin/packages/jags/package.py @@ -22,6 +22,10 @@ class Jags(AutotoolsPackage): version("4.3.0", sha256="8ac5dd57982bfd7d5f0ee384499d62f3e0bb35b5f1660feb368545f1186371fc") version("4.2.0", sha256="af3e9d2896d3e712f99e2a0c81091c6b08f096650af6aa9d0c631c0790409cf7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("blas") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/jali/package.py b/var/spack/repos/builtin/packages/jali/package.py index ce7b62ac54f09e..56e9d14a55f1b2 100644 --- a/var/spack/repos/builtin/packages/jali/package.py +++ b/var/spack/repos/builtin/packages/jali/package.py @@ -28,6 +28,8 @@ class Jali(CMakePackage): version("1.1.0", sha256="783dfcd6a9284af83bb380ed257fa8b0757dc2f7f9196d935eb974fb6523c644") version("1.0.5", sha256="979170615d33a7bf20c96bd4d0285e05a2bbd901164e377a8bccbd9af9463801") + depends_on("cxx", type="build") # generated + variant("mstk", default=True, description="Enable MSTK") # dependencies diff --git a/var/spack/repos/builtin/packages/jansi-native/package.py b/var/spack/repos/builtin/packages/jansi-native/package.py index 26903db65248e9..b57e73df86f4cd 100644 --- a/var/spack/repos/builtin/packages/jansi-native/package.py +++ b/var/spack/repos/builtin/packages/jansi-native/package.py @@ -18,4 +18,6 @@ class JansiNative(MavenPackage): version("1.8", sha256="053808f58495a5657c7e7f388008b02065fbbb3f231454bfcfa159adc2e2fcea") + depends_on("c", type="build") # generated + depends_on("java@8", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/jansson/package.py b/var/spack/repos/builtin/packages/jansson/package.py index 034040dcadba11..96ecf3588bb700 100644 --- a/var/spack/repos/builtin/packages/jansson/package.py +++ b/var/spack/repos/builtin/packages/jansson/package.py @@ -24,6 +24,9 @@ class Jansson(CMakePackage): version("2.10", sha256="b0a899f90ade82e42da0ecabc8af1fa296d69691e7c0786c4994fb79d4833ebb") version("2.9", sha256="952fa714b399e71c1c3aa020e32e899f290c82126ca4d0d14cff5d10af457656") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/jasper/package.py b/var/spack/repos/builtin/packages/jasper/package.py index 3158e66138cf33..5b77a1cd05f81a 100644 --- a/var/spack/repos/builtin/packages/jasper/package.py +++ b/var/spack/repos/builtin/packages/jasper/package.py @@ -3,34 +3,44 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.build_systems import autotools, cmake from spack.package import * -class Jasper(Package): +class Jasper(AutotoolsPackage, CMakePackage): """Library for manipulating JPEG-2000 images""" homepage = "https://www.ece.uvic.ca/~frodo/jasper/" url = "https://github.com/jasper-software/jasper/archive/version-2.0.32.tar.gz" + version("4.2.4", sha256="23a3d58cdeacf3abdf9fa1d81dcefee58da6ab330940790c0f27019703bfd2cd") + version("3.0.6", sha256="c79961bc00158f5b5dc5f5fcfa792fde9bebb024432689d0f9e3f95a097d0ec3") version("3.0.3", sha256="1b324f7746681f6d24d06fcf163cf3b8ae7ac320adc776c3d611b2b62c31b65f") version("2.0.32", sha256="a3583a06698a6d6106f2fc413aa42d65d86bedf9a988d60e5cfa38bf72bc64b9") version("2.0.31", sha256="d419baa2f8a6ffda18472487f6314f0f08b673204723bf11c3a1f5b3f1b8e768") version("2.0.16", sha256="f1d8b90f231184d99968f361884e2054a1714fdbbd9944ba1ae4ebdcc9bbfdb1") version("2.0.14", sha256="85266eea728f8b14365db9eaf1edc7be4c348704e562bb05095b9a077cf1a97b") - version("1.900.1", sha256="c2b03f28166f9dc8ae434918839ae9aa9962b880fcfd24eebddd0a2daeb9192c") + version( + "1.900.1", + sha256="c2b03f28166f9dc8ae434918839ae9aa9962b880fcfd24eebddd0a2daeb9192c", + deprecated=True, + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + build_system( + conditional("cmake", when="@2:"), conditional("autotools", when="@:1"), default="cmake" + ) variant("jpeg", default=True, description="Enable the use of the JPEG library") variant("opengl", default=False, description="Enable the use of the OpenGL and GLUT libraries") variant("shared", default=True, description="Enable the building of shared libraries") - variant( - "build_type", - default="Release", - description="CMake build type", - values=("Debug", "Release"), - ) - depends_on("cmake@2.8.11:", type="build", when="@2:") - depends_on("cmake@3.12:", type="build", when="@3:") + with when("build_system=cmake"): + depends_on("cmake@2.8.11:", type="build") + depends_on("cmake@3.12:", type="build", when="@3:") + depends_on("jpeg", when="+jpeg") depends_on("gl", when="+opengl") @@ -42,69 +52,22 @@ class Jasper(Package): # See: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=469786 patch("fix_alpha_channel_assert_fail.patch", when="@1.900.1") - def cmake_args(self): - spec = self.spec - args = std_cmake_args - args.append("-DJAS_ENABLE_DOC=false") - - if "+jpeg" in spec: - args.append("-DJAS_ENABLE_LIBJPEG=true") - else: - args.append("-DJAS_ENABLE_LIBJPEG=false") - - if "+opengl" in spec: - args.append("-DJAS_ENABLE_OPENGL=true") - else: - args.append("-DJAS_ENABLE_OPENGL=false") - if "+shared" in spec: - args.append("-DJAS_ENABLE_SHARED=true") - else: - args.append("-DJAS_ENABLE_SHARED=false") +class CMakeBuilder(cmake.CMakeBuilder): + def cmake_args(self): + return [ + self.define("JAS_ENABLE_DOC", False), + self.define("JAS_ENABLE_LATEX", False), + self.define_from_variant("JAS_ENABLE_LIBJPEG", "jpeg"), + self.define_from_variant("JAS_ENABLE_OPENGL", "opengl"), + self.define_from_variant("JAS_ENABLE_SHARED", "shared"), + ] - return args +class AutotoolsBuilder(autotools.AutotoolsBuilder): def configure_args(self): - spec = self.spec - args = ["--prefix={0}".format(self.prefix)] - - if "+jpeg" in spec: - args.append("--enable-libjpeg") - else: - args.append("--disable-libjpeg") - - if "+opengl" in spec: - args.append("--enable-opengl") - else: - args.append("--disable-opengl") - - if "+shared" in spec: - args.append("--enable-shared") - else: - args.append("--disable-shared") - - if "build_type=Debug" in spec: - args.append("--enable-debug") - else: - args.append("--disable-debug") - + args = [] + args.extend(self.enable_or_disable("jpeg")) + args.extend(self.enable_or_disable("opengl")) + args.extend(self.enable_or_disable("shared")) return args - - @when("@2:") - def install(self, spec, prefix): - with working_dir("spack-build", create=True): - cmake("..", *self.cmake_args()) - make() - if self.run_tests: - make("test") - make("install") - - @when("@:1") - def install(self, spec, prefix): - configure(*self.configure_args()) - make() - if self.run_tests: - make("check") - make("install") - if self.run_tests: - make("installcheck") diff --git a/var/spack/repos/builtin/packages/javafx/package.py b/var/spack/repos/builtin/packages/javafx/package.py index fe3d767c8ef12e..20e58fb5069aa8 100644 --- a/var/spack/repos/builtin/packages/javafx/package.py +++ b/var/spack/repos/builtin/packages/javafx/package.py @@ -47,6 +47,8 @@ class Javafx(Package): except KeyError: continue + skip_version_audit = ["platform=windows"] + maintainers("snehring") extends("openjdk") diff --git a/var/spack/repos/builtin/packages/jbigkit/package.py b/var/spack/repos/builtin/packages/jbigkit/package.py index 6a95bd304be4bf..9551d7b046ef43 100644 --- a/var/spack/repos/builtin/packages/jbigkit/package.py +++ b/var/spack/repos/builtin/packages/jbigkit/package.py @@ -16,6 +16,8 @@ class Jbigkit(MakefilePackage): version("2.1", sha256="de7106b6bfaf495d6865c7dd7ac6ca1381bd12e0d81405ea81e7f2167263d932") version("1.6", sha256="d841b6d0723c1082450967f3ea500be01810a34ec4a97ad10985ae7071a6150b") + depends_on("c", type="build") # generated + build_directory = "libjbig" def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/jchronoss/package.py b/var/spack/repos/builtin/packages/jchronoss/package.py index c6a991b33dd9ac..dcbf609af95de1 100644 --- a/var/spack/repos/builtin/packages/jchronoss/package.py +++ b/var/spack/repos/builtin/packages/jchronoss/package.py @@ -22,6 +22,9 @@ class Jchronoss(CMakePackage): version("1.1", sha256="e8230416c94fb58516a4b9293efd0a67edf4a37e82cfae2ced2c0af8b4615f22") version("1.0", sha256="6a92d3cf2424fc7eaaeac9bfefe395596275e552ac5660eb4543e43679586f24") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("realtime", default=False, description="Enable Real-Time support") variant("openmp", default=False, description="Enable OpenMP constructs") variant("ncurses", default=False, description="Enable ncurses-based tool") diff --git a/var/spack/repos/builtin/packages/jdk/package.py b/var/spack/repos/builtin/packages/jdk/package.py index b0bdf2e8e3721b..c699f19a102970 100644 --- a/var/spack/repos/builtin/packages/jdk/package.py +++ b/var/spack/repos/builtin/packages/jdk/package.py @@ -6,8 +6,6 @@ import os import re -import llnl.util.tty as tty - from spack.package import * from spack.util.prefix import Prefix @@ -21,96 +19,25 @@ class Jdk(Package): maintainers("justintoo") - # Oracle requires that you accept their License Agreement in order - # to access the Java packages in download.oracle.com. In order to - # automate this process, we need to utilize these additional curl - # command-line options. See: - # http://stackoverflow.com/questions/10268583/how-to-automate-download-and-installation-of-java-jdk-on-linux - fetch_options = {"cookie": "oraclelicense=accept-securebackup-cookie"} - - # To add the latest version, go to the homepage listed above, - # click "JDK Download", click "Accept License Agreement", right-click the - # Linux .tar.gz link, and select Copy Link Address. The checksum can be - # found in a link above. The build number can be deciphered from the URL. - # Alternatively, run `bin/java -version` after extracting. Replace '+' - # symbol in version with '_', otherwise it will be interpreted as a variant - version( - "14_36", - sha256="4639bbaecc9cc606f1a4b99fda1efcaefcbf57a7025b3828b095093a6c866afd", - url="https://download.oracle.com/otn-pub/java/jdk/14+36/076bab302c7b4508975440c56f6cc26a/jdk-14_linux-x64_bin.tar.gz", - ) - version( - "12.0.2_10", - sha256="2dde6fda89a4ec6e6560ed464e917861c9e40bf576e7a64856dafc55abaaff51", - url="https://download.oracle.com/otn-pub/java/jdk/12.0.2+10/e482c34c86bd4bf8b56c0b35558996b9/jdk-12.0.2_linux-x64_bin.tar.gz", - ) - version( - "12.0.1_12", - sha256="9fd6dcdaf2cfca7da59e39b009a0f5bcd53bec2fb16105f7ca8d689cdab68d75", - url="https://download.oracle.com/otn-pub/java/jdk/12.0.1+12/69cfe15208a647278a19ef0990eea691/jdk-12.0.1_linux-x64_bin.tar.gz", - ) - version( - "11.0.2_9", - sha256="7b4fd8ffcf53e9ff699d964a80e4abf9706b5bdb5644a765c2b96f99e3a2cdc8", - url="https://download.oracle.com/otn-pub/java/jdk/11.0.2+9/f51449fcd52f4d52b93a989c5c56ed3c/jdk-11.0.2_linux-x64_bin.tar.gz", - ) - version( - "11.0.1_13", - sha256="e7fd856bacad04b6dbf3606094b6a81fa9930d6dbb044bbd787be7ea93abc885", - url="https://download.oracle.com/otn-pub/java/jdk/11.0.1+13/90cf5d8f270a4347a95050320eef3fb7/jdk-11.0.1_linux-x64_bin.tar.gz", - ) - version( - "10.0.2_13", - sha256="6633c20d53c50c20835364d0f3e172e0cbbce78fff81867488f22a6298fa372b", - url="https://download.oracle.com/otn-pub/java/jdk/10.0.2+13/19aef61b38124481863b1413dce1855f/jdk-10.0.2_linux-x64_bin.tar.gz", - ) - version( - "10.0.1_10", - sha256="ae8ed645e6af38432a56a847597ac61d4283b7536688dbab44ab536199d1e5a4", - url="https://download.oracle.com/otn-pub/java/jdk/10.0.1+10/fb4372174a714e6b8c52526dc134031e/jdk-10.0.1_linux-x64_bin.tar.gz", - ) - version( - "1.8.0_241-b07", - sha256="419d32677855f676076a25aed58e79432969142bbd778ff8eb57cb618c69e8cb", - url="https://download.oracle.com/otn-pub/java/jdk/8u241-b07/1f5b5a70bf22433b84d0e960903adac8/jdk-8u241-linux-x64.tar.gz", - ) version( - "1.8.0_231-b11", - sha256="a011584a2c9378bf70c6903ef5fbf101b30b08937441dc2ec67932fb3620b2cf", - url="https://download.oracle.com/otn-pub/java/jdk/8u231-b11/5b13a193868b4bf28bcb45c792fce896/jdk-8u231-linux-x64.tar.gz", + "21.0.2", + sha256="9f1f4a7f25ef6a73255657c40a6d7714f2d269cf15fb2ff1dc9c0c8b56623a6f", + url="https://download.oracle.com/java/21/latest/jdk-21_linux-x64_bin.tar.gz", ) version( - "1.8.0_212-b10", - sha256="3160c50aa8d8e081c8c7fe0f859ea452922eca5d2ae8f8ef22011ae87e6fedfb", - url="https://download.oracle.com/otn-pub/java/jdk/8u212-b10/59066701cf1a433da9770636fbc4c9aa/jdk-8u212-linux-x64.tar.gz", - ) - version( - "1.8.0_202-b08", - sha256="9a5c32411a6a06e22b69c495b7975034409fa1652d03aeb8eb5b6f59fd4594e0", - url="https://download.oracle.com/otn-pub/java/jdk/8u202-b08/1961070e4c9b4e26a04e7f5a083f551e/jdk-8u202-linux-x64.tar.gz", - ) - version( - "1.8.0_141-b15", - sha256="041d5218fbea6cd7e81c8c15e51d0d32911573af2ed69e066787a8dc8a39ba4f", - url="https://download.oracle.com/otn-pub/java/jdk/8u141-b15/336fa29ff2bb4ef291e347e091f7f4a7/jdk-8u141-linux-x64.tar.gz", - ) - version( - "1.8.0_131-b11", - sha256="62b215bdfb48bace523723cdbb2157c665e6a25429c73828a32f00e587301236", - url="https://download.oracle.com/otn-pub/java/jdk/8u131-b11/d54c1d3a095b4ff2b6607d096fa80163/jdk-8u131-linux-x64.tar.gz", + "17.0.10", + sha256="e4fb2df9a32a876afb0a6e17f54c594c2780e18badfa2e8fc99bc2656b0a57b1", + url="https://download.oracle.com/java/17/latest/jdk-17_linux-x64_bin.tar.gz", ) - provides("java@14", when="@14.0:14") - provides("java@13", when="@13.0:13") - provides("java@12", when="@12.0:12") - provides("java@11", when="@11.0:11") - provides("java@10", when="@10.0:10") - provides("java@9", when="@9.0:9") - provides("java@8", when="@1.8.0:1.8") - provides("java@7", when="@1.7.0:1.7") + provides("java@21", when="@21") + provides("java@17", when="@17") - conflicts("target=ppc64:", msg="jdk is only available for x86_64") - conflicts("target=ppc64le:", msg="jdk is only available for x86_64") + requires("target=x86_64:", msg="binaries only availble for x86_64") + # requires("platform=linux") # bug in concretizer + conflicts("platform=windows") + conflicts("platform=darwin") + conflicts("platform=freebsd") # FIXME: # 1. `extends('java')` doesn't work, you need to use `extends('jdk')` @@ -168,46 +95,6 @@ def libs(self): return find_libraries(["libjvm"], root=self.home, recursive=True) - @run_before("install") - def macos_check(self): - if self.spec.satisfies("platform=darwin"): - msg = """\ -Spack's JDK package only supports Linux. If you need to install JDK on macOS, -manually download the .dmg from: - - {0} - -and double-click to install. Once JDK is installed, you can tell Spack where -to find it like so. To find the JDK installation directory, run: - - $ /usr/libexec/java_home - -If you have multiple versions of JDK installed, you can specify a particular -version to search for with the --version flag. To find the exact version -number, run: - - $ java -version - -If the version number contains a '+' symbol, replace it with '_', otherwise -Spack will think it is a variant. Add JDK as an external package by running: - - $ spack config edit packages - -and adding entries for each installation: - - packages: - jdk: - buildable: False - externals: - - spec: jdk@10.0.1_10 - prefix: /path/to/jdk/Home - - spec: jdk@1.7.0_45-b18 - prefix: /path/to/jdk/Home""".format( - self.homepage - ) - - tty.die(msg) - def install(self, spec, prefix): install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/jellyfish/package.py b/var/spack/repos/builtin/packages/jellyfish/package.py index 6bd9df99244fca..f20643fa8d020e 100644 --- a/var/spack/repos/builtin/packages/jellyfish/package.py +++ b/var/spack/repos/builtin/packages/jellyfish/package.py @@ -15,6 +15,7 @@ class Jellyfish(AutotoolsPackage): license("GPL-3.0-only") + version("2.3.1", sha256="ee032b57257948ca0f0610883099267572c91a635eecbd88ae5d8974c2430fcd") version("2.3.0", sha256="e195b7cf7ba42a90e5e112c0ed27894cd7ac864476dc5fb45ab169f5b930ea5a") version( "2.2.7", @@ -27,6 +28,8 @@ class Jellyfish(AutotoolsPackage): url="https://www.cbcb.umd.edu/software/jellyfish/jellyfish-1.1.11.tar.gz", ) + depends_on("cxx", type="build") # generated + depends_on("perl", when="@2.2.7:", type=("build", "run")) variant("ruby", default=False, description="Enable ruby bindings") # Info: python bindings exist, but are for python2 which is no longer supported in spack diff --git a/var/spack/repos/builtin/packages/jemalloc/package.py b/var/spack/repos/builtin/packages/jemalloc/package.py index 938e506b2ac610..e2bbecd2afac1d 100644 --- a/var/spack/repos/builtin/packages/jemalloc/package.py +++ b/var/spack/repos/builtin/packages/jemalloc/package.py @@ -26,6 +26,9 @@ class Jemalloc(AutotoolsPackage): version("4.1.0", sha256="fad06d714f72adb4265783bc169c6d98eeb032d57ba02d87d1dcb4a2d933ec8e") version("4.0.4", sha256="3fda8d8d7fcd041aa0bebbecd45c46b28873cf37bd36c56bf44961b36d0f42d0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("stats", default=False, description="Enable heap statistics") variant("prof", default=False, description="Enable heap profiling") variant( diff --git a/var/spack/repos/builtin/packages/jhpcn-df/package.py b/var/spack/repos/builtin/packages/jhpcn-df/package.py index 5f266d1936a883..5a63d2264403e5 100644 --- a/var/spack/repos/builtin/packages/jhpcn-df/package.py +++ b/var/spack/repos/builtin/packages/jhpcn-df/package.py @@ -25,6 +25,10 @@ class JhpcnDf(CMakePackage): version("1.1.0", sha256="106d99cc4faac5c76e51e8bfe3193c1d3dc91648072cf418d868ed830592b04b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("lz4", default=False, description="Enable lz4") variant("fortran", default=False, description="Enable Fortran Interface") diff --git a/var/spack/repos/builtin/packages/jimtcl/package.py b/var/spack/repos/builtin/packages/jimtcl/package.py index 35fc0ed7d09acc..b764fe7e129cd4 100644 --- a/var/spack/repos/builtin/packages/jimtcl/package.py +++ b/var/spack/repos/builtin/packages/jimtcl/package.py @@ -18,3 +18,6 @@ class Jimtcl(AutotoolsPackage): version("0.79", sha256="ab8204cd03b946f5149e1273af9c86d8e73b146084a0fbeb1d4f41a75b0b3411") version("0.78", sha256="cf801795c9fd98bfff6882c14afdf96424ba86dead58c2a4e15978b176d3e12b") version("0.77", sha256="0874c50ab932c68940c29c48c014266a322c54ff357a0919386f32cc341eb3b2") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/jogl/package.py b/var/spack/repos/builtin/packages/jogl/package.py index 0e03ff63194461..011fc980f4eca2 100644 --- a/var/spack/repos/builtin/packages/jogl/package.py +++ b/var/spack/repos/builtin/packages/jogl/package.py @@ -19,6 +19,9 @@ class Jogl(Package): version("java-11-fixes", branch="java-11-fixes", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("ant", type="build") depends_on("java", type=("build", "run")) depends_on("gluegen", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/jose/package.py b/var/spack/repos/builtin/packages/jose/package.py index 3f997647f9e7bd..c2d2df46064417 100644 --- a/var/spack/repos/builtin/packages/jose/package.py +++ b/var/spack/repos/builtin/packages/jose/package.py @@ -18,6 +18,8 @@ class Jose(AutotoolsPackage): version("9", sha256="64262b1344d92fc183f70ca93db6100cd97b3dfa7cddea1e08e8588e6cd681eb") version("8", sha256="24e3d71e3da5a7913ab3c299381d76dfde488d91cb108b1a9527454bf1e9dc51") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("jansson@2.10:") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/jpegoptim/package.py b/var/spack/repos/builtin/packages/jpegoptim/package.py index 070889c15ea9ad..802cdce85879d4 100644 --- a/var/spack/repos/builtin/packages/jpegoptim/package.py +++ b/var/spack/repos/builtin/packages/jpegoptim/package.py @@ -18,4 +18,6 @@ class Jpegoptim(AutotoolsPackage): version("1.4.5", sha256="53207f479f96c4f792b3187f31abf3534d69c88fe23720d0c23f5310c5d2b2f5") version("1.4.4", sha256="bc6b018ae8c3eb12d07596693d54243e214780a2a2303a6578747d3671f45da3") + depends_on("c", type="build") # generated + depends_on("libjpeg") diff --git a/var/spack/repos/builtin/packages/jq/package.py b/var/spack/repos/builtin/packages/jq/package.py index e0465cbb1c0c52..69886aa9b26068 100644 --- a/var/spack/repos/builtin/packages/jq/package.py +++ b/var/spack/repos/builtin/packages/jq/package.py @@ -21,6 +21,8 @@ class Jq(AutotoolsPackage): version("1.6", sha256="5de8c8e29aaa3fb9cc6b47bb27299f271354ebb72514e3accadc7d38b5bbaa72") version("1.5", sha256="c4d2bfec6436341113419debf479d833692cc5cdab7eb0326b5a4d4fbe9f493c") + depends_on("c", type="build") # generated + depends_on("oniguruma") depends_on("bison@3.0:", type="build") diff --git a/var/spack/repos/builtin/packages/json-c/package.py b/var/spack/repos/builtin/packages/json-c/package.py index c5ebb20a458fce..fbd69a01b6ac22 100644 --- a/var/spack/repos/builtin/packages/json-c/package.py +++ b/var/spack/repos/builtin/packages/json-c/package.py @@ -22,6 +22,9 @@ class JsonC(CMakePackage, AutotoolsPackage): version("0.12", sha256="000c01b2b3f82dcb4261751eb71f1b084404fb7d6a282f06074d3c17078b9f3f") version("0.11", sha256="28dfc65145dc0d4df1dfe7701ac173c4e5f9347176c8983edbfac9149494448c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_system( conditional("cmake", when="@0.14:"), conditional("autotools", when="@:0.13.1"), diff --git a/var/spack/repos/builtin/packages/json-cwx/package.py b/var/spack/repos/builtin/packages/json-cwx/package.py index b0b0091c9e903b..0ad82764b49c4f 100644 --- a/var/spack/repos/builtin/packages/json-cwx/package.py +++ b/var/spack/repos/builtin/packages/json-cwx/package.py @@ -16,6 +16,8 @@ class JsonCwx(AutotoolsPackage): version("0.12", sha256="3bfae1f23eacba53ee130dbd1a6acf617af4627a9b4e4581d64b20a99b4e2b60") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/json-fortran/package.py b/var/spack/repos/builtin/packages/json-fortran/package.py index 334cd6093ec69b..722fd2256b8a95 100644 --- a/var/spack/repos/builtin/packages/json-fortran/package.py +++ b/var/spack/repos/builtin/packages/json-fortran/package.py @@ -29,6 +29,8 @@ class JsonFortran(CMakePackage): version("7.0.0", sha256="9b5b6235489b27d572bbc7620ed8e039fa9d4d14d41b1581b279be9db499f32c") version("6.11.0", sha256="0ce38236a0debcd775108684b835f9f92ca9d6594da714c0025014fe9f03eec3") + depends_on("fortran", type="build") # generated + depends_on("cmake@2.8.8:", type="build") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/jsoncpp/package.py b/var/spack/repos/builtin/packages/jsoncpp/package.py index 8c5050761f5590..747aa8b205588a 100644 --- a/var/spack/repos/builtin/packages/jsoncpp/package.py +++ b/var/spack/repos/builtin/packages/jsoncpp/package.py @@ -35,6 +35,8 @@ class Jsoncpp(CMakePackage, MesonPackage): version("1.7.4", sha256="10dcd0677e80727e572a1e462193e51a5fde3e023b99e144b2ee1a469835f769") version("1.7.3", sha256="1cfcad14054039ba97c22531888796cb9369e6353f257aacaad34fda956ada53") + depends_on("cxx", type="build") # generated + # From 1.9.3 onwards CMAKE_CXX_STANDARD is finally set to 11. variant( "cxxstd", diff --git a/var/spack/repos/builtin/packages/jsonnet/package.py b/var/spack/repos/builtin/packages/jsonnet/package.py index e5db816c56a13d..37d7464653a084 100644 --- a/var/spack/repos/builtin/packages/jsonnet/package.py +++ b/var/spack/repos/builtin/packages/jsonnet/package.py @@ -22,6 +22,9 @@ class Jsonnet(MakefilePackage): version("0.18.0", sha256="85c240c4740f0c788c4d49f9c9c0942f5a2d1c2ae58b2c71068107bc80a3ced4") version("0.17.0", sha256="076b52edf888c01097010ad4299e3b2e7a72b60a41abbc65af364af1ed3c8dbe") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + conflicts("%gcc@:5.4.99", when="@0.18.0:") variant("python", default=False, description="Provide Python bindings for jsonnet") diff --git a/var/spack/repos/builtin/packages/jube/package.py b/var/spack/repos/builtin/packages/jube/package.py index dac82cac148734..ccd759d9667908 100644 --- a/var/spack/repos/builtin/packages/jube/package.py +++ b/var/spack/repos/builtin/packages/jube/package.py @@ -16,6 +16,16 @@ class Jube(PythonPackage): license("GPL-3.0-or-later") + version( + "2.6.1", + sha256="348ebeb4db0ea56889a5d13bf49e394fccc0992f620e8c0c61c40185db13ad64", + extension="tar.gz", + ) + version( + "2.6.0", + sha256="cc1bfa30c4a1de010c0a203c9d22ec810c5de8b76108d5a8174b395573e2ebcc", + extension="tar.gz", + ) version( "2.5.1", sha256="4c9a754b0e6f2b5e8cd0f5bd643dcfd7863a96b05cd02141d5eb301f2b89f6a3", diff --git a/var/spack/repos/builtin/packages/judy/package.py b/var/spack/repos/builtin/packages/judy/package.py index 7dec30271082b5..508b27bc5c4a4c 100644 --- a/var/spack/repos/builtin/packages/judy/package.py +++ b/var/spack/repos/builtin/packages/judy/package.py @@ -16,4 +16,6 @@ class Judy(AutotoolsPackage): version("1.0.5", sha256="d2704089f85fdb6f2cd7e77be21170ced4b4375c03ef1ad4cf1075bd414a63eb") + depends_on("c", type="build") # generated + parallel = False diff --git a/var/spack/repos/builtin/packages/julea/package.py b/var/spack/repos/builtin/packages/julea/package.py index 4d1f336fd77fa9..7c22aa696bcc8a 100644 --- a/var/spack/repos/builtin/packages/julea/package.py +++ b/var/spack/repos/builtin/packages/julea/package.py @@ -23,6 +23,9 @@ class Julea(MesonPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("hdf5", default=True, description="Enable HDF5 support") variant("leveldb", default=True, description="Enable LevelDB support") variant("lmdb", default=True, description="Enable LMDB support") diff --git a/var/spack/repos/builtin/packages/julia/julia-1.10-rm-suite-sparse-cuda-stubs.patch b/var/spack/repos/builtin/packages/julia/julia-1.10-rm-suite-sparse-cuda-stubs.patch new file mode 100644 index 00000000000000..e95b59fe3cc6d8 --- /dev/null +++ b/var/spack/repos/builtin/packages/julia/julia-1.10-rm-suite-sparse-cuda-stubs.patch @@ -0,0 +1,16 @@ +diff --git a/base/Makefile b/base/Makefile +index ad2bb6a63c..493302af78 100644 +--- a/base/Makefile ++++ b/base/Makefile +@@ -269,11 +269,9 @@ $(eval $(call symlink_system_library,LIBSUITESPARSE,libamd)) + $(eval $(call symlink_system_library,LIBSUITESPARSE,libcamd)) + $(eval $(call symlink_system_library,LIBSUITESPARSE,libccolamd)) + $(eval $(call symlink_system_library,LIBSUITESPARSE,libcholmod)) +-$(eval $(call symlink_system_library,LIBSUITESPARSE,libcholmod_cuda)) + $(eval $(call symlink_system_library,LIBSUITESPARSE,libcolamd)) + $(eval $(call symlink_system_library,LIBSUITESPARSE,libumfpack)) + $(eval $(call symlink_system_library,LIBSUITESPARSE,libspqr)) +-$(eval $(call symlink_system_library,LIBSUITESPARSE,libspqr_cuda)) + $(eval $(call symlink_system_library,LIBSUITESPARSE,libsuitesparseconfig)) + # EXCLUDED LIBRARIES (installed/used, but not vendored for use with dlopen): + # libunwind diff --git a/var/spack/repos/builtin/packages/julia/package.py b/var/spack/repos/builtin/packages/julia/package.py index 75db30d46bf325..c912c9aab4e8f7 100644 --- a/var/spack/repos/builtin/packages/julia/package.py +++ b/var/spack/repos/builtin/packages/julia/package.py @@ -26,6 +26,9 @@ class Julia(MakefilePackage): maintainers("vchuravy", "haampie", "giordano") version("master", branch="master") + version("1.10.4", sha256="c46ed8166fe860a7258d088a0add68dfdf11ad64cc4c0b1f113570862d3ef777") + version("1.10.3", sha256="b3cd34c839d25b98a162070b4e3abd5f34564ffdad13e07073be7885e5678a18") + version("1.10.2", sha256="e3d20c02975da054aeb18d32ed84c5d760d54d2563e45e25017684a5a105d185") version("1.9.3", sha256="8d7dbd8c90e71179e53838cdbe24ff40779a90d7360e29766609ed90d982081d") version("1.9.2", sha256="015438875d591372b80b09d01ba899657a6517b7c72ed41222298fef9d4ad86b") version("1.9.0", sha256="48f4c8a7d5f33d0bc6ce24226df20ab49e385c2d0c3767ec8dfdb449602095b2") @@ -46,6 +49,9 @@ class Julia(MakefilePackage): version("1.6.5", sha256="b70ae299ff6b63a9e9cbf697147a48a31b4639476d1947cb52e4201e444f23cb") version("1.6.4", sha256="a4aa921030250f58015201e28204bff604a007defc5a379a608723e6bb1808d4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("precompile", default=True, description="Improve julia startup time") variant("openlibm", default=True, description="Use openlibm instead of libm") @@ -59,9 +65,24 @@ class Julia(MakefilePackage): ) depends_on("libuv", when="@:1.7") depends_on("libuv-julia@1.42.0", when="@1.8.0:1.8.1") - depends_on("libuv-julia@1.44.2", when="@1.8.2:") + depends_on("libuv-julia@1.44.2", when="@1.8.2:1.9") + depends_on("libuv-julia@1.44.3", when="@1.10.0:") depends_on("suite-sparse@5.4:5.10", when="@1.6:1.9") + with when("@1.10.0:1.10"): + # libssh2.so.1, libpcre2-8.so.0, libmbedtls.so.14, libmbedcrypto.so.7, libmbedx509.so.1, + # libopenlibm.so.4, libblastrampoline.so.5, libgit2.so.1.6, libnghttp2.so.14, + # libcurl.so.4 + depends_on("libblastrampoline@5.8.0:5") + depends_on("libgit2@1.6.4:1.6") + depends_on("libssh2@1.11.0:1.11") + depends_on("llvm@15.0.7 +lld shlib_symbol_version=JL_LLVM_15.0") + depends_on("mbedtls@2.28.2:2.28") + depends_on("openlibm@0.8.1:0.8", when="+openlibm") + depends_on("nghttp2@1.52.0:1.52") + depends_on("curl@8.4.0:") + depends_on("suite-sparse@7.2.1") + with when("@1.9.0:1.9"): # libssh2.so.1, libpcre2-8.so.0, mbedtls.so.14, mbedcrypto.so.7, mbedx509.so.1 # openlibm.so.4, libblastrampoline.so.5, libgit2.so.1.5, libnghttp2.so.14, @@ -125,7 +146,7 @@ class Julia(MakefilePackage): "llvm", when="^llvm@12.0.1", patches=patch( - "https://raw.githubusercontent.com/spack/patches/master/julia/10cb42f80c2eaad3e9c87cb818b6676f1be26737bdf972c77392d71707386aa4.patch", + "https://raw.githubusercontent.com/spack/patches/24ff44c4c5439400747941473c0298a74c1fbcb1/julia/10cb42f80c2eaad3e9c87cb818b6676f1be26737bdf972c77392d71707386aa4.patch", sha256="10cb42f80c2eaad3e9c87cb818b6676f1be26737bdf972c77392d71707386aa4", ), ) @@ -133,7 +154,7 @@ class Julia(MakefilePackage): "llvm", when="^llvm@13.0.1", patches=patch( - "https://raw.githubusercontent.com/spack/patches/master/julia/45f72c59ae5cf45461e9cd8b224ca49b739d885c79b3786026433c6c22f83b5f.patch", + "https://raw.githubusercontent.com/spack/patches/24ff44c4c5439400747941473c0298a74c1fbcb1/julia/45f72c59ae5cf45461e9cd8b224ca49b739d885c79b3786026433c6c22f83b5f.patch", sha256="45f72c59ae5cf45461e9cd8b224ca49b739d885c79b3786026433c6c22f83b5f", ), ) @@ -141,10 +162,18 @@ class Julia(MakefilePackage): "llvm", when="^llvm@14.0.6", patches=patch( - "https://raw.githubusercontent.com/spack/patches/master/julia/f3def26930832532bbcd861d41b31ae03db993bc2b3510f89ef831a30bd3e099.patch", + "https://raw.githubusercontent.com/spack/patches/24ff44c4c5439400747941473c0298a74c1fbcb1/julia/f3def26930832532bbcd861d41b31ae03db993bc2b3510f89ef831a30bd3e099.patch", sha256="f3def26930832532bbcd861d41b31ae03db993bc2b3510f89ef831a30bd3e099", ), ) + depends_on( + "llvm", + when="^llvm@15.0.7", + patches=patch( + "https://raw.githubusercontent.com/spack/patches/24ff44c4c5439400747941473c0298a74c1fbcb1/julia/25cdc0271e7722d4a7cc6f72abcb17bfe205fc741bbe3716a21759c3eee7d32c.patch", + sha256="25cdc0271e7722d4a7cc6f72abcb17bfe205fc741bbe3716a21759c3eee7d32c", + ), + ) # Patches for libuv depends_on( @@ -234,6 +263,11 @@ class Julia(MakefilePackage): # Make sure Julia sets -DNDEBUG when including LLVM header files. patch("llvm-NDEBUG.patch", when="@1.7.0:1.7") + # suite-sparse@7.2.1 sometimes builds cuda stub libraries and Julia build + # system deals with them, but we don't compile them, so we remove the code + # which is creating symlinks to those libraries. + patch("julia-1.10-rm-suite-sparse-cuda-stubs.patch", when="@1.10.0:1.10") + def patch(self): # The system-libwhich-libblastrampoline.patch causes a rebuild of docs as it # touches the main Makefile, so we reset the a/m-time to doc/_build's. @@ -245,7 +279,7 @@ def patch(self): def setup_build_environment(self, env): # this is a bit ridiculous, but we are setting runtime linker paths to # dependencies so that libwhich can locate them. - if self.spec.satisfies("platform=linux") or self.spec.satisfies("platform=cray"): + if self.spec.satisfies("platform=linux"): linker_var = "LD_LIBRARY_PATH" elif self.spec.satisfies("platform=darwin"): linker_var = "DYLD_FALLBACK_LIBRARY_PATH" diff --git a/var/spack/repos/builtin/packages/justbuild/package.py b/var/spack/repos/builtin/packages/justbuild/package.py index 90f465933191c8..7261ed86a3f62d 100644 --- a/var/spack/repos/builtin/packages/justbuild/package.py +++ b/var/spack/repos/builtin/packages/justbuild/package.py @@ -24,6 +24,9 @@ class Justbuild(Package): license("Apache-2.0") version("master", branch="master") + version("1.3.1", tag="v1.3.1", commit="b248838ed0f01bc5824caee3a555e7fd22d5ad10") + version("1.3.0", tag="v1.3.0", commit="a7be2417f358049e6a0e28e01bc4020d8de2fdc5") + version("1.2.5", tag="v1.2.5", commit="0f7447e3f50e68ecfe00b2db06fb5f154842ac5a") version("1.2.4", tag="v1.2.4", commit="215e6afab93d28aeea54cb2c657afda0e5453307") version("1.2.3", tag="v1.2.3", commit="45e9c1c85399f00372ad8b72894979a0002d8f95") version("1.2.2", tag="v1.2.2", commit="e1ee04684c34ae30ac3c91b6753e99a81a9dc51c") @@ -33,6 +36,8 @@ class Justbuild(Package): version("1.1.2", tag="v1.1.2", commit="67b486e2ce6ab657a98b2212a9b6f68935d07a29") version("1.0.0", tag="v1.0.0", commit="c29b671f798e82ba26b5f54ebc9e24c7dcfb8166") + depends_on("cxx", type="build") # generated + depends_on("python@3:", type=("build", "run")) depends_on("wget", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/jwt-cpp/package.py b/var/spack/repos/builtin/packages/jwt-cpp/package.py index f0a97848247dc7..e0cc0a39713ee0 100644 --- a/var/spack/repos/builtin/packages/jwt-cpp/package.py +++ b/var/spack/repos/builtin/packages/jwt-cpp/package.py @@ -16,12 +16,17 @@ class JwtCpp(CMakePackage): license("MIT") + version("0.7.0", sha256="b9eb270e3ba8221e4b2bc38723c9a1cb4fa6c241a42908b9a334daff31137406") version("0.6.0", sha256="0227bd6e0356b211341075c7997c837f0b388c01379bd256aa525566a5553f03") version("0.5.2", sha256="d3188f9611597eb1bb285169879e1d87202bf10a08e4e7734c9f2097bfd4a850") version("0.5.1", sha256="d8f5ffb361824630b3b6f4aad26c730c915081071040c232ac57947d6177ef4f") version("0.5.0", sha256="079a273f070dd11213e301712319a65881e51ab81535cc436d5313191df852a2") version("0.4.0", sha256="f0dcc7b0e8bef8f9c3f434e7121f9941145042c9fe3055a5bdd709085a4f2be4") + depends_on("cxx", type="build") # generated + + # TODO: jwt-cpp>=0.5.0 has an embedded copy of picojson which can be packaged seperately + # TODO: jwt-cpp>=0.6.0 supports wolfSSL for which there is currently # no Spack recipe. variant( @@ -37,6 +42,7 @@ class JwtCpp(CMakePackage): depends_on("openssl@1.0.2:", when="@0.5.0:0.5.99 ssl=openssl") depends_on("openssl@1.0.1:", when="@0.6.0: ssl=openssl") depends_on("libressl@3:", when="@0.5.0: ssl=libressl") + depends_on("nlohmann-json", when="@0.7.0:") def cmake_args(self): spec = self.spec diff --git a/var/spack/repos/builtin/packages/jxrlib-debian/package.py b/var/spack/repos/builtin/packages/jxrlib-debian/package.py index b1c239aa37beff..9728efb5493ae7 100644 --- a/var/spack/repos/builtin/packages/jxrlib-debian/package.py +++ b/var/spack/repos/builtin/packages/jxrlib-debian/package.py @@ -24,6 +24,8 @@ class JxrlibDebian(MakefilePackage): sha256="3d9d5d6ca972b51259efe1f37a8e42892e90920b13308d70b8a24eb9a82bf34c", ) + depends_on("c", type="build") # generated + def setup_build_environment(self, env): env.set("DIR_INSTALL", self.prefix) if self.spec.satisfies("+shared"): diff --git a/var/spack/repos/builtin/packages/k8/package.py b/var/spack/repos/builtin/packages/k8/package.py index 14452606a6a38d..0448f21240fe92 100644 --- a/var/spack/repos/builtin/packages/k8/package.py +++ b/var/spack/repos/builtin/packages/k8/package.py @@ -17,6 +17,8 @@ class K8(Package): version("0.2.4", sha256="da8a99c7f1ce7f0cb23ff07ce10510e770686b906d5431442a5439743c0b3c47") + depends_on("cxx", type="build") # generated + depends_on("zlib-api", type="run") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/kadath/package.py b/var/spack/repos/builtin/packages/kadath/package.py index ec6ac84b9a861e..b77b4113b2132f 100644 --- a/var/spack/repos/builtin/packages/kadath/package.py +++ b/var/spack/repos/builtin/packages/kadath/package.py @@ -28,6 +28,8 @@ class Kadath(CMakePackage): version("fuka", branch="fuka") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant( diff --git a/var/spack/repos/builtin/packages/kahip/package.py b/var/spack/repos/builtin/packages/kahip/package.py index a623635468ffa4..6a757784c120dc 100644 --- a/var/spack/repos/builtin/packages/kahip/package.py +++ b/var/spack/repos/builtin/packages/kahip/package.py @@ -41,6 +41,9 @@ class Kahip(CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "deterministic", default=False, diff --git a/var/spack/repos/builtin/packages/kakoune-lsp/package.py b/var/spack/repos/builtin/packages/kakoune-lsp/package.py new file mode 100644 index 00000000000000..9088522449fd96 --- /dev/null +++ b/var/spack/repos/builtin/packages/kakoune-lsp/package.py @@ -0,0 +1,19 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class KakouneLsp(CargoPackage): + """Kakoune Language Server Protocol Client""" + + homepage = "https://github.com/kakoune-lsp/kakoune-lsp" + url = "https://github.com/kakoune-lsp/kakoune-lsp/archive/refs/tags/v17.0.1.tar.gz" + + maintainers("taliaferro") + + license("UNLICENSE", checked_by="taliaferro") + + version("17.0.1", sha256="c32172a7d13621d7f7fd8b32b819865fd58a38c0c431d3cedd6046fb6de42f44") diff --git a/var/spack/repos/builtin/packages/kakoune/package.py b/var/spack/repos/builtin/packages/kakoune/package.py index 345a69f3ae887e..b9aa23e04c8496 100644 --- a/var/spack/repos/builtin/packages/kakoune/package.py +++ b/var/spack/repos/builtin/packages/kakoune/package.py @@ -14,10 +14,13 @@ class Kakoune(MakefilePackage): "https://github.com/mawww/kakoune/releases/download/v2021.11.08/kakoune-2021.11.08.tar.bz2" ) - maintainers("Bambi") + maintainers("Bambi", "taliaferro") license("Unlicense") + version( + "2024.05.09", sha256="2190bddfd3af590c0593c38537088976547506f47bd6eb6c0e22350dbd16a229" + ) version( "2023.08.05", sha256="3e45151e0addd3500de2d6a29b5aacf2267c42bb256d44a782e73defb29cda5c" ) @@ -25,6 +28,8 @@ class Kakoune(MakefilePackage): "2021.11.08", sha256="aa30889d9da11331a243a8f40fe4f6a8619321b19217debac8f565e06eddb5f4" ) + depends_on("cxx", type="build") # generated + depends_on("ncurses") conflicts("%gcc@:8", when="@2021.11.08", msg="GCC version must be at least 9.0!") @@ -33,5 +38,6 @@ class Kakoune(MakefilePackage): build_targets = ["all", "man"] - def edit(self, spec, prefix): - env["PREFIX"] = prefix + @property + def install_targets(self): + return ["-e", f"PREFIX={prefix}", "install"] diff --git a/var/spack/repos/builtin/packages/kaks-calculator/package.py b/var/spack/repos/builtin/packages/kaks-calculator/package.py index c82f20469c2ecf..520a388a2b7189 100644 --- a/var/spack/repos/builtin/packages/kaks-calculator/package.py +++ b/var/spack/repos/builtin/packages/kaks-calculator/package.py @@ -17,6 +17,8 @@ class KaksCalculator(MakefilePackage, SourceforgePackage): version("2.0", sha256="e2df719a2fecc549d8ddc4e6d8f5cfa4b248282dca319c1928eaf886d68ec3c5") + depends_on("cxx", type="build") # generated + build_directory = "src" def url_for_version(self, version): diff --git a/var/spack/repos/builtin/packages/kaldi/package.py b/var/spack/repos/builtin/packages/kaldi/package.py index 576c0850da5d4f..0f115e244fffda 100644 --- a/var/spack/repos/builtin/packages/kaldi/package.py +++ b/var/spack/repos/builtin/packages/kaldi/package.py @@ -7,6 +7,8 @@ from fnmatch import fnmatch from os.path import join +from llnl.util.symlink import readlink + from spack.package import * @@ -27,6 +29,8 @@ class Kaldi(Package): # Does not use Autotools version("2018-07-11", commit="6f2140b032b0108bc313eefdca65151289642773") version("2015-10-07", commit="c024e8aa0a727bf76c91a318f76a1f8b0b59249e") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="build shared libraries") variant("double", default=False, description="build with double precision floats") variant("cuda", default=False, description="build with CUDA") @@ -105,7 +109,7 @@ def install(self, spec, prefix): for name in files: if name.endswith("." + dso_suffix): fpath = join(root, name) - src = os.readlink(fpath) + src = readlink(fpath) install(src, prefix.lib) for root, dirs, files in os.walk("."): diff --git a/var/spack/repos/builtin/packages/kalign/package.py b/var/spack/repos/builtin/packages/kalign/package.py index a4c0632c083198..f9b0895dc15ca0 100644 --- a/var/spack/repos/builtin/packages/kalign/package.py +++ b/var/spack/repos/builtin/packages/kalign/package.py @@ -17,6 +17,9 @@ class Kalign(AutotoolsPackage, CMakePackage): version("3.4.0", sha256="67d1a562d54b3b7622cc3164588c05b9e2bf8f1a5140bb48a4e816c61a87d4a8") version("3.3.1", sha256="7f10acf9a3fa15deabbc0304e7c14efa25cea39108318c9f02b47257de2d7390") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_system( conditional("cmake", when="@3.4.0:"), conditional("autotools", when="@3.3.1"), diff --git a/var/spack/repos/builtin/packages/kallisto/package.py b/var/spack/repos/builtin/packages/kallisto/package.py index a0cba6850c066f..21fbdbe7c2db3d 100644 --- a/var/spack/repos/builtin/packages/kallisto/package.py +++ b/var/spack/repos/builtin/packages/kallisto/package.py @@ -15,12 +15,17 @@ class Kallisto(CMakePackage): license("BSD-2-Clause") + version("0.50.1", sha256="030752bab3b0e33cd3f23f6d8feddd74194e5513532ffbf23519e84db2a86d34") version("0.48.0", sha256="1797ac4d1f0771e3f1f25dd7972bded735fcb43f853cf52184d3d9353a6269b0") version("0.46.2", sha256="c447ca8ddc40fcbd7d877d7c868bc8b72807aa8823a8a8d659e19bdd515baaf2") version("0.43.1", sha256="7baef1b3b67bcf81dc7c604db2ef30f5520b48d532bf28ec26331cb60ce69400") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # HDF5 support is optional beginning with version 0.46.2. variant("hdf5", when="@0.46.2:", default=False, description="Build with HDF5 support") + variant("bam", when="@0.50.1:", default=False, description="Build with htslib support") depends_on("zlib-api") depends_on("hdf5", when="@:0.43") @@ -38,7 +43,7 @@ class Kallisto(CMakePackage): patch("link_zlib.patch", when="@:0.43") patch("limits.patch", when="@:0.46") - patch("htslib_configure.patch", when="@0.44.0:^autoconf@2.70:") + patch("htslib_configure.patch", when="@0.44.0:0.48.0^autoconf@2.70:") @run_before("cmake") def autoreconf(self): @@ -54,17 +59,9 @@ def autoreconf(self): # configure script. # See https://github.com/spack/spack/issues/15274 and # https://github.com/pachterlab/kallisto/issues/253 - @property - def std_cmake_args(self): - """Call the original std_cmake_args and then filter the verbose - setting. - """ - a = super().std_cmake_args - if self.spec.satisfies("@0.44.0:"): - args = [i for i in a if i != "-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON"] - if self.spec.satisfies("@0.46.2:"): - args.append(self.define_from_variant("USE_HDF5", "hdf5")) - else: - args = a - - return args + def cmake_args(self): + return [ + self.define("CMAKE_VERBOSE_MAKEFILE", False), + self.define_from_variant("USE_HDF5", "hdf5"), + self.define_from_variant("USE_BAM", "bam"), + ] diff --git a/var/spack/repos/builtin/packages/kassiopeia/package.py b/var/spack/repos/builtin/packages/kassiopeia/package.py index 17adf4970f587b..e6912a446c1758 100644 --- a/var/spack/repos/builtin/packages/kassiopeia/package.py +++ b/var/spack/repos/builtin/packages/kassiopeia/package.py @@ -32,6 +32,9 @@ class Kassiopeia(CMakePackage): version("3.5.0", sha256="b704d77bd182b2806dc8323f642d3197ce21dba3d456430f594b19a7596bda22") version("3.4.0", sha256="4e2bca61011e670186d49048aea080a06c3c95dacf4b79e7549c36960b4557f4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("root", default=False, description="Include support for writing ROOT files") variant("vtk", default=False, description="Include visualization support through VTK") variant("mpi", default=False, description="Include MPI support for field calculations") diff --git a/var/spack/repos/builtin/packages/kbd/package.py b/var/spack/repos/builtin/packages/kbd/package.py index 561f5ae57bc35e..991bdad6d80be5 100644 --- a/var/spack/repos/builtin/packages/kbd/package.py +++ b/var/spack/repos/builtin/packages/kbd/package.py @@ -20,6 +20,8 @@ class Kbd(AutotoolsPackage): version("2.2.90", sha256="a310a915f474c85ee28cd860677a34a529aca940daa44634a428dd6df58c196e") version("2.2.0", sha256="5dec023c7a05b4d11d8ae795f59fab2b0bacfcc5c20a3d534dc7566cfe47ccf7") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/kcov/package.py b/var/spack/repos/builtin/packages/kcov/package.py index f0cfb30ec95ef1..4bf45f3f9883af 100644 --- a/var/spack/repos/builtin/packages/kcov/package.py +++ b/var/spack/repos/builtin/packages/kcov/package.py @@ -12,11 +12,20 @@ class Kcov(CMakePackage): compilation options""" homepage = "https://simonkagstrom.github.io/kcov/index.html" - url = "https://github.com/SimonKagstrom/kcov/archive/38.tar.gz" + url = "https://github.com/SimonKagstrom/kcov/archive/refs/tags/v42.tar.gz" license("GPL-2.0-or-later") - version("38", sha256="b37af60d81a9b1e3b140f9473bdcb7975af12040feb24cc666f9bb2bb0be68b4") + version("42", sha256="2c47d75397af248bc387f60cdd79180763e1f88f3dd71c94bb52478f8e74a1f8") + version( + "38", + sha256="b37af60d81a9b1e3b140f9473bdcb7975af12040feb24cc666f9bb2bb0be68b4", + url="https://github.com/SimonKagstrom/kcov/archive/38.tar.gz", + deprecated=True, + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("cmake@2.8.4:", type="build") depends_on("zlib-api") @@ -29,9 +38,13 @@ def cmake_args(self): # https://github.com/Homebrew/homebrew-core/blob/master/Formula/kcov.rb return ["-DSPECIFY_RPATH=ON"] - @run_after("install") - @on_package_attributes(run_tests=True) - def test_install(self): - # The help message exits with an exit code of 1 + def test_kcov_help(self): + """run installed kcov help""" kcov = Executable(self.prefix.bin.kcov) + # The help message exits with an exit code of 1 kcov("-h", ignore_errors=1) + + @run_after("install") + @on_package_attributes(run_tests=True) + def check_install(self): + self.test_kcov_help() diff --git a/var/spack/repos/builtin/packages/kdiff3/package.py b/var/spack/repos/builtin/packages/kdiff3/package.py index 3dc83d23b0c05d..931bae44f6f987 100644 --- a/var/spack/repos/builtin/packages/kdiff3/package.py +++ b/var/spack/repos/builtin/packages/kdiff3/package.py @@ -16,6 +16,8 @@ class Kdiff3(Package): version("0.9.98", sha256="802c1ababa02b403a5dca15955c01592997116a24909745016931537210fd668") + depends_on("cxx", type="build") # generated + depends_on("qt@:4,5.2.0:") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/kea/package.py b/var/spack/repos/builtin/packages/kea/package.py index 58d7e5e5fa868e..1adaa997a5481b 100644 --- a/var/spack/repos/builtin/packages/kea/package.py +++ b/var/spack/repos/builtin/packages/kea/package.py @@ -17,6 +17,8 @@ class Kea(AutotoolsPackage): version("1.6.2", sha256="2af7336027143c3e98d8d1d44165b2c2cbb0252a92bd88f6dd4d2c6adb69d7b5") + depends_on("cxx", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/kealib/package.py b/var/spack/repos/builtin/packages/kealib/package.py index f7691cfc83848e..2939c85d73bced 100644 --- a/var/spack/repos/builtin/packages/kealib/package.py +++ b/var/spack/repos/builtin/packages/kealib/package.py @@ -44,6 +44,8 @@ class Kealib(CMakePackage): version("1.4.8", sha256="0f24d8478865abcb17865c8f49c0370095726c529b8ac373ffae018ad3d40a02") version("1.4.7", sha256="ec38751b3b555d3a26f0c7445f2d2cd9d7c3a3502237519a206a50cb58df56ec") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.5:", type="build") depends_on("hdf5+cxx+hl", when="@:1.5.1") depends_on("hdf5+cxx", when="@1.5.2:") diff --git a/var/spack/repos/builtin/packages/keepalived/package.py b/var/spack/repos/builtin/packages/keepalived/package.py index e7f2333d1d7de8..757111350a1cf4 100644 --- a/var/spack/repos/builtin/packages/keepalived/package.py +++ b/var/spack/repos/builtin/packages/keepalived/package.py @@ -27,6 +27,8 @@ class Keepalived(AutotoolsPackage): version("2.0.12", sha256="fd50e433d784cfd948de5726752cf89ab7001f587fe10a5110c6c7cbda4b7b5e") version("2.0.11", sha256="a298b0c02a20959cfc365b62c14f45abd50d5e0595b2869f5bce10ec2392fa48") + depends_on("c", type="build") # generated + depends_on("openssl") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/keepassxc/package.py b/var/spack/repos/builtin/packages/keepassxc/package.py index 6c2a430ec878c3..455bf1841b69f1 100644 --- a/var/spack/repos/builtin/packages/keepassxc/package.py +++ b/var/spack/repos/builtin/packages/keepassxc/package.py @@ -18,12 +18,16 @@ class Keepassxc(CMakePackage): license("GPL-2.0-only OR GPL-3.0-only") version("master", branch="master") + version("2.7.7", sha256="58fc45ae98e4b3ffb052103014f5b97a41fefd17102c7f56073934dd3a82ee67") version("2.7.6", sha256="a58074509fa8e90f152c6247f73e75e126303081f55eedb4ea0cbb6fa980d670") version("2.7.1", sha256="6001ba626c35c316dbda6de35736f012a2264f95139fcb4a094b8eb49b15d3e7") version("2.7.0", sha256="83be76890904cd6703343fa097d68bcfdd99bb525cf518fa62a7df9293026aa7") version("2.6.6", sha256="3603b11ac39b289c47fac77fa150e05fd64b393d8cfdf5732dc3ef106650a4e2") version("2.6.4", sha256="e536e2a71c90fcf264eb831fb1a8b518ee1b03829828f862eeea748d3310f82b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("autotype", default=False, description="enable auto-type") variant("docs", default=True, description="Build documentation") diff --git a/var/spack/repos/builtin/packages/kentutils/fix-mysql-options-gcc13.patch b/var/spack/repos/builtin/packages/kentutils/fix-mysql-options-gcc13.patch new file mode 100644 index 00000000000000..f0a799d3060f85 --- /dev/null +++ b/var/spack/repos/builtin/packages/kentutils/fix-mysql-options-gcc13.patch @@ -0,0 +1,13 @@ +diff --git a/jksql.c.orig b/jksql.c +index bf38b3b..69b2c42 100644 +--- a/kent/src/hg/lib/jksql.c ++++ b/kent/src/hg/lib/jksql.c +@@ -1129,7 +1129,7 @@ mysql_options(conn, MYSQL_OPT_LOCAL_INFILE, NULL); + if (sp->verifyServerCert && !sameString(sp->verifyServerCert,"0")) + { + #if !defined(MARIADB_VERSION_ID) && MYSQL_VERSION_ID >= 80000 +- mysql_options(conn, MYSQL_OPT_SSL_MODE, SSL_MODE_REQUIRED); ++ mysql_options(conn, MYSQL_OPT_SSL_MODE, (void*) SSL_MODE_REQUIRED); + #else + my_bool flag = TRUE; + mysql_options(conn, MYSQL_OPT_SSL_VERIFY_SERVER_CERT, &flag); diff --git a/var/spack/repos/builtin/packages/kentutils/mysql-zlib-workaround.patch b/var/spack/repos/builtin/packages/kentutils/mysql-zlib-workaround.patch new file mode 100644 index 00000000000000..10a460d7810ebc --- /dev/null +++ b/var/spack/repos/builtin/packages/kentutils/mysql-zlib-workaround.patch @@ -0,0 +1,13 @@ +diff --git a/kent/src/inc/common.mk.orig b/kent/src/inc/common.mk +index 83803ad..8c90e3a 100644 +--- a/kent/src/inc/common.mk ++++ b/kent/src/inc/common.mk +@@ -226,6 +226,8 @@ ifeq (${ZLIB},) + ZLIB=-lz + endif + ++MYSQLLIBS := $(subst -lzlib,, ${MYSQLLIBS}) ++ + # on hgwdev, use the static libraries + ifeq (${IS_HGWDEV},yes) + FULLWARN = yes diff --git a/var/spack/repos/builtin/packages/kentutils/package.py b/var/spack/repos/builtin/packages/kentutils/package.py index 7757320c72d62c..d2838c9da62de9 100644 --- a/var/spack/repos/builtin/packages/kentutils/package.py +++ b/var/spack/repos/builtin/packages/kentutils/package.py @@ -3,39 +3,157 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os + from spack.package import * class Kentutils(MakefilePackage): - """Jim Kent command line bioinformatic utilities""" + """ + Jim Kent command line bioinformatic utilities and libraries + + This bundles a custom version of htslib, but can be overridden with ~htslib. + Consider adding the ^mysql+client_only dependency to avoid building all mysql/mariadb. + """ homepage = "https://genome.cse.ucsc.edu/" url = "https://hgdownload.cse.ucsc.edu/admin/exe/userApps.archive/userApps.v453.src.tgz" - version("459", sha256="0b6e89a183e6385c713cf010a7aeead9da6626d8d2f78c363a4f1bc56ccccebb") - # The above archive only goes back to v305. v302 is left for now but deprecated. Suggest - # this is dropped on next update (v302 is from 2014!) and the `requires()` removed. + maintainers("teaguesterling") + + version("465", sha256="eef17b1f3182d1d9dc99b5c73a6b0468d5d3bd80470f25d3f7706cc1372e04b0") + version("464", sha256="24e20fe68e2a2894d802c87662f69a62f71b3c15fafb2e4d6c3c425c63638bb2") + version("460", sha256="b955e56ee880074521ef1ab1371491f47e66dc6fdd93b05328386dd675a635fa") + version("455", sha256="e458cadad7c4a5c1b8385edafffa1b29380ac725a0c20535bf5a3bab99fe80db") + # This version isn't present in the archive any more + # Might be worth changing url to: https://github.com/ucscGenomeBrowser/kent-core/tags/... version( - "302.1", - commit="d8376c5d52a161f2267346ed3dc94b5dce74c2f9", - git="https://github.com/ENCODE-DCC/kentUtils.git", + "459", + sha256="0b6e89a183e6385c713cf010a7aeead9da6626d8d2f78c363a4f1bc56ccccebb", deprecated=True, ) - depends_on("libpng") - depends_on("openssl") - depends_on("libuuid") - depends_on("mariadb") - depends_on("zlib-api") - depends_on("freetype") - depends_on("libiconv") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + # The bundled version of kentlib has some custom changes that are used by parts of + # kentlib. See https://github.com/spack/spack/pull/44501#issuecomment-2162789410 + # for some additional details. A built-in version SHOULD work for most things though. + variant( + "builtin_htslib", + default=False, + description="Build with bundled htslib (using an external htslib may lead to errors)", + sticky=True, + ) + + with default_args(type=("build", "link", "run")): + depends_on("libpng") + depends_on("openssl") + depends_on("uuid") + depends_on("mysql-client") + depends_on("zlib-api") + depends_on("freetype") + depends_on("libiconv") + depends_on("htslib+pic", when="~builtin_htslib") + + # The bgzip.c bug present in other packages is present in kent/src/htslib/bgzf.c + # Conflicting line: assert(compressBound(BGZF_BLOCK_SIZE) < BGZF_MAX_BLOCK_SIZE); + # We can patch this by removing the assertion, but there are still performance issues + # See: https://github.com/samtools/htslib/issues/1257 + conflicts("zlib-ng") + + # Does not add a link to mysql_config, which is required for compilation + conflicts("mariadb-c-client") - requires("%gcc", when="@302.1") + # MySQL pointer/integer conversion issue (https://github.com/ucscGenomeBrowser/kent/pull/87) + patch("fix-mysql-options-gcc13.patch", when="%gcc@13: ^mysql") + # MySQL build flags from `mysql_config` are not compatible with Spack's method of building + # and includes zlib when it's not needed/available, leading to a linking failure. + patch("mysql-zlib-workaround.patch", when="%gcc ^mysql") def flag_handler(self, name, flags): - if name == "ldflags": + if name == "cflags": + flags.append(self.compiler.cc_pic_flag) + elif name == "ldflags": flags.append(f'{self.spec["libiconv"].libs.ld_flags}') return (flags, None, None) + @property + def machtype(self): + # This is hard-coded in the Makefile and included here for reference + # and to make it adjustable if we need to adjust this in the future + return "local" + + @property + def headers(self): + headers = [] + headers.extend(find_headers("*", self.prefix.inc, recursive=True)) + if self.spec.satisfies("+builtin_htslib"): + headers.extend(find_headers("*", self.prefix.htslib, recursive=True)) + return HeaderList(headers) + + @property + def libs(self): + return LibraryList([join_path(self.prefix, lib) for lib in self.local_libs]) + + @property + def local_libs(self): + libs = [ + f"lib/{self.machtype}/jkweb.a", + f"lib/{self.machtype}/jkOwnLib.a", + f"lib/{self.machtype}/jkhgap.a", + f"lib/{self.machtype}/jkhgapcgi.a", + f"hg/altSplice/lib/{self.machtype}/libSpliceGraph.a", + ] + if self.spec.satisfies("+builtin_htslib"): + libs.append("htslib/libhts.a") + return LibraryList(libs) + + @property + def lib_dir(self): + return join_path(self.prefix.lib, self.machtype) + + @property + def htslib_include_dir(self): + if self.spec.satisfies("~builtin_htslib"): + # If we're not using the bundled version, just defer to htslib + return self.spec["htslib"].prefix.include + else: + # In the event we're using the bundled htslib, the htslib + # headers live in a different part of the installed tree + return self.prefix.htslib + + # Packages that link to kentlib (and potential, htslib) often have + # idiosyncratic ways of setting up their includes and linker paths. + # Having these paths available will make things cleaner downstream. + def setup_dependent_package(self, module, dep_spec): + setattr(module, "kentutils_include_dir", self.prefix.inc) + setattr(module, "kentutils_lib_dir", self.lib_dir) + setattr(module, "kentutils_htslib_include_dir", self.htslib_include_dir) + + def install_libs_from_stage(self, spec, prefix): + # Dependent packages expect things in the source tree, but we don't + # want to copy all of the compilation artifacts in so we'll do them + # manually instead of leaving the build directory around + + src_prefix = "kent/src" + + def install_kent(path, tree): + src = join_path(src_prefix, path) + dest = join_path(prefix, path) + mkdirp(os.path.dirname(dest)) + if tree: + install_tree(src, dest) + else: + install(src, dest) + + install_kent("inc", tree=True) + if spec.satisfies("+builtin_htslib"): + install_kent("htslib/htslib", tree=True) + + for lib in self.local_libs: + install_kent(lib, tree=False) + def install(self, spec, prefix): install_tree("bin", prefix.bin) + self.install_libs_from_stage(spec, prefix) diff --git a/var/spack/repos/builtin/packages/keyutils/package.py b/var/spack/repos/builtin/packages/keyutils/package.py index 45fbb4de5beeb6..6278778e2e4c09 100644 --- a/var/spack/repos/builtin/packages/keyutils/package.py +++ b/var/spack/repos/builtin/packages/keyutils/package.py @@ -21,6 +21,8 @@ class Keyutils(MakefilePackage): version("1.5.10", sha256="e1fdbde234c786b65609a4cf080a2c5fbdb57f049249c139160c85fc3dfa7da9") version("1.5.9", sha256="2dc0bdb099ab8331e02e5dbbce320359bef76eda0a4ddbd2ba1d1b9d3a8cdff8") + depends_on("c", type="build") # generated + conflicts("platform=darwin", msg="Linux-only") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/khmer/package.py b/var/spack/repos/builtin/packages/khmer/package.py index c93b4fbacd5cc6..7c5dd928330a3f 100644 --- a/var/spack/repos/builtin/packages/khmer/package.py +++ b/var/spack/repos/builtin/packages/khmer/package.py @@ -17,6 +17,9 @@ class Khmer(PythonPackage): version("2.1.1", sha256="a709606910bb8679bd8525e9d2bf6d1421996272e343b54cc18090feb2fdbe24") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # https://github.com/dib-lab/khmer/pull/1922 ... conflicts("^python@3.12:") diff --git a/var/spack/repos/builtin/packages/kibana/package.py b/var/spack/repos/builtin/packages/kibana/package.py index 266a79685432d5..bbf8146ec2fb01 100644 --- a/var/spack/repos/builtin/packages/kibana/package.py +++ b/var/spack/repos/builtin/packages/kibana/package.py @@ -15,6 +15,8 @@ class Kibana(Package): version("6.4.0", sha256="df2056105a08c206a1adf9caed09a152a53429a0f1efc1ba3ccd616092d78aee") + depends_on("cxx", type="build") # generated + depends_on("java", type="run") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/kicad/package.py b/var/spack/repos/builtin/packages/kicad/package.py index 81db728ecc0400..be431d8a0eafe7 100644 --- a/var/spack/repos/builtin/packages/kicad/package.py +++ b/var/spack/repos/builtin/packages/kicad/package.py @@ -22,6 +22,9 @@ class Kicad(CMakePackage): version("5.1.9", sha256="841be864b9dc5c761193c3ee9cbdbed6729952d7b38451aa8e1977bdfdb6081b") version("5.1.8", sha256="bf24f8ef427b4a989479b8e4af0b8ae5c54766755f12748e2e88a922c5344ca4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("wxwidgets") depends_on("python@3:", type=("build", "run")) # py-wxpython needs work diff --git a/var/spack/repos/builtin/packages/kim-api/package.py b/var/spack/repos/builtin/packages/kim-api/package.py index 812b4f39e46729..bbe6f3a8cd2532 100644 --- a/var/spack/repos/builtin/packages/kim-api/package.py +++ b/var/spack/repos/builtin/packages/kim-api/package.py @@ -39,6 +39,10 @@ class KimApi(CMakePackage): version("2.1.1", sha256="25c4e83c6caa83a1c4ad480b430f1926fb44813b64f548fdaedc45e310b5f6b9") version("2.1.0", sha256="d6b154b31b288ec0a5643db176950ed71f1ca83a146af210a1d5d01cce8ce958") version("2.0.2", sha256="26e7cf91066692f316b8ba1548ccb7152bf56aad75902bce2338cff53e74e63d") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated # The Fujitsu compiler requires the '--linkfortran' # option to combine C++ and Fortran programs. patch("fujitsu_add_link_flags.patch", when="%fj") diff --git a/var/spack/repos/builtin/packages/kineto/package.py b/var/spack/repos/builtin/packages/kineto/package.py index 4c174114003c6a..5aa1c15faa347e 100644 --- a/var/spack/repos/builtin/packages/kineto/package.py +++ b/var/spack/repos/builtin/packages/kineto/package.py @@ -26,6 +26,8 @@ class Kineto(CMakePackage): "2021-02-04", commit="258d9a471f8d3a50a0f52b85c3fe0902f65489df", submodules=True ) # py-torch@1.8.0 + depends_on("cxx", type="build") # generated + root_cmakelists_dir = "libkineto" generator("ninja") diff --git a/var/spack/repos/builtin/packages/kitty/package.py b/var/spack/repos/builtin/packages/kitty/package.py index 8ff092a50ba22e..b9e65e5bb0c351 100644 --- a/var/spack/repos/builtin/packages/kitty/package.py +++ b/var/spack/repos/builtin/packages/kitty/package.py @@ -32,6 +32,8 @@ class Kitty(Package): version("0.10.1", sha256="ef22208497a76e2f88ebe56c176e4608f049b056252cf1bf122c9c1ec711cfa6") version("0.10.0", sha256="056563862c5759b740e95efff44b82c1a4efc370092f22f26aee0b774106bf4d") + depends_on("c", type="build") # generated + depends_on("python@3.5:", type=("build", "run")) depends_on("harfbuzz@1.5.0:") depends_on("libxkbcommon@0.5:") diff --git a/var/spack/repos/builtin/packages/kmergenie/package.py b/var/spack/repos/builtin/packages/kmergenie/package.py index 962042f5a8904f..f1eae61f16816e 100644 --- a/var/spack/repos/builtin/packages/kmergenie/package.py +++ b/var/spack/repos/builtin/packages/kmergenie/package.py @@ -17,6 +17,8 @@ class Kmergenie(MakefilePackage): version("1.7051", sha256="13148e5a2c700359cffca363b66ffa8f23c5db6af6eec03f739139ffdfee763f") version("1.7044", sha256="46f2a08a2d7b1885414143e436829dd7e61fcc31ec4e429433e516a168d2978e") + depends_on("cxx", type="build") # generated + depends_on("python", type=("build", "run")) depends_on("py-setuptools", type=("build", "run")) depends_on("r", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/kmod/package.py b/var/spack/repos/builtin/packages/kmod/package.py index 3c0d1a2c15d876..b017ff986b0317 100644 --- a/var/spack/repos/builtin/packages/kmod/package.py +++ b/var/spack/repos/builtin/packages/kmod/package.py @@ -22,6 +22,8 @@ class Kmod(AutotoolsPackage): version("24", sha256="f7a5ee07d4901c87711880536604de7e31c182d85a72de7b8d7dd04d4ee0aa59") version("23", sha256="8f139543d82e8ccc2227dec4c016d6656e9789365a6dce73f90b620a53e62ee6") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/knem/package.py b/var/spack/repos/builtin/packages/knem/package.py index ae6713cd3d1709..e3db858ff5b7cd 100644 --- a/var/spack/repos/builtin/packages/knem/package.py +++ b/var/spack/repos/builtin/packages/knem/package.py @@ -29,6 +29,8 @@ class Knem(AutotoolsPackage): url="https://gitlab.inria.fr/knem/knem/uploads/59375c38537e6ff2d94209f190c54aa6/knem-1.1.3.tar.gz", ) + depends_on("c", type="build") # generated + variant("hwloc", default=True, description="Enable hwloc in the user-space tools") patch( diff --git a/var/spack/repos/builtin/packages/kokkos-kernels-legacy/package.py b/var/spack/repos/builtin/packages/kokkos-kernels-legacy/package.py index c0582f19560fa9..9ade1c168a083f 100644 --- a/var/spack/repos/builtin/packages/kokkos-kernels-legacy/package.py +++ b/var/spack/repos/builtin/packages/kokkos-kernels-legacy/package.py @@ -29,6 +29,8 @@ class KokkosKernelsLegacy(MakefilePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + # make sure kokkos kernels version matches kokkos depends_on("kokkos-legacy@2.5.00", when="@2.5.00") depends_on("kokkos-legacy@2.6.00", when="@2.6.00") diff --git a/var/spack/repos/builtin/packages/kokkos-kernels/package.py b/var/spack/repos/builtin/packages/kokkos-kernels/package.py index 36e387208d24ac..3079888c360bc7 100644 --- a/var/spack/repos/builtin/packages/kokkos-kernels/package.py +++ b/var/spack/repos/builtin/packages/kokkos-kernels/package.py @@ -25,6 +25,8 @@ class KokkosKernels(CMakePackage, CudaPackage): # openssl sha256 kokkos-kernels-x.y.z.tar.gz version("develop", branch="develop") version("master", branch="master") + version("4.3.01", sha256="749553a6ea715ba1e56fa0b13b42866bb9880dba7a94e343eadf40d08c68fab8") + version("4.3.00", sha256="03c3226ee97dbca4fa56fe69bc4eefa0673e23c37f2741943d9362424a63950e") version("4.2.01", sha256="058052b3a40f5d4e447b7ded5c480f1b0d4aa78373b0bc7e43804d0447c34ca8") version("4.2.00", sha256="c65df9a101dbbef2d8fd43c60c9ea85f2046bb3535fa1ad16e7c661ddd60401e") version("4.1.00", sha256="d6a4108444ea226e43bf6a9c0dfc557f223a72b1142bf81aa78dd60e16ac2d56") @@ -44,9 +46,13 @@ class KokkosKernels(CMakePackage, CudaPackage): version("3.1.00", sha256="27fea241ae92f41bd5b070b1a590ba3a56a06aca750207a98bea2f64a4a40c89") version("3.0.00", sha256="e4b832aed3f8e785de24298f312af71217a26067aea2de51531e8c1e597ef0e6") + depends_on("cxx", type="build") # generated + depends_on("kokkos") depends_on("kokkos@master", when="@master") depends_on("kokkos@develop", when="@develop") + depends_on("kokkos@4.3.01", when="@4.3.01") + depends_on("kokkos@4.3.00", when="@4.3.00") depends_on("kokkos@4.2.01", when="@4.2.01") depends_on("kokkos@4.2.00", when="@4.2.00") depends_on("kokkos@4.1.00", when="@4.1.00") @@ -146,6 +152,8 @@ class KokkosKernels(CMakePackage, CudaPackage): "lapacke": (False, "clapack", "LAPACKE", "@3.1.00:", "Link to LAPACKE library"), "rocblas": (False, "rocblas", "ROCBLAS", "@3.6.00:", "Link to AMD BLAS library"), "rocsparse": (False, "rocsparse", "ROCSPARSE", "@3.6.00:", "Link to AMD sparse library"), + "cusolver": (False, "cuda", None, "@4.3.00:", "Link to CUDA solver library"), + "rocsolver": (False, "rocsolver", "ROCSOLVER", "@4.3.00:", "Link to AMD solver library"), } for tpl in tpls: diff --git a/var/spack/repos/builtin/packages/kokkos-legacy/package.py b/var/spack/repos/builtin/packages/kokkos-legacy/package.py index 54548c0ae1472f..a9c9a7706ebcd0 100644 --- a/var/spack/repos/builtin/packages/kokkos-legacy/package.py +++ b/var/spack/repos/builtin/packages/kokkos-legacy/package.py @@ -14,6 +14,8 @@ class KokkosLegacy(Package): url = "https://github.com/kokkos/kokkos/archive/2.03.00.tar.gz" git = "https://github.com/kokkos/kokkos.git" + # This package has been archived. All new versions of Kokkos should go into + # the kokkos package itself. version( "2.9.00", sha256="e0621197791ed3a381b4f02c78fa529f3cff3abb74d52157b4add17e8aa04bc4", @@ -85,6 +87,9 @@ class KokkosLegacy(Package): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("debug", default=False, description="Build debug version of Kokkos") variant("serial", default=True, description="enable Serial backend (default)") @@ -197,7 +202,7 @@ class KokkosLegacy(Package): # without specifying CUDA for p in gpu_values: conflicts( - "gpu_arch={0}".format(p), + f"gpu_arch={p}", when="~cuda", msg="Must specify CUDA backend to use a GPU architecture.", ) @@ -235,7 +240,7 @@ class KokkosLegacy(Package): def install(self, spec, prefix): generate = which(join_path(self.stage.source_path, "generate_makefile.bash")) with working_dir("build", create=True): - g_args = ["--prefix=%s" % prefix, "--with-hwloc=%s" % spec["hwloc"].prefix] + g_args = [f"--prefix={prefix}", f"--with-hwloc={spec['hwloc'].prefix}"] arch_args = [] kokkos_options_args = [] cuda_options_args = [] @@ -247,7 +252,7 @@ def install(self, spec, prefix): # C++ standard cxxstandard = spec.variants["cxxstd"].value if cxxstandard != "none": - g_args.append("--cxxstandard=%s" % cxxstandard) + g_args.append(f"--cxxstandard={cxxstandard}") # Build Debug if "+debug" in spec: @@ -261,9 +266,9 @@ def install(self, spec, prefix): if "+pthreads" in spec: g_args.append("--with-pthread") if "+qthreads" in spec: - g_args.append("--with-qthreads=%s" % spec["qthreads"].prefix) + g_args.append(f"--with-qthreads={spec['qthreads'].prefix}") if "+cuda" in spec: - g_args.append("--with-cuda=%s" % spec["cuda"].prefix) + g_args.append(f"--with-cuda={spec['cuda'].prefix}") # Host architectures host_arch = spec.variants["host_arch"].value # GPU architectures @@ -274,7 +279,7 @@ def install(self, spec, prefix): arch_args.append(gpu_arch) # Combined architecture flags if arch_args: - g_args.append("--arch={0}".format(",".join(arch_args))) + g_args.append(f"--arch={','.join(arch_args)}") # CUDA options if "+force_uvm" in spec: @@ -286,7 +291,7 @@ def install(self, spec, prefix): if "+enable_lambda" in spec: cuda_options_args.append("enable_lambda") if cuda_options_args: - g_args.append("--with-cuda-options={0}".format(",".join(cuda_options_args))) + g_args.append(f"--with-cuda-options={','.join(cuda_options_args)}") # Kokkos options if "+aggressive_vectorization" in spec: @@ -304,7 +309,7 @@ def install(self, spec, prefix): if "+enable_eti" in spec: kokkos_options_args.append("enable_eti") if kokkos_options_args: - g_args.append("--with-options={0}".format(",".join(kokkos_options_args))) + g_args.append(f"--with-options={','.join(kokkos_options_args)}") generate(*g_args) make() diff --git a/var/spack/repos/builtin/packages/kokkos-nvcc-wrapper/package.py b/var/spack/repos/builtin/packages/kokkos-nvcc-wrapper/package.py index e3bdc634719fc8..def599eda3d6c0 100644 --- a/var/spack/repos/builtin/packages/kokkos-nvcc-wrapper/package.py +++ b/var/spack/repos/builtin/packages/kokkos-nvcc-wrapper/package.py @@ -21,6 +21,10 @@ class KokkosNvccWrapper(Package): license("BSD-3-Clause") + version("4.3.01", sha256="5998b7c732664d6b5e219ccc445cd3077f0e3968b4be480c29cd194b4f45ec70") + version("4.3.00", sha256="53cf30d3b44dade51d48efefdaee7a6cf109a091b702a443a2eda63992e5fe0d") + version("4.2.01", sha256="cbabbabba021d00923fb357d2e1b905dda3838bd03c885a6752062fe03c67964") + version("4.2.00", sha256="ac08765848a0a6ac584a0a46cd12803f66dd2a2c2db99bb17c06ffc589bf5be8") version("4.1.00", sha256="cf725ea34ba766fdaf29c884cfe2daacfdc6dc2d6af84042d1c78d0f16866275") version("4.0.01", sha256="bb942de8afdd519fd6d5d3974706bfc22b6585a62dd565c12e53bdb82cd154f0") version("4.0.00", sha256="1829a423883d4b44223c7c3a53d3c51671145aad57d7d23e6a1a4bebf710dcf6") @@ -42,6 +46,10 @@ class KokkosNvccWrapper(Package): version("master", branch="master") version("develop", branch="develop") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cuda") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/kokkos/package.py b/var/spack/repos/builtin/packages/kokkos/package.py index 0f994087d2e1c3..8b7efad300facd 100644 --- a/var/spack/repos/builtin/packages/kokkos/package.py +++ b/var/spack/repos/builtin/packages/kokkos/package.py @@ -27,6 +27,8 @@ class Kokkos(CMakePackage, CudaPackage, ROCmPackage): version("master", branch="master") version("develop", branch="develop") + version("4.3.01", sha256="5998b7c732664d6b5e219ccc445cd3077f0e3968b4be480c29cd194b4f45ec70") + version("4.3.00", sha256="53cf30d3b44dade51d48efefdaee7a6cf109a091b702a443a2eda63992e5fe0d") version("4.2.01", sha256="cbabbabba021d00923fb357d2e1b905dda3838bd03c885a6752062fe03c67964") version("4.2.00", sha256="ac08765848a0a6ac584a0a46cd12803f66dd2a2c2db99bb17c06ffc589bf5be8") version("4.1.00", sha256="cf725ea34ba766fdaf29c884cfe2daacfdc6dc2d6af84042d1c78d0f16866275") @@ -48,7 +50,12 @@ class Kokkos(CMakePackage, CudaPackage, ROCmPackage): version("3.1.00", sha256="b935c9b780e7330bcb80809992caa2b66fd387e3a1c261c955d622dae857d878") version("3.0.00", sha256="c00613d0194a4fbd0726719bbed8b0404ed06275f310189b3493f5739042a92b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.16:", type="build") + conflicts("cmake@3.28", when="@:4.2.01 +cuda") devices_variants = { "cuda": [False, "Whether to build CUDA backend"], @@ -64,7 +71,6 @@ class Kokkos(CMakePackage, CudaPackage, ROCmPackage): conflicts("+openmptarget", when="@:3.5") # https://github.com/spack/spack/issues/29052 - conflicts("@:3.5 +sycl", when="%dpcpp@2022:") conflicts("@:3.5 +sycl", when="%oneapi@2022:") tpls_variants = { diff --git a/var/spack/repos/builtin/packages/kraken/package.py b/var/spack/repos/builtin/packages/kraken/package.py index 6bfaef69c93f60..806e3d29da4d4b 100644 --- a/var/spack/repos/builtin/packages/kraken/package.py +++ b/var/spack/repos/builtin/packages/kraken/package.py @@ -21,6 +21,8 @@ class Kraken(Package): version("1.1.1", sha256="73e48f40418f92b8cf036ca1da727ca3941da9b78d4c285b81ba3267326ac4ee") version("1.0", sha256="bade6d83233c26226d02bd427fe0a4d6cd6dc5c0300927e30d41e885a478c378") + depends_on("cxx", type="build") # generated + depends_on("perl", type=("build", "run")) # Does NOT support JELLYFISH 2.0. Ver 1.1.11 is the last version of # JELLYFISH 1. diff --git a/var/spack/repos/builtin/packages/kraken2/package.py b/var/spack/repos/builtin/packages/kraken2/package.py index efe7513656cdc3..5a41bff18ccd80 100644 --- a/var/spack/repos/builtin/packages/kraken2/package.py +++ b/var/spack/repos/builtin/packages/kraken2/package.py @@ -32,6 +32,8 @@ class Kraken2(Package): "2.0.6-beta", sha256="d77db6251179c4d7e16bc9b5e5e9043d25acf81f3e32ad6eadfba829a31e1d09" ) + depends_on("cxx", type="build") # generated + depends_on("perl", type=("build", "run")) depends_on("rsync", type=("run")) depends_on("wget", type=("run")) diff --git a/var/spack/repos/builtin/packages/krakenuniq/package.py b/var/spack/repos/builtin/packages/krakenuniq/package.py index c4610dac2f2bf5..53d8b865bdc33a 100644 --- a/var/spack/repos/builtin/packages/krakenuniq/package.py +++ b/var/spack/repos/builtin/packages/krakenuniq/package.py @@ -25,6 +25,8 @@ class Krakenuniq(Package): version("0.5.5", sha256="645f4387a59638526dededacd5104abc1b325c020d5e4c136b902f1167fc4fd5") version("0.5.3", sha256="bc57fd4d5f50363aef640d61b2b111d9bef84a32e9a4eebfb977812cb8dc0250") + depends_on("cxx", type="build") # generated + variant("jellyfish", default=False, description="Install jellyfish v1.1.") depends_on("bzip2") diff --git a/var/spack/repos/builtin/packages/krb5/package.py b/var/spack/repos/builtin/packages/krb5/package.py index d32f86991e76fd..73c349ca6f8636 100644 --- a/var/spack/repos/builtin/packages/krb5/package.py +++ b/var/spack/repos/builtin/packages/krb5/package.py @@ -18,6 +18,7 @@ class Krb5(AutotoolsPackage): license("MIT") + version("1.21.2", sha256="9560941a9d843c0243a71b17a7ac6fe31c7cebb5bce3983db79e52ae7e850491") version("1.20.1", sha256="704aed49b19eb5a7178b34b2873620ec299db08752d6a8574f95d41879ab8851") version("1.19.4", sha256="41f5981c5a4de0a26b3937e679a116cd5b3739641fd253124aac91f7179b54eb") version("1.19.3", sha256="56d04863cfddc9d9eb7af17556e043e3537d41c6e545610778676cf551b9dcd0") @@ -31,6 +32,9 @@ class Krb5(AutotoolsPackage): version("1.16.2", sha256="9f721e1fe593c219174740c71de514c7228a97d23eb7be7597b2ae14e487f027") version("1.16.1", sha256="214ffe394e3ad0c730564074ec44f1da119159d94281bbec541dc29168d21117") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("diffutils", type="build") depends_on("bison", type="build") depends_on("openssl@:1", when="@:1.19") @@ -73,19 +77,20 @@ def patch(self): ) def configure_args(self): + spec = self.spec args = ["--without-system-verto"] - if "~shared" in self.spec: + if spec.satisfies("~shared"): args.append("--enable-static") args.append("--disable-shared") else: args.append("--disable-static") # https://github.com/spack/spack/issues/34193 - if "%gcc@10:" in self.spec: + if spec.satisfies("%gcc@10:"): args.append("CFLAGS=-fcommon") - if self.spec["openssl"].satisfies("~shared"): + if spec["openssl"].satisfies("~shared"): pkgconf = which("pkg-config") ssllibs = pkgconf("--static", "--libs", "openssl", output=str) args.append(f"LDFLAGS={ssllibs}") diff --git a/var/spack/repos/builtin/packages/krims/package.py b/var/spack/repos/builtin/packages/krims/package.py index 3d07b1a5b6e5f2..17ba1149a48d7e 100644 --- a/var/spack/repos/builtin/packages/krims/package.py +++ b/var/spack/repos/builtin/packages/krims/package.py @@ -23,6 +23,8 @@ class Krims(CMakePackage): version("develop", branch="master") version("0.2.1", sha256="baac8de392e6c2a73a535f71596f51d4a80a08d9c0ecbf9a2d72d1d70dd17999") + depends_on("cxx", type="build") # generated + # # Variants # diff --git a/var/spack/repos/builtin/packages/kripke/001-remove-googletest-from-cmake.patch b/var/spack/repos/builtin/packages/kripke/001-remove-googletest-from-cmake.patch new file mode 100644 index 00000000000000..9e54cedc6abc3e --- /dev/null +++ b/var/spack/repos/builtin/packages/kripke/001-remove-googletest-from-cmake.patch @@ -0,0 +1,25 @@ + +m aa630efbd686c8581bb893b512dbf1613e1e574d Mon Sep 17 00:00:00 2001 +From: Afzal Patel +Date: Thu, 20 Jun 2024 18:40:02 +0000 +Subject: [PATCH] Comment out googletest folder + +--- + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 2f9bff0..3059e26 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -64,7 +64,7 @@ endif() + # + # Add googletest (needed by RAJA, etc) + # +-add_subdirectory(tpl/googletest) ++# add_subdirectory(tpl/googletest) + + + # +-- +2.31.1 diff --git a/var/spack/repos/builtin/packages/kripke/package.py b/var/spack/repos/builtin/packages/kripke/package.py index 87a31c896c06c8..7bd6c2dc7c7242 100644 --- a/var/spack/repos/builtin/packages/kripke/package.py +++ b/var/spack/repos/builtin/packages/kripke/package.py @@ -21,6 +21,15 @@ class Kripke(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("develop", branch="develop", submodules=False) + version( + "1.2.7", submodules=True, tag="v1.2.7", commit="ddcac43cdad999f0346eb682065ef0af1847029d" + ) + version( + "1.2.6", submodules=True, tag="v1.2.6", commit="55b39f34b68c68b2d828a33a75568abd66e1019f" + ) + version( + "1.2.5", submodules=True, tag="v1.2.5", commit="20e9ea975f1bf567829323a18927b69bed3f4ebd" + ) version( "1.2.4", submodules=False, tag="v1.2.4", commit="d85c6bc462f17a2382b11ba363059febc487f771" ) @@ -46,6 +55,10 @@ class Kripke(CMakePackage, CudaPackage, ROCmPackage): commit="67e4b0a2f092009d61f44b5122111d388a3bec2a", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Build with MPI.") variant("openmp", default=False, description="Build with OpenMP enabled.") variant("caliper", default=False, description="Build with Caliper support enabled.") @@ -55,10 +68,26 @@ class Kripke(CMakePackage, CudaPackage, ROCmPackage): depends_on("caliper", when="+caliper") depends_on("adiak@0.4:", when="+caliper") depends_on("chai~examples+raja") - depends_on("raja~exercises~examples") + depends_on("raja@:2024.02.1~exercises~examples") depends_on("umpire~examples") + + with when("+rocm @1.2.5:"): + depends_on("raja+rocm", when="+rocm") + depends_on("chai+rocm", when="+rocm") + for arch in ROCmPackage.amdgpu_targets: + depends_on( + "raja+rocm amdgpu_target={0}".format(arch), when="amdgpu_target={0}".format(arch) + ) + depends_on( + "chai+rocm amdgpu_target={0}".format(arch), when="amdgpu_target={0}".format(arch) + ) + conflicts("^blt@:0.3.6", when="+rocm") + # googletest folder version hasn't been updated in over 5 years + # and is commented out in later releases + patch("001-remove-googletest-from-cmake.patch", when="@1.2.5:1.2.6") + def cmake_args(self): spec = self.spec args = [] @@ -85,6 +114,7 @@ def cmake_args(self): # Set up the hip macros needed by the build args.append("-DENABLE_HIP=ON") args.append("-DHIP_ROOT_DIR={0}".format(spec["hip"].prefix)) + args.append(self.define("CMAKE_CXX_COMPILER", self.spec["hip"].hipcc)) rocm_archs = spec.variants["amdgpu_target"].value if "none" not in rocm_archs: args.append("-DHIP_HIPCC_FLAGS=--amdgpu-target={0}".format(",".join(rocm_archs))) @@ -113,4 +143,7 @@ def install(self, spec, prefix): # Kripke does not provide install target, so we have to copy # things into place. mkdirp(prefix.bin) - install(join_path(self.build_directory, "kripke.exe"), prefix.bin) + if spec.satisfies("@:1.2.4") or spec.satisfies("@1.2.7:"): + install(join_path(self.build_directory, "kripke.exe"), prefix.bin) + else: + install(join_path(self.build_directory, "bin", "kripke.exe"), prefix.bin) diff --git a/var/spack/repos/builtin/packages/kubectl/package.py b/var/spack/repos/builtin/packages/kubectl/package.py index 786a948c816529..b36f26f37ad256 100644 --- a/var/spack/repos/builtin/packages/kubectl/package.py +++ b/var/spack/repos/builtin/packages/kubectl/package.py @@ -21,6 +21,8 @@ class Kubectl(Package): version("1.27.1", sha256="3a3f7c6b8cf1d9f03aa67ba2f04669772b1205b89826859f1636062d5f8bec3f") version("1.27.0", sha256="536025dba2714ee5e940bb0a6b1df9ca97c244fa5b00236e012776a69121c323") + depends_on("c", type="build") # generated + depends_on("bash", type="build") depends_on("go", type="build") diff --git a/var/spack/repos/builtin/packages/kubernetes/package.py b/var/spack/repos/builtin/packages/kubernetes/package.py index 84ba7935c4da99..02be4abf8d01aa 100644 --- a/var/spack/repos/builtin/packages/kubernetes/package.py +++ b/var/spack/repos/builtin/packages/kubernetes/package.py @@ -40,6 +40,8 @@ class Kubernetes(Package): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("bash", type="build") depends_on("go", type="build") diff --git a/var/spack/repos/builtin/packages/kumi/package.py b/var/spack/repos/builtin/packages/kumi/package.py index 2ccd22dbbb9e36..45825157ac9452 100644 --- a/var/spack/repos/builtin/packages/kumi/package.py +++ b/var/spack/repos/builtin/packages/kumi/package.py @@ -21,3 +21,5 @@ class Kumi(CMakePackage): version("2.1", sha256="34fc756780d463db35716e40eecd89b1505917926281262c74af425556a5260c") version("2.0", sha256="c9f2d2014d3513c57db4457c5a678c7adce1fa9bd061ee008847876f06dac355") version("1.0", sha256="d28be244e326b1c9f1651b47728af74bb6be80a7accd39f07441a246d49220f5") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/kvasir-mpl/package.py b/var/spack/repos/builtin/packages/kvasir-mpl/package.py index d1627d064c87b0..bd73a3be8fc505 100644 --- a/var/spack/repos/builtin/packages/kvasir-mpl/package.py +++ b/var/spack/repos/builtin/packages/kvasir-mpl/package.py @@ -17,5 +17,7 @@ class KvasirMpl(Package): version("develop", branch="development") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): install_tree("src", prefix.include) diff --git a/var/spack/repos/builtin/packages/kvtree/package.py b/var/spack/repos/builtin/packages/kvtree/package.py index 042c5a75912932..a7d091f23fc16f 100644 --- a/var/spack/repos/builtin/packages/kvtree/package.py +++ b/var/spack/repos/builtin/packages/kvtree/package.py @@ -28,6 +28,8 @@ class Kvtree(CMakePackage): version("1.0.3", sha256="c742cdb1241ef4cb13767019204d5350a3c4383384bed9fb66680b93ff44b0d4") version("1.0.2", sha256="56fb5b747758c24a907a8380e8748d296900d94de9547bc15f6b427ac4ae2ec4") + depends_on("c", type="build") # generated + depends_on("zlib-api", type="link") variant("mpi", default=True, description="Build with MPI message packing") @@ -60,8 +62,5 @@ def cmake_args(self): if spec.satisfies("@1.2.0:"): args.append(self.define_from_variant("BUILD_SHARED_LIBS", "shared")) - else: - if spec.satisfies("platform=cray"): - args.append(self.define("KVTREE_LINK_STATIC", True)) return args diff --git a/var/spack/repos/builtin/packages/kylin/package.py b/var/spack/repos/builtin/packages/kylin/package.py index 623b23273e0e6c..4d4e3df591e387 100644 --- a/var/spack/repos/builtin/packages/kylin/package.py +++ b/var/spack/repos/builtin/packages/kylin/package.py @@ -23,4 +23,6 @@ class Kylin(MavenPackage): version("3.1.0", sha256="84073ff16a0dad6e0611fea9fbf2b977b6bac307107a222b7f576a3a3b712157") + depends_on("cxx", type="build") # generated + depends_on("java@8", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/kyotocabinet/package.py b/var/spack/repos/builtin/packages/kyotocabinet/package.py index 409fbc1532209e..684cbbd2d4fd30 100644 --- a/var/spack/repos/builtin/packages/kyotocabinet/package.py +++ b/var/spack/repos/builtin/packages/kyotocabinet/package.py @@ -18,6 +18,9 @@ class Kyotocabinet(AutotoolsPackage): version("1.2.80", sha256="4c85d736668d82920bfdbdb92ac3d66b7db1108f09581a769dd9160a02def349") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api@1.2.3:", type=("build", "link")) depends_on("lzo", type=("build", "link")) depends_on("xz", type=("build", "link")) diff --git a/var/spack/repos/builtin/packages/laghos/package.py b/var/spack/repos/builtin/packages/laghos/package.py index 270c78c831ea89..fb4277d20e8c14 100644 --- a/var/spack/repos/builtin/packages/laghos/package.py +++ b/var/spack/repos/builtin/packages/laghos/package.py @@ -30,6 +30,8 @@ class Laghos(MakefilePackage): version("1.1", sha256="53b9bfe2af263c63eb4544ca1731dd26f40b73a0d2775a9883db51821bf23b7f") version("1.0", sha256="af50a126355a41c758fcda335a43fdb0a3cd97e608ba51c485afda3dd84a5b34") + depends_on("cxx", type="build") # generated + variant("metis", default=True, description="Enable/disable METIS support") variant("ofast", default=False, description="Enable gcc optimization flags") diff --git a/var/spack/repos/builtin/packages/lame/package.py b/var/spack/repos/builtin/packages/lame/package.py index 3f0625c9737624..e48b203bb2958b 100644 --- a/var/spack/repos/builtin/packages/lame/package.py +++ b/var/spack/repos/builtin/packages/lame/package.py @@ -17,6 +17,9 @@ class Lame(AutotoolsPackage): version("3.100", sha256="ddfe36cab873794038ae2c1210557ad34857a4b6bdc515785d1da9e175b1da1e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("nasm", type="build") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/lammps-example-plugin/package.py b/var/spack/repos/builtin/packages/lammps-example-plugin/package.py new file mode 100644 index 00000000000000..729b29f732a018 --- /dev/null +++ b/var/spack/repos/builtin/packages/lammps-example-plugin/package.py @@ -0,0 +1,75 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import datetime as dt + +from spack.package import * +from spack.pkg.builtin.lammps import Lammps + + +class LammpsExamplePlugin(CMakePackage): + """LAMMPS Example Plugin""" + + homepage = "https://www.lammps.org/" + url = "https://github.com/lammps/lammps/archive/patch_1Sep2017.tar.gz" + git = "https://github.com/lammps/lammps.git" + + maintainers("rbberger") + + license("GPL-2.0-only") + + # rules for new versions and deprecation + # * new stable versions should be added to stable_versions set + # * a stable version that has updates and any of its outdated update releases should be + # marked deprecated=True + # * patch releases older than a stable release should be marked deprecated=True + version("develop", branch="develop") + version("20240627", sha256="2174a99d266279823a8c57629ee1c21ec357816aefd85f964d9f859fe9222aa5") + version("20240417", sha256="158b288725c251fd8b30dbcf61749e0d6a042807da92af865a7d3c413efdd8ea") + version( + "20240207.1", sha256="3ba62c2a1ed463fceedf313a1c3ea2997994aa102379a8d35b525ea424f56776" + ) + version( + "20240207", + sha256="d518f32de4eb2681f2543be63926411e72072dd7d67c1670c090b5baabed98ac", + deprecated=True, + ) + version("20231121", sha256="704d8a990874a425bcdfe0245faf13d712231ba23f014a3ebc27bc14398856f1") + version( + "20230802.3", + sha256="6666e28cb90d3ff01cbbda6c81bdb85cf436bbb41604a87f2ab2fa559caa8510", + preferred=True, + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + def url_for_version(self, version): + split_ver = str(version).split(".") + vdate = dt.datetime.strptime(split_ver[0], "%Y%m%d") + if len(split_ver) < 2: + update = "" + else: + update = "_update{0}".format(split_ver[1]) + + return "https://github.com/lammps/lammps/archive/{0}_{1}{2}.tar.gz".format( + "stable" if str(version) in Lammps.stable_versions else "patch", + vdate.strftime("%d%b%Y").lstrip("0"), + update, + ) + + depends_on("lammps+plugin+lib") + + root_cmakelists_dir = "examples/plugins" + + def patch(self): + with open("examples/plugins/CMakeLists.txt", "a") as f: + print("include(GNUInstallDirs)", file=f) + print( + "install(TARGETS morse2plugin nve2plugin helloplugin zero2plugin morse2plugin" + "LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/lammps/plugins)", + file=f, + ) diff --git a/var/spack/repos/builtin/packages/lammps/package.py b/var/spack/repos/builtin/packages/lammps/package.py index 0a78196563e36c..0be3ed6daaa344 100644 --- a/var/spack/repos/builtin/packages/lammps/package.py +++ b/var/spack/repos/builtin/packages/lammps/package.py @@ -5,8 +5,6 @@ import datetime as dt import os -import archspec - from spack.package import * @@ -31,12 +29,26 @@ class Lammps(CMakePackage, CudaPackage, ROCmPackage, PythonExtension): # marked deprecated=True # * patch releases older than a stable release should be marked deprecated=True version("develop", branch="develop") - version("20240207", sha256="d518f32de4eb2681f2543be63926411e72072dd7d67c1670c090b5baabed98ac") + version("20240627", sha256="2174a99d266279823a8c57629ee1c21ec357816aefd85f964d9f859fe9222aa5") + version("20240417", sha256="158b288725c251fd8b30dbcf61749e0d6a042807da92af865a7d3c413efdd8ea") + version( + "20240207.1", sha256="3ba62c2a1ed463fceedf313a1c3ea2997994aa102379a8d35b525ea424f56776" + ) + version( + "20240207", + sha256="d518f32de4eb2681f2543be63926411e72072dd7d67c1670c090b5baabed98ac", + deprecated=True, + ) version("20231121", sha256="704d8a990874a425bcdfe0245faf13d712231ba23f014a3ebc27bc14398856f1") + version( + "20230802.3", + sha256="6666e28cb90d3ff01cbbda6c81bdb85cf436bbb41604a87f2ab2fa559caa8510", + preferred=True, + ) version( "20230802.2", sha256="3bcecabc9cad08d0a4e4d989b52d29c58505f7ead8ebacf43c9db8d9fd3d564a", - preferred=True, + deprecated=True, ) version( "20230802.1", @@ -357,7 +369,12 @@ class Lammps(CMakePackage, CudaPackage, ROCmPackage, PythonExtension): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + stable_versions = { + "20230802.3", "20230802.2", "20230802.1", "20230802", @@ -450,6 +467,7 @@ def url_for_version(self, version): "ml-pod": {"when": "@20221222:"}, "ml-rann": {"when": "@20210702:"}, "ml-snap": {"when": "@20210702:"}, + "ml-uf3": {"when": "@20240627:"}, "mliap": {"when": "@20200630:20210527"}, "mofff": {"when": "@20210702:"}, "molecule": {"default": True}, @@ -619,6 +637,8 @@ def url_for_version(self, version): depends_on("kokkos+deprecated_code+shared@3.0.00", when="@20200303+kokkos") depends_on("kokkos+shared@3.1:", when="@20200505:+kokkos") depends_on("kokkos@3.7.01:", when="@20230208: +kokkos") + depends_on("kokkos@4.3.00:", when="@20240417: +kokkos") + depends_on("kokkos@4.3.01:", when="@20240627: +kokkos") depends_on("adios2", when="+user-adios") depends_on("adios2", when="+adios") depends_on("plumed", when="+user-plumed") @@ -809,9 +829,7 @@ def cmake_args(self): args.append(self.define("CMAKE_CXX_FLAGS_RELWITHDEBINFO", cxx_flags)) # Overwrite generic cpu tune option - cmake_tune_flags = archspec.cpu.TARGETS[spec.target.name].optimization_flags( - spec.compiler.name, spec.compiler.version - ) + cmake_tune_flags = spec.architecture.target.optimization_flags(spec.compiler) args.append(self.define("CMAKE_TUNE_FLAGS", cmake_tune_flags)) args.append(self.define_from_variant("LAMMPS_SIZES", "lammps_sizes")) @@ -862,6 +880,11 @@ def cmake_args(self): if "+rocm" in spec: args.append(self.define("CMAKE_CXX_COMPILER", spec["hip"].hipcc)) + if "@:20231121" in spec: + if "^hip@:5.4" in spec: + args.append(self.define("HIP_PATH", f"{spec['hip'].prefix}/hip")) + elif "^hip@5.5:" in spec: + args.append(self.define("HIP_PATH", spec["hip"].prefix)) return args @@ -878,6 +901,14 @@ def setup_run_environment(self, env): else: env.prepend_path("LD_LIBRARY_PATH", self.prefix.lib) env.prepend_path("LD_LIBRARY_PATH", self.prefix.lib64) + if "+plugin" in self.spec: + env.prepend_path("LAMMPS_PLUGIN_PATH", self.prefix.lib.lammps.plugins) + env.prepend_path("LAMMPS_PLUGIN_PATH", self.prefix.lib64.lammps.plugins) + + @run_after("install") + def make_plugins_directories(self): + os.makedirs(self.prefix.lib.lammps.plugins, exist_ok=True) + os.makedirs(self.prefix.lib64.lammps.plugins, exist_ok=True) @run_after("install") def install_python(self): diff --git a/var/spack/repos/builtin/packages/landsfcutil/package.py b/var/spack/repos/builtin/packages/landsfcutil/package.py index a854f0b8594904..88386714056f1f 100644 --- a/var/spack/repos/builtin/packages/landsfcutil/package.py +++ b/var/spack/repos/builtin/packages/landsfcutil/package.py @@ -21,6 +21,8 @@ class Landsfcutil(CMakePackage): version("develop", branch="develop") version("2.4.1", sha256="831c5005a480eabe9a8542b4deec838c2650f6966863ea2711cc0cc5db51ca14") + depends_on("fortran", type="build") # generated + def setup_run_environment(self, env): for suffix in ("4", "d"): lib = find_libraries( diff --git a/var/spack/repos/builtin/packages/lapackpp/package.py b/var/spack/repos/builtin/packages/lapackpp/package.py index fcea2cc87574a8..c295cf716f6e1f 100644 --- a/var/spack/repos/builtin/packages/lapackpp/package.py +++ b/var/spack/repos/builtin/packages/lapackpp/package.py @@ -11,6 +11,7 @@ _versions = [ # LAPACK++, BLAS++ ["master", "master"], + ["2024.05.31", "2024.05.31"], ["2023.11.05", "2023.11.05"], ["2023.08.25", "2023.08.25"], ["2023.06.00", "2023.06.00"], @@ -36,6 +37,9 @@ class Lapackpp(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("master", branch="master") + version( + "2024.05.31", sha256="093646d492a4c2c6b4d7001effb559c80da7fa31fd5ba517a6d686ca8c78cd99" + ) version( "2023.11.05", sha256="9a505ef4e76504b6714cc19eb1b58939694f9ab51427a5bb915b016d615570ca" ) @@ -64,6 +68,8 @@ class Lapackpp(CMakePackage, CudaPackage, ROCmPackage): "2020.10.00", sha256="5f6ab3bd3794711818a3a50198efd29571520bf455e13ffa8ba50fa8376d7d1a" ) + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared library") variant("sycl", default=False, description="Build support for the SYCL backend") diff --git a/var/spack/repos/builtin/packages/last/package.py b/var/spack/repos/builtin/packages/last/package.py index bbc2e87a22df0e..a5419d8193c575 100644 --- a/var/spack/repos/builtin/packages/last/package.py +++ b/var/spack/repos/builtin/packages/last/package.py @@ -22,6 +22,9 @@ class Last(MakefilePackage): version("1282", commit="4368be912f4759e52b549940276f1adf087f489a") version("869", sha256="6371a6282bc1bb02a5e5013cc463625f2ce3e7746ff2ea0bdf9fe6b15605a67c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/lastz/package.py b/var/spack/repos/builtin/packages/lastz/package.py index 6f366e74b75762..d570d32c247a8d 100644 --- a/var/spack/repos/builtin/packages/lastz/package.py +++ b/var/spack/repos/builtin/packages/lastz/package.py @@ -19,6 +19,8 @@ class Lastz(MakefilePackage): version("1.04.03", sha256="c58ed8e37c4b0e82492b3a2b3e12447a3c40286fb8358906d19f10b0a713e9f4") version("1.04.00", sha256="a4c2c7a77430387e96dbc9f5bdc75874334c672be90f5720956c0f211abf9f5a") + depends_on("c", type="build") # generated + # Ref: https://github.com/lastz/lastz/commit/20aa14f483265b4eac97f25aca666c708b9655e4 patch("sequences.c.patch", when="@:1.04.03") diff --git a/var/spack/repos/builtin/packages/laszip/package.py b/var/spack/repos/builtin/packages/laszip/package.py index b6d5d763c3fb8f..30a2a58bbbb69d 100644 --- a/var/spack/repos/builtin/packages/laszip/package.py +++ b/var/spack/repos/builtin/packages/laszip/package.py @@ -16,3 +16,6 @@ class Laszip(CMakePackage): version("3.4.3", sha256="53f546a7f06fc969b38d1d71cceb1862b4fc2c4a0965191a0eee81a57c7b373d") version("3.4.1", sha256="5d9b0ffaf8b7319c2fa216da3f3f878bb8f4e5b4b14d2c154d441a351da2be37") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/latte/package.py b/var/spack/repos/builtin/packages/latte/package.py index ca5605f7248134..735d478a1dfe0b 100644 --- a/var/spack/repos/builtin/packages/latte/package.py +++ b/var/spack/repos/builtin/packages/latte/package.py @@ -23,6 +23,9 @@ class Latte(CMakePackage): version("1.2.1", sha256="a21dda5ebdcefa56e9ff7296d74ef03f89c200d2e110a02af7a84612668bf702") version("1.0.1", sha256="67b2957639ad8e36b69bc6ea9a13085183a881562af9ca6d2b90b412ff073789") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Build with mpi") variant("progress", default=False, description="Use progress for fast") variant("shared", default=True, description="Build shared libs") diff --git a/var/spack/repos/builtin/packages/launchmon/package.py b/var/spack/repos/builtin/packages/launchmon/package.py index 4ca7b03b1f8ae3..45f35f0eb30742 100644 --- a/var/spack/repos/builtin/packages/launchmon/package.py +++ b/var/spack/repos/builtin/packages/launchmon/package.py @@ -23,6 +23,9 @@ class Launchmon(AutotoolsPackage): ) version("1.0.2", sha256="1d301ccccfe0873efcd66da87ed5e4d7bafc560b00aee396d8a9365f53b3a33a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build", when="@master") depends_on("automake", type="build", when="@master") depends_on("libtool", type="build", when="@master") diff --git a/var/spack/repos/builtin/packages/lazygit/package.py b/var/spack/repos/builtin/packages/lazygit/package.py index de68d64575d995..517dbb29842195 100644 --- a/var/spack/repos/builtin/packages/lazygit/package.py +++ b/var/spack/repos/builtin/packages/lazygit/package.py @@ -17,4 +17,7 @@ class Lazygit(GoPackage): license("MIT") + version("0.41.0", sha256="f2176fa253588fe4b7118bf83f4316ae3ecb914ae1e99aad8c474e23cea49fb8") version("0.40.2", sha256="146bd63995fcf2f2373bbc2143b3565b7a2be49a1d4e385496265ac0f69e4128") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/lazyten/package.py b/var/spack/repos/builtin/packages/lazyten/package.py index b155958a882450..76edae2c609e40 100644 --- a/var/spack/repos/builtin/packages/lazyten/package.py +++ b/var/spack/repos/builtin/packages/lazyten/package.py @@ -25,6 +25,8 @@ class Lazyten(CMakePackage): version("develop", branch="master") version("0.4.1", sha256="696d151382993c13d04516c77db3ea712a70e3cb449539b9e79abc78cf245ae4") + depends_on("cxx", type="build") # generated + # # Variants # diff --git a/var/spack/repos/builtin/packages/lbann/package.py b/var/spack/repos/builtin/packages/lbann/package.py index 482d591a1c03af..63db92d0353caf 100644 --- a/var/spack/repos/builtin/packages/lbann/package.py +++ b/var/spack/repos/builtin/packages/lbann/package.py @@ -35,6 +35,8 @@ class Lbann(CachedCMakePackage, CudaPackage, ROCmPackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + variant( "build_type", default="Release", @@ -357,10 +359,6 @@ def initconfig_hardware_entries(self): cmake_cache_string("CMAKE_CUDA_FLAGS", "-allow-unsupported-compiler") ) - if "+rocm" in spec: - if "platform=cray" in spec: - entries.append(cmake_cache_option("MPI_ASSUME_NO_BUILTIN_MPI", True)) - return entries def initconfig_package_entries(self): @@ -402,12 +400,8 @@ def initconfig_package_entries(self): ) entries.append(cmake_cache_option("protobuf_MODULE_COMPATIBLE", True)) - if spec.satisfies("^python") and "+pfe" in spec: - entries.append( - cmake_cache_path( - "LBANN_PFE_PYTHON_EXECUTABLE", "{0}/python3".format(spec["python"].prefix.bin) - ) - ) + if spec.satisfies("+pfe ^python"): + entries.append(cmake_cache_path("LBANN_PFE_PYTHON_EXECUTABLE", python.path)) entries.append( cmake_cache_string("LBANN_PFE_PYTHONPATH", env["PYTHONPATH"]) ) # do NOT need to sub ; for : because diff --git a/var/spack/repos/builtin/packages/lbfgspp/package.py b/var/spack/repos/builtin/packages/lbfgspp/package.py index 688ceeb5b17788..cdf3082dac43b5 100644 --- a/var/spack/repos/builtin/packages/lbfgspp/package.py +++ b/var/spack/repos/builtin/packages/lbfgspp/package.py @@ -17,4 +17,6 @@ class Lbfgspp(CMakePackage): version("0.3.0", sha256="490720b9d5acce6459cb0336ca3ae0ffc48677225f0ebfb35c9bef6baefdfc6a") version("0.2.0", sha256="7101744a538c3aff52e10c82267305847b0b5e9d39f9974b4b29812cd1398ff9") + depends_on("cxx", type="build") # generated + depends_on("eigen @3:") diff --git a/var/spack/repos/builtin/packages/lbxproxy/package.py b/var/spack/repos/builtin/packages/lbxproxy/package.py index 4e6765a9c6c691..d7951ee599db2d 100644 --- a/var/spack/repos/builtin/packages/lbxproxy/package.py +++ b/var/spack/repos/builtin/packages/lbxproxy/package.py @@ -21,6 +21,8 @@ class Lbxproxy(AutotoolsPackage, XorgPackage): version("1.0.3", sha256="db36251c9656c7da720f31e10df384f8946a9a5395915371b60d9423ad8f6a80") + depends_on("c", type="build") # generated + depends_on("libxext") depends_on("liblbxutil") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/lc-framework/package.py b/var/spack/repos/builtin/packages/lc-framework/package.py new file mode 100644 index 00000000000000..085fb07bafe932 --- /dev/null +++ b/var/spack/repos/builtin/packages/lc-framework/package.py @@ -0,0 +1,50 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +def try_le(x, y): + try: + return int(x) < y + except ValueError: + False + + +class LcFramework(CMakePackage, CudaPackage): + """a framework for automatically creating high-speed lossless and + error-bounded lossy data compression and decompression algorithms.""" + + homepage = "https://userweb.cs.txstate.edu/~burtscher/LC/" + url = "https://github.com/robertu94/LC-framework/archive/refs/tags/1.1.1.tar.gz" + git = "https://github.com/robertu94/LC-framework" + + maintainers("robertu94") + + version("1.2.2", sha256="957c5da99bca4cfe125486c11b4b7dc6e38f9a158261aff3cd545e47ad9894a6") + version("1.2.1", commit="98102fdaf443c968ab1bea5f006060b1e4f2d0e7") + version("1.2.0", commit="2d0f39a927c3487551e4f3c786c3799cada1e203") + version("1.1.2", sha256="5ccbeaf8e2ef93894854406054210c8525055d195b39e2f141b4f81175fe2815") + + depends_on("cxx", type="build") # generated + + variant("libpressio", description="build a libpressio plugin for LC", default=False) + conflicts("+cuda", when="@:1.2.1") + for sm in [i for i in CudaPackage.cuda_arch_values if try_le(i, 60)]: + conflicts( + "cuda_arch={sm}".format(sm=sm), when="+cuda", msg="cuda_arch 60 or newer is required" + ) + + depends_on("python", type=("build",)) + depends_on("libpressio@0.98.0:", when="+libpressio") + depends_on("libpressio+cuda", when="+cuda+libpressio") + + def cmake_args(self): + args = [self.define_from_variant("LC_BUILD_LIBPRESSIO_PLUGIN", "libpressio")] + if "+cuda" in self.spec: + args.append(self.define_from_variant("LC_BUILD_CUDA", "cuda")) + args.append(self.builder.define_cuda_architectures(self)) + + return args diff --git a/var/spack/repos/builtin/packages/lcc/package.py b/var/spack/repos/builtin/packages/lcc/package.py index 4ed9f48ee2c477..4fe7b4462f67d2 100644 --- a/var/spack/repos/builtin/packages/lcc/package.py +++ b/var/spack/repos/builtin/packages/lcc/package.py @@ -24,6 +24,9 @@ class Lcc(CMakePackage): version("1.0.1", sha256="fa13364dcdf3b1f8d80fc768f0e7ad3849f8d98091fb96926100a6764f836020") version("1.0.0", sha256="750ce09e809a4e85ae3219fd537dc84a923fe3d3683b26b5d915eccfd1f0120c") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=False, description="Build shared libs") depends_on("cmake@3.10:", type="build") diff --git a/var/spack/repos/builtin/packages/lci/package.py b/var/spack/repos/builtin/packages/lci/package.py new file mode 100644 index 00000000000000..4a30ea36c9cdde --- /dev/null +++ b/var/spack/repos/builtin/packages/lci/package.py @@ -0,0 +1,200 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +def is_positive_int(val): + try: + return int(val) > 0 + except ValueError: + return val == "auto" + + +class Lci(CMakePackage): + """LCI: the Lightweight Communication Interface""" + + homepage = "https://github.com/uiuc-hpc/lci" + url = "https://github.com/uiuc-hpc/lci/archive/refs/tags/v1.7.7.tar.gz" + git = "https://github.com/uiuc-hpc/lci.git" + + maintainers("omor1", "JiakunYan") + + license("MIT") + + version("master", branch="master") + version("1.7.7", sha256="c310f699b7b4317a2f5c3557f85c240fe3c85d2d06618dd248434ef807d53779") + version("1.7.6", sha256="c88ccea2ad277ed38fc23187771b52b6fb212ed4429114717bfa8887ed21665c") + version("1.7.5", sha256="13e4084c9e7aaf55966ba5aa0423164b8fd21ee7526fc62017b3c9b3db99cb83") + version("1.7.4", sha256="00c6ef06bf90a02b55c72076dedf912580dcb1fb59fdc0e771d9e1a71283b72f") + version("1.7.3", sha256="3c47d51d4925e6700294ac060c88a73c26ca6e9df5b4010d0e90b0bf5e505040") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant( + "fabric", + default="ibv", + values=("ofi", "ibv", "ucx"), + multi=False, + description="Communication fabric", + ) + + variant("examples", default=False, description="Build LCI examples") + variant("tests", default=False, description="Build LCI tests") + variant("benchmarks", default=False, description="Build LCI benchmarks") + variant("docs", default=False, description="Build LCI documentation") + + variant( + "cache-line", + default="auto", + values=is_positive_int, + description="Cache line size, in bytes", + ) + + variant( + "multithread-progress", + default=True, + description="Enable thread-safe LCI_progress function", + ) + variant("dreg", default="auto", description="Whether to use registration cache by default") + variant( + "packet-size", + default="auto", + values=is_positive_int, + description="Size of packet by default", + ) + variant( + "npackets", + default="auto", + values=is_positive_int, + description="Number of packets by default", + ) + variant( + "fabric-nsends-max", + default="auto", + values=is_positive_int, + description="Max number of send descriptors that can be posted (send queue length) " + "at the fabric layer by default", + ) + variant( + "fabric-nrecvs-max", + default="auto", + values=is_positive_int, + description="Max number of receive descriptors that can be posted (receive queue length) " + "at the fabric layer by default", + ) + variant( + "fabric-ncqes-max", + default="auto", + values=is_positive_int, + description="Max number of completion queue entries that can be posted " + "(completion queue length) at the fabric layer by default", + ) + + variant("debug", default=False, description="Enable the debug mode") + variant("pcounter", default=False, description="Enable the performance counters") + variant( + "papi", default=False, description="Enable the PAPI plugin to collect hardware counters" + ) + + variant( + "enable-pm", + description="Process management backends to enable", + values=disjoint_sets(("auto",), ("pmix", "pmi2", "pmi1", "mpi", "local")) + .prohibit_empty_set() + .with_default("auto") + .with_non_feature_values("auto"), + ) + variant( + "default-pm", + description="Order of process management backends to try by default", + values=disjoint_sets(("auto",), ("pmix", "pmi2", "pmi1", "mpi", "local"), ("cray",)) + .prohibit_empty_set() + .with_default("auto") + .with_non_feature_values("auto"), + ) + + generator("ninja", "make", default="ninja") + + depends_on("cmake@3.12:", type="build") + depends_on("libfabric", when="fabric=ofi") + depends_on("rdma-core", when="fabric=ibv") + depends_on("ucx", when="fabric=ucx") + depends_on("mpi", when="enable-pm=mpi") + depends_on("papi", when="+papi") + depends_on("doxygen", when="+docs") + depends_on("cray-pmi", when="default-pm=cray") + + def cmake_args(self): + args = [ + self.define_from_variant("LCI_SERVER", "fabric"), + self.define("LCI_FORCE_SERVER", True), + self.define_from_variant("LCI_WITH_EXAMPLES", "examples"), + self.define_from_variant("LCI_WITH_TESTS", "tests"), + self.define_from_variant("LCI_WITH_BENCHMARKS", "benchmarks"), + self.define_from_variant("LCI_WITH_DOC", "docs"), + self.define_from_variant("LCI_ENABLE_MULTITHREAD_PROGRESS", "multithread-progress"), + self.define_from_variant("LCI_DEBUG", "debug"), + self.define_from_variant("LCI_USE_PERFORMANCE_COUNTER", "pcounter"), + self.define_from_variant("LCI_USE_PAPI", "papi"), + ] + + if not self.spec.satisfies("dreg=auto"): + args.append(self.define_from_variant("LCI_USE_DREG_DEFAULT", "dreg")) + + if not self.spec.satisfies("enable-pm=auto"): + args.extend( + [ + self.define( + "LCT_PMI_BACKEND_ENABLE_PMI1", self.spec.satisfies("enable-pm=pmi1") + ), + self.define( + "LCT_PMI_BACKEND_ENABLE_PMI2", self.spec.satisfies("enable-pm=pmi2") + ), + self.define( + "LCT_PMI_BACKEND_ENABLE_MPI", self.spec.satisfies("enable-pm=mpi") + ), + self.define( + "LCT_PMI_BACKEND_ENABLE_PMIX", self.spec.satisfies("enable-pm=pmix") + ), + ] + ) + + if self.spec.satisfies("default-pm=cray"): + args.extend( + [ + self.define("LCI_PMI_BACKEND_DEFAULT", "pmi1"), + self.define("LCT_PMI_BACKEND_ENABLE_PMI1", True), + ] + ) + elif not self.spec.satisfies("default-pm=auto"): + args.append(self.define_from_variant("LCI_PMI_BACKEND_DEFAULT", "default-pm")) + + if not self.spec.satisfies("cache-line=auto"): + args.append(self.define_from_variant("LCI_CACHE_LINE", "cache-line")) + + if not self.spec.satisfies("packet-size=auto"): + args.append(self.define_from_variant("LCI_PACKET_SIZE_DEFAULT", "packet-size")) + + if not self.spec.satisfies("npackets=auto"): + args.append(self.define_from_variant("LCI_SERVER_NUM_PKTS_DEFAULT", "npackets")) + + if not self.spec.satisfies("fabric-nsends-max=auto"): + args.append( + self.define_from_variant("LCI_SERVER_MAX_SENDS_DEFAULT", "fabric-nsends-max") + ) + + if not self.spec.satisfies("fabric-nrecvs-max=auto"): + args.append( + self.define_from_variant("LCI_SERVER_MAX_RECVS_DEFAULT", "fabric-nrecvs-max") + ) + + if not self.spec.satisfies("fabric-ncqes-max=auto"): + args.append( + self.define_from_variant("LCI_SERVER_MAX_CQES_DEFAULT", "fabric-ncqes-max") + ) + + return args diff --git a/var/spack/repos/builtin/packages/lcio/package.py b/var/spack/repos/builtin/packages/lcio/package.py index f38550f748fe1a..6aca54b81dd21c 100644 --- a/var/spack/repos/builtin/packages/lcio/package.py +++ b/var/spack/repos/builtin/packages/lcio/package.py @@ -21,6 +21,7 @@ class Lcio(CMakePackage): license("BSD-3-Clause") version("master", branch="master") + version("2.22", sha256="95676977a0427f5ecc857e8504b13f332c2c2e5769dc00f6beecff3c73dab395") version("2.21", sha256="a9f0a9922ab2ef17c6f1b8f7187bfc341f27567745a43c0480c103b617dfcea6") version("2.20.2", sha256="b37cee344c28ccddc590e5317721b375ef19f4392ae067bc86583107acaf2374") version("2.20.1", sha256="125f657297de12b40694cb0dddec1d1ce3379058492f2a6a2a6f992ee51604d6") @@ -43,6 +44,8 @@ class Lcio(CMakePackage): version("2.13.2", sha256="9f153ba13e56ee16795378f9192678d40df1faca51d00aaa8fb80547bfecb8d8") version("2.13.1", sha256="aa572e2ba38c0cadd6a92fa933c3ed97e21d016c7982578d3f293901169f4ec0") + depends_on("cxx", type="build") # generated + variant( "cxxstd", default="17", diff --git a/var/spack/repos/builtin/packages/lcms/package.py b/var/spack/repos/builtin/packages/lcms/package.py index 5fcf28bf7f9722..6bb8d05941678f 100644 --- a/var/spack/repos/builtin/packages/lcms/package.py +++ b/var/spack/repos/builtin/packages/lcms/package.py @@ -16,11 +16,17 @@ class Lcms(AutotoolsPackage): license("MIT") + version("2.16", sha256="d873d34ad8b9b4cea010631f1a6228d2087475e4dc5e763eb81acc23d9d45a51") + version("2.15", sha256="b20cbcbd0f503433be2a4e81462106fa61050a35074dc24a4e356792d971ab39") + version("2.14", sha256="28474ea6f6591c4d4cee972123587001a4e6e353412a41b3e9e82219818d5740") version("2.13.1", sha256="d473e796e7b27c5af01bd6d1552d42b45b43457e7182ce9903f38bb748203b88") version("2.9", sha256="48c6fdf98396fa245ed86e622028caf49b96fa22f3e5734f853f806fbc8e7d20") version("2.8", sha256="66d02b229d2ea9474e62c2b6cd6720fde946155cd1d0d2bffdab829790a0fb22") version("2.6", sha256="5172528839647c54c3da211837225e221be93e4733f5b5e9f57668f7107e14b1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): url = "http://downloads.sourceforge.net/project/lcms/lcms/{0}/lcms2-{1}.tar.gz" return url.format(version.up_to(2), version) diff --git a/var/spack/repos/builtin/packages/lcov/package.py b/var/spack/repos/builtin/packages/lcov/package.py index 9794fb69e533ba..96a25f96a36ff1 100644 --- a/var/spack/repos/builtin/packages/lcov/package.py +++ b/var/spack/repos/builtin/packages/lcov/package.py @@ -14,15 +14,21 @@ class Lcov(MakefilePackage): homepage = "http://ltp.sourceforge.net/coverage/lcov.php" url = "https://github.com/linux-test-project/lcov/releases/download/v2.0/lcov-2.0.tar.gz" + git = "https://github.com/linux-test-project/lcov.git" + maintainers("KineticTheory") license("GPL-2.0-or-later") + version("master", branch="master") version("2.0", sha256="1857bb18e27abe8bcec701a907d5c47e01db4d4c512fc098d1a6acd29267bf46") version("1.16", sha256="987031ad5528c8a746d4b52b380bc1bffe412de1f2b9c2ba5224995668e3240b") version("1.15", sha256="c1cda2fa33bec9aa2c2c73c87226cfe97de0831887176b45ee523c5e30f8053a") version("1.14", sha256="14995699187440e0ae4da57fe3a64adc0a3c5cf14feab971f8db38fb7d8f071a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # dependencies from # https://github.com/linux-test-project/lcov/blob/02ece21d54ccd16255d74f8b00f8875b6c15653a/README#L91-L111 depends_on("perl", type=("build", "run")) @@ -51,6 +57,7 @@ class Lcov(MakefilePackage): depends_on("perl-specio", type=("run")) depends_on("perl-sub-identify", type=("run")) depends_on("perl-time-hires", type=("run")) + depends_on("perl-timedate", type=("run")) def install(self, spec, prefix): make( diff --git a/var/spack/repos/builtin/packages/ldak/package.py b/var/spack/repos/builtin/packages/ldak/package.py index 9dd4638c30045e..c4855de475343e 100644 --- a/var/spack/repos/builtin/packages/ldak/package.py +++ b/var/spack/repos/builtin/packages/ldak/package.py @@ -40,7 +40,6 @@ class Ldak(Package): policy="one_of", msg="Only mkl or openblas are supported for blas/lapack with ldak", ) - conflicts("platform=cray", when="~glpk", msg="bundled qsopt only for linux or mac") phases = ["build", "install"] diff --git a/var/spack/repos/builtin/packages/ldc-bootstrap/package.py b/var/spack/repos/builtin/packages/ldc-bootstrap/package.py index 7c9730c03d011a..c51e3016170151 100644 --- a/var/spack/repos/builtin/packages/ldc-bootstrap/package.py +++ b/var/spack/repos/builtin/packages/ldc-bootstrap/package.py @@ -26,6 +26,9 @@ class LdcBootstrap(CMakePackage): # This is the last version that does not require a D compiler to bootstrap version("0.17.4", sha256="48428afde380415640f3db4e38529345f3c8485b1913717995547f907534c1c3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("llvm@3.7:") depends_on("zlib-api") depends_on("libconfig") diff --git a/var/spack/repos/builtin/packages/ldc/package.py b/var/spack/repos/builtin/packages/ldc/package.py index a297edf5b7f126..5a75282f05f791 100644 --- a/var/spack/repos/builtin/packages/ldc/package.py +++ b/var/spack/repos/builtin/packages/ldc/package.py @@ -23,6 +23,9 @@ class Ldc(CMakePackage): version("1.3.0", sha256="efe31a639bcb44e1f5b752da21713376d9410a01279fecc8aab8572065a3050b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build runtime and tooling as shared libs") depends_on("llvm@3.9:") diff --git a/var/spack/repos/builtin/packages/legion/package.py b/var/spack/repos/builtin/packages/legion/package.py index ddf4deffd99ef9..0663518d2ea6c4 100644 --- a/var/spack/repos/builtin/packages/legion/package.py +++ b/var/spack/repos/builtin/packages/legion/package.py @@ -25,8 +25,12 @@ class Legion(CMakePackage, ROCmPackage): homepage = "https://legion.stanford.edu/" git = "https://github.com/StanfordLegion/legion.git" + license("Apache-2.0") + maintainers("pmccormick", "streichler", "elliottslaughter") tags = ["e4s"] + version("24.06.0", tag="legion-24.06.0", commit="3f27977943626ef23038ef0049b7ad1b389caad1") + version("24.03.0", tag="legion-24.03.0", commit="c61071541218747e35767317f6f89b83f374f264") version("23.12.0", tag="legion-23.12.0", commit="8fea67ee694a5d9fb27232a7976af189d6c98456") version("23.09.0", tag="legion-23.09.0", commit="7304dfcf9b69005dd3e65e9ef7d5bd49122f9b49") version("23.06.0", tag="legion-23.06.0", commit="7b5ff2fb9974511c28aec8d97b942f26105b5f6d") @@ -42,6 +46,15 @@ class Legion(CMakePackage, ROCmPackage): version("stable", branch="stable") version("master", branch="master") + # Old control replication commits used by FleCSI releases, prior to 24.03.0 + version("cr-20230307", commit="435183796d7c8b6ac1035a6f7af480ded750f67d", deprecated=True) + version("cr-20210122", commit="181e63ad4187fbd9a96761ab3a52d93e157ede20", deprecated=True) + version("cr-20191217", commit="572576b312509e666f2d72fafdbe9d968b1a6ac3", deprecated=True) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.16:", type="build") # TODO: Need to spec version of MPI v3 for use of the low-level MPI transport # layer. At present the MPI layer is still experimental and we discourge its @@ -53,8 +66,10 @@ class Legion(CMakePackage, ROCmPackage): depends_on("mpi", when="conduit=mpi") depends_on("cuda@10.0:11.9", when="+cuda_unsupported_compiler @21.03.0:23.03.0") depends_on("cuda@10.0:11.9", when="+cuda @21.03.0:23.03.0") - depends_on("cuda@10.0:12.2", when="+cuda_unsupported_compiler") - depends_on("cuda@10.0:12.2", when="+cuda") + depends_on("cuda@10.0:", when="+cuda_unsupported_compiler") + depends_on("cuda@10.0:", when="+cuda") + depends_on("hip@5.1:5.7", when="+rocm @23.03.0:23.12.0") + depends_on("hip@5.1:", when="+rocm") depends_on("hdf5", when="+hdf5") depends_on("hwloc", when="+hwloc") @@ -62,12 +77,12 @@ class Legion(CMakePackage, ROCmPackage): cuda_arch_list = CudaPackage.cuda_arch_values for nvarch in cuda_arch_list: depends_on( - "kokkos@3.3.01:+cuda+cuda_lambda+wrapper cuda_arch={0}".format(nvarch), - when="%gcc+kokkos+cuda cuda_arch={0}".format(nvarch), + f"kokkos@3.3.01:+cuda+cuda_lambda+wrapper cuda_arch={nvarch}", + when=f"%gcc+kokkos+cuda cuda_arch={nvarch}", ) depends_on( - "kokkos@3.3.01:+cuda+cuda_lambda~wrapper cuda_arch={0}".format(nvarch), - when="%clang+kokkos+cuda cuda_arch={0}".format(nvarch), + f"kokkos@3.3.01:+cuda+cuda_lambda~wrapper cuda_arch={nvarch}", + when=f"%clang+kokkos+cuda cuda_arch={nvarch}", ) depends_on("kokkos@3.3.01:~cuda", when="+kokkos~cuda") @@ -75,7 +90,6 @@ class Legion(CMakePackage, ROCmPackage): # https://github.com/spack/spack/issues/37232#issuecomment-1553376552 patch("hip-offload-arch.patch", when="@23.03.0 +rocm") - patch("update-hip-path-legion-23.06.0.patch", when="@23.06.0:23.12.0 ^hip@6.0 +rocm") def patch(self): if "network=gasnet conduit=ofi-slingshot11 ^cray-mpich+wrappers" in self.spec: @@ -103,10 +117,7 @@ def patch(self): ) for arch in ROCmPackage.amdgpu_targets: - depends_on( - "kokkos@3.3.01:+rocm amdgpu_target={0}".format(arch), - when="+rocm amdgpu_target={0}".format(arch), - ) + depends_on(f"kokkos@3.3.01:+rocm amdgpu_target={arch}", when=f"+rocm amdgpu_target={arch}") depends_on("kokkos@3.3.01:+rocm", when="+kokkos+rocm") @@ -114,6 +125,9 @@ def patch(self): depends_on("python@3.8:", when="+python") depends_on("py-cffi", when="+python") depends_on("py-numpy", when="+python") + depends_on("py-pip", when="+python", type="build") + depends_on("py-setuptools", when="+python", type="build") + depends_on("papi", when="+papi") depends_on("zlib-api", when="+zlib") @@ -121,8 +135,8 @@ def patch(self): # but this might be helpful for other use cases down the road. Legion's # current development policy is C++11 or greater so we capture that aspect # here. - cpp_stds = ["11", "14", "17", "20"] - variant("cxxstd", default="11", description="C++ standard", values=cpp_stds, multi=False) + cpp_stds = (conditional("11", "14", when="@:24.03.0"), "17", "20") + variant("cxxstd", default="17", description="C++ standard", values=cpp_stds, multi=False) # Network transport layer: the underlying data transport API should be used for # distributed data movement. For Legion, gasnet is the currently the most @@ -259,6 +273,12 @@ def validate_gasnet_root(value): variant( "redop_complex", default=False, description="Use reduction operators for complex types." ) + requires("+redop_complex", when="+bindings") + variant( + "redop_half", + default=False, + description="Use reduction operators for half precision types.", + ) variant( "max_dims", @@ -278,14 +298,21 @@ def validate_gasnet_root(value): default=1024, description="Maximum number of nodes supported by Legion.", ) + variant("prof", default=False, description="Install Rust Legion prof") + + depends_on("rust@1.74:", type="build", when="+prof") + + variant("gc", default=False, description="Enable garbage collector logging") + variant( + "sysomp", default=False, description="Use system OpenMP implementation instead of Realm's" + ) def cmake_args(self): spec = self.spec - cmake_cxx_flags = [] from_variant = self.define_from_variant options = [from_variant("CMAKE_CXX_STANDARD", "cxxstd")] - if "network=gasnet" in spec: + if spec.satisfies("network=gasnet"): options.append("-DLegion_NETWORKS=gasnetex") if spec.variants["gasnet_root"].value != "none": gasnet_dir = spec.variants["gasnet_root"].value @@ -304,110 +331,114 @@ def cmake_args(self): else: options.append("-DGASNet_CONDUIT=%s" % gasnet_conduit) - if "+gasnet_debug" in spec: + if spec.satisfies("+gasnet_debug"): options.append("-DLegion_EMBED_GASNet_CONFIGURE_ARGS=--enable-debug") - elif "network=mpi" in spec: + elif spec.satisfies("network=mpi"): options.append("-DLegion_NETWORKS=mpi") - elif "network=ucx" in spec: + elif spec.satisfies("network=ucx"): options.append("-DLegion_NETWORKS=ucx") else: options.append("-DLegion_EMBED_GASNet=OFF") - if "+shared" in spec: + if spec.satisfies("+shared"): options.append("-DBUILD_SHARED_LIBS=ON") else: options.append("-DBUILD_SHARED_LIBS=OFF") - if "+bounds_checks" in spec: + if spec.satisfies("+bounds_checks"): # default is off. options.append("-DLegion_BOUNDS_CHECKS=ON") - if "+privilege_checks" in spec: + if spec.satisfies("+privilege_checks"): # default is off. options.append("-DLegion_PRIVILEGE_CHECKS=ON") - if "output_level" in spec: - level = str.upper(spec.variants["output_level"].value) - options.append("-DLegion_OUTPUT_LEVEL=%s" % level) - if "+spy" in spec: + + options.append(f"-DLegion_OUTPUT_LEVEL={str.upper(spec.variants['output_level'].value)}") + + if spec.satisfies("+spy"): # default is off. options.append("-DLegion_SPY=ON") - if "+cuda" in spec: + if spec.satisfies("+cuda"): cuda_arch = spec.variants["cuda_arch"].value options.append("-DLegion_USE_CUDA=ON") options.append("-DLegion_GPU_REDUCTIONS=ON") options.append("-DLegion_CUDA_ARCH=%s" % cuda_arch) - if "+cuda_hijack" in spec: + if spec.satisfies("+cuda_hijack"): options.append("-DLegion_HIJACK_CUDART=ON") else: options.append("-DLegion_HIJACK_CUDART=OFF") - if "+cuda_unsupported_compiler" in spec: + if spec.satisfies("+cuda_unsupported_compiler"): options.append("-DCUDA_NVCC_FLAGS:STRING=--allow-unsupported-compiler") - if "+rocm" in spec: + if spec.satisfies("+rocm"): options.append("-DLegion_USE_HIP=ON") options.append("-DLegion_GPU_REDUCTIONS=ON") options.append(from_variant("Legion_HIP_TARGET", "hip_target")) options.append(from_variant("Legion_HIP_ARCH", "amdgpu_target")) options.append(from_variant("Legion_HIJACK_HIP", "hip_hijack")) - options.append(self.define("HIP_PATH", "{0}/hip".format(spec["hip"].prefix))) - if "^hip@:5.7" in spec: - options.append(self.define("HIP_PATH", "{0}/hip".format(spec["hip"].prefix))) - elif "^hip@6.0:" in spec: - options.append(self.define("HIP_PATH", "{0}".format(spec["hip"].prefix))) + if spec.satisfies("@23.03.0:23.12.0"): + options.append(self.define("HIP_PATH", f"{spec['hip'].prefix}/hip")) + else: + options.append(self.define("ROCM_PATH", spec["hip"].prefix)) - if "+fortran" in spec: + if spec.satisfies("+fortran"): # default is off. options.append("-DLegion_USE_Fortran=ON") - if "+hdf5" in spec: + if spec.satisfies("+hdf5"): # default is off. options.append("-DLegion_USE_HDF5=ON") - if "+hwloc" in spec: + if spec.satisfies("+hwloc"): # default is off. options.append("-DLegion_USE_HWLOC=ON") - if "+kokkos" in spec: + if spec.satisfies("+kokkos"): # default is off. options.append("-DLegion_USE_Kokkos=ON") os.environ["KOKKOS_CXX_COMPILER"] = spec["kokkos"].kokkos_cxx + if spec.satisfies("+cuda+cuda_unsupported_compiler ^kokkos%clang +cuda"): + # Keep CMake CUDA compiler detection happy + options.append( + self.define("CMAKE_CUDA_FLAGS", "--allow-unsupported-compiler -std=c++17") + ) - if "+libdl" in spec: + if spec.satisfies("+libdl"): # default is on. options.append("-DLegion_USE_LIBDL=ON") else: options.append("-DLegion_USE_LIBDL=OFF") - if "+openmp" in spec: + if spec.satisfies("+openmp"): # default is off. options.append("-DLegion_USE_OpenMP=ON") - if "+papi" in spec: + if spec.satisfies("+papi"): # default is off. options.append("-DLegion_USE_PAPI=ON") - if "+python" in spec: + if spec.satisfies("+python"): # default is off. options.append("-DLegion_USE_Python=ON") - if "+zlib" in spec: + if spec.satisfies("+zlib"): # default is on. options.append("-DLegion_USE_ZLIB=ON") else: options.append("-DLegion_USE_ZLIB=OFF") - if "+redop_complex" in spec: - # default is off. - options.append("-DLegion_REDOP_COMPLEX=ON") - - if "+bindings" in spec: + if spec.satisfies("+bindings"): # default is off. options.append("-DLegion_BUILD_BINDINGS=ON") - options.append("-DLegion_REDOP_COMPLEX=ON") # required for bindings - if spec.variants["build_type"].value == "Debug": - cmake_cxx_flags.extend(["-DDEBUG_REALM", "-DDEBUG_LEGION", "-ggdb"]) + if spec.satisfies("+redop_complex"): + # default is off + options.append("-DLegion_REDOP_COMPLEX=ON") + + if spec.satisfies("+redop_half"): + # default is off + options.append("-DLegion_REDOP_HALF=ON") maxdims = int(spec.variants["max_dims"].value) # TODO: sanity check if maxdims < 0 || > 9??? @@ -438,43 +469,56 @@ def cmake_args(self): # This disables Legion's CMake build system's logic for targeting the native # CPU architecture in favor of Spack-provided compiler flags options.append("-DBUILD_MARCH:STRING=") + + if spec.satisfies("+openmp +sysomp"): + options.append("-DLegion_OpenMP_SYSTEM_RUNTIME=ON") + + if spec.satisfies("+gc"): + options.append("-DCMAKE_CXX_FLAGS=-DLEGION_GC") + return options + def build(self, spec, prefix): + super().build(spec, prefix) + if spec.satisfies("+prof"): + with working_dir(join_path(self.stage.source_path, "tools", "legion_prof_rs")): + cargo = which("cargo") + cargo("install", "--root", "out", "--path", ".", "--all-features", "--locked") + + def install(self, spec, prefix): + super().install(spec, prefix) + if spec.satisfies("+prof"): + with working_dir(join_path(self.stage.source_path, "tools", "legion_prof_rs")): + install_tree("out", prefix) + @run_after("install") def cache_test_sources(self): """Copy the example source files after the package is installed to an install test subdirectory for use during `spack test run`.""" self.cache_extra_test_sources([join_path("examples", "local_function_tasks")]) - def run_local_function_tasks_test(self): - """Run stand alone test: local_function_tasks""" + def test_run_local_function_tasks(self): + """Build and run external application example""" test_dir = join_path( self.test_suite.current_test_cache_dir, "examples", "local_function_tasks" ) if not os.path.exists(test_dir): - print("Skipping local_function_tasks test") - return - - exe = "local_function_tasks" + raise SkipTest(f"{test_dir} must exist") cmake_args = [ - "-DCMAKE_C_COMPILER={0}".format(self.compiler.cc), - "-DCMAKE_CXX_COMPILER={0}".format(self.compiler.cxx), - "-DLegion_DIR={0}".format(join_path(self.prefix, "share", "Legion", "cmake")), + f"-DCMAKE_C_COMPILER={self.compiler.cc}", + f"-DCMAKE_CXX_COMPILER={self.compiler.cxx}", + f"-DLegion_DIR={join_path(self.prefix, 'share', 'Legion', 'cmake')}", ] - self.run_test( - "cmake", - options=cmake_args, - purpose="test: generate makefile for {0} example".format(exe), - work_dir=test_dir, - ) - - self.run_test("make", purpose="test: build {0} example".format(exe), work_dir=test_dir) + with working_dir(test_dir): + cmake = self.spec["cmake"].command + cmake(*cmake_args) - self.run_test(exe, purpose="test: run {0} example".format(exe), work_dir=test_dir) + make = which("make") + make() - def test(self): - self.run_local_function_tasks_test() + exe = which("local_function_tasks") + exe() diff --git a/var/spack/repos/builtin/packages/legion/update-hip-path-legion-23.06.0.patch b/var/spack/repos/builtin/packages/legion/update-hip-path-legion-23.06.0.patch deleted file mode 100644 index 9f7f6a7a86d114..00000000000000 --- a/var/spack/repos/builtin/packages/legion/update-hip-path-legion-23.06.0.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/cmake/FindHIP.cmake b/cmake/FindHIP.cmake -index f86edd2..24492ad 100644 ---- a/cmake/FindHIP.cmake -+++ b/cmake/FindHIP.cmake -@@ -22,7 +22,7 @@ if(NOT DEFINED HIP_PATH) - set(HIP_PATH $ENV{HIP_PATH} CACHE PATH "Path to where HIP has been installed") - endif() - endif() --include(${HIP_PATH}/cmake/FindHIP.cmake) -+include(${HIP_PATH}/lib/cmake/hip/FindHIP.cmake) - - if(NOT HIP_INCLUDE_DIRS) - list(APPEND HIP_INCLUDE_DIRS diff --git a/var/spack/repos/builtin/packages/lemon/package.py b/var/spack/repos/builtin/packages/lemon/package.py index 21effe4636ef64..8c770a3c230e94 100644 --- a/var/spack/repos/builtin/packages/lemon/package.py +++ b/var/spack/repos/builtin/packages/lemon/package.py @@ -17,6 +17,8 @@ class Lemon(CMakePackage): version("1.3.1", sha256="71b7c725f4c0b4a8ccb92eb87b208701586cf7a96156ebd821ca3ed855bad3c8") + depends_on("cxx", type="build") # generated + # variant("coin", default=False, description="Enable Coin solver backend") #TODO build fails variant("ilog", default=False, description="Enable ILOG (CPLEX) solver backend") variant("glpk", default=True, description="Enable GLPK solver backend") diff --git a/var/spack/repos/builtin/packages/leptonica/package.py b/var/spack/repos/builtin/packages/leptonica/package.py index 2f941a289fed3a..25cfd3f3730ddc 100644 --- a/var/spack/repos/builtin/packages/leptonica/package.py +++ b/var/spack/repos/builtin/packages/leptonica/package.py @@ -15,12 +15,16 @@ class Leptonica(CMakePackage): license("custom") + version("1.84.1", sha256="ecd7a868403b3963c4e33623595d77f2c87667e2cfdd9b370f87729192061bef") version("1.83.1", sha256="4289d0a4224b614010072253531c0455a33a4d7c7a0017fe7825ed382290c0da") version("1.81.0", sha256="70ebc04ff8b9684205bd1d01843c635a8521255b74813bf7cce9a33368f7952c") version("1.80.0", sha256="3952b974ec057d24267aae48c54bca68ead8275604bf084a73a4b953ff79196e") version("1.79.0", sha256="bf9716f91a4844c2682a07ef21eaf68b6f1077af1f63f27c438394fd66218e17") version("1.78.0", sha256="f8ac4d93cc76b524c2c81d27850bfc342e68b91368aa7a1f7d69e34ce13adbb4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("giflib") depends_on("jpeg") depends_on("libpng") @@ -30,6 +34,6 @@ class Leptonica(CMakePackage): depends_on("openjpeg") def cmake_args(self): - args = ["-DBUILD_SHARED_LIBS=ON"] + args = [self.define("BUILD_SHARED_LIBS", "ON")] return args diff --git a/var/spack/repos/builtin/packages/lerc/package.py b/var/spack/repos/builtin/packages/lerc/package.py index 0e7137118099cc..3ce249af434b64 100644 --- a/var/spack/repos/builtin/packages/lerc/package.py +++ b/var/spack/repos/builtin/packages/lerc/package.py @@ -22,6 +22,8 @@ class Lerc(CMakePackage): version("4.0.0", sha256="91431c2b16d0e3de6cbaea188603359f87caed08259a645fd5a3805784ee30a0") version("3.0", sha256="8c0148f5c22d823eff7b2c999b0781f8095e49a7d3195f13c68c5541dd5740a1") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.11:", type="build") depends_on("cmake@3.12:", type="build", when="@4.0.0:") diff --git a/var/spack/repos/builtin/packages/lesstif/package.py b/var/spack/repos/builtin/packages/lesstif/package.py index 8c936d91566274..214cfe2336e2ce 100644 --- a/var/spack/repos/builtin/packages/lesstif/package.py +++ b/var/spack/repos/builtin/packages/lesstif/package.py @@ -16,6 +16,8 @@ class Lesstif(AutotoolsPackage): version("0.95.2", sha256="eb4aa38858c29a4a3bcf605cfe7d91ca41f4522d78d770f69721e6e3a4ecf7e3") + depends_on("c", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("static", default=False, description="Build static libraries") diff --git a/var/spack/repos/builtin/packages/leveldb/package.py b/var/spack/repos/builtin/packages/leveldb/package.py index 1eaadf2058daa6..679a913a886604 100644 --- a/var/spack/repos/builtin/packages/leveldb/package.py +++ b/var/spack/repos/builtin/packages/leveldb/package.py @@ -23,6 +23,9 @@ class Leveldb(CMakePackage): version("1.20", sha256="f5abe8b5b209c2f36560b75f32ce61412f39a2922f7045ae764a2c23335b6664") version("1.18", sha256="4aa1a7479bc567b95a59ac6fb79eba49f61884d6fd400f20b7af147d54c5cee5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared library") depends_on("cmake@3.9:", when="@1.21:", type="build") diff --git a/var/spack/repos/builtin/packages/lfortran/package.py b/var/spack/repos/builtin/packages/lfortran/package.py index 50f157e1be8e15..a2d3bec19b7147 100644 --- a/var/spack/repos/builtin/packages/lfortran/package.py +++ b/var/spack/repos/builtin/packages/lfortran/package.py @@ -21,6 +21,10 @@ class Lfortran(CMakePackage): version("0.30.0", sha256="aafdfbfe81d69ceb3650ae1cf9bcd8a1f1532d895bf88f3071fe9610859bcd6f") version("0.19.0", sha256="d496f61d7133b624deb3562677c0cbf98e747262babd4ac010dbd3ab4303d805") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("llvm", default=True, description="Build with LLVM support") variant("stacktrace", default=True, description="Build with stacktrace support") diff --git a/var/spack/repos/builtin/packages/lftp/package.py b/var/spack/repos/builtin/packages/lftp/package.py index eebdb596a487aa..f5bce1fc233802 100644 --- a/var/spack/repos/builtin/packages/lftp/package.py +++ b/var/spack/repos/builtin/packages/lftp/package.py @@ -21,6 +21,9 @@ class Lftp(AutotoolsPackage): version("4.7.7", sha256="7bce216050094a1146ed05bed8fe5b3518224764ffe98884a848d44dc76fff8f") version("4.6.4", sha256="791e783779d3d6b519d0c23155430b9785f2854023eb834c716f5ba78873b15a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("expat") depends_on("gettext") depends_on("iconv") @@ -37,10 +40,10 @@ def configure_args(self): "--with-zlib={0}".format(self.spec["zlib-api"].prefix), "--disable-dependency-tracking", ] - if self.spec["iconv"].name == "libc": - args.append("--without-libiconv-prefix") + if self.spec["iconv"].name == "libiconv": + args.append(f"--with-libiconv-prefix={self.spec['iconv'].prefix}") elif not is_system_path(self.spec["iconv"].prefix): - args.append("--with-libiconv-prefix={0}".format(self.spec["iconv"].prefix)) + args.append("--without-libiconv-prefix") if "intl" not in self.spec["gettext"].libs.names: args.append("--without-libintl-prefix") elif not is_system_path(self.spec["gettext"].prefix): diff --git a/var/spack/repos/builtin/packages/lhapdf/package.py b/var/spack/repos/builtin/packages/lhapdf/package.py index 2a9bc2583cd4fd..c38f7b31606be8 100644 --- a/var/spack/repos/builtin/packages/lhapdf/package.py +++ b/var/spack/repos/builtin/packages/lhapdf/package.py @@ -31,6 +31,9 @@ class Lhapdf(AutotoolsPackage): version("6.3.0", sha256="864468439c7662bbceed6c61c7132682ec83381a23c9c9920502fdd7329dd816") version("6.2.3", sha256="37200a1ab70247250a141dfed7419d178f9a83bd23a4f8a38e203d4e27b41308") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("python", default=True, description="Build python bindings") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/lhapdf5/package.py b/var/spack/repos/builtin/packages/lhapdf5/package.py index 94fa2b369c2dc0..952a42a4a09aed 100644 --- a/var/spack/repos/builtin/packages/lhapdf5/package.py +++ b/var/spack/repos/builtin/packages/lhapdf5/package.py @@ -29,6 +29,10 @@ class Lhapdf5(AutotoolsPackage): version("5.8.0", sha256="8381ea5f785dde95772a2b6d5890f1cb72012e223e6861823fd81b09eedaa7a3") version("5.7.1", sha256="40529629351598317fbf7b5905661e51b23778019d50451eee78d7b1118e2559") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + def setup_build_environment(self, env): env.append_flags("FFLAGS", "-std=legacy") diff --git a/var/spack/repos/builtin/packages/libabigail/package.py b/var/spack/repos/builtin/packages/libabigail/package.py index 1d5cf3071f3de6..ecc8c645b05c39 100644 --- a/var/spack/repos/builtin/packages/libabigail/package.py +++ b/var/spack/repos/builtin/packages/libabigail/package.py @@ -16,9 +16,13 @@ class Libabigail(AutotoolsPackage): license("Apache-2.0 WITH LLVM-exception") version("master", branch="master") + version("2.1", sha256="4a6297d41d15d1936256117116bd61296e6b9bee23d54a0caf8d3f5ab8ddcc4c") version("2.0", sha256="3704ae97a56bf076ca08fb5dea6b21db998fbbf14c4f9de12824b78db53b6fda") version("1.8", sha256="1cbf260b894ccafc61b2673ba30c020c3f67dbba9dfa88dca3935dff661d665c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("docs", default=False, description="build documentation") depends_on("elfutils", type=("build", "link")) @@ -40,7 +44,7 @@ class Libabigail(AutotoolsPackage): def configure_args(self): spec = self.spec - config_args = ["CPPFLAGS=-I{0}/include".format(spec["libxml2"].prefix)] + config_args = [f"CPPFLAGS=-I{spec['libxml2'].prefix}/include"] config_args.append( "LDFLAGS=-L{0} -Wl,-rpath,{0}".format(spec["libxml2"].libs.directories[0]) ) diff --git a/var/spack/repos/builtin/packages/libaec/package.py b/var/spack/repos/builtin/packages/libaec/package.py index 5c2a21a5c6671f..f0498b3fd0dec5 100644 --- a/var/spack/repos/builtin/packages/libaec/package.py +++ b/var/spack/repos/builtin/packages/libaec/package.py @@ -29,6 +29,9 @@ class Libaec(CMakePackage): version("1.0.1", sha256="3668eb4ed36724441e488a7aadc197426afef4b1e8bd139af6d3e36023906459") version("1.0.0", sha256="849f08b08ddaaffe543d06d0ced5e4ee3e526b13a67c5f422d126b1c9cf1b546") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Builds a shared version of the library") @property diff --git a/var/spack/repos/builtin/packages/libaio/package.py b/var/spack/repos/builtin/packages/libaio/package.py index 9e01952ff898c7..4e43322098ba10 100644 --- a/var/spack/repos/builtin/packages/libaio/package.py +++ b/var/spack/repos/builtin/packages/libaio/package.py @@ -27,6 +27,8 @@ class Libaio(MakefilePackage): version("0.3.113", sha256="2c44d1c5fd0d43752287c9ae1eb9c023f04ef848ea8d4aafa46e9aedb678200b") version("0.3.110", sha256="e019028e631725729376250e32b473012f7cb68e1f7275bfc1bbcdd0f8745f7e") + depends_on("c", type="build") # generated + conflicts("platform=darwin", msg="libaio is a linux specific library") @property diff --git a/var/spack/repos/builtin/packages/libao/package.py b/var/spack/repos/builtin/packages/libao/package.py index d93e765e2ff9f8..1326940964b4d5 100644 --- a/var/spack/repos/builtin/packages/libao/package.py +++ b/var/spack/repos/builtin/packages/libao/package.py @@ -18,6 +18,8 @@ class Libao(AutotoolsPackage): version("1.2.0", sha256="5ec2d15ee39f218e93a87f5cc8508aaebf5c8b544f42488dcb2b504d97392c99") version("1.1.0", sha256="69edc39fa2759133edfcdee0ec47559067a1a8e7cd718db0eb3c82ca4254aa6b") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libapplewm/package.py b/var/spack/repos/builtin/packages/libapplewm/package.py index d3d4d579ffebf3..9486a10c269c4e 100644 --- a/var/spack/repos/builtin/packages/libapplewm/package.py +++ b/var/spack/repos/builtin/packages/libapplewm/package.py @@ -18,6 +18,8 @@ class Libapplewm(AutotoolsPackage, XorgPackage): version("1.4.1", sha256="d7fb098d65ad4d840f60e5c92de7f58f1725bd70d0d132755ea453462fd50049") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libapreq2/package.py b/var/spack/repos/builtin/packages/libapreq2/package.py index 39bad41c7b1147..4eda5032cf3103 100644 --- a/var/spack/repos/builtin/packages/libapreq2/package.py +++ b/var/spack/repos/builtin/packages/libapreq2/package.py @@ -21,6 +21,8 @@ class Libapreq2(AutotoolsPackage): version("2.12", sha256="75cc1daa60e781270178c8f9fbe9c68231a7bc96bcc5c7a970cfce75d784b568") version("2.08", sha256="9f491588957415ebe0decdf6758fcb5c0d3eaf05a573bdd51de499ae111ffc53") + depends_on("c", type="build") # generated + depends_on("apr") depends_on("apr-util") depends_on("httpd") diff --git a/var/spack/repos/builtin/packages/libarchive/package.py b/var/spack/repos/builtin/packages/libarchive/package.py index 25354511097260..388d6a7973c321 100644 --- a/var/spack/repos/builtin/packages/libarchive/package.py +++ b/var/spack/repos/builtin/packages/libarchive/package.py @@ -4,7 +4,6 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack.package import * -from spack.util.environment import is_system_path class Libarchive(AutotoolsPackage): @@ -18,6 +17,9 @@ class Libarchive(AutotoolsPackage): license("BSD-2-Clause AND BSD-3-Clause AND Public-Domain") + version("3.7.4", sha256="7875d49596286055b52439ed42f044bd8ad426aa4cc5aabd96bfe7abb971d5e8") + version("3.7.3", sha256="f27a97bc22ceb996e72502df47dc19f99f9a0f09181ae909f09f3c9eb17b67e2") + version("3.7.2", sha256="df404eb7222cf30b4f8f93828677890a2986b66ff8bf39dac32a804e96ddf104") version("3.7.1", sha256="5d24e40819768f74daf846b99837fc53a3a9dcdf3ce1c2003fe0596db850f0f0") version("3.7.0", sha256="d937886a14b48c4287c4d343644feb294a14b31b7926ba9a4f1777123ce7c2cc") version("3.6.2", sha256="ba6d02f15ba04aba9c23fd5f236bb234eab9d5209e95d1c4df85c44d5f19b9b3") @@ -65,6 +67,9 @@ class Libarchive(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "libs", default="static,shared", @@ -132,10 +137,10 @@ def configure_args(self): args += self.enable_or_disable("programs") if "+iconv" in spec: - if spec["iconv"].name == "libc": + if spec["iconv"].name == "libiconv": + args.append(f"--with-libiconv-prefix={spec['iconv'].prefix}") + else: args.append("--without-libiconv-prefix") - elif not is_system_path(spec["iconv"].prefix): - args.append("--with-libiconv-prefix={p}".format(p=spec["iconv"].prefix)) else: args.append("--without-iconv") diff --git a/var/spack/repos/builtin/packages/libasr/package.py b/var/spack/repos/builtin/packages/libasr/package.py index f4bd5bde80deab..b01cd9c0536fd2 100644 --- a/var/spack/repos/builtin/packages/libasr/package.py +++ b/var/spack/repos/builtin/packages/libasr/package.py @@ -16,3 +16,5 @@ class Libasr(AutotoolsPackage): version("1.0.4", sha256="19fb6bed10d15c9775c8d008cd1130155917ae4e801c729fe85e6d88a545dab4") version("1.0.3", sha256="9cd88e0172e6d426438875e09229d1d473d56db546d02b630f9dd14db226d68d") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libassuan/package.py b/var/spack/repos/builtin/packages/libassuan/package.py index c58c6d9d19093a..ccd55d3e18b2bf 100644 --- a/var/spack/repos/builtin/packages/libassuan/package.py +++ b/var/spack/repos/builtin/packages/libassuan/package.py @@ -15,6 +15,8 @@ class Libassuan(AutotoolsPackage): license("LGPL-2.1-or-later") + version("3.0.1", sha256="c8f0f42e6103dea4b1a6a483cb556654e97302c7465308f58363778f95f194b1") + version("3.0.0", sha256="0b160cbb898b852c6c04314b9a63e90ca87501305ad72a58a010f808665bbaf6") version("2.5.7", sha256="0103081ffc27838a2e50479153ca105e873d3d65d8a9593282e9c94c7e6afb76") version("2.5.6", sha256="e9fd27218d5394904e4e39788f9b1742711c3e6b41689a31aa3380bd5aa4f426") version("2.5.5", sha256="8e8c2fcc982f9ca67dcbb1d95e2dc746b1739a4668bc20b3a3c5be632edb34e4") @@ -23,8 +25,12 @@ class Libassuan(AutotoolsPackage): version("2.4.5", sha256="fbfea5d1dbcdee34f2597b0afb3d8bb4eda96c924a1e01b01c2acde68b81625f") version("2.4.3", sha256="22843a3bdb256f59be49842abf24da76700354293a066d82ade8134bb5aa2b71") + depends_on("c", type="build") # generated + depends_on("libgpg-error@1.17:") + conflicts("platform=darwin", when="@3") + def configure_args(self): return [ "--enable-static", diff --git a/var/spack/repos/builtin/packages/libatasmart/package.py b/var/spack/repos/builtin/packages/libatasmart/package.py index ee2dd4dfeaa94a..966cabfea87cd7 100644 --- a/var/spack/repos/builtin/packages/libatasmart/package.py +++ b/var/spack/repos/builtin/packages/libatasmart/package.py @@ -19,6 +19,8 @@ class Libatasmart(AutotoolsPackage): version("0.18", sha256="4a6e93fbaec2d4caffb06ddd47c2c35ea4ad2d3d22e805bf284adba949f64ddf") version("0.17", sha256="353b2ec097814254989a809fd495f95a315e608fdf320c2b96dc52d70392e955") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libatomic-ops/package.py b/var/spack/repos/builtin/packages/libatomic-ops/package.py index f03e9588627aca..da7561ebe2c30a 100644 --- a/var/spack/repos/builtin/packages/libatomic-ops/package.py +++ b/var/spack/repos/builtin/packages/libatomic-ops/package.py @@ -15,11 +15,14 @@ class LibatomicOps(AutotoolsPackage): license("GPL-2.0-only") + version("7.8.2", sha256="d305207fe207f2b3fb5cb4c019da12b44ce3fcbc593dfd5080d867b1a2419b51") version("7.8.0", sha256="15676e7674e11bda5a7e50a73f4d9e7d60452271b8acf6fd39a71fefdf89fa31") version("7.6.14", sha256="390f244d424714735b7050d056567615b3b8f29008a663c262fb548f1802d292") version("7.6.12", sha256="f0ab566e25fce08b560e1feab6a3db01db4a38e5bc687804334ef3920c549f3e") version("7.6.6", sha256="99feabc5f54877f314db4fadeb109f0b3e1d1a54afb6b4b3dfba1e707e38e074") version("7.4.4", sha256="bf210a600dd1becbf7936dd2914cf5f5d3356046904848dcfd27d0c8b12b6f8f") + depends_on("c", type="build") # generated + def configure_args(self): return ["--enable-shared"] diff --git a/var/spack/repos/builtin/packages/libbacktrace/package.py b/var/spack/repos/builtin/packages/libbacktrace/package.py index 7c258776272afd..a2379f591dded2 100644 --- a/var/spack/repos/builtin/packages/libbacktrace/package.py +++ b/var/spack/repos/builtin/packages/libbacktrace/package.py @@ -17,6 +17,8 @@ class Libbacktrace(AutotoolsPackage): version("master", branch="master") version("2020-02-19", commit="ca0de0517f3be44fedf5a2c01cfaf6437d4cae68") + depends_on("c", type="build") # generated + variant("shared", default=False, description="Additionally build shared library") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/libbeagle/package.py b/var/spack/repos/builtin/packages/libbeagle/package.py index 4fff19fe9c09dc..530815089c5f4e 100644 --- a/var/spack/repos/builtin/packages/libbeagle/package.py +++ b/var/spack/repos/builtin/packages/libbeagle/package.py @@ -22,6 +22,9 @@ class Libbeagle(AutotoolsPackage, CudaPackage): url="https://github.com/beagle-dev/beagle-lib/archive/beagle_release_2_1_2.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libbeato/package.py b/var/spack/repos/builtin/packages/libbeato/package.py index 2179a6de315987..5ff0acb1a19fa6 100644 --- a/var/spack/repos/builtin/packages/libbeato/package.py +++ b/var/spack/repos/builtin/packages/libbeato/package.py @@ -17,3 +17,5 @@ class Libbeato(AutotoolsPackage): license("GPL-3.0-or-later") version("master", branch="master") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libbigwig/package.py b/var/spack/repos/builtin/packages/libbigwig/package.py index 430c6d5593c899..8a6cde1b8ddef7 100644 --- a/var/spack/repos/builtin/packages/libbigwig/package.py +++ b/var/spack/repos/builtin/packages/libbigwig/package.py @@ -17,6 +17,8 @@ class Libbigwig(CMakePackage): version("0.4.7", sha256="8e057797011d93fa00e756600898af4fe6ca2d48959236efc9f296abe94916d9") + depends_on("c", type="build") # generated + variant("curl", default=True, description="Build with curl support") depends_on("curl", when="+curl") diff --git a/var/spack/repos/builtin/packages/libbinio/package.py b/var/spack/repos/builtin/packages/libbinio/package.py index 3d086a555020d5..0206ca9b15fce1 100644 --- a/var/spack/repos/builtin/packages/libbinio/package.py +++ b/var/spack/repos/builtin/packages/libbinio/package.py @@ -16,3 +16,5 @@ class Libbinio(AutotoolsPackage): version("1.5", sha256="398b2468e7838d2274d1f62dbc112e7e043433812f7ae63ef29f5cb31dc6defd") version("1.4", sha256="4a32d3154517510a3fe4f2dc95e378dcc818a4a921fc0cb992bdc0d416a77e75") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libblastrampoline/package.py b/var/spack/repos/builtin/packages/libblastrampoline/package.py index c7c498e97d70c0..fe8bb8d28cd848 100644 --- a/var/spack/repos/builtin/packages/libblastrampoline/package.py +++ b/var/spack/repos/builtin/packages/libblastrampoline/package.py @@ -41,6 +41,8 @@ class Libblastrampoline(MakefilePackage): version("3.0.0", sha256="4d0856d30e7ba0cb0de08b08b60fd34879ce98714341124acf87e587d1bbbcde") version("2.2.0", sha256="1fb8752891578b45e187019c67fccbaafb108756aadc69bdd876033846ad30d3") + depends_on("c", type="build") # generated + build_directory = "src" def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/libbsd/package.py b/var/spack/repos/builtin/packages/libbsd/package.py index 5d7ad3ab715902..a3718c82172566 100644 --- a/var/spack/repos/builtin/packages/libbsd/package.py +++ b/var/spack/repos/builtin/packages/libbsd/package.py @@ -21,6 +21,7 @@ class Libbsd(AutotoolsPackage): license("BSD-3-Clause") + version("0.12.2", sha256="b88cc9163d0c652aaf39a99991d974ddba1c3a9711db8f1b5838af2a14731014") version("0.12.1", sha256="d7747f8ec1baa6ff5c096a9dd587c061233dec90da0f1aedd66d830f6db6996a") version("0.11.7", sha256="9baa186059ebbf25c06308e9f991fda31f7183c0f24931826d83aa6abd8a0261") version("0.11.6", sha256="19b38f3172eaf693e6e1c68714636190c7e48851e45224d720b3b5bc0499b5df") @@ -35,6 +36,8 @@ class Libbsd(AutotoolsPackage): version("0.8.7", sha256="f548f10e5af5a08b1e22889ce84315b1ebe41505b015c9596bad03fd13a12b31") version("0.8.6", sha256="467fbf9df1f49af11f7f686691057c8c0a7613ae5a870577bef9155de39f9687") + depends_on("c", type="build") # generated + patch("cdefs.h.patch", when="@0.8.6 %gcc@:4") patch("local-elf.h.patch", when="@:0.10 %intel") diff --git a/var/spack/repos/builtin/packages/libbson/package.py b/var/spack/repos/builtin/packages/libbson/package.py index f394f6684110b8..1584f5bd29eb86 100644 --- a/var/spack/repos/builtin/packages/libbson/package.py +++ b/var/spack/repos/builtin/packages/libbson/package.py @@ -3,18 +3,20 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.build_systems import cmake from spack.package import * -class Libbson(Package): +class Libbson(AutotoolsPackage, CMakePackage): """libbson is a library providing useful routines related to building, parsing, and iterating BSON documents.""" homepage = "https://github.com/mongodb/mongo-c-driver" - url = "https://github.com/mongodb/mongo-c-driver/releases/download/1.16.2/mongo-c-driver-1.16.2.tar.gz" + url = "https://github.com/mongodb/mongo-c-driver/archive/refs/tags/1.25.0.tar.gz" maintainers("michaelkuhn") + version("1.27.2", sha256="a53010803e2df097a2ea756be6ece34c8f52cda2c18e6ea21115097b75f5d4bf") version("1.24.4", sha256="2f4a3e8943bfe3b8672c2053f88cf74acc8494dc98a45445f727901eee141544") version("1.23.4", sha256="209406c91fcf7c63aa633179a0a6b1b36ba237fb77e0470fd81f7299a408e334") version("1.23.3", sha256="c8f951d4f965d455f37ae2e10b72914736fc0f25c4ffc14afc3cbadd1a574ef6") @@ -33,52 +35,48 @@ class Libbson(Package): version("1.7.0", sha256="442d89e89dfb43bba1f65080dc61fdcba01dcb23468b2842c1dbdd4acd6049d3") version("1.6.3", sha256="e9e4012a9080bdc927b5060b126a2c82ca11e71ebe7f2152d079fa2ce461a7fb") version("1.6.2", sha256="aad410123e4bd8a9804c3c3d79e03344e2df104872594dc2cf19605d492944ba") - version("1.6.1", sha256="5f160d44ea42ce9352a7a3607bc10d3b4b22d3271763aa3b3a12665e73e3a02d") + version( + "1.6.1", + sha256="5f160d44ea42ce9352a7a3607bc10d3b4b22d3271763aa3b3a12665e73e3a02d", + deprecated=True, + ) - depends_on("cmake@3.1:", type="build", when="@1.10.0:") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated - depends_on("autoconf", type="build", when="@1.6.1") - depends_on("automake", type="build", when="@1.6.1") - depends_on("libtool", type="build", when="@1.6.1") - depends_on("m4", type="build", when="@1.6.1") + with when("build_system=cmake"): + depends_on("cmake@3.1:", type="build") + + with when("build_system=autotools"): + depends_on("autoconf", type="build", when="@1.6.1") + depends_on("automake", type="build", when="@1.6.1") + depends_on("libtool", type="build", when="@1.6.1") + + build_system( + conditional("cmake", when="@1.10:"), + conditional("autotools", when="@:1.9"), + default="cmake", + ) def url_for_version(self, version): + if version >= Version("1.25.0"): + return f"https://github.com/mongodb/mongo-c-driver/archive/refs/tags/{version}.tar.gz" if version >= Version("1.10.0"): - url = "https://github.com/mongodb/mongo-c-driver/releases/download/{0}/mongo-c-driver-{0}.tar.gz" + return f"https://github.com/mongodb/mongo-c-driver/releases/download/{version}/mongo-c-driver-{version}.tar.gz" else: - url = "https://github.com/mongodb/libbson/releases/download/{0}/libbson-{0}.tar.gz" - - return url.format(version) - - def cmake_args(self): - args = ["-DENABLE_AUTOMATIC_INIT_AND_CLEANUP=OFF", "-DENABLE_MONGOC=OFF"] - - return args - - def install(self, spec, prefix): - with working_dir("spack-build", create=True): - # We cannot simply do - # cmake('..', *std_cmake_args, *self.cmake_args()) - # because that is not Python 2 compatible. Instead, collect - # arguments into a temporary buffer first. - args = [] - args.extend(std_cmake_args) - args.extend(self.cmake_args()) - cmake("..", *args) - make() - make("install") + return f"https://github.com/mongodb/libbson/releases/download/{version}/libbson-{version}.tar.gz" @property def force_autoreconf(self): # 1.6.1 tarball is broken return self.spec.satisfies("@1.6.1") - @when("@:1.9") - def install(self, spec, prefix): - configure("--prefix={0}".format(prefix)) - make() - if self.run_tests: - make("check") - make("install") - if self.run_tests: - make("installcheck") + +class CMakeBuilder(cmake.CMakeBuilder): + def cmake_args(self): + return [ + self.define("ENABLE_AUTOMATIC_INIT_AND_CLEANUP", False), + self.define("ENABLE_MONGOC", False), + self.define("MONGO_USE_CCACHE", False), + self.define("MONGO_USE_LLD", False), + ] diff --git a/var/spack/repos/builtin/packages/libbytesize/package.py b/var/spack/repos/builtin/packages/libbytesize/package.py index 9c36c2d8aa9b04..7a0102b8f9e5b5 100644 --- a/var/spack/repos/builtin/packages/libbytesize/package.py +++ b/var/spack/repos/builtin/packages/libbytesize/package.py @@ -19,6 +19,8 @@ class Libbytesize(AutotoolsPackage): version("2.3", sha256="3c74113fc8cd1a2fbd8870fa0ed7cef2ef24d60ef91e7145fbc041f9aa144479") version("2.2", sha256="b93c54b502880c095c9f5767a42464853e2687db2e5e3084908a615bafe73baa") + depends_on("c", type="build") # generated + extends("python") depends_on("pcre2") depends_on("gmp") diff --git a/var/spack/repos/builtin/packages/libc/package.py b/var/spack/repos/builtin/packages/libc/package.py deleted file mode 100644 index 2a1f13739b1606..00000000000000 --- a/var/spack/repos/builtin/packages/libc/package.py +++ /dev/null @@ -1,24 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -from spack.package import * - - -class Libc(BundlePackage): - """Dummy package to provide interfaces available in libc.""" - - homepage = "https://en.wikipedia.org/wiki/C_standard_library" - - version("1.0") # Dummy - - variant("iconv", default=False, description="Provides interfaces for Localization Functions") - variant("rpc", default=False, description="Provides interfaces for RPC") - - provides("iconv", when="+iconv") - provides("rpc", when="+rpc") - - @property - def libs(self): - return LibraryList([]) diff --git a/var/spack/repos/builtin/packages/libcanberra/package.py b/var/spack/repos/builtin/packages/libcanberra/package.py index ba94f92309136b..19807aa5fae72a 100644 --- a/var/spack/repos/builtin/packages/libcanberra/package.py +++ b/var/spack/repos/builtin/packages/libcanberra/package.py @@ -18,6 +18,8 @@ class Libcanberra(AutotoolsPackage): version("0.30", sha256="c2b671e67e0c288a69fc33dc1b6f1b534d07882c2aceed37004bf48c601afa72") + depends_on("c", type="build") # generated + # TODO: Add variants and dependencies for the following audio support: # ALSA, OSS, PulseAudio, udev, GStreamer, null, GTK3+ , tdb diff --git a/var/spack/repos/builtin/packages/libcap-ng/package.py b/var/spack/repos/builtin/packages/libcap-ng/package.py index 373cf7c3999eed..064fd9b5d0f57b 100644 --- a/var/spack/repos/builtin/packages/libcap-ng/package.py +++ b/var/spack/repos/builtin/packages/libcap-ng/package.py @@ -19,6 +19,8 @@ class LibcapNg(AutotoolsPackage): version("0.7.11", sha256="78f32ff282b49b7b91c56d317fb6669df26da332c6fc9462870cec2573352222") version("0.7.10", sha256="c3c156a215e5be5430b2f3b8717bbd1afdabe458b6068a8d163e71cefe98fc32") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") @@ -33,7 +35,7 @@ class LibcapNg(AutotoolsPackage): def setup_build_environment(self, env): if self.spec.satisfies("+python"): - env.set("PYTHON", self.spec["python"].command.path) + env.set("PYTHON", python.path) def configure_args(self): args = [] diff --git a/var/spack/repos/builtin/packages/libcap/package.py b/var/spack/repos/builtin/packages/libcap/package.py index 6dedb75748f140..8793f4bd6d63e0 100644 --- a/var/spack/repos/builtin/packages/libcap/package.py +++ b/var/spack/repos/builtin/packages/libcap/package.py @@ -17,6 +17,7 @@ class Libcap(MakefilePackage): license("BSD-3-Clause OR GPL-2.0-only") + version("2.69", sha256="3a99ec26452e328e0ea408efd67096ef914f4ee4788fa8e8e21f214e2bd670b9") version("2.68", sha256="046e55716e0643b565efcd1dab1d26c5625709fcd0b5c271290c7ea1524cf906") version("2.67", sha256="2d0b679a431c06afd8651a8ada906303eda8b3ac67c308e5fe1937eea5c018aa") version("2.66", sha256="5f65dc5b2e9f63a0748ea1b05be7965a38548db1cbfd53b30271ff02186b3a4a") @@ -24,6 +25,8 @@ class Libcap(MakefilePackage): version("2.64", sha256="e9ec608ae5720989d7274531f9898d64b6bca2491a231b8091229e49891933dd") version("2.25", sha256="4ca80dc6f9f23d14747e4b619fd9784434c570e24a7346f326c692784ed83a86") + depends_on("c", type="build") # generated + patch("libcap-fix-the-libcap-native-building-failure-on-CentOS-6.7.patch", when="@2.25") def makeflags(self, prefix): @@ -33,7 +36,7 @@ def makeflags(self, prefix): "USE_GPERF=no", "SHARED=yes", "lib=lib", - "prefix={}".format(prefix), + f"prefix={prefix}", ] def build(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/libcatalyst/package.py b/var/spack/repos/builtin/packages/libcatalyst/package.py index c8539816bb0890..6bfc26cf93d33f 100644 --- a/var/spack/repos/builtin/packages/libcatalyst/package.py +++ b/var/spack/repos/builtin/packages/libcatalyst/package.py @@ -16,13 +16,17 @@ class Libcatalyst(CMakePackage): homepage = "https://gitlab.kitware.com/paraview/catalyst" git = "https://gitlab.kitware.com/paraview/catalyst.git" - url = "https://gitlab.kitware.com/api/v4/projects/paraview%2Fcatalyst/packages/generic/catalyst/v2.0.0/catalyst-v2.0.0.tar.gz" + url = "https://gitlab.kitware.com/api/v4/projects/5912/packages/generic/catalyst/v2.0.0/catalyst-v2.0.0.tar.gz" license("BSD-3-Clause") maintainers("mathstuf", "ayenpure") version("master", branch="master") - version("2.0.0-rc4", sha256="cb491e4ccd344156cc2494f65b9f38885598c16d12e1016c36e2ee0bc3640863") + version("2.0.0", sha256="5842b690bd8afa635414da9b9c5e5d79fa37879b0d382428d0d8e26ba5374828") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant("mpi", default=False, description="Enable MPI support") variant("conduit", default=False, description="Use external Conduit for Catalyst") @@ -32,6 +36,8 @@ class Libcatalyst(CMakePackage): depends_on("mpi", when="+mpi") depends_on("conduit", when="+conduit") depends_on("cmake@3.26:", type="build") + depends_on("python@3:", when="+python") + depends_on("py-numpy", when="+python", type=("build", "link", "run")) def cmake_args(self): """Populate cmake arguments for libcatalyst.""" diff --git a/var/spack/repos/builtin/packages/libceed/package.py b/var/spack/repos/builtin/packages/libceed/package.py index 5ca941bd0613eb..04f438ab30418a 100644 --- a/var/spack/repos/builtin/packages/libceed/package.py +++ b/var/spack/repos/builtin/packages/libceed/package.py @@ -31,6 +31,10 @@ class Libceed(MakefilePackage, CudaPackage, ROCmPackage): version("0.2", tag="v0.2", commit="113004cb41757b819325a4b3a8a7dfcea5156531") version("0.1", tag="v0.1", commit="74e0540e2478136394f75869675056eb6aba67cc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("occa", default=False, description="Enable OCCA backends") variant("debug", default=False, description="Enable debug build") variant("libxsmm", default=False, description="Enable LIBXSMM backend", when="@0.3:") diff --git a/var/spack/repos/builtin/packages/libcerf/package.py b/var/spack/repos/builtin/packages/libcerf/package.py index fb84326608de62..f4bac7710014b7 100644 --- a/var/spack/repos/builtin/packages/libcerf/package.py +++ b/var/spack/repos/builtin/packages/libcerf/package.py @@ -19,6 +19,9 @@ class Libcerf(AutotoolsPackage, SourceforgePackage): version("1.3", sha256="d7059e923d3f370c89fb4d19ed4f827d381bc3f0e36da5595a04aeaaf3e6a859") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + def configure_args(self): spec = self.spec options = [] diff --git a/var/spack/repos/builtin/packages/libcgroup/package.py b/var/spack/repos/builtin/packages/libcgroup/package.py index 8c564733515b56..98779767171266 100644 --- a/var/spack/repos/builtin/packages/libcgroup/package.py +++ b/var/spack/repos/builtin/packages/libcgroup/package.py @@ -18,6 +18,9 @@ class Libcgroup(AutotoolsPackage): version("0.37", sha256="15c8f3febb546530d3495af4e4904b3189c273277ca2d8553dec882cde1cd0f6") version("0.36", sha256="8dcd2ae220435b3de736d3efb0023fdf1192d7a7f4032b439f3cf5342cff7b4c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/libcint/package.py b/var/spack/repos/builtin/packages/libcint/package.py index 8273d63b3804c0..98fef4336768e6 100644 --- a/var/spack/repos/builtin/packages/libcint/package.py +++ b/var/spack/repos/builtin/packages/libcint/package.py @@ -11,13 +11,15 @@ class Libcint(CMakePackage): homepage = "https://github.com/sunqm/libcint" url = "https://github.com/sunqm/libcint/archive/v3.0.4.tar.gz" - maintainers("mfherbst") + maintainers("mfherbst", "bruneval") license("BSD-2-Clause") # # Versions # + version("6.1.2", sha256="8287e1eaf2b8c8e19eb7a8ea92fd73898f0884023c503b84624610400adb25c4") + version("5.5.0", sha256="c822a9a454587d935287de0f64a2c2cf5338323a554a3f34bcfb4a2892daf477") version("5.3.0", sha256="9d4fae074b53a8ce0335e2672d423deca2bda6df8020352e59d23c17a0c1239d") version("5.2.0", sha256="f9dba1040c445ee81ae5a2a59d9f1291fc0406edad0fb5ea37fceb66c2ef7799") version("5.1.3", sha256="a239275a0464360c904fd06e67d2e76ef1147e04bc634befb40c67d3e79b3638") @@ -31,6 +33,9 @@ class Libcint(CMakePackage): version("3.0.5", sha256="7bde241ce83c00b89c80459e3af5734d40925d8fd9fcaaa7245f61b08192c722") version("3.0.4", sha256="0f25ef7ad282dd7a20e4decf283558e4f949243a5423ff4c0cd875276c310c47") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # # Variants # diff --git a/var/spack/repos/builtin/packages/libcircle/package.py b/var/spack/repos/builtin/packages/libcircle/package.py index 115164fd99ad0f..a07cf2bb347e38 100644 --- a/var/spack/repos/builtin/packages/libcircle/package.py +++ b/var/spack/repos/builtin/packages/libcircle/package.py @@ -26,6 +26,8 @@ class Libcircle(AutotoolsPackage): "0.2.1-rc.1", sha256="5747f91cf4417023304dcc92fd07e3617ac712ca1eeb698880979bbca3f54865" ) + depends_on("c", type="build") # generated + depends_on("mpi") depends_on("pkgconfig", type="build") depends_on("libpciaccess", type="link") diff --git a/var/spack/repos/builtin/packages/libconfig/package.py b/var/spack/repos/builtin/packages/libconfig/package.py index a798afa49ceaed..2b2430577824ac 100644 --- a/var/spack/repos/builtin/packages/libconfig/package.py +++ b/var/spack/repos/builtin/packages/libconfig/package.py @@ -21,6 +21,9 @@ class Libconfig(AutotoolsPackage): version("1.7.1", sha256="d288e6ae817f4ef78df43cdb2647f768dc97899ee82fcc41f857e8eb9fd7fbdb") version("1.5", sha256="cae5c02361d8a9b2bb26946c64f089d2e5e599972f386203fbc48975c0d885c8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("m4", type=("build")) depends_on("autoconf", type=("build")) depends_on("automake", type=("build")) diff --git a/var/spack/repos/builtin/packages/libconfuse/package.py b/var/spack/repos/builtin/packages/libconfuse/package.py index e04391ba89c842..cdb5cc66dbdabf 100644 --- a/var/spack/repos/builtin/packages/libconfuse/package.py +++ b/var/spack/repos/builtin/packages/libconfuse/package.py @@ -18,6 +18,8 @@ class Libconfuse(AutotoolsPackage): version("3.2.2", sha256="2cf7e032980aff8f488efba61510dc3fb95e9a4b9183f985dea457a5651b0e2c") version("3.2.1", sha256="2eff8e3c300c4ed1d67fdb13f9d31a72a68e31874b4640db15334305bc40cebd") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/libcroco/package.py b/var/spack/repos/builtin/packages/libcroco/package.py index 851b364f8de8cc..45a6c6ef696c92 100644 --- a/var/spack/repos/builtin/packages/libcroco/package.py +++ b/var/spack/repos/builtin/packages/libcroco/package.py @@ -18,6 +18,8 @@ class Libcroco(AutotoolsPackage): version("0.6.13", sha256="767ec234ae7aa684695b3a735548224888132e063f92db585759b422570621d4") version("0.6.12", sha256="ddc4b5546c9fb4280a5017e2707fbd4839034ed1aba5b7d4372212f34f84f860") + depends_on("c", type="build") # generated + variant("doc", default=False, description="Build documentation with gtk-doc") depends_on("glib") diff --git a/var/spack/repos/builtin/packages/libctl/package.py b/var/spack/repos/builtin/packages/libctl/package.py index d1ac1b924429bc..86332a99e96938 100644 --- a/var/spack/repos/builtin/packages/libctl/package.py +++ b/var/spack/repos/builtin/packages/libctl/package.py @@ -25,6 +25,8 @@ class Libctl(AutotoolsPackage): url="http://ab-initio.mit.edu/libctl/libctl-3.2.2.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("guile") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/libcudf/package.py b/var/spack/repos/builtin/packages/libcudf/package.py index f3b56e93b470d5..b3fc85919d354f 100644 --- a/var/spack/repos/builtin/packages/libcudf/package.py +++ b/var/spack/repos/builtin/packages/libcudf/package.py @@ -19,6 +19,8 @@ class Libcudf(CMakePackage): version("0.15.0", sha256="2570636b72cce4c52f71e36307f51f630e2f9ea94a1abc018d40ce919ba990e4") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.14:", type="build") depends_on("cuda@10.0:") diff --git a/var/spack/repos/builtin/packages/libcuml/package.py b/var/spack/repos/builtin/packages/libcuml/package.py index 7d2b27346c311d..5173eb1b590dd5 100644 --- a/var/spack/repos/builtin/packages/libcuml/package.py +++ b/var/spack/repos/builtin/packages/libcuml/package.py @@ -16,6 +16,8 @@ class Libcuml(CMakePackage): version("0.15.0", sha256="5c9c656ae4eaa94a426e07d7385fd5ea0e5dc7abff806af2941aee10d4ca99c7") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.14:", type="build") depends_on("zlib-api") depends_on("libcudf@0.8:") diff --git a/var/spack/repos/builtin/packages/libcumlprims/package.py b/var/spack/repos/builtin/packages/libcumlprims/package.py index eaf7fab4559460..a7ae12acb2e3ba 100644 --- a/var/spack/repos/builtin/packages/libcumlprims/package.py +++ b/var/spack/repos/builtin/packages/libcumlprims/package.py @@ -25,6 +25,8 @@ class Libcumlprims(Package): sha256="f055f904b5ef67995869b0bc648d9fe30839b08e77cb335573bf9f1c816d4d9b", ) + depends_on("cxx", type="build") # generated + depends_on("cuda@11.0.0:11.0", when="@0.15.0-cuda11.0_gdbd0d39_0") depends_on("cuda@10.2.0:10.2", when="@0.15.0-cuda10.2_gdbd0d39_0") depends_on("cuda@10.1.0:10.1", when="@0.15.0-cuda10.1_gdbd0d39_0") diff --git a/var/spack/repos/builtin/packages/libcxxwrap-julia/package.py b/var/spack/repos/builtin/packages/libcxxwrap-julia/package.py index 9cdcfea1f8ed6d..e5ecdfe8fa53bd 100644 --- a/var/spack/repos/builtin/packages/libcxxwrap-julia/package.py +++ b/var/spack/repos/builtin/packages/libcxxwrap-julia/package.py @@ -21,8 +21,12 @@ class LibcxxwrapJulia(CMakePackage): # note: use the @main branch version if you're building for julia 1.7 version("main", branch="main") + version("0.12.5", sha256="7970ab5e2a22a7be5185d40f184fa0b3949a3e83ffdf4f1512feb4f261957312") + version("0.12.4", sha256="c1eafbbefd01074b4e303603e7c012518fc9ce86e055f08c0f0446bc46d50327") version("0.9.1", sha256="d7938d88ae2dbcc6abf505df3ac280dcd7c85fca0954af56911cf510d6161e05") version("0.8.3", sha256="b0421d11bdee5ce8af4922de6dfe3b0e5d69b07bb52894e3a22a477bbd27ee9e") version("0.8.2", sha256="f8b171def3d61904ba8f9a9052a405c25afbfb9a3c5af3dd30bc36a0184ed539") + depends_on("cxx", type="build") # generated + depends_on("julia") diff --git a/var/spack/repos/builtin/packages/libcyaml/package.py b/var/spack/repos/builtin/packages/libcyaml/package.py index c1d79006978bc2..098ea2af6e554c 100644 --- a/var/spack/repos/builtin/packages/libcyaml/package.py +++ b/var/spack/repos/builtin/packages/libcyaml/package.py @@ -15,13 +15,16 @@ class Libcyaml(MakefilePackage): license("ISC") + version("1.4.1", sha256="8dbd216e1fce90f9f7cca341e5178710adc76ee360a7793ef867edb28f3e4130") version("1.4.0", sha256="e803fef0e254aa1f302c622c2d25cff989e04e9b2bebb7d22abd91386373122f") version("1.1.0", sha256="37a00ed8ec206b60a712acfd44196bef063b8f02e376d8e86f61a7007a81daea") + depends_on("c", type="build") # generated + depends_on("libyaml") def build(self, spec, prefix): make("VARIANT=release") def install(self, spec, prefix): - make("install", "VARIANT=release", "PREFIX={0}".format(prefix)) + make("install", "VARIANT=release", f"PREFIX={prefix}") diff --git a/var/spack/repos/builtin/packages/libdaemon/package.py b/var/spack/repos/builtin/packages/libdaemon/package.py index a73e9947c0a7c0..92c127ee5447df 100644 --- a/var/spack/repos/builtin/packages/libdaemon/package.py +++ b/var/spack/repos/builtin/packages/libdaemon/package.py @@ -18,3 +18,5 @@ class Libdaemon(AutotoolsPackage): version("0.14", sha256="fd23eb5f6f986dcc7e708307355ba3289abe03cc381fc47a80bca4a50aa6b834") version("0.13", sha256="bd949d459d2da54f1cdfbd1f4592e32541e8a195aca56fa7a8329ed79836d709") version("0.12", sha256="39e7c9f8644d1af310d076c1a5cc648040033e4724e7edfd85eb983ad88336d0") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libdap4/package.py b/var/spack/repos/builtin/packages/libdap4/package.py index b8ad2a2e7fb58c..6744921e27ecbc 100644 --- a/var/spack/repos/builtin/packages/libdap4/package.py +++ b/var/spack/repos/builtin/packages/libdap4/package.py @@ -24,6 +24,10 @@ class Libdap4(AutotoolsPackage): version("3.20.6", sha256="e44e83043c158d8c9d0a37a1821626ab0db4a1a6578b02182440170c0b060e6d") version("3.20.4", sha256="c39fa310985cc8963029ad0d0aba784e7dbf1f70c566bd7ae58242f1bb06d24a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libdatrie/package.py b/var/spack/repos/builtin/packages/libdatrie/package.py index f2534674bd3174..0437fe86218ead 100644 --- a/var/spack/repos/builtin/packages/libdatrie/package.py +++ b/var/spack/repos/builtin/packages/libdatrie/package.py @@ -18,4 +18,6 @@ class Libdatrie(AutotoolsPackage): version("0.2.12", sha256="452dcc4d3a96c01f80f7c291b42be11863cd1554ff78b93e110becce6e00b149") version("0.2.11", sha256="547c7bd2ab9e10ad65f3270cae8ca7027f52db9c30f7327d24354ad41a98e94b") + depends_on("c", type="build") # generated + depends_on("doxygen@1.8.8:", type="build") diff --git a/var/spack/repos/builtin/packages/libdc1394/package.py b/var/spack/repos/builtin/packages/libdc1394/package.py index b8151a70d9df88..f84ff749d2fd8e 100644 --- a/var/spack/repos/builtin/packages/libdc1394/package.py +++ b/var/spack/repos/builtin/packages/libdc1394/package.py @@ -18,6 +18,8 @@ class Libdc1394(AutotoolsPackage): version("2.2.6", sha256="2b905fc9aa4eec6bdcf6a2ae5f5ba021232739f5be047dec8fe8dd6049c10fed") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("libusb") depends_on("libraw1394") diff --git a/var/spack/repos/builtin/packages/libde265/package.py b/var/spack/repos/builtin/packages/libde265/package.py index 7e6db94a658944..340f8061fd0824 100644 --- a/var/spack/repos/builtin/packages/libde265/package.py +++ b/var/spack/repos/builtin/packages/libde265/package.py @@ -21,4 +21,7 @@ class Libde265(CMakePackage): version("1.0.9", sha256="153554f407718a75f1e0ae197d35b43147ce282118a54f894554dbe27c32163d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.13:", type="build") diff --git a/var/spack/repos/builtin/packages/libdeflate/package.py b/var/spack/repos/builtin/packages/libdeflate/package.py index f140cb57a3f487..a79d5c8beaf70d 100644 --- a/var/spack/repos/builtin/packages/libdeflate/package.py +++ b/var/spack/repos/builtin/packages/libdeflate/package.py @@ -22,6 +22,8 @@ class Libdeflate(MakefilePackage, CMakePackage): version("1.10", sha256="5c1f75c285cd87202226f4de49985dcb75732f527eefba2b3ddd70a8865f2533") version("1.7", sha256="a5e6a0a9ab69f40f0f59332106532ca76918977a974e7004977a9498e3f11350") + depends_on("c", type="build") # generated + build_system( conditional("makefile", when="@:1.14"), conditional("cmake", when="@1.15:"), diff --git a/var/spack/repos/builtin/packages/libdicom/package.py b/var/spack/repos/builtin/packages/libdicom/package.py index 4ee90bfebf974b..ab55e4c220e93f 100644 --- a/var/spack/repos/builtin/packages/libdicom/package.py +++ b/var/spack/repos/builtin/packages/libdicom/package.py @@ -14,8 +14,11 @@ class Libdicom(MesonPackage): license("MIT") + version("1.1.0", sha256="a0ab640e050f373bc5a3e1ec99bee7d5b488652340855223a73002181b094ae8") version("1.0.5", sha256="ebf5f7c0d1a0f802c1801f2f762537f014f2a431be3e063142f6ed3c96878abb") + depends_on("c", type="build") # generated + depends_on("meson@0.50:", type="build") depends_on("ninja", type="build") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/libdistributed/package.py b/var/spack/repos/builtin/packages/libdistributed/package.py index 83d5aab986237a..42566c109ce593 100644 --- a/var/spack/repos/builtin/packages/libdistributed/package.py +++ b/var/spack/repos/builtin/packages/libdistributed/package.py @@ -17,6 +17,7 @@ class Libdistributed(CMakePackage): maintainers("robertu94") version("master", branch="master") + version("0.4.3", sha256="fbfb473ab6da18880d64a36cf2134c18938a57fe958b822606927b2132783c0d") version("0.4.2", sha256="ffb5e0aea2cd5ccbd7af2471059d6e70fa5ac2d6ce64fb71c6d434544c01be95") version("0.4.1", sha256="62bbd4cbaf396cea7f33d62d5e79086a56ee1396d070ad3c4fd9720c50d242c0") version("0.4.0", sha256="7895d268c4f9b5444e4378f60b5a28198720bc48633d0e5d072c39e3366b096c") @@ -35,6 +36,8 @@ class Libdistributed(CMakePackage): version("0.0.2", sha256="c25309108fe17021fd5f06ba98386210708158c439e98326e68f66c42875e58a") version("0.0.1", sha256="4c23ce0fd70a12ee5f8760ea00377ab6370d86b30ab42476e07453b19ea4ac44") + depends_on("cxx", type="build") # generated + depends_on("mpi@2:") depends_on("libstdcompat@0.0.2:", when="@0.1.0:") @@ -48,5 +51,5 @@ def cmake_args(self): @run_after("build") @on_package_attributes(run_tests=True) - def test(self): + def check_test(self): make("test") diff --git a/var/spack/repos/builtin/packages/libdivsufsort/package.py b/var/spack/repos/builtin/packages/libdivsufsort/package.py index bebbc0c57b19c2..4b6a56e19f39c2 100644 --- a/var/spack/repos/builtin/packages/libdivsufsort/package.py +++ b/var/spack/repos/builtin/packages/libdivsufsort/package.py @@ -17,6 +17,8 @@ class Libdivsufsort(CMakePackage): version("2.0.1", sha256="9164cb6044dcb6e430555721e3318d5a8f38871c2da9fd9256665746a69351e0") + depends_on("c", type="build") # generated + def cmake_args(self): args = ["-DBUILD_DIVSUFSORT64=ON"] return args diff --git a/var/spack/repos/builtin/packages/libdmx/package.py b/var/spack/repos/builtin/packages/libdmx/package.py index 80122777e866d9..0a864812544f9c 100644 --- a/var/spack/repos/builtin/packages/libdmx/package.py +++ b/var/spack/repos/builtin/packages/libdmx/package.py @@ -13,9 +13,12 @@ class Libdmx(AutotoolsPackage, XorgPackage): homepage = "https://cgit.freedesktop.org/xorg/lib/libdmx" xorg_mirror_path = "lib/libdmx-1.1.3.tar.gz" + version("1.1.5", sha256="070e82cc1daa1b21ee1339aef56a909eab04cbe7d430fabfbb01ecd21b2dd9f3") version("1.1.4", sha256="4d05bd5b248c1f46729fa1536b7a5e4d692567327ad41564c36742fb327af925") version("1.1.3", sha256="c4b24d7e13e5a67ead7a18f0b4cc9b7b5363c9d04cd01b83b5122ff92b3b4996") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libdrm/package.py b/var/spack/repos/builtin/packages/libdrm/package.py index 0b7497efdd75bb..703f1def981438 100644 --- a/var/spack/repos/builtin/packages/libdrm/package.py +++ b/var/spack/repos/builtin/packages/libdrm/package.py @@ -18,6 +18,11 @@ class Libdrm(Package): license("MIT") + version("2.4.120", sha256="3bf55363f76c7250946441ab51d3a6cc0ae518055c0ff017324ab76cdefb327a") + version("2.4.119", sha256="0a49f12f09b5b6e68eaaaff3f02ca7cff9aa926939b212d343161d3e8ac56291") + version("2.4.118", sha256="a777bd85f2b5fc9c57f886c82058300578317cafdbc77d0a769d7e9a9567ab88") + version("2.4.117", sha256="a2888d69e3eb1c8a77adc08a75a60fbae01f0d208d26f034d1a12e362361242b") + version("2.4.116", sha256="46c53f40735ea3d26d614297f155f6131a510624a24274f654f6469ca905339a") version("2.4.115", sha256="554cfbfe0542bddb391b4e3e05bfbbfc3e282b955bd56218d21c0616481f65eb") version("2.4.114", sha256="3049cf843a47d12e5eeefbc3be3496d782fa09f42346bf0b7defe3d1e598d026") version("2.4.113", sha256="7fd7eb2967f63beb4606f22d50e277d993480d05ef75dd88a9bd8e677323e5e1") @@ -34,6 +39,8 @@ class Libdrm(Package): version("2.4.59", sha256="ed9d03a92c2d80e6310cc350db3430620f1659ae084a07c6824cee7bc81ae8fa") version("2.4.33", sha256="bd2a8fecf28616f2157ca33ede691c139cc294ed2d0c4244b62ca7d22e98e5a4") + depends_on("c", type="build") # generated + variant("docs", default=False, description="Build man pages") depends_on("pkgconfig", type="build") @@ -42,7 +49,8 @@ class Libdrm(Package): # 2.4.90 is the first version to use meson, spack defaults to meson since # 2.4.101. - depends_on("meson", type="build", when="@2.4.101:") + depends_on("meson@0.53:", type="build", when="@2.4.101:") + depends_on("meson@0.59:", type="build", when="@2.4.117:") # >= 2.4.104 uses reStructuredText for man pages. with when("@2.4.104: +docs"): diff --git a/var/spack/repos/builtin/packages/libdwarf/package.py b/var/spack/repos/builtin/packages/libdwarf/package.py index f935a7ca79147f..bdb570ef1382c1 100644 --- a/var/spack/repos/builtin/packages/libdwarf/package.py +++ b/var/spack/repos/builtin/packages/libdwarf/package.py @@ -35,6 +35,9 @@ class Libdwarf(Package): version("20130729", sha256="b6455d8616baf2883e2af91f006d6cbd583128fdfff46e3d1fae460bc223bb7b") version("20130207", sha256="5cb81459f0a1f6a2a10ef4635faddc2fa5e1a9e36901018c017759e491e708b8") version("20130126", sha256="c23c847935f8612f4fcdcfa0b3311f1553dcbd95bb683d3d5e030440201192fe") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("elfutils@0.163", when="@20160507", type="link") depends_on("elf", type="link") depends_on("zlib-api", type="link") diff --git a/var/spack/repos/builtin/packages/libeatmydata/package.py b/var/spack/repos/builtin/packages/libeatmydata/package.py index 02c69137c38b0b..d749d9e9bf29ac 100644 --- a/var/spack/repos/builtin/packages/libeatmydata/package.py +++ b/var/spack/repos/builtin/packages/libeatmydata/package.py @@ -20,6 +20,8 @@ class Libeatmydata(AutotoolsPackage): version("131", sha256="cf18a8c52138a38541be3478af446c06048108729d7e18476492d62d54baabc4") version("105", sha256="bdd2d068b6b27cf47cd22aa4c5da43b3d4a05944cfe0ad1b0d843d360ed3a8dd") + depends_on("c", type="build") # generated + depends_on("strace", type="test") def check(self): diff --git a/var/spack/repos/builtin/packages/libecpint/package.py b/var/spack/repos/builtin/packages/libecpint/package.py index dc6c9af0624466..34bab8e69cd132 100644 --- a/var/spack/repos/builtin/packages/libecpint/package.py +++ b/var/spack/repos/builtin/packages/libecpint/package.py @@ -26,6 +26,8 @@ class Libecpint(CMakePackage): version("1.0.1", sha256="245b89fe8cb0a92cbbb79c811b48cb15fcfc937389df89387466f1bf76a096bf") version("1.0.0", sha256="47d741cc48a543ef9c85483cb2d5cd1c9f6677fa7e9920886d083b3c25232379") + depends_on("cxx", type="build") # generated + depends_on("pugixml") depends_on("googletest") diff --git a/var/spack/repos/builtin/packages/libedit/package.py b/var/spack/repos/builtin/packages/libedit/package.py index 0353765a68882b..5a85f50e334f4f 100644 --- a/var/spack/repos/builtin/packages/libedit/package.py +++ b/var/spack/repos/builtin/packages/libedit/package.py @@ -33,6 +33,8 @@ class Libedit(AutotoolsPackage): "3.1-20150325", sha256="c88a5e4af83c5f40dda8455886ac98923a9c33125699742603a88a0253fcc8c5" ) + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("ncurses") @@ -43,7 +45,7 @@ def url_for_version(self, version): def configure_args(self): args = ["ac_cv_lib_curses_tgetent=no", "ac_cv_lib_termcap_tgetent=no"] - if "+termlib" in self.spec["ncurses"]: + if self.spec["ncurses"].satisfies("+termlib"): args.append("ac_cv_lib_ncurses_tgetent=no") else: args.append("ac_cv_lib_tinfo_tgetent=no") diff --git a/var/spack/repos/builtin/packages/libefence/package.py b/var/spack/repos/builtin/packages/libefence/package.py index a0178ed080925e..70902fb8876219 100644 --- a/var/spack/repos/builtin/packages/libefence/package.py +++ b/var/spack/repos/builtin/packages/libefence/package.py @@ -22,6 +22,8 @@ class Libefence(MakefilePackage): version("2.2.6", sha256="a949e0dedb06cbcd444566cce1457223f2c41abd3513f21663f30f19ccc48e24") + depends_on("c", type="build") # generated + def build(self, spec, prefix): make() diff --git a/var/spack/repos/builtin/packages/libelf/package.py b/var/spack/repos/builtin/packages/libelf/package.py index 4b575a6a92331a..e4fe56ec745d2f 100644 --- a/var/spack/repos/builtin/packages/libelf/package.py +++ b/var/spack/repos/builtin/packages/libelf/package.py @@ -29,6 +29,8 @@ class Libelf(AutotoolsPackage): version("0.8.13", sha256="591a9b4ec81c1f2042a97aa60564e0cb79d041c52faa7416acb38bc95bd2c76d") + depends_on("c", type="build") # generated + provides("elf@0") # configure: error: neither int nor long is 32-bit @@ -55,7 +57,7 @@ def install(self, spec, prefix): def flag_handler(self, name, flags): if name == "cflags": - if self.spec.satisfies("%clang@16:"): + if self.spec.satisfies("%clang@16:") or self.spec.satisfies("%gcc@14:"): flags.append("-Wno-error=implicit-int") flags.append("-Wno-error=implicit-function-declaration") return (flags, None, None) diff --git a/var/spack/repos/builtin/packages/libepoxy/package.py b/var/spack/repos/builtin/packages/libepoxy/package.py index 1736ae80d75a11..1a530a072cfca1 100644 --- a/var/spack/repos/builtin/packages/libepoxy/package.py +++ b/var/spack/repos/builtin/packages/libepoxy/package.py @@ -18,6 +18,8 @@ class Libepoxy(AutotoolsPackage): version("1.4.3", sha256="0b808a06c9685a62fca34b680abb8bc7fb2fda074478e329b063c1f872b826f6") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("gl") depends_on("libx11", when="+glx") diff --git a/var/spack/repos/builtin/packages/libestr/package.py b/var/spack/repos/builtin/packages/libestr/package.py index 1f8a2cf0d004b1..140ac55962803c 100644 --- a/var/spack/repos/builtin/packages/libestr/package.py +++ b/var/spack/repos/builtin/packages/libestr/package.py @@ -18,6 +18,8 @@ class Libestr(AutotoolsPackage): version("0.1.10", sha256="e8756b071540314abef25c044f893d6b5d249e46709329a4b3e7361403c29a1e") version("0.1.9", sha256="efa0b90b5fe22844bac26042f988de6e8b2770e28dbd84bf49b9982d9c3e34f8") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libev/package.py b/var/spack/repos/builtin/packages/libev/package.py index 4a9836ead6b540..e436d4d81ed6b9 100644 --- a/var/spack/repos/builtin/packages/libev/package.py +++ b/var/spack/repos/builtin/packages/libev/package.py @@ -17,8 +17,11 @@ class Libev(AutotoolsPackage): license("BSD-2-Clause OR GPL-2.0-or-later") version("develop", branch="master") + version("4.33", sha256="507eb7b8d1015fbec5b935f34ebed15bf346bed04a11ab82b8eee848c4205aea") version("4.24", sha256="973593d3479abdf657674a55afe5f78624b0e440614e2b8cb3a07f16d4d7f821") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build", when="@develop") depends_on("automake", type="build", when="@develop") depends_on("libtool", type="build", when="@develop") diff --git a/var/spack/repos/builtin/packages/libevdev/package.py b/var/spack/repos/builtin/packages/libevdev/package.py index 3bd9774d30ab89..4742be67360770 100644 --- a/var/spack/repos/builtin/packages/libevdev/package.py +++ b/var/spack/repos/builtin/packages/libevdev/package.py @@ -22,6 +22,8 @@ class Libevdev(AutotoolsPackage): version("1.5.1", sha256="a9a789abf2f047d2449f09458bb754a9dd53f550ea537654d59492acad787ce6") version("1.5.0", sha256="ae1b64f26f4b6b55d78bf6e8de87eeb8c58e964b1d457ffa8060e4a889dcb31f") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libevent/package.py b/var/spack/repos/builtin/packages/libevent/package.py index 22fe9966700b52..f209436385e5af 100644 --- a/var/spack/repos/builtin/packages/libevent/package.py +++ b/var/spack/repos/builtin/packages/libevent/package.py @@ -36,6 +36,8 @@ class Libevent(AutotoolsPackage): version("2.0.13", sha256="e2cc3b9f03e68ff878919b1cd031a210ba9ff376283d895161afcbc25aca00a9") version("2.0.12", sha256="ac0283f72e0f881e93ac3ae9497a20c78bd075c6c12506ad10e821aa1c29e5ab") + depends_on("c", type="build") # generated + variant( "openssl", default=True, description="Build with encryption enabled at the libevent level." ) diff --git a/var/spack/repos/builtin/packages/libevpath/package.py b/var/spack/repos/builtin/packages/libevpath/package.py index 0b88d6c597c977..2bf9681b800323 100644 --- a/var/spack/repos/builtin/packages/libevpath/package.py +++ b/var/spack/repos/builtin/packages/libevpath/package.py @@ -24,6 +24,8 @@ class Libevpath(CMakePackage): version("4.1.2", sha256="2c0d5acc0e1c5aadd32d7147d2f0ce26220e3870e21c7d5429372d8f881e519e") version("4.1.1", sha256="cfc9587f98c1f057eb25712855d14311fd91d6284151eee7bd8936c4ff7ee001") + depends_on("c", type="build") # generated + variant("enet_transport", default=False, description="Build an ENET transport for EVpath") depends_on("gtkorvo-enet", when="@4.4.0: +enet_transport") diff --git a/var/spack/repos/builtin/packages/libexif/package.py b/var/spack/repos/builtin/packages/libexif/package.py index 185be43a3669dd..553b406e2ac522 100644 --- a/var/spack/repos/builtin/packages/libexif/package.py +++ b/var/spack/repos/builtin/packages/libexif/package.py @@ -16,4 +16,6 @@ class Libexif(AutotoolsPackage, SourceforgePackage): license("LGPL-2.0-or-later") version("0.6.21", sha256="16cdaeb62eb3e6dfab2435f7d7bccd2f37438d21c5218ec4e58efa9157d4d41a") + + depends_on("c", type="build") # generated depends_on("glib") diff --git a/var/spack/repos/builtin/packages/libfabric/package.py b/var/spack/repos/builtin/packages/libfabric/package.py index 87fa608ba8daed..4e15a2acd7828a 100644 --- a/var/spack/repos/builtin/packages/libfabric/package.py +++ b/var/spack/repos/builtin/packages/libfabric/package.py @@ -24,8 +24,11 @@ class Libfabric(AutotoolsPackage): license("GPL-2.0-or-later") version("main", branch="main") + version("1.21.0", sha256="0c1b7b830d9147f661e5d7f359250b85b5a9885c330464cd3b5e5d35b86551c7") + version("1.20.2", sha256="75b89252a0b8b3eae8e60f7098af1598445a99a99e8fc1ff458e2fd5d4ef8cde") version("1.20.1", sha256="fd88d65c3139865d42a6eded24e121aadabd6373239cef42b76f28630d6eed76") version("1.20.0", sha256="7fbbaeb0e15c7c4553c0ac5f54e4ef7aecaff8a669d4ba96fa04b0fc780b9ddc") + version("1.19.1", sha256="b8839e56d80470a917453a7d8ad9cb717f6683fee28cf93de5f3a056ed4f04c8") version("1.19.0", sha256="f14c764be9103e80c46223bde66e530e5954cb28b3835b57c8e728479603ef9e") version("1.18.2", sha256="64d7837853ca84d2a413fdd96534b6a81e6e777cc13866e28cf86cd0ccf1b93e") version("1.18.1", sha256="4615ae1e22009e59c72ae03c20adbdbd4a3dce95aeefbc86cc2bf1acc81c9e38") @@ -61,6 +64,8 @@ class Libfabric(AutotoolsPackage): version("1.5.0", sha256="88a8ad6772f11d83e5b6f7152a908ffcb237af273a74a1bd1cb4202f577f1f23") version("1.4.2", sha256="5d027d7e4e34cb62508803e51d6bd2f477932ad68948996429df2bfff37ca2a5") + depends_on("c", type="build") # generated + fabrics = ( conditional("cxi", when=spack.platforms.cray.slingshot_network()), "efa", diff --git a/var/spack/repos/builtin/packages/libfastcommon/package.py b/var/spack/repos/builtin/packages/libfastcommon/package.py index b66f8a3b73fc16..cf3612f0e214c7 100644 --- a/var/spack/repos/builtin/packages/libfastcommon/package.py +++ b/var/spack/repos/builtin/packages/libfastcommon/package.py @@ -24,6 +24,8 @@ class Libfastcommon(Package): version("1.0.40", sha256="ebb89a1bfeb5b140f596fd3e2a0ff202420be05a4d80ef67ddcfdbb248b9fef8") version("1.0.39", sha256="72ca36f83f3453564ca09d2d0c31354b868cf52ef5a24cfb15e66d0e505c90ac") + depends_on("c", type="build") # generated + def install(self, spec, prefix): sh = which("sh") sh("make.sh") diff --git a/var/spack/repos/builtin/packages/libfastjson/package.py b/var/spack/repos/builtin/packages/libfastjson/package.py index 445f7a3604eb4e..69878f99669065 100644 --- a/var/spack/repos/builtin/packages/libfastjson/package.py +++ b/var/spack/repos/builtin/packages/libfastjson/package.py @@ -18,6 +18,8 @@ class Libfastjson(AutotoolsPackage): version("0.99.7", sha256="a142a6e5fa5c9c4ac32615c42fc663a1a14bff305c922e55192b6abf7d1ce1d8") version("0.99.6", sha256="617373e5205c84b5f674354df6ee9cba53ef8a227f0d1aa928666ed8a16d5547") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libffi/package.py b/var/spack/repos/builtin/packages/libffi/package.py index 703ce16d3a9360..c2b8b12a6e8d5b 100644 --- a/var/spack/repos/builtin/packages/libffi/package.py +++ b/var/spack/repos/builtin/packages/libffi/package.py @@ -17,6 +17,8 @@ class Libffi(AutotoolsPackage): license("MIT") + version("3.4.6", sha256="b0dea9df23c863a7a50e825440f3ebffabd65df1497108e5d437747843895a4e") + version("3.4.5", sha256="96fff4e589e3b239d888d9aa44b3ff30693c2ba1617f953925a70ddebcc102b2") version("3.4.4", sha256="d66c56ad259a82cf2a9dfc408b32bf5da52371500b84745f7fb8b645712df676") version("3.4.3", sha256="4416dd92b6ae8fcb5b10421e711c4d3cb31203d77521a77d85d0102311e6c3b8") version("3.4.2", sha256="540fb721619a6aba3bdeef7d940d8e9e0e6d2c193595bc243241b77ff9e93620") @@ -31,6 +33,9 @@ class Libffi(AutotoolsPackage): sha256="d06ebb8e1d9a22d19e38d63fdb83954253f39bedc5d46232a05645685722ca37", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("clang-powerpc-3.2.1.patch", when="@3.2.1%clang platform=linux") # ref.: https://github.com/libffi/libffi/pull/561 patch("powerpc-3.3.patch", when="@3.3") @@ -56,7 +61,7 @@ def flag_handler(self, name, flags): return (flags, None, None) def configure_args(self): - args = [] + args = ["--with-pic"] if self.spec.version >= Version("3.3"): # Spack adds its own target flags, so tell libffi not to # second-guess us diff --git a/var/spack/repos/builtin/packages/libffs/package.py b/var/spack/repos/builtin/packages/libffs/package.py index 0623e1637bb733..ad3a2d1de1d81c 100644 --- a/var/spack/repos/builtin/packages/libffs/package.py +++ b/var/spack/repos/builtin/packages/libffs/package.py @@ -23,6 +23,8 @@ class Libffs(CMakePackage): version("1.1.1", sha256="9c3a82b3357e6ac255b65d4f45003dd270dea3ec0cd7a2aa40b59b3eab4bdb83") version("1.1", sha256="008fd87c5a6cb216cd757b4dc04057fc987b39b7a367623eb4cf0fd32a9fd81e") + depends_on("c", type="build") # generated + depends_on("flex", type="build", when="@:1.4") depends_on("bison", type="build", when="@:1.4") depends_on("gtkorvo-cercs-env", type="build", when="@:1.4") diff --git a/var/spack/repos/builtin/packages/libfirefly/package.py b/var/spack/repos/builtin/packages/libfirefly/package.py index 40ef846e163233..4230fb8b72ec72 100644 --- a/var/spack/repos/builtin/packages/libfirefly/package.py +++ b/var/spack/repos/builtin/packages/libfirefly/package.py @@ -20,6 +20,8 @@ class Libfirefly(CMakePackage): version("master", branch="master") version("2.1.0", sha256="4de4b216c73199a1826de7a0d45205b401603315347d7947d8b5950d3e6b893d") + depends_on("cxx", type="build") # generated + variant( "double-precision", description="Enables double type instead of float when enabled", diff --git a/var/spack/repos/builtin/packages/libfive/package.py b/var/spack/repos/builtin/packages/libfive/package.py index 71935c8128e1b2..04d2036b6e1b97 100644 --- a/var/spack/repos/builtin/packages/libfive/package.py +++ b/var/spack/repos/builtin/packages/libfive/package.py @@ -19,6 +19,8 @@ class Libfive(CMakePackage): # and currently, all tags are from 2017: version("master", branch="master") + depends_on("cxx", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("cmake@3.12:", type="build") depends_on("boost@1.65:") diff --git a/var/spack/repos/builtin/packages/libflame/package.py b/var/spack/repos/builtin/packages/libflame/package.py index f92c306aba207a..e43d9d358a4a2f 100644 --- a/var/spack/repos/builtin/packages/libflame/package.py +++ b/var/spack/repos/builtin/packages/libflame/package.py @@ -133,6 +133,9 @@ class Libflame(LibflameBase): version("5.2.0", sha256="997c860f351a5c7aaed8deec00f502167599288fd0559c92d5bfd77d0b4d475c") version("5.1.0", sha256="e7189b750890bd781fe773f366b374518dd1d89a6513d3d6261bf549826384d1") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + provides("flame@5.2", when="@5.2.0") provides("flame@5.1", when="@5.1.0") diff --git a/var/spack/repos/builtin/packages/libfms/package.py b/var/spack/repos/builtin/packages/libfms/package.py index a7e30c70dbe1ef..109f09800b4122 100644 --- a/var/spack/repos/builtin/packages/libfms/package.py +++ b/var/spack/repos/builtin/packages/libfms/package.py @@ -21,6 +21,9 @@ class Libfms(CMakePackage): version("develop", branch="master") version("0.2.0", tag="v0.2", commit="a66cb96711cc404c411f1bf07ca8db09b6f894eb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("conduit", default=True, description="Build with Conduit I/O support") variant("shared", default=True, description="Build shared libraries") diff --git a/var/spack/repos/builtin/packages/libfontenc/package.py b/var/spack/repos/builtin/packages/libfontenc/package.py index eb0daf794e34e9..79c153853e4f05 100644 --- a/var/spack/repos/builtin/packages/libfontenc/package.py +++ b/var/spack/repos/builtin/packages/libfontenc/package.py @@ -18,6 +18,8 @@ class Libfontenc(AutotoolsPackage, XorgPackage): version("1.1.7", sha256="5e5f210329823f08f97bfe9fd5b4105070c789bc5aef88ce01d86d8203d4aa9f") version("1.1.3", sha256="6fba26760ca8d5045f2b52ddf641c12cedc19ee30939c6478162b7db8b6220fb") + depends_on("c", type="build") # generated + depends_on("zlib-api") depends_on("xproto") diff --git a/var/spack/repos/builtin/packages/libfort/package.py b/var/spack/repos/builtin/packages/libfort/package.py new file mode 100644 index 00000000000000..6a09762f3e8162 --- /dev/null +++ b/var/spack/repos/builtin/packages/libfort/package.py @@ -0,0 +1,39 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Libfort(CMakePackage): + """libfort is a simple crossplatform library to create formatted text tables.""" + + homepage = "https://github.com/seleznevae/libfort" + url = "https://github.com/seleznevae/libfort/archive/refs/tags/v0.4.2.tar.gz" + + license("MIT") + + version("0.4.2", sha256="8f7b03f1aa526e50c9828f09490f3c844b73d5f9ca72493fe81931746f75e489") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant("enable_astyle", default=False, description="Enable astyle") + variant("enable_wchar", default=True, description="Enable wchar support") + variant("enable_utf8", default=True, description="Enable utf8 support") + variant("enable_testing", default=True, description="Enables building tests and examples") + variant("shared", default=False, description="Build shared library") + + depends_on("cmake@3.0.0:", type="build") + + def cmake_args(self): + args = [ + self.define_from_variant("FORT_ENABLE_ASTYLE", "enable_astyle"), + self.define_from_variant("FORT_ENABLE_WCHAR", "enable_wchar"), + self.define_from_variant("FORT_ENABLE_UTF8", "enable_utf8"), + self.define_from_variant("FORT_ENABLE_TESTING", "enable_testing"), + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + ] + + return args diff --git a/var/spack/repos/builtin/packages/libfs/package.py b/var/spack/repos/builtin/packages/libfs/package.py index 05a557246dd06e..9675762e54a319 100644 --- a/var/spack/repos/builtin/packages/libfs/package.py +++ b/var/spack/repos/builtin/packages/libfs/package.py @@ -18,6 +18,8 @@ class Libfs(AutotoolsPackage, XorgPackage): version("1.0.9", sha256="8bc2762f63178905228a28670539badcfa2c8793f7b6ce3f597b7741b932054a") version("1.0.7", sha256="91bf1c5ce4115b7dbf4e314fdbee54052708e8f7b6a2ec6e82c309bcbe40ef3d") + depends_on("c", type="build") # generated + depends_on("xproto@7.0.17:") depends_on("fontsproto") depends_on("xtrans") diff --git a/var/spack/repos/builtin/packages/libfuse/package.py b/var/spack/repos/builtin/packages/libfuse/package.py index 6aabffb453b89d..5177736a113c0d 100644 --- a/var/spack/repos/builtin/packages/libfuse/package.py +++ b/var/spack/repos/builtin/packages/libfuse/package.py @@ -31,6 +31,9 @@ class Libfuse(MesonPackage): version("3.9.2", sha256="b4409255cbda6f6975ca330f5b04cb335b823a95ddd8c812c3d224ec53478fc0") version("2.9.9", sha256="d0e69d5d608cc22ff4843791ad097f554dd32540ddc9bed7638cc6fea7c1b4b5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): if version < Version("3.0.0"): return "https://github.com/libfuse/libfuse/releases/download/fuse-{0}/fuse-{1}.tar.gz".format( diff --git a/var/spack/repos/builtin/packages/libfyaml/package.py b/var/spack/repos/builtin/packages/libfyaml/package.py index 9f19520e3ee037..7b2d4ac0d2a26e 100644 --- a/var/spack/repos/builtin/packages/libfyaml/package.py +++ b/var/spack/repos/builtin/packages/libfyaml/package.py @@ -15,8 +15,11 @@ class Libfyaml(AutotoolsPackage): license("MIT") + version("0.9", sha256="7731edc5dfcc345d5c5c9f6ce597133991a689dabede393cd77bae89b327cd6d") version("0.8", sha256="dc4d4348eedca68e8e2394556d57f71410e7d61791a71cbe178302ebe5f26b99") version("0.7.12", sha256="485342c6920e9fdc2addfe75e5c3e0381793f18b339ab7393c1b6edf78bf8ca8") version("0.5.7", sha256="3221f31bb3feba97e544a82d0d5e4711ff0e4101cca63923dc5a1a001c187590") + depends_on("c", type="build") # generated + depends_on("m4", type="build") diff --git a/var/spack/repos/builtin/packages/libgain/package.py b/var/spack/repos/builtin/packages/libgain/package.py index dfe0bdc2924756..3f265a9e468a37 100644 --- a/var/spack/repos/builtin/packages/libgain/package.py +++ b/var/spack/repos/builtin/packages/libgain/package.py @@ -22,6 +22,8 @@ class Libgain(AutotoolsPackage): url="https://gitlab.com/l_sim/bigdft-suite/-/raw/1.9.1/GaIn-1.0.tar.gz", ) + depends_on("fortran", type="build") # generated + @property def libs(self): shared = "+shared" in self.spec diff --git a/var/spack/repos/builtin/packages/libgcrypt/package.py b/var/spack/repos/builtin/packages/libgcrypt/package.py index 9066892a96332e..3c5bcfdd5d4004 100644 --- a/var/spack/repos/builtin/packages/libgcrypt/package.py +++ b/var/spack/repos/builtin/packages/libgcrypt/package.py @@ -16,15 +16,19 @@ class Libgcrypt(AutotoolsPackage): license("LGPL-2.1-or-later AND GPL-2.0-or-later") + version("1.11.0", sha256="09120c9867ce7f2081d6aaa1775386b98c2f2f246135761aae47d81f58685b9c") version("1.10.3", sha256="8b0870897ac5ac67ded568dcfadf45969cfa8a6beb0fd60af2a9eadc2a3272aa") version("1.10.2", sha256="3b9c02a004b68c256add99701de00b383accccf37177e0d6c58289664cce0c03") version("1.10.1", sha256="ef14ae546b0084cd84259f61a55e07a38c3b53afc0f546bffcef2f01baffe9de") version("1.10.0", sha256="6a00f5c05caa4c4acc120c46b63857da0d4ff61dc4b4b03933fa8d46013fae81") + # End of life: 2024-03-31 - version("1.9.4", sha256="ea849c83a72454e3ed4267697e8ca03390aee972ab421e7df69dfe42b65caaf7") - version("1.9.3", sha256="97ebe4f94e2f7e35b752194ce15a0f3c66324e0ff6af26659bbfb5ff2ec328fd") - version("1.9.2", sha256="b2c10d091513b271e47177274607b1ffba3d95b188bbfa8797f948aec9053c5a") - version("1.9.1", sha256="c5a67a8b9b2bd370fb415ed1ee31c7172e5683076493cf4a3678a0fbdf0265d9") + with default_args(deprecated=True): + version("1.9.4", sha256="ea849c83a72454e3ed4267697e8ca03390aee972ab421e7df69dfe42b65caaf7") + version("1.9.3", sha256="97ebe4f94e2f7e35b752194ce15a0f3c66324e0ff6af26659bbfb5ff2ec328fd") + version("1.9.2", sha256="b2c10d091513b271e47177274607b1ffba3d95b188bbfa8797f948aec9053c5a") + version("1.9.1", sha256="c5a67a8b9b2bd370fb415ed1ee31c7172e5683076493cf4a3678a0fbdf0265d9") + # End of life: 2024-12-31 (LTS) version("1.8.9", sha256="2bda4790aa5f0895d3407cf7bf6bd7727fd992f25a45a63d92fef10767fa3769") version("1.8.7", sha256="03b70f028299561b7034b8966d7dd77ef16ed139c43440925fe8782561974748") @@ -32,19 +36,15 @@ class Libgcrypt(AutotoolsPackage): version("1.8.5", sha256="3b4a2a94cb637eff5bdebbcaf46f4d95c4f25206f459809339cdada0eb577ac3") version("1.8.4", sha256="f638143a0672628fde0cad745e9b14deb85dffb175709cacc1f4fe24b93f2227") version("1.8.1", sha256="7a2875f8b1ae0301732e878c0cca2c9664ff09ef71408f085c50e332656a78b3") - # End of life: 2019-06-30 - version( - "1.7.6", - sha256="626aafee84af9d2ce253d2c143dc1c0902dda045780cc241f39970fc60be05bc", - deprecated=True, - ) - version( - "1.6.2", - sha256="de084492a6b38cdb27b67eaf749ceba76bf7029f63a9c0c3c1b05c88c9885c4c", - deprecated=True, - ) + + depends_on("c", type="build") # generated depends_on("libgpg-error@1.25:") + depends_on("libgpg-error@1.27:", when="@1.9:") + depends_on("libgpg-error@1.49:", when="@1.11:") + + # See https://dev.gnupg.org/T7170 + conflicts("platform=darwin", when="@1.11.0") def flag_handler(self, name, flags): # We should not inject optimization flags through the wrapper, because diff --git a/var/spack/repos/builtin/packages/libgd/package.py b/var/spack/repos/builtin/packages/libgd/package.py index aba8e8045d13a9..8beb6e83d54050 100644 --- a/var/spack/repos/builtin/packages/libgd/package.py +++ b/var/spack/repos/builtin/packages/libgd/package.py @@ -24,6 +24,9 @@ class Libgd(AutotoolsPackage): version("2.3.3", sha256="dd3f1f0bb016edcc0b2d082e8229c822ad1d02223511997c80461481759b1ed2") version("2.2.4", sha256="487a650aa614217ed08ab1bd1aa5d282f9d379cfd95c756aed0b43406381be65") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Build dependencies depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/libgdsii/package.py b/var/spack/repos/builtin/packages/libgdsii/package.py index 660ad7e479b07f..2681d3919e7afa 100644 --- a/var/spack/repos/builtin/packages/libgdsii/package.py +++ b/var/spack/repos/builtin/packages/libgdsii/package.py @@ -19,6 +19,8 @@ class Libgdsii(AutotoolsPackage): version("0.21", sha256="1adc571c6b53df4c08d108f9ac4f4a7fd6fbefd4bc56f74e0b7b2801353671b8") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libgeotiff/package.py b/var/spack/repos/builtin/packages/libgeotiff/package.py index 4be72c04b58d1d..3a50f6d2fad66b 100644 --- a/var/spack/repos/builtin/packages/libgeotiff/package.py +++ b/var/spack/repos/builtin/packages/libgeotiff/package.py @@ -27,6 +27,8 @@ class Libgeotiff(AutotoolsPackage): version("1.4.3", sha256="b8510d9b968b5ee899282cdd5bef13fd02d5a4c19f664553f81e31127bc47265") version("1.4.2", sha256="ad87048adb91167b07f34974a8e53e4ec356494c29f1748de95252e8f81a5e6e") + depends_on("c", type="build") # generated + variant("zlib", default=True, description="Include zlib support") variant("jpeg", default=True, description="Include jpeg support") variant("proj", default=True, description="Use PROJ.x library") diff --git a/var/spack/repos/builtin/packages/libgff/package.py b/var/spack/repos/builtin/packages/libgff/package.py index bfced2214727bd..074a58c675e8c3 100644 --- a/var/spack/repos/builtin/packages/libgff/package.py +++ b/var/spack/repos/builtin/packages/libgff/package.py @@ -17,3 +17,5 @@ class Libgff(CMakePackage): maintainers("ajxander12") version("2.0.0", sha256="7656b19459a7ca7d2fd0fcec4f2e0fd0deec1b4f39c703a114e8f4c22d82a99c") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libgit2/package.py b/var/spack/repos/builtin/packages/libgit2/package.py index cb721c99838891..19655d280a07c8 100644 --- a/var/spack/repos/builtin/packages/libgit2/package.py +++ b/var/spack/repos/builtin/packages/libgit2/package.py @@ -16,6 +16,7 @@ class Libgit2(CMakePackage): homepage = "https://libgit2.github.com/" url = "https://github.com/libgit2/libgit2/archive/v0.26.0.tar.gz" + version("1.8.0", sha256="9e1d6a880d59026b675456fbb1593c724c68d73c34c0d214d6eb848e9bbd8ae4") version("1.7.2", sha256="de384e29d7efc9330c6cdb126ebf88342b5025d920dcb7c645defad85195ea7f") version("1.7.0", sha256="d9d0f84a86bf98b73e68997f5c1543cc5067d0ca9c7a5acaba3e8d117ecefef3") version("1.6.4", sha256="d25866a4ee275a64f65be2d9a663680a5cf1ed87b7ee4c534997562c828e500d") @@ -65,6 +66,8 @@ class Libgit2(CMakePackage): version("0.26.1", sha256="68cd0f8ee9e0ca84dcf0f0267d0a8297471d3365622d22d3da67c57165bb0722") version("0.26.0", sha256="6a62393e0ceb37d02fe0d5707713f504e7acac9006ef33da1e88960bd78b6eac") + depends_on("c", type="build") # generated + # Backends variant( "https", @@ -89,7 +92,6 @@ class Libgit2(CMakePackage): # Runtime Dependencies depends_on("libssh2", when="+ssh") depends_on("openssl", when="https=system platform=linux") - depends_on("openssl", when="https=system platform=cray") depends_on("openssl", when="https=openssl") depends_on("curl", when="+curl") depends_on("pcre", when="@0.99:") @@ -104,7 +106,7 @@ def flag_handler(self, name, flags): def cmake_args(self): args = [] if "https=system" in self.spec: - if "platform=linux" in self.spec or "platform=cray" in self.spec: + if "platform=linux" in self.spec: args.append("-DUSE_HTTPS=OpenSSL") elif "platform=darwin" in self.spec: args.append("-DUSE_HTTPS=SecureTransport") diff --git a/var/spack/repos/builtin/packages/libgpg-error/package.py b/var/spack/repos/builtin/packages/libgpg-error/package.py index b28ada157b8f99..6b78a254237257 100644 --- a/var/spack/repos/builtin/packages/libgpg-error/package.py +++ b/var/spack/repos/builtin/packages/libgpg-error/package.py @@ -16,6 +16,8 @@ class LibgpgError(AutotoolsPackage): license("GPL-2.0-or-later AND LGPL-2.1-or-later") + version("1.50", sha256="69405349e0a633e444a28c5b35ce8f14484684518a508dc48a089992fe93e20a") + version("1.49", sha256="8b79d54639dbf4abc08b5406fb2f37e669a2dec091dd024fb87dd367131c63a9") version("1.48", sha256="89ce1ae893e122924b858de84dc4f67aae29ffa610ebf668d5aa539045663d6f") version("1.47", sha256="9e3c670966b96ecc746c28c2c419541e3bcb787d1a73930f5e5f5e1bcbbb9bdb") version("1.46", sha256="b7e11a64246bbe5ef37748de43b245abd72cfcd53c9ae5e7fc5ca59f1c81268d") @@ -31,9 +33,18 @@ class LibgpgError(AutotoolsPackage): version("1.21", sha256="b7dbdb3cad63a740e9f0c632a1da32d4afdb694ec86c8625c98ea0691713b84d") version("1.18", sha256="9ff1d6e61d4cef7c1d0607ceef6d40dc33f3da7a3094170c3718c00153d80810") + depends_on("c", type="build") # generated + depends_on("awk", type="build") # Patch for using gawk@5, c.f. https://dev.gnupg.org/T4459 patch("awk-5.patch", when="@1.36^gawk@5:") + # See https://github.com/macports/macports-ports/pull/24601 and https://dev.gnupg.org/T7169 + patch( + "https://raw.githubusercontent.com/ryandesign/macports-ports/290e77cca6ce054768ddefee2b51222d72780ac9/devel/libgpg-error/files/patch-src-spawn-posix.c.diff", + sha256="0b2a0ffab81b2b0b40d6ab59016c92fcebbe80710a3e0adba570f73f7a931d16", + level=0, + when="@1.50", + ) def configure_args(self): args = [ diff --git a/var/spack/repos/builtin/packages/libgpuarray/package.py b/var/spack/repos/builtin/packages/libgpuarray/package.py index fb989c250406f6..3b990e3bd945dd 100644 --- a/var/spack/repos/builtin/packages/libgpuarray/package.py +++ b/var/spack/repos/builtin/packages/libgpuarray/package.py @@ -24,6 +24,8 @@ class Libgpuarray(CMakePackage): version("0.6.1", sha256="b2466311e0e3bacdf7a586bba0263f6d232bf9f8d785e91ddb447653741e6ea5") version("0.6.0", sha256="a58a0624e894475a4955aaea25e82261c69b4d22c8f15ec07041a4ba176d35af") + depends_on("c", type="build") # generated + depends_on("cuda") depends_on("cmake@3:", type="build") depends_on("check") diff --git a/var/spack/repos/builtin/packages/libgridxc/package.py b/var/spack/repos/builtin/packages/libgridxc/package.py index 90473c0b0b9abe..85006947773b23 100644 --- a/var/spack/repos/builtin/packages/libgridxc/package.py +++ b/var/spack/repos/builtin/packages/libgridxc/package.py @@ -26,6 +26,8 @@ class Libgridxc(MakefilePackage): version("0.8.0", sha256="ff89b3302f850d1d9f651951e4ade20dfa4c71c809a2d86382c6797392064c9c") version("0.7.6", sha256="058b80f40c85997eea0eae3f15b7cc8105f817e59564106308b22f57a03b216b") + depends_on("fortran", type="build") # generated + depends_on("autoconf@2.69:", type="build") depends_on("automake@1.14:", type="build") depends_on("libtool@2.4.2:", type="build") diff --git a/var/spack/repos/builtin/packages/libgssglue/package.py b/var/spack/repos/builtin/packages/libgssglue/package.py index a3accd3280b4a3..f838f4d0bab544 100644 --- a/var/spack/repos/builtin/packages/libgssglue/package.py +++ b/var/spack/repos/builtin/packages/libgssglue/package.py @@ -17,3 +17,5 @@ class Libgssglue(AutotoolsPackage): version("0.4", sha256="3f791a75502ba723e5e85e41e5e0c711bb89e2716b7c0ec6e74bd1df6739043a") version("0.3", sha256="d98a022af432b61fe2a1eb811b5916743ccb781e383da680f1a00fd1005a5174") version("0.2", sha256="3de4974e19e54048acdc465d3b3c6c006cb66d2952d36e6b0afc10012184dc91") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libgta/package.py b/var/spack/repos/builtin/packages/libgta/package.py index 022be5a31d9abe..629408f62bc035 100644 --- a/var/spack/repos/builtin/packages/libgta/package.py +++ b/var/spack/repos/builtin/packages/libgta/package.py @@ -16,6 +16,9 @@ class Libgta(CMakePackage): version("1.2.1", sha256="d445667e145f755f0bc34ac89b63a6bfdce1eea943f87ee7a3f23dc0dcede8b1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.5:", type="build") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/libgtextutils/package.py b/var/spack/repos/builtin/packages/libgtextutils/package.py index c10e53bcb29666..4092d64ac39124 100644 --- a/var/spack/repos/builtin/packages/libgtextutils/package.py +++ b/var/spack/repos/builtin/packages/libgtextutils/package.py @@ -16,3 +16,6 @@ class Libgtextutils(AutotoolsPackage): patch("text_line_reader.patch") version("0.7", sha256="792e0ea3c96ffe3ad65617a104b7dc50684932bc96d2adab501c952fd65c3e4a") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libgtop/package.py b/var/spack/repos/builtin/packages/libgtop/package.py new file mode 100644 index 00000000000000..4486d691922edd --- /dev/null +++ b/var/spack/repos/builtin/packages/libgtop/package.py @@ -0,0 +1,26 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class Libgtop(AutotoolsPackage): + """Contains the GNOME top libraries for collecting system monitoring data""" + + homepage = "https://gitlab.gnome.org/GNOME/libgtop" + url = "https://download.gnome.org/sources/libgtop/2.41/libgtop-2.41.3.tar.xz" + + maintainers("teaguesterling") + + license("GPLv2", checked_by="teaguesterling") + + version("2.41.2", sha256="d9026cd8a48d27cdffd332f8d60a92764b56424e522c420cd13a01f40daf92c3") + version("2.41.1", sha256="43ea9ad13f7caf98303e64172b191be9b96bab340b019deeec72251ee140fe3b") + + depends_on("c", type="build") # generated + + depends_on("pkgconfig", type="build") + with default_args(type=("build", "link", "run")): + depends_on("glib@2.65:", when="@2.40:") + depends_on("gettext@:0.19", when="@:2.40.0") diff --git a/var/spack/repos/builtin/packages/libgudev/package.py b/var/spack/repos/builtin/packages/libgudev/package.py new file mode 100644 index 00000000000000..fa2642319299ef --- /dev/null +++ b/var/spack/repos/builtin/packages/libgudev/package.py @@ -0,0 +1,22 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class Libgudev(MesonPackage): + """Provides GObject bindings for libudev.""" + + homepage = "https://gitlab.gnome.org/GNOME/libgudev/" + url = "https://download.gnome.org/sources/libgudev/238/libgudev-238.tar.xz" + + maintainers("teaguesterling") + + license("LGPL2.1", checked_by="teaguesterling") + + version("238", sha256="61266ab1afc9d73dbc60a8b2af73e99d2fdff47d99544d085760e4fa667b5dd1") + + with default_args(type=("build", "link", "run")): + depends_on("glib@2.38:") + depends_on("systemd@251:") # For libuvdev diff --git a/var/spack/repos/builtin/packages/libharu/package.py b/var/spack/repos/builtin/packages/libharu/package.py index baebd257b70089..e3cad31663f64b 100644 --- a/var/spack/repos/builtin/packages/libharu/package.py +++ b/var/spack/repos/builtin/packages/libharu/package.py @@ -24,6 +24,9 @@ class Libharu(AutotoolsPackage): version("2.3.0", sha256="8f9e68cc5d5f7d53d1bc61a1ed876add1faf4f91070dbc360d8b259f46d9a4d2") version("2.2.0", sha256="5e63246d2da0272a9dbe5963fd827c7efa6e29d97a2d047c0d4c5f0b780f10b5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libtool", type=("build")) depends_on("autoconf", type=("build")) depends_on("automake", type=("build")) @@ -41,8 +44,8 @@ def configure_args(self): spec = self.spec args = [] - args.append("--with-zlib={0}".format(spec["zlib-api"].prefix)) - args.append("--with-png={0}".format(spec["libpng"].prefix)) + args.append(f"--with-zlib={spec['zlib-api'].prefix}") + args.append(f"--with-png={spec['libpng'].prefix}") return args diff --git a/var/spack/repos/builtin/packages/libhbaapi/package.py b/var/spack/repos/builtin/packages/libhbaapi/package.py index b61bcf2d7952cd..7749ecbc406e0e 100644 --- a/var/spack/repos/builtin/packages/libhbaapi/package.py +++ b/var/spack/repos/builtin/packages/libhbaapi/package.py @@ -18,6 +18,8 @@ class Libhbaapi(AutotoolsPackage): version("3.10", sha256="ca4f4ec3defa057c1b51bc87cc749efe5d54579e055d7a51688d18cc35166462") version("3.9", sha256="8e60616abde44488fed05254988f9b41653d2204a7218072714d6623e099c863") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libheif/package.py b/var/spack/repos/builtin/packages/libheif/package.py index fd45ec6bba262d..d33799e21045af 100644 --- a/var/spack/repos/builtin/packages/libheif/package.py +++ b/var/spack/repos/builtin/packages/libheif/package.py @@ -16,4 +16,7 @@ class Libheif(CMakePackage): version("1.12.0", sha256="086145b0d990182a033b0011caadb1b642da84f39ab83aa66d005610650b3c65") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.13:", type="build") diff --git a/var/spack/repos/builtin/packages/libhio/package.py b/var/spack/repos/builtin/packages/libhio/package.py index e978ede51507e0..b9a67e35bf21a0 100644 --- a/var/spack/repos/builtin/packages/libhio/package.py +++ b/var/spack/repos/builtin/packages/libhio/package.py @@ -32,6 +32,8 @@ class Libhio(AutotoolsPackage): version("1.4.1.1", sha256="5c65d18bf74357f9d9960bf6b9ad2432f8fc5a2b653e72befe4d1caabb9a2f7a") version("1.4.1.0", sha256="963f4a8d365afd92a5593f80946e2c4c79f4185d897436a43fae61dae5567ac4") + depends_on("c", type="build") # generated + # # main users of libhio thru spack will want to use HFDF5 plugin, # so make hdf5 variant a default diff --git a/var/spack/repos/builtin/packages/libhugetlbfs/package.py b/var/spack/repos/builtin/packages/libhugetlbfs/package.py index ba0bd486808f0d..a6eeb114566136 100644 --- a/var/spack/repos/builtin/packages/libhugetlbfs/package.py +++ b/var/spack/repos/builtin/packages/libhugetlbfs/package.py @@ -6,16 +6,28 @@ from spack.package import * -class Libhugetlbfs(MakefilePackage): +class Libhugetlbfs(AutotoolsPackage): """libhugetlbfs is a library which provides easy access to huge pages of memory.""" homepage = "https://github.com/libhugetlbfs/libhugetlbfs" - url = "https://github.com/libhugetlbfs/libhugetlbfs/releases/download/2.22/libhugetlbfs-2.22.tar.gz" + url = "https://github.com/libhugetlbfs/libhugetlbfs/releases/download/2.24/libhugetlbfs-2.24.tar.gz" license("LGPL-2.1-or-later") - version("2.22", sha256="94dca9ea2c527cd77bf28904094fe4708865a85122d416bfccc8f4b73b9a6785") + version("2.24", sha256="d501dfa91c8ead1106967a3d3829f2ba738c3fac0a65cb358ed2ab3870ddc5ef") - def install(self, spec, prefix): - make("install", "PREFIX=%s" % prefix) + depends_on("c", type="build") # generated + + depends_on("autoconf", type="build") + depends_on("automake", type="build") + depends_on("libtool", type="build") + + build_targets = ["-e", "libs", "tools"] + install_targets = ["-e", "install"] + parallel = False + + def setup_build_environment(self, env): + env.set("BUILDTYPE", "NATIVEONLY") + env.set("PREFIX", self.prefix) + env.set("V", "1") diff --git a/var/spack/repos/builtin/packages/libiberty/package.py b/var/spack/repos/builtin/packages/libiberty/package.py index 41f2f3ac691ce5..f5bf3acb4b08ee 100644 --- a/var/spack/repos/builtin/packages/libiberty/package.py +++ b/var/spack/repos/builtin/packages/libiberty/package.py @@ -37,6 +37,9 @@ class Libiberty(AutotoolsPackage, GNUMirrorPackage): version("2.29.1", sha256="e7010a46969f9d3e53b650a518663f98a5dde3c3ae21b7d71e5e6803bc36b577") version("2.28.1", sha256="16328a906e55a3c633854beec8e9e255a639b366436470b4f6245eb0d2fde942") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("pic", default=False, description="Compile with position independent code.") # Configure and build just libiberty. diff --git a/var/spack/repos/builtin/packages/libibumad/package.py b/var/spack/repos/builtin/packages/libibumad/package.py index 2601b3ffbe49e2..19a3fbd7a62881 100644 --- a/var/spack/repos/builtin/packages/libibumad/package.py +++ b/var/spack/repos/builtin/packages/libibumad/package.py @@ -19,6 +19,8 @@ class Libibumad(CMakePackage): version("44.1", sha256="1dec7e25dd248f1ff4d262e5674297205ad9113a4ff25ab7ecbb75a824adac27") version("25.0", sha256="d735bd091d13e8a68ce650e432b5bdc934fc7f1d5fb42a6045278a5b3f7fe48b") + depends_on("c", type="build") # generated + depends_on("libnl") def build(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/libical/package.py b/var/spack/repos/builtin/packages/libical/package.py index f75326a9a65c32..452dbabd65198c 100644 --- a/var/spack/repos/builtin/packages/libical/package.py +++ b/var/spack/repos/builtin/packages/libical/package.py @@ -14,10 +14,14 @@ class Libical(CMakePackage): license("LGPL-2.1-only OR MPL-2.0") + version("3.0.18", sha256="72b7dc1a5937533aee5a2baefc990983b66b141dd80d43b51f80aced4aae219c") version("3.0.17", sha256="bcda9a6db6870240328752854d1ea475af9bbc6356e6771018200e475e5f781b") version("3.0.11", sha256="1e6c5e10c5a48f7a40c68958055f0e2759d9ab3563aca17273fe35a5df7dbbf1") version("3.0.8", sha256="09fecacaf75ba5a242159e3a9758a5446b5ce4d0ab684f98a7040864e1d1286f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1.0:", type="build") depends_on("perl", type="build") depends_on("pkgconfig", type="build") @@ -26,4 +30,4 @@ class Libical(CMakePackage): depends_on("libxml2@2.7.3:") def cmake_args(self): - return ["-DENABLE_GTK_DOC=OFF"] + return [self.define("ENABLE_GTK_DOC", "OFF")] diff --git a/var/spack/repos/builtin/packages/libicd/package.py b/var/spack/repos/builtin/packages/libicd/package.py index a8c7521e4495b4..307e372772ded3 100644 --- a/var/spack/repos/builtin/packages/libicd/package.py +++ b/var/spack/repos/builtin/packages/libicd/package.py @@ -16,6 +16,9 @@ class Libicd(CMakePackage): version("main", branch="main") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.5:", type="build") depends_on("jpeg") depends_on("libpng") diff --git a/var/spack/repos/builtin/packages/libice/package.py b/var/spack/repos/builtin/packages/libice/package.py index 5a7565b5e7f594..574d80e0faa363 100644 --- a/var/spack/repos/builtin/packages/libice/package.py +++ b/var/spack/repos/builtin/packages/libice/package.py @@ -21,10 +21,11 @@ class Libice(AutotoolsPackage, XorgPackage): version("1.0.10", sha256="1116bc64c772fd127a0d0c0ffa2833479905e3d3d8197740b3abd5f292f22d2d") version("1.0.9", sha256="7812a824a66dd654c830d21982749b3b563d9c2dfe0b88b203cefc14a891edc0") + depends_on("c", type="build") # generated + # technically libbsd is only required when glibc < 2.36 which provides arc4random_buf, # but spack doesn't currently have a good way to model this so we depend on it unconditionally depends_on("libbsd", when="platform=linux") - depends_on("libbsd", when="platform=cray") depends_on("xproto") depends_on("xtrans") diff --git a/var/spack/repos/builtin/packages/libiconv/package.py b/var/spack/repos/builtin/packages/libiconv/package.py index efe9584a828948..bbc0178a95da1e 100644 --- a/var/spack/repos/builtin/packages/libiconv/package.py +++ b/var/spack/repos/builtin/packages/libiconv/package.py @@ -20,6 +20,8 @@ class Libiconv(AutotoolsPackage, GNUMirrorPackage): version("1.15", sha256="ccf536620a45458d26ba83887a983b96827001e92a13847b45e4925cc8913178") version("1.14", sha256="72b24ded17d687193c3366d0ebe7cde1e6b18f0df8c55438ac95be39e8a30613") + depends_on("c", type="build") # generated + variant( "libs", default="shared,static", @@ -41,6 +43,17 @@ def configure_args(self): args += self.enable_or_disable("libs") args.append("--with-pic") + # Starting version 1.17, libiconv uses the version of gnulib that implements a + # configure-time check for C compiler flags that enables/disables certain warning + # (see https://git.savannah.gnu.org/gitweb/?p=gnulib.git;h=0c8a563f6). Unfortunately, the + # check does not work for compilers that inject extra symbols into the translation unit + # during the preprocessing step. For example, NVHPC injects the definition of the + # __va_list_tag structure, which appears verbatim on the compilation command line as + # additional compiler flags. The easiest way to circumvent the issue is to make the + # configure script believe that the compiler does not support a flag that allows warnings: + if self.spec.satisfies("@1.17:%nvhpc"): + args.append("gl_cv_cc_wallow=none") + # A hack to patch config.guess in the libcharset sub directory copy("./build-aux/config.guess", "libcharset/build-aux/config.guess") return args diff --git a/var/spack/repos/builtin/packages/libid3tag/package.py b/var/spack/repos/builtin/packages/libid3tag/package.py index 2d28ded9c643d4..1fa9721b6a4bd0 100644 --- a/var/spack/repos/builtin/packages/libid3tag/package.py +++ b/var/spack/repos/builtin/packages/libid3tag/package.py @@ -19,6 +19,8 @@ class Libid3tag(AutotoolsPackage): version("0.15.1b", sha256="63da4f6e7997278f8a3fef4c6a372d342f705051d1eeb6a46a86b03610e26151") + depends_on("c", type="build") # generated + depends_on("zlib-api") depends_on("gperf") diff --git a/var/spack/repos/builtin/packages/libidl/package.py b/var/spack/repos/builtin/packages/libidl/package.py index 5074329b40c405..5dc471aebdb63c 100644 --- a/var/spack/repos/builtin/packages/libidl/package.py +++ b/var/spack/repos/builtin/packages/libidl/package.py @@ -17,6 +17,8 @@ class Libidl(AutotoolsPackage): version("0.8.14", sha256="c5d24d8c096546353fbc7cedf208392d5a02afe9d56ebcc1cccb258d7c4d2220") + depends_on("c", type="build") # generated + depends_on("flex", type="build") depends_on("bison", type="build") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/libidn/package.py b/var/spack/repos/builtin/packages/libidn/package.py index c46f2078bd0153..275ecd5f4f124c 100644 --- a/var/spack/repos/builtin/packages/libidn/package.py +++ b/var/spack/repos/builtin/packages/libidn/package.py @@ -22,3 +22,5 @@ class Libidn(AutotoolsPackage, GNUMirrorPackage): version("1.38", sha256="de00b840f757cd3bb14dd9a20d5936473235ddcba06d4bc2da804654b8bbf0f6") version("1.34", sha256="3719e2975f2fb28605df3479c380af2cf4ab4e919e1506527e4c7670afff6e3c") version("1.28", sha256="dd357a968449abc97c7e5fa088a4a384de57cb36564f9d4e0d898ecc6373abfb") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libidn2/package.py b/var/spack/repos/builtin/packages/libidn2/package.py index f36da936ac75f6..c073712bd12512 100644 --- a/var/spack/repos/builtin/packages/libidn2/package.py +++ b/var/spack/repos/builtin/packages/libidn2/package.py @@ -17,6 +17,7 @@ class Libidn2(AutotoolsPackage, GNUMirrorPackage): license("GPL-2.0-or-later OR LGPL-3.0-or-later") + version("2.3.7", sha256="4c21a791b610b9519b9d0e12b8097bf2f359b12f8dd92647611a929e6bfd7d64") version("2.3.4", sha256="93caba72b4e051d1f8d4f5a076ab63c99b77faee019b72b9783b267986dbb45f") version("2.3.3", sha256="f3ac987522c00d33d44b323cae424e2cffcb4c63c6aa6cd1376edacbf1c36eb0") version("2.3.2", sha256="76940cd4e778e8093579a9d195b25fff5e936e9dc6242068528b437a76764f91") @@ -27,6 +28,8 @@ class Libidn2(AutotoolsPackage, GNUMirrorPackage): version("2.1.0", sha256="032398dbaa9537af43f51a8d94e967e3718848547b1b2a4eb3138b20cad11d32") version("2.0.5", sha256="53f69170886f1fa6fa5b332439c7a77a7d22626a82ef17e2c1224858bb4ca2b8") + depends_on("c", type="build") # generated + depends_on("libunistring") # in-source build fails diff --git a/var/spack/repos/builtin/packages/libimagequant/package.py b/var/spack/repos/builtin/packages/libimagequant/package.py index e4f22875f3b0cb..9c6a50553c335f 100644 --- a/var/spack/repos/builtin/packages/libimagequant/package.py +++ b/var/spack/repos/builtin/packages/libimagequant/package.py @@ -19,5 +19,7 @@ class Libimagequant(MakefilePackage): version("2.12.6", sha256="b34964512c0dbe550c5f1b394c246c42a988cd73b71a76c5838aa2b4a96e43a0") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): configure("--prefix=" + prefix) diff --git a/var/spack/repos/builtin/packages/libinih/package.py b/var/spack/repos/builtin/packages/libinih/package.py index 8ed231a4cce81b..95f8333219fbc7 100644 --- a/var/spack/repos/builtin/packages/libinih/package.py +++ b/var/spack/repos/builtin/packages/libinih/package.py @@ -16,3 +16,6 @@ class Libinih(MesonPackage): git = "https://github.com/benhoyt/inih.git" version("master", branch="master") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libint/package.py b/var/spack/repos/builtin/packages/libint/package.py index 2dd4cd97a8601f..cb5798b543beb1 100644 --- a/var/spack/repos/builtin/packages/libint/package.py +++ b/var/spack/repos/builtin/packages/libint/package.py @@ -33,6 +33,7 @@ class Libint(AutotoolsPackage): license("LGPL-3.0-only") + version("2.9.0", sha256="4929b2f2d3e53479270be052e366e8c70fa154a7f309e5c2c23b7d394159687d") version("2.6.0", sha256="4ae47e8f0b5632c3d2a956469a7920896708e9f0e396ec10071b8181e4c8d9fa") version("2.4.2", sha256="86dff38065e69a3a51d15cfdc638f766044cb87e5c6682d960c14f9847e2eac3") version("2.4.1", sha256="0513be124563fdbbc7cd3c7043e221df1bda236a037027ba9343429a27db8ce4") @@ -42,6 +43,10 @@ class Libint(AutotoolsPackage): version("1.1.6", sha256="f201b0c621df678cfe8bdf3990796b8976ff194aba357ae398f2f29b0e2985a6") version("1.1.5", sha256="ec8cd4a4ba1e1a98230165210c293632372f0e573acd878ed62e5ec6f8b6174b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("debug", default=False, description="Enable building with debug symbols") variant("fortran", default=False, description="Build & install Fortran bindings") variant( @@ -64,11 +69,16 @@ class Libint(AutotoolsPackage): depends_on("automake", type="build") depends_on("libtool", type="build") depends_on("python", type="build") + depends_on("cmake@3.19:", when="@2.6.0:", type="build") # Libint 2 dependencies # Fixme: Can maintainers please confirm that this is a required dependency depends_on(Boost.with_default_variants, when="@2:") depends_on("gmp+cxx", when="@2:") + depends_on("eigen", when="@2.7.0:") + # unicode variable names in @2.9.0: + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67224 + conflicts("%gcc@:9", when="@2.9.0:", msg="libint@2.9.0: requires at least gcc 10") for tvariant in TUNE_VARIANTS[1:]: conflicts( @@ -98,10 +108,6 @@ def autoreconf(self, spec, prefix): aclocal("-I", "lib/autoconf") autoconf() - if "@2.6.0:" in spec: - # skip tarball creation and removal of dir with generated code - filter_file(r"^(export::.*)\s+tgz$", r"\1", "export/Makefile") - @property def optflags(self): flags = "-O2" @@ -212,39 +218,59 @@ def build(self, spec, prefix): """ # upstream says that using configure/make for the generated code - # is deprecated and one should use CMake, but with the currently - # recent 2.7.0.b1 it still doesn't work - # first generate the libint compiler + # is deprecated and one should use CMake + + # skip tarball creation and removal of dir with generated code + filter_file("&& rm -rf $(EXPORTDIR)", "", "export/Makefile", string=True) + make("export") # now build the library with working_dir(os.path.join(self.build_directory, "generated")): - # straight from the AutotoolsPackage class: - config_args = [ - "--prefix={0}".format(prefix), - "--enable-shared", - "--with-boost={0}".format(self.spec["boost"].prefix), - "--with-cxx-optflags={0}".format(self.optflags), - ] - config_args += self.enable_or_disable("debug", activation_value=lambda x: "opt") - config_args += self.enable_or_disable("fortran") - - configure = Executable("./configure") - configure(*config_args) - make() + if spec.satisfies("@2.6.0"): + config_args = [ + f"--prefix={prefix}", + "--enable-shared", + f"--with-boost={spec['boost'].prefix}", + f"--with-cxx-optflags={self.optflags}", + ] + config_args += self.enable_or_disable("debug", activation_value=lambda x: "opt") + config_args += self.enable_or_disable("fortran") + configure = Executable("./configure") + configure(*config_args) + make() + else: + cmake_args = [ + "..", + f"-DCMAKE_INSTALL_PREFIX={prefix}", + "-DLIBINT2_BUILD_SHARED_AND_STATIC_LIBS=ON", + ] + if "+fortran" in spec: + cmake_args.append("-DENABLE_FORTRAN=ON") + if "+debug" in spec: + cmake_args.append("CMAKE_BUILD_TYPE=Debug") + cmake = Executable("cmake") + mkdirp("build") + with working_dir("build"): + cmake(*cmake_args) + make() @when("@2.6.0:") def check(self): - with working_dir(os.path.join(self.build_directory, "generated")): + path = join_path(self.build_directory, "generated") + if self.spec.satisfies("@2.9.0:"): + path = join_path(path, "build") + with working_dir(path): make("check") @when("@2.6.0:") def install(self, spec, prefix): - with working_dir(os.path.join(self.build_directory, "generated")): + path = join_path(self.build_directory, "generated") + if self.spec.satisfies("@2.9.0:"): + path = join_path(path, "build") + with working_dir(path): make("install") - if "+fortran" in self.spec: - mkdirp(prefix.include) - install(join_path("fortran", "*.mod"), prefix.include) + @when("@:2.6.0") def patch(self): # Use Fortran compiler to link the Fortran example, not the C++ # compiler @@ -256,3 +282,7 @@ def patch(self): "export/fortran/Makefile", string=True, ) + + @property + def libs(self): + return find_libraries("libint2", self.spec.prefix, shared=True, recursive=True) diff --git a/var/spack/repos/builtin/packages/libisal/package.py b/var/spack/repos/builtin/packages/libisal/package.py index e812129e6ee1a4..4da1110d88ac5c 100644 --- a/var/spack/repos/builtin/packages/libisal/package.py +++ b/var/spack/repos/builtin/packages/libisal/package.py @@ -15,8 +15,11 @@ class Libisal(AutotoolsPackage): license("BSD-3-Clause") + version("2.31.0", sha256="e218b7b2e241cfb8e8b68f54a6e5eed80968cc387c4b1af03708b54e9fb236f1") version("2.29.0", sha256="832d9747ef3f0c8c05d39e3d7fd6ee5299a844e1ee7382fc8c8b52a268f36eda") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libiscsi/package.py b/var/spack/repos/builtin/packages/libiscsi/package.py index 9fe50b24b9befe..e6c366d248d346 100644 --- a/var/spack/repos/builtin/packages/libiscsi/package.py +++ b/var/spack/repos/builtin/packages/libiscsi/package.py @@ -19,6 +19,8 @@ class Libiscsi(AutotoolsPackage): version("1.16.0", sha256="35c7be63a8c3a7cee7b697901b6d2dd464e098e1881671eb67462983053b3c7b") version("1.15.0", sha256="489e625e58c1e6da2fa3536f9c4b12290f2d3fb4ce14edc0583b8ba500605c34") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libjpeg-turbo/package.py b/var/spack/repos/builtin/packages/libjpeg-turbo/package.py index 968a8fc7c56a35..f5364a793c8b45 100644 --- a/var/spack/repos/builtin/packages/libjpeg-turbo/package.py +++ b/var/spack/repos/builtin/packages/libjpeg-turbo/package.py @@ -22,6 +22,9 @@ class LibjpegTurbo(CMakePackage, AutotoolsPackage): license("BSD-3-Clause AND IJG AND Zlib") + version("3.0.3", sha256="a649205a90e39a548863a3614a9576a3fb4465f8e8e66d54999f127957c25b21") + version("3.0.2", sha256="29f2197345aafe1dcaadc8b055e4cbec9f35aad2a318d61ea081f835af2eebe9") + version("3.0.1", sha256="5b9bbca2b2a87c6632c821799438d358e27004ab528abf798533c15d50b39f82") version("3.0.0", sha256="171dae5d73560bc94006a7c0c3281bd9bfde6a34f7e41e66f930a1a9162bd7df") version("2.1.5.1", sha256="61846251941e5791005fb7face196eec24541fce04f12570c308557529e92c75") version("2.1.5", sha256="254f3642b04e309fee775123133c6464181addc150499561020312ec61c1bf7c") @@ -52,6 +55,9 @@ class LibjpegTurbo(CMakePackage, AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + provides("jpeg") build_system( diff --git a/var/spack/repos/builtin/packages/libjpeg/package.py b/var/spack/repos/builtin/packages/libjpeg/package.py index 473d07437a1305..93f89b7149e245 100644 --- a/var/spack/repos/builtin/packages/libjpeg/package.py +++ b/var/spack/repos/builtin/packages/libjpeg/package.py @@ -23,6 +23,8 @@ class Libjpeg(AutotoolsPackage): version("9b", sha256="240fd398da741669bf3c90366f58452ea59041cacc741a489b99f2f6a0bad052") version("9a", sha256="3a753ea48d917945dd54a2d97de388aa06ca2eb1066cbfdc6652036349fe05a7") + depends_on("c", type="build") # generated + provides("jpeg") def check(self): diff --git a/var/spack/repos/builtin/packages/libjson/package.py b/var/spack/repos/builtin/packages/libjson/package.py index e2f393bab09895..d7cd514f7e2805 100644 --- a/var/spack/repos/builtin/packages/libjson/package.py +++ b/var/spack/repos/builtin/packages/libjson/package.py @@ -20,6 +20,8 @@ class Libjson(MakefilePackage): version("0.5", sha256="d19e149118c01c4a1f4cd16be3ce54bfc97a7210b6f0d76a3f8ef75bf70e8acd") version("0.4", sha256="9b3ebbeb1940dbd8664524d27e66d991fedc00cca9f403f9aa9c2f28104ca81b") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): filter_file("-o root -g root", "", "Makefile") diff --git a/var/spack/repos/builtin/packages/libjwt/package.py b/var/spack/repos/builtin/packages/libjwt/package.py index ae372d3c4de5cc..9037fa72cf2093 100644 --- a/var/spack/repos/builtin/packages/libjwt/package.py +++ b/var/spack/repos/builtin/packages/libjwt/package.py @@ -23,6 +23,8 @@ class Libjwt(AutotoolsPackage): version("1.12.1", sha256="d29e4250d437340b076350e910e69fd5539ef8b92528d0306745cec0e343cc17") version("1.12.0", sha256="eaf5d8b31d867c02dde767efa2cf494840885a415a3c9a62680bf870a4511bee") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libjxl/package.py b/var/spack/repos/builtin/packages/libjxl/package.py index e4828c90a09333..68fd6d65d0dabe 100644 --- a/var/spack/repos/builtin/packages/libjxl/package.py +++ b/var/spack/repos/builtin/packages/libjxl/package.py @@ -16,6 +16,9 @@ class Libjxl(CMakePackage): license("Apache-2.0") version("main", branch="main", submodules=True) + version( + "0.10.2", tag="v0.10.2", commit="e1489592a770b989303b0edc5cc1dc447bbe0515", submodules=True + ) version( "0.7.0", tag="v0.7.0", commit="f95da131cf7c7ccd4da256356fde2fec1fa23bb5", submodules=True ) @@ -23,6 +26,9 @@ class Libjxl(CMakePackage): "0.6.1", tag="v0.6.1", commit="a205468bc5d3a353fb15dae2398a101dff52f2d3", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.10:", type="build") depends_on("brotli") depends_on("highway") @@ -40,6 +46,7 @@ def cmake_args(self): args = [ self.define("JPEGXL_FORCE_SYSTEM_BROTLI", True), self.define("JPEGXL_FORCE_SYSTEM_HWY", True), + self.define("BUILD_TESTING", self.run_tests), ] if self.run_tests: diff --git a/var/spack/repos/builtin/packages/libkcapi/package.py b/var/spack/repos/builtin/packages/libkcapi/package.py index 282c8395415ab6..5f9dfd29d5018c 100644 --- a/var/spack/repos/builtin/packages/libkcapi/package.py +++ b/var/spack/repos/builtin/packages/libkcapi/package.py @@ -19,6 +19,8 @@ class Libkcapi(AutotoolsPackage): version("1.1.5", sha256="ca38bf4d750dd2d3531ddb94d502feedb0f926bd9b29fb97e253b83bbceb6611") version("1.1.4", sha256="241ffa4f2813c6da442b1c1e152d489905ffab35a6c50e76aca5ee6fe60319dd") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libkml/package.py b/var/spack/repos/builtin/packages/libkml/package.py index 69f98eea8219c5..4f53a24f7d15e0 100644 --- a/var/spack/repos/builtin/packages/libkml/package.py +++ b/var/spack/repos/builtin/packages/libkml/package.py @@ -20,6 +20,9 @@ class Libkml(CMakePackage): version("1.3.0", sha256="8892439e5570091965aaffe30b08631fdf7ca7f81f6495b4648f0950d7ea7963") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("java", default=False, description="Build java bindings") variant("python", default=False, description="Build python bindings") diff --git a/var/spack/repos/builtin/packages/libksba/package.py b/var/spack/repos/builtin/packages/libksba/package.py index 1543167d398573..65bc644241d25c 100644 --- a/var/spack/repos/builtin/packages/libksba/package.py +++ b/var/spack/repos/builtin/packages/libksba/package.py @@ -17,10 +17,14 @@ class Libksba(AutotoolsPackage): license("LGPL-3.0-only AND GPL-2.0-only AND GPL-3.0-only") + version("1.6.7", sha256="cf72510b8ebb4eb6693eef765749d83677a03c79291a311040a5bfd79baab763") version("1.6.6", sha256="5dec033d211559338838c0c4957c73dfdc3ee86f73977d6279640c9cd08ce6a4") version("1.6.5", sha256="a564628c574c99287998753f98d750babd91a4e9db451f46ad140466ef2a6d16") version("1.6.4", sha256="bbb43f032b9164d86c781ffe42213a83bf4f2fee91455edfa4654521b8b03b6b") version("1.6.3", sha256="3f72c68db30971ebbf14367527719423f0a4d5f8103fc9f4a1c01a9fa440de5c") + + depends_on("c", type="build") # generated + # Versions before 1.6.3 were deprecated over CVE-2022-3515 # (https://gnupg.org/blog/20221017-pepe-left-the-ksba.html) diff --git a/var/spack/repos/builtin/packages/liblas/package.py b/var/spack/repos/builtin/packages/liblas/package.py index de77219900dca2..4c85e04cf90570 100644 --- a/var/spack/repos/builtin/packages/liblas/package.py +++ b/var/spack/repos/builtin/packages/liblas/package.py @@ -18,6 +18,9 @@ class Liblas(CMakePackage): version("1.8.1", sha256="9adb4a98c63b461ed2bc82e214ae522cbd809cff578f28511122efe6c7ea4e76") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # libLAS linkage of GDAL and libgeotiff enhances spatial coordinate system # description and provides data reprojection support. # Ref.: https://liblas.org/compilation.html#optional-libraries diff --git a/var/spack/repos/builtin/packages/liblbxutil/package.py b/var/spack/repos/builtin/packages/liblbxutil/package.py index 8a8e47cbbb131c..f69cb5b6b468d0 100644 --- a/var/spack/repos/builtin/packages/liblbxutil/package.py +++ b/var/spack/repos/builtin/packages/liblbxutil/package.py @@ -16,6 +16,8 @@ class Liblbxutil(AutotoolsPackage, XorgPackage): version("1.1.0", sha256="285c1bc688cc71ec089e9284f2566d1780cc5d90816e9997890af8689f386951") + depends_on("c", type="build") # generated + depends_on("xextproto@7.0.99.1:") depends_on("xproto") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/liblockfile/package.py b/var/spack/repos/builtin/packages/liblockfile/package.py index 91a9f04209b47d..9dce85e240df3f 100644 --- a/var/spack/repos/builtin/packages/liblockfile/package.py +++ b/var/spack/repos/builtin/packages/liblockfile/package.py @@ -16,6 +16,8 @@ class Liblockfile(AutotoolsPackage): version("1.14", sha256="be85dba347889d9b65cbd361a611e6b88e044fdca9c98e5139d5fbc9ba37ccc8") + depends_on("c", type="build") # generated + patch("install_as_nonroot.patch") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/liblognorm/package.py b/var/spack/repos/builtin/packages/liblognorm/package.py index 1512db8232adda..d8ff0853022904 100644 --- a/var/spack/repos/builtin/packages/liblognorm/package.py +++ b/var/spack/repos/builtin/packages/liblognorm/package.py @@ -20,6 +20,8 @@ class Liblognorm(AutotoolsPackage): version("2.0.3", sha256="fac2a6a5adbeb63d06a63ab2e398b3fac8625d0ea69db68f1d81196897a9d687") version("2.0.2", sha256="bdd08e9837e8fcca5029ec12c9fb9f16593313f9d743625bab062250e0daa5d8") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/liblouis/package.py b/var/spack/repos/builtin/packages/liblouis/package.py index d8428ca73aad52..730ea4ed6072f0 100644 --- a/var/spack/repos/builtin/packages/liblouis/package.py +++ b/var/spack/repos/builtin/packages/liblouis/package.py @@ -22,3 +22,5 @@ class Liblouis(AutotoolsPackage): version("3.13.0", sha256="2803b89a2bff9f02032125fa7b7d0a204a60d8d14f232242344b5f09535e9a01") version("3.12.0", sha256="87d9bad6d75916270bad14bb22fa5f487c7edee4774878c04bef82833bc9467d") version("3.11.0", sha256="b802aba0bff49636907ca748225e21c56ecf3f3ebc143d582430036d4d9f6259") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libluv/package.py b/var/spack/repos/builtin/packages/libluv/package.py index 88d61036bd226e..3f64589c2d5f45 100644 --- a/var/spack/repos/builtin/packages/libluv/package.py +++ b/var/spack/repos/builtin/packages/libluv/package.py @@ -25,6 +25,8 @@ class Libluv(CMakePackage): version("1.42.0-0", sha256="b5228a9d0eaacd9f862b6270c732d5c90773a28ce53b6d9e32a14050e7947f36") version("1.36.0-0", sha256="f2e7eb372574f25c6978c1dc74280d22efdcd7df2dda4a286c7fe7dceda26445") + depends_on("c", type="build") # generated + # https://github.com/neovim/neovim/issues/25770 # up to 1.45 (included) dynamic library on macOS did not have the @rpath prefix, being not # usable on this platform. diff --git a/var/spack/repos/builtin/packages/liblzf/package.py b/var/spack/repos/builtin/packages/liblzf/package.py index 91c60937e09d07..2e93bca660b62b 100644 --- a/var/spack/repos/builtin/packages/liblzf/package.py +++ b/var/spack/repos/builtin/packages/liblzf/package.py @@ -19,3 +19,5 @@ class Liblzf(AutotoolsPackage): license("BSD-2-Clause") version("3.6", sha256="9c5de01f7b9ccae40c3f619d26a7abec9986c06c36d260c179cedd04b89fb46a") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libmacaroons/package.py b/var/spack/repos/builtin/packages/libmacaroons/package.py index 37d433f852b9c2..4278f575d2323b 100644 --- a/var/spack/repos/builtin/packages/libmacaroons/package.py +++ b/var/spack/repos/builtin/packages/libmacaroons/package.py @@ -20,6 +20,8 @@ class Libmacaroons(AutotoolsPackage): version("0.2.0", sha256="fa2146d89a4e844703896ece778f0c42b2b0ee3d09dea350ff34fd6873e72018") version("0.1.0", sha256="0aa413d8a793f004874695466f93eed9c8e721524765704fe410694583928007") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libmad/package.py b/var/spack/repos/builtin/packages/libmad/package.py index 3d221d03ed3922..c064efd796306a 100644 --- a/var/spack/repos/builtin/packages/libmad/package.py +++ b/var/spack/repos/builtin/packages/libmad/package.py @@ -17,6 +17,8 @@ class Libmad(AutotoolsPackage): version("0.15.1b", sha256="bbfac3ed6bfbc2823d3775ebb931087371e142bb0e9bb1bee51a76a6e0078690") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libmatheval/package.py b/var/spack/repos/builtin/packages/libmatheval/package.py index abdd74882c28b9..d41a1ccda67422 100644 --- a/var/spack/repos/builtin/packages/libmatheval/package.py +++ b/var/spack/repos/builtin/packages/libmatheval/package.py @@ -21,6 +21,8 @@ class Libmatheval(AutotoolsPackage, GNUMirrorPackage): version("1.1.11", sha256="474852d6715ddc3b6969e28de5e1a5fbaff9e8ece6aebb9dc1cc63e9e88e89ab") + depends_on("c", type="build") # generated + # Only needed for unit tests, but configure crashes without it depends_on("guile", type="build") diff --git a/var/spack/repos/builtin/packages/libmaus2/package.py b/var/spack/repos/builtin/packages/libmaus2/package.py index fe4c0528f83b99..49f143c7578fb5 100644 --- a/var/spack/repos/builtin/packages/libmaus2/package.py +++ b/var/spack/repos/builtin/packages/libmaus2/package.py @@ -18,6 +18,9 @@ class Libmaus2(AutotoolsPackage): url="https://gitlab.com/german.tischler/libmaus2/-/archive/2.0.767-release-20201123131410/libmaus2-2.0.767-release-20201123131410.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libmaxminddb/package.py b/var/spack/repos/builtin/packages/libmaxminddb/package.py index 6564f340724e44..eb36bf98c3cd50 100644 --- a/var/spack/repos/builtin/packages/libmaxminddb/package.py +++ b/var/spack/repos/builtin/packages/libmaxminddb/package.py @@ -20,6 +20,8 @@ class Libmaxminddb(AutotoolsPackage): version("1.7.1", sha256="e8414f0dedcecbc1f6c31cb65cd81650952ab0677a4d8c49cab603b3b8fb083e") version("1.3.2", sha256="e6f881aa6bd8cfa154a44d965450620df1f714c6dc9dd9971ad98f6e04f6c0f0") + depends_on("c", type="build") # generated + def configure_args(self): args = ["--disable-debug", "--disable-dependency-tracking", "--disable-silent-rules"] return args diff --git a/var/spack/repos/builtin/packages/libmbim/package.py b/var/spack/repos/builtin/packages/libmbim/package.py index 6f86673daf61c8..5cae06c702e273 100644 --- a/var/spack/repos/builtin/packages/libmbim/package.py +++ b/var/spack/repos/builtin/packages/libmbim/package.py @@ -23,6 +23,8 @@ class Libmbim(AutotoolsPackage): version("1.14.4", sha256="4b2e8723ea50b2e1d22695850c40abb9f7bcb713ea3b9f91f2c350aaa6ae8d1c") version("1.14.2", sha256="bf161c4f78327f8422fd6a820e7e5571d99b719af45429e581bfd6a1585fe4a8") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libmcrypt/package.py b/var/spack/repos/builtin/packages/libmcrypt/package.py index 013c2a55ea7c75..771195a5c061be 100644 --- a/var/spack/repos/builtin/packages/libmcrypt/package.py +++ b/var/spack/repos/builtin/packages/libmcrypt/package.py @@ -17,3 +17,5 @@ class Libmcrypt(AutotoolsPackage): license("LGPL-2.1-or-later") version("2.5.8", sha256="e4eb6c074bbab168ac47b947c195ff8cef9d51a211cdd18ca9c9ef34d27a373e") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libmd/package.py b/var/spack/repos/builtin/packages/libmd/package.py index 6d813bfed4f897..c5de7e7c149731 100644 --- a/var/spack/repos/builtin/packages/libmd/package.py +++ b/var/spack/repos/builtin/packages/libmd/package.py @@ -22,5 +22,7 @@ class Libmd(AutotoolsPackage): version("1.0.1", sha256="e14eeb931cf85330f95ff822262d3033125488dfb2f867441e36e2d2c4a34c71") version("1.0.0", sha256="f21aea69f6411cb4307cda1f6378c7ed07830202b5f4cb9e64f681fdaf2d64c7") + depends_on("c", type="build") # generated + # Use wrapper functions instead of __attribute__ __alias__ patch("nvhpc-aliases.patch", when="%nvhpc") diff --git a/var/spack/repos/builtin/packages/libmesh/package.py b/var/spack/repos/builtin/packages/libmesh/package.py index 6f262646144c67..f7e1980d2da8fd 100644 --- a/var/spack/repos/builtin/packages/libmesh/package.py +++ b/var/spack/repos/builtin/packages/libmesh/package.py @@ -20,6 +20,7 @@ class Libmesh(AutotoolsPackage): version("master", branch="master", submodules=True) + version("1.7.1", sha256="0387d62773cf92356eb128ba92f767e56c298d78f4b97446e68bf288da1eb6b4") version("1.4.1", sha256="67eb7d5a9c954d891ca1386b70f138333a87a141d9c44213449ca6be69a66414") version("1.4.0", sha256="62d7fce89096c950d1b38908484856ea63df57754b64cde6582e7ac407c8c81d") version("1.3.1", sha256="638cf30d05c249315760f16cbae4804964db8857a04d5e640f37617bef17ab0f") @@ -119,6 +120,7 @@ class Libmesh(AutotoolsPackage): values=("none", "pthreads", "tbb", "openmp"), multi=False, ) + variant("shared", default=True, description="Enables the build of shared libraries") conflicts( "+metaphysicl", @@ -140,8 +142,8 @@ class Libmesh(AutotoolsPackage): depends_on("mpi", when="+slepc") # compilation dependencies depend on perl depends_on("perl") - depends_on("petsc+mpi", when="+mpi") - depends_on("petsc+metis", when="+metis") + depends_on("petsc+mpi", when="+petsc+mpi") + depends_on("petsc+metis", when="+petsc+metis") depends_on("slepc", when="+slepc") depends_on("petsc", when="+petsc") depends_on("tbb", when="threads=tbb") @@ -150,6 +152,11 @@ class Libmesh(AutotoolsPackage): def configure_args(self): options = [] + if "+shared" in self.spec: + options.extend(["--enable-shared", "--disable-static"]) + else: + options.extend(["--disable-shared", "--enable-static"]) + # GLIBCXX debugging is not, by default, supported by other libraries, # so unconditionally disable it for libmesh options.append("--enable-glibcxx-debugging=no") diff --git a/var/spack/repos/builtin/packages/libmetalink/package.py b/var/spack/repos/builtin/packages/libmetalink/package.py index b4465b86aa694c..fb7cca52c1f49c 100644 --- a/var/spack/repos/builtin/packages/libmetalink/package.py +++ b/var/spack/repos/builtin/packages/libmetalink/package.py @@ -20,6 +20,8 @@ class Libmetalink(AutotoolsPackage): version("0.1.2", sha256="64af0979c11658f7a1659ca97ebc3c7bac8104253bf504015ac3b9c363382bae") version("0.1.1", sha256="e9b8dff68b0b999884c21f68d9b1cc0c1993270e3e1f639f82e27b1eb960cb66") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libmicrodns/package.py b/var/spack/repos/builtin/packages/libmicrodns/package.py index 6a48c55266e4d1..cde841d6fbd4e5 100644 --- a/var/spack/repos/builtin/packages/libmicrodns/package.py +++ b/var/spack/repos/builtin/packages/libmicrodns/package.py @@ -17,3 +17,5 @@ class Libmicrodns(MesonPackage): version("0.2.0", sha256="2da28e7dda4861d76f797f92ac3e6c3e048333b95f9e4fc3a6548ad8afd8c446") version("0.1.2", sha256="666c4b9d86b5b3c37357bb78453c7e8b72cd65ade22d0a7963bfbefe51509b5c") version("0.1.1", sha256="498c81fd07718f449267a207948536cbb527610942d91999488eaea6de301c52") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libmicrohttpd/package.py b/var/spack/repos/builtin/packages/libmicrohttpd/package.py index fc9b25ba00554d..e39b9acf719cc2 100644 --- a/var/spack/repos/builtin/packages/libmicrohttpd/package.py +++ b/var/spack/repos/builtin/packages/libmicrohttpd/package.py @@ -27,6 +27,8 @@ class Libmicrohttpd(AutotoolsPackage): version("0.9.70", sha256="90d0a3d396f96f9bc41eb0f7e8187796049285fabef82604acd4879590977307") version("0.9.50", sha256="d1b6385068abded29b6470e383287aa7705de05ae3c08ad0bf5747ac4dc6ebd7") + depends_on("c", type="build") # generated + variant("https", default=False, description="HTTPS support with GnuTLS") depends_on("gettext") diff --git a/var/spack/repos/builtin/packages/libmmtf-cpp/package.py b/var/spack/repos/builtin/packages/libmmtf-cpp/package.py index 5109f7623bd649..66b172b9ef3c25 100644 --- a/var/spack/repos/builtin/packages/libmmtf-cpp/package.py +++ b/var/spack/repos/builtin/packages/libmmtf-cpp/package.py @@ -17,4 +17,6 @@ class LibmmtfCpp(CMakePackage): version("1.1.0", sha256="021173bdc1814b1d0541c4426277d39df2b629af53151999b137e015418f76c0") version("1.0.0", sha256="881f69c4bb56605fa63fd5ca50842facc4947f686cbf678ad04930674d714f40") + depends_on("cxx", type="build") # generated + depends_on("msgpack-c") diff --git a/var/spack/repos/builtin/packages/libmng/package.py b/var/spack/repos/builtin/packages/libmng/package.py index db1b8c35474bdd..37a7f5bafc5fcb 100644 --- a/var/spack/repos/builtin/packages/libmng/package.py +++ b/var/spack/repos/builtin/packages/libmng/package.py @@ -19,6 +19,9 @@ class Libmng(CMakePackage): version("2.0.3", sha256="cf112a1fb02f5b1c0fce5cab11ea8243852c139e669c44014125874b14b7dfaa") version("2.0.2", sha256="4908797bb3541fb5cd8fffbe0b1513ed163509f2a4d57a78b26a96f8d1dd05a2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("jpeg") depends_on("zlib-api") depends_on("lcms") diff --git a/var/spack/repos/builtin/packages/libmo-unpack/package.py b/var/spack/repos/builtin/packages/libmo-unpack/package.py index 6f7daacbe7d64a..0e89865830b4c8 100644 --- a/var/spack/repos/builtin/packages/libmo-unpack/package.py +++ b/var/spack/repos/builtin/packages/libmo-unpack/package.py @@ -17,4 +17,6 @@ class LibmoUnpack(CMakePackage): version("3.1.2", sha256="e09ef3e6f1075144acc5d6466b4ef70b2fe32ed4ab1840dd4fb7e15a40f3d370") + depends_on("c", type="build") # generated + depends_on("check") diff --git a/var/spack/repos/builtin/packages/libmodbus/package.py b/var/spack/repos/builtin/packages/libmodbus/package.py index e27e0aafa276ee..1c20d6ff83378e 100644 --- a/var/spack/repos/builtin/packages/libmodbus/package.py +++ b/var/spack/repos/builtin/packages/libmodbus/package.py @@ -26,3 +26,5 @@ class Libmodbus(AutotoolsPackage): version("3.0.7", sha256="6c26850cd5dedcf5dad40977ac7f2ee990a3667f6959a1e05e22959bdf537961") version("3.0.6", sha256="046d63f10f755e2160dc56ef681e5f5ad3862a57c1955fd82e0ce036b69471b6") version("3.0.5", sha256="19aad5d55fa315602d6e836a858a3802f1608f9d824afba05fa12a58a1b1e656") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libmolgrid/package.py b/var/spack/repos/builtin/packages/libmolgrid/package.py index 86bb4e7e0db606..a8e423f8c6dbb3 100644 --- a/var/spack/repos/builtin/packages/libmolgrid/package.py +++ b/var/spack/repos/builtin/packages/libmolgrid/package.py @@ -22,6 +22,8 @@ class Libmolgrid(CMakePackage): version("0.5.3", sha256="a9f7a62cdeb516bc62a06b324cdd33b095a787df175c6166d74a8d30b6916abb") version("0.5.2", sha256="e732d13a96c2f374d57a73999119bef700172d392c195c751214aa6ac6680c3a") + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("boost +regex +test +program_options +system +filesystem +iostreams +python") depends_on("openbabel@3:~gui~cairo") diff --git a/var/spack/repos/builtin/packages/libmonitor/package.py b/var/spack/repos/builtin/packages/libmonitor/package.py index 3eb4ca6060bcf5..58afd8126eb577 100644 --- a/var/spack/repos/builtin/packages/libmonitor/package.py +++ b/var/spack/repos/builtin/packages/libmonitor/package.py @@ -28,6 +28,8 @@ class Libmonitor(AutotoolsPackage): version("2018.07.18", commit="d28cc1d3c08c02013a68a022a57a6ac73db88166") version("2013.02.18", commit="4f2311e413fd90583263d6f20453bbe552ccfef3") + depends_on("c", type="build") # generated + # Configure for Rice HPCToolkit. variant("hpctoolkit", default=False, description="Configure for HPCToolkit") diff --git a/var/spack/repos/builtin/packages/libmpdclient/package.py b/var/spack/repos/builtin/packages/libmpdclient/package.py index 6182050e945f31..8e550c5de77646 100644 --- a/var/spack/repos/builtin/packages/libmpdclient/package.py +++ b/var/spack/repos/builtin/packages/libmpdclient/package.py @@ -20,3 +20,5 @@ class Libmpdclient(MesonPackage): version("2.17", sha256="06eb4b67c63f64d647e97257ff5f8506bf9c2a26b314bf5d0dd5944995b59fc9") version("2.16", sha256="6651898489b69d2f2f8e94f0ed6ddcc0dd2cdbcf99b02131b790551922558d6c") version("2.15", sha256="dd3d36801e397bf43719a291289ff610af71859c08f3196a506e4b1af43c290c") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libmypaint/package.py b/var/spack/repos/builtin/packages/libmypaint/package.py index 4714394c715a48..a457f1f80f914b 100644 --- a/var/spack/repos/builtin/packages/libmypaint/package.py +++ b/var/spack/repos/builtin/packages/libmypaint/package.py @@ -24,6 +24,8 @@ class Libmypaint(AutotoolsPackage): version("1.4.0", sha256="59d13b14c6aca0497095f29ee7228ca2499a923ba8e1dd718a2f2ecb45a9cbff") version("1.3.0", sha256="6a07d9d57fea60f68d218a953ce91b168975a003db24de6ac01ad69dcc94a671") + depends_on("c", type="build") # generated + variant("gegl", default=False, description="Enable GEGL based code in build") variant("introspection", default=True, description="Enable introspection for this build") diff --git a/var/spack/repos/builtin/packages/libnbc/package.py b/var/spack/repos/builtin/packages/libnbc/package.py index 7507ff362e7762..4174487e4989ff 100644 --- a/var/spack/repos/builtin/packages/libnbc/package.py +++ b/var/spack/repos/builtin/packages/libnbc/package.py @@ -20,4 +20,6 @@ class Libnbc(AutotoolsPackage): version("1.1.1", sha256="63aa5f75f84c191da0688cb551ebd0e9e46928edfba350b2a534eb0c704dd9c3") + depends_on("c", type="build") # generated + depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/libndp/package.py b/var/spack/repos/builtin/packages/libndp/package.py index 242f447b3fb253..1012974f20b8f4 100644 --- a/var/spack/repos/builtin/packages/libndp/package.py +++ b/var/spack/repos/builtin/packages/libndp/package.py @@ -20,6 +20,8 @@ class Libndp(AutotoolsPackage): version("1.4", sha256="b9b23d14e9b2d87745810d9d0e956e9fb45f44e794b1629492850c5a8fbbb083") version("1.3", sha256="e933dc1b9ce85089de8ba0f6ba4c3ec47eba0e9a404e14c1789a6fa9e23793f6") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libnet/package.py b/var/spack/repos/builtin/packages/libnet/package.py index 99a3d4c3db7320..44df3a759b2e1f 100644 --- a/var/spack/repos/builtin/packages/libnet/package.py +++ b/var/spack/repos/builtin/packages/libnet/package.py @@ -16,8 +16,11 @@ class Libnet(AutotoolsPackage): license("BSD-2-Clause") + version("1.3", sha256="44e28a4e5a9256ce74d96fd1ad8ac2e3f300f55dc70c93bb81851183a21d7d3a") version("1.2", sha256="b7a371a337d242c017f3471d70bea2963596bec5bd3bd0e33e8517550e2311ef") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libnetfilter-conntrack/package.py b/var/spack/repos/builtin/packages/libnetfilter-conntrack/package.py index fcbc19b9029614..40d793feb422bc 100644 --- a/var/spack/repos/builtin/packages/libnetfilter-conntrack/package.py +++ b/var/spack/repos/builtin/packages/libnetfilter-conntrack/package.py @@ -19,6 +19,8 @@ class LibnetfilterConntrack(AutotoolsPackage): version("1.0.3", sha256="e2129d7c0346c7140355d643da8e3409cbd755689ea889bc0d6dbd557f1b5671") version("1.0.2", sha256="97f641a2e47053bd87bc817292519d6661e8f84a22d3314724b83b9f5eaddbff") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libnetfilter-cthelper/package.py b/var/spack/repos/builtin/packages/libnetfilter-cthelper/package.py index cd99be3b0d0e15..bc30d4713596e2 100644 --- a/var/spack/repos/builtin/packages/libnetfilter-cthelper/package.py +++ b/var/spack/repos/builtin/packages/libnetfilter-cthelper/package.py @@ -18,6 +18,8 @@ class LibnetfilterCthelper(AutotoolsPackage): "1.2-2019Q4", sha256="15a7b13999d1428d75e720c8116318cd51bec1d365852ae1778d3c85b93a9777" ) + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libnetfilter-cttimeout/package.py b/var/spack/repos/builtin/packages/libnetfilter-cttimeout/package.py index b16dddd76c6bca..37f40239bd0862 100644 --- a/var/spack/repos/builtin/packages/libnetfilter-cttimeout/package.py +++ b/var/spack/repos/builtin/packages/libnetfilter-cttimeout/package.py @@ -18,6 +18,8 @@ class LibnetfilterCttimeout(AutotoolsPackage): "1.2-2019Q4", sha256="71cebdf07a578901b160a54199062a4b4cd445e14742e2c7badc0900d8ae56b6" ) + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libnetfilter-queue/package.py b/var/spack/repos/builtin/packages/libnetfilter-queue/package.py index e1ab35dab31f62..bc0e5710e3ef0b 100644 --- a/var/spack/repos/builtin/packages/libnetfilter-queue/package.py +++ b/var/spack/repos/builtin/packages/libnetfilter-queue/package.py @@ -18,6 +18,8 @@ class LibnetfilterQueue(AutotoolsPackage): "1.2-2019Q4", sha256="73b87e600b492cf9e3aa8fb6e9855e1ccc523a7bc466c1fd1a0e6ffa424d746e" ) + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libnetworkit/package.py b/var/spack/repos/builtin/packages/libnetworkit/package.py index 2ef31c7413fa72..5c3cd1a1a5bde8 100644 --- a/var/spack/repos/builtin/packages/libnetworkit/package.py +++ b/var/spack/repos/builtin/packages/libnetworkit/package.py @@ -31,6 +31,8 @@ class Libnetworkit(CMakePackage): version("7.0", sha256="4faf16c5fae3e14d3c1b6f30e25c6e093dcf6a3dbf021235f3161ac2a527f682") version("6.1", sha256="22c953ea1054c356663b31c77114c2f0c8fec17e0e707aeec23026241beab9b2") + depends_on("cxx", type="build") # generated + variant("static", default=False, description="Enables the build of shared libraries") variant("doc", default=False, description="Enables the build with sphinx documentation") diff --git a/var/spack/repos/builtin/packages/libnfnetlink/package.py b/var/spack/repos/builtin/packages/libnfnetlink/package.py index 041a15e1ca2906..4831211c77003e 100644 --- a/var/spack/repos/builtin/packages/libnfnetlink/package.py +++ b/var/spack/repos/builtin/packages/libnfnetlink/package.py @@ -21,6 +21,8 @@ class Libnfnetlink(AutotoolsPackage): version("1.0.0", sha256="1d43456e51d5ff2e8bc84b68d8acad3bb15603cfaa806ba9693eea4f2aa1abeb") version("0.0.41", sha256="84381ad3aec4fc4884c020c7774a241160d92ed50c9f93a2660db94e212cbb72") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libnfs/package.py b/var/spack/repos/builtin/packages/libnfs/package.py index bfbced8b343cd7..e98c70902754fc 100644 --- a/var/spack/repos/builtin/packages/libnfs/package.py +++ b/var/spack/repos/builtin/packages/libnfs/package.py @@ -19,3 +19,5 @@ class Libnfs(CMakePackage): version("2.0.0", sha256="7ea6cd8fa6c461d01091e584d424d28e137d23ff4b65b95d01a3fd0ef95d120e") version("1.11.0", sha256="fc2e45df14d8714ccd07dc2bbe919e45a2e36318bae7f045cbbb883a7854640f") version("1.10.0", sha256="7f6c62a05c7e0f0749f2b13f178a4ed7aaf17bd09e65a10bb147bfe9807da272") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libnfsidmap/package.py b/var/spack/repos/builtin/packages/libnfsidmap/package.py index 5643540c9511d7..0895b3c1c6623e 100644 --- a/var/spack/repos/builtin/packages/libnfsidmap/package.py +++ b/var/spack/repos/builtin/packages/libnfsidmap/package.py @@ -15,6 +15,8 @@ class Libnfsidmap(AutotoolsPackage): version("0-26", sha256="8c6d62285b528d673fcb8908fbe230ae82287b292d90925d014c6f367e8425ef") version("0-25", sha256="dbf844a2aa820d7275eca55c2e392d12453ab4020d37d532ea6beac47efc4725") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libnftnl/package.py b/var/spack/repos/builtin/packages/libnftnl/package.py index 35494bc2830995..b3ad7b0531854d 100644 --- a/var/spack/repos/builtin/packages/libnftnl/package.py +++ b/var/spack/repos/builtin/packages/libnftnl/package.py @@ -19,5 +19,7 @@ class Libnftnl(AutotoolsPackage): version("1.1.5", sha256="66de4d05227c0a1a731c369b193010d18a05b1185c2735211e0ecf658eeb14f3") version("1.1.4", sha256="c8c7988347adf261efac5bba59f8e5f995ffb65f247a88cc144e69620573ed20") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("libmnl@1.0.3:") diff --git a/var/spack/repos/builtin/packages/libnids/package.py b/var/spack/repos/builtin/packages/libnids/package.py index 9d8d2968bc26ef..8711e4de94a4b6 100644 --- a/var/spack/repos/builtin/packages/libnids/package.py +++ b/var/spack/repos/builtin/packages/libnids/package.py @@ -18,8 +18,11 @@ class Libnids(AutotoolsPackage): license("GPL-2.0-only") version("master", branch="master") + version("1.26", sha256="3f3e9f99a83cd37bc74af83d415c5e3a7505f5b190dfaf456b0849e0054f6733") version("1.25", sha256="47aa634bd0cdad81e092fac3aef6f12ee346c2f536a1eff4d3d5dacdb6dfcec1") + depends_on("c", type="build") # generated + depends_on("libpcap") depends_on("libnet") depends_on("glib@2.2.0:") diff --git a/var/spack/repos/builtin/packages/libnl/package.py b/var/spack/repos/builtin/packages/libnl/package.py index 7212ff3f08fb1e..656a2cd3612484 100644 --- a/var/spack/repos/builtin/packages/libnl/package.py +++ b/var/spack/repos/builtin/packages/libnl/package.py @@ -17,6 +17,8 @@ class Libnl(AutotoolsPackage): version("3.3.0", sha256="705468b5ae4cd1eb099d2d1c476d6a3abe519bc2810becf12fb1e32de1e074e4") + depends_on("c", type="build") # generated + depends_on("bison", type="build") depends_on("flex", type="build") depends_on("m4", type="build") diff --git a/var/spack/repos/builtin/packages/libnotify/package.py b/var/spack/repos/builtin/packages/libnotify/package.py index 4fab7677f669ab..eb96b1dda8c2b4 100644 --- a/var/spack/repos/builtin/packages/libnotify/package.py +++ b/var/spack/repos/builtin/packages/libnotify/package.py @@ -16,6 +16,8 @@ class Libnotify(MesonPackage): version("0.7.9", sha256="9bd4f5fa911d27567e7cc2d2d09d69356c16703c4e8d22c0b49a5c45651f3af0") + depends_on("c", type="build") # generated + # Libnotify is having trouble with finding the DTD and XSLT for docbook, # which is required for both of these varients. # variant('docbook', default=False, diff --git a/var/spack/repos/builtin/packages/libnova/package.py b/var/spack/repos/builtin/packages/libnova/package.py index 471be31eff65e3..7e5c381afbb716 100644 --- a/var/spack/repos/builtin/packages/libnova/package.py +++ b/var/spack/repos/builtin/packages/libnova/package.py @@ -17,6 +17,8 @@ class Libnova(AutotoolsPackage): version("0.15.0", sha256="7c5aa33e45a3e7118d77df05af7341e61784284f1e8d0d965307f1663f415bb1") + depends_on("c", type="build") # generated + depends_on("m4") depends_on("autoconf") depends_on("automake") diff --git a/var/spack/repos/builtin/packages/libnrm/package.py b/var/spack/repos/builtin/packages/libnrm/package.py index 2b91d482d14193..f714173323954a 100644 --- a/var/spack/repos/builtin/packages/libnrm/package.py +++ b/var/spack/repos/builtin/packages/libnrm/package.py @@ -17,6 +17,8 @@ class Libnrm(AutotoolsPackage): version("0.1.0", sha256="f849ada384025fa41251acc2a43aa335e0cb1b9cd1c8ab8b9d1808a036ae551e") + depends_on("c", type="build") # generated + tags = ["e4s"] depends_on("m4", type="build") diff --git a/var/spack/repos/builtin/packages/libnsl/package.py b/var/spack/repos/builtin/packages/libnsl/package.py index 9eb4e8489fbb97..5f9fd1c8f60a37 100644 --- a/var/spack/repos/builtin/packages/libnsl/package.py +++ b/var/spack/repos/builtin/packages/libnsl/package.py @@ -25,6 +25,8 @@ class Libnsl(AutotoolsPackage): url="https://github.com/thkukuk/libnsl/archive/1.1.0.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libogg/package.py b/var/spack/repos/builtin/packages/libogg/package.py index d711e9548389bd..4e62a81e9833a3 100644 --- a/var/spack/repos/builtin/packages/libogg/package.py +++ b/var/spack/repos/builtin/packages/libogg/package.py @@ -22,6 +22,8 @@ class Libogg(CMakePackage, AutotoolsPackage, Package): version("1.3.4", sha256="fe5670640bd49e828d64d2879c31cb4dde9758681bb664f9bdbf159a01b0c76e") version("1.3.2", sha256="e19ee34711d7af328cb26287f4137e70630e7261b17cbe3cd41011d73a654692") + depends_on("c", type="build") # generated + variant("shared", default=True, description="Build shared library", when="build_system=cmake") variant( "pic", diff --git a/var/spack/repos/builtin/packages/liboldx/package.py b/var/spack/repos/builtin/packages/liboldx/package.py index b65a99ae1678eb..2f7b9d7d7b5b7d 100644 --- a/var/spack/repos/builtin/packages/liboldx/package.py +++ b/var/spack/repos/builtin/packages/liboldx/package.py @@ -14,6 +14,8 @@ class Liboldx(AutotoolsPackage, XorgPackage): version("1.0.1", sha256="74322dbf04df69787485eb24b16e12783dfc3454befaf18482ead51bd7b55dc8") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/libopts/package.py b/var/spack/repos/builtin/packages/libopts/package.py index 78f48985a6da71..5c85ba65d51bdd 100644 --- a/var/spack/repos/builtin/packages/libopts/package.py +++ b/var/spack/repos/builtin/packages/libopts/package.py @@ -17,6 +17,8 @@ class Libopts(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + parallel = False def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/libp11/package.py b/var/spack/repos/builtin/packages/libp11/package.py index 69463c1669786c..addef7cc533a39 100644 --- a/var/spack/repos/builtin/packages/libp11/package.py +++ b/var/spack/repos/builtin/packages/libp11/package.py @@ -21,11 +21,14 @@ class Libp11(AutotoolsPackage): license("LGPL-2.1-or-later") + version("0.4.12", sha256="c1a233ecb09ab48595ba36a504c47f82cf53a59aa8db789c02ca72d50e85ca87") version("0.4.11", sha256="56d6149879bda379613d89adfd3486ce5a3c20af6c1e3f9e83d15d900ab9e4bc") version("0.4.10", sha256="123c1525fa7ce7a34060f9a4148a30717482c517a378f428b704459820c1bf35") version("0.4.9", sha256="9d1c76d74c21ca224f96204982097ebc6b956f645b2b0b5f9c502a20e9ffcfd8") version("0.4.8", sha256="acccd56b736942dfcc490d102d2cb2b6afa6b2e448dd1dc5a1b773eadb98f83d") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libpam/package.py b/var/spack/repos/builtin/packages/libpam/package.py index 85d888b07a367c..670df0cce10d6e 100644 --- a/var/spack/repos/builtin/packages/libpam/package.py +++ b/var/spack/repos/builtin/packages/libpam/package.py @@ -19,6 +19,8 @@ class Libpam(AutotoolsPackage): version("1.08", sha256="6f6d7530261ba9e2ece84214f1445857d488b7851c28a58356b49f2d9fd36290") version("1.07", sha256="104a158e013585e20287f8d33935e93c711b96281e6dda621a5c19575d0b0405") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libpaper/package.py b/var/spack/repos/builtin/packages/libpaper/package.py index 5723a25ea1260b..d4f0ef68bd836a 100644 --- a/var/spack/repos/builtin/packages/libpaper/package.py +++ b/var/spack/repos/builtin/packages/libpaper/package.py @@ -16,8 +16,11 @@ class Libpaper(AutotoolsPackage): license("LGPL-2.1-or-later") + version("1.1.29", sha256="26330e21e9a3124658d515fd850b0cde546ff42d89b2596a5264c5f1677f0547") version("1.1.28", sha256="c8bb946ec93d3c2c72bbb1d7257e90172a22a44a07a07fb6b802a5bb2c95fddc") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libpcap/package.py b/var/spack/repos/builtin/packages/libpcap/package.py index 19276cfd3de0b2..332ce47e0367f1 100644 --- a/var/spack/repos/builtin/packages/libpcap/package.py +++ b/var/spack/repos/builtin/packages/libpcap/package.py @@ -21,5 +21,8 @@ class Libpcap(AutotoolsPackage): version("1.9.1", sha256="635237637c5b619bcceba91900666b64d56ecb7be63f298f601ec786ce087094") version("1.8.1", sha256="673dbc69fdc3f5a86fb5759ab19899039a8e5e6c631749e48dcd9c6f0c83541e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("flex", type="build") depends_on("bison", type="build") diff --git a/var/spack/repos/builtin/packages/libpciaccess/package.py b/var/spack/repos/builtin/packages/libpciaccess/package.py index 90c9b543cab616..4704611854212c 100644 --- a/var/spack/repos/builtin/packages/libpciaccess/package.py +++ b/var/spack/repos/builtin/packages/libpciaccess/package.py @@ -19,6 +19,8 @@ class Libpciaccess(AutotoolsPackage, XorgPackage): version("0.13.5", sha256="fe26ec788732b4ef60b550f2d3fa51c605d27f646e18ecec878f061807a3526e") version("0.13.4", sha256="74d92bda448e6fdb64fee4e0091255f48d625d07146a121653022ed3a0ca1f2f") + depends_on("c", type="build") # generated + depends_on("libtool", type="build") depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") diff --git a/var/spack/repos/builtin/packages/libpfm4/package.py b/var/spack/repos/builtin/packages/libpfm4/package.py index 9ce27303269ab8..3f971e10dd67ab 100644 --- a/var/spack/repos/builtin/packages/libpfm4/package.py +++ b/var/spack/repos/builtin/packages/libpfm4/package.py @@ -24,6 +24,8 @@ class Libpfm4(MakefilePackage): version("4.9.0", sha256="db0fbe8ee28fd9beeb5d3e80b7cb3b104debcf6a9fcf5cb8b882f0662c79e4e2") version("4.8.0", sha256="9193787a73201b4254e3669243fd71d15a9550486920861912090a09f366cf68") + depends_on("c", type="build") # generated + # Fails to build libpfm4 with intel compiler version 16 and 17 conflicts("%intel@16:17") diff --git a/var/spack/repos/builtin/packages/libpipeline/package.py b/var/spack/repos/builtin/packages/libpipeline/package.py index b35c34559959fc..32d9e01d881e27 100644 --- a/var/spack/repos/builtin/packages/libpipeline/package.py +++ b/var/spack/repos/builtin/packages/libpipeline/package.py @@ -20,5 +20,7 @@ class Libpipeline(AutotoolsPackage): version("1.5.5", sha256="0c8367f8b82bb721b50647a647115b6e62a37e3b2e954a9685e4d933f30c00cc") version("1.4.2", sha256="fef1fc9aa40ce8796f18cd1aecd888a9484a9556c8b0f8d07c863578277679be") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("check", type="test") diff --git a/var/spack/repos/builtin/packages/libplist/package.py b/var/spack/repos/builtin/packages/libplist/package.py index d92235b13f96e5..d58de2c8916959 100644 --- a/var/spack/repos/builtin/packages/libplist/package.py +++ b/var/spack/repos/builtin/packages/libplist/package.py @@ -28,6 +28,9 @@ class Libplist(AutotoolsPackage): version("1.4", sha256="2ad226abe1131a72e7ecbb2b921ad92f54b8e787c2281c89b00145b519479a71") version("1.3", sha256="982c8aac59cdc3fafc925a407a29b6cf367c5ec9bad6ad509fe5ea25d3e5b6b0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build", when="@master") depends_on("automake", type="build", when="@master") depends_on("libtool", type="build", when="@master") diff --git a/var/spack/repos/builtin/packages/libpmemobj-cpp/package.py b/var/spack/repos/builtin/packages/libpmemobj-cpp/package.py index d4e43270ca758f..8d2af867d056c7 100644 --- a/var/spack/repos/builtin/packages/libpmemobj-cpp/package.py +++ b/var/spack/repos/builtin/packages/libpmemobj-cpp/package.py @@ -14,6 +14,7 @@ class LibpmemobjCpp(CMakePackage): git = "https://github.com/pmem/libpmemobj-cpp.git" version("develop", branch="master") + version("1.13.0", sha256="1fd204303b86ff9974e39d6cdb4037556402df981bebcc824a9125e12bf48c80") version("1.12", sha256="5a7e082a862affbd87ff174b790be7db77f7d85d4c583acc34011f1104bc54a9") version("1.11", sha256="2818f3ce23c861222d2765c377e6d4ccf8a2e2f66e4d23e4e2c35f4246f4a403") version("1.10", sha256="bba31d9a1c21b38c20cbe2d2b152effef7e2debfa89a87e0c32de616c31d9191") @@ -24,6 +25,9 @@ class LibpmemobjCpp(CMakePackage): version("1.5.1", sha256="0448bac4697f6563789e5bf22b8556288ae67ab916608bc45d0a3baa24c67985") version("1.5", sha256="6254aa2fb77977f8b91998eb866216d2af22f4ccbffdfc7932df1dff151da61e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # libpmemobj only supports 'Debug' and 'Release' variant( "build_type", diff --git a/var/spack/repos/builtin/packages/libpng/package.py b/var/spack/repos/builtin/packages/libpng/package.py index 395f2694c57cad..ef86a2e4930fa3 100644 --- a/var/spack/repos/builtin/packages/libpng/package.py +++ b/var/spack/repos/builtin/packages/libpng/package.py @@ -30,6 +30,9 @@ class Libpng(CMakePackage): version("1.5.30", sha256="7d76275fad2ede4b7d87c5fd46e6f488d2a16b5a69dc968ffa840ab39ba756ed") version("1.2.57", sha256="0f4620e11fa283fedafb474427c8e96bf149511a1804bdc47350963ae5cf54d8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") variant( diff --git a/var/spack/repos/builtin/packages/libpostal/package.py b/var/spack/repos/builtin/packages/libpostal/package.py index e594a00b689581..3bace0d7ae3644 100644 --- a/var/spack/repos/builtin/packages/libpostal/package.py +++ b/var/spack/repos/builtin/packages/libpostal/package.py @@ -25,6 +25,8 @@ class Libpostal(AutotoolsPackage): version("0.3.1", sha256="68c51a5fdae41e1cac474742789ba5a46a38e307a0a2450cb2d3e33b4f17cf4d") version("0.3", sha256="28c19e21bab13425a76aa65a8435f4b3909611056c2ff439c39b4e57b2a70150") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libpressio-adios1/package.py b/var/spack/repos/builtin/packages/libpressio-adios1/package.py new file mode 100644 index 00000000000000..f7a5f560b3653a --- /dev/null +++ b/var/spack/repos/builtin/packages/libpressio-adios1/package.py @@ -0,0 +1,26 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class LibpressioAdios1(CMakePackage): + """LibPressio file reader for legacy ADIOS1 files not supported by ADIOS2""" + + homepage = "https://github.com/robertu94/libpressio-adios1" + url = "https://github.com/robertu94/libpressio-adios1/archive/refs/tags/0.0.1.tar.gz" + git = "https://github.com/robertu94/libpressio-adios1" + + maintainers("robertu94") + + version("0.0.2", sha256="cb3c4ef3c9c3bd5f4c08d1145a07d2ce0c84605a2213b744992c6c8cef998d39") + + depends_on("cxx", type="build") # generated + + depends_on("adios") + depends_on("libpressio") + + def cmake_args(self): + args = ["-DCMAKE_MODULE_PATH={}".format(self.spec["adios"].prefix.etc)] + return args diff --git a/var/spack/repos/builtin/packages/libpressio-adios2/package.py b/var/spack/repos/builtin/packages/libpressio-adios2/package.py index d4aefcbb8566b9..778e780f50040c 100644 --- a/var/spack/repos/builtin/packages/libpressio-adios2/package.py +++ b/var/spack/repos/builtin/packages/libpressio-adios2/package.py @@ -14,9 +14,13 @@ class LibpressioAdios2(CMakePackage): maintainers("robertu94") + version("0.0.3", sha256="ca6a90dae1070f3ffe5c89b25966eb3142cb62820144e19ab4fd5b980531ba3b") version("0.0.2", sha256="8ab4b5a0dd8038d52f54aa9b5a67b83a8f7cd096db4c5a413fe0c6caf678e402") version("0.0.1", sha256="ab9c7e26114e8d81f8ad8aca703855079cd3441f9b72e01d9b4aeb0c57ce0746") + depends_on("cxx", type="build") # generated + + depends_on("libpressio@0.99.4:+mpi", when="@0.0.3:") depends_on("libpressio@0.85.0:+mpi", when="@0.0.2") depends_on("libpressio@0.60.0:+mpi") depends_on("adios2@2.8.0:+mpi") diff --git a/var/spack/repos/builtin/packages/libpressio-dataset/package.py b/var/spack/repos/builtin/packages/libpressio-dataset/package.py new file mode 100644 index 00000000000000..a7041bcdc9062c --- /dev/null +++ b/var/spack/repos/builtin/packages/libpressio-dataset/package.py @@ -0,0 +1,44 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class LibpressioDataset(CMakePackage): + """A set of libraries for LibPressio to easily load datasets""" + + homepage = "https://github.com/robertu94/libpressio_dataset" + url = "https://github.com/robertu94/libpressio_dataset/archive/refs/tags/0.0.2.tar.gz" + git = "https://github.com/robertu94/libpressio_dataset" + + maintainers = ["robertu94"] + + version("0.0.9", sha256="743edf3bda7a174ed9953388b7975d463384001b9c6e04d07e7adc8012d10f5a") + version("0.0.8", sha256="5e0adac22b8c96f26b93e253bb9d30623bf357da608c10bddad3871c4e9dbe17") + version("0.0.7", sha256="203b36b337d23b789658162ecc024d7acf60fbff2fdc5b946c0854998e03e7bf") + version("0.0.6", sha256="24c07ac329714587d0778e6a2bf598aa8005de374595c36180de81ab020d55fc") + version("0.0.5", sha256="07906545207831515ad7ce1ad99994887f458c2e2f422fd5ea7569a5b0d072ad") + version("0.0.4", sha256="ff65e9c45fac607c7e48d305694c79996a1eb20c409ca3e1af59aad0c6e16f57") + version("0.0.3", sha256="b821bd880159c93fe5a960f4b51927a3963b1f0d2b91dc2f6c4655d644e8a28b") + version("0.0.2", sha256="b5d62260cc596a6239a721bda12293bce34f86266c203a573d3afa8fe0876c2f") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant("hdf5", default=False, description="add support for hdf5") + variant("shared", default=True, description="build shared libaries") + + depends_on("libpressio@0.99.4:", when="@0.0.9:") + depends_on("libpressio@0.93.0:", when="@0.0.3:0.0.8") + depends_on("libpressio@0.91.1:", when="@:0.0.2") + depends_on("hdf5", when="+hdf5") + + def cmake_args(self): + args = [ + self.define("BUILD_TESTING", self.run_tests), + self.define_from_variant("LIBPRESSIO_DATASET_HAS_HDF5", "hdf5"), + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + ] + return args diff --git a/var/spack/repos/builtin/packages/libpressio-errorinjector/package.py b/var/spack/repos/builtin/packages/libpressio-errorinjector/package.py index 8ed53ad6704f83..05ad253ef83234 100644 --- a/var/spack/repos/builtin/packages/libpressio-errorinjector/package.py +++ b/var/spack/repos/builtin/packages/libpressio-errorinjector/package.py @@ -14,11 +14,15 @@ class LibpressioErrorinjector(CMakePackage): maintainers("robertu94") + version("0.9.0", commit="7042a11ca94f2027e60e5824c7c72c7e9a07f80f") version("0.8.0", commit="0bfac9a06b1ae34a872b8b599dd4ccb46aa2db4e") version("0.7.0", commit="0b5a5b15121be248a3e5af925f9ad88b3d43fef6") - depends_on("libpressio@0.88.0:", when="@0.8.0:") - depends_on("libpressio@:0.87.0", when="@:0.7.0") + depends_on("cxx", type="build") # generated + + depends_on("libpressio@0.99.4:", when="@0.9.0:") + depends_on("libpressio@0.88.0:", when="@0.8.0") + depends_on("libpressio@:0.87.0", when="@0.7.0") def cmake_args(self): args = ["-DBUILD_TESTING=OFF"] diff --git a/var/spack/repos/builtin/packages/libpressio-jit/package.py b/var/spack/repos/builtin/packages/libpressio-jit/package.py new file mode 100755 index 00000000000000..8d9fe66bdb01e8 --- /dev/null +++ b/var/spack/repos/builtin/packages/libpressio-jit/package.py @@ -0,0 +1,30 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class LibpressioJit(CMakePackage): + """the FZ module compiler""" + + homepage = "https://github.com/robertu94/libpressio_jit" + url = "https://github.com/robertu94/libpressio_jit/archive/refs/tags/0.0.1.tar.gz" + git = "https://github.com/robertu94/libpressio_jit" + + maintainers("robertu94") + license("BSD-4-Clause", checked_by="robertu94") + + version("0.0.1", sha256="6aa771c624980589cc941e8cfca1c5fb6cea3fef2b060f58bfdf07109eda8c08") + + depends_on("cxx", type="build") # generated + + variant("poorjit", description="include the prototype poorjit compiler", default=True) + + depends_on("poorjit", when="+poorjit") + depends_on("libpressio@0.99.1:") + + def cmake_args(self): + args = [self.define_from_variant("LIBPRESSIO_JIT_HAS_POORJIT", "poorjit")] + return args diff --git a/var/spack/repos/builtin/packages/libpressio-nvcomp/package.py b/var/spack/repos/builtin/packages/libpressio-nvcomp/package.py index d496bff18dd710..1b45443d086325 100644 --- a/var/spack/repos/builtin/packages/libpressio-nvcomp/package.py +++ b/var/spack/repos/builtin/packages/libpressio-nvcomp/package.py @@ -15,12 +15,18 @@ class LibpressioNvcomp(CMakePackage, CudaPackage): maintainers("robertu94") + version("0.0.6", sha256="19ecc090b32ec77ddbdf6a3f1f823cf19c32bd8c08b0acb0f87c740961a1d9b4") version("0.0.5", sha256="2f2a2567c77db550badaf594cda824fa313470b143f69bcef308eeb80b4876c2") version("0.0.4", sha256="6ff7d0f3167dead7584c994a6a11782f20eb3dd4844307e4ee8b2aebcd8571e9") version("0.0.3", sha256="21409d34f9281bfd7b83b74f5f8fc6d34794f3161391405538c060fb59534597") version("0.0.2", commit="38d7aa7c283681cbe5b7f17b900f72f9f25be51c") + depends_on("cxx", type="build") # generated + depends_on("nvcomp@2.2.0:", when="@0.0.3:") + depends_on("libpressio+cuda") + depends_on("libpressio@0.99.4:", when="@0.0.6:") + depends_on("libpressio@0.89.0:", when="@0.0.3:0.0.5") depends_on("libpressio@0.88.0:", when="@:0.0.2") conflicts("~cuda") diff --git a/var/spack/repos/builtin/packages/libpressio-opt/package.py b/var/spack/repos/builtin/packages/libpressio-opt/package.py index 07c4f3b03deba8..22ca887960430f 100644 --- a/var/spack/repos/builtin/packages/libpressio-opt/package.py +++ b/var/spack/repos/builtin/packages/libpressio-opt/package.py @@ -17,6 +17,7 @@ class LibpressioOpt(CMakePackage): version("develop", branch="develop") version("sdr-develop", branch="develop", git="git@github.com:szcompressor/SDRFramework") + version("0.15.4", sha256="43ff4a13300eb0812066b193f0883295156c85a5980f225e739f95f029c77f92") version("0.15.0", sha256="0f092ae287e555c890d0ab77df83a7acf619a2b05ab104cef8647df4f886d759") version("0.14.0", sha256="1e8d348f9777f3d49764b22b1f2abefd4b972cb9b1fa27c867373d32c8f1c57d") version("0.13.5", sha256="cc0e6a46335aa3552b8ab57757d39855f4fba71e661f706ec99519cb2c8a2f3c") @@ -29,7 +30,11 @@ class LibpressioOpt(CMakePackage): version("0.12.0", sha256="5f28f37de858634cf481d911f202360f078902803f82b5f49b7eec9b59948d64") version("0.11.0", sha256="cebbc512fcaa537d2af1a6919d6e0400cdc13595d71d9b90b74ad3eb865c9767") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libpressio+libdistributed+mpi") + depends_on("libpressio@0.99.4:", when="@0.15.4:") depends_on("libpressio@0.93.0:", when="@0.14.0:") depends_on("libpressio@0.95.0:", when="@0.15.0:") depends_on("libpressio@0.88.0:", when="@0.13.5:") @@ -49,5 +54,5 @@ def cmake_args(self): @run_after("build") @on_package_attributes(run_tests=True) - def test(self): + def check_test(self): make("test") diff --git a/var/spack/repos/builtin/packages/libpressio-predict/package.py b/var/spack/repos/builtin/packages/libpressio-predict/package.py new file mode 100644 index 00000000000000..6eeb7bc37d5e09 --- /dev/null +++ b/var/spack/repos/builtin/packages/libpressio-predict/package.py @@ -0,0 +1,66 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class LibpressioPredict(CMakePackage): + """High Fidelity Proxy Models for Compression""" + + homepage = "https://github.com/robertu94/libpressio-predict" + url = "https://github.com/robertu94/libpressio-predict/archive/refs/tags/0.0.0.tar.gz" + git = "https://github.com/robertu94/libpressio-predict" + + maintainers("robertu94") + + version("0.0.4", sha256="50131183196ba6476a887ee7ffeface3cbb368da24fab2f8c6352c1f891f8c1b") + version("0.0.3", sha256="dc2b97f58ba3ec5a86f93a4085ebb45521edb0347cb90a4ae68283de16e3c526") + version("0.0.2", sha256="02323e03c832cd1f116136347c6b2b52e5c04485fcd57aeb588b6f1923c62a60") + version("0.0.0", sha256="b3c08be05e3b49542929e4d3849c232d1343c66c9f785b312bb37196dc530035") + + depends_on("cxx", type="build") # generated + + variant("bin", default=True, description="build the command line tools") + variant("shared", default=True, description="build shared libaries") + + depends_on("libpressio-tools@0.4.2:", when="@:0.0.3") + depends_on("libpressio@0.96.3:", when="@:0.0.2") + depends_on("libpressio@0.96.5:", when="@0.0.3:") + depends_on("libpressio-dataset@0.0.7:", when="@0.0.3:") + depends_on("libpressio-dataset@0.0.6:", when="@0.0.2") + with when("@0.0.3:"): + variant("khan2023", description="build support for secde from khan2023", default=False) + variant("rahman2023", description="build support for secde from rahman2023", default=False) + variant("sian2022", description="build support for secde from sian2022", default=False) + variant( + "python", description="build support for python fit/predict methods", default=False + ) + with when("+python"): + depends_on("libpressio+pybind") + with when("+rahman2023"): + conflicts("~python") + with when("+khan2023"): + depends_on("libpressio+sz3+zfp") + depends_on("sz3") + depends_on("zfp") + with when("+sian2022"): + depends_on("libpressio+sz3") + depends_on("sz3") + with when("+bin"): + depends_on("libpressio+libdistributed+json+remote+mpi+openssl") + depends_on("libdistributed@0.4.3:") + depends_on("mpi") + depends_on("sqlite@3.38:+dynamic_extensions") + depends_on("libpressio-dataset@0.0.5", when="@0.0.0") + + def cmake_args(self): + args = [ + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + self.define_from_variant("LIBPRESSIO_PREDICT_BUILD_TOOLS", "bin"), + self.define_from_variant("LIBPRESSIO_PREDICT_HAS_PYTHON", "python"), + self.define_from_variant("LIBPRESSIO_PREDICT_HAS_SIAN2022", "sian2022"), + self.define_from_variant("LIBPRESSIO_PREDICT_HAS_KHAN2023", "khan2023"), + self.define("LIBPRESSIO_PREDICT_USE_MPI", self.spec.satisfies("^ mpi")), + ] + return args diff --git a/var/spack/repos/builtin/packages/libpressio-rmetric/package.py b/var/spack/repos/builtin/packages/libpressio-rmetric/package.py index a024871bae6813..01feff140f8fe6 100644 --- a/var/spack/repos/builtin/packages/libpressio-rmetric/package.py +++ b/var/spack/repos/builtin/packages/libpressio-rmetric/package.py @@ -17,13 +17,17 @@ class LibpressioRmetric(CMakePackage): version("master", branch="master") # note versions <= 0.0.3 do not build with spack + version("0.0.8", sha256="246d98c80f1011819bdac2893035d7914b40d328aae2d50b3608a178406f95d9") version("0.0.7", sha256="b01df5102076412064849335c2c928a4a5ba23e1f1f515062d9166b0a7531179") version("0.0.6", sha256="b23a79448cd32b51a7301d6cebf4e228289712dd77dd76d86821741467e9af46") version("0.0.5", sha256="51eb192314ef083790dd0779864cab527845bd8de699b3a33cd065c248eae24c") version("0.0.4", sha256="166af5e84d7156c828a3f0dcc5bf531793ea4ec44bbf468184fbab96e1f0a91f") version("0.0.3", sha256="c45948f83854c87748c7ec828ca2f06d7cf6f98a34f763b68c13a4e2deb7fd79") - depends_on("libpressio@0.88.0:", when="@0.0.5:") + depends_on("cxx", type="build") # generated + + depends_on("libpressio@0.99.4:", when="@0.0.8:") + depends_on("libpressio@0.88.0:", when="@0.0.5:0.0.7") depends_on("libpressio@0.85.0:", when="@:0.0.4") depends_on("r") depends_on("r-rcpp") @@ -40,5 +44,5 @@ def cmake_args(self): @run_after("build") @on_package_attributes(run_tests=True) - def test(self): + def check_test(self): make("test") diff --git a/var/spack/repos/builtin/packages/libpressio-sperr/package.py b/var/spack/repos/builtin/packages/libpressio-sperr/package.py index 193ac867375fe9..adf79898aa16ec 100644 --- a/var/spack/repos/builtin/packages/libpressio-sperr/package.py +++ b/var/spack/repos/builtin/packages/libpressio-sperr/package.py @@ -18,12 +18,16 @@ class LibpressioSperr(CMakePackage): license("GPL-3.0-only") version("master", branch="master") + version("0.0.5", sha256="8fda62ad923b4229b9a434d5f9197010e396e972ffb9e29c2e7783ec14fdc324") version("0.0.4", sha256="97f2879460b1a28ed8ebf0c300c1cf7ceeb2c7aa7b8a1307ed19bf8cce0b7941") version("0.0.3", sha256="e0d1fd083419aaaa243cbf780b7de17aeb96533000071088aa21ec238d358ecc") version("0.0.2", sha256="61995d687f9e7e798e17ec7238d19d917890dc0ff5dec18293b840c4d6f8c115") version("0.0.1", sha256="e2c164822708624b97654046b42abff704594cba6537d6d0646d485bdf2d03ca") - depends_on("libpressio@0.88.0:", when="@0.0.3:") + depends_on("cxx", type="build") # generated + + depends_on("libpressio@0.99.4:", when="@0.0.5:") + depends_on("libpressio@0.88.0:", when="@0.0.3:0.0.4") depends_on("libpressio@:0.88.0", when="@:0.0.2") depends_on("sperr@:0.6.2", when="@:0.0.3") depends_on("sperr@0.7.1:", when="@0.0.4:") diff --git a/var/spack/repos/builtin/packages/libpressio-tools/package.py b/var/spack/repos/builtin/packages/libpressio-tools/package.py index a72f1b4c8b29d9..b4f518e0f8245d 100644 --- a/var/spack/repos/builtin/packages/libpressio-tools/package.py +++ b/var/spack/repos/builtin/packages/libpressio-tools/package.py @@ -9,14 +9,18 @@ class LibpressioTools(CMakePackage): """General Utilities for LibPressio""" - homepage = "https://github.com/robertu94/pressio-tools" - url = "https://github.com/robertu94/pressio-tools/archive/refs/tags/0.0.15.tar.gz" + url = "https://github.com/robertu94/pressio-tools/archive/refs/tags/0.4.7.tar.gz" git = "https://github.com/robertu94/pressio-tools" + homepage = "https://github.com/robertu94/pressio-tools" maintainers("robertu94") tags = ["e4s"] - version("master", branch="master") + version("0.4.7", sha256="02052025529bcae6125bbcb6c1513776f06164324379d936175fc574188d4d7c") + version("0.4.6", sha256="b1253d49bd16669c41332146e3c441f5a6363cad73262e91a945831ec2bc76e0") + version("0.4.5", sha256="4f296e4b31f6880f388cb95823864f2c76244e40bb6a94d7918234d189f799ed") + version("0.4.4", sha256="edbff72b0dba11b145b4d61d507b869ef976c5a8941afb817a533b923a9d7a41") + version("0.4.3", sha256="2122e2c5212325a54bb6a80f4b7fb56060a1d2d0fa5733ac5757109ea892c9f9") version("0.3.0", sha256="2f309557df3e8df9e492691213933865a5dbfb051c03404e33918f4765223025") version("0.2.0", sha256="75048950f0dfa0e20f2651991875822f36fceb84bdda12d1c0361d49912392b8") version("0.1.6", sha256="a67a364f46dea29ff1b3e5c52c0a5abf2d9d53412fb8d424f6bd71252bfa7792") @@ -37,6 +41,16 @@ class LibpressioTools(CMakePackage): version("0.0.16", sha256="1299e441fb15666d1c8abfd40f3f52b1bf55b6bfda4bfcc71177eec37160a95e") version("0.0.15", sha256="bcdf865d77969a34e2d747034ceeccf5cb766a4c11bcc856630d837f442ee33e") + depends_on("cxx", type="build") # generated + + depends_on("libpressio-adios1@0.0.2:", when="+adios1") + depends_on("lc-framework@1.1.1:+libpressio", when="+lc") + + depends_on("dctz@0.2.2:+libpressio", when="+dctz") + depends_on("libpressio-predict@0.0.4:", when="+predict") + depends_on("libpressio-dataset@0.0.8:", when="+dataset") + depends_on("libpressio-jit@0.0.1:", when="+jit") + depends_on("mpi", when="+mpi") depends_on("libpressio+libdistributed+mpi", when="+mpi") depends_on("libpressio", when="~mpi") @@ -73,32 +87,34 @@ class LibpressioTools(CMakePackage): variant("adios2", default=False, description="depend on ADIOS2 for IO modules") variant("sperr", default=False, description="depend on sperr", when="@0.1.2:") variant("nvcomp", default=False, description="depend on nvcomp", when="@0.1.0:") - conflicts("+opt", "~mpi") + variant("adios1", default=False, description="depend on adios1", when="@0.4.3:") + variant("lc", default=False, description="depend on lc", when="@0.4.4:") + variant("dctz", default=False, description="depend on dctz", when="@0.4.5:") + variant("dataset", default=False, description="depend on libpressio-dataset", when="@0.4.6:") + variant("predict", default=False, description="depend on libpressio-predict", when="@0.4.6:") + variant("jit", default=False, description="depend on libpressio-jit", when="@0.4.6:") + conflicts("+opt", when="~mpi", msg="opt support requires MPI") def cmake_args(self): - args = [] - if "+mpi" in self.spec: - args.append("-DLIBPRESSIO_TOOLS_HAS_MPI=YES") - if "+opt" in self.spec: - args.append("-DLIBPRESSIO_TOOLS_HAS_OPT=YES") - if "+error_injector" in self.spec: - args.append("-DLIBPRESSIO_TOOLS_HAS_ERROR_INJECTOR=YES") - if "+tthresh" in self.spec: - args.append("-DLIBPRESSIO_TOOLS_HAS_TTHRESH=YES") - if "+rcpp" in self.spec: - args.append("-DLIBPRESSIO_TOOLS_HAS_RMETRIC=YES") - if "+sperr" in self.spec: - args.append("-DLIBPRESSIO_TOOLS_HAS_SPERR=YES") - if "+nvcomp" in self.spec: - args.append("-DLIBPRESSIO_TOOLS_HAS_NVCOMP=YES") - if self.run_tests: - args.append("-DBUILD_TESTING=ON") - else: - args.append("-DBUILD_TESTING=OFF") - + args = [ + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_MPI", "mpi"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_OPT", "opt"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_ERROR_INJECTOR", "error_injector"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_TTHRESH", "tthresh"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_RMETRIC", "rcpp"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_SPERR", "sperr"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_NVCOMP", "nvcomp"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_DCTZ", "dctz"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_ADIOS1", "adios1"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_LC", "lc"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_PREDICT", "predict"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_JIT", "jit"), + self.define_from_variant("LIBPRESSIO_TOOLS_HAS_DATASET", "dataset"), + self.define("BUILD_TESTING", self.run_tests), + ] return args @run_after("build") @on_package_attributes(run_tests=True) - def test(self): + def check_test(self): make("test") diff --git a/var/spack/repos/builtin/packages/libpressio-tthresh/package.py b/var/spack/repos/builtin/packages/libpressio-tthresh/package.py index c37bcb8ededb9e..d66cf2894d14dd 100644 --- a/var/spack/repos/builtin/packages/libpressio-tthresh/package.py +++ b/var/spack/repos/builtin/packages/libpressio-tthresh/package.py @@ -18,13 +18,17 @@ class LibpressioTthresh(CMakePackage): license("LGPL-3.0-or-later") version("main", branch="main") + version("0.0.8", sha256="c6590a965b0ff3e97db1bab8ddb6e552ad4f8142623d02323dc9598da9052309") version("0.0.7", sha256="5e364ef72dd1ed1cf786d2b7aef89624fdcf1a0ca845777ce54c365b35a75be2") version("0.0.6", sha256="e9dc4754421d892a86516c6bb892f6ff582e9ea3c242c1c052104e4f6944cbec") version("0.0.5", sha256="af47c90e9c16825312e390a7fb30d9d128847afb69ad6c2f6608bd80f60bae23") version("0.0.3", sha256="b0b0a4876d3362deafc2bb326be33882132e3d1666e0c5f916fd6fad74a18688") version("0.0.1", sha256="9efcfa97a5a81e9c456f50b712adb806d9d2f2ed6039860615df0f2e9d96569e") + depends_on("cxx", type="build") # generated + depends_on("eigen") + depends_on("libpressio@0.99.4:", when="@0.0.8:") depends_on("libpressio@0.85.0:", when="@:0.0.5") depends_on("libpressio@0.88.0:", when="@0.0.6:") @@ -38,5 +42,5 @@ def cmake_args(self): @run_after("build") @on_package_attributes(run_tests=True) - def test(self): + def check_test(self): make("test") diff --git a/var/spack/repos/builtin/packages/libpressio/package.py b/var/spack/repos/builtin/packages/libpressio/package.py index f1828bcf51c886..4ae7016e69d89e 100644 --- a/var/spack/repos/builtin/packages/libpressio/package.py +++ b/var/spack/repos/builtin/packages/libpressio/package.py @@ -20,6 +20,21 @@ class Libpressio(CMakePackage, CudaPackage): tests_require_compiler = True version("master", branch="master") version("develop", branch="develop") + version("0.99.4", sha256="091e4bac2cedca5fb9495a22eee7be718c2d04d899d56c65fc088936884eac0e") + version("0.99.2", sha256="556d157097b2168fefde1fe3b5e2da06a952346357d46c55548d92c77d1da878") + version("0.99.1", sha256="c9b19deaac4df5eaeecd938fea4c1752d86474f453880c0ba984ceee6bf15d35") + version("0.99.0", sha256="b95916c4851a7ec952e5f29284e4f7477eaeff0e52a2e5b593481c72edf733d6") + version("0.98.1", sha256="5246271fdf2e4ba99eeadfccd6224b75bf3af278a812ded74ec9adc11f6cabba") + version("0.98.0", sha256="6b6507bf1489ff2cbeaf4c507d34e1015495c811730aa809e778f111213062db") + version("0.97.3", sha256="631111253ec4cfd3138773eaf8280921e220b0d260985da762f0a0152e5b1b17") + version("0.97.2", sha256="70d549ef457d5192c084fbf6304cb362d367786afe88d7b8db4eea263f9c7d43") + version("0.96.6", sha256="a8d3269f0f5289d46471a5b85e5cd32e370edb8df45d04f5e707e0a1f64eccd8") + version("0.96.5", sha256="7cca6f3f98dde2dbd1c9ff7462d09975f6a3630704bd01b6bef6163418a0521b") + version("0.96.4", sha256="7f012b01ce1a6c9f5897487089266de5b60659ed6b220eadba51d63613620404") + version("0.96.3", sha256="e8f4af028d34df2f3c8eb61cfc2f93fadab7a2e2d072a30ee6a085fb344a3be4") + version("0.96.2", sha256="2c904ec16900b67ab0188ea96d27fa4efca2c9efc1b214119451becaaeaa2d18") + version("0.96.1", sha256="2305d04b57c1b49ecd5a4bda117f1252a57529c98e6bd260bfe5166a4f4d4043") + version("0.96.0", sha256="42f563b70c4f77abffb430284f0c5bc9adba2666412ee4072d6f97da88f0c1a0") version("0.95.1", sha256="c2e4f81d1491781cd47f2baba64acfbba9a7d6203c9b01369f8b1a8f94e0bb2b") version("0.94.0", sha256="4250597cdd54043a7d5009ffc3feea3eac9496cdd38ea3f61f9727b7acd09add") version("0.93.0", sha256="1da5940aaf0190a810988dcd8f415b9c8db53bbbdfcb627d899921c89170d990") @@ -159,6 +174,19 @@ class Libpressio(CMakePackage, CudaPackage): version("0.27.0", sha256="387ee5958de2d986095cda2aaf39d0bf319d02eaeeea2a565aea97e6a6f31f36") version("0.26.0", sha256="c451591d106d1671c9ddbb5c304979dd2d083e0616b2aeede62e7a6b568f828c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant( + "pybind", default=False, description="build support for pybind metrics", when="@0.96.0:" + ) + variant( + "openssl", default=False, description="build support for hashing options", when="@0.96.2:" + ) + variant("szx", default=False, description="build support for SZx", when="@0.87.0:") + variant("blosc2", default=False, description="build support for blosc2", when="@0.98.0:") + variant("matio", default=False, description="build support for matio", when="@0.99.0:") + variant("clang", default=False, description="build migration tools", when="@0.99.0:") variant("blosc", default=False, description="support the blosc lossless compressors") variant("fpzip", default=False, description="support for the FPZIP lossy compressor") variant("hdf5", default=False, description="support reading and writing from hdf5 files") @@ -206,6 +234,7 @@ class Libpressio(CMakePackage, CudaPackage): depends_on("boost", when="@:0.51.0+boost") depends_on("libstdcompat+boost", when="+boost") + depends_on("libstdcompat@0.0.16:", when="@0.93.0:") depends_on("libstdcompat@0.0.14:", when="@0.79.0:") depends_on("libstdcompat@0.0.13:", when="@0.73.0:") depends_on("libstdcompat@0.0.10:", when="@0.71.3:") @@ -253,106 +282,115 @@ class Libpressio(CMakePackage, CudaPackage): depends_on("arc", when="+arc") depends_on("netcdf-c", when="+netcdf") depends_on("mgardx", when="+mgardx") + depends_on("szx@:1.1.0", when="@0.87.0:0.97.1 +szx") + depends_on("szx@1.1.1:", when="@0.97.2: +szx") + depends_on("openssl", when="+openssl") + depends_on("py-pybind11", when="+pybind") + depends_on("matio+shared@1.5.17:", when="+matio") + depends_on("llvm@17: +clang", when="+clang") conflicts( "^ mgard@2022-11-18", when="@:0.88.3+mgard", msg="mgard@2022-11-18 is not supported before 0.89.0", ) conflicts( - "+mgardx", when="+szauto" - ) # SZ auto and MGARDx cause symbol conflicts with each other + "+mgardx", when="+szauto", msg="SZ auto and MGARDx cause symbol conflicts with each other" + ) conflicts( "~json", when="@0.57.0:+remote", msg="JSON support required for remote after version 0.57.0", ) + for cuda_compressor in ["cusz", "mgard", "zfp", "ndzip"]: + conflicts( + "~cuda+{pkg} ^ {pkg}+cuda".format(pkg=cuda_compressor), + msg="compiling a CUDA compressor without a CUDA support makes no sense", + ) depends_on("sz3", when="+sz3") + depends_on("sz3@3.1.8:", when="@0.98.1: +sz3") depends_on("bzip2", when="+bzip2") depends_on("qoz", when="+qoz") - depends_on("cusz", when="+cusz") + depends_on("cusz@0.6.0:", when="+cusz") extends("python", when="+python") + def lp_cxx_version(self): + try: + self.compiler.cxx20_flag + return "20" + except Exception: + pass + try: + self.compiler.cxx17_flag + return "17" + except Exception: + pass + try: + self.compiler.cxx14_flag + return "14" + except Exception: + pass + self.compiler.cxx11_flag + return "11" + def cmake_args(self): - args = [] + args = [ + self.define_from_variant("LIBPRESSIO_HAS_SZ", "sz"), + self.define_from_variant("LIBPRESSIO_HAS_SZx", "szx"), + self.define_from_variant("LIBPRESSIO_HAS_OPENSSL", "openssl"), + self.define_from_variant("LIBPRESSIO_HAS_PYTHON_LAUNCH", "pybind"), + self.define_from_variant("LIBPRESSIO_HAS_BLOSC2", "blosc2"), + self.define_from_variant("LIBPRESSIO_HAS_MATLABIO", "matio"), + self.define_from_variant("BUILD_MIGRATION_TOOLS", "clang"), + self.define_from_variant("LIBPRESSIO_HAS_SZ_AUTO", "szauto"), + self.define_from_variant("LIBPRESSIO_HAS_ZFP", "zfp"), + self.define_from_variant("LIBPRESSIO_HAS_FPZIP", "fpzip"), + self.define_from_variant("LIBPRESSIO_HAS_BLOSC", "blosc"), + self.define_from_variant("LIBPRESSIO_HAS_MAGICK", "magick"), + self.define_from_variant("LIBPRESSIO_HAS_MGARD", "mgard"), + self.define_from_variant("LIBPRESSIO_HAS_PETSC", "petsc"), + self.define_from_variant("LIBPRESSIO_HAS_MPI", "mpi"), + self.define_from_variant("LIBPRESSIO_HAS_LUA", "lua"), + self.define_from_variant("LIBPRESSIO_HAS_LIBDISTRIBUTED", "libdistributed"), + self.define_from_variant("LIBPRESSIO_HAS_FTK", "ftk"), + self.define_from_variant("LIBPRESSIO_HAS_BIT_GROOMING", "bitgrooming"), + self.define_from_variant("LIBPRESSIO_HAS_DIGIT_ROUNDING", "digitrounding"), + self.define_from_variant("LIBPRESSIO_HAS_OPENMP", "openmp"), + self.define_from_variant("LIBPRESSIO_HAS_REMOTELAUNCH", "remote"), + self.define_from_variant("LIBPRESSIO_HAS_JSON", "json"), + self.define_from_variant("LIBPRESSIO_HAS_LINUX", "unix"), + self.define_from_variant("LIBPRESSIO_HAS_NDZIP", "ndzip"), + self.define_from_variant("LIBPRESSIO_HAS_ARC", "arc"), + self.define_from_variant("LIBPRESSIO_HAS_NETCDF", "netcdf"), + self.define_from_variant("LIBPRESSIO_HAS_SZ3", "sz3"), + self.define_from_variant("LIBPRESSIO_HAS_MGARDx", "mgardx"), + self.define_from_variant("LIBPRESSIO_HAS_BZIP2", "bzip2"), + self.define_from_variant("LIBPRESSIO_HAS_QoZ", "qoz"), + self.define_from_variant("LIBPRESSIO_HAS_CUSZ", "cusz"), + self.define_from_variant("LIBPRESSIO_HAS_CUFILE", "cuda"), + self.define_from_variant("LIBPRESSIO_HAS_CUDA", "cuda"), + self.define_from_variant("LIBPRESSIO_HAS_HDF", "hdf5"), + self.define_from_variant("BUILD_DOCS", "docs"), + self.define_from_variant("LIBPRESSIO_INSTALL_DOCS", "docs"), + self.define_from_variant("BUILD_PYTHON_WRAPPER", "python"), + self.define("LIBPRESSIO_HAS_MPI4PY", self.spec.satisfies("+python +mpi")), + self.define("LIBPRESSIO_BUILD_MODE", "FULL" if "+core" in self.spec else "CORE"), + self.define("BUILD_TESTING", self.run_tests), + # this flag was removed in 0.52.0, we should deprecate and remove this + self.define( + "LIBPRESSIO_CXX_VERSION", "11" if "+boost" in self.spec else self.lp_cxx_version() + ), + ] + # if cuda is backed by the shim, we need to set these linker flags to + # avoid downstream linker errors + if self.spec.satisfies("+cusz +cuda"): + args.append("-DCMAKE_EXE_LINKER_FLAGS=-Wl,--allow-shlib-undefined") + # libpressio needs to know where to install the python libraries if "+python" in self.spec: args.append("-DLIBPRESSIO_PYTHON_SITELIB={0}".format(python_platlib)) - args.append("-DBUILD_PYTHON_WRAPPER=ON") - if "+mpi" in self.spec: - args.append("-DLIBPRESSIO_HAS_MPI4PY=ON") + # help ensure that libpressio finds the correct HDF5 package if "+hdf5" in self.spec: - args.append("-DLIBPRESSIO_HAS_HDF=ON") args.append("-DHDF5_ROOT=" + self.spec["hdf5"].prefix) - if "+sz" in self.spec: - args.append("-DLIBPRESSIO_HAS_SZ=ON") - if "+szauto" in self.spec: - args.append("-DLIBPRESSIO_HAS_SZ_AUTO=ON") - if "+zfp" in self.spec: - args.append("-DLIBPRESSIO_HAS_ZFP=ON") - if "+fpzip" in self.spec: - args.append("-DLIBPRESSIO_HAS_FPZIP=ON") - if "+blosc" in self.spec: - args.append("-DLIBPRESSIO_HAS_BLOSC=ON") - if "+magick" in self.spec: - args.append("-DLIBPRESSIO_HAS_MAGICK=ON") - if "+mgard" in self.spec: - args.append("-DLIBPRESSIO_HAS_MGARD=ON") - if "+petsc" in self.spec: - args.append("-DLIBPRESSIO_HAS_PETSC=ON") - if "+boost" in self.spec: - args.append("-DLIBPRESSIO_CXX_VERSION=11") - if "+mpi" in self.spec: - args.append("-DLIBPRESSIO_HAS_MPI=ON") - if "+lua" in self.spec: - args.append("-DLIBPRESSIO_HAS_LUA=ON") - if "+libdistributed" in self.spec: - args.append("-DLIBPRESSIO_HAS_LIBDISTRIBUTED=ON") - if "+ftk" in self.spec: - args.append("-DLIBPRESSIO_HAS_FTK=ON") - if "+bitgrooming" in self.spec: - args.append("-DLIBPRESSIO_HAS_BIT_GROOMING=ON") - if "+digitrounding" in self.spec: - args.append("-DLIBPRESSIO_HAS_DIGIT_ROUNDING=ON") - if "+openmp" in self.spec: - args.append("-DLIBPRESSIO_HAS_OPENMP=ON") - if "+docs" in self.spec: - args.append("-DBUILD_DOCS=ON") - args.append("-DLIBPRESSIO_INSTALL_DOCS=ON") - if "+remote" in self.spec: - args.append("-DLIBPRESSIO_HAS_REMOTELAUNCH=ON") - if "+json" in self.spec: - args.append("-DLIBPRESSIO_HAS_JSON=ON") - if "+unix" in self.spec: - args.append("-DLIBPRESSIO_HAS_LINUX=ON") - if "+ndzip" in self.spec: - args.append("-DLIBPRESSIO_HAS_NDZIP=ON") - if "+arc" in self.spec: - args.append("-DLIBPRESSIO_HAS_ARC=ON") - if "+netcdf" in self.spec: - args.append("-DLIBPRESSIO_HAS_NETCDF=ON") - if "+sz3" in self.spec: - args.append("-DLIBPRESSIO_HAS_SZ3=ON") - if "+cuda" in self.spec: - args.append("-DLIBPRESSIO_HAS_CUFILE=ON") - args.append("-DLIBPRESSIO_HAS_CUDA=ON") - if "+mgardx" in self.spec: - args.append("-DLIBPRESSIO_HAS_MGARDx=ON") - if "+bzip2" in self.spec: - args.append("-DLIBPRESSIO_HAS_BZIP2=ON") - if "+qoz" in self.spec: - args.append("-DLIBPRESSIO_HAS_QoZ=ON") - if "+cusz" in self.spec: - args.append("-DLIBPRESSIO_HAS_CUSZ=ON") - if self.spec.satisfies("+cusz +cuda"): - args.append("-DCMAKE_EXE_LINKER_FLAGS=-Wl,--allow-shlib-undefined") - if "+core" in self.spec: - args.append("-DLIBPRESSIO_BUILD_MODE=FULL") - else: - args.append("-DLIBPRESSIO_BUILD_MODE=CORE") - if self.run_tests: - args.append("-DBUILD_TESTING=ON") - else: - args.append("-DBUILD_TESTING=OFF") return args def setup_run_environment(self, env): diff --git a/var/spack/repos/builtin/packages/libproxy/package.py b/var/spack/repos/builtin/packages/libproxy/package.py index 70158c0bf90e8b..f7f826fd479fd3 100644 --- a/var/spack/repos/builtin/packages/libproxy/package.py +++ b/var/spack/repos/builtin/packages/libproxy/package.py @@ -21,6 +21,9 @@ class Libproxy(CMakePackage): version("0.4.14", sha256="6220a6cab837a8996116a0568324cadfd09a07ec16b930d2a330e16d5c2e1eb6") version("0.4.13", sha256="d610bc0ef81a18ba418d759c5f4f87bf7102229a9153fb397d7d490987330ffd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("perl", default=False, description="Enable Perl bindings") variant("python", default=False, description="Enable Python bindings", when="@0.4.16:") diff --git a/var/spack/repos/builtin/packages/libpsl/package.py b/var/spack/repos/builtin/packages/libpsl/package.py index f6ea835e9a5df8..fe8c8210d05294 100644 --- a/var/spack/repos/builtin/packages/libpsl/package.py +++ b/var/spack/repos/builtin/packages/libpsl/package.py @@ -15,12 +15,15 @@ class Libpsl(AutotoolsPackage): license("MIT") + version("0.21.5", sha256="1dcc9ceae8b128f3c0b3f654decd0e1e891afc6ff81098f227ef260449dae208") version("0.21.2", sha256="e35991b6e17001afa2c0ca3b10c357650602b92596209b7492802f3768a6285f") version("0.20.2", sha256="7aa949fd3fdba61b0dc7b3f4c2520263b942c189746e157f48436386eca3398e") version("0.19.1", sha256="9b47387a087bcac2af31ea0c94f644bfa32e0be6d079bfa430452b7521ad8c57") version("0.18.0", sha256="f79c6b257dd39e8f37c7e18d293bbfa35f38676f5d6b6e918687d1cd08216439") version("0.17.0", sha256="025729d6a26ffd53cb54b4d86196f62c01d1813a4360c627546c6eb60ce3dd4b") + depends_on("c", type="build") # generated + depends_on("icu4c") depends_on("gettext", type="build") @@ -40,7 +43,7 @@ def url_for_version(self, version): def configure_args(self): spec = self.spec - args = ["PYTHON={0}".format(spec["python"].command.path)] + args = [f"PYTHON={spec['python'].command.path}"] if self.run_tests: args.append("--enable-valgrind-tests") diff --git a/var/spack/repos/builtin/packages/libpsm3/package.py b/var/spack/repos/builtin/packages/libpsm3/package.py index 8ce2995bfdd1ae..8bb57327616b27 100644 --- a/var/spack/repos/builtin/packages/libpsm3/package.py +++ b/var/spack/repos/builtin/packages/libpsm3/package.py @@ -22,6 +22,8 @@ class Libpsm3(AutotoolsPackage): ) version("11.4.1.0", sha256="272adb9ec10edf709bfcfccc6b6e9296d25d892c36b845ad577caeb82b70c9ac") + depends_on("c", type="build") # generated + variant("atomics", default=True, description="Enable atomics") variant("debug", default=False, description="Enable debugging") variant("sockets", default=True, description="Enable PSM3 sockets") diff --git a/var/spack/repos/builtin/packages/libpsml/package.py b/var/spack/repos/builtin/packages/libpsml/package.py index b6fb93a282a009..77ac9840eb5f62 100644 --- a/var/spack/repos/builtin/packages/libpsml/package.py +++ b/var/spack/repos/builtin/packages/libpsml/package.py @@ -22,6 +22,8 @@ class Libpsml(AutotoolsPackage): version("1.1.7", sha256="b3f5431fd3965b66fe01b899c0c3ef73d9f969d67329cd1f5aba84fb056b5dd1") version("1.1.6", sha256="521647dbd945b208e5d468fceeb2bc397737d9a659e2c7549597bf4eb29f60df") + depends_on("fortran", type="build") # generated + depends_on("autoconf@2.69:", type="build") depends_on("automake@1.14:", type="build") depends_on("libtool@2.4.2:", type="build") diff --git a/var/spack/repos/builtin/packages/libpspio/package.py b/var/spack/repos/builtin/packages/libpspio/package.py index 97744468e17310..b462c5c58c21c1 100644 --- a/var/spack/repos/builtin/packages/libpspio/package.py +++ b/var/spack/repos/builtin/packages/libpspio/package.py @@ -18,6 +18,9 @@ class Libpspio(AutotoolsPackage): version("0.3.0", sha256="4dc092457e481e5cd703eeecd87e6f17749941fe274043550c8a2557a649afc5") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=False, description="Enable Fortran bindings") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/libpthread-stubs/package.py b/var/spack/repos/builtin/packages/libpthread-stubs/package.py index cdf5143b5b5b2c..0deb8fb7172288 100644 --- a/var/spack/repos/builtin/packages/libpthread-stubs/package.py +++ b/var/spack/repos/builtin/packages/libpthread-stubs/package.py @@ -15,6 +15,7 @@ class LibpthreadStubs(AutotoolsPackage, XorgPackage): maintainers("wdconinc") + version("0.5", sha256="593196cc746173d1e25cb54a93a87fd749952df68699aab7e02c085530e87747") version( "0.4", sha256="50d5686b79019ccea08bcbd7b02fe5a40634abcfd4146b6e75c6420cc170e9d9", diff --git a/var/spack/repos/builtin/packages/libpulsar/package.py b/var/spack/repos/builtin/packages/libpulsar/package.py index cb24450f499b1c..cbff8e93203287 100644 --- a/var/spack/repos/builtin/packages/libpulsar/package.py +++ b/var/spack/repos/builtin/packages/libpulsar/package.py @@ -20,6 +20,9 @@ class Libpulsar(CMakePackage): version("2.7.0", sha256="5bf8e5115075e12c848a9e4474cd47067c3200f7ff13c45f624f7383287e8e5e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zstd") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/libqrencode/package.py b/var/spack/repos/builtin/packages/libqrencode/package.py index d3db70755e1e59..3079c383347b9f 100644 --- a/var/spack/repos/builtin/packages/libqrencode/package.py +++ b/var/spack/repos/builtin/packages/libqrencode/package.py @@ -21,6 +21,8 @@ class Libqrencode(AutotoolsPackage): version("master", branch="master") version("4.1.1", sha256="5385bc1b8c2f20f3b91d258bf8ccc8cf62023935df2d2676b5b67049f31a049c") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") # We assume a reasonably recent libtool is necessary diff --git a/var/spack/repos/builtin/packages/libquo/package.py b/var/spack/repos/builtin/packages/libquo/package.py index 1c838d9c4a5097..95650df42e4614 100644 --- a/var/spack/repos/builtin/packages/libquo/package.py +++ b/var/spack/repos/builtin/packages/libquo/package.py @@ -27,6 +27,9 @@ class Libquo(AutotoolsPackage): version("1.3", sha256="61b0beff15eae4be94b5d3cbcbf7bf757659604465709ed01827cbba45efcf90") version("1.2.9", sha256="0a64bea8f52f9eecd89e4ab82fde1c5bd271f3866c612da0ce7f38049409429b") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("m4", when="@develop", type="build") diff --git a/var/spack/repos/builtin/packages/libraqm/package.py b/var/spack/repos/builtin/packages/libraqm/package.py index 745dc9f1a9002e..547931a621017a 100644 --- a/var/spack/repos/builtin/packages/libraqm/package.py +++ b/var/spack/repos/builtin/packages/libraqm/package.py @@ -17,6 +17,8 @@ class Libraqm(MesonPackage): version("0.9.0", sha256="9ed6fdf41da6391fc9bf7038662cbe412c330aa6eb22b19704af2258e448107c") + depends_on("c", type="build") # generated + variant( "bidi_algo", default="fribidi", diff --git a/var/spack/repos/builtin/packages/libraw1394/package.py b/var/spack/repos/builtin/packages/libraw1394/package.py index 89a9262f34a377..589bb96e8f65be 100644 --- a/var/spack/repos/builtin/packages/libraw1394/package.py +++ b/var/spack/repos/builtin/packages/libraw1394/package.py @@ -16,3 +16,5 @@ class Libraw1394(AutotoolsPackage): license("LGPL-2.1-or-later") version("1.2.0", sha256="1fdcfa4c5a0938705b925d06f17da9be6ec3f8f065040bb7f33082ef3fc63fad") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/librdkafka/package.py b/var/spack/repos/builtin/packages/librdkafka/package.py index 53cb81e2f8d717..dbc42080596d39 100644 --- a/var/spack/repos/builtin/packages/librdkafka/package.py +++ b/var/spack/repos/builtin/packages/librdkafka/package.py @@ -24,5 +24,8 @@ class Librdkafka(AutotoolsPackage): version("1.4.4", sha256="0984ffbe17b9e04599fb9eceb16cfa189f525a042bef02474cd1bbfe1ea68416") version("1.4.2", sha256="3b99a36c082a67ef6295eabd4fb3e32ab0bff7c6b0d397d6352697335f4e57eb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zstd") depends_on("lz4") diff --git a/var/spack/repos/builtin/packages/librelp/package.py b/var/spack/repos/builtin/packages/librelp/package.py index 3113da14f317e9..a3d0a468e73854 100644 --- a/var/spack/repos/builtin/packages/librelp/package.py +++ b/var/spack/repos/builtin/packages/librelp/package.py @@ -20,6 +20,8 @@ class Librelp(AutotoolsPackage): version("1.6.0", sha256="acaaa6b8e295ecd8e9d9b70c1c3c8fb3cc3c95a9ed5ce1689688510d0eecb37e") version("1.5.0", sha256="ce7f463944417ba77d7b586590e41e276f7b107d3e35a77ce768cf3889b5e1a6") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libreproc/package.py b/var/spack/repos/builtin/packages/libreproc/package.py index 353819c54d4831..2c98bcdea8451d 100644 --- a/var/spack/repos/builtin/packages/libreproc/package.py +++ b/var/spack/repos/builtin/packages/libreproc/package.py @@ -18,6 +18,9 @@ class Libreproc(CMakePackage): version("14.2.4", sha256="55c780f7faa5c8cabd83ebbb84b68e5e0e09732de70a129f6b3c801e905415dd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cxx", default=False, description="Build reproc C++ bindings") variant("shared", default=True, description="Build shared libraries") diff --git a/var/spack/repos/builtin/packages/libressl/package.py b/var/spack/repos/builtin/packages/libressl/package.py index fbdf8a956d8f90..6946c0c66efc28 100644 --- a/var/spack/repos/builtin/packages/libressl/package.py +++ b/var/spack/repos/builtin/packages/libressl/package.py @@ -22,6 +22,8 @@ class Libressl(AutotoolsPackage): version("3.6.3", sha256="87b1bbe36e9eec8d0ae5f04c83d36b2c5b0e581784c7eb0817025ed29eadea37") version("3.6.1", sha256="acfac61316e93b919c28d62d53037ca734de85c46b4d703f19fd8395cf006774") + depends_on("c", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("static", default=False, description="Build static libraries") diff --git a/var/spack/repos/builtin/packages/libristra/package.py b/var/spack/repos/builtin/packages/libristra/package.py index 74eb576d0b0bcc..bf884b47ffd74d 100644 --- a/var/spack/repos/builtin/packages/libristra/package.py +++ b/var/spack/repos/builtin/packages/libristra/package.py @@ -20,14 +20,16 @@ class Libristra(CMakePackage): version("master", branch="master", submodules=False, preferred=True) version("1.0.0", commit="33235fe0334ca7f1f99b386a90932d9f8e1e71de") + depends_on("cxx", type="build") # generated + variant("paraview", default=False, description="Enable ParaView") variant("shared_lua", default=False, description="Build with shared lua") depends_on("cmake@3.12:") depends_on("mpi") depends_on("boost@1.70.0: cxxstd=17 +program_options") - depends_on("lua@5.3.5~shared", when="~shared_lua") - depends_on("lua@5.3.5+shared", when="+shared_lua") + depends_on("lua@5.3.5:~shared", when="~shared_lua") + depends_on("lua@5.3.5:+shared", when="+shared_lua") # TODO: might want to move paraview out of libristra depends_on("paraview", when="+paraview") # We explicitly depend on gtest and can no longer rely on others for it diff --git a/var/spack/repos/builtin/packages/librmm/package.py b/var/spack/repos/builtin/packages/librmm/package.py index e7804ae2b40656..3adab29f30de7d 100644 --- a/var/spack/repos/builtin/packages/librmm/package.py +++ b/var/spack/repos/builtin/packages/librmm/package.py @@ -19,4 +19,6 @@ class Librmm(CMakePackage): version("24.02.00", sha256="63ddde8788727f0989f6397aed8a007ef414a577417b7d3cf39ca670c1bc4a91") version("0.15.0", sha256="599f97b95d169a90d11296814763f7e151a8a1e060ba10bc6c8f4684a5cd7972") + depends_on("cxx", type="build") # generated + depends_on("cuda@9.0:") diff --git a/var/spack/repos/builtin/packages/librom/package.py b/var/spack/repos/builtin/packages/librom/package.py index b46c9e0976bb40..1a95b3116fb10a 100644 --- a/var/spack/repos/builtin/packages/librom/package.py +++ b/var/spack/repos/builtin/packages/librom/package.py @@ -17,6 +17,10 @@ class Librom(AutotoolsPackage): version("develop", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("lapack") depends_on("mpi") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/librsb/package.py b/var/spack/repos/builtin/packages/librsb/package.py index 18cccd064f30ec..f9ba660f88dcce 100644 --- a/var/spack/repos/builtin/packages/librsb/package.py +++ b/var/spack/repos/builtin/packages/librsb/package.py @@ -24,6 +24,10 @@ class Librsb(AutotoolsPackage): version("1.2.0.9", sha256="f421f5d572461601120933e3c1cfee2ca69e6ecc92cbb11baa4e86bdedd3d9fa") version("1.2.0.8", sha256="8bebd19a1866d80ade13eabfdd0f07ae7e8a485c0b975b5d15f531ac204d80cb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("zlib-api") depends_on("googletest", type="build", when="+googletest") conflicts("%apple-clang") diff --git a/var/spack/repos/builtin/packages/librsvg/package.py b/var/spack/repos/builtin/packages/librsvg/package.py index 93ec2e714683a1..71a0a90d75d641 100644 --- a/var/spack/repos/builtin/packages/librsvg/package.py +++ b/var/spack/repos/builtin/packages/librsvg/package.py @@ -18,9 +18,12 @@ class Librsvg(AutotoolsPackage): version("2.51.0", sha256="89d32e38445025e1b1d9af3dd9d3aeb9f6fce527aeecbecf38b369b34c80c038") version("2.50.2", sha256="6211f271ce4cd44a7318190d36712e9cea384a933d3e3570004edeb210a056d3") version("2.50.0", sha256="b3fadba240f09b9c9898ab20cb7311467243e607cf8f928b7c5f842474ee3df4") + version("2.44.17", sha256="91bea64669203c677d5efbe21175aabbadf36754c7e7a1d1dc016dff4425273b") version("2.44.14", sha256="6a85a7868639cdd4aa064245cc8e9d864dad8b8e9a4a8031bb09a4796bc4e303") version("2.40.21", sha256="f7628905f1cada84e87e2b14883ed57d8094dca3281d5bcb24ece4279e9a92ba") + depends_on("c", type="build") # generated + variant("doc", default=False, description="Build documentation with gtk-doc") depends_on("gobject-introspection", type="build") @@ -49,6 +52,7 @@ class Librsvg(AutotoolsPackage): depends_on("libffi") depends_on("shared-mime-info") + depends_on("py-docutils", type="build") def url_for_version(self, version): url = "https://download.gnome.org/sources/librsvg/" diff --git a/var/spack/repos/builtin/packages/librtlsdr/package.py b/var/spack/repos/builtin/packages/librtlsdr/package.py index 0eaed4a6d0954d..5a8258fb408845 100644 --- a/var/spack/repos/builtin/packages/librtlsdr/package.py +++ b/var/spack/repos/builtin/packages/librtlsdr/package.py @@ -17,4 +17,6 @@ class Librtlsdr(CMakePackage): version("0.6.0", sha256="80a5155f3505bca8f1b808f8414d7dcd7c459b662a1cde84d3a2629a6e72ae55") version("0.5.4", sha256="6fd0d298c1a18fc8005b0c2f6199b08bc15e3fb4f4312f551eea2ae269c940c5") + depends_on("c", type="build") # generated + depends_on("libusb") diff --git a/var/spack/repos/builtin/packages/librttopo/package.py b/var/spack/repos/builtin/packages/librttopo/package.py index 082ca655c3c23d..79ef2f6236b38e 100644 --- a/var/spack/repos/builtin/packages/librttopo/package.py +++ b/var/spack/repos/builtin/packages/librttopo/package.py @@ -20,6 +20,8 @@ class Librttopo(AutotoolsPackage): version("1.1.0", sha256="2e2fcabb48193a712a6c76ac9a9be2a53f82e32f91a2bc834d9f1b4fa9cd879f") + depends_on("c", type="build") # generated + depends_on("geos") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/libsakura/package.py b/var/spack/repos/builtin/packages/libsakura/package.py index 788327f3fa9529..42ed11da53592a 100644 --- a/var/spack/repos/builtin/packages/libsakura/package.py +++ b/var/spack/repos/builtin/packages/libsakura/package.py @@ -20,6 +20,9 @@ class Libsakura(CMakePackage): version("4.0.2065", sha256="3fde3713b1ca539f0b2397ec72a0086a3138ef63f89dce4be51ee60585df995f") version("3.0.2025", sha256="381a49d57cbc88dea15e08f7ed64ba57481d25bce8e5f68938dd4b6a30589c16") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8:", type="build") depends_on("eigen@3.2:") diff --git a/var/spack/repos/builtin/packages/libsamplerate/package.py b/var/spack/repos/builtin/packages/libsamplerate/package.py index 35fc19520b2080..d2c5be4cd6c163 100644 --- a/var/spack/repos/builtin/packages/libsamplerate/package.py +++ b/var/spack/repos/builtin/packages/libsamplerate/package.py @@ -18,6 +18,8 @@ class Libsamplerate(AutotoolsPackage): version("0.1.9", sha256="0a7eb168e2f21353fb6d84da152e4512126f7dc48ccb0be80578c565413444c1") version("0.1.8", sha256="93b54bdf46d5e6d2354b7034395fe329c222a966790de34520702bb9642f1c06") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/libseccomp/package.py b/var/spack/repos/builtin/packages/libseccomp/package.py index 8b87dbff48f165..0dc52a6e62abe0 100644 --- a/var/spack/repos/builtin/packages/libseccomp/package.py +++ b/var/spack/repos/builtin/packages/libseccomp/package.py @@ -18,6 +18,8 @@ class Libseccomp(AutotoolsPackage): version("2.5.3", sha256="59065c8733364725e9721ba48c3a99bbc52af921daf48df4b1e012fbc7b10a76") version("2.3.3", sha256="7fc28f4294cc72e61c529bedf97e705c3acf9c479a8f1a3028d4cd2ca9f3b155") + depends_on("c", type="build") # generated + variant("python", default=True, description="Build Python bindings") depends_on("gperf", type="build", when="@2.5:") diff --git a/var/spack/repos/builtin/packages/libsecret/package.py b/var/spack/repos/builtin/packages/libsecret/package.py index ba7c8aa26584c1..91c79ed634f1c2 100644 --- a/var/spack/repos/builtin/packages/libsecret/package.py +++ b/var/spack/repos/builtin/packages/libsecret/package.py @@ -22,6 +22,8 @@ class Libsecret(AutotoolsPackage): version("0.18.8", sha256="3bfa889d260e0dbabcf5b9967f2aae12edcd2ddc9adc365de7a5cc840c311d15") + depends_on("c", type="build") # generated + variant("gcrypt", default=True, description="Build with libgcrypt") variant("gobj", default=False, description="Build with gobject-introspection") # Optional Vala support is not implemented yet diff --git a/var/spack/repos/builtin/packages/libsharp/package.py b/var/spack/repos/builtin/packages/libsharp/package.py index 482439306a8845..e6464dc88486f9 100644 --- a/var/spack/repos/builtin/packages/libsharp/package.py +++ b/var/spack/repos/builtin/packages/libsharp/package.py @@ -23,6 +23,9 @@ class Libsharp(AutotoolsPackage): version("1.0.0", commit="cc4753ff4b0ef393f0d4ada41a175c6d1dd85d71", preferred=True) version("2018-01-17", commit="593d4eba67d61827191c32fb94bf235cb31205e1") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin/packages/libshm/package.py b/var/spack/repos/builtin/packages/libshm/package.py index 6bbe6cd94e602e..c55fce1cc67723 100644 --- a/var/spack/repos/builtin/packages/libshm/package.py +++ b/var/spack/repos/builtin/packages/libshm/package.py @@ -17,5 +17,7 @@ class Libshm(Package): version("master") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): install_tree("include", prefix.include) diff --git a/var/spack/repos/builtin/packages/libsigcpp/package.py b/var/spack/repos/builtin/packages/libsigcpp/package.py index 318851ac097d88..f8e047a285d6ce 100644 --- a/var/spack/repos/builtin/packages/libsigcpp/package.py +++ b/var/spack/repos/builtin/packages/libsigcpp/package.py @@ -21,6 +21,8 @@ class Libsigcpp(AutotoolsPackage): version("2.1.1", sha256="7a2bd0b521544b31051c476205a0e74ace53771ec1a939bfec3c297b50c9fd78") version("2.0.3", sha256="6ee6d5f164d8a34da33d2251cdb348b4f5769bf993ed8a6d4055bd47562f94a2") + depends_on("cxx", type="build") # generated + depends_on("m4", when="@:2.9", type="build") def url_for_version(self, version): diff --git a/var/spack/repos/builtin/packages/libsignal-protocol-c/package.py b/var/spack/repos/builtin/packages/libsignal-protocol-c/package.py index 1b3bd1c1b4ffd3..da46db56796d6e 100644 --- a/var/spack/repos/builtin/packages/libsignal-protocol-c/package.py +++ b/var/spack/repos/builtin/packages/libsignal-protocol-c/package.py @@ -17,3 +17,5 @@ class LibsignalProtocolC(CMakePackage): license("GPL-3.0-only") version("2.3.3", sha256="c22e7690546e24d46210ca92dd808f17c3102e1344cd2f9a370136a96d22319d") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libsigsegv/patch.new_config_guess b/var/spack/repos/builtin/packages/libsigsegv/new_config_guess.patch similarity index 100% rename from var/spack/repos/builtin/packages/libsigsegv/patch.new_config_guess rename to var/spack/repos/builtin/packages/libsigsegv/new_config_guess.patch diff --git a/var/spack/repos/builtin/packages/libsigsegv/package.py b/var/spack/repos/builtin/packages/libsigsegv/package.py index f2dc840891898b..253ab41b798b31 100644 --- a/var/spack/repos/builtin/packages/libsigsegv/package.py +++ b/var/spack/repos/builtin/packages/libsigsegv/package.py @@ -23,7 +23,9 @@ class Libsigsegv(AutotoolsPackage, GNUMirrorPackage): version("2.11", sha256="dd7c2eb2ef6c47189406d562c1dc0f96f2fc808036834d596075d58377e37a18") version("2.10", sha256="8460a4a3dd4954c3d96d7a4f5dd5bc4d9b76f5754196aa245287553b26d2199a") - patch("patch.new_config_guess", when="@2.10") + depends_on("c", type="build") # generated + + patch("new_config_guess.patch", when="@2.10") def configure_args(self): return ["--enable-shared"] diff --git a/var/spack/repos/builtin/packages/libsixel/package.py b/var/spack/repos/builtin/packages/libsixel/package.py index c69628f3ff3c63..2d73c9fc7d0068 100644 --- a/var/spack/repos/builtin/packages/libsixel/package.py +++ b/var/spack/repos/builtin/packages/libsixel/package.py @@ -19,6 +19,9 @@ class Libsixel(MesonPackage): version("1.10.3", sha256="028552eb8f2a37c6effda88ee5e8f6d87b5d9601182ddec784a9728865f821e0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("img2sixel", default=True, description="build binary img2sixel") variant("sixel2png", default=True, description="build binary sixel2png") variant("gd", default=True, description="build with libgd") diff --git a/var/spack/repos/builtin/packages/libslirp/package.py b/var/spack/repos/builtin/packages/libslirp/package.py index cb75c8bcf87710..da3dc9c424d147 100644 --- a/var/spack/repos/builtin/packages/libslirp/package.py +++ b/var/spack/repos/builtin/packages/libslirp/package.py @@ -18,5 +18,7 @@ class Libslirp(MesonPackage): version("4.7.0", sha256="9398f0ec5a581d4e1cd6856b88ae83927e458d643788c3391a39e61b75db3d3b") version("4.6.1", sha256="69ad4df0123742a29cc783b35de34771ed74d085482470df6313b6abeb799b11") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("glib") diff --git a/var/spack/repos/builtin/packages/libsm/package.py b/var/spack/repos/builtin/packages/libsm/package.py index 6f89ff6d3dfc9c..eaa0858a9e480e 100644 --- a/var/spack/repos/builtin/packages/libsm/package.py +++ b/var/spack/repos/builtin/packages/libsm/package.py @@ -20,6 +20,8 @@ class Libsm(AutotoolsPackage, XorgPackage): version("1.2.3", sha256="1e92408417cb6c6c477a8a6104291001a40b3bb56a4a60608fdd9cd2c5a0f320") version("1.2.2", sha256="14bb7c669ce2b8ff712fbdbf48120e3742a77edcd5e025d6b3325ed30cf120f4") + depends_on("c", type="build") # generated + depends_on("libice@1.1.0:", when="@1.2.4:") depends_on("libice@1.0.5:") depends_on("uuid") diff --git a/var/spack/repos/builtin/packages/libsndfile/package.py b/var/spack/repos/builtin/packages/libsndfile/package.py index 031517c7552fca..9e262ca91253f5 100644 --- a/var/spack/repos/builtin/packages/libsndfile/package.py +++ b/var/spack/repos/builtin/packages/libsndfile/package.py @@ -19,6 +19,9 @@ class Libsndfile(AutotoolsPackage): version("1.0.28", sha256="1ff33929f042fa333aed1e8923aa628c3ee9e1eb85512686c55092d1e5a9dfa9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("alsa", default=False, description="Use alsa in example programs") variant( "external-libs", default=False, description="Build with support for FLAC, Ogg and Vorbis" diff --git a/var/spack/repos/builtin/packages/libsodium/package.py b/var/spack/repos/builtin/packages/libsodium/package.py index bd16c1e548f6f8..10ae833ad1fa2e 100644 --- a/var/spack/repos/builtin/packages/libsodium/package.py +++ b/var/spack/repos/builtin/packages/libsodium/package.py @@ -15,11 +15,15 @@ class Libsodium(AutotoolsPackage): decryption, signatures, password hashing and more.""" homepage = "https://download.libsodium.org/doc/" - url = "https://download.libsodium.org/libsodium/releases/libsodium-1.0.13.tar.gz" - list_url = "https://download.libsodium.org/libsodium/releases/old" + url = "https://github.com/jedisct1/libsodium/releases/download/1.0.19-RELEASE/libsodium-1.0.19.tar.gz" + git = "https://github.com/jedisct1/libsodium.git" license("ISC") + version("master", branch="master") + version("stable", branch="stable") + version("next", branch="next") + version("1.0.19", sha256="018d79fe0a045cca07331d37bd0cb57b2e838c51bc48fd837a1472e50068bbea") version("1.0.18", sha256="6f504490b342a4f8a4c4a02fc9b866cbef8622d5df4e5452b46be121e46636c1") version("1.0.17", sha256="0cc3dae33e642cc187b5ceb467e0ad0e1b51dcba577de1190e9ffa17766ac2b1") @@ -32,13 +36,7 @@ class Libsodium(AutotoolsPackage): version("1.0.0", sha256="ced1fe3d2066953fea94f307a92f8ae41bf0643739a44309cbe43aa881dbc9a5") version("0.7.1", sha256="ef46bbb5bac263ef6d3fc00ccc11d4690aea83643412919fe15369b9870280a7") - def url_for_version(self, version): - url = "https://download.libsodium.org/libsodium/releases/" - if version < Version("1.0.16"): - url += "old/unsupported/" - elif version < Version("1.0.17"): - url += "old/" - return url + f"libsodium-{version}.tar.gz" + depends_on("c", type="build") # generated def patch(self): # Necessary on ppc64le / aarch64, because Spack tries to execute these scripts diff --git a/var/spack/repos/builtin/packages/libsolv/package.py b/var/spack/repos/builtin/packages/libsolv/package.py index c75731358ea458..bb177bf3c2aa67 100644 --- a/var/spack/repos/builtin/packages/libsolv/package.py +++ b/var/spack/repos/builtin/packages/libsolv/package.py @@ -18,6 +18,9 @@ class Libsolv(CMakePackage): version("0.7.22", sha256="968aef452b5493751fa0168cd58745a77c755e202a43fe8d549d791eb16034d5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("conda", default=False, description="Include solv/conda.h") diff --git a/var/spack/repos/builtin/packages/libspatialindex/package.py b/var/spack/repos/builtin/packages/libspatialindex/package.py index 0f59f80bcb5fb8..3504012bfe9a23 100644 --- a/var/spack/repos/builtin/packages/libspatialindex/package.py +++ b/var/spack/repos/builtin/packages/libspatialindex/package.py @@ -17,6 +17,8 @@ class Libspatialindex(CMakePackage): version("1.9.3", sha256="7b44340a3edc55c11abfc453bb60f148b29f569cef9e1148583e76132e9c7379") version("1.8.5", sha256="93cce77269612f45287b521d5afdfb245be2b93b8b6438d92f8b9e0bdb37059d") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.5.0:", type="build") @property diff --git a/var/spack/repos/builtin/packages/libspatialite/package.py b/var/spack/repos/builtin/packages/libspatialite/package.py index 81d68e3746e197..b6643e4ade52cc 100644 --- a/var/spack/repos/builtin/packages/libspatialite/package.py +++ b/var/spack/repos/builtin/packages/libspatialite/package.py @@ -34,6 +34,8 @@ class Libspatialite(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("freexl") depends_on("freexl@2:", when="@5.1:") diff --git a/var/spack/repos/builtin/packages/libspiro/package.py b/var/spack/repos/builtin/packages/libspiro/package.py index 99dc733c5eded9..119839ab547292 100644 --- a/var/spack/repos/builtin/packages/libspiro/package.py +++ b/var/spack/repos/builtin/packages/libspiro/package.py @@ -19,6 +19,8 @@ class Libspiro(AutotoolsPackage): version("20200505", sha256="00be530b5c0ea9274baadf6c05521f0b192d4c3c1db636ac8b08efd44aaea8f5") version("20190731", sha256="24c7d1ccc7c7fe44ff10c376aa9f96e20e505f417ee72b63dc91a9b34eeac354") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libsplash/package.py b/var/spack/repos/builtin/packages/libsplash/package.py index b431a80f357fc9..3ece876675a9c2 100644 --- a/var/spack/repos/builtin/packages/libsplash/package.py +++ b/var/spack/repos/builtin/packages/libsplash/package.py @@ -31,6 +31,8 @@ class Libsplash(CMakePackage): version("1.3.1", sha256="6ad04261e6d377a59b209f345af56405b37830f0dcfac28770b63091bff59383") version("1.2.4", sha256="f5c4f792fee5609ede6a7d2fee5fa5799d3b68e8cdc23001a3aba390394d2f36") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Enable parallel I/O (one-file aggregation) support") depends_on("cmake@3.10.0:", type="build", when="@1.7.0:") diff --git a/var/spack/repos/builtin/packages/libspng/package.py b/var/spack/repos/builtin/packages/libspng/package.py index feb58288b94b89..4849cb93dbe72d 100644 --- a/var/spack/repos/builtin/packages/libspng/package.py +++ b/var/spack/repos/builtin/packages/libspng/package.py @@ -18,3 +18,6 @@ class Libspng(CMakePackage): version("0.7.4", sha256="47ec02be6c0a6323044600a9221b049f63e1953faf816903e7383d4dc4234487") version("0.7.2", sha256="4acf25571d31f540d0b7ee004f5461d68158e0a13182505376805da99f4ccc4e") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libssh/package.py b/var/spack/repos/builtin/packages/libssh/package.py index 8bd652d384dd03..d79d02d826ee12 100644 --- a/var/spack/repos/builtin/packages/libssh/package.py +++ b/var/spack/repos/builtin/packages/libssh/package.py @@ -16,6 +16,9 @@ class Libssh(CMakePackage): version("0.8.5", sha256="07d2c431240fc88f6b06bcb36ae267f9afeedce2e32f6c42f8844b205ab5a335") version("0.7.5", sha256="54e86dd5dc20e5367e58f3caab337ce37675f863f80df85b6b1614966a337095") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("gssapi", default=True, description="Build with gssapi support") depends_on("openssl@:1.0", when="@:0.7") depends_on("openssl") diff --git a/var/spack/repos/builtin/packages/libssh2/package.py b/var/spack/repos/builtin/packages/libssh2/package.py index 3a66e97f180f18..23dc57ce2deaff 100644 --- a/var/spack/repos/builtin/packages/libssh2/package.py +++ b/var/spack/repos/builtin/packages/libssh2/package.py @@ -23,6 +23,9 @@ class Libssh2(AutotoolsPackage, CMakePackage): "1.4.3", sha256="eac6f85f9df9db2e6386906a6227eb2cd7b3245739561cad7d6dc1d5d021b96d" ) # CentOS7 + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_system("autotools", "cmake", default="autotools") variant( diff --git a/var/spack/repos/builtin/packages/libstdcompat/package.py b/var/spack/repos/builtin/packages/libstdcompat/package.py index 279cd3367a38be..c9ccf77a0dee6d 100644 --- a/var/spack/repos/builtin/packages/libstdcompat/package.py +++ b/var/spack/repos/builtin/packages/libstdcompat/package.py @@ -16,6 +16,9 @@ class Libstdcompat(CMakePackage): maintainers("robertu94") version("master", branch="master") + version("0.0.21", sha256="67cfd57080a74752b4c239e031cc44734286589a89bb1cd51a8bd7039f87a3f3") + version("0.0.20", sha256="9fdc632eb135f57132953b512d8f9101e8eb4e6a88e6c3b838aaa9c51a2dbfd6") + version("0.0.19", sha256="584ee52b1f82671e5d8fde786c46aa7e98d30104674c6f4b75dbae8d83b13f21") version("0.0.17", sha256="8c8a3f2727dd28c51ab10e02a1114e39b683d6d9ea119d5c2a953f8c41d6bedd") version("0.0.16", sha256="1287251b694adb80210536ab6eb75c1ff2c4ed8b77023208a757ae27c9dae0bb") version("0.0.15", sha256="af374a8883a32d874f6cd18cce4e4344e32f9d60754be403a5ac7114feca2a28") @@ -34,9 +37,11 @@ class Libstdcompat(CMakePackage): version("0.0.2", sha256="36424399e649be38bdb21899aa45f94aebba25c66048bab2751b1b3b9fd27238") version("0.0.1", sha256="3d63e901f4e20b9032a67086f4b4281f641ee0dea436cf15f7058faa40d8637b") + depends_on("cxx", type="build") # generated + variant( "cpp_compat", - values=("11", "14", "17", "20", "auto"), + values=("11", "14", "17", "20", "23", "auto"), default="auto", multi=False, description="version of the c++ standard to use and depend on", @@ -57,6 +62,17 @@ class Libstdcompat(CMakePackage): conflicts("cpp_compat=20", when="@:0.0.7") def max_cxx_version(self): + if self.spec.version >= Version("0.0.20"): + try: + self.compiler.cxx23_flag + return "23" + except Exception: + pass + try: + self.compiler.cxx20_flag + return "20" + except Exception: + pass try: self.compiler.cxx17_flag return "17" @@ -93,8 +109,3 @@ def cmake_args(self): else: args.append("-DBUILD_TESTING=OFF") return args - - @run_after("build") - @on_package_attributes(run_tests=True) - def test(self): - make("test") diff --git a/var/spack/repos/builtin/packages/libsvm/package.py b/var/spack/repos/builtin/packages/libsvm/package.py index 8d1089337fe870..bc3506f206b64c 100644 --- a/var/spack/repos/builtin/packages/libsvm/package.py +++ b/var/spack/repos/builtin/packages/libsvm/package.py @@ -18,6 +18,9 @@ class Libsvm(MakefilePackage): version("323", sha256="7a466f90f327a98f8ed1cb217570547bcb00077933d1619f3cb9e73518f38196") version("322", sha256="a3469436f795bb3f8b1e65ea761e14e5599ec7ee941c001d771c07b7da318ac6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) mkdirp(prefix.lib) diff --git a/var/spack/repos/builtin/packages/libszip/package.py b/var/spack/repos/builtin/packages/libszip/package.py index 2aa2974fc40943..107c821272a567 100644 --- a/var/spack/repos/builtin/packages/libszip/package.py +++ b/var/spack/repos/builtin/packages/libszip/package.py @@ -24,6 +24,8 @@ class Libszip(AutotoolsPackage): version("2.1.1", sha256="21ee958b4f2d4be2c9cabfa5e1a94877043609ce86fde5f286f105f7ff84d412") version("2.1", sha256="a816d95d5662e8279625abdbea7d0e62157d7d1f028020b1075500bf483ed5ef") + depends_on("c", type="build") # generated + @property def libs(self): shared = "static" not in self.spec.last_query.extra_parameters diff --git a/var/spack/repos/builtin/packages/libtar/package.py b/var/spack/repos/builtin/packages/libtar/package.py index bf5757ab7242c0..ada56da6ac5cb9 100644 --- a/var/spack/repos/builtin/packages/libtar/package.py +++ b/var/spack/repos/builtin/packages/libtar/package.py @@ -17,6 +17,8 @@ class Libtar(AutotoolsPackage): version("1.2.19", sha256="5fea7152106b1b8cda109da27f505439865dd196da94f503fab18264591ddf64") version("1.2.18", sha256="a5ac82dae9677b5b74333ed63043b9699c7ef561e2eacf301188c277952d4b7d") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libtasn1/package.py b/var/spack/repos/builtin/packages/libtasn1/package.py index 07abb9199d97e6..3d7719b11f8954 100644 --- a/var/spack/repos/builtin/packages/libtasn1/package.py +++ b/var/spack/repos/builtin/packages/libtasn1/package.py @@ -29,6 +29,8 @@ class Libtasn1(Package): version("4.1", sha256="60ee6571dcfa00cf55406404912274d6dc759cbaa80d666b89d819feeff5f301") version("4.0", sha256="41d044f7644bdd1c4f8a5c15ac1885ca1fcbf32f5f6dd4760a19278b979857fe") + depends_on("c", type="build") # generated + def install(self, spec, prefix): configure( "--disable-dependency-tracking", diff --git a/var/spack/repos/builtin/packages/libtermkey/package.py b/var/spack/repos/builtin/packages/libtermkey/package.py index 817438a516c64d..253826b6200fa4 100644 --- a/var/spack/repos/builtin/packages/libtermkey/package.py +++ b/var/spack/repos/builtin/packages/libtermkey/package.py @@ -21,6 +21,8 @@ class Libtermkey(MakefilePackage): version("0.15b", sha256="6825422c6297e4f81b2c48962b4512585ca8a50bf31f24b3234a1be71a9d7a6e") version("0.14", sha256="3d114d4509499b80a583ea39cd35f18268aacf4a7bbf56c142cd032632005c79") + depends_on("c", type="build") # generated + depends_on("gzip", type="build") depends_on("libtool", type="build") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/libthai/package.py b/var/spack/repos/builtin/packages/libthai/package.py index 5ae2db3dbd9fa0..ff0233a466502d 100644 --- a/var/spack/repos/builtin/packages/libthai/package.py +++ b/var/spack/repos/builtin/packages/libthai/package.py @@ -22,5 +22,7 @@ class Libthai(AutotoolsPackage): version("0.1.28", sha256="ffe0a17b4b5aa11b153c15986800eca19f6c93a4025ffa5cf2cab2dcdf1ae911") version("0.1.27", sha256="1659fa1b7b1d6562102d7feb8c8c3fd94bb2dc5761ed7dbaae4f300e1c03eff6") + depends_on("c", type="build") # generated + depends_on("libdatrie") depends_on("doxygen@1.8.8:", type="build") diff --git a/var/spack/repos/builtin/packages/libtheora/package.py b/var/spack/repos/builtin/packages/libtheora/package.py index f12f67c4607921..a6aede4da7172f 100644 --- a/var/spack/repos/builtin/packages/libtheora/package.py +++ b/var/spack/repos/builtin/packages/libtheora/package.py @@ -26,6 +26,8 @@ class Libtheora(AutotoolsPackage, MSBuildPackage): version("1.1.1", sha256="f36da409947aa2b3dcc6af0a8c2e3144bc19db2ed547d64e9171c59c66561c61") version("1.1.0", sha256="3d7b4fb1c115f1a530afd430eed2e8861fa57c8b179ec2d5a5d8f1cd0c7a4268") + depends_on("c", type="build") # generated + variant("doc", default=False, description="Build documentation") depends_on("doxygen", when="+doc", type="build") @@ -76,12 +78,6 @@ def configure_args(self): args += ["LIBS=-lm"] return args - def autoreconf(self, pkg, spec, prefix): - sh = which("sh") - # arguments are passed on to configure, let it just print its version - # and exit, so that configure can run in the configure build phase - sh("./autogen.sh", "-V") - class MSBuildBuilder(MSBuildBuilder): def is_64bit(self): diff --git a/var/spack/repos/builtin/packages/libtiff/package.py b/var/spack/repos/builtin/packages/libtiff/package.py index 8bd59a30f625de..2b1778292653e0 100644 --- a/var/spack/repos/builtin/packages/libtiff/package.py +++ b/var/spack/repos/builtin/packages/libtiff/package.py @@ -40,6 +40,7 @@ class Libtiff(CMakePackage, AutotoolsPackage): license("libtiff") + version("4.6.0", sha256="88b3979e6d5c7e32b50d7ec72fb15af724f6ab2cbf7e10880c360a77e4b5d99a") version("4.5.1", sha256="d7f38b6788e4a8f5da7940c5ac9424f494d8a79eba53d555f4a507167dca5e2b") version("4.5.0", sha256="c7a1d9296649233979fa3eacffef3fa024d73d05d589cb622727b5b08c423464") version("4.4.0", sha256="917223b37538959aca3b790d2d73aa6e626b688e02dcda272aec24c2f498abed") @@ -55,6 +56,17 @@ class Libtiff(CMakePackage, AutotoolsPackage): version("4.0.4", sha256="8cb1d90c96f61cdfc0bcf036acc251c9dbe6320334da941c7a83cfe1576ef890") version("3.9.7", sha256="f5d64dd4ce61c55f5e9f6dc3920fbe5a41e02c2e607da7117a35eb5c320cef6a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + # GUI + variant( + "opengl", + default=False, + description="use OpenGL (required for tiffgt viewer)", + when="@4.5,4.7:", + ) + # Internal codecs variant("ccitt", default=True, description="support for CCITT Group 3 & 4 algorithms") variant("packbits", default=True, description="support for Macintosh PackBits algorithm") @@ -118,6 +130,7 @@ class CMakeBuilder(CMakeBuilder): def cmake_args(self): args = [self.define_from_variant(var) for var in VARIANTS] args.append("-Dsphinx=OFF") + args += [self.define_from_variant("tiff-opengl", "opengl")] args += [self.define_from_variant("BUILD_SHARED_LIBS", "shared")] args += [self.define_from_variant("CMAKE_POSITION_INDEPENDENT_CODE", "pic")] @@ -135,6 +148,7 @@ def configure_args(self): args.append("--disable-sphinx") + args.extend(self.enable_or_disable("opengl")) args.extend(self.enable_or_disable("shared")) args.extend(self.with_or_without("pic")) diff --git a/var/spack/repos/builtin/packages/libtirpc/package.py b/var/spack/repos/builtin/packages/libtirpc/package.py index e2f3b307dc8825..f401636a8069c0 100644 --- a/var/spack/repos/builtin/packages/libtirpc/package.py +++ b/var/spack/repos/builtin/packages/libtirpc/package.py @@ -18,6 +18,8 @@ class Libtirpc(AutotoolsPackage): version("1.2.6", sha256="4278e9a5181d5af9cd7885322fdecebc444f9a3da87c526e7d47f7a12a37d1cc") version("1.1.4", sha256="2ca529f02292e10c158562295a1ffd95d2ce8af97820e3534fe1b0e3aec7561d") + depends_on("c", type="build") # generated + depends_on("krb5") provides("rpc") diff --git a/var/spack/repos/builtin/packages/libtlx/package.py b/var/spack/repos/builtin/packages/libtlx/package.py index 8c852a11c2919d..5a4e64f6c2b63e 100644 --- a/var/spack/repos/builtin/packages/libtlx/package.py +++ b/var/spack/repos/builtin/packages/libtlx/package.py @@ -34,3 +34,5 @@ class Libtlx(CMakePackage): version( "0.5.20191212", sha256="5e67d3042a390dbb831b6d46437e3c7fadf738bff362aa7376b210b10ecd532d" ) + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libtomlc99/package.py b/var/spack/repos/builtin/packages/libtomlc99/package.py index c1cef890bd37a6..5f3ed20bc79420 100644 --- a/var/spack/repos/builtin/packages/libtomlc99/package.py +++ b/var/spack/repos/builtin/packages/libtomlc99/package.py @@ -28,6 +28,8 @@ class Libtomlc99(Package): # Does not build shared libraries. version("0.2019.03.06", commit="bd76f1276ee5f5df0eb064f1842af5ad1737cf1e") + depends_on("c", type="build") # generated + variant("debug", default=False, description="Build with debug enabled.") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/libtommath/package.py b/var/spack/repos/builtin/packages/libtommath/package.py index 6573ce7b80bf43..0eb2dae2999dc8 100644 --- a/var/spack/repos/builtin/packages/libtommath/package.py +++ b/var/spack/repos/builtin/packages/libtommath/package.py @@ -14,9 +14,12 @@ class Libtommath(MakefilePackage): license("Unlicense") + version("1.3.0", sha256="6d099e93ff00fa9b18346f4bcd97dcc48c3e91286f7e16c4ac5515a7171c3149") version("1.2.1", sha256="068adaf5155d28d4ac976eb95ea0df1ecb362f20d777287154c22a24fdb35faa") version("1.2.0", sha256="f3c20ab5df600d8d89e054d096c116417197827d12732e678525667aa724e30f") version("1.1.0", sha256="71b6f3f99341b7693393ab4b58f03b79b6afc2ee5288666cc4538b4b336355f4") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make(f"DESTDIR={prefix}", "LIBPATH=/lib", "INCPATH=/include", "install") diff --git a/var/spack/repos/builtin/packages/libtool/package.py b/var/spack/repos/builtin/packages/libtool/package.py index d5926669e4fe17..1547aa6764d96d 100644 --- a/var/spack/repos/builtin/packages/libtool/package.py +++ b/var/spack/repos/builtin/packages/libtool/package.py @@ -32,6 +32,8 @@ class Libtool(AutotoolsPackage, GNUMirrorPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("m4@1.4.6:", type="build") # the following are places in which libtool depends on findutils diff --git a/var/spack/repos/builtin/packages/libtorrent/package.py b/var/spack/repos/builtin/packages/libtorrent/package.py index 900cdf59c6a5bb..4160c7febb5465 100644 --- a/var/spack/repos/builtin/packages/libtorrent/package.py +++ b/var/spack/repos/builtin/packages/libtorrent/package.py @@ -17,6 +17,8 @@ class Libtorrent(AutotoolsPackage): version("0.13.8", sha256="0f6c2e7ffd3a1723ab47fdac785ec40f85c0a5b5a42c1d002272205b988be722") + depends_on("cxx", type="build") # generated + def autoreconf(self, spec, prefix): bash = which("bash") bash("./autogen.sh") diff --git a/var/spack/repos/builtin/packages/libtraceevent/package.py b/var/spack/repos/builtin/packages/libtraceevent/package.py new file mode 100644 index 00000000000000..4f3e736e636e3a --- /dev/null +++ b/var/spack/repos/builtin/packages/libtraceevent/package.py @@ -0,0 +1,50 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Libtraceevent(MakefilePackage): + """Library to parse raw trace event formats.""" + + homepage = "https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git" + url = "https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git/snapshot/libtraceevent-1.8.2.tar.gz" + git = "https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git" + + maintainers("Jordan474") + + license("LGPL-2.1-or-later AND GPL-2.0-or-later") + + version("1.8.2", sha256="919f0c024c7b5059eace52d854d4df00ae7e361a4033e1b4d6fe01d97064a1b9") + + variant("doc", default=False, description="Build documentation") + + depends_on("c", type="build") + depends_on("asciidoc", when="+doc", type="build") + depends_on("xmlto", when="+doc", type="build") + + def patch(self): + set_executable("Documentation/install-docs.sh.in") + + @property + def common_targets(self): + return [ + "prefix=" + self.prefix, + "pkgconfig_dir=" + join_path(self.prefix.lib, "pkgconfig"), + ] + + @property + def build_targets(self): + result = self.common_targets + ["all"] + if "+doc" in self.spec: + result.append("doc") + return result + + @property + def install_targets(self): + result = self.common_targets + ["install"] + if "+doc" in self.spec: + result.append("doc-install") + return result diff --git a/var/spack/repos/builtin/packages/libtree/package.py b/var/spack/repos/builtin/packages/libtree/package.py index 85eff7b2c8a3b1..3e956cec52c366 100644 --- a/var/spack/repos/builtin/packages/libtree/package.py +++ b/var/spack/repos/builtin/packages/libtree/package.py @@ -38,6 +38,8 @@ class Libtree(MakefilePackage, CMakePackage): version("1.0.4", sha256="b15a54b6f388b8bd8636e288fcb581029f1e65353660387b0096a554ad8e9e45") version("1.0.3", sha256="67ce886c191d50959a5727246cdb04af38872cd811c9ed4e3822f77a8f40b20b") + depends_on("c", type="build") # generated + build_system( conditional("cmake", when="@:2"), conditional("makefile", when="@3:"), default="makefile" ) diff --git a/var/spack/repos/builtin/packages/libuecc/package.py b/var/spack/repos/builtin/packages/libuecc/package.py index 8f916905bae261..8191b3bba0ce46 100644 --- a/var/spack/repos/builtin/packages/libuecc/package.py +++ b/var/spack/repos/builtin/packages/libuecc/package.py @@ -17,3 +17,5 @@ class Libuecc(CMakePackage): version("7", sha256="465a6584c991c13fddf36700328c44fee9a3baff9025fb5f232b34d003d715e0") version("6", sha256="ad813abd91462a6b10608e51862a65998649651b22ab5d82f920622cc93befd7") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/libunistring/package.py b/var/spack/repos/builtin/packages/libunistring/package.py index f9091adffc3992..1a634202d51106 100644 --- a/var/spack/repos/builtin/packages/libunistring/package.py +++ b/var/spack/repos/builtin/packages/libunistring/package.py @@ -18,6 +18,7 @@ class Libunistring(AutotoolsPackage, GNUMirrorPackage): license("GPL-2.0-or-later OR LGPL-3.0-or-later") version("master", branch="master") + version("1.2", sha256="632bd65ed74a881ca8a0309a1001c428bd1cbd5cd7ddbf8cedcd2e65f4dcdc44") version("1.1", sha256="827c1eb9cb6e7c738b171745dac0888aa58c5924df2e59239318383de0729b98") version("1.0", sha256="5bab55b49f75d77ed26b257997e919b693f29fd4a1bc22e0e6e024c246c72741") version("0.9.10", sha256="eb8fb2c3e4b6e2d336608377050892b54c3c983b646c561836550863003c05d7") @@ -26,6 +27,8 @@ class Libunistring(AutotoolsPackage, GNUMirrorPackage): version("0.9.7", sha256="2e3764512aaf2ce598af5a38818c0ea23dedf1ff5460070d1b6cee5c3336e797") version("0.9.6", sha256="2df42eae46743e3f91201bf5c100041540a7704e8b9abfd57c972b2d544de41b") + depends_on("c", type="build") # generated + depends_on("iconv") with when("@master"): depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/libunwind/package.py b/var/spack/repos/builtin/packages/libunwind/package.py index c389cbda7b15e0..2360178b132500 100644 --- a/var/spack/repos/builtin/packages/libunwind/package.py +++ b/var/spack/repos/builtin/packages/libunwind/package.py @@ -31,6 +31,9 @@ class Libunwind(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("docs", default=True, description="Build man page") variant( "libs", diff --git a/var/spack/repos/builtin/packages/liburing/package.py b/var/spack/repos/builtin/packages/liburing/package.py index 7e2d433a6f6941..24b53ae1a85b9f 100644 --- a/var/spack/repos/builtin/packages/liburing/package.py +++ b/var/spack/repos/builtin/packages/liburing/package.py @@ -22,5 +22,8 @@ class Liburing(AutotoolsPackage): version("master", branch="master") version("2.3", sha256="60b367dbdc6f2b0418a6e0cd203ee0049d9d629a36706fcf91dfb9428bae23c8") - conflicts("platform=darwin", msg="Only supported on 'linux' and 'cray'") - conflicts("platform=windows", msg="Only supported on 'linux' and 'cray'") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + conflicts("platform=darwin", msg="Only supported on linux") + conflicts("platform=windows", msg="Only supported on linux") diff --git a/var/spack/repos/builtin/packages/libusb/package.py b/var/spack/repos/builtin/packages/libusb/package.py index f51e9690167de9..36fb87fcc8aad7 100644 --- a/var/spack/repos/builtin/packages/libusb/package.py +++ b/var/spack/repos/builtin/packages/libusb/package.py @@ -21,6 +21,9 @@ class Libusb(AutotoolsPackage): version("1.0.21", sha256="7dce9cce9a81194b7065ee912bcd55eeffebab694ea403ffb91b67db66b1824b") version("1.0.20", sha256="cb057190ba0a961768224e4dc6883104c6f945b2bf2ef90d7da39e7c1834f7ff") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build", when="@master") depends_on("automake", type="build", when="@master") depends_on("libtool", type="build", when="@master") diff --git a/var/spack/repos/builtin/packages/libuser/package.py b/var/spack/repos/builtin/packages/libuser/package.py index 5edc7db485b766..f8bc34807a4818 100644 --- a/var/spack/repos/builtin/packages/libuser/package.py +++ b/var/spack/repos/builtin/packages/libuser/package.py @@ -18,6 +18,8 @@ class Libuser(AutotoolsPackage): version("0.61", sha256="0a114a52446e12781e2ffdf26f59df0d14e7809c7db5e551d3cf61c4e398751d") version("0.60", sha256="b1f73408ebfee79eb01a47c5879a2cdef6a00b75ee24870de7df1b816ff483eb") + depends_on("c", type="build") # generated + depends_on("glib") depends_on("linux-pam") depends_on("popt") diff --git a/var/spack/repos/builtin/packages/libuuid/package.py b/var/spack/repos/builtin/packages/libuuid/package.py index 6fa16449cc8dae..0cc3f48ff604a7 100644 --- a/var/spack/repos/builtin/packages/libuuid/package.py +++ b/var/spack/repos/builtin/packages/libuuid/package.py @@ -12,6 +12,14 @@ class Libuuid(AutotoolsPackage, SourceforgePackage): homepage = "https://sourceforge.net/projects/libuuid/" sourceforge_mirror_path = "libuuid/libuuid-1.0.3.tar.gz" - version("1.0.3", sha256="46af3275291091009ad7f1b899de3d0cea0252737550e7919d17237997db5644") + version( + "1.0.3", + sha256="46af3275291091009ad7f1b899de3d0cea0252737550e7919d17237997db5644", + deprecated=True, + ) + + depends_on("c", type="build") # generated provides("uuid") + + conflicts("%gcc@14:") diff --git a/var/spack/repos/builtin/packages/libuv-julia/package.py b/var/spack/repos/builtin/packages/libuv-julia/package.py index 8e668ca22f8fc2..6dd7890673e2fc 100644 --- a/var/spack/repos/builtin/packages/libuv-julia/package.py +++ b/var/spack/repos/builtin/packages/libuv-julia/package.py @@ -23,6 +23,8 @@ class LibuvJulia(AutotoolsPackage): version("1.44.1", commit="1b2d16477fe1142adea952168d828a066e03ee4c") version("1.42.0", commit="3a63bf71de62c64097989254e4f03212e3bf5fc8") + depends_on("c", type="build") # generated + def autoreconf(self, spec, prefix): # @haampie: Configure files are checked in, but git does not restore # mtime by design. Therefore, touch files to avoid regenerating those. diff --git a/var/spack/repos/builtin/packages/libuv/package.py b/var/spack/repos/builtin/packages/libuv/package.py index a994fbc3e7f830..f6a5947957a670 100644 --- a/var/spack/repos/builtin/packages/libuv/package.py +++ b/var/spack/repos/builtin/packages/libuv/package.py @@ -15,6 +15,7 @@ class Libuv(AutotoolsPackage): license("MIT") + version("1.48.0", sha256="c593139feb9061699fdd2f7fde47bb6c1ca77761ae9ec04f052083f1ef46c13b") version("1.46.0", sha256="94f101111ef3209340d7f09c2aa150ddb4feabd2f9d87d47d9f5bded835b8094") version("1.45.0", sha256="3793d8c0d6fa587721d010d0555b7e82443fd4e8b3c91e529eb6607592f52b87") version("1.44.2", sha256="8ff28f6ac0d6d2a31d2eeca36aff3d7806706c7d3f5971f5ee013ddb0bdd2e9e") @@ -31,8 +32,10 @@ class Libuv(AutotoolsPackage): version("1.10.0", sha256="0307a0eec6caddd476f9cad39e18fdd6f22a08aa58103c4b0aead96d638be15e") version("1.9.0", sha256="d595b2725abcce851c76239aab038adc126c58714cfb572b2ebb2d21b3593842") + depends_on("c", type="build") # generated + def url_for_version(self, version): - if version < Version("1.44.0"): + if self.spec.satisfies("@:1.43"): url = "https://dist.libuv.org/dist/v{0}/libuv-v{0}.tar.gz" else: # From 1.44 on, the `-dist` download includes a configure script diff --git a/var/spack/repos/builtin/packages/libvdwxc/fftw-detection.patch b/var/spack/repos/builtin/packages/libvdwxc/fftw-detection.patch new file mode 100644 index 00000000000000..f009188f52c03f --- /dev/null +++ b/var/spack/repos/builtin/packages/libvdwxc/fftw-detection.patch @@ -0,0 +1,13 @@ +diff --git a/configure b/configure +index 494ea9f..1ca6516 100755 +--- a/configure ++++ b/configure +@@ -17006,7 +17006,7 @@ int + main () + { + +- fftw_plan *plan; ++ fftw_plan plan; + fftw_complex *a1, *a2; + fftw_execute_dft(plan, a1, a2); + diff --git a/var/spack/repos/builtin/packages/libvdwxc/package.py b/var/spack/repos/builtin/packages/libvdwxc/package.py index f83ccd52ee8b76..e0e7241d9516c6 100644 --- a/var/spack/repos/builtin/packages/libvdwxc/package.py +++ b/var/spack/repos/builtin/packages/libvdwxc/package.py @@ -18,6 +18,9 @@ class Libvdwxc(AutotoolsPackage): version("0.4.0", sha256="3524feb5bb2be86b4688f71653502146b181e66f3f75b8bdaf23dd1ae4a56b33") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("pfft", default=False, description="Enable support for PFFT") @@ -51,3 +54,12 @@ def configure_args(self): args += ["--without-mpi"] return args + + # misuse of fftw_plan in m4 for fftw detection (configure fails with gcc 14) + # two patches for (1) m4 macro from upstream and (2) pre-generated configure in tarball + patch( + "https://gitlab.com/libvdwxc/libvdwxc/-/commit/9340f857515c4a2e56d2aa7cf3a21c41ba8559c3.diff", + sha256="b9ad695e54a25d7ffa92f783bb0a31d3b421225f97958972e32ba42893844b80", + when="@:0.4.0", + ) + patch("fftw-detection.patch", when="@:0.4.0") diff --git a/var/spack/repos/builtin/packages/libverto/package.py b/var/spack/repos/builtin/packages/libverto/package.py index 0698c553e1163d..73bbf393ca2041 100644 --- a/var/spack/repos/builtin/packages/libverto/package.py +++ b/var/spack/repos/builtin/packages/libverto/package.py @@ -21,6 +21,8 @@ class Libverto(AutotoolsPackage): version("0.3.0", sha256="fad201d9d0ac1abf1283d2d78bb3a615f72cfd2a2141673589d93c0cb762b3f1") version("0.2.7", sha256="0ef688a8a8690c24714834cc155b067b1c5d3f3194acceb333751deebd50de01") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/libvips/package.py b/var/spack/repos/builtin/packages/libvips/package.py index f5e64f6a9b44ba..abb360545e672f 100644 --- a/var/spack/repos/builtin/packages/libvips/package.py +++ b/var/spack/repos/builtin/packages/libvips/package.py @@ -22,6 +22,9 @@ class Libvips(AutotoolsPackage): version("8.9.1", sha256="45633798877839005016c9d3494e98dee065f5cb9e20f4552d3b315b8e8bce91") version("8.9.0", sha256="97334a5e70aff343d2587f23cb8068fc846a58cd937c89a446142ccf00ea0349") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("fftw", default=True, description="Uses FFTW3 for fourier transforms.") variant("jpeg", default=False, description="Enable JPEG support") diff --git a/var/spack/repos/builtin/packages/libvorbis/package.py b/var/spack/repos/builtin/packages/libvorbis/package.py index 922e9c57e9bb01..ccaf5fff0b7f7b 100644 --- a/var/spack/repos/builtin/packages/libvorbis/package.py +++ b/var/spack/repos/builtin/packages/libvorbis/package.py @@ -20,6 +20,8 @@ class Libvorbis(AutotoolsPackage): version("1.3.7", sha256="0e982409a9c3fc82ee06e08205b1355e5c6aa4c36bca58146ef399621b0ce5ab") version("1.3.5", sha256="6efbcecdd3e5dfbf090341b485da9d176eb250d893e3eb378c428a2db38301ce") + depends_on("c", type="build") # generated + depends_on("libogg") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/libvori/package.py b/var/spack/repos/builtin/packages/libvori/package.py index 47fb3be91a4b59..ecfd87922b0355 100644 --- a/var/spack/repos/builtin/packages/libvori/package.py +++ b/var/spack/repos/builtin/packages/libvori/package.py @@ -22,6 +22,8 @@ class Libvori(CMakePackage): version("201224", sha256="16f6c49eaa17ea23868925dbaae2eca71bdacbe50418c97d6c55e05728038f31") version("201217", sha256="6ad456ed6ca5d28cadcc0d90eabe8fff5caa77b99f12764323de5e3ae21cddf5") + depends_on("cxx", type="build") # generated + variant("pic", default=True, description="Compile the library with position independent code") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/libvpx/package.py b/var/spack/repos/builtin/packages/libvpx/package.py index 063c76c9bc1083..d1c56aafe35c2a 100644 --- a/var/spack/repos/builtin/packages/libvpx/package.py +++ b/var/spack/repos/builtin/packages/libvpx/package.py @@ -21,6 +21,9 @@ class Libvpx(AutotoolsPackage): version("1.10.0", sha256="85803ccbdbdd7a3b03d930187cb055f1353596969c1f92ebec2db839fa4f834a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("pic", default=True, description="Produce position-independent code (for shared libs)") depends_on("yasm") diff --git a/var/spack/repos/builtin/packages/libvterm/package.py b/var/spack/repos/builtin/packages/libvterm/package.py index 2c7481fb959a34..0277e2e8c809a6 100644 --- a/var/spack/repos/builtin/packages/libvterm/package.py +++ b/var/spack/repos/builtin/packages/libvterm/package.py @@ -27,6 +27,8 @@ class Libvterm(MakefilePackage): url="http://www.leonerd.org.uk/code/libvterm/libvterm-0+bzr726.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("libtool", type="build") def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/libwebp/package.py b/var/spack/repos/builtin/packages/libwebp/package.py index f74efe9a11b14b..4e118a47e9e241 100644 --- a/var/spack/repos/builtin/packages/libwebp/package.py +++ b/var/spack/repos/builtin/packages/libwebp/package.py @@ -16,12 +16,19 @@ class Libwebp(AutotoolsPackage): license("BSD-3-Clause") + version("1.4.0", sha256="61f873ec69e3be1b99535634340d5bde750b2e4447caa1db9f61be3fd49ab1e5") + version("1.3.2", sha256="2a499607df669e40258e53d0ade8035ba4ec0175244869d1025d460562aa09b4") + version("1.3.1", sha256="b3779627c2dfd31e3d8c4485962c2efe17785ef975e2be5c8c0c9e6cd3c4ef66") + version("1.3.0", sha256="64ac4614db292ae8c5aa26de0295bf1623dbb3985054cb656c55e67431def17c") version("1.2.4", sha256="7bf5a8a28cc69bcfa8cb214f2c3095703c6b73ac5fba4d5480c205331d9494df") version("1.2.3", sha256="f5d7ab2390b06b8a934a4fc35784291b3885b557780d099bd32f09241f9d83f9") version("1.2.2", sha256="7656532f837af5f4cec3ff6bafe552c044dc39bf453587bd5b77450802f4aee6") version("1.2.0", sha256="2fc8bbde9f97f2ab403c0224fb9ca62b2e6852cbc519e91ceaa7c153ffd88a0c") version("1.0.3", sha256="e20a07865c8697bba00aebccc6f54912d6bc333bb4d604e6b07491c1a226b34f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("libwebpmux", default=False, description="Build libwebpmux") variant("libwebpdemux", default=False, description="Build libwebpdemux") variant("libwebpdecoder", default=False, description="Build libwebpdecoder") @@ -44,13 +51,13 @@ def configure_args(self): # TODO: add variants and dependencies for these args = ["--disable-gl", "--disable-sdl", "--disable-wic"] - args += self.enable_or_disable("gif") - args += self.enable_or_disable("jpeg") - args += self.enable_or_disable("png") - args += self.enable_or_disable("tiff") args += self.enable_or_disable("libwebpmux") args += self.enable_or_disable("libwebpdemux") args += self.enable_or_disable("libwebpdecoder") args += self.enable_or_disable("libwebpextras") + args += self.enable_or_disable("gif") + args += self.enable_or_disable("jpeg") + args += self.enable_or_disable("png") + args += self.enable_or_disable("tiff") return args diff --git a/var/spack/repos/builtin/packages/libwebsockets/package.py b/var/spack/repos/builtin/packages/libwebsockets/package.py index 59fae25a809f4d..37e66b3d153737 100644 --- a/var/spack/repos/builtin/packages/libwebsockets/package.py +++ b/var/spack/repos/builtin/packages/libwebsockets/package.py @@ -21,5 +21,8 @@ class Libwebsockets(CMakePackage): version("2.0.3", sha256="cf0e91b564c879ab98844385c98e7c9e298cbb969dbc251a3f18a47feb94342c") version("1.7.9", sha256="86a5105881ea2cb206f8795483d294e9509055decf60436bcc1e746262416438") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("openssl") diff --git a/var/spack/repos/builtin/packages/libwhich/package.py b/var/spack/repos/builtin/packages/libwhich/package.py index 37ec3fc115ed3f..d9430ee12b6e1a 100644 --- a/var/spack/repos/builtin/packages/libwhich/package.py +++ b/var/spack/repos/builtin/packages/libwhich/package.py @@ -23,6 +23,8 @@ class Libwhich(Package): version("1.1.0", sha256="f1c30bf7396859ad437a5db74e9e328fb4b4e1379457121e28a3524b1e3a0b3f") version("1.0.0", sha256="61d5d643d4cbd4b340b9b48922e1b4fd2a35729b7cfdcc7283aab82a6f742a6c") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make() mkdir(prefix.bin) diff --git a/var/spack/repos/builtin/packages/libwindowswm/package.py b/var/spack/repos/builtin/packages/libwindowswm/package.py index dd533742c1bcf2..e0a2bd8dfed0d1 100644 --- a/var/spack/repos/builtin/packages/libwindowswm/package.py +++ b/var/spack/repos/builtin/packages/libwindowswm/package.py @@ -21,6 +21,8 @@ class Libwindowswm(AutotoolsPackage, XorgPackage): version("1.0.1", sha256="94f9c0add3bad38ebd84bc43d854207c4deaaa74fb15339276e022546124b98a") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libwmf/package.py b/var/spack/repos/builtin/packages/libwmf/package.py index 63d32c1b20f531..deb850e99e6f98 100644 --- a/var/spack/repos/builtin/packages/libwmf/package.py +++ b/var/spack/repos/builtin/packages/libwmf/package.py @@ -22,6 +22,8 @@ class Libwmf(AutotoolsPackage): version("0.2.12", sha256="464ff63605d7eaf61a4a12dbd420f7a41a4d854675d8caf37729f5bc744820e2") version("0.2.11", sha256="e2a2664afd5abc71a42be7ad3c200f64de2b8889bf088eac1d32e205ce843803") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("expat") depends_on("freetype") diff --git a/var/spack/repos/builtin/packages/libwnck/package.py b/var/spack/repos/builtin/packages/libwnck/package.py new file mode 100644 index 00000000000000..40f139cb6e9693 --- /dev/null +++ b/var/spack/repos/builtin/packages/libwnck/package.py @@ -0,0 +1,76 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class Libwnck(MesonPackage, AutotoolsPackage): + """Window Navigator Construction Kit""" + + homepage = "https://gitlab.gnome.org/GNOME/libwnck" + url = "https://download.gnome.org/sources/libwnck/3.4/libwnck-3.4.9.tar.xz" + list_url = "https://download.gnome.org/sources/libwnck/" + list_depth = 2 + + def url_for_version(self, version): + base = "https://download.gnome.org/sources/libwnck" + dirname = version.up_to(1) if version >= Version("40") else version.up_to(2) + filename = f"libwnck-{version.up_to(3)}.tar.xz" + return f"{base}/{dirname}/{filename}" + + license("GPLv2", checked_by="teaguesterling") + + version("43.0", sha256="905bcdb85847d6b8f8861e56b30cd6dc61eae67ecef4cd994a9f925a26a2c1fe") + version("40.1", sha256="03134fa114ef3fbe34075aa83678f58aa2debe9fcef4ea23c0779e28601d6611") + version("3.36.0", sha256="bc508150b3ed5d22354b0e6774ad4eee465381ebc0ace45eb0e2d3a4186c925f") + version("3.24.1", sha256="afa6dc283582ffec15c3374790bcbcb5fb422bd38356d72deeef35bf7f9a1f04") + version("3.20.1", sha256="1cb03716bc477058dfdf3ebfa4f534de3b13b1aa067fcd064d0b7813291cba72") + version("3.14.1", sha256="bb643c9c423c8aa79c59973ce27ce91d3b180d1e9907902278fb79391f52befa") + version("3.4.9", sha256="96e6353f2701a1ea565ece54d791a7bebef1832d96126f7377c54bb3516682c4") + + variant("cairo", default=True, description="Build with cairo support") + variant("install_tools", default=True, description="Install WNCK tools") + variant("xres", default=True, description="Build with xres support") + variant("introspection", default=True, description="Build with gobject-introspection support") + variant( + "startup_notification", default=True, description="Build with startup-notification support" + ) + variant("gtk_doc", default=False, description="Build documentation") + + build_system( + conditional("meson", when="@3.31:"), + conditional("autotools", when="@:3.24"), + default="meson", + ) + + with default_args(type="build"): + depends_on("pkgconfig@0.9.0:") + depends_on("gettext", when="@3.31:") + depends_on("intltool@0.40.6:", when="@:3.24") + depends_on("cmake", when="build_system=meson") + depends_on("gtk-doc@1.9:", when="+gtk_doc") + + with default_args(type=("build", "link", "run")): + depends_on("glib@2") + depends_on("gdk-pixbuf") + depends_on("gtkplus@3.22:") + + depends_on("cairo+X+gobject", when="+cairo") + depends_on("libxres", when="+xres") + depends_on("gobject-introspection", when="+introspection") + depends_on("startup-notification", when="+startup_notification") + + def configure_args(self): + args = [] + + args += self.enable_or_disable("introspection") + args += self.enable_or_disable("install_tools") + args += self.enable_or_disable("startup_notification") + args += self.enable_or_disable("gtk_doc") + + return args + + def setup_dependent_build_environment(self, env, dep_spec): + if self.spec.satisfies("+introspection") and dep_spec.satisfies("+introspection"): + env.append_path("XDG_DATA_DIRS", self.prefix.share) diff --git a/var/spack/repos/builtin/packages/libx11/package.py b/var/spack/repos/builtin/packages/libx11/package.py index d1d59561c27bc8..b5cf2307f4441d 100644 --- a/var/spack/repos/builtin/packages/libx11/package.py +++ b/var/spack/repos/builtin/packages/libx11/package.py @@ -11,11 +11,14 @@ class Libx11(AutotoolsPackage, XorgPackage): homepage = "https://www.x.org/" xorg_mirror_path = "lib/libX11-1.6.7.tar.gz" + git = "https://gitlab.freedesktop.org/xorg/lib/libx11.git" license("X11") maintainers("wdconinc") + version("1.8.9", sha256="57ca5f07d263788ad661a86f4139412e8b699662e6b60c20f1f028c25a935e48") + version("1.8.8", sha256="26997a2bc48c03df7d670f8a4ee961d1d6b039bf947475e5fec6b7635b4efe72") version("1.8.7", sha256="793ebebf569f12c864b77401798d38814b51790fce206e01a431e5feb982e20b") version("1.8.6", sha256="5ff0d26c94d82ebb94a944b9f1f55cd01b9713fd461fe93f62f3527ce14ad94e") version("1.8.5", sha256="d84a35c324d5a1724692eafc1ed76f1689c833021e0062933773ec437f91a56b") @@ -35,6 +38,8 @@ class Libx11(AutotoolsPackage, XorgPackage): version("1.6.5", sha256="3abce972ba62620611fab5b404dafb852da3da54e7c287831c30863011d28fb3") version("1.6.3", sha256="0b03b9d22f4c9e59b4ba498f294e297f013cae27050dfa0f3496640200db5376") + depends_on("c", type="build") # generated + depends_on("libxcb@1.11.1:", when="@1.6.4:") depends_on("libxcb@1.1.92:") diff --git a/var/spack/repos/builtin/packages/libxau/package.py b/var/spack/repos/builtin/packages/libxau/package.py index 491a67c1aa91dd..0f747619398792 100644 --- a/var/spack/repos/builtin/packages/libxau/package.py +++ b/var/spack/repos/builtin/packages/libxau/package.py @@ -11,7 +11,7 @@ class Libxau(AutotoolsPackage, XorgPackage): Authorization Protocol. This is useful for restricting client access to the display.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXau/" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXau/" xorg_mirror_path = "lib/libXau-1.0.8.tar.gz" license("MIT") @@ -23,6 +23,8 @@ class Libxau(AutotoolsPackage, XorgPackage): version("1.0.9", sha256="1f123d8304b082ad63a9e89376400a3b1d4c29e67e3ea07b3f659cccca690eea") version("1.0.8", sha256="c343b4ef66d66a6b3e0e27aa46b37ad5cab0f11a5c565eafb4a1c7590bc71d7b") + depends_on("c", type="build") # generated + depends_on("xproto") depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") diff --git a/var/spack/repos/builtin/packages/libxaw/package.py b/var/spack/repos/builtin/packages/libxaw/package.py index 4d5c54e5881f24..d67ca1f690fea8 100644 --- a/var/spack/repos/builtin/packages/libxaw/package.py +++ b/var/spack/repos/builtin/packages/libxaw/package.py @@ -10,18 +10,21 @@ class Libxaw(AutotoolsPackage, XorgPackage): """Xaw is the X Athena Widget Set. Xaw is a widget set based on the X Toolkit Intrinsics (Xt) Library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXaw" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXaw" xorg_mirror_path = "lib/libXaw-1.0.13.tar.gz" license("MIT") maintainers("wdconinc") + version("1.0.16", sha256="012f90adf8739f2f023d63a5fee1528949cf2aba92ef7ac1abcfc2ae9cf28798") version("1.0.15", sha256="ca8a613884c922985202075b3cc8ee8821bfa83a5eb066189ae3cca131e63972") version("1.0.14", sha256="59cfed2712cc80bbfe62dd1aacf24f58d74a76dd08329a922077b134a8d8048f") version("1.0.13", sha256="7e74ac3e5f67def549722ff0333d6e6276b8becd9d89615cda011e71238ab694") version("1.0.12", sha256="e32abc68d759ffb643f842329838f8b6c157e31023cc91059aabf730e7222ad2") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/libxaw3d/package.py b/var/spack/repos/builtin/packages/libxaw3d/package.py index cf70c53b255e5d..6ce61e39dfcc64 100644 --- a/var/spack/repos/builtin/packages/libxaw3d/package.py +++ b/var/spack/repos/builtin/packages/libxaw3d/package.py @@ -10,21 +10,26 @@ class Libxaw3d(AutotoolsPackage, XorgPackage): """Xaw3d is the X 3D Athena Widget Set. Xaw3d is a widget set based on the X Toolkit Intrinsics (Xt) Library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXaw3d" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXaw3d" xorg_mirror_path = "lib/libXaw3d-1.6.2.tar.gz" license("MIT") maintainers("wdconinc") + version("1.6.6", sha256="0cdb8f51c390b0f9f5bec74454e53b15b6b815bc280f6b7c969400c9ef595803") + version("1.6.5", sha256="1123d80c58f45616ef18502081eeec5e92f20c7e7dd82a24f9e2e4f3c0e86dc7") version("1.6.4", sha256="09fecfdab9d7d5953567883e2074eb231bc7a122a06e5055f9c119090f1f76a7") version("1.6.2", sha256="847dab01aeac1448916e3b4edb4425594b3ac2896562d9c7141aa4ac6c898ba9") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxt") depends_on("libxmu") depends_on("libxext") depends_on("libxpm") + depends_on("xproto@7.0.22:") depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") diff --git a/var/spack/repos/builtin/packages/libxc/nvhpc-configure.patch b/var/spack/repos/builtin/packages/libxc/nvhpc-configure.patch deleted file mode 100644 index 47e8f2213bd6b9..00000000000000 --- a/var/spack/repos/builtin/packages/libxc/nvhpc-configure.patch +++ /dev/null @@ -1,75 +0,0 @@ ---- a/configure 2020-09-24 11:13:16.306629033 -0700 -+++ b/configure 2020-09-24 11:14:16.412221646 -0700 -@@ -8908,7 +8908,7 @@ - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; -- pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) -+ pgcc* | pgf77* | pgf90* | pgf95* | pgfortran* | nvc | nvfortran*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl='-Wl,' -@@ -9547,11 +9547,11 @@ - tmp_addflag=' $pic_flag' - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in -- pgcc*) # Portland Group C compiler -+ pgcc* | nvc) # Portland Group C compiler - whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; -- pgf77* | pgf90* | pgf95* | pgfortran*) -+ pgf77* | pgf90* | pgf95* | pgfortran* | nvfortran*) - # Portland Group f77 and f90 compilers - whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; -@@ -13810,7 +13810,7 @@ - ac_link='$FC -o conftest$ac_exeext $FCFLAGS $LDFLAGS $ac_fcflags_srcext conftest.$ac_ext $LIBS >&5' - ac_compiler_gnu=$ac_cv_fc_compiler_gnu - if test -n "$ac_tool_prefix"; then -- for ac_prog in xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgfortran pgf95 lf95 ftn nagfor -+ for ac_prog in xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgfortran pgf95 nvfortran lf95 ftn nagfor - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. - set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -@@ -13854,7 +13854,7 @@ - fi - if test -z "$FC"; then - ac_ct_FC=$FC -- for ac_prog in xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgfortran pgf95 lf95 ftn nagfor -+ for ac_prog in xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgfortran pgf95 nvfortran lf95 ftn nagfor - do - # Extract the first word of "$ac_prog", so it can be a program name with args. - set dummy $ac_prog; ac_word=$2 -@@ -14545,7 +14545,7 @@ - lt_prog_compiler_pic_FC='-fPIC' - lt_prog_compiler_static_FC='-static' - ;; -- pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) -+ pgcc* | pgf77* | pgf90* | pgf95* | pgfortran* | nvc | nvfortran*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl_FC='-Wl,' -@@ -14587,7 +14587,7 @@ - lt_prog_compiler_pic_FC='-fPIC' - lt_prog_compiler_static_FC='-static' - ;; -- *Portland\ Group*) -+ *Portland\ Group* | *NVIDIA\ Compilers* | *PGI\ Compilers*) - lt_prog_compiler_wl_FC='-Wl,' - lt_prog_compiler_pic_FC='-fpic' - lt_prog_compiler_static_FC='-Bstatic' -@@ -15169,11 +15169,11 @@ - tmp_addflag=' $pic_flag' - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in -- pgcc*) # Portland Group C compiler -+ pgcc* | nvc) # Portland Group C compiler - whole_archive_flag_spec_FC='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; -- pgf77* | pgf90* | pgf95* | pgfortran*) -+ pgf77* | pgf90* | pgf95* | pgfortran* | nvfortran*) - # Portland Group f77 and f90 compilers - whole_archive_flag_spec_FC='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; diff --git a/var/spack/repos/builtin/packages/libxc/nvhpc-libtool.patch b/var/spack/repos/builtin/packages/libxc/nvhpc-libtool.patch deleted file mode 100644 index 18d6b0e1fef89c..00000000000000 --- a/var/spack/repos/builtin/packages/libxc/nvhpc-libtool.patch +++ /dev/null @@ -1,77 +0,0 @@ -From b71206582131f88f6602a40e4c67e3d92b119229 Mon Sep 17 00:00:00 2001 -From: Tin Huynh -Date: Mon, 27 Jul 2020 15:15:47 -0700 -Subject: [PATCH] Recognize new Nvidia compilers. - -With the upcoming release of HPC-SDK, updating Libtool to recognize Nvidia -compilers (nvc, nvc++, nvfortran). ---- - m4/libtool.m4 | 21 ++++++++++----------- - 1 file changed, 10 insertions(+), 11 deletions(-) - -diff --git a/m4/libtool.m4 b/m4/libtool.m4 -index f2d1f39..4eac689 100644 ---- a/m4/libtool.m4 -+++ b/m4/libtool.m4 -@@ -4402,8 +4402,8 @@ m4_if([$1], [CXX], [ - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; -- pgCC* | pgcpp*) -- # Portland Group C++ compiler -+ pgCC* | pgcpp* | pgc\+\+* | nvc\+\+*) -+ # NVIDIA HPC C++ compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' -@@ -4739,9 +4739,8 @@ m4_if([$1], [CXX], [ - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; -- pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) -- # Portland Group compilers (*not* the Pentium gcc compiler, -- # which looks to be a dead project) -+ pgcc* | pgf77* | pgf90* | pgf95* | pgfortran* | nvc | nvfortran*) -+ # NVIDIA HPC Compilers - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' -@@ -4781,7 +4780,7 @@ m4_if([$1], [CXX], [ - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; -- *Portland\ Group*) -+ *Portland\ Group* | *NVIDIA\ Compilers* | *PGI\ Compilers*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' -@@ -5209,12 +5208,12 @@ _LT_EOF - tmp_addflag=' $pic_flag' - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in -- pgcc*) # Portland Group C compiler -+ pgcc* | nvc) # NVIDIA HPC C++ Compiler - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; -- pgf77* | pgf90* | pgf95* | pgfortran*) -- # Portland Group f77 and f90 compilers -+ pgf77* | pgf90* | pgf95* | pgfortran* | nvfortran*) -+ # NVIDIA HPC Fortran Compilers - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 -@@ -7004,8 +7003,8 @@ if test yes != "$_lt_caught_CXX_error"; then - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' - ;; -- pgCC* | pgcpp*) -- # Portland Group C++ compiler -+ pgCC* | pgcpp* | pgc\+\+* | nvc\+\+*) -+ # NVIDIA HPC C++ compiler - case `$CC -V` in - *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) - _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ --- -2.7.4 - diff --git a/var/spack/repos/builtin/packages/libxc/package.py b/var/spack/repos/builtin/packages/libxc/package.py index 720095b1904efd..05fb99c7e063ca 100644 --- a/var/spack/repos/builtin/packages/libxc/package.py +++ b/var/spack/repos/builtin/packages/libxc/package.py @@ -10,29 +10,32 @@ class Libxc(AutotoolsPackage, CudaPackage): """Libxc is a library of exchange-correlation functionals for density-functional theory.""" - homepage = "https://tddft.org/programs/libxc/" + homepage = "https://libxc.gitlab.io" url = "https://gitlab.com/libxc/libxc/-/archive/6.1.0/libxc-6.1.0.tar.gz" license("MPL-2.0-no-copyleft-exception") - version("6.2.2", sha256="3b0523924579cf494cafc6fea92945257f35692b004217d3dfd3ea7ca780e8dc") - version("6.2.1", sha256="b5f3b4514db6bc4ccda1da90ac6176ea1f82e12241cc66427c58cbc4a5197b9b") - version("6.2.0", sha256="3d25878782b5f94e7e4d41bd6de27f98983584cd0be0c65e69a9ada986b56b4d") - version("6.1.0", sha256="f593745fa47ebfb9ddc467aaafdc2fa1275f0d7250c692ce9761389a90dd8eaf") - version("6.0.0", sha256="0c774e8e195dd92800b9adf3df5f5721e29acfe9af4b191a9937c7de4f9aa9f6") - version("5.2.3", sha256="7b7a96d8eeb472c7b8cca7ac38eae27e0a8113ef44dae5359b0eb12592b4bcf2") - version("5.1.7", sha256="1a818fdfe5c5f74270bc8ef0c59064e8feebcd66b8f642c08aecc1e7d125be34") - version("5.1.5", sha256="02e4615a22dc3ec87a23efbd3d9be5bfad2445337140bad1720699571c45c3f9") - version("5.1.3", sha256="0350defdd6c1b165e4cf19995f590eee6e0b9db95a6b221d28cecec40f4e85cd") - version("5.1.2", sha256="180d52b5552921d1fac8a10869dd30708c0fb41dc202a3bbee0e36f43872718a") - version("5.1.0", sha256="f67b6e518372871d9eed6e5dba77c3ab5ea030c229ba7a7d44bcf51f3258373f") - version("5.0.0", sha256="1cdc57930f7b57da4eb9b2c55a50ba1c2c385936ddaf5582fee830994461a892") - version("4.3.4", sha256="a8ee37ddc5079339854bd313272856c9d41a27802472ee9ae44b58ee9a298337") - version("4.3.2", sha256="bc159aea2537521998c7fb1199789e1be71e04c4b7758d58282622e347603a6f") - version("4.2.3", sha256="02e49e9ba7d21d18df17e9e57eae861e6ce05e65e966e1e832475aa09e344256") - version("3.0.0", sha256="5542b99042c09b2925f2e3700d769cda4fb411b476d446c833ea28c6bfa8792a") - version("2.2.2", sha256="6ca1d0bb5fdc341d59960707bc67f23ad54de8a6018e19e02eee2b16ea7cc642") - version("2.2.1", sha256="ade61c1fa4ed238edd56408fd8ee6c2e305a3d5753e160017e2a71817c98fd00") + version("6.2.2", sha256="d1b65ef74615a1e539d87a0e6662f04baf3a2316706b4e2e686da3193b26b20f") + version("6.2.1", sha256="da96fc4f6e4221734986f49758b410ffe1d406efd3538761062a4af57a2bd272") + version("6.2.0", sha256="31edb72c69157b6c0beaff1f10cbbb6348ce7579ef81d8f286764e5ab61194d1") + version("6.1.0", sha256="9baf23501dca21b05fa22d8e2ffeb56f294abe19ba12584cb3f9b421ae719c5f") + version("6.0.0", sha256="48a5393984d95bf0dd05c5ffc94e77da938b7f321058fe250c3448c7a9392c88") + version("5.2.3", sha256="3e0b36b3b9986a621fd8850133408f6f567bd7db5636a32a68f7637e116e268c") + version("5.1.7", sha256="1d50e1a92e59b5f3c8e7408f8612f0fb0e953d4f159515b7d81485891f3a1bbc") + version("5.1.5", sha256="101d6ea9e013006deae074843f0d02ab2813e16734e47ff7b0551babc4497163") + version("5.1.3", sha256="76b2abd063b692ed7e60fb6dfdf5a54072378710ee91f2b352a4e311d9805e97") + version("5.1.2", sha256="ff13eef8184b6c61dac8933ee74fc05967de4a67489581bdc500f1ec63826aae") + version("5.1.0", sha256="e8d2b6eb2b46b356a27f0367a7665ff276d7f295da7c734e774ee66f82e56297") + version("5.0.0", sha256="6b3be3cf6daf6b3eddf32d4077276eb9169531b42f98c2ca28ac85b9ea408493") + version("4.3.4", sha256="2d5878dd69f0fb68c5e97f46426581eed2226d1d86e3080f9aa99af604c65647") + version("4.3.2", sha256="3bbe01971d0a43fb63b5c17d922388a39a3f0ae3bd37ae5f6fe31bca9ab63f3c") + version("4.2.3", sha256="869ca4967cd255097fd2dc31664f30607e81f5abcf5f9c89bd467dc0bf93e5aa") + version("3.0.0", sha256="df2362351280edaf2233f3b2c8eb8e6dd6c68105f152897a4cc629fa346a7396") + version("2.2.2", sha256="6ffaad40505dbe8f155049448554b54ea31d31babf74ccf6b7935bfe55eeafd8") + version("2.2.1", sha256="c8577ba1ddd5c28fd0aa7c579ae65ab990eb7cb51ecf9f8175f9251f6deb9a06") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated variant("shared", default=True, description="Build shared libraries") variant("kxc", default=False, when="@5:", description="Build with third derivatives") @@ -41,11 +44,10 @@ class Libxc(AutotoolsPackage, CudaPackage): conflicts("+shared +cuda", msg="Only ~shared supported with +cuda") conflicts("+cuda", when="@:4", msg="CUDA support only in libxc 5.0.0 and above") - # Remove this when the release tarballs become available for 6.0.0 and above. - with when("@6.0.0:"): - depends_on("autoconf", type="build") - depends_on("automake", type="build") - depends_on("libtool", type="build") + # Remove this if the release tarballs are available again. + depends_on("autoconf", type="build") + depends_on("automake", type="build") + depends_on("libtool", type="build") depends_on("perl", type="build") @@ -57,17 +59,6 @@ class Libxc(AutotoolsPackage, CudaPackage): when="@6.0.0", ) - patch("nvhpc-configure.patch", when="%nvhpc") - patch("nvhpc-libtool.patch", when="@develop %nvhpc") - - def url_for_version(self, version): - # The webserver at https://tddft.org/programs/libxc/download is unreliable, - # see https://gitlab.com/libxc/libxc/-/issues/453. The pre 6.0.0 release tarballs - # ar available in our source mirror, but the latest versions are not. - if version < Version("6"): - return f"https://www.tddft.org/programs/libxc/down/{version}/libxc-{version}.tar.gz" - return f"https://gitlab.com/libxc/libxc/-/archive/{version}/libxc-{version}.tar.gz" - @property def libs(self): """Libxc can be queried for the following parameters: diff --git a/var/spack/repos/builtin/packages/libxcb/package.py b/var/spack/repos/builtin/packages/libxcb/package.py index 1f11a79ef9abb4..bc22cc20289e83 100644 --- a/var/spack/repos/builtin/packages/libxcb/package.py +++ b/var/spack/repos/builtin/packages/libxcb/package.py @@ -6,23 +6,32 @@ from spack.package import * -class Libxcb(AutotoolsPackage): +class Libxcb(AutotoolsPackage, XorgPackage): """The X protocol C-language Binding (XCB) is a replacement for Xlib featuring a small footprint, latency hiding, direct access to the protocol, improved threading support, and extensibility.""" homepage = "https://xcb.freedesktop.org/" - url = "https://xorg.freedesktop.org/archive/individual/lib/libxcb-1.14.tar.xz" + xorg_mirror_path = "lib/libxcb-1.14.tar.xz" license("MIT") maintainers("wdconinc") + version("1.17.0", sha256="599ebf9996710fea71622e6e184f3a8ad5b43d0e5fa8c4e407123c88a59a6d55") + version("1.16.1", sha256="f24d187154c8e027b358fc7cb6588e35e33e6a92f11c668fe77396a7ae66e311") version("1.16", sha256="4348566aa0fbf196db5e0a576321c65966189210cb51328ea2bb2be39c711d71") version("1.15", sha256="cc38744f817cf6814c847e2df37fcb8997357d72fa4bcbc228ae0fe47219a059") version("1.14", sha256="a55ed6db98d43469801262d81dc2572ed124edc3db31059d4e9916eb9f844c34") - version("1.13", sha256="0bb3cfd46dbd90066bf4d7de3cad73ec1024c7325a4a0cbf5f4a0d4fa91155fb") + version( + "1.13", + sha256="0bb3cfd46dbd90066bf4d7de3cad73ec1024c7325a4a0cbf5f4a0d4fa91155fb", + url="https://xcb.freedesktop.org/dist/libxcb-1.13.tar.gz", + deprecated=True, + ) + + depends_on("c", type="build") # generated depends_on("libpthread-stubs") depends_on("libxau@0.99.2:") @@ -30,6 +39,8 @@ class Libxcb(AutotoolsPackage): # libxcb 1.X requires xcb-proto >= 1.X depends_on("xcb-proto") + depends_on("xcb-proto@1.17:", when="@1.17") + depends_on("xcb-proto@1.16:", when="@1.16") depends_on("xcb-proto@1.15:", when="@1.15") depends_on("xcb-proto@1.14:", when="@1.14") depends_on("xcb-proto@1.13:", when="@1.13") @@ -38,14 +49,6 @@ class Libxcb(AutotoolsPackage): depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") - def url_for_version(self, version): - if version >= Version("1.14"): - url = "https://xorg.freedesktop.org/archive/individual/lib/libxcb-{0}.tar.xz" - else: - url = "https://xcb.freedesktop.org/dist/libxcb-{0}.tar.gz" - - return url.format(version) - def configure_args(self): config_args = [] diff --git a/var/spack/repos/builtin/packages/libxcomposite/package.py b/var/spack/repos/builtin/packages/libxcomposite/package.py index 8b4dd5d551e56b..620cd106e8e1eb 100644 --- a/var/spack/repos/builtin/packages/libxcomposite/package.py +++ b/var/spack/repos/builtin/packages/libxcomposite/package.py @@ -10,7 +10,7 @@ class Libxcomposite(AutotoolsPackage, XorgPackage): """libXcomposite - client library for the Composite extension to the X11 protocol.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXcomposite" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXcomposite" xorg_mirror_path = "lib/libXcomposite-0.4.4.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Libxcomposite(AutotoolsPackage, XorgPackage): version("0.4.6", sha256="3599dfcd96cd48d45e6aeb08578aa27636fa903f480f880c863622c2b352d076") version("0.4.4", sha256="83c04649819c6f52cda1b0ce8bcdcc48ad8618428ad803fb07f20b802f1bdad1") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxfixes") depends_on("fixesproto@0.4:") diff --git a/var/spack/repos/builtin/packages/libxcrypt/package.py b/var/spack/repos/builtin/packages/libxcrypt/package.py index fe641d3d3e40de..dccd34f7b984c9 100644 --- a/var/spack/repos/builtin/packages/libxcrypt/package.py +++ b/var/spack/repos/builtin/packages/libxcrypt/package.py @@ -33,6 +33,8 @@ def url_for_version(self, version): version("4.4.16", sha256="a98f65b8baffa2b5ba68ee53c10c0a328166ef4116bce3baece190c8ce01f375") version("4.4.15", sha256="8bcdef03bc65f9dbda742e56820435b6f13eea59fb903765141c6467f4655e5a") + depends_on("c", type="build") # generated + variant( "obsolete_api", default=False, diff --git a/var/spack/repos/builtin/packages/libxcursor/package.py b/var/spack/repos/builtin/packages/libxcursor/package.py index 9f6471a1090a34..5680971829a619 100644 --- a/var/spack/repos/builtin/packages/libxcursor/package.py +++ b/var/spack/repos/builtin/packages/libxcursor/package.py @@ -9,16 +9,19 @@ class Libxcursor(AutotoolsPackage, XorgPackage): """libXcursor - X Window System Cursor management library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXcursor" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXcursor" xorg_mirror_path = "lib/libXcursor-1.1.14.tar.gz" license("MIT") maintainers("wdconinc") + version("1.2.2", sha256="98c3a30a3f85274c167d1ac5419d681ce41f14e27bfa5fe3003c8172cd8af104") version("1.2.1", sha256="77f96b9ad0a3c422cfa826afabaf1e02b9bfbfc8908c5fa1a45094faad074b98") version("1.1.14", sha256="be0954faf274969ffa6d95b9606b9c0cfee28c13b6fc014f15606a0c8b05c17b") + depends_on("c", type="build") # generated + depends_on("libxrender@0.8.2:") depends_on("libxfixes") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/libxdamage/package.py b/var/spack/repos/builtin/packages/libxdamage/package.py index 0090ce624b8415..37546254c173db 100644 --- a/var/spack/repos/builtin/packages/libxdamage/package.py +++ b/var/spack/repos/builtin/packages/libxdamage/package.py @@ -9,7 +9,7 @@ class Libxdamage(AutotoolsPackage, XorgPackage): """This package contains the library for the X Damage extension.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXdamage" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXdamage" xorg_mirror_path = "lib/libXdamage-1.1.4.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Libxdamage(AutotoolsPackage, XorgPackage): version("1.1.5", sha256="630ec53abb8c2d6dac5cd9f06c1f73ffb4a3167f8118fdebd77afd639dbc2019") version("1.1.4", sha256="4bb3e9d917f5f593df2277d452926ee6ad96de7b7cd1017cbcf4579fe5d3442b") + depends_on("c", type="build") # generated + depends_on("libxfixes") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/libxdmcp/package.py b/var/spack/repos/builtin/packages/libxdmcp/package.py index d72a1ac61e5280..dd22e784386263 100644 --- a/var/spack/repos/builtin/packages/libxdmcp/package.py +++ b/var/spack/repos/builtin/packages/libxdmcp/package.py @@ -9,19 +9,21 @@ class Libxdmcp(AutotoolsPackage, XorgPackage): """libXdmcp - X Display Manager Control Protocol library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXdmcp" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXdmcp" xorg_mirror_path = "lib/libXdmcp-1.1.2.tar.gz" license("MIT") maintainers("wdconinc") + version("1.1.5", sha256="31a7abc4f129dcf6f27ae912c3eedcb94d25ad2e8f317f69df6eda0bc4e4f2f3") version("1.1.4", sha256="55041a8ff8992ab02777478c4b19c249c0f8399f05a752cb4a1a868a9a0ccb9a") version("1.1.3", sha256="2ef9653d32e09d1bf1b837d0e0311024979653fe755ad3aaada8db1aa6ea180c") version("1.1.2", sha256="6f7c7e491a23035a26284d247779174dedc67e34e93cc3548b648ffdb6fc57c0") + depends_on("c", type="build") # generated + depends_on("xproto") depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") depends_on("libbsd", when="platform=linux") - depends_on("libbsd", when="platform=cray") diff --git a/var/spack/repos/builtin/packages/libxevie/package.py b/var/spack/repos/builtin/packages/libxevie/package.py index 2dd724510c0273..30dcac3cf183e7 100644 --- a/var/spack/repos/builtin/packages/libxevie/package.py +++ b/var/spack/repos/builtin/packages/libxevie/package.py @@ -9,13 +9,15 @@ class Libxevie(AutotoolsPackage, XorgPackage): """Xevie - X Event Interception Extension (XEvIE).""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXevie" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXevie" xorg_mirror_path = "lib/libXevie-1.0.3.tar.gz" license("MIT") version("1.0.3", sha256="3759bb1f7fdade13ed99bfc05c0717bc42ce3f187e7da4eef80beddf5e461258") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libxext/package.py b/var/spack/repos/builtin/packages/libxext/package.py index b167d90d3bc921..fbd577914937bf 100644 --- a/var/spack/repos/builtin/packages/libxext/package.py +++ b/var/spack/repos/builtin/packages/libxext/package.py @@ -9,17 +9,20 @@ class Libxext(AutotoolsPackage, XorgPackage): """libXext - library for common extensions to the X11 protocol.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXext" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXext" xorg_mirror_path = "lib/libXext-1.3.3.tar.gz" license("MIT") maintainers("wdconinc") + version("1.3.6", sha256="1a0ac5cd792a55d5d465ced8dbf403ed016c8e6d14380c0ea3646c4415496e3d") version("1.3.5", sha256="1a3dcda154f803be0285b46c9338515804b874b5ccc7a2b769ab7fd76f1035bd") version("1.3.4", sha256="8ef0789f282826661ff40a8eef22430378516ac580167da35cc948be9041aac1") version("1.3.3", sha256="eb0b88050491fef4716da4b06a4d92b4fc9e76f880d6310b2157df604342cfe5") + depends_on("c", type="build") # generated + depends_on("libx11@1.6:") depends_on("xproto@7.0.13:") diff --git a/var/spack/repos/builtin/packages/libxfixes/package.py b/var/spack/repos/builtin/packages/libxfixes/package.py index 26f4a1204b6487..073270dc0b0580 100644 --- a/var/spack/repos/builtin/packages/libxfixes/package.py +++ b/var/spack/repos/builtin/packages/libxfixes/package.py @@ -10,7 +10,7 @@ class Libxfixes(AutotoolsPackage, XorgPackage): """This package contains header files and documentation for the XFIXES extension. Library and server implementations are separate.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXfixes" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXfixes" xorg_mirror_path = "lib/libXfixes-5.0.2.tar.gz" license("MIT") @@ -23,6 +23,8 @@ class Libxfixes(AutotoolsPackage, XorgPackage): version("5.0.3", sha256="9ab6c13590658501ce4bd965a8a5d32ba4d8b3bb39a5a5bc9901edffc5666570") version("5.0.2", sha256="ad8df1ecf3324512b80ed12a9ca07556e561b14256d94216e67a68345b23c981") + depends_on("c", type="build") # generated + depends_on("libx11@1.6:") depends_on("xproto") diff --git a/var/spack/repos/builtin/packages/libxfont/package.py b/var/spack/repos/builtin/packages/libxfont/package.py index 7647d81fdbcfb0..708a7bcdb8e450 100644 --- a/var/spack/repos/builtin/packages/libxfont/package.py +++ b/var/spack/repos/builtin/packages/libxfont/package.py @@ -14,7 +14,7 @@ class Libxfont(AutotoolsPackage, XorgPackage): but should not be used by normal X11 clients. X11 clients access fonts via either the new API's in libXft, or the legacy API's in libX11.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXfont" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXfont" xorg_mirror_path = "lib/libXfont-1.5.2.tar.gz" license("MIT") @@ -22,8 +22,10 @@ class Libxfont(AutotoolsPackage, XorgPackage): version("1.5.4", sha256="59be6eab53f7b0feb6b7933c11d67d076ae2c0fd8921229c703fc7a4e9a80d6e") version("1.5.2", sha256="a7350c75171d03d06ae0d623e42240356d6d3e1ac7dfe606639bf20f0d653c93") + depends_on("c", type="build") # generated + depends_on("libfontenc") - depends_on("freetype") + depends_on("freetype build_system=autotools") depends_on("xtrans") depends_on("xproto") diff --git a/var/spack/repos/builtin/packages/libxfont2/package.py b/var/spack/repos/builtin/packages/libxfont2/package.py index 417dfd23239e3d..34ac9d4da0e8d0 100644 --- a/var/spack/repos/builtin/packages/libxfont2/package.py +++ b/var/spack/repos/builtin/packages/libxfont2/package.py @@ -14,7 +14,7 @@ class Libxfont2(AutotoolsPackage, XorgPackage): but should not be used by normal X11 clients. X11 clients access fonts via either the new API's in libXft, or the legacy API's in libX11.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXfont" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXfont" xorg_mirror_path = "lib/libXfont2-2.0.1.tar.gz" license("MIT") @@ -22,6 +22,8 @@ class Libxfont2(AutotoolsPackage, XorgPackage): version("2.0.6", sha256="a944df7b6837c8fa2067f6a5fc25d89b0acc4011cd0bc085106a03557fb502fc") version("2.0.1", sha256="381b6b385a69343df48a082523c856aed9042fbbc8ee0a6342fb502e4321230a") + depends_on("c", type="build") # generated + depends_on("libfontenc") depends_on("freetype") diff --git a/var/spack/repos/builtin/packages/libxfontcache/package.py b/var/spack/repos/builtin/packages/libxfontcache/package.py index ea1d7486708891..f05ea5d59b1c42 100644 --- a/var/spack/repos/builtin/packages/libxfontcache/package.py +++ b/var/spack/repos/builtin/packages/libxfontcache/package.py @@ -9,13 +9,15 @@ class Libxfontcache(AutotoolsPackage, XorgPackage): """Xfontcache - X-TrueType font cache extension client library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXfontcache" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXfontcache" xorg_mirror_path = "lib/libXfontcache-1.0.5.tar.gz" license("BSD-2-Clause") version("1.0.5", sha256="fdba75307a0983d2566554e0e9effa7079551f1b7b46e8de642d067998619659") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libxft/package.py b/var/spack/repos/builtin/packages/libxft/package.py index d4ff5a4461e060..7833041afd4bbd 100644 --- a/var/spack/repos/builtin/packages/libxft/package.py +++ b/var/spack/repos/builtin/packages/libxft/package.py @@ -13,7 +13,7 @@ class Libxft(AutotoolsPackage, XorgPackage): connects X applications with the FreeType font rasterization library. Xft uses fontconfig to locate fonts so it has no configuration files.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXft" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXft" xorg_mirror_path = "lib/libXft-2.3.2.tar.gz" license("MIT") @@ -28,6 +28,8 @@ class Libxft(AutotoolsPackage, XorgPackage): version("2.3.3", sha256="3c3cf88b1a96e49a3d87d67d9452d34b6e25e96ae83959b8d0a980935014d701") version("2.3.2", sha256="26cdddcc70b187833cbe9dc54df1864ba4c03a7175b2ca9276de9f05dce74507") + depends_on("c", type="build") # generated + depends_on("freetype@2.1.6:") depends_on("fontconfig@2.5.92:") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/libxi/package.py b/var/spack/repos/builtin/packages/libxi/package.py index c2e4f1b37c0854..59f757f4e51496 100644 --- a/var/spack/repos/builtin/packages/libxi/package.py +++ b/var/spack/repos/builtin/packages/libxi/package.py @@ -9,7 +9,7 @@ class Libxi(AutotoolsPackage, XorgPackage): """libXi - library for the X Input Extension.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXi" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXi" xorg_mirror_path = "lib/libXi-1.7.6.tar.gz" license("MIT AND X11") @@ -25,6 +25,8 @@ class Libxi(AutotoolsPackage, XorgPackage): version("1.7.7", sha256="501f49e9c85609da17614d711aa4931fd128011042ff1cae53a16ce03e51ff5e") version("1.7.6", sha256="4e88fa7decd287e58140ea72238f8d54e4791de302938c83695fc0c9ac102b7e") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("libx11@1.6:") depends_on("libxext@1.0.99.1:") diff --git a/var/spack/repos/builtin/packages/libxinerama/package.py b/var/spack/repos/builtin/packages/libxinerama/package.py index ac6fad3a23f283..b29ffafd9ca3da 100644 --- a/var/spack/repos/builtin/packages/libxinerama/package.py +++ b/var/spack/repos/builtin/packages/libxinerama/package.py @@ -9,7 +9,7 @@ class Libxinerama(AutotoolsPackage, XorgPackage): """libXinerama - API for Xinerama extension to X11 Protocol.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXinerama" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXinerama" xorg_mirror_path = "lib/libXinerama-1.1.3.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Libxinerama(AutotoolsPackage, XorgPackage): version("1.1.4", sha256="64de45e18cc76b8e703cb09b3c9d28bd16e3d05d5cd99f2d630de2d62c3acc18") version("1.1.3", sha256="0ba243222ae5aba4c6a3d7a394c32c8b69220a6872dbb00b7abae8753aca9a44") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libxkbcommon/package.py b/var/spack/repos/builtin/packages/libxkbcommon/package.py index f8af4ede749b83..5b74ff5c3dc3d8 100644 --- a/var/spack/repos/builtin/packages/libxkbcommon/package.py +++ b/var/spack/repos/builtin/packages/libxkbcommon/package.py @@ -22,6 +22,8 @@ class Libxkbcommon(MesonPackage, AutotoolsPackage): license("MIT") + version("1.7.0", sha256="65782f0a10a4b455af9c6baab7040e2f537520caa2ec2092805cdfd36863b247") + version("1.6.0", sha256="0edc14eccdd391514458bc5f5a4b99863ed2d651e4dd761a90abf4f46ef99c2b") version("1.5.0", sha256="560f11c4bbbca10f495f3ef7d3a6aa4ca62b4f8fb0b52e7d459d18a26e46e017") version("1.4.1", sha256="943c07a1e2198026d8102b17270a1f406e4d3d6bbc4ae105b9e1b82d7d136b39") version("1.4.0", sha256="106cec5263f9100a7e79b5f7220f889bc78e7d7ffc55d2b6fdb1efefb8024031") @@ -41,11 +43,14 @@ class Libxkbcommon(MesonPackage, AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + variant("wayland", default=False, description="Enable Wayland support") depends_on("meson@0.41:", type="build", when="@0.9:") depends_on("meson@0.49:", type="build", when="@1.0:") depends_on("meson@0.51:", type="build", when="@1.5:") + depends_on("meson@0.52:", type="build", when="@1.6:") depends_on("pkgconfig@0.9.0:", type="build") depends_on("bison", type="build") depends_on("util-macros") @@ -59,12 +64,17 @@ class Libxkbcommon(MesonPackage, AutotoolsPackage): class MesonBuilder(spack.build_systems.meson.MesonBuilder): def meson_args(self): - return [ + args = [ "-Dxkb-config-root={0}".format(self.spec["xkbdata"].prefix), "-Denable-docs=false", "-Denable-wayland=" + str(self.spec.satisfies("+wayland")), ] + if self.spec.satisfies("@1.6:"): + args.append("-Denable-bash-completion=false") + + return args + class AutotoolsBuilder(spack.build_systems.autotools.AutotoolsBuilder): def configure_args(self): diff --git a/var/spack/repos/builtin/packages/libxkbfile/package.py b/var/spack/repos/builtin/packages/libxkbfile/package.py index 2b8f39215a5dd2..7d4917232acfbb 100644 --- a/var/spack/repos/builtin/packages/libxkbfile/package.py +++ b/var/spack/repos/builtin/packages/libxkbfile/package.py @@ -9,18 +9,21 @@ class Libxkbfile(AutotoolsPackage, XorgPackage): """XKB file handling routines.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libxkbfile" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libxkbfile" xorg_mirror_path = "lib/libxkbfile-1.0.9.tar.gz" license("MIT") maintainers("wdconinc") + version("1.1.3", sha256="c4c2687729d1f920f165ebb96557a1ead2ef655809ab5eaa66a1ad36dc31050d") version("1.1.2", sha256="d1a7e659bc7ae1aa1fc1ecced261c734df5ad5d86af1ef7a946be0e2d841e51d") version("1.1.1", sha256="87faee6d4873c5631e8bb53e85134084b862185da682de8617f08ca18d82e216") version("1.1.0", sha256="2a92adda3992aa7cbad758ef0b8dfeaedebb49338b772c64ddf369d78c1c51d3") version("1.0.9", sha256="95df50570f38e720fb79976f603761ae6eff761613eb56f258c3cb6bab4fd5e3") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("kbproto") diff --git a/var/spack/repos/builtin/packages/libxkbui/package.py b/var/spack/repos/builtin/packages/libxkbui/package.py index 4167ed1629e851..cb8a9cf6021145 100644 --- a/var/spack/repos/builtin/packages/libxkbui/package.py +++ b/var/spack/repos/builtin/packages/libxkbui/package.py @@ -9,11 +9,13 @@ class Libxkbui(AutotoolsPackage, XorgPackage): """X.org libxkbui library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libxkbui/" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libxkbui/" xorg_mirror_path = "lib/libxkbui-1.0.2.tar.gz" version("1.0.2", sha256="196ab4867f3754caae34e51a663cbce26b4af819db3960f1fc4fb42c6a3c535d") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxt") depends_on("libxkbfile") diff --git a/var/spack/repos/builtin/packages/libxml2/package.py b/var/spack/repos/builtin/packages/libxml2/package.py index c953c32e84bd19..fc665b12e44548 100644 --- a/var/spack/repos/builtin/packages/libxml2/package.py +++ b/var/spack/repos/builtin/packages/libxml2/package.py @@ -4,6 +4,8 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) import os +import llnl.util.filesystem as fs + import spack.builder from spack.build_systems import autotools, nmake from spack.package import * @@ -42,6 +44,8 @@ def url_for_version(self, version): version("2.9.2", sha256="5178c30b151d044aefb1b08bf54c3003a0ac55c59c866763997529d60770d5bc") version("2.7.8", sha256="cda23bc9ebd26474ca8f3d67e7d1c4a1f1e7106364b690d822e009fdc3c417ec") + depends_on("c", type="build") # generated + variant("python", default=False, description="Enable Python support") variant("shared", default=True, description="Build shared library") variant("pic", default=True, description="Enable position-independent code (PIC)") @@ -244,19 +248,30 @@ def makefile_name(self): @property def build_directory(self): - return os.path.join(self.stage.source_path, "win32") + return fs.windows_sfn(os.path.join(self.stage.source_path, "win32")) def configure(self, pkg, spec, prefix): with working_dir(self.build_directory): opts = [ - "prefix=%s" % prefix, + "prefix=%s" % fs.windows_sfn(prefix), "compiler=msvc", "iconv=no", "zlib=yes", "lzma=yes", - "lib=%s" % ";".join((spec["zlib-api"].prefix.lib, spec["xz"].prefix.lib)), + "lib=%s" + % ";".join( + ( + fs.windows_sfn(spec["zlib-api"].prefix.lib), + fs.windows_sfn(spec["xz"].prefix.lib), + ) + ), "include=%s" - % ";".join((spec["zlib-api"].prefix.include, spec["xz"].prefix.include)), + % ";".join( + ( + fs.windows_sfn(spec["zlib-api"].prefix.include), + fs.windows_sfn(spec["xz"].prefix.include), + ) + ), ] if "+python" in spec: opts.append("python=yes") diff --git a/var/spack/repos/builtin/packages/libxmu/package.py b/var/spack/repos/builtin/packages/libxmu/package.py index 723f326fee1977..7e79a2477847c4 100644 --- a/var/spack/repos/builtin/packages/libxmu/package.py +++ b/var/spack/repos/builtin/packages/libxmu/package.py @@ -12,17 +12,22 @@ class Libxmu(AutotoolsPackage, XorgPackage): that it may be layered on top of any proprietary implementation of Xlib or Xt.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXmu" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXmu" xorg_mirror_path = "lib/libXmu-1.1.2.tar.gz" license("MIT") maintainers("wdconinc") + version("1.2.1", sha256="bf0902583dd1123856c11e0a5085bd3c6e9886fbbd44954464975fd7d52eb599") + version("1.2.0", sha256="b4686c4b4570044bcfc35bfaa3edbe68185ddf8e3250387f74a140c8e45afb2f") version("1.1.4", sha256="3091d711cdc1d8ea0f545a13b90d1464c3c3ab64778fd121f0d789b277a80289") version("1.1.2", sha256="e5fd4bacef068f9509b8226017205040e38d3fba8d2de55037200e7176c13dba") + depends_on("c", type="build") # generated + depends_on("libxt") + depends_on("libxt@1.1:", when="@1.2:") depends_on("libxext") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/libxp/package.py b/var/spack/repos/builtin/packages/libxp/package.py index 03513df5ecb48c..28d08726637037 100644 --- a/var/spack/repos/builtin/packages/libxp/package.py +++ b/var/spack/repos/builtin/packages/libxp/package.py @@ -9,7 +9,7 @@ class Libxp(AutotoolsPackage, XorgPackage): """libXp - X Print Client Library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXp" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXp" xorg_mirror_path = "lib/libXp-1.0.3.tar.gz" maintainers("wdconinc") @@ -17,6 +17,8 @@ class Libxp(AutotoolsPackage, XorgPackage): version("1.0.4", sha256="05e46af1ccb68f1752cca5879774a4fb9bf3b19fe088eb745034956e0c6fadba") version("1.0.3", sha256="f6b8cc4ef05d3eafc9ef5fc72819dd412024b4ed60197c0d5914758125817e9c") + depends_on("c", type="build") # generated + depends_on("libx11@1.6:") depends_on("libxext") depends_on("libxau") diff --git a/var/spack/repos/builtin/packages/libxpm/package.py b/var/spack/repos/builtin/packages/libxpm/package.py index 0029d93cdd8dec..fa368d39db4601 100644 --- a/var/spack/repos/builtin/packages/libxpm/package.py +++ b/var/spack/repos/builtin/packages/libxpm/package.py @@ -9,7 +9,7 @@ class Libxpm(AutotoolsPackage, XorgPackage): """libXpm - X Pixmap (XPM) image file format library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXpm" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXpm" xorg_mirror_path = "lib/libXpm-3.5.12.tar.gz" license("X11") @@ -28,6 +28,8 @@ class Libxpm(AutotoolsPackage, XorgPackage): version("3.5.8", sha256="06472c7fdd175ea54c84162a428be19c154e7dda03d8bf91beee7f1d104669a6") version("3.5.7", sha256="422fbb311c4fe6ef337e937eb3adc8617a4320bd3e00fce06850d4360829b3ae") + depends_on("c", type="build") # generated + depends_on("gettext") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/libxpresent/package.py b/var/spack/repos/builtin/packages/libxpresent/package.py index e17ca584f9bb89..a91eedfd00fa9f 100644 --- a/var/spack/repos/builtin/packages/libxpresent/package.py +++ b/var/spack/repos/builtin/packages/libxpresent/package.py @@ -10,7 +10,7 @@ class Libxpresent(AutotoolsPackage, XorgPackage): """This package contains header files and documentation for the Present extension. Library and server implementations are separate.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXpresent/" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXpresent/" xorg_mirror_path = "lib/libXpresent-1.0.0.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Libxpresent(AutotoolsPackage, XorgPackage): version("1.0.1", sha256="8ebf8567a8f6afe5a64275a2ecfd4c84e957970c27299d964350f60be9f3541d") version("1.0.0", sha256="92f1bdfb67ae2ffcdb25ad72c02cac5e4912dc9bc792858240df1d7f105946fa") + depends_on("c", type="build") # generated + depends_on("libx11", type="link") depends_on("libxext", type="link") depends_on("libxfixes", type="link") diff --git a/var/spack/repos/builtin/packages/libxprintapputil/package.py b/var/spack/repos/builtin/packages/libxprintapputil/package.py index 990e29e18f8046..6aea4db93ec5a3 100644 --- a/var/spack/repos/builtin/packages/libxprintapputil/package.py +++ b/var/spack/repos/builtin/packages/libxprintapputil/package.py @@ -9,11 +9,13 @@ class Libxprintapputil(AutotoolsPackage, XorgPackage): """Xprint application utility routines.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXprintAppUtil/" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXprintAppUtil/" xorg_mirror_path = "lib/libXprintAppUtil-1.0.1.tar.gz" version("1.0.1", sha256="5af3939ffe15508b942bc1e325a29a95b1c85e8900a5f65a896101e63048bbf7") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxp") depends_on("libxprintutil") diff --git a/var/spack/repos/builtin/packages/libxprintutil/package.py b/var/spack/repos/builtin/packages/libxprintutil/package.py index c23f59de90922b..e79caaecf338c2 100644 --- a/var/spack/repos/builtin/packages/libxprintutil/package.py +++ b/var/spack/repos/builtin/packages/libxprintutil/package.py @@ -9,11 +9,13 @@ class Libxprintutil(AutotoolsPackage, XorgPackage): """Xprint application utility routines.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXprintUtil/" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXprintUtil/" xorg_mirror_path = "lib/libXprintUtil-1.0.1.tar.gz" version("1.0.1", sha256="220924216f98ef8f7aa4cff33629edb1171ad10f8ea302a1eb85055545d4d195") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxp") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/libxrandr/package.py b/var/spack/repos/builtin/packages/libxrandr/package.py index 3f476394825ab2..0a7f7b2ffb7d14 100644 --- a/var/spack/repos/builtin/packages/libxrandr/package.py +++ b/var/spack/repos/builtin/packages/libxrandr/package.py @@ -9,7 +9,7 @@ class Libxrandr(AutotoolsPackage, XorgPackage): """libXrandr - X Resize, Rotate and Reflection extension library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXrandr" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXrandr" xorg_mirror_path = "lib/libXrandr-1.5.0.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Libxrandr(AutotoolsPackage, XorgPackage): version("1.5.3", sha256="3ad316c1781fe2fe22574b819e81f0eff087a8560377f521ba932238b41b251f") version("1.5.0", sha256="1b594a149e6b124aab7149446f2fd886461e2935eca8dca43fe83a70cf8ec451") + depends_on("c", type="build") # generated + depends_on("libx11@1.6:") depends_on("libxext") depends_on("libxrender") diff --git a/var/spack/repos/builtin/packages/libxrender/package.py b/var/spack/repos/builtin/packages/libxrender/package.py index ee72890dd4b1fe..88fc25d8a570fe 100644 --- a/var/spack/repos/builtin/packages/libxrender/package.py +++ b/var/spack/repos/builtin/packages/libxrender/package.py @@ -9,7 +9,7 @@ class Libxrender(AutotoolsPackage, XorgPackage): """libXrender - library for the Render Extension to the X11 protocol.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXrender" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXrender" xorg_mirror_path = "lib/libXrender-0.9.10.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Libxrender(AutotoolsPackage, XorgPackage): version("0.9.10", sha256="770527cce42500790433df84ec3521e8bf095dfe5079454a92236494ab296adf") version("0.9.9", sha256="beeac64ff8d225f775019eb7c688782dee9f4cc7b412a65538f8dde7be4e90fe") + depends_on("c", type="build") # generated + depends_on("libx11@1.6:") depends_on("renderproto@0.9:") diff --git a/var/spack/repos/builtin/packages/libxres/package.py b/var/spack/repos/builtin/packages/libxres/package.py index 1b3c88f3adff79..2fc2137b5a4668 100644 --- a/var/spack/repos/builtin/packages/libxres/package.py +++ b/var/spack/repos/builtin/packages/libxres/package.py @@ -9,7 +9,7 @@ class Libxres(AutotoolsPackage, XorgPackage): """libXRes - X-Resource extension client library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXRes" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXRes" xorg_mirror_path = "lib/libXres-1.0.7.tar.gz" license("custom") @@ -21,6 +21,8 @@ class Libxres(AutotoolsPackage, XorgPackage): version("1.2.0", sha256="5b62feee09f276d74054787df030fceb41034de84174abec6d81c591145e043a") version("1.0.7", sha256="488c9fa14b38f794d1f019fe62e6b06514a39f1a7538e55ece8faf22482fefcd") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libxscrnsaver/package.py b/var/spack/repos/builtin/packages/libxscrnsaver/package.py index 9fbf54120b79b5..e624e737efcbb3 100644 --- a/var/spack/repos/builtin/packages/libxscrnsaver/package.py +++ b/var/spack/repos/builtin/packages/libxscrnsaver/package.py @@ -9,7 +9,7 @@ class Libxscrnsaver(AutotoolsPackage, XorgPackage): """XScreenSaver - X11 Screen Saver extension client library""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXScrnSaver" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXScrnSaver" xorg_mirror_path = "lib/libXScrnSaver-1.2.2.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Libxscrnsaver(AutotoolsPackage, XorgPackage): version("1.2.3", sha256="4f74e7e412144591d8e0616db27f433cfc9f45aae6669c6c4bb03e6bf9be809a") version("1.2.2", sha256="e12ba814d44f7b58534c0d8521e2d4574f7bf2787da405de4341c3b9f4cc8d96") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libxshmfence/package.py b/var/spack/repos/builtin/packages/libxshmfence/package.py index fa05f7ee5965b3..45c47fcd4b60b4 100644 --- a/var/spack/repos/builtin/packages/libxshmfence/package.py +++ b/var/spack/repos/builtin/packages/libxshmfence/package.py @@ -21,6 +21,8 @@ class Libxshmfence(AutotoolsPackage, XorgPackage): version("1.3", sha256="b884300d26a14961a076fbebc762a39831cb75f92bed5ccf9836345b459220c7") version("1.2", sha256="d21b2d1fd78c1efbe1f2c16dae1cb23f8fd231dcf891465b8debe636a9054b0c") + depends_on("c", type="build") # generated + depends_on("xproto") depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") diff --git a/var/spack/repos/builtin/packages/libxslt/package.py b/var/spack/repos/builtin/packages/libxslt/package.py index 102d5d2d34b620..aeb2e1b0808de8 100644 --- a/var/spack/repos/builtin/packages/libxslt/package.py +++ b/var/spack/repos/builtin/packages/libxslt/package.py @@ -24,6 +24,8 @@ class Libxslt(AutotoolsPackage): version("1.1.28", sha256="5fc7151a57b89c03d7b825df5a0fae0a8d5f05674c0e7cf2937ecec4d54a028c") version("1.1.26", sha256="55dd52b42861f8a02989d701ef716d6280bfa02971e967c285016f99c66e3db1") + depends_on("c", type="build") # generated + variant("crypto", default=True, description="Build libexslt with crypto support") variant("python", default=False, description="Build Python bindings") diff --git a/var/spack/repos/builtin/packages/libxsmm/package.py b/var/spack/repos/builtin/packages/libxsmm/package.py index 71e60f77032ff0..2747aa7627f93e 100644 --- a/var/spack/repos/builtin/packages/libxsmm/package.py +++ b/var/spack/repos/builtin/packages/libxsmm/package.py @@ -63,6 +63,10 @@ class Libxsmm(MakefilePackage): version("1.4.1", sha256="c19be118694c9b4e9a61ef4205b1e1a7e0c400c07f9bce65ae430d2dc2be5fe1") version("1.4", sha256="cf483a370d802bd8800c06a12d14d2b4406a745c8a0b2c8722ccc992d0cd72dd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=False, description="With shared libraries (and static libraries).") variant("debug", default=False, description="With call-trace (LIBXSMM_TRACE); unoptimized.") variant( diff --git a/var/spack/repos/builtin/packages/libxstream/package.py b/var/spack/repos/builtin/packages/libxstream/package.py index 6cf99d43907078..8002a7ace6abd1 100644 --- a/var/spack/repos/builtin/packages/libxstream/package.py +++ b/var/spack/repos/builtin/packages/libxstream/package.py @@ -18,6 +18,9 @@ class Libxstream(Package): version("0.9.0", sha256="03365f23b337533b8e5a049a24bc5a91c0f1539dd042ca5312abccc8f713b473") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def patch(self): kwargs = {"ignore_absent": False, "backup": True, "string": True} makefile = FileFilter("Makefile.inc") diff --git a/var/spack/repos/builtin/packages/libxt/package.py b/var/spack/repos/builtin/packages/libxt/package.py index 74f1614b751135..7a3804f336c442 100644 --- a/var/spack/repos/builtin/packages/libxt/package.py +++ b/var/spack/repos/builtin/packages/libxt/package.py @@ -9,7 +9,7 @@ class Libxt(AutotoolsPackage, XorgPackage): """libXt - X Toolkit Intrinsics library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXt" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXt" xorg_mirror_path = "lib/libXt-1.1.5.tar.gz" license("MIT") @@ -21,6 +21,8 @@ class Libxt(AutotoolsPackage, XorgPackage): version("1.2.0", sha256="d4bee88898fc5e1dc470e361430c72fbc529b9cdbbb6c0ed3affea3a39f97d8d") version("1.1.5", sha256="b59bee38a9935565fa49dc1bfe84cb30173e2e07e1dcdf801430d4b54eb0caa3") + depends_on("c", type="build") # generated + depends_on("libsm") depends_on("libice") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/libxtrap/package.py b/var/spack/repos/builtin/packages/libxtrap/package.py index 7027e0e6e42732..652a26a8d7998c 100644 --- a/var/spack/repos/builtin/packages/libxtrap/package.py +++ b/var/spack/repos/builtin/packages/libxtrap/package.py @@ -18,11 +18,13 @@ class Libxtrap(AutotoolsPackage, XorgPackage): As X11R6 was released in 1994, XTrap has now been deprecated for over 15 years, and uses of it should be quite rare.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXTrap" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXTrap" xorg_mirror_path = "lib/libXTrap-1.0.1.tar.gz" version("1.0.1", sha256="db748e299dcc9af68428795b898a4a96cf806f79b75786781136503e4fce5e17") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxt") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libxtst/package.py b/var/spack/repos/builtin/packages/libxtst/package.py index 3fbe336f8d46c3..112f8f5b529b84 100644 --- a/var/spack/repos/builtin/packages/libxtst/package.py +++ b/var/spack/repos/builtin/packages/libxtst/package.py @@ -18,7 +18,7 @@ class Libxtst(AutotoolsPackage, XorgPackage): The RECORD extension supports the recording and reporting of all core X protocol and arbitrary X extension protocol.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXtst" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXtst" xorg_mirror_path = "lib/libXtst-1.2.2.tar.gz" license("MIT") @@ -29,6 +29,8 @@ class Libxtst(AutotoolsPackage, XorgPackage): version("1.2.3", sha256="a0c83acce02d4923018c744662cb28eb0dbbc33b4adc027726879ccf68fbc2c2") version("1.2.2", sha256="221838960c7b9058cd6795c1c3ee8e25bae1c68106be314bc3036a4f26be0e6c") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext@1.0.99.4:") depends_on("libxi") diff --git a/var/spack/repos/builtin/packages/libxv/package.py b/var/spack/repos/builtin/packages/libxv/package.py index bc1019e575d3c7..4e01e3be04fc7c 100644 --- a/var/spack/repos/builtin/packages/libxv/package.py +++ b/var/spack/repos/builtin/packages/libxv/package.py @@ -10,7 +10,7 @@ class Libxv(AutotoolsPackage, XorgPackage): """libXv - library for the X Video (Xv) extension to the X Window System.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXv" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXv" xorg_mirror_path = "lib/libXv-1.0.10.tar.gz" license("MIT") @@ -21,6 +21,8 @@ class Libxv(AutotoolsPackage, XorgPackage): version("1.0.11", sha256="c4112532889b210e21cf05f46f0f2f8354ff7e1b58061e12d7a76c95c0d47bb1") version("1.0.10", sha256="89a664928b625558268de81c633e300948b3752b0593453d7815f8775bab5293") + depends_on("c", type="build") # generated + depends_on("libx11@1.6:") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libxvmc/package.py b/var/spack/repos/builtin/packages/libxvmc/package.py index a970c24a34aab6..cbe654022e88d0 100644 --- a/var/spack/repos/builtin/packages/libxvmc/package.py +++ b/var/spack/repos/builtin/packages/libxvmc/package.py @@ -9,19 +9,22 @@ class Libxvmc(AutotoolsPackage, XorgPackage): """X.org libXvMC library.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXvMC" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXvMC" xorg_mirror_path = "lib/libXvMC-1.0.9.tar.gz" license("MIT") maintainers("wdconinc") + version("1.0.14", sha256="3ad5d2b991219e2bf9b2f85d40b12c16f1afec038715e462f6058af73a9b5ef8") version("1.0.13", sha256="e630b4373af8c67a7c8f07ebe626a1269a613d262d1f737b57231a06f7c34b4e") version("1.0.12", sha256="024c9ec4f001f037eeca501ee724c7e51cf287eb69ced8c6126e16e7fa9864b5") version("1.0.11", sha256="0b931d216b23b95df87cc65f7bb7acef4120d9263adb0a4d90856ba1f7a390da") version("1.0.10", sha256="d8306f71c798d10409bb181b747c2644e1d60c05773c742c12304ab5aa5c8436") version("1.0.9", sha256="090f087fe65b30b3edfb996c79ff6cf299e473fb25e955fff1c4e9cb624da2c2") + depends_on("c", type="build") # generated + depends_on("libx11@1.6:") depends_on("libxext") depends_on("libxv") diff --git a/var/spack/repos/builtin/packages/libxxf86dga/package.py b/var/spack/repos/builtin/packages/libxxf86dga/package.py index c0d1300ef640fc..9f67a2a88c0fc7 100644 --- a/var/spack/repos/builtin/packages/libxxf86dga/package.py +++ b/var/spack/repos/builtin/packages/libxxf86dga/package.py @@ -9,7 +9,7 @@ class Libxxf86dga(AutotoolsPackage, XorgPackage): """libXxf86dga - Client library for the XFree86-DGA extension.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXxf86dga" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXxf86dga" xorg_mirror_path = "lib/libXxf86dga-1.1.4.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Libxxf86dga(AutotoolsPackage, XorgPackage): version("1.1.5", sha256="715e2bf5caf6276f0858eb4b11a1aef1a26beeb40dce2942387339da395bef69") version("1.1.4", sha256="e6361620a15ceba666901ca8423e8be0c6ed0271a7088742009160349173766b") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libxxf86misc/package.py b/var/spack/repos/builtin/packages/libxxf86misc/package.py index f9cd5db8a79a32..d06dc5326021e4 100644 --- a/var/spack/repos/builtin/packages/libxxf86misc/package.py +++ b/var/spack/repos/builtin/packages/libxxf86misc/package.py @@ -9,7 +9,7 @@ class Libxxf86misc(AutotoolsPackage, XorgPackage): """libXxf86misc - Extension library for the XFree86-Misc X extension.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXxf86misc" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXxf86misc" xorg_mirror_path = "lib/libXxf86misc-1.0.3.tar.gz" maintainers("wdconinc") @@ -17,6 +17,8 @@ class Libxxf86misc(AutotoolsPackage, XorgPackage): version("1.0.4", sha256="63a68b2fafd03236f9b0135de21976e9194d6d811ca2fd774c13a6b4be576676") version("1.0.3", sha256="358f692f793af00f6ef4c7a8566c1bcaeeea37e417337db3f519522cc1df3946") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libxxf86vm/package.py b/var/spack/repos/builtin/packages/libxxf86vm/package.py index 970ff1991f6016..dd04e35435eaff 100644 --- a/var/spack/repos/builtin/packages/libxxf86vm/package.py +++ b/var/spack/repos/builtin/packages/libxxf86vm/package.py @@ -9,7 +9,7 @@ class Libxxf86vm(AutotoolsPackage, XorgPackage): """libXxf86vm - Extension library for the XFree86-VidMode X extension.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libXxf86vm" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libXxf86vm" xorg_mirror_path = "lib/libXxf86vm-1.1.4.tar.gz" license("MIT") @@ -19,6 +19,8 @@ class Libxxf86vm(AutotoolsPackage, XorgPackage): version("1.1.5", sha256="f3f1c29fef8accb0adbd854900c03c6c42f1804f2bc1e4f3ad7b2e1f3b878128") version("1.1.4", sha256="5108553c378a25688dcb57dca383664c36e293d60b1505815f67980ba9318a99") + depends_on("c", type="build") # generated + depends_on("libx11@1.6:") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/libyaml/package.py b/var/spack/repos/builtin/packages/libyaml/package.py index e3f46d0367453e..47cb11570927b3 100644 --- a/var/spack/repos/builtin/packages/libyaml/package.py +++ b/var/spack/repos/builtin/packages/libyaml/package.py @@ -29,6 +29,8 @@ class Libyaml(AutotoolsPackage): version("0.1.2", sha256="5beb94529cc7ac79b17e354f9b03aea311f5af17be5d48bc39e6f1db5059f70f") version("0.1.1", sha256="76444692a94de4e6776a1bdf3b735e8f016bb374ae7c60496f8032fdc6085889") + depends_on("c", type="build") # generated + depends_on("automake", when="@master") depends_on("autoconf", when="@master") depends_on("libtool", when="@master") diff --git a/var/spack/repos/builtin/packages/libyogrt/package.py b/var/spack/repos/builtin/packages/libyogrt/package.py index f63d1736b9dfdb..d18dd7b31b4848 100644 --- a/var/spack/repos/builtin/packages/libyogrt/package.py +++ b/var/spack/repos/builtin/packages/libyogrt/package.py @@ -16,6 +16,7 @@ class Libyogrt(AutotoolsPackage): license("LGPL-2.1-or-later") + version("1.35", sha256="a03b3d24da49af626351aaca9ab3eaff102ed41d5171f1bcb2ff26a561bd0cd6") version("1.33", sha256="797d20c49cdc4f6beae8660b4f41ba7ac13f7e93a0344b47f0bdc64f780d1398") version("1.27", sha256="c57ce60770b61aa20bc83fe34ff52b5e444964338df3786f282d0d9bcdd26138") version("1.24", sha256="36695030e72b24b1f22bfcfe42bfd1d3c87f9c0eea5e94ce0120782581ea522f") @@ -29,6 +30,9 @@ class Libyogrt(AutotoolsPackage): version("1.20-3", sha256="61a8f28f452aef0e09d700dbaaffd91ae3855f7ac221c7ebe478a028df635e31") version("1.20-2", sha256="bf22a82ab3bfede780be3fb6c132cc354234f8d57d3cccd58fe594f074ed7f95") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # libyogrt supports the following schedulers: # flux, lcrm, lsf, moab, slurm, AIX+slurm @@ -57,7 +61,7 @@ class Libyogrt(AutotoolsPackage): def url_for_version(self, version): if version < Version("1.21"): - return "https://github.com/LLNL/libyogrt/archive/%s.tar.gz" % version + return f"https://github.com/LLNL/libyogrt/archive/{version}.tar.gz" else: return "https://github.com/LLNL/libyogrt/releases/download/{0}/libyogrt-{0}.tar.gz".format( version @@ -82,11 +86,11 @@ def configure_args(self): args.append("--with-lsf") args.append("LIBS=-llsf -lrt -lnsl") elif sched == "flux": - args.append("--with-flux=%s" % (self.spec["flux-core"].prefix)) + args.append(f"--with-flux={self.spec['flux-core'].prefix}") elif sched != "system": - args.append("--with-%s=%s" % (sched, self.spec[sched].prefix)) + args.append(f"--with-{sched}={self.spec[sched].prefix}") - if "+static" in self.spec: + if self.spec.satisfies("+static"): args.append("--enable-static=yes") return args @@ -108,4 +112,4 @@ def create_yogrt_conf(self): # create conf file to inform libyogrt about job scheduler with open(os.path.join(etcpath, "yogrt.conf"), "w+") as f: - f.write("backend=%s\n" % sched) + f.write(f"backend={sched}\n") diff --git a/var/spack/repos/builtin/packages/libzip/package.py b/var/spack/repos/builtin/packages/libzip/package.py index 79c31a8696b8c9..eff9884080af76 100644 --- a/var/spack/repos/builtin/packages/libzip/package.py +++ b/var/spack/repos/builtin/packages/libzip/package.py @@ -6,20 +6,51 @@ from spack.package import * -class Libzip(AutotoolsPackage): +class Libzip(CMakePackage, AutotoolsPackage): """libzip is a C library for reading, creating, and modifying zip archives.""" - homepage = "https://nih.at/libzip/index.html" - url = "https://nih.at/libzip/libzip-1.2.0.tar.gz" + homepage = "https://libzip.org/" license("BSD-3-Clause") - version("1.3.2", sha256="ab4c34eb6c3a08b678cd0f2450a6c57a13e9618b1ba34ee45d00eb5327316457") - version("1.2.0", sha256="6cf9840e427db96ebf3936665430bab204c9ebbd0120c326459077ed9c907d9f") + # current versions are released on GitHub + version("1.10.1", sha256="9669ae5dfe3ac5b3897536dc8466a874c8cf2c0e3b1fdd08d75b273884299363") + version("1.9.2", sha256="fd6a7f745de3d69cf5603edc9cb33d2890f0198e415255d0987a0cf10d824c6f") + version("1.8.0", sha256="30ee55868c0a698d3c600492f2bea4eb62c53849bcf696d21af5eb65f3f3839e") + version("1.7.3", sha256="0e2276c550c5a310d4ebf3a2c3dfc43fb3b4602a072ff625842ad4f3238cb9cc") + version( + "1.6.1", + sha256="06eb8e9141fd19e2788cabaea9c9c2fd4d488d9e1484eb474bbfcac78e7b1d88", + url="https://github.com/nih-at/libzip/releases/download/rel-1-6-1/libzip-1.6.1.tar.gz", + ) + # older releases are available on libzip.org + version( + "1.3.2", + sha256="ab4c34eb6c3a08b678cd0f2450a6c57a13e9618b1ba34ee45d00eb5327316457", + deprecated=True, + ) + version( + "1.2.0", + sha256="6cf9840e427db96ebf3936665430bab204c9ebbd0120c326459077ed9c907d9f", + deprecated=True, + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + def url_for_version(self, version): + if version < Version("1.6"): + return f"https://libzip.org/download/libzip-{version}.tar.gz" + return f"https://github.com/nih-at/libzip/releases/download/v{version}/libzip-{version}.tar.gz" depends_on("zlib-api") + # Build system + build_system( + conditional("cmake", when="@1.4:"), conditional("autotools", when="@:1.3"), default="cmake" + ) + @property def headers(self): # Up to version 1.3.0 zipconf.h was installed outside of self.prefix.include diff --git a/var/spack/repos/builtin/packages/libzmq/package.py b/var/spack/repos/builtin/packages/libzmq/package.py index 2028dcd55e026d..423fc9c43dcf30 100644 --- a/var/spack/repos/builtin/packages/libzmq/package.py +++ b/var/spack/repos/builtin/packages/libzmq/package.py @@ -35,6 +35,9 @@ class Libzmq(AutotoolsPackage): version("4.0.6", sha256="28a2a9c9b77014c39087a498942449df18bb9885cdb63334833525a1d19f2894") version("4.0.5", sha256="3bc93c5f67370341428364ce007d448f4bb58a0eaabd0a60697d8086bc43342b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "libsodium", default=True, diff --git a/var/spack/repos/builtin/packages/liggghts/package.py b/var/spack/repos/builtin/packages/liggghts/package.py index d67890824cb16d..5e02d21d85b05a 100644 --- a/var/spack/repos/builtin/packages/liggghts/package.py +++ b/var/spack/repos/builtin/packages/liggghts/package.py @@ -22,6 +22,10 @@ class Liggghts(MakefilePackage): version("3.8.0", sha256="9cb2e6596f584463ac2f80e3ff7b9588b7e3638c44324635b6329df87b90ab03") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("jpeg", default=True, description="Enable JPEG support") variant("gzip", default=True, description="Enable GZIP for some input and output files") diff --git a/var/spack/repos/builtin/packages/lighttpd/package.py b/var/spack/repos/builtin/packages/lighttpd/package.py index 7048111b6561ba..96a2cf04ec67ee 100644 --- a/var/spack/repos/builtin/packages/lighttpd/package.py +++ b/var/spack/repos/builtin/packages/lighttpd/package.py @@ -24,6 +24,8 @@ class Lighttpd(CMakePackage): version("1.4.50", sha256="c9a9f175aca6db22ebebbc47de52c54a99bbd1dce8d61bb75103609a3d798235") version("1.4.49", sha256="8b744baf9f29c386fff1a6d2e435491e726cb8d29cfdb1fe20ab782ee2fc2ac7") + depends_on("c", type="build") # generated + depends_on("pcre") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/ligra/package.py b/var/spack/repos/builtin/packages/ligra/package.py index 749cceeab26b59..737dd9c2509a62 100644 --- a/var/spack/repos/builtin/packages/ligra/package.py +++ b/var/spack/repos/builtin/packages/ligra/package.py @@ -21,6 +21,8 @@ class Ligra(MakefilePackage): version("1.1", sha256="a7311b96fabc286a8f1250d8a6e2d1b1e4545c720fa6bb4acf7ed31211fcc99a") version("1.0", sha256="fb39ae0a3eddb26f37b8cc0a543648575a50bcc488cecd4a5f1beaaf2458736c") + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Build with OpenMP") variant("mkl", default=False, description="Build with Intel MKL") # TODO: Add cilk variant when spack has a cilk plus package created. diff --git a/var/spack/repos/builtin/packages/likwid/package.py b/var/spack/repos/builtin/packages/likwid/package.py index eaa3c301a3c557..376f2ba46414e5 100644 --- a/var/spack/repos/builtin/packages/likwid/package.py +++ b/var/spack/repos/builtin/packages/likwid/package.py @@ -41,6 +41,10 @@ class Likwid(Package): version("4.3.1", sha256="4b40a96717da54514274d166f9b71928545468091c939c1d74109733279eaeb1") version("4.3.0", sha256="86fc5f82c80fcff1a643394627839ec79f1ca2bcfad30000eb7018da592588b4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + patch( "https://github.com/RRZE-HPC/likwid/commit/e0332ace8fe8ca7dcd4b4477a25e37944f173a5c.patch?full_index=1", when="@5.0.1", @@ -89,7 +93,6 @@ class Likwid(Package): depends_on("hwloc", when="@5.2.0:") depends_on("rocprofiler-dev", when="@5.3: +rocm") depends_on("rocm-core", when="@5.3: +rocm") - depends_on("rocm-smi", when="@5.3: +rocm") depends_on("rocm-smi-lib", when="@5.3: +rocm") # TODO: check diff --git a/var/spack/repos/builtin/packages/linaro-forge/package.py b/var/spack/repos/builtin/packages/linaro-forge/package.py index 108002ea5c7b63..18c03bb44dfa1b 100644 --- a/var/spack/repos/builtin/packages/linaro-forge/package.py +++ b/var/spack/repos/builtin/packages/linaro-forge/package.py @@ -23,6 +23,13 @@ class LinaroForge(Package): maintainers("kenche-linaro") if platform.machine() in ["aarch64", "arm64"]: + version( + "24.0.2", sha256="8346eb0375910498a83baff6833256c8221c2c06737670687bcf9f1497d9ede9" + ) + version( + "24.0.1", sha256="d9d8e8fd56894032ea98a5ff7885c16c0522a192d9cbf4e131581c65e34efb82" + ) + version("24.0", sha256="ee631177f5289127f0d3d99b600d437b4bd40c34c1c15388288b72543dc420ad") version( "23.1.2", sha256="8c01f4768a8f784f0bfa78c82dbd39e5077bbc6880b6f3c3704019eecfca5b3a" ) @@ -53,6 +60,7 @@ class LinaroForge(Package): "21.1.3", sha256="4a4ff7372aad5a31fc9e18b7b6c493691ab37d8d44a3158584e62d1ab82b0eeb" ) elif platform.machine() == "ppc64le": + # N.B. support for ppc64le was dropped in 24.0 version( "23.1.2", sha256="5c588a6b7391d75cced4016936d0c5a00023431269339432738ff33b860487b3" ) @@ -86,6 +94,13 @@ class LinaroForge(Package): "21.1.3", sha256="eecbc5686d60994c5468b2d7cd37bebe5d9ac0ba37bd1f98fbfc69b071db541e" ) elif platform.machine() == "x86_64": + version( + "24.0.2", sha256="e2ad12273d568560e948a9bcdd49b830a2309f247b146bf36579053f99ec59a3" + ) + version( + "24.0.1", sha256="70aa6b610d181c12be10e57d2fd3439261e2c6cb23d9f1f33303b85f04cb7bf2" + ) + version("24.0", sha256="5976067e3de14d0838e1069021a4a4a96d048824454668779473ff0776d66a01") version( "23.1.2", sha256="675d2d8e4510afefa0405eecb46ac8bf440ff35a5a40d5507dc12d29678a22bf" ) diff --git a/var/spack/repos/builtin/packages/linkphase3/package.py b/var/spack/repos/builtin/packages/linkphase3/package.py index 6eec3c55cd37d5..946a70dc177f52 100644 --- a/var/spack/repos/builtin/packages/linkphase3/package.py +++ b/var/spack/repos/builtin/packages/linkphase3/package.py @@ -16,6 +16,8 @@ class Linkphase3(Package): version("2017-06-14", commit="559913593fc818bb1adb29796a548cf5bf323827") + depends_on("fortran", type="build") # generated + def install(self, spec, prefix): fortran = Executable(self.compiler.fc) fortran("LINKPHASE3.f90", "-o", "LINKPHASE3") diff --git a/var/spack/repos/builtin/packages/linktest/package.py b/var/spack/repos/builtin/packages/linktest/package.py index ef8e510d06f9fc..b0163dd6167ab7 100644 --- a/var/spack/repos/builtin/packages/linktest/package.py +++ b/var/spack/repos/builtin/packages/linktest/package.py @@ -24,6 +24,8 @@ class Linktest(MakefilePackage): extension="tar.gz", ) + depends_on("c", type="build") # generated + depends_on("mpi") depends_on("sionlib") diff --git a/var/spack/repos/builtin/packages/linux-headers/package.py b/var/spack/repos/builtin/packages/linux-headers/package.py index 703e783352b081..1213d350142cb6 100644 --- a/var/spack/repos/builtin/packages/linux-headers/package.py +++ b/var/spack/repos/builtin/packages/linux-headers/package.py @@ -18,10 +18,15 @@ class LinuxHeaders(Package): license("GPL-2.0-only") + version("6.9.1", sha256="01b414ba98fd189ecd544435caf3860ae2a790e3ec48f5aa70fdf42dc4c5c04a") + version("6.8.9", sha256="f905f1238ea7a8e85314bacf283302e8097006010d25fcea726d0de0ea5bc9b6") version("6.5.2", sha256="2027e14057d568ad3ddc100dadf4c8853a49b031270478a61d88f6011572650f") version("6.2.8", sha256="fed0ad87d42f83a70ce019ff2800bc30a855e672e72bf6d54a014d98d344f665") version("4.9.10", sha256="bd6e05476fd8d9ea4945e11598d87bc97806bbc8d03556abbaaf809707661525") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): url = "https://www.kernel.org/pub/linux/kernel/v{0}.x/linux-{1}.tar.xz" return url.format(version.up_to(1), version) diff --git a/var/spack/repos/builtin/packages/linux-pam/package.py b/var/spack/repos/builtin/packages/linux-pam/package.py index e864d63b6b337c..484e9e2cb9a5d2 100644 --- a/var/spack/repos/builtin/packages/linux-pam/package.py +++ b/var/spack/repos/builtin/packages/linux-pam/package.py @@ -14,19 +14,56 @@ class LinuxPam(AutotoolsPackage): license("BSD-3-Clause") - version("1.5.1", sha256="201d40730b1135b1b3cdea09f2c28ac634d73181ccd0172ceddee3649c5792fc") + version("1.6.1", sha256="f8923c740159052d719dbfc2a2f81942d68dd34fcaf61c706a02c9b80feeef8e") + version("1.6.0", sha256="fff4a34e5bbee77e2e8f1992f27631e2329bcbf8a0563ddeb5c3389b4e3169ad") + version("1.5.3", sha256="7ac4b50feee004a9fa88f1dfd2d2fa738a82896763050cd773b3c54b0a818283") version("1.5.2", sha256="e4ec7131a91da44512574268f493c6d8ca105c87091691b8e9b56ca685d4f94d") + version("1.5.1", sha256="201d40730b1135b1b3cdea09f2c28ac634d73181ccd0172ceddee3649c5792fc") version("1.5.0", sha256="02d39854b508fae9dc713f7733bbcdadbe17b50de965aedddd65bcb6cc7852c8") version("1.4.0", sha256="cd6d928c51e64139be3bdb38692c68183a509b83d4f2c221024ccd4bcddfd034") version("1.3.1", sha256="eff47a4ecd833fbf18de9686632a70ee8d0794b79aecb217ebd0ce11db4cd0db") + variant("unix", default=True, description="Build pam_unix model") + variant("selinux", default=False, description="Build with selinux support") + variant("nls", default=False, description="Build with natural language support") + variant("xauth", default=False, description="Build with xauth support") + variant("openssl", default=False, description="Build with openssl support") + variant("lastlog", default=False, description="Build pam_lastlog model") + variant("regenerate-docu", default=False, description="Regenerate docs") + depends_on("libtirpc") + depends_on("libxcrypt") + depends_on("xauth", when="+xauth") + depends_on("c", type="build") + + with default_args(type="build"): + depends_on("m4") + depends_on("autoconf") + depends_on("automake") + depends_on("libtool") + depends_on("gettext", when="+nls") + with when("+regenerate-docu"): + depends_on("bison") + depends_on("flex") + depends_on("yacc") - depends_on("m4", type="build") - depends_on("autoconf", type="build") - depends_on("automake", type="build") - depends_on("libtool", type="build") + def flag_handler(self, name, flags): + if name == "ldflags" and self.spec.satisfies("+nls"): + flags += ["-lintl"] # Addresses https://github.com/spack/spack/issues/44637 + return (flags, None, None) def configure_args(self): - config_args = ["--includedir=" + self.prefix.include.security] - return config_args + args = [f"--includedir={self.prefix.include.security}"] + + args += self.enable_or_disable("nls") + args += self.enable_or_disable("openssl") + args += self.enable_or_disable("unix") + args += self.enable_or_disable("lastlog") + args += self.enable_or_disable("selinux") + args += self.enable_or_disable("regenerate-docu") + + if self.spec.satisfies("+xauth"): + xauth = self.spec["xauth"] + args.append(f"--with-xauth={xauth.prefix.bin.xauth}") + + return args diff --git a/var/spack/repos/builtin/packages/lis/package.py b/var/spack/repos/builtin/packages/lis/package.py index a969427f92b15c..111cecc27ff22f 100644 --- a/var/spack/repos/builtin/packages/lis/package.py +++ b/var/spack/repos/builtin/packages/lis/package.py @@ -16,6 +16,7 @@ class Lis(AutotoolsPackage): homepage = "https://www.ssisc.org/lis/index.en.html" url = "https://www.ssisc.org/lis/dl/lis-2.0.27.zip" + version("2.1.4", sha256="d94d634db49fff2368bb615225ee4fdde919c63b7a9bc1f81f7d166a8c105f92") version("2.1.3", sha256="2ca0682198c2cdb6beb7866bd2b25071dc8964c6f76d8962477f848f39ff57ea") version("2.1.1", sha256="e1b227fb9c88be4d897be4211198e1e9e8258eb75127848d35b67a0182bf4538") version("2.1.0", sha256="630a1341824fbeef7fdfb82413bfdeb7d3df14e77616ba88159fce1150cf006c") diff --git a/var/spack/repos/builtin/packages/listres/package.py b/var/spack/repos/builtin/packages/listres/package.py index 3b9d14d3c75472..2a82b923c2917e 100644 --- a/var/spack/repos/builtin/packages/listres/package.py +++ b/var/spack/repos/builtin/packages/listres/package.py @@ -19,6 +19,8 @@ class Listres(AutotoolsPackage, XorgPackage): version("1.0.5", sha256="ed068e63dfb6e42cfbcea568d161e53e1d120d99da9aa16c1f822803ebb38504") version("1.0.3", sha256="87d5698b8aa4d841e45e6556932c9914210cbd8b10003d664b31185b087981be") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxt") depends_on("libxmu") diff --git a/var/spack/repos/builtin/packages/lizard/package.py b/var/spack/repos/builtin/packages/lizard/package.py index 60ce4e9cc4d398..9e18d86f923fb7 100644 --- a/var/spack/repos/builtin/packages/lizard/package.py +++ b/var/spack/repos/builtin/packages/lizard/package.py @@ -18,9 +18,12 @@ class Lizard(MakefilePackage): git = "https://github.com/inikep/lizard.git" version("develop", branch="lizard") + version("2.0", sha256="85456b7274c9f0e477ff8e3f06dbc2f8ee8619d737a73c730c8a1adacb45f6da") version("1.0", sha256="6f666ed699fc15dc7fdaabfaa55787b40ac251681b50c0d8df017c671a9457e6") + depends_on("c", type="build") # generated + patch("fix-install-decompress.patch", when="@1.0") def install(self, spec, prefix): - make("PREFIX=%s" % prefix, "install") + make(f"PREFIX={prefix}", "install") diff --git a/var/spack/repos/builtin/packages/lksctp-tools/package.py b/var/spack/repos/builtin/packages/lksctp-tools/package.py index 957e4a1774c86c..1222dddffb42f3 100644 --- a/var/spack/repos/builtin/packages/lksctp-tools/package.py +++ b/var/spack/repos/builtin/packages/lksctp-tools/package.py @@ -16,6 +16,8 @@ class LksctpTools(AutotoolsPackage): version("1.0.18", sha256="3e9ab5b3844a8b65fc8152633aafe85f406e6da463e53921583dfc4a443ff03a") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/llvm-amdgpu/detection_test.yaml b/var/spack/repos/builtin/packages/llvm-amdgpu/detection_test.yaml new file mode 100644 index 00000000000000..5fa0fb526bf834 --- /dev/null +++ b/var/spack/repos/builtin/packages/llvm-amdgpu/detection_test.yaml @@ -0,0 +1,103 @@ +paths: +- layout: + - executables: + - "bin/amdclang" + - "bin/amdclang++" + script: | + echo "AMD clang version 17.0.0 (https://github.com/RadeonOpenCompute/llvm-project roc-5.7.1 23382 f3e174a1d286158c06e4cc8276366b1d4bc0c914)" + echo "Target: x86_64-unknown-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /opt/rocm-5.7.1/llvm/bin" + echo "Configuration file: /opt/rocm-5.7.1/llvm/bin/clang.cfg" + - executables: + - "bin/amdflang" + script: | + echo "AMD flang-classic version 17.0.0 (https://github.com/RadeonOpenCompute/llvm-project roc-5.7.1 23382 f3e174a1d286158c06e4cc8276366b1d4bc0c914)" + echo "Target: x86_64-unknown-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /opt/rocm-5.7.1/llvm/bin" + platforms: [linux] + results: + - spec: llvm-amdgpu@5.7.1 + extra_attributes: + compilers: + c: ".*/bin/amdclang" + cxx: ".*/bin/amdclang[+][+]" + fortran: ".*/bin/amdflang" + +- layout: + - executables: + - "bin/amdclang" + - "bin/amdclang++" + script: | + echo "AMD clang version 17.0.0 (https://github.com/RadeonOpenCompute/llvm-project roc-5.7.1 23382 f3e174a1d286158c06e4cc8276366b1d4bc0c914)" + echo "Target: x86_64-unknown-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /opt/rocm-5.7.1/llvm/bin" + echo "Configuration file: /opt/rocm-5.7.1/llvm/bin/clang.cfg" + platforms: [linux] + results: + - spec: llvm-amdgpu@5.7.1 + extra_attributes: + compilers: + c: ".*/bin/amdclang" + cxx: ".*/bin/amdclang[+][+]" + +- layout: + - executables: + - "bin/amdclang" + - "bin/amdclang++" + script: | + echo "AMD clang version 17.0.0 (https://github.com/RadeonOpenCompute/llvm-project roc-5.7.1 23382 f3e174a1d286158c06e4cc8276366b1d4bc0c914)" + echo "Target: x86_64-unknown-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /opt/rocm-5.7.1/llvm/bin" + echo "Configuration file: /opt/rocm-5.7.1/llvm/bin/clang.cfg" + - executables: + - "bin/amdflang" + script: | + echo "AMD flang-classic version 17.0.0 (https://github.com/RadeonOpenCompute/llvm-project roc-5.7.1 23382 f3e174a1d286158c06e4cc8276366b1d4bc0c914)" + echo "Target: x86_64-unknown-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /opt/rocm-5.7.1/llvm/bin" + - executables: + - "bin/amdclang-6" + - "bin/amdclang++-6" + script: | + echo "AMD clang version 17.0.0 (https://github.com/RadeonOpenCompute/llvm-project roc-6.0.2 24012 af27734ed982b52a9f1be0f035ac91726fc697e4)" + echo "Target: x86_64-unknown-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /opt/rocm-6.0.2/llvm/bin" + echo "Configuration file: /opt/rocm-6.0.2/llvm/bin/clang.cfg" + - executables: + - "bin/amdflang-6" + script: | + echo "AMD flang-classic version 17.0.0 (https://github.com/RadeonOpenCompute/llvm-project roc-6.0.2 24012 af27734ed982b52a9f1be0f035ac91726fc697e4)" + echo "Target: x86_64-unknown-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /opt/rocm-6.0.2/llvm/bin" + platforms: [linux] + results: + - spec: llvm-amdgpu@6.0.2 + extra_attributes: + compilers: + c: ".*/bin/amdclang-6$" + cxx: ".*/bin/amdclang[+][+]-6$" + fortran: ".*/bin/amdflang-6$" + - spec: llvm-amdgpu@5.7.1 + extra_attributes: + compilers: + c: ".*/bin/amdclang" + cxx: ".*/bin/amdclang[+][+]" + fortran: ".*/bin/amdflang" +- layout: # does not detect upstream clang + - executables: + - "bin/clang" + - "bin/clang++" + script: | + echo "clang version 8.0.0 (tags/RELEASE_800/final" + echo "Target: x86_64-unknown-linux-gnu\n" + echo "Thread model: posix\n" + echo "InstalledDir: /usr/bin" + platforms: [linux] + results: [] diff --git a/var/spack/repos/builtin/packages/llvm-amdgpu/package.py b/var/spack/repos/builtin/packages/llvm-amdgpu/package.py index f475dca99900ea..3e4556dd64d305 100644 --- a/var/spack/repos/builtin/packages/llvm-amdgpu/package.py +++ b/var/spack/repos/builtin/packages/llvm-amdgpu/package.py @@ -2,21 +2,18 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) - - import os -import re from spack.package import * -class LlvmAmdgpu(CMakePackage): +class LlvmAmdgpu(CMakePackage, CompilerPackage): """Toolkit for the construction of highly optimized compilers, optimizers, and run-time environments.""" homepage = "https://github.com/ROCm/llvm-project" git = "https://github.com/ROCm/llvm-project.git" - url = "https://github.com/ROCm/llvm-project/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/llvm-project/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] executables = [r"amdclang", r"amdclang\+\+", r"amdflang", r"clang.*", r"flang.*", "llvm-.*"] generator("ninja") @@ -26,6 +23,9 @@ class LlvmAmdgpu(CMakePackage): license("Apache-2.0") version("master", branch="amd-stg-open") + version("6.1.2", sha256="300e9d6a137dcd91b18d5809a316fddb615e0e7f982dc7ef1bb56876dff6e097") + version("6.1.1", sha256="f1a67efb49f76a9b262e9735d3f75ad21e3bd6a05338c9b15c01e6c625c4460d") + version("6.1.0", sha256="6bd9912441de6caf6b26d1323e1c899ecd14ff2431874a2f5883d3bc5212db34") version("6.0.2", sha256="7d35acc84de1adee65406f92a369a30364703f84279241c444cd93a48c7eeb76") version("6.0.0", sha256="c673708d413d60ca8606ee75c77e9871b6953c59029c987b92f2f6e85f683626") version("5.7.1", sha256="6b54c422e45ad19c9bf5ab090ec21753e7f7d854ca78132c30eb146657b168eb") @@ -34,16 +34,15 @@ class LlvmAmdgpu(CMakePackage): version("5.6.0", sha256="e922bd492b54d99e56ed88c81e2009ed6472059a180b10cc56ce1f9bd2d7b6ed") version("5.5.1", sha256="7d7181f20f89cb0715191aa32914186c67a34258c13457055570d47e15296553") version("5.5.0", sha256="5dc6c99f612b69ff73145bee17524e3712990100e16445b71634106acf7927cf") - version("5.4.3", sha256="a844d3cc01613f6284a75d44db67c495ac1e9b600eacbb1eb13d2649f5d5404d") - version("5.4.0", sha256="ff54f45a17723892cd775c1eaff9e5860527fcfd33d98759223c70e3362335bf") - version("5.3.3", sha256="5296d5e474811c7d1e456cb6d5011db248b79b8d0512155e8a6c2aa5b5f12d38") - version("5.3.0", sha256="4e3fcddb5b8ea8dcaa4417e0e31a9c2bbdc9e7d4ac3401635a636df32905c93e") with default_args(deprecated=True): - version("5.2.3", sha256="1b852711aec3137b568fb65f93606d37fdcd62e06f5da3766f2ffcd4e0c646df") - version("5.2.1", sha256="3644e927d943d61e22672422591c47a62ff83e3d87ced68439822156d8f79abf") - version("5.2.0", sha256="0f892174111b78a02d1a00f8f46d9f80b9abb95513a7af38ecf2a5a0882fe87f") - version("5.1.3", sha256="d236a2064363c0278f7ba1bb2ff1545ee4c52278c50640e8bb2b9cfef8a2f128") - version("5.1.0", sha256="db5d45c4a7842a908527c1b7b8d4a40c688225a41d23cfa382eab23edfffdd10") + version("5.4.3", sha256="a844d3cc01613f6284a75d44db67c495ac1e9b600eacbb1eb13d2649f5d5404d") + version("5.4.0", sha256="ff54f45a17723892cd775c1eaff9e5860527fcfd33d98759223c70e3362335bf") + version("5.3.3", sha256="5296d5e474811c7d1e456cb6d5011db248b79b8d0512155e8a6c2aa5b5f12d38") + version("5.3.0", sha256="4e3fcddb5b8ea8dcaa4417e0e31a9c2bbdc9e7d4ac3401635a636df32905c93e") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant( "rocm-device-libs", @@ -65,7 +64,6 @@ class LlvmAmdgpu(CMakePackage): description="Link LLVM tools against the LLVM shared library", ) - provides("libllvm@14", when="@5:5.2") provides("libllvm@15", when="@5.3:5.4") provides("libllvm@16", when="@5.5:5.6") provides("libllvm@17", when="@5.7:") @@ -99,7 +97,7 @@ class LlvmAmdgpu(CMakePackage): patch( "https://github.com/ROCm/llvm-project/commit/444d1d12bbc0269fed5451fb1a9110a049679ca5.patch?full_index=1", sha256="b4774ca19b030890d7b276d12c446400ccf8bc3aa724c7f2e9a73531a7400d69", - when="@6.0", + when="@6.0:", ) conflicts("^cmake@3.19.0") @@ -121,11 +119,6 @@ class LlvmAmdgpu(CMakePackage): ("5.4.0", "d68813ded47179c39914c8d1b76af3dad8c714b10229d1e2246af67609473951"), ("5.3.3", "963c9a0561111788b55a8c3b492e2a5737047914752376226c97a28122a4d768"), ("5.3.0", "f7e1665a1650d3d0481bec68252e8a5e68adc2c867c63c570f6190a1d2fe735c"), - ("5.2.3", "16b7fc7db4759bd6fb54852e9855fa16ead76c97871d7e1e9392e846381d611a"), - ("5.2.1", "e5855387ce73ed483ed0d03dbfef31f297c6ca66cf816f6816fd5ee373fc8225"), - ("5.2.0", "901674bc941115c72f82c5def61d42f2bebee687aefd30a460905996f838e16c"), - ("5.1.3", "c41958560ec29c8bf91332b9f668793463904a2081c330c0d828bf2f91d4f04e"), - ("5.1.0", "47dbcb41fb4739219cadc9f2b5f21358ed2f9895ce786d2f7a1b2c4fd044d30f"), ]: resource( name="rocm-device-libs", @@ -143,6 +136,9 @@ class LlvmAmdgpu(CMakePackage): when="@master +rocm-device-libs", ) for d_version, d_shasum in [ + ("6.1.2", "6eb7a02e5f1e5e3499206b9e74c9ccdd644abaafa2609dea0993124637617866"), + ("6.1.1", "72841f112f953c16619938273370eb8727ddf6c2e00312856c9fca54db583b99"), + ("6.1.0", "50386ebcb7ff24449afa2a10c76a059597464f877225c582ba3e097632a43f9c"), ("6.0.2", "e7ff4d7ac35a2dd8aad1cb40b96511a77a9c23fe4d1607902328e53728e05c28"), ("6.0.0", "99e8fa1af52d0bf382f28468e1a345af1ff3452c35914a6a7b5eeaf69fc568db"), ("5.7.1", "655e9bfef4b0b6ad3f9b89c934dc0a8377273bb0bccbda6c399ac5d5d2c1c04c"), @@ -205,15 +201,17 @@ def cmake_args(self): self.define("LLVM_ENABLE_RTTI", "ON"), self.define("LLVM_TARGETS_TO_BUILD", "AMDGPU;X86"), self.define("LLVM_AMDGPU_ALLOW_NPI_TARGETS", "ON"), - self.define("LLVM_ENABLE_RUNTIMES", llvm_runtimes), - self.define("LLVM_ENABLE_PROJECTS", llvm_projects), self.define("PACKAGE_VENDOR", "AMD"), self.define("CLANG_ENABLE_AMDCLANG", "ON"), ] # Enable rocm-device-libs as a external project if "+rocm-device-libs" in self.spec: - dir = os.path.join(self.stage.source_path, "rocm-device-libs") + if self.spec.satisfies("@:6.0"): + dir = os.path.join(self.stage.source_path, "rocm-device-libs") + elif self.spec.satisfies("@6.1:"): + dir = os.path.join(self.stage.source_path, "amd/device-libs") + args.extend( [ self.define("LLVM_EXTERNAL_PROJECTS", "device-libs"), @@ -236,29 +234,37 @@ def cmake_args(self): if self.spec.satisfies("@5.5.0:"): args.append("-DCLANG_DEFAULT_RTLIB=compiler-rt") args.append("-DCLANG_DEFAULT_UNWINDLIB=libgcc") - if self.spec.satisfies("@5.5.0:"): - args.append("-DCLANG_DEFAULT_RTLIB=compiler-rt") - args.append("-DCLANG_DEFAULT_UNWINDLIB=libgcc") + if self.spec.satisfies("@5.6.0:6.0"): + comgrinc_path = os.path.join(self.stage.source_path, "comgr/lib/comgr/include") + elif self.spec.satisfies("@6.1:"): + comgrinc_path = os.path.join(self.stage.source_path, "amd/comgr/include") if self.spec.satisfies("@5.6.0:"): hsainc_path = os.path.join(self.stage.source_path, "hsa-runtime/src/inc") - comgrinc_path = os.path.join(self.stage.source_path, "comgr/lib/comgr/include") args.append("-DSANITIZER_HSA_INCLUDE_PATH={0}".format(hsainc_path)) args.append("-DSANITIZER_COMGR_INCLUDE_PATH={0}".format(comgrinc_path)) args.append("-DSANITIZER_AMDGPU:Bool=ON") + if self.spec.satisfies("@:6.0"): + args.append(self.define("LLVM_ENABLE_PROJECTS", llvm_projects)) + args.append(self.define("LLVM_ENABLE_RUNTIMES", llvm_runtimes)) + elif self.spec.satisfies("@6.1:"): + llvm_projects.remove("compiler-rt") + llvm_runtimes.extend(["compiler-rt", "libunwind"]) + args.append(self.define("LLVM_ENABLE_PROJECTS", llvm_projects)) + args.append(self.define("LLVM_ENABLE_RUNTIMES", llvm_runtimes)) + args.append(self.define("LLVM_ENABLE_LIBCXX", "OFF")) + args.append(self.define("CLANG_LINK_FLANG_LEGACY", False)) + args.append(self.define("CMAKE_CXX_STANDARD", 17)) + args.append(self.define("FLANG_INCLUDE_DOCS", False)) + args.append(self.define("LLVM_BUILD_DOCS", "ON")) + args.append(self.define("CLANG_DEFAULT_PIE_ON_LINUX", "OFF")) return args - @classmethod - def determine_version(cls, path): - match = re.search(r"amdclang", path) - detected_version = None - if match: - version_query = Executable(path)("--version", output=str) - match = re.search(r"roc-(\d)\.(\d).(\d)", version_query) - if match: - detected_version = "{0}.{1}.{2}".format( - int(match.group(1)), int(match.group(2)), int(match.group(3)) - ) - return detected_version + compiler_languages = ["c", "cxx", "fortran"] + c_names = ["amdclang"] + cxx_names = ["amdclang++"] + fortran_names = ["amdflang"] + compiler_version_argument = "--version" + compiler_version_regex = r"roc-(\d+[._]\d+[._]\d+)" # Make sure that the compiler paths are in the LD_LIBRARY_PATH def setup_run_environment(self, env): diff --git a/var/spack/repos/builtin/packages/llvm-doe/package.py b/var/spack/repos/builtin/packages/llvm-doe/package.py index 8402e0c7434b81..173678cb2d3e6d 100644 --- a/var/spack/repos/builtin/packages/llvm-doe/package.py +++ b/var/spack/repos/builtin/packages/llvm-doe/package.py @@ -28,8 +28,6 @@ class LlvmDoe(CMakePackage, CudaPackage): generator("ninja") - family = "compiler" # Used by lmod - version("doe", branch="doe", preferred=True) version("upstream", branch="llvm.org/main") version("bolt", branch="bolt/main") @@ -38,6 +36,10 @@ class LlvmDoe(CMakePackage, CudaPackage): version("pragma-omp-tile", branch="sollve/pragma-omp-tile") version("13.0.0", branch="llvm.org/llvmorg-13.0.0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # NOTE: The debug version of LLVM is an order of magnitude larger than # the release version, and may take up 20-30 GB of space. If you want # to save space, build with `build_type=Release`. @@ -185,7 +187,6 @@ class LlvmDoe(CMakePackage, CudaPackage): # code signing is only necessary on macOS", conflicts("+code_signing", when="platform=linux") - conflicts("+code_signing", when="platform=cray") conflicts( "+code_signing", @@ -549,7 +550,7 @@ def cmake_args(self): if self.compiler.name == "gcc": cmake_args.append(define("GCC_INSTALL_PREFIX", self.compiler.prefix)) - # if spec.satisfies("platform=cray") or spec.satisfies("platform=linux"): + # if spec.satisfies("platform=linux"): # cmake_args.append("-DCMAKE_BUILD_WITH_INSTALL_RPATH=1") if self.spec.satisfies("~code_signing platform=darwin"): diff --git a/var/spack/repos/builtin/packages/llvm-openmp-ompt/package.py b/var/spack/repos/builtin/packages/llvm-openmp-ompt/package.py index cb35ca36d25981..5a7e206736e352 100644 --- a/var/spack/repos/builtin/packages/llvm-openmp-ompt/package.py +++ b/var/spack/repos/builtin/packages/llvm-openmp-ompt/package.py @@ -24,6 +24,10 @@ class LlvmOpenmpOmpt(CMakePackage): # align-to-tr-rebased branch version("3.9.2b", commit="982a08bcf3df9fb5afc04ac3bada47f19cc4e3d3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # variant for building llvm-openmp-ompt as a stand alone library variant( "standalone", diff --git a/var/spack/repos/builtin/packages/llvm-openmp/package.py b/var/spack/repos/builtin/packages/llvm-openmp/package.py index ec4046a61dd8fa..a1e3f056c980ed 100644 --- a/var/spack/repos/builtin/packages/llvm-openmp/package.py +++ b/var/spack/repos/builtin/packages/llvm-openmp/package.py @@ -43,6 +43,10 @@ class LlvmOpenmp(CMakePackage): version("9.0.0", sha256="9979eb1133066376cc0be29d1682bc0b0e7fb541075b391061679111ae4d3b5b") version("8.0.0", sha256="f7b1705d2f16c4fc23d6531f67d2dd6fb78a077dd346b02fed64f4b8df65c9d5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("multicompat", default=True, description="Support the GNU OpenMP runtime interface.") depends_on("cmake@3.13.4:", when="@12:", type="build") diff --git a/var/spack/repos/builtin/packages/llvm/detection_test.yaml b/var/spack/repos/builtin/packages/llvm/detection_test.yaml index 48e9d6751af20f..c5bf5aff64816f 100644 --- a/var/spack/repos/builtin/packages/llvm/detection_test.yaml +++ b/var/spack/repos/builtin/packages/llvm/detection_test.yaml @@ -1,56 +1,74 @@ paths: - - layout: - - executables: - - "bin/clang-3.9" - script: | - echo "clang version 3.9.1-19ubuntu1 (tags/RELEASE_391/rc2)" - echo "Target: x86_64-pc-linux-gnu" - echo "Thread model: posix" - echo "InstalledDir: /usr/bin" - - executables: - - "bin/clang++-3.9" - script: | - echo "clang version 3.9.1-19ubuntu1 (tags/RELEASE_391/rc2)" - echo "Target: x86_64-pc-linux-gnu" - echo "Thread model: posix" - echo "InstalledDir: /usr/bin" - results: - - spec: 'llvm@3.9.1 +clang~lld~lldb' - # Multiple LLVM packages in the same prefix - - layout: - - executables: - - "bin/clang-8" - - "bin/clang++-8" - script: | - echo "clang version 8.0.0-3~ubuntu18.04.2 (tags/RELEASE_800/final)" - echo "Target: x86_64-pc-linux-gnu" - echo "Thread model: posix" - echo "InstalledDir: /usr/bin" - - executables: - - "bin/ld.lld-8" - script: 'echo "LLD 8.0.0 (compatible with GNU linkers)"' - - executables: - - "bin/lldb" - script: 'echo "lldb version 8.0.0"' - - executables: - - "bin/clang-3.9" - - "bin/clang++-3.9" - script: | - echo "clang version 3.9.1-19ubuntu1 (tags/RELEASE_391/rc2)" - echo "Target: x86_64-pc-linux-gnu" - echo "Thread model: posix" - echo "InstalledDir: /usr/bin" - results: - - spec: 'llvm@8.0.0+clang+lld+lldb' - - spec: 'llvm@3.9.1+clang~lld~lldb' - # Apple Clang should not be detected - - layout: - - executables: - - "bin/clang" - - "bin/clang++" - script: | - echo "Apple clang version 11.0.0 (clang-1100.0.33.8)" - echo "Target: x86_64-apple-darwin19.5.0" - echo "Thread model: posix" - echo "InstalledDir: /Library/Developer/CommandLineTools/usr/bin" - results: [] +- layout: + - executables: + - "bin/clang-3.9" + script: | + echo "clang version 3.9.1-19ubuntu1 (tags/RELEASE_391/rc2)" + echo "Target: x86_64-pc-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /usr/bin" + - executables: + - "bin/clang++-3.9" + script: | + echo "clang version 3.9.1-19ubuntu1 (tags/RELEASE_391/rc2)" + echo "Target: x86_64-pc-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /usr/bin" + platforms: ["darwin", "linux"] + results: + - spec: 'llvm@3.9.1 +clang~lld~lldb' + extra_attributes: + compilers: + c: ".*/bin/clang-3.9$" + cxx: ".*/bin/clang[+][+]-3.9$" + +# Multiple LLVM packages in the same prefix +- layout: + - executables: + - "bin/clang-8" + - "bin/clang++-8" + script: | + echo "clang version 8.0.0-3~ubuntu18.04.2 (tags/RELEASE_800/final)" + echo "Target: x86_64-pc-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /usr/bin" + - executables: + - "bin/ld.lld-8" + script: 'echo "LLD 8.0.0 (compatible with GNU linkers)"' + - executables: + - "bin/lldb" + script: 'echo "lldb version 8.0.0"' + - executables: + - "bin/clang-3.9" + - "bin/clang++-3.9" + script: | + echo "clang version 3.9.1-19ubuntu1 (tags/RELEASE_391/rc2)" + echo "Target: x86_64-pc-linux-gnu" + echo "Thread model: posix" + echo "InstalledDir: /usr/bin" + platforms: ["darwin", "linux"] + results: + - spec: 'llvm@8.0.0+clang+lld+lldb' + extra_attributes: + compilers: + c: ".*/bin/clang-8$" + cxx: ".*/bin/clang[+][+]-8$" + + - spec: 'llvm@3.9.1+clang~lld~lldb' + extra_attributes: + compilers: + c: ".*/bin/clang-3.9$" + cxx: ".*/bin/clang[+][+]-3.9$" + +# Apple Clang should not be detected +- layout: + - executables: + - "bin/clang" + - "bin/clang++" + script: | + echo "Apple clang version 11.0.0 (clang-1100.0.33.8)" + echo "Target: x86_64-apple-darwin19.5.0" + echo "Thread model: posix" + echo "InstalledDir: /Library/Developer/CommandLineTools/usr/bin" + platforms: ["darwin"] + results: [] diff --git a/var/spack/repos/builtin/packages/llvm/llvm17-18-thread.patch b/var/spack/repos/builtin/packages/llvm/llvm17-18-thread.patch new file mode 100644 index 00000000000000..7e337433ff8d64 --- /dev/null +++ b/var/spack/repos/builtin/packages/llvm/llvm17-18-thread.patch @@ -0,0 +1,22 @@ +diff --git a/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake b/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake +index 1f2a50667c4f..d3ff232f6bd3 100644 +--- a/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake ++++ b/openmp/libomptarget/cmake/Modules/LibomptargetGetDependencies.cmake +@@ -280,4 +280,5 @@ if (NOT LIBOMPTARGET_CUDA_TOOLKIT_ROOT_DIR_PRESET AND + endif() + endif() + +-set(OPENMP_PTHREAD_LIB ${LLVM_PTHREAD_LIB}) ++find_package(Threads REQUIRED) ++set(OPENMP_PTHREAD_LIB Threads::Threads) +diff --git a/openmp/libomptarget/src/CMakeLists.txt b/openmp/libomptarget/src/CMakeLists.txt +index 071ec61889a2..b782c3b07e6f 100644 +--- a/openmp/libomptarget/src/CMakeLists.txt.orig 2024-03-26 14:30:52.000000000 +0900 ++++ b/openmp/libomptarget/src/CMakeLists.txt 2024-03-26 14:34:02.000000000 +0900 +@@ -41,5 +41,6 @@ + + if (LIBOMP_HAVE_VERSION_SCRIPT_FLAG) + target_link_libraries(omptarget PRIVATE ++ ${OPENMP_PTHREAD_LIB} + "-Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/exports") + endif() diff --git a/var/spack/repos/builtin/packages/llvm/llvm17-fujitsu.patch b/var/spack/repos/builtin/packages/llvm/llvm17-fujitsu.patch new file mode 100644 index 00000000000000..f960830c13bbc2 --- /dev/null +++ b/var/spack/repos/builtin/packages/llvm/llvm17-fujitsu.patch @@ -0,0 +1,28 @@ +diff --git a/lldb/include/lldb/Utility/LLDBAssert.h_org b/lldb/include/lldb/Utility/LLDBAssert.h +index aeef3e5..2f14ff3 100644 +--- a/lldb/include/lldb/Utility/LLDBAssert.h_org ++++ b/lldb/include/lldb/Utility/LLDBAssert.h +@@ -14,7 +14,7 @@ + #ifndef NDEBUG + #define lldbassert(x) assert(x) + #else +-#if defined(__clang__) ++#if defined(__clang__) && !defined(__CLANG_FUJITSU) + // __FILE_NAME__ is a Clang-specific extension that functions similar to + // __FILE__ but only renders the last path component (the filename) instead of + // an invocation dependent full path to that file. + +diff --git runtimes/CMakeLists.txt_org runtimes/CMakeLists.txt +--- a/runtimes/CMakeLists.txt_org ++++ b/runtimes/CMakeLists.txt +@@ -6,2 +6,2 @@ + include(${LLVM_COMMON_CMAKE_UTILS}/Modules/CMakePolicy.cmake + NO_POLICY_SCOPE) + ++string(REPLACE "-Nclang" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}") ++string(REPLACE "-Nnofjprof" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}") ++string(REPLACE "-Nfjprof" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}") ++ + project(Runtimes C CXX ASM) + + list(INSERT CMAKE_MODULE_PATH 0 diff --git a/var/spack/repos/builtin/packages/llvm/package.py b/var/spack/repos/builtin/packages/llvm/package.py index 33f77e236388d1..8ece089a507402 100644 --- a/var/spack/repos/builtin/packages/llvm/package.py +++ b/var/spack/repos/builtin/packages/llvm/package.py @@ -8,13 +8,14 @@ import sys import llnl.util.tty as tty +from llnl.util.lang import classproperty import spack.build_environment import spack.util.executable from spack.package import * -class Llvm(CMakePackage, CudaPackage): +class Llvm(CMakePackage, CudaPackage, CompilerPackage): """The LLVM Project is a collection of modular and reusable compiler and toolchain technologies. Despite its name, LLVM has little to do with traditional virtual machines, though it does provide helpful @@ -28,15 +29,20 @@ class Llvm(CMakePackage, CudaPackage): git = "https://github.com/llvm/llvm-project" maintainers("trws", "haampie", "skosukhin") - tags = ["e4s"] + tags = ["e4s", "compiler"] generator("ninja") - family = "compiler" # Used by lmod - license("Apache-2.0") version("main", branch="main") + version("18.1.8", sha256="09c08693a9afd6236f27a2ebae62cda656eba19021ef3f94d59e931d662d4856") + version("18.1.7", sha256="b60df7cbe02cef2523f7357120fb0d46cbb443791cde3a5fb36b82c335c0afc9") + version("18.1.6", sha256="01390edfae5b809e982b530ff9088e674c62b13aa92cb9dc1e067fa2cf501083") + version("18.1.5", sha256="d543309f55ae3f9b422108302b45c40f5696c96862f4bda8f5526955daa54284") + version("18.1.4", sha256="deca5a29e8b1d103ecc4badb3c304aca50d5cac6453364d88ee415dc55699dfb") + version("18.1.3", sha256="fc5a2fd176d73ceb17f4e522f8fe96d8dde23300b8c233476d3609f55d995a7a") + version("18.1.2", sha256="8d686d5ece6f12b09985cb382a3a530dc06bb6e7eb907f57c7f8bf2d868ebb0b") version("18.1.1", sha256="62439f733311869dbbaf704ce2e02141d2a07092d952fc87ef52d1d636a9b1e4") version("18.1.0", sha256="eb18f65a68981e94ea1a5aae4f02321b17da9e99f76bfdb983b953f4ba2d3550") version("17.0.6", sha256="81494d32e6f12ea6f73d6d25424dbd2364646011bb8f7e345ca870750aa27de1") @@ -88,6 +94,9 @@ class Llvm(CMakePackage, CudaPackage): version("5.0.1", sha256="84ca454abf262579814a2a2b846569f6e0cb3e16dc33ca3642b4f1dff6fbafd3") version("5.0.0", sha256="1f1843315657a4371d8ca37f01265fa9aae17dbcf46d2d0a95c1fdb3c6a4bab6") + depends_on("c", type="build") + depends_on("cxx", type="build") + variant( "clang", default=True, description="Build the LLVM C/C++/Objective-C compiler frontend" ) @@ -538,6 +547,10 @@ class Llvm(CMakePackage, CudaPackage): # avoid build failed with Fujitsu compiler patch("llvm13-fujitsu.patch", when="@13 %fj") + # avoid build failed with Fujitsu compiler since llvm17 + patch("llvm17-fujitsu.patch", when="@17: %fj") + patch("llvm17-18-thread.patch", when="@17:18 %fj") + # patch for missing hwloc.h include for libompd # see https://reviews.llvm.org/D123888 patch( @@ -590,11 +603,36 @@ def patch(self): string=True, ) - # The functions and attributes below implement external package - # detection for LLVM. See: - # - # https://spack.readthedocs.io/en/latest/packaging_guide.html#making-a-package-discoverable-with-spack-external-find - executables = ["clang", "flang", "ld.lld", "lldb"] + compiler_version_regex = ( + # Normal clang compiler versions are left as-is + r"clang version ([^ )\n]+)-svn[~.\w\d-]*|" + # Don't include hyphenated patch numbers in the version + # (see https://github.com/spack/spack/pull/14365 for details) + r"clang version ([^ )\n]+?)-[~.\w\d-]*|" + r"clang version ([^ )\n]+)|" + # LLDB + r"lldb version ([^ )\n]+)|" + # LLD + r"LLD ([^ )\n]+) \(compatible with GNU linkers\)" + ) + compiler_version_argument = "--version" + compiler_languages = ["c", "cxx", "fortran"] + c_names = ["clang"] + cxx_names = ["clang++"] + fortran_names = ["flang"] + + @property + def supported_languages(self): + languages = [] + if self.spec.satisfies("+clang"): + languages.extend(["c", "cxx"]) + if self.spec.satisfies("+flang"): + languages.append("fortran") + return languages + + @classproperty + def executables(cls): + return super().executables + ["ld.lld", "lldb"] @classmethod def filter_detected_exes(cls, prefix, exes_in_prefix): @@ -611,26 +649,14 @@ def filter_detected_exes(cls, prefix, exes_in_prefix): @classmethod def determine_version(cls, exe): - version_regex = re.compile( - # Normal clang compiler versions are left as-is - r"clang version ([^ )\n]+)-svn[~.\w\d-]*|" - # Don't include hyphenated patch numbers in the version - # (see https://github.com/spack/spack/pull/14365 for details) - r"clang version ([^ )\n]+?)-[~.\w\d-]*|" - r"clang version ([^ )\n]+)|" - # LLDB - r"lldb version ([^ )\n]+)|" - # LLD - r"LLD ([^ )\n]+) \(compatible with GNU linkers\)" - ) try: compiler = Executable(exe) - output = compiler("--version", output=str, error=str) + output = compiler(cls.compiler_version_argument, output=str, error=str) if "Apple" in output: return None if "AMD" in output: return None - match = version_regex.search(output) + match = re.search(cls.compiler_version_regex, output) if match: return match.group(match.lastindex) except spack.util.executable.ProcessError: @@ -642,23 +668,23 @@ def determine_version(cls, exe): @classmethod def determine_variants(cls, exes, version_str): + # Do not need to reuse more general logic from CompilerPackage + # because LLVM has kindly named compilers variants, compilers = ["+clang"], {} lld_found, lldb_found = False, False - for exe in exes: - if "clang++" in exe: - compilers["cxx"] = exe - elif "clang" in exe: - compilers["c"] = exe - elif "flang" in exe: + for exe in sorted(exes, key=len): + name = os.path.basename(exe) + if "clang++" in name: + compilers.setdefault("cxx", exe) + elif "clang" in name: + compilers.setdefault("c", exe) + elif "flang" in name: variants.append("+flang") - compilers["fc"] = exe - compilers["f77"] = exe - elif "ld.lld" in exe: + compilers.setdefault("fortran", exe) + elif "ld.lld" in name: lld_found = True - compilers["ld"] = exe - elif "lldb" in exe: + elif "lldb" in name: lldb_found = True - compilers["lldb"] = exe variants.append("+lld" if lld_found else "~lld") variants.append("+lldb" if lldb_found else "~lldb") @@ -751,10 +777,7 @@ def codesign_check(self): ) def flag_handler(self, name, flags): - if name == "cxxflags": - flags.append(self.compiler.cxx11_flag) - return (None, flags, None) - elif name == "ldflags" and self.spec.satisfies("%intel"): + if name == "ldflags" and self.spec.satisfies("%intel"): flags.append("-shared-intel") return (None, flags, None) return (flags, None, None) @@ -935,7 +958,9 @@ def cmake_args(self): cmake_args.append(from_variant("LIBOMP_TSAN_SUPPORT", "libomp_tsan")) - if self.compiler.name == "gcc": + # From clang 16 onwards we use a more precise --gcc-install-dir flag in post-install + # generated config files. + if self.spec.satisfies("@:15 %gcc"): cmake_args.append(define("GCC_INSTALL_PREFIX", self.compiler.prefix)) if self.spec.satisfies("~code_signing platform=darwin"): @@ -975,12 +1000,24 @@ def cmake_args(self): runtimes_order.index(x) if x in runtimes_order else len(runtimes_order) ) ) + + # CMake args passed just to runtimes + runtime_cmake_args = [define("CMAKE_INSTALL_RPATH_USE_LINK_PATH", True)] + + # When building runtimes, just-built clang has to know where GCC is. + gcc_install_dir_flag = get_gcc_install_dir_flag(spec, self.compiler) + if gcc_install_dir_flag: + runtime_cmake_args.extend( + [ + define("CMAKE_C_FLAGS", gcc_install_dir_flag), + define("CMAKE_CXX_FLAGS", gcc_install_dir_flag), + ] + ) + cmake_args.extend( [ define("LLVM_ENABLE_RUNTIMES", runtimes), - define( - "RUNTIMES_CMAKE_ARGS", [define("CMAKE_INSTALL_RPATH_USE_LINK_PATH", True)] - ), + define("RUNTIMES_CMAKE_ARGS", runtime_cmake_args), ] ) @@ -1030,6 +1067,19 @@ def post_install(self): with working_dir(self.build_directory): install_tree("bin", join_path(self.prefix, "libexec", "llvm")) + cfg_files = [] + if spec.satisfies("+clang"): + cfg_files.extend(("clang.cfg", "clang++.cfg")) + if spec.satisfies("@19: +flang"): + # The config file is `flang.cfg` even though the executable is `flang-new`. + # `--gcc-install-dir` / `--gcc-toolchain` support was only added in LLVM 19. + cfg_files.append("flang.cfg") + gcc_install_dir_flag = get_gcc_install_dir_flag(spec, self.compiler) + if gcc_install_dir_flag: + for cfg in cfg_files: + with open(os.path.join(self.prefix.bin, cfg), "w") as f: + print(gcc_install_dir_flag, file=f) + def llvm_config(self, *args, **kwargs): lc = Executable(self.prefix.bin.join("llvm-config")) if not kwargs.get("output"): @@ -1041,6 +1091,18 @@ def llvm_config(self, *args, **kwargs): return ret +def get_gcc_install_dir_flag(spec: Spec, compiler) -> Optional[str]: + """Get the --gcc-install-dir=... flag, so that clang does not do a system scan for GCC.""" + if not spec.satisfies("@16: %gcc"): + return None + gcc = Executable(compiler.cc) + libgcc_path = gcc("-print-file-name=libgcc.a", output=str, fail_on_error=False).strip() + if not os.path.isabs(libgcc_path): + return None + libgcc_dir = os.path.dirname(libgcc_path) + return f"--gcc-install-dir={libgcc_dir}" if os.path.exists(libgcc_dir) else None + + def get_llvm_targets_to_build(spec): targets = spec.variants["targets"].value diff --git a/var/spack/repos/builtin/packages/lm-sensors/package.py b/var/spack/repos/builtin/packages/lm-sensors/package.py index bdef319cbf7cbd..a9ae344fff44bb 100644 --- a/var/spack/repos/builtin/packages/lm-sensors/package.py +++ b/var/spack/repos/builtin/packages/lm-sensors/package.py @@ -29,6 +29,8 @@ class LmSensors(MakefilePackage): version("3-1-2", sha256="a587f4f37c0f32ac48575338013ee443a0152d87543e8e702db6161ec0ca1161") version("3-1-1", sha256="22b5ab0bab853c34298ff617efb292c5dde7b254596b31ce4c6e90b1d1cf8ad8") + depends_on("c", type="build") # generated + depends_on("bison", type="build") depends_on("flex", type="build") depends_on("perl", type="run") diff --git a/var/spack/repos/builtin/packages/lmbench/package.py b/var/spack/repos/builtin/packages/lmbench/package.py index a94a2793ab0851..742ae247f94641 100644 --- a/var/spack/repos/builtin/packages/lmbench/package.py +++ b/var/spack/repos/builtin/packages/lmbench/package.py @@ -19,6 +19,8 @@ class Lmbench(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("libtirpc") patch( diff --git a/var/spack/repos/builtin/packages/lmdb/package.py b/var/spack/repos/builtin/packages/lmdb/package.py index 6e8c9667a904e9..a74a8d6918dc47 100644 --- a/var/spack/repos/builtin/packages/lmdb/package.py +++ b/var/spack/repos/builtin/packages/lmdb/package.py @@ -24,6 +24,8 @@ class Lmdb(MakefilePackage): version("0.9.21", sha256="1187b635a4cc415bb6972bba346121f81edd996e99b8f0816151d4090f90b559") version("0.9.16", sha256="49d7b40949f2ced9bc8b23ea6a89e75471a1c9126537a8b268c318a00b84322b") + depends_on("c", type="build") # generated + build_directory = "libraries/liblmdb" @property diff --git a/var/spack/repos/builtin/packages/lmod/package.py b/var/spack/repos/builtin/packages/lmod/package.py index b1b0fd4e1579ac..e7e9cf85cb6535 100644 --- a/var/spack/repos/builtin/packages/lmod/package.py +++ b/var/spack/repos/builtin/packages/lmod/package.py @@ -23,6 +23,7 @@ class Lmod(AutotoolsPackage): license("MIT") + version("8.7.37", sha256="171529152fedfbb3c45d27937b0eaa1ee62b5e5cdac3086f44a6d56e5d1d7da4") version("8.7.24", sha256="8451267652059b6507b652e1b563929ecf9b689ffb20830642085eb6a55bd539") version("8.7.20", sha256="c04deff7d2ca354610a362459a7aa9a1c642a095e45a4b0bb2471bb3254e85f4") version("8.7.18", sha256="b9912caca1557dd0c17113bceb1a4952e0ae75331d38df6361601db3f80366af") @@ -54,6 +55,8 @@ class Lmod(AutotoolsPackage): version("6.4.1", sha256="a260b4e42269a80b517c066ba8484658362ea095e80767a2376bbe33d9b070a5") version("6.3.7", sha256="55ddb52cbdc0e2e389b3405229336df9aabfa582c874f5df2559ea264e2ee4ae") + depends_on("c", type="build") # generated + depends_on("lua+shared@5.1:") depends_on("lua-luaposix", type=("build", "run")) depends_on("lua-luafilesystem", type=("build", "run")) @@ -85,14 +88,15 @@ def patch(self): filter_file(r"^#!.*tclsh", "#!@path_to_tclsh@", tclscript) def configure_args(self): + spec = self.spec args = [] - if "+auto_swap" in self.spec: + if spec.satisfies("+auto_swap"): args.append("--with-autoSwap=yes") else: args.append("--with-autoSwap=no") - if "+redirect" in self.spec: + if spec.satisfies("+redirect"): args.append("--with-redirect=yes") else: args.append("--with-redirect=no") diff --git a/var/spack/repos/builtin/packages/lndir/package.py b/var/spack/repos/builtin/packages/lndir/package.py index 3c34408946f129..db18f773dddd50 100644 --- a/var/spack/repos/builtin/packages/lndir/package.py +++ b/var/spack/repos/builtin/packages/lndir/package.py @@ -13,8 +13,11 @@ class Lndir(AutotoolsPackage, XorgPackage): homepage = "https://cgit.freedesktop.org/xorg/util/lndir" xorg_mirror_path = "util/lndir-1.0.3.tar.gz" + version("1.0.5", sha256="2be863f59e6833955b11295c43d79ab32464a8706d29072171cd8da95922a7a2") version("1.0.4", sha256="b448b49a55d0750acfc3fd992c2511b21838ec2cea870d109bb9fdca2ac028da") version("1.0.3", sha256="95b2d26fb3cbe702f828146c7a4c7c48001d2da52b062580227b7b68180be902") + depends_on("c", type="build") # generated + depends_on("xproto@7.0.17:") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/lodepng/package.py b/var/spack/repos/builtin/packages/lodepng/package.py index 0fe2cc6375b1f9..d460f85c24fd40 100644 --- a/var/spack/repos/builtin/packages/lodepng/package.py +++ b/var/spack/repos/builtin/packages/lodepng/package.py @@ -16,6 +16,9 @@ class Lodepng(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("sdl2") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/log4c/package.py b/var/spack/repos/builtin/packages/log4c/package.py index 95fbd8fe3a8ea0..7a27b60ab76766 100644 --- a/var/spack/repos/builtin/packages/log4c/package.py +++ b/var/spack/repos/builtin/packages/log4c/package.py @@ -16,4 +16,7 @@ class Log4c(AutotoolsPackage): version("1.2.4", sha256="5991020192f52cc40fa852fbf6bbf5bd5db5d5d00aa9905c67f6f0eadeed48ea") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("expat@1.95.1:") diff --git a/var/spack/repos/builtin/packages/log4cplus/package.py b/var/spack/repos/builtin/packages/log4cplus/package.py index 6c3e6377817658..ad0b4e872067a9 100644 --- a/var/spack/repos/builtin/packages/log4cplus/package.py +++ b/var/spack/repos/builtin/packages/log4cplus/package.py @@ -19,3 +19,5 @@ class Log4cplus(CMakePackage): version("2.0.7", sha256="8fadbafee2ba4e558a0f78842613c9fb239c775d83f23340d091084c0e1b12ab") version("2.0.1", sha256="43baa7dec3db1ecc97dd9ecf3b50220439d2c7041d15860c36aa1d48dcf480b5") version("1.2.1", sha256="ada80be050033d7636beb894eb54de5575ceca95a5572e9437b0fc4ed7d877c4") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/log4cpp/package.py b/var/spack/repos/builtin/packages/log4cpp/package.py index 165ed73b7fb3b4..7a5303286366f0 100644 --- a/var/spack/repos/builtin/packages/log4cpp/package.py +++ b/var/spack/repos/builtin/packages/log4cpp/package.py @@ -19,3 +19,6 @@ class Log4cpp(AutotoolsPackage): license("LGPL-2.1-or-later") version("1.1.3", sha256="2cbbea55a5d6895c9f0116a9a9ce3afb86df383cd05c9d6c1a4238e5e5c8f51d") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/logrotate/package.py b/var/spack/repos/builtin/packages/logrotate/package.py index 4983a7fb8b56e6..be759478bf51af 100644 --- a/var/spack/repos/builtin/packages/logrotate/package.py +++ b/var/spack/repos/builtin/packages/logrotate/package.py @@ -20,6 +20,8 @@ class Logrotate(AutotoolsPackage): version("3.16.0", sha256="bc6acfd09925045d48b5ff553c24c567cfd5f59d513c4ac34bfb51fa6b79dc8a") version("3.15.1", sha256="a7b20f5184c9598c36546f9200d3bd616d561478a0423ab8074e97a1cd7b1c25") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/logstash/package.py b/var/spack/repos/builtin/packages/logstash/package.py index c7b922b06a1f5f..5f6318faa03bef 100644 --- a/var/spack/repos/builtin/packages/logstash/package.py +++ b/var/spack/repos/builtin/packages/logstash/package.py @@ -19,5 +19,8 @@ class Logstash(Package): version("6.6.0", sha256="5a9a8b9942631e9d4c3dfb8d47075276e8c2cff343841145550cc0c1cfe7bba7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/loki/package.py b/var/spack/repos/builtin/packages/loki/package.py index 46e670640230d5..3be71b8591682f 100644 --- a/var/spack/repos/builtin/packages/loki/package.py +++ b/var/spack/repos/builtin/packages/loki/package.py @@ -18,6 +18,8 @@ class Loki(MakefilePackage): version("0.1.7", sha256="07553754f6be2738559947db69b0718512665bf4a34015fa3a875b6eb1111198") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") def flag_handler(self, name, flags): diff --git a/var/spack/repos/builtin/packages/looptools/package.py b/var/spack/repos/builtin/packages/looptools/package.py index 52d56aca59565a..d84264b7581547 100644 --- a/var/spack/repos/builtin/packages/looptools/package.py +++ b/var/spack/repos/builtin/packages/looptools/package.py @@ -22,6 +22,9 @@ class Looptools(AutotoolsPackage): version("2.15", sha256="a065ffdc4fe6882aa3bb926134ba8ec875d6c0a633c3d4aa5f70db26542713f2") version("2.8", sha256="2395518d0eac9b0883a2c249b9a5ba80df443929c520c45e60f5a4284166eb42") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + patch("conf.patch", when="%fj") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/lordec/package.py b/var/spack/repos/builtin/packages/lordec/package.py index 24e6f2d9a28bfb..7e3d1b32bd7d37 100644 --- a/var/spack/repos/builtin/packages/lordec/package.py +++ b/var/spack/repos/builtin/packages/lordec/package.py @@ -20,6 +20,8 @@ class Lordec(MakefilePackage): version("0.9", sha256="8108b82a8404fbf44c7e300d3abb43358ccc28993f90546168a20ca82536923b") version("0.8", sha256="3894a7c57649a3545b598f92a48d55eda66d729ab51606b00470c50611b12823") + depends_on("cxx", type="build") # generated + def url_for_version(self, version): if version == Version("0.8"): return "https://gite.lirmm.fr/lordec/lordec-releases/uploads/e3116a5f251e46e47f7a3b7ddb2bd7f6/lordec-src_0.8.tar.gz" diff --git a/var/spack/repos/builtin/packages/lp-solve/package.py b/var/spack/repos/builtin/packages/lp-solve/package.py index 4f4b36117dc6a2..252cb25dd69a52 100644 --- a/var/spack/repos/builtin/packages/lp-solve/package.py +++ b/var/spack/repos/builtin/packages/lp-solve/package.py @@ -14,6 +14,8 @@ class LpSolve(Package): version("5.5.2.11", sha256="6d4abff5cc6aaa933ae8e6c17a226df0fc0b671c438f69715d41d09fe81f902f") + depends_on("c", type="build") # generated + def install(self, spec, prefix): with working_dir("lpsolve55"): mkdir(prefix.lib) diff --git a/var/spack/repos/builtin/packages/lrslib/package.py b/var/spack/repos/builtin/packages/lrslib/package.py index b07e73e42449b1..772b942b7aa538 100644 --- a/var/spack/repos/builtin/packages/lrslib/package.py +++ b/var/spack/repos/builtin/packages/lrslib/package.py @@ -23,6 +23,9 @@ class Lrslib(Package): version("5.1", sha256="500893df61631944bac14a76c6e13fc08e6e729727443fa5480b2510de0db635") version("4.3", sha256="04fc1916ea122b3f2446968d2739717aa2c6c94b21fba1f2c627fd17fcf7a963") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Note: lrslib can also be built with Boost, and probably without gmp # depends_on("boost") diff --git a/var/spack/repos/builtin/packages/lrzip/package.py b/var/spack/repos/builtin/packages/lrzip/package.py index 34224cad8b70b4..966b92149d7cee 100644 --- a/var/spack/repos/builtin/packages/lrzip/package.py +++ b/var/spack/repos/builtin/packages/lrzip/package.py @@ -27,6 +27,9 @@ class Lrzip(Package): version("0.616", sha256="6ef50bfec15d7585e5b085067c9fe91a87246ccd14a3165acd08b147bba26a2e") version("0.615", sha256="45bc3e09a9c467c9331499e4e7919ea97d0824d24a1f2c3ec9548bb2b9d14898") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # depends_on('coreutils') depends_on("lzo") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/lshw/package.py b/var/spack/repos/builtin/packages/lshw/package.py index dd6e49a0f49f2a..9afc8b4e9a555f 100644 --- a/var/spack/repos/builtin/packages/lshw/package.py +++ b/var/spack/repos/builtin/packages/lshw/package.py @@ -25,6 +25,9 @@ class Lshw(MakefilePackage): version("02.16", sha256="58a7731d204791dd33db5eb3fde9808d1235283e069e6c33a193637ccec27b3e") version("02.15", sha256="33c51ba0554d4bcd8ff9a67e5971a63b9ddd58213e2901a09000815376bc61b9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): make("install") install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/lsscsi/package.py b/var/spack/repos/builtin/packages/lsscsi/package.py index 2042e3b6b89126..387ee162840c95 100644 --- a/var/spack/repos/builtin/packages/lsscsi/package.py +++ b/var/spack/repos/builtin/packages/lsscsi/package.py @@ -20,3 +20,5 @@ class Lsscsi(AutotoolsPackage): version("0.32", sha256="0a800e9e94dca2ab702d65d72777ae8cae078e3d74d0bcbed64ba0849e8029a1") version("0.31", sha256="12bf1973014803c6fd6d547e7594a4c049f0eef3bf5d22190d4be29d7c09f3ca") version("0.30", sha256="619a2187405f02c5f57682f3478bffc75326803cd08839e39d434250c5518b15") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/ltp/package.py b/var/spack/repos/builtin/packages/ltp/package.py index f2dc4a280cbcb1..02fbb4619b05b7 100644 --- a/var/spack/repos/builtin/packages/ltp/package.py +++ b/var/spack/repos/builtin/packages/ltp/package.py @@ -23,6 +23,8 @@ class Ltp(AutotoolsPackage): version("20190930", sha256="eca11dbe11a61f3035561a2aa272d578ca9380563440f9ba876c0c4755a42533") version("20190517", sha256="538175fff2d6c9d69748b2d4afcf5ac43f7300456f839fa7b5b101c7ad447af7") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/ltrace/package.py b/var/spack/repos/builtin/packages/ltrace/package.py index 3db1d32379e986..596242024710cf 100644 --- a/var/spack/repos/builtin/packages/ltrace/package.py +++ b/var/spack/repos/builtin/packages/ltrace/package.py @@ -18,6 +18,9 @@ class Ltrace(AutotoolsPackage): version("0.7.3", sha256="0e6f8c077471b544c06def7192d983861ad2f8688dd5504beae62f0c5f5b9503") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + conflicts("platform=darwin", msg="ltrace runs only on Linux.") depends_on("elf", type="link") diff --git a/var/spack/repos/builtin/packages/lua-ffi/package.py b/var/spack/repos/builtin/packages/lua-ffi/package.py index d96c73dd4d7b5c..609475446ce876 100644 --- a/var/spack/repos/builtin/packages/lua-ffi/package.py +++ b/var/spack/repos/builtin/packages/lua-ffi/package.py @@ -23,4 +23,6 @@ class LuaFfi(LuaPackage): commit="a1cb731b08c91643b0665935eb5622b3d621211b", ) + depends_on("c", type="build") # generated + depends_on("lua-lang@5.1") diff --git a/var/spack/repos/builtin/packages/lua-lpeg/package.py b/var/spack/repos/builtin/packages/lua-lpeg/package.py index 6983f13b98b934..3bc9d379457d4e 100644 --- a/var/spack/repos/builtin/packages/lua-lpeg/package.py +++ b/var/spack/repos/builtin/packages/lua-lpeg/package.py @@ -15,6 +15,11 @@ class LuaLpeg(LuaPackage): license("MIT") + version( + "1.1.0-1", + sha256="6637fcf4d3ddef7be490a2f0155bd2dcd053272d1bb78c015498709ef9fa75dd", + expand=False, + ) version( "1.0.2-1", sha256="e0d0d687897f06588558168eeb1902ac41a11edd1b58f1aa61b99d0ea0abbfbc", diff --git a/var/spack/repos/builtin/packages/lua-luafilesystem/package.py b/var/spack/repos/builtin/packages/lua-luafilesystem/package.py index 7e072a5f37676e..8eab6e7bee6740 100644 --- a/var/spack/repos/builtin/packages/lua-luafilesystem/package.py +++ b/var/spack/repos/builtin/packages/lua-luafilesystem/package.py @@ -31,6 +31,8 @@ def url_for_version(self, version): version("1.7.0-2", sha256="23b4883aeb4fb90b2d0f338659f33a631f9df7a7e67c54115775a77d4ac3cc59") version("1.6.3", sha256="11c7b1fc2e560c0a521246b84e6257138d97dddde5a19e405714dbabcb9436ca") + depends_on("c", type="build") # generated + depends_on("lua-lang@:5.3", when="@:1.7") diff --git a/var/spack/repos/builtin/packages/lua-luajit-openresty/package.py b/var/spack/repos/builtin/packages/lua-luajit-openresty/package.py index 83849e691936ad..7d39c701578336 100644 --- a/var/spack/repos/builtin/packages/lua-luajit-openresty/package.py +++ b/var/spack/repos/builtin/packages/lua-luajit-openresty/package.py @@ -27,6 +27,9 @@ class LuaLuajitOpenresty(LuaImplPackage): "2.1-20230410", sha256="77bbcbb24c3c78f51560017288f3118d995fe71240aa379f5818ff6b166712ff" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "lualinks", default=True, diff --git a/var/spack/repos/builtin/packages/lua-luajit/package.py b/var/spack/repos/builtin/packages/lua-luajit/package.py index d771de3e9aa921..f46748202dfd91 100644 --- a/var/spack/repos/builtin/packages/lua-luajit/package.py +++ b/var/spack/repos/builtin/packages/lua-luajit/package.py @@ -27,6 +27,9 @@ class LuaLuajit(LuaImplPackage): ) version("2.0.4", sha256="620fa4eb12375021bef6e4f237cbd2dd5d49e56beb414bee052c746beef1807d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + conflicts("@:2.0.5", when="target=aarch64:") variant( diff --git a/var/spack/repos/builtin/packages/lua-luaposix/package.py b/var/spack/repos/builtin/packages/lua-luaposix/package.py index cddba50a2bf3a8..04bc97d6e490b1 100644 --- a/var/spack/repos/builtin/packages/lua-luaposix/package.py +++ b/var/spack/repos/builtin/packages/lua-luaposix/package.py @@ -23,4 +23,6 @@ class LuaLuaposix(LuaPackage): version("33.4.0", sha256="e66262f5b7fe1c32c65f17a5ef5ffb31c4d1877019b4870a5d373e2ab6526a21") version("33.2.1", sha256="4fb34dfea67f4cf3194cdecc6614c9aea67edc3c4093d34137669ea869c358e1") + depends_on("c", type="build") # generated + depends_on("lua-bit32", when="^lua-lang@5.1") diff --git a/var/spack/repos/builtin/packages/lua-mpack/package.py b/var/spack/repos/builtin/packages/lua-mpack/package.py index da4cd89c4de4c4..2ce70fc23d8e62 100644 --- a/var/spack/repos/builtin/packages/lua-mpack/package.py +++ b/var/spack/repos/builtin/packages/lua-mpack/package.py @@ -17,10 +17,13 @@ class LuaMpack(LuaPackage): license("MIT") + version("1.0.12", sha256="06b662b1f14cfaf592ecb3fab425bef20e51439509b7a1736a790ecc929ef8bf") version("1.0.9", sha256="0fd07e709c3f6f201c2ffc9f77cef1b303b02c12413f0c15670a32bf6c959e9e") version("1.0.8", sha256="ed6b1b4bbdb56f26241397c1e168a6b1672f284989303b150f7ea8d39d1bc9e9") version("1.0.7", sha256="68565484a3441d316bd51bed1cacd542b7f84b1ecfd37a8bd18dd0f1a20887e8") version("1.0.6-0", sha256="9068d9d3f407c72a7ea18bc270b0fa90aad60a2f3099fa23d5902dd71ea4cd5f") + depends_on("c", type="build") # generated + def luarocks_args(self): return ["CFLAGS=-fPIC -Wno-error=implicit-function-declaration"] diff --git a/var/spack/repos/builtin/packages/lua-sol2/package.py b/var/spack/repos/builtin/packages/lua-sol2/package.py index 6b07a6b3ede2b2..31d0367ffab513 100644 --- a/var/spack/repos/builtin/packages/lua-sol2/package.py +++ b/var/spack/repos/builtin/packages/lua-sol2/package.py @@ -26,6 +26,8 @@ class LuaSol2(CMakePackage): version("3.0.3", sha256="bf089e50387edfc70063e24fd7fbb693cceba4a50147d864fabedd1b33483582") version("3.0.2", sha256="3f5f369eae6732ae9a315fe4370bbdc9900d2f2f4f291206aeb5b2d5533f0c99") + depends_on("cxx", type="build") # generated + # Lua is not needed when building, since sol2 is headers-only depends_on("lua", type=("link", "run")) diff --git a/var/spack/repos/builtin/packages/lua/package.py b/var/spack/repos/builtin/packages/lua/package.py index 94cb17f409cb0b..042011208c3135 100644 --- a/var/spack/repos/builtin/packages/lua/package.py +++ b/var/spack/repos/builtin/packages/lua/package.py @@ -6,6 +6,8 @@ import glob import os +from llnl.util.symlink import readlink + import spack.build_environment from spack.package import * from spack.util.executable import Executable @@ -79,7 +81,7 @@ def symlink_luajit(self): assert len(luajits) >= 1 luajit = luajits[0] if os.path.islink(luajit): - luajit = os.readlink(luajit) + luajit = readlink(luajit) symlink(luajit, "lua") with working_dir(self.prefix.include): @@ -200,6 +202,7 @@ class Lua(LuaImplPackage): homepage = "https://www.lua.org" url = "https://www.lua.org/ftp/lua-5.3.4.tar.gz" + version("5.4.6", sha256="7d5ea1b9cb6aa0b59ca3dde1c6adcb57ef83a1ba8e5432c0ecd06bf439b3ad88") version("5.4.4", sha256="164c7849653b80ae67bec4b7473b884bf5cc8d2dca05653475ec2ed27b9ebf61") version("5.4.3", sha256="f8612276169e3bfcbcfb8f226195bfc6e466fe13042f1076cbde92b7ec96bbfb") version("5.4.2", sha256="11570d97e9d7303c0a59567ed1ac7c648340cd0db10d5fd594c09223ef2f524f") @@ -220,6 +223,9 @@ class Lua(LuaImplPackage): version("5.1.4", sha256="b038e225eaf2a5b57c9bcc35cd13aa8c6c8288ef493d52970c9545074098af3a") version("5.1.3", sha256="6b5df2edaa5e02bf1a2d85e1442b2e329493b30b0c0780f77199d24f087d296d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("pcfile", default=False, description="Add patch for lua.pc generation") variant("shared", default=True, description="Builds a shared version of the library") diff --git a/var/spack/repos/builtin/packages/lucene/package.py b/var/spack/repos/builtin/packages/lucene/package.py index 04991b6b8f6b55..784084835b3407 100644 --- a/var/spack/repos/builtin/packages/lucene/package.py +++ b/var/spack/repos/builtin/packages/lucene/package.py @@ -19,6 +19,7 @@ class Lucene(Package): license("BSD-2-Clause") + version("9.10.0", sha256="c57b75ee0ea12b54337967b7854ebd12af3d7bad27245c1dc12a167ce2b1f8a7") version("9.5.0", sha256="547277a2b6ce283422eccd14e9ee7ffb28b1af3975936959716c9b4d85843555") version("8.3.1", sha256="acd61ad458d16f3c98b9dd4653c6a34dd666a965842e461f7cdf8947fa041e1a") version("8.3.0", sha256="67c4f8081f24ff9f4eb4f2b999ac19f7a639b416e5b6f1c1c74e0524a481fc7e") diff --git a/var/spack/repos/builtin/packages/luit/package.py b/var/spack/repos/builtin/packages/luit/package.py index 1f9e7ca6424033..9c5596a7150581 100644 --- a/var/spack/repos/builtin/packages/luit/package.py +++ b/var/spack/repos/builtin/packages/luit/package.py @@ -19,6 +19,8 @@ class Luit(AutotoolsPackage, XorgPackage): version("1.1.1", sha256="87b0be0bd01f3b857a53e6625bdd31cef18418c95394b7f4387f8ecef78e45da") + depends_on("c", type="build") # generated + depends_on("libfontenc") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/lulesh/package.py b/var/spack/repos/builtin/packages/lulesh/package.py index d991975c2ee737..bac0bf86aa1868 100644 --- a/var/spack/repos/builtin/packages/lulesh/package.py +++ b/var/spack/repos/builtin/packages/lulesh/package.py @@ -18,6 +18,8 @@ class Lulesh(MakefilePackage): version("2.0.3", tag="2.0.3", commit="46c2a1d6db9171f9637d79f407212e0f176e8194") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Build with MPI support") variant("openmp", default=True, description="Build with OpenMP support") variant("visual", default=False, description="Build with Visualization support (Silo, hdf5)") diff --git a/var/spack/repos/builtin/packages/lumpy-sv/package.py b/var/spack/repos/builtin/packages/lumpy-sv/package.py index 71f316db949860..369072153cfa25 100644 --- a/var/spack/repos/builtin/packages/lumpy-sv/package.py +++ b/var/spack/repos/builtin/packages/lumpy-sv/package.py @@ -16,6 +16,9 @@ class LumpySv(MakefilePackage): version("0.2.13", sha256="3672b86ef0190ebe520648a6140077ee9f15b0549cb233dca18036e63bbf6375") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("htslib") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/lvarray/package.py b/var/spack/repos/builtin/packages/lvarray/package.py index 86c7dd07801570..180458015a3827 100644 --- a/var/spack/repos/builtin/packages/lvarray/package.py +++ b/var/spack/repos/builtin/packages/lvarray/package.py @@ -54,6 +54,9 @@ class Lvarray(CMakePackage, CudaPackage): "0.1.0", tag="v0.1.0", commit="0bf5f7d077de4a08f58db24baed207f9dba95f6e", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build Shared Libs") variant("umpire", default=False, description="Build Umpire support") variant("chai", default=False, description="Build Chai support") diff --git a/var/spack/repos/builtin/packages/lvm2/package.py b/var/spack/repos/builtin/packages/lvm2/package.py index cc005e970a0606..356faa1fc8c115 100644 --- a/var/spack/repos/builtin/packages/lvm2/package.py +++ b/var/spack/repos/builtin/packages/lvm2/package.py @@ -33,6 +33,9 @@ class Lvm2(AutotoolsPackage, SourcewarePackage): version("2.03.01", sha256="424e58b074195ec08e0315fa1aff2550590998c33aea5c43bdceb8c1d135530b") version("2.03.00", sha256="405992bf76960e60c7219d84d5f1e22edc34422a1ea812e21b2ac3c813d0da4e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): url = "https://sourceware.org/pub/lvm2/releases/LVM2.{0}.tgz" return url.format(version) diff --git a/var/spack/repos/builtin/packages/lwgrp/package.py b/var/spack/repos/builtin/packages/lwgrp/package.py index 5449439f02d5ce..79a55066209442 100644 --- a/var/spack/repos/builtin/packages/lwgrp/package.py +++ b/var/spack/repos/builtin/packages/lwgrp/package.py @@ -22,6 +22,8 @@ class Lwgrp(AutotoolsPackage): version("1.0.3", sha256="20b2fc3908bfdf04d1c177f86e227a147214cd155c548b3dd75e54c78e1c1c47") version("1.0.2", sha256="c9d4233946e40f01efd0b4644fd9224becec51b9b5f8cbf45f5bac3129b5b536") + depends_on("c", type="build") # generated + depends_on("mpi") depends_on("autoconf", type="build", when="@main build_system=autotools") diff --git a/var/spack/repos/builtin/packages/lwtnn/package.py b/var/spack/repos/builtin/packages/lwtnn/package.py index a823f7cb9ad855..0087b298d3b459 100644 --- a/var/spack/repos/builtin/packages/lwtnn/package.py +++ b/var/spack/repos/builtin/packages/lwtnn/package.py @@ -20,6 +20,8 @@ class Lwtnn(CMakePackage): version("2.12.1", sha256="b820e698d4ed60737e646ca87a42354e8ac548403348b7f2940e8fda1c0f8203") version("2.10", sha256="bf84b290c44da582226344b0d5febf7fdbd1cbdee94fcc8bcac972c7355564ed") + depends_on("cxx", type="build") # generated + depends_on("boost@1.54:") depends_on("eigen") # https://github.com/lwtnn/lwtnn/issues/161 diff --git a/var/spack/repos/builtin/packages/lxc/package.py b/var/spack/repos/builtin/packages/lxc/package.py index abc2c88f70be4f..30af5b77ca204a 100644 --- a/var/spack/repos/builtin/packages/lxc/package.py +++ b/var/spack/repos/builtin/packages/lxc/package.py @@ -29,6 +29,8 @@ class Lxc(AutotoolsPackage): version("2.0.11", sha256="31334ffe0e2d8e38779d80ce670a523f4f5559c2a02c9e085c2f0cf43995d0b0") version("2.0.10", sha256="b748de0914467aafea18a568602735907fc95f4272609dba7b0f8c91d7dde776") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/lynx/package.py b/var/spack/repos/builtin/packages/lynx/package.py index 7b8fb3673fa9d5..24053d94086b2d 100644 --- a/var/spack/repos/builtin/packages/lynx/package.py +++ b/var/spack/repos/builtin/packages/lynx/package.py @@ -16,6 +16,8 @@ class Lynx(AutotoolsPackage): version("2.8.9.1", sha256="a46e4167b8f02c066d2fe2eafcc5603367be0e3fe2e59e9fc4eb016f306afc8e") + depends_on("c", type="build") # generated + depends_on("ncurses") def url_for_version(self, version): diff --git a/var/spack/repos/builtin/packages/lz4/package.py b/var/spack/repos/builtin/packages/lz4/package.py index a1a59ff1a35efd..d0a4e20dafa1cf 100644 --- a/var/spack/repos/builtin/packages/lz4/package.py +++ b/var/spack/repos/builtin/packages/lz4/package.py @@ -34,6 +34,9 @@ class Lz4(CMakePackage, MakefilePackage): version("1.7.5", sha256="0190cacd63022ccb86f44fa5041dc6c3804407ad61550ca21c382827319e7e7e") version("1.3.1", sha256="9d4d00614d6b9dec3114b33d1224b6262b99ace24434c53487a0c8fd0b18cfed") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("valgrind", type="test") build_system("cmake", "makefile", default="makefile") diff --git a/var/spack/repos/builtin/packages/lzma/package.py b/var/spack/repos/builtin/packages/lzma/package.py index 46749cfcf445f5..1b08713e303b22 100644 --- a/var/spack/repos/builtin/packages/lzma/package.py +++ b/var/spack/repos/builtin/packages/lzma/package.py @@ -22,3 +22,6 @@ class Lzma(AutotoolsPackage): license("LGPL-2.1-or-later") version("4.32.7", sha256="9f337a8c51e5ded198d1032f5087ba3fe438f2a54e9df419e513a151775b032c") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/lzo/package.py b/var/spack/repos/builtin/packages/lzo/package.py index 6bb7f3b449e9aa..e0ff76808b2751 100644 --- a/var/spack/repos/builtin/packages/lzo/package.py +++ b/var/spack/repos/builtin/packages/lzo/package.py @@ -21,6 +21,8 @@ class Lzo(AutotoolsPackage): version("2.06", sha256="ff79e6f836d62d3f86ef6ce893ed65d07e638ef4d3cb952963471b4234d43e73") version("2.05", sha256="449f98186d76ba252cd17ff1241ca2a96b7f62e0d3e4766f88730dab0ea5f333") + depends_on("c", type="build") # generated + variant( "libs", default="shared,static", diff --git a/var/spack/repos/builtin/packages/lzop/package.py b/var/spack/repos/builtin/packages/lzop/package.py index 1d95066711eddb..4fe4f819b79bea 100644 --- a/var/spack/repos/builtin/packages/lzop/package.py +++ b/var/spack/repos/builtin/packages/lzop/package.py @@ -21,5 +21,7 @@ class Lzop(CMakePackage): version("1.03", sha256="c1425b8c77d49f5a679d5a126c90ea6ad99585a55e335a613cae59e909dbb2c9") version("1.01", sha256="28acd94d933befbc3af986abcfe833173fb7563b66533fdb4ac592f38bb944c7") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("lzo") diff --git a/var/spack/repos/builtin/packages/m4/package.py b/var/spack/repos/builtin/packages/m4/package.py index cfe1745549b403..cc4aa1d65d6a8a 100644 --- a/var/spack/repos/builtin/packages/m4/package.py +++ b/var/spack/repos/builtin/packages/m4/package.py @@ -21,6 +21,9 @@ class M4(AutotoolsPackage, GNUMirrorPackage): version("1.4.18", sha256="ab2633921a5cd38e48797bf5521ad259bdc4b979078034a3b790d7fec5493fab") version("1.4.17", sha256="3ce725133ee552b8b4baca7837fb772940b25e81b2a9dc92537aeaf733538c9e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("gnulib-pgi.patch", when="@1.4.18") patch("pgi.patch", when="@1.4.17") # The NVIDIA compilers do not currently support some GNU builtins. diff --git a/var/spack/repos/builtin/packages/macfuse/package.py b/var/spack/repos/builtin/packages/macfuse/package.py index 05de77cd740a59..fe1a2e80efdc3e 100644 --- a/var/spack/repos/builtin/packages/macfuse/package.py +++ b/var/spack/repos/builtin/packages/macfuse/package.py @@ -17,7 +17,6 @@ class Macfuse(Package): provides("fuse") conflicts("platform=linux", msg="macfuse does not support linux, use libfuse instead") - conflicts("platform=cray", msg="macfuse does not support cray, use libfuse instead") def install(self, spec, prefix): msg = """ diff --git a/var/spack/repos/builtin/packages/macsio/package.py b/var/spack/repos/builtin/packages/macsio/package.py index 0e601b32d1ea3e..9f61c5dff2745b 100644 --- a/var/spack/repos/builtin/packages/macsio/package.py +++ b/var/spack/repos/builtin/packages/macsio/package.py @@ -20,6 +20,8 @@ class Macsio(CMakePackage): version("1.1", sha256="a86249b0f10647c0b631773db69568388094605ec1a0af149d9e61e95e6961ec") version("1.0", sha256="1dd0df28f9f31510329d5874c1519c745b5c6bec12e102cea3e9f4b05e5d3072") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Build MPI plugin") variant("silo", default=False, description="Build with SILO plugin") # TODO: multi-level variants for hdf5 diff --git a/var/spack/repos/builtin/packages/mad-numdiff/package.py b/var/spack/repos/builtin/packages/mad-numdiff/package.py index b08a180dad5985..5095cf818b10ac 100644 --- a/var/spack/repos/builtin/packages/mad-numdiff/package.py +++ b/var/spack/repos/builtin/packages/mad-numdiff/package.py @@ -18,3 +18,5 @@ class MadNumdiff(CMakePackage): version("develop", branch="master") version("20150724", sha256="33130b48416f8dcb6402acbcb8906cdec35b7242fe2f3ad49b7d7c063d75377b") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/madis/package.py b/var/spack/repos/builtin/packages/madis/package.py index 7715debddad4d1..0b5033dac8d069 100644 --- a/var/spack/repos/builtin/packages/madis/package.py +++ b/var/spack/repos/builtin/packages/madis/package.py @@ -23,6 +23,8 @@ class Madis(MakefilePackage): version("4.3", sha256="5d1ee9800c84e623dcf4271653aa66d17a744143e58354e70f8a0646cd6b246c") + depends_on("fortran", type="build") # generated + variant("pic", default=True, description="Build with position-independent code (PIC)") variant("pnetcdf", default=False, description="Build with parallel NetCDF") diff --git a/var/spack/repos/builtin/packages/madx/package.py b/var/spack/repos/builtin/packages/madx/package.py index d05ce5197e760e..fd42729b9058b5 100644 --- a/var/spack/repos/builtin/packages/madx/package.py +++ b/var/spack/repos/builtin/packages/madx/package.py @@ -17,11 +17,16 @@ class Madx(CMakePackage): maintainers("wdconinc") # Supported MAD-X versions + version("5.09.03", sha256="cd57f9451e3541a820814ad9ef72b6e01d09c6f3be56802fa2e95b1742db7797") version("5.09.00", sha256="fc2823cdb90a53c1422cca93a48b003c97c1e72641d9e925cd8f59b08f795c7a") version("5.08.01", sha256="89c943fcb474344a4f7d28de98e8eae0aec40f779bf908daff79043bf3520555") version("5.08.00", sha256="0b3fe2aca8899289ef7bfb98d745f13b8c4082e239f54f2662c9cad8d1e63a53") version("5.07.00", sha256="77c0ec591dc3ea76cf57c60a5d7c73b6c0d66cca1fa7c4eb25a9071e8fc67e60") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("x11", default=True, description="Turn on plotting using X11") # patch for gcc-11 to avoid error due to variable shadowing diff --git a/var/spack/repos/builtin/packages/maeparser/package.py b/var/spack/repos/builtin/packages/maeparser/package.py index da0ef74d0f2a6a..fc77b984334a06 100644 --- a/var/spack/repos/builtin/packages/maeparser/package.py +++ b/var/spack/repos/builtin/packages/maeparser/package.py @@ -19,6 +19,8 @@ class Maeparser(CMakePackage): version("1.3.1", sha256="a8d80f67d1b9be6e23b9651cb747f4a3200132e7d878a285119c86bf44568e36") version("1.3.0", sha256="fa8f9336de1e5d1cabec29a6da04547b1fb040bb32ba511ff30b4a14097c751c") + depends_on("cxx", type="build") # generated + variant( "shared", default=True, diff --git a/var/spack/repos/builtin/packages/mafft/package.py b/var/spack/repos/builtin/packages/mafft/package.py index 799dbbc3525ab0..173f51f3008b8c 100644 --- a/var/spack/repos/builtin/packages/mafft/package.py +++ b/var/spack/repos/builtin/packages/mafft/package.py @@ -15,6 +15,7 @@ class Mafft(Package): homepage = "https://mafft.cbrc.jp/alignment/software/index.html" url = "https://mafft.cbrc.jp/alignment/software/mafft-7.221-with-extensions-src.tgz" + version("7.525", sha256="2876f4adc1a2de4ed206bc40896763bf208bf1a02bda52f8bfdd91cf52d73e4a") version("7.505", sha256="f54a78670fcd9960233bcc3b3dd359f395a71c0ced45a7be1cfeae19950ce6ff") version("7.481", sha256="7397f1193048587a3d887e46a353418e67849f71729764e8195b218e3453dfa2") version("7.475", sha256="bb6973ae089ea18cfbd3861a5b9d2c8b7e1543a1fdc78ac2d7cd8dbe3443f319") @@ -22,6 +23,9 @@ class Mafft(Package): version("7.407", sha256="1840b51a0b93f40b4d6076af996ee46396428d8dbaf7ba1d847abff9cb1463e5") version("7.221", sha256="0bc78111966d9b00ddfa14fa217fa5bb0c593a558674a13f02dca7bcd51f7fcf") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): with working_dir("core"): make("PREFIX=%s" % prefix) diff --git a/var/spack/repos/builtin/packages/magic-enum/package.py b/var/spack/repos/builtin/packages/magic-enum/package.py new file mode 100644 index 00000000000000..faa5b67ec2c3f3 --- /dev/null +++ b/var/spack/repos/builtin/packages/magic-enum/package.py @@ -0,0 +1,44 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class MagicEnum(CMakePackage): + """Header-only C++17 library provides static reflection for enums, + work with any enum type without any macro or boilerplate code.""" + + homepage = "https://github.com/Neargye/magic_enum" + url = "https://github.com/Neargye/magic_enum/archive/refs/tags/v0.9.6.tar.gz" + + maintainers("pranav-sivaraman") + + license("MIT", checked_by="pranav-sivaraman") + + version("0.9.6", sha256="814791ff32218dc869845af7eb89f898ebbcfa18e8d81aa4d682d18961e13731") + + variant("examples", default=False, description="Enable examples") + variant("tests", default=True, description="Enable tests") + + # minimum supported versions + conflicts("%clang@:5") + conflicts("%gcc@:9") + conflicts("%msvc@:14.11") + conflicts("%apple-clang@:10") + + depends_on("cxx", type="build") + + depends_on("cmake@3.14:", type="build") + + def cmake_args(self): + from_variant = self.define_from_variant + + args = [ + from_variant("MAGIC_ENUM_OPT_BUILD_EXAMPLES", "examples"), + from_variant("MAGIC_ENUM_OPT_BUILD_TESTS", "tests"), + ] + + return args diff --git a/var/spack/repos/builtin/packages/magics/package.py b/var/spack/repos/builtin/packages/magics/package.py index c635278c348240..e895e44702ebc3 100644 --- a/var/spack/repos/builtin/packages/magics/package.py +++ b/var/spack/repos/builtin/packages/magics/package.py @@ -32,6 +32,10 @@ class Magics(CMakePackage): version("4.2.4", sha256="920c7dbb1aaabe65a31c6c18010829210f8b2f8d614b6c405dc5a4530e346f07") version("4.1.0", sha256="da626c31f53716990754dd72ab7b2f3902a8ad924b23ef3309bd14900d170541") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + conflicts("%gcc@11:", when="@:4.4", msg="missing #include ") variant( diff --git a/var/spack/repos/builtin/packages/magma/package.py b/var/spack/repos/builtin/packages/magma/package.py index ebe204914f45fc..79b1a09d67477f 100644 --- a/var/spack/repos/builtin/packages/magma/package.py +++ b/var/spack/repos/builtin/packages/magma/package.py @@ -13,9 +13,9 @@ class Magma(CMakePackage, CudaPackage, ROCmPackage): current "Multicore+GPU" systems. """ - homepage = "https://icl.cs.utk.edu/magma/" + homepage = "https://icl.utk.edu/magma/" git = "https://bitbucket.org/icl/magma" - url = "https://icl.cs.utk.edu/projectsfiles/magma/downloads/magma-2.2.0.tar.gz" + url = "https://icl.utk.edu/projectsfiles/magma/downloads/magma-2.2.0.tar.gz" maintainers("stomov", "luszczek", "G-Ragghianti") tags = ["e4s"] @@ -23,6 +23,7 @@ class Magma(CMakePackage, CudaPackage, ROCmPackage): test_requires_compiler = True version("master", branch="master") + version("2.8.0", sha256="f4e5e75350743fe57f49b615247da2cc875e5193cc90c11b43554a7c82cc4348") version("2.7.2", sha256="729bc1a70e518a7422fe7a3a54537a4741035a77be3349f66eac5c362576d560") version("2.7.1", sha256="d9c8711c047a38cae16efde74bee2eb3333217fd2711e1e9b8606cbbb4ae1a50") version("2.7.0", sha256="fda1cbc4607e77cacd8feb1c0f633c5826ba200a018f647f1c5436975b39fd18") @@ -38,6 +39,10 @@ class Magma(CMakePackage, CudaPackage, ROCmPackage): version("2.3.0", sha256="010a4a057d7aa1e57b9426bffc0958f3d06913c9151463737e289e67dd9ea608") version("2.2.0", sha256="df5d4ace417e5bf52694eae0d91490c6bde4cde1b0da98e8d400c5c3a70d83a2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=True, description="Enable Fortran bindings support") variant("shared", default=True, description="Enable shared library") variant("cuda", default=True, description="Build with CUDA") @@ -47,6 +52,22 @@ class Magma(CMakePackage, CudaPackage, ROCmPackage): depends_on("cuda@8:", when="@2.5.1: +cuda") # See PR #14471 depends_on("hipblas", when="+rocm") depends_on("hipsparse", when="+rocm") + # This ensures that rocm-core matches the hip package version in the case that + # hip is an external package. + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: + depends_on(f"rocm-core@{ver}", when=f"@2.8.0: +rocm ^hip@{ver}") depends_on("python", when="@master", type="build") conflicts("~cuda", when="~rocm", msg="magma: Either CUDA or HIP support must be enabled") @@ -150,6 +171,8 @@ def cmake_args(self): # See https://github.com/ROCm/rocFFT/issues/322 if spec.satisfies("^cmake@3.21.0:3.21.2"): options.append(define("__skip_rocmclang", True)) + if spec.satisfies("@2.8.0:"): + options.append(define("ROCM_CORE", spec["rocm-core"].prefix)) else: options.append(define("MAGMA_ENABLE_CUDA", True)) diff --git a/var/spack/repos/builtin/packages/makedepend/package.py b/var/spack/repos/builtin/packages/makedepend/package.py index ec6fc74c2aedd8..0c4d7c4c58ed13 100644 --- a/var/spack/repos/builtin/packages/makedepend/package.py +++ b/var/spack/repos/builtin/packages/makedepend/package.py @@ -14,8 +14,12 @@ class Makedepend(AutotoolsPackage, XorgPackage): license("MIT-open-group") + version("1.0.9", sha256="bc94ffda6cd4671603a69c39dbe8f96b317707b9185b2aaa3b54b5d134b41884") version("1.0.8", sha256="275f0d2b196bfdc740aab9f02bb48cb7a97e4dfea011a7b468ed5648d0019e54") version("1.0.5", sha256="503903d41fb5badb73cb70d7b3740c8b30fe1cc68c504d3b6a85e6644c4e5004") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("xproto@7.0.17:") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/mallocmc/package.py b/var/spack/repos/builtin/packages/mallocmc/package.py index a9b0fbb2a86368..7666b55e8a3c52 100644 --- a/var/spack/repos/builtin/packages/mallocmc/package.py +++ b/var/spack/repos/builtin/packages/mallocmc/package.py @@ -35,6 +35,8 @@ class Mallocmc(CMakePackage): version("2.0.0crp", sha256="1a6b5b4f9a890d4389703cb853868cc31a97457bfea3b62d6b3ae31e56d7bbd9") version("1.0.2crp", sha256="696c5bb7e90a75937a2479c40e7cfddcc876f8fc634dca04b61d132ab1243f12") + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.12.2:", type="build") depends_on("boost@1.48.0:", type="link") diff --git a/var/spack/repos/builtin/packages/maloc/package.py b/var/spack/repos/builtin/packages/maloc/package.py index 19e94e98fa6a3b..f7149aa434dc3d 100644 --- a/var/spack/repos/builtin/packages/maloc/package.py +++ b/var/spack/repos/builtin/packages/maloc/package.py @@ -23,6 +23,9 @@ class Maloc(AutotoolsPackage): version("1.1", sha256="b5dd7923e84f13e7ed43304ed1062de24171c5a7a042a12b0d1e501d6eaedf58") version("1.0", sha256="23f3ea3215067fd8f1ba4c407375f387b5f1d11258f29508295e651828d32cb7") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("doc", default=False, description="Build documentation.") depends_on("graphviz", type="build", when="+doc") diff --git a/var/spack/repos/builtin/packages/malt/package.py b/var/spack/repos/builtin/packages/malt/package.py index b2d1ba4c959f88..f5a4bfe01bd547 100644 --- a/var/spack/repos/builtin/packages/malt/package.py +++ b/var/spack/repos/builtin/packages/malt/package.py @@ -24,6 +24,9 @@ class Malt(CMakePackage): version("1.2.2", sha256="e19f49ad97bf2deedf0557eb00267f4dcf1c932c494dd07ada07fcdf5421935f") version("1.2.1", sha256="0e4c0743561f9fcc04dc83457386167a9851fc9289765f8b4f9390384ae3618a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Variants variant( "nodejs", diff --git a/var/spack/repos/builtin/packages/man-db/package.py b/var/spack/repos/builtin/packages/man-db/package.py index 836c0c2a27d79e..1139f5182297ae 100644 --- a/var/spack/repos/builtin/packages/man-db/package.py +++ b/var/spack/repos/builtin/packages/man-db/package.py @@ -18,11 +18,15 @@ class ManDb(AutotoolsPackage): license("GPL-2.0-or-later") + version("2.12.1", sha256="ddee249daeb78cf92bab794ccd069cc8b575992265ea20e239e887156e880265") + version("2.12.0", sha256="415a6284a22764ad22ff0f66710d853be7790dd451cd71436e3d25c74d996a95") version("2.11.2", sha256="cffa1ee4e974be78646c46508e6dd2f37e7c589aaab2938cc1064f058fef9f8d") version("2.10.2", sha256="ee97954d492a13731903c9d0727b9b01e5089edbd695f0cdb58d405a5af5514d") version("2.10.1", sha256="2ffd8f2e80122fe72e60c740c851e6a3e15c9a7921185eb4752c1c672824bed6") version("2.7.6.1", sha256="08edbc52f24aca3eebac429b5444efd48b9b90b9b84ca0ed5507e5c13ed10f3f") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("gettext") depends_on("libpipeline@1.5.0:", when="@2.8.0:") diff --git a/var/spack/repos/builtin/packages/mapl/package.py b/var/spack/repos/builtin/packages/mapl/package.py index 8317c0aa98ec6e..2f9c2be678e991 100644 --- a/var/spack/repos/builtin/packages/mapl/package.py +++ b/var/spack/repos/builtin/packages/mapl/package.py @@ -38,6 +38,18 @@ class Mapl(CMakePackage): version("develop", branch="develop") version("main", branch="main") + version("2.47.1", sha256="ca3e94c0caa78a91591fe63603d1836196f5294d4baad7cf1d83b229b3a85916") + version("2.47.0", sha256="66c862d2ab8bcd6969e9728091dbca54f1f420e97e41424c4ba93ef606088459") + version("2.46.2", sha256="6d397ad73042355967de8ef5b521d6135c004f96e93ae7b215f9ee325e75c6f0") + version("2.46.1", sha256="f3090281de6293b484259d58f852c45b98759de8291d36a4950e6d348ece6573") + version("2.46.0", sha256="726d9588b724bd43e5085d1a2f8d806d548f185ed6b22a1b13c0ed06212d7be2") + # NOTE: Due to issues with CMake and ESMF, versions 2.44 and 2.45 of MAPL were not + # correctly installable with spack. The versions are still available in the + # repository, but we are skipping them in spack. There are references to these + # versions below in case a 2.44 or 2.45 spack-compatible version is needed + # and changes backported. + version("2.43.2", sha256="966130931153a9a3974ad6ae011d1df194e057cb82301c8703ef69669b9f27ba") + version("2.43.1", sha256="62b7a8c438c960e47b83d9835cb37c7ce25f617d648f2affe9961b4a6e638abc") version("2.43.0", sha256="1be99d64ca46001ac94f7db3607c345e144976dc34fe184e734e212bf3955d01") version("2.42.4", sha256="f6b643cc45f2dc55df96a316c84d84ace341bb6e06f81f83b5de258d9978b3d4") version("2.42.3", sha256="4ccac684dcbbca36cd7b30cb1515b52f05d7c06ca93399e60ccf42726d147018") @@ -47,6 +59,7 @@ class Mapl(CMakePackage): version("2.41.2", sha256="73e1f0961f1b70e8159c0a2ce3499eb5158f3ca6d081f4c7826af7854ebfb44d") version("2.41.1", sha256="2b384bd4fbaac1bff4ef009922c436c4ab54832172a5cd4d312ea44e32c1ae7c") version("2.41.0", sha256="1142f9395e161174e3ec1654fba8bda1d0bd93edc7438b1927d8f5d7b42a0a86") + version("2.40.5", sha256="85b4a4ac0d843398452808b88d7a5c29435aa37b69b91a1f4bee664e9f367b7d") version("2.40.4", sha256="fb843b118d6e56cd4fc4b114c4d6f91956d5c8b3d9389ada56da1dfdbc58904f") version("2.40.3", sha256="4b82a314c88a035fc2b91395750aa7950d6bee838786178ed16a3f39a1e45519") version("2.40.2", sha256="7327f6f5bce6e09e7f7b930013fba86ee7cbfe8ed4c7c087fc9ab5acbf6640fd") @@ -126,19 +139,40 @@ class Mapl(CMakePackage): deprecated=True, ) + depends_on("c", type="build") + depends_on("fortran", type="build") + # Versions later than 3.14 remove FindESMF.cmake # from ESMA_CMake. + resource( + name="esma_cmake", + git="https://github.com/GEOS-ESM/ESMA_cmake.git", + tag="v3.46.0", + when="@2.47:", + ) + resource( + name="esma_cmake", + git="https://github.com/GEOS-ESM/ESMA_cmake.git", + tag="v3.45.2", + when="@2.45:2.46", + ) + resource( + name="esma_cmake", + git="https://github.com/GEOS-ESM/ESMA_cmake.git", + tag="v3.40.0", + when="@2.44", + ) resource( name="esma_cmake", git="https://github.com/GEOS-ESM/ESMA_cmake.git", tag="v3.36.0", - when="@2.42.0:", + when="@2.42.0:2.43", ) resource( name="esma_cmake", git="https://github.com/GEOS-ESM/ESMA_cmake.git", tag="v3.31.0", - when="@2.40.0:", + when="@2.40.0:2.41", ) resource( name="esma_cmake", @@ -183,6 +217,10 @@ class Mapl(CMakePackage): conflicts("mpich@:3") conflicts("mpich@4", when="@:2.41") + # MAPL only supports gcc 13 from MAPL 2.45 onwards, so we only allow + # builds with gcc 13 from that version onwards + conflicts("%gcc@13:", when="@:2.44") + variant("flap", default=False, description="Build with FLAP support", when="@:2.39") variant("pflogger", default=True, description="Build with pFlogger support") variant("fargparse", default=True, description="Build with fArgParse support") @@ -199,24 +237,34 @@ class Mapl(CMakePackage): values=("Debug", "Release", "Aggressive"), ) + # https://github.com/JCSDA/spack-stack/issues/769 + conflicts("+pflogger", when="@:2.40.3 %intel@2021.7:") + conflicts("+extdata2g", when="@:2.40.3 %intel@2021.7:") + depends_on("cmake@3.17:", type="build") depends_on("mpi") depends_on("hdf5") depends_on("netcdf-c") depends_on("netcdf-fortran") - depends_on("esmf@8.5:", when="@2.40:") + depends_on("esmf@8.6.1:", when="@2.45:") + depends_on("esmf@8.6.0", when="@2.44") + depends_on("esmf@8.5:", when="@2.40:2.43") depends_on("esmf@8.4", when="@2.34:2.39") depends_on("esmf@8.3", when="@2.22:2.33") depends_on("esmf", when="@:2.12.99") depends_on("esmf~debug", when="~debug") depends_on("esmf+debug", when="+debug") - depends_on("gftl@1.10.0:", when="@2.40:") + depends_on("gftl@1.13.0:", when="@2.45:") + depends_on("gftl@1.11.0:", when="@2.44") + depends_on("gftl@1.10.0:", when="@2.40:2.43") depends_on("gftl@1.5.5:1.9", when="@:2.39") # There was an interface change in gftl-shared, so we need to control versions # MAPL 2.39 and older can use up to 1.6.0 but MAPL 2.40+ needs 1.6.1 or higher - depends_on("gftl-shared@1.6.1:", when="@2.40:") + depends_on("gftl-shared@1.8.0:", when="@2.45:") + depends_on("gftl-shared@1.7.0:", when="@2.44") + depends_on("gftl-shared@1.6.1:", when="@2.40:2.43") depends_on("gftl-shared@1.3.1:1.6.0", when="@:2.39") # There was an interface change in yaFyaml, so we need to control versions @@ -230,14 +278,23 @@ class Mapl(CMakePackage): # yaFyaml so we need to use old pFlogger, but MAPL 2.23+ uses new yaFyaml depends_on("pflogger@:1.6 +mpi", when="@:2.22+pflogger") depends_on("pflogger@1.9.1: +mpi", when="@2.23:2.39+pflogger") - depends_on("pflogger@1.9.5: +mpi", when="@2.40:+pflogger") + depends_on("pflogger@1.9.5: +mpi", when="@2.40:2.43+pflogger") + depends_on("pflogger@1.11.0: +mpi", when="@2.44+pflogger") + depends_on("pflogger@1.14.0: +mpi", when="@2.45:+pflogger") # fArgParse v1.4.1 is the first usable version with MAPL # we now require 1.5.0 with MAPL 2.40+ - depends_on("fargparse@1.5.0:", when="@2.40:+fargparse") + depends_on("fargparse@1.7.0:", when="@2.45:+fargparse") + depends_on("fargparse@1.6.0:", when="@2.44+fargparse") + depends_on("fargparse@1.5.0:", when="@2.40:43+fargparse") depends_on("fargparse@1.4.1:1.4", when="@:2.39+fargparse") - depends_on("pfunit@4.2: +mpi +fhamcrest", when="+pfunit") + depends_on("pfunit@4.9: +mpi +fhamcrest", when="@2.45:+pfunit") + depends_on("pfunit@4.8: +mpi +fhamcrest", when="@2.44+pfunit") + depends_on("pfunit@4.7.3: +mpi +fhamcrest", when="@2.40:+pfunit") + depends_on("pfunit@4.6.1: +mpi +fhamcrest", when="@2.32:+pfunit") + depends_on("pfunit@4.4.1: +mpi +fhamcrest", when="@2.26:+pfunit") + depends_on("pfunit@4.2: +mpi +fhamcrest", when="@:2.25+pfunit") depends_on("flap", when="+flap") depends_on("ecbuild", type="build") @@ -246,19 +303,23 @@ class Mapl(CMakePackage): depends_on("py-numpy", when="+f2py") depends_on("perl") + # when using apple-clang version 15.x or newer, need to use the llvm-openmp library + depends_on("llvm-openmp", when="%apple-clang@15:", type=("build", "run")) + def cmake_args(self): args = [ - self.define_from_variant("BUILD_WITH_FLAP", "flap"), self.define_from_variant("BUILD_WITH_PFLOGGER", "pflogger"), self.define_from_variant("BUILD_WITH_FARGPARSE", "fargparse"), self.define_from_variant("BUILD_SHARED_MAPL", "shared"), self.define_from_variant("USE_EXTDATA2G", "extdata2g"), self.define_from_variant("USE_F2PY", "f2py"), - "-DCMAKE_C_COMPILER=%s" % self.spec["mpi"].mpicc, - "-DCMAKE_CXX_COMPILER=%s" % self.spec["mpi"].mpicxx, - "-DCMAKE_Fortran_COMPILER=%s" % self.spec["mpi"].mpifc, ] + # We only want to add BUILD_WITH_FLAP if we are @:2.39 otherwise + # there is a weird empty string that gets added to the CMake command + if self.spec.satisfies("@:2.39"): + args.append(self.define("BUILD_WITH_FLAP", self.spec.satisfies("+flap"))) + if self.spec.satisfies("@2.22.0:"): args.append(self.define("CMAKE_MODULE_PATH", self.spec["esmf"].prefix.cmake)) @@ -277,6 +338,36 @@ def cmake_args(self): if fflags: args.append(self.define("CMAKE_Fortran_FLAGS", " ".join(fflags))) + # Scripts often need to know the MPI stack used to setup the environment. + # Normally, we can autodetect this, but building with Spack does not + # seem to work. We need to pass in the MPI stack used to CMake + # via -DMPI_STACK on the CMake command line. We use the following + # names for the MPI stacks: + # + # - MPICH --> mpich + # - Open MPI --> openmpi + # - Intel MPI --> intelmpi + # - MVAPICH --> mvapich + # - HPE MPT --> mpt + # - Cray MPICH --> mpich + + if self.spec.satisfies("^mpich"): + args.append(self.define("MPI_STACK", "mpich")) + elif self.spec.satisfies("^mvapich2"): + args.append(self.define("MPI_STACK", "mvapich")) + elif self.spec.satisfies("^openmpi"): + args.append(self.define("MPI_STACK", "openmpi")) + elif self.spec.satisfies("^intel-oneapi-mpi"): + args.append(self.define("MPI_STACK", "intelmpi")) + elif self.spec.satisfies("^mvapich"): + args.append(self.define("MPI_STACK", "mvapich")) + elif self.spec.satisfies("^mpt"): + args.append(self.define("MPI_STACK", "mpt")) + elif self.spec.satisfies("^cray-mpich"): + args.append(self.define("MPI_STACK", "mpich")) + else: + raise InstallError("Unsupported MPI stack") + return args def patch(self): diff --git a/var/spack/repos/builtin/packages/mapnik/package.py b/var/spack/repos/builtin/packages/mapnik/package.py index ba8622595c768d..a5d35ecb6f50be 100644 --- a/var/spack/repos/builtin/packages/mapnik/package.py +++ b/var/spack/repos/builtin/packages/mapnik/package.py @@ -19,6 +19,8 @@ class Mapnik(AutotoolsPackage): version("3.0.23", sha256="4b1352e01f7ce25ab099e586d7ae98e0b74145a3bf94dd365cb0a2bdab3b9dc2") version("3.0.22", sha256="930612ad9e604b6a29b9cea1bc1de85cf7cf2b2b8211f57ec8b6b94463128ab9") + depends_on("cxx", type="build") # generated + depends_on("python", type=("build", "run")) depends_on( "boost@:1.72.0 +regex+filesystem+system+icu+program_options cxxstd=11", when="@3.0.23" diff --git a/var/spack/repos/builtin/packages/mapserver/package.py b/var/spack/repos/builtin/packages/mapserver/package.py index e26951531e1175..66830e8a26e05a 100644 --- a/var/spack/repos/builtin/packages/mapserver/package.py +++ b/var/spack/repos/builtin/packages/mapserver/package.py @@ -3,8 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import os - from spack.package import * @@ -22,6 +20,9 @@ class Mapserver(CMakePackage): version("8.0.1", sha256="79d23595ef95d61d3d728ae5e60850a3dbfbf58a46953b4fdc8e6e0ffe5748ba") version("7.2.1", sha256="9459a7057d5a85be66a41096a5d804f74665381186c37077c94b56e784db6102") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("python", default=False, description="Enable Python mapscript support") variant( "curl", @@ -60,9 +61,7 @@ def patch(self): # prefix. This hack patches the CMakeLists.txt for the Python # bindings and hard-wires in the right destination. A bit ugly, # sorry, but I don't speak cmake. - pyversiondir = "python{0}".format(self.spec["python"].version.up_to(2)) - sitepackages = os.path.join(self.spec.prefix.lib, pyversiondir, "site-packages") - filter_file(r"\${PYTHON_SITE_PACKAGES}", sitepackages, "mapscript/python/CMakeLists.txt") + filter_file(r"\${PYTHON_SITE_PACKAGES}", python_platlib, "mapscript/python/CMakeLists.txt") def cmake_args(self): args = [] diff --git a/var/spack/repos/builtin/packages/maq/package.py b/var/spack/repos/builtin/packages/maq/package.py index 3c6dee69c3afda..5b3ec7a02eaecb 100644 --- a/var/spack/repos/builtin/packages/maq/package.py +++ b/var/spack/repos/builtin/packages/maq/package.py @@ -20,6 +20,9 @@ class Maq(AutotoolsPackage): version("0.7.1", sha256="e1671e0408b0895f5ab943839ee8f28747cf5f55dc64032c7469b133202b6de2") version("0.5.0", sha256="c292c19baf291b2415b460d687d43a71ece00a7d178cc5984bc8fc30cfce2dfb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl", type="run") def patch(self): diff --git a/var/spack/repos/builtin/packages/margo/package.py b/var/spack/repos/builtin/packages/margo/package.py index 2412849e50ba98..399b38d63af4c8 100644 --- a/var/spack/repos/builtin/packages/margo/package.py +++ b/var/spack/repos/builtin/packages/margo/package.py @@ -114,6 +114,8 @@ class Margo(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("json-c", when="@0.9:") depends_on("autoconf@2.65:", type=("build")) depends_on("m4", type=("build")) diff --git a/var/spack/repos/builtin/packages/mariadb-c-client/package.py b/var/spack/repos/builtin/packages/mariadb-c-client/package.py index 30dccf8db49db3..15ca777da0f9ad 100644 --- a/var/spack/repos/builtin/packages/mariadb-c-client/package.py +++ b/var/spack/repos/builtin/packages/mariadb-c-client/package.py @@ -60,6 +60,9 @@ class MariadbCClient(CMakePackage): version("2.2.0", sha256="3825b068d38bc19d6ad1eaecdd74bcd49d6ddd9d00559fb150e4e851a55bbbd4") version("2.1.0", sha256="568050b89463af7610d458669fd9eee06dcc9405689aca8a526ac8c013b59167") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + provides("mariadb-client") provides("mysql-client") diff --git a/var/spack/repos/builtin/packages/mariadb/package.py b/var/spack/repos/builtin/packages/mariadb/package.py index d1392fe893fb1b..5585600b9d798d 100644 --- a/var/spack/repos/builtin/packages/mariadb/package.py +++ b/var/spack/repos/builtin/packages/mariadb/package.py @@ -23,6 +23,9 @@ class Mariadb(CMakePackage): license("GPL-2.0-or-later") + version("11.3.2", sha256="5570778f0a2c27af726c751cda1a943f3f8de96d11d107791be5b44a0ce3fb5c") + version("10.9.6", sha256="fe6f5287fccc6a65b8bbccae09e841e05dc076fcc13017078854ca387eab8ae9") + version("10.8.8", sha256="8de1a151842976a492d6331b543d0ed87259febbbc03b9ebce07c80d754d6361") version("10.8.2", sha256="14e0f7f8817a41bbcb5ebdd2345a9bd44035fde7db45c028b6d4c35887ae956c") version("10.4.12", sha256="fef1e1d38aa253dd8a51006bd15aad184912fce31c446bb69434fcde735aa208") version("10.4.8", sha256="10cc2c3bdb76733c9c6fd1e3c6c860d8b4282c85926da7d472d2a0e00fffca9b") @@ -33,6 +36,9 @@ class Mariadb(CMakePackage): version("10.1.14", sha256="18e71974a059a268a3f28281599607344d548714ade823d575576121f76ada13") version("5.5.49", sha256="2c82f2af71b88a7940d5ff647498ed78922c92e88004942caa213131e20f4706") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "nonblocking", default=True, @@ -65,6 +71,7 @@ class Mariadb(CMakePackage): depends_on("krb5") conflicts("%gcc@9.1.0:", when="@:5.5") + conflicts("%gcc@13:", when="@:10.8.7") # https://github.com/spack/spack/issues/41377 # patch needed for cmake-3.20 patch( diff --git a/var/spack/repos/builtin/packages/masa/package.py b/var/spack/repos/builtin/packages/masa/package.py index b14b700bc9ab10..3145f4d4f2e6f1 100644 --- a/var/spack/repos/builtin/packages/masa/package.py +++ b/var/spack/repos/builtin/packages/masa/package.py @@ -20,6 +20,10 @@ class Masa(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=True, description="Compile with Fortran interfaces") variant("python", default=True, description="Compile with Python interfaces") diff --git a/var/spack/repos/builtin/packages/mash/package.py b/var/spack/repos/builtin/packages/mash/package.py index 8a33d72816e214..bcf554bbc13050 100644 --- a/var/spack/repos/builtin/packages/mash/package.py +++ b/var/spack/repos/builtin/packages/mash/package.py @@ -18,6 +18,9 @@ class Mash(AutotoolsPackage): version("2.3", sha256="f96cf7305e010012c3debed966ac83ceecac0351dbbfeaa6cd7ad7f068d87fe1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("gcc-11.patch", when="%gcc@11:") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/masurca/package.py b/var/spack/repos/builtin/packages/masurca/package.py index a81f957b5364e1..28bd9b2304937c 100644 --- a/var/spack/repos/builtin/packages/masurca/package.py +++ b/var/spack/repos/builtin/packages/masurca/package.py @@ -17,6 +17,7 @@ class Masurca(Package): license("GPL-3.0-only") + version("4.1.1", sha256="8758f6196bf7f57e24e08bda84abddfff08feb4cea204c0eb5e1cb9fe8198573") version("4.1.0", sha256="15078e24c79fe5aabe42748d64f95d15f3fbd7708e84d88fc07c4b7f2e4b0902") version("4.0.9", sha256="a31c2f786452f207c0b0b20e646b6c85b7357dcfd522b697c1009d902d3ed4cf") version("4.0.5", sha256="db525c26f2b09d6b359a2830fcbd4a3fdc65068e9a116c91076240fd1f5924ed") @@ -24,6 +25,9 @@ class Masurca(Package): version("3.3.1", sha256="587d0ee2c6b9fbd3436ca2a9001e19f251b677757fe5e88e7f94a0664231e020") version("3.2.9", sha256="795ad4bd42e15cf3ef2e5329aa7e4f2cdeb7e186ce2e350a45127e319db2904b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl", type=("build", "run")) depends_on(Boost.with_default_variants) depends_on("zlib-api") @@ -39,11 +43,11 @@ def patch(self): filter_file("-minline-all-stringops", "", m) def setup_build_environment(self, env): - if "@4:" in self.spec: + if self.spec.satisfies("@4:"): env.set("DEST", self.prefix) def install(self, spec, prefix): installer = Executable("./install.sh") installer() - if "@:4" in self.spec: + if self.spec.satisfies("@:4"): install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/matio/package.py b/var/spack/repos/builtin/packages/matio/package.py index ea4103996c22bc..460d700b919209 100644 --- a/var/spack/repos/builtin/packages/matio/package.py +++ b/var/spack/repos/builtin/packages/matio/package.py @@ -33,6 +33,8 @@ class Matio(AutotoolsPackage): version("1.5.3", sha256="85ba46e192331473dc4d8a9d266679f8f81e60c06debdc4b6f9d7906bad46257") version("1.5.2", sha256="db02d0fb3373c3d766a606309b17e64a5d8da55610e921a9f1a0ec171e911d45") + depends_on("c", type="build") # generated + variant("zlib", default=True, description="support for compressed mat files") variant("hdf5", default=True, description="support for version 7.3 mat files via hdf5") variant("shared", default=True, description="Enables the build of shared libraries.") diff --git a/var/spack/repos/builtin/packages/matrix-switch/package.py b/var/spack/repos/builtin/packages/matrix-switch/package.py new file mode 100644 index 00000000000000..e29afca4904c49 --- /dev/null +++ b/var/spack/repos/builtin/packages/matrix-switch/package.py @@ -0,0 +1,55 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class MatrixSwitch(CMakePackage): + """Intermediary interface between high-level routines for + physics-related algorithms and low-level routines dealing + with matrix storage and manipulation.""" + + homepage = "https://gitlab.com/ElectronicStructureLibrary/omm/matrixswitch" + url = "https://gitlab.com/ElectronicStructureLibrary/omm/matrixswitch/-/archive/1.2.1/matrixswitch-1.2.1.tar.gz" + git = "https://gitlab.com/ElectronicStructureLibrary/omm/matrixswitch.git" + + maintainers("RMeli") + + license("BSD-2-Clause", checked_by="RMeli") + + version("1.2.1", sha256="a3c2bac20435a8217cd1a1abefa8b7f8c52b1c6f55a75b2861565ade5ecfe37f") + version("master", branch="master") + + depends_on("fortran", type="build") # generated + + variant("lapack", default=True, description="Build with LAPACK interface.") + variant("mpi", default=True, description="Build with MPI support.") + variant("scalapack", default=True, when="+mpi", description="Build with ScaLAPACK interface.") + variant("dbcsr", default=False, when="+mpi", description="Build with DBCSR interface.") + + depends_on("cmake@3.22:", type="build") + generator("ninja") + + depends_on("lapack", when="+lapack") + depends_on("mpi", when="+mpi") + depends_on("scalapack", when="+scalapack") + depends_on("dbcsr~shared", when="+dbcsr") # Expects static library (FindCustomDbcsr) + + def cmake_args(self): + args = [ + self.define_from_variant("WITH_LAPACK", "lapack"), + self.define_from_variant("WITH_MPI", "mpi"), + self.define_from_variant("WITH_SCALAPACK", "scalapack"), + self.define_from_variant("WITH_DBCSR", "dbcsr"), + ] + + if self.spec.satisfies("+dbcsr"): + args.append(self.define("DBCSR_ROOT", self.spec["dbcsr"].prefix)) + + return args + + @property + def libs(self): + return find_libraries("libmatrixswitch", root=self.home, recursive=True, shared=False) diff --git a/var/spack/repos/builtin/packages/maverick/package.py b/var/spack/repos/builtin/packages/maverick/package.py index fa0df4f84a60f4..bce42ca490cd22 100644 --- a/var/spack/repos/builtin/packages/maverick/package.py +++ b/var/spack/repos/builtin/packages/maverick/package.py @@ -15,6 +15,9 @@ class Maverick(MakefilePackage): version("1.0.4", sha256="d4634c1b3f09cec9eb60d72348e2f479d74220ecbdebd940bb18b480db8df8cb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + conflicts("%gcc@:6.0") conflicts("%cce") conflicts("%apple-clang") diff --git a/var/spack/repos/builtin/packages/mawk/package.py b/var/spack/repos/builtin/packages/mawk/package.py index 762b3929f951dc..deb5126d7c1497 100644 --- a/var/spack/repos/builtin/packages/mawk/package.py +++ b/var/spack/repos/builtin/packages/mawk/package.py @@ -22,4 +22,6 @@ class Mawk(AutotoolsPackage): ) version("1.3.4", sha256="2f2ab8831c441a5793ad333193c888c9ba29c900f009aa23c9fffc100c405925") + depends_on("c", type="build") # generated + provides("awk") diff --git a/var/spack/repos/builtin/packages/mbdyn/package.py b/var/spack/repos/builtin/packages/mbdyn/package.py index c7276ad216ca17..34222aab149f13 100644 --- a/var/spack/repos/builtin/packages/mbdyn/package.py +++ b/var/spack/repos/builtin/packages/mbdyn/package.py @@ -17,5 +17,9 @@ class Mbdyn(AutotoolsPackage): version("1.7.3", sha256="3cf05cd1cb14c1af3d987aac119b6ecf0d835bc1aee06bc4cf7cc5a245c1f36d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Failed to build mbdyn with gcc@4.8.5 and gcc@9.2.0 conflicts("%gcc@:5.0,9.0:") diff --git a/var/spack/repos/builtin/packages/mbedtls/package.py b/var/spack/repos/builtin/packages/mbedtls/package.py index 0585a2529c6193..7f0bbc100006c7 100644 --- a/var/spack/repos/builtin/packages/mbedtls/package.py +++ b/var/spack/repos/builtin/packages/mbedtls/package.py @@ -121,6 +121,8 @@ class Mbedtls(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + variant("pic", default=False, description="Compile with position independent code.") variant( "build_type", diff --git a/var/spack/repos/builtin/packages/mc/package.py b/var/spack/repos/builtin/packages/mc/package.py index 890efee8c55494..045eae01945633 100644 --- a/var/spack/repos/builtin/packages/mc/package.py +++ b/var/spack/repos/builtin/packages/mc/package.py @@ -14,12 +14,15 @@ class Mc(AutotoolsPackage): license("GPL-3.0-or-later") + version("4.8.31", sha256="f42f4114ed42f6cf9995f1d896fa6c797ccb36dac57760dda8dd9f78ac462841") version("4.8.28", sha256="6bb47533d7a55bb21e46292d2f94786c9037bd7a70bf02b6a3c48adb0c9ce20c") version("4.8.26", sha256="9d6358d0a351a455a1410aab57f33b6b48b0fcf31344b9a10b0ff497595979d1") version("4.8.23", sha256="238c4552545dcf3065359bd50753abbb150c1b22ec5a36eaa02c82808293267d") version("4.8.21", sha256="251d9f0ef9309ef3eea0fdc4c12b8b61149e5056bef1b2de2ccc7f015d973444") version("4.8.20", sha256="2d85daaa6ab26e524946df4823ac2f69802bc16bc967781b5e28d5b86fc3b979") + depends_on("c", type="build") # generated + depends_on("ncurses") depends_on("pkgconfig", type="build") depends_on("glib@2.14:") @@ -33,7 +36,7 @@ def setup_build_environment(self, env): def configure_args(self): args = [ - "CFLAGS={0}".format(self.compiler.c99_flag), + f"CFLAGS={self.compiler.c99_flag}", "--disable-debug", "--disable-dependency-tracking", "--disable-silent-rules", diff --git a/var/spack/repos/builtin/packages/mcl/package.py b/var/spack/repos/builtin/packages/mcl/package.py index 8de3dcc57ddf54..e17f5a98d5b885 100644 --- a/var/spack/repos/builtin/packages/mcl/package.py +++ b/var/spack/repos/builtin/packages/mcl/package.py @@ -18,6 +18,8 @@ class Mcl(AutotoolsPackage): version("14-137", sha256="b5786897a8a8ca119eb355a5630806a4da72ea84243dba85b19a86f14757b497") + depends_on("c", type="build") # generated + @when("%gcc@10:") def patch(self): filter_file("^dim", "extern dim", "src/impala/iface.h") diff --git a/var/spack/repos/builtin/packages/mcpp/package.py b/var/spack/repos/builtin/packages/mcpp/package.py index bc0530cc512432..0dd0562ee2d32d 100644 --- a/var/spack/repos/builtin/packages/mcpp/package.py +++ b/var/spack/repos/builtin/packages/mcpp/package.py @@ -15,6 +15,9 @@ class Mcpp(AutotoolsPackage, SourceforgePackage): version("2.7.2", sha256="3b9b4421888519876c4fc68ade324a3bbd81ceeb7092ecdbbc2055099fcb8864") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def configure_args(self): config_args = ["--enable-mcpplib", "--disable-static"] return config_args diff --git a/var/spack/repos/builtin/packages/mct/package.py b/var/spack/repos/builtin/packages/mct/package.py index 1f6852c55138e9..53d1eb68ea0a4f 100644 --- a/var/spack/repos/builtin/packages/mct/package.py +++ b/var/spack/repos/builtin/packages/mct/package.py @@ -23,4 +23,7 @@ class Mct(AutotoolsPackage): version("2.11.0", sha256="1b2a30bcba0081226ff1f1f5152e82afa3a2bb911215883965e669f776dcb365") version("2.10.0", sha256="42f32e3ab8bba31d16a1c6c9533f717a9d950e42c9b03b864b3436335d4e1b71") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/mctc-lib/package.py b/var/spack/repos/builtin/packages/mctc-lib/package.py index bcbed778e8096b..43eb1bd2bf9ff6 100644 --- a/var/spack/repos/builtin/packages/mctc-lib/package.py +++ b/var/spack/repos/builtin/packages/mctc-lib/package.py @@ -21,6 +21,8 @@ class MctcLib(MesonPackage): version("0.3.1", sha256="a5032a0bbbbacc952037c5215b71aa6b438767a84bafb60fda25ba43c8835513") version("0.3.0", sha256="81f3edbf322e6e28e621730a796278498b84af0f221f785c537a315312059bf0") + depends_on("fortran", type="build") # generated + variant("json", default=False, description="Enable support for JSON") depends_on("meson@0.57.2:", type="build") diff --git a/var/spack/repos/builtin/packages/mcutils/package.py b/var/spack/repos/builtin/packages/mcutils/package.py index 82526e0144413c..fbf48a56d3f7c6 100644 --- a/var/spack/repos/builtin/packages/mcutils/package.py +++ b/var/spack/repos/builtin/packages/mcutils/package.py @@ -33,6 +33,8 @@ class Mcutils(MakefilePackage): version("1.0.1", tag="mcutils-1.0.1", commit="85bb1c9e2761a7c70bdd18955d6cccc120d9c523") version("1.0.0", tag="mcutils-1.0.0", commit="7ae9d007493ce65f5eac432d0ea6f730512a0a8a") + depends_on("cxx", type="build") # generated + depends_on("heputils", when="@1.1.0:") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/mdsplus/package.py b/var/spack/repos/builtin/packages/mdsplus/package.py index f4dad7bc6335f5..3f2ca7a83d24eb 100644 --- a/var/spack/repos/builtin/packages/mdsplus/package.py +++ b/var/spack/repos/builtin/packages/mdsplus/package.py @@ -26,6 +26,10 @@ class Mdsplus(AutotoolsPackage): submodules=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("java", default=True, description="Build java libraries and applications") variant("python", default=True, description="Install python module") diff --git a/var/spack/repos/builtin/packages/mdtest/package.py b/var/spack/repos/builtin/packages/mdtest/package.py index 9dc575f6720ae8..de0f92c1040f59 100644 --- a/var/spack/repos/builtin/packages/mdtest/package.py +++ b/var/spack/repos/builtin/packages/mdtest/package.py @@ -16,6 +16,8 @@ class Mdtest(Package): version("1.9.3", commit="49f3f047c254c62848c23226d6f1afa5fc3c6583") + depends_on("c", type="build") # generated + depends_on("mpi") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/med/package.py b/var/spack/repos/builtin/packages/med/package.py index 1d8aab4f536830..8e22764f6138fe 100644 --- a/var/spack/repos/builtin/packages/med/package.py +++ b/var/spack/repos/builtin/packages/med/package.py @@ -16,34 +16,67 @@ class Med(CMakePackage): license("LGPL-3.0-only") - # 4.1.0 does not compile in static mode - version("4.1.0", sha256="847db5d6fbc9ce6924cb4aea86362812c9a5ef6b9684377e4dd6879627651fce") + version( + "5.0.0", + sha256="267e76d0c67ec51c10e3199484ec1508baa8d5ed845c628adf660529dce7a3d4", + url="https://files.salome-platform.org/Salome/medfile/med-5.0.0.tar.bz2", + ) + version( + "4.1.1", + sha256="a082b705d1aafe95d3a231d12c57f0b71df554c253e190acca8d26fc775fb1e6", + url="https://files.salome-platform.org/Salome/medfile/med-4.1.1.tar.gz", + ) + # Older versions are no more available from the official provider + version( + "4.1.0", + sha256="847db5d6fbc9ce6924cb4aea86362812c9a5ef6b9684377e4dd6879627651fce", + deprecated=True, + ) version( "4.0.0", sha256="a474e90b5882ce69c5e9f66f6359c53b8b73eb448c5f631fa96e8cd2c14df004", - preferred=True, + deprecated=True, ) - version("3.2.0", sha256="d52e9a1bdd10f31aa154c34a5799b48d4266dc6b4a5ee05a9ceda525f2c6c138") + version( + "3.2.0", + sha256="d52e9a1bdd10f31aa154c34a5799b48d4266dc6b4a5ee05a9ceda525f2c6c138", + deprecated=True, + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant("api23", default=True, description="Enable API2.3") variant("mpi", default=True, description="Enable MPI") variant("shared", default=False, description="Builds a shared version of the library") variant("fortran", default=False, description="Enable Fortran support") + variant("doc", default=False, description="Install documentation") + variant("python", default=False, description="Build Python bindings") + + depends_on("hdf5@:1.8.22", when="@3.2.0") + depends_on("hdf5@1.10.2:1.10.7", when="@4") + depends_on("hdf5@1.12.1:1.12", when="@5:") + depends_on("hdf5~mpi", when="~mpi") + depends_on("hdf5+mpi", when="+mpi") depends_on("mpi", when="+mpi") - depends_on("hdf5@:1.8.22+mpi", when="@3.2.0+mpi") - depends_on("hdf5@1.10.2:1.10.7+mpi", when="@4.0.0:+mpi") - depends_on("hdf5@:1.8.22~mpi", when="@3.2.0~mpi") - depends_on("hdf5@1.10.2:1.10.7~mpi", when="@4.0.0:~mpi") - # the "TARGET hdf5" patch below only works with HDF5 shared library builds - depends_on("hdf5+shared", when="@4.0.0:4.1.99") + + depends_on("doxygen", type="build", when="+doc") + + depends_on("swig", type="build", when="+python") + depends_on("python", when="+python") + conflicts("~shared", when="+python", msg="Python bindings require shared libraries") conflicts("@4.1.0", when="~shared", msg="Link error when static") # C++11 requires a space between literal and identifier patch("add_space.patch", when="@3.2.0") - # fix problem where CMake "could not find TARGET hdf5" - patch("med-4.1.0-hdf5-target.patch", when="@4.0.0:4.1.99") + + # Fix problem where CMake "could not find TARGET hdf5" + # The patch only works with HDF5 shared library builds + patch("med-4.1.0-hdf5-target.patch", when="@4.0.0:4.1.0") + depends_on("hdf5+shared", when="@4.0.0:4.1.0") def patch(self): # resembles FindSalomeHDF5.patch as in salome-configuration @@ -61,8 +94,8 @@ def cmake_args(self): options = [ self.define("HDF5_ROOT_DIR", spec["hdf5"].prefix), self.define("MEDFILE_BUILD_TESTS", self.run_tests), - self.define("MEDFILE_BUILD_PYTHON", False), - self.define("MEDFILE_INSTALL_DOC", False), + self.define_from_variant("MEDFILE_BUILD_PYTHON", "python"), + self.define_from_variant("MEDFILE_INSTALL_DOC", "doc"), ] if "~fortran" in spec: options.append("-DCMAKE_Fortran_COMPILER=") diff --git a/var/spack/repos/builtin/packages/medipack/package.py b/var/spack/repos/builtin/packages/medipack/package.py index 7823a2227942b3..02c046215b55bf 100644 --- a/var/spack/repos/builtin/packages/medipack/package.py +++ b/var/spack/repos/builtin/packages/medipack/package.py @@ -16,6 +16,8 @@ class Medipack(CMakePackage): version("1.2.2", sha256="8937fa1025c6fb12f516cacf38a7f776221e7e818b30f17ce334c63f78513aa7") version("1.2.1", sha256="c746196b98cfe24a212584cdb88bd12ebb14f4a54728070d605e0c6d0e75db8a") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.12:", type="build", when="@1.2.2:") build_system( diff --git a/var/spack/repos/builtin/packages/meep/package.py b/var/spack/repos/builtin/packages/meep/package.py index 18771f50c5c188..768a5c7babd58e 100644 --- a/var/spack/repos/builtin/packages/meep/package.py +++ b/var/spack/repos/builtin/packages/meep/package.py @@ -18,6 +18,7 @@ class Meep(AutotoolsPackage): version("master", branch="master") + version("1.29.0", sha256="f63bdf6a8fbae8aad87d4f683da3a466d687848a53bbebe1d6935fb268aeeffa") version("1.28.0", sha256="fe79ec9b0d0cf87c3855a1661a38f23a3100120174f7e2df8add96cafe201544") version("1.25.0", sha256="3e5d6c6ef69a8cc7810bdd6d681ae494bfe7a4e91041abe5494f5c8a82d02e6f") version("1.21.0", sha256="71911cd2f38b15bdafe9a27ad111f706f24717894d5f9b6f9f19c6c10a0d5896") @@ -37,6 +38,9 @@ class Meep(AutotoolsPackage): url="http://ab-initio.mit.edu/meep/old/meep-1.1.1.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("blas", default=True, description="Enable BLAS support") variant("lapack", default=True, description="Enable LAPACK support") variant("harminv", default=True, description="Enable Harminv support") diff --git a/var/spack/repos/builtin/packages/megadock/package.py b/var/spack/repos/builtin/packages/megadock/package.py index c0aceac0b5d5c4..3d81a58bcfe230 100644 --- a/var/spack/repos/builtin/packages/megadock/package.py +++ b/var/spack/repos/builtin/packages/megadock/package.py @@ -20,6 +20,8 @@ class Megadock(MakefilePackage, CudaPackage): version("4.1.1", sha256="5e08416ea86169be9f0a998f081f53c04aa8696ef83b9fcc5bf685fe45d52087") version("4.0.3", sha256="c1409a411555f4f7b4eeeda81caf622d8a28259a599ea1d2181069c55f257664") + depends_on("cxx", type="build") # generated + variant("mpi", description="Enable MPI", default=False) depends_on("fftw") diff --git a/var/spack/repos/builtin/packages/melissa-api/package.py b/var/spack/repos/builtin/packages/melissa-api/package.py index 931460e22a899a..f40b2ddca2c554 100644 --- a/var/spack/repos/builtin/packages/melissa-api/package.py +++ b/var/spack/repos/builtin/packages/melissa-api/package.py @@ -21,6 +21,9 @@ class MelissaApi(CMakePackage): version("develop", branch="develop") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.7.2:", type="build") depends_on("libzmq@4.1.5:") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/melissa/package.py b/var/spack/repos/builtin/packages/melissa/package.py index 58855d6f2caa0a..dd1cfa45ef1f87 100644 --- a/var/spack/repos/builtin/packages/melissa/package.py +++ b/var/spack/repos/builtin/packages/melissa/package.py @@ -31,6 +31,9 @@ class Melissa(CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("no_mpi_api", default=False, description="Enable the deprecated no-MPI API") variant("shared", default=True, description="Build shared libraries") diff --git a/var/spack/repos/builtin/packages/memaxes/package.py b/var/spack/repos/builtin/packages/memaxes/package.py index b6a2f1651160b4..529a70bf63c1ee 100644 --- a/var/spack/repos/builtin/packages/memaxes/package.py +++ b/var/spack/repos/builtin/packages/memaxes/package.py @@ -6,7 +6,7 @@ from spack.package import * -class Memaxes(Package): +class Memaxes(CMakePackage): """MemAxes is a visualizer for sampled memory trace data.""" homepage = "https://github.com/llnl/MemAxes" @@ -19,11 +19,7 @@ class Memaxes(Package): url="https://github.com/llnl/MemAxes/archive/v0.5.tar.gz", ) + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.9:", type="build") depends_on("qt@5:") - - def install(self, spec, prefix): - with working_dir("spack-build", create=True): - cmake("..", *std_cmake_args) - make() - make("install") diff --git a/var/spack/repos/builtin/packages/memcached/package.py b/var/spack/repos/builtin/packages/memcached/package.py index a4a7260ac1a8a5..c99ecd67477ae9 100644 --- a/var/spack/repos/builtin/packages/memcached/package.py +++ b/var/spack/repos/builtin/packages/memcached/package.py @@ -26,6 +26,8 @@ class Memcached(AutotoolsPackage): version("1.5.14", sha256="ae8ed2ed853b840a8430d8575d4e91b87c550b111874b416c551001403ac6a74") version("1.5.13", sha256="ae59a8b49be17afb344e57c8a8d64f9ae38b6efbc3f9115a422dbcb2b23795fc") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/meme/package.py b/var/spack/repos/builtin/packages/meme/package.py index 4aaf317f57080d..77b69170c22132 100644 --- a/var/spack/repos/builtin/packages/meme/package.py +++ b/var/spack/repos/builtin/packages/meme/package.py @@ -22,6 +22,8 @@ class Meme(AutotoolsPackage): version("4.12.0", sha256="49ff80f842b59d328588acfcd1d15bf94c55fed661d22b0f95f37430cc363a06") version("4.11.4", sha256="3e869ff57e327a9c8615dbef784e3f1095f7f7a0120cecd55efe10c3f2ee8eb3") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("magick", default=False, description="Enable imagemagick for png output") diff --git a/var/spack/repos/builtin/packages/memkind/package.py b/var/spack/repos/builtin/packages/memkind/package.py index a853e5df853c7a..4ab957483b092b 100644 --- a/var/spack/repos/builtin/packages/memkind/package.py +++ b/var/spack/repos/builtin/packages/memkind/package.py @@ -35,6 +35,9 @@ class Memkind(AutotoolsPackage): version("1.8.0", sha256="8b57c5afa8afa6793e4662322e37620bbb11f119cd8d29654ec00945bbe13a17") version("1.7.0", sha256="5048eaaa1bc484203c685a019f3f428ab6c9b1cf94ef6d264e299bc0127ec572") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/memsurfer/package.py b/var/spack/repos/builtin/packages/memsurfer/package.py index b10bbf4e04b6de..2b6e3b812b82af 100644 --- a/var/spack/repos/builtin/packages/memsurfer/package.py +++ b/var/spack/repos/builtin/packages/memsurfer/package.py @@ -19,7 +19,7 @@ class Memsurfer(PythonPackage): version("master", branch="master", submodules=True) version("develop", branch="develop", submodules=True) - variant("osmesa", default=False, description="Enable OSMesa support (for VTK)") + depends_on("cxx", type="build") # generated extends("python") depends_on("python@3.7:", type=("build", "run")) @@ -36,8 +36,6 @@ class Memsurfer(PythonPackage): # vtk needs to know whether to build with mesa or opengl depends_on("vtk@8.1.2 ~ffmpeg~mpi+opengl2~qt~xdmf+python") - depends_on("vtk ~osmesa", when="~osmesa") - depends_on("vtk +osmesa", when="+osmesa") # memsurfer's setup needs path to these deps to build extension modules def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/mepo/package.py b/var/spack/repos/builtin/packages/mepo/package.py new file mode 100644 index 00000000000000..6d124d2121f90e --- /dev/null +++ b/var/spack/repos/builtin/packages/mepo/package.py @@ -0,0 +1,27 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Mepo(PythonPackage): + """Tool to manage (m)ultiple git r(epo)sitories""" + + homepage = "https://github.com/GEOS-ESM/mepo" + git = "https://github.com/GEOS-ESM/mepo.git" + pypi = "mepo/mepo-2.0.0rc4.tar.gz" + + maintainers("pchakraborty", "mathomp4") + + license("Apache-2.0", checked_by="mathomp4") + + version("2.0.0rc4", sha256="5f6113be565c561c08114355570a259042b25222a9e8e1dc6e6e44448381cd36") + version("2.0.0rc3", sha256="c0c897a33f5018489e6cc14892961831c8922a3378ac30436496c52bf877aff7") + + depends_on("python@3.9:", type=("build", "run")) + depends_on("py-colorama@0.4.6:", type=("build", "run")) + depends_on("py-pyyaml@6.0.1:", type=("build", "run")) + + depends_on("py-hatchling", type="build") diff --git a/var/spack/repos/builtin/packages/meraculous/package.py b/var/spack/repos/builtin/packages/meraculous/package.py index 1e17f87a8e32f1..2e87d70a016d77 100644 --- a/var/spack/repos/builtin/packages/meraculous/package.py +++ b/var/spack/repos/builtin/packages/meraculous/package.py @@ -20,6 +20,9 @@ class Meraculous(CMakePackage, SourceforgePackage): version("2.2.5.1", branch="release-2.2.5.1") version("2.2.4", sha256="3b4b8848232be902af9ebc77b38b83bcc531f12120115be089bdd6371ad2bf5b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl", type=("build", "run")) depends_on("boost@1.5.0:") diff --git a/var/spack/repos/builtin/packages/mercurial/package.py b/var/spack/repos/builtin/packages/mercurial/package.py index df0fb44fece43f..c8c8036f75d187 100644 --- a/var/spack/repos/builtin/packages/mercurial/package.py +++ b/var/spack/repos/builtin/packages/mercurial/package.py @@ -16,6 +16,7 @@ class Mercurial(PythonPackage): license("GPL-2.0-or-later") + version("6.7.3", sha256="00196944ea92738809317dc7a8ed7cb21287ca0a00a85246e66170955dcd9031") version("6.6.3", sha256="f75d6a4a75823a1b7d713a4967eca2f596f466e58fc6bc06d72642932fd7e307") version("6.4.5", sha256="b0b4b00b8b2639c8be387394796f0425beb339314df7e72937f8ddd2a41b1b8a") version("6.3.3", sha256="13c97ff589c7605e80a488f336852ce1d538c5d4143cfb33be69bdaddd9157bd") @@ -28,6 +29,9 @@ class Mercurial(PythonPackage): version("5.6.1", sha256="e55c254f4904c45226a106780e57f4279aee03368f6ff6a981d5d2a38243ffad") version("5.3", sha256="e57ff61d6b67695149dd451922b40aa455ab02e01711806a131a1e95c544f9b9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python+bz2+ssl+zlib", type=("build", "run")) depends_on("python@3.5:", when="@5.2:", type=("build", "run")) depends_on("python@3.6:", when="@6.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/mercury/package.py b/var/spack/repos/builtin/packages/mercury/package.py index 4371ffdd1469e4..9a533cde8c1993 100644 --- a/var/spack/repos/builtin/packages/mercury/package.py +++ b/var/spack/repos/builtin/packages/mercury/package.py @@ -29,6 +29,9 @@ class Mercury(CMakePackage): version("1.0.0", sha256="fb0e44d13f4652f53e21040435f91d452bc2b629b6e98dcf5292cd0bece899d4") version("0.9.0", sha256="40868e141cac035213fe79400f8926823fb1f5a0651fd7027cbe162b063843ef") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("bmi", default=False, description="Use BMI plugin") variant("mpi", default=False, description="Use MPI plugin") variant("ofi", default=True, when="@1.0.0:", description="Use OFI libfabric plugin") diff --git a/var/spack/repos/builtin/packages/mesa-demos/package.py b/var/spack/repos/builtin/packages/mesa-demos/package.py index c85b2eb2e3ddab..6282ddf9e0553b 100644 --- a/var/spack/repos/builtin/packages/mesa-demos/package.py +++ b/var/spack/repos/builtin/packages/mesa-demos/package.py @@ -2,8 +2,6 @@ # 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 * @@ -20,17 +18,8 @@ class MesaDemos(AutotoolsPackage): version("8.2.0", sha256="5a9f71b815d968d0c3b77edfcc3782d0211f8520b00da9e554ccfed80c8889f6") version("8.1.0", sha256="cc5826105355830208c90047fc38c5b09fa3ab0045366e7e859104935b00b76d") - variant( - "gl", - default="glx" if sys.platform.startswith("linux") else "osmesa", - values=("glx", "osmesa", "other"), - multi=False, - description="The OpenGL provider to use", - ) - conflicts("^osmesa", when="gl=glx") - conflicts("^osmesa", when="gl=other") - conflicts("^glx", when="gl=osmesa") - conflicts("^glx", when="gl=other") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("autoconf", type="build") depends_on("automake", type="build") @@ -39,10 +28,8 @@ class MesaDemos(AutotoolsPackage): depends_on("pkgconfig", type="build") depends_on("gl") - depends_on("osmesa", when="gl=osmesa") - depends_on("glx", when="gl=glx") - depends_on("libx11", when="gl=glx") - depends_on("libxext", when="gl=glx") + depends_on("libx11", when="^[virtuals=gl] glx") + depends_on("libxext", when="^[virtuals=gl] glx") depends_on("glu") depends_on("glew@1.5.4:") @@ -64,11 +51,11 @@ def configure_args(self): "--disable-rbug", "--without-glut", ] - if "gl=glx" in spec: + if spec.satisfies("^[virtuals=gl] glx"): args.append("--enable-x11") else: args.append("--disable-x11") - if "gl=osmesa" in spec: + if spec.satisfies("^[virtuals=gl] osmesa"): args.append("--enable-osmesa") else: args.append("--disable-osmesa") diff --git a/var/spack/repos/builtin/packages/mesa-glu/package.py b/var/spack/repos/builtin/packages/mesa-glu/package.py index 071703aa5f3208..4692ad4e6b73e3 100644 --- a/var/spack/repos/builtin/packages/mesa-glu/package.py +++ b/var/spack/repos/builtin/packages/mesa-glu/package.py @@ -2,9 +2,6 @@ # 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 * @@ -18,22 +15,10 @@ class MesaGlu(AutotoolsPackage): version("9.0.1", sha256="f6f484cfcd51e489afe88031afdea1e173aa652697e4c19ddbcb8260579a10f7") version("9.0.0", sha256="4387476a1933f36fec1531178ea204057bbeb04cc2d8396c9ea32720a1f7e264") - variant( - "gl", - default="glx" if sys.platform.startswith("linux") else "other", - values=("glx", "osmesa", "other"), - multi=False, - description="The OpenGL provider to use", - ) - conflicts("^osmesa", when="gl=glx") - conflicts("^osmesa", when="gl=other") - conflicts("^glx", when="gl=osmesa") - conflicts("^glx", when="gl=other") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("gl@3:") - depends_on("osmesa", when="gl=osmesa") - depends_on("glx", when="gl=glx") - provides("glu@1.3") # When using -std=c++17, using register long will throw an error. This @@ -43,7 +28,7 @@ class MesaGlu(AutotoolsPackage): def configure_args(self): args = ["--disable-libglvnd"] - if "gl=osmesa" in self.spec: + if self.spec.satisfies("^[virtuals=gl] osmesa"): args.append("--enable-osmesa") else: args.append("--disable-osmesa") diff --git a/var/spack/repos/builtin/packages/mesa/package.py b/var/spack/repos/builtin/packages/mesa/package.py index 08b32ddd070f5a..61494f3db6a80e 100644 --- a/var/spack/repos/builtin/packages/mesa/package.py +++ b/var/spack/repos/builtin/packages/mesa/package.py @@ -22,10 +22,11 @@ class Mesa(MesonPackage): version("main", branch="main") version( - "23.2.1", - sha256="64de0616fc2d801f929ab1ac2a4f16b3e2783c4309a724c8a259b20df8bbc1cc", + "23.3.6", + sha256="cd3d6c60121dea73abbae99d399dc2facaecde1a8c6bd647e6d85410ff4b577b", preferred=True, ) + version("23.2.1", sha256="64de0616fc2d801f929ab1ac2a4f16b3e2783c4309a724c8a259b20df8bbc1cc") version("23.1.9", sha256="295ba27c28146ed09214e8ce79afa1659edf9d142decc3c91f804552d64f7510") version("23.0.3", sha256="386362a5d80df3b096636b67f340e1ce67b705b44767d5bdd11d2ed1037192d5") version("23.0.2", sha256="1b7d3399fc6f16f030361f925d33ebc7600cbf98094582f54775b6a1180529e7") @@ -48,6 +49,9 @@ class Mesa(MesonPackage): version("20.3.4", sha256="dc21a987ec1ff45b278fe4b1419b1719f1968debbb80221480e44180849b4084") version("20.2.1", sha256="d1a46d9a3f291bc0e0374600bdcb59844fa3eafaa50398e472a36fc65fd0244a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("meson@0.52:", type="build") depends_on("pkgconfig", type="build") @@ -61,6 +65,7 @@ class Mesa(MesonPackage): depends_on("unwind") depends_on("expat") depends_on("zlib-api") + depends_on("libxml2") # Internal options variant("llvm", default=True, description="Enable LLVM.") @@ -101,9 +106,7 @@ class Mesa(MesonPackage): # Provides provides("libglx", when="+glx") - # provides('egl@1.5', when='+egl') - provides("libosmesa", when="+osmesa") # Variant dependencies with when("+llvm"): @@ -112,12 +115,13 @@ class Mesa(MesonPackage): depends_on("libllvm@:12", when="@:21") depends_on("libllvm@:17", when="@:23") - depends_on("libx11", when="+glx") - depends_on("libxcb", when="+glx") - depends_on("libxext", when="+glx") - depends_on("libxt", when="+glx") - depends_on("xrandr", when="+glx") - depends_on("glproto@1.4.14:", when="+glx") + with when("+glx"): + depends_on("libx11") + depends_on("libxcb") + depends_on("libxext") + depends_on("libxt") + depends_on("xrandr") + depends_on("glproto@1.4.14:") # version specific issue # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96130 diff --git a/var/spack/repos/builtin/packages/mesa18/autotools-x11-nodri.patch b/var/spack/repos/builtin/packages/mesa18/autotools-x11-nodri.patch deleted file mode 100644 index a88f5f5113a85b..00000000000000 --- a/var/spack/repos/builtin/packages/mesa18/autotools-x11-nodri.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff --git a/configure.ac b/configure.ac -index cd9ff25..79bc511 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -1859,7 +1859,9 @@ for plat in $platforms; do - ;; - - x11) -- PKG_CHECK_MODULES([XCB_DRI2], [x11-xcb xcb xcb-dri2 >= $XCBDRI2_REQUIRED xcb-xfixes]) -+ if test "x$enable_dri" = "xyes"; then -+ PKG_CHECK_MODULES([XCB_DRI2], [x11-xcb xcb xcb-dri2 >= $XCBDRI2_REQUIRED xcb-xfixes]) -+ fi - DEFINES="$DEFINES -DHAVE_X11_PLATFORM" - ;; diff --git a/var/spack/repos/builtin/packages/mesa18/multiple-symbols_hash.patch b/var/spack/repos/builtin/packages/mesa18/multiple-symbols_hash.patch deleted file mode 100644 index 7c92326f3774d4..00000000000000 --- a/var/spack/repos/builtin/packages/mesa18/multiple-symbols_hash.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/src/gallium/auxiliary/util/u_debug_stack.c 2019-11-07 17:57:36.000000000 -0700 -+++ b/src/gallium/auxiliary/util/u_debug_stack.c 2020-07-23 15:30:46.033145497 -0600 -@@ -46,7 +46,7 @@ - #include "os/os_thread.h" - #include "u_hash_table.h" - --struct util_hash_table* symbols_hash; -+static struct util_hash_table* symbols_hash; - static mtx_t symbols_mutex = _MTX_INITIALIZER_NP; - - static unsigned hash_ptr(void* p) ---- a/src/gallium/auxiliary/util/u_debug_symbol.c 2019-11-07 17:58:53.000000000 -0700 -+++ b/src/gallium/auxiliary/util/u_debug_symbol.c 2020-07-23 15:31:06.400146072 -0600 -@@ -270,7 +270,7 @@ - debug_printf("\t%s\n", buf); - } - --struct util_hash_table* symbols_hash; -+static struct util_hash_table* symbols_hash; - static mtx_t symbols_mutex = _MTX_INITIALIZER_NP; - - static unsigned hash_ptr(void* p) diff --git a/var/spack/repos/builtin/packages/mesa18/package.py b/var/spack/repos/builtin/packages/mesa18/package.py deleted file mode 100644 index 17f6903c8d1b40..00000000000000 --- a/var/spack/repos/builtin/packages/mesa18/package.py +++ /dev/null @@ -1,228 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# 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 * - - -class Mesa18(AutotoolsPackage): - """Mesa is an open-source implementation of the OpenGL specification - - a system for rendering interactive 3D graphics.""" - - homepage = "https://www.mesa3d.org" - maintainers("v-dobrev", "ChristianTackeGSI") - - # Note that we always want to build from the git repo instead of a - # tarball since the tarball has pre-generated files for certain versions - # of LLVM while the git repo doesn't so it can adapt at build time to - # whatever version of LLVM you're using. - git = "https://gitlab.freedesktop.org/mesa/mesa.git" - - version("18.3.6", tag="mesa-18.3.6", commit="11049bcff86da8013a4f63bd68daf637e3af22f3") - - depends_on("autoconf", type="build") - depends_on("automake", type="build") - depends_on("libtool", type="build") - depends_on("m4", type="build") - depends_on("pkgconfig", type="build") - depends_on("binutils+plugins", when=(sys.platform != "darwin"), type="build") - depends_on("bison", type="build") - depends_on("flex", type="build") - depends_on("gettext", type="build") - depends_on("pkgconfig", type="build") - depends_on("python@:3.8", type="build") # https://github.com/spack/spack/issues/28219 - depends_on("py-mako@0.8.0:", type="build") - depends_on("libxml2") - depends_on("zlib-api") - depends_on("expat") - depends_on("ncurses+termlib") - - # Internal options - variant("llvm", default=True, description="Enable LLVM.") - variant( - "swr", - values=spack.variant.DisjointSetsOfValues( - ("none",), ("auto",), ("avx", "avx2", "knl", "skx") - ) - .with_non_feature_values("auto") - .with_non_feature_values("none") - .with_default("auto"), - when="+llvm", - description="Enable the SWR driver.", - ) - - # Front ends - variant("osmesa", default=True, description="Enable the OSMesa frontend.") - - is_linux = sys.platform.startswith("linux") - variant("glx", default=is_linux, description="Enable the GLX frontend.") - - # Additional backends - variant("opengles", default=False, description="Enable OpenGL ES support.") - - # Provides - provides("libglx", when="+glx") - provides("libosmesa", when="+osmesa") - - # Variant dependencies - depends_on("libllvm@6:10", when="+llvm") - depends_on("libx11", when="+glx") - depends_on("libxcb", when="+glx") - depends_on("libxext", when="+glx") - depends_on("glproto@1.4.14:", when="+glx") - - # Require at least 1 front-end - conflicts("~osmesa ~glx") - - # Prevent an unnecessary xcb-dri dependency - patch("autotools-x11-nodri.patch") - - # Backport Mesa MR#6053 to prevent multiply-defined symbols - patch("multiple-symbols_hash.patch", when="@:20.1.4%gcc@10:") - - def setup_build_environment(self, env): - env.set("PYTHON", self.spec["python"].command.path) - - def autoreconf(self, spec, prefix): - which("autoreconf")("--force", "--verbose", "--install") - - def configure_args(self): - spec = self.spec - args = [ - "LDFLAGS={0}".format(self.spec["ncurses"].libs.search_flags), - "--enable-shared", - "--disable-static", - "--disable-libglvnd", - "--disable-nine", - "--disable-omx-bellagio", - "--disable-omx-tizonia", - "--disable-opencl", - "--disable-opencl-icd", - "--disable-va", - "--disable-vdpau", - "--disable-xa", - "--disable-xvmc", - "--disable-osmesa", - "--with-vulkan-drivers=", - "--disable-egl", - "--disable-gbm", - "--disable-dri", - "--enable-opengl", - ] - - args_platforms = [] - args_gallium_drivers = ["swrast"] - args_dri_drivers = [] - - if spec.target.family == "arm" or spec.target.family == "aarch64": - args.append("--disable-libunwind") - - num_frontends = 0 - if "+osmesa" in spec: - num_frontends += 1 - args.append("--enable-gallium-osmesa") - else: - args.append("--disable-gallium-osmesa") - - if "+glx" in spec: - num_frontends += 1 - args.append("--enable-glx=gallium-xlib") - args_platforms.append("x11") - else: - args.append("--disable-glx") - - if "+opengles" in spec: - args.extend(["--enable-gles1", "--enable-gles2"]) - else: - args.extend(["--disable-gles1", "--disable-gles2"]) - - if num_frontends > 1: - args.append("--enable-shared-glapi") - else: - args.append("--disable-shared-glapi") - - if "+llvm" in spec: - args.append("--enable-llvm") - args.append("--with-llvm-prefix=%s" % spec["libllvm"].prefix) - if "+llvm_dylib" in spec["libllvm"]: - args.append("--enable-llvm-shared-libs") - else: - args.append("--disable-llvm-shared-libs") - else: - args.append("--disable-llvm") - - args_swr_arches = [] - if "swr=auto" in spec: - if "avx" in spec.target: - args_swr_arches.append("avx") - if "avx2" in spec.target: - args_swr_arches.append("avx2") - if "avx512f" in spec.target: - if "avx512er" in spec.target: - args_swr_arches.append("knl") - if "avx512bw" in spec.target: - args_swr_arches.append("skx") - else: - if "swr=avx" in spec: - args_swr_arches.append("avx") - if "swr=avx2" in spec: - args_swr_arches.append("avx2") - if "swr=knl" in spec: - args_swr_arches.append("knl") - if "swr=skx" in spec: - args_swr_arches.append("skx") - if args_swr_arches: - args_gallium_drivers.append("swr") - args.append("--with-swr-archs=" + ",".join(args_swr_arches)) - - # Add the remaining list args - args.append("--with-platforms=" + ",".join(args_platforms)) - args.append("--with-gallium-drivers=" + ",".join(args_gallium_drivers)) - args.append("--with-dri-drivers=" + ",".join(args_dri_drivers)) - - return args - - @property - def libs(self): - spec = self.spec - libs_to_seek = set() - if "platform=windows" in spec: - libs_to_seek.add("opengl32") - if "+osmesa" in spec: - libs_to_seek.add("osmesa") - else: - libs_to_seek.add("libGL") - if "+osmesa" in spec: - libs_to_seek.add("libOSMesa") - if "+glx" in spec: - libs_to_seek.add("libGL") - if "+opengles" in spec: - libs_to_seek.add("libGLESv1_CM") - libs_to_seek.add("libGLESv2") - - return find_libraries( - list(libs_to_seek), root=self.spec.prefix, shared=True, recursive=True - ) - - @property - def libglx_headers(self): - return find_headers("GL/glx", root=self.spec.prefix.include, recursive=False) - - @property - def libglx_libs(self): - return find_libraries("libGL", root=self.spec.prefix, recursive=True) - - @property - def libosmesa_headers(self): - return find_headers("GL/osmesa", root=self.spec.prefix.include, recursive=False) - - @property - def libosmesa_libs(self): - if "platform=windows" in self.spec: - lib_name = "osmesa" - else: - lib_name = "libOSMesa" - return find_libraries(lib_name, root=self.spec.prefix, recursive=True) diff --git a/var/spack/repos/builtin/packages/meshkit/package.py b/var/spack/repos/builtin/packages/meshkit/package.py index 20262d8d0808e7..bac6cbb77e3d41 100644 --- a/var/spack/repos/builtin/packages/meshkit/package.py +++ b/var/spack/repos/builtin/packages/meshkit/package.py @@ -17,6 +17,8 @@ class Meshkit(AutotoolsPackage): version("1.5.0", sha256="6a4c119af191e24ef40644acb7cfbe967af0678ac3412f38a943fb28d661cac7") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="enable mpi support") variant("netgen", default=False, description="enable netgen support") variant("debug", default=False, description="enable debug symbols") diff --git a/var/spack/repos/builtin/packages/meshtool/package.py b/var/spack/repos/builtin/packages/meshtool/package.py index bde4e0c9908fd2..d5d63ddd6895f9 100644 --- a/var/spack/repos/builtin/packages/meshtool/package.py +++ b/var/spack/repos/builtin/packages/meshtool/package.py @@ -16,6 +16,9 @@ class Meshtool(MakefilePackage): version("master", branch="master", preferred=True) # Version to use with openCARP releases + # It is possible that different openCARP releases rely on the same + # meshtool version + version("oc15.0", commit="867431d6bde35ad41104f611aa57130ef58cfb79") version("oc13.0", commit="867431d6bde35ad41104f611aa57130ef58cfb79") version("oc12.0", commit="867431d6bde35ad41104f611aa57130ef58cfb79") version("oc11.0", commit="867431d6bde35ad41104f611aa57130ef58cfb79") @@ -25,6 +28,8 @@ class Meshtool(MakefilePackage): version("oc8.1", commit="6c5cfbd067120901f15a04bf63beec409bda6dc9") version("oc7.0", commit="6c5cfbd067120901f15a04bf63beec409bda6dc9") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("meshtool", prefix.bin) diff --git a/var/spack/repos/builtin/packages/meson/package.py b/var/spack/repos/builtin/packages/meson/package.py index 995e302389f1a0..b2ffaef99fd105 100644 --- a/var/spack/repos/builtin/packages/meson/package.py +++ b/var/spack/repos/builtin/packages/meson/package.py @@ -2,8 +2,6 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) - - from spack.package import * diff --git a/var/spack/repos/builtin/packages/met/package.py b/var/spack/repos/builtin/packages/met/package.py index d0e196355dfbf7..c75ebe8cf1a06a 100644 --- a/var/spack/repos/builtin/packages/met/package.py +++ b/var/spack/repos/builtin/packages/met/package.py @@ -30,6 +30,9 @@ class Met(AutotoolsPackage): version("10.0.0", sha256="92f37c8bd83c951d86026cce294a16e4d3aa6dd41905629d0a729fa1bebe668a") version("9.1.3", sha256="7356a5ad79ca961fd965cadd93a7bf6c73b3aa5fb1a01a932580b94e66d0d0c8") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=True, description="Use OpenMP multithreading") variant("grib2", default=False, description="Enable compilation of utilities using GRIB2") variant("python", default=False, description="Enable python embedding") diff --git a/var/spack/repos/builtin/packages/metabat/package.py b/var/spack/repos/builtin/packages/metabat/package.py index b2a6526c84f59f..3871b38b6cdfed 100644 --- a/var/spack/repos/builtin/packages/metabat/package.py +++ b/var/spack/repos/builtin/packages/metabat/package.py @@ -30,6 +30,8 @@ class Metabat(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("cmake", type="build", when="@2.13:") depends_on("boost@1.55.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/metacarpa/package.py b/var/spack/repos/builtin/packages/metacarpa/package.py new file mode 100644 index 00000000000000..6ec57d2fe02ed0 --- /dev/null +++ b/var/spack/repos/builtin/packages/metacarpa/package.py @@ -0,0 +1,43 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * +from spack.pkg.builtin.boost import Boost + + +class Metacarpa(MakefilePackage): + """ + METACARPA is designed for meta-analysing genetic + association studies with overlapping or related samples, + when details of the overlap or relatedness are unknown. + It implements and expands a method first described by Province and Borecki. + """ + + homepage = "https://www.sanger.ac.uk/tool/metacarpa/" + url = "https://github.com/hmgu-itg/metacarpa/archive/refs/tags/1.0.1.tar.gz" + + version("1.0.1", sha256="7d8fc774a88bf75a53ef8f74462924abba9b99fccbaa9979654c01e4379fab91") + + depends_on("cxx", type="build") # generated + + depends_on("boost@1.60.0") + depends_on(Boost.with_default_variants) + depends_on("cmake") + build_system = "Makefile" + build_directory = "src" + + def edit(self, spec, prefix): + makefile = FileFilter("src/Makefile") + makefile.filter(r"^IDIR.*", "IDIR=" + spec["boost"].prefix.include) + makefile.filter(r"^LDIR.*", "LDIR=" + spec["boost"].prefix.lib) + + def install(self, spec, prefix): + mkdirp(prefix.src) + + install_tree("src", prefix.src) + + mkdirp(prefix.bin) + + install("src/metacarpa", prefix.bin) diff --git a/var/spack/repos/builtin/packages/metaeuk/package.py b/var/spack/repos/builtin/packages/metaeuk/package.py index cabccc9db21e2f..7c2b87ad01650d 100644 --- a/var/spack/repos/builtin/packages/metaeuk/package.py +++ b/var/spack/repos/builtin/packages/metaeuk/package.py @@ -19,4 +19,7 @@ class Metaeuk(CMakePackage): version("6-a5d39d9", sha256="be19c26f5bdb7dcdd7bc48172105afecf19e5a2e5555edb3ba0c4aa0e4aac126") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.12:", type="build") diff --git a/var/spack/repos/builtin/packages/metal/package.py b/var/spack/repos/builtin/packages/metal/package.py index bdb821b2e0ec77..841c48b86d15ed 100644 --- a/var/spack/repos/builtin/packages/metal/package.py +++ b/var/spack/repos/builtin/packages/metal/package.py @@ -18,6 +18,8 @@ class Metal(CMakePackage): "2020-05-05", sha256="0ffa2419ca2ab43766e7e6e8c97822c8ce1f5b6233fb5f992d1b1be1955fede7" ) + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build") depends_on("zlib-ng") diff --git a/var/spack/repos/builtin/packages/metall/package.py b/var/spack/repos/builtin/packages/metall/package.py index 454e7eee2fbef5..8ca6ee468d73ee 100644 --- a/var/spack/repos/builtin/packages/metall/package.py +++ b/var/spack/repos/builtin/packages/metall/package.py @@ -23,6 +23,9 @@ class Metall(CMakePackage): version("master", branch="master") version("develop", branch="develop") + version("0.28", sha256="770dedb7f8220c333688b232a22104ca9d8d5823e7a8a21152b58ef970eb85d0") + version("0.27", sha256="6e6f17a760778f9162def939701f9381a75e5275fd1eb1b2af4b2e89e86e1c58") + version("0.26", sha256="7453c87d99708be8542e354e582cbeefac1e5ba65e609cd85d7126c5b25a6d7b") version("0.25", sha256="223cb54543b62a62fdbbe6274b02ddcc14b29806e344ee7e2fd3f055c2374295") version("0.24", sha256="872de2a1b76d44e6876c0b672c0cc518c6f334959e4a229f2f18cc7e01edf477") version("0.23.1", sha256="25e8fbc424e66d09e0faf60029288e4612685675bfd947cc142bd9d6d0645ac4") @@ -42,7 +45,10 @@ class Metall(CMakePackage): version("0.10", sha256="58b4b5507d4db5baca315b1bed2b728981755d755b91ef63bd0b6dfaf320f46b") version("0.9", sha256="2d7bd9ea2f1e04136050f210884445a9e3dcb96c992cf42ff9ea4b392f85f927") - depends_on("cmake@3.10:", type="build") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + depends_on("cmake@3.12:", type="build") depends_on("boost@1.75:", type=("build", "link")) # googletest is required only for test diff --git a/var/spack/repos/builtin/packages/metaphysicl/package.py b/var/spack/repos/builtin/packages/metaphysicl/package.py index d1c85e22a9d74c..3f16a3f3765797 100644 --- a/var/spack/repos/builtin/packages/metaphysicl/package.py +++ b/var/spack/repos/builtin/packages/metaphysicl/package.py @@ -15,10 +15,13 @@ class Metaphysicl(AutotoolsPackage): license("LGPL-2.1-or-later") + version("0.6.0", sha256="a1b8469de17ad9960b4c99a9dbe2db46b7da50f97c811467efce470585d3f7f2") version("0.5.0", sha256="dbba0590970a128ae2ae7064b621f78f95ca2303b70a12b079a51702573840a6") version("0.3.3", sha256="6581ec6512d3509bfca6f93052f7d47dd2d9e4b9f2b3580d778495ae381a0b0d") version("0.2.0", sha256="ff4f9fad870dcdc85d56fb1f8d94123fecbef9189f967d254ba9607624b5f32e") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/methyldackel/package.py b/var/spack/repos/builtin/packages/methyldackel/package.py index 35e03b872d04a7..641c14f3500d5e 100644 --- a/var/spack/repos/builtin/packages/methyldackel/package.py +++ b/var/spack/repos/builtin/packages/methyldackel/package.py @@ -22,6 +22,8 @@ class Methyldackel(MakefilePackage): version("0.6.1", sha256="eeb1da4c830bcd9f3e6663a764947d957c41337643069524a4b545812fcf4819") + depends_on("c", type="build") # generated + depends_on("htslib@1.11:") depends_on("libbigwig") depends_on("curl") diff --git a/var/spack/repos/builtin/packages/metis/package.py b/var/spack/repos/builtin/packages/metis/package.py index c77ef4b34594f7..75e8b15982cfca 100644 --- a/var/spack/repos/builtin/packages/metis/package.py +++ b/var/spack/repos/builtin/packages/metis/package.py @@ -31,6 +31,8 @@ class Metis(CMakePackage, MakefilePackage): version("5.1.0", sha256="76faebe03f6c963127dbb73c13eab58c9a3faeae48779f049066a21c087c5db2") version("4.0.3", sha256="5efa35de80703c1b2c4d0de080fafbcf4e0d363a21149a1ad2f96e0144841a55") + depends_on("c", type="build") # generated + build_system( conditional("cmake", when="@5:"), conditional("makefile", when="@:4"), default="cmake" ) @@ -98,12 +100,32 @@ def setup_build_environment(self, env): class MakefileBuilder(spack.build_systems.makefile.MakefileBuilder, SetupEnvironment): @property - def build_targets(self): + def compile_options(self): options = [] if "+shared" in self.spec: - options.append("COPTIONS={0}".format(self.pkg.compiler.cc_pic_flag)) + options.append(self.pkg.compiler.cc_pic_flag) + if self.spec.satisfies("%cce@17:"): + options.append("-std=c89") + return options + + @property + def optimize_options(self): + options = [] if "+debug" in self.spec: - options.append("OPTFLAGS=-g -O0") + options.extend(["-g", "-O0"]) + else: + options.append("-O2") # default in Makefile.in + return options + + @property + def build_targets(self): + options = [] + copts = self.compile_options + oopts = self.optimize_options + if copts: + options.append("COPTIONS={0}".format(" ".join(copts))) + if oopts: + options.append("OPTFLAGS={0}".format(" ".join(oopts))) return options def install(self, pkg, spec, prefix): @@ -156,6 +178,8 @@ def install(self, pkg, spec, prefix): # Set up and run tests on installation ccompile( + *self.compile_options, + *self.optimize_options, "-I%s" % prefix.include, "-L%s" % prefix.lib, (pkg.compiler.cc_rpath_arg + prefix.lib if "+shared" in spec else ""), diff --git a/var/spack/repos/builtin/packages/metkit/package.py b/var/spack/repos/builtin/packages/metkit/package.py index 9d801477b704d6..05f4b33065acb1 100644 --- a/var/spack/repos/builtin/packages/metkit/package.py +++ b/var/spack/repos/builtin/packages/metkit/package.py @@ -24,6 +24,8 @@ class Metkit(CMakePackage): version("1.9.2", sha256="35d5f67196197cc06e5c2afc6d1354981e7c85a441df79a2fbd774e0c343b0b4") version("1.7.0", sha256="8c34f6d8ea5381bd1bcfb22462349d03e1592e67d8137e76b3cecf134a9d338c") + depends_on("cxx", type="build") # generated + variant("tools", default=True, description="Build the command line tools") variant("grib", default=True, description="Enable support for GRIB format") variant("odb", default=False, description="Enable support for ODB data") diff --git a/var/spack/repos/builtin/packages/mfem/mfem-4.7.patch b/var/spack/repos/builtin/packages/mfem/mfem-4.7.patch new file mode 100644 index 00000000000000..6e0d3c7ef574bb --- /dev/null +++ b/var/spack/repos/builtin/packages/mfem/mfem-4.7.patch @@ -0,0 +1,102 @@ +diff --git a/examples/hiop/ex9p.cpp b/examples/hiop/ex9p.cpp +index 4facbb3c0b..f783b97a3b 100644 +--- a/examples/hiop/ex9p.cpp ++++ b/examples/hiop/ex9p.cpp +@@ -96,6 +96,7 @@ public: + { + Vector w_glob(width); + pfes.Dof_TrueDof_Matrix()->MultTranspose(w, w_glob); ++ w_glob.HostReadWrite(); // read+write -> can use w_glob(i) (non-const) + for (int i = 0; i < width; i++) { grad(0, i) = w_glob(i); } + } + +diff --git a/linalg/sparsemat.cpp b/linalg/sparsemat.cpp +index 0b5334d2a6..efe471d416 100644 +--- a/linalg/sparsemat.cpp ++++ b/linalg/sparsemat.cpp +@@ -1267,24 +1267,32 @@ real_t SparseMatrix::InnerProduct(const Vector &x, const Vector &y) const + + void SparseMatrix::GetRowSums(Vector &x) const + { +- for (int i = 0; i < height; i++) ++ if (Finalized()) + { +- real_t a = 0.0; +- if (A) ++ auto d_I = ReadI(); ++ auto d_A = ReadData(); ++ auto d_x = x.Write(); ++ mfem::forall(height, [=] MFEM_HOST_DEVICE (int i) + { +- for (int j = I[i], end = I[i+1]; j < end; j++) ++ real_t sum = 0.0; ++ for (int j = d_I[i], end = d_I[i+1]; j < end; j++) + { +- a += A[j]; ++ sum += d_A[j]; + } +- } +- else ++ d_x[i] = sum; ++ }); ++ } ++ else ++ { ++ for (int i = 0; i < height; i++) + { ++ real_t a = 0.0; + for (RowNode *np = Rows[i]; np != NULL; np = np->Prev) + { + a += np->Value; + } ++ x(i) = a; + } +- x(i) = a; + } + } + +diff --git a/linalg/sparsemat.hpp b/linalg/sparsemat.hpp +index 7042279663..dc2d773bc4 100644 +--- a/linalg/sparsemat.hpp ++++ b/linalg/sparsemat.hpp +@@ -216,7 +216,7 @@ public: + void ClearCuSparse() { ClearGPUSparse(); } + + /// Check if the SparseMatrix is empty. +- bool Empty() const { return (A == NULL) && (Rows == NULL); } ++ bool Empty() const { return A.Empty() && (Rows == NULL); } + + /// Return the array #I. + inline int *GetI() { return I; } +diff --git a/tests/unit/general/test_umpire_mem.cpp b/tests/unit/general/test_umpire_mem.cpp +index 84457669ec..d4a7b85093 100644 +--- a/tests/unit/general/test_umpire_mem.cpp ++++ b/tests/unit/general/test_umpire_mem.cpp +@@ -18,12 +18,13 @@ + #include + #include + #include "umpire/Umpire.hpp" ++#include + + #ifdef MFEM_USE_CUDA + #include + constexpr const char * device_name = "cuda"; + #elif defined(MFEM_USE_HIP) +-constexpr const char * device_name = "raja-hip"; ++constexpr const char * device_name = "hip"; + #endif + + using namespace mfem; +@@ -45,10 +46,12 @@ static bool is_pinned_host(void * h_p) + unsigned flags; + #ifdef MFEM_USE_CUDA + auto err = cudaHostGetFlags(&flags, h_p); ++ cudaGetLastError(); // also resets last error + if (err == cudaSuccess) { return true; } + else if (err == cudaErrorInvalidValue) { return false; } + #elif defined(MFEM_USE_HIP) + auto err = hipHostGetFlags(&flags, h_p); ++ hipGetLastError(); // also resets last error + if (err == hipSuccess) { return true; } + else if (err == hipErrorInvalidValue) { return false; } + #endif diff --git a/var/spack/repos/builtin/packages/mfem/mfem-hip.patch b/var/spack/repos/builtin/packages/mfem/mfem-hip.patch deleted file mode 100644 index 565bae348c0009..00000000000000 --- a/var/spack/repos/builtin/packages/mfem/mfem-hip.patch +++ /dev/null @@ -1,24 +0,0 @@ -From 93ab69cac72cc2d13cfd4b7efcc235bdbca2b9f5 Mon Sep 17 00:00:00 2001 -From: Afzal Patel -Date: Wed, 17 Jan 2024 11:44:18 -0800 -Subject: [PATCH] Add hip library path to ghv flags so libamdhip64 can be found - ---- - config/makefile | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/config/makefile b/config/makefile -index 627d117..a453865 100644 ---- a/config/makefile -+++ b/config/makefile -@@ -38,7 +38,7 @@ all: header config-mk - MPI = $(MFEM_USE_MPI:NO=) - GHV_CXX ?= $(MFEM_CXX) - GHV = get_hypre_version --GHV_FLAGS = $(subst @MFEM_DIR@,$(if $(MFEM_DIR),$(MFEM_DIR),..),$(HYPRE_OPT)) -+GHV_FLAGS = $(subst @MFEM_DIR@,$(if $(MFEM_DIR),$(MFEM_DIR),..),$(HYPRE_OPT)) $(HIP_LIB) - SMX = $(if $(MFEM_USE_PUMI:NO=),MFEM_USE_SIMMETRIX) - SMX_PATH = $(PUMI_DIR)/include/gmi_sim.h - SMX_FILE = $(subst @MFEM_DIR@,$(if $(MFEM_DIR),$(MFEM_DIR),..),$(SMX_PATH)) --- -2.25.1 \ No newline at end of file diff --git a/var/spack/repos/builtin/packages/mfem/package.py b/var/spack/repos/builtin/packages/mfem/package.py index 5154558b895bdb..05c59675b6f973 100644 --- a/var/spack/repos/builtin/packages/mfem/package.py +++ b/var/spack/repos/builtin/packages/mfem/package.py @@ -6,7 +6,6 @@ import os import shutil import sys -from platform import machine from spack.package import * @@ -51,6 +50,13 @@ class Mfem(Package, CudaPackage, ROCmPackage): # other version. version("develop", branch="master") + version( + "4.7.0", + sha256="5e889493f5f79848f7b2d16afaae307c59880ac2a7ff2315551c60ca54717751", + url="https://bit.ly/mfem-4-7", + extension="tar.gz", + ) + version( "4.6.0", sha256="5fa9465b5bec56bfb777a4d2826fba48d85fbace4aed8b64a2fd4059bf075b15", @@ -155,6 +161,8 @@ class Mfem(Package, CudaPackage, ROCmPackage): extension="tar.gz", ) + depends_on("cxx", type="build") # generated + variant("static", default=True, description="Build static library") variant("shared", default=False, description="Build shared library") variant("mpi", default=True, sticky=True, description="Enable MPI parallelism") @@ -212,6 +220,21 @@ class Mfem(Package, CudaPackage, ROCmPackage): variant("examples", default=False, description="Build and install examples") variant("miniapps", default=False, description="Build and install miniapps") variant("exceptions", default=False, description="Enable the use of exceptions") + variant( + "precision", + default="double", + values=("single", "double"), + multi=False, + description="Floating point precision", + when="@4.7.0:", + ) + variant( + "cxxstd", + default="auto", + values=("auto", conditional("98", when="@:3"), "11", "14", "17"), + multi=False, + description="C++ language standard", + ) conflicts("+shared", when="@:3.3.2") conflicts("~static~shared") @@ -288,8 +311,9 @@ class Mfem(Package, CudaPackage, ROCmPackage): depends_on("sundials@2.7.0:+mpi+hypre", when="@3.3.2:+sundials+mpi") depends_on("sundials@5.0.0:5", when="@4.0.1-xsdk:4.4+sundials~mpi") depends_on("sundials@5.0.0:5+mpi+hypre", when="@4.0.1-xsdk:4.4+sundials+mpi") - depends_on("sundials@5.0.0:", when="@4.5.0:+sundials~mpi") - depends_on("sundials@5.0.0:+mpi+hypre", when="@4.5.0:+sundials+mpi") + depends_on("sundials@5.0.0:6.7.0", when="@4.5.0:+sundials~mpi") + depends_on("sundials@5.0.0:6.7.0+mpi+hypre", when="@4.5.0:+sundials+mpi") + conflicts("cxxstd=11", when="^sundials@6.4.0:") for sm_ in CudaPackage.cuda_arch_values: depends_on( "sundials@5.4.0:+cuda cuda_arch={0}".format(sm_), @@ -337,7 +361,7 @@ class Mfem(Package, CudaPackage, ROCmPackage): # The PETSc tests in MFEM will fail if PETSc is not configured with # MUMPS (and SuiteSparse in older versions). On the other hand, PETSc built # with MUMPS is not strictly required, so we do not require it here. - depends_on("petsc@3.8:+mpi+double+hypre", when="+petsc") + depends_on("petsc@3.8:+mpi+hypre", when="+petsc") depends_on("slepc@3.8.0:", when="+slepc") # If petsc is built with +cuda, propagate cuda_arch to petsc and slepc for sm_ in CudaPackage.cuda_arch_values: @@ -361,6 +385,7 @@ class Mfem(Package, CudaPackage, ROCmPackage): depends_on("conduit+mpi", when="+conduit+mpi") depends_on("libfms@0.2.0:", when="+fms") depends_on("ginkgo@1.4.0:", when="+ginkgo") + conflicts("cxxstd=11", when="^ginkgo") for sm_ in CudaPackage.cuda_arch_values: depends_on( "ginkgo+cuda cuda_arch={0}".format(sm_), when="+ginkgo+cuda cuda_arch={0}".format(sm_) @@ -402,6 +427,7 @@ class Mfem(Package, CudaPackage, ROCmPackage): depends_on("raja@0.13.0", when="@4.3.0+raja") depends_on("raja@0.14.0:2022.03", when="@4.4.0:4.5.0+raja") depends_on("raja@2022.10.3:", when="@4.5.2:+raja") + conflicts("cxxstd=11", when="^raja@2022.03.0:") for sm_ in CudaPackage.cuda_arch_values: depends_on( "raja+cuda cuda_arch={0}".format(sm_), when="+raja+cuda cuda_arch={0}".format(sm_) @@ -429,6 +455,7 @@ class Mfem(Package, CudaPackage, ROCmPackage): depends_on("umpire@2.0.0:2.1.0", when="@:4.3.0+umpire") depends_on("umpire@3.0.0:", when="@4.4.0:+umpire") + conflicts("cxxstd=11", when="^umpire@2022.03.0:") for sm_ in CudaPackage.cuda_arch_values: depends_on( "umpire+cuda cuda_arch={0}".format(sm_), when="+umpire+cuda cuda_arch={0}".format(sm_) @@ -448,6 +475,20 @@ class Mfem(Package, CudaPackage, ROCmPackage): "amgx~mpi cuda_arch={0}".format(sm_), when="+amgx~mpi cuda_arch={0}".format(sm_) ) + for using_double_cond in ["@:4.6", "precision=double"]: + with when(using_double_cond): + # May need to enforce precision consistency on other packages in the + # future. + depends_on("hypre precision=double", when="+mpi") + depends_on("petsc+double", when="+petsc") + depends_on("mumps+double", when="+mumps") + with when("precision=single"): + # May need to enforce precision consistency on other packages in the + # future. + depends_on("hypre precision=single", when="+mpi") + depends_on("petsc~double", when="+petsc") + depends_on("mumps+float", when="+mumps") + patch("mfem_ppc_build.patch", when="@3.2:3.3.0 arch=ppc64le") patch("mfem-3.4.patch", when="@3.4.0") patch("mfem-3.3-3.4-petsc-3.9.patch", when="@3.3.0:3.4.0 +petsc ^petsc@3.9.0:") @@ -468,7 +509,7 @@ class Mfem(Package, CudaPackage, ROCmPackage): when="@4.6.0 +gslib+shared+miniapps", sha256="2a31682d876626529e2778a216d403648b83b90997873659a505d982d0e65beb", ) - patch("mfem-hip.patch", when="+rocm ^hip@6.0:") + patch("mfem-4.7.patch", when="@4.7.0") phases = ["configure", "build", "install"] @@ -489,56 +530,16 @@ def setup_build_environment(self, env): # likely to be up to date in supporting *all* of MFEM's # configuration options. So, don't use CMake # - def configure(self, spec, prefix): + def get_make_config_options(self, spec, prefix): def yes_no(varstr): return "YES" if varstr in self.spec else "NO" - # See also find_system_libraries in lib/spack/llnl/util/filesystem.py - # where the same list of paths is used. - sys_lib_paths = [ - "/lib64", - "/lib", - "/usr/lib64", - "/usr/lib", - "/usr/local/lib64", - "/usr/local/lib", - "/usr/lib/x86_64-linux-gnu", - ] - - def is_sys_lib_path(dir): - return dir in sys_lib_paths - - xcompiler = "" - xlinker = "-Wl," - if "+cuda" in spec: - xcompiler = "-Xcompiler=" - xlinker = "-Xlinker=" - cuda_arch = None if "~cuda" in spec else spec.variants["cuda_arch"].value + xcompiler = "" if "~cuda" in spec else "-Xcompiler=" # We need to add rpaths explicitly to allow proper export of link flags - # from within MFEM. - - # Similar to spec[pkg].libs.ld_flags but prepends rpath flags too. - # Also does not add system library paths as defined by 'sys_lib_paths' - # above -- this is done to avoid issues like this: - # https://github.com/mfem/mfem/issues/1088. - def ld_flags_from_library_list(libs_list): - flags = [ - "%s-rpath,%s" % (xlinker, dir) - for dir in libs_list.directories - if not is_sys_lib_path(dir) - ] - flags += ["-L%s" % dir for dir in libs_list.directories if not is_sys_lib_path(dir)] - flags += [libs_list.link_flags] - return " ".join(flags) - - def ld_flags_from_dirs(pkg_dirs_list, pkg_libs_list): - flags = [ - "%s-rpath,%s" % (xlinker, dir) for dir in pkg_dirs_list if not is_sys_lib_path(dir) - ] - flags += ["-L%s" % dir for dir in pkg_dirs_list if not is_sys_lib_path(dir)] - flags += ["-l%s" % lib for lib in pkg_libs_list] - return " ".join(flags) + # from within MFEM. We use the following two functions to do that. + ld_flags_from_library_list = self.ld_flags_from_library_list + ld_flags_from_dirs = self.ld_flags_from_dirs def find_optional_library(name, prefix): for shared in [True, False]: @@ -619,6 +620,8 @@ def find_optional_library(name, prefix): "MFEM_USE_EXCEPTIONS=%s" % yes_no("+exceptions"), "MFEM_USE_MUMPS=%s" % yes_no("+mumps"), ] + if spec.satisfies("@4.7.0:"): + options += ["MFEM_PRECISION=%s" % spec.variants["precision"].value] # Determine C++ standard to use: cxxstd = None @@ -632,6 +635,11 @@ def find_optional_library(name, prefix): cxxstd = "14" if self.spec.satisfies("^ginkgo"): cxxstd = "14" + cxxstd_req = spec.variants["cxxstd"].value + if cxxstd_req != "auto": + # Constraints for valid standard level should be imposed during + # concretization based on 'conflicts' or other directives. + cxxstd = cxxstd_req cxxstd_flag = None if cxxstd: if "+cuda" in spec: @@ -639,6 +647,8 @@ def find_optional_library(name, prefix): else: cxxstd_flag = getattr(self.compiler, "cxx" + cxxstd + "_flag") + cuda_arch = None if "~cuda" in spec else spec.variants["cuda_arch"].value + cxxflags = spec.compiler_flags["cxxflags"].copy() if cxxflags: @@ -944,7 +954,6 @@ def find_optional_library(name, prefix): options += ["HIP_CXX=%s" % spec["hip"].hipcc, "HIP_ARCH=%s" % amdgpu_target] hip_headers = HeaderList([]) hip_libs = LibraryList([]) - hip_libs += find_libraries("libamdhip64", spec["hip"].prefix.lib) # To use a C++ compiler that supports -xhip flag one can use # something like this: # options += [ @@ -972,9 +981,27 @@ def find_optional_library(name, prefix): hip_headers += spec["hipblas"].headers if "%cce" in spec: # We assume the proper Cray CCE module (cce) is loaded: - craylibs_path = env["CRAYLIBS_" + machine().upper()] - craylibs = ["libmodules", "libfi", "libcraymath", "libf", "libu", "libcsup"] + proc = str(spec.target.family) + craylibs_var = "CRAYLIBS_" + proc.upper() + craylibs_path = env.get(craylibs_var, None) + if not craylibs_path: + raise InstallError( + f"The environment variable {craylibs_var} is not defined.\n" + "\tMake sure the 'cce' module is in the compiler spec." + ) + craylibs = [ + "libmodules", + "libfi", + "libcraymath", + "libf", + "libu", + "libcsup", + "libpgas-shmem", + ] hip_libs += find_libraries(craylibs, craylibs_path) + craylibs_path2 = join_path(craylibs_path, "../../../cce-clang", proc, "lib") + hip_libs += find_libraries("libunwind", craylibs_path2) + if hip_headers: options += ["HIP_OPT=%s" % hip_headers.cpp_flags] if hip_libs: @@ -1018,9 +1045,17 @@ def find_optional_library(name, prefix): ] if "+umpire" in spec: + umpire = spec["umpire"] + umpire_opts = umpire.headers + umpire_libs = umpire.libs + if "^camp" in umpire: + umpire_opts += umpire["camp"].headers + if "^fmt" in umpire: + umpire_opts += umpire["fmt"].headers + umpire_libs += umpire["fmt"].libs options += [ - "UMPIRE_OPT=-I%s" % spec["umpire"].prefix.include, - "UMPIRE_LIB=%s" % ld_flags_from_library_list(spec["umpire"].libs), + "UMPIRE_OPT=%s" % umpire_opts.cpp_flags, + "UMPIRE_LIB=%s" % ld_flags_from_library_list(umpire_libs), ] timer_ids = {"std": "0", "posix": "2", "mac": "4", "mpi": "6"} @@ -1089,7 +1124,7 @@ def find_optional_library(name, prefix): hiop_libs = hiop.libs hiop_hdrs += spec["lapack"].headers + spec["blas"].headers hiop_libs += spec["lapack"].libs + spec["blas"].libs - hiop_opt_libs = ["magma", "umpire"] + hiop_opt_libs = ["magma", "umpire", "hipblas", "hiprand"] for opt_lib in hiop_opt_libs: if "^" + opt_lib in hiop: hiop_hdrs += hiop[opt_lib].headers @@ -1105,6 +1140,8 @@ def find_optional_library(name, prefix): camp = raja["camp"] hiop_hdrs += camp.headers hiop_libs += find_optional_library("libcamp", camp.prefix) + if hiop.satisfies("@0.6:+cuda"): + hiop_libs += LibraryList(["cublas", "curand"]) options += [ "HIOP_OPT=%s" % hiop_hdrs.cpp_flags, "HIOP_LIB=%s" % ld_flags_from_library_list(hiop_libs), @@ -1121,6 +1158,10 @@ def find_optional_library(name, prefix): "MUMPS_LIB=%s" % ld_flags_from_library_list(mumps.libs), ] + return options + + def configure(self, spec, prefix): + options = self.get_make_config_options(spec, prefix) make("config", *options, parallel=False) make("info", parallel=False) @@ -1281,3 +1322,46 @@ def test_mk(self): if os.access(f, os.R_OK): return FileList(f) return FileList(find(self.prefix, "test.mk", recursive=True)) + + # See also find_system_libraries in lib/spack/llnl/util/filesystem.py + # where the similar list of paths is used. + sys_lib_paths = [ + "/lib64", + "/lib", + "/usr/lib64", + "/usr/lib", + "/usr/local/lib64", + "/usr/local/lib", + "/usr/lib/x86_64-linux-gnu", + ] + + def is_sys_lib_path(self, dir): + return dir in self.sys_lib_paths + + @property + def xlinker(self): + return "-Wl," if "~cuda" in self.spec else "-Xlinker=" + + # Similar to spec[pkg].libs.ld_flags but prepends rpath flags too. + # Also does not add system library paths as defined by 'sys_lib_paths' + # above -- this is done to avoid issues like this: + # https://github.com/mfem/mfem/issues/1088. + def ld_flags_from_library_list(self, libs_list): + flags = [ + "%s-rpath,%s" % (self.xlinker, dir) + for dir in libs_list.directories + if not self.is_sys_lib_path(dir) + ] + flags += ["-L%s" % dir for dir in libs_list.directories if not self.is_sys_lib_path(dir)] + flags += [libs_list.link_flags] + return " ".join(flags) + + def ld_flags_from_dirs(self, pkg_dirs_list, pkg_libs_list): + flags = [ + "%s-rpath,%s" % (self.xlinker, dir) + for dir in pkg_dirs_list + if not self.is_sys_lib_path(dir) + ] + flags += ["-L%s" % dir for dir in pkg_dirs_list if not self.is_sys_lib_path(dir)] + flags += ["-l%s" % lib for lib in pkg_libs_list] + return " ".join(flags) diff --git a/var/spack/repos/builtin/packages/mfem/test_builds.sh b/var/spack/repos/builtin/packages/mfem/test_builds.sh index cb658dd59cc468..be0d27bc0f93b8 100755 --- a/var/spack/repos/builtin/packages/mfem/test_builds.sh +++ b/var/spack/repos/builtin/packages/mfem/test_builds.sh @@ -14,9 +14,9 @@ rocm_arch="gfx908" spack_jobs='' # spack_jobs='-j 128' -mfem='mfem@4.6.0'${compiler} +mfem='mfem@4.7.0'${compiler} # mfem_dev='mfem@develop'${compiler} -mfem_dev='mfem@4.6.0'${compiler} +mfem_dev='mfem@4.7.0'${compiler} backends='+occa+raja+libceed' backends_specs='^occa~cuda ^raja~openmp' @@ -31,44 +31,60 @@ petsc_spec_rocm='^petsc+rocm+mumps' strumpack_spec='^strumpack~slate~openmp~cuda' strumpack_cuda_spec='^strumpack+cuda~slate~openmp' strumpack_rocm_spec='^strumpack+rocm~slate~openmp~cuda' -# superlu specs with cuda and rocm -superlu_cuda_spec='^superlu-dist+cuda' -superlu_rocm_spec='^superlu-dist+rocm' +# superlu specs with cpu, cuda and rocm +# - v8.2.1 on CPU and GPU stalls in ex11p; works when superlu::PARMETIS is +# replaced with superlu::METIS_AT_PLUS_A, at least on CPU +superlu_spec='^superlu-dist@8.1.2' +superlu_cuda_spec='^superlu-dist@8.1.2+cuda' +superlu_rocm_spec='^superlu-dist@8.1.2+rocm' +# FMS spec +fms_spec='^libfms+conduit' builds=( # preferred version: ${mfem} ${mfem}'~mpi~metis~zlib' - ${mfem}"$backends"'+superlu-dist+strumpack+suite-sparse+petsc+slepc+gslib \ - +sundials+pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo+hiop \ - '"$backends_specs $strumpack_spec $petsc_spec $conduit_spec" + # TODO: add back "+fms $fms_spec" when the FMS unit test is fixed + ${mfem}"$backends"'+superlu-dist+strumpack+mumps+suite-sparse+petsc+slepc \ + +gslib+sundials+pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo \ + +hiop \ + '"$backends_specs $superlu_spec $strumpack_spec $petsc_spec"' \ + '"$conduit_spec" + # TODO: add back "+fms $fms_spec" when the FMS unit test is fixed ${mfem}'~mpi \ '"$backends"'+suite-sparse+sundials+gslib+mpfr+netcdf \ +zlib+gnutls+libunwind+conduit+ginkgo+hiop \ '"$backends_specs $conduit_spec"' ^sundials~mpi' + ${mfem}' precision=single +mumps+petsc '"$petsc_spec" # develop version, shared builds: ${mfem_dev}'+shared~static' ${mfem_dev}'+shared~static~mpi~metis~zlib' # NOTE: Shared build with +gslib works on mac but not on linux # TODO: add back '+gslib' when the above NOTE is addressed. + # TODO: add back "+fms $fms_spec" when the FMS unit test is fixed ${mfem_dev}'+shared~static \ - '"$backends"'+superlu-dist+strumpack+suite-sparse+petsc+slepc \ + '"$backends"'+superlu-dist+strumpack+mumps+suite-sparse+petsc+slepc \ +sundials+pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo+hiop \ - '"$backends_specs $strumpack_spec $petsc_spec $conduit_spec" + '"$backends_specs $superlu_spec $strumpack_spec $petsc_spec"' \ + '"$conduit_spec" # NOTE: Shared build with +gslib works on mac but not on linux # TODO: add back '+gslib' when the above NOTE is addressed. + # TODO: add back "+fms $fms_spec" when the FMS unit test is fixed ${mfem_dev}'+shared~static~mpi \ '"$backends"'+suite-sparse+sundials+mpfr+netcdf \ +zlib+gnutls+libunwind+conduit+ginkgo+hiop \ '"$backends_specs $conduit_spec"' ^sundials~mpi' + ${mfem_dev}'+shared~static precision=single +mumps+petsc '"$petsc_spec" ) builds2=( # preferred version ${mfem}"$backends $backends_specs" - ${mfem}'+superlu-dist' + ${mfem}' precision=single' + ${mfem}'+superlu-dist'" $superlu_spec" ${mfem}'+strumpack'" $strumpack_spec" + ${mfem}'+mumps' ${mfem}'+suite-sparse~mpi' ${mfem}'+suite-sparse' ${mfem}'+sundials~mpi ^sundials~mpi' @@ -81,6 +97,8 @@ builds2=( ${mfem}'+gnutls' ${mfem}'+conduit~mpi'" $conduit_spec" ${mfem}'+conduit'" $conduit_spec" + # TODO: uncomment next line when the FMS unit test is fixed + # ${mfem}'+fms'" $fms_spec" ${mfem}'+umpire' ${mfem}'+petsc'" $petsc_spec" ${mfem}'+petsc+slepc'" $petsc_spec" @@ -93,8 +111,10 @@ builds2=( # # develop version ${mfem_dev}"$backends $backends_specs" - ${mfem_dev}'+superlu-dist' + ${mfem_dev}' precision=single' + ${mfem_dev}'+superlu-dist'" $superlu_spec" ${mfem_dev}'+strumpack'" $strumpack_spec" + ${mfem_dev}'+mumps' ${mfem_dev}'+suite-sparse~mpi' ${mfem_dev}'+suite-sparse' ${mfem_dev}'+sundials~mpi ^sundials~mpi' @@ -107,6 +127,8 @@ builds2=( ${mfem_dev}'+gnutls' ${mfem_dev}'+conduit~mpi'" $conduit_spec" ${mfem_dev}'+conduit'" $conduit_spec" + # TODO: uncomment next line when the FMS unit test is fixed + # ${mfem_dev}'+fms'" $fms_spec" ${mfem_dev}'+umpire' ${mfem_dev}'+petsc'" $petsc_spec" ${mfem_dev}'+petsc+slepc'" $petsc_spec" @@ -134,25 +156,37 @@ builds_cuda=( # hypre without cuda: # NOTE: PETSc tests may need PETSC_OPTIONS="-use_gpu_aware_mpi 0" # TODO: restore '+libceed' when the libCEED CUDA unit tests take less time. - # TODO: remove "^hiop+shared" when the default static build is fixed. ${mfem}'+cuda+openmp+raja+occa cuda_arch='"${cuda_arch}"' \ +superlu-dist+strumpack+suite-sparse+gslib+petsc+slepc \ - +sundials+pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo+hiop \ - ^raja+cuda+openmp ^hiop+shared'" $strumpack_cuda_spec"' \ + +sundials+pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo \ + ^raja+cuda+openmp'" $strumpack_cuda_spec"' \ '"$superlu_cuda_spec $petsc_spec_cuda $conduit_spec" + ${mfem}'+cuda cuda_arch='"${cuda_arch}"' +raja+umpire' + + # hiop needs older versions of raja, umpire, etc + # TODO: combine this spec with the above spec when the combined spec works. + ${mfem}'+cuda cuda_arch='"${cuda_arch}"' +hiop' + # hypre with cuda: # TODO: restore '+libceed' when the libCEED CUDA unit tests take less time. # TODO: add back "+petsc+slepc $petsc_spec_cuda" when it works. # NOTE: PETSc tests may need PETSC_OPTIONS="-use_gpu_aware_mpi 0" # TODO: add back "+sundials" when it's supported with '^hypre+cuda'. - # TODO: remove "^hiop+shared" when the default static build is fixed. ${mfem}'+cuda+openmp+raja+occa cuda_arch='"${cuda_arch}"' \ +superlu-dist+strumpack+suite-sparse+gslib \ - +pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo+hiop \ - ^raja+cuda+openmp ^hiop+shared ^hypre+cuda \ + +pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo \ + ^raja+cuda+openmp ^hypre+cuda \ '" $strumpack_cuda_spec $superlu_cuda_spec $conduit_spec" + ${mfem}'+cuda cuda_arch='"${cuda_arch}"' +raja+umpire ^hypre+cuda' + + # hiop needs older versions of raja, umpire, etc + # TODO: combine this spec with the above spec when the combined spec works. + ${mfem}'+cuda cuda_arch='"${cuda_arch}"' +hiop ^hypre+cuda' + + ${mfem}' precision=single +cuda cuda_arch='"${cuda_arch}"' ^hypre+cuda' + # # same builds as above with ${mfem_dev} # @@ -171,24 +205,36 @@ builds_cuda=( # hypre without cuda: # NOTE: PETSc tests may need PETSC_OPTIONS="-use_gpu_aware_mpi 0" # TODO: restore '+libceed' when the libCEED CUDA unit tests take less time. - # TODO: remove "^hiop+shared" when the default static build is fixed. ${mfem_dev}'+cuda+openmp+raja+occa cuda_arch='"${cuda_arch}"' \ +superlu-dist+strumpack+suite-sparse+gslib+petsc+slepc \ - +sundials+pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo+hiop \ - ^raja+cuda+openmp ^hiop+shared'" $strumpack_cuda_spec"' \ + +sundials+pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo \ + ^raja+cuda+openmp'" $strumpack_cuda_spec"' \ '"$superlu_cuda_spec $petsc_spec_cuda $conduit_spec" + ${mfem_dev}'+cuda cuda_arch='"${cuda_arch}"' +raja+umpire' + + # hiop needs older versions of raja, umpire, etc + # TODO: combine this spec with the above spec when the combined spec works. + ${mfem_dev}'+cuda cuda_arch='"${cuda_arch}"' +hiop' + # hypre with cuda: # TODO: restore '+libceed' when the libCEED CUDA unit tests take less time. # TODO: add back "+petsc+slepc $petsc_spec_cuda" when it works. # NOTE: PETSc tests may need PETSC_OPTIONS="-use_gpu_aware_mpi 0" # TODO: add back "+sundials" when it's supported with '^hypre+cuda'. - # TODO: remove "^hiop+shared" when the default static build is fixed. ${mfem_dev}'+cuda+openmp+raja+occa cuda_arch='"${cuda_arch}"' \ +superlu-dist+strumpack+suite-sparse+gslib \ - +pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo+hiop \ - ^raja+cuda+openmp ^hiop+shared ^hypre+cuda \ + +pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo \ + ^raja+cuda+openmp ^hypre+cuda \ '"$strumpack_cuda_spec $superlu_cuda_spec $conduit_spec" + + ${mfem_dev}'+cuda cuda_arch='"${cuda_arch}"' +raja+umpire ^hypre+cuda' + + # hiop needs older versions of raja, umpire, etc + # TODO: combine this spec with the above spec when the combined spec works. + ${mfem_dev}'+cuda cuda_arch='"${cuda_arch}"' +hiop ^hypre+cuda' + + ${mfem_dev}' precision=single +cuda cuda_arch='"${cuda_arch}"' ^hypre+cuda' ) @@ -204,27 +250,35 @@ builds_rocm=( ^raja+rocm~openmp ^occa~cuda~openmp ^hypre+rocm' # hypre without rocm: - # TODO: add back '+hiop' when it is no longer linked with tcmalloc* through - # its magma dependency. - # TODO: add back '+ginkgo' when the Ginkgo example works. ${mfem}'+rocm+openmp+raja+occa+libceed amdgpu_target='"${rocm_arch}"' \ +superlu-dist+strumpack+suite-sparse+gslib+petsc+slepc \ - +sundials+pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit \ + +sundials+pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo \ ^raja+rocm~openmp ^occa~cuda'" $strumpack_rocm_spec"' \ '"$superlu_rocm_spec $petsc_spec_rocm $conduit_spec" + ${mfem}'+rocm amdgpu_target='"${rocm_arch}"' +raja+umpire' + + # hiop needs older versions of raja, umpire, etc + # TODO: combine this spec with the above spec when the combined spec works. + ${mfem}'+rocm amdgpu_target='"${rocm_arch}"' +hiop' + # hypre with rocm: # TODO: add back "+petsc+slepc $petsc_spec_rocm" when it works. - # TODO: add back '+hiop' when it is no longer linked with tcmalloc* through - # its magma dependency. - # TODO: add back '+ginkgo' when the Ginkgo example works. # TODO: add back "+sundials" when it's supported with '^hypre+rocm'. ${mfem}'+rocm+openmp+raja+occa+libceed amdgpu_target='"${rocm_arch}"' \ +superlu-dist+strumpack+suite-sparse+gslib \ - +pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit \ + +pumi+mpfr+netcdf+zlib+gnutls+libunwind+conduit+ginkgo \ ^raja+rocm~openmp ^occa~cuda ^hypre+rocm \ '"$strumpack_rocm_spec $superlu_rocm_spec $conduit_spec" + ${mfem}'+rocm amdgpu_target='"${rocm_arch}"' +raja+umpire ^hypre+rocm' + + # hiop needs older versions of raja, umpire, etc + # TODO: combine this spec with the above spec when the combined spec works. + ${mfem}'+rocm amdgpu_target='"${rocm_arch}"' +hiop ^hypre+rocm' + + ${mfem}' precision=single +rocm amdgpu_target='"${rocm_arch}"' ^hypre+rocm' + # # same builds as above with ${mfem_dev} # @@ -244,6 +298,8 @@ run_builds=("${builds[@]}" "${builds2[@]}") # PETSc CUDA tests on Lassen need this: # export PETSC_OPTIONS="-use_gpu_aware_mpi 0" +# STRUMPACK forces "^openblas threads=openmp" when using openblas: +export OMP_NUM_THREADS=1 # spack files to clean in "$mfem_src_dir" when using 'dev-build' clean_files=( diff --git a/var/spack/repos/builtin/packages/mg/package.py b/var/spack/repos/builtin/packages/mg/package.py index 81097f0a16f6e0..6a1c68807f08a9 100644 --- a/var/spack/repos/builtin/packages/mg/package.py +++ b/var/spack/repos/builtin/packages/mg/package.py @@ -18,6 +18,8 @@ class Mg(MakefilePackage): version("6.6", sha256="e8440353da1a52ec7d40fb88d4f145da49c320b5ba31daf895b0b0db5ccd0632") + depends_on("c", type="build") # generated + depends_on("ncurses") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/mgard/package.py b/var/spack/repos/builtin/packages/mgard/package.py index c3abc1a5cfd93e..d4ffaca07f9a1e 100644 --- a/var/spack/repos/builtin/packages/mgard/package.py +++ b/var/spack/repos/builtin/packages/mgard/package.py @@ -29,6 +29,8 @@ class Mgard(CMakePackage, CudaPackage): version("2021-11-12", commit="3c05c80a45a51bb6cc5fb5fffe7b1b16787d3366") version("2020-10-01", commit="b67a0ac963587f190e106cc3c0b30773a9455f7a") + depends_on("cxx", type="build") # generated + variant( "serial", when="@2022-11-18:", @@ -47,6 +49,7 @@ class Mgard(CMakePackage, CudaPackage): depends_on("python", type=("build",), when="@2022-11-18:") depends_on("sed", type=("build",), when="@2022-11-18:") depends_on("zlib-api") + depends_on("zlib@1.2.9:", when="^[virtuals=zlib-api] zlib") # crc32_z depends_on("pkgconfig", type=("build",), when="@2022-11-18:") depends_on("zstd") depends_on("protobuf@3.4:", when="@2022-11-18:") diff --git a/var/spack/repos/builtin/packages/mgardx/package.py b/var/spack/repos/builtin/packages/mgardx/package.py index ecbe45b209b4e4..8a105d123d6b89 100644 --- a/var/spack/repos/builtin/packages/mgardx/package.py +++ b/var/spack/repos/builtin/packages/mgardx/package.py @@ -23,6 +23,9 @@ class Mgardx(CMakePackage): version("2022-01-27", commit="aabe9de1a331eaeb8eec41125dd45e30c1d03af4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("sz-cpp") depends_on("pkgconfig") depends_on("zstd") diff --git a/var/spack/repos/builtin/packages/mgcfd-op2/package.py b/var/spack/repos/builtin/packages/mgcfd-op2/package.py index 8ad20e6dd2fa24..bec689e0cff69a 100644 --- a/var/spack/repos/builtin/packages/mgcfd-op2/package.py +++ b/var/spack/repos/builtin/packages/mgcfd-op2/package.py @@ -23,6 +23,9 @@ class MgcfdOp2(MakefilePackage): version("v1.0.0-rc1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Enable MPI support") depends_on("gmake@4.3:") @@ -54,11 +57,6 @@ def edit(self, spec, prefix): makefile.filter(r"CPP := clang", r"CPP := armclang") makefile.filter(r"-cxx=clang.*", "") - # Cray systems require use of 'cc' and 'CC' to call correct mpi wrappers - if self.spec.platform == "cray": - makefile.filter("mpicc", "cc") - makefile.filter("mpicxx", "CC") - if self.spec.compiler.name == "nvhpc": makefile.filter("pgc", "nvc") diff --git a/var/spack/repos/builtin/packages/mgis/package.py b/var/spack/repos/builtin/packages/mgis/package.py index a4dcb003bb5090..3ed05d7db37501 100644 --- a/var/spack/repos/builtin/packages/mgis/package.py +++ b/var/spack/repos/builtin/packages/mgis/package.py @@ -48,6 +48,10 @@ class Mgis(CMakePackage): version("1.0.1", sha256="6102621455bc5d9b1591cd33e93b2e15a9572d2ce59ca6dfa30ba57ae1265c08") version("1.0", sha256="279c98da00fa6855edf29c2b8f8bad6e7732298dc62ef67d028d6bbeaac043b3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # variants variant("c", default=True, description="Enables c bindings") variant("fortran", default=True, description="Enables fortran bindings") diff --git a/var/spack/repos/builtin/packages/microbiomeutil/package.py b/var/spack/repos/builtin/packages/microbiomeutil/package.py index 5bc771a1fbee2f..67aa13b1938df7 100644 --- a/var/spack/repos/builtin/packages/microbiomeutil/package.py +++ b/var/spack/repos/builtin/packages/microbiomeutil/package.py @@ -14,6 +14,8 @@ class Microbiomeutil(MakefilePackage, SourceforgePackage): version("20110519", sha256="9233de80ea57bfb9e9371cbe7e3bfad2d4a51168fddaf60fa144c4046c80d823") + depends_on("c", type="build") # generated + depends_on("perl", type=("build", "run")) depends_on("blast-plus") depends_on("cdbfasta") diff --git a/var/spack/repos/builtin/packages/micromamba/package.py b/var/spack/repos/builtin/packages/micromamba/package.py index 0effbe21e579d6..a157413c036d4a 100644 --- a/var/spack/repos/builtin/packages/micromamba/package.py +++ b/var/spack/repos/builtin/packages/micromamba/package.py @@ -28,6 +28,8 @@ class Micromamba(CMakePackage): version("1.4.2", sha256="dce034908d02d991c5e9aadeb9d01f139d027ba199aaeb1d47d543e3f24895d1") version("1.1.0", sha256="e2392cd90221234ae8ea92b37f40829fbe36d80278056269aa1994a5efe7f530") + depends_on("cxx", type="build") # generated + variant( "linkage", default="dynamic", diff --git a/var/spack/repos/builtin/packages/microsocks/package.py b/var/spack/repos/builtin/packages/microsocks/package.py index cad5b337d0e39a..86c0c0de877b55 100644 --- a/var/spack/repos/builtin/packages/microsocks/package.py +++ b/var/spack/repos/builtin/packages/microsocks/package.py @@ -23,6 +23,8 @@ class Microsocks(MakefilePackage): version("develop", branch="master") version("1.0.2", sha256="5ece77c283e71f73b9530da46302fdb4f72a0ae139aa734c07fe532407a6211a") + depends_on("c", type="build") # generated + def flag_handler(self, name, flags): if name == "cflags": flags.append(self.compiler.c99_flag) diff --git a/var/spack/repos/builtin/packages/migraphx/0002-restrict-python-2.7-usage.patch b/var/spack/repos/builtin/packages/migraphx/0002-restrict-python-2.7-usage.patch deleted file mode 100644 index 8cb736a9b5c6cb..00000000000000 --- a/var/spack/repos/builtin/packages/migraphx/0002-restrict-python-2.7-usage.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/cmake/PythonModules.cmake b/cmake/PythonModules.cmake -index 96727cc..51a970c 100755 ---- a/cmake/PythonModules.cmake -+++ b/cmake/PythonModules.cmake -@@ -53,7 +53,7 @@ function(py_add_module NAME) - ) - - endfunction() --set(PYTHON_SEARCH_VERSIONS 2.7 3.5 3.6 3.7 3.8 3.9) -+set(PYTHON_SEARCH_VERSIONS 3.5 3.6 3.7 3.8 3.9) - - set(_PYTHON_VERSIONS) - foreach(PYTHON_VERSION ${PYTHON_SEARCH_VERSIONS}) diff --git a/var/spack/repos/builtin/packages/migraphx/package.py b/var/spack/repos/builtin/packages/migraphx/package.py index c3a1ecf2607c78..cc18ab89e523ca 100644 --- a/var/spack/repos/builtin/packages/migraphx/package.py +++ b/var/spack/repos/builtin/packages/migraphx/package.py @@ -13,13 +13,16 @@ class Migraphx(CMakePackage): homepage = "https://github.com/ROCm/AMDMIGraphX" git = "https://github.com/ROCm/AMDMIGraphX.git" - url = "https://github.com/ROCm/AMDMIGraphX/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/AMDMIGraphX/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") libraries = ["libmigraphx"] license("MIT") + version("6.1.2", sha256="829f4a2bd9fe3dee130dfcca103ddc7691da18382f5b683aaca8f3ceceaef355") + version("6.1.1", sha256="e14a62678e97356236b45921e24f28ff430d670fb70456c3e5ebfeeb22160811") + version("6.1.0", sha256="2ba44146397624845c64f3898bb1b08837ad7a49f133329e58eb04c05d1f36ac") version("6.0.2", sha256="13f393f8fdf25275994dda07091a93eec867233cd2f99f9cb0df16fbabd53483") version("6.0.0", sha256="7bb3f5011da9b1f3b79707b06118c523c1259215f650c2ffa5622a7e1d88868f") version("5.7.1", sha256="3e58c043a5a7d1357ee05725fd6cd41e190b070f1ba57f61300128429902089c") @@ -28,21 +31,18 @@ class Migraphx(CMakePackage): version("5.6.0", sha256="eaec90535d62002fd5bb264677ad4a7e30c55f18d2a287680d0495c7e60432b2") version("5.5.1", sha256="e71c4744f8ef6a1a99c179bbad94b8fe9bd7686eaa9397f376b70988c3341f0c") version("5.5.0", sha256="6084eb596b170f5e38f22b5fa37e66aa43a8cbc626712c9f03cde48c8fecfc8f") - version("5.4.3", sha256="f83e7bbe5d6d0951fb2cf0abf7e8b3530e9a5e45f7cec6d760da055d6905d568") - version("5.4.0", sha256="b6e7f4a1bf445ea0dae644ed5722369cde66fbee82a5917722f5d3f8c48b0a8c") - version("5.3.3", sha256="91d91902bbedd5e1951a231e8e5c9a328360b128c731912ed17c8059df38e02a") - version("5.3.0", sha256="d0b7283f42e03fb38b612868b8c94f46f27a6e0b019ae95fde5b9086582a1c69") with default_args(deprecated=True): - version("5.2.3", sha256="03f7d49f2efdd2c7a6afcaa5a5db5103edc15047b0ff5e146a775cfb36b36af2") - version("5.2.1", sha256="300d990e1b92ad27c3eba3e94ef34538730ca9556398b8b9f7d61d28bf66c57d") - version("5.2.0", sha256="33afcdf52c6e0e3a2f939fcf30e87f712b8e8ef3633a3dc03a19fea359704925") - version("5.1.3", sha256="686e068774500a46b6e6488370bbf5bd0bba6d19ecdb00636f951704d19c9ef2") - version("5.1.0", sha256="6398efaef18a74f2a475aa21bd34bc7c077332a430ee3f6ba4fde6e6a6aa9f89") + version("5.4.3", sha256="f83e7bbe5d6d0951fb2cf0abf7e8b3530e9a5e45f7cec6d760da055d6905d568") + version("5.4.0", sha256="b6e7f4a1bf445ea0dae644ed5722369cde66fbee82a5917722f5d3f8c48b0a8c") + version("5.3.3", sha256="91d91902bbedd5e1951a231e8e5c9a328360b128c731912ed17c8059df38e02a") + version("5.3.0", sha256="d0b7283f42e03fb38b612868b8c94f46f27a6e0b019ae95fde5b9086582a1c69") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated patch("0001-Adding-nlohmann-json-include-directory.patch", when="@:5.5") # Restrict Python 2.7 usage to fix the issue below # https://github.com/spack/spack/issues/24429 - patch("0002-restrict-python-2.7-usage.patch", when="@:5.1") patch("0003-restrict-python-2.7-usage.patch", when="@5.2.0:5.4") patch("0004-restrict-python2.7-usage-for-5.5.0.patch", when="@5.5.0") patch("0005-Adding-half-include-directory-path-migraphx.patch", when="@5.6.0:5.7") @@ -50,13 +50,13 @@ class Migraphx(CMakePackage): patch( "https://github.com/ROCm/AMDMIGraphX/commit/728bea3489c97c9e1ddda0a0ae527ffd2d70cb97.patch?full_index=1", sha256="3a8afd32208aa4f59fb31f898d243287771ebd409c7af7a4a785c586081e3711", - when="@6.0:", + when="@6.0", ) patch( "https://github.com/ROCm/AMDMIGraphX/commit/624f8ef549522f64fdddad7f49a2afe1890b0b79.patch?full_index=1", sha256="410d0fd49f5f65089cd4f540c530c85896708b4fd94c67d15c2c279158aea85d", - when="@6.0:", + when="@6.0", ) patch("0003-add-half-include-directory-migraphx-6.0.patch", when="@6.0:") @@ -73,11 +73,6 @@ class Migraphx(CMakePackage): depends_on("abseil-cpp") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -90,6 +85,9 @@ class Migraphx(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") depends_on(f"hip@{ver}", when=f"@{ver}") @@ -97,7 +95,7 @@ class Migraphx(CMakePackage): depends_on(f"rocblas@{ver}", when=f"@{ver}") depends_on(f"miopen-hip@{ver}", when=f"@{ver}") - for ver in ["6.0.0", "6.0.2"]: + for ver in ["6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: depends_on(f"rocmlir@{ver}", when=f"@{ver}") @property diff --git a/var/spack/repos/builtin/packages/migrate/package.py b/var/spack/repos/builtin/packages/migrate/package.py index 33b408fb49aee5..67c52b80fd177c 100644 --- a/var/spack/repos/builtin/packages/migrate/package.py +++ b/var/spack/repos/builtin/packages/migrate/package.py @@ -18,6 +18,9 @@ class Migrate(AutotoolsPackage): version("3.6.11", sha256="a9ba06a4e995a45b8d04037f5f2da23e1fe64a2f3565189bdd50c62c6fe01fb8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Build MPI binaries") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/mii/package.py b/var/spack/repos/builtin/packages/mii/package.py index c0f24d8bb27dc6..45ef8531e09163 100644 --- a/var/spack/repos/builtin/packages/mii/package.py +++ b/var/spack/repos/builtin/packages/mii/package.py @@ -23,5 +23,7 @@ class Mii(MakefilePackage): version("1.1.2", sha256="bdf2cfe93b2b0989cd47f1447e8787d8339440295299c0a70d2646e2c02e29b8") version("1.0.4", sha256="3c4e7e6e8c21969da8dade05fecab35be61f2bb82d75eeaf19db8cc97f8058b5") + depends_on("c", type="build") # generated + def setup_build_environment(self, env): env.set("PREFIX", self.prefix) diff --git a/var/spack/repos/builtin/packages/millepede/package.py b/var/spack/repos/builtin/packages/millepede/package.py index 65edd50b89cebe..31d21b9463cf37 100644 --- a/var/spack/repos/builtin/packages/millepede/package.py +++ b/var/spack/repos/builtin/packages/millepede/package.py @@ -21,6 +21,10 @@ class Millepede(MakefilePackage): version("04-13-03", sha256="669a6e46a6f02ba3c78b2760e2ffb2c90d25b582ccd1a5c0770eef81c7bcbbe9") version("04-11-01", sha256="9869eb84d8d07cecfab15c396f3faa36aef10906e39f8641c48b58e0325b3205") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/mimalloc/package.py b/var/spack/repos/builtin/packages/mimalloc/package.py index 53eefe6b4de68a..7d5cd800622ff5 100644 --- a/var/spack/repos/builtin/packages/mimalloc/package.py +++ b/var/spack/repos/builtin/packages/mimalloc/package.py @@ -32,6 +32,9 @@ class Mimalloc(CMakePackage): version("1.7.7", sha256="0f6663be1e1764851bf9563fcf7a6b3330e23b933eb4737dd07e3289b87895fe") version("1.7.6", sha256="d74f86ada2329016068bc5a243268f1f555edd620b6a7d6ce89295e7d6cf18da") + depends_on("c", type="build") + depends_on("cxx", type="build") + depends_on("cmake@3.0:", type="build") libs_values = ("shared", "static", "object") diff --git a/var/spack/repos/builtin/packages/minc-toolkit/package.py b/var/spack/repos/builtin/packages/minc-toolkit/package.py index 9739b7f4c317c7..3241b7175a91cf 100644 --- a/var/spack/repos/builtin/packages/minc-toolkit/package.py +++ b/var/spack/repos/builtin/packages/minc-toolkit/package.py @@ -17,6 +17,9 @@ class MincToolkit(CMakePackage): version("1.9.18.2", commit="b98e4972bdac2b78e3c1e412d75c97e2e7c5f6b9", submodules=True) version("1.9.18.1", commit="38597c464b6e93eda680ab4a9e903366d53d7737", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant( "visualisation", default=False, description="Build visual tools (Display, register, etc.)" diff --git a/var/spack/repos/builtin/packages/mindthegap/package.py b/var/spack/repos/builtin/packages/mindthegap/package.py index af37a739045a59..2ff1e7a1d5d8ba 100644 --- a/var/spack/repos/builtin/packages/mindthegap/package.py +++ b/var/spack/repos/builtin/packages/mindthegap/package.py @@ -25,6 +25,9 @@ class Mindthegap(CMakePackage): "2.0.2", tag="v2.0.2", commit="8401af2a2bce9997396fbf0a04757ca7c887a1da", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build", when="@2.3.0") depends_on("cmake@2.6:", type="build", when="@2.0.2") diff --git a/var/spack/repos/builtin/packages/miniaero/package.py b/var/spack/repos/builtin/packages/miniaero/package.py index 138d0a1b077a70..724cf9561fe9c2 100644 --- a/var/spack/repos/builtin/packages/miniaero/package.py +++ b/var/spack/repos/builtin/packages/miniaero/package.py @@ -19,6 +19,8 @@ class Miniaero(MakefilePackage): version("2016-11-11", commit="f46d135479a5be19ec5d146ccaf0e581aeff4596") + depends_on("cxx", type="build") # generated + depends_on("kokkos-legacy") @property diff --git a/var/spack/repos/builtin/packages/miniamr/package.py b/var/spack/repos/builtin/packages/miniamr/package.py index 166ba379c09b7a..78bcce5084f297 100644 --- a/var/spack/repos/builtin/packages/miniamr/package.py +++ b/var/spack/repos/builtin/packages/miniamr/package.py @@ -21,6 +21,7 @@ class Miniamr(MakefilePackage): license("LGPL-3.0-only") version("master", branch="master") + version("1.7.0", sha256="f11aee04bc59f46c6894a07d365c9c3006c58739ac6abd2d9663843c01a8b62b") version("1.6.6", sha256="a7f79fae49e433ef8350cbd34cbf57c486089cf7ac0d1f1f3b23c820d3e5bb9f") version("1.6.5", sha256="c70f0f648c73ea4497817ceee158334eeb901fc5c32cf804deef3226cd9cf26a") version("1.6.4", sha256="807d50608b69fb1a61924718964be96c0a2f9fa2e37fdc027bc3f0f116544732") @@ -30,13 +31,15 @@ class Miniamr(MakefilePackage): version("1.4.1", sha256="dd8e8d9fd0768cb4f2c5d7fe6989dfa6bb95a8461f04deaccdbb50b0dd51e97a") version("1.4.0", sha256="f0b959c90416288c5ab51ed86b6ba49bc8a319006c2a74a070c94133267edc6f") + depends_on("c", type="build") # generated + depends_on("mpi") @property def build_targets(self): targets = [] - targets.append("CC={0}".format(self.spec["mpi"].mpicc)) - targets.append("LD={0}".format(self.spec["mpi"].mpicc)) + targets.append(f"CC={self.spec['mpi'].mpicc}") + targets.append(f"LD={self.spec['mpi'].mpicc}") targets.append("LDLIBS=-lm") targets.append("--directory=ref") diff --git a/var/spack/repos/builtin/packages/miniasm/package.py b/var/spack/repos/builtin/packages/miniasm/package.py index 2a908fc0b237cc..3aff8f964d7ab4 100644 --- a/var/spack/repos/builtin/packages/miniasm/package.py +++ b/var/spack/repos/builtin/packages/miniasm/package.py @@ -17,6 +17,8 @@ class Miniasm(MakefilePackage): version("2018-3-30", commit="55cf0189e2f7d5bda5868396cebe066eec0a9547") + depends_on("c", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/miniconda3/package.py b/var/spack/repos/builtin/packages/miniconda3/package.py index 7d5596e4d10c85..c28bf4be9cf751 100644 --- a/var/spack/repos/builtin/packages/miniconda3/package.py +++ b/var/spack/repos/builtin/packages/miniconda3/package.py @@ -10,6 +10,60 @@ from spack.util.environment import EnvironmentModifications _versions = { + "24.3.0": { + "Linux-x86_64": ( + "96a44849ff17e960eeb8877ecd9055246381c4d4f2d031263b63fa7e2e930af1", + "https://repo.anaconda.com/miniconda/Miniconda3-py312_24.3.0-0-Linux-x86_64.sh", + ) + }, + "24.1.2": { + "Linux-x86_64": ( + "b978856ec3c826eb495b60e3fffe621f670c101150ebcbdeede4f961f22dc438", + "https://repo.anaconda.com/miniconda/Miniconda3-py312_24.1.2-0-Linux-x86_64.sh", + ) + }, + "23.11.0": { + "Linux-x86_64": ( + "c9ae82568e9665b1105117b4b1e499607d2a920f0aea6f94410e417a0eff1b9c", + "https://repo.anaconda.com/miniconda/Miniconda3-py311_23.11.0-2-Linux-x86_64.sh", + ) + }, + "23.9.0": { + "Linux-x86_64": ( + "43651393236cb8bb4219dcd429b3803a60f318e5507d8d84ca00dafa0c69f1bb", + "https://repo.anaconda.com/miniconda/Miniconda3-py311_23.9.0-0-Linux-x86_64.sh", + ) + }, + "23.5.2": { + "Linux-x86_64": ( + "634d76df5e489c44ade4085552b97bebc786d49245ed1a830022b0b406de5817", + "https://repo.anaconda.com/miniconda/Miniconda3-py311_23.5.2-0-Linux-x86_64.sh", + ) + }, + "23.5.1": { + "Linux-x86_64": ( + "333779c9cae3fe14735949a8dcb9657b9e55ada69e9c60f191c5d582b2deac20", + "https://repo.anaconda.com/miniconda/Miniconda3-py311_23.5.1-0-Linux-x86_64.sh", + ) + }, + "23.5.0": { + "Linux-x86_64": ( + "61a5c087893f6210176045931b89ee6e8760c17abd9c862b2cab4c1b7d00f7c8", + "https://repo.anaconda.com/miniconda/Miniconda3-py311_23.5.0-3-Linux-x86_64.sh", + ) + }, + "23.3.1": { + "Linux-x86_64": ( + "aef279d6baea7f67940f16aad17ebe5f6aac97487c7c03466ff01f4819e5a651", + "https://repo.anaconda.com/miniconda/Miniconda3-py310_23.3.1-0-Linux-x86_64.sh", + ) + }, + "23.1.0": { + "Linux-x86_64": ( + "32d73e1bc33fda089d7cd9ef4c1be542616bd8e437d1f77afeeaf7afdb019787", + "https://repo.anaconda.com/miniconda/Miniconda3-py310_23.1.0-1-Linux-x86_64.sh", + ) + }, "22.11.1": { "Linux-x86_64": ( "00938c3534750a0e4069499baf8f4e6dc1c2e471c86a59caa0dd03f4a9269db6", diff --git a/var/spack/repos/builtin/packages/minife/package.py b/var/spack/repos/builtin/packages/minife/package.py index beb587c7c7973a..25cec0c808891f 100644 --- a/var/spack/repos/builtin/packages/minife/package.py +++ b/var/spack/repos/builtin/packages/minife/package.py @@ -20,6 +20,9 @@ class Minife(MakefilePackage): version("2.1.0", sha256="59f4c56d73d2a758cba86939db2d36e12705282cb4174ce78223d984527f5d15") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "build", default="ref", diff --git a/var/spack/repos/builtin/packages/miniforge3/package.py b/var/spack/repos/builtin/packages/miniforge3/package.py index d1b22e4f9ee4ba..f690742acafb48 100644 --- a/var/spack/repos/builtin/packages/miniforge3/package.py +++ b/var/spack/repos/builtin/packages/miniforge3/package.py @@ -3,50 +3,63 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import platform +from os.path import split + from spack.package import * +from spack.util.environment import EnvironmentModifications + +_versions = { + "24.3.0-0": { + "Linux-x86_64": ("23367676b610de826f50f7ddc91139a816d4b59bd4c69cc9b6082d9b2e7fe8a3",) + }, + "24.1.2-0": { + "Linux-x86_64": ("dbadb808edf4da00af35d888d3eeebbfdce71972b60bf4b16dbacaee2ab57f28",) + }, + "4.8.3-4": { + "Linux-x86_64": ("24951262a126582f5f2e1cf82c9cd0fa20e936ef3309fdb8397175f29e647646",), + "Linux-aarch64": ("52a8dde14ecfb633800a2de26543a78315058e30f5883701da1ad2f2d5ba9ed8",), + }, + "4.8.3-2": { + "Linux-x86_64": ("c8e5b894fe91ce0f86e61065d2247346af107f8d53de0ad89ec848701c4ec1f9",), + "Linux-aarch64": ("bfefc0ede6354568978b4198607edd7f17c2f50ca4c6a47e9f22f8c257c8230a",), + "MacOSX-x86_64": ("25ca082ab00a776db356f9bbc660edf6d24659e2aec1cbec5fd4ce992d4d193d"), + }, +} class Miniforge3(Package): - """Miniforge3 is a minimal installer for conda specific to conda-forge.""" + """Miniforge3 is a minimal installer for conda and mamba specific to conda-forge.""" homepage = "https://github.com/conda-forge/miniforge" - url = "https://github.com/conda-forge/miniforge/releases/download/4.8.3-2/Miniforge3-4.8.3-2-Linux-x86_64.sh" - - version( - "4.8.3-4-Linux-x86_64", - url="https://github.com/conda-forge/miniforge/releases/download/4.8.3-4/Miniforge3-4.8.3-4-Linux-x86_64.sh", - sha256="24951262a126582f5f2e1cf82c9cd0fa20e936ef3309fdb8397175f29e647646", - expand=False, - ) - version( - "4.8.3-4-Linux-aarch64", - url="https://github.com/conda-forge/miniforge/releases/download/4.8.3-4/Miniforge3-4.8.3-4-Linux-aarch64.sh", - sha256="52a8dde14ecfb633800a2de26543a78315058e30f5883701da1ad2f2d5ba9ed8", - expand=False, - ) - version( - "4.8.3-2-Linux-x86_64", - url="https://github.com/conda-forge/miniforge/releases/download/4.8.3-2/Miniforge3-4.8.3-2-Linux-x86_64.sh", - sha256="c8e5b894fe91ce0f86e61065d2247346af107f8d53de0ad89ec848701c4ec1f9", - expand=False, - ) - version( - "4.8.3-2-Linux-aarch64", - url="https://github.com/conda-forge/miniforge/releases/download/4.8.3-2/Miniforge3-4.8.3-2-Linux-aarch64.sh", - sha256="bfefc0ede6354568978b4198607edd7f17c2f50ca4c6a47e9f22f8c257c8230a", - expand=False, - ) - version( - "4.8.3-2-MacOSX-x86_64", - url="https://github.com/conda-forge/miniforge/releases/download/4.8.3-2/Miniforge3-4.8.3-2-MacOSX-x86_64.sh", - sha256="25ca082ab00a776db356f9bbc660edf6d24659e2aec1cbec5fd4ce992d4d193d", - expand=False, - ) + + maintainers("ChristopherChristofi") + + license("BSD-3-Clause") + + for ver, packages in _versions.items(): + key = f"{platform.system()}-{platform.machine()}" + pkg = packages.get(key) + if pkg: + version(ver, sha256=pkg[0], expand=False) + + variant("mamba", default=True, description="Enable mamba support.") + + conflicts("+mamba", when="@:22.3.1-0") + + def url_for_version(self, version): + script = f"Miniforge3-{version}-{platform.system()}-{platform.machine()}.sh" + return f"https://github.com/conda-forge/miniforge/releases/download/{version}/{script}" def install(self, spec, prefix): - mkdirp(prefix) - pkgname = "Miniforge3-{0}.sh".format(self.version) - chmod = which("chmod") - chmod("+x", pkgname) - sh = which("sh") - sh("./{0}".format(pkgname), "-b", "-f", "-s", "-p", prefix) + dir, script = split(self.stage.archive_file) + bash = which("bash") + bash(script, "-b", "-f", "-p", self.prefix) + + def setup_run_environment(self, env): + filename = self.prefix.etc.join("profile.d").join("conda.sh") + env.extend(EnvironmentModifications.from_sourcing_file(filename)) + + if "+mamba" in self.spec: + filename = self.prefix.etc.join("profile.d").join("mamba.sh") + env.extend(EnvironmentModifications.from_sourcing_file(filename)) diff --git a/var/spack/repos/builtin/packages/minigmg/package.py b/var/spack/repos/builtin/packages/minigmg/package.py index 4a5e4605f7a3bd..f29580c9c721d5 100644 --- a/var/spack/repos/builtin/packages/minigmg/package.py +++ b/var/spack/repos/builtin/packages/minigmg/package.py @@ -31,6 +31,8 @@ class Minigmg(Package): version("master", sha256="1c2d27496a881f655f5e849d6a7a132625e535739f82575991c511cc2cf899ac") + depends_on("c", type="build") # generated + variant( "vec", default="ompif", diff --git a/var/spack/repos/builtin/packages/minimap2/package.py b/var/spack/repos/builtin/packages/minimap2/package.py index 04de083fe3a362..142ef71fa46144 100644 --- a/var/spack/repos/builtin/packages/minimap2/package.py +++ b/var/spack/repos/builtin/packages/minimap2/package.py @@ -15,8 +15,11 @@ class Minimap2(PythonPackage): url = "https://github.com/lh3/minimap2/releases/download/v2.2/minimap2-2.2.tar.bz2" git = "https://github.com/lh3/minimap2.git" + maintainers("snehring") + license("MIT") + version("2.28", sha256="ffa5712735d229119f8c05722a0638ae0cc15aeb8938e29a3e52d5da5c92a0b4") version("2.26", sha256="6a588efbd273bff4f4808d5190957c50272833d2daeb4407ccf4c1b78143624c") version("2.24", sha256="9dd4c31ff082182948944bcdad6d328f64f09295d10547d72eba24189880a615") version("2.17", sha256="b68ac8882d33cc63e9e3246775062aeb159b6990ff7f38099172c3fe6f8a2742") @@ -24,6 +27,8 @@ class Minimap2(PythonPackage): version("2.10", sha256="52b36f726ec00bfca4a2ffc23036d1a2b5f96f0aae5a92fd826be6680c481c20") version("2.2", sha256="7e8683aa74c4454a8cfe3821f405c4439082e24c152b4b834fdb56a117ecaed9") + depends_on("c", type="build") # generated + conflicts("target=aarch64:", when="@:2.10") depends_on("zlib-api", type="link") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/miniqmc/package.py b/var/spack/repos/builtin/packages/miniqmc/package.py index 7c827dc9d8fba0..1f2d287575f858 100644 --- a/var/spack/repos/builtin/packages/miniqmc/package.py +++ b/var/spack/repos/builtin/packages/miniqmc/package.py @@ -18,6 +18,8 @@ class Miniqmc(CMakePackage): version("0.3.0", sha256="3ba494ba1055df91e157cb426d1fbe4192aa3f04b019277d9e571d057664d5a9") version("0.2.0", sha256="cdf6fc6df6ccc1e034c62f937c040bfd6a4e65a0974b95f6884edd004ae36ee4") + depends_on("cxx", type="build") # generated + tags = ["proxy-app", "ecp-proxy-app"] depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/minisign/package.py b/var/spack/repos/builtin/packages/minisign/package.py index 666c31ec293a92..386c3ba62ac9e3 100644 --- a/var/spack/repos/builtin/packages/minisign/package.py +++ b/var/spack/repos/builtin/packages/minisign/package.py @@ -20,6 +20,8 @@ class Minisign(CMakePackage): version("0.8", sha256="130eb5246076bc7ec42f13495a601382e566bb6733430d40a68de5e43a7f1082") version("0.7", sha256="0c9f25ae647b6ba38cf7e6aea1da4e8fb20e1bc64ef0c679da737a38c8ad43ef") + depends_on("c", type="build") # generated + variant("static", default=True, description="builds a static version of the executable") depends_on("libsodium") diff --git a/var/spack/repos/builtin/packages/minismac2d/package.py b/var/spack/repos/builtin/packages/minismac2d/package.py index f5161f669b76ac..7aaf40a1d6162c 100644 --- a/var/spack/repos/builtin/packages/minismac2d/package.py +++ b/var/spack/repos/builtin/packages/minismac2d/package.py @@ -20,6 +20,8 @@ class Minismac2d(MakefilePackage): version("2.0", sha256="ec01b74c06a2c0386efbbb61b14305327342a08fb92bf52e76f60a2063adf065") + depends_on("fortran", type="build") # generated + depends_on("mpi") parallel = False diff --git a/var/spack/repos/builtin/packages/minitri/package.py b/var/spack/repos/builtin/packages/minitri/package.py index 0cf2ecc393b572..09ee7ea8aa2604 100644 --- a/var/spack/repos/builtin/packages/minitri/package.py +++ b/var/spack/repos/builtin/packages/minitri/package.py @@ -14,6 +14,8 @@ class Minitri(MakefilePackage): version("1.0", sha256="e340dbb04b7c182804ebf6f5a946a392f1c68b7f798885c091c3f0d8aaa844ce") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Build with MPI support") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin/packages/minivite/package.py b/var/spack/repos/builtin/packages/minivite/package.py index 44c77e051dc9e8..2ae2c1722aab85 100644 --- a/var/spack/repos/builtin/packages/minivite/package.py +++ b/var/spack/repos/builtin/packages/minivite/package.py @@ -22,6 +22,8 @@ class Minivite(MakefilePackage): version("1.0", tag="v1.0", commit="65ccaa8a4ec0b4bea516e2abdafbeb2f8a5f0c94") version("1.1", tag="v1.1", commit="23476d9d41eb8a17bf4108ac56852dacda89b253") + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Build with OpenMP support") variant("opt", default=True, description="Optimization flags") diff --git a/var/spack/repos/builtin/packages/minixyce/package.py b/var/spack/repos/builtin/packages/minixyce/package.py index 71cb49a9795352..de20e532a08d88 100644 --- a/var/spack/repos/builtin/packages/minixyce/package.py +++ b/var/spack/repos/builtin/packages/minixyce/package.py @@ -19,6 +19,8 @@ class Minixyce(MakefilePackage): version("1.0", sha256="40e3b4ed5c65cb1d210e828460e99b755cac922a7e27e70c687d5bb6ed19a21b") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Build with MPI Support") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin/packages/minizip/package.py b/var/spack/repos/builtin/packages/minizip/package.py index d88a5e046b51d3..55aa8c2cea1925 100644 --- a/var/spack/repos/builtin/packages/minizip/package.py +++ b/var/spack/repos/builtin/packages/minizip/package.py @@ -16,6 +16,9 @@ class Minizip(AutotoolsPackage): version("1.2.11", sha256="c3e5e9fdd5004dcb542feda5ee4f0ff0744628baf8ed2dd5d66f8ca1197cb1a1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + configure_directory = "contrib/minizip" depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/miopen-hip/0002-add-include-dir-miopen-hip-6.1.0.patch b/var/spack/repos/builtin/packages/miopen-hip/0002-add-include-dir-miopen-hip-6.1.0.patch new file mode 100644 index 00000000000000..44e68e401c1cea --- /dev/null +++ b/var/spack/repos/builtin/packages/miopen-hip/0002-add-include-dir-miopen-hip-6.1.0.patch @@ -0,0 +1,35 @@ +From 1693afd9690b97fcceff09ffce765712e3c7361a Mon Sep 17 00:00:00 2001 +From: Renjith Ravindran +Date: Mon, 29 Apr 2024 08:01:47 +0000 +Subject: [PATCH] Adding roctracer-dev include and library path + +--- + src/CMakeLists.txt | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index 0741a60..84b6805 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -739,6 +739,9 @@ if(WIN32) + endif() + + target_include_directories(MIOpen SYSTEM PUBLIC $) ++target_include_directories(MIOpen SYSTEM PUBLIC "${NLOHMANN_JSON_INCLUDE}") ++target_include_directories(MIOpen SYSTEM PUBLIC "${ROCTRACER_INCLUDE_DIR}") ++target_include_directories(MIOpen SYSTEM PUBLIC "${SQLITE_INCLUDE_DIR}") + # Workaround : change in rocm-cmake was causing linking error so had to add ${CMAKE_DL_LIBS} + # We can remove ${CMAKE_DL_LIBS} once root cause is identified. + target_link_libraries(MIOpen PRIVATE ${CMAKE_DL_LIBS} Threads::Threads BZip2::BZip2 ${MIOPEN_CK_LINK_FLAGS}) +@@ -861,7 +864,7 @@ if(NOT WIN32 AND NOT APPLE) + endif() + + if(MIOPEN_USE_ROCTRACER) +- target_link_libraries(MIOpen PRIVATE roctx64) ++ target_link_libraries(MIOpen PRIVATE "${ROCTRACER_LIB_DIR}/libroctx64.so") + endif() + + ############################################################ +-- +2.31.1 + diff --git a/var/spack/repos/builtin/packages/miopen-hip/package.py b/var/spack/repos/builtin/packages/miopen-hip/package.py index 6f998676683bd0..b1ad016e9f61b7 100644 --- a/var/spack/repos/builtin/packages/miopen-hip/package.py +++ b/var/spack/repos/builtin/packages/miopen-hip/package.py @@ -14,13 +14,16 @@ class MiopenHip(CMakePackage): homepage = "https://github.com/ROCm/MIOpen" git = "https://github.com/ROCm/MIOpen.git" - url = "https://github.com/ROCm/MIOpen/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/MIOpen/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") libraries = ["libMIOpen"] license("MIT") + version("6.1.2", sha256="c8ff4af72264b2049bfe2685d581ea0f3e43319db7bd00dc347159bcf2731614") + version("6.1.1", sha256="cf568ea16dd23b32fe89e250bb33ed4722fea8aa7f407cc66ff37c37aab037ce") + version("6.1.0", sha256="3b373117eaeaf618aab9b39bb22e9950fd49bd0e264c8587b0c51fa348afe0d1") version("6.0.2", sha256="e6f671bd6af59f7470f42cda2ff9e77441d8f6c2105772bbf855d31da1085ffa") version("6.0.0", sha256="a0718a48353be30ff98118ade511f0c1b454e394d8f934aefe7dd6946562b2e9") version("5.7.1", sha256="912a658fe21ce6f1982b0f2ff251c3f7bb618f2e7e9876d983bcb54e3cd7129e") @@ -29,16 +32,13 @@ class MiopenHip(CMakePackage): version("5.6.0", sha256="d620ddab5b488bdf81242654fefa337c6b71dc410c2ff26d30a4ee86a8d22d11") version("5.5.1", sha256="2cd75071b8ee876c69a94f028b6c8a9346d6d2fde7d4b64e6d635f3b6c994262") version("5.5.0", sha256="791087242551669e546225e36123c21663f0dad14dbcfd6d0ce0e7bad0ab0de1") - version("5.4.3", sha256="37ffe2ed3d7942da8ea2f6bdb85c7a2f58e3ccd31767db158a322769d3604efd") - version("5.4.0", sha256="b4153791f9eeee4cbc5534bc6ad8b32c0947bcd38e08b77ebe144065a4fa5456") - version("5.3.3", sha256="7efc98215d23a2caaf212378c37e9a6484f54a4ed3e9660719286e4f287d3715") - version("5.3.0", sha256="c5819f593d71beeda2eb24b89182912240cc40f83b2b8f9de695a8e230aa4ea6") with default_args(deprecated=True): - version("5.2.3", sha256="28747847446955b3bab24f7fc65c1a6b863a12f12ad3a35e0312072482d38122") - version("5.2.1", sha256="0977a8876d41bbd2fa268341c93892f35878d7efc1711194ad87582f877ff500") - version("5.2.0", sha256="5fda69426e81df9f8fb6658e579176b9c4fcce3516fc8488d3cfd2b6f6f2b3b4") - version("5.1.3", sha256="510461f5c5bdbcf8dc889099d1e5960b9f84bd845a9fc9154588a9898c701c1d") - version("5.1.0", sha256="bb50201334d68addf153b84b88ab803027c4913d71bdbda6f5ccde3f672f6fdd") + version("5.4.3", sha256="37ffe2ed3d7942da8ea2f6bdb85c7a2f58e3ccd31767db158a322769d3604efd") + version("5.4.0", sha256="b4153791f9eeee4cbc5534bc6ad8b32c0947bcd38e08b77ebe144065a4fa5456") + version("5.3.3", sha256="7efc98215d23a2caaf212378c37e9a6484f54a4ed3e9660719286e4f287d3715") + version("5.3.0", sha256="c5819f593d71beeda2eb24b89182912240cc40f83b2b8f9de695a8e230aa4ea6") + + depends_on("cxx", type="build") # generated depends_on("cmake@3.5:", type="build") depends_on("pkgconfig", type="build") @@ -55,18 +55,14 @@ class MiopenHip(CMakePackage): patch("miopen-hip-include-nlohmann-include-directory.patch", when="@5.4.0:5.7") patch("0002-add-include-dir-miopen-hip-6.0.0.patch", when="@6.0") + patch("0002-add-include-dir-miopen-hip-6.1.0.patch", when="@6.1") patch( - "https://github.com/ROCm/MIOpen/pull/2276/commits/f60aa1ff89f8fb596b4a6a4c70aa7d557803db87.patch?full_index=1", - sha256="c777d9f4cd2bbfec632b38620c0f70bb0cce8da1", + "https://github.com/ROCm/MIOpen/commit/f60aa1ff89f8fb596b4a6a4c70aa7d557803db87.patch?full_index=1", + sha256="7f382c872d89f22da1ad499e85ffe9881cc7404c8465e42877a210a09382e2ea", when="@5.7", ) for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -79,23 +75,39 @@ class MiopenHip(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"rocm-clang-ocl@{ver}", when=f"@{ver}") depends_on(f"rocblas@{ver}", when=f"@{ver}") - for ver in ["5.1.0", "5.1.3", "5.2.0", "5.2.1", "5.2.3", "5.3.0", "5.3.3"]: + for ver in ["5.3.0", "5.3.3"]: depends_on(f"mlirmiopen@{ver}", when=f"@{ver}") - for ver in ["5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on("nlohmann-json", type="link") depends_on(f"composable-kernel@{ver}", when=f"@{ver}") for ver in ["5.4.0", "5.4.3", "5.5.0"]: depends_on("nlohmann-json", type="link") depends_on(f"rocmlir@{ver}", when=f"@{ver}") - for ver in ["6.0.0", "6.0.2"]: + for ver in ["6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: depends_on("roctracer-dev@" + ver, when="@" + ver) + for ver in ["6.1.0", "6.1.1", "6.1.2"]: + depends_on("googletest") def setup_build_environment(self, env): lib_dir = self.spec["zlib-api"].libs.directories[0] @@ -155,4 +167,6 @@ def cmake_args(self): "-DROCTRACER_INCLUDE_DIR={0}".format(self.spec["roctracer-dev"].prefix.include) ) args.append("-DROCTRACER_LIB_DIR={0}".format(self.spec["roctracer-dev"].prefix.lib)) + if self.spec.satisfies("@6.1:"): + args.append("-DSQLITE_INCLUDE_DIR={0}".format(self.spec["sqlite"].prefix.include)) return args diff --git a/var/spack/repos/builtin/packages/miopen-opencl/package.py b/var/spack/repos/builtin/packages/miopen-opencl/package.py index 34e4de3569f9ac..b9b5da9e53edab 100644 --- a/var/spack/repos/builtin/packages/miopen-opencl/package.py +++ b/var/spack/repos/builtin/packages/miopen-opencl/package.py @@ -24,16 +24,13 @@ class MiopenOpencl(CMakePackage): version("5.5.1", sha256="2cd75071b8ee876c69a94f028b6c8a9346d6d2fde7d4b64e6d635f3b6c994262") version("5.5.0", sha256="791087242551669e546225e36123c21663f0dad14dbcfd6d0ce0e7bad0ab0de1") - version("5.4.3", sha256="37ffe2ed3d7942da8ea2f6bdb85c7a2f58e3ccd31767db158a322769d3604efd") - version("5.4.0", sha256="b4153791f9eeee4cbc5534bc6ad8b32c0947bcd38e08b77ebe144065a4fa5456") - version("5.3.3", sha256="7efc98215d23a2caaf212378c37e9a6484f54a4ed3e9660719286e4f287d3715") - version("5.3.0", sha256="c5819f593d71beeda2eb24b89182912240cc40f83b2b8f9de695a8e230aa4ea6") with default_args(deprecated=True): - version("5.2.3", sha256="28747847446955b3bab24f7fc65c1a6b863a12f12ad3a35e0312072482d38122") - version("5.2.1", sha256="0977a8876d41bbd2fa268341c93892f35878d7efc1711194ad87582f877ff500") - version("5.2.0", sha256="5fda69426e81df9f8fb6658e579176b9c4fcce3516fc8488d3cfd2b6f6f2b3b4") - version("5.1.3", sha256="510461f5c5bdbcf8dc889099d1e5960b9f84bd845a9fc9154588a9898c701c1d") - version("5.1.0", sha256="bb50201334d68addf153b84b88ab803027c4913d71bdbda6f5ccde3f672f6fdd") + version("5.4.3", sha256="37ffe2ed3d7942da8ea2f6bdb85c7a2f58e3ccd31767db158a322769d3604efd") + version("5.4.0", sha256="b4153791f9eeee4cbc5534bc6ad8b32c0947bcd38e08b77ebe144065a4fa5456") + version("5.3.3", sha256="7efc98215d23a2caaf212378c37e9a6484f54a4ed3e9660719286e4f287d3715") + version("5.3.0", sha256="c5819f593d71beeda2eb24b89182912240cc40f83b2b8f9de695a8e230aa4ea6") + + depends_on("cxx", type="build") # generated depends_on("cmake@3.5:", type="build") depends_on("boost@1.67.0:1.73.0", type="link") @@ -47,23 +44,12 @@ class MiopenOpencl(CMakePackage): depends_on("sqlite", type="link") depends_on("half", type="build") - for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.3", - "5.3.0", - "5.3.3", - "5.4.0", - "5.4.3", - "5.5.0", - "5.5.1", - ]: + for ver in ["5.3.0", "5.3.3", "5.4.0", "5.4.3", "5.5.0", "5.5.1"]: depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") depends_on(f"rocm-opencl@{ver}", when=f"@{ver}") depends_on(f"miopengemm@{ver}", when=f"@{ver}") - for ver in ["5.1.0", "5.1.3", "5.2.0", "5.2.1", "5.2.3", "5.3.0", "5.3.3"]: + for ver in ["5.3.0", "5.3.3"]: depends_on(f"mlirmiopen@{ver}", when=f"@{ver}") for ver in ["5.4.0", "5.4.3", "5.5.0", "5.5.1"]: diff --git a/var/spack/repos/builtin/packages/miopen-tensile/package.py b/var/spack/repos/builtin/packages/miopen-tensile/package.py deleted file mode 100644 index c0e9d78ab7e267..00000000000000 --- a/var/spack/repos/builtin/packages/miopen-tensile/package.py +++ /dev/null @@ -1,91 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - -import re - -from spack.package import * - - -class MiopenTensile(CMakePackage): - """MIOpenTensile provides host-callable interfaces to Tensile library. - MIOpenTensile supports one programming model: HIP""" - - homepage = "https://github.com/ROCm/MIOpenTensile" - git = "https://github.com/ROCm/MIOpenTensile.git" - url = "https://github.com/ROCm/MIOpentensile/archive/rocm-5.0.0.tar.gz" - tags = ["rocm"] - - maintainers("srekolam") - libraries = ["libMIOpenTensile"] - - version("5.1.0", sha256="f1ae57bd4df8c154357b3f17caf0cfd5f80ba16ffff67bf6219a56f1eb5f897d") - - tensile_architecture = ("all", "gfx906", "gfx908", "gfx803", "gfx900") - - variant( - "tensile_architecture", - default="all", - description="AMD GPU architecture", - values=tensile_architecture, - multi=True, - ) - variant( - "build_type", - default="Release", - values=("Release", "Debug", "RelWithDebInfo"), - description="CMake build type", - ) - - patch("0002-Improve-compilation-by-using-local-tensile-path.patch", when="@4.5.0:") - - depends_on("cmake@3.5:", type="build") - depends_on("msgpack-c@3:") - depends_on("python@3.6:", type="build") - depends_on("py-virtualenv", type="build") - depends_on("perl-file-which", type="build") - depends_on("py-pyyaml", type="build") - depends_on("py-wheel", type="build") - depends_on("py-msgpack", type="build") - depends_on("py-pip", type="build") - - resource( - name="Tensile", - git="https://github.com/ROCm/Tensile.git", - commit="9cbabb07f81e932b9c98bf5ae48fbd7fcef615cf", - ) - - for ver in ["5.1.0"]: - depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") - depends_on(f"hip@{ver}", when=f"@{ver}") - depends_on(f"llvm-amdgpu@{ver}", when=f"@{ver}") - depends_on(f"rocminfo@{ver}", when=f"@{ver}") - - def setup_build_environment(self, env): - env.set("CXX", self.spec["hip"].hipcc) - - @classmethod - def determine_version(cls, lib): - match = re.search(r"lib\S*\.so\.\d+\.\d+\.(\d)(\d\d)(\d\d)", lib) - if match: - return "{0}.{1}.{2}".format( - int(match.group(1)), int(match.group(2)), int(match.group(3)) - ) - return None - - def cmake_args(self): - arch = self.spec.variants["tensile_architecture"].value - tensile_path = join_path(self.stage.source_path, "Tensile") - args = [ - self.define("TENSILE_USE_MSGPACK", "ON"), - self.define("COMPILER", "hipcc"), - self.define("TENSILE_USE_LLVM", "OFF"), - self.define("CODE_OBJECT_VERSION", "V3"), - self.define("TENSILE_LIBRARY_FORMAT", "msgpack"), - self.define("MIOPEN_TENSILE_SRC", "asm_full"), - self.define("Tensile_TEST_LOCAL_PATH", tensile_path), - ] - args.append(self.define("Tensile_ARCHITECTURE", arch)) - - return args diff --git a/var/spack/repos/builtin/packages/miopengemm/package.py b/var/spack/repos/builtin/packages/miopengemm/package.py index 112d8a749587d4..89e7399cbc7005 100644 --- a/var/spack/repos/builtin/packages/miopengemm/package.py +++ b/var/spack/repos/builtin/packages/miopengemm/package.py @@ -30,32 +30,22 @@ def url_for_version(self, version): version("5.5.1", sha256="a997b560521641e7173613cf547ecde5d15ac6fac1786d392b0f133c91f99a40") version("5.5.0", sha256="ffd9775129564662b338952588057a088f7e9723b4a9a766b2dd96fdc0992c26") - version("5.4.3", sha256="5051051cab60ca0f6347a981da6c9dbeddf8b0de698d4e5409a0db0c622acafc") - version("5.4.0", sha256="a39faa8f4ab73e0cd6505a667bf10c07f93b9612af0711405c65043c4755129d") - version("5.3.3", sha256="4a9c92bebe59bf6e08bd48861b68b1801d9e8dc406250dc8637d36614a5884c8") - version("5.3.0", sha256="7e299daaca8e514bdb5b5efd9d9d3fc5cbfda68ad0117fe7cdbbf946b3f842cd") with default_args(deprecated=True): + version("5.4.3", sha256="5051051cab60ca0f6347a981da6c9dbeddf8b0de698d4e5409a0db0c622acafc") + version("5.4.0", sha256="a39faa8f4ab73e0cd6505a667bf10c07f93b9612af0711405c65043c4755129d") + version("5.3.3", sha256="4a9c92bebe59bf6e08bd48861b68b1801d9e8dc406250dc8637d36614a5884c8") + version("5.3.0", sha256="7e299daaca8e514bdb5b5efd9d9d3fc5cbfda68ad0117fe7cdbbf946b3f842cd") version("5.2.3", sha256="de9eecf39e6620be1511923e990101e64c63c2f56d8491c8bf9ffd1033709c00") version("5.2.1", sha256="9cea190ee0a6645b6d3ce3e136a8e7d07cf4044e98014ccc82b5e5f8b468b1c1") version("5.2.0", sha256="10458fb07b56a7fbe165595d588b7bf5f1300c57bda2f3133c3687c7bae39ea8") version("5.1.3", sha256="c70fc9e2a6d47356a612e24f5757bf16fdf26e671bd53a0975c1a0978da740b6") version("5.1.0", sha256="e2b20cdc20a745bcb7a554852e6b4bd39274c7dcc13fc19a81a282fb4dfa475f") + depends_on("cxx", type="build") # generated + depends_on("cmake@3:", type="build") - for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", - "5.3.0", - "5.3.3", - "5.4.0", - "5.4.3", - "5.5.0", - "5.5.1", - ]: + for ver in ["5.3.0", "5.3.3", "5.4.0", "5.4.3", "5.5.0", "5.5.1"]: depends_on(f"rocm-cmake@{ver}", type="build", when=f"@{ver}") depends_on(f"rocm-opencl@{ver}", when=f"@{ver}") diff --git a/var/spack/repos/builtin/packages/mira/package.py b/var/spack/repos/builtin/packages/mira/package.py index 7c0cd23874bcc0..005a7a4a16691e 100644 --- a/var/spack/repos/builtin/packages/mira/package.py +++ b/var/spack/repos/builtin/packages/mira/package.py @@ -18,6 +18,8 @@ class Mira(AutotoolsPackage): version("4.0.2", sha256="a32cb2b21e0968a5536446287c895fe9e03d11d78957554e355c1080b7b92a80") + depends_on("cxx", type="build") # generated + depends_on("boost@1.46:") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/mitos/package.py b/var/spack/repos/builtin/packages/mitos/package.py index b9c12d9e5ff14d..8090d9ec8d1214 100644 --- a/var/spack/repos/builtin/packages/mitos/package.py +++ b/var/spack/repos/builtin/packages/mitos/package.py @@ -19,6 +19,8 @@ class Mitos(CMakePackage): version("0.9.2", commit="8cb143a2e8c00353ff531a781a9ca0992b0aaa3d") version("0.9.1", sha256="67abe227d2f9b4d2f235031b526d3ceb2c4792ad98772b1b1d5af0d227a795fc") + depends_on("cxx", type="build") # generated + depends_on("dyninst@8.2.1:") depends_on("hwloc") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/mivisionx/0002-add-half-include-path-for-tests-6.1.0.patch b/var/spack/repos/builtin/packages/mivisionx/0002-add-half-include-path-for-tests-6.1.0.patch new file mode 100644 index 00000000000000..80bbdff605c0ec --- /dev/null +++ b/var/spack/repos/builtin/packages/mivisionx/0002-add-half-include-path-for-tests-6.1.0.patch @@ -0,0 +1,86 @@ +From 19f084566394c6556cacf1b812a9a64e1fe0610e Mon Sep 17 00:00:00 2001 +From: Renjith Ravindran +Date: Wed, 12 Jun 2024 23:33:53 +0000 +Subject: [PATCH] add half include path for tests in 6.1 + +--- + model_compiler/python/nnir_to_clib.py | 4 ++++ + samples/mv_objdetect/CMakeLists.txt | 6 +++++- + utilities/rocAL/rocAL_unittests/CMakeLists.txt | 3 ++- + utilities/rocAL/rocAL_video_unittests/CMakeLists.txt | 3 ++- + 4 files changed, 13 insertions(+), 3 deletions(-) + +diff --git a/model_compiler/python/nnir_to_clib.py b/model_compiler/python/nnir_to_clib.py +index 623bf43..544ed31 100644 +--- a/model_compiler/python/nnir_to_clib.py ++++ b/model_compiler/python/nnir_to_clib.py +@@ -160,6 +160,10 @@ if (OPENVX_BACKEND_OPENCL_FOUND) + include_directories (${OpenCL_INCLUDE_DIRS} ${OpenCL_INCLUDE_DIRS}/Headers ) + endif() + ++find_path(HALF_INCLUDE_DIR half.hpp) ++message(STATUS "HALF_INCLUDE_DIR: ${HALF_INCLUDE_DIR}") ++include_directories(${HALF_INCLUDE_DIR}) ++ + find_package(OpenCV QUIET) + include_directories (${ROCM_PATH}/include ${ROCM_PATH}/include/mivisionx) + include_directories (${PROJECT_SOURCE_DIR}/lib) +diff --git a/samples/mv_objdetect/CMakeLists.txt b/samples/mv_objdetect/CMakeLists.txt +index 54d527b..c334ae4 100644 +--- a/samples/mv_objdetect/CMakeLists.txt ++++ b/samples/mv_objdetect/CMakeLists.txt +@@ -29,6 +29,7 @@ project (mvobjdetect) + set (CMAKE_CXX_STANDARD 14) + + list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake) ++find_path(HALF_INCLUDE_DIR half.hpp) + find_package(OpenCV QUIET) + + set(ROCM_PATH /opt/rocm CACHE PATH "ROCm Installation Path") +@@ -50,7 +51,10 @@ if (OPENVX_BACKEND_OPENCL_FOUND) + include_directories (${OpenCL_INCLUDE_DIRS} ${OpenCL_INCLUDE_DIRS}/Headers ) + endif() + +-include_directories (${ROCM_PATH}/include ${ROCM_PATH}/include/mivisionx ${PROJECT_SOURCE_DIR} ) ++find_path(HALF_INCLUDE_DIR half.hpp) ++message(STATUS "HALF_INCLUDE_DIR: ${HALF_INCLUDE_DIR}") ++ ++include_directories (${ROCM_PATH}/include/mivisionx ${PROJECT_SOURCE_DIR} ${HALF_INCLUDE_DIR} ) + link_directories (${ROCM_PATH}/lib ${PROJECT_SOURCE_DIR}/lib) + option (USE_POSTPROC "Use postprocessing module implementation" ON) + set(SOURCES mvobjdetect.cpp mvdeploy_api.cpp visualize.cpp) +diff --git a/utilities/rocAL/rocAL_unittests/CMakeLists.txt b/utilities/rocAL/rocAL_unittests/CMakeLists.txt +index ba90dce..f3f2df9 100644 +--- a/utilities/rocAL/rocAL_unittests/CMakeLists.txt ++++ b/utilities/rocAL/rocAL_unittests/CMakeLists.txt +@@ -43,11 +43,12 @@ include(GNUInstallDirs) + + list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../../../cmake) + ++find_path(HALF_INCLUDE_DIR half.hpp) + find_package(OpenCV QUIET) + find_package(AMDRPP QUIET) + + include_directories(${ROCM_PATH}/${CMAKE_INSTALL_INCLUDEDIR}) +-include_directories(${ROCM_PATH}/${CMAKE_INSTALL_INCLUDEDIR}/mivisionx/rocal) ++include_directories(${ROCM_PATH}/${CMAKE_INSTALL_INCLUDEDIR}/mivisionx/rocal ${HALF_INCLUDE_DIR}) + link_directories(${ROCM_PATH}/lib/) + file(GLOB My_Source_Files ./*.cpp) + add_executable(${PROJECT_NAME} ${My_Source_Files}) +diff --git a/utilities/rocAL/rocAL_video_unittests/CMakeLists.txt b/utilities/rocAL/rocAL_video_unittests/CMakeLists.txt +index 8f4c0fa..dd23135 100644 +--- a/utilities/rocAL/rocAL_video_unittests/CMakeLists.txt ++++ b/utilities/rocAL/rocAL_video_unittests/CMakeLists.txt +@@ -48,7 +48,8 @@ find_package(OpenCV QUIET) + find_package(AMDRPP QUIET) + + include_directories(${ROCM_PATH}/${CMAKE_INSTALL_INCLUDEDIR}) +-include_directories(${ROCM_PATH}/${CMAKE_INSTALL_INCLUDEDIR}/mivisionx/rocal) ++find_path(HALF_INCLUDE_DIR half.hpp) ++include_directories(${ROCM_PATH}/${CMAKE_INSTALL_INCLUDEDIR}/mivisionx/rocal ${HALF_INCLUDE_DIR}) + link_directories(${ROCM_PATH}/lib/) + file(GLOB My_Source_Files ./*.cpp) + add_executable(${PROJECT_NAME} ${My_Source_Files}) +-- +2.27.0 + diff --git a/var/spack/repos/builtin/packages/mivisionx/package.py b/var/spack/repos/builtin/packages/mivisionx/package.py index 1e4d36000ce0b5..e4e2daae199dce 100644 --- a/var/spack/repos/builtin/packages/mivisionx/package.py +++ b/var/spack/repos/builtin/packages/mivisionx/package.py @@ -13,7 +13,7 @@ class Mivisionx(CMakePackage): homepage = "https://github.com/GPUOpen-ProfessionalCompute-Libraries/MIVisionX" git = "https://github.com/GPUOpen-ProfessionalCompute-Libraries/MIVisionX.git" - url = "https://github.com/GPUOpen-ProfessionalCompute-Libraries/MIVisionX/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/GPUOpen-ProfessionalCompute-Libraries/MIVisionX/archive/rocm-6.1.2.tar.gz" maintainers("srekolam", "renjithravindrankannath") tags = ["rocm"] @@ -26,6 +26,9 @@ def url_for_version(self, version): return url.format(version) license("MIT") + version("6.1.2", sha256="0afa664931f566b7f5a3abd474dd641e56077529a2a5d7c788f5e6700e957ed6") + version("6.1.1", sha256="3483b5167c47047cca78581cc6c9685138f9b5b25edb11618b720814788fc2a0") + version("6.1.0", sha256="f18a72c4d12c36ab50f9c3a5c22fc3641feb11c99fed513540a16a65cd149fd1") version("6.0.2", sha256="e39521b3109aa0900f652ae95a4421df0fa29fd57e816268cc6602d243c50779") version("6.0.0", sha256="01324a12f21ea0e29a4d7d7c60498ba9231723569fedcdd90f28ddffb5e0570e") version("5.7.1", sha256="bfc074bc32ebe84c72149ee6abb30b5b6499023d5b98269232de82e35d0505a8") @@ -34,16 +37,13 @@ def url_for_version(self, version): version("5.6.0", sha256="34c184e202b1a6da2398b66e33c384d5bafd8f8291089c18539715c5cb73eb1f") version("5.5.1", sha256="e8209f87a57c4222003a936240e7152bbfa496862113358f29d4c3e80d4cdf56") version("5.5.0", sha256="af266550ecccad80f08954f23e47e8264eb338b0928a5314bd6efca349fc5a14") - version("5.4.3", sha256="4da82974962a70c326ce2427c664517b1efdff436efe222e6bc28817c222a082") - version("5.4.0", sha256="caa28a30972704ddbf1a87cefdc0b0a35381d369961c43973d473a1573bd35cc") - version("5.3.3", sha256="378fafcb327e17e0e11fe1d1029d1740d84aaef0fd59614ed7376499b3d716f6") - version("5.3.0", sha256="58e68f1c78bbe5694e42bf61be177f9e94bfd3e0c113ec6284493c8684836c58") with default_args(deprecated=True): - version("5.2.3", sha256="bbcdb5808d2bc880486dffa89f4111fb4b1d6dfe9b11fcd46fbd17939d057cf0") - version("5.2.1", sha256="201996b31f59a8d5e4cc3f17d17a5b81158a34d2a1c833b65ccc3dceb21d176f") - version("5.2.0", sha256="fee620a1edd3bce18b2cec9ef26ec2afe0a85d6da8a37ed713ab0d1342382503") - version("5.1.3", sha256="62591d5caedc13832c3ccef629a88d9c2a43c884daad1124ddcb9c5f7d5470e9") - version("5.1.0", sha256="e082415cc2fb859c53a6d6e5d72ca4529f6b4d56a4abe274dc374faaa5910513") + version("5.4.3", sha256="4da82974962a70c326ce2427c664517b1efdff436efe222e6bc28817c222a082") + version("5.4.0", sha256="caa28a30972704ddbf1a87cefdc0b0a35381d369961c43973d473a1573bd35cc") + version("5.3.3", sha256="378fafcb327e17e0e11fe1d1029d1740d84aaef0fd59614ed7376499b3d716f6") + version("5.3.0", sha256="58e68f1c78bbe5694e42bf61be177f9e94bfd3e0c113ec6284493c8684836c58") + + depends_on("cxx", type="build") # generated # Adding 2 variants OPENCL ,HIP which HIP as default. earlier to 5.0.0,OPENCL # was the default but has change dto HIP from 5.0.0 onwards. @@ -56,7 +56,8 @@ def url_for_version(self, version): patch("0001-add-half-include-path.patch", when="@5.5") patch("0001-add-half-include-path-5.6.patch", when="@5.6:") - patch("0002-add-half-include-path-for-tests.patch", when="@5.5: +add_tests") + patch("0002-add-half-include-path-for-tests.patch", when="@5.5:6.0 +add_tests") + patch("0002-add-half-include-path-for-tests-6.1.0.patch", when="@6.1.0: +add_tests") patch( "https://github.com/GPUOpen-ProfessionalCompute-Libraries/MIVisionX/commit/da24882438b91a0ae1feee23206b75c1a1256887.patch?full_index=1", @@ -68,25 +69,6 @@ def url_for_version(self, version): conflicts("+add_tests", when="@:5.4") def patch(self): - if self.spec.satisfies("@:5.1 + hip"): - filter_file( - r"${ROCM_PATH}/miopen", - self.spec["miopen-hip"].prefix.miopen, - "amd_openvx_extensions/CMakeLists.txt", - string=True, - ) - filter_file( - r"${ROCM_PATH}/bin", - self.spec["hip"].prefix.bin, - "amd_openvx/openvx/hipvx/CMakeLists.txt", - string=True, - ) - filter_file( - r"${ROCM_PATH}/bin", - self.spec["hip"].prefix.bin, - "amd_openvx_extensions/amd_nn/nn_hip/CMakeLists.txt", - string=True, - ) if self.spec.satisfies("@5.1.3: + hip"): filter_file( r"${ROCM_PATH}/include/miopen/config.h", @@ -121,41 +103,56 @@ def patch(self): "rocAL/rocAL/rocAL_hip/CMakeLists.txt", string=True, ) - if self.spec.satisfies("+add_tests"): + if self.spec.satisfies("@5.5.0:6.0.0 +add_tests"): filter_file( r"${ROCM_PATH}/include/mivisionx", "{0}/include/mivisionx".format(self.spec.prefix), - "tests/amd_migraphx_tests/mnist/CMakeLists.txt", + "samples/inference/mv_objdetect/CMakeLists.txt", string=True, ) filter_file( r"${ROCM_PATH}/lib", "{0}/lib".format(self.spec.prefix), - "tests/amd_migraphx_tests/mnist/CMakeLists.txt", + "samples/inference/mv_objdetect/CMakeLists.txt", string=True, ) + if self.spec.satisfies("@6.1.0: +add_tests"): filter_file( r"${ROCM_PATH}/include/mivisionx", "{0}/include/mivisionx".format(self.spec.prefix), - "tests/amd_migraphx_tests/resnet50/CMakeLists.txt", + "samples/mv_objdetect/CMakeLists.txt", string=True, ) filter_file( r"${ROCM_PATH}/lib", "{0}/lib".format(self.spec.prefix), - "tests/amd_migraphx_tests/resnet50/CMakeLists.txt", + "samples/mv_objdetect/CMakeLists.txt", string=True, ) + + if self.spec.satisfies("+add_tests"): filter_file( r"${ROCM_PATH}/include/mivisionx", "{0}/include/mivisionx".format(self.spec.prefix), - "samples/inference/mv_objdetect/CMakeLists.txt", + "tests/amd_migraphx_tests/mnist/CMakeLists.txt", string=True, ) filter_file( r"${ROCM_PATH}/lib", "{0}/lib".format(self.spec.prefix), - "samples/inference/mv_objdetect/CMakeLists.txt", + "tests/amd_migraphx_tests/mnist/CMakeLists.txt", + string=True, + ) + filter_file( + r"${ROCM_PATH}/include/mivisionx", + "{0}/include/mivisionx".format(self.spec.prefix), + "tests/amd_migraphx_tests/resnet50/CMakeLists.txt", + string=True, + ) + filter_file( + r"${ROCM_PATH}/lib", + "{0}/lib".format(self.spec.prefix), + "tests/amd_migraphx_tests/resnet50/CMakeLists.txt", string=True, ) filter_file( @@ -199,13 +196,6 @@ def patch(self): depends_on("ffmpeg@:4", type="build", when="@:5.3") depends_on("ffmpeg@4.4", type="build", when="@5.4:") depends_on("protobuf@:3", type="build") - depends_on( - "opencv@:3.4" - "+calib3d+features2d+highgui+imgcodecs+imgproc" - "+video+videoio+flann+photo+objdetect", - type="build", - when="@:5.2", - ) depends_on( "opencv@4.5:" "+calib3d+features2d+highgui+imgcodecs+imgproc" @@ -215,7 +205,7 @@ def patch(self): ) depends_on("openssl") depends_on("libjpeg-turbo@2.0.6+partial_decoder", type="build") - depends_on("rpp", when="@5.5:") + depends_on("rpp@1.2.0", when="@5.5:5.6") depends_on("lmdb", when="@5.5:") depends_on("py-setuptools", when="@5.6:") depends_on("py-wheel", when="@5.6:") @@ -231,32 +221,14 @@ def patch(self): # HIP as backend did not build for older releases 5.1.0 where # OPENCL was default backend. conflicts("+opencl+hip") - conflicts("+hip", when="@:5.1.0") with when("+opencl"): - for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", - "5.3.0", - "5.3.3", - "5.4.0", - "5.4.3", - "5.5.0", - "5.5.1", - ]: + for ver in ["5.3.0", "5.3.3", "5.4.0", "5.4.3", "5.5.0", "5.5.1"]: depends_on(f"rocm-opencl@{ver}", when=f"@{ver}") depends_on(f"miopengemm@{ver}", when=f"@{ver}") depends_on(f"miopen-opencl@{ver}", when=f"@{ver}") with when("+hip"): for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -269,6 +241,9 @@ def patch(self): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"miopen-hip@{ver}", when=f"@{ver}") for ver in [ @@ -283,16 +258,35 @@ def patch(self): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"migraphx@{ver}", when=f"@{ver}") depends_on(f"hip@{ver}", when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") depends_on("python@3.5:", type="build") + for ver in ["5.7.0", "5.7.1", "6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: + depends_on(f"rpp@{ver}", when=f"@{ver}") def setup_run_environment(self, env): env.set("MIVISIONX_MODEL_COMPILER_PATH", self.spec.prefix.libexec.mivisionx.model_compiler) + if self.spec.satisfies("@6.1:"): + env.prepend_path("LD_LIBRARY_PATH", self.spec["hsa-rocr-dev"].prefix.lib) def flag_handler(self, name, flags): spec = self.spec diff --git a/var/spack/repos/builtin/packages/mkfontscale/package.py b/var/spack/repos/builtin/packages/mkfontscale/package.py index da3531e9bf8288..ae74b563158793 100644 --- a/var/spack/repos/builtin/packages/mkfontscale/package.py +++ b/var/spack/repos/builtin/packages/mkfontscale/package.py @@ -19,8 +19,10 @@ class Mkfontscale(AutotoolsPackage, XorgPackage): version("1.2.2", sha256="4a5af55e670713024639a7f7d10826d905d86faf574cd77e0f5aef2d00e70168") version("1.1.2", sha256="8bba59e60fbc4cb082092cf6b67e810b47b4fe64fbc77dbea1d7e7d55312b2e4") + depends_on("c", type="build") # generated + depends_on("libfontenc") - depends_on("freetype") + depends_on("freetype build_system=autotools") depends_on("xproto@7.0.25:") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/mlhka/package.py b/var/spack/repos/builtin/packages/mlhka/package.py index 807e7c3bb2b7b9..02b9bd521def71 100644 --- a/var/spack/repos/builtin/packages/mlhka/package.py +++ b/var/spack/repos/builtin/packages/mlhka/package.py @@ -17,6 +17,8 @@ class Mlhka(Package): version("2.1", commit="e735ddd39073af58da21b00b27dea203736e5467") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): cxx = which("c++") cxx("MLHKA_version{0}.cpp".format(self.version), "-o", "MLHKA") diff --git a/var/spack/repos/builtin/packages/mlirmiopen/package.py b/var/spack/repos/builtin/packages/mlirmiopen/package.py index 4c4eb8c7c52f0d..d2766e8a939123 100644 --- a/var/spack/repos/builtin/packages/mlirmiopen/package.py +++ b/var/spack/repos/builtin/packages/mlirmiopen/package.py @@ -16,15 +16,10 @@ class Mlirmiopen(CMakePackage): tags = ["rocm"] maintainers("srekolam") - version("5.4.0", sha256="3823f455ee392118c3281e27d45fa0e5381f3c4070eb4e06ba13bc6b34a90a60") - version("5.3.3", sha256="e9aa407df775d00fdb9404689f69ac755575188f8b25c6bd0fa9599928c5c57f") - version("5.3.0", sha256="e8471a13cb39d33adff34730d3162adaa5d20f9544d61a6a94b39b9b5762ad6d") with default_args(deprecated=True): - version("5.2.3", sha256="29e1c352d203622fa083432d5d368caccb53ba141119fbb7e8d5247d99854625") - version("5.2.1", sha256="9e305e05474076d84c78b7a796bca20b64c70ee3e2caa066c625216c5ee21d95") - version("5.2.0", sha256="546121f203e7787d3501fbaf6673bdbeefbb39e0446b02c480454338362a1f01") - version("5.1.3", sha256="936f92707ffe9a1973728503db6365bb7f14e5aeccfaef9f0924e54d25080c69") - version("5.1.0", sha256="56dab11877295784cbb754c10bf2bd6535a3dfea31ec0b97ffe77b94115109dc") + version("5.4.0", sha256="3823f455ee392118c3281e27d45fa0e5381f3c4070eb4e06ba13bc6b34a90a60") + version("5.3.3", sha256="e9aa407df775d00fdb9404689f69ac755575188f8b25c6bd0fa9599928c5c57f") + version("5.3.0", sha256="e8471a13cb39d33adff34730d3162adaa5d20f9544d61a6a94b39b9b5762ad6d") variant( "build_type", @@ -51,7 +46,7 @@ def patch(self): depends_on("half") depends_on("pkgconfig", type="build") - for ver in ["5.1.0", "5.1.3", "5.2.0", "5.2.1", "5.2.3", "5.3.0", "5.3.3", "5.4.0"]: + for ver in ["5.3.0", "5.3.3", "5.4.0"]: depends_on("hip@" + ver, when="@" + ver) depends_on("llvm-amdgpu@" + ver, when="@" + ver) depends_on("hsa-rocr-dev@" + ver, when="@" + ver) diff --git a/var/spack/repos/builtin/packages/mlocate/package.py b/var/spack/repos/builtin/packages/mlocate/package.py index b520e3b87e97a1..0c9d6cca64fbf1 100644 --- a/var/spack/repos/builtin/packages/mlocate/package.py +++ b/var/spack/repos/builtin/packages/mlocate/package.py @@ -20,3 +20,5 @@ class Mlocate(AutotoolsPackage): version("0.26", sha256="3063df79fe198fb9618e180c54baf3105b33d88fe602ff2d8570aaf944f1263e") version("0.25", sha256="ab95c111f9dba35b5690896180dd0a7639dbf07d70b862fcb0731264d9273951") version("0.24", sha256="5787bee846735e21ff57df9e345d5db73d684d2cea9efc0f387462ccfbc6796f") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/mlpack/package.py b/var/spack/repos/builtin/packages/mlpack/package.py index d84fdc3bc1899f..f6432688957c41 100644 --- a/var/spack/repos/builtin/packages/mlpack/package.py +++ b/var/spack/repos/builtin/packages/mlpack/package.py @@ -24,6 +24,8 @@ class Mlpack(CMakePackage): version("4.1.0", sha256="e0c760baf15fd0af5601010b7cbc536e469115e9dd45f96712caa3b651b1852a") version("4.0.1", sha256="4c746936ed9da9f16744240ed7b9f2815d3abb90c904071a1d1a628a9bbfb3a5") + depends_on("cxx", type="build") # generated + # TODO: Go bindings are not supported due to the absence of gonum in spack # variant("go", default=False, description="Build Go bindings") variant("julia", default=False, description="Build Julia bindings") @@ -64,8 +66,8 @@ class Mlpack(CMakePackage): depends_on("r-pkgbuild") patch( - "https://github.com/mlpack/mlpack/pull/3502/commits/183396e51a6771d5d2b43f22b0d2a9a91785e533.patch?full_index=1", - sha256="eaa1791ca874201cca5fb661f44e0038f9996b2d02dac6c71d42935eac56a2b4", + "https://github.com/mlpack/mlpack/commit/183396e51a6771d5d2b43f22b0d2a9a91785e533.patch?full_index=1", + sha256="bd726818a8932888f8d38548cab7f8dde15bacfbd8c58a36ce6a3be8d459578d", when="@4:4.2.0", ) diff --git a/var/spack/repos/builtin/packages/mmg/package.py b/var/spack/repos/builtin/packages/mmg/package.py index 10a8118106a8b6..eb14be0c7761bf 100644 --- a/var/spack/repos/builtin/packages/mmg/package.py +++ b/var/spack/repos/builtin/packages/mmg/package.py @@ -32,12 +32,18 @@ class Mmg(CMakePackage): license("LGPL-3.0-or-later") + version("5.7.3", sha256="b0a9c5ad6789df369a68f94295df5b324b6348020b73bcc395d32fdd44abe706") + version("5.7.2", sha256="4c396dd44aec69e0a171a04f857e28aad2e0bbfb733b48b6d81a2c6868e86840") version("5.7.1", sha256="27c09477ebc080f54919f76f8533a343936677c81809fe37ce4e2d62fa97237b") version("5.6.0", sha256="bbf9163d65bc6e0f81dd3acc5a51e4a8c47a7fdae849abc26277e01154fe2437") version("5.5.2", sha256="58e3b866101e6f0686758e16bcf9fb5fb06c85184533fc5054ef1c8adfd4be73") version("5.4.0", sha256="2b5cc505018859856766be901797ff5d4789f89377038a0211176a5571039750") version("5.3.13", sha256="d9a5925b69b0433f942ab2c8e55659d9ccea758743354b43d54fdf88a6c3c191") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") variant("scotch", default=True, description="Enable SCOTCH library support") variant("doc", default=False, description="Build documentation") @@ -54,6 +60,7 @@ def cmake_args(self): return [ self.define_from_variant("USE_SCOTCH", "scotch"), self.define_from_variant("USE_VTK", "vtk"), + self.define("BUILD_SHARED_LIBS", shared_active), self.define("LIBMMG3D_SHARED", shared_active), self.define("LIBMMG2D_SHARED", shared_active), self.define("LIBMMGS_SHARED", shared_active), diff --git a/var/spack/repos/builtin/packages/mmseqs2/package.py b/var/spack/repos/builtin/packages/mmseqs2/package.py index 86d18d45c6dcbc..5855899a78ac37 100644 --- a/var/spack/repos/builtin/packages/mmseqs2/package.py +++ b/var/spack/repos/builtin/packages/mmseqs2/package.py @@ -16,9 +16,13 @@ class Mmseqs2(CMakePackage): license("GPL-3.0-only") + version("15-6f452", sha256="7115ac5a7e2a49229466806aaa760d00204bb08c870e3c231b00e525c77531dc") version("14-7e284", sha256="a15fd59b121073fdcc8b259fc703e5ce4c671d2c56eb5c027749f4bd4c28dfe1") version("13-45111", sha256="6444bb682ebf5ced54b2eda7a301fa3e933c2a28b7661f96ef5bdab1d53695a2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("openmp", default=False, description="build with OpenMP support") variant("mpi", default=False, description="build with MPI support") @@ -29,7 +33,7 @@ class Mmseqs2(CMakePackage): patch( "https://github.com/soedinglab/MMseqs2/commit/3e43617.patch?full_index=1", sha256="673737ac545260e7800ca191c6eee14feef3318d9cfa5005db32bd2ab3c006fe", - when="%gcc@13:", + when="@:14 %gcc@13:", level=1, ) diff --git a/var/spack/repos/builtin/packages/mmv/package.py b/var/spack/repos/builtin/packages/mmv/package.py index dc7a2550178eb0..991503504a42ac 100644 --- a/var/spack/repos/builtin/packages/mmv/package.py +++ b/var/spack/repos/builtin/packages/mmv/package.py @@ -20,6 +20,8 @@ class Mmv(MakefilePackage): version("1.01b", sha256="0399c027ea1e51fd607266c1e33573866d4db89f64a74be8b4a1d2d1ff1fdeef") + depends_on("c", type="build") # generated + patch("better-diagnostics-for-directories-584850.diff") patch("format-security.diff") patch("man-page-examples.diff") diff --git a/var/spack/repos/builtin/packages/moab/package.py b/var/spack/repos/builtin/packages/moab/package.py index a0ed8f8b1d365b..6ad76aba0728ea 100644 --- a/var/spack/repos/builtin/packages/moab/package.py +++ b/var/spack/repos/builtin/packages/moab/package.py @@ -41,6 +41,10 @@ class Moab(AutotoolsPackage): version("4.9.0", sha256="267a7c05da847e4ea856db2c649a5484fb7bdc132ab56721ca50ee69a7389f4d") version("4.8.2", sha256="b105cff42930058dc14eabb9a25e979df7289b175732fe319d2494e83e09e968") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI parallelism support") variant("hdf5", default=True, description="Enable the HDF5 (default I/O) format") variant("netcdf", default=False, description="Enable the ExodusII reader/writer support") diff --git a/var/spack/repos/builtin/packages/mochi-margo/package.py b/var/spack/repos/builtin/packages/mochi-margo/package.py index fa0943655866dd..57813c1b9ec741 100644 --- a/var/spack/repos/builtin/packages/mochi-margo/package.py +++ b/var/spack/repos/builtin/packages/mochi-margo/package.py @@ -17,6 +17,8 @@ class MochiMargo(AutotoolsPackage): maintainers("carns", "mdorier", "fbudin69500") version("main", branch="main") + version("0.17.0", sha256="5c456cdc2e3156f902e5068468ee6d061eb252dcfdfcb2b570726e9cf84fc2e8") + version("0.16.0", sha256="5fb7ea3633b5bcc735e605dba27187ea893958bf86b8928184028735a338c61b") version("0.15.0", sha256="f962f02ddaae125eaf15bf89126ee47b4f852d366b14248d2d67a0be8f661224") version("0.14.1", sha256="69229a9126b76aff7fd47e25c4a8f72804f101c5c603c4e4ef93f4fb7a1b6662") version("0.14.0", sha256="ff0e3fa786630b63280606243c35f1ea3a25fa2ba6f08bf9065cab9fcc7fa1c7") @@ -56,6 +58,8 @@ class MochiMargo(AutotoolsPackage): version("0.4.3", sha256="61a634d6983bee2ffa06e1e2da4c541cb8f56ddd9dd9f8e04e8044fb38657475") version("0.4.2", sha256="91085e28f50e373b9616e1ae5c3c8d40a19a7d3776259592d8f361766890bcaa") + depends_on("c", type="build") # generated + depends_on("json-c", when="@0.9:") depends_on("autoconf@2.65:", type=("build")) depends_on("m4", type=("build")) diff --git a/var/spack/repos/builtin/packages/mochi-thallium/package.py b/var/spack/repos/builtin/packages/mochi-thallium/package.py index 905292e1500728..7bdcfc7665296b 100644 --- a/var/spack/repos/builtin/packages/mochi-thallium/package.py +++ b/var/spack/repos/builtin/packages/mochi-thallium/package.py @@ -47,6 +47,8 @@ class MochiThallium(CMakePackage): version("0.3.1", sha256="61403b1ba5f4d205408e6a7e04c785df6dea02f59fe9fa1742db05aa752cc8a0") version("0.3", sha256="4f9f78e52c1725f6ea5f933d7548bde36729dd9eff08f58fe7fe40682bc5f748") + depends_on("cxx", type="build") # generated + variant( "cereal", default=True, diff --git a/var/spack/repos/builtin/packages/model-traits/package.py b/var/spack/repos/builtin/packages/model-traits/package.py index c49ab28bff5744..2215190dac04f9 100644 --- a/var/spack/repos/builtin/packages/model-traits/package.py +++ b/var/spack/repos/builtin/packages/model-traits/package.py @@ -23,6 +23,8 @@ class ModelTraits(CMakePackage): version("0.1.0", sha256="ff7c1c5be6977f1d3dc592e8b6c5bff5a8b7ea80d0f059d85c02300bdb8faf2c") version("main", branch="main") + depends_on("cxx", type="build") # generated + variant("yaml", default=True, description="build the Yaml IO backend") variant("simmetrix", default=False, description="build the Simmetrix backend") variant("pumi", default=False, description="build the pumi examples") diff --git a/var/spack/repos/builtin/packages/modeltest-ng/package.py b/var/spack/repos/builtin/packages/modeltest-ng/package.py index 3dd44a14968cc7..023fd759d02680 100644 --- a/var/spack/repos/builtin/packages/modeltest-ng/package.py +++ b/var/spack/repos/builtin/packages/modeltest-ng/package.py @@ -20,6 +20,9 @@ class ModeltestNg(CMakePackage): version("20220721", commit="1066356b984100897b8bd38ac771c5c950984c01", submodules=True) version("0.1.7", commit="cc028888f1d4222aaa53b99c6b02cd934a279001", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Enable MPI") depends_on("glib") diff --git a/var/spack/repos/builtin/packages/modern-wheel/package.py b/var/spack/repos/builtin/packages/modern-wheel/package.py index 692b1e49ee8423..a6c4fae52b3d6f 100644 --- a/var/spack/repos/builtin/packages/modern-wheel/package.py +++ b/var/spack/repos/builtin/packages/modern-wheel/package.py @@ -23,6 +23,8 @@ class ModernWheel(CMakePackage): version("1.1", sha256="d8ba4891257b96108e9b9406a556f8ced3b71ce85c3fcdca6bfd9cc37bf010a3") version("1.0", sha256="b90a1e29af0b67dfa4c07f9c19b2d04fa78cd878b29a9c42bc766dabd6cb1b90") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") # Test implementation files cause some issues on darwin, # needs to be investigated. diff --git a/var/spack/repos/builtin/packages/mokutil/package.py b/var/spack/repos/builtin/packages/mokutil/package.py index 8ca6f5cede2224..06048ee28595ce 100644 --- a/var/spack/repos/builtin/packages/mokutil/package.py +++ b/var/spack/repos/builtin/packages/mokutil/package.py @@ -18,6 +18,8 @@ class Mokutil(AutotoolsPackage): version("0.3.0", sha256="70ccbffbbba0427dfd6b57902d667bf73d6223296c897ce3441fc2221352a773") version("0.2.0", sha256="a51ef146b8f2169c4e4a0d2f86cae5f4d66cc520989fc2f70a7a620f9587a20b") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/mold/package.py b/var/spack/repos/builtin/packages/mold/package.py index 82e22a8a44a230..eae4005216816b 100644 --- a/var/spack/repos/builtin/packages/mold/package.py +++ b/var/spack/repos/builtin/packages/mold/package.py @@ -12,22 +12,35 @@ class Mold(CMakePackage): homepage = "https://github.com/rui314/mold" url = "https://github.com/rui314/mold/archive/refs/tags/v1.11.0.tar.gz" - maintainers("jabcross") + maintainers("msimberg") license("MIT") + version("2.32.1", sha256="f3c9a527d884c635834fe7d79b3de959b00783bf9446280ea274d996f0335825") + version("2.32.0", sha256="4b7e4146ea0f52be9adae8b417399f3676a041e65b55e3f25f088120d30a320b") + version("2.31.0", sha256="3dc3af83a5d22a4b29971bfad17261851d426961c665480e2ca294e5c74aa1e5") + version("2.30.0", sha256="6e5178ccafe828fdb4ba0dd841d083ff6004d3cb41e56485143eb64c716345fd") + version("2.4.1", sha256="c9853d007d6a1b4f3e36b7314346751f4cc91bc43c76e30db51709b53b44dd68") + version("2.4.0", sha256="be65f3d785d32ece7b3204ecaa57810847fdd25c232cf704cbfff2dafb1ac107") + version("2.3.0", sha256="6cfc1af0214f993be1b0ae4a2f0278d32b7fc48155c15b2d03758f6d81e7250b") + version("2.2.0", sha256="78ddddaaa004e50f8d92a13d8e792a46a1b37745fab48d39ad16aeb5a776e7c6") version("2.1.0", sha256="a32bec1282671b18ea4691855aed925ea2f348dfef89cb7689cd81273ea0c5df") version("2.0.0", sha256="2ae8a22db09cbff626df74c945079fa29c1e5f60bbe02502dcf69191cf43527b") version("1.11.0", sha256="99318eced81b09a77e4c657011076cc8ec3d4b6867bd324b8677974545bc4d6f") version("1.7.1", sha256="fa2558664db79a1e20f09162578632fa856b3cde966fbcb23084c352b827dfa9") + depends_on("c", type="build") + depends_on("cxx", type="build") + + depends_on("blake3", when="@2.2:") depends_on("mimalloc") - depends_on("zlib-api") - depends_on("openssl") + depends_on("openssl", when="@:2.1") depends_on("tbb") + depends_on("zlib-api") + depends_on("zstd") def cmake_args(self): - args = [] - args.append(self.define("MOLD_USE_SYSTEM_MIMALLOC", True)) - - return args + return [ + self.define("MOLD_USE_SYSTEM_MIMALLOC", True), + self.define("MOLD_USE_SYSTEM_TBB", True), + ] diff --git a/var/spack/repos/builtin/packages/molden/package.py b/var/spack/repos/builtin/packages/molden/package.py index 98c8152334694b..25d7680f63eb28 100644 --- a/var/spack/repos/builtin/packages/molden/package.py +++ b/var/spack/repos/builtin/packages/molden/package.py @@ -19,6 +19,9 @@ class Molden(MakefilePackage): version("6.6", sha256="2a2a7a116a336b607b50e8135bc2cca764c50e4a6896013ee3c6f582b741ee72") version("6.5", sha256="192631a0996b2bfa9f6b0769f83da38a9e4f83b1db9358982b23d6a594b4e8d4") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("libx11") depends_on("libxmu") depends_on("gl@3:") diff --git a/var/spack/repos/builtin/packages/molgw/package.py b/var/spack/repos/builtin/packages/molgw/package.py index 6f07ecea21890c..64325684212c54 100644 --- a/var/spack/repos/builtin/packages/molgw/package.py +++ b/var/spack/repos/builtin/packages/molgw/package.py @@ -18,16 +18,20 @@ class Molgw(MakefilePackage): MOLGW employs standard Gaussian basis set. """ - homepage = "https://github.com/bruneval/molgw" - url = "https://github.com/bruneval/molgw/archive/v3.2.tar.gz" - git = "https://github.com/bruneval/molgw.git" + homepage = "https://github.com/molgw/molgw" + url = "https://github.com/molgw/molgw/archive/v3.3.tar.gz" + git = "https://github.com/molgw/molgw.git" maintainers("bruneval") license("GPL-3.0-only") + version("3.3", sha256="ff1c8eb736049e52608d4554a2d435ee9d15e47c4a9934d41712962748929e81") version("3.2", sha256="a3f9a99db52d95ce03bc3636b5999e6d92b503ec2f4afca33d030480c3e10242") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=False, description="Build with OpenMP support") variant("scalapack", default=False, description="Build with ScaLAPACK support") @@ -50,7 +54,7 @@ class Molgw(MakefilePackage): def _get_mkl_ld_flags(self, spec): mklroot = str(getenv("MKLROOT")) - command = [mklroot + "/bin/intel64/mkl_link_tool", "-libs", "--quiet"] + command = [mklroot + "/bin/mkl_link_tool", "-libs", "--quiet"] if "+openmp" not in spec: command.extend(["--parallel=no"]) @@ -82,7 +86,11 @@ def edit(self, spec, prefix): flags["PREFIX"] = prefix # Set LAPACK and SCALAPACK - if spec["lapack"].name not in INTEL_MATH_LIBRARIES: + if ( + spec["scalapack"].name in INTEL_MATH_LIBRARIES + or spec["lapack"].name in INTEL_MATH_LIBRARIES + or spec["blas"].name in INTEL_MATH_LIBRARIES + ): flags["LAPACK"] = self._get_mkl_ld_flags(spec) else: flags["LAPACK"] = spec["lapack"].libs.ld_flags + " " + spec["blas"].libs.ld_flags @@ -109,7 +117,11 @@ def edit(self, spec, prefix): if "+scalapack" in spec: flags["CPPFLAGS"] = flags.get("CPPFLAGS", "") + " -DHAVE_SCALAPACK -DHAVE_MPI " - if spec["lapack"].name in INTEL_MATH_LIBRARIES: + if ( + spec["lapack"].name in INTEL_MATH_LIBRARIES + or spec["scalapack"].name in INTEL_MATH_LIBRARIES + or spec["blas"].name in INTEL_MATH_LIBRARIES + ): flags["CPPFLAGS"] = flags.get("CPPFLAGS", "") + " -DHAVE_MKL " # Write configuration file diff --git a/var/spack/repos/builtin/packages/mongo-c-driver/package.py b/var/spack/repos/builtin/packages/mongo-c-driver/package.py index f53ee03166ec85..add8e3c541ec2c 100644 --- a/var/spack/repos/builtin/packages/mongo-c-driver/package.py +++ b/var/spack/repos/builtin/packages/mongo-c-driver/package.py @@ -3,19 +3,21 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.build_systems import autotools, cmake from spack.package import * -class MongoCDriver(Package): +class MongoCDriver(AutotoolsPackage, CMakePackage): """libmongoc is a client library written in C for MongoDB.""" homepage = "https://github.com/mongodb/mongo-c-driver" - url = "https://github.com/mongodb/mongo-c-driver/releases/download/1.7.0/mongo-c-driver-1.7.0.tar.gz" + url = "https://github.com/mongodb/mongo-c-driver/archive/refs/tags/1.25.0.tar.gz" maintainers("michaelkuhn") license("Apache-2.0") + version("1.27.2", sha256="a53010803e2df097a2ea756be6ece34c8f52cda2c18e6ea21115097b75f5d4bf") version("1.24.4", sha256="2f4a3e8943bfe3b8672c2053f88cf74acc8494dc98a45445f727901eee141544") version("1.23.3", sha256="c8f951d4f965d455f37ae2e10b72914736fc0f25c4ffc14afc3cbadd1a574ef6") version("1.21.0", sha256="840ff79480070f98870743fbb332e2c10dd021b6b9c952d08010efdda4d70ee4") @@ -32,7 +34,14 @@ class MongoCDriver(Package): version("1.7.0", sha256="48a0dbd44fef2124b51cf501f06be269b1a39452303b880b37473a6030c6e023") version("1.6.3", sha256="82df03de117a3ccf563b9eccfd2e5365df8f215a36dea7446d439969033ced7b") version("1.6.2", sha256="7ec27e9be4da2bf9e4b316374f8c29f816f0a0f019b984411777e9681e17f70e") - version("1.6.1", sha256="1bdfb27944c6da8e56da209a5d56efac70df1f8c4ca4498b46f75bf3f9360898") + version( + "1.6.1", + sha256="1bdfb27944c6da8e56da209a5d56efac70df1f8c4ca4498b46f75bf3f9360898", + deprecated=True, + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated variant("ssl", default=True, description="Enable SSL support.") variant("snappy", default=True, description="Enable Snappy support.") @@ -45,16 +54,32 @@ class MongoCDriver(Package): when="@1.8.1", ) - depends_on("cmake@3.1:", type="build", when="@1.10.0:") + with when("build_system=cmake"): + depends_on("cmake@3.1:", type="build") + + with when("build_system=autotools"): + depends_on("autoconf", type="build", when="@1.8.1") + depends_on("automake", type="build", when="@1.8.1") + depends_on("libtool", type="build", when="@1.8.1") - depends_on("autoconf", type="build", when="@1.8.1") - depends_on("automake", type="build", when="@1.8.1") - depends_on("libtool", type="build", when="@1.8.1") - depends_on("m4", type="build", when="@1.8.1") + build_system( + conditional("cmake", when="@1.10:"), + conditional("autotools", when="@:1.9"), + default="cmake", + ) + + def url_for_version(self, version): + if version >= Version("1.25.0"): + return f"https://github.com/mongodb/mongo-c-driver/archive/refs/tags/{version}.tar.gz" + if version >= Version("1.10.0"): + return f"https://github.com/mongodb/mongo-c-driver/releases/download/{version}/mongo-c-driver-{version}.tar.gz" + else: + return f"https://github.com/mongodb/libbson/releases/download/{version}/libbson-{version}.tar.gz" depends_on("pkgconfig", type="build") # When updating mongo-c-driver, libbson has to be kept in sync. + depends_on("libbson@1.27", when="@1.27") depends_on("libbson@1.24", when="@1.24") depends_on("libbson@1.23", when="@1.23") depends_on("libbson@1.21", when="@1.21") @@ -70,56 +95,42 @@ class MongoCDriver(Package): depends_on("zlib-api", when="+zlib") depends_on("zstd", when="+zstd") - def cmake_args(self): - spec = self.spec - - args = ["-DENABLE_AUTOMATIC_INIT_AND_CLEANUP=OFF"] - - if spec.satisfies("@1.24:"): - args.append("-DUSE_SYSTEM_LIBBSON=ON") - else: - args.append("-DENABLE_BSON=SYSTEM") + @property + def force_autoreconf(self): + # Run autoreconf due to build system patch + return self.spec.satisfies("@1.8.1") - if "+ssl" in spec: - args.append("-DENABLE_SSL=OPENSSL") - else: - args.append("-DENABLE_SSL=OFF") - if "+snappy" in spec: - args.append("-DENABLE_SNAPPY=ON") +class CMakeBuilder(cmake.CMakeBuilder): + def cmake_args(self): + args = [ + self.define("ENABLE_AUTOMATIC_INIT_AND_CLEANUP", False), + self.define("ENABLE_MONGOC", True), + self.define("MONGO_USE_CCACHE", False), + self.define("MONGO_USE_LLD", False), + self.define_from_variant("ENABLE_SNAPPY", "snappy"), + self.define_from_variant("ENABLE_ZSTD", "zstd"), + ] + + if self.spec.satisfies("@1.24:"): + args.append(self.define("USE_SYSTEM_LIBBSON", True)) else: - args.append("-DENABLE_SNAPPY=OFF") + args.append(self.define("ENABLE_BSON", "SYSTEM")) - if "+zlib" in spec: - args.append("-DENABLE_ZLIB=SYSTEM") + if self.spec.satisfies("+ssl"): + args.append(self.define("ENABLE_SSL", "OPENSSL")) else: - args.append("-DENABLE_ZLIB=OFF") + args.append(self.define("ENABLE_SSL", False)) - if "+zstd" in spec: - args.append("-DENABLE_ZSTD=ON") + if self.spec.satisfies("+zlib"): + args.append(self.define("ENABLE_ZLIB", "SYSTEM")) else: - args.append("-DENABLE_ZSTD=OFF") + args.append(self.define("ENABLE_ZLIB", False)) return args - def install(self, spec, prefix): - with working_dir("spack-build", create=True): - # We cannot simply do - # cmake('..', *std_cmake_args, *self.cmake_args()) - # because that is not Python 2 compatible. Instead, collect - # arguments into a temporary buffer first. - args = [] - args.extend(std_cmake_args) - args.extend(self.cmake_args()) - cmake("..", *args) - make() - make("install") - - @property - def force_autoreconf(self): - # Run autoreconf due to build system patch - return self.spec.satisfies("@1.8.1") +class AutotoolsBuilder(autotools.AutotoolsBuilder): def configure_args(self): spec = self.spec @@ -143,13 +154,3 @@ def configure_args(self): args.append("--with-zlib=system") return args - - @when("@:1.9") - def install(self, spec, prefix): - configure("--prefix={0}".format(prefix), *self.configure_args()) - make() - if self.run_tests: - make("check") - make("install") - if self.run_tests: - make("installcheck") diff --git a/var/spack/repos/builtin/packages/mongo-cxx-driver/package.py b/var/spack/repos/builtin/packages/mongo-cxx-driver/package.py index b42b1827d76d56..06a7e8444eaa3b 100644 --- a/var/spack/repos/builtin/packages/mongo-cxx-driver/package.py +++ b/var/spack/repos/builtin/packages/mongo-cxx-driver/package.py @@ -16,6 +16,7 @@ class MongoCxxDriver(CMakePackage): license("Apache-2.0") + version("3.10.1", sha256="0297d9d1a513f09438cc05254b14baa49edd1fa64a6ce5d7a80a1eb7677cf2be") version("3.7.0", sha256="fb2da11178db728f63147fe4b0c7509eb49b1b02c5cb55f9bee5f927e451a0c7") version("3.6.7", sha256="2c58005d4fe46f1973352fba821f7bb37e818cefc922377ce979a9fd1bff38ac") version("3.6.6", sha256="d5906b9e308a8a353a2ef92b699c9b27ae28ec6b34fdda94e15d2981b27e64ca") @@ -36,10 +37,12 @@ class MongoCxxDriver(CMakePackage): version("3.2.1", sha256="d5e62797cbc48c6e5e18bc0a66c14556e78871d05db4bccc295074af51b8421e") version("3.2.0", sha256="e26edd44cf20bd6be91907403b6d63a065ce95df4c61565770147a46716aad8c") + depends_on("cxx", type="build") # generated + + depends_on("mongo-c-driver@1.9.2:") + def url_for_version(self, version): git_archive = self.git + "/archive/refs/tags/r{version}.tar.gz" release_url = self.git + "/releases/download/r{version}/mongo-cxx-driver-r{version}.tar.gz" - template_url = release_url if version >= Version("3.6.0") else git_archive + template_url = release_url if self.spec.satisfies("@3.6.0:") else git_archive return template_url.format(version=version) - - depends_on("mongo-c-driver@1.9.2:") diff --git a/var/spack/repos/builtin/packages/mongodb/package.py b/var/spack/repos/builtin/packages/mongodb/package.py index 3c65647e84bedd..408db7dabe4f4f 100644 --- a/var/spack/repos/builtin/packages/mongodb/package.py +++ b/var/spack/repos/builtin/packages/mongodb/package.py @@ -21,6 +21,9 @@ class Mongodb(SConsPackage): version("6.2", git="https://github.com/mongodb/mongo.git", branch="v6.2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + requires( "%gcc", "%clang", policy="one_of", msg=" builds only with GCC or Clang" ) diff --git a/var/spack/repos/builtin/packages/mono/package.py b/var/spack/repos/builtin/packages/mono/package.py index 509790d8984022..30faee839d9d42 100644 --- a/var/spack/repos/builtin/packages/mono/package.py +++ b/var/spack/repos/builtin/packages/mono/package.py @@ -4,7 +4,6 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack.package import * -from spack.util.environment import is_system_path class Mono(AutotoolsPackage): @@ -67,6 +66,10 @@ class Mono(AutotoolsPackage): version("5.0.1.1", sha256="48d6ae71d593cd01bf0f499de569359d45856cda325575e1bacb5fabaa7e9718") version("4.8.0.524", sha256="ca02614cfc9fe65e310631cd611d7b07d1ff205ce193006d4be0f9919c26bdcf") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + def patch(self): if "+patch-folder-path" in self.spec: before = 'return "/usr/share";' @@ -77,8 +80,8 @@ def patch(self): def configure_args(self): args = [] - if self.spec["iconv"].name == "libc": + if self.spec["iconv"].name == "libiconv": + args.append(f"--with-libiconv-prefix={self.spec['iconv'].prefix}") + else: args.append("--without-libiconv-prefix") - elif not is_system_path(self.spec["iconv"].prefix): - args.append("--with-libiconv-prefix={p}".format(p=self.spec["iconv"].prefix)) return args diff --git a/var/spack/repos/builtin/packages/montage/package.py b/var/spack/repos/builtin/packages/montage/package.py index c50de9265a1100..47873700c34db9 100644 --- a/var/spack/repos/builtin/packages/montage/package.py +++ b/var/spack/repos/builtin/packages/montage/package.py @@ -18,6 +18,10 @@ class Montage(MakefilePackage): version("6.0", sha256="1f540a7389d30fcf9f8cd9897617cc68b19350fbcde97c4d1cdc5634de1992c6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("freetype") depends_on("bzip2") depends_on("libnsl") diff --git a/var/spack/repos/builtin/packages/moosefs/package.py b/var/spack/repos/builtin/packages/moosefs/package.py index 60a98252984605..c0fbe28222bd7f 100644 --- a/var/spack/repos/builtin/packages/moosefs/package.py +++ b/var/spack/repos/builtin/packages/moosefs/package.py @@ -25,6 +25,8 @@ class Moosefs(AutotoolsPackage): version("3.0.104", sha256="b3209ecd8366038ba898c4642dd6fdf2fa5d50a37345f01ed209e078700db5bb") version("3.0.103", sha256="c5f1f6f78c2b7d8d6563000deed704ead3deac77279cb13f9f16d7ee56ee7ff7") + depends_on("c", type="build") # generated + def configure_args(self): args = ["--with-systemdsystemunitdir=" + self.spec["moosefs"].prefix.lib.systemd.system] return args diff --git a/var/spack/repos/builtin/packages/moreutils/package.py b/var/spack/repos/builtin/packages/moreutils/package.py index 2495dc740507df..c660882271ccfb 100644 --- a/var/spack/repos/builtin/packages/moreutils/package.py +++ b/var/spack/repos/builtin/packages/moreutils/package.py @@ -21,6 +21,8 @@ class Moreutils(MakefilePackage): version("0.65", sha256="ba0cfaa1ff6ead2b15c62a67292de66a366f9b815a09697b54677f7e15f5a2b2") version("0.63", sha256="01f0b331e07e62c70d58c2dabbb68f5c4ddae4ee6f2d8f070fd1e316108af72c") + depends_on("c", type="build") # generated + depends_on("perl", type="build") depends_on("docbook-xsl", type="build") depends_on("libxml2", type="build") diff --git a/var/spack/repos/builtin/packages/mosesdecoder/package.py b/var/spack/repos/builtin/packages/mosesdecoder/package.py index a797598658767b..2a87ab3bc6aa3d 100644 --- a/var/spack/repos/builtin/packages/mosesdecoder/package.py +++ b/var/spack/repos/builtin/packages/mosesdecoder/package.py @@ -17,6 +17,10 @@ class Mosesdecoder(Package): version("4.0", sha256="357376cdbb225a17cdf17195625d0fa7e10d722807e9e0b8a633ffbd7eec9b8f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("git") depends_on("subversion") depends_on("cmake") diff --git a/var/spack/repos/builtin/packages/mosquitto/package.py b/var/spack/repos/builtin/packages/mosquitto/package.py index 809cc4bca7a97e..4cc040287cc54d 100644 --- a/var/spack/repos/builtin/packages/mosquitto/package.py +++ b/var/spack/repos/builtin/packages/mosquitto/package.py @@ -23,6 +23,9 @@ class Mosquitto(CMakePackage): version("1.4.15", sha256="7d3b3e245a3b4ec94b05678c8199c806359737949f4cfe0bf936184f6ca89a83") version("1.3.5", sha256="16eb3dbef183827665feee9288362c7352cd016ba04ca0402a0ccf857d1c2ab2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("tls", default=True, description="Build with TLS support") variant("cjson", default=True, description="Build with cJSON support", when="@2.0.0:") variant("static", default=False, description="Build with static libraries", when="@1.5.0:") diff --git a/var/spack/repos/builtin/packages/mothur/package.py b/var/spack/repos/builtin/packages/mothur/package.py index 8fc043cf49964e..f661642c980514 100644 --- a/var/spack/repos/builtin/packages/mothur/package.py +++ b/var/spack/repos/builtin/packages/mothur/package.py @@ -22,6 +22,8 @@ class Mothur(MakefilePackage): version("1.42.1", sha256="6b61591dda289ac2d8361f9c1547ffbeeba3b9fbdff877dd286bad850bbd5539") version("1.40.5", sha256="a0fbdfa68b966d7adc4560e3787506a0dad8b47b4b996c2663cd6c0b416d101a") version("1.39.5", sha256="9f1cd691e9631a2ab7647b19eb59cd21ea643f29b22cde73d7f343372dfee342") + + depends_on("cxx", type="build") # generated maintainers("snehring") variant( diff --git a/var/spack/repos/builtin/packages/motif/package.py b/var/spack/repos/builtin/packages/motif/package.py index 4fa53c7e930dfd..8d2b39e8610be1 100644 --- a/var/spack/repos/builtin/packages/motif/package.py +++ b/var/spack/repos/builtin/packages/motif/package.py @@ -21,6 +21,9 @@ class Motif(AutotoolsPackage): version("2.3.8", sha256="859b723666eeac7df018209d66045c9853b50b4218cecadb794e2359619ebce7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("flex") depends_on("libx11") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/mount-point-attributes/package.py b/var/spack/repos/builtin/packages/mount-point-attributes/package.py index 0c50cd9b72d3fa..a1a8688907d068 100644 --- a/var/spack/repos/builtin/packages/mount-point-attributes/package.py +++ b/var/spack/repos/builtin/packages/mount-point-attributes/package.py @@ -23,6 +23,8 @@ class MountPointAttributes(AutotoolsPackage): ) version("1.1", sha256="bff84c75c47b74ea09b6cff949dd699b185ddba0463cb1ff39ab138003c96e02") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build", when="@master") depends_on("automake", type="build", when="@master") depends_on("libtool", type="build", when="@master") diff --git a/var/spack/repos/builtin/packages/mozjpeg/package.py b/var/spack/repos/builtin/packages/mozjpeg/package.py index 8a7e46f759f457..aa802f5e504e03 100644 --- a/var/spack/repos/builtin/packages/mozjpeg/package.py +++ b/var/spack/repos/builtin/packages/mozjpeg/package.py @@ -20,6 +20,9 @@ class Mozjpeg(CMakePackage): version("4.1.1", sha256="66b1b8d6b55d263f35f27f55acaaa3234df2a401232de99b6d099e2bb0a9d196") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + provides("jpeg") variant("shared", default=True, description="Build shared libs") diff --git a/var/spack/repos/builtin/packages/mpark-variant/package.py b/var/spack/repos/builtin/packages/mpark-variant/package.py index f1e2148fef9dd7..c7c9652d596c8d 100644 --- a/var/spack/repos/builtin/packages/mpark-variant/package.py +++ b/var/spack/repos/builtin/packages/mpark-variant/package.py @@ -21,6 +21,8 @@ class MparkVariant(CMakePackage): version("1.4.0", sha256="8f6b28ab3640b5d76d5b6664dda7257a4405ce59179220431b8fd196c79b2ecb") version("1.3.0", sha256="d0f7e41f818fcc839797a8017e76b8b66b323651c304cff641a83a56ae9943c6") + depends_on("cxx", type="build") # generated + # Ref.: https://github.com/mpark/variant/pull/73 patch("nvcc.patch", when="@:1.4.0") # Ref.: https://github.com/mpark/variant/issues/60 diff --git a/var/spack/repos/builtin/packages/mpas-model/package.py b/var/spack/repos/builtin/packages/mpas-model/package.py index 2e4a0e6a26c1fd..dddf3d47fc6b56 100644 --- a/var/spack/repos/builtin/packages/mpas-model/package.py +++ b/var/spack/repos/builtin/packages/mpas-model/package.py @@ -25,6 +25,10 @@ class MpasModel(MakefilePackage): version("6.3", sha256="e7f1d9ebfeb6ada37d42a286aaedb2e69335cbc857049dc5c5544bb51e7a8db8") version("6.2", sha256="2a81825a62a468bf5c56ef9d9677aa2eb88acf78d4f996cb49a7db98b94a6b16") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # These targets are defined in the Makefile. Some can be auto-detected by the # compiler name, others need to be explicitly set. make_target = [ @@ -104,15 +108,9 @@ def target(self, model, action): fflags = [self.compiler.openmp_flag] cppflags = ["-D_MPI"] if satisfies("%gcc"): - fflags.extend( - [ - "-ffree-line-length-none", - "-fconvert=big-endian", - "-ffree-form", - "-fdefault-real-8", - "-fdefault-double-8", - ] - ) + fflags.extend(["-ffree-line-length-none", "-fconvert=big-endian", "-ffree-form"]) + if satisfies("precision=double"): + fflags.extend(["-fdefault-real-8", "-fdefault-double-8"]) cppflags.append("-DUNDERSCORE") elif satisfies("%fj"): fflags.extend(["-Free", "-Fwide", "-CcdRR8"]) diff --git a/var/spack/repos/builtin/packages/mpb/package.py b/var/spack/repos/builtin/packages/mpb/package.py index c117130c3a4a0d..5898c67895f81c 100644 --- a/var/spack/repos/builtin/packages/mpb/package.py +++ b/var/spack/repos/builtin/packages/mpb/package.py @@ -17,6 +17,8 @@ class Mpb(AutotoolsPackage): version("1.11.1", sha256="7311fc525214c1184cad3e0626b8540c0b53b3c31c28e61ce6ec2860088eca46") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/mpc/package.py b/var/spack/repos/builtin/packages/mpc/package.py index d5c795a05876fa..697c42d24c6c82 100644 --- a/var/spack/repos/builtin/packages/mpc/package.py +++ b/var/spack/repos/builtin/packages/mpc/package.py @@ -23,6 +23,8 @@ class Mpc(AutotoolsPackage, GNUMirrorPackage): version("1.0.3", sha256="617decc6ea09889fb08ede330917a00b16809b8db88c29c31bfbb49cbf88ecc3") version("1.0.2", sha256="b561f54d8a479cee3bc891ee52735f18ff86712ba30f036f8b8537bae380c488") + depends_on("c", type="build") # generated + variant( "libs", default="shared,static", diff --git a/var/spack/repos/builtin/packages/mpdecimal/package.py b/var/spack/repos/builtin/packages/mpdecimal/package.py index 08a8bf372a815f..a08cb42d53008e 100644 --- a/var/spack/repos/builtin/packages/mpdecimal/package.py +++ b/var/spack/repos/builtin/packages/mpdecimal/package.py @@ -19,6 +19,9 @@ class Mpdecimal(AutotoolsPackage): version("2.5.1", sha256="9f9cd4c041f99b5c49ffb7b59d9f12d95b683d88585608aa56a6307667b2b21f") version("2.4.2", sha256="83c628b90f009470981cf084c5418329c88b19835d8af3691b930afccb7d79c7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gmake", type="build") @property diff --git a/var/spack/repos/builtin/packages/mpe2/package.py b/var/spack/repos/builtin/packages/mpe2/package.py index 85e001daa92338..b5b9eca97143d4 100644 --- a/var/spack/repos/builtin/packages/mpe2/package.py +++ b/var/spack/repos/builtin/packages/mpe2/package.py @@ -14,6 +14,9 @@ class Mpe2(AutotoolsPackage): version("1.3.0", sha256="0faf32f9adab6fd882be30be913089ebf75272f8b5e4a012bb20c54abc21c0be") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + patch("mpe2.patch") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/mpfr/package.py b/var/spack/repos/builtin/packages/mpfr/package.py index e58672c4dcf5f8..b20bb35a82fd8a 100644 --- a/var/spack/repos/builtin/packages/mpfr/package.py +++ b/var/spack/repos/builtin/packages/mpfr/package.py @@ -30,6 +30,8 @@ class Mpfr(AutotoolsPackage, GNUMirrorPackage): version("3.1.3", sha256="f63bb459157cacd223caac545cb816bcdb5a0de28b809e7748b82e9eb89b0afd") version("3.1.2", sha256="79c73f60af010a30a5c27a955a1d2d01ba095b72537dab0ecaad57f5a7bb1b6b") + depends_on("c", type="build") # generated + # mpir is a drop-in replacement for gmp depends_on("gmp@4.1:") # 4.2.3 or higher is recommended depends_on("gmp@5.0:", when="@4.0.0:") # https://www.mpfr.org/mpfr-4.0.0/ diff --git a/var/spack/repos/builtin/packages/mpi-bash/package.py b/var/spack/repos/builtin/packages/mpi-bash/package.py index d55940a6eaf2ab..bd29bcf73382c7 100644 --- a/var/spack/repos/builtin/packages/mpi-bash/package.py +++ b/var/spack/repos/builtin/packages/mpi-bash/package.py @@ -16,6 +16,8 @@ class MpiBash(AutotoolsPackage): version("1.3", sha256="ab39dcc0eadce765abaf685e73d38f4351e3229fdb4302aee4b9e6e70d431d99") version("1.2", sha256="5c2faaa74464111205dbae4799bd89c2425810ec3708d004237b42d620c8be57") + depends_on("c", type="build") # generated + depends_on("bash@4.4:") # uses MPI_Exscan which is in MPI-1.2 and later depends_on("mpi@1.2:") diff --git a/var/spack/repos/builtin/packages/mpi-serial/package.py b/var/spack/repos/builtin/packages/mpi-serial/package.py index 2d23ad8caa85b6..583bb56a6e8bea 100644 --- a/var/spack/repos/builtin/packages/mpi-serial/package.py +++ b/var/spack/repos/builtin/packages/mpi-serial/package.py @@ -20,6 +20,9 @@ class MpiSerial(AutotoolsPackage): version("2.5.0", sha256="2faf459ea1f37020662067e7ab6c76b926501c4b94e8fdf77591c0040ba1f006") version("2.3.0", sha256="cc55e6bf0ae5e1d93aafa31ba91bfc13e896642a511c3101695ea05eccf97988") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "fort-real-size", values=int, diff --git a/var/spack/repos/builtin/packages/mpi-test-suite/package.py b/var/spack/repos/builtin/packages/mpi-test-suite/package.py index 9c0e858778df4a..a07bbf86dc01d7 100644 --- a/var/spack/repos/builtin/packages/mpi-test-suite/package.py +++ b/var/spack/repos/builtin/packages/mpi-test-suite/package.py @@ -28,6 +28,8 @@ class MpiTestSuite(AutotoolsPackage): version("1.1.1", sha256="4cb7bdbdafa0855dab96d996f863b5d364c935e678c057ada3c8869c3666e926") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake@1.14:", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/mpibind/package.py b/var/spack/repos/builtin/packages/mpibind/package.py index 34910ae2010a75..945422c3a9b530 100644 --- a/var/spack/repos/builtin/packages/mpibind/package.py +++ b/var/spack/repos/builtin/packages/mpibind/package.py @@ -30,6 +30,9 @@ class Mpibind(AutotoolsPackage): version("0.7.0", commit="3c437a97cd841b9c13abfbe1062a0285e1a29d3e", no_cache=True) version("0.5.0", commit="8698f07412232e4dd4de4802b508374dc0de48c9", no_cache=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cuda", default=False, description="Build w/support for NVIDIA GPUs.") variant("rocm", default=False, description="Build w/support for AMD GPUs.") variant("flux", default=False, description="Build the Flux plugin.") diff --git a/var/spack/repos/builtin/packages/mpich/package.py b/var/spack/repos/builtin/packages/mpich/package.py index 61967ab917094a..5711ed72ff9949 100644 --- a/var/spack/repos/builtin/packages/mpich/package.py +++ b/var/spack/repos/builtin/packages/mpich/package.py @@ -27,9 +27,12 @@ class Mpich(AutotoolsPackage, CudaPackage, ROCmPackage): keep_werror = "specific" - license("Unlicense") + license("mpich2") version("develop", submodules=True) + version("4.2.2", sha256="883f5bb3aeabf627cb8492ca02a03b191d09836bbe0f599d8508351179781d41") + version("4.2.1", sha256="23331b2299f287c3419727edc2df8922d7e7abbb9fd0ac74e03b9966f9ad42d7") + version("4.2.0", sha256="a64a66781b9e5312ad052d32689e23252f745b27ee8818ac2ac0c8209bc0b90e") version("4.1.2", sha256="3492e98adab62b597ef0d292fb2459b6123bc80070a8aa0a30be6962075a12f0") version("4.1.1", sha256="ee30471b35ef87f4c88f871a5e2ad3811cd9c4df32fd4f138443072ff4284ca2") version("4.1", sha256="8b1ec63bc44c7caa2afbb457bc5b3cd4a70dbe46baba700123d67c48dc5ab6a0") @@ -53,6 +56,10 @@ class Mpich(AutotoolsPackage, CudaPackage, ROCmPackage): version("3.1", sha256="fcf96dbddb504a64d33833dc455be3dda1e71c7b3df411dfcf9df066d7c32c39") version("3.0.4", sha256="cf638c85660300af48b6f776e5ecd35b5378d5905ec5d34c3da7a27da0acf0b3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("hwloc", default=True, description="Use external hwloc package") variant("hydra", default=True, description="Build the hydra process manager") variant("romio", default=True, description="Enable ROMIO MPI I/O implementation") @@ -61,9 +68,9 @@ class Mpich(AutotoolsPackage, CudaPackage, ROCmPackage): variant("wrapperrpath", default=True, description="Enable wrapper rpath") variant( "pmi", - default="pmi", + default="default", description="""PMI interface.""", - values=("pmi", "pmi2", "pmix", "cray"), + values=("default", "pmi", "pmi2", "pmix", "cray"), multi=False, ) variant( @@ -137,6 +144,9 @@ class Mpich(AutotoolsPackage, CudaPackage, ROCmPackage): ) depends_on("hcoll", when="+hcoll") + variant("xpmem", default=False, when="@3.4:", description="Enable XPMEM support") + depends_on("xpmem", when="+xpmem") + # Todo: cuda can be a conditional variant, but it does not seem to work when # overriding the variant from CudaPackage. conflicts("+cuda", when="@:3.3") @@ -385,10 +395,16 @@ def is_disabled(text): if re.search(r"--with-thread-package=argobots", output): variants.append("+argobots") + if re.search(r"--with-pmi=default", output): + variants.append("pmi=default") elif re.search(r"--with-pmi=simple", output): variants.append("pmi=pmi") elif re.search(r"--with-pmi=pmi2/simple", output): variants.append("pmi=pmi2") + elif re.search(r"--with-pmi=pmi", output): + variants.append("pmi=pmi") + elif re.search(r"--with-pmi=pmi2", output): + variants.append("pmi=pmi2") elif re.search(r"--with-pmix", output): variants.append("pmi=pmix") @@ -437,47 +453,28 @@ def setup_build_environment(self, env): def setup_run_environment(self, env): # Because MPI implementations provide compilers, they have to add to # their run environments the code to make the compilers available. - # For Cray MPIs, the regular compiler wrappers *are* the MPI wrappers. - # Cray MPIs always have cray in the module name, e.g. "cray-mpich" - if self.spec.satisfies("platform=cray"): - # This is intended to support external MPICH instances registered - # by Spack on Cray machines prior to a879c87; users defining an - # external MPICH entry for Cray should generally refer to the - # "cray-mpich" package - env.set("MPICC", spack_cc) - env.set("MPICXX", spack_cxx) - env.set("MPIF77", spack_fc) - env.set("MPIF90", spack_fc) - else: - env.set("MPICC", join_path(self.prefix.bin, "mpicc")) - env.set("MPICXX", join_path(self.prefix.bin, "mpic++")) - env.set("MPIF77", join_path(self.prefix.bin, "mpif77")) - env.set("MPIF90", join_path(self.prefix.bin, "mpif90")) + env.set("MPICC", join_path(self.prefix.bin, "mpicc")) + env.set("MPICXX", join_path(self.prefix.bin, "mpic++")) + env.set("MPIF77", join_path(self.prefix.bin, "mpif77")) + env.set("MPIF90", join_path(self.prefix.bin, "mpif90")) def setup_dependent_build_environment(self, env, dependent_spec): - env.set("MPICH_CC", spack_cc) - env.set("MPICH_CXX", spack_cxx) - env.set("MPICH_F77", spack_f77) - env.set("MPICH_F90", spack_fc) - env.set("MPICH_FC", spack_fc) + dependent_module = dependent_spec.package.module + env.set("MPICH_CC", dependent_module.spack_cc) + env.set("MPICH_CXX", dependent_module.spack_cxx) + env.set("MPICH_F77", dependent_module.spack_f77) + env.set("MPICH_F90", dependent_module.spack_fc) + env.set("MPICH_FC", dependent_module.spack_fc) def setup_dependent_package(self, module, dependent_spec): spec = self.spec - # For Cray MPIs, the regular compiler wrappers *are* the MPI wrappers. - # Cray MPIs always have cray in the module name, e.g. "cray-mpich" - if self.spec.satisfies("platform=cray"): - spec.mpicc = spack_cc - spec.mpicxx = spack_cxx - spec.mpifc = spack_fc - spec.mpif77 = spack_f77 - else: - spec.mpicc = join_path(self.prefix.bin, "mpicc") - spec.mpicxx = join_path(self.prefix.bin, "mpic++") + spec.mpicc = join_path(self.prefix.bin, "mpicc") + spec.mpicxx = join_path(self.prefix.bin, "mpic++") - if "+fortran" in spec: - spec.mpifc = join_path(self.prefix.bin, "mpif90") - spec.mpif77 = join_path(self.prefix.bin, "mpif77") + if "+fortran" in spec: + spec.mpifc = join_path(self.prefix.bin, "mpif90") + spec.mpif77 = join_path(self.prefix.bin, "mpif77") spec.mpicxx_shared_libs = [ join_path(self.prefix.lib, "libmpicxx.{0}".format(dso_suffix)), @@ -551,16 +548,32 @@ def configure_args(self): else: config_args.append("--with-slurm=no") - if "pmi=off" in spec: - config_args.append("--with-pmi=no") - elif "pmi=pmi" in spec: - config_args.append("--with-pmi=simple") - elif "pmi=pmi2" in spec: - config_args.append("--with-pmi=pmi2/simple") - elif "pmi=pmix" in spec: - config_args.append("--with-pmix={0}".format(spec["pmix"].prefix)) - elif "pmi=cray" in spec: - config_args.append("--with-pmi=cray") + # PMI options changed in 4.2.0 + if spec.satisfies("@4.2:"): + # default (no option) is to build both PMIv1 and PMI2 client interfaces + if "pmi=pmi" in spec: + # make PMI1 the default client interface + config_args.append("--with-pmi=pmi") + elif "pmi=pmi2" in spec: + # make PMI2 the default client interface + config_args.append("--with-pmi=pmi2") + elif "pmi=pmix" in spec: + # use the PMIx client interface with an external PMIx library + config_args.append("--with-pmi=pmix") + config_args.append(f"--with-pmix={spec['pmix'].prefix}") + elif "pmi=cray" in spec: + # use PMI2 interface of the Cray PMI library + config_args.append("--with-pmi=pmi2") + config_args.append(f"--with-pmi2={spec['cray-pmi'].prefix}") + else: + if "pmi=pmi" in spec: + config_args.append("--with-pmi=simple") + elif "pmi=pmi2" in spec: + config_args.append("--with-pmi=pmi2/simple") + elif "pmi=pmix" in spec: + config_args.append(f"--with-pmix={spec['pmix'].prefix}") + elif "pmi=cray" in spec: + config_args.append("--with-pmi=cray") if "+cuda" in spec: config_args.append("--with-cuda={0}".format(spec["cuda"].prefix)) @@ -627,6 +640,9 @@ def configure_args(self): if "+hcoll" in spec: config_args.append("--with-hcoll=" + spec["hcoll"].prefix) + if "+xpmem" in spec: + config_args.append("--with-xpmem=" + spec["xpmem"].prefix) + return config_args @run_after("install") diff --git a/var/spack/repos/builtin/packages/mpifileutils/package.py b/var/spack/repos/builtin/packages/mpifileutils/package.py index 5b23f1dd1c3bad..2d51b9425ec3c6 100644 --- a/var/spack/repos/builtin/packages/mpifileutils/package.py +++ b/var/spack/repos/builtin/packages/mpifileutils/package.py @@ -6,7 +6,7 @@ from spack.package import * -class Mpifileutils(Package): +class Mpifileutils(CMakePackage): """mpiFileUtils is a suite of MPI-based tools to manage large datasets, which may vary from large directory trees to large files. High-performance computing users often generate large datasets with @@ -32,17 +32,23 @@ class Mpifileutils(Package): version("0.9.1", sha256="15a22450f86b15e7dc4730950b880fda3ef6f59ac82af0b268674d272aa61c69") version("0.9", sha256="1b8250af01aae91c985ca5d61521bfaa4564e46efa15cee65cd0f82cf5a2bcfb") + depends_on("c", type="build") # generated + + variant("xattr", default=True, description="Enable code for extended attributes") + variant("lustre", default=False, description="Enable optimizations and features for Lustre") + variant("gpfs", default=False, description="Enable optimizations and features for GPFS") + variant("experimental", default=False, description="Install experimental tools") + variant("daos", default=False, description="Enable DAOS support", when="@0.11:") + patch("nosys_getdents.patch", when="@:0.10.1 target=aarch64:") conflicts("platform=darwin") depends_on("mpi") - depends_on("libcircle@0.3:") + depends_on("libcircle") - # need precise version of dtcmp, since DTCMP_Segmented_exscan added - # in v1.0.3 but renamed in v1.1.0 and later - depends_on("dtcmp@1.0.3", when="@:0.7") - depends_on("dtcmp@1.1.0:", when="@0.8:") + # DTCMP_Segmented_exscan renamed in v1.1.0 + depends_on("dtcmp@1.1.0:") # fixes were added to libarchive somewhere between 3.1.2 and 3.5.0 # which helps with file names that start with "._", bumping to newer @@ -51,28 +57,11 @@ class Mpifileutils(Package): depends_on("libarchive@3.5.1:", when="@0.11:") depends_on("attr", when="@0.11.1:+xattr") - depends_on("daos", when="+daos") - depends_on("bzip2") - depends_on("libcap") - depends_on("openssl") - - depends_on("cmake@3.1:", when="@0.9:", type="build") - - variant("xattr", default=True, description="Enable code for extended attributes") - - variant("lustre", default=False, description="Enable optimizations and features for Lustre") - - variant("gpfs", default=False, description="Enable optimizations and features for GPFS") - conflicts("+gpfs", when="@:0.8.1") - - variant("experimental", default=False, description="Install experimental tools") - conflicts("+experimental", when="@:0.6") - - variant("daos", default=False, description="Enable DAOS support", when="@0.11:") + depends_on("cmake@3.1:", type="build") def flag_handler(self, name, flags): spec = self.spec @@ -83,92 +72,19 @@ def flag_handler(self, name, flags): return (iflags, None, None) def cmake_args(self): - args = std_cmake_args - args.append("-DCMAKE_INSTALL_PREFIX=%s" % self.spec.prefix) - args.append("-DWITH_DTCMP_PREFIX=%s" % self.spec["dtcmp"].prefix) - args.append("-DWITH_LibCircle_PREFIX=%s" % self.spec["libcircle"].prefix) - - if self.spec.satisfies("+xattr"): - args.append("-DENABLE_XATTRS=ON") - else: - args.append("-DENABLE_XATTRS=OFF") - - if self.spec.satisfies("+lustre"): - args.append("-DENABLE_LUSTRE=ON") - else: - args.append("-DENABLE_LUSTRE=OFF") - - if self.spec.satisfies("+gpfs"): - args.append("-DENABLE_GPFS=ON") - else: - args.append("-DENABLE_GPFS=OFF") - - if self.spec.satisfies("+experimental"): - args.append("-DENABLE_EXPERIMENTAL=ON") - else: - args.append("-DENABLE_EXPERIMENTAL=OFF") + args = [ + self.define("WITH_DTCMP_PREFIX", self.spec["dtcmp"].prefix), + self.define("WITH_LibCircle_PREFIX", self.spec["libcircle"].prefix), + self.define_from_variant("ENABLE_XATTRS", "xattr"), + self.define_from_variant("ENABLE_LUSTRE", "lustre"), + self.define_from_variant("ENABLE_GPFS", "gpfs"), + self.define_from_variant("ENABLE_EXPERIMENTAL", "experimental"), + ] if self.spec.satisfies("+daos"): - args.append("-DENABLE_DAOS=ON") - args.append("-DWITH_DAOS_PREFIX=%s" % self.spec["daos"].prefix) + args.append(self.define("ENABLE_DAOS", True)) + args.append(self.define("WITH_DAOS_PREFIX", self.spec["daos"].prefix)) else: - args.append("-DENABLE_DAOS=OFF") + args.append(self.define("ENABLE_DAOS", False)) return args - - @when("@0.9:") - def install(self, spec, prefix): - args = self.cmake_args() - - source_directory = self.stage.source_path - build_directory = join_path(source_directory, "build") - - with working_dir(build_directory, create=True): - cmake(source_directory, *args) - make() - make("install") - - if self.run_tests: - make("test") - - def configure_args(self): - args = [] - args.append("--prefix=%s" % self.spec.prefix) - args.append("CPPFLAGS=-I%s/src/common" % pwd()) - args.append("libarchive_CFLAGS=-I%s" % self.spec["libarchive"].prefix.include) - args.append( - "libarchive_LIBS=%s %s" - % (self.spec["libarchive"].libs.search_flags, self.spec["libarchive"].libs.link_flags) - ) - args.append("libcircle_CFLAGS=-I%s" % self.spec["libcircle"].prefix.include) - args.append( - "libcircle_LIBS=%s %s" - % (self.spec["libcircle"].libs.search_flags, self.spec["libcircle"].libs.link_flags) - ) - args.append("--with-dtcmp=%s" % self.spec["dtcmp"].prefix) - - if self.spec.satisfies("+xattr"): - args.append("CFLAGS=-DDCOPY_USE_XATTRS") - - if self.spec.satisfies("+lustre"): - args.append("--enable-lustre") - else: - args.append("--disable-lustre") - - if self.spec.satisfies("@0.7:"): - if self.spec.satisfies("+experimental"): - args.append("--enable-experimental") - else: - args.append("--disable-experimental") - return args - - @when("@:0.8.1") - def install(self, spec, prefix): - args = self.configure_args() - - configure(*args) - make() - make("install") - - if self.run_tests: - make("test") diff --git a/var/spack/repos/builtin/packages/mpilander/package.py b/var/spack/repos/builtin/packages/mpilander/package.py index 587b5e65d04860..5df4b63c2d22d7 100644 --- a/var/spack/repos/builtin/packages/mpilander/package.py +++ b/var/spack/repos/builtin/packages/mpilander/package.py @@ -18,6 +18,9 @@ class Mpilander(CMakePackage): version("develop", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # variant('cuda', default=False, description='Enable CUDA support') # variant( # 'schedulers', diff --git a/var/spack/repos/builtin/packages/mpileaks/package.py b/var/spack/repos/builtin/packages/mpileaks/package.py index 8c07e68ae645f4..89da44e32e5d9d 100644 --- a/var/spack/repos/builtin/packages/mpileaks/package.py +++ b/var/spack/repos/builtin/packages/mpileaks/package.py @@ -15,6 +15,10 @@ class Mpileaks(AutotoolsPackage): version("1.0", sha256="2e34cc4505556d1c1f085758e26f2f8eea0972db9382f051b2dcfb1d7d9e1825") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "stackstart", values=int, diff --git a/var/spack/repos/builtin/packages/mpip/package.py b/var/spack/repos/builtin/packages/mpip/package.py index c7628f07d62f00..4eed14cde543d8 100644 --- a/var/spack/repos/builtin/packages/mpip/package.py +++ b/var/spack/repos/builtin/packages/mpip/package.py @@ -19,6 +19,10 @@ class Mpip(AutotoolsPackage): version("master", branch="master") version("3.5", sha256="e366843d53fa016fb03903e51c8aac901aa5155edabe64698a8d6fa618a03bbd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("demangling", default=True, description="Build with demangling support") variant("setjmp", default=False, description="Use setjmp to generate stack trace") diff --git a/var/spack/repos/builtin/packages/mpir/package.py b/var/spack/repos/builtin/packages/mpir/package.py index ac0d0d41ab5d2c..830d12cdfda386 100644 --- a/var/spack/repos/builtin/packages/mpir/package.py +++ b/var/spack/repos/builtin/packages/mpir/package.py @@ -19,6 +19,9 @@ class Mpir(Package): version("2.7.0", sha256="2d0174aaccff918766215df00420f12929a6c376ab4e558af31f57c55193bcb7") version("2.6.0", sha256="dedb336098d41d4e298909586cf351003bcd7aad9317e801f3e4c4838f6d7691") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # This setting allows mpir to act as a drop-in replacement for gmp variant("gmp_compat", default=False, description="Compile with GMP library compatibility") diff --git a/var/spack/repos/builtin/packages/mpitrampoline/package.py b/var/spack/repos/builtin/packages/mpitrampoline/package.py index 39fa57564d5903..11cec3916086c8 100644 --- a/var/spack/repos/builtin/packages/mpitrampoline/package.py +++ b/var/spack/repos/builtin/packages/mpitrampoline/package.py @@ -59,6 +59,9 @@ class Mpitrampoline(CMakePackage): version("1.1.0", sha256="67fdb710d1ca49487593a9c023e94aa8ff0bec56de6005d1a437fca40833def9") version("1.0.1", sha256="4ce91b99fb6d2dab481b5e477b6b6a0709add48cf0f287afbbb440fdf3232500") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Build a shared version of the library") provides("mpi @3.1") @@ -90,10 +93,11 @@ def setup_run_environment(self, env): env.set("MPIF90", join_path(self.prefix.bin, "mpifc")) def setup_dependent_build_environment(self, env, dependent_spec): + dependent_module = dependent_spec.package.module # Use the Spack compiler wrappers under MPI - env.set("MPITRAMPOLINE_CC", spack_cc) - env.set("MPITRAMPOLINE_CXX", spack_cxx) - env.set("MPITRAMPOLINE_FC", spack_fc) + env.set("MPITRAMPOLINE_CC", dependent_module.spack_cc) + env.set("MPITRAMPOLINE_CXX", dependent_module.spack_cxx) + env.set("MPITRAMPOLINE_FC", dependent_module.spack_fc) fflags = [] if ( self.spec.satisfies("%apple-clang") diff --git a/var/spack/repos/builtin/packages/mpiwrapper/package.py b/var/spack/repos/builtin/packages/mpiwrapper/package.py index 50d18fc57f77be..2b6f7e9edd31a7 100644 --- a/var/spack/repos/builtin/packages/mpiwrapper/package.py +++ b/var/spack/repos/builtin/packages/mpiwrapper/package.py @@ -39,4 +39,7 @@ class Mpiwrapper(CMakePackage): version("2.0.0", sha256="cdc81f3fae459569d4073d99d068810689a19cf507d9c4e770fa91e93650dbe4") version("1.0.1", sha256="29d5499a1a7a358d69dd744c581e57cac9223ebde94b52fa4a2b98c730ad47ff") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi @3.1:") diff --git a/var/spack/repos/builtin/packages/mpix-launch-swift/package.py b/var/spack/repos/builtin/packages/mpix-launch-swift/package.py index d8b9b59f61a672..a25f1ca57685aa 100644 --- a/var/spack/repos/builtin/packages/mpix-launch-swift/package.py +++ b/var/spack/repos/builtin/packages/mpix-launch-swift/package.py @@ -16,6 +16,8 @@ class MpixLaunchSwift(MakefilePackage): version("develop", branch="envs") + depends_on("c", type="build") # generated + depends_on("stc") depends_on("tcl") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/mpl/package.py b/var/spack/repos/builtin/packages/mpl/package.py index f39c81c76d7580..bff77e0465b6bd 100644 --- a/var/spack/repos/builtin/packages/mpl/package.py +++ b/var/spack/repos/builtin/packages/mpl/package.py @@ -22,4 +22,7 @@ class Mpl(CMakePackage): version("0.2.0", tag="v0.2.0", commit="f322352c93627c1b91d8efb1c4ee2e4873aed016") version("0.1", tag="v0.1", commit="970d0f3436ddbfcf2eba12c5bc7f4f7660e433ca") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/mppp/package.py b/var/spack/repos/builtin/packages/mppp/package.py index 2c302ad3744804..ef4a7fbb2e8347 100644 --- a/var/spack/repos/builtin/packages/mppp/package.py +++ b/var/spack/repos/builtin/packages/mppp/package.py @@ -30,6 +30,8 @@ class Mppp(CMakePackage): version("0.21", sha256="49a05fc6874a800cb42a3ac16eb46a50583f0b59d3b54008c58af766186a8c69") version("0.20", sha256="c736daeaac30e38e1c09a19d249209ad49f8ec92ab1315a8fb9a47cc1f54e607") + depends_on("cxx", type="build") # generated + variant( "mpfr", default=True, diff --git a/var/spack/repos/builtin/packages/mpt/package.py b/var/spack/repos/builtin/packages/mpt/package.py index 7a1a01e482b5f2..1a45de40a09513 100644 --- a/var/spack/repos/builtin/packages/mpt/package.py +++ b/var/spack/repos/builtin/packages/mpt/package.py @@ -36,9 +36,10 @@ def libs(self): def setup_dependent_build_environment(self, env, dependent_spec): # use the Spack compiler wrappers under MPI - env.set("MPICC_CC", spack_cc) - env.set("MPICXX_CXX", spack_cxx) - env.set("MPIF90_F90", spack_fc) + dependent_module = dependent_spec.package.module + env.set("MPICC_CC", dependent_module.spack_cc) + env.set("MPICXX_CXX", dependent_module.spack_cxx) + env.set("MPIF90_F90", dependent_module.spack_fc) def setup_run_environment(self, env): # Because MPI is both runtime and compiler, we have to setup the mpi @@ -49,13 +50,7 @@ def setup_run_environment(self, env): env.set("MPIF90", self.prefix.bin.mpif90) def setup_dependent_package(self, module, dependent_spec): - if "platform=cray" in self.spec: - self.spec.mpicc = spack_cc - self.spec.mpicxx = spack_cxx - self.spec.mpifc = spack_fc - self.spec.mpif77 = spack_f77 - else: - self.spec.mpicc = self.prefix.bin.mpicc - self.spec.mpicxx = self.prefix.bin.mpicxx - self.spec.mpifc = self.prefix.bin.mpif90 - self.spec.mpif77 = self.prefix.bin.mpif77 + self.spec.mpicc = self.prefix.bin.mpicc + self.spec.mpicxx = self.prefix.bin.mpicxx + self.spec.mpifc = self.prefix.bin.mpif90 + self.spec.mpif77 = self.prefix.bin.mpif77 diff --git a/var/spack/repos/builtin/packages/mptensor/package.py b/var/spack/repos/builtin/packages/mptensor/package.py index 3fcae8fc5be9a9..5e243f1298a3ed 100644 --- a/var/spack/repos/builtin/packages/mptensor/package.py +++ b/var/spack/repos/builtin/packages/mptensor/package.py @@ -17,6 +17,8 @@ class Mptensor(CMakePackage): version("0.3.0", sha256="819395a91551bddb77958615042fcb935a4b67ee37f912b9a2ca5b49c71befae") + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Build with MPI library") variant("doc", default=False, description="build documentation with Doxygen") diff --git a/var/spack/repos/builtin/packages/mrbayes/package.py b/var/spack/repos/builtin/packages/mrbayes/package.py index ee3c846408c931..2cc9a68589e14d 100644 --- a/var/spack/repos/builtin/packages/mrbayes/package.py +++ b/var/spack/repos/builtin/packages/mrbayes/package.py @@ -20,6 +20,8 @@ class Mrbayes(AutotoolsPackage): version("3.2.7a", sha256="1a4670be84e6b968d59382328294db4c8ceb73e0c19c702265deec6f2177815c") version("3.2.7", sha256="39d9eb269969b501268d5c27f77687c6eaa2c71ccf15c724e6f330fc405f24b9") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Enable MPI parallel support") variant("beagle", default=True, description="Enable BEAGLE library for speed benefits") variant( diff --git a/var/spack/repos/builtin/packages/mrchem/package.py b/var/spack/repos/builtin/packages/mrchem/package.py index c73484c0f6f111..ada2c70ad9be50 100644 --- a/var/spack/repos/builtin/packages/mrchem/package.py +++ b/var/spack/repos/builtin/packages/mrchem/package.py @@ -25,6 +25,8 @@ class Mrchem(CMakePackage): version("0.2.0", sha256="eea223db8275f9f2ce09601088264ec952ce2557a7050466301f53070ab03b82") version("0.1.0", sha256="325fa45fe1918b4d394060f36d23432ab8139596ebc22b65b1284c1f673e8164") + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Enable OpenMP support.") variant("mpi", default=True, description="Enable MPI support") diff --git a/var/spack/repos/builtin/packages/mrcpp/package.py b/var/spack/repos/builtin/packages/mrcpp/package.py index 46dfbe6eef04b7..05a94892def7df 100644 --- a/var/spack/repos/builtin/packages/mrcpp/package.py +++ b/var/spack/repos/builtin/packages/mrcpp/package.py @@ -33,6 +33,8 @@ class Mrcpp(CMakePackage): version("1.0.1", sha256="b4d7120545da3531bc7aa0a4cb4eb579fdbe1f8e5d32b1fd1086976583e3e27c") version("1.0.0", sha256="0858146141d3a60232e8874380390f9e9fa0b1bd6e67099d5833704478213efd") + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Enable OpenMP support.") variant("mpi", default=True, description="Enable MPI support") diff --git a/var/spack/repos/builtin/packages/mrnet/package.py b/var/spack/repos/builtin/packages/mrnet/package.py index 16be03143c6de0..a27b7bfa057486 100644 --- a/var/spack/repos/builtin/packages/mrnet/package.py +++ b/var/spack/repos/builtin/packages/mrnet/package.py @@ -25,6 +25,9 @@ class Mrnet(AutotoolsPackage): version("4.1.0", sha256="94758191ac46a9dbfea931a8e61167fe7e8a5f880caa418305c44f1d12af5e45") version("4.0.0", sha256="7207c6d493b3f17c386667cfefa81364c96b9c8b831c67442d218d77813c5d38") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("lwthreads", default=False, description="Also build the MRNet LW threadsafe libraries") parallel = False diff --git a/var/spack/repos/builtin/packages/mrtrix3/package.py b/var/spack/repos/builtin/packages/mrtrix3/package.py index a5a2b1183188c7..38e8b7b6c0b81b 100644 --- a/var/spack/repos/builtin/packages/mrtrix3/package.py +++ b/var/spack/repos/builtin/packages/mrtrix3/package.py @@ -26,6 +26,8 @@ class Mrtrix3(Package): version("3.0.3", sha256="6ec7d5a567d8d7338e85575a74565189a26ec8971cbe8fb24a49befbc446542e") version("2017-09-25", commit="72aca89e3d38c9d9e0c47104d0fb5bd2cbdb536d") + depends_on("cxx", type="build") # generated + depends_on("python@2.7:", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) depends_on("glu") diff --git a/var/spack/repos/builtin/packages/mruby/package.py b/var/spack/repos/builtin/packages/mruby/package.py index 05a7f30f34a3fb..1bab29eb63157a 100644 --- a/var/spack/repos/builtin/packages/mruby/package.py +++ b/var/spack/repos/builtin/packages/mruby/package.py @@ -25,6 +25,9 @@ class Mruby(Package): version("2.1.1", sha256="bb27397ee9cb7e0ddf4ff51caf5b0a193d636b7a3c52399684c8c383b41c362a") version("2.1.0", sha256="d6733742a07e553c52ab71df08b0604b3b571768bbc0c2729fbf0389d1bb5d13") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cxx_exception", description="Enable C++ exceptions", default=False, when="@3.1.0:") depends_on("ruby@3.0.0:", type=("build")) diff --git a/var/spack/repos/builtin/packages/mscgen/package.py b/var/spack/repos/builtin/packages/mscgen/package.py index aae65bc5e9ebf4..6f533395bab020 100644 --- a/var/spack/repos/builtin/packages/mscgen/package.py +++ b/var/spack/repos/builtin/packages/mscgen/package.py @@ -17,6 +17,8 @@ class Mscgen(AutotoolsPackage): version("0.20", sha256="3c3481ae0599e1c2d30b7ed54ab45249127533ab2f20e768a0ae58d8551ddc23") + depends_on("c", type="build") # generated + depends_on("flex") depends_on("bison") depends_on("pkgconfig") diff --git a/var/spack/repos/builtin/packages/msgpack-c/package.py b/var/spack/repos/builtin/packages/msgpack-c/package.py index f8a041fbc72a9b..223e639108da1c 100644 --- a/var/spack/repos/builtin/packages/msgpack-c/package.py +++ b/var/spack/repos/builtin/packages/msgpack-c/package.py @@ -16,15 +16,24 @@ class MsgpackC(CMakePackage): version("3.1.1", sha256="bda49f996a73d2c6080ff0523e7b535917cd28c8a79c3a5da54fc29332d61d1e") version("3.0.1", sha256="1b834ab0b5b41da1dbfb96dd4a673f6de7e79dbd7f212f45a553ff9cc54abf3b") - version("1.4.1", sha256="74324d696f9abb75d8a7cd5e77add5062592b7eac386c8102de78a6cc5309886") - - depends_on("cmake@2.8.12:", type="build") + version( + "1.4.1", + sha256="74324d696f9abb75d8a7cd5e77add5062592b7eac386c8102de78a6cc5309886", + deprecated=True, + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + depends_on("boost", when="@4:") + depends_on("cmake@2.8.0:", type="build") + depends_on("cmake@3.1.0:", type="build", when="@4:") depends_on("googletest", type="test") def cmake_args(self): args = [ - "-DCMAKE_CXX_FLAGS=-Wno-implicit-fallthrough", - "-DCMAKE_C_FLAGS=-Wno-implicit-fallthrough", + self.define("CMAKE_CXX_FLAGS", "-Wno-implicit-fallthrough"), + self.define("CMAKE_C_FLAGS", "-Wno-implicit-fallthrough"), self.define("MSGPACK_BUILD_TESTS", self.run_tests), ] return args diff --git a/var/spack/repos/builtin/packages/mshadow/package.py b/var/spack/repos/builtin/packages/mshadow/package.py index 652c454f5d7d6a..fdb61f72d8af40 100644 --- a/var/spack/repos/builtin/packages/mshadow/package.py +++ b/var/spack/repos/builtin/packages/mshadow/package.py @@ -18,6 +18,8 @@ class Mshadow(Package): version("master", branch="master") version("20170721", commit="20b54f068c1035f0319fa5e5bbfb129c450a5256") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): install_tree("mshadow", prefix.include.mshadow) install_tree("make", prefix.make) diff --git a/var/spack/repos/builtin/packages/msmpi/package.py b/var/spack/repos/builtin/packages/msmpi/package.py index 5d05dd2c25d66e..eccb88f0c1a027 100644 --- a/var/spack/repos/builtin/packages/msmpi/package.py +++ b/var/spack/repos/builtin/packages/msmpi/package.py @@ -24,6 +24,9 @@ class Msmpi(Package): version("10.1.1", sha256="63c7da941fc4ffb05a0f97bd54a67968c71f63389a0d162d3182eabba1beab3d") version("10.0.0", sha256="cfb53cf53c3cf0d4935ab58be13f013a0f7ccb1189109a5b8eea0fcfdcaef8c1") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + provides("mpi") depends_on("win-wdk") @@ -41,14 +44,14 @@ def determine_version(cls, exe): return Version(ver_str.group(1)) if ver_str else None def setup_dependent_package(self, module, dependent_spec): - spec = self.spec # MSMPI does not vendor compiler wrappers, instead arguments should # be manually supplied to compiler by consuming package # Note: This is not typical of MPI installations - spec.mpicc = spack_cc - spec.mpicxx = spack_cxx - spec.mpifc = spack_fc - spec.mpif77 = spack_f77 + dependent_module = dependent_spec.package.module + self.spec.mpicc = dependent_module.spack_cc + self.spec.mpicxx = dependent_module.spack_cxx + self.spec.mpifc = dependent_module.spack_fc + self.spec.mpif77 = dependent_module.spack_f77 class GenericBuilder(GenericBuilder): diff --git a/var/spack/repos/builtin/packages/mstk/package.py b/var/spack/repos/builtin/packages/mstk/package.py index 5cc0be5f178b97..47af70a42f7f2b 100644 --- a/var/spack/repos/builtin/packages/mstk/package.py +++ b/var/spack/repos/builtin/packages/mstk/package.py @@ -49,6 +49,9 @@ class Mstk(CMakePackage): version("3.0.1", sha256="d44e4bf01b118b1d19710aa839b3f5f0c1a8391264a435f641ba4bd23bcf45ec") version("3.0.0", sha256="d993ff5fc6c431067eb97e4089835c7790397d9c1ad88a56523c0591d451df19") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("exodusii", default=False, description="Enable ExodusII") variant("use_markers", default=True, description="Enable use of markers") variant("parallel", default=False, description="Enable Parallel Support") diff --git a/var/spack/repos/builtin/packages/msvc/detection_test.yaml b/var/spack/repos/builtin/packages/msvc/detection_test.yaml new file mode 100644 index 00000000000000..9ece6297aceea9 --- /dev/null +++ b/var/spack/repos/builtin/packages/msvc/detection_test.yaml @@ -0,0 +1,14 @@ +paths: +- layout: + - executables: + - cl.bat + script: | + echo "Microsoft (R) C/C++ Optimizing Compiler Version 19.04.54321 for x86" + platforms: [windows] + results: + - spec: msvc@19.04.54321 + extra_attributes: + compilers: + c: ".*cl.bat$" + cxx: ".*cl.bat" + diff --git a/var/spack/repos/builtin/packages/msvc/package.py b/var/spack/repos/builtin/packages/msvc/package.py new file mode 100644 index 00000000000000..d58dea2f6bb652 --- /dev/null +++ b/var/spack/repos/builtin/packages/msvc/package.py @@ -0,0 +1,66 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +import re + +from spack.package import * + + +class Msvc(Package, CompilerPackage): + """ + Microsoft Visual C++ is a compiler for the C, C++, C++/CLI and C++/CX programming languages. + """ + + homepage = "https://visualstudio.microsoft.com/vs/features/cplusplus/" + + def install(self, spec, prefix): + raise InstallError( + "MSVC compilers are not installable with Spack, but can be " + "detected on a system where they are externally installed" + ) + + compiler_languages = ["c", "cxx"] + c_names = ["cl"] + cxx_names = ["cl"] + compiler_version_argument = "" + compiler_version_regex = r"([1-9][0-9]*\.[0-9]*\.[0-9]*)" + + @classmethod + def determine_version(cls, exe): + # MSVC compiler does not have a proper version argument + # Errors out and prints version info with no args + match = re.search( + cls.compiler_version_regex, + spack.compiler.get_compiler_version_output(exe, version_arg=None, ignore_errors=True), + ) + if match: + return match.group(1) + + @classmethod + def determine_variants(cls, exes, version_str): + # MSVC uses same executable for both languages + spec, extras = super().determine_variants(exes, version_str) + extras["compilers"]["c"] = extras["compilers"]["cxx"] + return spec, extras + + @property + def cc(self): + if self.spec.external: + return self.spec.extra_attributes["compilers"]["c"] + msg = "cannot retrieve C compiler [spec is not concrete]" + assert self.spec.concrete, msg + + @property + def cxx(self): + if self.spec.external: + return self.spec.extra_attributes["compilers"]["cxx"] + msg = "cannot retrieve C++ compiler [spec is not concrete]" + assert self.spec.concrete, msg + + @property + def fortran(self): + if self.spec.external: + return self.spec.extra_attributes["compilers"]["fortran"] + msg = "cannot retrieve Fortran compiler [spec is not concrete]" + assert self.spec.concrete, msg diff --git a/var/spack/repos/builtin/packages/mt-metis/package.py b/var/spack/repos/builtin/packages/mt-metis/package.py index 609c9634cc5cc5..acd534a79e1bb3 100644 --- a/var/spack/repos/builtin/packages/mt-metis/package.py +++ b/var/spack/repos/builtin/packages/mt-metis/package.py @@ -19,6 +19,9 @@ class MtMetis(CMakePackage): version("0.6.0", sha256="cb8fb836b630a899edbeca4e1da19ec9eb47e89903bda83e7ec62cb0ffdcc284") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # avoid asm('pause') for no x86_64 familly. patch("non_x8664.patch") diff --git a/var/spack/repos/builtin/packages/mtn/package.py b/var/spack/repos/builtin/packages/mtn/package.py index d92122211b6f96..3ea59dd9831da1 100644 --- a/var/spack/repos/builtin/packages/mtn/package.py +++ b/var/spack/repos/builtin/packages/mtn/package.py @@ -19,6 +19,8 @@ class Mtn(MakefilePackage): version("3.4.2", sha256="19b2076c00f5b0ad70c2467189b17f335c6e7ece5d1a01ed8910779f6a5ca52a") + depends_on("c", type="build") # generated + depends_on("ffmpeg") depends_on("libgd") diff --git a/var/spack/repos/builtin/packages/mujoco/package.py b/var/spack/repos/builtin/packages/mujoco/package.py index 44724042fff140..14868e203c0cd8 100644 --- a/var/spack/repos/builtin/packages/mujoco/package.py +++ b/var/spack/repos/builtin/packages/mujoco/package.py @@ -28,6 +28,9 @@ class Mujoco(Package): if pkg_sha256: version(ver, sha256=pkg_sha256) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): url = "https://mujoco.org/download/mujoco{0}-{1}-x86_64.tar.gz" diff --git a/var/spack/repos/builtin/packages/multitime/package.py b/var/spack/repos/builtin/packages/multitime/package.py index 38ce762525b305..497e2f841bf9fb 100644 --- a/var/spack/repos/builtin/packages/multitime/package.py +++ b/var/spack/repos/builtin/packages/multitime/package.py @@ -18,3 +18,5 @@ class Multitime(AutotoolsPackage): license("MIT") version("1.4", sha256="dd85c431c022d0b992f3a8816a1a3dfb414454a229c0ec22514761bf72d3ce47") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/multiverso/package.py b/var/spack/repos/builtin/packages/multiverso/package.py index 22b835323719c8..18ceee7aee1f52 100644 --- a/var/spack/repos/builtin/packages/multiverso/package.py +++ b/var/spack/repos/builtin/packages/multiverso/package.py @@ -20,6 +20,8 @@ class Multiverso(CMakePackage): version("143187", commit="143187575d1cfa410100037b8aea2e767e0af637") version("0.2", sha256="40e86543968faa2fe203cf0b004a4c7905303db0c860efe4ce4e1f27e46394fc") + depends_on("cxx", type="build") # generated + depends_on("mpi") depends_on("boost+exception+test") diff --git a/var/spack/repos/builtin/packages/mummer/package.py b/var/spack/repos/builtin/packages/mummer/package.py index a1e8f1b538cded..a9a1a7c877e9e3 100644 --- a/var/spack/repos/builtin/packages/mummer/package.py +++ b/var/spack/repos/builtin/packages/mummer/package.py @@ -16,6 +16,9 @@ class Mummer(Package): version("3.23", sha256="1efad4f7d8cee0d8eaebb320a2d63745bb3a160bb513a15ef7af46f330af662f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gnuplot") depends_on("perl", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/mummer4/package.py b/var/spack/repos/builtin/packages/mummer4/package.py index 122f4229dc42ac..98071ae52b5277 100644 --- a/var/spack/repos/builtin/packages/mummer4/package.py +++ b/var/spack/repos/builtin/packages/mummer4/package.py @@ -19,6 +19,8 @@ class Mummer4(AutotoolsPackage): "4.0.0beta2", sha256="cece76e418bf9c294f348972e5b23a0230beeba7fd7d042d5584ce075ccd1b93" ) + depends_on("cxx", type="build") # generated + conflicts("%gcc@:4.7") depends_on("perl@5.6.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/mumps/package.py b/var/spack/repos/builtin/packages/mumps/package.py index c048ce55eb9f39..7750547cd2b0a0 100644 --- a/var/spack/repos/builtin/packages/mumps/package.py +++ b/var/spack/repos/builtin/packages/mumps/package.py @@ -13,11 +13,12 @@ class Mumps(Package): """MUMPS: a MUltifrontal Massively Parallel sparse direct Solver""" - homepage = "https://graal.ens-lyon.fr/MUMPS/index.php" - url = "https://graal.ens-lyon.fr/MUMPS/MUMPS_5.5.1.tar.gz" + homepage = "https://mumps-solver.org/index.php" + url = "https://mumps-solver.org/MUMPS_5.5.1.tar.gz" maintainers("jcortial-safran") + version("5.7.2", sha256="1362d377ce7422fc886c55212b4a4d2c381918b5ca4478f682a22d0627a8fbf8") version("5.6.2", sha256="13a2c1aff2bd1aa92fe84b7b35d88f43434019963ca09ef7e8c90821a8f1d59a") version("5.6.1", sha256="1920426d543e34d377604070fde93b8d102aa38ebdf53300cbce9e15f92e2896") version("5.6.0", sha256="3e08c1bdea7aaaba303d3cf03059f3b4336fa49bef93f4260f478f067f518289") @@ -36,6 +37,9 @@ class Mumps(Package): # url='http://pkgs.fedoraproject.org/repo/pkgs/MUMPS/MUMPS_5.0.1.tar.gz/md5/b477573fdcc87babe861f62316833db0/MUMPS_5.0.1.tar.gz') version("5.0.1", sha256="50355b2e67873e2239b4998a46f2bbf83f70cdad6517730ab287ae3aae9340a0") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Compile MUMPS with MPI support") variant("scotch", default=False, description="Activate Scotch as a possible ordering library") variant( diff --git a/var/spack/repos/builtin/packages/munge/package.py b/var/spack/repos/builtin/packages/munge/package.py index a2dd177475f7ee..56584f7e3100fa 100644 --- a/var/spack/repos/builtin/packages/munge/package.py +++ b/var/spack/repos/builtin/packages/munge/package.py @@ -27,6 +27,8 @@ class Munge(AutotoolsPackage): url="https://github.com/dun/munge/releases/download/munge-0.5.11/munge-0.5.11.tar.bz2", ) + depends_on("c", type="build") # generated + variant( "localstatedir", default="PREFIX/var", diff --git a/var/spack/repos/builtin/packages/muparser/package.py b/var/spack/repos/builtin/packages/muparser/package.py index 3364f50a33da4f..6190b6280f6712 100644 --- a/var/spack/repos/builtin/packages/muparser/package.py +++ b/var/spack/repos/builtin/packages/muparser/package.py @@ -6,7 +6,7 @@ from spack.package import * -class Muparser(Package): +class Muparser(CMakePackage, Package): """C++ math expression parser library.""" homepage = "https://beltoforion.de/en/muparser/" @@ -18,25 +18,36 @@ class Muparser(Package): version("2.2.6.1", sha256="d2562853d972b6ddb07af47ce8a1cdeeb8bb3fa9e8da308746de391db67897b3") version("2.2.5", sha256="0666ef55da72c3e356ca85b6a0084d56b05dd740c3c21d26d372085aa2c6e708") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Replace std::auto_ptr by std::unique_ptr # https://github.com/beltoforion/muparser/pull/46 patch("auto_ptr.patch", when="@2.2.5") - depends_on("cmake@3.1.0:", when="@2.2.6:", type="build") - - # Cmake build since 2.2.6 - @when("@2.2.6:") - def install(self, spec, prefix): - cmake_args = ["-DENABLE_SAMPLES=OFF", "-DENABLE_OPENMP=OFF", "-DBUILD_SHARED_LIBS=ON"] - - cmake_args.extend(std_cmake_args) - - with working_dir("spack-build", create=True): - cmake("..", *cmake_args) - make() - make("install") + variant("samples", default=True, description="enable samples", when="build_system=cmake") + variant("openmp", default=True, description="enable OpenMP support", when="build_system=cmake") + variant( + "wide_char", + default=False, + description="enable wide character strings in place of ASCII", + when="build_system=cmake", + ) + variant("shared", default=True, description="enable shared libs", when="build_system=cmake") + + # Non-CMake build system is not supported by windows + conflicts("platform=windows", when="@:2.2.5") + build_system(conditional("cmake", when="@2.2.6:"), "generic", default="cmake") + + def cmake_args(self): + return [ + self.define_from_variant("ENABLE_SAMPLES", "samples"), + self.define_from_variant("ENABLE_OPENMP", "openmp"), + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + self.define_from_variant("ENABLE_WIDE_CHAR", "wide_char"), + ] - @when("@2.2.5") + @when("@:2.2.5") def install(self, spec, prefix): options = [ "--disable-debug", diff --git a/var/spack/repos/builtin/packages/muparserx/package.py b/var/spack/repos/builtin/packages/muparserx/package.py index a34b2ad55bb5e9..5d111cbc8bf8c1 100644 --- a/var/spack/repos/builtin/packages/muparserx/package.py +++ b/var/spack/repos/builtin/packages/muparserx/package.py @@ -18,3 +18,5 @@ class Muparserx(CMakePackage): version("4.0.12", sha256="941c79f9b8b924f2f22406af8587177b4b185da3c968dbe8dc371b9dbe117f6e") version("4.0.8", sha256="5913e0a4ca29a097baad1b78a4674963bc7a06e39ff63df3c73fbad6fadb34e1") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/muscle/package.py b/var/spack/repos/builtin/packages/muscle/package.py index 40460650b3f52c..caabc6ac748def 100644 --- a/var/spack/repos/builtin/packages/muscle/package.py +++ b/var/spack/repos/builtin/packages/muscle/package.py @@ -16,6 +16,8 @@ class Muscle(MakefilePackage): version("3.8.31", sha256="43c5966a82133bd7da5921e8142f2f592c2b5f53d802f0527a2801783af809ad") version("3.8.1551", sha256="c70c552231cd3289f1bad51c9bd174804c18bb3adcf47f501afec7a68f9c482e") + depends_on("cxx", type="build") # generated + @property def build_directory(self): if self.spec.satisfies("@3.8.31"): diff --git a/var/spack/repos/builtin/packages/muscle5/package.py b/var/spack/repos/builtin/packages/muscle5/package.py index 799bf1067468e7..87a140ad555853 100644 --- a/var/spack/repos/builtin/packages/muscle5/package.py +++ b/var/spack/repos/builtin/packages/muscle5/package.py @@ -20,6 +20,8 @@ class Muscle5(MakefilePackage): version("5.1.0", sha256="2bba8b06e3ccabf6465fa26f459763b2029d7e7b9596881063e3aaba60d9e87d") + depends_on("cxx", type="build") # generated + depends_on("sed", type="build") build_directory = "src" diff --git a/var/spack/repos/builtin/packages/muse/package.py b/var/spack/repos/builtin/packages/muse/package.py index e5f7928c988391..796f56168ede8a 100644 --- a/var/spack/repos/builtin/packages/muse/package.py +++ b/var/spack/repos/builtin/packages/muse/package.py @@ -16,6 +16,9 @@ class Muse(MakefilePackage): version("1.0-rc", sha256="b48b8be0044a2249bdc0b625fe0192c65089c598bbd1b1142902dfa81e804023") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api", type="link") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/music/package.py b/var/spack/repos/builtin/packages/music/package.py index 8c7ce2e50efdec..cc0cee2be4b6bf 100644 --- a/var/spack/repos/builtin/packages/music/package.py +++ b/var/spack/repos/builtin/packages/music/package.py @@ -23,6 +23,9 @@ class Music(CMakePackage): version("2021-12-01", commit="6747c54f3b73ec36719c265fd96362849a83cb45") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "hdf5", default=False, diff --git a/var/spack/repos/builtin/packages/musl/package.py b/var/spack/repos/builtin/packages/musl/package.py index 13ce939b41f403..aff44c3b94e505 100644 --- a/var/spack/repos/builtin/packages/musl/package.py +++ b/var/spack/repos/builtin/packages/musl/package.py @@ -25,9 +25,17 @@ class Musl(MakefilePackage): homepage = "https://www.musl-libc.org" url = "https://www.musl-libc.org/releases/musl-1.1.23.tar.gz" + tags = ["runtime"] license("MIT") + # This is used when the package is external and we need to find the actual default include path + # which may be in a multiarch subdir. + representative_headers = ["iso646.h"] + + provides("libc") + provides("iconv") + version("1.2.4", sha256="7a35eae33d5372a7c0da1188de798726f68825513b7ae3ebe97aaaa52114f039") version("1.2.3", sha256="7d5b0b6062521e4627e099e4c9dc8248d32a30285e959b7eecaa780cf8cfd4a4") version("1.2.2", sha256="9b969322012d796dc23dda27a35866034fa67d8fb67e0e2c45c913c3d43219dd") @@ -39,6 +47,8 @@ class Musl(MakefilePackage): version("1.1.21", sha256="c742b66f6f49c9e5f52f64d8b79fecb5a0f6e0203fca176c70ca20f6be285f44") version("1.1.20", sha256="44be8771d0e6c6b5f82dd15662eb2957c9a3173a19a8b49966ac0542bbd40d61") + depends_on("c", type="build") # generated + def patch(self): config = FileFilter("configure") if self.compiler.name == "gcc": @@ -59,3 +69,11 @@ def configure_args(self): def edit(self, spec, prefix): configure(*self.configure_args()) + + @property + def libs(self): + return LibraryList([]) + + @property + def headers(self): + return HeaderList([]) diff --git a/var/spack/repos/builtin/packages/must/package.py b/var/spack/repos/builtin/packages/must/package.py index 5597157134e4c6..388edc7a6f2fa3 100644 --- a/var/spack/repos/builtin/packages/must/package.py +++ b/var/spack/repos/builtin/packages/must/package.py @@ -23,6 +23,10 @@ class Must(CMakePackage): version("1.8.0", sha256="9754fefd2e4c8cba812f8b56a5dd929bc84aa599b2509305e1eb8518be0a8a39") version("1.7.2", sha256="616c54b7487923959df126ac4b47ae8c611717d679fe7ec29f57a89bf0e2e0d0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("test", default=False, description="Enable must internal tests") variant("tsan", default=True, description="Enable thread sanitizer") variant("graphviz", default=False, description="Use to generate graphs") diff --git a/var/spack/repos/builtin/packages/muster/package.py b/var/spack/repos/builtin/packages/muster/package.py index 13ebbd04f35bda..76c1c4f988c987 100644 --- a/var/spack/repos/builtin/packages/muster/package.py +++ b/var/spack/repos/builtin/packages/muster/package.py @@ -20,6 +20,8 @@ class Muster(CMakePackage): version("1.0.1", sha256="71e2fcdd7abf7ae5cc648a5f310e1c5369e4889718eab2a045e747c590d2dd71") version("1.0", sha256="370a670419e391494fcca0294882ee5f83c5d8af94ca91ac4182235332bd56d6") + depends_on("cxx", type="build") # generated + depends_on("boost+exception+serialization+random") depends_on("mpi") depends_on("cmake@2.8:", type="build") diff --git a/var/spack/repos/builtin/packages/mutationpp/package.py b/var/spack/repos/builtin/packages/mutationpp/package.py index 0a7a01262edcd0..449c7011630b70 100644 --- a/var/spack/repos/builtin/packages/mutationpp/package.py +++ b/var/spack/repos/builtin/packages/mutationpp/package.py @@ -24,6 +24,10 @@ class Mutationpp(CMakePackage): version("1.0.0", sha256="928df99accd1a02706a57246edeef8ebbf3bd91bb40492258ee18b810a7e0194") version("0.3.1", sha256="a6da2816e145ac9fcfbd8920595b7f65ce7bc8df0bec572b32647720758cbe69") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=True, description="Enable Fortran interface") variant("data", default=True, description="Install default model data") variant("examples", default=True, description="Install examples") diff --git a/var/spack/repos/builtin/packages/mvapich/package.py b/var/spack/repos/builtin/packages/mvapich/package.py index d2b429d3c14eb3..37221fec277310 100644 --- a/var/spack/repos/builtin/packages/mvapich/package.py +++ b/var/spack/repos/builtin/packages/mvapich/package.py @@ -29,6 +29,10 @@ class Mvapich(AutotoolsPackage): # Prefer the latest stable release version("3.0", sha256="ee076c4e672d18d6bf8dd2250e4a91fa96aac1db2c788e4572b5513d86936efb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + provides("mpi") provides("mpi@:3.1") @@ -215,40 +219,24 @@ def setup_dependent_build_environment(self, env, dependent_spec): self.setup_compiler_environment(env) # use the Spack compiler wrappers under MPI - env.set("MPICH_CC", spack_cc) - env.set("MPICH_CXX", spack_cxx) - env.set("MPICH_F77", spack_f77) - env.set("MPICH_F90", spack_fc) - env.set("MPICH_FC", spack_fc) + dependent_module = dependent_spec.package.module + env.set("MPICH_CC", dependent_module.spack_cc) + env.set("MPICH_CXX", dependent_module.spack_cxx) + env.set("MPICH_F77", dependent_module.spack_f77) + env.set("MPICH_F90", dependent_module.spack_fc) + env.set("MPICH_FC", dependent_module.spack_fc) def setup_compiler_environment(self, env): - # For Cray MPIs, the regular compiler wrappers *are* the MPI wrappers. - # Cray MPIs always have cray in the module name, e.g. "cray-mvapich" - if self.spec.satisfies("platform=cray"): - env.set("MPICC", spack_cc) - env.set("MPICXX", spack_cxx) - env.set("MPIF77", spack_fc) - env.set("MPIF90", spack_fc) - else: - env.set("MPICC", join_path(self.prefix.bin, "mpicc")) - env.set("MPICXX", join_path(self.prefix.bin, "mpicxx")) - env.set("MPIF77", join_path(self.prefix.bin, "mpif77")) - env.set("MPIF90", join_path(self.prefix.bin, "mpif90")) + env.set("MPICC", join_path(self.prefix.bin, "mpicc")) + env.set("MPICXX", join_path(self.prefix.bin, "mpicxx")) + env.set("MPIF77", join_path(self.prefix.bin, "mpif77")) + env.set("MPIF90", join_path(self.prefix.bin, "mpif90")) def setup_dependent_package(self, module, dependent_spec): - # For Cray MPIs, the regular compiler wrappers *are* the MPI wrappers. - # Cray MPIs always have cray in the module name, e.g. "cray-mvapich" - if self.spec.satisfies("platform=cray"): - self.spec.mpicc = spack_cc - self.spec.mpicxx = spack_cxx - self.spec.mpifc = spack_fc - self.spec.mpif77 = spack_f77 - else: - self.spec.mpicc = join_path(self.prefix.bin, "mpicc") - self.spec.mpicxx = join_path(self.prefix.bin, "mpicxx") - self.spec.mpifc = join_path(self.prefix.bin, "mpif90") - self.spec.mpif77 = join_path(self.prefix.bin, "mpif77") - + self.spec.mpicc = join_path(self.prefix.bin, "mpicc") + self.spec.mpicxx = join_path(self.prefix.bin, "mpicxx") + self.spec.mpifc = join_path(self.prefix.bin, "mpif90") + self.spec.mpif77 = join_path(self.prefix.bin, "mpif77") self.spec.mpicxx_shared_libs = [ os.path.join(self.prefix.lib, "libmpicxx.{0}".format(dso_suffix)), os.path.join(self.prefix.lib, "libmpi.{0}".format(dso_suffix)), diff --git a/var/spack/repos/builtin/packages/mvapich2-gdr/package.py b/var/spack/repos/builtin/packages/mvapich2-gdr/package.py index a284f6ffa02ef9..ae9ad23d02fec3 100755 --- a/var/spack/repos/builtin/packages/mvapich2-gdr/package.py +++ b/var/spack/repos/builtin/packages/mvapich2-gdr/package.py @@ -166,13 +166,12 @@ def setup_run_environment(self, env): def setup_dependent_build_environment(self, env, dependent_spec): self.setup_compiler_environment(env) - - # use the Spack compiler wrappers under MPI - env.set("MPICH_CC", spack_cc) - env.set("MPICH_CXX", spack_cxx) - env.set("MPICH_F77", spack_f77) - env.set("MPICH_F90", spack_fc) - env.set("MPICH_FC", spack_fc) + dependent_module = dependent_spec.package.module + env.set("MPICH_CC", dependent_module.spack_cc) + env.set("MPICH_CXX", dependent_module.spack_cxx) + env.set("MPICH_F77", dependent_module.spack_f77) + env.set("MPICH_F90", dependent_module.spack_fc) + env.set("MPICH_FC", dependent_module.spack_fc) def setup_compiler_environment(self, env): env.set("MPICC", join_path(self.prefix.bin, "mpicc")) diff --git a/var/spack/repos/builtin/packages/mvapich2/package.py b/var/spack/repos/builtin/packages/mvapich2/package.py index 7e9204ffbde19f..23129c3ec0c4da 100644 --- a/var/spack/repos/builtin/packages/mvapich2/package.py +++ b/var/spack/repos/builtin/packages/mvapich2/package.py @@ -39,6 +39,10 @@ class Mvapich2(AutotoolsPackage): version("2.2", sha256="791a6fc2b23de63b430b3e598bf05b1b25b82ba8bf7e0622fc81ba593b3bb131") version("2.1", sha256="49f3225ad17d2f3b6b127236a0abdc979ca8a3efb8d47ab4b6cd4f5252d05d29") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + provides("mpi") provides("mpi@:3.1", when="@2.3:") provides("mpi@:3.0", when="@2.1:") @@ -375,42 +379,25 @@ def setup_run_environment(self, env): def setup_dependent_build_environment(self, env, dependent_spec): self.setup_compiler_environment(env) - # use the Spack compiler wrappers under MPI - env.set("MPICH_CC", spack_cc) - env.set("MPICH_CXX", spack_cxx) - env.set("MPICH_F77", spack_f77) - env.set("MPICH_F90", spack_fc) - env.set("MPICH_FC", spack_fc) + dependent_module = dependent_spec.package.module + env.set("MPICH_CC", dependent_module.spack_cc) + env.set("MPICH_CXX", dependent_module.spack_cxx) + env.set("MPICH_F77", dependent_module.spack_f77) + env.set("MPICH_F90", dependent_module.spack_fc) + env.set("MPICH_FC", dependent_module.spack_fc) def setup_compiler_environment(self, env): - # For Cray MPIs, the regular compiler wrappers *are* the MPI wrappers. - # Cray MPIs always have cray in the module name, e.g. "cray-mvapich" - if self.spec.satisfies("platform=cray"): - env.set("MPICC", spack_cc) - env.set("MPICXX", spack_cxx) - env.set("MPIF77", spack_fc) - env.set("MPIF90", spack_fc) - else: - env.set("MPICC", join_path(self.prefix.bin, "mpicc")) - env.set("MPICXX", join_path(self.prefix.bin, "mpicxx")) - env.set("MPIF77", join_path(self.prefix.bin, "mpif77")) - env.set("MPIF90", join_path(self.prefix.bin, "mpif90")) + env.set("MPICC", join_path(self.prefix.bin, "mpicc")) + env.set("MPICXX", join_path(self.prefix.bin, "mpicxx")) + env.set("MPIF77", join_path(self.prefix.bin, "mpif77")) + env.set("MPIF90", join_path(self.prefix.bin, "mpif90")) def setup_dependent_package(self, module, dependent_spec): - # For Cray MPIs, the regular compiler wrappers *are* the MPI wrappers. - # Cray MPIs always have cray in the module name, e.g. "cray-mvapich" - if self.spec.satisfies("platform=cray"): - self.spec.mpicc = spack_cc - self.spec.mpicxx = spack_cxx - self.spec.mpifc = spack_fc - self.spec.mpif77 = spack_f77 - else: - self.spec.mpicc = join_path(self.prefix.bin, "mpicc") - self.spec.mpicxx = join_path(self.prefix.bin, "mpicxx") - self.spec.mpifc = join_path(self.prefix.bin, "mpif90") - self.spec.mpif77 = join_path(self.prefix.bin, "mpif77") - + self.spec.mpicc = join_path(self.prefix.bin, "mpicc") + self.spec.mpicxx = join_path(self.prefix.bin, "mpicxx") + self.spec.mpifc = join_path(self.prefix.bin, "mpif90") + self.spec.mpif77 = join_path(self.prefix.bin, "mpif77") self.spec.mpicxx_shared_libs = [ os.path.join(self.prefix.lib, "libmpicxx.{0}".format(dso_suffix)), os.path.join(self.prefix.lib, "libmpi.{0}".format(dso_suffix)), diff --git a/var/spack/repos/builtin/packages/mvapich2x/package.py b/var/spack/repos/builtin/packages/mvapich2x/package.py index b817f3cd34331e..5962ef69683872 100644 --- a/var/spack/repos/builtin/packages/mvapich2x/package.py +++ b/var/spack/repos/builtin/packages/mvapich2x/package.py @@ -218,13 +218,13 @@ def setup_run_environment(self, env): def setup_dependent_build_environment(self, env, dependent_spec): self.setup_compiler_environment(env) - # use the Spack compiler wrappers under MPI - env.set("MPICH_CC", spack_cc) - env.set("MPICH_CXX", spack_cxx) - env.set("MPICH_F77", spack_f77) - env.set("MPICH_F90", spack_fc) - env.set("MPICH_FC", spack_fc) + dependent_module = dependent_spec.package.module + env.set("MPICH_CC", dependent_module.spack_cc) + env.set("MPICH_CXX", dependent_module.spack_cxx) + env.set("MPICH_F77", dependent_module.spack_f77) + env.set("MPICH_F90", dependent_module.spack_fc) + env.set("MPICH_FC", dependent_module.spack_fc) def setup_compiler_environment(self, env): # For Cray MPIs, the regular compiler wrappers *are* the MPI wrappers. diff --git a/var/spack/repos/builtin/packages/mxml/package.py b/var/spack/repos/builtin/packages/mxml/package.py index 7ae66fbd23c749..40a892419e086a 100644 --- a/var/spack/repos/builtin/packages/mxml/package.py +++ b/var/spack/repos/builtin/packages/mxml/package.py @@ -21,6 +21,9 @@ class Mxml(AutotoolsPackage): version("2.9", sha256="cded54653c584b24c4a78a7fa1b3b4377d49ac4f451ddf170ebbc8161d85ff92") version("2.8", sha256="0c9369f91a718d82e32cb007c0bd41b6642822c9a0ffe1d10eccbdea9a3011d5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): if version <= Version("2.7"): return "https://github.com/michaelrsweet/mxml/archive/release-{0}.tar.gz".format( diff --git a/var/spack/repos/builtin/packages/mxnet/package.py b/var/spack/repos/builtin/packages/mxnet/package.py index 9558cc6b80bb5b..084b1d241556da 100644 --- a/var/spack/repos/builtin/packages/mxnet/package.py +++ b/var/spack/repos/builtin/packages/mxnet/package.py @@ -14,8 +14,6 @@ class Mxnet(CMakePackage, CudaPackage, PythonExtension): list_url = "https://mxnet.apache.org/get_started/download" git = "https://github.com/apache/mxnet.git" - maintainers("adamjstewart") - license("Apache-2.0") version("master", branch="master", submodules=True) @@ -25,6 +23,9 @@ class Mxnet(CMakePackage, CudaPackage, PythonExtension): version("1.7.0", sha256="1d20c9be7d16ccb4e830e9ee3406796efaf96b0d93414d676337b64bc59ced18") version("1.6.0", sha256="01eb06069c90f33469c7354946261b0a94824bbaf819fd5d5a7318e8ee596def") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "build_type", default="Distribution", diff --git a/var/spack/repos/builtin/packages/mysql-connector-c/package.py b/var/spack/repos/builtin/packages/mysql-connector-c/package.py index d0e4d1f218b5c1..874447d3ea3281 100644 --- a/var/spack/repos/builtin/packages/mysql-connector-c/package.py +++ b/var/spack/repos/builtin/packages/mysql-connector-c/package.py @@ -23,3 +23,6 @@ class MysqlConnectorC(CMakePackage): license("GPL-2.0-or-later") version("6.1.11", sha256="c8664851487200162b38b6f3c8db69850bd4f0e4c5ff5a6d161dbfb5cb76b6c4") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/mysql/package.py b/var/spack/repos/builtin/packages/mysql/package.py index 36964dfa5a4fd2..42288aaab74b95 100644 --- a/var/spack/repos/builtin/packages/mysql/package.py +++ b/var/spack/repos/builtin/packages/mysql/package.py @@ -50,6 +50,9 @@ class Mysql(CMakePackage): version("5.6.43", sha256="1c95800bf0e1b7a19a37d37fbc5023af85c6bc0b41532433b3a886263a1673ef") version("5.5.62", sha256="b1e7853bc1f04aabf6771e0ad947f35ac8d237f4b35d0706d1095c9526ff99d7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("client_only", default=False, description="Build and install client only.") variant( "cxxstd", diff --git a/var/spack/repos/builtin/packages/mysqlpp/package.py b/var/spack/repos/builtin/packages/mysqlpp/package.py index cec4a6d4dc6076..d34501bbf690b4 100644 --- a/var/spack/repos/builtin/packages/mysqlpp/package.py +++ b/var/spack/repos/builtin/packages/mysqlpp/package.py @@ -19,6 +19,8 @@ class Mysqlpp(AutotoolsPackage): version("3.3.0", sha256="449cbc46556cc2cc9f9d6736904169a8df6415f6960528ee658998f96ca0e7cf") version("3.2.5", sha256="839cfbf71d50a04057970b8c31f4609901f5d3936eaa86dab3ede4905c4db7a8") + depends_on("cxx", type="build") # generated + depends_on("mysql-client") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/n2p2/package.py b/var/spack/repos/builtin/packages/n2p2/package.py index 2a41a52c20422f..3bb4f0d42db63c 100644 --- a/var/spack/repos/builtin/packages/n2p2/package.py +++ b/var/spack/repos/builtin/packages/n2p2/package.py @@ -22,6 +22,8 @@ class N2p2(MakefilePackage): version("2.1.1", sha256="90fbc0756132984d0d7e6d92d2f53358c120e75f148910d90c027158163251b9") version("2.1.0", sha256="283c00e9a5b964f4c84a70c5f1cef7167e9b881080b50a221da08799e5ede400") + depends_on("cxx", type="build") # generated + variant("doc", default=False, description="build documentation with Doxygen") variant("shared", default=False, description="build shared libraries") diff --git a/var/spack/repos/builtin/packages/nag/detection_test.yaml b/var/spack/repos/builtin/packages/nag/detection_test.yaml new file mode 100644 index 00000000000000..df2bbe9bbd9aaf --- /dev/null +++ b/var/spack/repos/builtin/packages/nag/detection_test.yaml @@ -0,0 +1,13 @@ +paths: +- layout: + - executables: + - bin/nagfor + script: | + echo "NAG Fortran Compiler Release 6.0(Hibiya) Build 1037" + echo "Product NPL6A60NA for x86-64 Linux" + platforms: [linux] + results: + - spec: nag@6.0.1037 + extra_attributes: + compilers: + fortran: ".*/bin/nagfor" diff --git a/var/spack/repos/builtin/packages/nag/package.py b/var/spack/repos/builtin/packages/nag/package.py index d00d11ea30737d..d0c35c8de70ff2 100644 --- a/var/spack/repos/builtin/packages/nag/package.py +++ b/var/spack/repos/builtin/packages/nag/package.py @@ -3,15 +3,11 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) import os -import re -import llnl.util.tty as tty - -import spack.compiler from spack.package import * -class Nag(Package): +class Nag(Package, CompilerPackage): """The NAG Fortran Compiler.""" homepage = "https://www.nag.com/nagware/np.asp" @@ -34,6 +30,8 @@ class Nag(Package): deprecated=True, ) + depends_on("fortran", type="build") # generated + # Licensing license_required = True license_comment = "!" @@ -64,54 +62,10 @@ def setup_run_environment(self, env): env.set("F77", self.prefix.bin.nagfor) env.set("FC", self.prefix.bin.nagfor) - executables = ["^nagfor$"] - - @classmethod - def determine_version(cls, exe): - version_regex = re.compile(r"NAG Fortran Compiler Release ([0-9.]+)") - # NAG does not support a flag that would enable verbose output and - # compilation/linking at the same time (with either '-#' or '-dryrun' - # the compiler only prints the commands but does not run them). - # Therefore, the only thing we can do is to pass the '-v' argument to - # the underlying GCC. In order to get verbose output from the latter - # at both compile and linking stages, we need to call NAG with two - # additional flags: '-Wc,-v' and '-Wl,-v'. However, we return only - # '-Wl,-v' for the following reasons: - # 1) the interface of this method does not support multiple flags in - # the return value and, at least currently, verbose output at the - # linking stage has a higher priority for us; - # 2) NAG is usually mixed with GCC compiler, which also accepts - # '-Wl,-v' and produces meaningful result with it: '-v' is passed - # to the linker and the latter produces verbose output for the - # linking stage ('-Wc,-v', however, would break the compilation - # with a message from GCC that the flag is not recognized). - # - # This way, we at least enable the implicit rpath detection, which is - # based on compilation of a C file (see method - # spack.compiler._get_compiler_link_paths): in the case of a mixed - # NAG/GCC toolchain, the flag will be passed to g++ (e.g. - # 'g++ -Wl,-v ./main.c'), otherwise, the flag will be passed to nagfor - # (e.g. 'nagfor -Wl,-v ./main.c' - note that nagfor recognizes '.c' - # extension and treats the file accordingly). The list of detected - # rpaths will contain only GCC-related directories and rpaths to - # NAG-related directories are injected by nagfor anyway. - try: - output = spack.compiler.get_compiler_version_output(exe, "-Wl,-v") - match = version_regex.search(output) - if match: - return match.group(1) - except spack.util.executable.ProcessError: - pass - except Exception as e: - tty.debug(e) - - @classmethod - def determine_variants(cls, exes, version_str): - compilers = {} - for exe in exes: - if "nagfor" in exe: - compilers["fortran"] = exe - return "", {"compilers": compilers} + compiler_languages = ["fortran"] + fortran_names = ["nagfor"] + compiler_version_regex = r"NAG Fortran Compiler Release (\d+).(\d+)\(.*\) Build (\d+)" + compiler_version_argument = "-V" @property def fortran(self): diff --git a/var/spack/repos/builtin/packages/nalu-wind/package.py b/var/spack/repos/builtin/packages/nalu-wind/package.py index 7d77c431d10b76..eb923367541098 100644 --- a/var/spack/repos/builtin/packages/nalu-wind/package.py +++ b/var/spack/repos/builtin/packages/nalu-wind/package.py @@ -3,8 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import sys - from spack.package import * @@ -15,17 +13,28 @@ def _parse_float(val): return False -class NaluWind(CMakePackage, CudaPackage): +def submodules(package): + submodules = [] + if package.spec.satisfies("+wind-utils"): + submodules.append("wind-utils") + if package.spec.satisfies("+tests"): + submodules.append("reg_tests/mesh") + return submodules + + +class NaluWind(CMakePackage, CudaPackage, ROCmPackage): """Nalu-Wind: Wind energy focused variant of Nalu.""" homepage = "https://nalu-wind.readthedocs.io" git = "https://github.com/exawind/nalu-wind.git" + url = "https://github.com/Exawind/nalu-wind/archive/refs/tags/v2.0.0.tar.gz" maintainers("jrood-nrel", "psakievich") tags = ["ecp", "ecp-apps"] - version("master", branch="master") + version("master", branch="master", submodules=submodules) + version("2.0.0", tag="v2.0.0", submodules=submodules) variant("pic", default=True, description="Position independent code") variant( @@ -43,30 +52,44 @@ class NaluWind(CMakePackage, CudaPackage): variant("openfast", default=False, description="Compile with OpenFAST support") variant("tioga", default=False, description="Compile with Tioga support") variant("hypre", default=True, description="Compile with Hypre support") - variant("trilinos-solvers", default=True, description="Compile with Trilinos Solvers support") + variant("trilinos-solvers", default=False, description="Compile with Trilinos Solvers support") variant("catalyst", default=False, description="Compile with Catalyst support") + variant("shared", default=True, description="Build shared libraries") variant("fftw", default=False, description="Compile with FFTW support") + variant("fsi", default=False, description="Enable fluid-structure-interaction models") variant("boost", default=False, description="Enable Boost integration") + variant("gpu-aware-mpi", default=False, description="gpu-aware-mpi") variant("wind-utils", default=False, description="Build wind-utils") + variant("umpire", default=False, description="Enable Umpire") + variant( + "tests", default=False, description="Enable regression tests and clone the mesh submodule" + ) depends_on("mpi") depends_on("yaml-cpp@0.5.3:") + depends_on("openfast@4.0.0:+cxx+netcdf", when="+fsi") + depends_on("trilinos@13.4.1", when="@=2.0.0") + depends_on("hypre@2.29.0:", when="@2.0.0:+hypre") depends_on( - "trilinos@13:+exodus+tpetra+zoltan+stk~superlu-dist~superlu+hdf5+shards~hypre+gtest" + "trilinos@13:+exodus+tpetra+zoltan+stk~superlu-dist~superlu+hdf5+shards~hypre+gtest " + "gotype=long cxxstd=17" ) depends_on("trilinos~cuda~wrapper", when="~cuda") - # Cannot build Trilinos as a shared library with STK on Darwin - # https://github.com/trilinos/Trilinos/issues/2994 - depends_on("trilinos~shared", when=(sys.platform == "darwin")) depends_on("openfast@2.6.0: +cxx", when="+openfast") - depends_on("tioga@master:", when="+tioga") + depends_on("tioga@1.0.0:", when="+tioga") depends_on("hypre@2.18.2: ~int64+mpi~superlu-dist", when="+hypre") depends_on("trilinos+muelu+belos+amesos2+ifpack2", when="+trilinos-solvers") - conflicts( - "~hypre~trilinos-solvers", - msg="nalu-wind: Must enable at least one of the linear-solvers: hypre or trilinos-solvers", - ) depends_on("kokkos-nvcc-wrapper", type="build", when="+cuda") + depends_on("trilinos-catalyst-ioss-adapter", when="+catalyst") + depends_on("fftw+mpi", when="+fftw") + depends_on("nccmp") + depends_on("boost +filesystem +iostreams cxxstd=14", when="+boost") + depends_on("hypre+gpu-aware-mpi", when="+gpu-aware-mpi") + depends_on("hypre+umpire", when="+umpire") + depends_on("trilinos~shared", when="+trilinos-solvers") + # indirect dependency needed to make original concretizer work + depends_on("netcdf-c+parallel-netcdf") + for _arch in CudaPackage.cuda_arch_values: depends_on( "trilinos~shared+cuda+cuda_rdc+wrapper cuda_arch={0}".format(_arch), @@ -76,50 +99,98 @@ class NaluWind(CMakePackage, CudaPackage): "hypre@develop +mpi+cuda~int64~superlu-dist cuda_arch={0}".format(_arch), when="+hypre+cuda cuda_arch={0}".format(_arch), ) - depends_on("trilinos-catalyst-ioss-adapter", when="+catalyst") - depends_on("fftw+mpi", when="+fftw") - depends_on("nccmp") - # indirect dependency needed to make original concretizer work - depends_on("netcdf-c+parallel-netcdf") - depends_on("boost +filesystem +iostreams cxxstd=14", when="+boost") + for _arch in ROCmPackage.amdgpu_targets: + depends_on( + "trilinos@13.4: ~shared+rocm+rocm_rdc amdgpu_target={0}".format(_arch), + when="+rocm amdgpu_target={0}".format(_arch), + ) + depends_on( + "hypre+rocm amdgpu_target={0}".format(_arch), + when="+hypre+rocm amdgpu_target={0}".format(_arch), + ) + + conflicts( + "~hypre~trilinos-solvers", + msg="nalu-wind: Must enable at least one of the linear-solvers: hypre or trilinos-solvers", + ) + conflicts( + "+shared", + when="+cuda", + msg="invalid device functions are generated with shared libs and cuda", + ) + conflicts( + "+shared", + when="+rocm", + msg="invalid device functions are generated with shared libs and rocm", + ) + conflicts("+cuda", when="+rocm") + conflicts("+rocm", when="+cuda") + conflicts("^hypre+cuda", when="~cuda") + conflicts("^hypre+rocm", when="~rocm") + conflicts("^hypre+sycl") + conflicts("^trilinos+cuda", when="~cuda") + conflicts("^trilinos+rocm", when="~rocm") + conflicts("+shared", when="+trilinos-solvers") + + def setup_dependent_run_environment(self, env, dependent_spec): + spec = self.spec + if spec.satisfies("+cuda") or spec.satisfies("+rocm"): + env.set("CUDA_LAUNCH_BLOCKING", "1") + env.set("CUDA_MANAGED_FORCE_DEVICE_ALLOC", "1") + env.set("HIP_LAUNCH_BLOCKING", "1") + env.set("HIP_MANAGED_FORCE_DEVICE_ALLOC", "1") + + def setup_build_environment(self, env): + spec = self.spec + env.append_flags("CXXFLAGS", "-DUSE_STK_SIMD_NONE") + if spec.satisfies("+cuda"): + env.set("OMPI_CXX", self.spec["kokkos-nvcc-wrapper"].kokkos_cxx) + env.set("MPICH_CXX", self.spec["kokkos-nvcc-wrapper"].kokkos_cxx) + env.set("MPICXX_CXX", self.spec["kokkos-nvcc-wrapper"].kokkos_cxx) + if spec.satisfies("+rocm"): + env.append_flags("CXXFLAGS", "-fgpu-rdc") def cmake_args(self): spec = self.spec args = [ - self.define_from_variant("CMAKE_POSITION_INDEPENDENT_CODE", "pic"), self.define("CMAKE_CXX_COMPILER", spec["mpi"].mpicxx), self.define("CMAKE_Fortran_COMPILER", spec["mpi"].mpifc), self.define("Trilinos_DIR", spec["trilinos"].prefix), self.define("YAML_DIR", spec["yaml-cpp"].prefix), + self.define("CMAKE_CXX_STANDARD", "17"), + self.define_from_variant("CMAKE_POSITION_INDEPENDENT_CODE", "pic"), self.define_from_variant("ENABLE_CUDA", "cuda"), self.define_from_variant("ENABLE_WIND_UTILS", "wind-utils"), self.define_from_variant("ENABLE_BOOST", "boost"), + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + self.define_from_variant("ENABLE_OPENFAST", "openfast"), + self.define_from_variant("ENABLE_TIOGA", "tioga"), + self.define_from_variant("ENABLE_HYPRE", "hypre"), + self.define_from_variant("ENABLE_TRILINOS_SOLVERS", "trilinos-solvers"), + self.define_from_variant("ENABLE_PARAVIEW_CATALYST", "catalyst"), + self.define_from_variant("ENABLE_FFTW", "fftw"), + self.define_from_variant("ENABLE_UMPIRE", "umpire"), + self.define_from_variant("ENABLE_TESTS", "tests"), ] - args.append(self.define_from_variant("ENABLE_OPENFAST", "openfast")) - if "+openfast" in spec: + if spec.satisfies("+openfast"): args.append(self.define("OpenFAST_DIR", spec["openfast"].prefix)) - args.append(self.define_from_variant("ENABLE_TIOGA", "tioga")) - if "+tioga" in spec: + if spec.satisfies("+tioga"): args.append(self.define("TIOGA_DIR", spec["tioga"].prefix)) - args.append(self.define_from_variant("ENABLE_HYPRE", "hypre")) - if "+hypre" in spec: + if spec.satisfies("+hypre"): args.append(self.define("HYPRE_DIR", spec["hypre"].prefix)) - args.append(self.define_from_variant("ENABLE_TRILINOS_SOLVERS", "trilinos-solvers")) - args.append(self.define_from_variant("ENABLE_PARAVIEW_CATALYST", "catalyst")) - if "+catalyst" in spec: + if spec.satisfies("+catalyst"): args.append( self.define( "PARAVIEW_CATALYST_INSTALL_PATH", spec["trilinos-catalyst-ioss-adapter"].prefix ) ) - args.append(self.define_from_variant("ENABLE_FFTW", "fftw")) - if "+fftw" in spec: + if spec.satisfies("+fftw"): args.append(self.define("FFTW_DIR", spec["fftw"].prefix)) args.append(self.define("ENABLE_TESTS", self.run_tests)) @@ -131,6 +202,15 @@ def cmake_args(self): ] ) + if spec.satisfies("+umpire"): + args.append(self.define("UMPIRE_DIR", spec["umpire"].prefix)) + + if spec.satisfies("+rocm"): + args.append(self.define("CMAKE_CXX_COMPILER", spec["hip"].hipcc)) + args.append(self.define("ENABLE_ROCM", True)) + targets = spec.variants["amdgpu_target"].value + args.append(self.define("GPU_TARGETS", ";".join(str(x) for x in targets))) + if "darwin" in spec.architecture: args.append(self.define("CMAKE_MACOSX_RPATH", "ON")) @@ -138,6 +218,6 @@ def cmake_args(self): @run_before("cmake") def add_submodules(self): - if self.run_tests or "+wind-utils" in self.spec: + if self.run_tests or self.spec.satisfies("+wind-utils"): git = which("git") git("submodule", "update", "--init", "--recursive") diff --git a/var/spack/repos/builtin/packages/nalu/package.py b/var/spack/repos/builtin/packages/nalu/package.py index 0d3f3c9280db9d..6d022f2b25a5d5 100644 --- a/var/spack/repos/builtin/packages/nalu/package.py +++ b/var/spack/repos/builtin/packages/nalu/package.py @@ -15,9 +15,17 @@ class Nalu(CMakePackage): """ homepage = "https://github.com/NaluCFD/Nalu" + url = "https://github.com/NaluCFD/Nalu/archive/refs/tags/v1.6.0.tar.gz" git = "https://github.com/NaluCFD/Nalu.git" version("master", branch="master") + version("1.6.0", sha256="2eafafe25ed44a7bc1429881f8f944b9794ca51b1e1b29c28a45b91520c7cf97") + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + depends_on("trilinos@master", when="@master") + depends_on("trilinos@14.0.0:14.2.0", when="@1.6.0") # Options variant( @@ -31,16 +39,16 @@ class Nalu(CMakePackage): # Required dependencies depends_on("mpi") - depends_on("yaml-cpp@0.5.3:", when="+shared") - depends_on("yaml-cpp~shared@0.5.3:", when="~shared") + depends_on("yaml-cpp@0.5.3:0.6.2", when="+shared") + depends_on("yaml-cpp~shared@0.5.3:0.6.2", when="~shared") # Cannot build Trilinos as a shared library with STK on Darwin # which is why we have a 'shared' variant for Nalu # https://github.com/trilinos/Trilinos/issues/2994 depends_on( "trilinos" - "+mpi+exodus+tpetra+muelu+belos+ifpack2+amesos2+zoltan+stk+boost" - "~superlu-dist+superlu+hdf5+shards~hypre" - "@master" + "+mpi+exodus+tpetra+muelu+belos+ifpack2+amesos2+zoltan+stk+boost+gtest" + "~epetra~ml" + "~superlu-dist+superlu+hdf5+shards~hypre gotype=long" ) depends_on("trilinos~shared", when="~shared") # Optional dependencies diff --git a/var/spack/repos/builtin/packages/namd/package.py b/var/spack/repos/builtin/packages/namd/package.py index bfe4fe9e422915..80446885fc10f0 100644 --- a/var/spack/repos/builtin/packages/namd/package.py +++ b/var/spack/repos/builtin/packages/namd/package.py @@ -20,17 +20,38 @@ class Namd(MakefilePackage, CudaPackage): url = "file://{0}/NAMD_2.12_Source.tar.gz".format(os.getcwd()) git = "https://charm.cs.illinois.edu/gerrit/namd.git" manual_download = True + redistribute(source=False, binary=False) maintainers("jcphill") version("master", branch="master") - version("3.0b6", sha256="8b5fb1dc8d5b5666c6a45d20ee7e8c9d1f5c186578e2cf148b68ba421d43b850") - version("3.0b3", sha256="20c32b6161f9c376536e3cb97c3bfe5367e1baaaace3c716ff79831fc2eb8199") - version("2.15a2", sha256="8748cbaa93fc480f92fc263d9323e55bce6623fc693dbfd4a40f59b92669713e") - version("2.15a1", branch="master", tag="release-2-15-alpha-1") + version("3.0", sha256="301c64f0f1db860f7336efdb26223ccf66b5ab42bfc9141df8d81ec1e20bf472") + version( + "3.0b7", + sha256="b18ff43b0f55ec59e137c62eba1812589dd88b2122c3a05ea652781667f438b4", + deprecated=True, + ) + version( + "3.0b6", + sha256="8b5fb1dc8d5b5666c6a45d20ee7e8c9d1f5c186578e2cf148b68ba421d43b850", + deprecated=True, + ) + version( + "3.0b3", + sha256="20c32b6161f9c376536e3cb97c3bfe5367e1baaaace3c716ff79831fc2eb8199", + deprecated=True, + ) + version( + "2.15a2", + sha256="8748cbaa93fc480f92fc263d9323e55bce6623fc693dbfd4a40f59b92669713e", + deprecated=True, + ) + version("2.15a1", branch="master", tag="release-2-15-alpha-1", deprecated=True) # Same as above, but lets you use a local file instead of git version( - "2.15a1.manual", sha256="474006e98e32dddae59616b3b75f13a2bb149deaf7a0d617ce7fb9fd5a56a33a" + "2.15a1.manual", + sha256="474006e98e32dddae59616b3b75f13a2bb149deaf7a0d617ce7fb9fd5a56a33a", + deprecated=True, ) version( "2.14", @@ -133,7 +154,7 @@ def _edit_arch_generic(self, spec, prefix): # this options are take from the default provided # configuration files # https://github.com/UIUC-PPL/charm/pull/2778 - archopt = spec.target.optimization_flags(spec.compiler.name, spec.compiler.version) + archopt = spec.architecture.target.optimization_flags(spec.compiler) if self.spec.satisfies("^charmpp@:6.10.1"): optims_opts = { @@ -289,6 +310,13 @@ def edit(self, spec, prefix): join_path(self.build_directory, "Make.config"), ) + @when("@3.0b3") + def build(self, spec, prefix): + # Disable parallel build + # https://github.com/spack/spack/pull/43215 + with working_dir(self.build_directory): + make(parallel=False) + def install(self, spec, prefix): with working_dir(self.build_directory): mkdirp(prefix.bin) diff --git a/var/spack/repos/builtin/packages/nano/package.py b/var/spack/repos/builtin/packages/nano/package.py index 3fd46110cb0f8c..0fb2035b637bfa 100644 --- a/var/spack/repos/builtin/packages/nano/package.py +++ b/var/spack/repos/builtin/packages/nano/package.py @@ -16,6 +16,8 @@ class Nano(AutotoolsPackage): license("GPL-3.0-or-later") + # 8.x + version("8.0", sha256="c17f43fc0e37336b33ee50a209c701d5beb808adc2d9f089ca831b40539c9ac4") # 7.x version("7.2", sha256="86f3442768bd2873cec693f83cdf80b4b444ad3cc14760b74361474fc87a4526") # 6.x @@ -80,6 +82,9 @@ class Nano(AutotoolsPackage): version("2.6.2", sha256="22f79cc635458e0c0d110d211576f1edc03b112a62d73b914826a46547a6ac27") version("2.6.1", sha256="45721fa6d6128068895ad71a6967ff7398d11b064b3f888e5073c97a2b6e9a81") + depends_on("c", type="build") # generated + + depends_on("pkgconfig", type="build") depends_on("ncurses") def url_for_version(self, version): diff --git a/var/spack/repos/builtin/packages/nanoflann/package.py b/var/spack/repos/builtin/packages/nanoflann/package.py index 9a6daec988a145..a307c71c6d80e4 100644 --- a/var/spack/repos/builtin/packages/nanoflann/package.py +++ b/var/spack/repos/builtin/packages/nanoflann/package.py @@ -14,10 +14,13 @@ class Nanoflann(CMakePackage): license("BSD-2-Clause") + version("1.5.5", sha256="fd28045eabaf0e7f12236092f80905a1750e0e6b580bb40eadd64dc4f75d641d") version("1.5.4", sha256="a7f64d0bdff42614c561e52680b16de46c0edac9719f21f935c5e1f8b0654afc") version("1.4.3", sha256="cbcecf22bec528a8673a113ee9b0e134f91f1f96be57e913fa1f74e98e4449fa") version("1.2.3", sha256="5ef4dfb23872379fe9eb306aabd19c9df4cae852b72a923af01aea5e8d7a59c3") + depends_on("cxx", type="build") # generated + def patch(self): filter_file("-mtune=native", "", "CMakeLists.txt") diff --git a/var/spack/repos/builtin/packages/nanomsg/package.py b/var/spack/repos/builtin/packages/nanomsg/package.py index ed2a74c7753f9c..895e0d4d71cb5c 100644 --- a/var/spack/repos/builtin/packages/nanomsg/package.py +++ b/var/spack/repos/builtin/packages/nanomsg/package.py @@ -19,3 +19,5 @@ class Nanomsg(CMakePackage): version("1.2", sha256="6ef7282e833df6a364f3617692ef21e59d5c4878acea4f2d7d36e21c8858de67") version("1.1.5", sha256="218b31ae1534ab897cb5c419973603de9ca1a5f54df2e724ab4a188eb416df5a") version("1.0.0", sha256="24afdeb71b2e362e8a003a7ecc906e1b84fd9f56ce15ec567481d1bb33132cc7") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/nanopb/package.py b/var/spack/repos/builtin/packages/nanopb/package.py index 83c6daa425a125..0f8c0ff5871b58 100644 --- a/var/spack/repos/builtin/packages/nanopb/package.py +++ b/var/spack/repos/builtin/packages/nanopb/package.py @@ -17,5 +17,7 @@ class Nanopb(CMakePackage): version("0.3.9.1", sha256="b22d1f86d4adb2aa0436a277c4a59a5adfc467cafeb9bf405c27ef136599bbb3") + depends_on("c", type="build") # generated + depends_on("protobuf", type=("build")) depends_on("py-protobuf", type=("build")) diff --git a/var/spack/repos/builtin/packages/nasm/package.py b/var/spack/repos/builtin/packages/nasm/package.py index d3f2fad668d026..a9861e96cedb7a 100644 --- a/var/spack/repos/builtin/packages/nasm/package.py +++ b/var/spack/repos/builtin/packages/nasm/package.py @@ -27,6 +27,8 @@ class Nasm(AutotoolsPackage, Package): version("2.13.03", sha256="23e1b679d64024863e2991e5c166e19309f0fe58a9765622b35bd31be5b2cc99") version("2.11.06", sha256="3a72476f3cb45294d303f4d34f20961b15323ac24e84eb41bc130714979123bb") + depends_on("c", type="build") # generated + # Fix compilation with GCC 8 # https://bugzilla.nasm.us/show_bug.cgi?id=3392461 patch( diff --git a/var/spack/repos/builtin/packages/nauty/package.py b/var/spack/repos/builtin/packages/nauty/package.py index 056eff96a1fb30..fd9371bcb3e922 100644 --- a/var/spack/repos/builtin/packages/nauty/package.py +++ b/var/spack/repos/builtin/packages/nauty/package.py @@ -20,6 +20,8 @@ class Nauty(AutotoolsPackage): version("2.6r7", sha256="97b5648de17645895cbd56a9a0b3e23cf01f5332c476d013ea459f1a0363cdc6") + depends_on("c", type="build") # generated + # Debian/ Fedora patches for @2.6r7: urls_for_patches = { "@2.6r7": [ diff --git a/var/spack/repos/builtin/packages/nb/package.py b/var/spack/repos/builtin/packages/nb/package.py new file mode 100644 index 00000000000000..528d7d911fb607 --- /dev/null +++ b/var/spack/repos/builtin/packages/nb/package.py @@ -0,0 +1,45 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Nb(Package): + """ + nb is a command line and local web note‑taking, bookmarking, archiving, + and knowledge base application. + """ + + homepage = "https://xwmx.github.io/nb/" + url = "https://github.com/xwmx/nb/archive/refs/tags/7.12.1.tar.gz" + + maintainers("taliaferro") + + license("AGPL-3.0", checked_by="taliaferro") + + version("7.12.1", sha256="c9b30448751dd726469ed3fde29e618c5747eb4a16ceaaf86d773989a6cf13f3") + + depends_on("git") + depends_on("bash") + + def patch(self): + filter_file( + r"^#!\s?.*bash", + "#!{}".format(self.spec["bash"].command.path), + "nb", + "bin/bookmark", + "bin/notes", + "etc/nb-completion.bash", + ) + + def install(self, spec, prefix): + mkdirp(prefix.bin) + mkdirp(prefix + "/share/bash-completion/completions") + install("nb", join_path(prefix, "bin/nb")) + install("bin/notes", join_path(prefix, "bin/notes")) + install("bin/bookmark", join_path(prefix, "bin/bookmark")) + install( + "etc/nb-completion.bash", join_path(prefix, "share/bash-completion/completions/nb") + ) diff --git a/var/spack/repos/builtin/packages/nbdkit/package.py b/var/spack/repos/builtin/packages/nbdkit/package.py index 0f748b9c9e6f70..8c2ad6041a476e 100644 --- a/var/spack/repos/builtin/packages/nbdkit/package.py +++ b/var/spack/repos/builtin/packages/nbdkit/package.py @@ -22,6 +22,9 @@ class Nbdkit(AutotoolsPackage): version("1.23.4", sha256="6581e6cc6dbcb42451abad096efd4e1016b3a0f0d1c7a1724d0a76259ab96429") version("1.23.3", sha256="78f14b00c771733047abcf882e715f62bb19820a6571cae0ccb5f965054697c6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/ncbi-magicblast/package.py b/var/spack/repos/builtin/packages/ncbi-magicblast/package.py index 1fb7379af0a128..15c3c23cfb8a64 100644 --- a/var/spack/repos/builtin/packages/ncbi-magicblast/package.py +++ b/var/spack/repos/builtin/packages/ncbi-magicblast/package.py @@ -16,6 +16,9 @@ class NcbiMagicblast(AutotoolsPackage): version("1.5.0", sha256="b261914d9f7ffc0e655079ceba3e348ba11df1a1f73c4e47a4b1ca154754985c") version("1.3.0", sha256="47b9b65d595b5cb0c4fef22bc7f7c038fb8d4a0accdbe560d7232820575aff67") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cpio", type="build") depends_on("lmdb") diff --git a/var/spack/repos/builtin/packages/ncbi-rmblastn/package.py b/var/spack/repos/builtin/packages/ncbi-rmblastn/package.py index 228c5fc6f60eb7..4700e5e4129910 100644 --- a/var/spack/repos/builtin/packages/ncbi-rmblastn/package.py +++ b/var/spack/repos/builtin/packages/ncbi-rmblastn/package.py @@ -18,6 +18,9 @@ class NcbiRmblastn(AutotoolsPackage): version("2.11.0", sha256="d88e1858ae7ce553545a795a2120e657a799a6d334f2a07ef0330cc3e74e1954") version("2.9.0", sha256="a390cc2d7a09422759fc178db84de9def822cbe485916bbb2ec0d215dacdc257") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + maintainers("snehring") # There is a corresponding gzipped patch file associated with each version. diff --git a/var/spack/repos/builtin/packages/ncbi-toolkit/package.py b/var/spack/repos/builtin/packages/ncbi-toolkit/package.py index 2576cc2cafbf3e..c058ea4e53e3c2 100644 --- a/var/spack/repos/builtin/packages/ncbi-toolkit/package.py +++ b/var/spack/repos/builtin/packages/ncbi-toolkit/package.py @@ -37,6 +37,9 @@ class NcbiToolkit(AutotoolsPackage): url="ftp://ftp.ncbi.nih.gov/toolbox/ncbi_tools++/ARCHIVE/2018/Apr_2_2018/ncbi_cxx--21_0_0.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("debug", default=False, description="Build debug versions of libs and apps") depends_on("boost@1.35.0:+test+log") diff --git a/var/spack/repos/builtin/packages/ncbi-vdb/package.py b/var/spack/repos/builtin/packages/ncbi-vdb/package.py index 88b213c72a474d..32257c5c2e0ccd 100644 --- a/var/spack/repos/builtin/packages/ncbi-vdb/package.py +++ b/var/spack/repos/builtin/packages/ncbi-vdb/package.py @@ -17,6 +17,9 @@ class NcbiVdb(CMakePackage): version("3.0.2", tag="3.0.2", commit="c4aa19632714c2f04af07505721fb16c71bba3d5") version("3.0.0", tag="3.0.0", commit="2222d7727122d0cbad93344dd6a9044abff34280") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("openjdk") depends_on("flex@2.6:") depends_on("libxml2") diff --git a/var/spack/repos/builtin/packages/nccl-fastsocket/package.py b/var/spack/repos/builtin/packages/nccl-fastsocket/package.py index ab69fb4b4ba783..12601c61f4509e 100644 --- a/var/spack/repos/builtin/packages/nccl-fastsocket/package.py +++ b/var/spack/repos/builtin/packages/nccl-fastsocket/package.py @@ -16,6 +16,8 @@ class NcclFastsocket(Package): version("master", preferred=True) + depends_on("cxx", type="build") # generated + depends_on("bazel", type="build") depends_on("nccl", type=["build", "run"]) diff --git a/var/spack/repos/builtin/packages/nccl-tests/package.py b/var/spack/repos/builtin/packages/nccl-tests/package.py index 4ec1d9ffdc3184..0bd21040134ce6 100644 --- a/var/spack/repos/builtin/packages/nccl-tests/package.py +++ b/var/spack/repos/builtin/packages/nccl-tests/package.py @@ -17,6 +17,8 @@ class NcclTests(MakefilePackage, CudaPackage): version("2.13.6", sha256="52b472a58a4918d3221a9b8c4bd9335382643d7e241983918b64692d685cc3d1") version("2.0.0", sha256="731fc3b7c37de59cfe880bf198349ac185639ef23570749ea6aef334c850c49c") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="with MPI support") variant("cuda", default=True, description="with CUDA support, must be true") conflicts("~cuda", msg="nccl-tests require cuda") diff --git a/var/spack/repos/builtin/packages/nccl/package.py b/var/spack/repos/builtin/packages/nccl/package.py index 4517124f661a63..d70ee8180da804 100644 --- a/var/spack/repos/builtin/packages/nccl/package.py +++ b/var/spack/repos/builtin/packages/nccl/package.py @@ -17,6 +17,8 @@ class Nccl(MakefilePackage, CudaPackage): maintainers("adamjstewart") libraries = ["libnccl.so"] + version("2.22.3-1", sha256="45151629a9494460e73375281e8b0fe379141528879301899ece9b776faca024") + version("2.21.5-1", sha256="1923596984d85e310b5b6c52b2c72a1b93da57218f2bc5a5c7ac3d59297a3303") version("2.20.3-1", sha256="19456bd63ca7d23a8319cbbdbaaf6c25949dd51161a9f8809f6b7453282983dd") version("2.19.3-1", sha256="1c5474553afedb88e878c772f13d6f90b9226b3f2971dfa6f873adb9443100c2") version("2.18.5-1", sha256="16ac98f3e926c024ce48e10ab220e19ce734adc48c423cfd55ad6f509bd1179f") @@ -51,6 +53,9 @@ class Nccl(MakefilePackage, CudaPackage): version("2.3.7-1", sha256="e6eff80d9d2db13c61f8452e1400ca2f098d2dfe42857cb23413ce081c5b9e9b") version("2.3.5-5", sha256="bac9950b4d3980c25baa8e3e4541d2dfb4d21edf32ad3b89022d04920357142f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cuda", default=True, description="Build with CUDA") depends_on("rdma-core") diff --git a/var/spack/repos/builtin/packages/nccmp/package.py b/var/spack/repos/builtin/packages/nccmp/package.py index 7204eaff96eb82..af601d662595b4 100644 --- a/var/spack/repos/builtin/packages/nccmp/package.py +++ b/var/spack/repos/builtin/packages/nccmp/package.py @@ -21,6 +21,8 @@ class Nccmp(CMakePackage): version("1.8.9.0", sha256="da5d2b4dcd52aec96e7d96ba4d0e97efebbd40fe9e640535e5ee3d5cd082ae50") version("1.8.2.0", sha256="7f5dad4e8670568a71f79d2bcebb08d95b875506d3d5faefafe1a8b3afa14f18") + depends_on("c", type="build") # generated + depends_on("cmake@3.12:", type="build") depends_on("netcdf-c", type=("build", "run")) depends_on("mpi", when="^netcdf-c+mpi~shared") diff --git a/var/spack/repos/builtin/packages/ncdu/package.py b/var/spack/repos/builtin/packages/ncdu/package.py index 9acbaa9802968f..1b57d8ef954542 100644 --- a/var/spack/repos/builtin/packages/ncdu/package.py +++ b/var/spack/repos/builtin/packages/ncdu/package.py @@ -33,6 +33,8 @@ class Ncdu(Package): version("1.8", sha256="42aaf0418c05e725b39b220166a9c604a9c54c0fbf7692c9c119b36d0ed5d099") version("1.7", sha256="70dfe10b4c0843050ee17ab27b7ad4d65714682f117079b85d779f83431fb333") + depends_on("c", type="build") # generated + depends_on("ncurses") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/ncio/package.py b/var/spack/repos/builtin/packages/ncio/package.py index 80d32a5014a77b..2af462841b51d9 100644 --- a/var/spack/repos/builtin/packages/ncio/package.py +++ b/var/spack/repos/builtin/packages/ncio/package.py @@ -24,6 +24,8 @@ class Ncio(CMakePackage): version("1.1.0", sha256="9de05cf3b8b1291010197737666cede3d621605806379b528d2146c4f02d08f6") version("1.0.0", sha256="2e2630b26513bf7b0665619c6c3475fe171a9d8b930e9242f5546ddf54749bd4") + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("netcdf-fortran") diff --git a/var/spack/repos/builtin/packages/ncl/package.py b/var/spack/repos/builtin/packages/ncl/package.py index b41ddaef1cf109..e3949f4d335d19 100644 --- a/var/spack/repos/builtin/packages/ncl/package.py +++ b/var/spack/repos/builtin/packages/ncl/package.py @@ -28,6 +28,9 @@ class Ncl(Package): version("6.5.0", sha256="133446f3302eddf237db56bf349e1ebf228240a7320699acc339a3d7ee414591") version("6.4.0", sha256="0962ae1a1d716b182b3b27069b4afe66bf436c64c312ddfcf5f34d4ec60153c8") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + patch("for_aarch64.patch", when="target=aarch64:") # Use Spack config file, which we generate during the installation: @@ -136,18 +139,26 @@ def patch(self): # Make configure scripts use Spack's tcsh files = ["Configure"] + glob.glob("config/*") - filter_file("^#!/bin/csh -f", "#!/usr/bin/env csh", *files) - - @run_before("install") - def filter_sbang(self): # Filter sbang before install so Spack's sbang hook can fix it up - files = glob.glob("ncarg2d/src/bin/scripts/*") + files += glob.glob("ncarg2d/src/bin/scripts/*") files += glob.glob("ncarview/src/bin/scripts/*") files += glob.glob("ni/src/scripts/*") csh = join_path(self.spec["tcsh"].prefix.bin, "csh") - filter_file("^#!/bin/csh", "#!{0}".format(csh), *files) + filter_file("^#!/bin/csh.*", "#!{0}".format(csh), *files) + + if self.spec.satisfies("+grib"): + # Newer versions of libjasper do not provide the inmem property + if self.spec.satisfies("^jasper@2"): + filter_file("image.inmem_=1;", "", "external/g2clib-1.6.0/enc_jpeg2000.c") + + filter_file("SUBDIRS = ", "SUBDIRS = g2clib-1.6.0 ", "external/yMakefile") + filter_file( + "INC=.*", + "INC=%s" % self.spec["jasper"].prefix.include, + "external/g2clib-1.6.0/makefile", + ) def install(self, spec, prefix): if (self.compiler.fc is None) or (self.compiler.cc is None): @@ -236,9 +247,11 @@ def prepare_site_config(self): f.writelines( [ "#define HdfDefines\n", - "#define StdDefines -DByteSwapped\n#define ByteSwapped\n" - if self.spec.satisfies("+byteswapped") - else "", + ( + "#define StdDefines -DByteSwapped\n#define ByteSwapped\n" + if self.spec.satisfies("+byteswapped") + else "" + ), "#define CppCommand '/usr/bin/env cpp -traditional'\n", "#define CCompiler {0}\n".format(spack_cc), "#define FCompiler {0}\n".format(spack_fc), @@ -367,7 +380,7 @@ def prepare_install_config(self): with open(config_answers_filename, "r") as f: config_script(input=f) - if self.spec.satisfies("^hdf+external-xdr") and not self.spec["hdf"].satisfies("^libc"): + if self.spec.satisfies("^hdf+external-xdr ^libtirpc"): hdf4 = self.spec["hdf"] replace_str = hdf4["rpc"].libs.link_flags @@ -396,16 +409,3 @@ def delete_files(*filenames): os.remove(filename) except OSError as e: raise InstallError("Failed to delete file %s: %s" % (e.filename, e.strerror)) - - @when("+grib") - def patch(self): - # Newer versions of libjasper do not provide the inmem property - if self.spec.satisfies("^jasper@2"): - filter_file("image.inmem_=1;", "", "external/g2clib-1.6.0/enc_jpeg2000.c") - - filter_file("SUBDIRS = ", "SUBDIRS = g2clib-1.6.0 ", "external/yMakefile") - filter_file( - "INC=.*", - "INC=%s" % self.spec["jasper"].prefix.include, - "external/g2clib-1.6.0/makefile", - ) diff --git a/var/spack/repos/builtin/packages/nco/package.py b/var/spack/repos/builtin/packages/nco/package.py index 2f84bb1a3019b0..8160ca8f58d760 100644 --- a/var/spack/repos/builtin/packages/nco/package.py +++ b/var/spack/repos/builtin/packages/nco/package.py @@ -15,6 +15,7 @@ class Nco(AutotoolsPackage): license("BSD-3-Clause") + version("5.2.4", sha256="44efa9151825487fa0562fa5c6d68837624059a8e2da9d15c83ceb4d498f7902") version("5.1.9", sha256="9cd90345c1e3860a690b53fd6c08b721d631a646d169431927884c99841c34e9") version("5.1.8", sha256="f22c63a3cbe1947fbf06160a6ed7b6d1934aa242fbe3feeb8d1964eef266b7d5") version("5.1.7", sha256="2b068558a605e30a465870166747e1d37726849814a5cfe41a000764b30e2ba1") @@ -40,6 +41,9 @@ class Nco(AutotoolsPackage): version("4.6.1", sha256="7433fe5901f48eb5170f24c6d53b484161e1c63884d9350600070573baf8b8b0") version("4.5.5", sha256="bc6f5b976fdfbdec51f2ebefa158fa54672442c2fd5f042ba884f9f32c2ad666") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # https://github.com/nco/nco/issues/43 patch("NUL-0-NULL.patch", when="@:4.6.7") @@ -60,7 +64,7 @@ class Nco(AutotoolsPackage): def configure_args(self): spec = self.spec - return ["--{0}-doc".format("enable" if "+doc" in spec else "disable")] + return [f"--{'enable' if '+doc' in spec else 'disable'}-doc"] def setup_build_environment(self, env): spec = self.spec diff --git a/var/spack/repos/builtin/packages/ncompress/package.py b/var/spack/repos/builtin/packages/ncompress/package.py index 56b61a98b4ede8..5dbcbdddedd2ca 100644 --- a/var/spack/repos/builtin/packages/ncompress/package.py +++ b/var/spack/repos/builtin/packages/ncompress/package.py @@ -18,5 +18,7 @@ class Ncompress(MakefilePackage): version("4.2.4.6", sha256="112acfc76382e7b631d6cfc8e6ff9c8fd5b3677e5d49d3d9f1657bc15ad13d13") version("4.2.4.5", sha256="2b532f02569e5557e1ed9cbe95c8db0e347a029517d3a50b906119808a996433") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make("install", f"PREFIX={prefix}") diff --git a/var/spack/repos/builtin/packages/ncurses/package.py b/var/spack/repos/builtin/packages/ncurses/package.py index 50694660b552e5..6f3b424ae36d04 100644 --- a/var/spack/repos/builtin/packages/ncurses/package.py +++ b/var/spack/repos/builtin/packages/ncurses/package.py @@ -24,6 +24,7 @@ class Ncurses(AutotoolsPackage, GNUMirrorPackage): license("X11") + version("6.5", sha256="136d91bc269a9a5785e5f9e980bc76ab57428f604ce3e5a5a90cebc767971cc6") version("6.4", sha256="6931283d9ac87c5073f30b6290c4c75f21632bb4fc3603ac8100812bed248159") version("6.3", sha256="97fc51ac2b085d4cde31ef4d2c3122c21abc217e9090a43a30fc5ec21684e059") version("6.2", sha256="30306e0c76e0f9f1f0de987cf1c82a5c21e1ce6568b9227f7da5b71cbea86c9d") @@ -31,6 +32,9 @@ class Ncurses(AutotoolsPackage, GNUMirrorPackage): version("6.0", sha256="f551c24b30ce8bfb6e96d9f59b42fbea30fa3a6123384172f9e7284bcf647260") version("5.9", sha256="9046298fb440324c9d4135ecea7879ffed8546dd1b58e59430ea07a4633f563b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("symlinks", default=False, description="Enables symlinks. Needed on AFS filesystem.") variant( "termlib", @@ -56,6 +60,7 @@ class Ncurses(AutotoolsPackage, GNUMirrorPackage): patch("0001-Fix-errors-in-type-conversion.patch", when="@:5") patch("sed_pgi.patch", when="@:6.0") patch("nvhpc_fix_preprocessor_flag.patch", when="@6.0:6.2%nvhpc") + patch("rxvt_unicode_6_4.patch", when="@6.1:") @classmethod def determine_version(cls, exe): diff --git a/var/spack/repos/builtin/packages/ncurses/rxvt_unicode_6_4.patch b/var/spack/repos/builtin/packages/ncurses/rxvt_unicode_6_4.patch new file mode 100644 index 00000000000000..57bcd9949930aa --- /dev/null +++ b/var/spack/repos/builtin/packages/ncurses/rxvt_unicode_6_4.patch @@ -0,0 +1,203 @@ +--- a/misc/terminfo.src 2024-02-16 03:02:02.153142888 +0100 ++++ b/misc/terminfo.src 2024-02-16 03:08:25.878807875 +0100 +@@ -6921,6 +6921,200 @@ + mrxvt-256color|multitabbed rxvt with 256 colors, + use=xterm+256color, use=mrxvt, + ++#### RXVT-UNICODE ++# From: Thomas Dickey 04 Oct 1997 ++# Updated: Özgür Kesim 02 Nov 1997 ++# Updated: Marc Lehmann , 17 Feb 2005 ++# Updated: Marc Lehmann , 04 Nov 2008: change init/reset sequences ++# Updated: Marc Lehmann , 24 Nov 2014: implement cvvis as blinking cursor ++# Updated: Marc Lehmann , 13 Dec 2014: removed superfluous 0 from sgr ++rxvt-unicode|rxvt-unicode terminal (X Window System), ++ am, ++ bce, ++ eo, ++ km, ++ msgr, ++ xenl, ++ hs, ++ cols#80, ++ it#8, ++ lines#24, ++ acsc=``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~-A.B+C\,D0EhFiG, ++ bel=^G, ++ blink=\E[5m, ++ bold=\E[1m, ++ clear=\E[H\E[2J, ++ civis=\E[?25l, ++ cnorm=\E[?12l\E[?25h, ++ cvvis=\E[?12;25h, ++ cr=^M, ++ csr=\E[%i%p1%d;%p2%dr, ++ cub=\E[%p1%dD, ++ cub1=^H, ++ cud=\E[%p1%dB, ++ cud1=^J, ++ cuf=\E[%p1%dC, ++ cuf1=\E[C, ++ cup=\E[%i%p1%d;%p2%dH, ++ cuu=\E[%p1%dA, ++ cuu1=\E[A, ++ dch=\E[%p1%dP, ++ dch1=\E[P, ++ dl=\E[%p1%dM, ++ dl1=\E[M, ++ ed=\E[J, ++ el=\E[K, ++ el1=\E[1K, ++ flash=\E[?5h$<20/>\E[?5l, ++ home=\E[H, ++ hpa=\E[%i%p1%dG, ++ ht=^I, ++ hts=\EH, ++ ich=\E[%p1%d@, ++ ich1=\E[@, ++ il=\E[%p1%dL, ++ il1=\E[L, ++ ind=^J, ++ is1=\E[\041p, ++ is2=\E[r\E[m\E[2J\E[?7;25h\E[?1;3;4;5;6;9;66;1000;1001;1049l\E[4l, ++ kDC=\E[3$, ++ kDC5=\E[3\^, ++ kDC6=\E[3@, ++ kDN=\E[b, ++ kDN5=\EOb, ++ kIC=\E[2$, ++ kIC5=\E[2\^, ++ kIC6=\E[2@, ++ kEND=\E[8$, ++ kEND5=\E[8\^, ++ kEND6=\E[8@, ++ kFND=\E[1$, ++ kFND5=\E[1\^, ++ kFND6=\E[1@, ++ kHOM=\E[7$, ++ kHOM5=\E[7\^, ++ kHOM6=\E[7@, ++ kLFT=\E[d, ++ kLFT5=\EOd, ++ kNXT=\E[6$, ++ kNXT5=\E[6\^, ++ kNXT6=\E[6@, ++ kPRV=\E[5$, ++ kPRV5=\E[5\^, ++ kPRV6=\E[5@, ++ kRIT=\E[c, ++ kRIT5=\EOc, ++ kUP=\E[a, ++ kUP5=\EOa, ++ kbs=\177, ++ ka1=\EOw, ++ ka3=\EOy, ++ kb2=\EOu, ++ kc1=\EOq, ++ kc3=\EOs, ++ kcbt=\E[Z, ++ kcub1=\E[D, ++ kcud1=\E[B, ++ kcuf1=\E[C, ++ kcuu1=\E[A, ++ kdch1=\E[3~, ++ kel=\E[8\^, ++ kend=\E[8~, ++ kent=\EOM, ++ kf1=\E[11~, ++ kf10=\E[21~, ++ kf11=\E[23~, ++ kf12=\E[24~, ++ kf13=\E[25~, ++ kf14=\E[26~, ++ kf15=\E[28~, ++ kf16=\E[29~, ++ kf17=\E[31~, ++ kf18=\E[32~, ++ kf19=\E[33~, ++ kf2=\E[12~, ++ kf20=\E[34~, ++ kf3=\E[13~, ++ kf4=\E[14~, ++ kf5=\E[15~, ++ kf6=\E[17~, ++ kf7=\E[18~, ++ kf8=\E[19~, ++ kf9=\E[20~, ++ kfnd=\E[1~, ++ khome=\E[7~, ++ kich1=\E[2~, ++ kmous=\E[M, ++ knp=\E[6~, ++ kpp=\E[5~, ++ kslt=\E[4~, ++ rc=\E8, ++ rev=\E[7m, ++ ri=\EM, ++ rmso=\E[27m, ++ rmul=\E[24m, ++ rs1=\Ec, ++ rs2=\E[r\E[m\E[?7;25h\E[?1;3;4;5;6;9;66;1000;1001;1049l\E[4l, ++ sgr0=\E[m\E(B, ++ enacs=, ++ smacs=\E(0, ++ rmacs=\E(B, ++ smso=\E[7m, ++ smul=\E[4m, ++ tbc=\E[3g, ++ vpa=\E[%i%p1%dd, ++ colors#88, ++ pairs#7744, ++ btns#5, ++ lm#0, ++ ccc, ++ npc, ++ mc5i, ++ ncv#0, ++ mir, ++ xon, ++ bw, ++ ech=\E[%p1%dX, ++ mc0=\E[i, ++ mc4=\E[4i, ++ mc5=\E[5i, ++ sitm=\E[3m, ++ ritm=\E[23m, ++ smam=\E[?7h, ++ rmam=\E[?7l, ++ smir=\E[4h, ++ rmir=\E[4l, ++ smcup=\E[?1049h, ++ rmcup=\E[r\E[?1049l, ++ smkx=\E=, ++ rmkx=\E>, ++ indn=\E[%p1%dS, ++ rin=\E[%p1%dT, ++ sgr=\E[%?%p6%t;1%;%?%p2%t;4%;%?%p1%p3%|%t;7%;%?%p4%t;5%;%?%p7%t;8%;m%?%p9%t\E(0%e\E(B%;, ++ op=\E[39;49m, ++ setaf=\E[38;5;%p1%dm, ++ setab=\E[48;5;%p1%dm, ++ setf=%?%p1%{7}%>%t\E[38;5;%p1%dm%e\E[3%?%p1%{1}%=%t4%e%p1%{3}%=%t6%e%p1%{4}%=%t1%e%p1%{6}%=%t3%e%p1%d%;m%;, ++ setb=%?%p1%{7}%>%t\E[48;5;%p1%dm%e\E[4%?%p1%{1}%=%t4%e%p1%{3}%=%t6%e%p1%{4}%=%t1%e%p1%{6}%=%t3%e%p1%d%;m%;, ++ initc=\E]4;%p1%d;rgb\:%p2%{65535}%*%{1000}%/%4.4X/%p3%{65535}%*%{1000}%/%4.4X/%p4%{65535}%*%{1000}%/%4.4X\E\\, ++ sc=\E7, ++ s0ds=\E(B, ++ s1ds=\E(0, ++ s2ds=\E*B, ++ s3ds=\E+B, ++ u6=\E[%i%d;%dR, ++ u7=\E[6n, ++ u8=\E[?1;2c, ++ u9=\E[c, ++ tsl=\E]2;, ++ fsl=\007, ++ dsl=\E]2;\007, ++ ++rxvt-unicode-256color|rxvt-unicode terminal with 256 colors (X Window System), ++ colors#256, ++ pairs#32767, ++ use=rxvt-unicode, ++ + #### ETERM + # From: Michael Jennings + # diff --git a/var/spack/repos/builtin/packages/ncview/package.py b/var/spack/repos/builtin/packages/ncview/package.py index 70fe3098258bc4..c5bca955b96a34 100644 --- a/var/spack/repos/builtin/packages/ncview/package.py +++ b/var/spack/repos/builtin/packages/ncview/package.py @@ -17,6 +17,8 @@ class Ncview(AutotoolsPackage): version("2.1.8", sha256="e8badc507b9b774801288d1c2d59eb79ab31b004df4858d0674ed0d87dfc91be") version("2.1.7", sha256="a14c2dddac0fc78dad9e4e7e35e2119562589738f4ded55ff6e0eca04d682c82") + depends_on("c", type="build") # generated + depends_on("netcdf-c") depends_on("udunits") depends_on("libpng") diff --git a/var/spack/repos/builtin/packages/ncvis/package.py b/var/spack/repos/builtin/packages/ncvis/package.py index aa56e4e342ebcd..c44bd4b14d85b7 100644 --- a/var/spack/repos/builtin/packages/ncvis/package.py +++ b/var/spack/repos/builtin/packages/ncvis/package.py @@ -20,6 +20,8 @@ class Ncvis(CMakePackage): "2022.08.28", sha256="a522926739b2a05ef0b436fe67a2014557f9e5fecf3b7d7700964e9006a4bf3e" ) + depends_on("cxx", type="build") # generated + depends_on("cmake", type="build") depends_on("netcdf-c", type="link") depends_on("wxwidgets+opengl", type="link") diff --git a/var/spack/repos/builtin/packages/ndiff/package.py b/var/spack/repos/builtin/packages/ndiff/package.py index 41b7dbd4a565e8..1aa83a51b2387d 100644 --- a/var/spack/repos/builtin/packages/ndiff/package.py +++ b/var/spack/repos/builtin/packages/ndiff/package.py @@ -23,6 +23,8 @@ class Ndiff(Package): version("2.00", sha256="f2bbd9a2c8ada7f4161b5e76ac5ebf9a2862cab099933167fe604b88f000ec2c") version("1.00", sha256="d4be3ab38e4b87da8d689fe47413e01a7bfdf8c8627bfb673aac37953a463a92") + depends_on("c", type="build") # generated + def install(self, spec, prefix): configure("--prefix=%s" % prefix) diff --git a/var/spack/repos/builtin/packages/ndzip/package.py b/var/spack/repos/builtin/packages/ndzip/package.py index 867cb373dcfd04..91dead20db1011 100644 --- a/var/spack/repos/builtin/packages/ndzip/package.py +++ b/var/spack/repos/builtin/packages/ndzip/package.py @@ -25,6 +25,9 @@ class Ndzip(CMakePackage, CudaPackage): version("master", branch="master") version("2021-11-30", commit="5b3c34991005c0924a339f2ec06750729ebbf015") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cuda", description="build with cuda support", default=False) variant("openmp", description="build with cuda support", default=False) diff --git a/var/spack/repos/builtin/packages/neartree/package.py b/var/spack/repos/builtin/packages/neartree/package.py index a898593b6a1a42..789bff4e6b3cef 100644 --- a/var/spack/repos/builtin/packages/neartree/package.py +++ b/var/spack/repos/builtin/packages/neartree/package.py @@ -17,6 +17,9 @@ class Neartree(MakefilePackage): version("3.1", sha256="07b668516f15a7c13c219fd005b14e73bced5dc6b23857edcc24d3e5cf0d3be3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libtool", type="build") depends_on("cvector") diff --git a/var/spack/repos/builtin/packages/neic-finitefault/fortran-filename-length.patch b/var/spack/repos/builtin/packages/neic-finitefault/fortran-filename-length.patch new file mode 100644 index 00000000000000..c89ec14dcb8759 --- /dev/null +++ b/var/spack/repos/builtin/packages/neic-finitefault/fortran-filename-length.patch @@ -0,0 +1,370 @@ +diff --git a/fortran_code/bin_inversion_gfortran_f95/docs/src/retrieve_gf.f95 b/fortran_code/bin_inversion_gfortran_f95/docs/src/retrieve_gf.f95 +index a87100b..658decf 100644 +--- a/fortran_code/bin_inversion_gfortran_f95/docs/src/retrieve_gf.f95 ++++ b/fortran_code/bin_inversion_gfortran_f95/docs/src/retrieve_gf.f95 +@@ -139,9 +139,9 @@ contains + real omega, block, lat_e, lon_e, lat_s(nnsta), lon_s(nnsta), dt, depth, & + & weig, df, dt_sample, w, tlen + complex z0, z +- character(len=80) path ++ character(len=255) path + character(len=6) sta_name(nnsta) +- character(len=80) filename ++ character(len=255) filename + character(len=3) component(nnsta), comp + + z0 = cmplx(0.0, 0.0) +@@ -244,9 +244,9 @@ contains + real omega, block, lat_e, lon_e, lat_s(nnsta), lon_s(nnsta), dt, depth, & + & weig, df, dt_sample, w, low_freq, tlen + complex z0, z +- character(len=80) path ++ character(len=255) path + character(len=6) sta_name(nnsta) +- character(len=80) filename ++ character(len=255) filename + character(len=3) component(nnsta), comp + + z0 = cmplx(0.0, 0.0) +@@ -572,8 +572,8 @@ contains + complex :: kahan_y, kahan_t, kahan_c + complex sour_sub(npth), green_s(inptd, 10), www, wss, z0 + +- character(len=250) modes +- character(len=100) surf_gf_bank ++ character(len=255) modes ++ character(len=255) surf_gf_bank + character(len=6) sta_name(nnsta) + + z0 = cmplx(0.0, 0.0) +@@ -776,9 +776,9 @@ contains + & gf_imag(inptd), h, time, tsub(nnxy_m), a + complex z0, z, sour_sub(npth) + complex :: kahan_y, kahan_t, kahan_c +- character(len=80) path ++ character(len=255) path + character(len=6) sta_name(nnsta) +- character(len=80) filename ++ character(len=255) filename + + z0 = cmplx(0.0, 0.0) + n_chan3 = 0 +diff --git a/fortran_code/bin_inversion_gfortran_f95/docs/src/retrieve_surf_gf.f95 b/fortran_code/bin_inversion_gfortran_f95/docs/src/retrieve_surf_gf.f95 +index 6123151..416d81d 100644 +--- a/fortran_code/bin_inversion_gfortran_f95/docs/src/retrieve_surf_gf.f95 ++++ b/fortran_code/bin_inversion_gfortran_f95/docs/src/retrieve_surf_gf.f95 +@@ -15,8 +15,8 @@ contains + + subroutine get_surf_gf_data(gf_file, gf_bank) + implicit none +- character(len=100), intent(in) :: gf_file +- character(len=100), intent(out) :: gf_bank ++ character(len=255), intent(in) :: gf_file ++ character(len=255), intent(out) :: gf_bank + integer :: int2, int3, int4 + open(1, file=gf_file) + read(1, *) npt_bank, dt_bank, int2, int3, int4, nfmax, nblock2 +@@ -36,7 +36,7 @@ contains + !! Load to memory GF bank, from a specified location. + !! + implicit none +- character(len=100) :: gf_bank ++ character(len=255) :: gf_bank + real :: d_min, d_max, z_min, z_max + integer :: nx_b, nx_e, nz_b, nz_e, ixx, izz + integer :: index_rec +diff --git a/fortran_code/bin_inversion_gfortran_f95/get_stations_data.f95 b/fortran_code/bin_inversion_gfortran_f95/get_stations_data.f95 +index e47dea1..e6bd2d7 100755 +--- a/fortran_code/bin_inversion_gfortran_f95/get_stations_data.f95 ++++ b/fortran_code/bin_inversion_gfortran_f95/get_stations_data.f95 +@@ -153,8 +153,8 @@ contains + & n_wave_weight, stations, channels0, int1, int2, used_channels + real dt, weig(max_stations), wavelet_weight0(11), dt_sample, lat_s, lon_s + logical, parameter :: dart = .False. +- character(len=20) filename, string2, string1 +- character(len=30) event_file, channels_file, wavelets_file, waveforms_file ++ character(len=255) filename, string2, string1 ++ character(len=255) event_file, channels_file, wavelets_file, waveforms_file + logical :: is_file, strong, cgps + ! character(len=6) sta_name(max_stations) + ! character(len=3) component(max_stations) +@@ -258,7 +258,7 @@ contains + real lat_sta, lon_sta, wavelet_weight0(11), dt, & + & rang, az, angle, float1, float2 + logical, parameter :: cgps=.False., dart = .False. +- character(len=20) filename, string1, string2 ++ character(len=255) filename, string1, string2 + character(len=30) event_file + character(len=6) earth, sttyp + character(len=14) fname +@@ -361,10 +361,10 @@ contains + & weig(max_stations, 3), wavelet_weight0(11), dt_sample, & + & dip, rake, theta + logical, parameter :: cgps=.False., dart=.False. +- character(len=20) filename, string1, string2 ++ character(len=255) filename, string1, string2 + character(len=30) event_file + ! character(len=6) sta_name(max_stations) +- character(len=250) modes ++ character(len=255) modes + logical :: is_file + + write(*,*)'Get stations metadata and waveforms for long period surface waves...' +@@ -469,7 +469,7 @@ contains + & n_wave_weight, stations, channels0, int1, int2, used_channels + real :: lat_s, lon_s, dt, weig(max_stations), wavelet_weight0(11), dt_sample + logical, parameter :: cgps=.False., dart=.True. +- character(len=20) filename ++ character(len=255) filename + ! character(len=6) sta_name(max_stations) + ! character(len=3) component(max_stations) + +@@ -544,7 +544,7 @@ contains + integer first, channel, i, j, channels0 + real :: dto + character(len=40) string +- character(len=20) filename ++ character(len=255) filename + + filename = trim(filename) + open(13, file=filename, status='old') +diff --git a/fortran_code/bin_inversion_gfortran_f95/retrieve_gf.f95 b/fortran_code/bin_inversion_gfortran_f95/retrieve_gf.f95 +index b37efeb..a47ffcd 100755 +--- a/fortran_code/bin_inversion_gfortran_f95/retrieve_gf.f95 ++++ b/fortran_code/bin_inversion_gfortran_f95/retrieve_gf.f95 +@@ -116,7 +116,7 @@ contains + & l, k, event + real :: omega, factor, start, dt, df, dt_sample, tlen + complex :: z0, z +- character(len=80) filename, filename2 ++ character(len=255) filename, filename2 + character(len=3) comp + character(len=1) channel2 + character(len=2) event2 +@@ -414,8 +414,8 @@ contains + complex :: kahan_y, kahan_t, kahan_c + complex start(wave_pts), green_s(wave_pts2, 10), green_dip0, green_stk0, z0 + +- character(len=250) modes +- character(len=100) surf_gf_bank ++ character(len=255) modes ++ character(len=255) surf_gf_bank + character(len=6) sta_name1 + logical :: many_events + +@@ -632,7 +632,7 @@ contains + & k, l, etc + real :: omega, dt, df, dt_sample, start, tlen, real1, imag1, time + complex :: z0, z +- character(len=80) filename ++ character(len=255) filename + + write(*,*)'Store DART GF in memory...' + z0 = cmplx(0.0, 0.0) +diff --git a/fortran_code/bin_inversion_gfortran_f95/retrieve_surf_gf.f95 b/fortran_code/bin_inversion_gfortran_f95/retrieve_surf_gf.f95 +index e07e1f3..bfc5250 100755 +--- a/fortran_code/bin_inversion_gfortran_f95/retrieve_surf_gf.f95 ++++ b/fortran_code/bin_inversion_gfortran_f95/retrieve_surf_gf.f95 +@@ -20,8 +20,8 @@ contains + ! gf_bank: location of GF bank + ! + implicit none +- character(len=100), intent(in) :: gf_file +- character(len=100), intent(out) :: gf_bank ++ character(len=255), intent(in) :: gf_file ++ character(len=255), intent(out) :: gf_bank + integer :: int2, int3, int4 + open(1, file=gf_file, status='old') + read(1, *) npt_bank, dt_bank, int2, int3, int4, nfmax, nblock2 +@@ -71,7 +71,7 @@ contains + ! z_max: maximum depth to get GF from Gf bank + ! + implicit none +- character(len=100) :: gf_bank ++ character(len=255) :: gf_bank + real :: d_min, d_max, z_min, z_max + integer :: nx_b, nx_e, nz_b, nz_e, ixx, izz + integer :: index_rec +diff --git a/fortran_code/bin_inversion_gfortran_f95/save_forward.f95 b/fortran_code/bin_inversion_gfortran_f95/save_forward.f95 +index 987b115..b626166 100755 +--- a/fortran_code/bin_inversion_gfortran_f95/save_forward.f95 ++++ b/fortran_code/bin_inversion_gfortran_f95/save_forward.f95 +@@ -114,7 +114,7 @@ contains + real*8 t1, t2, df + complex forward(wave_pts2), z0, z + complex :: source2(wave_pts, max_rise_time_range, max_rise_time_range) +- character(len=70) filename, filename2 ++ character(len=255) filename, filename2 + character(len=3) comp!component(max_stations), comp + logical :: strong, cgps + +diff --git a/fortran_code/bin_inversion_gfortran_f95/static_data.f95 b/fortran_code/bin_inversion_gfortran_f95/static_data.f95 +index 9e5bc3a..28e9085 100755 +--- a/fortran_code/bin_inversion_gfortran_f95/static_data.f95 ++++ b/fortran_code/bin_inversion_gfortran_f95/static_data.f95 +@@ -52,7 +52,7 @@ contains + real :: cosal, sinal, angle + real*8 :: disp + logical is_file, is_file2, many_events +- character(len=30) :: event_file, string1, string2 ++ character(len=255) :: event_file, string1, string2 + ! + inquire( file = 'static_data.txt', exist = is_file ) + if (is_file) then +diff --git a/fortran_code/bin_str_f95/get_stations_data.f95 b/fortran_code/bin_str_f95/get_stations_data.f95 +index 49e5788..a43990c 100755 +--- a/fortran_code/bin_str_f95/get_stations_data.f95 ++++ b/fortran_code/bin_str_f95/get_stations_data.f95 +@@ -66,7 +66,7 @@ contains + & n_wave_weight, ir_max, n_chan, & + & nos(nnsta), io_mod(nnsta), n_chan3 + real dt, weig(nnsta), j_wig(11), dt_sample, lat_s, lon_s +- character(len=20) filename ++ character(len=255) filename + ! character(len=6) sta_name(nnsta) + ! character(len=3) component(nnsta) + +@@ -144,7 +144,7 @@ contains + & n_wave_weight, ir_max, n_chan, & + & nos(nnsta), io_mod(nnsta), n_chan3 + real :: lat_s, lon_s, dt, weig(nnsta), j_wig(11), dt_sample +- character(len=20) filename ++ character(len=255) filename + ! character(len=6) sta_name(nnsta) + ! character(len=3) component(nnsta) + +@@ -221,7 +221,7 @@ contains + & nos, n_chan3, idts, nstaon, love, int1 + real lat_sta, lon_sta, j_wig(11), dt, & + & rang, az, earth_angle, disp_or_vel(nnsta), float1, float2 +- character(len=20) filename ++ character(len=255) filename + character(len=6) earth, sttyp + character(len=14) fname + +@@ -303,9 +303,9 @@ contains + real lat_s(nnsta), lon_s(nnsta), dt, & + & ang_ns(nnsta), ang_ew(nnsta), weig(nnsta, 3), j_wig(11), dt_sample, & + & dip, rake, theta +- character(len=20) filename ++ character(len=255) filename + ! character(len=6) sta_name(nnsta) +- character(len=250) modes ++ character(len=255) modes + + n_chan3 = 0 + ! +@@ -401,7 +401,7 @@ contains + integer ll_in, ll_out, ll_g, j_con(11), k, ir, no, & + & n_wave_weight, ir_max, n_chan, nos, io_mod, n_chan3 + real :: lat_s, lon_s, dt, weig(nnsta), j_wig(11), dt_sample +- character(len=20) filename ++ character(len=255) filename + ! character(len=6) sta_name(nnsta) + ! character(len=3) component(nnsta) + +@@ -476,7 +476,7 @@ contains + real cr(inptd), cz(inptd), obser(n_data), & + & dto, amp_max, obse(n_data, nnsta) + character(len=40) string +- character(len=20) filename ++ character(len=255) filename + + filename = trim(filename) + open(13, file=filename, status='old') +diff --git a/fortran_code/bin_str_f95/get_strong_motion.f95 b/fortran_code/bin_str_f95/get_strong_motion.f95 +index ff6f158..b13e734 100755 +--- a/fortran_code/bin_str_f95/get_strong_motion.f95 ++++ b/fortran_code/bin_str_f95/get_strong_motion.f95 +@@ -14,10 +14,10 @@ program get_strong_motion + use bpfilter, only : bandpassfilter + use rad_pattern, only : rad_coef + implicit none +- character(len=100) :: vel_model, gf_file, vel_file, gf_bank, filter_file, wave_file, stat_file ++ character(len=255) :: vel_model, gf_file, vel_file, gf_bank, filter_file, wave_file, stat_file + character(len=70) :: string1, input +- character(len=200) :: directory,filterfile,risetimefile,pointsourcefile +- character(len=200) :: channelsfile,waveformsfile,responsefile ++ character(len=255) :: directory,filterfile,risetimefile,pointsourcefile ++ character(len=255) :: channelsfile,waveformsfile,responsefile + character(len=10) :: sta_name(200) + character(len=12) :: filename + character(len=3) :: comp +diff --git a/fortran_code/bin_str_f95/retrieve_gf.f95 b/fortran_code/bin_str_f95/retrieve_gf.f95 +index 6a80593..fac8795 100755 +--- a/fortran_code/bin_str_f95/retrieve_gf.f95 ++++ b/fortran_code/bin_str_f95/retrieve_gf.f95 +@@ -22,8 +22,8 @@ contains + ! vel_model: file with velocity model + ! + implicit none +- character(len=100), intent(in) :: gf_file +- character(len=100), intent(out) :: vel_model, gf_bank ++ character(len=255), intent(in) :: gf_file ++ character(len=255), intent(out) :: vel_model, gf_bank + open(1, file=gf_file, status='old') + read(1, *)vel_model + read(1, *)dep_max, dep_min, dep_step +@@ -44,7 +44,7 @@ contains + ! z_max: maximum depth of point sources + ! + implicit none +- character(len=100) :: gf_bank ++ character(len=255) :: gf_bank + real :: z_min, z_max + integer :: npt, nx_b, nx_e, nz_b, nz_e, ixx, izz + integer :: index_rec +diff --git a/fortran_code/bin_str_f95/store_gf.f95 b/fortran_code/bin_str_f95/store_gf.f95 +index b544795..8b92bc7 100644 +--- a/fortran_code/bin_str_f95/store_gf.f95 ++++ b/fortran_code/bin_str_f95/store_gf.f95 +@@ -81,7 +81,7 @@ contains + ! disp: True if data to be used is cGPS, False otherwise + ! + implicit none +- character(len=100) :: filter_file, wave_file, stat_file, event_file ++ character(len=255) :: filter_file, wave_file, stat_file, event_file + character(len=70) :: string1, string2 + real :: lat_e, lon_e, dep_e + integer :: ir, no +diff --git a/fortran_code/src_dc_f95/green_bank_fk.f95 b/fortran_code/src_dc_f95/green_bank_fk.f95 +index aed84e9..76db003 100644 +--- a/fortran_code/src_dc_f95/green_bank_fk.f95 ++++ b/fortran_code/src_dc_f95/green_bank_fk.f95 +@@ -20,7 +20,7 @@ program green_bank_fk + integer iz, k, ll, n_com, nd_max, npt, ntc, nx, nz + logical :: disp + +- character(len=100) gf_file, vel_model, gf_bank, input ++ character(len=255) gf_file, vel_model, gf_bank, input + ! + call getarg(1, input) + disp = (input.eq.'cgps') +diff --git a/fortran_code/src_dc_f95/green_bank_fk_openmp.f95 b/fortran_code/src_dc_f95/green_bank_fk_openmp.f95 +index 4d89e33..3f819b1 100644 +--- a/fortran_code/src_dc_f95/green_bank_fk_openmp.f95 ++++ b/fortran_code/src_dc_f95/green_bank_fk_openmp.f95 +@@ -20,7 +20,7 @@ program green_bank_fk_openmp + integer iz, k, ll, n_com, nd_max, npt, ntc, nx, nz + logical :: disp + +- character(len=100) gf_file, vel_model, gf_bank, input, directory ++ character(len=255) gf_file, vel_model, gf_bank, input, directory + ! + call getarg(1, input) + call getarg(2, directory) +diff --git a/fortran_code/src_dc_f95/retrieve_gf.f95 b/fortran_code/src_dc_f95/retrieve_gf.f95 +index 94191d6..555ec59 100755 +--- a/fortran_code/src_dc_f95/retrieve_gf.f95 ++++ b/fortran_code/src_dc_f95/retrieve_gf.f95 +@@ -24,8 +24,8 @@ contains + ! gf_bank: location of GF bank + ! + implicit none +- character(len=100), intent(in) :: gf_file +- character(len=100), intent(out) :: vel_model, gf_bank ++ character(len=255), intent(in) :: gf_file ++ character(len=255), intent(out) :: vel_model, gf_bank + open(1, file=gf_file, status='old') + read(1, *)vel_model + read(1, *)dep_max, dep_min, dep_step diff --git a/var/spack/repos/builtin/packages/neic-finitefault/package.py b/var/spack/repos/builtin/packages/neic-finitefault/package.py new file mode 100644 index 00000000000000..93607c6220a8c4 --- /dev/null +++ b/var/spack/repos/builtin/packages/neic-finitefault/package.py @@ -0,0 +1,145 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class NeicFinitefault(PythonPackage): + """Wavelet and simulated Annealing SliP inversion (WASP). + This code uses a nonlinear simulated annealing inversion method to + model slip amplitude, rake, rupture time, and rise time on a discretized + fault plane, finding the solution that best fits the observations in + the wavelet domain.""" + + homepage = "https://code.usgs.gov/ghsc/neic/algorithms/neic-finitefault" + + url = "https://code.usgs.gov/ghsc/neic/algorithms/neic-finitefault/-/archive/0.1.0/neic-finitefault-0.1.0.tar.gz" + git = "https://code.usgs.gov/ghsc/neic/algorithms/neic-finitefault" + + maintainers("snehring") + + license("CC0-1.0", checked_by="snehring") + + version("20240410", commit="ef6a1a92d60549100885112e24a18e38d8d4ce0b") + version("0.1.0", sha256="36b400dfc418bf78a3099f6fc308681c87ae320e6d71c7d0e98a2738e72fb570") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + + resource( + name="fd_bank", + url="https://zenodo.org/records/7236739/files/fd_bank", + sha256="fe0f1a392cb9b6623c981de2a4fae405d9820b14e274e287e64731aede8ecb40", + expand=False, + when="@0.1.0:", + ) + resource( + name="LITHO1.0.nc", + url="https://ds.iris.edu/files/products/emc/emc-files/LITHO1.0.nc", + sha256="4429bdf3fc2a5402064b40b059faf3a79d9ce0818feb1b13122e169af56f4b43", + expand=False, + when="@0.1.0:", + ) + resource( + name="tectonicplates", + url="https://github.com/fraxen/tectonicplates/archive/339b0c56563c118307b1f4542703047f5f698fae.zip", + sha256="694ebf7090db07e47b07f1ae21175c4a5fa9c85bb79815680e439c1032407b95", + when="@0.1.0:", + ) + + depends_on("python@3.9:3.12", type=("build", "run")) + + depends_on("py-poetry-core@1:", type="build") + + depends_on("py-cartopy@0.21.1:0", type=("build", "run")) + depends_on("py-ipykernel@6.15:6", type=("build", "run")) + depends_on("py-matplotlib@3.8.3:3", type=("build", "run")) + depends_on("py-matplotlib@3.7.2:3", type=("build", "run"), when="@0.1.0") + depends_on("py-netcdf4@1.6.4:1~mpi", type=("build", "run")) + depends_on("py-numpy@1.25:1", type=("build", "run")) + depends_on("py-obspy@1.4:1", type=("build", "run")) + depends_on("py-pygmt@0.9:0.9", type=("build", "run")) + depends_on("py-pyproj@3.3:3", type=("build", "run")) + depends_on("py-scipy@1.11.1:1", type=("build", "run")) + depends_on("py-shapely@=1.7.1", type=("build", "run")) + depends_on("py-pyrocko@=2023.6.29", type=("build", "run")) + depends_on("py-typer@0.9", type=("build", "run")) + depends_on("py-okada-wrapper@=18.12.07.3", type=("build", "run")) + + # non python deps + depends_on("geos@=3.11.2", type=("build", "run")) + depends_on("gmt@=6.4.0", type=("build", "run")) + depends_on("proj@=9.2.0", type=("build", "run")) + # not a direct dep, but we do need gdal to have these variants + depends_on("gdal+jpeg+jxl+openjpeg", type=("build", "run")) + + parallel = False + + patch("fortran-filename-length.patch") + + @run_before("install") + def build(self): + # place resources, couldn't figure out another way to do this + # that didn't result in symlinks + relevant_resources = [ + resource + for resource_spec, resource_list in self.resources.items() + if self.spec.intersects(resource_spec) + for resource in resource_list + ] + for resource in relevant_resources: + res_path = resource.fetcher.stage.source_path + if resource.name == "fd_bank": + res_dst = join_path(self.build_directory, "fortran_code", "gfs_nm", "long") + elif resource.name == "LITHO1.0.nc": + res_dst = join_path(self.build_directory, "fortran_code", "info") + elif resource.name == "tectonicplates": + res_dst = self.build_directory + + res_dst = join_path(res_dst, resource.name) + + if resource.name == "tectonicplates": + copy_tree(res_path, res_dst) + else: + copy(join_path(res_path, resource.name), res_dst) + + # everything about this seems to assume it's going to reside where it's compiled + mkdirp(self.prefix) + install_tree(".", self.prefix) + + with working_dir(self.prefix.fortran_code): + with open(join_path("gfs_nm", "long", "low.in"), mode="a") as f: + f.write(f"\n{self.prefix.fortran_code.gfs_nm.long.fd_bank}") + # compile fortran code + with working_dir("bin_inversion_gfortran_f95"): + make("clean") + make() + with working_dir("bin_str_f95"): + make("clean") + make() + with working_dir("src_dc_f95"): + make("clean") + make() + + @run_after("install") + def generate_config_file(self): + file = f"""[PATHS] +code_path = {self.prefix} +surf_gf_bank = {join_path(self.prefix.fortran_code.gfs_nm.long, "low.in")} +modelling = {self.prefix.fortran_code.bin_inversion_gfortran_f95} +get_near_gf = {self.prefix.fortran_code.bin_str_f95} +compute_near_gf = {self.prefix.fortran_code.src_dc_f95} +info = {self.prefix.fortran_code.info} +cartopy_files = {self.prefix.tectonicplates}""" + + with working_dir(self.prefix): + with open("config.ini", mode="w") as f: + f.write(file) + symlink( + join_path(self.prefix, "config.ini"), + join_path( + self.prefix.lib, f"python{self.spec['python'].version.up_to(2)}", "config.ini" + ), + ) diff --git a/var/spack/repos/builtin/packages/nek5000/package.py b/var/spack/repos/builtin/packages/nek5000/package.py index 2936177d7246e4..5221d0cb234c61 100644 --- a/var/spack/repos/builtin/packages/nek5000/package.py +++ b/var/spack/repos/builtin/packages/nek5000/package.py @@ -33,6 +33,9 @@ class Nek5000(Package): version("17.0", sha256="4d8d4793ce3c926c54e09a5a5968fa959fe0ba46bd2e6b8043e099528ee35a60") version("19.0", sha256="db129877a10ff568d49edc77cf65f9e732eecb1fce10edbd91ffc5ac10c41ad6") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # MPI, Profiling and Visit variants variant("mpi", default=True, description="Build with MPI.") variant("profiling", default=True, description="Build with profiling data.") diff --git a/var/spack/repos/builtin/packages/nekbone/package.py b/var/spack/repos/builtin/packages/nekbone/package.py index 23a494119d2c62..e6d36687cee2d7 100644 --- a/var/spack/repos/builtin/packages/nekbone/package.py +++ b/var/spack/repos/builtin/packages/nekbone/package.py @@ -27,6 +27,9 @@ class Nekbone(Package): extension=".tar.gz", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # Variants variant("mpi", default=True, description="Build with MPI") diff --git a/var/spack/repos/builtin/packages/nekcem/package.py b/var/spack/repos/builtin/packages/nekcem/package.py index 76fae8fd6cd5ad..51b8cc0b525ebe 100644 --- a/var/spack/repos/builtin/packages/nekcem/package.py +++ b/var/spack/repos/builtin/packages/nekcem/package.py @@ -27,6 +27,9 @@ class Nekcem(Package): version("0b8bedd", commit="0b8beddfdcca646bfcc866dfda1c5f893338399b") version("7332619", commit="7332619b73d03868a256614b61794dce2d95b360") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # dependencies depends_on("mpi", when="+mpi") depends_on("blas") diff --git a/var/spack/repos/builtin/packages/neko/package.py b/var/spack/repos/builtin/packages/neko/package.py index 3eab17ecabc564..7b83d6b83dc350 100644 --- a/var/spack/repos/builtin/packages/neko/package.py +++ b/var/spack/repos/builtin/packages/neko/package.py @@ -16,6 +16,7 @@ class Neko(AutotoolsPackage, CudaPackage, ROCmPackage): url = "https://github.com/ExtremeFLOW/neko/releases/download/v0.3.2/neko-0.3.2.tar.gz" maintainers("njansson") + version("0.8.0", sha256="09d0b253c8abda9f384bf8f03b17b50d774cb0a1f7b72744a8e863acac516a51") version("0.7.2", sha256="5dd17fbae83d0b26dc46fafce4e5444be679cdce9493cef4ff7d504e2f854254") version("0.7.1", sha256="c935c3d93b0975db46448045f97aced6ac2cab31a2b8803047f8086f98dcb981") version("0.7.0", sha256="fe871e0a79f388073e0b3dc191d1c0d5da3a53883f5b1951d88b9423fc79a53c") @@ -29,9 +30,13 @@ class Neko(AutotoolsPackage, CudaPackage, ROCmPackage): version("0.3.2", sha256="0628910aa9838a414f2f27d09ea9474d1b3d7dcb5a7715556049a2fdf81a71ae") version("0.3.0", sha256="e46bef72f694e59945514ab8b1ad7d74f87ec9dca2ba2b230e2148662baefdc8") version("develop", branch="develop") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated variant("parmetis", default=False, description="Build with support for parmetis") variant("xsmm", default=False, description="Build with support for libxsmm") - variant("gslib", default=False, when="@develop", description="Build with support for gslib") + variant("gslib", default=False, when="@0.7.0:", description="Build with support for gslib") + variant("hdf5", default=False, when="@develop", description="Build with support for HDF5") # Requires cuda or rocm enabled MPI variant( @@ -54,6 +59,7 @@ class Neko(AutotoolsPackage, CudaPackage, ROCmPackage): depends_on("json-fortran", when="@develop") depends_on("json-fortran", when="@0.7.0:") depends_on("gslib", when="+gslib") + depends_on("hdf5+fortran+mpi", when="+hdf5") def configure_args(self): args = [] @@ -63,6 +69,7 @@ def configure_args(self): args += self.with_or_without("metis", variant="parmetis", activation_value="prefix") args += self.with_or_without("libxsmm", variant="xsmm") args += self.with_or_without("gslib", variant="gslib", activation_value="prefix") + args += self.with_or_without("hdf5", variant="hdf5", activation_value="prefix") args += self.with_or_without("cuda", activation_value="prefix") rocm_fn = lambda x: self.spec["hip"].prefix args += self.with_or_without("hip", variant="rocm", activation_value=rocm_fn) diff --git a/var/spack/repos/builtin/packages/nekrs/package.py b/var/spack/repos/builtin/packages/nekrs/package.py index d3c9c41b74650f..1472bd26c46bcf 100644 --- a/var/spack/repos/builtin/packages/nekrs/package.py +++ b/var/spack/repos/builtin/packages/nekrs/package.py @@ -34,6 +34,10 @@ class Nekrs(Package, CudaPackage, ROCmPackage): version("21.0", tag="v21.0", commit="bcd890bf3f9fb4d91224c83aeda75c33570f1eaa") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("opencl", default=False, description="Activates support for OpenCL") # Conflicts: diff --git a/var/spack/repos/builtin/packages/nektar/package.py b/var/spack/repos/builtin/packages/nektar/package.py index a236bd5c4e9391..482a66a31ceae1 100644 --- a/var/spack/repos/builtin/packages/nektar/package.py +++ b/var/spack/repos/builtin/packages/nektar/package.py @@ -3,6 +3,10 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os + +import llnl.util.filesystem as fs + from spack.package import * @@ -10,30 +14,109 @@ class Nektar(CMakePackage): """Nektar++: Spectral/hp Element Framework""" homepage = "https://www.nektar.info/" - url = "https://gitlab.nektar.info/nektar/nektar/-/archive/v4.4.1/nektar-v4.4.1.tar.bz2" + git = "https://gitlab.nektar.info/nektar/nektar.git" - version("5.0.0", sha256="5c594453fbfaa433f732a55405da9bba27d4a00c32d7b9d7515767925fb4a818") - version("4.4.1", sha256="71cfd93d848a751ae9ae5e5ba336cee4b4827d4abcd56f6b8dc5c460ed6b738c") + version("5.5.0", commit="4365d5d7156139f238db962deae5eb25e0437d12", preferred=True) + version("5.4.0", commit="002bf62648ec667e10524ceb8a98bb1c21804130") + version("5.3.0", commit="f286f809cfeb26cb73828c90a689a048898971d2") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated variant("mpi", default=True, description="Builds with mpi support") variant("fftw", default=True, description="Builds with fftw support") variant("arpack", default=True, description="Builds with arpack support") + variant("tinyxml", default=True, description="Builds with external tinyxml support") variant("hdf5", default=True, description="Builds with hdf5 support") variant("scotch", default=False, description="Builds with scotch partitioning support") + variant("demos", default=False, description="Build demonstration codes") + variant("python", default=True, description="Enable python support") + # Solver variants + variant( + "acoustic_solver", + default=False, + description="Builds an executable associated with the Acoustic solver", + ) + variant( + "adr_solver", + default=False, + description="Builds an executable associated with the ADR solver", + ) + variant( + "cardiac_solver", + default=False, + description="Builds an executable associated with the Cardiac electrophysiology solver", + ) + variant( + "compflow_solver", + default=False, + description="Builds an executable associated with the CompressibleFlow solver", + ) + variant( + "diff_solver", + default=False, + description="Builds an executable associated with the Diffusion solver", + ) + variant( + "dummy_solver", + default=False, + description="Builds an executable associated with the Dummy solver", + ) + variant( + "elasticity_solver", + default=False, + description="Builds an executable associated with the Elasticity solver", + ) + variant( + "imgwarp_solver", + default=False, + description="Builds an executable associated with the Image Warping solver", + ) + variant( + "ins_solver", + default=False, + description="Builds an executable associated with the Incompressible Navier Stokes solver", + ) + variant( + "mmf_solver", + default=False, + description="Builds an executable associated with the MMF solver", + ) + variant( + "pulsewave_solver", + default=False, + description="Builds an executable associated with the Pulse Wave solver", + ) + variant( + "shwater_solver", + default=False, + description="Builds an executable associated with the Shallow Water solver", + ) + variant( + "vortexwave_solver", + default=False, + description="Builds an executable associated with the Vortex Wave solver", + ) depends_on("cmake@2.8.8:", type="build", when="~hdf5") depends_on("cmake@3.2:", type="build", when="+hdf5") depends_on("blas") + depends_on("zlib") + depends_on("tinyxml", when="+tinyxml") depends_on("lapack") depends_on( - "boost@1.56.0:" - "+iostreams+exception+filesystem+system+chrono+serialization" - "+atomic+regex+math+thread+container" + "boost@1.74.0: +thread +iostreams +filesystem +system +program_options +regex +pic" + "+python +numpy", + when="+python", + ) + depends_on( + "boost@1.74.0: +thread +iostreams +filesystem +system +program_options +regex +pic", + when="~python", ) depends_on("tinyxml", when="platform=darwin") - depends_on("mpi", when="+mpi") + depends_on("mpi", when="+mpi", type=("build", "link", "run")) depends_on("fftw@3.0: +mpi", when="+mpi+fftw") depends_on("fftw@3.0: ~mpi", when="~mpi+fftw") depends_on("arpack-ng +mpi", when="+arpack+mpi") @@ -42,18 +125,70 @@ class Nektar(CMakePackage): depends_on("scotch ~mpi ~metis", when="~mpi+scotch") depends_on("scotch +mpi ~metis", when="+mpi+scotch") + extends("python@3:", when="+python") + conflicts("+hdf5", when="~mpi", msg="Nektar's hdf5 output is for parallel builds only") def cmake_args(self): - args = [] - def hasfeature(feature): - return "ON" if feature in self.spec else "OFF" - - args.append("-DNEKTAR_USE_MPI=%s" % hasfeature("+mpi")) - args.append("-DNEKTAR_USE_FFTW=%s" % hasfeature("+fftw")) - args.append("-DNEKTAR_USE_ARPACK=%s" % hasfeature("+arpack")) - args.append("-DNEKTAR_USE_HDF5=%s" % hasfeature("+hdf5")) - args.append("-DNEKTAR_USE_SCOTCH=%s" % hasfeature("+scotch")) - args.append("-DNEKTAR_USE_PETSC=OFF") + return True if feature in self.spec else False + + args = [ + self.define_from_variant("NEKTAR_BUILD_DEMOS", "demos"), + self.define_from_variant("NEKTAR_BUILD_PYTHON", "python"), + self.define("NEKTAR_BUILD_SOLVERS", True), + self.define("NEKTAR_BUILD_UTILITIES", True), + self.define("NEKTAR_ERROR_ON_WARNINGS", False), + self.define_from_variant("NEKTAR_SOLVER_ACOUSTIC", "acoustic_solver"), + self.define_from_variant("NEKTAR_SOLVER_ADR", "adr_solver"), + self.define_from_variant("NEKTAR_SOLVER_CARDIAC_EP", "cardiac_solver"), + self.define_from_variant("NEKTAR_SOLVER_COMPRESSIBLE_FLOW", "compflow_solver"), + self.define_from_variant("NEKTAR_SOLVER_DIFFUSION", "diff_solver"), + self.define_from_variant("NEKTAR_SOLVER_DUMMY", "dummy_solver"), + self.define_from_variant("NEKTAR_SOLVER_ELASTICITY", "elasticity_solver"), + self.define_from_variant("NEKTAR_SOLVER_IMAGE_WARPING", "imgwarp_solver"), + self.define_from_variant("NEKTAR_SOLVER_INCNAVIERSTOKES", "ins_solver"), + self.define_from_variant("NEKTAR_SOLVER_MMF", "mmf_solver"), + self.define_from_variant("NEKTAR_SOLVER_PULSEWAVE", "pulsewave_solver"), + self.define_from_variant("NEKTAR_SOLVER_SHALLOW_WATER", "shwater_solver"), + self.define_from_variant("NEKTAR_SOLVER_VORTEXWAVE", "vortexwave_solver"), + self.define_from_variant("NEKTAR_USE_ARPACK", "arpack"), + self.define_from_variant("NEKTAR_USE_FFTW", "fftw"), + self.define_from_variant("NEKTAR_USE_HDF5", "hdf5"), + self.define_from_variant("NEKTAR_USE_MPI", "mpi"), + self.define("NEKTAR_USE_PETSC", False), + self.define_from_variant("NEKTAR_USE_SCOTCH", "scotch"), + self.define("NEKTAR_USE_THREAD_SAFETY", True), + self.define("NEKTAR_USE_MKL", hasfeature("^intel-oneapi-mkl")), + self.define("NEKTAR_USE_OPENBLAS", hasfeature("^openblas")), + ] return args + + def install(self, spec, prefix): + super(Nektar, self).install(spec, prefix) + if "+python" in spec: + python = which("python") + with fs.working_dir(self.build_directory): + python("setup.py", "install", "--prefix", prefix) + + def setup_run_environment(self, env): + env.append_path( + "CMAKE_PREFIX_PATH", + os.path.join( + self.spec.prefix, os.path.join("lib64", os.path.join("nektar++", "cmake")) + ), + ) + env.append_path( + "PYTHONPATH", os.path.abspath(os.path.join(self.spec.prefix, "build_tree")) + ) + + def setup_dependent_run_environment(self, env, dependent_spec): + self.setup_run_environment(env) + + def setup_dependent_build_environment(self, env, dependent_spec): + self.setup_run_environment(env) + + def add_files_to_view(self, view, merge_map, skip_if_exists=True): + super(Nektar, self).add_files_to_view(view, merge_map, skip_if_exists) + path = self.view_destination(view) + view.link(os.path.join(path, "lib64", "nektar++"), os.path.join(path, "lib", "nektar++")) diff --git a/var/spack/repos/builtin/packages/nektools/package.py b/var/spack/repos/builtin/packages/nektools/package.py index 125b3838f35a3e..90e7951449ad3c 100644 --- a/var/spack/repos/builtin/packages/nektools/package.py +++ b/var/spack/repos/builtin/packages/nektools/package.py @@ -40,6 +40,9 @@ class Nektools(Package): version("19.0", sha256="db129877a10ff568d49edc77cf65f9e732eecb1fce10edbd91ffc5ac10c41ad6") version("17.0", sha256="4d8d4793ce3c926c54e09a5a5968fa959fe0ba46bd2e6b8043e099528ee35a60") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # Variant for MAXNEL, we need to read this from user variant( "MAXNEL", diff --git a/var/spack/repos/builtin/packages/nemsio/package.py b/var/spack/repos/builtin/packages/nemsio/package.py index 68b4edb15eb6c3..f6fe0827accecc 100644 --- a/var/spack/repos/builtin/packages/nemsio/package.py +++ b/var/spack/repos/builtin/packages/nemsio/package.py @@ -28,6 +28,8 @@ class Nemsio(CMakePackage): version("2.5.3", sha256="3fe8a781fc96197803d369cafe0138f3a5cbbca9816a7f8fd57567a1719a4d49") version("2.5.2", sha256="c59e9379969690de8d030cbf4bbbbe3726faf13c304f3b88b0f6aec1496d2c08") + depends_on("fortran", type="build") # generated + depends_on("bacio") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin/packages/nemsiogfs/package.py b/var/spack/repos/builtin/packages/nemsiogfs/package.py index cd632b01a203e8..40b27022b7c5b5 100644 --- a/var/spack/repos/builtin/packages/nemsiogfs/package.py +++ b/var/spack/repos/builtin/packages/nemsiogfs/package.py @@ -21,4 +21,6 @@ class Nemsiogfs(CMakePackage): version("develop", branch="develop") version("2.5.3", sha256="bf84206b08c8779787bef33e4aba18404df05f8b2fdd20fc40b3af608ae4b9af") + depends_on("fortran", type="build") # generated + depends_on("nemsio") diff --git a/var/spack/repos/builtin/packages/neovim/package.py b/var/spack/repos/builtin/packages/neovim/package.py index 7924b894fab006..50baf6062fa9e2 100644 --- a/var/spack/repos/builtin/packages/neovim/package.py +++ b/var/spack/repos/builtin/packages/neovim/package.py @@ -19,6 +19,8 @@ class Neovim(CMakePackage): version("master", branch="master") version("stable", tag="stable", commit="d772f697a281ce9c58bf933997b87c7f27428a60") + version("0.10.0", sha256="372ea2584b0ea2a5a765844d95206bda9e4a57eaa1a2412a9a0726bab750f828") + version("0.9.5", sha256="fe74369fc30a32ec7a086b1013acd0eacd674e7570eb1acc520a66180c9e9719") version("0.9.4", sha256="148356027ee8d586adebb6513a94d76accc79da9597109ace5c445b09d383093") version("0.9.2", sha256="06b8518bad4237a28a67a4fbc16ec32581f35f216b27f4c98347acee7f5fb369") version("0.9.1", sha256="8db17c2a1f4776dcda00e59489ea0d98ba82f7d1a8ea03281d640e58d8a3a00e") @@ -77,6 +79,8 @@ class Neovim(CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + variant( "no_luajit", default=False, @@ -135,6 +139,10 @@ class Neovim(CMakePackage): depends_on("libvterm@0.3:", type="link") with when("@0.9:"): depends_on("tree-sitter@0.20.8:") + with when("@0.10:"): + depends_on("cmake@3.13:", type="build") + depends_on("libvterm@0.3.3:") + depends_on("tree-sitter@0.20.9:") # Support for `libvterm@0.2:` has been added in neovim@0.8.0 # term: Add support for libvterm >= 0.2 (https://github.com/neovim/neovim/releases/tag/v0.8.0) diff --git a/var/spack/repos/builtin/packages/nest/package.py b/var/spack/repos/builtin/packages/nest/package.py index a664749bc67fa6..5dcfcdec2de0fa 100644 --- a/var/spack/repos/builtin/packages/nest/package.py +++ b/var/spack/repos/builtin/packages/nest/package.py @@ -22,6 +22,9 @@ class Nest(CMakePackage): version("3.0", sha256="d481ea67f3251fe3aadf5252ab0a999172f0cd5536c5985366d271d772e686e6") version("2.20.1", sha256="df3d32b5899d5d444f708037b290f889ac6ff8eae6b7be9e9faee2c0d660d8e5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + maintainers("ikitayama") variant("python", default=False, description="Build the PyNest interface") diff --git a/var/spack/repos/builtin/packages/net-snmp/package.py b/var/spack/repos/builtin/packages/net-snmp/package.py index d3573406542d33..0bbdae054a63f1 100644 --- a/var/spack/repos/builtin/packages/net-snmp/package.py +++ b/var/spack/repos/builtin/packages/net-snmp/package.py @@ -17,6 +17,8 @@ class NetSnmp(AutotoolsPackage): version("5.9.1", sha256="eb7fd4a44de6cddbffd9a92a85ad1309e5c1054fb9d5a7dd93079c8953f48c3f") version("5.9", sha256="04303a66f85d6d8b16d3cc53bde50428877c82ab524e17591dfceaeb94df6071") + depends_on("c", type="build") # generated + depends_on("perl-extutils-makemaker") depends_on("ncurses") diff --git a/var/spack/repos/builtin/packages/netcdf-c/package.py b/var/spack/repos/builtin/packages/netcdf-c/package.py index 8753edb6e3d7c5..c046cc38b99dd7 100644 --- a/var/spack/repos/builtin/packages/netcdf-c/package.py +++ b/var/spack/repos/builtin/packages/netcdf-c/package.py @@ -53,6 +53,9 @@ class NetcdfC(CMakePackage, AutotoolsPackage): version("4.3.3.1", sha256="f2ee78eb310637c007f001e7c18e2d773d23f3455242bde89647137b7344c2e2") version("4.3.3", sha256="3f16e21bc3dfeb3973252b9addf5defb48994f84fc9c9356081f871526a680e7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + with when("build_system=cmake"): # TODO: document why we need to revert https://github.com/Unidata/netcdf-c/pull/1731 # with the following patch: @@ -134,6 +137,7 @@ class NetcdfC(CMakePackage, AutotoolsPackage): variant("fsync", default=False, description="Enable fsync support") variant("nczarr_zip", default=False, description="Enable NCZarr zipfile format storage") variant("optimize", default=True, description="Enable -O2 for a more optimized lib") + variant("logging", default=False, description="Enable logging") variant("szip", default=True, description="Enable Szip compression plugin") variant("blosc", default=True, description="Enable Blosc compression plugin") @@ -164,7 +168,7 @@ class NetcdfC(CMakePackage, AutotoolsPackage): # The man files are included in the release tarballs starting version 4.5.0 but they are not # needed for the Windows platform: - for __p in ["darwin", "cray", "linux"]: + for __p in ["darwin", "linux"]: with when("platform={0}".format(__p)): # It is possible to install the package with CMake and without M4 on a non-Windows # platform but some of the man files will not be installed in that case (even if they @@ -250,7 +254,7 @@ class NetcdfC(CMakePackage, AutotoolsPackage): depends_on("zlib@1.2.5:", when="^[virtuals=zlib-api] zlib") # Use the vendored bzip2 on Windows: - for __p in ["darwin", "cray", "linux"]: + for __p in ["darwin", "linux"]: depends_on("bzip2", when="@4.9.0:+shared platform={0}".format(__p)) del __p @@ -337,6 +341,7 @@ def cmake_args(self): self.define("ENABLE_PARALLEL_TESTS", False), self.define_from_variant("ENABLE_FSYNC", "fsync"), self.define("ENABLE_LARGE_FILE_SUPPORT", True), + self.define_from_variant("NETCDF_ENABLE_LOGGING", "logging"), ] if "+parallel-netcdf" in self.pkg.spec: base_cmake_args.append(self.define("ENABLE_PNETCDF", True)) @@ -432,6 +437,8 @@ def configure_args(self): config_args += self.enable_or_disable("fsync") + config_args += self.enable_or_disable("logging") + if any(self.spec.satisfies(s) for s in ["+mpi", "+parallel-netcdf", "^hdf5+mpi~shared"]): config_args.append("CC={0}".format(self.spec["mpi"].mpicc)) @@ -460,7 +467,7 @@ def configure_args(self): # introduced by the configure script: if "+szip" in hdf: extra_libs.append(hdf["szip"].libs) - if "+external-xdr" in hdf: + if "+external-xdr ^libtirpc" in hdf: extra_libs.append(hdf["rpc"].libs) extra_libs.append(hdf["zlib-api"].libs) diff --git a/var/spack/repos/builtin/packages/netcdf-cxx/package.py b/var/spack/repos/builtin/packages/netcdf-cxx/package.py index 876e85b30be43e..4193c5894983f8 100644 --- a/var/spack/repos/builtin/packages/netcdf-cxx/package.py +++ b/var/spack/repos/builtin/packages/netcdf-cxx/package.py @@ -19,6 +19,8 @@ class NetcdfCxx(AutotoolsPackage): version("4.2", sha256="95ed6ab49a0ee001255eac4e44aacb5ca4ea96ba850c08337a3e4c9a0872ccd1") + depends_on("cxx", type="build") # generated + depends_on("netcdf-c") variant("netcdf4", default=True, description="Compile with netCDF4 support") diff --git a/var/spack/repos/builtin/packages/netcdf-cxx4/package.py b/var/spack/repos/builtin/packages/netcdf-cxx4/package.py index 5bdfabaf62f031..046c17a3fc1117 100644 --- a/var/spack/repos/builtin/packages/netcdf-cxx4/package.py +++ b/var/spack/repos/builtin/packages/netcdf-cxx4/package.py @@ -50,7 +50,7 @@ def flag_handler(self, name, flags): @property def libs(self): libraries = ["libnetcdf_c++4"] - shared = "+shared" in spec + shared = "+shared" in self.spec libs = find_libraries(libraries, root=self.prefix, shared=shared, recursive=True) if libs: diff --git a/var/spack/repos/builtin/packages/netcdf-fortran/package.py b/var/spack/repos/builtin/packages/netcdf-fortran/package.py index dbd4fd8e083f0f..c80f8843005e0d 100644 --- a/var/spack/repos/builtin/packages/netcdf-fortran/package.py +++ b/var/spack/repos/builtin/packages/netcdf-fortran/package.py @@ -32,6 +32,9 @@ class NetcdfFortran(AutotoolsPackage): version("4.4.4", sha256="b2d395175f8d283e68c8be516e231a96b191ade67ad0caafaf7fa01b1e6b5d75") version("4.4.3", sha256="330373aa163d5931e475b5e83da5c1ad041e855185f24e6a8b85d73b48d6cda9") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("pic", default=True, description="Produce position-independent code (for shared libs)") variant("shared", default=True, description="Enable shared library") variant("doc", default=False, description="Enable building docs") diff --git a/var/spack/repos/builtin/packages/netcdf95/package.py b/var/spack/repos/builtin/packages/netcdf95/package.py index 52a03c2b63a6aa..69df8425714c14 100644 --- a/var/spack/repos/builtin/packages/netcdf95/package.py +++ b/var/spack/repos/builtin/packages/netcdf95/package.py @@ -19,4 +19,7 @@ class Netcdf95(CMakePackage): version("0.3", tag="v0.3", commit="5b8db6bb66a22b6a080589ee1c11521ee3cae550", submodules=True) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("netcdf-fortran") diff --git a/var/spack/repos/builtin/packages/netdata/package.py b/var/spack/repos/builtin/packages/netdata/package.py index 9f4943759e4193..e9dda6be8cff2f 100644 --- a/var/spack/repos/builtin/packages/netdata/package.py +++ b/var/spack/repos/builtin/packages/netdata/package.py @@ -20,6 +20,10 @@ class Netdata(AutotoolsPackage): version("1.30.1", sha256="3df188ac04f17094cb929e2990841ba77f68aa6af484e0509b99db298fa206c9") version("1.22.1", sha256="f169c8615a6823448c2f1923c87c286d798132ea29d26f366e96d26e0aec3697") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("json-c") depends_on("judy") diff --git a/var/spack/repos/builtin/packages/netgauge/package.py b/var/spack/repos/builtin/packages/netgauge/package.py index 692ce5af1b5ceb..108abb8dd9c33e 100644 --- a/var/spack/repos/builtin/packages/netgauge/package.py +++ b/var/spack/repos/builtin/packages/netgauge/package.py @@ -22,6 +22,9 @@ class Netgauge(AutotoolsPackage): version("2.4.6", sha256="dc9398e4e042efec70881f2c7074ff18cc5b74bc5ffc4b8a4aaf813b39f83444") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("mpi") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/netgen/package.py b/var/spack/repos/builtin/packages/netgen/package.py index 4430a2530906ed..75b1fa6ee83937 100644 --- a/var/spack/repos/builtin/packages/netgen/package.py +++ b/var/spack/repos/builtin/packages/netgen/package.py @@ -19,6 +19,8 @@ class Netgen(AutotoolsPackage): version("5.3.1", sha256="cb97f79d8f4d55c00506ab334867285cde10873c8a8dc783522b47d2bc128bf9") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="enable mpi support") variant("oce", default=False, description="enable oce geometry kernel") variant("gui", default=False, description="enable gui") diff --git a/var/spack/repos/builtin/packages/netkit-ftp/package.py b/var/spack/repos/builtin/packages/netkit-ftp/package.py index beb565e4f123e2..8b2e373dbef123 100644 --- a/var/spack/repos/builtin/packages/netkit-ftp/package.py +++ b/var/spack/repos/builtin/packages/netkit-ftp/package.py @@ -16,6 +16,8 @@ class NetkitFtp(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) mkdirp(prefix.man.man1) diff --git a/var/spack/repos/builtin/packages/netlib-lapack/package.py b/var/spack/repos/builtin/packages/netlib-lapack/package.py index 2b6eb12fa19a61..1686a0a76a424e 100644 --- a/var/spack/repos/builtin/packages/netlib-lapack/package.py +++ b/var/spack/repos/builtin/packages/netlib-lapack/package.py @@ -61,6 +61,9 @@ class NetlibLapack(CMakePackage): version("3.4.0", sha256="a7139ef97004d0e3c4c30f1c52d508fd7ae84b5fbaf0dd8e792c167dc306c3e9") version("3.3.1", sha256="56821ab51c29369a34e5085728f92c549a9aa926f26acf7eeac87b61eed329e4") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # netlib-lapack is the reference implementation of LAPACK for ver in [ "3.10.1", @@ -81,6 +84,7 @@ class NetlibLapack(CMakePackage): provides("lapack@" + ver, when="@" + ver) variant("shared", default=True, description="Build shared library version") + variant("pic", default=True, description="Produce position-independent code") variant("external-blas", default=False, description="Build lapack with an external blas") variant("lapacke", default=True, description="Activates the build of the LAPACKE C interface") @@ -108,8 +112,9 @@ class NetlibLapack(CMakePackage): # https://github.com/Reference-LAPACK/lapack/pull/268 patch("testing.patch", when="@3.7.0:3.8") - # virtual dependency - provides("blas", when="~external-blas") + # liblapack links to libblas, so if this package is used as a lapack + # provider, it must also provide blas. + provides("lapack", "blas", when="~external-blas") provides("lapack") depends_on("blas", when="+external-blas") @@ -183,6 +188,7 @@ class CMakeBuilder(spack.build_systems.cmake.CMakeBuilder): def cmake_args(self): args = [ self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + self.define_from_variant("CMAKE_POSITION_INDEPENDENT_CODE", "pic"), self.define_from_variant("LAPACKE", "lapacke"), self.define_from_variant("LAPACKE_WITH_TMG", "lapacke"), self.define("CBLAS", self.spec.satisfies("@3.6.0:")), diff --git a/var/spack/repos/builtin/packages/netlib-scalapack/package.py b/var/spack/repos/builtin/packages/netlib-scalapack/package.py index df3792b93bd70f..38ad49f7957aad 100644 --- a/var/spack/repos/builtin/packages/netlib-scalapack/package.py +++ b/var/spack/repos/builtin/packages/netlib-scalapack/package.py @@ -42,7 +42,11 @@ class ScalapackBase(CMakePackage): def flag_handler(self, name, flags): iflags = [] - if name == "fflags": + if name == "cflags": + if self.spec.satisfies("%gcc@14:"): + # https://bugzilla.redhat.com/show_bug.cgi?id=2178710 + iflags.append("-std=gnu89") + elif name == "fflags": if self.spec.satisfies("%cce"): iflags.append("-hnopattern") return (iflags, None, None) @@ -119,5 +123,8 @@ class NetlibScalapack(ScalapackBase): version("2.0.1", sha256="a9b34278d4e10b40cbe084c6d87d09af8845e874250719bfbbc497b2a88bfde1") version("2.0.0", sha256="e51fbd9c3ef3a0dbd81385b868e2355900148eea689bf915c5383d72daf73114") version("master", branch="master") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated # versions before 2.0.0 are not using cmake and requires blacs as # a separated package diff --git a/var/spack/repos/builtin/packages/netlib-xblas/package.py b/var/spack/repos/builtin/packages/netlib-xblas/package.py index 787fe900241ca6..9c0dde12557652 100644 --- a/var/spack/repos/builtin/packages/netlib-xblas/package.py +++ b/var/spack/repos/builtin/packages/netlib-xblas/package.py @@ -27,6 +27,8 @@ class NetlibXblas(AutotoolsPackage): version("1.0.248", sha256="b5fe7c71c2da1ed9bcdc5784a12c5fa9fb417577513fe8a38de5de0007f7aaa1") + depends_on("c", type="build") # generated + variant("fortran", default=True, description="Build Fortran interfaces") variant("plain_blas", default=True, description="As part of XBLAS, build plain BLAS routines") diff --git a/var/spack/repos/builtin/packages/netpbm/package.py b/var/spack/repos/builtin/packages/netpbm/package.py index 320a414e2dc72a..4fe72eaa009098 100644 --- a/var/spack/repos/builtin/packages/netpbm/package.py +++ b/var/spack/repos/builtin/packages/netpbm/package.py @@ -30,6 +30,8 @@ class Netpbm(MakefilePackage): version("10.73.40", sha256="8542ae62aa744dfd52c8e425208f895f082955a0629ac1749f80278d6afc0344") version("10.73.35", sha256="628dbe8490bc43557813d1fedb2720dfdca0b80dd3f2364cb2a45c6ff04b0f18") + depends_on("c", type="build") # generated + # As a default we wish to commpile absolutely everything at once. # Variants are there in case compilation was a problem. variant("all", default=True, description="Enable all 3rd party libs") diff --git a/var/spack/repos/builtin/packages/netperf/package.py b/var/spack/repos/builtin/packages/netperf/package.py index ce320812fccaab..aacf408c1a9485 100644 --- a/var/spack/repos/builtin/packages/netperf/package.py +++ b/var/spack/repos/builtin/packages/netperf/package.py @@ -17,3 +17,5 @@ class Netperf(AutotoolsPackage): version("2.7.0", sha256="4569bafa4cca3d548eb96a486755af40bd9ceb6ab7c6abd81cc6aa4875007c4e") version("2.6.0", sha256="560b9c0ef0eed826941f74708b3ac53d91ec13b0b8c565fb107a1b5e6d99ded4") version("2.5.0", sha256="bebc94102fb74071cf289e0c116f83920dbd982f9e6c913ec0f1c7f6fcffbf77") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/nettle/package.py b/var/spack/repos/builtin/packages/nettle/package.py index 1ebcd3fc0d8d14..df7f51d350e986 100644 --- a/var/spack/repos/builtin/packages/nettle/package.py +++ b/var/spack/repos/builtin/packages/nettle/package.py @@ -24,9 +24,16 @@ class Nettle(AutotoolsPackage, GNUMirrorPackage): version("2.7.1", sha256="bc71ebd43435537d767799e414fce88e521b7278d48c860651216e1fc6555b40") version("2.7", sha256="c294ea133c05382cc2effb1734d49f4abeb1ad8515543a333de49a11422cd4d6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gmp") depends_on("m4", type="build") - depends_on("openssl") + + def flag_handler(self, name, flags): + if name == "cflags": + flags.append(self.compiler.c99_flag) + return (flags, None, None) def configure_args(self): - return ["CFLAGS={0}".format(self.compiler.c99_flag)] + return ["--disable-openssl"] diff --git a/var/spack/repos/builtin/packages/neuron/package.py b/var/spack/repos/builtin/packages/neuron/package.py index c6d33e70308a11..2887ea934286aa 100644 --- a/var/spack/repos/builtin/packages/neuron/package.py +++ b/var/spack/repos/builtin/packages/neuron/package.py @@ -37,6 +37,10 @@ class Neuron(CMakePackage): "7.8.2", tag="7.8.2", commit="09b151ecb2b3984335c265932dc6ba3e4fcb318e", submodules="True" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("backtrace", default=False, description="Enable printing backtraces on failure") variant("interviews", default=False, description="Enable GUI with INTERVIEWS") variant("legacy-unit", default=False, description="Enable legacy units") @@ -157,10 +161,7 @@ def filter_compilers(self): spec = self.spec - if "cray" in spec.architecture: - cc_compiler = "cc" - cxx_compiler = "CC" - elif spec.satisfies("+mpi"): + if spec.satisfies("+mpi"): cc_compiler = spec["mpi"].mpicc cxx_compiler = spec["mpi"].mpicxx else: diff --git a/var/spack/repos/builtin/packages/neve/package.py b/var/spack/repos/builtin/packages/neve/package.py index 916ad5091d4ba2..7e095a300cb7bc 100644 --- a/var/spack/repos/builtin/packages/neve/package.py +++ b/var/spack/repos/builtin/packages/neve/package.py @@ -17,6 +17,8 @@ class Neve(MakefilePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Build with OpenMP support") variant("opt", default=True, description="Optimization flags") diff --git a/var/spack/repos/builtin/packages/newt/package.py b/var/spack/repos/builtin/packages/newt/package.py index b92803eba28996..5ef214d549387f 100644 --- a/var/spack/repos/builtin/packages/newt/package.py +++ b/var/spack/repos/builtin/packages/newt/package.py @@ -18,5 +18,7 @@ class Newt(AutotoolsPackage): version("0.52.20", sha256="8d66ba6beffc3f786d4ccfee9d2b43d93484680ef8db9397a4fb70b5adbb6dbc") version("0.52.19", sha256="08c0db56c21996af6a7cbab99491b774c6c09cef91cd9b03903c84634bff2e80") + depends_on("c", type="build") # generated + depends_on("slang") depends_on("popt") diff --git a/var/spack/repos/builtin/packages/nextdenovo/package.py b/var/spack/repos/builtin/packages/nextdenovo/package.py index fca9afd2ee70d5..b9c242e1568538 100644 --- a/var/spack/repos/builtin/packages/nextdenovo/package.py +++ b/var/spack/repos/builtin/packages/nextdenovo/package.py @@ -16,6 +16,8 @@ class Nextdenovo(MakefilePackage): version("2.5.2", sha256="f1d07c9c362d850fd737c41e5b5be9d137b1ef3f1aec369dc73c637790611190") + depends_on("c", type="build") # generated + depends_on("python", type="run") depends_on("py-paralleltask", type="run") diff --git a/var/spack/repos/builtin/packages/nextflow/package.py b/var/spack/repos/builtin/packages/nextflow/package.py index f0800126c56dd0..4687218fc6bfbe 100644 --- a/var/spack/repos/builtin/packages/nextflow/package.py +++ b/var/spack/repos/builtin/packages/nextflow/package.py @@ -14,6 +14,16 @@ class Nextflow(Package): maintainers("dialvarezs", "marcodelapierre") + version( + "24.04.3", + sha256="e258f6395a38f044eb734cba6790af98b561aa521f63e2701fe95c050986e11c", + expand=False, + ) + version( + "24.04.1", + sha256="d1199179e31d0701d86e6c38afa9ccade93f62d545e800824be7767a130510ba", + expand=False, + ) version( "23.10.1", sha256="9abc54f1ffb2b834a8135d44300404552d1e27719659cbb635199898677b660a", @@ -177,7 +187,8 @@ class Nextflow(Package): deprecated=True, ) - depends_on("java") + depends_on("java@17", when="@24", type="run") + depends_on("java", type="run") def install(self, spec, prefix): mkdirp(prefix.bin) diff --git a/var/spack/repos/builtin/packages/nf-tower-cli/package.py b/var/spack/repos/builtin/packages/nf-tower-cli/package.py index 0db4df3ed9d9e5..bb9520f98b3d3b 100644 --- a/var/spack/repos/builtin/packages/nf-tower-cli/package.py +++ b/var/spack/repos/builtin/packages/nf-tower-cli/package.py @@ -17,6 +17,8 @@ class NfTowerCli(Package): homepage = "https://github.com/seqeralabs/tower-cli" maintainers("marcodelapierre") + skip_version_audit = ["platform=windows"] + if platform.machine() == "x86_64": if platform.system() == "Darwin": version( @@ -104,7 +106,7 @@ class NfTowerCli(Package): url="https://github.com/seqeralabs/tower-cli/releases/download/v0.6.2/tw-0.6.2-linux-x86_64", expand=False, ) - elif platform.machine() == "aarch64": + elif platform.machine() == "arm64": if platform.system() == "Darwin": version( "0.9.2", diff --git a/var/spack/repos/builtin/packages/nf-wave-cli/package.py b/var/spack/repos/builtin/packages/nf-wave-cli/package.py index 7143cd8aedc884..1d978894eb359b 100644 --- a/var/spack/repos/builtin/packages/nf-wave-cli/package.py +++ b/var/spack/repos/builtin/packages/nf-wave-cli/package.py @@ -41,7 +41,7 @@ class NfWaveCli(Package): url="https://github.com/seqeralabs/wave-cli/releases/download/v1.1.3/wave-1.1.3-linux-x86_64", expand=False, ) - elif platform.machine() == "aarch64": + elif platform.machine() == "arm64": if platform.system() == "Darwin": version( "1.2.0", diff --git a/var/spack/repos/builtin/packages/nfft/package.py b/var/spack/repos/builtin/packages/nfft/package.py index 3d86f0710b123e..8ae71152d45011 100644 --- a/var/spack/repos/builtin/packages/nfft/package.py +++ b/var/spack/repos/builtin/packages/nfft/package.py @@ -27,6 +27,8 @@ class Nfft(AutotoolsPackage): url="https://www-user.tu-chemnitz.de/~potts/nfft/download/nfft-3.2.4.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("fftw") _fftw_precisions = None diff --git a/var/spack/repos/builtin/packages/nfs-ganesha/package.py b/var/spack/repos/builtin/packages/nfs-ganesha/package.py index f5e0da3e6a401a..caf3e5da077514 100644 --- a/var/spack/repos/builtin/packages/nfs-ganesha/package.py +++ b/var/spack/repos/builtin/packages/nfs-ganesha/package.py @@ -18,6 +18,9 @@ class NfsGanesha(CMakePackage): version("3.0.3", sha256="fcc0361b9a2752be7eb4e990230765e17de373452ac24514be22c81a5447a460") version("3.0", sha256="136c5642ff21ec6e8a4e77c037f6218a39b2eeba77798b13556f1abbb0923ccd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("bison", type="build") depends_on("flex", type="build") depends_on("py-stsci-distutils", type="build") diff --git a/var/spack/repos/builtin/packages/nfs-utils/package.py b/var/spack/repos/builtin/packages/nfs-utils/package.py index 48c7d8c33d4fda..ddfb62dc720ec6 100644 --- a/var/spack/repos/builtin/packages/nfs-utils/package.py +++ b/var/spack/repos/builtin/packages/nfs-utils/package.py @@ -20,6 +20,8 @@ class NfsUtils(AutotoolsPackage): version("2.4.1", sha256="c0dda96318af554881f4eb1590bfe91f1aba2fba59ed2ac3ba099f80fdf838e9") version("2.3.4", sha256="36e70b0a583751ead0034ebe5d8826caf2dcc7ee7c0beefe94d6ee5a3b0b2484") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("libtirpc") depends_on("libevent") diff --git a/var/spack/repos/builtin/packages/nghttp2/package.py b/var/spack/repos/builtin/packages/nghttp2/package.py index d973a232e639f2..28c02713ece46e 100644 --- a/var/spack/repos/builtin/packages/nghttp2/package.py +++ b/var/spack/repos/builtin/packages/nghttp2/package.py @@ -15,6 +15,8 @@ class Nghttp2(AutotoolsPackage): license("MIT") + version("1.62.0", sha256="482e41a46381d10adbdfdd44c1942ed5fd1a419e0ab6f4a5ff5b61468fe6f00d") + version("1.61.0", sha256="aa7594c846e56a22fbf3d6e260e472268808d3b49d5e0ed339f589e9cc9d484c") version("1.57.0", sha256="1e3258453784d3b7e6cc48d0be087b168f8360b5d588c66bfeda05d07ad39ffd") version("1.52.0", sha256="9877caa62bd72dde1331da38ce039dadb049817a01c3bdee809da15b754771b8") version("1.51.0", sha256="2a0bef286f65b35c24250432e7ec042441a8157a5b93519412d9055169d9ce54") @@ -24,7 +26,11 @@ class Nghttp2(AutotoolsPackage): version("1.44.0", sha256="3e4824d02ae27eca931e0bb9788df00a26e5fd8eb672cf52cbb89c1463ba16e9") version("1.26.0", sha256="daf7c0ca363efa25b2cbb1e4bd925ac4287b664c3d1465f6a390359daa3f0cf1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pkgconfig", type="build") + depends_on("diffutils", type="build") def configure_args(self): return [ diff --git a/var/spack/repos/builtin/packages/nginx/package.py b/var/spack/repos/builtin/packages/nginx/package.py index 2f41d3e1996983..cdee6710cd40cf 100644 --- a/var/spack/repos/builtin/packages/nginx/package.py +++ b/var/spack/repos/builtin/packages/nginx/package.py @@ -16,6 +16,7 @@ class Nginx(AutotoolsPackage): license("BSD-2-Clause") + version("1.26.0", sha256="d2e6c8439d6c6db5015d8eaab2470ab52aef85a7bf363182879977e084370497") version("1.24.0", sha256="77a2541637b92a621e3ee76776c8b7b40cf6d707e69ba53a940283e30ff2f55d") version("1.23.4", sha256="d43300e36bb249a7e6edc60bca1b0fc372a0bafce2f346d76acfb677a8790fc0") version("1.23.3", sha256="75cb5787dbb9fae18b14810f91cc4343f64ce4c24e27302136fb52498042ba54") @@ -24,6 +25,9 @@ class Nginx(AutotoolsPackage): version("1.13.8", sha256="8410b6c31ff59a763abf7e5a5316e7629f5a5033c95a3a0ebde727f9ec8464c5") version("1.12.0", sha256="b4222e26fdb620a8d3c3a3a8b955e08b713672e1bc5198d1e4f462308a795b30") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("openssl") depends_on("openssl@:1", when="@:1.21.2") depends_on("pcre") diff --git a/var/spack/repos/builtin/packages/ngmerge/package.py b/var/spack/repos/builtin/packages/ngmerge/package.py index 4114d071b977e9..7e627acfa2fb5c 100644 --- a/var/spack/repos/builtin/packages/ngmerge/package.py +++ b/var/spack/repos/builtin/packages/ngmerge/package.py @@ -16,6 +16,8 @@ class Ngmerge(MakefilePackage): version("0.3", sha256="5928f727feebd0d1bcdbee0e631ba06fbe9ce88328bd58b6c8bf4e54cc742ac3") + depends_on("c", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/ngmlr/package.py b/var/spack/repos/builtin/packages/ngmlr/package.py index 51e5197f6a721e..748fbb262c0a47 100644 --- a/var/spack/repos/builtin/packages/ngmlr/package.py +++ b/var/spack/repos/builtin/packages/ngmlr/package.py @@ -19,6 +19,9 @@ class Ngmlr(CMakePackage): version("0.2.7", sha256="5126a6b3e726cac0da0713883daac688f38587f118428247a9a3ace5a55b29aa") version("0.2.5", sha256="719944a35cc7ff9c321eedbf3385a7375ce2301f609b3fd7be0a850cabbb028b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api", type="link") depends_on("sse2neon", when="target=aarch64:") diff --git a/var/spack/repos/builtin/packages/ngspice/package.py b/var/spack/repos/builtin/packages/ngspice/package.py index dafffd8f2292f3..0b22cd0df5a5d7 100644 --- a/var/spack/repos/builtin/packages/ngspice/package.py +++ b/var/spack/repos/builtin/packages/ngspice/package.py @@ -36,6 +36,9 @@ class Ngspice(AutotoolsPackage): version("29", sha256="8d6d0ffbc15f248eb6ec3bde3b9d1397fbc95cb677e1c6a14ff46065c7f95c4a") version("27", sha256="0c08c7d57a2e21cf164496f3237f66f139e0c78e38345fbe295217afaf150695") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # kicad needs build=lib, i.e. --with--ngshared variant( "build", diff --git a/var/spack/repos/builtin/packages/nicstat/package.py b/var/spack/repos/builtin/packages/nicstat/package.py index ef25505ae4ca7b..2018741df61eb5 100644 --- a/var/spack/repos/builtin/packages/nicstat/package.py +++ b/var/spack/repos/builtin/packages/nicstat/package.py @@ -20,6 +20,8 @@ class Nicstat(MakefilePackage, SourceforgePackage): version("1.95", sha256="c4cc33f8838f4523f27c3d7584eedbe59f4c587f0821612f5ac2201adc18b367") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): copy("Makefile.Linux", "makefile") filter_file(r"CMODEL =\s+-m32", "", "makefile") diff --git a/var/spack/repos/builtin/packages/nim/package.py b/var/spack/repos/builtin/packages/nim/package.py index a00495a2eed458..241ec9259e264e 100644 --- a/var/spack/repos/builtin/packages/nim/package.py +++ b/var/spack/repos/builtin/packages/nim/package.py @@ -2,7 +2,6 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import os.path from spack.package import * @@ -18,6 +17,7 @@ class Nim(Package): license("MIT") + version("2.0.4", sha256="71526bd07439dc8e378fa1a6eb407eda1298f1f3d4df4476dca0e3ca3cbe3f09") version("1.9.3", sha256="d8de7515db767f853d9b44730f88ee113bfe9c38dcccd5afabc773e2e13bf87c") version("1.4.4", sha256="6d73729def143f72fc2491ca937a9cab86d2a8243bd845a5d1403169ad20660e") version("1.4.2", sha256="03a47583777dd81380a3407aa6a788c9aa8a67df4821025770c9ac4186291161") @@ -38,22 +38,27 @@ class Nim(Package): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pcre") depends_on("openssl") def patch(self): - install_sh_path = os.path.join(self.stage.source_path, "install.sh") + install_sh_path = join_path(self.stage.source_path, "install.sh") filter_file("1/nim", "1", install_sh_path) def install(self, spec, prefix): bash = which("bash") bash("./build.sh") - nim = Executable(os.path.join("bin", "nim")) + nim = Executable(join_path("bin", "nim")) nim("c", "koch") koch = Executable("./koch") koch("boot", "-d:release") koch("tools") + koch("nimble") bash("./install.sh", prefix) + install(join_path("bin", "nimble"), join_path(prefix, "bin")) diff --git a/var/spack/repos/builtin/packages/nimrod-aai/package.py b/var/spack/repos/builtin/packages/nimrod-aai/package.py index 280173bfca82c0..0b24858ef86886 100644 --- a/var/spack/repos/builtin/packages/nimrod-aai/package.py +++ b/var/spack/repos/builtin/packages/nimrod-aai/package.py @@ -12,17 +12,18 @@ class NimrodAai(CMakePackage): enabled by modern Fortran. """ - homepage = "https://gitlab.com/NIMRODteam/nimrod-abstract" - url = ( - "https://gitlab.com/NIMRODteam/nimrod-abstract/-/archive/23.9/nimrod-abstract-23.9.tar.gz" - ) - git = "https://gitlab.com/NIMRODteam/nimrod-abstract.git" + homepage = "https://gitlab.com/NIMRODteam/open/nimrod-abstract" + url = "https://gitlab.com/NIMRODteam/open/nimrod-abstract/-/archive/24.2/nimrod-abstract-24.2.tar.gz" + git = "https://gitlab.com/NIMRODteam/open/nimrod-abstract.git" maintainers("jacobrking") version("main", branch="main") - version("23.9", sha256="212d591c5a5e7a394b56a5cf2f92cc69feafc49dd5f042fa95eeb6441649390b") - version("23.6", sha256="1794b89a5a64ff2b3c548818b90d17eef85d819ba4f63a76c41a682d5b76c14f") + version("24.2", sha256="1dd4d51426f141c058e25cb29870eaf15e0edfb44d80df94e7c65c850ca78eda") + version("23.9", sha256="34f7ee00bbbe9a6d08304473e8893af9bd94af8dbd0bbd50b8b441057023e179") + version("23.6", sha256="de7e5c5cc2ad97dc0e66628d29c8153fa807821a316eb9aa8ee21a39c69df800") + + depends_on("fortran", type="build") # generated variant("debug", default=False, description="Whether to enable debug code") variant("openacc", default=False, description="Whether to enable OpenACC") @@ -43,8 +44,8 @@ class NimrodAai(CMakePackage): depends_on("cmake", type="build") depends_on("mpi", when="+mpi") - depends_on("hdf5+fortran~mpi", type="build", when="~mpi") - depends_on("hdf5+fortran+mpi", type="build", when="+mpi") + depends_on("hdf5+fortran~mpi", when="~mpi") + depends_on("hdf5+fortran+mpi", when="+mpi") def cmake_args(self): args = [ diff --git a/var/spack/repos/builtin/packages/ninja-fortran/package.py b/var/spack/repos/builtin/packages/ninja-fortran/package.py index 9cc2cbeb4164ff..071a64b7b6b1da 100644 --- a/var/spack/repos/builtin/packages/ninja-fortran/package.py +++ b/var/spack/repos/builtin/packages/ninja-fortran/package.py @@ -46,6 +46,9 @@ class NinjaFortran(Package): "1.7.1.0.g7ca7f", sha256="53472d0c3cf9c1cff7e991699710878be55d21a1c229956dea6a2c3e44edee80" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python", type="build") phases = ["configure", "install"] @@ -76,7 +79,7 @@ def configure(self, spec, prefix): @on_package_attributes(run_tests=True) def configure_test(self): ninja = Executable("./ninja") - ninja("-j{0}".format(make_jobs), "ninja_test") + ninja(f"-j{make_jobs}", "ninja_test") ninja_test = Executable("./ninja_test") ninja_test() diff --git a/var/spack/repos/builtin/packages/ninja-phylogeny/package.py b/var/spack/repos/builtin/packages/ninja-phylogeny/package.py index f6251cf54e82a3..f0c325ebae0e33 100644 --- a/var/spack/repos/builtin/packages/ninja-phylogeny/package.py +++ b/var/spack/repos/builtin/packages/ninja-phylogeny/package.py @@ -18,6 +18,8 @@ class NinjaPhylogeny(MakefilePackage): version("0.98", sha256="55675e1a9d51eddb3decc9a7570b6bcddb12e8a922cf1ca0a1ea43995793c9db") + depends_on("cxx", type="build") # generated + build_directory = "NINJA" def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/ninja/package.py b/var/spack/repos/builtin/packages/ninja/package.py index 5d9e7af81d34ba..c63972d0484558 100644 --- a/var/spack/repos/builtin/packages/ninja/package.py +++ b/var/spack/repos/builtin/packages/ninja/package.py @@ -26,6 +26,7 @@ class Ninja(Package): version("kitware", branch="features-for-fortran", git="https://github.com/Kitware/ninja.git") version("master", branch="master") + version("1.12.0", sha256="8b2c86cd483dc7fcb7975c5ec7329135d210099a89bc7db0590a07b0bbfe49a5") version("1.11.1", sha256="31747ae633213f1eda3842686f83c2aa1412e0f5691d1c14dbbcc67fe7400cea") version("1.11.0", sha256="3c6ba2e66400fe3f1ae83deb4b235faf3137ec20bd5b08c29bfc368db143e4c6") version("1.10.2", sha256="ce35865411f0490368a8fc383f29071de6690cbadc27704734978221f25e2bed") @@ -36,6 +37,9 @@ class Ninja(Package): version("1.7.2", sha256="2edda0a5421ace3cf428309211270772dd35a91af60c96f93f90df6bc41b16d9") version("1.6.0", sha256="b43e88fb068fe4d92a3dfd9eb4d19755dae5c33415db2e9b7b61b4659009cde7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "re2c", default=not sys.platform == "win32", description="Enable buidling Ninja with re2c" ) @@ -57,7 +61,7 @@ def configure(self, spec, prefix): @on_package_attributes(run_tests=True) def configure_test(self): ninja = Executable("./ninja") - ninja("-j{0}".format(make_jobs), "ninja_test") + ninja(f"-j{make_jobs}", "ninja_test") ninja_test = Executable("./ninja_test") ninja_test() diff --git a/var/spack/repos/builtin/packages/njet/package.py b/var/spack/repos/builtin/packages/njet/package.py index d9f48c7dc04a3c..25d1dca28a3a27 100644 --- a/var/spack/repos/builtin/packages/njet/package.py +++ b/var/spack/repos/builtin/packages/njet/package.py @@ -20,6 +20,10 @@ class Njet(AutotoolsPackage): version("2.1.1", sha256="3858ad37e84f3652711aa033819a6566352ecff04a1cb0189d6590af75b7bb56") version("2.0.0", sha256="a1f5c171b8aff3553d9dde24d3ced5479bdaeec67f4c90c70a846ee3449b40ea") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("qd") patch("njet-2.0.0.patch", when="@2.0.0", level=0) diff --git a/var/spack/repos/builtin/packages/nlcglib/package.py b/var/spack/repos/builtin/packages/nlcglib/package.py index 694fbbfc5c1fed..5f854969007bf1 100644 --- a/var/spack/repos/builtin/packages/nlcglib/package.py +++ b/var/spack/repos/builtin/packages/nlcglib/package.py @@ -18,11 +18,13 @@ class Nlcglib(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("develop", branch="develop") - version("master", branch="master") + version("1.1.0", sha256="9e7c2eea84a5ce191bd9af08f6c890717f7b6e88be7bd15cfe774eb0e0dabd8a") version("1.0b", sha256="086c46f06a117f267cbdf1df4ad42a8512689a9610885763f463469fb15e82dc") version("0.9", sha256="8d5bc6b85ee714fb3d6480f767e7f43e5e7d569116cf60e48f533a7f50a37a08") + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Use OpenMP") variant("tests", default=False, description="Build tests") variant( @@ -32,13 +34,26 @@ class Nlcglib(CMakePackage, CudaPackage, ROCmPackage): values=("Debug", "Release", "RelWithDebInfo"), ) + with when("@1.1: +cuda"): + variant( + "gpu_direct", + default=False, + description="Enable GPU direct. Required to support distributed wave-functions.", + ) + depends_on("cmake@3.21:", type="build") depends_on("mpi") depends_on("lapack") + depends_on("kokkos~cuda~rocm", when="~cuda~rocm") depends_on("kokkos+openmp", when="+openmp") + depends_on("googletest", type="build", when="+tests") depends_on("nlohmann-json") + depends_on("kokkos@4:", when="@1.1:") + + # MKLConfig.cmake introduced in 2021.3 + conflicts("intel-oneapi-mkl@:2021.2", when="^intel-oneapi-mkl") with when("@:0.9"): conflicts("+rocm") @@ -51,18 +66,18 @@ class Nlcglib(CMakePackage, CudaPackage, ROCmPackage): depends_on("rocblas") depends_on("rocsolver") - for arch in CudaPackage.cuda_arch_values: - depends_on( - f"kokkos+cuda+cuda_lambda+wrapper cuda_arch={arch}", - when=f"%gcc +cuda cuda_arch={arch}", - ) - depends_on(f"kokkos+cuda cuda_arch={arch}", when=f"+cuda cuda_arch={arch}") + with when("+cuda"): + depends_on("kokkos+cuda_lambda+wrapper", when="%gcc") + depends_on("kokkos+cuda") + for arch in CudaPackage.cuda_arch_values: + depends_on(f"kokkos cuda_arch={arch}", when=f"cuda_arch={arch}") def cmake_args(self): options = [ self.define_from_variant("USE_OPENMP", "openmp"), self.define_from_variant("BUILD_TESTS", "tests"), self.define_from_variant("USE_ROCM", "rocm"), + self.define_from_variant("USE_GPU_DIRECT", "gpu_direct"), self.define_from_variant("USE_MAGMA", "magma"), self.define_from_variant("USE_CUDA", "cuda"), ] @@ -71,6 +86,29 @@ def cmake_args(self): options += [self.define("LAPACK_VENDOR", "MKL")] elif self.spec["blas"].name in ["intel-oneapi-mkl"]: options += [self.define("LAPACK_VENDOR", "MKLONEAPI")] + mkl_mapper = { + "threading": {"none": "sequential", "openmp": "gnu_thread", "tbb": "tbb_thread"}, + "mpi": {"intel-mpi": "intelmpi", "mpich": "mpich", "openmpi": "openmpi"}, + } + + mkl_threads = mkl_mapper["threading"][ + self.spec["intel-oneapi-mkl"].variants["threads"].value + ] + + mpi_provider = self.spec["mpi"].name + if mpi_provider in ["mpich", "cray-mpich", "mvapich", "mvapich2"]: + mkl_mpi = mkl_mapper["mpi"]["mpich"] + else: + mkl_mpi = mkl_mapper["mpi"][mpi_provider] + + options.extend( + [ + self.define("MKL_INTERFACE", "lp64"), + self.define("MKL_THREADING", mkl_threads), + self.define("MKL_MPI", mkl_mpi), + ] + ) + elif self.spec["blas"].name in ["openblas"]: options += [self.define("LAPACK_VENDOR", "OpenBLAS")] else: diff --git a/var/spack/repos/builtin/packages/nlohmann-json-schema-validator/package.py b/var/spack/repos/builtin/packages/nlohmann-json-schema-validator/package.py index 166c5344b781dd..29f9946567fa83 100644 --- a/var/spack/repos/builtin/packages/nlohmann-json-schema-validator/package.py +++ b/var/spack/repos/builtin/packages/nlohmann-json-schema-validator/package.py @@ -22,6 +22,8 @@ class NlohmannJsonSchemaValidator(CMakePackage): version("2.0.0", sha256="ca8e4ca5a88c49ea52b5f5c2a08a293dbf02b2fc66cb8c09d4cce5810ee98b57") version("1.0.0", sha256="4bdcbf6ce98eda993d8a928dbe97a03f46643395cb872af875a908156596cc4b") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.2:", type="build") depends_on("nlohmann-json") diff --git a/var/spack/repos/builtin/packages/nlohmann-json/package.py b/var/spack/repos/builtin/packages/nlohmann-json/package.py index 219e73c87a80ac..d0003219c60039 100644 --- a/var/spack/repos/builtin/packages/nlohmann-json/package.py +++ b/var/spack/repos/builtin/packages/nlohmann-json/package.py @@ -15,6 +15,7 @@ class NlohmannJson(CMakePackage): license("MIT") + version("3.11.3", sha256="0d8ef5af7f9794e3263480193c491549b2ba6cc74bb018906202ada498a79406") version("3.11.2", sha256="d69f9deb6a75e2580465c6c4c5111b89c4dc2fa94e3a85fcd2ffcd9a143d9273") # v3.11.0 & v3.11.1 omitted; released with significant regressions version("3.10.5", sha256="5daca6ca216495edf89d167f808d1d03c4a4d929cef7da5e10f135ae1540c7e4") @@ -35,6 +36,9 @@ class NlohmannJson(CMakePackage): version("3.1.2", sha256="e8fffa6cbdb3c15ecdff32eebf958b6c686bc188da8ad5c6489462d16f83ae54") version("3.1.1", sha256="9f3549824af3ca7e9707a2503959886362801fb4926b869789d6929098a79e47") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "multiple_headers", default=True, description="Use non-amalgamated version of the library" ) diff --git a/var/spack/repos/builtin/packages/nlopt/package.py b/var/spack/repos/builtin/packages/nlopt/package.py index b71450d78f4a98..fd9ed9b18f4877 100644 --- a/var/spack/repos/builtin/packages/nlopt/package.py +++ b/var/spack/repos/builtin/packages/nlopt/package.py @@ -29,6 +29,10 @@ class Nlopt(CMakePackage): version("2.6.0", sha256="a13077cdf5f5f1127eaaac0bf1e06744bfe98d8a4a3430a15e0af50a69f451ab") version("2.5.0", sha256="c6dd7a5701fff8ad5ebb45a3dc8e757e61d52658de3918e38bab233e7fd3b4ae") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") variant("python", default=True, description="Build python wrappers") variant("guile", default=False, description="Enable Guile support") diff --git a/var/spack/repos/builtin/packages/nmap/package.py b/var/spack/repos/builtin/packages/nmap/package.py index 47ef9de535c939..205ae5c56e4cb4 100644 --- a/var/spack/repos/builtin/packages/nmap/package.py +++ b/var/spack/repos/builtin/packages/nmap/package.py @@ -33,6 +33,9 @@ class Nmap(AutotoolsPackage): version("6.40", sha256="491f77d8b3fb3bb38ba4e3850011fe6fb43bbe197f9382b88cb59fa4e8f7a401") version("6.01", sha256="77f6635b677d28b546cbef97e4ead6c2d4a5aebcaa108fe3a3c135db6448617a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("liblua", default=True, description="Enable lua (required by all of NSE)") variant("ncat", default=True, description="Enable ncat") variant("nping", default=True, description="Enable nping") diff --git a/var/spack/repos/builtin/packages/nn-c/package.py b/var/spack/repos/builtin/packages/nn-c/package.py index d66c061de2b60f..29e262e7153957 100644 --- a/var/spack/repos/builtin/packages/nn-c/package.py +++ b/var/spack/repos/builtin/packages/nn-c/package.py @@ -17,6 +17,8 @@ class NnC(AutotoolsPackage): version("master", branch="master") version("1.86.2", commit="343c7784d38d3270d75d450569fc0b64767c37e9") + depends_on("c", type="build") # generated + variant("pic", default=True, description="Produce position-independent code (for shared libs)") configure_directory = "nn" diff --git a/var/spack/repos/builtin/packages/nnpack/package.py b/var/spack/repos/builtin/packages/nnpack/package.py index 36110c6f4ffe42..88c7398f61a475 100644 --- a/var/spack/repos/builtin/packages/nnpack/package.py +++ b/var/spack/repos/builtin/packages/nnpack/package.py @@ -20,6 +20,9 @@ class Nnpack(CMakePackage): version("2018-05-21", commit="3eb0d453662d05a708f43b108bed9e17b705383e") # py-torch@0.4.1 version("2018-04-05", commit="b63fe1ba8963f1756b8decc593766615cee99c35") # py-torch@:0.4.0 + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@2.8.12:", type="build") depends_on("python", type="build") diff --git a/var/spack/repos/builtin/packages/nnvm/package.py b/var/spack/repos/builtin/packages/nnvm/package.py index ca57d8aa199a00..974177ffcd3e67 100644 --- a/var/spack/repos/builtin/packages/nnvm/package.py +++ b/var/spack/repos/builtin/packages/nnvm/package.py @@ -18,6 +18,8 @@ class Nnvm(CMakePackage): version("master", branch="master") version("20170418", commit="b279286304ac954098d94a2695bca599e832effb") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build a shared NNVM lib.") depends_on("dmlc-core") diff --git a/var/spack/repos/builtin/packages/node-js/fix-old-glibc-random-headers.patch b/var/spack/repos/builtin/packages/node-js/fix-old-glibc-random-headers.patch new file mode 100644 index 00000000000000..9629a6bb0c5342 --- /dev/null +++ b/var/spack/repos/builtin/packages/node-js/fix-old-glibc-random-headers.patch @@ -0,0 +1,22 @@ +diff --git a/deps/cares/config/linux/ares_config.h b/deps/cares/config/linux/ares_config.h +index 3cb135a..88934ad 100644 +--- a/deps/cares/config/linux/ares_config.h ++++ b/deps/cares/config/linux/ares_config.h +@@ -116,7 +116,7 @@ + #define HAVE_GETNAMEINFO 1 + + /* Define to 1 if you have `getrandom` */ +-#define HAVE_GETRANDOM 1 ++#undef HAVE_GETRANDOM + + /* Define to 1 if you have `getservbyport_r` */ + #define HAVE_GETSERVBYPORT_R 1 +@@ -329,7 +329,7 @@ + #define HAVE_SYS_PARAM_H 1 + + /* Define to 1 if you have the header file. */ +-#define HAVE_SYS_RANDOM_H 1 ++#undef HAVE_SYS_RANDOM_H + + /* Define to 1 if you have the header file. */ + #define HAVE_SYS_SELECT_H 1 diff --git a/var/spack/repos/builtin/packages/node-js/package.py b/var/spack/repos/builtin/packages/node-js/package.py index 744304f4660afd..b76d72ae91bdb9 100644 --- a/var/spack/repos/builtin/packages/node-js/package.py +++ b/var/spack/repos/builtin/packages/node-js/package.py @@ -22,17 +22,22 @@ class NodeJs(Package): license("Unicode-TOU") # Current (latest features) - odd major number + version("21.7.3", sha256="ce1f61347671ef219d9c2925313d629d3fef98fc8d7f5ef38dd4656f7d0f58e7") version("19.2.0", sha256="aac9d1a366fb57d68f4639f9204d1de5d6387656959a97ed929a5ba9e62c033a") + version("17.9.1", sha256="1102f5e0aafaab8014d19c6c57142caf2ba3ef69d88d7a7f0f82798051796027") version("15.3.0", sha256="cadfa384a5f14591b84ce07a1afe529f28deb0d43366fb0ae4e78afba96bfaf2") version("13.8.0", sha256="815b5e1b18114f35da89e4d98febeaba97555d51ef593bd5175db2b05f2e8be6") version("13.5.0", sha256="4b8078d896a7550d7ed399c1b4ac9043e9f883be404d9b337185c8d8479f2db8") # LTS (recommended for most users) - even major number version( - "18.12.1", - sha256="ba8174dda00d5b90943f37c6a180a1d37c861d91e04a4cb38dc1c0c74981c186", + "22.4.0", + sha256="b62cd83c9a57a11349883f89b1727a16e66c02eb6255a4bf32714ff5d93165f5", preferred=True, ) + version("22.3.0", sha256="6326484853093ab6b8f361a267445f4a5bff469042cda11a3585497b13136b55") + version("20.15.0", sha256="01e2c034467a324a33e778c81f2808dff13d289eaa9307d3e9b06c171e4d932d") + version("18.12.1", sha256="ba8174dda00d5b90943f37c6a180a1d37c861d91e04a4cb38dc1c0c74981c186") version("16.18.1", sha256="3d24c9c3a953afee43edc44569045eda56cd45cd58b0539922d17da62736189c") version("14.21.1", sha256="76ba961536dc11e4dfd9b198c61ff3399e655eca959ae4b66d926f29bfcce9d3") version("14.16.1", sha256="5f5080427abddde7f22fd2ba77cd2b8a1f86253277a1eec54bc98a202728ce80") @@ -40,6 +45,9 @@ class NodeJs(Package): version("14.13.0", sha256="8538b2e76aa06ee0e6eb1c118426c3c5ca53b2e49d66591738eacf76e89edd61") version("14.10.0", sha256="7e0d7a1aa23697415e3588a1ca4f1c47496e6c88b9cf37c66be90353d3e4ac3e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("debug", default=False, description="Include debugger support") variant("doc", default=False, description="Compile with documentation") variant( @@ -76,9 +84,16 @@ class NodeJs(Package): # https://github.com/spack/spack/issues/19310 conflicts( "%gcc@:4.8", - msg="fails to build with gcc 4.8 (see https://github.com/spack/spack/issues/19310", + msg="fails to build with gcc 4.8 (see https://github.com/spack/spack/issues/19310)", ) + conflicts( + "%gcc@14:", when="@:19", msg="fails to build with gcc 14+ due to implicit conversions" + ) + + # See https://github.com/nodejs/node/issues/52223 + patch("fix-old-glibc-random-headers.patch", when="^glibc@:2.24") + def setup_build_environment(self, env): # Force use of experimental Python 3 support env.set("PYTHON", self.spec["python"].command.path) diff --git a/var/spack/repos/builtin/packages/nopayloadclient/package.py b/var/spack/repos/builtin/packages/nopayloadclient/package.py new file mode 100644 index 00000000000000..0686d1b74e4c0c --- /dev/null +++ b/var/spack/repos/builtin/packages/nopayloadclient/package.py @@ -0,0 +1,33 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Nopayloadclient(CMakePackage): + """NoPayloadClient is the client-side library meant to communicate with NoPayloadDB.""" + + homepage = "https://github.com/BNLNPPS/nopayloadclient" + url = "https://github.com/BNLNPPS/nopayloadclient/archive/refs/tags/v0.0.3.tar.gz" + git = "https://github.com/BNLNPPS/nopayloadclient.git" + + maintainers("wdconinc") + + license("Apache-2.0", checked_by="wdconinc") + + version("main", branch="main") + version("0.0.3", sha256="9481981d0cfbe1727f08ae3d1129c142a952d5e67ddb9ad88224356040af2225") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + depends_on("curl") + depends_on("nlohmann-json", type="build") + + def cmake_args(self): + return [ + self.define("BUILD_TESTING", self.run_tests), + self.define("INCLUDE_DIR_NLOHMANN_JSON", self.spec["nlohmann-json"].prefix.include), + ] diff --git a/var/spack/repos/builtin/packages/notmuch/package.py b/var/spack/repos/builtin/packages/notmuch/package.py index 744dbd029b2592..4b500fcb744615 100644 --- a/var/spack/repos/builtin/packages/notmuch/package.py +++ b/var/spack/repos/builtin/packages/notmuch/package.py @@ -19,6 +19,9 @@ class Notmuch(AutotoolsPackage): version("0.23.7", sha256="f11bb10d71945f6c3f16d23117afc70810aa485878e66bb4bf43cc3f08038913") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("talloc") depends_on("gmime@2.6:") diff --git a/var/spack/repos/builtin/packages/npb/package.py b/var/spack/repos/builtin/packages/npb/package.py index e14f99bbabef62..439a09e45ce9fb 100644 --- a/var/spack/repos/builtin/packages/npb/package.py +++ b/var/spack/repos/builtin/packages/npb/package.py @@ -35,6 +35,9 @@ class Npb(MakefilePackage): version("3.3.1", sha256="4a8ea679b1df69f583c544c47198b3c26a50ec2bb6f8f69aef66c04c9a747d2d") version("3.4.1", sha256="f3a43467da6e84a829ea869156d3ea86c17932136bb413a4b6dab23018a28881") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # Valid Benchmark Names valid_names = ( "is", # Integer Sort, random memory access diff --git a/var/spack/repos/builtin/packages/npm/package.py b/var/spack/repos/builtin/packages/npm/package.py index decade229c4984..d44566a3ab4d82 100644 --- a/var/spack/repos/builtin/packages/npm/package.py +++ b/var/spack/repos/builtin/packages/npm/package.py @@ -23,6 +23,8 @@ class Npm(Package): version("7.24.2", sha256="5b9eeea011f8bc3b76e55cc33339e87213800677f37e0756ad13ef0e9eaccd64") version("6.14.18", sha256="c9b15f277e2a0b1b57e05bad04504296a27024555d56c2aa967f862e957ad2ed") + depends_on("cxx", type="build") # generated + depends_on("node-js", type=("build", "run")) depends_on("libvips", when="@:7") diff --git a/var/spack/repos/builtin/packages/npth/package.py b/var/spack/repos/builtin/packages/npth/package.py index 24bb3e68291806..317d1adf456f92 100644 --- a/var/spack/repos/builtin/packages/npth/package.py +++ b/var/spack/repos/builtin/packages/npth/package.py @@ -15,6 +15,9 @@ class Npth(AutotoolsPackage): license("LGPL-2.0-or-later") + version("1.7", sha256="8589f56937b75ce33b28d312fccbf302b3b71ec3f3945fde6aaa74027914ad05") version("1.6", sha256="1393abd9adcf0762d34798dc34fdcf4d0d22a8410721e76f1e3afcd1daa4e2d1") version("1.5", sha256="294a690c1f537b92ed829d867bee537e46be93fbd60b16c04630fbbfcd9db3c2") version("1.4", sha256="8915141836a3169a502d65c1ebd785fcc6d406cae5ee84474272ebf2fa96f1f2") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/ns-3-dev/package.py b/var/spack/repos/builtin/packages/ns-3-dev/package.py index 6a8aef33b1e06e..a6a8d6fc9114e2 100644 --- a/var/spack/repos/builtin/packages/ns-3-dev/package.py +++ b/var/spack/repos/builtin/packages/ns-3-dev/package.py @@ -18,6 +18,9 @@ class Ns3Dev(CMakePackage): version("3.40", sha256="96526e7ae6cb746d02af0cad04f63daff926dad5d30a6fe0d3c7943989ba4e59") version("3.37", sha256="d72defeeddbba14397cd4403565992d98cd7b7d9c680c22fee56022706878720") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("boost", default=True, description="Compile with Boost libraries") depends_on("gsl") diff --git a/var/spack/repos/builtin/packages/nsimd/package.py b/var/spack/repos/builtin/packages/nsimd/package.py index d7981d1ff46783..fc4f02baeeb888 100644 --- a/var/spack/repos/builtin/packages/nsimd/package.py +++ b/var/spack/repos/builtin/packages/nsimd/package.py @@ -26,6 +26,9 @@ class Nsimd(CMakePackage): # version('2.0', sha256='b239e98316f93257161b25c8232634884edcee358982a74742981cc9b68da642') version("1.0", sha256="523dae83f1d93eab30114321f1c9a67e2006a52595da4c51f121ca139abe0857") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "simd", default="auto", diff --git a/var/spack/repos/builtin/packages/nspr/package.py b/var/spack/repos/builtin/packages/nspr/package.py index f18f4c778d7d56..a2fa85d11ee67c 100644 --- a/var/spack/repos/builtin/packages/nspr/package.py +++ b/var/spack/repos/builtin/packages/nspr/package.py @@ -22,6 +22,9 @@ class Nspr(AutotoolsPackage): version("4.31", sha256="5729da87d5fbf1584b72840751e0c6f329b5d541850cacd1b61652c95015abc8") version("4.13.1", sha256="5e4c1751339a76e7c772c0c04747488d7f8c98980b434dc846977e43117833ab") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl", type="build") configure_directory = "nspr" diff --git a/var/spack/repos/builtin/packages/nss/package.py b/var/spack/repos/builtin/packages/nss/package.py index 3f10701b42e19f..189140250d6629 100644 --- a/var/spack/repos/builtin/packages/nss/package.py +++ b/var/spack/repos/builtin/packages/nss/package.py @@ -28,6 +28,9 @@ class Nss(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("nspr@4.24:") depends_on("sqlite") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/ntirpc/package.py b/var/spack/repos/builtin/packages/ntirpc/package.py index b35f256d49a009..6922fbe3810f79 100644 --- a/var/spack/repos/builtin/packages/ntirpc/package.py +++ b/var/spack/repos/builtin/packages/ntirpc/package.py @@ -18,5 +18,7 @@ class Ntirpc(CMakePackage): version("1.8.0", sha256="3bb642dccc8f2506b57a03b5d3358654f59f47b33fddfaa5a7330df4cf336f9f") version("1.7.3", sha256="8713ef095efc44df426bbd2b260ad457e5335bf3008fb97f01b0775c8042e54b") + depends_on("c", type="build") # generated + depends_on("libnsl") depends_on("userspace-rcu") diff --git a/var/spack/repos/builtin/packages/ntl/package.py b/var/spack/repos/builtin/packages/ntl/package.py index 2096c3334b42be..f7cf1c35f76da2 100644 --- a/var/spack/repos/builtin/packages/ntl/package.py +++ b/var/spack/repos/builtin/packages/ntl/package.py @@ -26,6 +26,8 @@ class Ntl(MakefilePackage): version("11.5.0", sha256="9e1e6488b177c3e5d772fdd6279c890937a9d1c3b694a904ac1cfbe9cab836db") version("11.4.4", sha256="2ce7a10fadbed6c3859d72c859612a4ca0dbdf6a9db99db4261422b7f0804bfa") + depends_on("cxx", type="build") # generated + variant("shared", default=False, description="Build shared library.") depends_on("gmp") diff --git a/var/spack/repos/builtin/packages/ntpoly/package.py b/var/spack/repos/builtin/packages/ntpoly/package.py index b6b736a6f77402..57db40ac75b51d 100644 --- a/var/spack/repos/builtin/packages/ntpoly/package.py +++ b/var/spack/repos/builtin/packages/ntpoly/package.py @@ -23,13 +23,25 @@ class Ntpoly(CMakePackage): version("3.1.0", sha256="71cd6827f20c68e384555dbcfc85422d0690e21d21d7b5d4f7375544a2755271") version("2.3.1", sha256="af8c7690321607fbdee9671b9cb3acbed945148014e0541435858cf82bfd887e") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("shared", default=True, description="Build shared libraries.") + depends_on("cmake", type="build") depends_on("blas", type="link") depends_on("mpi@3") def cmake_args(self): - args = ["-DNOSWIG=Yes"] + args = ["-DNOSWIG=Yes", self.define_from_variant("BUILD_SHARED_LIBS", "shared")] + if self.spec.satisfies("%fj"): args.append("-DCMAKE_Fortran_MODDIR_FLAG=-M") return args + + @property + def libs(self): + return find_libraries( + ["libNTPoly", "libNTPolyCPP", "libNTPolyWrapper"], root=self.home, recursive=True + ) diff --git a/var/spack/repos/builtin/packages/numactl/package.py b/var/spack/repos/builtin/packages/numactl/package.py index 1d50ca656e9191..0abd8d7c5a9434 100644 --- a/var/spack/repos/builtin/packages/numactl/package.py +++ b/var/spack/repos/builtin/packages/numactl/package.py @@ -20,6 +20,8 @@ class Numactl(AutotoolsPackage): version("2.0.12", sha256="7c3e819c2bdeb883de68bafe88776a01356f7ef565e75ba866c4b49a087c6bdf") version("2.0.11", sha256="3e099a59b2c527bcdbddd34e1952ca87462d2cef4c93da9b0bc03f02903f7089") + depends_on("c", type="build") # generated + patch("numactl-2.0.11-sysmacros.patch", when="@2.0.11") # https://github.com/numactl/numactl/issues/94 patch("numactl-2.0.14-symver.patch", when="@2.0.14") diff --git a/var/spack/repos/builtin/packages/numamma/package.py b/var/spack/repos/builtin/packages/numamma/package.py index 01bfa7fe4869d1..a560b619d7b619 100644 --- a/var/spack/repos/builtin/packages/numamma/package.py +++ b/var/spack/repos/builtin/packages/numamma/package.py @@ -18,6 +18,8 @@ class Numamma(CMakePackage): version("1.1.1", sha256="f79ca22a95df33a1af529ddd653d043f7f0d32a6d196e559aee8bef8fc74771f") + depends_on("c", type="build") # generated + depends_on("numap") depends_on("libbacktrace") depends_on("numactl") diff --git a/var/spack/repos/builtin/packages/numap/package.py b/var/spack/repos/builtin/packages/numap/package.py index 85ebf348ca324f..6e5623ae3400ef 100644 --- a/var/spack/repos/builtin/packages/numap/package.py +++ b/var/spack/repos/builtin/packages/numap/package.py @@ -17,4 +17,6 @@ class Numap(CMakePackage): version("master", branch="master") version("2019-09-06", commit="ffcdb88c64b59b7a3220eb1077d2b237029ca96a") + depends_on("c", type="build") # generated + depends_on("libpfm4") diff --git a/var/spack/repos/builtin/packages/numaprof/package.py b/var/spack/repos/builtin/packages/numaprof/package.py index bd7a2cd9e1a8ad..cb0282eca6a2c9 100644 --- a/var/spack/repos/builtin/packages/numaprof/package.py +++ b/var/spack/repos/builtin/packages/numaprof/package.py @@ -25,6 +25,9 @@ class Numaprof(CMakePackage): version("1.1.5", sha256="7c479cc6d39f2fe685532b9aaeb9efce8153350177fdcc24133e447dd0776323") version("1.1.4", sha256="96cc5e153895f43d8be58e052433c9e7c9842071cc6bf915b3b1b346908cbbff") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Variants variant( "qt", default=False, description="Build the QT embeded webview with Pyton + QT web toolkit" diff --git a/var/spack/repos/builtin/packages/numdiff/package.py b/var/spack/repos/builtin/packages/numdiff/package.py index 2fee673edbd14f..6d01acc677a9d2 100644 --- a/var/spack/repos/builtin/packages/numdiff/package.py +++ b/var/spack/repos/builtin/packages/numdiff/package.py @@ -19,6 +19,8 @@ class Numdiff(AutotoolsPackage): version("5.9.0", sha256="87284a117944723eebbf077f857a0a114d818f8b5b54d289d59e73581194f5ef") version("5.8.1", sha256="99aebaadf63325f5658411c09c6dde60d2990c5f9a24a51a6851cb574a4af503") + depends_on("c", type="build") # generated + variant("nls", default=False, description="Enable Natural Language Support") variant("gmp", default=False, description="Use GNU Multiple Precision Arithmetic Library") diff --git a/var/spack/repos/builtin/packages/nut/package.py b/var/spack/repos/builtin/packages/nut/package.py index 42764b62bcb53c..4d00edcbb31950 100644 --- a/var/spack/repos/builtin/packages/nut/package.py +++ b/var/spack/repos/builtin/packages/nut/package.py @@ -23,6 +23,8 @@ class Nut(CMakePackage): version("master", branch="master") version("0.1.1", sha256="9f1dca4a9d7003b170fd57d6720228ff25471616cf884e033652e90c49c089bb") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.0:", type="build") depends_on("random123") diff --git a/var/spack/repos/builtin/packages/nvbandwidth/package.py b/var/spack/repos/builtin/packages/nvbandwidth/package.py index 64f4fa5eee7291..677574ba22ea5d 100644 --- a/var/spack/repos/builtin/packages/nvbandwidth/package.py +++ b/var/spack/repos/builtin/packages/nvbandwidth/package.py @@ -42,6 +42,8 @@ class Nvbandwidth(CMakePackage, CudaPackage): sha256="ce164f91e35d1b28ebb1f83b22f38199e430d18ebfb8e21fa8c5e53c38d82daf", ) + depends_on("cxx", type="build") # generated + depends_on("boost@1.66.0 +program_options") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/nvcomp/package.py b/var/spack/repos/builtin/packages/nvcomp/package.py index 6dccb895bb1a06..e8a05563ebd2ae 100644 --- a/var/spack/repos/builtin/packages/nvcomp/package.py +++ b/var/spack/repos/builtin/packages/nvcomp/package.py @@ -26,6 +26,9 @@ class Nvcomp(CMakePackage, CudaPackage): version("2.2.0", commit="3737f6e5028ed1887b0023ad0fc033e139d57574") version("2.0.2", commit="5d5c194f3449486d989057f632d10954b8d11d75") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cuda") conflicts("~cuda") diff --git a/var/spack/repos/builtin/packages/nvdimmsim/package.py b/var/spack/repos/builtin/packages/nvdimmsim/package.py index 90cf100ab34a39..a8928e9dd3771c 100644 --- a/var/spack/repos/builtin/packages/nvdimmsim/package.py +++ b/var/spack/repos/builtin/packages/nvdimmsim/package.py @@ -20,6 +20,8 @@ class Nvdimmsim(MakefilePackage): version("2.0.0", sha256="2a621ef10be5e52a1f543985d08354a2e6ee6532b5720e5f17ad6362cfd4adef") + depends_on("cxx", type="build") # generated + def build(self, spec, prefix): with working_dir("src"): if spec.satisfies("platform=darwin"): diff --git a/var/spack/repos/builtin/packages/nvhpc/detection_test.yaml b/var/spack/repos/builtin/packages/nvhpc/detection_test.yaml new file mode 100644 index 00000000000000..bdf1c6b596c4dd --- /dev/null +++ b/var/spack/repos/builtin/packages/nvhpc/detection_test.yaml @@ -0,0 +1,82 @@ +paths: +- layout: + - executables: + - bin/nvc + script: | + echo "nvc 20.9-0 LLVM 64-bit target on x86-64 Linux -tp haswell" + echo "NVIDIA Compilers and Tools" + echo "Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved." + - executables: + - bin/nvc++ + script: | + echo "nvc++ 20.9-0 LLVM 64-bit target on x86-64 Linux -tp haswell" + echo "NVIDIA Compilers and Tools" + echo "Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved." + - executables: + - bin/nvfortran + script: | + echo "nvfortran 20.9-0 LLVM 64-bit target on x86-64 Linux -tp haswell" + echo "NVIDIA Compilers and Tools" + echo "Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved." + platforms: [linux] + results: + - spec: nvhpc@20.9~blas~lapack~mpi + extra_attributes: + compilers: + c: ".*/bin/nvc" + cxx: ".*/bin/nvc++" + fortran: ".*/bin/nvfortran" +- layout: + - executables: + - bin/nvc + script: | + echo "nvc 20.9-0 linuxpower target on Linuxpower" + echo "NVIDIA Compilers and Tools" + echo "Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved." + - executables: + - bin/nvc++ + script: | + echo "nvc++ 20.9-0 linuxpower target on Linuxpower" + echo "NVIDIA Compilers and Tools" + echo "Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved." + - executables: + - bin/nvfortran + script: | + echo "nvfortran 20.9-0 linuxpower target on Linuxpower" + echo "NVIDIA Compilers and Tools" + echo "Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved." + platforms: [linux] + results: + - spec: nvhpc@20.9~blas~lapack~mpi + extra_attributes: + compilers: + c: ".*/bin/nvc" + cxx: ".*/bin/nvc++" + fortran: ".*/bin/nvfortran" +- layout: + - executables: + - bin/nvc + script: | + echo "nvc 20.9-0 linuxarm64 target on aarch64 Linux" + echo "NVIDIA Compilers and Tools" + echo "Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved." + - executables: + - bin/nvc++ + script: | + echo "nvc++ 20.9-0 linuxarm64 target on aarch64 Linux" + echo "NVIDIA Compilers and Tools" + echo "Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved." + - executables: + - bin/nvfortran + script: | + echo "nvfortran 20.9-0 linuxarm64 target on aarch64 Linux" + echo "NVIDIA Compilers and Tools" + echo "Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved." + platforms: [linux] + results: + - spec: nvhpc@20.9~blas~lapack~mpi + extra_attributes: + compilers: + c: ".*/bin/nvc" + cxx: ".*/bin/nvc++" + fortran: ".*/bin/nvfortran" diff --git a/var/spack/repos/builtin/packages/nvhpc/package.py b/var/spack/repos/builtin/packages/nvhpc/package.py index 4531965a18848b..7b8c9bc553b798 100644 --- a/var/spack/repos/builtin/packages/nvhpc/package.py +++ b/var/spack/repos/builtin/packages/nvhpc/package.py @@ -21,6 +21,16 @@ # - package key must be in the form '{os}-{arch}' where 'os' is in the # format returned by platform.system() and 'arch' by platform.machine() _versions = { + "24.5": { + "Linux-aarch64": ( + "c52b5ba370e053472cbffb825ba1da5b6abaee93d4e15479ec12c32d6ebc47d5", + "https://developer.download.nvidia.com/hpc-sdk/24.5/nvhpc_2024_245_Linux_aarch64_cuda_multi.tar.gz", + ), + "Linux-x86_64": ( + "e26c5027ffd83fd9e854946670a97253e950cdbacd4894a6715aea91070042ae", + "https://developer.download.nvidia.com/hpc-sdk/24.5/nvhpc_2024_245_Linux_x86_64_cuda_multi.tar.gz", + ), + }, "24.3": { "Linux-aarch64": ( "6385847de5f8725e5c56d2abf70c90fed5490f2e71a7bd13d3f4ada8720ef036", @@ -370,7 +380,7 @@ } -class Nvhpc(Package): +class Nvhpc(Package, CompilerPackage): """The NVIDIA HPC SDK is a comprehensive suite of compilers, libraries and tools essential to maximizing developer productivity and the performance and portability of HPC applications. The NVIDIA HPC @@ -388,7 +398,9 @@ class Nvhpc(Package): maintainers("samcmill") tags = ["e4s"] - skip_version_audit = ["platform=darwin"] + skip_version_audit = ["platform=darwin", "platform=windows"] + + redistribute(source=False, binary=False) for ver, packages in _versions.items(): key = "{0}-{1}".format(platform.system(), platform.machine()) @@ -396,6 +408,10 @@ class Nvhpc(Package): if pkg: version(ver, sha256=pkg[0], url=pkg[1]) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("blas", default=True, description="Enable BLAS") variant( "install_type", @@ -417,6 +433,20 @@ class Nvhpc(Package): requires("%gcc", msg="nvhpc must be installed with %gcc") + # For now we only detect compiler components + # It will require additional work to detect mpi/lapack/blas components + compiler_languages = ["c", "cxx", "fortran"] + c_names = ["nvc"] + cxx_names = ["nvc++"] + fortran_names = ["nvfortran"] + compiler_version_argument = "--version" + compiler_version_regex = r"nv[^ ]* (?:[^ ]+ Dev-r)?([0-9.]+)(?:-[0-9]+)?" + + @classmethod + def determine_variants(cls, exes, version_str): + # TODO: use other exes to determine default_cuda/install_type/blas/lapack/mpi variants + return "~blas~lapack~mpi", {"compilers": cls.determine_compiler_paths(exes=exes)} + def _version_prefix(self): return join_path(self.prefix, "Linux_%s" % self.spec.target.family, self.version) diff --git a/var/spack/repos/builtin/packages/nvpl-blas/package.py b/var/spack/repos/builtin/packages/nvpl-blas/package.py index 211717d2bb414f..8e05a0be05ebf1 100644 --- a/var/spack/repos/builtin/packages/nvpl-blas/package.py +++ b/var/spack/repos/builtin/packages/nvpl-blas/package.py @@ -23,6 +23,7 @@ class NvplBlas(Package): license("UNKNOWN") version("0.1.0", sha256="4ccc894593cbcbfaa1a4f3c54505982691971667acf191c9ab0f4252a37c8063") + version("0.2.0.1", sha256="ba29f6a9d3831b6ae5c9265b4d124c13b9b9e0faea025359b02b41ad230975c2") provides("blas") @@ -42,6 +43,10 @@ class NvplBlas(Package): conflicts("threads=openmp", when="%clang") + def url_for_version(self, version): + url = "https://developer.download.nvidia.com/compute/nvpl/redist/nvpl_blas/linux-sbsa/nvpl_blas-linux-sbsa-{0}-archive.tar.xz" + return url.format(version) + @property def blas_headers(self): return find_all_headers(self.spec.prefix.include) diff --git a/var/spack/repos/builtin/packages/nvpl-lapack/package.py b/var/spack/repos/builtin/packages/nvpl-lapack/package.py index 20bc6d16d7867a..5d8547119eefdd 100644 --- a/var/spack/repos/builtin/packages/nvpl-lapack/package.py +++ b/var/spack/repos/builtin/packages/nvpl-lapack/package.py @@ -22,7 +22,8 @@ class NvplLapack(Package): license("UNKNOWN") - version("0.2.0", sha256="7054f775b18916ee662c94ad7682ace53debbe8ee36fa926000fe412961edb0b") + version("0.2.0.1", sha256="7054f775b18916ee662c94ad7682ace53debbe8ee36fa926000fe412961edb0b") + version("0.2.2.1", sha256="cdfbf69517a044e99e3e6231c8b2f4e845fd0de57775ccad6b4b0b4fe7e91e84") provides("lapack") @@ -50,6 +51,10 @@ class NvplLapack(Package): conflicts("threads=openmp", when="%clang") + def url_for_version(self, version): + url = "https://developer.download.nvidia.com/compute/nvpl/redist/nvpl_lapack/linux-sbsa/nvpl_lapack-linux-sbsa-{0}-archive.tar.xz" + return url.format(version) + @property def lapack_headers(self): return find_all_headers(self.spec.prefix.include) diff --git a/var/spack/repos/builtin/packages/nvptx-tools/package.py b/var/spack/repos/builtin/packages/nvptx-tools/package.py index 7305a403476178..e442fbc17ef2ee 100644 --- a/var/spack/repos/builtin/packages/nvptx-tools/package.py +++ b/var/spack/repos/builtin/packages/nvptx-tools/package.py @@ -19,6 +19,9 @@ class NvptxTools(AutotoolsPackage): version("2021-05-21", commit="d0524fbdc86dfca068db5a21cc78ac255b335be5") version("2018-03-01", commit="5f6f343a302d620b0868edab376c00b15741e39e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("binutils") depends_on("cuda") diff --git a/var/spack/repos/builtin/packages/nvshmem/package.py b/var/spack/repos/builtin/packages/nvshmem/package.py index 7bb13dd912a3ff..5d93c01afc7867 100644 --- a/var/spack/repos/builtin/packages/nvshmem/package.py +++ b/var/spack/repos/builtin/packages/nvshmem/package.py @@ -28,6 +28,9 @@ class Nvshmem(MakefilePackage, CudaPackage): version("2.1.2-0", sha256="367211808df99b4575fb901977d9f4347065c61a26642d65887f24d60342a4ec") version("2.0.3-0", sha256="20da93e8508511e21aaab1863cb4c372a3bec02307b932144a7d757ea5a1bad2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cuda", default=True, description="Build with CUDA") variant("ucx", default=True, description="Build with UCX support") variant("nccl", default=True, description="Build with NCCL support") diff --git a/var/spack/repos/builtin/packages/nvtx/package.py b/var/spack/repos/builtin/packages/nvtx/package.py index eff8c65b36cb4f..ef2ecfa64c9249 100644 --- a/var/spack/repos/builtin/packages/nvtx/package.py +++ b/var/spack/repos/builtin/packages/nvtx/package.py @@ -19,6 +19,8 @@ class Nvtx(Package, PythonExtension): version("develop", branch="dev") version("3.1.0", sha256="dc4e4a227d04d3da46ad920dfee5f7599ac8d6b2ee1809c9067110fb1cc71ced") + depends_on("cxx", type="build") # generated + variant("python", default=True, description="Install Python bindings.") extends("python", when="+python") depends_on("py-pip", type="build", when="+python") diff --git a/var/spack/repos/builtin/packages/nwchem/package.py b/var/spack/repos/builtin/packages/nwchem/package.py index 4795a8e800d8af..e4f5829503d1ae 100644 --- a/var/spack/repos/builtin/packages/nwchem/package.py +++ b/var/spack/repos/builtin/packages/nwchem/package.py @@ -17,6 +17,8 @@ class Nwchem(Package): tags = ["ecp", "ecp-apps"] + maintainers("jeffhammond") + version( "7.2.2", sha256="6b68e9c12eec38c09d92472bdd1ff130b93c1b5e1f65e4702aa7ee36c80e4af7", @@ -33,8 +35,22 @@ class Nwchem(Package): url="https://github.com/nwchemgit/nwchem/releases/download/v7.0.2-release/nwchem-7.0.2-release.revision-b9985dfa-srconly.2020-10-12.tar.bz2", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=False, description="Enables OpenMP support") - variant("mpipr", default=False, description="Enables ARMCI with progress rank") + variant( + "armci", + values=("mpi-ts", "mpi-pr", "armcimpi", "mpi3", "openib", "ofi"), + default="mpi-ts", + description="ARMCI runtime", + ) + variant( + "extratce", + default=False, + description="Enables rarely-used TCE features (CCSDTQ, CCSDTLR, EACCSD, IPCCSD, MRCC)", + ) variant("fftw3", default=False, description="Link against the FFTW library") variant("libxc", default=False, description="Support additional functionals via libxc") variant( @@ -55,11 +71,14 @@ class Nwchem(Package): # https://github.com/nwchemgit/nwchem/commit/376f86f96eb982e83f10514e9dcd994564f973b4 # https://github.com/nwchemgit/nwchem/commit/c89fc9d1eca6689bce12564a63fdea95d962a123 # Prior versions of NWChem, including 7.0.2, were not able to link with FFTW - patch("fftw_splans.patch", when="@7.2.0 +fftw3") + patch("fftw_splans.patch", when="@7.2.0:7.2.2 +fftw3") depends_on("blas") depends_on("lapack") depends_on("mpi") + depends_on("armcimpi", when="armci=armcimpi") + depends_on("libfabric", when="armci=ofi") + depends_on("rdma-core", when="armci=openib") depends_on("scalapack") depends_on("fftw-api@3", when="+fftw3") depends_on("libxc", when="+libxc") @@ -88,10 +107,6 @@ def install(self, spec, prefix): f"LAPACK_LIB={lapack.ld_flags}", f"SCALAPACK_LIB={scalapack.ld_flags}", "USE_NOIO=Y", # skip I/O algorithms - "MRCC_METHODS=y", # TCE extra module - "IPCCSD=y", # TCE extra module - "EACCSD=y", # TCE extra module - "CCSDTQ=y", # TCE extra module "V=1", # verbose build ] ) @@ -121,11 +136,32 @@ def install(self, spec, prefix): args.extend([f"NWCHEM_TARGET={target}"]) + # These optional components of TCE are rarely used and in some cases + # increase the compilation time significantly (CCSDTLR and CCSDTQ). + if spec.satisfies("+extratce"): + args.extend(["MRCC_METHODS=y"]) + args.extend(["IPCCSD=y"]) + args.extend(["EACCSD=y"]) + args.extend(["CCSDTLR=y"]) + args.extend(["CCSDTQ=y"]) + if spec.satisfies("+openmp"): args.extend(["USE_OPENMP=y"]) - if spec.satisfies("+mpipr"): + if self.spec.variants["armci"].value == "armcimpi": + armcimpi = spec["armci"] + args.extend(["ARMCI_NETWORK=ARMCI"]) + args.extend([f"EXTERNAL_ARMCI_PATH={armcimpi.prefix}"]) + elif self.spec.variants["armci"].value == "mpi-pr": args.extend(["ARMCI_NETWORK=MPI-PR"]) + elif self.spec.variants["armci"].value == "mpi-ts": + args.extend(["ARMCI_NETWORK=MPI-TS"]) + elif self.spec.variants["armci"].value == "mpi3": + args.extend(["ARMCI_NETWORK=MPI3"]) + elif self.spec.variants["armci"].value == "openib": + args.extend(["ARMCI_NETWORK=OPENIB"]) + elif self.spec.variants["armci"].value == "ofi": + args.extend(["ARMCI_NETWORK=OFI"]) if spec.satisfies("+fftw3"): args.extend(["USE_FFTW3=y"]) @@ -133,8 +169,8 @@ def install(self, spec, prefix): args.extend(["FFTW3_INCLUDE={0}".format(spec["fftw-api"].prefix.include)]) if spec.satisfies("+libxc"): - args.extend([f"LIBXC_LIB={0}".format(spec["libxc"].libs.ld_flags)]) - args.extend([f"LIBXC_INCLUDE={0}".format(spec["libxc"].prefix.include)]) + args.extend(["LIBXC_LIB={0}".format(spec["libxc"].libs.ld_flags)]) + args.extend(["LIBXC_INCLUDE={0}".format(spec["libxc"].prefix.include)]) if spec.satisfies("+elpa"): elpa = spec["elpa"] diff --git a/var/spack/repos/builtin/packages/nyancat/package.py b/var/spack/repos/builtin/packages/nyancat/package.py index 6aae2643442520..8eb8edaf34a2c6 100644 --- a/var/spack/repos/builtin/packages/nyancat/package.py +++ b/var/spack/repos/builtin/packages/nyancat/package.py @@ -18,6 +18,8 @@ class Nyancat(MakefilePackage): version("1.5.0", sha256="9ae4f740060b77bba815d8d4e97712d822bd0812a118b88b7fd6b4136a971bce") version("1.4.5", sha256="b26d752b95088be9d5caa73daea884572c0fc836ba55f0062e4d975301c4c661") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): makefile = FileFilter("Makefile") makefile.filter( diff --git a/var/spack/repos/builtin/packages/ocaml/package.py b/var/spack/repos/builtin/packages/ocaml/package.py index 175a5833cf2ca0..7fb887965a2322 100644 --- a/var/spack/repos/builtin/packages/ocaml/package.py +++ b/var/spack/repos/builtin/packages/ocaml/package.py @@ -27,6 +27,9 @@ class Ocaml(Package): version("4.06.0", sha256="c17578e243c4b889fe53a104d8927eb8749c7be2e6b622db8b3c7b386723bf50") version("4.03.0", sha256="7fdf280cc6c0a2de4fc9891d0bf4633ea417046ece619f011fd44540fcfc8da2") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + patch("fix-duplicate-defs.patch", when="@4.08.0:4.09.0 %gcc@10.0:") # #9969, #9981: Added mergeable flag to ELF sections containing mergeable # constants. Fixes compatibility with the integrated assembler in clang 11.0.0. diff --git a/var/spack/repos/builtin/packages/occa/package.py b/var/spack/repos/builtin/packages/occa/package.py index bd56b8e3fac13b..941cbf3ca551ee 100644 --- a/var/spack/repos/builtin/packages/occa/package.py +++ b/var/spack/repos/builtin/packages/occa/package.py @@ -34,6 +34,10 @@ class Occa(Package): version("0.2.0", tag="v0.2.0", commit="2eceaa5706ad6cf3a1b153c1f2a8a2fffa2d5945") version("0.1.0", tag="v0.1.0", commit="381e886886dc87823769c5f20d0ecb29dd117afa") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("cuda", default=True, description="Activates support for CUDA") variant("openmp", default=True, description="Activates support for OpenMP") variant("opencl", default=True, description="Activates support for OpenCL") diff --git a/var/spack/repos/builtin/packages/oce/package.py b/var/spack/repos/builtin/packages/oce/package.py index ecc72911ae5de4..48f1ed0eeb27ee 100644 --- a/var/spack/repos/builtin/packages/oce/package.py +++ b/var/spack/repos/builtin/packages/oce/package.py @@ -3,13 +3,10 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import platform - -from spack.operating_systems.mac_os import macos_version from spack.package import * -class Oce(Package): +class Oce(CMakePackage): """Open CASCADE Community Edition UNMAINTAINED: see https://github.com/tpaviot/oce/issues/745#issuecomment-992285943 @@ -18,20 +15,36 @@ class Oce(Package): homepage = "https://github.com/tpaviot/oce" url = "https://github.com/tpaviot/oce/archive/OCE-0.18.tar.gz" - version("0.18.3", sha256="c553d6a7bf52f790abc3b6bb7a1e91a65947e92a426bb1a88a11960c31f0966c") - version("0.18.2", sha256="dc21ddea678a500ad87c773e9a502ed7a71768cf83d9af0bd4c43294186a7fef") - version("0.18.1", sha256="1acf5da4bffa3592ca9f3535af9b927b79fcfeadcb81e9963e89aec192929a6c") - version("0.18", sha256="226e45e77c16a4a6e127c71fefcd171410703960ae75c7ecc7eb68895446a993") - version("0.17.2", sha256="8d9995360cd531cbd4a7aa4ca5ed969f08ec7c7a37755e2f3d4ef832c1b2f56e") - version("0.17.1", sha256="b1ff0cb8cf31339bbb30ac7ed2415d376b9b75810279d2f497e115f08c090928") - version("0.17", sha256="9ab0dc2a2d125b46cef458b56c6d171dfe2218d825860d616c5ab17994b8f74d") - version("0.16.1", sha256="d31030c8da4a1b33f767d0d59895a995c8eabc8fc65cbe0558734f6021ea2f57") - version("0.16", sha256="841fe4337a5a4e733e36a2efc4fe60a4e6e8974917028df05d47a02f59787515") + with default_args(deprecated=True): + version( + "0.18.3", sha256="c553d6a7bf52f790abc3b6bb7a1e91a65947e92a426bb1a88a11960c31f0966c" + ) + version( + "0.18.2", sha256="dc21ddea678a500ad87c773e9a502ed7a71768cf83d9af0bd4c43294186a7fef" + ) + version( + "0.18.1", sha256="1acf5da4bffa3592ca9f3535af9b927b79fcfeadcb81e9963e89aec192929a6c" + ) + version("0.18", sha256="226e45e77c16a4a6e127c71fefcd171410703960ae75c7ecc7eb68895446a993") + version( + "0.17.2", sha256="8d9995360cd531cbd4a7aa4ca5ed969f08ec7c7a37755e2f3d4ef832c1b2f56e" + ) + version( + "0.17.1", sha256="b1ff0cb8cf31339bbb30ac7ed2415d376b9b75810279d2f497e115f08c090928" + ) + version("0.17", sha256="9ab0dc2a2d125b46cef458b56c6d171dfe2218d825860d616c5ab17994b8f74d") + version( + "0.16.1", sha256="d31030c8da4a1b33f767d0d59895a995c8eabc8fc65cbe0558734f6021ea2f57" + ) + version("0.16", sha256="841fe4337a5a4e733e36a2efc4fe60a4e6e8974917028df05d47a02f59787515") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated variant("tbb", default=True, description="Build with Intel Threading Building Blocks") variant("X11", default=False, description="Build with X11 enabled") - depends_on("cmake@2.8:", type="build") + depends_on("cmake@3:", type="build") with when("+tbb"): depends_on("tbb") @@ -50,43 +63,25 @@ class Oce(Package): # see https://github.com/tpaviot/oce/issues/675 patch("xlocale.patch", level=0, when="@0.18.1:0.18.2") - # fix build with Xcode 8 "previous definition of CLOCK_REALTIME" - # reported 27 Sep 2016 https://github.com/tpaviot/oce/issues/643 - if (platform.system() == "Darwin") and (macos_version() == Version("10.12")): - patch("sierra.patch", when="@0.17.2:0.18.0") - - def install(self, spec, prefix): - options = [] - options.extend(std_cmake_args) - options.extend( - [ - "-DOCE_INSTALL_PREFIX=%s" % prefix, - "-DOCE_BUILD_SHARED_LIB:BOOL=ON", - "-DCMAKE_BUILD_TYPE:STRING=Release", - "-DOCE_DATAEXCHANGE:BOOL=ON", - "-DOCE_DISABLE_X11:BOOL=%s" % ("OFF" if "+X11" in spec else "ON"), - "-DOCE_DRAW:BOOL=OFF", - "-DOCE_MODEL:BOOL=ON", - "-DOCE_MULTITHREAD_LIBRARY:STRING=%s" % ("TBB" if "+tbb" in spec else "NONE"), - "-DOCE_OCAF:BOOL=ON", - "-DOCE_USE_TCL_TEST_FRAMEWORK:BOOL=OFF", - "-DOCE_VISUALISATION:BOOL=OFF", - "-DOCE_WITH_FREEIMAGE:BOOL=OFF", - "-DOCE_WITH_GL2PS:BOOL=OFF", - "-DOCE_WITH_OPENCL:BOOL=OFF", - ] - ) - - if platform.system() == "Darwin": - options.extend(["-DOCE_OSX_USE_COCOA:BOOL=ON"]) - - if platform.system() == "Darwin" and (macos_version() >= Version("10.12")): - # use @rpath on Sierra due to limit of dynamic loader - options.append("-DCMAKE_MACOSX_RPATH=ON") - else: - options.append("-DCMAKE_INSTALL_NAME_DIR:PATH=%s/lib" % prefix) - - cmake(".", *options) - make("install/strip") - if self.run_tests: - make("test") + def cmake_args(self): + args = [ + self.define("OCE_INSTALL_PREFIX", self.prefix), + self.define("OCE_BUILD_SHARED_LIB", True), + self.define("OCE_DATAEXCHANGE", True), + self.define("OCE_DISABLE_X11", self.spec.satisfies("~X11")), + self.define("OCE_DRAW", False), + self.define("OCE_MODEL", True), + self.define( + "OCE_MULTITHREAD_LIBRARY", ("TBB" if self.spec.satisfies("+tbb") else "NONE") + ), + self.define("OCE_OCAF", True), + self.define("OCE_USE_TCL_TEST_FRAMEWORK", False), + self.define("OCE_VISUALISATION", False), + self.define("OCE_WITH_FREEIMAGE", False), + self.define("OCE_WITH_GL2PS", False), + self.define("OCE_WITH_OPENCL", False), + ] + + if self.spec.satisfies("platform=darwin"): + args.append(self.define("OCE_OSX_USE_COCOA", True)) + return args diff --git a/var/spack/repos/builtin/packages/oce/sierra.patch b/var/spack/repos/builtin/packages/oce/sierra.patch deleted file mode 100644 index 1c0c86569bf85b..00000000000000 --- a/var/spack/repos/builtin/packages/oce/sierra.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/src/OSD/OSD_Chronometer.cxx b/src/OSD/OSD_Chronometer.cxx -index f7374fb..63ac140 100644 ---- a/src/OSD/OSD_Chronometer.cxx.old -+++ b/src/OSD/OSD_Chronometer.cxx -@@ -51,7 +51,7 @@ - #include - #endif - --#if defined(__APPLE__) && defined(__MACH__) -+#if defined(__APPLE__) && !defined(__MAC_10_12) - #include "gettime_osx.h" - #endif diff --git a/var/spack/repos/builtin/packages/oci-systemd-hook/package.py b/var/spack/repos/builtin/packages/oci-systemd-hook/package.py index 5d0c5c62bdae1d..01d29d8bf7cb64 100644 --- a/var/spack/repos/builtin/packages/oci-systemd-hook/package.py +++ b/var/spack/repos/builtin/packages/oci-systemd-hook/package.py @@ -19,6 +19,8 @@ class OciSystemdHook(AutotoolsPackage): version("0.1.18", sha256="c17291bf5151e972c502ec3cc9b445967823444b1f3917481eb419c9e476649e") version("0.1.5", sha256="53f773b055928d0f3d25ccc966d0d0b3ccb4dd00e8ff71a067b105142da22763") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/ocl-icd/package.py b/var/spack/repos/builtin/packages/ocl-icd/package.py index 80f500c61bd4c3..6ef7dd87a0d221 100644 --- a/var/spack/repos/builtin/packages/ocl-icd/package.py +++ b/var/spack/repos/builtin/packages/ocl-icd/package.py @@ -31,6 +31,8 @@ class OclIcd(AutotoolsPackage): version("2.2.4", sha256="92853137ffff393cc74f829357fdd80ac46a82b46c970e80195db86164cca316") version("2.2.3", sha256="46b8355d90f8cc240555e4e077f223c47b950abeadf3e1af52d6e68d2efc2ff3") + depends_on("c", type="build") # generated + variant( "headers", default=False, diff --git a/var/spack/repos/builtin/packages/oclgrind/package.py b/var/spack/repos/builtin/packages/oclgrind/package.py index 76dd8fd47a0fdd..fdf3bc69dba339 100644 --- a/var/spack/repos/builtin/packages/oclgrind/package.py +++ b/var/spack/repos/builtin/packages/oclgrind/package.py @@ -20,4 +20,7 @@ class Oclgrind(CMakePackage): version("master", branch="master") version("19.10", sha256="f9a8f22cb9f6d88670f2578c46ba0d728ba8eaee5c481c2811129dc157c43dc0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("llvm +clang @5.0:") diff --git a/var/spack/repos/builtin/packages/oclint/package.py b/var/spack/repos/builtin/packages/oclint/package.py index c278ea5751d219..2fa9c53596f71e 100644 --- a/var/spack/repos/builtin/packages/oclint/package.py +++ b/var/spack/repos/builtin/packages/oclint/package.py @@ -18,6 +18,8 @@ class Oclint(Package): version("0.13", sha256="a0fd188673863e6357d6585b9bb9c3affe737df134b9383a1a5ed021d09ed848") + depends_on("cxx", type="build") # generated + depends_on("python", type=("build")) depends_on("git", type=("build")) depends_on("subversion", type=("build")) diff --git a/var/spack/repos/builtin/packages/oclock/package.py b/var/spack/repos/builtin/packages/oclock/package.py index c8816c74075acd..9622c8f8874e1b 100644 --- a/var/spack/repos/builtin/packages/oclock/package.py +++ b/var/spack/repos/builtin/packages/oclock/package.py @@ -17,6 +17,8 @@ class Oclock(AutotoolsPackage, XorgPackage): version("1.0.4", sha256="cffc414cd0cf0b0e4a9bec3b5e707d9c2e2bcd109629d74bd6dd61381563dd35") version("1.0.3", sha256="6628d1abe1612b87db9d0170cbe7f1cf4205cd764274f648c3c1bdb745bff877") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxmu") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/octave-arduino/package.py b/var/spack/repos/builtin/packages/octave-arduino/package.py index 52857e761c91e5..9dab93a2a908c9 100644 --- a/var/spack/repos/builtin/packages/octave-arduino/package.py +++ b/var/spack/repos/builtin/packages/octave-arduino/package.py @@ -17,5 +17,7 @@ class OctaveArduino(OctavePackage, SourceforgePackage): version("0.2.0", sha256="0562ff48ea4b2cef28e2e03ccc4678dafa16f91d1580245bb7f9f488c4f56238") + depends_on("cxx", type="build") # generated + depends_on("octave-instrctl") extends("octave@3.6.0:") diff --git a/var/spack/repos/builtin/packages/octave-control/package.py b/var/spack/repos/builtin/packages/octave-control/package.py index 629d2a1baf2f0e..e3da8de047c2b2 100644 --- a/var/spack/repos/builtin/packages/octave-control/package.py +++ b/var/spack/repos/builtin/packages/octave-control/package.py @@ -17,4 +17,6 @@ class OctaveControl(OctavePackage, SourceforgePackage): version("3.2.0", sha256="faf1d510d16ab46e4fa91a1288f4a7839ee05469c33e4698b7a007a0bb965e3e") + depends_on("cxx", type="build") # generated + extends("octave@4.0.0:") diff --git a/var/spack/repos/builtin/packages/octave-gsl/package.py b/var/spack/repos/builtin/packages/octave-gsl/package.py index ca82c960561b80..0884768d822f50 100644 --- a/var/spack/repos/builtin/packages/octave-gsl/package.py +++ b/var/spack/repos/builtin/packages/octave-gsl/package.py @@ -16,6 +16,8 @@ class OctaveGsl(OctavePackage, SourceforgePackage): version("2.1.1", sha256="d028c52579e251c3f21ebfdf065dffab3ad7893434efda33b501225ef1ea6ed3") + depends_on("cxx", type="build") # generated + depends_on("gsl@2.4:") extends("octave@2.9.7:") diff --git a/var/spack/repos/builtin/packages/octave-instrctl/package.py b/var/spack/repos/builtin/packages/octave-instrctl/package.py index 3ee5ff878e26e1..be6c23aba99ccd 100644 --- a/var/spack/repos/builtin/packages/octave-instrctl/package.py +++ b/var/spack/repos/builtin/packages/octave-instrctl/package.py @@ -15,4 +15,6 @@ class OctaveInstrctl(OctavePackage, SourceforgePackage): version("0.3.1", sha256="d9c3b2e258cc8245ebfdd282e6314af12987daf453f4356555f56ca5ec55873c") + depends_on("cxx", type="build") # generated + extends("octave@3.6.0:") diff --git a/var/spack/repos/builtin/packages/octave/package.py b/var/spack/repos/builtin/packages/octave/package.py index ef2e5e02e3023b..422664ef8deab0 100644 --- a/var/spack/repos/builtin/packages/octave/package.py +++ b/var/spack/repos/builtin/packages/octave/package.py @@ -30,6 +30,8 @@ class Octave(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-or-later") + version("9.1.0", sha256="3f8c6c6ecfa249a47c97e18e651be4db8499be2f5de1a095a3eea53efc01d6a1") + version("8.4.0", sha256="6b38dd9751678424aeb3a9d666432b1f378eb3971a21290a90cd3d35119d56ad") version("8.2.0", sha256="57d17f918a940d38ca3348211e110b34d735a322a87db71c177c4692a49a9c84") version("8.1.0", sha256="8052074d17b0ef643d037de8ab389672c752bb201ee9cea4dfa69858fb6a213f") version("7.3.0", sha256="6e14a4649d70af45ab660f8cbbf645aaf1ec33f25f88bfda4697cb17e440c4f5") @@ -49,6 +51,10 @@ class Octave(AutotoolsPackage, GNUMirrorPackage): version("4.0.2", sha256="39cd8fd36c218fc00adace28d74a6c7c9c6faab7113a5ba3c4372324c755bdc1") version("4.0.0", sha256="4c7ee0957f5dd877e3feb9dfe07ad5f39b311f9373932f0d2a289dc97cca3280") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # patches # see https://savannah.gnu.org/bugs/?50234 patch("patch_4.2.1_inline.diff", when="@4.2.1") @@ -67,9 +73,10 @@ class Octave(AutotoolsPackage, GNUMirrorPackage): variant("gnuplot", default=False, description="Use gnuplot") variant("magick", default=False, description="Use magick") variant("hdf5", default=False, description="Use HDF5") - variant("jdk", default=False, description="Use JDK") + variant("jdk", default=False, description="Use Java") variant("llvm", default=False, description="Use LLVM") variant("opengl", default=False, description="Use OpenGL") + variant("pcre2", default=True, when="@8:", description="Use PCRE2 instead of PCRE") variant("qhull", default=False, description="Use qhull") variant("qrupdate", default=False, description="Use qrupdate") variant("qscintilla", default=False, description="Use QScintill") @@ -82,7 +89,9 @@ class Octave(AutotoolsPackage, GNUMirrorPackage): depends_on("lapack") # Octave does not configure with sed from darwin: depends_on("sed", when=sys.platform == "darwin", type="build") - depends_on("pcre") + depends_on("pcre", when="@:7") + depends_on("pcre", when="~pcre2") + depends_on("pcre2", when="+pcre2") depends_on("pkgconfig", type="build") depends_on("texinfo", type="build") @@ -348,6 +357,8 @@ def configure_args(self): else: config_args.append("--without-z") + if spec.satisfies("~pcre2"): + config_args.append("--without-pcre2") # If 64-bit BLAS is used: if ( spec.satisfies("^openblas+ilp64") diff --git a/var/spack/repos/builtin/packages/octopus/package.py b/var/spack/repos/builtin/packages/octopus/package.py index 3690feb1c3e361..8c8e2dd5d0b4c6 100644 --- a/var/spack/repos/builtin/packages/octopus/package.py +++ b/var/spack/repos/builtin/packages/octopus/package.py @@ -23,6 +23,7 @@ class Octopus(AutotoolsPackage, CudaPackage): license("Apache-2.0") + version("14.1", sha256="6955f4020e69f038650a24509ff19ef35de4fd34e181539f92fa432db9b66ca7") version("14.0", sha256="3cf6ef571ff97cc2c226016815d2ac4aa1e00ae3fb0cc693e0aff5620b80373e") version("13.0", sha256="b4d0fd496c31a9c4aa4677360e631765049373131e61f396b00048235057aeb1") version("12.2", sha256="e919e07703696eadb4ba59352d7a2678a9191b4586cb9da538661615e765a5a2") @@ -43,6 +44,10 @@ class Octopus(AutotoolsPackage, CudaPackage): version("develop", branch="main") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Build with MPI support") variant("scalapack", default=False, when="+mpi", description="Compile with Scalapack") variant("berkeleygw", default=False, description="Compile with BerkeleyGW") @@ -300,6 +305,11 @@ def configure_args(self): args.append(f"{cxxflags} {gcc10_extra}") args.append(f"{cflags} {gcc10_extra}") + # for octopus 14.1 and above autotools is deprecated in favour of cmake + # inorder to continue using autotools we pass `--enable-silent-deprecation` + if spec.satisfies("@14.1:"): + args.append("--enable-silent-deprecation") + # Disable flags # # disable gdlib explicitly to avoid @@ -310,54 +320,38 @@ def configure_args(self): @run_after("install") @on_package_attributes(run_tests=True) - def smoke_tests_after_install(self): + def benchmark_tests_after_install(self): """Function stub to run tests after install if desired (for example through `spack install --test=root octopus`) """ - self.smoke_tests() + self.test_version() + self.test_example() + self.test_he() - def test(self): - """Entry point for smoke tests run through `spack test run octopus`.""" - self.smoke_tests() - - def smoke_tests(self): - """Actual smoke tests for Octopus.""" - # - # run "octopus --version" - # - exe = join_path(self.spec.prefix.bin, "octopus") - options = ["--version"] - purpose = "Check octopus can execute (--version)" + def test_version(self): + """Check octopus can execute (--version)""" # Example output: # # spack-v0.17.2$ octopus --version # octopus 11.3 (git commit ) - expected = ["octopus "] - - self.run_test( - exe, - options=options, - expected=expected, - status=[0], - installed=False, - purpose=purpose, - skip_missing=False, - ) + + exe = which(self.spec.prefix.bin.octopus) + out = exe("--version", output=str.split, error=str.split) + assert "octopus " in out + + def test_recipe(self): + """run recipe example""" # Octopus expects a file with name `inp` in the current working # directory to read configuration information for a simulation run from # that file. We copy the relevant configuration file in a dedicated - # subfolder for each test. + # subfolder for the test. # # As we like to be able to run these tests also with the # `spack install --test=root` command, we cannot rely on # self.test_suite.current_test_data_dir, and need to copy the test # input files manually (see below). - # - # run recipe example - # - expected = [ "Running octopus", "CalculationMode = recipe", @@ -365,24 +359,27 @@ def smoke_tests(self): "recipe leads to an edible dish, " 'for it is clearly "system-dependent".', "Calculation ended on", ] - options = [] - purpose = "Run Octopus recipe example" + with working_dir("example-recipe", create=True): print("Current working directory (in example-recipe)") fs.copy(join_path(os.path.dirname(__file__), "test", "recipe.inp"), "inp") - self.run_test( - exe, - options=options, - expected=expected, - status=[0], - installed=False, - purpose=purpose, - skip_missing=False, - ) + exe = which(self.spec.prefix.bin.octopus) + out = exe(output=str.split, error=str.split) + check_outputs(expected, out) + def test_he(self): + """run He example""" + + # Octopus expects a file with name `inp` in the current working + # directory to read configuration information for a simulation run from + # that file. We copy the relevant configuration file in a dedicated + # subfolder for the test. # - # run He example - # + # As we like to be able to run these tests also with the + # `spack install --test=root` command, we cannot rely on + # self.test_suite.current_test_data_dir, and need to copy the test + # input files manually (see below). + expected = [ "Running octopus", "Info: Starting calculation mode.", @@ -391,17 +388,10 @@ def smoke_tests(self): "Info: Writing states.", "Calculation ended on", ] - options = [] - purpose = "Run tiny calculation for He" + with working_dir("example-he", create=True): print("Current working directory (in example-he)") fs.copy(join_path(os.path.dirname(__file__), "test", "he.inp"), "inp") - self.run_test( - exe, - options=options, - expected=expected, - status=[0], - installed=False, - purpose=purpose, - skip_missing=False, - ) + exe = which(self.spec.prefix.bin.octopus) + out = exe(output=str.split, error=str.split) + check_outputs(expected, out) diff --git a/var/spack/repos/builtin/packages/odc/package.py b/var/spack/repos/builtin/packages/odc/package.py index 5022fd6b25750d..b34a279701cb09 100644 --- a/var/spack/repos/builtin/packages/odc/package.py +++ b/var/spack/repos/builtin/packages/odc/package.py @@ -16,9 +16,14 @@ class Odc(CMakePackage): license("Apache-2.0") + version("1.4.6", sha256="ff99d46175e6032ddd0bdaa3f6a5e2c4729d24b698ba0191a2a4aa418f48867c") version("1.4.5", sha256="8532d0453531d62e1f15791d1c5c96540b842913bd211a8ef090211eaf4cccae") version("1.3.0", sha256="97a4f10765b341cc8ccbbf203f5559cb1b838cbd945f48d4cecb1bc4305e6cd6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=False, description="Enable the Fortran interface") depends_on("ecbuild@3.4:", type="build") diff --git a/var/spack/repos/builtin/packages/odgi/package.py b/var/spack/repos/builtin/packages/odgi/package.py index 0c4b9ea2ff3b07..c96761bcfc06b5 100644 --- a/var/spack/repos/builtin/packages/odgi/package.py +++ b/var/spack/repos/builtin/packages/odgi/package.py @@ -21,6 +21,9 @@ class Odgi(CMakePackage): # <<< Versions list starts here version("0.8.3", commit="34f006f31c3f6b35a1eb8d58a4edb1c458583de3", submodules=True) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated # >>> Versions list ends here # compilation problem with ninja diff --git a/var/spack/repos/builtin/packages/of-catalyst/package.py b/var/spack/repos/builtin/packages/of-catalyst/package.py index d7a3821736a2da..7db9cb811a6f6a 100644 --- a/var/spack/repos/builtin/packages/of-catalyst/package.py +++ b/var/spack/repos/builtin/packages/of-catalyst/package.py @@ -28,11 +28,17 @@ class OfCatalyst(CMakePackage): version("develop", branch="develop") version("1806", tag="v1806", commit="d97babec3581bad413fd602e17fcd4bc1e312d26") + depends_on("cxx", type="build") # generated + variant("full", default=False, description="Build against paraview (full) or catalyst (light)") depends_on("openfoam@1806", when="@1806", type=("build", "link", "run")) depends_on("openfoam@develop", when="@develop", type=("build", "link", "run")) - depends_on("paraview@5.5:+osmesa~qt", when="+full") + + with when("+full"): + depends_on("paraview@5.5: ~qt") + depends_on("gl") + requires("^[virtuals=gl] osmesa") root_cmakelists_dir = "src/catalyst" diff --git a/var/spack/repos/builtin/packages/of-precice/package.py b/var/spack/repos/builtin/packages/of-precice/package.py index 6c47302e3aec38..ff7fd26827760d 100644 --- a/var/spack/repos/builtin/packages/of-precice/package.py +++ b/var/spack/repos/builtin/packages/of-precice/package.py @@ -30,6 +30,8 @@ class OfPrecice(Package): version("1.1.0", sha256="c35340b50d1b01978635130da94a876e1fa846c80b62e45204aa727db2ef4983") version("1.0.0", sha256="b70e5bdce47328f789f76dc6187604f8568b4a996158b5a6f6c11f111ff10308") + depends_on("cxx", type="build") # generated + depends_on("openfoam+source") depends_on("precice") depends_on("yaml-cpp") diff --git a/var/spack/repos/builtin/packages/ollama/package.py b/var/spack/repos/builtin/packages/ollama/package.py new file mode 100644 index 00000000000000..8213efdebc1c02 --- /dev/null +++ b/var/spack/repos/builtin/packages/ollama/package.py @@ -0,0 +1,57 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import spack.build_systems.go +from spack.package import * + + +class Ollama(GoPackage): + """Run Llama 2, Code Llama, and other models. Customize and create your own.""" + + homepage = "https://ollama.com" + git = "https://github.com/ollama/ollama.git" + + maintainers("teaguesterling") + + # We're using commit IDs because the `go generate` process will fail for some + # dependencies that expect to be within a git repo. This is also an issue with + # cached downloads, but I don't know how to fix that yet + version("0.1.31", commit="dc011d16b9ff160c0be3829fc39a43054f0315d0", submodules=True) + # This is the last verified non-preview version as of 20240413 + version( + "0.1.30", + commit="756c2575535641f1b96d94b4214941b90f4c30c7", + submodules=True, + preferred=True, + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + license("MIT", checked_by="teaguesterling") + + depends_on("cmake", type="build") + depends_on("go", type="build") + depends_on("gcc", type="build") + depends_on("git", type="build") + depends_on("ccache", type="build") + + +class GoBuilder(spack.build_systems.go.GoBuilder): + phases = ("generate", "build", "install") + + @property + def generate_args(self): + """Arguments for ``go generate``.""" + return ["./..."] + + def generate(self, pkg, spec, prefix): + """Runs ``go generate`` in the source directory""" + import inspect + + import llnl.util.filesystem as fs + + with fs.working_dir(self.build_directory): + inspect.getmodule(pkg).go("generate", *self.generate_args) diff --git a/var/spack/repos/builtin/packages/ome-common-cpp/package.py b/var/spack/repos/builtin/packages/ome-common-cpp/package.py index 7e4939d028adb8..a13957de5b9e07 100644 --- a/var/spack/repos/builtin/packages/ome-common-cpp/package.py +++ b/var/spack/repos/builtin/packages/ome-common-cpp/package.py @@ -25,6 +25,8 @@ class OmeCommonCpp(CMakePackage): version("master", branch="master") version("6.0.0", sha256="26f3ce6e0b9a022590eed2ade5519eca12a2507bb207cdfe9f29d360984a7e0d") + depends_on("cxx", type="build") # generated + depends_on("fmt") depends_on("spdlog") depends_on("xalan-c") diff --git a/var/spack/repos/builtin/packages/ome-files-cpp/package.py b/var/spack/repos/builtin/packages/ome-files-cpp/package.py index 96af69f7df1258..2edab104fd768c 100644 --- a/var/spack/repos/builtin/packages/ome-files-cpp/package.py +++ b/var/spack/repos/builtin/packages/ome-files-cpp/package.py @@ -24,6 +24,8 @@ class OmeFilesCpp(CMakePackage): version("master", branch="master") version("0.6.0", sha256="e0baf3eeb2ea639f426292a36b58adcaa42ce61a4a0f15f34690602f3f5d47c1") + depends_on("cxx", type="build") # generated + depends_on("boost@1.53: +filesystem +program_options") depends_on("ome-model") depends_on("ome-model@master", when="@master") diff --git a/var/spack/repos/builtin/packages/ome-model/package.py b/var/spack/repos/builtin/packages/ome-model/package.py index aa94521f266a66..93c58e086c8632 100644 --- a/var/spack/repos/builtin/packages/ome-model/package.py +++ b/var/spack/repos/builtin/packages/ome-model/package.py @@ -23,6 +23,8 @@ class OmeModel(CMakePackage): version("master", branch="master") version("6.0.0", sha256="d6644ff722411d3a8ac9f26a49c1afda30e4d4102e37b31593d2a9fdc8f96700") + depends_on("cxx", type="build") # generated + # Match version with ome-common-cpp. It would be nice to match versions in a # more automated way. depends_on("ome-common-cpp") diff --git a/var/spack/repos/builtin/packages/omega-h/package.py b/var/spack/repos/builtin/packages/omega-h/package.py index 25887e04910d5e..0209d3565f1f6e 100644 --- a/var/spack/repos/builtin/packages/omega-h/package.py +++ b/var/spack/repos/builtin/packages/omega-h/package.py @@ -47,6 +47,8 @@ class OmegaH(CMakePackage, CudaPackage): version("9.13.14", sha256="f617dfd024c9cc323e56800ca23df3386bfa37e1b9bd378847d1f5d32d2b8e5d") version("9.13.13", sha256="753702edf4bda9ae57ea21f09ca071e341604a468d8c86468c9aebba049f581c") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("mpi", default=True, description="Activates MPI support") variant("zlib", default=True, description="Activates ZLib support") @@ -158,23 +160,20 @@ def flag_handler(self, name, flags): return (None, None, flags) - def test(self): - if self.spec.version < Version("9.34.1"): - print("Skipping tests since only relevant for versions > 9.34.1") - return - - exe = join_path(self.prefix.bin, "osh_box") - options = ["1", "1", "1", "2", "2", "2", "box.osh"] - description = "testing mesh construction" - self.run_test(exe, options, purpose=description) - - exe = join_path(self.prefix.bin, "osh_scale") - options = ["box.osh", "100", "box_100.osh"] - expected = "adapting took" - description = "testing mesh adaptation" - self.run_test(exe, options, expected, purpose=description) - - exe = join_path(self.prefix.bin, "osh2vtk") - options = ["box_100.osh", "box_100_vtk"] - description = "testing mesh to vtu conversion" - self.run_test(exe, options, purpose=description) + def test_mesh(self): + """test construction, adaptation, and conversion of a mesh""" + if self.spec.satisfies("@:9.34.0"): + raise SkipTest("Package must be installed as version 9.34.1 or later") + + with test_part(self, "test_mesh_create", purpose="mesh construction"): + exe = which(self.prefix.bin.osh_box) + exe("1", "1", "1", "2", "2", "2", "box.osh") + + with test_part(self, "test_mesh_adapt", purpose="mesh adaptation"): + exe = which(self.prefix.bin.osh_scale) + actual = exe("box.osh", "100", "box_100.osh", output=str.split, error=str.split) + assert "adapting took" in actual + + with test_part(self, "test_mesh_convert", purpose="mesh to vtu conversion"): + exe = which(self.prefix.bin.osh2vtk) + exe("box_100.osh", "box_100_vtk") diff --git a/var/spack/repos/builtin/packages/omm-bundle/package.py b/var/spack/repos/builtin/packages/omm-bundle/package.py index e16209c0c92cf4..f42ce9a7bb3334 100644 --- a/var/spack/repos/builtin/packages/omm-bundle/package.py +++ b/var/spack/repos/builtin/packages/omm-bundle/package.py @@ -19,6 +19,8 @@ class OmmBundle(MakefilePackage): version("master", branch="master") version("1.0.0", tag="v1.0.0", commit="8b644267284695ff1a40b78d098bda6464a7b821") + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("blas") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/omm/package.py b/var/spack/repos/builtin/packages/omm/package.py new file mode 100644 index 00000000000000..c89b883f57765a --- /dev/null +++ b/var/spack/repos/builtin/packages/omm/package.py @@ -0,0 +1,60 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Omm(CMakePackage): + """Solution of Kohn-Sham equations using the Orbital Minimization Method (OMM).""" + + homepage = "https://gitlab.com/ElectronicStructureLibrary/omm/libomm" + url = "https://gitlab.com/ElectronicStructureLibrary/omm/libomm/-/archive/1.2.1/libomm-1.2.1.tar.gz" + git = "https://gitlab.com/ElectronicStructureLibrary/omm/libomm.git" + + maintainers("RMeli") + + license("BSD-2-Clause", checked_by="RMeli") + + version("1.2.1", sha256="4876990056efabdd83b0caad52ed56632d9926b61d73fe3efbd04d0f8d242ede") + version("master", branch="master") + + depends_on("fortran", type="build") # generated + + variant("lapack", default=True, description="Build libOMM with LAPACK interface.") + variant("mpi", default=True, description="Build libOMM with MPI support.") + variant( + "scalapack", + default=True, + when="+mpi", + description="Build libOMM with ScaLAPACK interface.", + ) + variant("dbcsr", default=False, when="+mpi", description="Build libOMM with DBCSR interface.") + + depends_on("cmake@3.22:", type="build") + generator("ninja") + + depends_on("lapack", when="+lapack") + depends_on("mpi", when="+mpi") + depends_on("scalapack", when="+scalapack") + depends_on("dbcsr~shared", when="+dbcsr") # Expects static library (FindCustomDbcsr) + + depends_on("matrix-switch") + depends_on("matrix-switch+lapack", when="+lapack") + depends_on("matrix-switch+mpi", when="+mpi") + depends_on("matrix-switch+scalapack", when="+scalapack") + depends_on("matrix-switch+dbcsr", when="+dbcsr") + + def cmake_args(self): + args = [ + self.define_from_variant("WITH_LAPACK", "lapack"), + self.define_from_variant("WITH_MPI", "mpi"), + self.define_from_variant("WITH_SCALAPACK", "scalapack"), + self.define_from_variant("WITH_DBCSR", "dbcsr"), + ] + + if self.spec.satisfies("+dbcsr"): + args.append(self.define("DBCSR_ROOT", self.spec["dbcsr"].prefix)) + + return args diff --git a/var/spack/repos/builtin/packages/omnitrace/package.py b/var/spack/repos/builtin/packages/omnitrace/package.py index bc3ed3175886a1..ba42a69c1495fe 100644 --- a/var/spack/repos/builtin/packages/omnitrace/package.py +++ b/var/spack/repos/builtin/packages/omnitrace/package.py @@ -30,6 +30,10 @@ class Omnitrace(CMakePackage): version("1.3.0", commit="4dd144a32c8b83c44e132ef53f2b44fe4b4d5569", submodules=True) version("1.2.0", commit="f82845388aab108ed1d1fc404f433a0def391bb3", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "rocm", default=True, @@ -141,7 +145,3 @@ def setup_build_environment(self, env): files = glob.glob(pattern) if files: env.set("TAU_MAKEFILE", files[0]) - - def setup_run_environment(self, env): - if "+python" in self.spec: - env.prepend_path("PYTHONPATH", join_path(self.prefix.lib, "python", "site-packages")) diff --git a/var/spack/repos/builtin/packages/ompss-2/package.py b/var/spack/repos/builtin/packages/ompss-2/package.py index 48ea331f9d4b2b..6ba60dd25bc172 100644 --- a/var/spack/repos/builtin/packages/ompss-2/package.py +++ b/var/spack/repos/builtin/packages/ompss-2/package.py @@ -24,6 +24,10 @@ class Ompss2(Package): version("2022.11", sha256="2df1a5c0f01523ebee49596ca0939b3edeae50e6bd76680cc8777d92583e5a1e") version("2021.11.1", sha256="9e0ee0c9f75cd558882465efc3d521c2fe93f1a6b50d4d9c8e614ab4eb3a9e6c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("extrae", default=False, description="Build with Extrae instrumentation support") depends_on("hwloc") diff --git a/var/spack/repos/builtin/packages/ompss/package.py b/var/spack/repos/builtin/packages/ompss/package.py index 67986430bb087e..428162c5890db1 100644 --- a/var/spack/repos/builtin/packages/ompss/package.py +++ b/var/spack/repos/builtin/packages/ompss/package.py @@ -27,6 +27,10 @@ class Ompss(Package): version("14.10", sha256="5b38d3e6ce108e7ca73a2599bc698d75ea9f6d90a3be0349faf6d61022e62a38") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # all dependencies are optional, really depends_on("mpi") # depends_on("openmp") diff --git a/var/spack/repos/builtin/packages/ompt-openmp/package.py b/var/spack/repos/builtin/packages/ompt-openmp/package.py index 5f67b63c6d73d5..4d452d103f4893 100644 --- a/var/spack/repos/builtin/packages/ompt-openmp/package.py +++ b/var/spack/repos/builtin/packages/ompt-openmp/package.py @@ -21,6 +21,10 @@ class OmptOpenmp(CMakePackage): version("0.1", sha256="a35dd2a83777fce54386d54cea8d2df9b5f34309d66fbc1d1757d55f6048c7a7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@2.8:", type="build") conflicts("%gcc@:4.7") diff --git a/var/spack/repos/builtin/packages/oneapi-level-zero/package.py b/var/spack/repos/builtin/packages/oneapi-level-zero/package.py index 120509dab362b8..97b67e065e3f8e 100644 --- a/var/spack/repos/builtin/packages/oneapi-level-zero/package.py +++ b/var/spack/repos/builtin/packages/oneapi-level-zero/package.py @@ -23,6 +23,26 @@ class OneapiLevelZero(CMakePackage): license("MIT") + version("1.17.2", sha256="f1b7414f468779a6c422d38bd06b2e5a59d861c9b1af826472724078b49b2277") + version("1.17.0", sha256="edf820eab84a5f746fee730604f0381c8811f7942302c0835226715e5ae93a25") + version("1.16.15", sha256="dba50f512c7da81c8d2c487f04c0fcf0ffff79a41f88a90658c96680e7c97be6") + version("1.16.14", sha256="afd1dfc4db6869a3e252bf15a2a6e1d59b4e511671ebc3e29becd4ac4dc4f03e") + version("1.16.11", sha256="885bc356d1ecb74e4d3406ece91503d998dd0b4ab484864c38fd41dac588afbb") + version("1.16.9", sha256="1d348370ba47a7047ae58805a7a33f219d78c8cbb1dd32a0b6c140be66f71d11") + version("1.16.1", sha256="f341dd6355d8da6ee9c29031642b8e8e4259f91c13c72d318c81663af048817e") + version("1.16.0", sha256="e5bf9caddeabf58b73252ada5390a78772001d91ec853ee12636811aeb66db41") + version("1.15.13", sha256="fadda7306dc05c279a9dfc0c60749846351ce5ac7186692201220acb02c59787") + version("1.15.8", sha256="80663dbd4d01d9519185c6e568f2e836bfea7484363f4da8cf5cf77c3bf58602") + version("1.15.7", sha256="3f82c83218cc047dc98a3b0767b874964d757b808d9954a2e8949edfcdddbf81") + version("1.15.1", sha256="aa96edb85a7953041baf8e7d0b0a0e10fa85673e52f5d0466bc2fc802beb9522") + version("1.15.0", sha256="0472f919435e72d93ef00239694c9380692f923fa1d3bf7e7ba79270cf78291c") + version("1.14.0", sha256="44b9cfa039625e4d9b273bebda26597a91d34c039ea22311530777ea386cfe6c") + version("1.13.5", sha256="bb0f37c40b1b2c1eb2c379928314539cac778d3accfc5de66d9f909a2f69fd32") + version("1.13.1", sha256="9c41640edd3738528911405ffe31c3caa9f9a747c43f6a7375a7b2e77eca3192") + version("1.13.0", sha256="8966e16f5152d14fed3b2d526d1a75eb99b8ef870499d8375c5d327345d09e48") + version("1.12.0", sha256="96e6f7ce0179833316f70582ebe4889619349cd4fb1a76efd49a71d8e8ac2e93") + version("1.11.0", sha256="eee9805bdf0973aff5858a32a8c3ac98e0337b64648d96bb8adeaecc0bdda5bd") + version("1.10.0", sha256="2811e4128ff6114020d0a147c2769b9b2e782e68ad49827685c33b9e716bf6ab") version("1.9.9", sha256="3d1784e790bbaae5f160b920c07e7dc2941640d9c631aaa668ccfd57aafc7b56") version("1.9.4", sha256="7f91ed993be1e643c752cf95a319a0fc64113d91ec481fbb8a2f478f433d3380") version("1.8.12", sha256="9c5d3dd912882abe8e2e3ba72f8c27e2a2d86759ac48f6318a0df091204985eb") @@ -40,3 +60,5 @@ class OneapiLevelZero(CMakePackage): version("1.3.7", sha256="e84c7f36316257eb46f74b41aef5c37fb593a8821497e45dfeda81aceba0abbc") version("1.3.6", sha256="c2b3bd6e4ee3cc874bdcc32bc8705bd217ffc46b194c77e27b23b8391c0c9704") version("1.2.3", sha256="69689429fcdaef74fa8395785aca65f5652e410bd6c56f47b2b64692c098892b") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/onednn/package.py b/var/spack/repos/builtin/packages/onednn/package.py index 40708d41e0270e..4d2d2ac2763bca 100644 --- a/var/spack/repos/builtin/packages/onednn/package.py +++ b/var/spack/repos/builtin/packages/onednn/package.py @@ -71,6 +71,9 @@ class Onednn(CMakePackage): version("0.10", sha256="e783d6d085e4dd930a990cf02a76401071f606c6f40e47eae4dc638b54146430") version("0.9", sha256="721ab6a14e05f9916645ebb410c3e97fae660d09a1c7df4da7958676504e572b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + default_cpu_runtime = "omp" if sys.platform == "darwin": default_cpu_runtime = "tbb" @@ -85,7 +88,6 @@ class Onednn(CMakePackage): "tbb", "seq", conditional("threadpool", when="@1.4:"), - conditional("dpcpp", when="@2:"), conditional("sycl", when="@2:"), ), multi=False, @@ -94,7 +96,7 @@ class Onednn(CMakePackage): "gpu_runtime", default="none", description="Runtime to use for GPU engines", - values=("ocl", "none", conditional("dpcpp", when="@2:"), conditional("sycl", when="@2:")), + values=("ocl", "none", conditional("sycl", when="@2:")), multi=False, ) variant( diff --git a/var/spack/repos/builtin/packages/oniguruma/package.py b/var/spack/repos/builtin/packages/oniguruma/package.py index de5be77f75f342..a7afee51cb7307 100644 --- a/var/spack/repos/builtin/packages/oniguruma/package.py +++ b/var/spack/repos/builtin/packages/oniguruma/package.py @@ -14,10 +14,13 @@ class Oniguruma(AutotoolsPackage): license("BSD-2-Clause") + version("6.9.9", sha256="60162bd3b9fc6f4886d4c7a07925ffd374167732f55dce8c491bfd9cd818a6cf") version("6.9.8", sha256="28cd62c1464623c7910565fb1ccaaa0104b2fe8b12bcd646e81f73b47535213e") version("6.9.4", sha256="4669d22ff7e0992a7e93e116161cac9c0949cd8960d1c562982026726f0e6d53") version("6.1.3", sha256="480c850cd7c7f2fcaad0942b4a488e2af01fbb8e65375d34908f558b432725cf") + depends_on("c", type="build") # generated + @property def libs(self): return find_libraries("libonig", root=self.prefix, recursive=True) diff --git a/var/spack/repos/builtin/packages/onnx/package.py b/var/spack/repos/builtin/packages/onnx/package.py index 5417e01127220a..3cc781463ee7e1 100644 --- a/var/spack/repos/builtin/packages/onnx/package.py +++ b/var/spack/repos/builtin/packages/onnx/package.py @@ -20,6 +20,11 @@ class Onnx(CMakePackage): license("Apache-2.0") version("master", branch="master") + version("1.16.1", sha256="0e6aa2c0a59bb2d90858ad0040ea1807117cc2f05b97702170f18e6cd6b66fb3") + version("1.16.0", sha256="0ce153e26ce2c00afca01c331a447d86fbf21b166b640551fe04258b4acfc6a4") + version("1.15.0", sha256="c757132e018dd0dd171499ef74fca88b74c5430a20781ec53da19eb7f937ef68") + version("1.14.1", sha256="e296f8867951fa6e71417a18f2e550a730550f8829bd35e947b4df5e3e777aa1") + version("1.14.0", sha256="1b02ad523f79d83f9678c749d5a3f63f0bcd0934550d5e0d7b895f9a29320003") version( "1.13.1", sha256="090d3e10ec662a98a2a72f1bf053f793efc645824f0d4b779e0ce47468a0890e" ) # py-torch@2: @@ -56,13 +61,15 @@ class Onnx(CMakePackage): "1.1.0_2018-04-19", commit="7e1bed51cc508a25b22130de459830b5d5063c41" ) # py-torch@0.4.0 + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@3.1:", type="build") depends_on("python", type="build") depends_on("protobuf") def patch(self): - if self.spec.satisfies("@1.13 ^protobuf@3.22:"): + if self.spec.satisfies("@1.13:1.14 ^protobuf@3.22:"): filter_file("CMAKE_CXX_STANDARD 11", "CMAKE_CXX_STANDARD 14", "CMakeLists.txt") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/oommf/package.py b/var/spack/repos/builtin/packages/oommf/package.py index fb181cba5ec88e..e339b417df7b2d 100644 --- a/var/spack/repos/builtin/packages/oommf/package.py +++ b/var/spack/repos/builtin/packages/oommf/package.py @@ -108,6 +108,9 @@ class Oommf(Package): url="https://github.com/fangohr/oommf/archive/refs/tags/1.2b0_20160930b1.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("tk", type=("build", "link", "test", "run")) depends_on("tcl", type=("build", "test", "run")) depends_on("xproto", type=("build")) diff --git a/var/spack/repos/builtin/packages/op2-dsl/package.py b/var/spack/repos/builtin/packages/op2-dsl/package.py index 18df2a38ebc75d..53618f814aaace 100644 --- a/var/spack/repos/builtin/packages/op2-dsl/package.py +++ b/var/spack/repos/builtin/packages/op2-dsl/package.py @@ -19,6 +19,10 @@ class Op2Dsl(MakefilePackage, CudaPackage): version("master", branch="master") version("1.1.0", tag="v1.1.0", commit="22c13b425976e32a6c904f3a5a95ffb761680eb3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + build_directory = "op2" variant("mpi", default=False, description="Enable MPI support") diff --git a/var/spack/repos/builtin/packages/opa-psm2/package.py b/var/spack/repos/builtin/packages/opa-psm2/package.py index 795eeb7e69feb4..aff8c73e6e3a5e 100644 --- a/var/spack/repos/builtin/packages/opa-psm2/package.py +++ b/var/spack/repos/builtin/packages/opa-psm2/package.py @@ -30,6 +30,8 @@ class OpaPsm2(MakefilePackage, CudaPackage): version("10.2-235", sha256="052031ab87abadc2c11971e6aa53be363b38d58a496a6e54a820ca5bcd6545a5") version("10.2-175", sha256="61b694191eca66e15e7ae1659bfacb10813e569d4e27182a88fb00b5661fb365") + depends_on("c", type="build") # generated + variant("avx2", default=True, description="Enable AVX2 instructions") depends_on("numactl") diff --git a/var/spack/repos/builtin/packages/opam/package.py b/var/spack/repos/builtin/packages/opam/package.py index d1b6bff3facc64..d9c170fc180ae2 100644 --- a/var/spack/repos/builtin/packages/opam/package.py +++ b/var/spack/repos/builtin/packages/opam/package.py @@ -29,6 +29,8 @@ class Opam(AutotoolsPackage): version("1.2.2", sha256="15e617179251041f4bf3910257bbb8398db987d863dd3cfc288bdd958de58f00") version("1.2.1", sha256="f210ece7a2def34b486c9ccfb75de8febd64487b2ea4a14a7fa0358f37eacc3b") + depends_on("c", type="build") # generated + # OCaml 4.10.0 has removed the -safe-string flag, which is necessary # for OPAM 1i (see docstring of setup_build_environment). depends_on("ocaml@:4.09.0", type="build", when="@:1.2.2") diff --git a/var/spack/repos/builtin/packages/opari2/package.py b/var/spack/repos/builtin/packages/opari2/package.py index ca08fa3ad856bc..5b000d5542d0e8 100644 --- a/var/spack/repos/builtin/packages/opari2/package.py +++ b/var/spack/repos/builtin/packages/opari2/package.py @@ -31,6 +31,10 @@ class Opari2(AutotoolsPackage): version("1.1.4", sha256="b80c04fe876faaa4ee9a0654486ecbeba516b27fc14a90d20c6384e81060cffe") version("1.1.2", sha256="8405c2903730d94c828724b3a5f8889653553fb8567045a6c54ac0816237835d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + def url_for_version(self, version): if version >= Version("2.0.6"): url = "https://perftools.pages.jsc.fz-juelich.de/cicd/opari2/tags/opari2-{0}/opari2-{0}.tar.gz" diff --git a/var/spack/repos/builtin/packages/opdilib/package.py b/var/spack/repos/builtin/packages/opdilib/package.py index baeb63c312bcf1..9aa5f14ec29f79 100644 --- a/var/spack/repos/builtin/packages/opdilib/package.py +++ b/var/spack/repos/builtin/packages/opdilib/package.py @@ -14,10 +14,13 @@ class Opdilib(Package): homepage = "https://github.com/SciCompKL/OpDiLib" url = "https://github.com/SciCompKL/OpDiLib/archive/refs/tags/v1.5.tar.gz" + version("1.5.1", sha256="58bbd4c7105e519b553bd0cbcf1c9797e6e9ca5ea445e4cc55cd32f216300781") version("1.5", sha256="47b345954df5e7ee8147e7b29db2ec160ba02ccc93b3b88af0b34bb880170248") version("1.4", sha256="f1dd2575a8c3b2328df89b732dbeaa23657731d77e4bf7ee201c6571f20d13d5") version("1.3.2", sha256="5da4a99ab1332e5c3746cb6d55ee4cd96ce578b06987e2b10e33ae6413b7cf7a") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(join_path(prefix, "include")) install_tree(join_path(self.stage.source_path, "include"), join_path(prefix, "include")) diff --git a/var/spack/repos/builtin/packages/open-iscsi/package.py b/var/spack/repos/builtin/packages/open-iscsi/package.py index fe0f354ab9ef64..9012dc92ae399b 100644 --- a/var/spack/repos/builtin/packages/open-iscsi/package.py +++ b/var/spack/repos/builtin/packages/open-iscsi/package.py @@ -21,6 +21,8 @@ class OpenIscsi(MakefilePackage): version("2.0.877", sha256="69eb95b0c39dee2da9d0d751bfdcdb8d11f9d37390de15c1a0b4558f9d0c4a57") version("2.0.876", sha256="9f01327d5e100ed794dc5083fc18dc4a06a0c29c77b252e21abd1b8f56edd9a7") + depends_on("c", type="build") # generated + depends_on("gettext") depends_on("uuid") depends_on("util-linux") diff --git a/var/spack/repos/builtin/packages/open-isns/package.py b/var/spack/repos/builtin/packages/open-isns/package.py index 38a97504193283..a389cf8ca9a552 100644 --- a/var/spack/repos/builtin/packages/open-isns/package.py +++ b/var/spack/repos/builtin/packages/open-isns/package.py @@ -21,6 +21,8 @@ class OpenIsns(AutotoolsPackage): version("0.97", sha256="c1c9ae740172e55a1ff33bc22151ec3d916562bf5d60c8420cd64496343683a9") version("0.96", sha256="487fd0d87826423ea99dc159826d0b654a5da016ed670d4395a77bfa4f62e2ec") + depends_on("c", type="build") # generated + def configure_args(self): args = ["--enable-shared"] return args diff --git a/var/spack/repos/builtin/packages/open3d/package.py b/var/spack/repos/builtin/packages/open3d/package.py index 2a63de25caed6d..cd77d5290e721e 100644 --- a/var/spack/repos/builtin/packages/open3d/package.py +++ b/var/spack/repos/builtin/packages/open3d/package.py @@ -21,6 +21,10 @@ class Open3d(CMakePackage, CudaPackage): "0.13.0", tag="v0.13.0", commit="c3f9de224e13838a72da0e5565a7ba51038b0f11", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("python", default=False, description="Build the Python module") # http://www.open3d.org/docs/latest/compilation.html @@ -116,10 +120,10 @@ def install(self, spec, prefix): @run_after("install") @on_package_attributes(run_tests=True) - def test(self): + def check_import(self): if "+python" in self.spec: self.run_test( - self.spec["python"].command.path, + python.path, ["-c", "import open3d"], purpose="checking import of open3d", work_dir="spack-test", diff --git a/var/spack/repos/builtin/packages/openal-soft/package.py b/var/spack/repos/builtin/packages/openal-soft/package.py index 51d62c2c6ea0fe..6e835e03955223 100644 --- a/var/spack/repos/builtin/packages/openal-soft/package.py +++ b/var/spack/repos/builtin/packages/openal-soft/package.py @@ -21,6 +21,9 @@ class OpenalSoft(CMakePackage): version("1.23.0", sha256="057dcf96c3cdfcf40159800a93f57740fe79c2956f76247bee10e436b6657183") version("1.21.1", sha256="c8ad767e9a3230df66756a21cc8ebf218a9d47288f2514014832204e666af5d8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("alsa", default=False, description="ALSA support") depends_on("alsa-lib", when="+alsa") diff --git a/var/spack/repos/builtin/packages/openbabel/cmake-time.patch b/var/spack/repos/builtin/packages/openbabel/cmake-time.patch new file mode 100644 index 00000000000000..bc55894ff637b5 --- /dev/null +++ b/var/spack/repos/builtin/packages/openbabel/cmake-time.patch @@ -0,0 +1,15 @@ +diff --git a/src/config.h.cmake b/src/config.h.cmake +index 1c59c6769..26e5dde94 100644 +--- a/src/config.h.cmake ++++ b/src/config.h.cmake +@@ -182,8 +182,8 @@ + #define OB_MODULE_PATH "@OB_MODULE_PATH@" + + #ifndef TIME_WITH_SYS_TIME +- #ifdef HAVE_SYS_TIME +- #ifdef HAVE_TIME ++ #ifdef HAVE_SYS_TIME_H ++ #ifdef HAVE_TIME_H + #define TIME_WITH_SYS_TIME 1 + #else + #define TIME_WITH_SYS_TIME 0 diff --git a/var/spack/repos/builtin/packages/openbabel/package.py b/var/spack/repos/builtin/packages/openbabel/package.py index 65cff9e35c485d..d7314e2714a9a4 100644 --- a/var/spack/repos/builtin/packages/openbabel/package.py +++ b/var/spack/repos/builtin/packages/openbabel/package.py @@ -25,6 +25,9 @@ class Openbabel(CMakePackage): version("2.4.1", tag="openbabel-2-4-1", commit="701f6049c483b1349118c2ff736a7f609a84dedd") version("2.4.0", tag="openbabel-2-4-0", commit="087f33320e6796f39e6a1da04f4de7ec46bec4af") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("python", default=True, description="Build Python bindings") variant("gui", default=True, description="Build with GUI") variant("cairo", default=True, description="Build with Cairo (PNG output support)") @@ -58,6 +61,9 @@ class Openbabel(CMakePackage): # Convert tabs to spaces. Allows unit tests to pass patch("testpdbformat-tabs-to-spaces.patch", when="@:2.4.1") + # https://github.com/openbabel/openbabel/pull/2493 + patch("cmake-time.patch", when="@3.1.1") + def cmake_args(self): spec = self.spec args = [] diff --git a/var/spack/repos/builtin/packages/openblas/package.py b/var/spack/repos/builtin/packages/openblas/package.py index 5e1a6f2b8e40c1..74961d16aaee93 100644 --- a/var/spack/repos/builtin/packages/openblas/package.py +++ b/var/spack/repos/builtin/packages/openblas/package.py @@ -26,6 +26,7 @@ class Openblas(CMakePackage, MakefilePackage): license("BSD-3-Clause") version("develop", branch="develop") + version("0.3.27", sha256="aa2d68b1564fe2b13bc292672608e9cdeeeb6dc34995512e65c3b10f4599e897") version("0.3.26", sha256="4e6e4f5cb14c209262e33e6816d70221a2fe49eb69eaf0a06f065598ac602c68") version("0.3.25", sha256="4c25cb30c4bb23eddca05d7d0a85997b8db6144f5464ba7f8c09ce91e2f35543") version("0.3.24", sha256="ceadc5065da97bd92404cac7254da66cc6eb192679cf1002098688978d4d5132") @@ -60,6 +61,10 @@ class Openblas(CMakePackage, MakefilePackage): version("0.2.16", sha256="766f350d0a4be614812d535cead8c816fc3ad3b9afcd93167ea5e4df9d61869b") version("0.2.15", sha256="73c40ace5978282224e5e122a41c8388c5a19e65a6f2329c2b7c0b61bacc9044") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "fortran", default=True, @@ -70,6 +75,11 @@ class Openblas(CMakePackage, MakefilePackage): variant("ilp64", default=False, description="Force 64-bit Fortran native integers") variant("pic", default=True, description="Build position independent code") variant("shared", default=True, description="Build shared libraries") + variant( + "dynamic_dispatch", + default=True, + description="Enable runtime cpu detection for best kernel selection", + ) variant( "consistent_fpcsr", default=False, @@ -216,6 +226,13 @@ class Openblas(CMakePackage, MakefilePackage): when="@0.3.24 target=a64fx", ) + # Disable -fp-model=fast default on OneAPI (https://github.com/OpenMathLib/OpenBLAS/issues/4713) + patch( + "https://github.com/OpenMathLib/OpenBLAS/commit/834e633d796ba94ecb892acb32b6cdcee4e3771d.patch?full_index=1", + sha256="3e165d8cba4023cb2082b241eee41287dd6cbb66078c5e3cb5d246081b361ff3", + when="@0.3.27 %oneapi", + ) + # See https://github.com/spack/spack/issues/19932#issuecomment-733452619 # Notice: fixed on Amazon Linux GCC 7.3.1 (which is an unofficial version # as GCC only has major.minor releases. But the bound :7.3.0 doesn't hurt) @@ -226,6 +243,7 @@ class Openblas(CMakePackage, MakefilePackage): # See https://github.com/spack/spack/issues/3036 conflicts("%intel@16", when="@0.2.15:0.2.19") + conflicts( "+consistent_fpcsr", when="threads=none", @@ -239,6 +257,12 @@ class Openblas(CMakePackage, MakefilePackage): when="%clang", msg="OpenBLAS @:0.2.19 does not support OpenMP with clang!", ) + # See https://github.com/OpenMathLib/OpenBLAS/issues/2826#issuecomment-688399162 + conflicts( + "+dynamic_dispatch", + when="platform=windows", + msg="Visual Studio does not support OpenBLAS dynamic dispatch features", + ) depends_on("perl", type="build") @@ -453,6 +477,9 @@ def make_defs(self): # Add target and architecture flags make_defs += self._microarch_target_args() + if self.spec.satisfies("+dynamic_dispatch"): + make_defs += ["DYNAMIC_ARCH=1"] + # Fortran-free compilation if "~fortran" in self.spec: make_defs += ["NOFORTRAN=1"] @@ -562,6 +589,8 @@ def check_install(self): class CMakeBuilder(spack.build_systems.cmake.CMakeBuilder): def cmake_args(self): cmake_defs = [self.define("TARGET", "GENERIC")] + if self.spec.satisfies("+dynamic_dispatch"): + cmake_defs += [self.define("DYNAMIC_ARCH", "ON")] if self.spec.satisfies("platform=windows"): cmake_defs += [ self.define("DYNAMIC_ARCH", "OFF"), diff --git a/var/spack/repos/builtin/packages/opencarp/package.py b/var/spack/repos/builtin/packages/opencarp/package.py index c6926bf064a19f..0316cc288cbcb5 100644 --- a/var/spack/repos/builtin/packages/opencarp/package.py +++ b/var/spack/repos/builtin/packages/opencarp/package.py @@ -19,12 +19,15 @@ class Opencarp(CMakePackage): maintainers("MarieHouillon") version( - "13.0", - commit="e1e0deca7eddcfd210835f54430361c85a97a5a4", + "15.0", + commit="2271a3cccd7137f1e28c043c10adbd80480f1462", submodules=False, no_cache=True, preferred=True, ) + version( + "13.0", commit="e1e0deca7eddcfd210835f54430361c85a97a5a4", submodules=False, no_cache=True + ) version( "12.0", commit="a34c11af3e8c2afd6e123e586a446c6993e0b039", submodules=False, no_cache=True ) @@ -48,6 +51,9 @@ class Opencarp(CMakePackage): ) version("master", branch="master", submodules=False, no_cache=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("carputils", default=False, description="Installs the carputils framework") variant("meshtool", default=False, description="Installs the meshtool software") @@ -66,7 +72,7 @@ class Opencarp(CMakePackage): depends_on("py-carputils", when="+carputils", type=("build", "run")) depends_on("meshtool", when="+meshtool", type=("build", "run")) # Use specific versions of carputils and meshtool for releases - for ver in ["13.0", "12.0", "11.0", "10.0", "9.0", "8.2", "7.0", "8.1"]: + for ver in ["15.0", "13.0", "12.0", "11.0", "10.0", "9.0", "8.2", "8.1", "7.0"]: depends_on("py-carputils@oc" + ver, when="@" + ver + " +carputils") depends_on("meshtool@oc" + ver, when="@" + ver + " +meshtool") diff --git a/var/spack/repos/builtin/packages/opencascade/package.py b/var/spack/repos/builtin/packages/opencascade/package.py index 4c07bb5a7d1e84..b223ecad491b98 100644 --- a/var/spack/repos/builtin/packages/opencascade/package.py +++ b/var/spack/repos/builtin/packages/opencascade/package.py @@ -89,6 +89,9 @@ class Opencascade(CMakePackage): sha256="655da7717dac3460a22a6a7ee68860c1da56da2fec9c380d8ac0ac0349d67676", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # fix for numeric_limits in gcc-12; applies cleanly to all older versions patch( "https://git.dev.opencascade.org/gitweb/?p=occt.git;a=patch;h=2a8c5ad46cfef8114b13c3a33dcd88a81e522c1e", diff --git a/var/spack/repos/builtin/packages/opencl-c-headers/package.py b/var/spack/repos/builtin/packages/opencl-c-headers/package.py index 2249897e8ddf8d..afba470d0f2794 100644 --- a/var/spack/repos/builtin/packages/opencl-c-headers/package.py +++ b/var/spack/repos/builtin/packages/opencl-c-headers/package.py @@ -16,6 +16,9 @@ class OpenclCHeaders(CMakePackage): license("Apache-2.0") + version( + "2024.05.08", sha256="3c3dd236d35f4960028f4f58ce8d963fb63f3d50251d1e9854b76f1caab9a309" + ) version( "2023.12.14", sha256="407d5e109a70ec1b6cd3380ce357c21e3d3651a91caae6d0d8e1719c69a1791d" ) @@ -53,6 +56,8 @@ class OpenclCHeaders(CMakePackage): "2020.03.13", sha256="664bbe587e5a0a00aac267f645b7c413586e7bc56dca9ff3b00037050d06f476" ) + depends_on("c", type="build") # generated + def cmake_args(self): # Disable testing the headers. They definitely work. return ["-DBUILD_TESTING=OFF"] diff --git a/var/spack/repos/builtin/packages/opencl-clhpp/package.py b/var/spack/repos/builtin/packages/opencl-clhpp/package.py index 84e3b8dad4968f..c580b966775af4 100644 --- a/var/spack/repos/builtin/packages/opencl-clhpp/package.py +++ b/var/spack/repos/builtin/packages/opencl-clhpp/package.py @@ -27,6 +27,8 @@ class OpenclClhpp(CMakePackage): version("2.0.10", sha256="fa27456295c3fa534ce824eb0314190a8b3ebd3ba4d93a0b1270fc65bf378f2b") version("2.0.9", sha256="ba8ac4977650d833804f208a1b0c198006c65c5eac7c83b25dc32cea6199f58c") + depends_on("cxx", type="build") # generated + root_cmakelists_dir = "include" @run_after("install") diff --git a/var/spack/repos/builtin/packages/opencl-icd-loader/package.py b/var/spack/repos/builtin/packages/opencl-icd-loader/package.py new file mode 100644 index 00000000000000..368eb1aa336927 --- /dev/null +++ b/var/spack/repos/builtin/packages/opencl-icd-loader/package.py @@ -0,0 +1,68 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class OpenclIcdLoader(CMakePackage): + """Khronos official OpenCL ICD Loader""" + + homepage = "https://github.com/KhronosGroup/OpenCL-ICD-Loader" + url = "https://github.com/KhronosGroup/OpenCL-ICD-Loader/archive/refs/tags/v2024.05.08.tar.gz" + + maintainers("uphoffc") + + license("Apache-2.0", checked_by="uphoffc") + + version( + "2024.05.08", sha256="eb2c9fde125ffc58f418d62ad83131ba686cccedcb390cc7e6bb81cc5ef2bd4f" + ) + version( + "2023.12.14", sha256="af8df96f1e1030329e8d4892ba3aa761b923838d4c689ef52d97822ab0bd8917" + ) + version( + "2023.04.17", sha256="173bdc4f321d550b6578ad2aafc2832f25fbb36041f095e6221025f74134b876" + ) + version( + "2023.02.06", sha256="f31a932b470c1e115d6a858b25c437172809b939953dc1cf20a3a15e8785d698" + ) + version( + "2022.09.30", sha256="e9522fb736627dd4feae2a9c467a864e7d25bb715f808de8a04eea5a7d394b74" + ) + version( + "2022.09.23", sha256="937bbdb52819922e0e38ae765e3c3d76b63be185d62f25e256ea3f77fdaa9913" + ) + version( + "2022.05.18", sha256="71f70bba797a501b13b6b0905dc852f3fd6e264d74ce294f2df98d29914c4303" + ) + version( + "2022.01.04", sha256="9f21d958af68c1b625a03c2befddd79da95d610614ddab6c291f26f01a947dd8" + ) + version( + "2021.06.30", sha256="a50557ed6ff18c81aa1ed5e74700521e389c84ca5cd9188d35d368936e0a4972" + ) + version( + "2021.04.29", sha256="c2eb8a15b3d6d0795d609f55a4cea92eaa34571f6a21428d5593673b568ac6fd" + ) + + depends_on("c", type="build") # generated + + depends_on("opencl-c-headers@2024.05.08", when="@2024.05.08") + depends_on("opencl-c-headers@2023.12.14", when="@2023.12.14") + depends_on("opencl-c-headers@2023.04.17", when="@2023.04.17") + depends_on("opencl-c-headers@2023.02.06", when="@2023.02.06") + depends_on("opencl-c-headers@2022.09.30", when="@2022.09.30") + depends_on("opencl-c-headers@2022.09.23", when="@2022.09.23") + depends_on("opencl-c-headers@2022.05.18", when="@2022.05.18") + depends_on("opencl-c-headers@2022.01.04", when="@2022.01.04") + depends_on("opencl-c-headers@2021.06.30", when="@2021.06.30") + depends_on("opencl-c-headers@2021.04.29", when="@2021.04.29") + + provides("opencl@:3.0") + + def cmake_args(self): + headers_include_dir = self.spec["opencl-c-headers"].prefix.include + args = [self.define("OPENCL_ICD_LOADER_HEADERS_DIR", headers_include_dir)] + return args diff --git a/var/spack/repos/builtin/packages/opencoarrays/package.py b/var/spack/repos/builtin/packages/opencoarrays/package.py index 7d5a668c07c31a..9c5922f47b1c98 100644 --- a/var/spack/repos/builtin/packages/opencoarrays/package.py +++ b/var/spack/repos/builtin/packages/opencoarrays/package.py @@ -31,6 +31,9 @@ class Opencoarrays(CMakePackage): version("1.7.4", sha256="1929dee793ce8f09e3b183e2b07c3e0008580cc76b460b1f7f7c066ad6672e14") version("1.6.2", sha256="7855d42a01babc233a070cc87282b5f8ffd538a7c87ec5119605d4d7c6d7f67e") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "build_type", default="RelWithDebInfo", diff --git a/var/spack/repos/builtin/packages/opencv/package.py b/var/spack/repos/builtin/packages/opencv/package.py index 8e3f3236bb7b66..a5985861b6c2bd 100644 --- a/var/spack/repos/builtin/packages/opencv/package.py +++ b/var/spack/repos/builtin/packages/opencv/package.py @@ -46,6 +46,9 @@ class Opencv(CMakePackage, CudaPackage): version("3.3.1", sha256="5dca3bb0d661af311e25a72b04a7e4c22c47c1aa86eb73e70063cd378a2aa6ee") version("3.3.0", sha256="8bb312b9d9fd17336dc1f8b3ac82f021ca50e2034afc866098866176d985adc6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + contrib_vers = [ "3.3.0", "3.3.1", @@ -251,6 +254,8 @@ class Opencv(CMakePackage, CudaPackage): depends_on("python@3.2:", type=("build", "link", "run")) depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) + # https://github.com/opencv/opencv-python/issues/943 + depends_on("py-numpy@:1", when="@:4.10.0.83", type=("build", "run")) extends("python", when="+python3") with when("+stitching"): @@ -781,41 +786,31 @@ class Opencv(CMakePackage, CudaPackage): # using `OCV_OPTION(WITH_* ...)` conflicts("+android_mediandk", when="platform=darwin", msg="Android only") conflicts("+android_mediandk", when="platform=linux", msg="Android only") - conflicts("+android_mediandk", when="platform=cray", msg="Android only") conflicts("+android_native_camera", when="platform=darwin", msg="Android only") conflicts("+android_native_camera", when="platform=linux", msg="Android only") - conflicts("+android_native_camera", when="platform=cray", msg="Android only") conflicts("+avfoundation", when="platform=linux", msg="iOS/macOS only") - conflicts("+avfoundation", when="platform=cray", msg="iOS/macOS only") conflicts("+cap_ios", when="platform=darwin", msg="iOS only") conflicts("+cap_ios", when="platform=linux", msg="iOS only") - conflicts("+cap_ios", when="platform=cray", msg="iOS only") conflicts("+carotene", when="target=x86:", msg="ARM/AARCH64 only") conflicts("+carotene", when="target=x86_64:", msg="ARM/AARCH64 only") conflicts("+cpufeatures", when="platform=darwin", msg="Android only") conflicts("+cpufeatures", when="platform=linux", msg="Android only") - conflicts("+cpufeatures", when="platform=cray", msg="Android only") conflicts("+cublas", when="~cuda") conflicts("+cudnn", when="~cuda") conflicts("+cufft", when="~cuda") conflicts("+directx", when="platform=darwin", msg="Windows only") conflicts("+directx", when="platform=linux", msg="Windows only") - conflicts("+directx", when="platform=cray", msg="Windows only") conflicts("+dshow", when="platform=darwin", msg="Windows only") conflicts("+dshow", when="platform=linux", msg="Windows only") - conflicts("+dshow", when="platform=cray", msg="Windows only") conflicts("+gtk", when="platform=darwin", msg="Linux only") conflicts("+ipp", when="target=aarch64:", msg="x86 or x86_64 only") conflicts("+jasper", when="+openjpeg") conflicts("+msmf", when="platform=darwin", msg="Windows only") conflicts("+msmf", when="platform=linux", msg="Windows only") - conflicts("+msmf", when="platform=cray", msg="Windows only") conflicts("+msmf_dxva", when="platform=darwin", msg="Windows only") conflicts("+msmf_dxva", when="platform=linux", msg="Windows only") - conflicts("+msmf_dxva", when="platform=cray", msg="Windows only") conflicts("+opencl_d3d11_nv", when="platform=darwin", msg="Windows only") conflicts("+opencl_d3d11_nv", when="platform=linux", msg="Windows only") - conflicts("+opencl_d3d11_nv", when="platform=cray", msg="Windows only") conflicts("+opengl", when="~qt") conflicts("+tengine", when="platform=darwin", msg="Linux only") conflicts("+tengine", when="target=x86:", msg="ARM/AARCH64 only") @@ -823,7 +818,6 @@ class Opencv(CMakePackage, CudaPackage): conflicts("+v4l", when="platform=darwin", msg="Linux only") conflicts("+win32ui", when="platform=darwin", msg="Windows only") conflicts("+win32ui", when="platform=linux", msg="Windows only") - conflicts("+win32ui", when="platform=cray", msg="Windows only") # https://github.com/opencv/opencv/wiki/ChangeLog#version460 conflicts("%gcc@12:", when="@:4.5") @@ -1027,14 +1021,13 @@ def cmake_args(self): ) # Python - python_exe = spec["python"].command.path python_lib = spec["python"].libs[0] python_include_dir = spec["python"].headers.directories[0] if "+python3" in spec: args.extend( [ - self.define("PYTHON3_EXECUTABLE", python_exe), + self.define("PYTHON3_EXECUTABLE", python.path), self.define("PYTHON3_LIBRARY", python_lib), self.define("PYTHON3_INCLUDE_DIR", python_include_dir), self.define("PYTHON2_EXECUTABLE", ""), diff --git a/var/spack/repos/builtin/packages/opendatadetector/package.py b/var/spack/repos/builtin/packages/opendatadetector/package.py index 345c0c90e0dd41..a2be138b5734d6 100644 --- a/var/spack/repos/builtin/packages/opendatadetector/package.py +++ b/var/spack/repos/builtin/packages/opendatadetector/package.py @@ -24,6 +24,8 @@ class Opendatadetector(CMakePackage): version("v2", tag="v2", commit="7041ae086dff4ee4a8d5b65f5d9559acc6dbec47") version("v1", tag="v1", commit="81c43c6511723c13c15327479082d3dcfa1947c7") + depends_on("cxx", type="build") # generated + depends_on("dd4hep") depends_on("root") depends_on("boost") diff --git a/var/spack/repos/builtin/packages/opendx/package.py b/var/spack/repos/builtin/packages/opendx/package.py index 27a7052f30ae2e..0a92677f77f3d4 100644 --- a/var/spack/repos/builtin/packages/opendx/package.py +++ b/var/spack/repos/builtin/packages/opendx/package.py @@ -15,6 +15,9 @@ class Opendx(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("motif") # lesstif also works, but exhibits odd behaviors depends_on("gl") diff --git a/var/spack/repos/builtin/packages/openexr/package.py b/var/spack/repos/builtin/packages/openexr/package.py index ce2bf16b5966aa..f901aef212bb59 100644 --- a/var/spack/repos/builtin/packages/openexr/package.py +++ b/var/spack/repos/builtin/packages/openexr/package.py @@ -70,6 +70,9 @@ class Openexr(CMakePackage, AutotoolsPackage): url="http://download.savannah.nongnu.org/releases/openexr/openexr-1.3.2.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("imath", when="@3:") depends_on("ilmbase", when="@:2") diff --git a/var/spack/repos/builtin/packages/openfast/hub_seg_fault.patch b/var/spack/repos/builtin/packages/openfast/hub_seg_fault.patch new file mode 100644 index 00000000000000..a312f04b8d5c6e --- /dev/null +++ b/var/spack/repos/builtin/packages/openfast/hub_seg_fault.patch @@ -0,0 +1,17 @@ +diff --git a/modules/openfast-library/src/FAST_Solver.f90 b/modules/openfast-library/src/FAST_Solver.f90 +index 364d0b78..10056965 100644 +--- a/modules/openfast-library/src/FAST_Solver.f90 ++++ b/modules/openfast-library/src/FAST_Solver.f90 +@@ -607,9 +607,9 @@ SUBROUTINE AD_InputSolve_IfW( p_FAST, u_AD, y_IfW, y_OpFM, ErrStat, ErrMsg ) + end if + + if (u_AD%rotors(1)%NacelleMotion%NNodes > 0) then +- u_AD%rotors(1)%InflowOnNacelle(1) = y_OpFM%u(node) +- u_AD%rotors(1)%InflowOnNacelle(2) = y_OpFM%v(node) +- u_AD%rotors(1)%InflowOnNacelle(3) = y_OpFM%w(node) ++ u_AD%rotors(1)%InflowOnNacelle(1) = y_OpFM%u(1) ++ u_AD%rotors(1)%InflowOnNacelle(2) = y_OpFM%v(1) ++ u_AD%rotors(1)%InflowOnNacelle(3) = y_OpFM%w(1) + node = node + 1 + else + u_AD%rotors(1)%InflowOnNacelle = 0.0_ReKi diff --git a/var/spack/repos/builtin/packages/openfast/package.py b/var/spack/repos/builtin/packages/openfast/package.py index d00f560c604105..fbe3e8bd47463a 100644 --- a/var/spack/repos/builtin/packages/openfast/package.py +++ b/var/spack/repos/builtin/packages/openfast/package.py @@ -18,6 +18,7 @@ class Openfast(CMakePackage): version("develop", branch="dev") version("master", branch="main") + version("3.5.3", tag="v3.5.3", commit="6a7a543790f3cad4a65b87242a619ac5b34b4c0f") version("3.4.1", tag="v3.4.1", commit="18704086dad861ab13daf804825da7c4b8d59428") version("3.4.0", tag="v3.4.0", commit="e8ec53f9c7f9d3f6a13bfb61dba12a0ca04d8a2f") version("3.3.0", tag="v3.3.0", commit="5f3fb6ef74f48e75ca94000090737a41866fb264") @@ -34,6 +35,12 @@ class Openfast(CMakePackage): version("2.0.0", tag="v2.0.0", commit="0769598a17e19b3ccd00a85cde389995f55024a8") version("1.0.0", tag="v1.0.0", commit="e788b9b18bd5ed96ea59d4bc0812d461bc430cfe") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + patch("hub_seg_fault.patch", when="@2.7:3.2") + variant("shared", default=True, description="Build shared libraries") variant("double-precision", default=True, description="Treat REAL as double precision") variant("dll-interface", default=True, description="Enable dynamic library loading interface") @@ -41,18 +48,19 @@ class Openfast(CMakePackage): variant("pic", default=True, description="Position independent code") variant("openmp", default=False, description="Enable OpenMP support") variant("netcdf", default=False, description="Enable NetCDF support") + variant("rosco", default=False, description="Build ROSCO controller") - # Dependencies for OpenFAST Fortran depends_on("blas") depends_on("lapack") - - # Additional dependencies when compiling C++ library depends_on("mpi", when="+cxx") - depends_on("yaml-cpp", when="+cxx") + depends_on("yaml-cpp@0.6.0:0.6.3", when="+cxx") depends_on("hdf5+mpi+cxx+hl", when="+cxx") depends_on("zlib-api", when="+cxx") depends_on("libxml2", when="+cxx") depends_on("netcdf-c", when="+cxx+netcdf") + depends_on("rosco", when="+rosco") + + conflicts("~cxx", when="+netcdf") def cmake_args(self): spec = self.spec diff --git a/var/spack/repos/builtin/packages/openfoam-org/package.py b/var/spack/repos/builtin/packages/openfoam-org/package.py index 44408134bf727e..78140182e7859b 100644 --- a/var/spack/repos/builtin/packages/openfoam-org/package.py +++ b/var/spack/repos/builtin/packages/openfoam-org/package.py @@ -84,6 +84,9 @@ class OpenfoamOrg(Package): url="http://downloads.sourceforge.net/foam/OpenFOAM-2.3.1.tgz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("int64", default=False, description="Compile with 64-bit label") variant( "source", default=True, description="Install library/application sources and tutorials" diff --git a/var/spack/repos/builtin/packages/openfoam/package.py b/var/spack/repos/builtin/packages/openfoam/package.py index 0919b9abd6f617..d3de3823f62092 100644 --- a/var/spack/repos/builtin/packages/openfoam/package.py +++ b/var/spack/repos/builtin/packages/openfoam/package.py @@ -333,6 +333,9 @@ class Openfoam(Package): version("1706", sha256="7779048bb53798d9a5bd2b2be0bf302c5fd3dff98e29249d6e0ef7eeb83db79a") version("1612", sha256="2909c43506a68e1f23efd0ca6186a6948ae0fc8fe1e39c78cc23ef0d69f3569d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("int64", default=False, description="With 64-bit labels") variant("knl", default=False, description="Use KNL compiler settings") variant("kahip", default=False, description="With kahip decomposition") @@ -369,8 +372,12 @@ class Openfoam(Package): # See https://github.com/spack/spack/pull/22303 for reference depends_on(Boost.with_default_variants) - # OpenFOAM does not play nice with CGAL 5.X - depends_on("cgal@:4") + # Earlier versions of OpenFOAM may not work with CGAL 5.6. I do + # not know which OpenFOAM added support for 5.x and conservatively + # use 2312 in the check. + depends_on("cgal", when="@2312:") + depends_on("cgal@:4", when="@:2306") + # The flex restriction is ONLY to deal with a spec resolution clash # introduced by the restriction within scotch! depends_on("flex@:2.6.1,2.6.4:") diff --git a/var/spack/repos/builtin/packages/openfst/package.py b/var/spack/repos/builtin/packages/openfst/package.py index ec4271a0cfce0d..03dcd04925aada 100644 --- a/var/spack/repos/builtin/packages/openfst/package.py +++ b/var/spack/repos/builtin/packages/openfst/package.py @@ -38,6 +38,8 @@ class Openfst(AutotoolsPackage): version("1.4.1", sha256="e671bf6bd4425a1fed4e7543a024201b74869bfdd029bdf9d10c53a3c2818277") version("1.4.0", sha256="eb557f37560438f03912b4e43335c4c9e72aa486d4f2046127131185eb88f17a") + depends_on("cxx", type="build") # generated + conflicts("%intel@16:") conflicts("%gcc@6:", when="@:1.6.1") diff --git a/var/spack/repos/builtin/packages/opengl/package.py b/var/spack/repos/builtin/packages/opengl/package.py index 280b8efc63b472..7d16073ed4af1f 100644 --- a/var/spack/repos/builtin/packages/opengl/package.py +++ b/var/spack/repos/builtin/packages/opengl/package.py @@ -106,6 +106,6 @@ def gl_libs(self): lib_name = "opengl32" elif "platform=darwin" in spec: lib_name = "libOpenGL" - else: # linux and cray + else: lib_name = "libGL" return find_libraries(lib_name, root=self.prefix, recursive=True) diff --git a/var/spack/repos/builtin/packages/openimagedenoise/package.py b/var/spack/repos/builtin/packages/openimagedenoise/package.py index 17354667cf4ff2..57ac527e9ca616 100644 --- a/var/spack/repos/builtin/packages/openimagedenoise/package.py +++ b/var/spack/repos/builtin/packages/openimagedenoise/package.py @@ -15,10 +15,9 @@ class Openimagedenoise(CMakePackage): homepage = "https://www.openimagedenoise.org/" url = "https://github.com/OpenImageDenoise/oidn/releases/download/v1.4.3/oidn-1.4.3.src.tar.gz" - # maintainers("github_user1", "github_user2") - license("Apache-2.0") + version("2.2.2", sha256="d26b75fa216165086f65bf48c80648290f2cfed7d3c4bfc1e86c247b46c96b7e") version("2.1.0", sha256="ce144ba582ff36563d9442ee07fa2a4d249bc85aa93e5b25fc527ff4ee755ed6") version("2.0.1", sha256="328eeb9809d18e835dca7203224af3748578794784c026940c02eea09c695b90") version("1.4.3", sha256="3276e252297ebad67a999298d8f0c30cfb221e166b166ae5c955d88b94ad062a") @@ -29,6 +28,9 @@ class Openimagedenoise(CMakePackage): version("1.2.4", sha256="948b070c780b5de0d983e7d5d37f6d9454932cc278913d9ee5b0bd047d23864a") version("1.2.3", sha256="469d20b093a73b18a54a2e559b0f18a6baac845ede864be62429737042ebe4f7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("ispc", type=("build")) depends_on("python@3:", type=("build", "test")) depends_on("tbb") diff --git a/var/spack/repos/builtin/packages/openimageio/package.py b/var/spack/repos/builtin/packages/openimageio/package.py index f2f2169e5b89fc..1733210fc1ad76 100644 --- a/var/spack/repos/builtin/packages/openimageio/package.py +++ b/var/spack/repos/builtin/packages/openimageio/package.py @@ -19,6 +19,8 @@ class Openimageio(CMakePackage): version("2.2.7.0", sha256="857ac83798d6d2bda5d4d11a90618ff19486da2e5a4c4ff022c5976b5746fe8c") version("1.8.15", sha256="4d5b4ed3f2daaed69989f53c0f9364dd87c82dc0a09807b5b6e9008e2426e86f") + depends_on("cxx", type="build") # generated + # Core dependencies depends_on("cmake@3.2.2:", type="build") depends_on("boost@1.53:", type=("build", "link")) diff --git a/var/spack/repos/builtin/packages/openipmi/package.py b/var/spack/repos/builtin/packages/openipmi/package.py index 7f4aea4d7e705a..6e64d5c5526f4a 100644 --- a/var/spack/repos/builtin/packages/openipmi/package.py +++ b/var/spack/repos/builtin/packages/openipmi/package.py @@ -14,10 +14,13 @@ class Openipmi(AutotoolsPackage): homepage = "https://sourceforge.net/projects/openipmi/" url = "https://sourceforge.net/projects/openipmi/files/OpenIPMI%202.0%20Library/OpenIPMI-2.0.29.tar.gz" + version("2.0.35", sha256="b059114f6299d73f04ff6e76a0857a0ab81aa362dee99644d256b223872437ad") version("2.0.29", sha256="2244124579afb14e569f34393e9ac61e658a28b6ffa8e5c0d2c1c12a8ce695cd") version("2.0.28", sha256="8e8b1de2a9a041b419133ecb21f956e999841cf2e759e973eeba9a36f8b40996") version("2.0.27", sha256="f3b1fafaaec2e2bac32fec5a86941ad8b8cb64543470bd6d819d7b166713d20b") + depends_on("c", type="build") # generated + depends_on("popt", type="link") depends_on("python", type=("build", "link", "run")) depends_on("perl", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/openjdk/package.py b/var/spack/repos/builtin/packages/openjdk/package.py index 532e56ee1afe2b..a884eaddbb6a4b 100644 --- a/var/spack/repos/builtin/packages/openjdk/package.py +++ b/var/spack/repos/builtin/packages/openjdk/package.py @@ -18,6 +18,40 @@ # format returned by platform.system() and 'arch' by platform.machine() _versions = { + "21.0.3_9": { + "Linux-x86_64": ( + "fffa52c22d797b715a962e6c8d11ec7d79b90dd819b5bc51d62137ea4b22a340", + "https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21.0.3%2B9/OpenJDK21U-jdk_x64_linux_hotspot_21.0.3_9.tar.gz", + ), + "Linux-aarch64": ( + "7d3ab0e8eba95bd682cfda8041c6cb6fa21e09d0d9131316fd7c96c78969de31", + "https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21.0.3%2B9/OpenJDK21U-jdk_aarch64_linux_hotspot_21.0.3_9.tar.gz", + ), + "Darwin-arm64": ( + "b6be6a9568be83695ec6b7cb977f4902f7be47d74494c290bc2a5c3c951e254f", + "https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21.0.3%2B9/OpenJDK21U-jdk_aarch64_mac_hotspot_21.0.3_9.tar.gz", + ), + }, + "21.0.0_35": { + "Linux-x86_64": ( + "82f64c53acaa045370d6762ebd7441b74e6fda14b464d54d1ff8ca941ec069e6", + "https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21%2B35/OpenJDK21U-jdk_x64_linux_hotspot_21_35.tar.gz", + ) + }, + "17.0.11_9": { + "Linux-x86_64": ( + "aa7fb6bb342319d227a838af5c363bfa1b4a670c209372f9e6585bd79da6220c", + "https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.11%2B9/OpenJDK17U-jdk_x64_linux_hotspot_17.0.11_9.tar.gz", + ), + "Linux-aarch64": ( + "a900acf3ae56b000afc35468a083b6d6fd695abec87a8abdb02743d5c72f6d6d", + "https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.11%2B9/OpenJDK17U-jdk_aarch64_linux_hotspot_17.0.11_9.tar.gz", + ), + "Darwin-arm64": ( + "09a162c58dd801f7cfacd87e99703ed11fb439adc71cfa14ceb2d3194eaca01c", + "https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.11%2B9/OpenJDK17U-jdk_aarch64_mac_hotspot_17.0.11_9.tar.gz", + ), + }, "17.0.8.1_1": { "Linux-x86_64": ( "c25dfbc334068a48c19c44ce39ad4b8427e309ae1cfa83f23c102e78b8a6dcc0", @@ -31,7 +65,7 @@ "18be56732c1692ef131625d814dcb02ee091a43fdd6f214a33d87cc14842fc3f", "https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.8.1%2B1/OpenJDK17U-jdk_x64_mac_hotspot_17.0.8.1_1.tar.gz", ), - "Darwin-aarch64": ( + "Darwin-arm64": ( "2e95eed48650f00650e963c8213b6c6ecda54458edf8d254ebc99d6a6966ffad", "https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.8.1%2B1/OpenJDK17U-jdk_aarch64_mac_hotspot_17.0.8.1_1.tar.gz", ), @@ -63,7 +97,7 @@ "ac21a5a87f7cfa00212ab7c41f7eb80ca33640d83b63ad850be811c24095d61a", "https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.4.1%2B1/OpenJDK17U-jdk_x64_mac_hotspot_17.0.4.1_1.tar.gz", ), - "Darwin-aarch64": ( + "Darwin-arm64": ( "3a976943a9e6a635e68e2b06bd093fc096aad9f5894acda673d3bea0cb3a6f38", "https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.4.1%2B1/OpenJDK17U-jdk_aarch64_mac_hotspot_17.0.4.1_1.tar.gz", ), @@ -144,6 +178,30 @@ "https://download.java.net/java/GA/jdk16.0.2/d4a915d82b4c4fbb9bde534da945d746/7/GPL/openjdk-16.0.2_linux-aarch64_bin.tar.gz", ), }, + "15.0.2": { + "Linux-x86_64": ( + "91ac6fc353b6bf39d995572b700e37a20e119a87034eeb939a6f24356fbcd207", + "https://download.java.net/java/GA/jdk15.0.2/0d1cfde4252546c6931946de8db48ee2/7/GPL/openjdk-15.0.2_linux-x64_bin.tar.gz", + ), + "Linux-aarch64": ( + "3958f01858f9290c48c23e7804a0af3624e8eca6749b085c425df4c4f2f7dcbc", + "https://download.java.net/java/GA/jdk15.0.2/0d1cfde4252546c6931946de8db48ee2/7/GPL/openjdk-15.0.2_linux-aarch64_bin.tar.gz", + ), + }, + "11.0.23_9": { + "Linux-x86_64": ( + "23e47ea7a3015be3240f21185fd902adebdcf76530757c9b482c7eb5bd3417c2", + "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.23%2B9/OpenJDK11U-jdk_x64_linux_hotspot_11.0.23_9.tar.gz", + ), + "Linux-aarch64": ( + "e00476a7be3c4adfa9b3d55d30768967fd246a8352e518894e183fa444d4d3ce", + "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.23%2B9/OpenJDK11U-jdk_aarch64_linux_hotspot_11.0.23_9.tar.gz", + ), + "Darwin-arm64": ( + "49122443bdeab2c9f468bd400f58f85a9ea462846faa79084fd6fd786d9b492d", + "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.23%2B9/OpenJDK11U-jdk_aarch64_mac_hotspot_11.0.23_9.tar.gz", + ), + }, "11.0.20.1_1": { "Linux-x86_64": ( "398a64bff002f0e3b0c01ecd24a1a32c83cb72a5255344219e9757d4ddd9f857", @@ -157,7 +215,7 @@ "42fd1373ee3f7c24f13551be20c8a5ae7ade778f83c45476ea333b2e3e025267", "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.20.1%2B1/OpenJDK11U-jdk_x64_mac_hotspot_11.0.20.1_1.tar.gz", ), - "Darwin-aarch64": ( + "Darwin-arm64": ( "d36abd2f8a8cd2c73a7893306d65a5ae03eaa73565c1fc197a69d1d6fb02405e", "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.20.1%2B1/OpenJDK11U-jdk_aarch64_mac_hotspot_11.0.20.1_1.tar.gz", ), @@ -175,7 +233,7 @@ "18c636bd103e240d29cdb30d7867720ea9fb9ff7c645738bfb4d5b8027269263", "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.17%2B8/OpenJDK11U-jdk_ppc64le_linux_hotspot_11.0.17_8.tar.gz", ), - "Darwin-aarch64": ( + "Darwin-arm64": ( "79b18cbd398b67a52ebaf033dfca15c7af4c1a84ec5fa68a88f3bf742bb082f7", "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.17%2B8/OpenJDK11U-jdk_aarch64_mac_hotspot_11.0.17_8.tar.gz", ), @@ -197,7 +255,7 @@ "723548e36e0b3e0a5a2f36a38b22ea825d3004e26054a0e254854adc57045352", "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.16.1%2B1/OpenJDK11U-jdk_x64_mac_hotspot_11.0.16.1_1.tar.gz", ), - "Darwin-aarch64": ( + "Darwin-arm64": ( "1953f06702d45eb54bae3ccf453b57c33de827015f5623a2dfc16e1c83e6b0a1", "https://github.com/adoptium/temurin11-binaries/releases/download/jdk-11.0.16.1%2B1/OpenJDK11U-jdk_aarch64_mac_hotspot_11.0.16.1_1.tar.gz", ), @@ -334,8 +392,8 @@ class Openjdk(Package): """The free and opensource java implementation""" - homepage = "https://jdk.java.net" - preferred_prefix = "11." + homepage = "https://openjdk.org/" + preferred_prefix = "17." preferred_defined = False for ver, packages in _versions.items(): @@ -348,8 +406,10 @@ class Openjdk(Package): version(ver, sha256=pkg[0], url=pkg[1], preferred=is_preferred) + provides("java@21", when="@21.0:21") provides("java@17", when="@17.0:17") provides("java@16", when="@16.0:16") + provides("java@15", when="@15.0:15") provides("java@11", when="@11.0:11") provides("java@10", when="@10.0:10") provides("java@9", when="@9.0:9") @@ -367,6 +427,8 @@ class Openjdk(Package): executables = ["^java$"] + skip_version_audit = ["platform=windows"] + @classmethod def determine_version(cls, exe): output = Executable(exe)("-version", output=str, error=str) diff --git a/var/spack/repos/builtin/packages/openjpeg/package.py b/var/spack/repos/builtin/packages/openjpeg/package.py index 4a00fcc42b584e..86d2af471a54ea 100644 --- a/var/spack/repos/builtin/packages/openjpeg/package.py +++ b/var/spack/repos/builtin/packages/openjpeg/package.py @@ -21,6 +21,8 @@ class Openjpeg(CMakePackage): license("BSD-2-Clause-NetBSD") + version("2.5.2", sha256="90e3896fed910c376aaf79cdd98bdfdaf98c6472efd8e1debf0a854938cbda6a") + version("2.5.1", sha256="c0b92dadd65e33b1cf94f39dd9157d5469846744c2e0afb8ca10961f51f61da6") version("2.5.0", sha256="0333806d6adecc6f7a91243b2b839ff4d2053823634d4f6ed7a59bc87409122a") version("2.4.0", sha256="8702ba68b442657f11aaeb2b338443ca8d5fb95b0d845757968a7be31ef7f16d") version("2.3.1", sha256="63f5a4713ecafc86de51bfad89cc07bb788e9bba24ebbf0c4ca637621aadb6a9") @@ -34,8 +36,12 @@ class Openjpeg(CMakePackage): version("1.5.2", sha256="3734e95edd0bef6e056815591755efd822228dc3cd866894e00a2c929026b16d") version("1.5.1", sha256="6a42fcc23cb179f69a1e94429089e5a5926aee1ffe582a0a6bd91299d297e61a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("codec", default=False, description="Build the CODEC executables") + depends_on("cmake@3.5:", when="@2.5.1:", type="build") depends_on("zlib-api", when="+codec") depends_on("libpng", when="+codec") depends_on("libtiff", when="+codec") diff --git a/var/spack/repos/builtin/packages/openkim-models/package.py b/var/spack/repos/builtin/packages/openkim-models/package.py index dd2156ba3247c7..c88290cbb5a9a4 100644 --- a/var/spack/repos/builtin/packages/openkim-models/package.py +++ b/var/spack/repos/builtin/packages/openkim-models/package.py @@ -41,6 +41,10 @@ class OpenkimModels(CMakePackage): "2019-03-29", sha256="053dda2023fe4bb6d7c1d66530c758c4e633bbf1f1be17b6b075b276fe8874f6" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + def cmake_args(self): args = [] args.append( diff --git a/var/spack/repos/builtin/packages/openldap/package.py b/var/spack/repos/builtin/packages/openldap/package.py index 4fedf169db4a06..d5fe9f11007eb1 100644 --- a/var/spack/repos/builtin/packages/openldap/package.py +++ b/var/spack/repos/builtin/packages/openldap/package.py @@ -26,6 +26,9 @@ class Openldap(AutotoolsPackage): version("2.4.49", sha256="e3b117944b4180f23befe87d0dcf47f29de775befbc469dcf4ac3dab3311e56e") version("2.4.48", sha256="d9523ffcab5cd14b709fcf3cb4d04e8bc76bb8970113255f372bc74954c6074d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("client_only", default=True, description="Client only installation") variant("icu", default=False, description="Build with unicode support") # Below, tls=none is not an option from programming point of view diff --git a/var/spack/repos/builtin/packages/openlibm/package.py b/var/spack/repos/builtin/packages/openlibm/package.py index 2645969ad9cbd3..7d1bf65682c0e8 100644 --- a/var/spack/repos/builtin/packages/openlibm/package.py +++ b/var/spack/repos/builtin/packages/openlibm/package.py @@ -21,6 +21,9 @@ class Openlibm(MakefilePackage): version("0.8.0", sha256="03620768df4ca526a63dd675c6de95a5c9d167ff59555ce57a61c6bf49e400ee") version("0.7.5", sha256="be983b9e1e40e696e8bbb7eb8f6376d3ca0ae675ae6d82936540385b0eeec15b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def make(self, spec, prefix): args = [ "prefix={0}".format(prefix), diff --git a/var/spack/repos/builtin/packages/openloops/package.py b/var/spack/repos/builtin/packages/openloops/package.py index 3c82765fd429e6..97510a2c685110 100644 --- a/var/spack/repos/builtin/packages/openloops/package.py +++ b/var/spack/repos/builtin/packages/openloops/package.py @@ -25,6 +25,10 @@ class Openloops(Package): version("2.1.2", sha256="f52575cae3d70b6b51a5d423e9cd0e076ed5961afcc015eec00987e64529a6ae") version("2.1.1", sha256="f1c47ece812227eab584e2c695fef74423d2f212873f762b8658f728685bcb91") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + all_processes = [ "tbln", "tbln_ew", diff --git a/var/spack/repos/builtin/packages/openmc/package.py b/var/spack/repos/builtin/packages/openmc/package.py index 67ad7d6337f72f..68e6f2142313a6 100644 --- a/var/spack/repos/builtin/packages/openmc/package.py +++ b/var/spack/repos/builtin/packages/openmc/package.py @@ -18,12 +18,14 @@ class Openmc(CMakePackage): programming model.""" homepage = "https://docs.openmc.org/" - url = "https://github.com/openmc-dev/openmc/tarball/v0.13.3" + url = "https://github.com/openmc-dev/openmc/tarball/v0.15.0" git = "https://github.com/openmc-dev/openmc.git" maintainers("paulromano") version("develop", branch="develop", submodules=True) version("master", branch="master", submodules=True) + version("0.15.0", commit="55b52b7ef3c9415ce045712132bf31c2a013d8c8", submodules=True) + version("0.14.0", commit="fa2330103de61a864c958d1a7250f11e5dd91468", submodules=True) version("0.13.3", commit="27cb0dc97960fe6d750eb5a93584a9a0ca532ac8", submodules=True) version("0.13.2", commit="030f73a8690ed19e91806e46c8caf338d252e74a", submodules=True) version("0.13.1", commit="33bc948f4b855c037975f16d16091fe4ecd12de3", submodules=True) @@ -34,6 +36,9 @@ class Openmc(CMakePackage): version("0.11.0", sha256="19a9d8e9c3b581e9060fbd96d30f1098312d217cb5c925eb6372a5786d9175af") version("0.10.0", sha256="47650cb45e2c326ae439208d6f137d75ad3e5c657055912d989592c6e216178f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Enable MPI support") variant("openmp", default=True, description="Enable OpenMP support") diff --git a/var/spack/repos/builtin/packages/openmm/package.py b/var/spack/repos/builtin/packages/openmm/package.py index 1d9f96ffab6a87..94d7cbb1050849 100644 --- a/var/spack/repos/builtin/packages/openmm/package.py +++ b/var/spack/repos/builtin/packages/openmm/package.py @@ -17,6 +17,7 @@ class Openmm(CMakePackage, CudaPackage): homepage = "https://openmm.org/" url = "https://github.com/openmm/openmm/archive/7.4.1.tar.gz" + version("8.1.1", sha256="347ad9f04dd88a673f7871127d9f23a75caf2c1a460a3f21f3328a24dc6547d0") version("8.0.0", sha256="dc63d7b47c8bb7b169c409cfd63d909ed0ce1ae114d37c627bf7a4231acf488e") version("7.7.0", sha256="51970779b8dc639ea192e9c61c67f70189aa294575acb915e14be1670a586c25") version("7.6.0", sha256="5a99c491ded9ba83ecc3fb1d8d22fca550f45da92e14f64f25378fda0048a89d") @@ -24,6 +25,10 @@ class Openmm(CMakePackage, CudaPackage): version("7.5.0", sha256="516748b4f1ae936c4d70cc6401174fc9384244c65cd3aef27bc2c53eac6d6de5") version("7.4.1", sha256="e8102b68133e6dcf7fcf29bc76a11ea54f30af71d8a7705aec0aee957ebe3a6d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + install_targets = ["install", "PythonInstall"] depends_on("python@2.7:", type=("build", "run")) @@ -49,7 +54,7 @@ class Openmm(CMakePackage, CudaPackage): ) def patch(self): - install_string = 'set(PYTHON_SETUP_COMMAND "install ' '--prefix={0}")'.format(self.prefix) + install_string = f'set(PYTHON_SETUP_COMMAND "install --prefix={self.prefix}")' filter_file( r"set\(PYTHON_SETUP_COMMAND \"install.*", diff --git a/var/spack/repos/builtin/packages/openmolcas/package.py b/var/spack/repos/builtin/packages/openmolcas/package.py index c3a59df79de2d6..d9e95fca8fffd8 100644 --- a/var/spack/repos/builtin/packages/openmolcas/package.py +++ b/var/spack/repos/builtin/packages/openmolcas/package.py @@ -22,6 +22,9 @@ class Openmolcas(CMakePackage): version("21.02", sha256="d0b9731a011562ff4740c0e67e48d9af74bf2a266601a38b37640f72190519ca") version("19.11", sha256="8ebd1dcce98fc3f554f96e54e34f1e8ad566c601196ee68153763b6c0a04c7b9") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=False, description="Build with mpi support.") depends_on("hdf5") diff --git a/var/spack/repos/builtin/packages/openmpi/package.py b/var/spack/repos/builtin/packages/openmpi/package.py index 6fb017ae023713..ee5f1517e874f3 100644 --- a/var/spack/repos/builtin/packages/openmpi/package.py +++ b/var/spack/repos/builtin/packages/openmpi/package.py @@ -44,10 +44,13 @@ class Openmpi(AutotoolsPackage, CudaPackage): # Current version( - "5.0.2", sha256="ee46ad8eeee2c3ff70772160bff877cbf38c330a0bc3b3ddc811648b3396698f" - ) # libmpi.so.40.40.2 + "5.0.3", sha256="990582f206b3ab32e938aa31bbf07c639368e4405dca196fabe7f0f76eeda90b" + ) # libmpi.so.40.40.3 # Still supported + version( + "5.0.2", sha256="ee46ad8eeee2c3ff70772160bff877cbf38c330a0bc3b3ddc811648b3396698f" + ) # libmpi.so.40.40.2 version( "5.0.1", sha256="e357043e65fd1b956a47d0dae6156a90cf0e378df759364936c1781f1a25ef80" ) # libmpi.so.40.40.1 @@ -385,6 +388,10 @@ class Openmpi(AutotoolsPackage, CudaPackage): "1.0", sha256="cf75e56852caebe90231d295806ac3441f37dc6d9ad17b1381791ebb78e21564" ) # libmpi.so.0.0.0 + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + patch("ad_lustre_rwcontig_open_source.patch", when="@1.6.5") patch("llnl-platforms.patch", when="@1.6.5") patch("configure.patch", when="@1.10.1") @@ -430,6 +437,12 @@ class Openmpi(AutotoolsPackage, CudaPackage): patch("btlsmcuda-fix-problem-with-makefile.patch", when="@5.0.0") patch("accelerator-build-components-as-dso-s-by-default.patch", when="@5.0.0:5.0.1") + # OpenMPI 5.0.0-5.0.3 needs to change PMIX version check to compile w/ PMIX > 4.2.5 + # https://github.com/open-mpi/ompi/issues/12537#issuecomment-2103350910 + # https://github.com/openpmix/prrte/pull/1957 + patch("pmix_getline_pmix_version.patch", when="@5.0.0:5.0.3") + patch("pmix_getline_pmix_version-prte.patch", when="@5.0.3") + variant( "fabrics", values=disjoint_sets( @@ -499,6 +512,26 @@ class Openmpi(AutotoolsPackage, CudaPackage): variant("lustre", default=False, description="Lustre filesystem library support") variant("romio", default=True, when="@:5", description="Enable ROMIO support") variant("romio", default=False, when="@5:", description="Enable ROMIO support") + variant( + "romio-filesystem", + description="Add the filesystem to romio", + values=disjoint_sets( + ( + "daos", + "nfs", + "ufs", + "pvfs2", + "testfs", + "xfs", + "panfs", + "lustre", + "gpfs", + "ime", + "quobytefs", + ) + ).with_non_feature_values("none"), + ) + variant("rsh", default=True, description="Enable rsh (openssh) process lifecycle management") variant( "orterunprefix", @@ -822,13 +855,20 @@ def setup_run_environment(self, env): env.set("MPICXX", join_path(self.prefix.bin, "mpic++")) env.set("MPIF77", join_path(self.prefix.bin, "mpif77")) env.set("MPIF90", join_path(self.prefix.bin, "mpif90")) + # Open MPI also has had mpifort since v1.7, so we can set MPIFC to that + # Note: that mpif77 and mpif90 are deprecated since v1.7, but careful + # testing would be needed to change the MPIF77 and MPIF90 above. For now + # we just *add* functionality + if self.spec.satisfies("@1.7:"): + env.set("MPIFC", join_path(self.prefix.bin, "mpifort")) def setup_dependent_build_environment(self, env, dependent_spec): # Use the spack compiler wrappers under MPI - env.set("OMPI_CC", spack_cc) - env.set("OMPI_CXX", spack_cxx) - env.set("OMPI_FC", spack_fc) - env.set("OMPI_F77", spack_f77) + dependent_module = dependent_spec.package.module + env.set("OMPI_CC", dependent_module.spack_cc) + env.set("OMPI_CXX", dependent_module.spack_cxx) + env.set("OMPI_FC", dependent_module.spack_fc) + env.set("OMPI_F77", dependent_module.spack_f77) # See https://www.open-mpi.org/faq/?category=building#installdirs for suffix in [ @@ -850,7 +890,7 @@ def setup_dependent_build_environment(self, env, dependent_spec): "PKGLIBDIR", "PKGINCLUDEDIR", ]: - env.unset("OPAL_%s" % suffix) + env.unset(f"OPAL_{suffix}") def setup_dependent_package(self, module, dependent_spec): self.spec.mpicc = join_path(self.prefix.bin, "mpicc") @@ -956,6 +996,11 @@ def configure_args(self): spec = self.spec config_args = ["--enable-shared", "--disable-silent-rules", "--disable-sphinx"] + # Work around incompatibility with new apple-clang linker + # https://github.com/open-mpi/ompi/issues/12427 + if spec.satisfies("@5: %apple-clang@15:"): + config_args.append("--with-wrapper-fcflags=-Wl,-ld_classic") + # All rpath flags should be appended with self.compiler.cc_rpath_arg. # Later, we might need to update share/openmpi/mpic++-wrapper-data.txt # and mpifort-wrapper-data.txt (see filter_rpaths()). @@ -994,7 +1039,7 @@ def configure_args(self): config_args.extend(self.with_or_without("fabrics")) if spec.satisfies("@2.0.0:"): - if "fabrics=xpmem platform=cray" in spec: + if "fabrics=xpmem" in spec: config_args.append("--with-cray-xpmem") else: config_args.append("--without-cray-xpmem") @@ -1003,6 +1048,9 @@ def configure_args(self): if "schedulers=auto" not in spec: config_args.extend(self.with_or_without("schedulers")) + if spec.satisfies("schedulers=lsf"): + config_args.append("--with-lsf-libdir={0}".format(spec["lsf"].libs.directories[0])) + config_args.extend(self.enable_or_disable("memchecker")) if spec.satisfies("+memchecker"): config_args.extend(["--enable-debug"]) @@ -1035,9 +1083,14 @@ def configure_args(self): elif spec.satisfies("@1.7.4:"): config_args.extend(["--disable-java", "--disable-mpi-java"]) + # Romio if "~romio" in spec: config_args.append("--disable-io-romio") + if not spec.satisfies("romio-filesystem=none"): + args = "+".join(spec.variants["romio-filesystem"].value) + config_args.append(f"--with-io-romio-flags=--with-file-system={args}") + if "+gpfs" in spec: config_args.append("--with-gpfs") else: @@ -1139,6 +1192,23 @@ def configure_args(self): # if spec.satisfies("@5.0.0:") and spec.satisfies("%oneapi"): # config_args.append("--disable-io-romio") + # https://www.intel.com/content/www/us/en/developer/articles/release-notes/oneapi-c-compiler-release-notes.html : + # Key Features in Intel C++ Compiler Classic 2021.7 + # + # The Intel C++ Classic Compiler is deprecated and an additional + # diagnostic message will be output with each invocation. This + # diagnostic may impact expected output during compilation. For + # example, using the compiler to produce preprocessed information + # (icpc -E) will produce the additional deprecation diagnostic, + # interfering with the expected preprocessed output. + # + # This output can be disabled by using -diag-disable=10441 on + # Linux/macOS or /Qdiag-disable:10441 on Windows. You can add this + # option on the command line, configuration file or option setting + # environment variables. + if spec.satisfies("%intel@2021.7.0:"): + config_args.append("CPPFLAGS=-diag-disable=10441") + return config_args @run_after("install", when="+wrapper-rpath") diff --git a/var/spack/repos/builtin/packages/openmpi/pmix_getline_pmix_version-prte.patch b/var/spack/repos/builtin/packages/openmpi/pmix_getline_pmix_version-prte.patch new file mode 100644 index 00000000000000..add0fb2c9bca0a --- /dev/null +++ b/var/spack/repos/builtin/packages/openmpi/pmix_getline_pmix_version-prte.patch @@ -0,0 +1,14 @@ +diff --git a/3rd-party/prrte/src/tools/prte/prte.c b/3rd-party/prrte/src/tools/prte/prte.c +index 3c62ef4b66..d15347d324 100644 +--- a/3rd-party/prrte/src/tools/prte/prte.c ++++ b/3rd-party/prrte/src/tools/prte/prte.c +@@ -256,7 +256,7 @@ static void shutdown_callback(int fd, short flags, void *arg) + exit(PRTE_ERROR_DEFAULT_EXIT_CODE); + } + +-#if PMIX_NUMERIC_VERSION < 0x00040208 ++#if PMIX_NUMERIC_VERSION < 0x00040205 + static char *pmix_getline(FILE *fp) + { + char *ret, *buff; + diff --git a/var/spack/repos/builtin/packages/openmpi/pmix_getline_pmix_version.patch b/var/spack/repos/builtin/packages/openmpi/pmix_getline_pmix_version.patch new file mode 100644 index 00000000000000..ccb854ce811993 --- /dev/null +++ b/var/spack/repos/builtin/packages/openmpi/pmix_getline_pmix_version.patch @@ -0,0 +1,52 @@ +diff --git a/3rd-party/prrte/src/mca/ess/base/ess_base_bootstrap.c b/3rd-party/prrte/src/mca/ess/base/ess_base_bootstrap.c +index 48ce664915..f37bd7bea2 100644 +--- a/3rd-party/prrte/src/mca/ess/base/ess_base_bootstrap.c ++++ b/3rd-party/prrte/src/mca/ess/base/ess_base_bootstrap.c +@@ -68,7 +68,7 @@ static pmix_status_t regex_parse_value_range(char *base, char *range, + char ***names); + static pmix_status_t read_file(char *regexp, char ***names); + +-#if PMIX_NUMERIC_VERSION < 0x00040208 ++#if PMIX_NUMERIC_VERSION < 0x00040205 + static char *pmix_getline(FILE *fp) + { + char *ret, *buff; +diff --git a/3rd-party/prrte/src/mca/ras/base/ras_base_allocate.c b/3rd-party/prrte/src/mca/ras/base/ras_base_allocate.c +index bc9db628f5..858f1397fb 100644 +--- a/3rd-party/prrte/src/mca/ras/base/ras_base_allocate.c ++++ b/3rd-party/prrte/src/mca/ras/base/ras_base_allocate.c +@@ -59,7 +59,7 @@ + + #include "src/mca/ras/base/ras_private.h" + +-#if PMIX_NUMERIC_VERSION < 0x00040208 ++#if PMIX_NUMERIC_VERSION < 0x00040205 + static char *pmix_getline(FILE *fp) + { + char *ret, *buff; +diff --git a/3rd-party/prrte/src/mca/rmaps/rank_file/rmaps_rank_file.c b/3rd-party/prrte/src/mca/rmaps/rank_file/rmaps_rank_file.c +index b8316e0a8e..dfd0b847d0 100644 +--- a/3rd-party/prrte/src/mca/rmaps/rank_file/rmaps_rank_file.c ++++ b/3rd-party/prrte/src/mca/rmaps/rank_file/rmaps_rank_file.c +@@ -71,7 +71,7 @@ static int prte_rmaps_rf_process_lsf_affinity_hostfile(prte_job_t *jdata, prte_r + + char *prte_rmaps_rank_file_slot_list = NULL; + +-#if PMIX_NUMERIC_VERSION < 0x00040208 ++#if PMIX_NUMERIC_VERSION < 0x00040205 + static char *pmix_getline(FILE *fp) + { + char *ret, *buff; +diff --git a/3rd-party/prrte/src/mca/rmaps/seq/rmaps_seq.c b/3rd-party/prrte/src/mca/rmaps/seq/rmaps_seq.c +index 555aa39c42..356fb72aa9 100644 +--- a/3rd-party/prrte/src/mca/rmaps/seq/rmaps_seq.c ++++ b/3rd-party/prrte/src/mca/rmaps/seq/rmaps_seq.c +@@ -109,7 +109,7 @@ static bool quickmatch(prte_node_t *nd, char *name) + return false; + } + +-#if PMIX_NUMERIC_VERSION < 0x00040208 ++#if PMIX_NUMERIC_VERSION < 0x00040205 + static char *pmix_getline(FILE *fp) + { + char *ret, *buff; diff --git a/var/spack/repos/builtin/packages/openmx/package.py b/var/spack/repos/builtin/packages/openmx/package.py index 96626672ec18ea..3ec7c6b818e1e2 100644 --- a/var/spack/repos/builtin/packages/openmx/package.py +++ b/var/spack/repos/builtin/packages/openmx/package.py @@ -20,6 +20,9 @@ class Openmx(MakefilePackage): version("3.9", sha256="27bb56bd4d1582d33ad32108fb239b546bdd1bdffd6f5b739b4423da1ab93ae2") version("3.8", sha256="36ee10d8b1587b25a2ca1d57f110111be65c4fb4dc820e6d93e1ed2b562634a1") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + resource( name="patch", url="http://www.openmx-square.org/bugfixed/18June12/patch3.8.5.tar.gz", diff --git a/var/spack/repos/builtin/packages/opennurbs/package.py b/var/spack/repos/builtin/packages/opennurbs/package.py index cd583f0f888ca5..c9110087a06037 100644 --- a/var/spack/repos/builtin/packages/opennurbs/package.py +++ b/var/spack/repos/builtin/packages/opennurbs/package.py @@ -4,10 +4,11 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.build_systems import cmake, makefile from spack.package import * -class Opennurbs(Package): +class Opennurbs(CMakePackage, MakefilePackage): """OpenNURBS is an open-source NURBS-based geometric modeling library and toolset, with meshing and display / output functions. """ @@ -20,34 +21,34 @@ class Opennurbs(Package): license("Zlib") version("develop", branch="develop") - version( "percept", sha256="d12a8f14f0b27d286fb7a75ab3c4e300f77d1fbb028326d1c8d28e4641605538", url="https://github.com/PerceptTools/percept/raw/master/build-cmake/opennurbs-percept.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + build_system( + conditional("cmake", when="@1:"), conditional("makefile", when="@:0"), default="cmake" + ) + variant("shared", default=True, description="Build shared libraries") - # CMake installation method - def install(self, spec, prefix): - cmake_args = [self.define_from_variant("BUILD_SHARED_LIBS", "shared")] - cmake_args.extend(std_cmake_args) +class CMakeBuilder(cmake.CMakeBuilder): + def cmake_args(self): + return [self.define_from_variant("BUILD_SHARED_LIBS", "shared")] + - with working_dir("spack-build", create=True): - cmake("..", *cmake_args) - make() - make("install") +class MakefileBuilder(makefile.MakefileBuilder): - # Pre-cmake installation method - @when("@percept") - def install(self, spec, prefix): - make(parallel=False) + def build(self, pkg, spec, prefix): + make("RM=rm -f", "AR=ar cr", f"CC={spack_cc}", f"CCC={spack_cxx}", parallel=False) - # Install manually + def install(self, pkg, spec, prefix): mkdir(prefix.lib) mkdir(prefix.include) install("libopenNURBS.a", prefix.lib) - install_tree("zlib", join_path(prefix.include, "zlib")) install("*.h", prefix.include) diff --git a/var/spack/repos/builtin/packages/openpa/package.py b/var/spack/repos/builtin/packages/openpa/package.py index 63f73bbb7492cd..7ab2d75413943f 100644 --- a/var/spack/repos/builtin/packages/openpa/package.py +++ b/var/spack/repos/builtin/packages/openpa/package.py @@ -14,8 +14,11 @@ class Openpa(AutotoolsPackage): license("mpich2") + version("1.0.5", sha256="4a18c054970970a1baf477504053a49149f962329b70b481c2ec93e157c9093b") version("1.0.4", sha256="9e5904b3bbdcb24e8429c12d613422e716a3479f3e0aeefbd9ce546852899e3a") version("1.0.3", sha256="b73943f341b0d4475109f8f341a5229258e43510b62cb5d488cf7f0e84fa5557") version("1.0.2", sha256="13b5ef8ea3502822ab03861bf9d047c3bda722b22605edf3f508fb355746db4f") version("1.0.1", sha256="63fae765d44e5741506b92cd0ff55c237c1e19d20bd5539c77cea1c67d5b4303") version("1.0.0", sha256="0f163da7fbe39a438c301b52bb876961bfedfe4ab6248a98297dd326fabee627") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/openpbs/package.py b/var/spack/repos/builtin/packages/openpbs/package.py index 1a588e95b1436e..32ae5909785a15 100644 --- a/var/spack/repos/builtin/packages/openpbs/package.py +++ b/var/spack/repos/builtin/packages/openpbs/package.py @@ -21,6 +21,9 @@ class Openpbs(AutotoolsPackage): version("20.0.1", sha256="685a4abcea92bf518df02b544d25e237ae8cef76f86525f7bf3554812e9f50fa") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/openpmd-api/package.py b/var/spack/repos/builtin/packages/openpmd-api/package.py index b114ed8efebf92..338895684d7481 100644 --- a/var/spack/repos/builtin/packages/openpmd-api/package.py +++ b/var/spack/repos/builtin/packages/openpmd-api/package.py @@ -40,6 +40,8 @@ class OpenpmdApi(CMakePackage): version("0.12.0", tag="0.12.0-alpha", commit="23be484dd2570b5277779eafcc5f1eb70c6d98f2") version("0.11.1", tag="0.11.1-alpha", commit="c40292aafbf564807710424d106304f9670a8304") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build a shared version of the library") variant("mpi", default=True, description="Enable parallel I/O") variant("hdf5", default=True, description="Enable HDF5 support") @@ -54,7 +56,7 @@ class OpenpmdApi(CMakePackage): depends_on("mpi@2.3:", when="+mpi") # might become MPI 3.0+ depends_on("nlohmann-json@3.9.1:") depends_on("mpark-variant@1.4.0:", when="@:0.14") # pre C++17 releases - depends_on("toml11@3.7.1:", when="@0.15.0:") + depends_on("toml11@3.7.1:3.8.1", when="@0.15.0:") with when("+hdf5"): depends_on("hdf5@1.8.13:") depends_on("hdf5@1.8.13: ~mpi", when="~mpi") @@ -172,17 +174,10 @@ def check(self): # later tests ctest("--output-on-failure", "-j1") - def test(self): - """Perform smoke tests on the installed package.""" - exes = ["openpmd-ls"] # in 0.11.1+ - for exe in exes: - spec_vers_str = "{0}".format(self.spec.version) - reason = "test version of {0} is {1}".format(exe, spec_vers_str) - self.run_test( - exe, - ["--version"], - [spec_vers_str], - installed=True, - purpose=reason, - skip_missing=False, - ) + def test_run_openpmd_ls(self): + """Test if openpmd-ls runs correctly""" + if self.spec.satisfies("@:0.11.0"): + raise SkipTest("Package must be installed as version 0.11.1 or later") + exe = which(join_path(self.prefix.bin, "openpmd-ls")) + out = exe(output=str.split, error=str.split) + assert str(self.spec.version) in out diff --git a/var/spack/repos/builtin/packages/openradioss-engine/package.py b/var/spack/repos/builtin/packages/openradioss-engine/package.py index 9dcd3591558fab..3fe45e505426a6 100644 --- a/var/spack/repos/builtin/packages/openradioss-engine/package.py +++ b/var/spack/repos/builtin/packages/openradioss-engine/package.py @@ -27,6 +27,10 @@ class OpenradiossEngine(CMakePackage): maintainers("kjrstory") version("main", branch="main") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=False, description="Enable MPI support") variant("sp", default=False, description="Using single precision option") variant("debug", default=False, description="Debug Option") @@ -54,59 +58,52 @@ class OpenradiossEngine(CMakePackage): @property def compiler_name(self): compiler_mapping = { - "aocc": "64_AOCC", - "intel": "64_intel", - "oneapi": "64_intel", - "gcc": "64_gf", - "arm": "a64_gf", + "aocc": "linux64_AOCC", + "intel": "linux64_intel", + "oneapi": "linux64_intel", + "gcc": "linux64_gf", + "arm": "linuxa64", } compiler_name = compiler_mapping[self.spec.compiler.name] return compiler_name def cmake_args(self): args = [ - "-Dmpi_os=0", - "-DCMAKE_Fortran_COMPILER={0}".format(spack_fc), - "-DCMAKE_C_COMPILER={0}".format(spack_cc), - "-DCMAKE_CPP_COMPILER={0}".format(spack_cxx), - "-DCMAKE_CXX_COMPILER={0}".format(spack_cxx), - "-Dsanitize=0", + self.define("mpi_os", False), + self.define("CMAKE_Fortran_COMPILER", spack_fc), + self.define("CMAKE_C_COMPILER", spack_cc), + self.define("CMAKE_CPP_COMPILER", spack_cxx), + self.define("CMAKE_CXX_COMPILER", spack_cxx), + self.define("sanitize", False), + self.define("arch", self.compiler_name), + self.define_from_variant("debug", "debug"), + self.define_from_variant("static_link", "static_link"), ] - args.append("-Drach=linux" + self.compiler_name) - if "+sp" in self.spec: - args.append("-Dprecision=sp") + args.append(self.define("precision", "sp")) else: - args.append("-Dprecision=dp") + args.append(self.define("precision", "dp")) if "+mpi" in self.spec: - args.append("-DMPI=ompi") - args.append("-Dmpi_root=" + self.spec["mpi"].prefix) - args.append("-Dmpi_incdir=" + self.spec["mpi"].prefix.include) - args.append("-Dmpi_libdir=" + self.spec["mpi"].prefix.lib) - else: - args.append("-DMPI=smp") - - if "+debug" in self.spec: - args.append("-Ddebug=1") + args.append(self.define("MPI", "ompi")) + args.append(self.define("mpi_root", self.spec["mpi"].prefix)) + args.append(self.define("mpi_incdir", self.spec["mpi"].prefix.include)) + args.append(self.define("mpi_libdir", self.spec["mpi"].prefix.lib)) else: - args.append("-Ddebug=0") + args.append(self.define("MPI", "smp")) - if "+static_link" in self.spec: - args.append("-Dstatic_link=1") - else: - args.append("-Dstatic_link=0") + exec_file = f"engine_{self.compiler_name}" + exec_file += "_ompi" if "+mpi" in self.spec else "" + args.append(self.define("EXEC_NAME", exec_file)) return args def install(self, spec, prefix): mkdirp(join_path(prefix, "exec")) - if "+mpi" in spec: - exec_file = "engine_linux" + self.compiler_name + "_ompi" - else: - exec_file = "engine_linux" + self.compiler_name + exec_file = f"engine_{self.compiler_name}" + exec_file += "_ompi" if "+mpi" in self.spec else "" install( join_path(self.stage.source_path, "engine", exec_file), diff --git a/var/spack/repos/builtin/packages/openradioss-starter/package.py b/var/spack/repos/builtin/packages/openradioss-starter/package.py index edede265c9b211..b727c7e5c07110 100644 --- a/var/spack/repos/builtin/packages/openradioss-starter/package.py +++ b/var/spack/repos/builtin/packages/openradioss-starter/package.py @@ -28,6 +28,10 @@ class OpenradiossStarter(CMakePackage): maintainers("kjrstory") version("main", branch="main") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("sp", default=False, description="Using single precision option") variant("debug", default=False, description="Debug Option") variant("static_link", default=False, description="Static_link Option") @@ -53,47 +57,39 @@ class OpenradiossStarter(CMakePackage): @property def compiler_name(self): compiler_mapping = { - "aocc": "64_AOCC", - "intel": "64_intel", - "oneapi": "64_intel", - "gcc": "64_gf", - "arm": "a64_gf", + "aocc": "linux64_AOCC", + "intel": "linux64_intel", + "oneapi": "linux64_intel", + "gcc": "linux64_gf", + "arm": "linuxa64", } compiler_name = compiler_mapping[self.spec.compiler.name] return compiler_name def cmake_args(self): args = [ - "-DCMAKE_Fortran_COMPILER={0}".format(spack_fc), - "-DCMAKE_C_COMPILER={0}".format(spack_cc), - "-DCMAKE_CPP_COMPILER={0}".format(spack_cxx), - "-DCMAKE_CXX_COMPILER={0}".format(spack_cxx), - "-Dsanitize=0", + self.define("CMAKE_Fortran_COMPILER", spack_fc), + self.define("CMAKE_C_COMPILER", spack_cc), + self.define("CMAKE_CPP_COMPILER", spack_cxx), + self.define("CMAKE_CXX_COMPILER", spack_cxx), + self.define("santize", False), + self.define("arch", self.compiler_name), + self.define("EXEC_NAME", f"starter_{self.compiler_name}"), + self.define_from_variant("debug", "debug"), + self.define_from_variant("static_link", "static_link"), ] - args.append("-Darch=linux" + self.compiler_name) - if "+sp" in self.spec: - args.append("-Dprecision=sp") - else: - args.append("-Dprecision=dp") - - if "+debug" in self.spec: - args.append("-Ddebug=1") - else: - args.append("-Ddebug=0") - - if "+static_link" in self.spec: - args.append("-Dstatic_link=1") + args.append(self.define("precision", "sp")) else: - args.append("-Dstatic_link=0") + args.append(self.define("precision", "dp")) return args def install(self, spec, prefix): mkdirp(join_path(prefix, "exec")) - exec_file = "starter_linux" + self.compiler_name + exec_file = f"starter_{self.compiler_name}" install( join_path(self.stage.source_path, "starter", exec_file), diff --git a/var/spack/repos/builtin/packages/openrasmol/package.py b/var/spack/repos/builtin/packages/openrasmol/package.py index b7064e810bd336..f66dd35241ee73 100644 --- a/var/spack/repos/builtin/packages/openrasmol/package.py +++ b/var/spack/repos/builtin/packages/openrasmol/package.py @@ -17,6 +17,8 @@ class Openrasmol(MakefilePackage): version("2.7.5.2", sha256="b975e6e69d5c6b161a81f04840945d2f220ac626245c61bcc6c56181b73a5718") + depends_on("c", type="build") # generated + depends_on("imake", type="build") depends_on("libxext", type="link") depends_on("libxi", type="link") diff --git a/var/spack/repos/builtin/packages/openresty/package.py b/var/spack/repos/builtin/packages/openresty/package.py index 5c4ca053eea269..df9cb91771c4d9 100644 --- a/var/spack/repos/builtin/packages/openresty/package.py +++ b/var/spack/repos/builtin/packages/openresty/package.py @@ -18,10 +18,14 @@ class Openresty(AutotoolsPackage): license("BSD-2-Clause") + version("1.25.3.1", sha256="32ec1a253a5a13250355a075fe65b7d63ec45c560bbe213350f0992a57cd79df") version("1.15.8.2", sha256="bf92af41d3ad22880047a8b283fc213d59c7c1b83f8dae82e50d14b64d73ac38") version("1.15.8.1", sha256="89a1238ca177692d6903c0adbea5bdf2a0b82c383662a73c03ebf5ef9f570842") version("1.13.6.2", sha256="946e1958273032db43833982e2cec0766154a9b5cb8e67868944113208ff2942") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pcre", type="build") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/openscenegraph/package.py b/var/spack/repos/builtin/packages/openscenegraph/package.py index 060eb6529e0c70..9d257c5c71ba72 100644 --- a/var/spack/repos/builtin/packages/openscenegraph/package.py +++ b/var/spack/repos/builtin/packages/openscenegraph/package.py @@ -29,6 +29,9 @@ class Openscenegraph(CMakePackage): version("3.2.3", sha256="a1ecc6524197024834e1277916922b32f30246cb583e27ed19bf3bf889534362") version("3.1.5", sha256="dddecf2b33302076712100af59b880e7647bc595a9a7cc99186e98d6e0eaeb5c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Builds a shared version of the library") variant("apps", default=False, description="Build OpenSceneGraph tools") variant("dcmtk", default=False, description="Build support for DICOM files using DCMTK") @@ -74,10 +77,19 @@ class Openscenegraph(CMakePackage): depends_on("poppler+glib", when="+pdf") depends_on("librsvg", when="+svg") - depends_on("ffmpeg@:4 +avresample", when="+ffmpeg") - # https://github.com/openscenegraph/OpenSceneGraph/issues/167 - depends_on("ffmpeg@:2", when="@:3.4.0+ffmpeg") - + with when("+ffmpeg"): + depends_on("ffmpeg") + requires("^ffmpeg +avresample", when="^ffmpeg@:4") + # https://github.com/openscenegraph/OpenSceneGraph/issues/167 + depends_on("ffmpeg@:2", when="@:3.4.0") + + # patch submitted for inclusion in OpenSceneGraph for extending compatibility + # with ffmpeg from versions up to 4 to versions 5 & 6 + patch( + "https://github.com/openscenegraph/OpenSceneGraph/commit/759620a3b7b787c960a7e414ba26ab5497817d40.patch?full_index=1", + sha256="1e6daf0d15e916b69d62519a0ca4f8a722fe2144cbdab7dd182eaffb141e3c1a", + when="@3.6:", + ) patch("glibc-jasper.patch", when="@3.4%gcc") # from gentoo: https://raw.githubusercontent.com/gentoo/gentoo/9523b20c27d12dd72d1fd5ced3ba4995099925a2/dev-games/openscenegraph/files/openscenegraph-3.6.5-openexr3.patch patch("openscenegraph-3.6.5-openexr3.patch", when="@3.6:") diff --git a/var/spack/repos/builtin/packages/openslide/package.py b/var/spack/repos/builtin/packages/openslide/package.py index e9992484be3996..c94e2e39f67082 100644 --- a/var/spack/repos/builtin/packages/openslide/package.py +++ b/var/spack/repos/builtin/packages/openslide/package.py @@ -16,6 +16,8 @@ class Openslide(AutotoolsPackage): version("3.4.1", sha256="9938034dba7f48fadc90a2cdf8cfe94c5613b04098d1348a5ff19da95b990564") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("openjpeg") depends_on("jpeg") diff --git a/var/spack/repos/builtin/packages/openslp/package.py b/var/spack/repos/builtin/packages/openslp/package.py index 6e77b75dbfa3fa..f930d127234065 100644 --- a/var/spack/repos/builtin/packages/openslp/package.py +++ b/var/spack/repos/builtin/packages/openslp/package.py @@ -18,6 +18,9 @@ class Openslp(AutotoolsPackage): version("2.0.0", sha256="9dda45ff52cf8561ca1414ac8b4947ed2d9b43e66aec03478fa0ed37121a5ea2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/openspeedshop-utils/package.py b/var/spack/repos/builtin/packages/openspeedshop-utils/package.py index 7fa3e646e3f908..0e9c5caf6d639a 100644 --- a/var/spack/repos/builtin/packages/openspeedshop-utils/package.py +++ b/var/spack/repos/builtin/packages/openspeedshop-utils/package.py @@ -38,6 +38,10 @@ class OpenspeedshopUtils(CMakePackage): version("2.4.2", branch="2.4.2") version("2.4.1", branch="2.4.1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "runtime", default=False, description="build only the runtime libraries and collectors." ) diff --git a/var/spack/repos/builtin/packages/openspeedshop/package.py b/var/spack/repos/builtin/packages/openspeedshop/package.py index 5ef937a0f8e92e..5ceb5113300c74 100644 --- a/var/spack/repos/builtin/packages/openspeedshop/package.py +++ b/var/spack/repos/builtin/packages/openspeedshop/package.py @@ -35,6 +35,10 @@ class Openspeedshop(CMakePackage): version("2.4.2", branch="2.4.2") version("2.4.1", branch="2.4.1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "runtime", default=False, description="build only the runtime libraries and collectors." ) diff --git a/var/spack/repos/builtin/packages/openssh/package.py b/var/spack/repos/builtin/packages/openssh/package.py index 970a8da703e5d4..b39e33aee7be32 100755 --- a/var/spack/repos/builtin/packages/openssh/package.py +++ b/var/spack/repos/builtin/packages/openssh/package.py @@ -25,6 +25,8 @@ class Openssh(AutotoolsPackage): license("SSH-OpenSSH") + version("9.7p1", sha256="490426f766d82a2763fcacd8d83ea3d70798750c7bd2aff2e57dc5660f773ffd") + version("9.6p1", sha256="910211c07255a8c5ad654391b40ee59800710dd8119dd5362de09385aa7a777c") version("9.5p1", sha256="f026e7b79ba7fb540f75182af96dc8a8f1db395f922bbc9f6ca603672686086b") version("9.4p1", sha256="3608fd9088db2163ceb3e600c85ab79d0de3d221e59192ea1923e23263866a85") version("9.3p1", sha256="e9baba7701a76a51f3d85a62c383a3c9dcd97fa900b859bc7db114c1868af8a8") @@ -52,6 +54,9 @@ class Openssh(AutotoolsPackage): version("6.7p1", sha256="b2f8394eae858dabbdef7dac10b99aec00c95462753e80342e530bbb6f725507") version("6.6p1", sha256="48c1f0664b4534875038004cc4f3555b8329c2a81c1df48db5c517800de203bb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "gssapi", default=True, description="Enable authentication via Kerberos through GSSAPI" ) @@ -106,9 +111,13 @@ def patch(self): # #39599: fix configure to parse zlib 1.3's version number to prevent build fail filter_file(r"if \(n != 3 && n != 4\)", "if (n < 2)", "configure") - # https://github.com/Homebrew/homebrew-core/blob/7aabdeb30506be9b01708793ae553502c115dfc8/Formula/o/openssh.rb#L71-L77 - if self.spec.target.family == "x86_64" and self.spec.platform == "darwin": - filter_file(r"-fzero-call-used-regs=all", "-fzero-call-used-regs=used", "configure") + # Clang-based compilers (known at least 14-17) may randomly mis-compile + # openssh according to this thread even when -fzero-call-used-regs=used: + # https://www.mail-archive.com/openssh-bugs@mindrot.org/msg17461.html + # Therefore, remove -fzero-call-used-regs=all for these compilers: + spec = self.spec + if spec.version < Version("9.6p1") and self.compiler.name.endswith(("clang", "oneapi")): + filter_file("-fzero-call-used-regs=all", "", "configure") def configure_args(self): # OpenSSH's privilege separation path defaults to /var/empty. At diff --git a/var/spack/repos/builtin/packages/openssl/package.py b/var/spack/repos/builtin/packages/openssl/package.py index 646a88f2b02a29..e21d427731c63c 100644 --- a/var/spack/repos/builtin/packages/openssl/package.py +++ b/var/spack/repos/builtin/packages/openssl/package.py @@ -12,10 +12,9 @@ class Openssl(Package): # Uses Fake Autotools, should subclass Package - """OpenSSL is an open source project that provides a robust, - commercial-grade, and full-featured toolkit for the Transport - Layer Security (TLS) and Secure Sockets Layer (SSL) protocols. - It is also a general-purpose cryptography library.""" + """OpenSSL is an open source project that provides a robust, commercial-grade, and + full-featured toolkit for the Transport Layer Security (TLS) and Secure Sockets Layer (SSL) + protocols. It is also a general-purpose cryptography library.""" homepage = "https://www.openssl.org" @@ -32,340 +31,44 @@ class Openssl(Package): # Uses Fake Autotools, should subclass Package license("Apache-2.0") - version("3.2.1", sha256="83c7329fe52c850677d75e5d0b0ca245309b97e8ecbcfdc1dfdc4ab9fac35b39") - version("3.1.5", sha256="6ae015467dabf0469b139ada93319327be24b98251ffaeceda0221848dc09262") - version("3.0.13", sha256="88525753f79d3bec27d2fa7c66aa0b92b3aa9498dafd93d7cfa4b3780cdae313") + version("3.3.1", sha256="777cd596284c883375a2a7a11bf5d2786fc5413255efab20c50d6ffe6d020b7e") + version("3.2.2", sha256="197149c18d9e9f292c43f0400acaba12e5f52cacfe050f3d199277ea738ec2e7") + version("3.1.6", sha256="5d2be4036b478ef3cb0a854ca9b353072c3a0e26d8a56f8f0ab9fb6ed32d38d7") + version("3.0.14", sha256="eeca035d4dd4e84fc25846d952da6297484afa0650a6f84c682e39df3a4123ca") version( - "3.1.3", - sha256="f0316a2ebd89e7f2352976445458689f80302093788c466692fb2a188b2eacf6", + "3.3.0", + sha256="53e66b043322a606abf0087e7699a0e033a37fa13feb9742df35c3a33b18fb02", deprecated=True, ) version( - "3.1.2", - sha256="a0ce69b8b97ea6a35b96875235aa453b966ba3cba8af2de23657d8b6767d6539", + "3.2.1", + sha256="83c7329fe52c850677d75e5d0b0ca245309b97e8ecbcfdc1dfdc4ab9fac35b39", deprecated=True, ) version( - "3.1.1", - sha256="b3aa61334233b852b63ddb048df181177c2c659eb9d4376008118f9c08d07674", + "3.1.5", + sha256="6ae015467dabf0469b139ada93319327be24b98251ffaeceda0221848dc09262", deprecated=True, ) version( - "3.1.0", - sha256="aaa925ad9828745c4cad9d9efeb273deca820f2cdcf2c3ac7d7c1212b7c497b4", - deprecated=True, - ) - version( - "3.0.11", - sha256="b3425d3bb4a2218d0697eb41f7fc0cdede016ed19ca49d168b78e8d947887f55", - deprecated=True, - ) - version( - "3.0.10", - sha256="1761d4f5b13a1028b9b6f3d4b8e17feb0cedc9370f6afe61d7193d2cdce83323", - deprecated=True, - ) - version( - "3.0.9", - sha256="eb1ab04781474360f77c318ab89d8c5a03abc38e63d65a603cabbf1b00a1dc90", - deprecated=True, - ) - version( - "3.0.8", - sha256="6c13d2bf38fdf31eac3ce2a347073673f5d63263398f1f69d0df4a41253e4b3e", - deprecated=True, - ) - version( - "3.0.7", - sha256="83049d042a260e696f62406ac5c08bf706fd84383f945cf21bd61e9ed95c396e", - deprecated=True, - ) - version( - "3.0.5", - sha256="aa7d8d9bef71ad6525c55ba11e5f4397889ce49c2c9349dcea6d3e4f0b024a7a", - deprecated=True, - ) - version( - "3.0.4", - sha256="2831843e9a668a0ab478e7020ad63d2d65e51f72977472dc73efcefbafc0c00f", - deprecated=True, - ) - version( - "3.0.2", - sha256="98e91ccead4d4756ae3c9cde5e09191a8e586d9f4d50838e7ec09d6411dfdb63", - deprecated=True, - ) - version( - "3.0.1", - sha256="c311ad853353bce796edad01a862c50a8a587f62e7e2100ef465ab53ec9b06d1", - deprecated=True, - ) - version( - "3.0.0", - sha256="59eedfcb46c25214c9bd37ed6078297b4df01d012267fe9e9eee31f61bc70536", + "3.0.13", + sha256="88525753f79d3bec27d2fa7c66aa0b92b3aa9498dafd93d7cfa4b3780cdae313", deprecated=True, ) + version( "1.1.1w", sha256="cf3098950cb4d853ad95c0841f1f9c6d3dc102dccfcacd521d93925208b76ac8", deprecated=True, ) - version( - "1.1.1v", - sha256="d6697e2871e77238460402e9362d47d18382b15ef9f246aba6c7bd780d38a6b0", - deprecated=True, - ) - version( - "1.1.1u", - sha256="e2f8d84b523eecd06c7be7626830370300fbcc15386bf5142d72758f6963ebc6", - deprecated=True, - ) - version( - "1.1.1t", - sha256="8dee9b24bdb1dcbf0c3d1e9b02fb8f6bf22165e807f45adeb7c9677536859d3b", - deprecated=True, - ) - version( - "1.1.1s", - sha256="c5ac01e760ee6ff0dab61d6b2bbd30146724d063eb322180c6f18a6f74e4b6aa", - deprecated=True, - ) - version( - "1.1.1q", - sha256="d7939ce614029cdff0b6c20f0e2e5703158a489a72b2507b8bd51bf8c8fd10ca", - deprecated=True, - ) - version( - "1.1.1p", - sha256="bf61b62aaa66c7c7639942a94de4c9ae8280c08f17d4eac2e44644d9fc8ace6f", - deprecated=True, - ) - version( - "1.1.1o", - sha256="9384a2b0570dd80358841464677115df785edb941c71211f75076d72fe6b438f", - deprecated=True, - ) - version( - "1.1.1n", - sha256="40dceb51a4f6a5275bde0e6bf20ef4b91bfc32ed57c0552e2e8e15463372b17a", - deprecated=True, - ) - version( - "1.1.1m", - sha256="f89199be8b23ca45fc7cb9f1d8d3ee67312318286ad030f5316aca6462db6c96", - deprecated=True, - ) - version( - "1.1.1l", - sha256="0b7a3e5e59c34827fe0c3a74b7ec8baef302b98fa80088d7f9153aa16fa76bd1", - deprecated=True, - ) - version( - "1.1.1k", - sha256="892a0875b9872acd04a9fde79b1f943075d5ea162415de3047c327df33fbaee5", - deprecated=True, - ) - version( - "1.1.1j", - sha256="aaf2fcb575cdf6491b98ab4829abf78a3dec8402b8b81efc8f23c00d443981bf", - deprecated=True, - ) - version( - "1.1.1i", - sha256="e8be6a35fe41d10603c3cc635e93289ed00bf34b79671a3a4de64fcee00d5242", - deprecated=True, - ) - version( - "1.1.1h", - sha256="5c9ca8774bd7b03e5784f26ae9e9e6d749c9da2438545077e6b3d755a06595d9", - deprecated=True, - ) - version( - "1.1.1g", - sha256="ddb04774f1e32f0c49751e21b67216ac87852ceb056b75209af2443400636d46", - deprecated=True, - ) - version( - "1.1.1f", - sha256="186c6bfe6ecfba7a5b48c47f8a1673d0f3b0e5ba2e25602dd23b629975da3f35", - deprecated=True, - ) - version( - "1.1.1e", - sha256="694f61ac11cb51c9bf73f54e771ff6022b0327a43bbdfa1b2f19de1662a6dcbe", - deprecated=True, - ) - version( - "1.1.1d", - sha256="1e3a91bc1f9dfce01af26026f856e064eab4c8ee0a8f457b5ae30b40b8b711f2", - deprecated=True, - ) - version( - "1.1.1c", - sha256="f6fb3079ad15076154eda9413fed42877d668e7069d9b87396d0804fdb3f4c90", - deprecated=True, - ) - version( - "1.1.1b", - sha256="5c557b023230413dfb0756f3137a13e6d726838ccd1430888ad15bfb2b43ea4b", - deprecated=True, - ) - version( - "1.1.1a", - sha256="fc20130f8b7cbd2fb918b2f14e2f429e109c31ddd0fb38fc5d71d9ffed3f9f41", - deprecated=True, - ) - version( - "1.1.1", - sha256="2836875a0f89c03d0fdf483941512613a50cfb421d6fd94b9f41d7279d586a3d", - deprecated=True, - ) - version( - "1.1.0l", - sha256="74a2f756c64fd7386a29184dc0344f4831192d61dc2481a93a4c5dd727f41148", - deprecated=True, - ) - version( - "1.1.0k", - sha256="efa4965f4f773574d6cbda1cf874dbbe455ab1c0d4f906115f867d30444470b1", - deprecated=True, - ) - version( - "1.1.0j", - sha256="31bec6c203ce1a8e93d5994f4ed304c63ccf07676118b6634edded12ad1b3246", - deprecated=True, - ) - version( - "1.1.0i", - sha256="ebbfc844a8c8cc0ea5dc10b86c9ce97f401837f3fa08c17b2cdadc118253cf99", - deprecated=True, - ) - version( - "1.1.0g", - sha256="de4d501267da39310905cb6dc8c6121f7a2cad45a7707f76df828fe1b85073af", - deprecated=True, - ) - version( - "1.1.0e", - sha256="57be8618979d80c910728cfc99369bf97b2a1abd8f366ab6ebdee8975ad3874c", - deprecated=True, - ) - version( - "1.1.0d", - sha256="7d5ebb9e89756545c156ff9c13cf2aa6214193b010a468a3bc789c3c28fe60df", - deprecated=True, - ) - version( - "1.1.0c", - sha256="fc436441a2e05752d31b4e46115eb89709a28aef96d4fe786abe92409b2fd6f5", - deprecated=True, - ) version( "1.0.2u", sha256="ecd0c6ffb493dd06707d38b14bb4d8c2288bb7033735606569d8f90f89669d16", deprecated=True, ) - version( - "1.0.2t", - sha256="14cb464efe7ac6b54799b34456bd69558a749a4931ecfd9cf9f71d7881cac7bc", - deprecated=True, - ) - version( - "1.0.2s", - sha256="cabd5c9492825ce5bd23f3c3aeed6a97f8142f606d893df216411f07d1abab96", - deprecated=True, - ) - version( - "1.0.2r", - sha256="ae51d08bba8a83958e894946f15303ff894d75c2b8bbd44a852b64e3fe11d0d6", - deprecated=True, - ) - version( - "1.0.2p", - sha256="50a98e07b1a89eb8f6a99477f262df71c6fa7bef77df4dc83025a2845c827d00", - deprecated=True, - ) - version( - "1.0.2o", - sha256="ec3f5c9714ba0fd45cb4e087301eb1336c317e0d20b575a125050470e8089e4d", - deprecated=True, - ) - version( - "1.0.2n", - sha256="370babb75f278c39e0c50e8c4e7493bc0f18db6867478341a832a982fd15a8fe", - deprecated=True, - ) - version( - "1.0.2m", - sha256="8c6ff15ec6b319b50788f42c7abc2890c08ba5a1cdcd3810eb9092deada37b0f", - deprecated=True, - ) - version( - "1.0.2k", - sha256="6b3977c61f2aedf0f96367dcfb5c6e578cf37e7b8d913b4ecb6643c3cb88d8c0", - deprecated=True, - ) - version( - "1.0.2j", - sha256="e7aff292be21c259c6af26469c7a9b3ba26e9abaaffd325e3dccc9785256c431", - deprecated=True, - ) - version( - "1.0.2i", - sha256="9287487d11c9545b6efb287cdb70535d4e9b284dd10d51441d9b9963d000de6f", - deprecated=True, - ) - version( - "1.0.2h", - sha256="1d4007e53aad94a5b2002fe045ee7bb0b3d98f1a47f8b2bc851dcd1c74332919", - deprecated=True, - ) - version( - "1.0.2g", - sha256="b784b1b3907ce39abf4098702dade6365522a253ad1552e267a9a0e89594aa33", - deprecated=True, - ) - version( - "1.0.2f", - sha256="932b4ee4def2b434f85435d9e3e19ca8ba99ce9a065a61524b429a9d5e9b2e9c", - deprecated=True, - ) - version( - "1.0.2e", - sha256="e23ccafdb75cfcde782da0151731aa2185195ac745eea3846133f2e05c0e0bff", - deprecated=True, - ) - version( - "1.0.2d", - sha256="671c36487785628a703374c652ad2cebea45fa920ae5681515df25d9f2c9a8c8", - deprecated=True, - ) - version( - "1.0.1u", - sha256="4312b4ca1215b6f2c97007503d80db80d5157f76f8f7d3febbe6b4c56ff26739", - deprecated=True, - ) - version( - "1.0.1t", - sha256="4a6ee491a2fdb22e519c76fdc2a628bb3cec12762cd456861d207996c8a07088", - deprecated=True, - ) - version( - "1.0.1r", - sha256="784bd8d355ed01ce98b812f873f8b2313da61df7c7b5677fcf2e57b0863a3346", - deprecated=True, - ) - version( - "1.0.1h", - sha256="9d1c8a9836aa63e2c6adb684186cbd4371c9e9dcc01d6e3bb447abf2d4d3d093", - deprecated=True, - ) - version( - "1.0.1e", - sha256="f74f15e8c8ff11aa3d5bb5f276d202ec18d7246e95f961db76054199c69c1ae3", - deprecated=True, - ) + + depends_on("c", type="build") # generated # On Cray DVS mounts, we can't make symlinks to /etc/ssl/openssl.cnf, # either due to a bug or because DVS is not intended to be POSIX compliant. @@ -376,12 +79,10 @@ class Openssl(Package): # Uses Fake Autotools, should subclass Package values=("mozilla", "system", "none"), multi=False, description=( - "Use certificates from the ca-certificates-mozilla " - "package, symlink system certificates, or use none, " - "respectively. The default is `mozilla`, since it is " - "system agnostic. Instead of picking certs=system, " - "one can mark openssl as an external package, to " - "avoid compiling openssl entirely." + "Use certificates from the ca-certificates-mozilla package, symlink system " + "certificates, or use none, respectively. The default is `mozilla`, since it is " + "system agnostic. Instead of picking certs=system, one can mark openssl as an " + "external package, to avoid compiling openssl entirely." ), ) variant("docs", default=False, description="Install docs and manpages") @@ -395,15 +96,8 @@ class Openssl(Package): # Uses Fake Autotools, should subclass Package depends_on("nasm", when="platform=windows") depends_on("gmake", type="build", when="platform=linux") - depends_on("gmake", type="build", when="platform=cray") depends_on("gmake", type="build", when="platform=darwin") - patch( - "https://github.com/openssl/openssl/commit/f9e578e720bb35228948564192adbe3bc503d5fb.patch?full_index=1", - sha256="3fdcf2d1e47c34f3a012f23306322c5a35cad55b180c9b6fb34537b55884645c", - when="@1.1.1q", - ) - @classmethod def determine_version(cls, exe): output = Executable(exe)("version", output=str, error=str) diff --git a/var/spack/repos/builtin/packages/opensta/package.py b/var/spack/repos/builtin/packages/opensta/package.py index 7b6db1c532adf3..6dea137c243079 100644 --- a/var/spack/repos/builtin/packages/opensta/package.py +++ b/var/spack/repos/builtin/packages/opensta/package.py @@ -28,6 +28,8 @@ class Opensta(CMakePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + variant("zlib", default=True, description="build with zlib support") variant("cudd", default=True, description="build with cudd support") diff --git a/var/spack/repos/builtin/packages/opensubdiv/package.py b/var/spack/repos/builtin/packages/opensubdiv/package.py index 32399f546da45d..b526ef9a1e5d16 100644 --- a/var/spack/repos/builtin/packages/opensubdiv/package.py +++ b/var/spack/repos/builtin/packages/opensubdiv/package.py @@ -26,6 +26,8 @@ class Opensubdiv(CMakePackage, CudaPackage): version("3.4.3", sha256="7b22eb27d636ab0c1e03722c7a5a5bd4f11664ee65c9b48f341a6d0ce7f36745") version("3.4.0", sha256="d932b292f83371c7518960b2135c7a5b931efb43cdd8720e0b27268a698973e4") + depends_on("cxx", type="build") # generated + def url_for_version(self, version): url = "https://github.com/PixarAnimationStudios/OpenSubdiv/archive/v{0}.tar.gz" return url.format(version.underscored) diff --git a/var/spack/repos/builtin/packages/openturns/package.py b/var/spack/repos/builtin/packages/openturns/package.py index d5e0d5d1a2921e..ba002881d91559 100644 --- a/var/spack/repos/builtin/packages/openturns/package.py +++ b/var/spack/repos/builtin/packages/openturns/package.py @@ -27,6 +27,9 @@ class Openturns(CMakePackage): version("1.19", sha256="1d61cb6ce8ec1121db9f1e9fb490aaa056d2ff250db26df05d2e3e30ceb32344") version("1.18", sha256="1840d3fd8b38fd5967b1fa04e49d8f760c2c497400430e97623595ca48754ae0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("python", default=True, description="Build Python bindings") variant("libxml2", default=False, description="Use LibXML2 for XML support") diff --git a/var/spack/repos/builtin/packages/openvdb/package.py b/var/spack/repos/builtin/packages/openvdb/package.py index 293839704f79be..0ef4cbb354bfe3 100644 --- a/var/spack/repos/builtin/packages/openvdb/package.py +++ b/var/spack/repos/builtin/packages/openvdb/package.py @@ -28,6 +28,8 @@ class Openvdb(CMakePackage): version("8.0.1", sha256="a6845da7c604d2c72e4141c898930ac8a2375521e535f696c2cd92bebbe43c4f") version("7.1.0", sha256="0c3588c1ca6e647610738654ec2c6aaf41a203fd797f609fbeab1c9f7c3dc116") + depends_on("cxx", type="build") # generated + # these variants were for 8.0.1 and probably could be updated... variant("shared", default=True, description="Build as a shared library.") variant("python", default=False, description="Build the pyopenvdb python extension.") diff --git a/var/spack/repos/builtin/packages/openvkl/package.py b/var/spack/repos/builtin/packages/openvkl/package.py index 8fee89b37b805d..165c5b39b26462 100644 --- a/var/spack/repos/builtin/packages/openvkl/package.py +++ b/var/spack/repos/builtin/packages/openvkl/package.py @@ -14,10 +14,9 @@ class Openvkl(CMakePackage): url = "https://www.github.com/OpenVKL/openvkl/archive/v1.0.0.tar.gz" git = "https://www.github.com/OpenVKL/openvkl.git" - # maintainers("github_user1", "github_user2") - license("Apache-2.0") + version("2.0.1", sha256="0c7faa9582a93e93767afdb15a6c9c9ba154af7ee83a6b553705797be5f8af62") version("2.0.0", sha256="469c3fba254c4fcdd84f8a9763d2e1aaa496dc123b5a9d467cc0a561e284c4e6") version("1.3.2", sha256="7704736566bf17497a3e51c067bd575316895fda96eccc682dae4aac7fb07b28") version("1.3.1", sha256="c9cefb6c313f2b4c0331e9629931759a6bc204ec00deed6ec0becad1670a1933") @@ -28,6 +27,9 @@ class Openvkl(CMakePackage): version("1.0.0", sha256="81ccae679bfa2feefc4d4b1ce72bcd242ba34d2618fbb418a1c2a05d640d16b4") version("0.13.0", sha256="974608259e3a5d8e29d2dfe81c6b2b1830aadeb9bbdc87127f3a7c8631e9f1bd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("embree@4", when="@1.3.2:") depends_on("embree@3.13.0:3", when="@:1.3.1") depends_on("embree@3.13.1:", when="@1.0.0:") diff --git a/var/spack/repos/builtin/packages/openwsman/package.py b/var/spack/repos/builtin/packages/openwsman/package.py index 4be921bad99c57..d9cdb2f80b0c6d 100644 --- a/var/spack/repos/builtin/packages/openwsman/package.py +++ b/var/spack/repos/builtin/packages/openwsman/package.py @@ -17,6 +17,9 @@ class Openwsman(CMakePackage): version("2.6.11", sha256="895eaaae62925f9416766ea3e71a5368210e6cfe13b23e4e0422fa0e75c2541c") version("2.6.10", sha256="d3c624a03d7bc1835544ce1af56efd010f77cbee0c02b34e0755aa9c9b2c317b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("python", default=True, description="Enable python") extends("python", when="+python") @@ -31,13 +34,9 @@ class Openwsman(CMakePackage): def patch(self): """Change python install directory.""" if self.spec.satisfies("+python"): - python_spec = self.spec["python"] - python_libdir = join_path( - self.spec.prefix.lib, "python" + str(python_spec.version.up_to(2)), "site-packages" - ) filter_file( "DESTINATION .*", - "DESTINATION {0} )".format(python_libdir), + "DESTINATION {0} )".format(python_platlib), join_path("bindings", "python", "CMakeLists.txt"), ) diff --git a/var/spack/repos/builtin/packages/ophidia-analytics-framework/package.py b/var/spack/repos/builtin/packages/ophidia-analytics-framework/package.py index 443ecb3df542a5..dfc990efbd64ca 100644 --- a/var/spack/repos/builtin/packages/ophidia-analytics-framework/package.py +++ b/var/spack/repos/builtin/packages/ophidia-analytics-framework/package.py @@ -18,6 +18,8 @@ class OphidiaAnalyticsFramework(AutotoolsPackage): sha256="565050b90ce1cefc59136c835a335ca7981fec792df7a1ee9309b24c05b275d6", deprecated=True, ) + + depends_on("c", type="build") # generated depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/ophidia-io-server/package.py b/var/spack/repos/builtin/packages/ophidia-io-server/package.py index c9215b0f6df0fd..1d98f78271b24b 100644 --- a/var/spack/repos/builtin/packages/ophidia-io-server/package.py +++ b/var/spack/repos/builtin/packages/ophidia-io-server/package.py @@ -18,6 +18,8 @@ class OphidiaIoServer(AutotoolsPackage): sha256="8b203c44e0e5497c00f1fdb2322f0b0a41f36900b62a33d95a4570ae1ccc2971", deprecated=True, ) + + depends_on("c", type="build") # generated depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/ophidia-primitives/package.py b/var/spack/repos/builtin/packages/ophidia-primitives/package.py index 5e010251f46a52..636854421d7a77 100644 --- a/var/spack/repos/builtin/packages/ophidia-primitives/package.py +++ b/var/spack/repos/builtin/packages/ophidia-primitives/package.py @@ -14,6 +14,8 @@ class OphidiaPrimitives(AutotoolsPackage): maintainers("eldoo", "SoniaScard") version("1.7.1", sha256="efec5248dca8fb766abcd536344eefbe2e970fb551f03454a968e59e2df69116") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/ophidia-server/package.py b/var/spack/repos/builtin/packages/ophidia-server/package.py index 174e68dafb4d2b..c300b2100cb19b 100644 --- a/var/spack/repos/builtin/packages/ophidia-server/package.py +++ b/var/spack/repos/builtin/packages/ophidia-server/package.py @@ -14,6 +14,8 @@ class OphidiaServer(AutotoolsPackage): maintainers("eldoo", "SoniaScard") version("1.7.4", sha256="30128c99ae089ab766141397ea5098ac930cfe10d09b289ed120f6581d8bb07d") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/opium/package.py b/var/spack/repos/builtin/packages/opium/package.py index 277acc74de431c..73ab47cd786227 100644 --- a/var/spack/repos/builtin/packages/opium/package.py +++ b/var/spack/repos/builtin/packages/opium/package.py @@ -17,6 +17,9 @@ class Opium(AutotoolsPackage): version("4.1", sha256="e5a102b52601ad037d8a7b3e2dbd295baad23b8c1e4908b9014df2e432c23c60") version("3.8", sha256="edee6606519330aecaee436ee8cfb0a33788b5677861d59e38aba936e87d5ad3") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("external-lapack", default=False, description="Links to externally installed LAPACK") depends_on("lapack", when="+external-lapack") diff --git a/var/spack/repos/builtin/packages/optional-lite/package.py b/var/spack/repos/builtin/packages/optional-lite/package.py index 3b09e935bdd2a3..b3ed4112cdf131 100644 --- a/var/spack/repos/builtin/packages/optional-lite/package.py +++ b/var/spack/repos/builtin/packages/optional-lite/package.py @@ -30,6 +30,8 @@ class OptionalLite(CMakePackage): version("2.0.0", sha256="e8d803cbc7be241df41a9ab267b525b7941df09747cd5a7deb55f863bd8a4e8d") version("1.0.3", sha256="7a2fb0fe20d61d091f6730237add9bab58bc0df1288cb96f3e8a61b859539067") + depends_on("cxx", type="build") # generated + def cmake_args(self): return [ f"-DOPTIONAL_LITE_OPT_BUILD_TESTS={'ON' if self.run_tests else 'OFF'}", diff --git a/var/spack/repos/builtin/packages/optipng/package.py b/var/spack/repos/builtin/packages/optipng/package.py index ebef46e2ae958d..40ee730f19c3bc 100644 --- a/var/spack/repos/builtin/packages/optipng/package.py +++ b/var/spack/repos/builtin/packages/optipng/package.py @@ -20,5 +20,8 @@ class Optipng(AutotoolsPackage, SourceforgePackage): license("Zlib") version("0.7.7", sha256="4f32f233cef870b3f95d3ad6428bfe4224ef34908f1b42b0badf858216654452") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated # See https://github.com/imagemin/optipng-bin/issues/97 patch("for_aarch64.patch", when="target=aarch64:") diff --git a/var/spack/repos/builtin/packages/opus/package.py b/var/spack/repos/builtin/packages/opus/package.py index 211fd6b7cf576a..4cfc0b897be110 100644 --- a/var/spack/repos/builtin/packages/opus/package.py +++ b/var/spack/repos/builtin/packages/opus/package.py @@ -14,7 +14,15 @@ class Opus(AutotoolsPackage): license("BSD-3-Clause") + version("1.5.2", sha256="65c1d2f78b9f2fb20082c38cbe47c951ad5839345876e46941612ee87f9a7ce1") + version("1.5.1", sha256="b84610959b8d417b611aa12a22565e0a3732097c6389d19098d844543e340f85") + version("1.5", sha256="d8230bbeb99e6d558645aaad25d79de8f4f28fdcc55f8af230050586d62c4f2c") + version("1.4", sha256="c9b32b4253be5ae63d1ff16eea06b94b5f0f2951b7a02aceef58e3a3ce49c51f") version("1.3.1", sha256="65b58e1e25b2a114157014736a3d9dfeaad8d41be1c8179866f144a2fb44ff9d") + version("1.3", sha256="4f3d69aefdf2dbaf9825408e452a8a414ffc60494c70633560700398820dc550") + version("1.2.1", sha256="cfafd339ccd9c5ef8d6ab15d7e1a412c054bf4cb4ecbbbcc78c12ef2def70732") + version("1.2", sha256="77db45a87b51578fbc49555ef1b10926179861d854eb2613207dc79d9ec0a9a9") + version("1.1.5", sha256="eb84981ca0f40a3e5d5e58d2e8582cb2fee05a022825a6dfe14d14b04eb563e4") version("1.1.4", sha256="9122b6b380081dd2665189f97bfd777f04f92dc3ab6698eea1dbb27ad59d8692") version("1.1.3", sha256="58b6fe802e7e30182e95d0cde890c0ace40b6f125cffc50635f0ad2eef69b633") version("1.1.2", sha256="0e290078e31211baa7b5886bcc8ab6bc048b9fc83882532da4a1a45e58e907fd") @@ -36,4 +44,4 @@ class Opus(AutotoolsPackage): version("0.9.1", sha256="206221afc47b87496588013bd4523e1e9f556336c0813f4372773fc536dd4293") version("0.9.0", sha256="b2f75c4ac5ab837845eb028413fae2a28754bfb0a6d76416e2af1441ef447649") - depends_on("libvorbis") + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/or-tools/package.py b/var/spack/repos/builtin/packages/or-tools/package.py index 922b849d443588..138d8d7cea915c 100644 --- a/var/spack/repos/builtin/packages/or-tools/package.py +++ b/var/spack/repos/builtin/packages/or-tools/package.py @@ -19,6 +19,8 @@ class OrTools(CMakePackage): license("Apache-2.0") version("7.8", sha256="d93a9502b18af51902abd130ff5f23768fcf47e266e6d1f34b3586387aa2de68") + + depends_on("cxx", type="build") # generated variant("coin", default=False, description="Enable COIN-OR solvers.") depends_on("cmake@3.14:", type="build") depends_on("gflags@2.2.2:") diff --git a/var/spack/repos/builtin/packages/orbit2/package.py b/var/spack/repos/builtin/packages/orbit2/package.py index 597e229a0844a5..a911b64a676ee1 100644 --- a/var/spack/repos/builtin/packages/orbit2/package.py +++ b/var/spack/repos/builtin/packages/orbit2/package.py @@ -17,6 +17,8 @@ class Orbit2(AutotoolsPackage): version("2.14.19", sha256="55c900a905482992730f575f3eef34d50bda717c197c97c08fa5a6eafd857550") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("glib") depends_on("libidl") diff --git a/var/spack/repos/builtin/packages/orc/package.py b/var/spack/repos/builtin/packages/orc/package.py index b07b5abe0ff922..1c3487cb1a08b2 100644 --- a/var/spack/repos/builtin/packages/orc/package.py +++ b/var/spack/repos/builtin/packages/orc/package.py @@ -16,6 +16,8 @@ class Orc(CMakePackage): version("1.6.5", sha256="df5885db8fa2e4435db8d486c6c7fc4e2c565d6197eee27729cf9cbdf36353c0") + depends_on("cxx", type="build") # generated + depends_on("maven") depends_on("openssl") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/orca/package.py b/var/spack/repos/builtin/packages/orca/package.py index d5c111c8180e35..d2e47fb334e4ad 100644 --- a/var/spack/repos/builtin/packages/orca/package.py +++ b/var/spack/repos/builtin/packages/orca/package.py @@ -18,64 +18,37 @@ class Orca(Package): set up a mirror, see https://spack.readthedocs.io/en/latest/mirrors.html""" homepage = "https://cec.mpg.de" - url = "file://{0}/orca_4_0_1_2_linux_x86-64_openmpi202.tar.zst".format(os.getcwd()) maintainers("snehring") manual_download = True license("LGPL-2.1-or-later") - version( - "5.0.3", - sha256="b8b9076d1711150a6d6cb3eb30b18e2782fa847c5a86d8404b9339faef105043", - url="file://{0}/orca_5_0_3_linux_x86-64_shared_openmpi411.tar.xz".format(os.getcwd()), - ) - version( - "4.2.1", - sha256="9bbb3bfdca8220b417ee898b27b2885508d8c82799adfa63dde9e72eab49a6b2", - expand=False, - ) - version( - "4.2.0", - sha256="55a5ca5aaad03396ac5ada2f14b61ffa735fdc2d98355e272465e07a6749d399", - expand=False, - ) - version( - "4.0.1.2", - sha256="cea442aa99ec0d7ffde65014932196b62343f7a6191b4bfc438bfb38c03942f7", - expand=False, - ) + version("5.0.4", sha256="c4ea5aea60da7bcb18a6b7042609206fbeb2a765c6fa958c5689d450b588b036") + version("5.0.3", sha256="b8b9076d1711150a6d6cb3eb30b18e2782fa847c5a86d8404b9339faef105043") + version("4.2.1", sha256="a84b6d2706f0ddb2f3750951864502a5c49d081836b00164448b1d81c577f51a") + version("4.2.0", sha256="01096466e41a5232e5a18af7400e48c02a6e489f0d5d668a90cdd2746e8e22e2") - depends_on("zstd", when="@:4.2.1", type="build") depends_on("libevent", type="run") depends_on("libpciaccess", type="run") # Map Orca version with the required OpenMPI version - openmpi_versions = {"4.0.1.2": "2.0.2", "4.2.0": "3.1.4", "4.2.1": "3.1.4", "5.0.3": "4.1.2"} + # OpenMPI@4.1.1 has issues in pmix environments, hence 4.1.2 here + openmpi_versions = {"4.2.0": "3.1.4", "4.2.1": "3.1.4", "5.0.3": "4.1.2", "5.0.4": "4.1.2"} for orca_version, openmpi_version in openmpi_versions.items(): depends_on( "openmpi@{0}".format(openmpi_version), type="run", when="@{0}".format(orca_version) ) def url_for_version(self, version): - out = "file://{0}/orca_{1}_linux_x86-64_openmpi{2}.tar.zst" - return out.format(os.getcwd(), version.underscored, self.openmpi_versions[version.string]) + openmpi_version = self.openmpi_versions[str(version.dotted)].replace(".", "") + if openmpi_version == "412": + openmpi_version = "411" + return f"file://{os.getcwd()}/orca_{version.underscored}_linux_x86-64_shared_openmpi{openmpi_version}.tar.xz" def install(self, spec, prefix): mkdirp(prefix.bin) - if self.spec.satisfies("@:4.2.1"): - vername = os.path.basename(self.stage.archive_file).split(".")[0] - - zstd = which("zstd") - zstd("-d", self.stage.archive_file, "-o", vername + ".tar") - - tar = which("tar") - tar("-xvf", vername + ".tar") - - # there are READMEs in there but they don't hurt anyone - install_tree(vername, prefix.bin) - else: - install_tree(".", prefix.bin) + install_tree(".", prefix.bin) # Check "mpirun" usability when building against OpenMPI # with Slurm scheduler and add a "mpirun" wrapper that diff --git a/var/spack/repos/builtin/packages/orfm/package.py b/var/spack/repos/builtin/packages/orfm/package.py index 3b87e6084278ba..9aeb4ada490aff 100644 --- a/var/spack/repos/builtin/packages/orfm/package.py +++ b/var/spack/repos/builtin/packages/orfm/package.py @@ -17,4 +17,6 @@ class Orfm(AutotoolsPackage): version("0.7.1", sha256="19f39c72bcc48127b757613c5eef4abae95ee6c82dccf96b041db527b27f319a") + depends_on("c", type="build") # generated + depends_on("zlib-api", type="link") diff --git a/var/spack/repos/builtin/packages/orthofinder/package.py b/var/spack/repos/builtin/packages/orthofinder/package.py index c0e1b45cb1b893..df79d4e30291b7 100644 --- a/var/spack/repos/builtin/packages/orthofinder/package.py +++ b/var/spack/repos/builtin/packages/orthofinder/package.py @@ -54,7 +54,7 @@ class Orthofinder(Package): depends_on("blast-plus", type="run", when="+blast") depends_on("mmseqs2", type="run", when="+mmseqs2") depends_on("muscle5", type="run", when="+muscle") - depends_on("iqtree2", type="run", when="+iqtree") + depends_on("iq-tree@2", type="run", when="+iqtree") depends_on("raxml", type="run", when="+raxml") depends_on("raxml-ng", type="run", when="+raxml-ng") diff --git a/var/spack/repos/builtin/packages/osg-ca-certs/package.py b/var/spack/repos/builtin/packages/osg-ca-certs/package.py index fa87cb10ccd5a8..7a36212ac64bd7 100644 --- a/var/spack/repos/builtin/packages/osg-ca-certs/package.py +++ b/var/spack/repos/builtin/packages/osg-ca-certs/package.py @@ -11,9 +11,8 @@ class OsgCaCerts(Package): in the OpenSSL 1.0.* format.""" homepage = "http://repo.opensciencegrid.org/cadist" - url = "https://github.com/opensciencegrid/osg-certificates/archive/v1.109.igtf.1.117/osg-certificates-1.109.igtf.1.117.tar.gz" + git = "https://github.com/opensciencegrid/osg-certificates.git" - _osg_base_url = "https://github.com/opensciencegrid/osg-certificates/archive/v{osg_version}.igtf.{igtf_version}/osg-certificates-{osg_version}.igtf.{igtf_version}.tar.gz" _igtf_base_url = "https://dist.eugridpma.info/distribution/igtf/{igtf_version}/igtf-policy-installation-bundle-{igtf_version}.tar.gz" _letsencrypt_base_url = "https://github.com/opensciencegrid/letsencrypt-certificates/archive/v{letsencrypt_version}/letsencrypt-certificates.tar.gz" @@ -21,29 +20,17 @@ class OsgCaCerts(Package): releases = [ { - "osg_version": "1.110", - "igtf_version": "1.119", - "osg_sha256": "025969d415bf27c1609699caf63d0d79540a01df500187195f2bd973fe69e00d", - "igtf_sha256": "cc4db07a86fc27f0e0dfd15c797d1a0da7b5620f4b611dbb686543712b2f335a", - }, - { - "osg_version": "1.109", - "igtf_version": "1.117", - "osg_sha256": "41e12c05aedb4df729bf326318cc29b9b79eb097564fd68c6af2e1448ec74f75", - "igtf_sha256": "130d4d95cd65d01d2db250ee24c539341e3adc899b7eff1beafef1ba4674807d", - }, + "osg_version": "1.119", + "igtf_version": "1.128", + "osg_commit": "1f7abbe392e339aae28625a4016bc98d58ad7cab", + "igtf_sha256": "1385e2206b4088cbad94264e2c252ad431f075f88a427cdee4ed523df95b9ab7", + } ] for release in releases: _version = "{0}.igtf.{1}".format(release["osg_version"], release["igtf_version"]) - version( - _version, - url=_osg_base_url.format( - osg_version=release["osg_version"], igtf_version=release["igtf_version"] - ), - sha256=release["osg_sha256"], - ) + version(_version, commit=release["osg_commit"]) resource( name="igtf-{igtf_version}".format(igtf_version=release["igtf_version"]), diff --git a/var/spack/repos/builtin/packages/osi/package.py b/var/spack/repos/builtin/packages/osi/package.py index 83e12ebe3a7c8e..a29a9fea0f9e67 100644 --- a/var/spack/repos/builtin/packages/osi/package.py +++ b/var/spack/repos/builtin/packages/osi/package.py @@ -30,4 +30,6 @@ class Osi(AutotoolsPackage): version("0.108.7", sha256="f1bc53a498585f508d3f8d74792440a30a83c8bc934d0c8ecf8cd8bc0e486228") version("0.108.6", sha256="984a5886825e2da9bf44d8a665f4b92812f0700e451c12baf9883eaa2315fad5") + depends_on("cxx", type="build") # generated + build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/osmctools/package.py b/var/spack/repos/builtin/packages/osmctools/package.py index a322d470db6d3a..c78837343c2a6f 100644 --- a/var/spack/repos/builtin/packages/osmctools/package.py +++ b/var/spack/repos/builtin/packages/osmctools/package.py @@ -18,6 +18,8 @@ class Osmctools(AutotoolsPackage): version("0.9", sha256="2f5298be5b4ba840a04f360c163849b34a31386ccd287657885e21268665f413") version("0.8", sha256="54ae48717afd05707c9b1fd750dd56c33c3bae0755424ce8ca3795ee28e0ece8") + depends_on("c", type="build") # generated + depends_on("zlib-api") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/osmesa/package.py b/var/spack/repos/builtin/packages/osmesa/package.py index b42564cc9c0126..682032655bccf7 100644 --- a/var/spack/repos/builtin/packages/osmesa/package.py +++ b/var/spack/repos/builtin/packages/osmesa/package.py @@ -13,20 +13,20 @@ class Osmesa(BundlePackage): version("11.2.0") - depends_on("libosmesa") + depends_on("mesa+osmesa") provides("gl@4.5") @property def home(self): - return self.spec["libosmesa"].home + return self.spec["mesa"].home @property def headers(self): - return self.spec["libosmesa"].headers + return self.spec["mesa"].package.libosmesa_headers @property def libs(self): - return self.spec["libosmesa"].libs + return self.spec["mesa"].package.libosmesa_libs @property def gl_headers(self): @@ -34,4 +34,4 @@ def gl_headers(self): @property def gl_libs(self): - return self.spec["libosmesa"].libs + return self.spec["mesa"].package.libosmesa_libs diff --git a/var/spack/repos/builtin/packages/ospray/package.py b/var/spack/repos/builtin/packages/ospray/package.py index e49bbf83ec0f9d..7dd9541cf1a21d 100644 --- a/var/spack/repos/builtin/packages/ospray/package.py +++ b/var/spack/repos/builtin/packages/ospray/package.py @@ -16,6 +16,7 @@ class Ospray(CMakePackage): # maintainers("aumuell") + version("3.1.0", sha256="0b9d7df900fe0474b12e5a2641bb9c3f5a1561217b2789834ebf994a15288a82") version("3.0.0", sha256="d8d8e632d77171c810c0f38f8d5c8387470ca19b75f5b80ad4d3d12007280288") version("2.12.0", sha256="268b16952b2dd44da2a1e40d2065c960bc2442dd09b63ace8b65d3408f596301") version("2.11.0", sha256="55974e650d9b78989ee55adb81cffd8c6e39ce5d3cf0a3b3198c522bf36f6e81") @@ -26,6 +27,9 @@ class Ospray(CMakePackage): version("2.7.0", sha256="bcaeb221b5dd383d27587ffaca7f75d7e0064f64017a0d73df90862b14b5704b") version("2.6.0", sha256="5efccd7eff5774b77f8894e68a6b803b535a0d12f32ab49edf13b954e2848f2e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("apps", default=False, description="Enable building OSPRay Apps") variant("denoiser", default=True, description="Enable denoiser image operation") variant("glm", default=False, description="Build ospray_cpp GLM tests/tutorial") @@ -40,6 +44,7 @@ class Ospray(CMakePackage): depends_on("rkcommon@1.10:", when="@2.10.0:") depends_on("rkcommon@1.11:", when="@2.11:") depends_on("rkcommon@1.12:", when="@3:") + depends_on("rkcommon@1.13:", when="@3.1:") depends_on("embree@3.12: +ispc") depends_on("embree@3.13.1:", when="@2.7.0:") depends_on("embree@:3", when="@:2.10") diff --git a/var/spack/repos/builtin/packages/osqp/package.py b/var/spack/repos/builtin/packages/osqp/package.py index 9fb9614d374898..8506e50949337e 100644 --- a/var/spack/repos/builtin/packages/osqp/package.py +++ b/var/spack/repos/builtin/packages/osqp/package.py @@ -22,3 +22,5 @@ class Osqp(CMakePackage): version("master", branch="master", submodules=True) version("0.6.0", commit="0baddd36bd57ec1cace0a52c6dd9663e8f16df0a", submodules=True) version("0.5.0", commit="97050184aa2cbebe446ae02d1f8b811243e180d6", submodules=True) + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/ossp-uuid/package.py b/var/spack/repos/builtin/packages/ossp-uuid/package.py index 24dd3c08092cb7..24029387f52186 100644 --- a/var/spack/repos/builtin/packages/ossp-uuid/package.py +++ b/var/spack/repos/builtin/packages/ossp-uuid/package.py @@ -19,6 +19,9 @@ class OsspUuid(AutotoolsPackage): version("1.6.2", sha256="11a615225baa5f8bb686824423f50e4427acd3f70d394765bdff32801f0fd5b0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + provides("uuid") @property diff --git a/var/spack/repos/builtin/packages/osu-micro-benchmarks/package.py b/var/spack/repos/builtin/packages/osu-micro-benchmarks/package.py index 0eaad99082c533..bf2c2e505dc20c 100644 --- a/var/spack/repos/builtin/packages/osu-micro-benchmarks/package.py +++ b/var/spack/repos/builtin/packages/osu-micro-benchmarks/package.py @@ -20,6 +20,7 @@ class OsuMicroBenchmarks(AutotoolsPackage, CudaPackage, ROCmPackage): maintainers("natshineman", "harisubramoni", "MatthewLieber") + version("7.4", sha256="1edd0c2efa61999409bfb28740a7f39689a5b42b1a1b4c66d1656e5637f7cefc") version("7.3", sha256="8fa25b8aaa34e4b07ab3a4f30b7690ab46b038b08d204a853a9b6aa7bdb02f2f") version("7.2", sha256="1a4e1f2aab0e65404b3414e23bd46616184b69b6231ce9313d9c630bd6e633c1") version("7.1-1", sha256="85f4dd8be1df31255e232852769ae5b82e87a5fb14be2f8eba1ae9de8ffe391a") @@ -43,6 +44,9 @@ class OsuMicroBenchmarks(AutotoolsPackage, CudaPackage, ROCmPackage): version("5.4", sha256="e1ca762e13a07205a59b59ad85e85ce0f826b70f76fd555ce5568efb1f2a8f33") version("5.3", sha256="d7b3ad4bee48ac32f5bef39650a88f8f2c23a3050b17130c63966283edced89b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("mpi") variant("papi", description="Enable/Disable support for papi", default=False) variant("graphing", description="Enable/Disable support for graphing", default=False) diff --git a/var/spack/repos/builtin/packages/otf/package.py b/var/spack/repos/builtin/packages/otf/package.py index 757d34d08af3d6..56bfddac03f586 100644 --- a/var/spack/repos/builtin/packages/otf/package.py +++ b/var/spack/repos/builtin/packages/otf/package.py @@ -22,6 +22,9 @@ class Otf(AutotoolsPackage): "1.12.5salmon", sha256="0a8427360dedb38e8ddca30f14d95f826420c550337c5a79dbb754904e194088" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/otf2/package.py b/var/spack/repos/builtin/packages/otf2/package.py index 60d55d097cb170..ff16ea5dd4bdee 100644 --- a/var/spack/repos/builtin/packages/otf2/package.py +++ b/var/spack/repos/builtin/packages/otf2/package.py @@ -59,21 +59,24 @@ class Otf2(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): if version < Version("2.3"): - return "https://www.vi-hps.org/cms/upload/packages/otf2/otf2-{0}.tar.gz".format( - version - ) + return f"https://www.vi-hps.org/cms/upload/packages/otf2/otf2-{version}.tar.gz" + + return f"https://perftools.pages.jsc.fz-juelich.de/cicd/otf2/tags/otf2-{version}/otf2-{version}.tar.gz" - return "https://perftools.pages.jsc.fz-juelich.de/cicd/otf2/tags/otf2-{0}/otf2-{0}.tar.gz".format( - version - ) + extends("python") + + # `imp` module required + depends_on("python@:3.11", type=("build", "run")) with when("@2.2 %cce"): depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") - depends_on("m4", type="build") # Fix missing initialization of variable resulting in issues when used by # APEX/HPX: https://github.com/STEllAR-GROUP/hpx/issues/5239 @@ -86,14 +89,19 @@ def url_for_version(self, version): def force_autoreconf(self): return self.spec.satisfies("@2.2 %cce") + def flag_handler(self, name, flags): + if name == "cflags": + flags.append(self.compiler.cc_pic_flag) + elif name == "cxxflags": + flags.append(self.compiler.cxx_pic_flag) + return (flags, None, None) + def configure_args(self): return [ "--enable-shared", - "CC={0}".format(spack_cc), - "CXX={0}".format(spack_cxx), - "F77={0}".format(spack_f77), - "FC={0}".format(spack_fc), - "CFLAGS={0}".format(self.compiler.cc_pic_flag), - "CXXFLAGS={0}".format(self.compiler.cxx_pic_flag), + f"CC={spack_cc}", + f"CXX={spack_cxx}", + f"F77={spack_f77}", + f"FC={spack_fc}", "PYTHON_FOR_GENERATOR=:", ] diff --git a/var/spack/repos/builtin/packages/p11-kit/package.py b/var/spack/repos/builtin/packages/p11-kit/package.py index 685d6aede57652..b46bb62fac6b9e 100644 --- a/var/spack/repos/builtin/packages/p11-kit/package.py +++ b/var/spack/repos/builtin/packages/p11-kit/package.py @@ -24,6 +24,8 @@ class P11Kit(AutotoolsPackage): version("0.23.20", sha256="8f6116f34735f6902e9db461c5dbe3e7e25b5cb8c38f42ea2a5aede1cf693749") version("0.23.19", sha256="c27921404e82244d97b27f46bae654e5814b5963e0ce3c75ad37007ded46f700") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/p3dfft3/package.py b/var/spack/repos/builtin/packages/p3dfft3/package.py index dc82a5ad273290..11427f1f8e1ea3 100644 --- a/var/spack/repos/builtin/packages/p3dfft3/package.py +++ b/var/spack/repos/builtin/packages/p3dfft3/package.py @@ -20,6 +20,10 @@ class P3dfft3(AutotoolsPackage): version("develop", branch="master") version("3.0.0", sha256="1c549e78097d1545d18552b039be0d11cdb96be46efe99a16b65fd5d546dbfa7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fftw", default=True, description="Builds with FFTW library") variant("essl", default=False, description="Builds with ESSL library") variant("mpi", default=True, description="Enable MPI support.") diff --git a/var/spack/repos/builtin/packages/p4est/package.py b/var/spack/repos/builtin/packages/p4est/package.py index de98e31e1e04e2..9b71294db3d3d1 100644 --- a/var/spack/repos/builtin/packages/p4est/package.py +++ b/var/spack/repos/builtin/packages/p4est/package.py @@ -29,6 +29,8 @@ class P4est(AutotoolsPackage): version("2.0", sha256="c522c5b69896aab39aa5a81399372a19a6b03fc6200d2d5d677d9a22fe31029a") version("1.1", sha256="0b5327a35f0c869bf920b8cab5f20caa4eb55692eaaf1f451d5de30285b25139") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Enable MPI") variant("openmp", default=False, description="Enable OpenMP") diff --git a/var/spack/repos/builtin/packages/p7zip/package.py b/var/spack/repos/builtin/packages/p7zip/package.py index bb6266286d93d9..c50aeb4d070069 100644 --- a/var/spack/repos/builtin/packages/p7zip/package.py +++ b/var/spack/repos/builtin/packages/p7zip/package.py @@ -19,6 +19,9 @@ class P7zip(MakefilePackage): version("17.04", sha256="ea029a2e21d2d6ad0a156f6679bd66836204aa78148a4c5e498fe682e77127ef") version("16.02", sha256="5eb20ac0e2944f6cb9c2d51dd6c4518941c185347d4089ea89087ffdd6e2341f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch( "gcc10.patch", when="@16.02%gcc@10:", diff --git a/var/spack/repos/builtin/packages/pacbio-daligner/package.py b/var/spack/repos/builtin/packages/pacbio-daligner/package.py index 28ede3ec5062a2..b51a86435e0986 100644 --- a/var/spack/repos/builtin/packages/pacbio-daligner/package.py +++ b/var/spack/repos/builtin/packages/pacbio-daligner/package.py @@ -15,6 +15,8 @@ class PacbioDaligner(MakefilePackage): version("2017-08-05", commit="0fe5240d2cc6b55bf9e04465b700b76110749c9d") + depends_on("c", type="build") # generated + depends_on("gmake", type="build") depends_on("pacbio-dazz-db") diff --git a/var/spack/repos/builtin/packages/pacbio-damasker/package.py b/var/spack/repos/builtin/packages/pacbio-damasker/package.py index fbcff6696ed564..3a431949230872 100644 --- a/var/spack/repos/builtin/packages/pacbio-damasker/package.py +++ b/var/spack/repos/builtin/packages/pacbio-damasker/package.py @@ -15,6 +15,8 @@ class PacbioDamasker(MakefilePackage): version("2017-02-11", commit="144244b77d52cb785cb1b3b8ae3ab6f3f0c63264") + depends_on("c", type="build") # generated + depends_on("gmake", type="build") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/pacbio-dazz-db/package.py b/var/spack/repos/builtin/packages/pacbio-dazz-db/package.py index 27a01e5ea06235..8909dd66c87cec 100644 --- a/var/spack/repos/builtin/packages/pacbio-dazz-db/package.py +++ b/var/spack/repos/builtin/packages/pacbio-dazz-db/package.py @@ -16,6 +16,8 @@ class PacbioDazzDb(MakefilePackage): version("2017-04-10", commit="f29d27d51f460563481cd227d17f4bdc5e288365") + depends_on("c", type="build") # generated + depends_on("gmake", type="build") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/pacbio-dextractor/package.py b/var/spack/repos/builtin/packages/pacbio-dextractor/package.py index 4b6f0eef1c6452..033a927fdf514e 100644 --- a/var/spack/repos/builtin/packages/pacbio-dextractor/package.py +++ b/var/spack/repos/builtin/packages/pacbio-dextractor/package.py @@ -15,6 +15,8 @@ class PacbioDextractor(MakefilePackage): version("2016-08-09", commit="89726800346d0bed15d98dcc577f4c7733aab4b1") + depends_on("c", type="build") # generated + depends_on("hdf5") depends_on("gmake", type="build") diff --git a/var/spack/repos/builtin/packages/packmol/package.py b/var/spack/repos/builtin/packages/packmol/package.py index 2821ae6eec5050..0790f950860030 100644 --- a/var/spack/repos/builtin/packages/packmol/package.py +++ b/var/spack/repos/builtin/packages/packmol/package.py @@ -17,3 +17,5 @@ class Packmol(CMakePackage): version("20.0.0", sha256="4faa1c8d5e5db2e935fbc23e7167df7e0b85aa0993c57b74cb897d13e5cf2202") version("18.169", sha256="8acf2cbc742a609e763eb00cae55aecd09af2edb4cc4e931706e2f06ac380de9") + + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/pacparser/package.py b/var/spack/repos/builtin/packages/pacparser/package.py index f10dbee84b12dd..4cbd05788e7798 100644 --- a/var/spack/repos/builtin/packages/pacparser/package.py +++ b/var/spack/repos/builtin/packages/pacparser/package.py @@ -24,6 +24,8 @@ class Pacparser(MakefilePackage): url="https://github.com/manugarg/pacparser/releases/download/1.3.7/pacparser-1.3.7.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("python", when="+python") depends_on("py-setuptools", when="+python", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/pacvim/package.py b/var/spack/repos/builtin/packages/pacvim/package.py index ac72eed956aa35..582da1d9c39f49 100644 --- a/var/spack/repos/builtin/packages/pacvim/package.py +++ b/var/spack/repos/builtin/packages/pacvim/package.py @@ -16,6 +16,8 @@ class Pacvim(MakefilePackage): version("1.1.1", sha256="c869c5450fbafdfe8ba8a8a9bba3718775926f276f0552052dcfa090d21acb28") + depends_on("cxx", type="build") # generated + depends_on("ncurses") def edit(self, stage, prefix): diff --git a/var/spack/repos/builtin/packages/paddle/package.py b/var/spack/repos/builtin/packages/paddle/package.py index 92724d24177b63..84baaad08cee36 100644 --- a/var/spack/repos/builtin/packages/paddle/package.py +++ b/var/spack/repos/builtin/packages/paddle/package.py @@ -17,6 +17,9 @@ class Paddle(CMakePackage): version("master", branch="master", submodules=True) version("0.3.7", tag="0.3.7", submodules=True) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("parmetis", default=False, description="Enable ParMETIS ordering") variant("tests", default=False, description="Enable tests") diff --git a/var/spack/repos/builtin/packages/pagit/package.py b/var/spack/repos/builtin/packages/pagit/package.py index 7cec37c0eef77a..723eb8bc7eb60c 100644 --- a/var/spack/repos/builtin/packages/pagit/package.py +++ b/var/spack/repos/builtin/packages/pagit/package.py @@ -15,6 +15,8 @@ class Pagit(Package): version("1.01", sha256="8069c1d236804cf4ea782495adcc50d18561ef466af06b21946b980b3c37ad55") + depends_on("c", type="build") # generated + depends_on("java", type=("build", "run")) depends_on("perl", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/pagmo/package.py b/var/spack/repos/builtin/packages/pagmo/package.py index 0a7538d2e342dd..2bcebe0187b9a2 100644 --- a/var/spack/repos/builtin/packages/pagmo/package.py +++ b/var/spack/repos/builtin/packages/pagmo/package.py @@ -24,6 +24,9 @@ class Pagmo(CMakePackage): version("1.1.7", sha256="6d8fab89ef9d5d5f30f148225bf9b84b2e5a38997f3d68b85547840e9fd95172") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("examples", default=False, description="Build examples") variant("cxx", default=True, description="Build the C++ interface") variant("python", default=True, description="Build Python bindings") diff --git a/var/spack/repos/builtin/packages/pagmo2/package.py b/var/spack/repos/builtin/packages/pagmo2/package.py index a72cb796767526..527314c70055b0 100644 --- a/var/spack/repos/builtin/packages/pagmo2/package.py +++ b/var/spack/repos/builtin/packages/pagmo2/package.py @@ -22,6 +22,8 @@ class Pagmo2(CMakePackage): version("master", branch="master") version("2.18.0", sha256="5ad40bf3aa91857a808d6b632d9e1020341a33f1a4115d7a2b78b78fd063ae31") + depends_on("cxx", type="build") # generated + depends_on("boost+system+serialization+thread") depends_on("intel-tbb") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/paintor/package.py b/var/spack/repos/builtin/packages/paintor/package.py index 43ff1ae55927d4..50fd6d86ef39da 100644 --- a/var/spack/repos/builtin/packages/paintor/package.py +++ b/var/spack/repos/builtin/packages/paintor/package.py @@ -15,6 +15,10 @@ class Paintor(MakefilePackage): version("3.0", sha256="cc39d3c334cc6d787e4f04847192c9d0185025a2ca46910bd38901b6679d198f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("nlopt") depends_on("eigen") diff --git a/var/spack/repos/builtin/packages/pajeng/package.py b/var/spack/repos/builtin/packages/pajeng/package.py index b607a24209be22..b718f4c9b3c3b7 100644 --- a/var/spack/repos/builtin/packages/pajeng/package.py +++ b/var/spack/repos/builtin/packages/pajeng/package.py @@ -33,6 +33,8 @@ class Pajeng(CMakePackage): version("1.1", sha256="986d03e6deed20a3b9d0e076b1be9053c1bc86c8b41ca36cce3ba3b22dc6abca") version("1.0", sha256="4d98d1a78669290d0a2e6bfe07a1eb4ab96bd05e5ef78da96d2c3cf03b023aa0") + depends_on("cxx", type="build") # generated + variant("static", default=False, description="Build as static library") variant("doc", default=False, description="The Paje Trace File documentation") variant("lib", default=True, description="Build libpaje") diff --git a/var/spack/repos/builtin/packages/pal/package.py b/var/spack/repos/builtin/packages/pal/package.py index 9edf9290ee6c4c..e4bc3af5ad33d9 100644 --- a/var/spack/repos/builtin/packages/pal/package.py +++ b/var/spack/repos/builtin/packages/pal/package.py @@ -19,6 +19,8 @@ class Pal(AutotoolsPackage): version("0.9.8", sha256="191fde8c4f45d6807d4b011511344014966bb46e44029a4481d070cd5e7cc697") + depends_on("c", type="build") # generated + depends_on("sofa-c") depends_on("erfa") diff --git a/var/spack/repos/builtin/packages/palace/package.py b/var/spack/repos/builtin/packages/palace/package.py index 176b358472a45a..630645642f4f53 100644 --- a/var/spack/repos/builtin/packages/palace/package.py +++ b/var/spack/repos/builtin/packages/palace/package.py @@ -20,6 +20,8 @@ class Palace(CMakePackage): version("0.12.0", tag="v0.12.0", commit="8c192071206466638d5818048ee712e1fada386f") version("0.11.2", tag="v0.11.2", commit="6c3aa5f84a934a6ddd58022b2945a1bdb5fa329d") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("int64", default=False, description="Use 64 bit integers") variant("openmp", default=False, description="Use OpenMP for shared-memory parallelism") diff --git a/var/spack/repos/builtin/packages/palisade-development/package.py b/var/spack/repos/builtin/packages/palisade-development/package.py index 05e523a13cdc05..df1c75e05c0f23 100644 --- a/var/spack/repos/builtin/packages/palisade-development/package.py +++ b/var/spack/repos/builtin/packages/palisade-development/package.py @@ -39,6 +39,9 @@ class PalisadeDevelopment(CMakePackage): ) version("master", branch="master", preferred=True, submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared library.") variant("static", default=True, description="Build static library.") variant("with_be2", default=True, description="Build with backend 2.") diff --git a/var/spack/repos/builtin/packages/paml/package.py b/var/spack/repos/builtin/packages/paml/package.py index 63d35ec21adeaf..1e989967741bda 100644 --- a/var/spack/repos/builtin/packages/paml/package.py +++ b/var/spack/repos/builtin/packages/paml/package.py @@ -34,6 +34,8 @@ class Paml(MakefilePackage): url="http://abacus.gene.ucl.ac.uk/software/SoftOld/paml4.9h.tgz", ) + depends_on("c", type="build") # generated + build_directory = "src" def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/panda/package.py b/var/spack/repos/builtin/packages/panda/package.py index c97a5a21adb353..127413bae35a74 100644 --- a/var/spack/repos/builtin/packages/panda/package.py +++ b/var/spack/repos/builtin/packages/panda/package.py @@ -19,6 +19,8 @@ class Panda(CMakePackage): "2016-03-07", sha256="9fae1544626db417ade7318d26bc43c8af04151b9f7679b6d742dba598762037" ) + depends_on("cxx", type="build") # generated + # Note: Panda can also be built without MPI support depends_on("cmake@2.6.4:", type="build") diff --git a/var/spack/repos/builtin/packages/pandaseq/package.py b/var/spack/repos/builtin/packages/pandaseq/package.py index 15f6c64af03868..98f6ab47ca8806 100644 --- a/var/spack/repos/builtin/packages/pandaseq/package.py +++ b/var/spack/repos/builtin/packages/pandaseq/package.py @@ -19,6 +19,8 @@ class Pandaseq(AutotoolsPackage): version("2.11", sha256="6e3e35d88c95f57d612d559e093656404c1d48c341a8baa6bef7bb0f09fc8f82") version("2.10", sha256="93cd34fc26a7357e14e386b9c9ba9b28361cf4da7cf62562dc8501e220f9a561") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type=("build", "link")) diff --git a/var/spack/repos/builtin/packages/pandoc/package.py b/var/spack/repos/builtin/packages/pandoc/package.py index 870490a587d1d0..81a93f5f57a522 100644 --- a/var/spack/repos/builtin/packages/pandoc/package.py +++ b/var/spack/repos/builtin/packages/pandoc/package.py @@ -20,6 +20,8 @@ class Pandoc(Package): # the challenges with Haskell. Until the Haskell framework is in Spack this # package will meet the needs of packages that have a dependency on pandoc. + skip_version_audit = ["platform=windows"] + if platform.system() == "Linux" and platform.machine() == "aarch64": url = "https://github.com/jgm/pandoc/releases/download/2.14.0.3/pandoc-2.14.0.3-linux-arm64.tar.gz" version( diff --git a/var/spack/repos/builtin/packages/pandoramonitoring/package.py b/var/spack/repos/builtin/packages/pandoramonitoring/package.py index df7599c0a59c05..25008056ad968c 100644 --- a/var/spack/repos/builtin/packages/pandoramonitoring/package.py +++ b/var/spack/repos/builtin/packages/pandoramonitoring/package.py @@ -23,6 +23,8 @@ class Pandoramonitoring(CMakePackage): version("master", branch="master") version("3.5.0", sha256="274562abb7c797194634d5460a56227444a1de07a240c88ae35ca806abcbaf60") + depends_on("cxx", type="build") # generated + depends_on("root@6.18.04: +x +opengl") depends_on("pandorasdk") diff --git a/var/spack/repos/builtin/packages/pandorasdk/package.py b/var/spack/repos/builtin/packages/pandorasdk/package.py index 2f4d3be357a5e7..77535e003eb442 100644 --- a/var/spack/repos/builtin/packages/pandorasdk/package.py +++ b/var/spack/repos/builtin/packages/pandorasdk/package.py @@ -25,6 +25,8 @@ class Pandorasdk(CMakePackage): version("3.4.1", sha256="9607bf52a9d79d88d28c45d4f3336e066338b36ab81b4d2d125226f4ad3a7aaf") version("3.4.0", sha256="1e30db056d4a43f8659fccdda00270af14593425d933f91e91d5c97f1e124c6b") + depends_on("cxx", type="build") # generated + depends_on("pandorapfa") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/pango/package.py b/var/spack/repos/builtin/packages/pango/package.py index 69ecc81f0d6ffd..5e4db93eba4551 100644 --- a/var/spack/repos/builtin/packages/pango/package.py +++ b/var/spack/repos/builtin/packages/pango/package.py @@ -19,6 +19,10 @@ class Pango(MesonPackage): license("LGPL-2.1-or-later") + # Do not upgrade to v1.90.x. It is a development release in preparation for + # v2.0 that will break API and ABI compatibility. For more information see + # https://download.gnome.org/sources/pango/1.90/pango-1.90.0.news + version("1.52.2", sha256="d0076afe01082814b853deec99f9349ece5f2ce83908b8e58ff736b41f78a96b") version("1.50.13", sha256="5cdcf6d761d26a3eb9412b6cb069b32bd1d9b07abf116321167d94c2189299fd") version("1.50.7", sha256="0477f369a3d4c695df7299a6989dc004756a7f4de27eecac405c6790b7e3ad33") version("1.49.4", sha256="1fda6c03161bd1eacfdc349244d26828c586d25bfc600b9cfe2494902fdf56cf") @@ -28,31 +32,9 @@ class Pango(MesonPackage): version("1.45.5", sha256="f61dd911de2d3318b43bbc56bd271637a46f9118a1ee4378928c06df8a1c1705") version("1.44.6", sha256="3e1e41ba838737e200611ff001e3b304c2ca4cdbba63d200a20db0b0ddc0f86c") version("1.42.4", sha256="1d2b74cd63e8bd41961f2f8d952355aa0f9be6002b52c8aa7699d9f5da597c9d") - version( - "1.42.0", - sha256="9924d88a3dcedff753f0763814a1605307c5c9c931413b8b47ea7267d1b19446", - deprecated=True, - ) - version( - "1.41.0", - sha256="1f76ef95953dc58ee5d6a53e5f1cb6db913f3e0eb489713ee9266695cae580ba", - deprecated=True, - ) - version( - "1.40.3", - sha256="abba8b5ce728520c3a0f1535eab19eac3c14aeef7faa5aded90017ceac2711d3", - deprecated=True, - ) - version( - "1.40.1", - sha256="e27af54172c72b3ac6be53c9a4c67053e16c905e02addcf3a603ceb2005c1a40", - deprecated=True, - ) - version( - "1.36.8", - sha256="18dbb51b8ae12bae0ab7a958e7cf3317c9acfc8a1e1103ec2f147164a0fc2d07", - deprecated=True, - ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated variant("X", default=False, description="Enable an X toolkit") @@ -97,16 +79,17 @@ def url_for_version(self, version): return url.format(version.up_to(2), version) def meson_args(self): + spec = self.spec args = [] # xft is not a meson option, even when it is a configure option - if self.spec.satisfies("@1.49: +X"): + if spec.satisfies("@1.49: +X"): args.append("-Dxft=enabled") - elif self.spec.satisfies("@1.49: -X"): + elif spec.satisfies("@1.49: -X"): args.append("-Dxft=disabled") # disable building of gtk-doc files following #9885 and #9771 - if self.spec.satisfies("@1.44:"): + if spec.satisfies("@1.44:"): args.append("-Dgtk_doc=false") else: args.append("-Denable_docs=false") @@ -124,10 +107,10 @@ def configure_args(self): # disable building of gtk-doc files following #9885 and #9771 args.append("--disable-gtk-doc-html") true = which("true") - args.append("GTKDOC_CHECK={0}".format(true)) - args.append("GTKDOC_CHECK_PATH={0}".format(true)) - args.append("GTKDOC_MKPDF={0}".format(true)) - args.append("GTKDOC_REBASE={0}".format(true)) + args.append(f"GTKDOC_CHECK={true}") + args.append(f"GTKDOC_CHECK_PATH={true}") + args.append(f"GTKDOC_MKPDF={true}") + args.append(f"GTKDOC_REBASE={true}") return args diff --git a/var/spack/repos/builtin/packages/pangolin/package.py b/var/spack/repos/builtin/packages/pangolin/package.py index 1cde66335f0d0b..d7d7108c4b7725 100644 --- a/var/spack/repos/builtin/packages/pangolin/package.py +++ b/var/spack/repos/builtin/packages/pangolin/package.py @@ -18,6 +18,8 @@ class Pangolin(CMakePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + # Required dependencies depends_on("cmake@2.8.12:", type="build") depends_on("gl") diff --git a/var/spack/repos/builtin/packages/pangomm/package.py b/var/spack/repos/builtin/packages/pangomm/package.py index d09c682720d82b..032694b8e0e0f3 100644 --- a/var/spack/repos/builtin/packages/pangomm/package.py +++ b/var/spack/repos/builtin/packages/pangomm/package.py @@ -32,6 +32,8 @@ class Pangomm(AutotoolsPackage): version("2.14.1", sha256="2ea6cee273cca1aae2ee5a5dac0c416b4dc354e46debb51f20c6eeba828f5ed5") version("2.14.0", sha256="baa3b231c9498fb1140254e3feb4eb93c638f07e6e26ae0e36c3699ec14d80fd") + depends_on("cxx", type="build") # generated + depends_on("pango") depends_on("glibmm") depends_on("cairomm") diff --git a/var/spack/repos/builtin/packages/papi/package.py b/var/spack/repos/builtin/packages/papi/package.py index 89f6508c7f75db..7fb31bc920a094 100644 --- a/var/spack/repos/builtin/packages/papi/package.py +++ b/var/spack/repos/builtin/packages/papi/package.py @@ -46,6 +46,10 @@ class Papi(AutotoolsPackage, ROCmPackage): version("5.4.1", sha256="e131c1449786fe870322a949e44f974a5963824f683232e653fb570cc65d4e87") version("5.3.0", sha256="99f2f36398b370e75d100b4a189d5bc0ac4f5dd66df44d441f88fd32e1421524") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("example", default=True, description="Install the example files") variant("infiniband", default=False, description="Enable Infiniband support") variant("powercap", default=False, description="Enable powercap interface support") diff --git a/var/spack/repos/builtin/packages/parallel-hashmap/package.py b/var/spack/repos/builtin/packages/parallel-hashmap/package.py index 327c9ce3944a3f..27d8f6b1ab6ba0 100644 --- a/var/spack/repos/builtin/packages/parallel-hashmap/package.py +++ b/var/spack/repos/builtin/packages/parallel-hashmap/package.py @@ -17,6 +17,8 @@ class ParallelHashmap(CMakePackage): version("1.3.11", sha256="0515a681bfb24207013786a7737e9d8561302e656689d8a65ea480bbabab460f") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.8:", type="build") patch("pthread.patch") diff --git a/var/spack/repos/builtin/packages/parallel-netcdf/package.py b/var/spack/repos/builtin/packages/parallel-netcdf/package.py index ee67a43b0cabb3..aed8d43d6fe17f 100644 --- a/var/spack/repos/builtin/packages/parallel-netcdf/package.py +++ b/var/spack/repos/builtin/packages/parallel-netcdf/package.py @@ -47,6 +47,10 @@ def url_for_version(self, version): version("1.7.0", sha256="52f0d106c470a843c6176318141f74a21e6ece3f70ee8fe261c6b93e35f70a94") version("1.6.1", sha256="8cf1af7b640475e3cc931e5fbcfe52484c5055f2fab526691933c02eda388aae") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("cxx", default=True, description="Build the C++ Interface") variant("fortran", default=True, description="Build the Fortran Interface") variant("pic", default=True, description="Produce position-independent code (for shared libs)") diff --git a/var/spack/repos/builtin/packages/parallelio/package.py b/var/spack/repos/builtin/packages/parallelio/package.py index 2cf9f2c8c59ae4..5872c17a8d5463 100644 --- a/var/spack/repos/builtin/packages/parallelio/package.py +++ b/var/spack/repos/builtin/packages/parallelio/package.py @@ -30,6 +30,10 @@ class Parallelio(CMakePackage): version("2.5.3", sha256="205a0a128fd5262700efc230b3380dc5ab10e74bc5d273ae05db76c9d95487ca") version("2.5.2", sha256="935bc120ef3bf4fe09fb8bfdf788d05fb201a125d7346bf6b09e27ac3b5f345c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("pnetcdf", default=False, description="enable pnetcdf") variant("timing", default=False, description="enable GPTL timing") variant("ncint", default=False, description="enable netcdf integration", when="@2.6.0:") diff --git a/var/spack/repos/builtin/packages/parallelmergetree/package.py b/var/spack/repos/builtin/packages/parallelmergetree/package.py index 639d7689148e81..4e27759a580070 100644 --- a/var/spack/repos/builtin/packages/parallelmergetree/package.py +++ b/var/spack/repos/builtin/packages/parallelmergetree/package.py @@ -57,6 +57,9 @@ class Parallelmergetree(CMakePackage): submodules=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("babelflow@1.1.0", when="@1.1.2") depends_on("babelflow@1.1.0", when="@1.1.1") depends_on("babelflow@1.1.0", when="@1.1.0") diff --git a/var/spack/repos/builtin/packages/paraver/package.py b/var/spack/repos/builtin/packages/paraver/package.py index 530bb340177ada..3098ab8c46f011 100644 --- a/var/spack/repos/builtin/packages/paraver/package.py +++ b/var/spack/repos/builtin/packages/paraver/package.py @@ -32,6 +32,9 @@ class Paraver(Package): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost@1.36: +serialization") depends_on("wxwidgets@2.8:") # NOTE: using external for this one is usually simpler depends_on("wxpropgrid@1.4:") diff --git a/var/spack/repos/builtin/packages/paraview/kits_with_catalyst_5_12.patch b/var/spack/repos/builtin/packages/paraview/kits_with_catalyst_5_12.patch new file mode 100644 index 00000000000000..f61767fd64ffdf --- /dev/null +++ b/var/spack/repos/builtin/packages/paraview/kits_with_catalyst_5_12.patch @@ -0,0 +1,21 @@ +From 65ec5b0604576474141def0ba7f0c7b94f6b32ee Mon Sep 17 00:00:00 2001 +From: Ryan Krattiger +Date: Fri, 8 Mar 2024 09:17:03 -0600 + +--- + VTK/IO/CatalystConduit/vtk.module | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/VTK/IO/CatalystConduit/vtk.module b/VTK/IO/CatalystConduit/vtk.module +index c67f5a099d5..18e706e8c9f 100644 +--- a/VTK/IO/CatalystConduit/vtk.module ++++ b/VTK/IO/CatalystConduit/vtk.module +@@ -5,7 +5,7 @@ LIBRARY_NAME + DESCRIPTION + Catalyst implementation for VTK, including Conduit to/from VTK conversion. + KIT +- VTK::IO ++ VTK::Parallel + SPDX_LICENSE_IDENTIFIER + BSD-3-Clause + SPDX_COPYRIGHT_TEXT diff --git a/var/spack/repos/builtin/packages/paraview/package.py b/var/spack/repos/builtin/packages/paraview/package.py index f89080f8cf9363..8edec4e3f33b37 100644 --- a/var/spack/repos/builtin/packages/paraview/package.py +++ b/var/spack/repos/builtin/packages/paraview/package.py @@ -31,13 +31,15 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): version("master", branch="master", submodules=True) version( - "5.12.0-RC3", sha256="6aaa46ff295126707294482e6ba24bd0ec0d68cf6bb5f56f145f8bcc53fc3f70" + "5.13.0-RC1", sha256="00aea2bbaf2eacd288a6cc95c1f4ed1a8a4965f27548b53ae473c1ee7caec30e" ) version( - "5.11.2", - sha256="5c5d2f922f30d91feefc43b4a729015dbb1459f54c938896c123d2ac289c7a1e", + "5.12.1", + sha256="927f880c13deb6dde4172f4727d2b66f5576e15237b35778344f5dd1ddec863e", preferred=True, ) + version("5.12.0", sha256="d289afe7b48533e2ca4a39a3b48d3874bfe67cf7f37fdd2131271c57e64de20d") + version("5.11.2", sha256="5c5d2f922f30d91feefc43b4a729015dbb1459f54c938896c123d2ac289c7a1e") version("5.11.1", sha256="5cc2209f7fa37cd3155d199ff6c3590620c12ca4da732ef7698dec37fa8dbb34") version("5.11.0", sha256="9a0b8fe8b1a2cdfd0ace9a87fa87e0ec21ee0f6f0bcb1fdde050f4f585a25165") version("5.10.1", sha256="520e3cdfba4f8592be477314c2f6c37ec73fb1d5b25ac30bdbd1c5214758b9c2") @@ -60,6 +62,10 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): version("5.0.1", sha256="caddec83ec284162a2cbc46877b0e5a9d2cca59fb4ab0ea35b0948d2492950bb") version("4.4.0", sha256="c2dc334a89df24ce5233b81b74740fc9f10bc181cd604109fd13f6ad2381fc73") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "development_files", default=True, @@ -68,8 +74,6 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): variant("python", default=False, description="Enable Python support", when="@5.6:") variant("fortran", default=False, description="Enable Fortran support") variant("mpi", default=True, description="Enable MPI support") - variant("osmesa", default=False, description="Enable OSMesa support") - variant("egl", default=False, description="Enable EGL in the OpenGL library being used") variant("qt", default=False, description="Enable Qt (gui) support") variant("opengl2", default=True, description="Enable OpenGL2 backend") variant("examples", default=False, description="Build examples") @@ -147,6 +151,40 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): msg="Use paraview@5.9.0 with %xl_r. Earlier versions are not able to build with xl.", ) + # CUDA ARCH + + # This is (more or less) the mapping hard-coded in VTK-m logic + # see https://gitlab.kitware.com/vtk/vtk-m/-/blob/v2.1.0/CMake/VTKmDeviceAdapters.cmake?ref_type=tags#L221-247 + supported_cuda_archs = { + "20": "fermi", + "21": "fermi", + "30": "kepler", + "32": "kepler", + "35": "kepler", + "37": "kepler", + "50": "maxwel", + "52": "maxwel", + "53": "maxwel", + "60": "pascal", + "61": "pascal", + "62": "pascal", + "70": "volta", + "72": "volta", + "75": "turing", + "80": "ampere", + "86": "ampere", + } + + # VTK-m and transitively ParaView does not support Tesla Arch + for _arch in range(10, 14): + conflicts(f"cuda_arch={_arch}", when="+cuda", msg="ParaView requires cuda_arch >= 20") + + # Starting from cmake@3.18, CUDA architecture managament can be delegated to CMake. + # Hence, it is possible to rely on it instead of relying on custom logic updates from VTK-m for + # newer architectures (wrt mapping). + for _arch in [arch for arch in CudaPackage.cuda_arch_values if int(arch) > 86]: + conflicts("cmake@:3.17", when=f"cuda_arch={_arch}") + # We only support one single Architecture for _arch, _other_arch in itertools.permutations(CudaPackage.cuda_arch_values, 2): conflicts( @@ -155,9 +193,6 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): msg="Paraview only accepts one architecture value", ) - for _arch in range(10, 14): - conflicts("cuda_arch=%d" % _arch, when="+cuda", msg="ParaView requires cuda_arch >= 20") - depends_on("cmake@3.3:", type="build") depends_on("cmake@3.21:", type="build", when="+rocm") @@ -189,16 +224,10 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): depends_on("gl@3.2:", when="+opengl2") depends_on("gl@1.2:", when="~opengl2") - depends_on("glew", when="~egl") - depends_on("glew gl=egl", when="+egl") + depends_on("glew") + depends_on("libxt", when="platform=linux ^[virtuals=gl] glx") - depends_on("osmesa", when="+osmesa") - for p in ["linux", "cray"]: - depends_on("glx", when="~egl ~osmesa platform={}".format(p)) - depends_on("libxt", when="~egl ~osmesa platform={}".format(p)) - conflicts("+qt", when="+osmesa") - conflicts("+qt", when="+egl") - conflicts("+egl", when="+osmesa") + requires("^[virtuals=gl] glx", when="+qt", msg="Qt support requires GLX") depends_on("ospray@2.1:2", when="+raytracing") depends_on("openimagedenoise", when="+raytracing") @@ -209,6 +238,7 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): depends_on("expat") depends_on("eigen@3:") depends_on("freetype") + depends_on("freetype@:2.10.2", when="@:5.8") # depends_on('hdf5+mpi', when='+mpi') # depends_on('hdf5~mpi', when='~mpi') depends_on("hdf5+hl+mpi", when="+hdf5+mpi") @@ -236,8 +266,10 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): depends_on("protobuf@3.4:3.18", when="@:5.10%xl") depends_on("protobuf@3.4:3.18", when="@:5.10%xl_r") # protobuf requires newer abseil-cpp, which in turn requires C++14, - # but paraview uses C++11 by default. Use for 5.11+ until ParaView updates + # but paraview uses C++11 by default. Use for 5.8+ until ParaView updates # its C++ standard level. + depends_on("protobuf@3.4:3.21", when="@5.8:%gcc") + depends_on("protobuf@3.4:3.21", when="@5.8:%clang") depends_on("protobuf@3.4:3.21", when="@5.11:") depends_on("protobuf@3.4:3.21", when="@master") depends_on("libxml2") @@ -288,7 +320,7 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): patch("vtkm-findmpi-downstream.patch", when="@5.9.0") # Include limits header wherever needed to fix compilation with GCC 11 - patch("paraview-gcc11-limits.patch", when="@5.9.1 %gcc@11.1.0:") + patch("paraview-gcc11-limits.patch", when="@5.8:5.9 %gcc@11.1.0:") # Fix IOADIOS2 module to work with kits # https://gitlab.kitware.com/vtk/vtk/-/merge_requests/8653 @@ -301,10 +333,14 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): # intel oneapi doesn't compile some code in catalyst patch("catalyst-etc_oneapi_fix.patch", when="@5.10.0:5.10.1%oneapi") - # Patch for paraview 5.10: +hdf5 ^hdf5@1.13.2: + # Patch for paraview 5.8: ^hdf5@1.13.2: + # Even with ~hdf5, hdf5 is part of the dependency tree due to netcdf-c # https://gitlab.kitware.com/vtk/vtk/-/merge_requests/9690 - patch("vtk-xdmf2-hdf51.13.1.patch", when="@5.10.0:5.10") - patch("vtk-xdmf2-hdf51.13.2.patch", when="@5.10:5.11.0") + patch("vtk-xdmf2-hdf51.13.1.patch", when="@5.8:5.10") + patch("vtk-xdmf2-hdf51.13.2.patch", when="@5.8:5.11.0") + # a patch with the same name is also applied to vtk + # the two patches are the same but for the path to the files they patch + patch("vtk_alias_hdf5.patch", when="@5.9.0: platform=windows") # Fix VTK to work with external freetype using CONFIG mode for find_package patch("FindFreetype.cmake.patch", when="@5.10.1:") @@ -313,7 +349,9 @@ class Paraview(CMakePackage, CudaPackage, ROCmPackage): # https://gitlab.kitware.com/vtk/vtk/-/merge_requests/10113 patch("adios2-remove-deprecated-functions.patch", when="@5.10:5.11 ^adios2@2.9:") - patch("exodusII-netcdf4.9.0.patch", when="@:5.10.2") + patch("exodusII-netcdf4.9.0.patch", when="@5.10.0:5.10.2") + + patch("kits_with_catalyst_5_12.patch", when="@5.12.0") generator("ninja", "make", default="ninja") # https://gitlab.kitware.com/paraview/paraview/-/issues/21223 @@ -368,7 +406,8 @@ def flag_handler(self, name, flags): elif self.spec.satisfies("@5.10: +hdf5"): if self.spec["hdf5"].satisfies("@1.12:"): flags.append("-DH5_USE_110_API") - return (flags, None, None) + + return flags, None, None def setup_run_environment(self, env): # paraview 5.5 and later @@ -416,19 +455,17 @@ def cmake_args(self): def variant_bool(feature, on="ON", off="OFF"): """Ternary for spec variant to ON/OFF string""" - if feature in spec: + if spec.satisfies(feature): return on return off - def nvariant_bool(feature): - """Negated ternary for spec variant to OFF/ON string""" - return variant_bool(feature, on="OFF", off="ON") - def use_x11(): """Return false if osmesa or egl are requested""" - if "+osmesa" in spec or "+egl" in spec: - return "OFF" - if spec.satisfies("platform=windows"): + if ( + spec.satisfies("^[virtuals=gl] osmesa") + or spec.satisfies("^[virtuals=gl] egl") + or spec.satisfies("platform=windows") + ): return "OFF" return "ON" @@ -436,7 +473,7 @@ def use_x11(): includes = variant_bool("+development_files") cmake_args = [ - "-DVTK_OPENGL_HAS_OSMESA:BOOL=%s" % variant_bool("+osmesa"), + "-DVTK_OPENGL_HAS_OSMESA:BOOL=%s" % variant_bool("^[virtuals=gl] osmesa"), "-DVTK_USE_X:BOOL=%s" % use_x11(), "-DPARAVIEW_INSTALL_DEVELOPMENT_FILES:BOOL=%s" % includes, "-DBUILD_TESTING:BOOL=OFF", @@ -445,7 +482,7 @@ def use_x11(): self.define_from_variant("VISIT_BUILD_READER_Silo", "visitbridge"), ] - if "+egl" in spec: + if spec.satisfies("^[virtuals=gl] egl"): cmake_args.append("-DVTK_OPENGL_HAS_EGL:BOOL=ON") if spec.satisfies("@5.12:"): @@ -522,7 +559,7 @@ def use_x11(): # The assumed qt version changed to QT5 (as of paraview 5.2.1), # so explicitly specify which QT major version is actually being used - if "+qt" in spec: + if spec.satisfies("+qt"): cmake_args.extend(["-DPARAVIEW_QT_VERSION=%s" % spec["qt"].version[0]]) if "+fortran" in spec: @@ -578,38 +615,25 @@ def use_x11(): # VTK-m expects cuda_arch to be the arch name vs. the arch version. if spec.satisfies("+cuda"): - supported_cuda_archs = { - # VTK-m and transitively ParaView does not support Tesla Arch - "20": "fermi", - "21": "fermi", - "30": "kepler", - "32": "kepler", - "35": "kepler", - "37": "kepler", - "50": "maxwel", - "52": "maxwel", - "53": "maxwel", - "60": "pascal", - "61": "pascal", - "62": "pascal", - "70": "volta", - "72": "volta", - "75": "turing", - "80": "ampere", - "86": "ampere", - } - - cuda_arch_value = "native" - requested_arch = spec.variants["cuda_arch"].value - - # ParaView/VTK-m only accepts one arch, default to first element - if requested_arch[0] != "none": - try: - cuda_arch_value = supported_cuda_archs[requested_arch[0]] - except KeyError: - raise InstallError("Incompatible cuda_arch=" + requested_arch[0]) - - cmake_args.append(self.define("VTKm_CUDA_Architecture", cuda_arch_value)) + if spec["cmake"].satisfies("@3.18:"): + cmake_args.append( + self.define( + "CMAKE_CUDA_ARCHITECTURES", ";".join(spec.variants["cuda_arch"].value) + ) + ) + else: + # ParaView/VTK-m only accepts one arch, default to first element + requested_arch = spec.variants["cuda_arch"].value[0] + + if requested_arch == "none": + cuda_arch_value = "native" + else: + try: + cuda_arch_value = supported_cuda_archs[requested_arch] + except KeyError: + raise InstallError("Incompatible cuda_arch=" + requested_arch) + + cmake_args.append(self.define("VTKm_CUDA_Architecture", cuda_arch_value)) if "darwin" in spec.architecture: cmake_args.extend( diff --git a/var/spack/repos/builtin/packages/paraview/vtk_alias_hdf5.patch b/var/spack/repos/builtin/packages/paraview/vtk_alias_hdf5.patch new file mode 100644 index 00000000000000..a580debfa1e037 --- /dev/null +++ b/var/spack/repos/builtin/packages/paraview/vtk_alias_hdf5.patch @@ -0,0 +1,14 @@ +diff --git a/CMake/patches/99/FindHDF5.cmake b/CMake/patches/99/FindHDF5.cmake +index b54877d519..adf5d84430 100644 +--- a/VTK/CMake/patches/99/FindHDF5.cmake ++++ b/VTK/CMake/patches/99/FindHDF5.cmake +@@ -1150,6 +1150,9 @@ if (HDF5_FOUND) + endif () + endif () + endforeach () ++ if(NOT TARGET "hdf5") ++ add_library(hdf5 ALIAS hdf5::hdf5) ++ endif() + unset(hdf5_lang) + + if (HDF5_DIFF_EXECUTABLE AND NOT TARGET hdf5::h5diff) diff --git a/var/spack/repos/builtin/packages/parflow/package.py b/var/spack/repos/builtin/packages/parflow/package.py index 3906e6f8f46d44..937ab1786d09ea 100644 --- a/var/spack/repos/builtin/packages/parflow/package.py +++ b/var/spack/repos/builtin/packages/parflow/package.py @@ -3,8 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import os - from spack.package import * @@ -23,6 +21,10 @@ class Parflow(CMakePackage): version("3.9.0", sha256="0ac610208baf973ac07ca93187ec289ba3f6e904d3f01d721ee96a2ace0f5e48") version("3.8.0", sha256="5ad01457bb03265d1e221090450e3bac5a680d6290db7e3872c295ce6d6aaa08") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") # Using explicit versions to keep builds consistent @@ -65,21 +67,16 @@ def setup_run_environment(self, env): examples_dir = "examples" - def test(self): - """Perform smoke test on installed ParFlow package.""" - # Run the single phase flow test + def test_single_phase_flow(self): + """Run the single phase flow test""" run_path = join_path(self.spec.prefix, self.examples_dir) - if os.path.isdir(run_path): - with working_dir(run_path): - self.run_test( - "{0}/tclsh".format(self.spec["tcl"].prefix.bin), - ["default_single.tcl", "1", "1" "1"], - ) - else: - # If examples are not installed test if exe executes - exes = ["parflow"] - for exe in exes: - reason = "test version of {0} is {1}".format(exe, self.spec.version) - self.run_test( - exe, ["-v"], [self.spec.version.string], installed=True, purpose=reason - ) + options = ["default_single.tcl", "1", "1" "1"] + with working_dir(run_path): + exe = which(f"{self.spec['tcl'].prefix.bin}/tclsh") + exe(*options) + + def test_check_version(self): + """Test if exe executes""" + exe = which(join_path(self.prefix.bin, "parflow")) + out = exe("-v", output=str.split, error=str.split) + assert str(self.spec.version) in out diff --git a/var/spack/repos/builtin/packages/parmetis/package.py b/var/spack/repos/builtin/packages/parmetis/package.py index 9d18cd69511773..c18d61e798799d 100644 --- a/var/spack/repos/builtin/packages/parmetis/package.py +++ b/var/spack/repos/builtin/packages/parmetis/package.py @@ -21,6 +21,8 @@ class Parmetis(CMakePackage): version("4.0.3", sha256="f2d9a231b7cf97f1fee6e8c9663113ebf6c240d407d3c118c55b3633d6be6e5f") version("4.0.2", sha256="5acbb700f457d3bda7d4bb944b559d7f21f075bb6fa4c33f42c261019ef2f0b2") + depends_on("c", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries.") variant("gdb", default=False, description="Enables gdb support.") variant("int64", default=False, description="Sets the bit width of METIS's index type to 64.") diff --git a/var/spack/repos/builtin/packages/parmgridgen/package.py b/var/spack/repos/builtin/packages/parmgridgen/package.py index ee83f9622fe35b..942e7be7ba35c6 100644 --- a/var/spack/repos/builtin/packages/parmgridgen/package.py +++ b/var/spack/repos/builtin/packages/parmgridgen/package.py @@ -20,6 +20,8 @@ class Parmgridgen(Package): version("1.0", sha256="62cdb6e48cfc59124e5d5d360c2841e0fc2feecafe65bda110b74e942740b395") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Activate the compilation of parallel libraries") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin/packages/parmmg/package.py b/var/spack/repos/builtin/packages/parmmg/package.py index 5766f9b79b6f00..e41f7129400bcc 100644 --- a/var/spack/repos/builtin/packages/parmmg/package.py +++ b/var/spack/repos/builtin/packages/parmmg/package.py @@ -21,6 +21,10 @@ class Parmmg(CMakePackage): version("1.1.0", sha256="a5904f1f56b7809ab9ec2f6118b03a082ec2b5564355a73c74fc55426cc69600") version("1.0.0", sha256="614feb815ff6cdfc9bced30e8105994f0bf3a812243619d3349203ec1851cf6d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mmg") depends_on("metis") depends_on("vtk") diff --git a/var/spack/repos/builtin/packages/parquet-cpp/package.py b/var/spack/repos/builtin/packages/parquet-cpp/package.py index 1525bd45f95109..6c3719519f16bb 100644 --- a/var/spack/repos/builtin/packages/parquet-cpp/package.py +++ b/var/spack/repos/builtin/packages/parquet-cpp/package.py @@ -17,6 +17,8 @@ class ParquetCpp(CMakePackage): version("1.4.0", sha256="52899be6c9dc49a14976d4ad84597243696c3fa2882e5c802b56e912bfbcc7ce") + depends_on("cxx", type="build") # generated + depends_on("arrow") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/parsimonator/package.py b/var/spack/repos/builtin/packages/parsimonator/package.py index 472cbcb34c7105..b13e425f063345 100644 --- a/var/spack/repos/builtin/packages/parsimonator/package.py +++ b/var/spack/repos/builtin/packages/parsimonator/package.py @@ -17,6 +17,8 @@ class Parsimonator(MakefilePackage): version("1.0.2", commit="78368c6ab1e9adc7e9c6ec9256dd7ff2a5bb1b0a") + depends_on("c", type="build") # generated + patch("nox86.patch") @property diff --git a/var/spack/repos/builtin/packages/parsplice/package.py b/var/spack/repos/builtin/packages/parsplice/package.py index cc04c1ad98d845..b4755313fd698a 100644 --- a/var/spack/repos/builtin/packages/parsplice/package.py +++ b/var/spack/repos/builtin/packages/parsplice/package.py @@ -25,6 +25,8 @@ class Parsplice(CMakePackage): version("multisplice", branch="multisplice") version("1.1", sha256="a011c4d14f66e7cdbc151cc74b5d40dfeae19ceea033ef48185d8f3b1bc2f86b") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build") depends_on("berkeley-db") depends_on("nauty") diff --git a/var/spack/repos/builtin/packages/parthenon/package.py b/var/spack/repos/builtin/packages/parthenon/package.py new file mode 100644 index 00000000000000..9d2cdfc5c3ce54 --- /dev/null +++ b/var/spack/repos/builtin/packages/parthenon/package.py @@ -0,0 +1,77 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Parthenon(CMakePackage): + """A performance portable block-structured adaptive mesh refinement framework.""" + + homepage = "https://github.com/parthenon-hpc-lab/parthenon" + git = "https://github.com/parthenon-hpc-lab/parthenon.git" + url = "https://github.com/parthenon-hpc-lab/parthenon/archive/v0.8.0.tar.gz" + maintainers("pbrady", "pgrete") + + version("develop", branch="develop") + version("24.03", sha256="ec9109c6bf442237641e627f301567527eb5e756b6959b6747d35315d041727c") + version("23.11", sha256="76f79fb7d6556d94052829a8ac71f53cbda76f37fabd9233c5c0cd47ef561aee") + version("0.8.0", sha256="9ed7c9ebdc84927a43b86c1e061f925b57cef9b567c7275f22779ed4d98e858d") + + depends_on("cxx", type="build") # generated + + # ------------------------------------------------------------# + # Variants + # ------------------------------------------------------------# + + variant("single", default=False, description="Run in single precision") + variant("mpi", default=True, description="Enable mpi") + variant( + "host_comm_buffers", default=False, description="Allocate communication buffers on host" + ) + variant("hdf5", default=True, description="Enable hdf5") + with when("+hdf5"): + variant( + "compression", + default=True, + description="Enable compression in hdf5 output/restart files", + ) + variant("sparse", default=True, description="Sparse capability") + variant("ascent", default=False, description="Enable Ascent for in-situ vis and analysis") + variant("examples", default=False, description="Build example drivers") + variant("python", default=False, description="Enable python for testing") + variant( + "pressure", default=False, description="Registry pressure check for Kokkos CUDA kernels" + ) + + # ------------------------------------------------------------# + # Dependencies + # ------------------------------------------------------------# + + depends_on("cmake@3.16:", type="build") + + depends_on("mpi", when="+mpi") + depends_on("hdf5", when="+hdf5") + depends_on("hdf5 +mpi", when="+mpi +hdf5") + depends_on("ascent", when="+ascent") + depends_on("python@3.5:", when="+python") + depends_on("kokkos@4:") + + def cmake_args(self): + spec = self.spec + return [ + self.define("PARTHENON_IMPORT_KOKKOS", True), + self.define_from_variant("PARTHENON_SINGLE_PRECISION", "single"), + self.define_from_variant("PARTHENON_ENABLE_HOST_COMM_BUFFERS", "host_comm_buffers"), + self.define_from_variant("CHECK_REGISTRY_PRESSURE", "pressure"), + self.define_from_variant("PARTHENON_ENABLE_ASCENT", "ascent"), + self.define("PARTHENON_DISABLE_MPI", not spec.variants["mpi"].value), + self.define("PARTHENON_DISABLE_HDF5", not spec.variants["hdf5"].value), + self.define( + "PARTHENON_DISABLE_HDF5_COMPRESSION", not spec.variants["compression"].value + ), + self.define("PARTHENON_DISABLE_SPARSE", not spec.variants["sparse"].value), + self.define("PARTHENON_DISABLE_EXAMPLES", not spec.variants["examples"].value), + self.define("BUILD_TESTING", self.run_tests), + ] diff --git a/var/spack/repos/builtin/packages/pass/package.py b/var/spack/repos/builtin/packages/pass/package.py new file mode 100644 index 00000000000000..b5d953d4e0a272 --- /dev/null +++ b/var/spack/repos/builtin/packages/pass/package.py @@ -0,0 +1,63 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Pass(MakefilePackage): + """A minimal password manager following the UNIX philosphy.""" + + homepage = "https://www.passwordstore.org/" + git = "https://git.zx2c4.com/password-store.git" + + maintainers("alecbcs", "taliaferro") + + license("GPL-2.0", checked_by="taliaferro") + + version("1.7.4", tag="1.7.4", commit="1078f2514d579178d5df7042c6a790e9c9b731ad") + + variant("xclip", default=False, description="install the X11 clipboard provider") + + depends_on("bash") + depends_on("gnupg") + depends_on("git") + depends_on("tree") + depends_on("util-linux") # for GNU getopt + depends_on("libqrencode") + depends_on("openssl") # used for base64 only + + depends_on("xclip", when="+xclip") + + def setup_build_environment(self, env): + env.set("PREFIX", prefix) + env.set("WITH_ALLCOMP", "yes") + + def edit(self, spec, prefix): + """ + Pass's install process involves slotting in a small script snippet at + the start of the file, defining certain platform-specific behaviors + including the paths where some of its key dependencies are likely to + be found. Most of this logic still works when installed with Spack, + but the paths to the dependencies are wrong (for example, on MacOS + it looks for getopt in /opt/homebrew.) We can hardcode those paths here. + """ + + bash_exec = self.spec["bash"].command + gpg_exec = self.spec["gnupg"].prefix.bin.gpg + getopt_exec = self.spec["util-linux"].prefix.bin.getopt + openssl_exec = self.spec["openssl"].command + + platform_files = FileFilter( + "src/password-store.sh", + "src/platform/darwin.sh", + "src/platform/freebsd.sh", + "src/platform/openbsd.sh", + "src/platform/cygwin.sh", + ) + + platform_files.filter("^#!.*$", f"#! {bash_exec}") + platform_files.filter('^GPG="gpg"$', f'GPG="{gpg_exec}"') + platform_files.filter('^GETOPT=".*"$', f'GETOPT="{getopt_exec}"') + platform_files.filter('^BASE64=".*"$', f'BASE64="{openssl_exec} base64"') diff --git a/var/spack/repos/builtin/packages/pastix/package.py b/var/spack/repos/builtin/packages/pastix/package.py index 18877d58b11713..6112d51ba0c3e1 100644 --- a/var/spack/repos/builtin/packages/pastix/package.py +++ b/var/spack/repos/builtin/packages/pastix/package.py @@ -12,17 +12,21 @@ class Pastix(CMakePackage, CudaPackage): based on direct methods""" homepage = "https://gitlab.inria.fr/solverstack/pastix/blob/master/README.md" - url = "https://files.inria.fr/pastix/releases/v6/pastix-6.3.2.tar.gz" + url = "https://files.inria.fr/pastix/releases/v6/pastix-6.4.0.tar.gz" git = "https://gitlab.inria.fr/solverstack/pastix.git" maintainers("fpruvost", "mfaverge", "ramet") version("master", branch="master", submodules=True) + version("6.4.0", sha256="891d426188eed56c1075fb34d2d80132593a1536ffc05cf333567f68a4811e55") version("6.3.2", sha256="c4da8802d1933eecf8c09d7e63c014c81ccf353fe623142e9f5c5fc65ed82ee0") version("6.3.1", sha256="290464d73b7d43356e4735a29932bf6f23a88e94ec7139ba7744c21e42c52681") version("6.3.0", sha256="a6bfec32a3279d7b24c5fc05885c6632d177e467f1584707c6fd7c42a8703c3e") version("6.2.2", sha256="cce9a1fe4678b5733c9f1a5a52f77b040eadc3e254418c6fb03d8ab37dede508") version("6.2.1", sha256="b680cbfc265df8cba18d3a7093fcc02e260198c4a2d6a86d1e684bb291e309dd") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # cmake's specific variant("shared", default=True, description="Build Pastix as a shared library") diff --git a/var/spack/repos/builtin/packages/patch/package.py b/var/spack/repos/builtin/packages/patch/package.py index f974ab01c25606..50bbda43bc4caa 100644 --- a/var/spack/repos/builtin/packages/patch/package.py +++ b/var/spack/repos/builtin/packages/patch/package.py @@ -22,4 +22,6 @@ class Patch(AutotoolsPackage, GNUMirrorPackage): version("2.7.6", sha256="ac610bda97abe0d9f6b7c963255a11dcb196c25e337c61f94e4778d632f1d8fd") version("2.7.5", sha256="fd95153655d6b95567e623843a0e77b81612d502ecf78a489a4aed7867caa299") + depends_on("c", type="build") # generated + build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/patchelf/package.py b/var/spack/repos/builtin/packages/patchelf/package.py index 3aa78aa604c3ea..f5f2c9742783e9 100644 --- a/var/spack/repos/builtin/packages/patchelf/package.py +++ b/var/spack/repos/builtin/packages/patchelf/package.py @@ -44,6 +44,9 @@ class Patchelf(AutotoolsPackage): version("0.9", sha256="f2aa40a6148cb3b0ca807a1bf836b081793e55ec9e5540a5356d800132be7e0a") version("0.8", sha256="14af06a2da688d577d64ff8dac065bb8903bbffbe01d30c62df7af9bf4ce72fe") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + conflicts("%gcc@:4.6", when="@0.10:", msg="Requires C++11 support") conflicts("%gcc@:6", when="@0.14:", msg="Requires C++17 support") conflicts("%clang@:3", when="@0.14:", msg="Requires C++17 support") diff --git a/var/spack/repos/builtin/packages/patchutils/package.py b/var/spack/repos/builtin/packages/patchutils/package.py index 407c7021aeb57a..ef0ee22a9e01dc 100644 --- a/var/spack/repos/builtin/packages/patchutils/package.py +++ b/var/spack/repos/builtin/packages/patchutils/package.py @@ -18,3 +18,5 @@ class Patchutils(AutotoolsPackage): version("0.4.2", sha256="8875b0965fe33de62b890f6cd793be7fafe41a4e552edbf641f1fed5ebbf45ed") version("0.4.0", sha256="da6df1fa662b635c2969e7d017e6f32f5b39f1b802673a0af635e4936d4bc2f4") version("0.3.4", sha256="cf55d4db83ead41188f5b6be16f60f6b76a87d5db1c42f5459d596e81dabe876") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/pathfinder/package.py b/var/spack/repos/builtin/packages/pathfinder/package.py index c6940f01920bc6..26f34d2e1ddfff 100644 --- a/var/spack/repos/builtin/packages/pathfinder/package.py +++ b/var/spack/repos/builtin/packages/pathfinder/package.py @@ -19,6 +19,8 @@ class Pathfinder(MakefilePackage): version("1.0.0", sha256="e002ff7df1ee9a6ee8a892fc208e047e2daf4215ff0d77e7ddc6b09d0506be16") + depends_on("c", type="build") # generated + build_targets = ["--directory=PathFinder_ref", "CC=cc"] def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/pax-utils/package.py b/var/spack/repos/builtin/packages/pax-utils/package.py index bf14c3c2792de0..aee7b4ced63668 100644 --- a/var/spack/repos/builtin/packages/pax-utils/package.py +++ b/var/spack/repos/builtin/packages/pax-utils/package.py @@ -17,3 +17,5 @@ class PaxUtils(AutotoolsPackage): version("1.3.3", sha256="eeca7fbd98bc66bead4a77000c2025d9f17ea8201b84245882406ce00b9b6b14") version("1.2.2", sha256="7f4a7f8db6b4743adde7582fa48992ad01776796fcde030683732f56221337d9") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/pbbam/package.py b/var/spack/repos/builtin/packages/pbbam/package.py index 65d1f6467f3c50..f0dc90cfaa92be 100644 --- a/var/spack/repos/builtin/packages/pbbam/package.py +++ b/var/spack/repos/builtin/packages/pbbam/package.py @@ -23,6 +23,8 @@ class Pbbam(MesonPackage): ) version("0.18.0", sha256="45286e5f7deb7ff629e0643c8a416155915aec7b85d54c60b5cdc07f4d7b234a") + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("boost@1.55.0:") depends_on("htslib@1.3.1:") diff --git a/var/spack/repos/builtin/packages/pblat/package.py b/var/spack/repos/builtin/packages/pblat/package.py index b62a96eb2a54e7..3c82805097c716 100644 --- a/var/spack/repos/builtin/packages/pblat/package.py +++ b/var/spack/repos/builtin/packages/pblat/package.py @@ -17,6 +17,8 @@ class Pblat(MakefilePackage): version("2.5.1", sha256="e85a4d752b8e159502d529f0f9e47579851a6b466b6c2f1f4d49f598642bc615") + depends_on("c", type="build") # generated + depends_on("openssl") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/pbmpi/package.py b/var/spack/repos/builtin/packages/pbmpi/package.py index f063f0cd843a4c..be59df98832008 100644 --- a/var/spack/repos/builtin/packages/pbmpi/package.py +++ b/var/spack/repos/builtin/packages/pbmpi/package.py @@ -21,6 +21,8 @@ class Pbmpi(MakefilePackage): version("1.8c", sha256="2a80ec4a98d92ace61c67ff9ba78249d45d03094b364959d490b1ad05797a279") version("partition", branch="partition") + depends_on("cxx", type="build") # generated + depends_on("mpi") depends_on("libfabric") diff --git a/var/spack/repos/builtin/packages/pciutils/package.py b/var/spack/repos/builtin/packages/pciutils/package.py index a2b8d2fdb3f07d..b066d797d71c5a 100644 --- a/var/spack/repos/builtin/packages/pciutils/package.py +++ b/var/spack/repos/builtin/packages/pciutils/package.py @@ -18,6 +18,8 @@ class Pciutils(MakefilePackage): version("3.6.4", sha256="551d0ac33f030868b7e95c29e58dc2b1882455dbc9c15c15adf7086e664131f1") version("3.6.3", sha256="7ab0fbb35cffa326eb852539260562bac14f3d27cda8c70bc2cf3211ed97c014") + depends_on("c", type="build") # generated + variant("lib", default=False, description="Install libraries with headers") def build(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/pcl/package.py b/var/spack/repos/builtin/packages/pcl/package.py index f0df251e5f0aae..4cc74a437d5daf 100644 --- a/var/spack/repos/builtin/packages/pcl/package.py +++ b/var/spack/repos/builtin/packages/pcl/package.py @@ -16,12 +16,16 @@ class Pcl(CMakePackage): license("BSD-3-Clause") + version("1.14.1", sha256="cc3dc26a9ea176cb588fb1f182324399dbaf11e5ba1bea95c7d39005b7a5d352") version("1.13.1", sha256="be4d499c066203a3c296e2f7e823d6209be5983415f2279310ed1c9abb361d30") version("1.13.0", sha256="bd110789f6a7416ed1c58da302afbdb80f8d297a9e23cc02fd78ab78b4762698") version("1.12.1", sha256="a9573efad5e024c02f2cc9180bb8f82605c3772c62463efbe25c5d6e634b91dc") version("1.12.0", sha256="606a2d5c7af304791731d6b8ea79365bc8f2cd75908006484d71ecee01d9b51c") version("1.11.1", sha256="19d1a0bee2bc153de47c05da54fc6feb23393f306ab2dea2e25419654000336e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.5:", type="build") depends_on("cmake@3.10:", when="@1.12.1:", type="build") depends_on("eigen@3.1:") diff --git a/var/spack/repos/builtin/packages/pcma/package.py b/var/spack/repos/builtin/packages/pcma/package.py index ce9a459056b6b1..0b7fc617a06c8b 100644 --- a/var/spack/repos/builtin/packages/pcma/package.py +++ b/var/spack/repos/builtin/packages/pcma/package.py @@ -15,6 +15,8 @@ class Pcma(MakefilePackage): version("2.0", sha256="4b92d412126d393baa3ede501cafe9606ada9a66af6217d56befd6ec2e0c01ba") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): makefile = FileFilter("makefile") makefile.filter("gcc", spack_cc) diff --git a/var/spack/repos/builtin/packages/pcre/package.py b/var/spack/repos/builtin/packages/pcre/package.py index 02d4ea0cd07878..4f7496f19c2bff 100644 --- a/var/spack/repos/builtin/packages/pcre/package.py +++ b/var/spack/repos/builtin/packages/pcre/package.py @@ -27,6 +27,9 @@ class Pcre(AutotoolsPackage, CMakePackage): version("8.39", sha256="b858099f82483031ee02092711689e7245586ada49e534a06e678b8ea9549e8b") version("8.38", sha256="b9e02d36e23024d6c02a2e5b25204b3a4fa6ade43e0a5f869f254f49535079df") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + maintainers("drkennetz") patch("intel.patch", when="@8.38") diff --git a/var/spack/repos/builtin/packages/pcre2/package.py b/var/spack/repos/builtin/packages/pcre2/package.py index d2bf686f89d83e..2e1f4c03f3be06 100644 --- a/var/spack/repos/builtin/packages/pcre2/package.py +++ b/var/spack/repos/builtin/packages/pcre2/package.py @@ -16,6 +16,7 @@ class Pcre2(AutotoolsPackage): license("BSD-3-Clause") + version("10.43", sha256="e2a53984ff0b07dfdb5ae4486bbb9b21cca8e7df2434096cc9bf1b728c350bcb") version("10.42", sha256="8d36cd8cb6ea2a4c2bb358ff6411b0c788633a2a45dabbf1aeb4b701d1b5e840") version("10.41", sha256="0f78cebd3e28e346475fb92e95fe9999945b4cbaad5f3b42aca47b887fb53308") version("10.40", sha256="14e4b83c4783933dc17e964318e6324f7cae1bc75d8f3c79bc6969f00c159d68") @@ -25,6 +26,8 @@ class Pcre2(AutotoolsPackage): version("10.31", sha256="e07d538704aa65e477b6a392b32ff9fc5edf75ab9a40ddfc876186c4ff4d68ac") version("10.20", sha256="332e287101c9e9567d1ed55391b338b32f1f72c5b5ee7cc81ef2274a53ad487a") + depends_on("c", type="build") # generated + variant("multibyte", default=True, description="Enable support for 16 and 32 bit characters.") variant("jit", default=False, description="enable Just-In-Time compiling support") diff --git a/var/spack/repos/builtin/packages/pcsclite/package.py b/var/spack/repos/builtin/packages/pcsclite/package.py index a531d14defd463..50a785c1e2648b 100644 --- a/var/spack/repos/builtin/packages/pcsclite/package.py +++ b/var/spack/repos/builtin/packages/pcsclite/package.py @@ -22,6 +22,8 @@ class Pcsclite(AutotoolsPackage): version("master", branch="master") version("1.9.8", sha256="502d80c557ecbee285eb99fe8703eeb667bcfe067577467b50efe3420d1b2289") + depends_on("c", type="build") # generated + # no libudev/systemd package currently in spack variant("libudev", default=False, description="Build with libudev") diff --git a/var/spack/repos/builtin/packages/pdal/package.py b/var/spack/repos/builtin/packages/pdal/package.py index 76f53662986f15..58c78abb7c36fd 100644 --- a/var/spack/repos/builtin/packages/pdal/package.py +++ b/var/spack/repos/builtin/packages/pdal/package.py @@ -26,6 +26,8 @@ class Pdal(CMakePackage): version("2.4.3", sha256="e1a910d593311e68b51f32d1f4f8fe4327b97ae7a8de209147b6111091b6f75b") version("2.3.0", sha256="8ae848e9b3fe5149a9277fe60e10b9858edb9a3cf1a40728f11712498e5da13a") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.13:", type="build") depends_on("gdal@3:") depends_on("gdal@3.4:", when="@2.6:") diff --git a/var/spack/repos/builtin/packages/pdc/package.py b/var/spack/repos/builtin/packages/pdc/package.py index 1915dbdbe29976..1c09eb56f6358a 100644 --- a/var/spack/repos/builtin/packages/pdc/package.py +++ b/var/spack/repos/builtin/packages/pdc/package.py @@ -14,13 +14,14 @@ class Pdc(CMakePackage): metadata operations to find data objects.""" homepage = "https://pdc.readthedocs.io/en/latest/" - url = "https://github.com/hpc-io/pdc/archive/refs/tags/0.4.tar.gz" + url = "https://github.com/hpc-io/pdc/archive/refs/tags/0.5.tar.gz" git = "https://github.com/hpc-io/pdc.git" maintainers("houjun", "sbyna", "jeanbez") license("BSD-3-Clause-LBNL") + version("0.5", sha256="d8ee6ad31670882dec8a9a131cd491a7134953acf3d18abf288605f3cc517636") version("0.4", sha256="eb2c2b69e5cdbca3210b8d72a646c16a2aa004ca08792f28cc6290a9a3ad6c8a") version("0.3", sha256="14a3abd5e1e604f9527105709fca545bcdebe51abd2b89884db74d48a38b5443") version( @@ -37,6 +38,9 @@ class Pdc(CMakePackage): version("stable", branch="stable") version("develop", branch="develop") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + conflicts("%clang") depends_on("libfabric") @@ -60,8 +64,4 @@ def cmake_args(self): self.define("PDC_ENABLE_MPI", "ON"), self.define("CMAKE_C_COMPILER", self.spec["mpi"].mpicc), ] - - if self.spec.satisfies("platform=cray"): - args.append("-DRANKSTR_LINK_STATIC=ON") - return args diff --git a/var/spack/repos/builtin/packages/pdf2svg/package.py b/var/spack/repos/builtin/packages/pdf2svg/package.py index b7a74e0e96eedf..9f190a14ca11d8 100644 --- a/var/spack/repos/builtin/packages/pdf2svg/package.py +++ b/var/spack/repos/builtin/packages/pdf2svg/package.py @@ -17,6 +17,8 @@ class Pdf2svg(AutotoolsPackage): version("0.2.3", sha256="4fb186070b3e7d33a51821e3307dce57300a062570d028feccd4e628d50dea8a") version("0.2.2", sha256="e5f1d9b78821e44cd85379fb07f38a42f00bb2bde3743b95301ff8c0a5ae229a") + depends_on("c", type="build") # generated + depends_on("pkgconfig@0.9.0:", type="build") depends_on("cairo@1.2.6:") depends_on("poppler@0.5.4:+glib") diff --git a/var/spack/repos/builtin/packages/pdsh/package.py b/var/spack/repos/builtin/packages/pdsh/package.py index 58872d3a3a8344..77be9d6305cf21 100644 --- a/var/spack/repos/builtin/packages/pdsh/package.py +++ b/var/spack/repos/builtin/packages/pdsh/package.py @@ -18,6 +18,8 @@ class Pdsh(AutotoolsPackage): version("2.31", sha256="0ee066ce395703285cf4f6cf00b54b7097d12457a4b1c146bc6f33d8ba73caa7") + depends_on("c", type="build") # generated + variant("ssh", default=True, description="Build with ssh module") variant("static_modules", default=True, description="Build with static modules") diff --git a/var/spack/repos/builtin/packages/pdt/package.py b/var/spack/repos/builtin/packages/pdt/package.py index bb414c0bf5684a..41a0d02a9fce63 100644 --- a/var/spack/repos/builtin/packages/pdt/package.py +++ b/var/spack/repos/builtin/packages/pdt/package.py @@ -38,6 +38,8 @@ class Pdt(AutotoolsPackage): version("3.19", sha256="d57234077e2e999f2acf9860ea84369a4694b50cc17fa6728e5255dc5f4a2160") version("3.18.1", sha256="d06c2d1793fadebf169752511e5046d7e02cf3fead6135a35c34b1fee6d6d3b2") + depends_on("cxx", type="build") # generated + variant("pic", default=False, description="Builds with pic") patch("cray_configure.patch", when="%cce") diff --git a/var/spack/repos/builtin/packages/pegtl/package.py b/var/spack/repos/builtin/packages/pegtl/package.py index af038366f46bd2..f8a98604309552 100644 --- a/var/spack/repos/builtin/packages/pegtl/package.py +++ b/var/spack/repos/builtin/packages/pegtl/package.py @@ -27,6 +27,8 @@ class Pegtl(CMakePackage): version("2.1.4", sha256="d990dccc07b4d9ba548326d11c5c5e34fa88b34fe113cb5377da03dda29f23f2") version("2.0.0", sha256="5aae0505077e051cae4d855c38049cc6cf71103a6cc8d0ddef01a576e8a60cc0") + depends_on("cxx", type="build") # generated + # Ref: https://github.com/taocpp/PEGTL/blob/master/src/example/pegtl/json_classes.hpp patch("change_to_virtual_destructor.patch", when="@:2.4") diff --git a/var/spack/repos/builtin/packages/pennant/package.py b/var/spack/repos/builtin/packages/pennant/package.py index bfce36fc5968b8..eb5fd1b8d66f65 100644 --- a/var/spack/repos/builtin/packages/pennant/package.py +++ b/var/spack/repos/builtin/packages/pennant/package.py @@ -25,6 +25,8 @@ class Pennant(MakefilePackage): version("0.5", sha256="21ef5889731fad0075f9dab8ffa97af8fd8ff87f6a5fe6434916b6e28cf64e43") version("0.4", sha256="65b81b92ed6fdbe407310948dd76ffb48cca155ee05c1f990a649faf81b45bb0") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Build with MPI support") variant("openmp", default=True, description="Build with OpenMP support") variant("debug", default=False, description="Enable debug") diff --git a/var/spack/repos/builtin/packages/percept/package.py b/var/spack/repos/builtin/packages/percept/package.py index 2680fe33bda575..7bfea43e800feb 100644 --- a/var/spack/repos/builtin/packages/percept/package.py +++ b/var/spack/repos/builtin/packages/percept/package.py @@ -20,6 +20,8 @@ class Percept(CMakePackage): # here and the patch allows us to build the mesh_transfer exe and # creates a make install target so Spack can install Percept version("master", commit="363cdd0050443760d54162f140b2fb54ed9decf0") + + depends_on("cxx", type="build") # generated patch("cmakelists.patch") depends_on("googletest~shared") diff --git a/var/spack/repos/builtin/packages/percona-server/package.py b/var/spack/repos/builtin/packages/percona-server/package.py index 6a7203cd5efce7..bd7de28d111623 100644 --- a/var/spack/repos/builtin/packages/percona-server/package.py +++ b/var/spack/repos/builtin/packages/percona-server/package.py @@ -20,6 +20,9 @@ class PerconaServer(CMakePackage): version("8.0.19-10", sha256="f2f979bd7dfb4d62aef79b7c488070d5d599341a6acbb295400f1d68257cbd80") version("8.0.18-9", sha256="e79a8c1ae5f2271c0b344494a299a9bbbada88d3bce87449b7de274d17d1ccd0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost@1.70.0") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/perfstubs/package.py b/var/spack/repos/builtin/packages/perfstubs/package.py index 699521a631bbde..993e1567403a4c 100644 --- a/var/spack/repos/builtin/packages/perfstubs/package.py +++ b/var/spack/repos/builtin/packages/perfstubs/package.py @@ -24,6 +24,10 @@ class Perfstubs(CMakePackage): license("BSD-3-Clause") version("master", branch="master") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant("static", default=False, description="Build static executable support") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/perl-alien-build/package.py b/var/spack/repos/builtin/packages/perl-alien-build/package.py index 74799af883a283..15f41fc09cd930 100644 --- a/var/spack/repos/builtin/packages/perl-alien-build/package.py +++ b/var/spack/repos/builtin/packages/perl-alien-build/package.py @@ -19,6 +19,8 @@ class PerlAlienBuild(PerlPackage): version("2.78", sha256="9140671790a0696920b0a97acd812ab4d0b93ac69306d20679f027dd0c7caa27") version("1.86", sha256="f856a46aea72fe77daea5b1788b4ea0dc215f5704f5a35fa063171be8523e4e9") + depends_on("c", type="build") # generated + depends_on("perl-capture-tiny", type=("build", "run")) depends_on("perl-ffi-checklib", type=("build", "run")) depends_on("perl-file-which", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-alien-svn/package.py b/var/spack/repos/builtin/packages/perl-alien-svn/package.py index 94b06b1bde9aa3..f75341d10c354b 100644 --- a/var/spack/repos/builtin/packages/perl-alien-svn/package.py +++ b/var/spack/repos/builtin/packages/perl-alien-svn/package.py @@ -22,6 +22,9 @@ class PerlAlienSvn(PerlPackage): version("1.7.3.0", sha256="02abbe17ad7db912001e6f1c5018cec08c3840e0c32700363a79274e144e74e5") version("1.6.12.1", sha256="a89d8eeff61e34aa7b3d35dee3e6752b12dfa5f0f04bf69d796846cf0391f53d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl-module-build", type="build") depends_on("apr@1.6.2", type="build") depends_on("apr-util", type=("build", "link")) diff --git a/var/spack/repos/builtin/packages/perl-bignum/package.py b/var/spack/repos/builtin/packages/perl-bignum/package.py index 828fc8578bafb5..3ddd4e8ec8bfea 100644 --- a/var/spack/repos/builtin/packages/perl-bignum/package.py +++ b/var/spack/repos/builtin/packages/perl-bignum/package.py @@ -12,6 +12,7 @@ class PerlBignum(PerlPackage): homepage = "https://github.com/pjacklam/p5-bignum" url = "https://cpan.metacpan.org/authors/id/P/PJ/PJACKLAM/bignum-0.66.tar.gz" + version("0.67", sha256="1c9a824ab323e3e58d9808011c10ad27589dba1202806278215012ca7f522875") version("0.66", sha256="26d48fb4b63a4b738ab84b577f9de7cdec164fe5f8a7089010a1ec17e127ed97") depends_on("perl@5.6.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-bioperl/package.py b/var/spack/repos/builtin/packages/perl-bioperl/package.py index abe4ab450ae442..ddbcc265b69c59 100644 --- a/var/spack/repos/builtin/packages/perl-bioperl/package.py +++ b/var/spack/repos/builtin/packages/perl-bioperl/package.py @@ -49,6 +49,8 @@ class PerlBioperl(PerlPackage): url="https://cpan.metacpan.org/authors/id/C/CJ/CJFIELDS/BioPerl-1.007002.tar.gz", ) + depends_on("fortran", type="build") # generated + # According to cpandeps.grinnz.com Module-Build is both a build and run # time dependency for BioPerl depends_on("perl-module-build", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-bit-vector/package.py b/var/spack/repos/builtin/packages/perl-bit-vector/package.py index f48e8c993adaa7..ecf719976e91d1 100644 --- a/var/spack/repos/builtin/packages/perl-bit-vector/package.py +++ b/var/spack/repos/builtin/packages/perl-bit-vector/package.py @@ -16,4 +16,6 @@ class PerlBitVector(PerlPackage): version("7.4", sha256="3c6daa671fecfbc35f92a9385b563d65f50dfc6bdc8b4805f9ef46c0d035a926") + depends_on("c", type="build") # generated + depends_on("perl-carp-clan", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-cairo/package.py b/var/spack/repos/builtin/packages/perl-cairo/package.py index 828cbc64aefda9..343f902c62a070 100644 --- a/var/spack/repos/builtin/packages/perl-cairo/package.py +++ b/var/spack/repos/builtin/packages/perl-cairo/package.py @@ -14,6 +14,7 @@ class PerlCairo(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("1.109", sha256="8219736e401c2311da5f515775de43fd87e6384b504da36a192f2b217643077f") version("1.106", sha256="e64803018bc7cba49e73e258547f5378cc4249797beafec524852140f49c45c4") depends_on("cairo") diff --git a/var/spack/repos/builtin/packages/perl-compress-raw-bzip2/package.py b/var/spack/repos/builtin/packages/perl-compress-raw-bzip2/package.py index e3d5727399c5ea..21791aa84215dd 100644 --- a/var/spack/repos/builtin/packages/perl-compress-raw-bzip2/package.py +++ b/var/spack/repos/builtin/packages/perl-compress-raw-bzip2/package.py @@ -14,8 +14,11 @@ class PerlCompressRawBzip2(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("2.212", sha256="6caeee843c428f45fa9646ea98dc675470db63dbac0ee3e2d8e9ee4eb58a856d") version("2.204", sha256="ee7b490e67e7e2a7a0e8c1e1aa29a9610066149f46b836921149ad1813f70c69") version("2.081", sha256="8692b5c9db91954408e24e805fbfda222879da80d89d9410791421e3e5bc3520") + depends_on("c", type="build") # generated + depends_on("bzip2") depends_on("perl-extutils-makemaker", type="build") diff --git a/var/spack/repos/builtin/packages/perl-compress-raw-zlib/package.py b/var/spack/repos/builtin/packages/perl-compress-raw-zlib/package.py index 318c47cd6363f0..8006b3a58fa471 100644 --- a/var/spack/repos/builtin/packages/perl-compress-raw-zlib/package.py +++ b/var/spack/repos/builtin/packages/perl-compress-raw-zlib/package.py @@ -14,9 +14,12 @@ class PerlCompressRawZlib(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("2.212", sha256="6d9de0c11921fd520dfd99a3f6b0ca9f1fd9850274f8bec10bbaa4f6803cc049") version("2.206", sha256="46785a6a383a1c843895b7f9f25d5d759e7c305159f9d1e04a3604eb74c77374") version("2.204", sha256="f161f4297efadbed79c8b096a75951784fc5ccd3170bd32866a19e5c6876d13f") version("2.081", sha256="e156de345bd224bbdabfcab0eeb3f678a3099a4e86c9d1b6771d880b55aa3a1b") + depends_on("c", type="build") # generated + depends_on("zlib-api") depends_on("perl-extutils-makemaker", type="build") diff --git a/var/spack/repos/builtin/packages/perl-config-general/package.py b/var/spack/repos/builtin/packages/perl-config-general/package.py index 3397394fb0817d..e7371fd1a22753 100644 --- a/var/spack/repos/builtin/packages/perl-config-general/package.py +++ b/var/spack/repos/builtin/packages/perl-config-general/package.py @@ -16,3 +16,5 @@ class PerlConfigGeneral(PerlPackage): version("2.65", sha256="4d6d5754be3a9f30906836f0cc10e554c8832e14e7a1341efb15b05d706fc58f") version("2.63", sha256="0a9bf977b8aabe76343e88095d2296c8a422410fd2a05a1901f2b20e2e1f6fad") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/perl-data-stag/package.py b/var/spack/repos/builtin/packages/perl-data-stag/package.py index 94d8e5e7f8ce14..3184c827796e82 100644 --- a/var/spack/repos/builtin/packages/perl-data-stag/package.py +++ b/var/spack/repos/builtin/packages/perl-data-stag/package.py @@ -14,4 +14,6 @@ class PerlDataStag(PerlPackage): version("0.14", sha256="4ab122508d2fb86d171a15f4006e5cf896d5facfa65219c0b243a89906258e59") + depends_on("c", type="build") # generated + depends_on("perl-io-string", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-db-file/package.py b/var/spack/repos/builtin/packages/perl-db-file/package.py index c28ff8ad0077fd..08725e63c3d94e 100644 --- a/var/spack/repos/builtin/packages/perl-db-file/package.py +++ b/var/spack/repos/builtin/packages/perl-db-file/package.py @@ -17,9 +17,12 @@ class PerlDbFile(PerlPackage): homepage = "https://metacpan.org/pod/DB_File" url = "https://cpan.metacpan.org/authors/id/P/PM/PMQS/DB_File-1.840.tar.gz" + version("1.859", sha256="5674e0d2cd0b060c4d1253670ea022c64d842a55257f9eb8edb19c0f53e2565c") version("1.858", sha256="ceb7a2868bd71f87b31e8b7c38d6f8cc0a31fb0322a377ee448994f094d0a7f6") version("1.840", sha256="b7864707fad0f2d1488c748c4fa08f1fb8bcfd3da247c36909fd42f20bfab2c4") + depends_on("c", type="build") # generated + depends_on("perl-extutils-makemaker", type="build") depends_on("berkeley-db", type="build") diff --git a/var/spack/repos/builtin/packages/perl-dbd-mysql/package.py b/var/spack/repos/builtin/packages/perl-dbd-mysql/package.py index 0cdf051ce06c56..9ce4fbe00c2f03 100644 --- a/var/spack/repos/builtin/packages/perl-dbd-mysql/package.py +++ b/var/spack/repos/builtin/packages/perl-dbd-mysql/package.py @@ -14,6 +14,17 @@ class PerlDbdMysql(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version( + "5.005", + sha256="1558c203b3911e273d3f83249535b312165be2ca8edba6b6c210645d769d0541", + url="https://cpan.metacpan.org/authors/id/D/DV/DVEEDEN/DBD-mysql-5.005.tar.gz", + ) + version( + "4.052", + sha256="a83f57af7817787de0ef56fb15fdfaf4f1c952c8f32ff907153b66d2da78ff5b", + url="https://cpan.metacpan.org/authors/id/D/DV/DVEEDEN/DBD-mysql-4.052.tar.gz", + ) + version( "4.050", sha256="4f48541ff15a0a7405f76adc10f81627c33996fbf56c95c26c094444c0928d78", @@ -21,7 +32,21 @@ class PerlDbdMysql(PerlPackage): ) version("4.043", sha256="629f865e8317f52602b2f2efd2b688002903d2e4bbcba5427cb6188b043d6f99") + depends_on("c", type="build") # generated + depends_on("perl-devel-checklib", type="build", when="@4.050:") - depends_on("perl-test-deep", type=("build", "run")) - depends_on("perl-dbi", type=("build", "run")) - depends_on("mysql-client") + + with default_args(type=("build", "link", "run")): + # Does it's own version check and mariadb doesn't conform to it's + # strict checking. This could probably be patched in the future. + depends_on("mysql@4:", when="@4") + depends_on("mysql@8", when="@5") + + with default_args(type=("build", "run")): + depends_on("perl-test-deep") + depends_on("perl-dbi") + + def configure_args(self): + # Work around mysql_config providing incorrect linker args + mysql = self.spec["mysql-client"].prefix + return [f"--cflags=-I{mysql.include}", f"--libs=-L{mysql.lib} -lmysqlclient"] diff --git a/var/spack/repos/builtin/packages/perl-dbd-oracle/package.py b/var/spack/repos/builtin/packages/perl-dbd-oracle/package.py index 5b755fb8c84bc4..05d00d17e02846 100644 --- a/var/spack/repos/builtin/packages/perl-dbd-oracle/package.py +++ b/var/spack/repos/builtin/packages/perl-dbd-oracle/package.py @@ -16,6 +16,8 @@ class PerlDbdOracle(PerlPackage): version("1.83", sha256="51fe9c158955fda0ca917a806863f0bc51068b533fbbc7423b3cc4ad595ed153") + depends_on("c", type="build") # generated + depends_on("perl@5.8.0:", type=("build", "link", "run", "test")) depends_on("perl-dbi@1.623:", type=("build", "run", "test")) depends_on("perl-test-nowarnings", type=("build", "link")) diff --git a/var/spack/repos/builtin/packages/perl-dbd-pg/package.py b/var/spack/repos/builtin/packages/perl-dbd-pg/package.py index 7b6e708bc1b32d..272e1fd6d588b0 100644 --- a/var/spack/repos/builtin/packages/perl-dbd-pg/package.py +++ b/var/spack/repos/builtin/packages/perl-dbd-pg/package.py @@ -15,8 +15,11 @@ class PerlDbdPg(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("3.18.0", sha256="92bbe8a363040f8ce6a3f1963f128132e245861a9b4dc5a84178b42d625a7807") version("3.16.1", sha256="8e917a746dacb1edce5832d8911e5938cc4863aeac4a52820382e7d174e9c3b9") version("3.10.0", sha256="e103268a63e2828e3d43659bdba5f743446cbbe047a766f843112eedae105f80") + depends_on("c", type="build") # generated + depends_on("postgresql") depends_on("perl-dbi", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-dbd-sqlite/package.py b/var/spack/repos/builtin/packages/perl-dbd-sqlite/package.py index 36f8bfce69ad14..8d96305c7e9cd8 100644 --- a/var/spack/repos/builtin/packages/perl-dbd-sqlite/package.py +++ b/var/spack/repos/builtin/packages/perl-dbd-sqlite/package.py @@ -14,10 +14,13 @@ class PerlDbdSqlite(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("1.74", sha256="8994997d84b9feb4547795f78746c661fb72e3cb6a25dbdd789b731f5688a4dd") version("1.72", sha256="5ca41e61eb52b52bd862a3088b912a75fe70910ac789b9a9983e0a449e94f551") version("1.59_01", sha256="b6f331e4054688572c2010e72c355f7ba3f30d86051e50d9925d34d9df1001e2") version("1.58", sha256="7120dd99d0338dea2802fda8bfe3fbf10077d5af559f6c67ae35e9270d1a1d3b") version("1.57_01", sha256="fa7fb111fa8bfc257c3208f8980ac802a9cac4531ab98afc1988b88929672184") version("1.56", sha256="c5f831a67a94f9bb2fb3c44051f309fc7994b2725d1896c018ad5d4cd865e991") + depends_on("c", type="build") # generated + depends_on("perl-dbi", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-devel-cover/package.py b/var/spack/repos/builtin/packages/perl-devel-cover/package.py index 0734d38345c322..dd5704ffd3f867 100644 --- a/var/spack/repos/builtin/packages/perl-devel-cover/package.py +++ b/var/spack/repos/builtin/packages/perl-devel-cover/package.py @@ -14,4 +14,5 @@ class PerlDevelCover(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("1.42", sha256="cb9c45dee359f3d259856450389df270e2ecea1b49f5f8800fdb972ff50bbebb") version("1.40", sha256="26e2f431fbcf7bff3851f352f83b84067c09ff206f40ab975cad8d2bafe711a8") diff --git a/var/spack/repos/builtin/packages/perl-devel-stacktrace/package.py b/var/spack/repos/builtin/packages/perl-devel-stacktrace/package.py index 4b7c3184bcbfd6..11d7a409ddf918 100644 --- a/var/spack/repos/builtin/packages/perl-devel-stacktrace/package.py +++ b/var/spack/repos/builtin/packages/perl-devel-stacktrace/package.py @@ -14,5 +14,6 @@ class PerlDevelStacktrace(PerlPackage): license("Artistic-2.0") + version("2.05", sha256="63cb6196e986a7e578c4d28b3c780e7194835bfc78b68eeb8f00599d4444888c") version("2.04", sha256="cd3c03ed547d3d42c61fa5814c98296139392e7971c092e09a431f2c9f5d6855") version("2.02", sha256="cbbd96db0ecf194ed140198090eaea0e327d9a378a4aa15f9a34b3138a91931f") diff --git a/var/spack/repos/builtin/packages/perl-email-address-xs/package.py b/var/spack/repos/builtin/packages/perl-email-address-xs/package.py index 569788ad1e6c04..2847f52b52413d 100644 --- a/var/spack/repos/builtin/packages/perl-email-address-xs/package.py +++ b/var/spack/repos/builtin/packages/perl-email-address-xs/package.py @@ -16,4 +16,6 @@ class PerlEmailAddressXs(PerlPackage): version("1.05", sha256="1510b7f10d67201037cd50d22c9d6b26eeca55ededa4cdb46bbca27e59a4ea16") + depends_on("c", type="build") # generated + depends_on("perl@5.6.0:", type=("build", "link", "run", "test")) diff --git a/var/spack/repos/builtin/packages/perl-extutils-config/package.py b/var/spack/repos/builtin/packages/perl-extutils-config/package.py index 6f8ec7c689a90c..2de21f01899983 100644 --- a/var/spack/repos/builtin/packages/perl-extutils-config/package.py +++ b/var/spack/repos/builtin/packages/perl-extutils-config/package.py @@ -14,4 +14,5 @@ class PerlExtutilsConfig(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("0.009", sha256="4ef84e73aad50a3be332885d2a3b12f3cab1b1e0bad24e88297a123b4f39f3ce") version("0.008", sha256="ae5104f634650dce8a79b7ed13fb59d67a39c213a6776cfdaa3ee749e62f1a8c") diff --git a/var/spack/repos/builtin/packages/perl-extutils-installpaths/package.py b/var/spack/repos/builtin/packages/perl-extutils-installpaths/package.py index cb583055eefcb0..747ff747fac248 100644 --- a/var/spack/repos/builtin/packages/perl-extutils-installpaths/package.py +++ b/var/spack/repos/builtin/packages/perl-extutils-installpaths/package.py @@ -14,6 +14,7 @@ class PerlExtutilsInstallpaths(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("0.013", sha256="65969d3ad8a3a2ea8ef5b4213ed5c2c83961bb5bd12f7ad35128f6bd5b684aa0") version("0.012", sha256="84735e3037bab1fdffa3c2508567ad412a785c91599db3c12593a50a1dd434ed") depends_on("perl-extutils-config", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-fth/package.py b/var/spack/repos/builtin/packages/perl-fth/package.py index 865e5693b5371d..1fd728ec2a3fb4 100644 --- a/var/spack/repos/builtin/packages/perl-fth/package.py +++ b/var/spack/repos/builtin/packages/perl-fth/package.py @@ -23,10 +23,11 @@ class PerlFth(Package): """ homepage = "https://sourceforge.net/projects/ftagshtml/" - url = "https://downloads.sourceforge.net/project/ftagshtml/ftagshtml-0.524.tgz" + url = "https://downloads.sourceforge.net/project/ftagshtml/ftagshtml-0.529.tgz" maintainers("cessenat") + version("0.529", sha256="3cc2030372cf88dad257bd0cfbe662873a454d55035c54a76090e0da860074c4") version("0.527", sha256="df98e9e2f4dbef863b09a22ed92681dff028a6f345ba530bc3afd8221efe633c") version("0.526", sha256="ada1c7306111d59d64572fe8a9b038026fd0daebaff630924997ef2dc22d87a8") version("0.525", sha256="378116febeb20f4b0c1e298de90305e8494335949d853c7e390d1b6386c1326a") @@ -39,6 +40,9 @@ class PerlFth(Package): version("0.518", sha256="7aed7c831270bb1935d4ccd090ef1360ec9446dd773c10350645985047f8879b") version("0.517", sha256="e24488a7edbfa764060f007693329d5ee3154e1ce49a627ec109c41a9d7abcbe") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "hevea", default=False, description="Use hevea when inputting LaTeX files (fth.pl -hevea)" ) diff --git a/var/spack/repos/builtin/packages/perl-gd/package.py b/var/spack/repos/builtin/packages/perl-gd/package.py index be7651d7ae343d..0bb317073f4db8 100644 --- a/var/spack/repos/builtin/packages/perl-gd/package.py +++ b/var/spack/repos/builtin/packages/perl-gd/package.py @@ -14,6 +14,7 @@ class PerlGd(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("2.81", sha256="21df5d9c5ced9971f661a69d1c80312bc59d27afdba17a242ac2e8c870b635d5") version("2.77", sha256="b56c88b8ef3be016ce29bb62dd1f1b6f6b5fbcaa57fea59e9468af6901016fb5") version("2.53", sha256="d05d01fe95e581adb3468cf05ab5d405db7497c0fb3ec7ecf23d023705fab7aa") diff --git a/var/spack/repos/builtin/packages/perl-gzip-faster/package.py b/var/spack/repos/builtin/packages/perl-gzip-faster/package.py index 30628b8cf1192f..bf0a140804d90e 100644 --- a/var/spack/repos/builtin/packages/perl-gzip-faster/package.py +++ b/var/spack/repos/builtin/packages/perl-gzip-faster/package.py @@ -18,4 +18,6 @@ class PerlGzipFaster(PerlPackage): version("0.21", sha256="c65f41ca108e7e53ec34c30dbb1b5d614bf4b8100673646cf301d0caf82c7aa5") + depends_on("c", type="build") # generated + depends_on("perl@5.8.1:", type=("build", "link", "run", "test")) diff --git a/var/spack/repos/builtin/packages/perl-html-parser/package.py b/var/spack/repos/builtin/packages/perl-html-parser/package.py index 6f1cbfc160d6d6..09b9139501a480 100644 --- a/var/spack/repos/builtin/packages/perl-html-parser/package.py +++ b/var/spack/repos/builtin/packages/perl-html-parser/package.py @@ -16,4 +16,6 @@ class PerlHtmlParser(PerlPackage): version("3.72", sha256="ec28c7e1d9e67c45eca197077f7cdc41ead1bb4c538c7f02a3296a4bb92f608b") + depends_on("c", type="build") # generated + depends_on("perl-html-tagset", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-html-tagset/package.py b/var/spack/repos/builtin/packages/perl-html-tagset/package.py index c9061bc57ea190..38dbf56dcb8e44 100644 --- a/var/spack/repos/builtin/packages/perl-html-tagset/package.py +++ b/var/spack/repos/builtin/packages/perl-html-tagset/package.py @@ -14,4 +14,5 @@ class PerlHtmlTagset(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("3.24", sha256="eb89e145a608ed1f8f141a57472ee5f69e67592a432dcd2e8b1dbb445f2b230b") version("3.20", sha256="adb17dac9e36cd011f5243881c9739417fd102fce760f8de4e9be4c7131108e2") diff --git a/var/spack/repos/builtin/packages/perl-http-message/package.py b/var/spack/repos/builtin/packages/perl-http-message/package.py index 202080cd034405..e548cd55ead859 100644 --- a/var/spack/repos/builtin/packages/perl-http-message/package.py +++ b/var/spack/repos/builtin/packages/perl-http-message/package.py @@ -14,6 +14,7 @@ class PerlHttpMessage(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("6.45", sha256="01cb8406612a3f738842d1e97313ae4d874870d1b8d6d66331f16000943d4cbe") version("6.44", sha256="398b647bf45aa972f432ec0111f6617742ba32fc773c6612d21f64ab4eacbca1") version("6.13", sha256="f25f38428de851e5661e72f124476494852eb30812358b07f1c3a289f6f5eded") diff --git a/var/spack/repos/builtin/packages/perl-http-parser-xs/package.py b/var/spack/repos/builtin/packages/perl-http-parser-xs/package.py index 33ee14b5ea266e..9bae76faa43530 100644 --- a/var/spack/repos/builtin/packages/perl-http-parser-xs/package.py +++ b/var/spack/repos/builtin/packages/perl-http-parser-xs/package.py @@ -17,3 +17,5 @@ class PerlHttpParserXs(PerlPackage): license("Artistic-1.0-Perl OR GPL-1.0-or-later") version("0.17", sha256="794e6833e326b10d24369f9cdbfc1667105ef6591e8f41e561a3d41a7027a809") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/perl-http-tiny/package.py b/var/spack/repos/builtin/packages/perl-http-tiny/package.py new file mode 100644 index 00000000000000..1a3250252923c8 --- /dev/null +++ b/var/spack/repos/builtin/packages/perl-http-tiny/package.py @@ -0,0 +1,23 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class PerlHttpTiny(PerlPackage): + """HTTP::Tiny: A small, simple, correct HTTP/1.1 client perl module""" + + homepage = "https://github.com/Perl-Toolchain-Gang/HTTP-Tiny" + url = "https://cpan.metacpan.org/authors/id/D/DA/DAGOLDEN/HTTP-Tiny-0.088.tar.gz" + + maintainers("teaguesterling") + + # Stated: same as perl5 + license("Artistic-1.0-Perl OR GPL-1.0-or-later", checked_by="teaguesterling") + + version("0.088", sha256="7ce6367e861883b6868d6dd86168af33524717d8cc94100c2abf9bd86a82b4d8") + version("0.086", sha256="c616e0ff9ec808a7a92f47edb7d017fc45ef0c2cddd21a9bab194096cb6b7b32") + + with default_args(type=("build", "run")): + depends_on("perl-carp") diff --git a/var/spack/repos/builtin/packages/perl-io-socket-ssl/package.py b/var/spack/repos/builtin/packages/perl-io-socket-ssl/package.py index 7463880ad49f34..143360fd204519 100644 --- a/var/spack/repos/builtin/packages/perl-io-socket-ssl/package.py +++ b/var/spack/repos/builtin/packages/perl-io-socket-ssl/package.py @@ -16,6 +16,7 @@ class PerlIoSocketSsl(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("2.085", sha256="95b2f7c0628a7e246a159665fbf0620d0d7835e3a940f22d3fdd47c3aa799c2e") version("2.052", sha256="e4897a9b17cb18a3c44aa683980d52cef534cdfcb8063d6877c879bfa2f26673") depends_on("perl-net-ssleay", type=("build", "run")) @@ -31,4 +32,4 @@ def configure(self, spec, prefix): f.writelines(config_answers) with open(config_answers_filename, "r") as f: - inspect.getmodule(self).perl("Makefile.PL", "INSTALL_BASE={0}".format(prefix), input=f) + inspect.getmodule(self).perl("Makefile.PL", f"INSTALL_BASE={prefix}", input=f) diff --git a/var/spack/repos/builtin/packages/perl-io-tty/package.py b/var/spack/repos/builtin/packages/perl-io-tty/package.py index 4be01b572c074b..af0da3ed9c115a 100644 --- a/var/spack/repos/builtin/packages/perl-io-tty/package.py +++ b/var/spack/repos/builtin/packages/perl-io-tty/package.py @@ -16,5 +16,6 @@ class PerlIoTty(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("1.20", sha256="b15309fc85623893289cb9b2b88dfa9ed1e69156b75f29938553a45be6d730af") version("1.17", sha256="a5f1a83020bc5b5dd6c1b570f48c7546e0a8f7fac10a068740b03925ad9e14e8") version("1.13_01", sha256="89798eba7c31d9c169ef2f38ff49490aa769b1d9a68033de365595cfaf9cc258") diff --git a/var/spack/repos/builtin/packages/perl-ipc-run/package.py b/var/spack/repos/builtin/packages/perl-ipc-run/package.py index c951d3b315e9f2..b7256ba7079990 100644 --- a/var/spack/repos/builtin/packages/perl-ipc-run/package.py +++ b/var/spack/repos/builtin/packages/perl-ipc-run/package.py @@ -17,6 +17,9 @@ class PerlIpcRun(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version( + "20231003.0", sha256="eb25bbdf5913d291797ef1bfe998f15130b455d3ed02aacde6856f0b25e4fe57" + ) version( "20220807.0", sha256="277d781dbbc98af18e979c7ef36f222513d7361742c52507c3348b265f6f5e69" ) diff --git a/var/spack/repos/builtin/packages/perl-ipc-sharelite/package.py b/var/spack/repos/builtin/packages/perl-ipc-sharelite/package.py index 6b2c01349e4c57..fa6d5908181874 100644 --- a/var/spack/repos/builtin/packages/perl-ipc-sharelite/package.py +++ b/var/spack/repos/builtin/packages/perl-ipc-sharelite/package.py @@ -17,3 +17,5 @@ class PerlIpcSharelite(PerlPackage): license("Artistic-1.0-Perl OR GPL-1.0-or-later") version("0.17", sha256="14d406b91da96d6521d0d1a82d22a306274765226b86b0a56e7ffddcf96ae7bf") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/perl-json/package.py b/var/spack/repos/builtin/packages/perl-json/package.py index 16387789976d4b..5ffad50b64ec95 100644 --- a/var/spack/repos/builtin/packages/perl-json/package.py +++ b/var/spack/repos/builtin/packages/perl-json/package.py @@ -16,3 +16,12 @@ class PerlJson(PerlPackage): version("4.10", sha256="df8b5143d9a7de99c47b55f1a170bd1f69f711935c186a6dc0ab56dd05758e35") version("2.97001", sha256="e277d9385633574923f48c297e1b8acad3170c69fa590e31fa466040fc6f8f5a") + + variant( + "json-xs", + default=True, + description="""Makes the preferred backend JSON::XS available to avoid defaulting to the + slower JSON::PP""", + ) + + depends_on("perl-json-xs", when="+json-xs", type=("run")) diff --git a/var/spack/repos/builtin/packages/perl-math-bigint/package.py b/var/spack/repos/builtin/packages/perl-math-bigint/package.py index 655ea9fe897f9d..ec09e393dddf92 100644 --- a/var/spack/repos/builtin/packages/perl-math-bigint/package.py +++ b/var/spack/repos/builtin/packages/perl-math-bigint/package.py @@ -12,5 +12,6 @@ class PerlMathBigint(PerlPackage): homepage = "https://metacpan.org/pod/Math::BigInt" url = "https://cpan.metacpan.org/authors/id/P/PJ/PJACKLAM/Math-BigInt-1.999837.tar.gz" + version("2.003002", sha256="5ac1fd255cca29d7cf5cb9283e6bb8177cdb07c5bb97502a58084b1c6eace35c") version("1.999838", sha256="d3c2fb37d412ac8d126452caad5764f02193147261b59c56e652167c41d1e9d5") version("1.999837", sha256="038f9aad6318f20a84a7b1afe3087a1b02406c9988ce5919311a797f85a32962") diff --git a/var/spack/repos/builtin/packages/perl-math-cdf/package.py b/var/spack/repos/builtin/packages/perl-math-cdf/package.py index 1b29e2f11c044b..01df08643da92d 100644 --- a/var/spack/repos/builtin/packages/perl-math-cdf/package.py +++ b/var/spack/repos/builtin/packages/perl-math-cdf/package.py @@ -14,3 +14,5 @@ class PerlMathCdf(PerlPackage): url = "http://search.cpan.org/CPAN/authors/id/C/CA/CALLAHAN/Math-CDF-0.1.tar.gz" version("0.1", sha256="7896bf250835ce47dcc813cb8cf9dc576c5455de42e822dcd7d8d3fef2125565") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/perl-math-cephes/package.py b/var/spack/repos/builtin/packages/perl-math-cephes/package.py index 3bc07147754af4..1389c02e9d3373 100644 --- a/var/spack/repos/builtin/packages/perl-math-cephes/package.py +++ b/var/spack/repos/builtin/packages/perl-math-cephes/package.py @@ -16,3 +16,5 @@ class PerlMathCephes(PerlPackage): license("Artistic-1.0") version("0.5305", sha256="561a800a4822e748d2befc366baa4b21e879a40cc00c22293c7b8736caeb83a1") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/perl-mce/package.py b/var/spack/repos/builtin/packages/perl-mce/package.py index 7ca21f4107fe5f..ca6497a2daa795 100644 --- a/var/spack/repos/builtin/packages/perl-mce/package.py +++ b/var/spack/repos/builtin/packages/perl-mce/package.py @@ -21,5 +21,6 @@ class PerlMce(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("1.889", sha256="db6153e474d046fc253050bf53c54002d84cd4ca77d21c2b9df56feeb809bbed") version("1.884", sha256="c830c0e548094f19c620049e744258be2c121d4a86cf7c94a37599ad016daf33") version("1.874", sha256="d809e3018475115ad7eccb8bef49bde3bf3e75abbbcd80564728bbcfab86d3d0") diff --git a/var/spack/repos/builtin/packages/perl-module-build-tiny/package.py b/var/spack/repos/builtin/packages/perl-module-build-tiny/package.py index e7475e213bf3db..333c7448ef51f4 100644 --- a/var/spack/repos/builtin/packages/perl-module-build-tiny/package.py +++ b/var/spack/repos/builtin/packages/perl-module-build-tiny/package.py @@ -14,6 +14,7 @@ class PerlModuleBuildTiny(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("0.048", sha256="79a73e506fb7badabdf79137a45c6c5027daaf6f9ac3dcfb9d4ffcce92eb36bd") version("0.044", sha256="cb053a3049cb717dbf4fd7f3c7ab7c0cb1015b22e2d93f38b1ffc47c078322fd") version("0.039", sha256="7d580ff6ace0cbe555bf36b86dc8ea232581530cbeaaea09bccb57b55797f11c") diff --git a/var/spack/repos/builtin/packages/perl-module-build/package.py b/var/spack/repos/builtin/packages/perl-module-build/package.py index 62c1822d59229d..248c78789f1e09 100644 --- a/var/spack/repos/builtin/packages/perl-module-build/package.py +++ b/var/spack/repos/builtin/packages/perl-module-build/package.py @@ -20,6 +20,7 @@ class PerlModuleBuild(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("0.4234", sha256="66aeac6127418be5e471ead3744648c766bd01482825c5b66652675f2bc86a8f") version("0.4232", sha256="67c82ee245d94ba06decfa25572ab75fdcd26a9009094289d8f45bc54041771b") version("0.4224", sha256="a6ca15d78244a7b50fdbf27f85c85f4035aa799ce7dd018a0d98b358ef7bc782") version("0.4220", sha256="fb1207c7e799366f7a8adda3f135bf8141c4d6068505650d4db2b2d3ce34b5a2") diff --git a/var/spack/repos/builtin/packages/perl-module-corelist/package.py b/var/spack/repos/builtin/packages/perl-module-corelist/package.py index b4b0a27cf1bf57..3ff083a14611d1 100644 --- a/var/spack/repos/builtin/packages/perl-module-corelist/package.py +++ b/var/spack/repos/builtin/packages/perl-module-corelist/package.py @@ -12,6 +12,9 @@ class PerlModuleCorelist(PerlPackage): homepage = "https://metacpan.org/pod/Module::CoreList" url = "https://cpan.metacpan.org/authors/id/B/BI/BINGOS/Module-CoreList-5.20220820.tar.gz" + version( + "5.20240420", sha256="ce3b4548774c6761d91b479cf5b80b10dc74b0c07054dcf3b6252c22639aee8d" + ) version( "5.20230320", sha256="324a28f755bd10abc26e0e8b6564ae2623276ae99cbb28ee09ced647fa80f87b" ) diff --git a/var/spack/repos/builtin/packages/perl-moose/package.py b/var/spack/repos/builtin/packages/perl-moose/package.py index 234cc6167c86bc..d3b08f943b9fb0 100644 --- a/var/spack/repos/builtin/packages/perl-moose/package.py +++ b/var/spack/repos/builtin/packages/perl-moose/package.py @@ -14,12 +14,15 @@ class PerlMoose(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("2.2207", sha256="7c2daddc49754ded93f65b8ce9e3ac9b6d11ab27d111ec77f95a8528cf4ac409") version("2.2203", sha256="fa7814acf4073fa434c148d403cbbf8a7b62f73ad396fa8869f3036d6e3241a7") version("2.2010", sha256="af0905b69f18c27de1177c9bc7778ee495d4ec91be1f223e8ca8333af4de08c5") version("2.2009", sha256="63ba8a5e27dbcbdbac2cd8f4162fff50a31e9829d8955a196a5898240c02d194") version("2.2007", sha256="bc75a320b55ba26ac9e60e11a77b3471066cb615bf7097537ed22e20df88afe8") version("2.2006", sha256="a4e00ab25cc41bebc5e7a11d71375fb5e64b56d5f91159afee225d698e06392b") + depends_on("c", type="build") # generated + depends_on("perl-cpan-meta-check", type=("build", "run")) depends_on("perl-test-cleannamespaces", type=("build", "run")) depends_on("perl-devel-overloadinfo", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-net-http/package.py b/var/spack/repos/builtin/packages/perl-net-http/package.py index 27a18f0598352b..42cdb6ca5ab8c8 100644 --- a/var/spack/repos/builtin/packages/perl-net-http/package.py +++ b/var/spack/repos/builtin/packages/perl-net-http/package.py @@ -14,6 +14,7 @@ class PerlNetHttp(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("6.23", sha256="0d65c09dd6c8589b2ae1118174d3c1a61703b6ecfc14a3442a8c74af65e0c94e") version("6.22", sha256="62faf9a5b84235443fe18f780e69cecf057dea3de271d7d8a0ba72724458a1a2") version("6.17", sha256="1e8624b1618dc6f7f605f5545643ebb9b833930f4d7485d4124aa2f2f26d1611") diff --git a/var/spack/repos/builtin/packages/perl-net-ssleay/package.py b/var/spack/repos/builtin/packages/perl-net-ssleay/package.py index cd6a8168b1f2a4..f03f030f00247f 100644 --- a/var/spack/repos/builtin/packages/perl-net-ssleay/package.py +++ b/var/spack/repos/builtin/packages/perl-net-ssleay/package.py @@ -19,6 +19,8 @@ class PerlNetSsleay(PerlPackage): version("1.85", sha256="9d8188b9fb1cae3bd791979c20554925d5e94a138d00414f1a6814549927b0c8") version("1.82", sha256="5895c519c9986a5e5af88e3b8884bbdc70e709ee829dc6abb9f53155c347c7e5") + depends_on("c", type="build") # generated + depends_on("openssl") def configure(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/perl-parse-recdescent/package.py b/var/spack/repos/builtin/packages/perl-parse-recdescent/package.py index 491b8f42f6c038..90e87a4dc29a74 100644 --- a/var/spack/repos/builtin/packages/perl-parse-recdescent/package.py +++ b/var/spack/repos/builtin/packages/perl-parse-recdescent/package.py @@ -14,4 +14,6 @@ class PerlParseRecdescent(PerlPackage): version("1.967015", sha256="1943336a4cb54f1788a733f0827c0c55db4310d5eae15e542639c9dd85656e37") + depends_on("c", type="build") # generated + depends_on("perl-module-build", type="build") diff --git a/var/spack/repos/builtin/packages/perl-path-tiny/package.py b/var/spack/repos/builtin/packages/perl-path-tiny/package.py index ec90934c53b064..19fbc6ba700ca1 100644 --- a/var/spack/repos/builtin/packages/perl-path-tiny/package.py +++ b/var/spack/repos/builtin/packages/perl-path-tiny/package.py @@ -18,5 +18,6 @@ class PerlPathTiny(PerlPackage): license("Apache-2.0") + version("0.146", sha256="861ef09bca68254e9ab24337bb6ec9d58593a792e9d68a27ee6bec2150f06741") version("0.144", sha256="f6ea094ece845c952a02c2789332579354de8d410a707f9b7045bd241206487d") version("0.108", sha256="3c49482be2b3eb7ddd7e73a5b90cff648393f5d5de334ff126ce7a3632723ff5") diff --git a/var/spack/repos/builtin/packages/perl-perl-version/package.py b/var/spack/repos/builtin/packages/perl-perl-version/package.py index f81f02b8462c03..c65fe2763bf56b 100644 --- a/var/spack/repos/builtin/packages/perl-perl-version/package.py +++ b/var/spack/repos/builtin/packages/perl-perl-version/package.py @@ -12,6 +12,7 @@ class PerlPerlVersion(PerlPackage): homepage = "https://metacpan.org/pod/Perl::Version" url = "http://search.cpan.org/CPAN/authors/id/B/BD/BDFOY/Perl-Version-1.013_03.tar.gz" + version("1.017", sha256="3d85283bc5411af0f71fd75284a0b2e1ff3a7ec13f16464046f1fd77aa8647e4") version("1.013_03", sha256="6b5978f598dcdf8a304500c1b7bcdce967ca05e7b38673cebfdb4237531c2ff9") depends_on("perl-file-slurp-tiny", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/perl-proc-processtable/package.py b/var/spack/repos/builtin/packages/perl-proc-processtable/package.py index efc7faaa40b2f5..7b133d55a4e6fc 100644 --- a/var/spack/repos/builtin/packages/perl-proc-processtable/package.py +++ b/var/spack/repos/builtin/packages/perl-proc-processtable/package.py @@ -18,4 +18,6 @@ class PerlProcProcesstable(PerlPackage): version("0.636", sha256="944224ffb00fc1ef35069633770a0afda8623b5c7532d1e4ab48a9df394890fd") + depends_on("c", type="build") # generated + depends_on("perl@5.6.0:", type=("build", "link", "run", "test")) diff --git a/var/spack/repos/builtin/packages/perl-sereal-decoder/package.py b/var/spack/repos/builtin/packages/perl-sereal-decoder/package.py index 000887a6bee4ae..74d9b3c705a767 100644 --- a/var/spack/repos/builtin/packages/perl-sereal-decoder/package.py +++ b/var/spack/repos/builtin/packages/perl-sereal-decoder/package.py @@ -18,6 +18,8 @@ class PerlSerealDecoder(PerlPackage): version("5.004", sha256="68ef0314d87d1a6e60bb0f66fcf43eb2cacdeb1754432f5e25e784e39d3e6784") + depends_on("c", type="build") # generated + depends_on("perl@5.8.0:", type=("build", "link", "run", "test")) depends_on("perl-devel-checklib@1.16:", type=("build")) depends_on("perl-test-deep", type=("build", "link", "test")) diff --git a/var/spack/repos/builtin/packages/perl-sereal-encoder/package.py b/var/spack/repos/builtin/packages/perl-sereal-encoder/package.py index 6c27d95527f033..891d6171872411 100644 --- a/var/spack/repos/builtin/packages/perl-sereal-encoder/package.py +++ b/var/spack/repos/builtin/packages/perl-sereal-encoder/package.py @@ -18,6 +18,8 @@ class PerlSerealEncoder(PerlPackage): version("5.004", sha256="5e5a86ccd32dae34ed80932ecbe5c68e29752b5de0e9b0a793ab7eb2ca55cb1b") + depends_on("c", type="build") # generated + depends_on("perl@5.8.0:", type=("build", "link", "run", "test")) depends_on("perl-devel-checklib@1.16:", type=("build")) depends_on("perl-sereal-decoder@5.004:", type=("build", "link", "run", "test")) diff --git a/var/spack/repos/builtin/packages/perl-set-intervaltree/package.py b/var/spack/repos/builtin/packages/perl-set-intervaltree/package.py index aa788637b0a93e..fa45c04a00cf4b 100644 --- a/var/spack/repos/builtin/packages/perl-set-intervaltree/package.py +++ b/var/spack/repos/builtin/packages/perl-set-intervaltree/package.py @@ -15,4 +15,6 @@ class PerlSetIntervaltree(PerlPackage): version("0.10", sha256="e3bd9ccf0d074b5f879eef1ed88254983697bf83d02744fce62150ee46553ebc") + depends_on("cxx", type="build") # generated + depends_on("perl-extutils-makemaker", type="build") diff --git a/var/spack/repos/builtin/packages/perl-string-approx/package.py b/var/spack/repos/builtin/packages/perl-string-approx/package.py index aa25c0bf84dd4e..9d41cbc7880fcf 100644 --- a/var/spack/repos/builtin/packages/perl-string-approx/package.py +++ b/var/spack/repos/builtin/packages/perl-string-approx/package.py @@ -15,3 +15,5 @@ class PerlStringApprox(PerlPackage): maintainers("EbiArnie") version("3.28", sha256="43201e762d8699cb0ac2c0764a5454bdc2306c0771014d6c8fba821480631342") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/perl-string-crc32/package.py b/var/spack/repos/builtin/packages/perl-string-crc32/package.py index dbe2eced521b28..7b7a544329c7de 100644 --- a/var/spack/repos/builtin/packages/perl-string-crc32/package.py +++ b/var/spack/repos/builtin/packages/perl-string-crc32/package.py @@ -17,3 +17,5 @@ class PerlStringCrc32(PerlPackage): license("CC0-1.0 OR SSLeay") version("2.100", sha256="9706093b2d068b6715d35b4c58f51558e37960083202129fbb00a57e19a74713") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/perl-sub-exporter/package.py b/var/spack/repos/builtin/packages/perl-sub-exporter/package.py index b559099b9980aa..e22b2790cf6e6d 100644 --- a/var/spack/repos/builtin/packages/perl-sub-exporter/package.py +++ b/var/spack/repos/builtin/packages/perl-sub-exporter/package.py @@ -14,6 +14,7 @@ class PerlSubExporter(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("0.991", sha256="2a95695d35c5d0d5373a7e145c96b9b016113b74e94116835ac05450cae4d445") version("0.989", sha256="334896e0af5e0643fc3799cbbcf01f933d4ca6324cd644c0b6660e71cdbd01c9") version("0.987", sha256="543cb2e803ab913d44272c7da6a70bb62c19e467f3b12aaac4c9523259b083d6") diff --git a/var/spack/repos/builtin/packages/perl-sub-name/package.py b/var/spack/repos/builtin/packages/perl-sub-name/package.py index db7125162b0750..95cd7be1abcd4f 100644 --- a/var/spack/repos/builtin/packages/perl-sub-name/package.py +++ b/var/spack/repos/builtin/packages/perl-sub-name/package.py @@ -14,5 +14,6 @@ class PerlSubName(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("0.27", sha256="ecf36fba1c47ca93e1daa394968ed39c4186867459d9cd173c421e2b972043e8") version("0.26", sha256="2d2f2d697d516c89547e7c4307f1e79441641cae2c7395e7319b306d390df105") version("0.21", sha256="bd32e9dee07047c10ae474c9f17d458b6e9885a6db69474c7a494ccc34c27117") diff --git a/var/spack/repos/builtin/packages/perl-term-readline-gnu/package.py b/var/spack/repos/builtin/packages/perl-term-readline-gnu/package.py index 80ec3394a8c96e..a14da8ac593583 100644 --- a/var/spack/repos/builtin/packages/perl-term-readline-gnu/package.py +++ b/var/spack/repos/builtin/packages/perl-term-readline-gnu/package.py @@ -13,6 +13,7 @@ class PerlTermReadlineGnu(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("1.46", sha256="b13832132e50366c34feac12ce82837c0a9db34ca530ae5d27db97cf9c964c7b") version("1.36", sha256="9a08f7a4013c9b865541c10dbba1210779eb9128b961250b746d26702bab6925") depends_on("readline") diff --git a/var/spack/repos/builtin/packages/perl-test-differences/package.py b/var/spack/repos/builtin/packages/perl-test-differences/package.py index 177aece8373c5e..6c3d2d5b936ff9 100644 --- a/var/spack/repos/builtin/packages/perl-test-differences/package.py +++ b/var/spack/repos/builtin/packages/perl-test-differences/package.py @@ -14,6 +14,7 @@ class PerlTestDifferences(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("0.71", sha256="cac16a56cd843b0809e5b49199d60d75a8dbad7ca9a08380dbf3f5cc3aaa38d9") version("0.69", sha256="18f644fdd4a1fef93ef3f7f67df8e95b593d811899f34bcbbaba4d717222f58f") version("0.64", sha256="9f459dd9c2302a0a73e2f5528a0ce7d09d6766f073187ae2c69e603adf2eb276") diff --git a/var/spack/repos/builtin/packages/perl-test-warnings/package.py b/var/spack/repos/builtin/packages/perl-test-warnings/package.py index 27a4f34048f96b..62e16d23f1314b 100644 --- a/var/spack/repos/builtin/packages/perl-test-warnings/package.py +++ b/var/spack/repos/builtin/packages/perl-test-warnings/package.py @@ -14,5 +14,6 @@ class PerlTestWarnings(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("0.033", sha256="b9c375719f2c61c5f97aa5ee6cf4c901a972347c415969379b0b51f67c48bbcb") version("0.031", sha256="1e542909fef305e45563e9878ea1c3b0c7cef1b28bb7ae07eba2e1efabec477b") version("0.026", sha256="ae2b68b1b5616704598ce07f5118efe42dc4605834453b7b2be14e26f9cc9a08") diff --git a/var/spack/repos/builtin/packages/perl-text-csv/package.py b/var/spack/repos/builtin/packages/perl-text-csv/package.py index 8cc0254d8c10f0..9f8f3e3f369c2b 100644 --- a/var/spack/repos/builtin/packages/perl-text-csv/package.py +++ b/var/spack/repos/builtin/packages/perl-text-csv/package.py @@ -14,5 +14,6 @@ class PerlTextCsv(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("2.04", sha256="4f80122e4ea0b05079cad493e386564030f18c8d7b1f9af561df86985a653fe3") version("2.02", sha256="84120de3e10489ea8fbbb96411a340c32cafbe5cdff7dd9576b207081baa9d24") version("1.95", sha256="7e0a11d9c1129a55b68a26aa4b37c894279df255aa63ec8341d514ab848dbf61") diff --git a/var/spack/repos/builtin/packages/perl-tk/package.py b/var/spack/repos/builtin/packages/perl-tk/package.py index f8410200cd521b..146b7260b13f1e 100644 --- a/var/spack/repos/builtin/packages/perl-tk/package.py +++ b/var/spack/repos/builtin/packages/perl-tk/package.py @@ -18,6 +18,9 @@ class PerlTk(PerlPackage): version("804.035", sha256="4d2b80291ba6de34d8ec886a085a6dbd2b790b926035a087e99025614c5ffdd4") version("804.033", sha256="84756e9b07a2555c8eecf88e63d5cbbba9b1aa97b1e71a3d4aa524a7995a88ad") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl-extutils-makemaker", type="build") depends_on("libx11") depends_on("libxcb") diff --git a/var/spack/repos/builtin/packages/perl-xml-hash-xs/package.py b/var/spack/repos/builtin/packages/perl-xml-hash-xs/package.py index dce4b09c55b6ce..06f1dd0ed58def 100644 --- a/var/spack/repos/builtin/packages/perl-xml-hash-xs/package.py +++ b/var/spack/repos/builtin/packages/perl-xml-hash-xs/package.py @@ -17,3 +17,5 @@ class PerlXmlHashXs(PerlPackage): license("Artistic-1.0-Perl OR GPL-1.0-or-later") version("0.56", sha256="be4c60ded94c5ebe53a81ef74928dfbec9613986d2a6056dd253665c6ae9802f") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/perl-xml-libxml/package.py b/var/spack/repos/builtin/packages/perl-xml-libxml/package.py index be125ef471fbf9..c789f96409e245 100644 --- a/var/spack/repos/builtin/packages/perl-xml-libxml/package.py +++ b/var/spack/repos/builtin/packages/perl-xml-libxml/package.py @@ -19,10 +19,16 @@ class PerlXmlLibxml(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("2.0210", sha256="a29bf3f00ab9c9ee04218154e0afc8f799bf23674eb99c1a9ed4de1f4059a48d") + version("2.0209", sha256="b4a5abbcd689aa2fbbc8b7b45339e961c4984e48108494eb6c282b4748222425") version("2.0201", sha256="e008700732502b3f1f0890696ec6e2dc70abf526cd710efd9ab7675cae199bc2") + depends_on("c", type="build") # generated + depends_on("libxml2") depends_on("perl-xml-namespacesupport", type=("build", "run")) depends_on("perl-xml-sax", type=("build", "run")) depends_on("perl-xml-sax-base", type=("build", "run")) depends_on("perl-alien-libxml2", type="build") + + conflicts("%gcc@14:", when="@:2.0209") diff --git a/var/spack/repos/builtin/packages/perl-xml-libxslt/package.py b/var/spack/repos/builtin/packages/perl-xml-libxslt/package.py index d096df2d5af09f..c16a3c83f89c19 100644 --- a/var/spack/repos/builtin/packages/perl-xml-libxslt/package.py +++ b/var/spack/repos/builtin/packages/perl-xml-libxslt/package.py @@ -13,7 +13,10 @@ class PerlXmlLibxslt(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("2.002001", sha256="df8927c4ff1949f62580d1c1e6f00f0cd56b53d3a957ee4b171b59bffa63b2c0") version("1.96", sha256="2a5e374edaa2e9f9d26b432265bfea9b4bb7a94c9fbfef9047b298fce844d473") + depends_on("c", type="build") # generated + depends_on("libxslt") depends_on("perl-xml-libxml") diff --git a/var/spack/repos/builtin/packages/perl-xml-parser/package.py b/var/spack/repos/builtin/packages/perl-xml-parser/package.py index 86e2027e0fc25e..f199fd8073bb4e 100644 --- a/var/spack/repos/builtin/packages/perl-xml-parser/package.py +++ b/var/spack/repos/builtin/packages/perl-xml-parser/package.py @@ -14,6 +14,7 @@ class PerlXmlParser(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("2.47", sha256="ad4aae643ec784f489b956abe952432871a622d4e2b5c619e8855accbfc4d1d8") version("2.46", sha256="d331332491c51cccfb4cb94ffc44f9cd73378e618498d4a37df9e043661c515d") version("2.44", sha256="1ae9d07ee9c35326b3d9aad56eae71a6730a73a116b9fe9e8a4758b7cc033216") @@ -24,8 +25,8 @@ def configure_args(self): args = [] p = self.spec["expat"].prefix.lib - args.append("EXPATLIBPATH={0}".format(p)) + args.append(f"EXPATLIBPATH={p}") p = self.spec["expat"].prefix.include - args.append("EXPATINCPATH={0}".format(p)) + args.append(f"EXPATINCPATH={p}") return args diff --git a/var/spack/repos/builtin/packages/perl-yaml-libyaml/package.py b/var/spack/repos/builtin/packages/perl-yaml-libyaml/package.py index 9b2276c4cc3d5c..0e37d54ab13d53 100644 --- a/var/spack/repos/builtin/packages/perl-yaml-libyaml/package.py +++ b/var/spack/repos/builtin/packages/perl-yaml-libyaml/package.py @@ -14,5 +14,8 @@ class PerlYamlLibyaml(PerlPackage): license("GPL-1.0-or-later OR Artistic-1.0-Perl") + version("0.89", sha256="155ab83675345c50add03311acf9dd915955707f909a2abd8b17d7792859b2ec") version("0.84", sha256="225bcb39be2d5e3d02df7888d5f99fd8712f048ba539b09232ca1481e70bfd05") version("0.67", sha256="e65a22abc912a46a10abddf3b88d806757f44f164ab3167c8f0ff6aa30648187") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/perl-yaml-syck/package.py b/var/spack/repos/builtin/packages/perl-yaml-syck/package.py index 0b1e74eecd48b8..a58c078a9b44b0 100644 --- a/var/spack/repos/builtin/packages/perl-yaml-syck/package.py +++ b/var/spack/repos/builtin/packages/perl-yaml-syck/package.py @@ -18,4 +18,6 @@ class PerlYamlSyck(PerlPackage): version("1.34", sha256="cc9156ccaebda798ebfe2f31b619e806577f860ed1704262f17ffad3c6e34159") + depends_on("c", type="build") # generated + depends_on("perl@5.6.0:", type=("build", "link", "run", "test")) diff --git a/var/spack/repos/builtin/packages/perl/package.py b/var/spack/repos/builtin/packages/perl/package.py index ad44d760f3e2b3..cb5f76f98cfd18 100644 --- a/var/spack/repos/builtin/packages/perl/package.py +++ b/var/spack/repos/builtin/packages/perl/package.py @@ -3,14 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -# -# Author: Milton Woods -# Date: March 22, 2017 -# Author: George Hartzell -# Date: July 21, 2016 -# Author: Justin Too -# Date: September 6, 2015 -# import os import re import sys @@ -35,19 +27,29 @@ class Perl(Package): # Perl doesn't use Autotools, it should subclass Package maintainers("LydDeb") + license("Artistic-1.0-Perl OR GPL-1.0-or-later") + executables = [r"^perl(-?\d+.*)?$"] # see https://www.cpan.org/src/README.html for # explanation of version numbering scheme - license("Artistic-1.0-Perl OR GPL-1.0-or-later") - # Maintenance releases (even numbers, preferred) + version( + "5.38.2", + sha256="a0a31534451eb7b83c7d6594a497543a54d488bc90ca00f5e34762577f40655e", + preferred=True, + ) version( "5.38.0", sha256="213ef58089d2f2c972ea353517dc60ec3656f050dcc027666e118b508423e517", preferred=True, ) + version( + "5.36.3", + sha256="f2a1ad88116391a176262dd42dfc52ef22afb40f4c0e9810f15d561e6f1c726a", + preferred=True, + ) version( "5.36.1", sha256="68203665d8ece02988fc77dc92fccbb297a83a4bb4b8d07558442f978da54cc1", @@ -58,66 +60,133 @@ class Perl(Package): # Perl doesn't use Autotools, it should subclass Package sha256="e26085af8ac396f62add8a533c3a0ea8c8497d836f0689347ac5abd7b7a4e00a", preferred=True, ) + + # End of life releases (deprecated) version( "5.34.1", sha256="357951a491b0ba1ce3611263922feec78ccd581dddc24a446b033e25acf242a1", - preferred=True, + deprecated=True, ) version( "5.34.0", sha256="551efc818b968b05216024fb0b727ef2ad4c100f8cb6b43fab615fa78ae5be9a", - preferred=True, + deprecated=True, ) version( "5.32.1", sha256="03b693901cd8ae807231b1787798cf1f2e0b8a56218d07b7da44f784a7caeb2c", - preferred=True, + deprecated=True, ) version( "5.32.0", sha256="efeb1ce1f10824190ad1cadbcccf6fdb8a5d37007d0100d2d9ae5f2b5900c0b4", - preferred=True, + deprecated=True, ) version( "5.30.3", sha256="32e04c8bb7b1aecb2742a7f7ac0eabac100f38247352a73ad7fa104e39e7406f", - preferred=True, + deprecated=True, ) version( "5.30.2", sha256="66db7df8a91979eb576fac91743644da878244cf8ee152f02cd6f5cd7a731689", - preferred=True, + deprecated=True, ) version( "5.30.1", sha256="bf3d25571ff1ee94186177c2cdef87867fd6a14aa5a84f0b1fb7bf798f42f964", - preferred=True, + deprecated=True, ) version( "5.30.0", sha256="851213c754d98ccff042caa40ba7a796b2cee88c5325f121be5cbb61bbf975f2", - preferred=True, + deprecated=True, + ) + version( + "5.28.0", + sha256="7e929f64d4cb0e9d1159d4a59fc89394e27fa1f7004d0836ca0d514685406ea8", + deprecated=True, + ) + version( + "5.26.2", + sha256="572f9cea625d6062f8a63b5cee9d3ee840800a001d2bb201a41b9a177ab7f70d", + deprecated=True, + ) + version( + "5.24.1", + sha256="e6c185c9b09bdb3f1b13f678999050c639859a7ef39c8cad418448075f5918af", + deprecated=True, + ) + version( + "5.22.4", + sha256="ba9ef57c2b709f2dad9c5f6acf3111d9dfac309c484801e0152edbca89ed61fa", + deprecated=True, + ) + version( + "5.22.3", + sha256="1b351fb4df7e62ec3c8b2a9f516103595b2601291f659fef1bbe3917e8410083", + deprecated=True, + ) + version( + "5.22.2", + sha256="81ad196385aa168cb8bd785031850e808c583ed18a7901d33e02d4f70ada83c2", + deprecated=True, + ) + version( + "5.22.1", + sha256="2b475d0849d54c4250e9cba4241b7b7291cffb45dfd083b677ca7b5d38118f27", + deprecated=True, + ) + version( + "5.22.0", + sha256="0c690807f5426bbd1db038e833a917ff00b988bf03cbf2447fa9ffdb34a2ab3c", + deprecated=True, + ) + version( + "5.20.3", + sha256="3524e3a76b71650ab2f794fd68e45c366ec375786d2ad2dca767da424bbb9b4a", + deprecated=True, + ) + version( + "5.18.4", + sha256="01a4e11a9a34616396c4a77b3cef51f76a297e1a2c2c490ae6138bf0351eb29f", + deprecated=True, + ) + version( + "5.16.3", + sha256="69cf08dca0565cec2c5c6c2f24b87f986220462556376275e5431cc2204dedb6", + deprecated=True, ) # Development releases (odd numbers) - version("5.37.9", sha256="9884fa8a4958bf9434b50f01cbfd187f9e2738f38fe1ae37f844e9950c5117c1") - version("5.35.0", sha256="d6c0eb4763d1c73c1d18730664d43fcaf6100c31573c3b81e1504ec8f5b22708") - version("5.33.3", sha256="4f4ba0aceb932e6cf7c05674d05e51ef759d1c97f0685dee65a8f3d190f737cd") - version("5.31.7", sha256="d05c4e72128f95ef6ffad42728ecbbd0d9437290bf0f88268b51af011f26b57d") - version("5.31.4", sha256="418a7e6fe6485cc713a86d1227ef112f0bb3f80322e3b715ffe42851d97804a5") - - # End of life releases - version("5.28.0", sha256="7e929f64d4cb0e9d1159d4a59fc89394e27fa1f7004d0836ca0d514685406ea8") - version("5.26.2", sha256="572f9cea625d6062f8a63b5cee9d3ee840800a001d2bb201a41b9a177ab7f70d") - version("5.24.1", sha256="e6c185c9b09bdb3f1b13f678999050c639859a7ef39c8cad418448075f5918af") - version("5.22.4", sha256="ba9ef57c2b709f2dad9c5f6acf3111d9dfac309c484801e0152edbca89ed61fa") - version("5.22.3", sha256="1b351fb4df7e62ec3c8b2a9f516103595b2601291f659fef1bbe3917e8410083") - version("5.22.2", sha256="81ad196385aa168cb8bd785031850e808c583ed18a7901d33e02d4f70ada83c2") - version("5.22.1", sha256="2b475d0849d54c4250e9cba4241b7b7291cffb45dfd083b677ca7b5d38118f27") - version("5.22.0", sha256="0c690807f5426bbd1db038e833a917ff00b988bf03cbf2447fa9ffdb34a2ab3c") - version("5.20.3", sha256="3524e3a76b71650ab2f794fd68e45c366ec375786d2ad2dca767da424bbb9b4a") - version("5.18.4", sha256="01a4e11a9a34616396c4a77b3cef51f76a297e1a2c2c490ae6138bf0351eb29f") - version("5.16.3", sha256="69cf08dca0565cec2c5c6c2f24b87f986220462556376275e5431cc2204dedb6") + version("5.39.10", sha256="4b7ffb3e068583fa5c8413390c998b2c15214f205ce737acc485b40932b9f419") + version( + "5.37.9", + sha256="9884fa8a4958bf9434b50f01cbfd187f9e2738f38fe1ae37f844e9950c5117c1", + deprecated=True, + ) + version( + "5.35.0", + sha256="d6c0eb4763d1c73c1d18730664d43fcaf6100c31573c3b81e1504ec8f5b22708", + deprecated=True, + ) + version( + "5.33.3", + sha256="4f4ba0aceb932e6cf7c05674d05e51ef759d1c97f0685dee65a8f3d190f737cd", + deprecated=True, + ) + version( + "5.31.7", + sha256="d05c4e72128f95ef6ffad42728ecbbd0d9437290bf0f88268b51af011f26b57d", + deprecated=True, + ) + version( + "5.31.4", + sha256="418a7e6fe6485cc713a86d1227ef112f0bb3f80322e3b715ffe42851d97804a5", + deprecated=True, + ) + + depends_on("c", type="build") # generated extendable = True @@ -455,10 +524,6 @@ def setup_dependent_package(self, module, dependent_spec): # Add variables for library directory module.perl_lib_dir = dependent_spec.prefix.lib.perl5 - # Make the site packages directory for extensions, - # if it does not exist already. - mkdirp(module.perl_lib_dir) - def setup_build_environment(self, env): if sys.platform == "win32": env.append_path("PATH", self.prefix.bin) diff --git a/var/spack/repos/builtin/packages/pestpp/package.py b/var/spack/repos/builtin/packages/pestpp/package.py index 9f9f4786c7b86c..f4b0c5a75adbd1 100644 --- a/var/spack/repos/builtin/packages/pestpp/package.py +++ b/var/spack/repos/builtin/packages/pestpp/package.py @@ -16,9 +16,14 @@ class Pestpp(CMakePackage): homepage = "https://pesthomepage.org" url = "https://github.com/usgs/pestpp/archive/5.0.5.tar.gz" + version("5.2.9", sha256="401db5eec509c6771cd509a43c1710ac76b1ebe533f4cbaa1df26375aa167e60") version("5.2.3", sha256="6b86a7db863a034e730480046a4b7b4a8dc7cc798658a5404a961be379c05dc3") version("5.0.5", sha256="b9695724758f69c1199371608b01419973bd1475b1788039a2fab6313f6ed67c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") depends_on("cmake@3.9:", type="build") diff --git a/var/spack/repos/builtin/packages/petaca/package.py b/var/spack/repos/builtin/packages/petaca/package.py index 4c78092b1a8a1e..1dd72a24dd9edb 100644 --- a/var/spack/repos/builtin/packages/petaca/package.py +++ b/var/spack/repos/builtin/packages/petaca/package.py @@ -28,9 +28,16 @@ class Petaca(CMakePackage): license("MIT") version("develop", branch="master") + version("24.04", sha256="951a0ba3380502fa09009af8613471256bbcb4edc14fe810f7e3afe7adc21b7e") + version("23.12", sha256="8d7f1c7170500db52a624c891fb1563b8cfc322d138d935a5b4c6f12d9bdbd23") + version("23.11.1", sha256="5c0809965046be5391b476edf1bc0c80584c3bc4fc5ecbf915a2344c6c5b9914") + version("23.11", sha256="2230ea8e90ee00bd571c557be4f208077e1606310bef2e43a0257102cc875c45") version("22.03", sha256="e6559e928c7cca6017ef0582c204eee775f6bb3f927f1c224c515c2ad574cc32") version("21.03", commit="f17df95193ca1a3879687a59a91a123be25e3efa") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.3:", type="build") depends_on("yajl@2.0.1:") diff --git a/var/spack/repos/builtin/packages/petsc/package.py b/var/spack/repos/builtin/packages/petsc/package.py index eae1aa9ff96be1..47641a0d807761 100644 --- a/var/spack/repos/builtin/packages/petsc/package.py +++ b/var/spack/repos/builtin/packages/petsc/package.py @@ -21,6 +21,12 @@ class Petsc(Package, CudaPackage, ROCmPackage): tags = ["e4s"] version("main", branch="main") + version("3.21.3", sha256="6d9ceb99d84d275250c614192dad45955d4a7610e12d8292a07dc49403556d26") + version("3.21.2", sha256="a1ac62b6204bdf2f7f9b637abf45e6cff24d372d4d3d3702c50e157bdb56eb21") + version("3.21.1", sha256="7ff8b692bceb7d7a8f51e2f45ccb20af00ba9395d7e1eee8816d46eb1c4c4b27") + version("3.21.0", sha256="1e0c2f92514c72f80d4a4d0e6439a3aba0ceda7a0bcbc7ad9c44ce4cd8b14c28") + version("3.20.6", sha256="20e6c260765f9593924bc5b1783bd152ec5c47246b47ce516cded7b505b34795") + version("3.20.5", sha256="fb4e637758737af910b05f30a785245633916cd0a929b7b6447ad1028da4ea5a") version("3.20.4", sha256="b0d03a5595ee0a5696dd6683321e1dbfe9fea85238d3016a847b3d0bcdcfb3d9") version("3.20.3", sha256="75a94fb44df0512f51ad093fa784e56b61f51b7ead5956fbe49185c203f8c245") version("3.20.2", sha256="2a2d08b5f0e3d0198dae2c42ce1fd036f25c153ef2bb4a2d320ca141ac7cd30b") @@ -85,6 +91,10 @@ class Petsc(Package, CudaPackage, ROCmPackage): version("3.11.1", sha256="cb627f99f7ce1540ebbbf338189f89a5f1ecf3ab3b5b0e357f9e46c209f1fb23") version("3.11.0", sha256="b3bed2a9263193c84138052a1b92d47299c3490dd24d1d0bf79fb884e71e678a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") variant("mpi", default=True, description="Activates MPI support") variant("double", default=True, description="Switches between single and double precision") @@ -226,7 +236,7 @@ def check_fortran_compiler(self): # Virtual dependencies # Git repository needs sowing to build Fortran interface - depends_on("sowing", when="@main") + depends_on("sowing@master", when="@main") # PETSc, hypre, superlu_dist when built with int64 use 32 bit integers # with BLAS/LAPACK @@ -234,6 +244,10 @@ def check_fortran_compiler(self): depends_on("lapack") depends_on("mpi", when="+mpi") depends_on("cuda", when="+cuda") + # Fixed in https://gitlab.com/petsc/petsc/-/merge_requests/7354 + conflicts( + "^cuda@12.4:", when="@:3.20.5 +cuda", msg="Deprecation in CCCL 2.3 causes build failure." + ) depends_on("hip", when="+rocm") with when("+rocm"): @@ -604,6 +618,10 @@ def configure_options(self): if "superlu-dist" in spec: if spec.satisfies("@3.10.3:3.15"): options.append("--with-cxx-dialect=C++11") + if spec["superlu-dist"].satisfies("+rocm"): + # Suppress HIP header warning message, otherwise the PETSc + # configuration fails: + options.append("CXXPPFLAGS=-DROCM_NO_WRAPPER_HEADER_WARNING") if "+mkl-pardiso" in spec: options.append("--with-mkl_pardiso-dir=%s" % spec["mkl"].prefix) diff --git a/var/spack/repos/builtin/packages/pexsi/package.py b/var/spack/repos/builtin/packages/pexsi/package.py index 9b7191ef00195d..b8ef54bc26fb44 100644 --- a/var/spack/repos/builtin/packages/pexsi/package.py +++ b/var/spack/repos/builtin/packages/pexsi/package.py @@ -38,6 +38,10 @@ class Pexsi(MakefilePackage, CMakePackage): version("0.10.2", sha256="8714c71b76542e096211b537a9cb1ffb2c28f53eea4f5a92f94cc1ca1e7b499f") version("0.9.0", sha256="e5efe0c129013392cdac3234e37f1f4fea641c139b1fbea47618b4b839d05029") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + patch("fujitsu-add-link-flags.patch", when="%fj") depends_on("parmetis") diff --git a/var/spack/repos/builtin/packages/pfapack/package.py b/var/spack/repos/builtin/packages/pfapack/package.py index a86549949c2f0f..bcc5a875942d89 100644 --- a/var/spack/repos/builtin/packages/pfapack/package.py +++ b/var/spack/repos/builtin/packages/pfapack/package.py @@ -19,6 +19,10 @@ class Pfapack(MakefilePackage): "2014-09-17", sha256="b68fc35dda23ee24c358641b1a92ef701c4ffa0b3f0b0808b24e68afeb58ef07" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + parallel = False depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/pfft/package.py b/var/spack/repos/builtin/packages/pfft/package.py index 4a9796067f8b94..f2545593b51e49 100644 --- a/var/spack/repos/builtin/packages/pfft/package.py +++ b/var/spack/repos/builtin/packages/pfft/package.py @@ -23,6 +23,9 @@ class Pfft(AutotoolsPackage): "1.0.8-alpha", sha256="6c43960ad72fcff7e49b87c604c5f471fb5890f1bd11ce750ab52f035e7c5317" ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("fftw+mpi+pfft_patches") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/pflask/package.py b/var/spack/repos/builtin/packages/pflask/package.py index f7831f61403bd5..392edadf6719de 100644 --- a/var/spack/repos/builtin/packages/pflask/package.py +++ b/var/spack/repos/builtin/packages/pflask/package.py @@ -16,3 +16,5 @@ class Pflask(CMakePackage): version("0.2", sha256="dabbd060d1c50174de5fffae9ec97dc1d41b22de898a8280166cba768c940ebd") version("0.1", sha256="3c41c670fd8c48b7b6a41d697b444df8bf95380937ba4f734b41af135d5c5816") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/pflogger/package.py b/var/spack/repos/builtin/packages/pflogger/package.py index 5aedadfe6439f1..1bd366066057b3 100644 --- a/var/spack/repos/builtin/packages/pflogger/package.py +++ b/var/spack/repos/builtin/packages/pflogger/package.py @@ -22,6 +22,9 @@ class Pflogger(CMakePackage): version("develop", branch="develop") version("main", branch="main") + version("1.15.0", sha256="454f05731a3ba50c7ae3ef9463b642c53248ae84ccb3b93455ef2ae2b6858235") + version("1.14.0", sha256="63422493136f66f61d5148b7b1d278b1e5ca76bd37c578e45e4ae0e967351823") + version("1.13.2", sha256="934e573134f7f1a22b14eb582ea38dd68eb9dccb10526bfabe51229efe106352") version("1.13.1", sha256="d2246d1bf3e5186045ae84c52656168856f693f743700f473cf3d1c99eecae02") version("1.13.0", sha256="d46b61162496e227d2982bcdfe9b2c8af6a5734d0fbad9305b1a1547abeac06e") version("1.12.0", sha256="ff29b0ce4baf50675edb69c3c7493be5410839b5f81e3ce5405f04925503fb0d") @@ -35,6 +38,8 @@ class Pflogger(CMakePackage): version("1.8.0", sha256="28ce9ac8af374253b6dfd8f53f8fd271c787d432645ec9bc6a5a01601dc56e19") version("1.6.1", sha256="114a15daa7994ab7d4eea463c3a9b8fe7df3da7d07a0004b5c40cf155e374916") + depends_on("fortran", type="build") # generated + variant( "build_type", default="Release", diff --git a/var/spack/repos/builtin/packages/pflotran/package.py b/var/spack/repos/builtin/packages/pflotran/package.py index 71ff9d1b94c615..fea93a95ece1b3 100644 --- a/var/spack/repos/builtin/packages/pflotran/package.py +++ b/var/spack/repos/builtin/packages/pflotran/package.py @@ -28,6 +28,10 @@ class Pflotran(AutotoolsPackage): version("xsdk-0.4.0", commit="c851cbc94fc56a32cfdb0678f3c24b9936a5584e") version("xsdk-0.3.0", branch="release/xsdk-0.3.0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("rxn", default=False, description="Use inbuilt reaction code, useful with cray ftn") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/pfunit/package.py b/var/spack/repos/builtin/packages/pfunit/package.py index 008a5b26d04111..679788bffcfe56 100644 --- a/var/spack/repos/builtin/packages/pfunit/package.py +++ b/var/spack/repos/builtin/packages/pfunit/package.py @@ -77,6 +77,9 @@ class Pfunit(CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=False, description="Enable MPI") variant( "use_comm_world", diff --git a/var/spack/repos/builtin/packages/pgi/detection_test.yaml b/var/spack/repos/builtin/packages/pgi/detection_test.yaml new file mode 100644 index 00000000000000..1a4745fc4c2d42 --- /dev/null +++ b/var/spack/repos/builtin/packages/pgi/detection_test.yaml @@ -0,0 +1,11 @@ +paths: +- layout: + - executables: + - bin/pgcc + script: | + echo "pgcc 15.10-0 64-bit target on x86-64 Linux -tp sandybridge" + echo "The Portland Group - PGI Compilers and Tools" + echo "Copyright (c) 2015, NVIDIA CORPORATION. All rights reserved." + platforms: [linux] + results: + - spec: pgi@15.10 diff --git a/var/spack/repos/builtin/packages/pgi/package.py b/var/spack/repos/builtin/packages/pgi/package.py index 995e27ee398712..37196669cf4c9d 100644 --- a/var/spack/repos/builtin/packages/pgi/package.py +++ b/var/spack/repos/builtin/packages/pgi/package.py @@ -9,7 +9,7 @@ from spack.util.prefix import Prefix -class Pgi(Package): +class Pgi(Package, CompilerPackage): """PGI optimizing multi-core x64 compilers for Linux, MacOS & Windows with support for debugging and profiling of local MPI processes. @@ -58,6 +58,13 @@ def url_for_version(self, version): os.getcwd(), version.up_to(1), version.joined ) + compiler_languages = ["c", "cxx", "fortran"] + c_names = ["pgcc"] + cxx_names = ["pgc++", "pgCC"] + fortran_names = ["pgfortran"] # older names long deprecated + compiler_version_argument = "-V" + compiler_version_regex = r"pg[^ ]* ([0-9.]+)-[0-9]+ (?:LLVM )?[^ ]+ target on " + def install(self, spec, prefix): # Enable the silent installation feature os.environ["PGI_SILENT"] = "true" diff --git a/var/spack/repos/builtin/packages/pgplot/package.py b/var/spack/repos/builtin/packages/pgplot/package.py index 4821370345a7c8..f3204fc95fa00d 100644 --- a/var/spack/repos/builtin/packages/pgplot/package.py +++ b/var/spack/repos/builtin/packages/pgplot/package.py @@ -28,6 +28,9 @@ class Pgplot(MakefilePackage): sha256="a5799ff719a510d84d26df4ae7409ae61fe66477e3f1e8820422a9a4727a5be4", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # Replace hard-coded compilers and options by tokens, so that Spack can # edit the file more easily patch("g77_gcc.conf.patch") diff --git a/var/spack/repos/builtin/packages/phast/package.py b/var/spack/repos/builtin/packages/phast/package.py index 5626a79f6924fb..4e35bc6d1c923d 100644 --- a/var/spack/repos/builtin/packages/phast/package.py +++ b/var/spack/repos/builtin/packages/phast/package.py @@ -18,6 +18,8 @@ class Phast(MakefilePackage): version("1.6", sha256="8100f6582008c5de46d2de05cee038f0f1ca3a50147031da1bc5e8744883cbe4") version("1.4", sha256="287c77599c51256a3adbd62ed217cb6d6a547fcec2c29262e9d61fa32ed92b99") + depends_on("c", type="build") # generated + # phast cannot build with clapack using external blas depends_on("clapack~external-blas") diff --git a/var/spack/repos/builtin/packages/phasta/package.py b/var/spack/repos/builtin/packages/phasta/package.py index 6cf303420c2260..8ffb91f89bb93f 100644 --- a/var/spack/repos/builtin/packages/phasta/package.py +++ b/var/spack/repos/builtin/packages/phasta/package.py @@ -18,6 +18,10 @@ class Phasta(CMakePackage): version("develop", branch="master") version("0.0.1", commit="11f431f2d1a53a529dab4b0f079ab8aab7ca1109") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/phist/package.py b/var/spack/repos/builtin/packages/phist/package.py index d96c72a858eba6..34d704e3ce2cde 100644 --- a/var/spack/repos/builtin/packages/phist/package.py +++ b/var/spack/repos/builtin/packages/phist/package.py @@ -71,6 +71,10 @@ class Phist(CMakePackage): version("1.6.0", sha256="667a967b37d248242c275226c96efc447ef73a2b15f241c6a588d570d7fac07b") version("1.4.3", sha256="9cc1c7ba7f7a04e94f4497da14199e4631a0d02d0e4187f3e16f4c242dc777c1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( name="kernel_lib", default="builtin", diff --git a/var/spack/repos/builtin/packages/photos-f/package.py b/var/spack/repos/builtin/packages/photos-f/package.py index ce86f30fe22f65..3abeb512459893 100644 --- a/var/spack/repos/builtin/packages/photos-f/package.py +++ b/var/spack/repos/builtin/packages/photos-f/package.py @@ -20,6 +20,8 @@ class PhotosF(MakefilePackage): version("215.5", sha256="3e2b3f60ffe2d3a6a95cf2f156aa24b93e1fa3c439a85fa0ae780ca2f6e0dbb5") + depends_on("fortran", type="build") # generated + patch("photos-215.5-update-configure.patch", level=2) def do_stage(self, mirror_only=False): diff --git a/var/spack/repos/builtin/packages/photos/package.py b/var/spack/repos/builtin/packages/photos/package.py index ea07db9e107393..2ee8af60cf3887 100644 --- a/var/spack/repos/builtin/packages/photos/package.py +++ b/var/spack/repos/builtin/packages/photos/package.py @@ -20,6 +20,9 @@ class Photos(AutotoolsPackage): version("3.64", sha256="cb4096b4804289fc4d54a992caa566cbbd33f41f65f8906deb01200dc5163027") version("3.61", sha256="acd3bcb769ba2a3e263de399e9b89fd6296405c9cbc5045b83baba3e60db4b26") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("hepmc", default=True, description="Build with HepMC2 support") variant("hepmc3", default=False, description="Build with HepMC3 support") diff --git a/var/spack/repos/builtin/packages/photospline/package.py b/var/spack/repos/builtin/packages/photospline/package.py index 14534795420b4d..ecfbab83733d74 100644 --- a/var/spack/repos/builtin/packages/photospline/package.py +++ b/var/spack/repos/builtin/packages/photospline/package.py @@ -25,4 +25,7 @@ class Photospline(CMakePackage): version("2.0.3", sha256="7045a631c41489085037b05fac98fd9cad73dc4262b7eead143d09e5f8265dec") version("2.0.2", sha256="0a3368205a7971a6919483ad5b5f0fbebb74614ec1891c95bb6a4fc9d3b950d4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cfitsio") diff --git a/var/spack/repos/builtin/packages/php/package.py b/var/spack/repos/builtin/packages/php/package.py index 441fe3af7bb464..9abe26f281e89f 100644 --- a/var/spack/repos/builtin/packages/php/package.py +++ b/var/spack/repos/builtin/packages/php/package.py @@ -29,6 +29,9 @@ class Php(AutotoolsPackage): version("7.2.24", sha256="334c9915733f6a29e1462f64038b1b4b1b21cb18f4f5f980add86792b5550ab3") version("7.1.33", sha256="f80a795a09328a9441bae4a8a60fa0d6d43ec5adc98f5aa5f51d06f4522c07fe") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/phylobayesmpi/package.py b/var/spack/repos/builtin/packages/phylobayesmpi/package.py index dadbb37a42b94a..8cd32e1c22f5b7 100644 --- a/var/spack/repos/builtin/packages/phylobayesmpi/package.py +++ b/var/spack/repos/builtin/packages/phylobayesmpi/package.py @@ -15,8 +15,11 @@ class Phylobayesmpi(MakefilePackage): license("GPL-2.0-only") + version("1.9", sha256="567d8db995f23b2b0109c1e6088a7e5621e38fec91d6b2f27abd886b90ea31ce") version("1.8b", sha256="7ff017bf492c1d8b42bfff3ee8e998ba1c50f4e4b3d9d6125647b91738017324") + depends_on("cxx", type="build") # generated + depends_on("mpi") build_directory = "sources" diff --git a/var/spack/repos/builtin/packages/picsar/package.py b/var/spack/repos/builtin/packages/picsar/package.py index 522551fa1cb345..bfc36739152af2 100644 --- a/var/spack/repos/builtin/packages/picsar/package.py +++ b/var/spack/repos/builtin/packages/picsar/package.py @@ -18,6 +18,10 @@ class Picsar(MakefilePackage): version("develop", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("prod", default=True, description="Production mode (without FFTW)") variant( "prod_spectral", default=False, description="Production mode with spectral solver and FFTW" diff --git a/var/spack/repos/builtin/packages/picsarlite/package.py b/var/spack/repos/builtin/packages/picsarlite/package.py index 79e6fd58e2114b..98365c4f42620e 100644 --- a/var/spack/repos/builtin/packages/picsarlite/package.py +++ b/var/spack/repos/builtin/packages/picsarlite/package.py @@ -21,6 +21,9 @@ class Picsarlite(MakefilePackage): version("develop", branch="PICSARlite") version("0.1", tag="PICSARlite-0.1", commit="3c9cee9bdf32da0998f504bff7af31fcae2f0452") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("prod", default=True, description="Production mode (without FFTW)") variant( "prod_spectral", default=False, description="Production mode with spectral solver and FFTW" diff --git a/var/spack/repos/builtin/packages/pidx/package.py b/var/spack/repos/builtin/packages/pidx/package.py index b9f0fa4f9ce551..e16cb06af670bf 100644 --- a/var/spack/repos/builtin/packages/pidx/package.py +++ b/var/spack/repos/builtin/packages/pidx/package.py @@ -20,5 +20,8 @@ class Pidx(CMakePackage): version("1.0", commit="6afa1cf71d1c41263296dc049c8fabaf73c296da") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.4:", type="build") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/pigz/package.py b/var/spack/repos/builtin/packages/pigz/package.py index 92b1084d53931e..bad604900e3494 100644 --- a/var/spack/repos/builtin/packages/pigz/package.py +++ b/var/spack/repos/builtin/packages/pigz/package.py @@ -21,6 +21,8 @@ class Pigz(MakefilePackage): version("2.4", sha256="e228e7d18b34c4ece8d596eb6eee97bde533c6beedbb728d07d3abe90b4b1b52") version("2.3.4", sha256="763f2fdb203aa0b7b640e63385e38e5dd4e5aaa041bc8e42aa96f2ef156b06e8") + depends_on("c", type="build") # generated + depends_on("zlib-api") def build(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/pika-algorithms/package.py b/var/spack/repos/builtin/packages/pika-algorithms/package.py index 3442ff8aba46b1..b96ab2c764743a 100644 --- a/var/spack/repos/builtin/packages/pika-algorithms/package.py +++ b/var/spack/repos/builtin/packages/pika-algorithms/package.py @@ -24,6 +24,8 @@ class PikaAlgorithms(CMakePackage): version("0.1.0", sha256="64da008897dfa7373155595c46d2ce6b97a8a3cb5bea33ae7f2d1ff359f0d9b6") version("main", branch="main") + depends_on("cxx", type="build") + generator("ninja") map_cxxstd = lambda cxxstd: "2a" if cxxstd == "20" else cxxstd diff --git a/var/spack/repos/builtin/packages/pika/package.py b/var/spack/repos/builtin/packages/pika/package.py index 270e802471381a..e20d181fe7b6e1 100644 --- a/var/spack/repos/builtin/packages/pika/package.py +++ b/var/spack/repos/builtin/packages/pika/package.py @@ -19,6 +19,9 @@ class Pika(CMakePackage, CudaPackage, ROCmPackage): license("BSL-1.0") + version("0.26.0", sha256="bbec5472c71006c1f55e7946c8dc517dae76c41cacb36fa98195312c74a1bb9a") + version("0.25.0", sha256="6646e12f88049116d84ce0caeedaa039a13caaa0431964caea4660b739767b2e") + version("0.24.0", sha256="3b97c684107f892a633f598d94bcbd1e238d940e88e1c336f205e81b99326cc3") version("0.23.0", sha256="d1981e198ac4f8443770cebbeff7a132b8f6c1a42e32b0b06fea02cc9df99595") version("0.22.2", sha256="eeffa8584336b239aca167f0056e815b1b6d911e46cbb3cd6b8b811d101c1052") version("0.22.1", sha256="b0de0649bee336847622f97b59b34a80cb3cfd9a931bbdb38299bc4904f19b92") @@ -48,8 +51,13 @@ class Pika(CMakePackage, CudaPackage, ROCmPackage): version("0.1.0", sha256="aa0ae2396cd264d821a73c4c7ecb118729bb3de042920c9248909d33755e7327") version("main", branch="main") + depends_on("cxx", type="build") + generator("ninja") + variant("shared", default=True, description="Build shared libraries") + conflicts("~shared", when="@:0.25") + cxxstds = ("17", "20", "23") variant( "cxxstd", @@ -85,6 +93,7 @@ class Pika(CMakePackage, CudaPackage, ROCmPackage): description="Enable support for sanitizers. " "Specific sanitizers must be explicitly enabled with -fsanitize=*.", ) + variant("valgrind", default=False, description="Enable support for valgrind") variant( "stdexec", default=False, @@ -114,6 +123,7 @@ class Pika(CMakePackage, CudaPackage, ROCmPackage): # https://github.com/pika-org/pika/issues/686 conflicts("^fmt@10:", when="@:0.15 +cuda") conflicts("^fmt@10:", when="@:0.15 +rocm") + depends_on("spdlog@1.9.2:", when="@0.25:") depends_on("hwloc@1.11.5:") depends_on("gperftools", when="malloc=tcmalloc") @@ -134,6 +144,8 @@ class Pika(CMakePackage, CudaPackage, ROCmPackage): depends_on("whip@0.1: +rocm", when="@0.9: +rocm") depends_on("whip@0.1: +cuda", when="@0.9: +cuda") + depends_on("valgrind", when="+valgrind") + with when("+rocm"): for val in ROCmPackage.amdgpu_targets: depends_on(f"whip@0.1: amdgpu_target={val}", when=f"@0.9: amdgpu_target={val}") @@ -184,6 +196,7 @@ def cmake_args(self): spec, args = self.spec, [] args += [ + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), self.define("PIKA_WITH_CXX_STANDARD", spec.variants["cxxstd"].value), self.define_from_variant("PIKA_WITH_EXAMPLES", "examples"), self.define_from_variant("PIKA_WITH_MALLOC", "malloc"), @@ -193,6 +206,7 @@ def cmake_args(self): self.define_from_variant("PIKA_WITH_APEX", "apex"), self.define_from_variant("PIKA_WITH_TRACY", "tracy"), self.define_from_variant("PIKA_WITH_SANITIZERS", "sanitizers"), + self.define_from_variant("PIKA_WITH_VALGRIND", "valgrind"), self.define("PIKA_WITH_TESTS", self.run_tests), self.define_from_variant("PIKA_WITH_GENERIC_CONTEXT_COROUTINES", "generic_coroutines"), self.define("BOOST_ROOT", spec["boost"].prefix), diff --git a/var/spack/repos/builtin/packages/pilercr/package.py b/var/spack/repos/builtin/packages/pilercr/package.py index a25737b242119e..9a9189b853f349 100644 --- a/var/spack/repos/builtin/packages/pilercr/package.py +++ b/var/spack/repos/builtin/packages/pilercr/package.py @@ -15,6 +15,8 @@ class Pilercr(MakefilePackage): version("1.06", sha256="50175f7aa171674cda5ba255631f340f9cc7f80e8cc25135a4cb857147d91068") + depends_on("cxx", type="build") # generated + @property def build_targets(self): targets = [] diff --git a/var/spack/repos/builtin/packages/pindel/package.py b/var/spack/repos/builtin/packages/pindel/package.py index 484228f4986711..f43ae2c1224b93 100644 --- a/var/spack/repos/builtin/packages/pindel/package.py +++ b/var/spack/repos/builtin/packages/pindel/package.py @@ -22,6 +22,8 @@ class Pindel(MakefilePackage): version("0.2.5a7", sha256="0a270483dee9ef617d422eb61d3478334ee8f55e952d0a439529c2b21fcf8fb4") version("0.2.5", sha256="9908940d090eff23d940c3b6f2f6b3fc2bb1fd3b7a2d553cc81eed240a23fd9f") + depends_on("cxx", type="build") # generated + depends_on("htslib@1.7:") # GCC > 4.8 seems to dislike calling abs on an unsigned integer diff --git a/var/spack/repos/builtin/packages/pinentry/package.py b/var/spack/repos/builtin/packages/pinentry/package.py index eb52d3385f8b00..81b166f3a32f2e 100644 --- a/var/spack/repos/builtin/packages/pinentry/package.py +++ b/var/spack/repos/builtin/packages/pinentry/package.py @@ -22,11 +22,16 @@ class Pinentry(AutotoolsPackage): license("GPL-2.0-or-later") + version("1.3.1", sha256="bc72ee27c7239007ab1896c3c2fae53b076e2c9bd2483dc2769a16902bce8c04") + version("1.3.0", sha256="9b3cd5226e7597f2fded399a3bc659923351536559e9db0826981bca316494de") version("1.2.1", sha256="457a185e5a85238fb945a955dc6352ab962dc8b48720b62fc9fa48c7540a4067") version("1.2.0", sha256="10072045a3e043d0581f91cd5676fcac7ffee957a16636adedaa4f583a616470") version("1.1.1", sha256="cd12a064013ed18e2ee8475e669b9f58db1b225a0144debdb85a68cecddba57f") version("1.1.0", sha256="68076686fa724a290ea49cdf0d1c0c1500907d1b759a3bcbfbec0293e8f56570") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + supported_guis = [ "curses", "tty", @@ -51,6 +56,7 @@ class Pinentry(AutotoolsPackage): depends_on("libgpg-error@1.16:") depends_on("libassuan@2.1.0:") + depends_on("libassuan@:2", when="@:1.2") # Optional GUI dependencies depends_on("ncurses", when="gui=curses") diff --git a/var/spack/repos/builtin/packages/pinfo/package.py b/var/spack/repos/builtin/packages/pinfo/package.py index 39b66c9ee71f5e..62e5e06875d87e 100644 --- a/var/spack/repos/builtin/packages/pinfo/package.py +++ b/var/spack/repos/builtin/packages/pinfo/package.py @@ -16,6 +16,8 @@ class Pinfo(AutotoolsPackage): version("0.6.12", sha256="82af48ba23b8c26b1f4e67b45f718142eb0f760326b782f80c765801d3532077") version("0.6.11", sha256="fd26017ac9db179d709b49e450c3097e7d6f99cd94de7b5da824ec757c6992b2") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/piranha/package.py b/var/spack/repos/builtin/packages/piranha/package.py index 8ae15b3d82d947..19a5fd97632cbb 100644 --- a/var/spack/repos/builtin/packages/piranha/package.py +++ b/var/spack/repos/builtin/packages/piranha/package.py @@ -21,6 +21,8 @@ class Piranha(CMakePackage): version("develop", branch="master") version("0.5", sha256="34a89bda8208ff48cfb116efa7d53c09e8a9b3838af4bb96ba2e19e4930b3a58") + depends_on("cxx", type="build") # generated + variant("python", default=True, description="Build the Python bindings") # Build dependencies diff --git a/var/spack/repos/builtin/packages/pism/package.py b/var/spack/repos/builtin/packages/pism/package.py index 641e985ddb5f6d..85b45cec32ddc7 100644 --- a/var/spack/repos/builtin/packages/pism/package.py +++ b/var/spack/repos/builtin/packages/pism/package.py @@ -22,6 +22,10 @@ class Pism(CMakePackage): version("0.7.x", branch="stable0.7") version("icebin", branch="efischer/dev") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("extra", default=False, description="Build extra executables (testing/verification)") variant("shared", default=True, description="Build shared Pism libraries") variant("python", default=False, description="Build python bindings", when="@1.1:") diff --git a/var/spack/repos/builtin/packages/pixman/package.py b/var/spack/repos/builtin/packages/pixman/package.py index 422996cb0171cb..499b313c815aba 100644 --- a/var/spack/repos/builtin/packages/pixman/package.py +++ b/var/spack/repos/builtin/packages/pixman/package.py @@ -26,11 +26,15 @@ class Pixman(AutotoolsPackage): version("0.34.0", sha256="21b6b249b51c6800dc9553b65106e1e37d0e25df942c90531d4c3997aa20a88e") version("0.32.6", sha256="3dfed13b8060eadabf0a4945c7045b7793cc7e3e910e748a8bb0f0dc3e794904") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("flex", type="build") depends_on("bison@3:", type="build") depends_on("libpng") + variant("shared", default=True, description="Build shared library") + # As discussed here: # https://bugs.freedesktop.org/show_bug.cgi?id=104886 # __builtin_shuffle was removed in clang 5.0. @@ -60,10 +64,12 @@ def patch_config_h_for_intel(self): @property def libs(self): - return find_libraries("libpixman-1", self.prefix, shared=True, recursive=True) + return find_libraries( + "libpixman-1", self.prefix, shared=self.spec.satisfies("+shared"), recursive=True + ) def configure_args(self): - args = ["--enable-libpng", "--disable-gtk"] + args = ["--enable-libpng", "--disable-gtk", "--with-pic"] if sys.platform == "darwin": args += ["--disable-mmx", "--disable-silent-rules"] @@ -74,4 +80,10 @@ def configure_args(self): if self.spec.target.family == "aarch64": args.append("--disable-arm-a64-neon") + # The Fujitsu compiler does not support assembler macros. + if self.spec.satisfies("%fj"): + args.append("--disable-arm-a64-neon") + + args.extend(self.enable_or_disable("shared")) + return args diff --git a/var/spack/repos/builtin/packages/pixz/package.py b/var/spack/repos/builtin/packages/pixz/package.py index 932128da273b4b..e4b91b99d98e3a 100644 --- a/var/spack/repos/builtin/packages/pixz/package.py +++ b/var/spack/repos/builtin/packages/pixz/package.py @@ -17,5 +17,7 @@ class Pixz(AutotoolsPackage): version("1.0.7", sha256="e5e32c6eb0bf112b98e74a5da8fb63b9f2cae71800f599d97ce540e150c8ddc5") version("1.0.6", sha256="02c50746b134fa1b1aae41fcc314d7c6f1919b3d48bcdea01bf11769f83f72e8") + depends_on("c", type="build") # generated + depends_on("xz") depends_on("libarchive") diff --git a/var/spack/repos/builtin/packages/pkg-config/package.py b/var/spack/repos/builtin/packages/pkg-config/package.py index b86996f731e56c..d2f51bf11d0488 100644 --- a/var/spack/repos/builtin/packages/pkg-config/package.py +++ b/var/spack/repos/builtin/packages/pkg-config/package.py @@ -20,6 +20,8 @@ class PkgConfig(AutotoolsPackage): version("0.29.1", sha256="beb43c9e064555469bd4390dcfd8030b1536e0aa103f08d7abf7ae8cac0cb001") version("0.28", sha256="6b6eb31c6ec4421174578652c7e141fdaae2dabad1021f420d8713206ac1f845") + depends_on("c", type="build") # generated + provides("pkgconfig") variant("internal_glib", default=True, description="Builds with internal glib") @@ -53,12 +55,18 @@ def setup_dependent_build_environment(self, env, dependent_spec): env.append_path("ACLOCAL_PATH", self.prefix.share.aclocal) def configure_args(self): + spec = self.spec config_args = ["--enable-shared"] - if "+internal_glib" in self.spec: + if spec.satisfies("+internal_glib"): # There's a bootstrapping problem here; # glib uses pkg-config as well, so break # the cycle by using the internal glib. config_args.append("--with-internal-glib") + for strict_compiler in ("%oneapi", "%cce", "%apple-clang@15:", "%clang@15:"): + if spec.satisfies(strict_compiler): + config_args.append("CFLAGS=-Wno-error=int-conversion") + break + return config_args diff --git a/var/spack/repos/builtin/packages/pkgconf/package.py b/var/spack/repos/builtin/packages/pkgconf/package.py index 8e04c0f99cef23..39f3b198e0d2d4 100644 --- a/var/spack/repos/builtin/packages/pkgconf/package.py +++ b/var/spack/repos/builtin/packages/pkgconf/package.py @@ -19,6 +19,7 @@ class Pkgconf(AutotoolsPackage): license("ISC") + version("2.2.0", sha256="b06ff63a83536aa8c2f6422fa80ad45e4833f590266feb14eaddfe1d4c853c69") version("1.9.5", sha256="1ac1656debb27497563036f7bffc281490f83f9b8457c0d60bcfb638fb6b6171") version("1.8.0", sha256="ef9c7e61822b7cb8356e6e9e1dca58d9556f3200d78acab35e4347e9d4c2bbaf") version("1.7.4", sha256="d73f32c248a4591139a6b17777c80d4deab6b414ec2b3d21d0a24be348c476ab") @@ -32,6 +33,8 @@ class Pkgconf(AutotoolsPackage): version("1.3.10", sha256="62577d265fa9415a57a77a59dede5526b7ece3ef59a750434b281b262f0c1da9") version("1.3.8", sha256="fc06f058e6905435481f649865ca51000192c91808f307b1053ca5e859cb1488") + depends_on("c", type="build") # generated + provides("pkgconfig") # https://github.com/spack/spack/issues/11704 @@ -71,5 +74,5 @@ def check(self): @run_after("install") def link_pkg_config(self): - symlink("pkgconf", "{0}/pkg-config".format(self.prefix.bin)) - symlink("pkgconf.1", "{0}/pkg-config.1".format(self.prefix.share.man.man1)) + symlink("pkgconf", f"{self.prefix.bin}/pkg-config") + symlink("pkgconf.1", f"{self.prefix.share.man.man1}/pkg-config.1") diff --git a/var/spack/repos/builtin/packages/pktools/package.py b/var/spack/repos/builtin/packages/pktools/package.py index 59c2d1ef234f83..131911892e700b 100644 --- a/var/spack/repos/builtin/packages/pktools/package.py +++ b/var/spack/repos/builtin/packages/pktools/package.py @@ -19,6 +19,9 @@ class Pktools(CMakePackage): version("2.6.7.1", sha256="519b6a500ce3c5ef3793c1cda1f5377f13b7d7591b5ccc376b2bd1de4bd4f7e5") version("2.6.7", sha256="f566647e93037cc01cebfe17ea554d798177fe5081887c70223dcca817f4fe7f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("fann", default=True, description="Build with libfann to enable related programs") variant("liblas", default=False, description="Build with libLAS support") diff --git a/var/spack/repos/builtin/packages/planck-likelihood/package.py b/var/spack/repos/builtin/packages/planck-likelihood/package.py index 7315b7f9e25df4..30629a7ec3a74e 100644 --- a/var/spack/repos/builtin/packages/planck-likelihood/package.py +++ b/var/spack/repos/builtin/packages/planck-likelihood/package.py @@ -21,6 +21,9 @@ class PlanckLikelihood(Package): url="https://irsa.ipac.caltech.edu/data/Planck/release_2/software/COM_Likelihood_Code-v2.0.R2.00.tar.bz2", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("lensing-ext", default=False, description="Provide lensing-ext data") variant("plik-DS", default=False, description="Provide plik-DS data") variant("plik-HM-ext", default=False, description="Provide plik-HM-ext data") @@ -80,9 +83,9 @@ def install(self, spec, prefix): filter_file("^\t@", "\t", "Makefile") makeflags = [ - "PREFIX=%s" % prefix, + f"PREFIX={prefix}", "COLORS=0", - "CFITSIOPATH=%s" % spec["cfitsio"].prefix, + f"CFITSIOPATH={spec['cfitsio'].prefix}", "CC=cc", "FC=fc", "IFORTLIBPATH=", @@ -90,9 +93,9 @@ def install(self, spec, prefix): "GFORTRANLIBPATH=", "GFORTRANRUNTIME=-lgfortran -lgomp", "LAPACKLIBPATH=", - "LAPACK=%s" % (spec["lapack"].libs + spec["blas"].libs).ld_flags, - "COPENMP=%s" % self.compiler.openmp_flag, - "FOPENMP=%s" % self.compiler.openmp_flag, + f"LAPACK={(spec['lapack'].libs + spec['blas'].libs).ld_flags}", + f"COPENMP={self.compiler.openmp_flag}", + f"FOPENMP={self.compiler.openmp_flag}", ] # Build diff --git a/var/spack/repos/builtin/packages/plasma/package.py b/var/spack/repos/builtin/packages/plasma/package.py index 1ff83f62011ea6..85b0141fafddae 100644 --- a/var/spack/repos/builtin/packages/plasma/package.py +++ b/var/spack/repos/builtin/packages/plasma/package.py @@ -43,6 +43,9 @@ class Plasma(CMakePackage): url="https://github.com/icl-utk-edu/plasma/releases/download/17.01/plasma-17.01.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + build_system( conditional("makefile", when="@:17.1"), conditional("cmake", when="@18.9:"), diff --git a/var/spack/repos/builtin/packages/plink2/package.py b/var/spack/repos/builtin/packages/plink2/package.py index f1c2b439cf551c..498ef092b018cb 100644 --- a/var/spack/repos/builtin/packages/plink2/package.py +++ b/var/spack/repos/builtin/packages/plink2/package.py @@ -11,9 +11,20 @@ class Plink2(MakefilePackage): range of basic, large-scale analyses in a computationally efficient manner.""" homepage = "https://www.cog-genomics.org/plink/2.0/" - git = "https://github.com/chrchang/plink-ng.git" + url = "https://github.com/chrchang/plink-ng/archive/refs/tags/v2.00a5.11.tar.gz" + list_url = "https://github.com/chrchang/plink-ng/tags" - version("2.00a4.3", tag="v2.00a4.3", commit="59fca48f6f8135886ff68962fbe31ae0c6413228") + maintainers("teaguesterling") + + license("GPLv3", checked_by="teaguesterling") + # See: https://github.com/chrchang/plink-ng/blob/master/2.0/COPYING + + version("2.00a5.11", sha256="8b664baa0b603f374123c32818ea2f053272840ba60e998d06cb864f3a6f1c38") + version("2.00a5.10", sha256="53d845c6a04f8fc701e6f58f6431654e36cbf6b79bff25099862d169a8199a45") + version("2.00a4.3", sha256="3cd1d26ac6dd1c451b42440f479789aa19d2b57642c118aac530a5ff1b0b4ce6") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("zlib-api") depends_on("zlib@1.2.12:", when="^[virtuals=zlib-api] zlib") diff --git a/var/spack/repos/builtin/packages/ploticus/package.py b/var/spack/repos/builtin/packages/ploticus/package.py index c473a926dd2e1d..0f1ae59373d0c2 100644 --- a/var/spack/repos/builtin/packages/ploticus/package.py +++ b/var/spack/repos/builtin/packages/ploticus/package.py @@ -15,6 +15,8 @@ class Ploticus(MakefilePackage): version("2.42", sha256="3f29e4b9f405203a93efec900e5816d9e1b4381821881e241c08cab7dd66e0b0") + depends_on("c", type="build") # generated + depends_on("zlib-api") depends_on("libpng") diff --git a/var/spack/repos/builtin/packages/plplot/package.py b/var/spack/repos/builtin/packages/plplot/package.py index 1035a45d254590..dc3b4d948bf3d2 100644 --- a/var/spack/repos/builtin/packages/plplot/package.py +++ b/var/spack/repos/builtin/packages/plplot/package.py @@ -20,6 +20,10 @@ class Plplot(CMakePackage): version("5.12.0", sha256="8dc5da5ef80e4e19993d4c3ef2a84a24cc0e44a5dade83201fca7160a6d352ce") version("5.11.0", sha256="bfa8434e6e1e7139a5651203ec1256c8581e2fac3122f907f7d8d25ed3bd5f7e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("java", default=False, description="Enable Java binding") variant("lua", default=False, description="Enable Lua binding") variant("pango", default=False, description="Enable Pango") diff --git a/var/spack/repos/builtin/packages/plumed/package.py b/var/spack/repos/builtin/packages/plumed/package.py index df734349c11549..bf3b3099fd6320 100644 --- a/var/spack/repos/builtin/packages/plumed/package.py +++ b/var/spack/repos/builtin/packages/plumed/package.py @@ -113,6 +113,10 @@ class Plumed(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Variants. PLUMED by default builds a number of optional modules. # The ones listed here are not built by default for various reasons, # such as stability, lack of testing, or lack of demand. diff --git a/var/spack/repos/builtin/packages/ply/package.py b/var/spack/repos/builtin/packages/ply/package.py index fde3b9787fc1ef..19c74c75d80c5b 100644 --- a/var/spack/repos/builtin/packages/ply/package.py +++ b/var/spack/repos/builtin/packages/ply/package.py @@ -18,6 +18,8 @@ class Ply(AutotoolsPackage): version("2.1.1", commit="899afb0c35ba2191dd7aa21f13bc7fde2655c475") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/pmdk/package.py b/var/spack/repos/builtin/packages/pmdk/package.py index ab6728754fd2dd..033e833d7a0b65 100644 --- a/var/spack/repos/builtin/packages/pmdk/package.py +++ b/var/spack/repos/builtin/packages/pmdk/package.py @@ -31,6 +31,9 @@ class Pmdk(Package): version("1.6", sha256="3b99e6c30709326a94d2e73a9247a8dfb58d0a394c5b7714e5c3d8a3ad2e2e9f") version("1.5", sha256="6b069d7207febeb62440e89245e8b18fcdf40b6170d2ec2ef33c252ed16db2d4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("ndctl", default=False, description="Build components requiring ndctl") variant("doc", default=False, description="Build documentation") variant("experimental", default=False, description="Build experimental stuff") diff --git a/var/spack/repos/builtin/packages/pmemkv/package.py b/var/spack/repos/builtin/packages/pmemkv/package.py index 73d4cf99ab99b5..1c097540031486 100644 --- a/var/spack/repos/builtin/packages/pmemkv/package.py +++ b/var/spack/repos/builtin/packages/pmemkv/package.py @@ -23,6 +23,9 @@ class Pmemkv(CMakePackage): version("1.0.3", sha256="cae393a01ba69364271c5894046bf2c611f677ac88012f2473fadf6fcd20ff29") version("1.0.2", sha256="a0cbbb60c0342d6fd0b73d2cee1a1423c6a894b8d21daf669016809961fe23b8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libpmemobj-cpp@develop", when="@master") depends_on("libpmemobj-cpp@1.12:", when="@1.4:") depends_on("libpmemobj-cpp@1.11:", when="@1.3:") diff --git a/var/spack/repos/builtin/packages/pmerge/package.py b/var/spack/repos/builtin/packages/pmerge/package.py index 5262493d5437e6..ce51a38c7445d7 100644 --- a/var/spack/repos/builtin/packages/pmerge/package.py +++ b/var/spack/repos/builtin/packages/pmerge/package.py @@ -21,6 +21,8 @@ class Pmerge(AutotoolsPackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + depends_on("automake@1.14.0:1.14", type="build") depends_on("autoconf", type="build") depends_on("m4", type="build") diff --git a/var/spack/repos/builtin/packages/pmgr-collective/package.py b/var/spack/repos/builtin/packages/pmgr-collective/package.py index 2f8b0f1246f252..2de440b3c901ea 100644 --- a/var/spack/repos/builtin/packages/pmgr-collective/package.py +++ b/var/spack/repos/builtin/packages/pmgr-collective/package.py @@ -15,6 +15,8 @@ class PmgrCollective(Package): version("1.0", sha256="c8022d1128ce5e8f637166af6e55c13700e665550e468b8cdb1531441c6bb7f5") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make('PREFIX="' + prefix + '"') make('PREFIX="' + prefix + '"', "install") diff --git a/var/spack/repos/builtin/packages/pmix/package.py b/var/spack/repos/builtin/packages/pmix/package.py index 99850782780912..6dd7947f88c122 100644 --- a/var/spack/repos/builtin/packages/pmix/package.py +++ b/var/spack/repos/builtin/packages/pmix/package.py @@ -2,6 +2,7 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) + import os import platform @@ -33,40 +34,127 @@ class Pmix(AutotoolsPackage): homepage = "https://pmix.org" url = "https://github.com/pmix/pmix/releases/download/v3.1.3/pmix-3.1.3.tar.bz2" git = "https://github.com/openpmix/openpmix.git" + maintainers("rhc54") license("BSD-3-Clause-Open-MPI") # Branches 4.2 & 5.0 will also need submodules version("master", branch="master", submodules=True) + version("5.0.2", sha256="28227ff2ba925da2c3fece44502f23a91446017de0f5a58f5cea9370c514b83c") version("5.0.1", sha256="d4371792d4ba4c791e1010100b4bf9a65500ababaf5ff25d681f938527a67d4a") version("5.0.0", sha256="92a85c4946346816c297ac244fbaf4f723bba87fb7e4424a057c2dabd569928d") + version("4.2.9", sha256="6b11f4fd5c9d7f8e55fc6ebdee9af04b839f44d06044e58cea38c87c168784b3") + version("4.2.8", sha256="09b442878e233f3d7f11168e129b32e5c8573c3ab6aaa9f86cf2d59c31a43dc9") + version("4.2.7", sha256="ac9cf58a0bf01bfacd51d342100234f04c740ec14257e4492d1dd0207ff2a917") version("4.2.6", sha256="10b0d5a7fca70272e9427c677557578ac452cea02aeb00e30dec2116d20c3cd0") version("4.2.5", sha256="a89c2c5dc69715a4df1e76fdc4318299386c184623a1d0d5eb1fb062e14b0d2b") version("4.2.4", sha256="c4699543f2278d3a78bdac72b4b2da9cd92d11d18478d66522b8991764b021c8") version("4.2.3", sha256="c3d9d6885ae39c15627a86dc4718e050baf604acda71b8b9e2ee3b12ad5c2d2a") version("4.2.2", sha256="935b2f492e4bc409017f1425a83366aa72a7039605ea187c9fac7bb1371cd73c") version("4.2.1", sha256="3c992fa0d653b56e0e409bbaec9de8fc1b82c948364dbb28545442315ed2a179") - version("4.1.2", sha256="670d3a02b39fb2126fe8084174cf03c484e027b5921b5c98a851108134e2597a") - version("4.1.1", sha256="0527a15d616637b95975d238bbc100b244894518fbba822cd8f46589ca61ccec") - version("4.1.0", sha256="145f05a6c621bfb3fc434776b615d7e6d53260cc9ba340a01f55b383e07c842e") - version("3.2.3", sha256="9b835f23c2f94a193c14012ee68b3657a61c568598cdd1212a3716b32d41a135") - version("3.2.2", sha256="7e7fafe2b338dab42a94002d99330a5bb0ebbdd06381ec65953a87c94db3dd23") - version("3.2.1", sha256="7e5db8ada5828cf85c12f70db6bfcf777d13e5c4c73b2206bb5e394d47066a2b") - version("3.1.6", sha256="3df0e0cb0cae67b59edba1d90f55d73467be8404874fe89056690739e039a840") - version("3.1.5", sha256="88934195174455df478b996313095df25b51d0caf5a5cce01b22f0ccdc6c5cf7") - version("3.1.3", sha256="118acb9c4e10c4e481406dcffdfa762f314af50db75336bf8460e53b56dc439d") - version("3.1.2", sha256="28aed0392d4ca2cdfbdd721e6210c94dadc9830677fea37a0abe9d592c00f9c3") - version("3.0.2", sha256="df68f35a3ed9517eeade80b13855cebad8fde2772b36a3f6be87559b6d430670") - version("3.0.1", sha256="b81055d2c0d61ef5a451b63debc39c820bcd530490e2e4dcb4cdbacb618c157c") - version("3.0.0", sha256="ee8f68107c24b706237a53333d832445315ae37de6773c5413d7fda415a6e2ee") - version("2.2.3", sha256="6fa5d45eb089e29101190c645e986342a24a03a4ea3a936db0b120aafa45b1f0") - version("2.2.2", sha256="cd951dbda623fadc5b32ae149d8cc41f9462eac4d718d089340911b1a7c20714") - version("2.1.4", sha256="eb72d292e76e200f02cf162a477eecea2559ef3ac2edf50ee95b3fe3983d033e") - version("2.1.3", sha256="281283133498e7e5999ed5c6557542c22408bc9eb51ecbcf7696160616782a41") - version("2.1.2", sha256="94bb9c801c51a6caa1b8cef2b85ecf67703a5dfa4d79262e6668c37c744bb643") - version("2.0.1", sha256="ba6e0f32936b1859741adb221e18b2c1ee7dc53a6b374b9f7831adf1692b15fd") - version("1.2.5", sha256="a2b02d489ee730c06ee40e7f9ffcebb6c35bcb4f95153fab7c4276a3add6ae31") + version( + "4.1.2", + sha256="670d3a02b39fb2126fe8084174cf03c484e027b5921b5c98a851108134e2597a", + deprecated=True, + ) + version( + "4.1.1", + sha256="0527a15d616637b95975d238bbc100b244894518fbba822cd8f46589ca61ccec", + deprecated=True, + ) + version( + "4.1.0", + sha256="145f05a6c621bfb3fc434776b615d7e6d53260cc9ba340a01f55b383e07c842e", + deprecated=True, + ) + version( + "3.2.3", + sha256="9b835f23c2f94a193c14012ee68b3657a61c568598cdd1212a3716b32d41a135", + deprecated=True, + ) + version( + "3.2.2", + sha256="7e7fafe2b338dab42a94002d99330a5bb0ebbdd06381ec65953a87c94db3dd23", + deprecated=True, + ) + version( + "3.2.1", + sha256="7e5db8ada5828cf85c12f70db6bfcf777d13e5c4c73b2206bb5e394d47066a2b", + deprecated=True, + ) + version( + "3.1.6", + sha256="3df0e0cb0cae67b59edba1d90f55d73467be8404874fe89056690739e039a840", + deprecated=True, + ) + version( + "3.1.5", + sha256="88934195174455df478b996313095df25b51d0caf5a5cce01b22f0ccdc6c5cf7", + deprecated=True, + ) + version( + "3.1.3", + sha256="118acb9c4e10c4e481406dcffdfa762f314af50db75336bf8460e53b56dc439d", + deprecated=True, + ) + version( + "3.1.2", + sha256="28aed0392d4ca2cdfbdd721e6210c94dadc9830677fea37a0abe9d592c00f9c3", + deprecated=True, + ) + version( + "3.0.2", + sha256="df68f35a3ed9517eeade80b13855cebad8fde2772b36a3f6be87559b6d430670", + deprecated=True, + ) + version( + "3.0.1", + sha256="b81055d2c0d61ef5a451b63debc39c820bcd530490e2e4dcb4cdbacb618c157c", + deprecated=True, + ) + version( + "3.0.0", + sha256="ee8f68107c24b706237a53333d832445315ae37de6773c5413d7fda415a6e2ee", + deprecated=True, + ) + version( + "2.2.3", + sha256="6fa5d45eb089e29101190c645e986342a24a03a4ea3a936db0b120aafa45b1f0", + deprecated=True, + ) + version( + "2.2.2", + sha256="cd951dbda623fadc5b32ae149d8cc41f9462eac4d718d089340911b1a7c20714", + deprecated=True, + ) + version( + "2.1.4", + sha256="eb72d292e76e200f02cf162a477eecea2559ef3ac2edf50ee95b3fe3983d033e", + deprecated=True, + ) + version( + "2.1.3", + sha256="281283133498e7e5999ed5c6557542c22408bc9eb51ecbcf7696160616782a41", + deprecated=True, + ) + version( + "2.1.2", + sha256="94bb9c801c51a6caa1b8cef2b85ecf67703a5dfa4d79262e6668c37c744bb643", + deprecated=True, + ) + version( + "2.0.1", + sha256="ba6e0f32936b1859741adb221e18b2c1ee7dc53a6b374b9f7831adf1692b15fd", + deprecated=True, + ) + version( + "1.2.5", + sha256="a2b02d489ee730c06ee40e7f9ffcebb6c35bcb4f95153fab7c4276a3add6ae31", + deprecated=True, + ) + + depends_on("c", type="build") # generated variant( "pmi_backwards_compatibility", @@ -78,10 +166,10 @@ class Pmix(AutotoolsPackage): "restful", default=False, when="@4:", - description="allow a PMIx server to request services from " "a system-level REST server", + description="Allow a PMIx server to request services from " "a system-level REST server", ) - variant("python", default=False, when="@4.1.2:", description="Enable python bindigs") + variant("python", default=False, when="@4.1.2:", description="Enable python bindings") variant("docs", default=False, description="Build manpages") diff --git a/var/spack/repos/builtin/packages/pmlib/package.py b/var/spack/repos/builtin/packages/pmlib/package.py index 2ff509ad0084f8..01fd746cf53dd0 100644 --- a/var/spack/repos/builtin/packages/pmlib/package.py +++ b/var/spack/repos/builtin/packages/pmlib/package.py @@ -21,6 +21,10 @@ class Pmlib(CMakePackage): version("master", branch="master") version("6.4.1", commit="0a35f5bec8c12e532e5a1bdac8c32c659fd3ee11") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Activate MPI support") variant("example", default=False, description="This option turns on compiling sample codes.") variant("fortran", default=False, description="This option tells a compiler to use a Fortran.") diff --git a/var/spack/repos/builtin/packages/pnfft/package.py b/var/spack/repos/builtin/packages/pnfft/package.py index e3d765f8cb2f4c..ae7530cabd2603 100644 --- a/var/spack/repos/builtin/packages/pnfft/package.py +++ b/var/spack/repos/builtin/packages/pnfft/package.py @@ -21,6 +21,9 @@ class Pnfft(AutotoolsPackage): "1.0.7-alpha", sha256="fda558ff57ee3119754363bb6e6739338680d2d6860fe7dc42009d85562bd67a" ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("pfft") depends_on("gsl") diff --git a/var/spack/repos/builtin/packages/pngquant/package.py b/var/spack/repos/builtin/packages/pngquant/package.py index 4d58346a98ba9b..1cbfd086586492 100644 --- a/var/spack/repos/builtin/packages/pngquant/package.py +++ b/var/spack/repos/builtin/packages/pngquant/package.py @@ -19,4 +19,6 @@ class Pngquant(AutotoolsPackage): version("2.12.5", sha256="3638936cf6270eeeaabcee42e10768d78e4dc07cac9310307835c1f58b140808") + depends_on("c", type="build") # generated + depends_on("libpng") diff --git a/var/spack/repos/builtin/packages/pngwriter/package.py b/var/spack/repos/builtin/packages/pngwriter/package.py index 84bb9b3c38a5a4..679eb138e49e61 100644 --- a/var/spack/repos/builtin/packages/pngwriter/package.py +++ b/var/spack/repos/builtin/packages/pngwriter/package.py @@ -28,6 +28,8 @@ class Pngwriter(CMakePackage): version("0.6.0", sha256="5107c6be0bfadf76ba4d01a553f7e060b5a7763ca7d9374ef3e7e59746b3911e") version("0.5.6", sha256="0c5f3c1fd6f2470e88951f4b8add64cf5f5a7e7038115dba69604139359b08f1") + depends_on("cxx", type="build") # generated + depends_on("libpng") depends_on("zlib-api") depends_on("freetype") diff --git a/var/spack/repos/builtin/packages/pnmpi/package.py b/var/spack/repos/builtin/packages/pnmpi/package.py index 331ca93767aeb5..c875fd9070a0df 100644 --- a/var/spack/repos/builtin/packages/pnmpi/package.py +++ b/var/spack/repos/builtin/packages/pnmpi/package.py @@ -17,6 +17,10 @@ class Pnmpi(CMakePackage): version("1.7", sha256="523228bdc220ae417d6812c0766bba698a240d71c69981cb0cb2b09a75ef4a9e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=False, description="Configure PnMPI with Fortran support") variant( "tests", default=False, description='Build test cases and enable "test" makefile target' diff --git a/var/spack/repos/builtin/packages/poamsa/package.py b/var/spack/repos/builtin/packages/poamsa/package.py index 1193865c68e669..244eece6331626 100644 --- a/var/spack/repos/builtin/packages/poamsa/package.py +++ b/var/spack/repos/builtin/packages/poamsa/package.py @@ -17,6 +17,8 @@ class Poamsa(MakefilePackage): version("2.0", sha256="d98d8251af558f442d909a6527694825ef6f79881b7636cad4925792559092c2") + depends_on("c", type="build") # generated + def url_for_version(self, version): url = "https://downloads.sourceforge.net/project/poamsa/poamsa/{0}/poaV{1}.tar.gz" return url.format(version.dotted, version.up_to(1)) diff --git a/var/spack/repos/builtin/packages/pocl/package.py b/var/spack/repos/builtin/packages/pocl/package.py index da8ad4e6a69318..7a139a624a6bf5 100644 --- a/var/spack/repos/builtin/packages/pocl/package.py +++ b/var/spack/repos/builtin/packages/pocl/package.py @@ -33,6 +33,9 @@ class Pocl(CMakePackage): version("1.1", sha256="1e8dd0693a88c84937754df947b202871a40545b1b0a97ebefa370b0281c3c53") version("1.0", sha256="94bd86a2f9847c03e6c3bf8dca12af3734f8b272ffeacbc3fa8fcca58844b1d4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + conflicts("@:1.5", when="target=a64fx", msg="a64fx is supported by pocl v1.6 and above.") # < 3.0 provided full OpenCL 1.2 support and some intermediate level of diff --git a/var/spack/repos/builtin/packages/podio/cpack.patch b/var/spack/repos/builtin/packages/podio/cpack.patch deleted file mode 100644 index e685f9bc13dc94..00000000000000 --- a/var/spack/repos/builtin/packages/podio/cpack.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -86,7 +86,7 @@ include(cmake/podioMacros.cmake) - include(CTest) - - #--- enable CPack -------------------------------------------------------------- --include(cmake/podioCPack.cmake) -+#include(cmake/podioCPack.cmake) - - #--- target for Doxygen documentation ------------------------------------------ - if(CREATE_DOC) diff --git a/var/spack/repos/builtin/packages/podio/dictloading.patch b/var/spack/repos/builtin/packages/podio/dictloading.patch deleted file mode 100644 index 15ec301b13984b..00000000000000 --- a/var/spack/repos/builtin/packages/podio/dictloading.patch +++ /dev/null @@ -1,20 +0,0 @@ -diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index 120a899..05991f1 100755 ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -41,7 +41,7 @@ SET(headers - ${CMAKE_SOURCE_DIR}/include/podio/PythonEventStore.h - ) - PODIO_GENERATE_DICTIONARY(podioDict ${headers} SELECTION selection.xml -- OPTIONS --library ${CMAKE_SHARED_LIBRARY_PREFIX}podio${CMAKE_SHARED_LIBRARY_SUFFIX} -+ OPTIONS --library ${CMAKE_SHARED_LIBRARY_PREFIX}podioDict${CMAKE_SHARED_LIBRARY_SUFFIX} - ) - # prevent generating dictionary twice - set_target_properties(podioDict-dictgen PROPERTIES EXCLUDE_FROM_ALL TRUE) -@@ -58,5 +58,5 @@ install(TARGETS podio podioDict podioRootIO - install(DIRECTORY ${PROJECT_SOURCE_DIR}/include/podio DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}") - install(FILES - ${CMAKE_CURRENT_BINARY_DIR}/podioDictDict.rootmap -- ${CMAKE_CURRENT_BINARY_DIR}/libpodio_rdict.pcm -+ ${CMAKE_CURRENT_BINARY_DIR}/libpodioDict_rdict.pcm - DESTINATION "${CMAKE_INSTALL_LIBDIR}") diff --git a/var/spack/repos/builtin/packages/podio/package.py b/var/spack/repos/builtin/packages/podio/package.py index 944b491822984f..b4b4749dbc8724 100644 --- a/var/spack/repos/builtin/packages/podio/package.py +++ b/var/spack/repos/builtin/packages/podio/package.py @@ -20,6 +20,8 @@ class Podio(CMakePackage): tags = ["hep", "key4hep"] version("master", branch="master") + version("1.0.1", sha256="915531a2bcf638011bb6cc19715bbc46d846ec8b985555a1afdcd6abc017e21b") + version("1.0", sha256="491f335e148708e387e90e955a6150e1fc2e01bf6b4980b65e257ab0619559a9") version("0.99", sha256="c823918a6ec1365d316e0a753feb9d492e28903141dd124a1be06efac7c1877a") version( "0.17.4", @@ -66,86 +68,8 @@ class Podio(CMakePackage): sha256="d8208f98496af68ca8d02d302f428aab510e50d07575b90c3477fff7e499335b", deprecated=True, ) - version( - "0.16.2", - sha256="faf7167290faf322f23c734adff19904b10793b5ab14e1dfe90ce257c225114b", - deprecated=True, - ) - version( - "0.16.1", - sha256="23cd8dfd00f9cd5ae0b473ae3279fa2c22a2d90fb6c07b37d56e63a80dd76ab2", - deprecated=True, - ) - version( - "0.16", - sha256="4e149c2c9be9f9ca3a6d863498bb0f642dda1a43a19ac1afe7f99854ded5c510", - deprecated=True, - ) - version( - "0.15", - sha256="6c1520877ba1bce250e35a2a56c0a3da89fae0916c5ed7d5548d658237e067d9", - deprecated=True, - ) - version( - "0.14.3", - sha256="2a7a405dedc7f6980a0aad7df87b427a1f43bcf6d923a9bcce1698fd296359f7", - deprecated=True, - ) - version( - "0.14.1", - sha256="361ac3f3ec6f5a4830729ab45f96c19f0f62e9415ff681f7c6cdb4ebdb796f72", - deprecated=True, - ) - version( - "0.14", - sha256="47f99f1190dc71d6deb52a2b1831250515dbd5c9e0f263c3c8553ffc5b260dfb", - deprecated=True, - ) - version( - "0.13.2", - sha256="645f6915ca6f34789157c0a9dc8b0e9ec901e019b96eb8a68fb39011602e92eb", - deprecated=True, - ) - version( - "0.13.1", - sha256="2ae561c2a0e46c44245aa2098772374ad246c9fcb1956875c95c69c963501353", - deprecated=True, - ) - version( - "0.13", - sha256="e9cbd4e25730003d3706ad82e28b15cb5bdc524a78b0a26e90b89ea852101498", - deprecated=True, - ) - version( - "0.12", - sha256="1729a2ce21e8b307fc37dfb9a9f5ae031e9f4be4992385cf99dba3e5fdf5323a", - deprecated=True, - ) - version( - "0.11", - sha256="4b2765566a14f0ddece2c894634e0a8e4f42f3e44392addb9110d856f6267fb6", - deprecated=True, - ) - version( - "0.10", - sha256="b5b42770ec8b96bcd2748abc05669dd3e4d4cc84f81ed57d57d2eda1ade90ef2", - deprecated=True, - ) - version( - "0.9.2", - sha256="8234d1b9636029124235ef81199a1220968dcc7fdaeab81cdc96a47af332d240", - deprecated=True, - ) - version( - "0.9", - sha256="3cde67556b6b76fd2d004adfaa3b3b6173a110c0c209792bfdb5f9353e21076f", - deprecated=True, - ) - version( - "0.8", - sha256="9d035a7f5ebfae5279a17405003206853271af692f762e2bac8e73825f2af327", - deprecated=True, - ) + + depends_on("cxx", type="build") # generated variant( "cxxstd", @@ -157,13 +81,8 @@ class Podio(CMakePackage): variant("sio", default=False, description="Build the SIO I/O backend") variant("rntuple", default=False, description="Build the RNTuple backend") - # cpack config throws an error on some systems - patch("cpack.patch", when="@:0.10.0") - patch("dictloading.patch", when="@0.10.0") - patch("python-tests.patch", when="@:0.14.0") - depends_on("root@6.08.06: cxxstd=17", when="cxxstd=17") - depends_on("root@6.28.04:", when="+rntuple") + depends_on("root@6.28.04: +root7", when="+rntuple") depends_on("root@6.28:", when="@0.17:") for cxxstd in ("17", "20"): depends_on("root cxxstd={}".format(cxxstd), when="cxxstd={}".format(cxxstd)) @@ -171,16 +90,18 @@ class Podio(CMakePackage): depends_on("cmake@3.12:", type="build") depends_on("python", type=("build", "run")) depends_on("py-pyyaml", type=("build", "run")) - depends_on("py-jinja2@2.10.1:", type=("build", "run"), when="@0.12.0:") + depends_on("py-jinja2@2.10.1:", type=("build", "run")) depends_on("sio", type=("build", "link"), when="+sio") - depends_on("catch2@3.0.1:", type=("test"), when="@0.13:0.16.5") + depends_on("catch2@3.0.1:", type=("test"), when="@:0.16.5") depends_on("catch2@3.1:", type=("test"), when="@0.16.6:") - depends_on("py-graphviz", type=("run"), when="@0.16.3:") + depends_on("py-graphviz", type=("run")) depends_on("py-tabulate", type=("run", "test"), when="@0.16.6:") - conflicts("+sio", when="@:0.12", msg="sio support requires at least podio@0.13") conflicts("+rntuple", when="@:0.16", msg="rntuple support requires at least podio@0.17") + # See https://github.com/AIDASoft/podio/pull/599 that landed after 0.99 + extends("python", when="@1.0:") + def cmake_args(self): args = [ self.define_from_variant("ENABLE_SIO", "sio"), @@ -191,19 +112,23 @@ def cmake_args(self): return args def setup_run_environment(self, env): - env.prepend_path("PYTHONPATH", self.prefix.python) + if self.spec.satisfies("@:0.99"): + # After 0.99 podio installs its python bindings into a more standard place + env.prepend_path("PYTHONPATH", self.prefix.python) + env.prepend_path("LD_LIBRARY_PATH", self.spec["podio"].libs.directories[0]) - if "+sio" in self.spec and self.version >= Version("0.16"): + if "+sio" in self.spec: # sio needs to be on LD_LIBRARY_PATH for ROOT to be able to # dynamicaly load the python bindings library env.prepend_path("LD_LIBRARY_PATH", self.spec["sio"].libs.directories[0]) - if self.spec.satisfies("@0.16.1:"): - # Frame header needs to be available for python bindings - env.prepend_path("ROOT_INCLUDE_PATH", self.prefix.include) + # Frame header needs to be available for python bindings + env.prepend_path("ROOT_INCLUDE_PATH", self.prefix.include) def setup_dependent_build_environment(self, env, dependent_spec): - env.prepend_path("PYTHONPATH", self.prefix.python) + if self.spec.satisfies("@:0.99"): + env.prepend_path("PYTHONPATH", self.prefix.python) + env.prepend_path("LD_LIBRARY_PATH", self.spec["podio"].libs.directories[0]) env.prepend_path("ROOT_INCLUDE_PATH", self.prefix.include) if self.spec.satisfies("+sio @0.17:"): diff --git a/var/spack/repos/builtin/packages/podio/python-tests.patch b/var/spack/repos/builtin/packages/podio/python-tests.patch deleted file mode 100644 index 06d14c6e61a711..00000000000000 --- a/var/spack/repos/builtin/packages/podio/python-tests.patch +++ /dev/null @@ -1,12 +0,0 @@ -index 5b6e13e..ac9ccf5 100644 ---- a/tests/CMakeLists.txt -+++ b/tests/CMakeLists.txt -@@ -106,7 +106,7 @@ endif() - add_test( NAME pyunittest COMMAND python -m unittest discover -s ${CMAKE_SOURCE_DIR}/python) - set_property(TEST pyunittest - PROPERTY ENVIRONMENT -- LD_LIBRARY_PATH=${CMAKE_CURRENT_BINARY_DIR}:${CMAKE_BINARY_DIR}/src:$ENV{LD_LIBRARY_PATH} -+ LD_LIBRARY_PATH=${CMAKE_CURRENT_BINARY_DIR}:${CMAKE_BINARY_DIR}/src:$ - PYTHONPATH=${CMAKE_SOURCE_DIR}/python:$ENV{PYTHONPATH} - ROOT_INCLUDE_PATH=${CMAKE_SOURCE_DIR}/tests/datamodel:${ROOT_INCLUDE_PATH}) - set_property(TEST pyunittest PROPERTY DEPENDS write) diff --git a/var/spack/repos/builtin/packages/podman/package.py b/var/spack/repos/builtin/packages/podman/package.py index bbc739a3627657..1d39221de54a20 100644 --- a/var/spack/repos/builtin/packages/podman/package.py +++ b/var/spack/repos/builtin/packages/podman/package.py @@ -20,6 +20,8 @@ class Podman(Package): version("3.4.7", sha256="4af6606dd072fe946960680611ba65201be435b43edbfc5cc635b2a01a899e6e") version("3.4.2", sha256="b0c4f9a11eb500b1d440d5e51a6c0c632aa4ac458e2dc0362f50f999eb7fbf31") + depends_on("c", type="build") # generated + # See for the # respective issue and the suggested patch # issue was fixed as of 4.4.0 diff --git a/var/spack/repos/builtin/packages/poke/package.py b/var/spack/repos/builtin/packages/poke/package.py index f9e24428ea2676..a3dbde71a1de4d 100644 --- a/var/spack/repos/builtin/packages/poke/package.py +++ b/var/spack/repos/builtin/packages/poke/package.py @@ -21,6 +21,8 @@ class Poke(AutotoolsPackage, GNUMirrorPackage): version("3.0", sha256="79a9b2f33c9f8c327c499afadaeeabfeecf6ad4988924d2c6c6f317e50317add") version("1.0", sha256="de930b8700c0772b3c2cd0d0ca35f50fd3d77bdf82c6251eb516b49e8ca25b0a") + depends_on("c", type="build") # generated + depends_on("pkgconfig") depends_on("readline") depends_on("bdw-gc") diff --git a/var/spack/repos/builtin/packages/polymake/package.py b/var/spack/repos/builtin/packages/polymake/package.py index 8fe14258749b3f..c8933eace7291f 100644 --- a/var/spack/repos/builtin/packages/polymake/package.py +++ b/var/spack/repos/builtin/packages/polymake/package.py @@ -18,6 +18,10 @@ class Polymake(Package): version("3.0r2", sha256="e7c0f8e3a45ea288d2fb4ae781a1dcea913ef9c275fed401632cdb11a672d6dc") version("3.0r1", sha256="cdc223716b1cc3f4f3cc126089a438f9d12390caeed78291a87565717c7b504d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Note: Could also be built with nauty instead of bliss depends_on("bliss") diff --git a/var/spack/repos/builtin/packages/poorjit/package.py b/var/spack/repos/builtin/packages/poorjit/package.py new file mode 100755 index 00000000000000..ac03c796765c23 --- /dev/null +++ b/var/spack/repos/builtin/packages/poorjit/package.py @@ -0,0 +1,30 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Poorjit(CMakePackage): + """A poorman's JIT library""" + + homepage = "https://github.com/robertu94/poorjit" + url = "https://github.com/robertu94/poorjit/archive/refs/tags/0.0.2.tar.gz" + git = "https://github.com/robertu94/poorjit" + + maintainers("robertu94") + + license("BSD-4-Clause", checked_by="robertu94") + + version("0.0.2", sha256="d7d43ba3b343ac8a6b0fb4928d5882f64a8c13c6fccfc37e1a3f3cd581c2739a") + + depends_on("cxx", type="build") # generated + + depends_on("boost+filesystem") + depends_on("zlib") + depends_on("fmt") + + def cmake_args(self): + args = [] + return args diff --git a/var/spack/repos/builtin/packages/poppler/package.py b/var/spack/repos/builtin/packages/poppler/package.py index b71c5b30ff54fc..a3b4d5efbdf5e0 100644 --- a/var/spack/repos/builtin/packages/poppler/package.py +++ b/var/spack/repos/builtin/packages/poppler/package.py @@ -29,6 +29,9 @@ class Poppler(CMakePackage): version("0.64.0", sha256="b21df92ca99f78067785cf2dc8e06deb04726b62389c0ee1f5d8b103c77f64b1") version("0.61.1", sha256="1266096343f5163c1a585124e9a6d44474e1345de5cdfe55dc7b47357bcfcda9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("boost", default=False, description="Enable Boost for Splash") variant("cms", default=False, description="Use color management system") variant("cpp", default=False, description="Compile poppler cpp wrapper") diff --git a/var/spack/repos/builtin/packages/popt/package.py b/var/spack/repos/builtin/packages/popt/package.py index 75cd3a348d4229..037a0edd3c2677 100644 --- a/var/spack/repos/builtin/packages/popt/package.py +++ b/var/spack/repos/builtin/packages/popt/package.py @@ -16,6 +16,8 @@ class Popt(AutotoolsPackage): version("1.16", sha256="e728ed296fe9f069a0e005003c3d6b2dde3d9cad453422a10d6558616d304cc8") + depends_on("c", type="build") # generated + depends_on("iconv") def patch(self): diff --git a/var/spack/repos/builtin/packages/portage/package.py b/var/spack/repos/builtin/packages/portage/package.py index f4108565580a26..971ee1388e0ad4 100644 --- a/var/spack/repos/builtin/packages/portage/package.py +++ b/var/spack/repos/builtin/packages/portage/package.py @@ -23,6 +23,8 @@ class Portage(CMakePackage): version("3.0.0", sha256="7a5a21ffbc35fa54a5136d937cfda6f836c7496ff2b5adf54deb4107501333da") version("master", branch="master", submodules=True) + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Support MPI") variant("tangram", default=False, description="Use Tangram interface reconstruction package") variant("jali", default=False, description="Include support for Jali mesh framework") diff --git a/var/spack/repos/builtin/packages/portcullis/package.py b/var/spack/repos/builtin/packages/portcullis/package.py index 7944a6ea355ca2..95df2d493ae665 100644 --- a/var/spack/repos/builtin/packages/portcullis/package.py +++ b/var/spack/repos/builtin/packages/portcullis/package.py @@ -18,6 +18,9 @@ class Portcullis(AutotoolsPackage): version("1.2.3", sha256="172452b5cef12a8dcc2c1c68527000743114136ee63a0dbe307ac4e2a816bc99") version("1.1.2", sha256="5c581a7f827ffeecfe68107b7fe27ed60108325fd2f86a79d93f61b328687749") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf@2.53:", type="build") depends_on("automake@1.11:", type="build") depends_on("libtool@2.4.2:", type="build") diff --git a/var/spack/repos/builtin/packages/ports-of-call/package.py b/var/spack/repos/builtin/packages/ports-of-call/package.py index 699f4007ccf2e4..d0ad83b84a4909 100644 --- a/var/spack/repos/builtin/packages/ports-of-call/package.py +++ b/var/spack/repos/builtin/packages/ports-of-call/package.py @@ -34,6 +34,8 @@ class PortsOfCall(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + variant( "portability_strategy", description="Portability strategy backend", diff --git a/var/spack/repos/builtin/packages/postgis/package.py b/var/spack/repos/builtin/packages/postgis/package.py index 5fe76b8889d2cc..5bc68169291e5b 100644 --- a/var/spack/repos/builtin/packages/postgis/package.py +++ b/var/spack/repos/builtin/packages/postgis/package.py @@ -22,6 +22,9 @@ class Postgis(AutotoolsPackage): version("3.0.0", sha256="c06fd2cd5cea0119106ffe17a7235d893c2bbe6f4b63c8617c767630973ba594") version("2.5.3", sha256="72e8269d40f981e22fb2b78d3ff292338e69a4f5166e481a77b015e1d34e559a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "gui", default=False, diff --git a/var/spack/repos/builtin/packages/postgresql/package.py b/var/spack/repos/builtin/packages/postgresql/package.py index fc13e3e1d521f0..dfe9d05de917ed 100644 --- a/var/spack/repos/builtin/packages/postgresql/package.py +++ b/var/spack/repos/builtin/packages/postgresql/package.py @@ -21,6 +21,7 @@ class Postgresql(AutotoolsPackage): license("PostgreSQL") + version("16.3", sha256="331963d5d3dc4caf4216a049fa40b66d6bcb8c730615859411b9518764e60585") version("15.2", sha256="99a2171fc3d6b5b5f56b757a7a3cb85d509a38e4273805def23941ed2b8468c7") version("14.0", sha256="ee2ad79126a7375e9102c4db77c4acae6ae6ffe3e082403b88826d96d927a122") version("13.1", sha256="12345c83b89aa29808568977f5200d6da00f88a035517f925293355432ffe61f") @@ -41,6 +42,9 @@ class Postgresql(AutotoolsPackage): version("9.5.3", sha256="7385c01dc58acba8d7ac4e6ad42782bd7c0b59272862a3a3d5fe378d4503a0b4") version("9.3.4", sha256="9ee819574dfc8798a448dc23a99510d2d8924c2f8b49f8228cd77e4efc8a6621") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("client_only", default=False, description="Build and install client only.") variant("threadsafe", default=False, description="Build with thread safe.") variant( @@ -69,37 +73,35 @@ def command(self): return Executable(self.prefix.bin.pg_config) def configure_args(self): - config_args = ["--with-openssl"] + spec = self.spec + args = ["--with-openssl"] - if "+threadsafe" in self.spec: - config_args.append("--enable-thread-safety") - else: - config_args.append("--disable-thread-safety") + args.extend(self.enable_or_disable("thread-safety", variant="threadsafe")) - if self.spec.variants["lineedit"].value == "libedit": - config_args.append("--with-libedit-preferred") - elif self.spec.variants["lineedit"].value == "none": - config_args.append("--without-readline") + if spec.variants["lineedit"].value == "libedit": + args.append("--with-libedit-preferred") + elif spec.variants["lineedit"].value == "none": + args.append("--without-readline") - if "+gssapi" in self.spec: - config_args.append("--with-gssapi") + if spec.satisfies("+gssapi"): + args.append("--with-gssapi") - if "+python" in self.spec: - config_args.append("--with-python") + if spec.satisfies("+python"): + args.append("--with-python") - if "+perl" in self.spec: - config_args.append("--with-perl") + if spec.satisfies("+perl"): + args.append("--with-perl") - if "+tcl" in self.spec: - config_args.append("--with-tcl") + if spec.satisfies("+tcl"): + args.append("--with-tcl") - if "+xml" in self.spec: - config_args.append("--with-libxml") + if spec.satisfies("+xml"): + args.append("--with-libxml") - return config_args + return args def install(self, spec, prefix): - if "+client_only" in self.spec: + if spec.satisfies("+client_only"): for subdir in ("bin", "include", "interfaces", "pl"): with working_dir(os.path.join("src", subdir)): make("install") @@ -109,31 +111,31 @@ def install(self, spec, prefix): def setup_run_environment(self, env): spec = self.spec - if "+perl" in spec: + if spec.satisfies("+perl"): env.prepend_path("PERL5LIB", self.prefix.lib) - if "+tcl" in spec: + if spec.satisfies("+tcl"): env.prepend_path("TCLLIBPATH", self.prefix.lib) - if "+python" in spec: + if spec.satisfies("+python"): env.prepend_path("PYTHONPATH", self.prefix.lib) def setup_dependent_build_environment(self, env, dependent_spec): spec = self.spec - if "+perl" in spec: + if spec.satisfies("+perl"): env.prepend_path("PERL5LIB", self.prefix.lib) - if "+tcl" in spec: + if spec.satisfies("+tcp"): env.prepend_path("TCLLIBPATH", self.prefix.lib) - if "+python" in spec: + if spec.satisfies("+python"): env.prepend_path("PYTHONPATH", self.prefix.lib) def setup_dependent_run_environment(self, env, dependent_spec): spec = self.spec - if "+perl" in spec: + if spec.satisfies("+perl"): env.prepend_path("PERL5LIB", self.prefix.lib) - if "+tcl" in spec: + if spec.satisfies("+tcl"): env.prepend_path("TCLLIBPATH", self.prefix.lib) - if "+python" in spec: + if spec.satisfies("+python"): env.prepend_path("PYTHONPATH", self.prefix.lib) @property diff --git a/var/spack/repos/builtin/packages/povray/package.py b/var/spack/repos/builtin/packages/povray/package.py index d77bafd9d5cf9e..51a8832e2b6bf2 100644 --- a/var/spack/repos/builtin/packages/povray/package.py +++ b/var/spack/repos/builtin/packages/povray/package.py @@ -34,6 +34,9 @@ class Povray(AutotoolsPackage): version("3.7.0.8", sha256="53d11ebd2972fc452af168a00eb83aefb61387662c10784e81b63e44aa575de4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("boost", default=True, description="Build with boost support") variant("debug", default=False, description="Enable compiler debugging mode") variant( diff --git a/var/spack/repos/builtin/packages/powerapi/package.py b/var/spack/repos/builtin/packages/powerapi/package.py index 9943a94d5a3d39..02bc31c81eac34 100644 --- a/var/spack/repos/builtin/packages/powerapi/package.py +++ b/var/spack/repos/builtin/packages/powerapi/package.py @@ -16,6 +16,9 @@ class Powerapi(AutotoolsPackage): version("2020-01-30", commit="21f75b1469261d99e604f7ddc18f30513ebdd048") version("1.1.1", commit="93f66dfa29f014067823f2b790a1862e5841a11c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("hwloc", default=False, description="Build hwloc support") variant("debug", default=False, description="Enable debug support") variant("mpi", default=False, description="Enable MPI support") diff --git a/var/spack/repos/builtin/packages/ppl/package.py b/var/spack/repos/builtin/packages/ppl/package.py index c0c918b11c90f6..72cc2a26a63d2f 100644 --- a/var/spack/repos/builtin/packages/ppl/package.py +++ b/var/spack/repos/builtin/packages/ppl/package.py @@ -28,6 +28,9 @@ class Ppl(Package): version("1.2", sha256="6bc36dd4a87abc429d8f9c00c53e334e5041a9b0857cfc00dbad6ef14294aac8") version("1.1", sha256="46f073c0626234f0b1a479356c0022fe5dc3c9cf10df1a246c9cde81f7cf284d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gmp") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/ppopen-appl-amr-fdm/package.py b/var/spack/repos/builtin/packages/ppopen-appl-amr-fdm/package.py index 17000ee5ba5064..1ce03db9af11c7 100644 --- a/var/spack/repos/builtin/packages/ppopen-appl-amr-fdm/package.py +++ b/var/spack/repos/builtin/packages/ppopen-appl-amr-fdm/package.py @@ -18,6 +18,8 @@ class PpopenApplAmrFdm(MakefilePackage): version("master", branch="APPL/FDM_AMR") + depends_on("fortran", type="build") # generated + depends_on("mpi") parallel = False diff --git a/var/spack/repos/builtin/packages/ppopen-appl-bem-at/package.py b/var/spack/repos/builtin/packages/ppopen-appl-bem-at/package.py index 5fae5b5269dc24..ebeac298347541 100644 --- a/var/spack/repos/builtin/packages/ppopen-appl-bem-at/package.py +++ b/var/spack/repos/builtin/packages/ppopen-appl-bem-at/package.py @@ -17,6 +17,8 @@ class PpopenApplBemAt(MakefilePackage): git = "https://github.com/Post-Peta-Crest/ppOpenHPC.git" version("master", branch="ATA/BEM") + + depends_on("fortran", type="build") # generated # In OAT_bem-bb-fw-dense-0.1.0.f90 the 2 variables are defined. # But ame variables are already defined in include file DAT.h. # This patch is deleted the variables definitions diff --git a/var/spack/repos/builtin/packages/ppopen-appl-bem/package.py b/var/spack/repos/builtin/packages/ppopen-appl-bem/package.py index 20e2d01f6c6dda..6d26c656c6127b 100644 --- a/var/spack/repos/builtin/packages/ppopen-appl-bem/package.py +++ b/var/spack/repos/builtin/packages/ppopen-appl-bem/package.py @@ -26,6 +26,8 @@ class PpopenApplBem(MakefilePackage): version("master", branch="APPL/BEM") + depends_on("fortran", type="build") # generated + depends_on("mpi") parallel = False diff --git a/var/spack/repos/builtin/packages/ppopen-appl-dem-util/package.py b/var/spack/repos/builtin/packages/ppopen-appl-dem-util/package.py index afe2c21e92ff1c..235f3c308d187f 100644 --- a/var/spack/repos/builtin/packages/ppopen-appl-dem-util/package.py +++ b/var/spack/repos/builtin/packages/ppopen-appl-dem-util/package.py @@ -22,6 +22,8 @@ class PpopenApplDemUtil(MakefilePackage): version("master", branch="APPL/DEM") + depends_on("fortran", type="build") # generated + depends_on("mpi") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/ppopen-appl-fdm-at/package.py b/var/spack/repos/builtin/packages/ppopen-appl-fdm-at/package.py index a61f9c9de897f3..2c35211ecb7a45 100644 --- a/var/spack/repos/builtin/packages/ppopen-appl-fdm-at/package.py +++ b/var/spack/repos/builtin/packages/ppopen-appl-fdm-at/package.py @@ -14,6 +14,8 @@ class PpopenApplFdmAt(MakefilePackage): version("master", branch="ATA/FDM") + depends_on("fortran", type="build") # generated + depends_on("mpi") # depends_on('ppopen-appl-fdm', type='build') diff --git a/var/spack/repos/builtin/packages/ppopen-appl-fdm/package.py b/var/spack/repos/builtin/packages/ppopen-appl-fdm/package.py index c9aa471a1d56dc..7199b196882620 100644 --- a/var/spack/repos/builtin/packages/ppopen-appl-fdm/package.py +++ b/var/spack/repos/builtin/packages/ppopen-appl-fdm/package.py @@ -19,6 +19,10 @@ class PpopenApplFdm(MakefilePackage): version("master", branch="APPL/FDM") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # remove unused variable definition patch("unused.patch") # remove iargc external definition diff --git a/var/spack/repos/builtin/packages/ppopen-appl-fem/package.py b/var/spack/repos/builtin/packages/ppopen-appl-fem/package.py index 2286b3f5cc50b7..a1036df34794d8 100644 --- a/var/spack/repos/builtin/packages/ppopen-appl-fem/package.py +++ b/var/spack/repos/builtin/packages/ppopen-appl-fem/package.py @@ -21,6 +21,9 @@ class PpopenApplFem(MakefilePackage): version("master", branch="APPL/FEM") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("metis") diff --git a/var/spack/repos/builtin/packages/ppopen-appl-fvm/package.py b/var/spack/repos/builtin/packages/ppopen-appl-fvm/package.py index 903254e683d556..9637d6b265c880 100644 --- a/var/spack/repos/builtin/packages/ppopen-appl-fvm/package.py +++ b/var/spack/repos/builtin/packages/ppopen-appl-fvm/package.py @@ -32,6 +32,8 @@ class PpopenApplFvm(MakefilePackage): version("master", branch="APPL/FVM") + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("metis@:4") diff --git a/var/spack/repos/builtin/packages/ppopen-at/package.py b/var/spack/repos/builtin/packages/ppopen-at/package.py index 685d3ba3766630..cce600e0ef490d 100644 --- a/var/spack/repos/builtin/packages/ppopen-at/package.py +++ b/var/spack/repos/builtin/packages/ppopen-at/package.py @@ -17,6 +17,10 @@ class PpopenAt(MakefilePackage): version("master", branch="AT") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + def edit(self, spec, prefix): makefile_in = FileFilter("Makefile.in") makefile_in.filter("gcc", spack_cxx) diff --git a/var/spack/repos/builtin/packages/ppopen-math-mp/package.py b/var/spack/repos/builtin/packages/ppopen-math-mp/package.py index 5f7e964d12e4f4..dbe294a81588de 100644 --- a/var/spack/repos/builtin/packages/ppopen-math-mp/package.py +++ b/var/spack/repos/builtin/packages/ppopen-math-mp/package.py @@ -29,6 +29,8 @@ class PpopenMathMp(MakefilePackage): version("master", branch="MATH/MP") + depends_on("fortran", type="build") # generated + depends_on("mpi") build_directory = "src" diff --git a/var/spack/repos/builtin/packages/ppopen-math-vis/package.py b/var/spack/repos/builtin/packages/ppopen-math-vis/package.py index c9ff21b6660b0e..eb32035682de04 100644 --- a/var/spack/repos/builtin/packages/ppopen-math-vis/package.py +++ b/var/spack/repos/builtin/packages/ppopen-math-vis/package.py @@ -26,6 +26,9 @@ class PpopenMathVis(MakefilePackage): version("master", branch="MATH/VIS") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/prank/package.py b/var/spack/repos/builtin/packages/prank/package.py index a04576cb487994..2a1c8376679671 100644 --- a/var/spack/repos/builtin/packages/prank/package.py +++ b/var/spack/repos/builtin/packages/prank/package.py @@ -14,6 +14,8 @@ class Prank(Package): version("170427", sha256="623eb5e9b5cb0be1f49c3bf715e5fabceb1059b21168437264bdcd5c587a8859") + depends_on("cxx", type="build") # generated + depends_on("mafft") depends_on("exonerate") depends_on("bpp-suite") # for bppancestor diff --git a/var/spack/repos/builtin/packages/precice/package.py b/var/spack/repos/builtin/packages/precice/package.py index 2c4ea936e39dd7..2c1db9878fd8d5 100644 --- a/var/spack/repos/builtin/packages/precice/package.py +++ b/var/spack/repos/builtin/packages/precice/package.py @@ -23,6 +23,9 @@ class Precice(CMakePackage): license("LGPL-3.0-or-later") version("develop", branch="develop") + version("3.1.2", sha256="e06d5e183f584c51812dcddf958210d1195bea38fa2df13be72303dcb06c869b") + version("3.1.1", sha256="fe759293942ebc9cb2e6127f356a8c795ab7383c1b074595994ebc92466e478d") + version("3.1.0", sha256="11e7d3d4055ee30852c0e83692ca7563acaa095bd223ebdbd5c8c851b3646d37") version("3.0.0", sha256="efe6cf505d9305af89c6da1fdba246199a75a1c63a6a22103773ed95341879ba") version("2.5.1", sha256="a5a37d3430eac395e885eb9cbbed9d0980a15e96c3e44763a3769fa7301e3b3a") version("2.5.0", sha256="76ec6ee0d1a66f6f3d3d2d11f03cfc5aa7ef4d9e5deb9b7a4b4455ec7f796c00") @@ -44,6 +47,10 @@ class Precice(CMakePackage): version("1.4.0", sha256="3499bfc0941fb9f004d5e32eb63d64f93e17b4057fab3ada1cde40c8311bd466") version("1.3.0", sha256="610322ba1b03df8e8f7d060d57a6a5afeabd5db4e8c4a638d04ba4060a3aec96") version("1.2.0", sha256="0784ecd002092949835151b90393beb6e9e7a3e9bd78ffd40d18302d6da4b05b") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated # Skip version 1.1.1 entirely, the cmake was lacking install. variant("mpi", default=True, description="Enable MPI support") @@ -68,16 +75,19 @@ class Precice(CMakePackage): depends_on("cmake@3.5:", type="build") depends_on("cmake@3.10.2:", type="build", when="@1.4:") depends_on("cmake@3.16.3:", type="build", when="@2.4:") + depends_on("cmake@3.22.1:", type="build", when="@3.2:") depends_on("pkgconfig", type="build", when="@2.2:") # Boost components - depends_on("boost+filesystem+log+program_options+system+test+thread") + depends_on("boost+log+program_options+system+test+thread") + depends_on("boost+filesystem", when="@:3.0.0") depends_on("boost+signals", when="@:2.3") # Baseline versions depends_on("boost@1.60.0:") depends_on("boost@1.65.1:", when="@1.4:") depends_on("boost@1.71.0:", when="@2.4:") + depends_on("boost@1.74.0:", when="@3.2:") # Forward compatibility depends_on("boost@:1.72", when="@:2.0.2") @@ -85,15 +95,21 @@ class Precice(CMakePackage): depends_on("boost@:1.78", when="@:2.3.0") depends_on("eigen@3.2:") + depends_on("eigen@3.4:", when="@3.2:") depends_on("eigen@:3.3.7", type="build", when="@:1.5") # bug in prettyprint + depends_on("libxml2") depends_on("libxml2@:2.11.99", type="build", when="@:2.5.0") + depends_on("mpi", when="+mpi") + depends_on("petsc@3.6:", when="+petsc") depends_on("petsc@3.12:", when="+petsc@2.1.0:") + depends_on("petsc@3.15:", when="+petsc@3.2:") depends_on("python@3:", when="+python", type=("build", "run")) depends_on("py-numpy@1.17:", when="+python", type=("build", "run")) + depends_on("py-numpy@1.21.5:", when="+python@3.2:", type=("build", "run")) # We require C++14 compiler support conflicts("%gcc@:4") @@ -180,7 +196,7 @@ def cmake_args(self): python_library = spec["python"].libs[0] python_include = spec["python"].headers.directories[0] numpy_include = join_path( - spec["py-numpy"].prefix, spec["python"].package.platlib, "numpy", "core", "include" + spec["py-numpy"].package.module.python_platlib, "numpy", "core", "include" ) cmake_args.extend( [ diff --git a/var/spack/repos/builtin/packages/predixy/package.py b/var/spack/repos/builtin/packages/predixy/package.py index 4b62b48698dee8..6a9bb0a605ece1 100644 --- a/var/spack/repos/builtin/packages/predixy/package.py +++ b/var/spack/repos/builtin/packages/predixy/package.py @@ -15,10 +15,13 @@ class Predixy(MakefilePackage): license("BSD-3-Clause") + # Predixy is no longer open source starting with @7: releases. version("1.0.5", sha256="0670d0b80f991b415a6dc6df107e5f223e3b41dc5d6b18bf73e26578178dd9e0") version("1.0.4", sha256="30a7dd44ce507a7a2f8a570c59c9133df239a7f8bad14ef1b97df92b2ee96d40") version("1.0.3", sha256="d815d0ffcd33b16bfee76fe5523bdd47cf9acca0419eaa284d5ccda4cf62b828") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(self.prefix.bin) install("src/predixy", self.prefix.bin) diff --git a/var/spack/repos/builtin/packages/premake-core/package.py b/var/spack/repos/builtin/packages/premake-core/package.py index 6bd9c53ba9b33b..c072adba3caf46 100644 --- a/var/spack/repos/builtin/packages/premake-core/package.py +++ b/var/spack/repos/builtin/packages/premake-core/package.py @@ -28,6 +28,9 @@ class PremakeCore(MakefilePackage): "5.0.0-alpha13", sha256="bfe983e24686c50cada935f74adad2aefe6581649734b2ab8c1aaa2de4d473c6" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def build(self, spec, prefix): make("-f", "Bootstrap.mak", self.architecture.platform.name) diff --git a/var/spack/repos/builtin/packages/preseq/package.py b/var/spack/repos/builtin/packages/preseq/package.py index 60a6dd20bd6157..811e262cf96900 100644 --- a/var/spack/repos/builtin/packages/preseq/package.py +++ b/var/spack/repos/builtin/packages/preseq/package.py @@ -21,6 +21,9 @@ class Preseq(MakefilePackage): version("2.0.3", sha256="747ddd4227515a96a45fcff0709f26130386bff3458c829c7bc1f3306b4f3d91") version("2.0.2", sha256="1d7ea249bf4e5826e09697256643e6a2473bc302cd455f31d4eb34c23c10b97c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("samtools") depends_on("gsl") diff --git a/var/spack/repos/builtin/packages/prettier/package.py b/var/spack/repos/builtin/packages/prettier/package.py new file mode 100644 index 00000000000000..bb71668d7bd333 --- /dev/null +++ b/var/spack/repos/builtin/packages/prettier/package.py @@ -0,0 +1,25 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Prettier(Package): + """Prettier is an opinionated code formatter.""" + + homepage = "https://prettier.io/" + url = "https://github.com/prettier/prettier/archive/refs/tags/3.2.5.tar.gz" + + maintainers("adamjstewart") + license("MIT") + + version("3.2.5", sha256="0ac58fbe50859feb06099670526460cef7f51c83fee458b02fc67e53ffd23f57") + + depends_on("node-js", type=("build", "run")) + depends_on("npm", type="build") + + def install(self, spec, prefix): + npm = which("npm", required=True) + npm("install", "--global", f"--prefix={prefix}") diff --git a/var/spack/repos/builtin/packages/price/package.py b/var/spack/repos/builtin/packages/price/package.py index 80941a12800fbb..248a3bd74439c1 100644 --- a/var/spack/repos/builtin/packages/price/package.py +++ b/var/spack/repos/builtin/packages/price/package.py @@ -15,6 +15,8 @@ class Price(MakefilePackage): version("140408", sha256="12276b2b15f4e020a772944a19fd2aaf089d3437cbc71e7486fa8db95014843f") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("PriceTI", prefix.bin) diff --git a/var/spack/repos/builtin/packages/primer3/package.py b/var/spack/repos/builtin/packages/primer3/package.py index 8bee8d75294a98..c763db1555ae73 100644 --- a/var/spack/repos/builtin/packages/primer3/package.py +++ b/var/spack/repos/builtin/packages/primer3/package.py @@ -21,6 +21,10 @@ class Primer3(MakefilePackage): version("2.5.0", sha256="7581e2fa3228ef0ee1ffa427b2aa0a18fc635d561208327471daf59d1b804da0") version("2.3.7", sha256="f7ac3e64dc89b7c80882bf0f52c2c0a58572f5fdafd178680d4a7ae91b6c465b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + build_directory = "src" # Prior to May 15, 2018, the code contained invalid pointer/int diff --git a/var/spack/repos/builtin/packages/prism/package.py b/var/spack/repos/builtin/packages/prism/package.py index 080e387c9b26b8..ffa2b155f2e400 100644 --- a/var/spack/repos/builtin/packages/prism/package.py +++ b/var/spack/repos/builtin/packages/prism/package.py @@ -20,6 +20,9 @@ class Prism(MakefilePackage): version("4.7", sha256="16186047ba49efc6532de6e9c3993c8c73841a7c76c99758d6ee769e72092d6d") version("4.5", sha256="1cb7a77538b5c997d98a8c209030c46f9e8f021f7a8332e5eb2fd3b4a23936fd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_directory = "prism" depends_on("java@9:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/prmon/package.py b/var/spack/repos/builtin/packages/prmon/package.py index c194c1d975a25e..179a2a74a1abbb 100644 --- a/var/spack/repos/builtin/packages/prmon/package.py +++ b/var/spack/repos/builtin/packages/prmon/package.py @@ -19,6 +19,7 @@ class Prmon(CMakePackage): license("Apache-2.0") version("main", branch="main") + version("3.1.0", sha256="02f25f1ea82300c93e5af14137e366b31c8d615283768d5f3f98616a0d6e507c") version("3.0.2", sha256="ea9ff521689fecb8c395e35e9540be18c7ab37812354c4a5c0ba505e2ab467c1") version("3.0.0", sha256="fd6f4e3a95e055d265fbbaba08d680826cb4770eb8830cc987898d6504ac7474") version("2.2.1", sha256="7c95538a0ddcfc71b5c581979a5bb298873fdf16966fd6951aaa2b2639b08319") diff --git a/var/spack/repos/builtin/packages/prng/package.py b/var/spack/repos/builtin/packages/prng/package.py index b3d039283f69f2..5bba9faa042df6 100644 --- a/var/spack/repos/builtin/packages/prng/package.py +++ b/var/spack/repos/builtin/packages/prng/package.py @@ -16,6 +16,8 @@ class Prng(AutotoolsPackage): version("3.0.2", sha256="8299182b97c24b7891d74590a8a8438641a6c681ce34d6c3f7bc98a0649da48b") + depends_on("c", type="build") # generated + depends_on("automake", type="build") depends_on("autoconf", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/probconsrna/package.py b/var/spack/repos/builtin/packages/probconsrna/package.py index 6353022a160fb0..c0231f5e47ae06 100644 --- a/var/spack/repos/builtin/packages/probconsrna/package.py +++ b/var/spack/repos/builtin/packages/probconsrna/package.py @@ -15,6 +15,8 @@ class Probconsrna(Package): version("2005-6-7", sha256="7fe4494bd423db1d5f33f5ece2c70f9f66a0d9112e28d3eaa7dfdfe7fa66eba8") + depends_on("cxx", type="build") # generated + def install(self, build, prefix): mkdirp(prefix.bin) install("compare", prefix.bin) diff --git a/var/spack/repos/builtin/packages/procenv/package.py b/var/spack/repos/builtin/packages/procenv/package.py index b4be9e38627669..6df01c967def7c 100644 --- a/var/spack/repos/builtin/packages/procenv/package.py +++ b/var/spack/repos/builtin/packages/procenv/package.py @@ -20,6 +20,8 @@ class Procenv(AutotoolsPackage): version("0.60", sha256="fac0438bf08ed73b10ace78d85acb83cf81ade5ecf866762c2c6e92e41dbde43") version("0.51", sha256="b831c14729e06a285cc13eba095817ce3b6d0ddf484b1264951b03ee4fe25bc9") + depends_on("c", type="build") # generated + # https://github.com/jamesodhunt/procenv/pull/16 patch("7cafed1316ddb16fe0689d54ba10c05dd2edd347.patch", when="@:0.51") diff --git a/var/spack/repos/builtin/packages/process-in-process/package.py b/var/spack/repos/builtin/packages/process-in-process/package.py index 283fd52064091a..e2775ea78fc1b3 100644 --- a/var/spack/repos/builtin/packages/process-in-process/package.py +++ b/var/spack/repos/builtin/packages/process-in-process/package.py @@ -31,6 +31,8 @@ class ProcessInProcess(Package): # PiP version 3 is experimental and unstable yet version("3", branch="pip-3", deprecated=True) + depends_on("c", type="build") # generated + conflicts("%gcc@:3", when="os=centos7") conflicts("%gcc@5:", when="os=centos7") conflicts("%gcc@:3", when="os=rhel7") diff --git a/var/spack/repos/builtin/packages/procps-ng/package.py b/var/spack/repos/builtin/packages/procps-ng/package.py index e66376242f7a91..e66eb53b17b429 100644 --- a/var/spack/repos/builtin/packages/procps-ng/package.py +++ b/var/spack/repos/builtin/packages/procps-ng/package.py @@ -16,5 +16,7 @@ class ProcpsNg(AutotoolsPackage): version("3.3.16", sha256="925eacd65dedcf9c98eb94e8978bbfb63f5de37294cc1047d81462ed477a20af") + depends_on("c", type="build") # generated + def setup_run_environment(self, env): env.prepend_path("PATH", self.prefix.sbin) diff --git a/var/spack/repos/builtin/packages/procps/package.py b/var/spack/repos/builtin/packages/procps/package.py index bfb0432488cdf1..55ee0c554be9fe 100644 --- a/var/spack/repos/builtin/packages/procps/package.py +++ b/var/spack/repos/builtin/packages/procps/package.py @@ -29,6 +29,8 @@ class Procps(AutotoolsPackage): version("3.3.15", sha256="14dfa751517dd844efa9f492e3ad8071f908a269c6aea643b9a1759235fa2053") version("3.3.14", sha256="1ff716e7bde6b3841b8519831690b10b644ed344490369c55e410edc8db2fe18") + depends_on("c", type="build") # generated + variant("nls", default=True, description="Enable Native Language Support.") depends_on("autoconf", type="build") @@ -70,9 +72,9 @@ def configure_args(self): else: args.append("--disable-nls") - if spec["iconv"].name == "libc": + if spec["iconv"].name == "libiconv": + args.append(f"--with-libiconv-prefix={spec['iconv'].prefix}") + else: args.append("--without-libiconv-prefix") - elif not is_system_path(spec["iconv"].prefix): - args.append("--with-libiconv-prefix={0}".format(spec["iconv"].prefix)) return args diff --git a/var/spack/repos/builtin/packages/prod-util/package.py b/var/spack/repos/builtin/packages/prod-util/package.py index aa2ee1d528c040..45781b303c11ac 100644 --- a/var/spack/repos/builtin/packages/prod-util/package.py +++ b/var/spack/repos/builtin/packages/prod-util/package.py @@ -14,9 +14,25 @@ class ProdUtil(CMakePackage): homepage = "https://github.com/NOAA-EMC/NCEPLIBS-prod_util" url = "https://github.com/NOAA-EMC/NCEPLIBS-prod_util/archive/refs/tags/v1.2.2.tar.gz" + git = "https://github.com/NOAA-EMC/NCEPLIBS-prod_util" maintainers("AlexanderRichert-NOAA", "Hang-Lei-NOAA", "edwardhartnett") - version("1.2.2", sha256="c51b903ea5a046cb9b545b5c04fd28647c58b4ab6182e61710f0287846350ef8") + version("develop", branch="develop") + version("2.1.1", sha256="2f7507fa378a44f42b971f60de8152387c311bfa9c5c05a274c87b43a143aacd") + version("2.1.0", sha256="fa7df4a82dae269ffb347b9007376fb0d9979c17c4974814ea82204b12d70ea5") + version( + "1.2.2", + sha256="c51b903ea5a046cb9b545b5c04fd28647c58b4ab6182e61710f0287846350ef8", + deprecated=True, + ) - depends_on("w3nco") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + + depends_on("w3nco", when="@1") + depends_on("w3emc", when="@2:") + + def check(self): + with working_dir(self.builder.build_directory): + make("test") diff --git a/var/spack/repos/builtin/packages/prodigal/package.py b/var/spack/repos/builtin/packages/prodigal/package.py index 1c670bd973077f..6d7693d10b6cac 100644 --- a/var/spack/repos/builtin/packages/prodigal/package.py +++ b/var/spack/repos/builtin/packages/prodigal/package.py @@ -17,6 +17,8 @@ class Prodigal(MakefilePackage): version("2.6.3", sha256="89094ad4bff5a8a8732d899f31cec350f5a4c27bcbdd12663f87c9d1f0ec599f") + depends_on("c", type="build") # generated + def install(self, spec, prefix): make("INSTALLDIR={0}".format(self.prefix), "install") diff --git a/var/spack/repos/builtin/packages/professor/package.py b/var/spack/repos/builtin/packages/professor/package.py index b021c7e9571345..7848bfcafb3d21 100644 --- a/var/spack/repos/builtin/packages/professor/package.py +++ b/var/spack/repos/builtin/packages/professor/package.py @@ -17,6 +17,8 @@ class Professor(Package): version("2.3.3", sha256="60c5ba00894c809e2c31018bccf22935a9e1f51c0184468efbdd5d27b211009f") + depends_on("cxx", type="build") # generated + variant( "interactive", default=True, diff --git a/var/spack/repos/builtin/packages/profugusmc/package.py b/var/spack/repos/builtin/packages/profugusmc/package.py index 18cc276502e44a..6347665a1a71a2 100644 --- a/var/spack/repos/builtin/packages/profugusmc/package.py +++ b/var/spack/repos/builtin/packages/profugusmc/package.py @@ -17,6 +17,10 @@ class Profugusmc(CMakePackage, CudaPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI") variant("cuda", default=False, description="Enable CUDA") diff --git a/var/spack/repos/builtin/packages/proj/package.py b/var/spack/repos/builtin/packages/proj/package.py index ef18d834dcb641..d9ed3ef11d8403 100644 --- a/var/spack/repos/builtin/packages/proj/package.py +++ b/var/spack/repos/builtin/packages/proj/package.py @@ -25,6 +25,10 @@ class Proj(CMakePackage, AutotoolsPackage): license("MIT") + version("9.4.1", sha256="ffe20170ee2b952207adf8a195e2141eab12cda181e49fdeb54425d98c7171d7") + version("9.4.0", sha256="3643b19b1622fe6b2e3113bdb623969f5117984b39f173b4e3fb19a8833bd216") + version("9.3.1", sha256="b0f919cb9e1f42f803a3e616c2b63a78e4d81ecfaed80978d570d3a5e29d10bc") + version("9.3.0", sha256="91a3695a004ea28db0448a34460bed4cc3b130e5c7d74339ec999efdab0e547d") version("9.2.1", sha256="15ebf4afa8744b9e6fccb5d571fc9f338dc3adcf99907d9e62d1af815d4971a1") version("9.2.0", sha256="dea816f5aa732ae6b2ee3977b9bdb28b1d848cf56a1aad8faf6708b89f0ed50e") version("9.1.1", sha256="003cd4010e52bb5eb8f7de1c143753aa830c8902b6ed01209f294846e40e6d39") @@ -41,7 +45,11 @@ class Proj(CMakePackage, AutotoolsPackage): version("7.2.0", sha256="2957798e5fe295ff96a2af1889d0428e486363d210889422f76dd744f7885763") version("7.1.0", sha256="876151e2279346f6bdbc63bd59790b48733496a957bccd5e51b640fdd26eaa8d") version("7.0.1", sha256="a7026d39c9c80d51565cfc4b33d22631c11e491004e19020b3ff5a0791e1779f") - version("7.0.0", sha256="ee0e14c1bd2f9429b1a28999240304c0342ed739ebaea3d4ff44c585b1097be8") + version( + "7.0.0", + sha256="ee0e14c1bd2f9429b1a28999240304c0342ed739ebaea3d4ff44c585b1097be8", + deprecated=True, + ) version("6.3.2", sha256="cb776a70f40c35579ae4ba04fb4a388c1d1ce025a1df6171350dc19f25b80311") version("6.3.1", sha256="6de0112778438dcae30fcc6942dee472ce31399b9e5a2b67e8642529868c86f8") version("6.2.0", sha256="b300c0f872f632ad7f8eb60725edbf14f0f8f52db740a3ab23e7b94f1cd22a50") @@ -52,12 +60,27 @@ class Proj(CMakePackage, AutotoolsPackage): version("5.0.1", sha256="a792f78897482ed2c4e2af4e8a1a02e294c64e32b591a635c5294cb9d49fdc8c") version("4.9.2", sha256="60bf9ad1ed1c18158e652dfff97865ba6fb2b67f1511bc8dceae4b3c7e657796") version("4.9.1", sha256="fca0388f3f8bc5a1a803d2f6ff30017532367992b30cf144f2d39be88f36c319") - version("4.8.0", sha256="2db2dbf0fece8d9880679154e0d6d1ce7c694dd8e08b4d091028093d87a9d1b5") - version("4.7.0", sha256="fc5440002a496532bfaf423c28bdfaf9e26cc96c84ccefcdefde911efbd98986") - version("4.6.1", sha256="76d174edd4fdb4c49c1c0ed8308a469216c01e7177a4510b1b303ef3c5f97b47") + version( + "4.8.0", + sha256="2db2dbf0fece8d9880679154e0d6d1ce7c694dd8e08b4d091028093d87a9d1b5", + deprecated=True, + ) + version( + "4.7.0", + sha256="fc5440002a496532bfaf423c28bdfaf9e26cc96c84ccefcdefde911efbd98986", + deprecated=True, + ) + version( + "4.6.1", + sha256="76d174edd4fdb4c49c1c0ed8308a469216c01e7177a4510b1b303ef3c5f97b47", + deprecated=True, + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated - variant("tiff", default=True, description="Enable TIFF support") - variant("curl", default=True, description="Enable curl support") + variant("tiff", default=True, when="@7:", description="Enable TIFF support") + variant("curl", default=True, when="@7:", description="Enable curl support") variant("shared", default=True, description="Enable shared libraries") variant("pic", default=False, description="Enable position-independent code (PIC)") @@ -87,11 +110,16 @@ class Proj(CMakePackage, AutotoolsPackage): when="@6.2:9.1", ) - patch("proj.cmakelists.5.0.patch", when="@5.0") - patch("proj.cmakelists.5.1.patch", when="@5.1:5.2") - # https://proj.org/install.html#build-requirements with when("build_system=cmake"): + # https://github.com/OSGeo/PROJ/pull/3374 + patch("proj-8-tiff.patch", when="@8:9.1") + patch("proj-7-tiff.patch", when="@7") + # https://github.com/spack/spack/pull/41065 + patch("proj.cmakelists.5.0.patch", when="@5.0") + patch("proj.cmakelists.5.1.patch", when="@5.1:5.2") + + depends_on("cmake@3.16:", when="@9.4:", type="build") depends_on("cmake@3.9:", when="@6:", type="build") depends_on("cmake@3.5:", when="@5", type="build") depends_on("cmake@2.6:", when="@:4", type="build") @@ -133,6 +161,8 @@ def cmake_args(self): self.define_from_variant("ENABLE_TIFF", "tiff"), self.define_from_variant("ENABLE_CURL", "curl"), self.define_from_variant(shared_arg, "shared"), + # projsync needs curl + self.define_from_variant("BUILD_PROJSYNC", "curl"), self.define_from_variant("CMAKE_POSITION_INDEPENDENT_CODE", "pic"), ] if self.spec.satisfies("@6:") and self.pkg.run_tests: diff --git a/var/spack/repos/builtin/packages/proj/proj-7-tiff.patch b/var/spack/repos/builtin/packages/proj/proj-7-tiff.patch new file mode 100644 index 00000000000000..d6597a3e933675 --- /dev/null +++ b/var/spack/repos/builtin/packages/proj/proj-7-tiff.patch @@ -0,0 +1,19 @@ +--- a/src/lib_proj.cmake 2024-06-12 13:29:53 ++++ b/src/lib_proj.cmake 2024-06-12 13:30:27 +@@ -406,8 +406,14 @@ + + if(TIFF_ENABLED) + target_compile_definitions(${PROJ_CORE_TARGET} PRIVATE -DTIFF_ENABLED) +- target_include_directories(${PROJ_CORE_TARGET} PRIVATE ${TIFF_INCLUDE_DIR}) +- target_link_libraries(${PROJ_CORE_TARGET} ${TIFF_LIBRARY}) ++ if( CMAKE_VERSION VERSION_LESS 3.11 AND CMAKE_CROSSCOMPILING ) ++ # Hack needed for ubuntu:18.04 mingw64 cross compiling to avoid ++ # -isystem to be emitted (similar to https://discourse.cmake.org/t/use-of-isystem/1574) ++ target_include_directories(proj PRIVATE ${TIFF_INCLUDE_DIRS}) ++ target_link_libraries(proj ${TIFF_LIBRARIES}) ++ else() ++ target_link_libraries(proj TIFF::TIFF) ++ endif() + endif() + + if(CURL_ENABLED) diff --git a/var/spack/repos/builtin/packages/proj/proj-8-tiff.patch b/var/spack/repos/builtin/packages/proj/proj-8-tiff.patch new file mode 100644 index 00000000000000..e223d860c96b26 --- /dev/null +++ b/var/spack/repos/builtin/packages/proj/proj-8-tiff.patch @@ -0,0 +1,19 @@ +--- a/src/lib_proj.cmake 2024-06-12 13:07:41 ++++ b/src/lib_proj.cmake 2024-06-12 13:08:16 +@@ -404,8 +404,14 @@ + + if(TIFF_ENABLED) + target_compile_definitions(proj PRIVATE -DTIFF_ENABLED) +- target_include_directories(proj PRIVATE ${TIFF_INCLUDE_DIR}) +- target_link_libraries(proj PRIVATE ${TIFF_LIBRARY}) ++ if( CMAKE_VERSION VERSION_LESS 3.11 AND CMAKE_CROSSCOMPILING ) ++ # Hack needed for ubuntu:18.04 mingw64 cross compiling to avoid ++ # -isystem to be emitted (similar to https://discourse.cmake.org/t/use-of-isystem/1574) ++ target_include_directories(proj PRIVATE ${TIFF_INCLUDE_DIRS}) ++ target_link_libraries(proj PRIVATE ${TIFF_LIBRARIES}) ++ else() ++ target_link_libraries(proj PRIVATE TIFF::TIFF) ++ endif() + endif() + + if(CURL_ENABLED) diff --git a/var/spack/repos/builtin/packages/prometheus/package.py b/var/spack/repos/builtin/packages/prometheus/package.py index 7b0f0fdb53f970..3e6c8baab10b03 100644 --- a/var/spack/repos/builtin/packages/prometheus/package.py +++ b/var/spack/repos/builtin/packages/prometheus/package.py @@ -21,6 +21,8 @@ class Prometheus(MakefilePackage): version("2.17.1", sha256="d0b53411ea0295c608634ca7ef1d43fa0f5559e7ad50705bf4d64d052e33ddaf") version("2.17.0", sha256="b5e508f1c747aaf50dd90a48e5e2a3117fec2e9702d0b1c7f97408b87a073009") + depends_on("c", type="build") # generated + depends_on("go", type="build") depends_on("node-js@11.10.1:", type="build") depends_on("yarn", type="build") diff --git a/var/spack/repos/builtin/packages/prophecy4f/package.py b/var/spack/repos/builtin/packages/prophecy4f/package.py index 4e9ce114ed09ce..be8ac6ed48af41 100644 --- a/var/spack/repos/builtin/packages/prophecy4f/package.py +++ b/var/spack/repos/builtin/packages/prophecy4f/package.py @@ -19,6 +19,9 @@ class Prophecy4f(MakefilePackage): version("3.0.2", sha256="01e6ad4d7e913082c1dcabd589173f5d962086dd7860c710f14a0528d8d80eb7") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("collier") @property diff --git a/var/spack/repos/builtin/packages/protobuf-c/package.py b/var/spack/repos/builtin/packages/protobuf-c/package.py index 86f590b52589f7..953026c6fe4186 100644 --- a/var/spack/repos/builtin/packages/protobuf-c/package.py +++ b/var/spack/repos/builtin/packages/protobuf-c/package.py @@ -22,5 +22,8 @@ class ProtobufC(AutotoolsPackage): version("1.4.1", sha256="4cc4facd508172f3e0a4d3a8736225d472418aee35b4ad053384b137b220339f") version("1.3.2", sha256="53f251f14c597bdb087aecf0b63630f434d73f5a10fc1ac545073597535b9e74") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("protobuf@:3.21.12") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/protobuf/package.py b/var/spack/repos/builtin/packages/protobuf/package.py index 035eab572a922d..8ae36963a46300 100644 --- a/var/spack/repos/builtin/packages/protobuf/package.py +++ b/var/spack/repos/builtin/packages/protobuf/package.py @@ -77,6 +77,9 @@ class Protobuf(CMakePackage): version("3.1.0", sha256="fb2a314f4be897491bb2446697be693d489af645cb0e165a85e7e64e07eb134d") version("3.0.2", sha256="a0a265bcc9d4e98c87416e59c33afc37cede9fb277292523739417e449b18c1e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Enables the build of shared libraries") variant( "build_type", @@ -110,9 +113,9 @@ class Protobuf(CMakePackage): # fix build on Centos 8, see also https://github.com/protocolbuffers/protobuf/issues/5144 patch( - "https://github.com/protocolbuffers/protobuf/pull/11032/commits/3039f932aaf212bcf2f14a3f2fd00dbfb881e46b.patch?full_index=1", + "https://github.com/protocolbuffers/protobuf/commit/462964ed322503af52638d54c00a0a67d7133349.patch?full_index=1", when="@3.4:3.21", - sha256="cefc4bf4aadf9ca33a336b2aa6d0d82006b6563e85122ae8cfb70345f85321dd", + sha256="9b6dcfa30dd3ae0abb66ab0f252a4fc1e1cc82a9820d2bdb72da35c4f80c3603", ) patch("msvc-abseil-target-namespace.patch", when="@3.22 %msvc") diff --git a/var/spack/repos/builtin/packages/proxymngr/package.py b/var/spack/repos/builtin/packages/proxymngr/package.py index 30c8f5e73f1b81..cc1ec5d46c8ca2 100644 --- a/var/spack/repos/builtin/packages/proxymngr/package.py +++ b/var/spack/repos/builtin/packages/proxymngr/package.py @@ -17,6 +17,9 @@ class Proxymngr(AutotoolsPackage, XorgPackage): version("1.0.4", sha256="d40f2d15985ee8e8ef5320a85c0b1899a7bc95974a65137ae886e499bced86f4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libice") depends_on("libxt") depends_on("lbxproxy") diff --git a/var/spack/repos/builtin/packages/prrte/package.py b/var/spack/repos/builtin/packages/prrte/package.py index e233a5102df0b6..c882188f0f78b3 100644 --- a/var/spack/repos/builtin/packages/prrte/package.py +++ b/var/spack/repos/builtin/packages/prrte/package.py @@ -26,6 +26,8 @@ class Prrte(AutotoolsPackage): version("develop", branch="master") version("1.0.0", sha256="a9b3715e059c10ed091bd6e3a0d8896f7752e43ee731abcc95fb962e67132a2d") + depends_on("c", type="build") # generated + depends_on("pmix") depends_on("libevent") depends_on("hwloc") diff --git a/var/spack/repos/builtin/packages/pruners-ninja/package.py b/var/spack/repos/builtin/packages/pruners-ninja/package.py index 931eac995110be..f91ca34dc94f8e 100644 --- a/var/spack/repos/builtin/packages/pruners-ninja/package.py +++ b/var/spack/repos/builtin/packages/pruners-ninja/package.py @@ -20,6 +20,9 @@ class PrunersNinja(AutotoolsPackage): version("1.0.1", sha256="53df5c019054b60c68e63d3e249127f1d5f267a70539c8809fb42a8ddbfcb29b") version("1.0.0", sha256="f25c189783b57801f298dfff8770f42733a43f926668aceff4abd287b6e3a4d1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("mpi") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/ps-lite/package.py b/var/spack/repos/builtin/packages/ps-lite/package.py index 84360da87822ad..cdc2a111099bbf 100644 --- a/var/spack/repos/builtin/packages/ps-lite/package.py +++ b/var/spack/repos/builtin/packages/ps-lite/package.py @@ -18,6 +18,8 @@ class PsLite(CMakePackage): version("master", branch="master") version("20170328", commit="acdb698fa3bb80929ef83bb37c705f025e119b82") + depends_on("cxx", type="build") # generated + depends_on("protobuf@3:") depends_on("libzmq") diff --git a/var/spack/repos/builtin/packages/psalg/package.py b/var/spack/repos/builtin/packages/psalg/package.py index 295f38b21ab277..be4bfc751182d8 100644 --- a/var/spack/repos/builtin/packages/psalg/package.py +++ b/var/spack/repos/builtin/packages/psalg/package.py @@ -16,6 +16,9 @@ class Psalg(CMakePackage): version("3.3.37", sha256="127a5ae44c9272039708bd877849a3af354ce881fde093a2fc6fe0550b698b72") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("xtcdata") depends_on("rapidjson") depends_on("curl") diff --git a/var/spack/repos/builtin/packages/pscmc/package.py b/var/spack/repos/builtin/packages/pscmc/package.py index 03b08534d770eb..0e8b321630551d 100644 --- a/var/spack/repos/builtin/packages/pscmc/package.py +++ b/var/spack/repos/builtin/packages/pscmc/package.py @@ -23,6 +23,8 @@ class Pscmc(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + def setup_run_environment(self, env): env.set("SCMC_COMPILE_ROOT", self.prefix.source) env.set("SCMC_ROOT", join_path(self.prefix.source, "runtime_passes")) diff --git a/var/spack/repos/builtin/packages/psi4/package.py b/var/spack/repos/builtin/packages/psi4/package.py index 497adbf65a20f2..b1ff4187fd262b 100644 --- a/var/spack/repos/builtin/packages/psi4/package.py +++ b/var/spack/repos/builtin/packages/psi4/package.py @@ -20,6 +20,8 @@ class Psi4(CMakePackage): version("1.3.2", sha256="ed76c67803b6420f35f57a6dd31c47108b9145b8c9fced5c94cdc179f6b5fbf3") + depends_on("cxx", type="build") # generated + variant( "build_type", default="Release", diff --git a/var/spack/repos/builtin/packages/psipred/package.py b/var/spack/repos/builtin/packages/psipred/package.py index e8f83999da111d..86fefdc6792154 100644 --- a/var/spack/repos/builtin/packages/psipred/package.py +++ b/var/spack/repos/builtin/packages/psipred/package.py @@ -19,6 +19,8 @@ class Psipred(MakefilePackage): version("4.02", sha256="b4009b6a5f8b76c6d60ac91c4a743512d844864cf015c492fb6d1dc0d092c467") + depends_on("c", type="build") # generated + variant("blast-plus", default=False, description="Use blast-plus in place of blast-legacy") depends_on("blast-legacy", type="run", when="~blast-plus") diff --git a/var/spack/repos/builtin/packages/pslib/package.py b/var/spack/repos/builtin/packages/pslib/package.py index 99031d78e792e8..a720e6a8246725 100644 --- a/var/spack/repos/builtin/packages/pslib/package.py +++ b/var/spack/repos/builtin/packages/pslib/package.py @@ -16,5 +16,7 @@ class Pslib(AutotoolsPackage): version("0.4.5", sha256="7a33928982b281660206bb3749a4a563e3ac987eea64f41696f212df345212be") + depends_on("c", type="build") # generated + depends_on("jpeg") depends_on("libpng") diff --git a/var/spack/repos/builtin/packages/psm/package.py b/var/spack/repos/builtin/packages/psm/package.py index 5946f552d1c85a..992ff39fa5fc37 100644 --- a/var/spack/repos/builtin/packages/psm/package.py +++ b/var/spack/repos/builtin/packages/psm/package.py @@ -22,6 +22,8 @@ class Psm(MakefilePackage): ) version("2017-04-28", commit="604758e76dc31e68d1de736ccf5ddf16cb22355b") + depends_on("c", type="build") # generated + conflicts("%gcc@6:", when="@3.3") depends_on("uuid") diff --git a/var/spack/repos/builtin/packages/psmc/package.py b/var/spack/repos/builtin/packages/psmc/package.py index 2398433563c52b..2ab456639f6d23 100644 --- a/var/spack/repos/builtin/packages/psmc/package.py +++ b/var/spack/repos/builtin/packages/psmc/package.py @@ -17,6 +17,8 @@ class Psmc(MakefilePackage): version("2016-1-21", commit="e5f7df5d00bb75ec603ae0beff62c0d7e37640b9") + depends_on("c", type="build") # generated + depends_on("zlib-api", type="link") def setup_run_environment(self, env): diff --git a/var/spack/repos/builtin/packages/psrcat/package.py b/var/spack/repos/builtin/packages/psrcat/package.py index df8cb88bd4e339..087f7410da63f3 100644 --- a/var/spack/repos/builtin/packages/psrcat/package.py +++ b/var/spack/repos/builtin/packages/psrcat/package.py @@ -16,6 +16,8 @@ class Psrcat(MakefilePackage): version("1.68", sha256="fbe4710c9122e4f93dbca54cf42cc2906f948f76885b241d1da2f8caecfbc657") + depends_on("c", type="build") # generated + def build(self, spec, prefix): makeit = which("./makeit") makeit() diff --git a/var/spack/repos/builtin/packages/psrchive/package.py b/var/spack/repos/builtin/packages/psrchive/package.py index f96a70cbd51f41..f97f318fa72e15 100644 --- a/var/spack/repos/builtin/packages/psrchive/package.py +++ b/var/spack/repos/builtin/packages/psrchive/package.py @@ -29,6 +29,10 @@ class Psrchive(AutotoolsPackage): # as of Nov 23 2022 version("2020-10-17", commit="ca12b4a279f3d4adcca223508116d9d270df8cc6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Compile with MPI") variant("mkl", default=False, description="Compile with MKL") variant("armadillo", default=False, description="Compile with armadillo") diff --git a/var/spack/repos/builtin/packages/psrdada/package.py b/var/spack/repos/builtin/packages/psrdada/package.py new file mode 100644 index 00000000000000..e2d3d62e70a579 --- /dev/null +++ b/var/spack/repos/builtin/packages/psrdada/package.py @@ -0,0 +1,32 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Psrdada(AutotoolsPackage, CudaPackage): + """Open source software to process some types of astronomy data.""" + + homepage = "https://psrdada.sourceforge.net/" + git = "https://git.code.sf.net/p/psrdada/code" + + maintainers("aweaver1fandm") + + version("master", branch="master", preferred=True) + + depends_on("c", type="build") # generated + + conflicts("~cuda", msg="You must specify +cuda") + conflicts("cuda@11.8") + conflicts("cuda_arch=none", msg="You must specify the CUDA architecture") + + depends_on("autoconf", type="build") + depends_on("automake", type="build") + depends_on("libtool", type="build") + depends_on("nasm", type="build") + depends_on("pkgconf", type="build") + depends_on("fftw@3.3:", type="build") + depends_on("python") + depends_on("cuda", type="build") diff --git a/var/spack/repos/builtin/packages/pstreams/package.py b/var/spack/repos/builtin/packages/pstreams/package.py index 2fc2bdaa901188..204c83cf7473f5 100644 --- a/var/spack/repos/builtin/packages/pstreams/package.py +++ b/var/spack/repos/builtin/packages/pstreams/package.py @@ -18,6 +18,8 @@ class Pstreams(Package): version("1.0.3", sha256="e9ca807bc6046840deae63207183f9ac516e67187d035429772a5fc7bd3e8fc8") version("1.0.1", sha256="a5f1f2e014392cd0e2cdb508a429e11afe64140db05b7f0a83d7534faa1a9226") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.include) install("pstream.h", prefix.include) diff --git a/var/spack/repos/builtin/packages/pthreadpool/package.py b/var/spack/repos/builtin/packages/pthreadpool/package.py index 64f190e4d0aa07..3a60f89d0835be 100644 --- a/var/spack/repos/builtin/packages/pthreadpool/package.py +++ b/var/spack/repos/builtin/packages/pthreadpool/package.py @@ -23,6 +23,9 @@ class Pthreadpool(CMakePackage): version("2018-10-08", commit="13da0b4c21d17f94150713366420baaf1b5a46f4") # py-torch@1.0:1.4 version("2018-02-25", commit="2b06b31f6a315162348e1f3c24325eedaf6cc559") # py-torch@:0.4 + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@3.5:", type="build") depends_on("python", type="build") diff --git a/var/spack/repos/builtin/packages/pugixml/package.py b/var/spack/repos/builtin/packages/pugixml/package.py index 3cb7ae0e64c48f..dab9c1aa8a28ff 100644 --- a/var/spack/repos/builtin/packages/pugixml/package.py +++ b/var/spack/repos/builtin/packages/pugixml/package.py @@ -15,12 +15,15 @@ class Pugixml(CMakePackage): license("MIT") + version("1.14", sha256="2f10e276870c64b1db6809050a75e11a897a8d7456c4be5c6b2e35a11168a015") version("1.13", sha256="40c0b3914ec131485640fa57e55bf1136446026b41db91c1bef678186a12abbe") version("1.11.4", sha256="8ddf57b65fb860416979a3f0640c2ad45ddddbbafa82508ef0a0af3ce7061716") version("1.11", sha256="26913d3e63b9c07431401cf826df17ed832a20d19333d043991e611d23beaa2c") version("1.10", sha256="55f399fbb470942410d348584dc953bcaec926415d3462f471ef350f29b5870a") version("1.8.1", sha256="929c4657c207260f8cc28e5b788b7499dffdba60d83d59f55ea33d873d729cd4") + depends_on("cxx", type="build") # generated + variant("pic", default=True, description="Build position-independent code") variant("shared", default=True, description="Build shared libraries") diff --git a/var/spack/repos/builtin/packages/pulseaudio/package.py b/var/spack/repos/builtin/packages/pulseaudio/package.py index a8056319fcc28e..bacf9bb733edb6 100644 --- a/var/spack/repos/builtin/packages/pulseaudio/package.py +++ b/var/spack/repos/builtin/packages/pulseaudio/package.py @@ -24,6 +24,9 @@ class Pulseaudio(AutotoolsPackage): version("13.0", sha256="961b23ca1acfd28f2bc87414c27bb40e12436efcf2158d29721b1e89f3f28057") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("alsa", default=False, description="alsa support") variant("fftw", default=False, description="FFTW support") variant("gconf", default=False, description="Gconf support") diff --git a/var/spack/repos/builtin/packages/pumi/package.py b/var/spack/repos/builtin/packages/pumi/package.py index f06b0078336178..a2ce76b27ce621 100644 --- a/var/spack/repos/builtin/packages/pumi/package.py +++ b/var/spack/repos/builtin/packages/pumi/package.py @@ -45,6 +45,10 @@ class Pumi(CMakePackage): version("2.2.0", commit="8c7e6f13943893b2bc1ece15003e4869a0e9634f") # tag 2.2.0 version("2.1.0", commit="840fbf6ec49a63aeaa3945f11ddb224f6055ac9f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("int64", default=False, description="Enable 64bit mesh entity ids") variant("shared", default=False, description="Build shared libraries") variant("zoltan", default=False, description="Enable Zoltan Features") @@ -65,6 +69,10 @@ class Pumi(CMakePackage): "Disable the check for testing new versions.", ) + depends_on("cxx", type="build") + depends_on("c", type="build") + depends_on("fortran", type="build", when="+fortran") + depends_on("mpi") depends_on("cmake@3:", type="build") depends_on("zoltan", when="+zoltan") @@ -111,25 +119,34 @@ def cmake_args(self): args.append("-DSIM_DISCRETE=ON") return args - def test(self): - if self.spec.version <= Version("2.2.6"): - return - exe = "uniform" - options = ["../testdata/pipe.dmg", "../testdata/pipe.smb", "pipe_unif.smb"] - expected = "mesh pipe_unif.smb written" - description = "testing pumi uniform mesh refinement" - self.run_test(exe, options, expected, purpose=description, work_dir=self.prefix.bin) - - mpiexec = Executable(join_path(self.spec["mpi"].prefix.bin, "mpiexec")).command - mpiopt = ["-n", "2"] - exe = ["split"] - options = ["../testdata/pipe.dmg", "../testdata/pipe.smb", "pipe_2_.smb", "2"] - expected = "mesh pipe_2_.smb written" - description = "testing pumi mesh partitioning" - self.run_test( - mpiexec, - mpiopt + exe + options, - expected, - purpose=description, - work_dir=self.prefix.bin, - ) + def test_partition(self): + """Testing pumi mesh partitioning""" + if self.spec.satisfies("@:2.2.6"): + raise SkipTest("Package must be installed as version @2.2.7 or later") + + options = [ + "-n", + "2", + join_path(self.prefix.bin, "split"), + join_path(self.prefix.share.testdata, "pipe.dmg"), + join_path(self.prefix.share.testdata, "pipe.smb"), + "pipe_2_.smb", + "2", + ] + exe = which(self.spec["mpi"].prefix.bin.mpiexec) + out = exe(*options, output=str.split, error=str.split) + assert "mesh pipe_2_.smb written" in out + + def test_refine(self): + """Testing pumi uniform mesh refinement""" + if self.spec.satisfies("@:2.2.6"): + raise SkipTest("Package must be installed as version @2.2.7 or later") + + options = [ + join_path(self.prefix.share.testdata, "pipe.dmg"), + join_path(self.prefix.share.testdata, "pipe.smb"), + "pipe_unif.smb", + ] + exe = which(self.prefix.bin.uniform) + out = exe(*options, output=str.split, error=str.split) + assert "mesh pipe_unif.smb written" in out diff --git a/var/spack/repos/builtin/packages/pv/package.py b/var/spack/repos/builtin/packages/pv/package.py index 81dcbf63a3808e..9168d2177dc4cc 100644 --- a/var/spack/repos/builtin/packages/pv/package.py +++ b/var/spack/repos/builtin/packages/pv/package.py @@ -20,3 +20,5 @@ class Pv(AutotoolsPackage): version("1.8.5", sha256="d22948d06be06a5be37336318de540a2215be10ab0163f8cd23a20149647b780") version("1.6.20", sha256="b5f1ee79a370c5287e092b6e8f1084f026521fe0aecf25c44b9460b870319a9e") version("1.6.6", sha256="94defb4183ae07c44219ba298d43c4991d6e203c29f74393d72ecad3b090508a") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/pvm/package.py b/var/spack/repos/builtin/packages/pvm/package.py index 0000c87e810ff0..d546b4ce9c1bd8 100644 --- a/var/spack/repos/builtin/packages/pvm/package.py +++ b/var/spack/repos/builtin/packages/pvm/package.py @@ -18,6 +18,9 @@ class Pvm(MakefilePackage): version("3.4.6", sha256="482665e9bc975d826bcdacf1df1d42e43deda9585a2c430fd3b7b7ed08eada44") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("m4", type="build") depends_on("libtirpc", type="link") diff --git a/var/spack/repos/builtin/packages/pwgen/package.py b/var/spack/repos/builtin/packages/pwgen/package.py index dde641f0693699..fd402bba2f2899 100644 --- a/var/spack/repos/builtin/packages/pwgen/package.py +++ b/var/spack/repos/builtin/packages/pwgen/package.py @@ -19,4 +19,6 @@ class Pwgen(AutotoolsPackage): version("2.08", sha256="dab03dd30ad5a58e578c5581241a6e87e184a18eb2c3b2e0fffa8a9cf105c97b") + depends_on("c", type="build") # generated + depends_on("coreutils", type="build") diff --git a/var/spack/repos/builtin/packages/pxz/package.py b/var/spack/repos/builtin/packages/pxz/package.py index 8d49db024c85df..60af37c6faa39d 100644 --- a/var/spack/repos/builtin/packages/pxz/package.py +++ b/var/spack/repos/builtin/packages/pxz/package.py @@ -19,6 +19,8 @@ class Pxz(MakefilePackage): sha256="df69f91103db6c20f0b523bb7f026d86ee662c49fe714647ed63f918cd39767a", ) + depends_on("c", type="build") # generated + depends_on("xz") conflicts("platform=darwin", msg="Pxz runs only on Linux.") diff --git a/var/spack/repos/builtin/packages/py-4suite-xml/package.py b/var/spack/repos/builtin/packages/py-4suite-xml/package.py index ffb1a78e43ab61..474c4ed2ac4187 100644 --- a/var/spack/repos/builtin/packages/py-4suite-xml/package.py +++ b/var/spack/repos/builtin/packages/py-4suite-xml/package.py @@ -15,6 +15,8 @@ class Py4suiteXml(PythonPackage): version("1.0.2", sha256="f0c24132eb2567e64b33568abff29a780a2f0236154074d0b8f5262ce89d8c03") + depends_on("c", type="build") # generated + depends_on("python@2.2.1:", type=("build", "run")) # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-accimage/package.py b/var/spack/repos/builtin/packages/py-accimage/package.py index 46f226676a3521..da85b97d062e78 100644 --- a/var/spack/repos/builtin/packages/py-accimage/package.py +++ b/var/spack/repos/builtin/packages/py-accimage/package.py @@ -20,6 +20,8 @@ class PyAccimage(PythonPackage): version("0.1.1", sha256="573c56866a42683c7cf25185620fe82ec2ce78468e0621c29fac8f4134a785f5") + depends_on("c", type="build") # generated + depends_on("python", type=("build", "link", "run")) # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-adios/package.py b/var/spack/repos/builtin/packages/py-adios/package.py index be61bec7719cbc..173e6df7e02d0f 100644 --- a/var/spack/repos/builtin/packages/py-adios/package.py +++ b/var/spack/repos/builtin/packages/py-adios/package.py @@ -20,6 +20,10 @@ class PyAdios(PythonPackage): version("develop", branch="master") version("1.13.1", sha256="b1c6949918f5e69f701cabfe5987c0b286793f1057d4690f04747852544e157b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") for v in ["1.13.1", "develop"]: diff --git a/var/spack/repos/builtin/packages/py-aiohttp/package.py b/var/spack/repos/builtin/packages/py-aiohttp/package.py index 28fe3f58a33eb6..da787028e38103 100644 --- a/var/spack/repos/builtin/packages/py-aiohttp/package.py +++ b/var/spack/repos/builtin/packages/py-aiohttp/package.py @@ -18,12 +18,18 @@ class PyAiohttp(PythonPackage): license("Apache-2.0") + version("3.9.5", sha256="edea7d15772ceeb29db4aff55e482d4bcfb6ae160ce144f2682de02f6d693551") + version("3.9.4", sha256="6ff71ede6d9a5a58cfb7b6fffc83ab5d4a63138276c771ac91ceaaddf5459644") + version("3.9.0", sha256="09f23292d29135025e19e8ff4f0a68df078fe4ee013bca0105b2e803989de92d") version("3.8.4", sha256="bf2e1a9162c1e441bf805a1fd166e249d574ca04e03b34f97e2928769e91ab5c") version("3.8.1", sha256="fc5471e1a54de15ef71c1bc6ebe80d4dc681ea600e68bfd1cbce40427f0b7578") version("3.8.0", sha256="d3b19d8d183bcfd68b25beebab8dc3308282fe2ca3d6ea3cb4cd101b3c279f8d") version("3.7.4", sha256="5d84ecc73141d0a0d61ece0742bb7ff5751b0657dab8405f899d3ceb104cc7de") version("3.6.2", sha256="259ab809ff0727d0e834ac5e8a283dc5e3e0ecc30c4d80b3cd17a4139ce1f326") + depends_on("c", type="build") # generated + + depends_on("python@3.8:", when="@3.9:") depends_on("py-setuptools@46.4:", type="build") depends_on("py-attrs@17.3.0:", type=("build", "run")) @@ -31,8 +37,8 @@ class PyAiohttp(PythonPackage): depends_on("py-charset-normalizer@2", when="@3.8.0:3.8.3", type=("build", "run")) depends_on("py-multidict@4.5:6", when="@3.6.3:", type=("build", "run")) depends_on("py-multidict@4.5:4", when="@:3.6.2", type=("build", "run")) - depends_on("py-async-timeout@4", when="@3.8.0:", type=("build", "run")) - depends_on("py-async-timeout@3", when="@:3.7.4", type=("build", "run")) + depends_on("py-async-timeout@4", when="@3.8.0 ^python@:3.10", type=("build", "run")) + depends_on("py-async-timeout@3", when="@:3.7.4 ^python@:3.10", type=("build", "run")) depends_on("py-asynctest@0.13.0", when="@3.8.0: ^python@:3.7", type=("build", "run")) depends_on("py-yarl@1", type=("build", "run")) depends_on("py-typing-extensions@3.7.4:", when="@3.8: ^python@:3.7", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-alabaster/package.py b/var/spack/repos/builtin/packages/py-alabaster/package.py index 44fc988f00168a..1c2c026136648f 100644 --- a/var/spack/repos/builtin/packages/py-alabaster/package.py +++ b/var/spack/repos/builtin/packages/py-alabaster/package.py @@ -14,9 +14,12 @@ class PyAlabaster(PythonPackage): pypi = "alabaster/alabaster-0.7.10.tar.gz" git = "https://github.com/sphinx-doc/alabaster.git" + version("0.7.16", sha256="75a8b99c28a5dad50dd7f8ccdd447a121ddb3892da9e53d1ca5cca3106d58d65") version("0.7.13", sha256="a27a4a084d5e690e16e01e03ad2b2e552c61a65469419b907243193de1a84ae2") version("0.7.12", sha256="a661d72d58e6ea8a57f7a86e37d86716863ee5e92788398526d58b26a4e4dc02") version("0.7.10", sha256="37cdcb9e9954ed60912ebc1ca12a9d12178c26637abdf124e3cde2341c257fe0") version("0.7.9", sha256="47afd43b08a4ecaa45e3496e139a193ce364571e7e10c6a87ca1a4c57eb7ea08") - depends_on("py-setuptools", type="build") + depends_on("python@3.9:", when="@0.7.16:", type=("build", "run")) + depends_on("py-flit-core@3.7:", when="@0.7.16:", type="build") + depends_on("py-setuptools", when="@:0.7.13", type="build") diff --git a/var/spack/repos/builtin/packages/py-alphafold/package.py b/var/spack/repos/builtin/packages/py-alphafold/package.py index 674f3ebf10810d..0269a2abdfb187 100644 --- a/var/spack/repos/builtin/packages/py-alphafold/package.py +++ b/var/spack/repos/builtin/packages/py-alphafold/package.py @@ -77,7 +77,7 @@ class PyAlphafold(PythonPackage, CudaPackage): @run_after("install") def install_scripts(self): mkdirp(self.prefix.bin) - shebang = "#!{0}\n".format(self.spec["python"].command) + shebang = f"#!{python.path}\n" for fname in glob.glob("run_alphafold*.py"): destfile = join_path(self.prefix.bin, fname) with open(fname, "r") as src: diff --git a/var/spack/repos/builtin/packages/py-amici/package.py b/var/spack/repos/builtin/packages/py-amici/package.py index 7b6bac8e88daf0..731734daa599b1 100644 --- a/var/spack/repos/builtin/packages/py-amici/package.py +++ b/var/spack/repos/builtin/packages/py-amici/package.py @@ -15,6 +15,9 @@ class PyAmici(PythonPackage): version("0.16.0", sha256="1a2d6633ec34241d8d8b496d18d4318482cffe125e9ddf3ca6cac5d36d235f38") version("0.11.28", sha256="a8ddda70d8ebdc40600b4ad2ea02eb26e765ca0e594b957f61866b8c84255d5b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("boost", default=True, description="Enable boost support") variant("hdf5", default=True, description="Enable HDF5 support") diff --git a/var/spack/repos/builtin/packages/py-amplpy/package.py b/var/spack/repos/builtin/packages/py-amplpy/package.py index cc9d0c069b6e0f..77f0f3fa823a08 100644 --- a/var/spack/repos/builtin/packages/py-amplpy/package.py +++ b/var/spack/repos/builtin/packages/py-amplpy/package.py @@ -22,6 +22,8 @@ class PyAmplpy(PythonPackage): version("0.8.6", sha256="ad0945d69f75e7762802bb54849009717fbcf226a6da6f37b539d9534bdcf68d") + depends_on("cxx", type="build") # generated + depends_on("py-future@0.15.0:", type=("build", "run")) depends_on("py-ampltools@0.4.5:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-amqp/package.py b/var/spack/repos/builtin/packages/py-amqp/package.py index 13b5e912eafbd0..41905eb05689b1 100644 --- a/var/spack/repos/builtin/packages/py-amqp/package.py +++ b/var/spack/repos/builtin/packages/py-amqp/package.py @@ -13,12 +13,20 @@ class PyAmqp(PythonPackage): license("BSD-3-Clause") + version("5.2.0", sha256="a1ecff425ad063ad42a486c902807d1482311481c8ad95a72694b2975e75f7fd") + version("5.1.1", sha256="2c1b13fecc0893e946c65cbd5f36427861cffa4ea2201d8f6fca22e2a373b5e2") version("5.0.9", sha256="1e5f707424e544078ca196e72ae6a14887ce74e02bd126be54b7c03c971bef18") + version("5.0.6", sha256="03e16e94f2b34c31f8bf1206d8ddd3ccaa4c315f7f6a1879b7b1210d229568c2") version("5.0.1", sha256="9881f8e6fe23e3db9faa6cfd8c05390213e1d1b95c0162bc50552cad75bffa5f") + version("5.0.0", sha256="1183b66e54a5c533b679d9f557b31c5b31d26701761f2bbd144054cce58f3588") version("2.6.1", sha256="70cdb10628468ff14e57ec2f751c7aa9e48e7e3651cfd62d431213c0c4e58f21") + version("2.6.0", sha256="24dbaff8ce4f30566bb88976b398e8c4e77637171af3af6f1b9650f48890e60b") version("2.5.2", sha256="77f1aef9410698d20eaeac5b73a87817365f457a507d82edf292e12cbb83b08d") + version("2.5.1", sha256="19a917e260178b8d410122712bac69cb3e6db010d68f6101e7307508aded5e68") + version("2.5.0", sha256="cbb6f87d53cac612a594f982b717cc1c54c6a1e17943a0a0d32dc6cc9e2120c8") version("2.4.2", sha256="043beb485774ca69718a35602089e524f87168268f0d1ae115f28b88d27f92d7") version("2.4.1", sha256="6816eed27521293ee03aa9ace300a07215b11fee4e845588a9b863a7ba30addb") + version("2.4.0", sha256="9f181e4aef6562e6f9f45660578fc1556150ca06e836ecb9e733e6ea10b48464") depends_on("python@2.7:2.8,3.5:", type=("build", "run")) depends_on("python@3.6:", type=("build", "run"), when="@5.0.9:") diff --git a/var/spack/repos/builtin/packages/py-amrex/package.py b/var/spack/repos/builtin/packages/py-amrex/package.py index 218a3b4ac82ce2..b5dfe578e26d7e 100644 --- a/var/spack/repos/builtin/packages/py-amrex/package.py +++ b/var/spack/repos/builtin/packages/py-amrex/package.py @@ -10,6 +10,7 @@ class PyAmrex(PythonPackage, CudaPackage, ROCmPackage): """AMReX Python Bindings with pybind11""" homepage = "https://amrex-codes.github.io/amrex/" + url = "https://github.com/AMReX-Codes/pyamrex/archive/refs/tags/24.04.tar.gz" git = "https://github.com/AMReX-Codes/pyamrex.git" maintainers("ax3l", "RTSandberg", "sayerhs", "WeiqunZhang") @@ -17,8 +18,21 @@ class PyAmrex(PythonPackage, CudaPackage, ROCmPackage): license("BSD-3-Clause-LBNL") version("develop", branch="development") + version("24.04", sha256="ab85695bb9644b702d0fc84e77205d264d27ba94999cab912c8a3212a7eb77fc") + version("24.03", sha256="bf85b4ad35b623278cbaae2c07e22138545dec0732d15c4ab7c53be76a7f2315") - variant("dimensions", default="3", description="Dimensionality", values=("1", "2", "3")) + depends_on("cxx", type="build") # generated + + for v in ["24.04", "24.03"]: + depends_on("amrex@{0}".format(v), when="@{0}".format(v), type=("build", "link")) + + variant( + "dimensions", + default="1,2,3", + values=("1", "2", "3"), + multi=True, + description="Dimensionality", + ) variant("mpi", default=True, description="Build with MPI support") variant("openmp", default=False, description="Build with OpenMP support") variant( @@ -29,21 +43,17 @@ class PyAmrex(PythonPackage, CudaPackage, ROCmPackage): ) variant("tiny_profile", default=False, description="Enable tiny profiling") - depends_on("python@3.7:", type=("build", "run")) + depends_on("python@3.8:", type=("build", "run")) depends_on("py-numpy@1.15.0:1", type=("build", "run")) depends_on("py-mpi4py@2.1.0:", type=("build", "run"), when="+mpi") + depends_on("py-packaging@23:", type="build") depends_on("py-setuptools@42:", type="build") - # We just need a CMake binary, and py-cmake is notoriously hard to build on - # exotic architectures. So ignore the pyproject.toml declaration and use - # Spack's cmake package. - # depends_on('py-cmake@3.20:3', type='build') depends_on("cmake@3.20:3", type="build") - depends_on("py-pybind11@2.9.1:", type="link") + depends_on("py-pybind11@2.11.1:", type="link") # AMReX options - depends_on("amrex@22.08:", type=("build", "link")) # required variants - depends_on("amrex +pic +particles") + depends_on("amrex +shared +pic +particles") # controllable variants with when("dimensions=1"): depends_on("amrex dimensions=1") @@ -64,15 +74,23 @@ class PyAmrex(PythonPackage, CudaPackage, ROCmPackage): depends_on("amrex +rocm") # todo: how to forward amdgpu_target? + depends_on("py-pytest", type="test") + depends_on("py-pandas", type="test") + depends_on("py-cupy", type="test", when="+cuda") + + tests_src_dir = "tests/" + def setup_build_environment(self, env): spec = self.spec # disable superbuilds: use external dependencies env.set("AMREX_INTERNAL", "OFF") + env.set("PYAMREX_CCACHE", "OFF") + env.set("PYAMREX_IPO", "ON") env.set("PYBIND11_INTERNAL", "OFF") # configure to require the exact AMReX configs provided by Spack - env.set("AMREX_SPACEDIM", spec.variants["dimensions"].value) + env.set("AMREX_SPACEDIM", ";".join(spec.variants["dimensions"].value)) env.set("AMREX_MPI", "ON" if spec.satisfies("+mpi") else "OFF") env.set("AMREX_OMP", "ON" if spec.satisfies("+omp") else "OFF") env.set("AMREX_PRECISION", spec.variants["precision"].value.upper()) @@ -85,3 +103,19 @@ def setup_build_environment(self, env): # control build parallelism env.set("CMAKE_BUILD_PARALLEL_LEVEL", make_jobs) + + def check(self): + """Checks after the build phase""" + pytest = which("pytest") + pytest(join_path(self.stage.source_path, self.tests_src_dir)) + + @run_after("install") + def copy_test_sources(self): + """Copy the example test files after the package is installed to an + install test subdirectory for use during `spack test run`.""" + cache_extra_test_sources(self, [self.tests_src_dir]) + + def test(self): + """Perform smoke tests on the installed package.""" + pytest = which("pytest") + pytest(join_path(install_test_root(self), self.tests_src_dir)) diff --git a/var/spack/repos/builtin/packages/py-angel/package.py b/var/spack/repos/builtin/packages/py-angel/package.py index c1e5da3b2a80d3..4f0babecf5c920 100644 --- a/var/spack/repos/builtin/packages/py-angel/package.py +++ b/var/spack/repos/builtin/packages/py-angel/package.py @@ -16,6 +16,8 @@ class PyAngel(PythonPackage): version("3.0", sha256="a0319553055d3dfc84a4f732ed246c180c23ee9c397810c96acd7940721ae57d") + depends_on("cxx", type="build") # generated + depends_on("python@3.7:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-annoy/package.py b/var/spack/repos/builtin/packages/py-annoy/package.py index 6d65d9ae8cf775..00abc22c0efd8a 100644 --- a/var/spack/repos/builtin/packages/py-annoy/package.py +++ b/var/spack/repos/builtin/packages/py-annoy/package.py @@ -19,5 +19,7 @@ class PyAnnoy(PythonPackage): version("1.17.1", sha256="bf177dbeafb81f63b2ac1e1246b1f26a2acc82e73ba46638734d29d8258122da") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-nose@1:", type="build") diff --git a/var/spack/repos/builtin/packages/py-anuga/package.py b/var/spack/repos/builtin/packages/py-anuga/package.py index bae0e394e88927..97e83db416f160 100644 --- a/var/spack/repos/builtin/packages/py-anuga/package.py +++ b/var/spack/repos/builtin/packages/py-anuga/package.py @@ -20,6 +20,10 @@ class PyAnuga(PythonPackage): # The git main branch of the repo is now python3-only version("main", branch="main") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Non-versioned dependencies for Anuga main and future versions based on python@3.5: depends_on("python@3.5:", type=("build", "run"), when="@2.2:") depends_on("gdal+geos+python", type=("build", "run"), when="@2.2:") diff --git a/var/spack/repos/builtin/packages/py-archspec/package.py b/var/spack/repos/builtin/packages/py-archspec/package.py index ea16e4acb8590a..cd1ffca6262bfb 100644 --- a/var/spack/repos/builtin/packages/py-archspec/package.py +++ b/var/spack/repos/builtin/packages/py-archspec/package.py @@ -17,6 +17,7 @@ class PyArchspec(PythonPackage): license("Apache-2.0") + version("0.2.4", sha256="eabbae22f315d24cc2ce786a092478ec8e245208c9877fb213c2172a6ecb9302") version("0.2.3", sha256="d07deb5b6e2ab3b74861e217523d02e69be8522f6e6565f4cc5d2062eb1a5d2c") version("0.2.2", sha256="d922c9fd80a5234d8cef883fbe0e146b381c449062c0405f91714ebad1edc035") version("0.2.1", sha256="0974a8a95831d2d43cce906c5b79a35d5fd2bf9be478b0e3b7d83ccc51ac815e") diff --git a/var/spack/repos/builtin/packages/py-argon2-cffi-bindings/package.py b/var/spack/repos/builtin/packages/py-argon2-cffi-bindings/package.py index fe684841fa0564..e65da55147752a 100644 --- a/var/spack/repos/builtin/packages/py-argon2-cffi-bindings/package.py +++ b/var/spack/repos/builtin/packages/py-argon2-cffi-bindings/package.py @@ -16,6 +16,8 @@ class PyArgon2CffiBindings(PythonPackage): version("21.2.0", sha256="bb89ceffa6c791807d1305ceb77dbfacc5aa499891d2c55661c6459651fc39e3") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools@45:", type="build") depends_on("py-setuptools-scm@6.2:", type="build") diff --git a/var/spack/repos/builtin/packages/py-arm-pyart/package.py b/var/spack/repos/builtin/packages/py-arm-pyart/package.py index 433e7298fe6db7..3ed8511fb49e63 100644 --- a/var/spack/repos/builtin/packages/py-arm-pyart/package.py +++ b/var/spack/repos/builtin/packages/py-arm-pyart/package.py @@ -22,6 +22,8 @@ class PyArmPyart(PythonPackage): version("1.12.7", sha256="b7b23ecef270c60b017d94603941f0c117de072a10125c5f58c0685d801f9161") + depends_on("c", type="build") # generated + variant("cartopy", description="Plot grids on maps", default=False) variant("cylp", description="Linear programming solver", default=False) variant("gdal", description="Output GeoTIFFs from grid objects", default=False) @@ -39,6 +41,8 @@ class PyArmPyart(PythonPackage): depends_on("py-cython", type="build") depends_on("py-numpy", type=("build", "run")) + # https://github.com/ARM-DOE/pyart/issues/1550 + depends_on("py-numpy@:1", when="@:1.18.1", type=("build", "run")) depends_on("py-scipy", type=("build", "run")) depends_on("py-netcdf4", type=("build", "run")) depends_on("py-matplotlib", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-arrow/package.py b/var/spack/repos/builtin/packages/py-arrow/package.py index d37264f82569b0..c6ba2131f1ec14 100644 --- a/var/spack/repos/builtin/packages/py-arrow/package.py +++ b/var/spack/repos/builtin/packages/py-arrow/package.py @@ -19,6 +19,7 @@ class PyArrow(PythonPackage): license("Apache-2.0") + version("1.3.0", sha256="d4540617648cb5f895730f1ad8c82a65f2dad0166f57b75f3ca54759c4d67a85") version("1.2.3", sha256="3934b30ca1b9f292376d9db15b19446088d12ec58629bc3f0da28fd55fb633a1") version("1.2.2", sha256="05caf1fd3d9a11a1135b2b6f09887421153b94558e5ef4d090b567b47173ac2b") version("1.2.1", sha256="c2dde3c382d9f7e6922ce636bf0b318a7a853df40ecb383b29192e6c5cc82840") @@ -26,9 +27,12 @@ class PyArrow(PythonPackage): version("0.14.7", sha256="67f8be7c0cf420424bc62d8d7dc40b44e4bb2f7b515f9cc2954fb36e35797656") version("0.14.1", sha256="2d30837085011ef0b90ff75aa0a28f5c7d063e96b7e76b6cbc7e690310256685") + depends_on("python@3.8:", type=("build", "run"), when="@1.3:") depends_on("python@3.6:", type=("build", "run"), when="@1.2.1:") depends_on("python@2.7:2.8,3.5:", type=("build", "run"), when="@:0.16.0") - depends_on("py-setuptools", type="build") + depends_on("py-setuptools", type="build", when="@:1.2") + depends_on("py-flit-core@3.2:3", type="build", when="@1.3:") depends_on("py-python-dateutil", type=("build", "run")) - depends_on("py-typing-extensions", type=("build", "run"), when="@1.2.1: ^python@:3.7") + depends_on("py-typing-extensions", type=("build", "run"), when="@1.2.1:1.2 ^python@:3.7") depends_on("py-python-dateutil@2.7.0:", type=("build", "run"), when="@1.2.1:") + depends_on("py-types-python-dateutil@2.8.10:", type=("build", "run"), when="@1.3:") diff --git a/var/spack/repos/builtin/packages/py-asgiref/package.py b/var/spack/repos/builtin/packages/py-asgiref/package.py index 076dadd88a0f46..1d2aa90d53756f 100644 --- a/var/spack/repos/builtin/packages/py-asgiref/package.py +++ b/var/spack/repos/builtin/packages/py-asgiref/package.py @@ -10,24 +10,24 @@ class PyAsgiref(PythonPackage): """ASGI specification and utilities.""" homepage = "https://asgi.readthedocs.io/en/latest/" - url = "https://github.com/django/asgiref/archive/3.2.7.tar.gz" + pypi = "asgiref/asgiref-3.7.2.tar.gz" license("BSD-3-Clause") - version("3.5.2", sha256="62f04f81110898e471a7d5b37f88c923c2864d43fa6abb66a95980becb1a2ba4") + version("3.7.2", sha256="9e0ce3aa93a819ba5b45120216b23878cf6e8525eb3848653452b4192b92afed") + version("3.5.2", sha256="4a29362a6acebe09bf1d6640db38c1dc3d9217c68e6f9f6204d72667fc19a424") version("3.5.0", sha256="2f8abc20f7248433085eda803936d98992f1343ddb022065779f37c5da0181d0") - version("3.2.7", sha256="8a0b556b9e936418475f6670d59e14592c41d15d00b5ea4ad26f2b46f9f4fb9a") - version("3.2.6", sha256="29788163bdad8d494475a0137eba39b111fd86fbe825534a9376f9f2ab44251a") - version("3.2.5", sha256="eeb01ba02e86859746ee2a7bc8a75c484a006dc9575723563f24642a12b2bba8") - version("3.2.4", sha256="89e47532340338b7eafd717ab28658e8b48f4565d8384628c88d2d41565c8da0") - version("3.2.3", sha256="d38e16141c7189e23bfe03342d9cd3dbfd6baab99217892bfa7bc5646315b6bd") - version("3.2.2", sha256="47edf327aa70f317c9bc810d469ce681f1b35a7f499f68cf2b5da3ba6a651e69") - version("3.2.1", sha256="06a21df1f4456d29079f3c475c09ac31167bcc5f024c637dedf4e00d2dd9020b") - version("3.2.0", sha256="5db8c7a6c1ff54ea04a52f994d8af959427f1cab8e427aa802492a89fb0b635a") - version("3.1.4", sha256="bf01c52111ef7af2adc1e6d90282d2a32c5ebe09e84ae448389ceff7cef53fa9") - version("3.1.3", sha256="5b8bb7b3719b8c12a6c2363784a4d8c0eb5e980d8b4fdb6f38eccb52071dfab5") + version("3.2.7", sha256="8036f90603c54e93521e5777b2b9a39ba1bad05773fcf2d208f0299d1df58ce5") + version("3.2.6", sha256="63007b556233381c5f22ae4c7e4292c9f1b953dc8909ae8fd268f611dc23cbd0") + version("3.2.5", sha256="c8f49dd3b42edcc51d09dd2eea8a92b3cfc987ff7e6486be734b4d0cbfd5d315") + version("3.2.4", sha256="f07043512078c76bb28a62fd1e327876599062b5f0aea60ed1d9cabc42e95fe2") + version("3.2.3", sha256="7e06d934a7718bf3975acbf87780ba678957b87c7adc056f13b6215d610695a0") + version("3.2.2", sha256="f62b1c88ebf5fe95db202a372982970edcf375c1513d7e70717df0750f5c2b98") + version("3.2.1", sha256="57ed0d07634a23bebfa1b02a1aa05eba09c37aab3fc93893e4039e7bc2d96d9e") + version("3.2.0", sha256="cefcbd64acbfc9f38913566824ef070dd9a50e63f1b4cc5a7f1c44be809d7ff3") + version("3.1.4", sha256="865b7ccce5a6e815607b08d9059fe9c058cd75c77f896f5e0b74ff6c1ba81818") + version("3.1.3", sha256="566126b4cbf190c315121965253ecb2159499197ff4afd686e0921f4dd987999") depends_on("py-setuptools", type="build") - depends_on("python@3.5:", type=("build", "run")) - depends_on("python@3.7:", type=("build", "run"), when="@3.5.0:") - depends_on("py-typing-extensions", type=("build", "run"), when="@3.5: ^python@:3.7") + depends_on("py-typing-extensions@4:", type=("build", "run"), when="@3.7: ^python@:3.10") + depends_on("py-typing-extensions", type=("build", "run"), when="@3.5 ^python@:3.7") diff --git a/var/spack/repos/builtin/packages/py-astor/package.py b/var/spack/repos/builtin/packages/py-astor/package.py index 8b7703fc7eb5ad..6664b48b429a08 100644 --- a/var/spack/repos/builtin/packages/py-astor/package.py +++ b/var/spack/repos/builtin/packages/py-astor/package.py @@ -25,7 +25,7 @@ class PyAstor(PythonPackage): # https://github.com/berkerpeksag/astor/issues/162 # https://github.com/berkerpeksag/astor/pull/163 patch( - "https://github.com/berkerpeksag/astor/pull/163/commits/30059dac4eb832e58ab2109db84508b294ba366d.patch?full_index=1", - sha256="edc5eeddabe153b08e938f52edaeb2d880ee3128082967f310db0f98510fe6e0", + "https://github.com/berkerpeksag/astor/commit/30059dac4eb832e58ab2109db84508b294ba366d.patch?full_index=1", + sha256="4993c8d7e36b7fbad7586ff49e57fd8e7abe79724936445db2eed2d91398e82d", when="@0.8.0", ) diff --git a/var/spack/repos/builtin/packages/py-astropy-healpix/package.py b/var/spack/repos/builtin/packages/py-astropy-healpix/package.py index 35a01f483c544e..68791eed29fe9c 100644 --- a/var/spack/repos/builtin/packages/py-astropy-healpix/package.py +++ b/var/spack/repos/builtin/packages/py-astropy-healpix/package.py @@ -21,7 +21,11 @@ class PyAstropyHealpix(PythonPackage): version("0.5", sha256="5ae15da796a840f221fb83e25de791e827b6921bc21a365d99bc1a59c7c0cdad") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type=("build", "run")) depends_on("python@3.6:", type=("build", "run")) depends_on("py-astropy@2.0:", type=("build", "run")) depends_on("py-numpy@1.11:", type=("build", "run")) + # https://github.com/astropy/astropy-healpix/pull/214 + depends_on("py-numpy@:1", when="@:1.0.2", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-astropy-helpers/package.py b/var/spack/repos/builtin/packages/py-astropy-helpers/package.py index bb88d9e98d8ccf..00b2d6a7a2af83 100644 --- a/var/spack/repos/builtin/packages/py-astropy-helpers/package.py +++ b/var/spack/repos/builtin/packages/py-astropy-helpers/package.py @@ -19,5 +19,7 @@ class PyAstropyHelpers(PythonPackage): version("4.0.1", sha256="88602971c3b63d6aaa6074d013f995d1e234acb3d517d70d7fcebd30cdaf5c89") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools@30.3:", type="build") diff --git a/var/spack/repos/builtin/packages/py-astropy-iers-data/package.py b/var/spack/repos/builtin/packages/py-astropy-iers-data/package.py new file mode 100644 index 00000000000000..06345c0a21728f --- /dev/null +++ b/var/spack/repos/builtin/packages/py-astropy-iers-data/package.py @@ -0,0 +1,30 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyAstropyIersData(PythonPackage): + """IERS Earth rotation and leap second table + + Note: This package is not meant for standalone purposes + but is needed by AstroPy.""" + + homepage = "https://github.com/astropy/astropy-iers-data" + pypi = "astropy-iers-data/astropy_iers_data-0.2024.4.29.0.28.48.tar.gz" + + version( + "0.2024.5.20.0.29.40", + sha256="7fff3d3404ae8560533ac0e685db7acc02c4d8984faa4ac3d607096879fba2d1", + ) + version( + "0.2024.4.29.0.28.48", + sha256="a2d5acf97e731f1d4a0eab1c8e4c7f454ddc166af06797b141202dd901bd1dfc", + ) + + depends_on("python@3.8:") + depends_on("py-setuptools", type="build") + depends_on("py-setuptools-scm", type="build") + depends_on("py-wheel", type="build") diff --git a/var/spack/repos/builtin/packages/py-astropy/package.py b/var/spack/repos/builtin/packages/py-astropy/package.py index 7bb70a8fd9ae8a..b60afb07f285bc 100644 --- a/var/spack/repos/builtin/packages/py-astropy/package.py +++ b/var/spack/repos/builtin/packages/py-astropy/package.py @@ -19,6 +19,7 @@ class PyAstropy(PythonPackage): license("BSD-3-Clause") + version("6.1.0", sha256="6c3b915f10b1576190730ddce45f6245f9927dda3de6e3f692db45779708950f") version("5.1", sha256="1db1b2c7eddfc773ca66fa33bd07b25d5b9c3b5eee2b934e0ca277fa5b1b7b7e") version( "4.0.1.post1", sha256="5c304a6c1845ca426e7bc319412b0363fccb4928cb4ba59298acd1918eec44b5" @@ -28,15 +29,23 @@ class PyAstropy(PythonPackage): version("1.1.2", sha256="6f0d84cd7dfb304bb437dda666406a1d42208c16204043bc920308ff8ffdfad1") version("1.1.post1", sha256="64427ec132620aeb038e4d8df94d6c30df4cc8b1c42a6d8c5b09907a31566a21") + depends_on("c", type="build") # generated + variant("all", default=False, when="@3.2:", description="Enable all functionality") # Required dependencies + depends_on("python@3.10:", when="@6.1.0:", type=("build", "run")) depends_on("python@3.8:", when="@5.1:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-cython@0.29.13:", type="build") + depends_on("py-cython@0.29.30", when="@5.1:6.0", type="build") + depends_on("py-cython@3.0.0", when="@6.1.0:", type="build") + # in newer pip versions --install-option does not exist depends_on("py-pip@:23.0", type="build") + depends_on("py-astropy-iers-data", when="@6:", type=("build", "run")) + depends_on("py-numpy@1.23:", when="@6.1:", type=("build", "run")) depends_on("py-numpy@1.18:", when="@5.1:", type=("build", "run")) depends_on("py-numpy@1.16:", when="@4.0:", type=("build", "run")) depends_on("py-numpy@1.13:", when="@3.1:", type=("build", "run")) @@ -44,11 +53,13 @@ class PyAstropy(PythonPackage): depends_on("py-numpy@1.9:", when="@2.0:", type=("build", "run")) depends_on("py-numpy@1.7:", when="@1.2:", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) + # https://github.com/astropy/astropy/issues/16200 + depends_on("py-numpy@:1", when="@:6.0") depends_on("py-packaging@19.0:", when="@5.1:", type=("build", "run")) depends_on("py-pyyaml@3.13:", when="@5.1:", type=("build", "run")) depends_on("py-pyerfa@2.0:", when="@5.1:", type=("build", "run")) + depends_on("py-pyerfa@2.0.1.1:", when="@6.1.0:", type=("build", "run")) depends_on("py-setuptools-scm@6.2:", when="@5.1:", type="build") - depends_on("py-cython@0.29.30", when="@5.1:", type="build") depends_on("py-extension-helpers", when="@5.1:", type="build") depends_on("pkgconfig", type="build") @@ -60,8 +71,10 @@ class PyAstropy(PythonPackage): # Optional dependencies with when("+all"): + depends_on("py-scipy@1.8:", when="@6:", type=("build", "run")) depends_on("py-scipy@1.3:", when="@5:", type=("build", "run")) depends_on("py-scipy@0.18:", type=("build", "run")) + depends_on("py-matplotlib@3.3:", when="@6:", type=("build", "run")) depends_on("py-matplotlib@3.1:", when="@5:", type=("build", "run")) depends_on("py-matplotlib@2.1:", when="@4:", type=("build", "run")) depends_on("py-matplotlib@2.0:", type=("build", "run")) @@ -85,6 +98,8 @@ class PyAstropy(PythonPackage): depends_on("py-ipython", type=("build", "run")) depends_on("py-pytest@7:", when="@5.0.2:", type=("build", "run")) depends_on("py-pytest", type=("build", "run")) + depends_on("py-fsspec+http@2023.4:", when="@6.1:", type=("build", "run")) + depends_on("py-s3fs@2023.4:", when="@6.1:", type=("build", "run")) depends_on("py-typing-extensions@3.10.0.1:", when="@5.0.2:", type=("build", "run")) # Historical optional dependencies diff --git a/var/spack/repos/builtin/packages/py-asyncio/package.py b/var/spack/repos/builtin/packages/py-asyncio/package.py index 6ccaabf25b8c7d..df4549681ba491 100644 --- a/var/spack/repos/builtin/packages/py-asyncio/package.py +++ b/var/spack/repos/builtin/packages/py-asyncio/package.py @@ -21,5 +21,7 @@ class PyAsyncio(PythonPackage): version("3.4.2", sha256="ba28d351c579875e2a1cb1989e310285d3eb76c5bb749694b6ddd3901f8d39de") version("3.4.1", sha256="51cdfbd4964ef8286cbef7d88f9b7abcc8b710ecec0a0794aa354f94ef703126") + depends_on("c", type="build") # generated + depends_on("python@3.3:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-atropos/package.py b/var/spack/repos/builtin/packages/py-atropos/package.py index ac4c4717b365c3..80f38b89ce6179 100644 --- a/var/spack/repos/builtin/packages/py-atropos/package.py +++ b/var/spack/repos/builtin/packages/py-atropos/package.py @@ -18,6 +18,8 @@ class PyAtropos(PythonPackage): version("1.1.22", sha256="05e40cb9337421479c692e1154b962fbf811d7939b72c197a024929b7ae88b78") + depends_on("c", type="build") # generated + depends_on("python@3.3:", type=("build", "run")) depends_on("py-setuptools", type=("build", "run")) depends_on("py-cython@0.25.2:", type="build") diff --git a/var/spack/repos/builtin/packages/py-ats/package.py b/var/spack/repos/builtin/packages/py-ats/package.py index bceb259e2489b1..a37ac3069080d4 100644 --- a/var/spack/repos/builtin/packages/py-ats/package.py +++ b/var/spack/repos/builtin/packages/py-ats/package.py @@ -23,6 +23,9 @@ class PyAts(PythonPackage): version("7.0.100", tag="7.0.100", commit="202c18d11b8f1c14f1a3361a6e45c9e4f83a3fa1") version("7.0.5", tag="7.0.5", commit="86b0b18b96b179f97008393170f5e5bc95118867") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # TODO: Add flux variant when Flux functionality works in ATS depends_on("python@3.8:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-auditwheel/package.py b/var/spack/repos/builtin/packages/py-auditwheel/package.py index 66b216c3c00925..85fc947c1eac23 100644 --- a/var/spack/repos/builtin/packages/py-auditwheel/package.py +++ b/var/spack/repos/builtin/packages/py-auditwheel/package.py @@ -18,6 +18,10 @@ class PyAuditwheel(PythonPackage): version("5.1.2", sha256="3ee5830014931ea84af5cd065c637b6614efa03d9b88bd8fbfc924e7ed01d6ba") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools@45:", type="build") depends_on("py-setuptools-scm@6.2:", type="build") diff --git a/var/spack/repos/builtin/packages/py-autograd/package.py b/var/spack/repos/builtin/packages/py-autograd/package.py index 51512168000fab..c3f76030db69c9 100644 --- a/var/spack/repos/builtin/packages/py-autograd/package.py +++ b/var/spack/repos/builtin/packages/py-autograd/package.py @@ -21,11 +21,17 @@ class PyAutograd(PythonPackage): examples directory.""" homepage = "https://github.com/HIPS/autograd" - pypi = "autograd/autograd-1.3.tar.gz" + pypi = "autograd/autograd-1.6.2.tar.gz" license("MIT") + version("1.6.2", sha256="8731e08a0c4e389d8695a40072ada4512641c113b6cace8f4cfbe8eb7e9aedeb") + version("1.6.1", sha256="dd0068f3f78fd76cf28cee94358737c3b5e8a1d2acac0b850e14d14e1bca84ac") + version("1.6", sha256="b10ad7598bab69251a496210370f7802a21da0ae6a7710197eaae99c3a59b30a") + version("1.5", sha256="d80bd225154d1db13cb4eaccf7a18c358be72092641b68717f96fcf1d16acd0b") + version("1.4", sha256="383de0f537ef2e38b85ff9692593b0cfae8958c9b3bd451b52c255fd9171ffce") version("1.3", sha256="a15d147577e10de037de3740ca93bfa3b5a7cdfbc34cfb9105429c3580a33ec4") + version("1.2", sha256="a08bfa6d539b7a56e7c9f4d0881044afbef5e75f324a394c2494de963ea4a47d") depends_on("py-setuptools", type="build") depends_on("py-future@0.15.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-autoray/package.py b/var/spack/repos/builtin/packages/py-autoray/package.py index e9043a7e902ba6..316596abe3b3c5 100644 --- a/var/spack/repos/builtin/packages/py-autoray/package.py +++ b/var/spack/repos/builtin/packages/py-autoray/package.py @@ -15,6 +15,15 @@ class PyAutoray(PythonPackage): license("Apache-2.0") + version("0.6.9", sha256="9f41759f6a286bc280c4f6aece436da1c87ce75eb00efe7dc7319860c43654fa") + version("0.6.8", sha256="8e31832597cb2075e5f9f65894fafff9d726d9287718415d3c8b008e592f0197") + version("0.6.7", sha256="8945cfdf3aa8a35f9fe1abc03d84925db61f58bbd386623206dd8e9ba1d9e377") + version("0.6.6", sha256="a31cd03f983a6e80b58f40618a652b7979fa09c762050f5dc4b7e6b6a0a3b62d") + version("0.6.5", sha256="093f151539769b03374f67bd2296cf76d359ac190ab6fd8ebe26984a2dc88a4c") + version("0.6.4", sha256="b8e38ff87e2ea1dd8bd17ddd1174f02c41dc4cfec933a3aac9f0516288548e81") + version("0.6.3", sha256="6729f49c8787778fd8bc2a3b57a625c8c21577c6e92628cad4b13aefd7531355") + version("0.6.1", sha256="857cbd4d60d47511ab9956f8765d5fd3c68a538d317cda7d829b00982c599140") + version("0.6.0", sha256="ba3f30812549209bbba9d4976528f3f84bf84c22374699fd2e6aa84bf496d295") version("0.5.3", sha256="ecbecbc1ab65dd704234b3307fa7c7a511a36f6b9339a0ffcdaa4e5a7aab826b") depends_on("python@3.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-awkward-cpp/package.py b/var/spack/repos/builtin/packages/py-awkward-cpp/package.py index 1f6402633be390..ba43f7a3375a79 100644 --- a/var/spack/repos/builtin/packages/py-awkward-cpp/package.py +++ b/var/spack/repos/builtin/packages/py-awkward-cpp/package.py @@ -30,6 +30,8 @@ class PyAwkwardCpp(PythonPackage): version("3", sha256="6070557762bd95d3642ad9c585609db51f899a1e79ce4f41568835efd7d6e066") version("2", sha256="5e63f43e3135f76db81e0924a74ecf4870f585c11a9f432568b377c04028868c") + depends_on("cxx", type="build") # generated + depends_on("python@3.7:", type=("build", "run")) depends_on("py-scikit-build-core@0.2.0:+pyproject", when="@11:", type="build") depends_on("py-pybind11", type=("build", "link")) diff --git a/var/spack/repos/builtin/packages/py-awscrt/package.py b/var/spack/repos/builtin/packages/py-awscrt/package.py index 490c99d4a38783..972477c77539eb 100644 --- a/var/spack/repos/builtin/packages/py-awscrt/package.py +++ b/var/spack/repos/builtin/packages/py-awscrt/package.py @@ -12,12 +12,18 @@ class PyAwscrt(PythonPackage): homepage = "https://docs.aws.amazon.com/sdkref/latest/guide/common-runtime.html" pypi = "awscrt/awscrt-0.16.16.tar.gz" - maintainers("climbfuji") + maintainers("climbfuji", "teaguesterling") license("Apache-2.0") + version("0.20.9", sha256="243785ac9ee64945e0479c2384325545f29597575743ce84c371556d1014e63e") + version("0.19.19", sha256="1c1511535dee146a6c26a382ed3ead56259a105b3b7d7d823553ae567d038dfe") + version("0.19.18", sha256="350b6efd8ebee082ea3f3e52c59a3c3ec594cdaf01db8b4853dceb9fec90c89d") version("0.16.16", sha256="13075df2c1d7942fe22327b6483274517ee0f6ae765c4e6b6ae9ef5b4c43a827") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type=("build")) depends_on("openssl", type=("build"), when="platform=linux") depends_on("py-setuptools", type=("build")) diff --git a/var/spack/repos/builtin/packages/py-azure-cli/package.py b/var/spack/repos/builtin/packages/py-azure-cli/package.py index 43f8f546a812b3..27cb5a34c538d7 100644 --- a/var/spack/repos/builtin/packages/py-azure-cli/package.py +++ b/var/spack/repos/builtin/packages/py-azure-cli/package.py @@ -76,7 +76,7 @@ class PyAzureCli(PythonPackage): depends_on("py-azure-mgmt-recoveryservices@0.4.0:0.4", type=("build", "run")) depends_on("py-azure-mgmt-recoveryservicesbackup@0.6.0:0.6", type=("build", "run")) depends_on("py-azure-mgmt-redhatopenshift@0.1.0", type=("build", "run")) - depends_on("py-azure-mgmt-redis@7.0.0:7.0", type=("build", "run")) + depends_on("py-azure-mgmt-redis@7.0", type=("build", "run")) depends_on("py-azure-mgmt-relay@0.1.0:0.1", type=("build", "run")) depends_on("py-azure-mgmt-reservations@0.6.0", type=("build", "run")) depends_on("py-azure-mgmt-search@2.0:2", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azure-mgmt-storage/package.py b/var/spack/repos/builtin/packages/py-azure-mgmt-storage/package.py index 5e16d385184efb..9fccff50ac2df2 100644 --- a/var/spack/repos/builtin/packages/py-azure-mgmt-storage/package.py +++ b/var/spack/repos/builtin/packages/py-azure-mgmt-storage/package.py @@ -13,6 +13,8 @@ class PyAzureMgmtStorage(PythonPackage): homepage = "https://github.com/Azure/azure-sdk-for-python" pypi = "azure-mgmt-storage/azure-mgmt-storage-11.1.0.zip" + version("21.0.0", sha256="6eb13eeecf89195b2b5f47be0679e3f27888efd7bd2132eec7ebcbce75cb1377") + version("20.1.0", sha256="214f3fde8c91e27d53f2e654a28d15003ad3f6f15c8438a8205f0c88a48d9451") version("11.1.0", sha256="ef23587c1b6dc0866ebf0e91e83ba05d7f7e4fea7951b704781b9cd9f5f27f1c") version("11.0.0", sha256="f9791c2a84eee0a55bbf757632a2a4d1e102db958e75422d5e0e7306041129b8") diff --git a/var/spack/repos/builtin/packages/py-azureml-automl-core/package.py b/var/spack/repos/builtin/packages/py-azureml-automl-core/package.py index 1f1730659c55cc..87d51dfccdbd77 100644 --- a/var/spack/repos/builtin/packages/py-azureml-automl-core/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-automl-core/package.py @@ -14,11 +14,7 @@ class PyAzuremlAutomlCore(PythonPackage): homepage = "https://docs.microsoft.com/en-us/azure/machine-learning/service/" url = "https://pypi.io/packages/py3/a/azureml_automl_core/azureml_automl_core-1.11.0-py3-none-any.whl" - version( - "1.23.0", - sha256="1fa4a900856b15e1ec9a6bb949946ed0c873a5a54da3db592f03dbb46a117ceb", - expand=False, - ) + version("1.23.0", sha256="1fa4a900856b15e1ec9a6bb949946ed0c873a5a54da3db592f03dbb46a117ceb") depends_on("python@3.5:3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azureml-core/package.py b/var/spack/repos/builtin/packages/py-azureml-core/package.py index f5c55597801993..2ce6c6b7272124 100644 --- a/var/spack/repos/builtin/packages/py-azureml-core/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-core/package.py @@ -17,21 +17,9 @@ class PyAzuremlCore(PythonPackage): homepage = "https://docs.microsoft.com/en-us/azure/machine-learning/service/" url = "https://pypi.io/packages/py3/a/azureml_core/azureml_core-1.11.0-py3-none-any.whl" - version( - "1.23.0", - sha256="0965d0741e39cdb95cff5880dbf1a55fdd87cd9fc316884f965668e6cc36e628", - expand=False, - ) - version( - "1.11.0", - sha256="df8a01b04bb156852480de0bdd78434ed84f386e1891752bdf887faeaa2ca417", - expand=False, - ) - version( - "1.8.0", - sha256="a0f2b0977f18fb7dcb88c314594a4a85c636a36be3d582be1cae25655fea6105", - expand=False, - ) + version("1.23.0", sha256="0965d0741e39cdb95cff5880dbf1a55fdd87cd9fc316884f965668e6cc36e628") + version("1.11.0", sha256="df8a01b04bb156852480de0bdd78434ed84f386e1891752bdf887faeaa2ca417") + version("1.8.0", sha256="a0f2b0977f18fb7dcb88c314594a4a85c636a36be3d582be1cae25655fea6105") depends_on("python@3.5:3.8", type=("build", "run")) depends_on("py-pytz", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azureml-dataprep-native/package.py b/var/spack/repos/builtin/packages/py-azureml-dataprep-native/package.py index 214d8c7751949b..405dcac6330c59 100644 --- a/var/spack/repos/builtin/packages/py-azureml-dataprep-native/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-dataprep-native/package.py @@ -13,17 +13,17 @@ class PyAzuremlDataprepNative(PythonPackage): homepage = "https://docs.microsoft.com/en-us/python/api/overview/azure/ml/?view=azure-ml-py" + skip_version_audit = ["platform=windows"] + if sys.platform == "darwin": version( "30.0.0-py3.9", sha256="eaf3fcd9f965e87b03fe89d7c6fe6abce53483a79afc963e4981061f4c250e85", - expand=False, url="https://pypi.io/packages/cp39/a/azureml_dataprep_native/azureml_dataprep_native-30.0.0-cp39-cp39-macosx_10_9_x86_64.whl", ) version( "30.0.0-py3.8", sha256="6772b638f9d03a041b17ce4343061f5d543019200904b9d361b2b2629c3595a7", - expand=False, preferred=True, url="https://pypi.io/packages/cp38/a/azureml_dataprep_native/azureml_dataprep_native-30.0.0-cp38-cp38-macosx_10_9_x86_64.whl", ) @@ -31,13 +31,11 @@ class PyAzuremlDataprepNative(PythonPackage): version( "30.0.0-py3.9", sha256="b8673136948f682c84d047feacbfee436df053cba4f386f31c4c3a245a4e3646", - expand=False, url="https://pypi.io/packages/cp39/a/azureml_dataprep_native/azureml_dataprep_native-30.0.0-cp39-cp39-manylinux1_x86_64.whl", ) version( "30.0.0-py3.8", sha256="d07cf20f22b14c98576e135bbad9bb8aaa3108941d2beaadf050b4238bc93a18", - expand=False, preferred=True, url="https://pypi.io/packages/cp38/a/azureml_dataprep_native/azureml_dataprep_native-30.0.0-cp38-cp38-manylinux1_x86_64.whl", ) diff --git a/var/spack/repos/builtin/packages/py-azureml-dataprep-rslex/package.py b/var/spack/repos/builtin/packages/py-azureml-dataprep-rslex/package.py index f45d451a0b91e9..c7ade72fee306d 100644 --- a/var/spack/repos/builtin/packages/py-azureml-dataprep-rslex/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-dataprep-rslex/package.py @@ -16,17 +16,17 @@ class PyAzuremlDataprepRslex(PythonPackage): homepage = "https://docs.microsoft.com/en-us/python/api/overview/azure/ml/?view=azure-ml-py" + skip_version_audit = ["platform=windows"] + if sys.platform == "darwin": version( "1.9.0-py3.9", sha256="9bdaa31d129dac19ee20d5a3aad1726397e90d8d741b4f6de4554040800fefe8", - expand=False, url="https://pypi.io/packages/cp39/a/azureml_dataprep_rslex/azureml_dataprep_rslex-1.9.0-cp39-cp39-macosx_10_9_x86_64.whl", ) version( "1.9.0-py3.8", sha256="9b2e741ac1c53d3f7e6061d264feccf157d97e404c772933a176e6021014484e", - expand=False, preferred=True, url="https://pypi.io/packages/cp38/a/azureml_dataprep_rslex/azureml_dataprep_rslex-1.9.0-cp38-cp38-macosx_10_9_x86_64.whl", ) @@ -34,26 +34,22 @@ class PyAzuremlDataprepRslex(PythonPackage): version( "1.8.0-py3.9", sha256="677c25a7e23ec7f91d25aa596f382f7f3b6d60fbc3258bead2b2a6aa42f3a16d", - expand=False, url="https://pypi.io/packages/cp39/a/azureml_dataprep_rslex/azureml_dataprep_rslex-1.8.0-cp39-cp39-macosx_10_9_x86_64.whl", ) version( "1.8.0-py3.8", sha256="d7f2dec06296544b1707f5b01c6a4eaad744b4abfe9e8e89830b561c84d95a7a", - expand=False, url="https://pypi.io/packages/cp38/a/azureml_dataprep_rslex/azureml_dataprep_rslex-1.8.0-cp38-cp38-macosx_10_9_x86_64.whl", ) elif sys.platform.startswith("linux"): version( "1.9.0-py3.9", sha256="79d52bb427e3ca781a645c4f11f7a8e5e2c8f61e61bfc162b4062d8e47bcf3d6", - expand=False, url="https://pypi.io/packages/cp39/a/azureml_dataprep_rslex/azureml_dataprep_rslex-1.9.0-cp39-cp39-manylinux1_x86_64.whl", ) version( "1.9.0-py3.8", sha256="a52461103b45867dd919bab593bb6f2426c9b5f5a435081e82a3c57c54c3add6", - expand=False, preferred=True, url="https://pypi.io/packages/cp38/a/azureml_dataprep_rslex/azureml_dataprep_rslex-1.9.0-cp38-cp38-manylinux1_x86_64.whl", ) @@ -61,13 +57,11 @@ class PyAzuremlDataprepRslex(PythonPackage): version( "1.8.0-py3.9", sha256="e251a077669703ca117b157b225fbc20832169f913476cf79c01a5c6f8ff7a50", - expand=False, url="https://pypi.io/packages/cp39/a/azureml_dataprep_rslex/azureml_dataprep_rslex-1.8.0-cp39-cp39-manylinux1_x86_64.whl", ) version( "1.8.0-py3.8", sha256="2ebfa164f0933a5cec383cd27ba10d33861a73237ef481ada5a9a822bb55514a", - expand=False, url="https://pypi.io/packages/cp38/a/azureml_dataprep_rslex/azureml_dataprep_rslex-1.8.0-cp38-cp38-manylinux1_x86_64.whl", ) diff --git a/var/spack/repos/builtin/packages/py-azureml-dataprep/package.py b/var/spack/repos/builtin/packages/py-azureml-dataprep/package.py index bbeeb76cccf80d..90bfdae74e092a 100644 --- a/var/spack/repos/builtin/packages/py-azureml-dataprep/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-dataprep/package.py @@ -13,16 +13,8 @@ class PyAzuremlDataprep(PythonPackage): homepage = "https://docs.microsoft.com/en-us/python/api/overview/azure/ml/?view=azure-ml-py" url = "https://pypi.io/packages/py3/a/azureml_dataprep/azureml_dataprep-2.0.2-py3-none-any.whl" - version( - "2.11.0", - sha256="755c0d7cfe228705aee7adc97813fb6d7d6ecb048b66f47c1fd5897f2709c3a2", - expand=False, - ) - version( - "2.10.1", - sha256="a36f807112ff1e64d21265b8e7f40154c93e3bead539e2a74c9d74200fd77c86", - expand=False, - ) + version("2.11.0", sha256="755c0d7cfe228705aee7adc97813fb6d7d6ecb048b66f47c1fd5897f2709c3a2") + version("2.10.1", sha256="a36f807112ff1e64d21265b8e7f40154c93e3bead539e2a74c9d74200fd77c86") variant("fuse", default=False, description="Build with FUSE support") diff --git a/var/spack/repos/builtin/packages/py-azureml-dataset-runtime/package.py b/var/spack/repos/builtin/packages/py-azureml-dataset-runtime/package.py index 56878089a0e127..7399b0832a5ef0 100644 --- a/var/spack/repos/builtin/packages/py-azureml-dataset-runtime/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-dataset-runtime/package.py @@ -14,11 +14,7 @@ class PyAzuremlDatasetRuntime(PythonPackage): homepage = "https://docs.microsoft.com/en-us/azure/machine-learning/service/" url = "https://pypi.io/packages/py3/a/azureml-dataset-runtime/azureml_dataset_runtime-1.11.0.post1-py3-none-any.whl" - version( - "1.23.0", - sha256="96ca73d03ffedc0dd336d9383d2e17cf74548a89fc7ca4c201c599817c97bbc6", - expand=False, - ) + version("1.23.0", sha256="96ca73d03ffedc0dd336d9383d2e17cf74548a89fc7ca4c201c599817c97bbc6") variant("fuse", default=False, description="Build with FUSE support") diff --git a/var/spack/repos/builtin/packages/py-azureml-pipeline-core/package.py b/var/spack/repos/builtin/packages/py-azureml-pipeline-core/package.py index 4542e001fb9d26..8a9f3bd4021785 100644 --- a/var/spack/repos/builtin/packages/py-azureml-pipeline-core/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-pipeline-core/package.py @@ -13,21 +13,9 @@ class PyAzuremlPipelineCore(PythonPackage): homepage = "https://docs.microsoft.com/en-us/azure/machine-learning/service/" url = "https://pypi.io/packages/py3/a/azureml_pipeline_core/azureml_pipeline_core-1.11.0-py3-none-any.whl" - version( - "1.23.0", - sha256="347e3e41559879611d53eeff5c05dd133db6fa537edcf2b9f70d91aad461df02", - expand=False, - ) - version( - "1.11.0", - sha256="98012195e3bba12bf42ac69179549038b3563b39e3dadab4f1d06407a00ad8b3", - expand=False, - ) - version( - "1.8.0", - sha256="24e1c57a57e75f9d74ea6f45fa4e93c1ee3114c8ed9029d538f9cc8e4f8945b2", - expand=False, - ) + version("1.23.0", sha256="347e3e41559879611d53eeff5c05dd133db6fa537edcf2b9f70d91aad461df02") + version("1.11.0", sha256="98012195e3bba12bf42ac69179549038b3563b39e3dadab4f1d06407a00ad8b3") + version("1.8.0", sha256="24e1c57a57e75f9d74ea6f45fa4e93c1ee3114c8ed9029d538f9cc8e4f8945b2") depends_on("python@3.5:3", type=("build", "run")) depends_on("py-azureml-core@1.23.0:1.23", when="@1.23.0", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azureml-pipeline-steps/package.py b/var/spack/repos/builtin/packages/py-azureml-pipeline-steps/package.py index 6598be7b57b5d8..e2dcd81f772573 100644 --- a/var/spack/repos/builtin/packages/py-azureml-pipeline-steps/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-pipeline-steps/package.py @@ -13,11 +13,7 @@ class PyAzuremlPipelineSteps(PythonPackage): homepage = "https://docs.microsoft.com/en-us/azure/machine-learning/service/" url = "https://pypi.io/packages/py3/a/azureml_pipeline_steps/azureml_pipeline_steps-1.11.0-py3-none-any.whl" - version( - "1.23.0", - sha256="72154c2f75624a1e7500b8e2239ae1354eeedf66d2cabb11e213b7eb80aedddb", - expand=False, - ) + version("1.23.0", sha256="72154c2f75624a1e7500b8e2239ae1354eeedf66d2cabb11e213b7eb80aedddb") depends_on("python@3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azureml-pipeline/package.py b/var/spack/repos/builtin/packages/py-azureml-pipeline/package.py index cecf981ab91e25..e8d732cb5944db 100644 --- a/var/spack/repos/builtin/packages/py-azureml-pipeline/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-pipeline/package.py @@ -16,11 +16,7 @@ class PyAzuremlPipeline(PythonPackage): "https://pypi.io/packages/py3/a/azureml_pipeline/azureml_pipeline-1.11.0-py3-none-any.whl" ) - version( - "1.23.0", - sha256="ed0fae96771840d3ffd63d63df1b1eed2f50c3b8dbe7b672a4f1ba6e66d0a392", - expand=False, - ) + version("1.23.0", sha256="ed0fae96771840d3ffd63d63df1b1eed2f50c3b8dbe7b672a4f1ba6e66d0a392") depends_on("python@3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azureml-sdk/package.py b/var/spack/repos/builtin/packages/py-azureml-sdk/package.py index 8e613aee9eb65c..9c9f571ec82a9b 100644 --- a/var/spack/repos/builtin/packages/py-azureml-sdk/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-sdk/package.py @@ -15,11 +15,7 @@ class PyAzuremlSdk(PythonPackage): maintainers("adamjstewart") - version( - "1.23.0", - sha256="b9520f426831acb99fafa1ecd154b6bfd4f73fbf71e918d819f9db4a75438ab9", - expand=False, - ) + version("1.23.0", sha256="b9520f426831acb99fafa1ecd154b6bfd4f73fbf71e918d819f9db4a75438ab9") # https://github.com/Azure/MachineLearningNotebooks/issues/1285 depends_on("python@3.5:3.8", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azureml-telemetry/package.py b/var/spack/repos/builtin/packages/py-azureml-telemetry/package.py index 89e5f6a5a51593..69f2d1bd8133db 100644 --- a/var/spack/repos/builtin/packages/py-azureml-telemetry/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-telemetry/package.py @@ -14,21 +14,9 @@ class PyAzuremlTelemetry(PythonPackage): homepage = "https://docs.microsoft.com/en-us/azure/machine-learning/service/" url = "https://pypi.io/packages/py3/a/azureml_telemetry/azureml_telemetry-1.11.0-py3-none-any.whl" - version( - "1.23.0", - sha256="68f9aac77e468db80e60f75d0843536082e2884ab251b6d3054dd623bd9c9e0d", - expand=False, - ) - version( - "1.11.0", - sha256="0d46c4a7bb8c0b188f1503504a6029384bc2237d82a131e7d1e9e89c3491b1fc", - expand=False, - ) - version( - "1.8.0", - sha256="de657efe9773bea0de76c432cbab34501ac28606fe1b380d6883562ebda3d804", - expand=False, - ) + version("1.23.0", sha256="68f9aac77e468db80e60f75d0843536082e2884ab251b6d3054dd623bd9c9e0d") + version("1.11.0", sha256="0d46c4a7bb8c0b188f1503504a6029384bc2237d82a131e7d1e9e89c3491b1fc") + version("1.8.0", sha256="de657efe9773bea0de76c432cbab34501ac28606fe1b380d6883562ebda3d804") depends_on("python@3.5:3", type=("build", "run")) depends_on("py-applicationinsights", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azureml-train-automl-client/package.py b/var/spack/repos/builtin/packages/py-azureml-train-automl-client/package.py index bd676ef78c65aa..baabe2705aae7a 100644 --- a/var/spack/repos/builtin/packages/py-azureml-train-automl-client/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-train-automl-client/package.py @@ -15,11 +15,7 @@ class PyAzuremlTrainAutomlClient(PythonPackage): homepage = "https://docs.microsoft.com/en-us/azure/machine-learning/service/" url = "https://pypi.io/packages/py3/a/azureml_train_automl_client/azureml_train_automl_client-1.11.0-py3-none-any.whl" - version( - "1.23.0", - sha256="ac5f1ce9b04b4e61e2e28e0fa8d2d8e47937a546f624d1cd3aa6bc4f9110ecbe", - expand=False, - ) + version("1.23.0", sha256="ac5f1ce9b04b4e61e2e28e0fa8d2d8e47937a546f624d1cd3aa6bc4f9110ecbe") depends_on("python@3.5:3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azureml-train-core/package.py b/var/spack/repos/builtin/packages/py-azureml-train-core/package.py index 55a18dc6254992..d67049ca7dbce8 100644 --- a/var/spack/repos/builtin/packages/py-azureml-train-core/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-train-core/package.py @@ -14,21 +14,9 @@ class PyAzuremlTrainCore(PythonPackage): homepage = "https://docs.microsoft.com/en-us/azure/machine-learning/service/" url = "https://pypi.io/packages/py3/a/azureml_train_core/azureml_train_core-1.11.0-py3-none-any.whl" - version( - "1.23.0", - sha256="5c384ea0bea3ecd8bf2a1832dda906fd183cf2a03ad3372cb824ce8fa417979e", - expand=False, - ) - version( - "1.11.0", - sha256="1b5fd813d21e75cd522d3a078eba779333980a309bcff6fc72b74ddc8e7a26f1", - expand=False, - ) - version( - "1.8.0", - sha256="5a8d90a08d4477527049d793feb40d07dc32fafc0e4e57b4f0729d3c50b408a2", - expand=False, - ) + version("1.23.0", sha256="5c384ea0bea3ecd8bf2a1832dda906fd183cf2a03ad3372cb824ce8fa417979e") + version("1.11.0", sha256="1b5fd813d21e75cd522d3a078eba779333980a309bcff6fc72b74ddc8e7a26f1") + version("1.8.0", sha256="5a8d90a08d4477527049d793feb40d07dc32fafc0e4e57b4f0729d3c50b408a2") depends_on("python@3.5:3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azureml-train-restclients-hyperdrive/package.py b/var/spack/repos/builtin/packages/py-azureml-train-restclients-hyperdrive/package.py index e0ec281e5ec31f..2d0d2186a5d6b7 100644 --- a/var/spack/repos/builtin/packages/py-azureml-train-restclients-hyperdrive/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-train-restclients-hyperdrive/package.py @@ -14,21 +14,9 @@ class PyAzuremlTrainRestclientsHyperdrive(PythonPackage): homepage = "https://docs.microsoft.com/en-us/azure/machine-learning/service/" url = "https://pypi.io/packages/py3/a/azureml_train_restclients_hyperdrive/azureml_train_restclients_hyperdrive-1.11.0-py3-none-any.whl" - version( - "1.23.0", - sha256="8ecee0cdb92a4a431b778ebcc7f9fe7c5bf63ea4cae9caa687980bc34ae3a42c", - expand=False, - ) - version( - "1.11.0", - sha256="8bc6f9676a9f75e6ee06d201c418ea904c24e854f26cf799b08c259c3ac92d13", - expand=False, - ) - version( - "1.8.0", - sha256="1633c7eb0fd96714f54f72072ccf1c5ee1ef0a8ba52680793f20d27e0fd43c87", - expand=False, - ) + version("1.23.0", sha256="8ecee0cdb92a4a431b778ebcc7f9fe7c5bf63ea4cae9caa687980bc34ae3a42c") + version("1.11.0", sha256="8bc6f9676a9f75e6ee06d201c418ea904c24e854f26cf799b08c259c3ac92d13") + version("1.8.0", sha256="1633c7eb0fd96714f54f72072ccf1c5ee1ef0a8ba52680793f20d27e0fd43c87") depends_on("python@3.5:3", type=("build", "run")) depends_on("py-requests@2.19.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-azureml-train/package.py b/var/spack/repos/builtin/packages/py-azureml-train/package.py index 9c2ae180939497..329387fe06ae3b 100644 --- a/var/spack/repos/builtin/packages/py-azureml-train/package.py +++ b/var/spack/repos/builtin/packages/py-azureml-train/package.py @@ -15,21 +15,9 @@ class PyAzuremlTrain(PythonPackage): homepage = "https://docs.microsoft.com/en-us/azure/machine-learning/service/" url = "https://pypi.io/packages/py3/a/azureml_train/azureml_train-1.11.0-py3-none-any.whl" - version( - "1.23.0", - sha256="e16cb8673d9c9c70966c37c7362ceed3514e9797b0816c0aa449730da3b9c857", - expand=False, - ) - version( - "1.11.0", - sha256="7800a3067979972b976c81082dc509e23c04405129cc1fdef0f9cd7895bcafc7", - expand=False, - ) - version( - "1.8.0", - sha256="124e5b7d8d64bac61db022f305bd31c25e57fdcb4be93eefd4244a04a13deab3", - expand=False, - ) + version("1.23.0", sha256="e16cb8673d9c9c70966c37c7362ceed3514e9797b0816c0aa449730da3b9c857") + version("1.11.0", sha256="7800a3067979972b976c81082dc509e23c04405129cc1fdef0f9cd7895bcafc7") + version("1.8.0", sha256="124e5b7d8d64bac61db022f305bd31c25e57fdcb4be93eefd4244a04a13deab3") depends_on("python@3.5:3", type=("build", "run")) depends_on("py-azureml-train-core@1.23.0:1.23", when="@1.23.0", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-babel/package.py b/var/spack/repos/builtin/packages/py-babel/package.py index 1c73663fed2e34..c1a56e434b1366 100644 --- a/var/spack/repos/builtin/packages/py-babel/package.py +++ b/var/spack/repos/builtin/packages/py-babel/package.py @@ -12,11 +12,12 @@ class PyBabel(PythonPackage): emphasis on web-based applications.""" homepage = "https://babel.pocoo.org/en/latest/" - pypi = "Babel/Babel-2.7.0.tar.gz" + pypi = "Babel/babel-2.15.0.tar.gz" git = "https://github.com/python-babel/babel" license("BSD-3-Clause") + version("2.15.0", sha256="8daf0e265d05768bc6c7a314cf1321e9a123afc328cc635c18622a2f30a04413") version("2.12.1", sha256="cc2d99999cd01d44420ae725a21c9e3711b3aadc7976d6147f622d8581963455") version("2.10.3", sha256="7614553711ee97490f732126dc077f8d0ae084ebc6a96e23db1482afabdb2c51") version("2.9.1", sha256="bc0c176f9f6a994582230df350aa6e05ba2ebe4b3ac317eab29d9be5d2768da0") @@ -28,3 +29,10 @@ class PyBabel(PythonPackage): depends_on("py-setuptools", type=("build", "run")) depends_on("py-pytz@2015.7:", when="@2.12: ^python@:3.8", type=("build", "run")) depends_on("py-pytz@2015.7:", when="@:2.10", type=("build", "run")) + + def url_for_version(self, version): + url = "https://files.pythonhosted.org/packages/source/B/Babel/{}-{}.tar.gz" + name = "Babel" + if version >= Version("2.15"): + name = name.lower() + return url.format(name, version) diff --git a/var/spack/repos/builtin/packages/py-backports-lzma/package.py b/var/spack/repos/builtin/packages/py-backports-lzma/package.py index d0fd466db745ef..5539e26a851598 100644 --- a/var/spack/repos/builtin/packages/py-backports-lzma/package.py +++ b/var/spack/repos/builtin/packages/py-backports-lzma/package.py @@ -26,5 +26,7 @@ class PyBackportsLzma(PythonPackage): version("0.0.6", sha256="8e70936641398a6814d70f6eae6399be2ae514578d38b7f9b15c277438bbd853") version("0.0.4", sha256="7c973edbd50c1467fed2247117e128a924d25404394a57e30d5b6c52cfcd342d") + depends_on("c", type="build") # generated + depends_on("python@2.6:3.0,3.4:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-backports-zoneinfo/package.py b/var/spack/repos/builtin/packages/py-backports-zoneinfo/package.py index 546c9e993bb114..cebdb80ab4ce68 100644 --- a/var/spack/repos/builtin/packages/py-backports-zoneinfo/package.py +++ b/var/spack/repos/builtin/packages/py-backports-zoneinfo/package.py @@ -16,4 +16,6 @@ class PyBackportsZoneinfo(PythonPackage): version("0.2.1", sha256="fadbfe37f74051d024037f223b8e001611eac868b5c5b06144ef4d8b799862f2") + depends_on("c", type="build") # generated + depends_on("py-setuptools@40.8.0:", type="build") diff --git a/var/spack/repos/builtin/packages/py-basemap/package.py b/var/spack/repos/builtin/packages/py-basemap/package.py index b5b4bae220a64e..424d696e460c86 100644 --- a/var/spack/repos/builtin/packages/py-basemap/package.py +++ b/var/spack/repos/builtin/packages/py-basemap/package.py @@ -17,6 +17,9 @@ class PyBasemap(PythonPackage): version("1.2.1", sha256="3fb30424f18cd4ffd505e30fd9c810ae81b999bb92f950c76553e1abc081faa7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Per Github issue #3813, setuptools is required at runtime in order # to make mpl_toolkits a namespace package that can span multiple # directories (i.e., matplotlib and basemap) diff --git a/var/spack/repos/builtin/packages/py-bcolz/package.py b/var/spack/repos/builtin/packages/py-bcolz/package.py index 9bfbd7839bef94..208f2ff90ab377 100644 --- a/var/spack/repos/builtin/packages/py-bcolz/package.py +++ b/var/spack/repos/builtin/packages/py-bcolz/package.py @@ -20,6 +20,9 @@ class PyBcolz(PythonPackage): version("1.2.1", sha256="c017d09bb0cb5bbb07f2ae223a3f3638285be3b574cb328e91525b2880300bd1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@2.7:2.8,3.5:", type=("build", "run")) depends_on("py-numpy@1.7:", type=("build", "run")) depends_on("py-setuptools@18.1:", type="build") diff --git a/var/spack/repos/builtin/packages/py-bcrypt/package.py b/var/spack/repos/builtin/packages/py-bcrypt/package.py index d2021ea9e066d6..ca94d6cc162b93 100644 --- a/var/spack/repos/builtin/packages/py-bcrypt/package.py +++ b/var/spack/repos/builtin/packages/py-bcrypt/package.py @@ -19,6 +19,8 @@ class PyBcrypt(PythonPackage): version("3.1.6", sha256="169d3e6edbf8717e8856748b72fb02abe8ce8e0b65d733b1509ae9942e77f2a9") version("3.1.4", sha256="ca122a2cdcdffb0fd04f9dfe3493766f298bef02dea2f190f35ea6fdee222b96") + depends_on("c", type="build") # generated + depends_on("python@3.6:", when="@3.2:", type="build") depends_on("python@2.7:2,3.4:", when="@3.1.6:", type="build") depends_on("py-setuptools@40.8:", when="@3.1.7:", type="build") diff --git a/var/spack/repos/builtin/packages/py-beancount/package.py b/var/spack/repos/builtin/packages/py-beancount/package.py index 9c9ec496e849ec..1f9594defb320c 100644 --- a/var/spack/repos/builtin/packages/py-beancount/package.py +++ b/var/spack/repos/builtin/packages/py-beancount/package.py @@ -19,6 +19,8 @@ class PyBeancount(PythonPackage): version("2.3.3", sha256="d9a29839ea867d1dda7af1f4bf5d3959aa7c1574cd4a0bc86f69ee64c555c71c") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type=("build")) diff --git a/var/spack/repos/builtin/packages/py-bigdft/package.py b/var/spack/repos/builtin/packages/py-bigdft/package.py index cae97858e1d599..2251438053ed6e 100644 --- a/var/spack/repos/builtin/packages/py-bigdft/package.py +++ b/var/spack/repos/builtin/packages/py-bigdft/package.py @@ -19,6 +19,10 @@ class PyBigdft(PythonPackage): version("1.9.1", sha256="3c334da26d2a201b572579fc1a7f8caad1cbf971e848a3e10d83bc4dc8c82e41") version("1.9.0", sha256="4500e505f5a29d213f678a91d00a10fef9dc00860ea4b3edf9280f33ed0d1ac8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("python@3.0:", type=("build", "run")) depends_on("py-numpy") depends_on("py-setuptools") diff --git a/var/spack/repos/builtin/packages/py-bigfloat/package.py b/var/spack/repos/builtin/packages/py-bigfloat/package.py index 1044b752920734..83c35e24ae9554 100644 --- a/var/spack/repos/builtin/packages/py-bigfloat/package.py +++ b/var/spack/repos/builtin/packages/py-bigfloat/package.py @@ -16,6 +16,8 @@ class PyBigfloat(PythonPackage): version("0.4.0", sha256="58b96bde872aca5989d13d82eba3acf2aa1b94e22117dd72a16ba5911b0c0cb8") + depends_on("c", type="build") # generated + depends_on("python@2.7:2.8,3.5:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-six", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-billiard/package.py b/var/spack/repos/builtin/packages/py-billiard/package.py index 3a7802d4e61b21..1dad47a3c444d4 100644 --- a/var/spack/repos/builtin/packages/py-billiard/package.py +++ b/var/spack/repos/builtin/packages/py-billiard/package.py @@ -13,10 +13,13 @@ class PyBilliard(PythonPackage): license("BSD-3-Clause") + version("4.2.0", sha256="9a3c3184cb275aa17a732f93f65b20c525d3d9f253722d26a82194803ade5a2c") version("3.6.4.0", sha256="299de5a8da28a783d51b197d496bef4f1595dd023a93a4f59dde1886ae905547") version("3.6.3.0", sha256="d91725ce6425f33a97dfa72fb6bfef0e47d4652acd98a032bd1a7fbf06d5fa6a") version("3.6.1.0", sha256="b8809c74f648dfe69b973c8e660bcec00603758c9db8ba89d7719f88d5f01f26") version("3.6.0.0", sha256="756bf323f250db8bf88462cd042c992ba60d8f5e07fc5636c24ba7d6f4261d84") version("3.5.0.5", sha256="42d9a227401ac4fba892918bba0a0c409def5435c4b483267ebfe821afaaba0e") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-biopython/package.py b/var/spack/repos/builtin/packages/py-biopython/package.py index fa3cdeefcc031b..822321ba889c06 100644 --- a/var/spack/repos/builtin/packages/py-biopython/package.py +++ b/var/spack/repos/builtin/packages/py-biopython/package.py @@ -27,10 +27,14 @@ class PyBiopython(PythonPackage): version("1.70", sha256="4a7c5298f03d1a45523f32bae1fffcff323ea9dce007fb1241af092f5ab2e45b") version("1.65", sha256="6d591523ba4d07a505978f6e1d7fac57e335d6d62fb5b0bcb8c40bdde5c8998e") - depends_on("python@2.6:2.7,3.3:", type=("build", "run"), when="@1.63:1.68") - depends_on("python@2.7,3.3:", type=("build", "run"), when="@1.69") - depends_on("python@2.7,3.4:", type=("build", "run"), when="@1.70:1.74") - depends_on("python@2.7,3.5:", type=("build", "run"), when="@1.75:1.76") + depends_on("c", type="build") # generated + + depends_on("python@2.6:2.7,3.3:3.9", type=("build", "run"), when="@1.63:1.68") + depends_on("python@2.7,3.3:3.9", type=("build", "run"), when="@1.69") + depends_on("python@2.7,3.4:3.9", type=("build", "run"), when="@1.70:1.74") + depends_on("python@2.7,3.5:3.9", type=("build", "run"), when="@1.75:1.76") depends_on("python@3.6:", type=("build", "run"), when="@1.77:") depends_on("py-numpy", type=("build", "run")) + # https://github.com/biopython/biopython/issues/4676 + depends_on("py-numpy@:1", when="@:1.83", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-bitarray/package.py b/var/spack/repos/builtin/packages/py-bitarray/package.py index 47ae50a3dcb8b4..0724fb3b49f252 100644 --- a/var/spack/repos/builtin/packages/py-bitarray/package.py +++ b/var/spack/repos/builtin/packages/py-bitarray/package.py @@ -16,4 +16,6 @@ class PyBitarray(PythonPackage): version("2.6.0", sha256="56d3f16dd807b1c56732a244ce071c135ee973d3edc9929418c1b24c5439a0fd") version("0.8.1", sha256="7da501356e48a83c61f479393681c1bc4b94e5a34ace7e08cb29e7dd9290ab18") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-bitshuffle/package.py b/var/spack/repos/builtin/packages/py-bitshuffle/package.py index b41636ab2d4fc0..357d9bbabefa66 100644 --- a/var/spack/repos/builtin/packages/py-bitshuffle/package.py +++ b/var/spack/repos/builtin/packages/py-bitshuffle/package.py @@ -17,6 +17,8 @@ class PyBitshuffle(PythonPackage): version("0.4.2", sha256="df7d7dc0add8a37f0c5f4704475db60a3c843171a49aa4e3301d1d7e827b2536") + depends_on("c", type="build") # generated + depends_on("py-cython@0.19:", type="build") depends_on("py-setuptools@0.7:", type="build") depends_on("py-numpy@1.6.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-bitstruct/package.py b/var/spack/repos/builtin/packages/py-bitstruct/package.py index d009d50c4e6b57..d510b7c766a6d0 100644 --- a/var/spack/repos/builtin/packages/py-bitstruct/package.py +++ b/var/spack/repos/builtin/packages/py-bitstruct/package.py @@ -20,4 +20,6 @@ class PyBitstruct(PythonPackage): version("8.17.0", sha256="eb94b40e4218a23aa8f90406b836a9e6ed83e48b8d112ce3f96408463bd1b874") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-black/package.py b/var/spack/repos/builtin/packages/py-black/package.py index 17bae601c39aaa..d68ecc57e6e9f6 100644 --- a/var/spack/repos/builtin/packages/py-black/package.py +++ b/var/spack/repos/builtin/packages/py-black/package.py @@ -15,9 +15,8 @@ class PyBlack(PythonPackage): homepage = "https://github.com/psf/black" pypi = "black/black-22.1.0.tar.gz" - maintainers("adamjstewart") - license("MIT", checked_by="tgamblin") + maintainers("spack/spack-releasers") version("24.3.0", sha256="a0c9c4a0771afc6919578cec71ce82a3e31e054904e7197deacbc9382671c41f") version("24.2.0", sha256="bce4f25c27c3435e4dace4815bcb2008b87e167e3bf4ee47ccdc5ce906eb4894") diff --git a/var/spack/repos/builtin/packages/py-blis/package.py b/var/spack/repos/builtin/packages/py-blis/package.py index e2a158a11e054d..46108428b26ac3 100644 --- a/var/spack/repos/builtin/packages/py-blis/package.py +++ b/var/spack/repos/builtin/packages/py-blis/package.py @@ -20,6 +20,8 @@ class PyBlis(PythonPackage): version("0.7.9", sha256="29ef4c25007785a90ffc2f0ab3d3bd3b75cd2d7856a9a482b7d0dac8d511a09d") version("0.4.1", sha256="d69257d317e86f34a7f230a2fd1f021fd2a1b944137f40d8cdbb23bd334cd0c4") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cython@0.25:", when="@0.7.9:", type="build") depends_on("py-numpy@1.15:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-blosc/package.py b/var/spack/repos/builtin/packages/py-blosc/package.py index 7d6b26ac6fcd19..ddd2f55732d292 100644 --- a/var/spack/repos/builtin/packages/py-blosc/package.py +++ b/var/spack/repos/builtin/packages/py-blosc/package.py @@ -17,9 +17,12 @@ class PyBlosc(PythonPackage): version("1.9.1", sha256="ffc884439a12409aa4e8945e21dc920d6bc21807357c51d24c7f0a27ae4f79b9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-scikit-build", type="build") - depends_on("py-cmake@3.11:", type="build") - depends_on("py-ninja", type="build") + depends_on("cmake@3.11:", type="build") + depends_on("ninja", type="build") # depends_on('c-blosc') # shipped internally diff --git a/var/spack/repos/builtin/packages/py-blosc2/package.py b/var/spack/repos/builtin/packages/py-blosc2/package.py index 238a963f362218..30964085df71a7 100644 --- a/var/spack/repos/builtin/packages/py-blosc2/package.py +++ b/var/spack/repos/builtin/packages/py-blosc2/package.py @@ -14,18 +14,19 @@ class PyBlosc2(PythonPackage): license("BSD-3-Clause") + version("2.6.2", sha256="8ca29d9aa988b85318bd8a9b707a7a06c8d6604ae1304cae059170437ae4f53a") version("2.2.8", sha256="59065aac5e9b01b0e9f3825d8e7f69f64b59bbfab148a47c54e4115f62a97474") version("2.0.0", sha256="f19b0b3674f6c825b490f00d8264b0c540c2cdc11ec7e81178d38b83c57790a1") + depends_on("c", type="build") # generated + depends_on("python@3.9:3", when="@2.2:", type=("build", "link", "run")) depends_on("python@3.8:3", when="@2.0", type=("build", "link", "run")) depends_on("py-setuptools", type="build") depends_on("py-scikit-build", type="build") depends_on("py-cython", type="build") - # FIXME: why doesn't this work? - # depends_on("py-cmake", type="build") depends_on("cmake@3.11:", type="build") - depends_on("py-ninja", type="build") + depends_on("ninja", type="build") depends_on("py-numpy@1.20.3:", type=("build", "link", "run")) depends_on("py-ndindex@1.4:", when="@2.2:", type=("build", "run")) depends_on("py-msgpack", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-bluepyopt/package.py b/var/spack/repos/builtin/packages/py-bluepyopt/package.py index 826fc265ba9353..67cfa6b65ee7e9 100644 --- a/var/spack/repos/builtin/packages/py-bluepyopt/package.py +++ b/var/spack/repos/builtin/packages/py-bluepyopt/package.py @@ -14,6 +14,7 @@ class PyBluepyopt(PythonPackage): license("LGPL-3.0-only") # NOTE : while adding new release check pmi_rank.patch compatibility + version("1.14.11", sha256="fe2830c36699a93d2ef9ddef316da42f9c57ca6654c92356eab973ee2298ebf7") version("1.14.4", sha256="7567fd736053250ca06030f67ad93c607b100c2b98df8dc588c26b64cb3e171c") # patch required to avoid hpe-mpi linked mechanism library @@ -32,7 +33,8 @@ class PyBluepyopt(PythonPackage): depends_on("py-future", type=("build", "run")) depends_on("py-pebble@4.6:", type=("build", "run")) depends_on("py-scoop@0.7:", type=("build", "run"), when="+scoop") - depends_on("neuron@7.4:", type=("build", "run")) + depends_on("neuron@7.4:", type=("build", "run"), when="@:1.14.4") + depends_on("neuron@7.8:", type=("build", "run"), when="@1.14.11:") def setup_run_environment(self, env): env.unset("PMI_RANK") diff --git a/var/spack/repos/builtin/packages/py-bokeh/package.py b/var/spack/repos/builtin/packages/py-bokeh/package.py index 8f79fb16c921c2..1384201b2dbe76 100644 --- a/var/spack/repos/builtin/packages/py-bokeh/package.py +++ b/var/spack/repos/builtin/packages/py-bokeh/package.py @@ -46,6 +46,8 @@ class PyBokeh(PythonPackage): depends_on("py-numpy@1.7.1:", type=("build", "run")) depends_on("py-numpy@1.11.3:", type=("build", "run"), when="@2.3.3:") depends_on("py-numpy@1.16:", type=("build", "run"), when="@3.1:") + # https://github.com/bokeh/bokeh/issues/13835 + depends_on("py-numpy@:1", when="@:3.4.0", type=("build", "run")) depends_on("py-packaging@16.8:", type=("build", "run"), when="@1.3.4:") diff --git a/var/spack/repos/builtin/packages/py-boost-histogram/package.py b/var/spack/repos/builtin/packages/py-boost-histogram/package.py index bd743760411a8e..4dff0fc12efb96 100644 --- a/var/spack/repos/builtin/packages/py-boost-histogram/package.py +++ b/var/spack/repos/builtin/packages/py-boost-histogram/package.py @@ -18,8 +18,12 @@ class PyBoostHistogram(PythonPackage): version("1.3.1", sha256="31cd396656f3a37834e07d304cdb84d9906bc2172626a3d92fe577d08bcf410f") version("1.2.1", sha256="a27842b2f1cfecc509382da2b25b03056354696482b38ec3c0220af0fc9b7579") + depends_on("cxx", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools@45:", type="build") depends_on("py-setuptools-scm@4.1.2:+toml", type="build") depends_on("py-numpy@1.13.3:", type=("build", "run")) + # https://github.com/numpy/numpy/issues/26191#issuecomment-2179127999 + depends_on("py-numpy@:1", when="@:1.4.0", type=("build", "run")) depends_on("py-typing-extensions", when="^python@:3.7", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-bottleneck/package.py b/var/spack/repos/builtin/packages/py-bottleneck/package.py index 334975f9e19413..82599607ff3702 100644 --- a/var/spack/repos/builtin/packages/py-bottleneck/package.py +++ b/var/spack/repos/builtin/packages/py-bottleneck/package.py @@ -22,6 +22,10 @@ class PyBottleneck(PythonPackage): version("1.2.1", sha256="6efcde5f830aed64feafca0359b51db0e184c72af8ba6675b4a99f263922eb36") version("1.0.0", sha256="8d9b7ad4fadf9648acc924a6ee522c7cb5b474e75faaad9d90dfd55e2805b495") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-versioneer", when="@1.3.3:", type="build") depends_on("py-numpy", type=("build", "run")) + # https://github.com/pydata/bottleneck/issues/453 + depends_on("py-numpy@:1", when="@:1.3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-bravado-core/package.py b/var/spack/repos/builtin/packages/py-bravado-core/package.py new file mode 100644 index 00000000000000..ae657c1befc3ee --- /dev/null +++ b/var/spack/repos/builtin/packages/py-bravado-core/package.py @@ -0,0 +1,34 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyBravadoCore(PythonPackage): + """ + bravado-core is a Python library that adds client-side and server-side + support for the OpenAPI Specification v2.0. + """ + + homepage = "https://github.com/Yelp/bravado-core" + pypi = "bravado-core/bravado-core-5.17.1.tar.gz" + + version("5.17.1", sha256="0da9c6f3814734622a55db3f62d08db6e188b25f3ebd087de370c91afb66a7f4") + + depends_on("python@:2,3.5.1:", type=("build", "run")) + depends_on("py-setuptools", type="build") + + depends_on("py-jsonref", type=("build", "run")) + depends_on("py-jsonschema@2.5.1:", type=("build", "run")) + depends_on("py-python-dateutil", type=("build", "run")) + depends_on("py-pyyaml", type=("build", "run")) + depends_on("py-requests", type=("build", "run")) + depends_on("py-simplejson", type=("build", "run")) + depends_on("py-six", type=("build", "run")) + depends_on("py-swagger-spec-validator@2.0.1:", type=("build", "run")) + depends_on("py-pytz", type=("build", "run")) + depends_on("py-msgpack@0.5.2:", type=("build", "run")) + + depends_on("py-pyrsistent@0.17:", when="^python@:3.4", type="build") diff --git a/var/spack/repos/builtin/packages/py-bravado/package.py b/var/spack/repos/builtin/packages/py-bravado/package.py new file mode 100644 index 00000000000000..7dd2494f1b5b3d --- /dev/null +++ b/var/spack/repos/builtin/packages/py-bravado/package.py @@ -0,0 +1,31 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyBravado(PythonPackage): + """ + Bravado is a Yelp maintained fork of digium/swagger-py for use with + OpenAPI Specification version 2.0 (previously known as Swagger). + """ + + homepage = "https://github.com/Yelp/bravado" + pypi = "bravado/bravado-11.0.3.tar.gz" + + version("11.0.3", sha256="1bb6ef75d84140c851fffe6420baaee5037d840070cfe11d60913be6ab8e0530") + + depends_on("python@:2,3.5.1:", type=("build", "run")) + depends_on("py-setuptools", type="build") + + depends_on("py-bravado-core@5.16.1:", type=("build", "run")) + depends_on("py-msgpack", type=("build", "run")) + depends_on("py-python-dateutil", type=("build", "run")) + depends_on("py-pyyaml", type=("build", "run")) + depends_on("py-requests@2.17:", type=("build", "run")) + depends_on("py-six", type=("build", "run")) + depends_on("py-simplejson", type=("build", "run")) + depends_on("py-monotonic", type=("build", "run")) + depends_on("py-typing-extensions", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-breathe/package.py b/var/spack/repos/builtin/packages/py-breathe/package.py index 8bc1fc6db7910f..2b1b515fdd3c42 100644 --- a/var/spack/repos/builtin/packages/py-breathe/package.py +++ b/var/spack/repos/builtin/packages/py-breathe/package.py @@ -30,6 +30,9 @@ class PyBreathe(PythonPackage): version("4.7.1", sha256="afb1ab0084b25d3670fa8f5cf2eeaee6fe61bfc77876e3816b140eacd4949875") version("4.7.0", sha256="5629c67f5adb41f39375d36c5f0d60d34b1230be268125e535205d77f69211e4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("python@3.5:", type=("build", "run"), when="@4.21:4.32") diff --git a/var/spack/repos/builtin/packages/py-brian/package.py b/var/spack/repos/builtin/packages/py-brian/package.py index 4b7888e3f5f7ee..32bf478f930ef4 100644 --- a/var/spack/repos/builtin/packages/py-brian/package.py +++ b/var/spack/repos/builtin/packages/py-brian/package.py @@ -14,6 +14,9 @@ class PyBrian(PythonPackage): version("1.4.3", sha256="c881dcfcd1a21990f9cb3cca76cdd868111cfd9e227ef5c1b13bb372d2efeaa4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") depends_on("py-matplotlib@0.90.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-brian2/package.py b/var/spack/repos/builtin/packages/py-brian2/package.py index 911377cd8a36bf..b57f9f17951861 100644 --- a/var/spack/repos/builtin/packages/py-brian2/package.py +++ b/var/spack/repos/builtin/packages/py-brian2/package.py @@ -21,6 +21,9 @@ class PyBrian2(PythonPackage): version("2.0.1", sha256="195d8ced0d20e9069917776948f92aa70b7457bbc6b5222b8199654402ee1153") version("2.0rc3", sha256="05f347f5fa6b25d1ce5ec152a2407bbce033599eb6664f32f5331946eb3c7d66") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@2.7:", type=("build", "run")) depends_on("python@3.6:", type=("build", "run"), when="@2.4:") depends_on("python@3.7:", type=("build", "run"), when="@2.5:") diff --git a/var/spack/repos/builtin/packages/py-brotli/package.py b/var/spack/repos/builtin/packages/py-brotli/package.py index eece9c58daf1cc..49c91d980f6494 100644 --- a/var/spack/repos/builtin/packages/py-brotli/package.py +++ b/var/spack/repos/builtin/packages/py-brotli/package.py @@ -16,4 +16,6 @@ class PyBrotli(PythonPackage): version("1.1.0", sha256="81de08ac11bcb85841e440c13611c00b67d3bf82698314928d0b676362546724") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-brotlipy/package.py b/var/spack/repos/builtin/packages/py-brotlipy/package.py index 8cb3c407b3ad25..d526fb37c1377a 100644 --- a/var/spack/repos/builtin/packages/py-brotlipy/package.py +++ b/var/spack/repos/builtin/packages/py-brotlipy/package.py @@ -16,6 +16,8 @@ class PyBrotlipy(PythonPackage): version("0.7.0", sha256="36def0b859beaf21910157b4c33eb3b06d8ce459c942102f16988cca6ea164df") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cffi@1.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-bsddb3/package.py b/var/spack/repos/builtin/packages/py-bsddb3/package.py index 97db040831b86f..d13d3e149ebb5a 100644 --- a/var/spack/repos/builtin/packages/py-bsddb3/package.py +++ b/var/spack/repos/builtin/packages/py-bsddb3/package.py @@ -18,6 +18,8 @@ class PyBsddb3(PythonPackage): version("6.2.5", sha256="784bf40ad935258507594a89b32ea11f362cde120751c8b96de163955ced7db8") + depends_on("c", type="build") # generated + depends_on("python@2.6:") depends_on("py-setuptools", type="build") depends_on("berkeley-db") diff --git a/var/spack/repos/builtin/packages/py-bx-python/package.py b/var/spack/repos/builtin/packages/py-bx-python/package.py index e37f48f4f77824..a96821f349302c 100644 --- a/var/spack/repos/builtin/packages/py-bx-python/package.py +++ b/var/spack/repos/builtin/packages/py-bx-python/package.py @@ -18,6 +18,8 @@ class PyBxPython(PythonPackage): version("0.9.0", sha256="fe545c44d2ea74b239d41e9090618aaf6a859d1a1f64b4a21b133cb602dfdb49") version("0.8.8", sha256="ad0808ab19c007e8beebadc31827e0d7560ac0e935f1100fb8cc93607400bb47") + depends_on("c", type="build") # generated + # See https://pypi.org/project/bx-python/(version)/#files for which Python versions # work with which releases. depends_on("python@3.7:3.11", when="@=0.9.0", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-carputils/package.py b/var/spack/repos/builtin/packages/py-carputils/package.py index 9a50582c5343d2..695e63bee1d8c6 100644 --- a/var/spack/repos/builtin/packages/py-carputils/package.py +++ b/var/spack/repos/builtin/packages/py-carputils/package.py @@ -19,6 +19,7 @@ class PyCarputils(PythonPackage): version("master", branch="master") # Version to use with openCARP releases + version("oc15.0", commit="50e2580b3f75711388eb55982a9b43871c3201f3") version("oc13.0", commit="216c3802c2ac2d14c739164dcd57f2e59aa2ede3") version("oc12.0", commit="4d7a1f0c604a2ad232e70cf9aa3a8daff5ffb195") version("oc11.0", commit="a02f9b846c6e852b7315b20e925d55c355f239b8") @@ -28,6 +29,8 @@ class PyCarputils(PythonPackage): version("oc8.1", commit="a4210fcb0fe17226a1744ee9629f85b629decba3") version("oc7.0", commit="4c04db61744f2fb7665594d7c810699c5c55c77c") + depends_on("c", type="build") # generated + depends_on("git", type=("build", "run")) depends_on("py-numpy@1.14.5:", type=("build", "run")) @@ -36,7 +39,7 @@ class PyCarputils(PythonPackage): depends_on("py-scipy@1.5.0:", type=("build", "run")) depends_on("py-matplotlib@3.0.0:", type=("build", "run")) depends_on("py-pandas", type=("build", "run")) - depends_on("py-tables@3.6.1:", type=("build", "run")) + depends_on("py-tables@3.8.0:", type=("build", "run")) depends_on("py-six@1.12.0:", type=("build", "run")) depends_on("py-pydoe@0.3.8", type=("build", "run")) depends_on("py-ruamel-yaml@0.17.4:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-cartopy/package.py b/var/spack/repos/builtin/packages/py-cartopy/package.py index ef7f72b4828ba2..a31c1c50194fab 100644 --- a/var/spack/repos/builtin/packages/py-cartopy/package.py +++ b/var/spack/repos/builtin/packages/py-cartopy/package.py @@ -17,6 +17,7 @@ class PyCartopy(PythonPackage): license("LGPL-3.0-or-later") + version("0.23.0", sha256="231f37b35701f2ba31d94959cca75e6da04c2eea3a7f14ce1c75ee3b0eae7676") version("0.22.0", sha256="b300f90120931d43f11ef87c064ea1dacec1b59a4940aa76ebf82cf09548bb49") version("0.21.1", sha256="89d5649712c8582231c6e11825a04c85f6f0cee94dbb89e4db23eabca1cc250a") version("0.21.0", sha256="ce1d3a28a132e94c89ac33769a50f81f65634ab2bd40556317e15bd6cad1ce42") @@ -31,6 +32,8 @@ class PyCartopy(PythonPackage): version("0.17.0", sha256="424bd9e9ddef6e48cbdee694ce589ec431be8591f15b6cb93cb2b333a29b2c61") version("0.16.0", sha256="f23dffa101f43dd91e866a49ebb5f5048be2a24ab8a921a5c07edabde746d9a4") + depends_on("cxx", type="build") # generated + variant("epsg", default=False, when="@:0.19", description="Add support for epsg.io") variant( "ows", @@ -40,55 +43,67 @@ class PyCartopy(PythonPackage): variant("plotting", default=False, description="Add plotting functionality") # Based on wheel availability on PyPI - depends_on("python@3.9:3.11", when="@0.22:", type=("build", "link", "run")) - depends_on("python@3.8:3.11", when="@0.21", type=("build", "link", "run")) - depends_on("python@:3.11", when="@0.20", type=("build", "link", "run")) - depends_on("python@:3.10", when="@0.19", type=("build", "link", "run")) - depends_on("python@:3.9", when="@:0.18", type=("build", "link", "run")) - - # Required dependencies - depends_on("py-setuptools@40.6:", when="@0.19:", type="build") - depends_on("py-setuptools@0.7.2:", type="build") - depends_on("py-cython@0.29.24:", when="@0.22:", type="build") - depends_on("py-cython@0.29.13:", when="@0.20:", type="build") - depends_on("py-cython@0.29.2:", when="@0.19:", type="build") - depends_on("py-cython@0.28:", when="@0.18:", type="build") - depends_on("py-cython@0.15.1:", when="@0.17:", type="build") - depends_on("py-cython", type="build") - depends_on("py-setuptools-scm@7:", when="@0.20.3:", type="build") - depends_on("py-setuptools-scm", when="@0.19:", type="build") - depends_on("py-numpy@1.21:", when="@0.22:", type=("build", "link", "run")) - depends_on("py-numpy@1.18:", when="@0.20:", type=("build", "link", "run")) - depends_on("py-numpy@1.13.3:", when="@0.19:", type=("build", "link", "run")) - depends_on("py-numpy@1.10:", when="@0.17:", type=("build", "link", "run")) - depends_on("py-numpy@1.6:", type=("build", "link", "run")) - depends_on("py-matplotlib@3.4:", when="@0.22:", type=("build", "run")) - depends_on("py-matplotlib@3.1:", when="@0.21", type=("build", "run")) - # https://github.com/SciTools/cartopy/issues/2086 - depends_on("py-matplotlib@3.1:3.5", when="@0.20", type=("build", "run")) - depends_on("py-shapely@1.7:", when="@0.22:", type=("build", "run")) - depends_on("py-shapely@1.6.4:", when="@0.21.1:0.21", type=("build", "run")) - depends_on("py-shapely@1.6.4:1", when="@0.20:0.21.0", type=("build", "run")) - depends_on("py-shapely@1.5.6:1", when="@:0.19", type=("build", "run")) - depends_on("py-packaging@20:", when="@0.22:", type=("build", "run")) - depends_on("py-pyshp@2.1:", when="@0.20:", type=("build", "run")) - depends_on("py-pyshp@2:", when="@0.19:", type=("build", "run")) - depends_on("py-pyshp@1.1.4:", type=("build", "run")) - depends_on("py-pyproj@3.1:", when="@0.22:", type=("build", "run")) - depends_on("py-pyproj@3:", when="@0.20:", type=("build", "run")) - - with when("+ows"): - depends_on("py-owslib@0.20:", when="@0.22:", type="run") - depends_on("py-owslib@0.18:", when="@0.20:", type="run") - depends_on("py-owslib@0.8.11:", type="run") - depends_on("pil@6.1:", when="@0.20:", type="run") - depends_on("pil@1.7.8:", type="run") - - with when("+plotting"): - depends_on("pil@6.1:", when="@0.20:", type="run") - depends_on("pil@1.7.8:", type="run") - depends_on("py-scipy@1.3.1:", when="@0.20:", type="run") - depends_on("py-scipy@0.10:", type="run") + with default_args(type=("build", "link", "run")): + depends_on("python@3.9:3.12", when="@0.23:") + depends_on("python@3.9:3.11", when="@0.22") + depends_on("python@3.8:3.11", when="@0.21") + depends_on("python@:3.11", when="@0.20") + depends_on("python@:3.10", when="@0.19") + depends_on("python@:3.9", when="@:0.18") + + with default_args(type="build"): + depends_on("py-setuptools@40.6:", when="@0.19:") + depends_on("py-setuptools@0.7.2:") + depends_on("py-cython@0.29.24:", when="@0.22:") + depends_on("py-cython@0.29.13:", when="@0.20:") + depends_on("py-cython@0.29.2:", when="@0.19:") + depends_on("py-cython@0.28:", when="@0.18:") + depends_on("py-cython@0.15.1:", when="@0.17:") + depends_on("py-cython") + depends_on("py-setuptools-scm@7:", when="@0.20.3:") + depends_on("py-setuptools-scm", when="@0.19:") + + with default_args(type=("build", "link", "run")): + depends_on("py-numpy@1.21:", when="@0.22:") + depends_on("py-numpy@1.18:", when="@0.20:21") + depends_on("py-numpy@1.13.3:", when="@0.19") + depends_on("py-numpy@1.10:", when="@0.17:0.18") + depends_on("py-numpy@1.6:", when="@0.16") + # https://github.com/SciTools/cartopy/issues/2339 + depends_on("py-numpy@:1", when="@:0.22") + + with default_args(type=("build", "run")): + depends_on("py-matplotlib@3.5:", when="@0.23:") + depends_on("py-matplotlib@3.4:", when="@0.22:") + depends_on("py-matplotlib@3.1:", when="@0.21") + # https://github.com/SciTools/cartopy/issues/2086 + depends_on("py-matplotlib@3.1:3.5", when="@0.20") + depends_on("py-shapely@1.7:", when="@0.22:") + depends_on("py-shapely@1.6.4:", when="@0.21.1:0.21") + depends_on("py-shapely@1.6.4:1", when="@0.20:0.21.0") + depends_on("py-shapely@1.5.6:1", when="@:0.19") + depends_on("py-packaging@20:", when="@0.22:") + depends_on("py-pyshp@2.3:", when="@0.23:") + depends_on("py-pyshp@2.1:", when="@0.20:") + depends_on("py-pyshp@2:", when="@0.19:") + depends_on("py-pyshp@1.1.4:") + depends_on("py-pyproj@3.3.1:", when="@0.23:") + depends_on("py-pyproj@3.1:", when="@0.22:") + depends_on("py-pyproj@3:", when="@0.20:") + + with default_args(type="run"): + with when("+ows"): + depends_on("py-owslib@0.20:", when="@0.22:") + depends_on("py-owslib@0.18:", when="@0.20:") + depends_on("py-owslib@0.8.11:") + depends_on("pil@6.1:", when="@0.20:") + depends_on("pil@1.7.8:") + + with when("+plotting"): + depends_on("pil@6.1:", when="@0.20:") + depends_on("pil@1.7.8:") + depends_on("py-scipy@1.3.1:", when="@0.20:") + depends_on("py-scipy@0.10:") # Historical dependencies depends_on("py-setuptools-scm-git-archive", when="@0.19:0.20.2", type="build") diff --git a/var/spack/repos/builtin/packages/py-casadi/package.py b/var/spack/repos/builtin/packages/py-casadi/package.py index f4f47b771c8dd1..0239dd4acae334 100644 --- a/var/spack/repos/builtin/packages/py-casadi/package.py +++ b/var/spack/repos/builtin/packages/py-casadi/package.py @@ -16,5 +16,9 @@ class PyCasadi(PythonPackage): version("3.6.4", sha256="affdca1a99c14580992cdf34d247754b7d851080b712c2922ad2e92442eeaa35") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-celery/package.py b/var/spack/repos/builtin/packages/py-celery/package.py index 7cbe513c974f28..fa0fb1e2520000 100644 --- a/var/spack/repos/builtin/packages/py-celery/package.py +++ b/var/spack/repos/builtin/packages/py-celery/package.py @@ -9,10 +9,11 @@ class PyCelery(PythonPackage): """Celery - Distributed Task Queue.""" - pypi = "celery/celery-4.2.1.tar.gz" + pypi = "celery/celery-5.3.6.tar.gz" license("BSD-3-Clause") + version("5.3.6", sha256="870cc71d737c0200c397290d730344cc991d13a057534353d124c9380267aab9") version("5.2.3", sha256="e2cd41667ad97d4f6a2f4672d1c6a6ebada194c619253058b5f23704aaadaa82") version("5.0.0", sha256="313930fddde703d8e37029a304bf91429cd11aeef63c57de6daca9d958e1f255") version("4.4.7", sha256="d220b13a8ed57c78149acf82c006785356071844afe0b27012a4991d44026f9f") @@ -53,24 +54,34 @@ class PyCelery(PythonPackage): depends_on("python@2.7:2.8,3.4:", type=("build", "run")) depends_on("py-setuptools", type=("build", "run")) - depends_on("py-setuptools@59.1.1:59.6", type=("build", "run"), when="@5.2.3:") + depends_on("py-setuptools@59.1.1:59.6", type=("build", "run"), when="@5.2.3:5.2.4") depends_on("py-redis@3.2.0:", when="+redis", type=("build", "run")) depends_on("py-redis@3.4.1:3,4.0.2:", when="@5.2.3:+redis", type=("build", "run")) depends_on("py-sqlalchemy", when="+sqlalchemy", type=("build", "run")) depends_on("py-click@7.0:7", when="@5.0.0:5.0", type=("build", "run")) - depends_on("py-click@8.0.3:8", when="@5.2.0:", type=("build", "run")) + depends_on("py-click@8.0.3:8", when="@5.2", type=("build", "run")) + depends_on("py-click@8.1.2:", when="@5.3:", type=("build", "run")) depends_on("py-click-didyoumean@0.0.3:", when="@5.0.0:5", type=("build", "run")) depends_on("py-click-plugins@1.1.1:", when="@5.0.3:", type=("build", "run")) depends_on("py-click-repl@:0.1.6", when="@5.0.0:5.0", type=("build", "run")) depends_on("py-click-repl@0.2.0:", when="@5.2.0:", type=("build", "run")) - depends_on("py-pytz@2019.3:", type=("build", "run")) - depends_on("py-pytz@2021.3:", type=("build", "run"), when="@5.2.3") - depends_on("py-billiard@3.6.3.0:3", type=("build", "run")) - depends_on("py-billiard@3.6.4.0:3", type=("build", "run"), when="@5.2.3") + depends_on("py-pytz@2019.3:", type=("build", "run"), when="@:5.2") + depends_on("py-pytz@2021.3:", type=("build", "run"), when="@5.2.3:5.2.99") + depends_on("py-billiard@3.6.3", type=("build", "run"), when="@:5.0.99") + depends_on("py-billiard@3.6.4.0:3.99", type=("build", "run"), when="@5.1.0:5.2") + depends_on("py-billiard@4.2.0:5.0", type=("build", "run"), when="@5.3.0:") depends_on("py-kombu@4.6.11", when="@4.3.0:4", type=("build", "run")) - depends_on("py-kombu@5.0.0:", when="@5.0.0:5.0", type=("build", "run")) - depends_on("py-kombu@5.2.3:5", when="@5.2.0:5.2", type=("build", "run")) + depends_on("py-kombu@5.0.0:", when="@5.0", type=("build", "run")) + depends_on("py-kombu@5.1.0:", when="@5.1", type=("build", "run")) + depends_on("py-kombu@5.2.1", when="@5.2.0", type=("build", "run")) + depends_on("py-kombu@5.2.2", when="@5.2.1:5.2.2", type=("build", "run")) + depends_on("py-kombu@5.2.3", when="@5.2.3:5.2.99", type=("build", "run")) + depends_on("py-kombu@5.3.0", when="@5.3.0", type=("build", "run")) + depends_on("py-kombu@5.3.1", when="@5.3.1", type=("build", "run")) + depends_on("py-kombu@5.3.2", when="@5.3.4", type=("build", "run")) + depends_on("py-kombu@5.3.3", when="@5.3.5", type=("build", "run")) + depends_on("py-kombu@5.3.4:5.3.5", when="@5.3.6", type=("build", "run")) depends_on("py-vine@1.3.0", when="@4.3.0:4", type=("build", "run")) depends_on("py-vine@5.0.0:5", when="@5.0.0:5", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-cf-units/package.py b/var/spack/repos/builtin/packages/py-cf-units/package.py index 8638fb94804643..d303c66f0b839f 100644 --- a/var/spack/repos/builtin/packages/py-cf-units/package.py +++ b/var/spack/repos/builtin/packages/py-cf-units/package.py @@ -21,6 +21,8 @@ class PyCfUnits(PythonPackage): version("2.1.4", sha256="25f81ad994af30713ee8f5ef18ffddd83c6ec1ac308e1bd89d45de9d2e0f1c31") version("2.1.1", sha256="fa0ef8efd84546e61088aa23e76ebbaf7043167dc3a7f35f34549c234b543530") + depends_on("c", type="build") # generated + depends_on("python@3:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-six", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-cffi/package.py b/var/spack/repos/builtin/packages/py-cffi/package.py index 5e840d3c9edce3..932fcaaa1659a8 100644 --- a/var/spack/repos/builtin/packages/py-cffi/package.py +++ b/var/spack/repos/builtin/packages/py-cffi/package.py @@ -26,6 +26,8 @@ class PyCffi(PythonPackage): version("1.10.0", sha256="b3b02911eb1f6ada203b0763ba924234629b51586f72a21faacc638269f4ced5") version("1.1.2", sha256="390970b602708c91ddc73953bb6929e56291c18a4d80f360afa00fad8b6f3339") + depends_on("c", type="build") # generated + # ./spack-src/cffi/ffiplatform.py has _hack_at_distutils which imports # setuptools before distutils, but only on Windows. This could be made # unconditional to support Python 3.12 diff --git a/var/spack/repos/builtin/packages/py-chainer/package.py b/var/spack/repos/builtin/packages/py-chainer/package.py index 1f78c76a30d3bb..f284f2a054e330 100644 --- a/var/spack/repos/builtin/packages/py-chainer/package.py +++ b/var/spack/repos/builtin/packages/py-chainer/package.py @@ -31,6 +31,8 @@ class PyChainer(PythonPackage): version("7.2.0", sha256="6e2fba648cc5b8a5421e494385b76fe5ec154f1028a1c5908557f5d16c04f0b3") version("6.7.0", sha256="87cb3378a35e7c5c695028ec91d58dc062356bc91412384ea939d71374610389") + depends_on("cxx", type="build") # generated + variant("mn", default=False, description="run with ChainerMN") depends_on("python@3.5.1:", when="@7:", type=("build", "run")) @@ -59,7 +61,7 @@ def test_chainermn(self): mnist_file = join_path(self.install_test_root.examples.chainermn.mnist, "train_mnist.py") mpirun = which(self.spec["mpi"].prefix.bin.mpirun) - opts = ["-n", "4", self.spec["python"].command.path, mnist_file, "-o", "."] + opts = ["-n", "4", python.path, mnist_file, "-o", "."] env["OMP_NUM_THREADS"] = "4" mpirun(*opts) diff --git a/var/spack/repos/builtin/packages/py-cheetah3/package.py b/var/spack/repos/builtin/packages/py-cheetah3/package.py index 373ae463f41781..2c387534fe64ac 100644 --- a/var/spack/repos/builtin/packages/py-cheetah3/package.py +++ b/var/spack/repos/builtin/packages/py-cheetah3/package.py @@ -15,5 +15,7 @@ class PyCheetah3(PythonPackage): version("3.2.6", sha256="f1c2b693cdcac2ded2823d363f8459ae785261e61c128d68464c8781dba0466b") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-markdown@2.0.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-chemfiles/package.py b/var/spack/repos/builtin/packages/py-chemfiles/package.py index 5cb22d838e08df..ee03273c34e27d 100644 --- a/var/spack/repos/builtin/packages/py-chemfiles/package.py +++ b/var/spack/repos/builtin/packages/py-chemfiles/package.py @@ -18,11 +18,14 @@ class PyChemfiles(PythonPackage): version("0.10.3", sha256="4bbb8b116492a57dbf6ddb4c84aad0133cd782e0cc0e53e4b957f2d93e6806ea") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("chemfiles@0.10.3+shared", when="@0.10.3") depends_on("py-numpy", type=("build", "run")) depends_on("py-setuptools@44:", type="build") depends_on("py-wheel@0.36:", type="build") - depends_on("py-cmake", type="build") - depends_on("py-ninja", type="build") + depends_on("cmake", type="build") + depends_on("ninja", type="build") diff --git a/var/spack/repos/builtin/packages/py-cig-pythia/package.py b/var/spack/repos/builtin/packages/py-cig-pythia/package.py new file mode 100644 index 00000000000000..7058481de61505 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-cig-pythia/package.py @@ -0,0 +1,47 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyCigPythia(AutotoolsPackage, PythonExtension): + """This is the Computational Infrastructure for Geodynamics (CIG) fork of + Pythia/Pyre originally written by Michael Aivazis (California Institute of Technology). + + Pythia/Pyre provides a Python framework for scientific simulations. This + fork focuses (and maintains) functionality for: + + specification of simulation parameters + specification of units and unit conversions + user-friendly interface to popular batch job schedulers + Python and C++ interfaces for logging""" + + homepage = "https://github.com/geodynamics/pythia/" + url = "https://github.com/geodynamics/pythia/releases/download/v1.1.0/pythia-1.1.0.tar.gz" + + license("BSD-3-Clause", checked_by="downloadico") + + version("1.1.0", sha256="d8e941d2d0fa4772c3c0cb3d1d9b6acbb5fa01ef346dc0706a8da541a8f97731") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant("mpi", default=True, description="Build with MPI support.") + + depends_on("mpi", when="+mpi") + depends_on("python@3.8:") + depends_on("py-pip") + depends_on("py-setuptools") + + def configure_args(self): + spec = self.spec + args = [] + if "+mpi" in spec: + args.append("--enable-mpi") + args.append(f"CC={spec['mpi'].mpicc}") + args.append(f"CXX={spec['mpi'].mpicxx}") + else: + args.append("--disable-mpi") + return args diff --git a/var/spack/repos/builtin/packages/py-climate/package.py b/var/spack/repos/builtin/packages/py-climate/package.py index 37e1f940696e41..76e69a668a9abb 100644 --- a/var/spack/repos/builtin/packages/py-climate/package.py +++ b/var/spack/repos/builtin/packages/py-climate/package.py @@ -14,10 +14,6 @@ class PyClimate(PythonPackage): license("Apache-2.0") - version( - "0.1.0", - sha256="01026c764b34d8204b8f527a730ef667fa5827fca765993ff1ed3e9dab2c11ae", - expand=False, - ) + version("0.1.0", sha256="01026c764b34d8204b8f527a730ef667fa5827fca765993ff1ed3e9dab2c11ae") depends_on("python@3.7:3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-cloudpickle/package.py b/var/spack/repos/builtin/packages/py-cloudpickle/package.py index 044f472b7d0887..5627cbafb9afeb 100644 --- a/var/spack/repos/builtin/packages/py-cloudpickle/package.py +++ b/var/spack/repos/builtin/packages/py-cloudpickle/package.py @@ -14,6 +14,8 @@ class PyCloudpickle(PythonPackage): license("BSD-3-Clause") + version("3.0.0", sha256="996d9a482c6fb4f33c1a35335cf8afd065d2a56e973270364840712d9131a882") + version("2.2.1", sha256="d89684b8de9e34a2a43b3460fbca07d09d6e25ce858df4d5a44240403b6178f5") version("2.2.0", sha256="3f4219469c55453cfe4737e564b67c2a149109dabf7f242478948b895f61106f") version("1.6.0", sha256="9bc994f9e9447593bd0a45371f0e7ac7333710fcf64a4eb9834bf149f4ef2f32") version("1.2.1", sha256="603244e0f552b72a267d47a7d9b347b27a3430f58a0536037a290e7e0e212ecf") @@ -22,4 +24,6 @@ class PyCloudpickle(PythonPackage): depends_on("python@3.5:", type=("build", "run"), when="@1.6.0:") depends_on("python@3.6:", type=("build", "run"), when="@2.2.0:") - depends_on("py-setuptools", type="build") + depends_on("python@3.8:", type=("build", "run"), when="@3:") + depends_on("py-setuptools", type="build", when="@:2") + depends_on("py-flit-core", type="build", when="@3:") diff --git a/var/spack/repos/builtin/packages/py-cmake/package.py b/var/spack/repos/builtin/packages/py-cmake/package.py index db15cd82591822..3d0ec8d7613664 100644 --- a/var/spack/repos/builtin/packages/py-cmake/package.py +++ b/var/spack/repos/builtin/packages/py-cmake/package.py @@ -15,7 +15,9 @@ class PyCmake(PythonPackage): """CMake is an open-source, cross-platform family of tools designed to - build, test and package software + build, test and package software. + + Deprecated: use cmake instead. """ homepage = "https://cmake.org" @@ -25,7 +27,7 @@ class PyCmake(PythonPackage): license("Apache-2.0") for v, sha in pycmake_versions.items(): - version(v, sha256=sha) + version(v, sha256=sha, deprecated=True) depends_on("ninja", type="build") depends_on("py-scikit-build@0.12:", type="build") @@ -53,3 +55,16 @@ class PyCmake(PythonPackage): def install_options(self, spec, prefix): return ["-DBUILD_CMAKE_FROM_SOURCE=ON", "-DCMakeProject_SOURCE_DIR=cmake-src"] + + def setup_build_environment(self, env): + if self.run_tests: + env.set( + "SKBUILD_CONFIGURE_OPTIONS", + # BootstrapTest is already exlcude upstream, + # The rest are (non-understood) known failures, disabled to get test suite working + # todo: investigate test failures / check if still needed in newer versions + "-DRUN_CMAKE_TEST=ON -DRUN_CMAKE_TEST_EXCLUDE=BootstrapTest|CompileWarningAsError" + "|GET_RUNTIME_DEPENDENCIES", + ) + else: + env.set("SKBUILD_CONFIGURE_OPTIONS", "-DRUN_CMAKE_TEST=OFF") diff --git a/var/spack/repos/builtin/packages/py-codepy/package.py b/var/spack/repos/builtin/packages/py-codepy/package.py index 342c3ce52a05db..542ebb2ed6accd 100644 --- a/var/spack/repos/builtin/packages/py-codepy/package.py +++ b/var/spack/repos/builtin/packages/py-codepy/package.py @@ -21,6 +21,8 @@ class PyCodepy(PythonPackage): version("2019.1", sha256="384f22c37fe987c0ca71951690c3c2fd14dacdeddbeb0fde4fd01cd84859c94e") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-pytools@2015.1.2:", type=("build", "run")) depends_on("py-numpy@1.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-colored/package.py b/var/spack/repos/builtin/packages/py-colored/package.py index e94f5d857d2e8b..4e8d1fe0347699 100644 --- a/var/spack/repos/builtin/packages/py-colored/package.py +++ b/var/spack/repos/builtin/packages/py-colored/package.py @@ -17,6 +17,8 @@ class PyColored(PythonPackage): homepage = "https://gitlab.com/dslackw/colored" pypi = "colored/colored-1.4.2.tar.gz" + version("2.2.4", sha256="595e1dd7f3b472ea5f12af21d2fec8a2ea2cf8f9d93e67180197330b26df9b61") version("1.4.2", sha256="056fac09d9e39b34296e7618897ed1b8c274f98423770c2980d829fd670955ed") - depends_on("py-setuptools", type="build") + depends_on("py-setuptools", type="build", when="@1.4.2") + depends_on("py-flit-core@3.2.0:3", type="build", when="@2.2.4:") diff --git a/var/spack/repos/builtin/packages/py-configspace/package.py b/var/spack/repos/builtin/packages/py-configspace/package.py index e02780b25c7b18..64dfd9d4472c6e 100644 --- a/var/spack/repos/builtin/packages/py-configspace/package.py +++ b/var/spack/repos/builtin/packages/py-configspace/package.py @@ -17,10 +17,20 @@ class PyConfigspace(PythonPackage): license("BSD-3-Clause") + version("0.7.1", sha256="57b5b8e28ed6ee14ecf6206fdca43ca698ef63bc1531f081d482b26acf4edf1a") + version("0.6.1", sha256="b0a9487c7997481a041feee46f2c8fc9fb9787e1ff553250838d62624dfb0d5a") + version("0.6.0", sha256="9b6c95d8839fcab220372673214b3129b45dcd8b1179829eb2c65746cacb72a9") + version("0.5.0", sha256="c8b61fe119829c29c47fc8719bb5f5740ae3034c793040f7bff67dbc9eb9c754") + version("0.4.21", sha256="09c5ee343f2850865609cc91f2ab27da0a6182f7f196354f9550f6da578ea827") version("0.4.20", sha256="2e4ca06f5a6a61e5322a73dd7545468c79f2a3e8385cab92fdada317af41d9e9") + depends_on("c", type="build") # generated + depends_on("python@3.7:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) depends_on("py-cython", type="build") depends_on("py-pyparsing", type=("build", "run")) + depends_on("py-scipy", when="@0.4.21:") + depends_on("py-typing-extensions", when="@0.6.0:") + depends_on("py-more-itertools", when="@0.6.1:") diff --git a/var/spack/repos/builtin/packages/py-contourpy/package.py b/var/spack/repos/builtin/packages/py-contourpy/package.py index 9d13c9957aa25c..963e3e1255fb69 100644 --- a/var/spack/repos/builtin/packages/py-contourpy/package.py +++ b/var/spack/repos/builtin/packages/py-contourpy/package.py @@ -17,10 +17,14 @@ class PyContourpy(PythonPackage): version("1.0.7", sha256="d8165a088d31798b59e91117d1f5fc3df8168d8b48c4acc10fc0df0d0bdbcc5e") version("1.0.5", sha256="896631cd40222aef3697e4e51177d14c3709fda49d30983269d584f034acc8a4") + depends_on("cxx", type="build") # generated + depends_on("python@3.8:", when="@1.0.7:", type=("build", "link", "run")) depends_on("python@3.7:", type=("build", "link", "run")) depends_on("py-pybind11@2.6:", type=("build", "link")) depends_on("py-setuptools@42:", type="build") depends_on("py-numpy@1.16:", type=("build", "run")) + # https://github.com/numpy/numpy/issues/26191 + depends_on("py-numpy@:1", when="@:1.2.0", type=("build", "run")) depends_on("py-build", when="@:1.0.5", type="build") diff --git a/var/spack/repos/builtin/packages/py-correctionlib/package.py b/var/spack/repos/builtin/packages/py-correctionlib/package.py index 677e75fa8843d8..8757d244b07219 100644 --- a/var/spack/repos/builtin/packages/py-correctionlib/package.py +++ b/var/spack/repos/builtin/packages/py-correctionlib/package.py @@ -17,6 +17,8 @@ class PyCorrectionlib(PythonPackage): version("2.1.0", sha256="edf79644dc1d9d94f12b4b45366331e5da3f1e21d4cbcd3bb8b0d4b1421b0c44") version("2.0.0", sha256="e4d240cbdb2633a8955ddcd02d5b9bfb33d7e1a33554d6f7957f2dec56988a67") + depends_on("cxx", type="build") # generated + variant( "convert", default=False, @@ -27,7 +29,7 @@ class PyCorrectionlib(PythonPackage): depends_on("py-setuptools@42:", type="build") depends_on("py-setuptools-scm@3.4:+toml", type="build") depends_on("py-scikit-build", type="build") - depends_on("py-cmake@3.11:", type="build") + depends_on("cmake@3.11:", type="build") depends_on("py-make", type="build") depends_on("py-pybind11@2.6.1:", type="build") depends_on("py-numpy@1.13.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-coverage/package.py b/var/spack/repos/builtin/packages/py-coverage/package.py index 19d7d28d83a348..4a3995bf019c6c 100644 --- a/var/spack/repos/builtin/packages/py-coverage/package.py +++ b/var/spack/repos/builtin/packages/py-coverage/package.py @@ -26,6 +26,8 @@ class PyCoverage(PythonPackage): version("4.3.4", sha256="eaaefe0f6aa33de5a65f48dd0040d7fe08cac9ac6c35a56d0a7db109c3e733df") version("4.0a6", sha256="85c7f3efceb3724ab066a3fcccc05b9b89afcaefa5b669a7e2222d31eac4728d") + depends_on("c", type="build") # generated + variant("toml", default=False, description="Enable pyproject.toml support") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-crcmod/package.py b/var/spack/repos/builtin/packages/py-crcmod/package.py index 77b755b1929773..fa32304829978e 100644 --- a/var/spack/repos/builtin/packages/py-crcmod/package.py +++ b/var/spack/repos/builtin/packages/py-crcmod/package.py @@ -18,5 +18,7 @@ class PyCrcmod(PythonPackage): version("1.7", sha256="dc7051a0db5f2bd48665a990d3ec1cc305a466a77358ca4492826f41f283601e") version("1.6", sha256="56d27d035ea029c6ed96779ca042c0136d39d106e3c30baa6422738c7d86aaa5") + depends_on("c", type="build") # generated + depends_on("python@2.4:2.7,3.1:", type=("build", "run")) depends_on("py-setuptools@40.0.0:", type="build") diff --git a/var/spack/repos/builtin/packages/py-cryptography/package.py b/var/spack/repos/builtin/packages/py-cryptography/package.py index 84d63a84ccb5ec..a883c11e04ae4d 100644 --- a/var/spack/repos/builtin/packages/py-cryptography/package.py +++ b/var/spack/repos/builtin/packages/py-cryptography/package.py @@ -15,6 +15,8 @@ class PyCryptography(PythonPackage): license("Apache-2.0") + version("42.0.8", sha256="8d09d05439ce7baa8e9e95b07ec5b6c886f548deb7e0f69ef25f64b3bce842f2") + version("41.0.7", sha256="13f93ce9bea8016c253b34afc6bd6a75993e5c40672ed5405a9c832f0d4a00bc") version("41.0.3", sha256="6d192741113ef5e30d89dcb5b956ef4e1578f304708701b8b73d38e3e1461f34") version("40.0.2", sha256="c33c0d32b8594fa647d2e01dbccc303478e16fdd7cf98652d5b3ed11aa5e5c99") version("38.0.1", sha256="1db3d807a14931fa317f96435695d9ec386be7b84b618cc61cfa5d08b0ae33d7") @@ -39,6 +41,7 @@ class PyCryptography(PythonPackage): depends_on("py-setuptools@40.6:", when="@2.7:36", type="build") depends_on("py-setuptools@18.5:", when="@2.2:2.6", type="build") depends_on("py-setuptools@11.3:", when="@:2.1", type="build") + depends_on("py-setuptools-rust@1.7.0:", when="@42:", type=("build", "run")) depends_on("py-setuptools-rust@0.11.4:", when="@3.4.2:", type="build") depends_on("py-setuptools-rust@0.11.4:", when="@3.4:3.4.1", type=("build", "run")) depends_on("rust@1.56:", when="@41:", type="build") diff --git a/var/spack/repos/builtin/packages/py-cudf/package.py b/var/spack/repos/builtin/packages/py-cudf/package.py index 0bf97fbfed0b91..36bc72bdc34dc0 100644 --- a/var/spack/repos/builtin/packages/py-cudf/package.py +++ b/var/spack/repos/builtin/packages/py-cudf/package.py @@ -20,6 +20,8 @@ class PyCudf(PythonPackage): version("0.15.0", sha256="2570636b72cce4c52f71e36307f51f630e2f9ea94a1abc018d40ce919ba990e4") + depends_on("cxx", type="build") # generated + build_directory = "python/cudf" depends_on("cmake@3.14:", type="build") diff --git a/var/spack/repos/builtin/packages/py-cuml/package.py b/var/spack/repos/builtin/packages/py-cuml/package.py index 4ad9862b893875..a3afb09999b1e0 100644 --- a/var/spack/repos/builtin/packages/py-cuml/package.py +++ b/var/spack/repos/builtin/packages/py-cuml/package.py @@ -18,6 +18,8 @@ class PyCuml(PythonPackage): version("0.15.0", sha256="5c9c656ae4eaa94a426e07d7385fd5ea0e5dc7abff806af2941aee10d4ca99c7") + depends_on("cxx", type="build") # generated + depends_on("python@3.7:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-cupy/package.py b/var/spack/repos/builtin/packages/py-cupy/package.py index 1ba1c3b37b7b06..8865cb68060b32 100644 --- a/var/spack/repos/builtin/packages/py-cupy/package.py +++ b/var/spack/repos/builtin/packages/py-cupy/package.py @@ -18,6 +18,7 @@ class PyCupy(PythonPackage, CudaPackage, ROCmPackage): homepage = "https://cupy.dev/" pypi = "cupy/cupy-8.0.0.tar.gz" + version("13.1.0", sha256="5caf62288481a27713384523623045380ff42e618be4245f478238ed1786f32d") version("12.1.0", sha256="f6d31989cdb2d96581da12822e28b102f29e254427195c2017eac327869b7320") version("12.0.0", sha256="61ddbbef73d50d606bd5087570645f3c91ec9176c2566784c1d486d6a3404545") version("11.6.0", sha256="53dbb840072bb32d4bfbaa6bfa072365a30c98b1fcd1f43e48969071ad98f1a7") @@ -26,6 +27,8 @@ class PyCupy(PythonPackage, CudaPackage, ROCmPackage): version("11.3.0", sha256="d057cc2f73ecca06fae8b9c270d9e14116203abfd211a704810cc50a453b4c9e") version("11.2.0", sha256="c33361f117a347a63f6996ea97446d17f1c038f1a1f533e502464235076923e2") + depends_on("cxx", type="build") # generated + variant("all", default=False, description="Enable optional py-scipy, optuna, and cython") depends_on("python@3.7:", when="@:11", type=("build", "run")) @@ -35,20 +38,24 @@ class PyCupy(PythonPackage, CudaPackage, ROCmPackage): depends_on("py-fastrlock@0.5:", type=("build", "run")) depends_on("py-numpy@1.20:1.25", when="@:11", type=("build", "run")) depends_on("py-numpy@1.20:1.26", when="@12:", type=("build", "run")) + depends_on("py-numpy@1.22:1.28", when="@13:", type=("build", "run")) - depends_on("py-scipy@1.6:1.12", when="+all", type=("build", "run")) + depends_on("py-scipy@1.6:1.12", when="@:12+all", type=("build", "run")) + depends_on("py-scipy@1.7:1.13", when="@13:+all", type=("build", "run")) depends_on("py-cython@0.29.22:2", when="+all", type=("build", "run")) depends_on("py-optuna@2:", when="+all", type=("build", "run")) # Based on https://github.com/cupy/cupy/releases depends_on("cuda@:11.9", when="@:11 +cuda") - depends_on("cuda@:12.1", when="@12: +cuda") + depends_on("cuda@:12.1", when="@12:12.1.0 +cuda") + depends_on("cuda@:12.4", when="@13: +cuda") for a in CudaPackage.cuda_arch_values: depends_on("nccl +cuda cuda_arch={0}".format(a), when="+cuda cuda_arch={0}".format(a)) depends_on("cudnn", when="+cuda") - depends_on("cutensor", when="+cuda") + depends_on("cutensor", when="@:12.1.0 +cuda") + depends_on("cutensor@2.0.1.2", when="@13.1: +cuda") for _arch in ROCmPackage.amdgpu_targets: arch_str = "amdgpu_target={0}".format(_arch) diff --git a/var/spack/repos/builtin/packages/py-cvxopt/package.py b/var/spack/repos/builtin/packages/py-cvxopt/package.py index 2fcf1433e6b5f5..30b62012450b44 100644 --- a/var/spack/repos/builtin/packages/py-cvxopt/package.py +++ b/var/spack/repos/builtin/packages/py-cvxopt/package.py @@ -17,6 +17,8 @@ class PyCvxopt(PythonPackage): version("1.2.5", sha256="94ec8c36bd6628a11de9014346692daeeef99b3b7bae28cef30c7490bbcb2d72") + depends_on("c", type="build") # generated + variant( "gsl", default=False, diff --git a/var/spack/repos/builtin/packages/py-cvxpy/package.py b/var/spack/repos/builtin/packages/py-cvxpy/package.py index 828982503dd57a..fcf3856aced39a 100644 --- a/var/spack/repos/builtin/packages/py-cvxpy/package.py +++ b/var/spack/repos/builtin/packages/py-cvxpy/package.py @@ -18,6 +18,8 @@ class PyCvxpy(PythonPackage): version("1.1.13", sha256="a9c781e74ad76097b47b86456cb3a943898f7ec9ac8f47bcefc922051cdc4a04") version("1.0.25", sha256="8535529ddb807067b0d59661dce1d9a6ddb2a218398a38ea7772328ad8a6ea13") + depends_on("cxx", type="build") # generated + # Dependency versions based on README.md in python packages depends_on("python@3.4:", type=("build", "run"), when="@1.1:") depends_on("python@3.6:", type=("build", "run"), when="@1.1.13:") diff --git a/var/spack/repos/builtin/packages/py-cx-oracle/package.py b/var/spack/repos/builtin/packages/py-cx-oracle/package.py index 34c6b76002bccd..c93c005b575d82 100644 --- a/var/spack/repos/builtin/packages/py-cx-oracle/package.py +++ b/var/spack/repos/builtin/packages/py-cx-oracle/package.py @@ -14,6 +14,8 @@ class PyCxOracle(PythonPackage): version("8.3.0", sha256="3b2d215af4441463c97ea469b9cc307460739f89fdfa8ea222ea3518f1a424d9") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("oracle-instant-client", type="run") depends_on("py-setuptools@40.6.0:", type="build") diff --git a/var/spack/repos/builtin/packages/py-cylp/package.py b/var/spack/repos/builtin/packages/py-cylp/package.py index ac9301f0ddcaa9..90b0254768439e 100644 --- a/var/spack/repos/builtin/packages/py-cylp/package.py +++ b/var/spack/repos/builtin/packages/py-cylp/package.py @@ -21,6 +21,8 @@ class PyCylp(PythonPackage): version("0.91.5", sha256="d68ab1dde125be60abf45c8fd9edd24ab880c8144ad881718ddfa01ff6674c77") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cython@:2", type="build") diff --git a/var/spack/repos/builtin/packages/py-cyordereddict/package.py b/var/spack/repos/builtin/packages/py-cyordereddict/package.py index debfa13e6a49f1..11be0d688eeaa3 100644 --- a/var/spack/repos/builtin/packages/py-cyordereddict/package.py +++ b/var/spack/repos/builtin/packages/py-cyordereddict/package.py @@ -18,4 +18,6 @@ class PyCyordereddict(PythonPackage): version("1.0.0", sha256="d9b2c31796999770801a9a49403b8cb49510ecb64e5d1e9d4763ed44f2d5a76e") version("0.2.2", sha256="f8387caaffba695d704311842291ede696080a5ed306f07f1825de126fb7f1ec") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-cython-bbox/package.py b/var/spack/repos/builtin/packages/py-cython-bbox/package.py index 9320d12e3cbcc0..58978a14081977 100644 --- a/var/spack/repos/builtin/packages/py-cython-bbox/package.py +++ b/var/spack/repos/builtin/packages/py-cython-bbox/package.py @@ -19,6 +19,8 @@ class PyCythonBbox(PythonPackage): pypi = "cython-bbox/cython_bbox-0.1.3.tar.gz" version("0.1.3", sha256="82e2d887534ecc10d3507489a05b11259f3baacd29eee37e6d8c97e1ffb16554") + + depends_on("c", type="build") # generated depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-cython/package.py b/var/spack/repos/builtin/packages/py-cython/package.py index e4acf657b41c06..182a3286a25e54 100644 --- a/var/spack/repos/builtin/packages/py-cython/package.py +++ b/var/spack/repos/builtin/packages/py-cython/package.py @@ -15,6 +15,7 @@ class PyCython(PythonPackage): license("Apache-2.0") + version("3.0.10", sha256="dcc96739331fb854dcf503f94607576cfe8488066c61ca50dfd55836f132de99") version("3.0.8", sha256="8333423d8fd5765e7cceea3a9985dd1e0a5dfeb2734629e1a2ed2d6233d39de6") version("3.0.7", sha256="fb299acf3a578573c190c858d49e0cf9d75f4bc49c3f24c5a63804997ef09213") version("3.0.6", sha256="399d185672c667b26eabbdca420c98564583798af3bc47670a8a09e9f19dd660") @@ -47,6 +48,9 @@ class PyCython(PythonPackage): version("0.23.5", sha256="0ae5a5451a190e03ee36922c4189ca2c88d1df40a89b4f224bc842d388a0d1b6") version("0.23.4", sha256="fec42fecee35d6cc02887f1eef4e4952c97402ed2800bfe41bbd9ed1a0730d8e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # https://github.com/cython/cython/issues/5751 (distutils not yet dropped) depends_on("python@:3.11", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/py-cyvcf2/package.py b/var/spack/repos/builtin/packages/py-cyvcf2/package.py index f00894b9e50c8b..d8954dc6c3d74e 100644 --- a/var/spack/repos/builtin/packages/py-cyvcf2/package.py +++ b/var/spack/repos/builtin/packages/py-cyvcf2/package.py @@ -16,6 +16,8 @@ class PyCyvcf2(PythonPackage): version("0.11.7", sha256="a4b6229b89a0a1043684c65cbdd702c366a8800dc3591fb44c4b5a08640cbeec") + depends_on("c", type="build") # generated + depends_on("python@2.7:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-d2to1/package.py b/var/spack/repos/builtin/packages/py-d2to1/package.py index c8e89103b0c682..6931eef27e30da 100644 --- a/var/spack/repos/builtin/packages/py-d2to1/package.py +++ b/var/spack/repos/builtin/packages/py-d2to1/package.py @@ -19,4 +19,6 @@ class PyD2to1(PythonPackage): ) version("0.2.12", sha256="04ab9f3ac255d367ecda1eb59379e5031816740c3a3eda95d0dba9f6bb3b7ca4") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-dace/package.py b/var/spack/repos/builtin/packages/py-dace/package.py index bfa8bf0d80efbe..2eae218cde2c56 100644 --- a/var/spack/repos/builtin/packages/py-dace/package.py +++ b/var/spack/repos/builtin/packages/py-dace/package.py @@ -21,6 +21,8 @@ class PyDace(PythonPackage): version("master", branch="master", submodules=True) version("0.15.1", sha256="69bfdbbd5c7177f2926a874f5fa82fcdef61fc532c022b4bc12e1e9218724093") + depends_on("cxx", type="build") # generated + variant( "counters", description="Optional requirements that enable performance counter collection.", diff --git a/var/spack/repos/builtin/packages/py-dadi/package.py b/var/spack/repos/builtin/packages/py-dadi/package.py index e059fb9411e1b5..906db1628f203e 100644 --- a/var/spack/repos/builtin/packages/py-dadi/package.py +++ b/var/spack/repos/builtin/packages/py-dadi/package.py @@ -21,6 +21,8 @@ class PyDadi(PythonPackage): version("2020-12-02", commit="047bac0db5245009d9c724e91a851149c34c9de0") version("2.1.0", sha256="97a15aa7ef501850cad4cff66b11b66ecb65d5d68acbf2ff713585c81c3a1038") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type=("build")) depends_on("python@3:", type=("build", "run")) depends_on("py-scipy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-damask/package.py b/var/spack/repos/builtin/packages/py-damask/package.py index c56773e98b4500..1f8106b15d5cb8 100644 --- a/var/spack/repos/builtin/packages/py-damask/package.py +++ b/var/spack/repos/builtin/packages/py-damask/package.py @@ -36,6 +36,9 @@ class PyDamask(PythonPackage): "3.0.0-alpha4", sha256="0bb8bde43b27d852b1fb6e359a7157354544557ad83d87987b03f5d629ce5493" ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("py-pandas@0.24:", type=("build", "run"), when="@3.0.0-alpha8:") depends_on("py-numpy@1.17:", type=("build", "run"), when="@3.0.0-alpha8:") depends_on("py-scipy@1.2:", type=("build", "run"), when="@3.0.0-alpha8:") diff --git a/var/spack/repos/builtin/packages/py-darshan/package.py b/var/spack/repos/builtin/packages/py-darshan/package.py index 4b9c929e25752f..b6124eb9cb5412 100644 --- a/var/spack/repos/builtin/packages/py-darshan/package.py +++ b/var/spack/repos/builtin/packages/py-darshan/package.py @@ -14,14 +14,18 @@ class PyDarshan(PythonPackage): maintainers("jeanbez", "shanedsnyder") + version("3.4.5.0", sha256="1419e246b2383d3e71da14942d6579a86fb298bf6dbbc3f507accefa614c6e50") version("3.4.4.0", sha256="2d218a1b2a450934698a78148c6603e453c246ec852679432bf217981668e56b") version("3.4.3.0", sha256="e0708fc5445f2d491ebd381a253cd67534cef13b963f1d749dd605a10f5c0f8f") version("3.4.2.0", sha256="eb00eb758c96899c0d523b71eb00caa3b967509c27fd504c579ac8c9b521845c") version("3.4.1.0", sha256="41a033ebac6fcd0ca05b8ccf07e11191286dee923ec334b876a7ec8e8a6add84") version("3.4.0.1", sha256="0142fc7c0b12a9e5c22358aa26cca7083d28af42aeea7dfcc5698c56b6aee6b7") + depends_on("c", type="build") # generated + depends_on("python@3.7:", type=("build", "run")) - depends_on("py-setuptools@:63", type="build") + depends_on("py-setuptools@:63", when="@:3.4.4", type="build") + depends_on("py-setuptools@64:", when="@3.4.5:", type="build") depends_on("py-pytest-runner", type="build") depends_on("py-cffi", type=("build", "run")) # NOTE: SciPy is an indirect dependency needed for interpolate usage in pandas @@ -34,6 +38,9 @@ class PyDarshan(PythonPackage): depends_on("py-mako", type=("build", "run")) depends_on("py-humanize", when="@3.4.3.0:", type=("build", "run")) depends_on("py-pytest", type="test") + depends_on("py-packaging", type="test") + depends_on("py-lxml", type="test") + depends_on("py-importlib-resources", when="^python@:3.8", type="test") # py-darshan depends on specific darshan-util versions corresponding # to the first 3 parts of the py-darshan version string diff --git a/var/spack/repos/builtin/packages/py-dask/package.py b/var/spack/repos/builtin/packages/py-dask/package.py index 5980a9efe4368e..87403780981414 100644 --- a/var/spack/repos/builtin/packages/py-dask/package.py +++ b/var/spack/repos/builtin/packages/py-dask/package.py @@ -63,6 +63,8 @@ class PyDask(PythonPackage): depends_on("py-numpy@1.16.0:", type=("build", "run"), when="@2021.3.1: +array") depends_on("py-numpy@1.18.0:", type=("build", "run"), when="@2022.10.2: +array") depends_on("py-numpy@1.21.0:", type=("build", "run"), when="@2023.4.0: +array") + # https://github.com/dask/dask/issues/11066 + depends_on("py-numpy@:1", when="@:2024.5.0+array", type=("build", "run")) # The dependency on py-toolz is non-optional starting version 2021.3.1 depends_on("py-toolz@0.8.2:", type=("build", "run"), when="@:2021.3.0 +array") @@ -82,6 +84,8 @@ class PyDask(PythonPackage): depends_on("py-numpy@1.16.0:", type=("build", "run"), when="@2021.3.1: +dataframe") depends_on("py-numpy@1.18.0:", type=("build", "run"), when="@2022.10.2: +dataframe") depends_on("py-numpy@1.21.0:", type=("build", "run"), when="@2023.4.0: +dataframe") + # https://github.com/dask/dask/issues/11066 + depends_on("py-numpy@:1", when="@:2024.5.0+dataframe", type=("build", "run")) depends_on("py-pandas@0.25.0:", type=("build", "run"), when="@2020.12.0: +dataframe") depends_on("py-pandas@1.0:", type=("build", "run"), when="@2022.10.2: +dataframe") depends_on("py-pandas@1.3:", type=("build", "run"), when="@2023.4.0: +dataframe") diff --git a/var/spack/repos/builtin/packages/py-datasets/package.py b/var/spack/repos/builtin/packages/py-datasets/package.py index a85a40531c3a7a..03ecf1c792cc15 100644 --- a/var/spack/repos/builtin/packages/py-datasets/package.py +++ b/var/spack/repos/builtin/packages/py-datasets/package.py @@ -18,30 +18,46 @@ class PyDatasets(PythonPackage): license("Apache-2.0") + version("2.20.0", sha256="3c4dbcd27e0f642b9d41d20ff2efa721a5e04b32b2ca4009e0fc9139e324553f") version("2.8.0", sha256="a843b69593914071f921fc1086fde939f30a63415a34cdda5db3c0acdd58aff2") version("1.8.0", sha256="d57c32bb29e453ee7f3eb0bbca3660ab4dd2d0e4648efcfa987432624cab29d3") - depends_on("python@3.6:", type=("build", "run")) - depends_on("py-setuptools", type="build") - depends_on("py-numpy@1.17:", type=("build", "run")) - depends_on("py-pyarrow@1:3+parquet", type=("build", "run"), when="@:1.8.0") - depends_on("py-pyarrow@6:+parquet", type=("build", "run"), when="@2.8.0:") - depends_on("py-dill@:0.3.6", type=("build", "run")) - depends_on("py-pandas", type=("build", "run")) - depends_on("py-requests@2.19:", type=("build", "run")) - depends_on("py-tqdm@4.27:4.49", type=("build", "run"), when="@:1.8.0") - depends_on("py-tqdm@4.62.1:", type=("build", "run"), when="@2.8.0:") - depends_on("py-xxhash", type=("build", "run")) - depends_on("py-multiprocess", type=("build", "run")) - depends_on("py-importlib-metadata", when="^python@:3.7", type=("build", "run")) - depends_on("py-huggingface-hub@:0.0", type=("build", "run"), when="@:1.8.0") - depends_on("py-huggingface-hub@0.2:0", type=("build", "run"), when="@2.8.0:") - depends_on("py-packaging", type=("build", "run")) - depends_on("py-aiohttp", type=("build", "run"), when="@2.8.0:") - depends_on("py-responses@:0.18", type=("build", "run"), when="@2.8.0:") - depends_on("py-pyyaml@5.1:", type=("build", "run"), when="@2.8.0:") - - with when("@:1.8.0"): - depends_on("py-fsspec", type=("build", "run"), when="^python@3.8:") - depends_on("py-fsspec@:0.8.0", type=("build", "run"), when="^python@:3.7") - depends_on("py-fsspec@2021.11.1:+http", type=("build", "run"), when="@2.8.0:") + with default_args(type="build"): + depends_on("py-setuptools") + + with default_args(type=("build", "run")): + depends_on("python@3.6:") + depends_on("py-numpy@1.17:") + depends_on("py-pandas") + depends_on("py-requests@2.19:") + depends_on("py-xxhash") + depends_on("py-multiprocess") + depends_on("py-packaging") + with when("@:1.8.0"): + depends_on("py-dill@:0.3.6") + depends_on("py-fsspec", when="^python@3.8:") + depends_on("py-fsspec@:0.8.0", when="^python@:3.7") + depends_on("py-huggingface-hub@:0.0") + depends_on("py-importlib-metadata", when="^python@:3.7") + depends_on("py-pyarrow@1:3+parquet") + depends_on("py-tqdm@4.27:4.49", when="@:1.8.0") + with when("@2.8.0:"): + depends_on("py-aiohttp") + depends_on("py-pyyaml@5.1:") + depends_on("python@3.7:") + with when("@2.8.0"): + depends_on("py-dill@:0.3.6") + depends_on("py-fsspec@2021.11.1:+http") + depends_on("py-huggingface-hub@0.2:0") + depends_on("py-pyarrow@6:+parquet") + depends_on("py-responses@:0.18") + depends_on("py-tqdm@4.62.1:") + with when("@2.20.0:"): + depends_on("py-filelock") + depends_on("py-dill@0.3.0:0.3.8") # temporary upper bound + depends_on("py-fsspec@2023.1.0:2024.5.0+http") + depends_on("py-huggingface-hub@0.21.2:") + depends_on("py-pyarrow@15:+parquet") + depends_on("py-requests@2.32.2:") + depends_on("py-tqdm@4.66.3:") + depends_on("python@3.8:") diff --git a/var/spack/repos/builtin/packages/py-datrie/package.py b/var/spack/repos/builtin/packages/py-datrie/package.py index 9bb763aed512c3..559ad594d8dbc3 100644 --- a/var/spack/repos/builtin/packages/py-datrie/package.py +++ b/var/spack/repos/builtin/packages/py-datrie/package.py @@ -16,6 +16,8 @@ class PyDatrie(PythonPackage): version("0.8.2", sha256="525b08f638d5cf6115df6ccd818e5a01298cd230b2dac91c8ff2e6499d18765d") + depends_on("c", type="build") # generated + depends_on("python@2.7:2.8,3.4:", type=("build", "run")) depends_on("py-setuptools@40.8:", type=("build")) depends_on("py-cython@0.28:", type="build") diff --git a/var/spack/repos/builtin/packages/py-deap/package.py b/var/spack/repos/builtin/packages/py-deap/package.py index cc4085cc65ff06..22589fcb86024c 100644 --- a/var/spack/repos/builtin/packages/py-deap/package.py +++ b/var/spack/repos/builtin/packages/py-deap/package.py @@ -17,6 +17,9 @@ class PyDeap(PythonPackage): version("1.3.3", sha256="8772f1b0fff042d5e516b0aebac2c706243045aa7d0de8e0b8658f380181cf31") version("1.3.1", sha256="11f54493ceb54aae10dde676577ef59fc52d52f82729d5a12c90b0813c857a2f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") # uses 2to3 depends_on("py-setuptools@:57", type="build", when="@1.3.1") diff --git a/var/spack/repos/builtin/packages/py-deephyper/package.py b/var/spack/repos/builtin/packages/py-deephyper/package.py index 2bde1cff747316..80b67dfb918bc6 100644 --- a/var/spack/repos/builtin/packages/py-deephyper/package.py +++ b/var/spack/repos/builtin/packages/py-deephyper/package.py @@ -20,22 +20,32 @@ class PyDeephyper(PythonPackage): license("BSD-3-Clause") version("master", branch="master") + version("0.6.0", sha256="cda2dd7c74bdca4203d9cd637c4f441595f77bae6d77ef8e4a056b005357de34") version("0.4.2", sha256="ee1811a22b08eff3c9098f63fbbb37f7c8703e2f878f2bdf2ec35a978512867f") depends_on("python@3.7:3.9", type=("build", "run")) + depends_on("python@3.7:3.11", type=("build", "run"), when="@0.6.0") + depends_on("py-setuptools@42:", type="build", when="@0.6.0") depends_on("py-setuptools@40:49.1", type="build") depends_on("py-wheel@0.36.2", type="build") - depends_on("py-cython@0.29.24:2", type="build") + depends_on("py-cython@0.29.24:", type="build", when="@0.6.0") + depends_on("py-cython@0.29.24:2", type="build", when="@0.4.2") depends_on("py-configspace@0.4.20:", type=("build", "run")) depends_on("py-dm-tree", type=("build", "run")) - depends_on("py-jinja2@:3.0", type=("build", "run")) + depends_on("py-jinja2@:3.1", type=("build", "run"), when="@0.6.0") + depends_on("py-jinja2@:3.0", type=("build", "run"), when="@0.4.2") + depends_on("py-numpy@1.20:", type=("build", "run"), when="@0.6.0") depends_on("py-numpy", type=("build", "run")) depends_on("py-pandas@0.24.2:", type=("build", "run")) depends_on("py-packaging", type=("build", "run")) + depends_on( + "py-packaging@20.5:", type=("build", "run"), when="@0.6.0 target=aarch64: platform=darwin" + ) depends_on("py-scikit-learn@0.23.1:", type=("build", "run")) + depends_on("py-scipy@1.7:", type=("build", "run"), when="@0.6.0") depends_on("py-scipy@0.19.1:", type=("build", "run")) depends_on("py-tqdm@4.64.0:", type=("build", "run")) depends_on("py-pyyaml", type=("build", "run")) - depends_on("py-tinydb", type=("build", "run")) + depends_on("py-tinydb", type=("build", "run"), when="@0.4.2") diff --git a/var/spack/repos/builtin/packages/py-deepspeed/package.py b/var/spack/repos/builtin/packages/py-deepspeed/package.py index e73d9552863d42..5b4321f24815d9 100644 --- a/var/spack/repos/builtin/packages/py-deepspeed/package.py +++ b/var/spack/repos/builtin/packages/py-deepspeed/package.py @@ -21,9 +21,11 @@ class PyDeepspeed(PythonPackage): version("0.10.0", sha256="afb06a97fde2a33d0cbd60a8357a70087c037b9f647ca48377728330c35eff3e") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-hjson", type=("build", "run")) - depends_on("py-ninja", type=("build", "run")) + depends_on("ninja", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) depends_on("py-packaging@20:", type=("build", "run")) depends_on("py-psutil", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-deeptoolsintervals/package.py b/var/spack/repos/builtin/packages/py-deeptoolsintervals/package.py index ac13c36108982f..c8b7c62907d8fd 100644 --- a/var/spack/repos/builtin/packages/py-deeptoolsintervals/package.py +++ b/var/spack/repos/builtin/packages/py-deeptoolsintervals/package.py @@ -16,5 +16,7 @@ class PyDeeptoolsintervals(PythonPackage): version("0.1.9", sha256="7d94c36fd2b6f10d8b99e536d2672e8228971f1fc810497d33527bba2c40d4f6") + depends_on("c", type="build") # generated + depends_on("python@2.7:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-devlib/package.py b/var/spack/repos/builtin/packages/py-devlib/package.py index 941590e0e1e195..8b88231ba7a2a4 100644 --- a/var/spack/repos/builtin/packages/py-devlib/package.py +++ b/var/spack/repos/builtin/packages/py-devlib/package.py @@ -23,6 +23,8 @@ class PyDevlib(PythonPackage): version("0.0.3", sha256="29ec5f1de481783ab0b9efc111dfeb67c890187d56fca8592b25ee756ff32902") version("0.0.2", sha256="972f33be16a06572a19b67d909ee0ed6cb6f21f9a9da3c43fd0ff5851421051d") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-python-dateutil", type=("build", "run")) depends_on("py-pexpect@3.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-dgl/package.py b/var/spack/repos/builtin/packages/py-dgl/package.py index 10c6cc2e3e3aa6..f16980179eba06 100644 --- a/var/spack/repos/builtin/packages/py-dgl/package.py +++ b/var/spack/repos/builtin/packages/py-dgl/package.py @@ -34,6 +34,10 @@ class PyDgl(CMakePackage, PythonExtension, CudaPackage): "0.4.2", tag="0.4.2", commit="55e056fbae8f25f3da4aab0a0d864d72c2a445ff", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("cuda", default=True, description="Build with CUDA") variant("openmp", default=True, description="Build with OpenMP") variant( diff --git a/var/spack/repos/builtin/packages/py-dipy/package.py b/var/spack/repos/builtin/packages/py-dipy/package.py index dfc95a71b76f46..23d5d4ff32f244 100644 --- a/var/spack/repos/builtin/packages/py-dipy/package.py +++ b/var/spack/repos/builtin/packages/py-dipy/package.py @@ -22,6 +22,8 @@ class PyDipy(PythonPackage): version("1.7.0", sha256="59bb647128aae7793215c813bb8ea35dae260ac9f0d938c724064f0af5a05cc3") version("1.4.1", sha256="b4bf830feae751f3f985d54cb71031fc35cea612838320f1f74246692b8a3cc0") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("python@:3.9", type=("build", "run"), when="@:1.4") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-distance/package.py b/var/spack/repos/builtin/packages/py-distance/package.py index 214471881bb0ae..447a0c9abe9559 100644 --- a/var/spack/repos/builtin/packages/py-distance/package.py +++ b/var/spack/repos/builtin/packages/py-distance/package.py @@ -19,4 +19,6 @@ class PyDistance(PythonPackage): version("0.1.3", sha256="60807584f5b6003f5c521aa73f39f51f631de3be5cccc5a1d67166fcbf0d4551") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-distlib/package.py b/var/spack/repos/builtin/packages/py-distlib/package.py index 664f6621aa36a8..91bb8bbbbdad84 100644 --- a/var/spack/repos/builtin/packages/py-distlib/package.py +++ b/var/spack/repos/builtin/packages/py-distlib/package.py @@ -19,6 +19,8 @@ class PyDistlib(PythonPackage): version("0.3.4", sha256="e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579") version("0.3.3", sha256="d982d0751ff6eaaab5e2ec8e691d949ee80eddf01a62eaa96ddb11531fe16b05") + depends_on("c", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") depends_on("py-setuptools@44:", when="@0.3.6:", type="build") diff --git a/var/spack/repos/builtin/packages/py-django/package.py b/var/spack/repos/builtin/packages/py-django/package.py index 96b8e4cf73715f..75411a79673fae 100644 --- a/var/spack/repos/builtin/packages/py-django/package.py +++ b/var/spack/repos/builtin/packages/py-django/package.py @@ -10,21 +10,28 @@ class PyDjango(PythonPackage): """The Web framework for perfectionists with deadlines.""" homepage = "https://www.djangoproject.com/" - url = "https://github.com/django/django/archive/3.0.5.tar.gz" + pypi = "Django/Django-5.0.1.tar.gz" license("BSD-3-Clause") - version("3.0.5", sha256="ef2d4f26414dc9598afce9c56cee4578313b88861cedfc5b3d9a71078e5cc79b") - version("3.0.4", sha256="99699643d83acfab51d3ad73c2c2904173e03a4f59fe24c3d494e4fafc0b679f") - version("3.0.3", sha256="d953c950f0c395db065c8bc39d20e87faded376632a3aacf889ae92d5adaac8b") - version("3.0.2", sha256="ca316b1179a16931ed872ce970aabefcf3d41fe0d4b1a8e1301ec59e1e0ab45b") - version("3.0.1", sha256="85349b9366364847264b2b707ffcff5a27a022afa29aac0e904ca672cbe5ee65") - version("2.2.12", sha256="ec490c67bd2780b4ec4f5355cd99fa2fa6007f81695dd45a9e8f7ccc5ff17772") - version("2.2.11", sha256="f4274181973f0f021cc00419cfa342f1a6f862406e766ae93e7fbba9d84c680c") - version("2.2.10", sha256="3741536cf122d6695e8575b2fcf67c18812751fd3143393ea75c01a277afdacc") + version("5.0.1", sha256="8c8659665bc6e3a44fefe1ab0a291e5a3fb3979f9a8230be29de975e57e8f854") + version("3.0.5", sha256="d4666c2edefa38c5ede0ec1655424c56dc47ceb04b6d8d62a7eac09db89545c1") + version("3.0.4", sha256="50b781f6cbeb98f673aa76ed8e572a019a45e52bdd4ad09001072dfd91ab07c8") + version("3.0.3", sha256="2f1ba1db8648484dd5c238fb62504777b7ad090c81c5f1fd8d5eb5ec21b5f283") + version("3.0.2", sha256="8c3575f81e11390893860d97e1e0154c47512f180ea55bd84ce8fa69ba8051ca") + version("3.0.1", sha256="315b11ea265dd15348d47f2cbb044ef71da2018f6e582fed875c889758e6f844") + version("2.2.12", sha256="69897097095f336d5aeef45b4103dceae51c00afa6d3ae198a2a18e519791b7a") + version("2.2.11", sha256="65e2387e6bde531d3bb803244a2b74e0253550a9612c64a60c8c5be267b30f50") + version("2.2.10", sha256="1226168be1b1c7efd0e66ee79b0e0b58b2caa7ed87717909cd8a57bb13a7079a") + depends_on("python@3.10:", when="@5:", type=("build", "run")) + depends_on("py-setuptools@40.8:", when="@5:", type="build") depends_on("py-setuptools", type="build") - depends_on("python@3.6:", type=("build", "run")) - depends_on("py-pytz", type=("build", "run")) - depends_on("py-sqlparse", type=("build", "run")) + depends_on("py-asgiref@3.7:3", when="@5:", type=("build", "run")) depends_on("py-asgiref", type=("build", "run")) + depends_on("py-sqlparse@0.3.1:", when="@5:", type=("build", "run")) + depends_on("py-sqlparse", type=("build", "run")) + depends_on("py-tzdata", when="@5: platform=windows", type=("build", "run")) + + # Historical dependencies + depends_on("py-pytz", when="@:3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-dlio-profiler-py/package.py b/var/spack/repos/builtin/packages/py-dlio-profiler-py/package.py index 4c408c5ebf0d5f..0bb2d7a86c1cfe 100644 --- a/var/spack/repos/builtin/packages/py-dlio-profiler-py/package.py +++ b/var/spack/repos/builtin/packages/py-dlio-profiler-py/package.py @@ -17,21 +17,26 @@ class PyDlioProfilerPy(PythonPackage): version("develop", branch="dev") version("master", branch="master") + version("0.0.5", tag="v0.0.5", commit="08f1a43c67c8dbb458d547020674c86118c9742e") + version("0.0.4", tag="v0.0.4", commit="f9ba207f4c3e3789eb7759653a94013e6b76c91c") + version("0.0.3", tag="v0.0.3", commit="531f4475cf03312e121c78bf644445882b51ad57") version("0.0.2", tag="v0.0.2", commit="b72144abf1499e03d1db87ef51e780633e9e9533") version("0.0.1", tag="v0.0.1", commit="28affe716211315dd6936ddc8e25ce6c43cdf491") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cpp-logger@0.0.1", when="@:0.0.1") - depends_on("cpp-logger@0.0.2", when="@0.0.2:") + depends_on("cpp-logger@0.0.2", when="@0.0.2") + depends_on("cpp-logger@0.0.3", when="@0.0.3:") depends_on("brahma@0.0.1", when="@:0.0.1") - depends_on("brahma@0.0.2", when="@0.0.2:") - depends_on("gotcha@1.0.4", when="@:0.0.1") - depends_on("gotcha@1.0.5", when="@0.0.2:") - depends_on("gotcha@1.0.5", when="@0.0.2:") + depends_on("brahma@0.0.2", when="@0.0.2") + depends_on("brahma@0.0.3", when="@0.0.3:") depends_on("yaml-cpp@0.6.3", when="@0.0.2:") depends_on("py-setuptools@42:", type="build") depends_on("py-pybind11", type=("build", "run")) - depends_on("py-ninja", type="build") - depends_on("py-cmake@3.12:", type="build") + depends_on("ninja", type="build") + depends_on("cmake@3.12:", type="build") def setup_build_environment(self, env): env.set("DLIO_PROFILER_DIR", self.prefix) diff --git a/var/spack/repos/builtin/packages/py-dm-tree/package.py b/var/spack/repos/builtin/packages/py-dm-tree/package.py index bd2d7e4eb3f130..f00909fe73881a 100644 --- a/var/spack/repos/builtin/packages/py-dm-tree/package.py +++ b/var/spack/repos/builtin/packages/py-dm-tree/package.py @@ -26,6 +26,8 @@ class PyDmTree(PythonPackage): version("0.1.6", sha256="6776404b23b4522c01012ffb314632aba092c9541577004ab153321e87da439a") version("0.1.5", sha256="a951d2239111dfcc468071bc8ff792c7b1e3192cab5a3c94d33a8b2bda3127fa") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("cmake", when="@0.1.7:", type="build") depends_on("bazel@:5", when="@:0.1.6", type="build") diff --git a/var/spack/repos/builtin/packages/py-doit/package.py b/var/spack/repos/builtin/packages/py-doit/package.py index fdd111efcde30c..43b6d0fe6174e6 100644 --- a/var/spack/repos/builtin/packages/py-doit/package.py +++ b/var/spack/repos/builtin/packages/py-doit/package.py @@ -16,6 +16,8 @@ class PyDoit(PythonPackage): version("0.36.0", sha256="71d07ccc9514cb22fe59d98999577665eaab57e16f644d04336ae0b4bae234bc") + depends_on("c", type="build") # generated + depends_on("python@3.8:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-cloudpickle", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-dotnetcore2/package.py b/var/spack/repos/builtin/packages/py-dotnetcore2/package.py index 901f10bcc33307..7838bc1d0252fe 100644 --- a/var/spack/repos/builtin/packages/py-dotnetcore2/package.py +++ b/var/spack/repos/builtin/packages/py-dotnetcore2/package.py @@ -13,18 +13,18 @@ class PyDotnetcore2(PythonPackage): homepage = "https://github.com/dotnet/core" + skip_version_audit = ["platform=windows"] + if sys.platform == "darwin": version( "2.1.14", sha256="68182f4b704db401b2012c10ed8a19561f8d487063632f8731c2e58960ca9242", - expand=False, url="https://pypi.io/packages/py3/d/dotnetcore2/dotnetcore2-2.1.14-py3-none-macosx_10_9_x86_64.whl", ) elif sys.platform.startswith("linux"): version( "2.1.14", sha256="d8d83ac30c22a0e48a9a881e117d98da17f95c4098cb9500a35e323b8e4ab737", - expand=False, url="https://pypi.io/packages/py3/d/dotnetcore2/dotnetcore2-2.1.14-py3-none-manylinux1_x86_64.whl", ) diff --git a/var/spack/repos/builtin/packages/py-dulwich/package.py b/var/spack/repos/builtin/packages/py-dulwich/package.py index 928e7d5eff0209..6e9c5027a16baa 100644 --- a/var/spack/repos/builtin/packages/py-dulwich/package.py +++ b/var/spack/repos/builtin/packages/py-dulwich/package.py @@ -24,6 +24,8 @@ class PyDulwich(PythonPackage): version("0.20.15", sha256="fb1773373ec2af896031f8312af6962a1b8b0176a2de3fb3d84a84ec04498888") version("0.20.14", sha256="21d6ee82708f7c67ce3fdcaf1f1407e524f7f4f7411a410a972faa2176baec0d") + depends_on("c", type="build") # generated + depends_on("py-setuptools@61.2:", when="@0.21.6", type="build") depends_on("py-setuptools", type="build") depends_on("py-certifi", when="@:0.20.44", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-eccodes/package.py b/var/spack/repos/builtin/packages/py-eccodes/package.py index bff8f2fdc0308e..b53c545e4a00ca 100644 --- a/var/spack/repos/builtin/packages/py-eccodes/package.py +++ b/var/spack/repos/builtin/packages/py-eccodes/package.py @@ -15,6 +15,7 @@ class PyEccodes(PythonPackage): license("Apache-2.0") version("1.5.0", sha256="e70c8f159140c343c215fd608ddf533be652ff05ad2ff17243c7b66cf92127fa") + version("1.4.2", sha256="63fa80a1d1b445904f486bc396a6a6605df029f4e215acc28ceb1a1ff5eb664f") version("1.3.2", sha256="f282adfdc1bc658356163c9cef1857d4b2bae99399660d3d4fcb145a52d3b2a6") depends_on("py-setuptools", type="build") @@ -42,5 +43,4 @@ def setup_dependent_run_environment(self, env, dependent_spec): def test_selfcheck(self): """checking system setup""" - python = self.spec["python"].command python("-m", "eccodes", "selfcheck") diff --git a/var/spack/repos/builtin/packages/py-ecmwflibs/package.py b/var/spack/repos/builtin/packages/py-ecmwflibs/package.py index 7ed64c30883385..5257a909e5f08e 100644 --- a/var/spack/repos/builtin/packages/py-ecmwflibs/package.py +++ b/var/spack/repos/builtin/packages/py-ecmwflibs/package.py @@ -18,6 +18,9 @@ class PyEcmwflibs(PythonPackage): version("0.6.1", sha256="9f2153d1b4a07038b975b7d6bb89bbf9e88d6bc4e2ef4d4e067e58a2fb5270d3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-findlibs", type=("build", "run")) depends_on("eccodes") diff --git a/var/spack/repos/builtin/packages/py-ecos/package.py b/var/spack/repos/builtin/packages/py-ecos/package.py index d1e44f9ff1eb7a..3eca689c11f051 100644 --- a/var/spack/repos/builtin/packages/py-ecos/package.py +++ b/var/spack/repos/builtin/packages/py-ecos/package.py @@ -22,6 +22,8 @@ class PyEcos(PythonPackage): "2.0.7.post1", sha256="83e90f42b3f32e2a93f255c3cfad2da78dbd859119e93844c45d2fca20bdc758" ) + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy@1.6:", type=("build", "run")) depends_on("py-scipy@0.9:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-editables/package.py b/var/spack/repos/builtin/packages/py-editables/package.py index 990b2db11fd668..8cc8f18bd9711d 100644 --- a/var/spack/repos/builtin/packages/py-editables/package.py +++ b/var/spack/repos/builtin/packages/py-editables/package.py @@ -12,7 +12,10 @@ class PyEditables(PythonPackage): homepage = "https://github.com/pfmoore/editables" pypi = "editables/editables-0.3.tar.gz" + version("0.5", sha256="309627d9b5c4adc0e668d8c6fa7bac1ba7c8c5d415c2d27f60f081f8e80d1de2") + version("0.4", sha256="dc322c42e7ccaf19600874035a4573898d88aadd07e177c239298135b75da772") version("0.3", sha256="167524e377358ed1f1374e61c268f0d7a4bf7dbd046c656f7b410cde16161b1a") depends_on("python@3.7:", type=("build", "run")) - depends_on("py-setuptools@42:", type="build") + depends_on("py-setuptools@42:", type="build", when="@:0.3") + depends_on("py-flit-core@3.3:", type="build", when="@0.4:") diff --git a/var/spack/repos/builtin/packages/py-editdistance/package.py b/var/spack/repos/builtin/packages/py-editdistance/package.py index ca627c31612796..7c717519c83c7a 100644 --- a/var/spack/repos/builtin/packages/py-editdistance/package.py +++ b/var/spack/repos/builtin/packages/py-editdistance/package.py @@ -22,6 +22,8 @@ class PyEditdistance(PythonPackage): version("0.6.2", tag="v0.6.2", commit="3f5a5b0299f36662349df0917352a42c620e3dd4") version("0.4", sha256="c765db6f8817d38922e4a50be4b9ab338b2c539377b6fcf0bca11dea72eeb8c1") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cython", when="@0.6.2:", type="build") depends_on("python@3.6:", when="@0.6.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-edlib/package.py b/var/spack/repos/builtin/packages/py-edlib/package.py index f9f070eb7870f7..c4cf4feaaad92a 100644 --- a/var/spack/repos/builtin/packages/py-edlib/package.py +++ b/var/spack/repos/builtin/packages/py-edlib/package.py @@ -18,4 +18,6 @@ class PyEdlib(PythonPackage): version("1.3.9", sha256="64c3dfab3ebe3e759565a0cc71eb4df23cf3ce1713fd558af3c473dddc2a3766") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-efel/package.py b/var/spack/repos/builtin/packages/py-efel/package.py index 2a1282c38912d2..26fa4ce358c3ac 100644 --- a/var/spack/repos/builtin/packages/py-efel/package.py +++ b/var/spack/repos/builtin/packages/py-efel/package.py @@ -22,5 +22,7 @@ class PyEfel(PythonPackage): version("5.2.0", sha256="ed2c5efe22a4c703a4d9e47775b939009e1456713ac896898ebabf177c60b1dc") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy@1.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-einops/package.py b/var/spack/repos/builtin/packages/py-einops/package.py index 7bb19aafbf3b63..d2c3770e3ac9bb 100644 --- a/var/spack/repos/builtin/packages/py-einops/package.py +++ b/var/spack/repos/builtin/packages/py-einops/package.py @@ -15,7 +15,9 @@ class PyEinops(PythonPackage): pypi = "einops/einops-0.3.2.tar.gz" license("MIT") + maintainers("adamjstewart") + version("0.8.0", sha256="63486517fed345712a8385c100cb279108d9d47e6ae59099b07657e983deae85") version("0.7.0", sha256="b2b04ad6081a3b227080c9bf5e3ace7160357ff03043cd66cc5b2319eb7031d1") version("0.6.1", sha256="f95f8d00f4ded90dbc4b19b6f98b177332614b0357dde66997f3ae5d474dc8c8") version("0.6.0", sha256="6f6c78739316a2e3ccbce8052310497e69da092935e4173f2e76ec4e3a336a35") diff --git a/var/spack/repos/builtin/packages/py-elephant/package.py b/var/spack/repos/builtin/packages/py-elephant/package.py index 2b8a0abfc101f7..9190398cfc4468 100644 --- a/var/spack/repos/builtin/packages/py-elephant/package.py +++ b/var/spack/repos/builtin/packages/py-elephant/package.py @@ -33,6 +33,8 @@ class PyElephant(PythonPackage): version("0.4.1", sha256="86b21a44cbacdc09a6ba6f51738dcd5b42ecd553d73acb29f71a0be7c82eac81") version("0.3.0", sha256="747251ccfb5820bdead6391411b5faf205b4ddf3ababaefe865f50b16540cfef") + depends_on("cxx", type="build") # generated + variant("docs", default=False, description="Install documentation dependencies") variant( "extras", default=False, description="Build with extras for GPFA, ASSET", when="@0.6.4:" diff --git a/var/spack/repos/builtin/packages/py-ephem/package.py b/var/spack/repos/builtin/packages/py-ephem/package.py index 74025e66cbaf24..659d344c3c2704 100644 --- a/var/spack/repos/builtin/packages/py-ephem/package.py +++ b/var/spack/repos/builtin/packages/py-ephem/package.py @@ -17,5 +17,7 @@ class PyEphem(PythonPackage): version("3.7.7.1", sha256="d9d05d85c0d38a79169acaef25964ac9df2d808f0d833354545b9ef681ff584d") + depends_on("c", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-eprosima-fastdds/package.py b/var/spack/repos/builtin/packages/py-eprosima-fastdds/package.py index 1d65cd5f6c97b3..ec965a1a25aaf3 100644 --- a/var/spack/repos/builtin/packages/py-eprosima-fastdds/package.py +++ b/var/spack/repos/builtin/packages/py-eprosima-fastdds/package.py @@ -21,6 +21,8 @@ class PyEprosimaFastdds(CMakePackage, PythonExtension): version("1.2.2", sha256="78c53739a66544b8c91d0016560c267e11bd7fdaf727b3bfbffd44ae65c93c62") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.15:", type="build") extends("python") depends_on("py-pytest", type="test") diff --git a/var/spack/repos/builtin/packages/py-espresso/package.py b/var/spack/repos/builtin/packages/py-espresso/package.py index c189bb45405f3a..ffa05d3a10ef86 100644 --- a/var/spack/repos/builtin/packages/py-espresso/package.py +++ b/var/spack/repos/builtin/packages/py-espresso/package.py @@ -31,6 +31,8 @@ class PyEspresso(CMakePackage): version("4.0.1", sha256="17b7268eeba652a77f861bc534cdd05d206e7641d203a9dd5029b44bd422304b") version("4.0.0", sha256="8e128847447eebd843de24be9b4ad14aa19c028ae48879a5a4535a9683836e6b") + depends_on("cxx", type="build") # generated + # espressomd/espresso#2244 merge upstream patch("2244.patch", when="@4.0.0") diff --git a/var/spack/repos/builtin/packages/py-espressopp/package.py b/var/spack/repos/builtin/packages/py-espressopp/package.py index ecb9512620cb3e..e52ffe7084e0ce 100644 --- a/var/spack/repos/builtin/packages/py-espressopp/package.py +++ b/var/spack/repos/builtin/packages/py-espressopp/package.py @@ -23,6 +23,9 @@ class PyEspressopp(CMakePackage): version("master", branch="master") version("3.0.0", sha256="63518e768a98179ad5ef3be96eabaa4d38063b34962e2278db7d59ed2bb8a32e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("ug", default=False, description="Build user guide") variant("pdf", default=False, description="Build user guide in pdf format") variant("dg", default=False, description="Build developer guide") diff --git a/var/spack/repos/builtin/packages/py-ete3/package.py b/var/spack/repos/builtin/packages/py-ete3/package.py index 85b2f3a4edbf5f..a2dade451bace9 100644 --- a/var/spack/repos/builtin/packages/py-ete3/package.py +++ b/var/spack/repos/builtin/packages/py-ete3/package.py @@ -23,6 +23,8 @@ class PyEte3(PythonPackage): version("3.1.3", sha256="06a3b7fa8ed90187b076a8dbbe5b1b62acee94201d3c6e822f55f449601ef6f2") version("3.1.2", sha256="4fc987b8c529889d6608fab1101f1455cb5cbd42722788de6aea9c7d0a8e59e9") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-exarl/package.py b/var/spack/repos/builtin/packages/py-exarl/package.py index a4fde23a02cef4..9a3db4675f797f 100644 --- a/var/spack/repos/builtin/packages/py-exarl/package.py +++ b/var/spack/repos/builtin/packages/py-exarl/package.py @@ -23,6 +23,8 @@ class PyExarl(PythonPackage): version("update-spack", branch="update-spack") version("0.1.0", tag="v0.1.0", commit="5f5b99884a92f86ea9f637524eca6f4393b9635f") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("git-lfs", type=("build")) depends_on("py-setuptools", type=("build")) diff --git a/var/spack/repos/builtin/packages/py-exodus-bundler/package.py b/var/spack/repos/builtin/packages/py-exodus-bundler/package.py index cbb4fb6d430671..8ac56eb41ba96d 100644 --- a/var/spack/repos/builtin/packages/py-exodus-bundler/package.py +++ b/var/spack/repos/builtin/packages/py-exodus-bundler/package.py @@ -17,6 +17,8 @@ class PyExodusBundler(PythonPackage): version("2.0.2", sha256="4e896a2034b94cf7b4fb33d86a68e29a7d3b08e57541e444db34dddc6ac1ef68") + depends_on("c", type="build") # generated + depends_on("musl", type="run", when="%apple-clang") depends_on("musl", type="run", when="%clang") depends_on("musl", type="run", when="%gcc") diff --git a/var/spack/repos/builtin/packages/py-extension-helpers/package.py b/var/spack/repos/builtin/packages/py-extension-helpers/package.py index 298d78a8b259fa..4005310244be20 100644 --- a/var/spack/repos/builtin/packages/py-extension-helpers/package.py +++ b/var/spack/repos/builtin/packages/py-extension-helpers/package.py @@ -20,5 +20,7 @@ class PyExtensionHelpers(PythonPackage): version("0.1", sha256="ac8a6fe91c6d98986a51a9f08ca0c7945f8fd70d95b662ced4040ae5eb973882") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools@30.3:", type="build") diff --git a/var/spack/repos/builtin/packages/py-f90wrap/package.py b/var/spack/repos/builtin/packages/py-f90wrap/package.py index 705cddc2e8c879..096defc24dd75f 100644 --- a/var/spack/repos/builtin/packages/py-f90wrap/package.py +++ b/var/spack/repos/builtin/packages/py-f90wrap/package.py @@ -19,6 +19,9 @@ class PyF90wrap(PythonPackage): version("0.2.6", sha256="e0748eb5e288be7f47829a272fc230373469fb40afccddf91e9973c56da43dd4") version("0.2.3", sha256="5577ea92934c5aad378df21fb0805b5fb433d6f2b8b9c1bf1a9ec1e3bf842cff") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # TODO errors with python 3.6 due to UnicodeDecodeError depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-fallocate/package.py b/var/spack/repos/builtin/packages/py-fallocate/package.py index ad9927e94f886b..6946b25f6ecbb5 100644 --- a/var/spack/repos/builtin/packages/py-fallocate/package.py +++ b/var/spack/repos/builtin/packages/py-fallocate/package.py @@ -16,5 +16,7 @@ class PyFallocate(PythonPackage): version("1.6.4", sha256="85ebeb2786761fbe80d88c52590a610bd3425fc89e188c208a3f261a5bd6acb3") + depends_on("c", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-fastcache/package.py b/var/spack/repos/builtin/packages/py-fastcache/package.py index 0137184e1a734d..f0fa37406863a7 100644 --- a/var/spack/repos/builtin/packages/py-fastcache/package.py +++ b/var/spack/repos/builtin/packages/py-fastcache/package.py @@ -16,4 +16,6 @@ class PyFastcache(PythonPackage): version("1.1.0", sha256="6de1b16e70335b7bde266707eb401a3aaec220fb66c5d13b02abf0eab8be782b") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-fastcluster/package.py b/var/spack/repos/builtin/packages/py-fastcluster/package.py index 0eb63dc1a1b98c..ce605e2e250d61 100644 --- a/var/spack/repos/builtin/packages/py-fastcluster/package.py +++ b/var/spack/repos/builtin/packages/py-fastcluster/package.py @@ -16,5 +16,7 @@ class PyFastcluster(PythonPackage): version("1.1.26", sha256="a202f44a3b06f5cf9cdba3c67d6c523288922d6e6a1cdf737292f93759aa82f7") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy@1.9:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-fastdtw/package.py b/var/spack/repos/builtin/packages/py-fastdtw/package.py index a7dd56cd65eba7..6341b00db3e8a3 100644 --- a/var/spack/repos/builtin/packages/py-fastdtw/package.py +++ b/var/spack/repos/builtin/packages/py-fastdtw/package.py @@ -21,6 +21,8 @@ class PyFastdtw(PythonPackage): version("0.3.4", sha256="2350fa6ec36bcad186eaf81f46eff35181baf04e324f522de8aeb43d0243f64f") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-fastfold/package.py b/var/spack/repos/builtin/packages/py-fastfold/package.py index 6d741ead6c8c6f..4a49c573df7443 100644 --- a/var/spack/repos/builtin/packages/py-fastfold/package.py +++ b/var/spack/repos/builtin/packages/py-fastfold/package.py @@ -17,6 +17,8 @@ class PyFastfold(PythonPackage): version("0.2.0", sha256="6760dbae9809b8b26219c9477489d34325807be504098901d0375fbdc3103f88") + depends_on("cxx", type="build") # generated + # From README: depends_on("python@3.8:", type=("build", "run")) # Req Relaxed (was @3.8:3.9) depends_on("cuda@11.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-fastpath/package.py b/var/spack/repos/builtin/packages/py-fastpath/package.py index a94b8d545fbc9c..44d97624d41e0c 100644 --- a/var/spack/repos/builtin/packages/py-fastpath/package.py +++ b/var/spack/repos/builtin/packages/py-fastpath/package.py @@ -19,5 +19,7 @@ class PyFastpath(PythonPackage): version("1.9", sha256="3372d306a3c4e4e764b3995946132333726a229e9002879b9112779dd442b31a") + depends_on("c", type="build") # generated + depends_on("python@3.5.3:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-fastremap/package.py b/var/spack/repos/builtin/packages/py-fastremap/package.py index 71103a1375531d..4e3d1bb68344b4 100644 --- a/var/spack/repos/builtin/packages/py-fastremap/package.py +++ b/var/spack/repos/builtin/packages/py-fastremap/package.py @@ -17,6 +17,8 @@ class PyFastremap(PythonPackage): version("1.14.1", sha256="067d42d6cb3b1b0789889efd1d7fae58006c82ada4a8446d40e9e838b358ee7c") + depends_on("cxx", type="build") # generated + depends_on("python@3.7:3", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-fastrlock/package.py b/var/spack/repos/builtin/packages/py-fastrlock/package.py index e45bc5f3a75cbd..02081e1d506805 100644 --- a/var/spack/repos/builtin/packages/py-fastrlock/package.py +++ b/var/spack/repos/builtin/packages/py-fastrlock/package.py @@ -18,6 +18,8 @@ class PyFastrlock(PythonPackage): version("0.8.1", sha256="8a5f2f00021c4ac72e4dab910dc1863c0e008a2e7fb5c843933ae9bcfc3d0802") version("0.5", sha256="9ae1a31f6e069b5f0f28ba63c594d0c952065de0a375f7b491d21ebaccc5166f") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") # in newer pip versions --install-option does not exist diff --git a/var/spack/repos/builtin/packages/py-faststructure/package.py b/var/spack/repos/builtin/packages/py-faststructure/package.py index 256dc429cbf171..b9b90c490ad036 100644 --- a/var/spack/repos/builtin/packages/py-faststructure/package.py +++ b/var/spack/repos/builtin/packages/py-faststructure/package.py @@ -17,6 +17,8 @@ class PyFaststructure(PythonPackage): version("1.0", sha256="f1bfb24bb5ecd108bc3a90145fad232012165c1e60608003f1c87d200f867b81") + depends_on("c", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-fenics-basix/package.py b/var/spack/repos/builtin/packages/py-fenics-basix/package.py index 8dccdf2b071f5e..02f42c149a8076 100644 --- a/var/spack/repos/builtin/packages/py-fenics-basix/package.py +++ b/var/spack/repos/builtin/packages/py-fenics-basix/package.py @@ -17,37 +17,28 @@ class PyFenicsBasix(PythonPackage): license("MIT") version("main", branch="main") + version("0.8.0", sha256="b299af82daf8fa3e4845e17f202491fe71b313bf6ab64c767a5287190b3dd7fe") version("0.7.0", sha256="9bee81b396ee452eec8d9735f278cb44cb6994c6bc30aec8ed9bb4b12d83fa7f") version("0.6.0", sha256="687ae53153c98facac4080dcdc7081701db1dcea8c5e7ae3feb72aec17f83304") - version( - "0.5.1", - sha256="69133476ac35f0bd0deccb480676030378c341d7dfb2adaca22cd16b7e1dc1cb", - deprecated=True, - ) - version( - "0.4.2", - sha256="a54f5e442b7cbf3dbb6319c682f9161272557bd7f42e2b8b8ccef88bc1b7a22f", - deprecated=True, - ) + + depends_on("cxx", type="build") # generated depends_on("fenics-basix@main", type=("build", "run"), when="@main") + depends_on("fenics-basix@0.8.0", type=("build", "run"), when="@0.8.0") depends_on("fenics-basix@0.7.0", type=("build", "run"), when="@0.7.0") depends_on("fenics-basix@0.6.0", type=("build", "run"), when="@0.6.0") - depends_on("fenics-basix@0.5.1", type=("build", "run"), when="@0.5.1") - depends_on("fenics-basix@0.4.2", type=("build", "run"), when="@0.4.2") # See python/CMakeLists.txt - depends_on("cmake@3.16:", when="@:0.7", type="build") depends_on("cmake@3.19:", when="@0.8:", type="build") + depends_on("cmake@3.16:", when="@:0.7", type="build") # See python/pyproject.toml - depends_on("python@3.8:", when="@0.7:", type=("build", "run")) + depends_on("python@3.9:", when="@0.8:", type=("build", "run")) + depends_on("python@3.8:", when="@:0.7", type=("build", "run")) depends_on("py-numpy@1.21:", type=("build", "run")) depends_on("py-pybind11@2.9.1:", when="@:0.7", type="build") depends_on("py-setuptools@42:", when="@:0.7", type="build") depends_on("py-nanobind@1.6.0:", when="@0.8:", type="build") depends_on("py-scikit-build-core+pyproject@0.5.0:", when="@0.8:", type="build") - depends_on("xtensor@0.23.10:", type="build", when="@:0.4") - build_directory = "python" diff --git a/var/spack/repos/builtin/packages/py-fenics-dolfinx/package.py b/var/spack/repos/builtin/packages/py-fenics-dolfinx/package.py index a3a658fc3cffd4..97ce274173cd5d 100644 --- a/var/spack/repos/builtin/packages/py-fenics-dolfinx/package.py +++ b/var/spack/repos/builtin/packages/py-fenics-dolfinx/package.py @@ -18,68 +18,53 @@ class PyFenicsDolfinx(PythonPackage): license("LGPL-3.0-only") version("main", branch="main") + version("0.8.0", sha256="acf3104d9ecc0380677a6faf69eabfafc58d0cce43f7777e1307b95701c7cad9") version("0.7.2", sha256="7d9ce1338ce66580593b376327f23ac464a4ce89ef63c105efc1a38e5eae5c0b") version("0.6.0", sha256="eb8ac2bb2f032b0d393977993e1ab6b4101a84d54023a67206e3eac1a8d79b80") - version( - "0.5.1", - sha256="a570e3f6ed8e7c570e7e61d0e6fd44fa9dad2c5f8f1f48a6dc9ad22bacfbc973", - deprecated=True, - ) - version( - "0.5.0", - sha256="503c70c01a44d1ffe48e052ca987693a49f8d201877652cabbe2a44eb3b7c040", - deprecated=True, - ) - version( - "0.4.1", - sha256="68dcf29a26c750fcea5e02d8d58411e3b054313c3bf6fcbc1d0f08dd2851117f", - deprecated=True, - ) + + depends_on("cxx", type="build") # generated depends_on("cmake@3.19:", type="build") depends_on("hdf5", type="build") depends_on("pkgconfig", type="build") - depends_on("python@3.8:", when="@0.6.1:", type=("build", "run")) - depends_on("python@3.8:3.10", when="@0.5:0.6.0", type=("build", "run")) - depends_on("python@3.7:3.10", when="@0.4", type=("build", "run")) + depends_on("python@3.9:", when="@0.8:", type=("build", "run")) + depends_on("python@3.8:", when="@0.7", type=("build", "run")) + depends_on("python@3.8:3.10", when="@0.6.0", type=("build", "run")) depends_on("fenics-dolfinx@main", when="@main") + depends_on("fenics-dolfinx@0.8.0", when="@0.8.0") depends_on("fenics-dolfinx@0.7.2", when="@0.7.2") depends_on("fenics-dolfinx@0.6.0", when="@0.6.0") - depends_on("fenics-dolfinx@0.5.1", when="@0.5.1") - depends_on("fenics-dolfinx@0.5.0", when="@0.5.0") - depends_on("fenics-dolfinx@0.4.1", when="@0.4.1") depends_on("py-fenics-basix@main", type=("build", "run"), when="@main") + depends_on("py-fenics-basix@0.8", type=("build", "link"), when="@0.8") + depends_on("fenics-basix@main", type=("build", "link"), when="@main") + depends_on("fenics-basix@0.8", type=("build", "link"), when="@0.8") depends_on("fenics-basix@0.7", type=("build", "link"), when="@0.7") - depends_on("fenics-basix@0.6.0:0.6", type=("build", "link"), when="@0.6.0:0.6") - depends_on("fenics-basix@0.5.1:0.5", type=("build", "link"), when="@0.5.0:0.5") - depends_on("fenics-basix@0.4.2", type=("build", "link"), when="@0.4.1") + depends_on("fenics-basix@0.6", type=("build", "link"), when="@0.6") depends_on("py-fenics-ffcx@main", type=("build", "run"), when="@main") + depends_on("py-fenics-ffcx@0.8", type=("build", "run"), when="@0.8") depends_on("py-fenics-ffcx@0.7", type=("build", "run"), when="@0.7") depends_on("py-fenics-ffcx@0.6", type=("build", "run"), when="@0.6") - depends_on("py-fenics-ffcx@0.5.0.post0", type=("build", "run"), when="@0.5.0:0.5") - depends_on("py-fenics-ffcx@0.4.2", type=("build", "run"), when="@0.4.1") depends_on("py-fenics-ufl@main", type=("build", "run"), when="@main") + depends_on("py-fenics-ufl@2024.1", type=("build", "run"), when="@0.8") depends_on("py-fenics-ufl@2023.2", type=("build", "run"), when="@0.7") depends_on("py-fenics-ufl@2023.1", type=("build", "run"), when="@0.6") - depends_on("py-fenics-ufl@2022.2.0", type=("build", "run"), when="@0.5.0:0.5") - depends_on("py-fenics-ufl@2022.1.0", type=("build", "run"), when="@0.4.1") depends_on("py-numpy@1.21:", type=("build", "run")) depends_on("py-mpi4py", type=("build", "run")) depends_on("py-petsc4py", type=("build", "run")) depends_on("py-cffi", type=("build", "run")) - depends_on("py-nanobind@1.8:", when="@0.8:", type="build") + depends_on("py-nanobind@2:", when="@0.9:", type="build") + depends_on("py-nanobind@1.8:1.9", when="@0.8", type="build") depends_on("py-scikit-build-core+pyproject@0.5:", when="@0.8:", type="build") depends_on("py-pybind11@2.7.0:", when="@:0.7", type=("build", "run")) depends_on("py-setuptools@42:", when="@:0.7", type="build") - depends_on("xtensor@0.23.10:", type="build", when="@:0.5") build_directory = "python" diff --git a/var/spack/repos/builtin/packages/py-fenics-ffc/package.py b/var/spack/repos/builtin/packages/py-fenics-ffc/package.py index b5ddb2755808a0..f77114e9e2aa49 100644 --- a/var/spack/repos/builtin/packages/py-fenics-ffc/package.py +++ b/var/spack/repos/builtin/packages/py-fenics-ffc/package.py @@ -28,6 +28,8 @@ class PyFenicsFfc(PythonPackage): ) version("2016.2.0", sha256="097c284780447ea7bb47d4d51956648a1efb2cb9047eb1382944421dde351ecb") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-fenics-ffcx/package.py b/var/spack/repos/builtin/packages/py-fenics-ffcx/package.py index 37017ad6c82504..00b7e04962283e 100644 --- a/var/spack/repos/builtin/packages/py-fenics-ffcx/package.py +++ b/var/spack/repos/builtin/packages/py-fenics-ffcx/package.py @@ -17,23 +17,15 @@ class PyFenicsFfcx(PythonPackage): license("LGPL-3.0-or-later") version("main", branch="main") + version("0.8.0", sha256="8a854782dbd119ec1c23c4522a2134d5281e7f1bd2f37d64489f75da055282e3") version("0.7.0", sha256="7f3c3ca91d63ce7831d37799cc19d0551bdcd275bdfa4c099711679533dd1c71") version("0.6.0", sha256="076fad61d406afffd41019ae1abf6da3f76406c035c772abad2156127667980e") - version( - "0.5.0.post0", - sha256="039908c9998b51ba53e5deb3a97016062c262f0a4285218644304f7d3cd35882", - deprecated=True, - ) - version( - "0.4.2", - sha256="3be6eef064d6ef907245db5b6cc15d4e603762e68b76e53e099935ca91ef1ee4", - deprecated=True, - ) - depends_on("python@3.8:", when="@0.7:", type=("build", "run")) + depends_on("python@3.9:", when="@0.8:", type=("build", "run")) + depends_on("python@3.8:", when="@:0.7", type=("build", "run")) depends_on("py-setuptools@62:", when="@0.7:", type="build") # Runtime dependency on pkg_resources from setuptools at 0.6.0 - depends_on("py-setuptools@58:", when="@0.4.2:0.6", type=("build", "run")) + depends_on("py-setuptools@58:", when="@:0.6", type=("build", "run")) # CFFI is required at runtime for JIT support depends_on("py-cffi", type=("build", "run")) @@ -42,17 +34,14 @@ class PyFenicsFfcx(PythonPackage): depends_on("py-numpy@1.21:", type=("build", "run")) depends_on("py-fenics-ufl@main", type=("build", "run"), when="@main") - depends_on("py-fenics-ufl@2023.3.0:", type=("build", "run"), when="@0.8") + depends_on("py-fenics-ufl@2024.1.0:", type=("build", "run"), when="@0.8") depends_on("py-fenics-ufl@2023.2.0", type=("build", "run"), when="@0.7") depends_on("py-fenics-ufl@2023.1", type=("build", "run"), when="@0.6") - depends_on("py-fenics-ufl@2022.2.0", type=("build", "run"), when="@0.5.0:0.5") - depends_on("py-fenics-ufl@2022.1.0", type=("build", "run"), when="@0.4.2") depends_on("py-fenics-basix@main", type=("build", "run"), when="@main") + depends_on("py-fenics-basix@0.8", type=("build", "run"), when="@0.8") depends_on("py-fenics-basix@0.7", type=("build", "run"), when="@0.7") - depends_on("py-fenics-basix@0.6.0:0.6", type=("build", "run"), when="@0.6.0:0.6") - depends_on("py-fenics-basix@0.5.1:0.5", type=("build", "run"), when="@0.5.0:0.5") - depends_on("py-fenics-basix@0.4.2", type=("build", "run"), when="@0.4.2") + depends_on("py-fenics-basix@0.6", type=("build", "run"), when="@0.6") depends_on("py-pytest@6:", type="test") depends_on("py-sympy", type="test") diff --git a/var/spack/repos/builtin/packages/py-fenics-ufl/package.py b/var/spack/repos/builtin/packages/py-fenics-ufl/package.py index 252e87af122044..b4e8cfe937dae6 100644 --- a/var/spack/repos/builtin/packages/py-fenics-ufl/package.py +++ b/var/spack/repos/builtin/packages/py-fenics-ufl/package.py @@ -21,6 +21,9 @@ class PyFenicsUfl(PythonPackage): license("LGPL-3.0-or-later") version("main", branch="main") + version( + "2024.1.0.post1", sha256="6e38e93a2c8417271c9fb316e0d0ea5fe1101c6a37b2496fff8290e7ea7ead74" + ) version("2023.2.0", sha256="d1d3209e8ebd4bd70513c26890f51823bac90edc956233c47bd8e686e064436e") version( "2023.1.1.post0", sha256="9e6e87f1447635029cec42604f62a76bba84899beb4b8822af10389d1f93a9b6" diff --git a/var/spack/repos/builtin/packages/py-flash-attn/package.py b/var/spack/repos/builtin/packages/py-flash-attn/package.py new file mode 100644 index 00000000000000..692f5f71de1c61 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-flash-attn/package.py @@ -0,0 +1,50 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyFlashAttn(PythonPackage): + """ + This package provides the official implementation of FlashAttention. + """ + + homepage = "https://github.com/Dao-AILab/flash-attention.git" + pypi = "flash-attn/flash_attn-0.0.0.tar.gz" + git = "https://github.com/Dao-AILab/flash-attention.git" + + maintainers("aurianer") + + license("BSD") + + version("main", branch="main") + version( + "2.5.9.post1", sha256="a92db1683a5b141a0f4371d251ae9f73e9aef629b3a58a50d0ef430266c68782" + ) + version("2.5.8", sha256="2e5b2bcff6d5cff40d494af91ecd1eb3c5b4520a6ce7a0a8b1f9c1ed129fb402") + version("2.5.7", sha256="7c079aef4e77c4e9a71a3cd88662362e0fe82f658db0b2dbff6f279de2a387a8") + version("2.5.6", sha256="d25801aa060877cad997939bd7130faf620fdbeda947c3ffde5865906d430c36") + version("2.5.5", sha256="751cee17711d006fe7341cdd78584af86a6239afcfe43b9ed11c84db93126267") + version("2.5.4", sha256="d83bb427b517b07e9db655f6e5166eb2607dccf4d6ca3229e3a3528c206b0175") + version("2.4.2", sha256="eb822a8c4219b610e9d734cbc8cd9ee4547f27433815a2b90dc1462766feefc1") + + depends_on("cxx", type="build") # generated + + with default_args(type="build"): + depends_on("py-ninja") + depends_on("py-packaging") + depends_on("py-psutil") + depends_on("py-setuptools") + + with default_args(type=("build", "run")): + depends_on("py-torch+cuda") + depends_on("ninja") + depends_on("py-einops") + depends_on("py-packaging") + + with default_args(type=("build", "link", "run")): + depends_on("py-pybind11") + + depends_on("python@3.7:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-flatbuffers/package.py b/var/spack/repos/builtin/packages/py-flatbuffers/package.py index d91f04e672a9de..3b2d6249bd05a1 100644 --- a/var/spack/repos/builtin/packages/py-flatbuffers/package.py +++ b/var/spack/repos/builtin/packages/py-flatbuffers/package.py @@ -20,6 +20,7 @@ class PyFlatbuffers(PythonPackage): license("Apache-2.0") + version("24.3.25", sha256="de2ec5b203f21441716617f38443e0a8ebf3d25bf0d9c0bb0ce68fa00ad546a4") version("23.5.26", sha256="9ea1144cac05ce5d86e2859f431c6cd5e66cd9c78c558317c7955fb8d4c78d89") version("2.0.7", sha256="0ae7d69c5b82bf41962ca5fde9cc43033bc9501311d975fd5a25e8a7d29c1245") version("2.0", sha256="12158ab0272375eab8db2d663ae97370c33f152b27801fa6024e1d6105fd4dd2") diff --git a/var/spack/repos/builtin/packages/py-flawfinder/package.py b/var/spack/repos/builtin/packages/py-flawfinder/package.py index 56a6a80e3cb02b..1d4d0d768b1317 100644 --- a/var/spack/repos/builtin/packages/py-flawfinder/package.py +++ b/var/spack/repos/builtin/packages/py-flawfinder/package.py @@ -16,5 +16,8 @@ class PyFlawfinder(PythonPackage, SourceforgePackage): version("2.0.19", sha256="fe550981d370abfa0a29671346cc0b038229a9bd90b239eab0f01f12212df618") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@2.7:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-flye/package.py b/var/spack/repos/builtin/packages/py-flye/package.py index 8ec6ca4c9f46ff..83529bae78c6d2 100644 --- a/var/spack/repos/builtin/packages/py-flye/package.py +++ b/var/spack/repos/builtin/packages/py-flye/package.py @@ -23,6 +23,9 @@ class PyFlye(PythonPackage): version("2.7.1", sha256="0e826261c81537a7fa8fd37dc583edd75535eee0f30429d6bdb55f37b5722dbb") version("2.6", sha256="5bdc44b84712794fa4264eed690d8c65c0d72f495c7bbf2cd15b634254809131") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # https://github.com/fenderglass/Flye/blob/flye/docs/INSTALL.md depends_on("python@2.7:2.8,3.5:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-folium/package.py b/var/spack/repos/builtin/packages/py-folium/package.py new file mode 100644 index 00000000000000..0b8eab4b87e718 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-folium/package.py @@ -0,0 +1,25 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyFolium(PythonPackage): + """Make beautiful maps with Leaflet.js & Python.""" + + homepage = "https://python-visualization.github.io/folium" + pypi = "folium/folium-0.16.0.tar.gz" + + license("MIT") + + version("0.16.0", sha256="2585ee9253dc758d3a365534caa6fb5fa0c244646db4dc5819afc67bbd4daabb") + + depends_on("py-setuptools@41.2:", type="build") + depends_on("py-setuptools-scm", type="build") + depends_on("py-branca@0.6.0:", type=("build", "run")) + depends_on("py-jinja2@2.9:", type=("build", "run")) + depends_on("py-numpy", type=("build", "run")) + depends_on("py-requests", type=("build", "run")) + depends_on("py-xyzservices", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-ford/package.py b/var/spack/repos/builtin/packages/py-ford/package.py index 0bab66112a3636..43455c69cf860b 100644 --- a/var/spack/repos/builtin/packages/py-ford/package.py +++ b/var/spack/repos/builtin/packages/py-ford/package.py @@ -20,6 +20,8 @@ class PyFord(PythonPackage): version("6.1.12", sha256="101191e1aa33cfe780ea5b2d66d02c7281b9b314e82bb138d76809a49c08506a") version("6.1.11", sha256="feb9a88040e717e84c632e4b023904ab36a463fc9a8ff80c8c7f86454e5d8043") + depends_on("fortran", type="build") # generated + depends_on("py-wheel@0.29:", type="build") depends_on("py-setuptools@48:", type="build") diff --git a/var/spack/repos/builtin/packages/py-fortls/package.py b/var/spack/repos/builtin/packages/py-fortls/package.py index 47e9aafed33af3..ccb5133bfb4bdd 100644 --- a/var/spack/repos/builtin/packages/py-fortls/package.py +++ b/var/spack/repos/builtin/packages/py-fortls/package.py @@ -16,12 +16,17 @@ class PyFortls(PythonPackage): license("MIT") + version("3.1.0", sha256="e38f9f6af548f78151d54bdbb9884166f8d717f8e147ab1e2dbf06b985df2c6d") version("2.13.0", sha256="23c5013e8dd8e1d65bf07be610d0827bc48aa7331a7a7ce13612d4c646d0db31") + depends_on("fortran", type="build") # generated + depends_on("py-setuptools@45:", type="build") + depends_on("py-setuptools@61:", when="@3:", type="build") depends_on("py-packaging", type=("build", "run")) depends_on("py-setuptools-scm@6.2:+toml", type="build") - depends_on("py-setuptools-scm-git-archive", type="build") + depends_on("py-setuptools-scm@7:+toml", when="@3:", type="build") + depends_on("py-setuptools-scm-git-archive", when="@:2", type="build") depends_on("py-json5", type=("build", "run")) depends_on("py-importlib-metadata", type=("build", "run"), when="^python@:3.7") diff --git a/var/spack/repos/builtin/packages/py-fortran-language-server/package.py b/var/spack/repos/builtin/packages/py-fortran-language-server/package.py index 7187cea8db8258..3e872f85abcad4 100644 --- a/var/spack/repos/builtin/packages/py-fortran-language-server/package.py +++ b/var/spack/repos/builtin/packages/py-fortran-language-server/package.py @@ -20,5 +20,7 @@ class PyFortranLanguageServer(PythonPackage): version("1.12.0", sha256="5cda6341b1d2365cce3d80ba40043346c5dcbd0b35f636bfa57cb34df789ff17") version("1.11.1", sha256="8f03782dd992d6652a3f2d349115fdad3aa3464fee3fafbbc4f8ecf780166e3c") + depends_on("fortran", type="build") # generated + depends_on("python@2.7:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-fparser/package.py b/var/spack/repos/builtin/packages/py-fparser/package.py index 7ac6bca213b987..c211c83a5bb83c 100644 --- a/var/spack/repos/builtin/packages/py-fparser/package.py +++ b/var/spack/repos/builtin/packages/py-fparser/package.py @@ -35,6 +35,8 @@ class PyFparser(PythonPackage): version("0.0.6", sha256="bf8a419cb528df1bfc24ddd26d63f2ebea6f1e103f1a259d8d3a6c9b1cd53012") version("0.0.5", sha256="f3b5b0ac56fd22abed558c0fb0ba4f28edb8de7ef24cfda8ca8996562215822f") + depends_on("fortran", type="build") # generated + # Dependencies for latest version depends_on("py-setuptools@61:", type="build", when="@0.1.4:") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-frozendict/package.py b/var/spack/repos/builtin/packages/py-frozendict/package.py index d526db84acb68b..0083d1b9b64b25 100644 --- a/var/spack/repos/builtin/packages/py-frozendict/package.py +++ b/var/spack/repos/builtin/packages/py-frozendict/package.py @@ -18,6 +18,8 @@ class PyFrozendict(PythonPackage): version("2.3.4", sha256="15b4b18346259392b0d27598f240e9390fafbff882137a9c48a1e0104fb17f78") version("1.2", sha256="774179f22db2ef8a106e9c38d4d1f8503864603db08de2e33be5b778230f6e45") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-frozenlist/package.py b/var/spack/repos/builtin/packages/py-frozenlist/package.py index 619c8981fb911f..b98a509c7043ed 100644 --- a/var/spack/repos/builtin/packages/py-frozenlist/package.py +++ b/var/spack/repos/builtin/packages/py-frozenlist/package.py @@ -19,6 +19,8 @@ class PyFrozenlist(PythonPackage): version("1.3.0", sha256="ce6f2ba0edb7b0c1d8976565298ad2deba6f8064d2bebb6ffce2ca896eb35b0b") version("1.2.0", sha256="68201be60ac56aff972dc18085800b6ee07973c49103a8aba669dee3d71079de") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("python@3.7:", when="@1.3.1:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-fsspec/package.py b/var/spack/repos/builtin/packages/py-fsspec/package.py index 0b46a7c951c71b..1e5bc5bad39821 100644 --- a/var/spack/repos/builtin/packages/py-fsspec/package.py +++ b/var/spack/repos/builtin/packages/py-fsspec/package.py @@ -17,6 +17,8 @@ class PyFsspec(PythonPackage): # Requires pytest skip_modules = ["fsspec.tests"] + version("2024.5.0", sha256="1d021b0b0f933e3b3029ed808eb400c08ba101ca2de4b3483fbc9ca23fcee94a") + version("2024.3.1", sha256="f39780e282d7d117ffb42bb96992f8a90795e4d0fb0f661a70ca39fe9c43ded9") version("2024.2.0", sha256="b6ad1a679f760dda52b1168c859d01b7b80648ea6f7f7c7f5a8a91dc3f3ecb84") version("2023.10.0", sha256="330c66757591df346ad3091a53bd907e15348c2ba17d63fd54f5c39c4457d2a5") version("2023.1.0", sha256="fbae7f20ff801eb5f7d0bedf81f25c787c0dfac5e982d98fa3884a9cde2b5411") @@ -30,6 +32,8 @@ class PyFsspec(PythonPackage): variant("http", default=False, description="HTTPFileSystem support", when="@0.8.1:") - depends_on("py-setuptools", type="build") + depends_on("py-setuptools", type="build", when="@:2024.4") + depends_on("py-hatchling", type="build", when="@2024.5:") + depends_on("py-hatch-vcs", type="build", when="@2024.5:") depends_on("py-requests", type=("build", "run"), when="@:2023+http") depends_on("py-aiohttp", type=("build", "run"), when="+http") diff --git a/var/spack/repos/builtin/packages/py-gdown/package.py b/var/spack/repos/builtin/packages/py-gdown/package.py new file mode 100644 index 00000000000000..4c7e0cef988c49 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-gdown/package.py @@ -0,0 +1,28 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyGdown(PythonPackage): + """Google Drive Public File/Folder Downloader.""" + + homepage = "https://github.com/wkentaro/gdown" + pypi = "gdown/gdown-5.2.0.tar.gz" + + license("MIT") + + version("5.2.0", sha256="2145165062d85520a3cd98b356c9ed522c5e7984d408535409fd46f94defc787") + + with default_args(type="build"): + depends_on("py-hatchling@1.20:") + depends_on("py-hatch-vcs") + depends_on("py-hatch-fancy-pypi-readme") + + with default_args(type=("build", "run")): + depends_on("py-filelock") + depends_on("py-requests+socks") + depends_on("py-tqdm") + depends_on("py-beautifulsoup4") diff --git a/var/spack/repos/builtin/packages/py-genders/package.py b/var/spack/repos/builtin/packages/py-genders/package.py index b548d374b1700c..dbaf2d715b4f7d 100644 --- a/var/spack/repos/builtin/packages/py-genders/package.py +++ b/var/spack/repos/builtin/packages/py-genders/package.py @@ -21,6 +21,9 @@ class PyGenders(Package): sha256="0ff292825a29201106239c4d47d9ce4c6bda3f51c78c0463eb2634ecc337b774", url="https://github.com/chaos/genders/releases/download/genders-1-22-1/genders-1.22.tar.gz", ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated extends("python") # FIXME: Missing a dependency on genders diff --git a/var/spack/repos/builtin/packages/py-genshi/package.py b/var/spack/repos/builtin/packages/py-genshi/package.py index 66c8de0fd05816..fba512eca04e0c 100644 --- a/var/spack/repos/builtin/packages/py-genshi/package.py +++ b/var/spack/repos/builtin/packages/py-genshi/package.py @@ -15,6 +15,8 @@ class PyGenshi(PythonPackage): version("0.7.7", sha256="c100520862cd69085d10ee1a87e91289e7f59f6b3d9bd622bf58b2804e6b9aab") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type=("build", "run")) depends_on("py-six", type=("build", "run", "test")) diff --git a/var/spack/repos/builtin/packages/py-gensim/package.py b/var/spack/repos/builtin/packages/py-gensim/package.py index c5ac143f0e59bc..c4d412425712f0 100644 --- a/var/spack/repos/builtin/packages/py-gensim/package.py +++ b/var/spack/repos/builtin/packages/py-gensim/package.py @@ -23,6 +23,9 @@ class PyGensim(PythonPackage): version("3.8.1", sha256="33277fc0a8d7b0c7ce70fcc74bb82ad39f944c009b334856c6e86bf552b1dfdc") version("3.8.0", sha256="ec5de7ff2bfa8692fa96a846bb5aae52f267fc322fbbe303c1f042d258af5766") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@2.7:2.8,3.5:", type=("build", "run")) depends_on("python@3.8:", type=("build", "run"), when="@4.3.1:") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-geopmdpy/package.py b/var/spack/repos/builtin/packages/py-geopmdpy/package.py new file mode 100644 index 00000000000000..a67981826d4fa7 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-geopmdpy/package.py @@ -0,0 +1,54 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyGeopmdpy(PythonPackage): + """The Global Extensible Open Power Manager (GEOPM) Service provides a + user interface for accessing hardware telemetry and settings securely.""" + + homepage = "https://geopm.github.io" + git = "https://github.com/geopm/geopm.git" + url = "https://github.com/geopm/geopm/tarball/v3.1.0" + + maintainers("bgeltz", "cmcantalupo") + license("BSD-3-Clause") + tags = ["e4s"] + + version("develop", branch="dev", get_full_repo=True) + version("3.1.0", sha256="2d890cad906fd2008dc57f4e06537695d4a027e1dc1ed92feed4d81bb1a1449e") + version("3.0.1", sha256="32ba1948de58815ee055470dcdea64593d1113a6cad70ce00ab0286c127f8234") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + depends_on("py-dasbus@1.6.0:", type=("build", "run")) + depends_on("py-cffi@1.14.5:", type="run") + depends_on("py-psutil@5.8.0:", type="run") + depends_on("py-jsonschema@3.2.0:", type="run") + depends_on("py-pyyaml@6.0:", type="run") + depends_on("py-setuptools@53.0.0:", type="build") + depends_on("py-setuptools-scm@7.0.3:", when="@3.1:", type="build") + depends_on("py-build@0.9.0:", when="@3.1:", type="build") + + @property + def build_directory(self): + if self.version == Version("3.0.1"): + return "service" + else: + return "geopmdpy" + + def setup_build_environment(self, env): + if not self.spec.version.isdevelop(): + env.set("SETUPTOOLS_SCM_PRETEND_VERSION", self.version) + + @run_before("install") + def populate_version(self): + if self.version == Version("3.0.1"): + with working_dir(join_path(self.build_directory, "geopmdpy")): + with open("version.py", "w") as fd: + fd.write(f"__version__ = '{self.spec.version}'") diff --git a/var/spack/repos/builtin/packages/py-geopmpy/package.py b/var/spack/repos/builtin/packages/py-geopmpy/package.py new file mode 100644 index 00000000000000..7a7e13f7343b18 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-geopmpy/package.py @@ -0,0 +1,41 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyGeopmpy(PythonPackage): + """The Global Extensible Open Power Manager (GEOPM) Service provides a + user interface for accessing hardware telemetry and settings securely.""" + + homepage = "https://geopm.github.io" + git = "https://github.com/geopm/geopm.git" + url = "https://github.com/geopm/geopm/tarball/v3.1.0" + + maintainers("bgeltz", "cmcantalupo") + license("BSD-3-Clause") + tags = ["e4s"] + + version("develop", branch="dev", get_full_repo=True) + version("3.1.0", sha256="2d890cad906fd2008dc57f4e06537695d4a027e1dc1ed92feed4d81bb1a1449e") + + depends_on("python@3.6:3", type=("build", "run")) + depends_on("py-setuptools@53.0.0:", type="build") + depends_on("py-setuptools-scm@7.0.3:", when="@3.1:", type="build") + depends_on("py-build@0.9.0:", when="@3.1:", type="build") + depends_on("py-cffi@1.14.5:", type="run") + depends_on("py-natsort@8.2.0:", type="run") + depends_on("py-numpy@1.19.5:", type="run") + depends_on("py-pandas@1.1.5:", type="run") + depends_on("py-tables@3.7.0:", type="run") + depends_on("py-psutil@5.8.0:", type="run") + depends_on("py-pyyaml@6.0:", type="run") + depends_on("py-docutils@0.18:", type="run") + + build_directory = "geopmpy" + + def setup_build_environment(self, env): + if not self.spec.version.isdevelop(): + env.set("SETUPTOOLS_SCM_PRETEND_VERSION", self.version) diff --git a/var/spack/repos/builtin/packages/py-gevent/package.py b/var/spack/repos/builtin/packages/py-gevent/package.py index 85b6d5ff209303..fb42471f8a108a 100644 --- a/var/spack/repos/builtin/packages/py-gevent/package.py +++ b/var/spack/repos/builtin/packages/py-gevent/package.py @@ -20,6 +20,8 @@ class PyGevent(PythonPackage): version("21.8.0", sha256="43e93e1a4738c922a2416baf33f0afb0a20b22d3dba886720bc037cd02a98575") version("1.5.0", sha256="b2814258e3b3fb32786bb73af271ad31f51e1ac01f33b37426b66cb8491b4c29") + depends_on("c", type="build") # generated + depends_on("python@3.8:", when="@23.7.0:", type=("build", "run")) depends_on("python@:3.10", when="@:21.12", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-gimmik/package.py b/var/spack/repos/builtin/packages/py-gimmik/package.py index 2d14aca41e3640..4c9617994d7d1b 100644 --- a/var/spack/repos/builtin/packages/py-gimmik/package.py +++ b/var/spack/repos/builtin/packages/py-gimmik/package.py @@ -19,6 +19,7 @@ class PyGimmik(PythonPackage): license("BSD-3-Clause") + version("3.2.1", sha256="048644bd71497eb07e144f2c22fdee49ba23e1cde5fb954c3c30c4e3ea23687a") version("3.0", sha256="45c2da7acff3201b7796ba731e4be7f3b4f39469ff1f1bc0ddf4f19c4a6af010") version("2.3", sha256="c019c85316bcf0d5e84de9b7d10127355dfe8037c0e37f1880a9819ce92b74e1") version("2.2", sha256="9144640f94aab92f9c5dfcaf16885a79428ab97337cf503a4b2dddeb870f3cf0") diff --git a/var/spack/repos/builtin/packages/py-glmnet-python/package.py b/var/spack/repos/builtin/packages/py-glmnet-python/package.py new file mode 100644 index 00000000000000..8b6e5cbfe59146 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-glmnet-python/package.py @@ -0,0 +1,29 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class PyGlmnetPython(PythonPackage): + """This is a python version of the popular glmnet library (beta release). + Glmnet fits the entire lasso or elastic-net regularization path for linear + regression, logistic and multinomial regression models, poisson regression + and the cox model.""" + + # Not to be confused with py-glmnet + + homepage = "https://github.com/johnlees/glmnet_python/" + # Not availible on PyPI. Note that this is a fork of + # https://github.com/bbalasub1/glmnet_python, as required for py-pyseer + url = "https://github.com/johnlees/glmnet_python/archive/v1.0.2.zip" + + version("1.0.2", sha256="cc80020dcebc5366dcc061aec59318efac69d23578066326d925bfc27a23cb27") + + depends_on("py-setuptools", type="build") + depends_on("py-joblib@0.10.3:", type=("build", "run")) + # Not in setup.py, but imported and used: + depends_on("py-numpy", type=("build", "run")) + depends_on("py-scipy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-glmnet/package.py b/var/spack/repos/builtin/packages/py-glmnet/package.py index f4f11ce6112eb1..ed41241b827eea 100644 --- a/var/spack/repos/builtin/packages/py-glmnet/package.py +++ b/var/spack/repos/builtin/packages/py-glmnet/package.py @@ -19,6 +19,8 @@ class PyGlmnet(PythonPackage): version("2.2.1", sha256="3222bca2e901b3f60c2dc22df7aeba6bb9c7b6451b44cbbe1b91084b66f14481") + depends_on("fortran", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type=("build")) diff --git a/var/spack/repos/builtin/packages/py-globus-cli/package.py b/var/spack/repos/builtin/packages/py-globus-cli/package.py new file mode 100644 index 00000000000000..c945eddabaaba9 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-globus-cli/package.py @@ -0,0 +1,28 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class PyGlobusCli(PythonPackage): + """Globus CLI is a standalone application that can be installed on the user's machine + and is used to access the Globus service. The CLI provides an interface to Globus + services from the shell, and is suited to both interactive and simple scripting use cases.""" + + homepage = "https://docs.globus.org/cli" + git = "https://github.com/globus/globus-cli.git" + url = "https://github.com/globus/globus-cli/archive/refs/tags/3.16.0.zip" + + maintainers("climbfuji") + + version("3.16.0", sha256="0ef721060870d9346505e52b9bf30c7bed6ae136cc08762deb2f8893bd25d8c5") + + depends_on("python@3.7:", type=("build", "run")) + depends_on("py-setuptools", type="build") + depends_on("py-globus-sdk@3.25.0", type=("build", "run")) + depends_on("py-click@8", type=("build", "run")) + depends_on("py-jmespath@1.0.1", type=("build", "run")) + depends_on("py-packaging@17:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-globus-sdk/package.py b/var/spack/repos/builtin/packages/py-globus-sdk/package.py index 63479391f8e0c6..33458b22d81bb5 100644 --- a/var/spack/repos/builtin/packages/py-globus-sdk/package.py +++ b/var/spack/repos/builtin/packages/py-globus-sdk/package.py @@ -15,10 +15,11 @@ class PyGlobusSdk(PythonPackage): homepage = "https://github.com/globus/globus-sdk-python" pypi = "globus-sdk/globus-sdk-3.0.2.tar.gz" - maintainers("hategan") + maintainers("hategan", "climbfuji") license("Apache-2.0") + version("3.25.0", sha256="d9be275d4ec18054db04732f75649c4227800c79b31fbcfb3f4f31eccfa5f4f7") version("3.10.1", sha256="c20fec55fc7e099f4d0c8224a36e194604577539445c5985cb465b23779baee8") version("3.10.0", sha256="7a7e7cd5cfbc40c6dc75bdb92b050c4191f992b5f7081cd08895bf119fd97bbf") version("3.9.0", sha256="456f707b25a8c502607134f1d699b5970ef1aa9d17877474db73fc6d87c711e9") @@ -32,3 +33,4 @@ class PyGlobusSdk(PythonPackage): depends_on("py-pyjwt@2.0.0:2+crypto", type=("build", "run")) depends_on("py-cryptography@3.3.1:3.3,3.4.1:", when="@3.7:", type=("build", "run")) depends_on("py-cryptography@2:3.3,3.4.1:3.6", when="@:3.0", type=("build", "run")) + depends_on("py-typing-extensions@4:", when="@3.25:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-gmxapi/package.py b/var/spack/repos/builtin/packages/py-gmxapi/package.py index 77a03d6fd4257d..27f3f7bf935f10 100644 --- a/var/spack/repos/builtin/packages/py-gmxapi/package.py +++ b/var/spack/repos/builtin/packages/py-gmxapi/package.py @@ -26,9 +26,11 @@ class PyGmxapi(PythonPackage): version("0.4.1", sha256="cc7a2e509ab8a59c187d388dcfd21ea78b785c3b355149b1818085f34dbda62a") version("0.4.0", sha256="7fd58e6a4b1391043379e8ba55555ebeba255c5b394f5df9d676e6a5571d7eba") + depends_on("cxx", type="build") # generated + depends_on("gromacs@2022.1:~mdrun_only+shared") depends_on("mpi") - depends_on("py-cmake@3.16:", type="build") + depends_on("cmake@3.16:", type="build") depends_on("py-importlib-metadata", type="test", when="^python@:3.7") depends_on("py-mpi4py", type=("build", "run")) depends_on("py-networkx@2.0:", type=("build", "run")) @@ -49,5 +51,4 @@ def setup_build_environment(self, env): def install_test(self): with working_dir("spack-test", create=True): # test include helper points to right location - python = self.spec["python"].command python("-m", "pytest", "-x", os.path.join(self.build_directory, "test")) diff --git a/var/spack/repos/builtin/packages/py-google-crc32c/package.py b/var/spack/repos/builtin/packages/py-google-crc32c/package.py index a083dd9cbc3965..2926fce25a53ac 100644 --- a/var/spack/repos/builtin/packages/py-google-crc32c/package.py +++ b/var/spack/repos/builtin/packages/py-google-crc32c/package.py @@ -19,6 +19,8 @@ class PyGoogleCrc32c(PythonPackage): version("1.3.0", sha256="276de6273eb074a35bc598f8efbc00c7869c5cf2e29c90748fccc8c898c244df") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("google-crc32c", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-googleapis-common-protos/package.py b/var/spack/repos/builtin/packages/py-googleapis-common-protos/package.py index b3529b2ffc60a9..2adba921f76c54 100644 --- a/var/spack/repos/builtin/packages/py-googleapis-common-protos/package.py +++ b/var/spack/repos/builtin/packages/py-googleapis-common-protos/package.py @@ -14,7 +14,9 @@ class PyGoogleapisCommonProtos(PythonPackage): license("Apache-2.0") + version("1.63.0", sha256="17ad01b11d5f1d0171c06d3ba5c04c54474e883b66b949722b4938ee2694ef4e") version("1.58.0", sha256="c727251ec025947d545184ba17e3578840fc3a24a0516a020479edab660457df") + version("1.56.4", sha256="c25873c47279387cfdcbdafa36149887901d36202cb645a0e4f29686bf6e4417") version("1.55.0", sha256="53eb313064738f45d5ac634155ae208e121c963659627b90dfcb61ef514c03e1") version("1.6.0", sha256="e61b8ed5e36b976b487c6e7b15f31bb10c7a0ca7bd5c0e837f4afab64b53a0c6") @@ -26,14 +28,21 @@ class PyGoogleapisCommonProtos(PythonPackage): description="Enable support for gRPC Remote Procedure Call framework.", ) - with when("+grpc"): - depends_on("py-grpcio@1.44:1", when="@1.57:", type="run") - depends_on("py-grpcio@1", when="@1.56.2:", type="run") - depends_on("py-grpcio@1:", type="run") - depends_on("py-setuptools", type="build") - depends_on( - "py-protobuf@3.19.5:3.19,3.20.2:4.21.0,4.21.6:4", when="@1.58:", type=("build", "run") - ) - depends_on("py-protobuf@3.12.0:3", when="@1.55", type=("build", "run")) - depends_on("py-protobuf@3.6.0:3", when="@:1.6", type=("build", "run")) + + with default_args(type=("build", "run")): + # https://github.com/googleapis/python-api-common-protos/blob/main/setup.py + # May be able to rais max version to :5 in next release + depends_on("py-protobuf@3.19.5:4", when="@1.58:") + depends_on("py-protobuf@3.15.0:4", when="@1.56:1.57") + depends_on("py-protobuf@3.12.0:4", when="@1.55") + depends_on("py-protobuf@3.6.0:", when="@1.6.0:") + + # Explicitly incompatibile versions per setup.py + # https://github.com/googleapis/python-api-common-protos/issues/128 + conflicts("py-protobuf@3.20:3.20.1") + conflicts("py-protobuf@4.21.1:4.21.5") + + with when("+grpc"), default_args(type="run"): + depends_on("py-grpcio@1.44:1", when="@1.57:") + depends_on("py-grpcio@1:") diff --git a/var/spack/repos/builtin/packages/py-gosam/package.py b/var/spack/repos/builtin/packages/py-gosam/package.py index 22e8f70f15938b..fc6eff141da774 100644 --- a/var/spack/repos/builtin/packages/py-gosam/package.py +++ b/var/spack/repos/builtin/packages/py-gosam/package.py @@ -26,6 +26,10 @@ class PyGosam(Package): sha256="4a2b9160d51e3532025b9579a4d17d0e0f8a755b8481aeb8271c1f58eb97ab01", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("form", type="run") depends_on("qgraf", type="run") depends_on("gosam-contrib", type="link") diff --git a/var/spack/repos/builtin/packages/py-gpaw/package.py b/var/spack/repos/builtin/packages/py-gpaw/package.py index 8a94a37b1d0077..c8e3c0a8e26b6c 100644 --- a/var/spack/repos/builtin/packages/py-gpaw/package.py +++ b/var/spack/repos/builtin/packages/py-gpaw/package.py @@ -22,6 +22,8 @@ class PyGpaw(PythonPackage): version("19.8.1", sha256="79dee367d695d68409c4d69edcbad5c8679137d6715da403f6c2500cb2178c2a") version("1.3.0", sha256="cf601c69ac496421e36111682bcc1d23da2dba2aabc96be51accf73dea30655c") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Build with MPI support") variant("scalapack", default=True, description="Build with ScaLAPACK support") variant("fftw", default=True, description="Build with FFTW support") @@ -59,7 +61,7 @@ def patch(self): python_include = spec["python"].headers.directories[0] numpy_include = join_path( - spec["py-numpy"].prefix, spec["python"].package.platlib, "numpy", "core", "include" + spec["py-numpy"].package.module.python_platlib, "numpy", "core", "include" ) libs = blas.libs + lapack.libs + libxc.libs diff --git a/var/spack/repos/builtin/packages/py-gpy/package.py b/var/spack/repos/builtin/packages/py-gpy/package.py index 172b79277ddaec..b2e8abf38dc381 100644 --- a/var/spack/repos/builtin/packages/py-gpy/package.py +++ b/var/spack/repos/builtin/packages/py-gpy/package.py @@ -19,6 +19,8 @@ class PyGpy(PythonPackage): version("1.9.9", sha256="04faf0c24eacc4dea60727c50a48a07ddf9b5751a3b73c382105e2a31657c7ed") version("0.8.8", sha256="e135d928cf170e2ec7fb058a035b5a7e334dc6b84d0bfb981556782528341988") + depends_on("c", type="build") # generated + variant("plotting", default=False, description="Enable plotting") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-grapheme/package.py b/var/spack/repos/builtin/packages/py-grapheme/package.py index 2670c50dc58d61..02e67b05756ec9 100644 --- a/var/spack/repos/builtin/packages/py-grapheme/package.py +++ b/var/spack/repos/builtin/packages/py-grapheme/package.py @@ -20,4 +20,6 @@ class PyGrapheme(PythonPackage): version("0.6.0", sha256="44c2b9f21bbe77cfb05835fec230bd435954275267fea1858013b102f8603cca") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-greenlet/package.py b/var/spack/repos/builtin/packages/py-greenlet/package.py index 920fa2f4907946..4b08225f4ee89a 100644 --- a/var/spack/repos/builtin/packages/py-greenlet/package.py +++ b/var/spack/repos/builtin/packages/py-greenlet/package.py @@ -29,5 +29,8 @@ class PyGreenlet(PythonPackage): version("0.4.17", sha256="41d8835c69a78de718e466dd0e6bfd4b46125f21a67c3ff6d76d8d8059868d6b") version("0.4.13", sha256="0fef83d43bf87a5196c91e73cb9772f945a4caaff91242766c5916d1dd1381e4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python", type=("build", "link", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-griddataformats/package.py b/var/spack/repos/builtin/packages/py-griddataformats/package.py index d91e53a05edbbd..d6a807cbf6137a 100644 --- a/var/spack/repos/builtin/packages/py-griddataformats/package.py +++ b/var/spack/repos/builtin/packages/py-griddataformats/package.py @@ -19,10 +19,13 @@ class PyGriddataformats(PythonPackage): license("LGPL-3.0-only") + version("1.0.2", sha256="b93cf7f36fce33dbc428026f26dba560d5c7ba2387caca495bad920f90094502") version("1.0.1", sha256="ad2c9ab7d672a6d8c426de7d083eee4f3e2b0bd59391675d30683c768ab83cc4") depends_on("py-setuptools", type="build") - depends_on("python@3.8:", type=("build", "run")) - depends_on("py-numpy@1.19:", type=("build", "run")) + depends_on("python@3.8:3.11", when="@1.0.1", type=("build", "run")) + depends_on("python@3.9:3.12", when="@1.0.2:", type=("build", "run")) + depends_on("py-numpy@1.19:", when="@1.0.1", type=("build", "run")) + depends_on("py-numpy@1.21:", when="@1.0.2:", type=("build", "run")) depends_on("py-scipy", type=("build", "run")) depends_on("py-mrcfile", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-grpcio-status/package.py b/var/spack/repos/builtin/packages/py-grpcio-status/package.py index ef05d860c9dbcf..7302b259cce86b 100644 --- a/var/spack/repos/builtin/packages/py-grpcio-status/package.py +++ b/var/spack/repos/builtin/packages/py-grpcio-status/package.py @@ -14,12 +14,18 @@ class PyGrpcioStatus(PythonPackage): license("Apache-2.0") + # Versions 1.63.0 and 1.64.0 are released but not yet on pypi + + version("1.62.2", sha256="62e1bfcb02025a1cd73732a2d33672d3e9d0df4d21c12c51e0bbcaf09bab742a") version("1.60.1", sha256="61b5aab8989498e8aa142c20b88829ea5d90d18c18c853b9f9e6d407d37bf8b4") + version("1.56.2", sha256="a046b2c0118df4a5687f4585cca9d3c3bae5c498c4dff055dcb43fb06a1180c8") # https://github.com/grpc/grpc/blob/v1.60.1/src/python/grpcio_status/setup.py - depends_on("py-protobuf@4.21.6:", type=("build", "run")) - depends_on("py-grpcio@1.60.1:", when="@1.60.1", type=("build", "run")) - depends_on("py-googleapis-common-protos@1.5.5:", type=("build", "run")) + with default_args(type=("build", "run")): + depends_on("py-protobuf@4.21.6:") + for grpcio in ("1.62.2", "1.60.1", "1.56.2"): + depends_on(f"py-grpcio@{grpcio}", when=f"@{grpcio}") + depends_on("py-googleapis-common-protos@1.5.5:") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-grpcio-tools/package.py b/var/spack/repos/builtin/packages/py-grpcio-tools/package.py index b46a70255eb73b..55069ba1c55b52 100644 --- a/var/spack/repos/builtin/packages/py-grpcio-tools/package.py +++ b/var/spack/repos/builtin/packages/py-grpcio-tools/package.py @@ -12,14 +12,23 @@ class PyGrpcioTools(PythonPackage): homepage = "https://grpc.io/" pypi = "grpcio-tools/grpcio-tools-1.42.0.tar.gz" + version("1.62.2", sha256="5fd5e1582b678e6b941ee5f5809340be5e0724691df5299aae8226640f94e18f") + version("1.56.2", sha256="82af2f4040084141a732f0ef1ecf3f14fdf629923d74d850415e4d09a077e77a") + version("1.48.2", sha256="8902a035708555cddbd61b5467cea127484362decc52de03f061a1a520fe90cd") version("1.48.1", sha256="1178f2ea531f80cc2027ec64728df6ffc8e98cf1df61652a496eafd612127183") version("1.42.0", sha256="d0a0daa82eb2c2fb8e12b82a458d1b7c5516fe1135551da92b1a02e2cba93422") version("1.39.0", sha256="39dfe7415bc0d3860fdb8dd90607594b046b88b57dbe64284efa4820f951c805") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-protobuf@3.12.0:3", when="@1.48.1:", type=("build", "run")) depends_on("py-protobuf@3.5.0.post1:3", type=("build", "run")) + depends_on("py-grpcio@1.62.2:", when="@1.62.2:", type=("build", "run")) + depends_on("py-grpcio@1.56.2:", when="@1.56.2:", type=("build", "run")) + depends_on("py-grpcio@1.48.2:", when="@1.48.2:", type=("build", "run")) depends_on("py-grpcio@1.48.1:", when="@1.48.1:", type=("build", "run")) depends_on("py-grpcio@1.42.0:", when="@1.42.0:", type=("build", "run")) depends_on("py-grpcio@1.39.0:", when="@1.39.0:1.41", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-grpcio/30522.diff b/var/spack/repos/builtin/packages/py-grpcio/30522.diff new file mode 100644 index 00000000000000..f0c9813fad30d4 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-grpcio/30522.diff @@ -0,0 +1,21 @@ +diff --git a/setup.py b/setup.py +index 8c428cb7f32b4..2646af5fd5ebb 100644 +--- a/setup.py ++++ b/setup.py +@@ -214,11 +214,11 @@ def check_linker_need_libatomic(): + return False + # Double-check to see if -latomic actually can solve the problem. + # https://github.com/grpc/grpc/issues/22491 +- cpp_test = subprocess.Popen( +- [cxx, '-x', 'c++', '-std=c++14', '-', '-latomic'], +- stdin=PIPE, +- stdout=PIPE, +- stderr=PIPE) ++ cpp_test = subprocess.Popen(cxx + ++ ['-x', 'c++', '-std=c++14', '-', '-latomic'], ++ stdin=PIPE, ++ stdout=PIPE, ++ stderr=PIPE) + cpp_test.communicate(input=code_test) + return cpp_test.returncode == 0 + diff --git a/var/spack/repos/builtin/packages/py-grpcio/package.py b/var/spack/repos/builtin/packages/py-grpcio/package.py index 02d06321236021..2163a87a0db1ee 100644 --- a/var/spack/repos/builtin/packages/py-grpcio/package.py +++ b/var/spack/repos/builtin/packages/py-grpcio/package.py @@ -14,9 +14,22 @@ class PyGrpcio(PythonPackage): license("Apache-2.0") + version("1.64.0", sha256="257baf07f53a571c215eebe9679c3058a313fd1d1f7c4eede5a8660108c52d9c") + version("1.63.0", sha256="f3023e14805c61bc439fb40ca545ac3d5740ce66120a678a3c6c2c55b70343d1") + version("1.62.2", sha256="c77618071d96b7a8be2c10701a98537823b9c65ba256c0b9067e0594cdbd954d") version("1.60.1", sha256="dd1d3a8d1d2e50ad9b59e10aa7f07c7d1be2b367f3f2d33c5fade96ed5460962") - version("1.52.0", sha256="a5d4a83d29fc39af429c10b9b326c174fec49b73398e4a966a1f2a4f30aa4fdb") - version("1.48.1", sha256="660217eccd2943bf23ea9a36e2a292024305aec04bf747fbcff1f5032b83610e") + version("1.56.2", sha256="0ff789ae7d8ddd76d2ac02e7d13bfef6fc4928ac01e1dcaa182be51b6bcc0aaa") + version( + "1.52.0", + sha256="a5d4a83d29fc39af429c10b9b326c174fec49b73398e4a966a1f2a4f30aa4fdb", + deprecated=True, # https://github.com/grpc/grpc/issues/32306 + ) + version("1.48.2", sha256="90e5da224c6b9b23658adf6f36de6f435ef7dbcc9c5c12330314d70d6f8de1f7") + version( + "1.48.1", + sha256="660217eccd2943bf23ea9a36e2a292024305aec04bf747fbcff1f5032b83610e", + deprecated=True, # https://github.com/grpc/grpc/issues/30372 + ) version("1.43.0", sha256="735d9a437c262ab039d02defddcb9f8f545d7009ae61c0114e19dda3843febe5") version("1.42.0", sha256="4a8f2c7490fe3696e0cdd566e2f099fb91b51bc75446125175c55581c2f7bc11") version("1.39.0", sha256="57974361a459d6fe04c9ae0af1845974606612249f467bbd2062d963cb90f407") @@ -36,16 +49,41 @@ class PyGrpcio(PythonPackage): version("1.28.1", sha256="cbc322c5d5615e67c2a15be631f64e6c2bab8c12505bc7c150948abdaa0bdbac") version("1.27.2", sha256="5ae532b93cf9ce5a2a549b74a2c35e3b690b171ece9358519b3039c7b84c887e") version("1.25.0", sha256="c948c034d8997526011960db54f512756fb0b4be1b81140a15b4ef094c6594a4") - version("1.16.0", sha256="d99db0b39b490d2469a8ef74197d5f211fa740fc9581dccecbb76c56d080fce1") + version( + "1.16.0", + sha256="0cc5f2d3ee21c642d8982f197c83053fd3a8cbcd6a60240d8c87c6c256b10d57", + deprecated=True, + # Released 6ish years ago and does not install for python 3.8 with gcc11 + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("py-setuptools", type="build") - depends_on("py-six@1.5.2:", when="@:1.48", type=("build", "run")) - depends_on("py-cython@0.23:2", type="build") + with default_args(type=("build", "run")): + depends_on("py-coverage@4:") + depends_on("py-wheel@0.29:") + + depends_on("py-cython@3:", when="@1.63.0:") + depends_on("py-cython@0.29.8:2", when="@1.56.0:1.62") + depends_on("py-cython@0.29.8:", when="@1.49.0:1.55") + # States dependency in setup.py >=0.23 + # Package states >=0.23 but doesn't compile w/ >=3 + depends_on("py-cython@0.23:2", when="@:1.48") + + depends_on("py-protobuf@5.26.1:5", when="@1.63.0:") + depends_on("py-protobuf@4.21.3:4", when="@1.49.0:1.62") + depends_on("py-protobuf@3.5.0:3", when="@:1.48") + + depends_on("py-six@1.10:", when="@:1.48") + depends_on("openssl") depends_on("zlib-api") depends_on("c-ares") depends_on("re2+shared") + patch("30522.diff", when="@1.48") # https://github.com/grpc/grpc/issues/30372 + def setup_build_environment(self, env): env.set("GRPC_PYTHON_BUILD_WITH_CYTHON", True) env.set("GRPC_PYTHON_BUILD_SYSTEM_OPENSSL", True) diff --git a/var/spack/repos/builtin/packages/py-gsd/package.py b/var/spack/repos/builtin/packages/py-gsd/package.py index a87b2c93a6a675..85eaa50c5b23eb 100644 --- a/var/spack/repos/builtin/packages/py-gsd/package.py +++ b/var/spack/repos/builtin/packages/py-gsd/package.py @@ -15,13 +15,14 @@ class PyGsd(PythonPackage): trajectory output with a script. Read a GSD trajectory with a visualization tool to explore the behavior of the simulation.""" - homepage = "https://gsd.readthedocs.io/en/stable/#" + homepage = "https://gsd.readthedocs.io/en/stable/" pypi = "gsd/gsd-1.9.3.tar.gz" maintainers("RMeli") license("BSD-2-Clause") + version("3.2.1", sha256="cf05148e23f169a00c073eb7d8151e8b521e0f962ce460b55d812cae5be326aa") version("3.2.0", sha256="cf3c8419ec66085b2b9853577058861d9e738bfe397b0170ead821b866ab49b9") version("3.1.1", sha256="6802b79d7f078536faf5a96ac300518613dd285cf3bc21ed81e1f2d0f7155bf5") version("3.1.0", sha256="35a70419c6a519825afd9d5e47a570d98cec7273c39f43e2ab0aa3e7166ad198") @@ -29,6 +30,8 @@ class PyGsd(PythonPackage): version("2.8.0", sha256="f2b031a26a7a5bee5f3940dc2f36c5a5b6670307b297c526adf2e26c1f5b46ae") version("1.9.3", sha256="c6b37344e69020f69fda2b8d97f894cb41fd720840abeda682edd680d1cff838") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-setuptools@42:", type="build", when="@2.8.0:") depends_on("py-setuptools@64:", type="build", when="@3.0.1:") diff --git a/var/spack/repos/builtin/packages/py-gtdbtk/package.py b/var/spack/repos/builtin/packages/py-gtdbtk/package.py index a78e86eed08d6c..08eda2bc7d18b8 100644 --- a/var/spack/repos/builtin/packages/py-gtdbtk/package.py +++ b/var/spack/repos/builtin/packages/py-gtdbtk/package.py @@ -28,7 +28,7 @@ class PyGtdbtk(PythonPackage): depends_on("py-pydantic@1.9.2:1", type=("build", "run"), when="@2.3.0:") depends_on("prodigal@2.6.2:", type=("build", "run")) depends_on("hmmer@3.1b2:", type=("build", "run")) - depends_on("pplacer@1.1:", type=("build", "run")) + depends_on("pplacer@1.1alpha:", type=("build", "run")) depends_on("fastani@1.32:", type=("build", "run")) depends_on("fasttree@2.1.9:", type=("build", "run")) depends_on("mash@2.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-h5py/package.py b/var/spack/repos/builtin/packages/py-h5py/package.py index aadeb4b9001b4a..43220375073ff9 100644 --- a/var/spack/repos/builtin/packages/py-h5py/package.py +++ b/var/spack/repos/builtin/packages/py-h5py/package.py @@ -18,6 +18,7 @@ class PyH5py(PythonPackage): license("BSD-3-Clause") version("master", branch="master") + version("3.11.0", sha256="7b7e8f78072a2edec87c9836f25f34203fd492a4475709a18b417a33cfb21fa9") version("3.10.0", sha256="d93adc48ceeb33347eb24a634fb787efc7ae4644e6ea4ba733d099605045c049") version("3.9.0", sha256="e604db6521c1e367c6bd7fad239c847f53cc46646f2d2651372d05ae5e95f817") version("3.8.0", sha256="6fead82f0c4000cf38d53f9c030780d81bfa0220218aee13b90b7701c937d95f") @@ -39,16 +40,20 @@ class PyH5py(PythonPackage): version("2.5.0", sha256="9833df8a679e108b561670b245bcf9f3a827b10ccb3a5fa1341523852cfac2f6") version("2.4.0", sha256="faaeadf4b8ca14c054b7568842e0d12690de7d5d68af4ecce5d7b8fc104d8e60") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Build with MPI support") # Python versions depends_on("python@:3.9", type=("build", "run"), when="@:2.8") # Build dependencies - depends_on("py-cython@0.29.31:0", type="build", when="@3.9:") + # h5py@3.11 can build with cython@3.x + depends_on("py-cython@0.29.31:3", type="build", when="@3.11:") + depends_on("py-cython@0.29.31:0", type="build", when="@3.9:3.10") depends_on("py-cython@0.29.15:0", type=("build"), when="@3:3.7 ^python@3.9.0:") depends_on("py-cython@0.29.14:0", type=("build"), when="@3:3.7 ^python@3.8.0:3.8") - depends_on("py-cython@0.29:0", type=("build"), when="@3:") + depends_on("py-cython@0.29:0", type=("build"), when="@3.0:3.10") depends_on("py-cython@0.23:0", type="build", when="@:2") depends_on("py-pkgconfig", type="build") depends_on("py-setuptools@61:", type="build", when="@3.8.0:") @@ -60,10 +65,13 @@ class PyH5py(PythonPackage): depends_on("py-numpy@1.17.5:", type=("build", "run"), when="@3:3.5 ^python@3.8.0:3.8") depends_on("py-numpy@1.14.5:", type=("build", "run"), when="@3:") depends_on("py-numpy@1.7:", type=("build", "run"), when="@:2") + # https://github.com/h5py/h5py/issues/2353 + depends_on("py-numpy@:1", when="@:3.10", type=("build", "run")) # Link dependencies (py-h5py v2 cannot build against HDF5 1.12 regardless # of API setting) - depends_on("hdf5@1.8.4:1.14 +hl", when="@3.8:") + depends_on("hdf5@1.10.4:1.14 +hl", when="@3.10:") + depends_on("hdf5@1.8.4:1.14 +hl", when="@3.8:3.9") depends_on("hdf5@1.8.4:1.12 +hl", when="@3:3.7") depends_on("hdf5@1.8.4:1.11 +hl", when="@:2") diff --git a/var/spack/repos/builtin/packages/py-hatchet/package.py b/var/spack/repos/builtin/packages/py-hatchet/package.py index 1a3a69b543ad44..d9ce43e8068fcf 100644 --- a/var/spack/repos/builtin/packages/py-hatchet/package.py +++ b/var/spack/repos/builtin/packages/py-hatchet/package.py @@ -24,6 +24,8 @@ class PyHatchet(PythonPackage): version("1.0.1", sha256="e5a4b455ab6bfbccbce3260673d9af8d1e4b21e19a2b6d0b6c1e1d7727613b7a") version("1.0.0", sha256="efd218bc9152abde0a8006489a2c432742f00283a114c1eeb6d25abc10f5862d") + depends_on("c", type="build") # generated + # https://github.com/hatchet/hatchet/issues/428 depends_on("python@2.7:3.8", when="@:1.3.0", type=("build", "run")) depends_on("python@2.7:", when="@1.3.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-healpy/package.py b/var/spack/repos/builtin/packages/py-healpy/package.py index eb7931bf2504ab..19fe0f5367f066 100644 --- a/var/spack/repos/builtin/packages/py-healpy/package.py +++ b/var/spack/repos/builtin/packages/py-healpy/package.py @@ -18,6 +18,10 @@ class PyHealpy(PythonPackage): version("1.13.0", sha256="d0ae02791c2404002a09c643e9e50bc58e3d258f702c736dc1f39ce1e6526f73") version("1.7.4", sha256="3cca7ed7786ffcca70e2f39f58844667ffb8521180ac890d4da651b459f51442") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("py-setuptools@3.2:", type="build") depends_on("py-pkgconfig", type="build") depends_on("py-numpy@1.13:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-heat/package.py b/var/spack/repos/builtin/packages/py-heat/package.py index 90e5bcaf4ce15b..f14a4c02099177 100644 --- a/var/spack/repos/builtin/packages/py-heat/package.py +++ b/var/spack/repos/builtin/packages/py-heat/package.py @@ -18,6 +18,9 @@ class PyHeat(PythonPackage): license("MIT") + version("1.4.1", sha256="ecd871717c372a6983f643c0178dda44bc017d6b32b9258dbf3775af95f580ce") + version("1.4.0", sha256="6836fa10f9ce62ea61cf1bdc3283d7ad0c305836cc5a08c4edfd30695708e788") + version("1.3.1", sha256="8997ddc56a1d3078b44a1e2933adc0a7fbf678bd19bade3ae015bc0e13d40d3b") version("1.3.0", sha256="fa247539a559881ffe574a70227d3c72551e7c4a9fb29b0945578d6a840d1c87") variant("docutils", default=False, description="Use the py-docutils package") @@ -32,15 +35,26 @@ class PyHeat(PythonPackage): description="Use py-scikit-learn and py-matplotlib for the example tests", ) - depends_on("python@3.8:", type=("build", "run")) - depends_on("py-numpy@1.20:", type=("build", "run")) - depends_on("py-torch@1.8:2.0.1", type=("build", "run")) - depends_on("py-scipy@0.14:", type=("build", "run")) - depends_on("pil@6:", type=("build", "run")) - depends_on("py-torchvision@0.8:", type=("build", "run")) - depends_on("py-mpi4py@3:", type=("build", "run")) depends_on("py-setuptools", type="build") + with when("@1.3"): + depends_on("python@3.8:3.10", type=("build", "run")) + depends_on("py-mpi4py@3:", type=("build", "run")) + depends_on("py-numpy@1.20:1", type=("build", "run")) + depends_on("py-torch@1.8:2.0.1", type=("build", "run")) + depends_on("py-scipy@0.14:", type=("build", "run")) + depends_on("pil@6:", type=("build", "run")) + depends_on("py-torchvision@0.8:", type=("build", "run")) + + with when("@1.4"): + depends_on("python@3.8:3.11", type=("build", "run")) + depends_on("py-mpi4py@3:", type=("build", "run")) + depends_on("py-numpy@1.22:1", type=("build", "run")) + depends_on("py-torch@1.11:2.2.2", type=("build", "run")) + depends_on("py-scipy@1.10:", type=("build", "run")) + depends_on("pil@6:", type=("build", "run")) + depends_on("py-torchvision@0.12:", type=("build", "run")) + depends_on("py-docutils@0.16:", when="+docutils", type=("build", "link", "run")) depends_on("py-h5py@2.8.0:", when="+hdf5", type=("build", "link", "run")) depends_on("py-netcdf4@1.5.6:", when="+netcdf", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/py-hepdata-lib/package.py b/var/spack/repos/builtin/packages/py-hepdata-lib/package.py index d1b9fe2c4a889e..9512559ad2fd50 100644 --- a/var/spack/repos/builtin/packages/py-hepdata-lib/package.py +++ b/var/spack/repos/builtin/packages/py-hepdata-lib/package.py @@ -19,6 +19,8 @@ class PyHepdataLib(PythonPackage): version("0.10.1", sha256="71c635963883c51e7be18e03d80bfe42c5de350852b01010e3e45cbd1bff7a81") version("0.9.0", sha256="c9238e45c603d7c061ed670cf197ff03ad9d370ab50419b6916fda2cd86d6150") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("root+python", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-hiredis/package.py b/var/spack/repos/builtin/packages/py-hiredis/package.py index 03379ae6777f6a..0b783b1ce0fd43 100644 --- a/var/spack/repos/builtin/packages/py-hiredis/package.py +++ b/var/spack/repos/builtin/packages/py-hiredis/package.py @@ -18,5 +18,7 @@ class PyHiredis(PythonPackage): version("1.1.0", sha256="996021ef33e0f50b97ff2d6b5f422a0fe5577de21a8873b58a779a5ddd1c3132") + depends_on("c", type="build") # generated + depends_on("python@2.7:2.8,3.4:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-hmmlearn/package.py b/var/spack/repos/builtin/packages/py-hmmlearn/package.py index cbb457b6e7f735..6eca677529464b 100644 --- a/var/spack/repos/builtin/packages/py-hmmlearn/package.py +++ b/var/spack/repos/builtin/packages/py-hmmlearn/package.py @@ -19,6 +19,8 @@ class PyHmmlearn(PythonPackage): version("0.3.0", sha256="d13a91ea3695df881465e3d36132d7eef4e84d483f4ba538a4b46e24b5ea100f") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-setuptools-scm@3.3:", type="build") depends_on("py-pybind11@2.6:", type="build") diff --git a/var/spack/repos/builtin/packages/py-horovod/package.py b/var/spack/repos/builtin/packages/py-horovod/package.py index 56effd1982ec36..61d85736c01876 100644 --- a/var/spack/repos/builtin/packages/py-horovod/package.py +++ b/var/spack/repos/builtin/packages/py-horovod/package.py @@ -125,6 +125,10 @@ class PyHorovod(PythonPackage, CudaPackage): "0.16.2", tag="v0.16.2", commit="217774652eeccfcd60aa6e268dfd6b766d71b768", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # https://github.com/horovod/horovod/blob/master/docs/install.rst variant( "frameworks", diff --git a/var/spack/repos/builtin/packages/py-htseq/package.py b/var/spack/repos/builtin/packages/py-htseq/package.py index 8b90b775640b5c..0a524e543ae970 100644 --- a/var/spack/repos/builtin/packages/py-htseq/package.py +++ b/var/spack/repos/builtin/packages/py-htseq/package.py @@ -19,6 +19,9 @@ class PyHtseq(PythonPackage): version("0.11.2", sha256="65c4c13968506c7df92e97124df96fdd041c4476c12a548d67350ba8b436bcfc") version("0.9.1", sha256="af5bba775e3fb45ed4cde64c691ebef36b0bf7a86efd35c884ad0734c27ad485") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("qa", default=True, description="Quality assessment") variant("mtx", default=True, description="BigWig manipulation", when="@2:") variant("mtx", default=True, description="mtx output files", when="@2:") diff --git a/var/spack/repos/builtin/packages/py-httpstan/package.py b/var/spack/repos/builtin/packages/py-httpstan/package.py index efa08de8110fc7..f4ecbbe8d5fac9 100644 --- a/var/spack/repos/builtin/packages/py-httpstan/package.py +++ b/var/spack/repos/builtin/packages/py-httpstan/package.py @@ -20,6 +20,8 @@ class PyHttpstan(PythonPackage): version("4.7.2", sha256="94f6631d969cbd91d136194b074d02642d8c9e2a05674877a39059be87c5bf7b") version("4.6.1", sha256="703e5e04e60651e0004574bb9695827d759fd13eb0d6bd67f827c1bfa0a1fd31") + depends_on("cxx", type="build") # generated + depends_on("python@3.8:3", type=("build", "run"), when="@4.7:") depends_on("python@3.7:3", type=("build", "run"), when="@:4.6") depends_on("py-setuptools@41.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-httptools/package.py b/var/spack/repos/builtin/packages/py-httptools/package.py index d4708c117bdc99..cfba153d5210c2 100644 --- a/var/spack/repos/builtin/packages/py-httptools/package.py +++ b/var/spack/repos/builtin/packages/py-httptools/package.py @@ -17,5 +17,7 @@ class PyHttptools(PythonPackage): version("0.5.0", sha256="295874861c173f9101960bba332429bb77ed4dcd8cdf5cee9922eb00e4f6bc09") version("0.1.1", sha256="41b573cf33f64a8f8f3400d0a7faf48e1888582b6f6e02b82b9bd4f0bf7497ce") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cython@0.29.24:0.29", type="build") diff --git a/var/spack/repos/builtin/packages/py-huggingface-hub/package.py b/var/spack/repos/builtin/packages/py-huggingface-hub/package.py index d9ee1717de2b6a..f0766e409fe272 100644 --- a/var/spack/repos/builtin/packages/py-huggingface-hub/package.py +++ b/var/spack/repos/builtin/packages/py-huggingface-hub/package.py @@ -16,6 +16,7 @@ class PyHuggingfaceHub(PythonPackage): license("Apache-2.0") + version("0.23.4", sha256="35d99016433900e44ae7efe1c209164a5a81dbbcd53a52f99c281dcd7ce22431") version("0.19.4", sha256="176a4fc355a851c17550e7619488f383189727eab209534d7cef2114dae77b22") version("0.14.1", sha256="9ab899af8e10922eac65e290d60ab956882ab0bf643e3d990b1394b6b47b7fbc") version("0.10.1", sha256="5c188d5b16bec4b78449f8681f9975ff9d321c16046cc29bcf0d7e464ff29276") diff --git a/var/spack/repos/builtin/packages/py-humanize/package.py b/var/spack/repos/builtin/packages/py-humanize/package.py index d9efe5ef12cd9f..f12a12996cb836 100644 --- a/var/spack/repos/builtin/packages/py-humanize/package.py +++ b/var/spack/repos/builtin/packages/py-humanize/package.py @@ -18,12 +18,19 @@ class PyHumanize(PythonPackage): license("MIT") + version("4.9.0", sha256="582a265c931c683a7e9b8ed9559089dea7edcf6cc95be39a3cbc2c5d5ac2bcfa") + version("4.8.0", sha256="9783373bf1eec713a770ecaa7c2d7a7902c98398009dfa3d8a2df91eec9311e8") version("4.6.0", sha256="5f1f22bc65911eb1a6ffe7659bd6598e33dcfeeb904eb16ee1e705a09bf75916") version("4.4.0", sha256="efb2584565cc86b7ea87a977a15066de34cdedaf341b11c851cfcfd2b964779c") version("4.0.0", sha256="ee1f872fdfc7d2ef4a28d4f80ddde9f96d36955b5d6b0dac4bdeb99502bddb00") + version("3.14.0", sha256="60dd8c952b1df1ad83f0903844dec50a34ba7a04eea22a6b14204ffb62dbb0a4") version("3.12.0", sha256="5ec1a66e230a3e31fb3f184aab9436ea13d4e37c168e0ffc345ae5bb57e58be6") + version("2.6.0", sha256="8ee358ea6c23de896b9d1925ebe6a8504bb2ba7e98d5ccf4d07ab7f3b28f3819") + version("1.1.0", sha256="ad83016fae2453a7486f5be5dba8e19883020c77f6c12c63702f3b6c15ae3c5e") + version("1.0.0", sha256="38ace9b66bcaeb7f8186b9dbf0b3448e00148e5b4fbaf726f96c789e52c3e741") version("0.5.1", sha256="a43f57115831ac7c70de098e6ac46ac13be00d69abbf60bdcac251344785bb19") + depends_on("python@3.8:", when="@4.6:") depends_on("py-hatch-vcs", when="@4.6:", type=("build", "run")) depends_on("py-hatchling", when="@4.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-hypothesis/package.py b/var/spack/repos/builtin/packages/py-hypothesis/package.py index 90469c997b0995..cbec4e5c5208a5 100644 --- a/var/spack/repos/builtin/packages/py-hypothesis/package.py +++ b/var/spack/repos/builtin/packages/py-hypothesis/package.py @@ -14,6 +14,7 @@ class PyHypothesis(PythonPackage): license("MPL-2.0") + version("6.96.2", sha256="524a0ac22c8dfff640f21f496b85ee193a470e8570ab7707b8e3bfccd7da34a6") version("6.23.1", sha256="23a1b0488aec5719e2f9e399342e10f30d497cbb9fd39470ef0975c1b502ae35") version("5.3.0", sha256="c9fdb53fe3bf1f8e7dcca1a7dd6e430862502f088aca2903d141511212e79429") version("4.57.1", sha256="3c4369a4b0a1348561048bcda5f1db951a1b8e2a514ea8e8c70d36e656bf6fa0") @@ -22,42 +23,33 @@ class PyHypothesis(PythonPackage): version("4.7.2", sha256="87944c6379f77634474b88abbf1e5ed5fe966637cc926131eda5e2af5b54a608") version("3.7.0", sha256="0fea49d08f2d5884f014151a5af6fb48d862f6ad567ffc4a2e84abf2f186c423") - depends_on("python@2.7:2.8,3.5:", type=("build", "run")) - depends_on("python@3.6:", type=("build", "run"), when="@6:") - depends_on("py-setuptools@36.2:", type=("build")) - depends_on("py-attrs@19.2.0:", when="@4.38.2:", type=("build", "run")) - depends_on("py-attrs@16.0.0:", when="@3.44.22:", type=("build", "run")) + variant("django", default=False, description="Enable django support") + variant("numpy", default=False, description="Enable numpy support") + variant("pandas", default=False, description="Enable pandas support") + + depends_on("py-setuptools@36.2:", type="build") + depends_on("py-attrs@22.2:", when="@6.96:", type=("build", "run")) + depends_on("py-attrs@19.2:", when="@4.38.2:", type=("build", "run")) + depends_on("py-attrs@16.0:", when="@3.44.22:", type=("build", "run")) depends_on("py-attrs", when="@3.28.0:", type=("build", "run")) - depends_on("py-sortedcontainers@2.1.0:2", type=("build", "run"), when="@4.57.1:") + depends_on("py-exceptiongroup@1:", when="@6.96: ^python@:3.10", type=("build", "run")) + depends_on("py-sortedcontainers@2.1:2", type=("build", "run"), when="@4.57.1:") + depends_on("py-django@3.2:", type="run", when="@6.96: +django") depends_on("py-django@2.2:", type="run", when="+django") depends_on("py-pytz@2014.1:", type="run", when="+django") + depends_on("py-numpy@1.17.3:", type="run", when="@6.96: +numpy") depends_on("py-numpy@1.9.0:", type="run", when="+numpy") + # https://github.com/HypothesisWorks/hypothesis/issues/3950 + depends_on("py-numpy@:1", when="@:6.100.1+numpy", type="run") + depends_on("py-pandas@1.1:", type="run", when="@6.96: +pandas") depends_on("py-pandas@0.25:", type="run", when="+pandas") - variant("django", default=False, description="Enable django support") - variant("numpy", default=False, description="Enable numpy support") - variant("pandas", default=False, description="Enable pandas support") - - # All modules except for 'hypothesis.extra.pandas' and 'hypothesis.extra.django', - # which are optional and are only added when their variants are enabled: - import_test_modules = [ - "hypothesis", - "hypothesis.extra", - "hypothesis.utils", - "hypothesis.strategies", - "hypothesis.strategies._internal", - "hypothesis.vendor", - "hypothesis.internal", - "hypothesis.internal.conjecture", - "hypothesis.internal.conjecture.shrinking", - "hypothesis.internal.conjecture.dfa", - ] - @property - def import_modules(self): - if self.spec.satisfies("+pandas"): - self.import_test_modules.append("hypothesis.extra.pandas") - if self.spec.satisfies("+django"): - self.import_test_modules.append("hypothesis.extra.django") - return self.import_test_modules + def skip_modules(self): + modules = [] + if "+django" not in self.spec: + modules.append("hypothesis.extra.django") + if "+pandas" not in self.spec: + modules.append("hypothesis.extra.pandas") + return modules diff --git a/var/spack/repos/builtin/packages/py-igor2/package.py b/var/spack/repos/builtin/packages/py-igor2/package.py index 6f3e7d47ba7c35..5e03507d7b4937 100644 --- a/var/spack/repos/builtin/packages/py-igor2/package.py +++ b/var/spack/repos/builtin/packages/py-igor2/package.py @@ -15,11 +15,7 @@ class PyIgor2(PythonPackage): license("LGPL-3.0-or-later") - version( - "0.5.3", - sha256="bb7b54a5926ec640e0e9176f46e0dd88ad956fec2d17ba3b0a7687eba82cefee", - expand=False, - ) + version("0.5.3", sha256="bb7b54a5926ec640e0e9176f46e0dd88ad956fec2d17ba3b0a7687eba82cefee") depends_on("python@3.8:3", type=("build", "run")) depends_on("py-numpy@1.25.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-igraph/package.py b/var/spack/repos/builtin/packages/py-igraph/package.py index 7d3b4b32266949..5468e008c5d89b 100644 --- a/var/spack/repos/builtin/packages/py-igraph/package.py +++ b/var/spack/repos/builtin/packages/py-igraph/package.py @@ -17,6 +17,10 @@ class PyIgraph(PythonPackage): version("0.10.6", sha256="76f7aad294514412f835366a7d9a9c1e7a34c3e6ef0a6c3a1a835234323228e8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("matplotlib", default=False, description="Enable plotting with Matplotlib") depends_on("cmake", type="build") diff --git a/var/spack/repos/builtin/packages/py-ilmbase/package.py b/var/spack/repos/builtin/packages/py-ilmbase/package.py index 7b55335768f406..16c8cd3679b418 100644 --- a/var/spack/repos/builtin/packages/py-ilmbase/package.py +++ b/var/spack/repos/builtin/packages/py-ilmbase/package.py @@ -14,6 +14,8 @@ class PyIlmbase(AutotoolsPackage): version("2.3.0", sha256="9c898bb16e7bc916c82bebdf32c343c0f2878fc3eacbafa49937e78f2079a425") + depends_on("cxx", type="build") # generated + depends_on("ilmbase") depends_on("boost+python") depends_on("py-numpy") diff --git a/var/spack/repos/builtin/packages/py-imagecodecs/package.py b/var/spack/repos/builtin/packages/py-imagecodecs/package.py index bd425abe9b8b37..b6f1bb6c19dcfc 100644 --- a/var/spack/repos/builtin/packages/py-imagecodecs/package.py +++ b/var/spack/repos/builtin/packages/py-imagecodecs/package.py @@ -20,8 +20,13 @@ class PyImagecodecs(PythonPackage): version("2022.2.22", sha256="062bef6b003290a8163abed2744b406854238208dfdd41cf7165253c6e01c0bd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.8:", type=("build", "run")) depends_on("py-numpy@1.19.2:", type=("build", "run")) + # https://github.com/cgohlke/imagecodecs/issues/100 + depends_on("py-numpy@:1", when="@:2024.6.0", type=("build", "run")) depends_on("py-setuptools@18.0:", type="build") depends_on("py-cython@0.29.27:", type="build") depends_on("py-bitshuffle@0.3.5:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-imageio/package.py b/var/spack/repos/builtin/packages/py-imageio/package.py index c82511a03be4d4..c204ef6c61d730 100644 --- a/var/spack/repos/builtin/packages/py-imageio/package.py +++ b/var/spack/repos/builtin/packages/py-imageio/package.py @@ -19,6 +19,7 @@ class PyImageio(PythonPackage): license("BSD-2-Clause") + version("2.34.0", sha256="ae9732e10acf807a22c389aef193f42215718e16bd06eed0c5bb57e1034a4d53") version("2.30.0", sha256="7fc6ad5b5677cb1e58077875a72512aa8c392b6d40885eca0a6ab250efb4b8f4") version("2.22.0", sha256="a332d127ec387b2d3dca967fd065a90f1c1a4ba2343570b03fe2cebb6ed064ea") version("2.16.0", sha256="7f7d8d8e1eb6f8bb1d15e0dd93bee3f72026a4c3b96e9c690e42f403f7bdea3e") @@ -34,6 +35,8 @@ class PyImageio(PythonPackage): depends_on("py-numpy", type=("build", "run")) depends_on("py-numpy@1.20:", when="@2.16", type=("build", "run")) + # https://github.com/imageio/imageio/issues/1077 + depends_on("py-numpy@:1", when="@:2.34.1", type=("build", "run")) depends_on("pil@8.3.2:", when="@2.10:", type=("build", "run")) depends_on("pil", type=("build", "run")) depends_on("ffmpeg", type="run") diff --git a/var/spack/repos/builtin/packages/py-iminuit/package.py b/var/spack/repos/builtin/packages/py-iminuit/package.py index 45311c7595661e..b66aaa0938580e 100644 --- a/var/spack/repos/builtin/packages/py-iminuit/package.py +++ b/var/spack/repos/builtin/packages/py-iminuit/package.py @@ -17,9 +17,13 @@ class PyIminuit(PythonPackage): version("1.3.6", sha256="d79a197f305d4708a0e3e52b0a6748c1a6997360d2fbdfd09c022995a6963b5e") version("1.2", sha256="7651105fc3f186cfb5742f075ffebcc5088bf7797d8ed124c00977eebe0d1c64") + depends_on("cxx", type="build") # generated + # Required dependencies depends_on("python@3.6:", type=("build", "run"), when="@2.6.1:") depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run"), when="@1.3:1.3.6") depends_on("py-numpy@1.11.3:", type=("build", "run"), when="@1.3.7:") - depends_on("py-cmake", type="build", when="@2.8.4") + # https://github.com/numpy/numpy/issues/26191#issuecomment-2179127999 + depends_on("py-numpy@:1", when="@:2.25", type=("build", "run")) + depends_on("cmake", type="build", when="@2.8.4") diff --git a/var/spack/repos/builtin/packages/py-immutables/package.py b/var/spack/repos/builtin/packages/py-immutables/package.py index 22ddcdc7413db2..e2b53d484c8170 100644 --- a/var/spack/repos/builtin/packages/py-immutables/package.py +++ b/var/spack/repos/builtin/packages/py-immutables/package.py @@ -21,6 +21,8 @@ class PyImmutables(PythonPackage): version("0.16", sha256="d67e86859598eed0d926562da33325dac7767b7b1eff84e232c22abea19f4360") version("0.14", sha256="a0a1cc238b678455145bae291d8426f732f5255537ed6a5b7645949704c70a78") + depends_on("c", type="build") # generated + depends_on("python@3.5:", type=("build", "run")) depends_on("python@3.6:", type=("build", "run"), when="@0.16:") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-installer/package.py b/var/spack/repos/builtin/packages/py-installer/package.py index 7de649a5e91f68..6ecf2c5b4e8f93 100644 --- a/var/spack/repos/builtin/packages/py-installer/package.py +++ b/var/spack/repos/builtin/packages/py-installer/package.py @@ -17,16 +17,8 @@ class PyInstaller(Package, PythonExtension): ) list_url = "https://pypi.org/simple/installer/" - version( - "0.7.0", - sha256="05d1933f0a5ba7d8d6296bb6d5018e7c94fa473ceb10cf198a92ccea19c27b53", - expand=False, - ) - version( - "0.6.0", - sha256="ae7c62d1d6158b5c096419102ad0d01fdccebf857e784cee57f94165635fe038", - expand=False, - ) + version("0.7.0", sha256="05d1933f0a5ba7d8d6296bb6d5018e7c94fa473ceb10cf198a92ccea19c27b53") + version("0.6.0", sha256="ae7c62d1d6158b5c096419102ad0d01fdccebf857e784cee57f94165635fe038") extends("python") @@ -44,6 +36,4 @@ def install(self, spec, prefix): python(*args) def setup_dependent_package(self, module, dependent_spec): - installer = dependent_spec["python"].command - installer.add_default_arg("-m", "installer") - setattr(module, "installer", installer) + setattr(module, "installer", python.with_default_args("-m", "installer")) diff --git a/var/spack/repos/builtin/packages/py-intbitset/package.py b/var/spack/repos/builtin/packages/py-intbitset/package.py index 01a55114bc043e..93c72606f01032 100644 --- a/var/spack/repos/builtin/packages/py-intbitset/package.py +++ b/var/spack/repos/builtin/packages/py-intbitset/package.py @@ -20,4 +20,6 @@ class PyIntbitset(PythonPackage): version("3.0.1", sha256="f1e6d03c6729922a223c51849df65b9e916e625aefb911784e7f9acd4c207d53") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-intel-openmp/package.py b/var/spack/repos/builtin/packages/py-intel-openmp/package.py index bfb28c441ca9ca..5fdfe9449bbff9 100644 --- a/var/spack/repos/builtin/packages/py-intel-openmp/package.py +++ b/var/spack/repos/builtin/packages/py-intel-openmp/package.py @@ -23,7 +23,6 @@ class PyIntelOpenmp(PythonPackage): "2021.1.2", url="https://pypi.io/packages/py2.py3/i/intel-openmp/intel_openmp-2021.1.2-py2.py3-none-manylinux1_x86_64.whl", sha256="8796797ecae99f39b27065e4a7f1f435e2ca08afba654ca57a77a2717f864dca", - expand=False, ) if sys.platform.startswith("darwin"): @@ -31,5 +30,4 @@ class PyIntelOpenmp(PythonPackage): "2021.1.2", url="https://pypi.io/packages/py2.py3/i/intel-openmp/intel_openmp-2021.1.2-py2.py3-none-macosx_10_15_x86_64.whl", sha256="2af893738b4b06cb0183746f2992169111031340b59c84a0fd4dec1ed66b80f2", - expand=False, ) diff --git a/var/spack/repos/builtin/packages/py-ipykernel/package.py b/var/spack/repos/builtin/packages/py-ipykernel/package.py index 2357fbb56d5ffb..b272f2faca49b0 100644 --- a/var/spack/repos/builtin/packages/py-ipykernel/package.py +++ b/var/spack/repos/builtin/packages/py-ipykernel/package.py @@ -15,6 +15,13 @@ class PyIpykernel(PythonPackage): license("BSD-3-Clause") + version("6.29.4", sha256="3d44070060f9475ac2092b760123fadf105d2e2493c24848b6691a7c4f42af5c") + version("6.28.0", sha256="69c11403d26de69df02225916f916b37ea4b9af417da0a8c827f84328d88e5f3") + version("6.27.1", sha256="7d5d594b6690654b4d299edba5e872dc17bb7396a8d0609c97cb7b8a1c605de6") + version("6.26.0", sha256="553856658eb8430bbe9653ea041a41bff63e9606fc4628873fc92a6cf3abd404") + version("6.25.2", sha256="f468ddd1f17acb48c8ce67fcfa49ba6d46d4f9ac0438c1f441be7c3d1372230b") + version("6.24.0", sha256="29cea0a716b1176d002a61d0b0c851f34536495bc4ef7dd0222c88b41b816123") + version("6.23.3", sha256="dd4e18116357f36a1e459b3768412371bee764c51844cbf25c4ed1eb9cae4a54") version("6.23.1", sha256="1aba0ae8453e15e9bc6b24e497ef6840114afcdb832ae597f32137fa19d42a6f") version("6.22.0", sha256="302558b81f1bc22dc259fb2a0c5c7cf2f4c0bdb21b50484348f7bafe7fb71421") version("6.16.0", sha256="7fe42c0d58435e971dc15fd42189f20d66bf35f3056bda4f6554271bc1fa3d0d") @@ -70,6 +77,7 @@ class PyIpykernel(PythonPackage): depends_on("py-matplotlib-inline@0.1:", when="@6.11:", type=("build", "run")) depends_on("py-matplotlib-inline@0.1.0:0.1", when="@6:6.10", type=("build", "run")) depends_on("py-appnope", when="@5.1.3: platform=darwin", type=("build", "run")) + depends_on("py-pyzmq@24:", when="@6.28:", type=("build", "run")) depends_on("py-pyzmq@20:", when="@6.22:", type=("build", "run")) depends_on("py-pyzmq@17:", when="@6.15:", type=("build", "run")) depends_on("py-psutil", when="@6.9.2:", type=("build", "run")) @@ -89,4 +97,4 @@ class PyIpykernel(PythonPackage): @run_after("install") def install_data(self): """install the Jupyter kernel spec""" - self.spec["python"].command("-m", "ipykernel", "install", "--prefix=" + self.prefix) + python("-m", "ipykernel", "install", "--prefix=" + self.prefix) diff --git a/var/spack/repos/builtin/packages/py-ipython/package.py b/var/spack/repos/builtin/packages/py-ipython/package.py index d1f1044e7674a5..9e81bf2ba03550 100644 --- a/var/spack/repos/builtin/packages/py-ipython/package.py +++ b/var/spack/repos/builtin/packages/py-ipython/package.py @@ -22,6 +22,17 @@ class PyIpython(PythonPackage): license("BSD-3-Clause") + version("8.25.0", sha256="c6ed726a140b6e725b911528f80439c534fac915246af3efc39440a6b0f9d716") + version("8.24.0", sha256="010db3f8a728a578bb641fdd06c063b9fb8e96a9464c63aec6310fbcb5e80501") + version("8.23.0", sha256="7468edaf4f6de3e1b912e57f66c241e6fd3c7099f2ec2136e239e142e800274d") + version("8.22.2", sha256="2dcaad9049f9056f1fef63514f176c7d41f930daa78d05b82a176202818f2c14") + version("8.21.0", sha256="48fbc236fbe0e138b88773fa0437751f14c3645fb483f1d4c5dee58b37e5ce73") + version("8.20.0", sha256="2f21bd3fc1d51550c89ee3944ae04bbc7bc79e129ea0937da6e6c68bfdbf117a") + version("8.19.0", sha256="ac4da4ecf0042fb4e0ce57c60430c2db3c719fa8bdf92f8631d6bd8a5785d1f0") + version("8.18.1", sha256="ca6f079bb33457c66e233e4580ebfc4128855b4cf6370dddd73842a9563e8a27") + version("8.17.2", sha256="126bb57e1895594bb0d91ea3090bbd39384f6fe87c3d57fd558d0670f50339bb") + version("8.16.1", sha256="ad52f58fca8f9f848e256c629eff888efc0528c12fe0f8ec14f33205f23ef938") + version("8.15.0", sha256="2baeb5be6949eeebf532150f81746f8333e2ccce02de1c7eedde3f23ed5e9f1e") version("8.14.0", sha256="1d197b907b6ba441b692c48cf2a3a2de280dc0ac91a3405b39349a50272ca0a1") version("8.11.0", sha256="735cede4099dbc903ee540307b9171fbfef4aa75cfcacc5a273b2cda2f02be04") version("8.5.0", sha256="097bdf5cd87576fd066179c9f7f208004f7a6864ee1b20f37d346c0bcb099f84") @@ -38,25 +49,23 @@ class PyIpython(PythonPackage): version("5.1.0", sha256="7ef4694e1345913182126b219aaa4a0047e191af414256da6772cf249571b961") depends_on("python@3.9:", when="@8.13.1:", type=("build", "run")) - depends_on("python@3.8:", when="@8:", type=("build", "run")) + depends_on("python@3.8: +sqlite3", when="@8:", type=("build", "run")) + depends_on("py-setuptools@61.2:", when="@8.22:", type="build") depends_on("py-setuptools@51:", when="@8:", type="build") depends_on("py-setuptools@18.5:", when="@:7", type="run") depends_on("py-setuptools", type="build") - depends_on("py-appnope", when="platform=darwin", type=("build", "run")) - depends_on("py-backcall", when="@7.3.0:", type=("build", "run")) depends_on("py-colorama", when="platform=windows", type=("build", "run")) depends_on("py-decorator", type=("build", "run")) + depends_on("py-exceptiongroup", when="@8.15: ^python@:3.10", type=("build", "run")) depends_on("py-jedi@0.16:", when="@7.18,7.20:", type=("build", "run")) depends_on("py-jedi@0.10:", when="@7.5:7.17,7.19", type=("build", "run")) depends_on("py-matplotlib-inline", when="@7.23:", type=("build", "run")) depends_on("py-pexpect@4.4:", when="@7.18: platform=linux", type=("build", "run")) depends_on("py-pexpect@4.4:", when="@7.18: platform=darwin", type=("build", "run")) - depends_on("py-pexpect@4.4:", when="@7.18: platform=cray", type=("build", "run")) depends_on("py-pexpect", when="platform=linux", type=("build", "run")) depends_on("py-pexpect", when="platform=darwin", type=("build", "run")) - depends_on("py-pexpect", when="platform=cray", type=("build", "run")) - depends_on("py-pickleshare", type=("build", "run")) + depends_on("py-prompt-toolkit@3.0.41:3.0", when="@8.18.1:", type=("build", "run")) depends_on("py-prompt-toolkit@3.0.30:3.0.36,3.0.38:3.0", when="@8.11:", type=("build", "run")) depends_on("py-prompt-toolkit@3.0.2:3.0", when="@8.5:", type=("build", "run")) depends_on("py-prompt-toolkit@2.0.0:2,3.0.2:3.0", when="@7.26:", type=("build", "run")) @@ -68,11 +77,17 @@ class PyIpython(PythonPackage): depends_on("py-pygments@2.4:", when="@8.1:", type=("build", "run")) depends_on("py-pygments", type=("build", "run")) depends_on("py-stack-data", when="@8:", type=("build", "run")) + depends_on("py-traitlets@5.13:", when="@8.22.1:", type=("build", "run")) depends_on("py-traitlets@5:", when="@8:", type=("build", "run")) depends_on("py-traitlets@4.2:", type=("build", "run")) depends_on("py-traitlets", type=("build", "run")) + depends_on("py-typing-extensions@4.6:", when="@8.24: ^python@:3.11", type=("build", "run")) + depends_on("py-typing-extensions", when="@8.23: ^python@:3.11", type=("build", "run")) depends_on("py-typing-extensions", when="@8.12: ^python@:3.9", type=("build", "run")) # Historical dependencies + depends_on("py-appnope", when="@:8.17 platform=darwin", type=("build", "run")) + depends_on("py-backcall", when="@7.3.0:8.16", type=("build", "run")) depends_on("py-black", when="@8.0", type=("build", "run")) + depends_on("py-pickleshare", when="@:8.16", type=("build", "run")) depends_on("py-simplegeneric@0.8:", when="@:7.0.0", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-isal/package.py b/var/spack/repos/builtin/packages/py-isal/package.py index 1a8bbcb444f7b0..0d8ecf16595c25 100644 --- a/var/spack/repos/builtin/packages/py-isal/package.py +++ b/var/spack/repos/builtin/packages/py-isal/package.py @@ -19,6 +19,8 @@ class PyIsal(PythonPackage): version("1.1.0", sha256="1364f4e3255a57d51c01422ab3ae785a43c076d516ebf49f6a25adecf8232105") version("1.0.0", sha256="a30369de6852109eef8ca1bdd46d7e4b5c4517846a25acfc707cbb19db66ac80") + depends_on("c", type="build") # generated + depends_on("python@3.7:", type=("build", "run")) depends_on("py-setuptools@51:", type="build") depends_on("libisal") diff --git a/var/spack/repos/builtin/packages/py-itk/package.py b/var/spack/repos/builtin/packages/py-itk/package.py index b76245a204305d..92e89c09eb4697 100644 --- a/var/spack/repos/builtin/packages/py-itk/package.py +++ b/var/spack/repos/builtin/packages/py-itk/package.py @@ -15,13 +15,14 @@ class PyItk(PythonPackage): homepage = "https://itk.org/" + skip_version_audit = ["platform=windows"] + if sys.platform == "darwin": # version 5.1.1 version( "5.1.1-cp38", url="https://pypi.io/packages/cp35/i/itk/itk-5.1.1-cp38-cp38-macosx_10_9_x86_64.whl", sha256="94b09ab9dd59ceaecc456ede2b719a44b8f0d54d92409eede372c6004395ae7b", - expand=False, ) # version 5.1.2 @@ -29,13 +30,11 @@ class PyItk(PythonPackage): "5.1.2-cp38", url="https://pypi.io/packages/cp38/i/itk/itk-5.1.2-cp38-cp38-macosx_10_9_x86_64.whl", sha256="e8dec75b4452bd2ee65beb4901b245fc3a2a2ccc46dfa008ae0b5b757718d458", - expand=False, ) version( "5.1.2-cp39", url="https://pypi.io/packages/cp39/i/itk/itk-5.1.2-cp39-cp39-macosx_10_9_x86_64.whl", sha256="e8dec75b4452bd2ee65beb4901b245fc3a2a2ccc46dfa008ae0b5b757718d458", - expand=False, ) # version 5.3.0 @@ -43,25 +42,21 @@ class PyItk(PythonPackage): "5.3.0-cp38", url="https://pypi.io/packages/cp38/i/itk/itk-5.3.0-cp38-cp38-macosx_10_9_x86_64.whl", sha256="1fbcde6f6612b13d2934722707fd7194b1d5900a655efa191dfc130bbb94df09", - expand=False, ) version( "5.3.0-cp39", url="https://pypi.io/packages/cp39/i/itk/itk-5.3.0-cp39-cp39-macosx_10_9_x86_64.whl", sha256="155581581929dfe834af6c6233a8c83e2ca2b1f52d6c7b2c81f04dc249aab1a5", - expand=False, ) version( "5.3.0-cp310", url="https://pypi.io/packages/cp310/i/itk/itk-5.3.0-cp310-cp310-macosx_10_9_x86_64.whl", sha256="f92ec860173c82eb458764b4b5b771783b690c3aa3a01d15c6f3d008fc2bb493", - expand=False, ) version( "5.3.0-cp311", url="https://pypi.io/packages/cp311/i/itk/itk-5.3.0-cp311-cp311-macosx_10_9_x86_64.whl", sha256="9dcfd9721ff6022e91eb98dc4004d437de2912dfd50d707d1ee72b89c334a3d4", - expand=False, ) elif sys.platform.startswith("linux"): # version 5.1.1 @@ -69,7 +64,6 @@ class PyItk(PythonPackage): "5.1.1-cp38", url="https://pypi.io/packages/cp38/i/itk/itk-5.1.1-cp38-cp38-manylinux1_x86_64.whl", sha256="14cd6c3a25f0d69f45eda74b006eceeaf8e2b2fcbe7c343e49683edf97e0fb14", - expand=False, ) # version 5.1.2 @@ -77,13 +71,11 @@ class PyItk(PythonPackage): "5.1.2-cp38", url="https://pypi.io/packages/cp38/i/itk/itk-5.1.2-cp38-cp38-manylinux1_x86_64.whl", sha256="fe9225ac353116f4000c0a3440bf151200beb4a65deec5b2e626edda5b498f16", - expand=False, ) version( "5.1.2-cp39", url="https://pypi.io/packages/cp39/i/itk/itk-5.1.2-cp39-cp39-manylinux1_x86_64.whl", sha256="5781b74410b7189a825c89d370411595e5e3d5dbb480201907f751f26698df83", - expand=False, ) # version 5.3.0 @@ -91,25 +83,21 @@ class PyItk(PythonPackage): "5.3.0-cp38", url="https://pypi.io/packages/cp38/i/itk/itk-5.3.0-cp38-cp38-manylinux_2_28_x86_64.whl", sha256="d83dc2b0f5d673226ef6eacac012d1da6dd36c6126f2b3cffc7ed62231c29bf2", - expand=False, ) version( "5.3.0-cp39", url="https://pypi.io/packages/cp39/i/itk/itk-5.3.0-cp39-cp39-manylinux_2_28_x86_64.whl", sha256="bcc4449f2df35224cbc26472475d2afeb8a92886a81db950b2305f911bc2a38c", - expand=False, ) version( "5.3.0-cp310", url="https://pypi.io/packages/cp310/i/itk/itk-5.3.0-cp310-cp310-manylinux_2_28_x86_64.whl", sha256="272708ee5ed5d09a519b2e98ac9c130f3146630257506ea440c83501c16f9580", - expand=False, ) version( "5.3.0-cp311", url="https://pypi.io/packages/cp311/i/itk/itk-5.3.0-cp311-cp311-manylinux_2_28_x86_64.whl", sha256="ba8361a8ed1c5462e690ee893f624c0babb7a1072a15609c26790eea717e3f77", - expand=False, ) depends_on("python@3.8.0:3.8", when="@5.1.1-cp38,5.1.2-cp38,5.3.0-cp38", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-janus/package.py b/var/spack/repos/builtin/packages/py-janus/package.py new file mode 100644 index 00000000000000..62f2771111f2fe --- /dev/null +++ b/var/spack/repos/builtin/packages/py-janus/package.py @@ -0,0 +1,23 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class PyJanus(PythonPackage): + """Thread-safe asyncio-aware queue for Python""" + + homepage = "https://github.com/aio-libs/janus" + pypi = "janus/janus-1.0.0.tar.gz" + + maintainers("teaguesterling") + + license("APACHE-2.0", checked_by="teaguesterling") + + version("1.0.0", sha256="df976f2cdcfb034b147a2d51edfc34ff6bfb12d4e2643d3ad0e10de058cb1612") + version("0.7.0", sha256="f10dcf5776e8d49cc30ec86d5eb7268eeec39abaa24fe0332ee8fb8fa3611845") + + depends_on("python@3.7:", type=("build", "run")) + depends_on("py-setuptools@51:", type="build") + depends_on("py-wheel@0.36:", type="build") diff --git a/var/spack/repos/builtin/packages/py-jarowinkler/package.py b/var/spack/repos/builtin/packages/py-jarowinkler/package.py index 1ae633e44e139d..8974c1dc581a61 100644 --- a/var/spack/repos/builtin/packages/py-jarowinkler/package.py +++ b/var/spack/repos/builtin/packages/py-jarowinkler/package.py @@ -18,6 +18,8 @@ class PyJarowinkler(PythonPackage): version("1.2.3", sha256="af28ea284cfbd1b21b29ff94b759f20e94e4f7c06f424b0b4702e701c2a21668") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@42:", type="build") depends_on("py-scikit-build@0.15.0", type="build") depends_on("py-rapidfuzz-capi@1.0.5", type="build") diff --git a/var/spack/repos/builtin/packages/py-jax/package.py b/var/spack/repos/builtin/packages/py-jax/package.py index 1edf08895b8cee..e97c0966ba374e 100644 --- a/var/spack/repos/builtin/packages/py-jax/package.py +++ b/var/spack/repos/builtin/packages/py-jax/package.py @@ -19,67 +19,103 @@ class PyJax(PythonPackage): arbitrarily to any order.""" homepage = "https://github.com/google/jax" - pypi = "jax/jax-0.2.25.tar.gz" + pypi = "jax/jax-0.4.27.tar.gz" license("Apache-2.0") + maintainers("adamjstewart", "jonas-eschle") + version("0.4.30", sha256="94d74b5b2db0d80672b61d83f1f63ebf99d2ab7398ec12b2ca0c9d1e97afe577") + version("0.4.29", sha256="12904571eaefddcdc8c3b8d4936482b783d5a216e99ef5adcd3522fdfb4fc186") + version("0.4.28", sha256="dcf0a44aff2e1713f0a2b369281cd5b79d8c18fc1018905c4125897cb06b37e9") + version("0.4.27", sha256="f3d7f19bdc0a17ccdb305086099a5a90c704f904d4272a70debe06ae6552998c") + version("0.4.26", sha256="2cce025d0a279ec630d550524749bc8efe25d2ff47240d2a7d4cfbc5090c5383") version("0.4.25", sha256="a8ee189c782de2b7b2ffb64a8916da380b882a617e2769aa429b71d79747b982") + version("0.4.24", sha256="4a6b6fd026ddd22653c7fa2fac1904c3de2dbe845b61ede08af9a5cc709662ae") version("0.4.23", sha256="2a229a5a758d1b803891b2eaed329723f6b15b4258b14dc0ccb1498c84963685") + version("0.4.22", sha256="801434dda6e14f82a45fff753969a33281ab22fb2a50fe801b651390321057ba") + version("0.4.21", sha256="c97fd0d2751d6e1eb15aa2052ff7cfdc129f8fafc2c14cd779720658926a587b") + version("0.4.20", sha256="ea96a763a8b1a9374639d1159ab4de163461d01cd022f67c34c09581b71ed2ac") + version("0.4.19", sha256="29f87f9a50964d3ca5eeb2973de3462f0e8b4eca6d46027894a0e9a903420601") + version("0.4.18", sha256="776cf33890100803e98f45f9af10aa727271c6993d4e766c069118733c928132") + version("0.4.17", sha256="d7508a69e87835f534cb07a2f21d79cc1cb8c4cfdcf7fb010927267ef7355f1d") version("0.4.16", sha256="e2ca82c9bf973c2c1c01f5340a583692b31f277aa3abd0544229c1fe5fa44b02") + version("0.4.15", sha256="2aa123ccef591e355dea94a6e714b6559f8e1d6368a576a223f97d031ece0d15") + version("0.4.14", sha256="18fed3881f26e8b13c8cb46eeeea3dba9eb4d48e3714d8e8f2304dd6e237083d") + version("0.4.13", sha256="03bfe6749dfe647f16f15f6616638adae6c4a7ca7167c75c21961ecfd3a3baaa") + version("0.4.12", sha256="d2de9a2388ffe002f16506d3ad1cc6e34d7536b98948e49c7e05bbcfe8e57998") + version("0.4.11", sha256="8b1cd443b698339df8d8807578ee141e5b67e36125b3945b146f600177d60d79") + version("0.4.10", sha256="1bf0f2720f778f2937301a16a4d5cd3497f13a4d6c970c24a88918a81816a888") + version("0.4.9", sha256="1ed135cd08f48e4baf10f6eafdb4a4cdae781f9052b5838c09c91a9f4fa75f09") + version("0.4.8", sha256="08116481f7336db16c24812bfb5e6f9786915f4c2f6ff4028331fa69e7535202") + version("0.4.7", sha256="5e7002d74db25f97c99b979d4ba1233b1ef26e1597e5fc468ad11d1c8a9dc4f8") + version("0.4.6", sha256="d06ea8fba4ed315ec55110396058cb48c8edb2ab0b412f28c8a123beee9e58ab") + version("0.4.5", sha256="1633e56d34b18ddfa7d2a216ce214fa6fa712d36552532aaa71da416aede7268") + version("0.4.4", sha256="39b07e07343ed7c74492ee5e75db77456d3afdd038a322671f09fc748f6392cb") version("0.4.3", sha256="d43f08f940aa30eb339965cfb3d6bee2296537b0dc2f0c65ccae3009279529ae") - version( - "0.3.23", - sha256="bff436e15552a82c0ebdef32737043b799e1e10124423c57a6ae6118c3a7b6cd", - deprecated=True, - ) - version( - "0.2.25", - sha256="822e8d1e06257eaa0fdc4c0a0686c4556e9f33647fa2a766755f984786ae7446", - deprecated=True, - ) - depends_on("python@3.9:", when="@0.4.14:", type=("build", "run")) - depends_on("python@3.8:", when="@0.4:", type=("build", "run")) depends_on("py-setuptools", type="build") - depends_on("py-ml-dtypes@0.2:", when="@0.4.14:", type=("build", "run")) - depends_on("py-ml-dtypes@0.1:", when="@0.4.9:", type=("build", "run")) - depends_on("py-ml-dtypes@0.0.3:", when="@0.4.7:", type=("build", "run")) - depends_on("py-numpy@1.22:", when="@0.4.14:", type=("build", "run")) - depends_on("py-numpy@1.21:", when="@0.4.7:", type=("build", "run")) - depends_on("py-numpy@1.20:", when="@0.3:", type=("build", "run")) - depends_on("py-numpy@1.18:", type=("build", "run")) - depends_on("py-opt-einsum", type=("build", "run")) - depends_on("py-scipy@1.9:", when="@0.4.19:", type=("build", "run")) - depends_on("py-scipy@1.7:", when="@0.4.7:", type=("build", "run")) - depends_on("py-scipy@1.5:", when="@0.3:", type=("build", "run")) - depends_on("py-scipy@1.2.1:", type=("build", "run")) - depends_on("py-importlib-metadata@4.6:", when="@0.4.11: ^python@:3.9", type=("build", "run")) - # See jax/_src/lib/__init__.py - # https://github.com/google/jax/commit/8be057de1f50756fe7522f7e98b2f30fad56f7e4 - for v in ["0.4.25", "0.4.23", "0.4.16", "0.4.3", "0.3.23"]: - depends_on(f"py-jaxlib@:{v}", when=f"@{v}", type=("build", "run")) + with default_args(type=("build", "run")): + # setup.py + depends_on("python@3.9:", when="@0.4.14:") + depends_on("py-ml-dtypes@0.4:", when="@0.4.29") + depends_on("py-ml-dtypes@0.2:", when="@0.4.14:") + depends_on("py-ml-dtypes@0.1:", when="@0.4.9:") + depends_on("py-ml-dtypes@0.0.3:", when="@0.4.7:") + depends_on("py-numpy@1.22:", when="@0.4.14:") + depends_on("py-numpy@1.21:", when="@0.4.7:") + depends_on("py-numpy@1.20:", when="@0.3:") + # https://github.com/google/jax/issues/19246 + depends_on("py-numpy@:1", when="@:0.4.25") + depends_on("py-opt-einsum") + depends_on("py-scipy@1.9:", when="@0.4.19:") + depends_on("py-scipy@1.7:", when="@0.4.7:") + depends_on("py-scipy@1.5:", when="@0.3:") + depends_on("py-importlib-metadata@4.6:", when="@0.4.11: ^python@:3.9") - # See _minimum_jaxlib_version in jax/version.py - depends_on("py-jaxlib@0.4.20:", when="@0.4.25:", type=("build", "run")) - depends_on("py-jaxlib@0.4.19:", when="@0.4.21:", type=("build", "run")) - depends_on("py-jaxlib@0.4.14:", when="@0.4.15:", type=("build", "run")) - depends_on("py-jaxlib@0.4.11:", when="@0.4.12:", type=("build", "run")) - depends_on("py-jaxlib@0.4.7:", when="@0.4.8:", type=("build", "run")) - depends_on("py-jaxlib@0.4.6:", when="@0.4.7:", type=("build", "run")) - depends_on("py-jaxlib@0.4.4:", when="@0.4.5:", type=("build", "run")) - depends_on("py-jaxlib@0.4.2:", when="@0.4.3:", type=("build", "run")) - depends_on("py-jaxlib@0.4.1:", when="@0.4.2:", type=("build", "run")) - depends_on("py-jaxlib@0.3.22:", when="@0.3.24:", type=("build", "run")) - depends_on("py-jaxlib@0.3.15:", when="@0.3.18:", type=("build", "run")) - depends_on("py-jaxlib@0.3.14:", when="@0.3.15:", type=("build", "run")) - depends_on("py-jaxlib@0.3.7:", when="@0.3.8:", type=("build", "run")) - depends_on("py-jaxlib@0.3.2:", when="@0.3.7:", type=("build", "run")) - depends_on("py-jaxlib@0.3.0:", when="@0.3.2:", type=("build", "run")) - depends_on("py-jaxlib@0.1.74:", when="@0.2.26:", type=("build", "run")) - depends_on("py-jaxlib@0.1.69:", when="@0.2.18:", type=("build", "run")) + # jax/_src/lib/__init__.py + # https://github.com/google/jax/commit/8be057de1f50756fe7522f7e98b2f30fad56f7e4 + for v in [ + "0.4.30", + "0.4.29", + "0.4.28", + "0.4.27", + "0.4.26", + "0.4.25", + "0.4.24", + "0.4.23", + "0.4.22", + "0.4.21", + "0.4.20", + "0.4.19", + "0.4.18", + "0.4.17", + "0.4.16", + "0.4.15", + "0.4.14", + "0.4.13", + "0.4.12", + "0.4.11", + "0.4.10", + "0.4.9", + "0.4.8", + "0.4.7", + "0.4.6", + "0.4.5", + "0.4.4", + "0.4.3", + ]: + depends_on(f"py-jaxlib@:{v}", when=f"@{v}") - # Historical dependencies - depends_on("py-absl-py", when="@:0.3", type=("build", "run")) - depends_on("py-typing-extensions", when="@:0.3", type=("build", "run")) - depends_on("py-etils+epath", when="@0.3", type=("build", "run")) + # See _minimum_jaxlib_version in jax/version.py + depends_on("py-jaxlib@0.4.27:", when="@0.4.28:") + depends_on("py-jaxlib@0.4.23:", when="@0.4.27:") + depends_on("py-jaxlib@0.4.20:", when="@0.4.25:") + depends_on("py-jaxlib@0.4.19:", when="@0.4.21:") + depends_on("py-jaxlib@0.4.14:", when="@0.4.15:") + depends_on("py-jaxlib@0.4.11:", when="@0.4.12:") + depends_on("py-jaxlib@0.4.7:", when="@0.4.8:") + depends_on("py-jaxlib@0.4.6:", when="@0.4.7:") + depends_on("py-jaxlib@0.4.4:", when="@0.4.5:") + depends_on("py-jaxlib@0.4.2:", when="@0.4.3:") + depends_on("py-jaxlib@0.4.1:", when="@0.4.2:") diff --git a/var/spack/repos/builtin/packages/py-jaxlib/package.py b/var/spack/repos/builtin/packages/py-jaxlib/package.py index dedc39489bad18..aac511a8723ef6 100644 --- a/var/spack/repos/builtin/packages/py-jaxlib/package.py +++ b/var/spack/repos/builtin/packages/py-jaxlib/package.py @@ -12,67 +12,85 @@ class PyJaxlib(PythonPackage, CudaPackage): """XLA library for Jax""" homepage = "https://github.com/google/jax" - url = "https://github.com/google/jax/archive/refs/tags/jaxlib-v0.1.74.tar.gz" + url = "https://github.com/google/jax/archive/refs/tags/jaxlib-v0.4.27.tar.gz" tmp_path = "" buildtmp = "" license("Apache-2.0") + maintainers("adamjstewart", "jonas-eschle") + version("0.4.30", sha256="0ef9635c734d9bbb44fcc87df4f1c3ccce1cfcfd243572c80d36fcdf826fe1e6") + version("0.4.29", sha256="3a8005f4f62d35a5aad7e3dbd596890b47c81cc6e34fcfe3dcb93b3ca7cb1246") + version("0.4.28", sha256="4dd11577d4ba5a095fbc35258ddd4e4c020829ed6e6afd498c9e38ccbcdfe20b") + version("0.4.27", sha256="c2c82cd9ad3b395d5cbc0affa26a2938e52677a69ca8f0b9ef9922a52cac4f0c") + version("0.4.26", sha256="ddc14da1eaa34f23430d40ad9b9585088575cac439a2fa1c6833a247e1b221fd") version("0.4.25", sha256="fc1197c401924942eb14185a61688d0c476e3e81ff71f9dc95e620b57c06eec8") version("0.4.24", sha256="c4e6963c2c36f634a9a1765e476a1ed4e6c4a7954465ebf72e29f344c28ddc28") + version("0.4.23", sha256="e4c06d62ba54becffd91abc862627b8b11b79c5a77366af8843b819665b6d568") + version("0.4.21", sha256="8d57f66d00b9c0b824b1eff84adda5b765a412b3f316ef7c773632d1edbf9477") + version("0.4.20", sha256="058410d2bc12f7562c7b01e0c8cd587cb68059c12f78bc945055e5ddc445f5fd") + version("0.4.19", sha256="51242b217a1f82474e42d24f09ed5dedff951eeb4579c6e49e706d1adfd6949d") version("0.4.16", sha256="85c8bc050abe0a2cf62e8cfc7edb4904dd3807924b5714ec6277f291c576b5ca") + version("0.4.14", sha256="9f309476a8f6337717b059b8d10b5859b4134c30cf8f1220bb70379b5e2744a4") + version("0.4.11", sha256="bdfc45f33970beba5caf28d061668a4863f05994deea26791db50ea605fc2e36") + version("0.4.7", sha256="0578d5dd5035b5225cadb6a62ca5f93dd76b70292268502fc01a0fd9ca7001d0") + version("0.4.6", sha256="2c9bf8962815bc54ef524e33dc8eda9d165d379fe87e0df210f316adead27787") + version("0.4.4", sha256="881f402c7983b56b185e182d5315dd64c9f5320be96213d0415996ece1826806") version("0.4.3", sha256="2104735dc22be2b105e5517bd5bc6ae97f40e8e9e54928cac1585c6112a3d910") - version( - "0.3.22", - sha256="680a6f5265ba26d5515617a95ae47244005366f879a5c321782fde60f34e6d0d", - deprecated=True, - ) - version( - "0.1.74", - sha256="bbc78c7a4927012dcb1b7cd135c7521f782d7dad516a2401b56d3190f81afe35", - deprecated=True, - ) - variant("cuda", default=True, description="Build with CUDA") - - # build/build.py - depends_on("py-build", when="@0.4.14:", type="build") - - # jaxlib/setup.py - depends_on("python@3.9:", when="@0.4.14:", type=("build", "run")) - depends_on("python@3.8:", when="@0.4:", type=("build", "run")) - depends_on("py-setuptools", type="build") - depends_on("py-scipy@1.9:", when="@0.4.19:", type=("build", "run")) - depends_on("py-scipy@1.7:", when="@0.4.7:", type=("build", "run")) - depends_on("py-scipy@1.5:", type=("build", "run")) - depends_on("py-numpy@1.22:", when="@0.4.14:", type=("build", "run")) - depends_on("py-numpy@1.21:", when="@0.4.7:", type=("build", "run")) - depends_on("py-numpy@1.20:", when="@0.3:", type=("build", "run")) - depends_on("py-numpy@1.18:", type=("build", "run")) - depends_on("py-ml-dtypes@0.2:", when="@0.4.14:", type=("build", "run")) - depends_on("py-ml-dtypes@0.1:", when="@0.4.9:", type=("build", "run")) - depends_on("py-ml-dtypes@0.0.3:", when="@0.4.7:", type=("build", "run")) - - # .bazelversion - depends_on("bazel@6.1.2", when="@0.4.11:", type="build") - depends_on("bazel@5.1.1", when="@0.3.7:0.4.10", type="build") - depends_on("bazel@5.1.0", when="@0.3.5", type="build") - depends_on("bazel@5.0.0", when="@0.3.0:0.3.2", type="build") - depends_on("bazel@4.2.1", when="@0.1.75:0.1.76", type="build") - depends_on("bazel@4.1.0", when="@0.1.70:0.1.74", type="build") - - # README.md - depends_on("cuda@11.4:", when="@0.4:+cuda") - depends_on("cuda@11.1:", when="@0.3+cuda") - # https://github.com/google/jax/issues/12614 - depends_on("cuda@11.1:11.7.0", when="@0.1+cuda") - depends_on("cudnn@8.2:", when="@0.4:+cuda") - depends_on("cudnn@8.0.5:", when="+cuda") - - # Historical dependencies - depends_on("py-absl-py", when="@:0.3", type=("build", "run")) - depends_on("py-flatbuffers@1.12:2", when="@0.1", type=("build", "run")) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant("cuda", default=True, description="Build with CUDA enabled") + variant("nccl", default=True, description="Build with NCCL enabled", when="+cuda") + + # docs/installation.md + with when("+cuda"): + depends_on("cuda@12.1:", when="@0.4.26:") + depends_on("cuda@11.8:", when="@0.4.11:") + depends_on("cuda@11.4:", when="@0.4.0:0.4.7") + depends_on("cudnn@9", when="@0.4.29:") + depends_on("cudnn@8.9:8", when="@0.4.26:0.4.28") + depends_on("cudnn@8.8:8", when="@0.4.11:0.4.25") + depends_on("cudnn@8.2:8", when="@0.4:0.4.7") + + with when("+nccl"): + depends_on("nccl@2.18:", when="@0.4.26:") + depends_on("nccl@2.16:", when="@0.4.18:") + depends_on("nccl") + + with default_args(type="build"): + # .bazelversion + depends_on("bazel@6.5.0", when="@0.4.28:") + depends_on("bazel@6.1.2", when="@0.4.11:0.4.27") + depends_on("bazel@5.1.1", when="@0.3.7:0.4.10") + + # jaxlib/setup.py + depends_on("py-setuptools") + + # build/build.py + depends_on("py-build", when="@0.4.14:") + + with default_args(type=("build", "run")): + # Based on PyPI wheels + depends_on("python@3.9:3.12", when="@0.4.17:") + depends_on("python@3.9:3.11", when="@0.4.14:0.4.16") + depends_on("python@3.8:3.11", when="@0.4.6:0.4.13") + + # jaxlib/setup.py + depends_on("py-scipy@1.9:", when="@0.4.19:") + depends_on("py-scipy@1.7:", when="@0.4.7:") + depends_on("py-scipy@1.5:") + depends_on("py-numpy@1.22:", when="@0.4.14:") + depends_on("py-numpy@1.21:", when="@0.4.7:") + depends_on("py-numpy@1.20:", when="@0.3:") + # https://github.com/google/jax/issues/19246 + depends_on("py-numpy@:1", when="@:0.4.25") + depends_on("py-ml-dtypes@0.4:", when="@0.4.29") + depends_on("py-ml-dtypes@0.2:", when="@0.4.14:") + depends_on("py-ml-dtypes@0.1:", when="@0.4.9:") + depends_on("py-ml-dtypes@0.0.3:", when="@0.4.7:") conflicts( "cuda_arch=none", @@ -82,7 +100,7 @@ class PyJaxlib(PythonPackage, CudaPackage): ) # https://github.com/google/jax/issues/19992 - conflicts("@0.4.16:", when="target=ppc64le:") + conflicts("@0.4.4:", when="target=ppc64le:") def patch(self): self.tmp_path = tempfile.mkdtemp(prefix="spack") diff --git a/var/spack/repos/builtin/packages/py-jcb/package.py b/var/spack/repos/builtin/packages/py-jcb/package.py new file mode 100644 index 00000000000000..a13c134b3c57ce --- /dev/null +++ b/var/spack/repos/builtin/packages/py-jcb/package.py @@ -0,0 +1,39 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyJcb(PythonPackage): + """ + JEDI Configuration Builder + """ + + homepage = "https://github.com/NOAA-EMC/jcb" + git = "https://github.com/NOAA-EMC/jcb" + + maintainers("danholdaway", "CoryMartin-NOAA", "AlexanderRichert-NOAA") + + license("GPL-3.0-only", checked_by="AlexanderRichert-NOAA") + + version("develop", branch="develop", commit="16399323e36df6f17bfd4740a2330ca7fae31537") + + depends_on("python@3.6:", type=("build", "run")) + depends_on("py-setuptools", type="build") + + depends_on("py-pyyaml@6:", type=("build", "run")) + depends_on("py-jinja2@3.1.2:", type=("build", "run")) + depends_on("py-click@8:", type=("build", "run")) + + depends_on("py-pytest@7:", type="test") + + @run_after("install") + @on_package_attributes(run_tests=True) + def check(self): + env["PYTHONPATH"] = ":".join( + (join_path(self.build_directory, "build/lib"), env["PYTHONPATH"]) + ) + pytest = which(join_path(self.spec["py-pytest"].prefix.bin, "pytest")) + pytest("-v", self.build_directory) diff --git a/var/spack/repos/builtin/packages/py-jedi/package.py b/var/spack/repos/builtin/packages/py-jedi/package.py index 4ac1c9574c4824..7074588beef056 100644 --- a/var/spack/repos/builtin/packages/py-jedi/package.py +++ b/var/spack/repos/builtin/packages/py-jedi/package.py @@ -39,6 +39,8 @@ class PyJedi(PythonPackage): ) version("0.9.0", sha256="3b4c19fba31bdead9ab7350fb9fa7c914c59b0a807dcdd5c00a05feb85491d31") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type=("build", "run")) depends_on("py-parso@0.8", when="@0.18.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-jellyfish/package.py b/var/spack/repos/builtin/packages/py-jellyfish/package.py index d0ccd6ba3958a6..85e916c21f4274 100644 --- a/var/spack/repos/builtin/packages/py-jellyfish/package.py +++ b/var/spack/repos/builtin/packages/py-jellyfish/package.py @@ -17,4 +17,6 @@ class PyJellyfish(PythonPackage): version("0.6.1", sha256="5104e45a2b804b48a46a92a5e6d6e86830fe60ae83b1da32c867402c8f4c2094") version("0.5.6", sha256="887a9a49d0caee913a883c3e7eb185f6260ebe2137562365be422d1316bd39c9") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-jproperties/package.py b/var/spack/repos/builtin/packages/py-jproperties/package.py new file mode 100644 index 00000000000000..df024a6ed604f1 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-jproperties/package.py @@ -0,0 +1,31 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class PyJproperties(PythonPackage): + """Java Property file parser and writer for Python""" + + homepage = "https://github.com/Tblue/python-jproperties" + pypi = "jproperties/jproperties-2.1.1.tar.gz" + + maintainers("teaguesterling") + + license("BSD", checked_by="teaguesterling") + + version("2.1.1", sha256="40b71124e8d257e8954899a91cd2d5c0f72e0f67f1b72048a5ba264567604f29") + version("2.1.0", sha256="504d7b8d3b2f5f0f52c22c1f72bd50576dca17b01b4cd00d4359c6b0607a59ce") + version("2.0.0", sha256="b6709652f5c602e5271f519cf14cb9bf5d5a101df06e6c1d300123477a239588") + version("1.0.1", sha256="327e14082653a4f2212ff81a96fbf141382f727f421e8afc933bf56ff7c010f4") + + depends_on("py-setuptools", type="build") + with default_args(type=("build", "run")): + depends_on("python@2.7,3:") + depends_on("py-six@1.10:1", when="@2.0.0") + depends_on("py-six@1.12:1", when="@2.1.0") + depends_on("py-six@1.13:1", when="@2.1.1") + depends_on("py-setuptools-scm@3.3:3", when="@2.1.1") diff --git a/var/spack/repos/builtin/packages/py-jpype1/package.py b/var/spack/repos/builtin/packages/py-jpype1/package.py index 8c2f32f41a9bb3..aa12e7c9dec065 100644 --- a/var/spack/repos/builtin/packages/py-jpype1/package.py +++ b/var/spack/repos/builtin/packages/py-jpype1/package.py @@ -18,6 +18,9 @@ class PyJpype1(PythonPackage): version("0.6.1", sha256="0d366228b7b37b0266184161cc7ea1ce58f60199f6ec9451985149ea873774be") version("0.6.0", sha256="f5d783520cb4c30595c3bc509065e30fc292ec7cfb57045141eae77c518bcdb0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("numpy", default=False, description="Build numpy extensions") depends_on("python@2.6:") diff --git a/var/spack/repos/builtin/packages/py-jsonargparse/package.py b/var/spack/repos/builtin/packages/py-jsonargparse/package.py index 8652b382c8cf87..f71830fd3f0e8f 100644 --- a/var/spack/repos/builtin/packages/py-jsonargparse/package.py +++ b/var/spack/repos/builtin/packages/py-jsonargparse/package.py @@ -17,6 +17,7 @@ class PyJsonargparse(PythonPackage): license("MIT") + version("4.28.0", sha256="ac835a290ef18cc2a5309e6bfa8ada9c5d63f46ff18701583fc8f3e95314679c") version("4.27.5", sha256="88ad908387ea5c8285a48e7d94bfd025e6f536b0dbae616d755d701248ab85d9") version("4.25.0", sha256="4eaadae69c387a3d83a76b1eaf20ca98d5274d8637f180dca0754ce5405adb6b") version("4.19.0", sha256="63aa3c7bbdb219d0f254a5ae86f3d54384ebc1ffa905e776cc19283bc843787b") diff --git a/var/spack/repos/builtin/packages/py-junit2html/package.py b/var/spack/repos/builtin/packages/py-junit2html/package.py new file mode 100644 index 00000000000000..d6965674b8f4f1 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-junit2html/package.py @@ -0,0 +1,23 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyJunit2html(PythonPackage): + """ + Simple self-contained python tool to produce a single html file from a single junit xml file. + """ + + homepage = "https://gitlab.com/inorton/junit2html" + + url = "https://gitlab.com/inorton/junit2html/-/archive/v31.0.2/junit2html-v31.0.2.tar.gz" + + maintainers("LydDeb") + + version("31.0.2", sha256="8d90ae83163dde6bf0bde9c3e8d21c0ab0796de7c5f33917cfdbb9d319212213") + + depends_on("py-setuptools", type=("build")) + depends_on("py-jinja2@3.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-jupyterlab-pygments/package.py b/var/spack/repos/builtin/packages/py-jupyterlab-pygments/package.py index a0b96f0c5cbf8c..22905b7252b80e 100644 --- a/var/spack/repos/builtin/packages/py-jupyterlab-pygments/package.py +++ b/var/spack/repos/builtin/packages/py-jupyterlab-pygments/package.py @@ -18,21 +18,9 @@ class PyJupyterlabPygments(PythonPackage): # -> py-jupyter-server -> py-nbconvert # Reported here: https://github.com/jupyterlab/jupyterlab_pygments/issues/23 - version( - "0.2.2", - sha256="2405800db07c9f770863bcf8049a529c3dd4d3e28536638bd7c1c01d2748309f", - expand=False, - ) - version( - "0.1.2", - sha256="abfb880fd1561987efaefcb2d2ac75145d2a5d0139b1876d5be806e32f630008", - expand=False, - ) - version( - "0.1.1", - sha256="c9535e5999f29bff90bd0fa423717dcaf247b71fad505d66b17d3217e9021fc5", - expand=False, - ) + version("0.2.2", sha256="2405800db07c9f770863bcf8049a529c3dd4d3e28536638bd7c1c01d2748309f") + version("0.1.2", sha256="abfb880fd1561987efaefcb2d2ac75145d2a5d0139b1876d5be806e32f630008") + version("0.1.1", sha256="c9535e5999f29bff90bd0fa423717dcaf247b71fad505d66b17d3217e9021fc5") depends_on("python@3.7:", when="@0.2.2:", type=("build", "run")) depends_on("py-pygments@2.4.1:2", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-jupyterlab-widgets/package.py b/var/spack/repos/builtin/packages/py-jupyterlab-widgets/package.py index 5aada203f6e55f..9de987a0f7e0cf 100644 --- a/var/spack/repos/builtin/packages/py-jupyterlab-widgets/package.py +++ b/var/spack/repos/builtin/packages/py-jupyterlab-widgets/package.py @@ -16,21 +16,9 @@ class PyJupyterlabWidgets(PythonPackage): license("BSD-3-Clause") - version( - "3.0.3", - sha256="6aa1bc0045470d54d76b9c0b7609a8f8f0087573bae25700a370c11f82cb38c8", - expand=False, - ) - version( - "1.1.0", - sha256="c2a9bd3789f120f64d73268c066ed3b000c56bc1dda217be5cdc43e7b4ebad3f", - expand=False, - ) - version( - "1.0.2", - sha256="f5d9efface8ec62941173ba1cffb2edd0ecddc801c11ae2931e30b50492eb8f7", - expand=False, - ) + version("3.0.3", sha256="6aa1bc0045470d54d76b9c0b7609a8f8f0087573bae25700a370c11f82cb38c8") + version("1.1.0", sha256="c2a9bd3789f120f64d73268c066ed3b000c56bc1dda217be5cdc43e7b4ebad3f") + version("1.0.2", sha256="f5d9efface8ec62941173ba1cffb2edd0ecddc801c11ae2931e30b50492eb8f7") depends_on("python@3.6:", type=("build", "run")) depends_on("python@3.7:", when="@3.0.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-jupytext/package.py b/var/spack/repos/builtin/packages/py-jupytext/package.py index 742310fd4ec782..b7556f3648f9a2 100644 --- a/var/spack/repos/builtin/packages/py-jupytext/package.py +++ b/var/spack/repos/builtin/packages/py-jupytext/package.py @@ -23,6 +23,8 @@ class PyJupytext(PythonPackage): version("1.13.6", sha256="c6c25918ddb6403d0d8504e08d35f6efc447baf0dbeb6a28b73adf39e866a0c4") version("1.13.0", sha256="fb220af65d2bd32d01c779b0e935c4c2b71e3f5f2f01bf1bab10d5f23fe121d4") + depends_on("cxx", type="build") # generated + depends_on("python@3.8:", type=("build", "run"), when="@1.16:") depends_on("python@3.6:3", type=("build", "run"), when="@:1.14") diff --git a/var/spack/repos/builtin/packages/py-kaleido/package.py b/var/spack/repos/builtin/packages/py-kaleido/package.py index b9d65bc80028bb..a58a207ddf51a4 100644 --- a/var/spack/repos/builtin/packages/py-kaleido/package.py +++ b/var/spack/repos/builtin/packages/py-kaleido/package.py @@ -3,19 +3,72 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import platform +import sys + from spack.package import * +arch, os = platform.machine(), sys.platform +arch64_32, _ = platform.architecture() + class PyKaleido(PythonPackage): """Static image export for web-based visualization libraries with zero dependencies""" - homepage = "https://github.com/wdecoster/nanostat" - url = "https://github.com/plotly/Kaleido/archive/refs/tags/v0.2.1.tar.gz" + homepage = "https://github.com/plotly/Kaleido" + pypi = "kaleido/kaleido-0.2.1-py2.py3-none-manylinux1_x86_64.whl" maintainers("Pandapip1") - version("0.2.1", sha256="fdb673a9759835d4f455990fc1ff8919bd100a0d34f2d3de7bd5eeb2162b57ec") + if (arch == "x86_64" or arch == "x64") and os == "linux": # Linux on x86_64 + version( + "0.2.1", + sha256="aa21cf1bf1c78f8fa50a9f7d45e1003c387bd3d6fe0a767cfbbf344b95bdc3a8", + url="https://files.pythonhosted.org/packages/ae/b3/a0f0f4faac229b0011d8c4a7ee6da7c2dca0b6fd08039c95920846f23ca4/kaleido-0.2.1-py2.py3-none-manylinux1_x86_64.whl", + expand=False, + ) + elif arch == "arm7l" and os == "linux": # Linux on ARMv7 + version( + "0.2.1.post1", + sha256="d313940896c24447fc12c74f60d46ea826195fc991f58569a6e73864d53e5c20", + url="https://files.pythonhosted.org/packages/86/4b/d668e288b694661d2fbfc2b972db69cf1f30f8b8a91be14dcf9f000cab16/kaleido-0.2.1.post1-py2.py3-none-manylinux2014_armv7l.whl", + expand=False, + ) + elif arch == "aarch64" and os == "linux": # Linux on 64-bit ARM + version( + "0.2.1", + sha256="845819844c8082c9469d9c17e42621fbf85c2b237ef8a86ec8a8527f98b6512a", + url="https://files.pythonhosted.org/packages/a1/2b/680662678a57afab1685f0c431c2aba7783ce4344f06ec162074d485d469/kaleido-0.2.1-py2.py3-none-manylinux2014_aarch64.whl", + expand=False, + ) + elif (arch == "x86_64" or arch == "x64") and os == "darwin": # MacOS on x86_64 + version( + "0.2.1", + sha256="ca6f73e7ff00aaebf2843f73f1d3bacde1930ef5041093fe76b83a15785049a7", + url="https://files.pythonhosted.org/packages/e0/f7/0ccaa596ec341963adbb4f839774c36d5659e75a0812d946732b927d480e/kaleido-0.2.1-py2.py3-none-macosx_10_11_x86_64.whl", + expand=False, + ) + elif not (arch == "x86_64" or arch == "x64") and os == "darwin": # MacOS on Apple Silicon + version( + "0.2.1", + sha256="bb9a5d1f710357d5d432ee240ef6658a6d124c3e610935817b4b42da9c787c05", + url="https://files.pythonhosted.org/packages/45/8e/4297556be5a07b713bb42dde0f748354de9a6918dee251c0e6bdcda341e7/kaleido-0.2.1-py2.py3-none-macosx_11_0_arm64.whl", + expand=False, + ) + elif arch64_32 == "64bit" and os == "win32": # 64-bit windows + version( + "0.2.1", + sha256="4670985f28913c2d063c5734d125ecc28e40810141bdb0a46f15b76c1d45f23c", + url="https://files.pythonhosted.org/packages/f7/9a/0408b02a4bcb3cf8b338a2b074ac7d1b2099e2b092b42473def22f7b625f/kaleido-0.2.1-py2.py3-none-win_amd64.whl", + expand=False, + ) + elif arch64_32 == "32bit" and os == "win32": # 32-bit windows + version( + "0.2.1", + sha256="ecc72635860be616c6b7161807a65c0dbd9b90c6437ac96965831e2e24066552", + url="https://files.pythonhosted.org/packages/88/89/4b6f8bb3f9ab036fd4ad1cb2d628ab5c81db32ac9aa0641d7b180073ba43/kaleido-0.2.1-py2.py3-none-win32.whl", + expand=False, + ) + depends_on("python", type=("build", "run")) depends_on("py-setuptools", type="build") - - build_directory = join_path("repos", "kaleido", "py") diff --git a/var/spack/repos/builtin/packages/py-keras/package.py b/var/spack/repos/builtin/packages/py-keras/package.py index bb13e3a3dc9cab..e2456f9e66a4db 100644 --- a/var/spack/repos/builtin/packages/py-keras/package.py +++ b/var/spack/repos/builtin/packages/py-keras/package.py @@ -22,6 +22,15 @@ class PyKeras(PythonPackage): maintainers("adamjstewart") license("Apache-2.0") + version("3.4.1", sha256="34cd9aeaa008914715149234c215657ca758e1b473bd2aab2e211ac967d1f8fe") + version("3.4.0", sha256="c4b05b150b1c4df27b4a17efd137b2d5e20f385f146fd48636791d675e75059d") + version("3.3.3", sha256="f2fdffc8434fd77045cf8fb21816dbaa2308d5f76974ca924b2f60b40433b1a0") + version("3.3.2", sha256="e7e2ccba2dfe2cf10b82e3c75ea971b82a4c62560dc562c43b33f7790127c92f") + version("3.3.1", sha256="03531beb01b108b867683762ceaacd0f28efc40cb92eee3c8c988b80cf718bbe") + version("3.3.0", sha256="46763bd84696aa5e326734ee0ccfde12bef73b27f1e5e241bbf539cb6411e78d") + version("3.2.1", sha256="966abbf0dfc1f9725f6293fb2a04ec83f56cd2a800990b38d1a03041255214a7") + version("3.2.0", sha256="e3ff572c872ebb24d2ae62d4e12c3579ccd0019d0f0adaf3cb7dc610e77e84c1") + version("3.1.1", sha256="55558ea228dc38e7667874fd2e83eaf7faeb026e2e8615b36a8616830f7e303b") version("3.1.0", sha256="cac46e053f0493da313e7c9b16379a532b1a38f9f19c7a5fe4578759f4c6aa4d") version("3.0.5", sha256="df3d3795e12c3f6035e811c43c13f1eb41e37241796a0fea120ede4ebe1c4496") version("3.0.4", sha256="ff2204792582e3889c51c77722cc6e8258dbb1ece7db192f5a9bcd1887cf3385") @@ -61,60 +70,64 @@ class PyKeras(PythonPackage): when="@3:", ) - # setup.py - depends_on("python@3.9:", type=("build", "run"), when="@3:") - depends_on("python@3.8:", type=("build", "run"), when="@2.12:") - depends_on("py-setuptools", type="build") - depends_on("py-absl-py", type=("build", "run"), when="@2.6:") - depends_on("py-numpy", type=("build", "run")) - depends_on("py-rich", type=("build", "run"), when="@3:") - depends_on("py-namex", type=("build", "run"), when="@3:") - depends_on("py-h5py", type=("build", "run")) - depends_on("py-dm-tree", type=("build", "run"), when="@3:") - depends_on("py-ml-dtypes", type=("build", "run"), when="@3.0.5:") - - # requirements-common.txt - depends_on("py-scipy", type=("build", "run")) - depends_on("py-pandas", type=("build", "run")) - depends_on("py-requests", type=("build", "run"), when="@3:") - depends_on("py-protobuf", type=("build", "run"), when="@3:") - - # requirements-tensorflow-cuda.txt - depends_on("py-tensorflow@2.16.1", type=("build", "run"), when="@3.0: backend=tensorflow") - - # requirements-jax-cuda.txt - depends_on("py-jax@0.4.23", type=("build", "run"), when="@3.0.5: backend=jax") - depends_on("py-jax", type=("build", "run"), when="@3: backend=jax") - - # requirements-torch-cuda.txt - depends_on("py-torch@2.2.1", type=("build", "run"), when="@3.1.0: backend=torch") - depends_on("py-torch@2.1.2", type=("build", "run"), when="@3.0.3:3.0.5 backend=torch") - depends_on("py-torch@2.1.1", type=("build", "run"), when="@3.0.1:3.0.2 backend=torch") - depends_on("py-torch@2.1.0", type=("build", "run"), when="@3.0.0 backend=torch") - depends_on("py-torchvision@0.17.1", type=("build", "run"), when="@3.1.0: backend=torch") - depends_on("py-torchvision@0.16.2", type=("build", "run"), when="@3.0.3:3.0.5 backend=torch") - depends_on("py-torchvision@0.16.1", type=("build", "run"), when="@3.0.1:3.0.2 backend=torch") - depends_on("py-torchvision@0.16.0", type=("build", "run"), when="@3.0.0 backend=torch") + with default_args(type="build"): + depends_on("py-setuptools") + + with default_args(type=("build", "run")): + # setup.py + depends_on("python@3.9:", when="@3:") + depends_on("python@3.8:", when="@2.12:") + depends_on("py-absl-py", when="@2.6:") + depends_on("py-numpy") + # https://github.com/keras-team/keras/issues/19691 + depends_on("py-numpy@:1") + depends_on("py-rich", when="@3:") + depends_on("py-namex@0.0.8:", when="@3.3.3:") + depends_on("py-namex", when="@3:") + depends_on("py-h5py") + depends_on("py-optree", when="@3.1:") + depends_on("py-ml-dtypes", when="@3.0.5:") + depends_on("py-packaging", when="@3.4:") + + # requirements-common.txt + depends_on("py-scipy") + depends_on("py-pandas") + depends_on("py-requests", when="@3:") + depends_on("py-protobuf", when="@3:") + + # requirements-tensorflow-cuda.txt + depends_on("py-tensorflow@2.16.1:2.16", when="@3.0: backend=tensorflow") + + # requirements-jax-cuda.txt + depends_on("py-jax@0.4.23", when="@3.0.5: backend=jax") + depends_on("py-jax", when="@3: backend=jax") + + # requirements-torch-cuda.txt + depends_on("py-torch@2.2.1", when="@3.1.0: backend=torch") + depends_on("py-torch@2.1.2", when="@3.0.3:3.0.5 backend=torch") + depends_on("py-torch@2.1.1", when="@3.0.1:3.0.2 backend=torch") + depends_on("py-torch@2.1.0", when="@3.0.0 backend=torch") + depends_on("py-torchvision@0.17.1", when="@3.1.0: backend=torch") + depends_on("py-torchvision@0.16.2", when="@3.0.3:3.0.5 backend=torch") + depends_on("py-torchvision@0.16.1", when="@3.0.1:3.0.2 backend=torch") + depends_on("py-torchvision@0.16.0", when="@3.0.0 backend=torch") # Historical dependencies - depends_on("bazel", type="build", when="@2.5:2") - depends_on("protobuf", type="build", when="@2.5:2") - depends_on("pil", type=("build", "run"), when="@:2") - depends_on("py-portpicker", type=("build", "run"), when="@2.10:2") - depends_on("py-pydot", type=("build", "run"), when="@:2") - depends_on("py-pyyaml", type=("build", "run"), when="@:2") - depends_on("py-six", type=("build", "run"), when="@:2") - for minor_ver in range(6, 16): - depends_on( - "py-tensorflow@2.{}".format(minor_ver), - type=("build", "run"), - when="@2.{}".format(minor_ver), - ) - depends_on( - "py-tensorboard@2.{}".format(minor_ver), - type=("build", "run"), - when="@2.{}".format(minor_ver), - ) + with default_args(type="build"): + depends_on("bazel", when="@2.5:2") + depends_on("protobuf", when="@2.5:2") + + with default_args(type=("build", "run")): + depends_on("pil", when="@:2") + depends_on("py-dm-tree", when="@3.0") + depends_on("py-portpicker", when="@2.10:2") + depends_on("py-pydot", when="@:2") + depends_on("py-pyyaml", when="@:2") + depends_on("py-six", when="@:2") + + for minor_ver in range(6, 16): + depends_on("py-tensorflow@2.{}".format(minor_ver), when="@2.{}".format(minor_ver)) + depends_on("py-tensorboard@2.{}".format(minor_ver), when="@2.{}".format(minor_ver)) def url_for_version(self, version): if version >= Version("3"): diff --git a/var/spack/repos/builtin/packages/py-kerberos/package.py b/var/spack/repos/builtin/packages/py-kerberos/package.py index f6f62be68179cc..537c969e06f72d 100644 --- a/var/spack/repos/builtin/packages/py-kerberos/package.py +++ b/var/spack/repos/builtin/packages/py-kerberos/package.py @@ -20,6 +20,8 @@ class PyKerberos(PythonPackage): version("1.3.0", sha256="f039b7dd4746df56f6102097b3dc250fe0078be75130b9dc4211a85a3b1ec6a4") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("keyutils", when="platform=linux") depends_on("krb5@1.3.0:") diff --git a/var/spack/repos/builtin/packages/py-kiwisolver/package.py b/var/spack/repos/builtin/packages/py-kiwisolver/package.py index 3447cf310f6f01..703af1eef1a868 100644 --- a/var/spack/repos/builtin/packages/py-kiwisolver/package.py +++ b/var/spack/repos/builtin/packages/py-kiwisolver/package.py @@ -21,6 +21,8 @@ class PyKiwisolver(PythonPackage): version("1.1.0", sha256="53eaed412477c836e1b9522c19858a8557d6e595077830146182225613b11a75") version("1.0.1", sha256="ce3be5d520b4d2c3e5eeb4cd2ef62b9b9ab8ac6b6fedbaa0e39cdb6f50644278") + depends_on("cxx", type="build") # generated + depends_on("python@2.7:2.8,3.4:", type=("build", "run")) depends_on("python@3.6:", type=("build", "run"), when="@1.2.0:") depends_on("python@3.7:", type=("build", "run"), when="@1.3.2:") diff --git a/var/spack/repos/builtin/packages/py-kneaddata/package.py b/var/spack/repos/builtin/packages/py-kneaddata/package.py new file mode 100644 index 00000000000000..6be478c15d4fc8 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-kneaddata/package.py @@ -0,0 +1,35 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyKneaddata(PythonPackage): + """ + Quality control tool on metagenomic and metatranscriptomic sequencing data, + especially data from microbiome experiments + """ + + homepage = "https://github.com/biobakery/kneaddata" + pypi = "kneaddata/kneaddata-0.12.0.tar.gz" + + version("0.12.0", sha256="b211bf973ea50cc89dd5935761ca3b101d422cfb62b215aae08f5ed92a624a58") + + maintainers("Pandapip1") + + depends_on("py-setuptools", type="build") + depends_on("trimmomatic@0.33", type=("build", "run")) + depends_on("bowtie2@2.2:", type=("build", "run")) + depends_on("python", type=("build", "run")) + depends_on("java", type=("build", "run")) + + variant("bam", default=True, description="Enable support for input files in BAM format") + depends_on("samtools", when="+bam", type=("build", "run")) + + variant("trf", default=True, description="Enable support for Tandem Repeats Finder") + depends_on("trf", when="+trf", type=("build", "run")) + + variant("fastqc", default=True, description="Enable support for FastQC") + depends_on("fastqc", when="+fastqc", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-kombu/package.py b/var/spack/repos/builtin/packages/py-kombu/package.py index f3ddf98eee708a..8ebb97fed35181 100644 --- a/var/spack/repos/builtin/packages/py-kombu/package.py +++ b/var/spack/repos/builtin/packages/py-kombu/package.py @@ -13,7 +13,17 @@ class PyKombu(PythonPackage): license("BSD-3-Clause") + version("5.3.5", sha256="30e470f1a6b49c70dc6f6d13c3e4cc4e178aa6c469ceb6bcd55645385fc84b93") + version("5.3.4", sha256="0bb2e278644d11dea6272c17974a3dbb9688a949f3bb60aeb5b791329c44fadc") + version("5.3.3", sha256="1491df826cfc5178c80f3e89dd6dfba68e484ef334db81070eb5cb8094b31167") + version("5.3.2", sha256="0ba213f630a2cb2772728aef56ac6883dc3a2f13435e10048f6e97d48506dbbd") + version("5.3.1", sha256="fbd7572d92c0bf71c112a6b45163153dea5a7b6a701ec16b568c27d0fd2370f2") + version("5.3.0", sha256="d084ec1f96f7a7c37ba9e816823bdbc08f0fc7ddb3a5be555805e692102297d8") + version("5.2.4", sha256="37cee3ee725f94ea8bb173eaab7c1760203ea53bbebae226328600f9d2799610") version("5.2.3", sha256="81a90c1de97e08d3db37dbf163eaaf667445e1068c98bfd89f051a40e9f6dbbd") + version("5.2.2", sha256="0f5d0763fb916808f617b886697b2be28e6bc35026f08e679697fc814b48a608") + version("5.2.1", sha256="f262a2adc71b53e5b7dad4933bbdee65d8766ca4df6a9043b13edaad2144aaec") + version("5.1.0", sha256="01481d99f4606f6939cdc9b637264ed353ee9e3e4f62cfb582324142c41a572d") version("5.0.2", sha256="f4965fba0a4718d47d470beeb5d6446e3357a62402b16c510b6a2f251e05ac3c") version("4.6.11", sha256="ca1b45faac8c0b18493d02a8571792f3c40291cf2bcf1f55afed3d8f3aa7ba74") version("4.6.6", sha256="1760b54b1d15a547c9a26d3598a1c8cdaf2436386ac1f5561934bc8a3cbbbd86") @@ -26,15 +36,19 @@ class PyKombu(PythonPackage): variant("redis", default=False, description="Use redis transport") depends_on("py-setuptools", type="build") - # "pytz>dev" in tests_require: setuptools parser changed in v60 and errors. - depends_on("py-setuptools@:59", when="@4.6:5.2", type="build") + depends_on("py-amqp@2.4", when="@4.3.0:4.5.0", type=("build", "run")) + depends_on("py-amqp@2.5.0", when="@4.6.0:4.6.3", type=("build", "run")) + depends_on("py-amqp@2.5.1", when="@4.6.4:4.6.5", type=("build", "run")) + depends_on("py-amqp@2.5.2:2.5.99", when="@4.6.6:4.6.8", type=("build", "run")) + depends_on("py-amqp@2.6.0:2.99", when="@4.6.9:5.0.1", type=("build", "run")) + depends_on("py-amqp@5.0.0:5.0.5", when="@5.0.2:5.0.99", type=("build", "run")) + depends_on("py-amqp@5.0.6:5.0.8", when="@5.1.0:5.2.2", type=("build", "run")) + depends_on("py-amqp@5.0.9:5.1.0", when="@5.2.3:5.2.4", type=("build", "run")) + depends_on("py-amqp@5.1.1:5.1.99", when="@5.3.0:5.3.5", type=("build", "run")) - depends_on("py-amqp@2.5.2:2.5", when="@:4.6.6", type=("build", "run")) - depends_on("py-amqp@2.6.0:2.6", when="@4.6.7:4", type=("build", "run")) - depends_on("py-amqp@5.0.0:5", when="@5.0.0:5.0.2", type=("build", "run")) - depends_on("py-amqp@5.0.9:5.0", when="@5.2.3", type=("build", "run")) depends_on("py-vine", when="@5.1.0:", type=("build", "run")) depends_on("py-importlib-metadata@0.18:", type=("build", "run"), when="^python@:3.7") depends_on("py-cached-property", type=("build", "run"), when="^python@:3.7") depends_on("py-redis@3.4.1:3,4.0.2:", when="+redis", type=("build", "run")) + depends_on("py-backports-zoneinfo@0.2.1:", when="^python@:3.8", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-kornia-rs/package.py b/var/spack/repos/builtin/packages/py-kornia-rs/package.py new file mode 100644 index 00000000000000..21f54eb79bb4c2 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-kornia-rs/package.py @@ -0,0 +1,43 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyKorniaRs(PythonPackage): + """Low level implementations for computer vision in Rust.""" + + homepage = "http://www.kornia.org/" + url = "https://github.com/kornia/kornia-rs/archive/refs/tags/v0.1.1.tar.gz" + + license("Apache-2.0") + maintainers( + "edgarriba", + "ducha-aiki", + "lferraz", + "shijianjian", + "cjpurackal", + "johnnv1", + "adamjstewart", + ) + + version("0.1.1", sha256="b9ac327fae6e982e6d7df9faeadd1d4f6453e65521819ae9ae5b90e9da0ed1a5") + version("0.1.0", sha256="0fca64f901dddff49b72e51fc92a25f0a7606e9a1a72ef283606245ea6b4f90d") + + build_directory = "py-kornia" + + depends_on("py-maturin@1.3.2:", type="build") + + # rav1e needs rustdoc + depends_on("rust+dev", type="build") + + # pyo3 needs cmake + depends_on("cmake", type="build") + + # turbojpeg-sys needs an assembly compiler + depends_on("nasm", type="build") + + # dlpack-rs needs libclang + depends_on("llvm+clang") diff --git a/var/spack/repos/builtin/packages/py-kornia/package.py b/var/spack/repos/builtin/packages/py-kornia/package.py index bb9c788f574631..4789984a2ecd78 100644 --- a/var/spack/repos/builtin/packages/py-kornia/package.py +++ b/var/spack/repos/builtin/packages/py-kornia/package.py @@ -9,11 +9,22 @@ class PyKornia(PythonPackage): """Open Source Differentiable Computer Vision Library for PyTorch.""" - homepage = "https://www.kornia.org/" + homepage = "http://www.kornia.org/" pypi = "kornia/kornia-0.5.10.tar.gz" license("Apache-2.0") - + maintainers( + "edgarriba", + "ducha-aiki", + "lferraz", + "shijianjian", + "cjpurackal", + "johnnv1", + "adamjstewart", + ) + + version("0.7.3", sha256="0eb861ea5d7e6c3891ae699a8b7103a5783af0a7c41888ca482420dd3d055306") + version("0.7.2", sha256="f834ccd51188d071ed286a6727471c94344ea2a718903cc6f0e56a92f9c66ac5") version("0.7.1", sha256="65b54a50f70c1f88240b557fda3fdcc1ab866982a5d062e52213130f5a48465c") version("0.7.0", sha256="72cba6a0965a15caf10a664647654412effb7c0b9afcf40e458bc005f976ffac") version("0.6.12", sha256="e30bd3d830226f7a159dff1f7757c6200e8f27d1333f06e9d2f98bdb33ce18d3") @@ -31,11 +42,11 @@ class PyKornia(PythonPackage): version("0.5.10", sha256="428b4b934a2ba7360cc6cba051ed8fd96c2d0f66611fdca0834e82845f14f65d") # pyproject.toml - depends_on("python@3.8:", when="@0.7:", type=("build", "run")) depends_on("py-setuptools@61.2:", when="@0.6.11:", type="build") depends_on("py-setuptools", type="build") # requirements/requirements.txt + depends_on("py-kornia-rs@0.1:", when="@0.7.2:", type=("build", "run")) depends_on("py-packaging", when="@0.6:", type=("build", "run")) depends_on("py-torch@1.9.1:", when="@0.6.9:", type=("build", "run")) depends_on("py-torch@1.8.1:", when="@0.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-langsmith/package.py b/var/spack/repos/builtin/packages/py-langsmith/package.py index 2066c16a4a22eb..c2f759c9a007de 100644 --- a/var/spack/repos/builtin/packages/py-langsmith/package.py +++ b/var/spack/repos/builtin/packages/py-langsmith/package.py @@ -13,6 +13,11 @@ class PyLangsmith(PythonPackage): license("MIT") + version( + "0.1.1", + sha256="09df0c2ca9085105f97a4e4f281b083e312c99d162f3fe2b2d5eefd5c3692e60", + expand=False, + ) version("0.0.11", sha256="7c1be28257d6c7279c85f81e6d8359d1006af3b1238fc198d13ca75c8fe421c8") version("0.0.10", sha256="11e5db0d8e29ee5583cabd872eeece8ce50738737b1f52f316ac984f4a1a58c5") version("0.0.7", sha256="2f18e51cfd4e42f2b3cf00fa87e9d03012eb7269cdafd8e7c0cf7aa828dcc03e") diff --git a/var/spack/repos/builtin/packages/py-lap/package.py b/var/spack/repos/builtin/packages/py-lap/package.py index 61202d4f97b734..b68ba7ef7247d3 100644 --- a/var/spack/repos/builtin/packages/py-lap/package.py +++ b/var/spack/repos/builtin/packages/py-lap/package.py @@ -18,6 +18,8 @@ class PyLap(PythonPackage): license("BSD-2-Clause") version("0.4.0", sha256="c4dad9976f0e9f276d8a676a6d03632c3cb7ab7c80142e3b27303d49f0ed0e3b") + + depends_on("cxx", type="build") # generated depends_on("py-setuptools", type="build") depends_on("py-cython@0.21:", type="build") depends_on("py-numpy@1.10.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-laspy/package.py b/var/spack/repos/builtin/packages/py-laspy/package.py index babd8bf528fd89..1e90f03aaa58cb 100644 --- a/var/spack/repos/builtin/packages/py-laspy/package.py +++ b/var/spack/repos/builtin/packages/py-laspy/package.py @@ -21,3 +21,5 @@ class PyLaspy(PythonPackage): depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) + # https://github.com/laspy/laspy/pull/313 + depends_on("py-numpy@:1", when="@:2.5.3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-lazy-loader/package.py b/var/spack/repos/builtin/packages/py-lazy-loader/package.py index 5cc4107ad390c2..641f95875b47d7 100644 --- a/var/spack/repos/builtin/packages/py-lazy-loader/package.py +++ b/var/spack/repos/builtin/packages/py-lazy-loader/package.py @@ -14,9 +14,13 @@ class PyLazyLoader(PythonPackage): license("BSD-3-Clause") + version("0.4", sha256="47c75182589b91a4e1a85a136c074285a5ad4d9f39c63e0d7fb76391c4574cd1") version("0.3", sha256="3b68898e34f5b2a29daaaac172c6555512d0f32074f147e2254e4a6d9d838f37") version("0.1", sha256="77ce7f2737ebabf9c0ff73b4a99c947876d74d24c2f026544e32246ecca5feca") - depends_on("python@3.7:") - depends_on("py-flit-core@3.8:3", when="@0.3:", type="build") + depends_on("py-setuptools@61.2:", when="@0.4:", type="build") + depends_on("py-packaging", when="@0.4:", type=("build", "run")) + + # Historical dependencies + depends_on("py-flit-core@3.8:3", when="@0.3", type="build") depends_on("py-flit-core@3.7:3", when="@0.1", type="build") diff --git a/var/spack/repos/builtin/packages/py-lazy-object-proxy/package.py b/var/spack/repos/builtin/packages/py-lazy-object-proxy/package.py index 89cbbfb72602d9..c8b247ad92a98a 100644 --- a/var/spack/repos/builtin/packages/py-lazy-object-proxy/package.py +++ b/var/spack/repos/builtin/packages/py-lazy-object-proxy/package.py @@ -20,6 +20,8 @@ class PyLazyObjectProxy(PythonPackage): version("1.4.3", sha256="f3900e8a5de27447acbf900b4750b0ddfd7ec1ea7fbaf11dfa911141bc522af0") version("1.3.1", sha256="eb91be369f945f10d3a49f5f9be8b3d0b93a4c2be8f8a5b83b0571b8123e0a7a") + depends_on("c", type="build") # generated + depends_on("python@2.7:2.8,3.4:", type=("build", "run")) depends_on("python@2.7:2.8,3.6:", type=("build", "run"), when="@1.6.0:") depends_on("python@3.6:", type=("build", "run"), when="@1.7.0:") diff --git a/var/spack/repos/builtin/packages/py-libensemble/package.py b/var/spack/repos/builtin/packages/py-libensemble/package.py index 75d17979ec2f53..2d5994001dc254 100644 --- a/var/spack/repos/builtin/packages/py-libensemble/package.py +++ b/var/spack/repos/builtin/packages/py-libensemble/package.py @@ -12,7 +12,7 @@ class PyLibensemble(PythonPackage): """Library for managing ensemble-like collections of computations.""" homepage = "https://libensemble.readthedocs.io" - pypi = "libensemble/libensemble-1.2.1.tar.gz" + pypi = "libensemble/libensemble-1.3.0.tar.gz" git = "https://github.com/Libensemble/libensemble.git" maintainers("shuds13", "jlnav") @@ -21,6 +21,8 @@ class PyLibensemble(PythonPackage): license("BSD-3-Clause") version("develop", branch="develop") + version("1.3.0", sha256="4a2f47de9ab57c577f3de5dd849ec1b621effde7206a54b2aa29aaf309c87532") + version("1.2.2", sha256="936e34ed4e8129a9980187b21d586472b6362403889a739595d6b631335a8678") version("1.2.1", sha256="b80e77548a1e2a71483352b3b00e22b47191e45ca5741324c2b0f20b05579a3d") version("1.2.0", sha256="e1076e8eea7844d3799f92d136586eca4da34ec753bf41a8d1be04d7a45ec4c1") version("1.1.0", sha256="3e3ddc4233272d3651e9d62c7bf420018930a4b9b135ef9ede01d5356235c1c6") @@ -46,6 +48,9 @@ class PyLibensemble(PythonPackage): version("0.2.0", sha256="ecac7275d4d0f4a5e497e5c9ef2cd998da82b2c020a0fb87546eeea262f495ff") version("0.1.0", sha256="0b27c59ae80f7af8b1bee92fcf2eb6c9a8fd3494bf2eb6b3ea17a7c03d3726bb") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Install with MPI") # Optional communications method # The following variants are for optional built-in generators @@ -98,7 +103,6 @@ def run_tutorial_script(self, script): if not os.path.isfile(exe): raise SkipTest(f"{script} is missing") - python = self.spec["python"].command python(exe, "--comms", "local", "--nworkers", "2") def test_uniform_sampling(self): diff --git a/var/spack/repos/builtin/packages/py-libsonata/package.py b/var/spack/repos/builtin/packages/py-libsonata/package.py new file mode 100644 index 00000000000000..36937e902d8ec8 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-libsonata/package.py @@ -0,0 +1,36 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyLibsonata(PythonPackage): + """SONATA files reader""" + + homepage = "https://github.com/BlueBrain/libsonata" + git = "https://github.com/BlueBrain/libsonata.git" + pypi = "libsonata/libsonata-0.1.14.tar.gz" + + maintainers("tristan0x") + + version("master", branch="master") + version("0.1.25", sha256="b332efa718123ee265263e1583a5998eaa945a13b8a22903873764cf1d8173fa") + + depends_on("cxx", type="build") # generated + + depends_on("catch2@2.13:", type="test") + depends_on("cmake@3.16:", type="build") + depends_on("fmt@7.1:") + depends_on("hdf5@1.14:") + depends_on("highfive@2.9:") + depends_on("nlohmann-json@3.9.1") + depends_on("py-pybind11@2.11.1:") + + depends_on("py-numpy@1.17.3:", type=("build", "run")) + depends_on("py-setuptools@42:", type="build", when="@0.1:") + depends_on("py-setuptools-scm@3.4:", type="build", when="@0.1:") + + def patch(self): + filter_file("-DEXTLIB_FROM_SUBMODULES=ON", "-DEXTLIB_FROM_SUBMODULES=OFF", "setup.py") diff --git a/var/spack/repos/builtin/packages/py-lightgbm/package.py b/var/spack/repos/builtin/packages/py-lightgbm/package.py index 0596e07ecc68b5..cb4a17d8ee5a0c 100644 --- a/var/spack/repos/builtin/packages/py-lightgbm/package.py +++ b/var/spack/repos/builtin/packages/py-lightgbm/package.py @@ -17,6 +17,8 @@ class PyLightgbm(PythonPackage): version("3.1.1", sha256="babece2e3613e97748a67ed45387bb0e984bdb1f4126e39f010fbfe7503c7b20") + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Build with mpi support") depends_on("py-setuptools", type="build") @@ -24,6 +26,9 @@ class PyLightgbm(PythonPackage): depends_on("py-pip@:23.0", when="+mpi", type="build") depends_on("py-wheel", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) + # https://github.com/microsoft/LightGBM/issues/6454 + # https://github.com/microsoft/LightGBM/pull/6439 + depends_on("py-numpy@:1", when="@:4.3", type=("build", "run")) depends_on("py-scipy", type=("build", "run")) depends_on("py-scikit-learn@:0.21,0.22.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-lightly/package.py b/var/spack/repos/builtin/packages/py-lightly/package.py index be9259fa78fd71..5a34d6cfa6b4d5 100644 --- a/var/spack/repos/builtin/packages/py-lightly/package.py +++ b/var/spack/repos/builtin/packages/py-lightly/package.py @@ -49,6 +49,8 @@ class PyLightly(PythonPackage): depends_on("py-hydra-core@1:", type=("build", "run")) depends_on("py-lightly-utils@0.0", type=("build", "run")) depends_on("py-numpy@1.18.1:", type=("build", "run")) + # https://github.com/lightly-ai/lightly/issues/1558 + depends_on("py-numpy@:1", type=("build", "run")) depends_on("py-python-dateutil@2.5.3:", type=("build", "run")) depends_on("py-requests@2.23:", type=("build", "run")) depends_on("py-six@1.10:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-lightning-api-access/package.py b/var/spack/repos/builtin/packages/py-lightning-api-access/package.py index a61f0f87a516ed..75c6533d7f7fa2 100644 --- a/var/spack/repos/builtin/packages/py-lightning-api-access/package.py +++ b/var/spack/repos/builtin/packages/py-lightning-api-access/package.py @@ -15,8 +15,4 @@ class PyLightningApiAccess(PythonPackage): url = "https://files.pythonhosted.org/packages/py3/l/lightning-api-access/lightning_api_access-0.0.5-py3-none-any.whl" list_url = "https://pypi.org/simple/lightning-api-access/" - version( - "0.0.5", - sha256="08657fee636377534332df92e0bee893d46cb877f9642cba09ce560aed95fd40", - expand=False, - ) + version("0.0.5", sha256="08657fee636377534332df92e0bee893d46cb877f9642cba09ce560aed95fd40") diff --git a/var/spack/repos/builtin/packages/py-lightning/package.py b/var/spack/repos/builtin/packages/py-lightning/package.py index dfaba9298a6d78..791ab781b6b06f 100644 --- a/var/spack/repos/builtin/packages/py-lightning/package.py +++ b/var/spack/repos/builtin/packages/py-lightning/package.py @@ -17,6 +17,11 @@ class PyLightning(PythonPackage): license("Apache-2.0") + version("2.3.0", sha256="4bb4d6e3650d2d5f544ad60853a22efc4e164aa71b9596d13f0454b29df05130") + version("2.2.5", sha256="a6c31a2052fc30fee34aec7e31ea2a117a005d049c3593fc9cfb867a34f962bf") + version("2.2.4", sha256="4cc3fb3edf04fcd63c0ecf75087d2fa06163759fc8c1fc500b16404ac1854f77") + version("2.2.3", sha256="9f208d57ad9c1ae40918136dbef673f02d8e9ab519d33237a6e74984bcd73d96") + version("2.2.2", sha256="799e933bf51f3f10516b3f1acf3650e4bc063682eb5b5dc9dcbd1ebd38e03e3a") version("2.2.1", sha256="b3e46d596b32cafd1fb9b21fdba1b1767df97b1af5cc702693d1c51df60b19aa") version("2.2.0", sha256="acf47bebc924f443f90a860b84a3f5566933a930adde42e3021abb5cf466c45f") version("2.1.4", sha256="0e45098c700fa28c604a11ae233ce181b44aeffce2404debebc2616118431d9f") @@ -34,77 +39,88 @@ class PyLightning(PythonPackage): version("2.0.2", sha256="fa32d671850a5be2d961c6705c927f6f48d1cf9696f61f7d865244142e684430") version("2.0.1", sha256="abf4f9e10b0d97348336038db79f4efc75daa2f3f81876822273023294d6ef3e") version("2.0.0", sha256="dfe158aa91ac139d8bdfccc7cdb627072e0052076ae9c0459c8fa12a028dbe6c") - version("1.9.5", sha256="4a6ee1bf338f7677f04d339b84dd0c9c0fa407c3dacea366a111dc86476d4dec") + version( + "1.9.5", + sha256="4a6ee1bf338f7677f04d339b84dd0c9c0fa407c3dacea366a111dc86476d4dec", + deprecated=True, + ) - # src/lightning/__setup__.py - depends_on("python@3.8:", when="@2:", type=("build", "run")) depends_on("py-setuptools", type="build") - # src/lightning.egg-info/requires.txt - depends_on("py-pyyaml@5.4:7", type=("build", "run")) - depends_on("py-fsspec@2022.5:2024+http", when="@2.1.3:", type=("build", "run")) - depends_on("py-fsspec@2021.6.1:2024+http", when="@2.1.0:2.1.2", type=("build", "run")) - depends_on("py-fsspec@2022.5:2024+http", when="@2.0.5:2.0", type=("build", "run")) - depends_on("py-fsspec@2022.5:2023+http", when="@:2.0.4", type=("build", "run")) - depends_on("py-lightning-utilities@0.8:1", when="@2.1:", type=("build", "run")) - depends_on("py-lightning-utilities@0.7:1", when="@2.0", type=("build", "run")) - depends_on("py-lightning-utilities@0.6.0.post0:1", when="@:1", type=("build", "run")) - depends_on("py-numpy@1.17.2:2", type=("build", "run")) - depends_on("py-packaging@20:24", when="@2.1:", type=("build", "run")) - depends_on("py-packaging@17.1:24", when="@:2.0", type=("build", "run")) - depends_on("py-torch@1.13:3", when="@2.2:", type=("build", "run")) - depends_on("py-torch@1.12:3", when="@2.1", type=("build", "run")) - depends_on("py-torch@1.11:3", when="@2.0", type=("build", "run")) - depends_on("py-torch@1.10:3", when="@:1", type=("build", "run")) - depends_on("py-torchmetrics@0.7:2", when="@2.0.9:", type=("build", "run")) - depends_on("py-torchmetrics@0.7:1", when="@:2.0.8", type=("build", "run")) - depends_on("py-tqdm@4.57:5", type=("build", "run")) - depends_on("py-typing-extensions@4.4:5", when="@2.2:", type=("build", "run")) - depends_on("py-typing-extensions@4:5", type=("build", "run")) + with default_args(type=("build", "run")): + # src/lightning/__setup__.py + depends_on("python@3.8:", when="@2:") - # Only an alias, not actually used by the library - # depends_on("py-pytorch-lightning", when="@2:", type=("build", "run")) + # src/lightning.egg-info/requires.txt + depends_on("py-pyyaml@5.4:7") + depends_on("py-fsspec@2022.5:2025+http", when="@2.3:") + depends_on("py-fsspec@2022.5:2024+http", when="@2.1.3:2.2") + depends_on("py-fsspec@2021.6.1:2024+http", when="@2.1.0:2.1.2") + depends_on("py-fsspec@2022.5:2024+http", when="@2.0.5:2.0") + depends_on("py-fsspec@2022.5:2023+http", when="@:2.0.4") + depends_on("py-lightning-utilities@0.8:1", when="@2.1:") + depends_on("py-lightning-utilities@0.7:1", when="@2.0") + depends_on("py-lightning-utilities@0.6.0.post0:1", when="@:1") + depends_on("py-numpy@1.17.2:2") + depends_on("py-packaging@20:24", when="@2.1:") + depends_on("py-packaging@17.1:24", when="@:2.0") + depends_on("py-torch@2:3", when="@2.3:") + depends_on("py-torch@1.13:3", when="@2.2:") + depends_on("py-torch@1.12:3", when="@2.1") + depends_on("py-torch@1.11:3", when="@2.0") + depends_on("py-torch@1.10:3", when="@:1") + depends_on("py-torchmetrics@0.7:2", when="@2.0.9:") + depends_on("py-torchmetrics@0.7:1", when="@:2.0.8") + depends_on("py-tqdm@4.57:5") + depends_on("py-typing-extensions@4.4:5", when="@2.2:") + depends_on("py-typing-extensions@4:5") - # Historical requirements - with when("@:2.0"): - depends_on("py-jinja2@:4", type=("build", "run")) - depends_on("py-arrow@1.2:2", type=("build", "run")) - depends_on("py-backoff@2.2.1:3", when="@2.0.5:", type=("build", "run")) - depends_on("py-beautifulsoup4@4.8:5", type=("build", "run")) - depends_on("py-click@:9", type=("build", "run")) - depends_on("py-croniter@1.3:1.4", when="@2.0.5:", type=("build", "run")) - depends_on("py-croniter@1.3", when="@:2.0.4", type=("build", "run")) - depends_on("py-dateutils@:1", type=("build", "run")) - depends_on("py-deepdiff@5.7:7", type=("build", "run")) - depends_on("py-fastapi@0.92:1", when="@2.0.4:", type=("build", "run")) - depends_on("py-fastapi@0.69:0.88", when="@2.0.3", type=("build", "run")) - depends_on("py-fastapi@:0.88", when="@:2.0.2", type=("build", "run")) - depends_on("py-inquirer@2.10:4", type=("build", "run")) - depends_on("py-lightning-cloud@0.5.38:", when="@2.0.9:", type=("build", "run")) - depends_on("py-lightning-cloud@0.5.37:", when="@2.0.5:", type=("build", "run")) - depends_on("py-lightning-cloud@0.5.34:", when="@2.0.3:", type=("build", "run")) - depends_on("py-lightning-cloud@0.5.31:", when="@2:", type=("build", "run")) - depends_on("py-lightning-cloud@0.5.27:", when="@:1", type=("build", "run")) - depends_on("py-psutil@:6", type=("build", "run")) - depends_on("py-pydantic@1.7.4:2.1", when="@2.0.7:", type=("build", "run")) - depends_on("py-pydantic@1.7.4:2.0", when="@2.0.6", type=("build", "run")) - depends_on("py-pydantic@1.7.4:1", when="@2.0.5", type=("build", "run")) - depends_on("py-pydantic@1.7.4:3", when="@2.0.3:2.0.4", type=("build", "run")) - depends_on("py-pydantic@:2", when="@:2.0.2", type=("build", "run")) - depends_on("py-python-multipart@0.0.5:1", type=("build", "run")) - depends_on("py-requests@:3", type=("build", "run")) - depends_on("py-rich@12.3:14", when="@2:", type=("build", "run")) - depends_on("py-rich@:14", when="@:1", type=("build", "run")) - depends_on("py-starlette", when="@2.0.3:", type=("build", "run")) - depends_on("py-starlette@:1", when="@:2.0.2", type=("build", "run")) - depends_on("py-starsessions@1.2.1:1", type=("build", "run")) - depends_on("py-traitlets@5.3:6", type=("build", "run")) - depends_on("py-urllib3@:3", when="@2.0.4:", type=("build", "run")) - depends_on("py-urllib3@:2", when="@:2.0.3", type=("build", "run")) - depends_on("py-uvicorn@:1", type=("build", "run")) - depends_on("py-websocket-client@:2", type=("build", "run")) - depends_on("py-websockets@:12", when="@2.0.5:", type=("build", "run")) - depends_on("py-websockets@:11", when="@:2.0.4", type=("build", "run")) + # Only an alias, not actually used by the library + # depends_on("py-pytorch-lightning", when="@2:") + + # Historical requirements + # https://github.com/Lightning-AI/pytorch-lightning/pull/20081 + depends_on("py-setuptools", when="@:2.3") + + with when("@:2.0"): + depends_on("py-jinja2@:4") + depends_on("py-arrow@1.2:2") + depends_on("py-backoff@2.2.1:3", when="@2.0.5:") + depends_on("py-beautifulsoup4@4.8:5") + depends_on("py-click@:9") + depends_on("py-croniter@1.3:1.4", when="@2.0.5:") + depends_on("py-croniter@1.3", when="@:2.0.4") + depends_on("py-dateutils@:1") + depends_on("py-deepdiff@5.7:7") + depends_on("py-fastapi@0.92:1", when="@2.0.4:") + depends_on("py-fastapi@0.69:0.88", when="@2.0.3") + depends_on("py-fastapi@:0.88", when="@:2.0.2") + depends_on("py-inquirer@2.10:4") + depends_on("py-lightning-cloud@0.5.38:", when="@2.0.9:") + depends_on("py-lightning-cloud@0.5.37:", when="@2.0.5:") + depends_on("py-lightning-cloud@0.5.34:", when="@2.0.3:") + depends_on("py-lightning-cloud@0.5.31:", when="@2:") + depends_on("py-lightning-cloud@0.5.27:", when="@:1") + depends_on("py-psutil@:6") + depends_on("py-pydantic@1.7.4:2.1", when="@2.0.7:") + depends_on("py-pydantic@1.7.4:2.0", when="@2.0.6") + depends_on("py-pydantic@1.7.4:1", when="@2.0.5") + depends_on("py-pydantic@1.7.4:3", when="@2.0.3:2.0.4") + depends_on("py-pydantic@:2", when="@:2.0.2") + depends_on("py-python-multipart@0.0.5:1") + depends_on("py-requests@:3") + depends_on("py-rich@12.3:14", when="@2:") + depends_on("py-rich@:14", when="@:1") + depends_on("py-starlette", when="@2.0.3:") + depends_on("py-starlette@:1", when="@:2.0.2") + depends_on("py-starsessions@1.2.1:1") + depends_on("py-traitlets@5.3:6") + depends_on("py-urllib3@:3", when="@2.0.4:") + depends_on("py-urllib3@:2", when="@:2.0.3") + depends_on("py-uvicorn@:1") + depends_on("py-websocket-client@:2") + depends_on("py-websockets@:12", when="@2.0.5:") + depends_on("py-websockets@:11", when="@:2.0.4") # https://github.com/Lightning-AI/lightning/issues/18858 conflicts("^py-torch~distributed", when="@2.1.0") diff --git a/var/spack/repos/builtin/packages/py-ligo-segments/package.py b/var/spack/repos/builtin/packages/py-ligo-segments/package.py index 0182330d79ad76..491c7468a4ec57 100644 --- a/var/spack/repos/builtin/packages/py-ligo-segments/package.py +++ b/var/spack/repos/builtin/packages/py-ligo-segments/package.py @@ -15,5 +15,7 @@ class PyLigoSegments(PythonPackage): version("1.2.0", sha256="5edbcb88cae007c4e154a61cb2c9d0a6d6d4016c1ecaf0a59a667a267bd20e7a") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-six", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-line-profiler/gettimeofday_py39.patch b/var/spack/repos/builtin/packages/py-line-profiler/gettimeofday_py39.patch new file mode 100644 index 00000000000000..50f9c8b9dd7886 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-line-profiler/gettimeofday_py39.patch @@ -0,0 +1,24 @@ +--- spack-src/timers.c.orig 2024-03-12 23:42:29.017345816 -0700 ++++ spack-src/timers.c 2024-03-12 23:43:55.329454579 -0700 +@@ -32,9 +32,6 @@ + + #else /* !MS_WINDOWS */ + +-#ifndef HAVE_GETTIMEOFDAY +-#error "This module requires gettimeofday() on non-Windows platforms!" +-#endif + + #if (defined(PYOS_OS2) && defined(PYCC_GCC)) + #include +@@ -48,11 +45,7 @@ + { + struct timeval tv; + PY_LONG_LONG ret; +-#ifdef GETTIMEOFDAY_NO_TZ +- gettimeofday(&tv); +-#else + gettimeofday(&tv, (struct timezone *)NULL); +-#endif + ret = tv.tv_sec; + ret = ret * 1000000 + tv.tv_usec; + return ret; diff --git a/var/spack/repos/builtin/packages/py-line-profiler/package.py b/var/spack/repos/builtin/packages/py-line-profiler/package.py index 8adc1106186c14..4001fef2e0fa50 100644 --- a/var/spack/repos/builtin/packages/py-line-profiler/package.py +++ b/var/spack/repos/builtin/packages/py-line-profiler/package.py @@ -11,18 +11,31 @@ class PyLineProfiler(PythonPackage): """Line-by-line profiler.""" - homepage = "https://github.com/rkern/line_profiler" + homepage = "https://github.com/pyutils/line_profiler" pypi = "line_profiler/line_profiler-2.0.tar.gz" license("PSF-2.0") + version("4.1.2", sha256="aa56578b0ff5a756fe180b3fda7bd67c27bbd478b3d0124612d8cf00e4a21df2") + version("3.5.1", sha256="77400208bfbd5d4341938a9a3a4fb5194f5af7fc23b2d496c913755f8310e8b8") version("2.1.2", sha256="efa66e9e3045aa7cb1dd4bf0106e07dec9f80bc781a993fbaf8162a36c20af5c") version("2.0", sha256="739f8ad0e4bcd0cb82e99afc09e00a0351234f6b3f0b1f7f0090a8a2fbbf8381") + depends_on("c", type="build") # generated + + # see pyproject.toml depends_on("python@2.5:", type=("build", "run")) + depends_on("python@:3.10", type=("build", "run"), when="@:3") depends_on("py-setuptools", type="build") - depends_on("py-cython", type="build") + depends_on("py-setuptools@68.2.2", type="build", when="@4.1.2:") + depends_on("py-cython@0.29.24:2", type="build", when="@:4.1.1") + depends_on("py-cython@3.0.3:", type="build", when="@4.1.2:") depends_on("py-ipython@0.13:", type=("build", "run")) + depends_on("cmake", type="build", when="@3") + depends_on("ninja", type="build", when="@3") + depends_on("py-scikit-build@0.9.0:", type="build", when="@3") + + patch("gettimeofday_py39.patch", when="@:2.1.2 ^python@3.9:") # See https://github.com/rkern/line_profiler/issues/166 @run_before("install") diff --git a/var/spack/repos/builtin/packages/py-llnl-sina/package.py b/var/spack/repos/builtin/packages/py-llnl-sina/package.py index d55adb4510cb73..4670788828baf5 100644 --- a/var/spack/repos/builtin/packages/py-llnl-sina/package.py +++ b/var/spack/repos/builtin/packages/py-llnl-sina/package.py @@ -31,6 +31,8 @@ class PyLlnlSina(PythonPackage): version("1.11.0", tag="v1.11.0", commit="f3e9bb3a122cfae2a9fd82c3c5613cff939d3aa1") version("1.10.0", tag="v1.10.0", commit="9c3c0acca5f0d4ac02470571688f00ab0bd61a30") + depends_on("cxx", type="build") # generated + # let's remove dependency on orjson patch("no_orjson.patch") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-llvmlite/package.py b/var/spack/repos/builtin/packages/py-llvmlite/package.py index 73e8f568435f33..758e942337694b 100644 --- a/var/spack/repos/builtin/packages/py-llvmlite/package.py +++ b/var/spack/repos/builtin/packages/py-llvmlite/package.py @@ -28,6 +28,8 @@ class PyLlvmlite(PythonPackage): version("0.33.0", sha256="9c8aae96f7fba10d9ac864b443d1e8c7ee4765c31569a2b201b3d0b67d8fc596") version("0.31.0", sha256="22ab2b9d7ec79fab66ac8b3d2133347de86addc2e2df1b3793e523ac84baa3c8") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("python@3.8:3.11", when="@0.40:", type=("build", "run")) depends_on("python@:3.10", when="@0.38:0.39", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-lmdb/package.py b/var/spack/repos/builtin/packages/py-lmdb/package.py index 9a953753e38915..2707bda7f5e9e9 100644 --- a/var/spack/repos/builtin/packages/py-lmdb/package.py +++ b/var/spack/repos/builtin/packages/py-lmdb/package.py @@ -18,6 +18,8 @@ class PyLmdb(PythonPackage): version("1.3.0", sha256="60a11efc21aaf009d06518996360eed346f6000bfc9de05114374230879f992e") version("1.1.1", sha256="165cd1669b29b16c2d5cc8902b90fede15a7ee475c54d466f1444877a3f511ac") + depends_on("c", type="build") # generated + depends_on("python@2.7:2,3.4:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("lmdb") diff --git a/var/spack/repos/builtin/packages/py-lru-dict/package.py b/var/spack/repos/builtin/packages/py-lru-dict/package.py index d5d88abb93a3a6..2153da2db5c271 100644 --- a/var/spack/repos/builtin/packages/py-lru-dict/package.py +++ b/var/spack/repos/builtin/packages/py-lru-dict/package.py @@ -17,5 +17,7 @@ class PyLruDict(PythonPackage): version("1.1.6", sha256="365457660e3d05b76f1aba3e0f7fedbfcd6528e97c5115a351ddd0db488354cc") + depends_on("c", type="build") # generated + depends_on("python@2.7:", type=("build", "run")) depends_on("py-setuptools", type=("build")) diff --git a/var/spack/repos/builtin/packages/py-lscsoft-glue/package.py b/var/spack/repos/builtin/packages/py-lscsoft-glue/package.py index d35d5544325fde..42f55fb5a2061a 100644 --- a/var/spack/repos/builtin/packages/py-lscsoft-glue/package.py +++ b/var/spack/repos/builtin/packages/py-lscsoft-glue/package.py @@ -18,6 +18,8 @@ class PyLscsoftGlue(PythonPackage): version("2.0.0", sha256="9bdfaebe4c921d83d1e3d1ca24379a644665e9d7530e7070665f387767c66923") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-six", type=("build", "run")) depends_on("py-pyopenssl", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-lws/package.py b/var/spack/repos/builtin/packages/py-lws/package.py index 783fc91e008f81..25e778e6afbc99 100644 --- a/var/spack/repos/builtin/packages/py-lws/package.py +++ b/var/spack/repos/builtin/packages/py-lws/package.py @@ -17,6 +17,8 @@ class PyLws(PythonPackage): version("1.2.6", sha256="ac94834832aadfcd53fcf4a77e1d95155063b39adbce14c733f8345bdac76e87") + depends_on("cxx", type="build") # generated + depends_on("python@3:", type=("build", "run")) depends_on("py-cython", type="build") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-lxml/package.py b/var/spack/repos/builtin/packages/py-lxml/package.py index 7b6c31b08fa7cb..dacbaeed4793f5 100644 --- a/var/spack/repos/builtin/packages/py-lxml/package.py +++ b/var/spack/repos/builtin/packages/py-lxml/package.py @@ -31,6 +31,8 @@ class PyLxml(PythonPackage): version("3.7.3", sha256="aa502d78a51ee7d127b4824ff96500f0181d3c7826e6ee7b800d068be79361c7") version("2.3", sha256="eea1b8d29532739c1383cb4794c5eacd6176f0972b59e8d29348335b87ff2e66") + depends_on("c", type="build") # generated + variant("html5", default=False, description="Enable html5lib backend") variant("htmlsoup", default=False, description="Enable BeautifulSoup4 backend") variant("cssselect", default=False, description="Enable cssselect module") diff --git a/var/spack/repos/builtin/packages/py-lz4/package.py b/var/spack/repos/builtin/packages/py-lz4/package.py index f3b889859dc223..79a7caea39b96b 100644 --- a/var/spack/repos/builtin/packages/py-lz4/package.py +++ b/var/spack/repos/builtin/packages/py-lz4/package.py @@ -18,6 +18,8 @@ class PyLz4(PythonPackage): version("3.1.3", sha256="081ef0a3b5941cb03127f314229a1c78bd70c9c220bb3f4dd80033e707feaa18") version("3.1.0", sha256="debe75513db3eb9e5cdcd82a329ff38374b6316ab65b848b571e0404746c1e05") + depends_on("c", type="build") # generated + depends_on("python@3.5:", type=("build", "run")) depends_on("python@3.7:", when="@4.0.2:", type=("build", "run")) depends_on("py-setuptools@45:", when="@4.0.2:", type="build") diff --git a/var/spack/repos/builtin/packages/py-macs2/package.py b/var/spack/repos/builtin/packages/py-macs2/package.py index ffddbafe0eb250..d76360b04e81ae 100644 --- a/var/spack/repos/builtin/packages/py-macs2/package.py +++ b/var/spack/repos/builtin/packages/py-macs2/package.py @@ -21,6 +21,8 @@ class PyMacs2(PythonPackage): version("2.2.7.1", sha256="ad2ca69bdd02a8942a68aae23133289b5c16ba382bcbe20c39fabf3948929de5") version("2.2.4", sha256="b131aadc8f5fd94bec35308b821e1f7585def788d2e7c756fc8cac402ffee25b") + depends_on("c", type="build") # generated + # patch to correctly identify python-3.10 as greater than required version patch( "https://github.com/macs3-project/MACS/pull/497.patch?full_index=1", diff --git a/var/spack/repos/builtin/packages/py-macs3/package.py b/var/spack/repos/builtin/packages/py-macs3/package.py index 0c547d66d56ac5..cdc6091851472f 100644 --- a/var/spack/repos/builtin/packages/py-macs3/package.py +++ b/var/spack/repos/builtin/packages/py-macs3/package.py @@ -18,6 +18,8 @@ class PyMacs3(PythonPackage): version("3.0.0b3", sha256="caa794d4cfcd7368447eae15878505315dac44c21546e8fecebb3561e9cee362") + depends_on("c", type="build") # generated + depends_on("python@3.9:", type=("build", "run")) depends_on("py-setuptools@60.0:", type="build") diff --git a/var/spack/repos/builtin/packages/py-mahotas/package.py b/var/spack/repos/builtin/packages/py-mahotas/package.py index 0a8badbe14c132..ff8406b5bb9c90 100644 --- a/var/spack/repos/builtin/packages/py-mahotas/package.py +++ b/var/spack/repos/builtin/packages/py-mahotas/package.py @@ -18,5 +18,7 @@ class PyMahotas(PythonPackage): version("1.4.13", sha256="a78dfe15045a20a0d9e01538b80f874580cd3525ae3eaa2c83ced51eb455879c") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-mapbox-earcut/package.py b/var/spack/repos/builtin/packages/py-mapbox-earcut/package.py index 4b529cd9c5ec88..f07e5f22fc9410 100644 --- a/var/spack/repos/builtin/packages/py-mapbox-earcut/package.py +++ b/var/spack/repos/builtin/packages/py-mapbox-earcut/package.py @@ -18,6 +18,8 @@ class PyMapboxEarcut(PythonPackage): version("1.0.1", sha256="9f155e429a22e27387cfd7a6372c3a3865aafa609ad725e2c4465257f154a438") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@42:", type="build") depends_on("py-pybind11@2.6:2", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-mariadb/package.py b/var/spack/repos/builtin/packages/py-mariadb/package.py index 1082fd0f42e774..a16727820379aa 100644 --- a/var/spack/repos/builtin/packages/py-mariadb/package.py +++ b/var/spack/repos/builtin/packages/py-mariadb/package.py @@ -22,6 +22,8 @@ class PyMariadb(PythonPackage): url="https://www.pypi.org/packages/source/m/mariadb/mariadb-1.0.10.zip", ) + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-packaging", type=("build", "run")) depends_on("mariadb-c-client", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-markupsafe/package.py b/var/spack/repos/builtin/packages/py-markupsafe/package.py index 1dee1e7b4c47fc..b4f411d18b4854 100644 --- a/var/spack/repos/builtin/packages/py-markupsafe/package.py +++ b/var/spack/repos/builtin/packages/py-markupsafe/package.py @@ -29,4 +29,6 @@ class PyMarkupsafe(PythonPackage): version("0.20", sha256="f6cf3bd233f9ea6147b21c7c02cac24e5363570ce4fd6be11dab9f499ed6a7d8") version("0.19", sha256="62fcc5d641df8b5ad271ebbd6b77a19cd92eceba1e1a990de4e96c867789f037") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-matplotlib/freetype-include-path.patch b/var/spack/repos/builtin/packages/py-matplotlib/freetype-include-path.patch deleted file mode 100644 index 7007c88d0dbfd9..00000000000000 --- a/var/spack/repos/builtin/packages/py-matplotlib/freetype-include-path.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff --git a/setupext.py b/setupext.py -index 6d363012eb4..00ef3fe5a3d 100644 ---- a/setupext.py -+++ b/setupext.py -@@ -162,8 +162,10 @@ def get_include_dirs(): - """ - include_dirs = [os.path.join(d, 'include') for d in get_base_dirs()] - if sys.platform != 'win32': -- # gcc includes this dir automatically, so also look for headers in -+ # gcc includes these dirs automatically, so also look for headers in - # these dirs -+ include_dirs.extend( -+ os.environ.get('CPATH', '').split(os.pathsep)) - include_dirs.extend( - os.environ.get('CPLUS_INCLUDE_PATH', '').split(os.pathsep)) - return include_dirs diff --git a/var/spack/repos/builtin/packages/py-matplotlib/package.py b/var/spack/repos/builtin/packages/py-matplotlib/package.py index b7ddf66c122c15..7d64014779038d 100644 --- a/var/spack/repos/builtin/packages/py-matplotlib/package.py +++ b/var/spack/repos/builtin/packages/py-matplotlib/package.py @@ -16,7 +16,6 @@ class PyMatplotlib(PythonPackage): homepage = "https://matplotlib.org/" pypi = "matplotlib/matplotlib-3.3.2.tar.gz" - maintainers("adamjstewart") skip_modules = [ "matplotlib.tests", "mpl_toolkits.axes_grid1.tests", @@ -25,11 +24,16 @@ class PyMatplotlib(PythonPackage): ] license("Apache-2.0") + maintainers("adamjstewart", "rgommers") + version("3.9.1", sha256="de06b19b8db95dd33d0dc17c926c7c9ebed9f572074b6fac4f65068a6814d010") + version("3.9.0", sha256="e6d29ea6c19e34b30fb7d88b7081f869a03014f66fe06d62cc77d5a6ea88ed7a") + version("3.8.4", sha256="8aac397d5e9ec158960e31c381c5ffc52ddd52bd9a47717e2a694038167dffea") version("3.8.3", sha256="7b416239e9ae38be54b028abbf9048aff5054a9aba5416bef0bd17f9162ce161") version("3.8.2", sha256="01a978b871b881ee76017152f1f1a0cbf6bd5f7b8ff8c96df0df1bd57d8755a1") version("3.8.1", sha256="044df81c1f6f3a8e52d70c4cfcb44e77ea9632a10929932870dfaa90de94365d") version("3.8.0", sha256="df8505e1c19d5c2c26aff3497a7cbd3ccfc2e97043d1e4db3e76afa399164b69") + version("3.7.5", sha256="1e5c971558ebc811aa07f54c7b7c677d78aa518ef4c390e14673a09e0860184a") version("3.7.4", sha256="7cd4fef8187d1dd0d9dcfdbaa06ac326d396fb8c71c647129f0bf56835d77026") version("3.7.3", sha256="f09b3dd6bdeb588de91f853bbb2d6f0ff8ab693485b0c49035eaa510cb4f142e") version("3.7.2", sha256="a8cdb91dddb04436bd2f098b8fdf4b81352e68cf4d2c6756fcc414791076569b") @@ -59,56 +63,53 @@ class PyMatplotlib(PythonPackage): version("3.1.2", sha256="8e8e2c2fe3d873108735c6ee9884e6f36f467df4a143136209cff303b183bada") version("3.1.1", sha256="1febd22afe1489b13c6749ea059d392c03261b2950d1d45c17e3aed812080c93") version("3.1.0", sha256="1e0213f87cc0076f7b0c4c251d7e23601e2419cd98691df79edb95517ba06f0c") + version("3.0.3", sha256="e1d33589e32f482d0a7d1957bf473d43341115d40d33f578dad44432e47df7b7") version("3.0.2", sha256="c94b792af431f6adb6859eb218137acd9a35f4f7442cea57e4a59c54751c36af") + version("3.0.1", sha256="70f8782c50ac2c7617aad0fa5ba59fc49f690a851d6afc0178813c49767644dd") version("3.0.0", sha256="b4e2333c98a7c2c1ff6eb930cd2b57d4b818de5437c5048802096b32f66e65f9") - version("2.2.5", sha256="a3037a840cd9dfdc2df9fee8af8f76ca82bfab173c0f9468193ca7a89a2b60ea") - version("2.2.4", sha256="029620799e581802961ac1dcff5cb5d3ee2f602e0db9c0f202a90495b37d2126") - version("2.2.3", sha256="7355bf757ecacd5f0ac9dd9523c8e1a1103faadf8d33c22664178e17533f8ce5") - version("2.2.2", sha256="4dc7ef528aad21f22be85e95725234c5178c0f938e2228ca76640e5e84d8cde8") - version("2.0.2", sha256="0ffbc44faa34a8b1704bc108c451ecf87988f900ef7ce757b8e2e84383121ff1") - version("2.0.0", sha256="36cf0985829c1ab2b8b1dae5e2272e53ae681bf33ab8bedceed4f0565af5f813") - - # https://matplotlib.org/tutorials/introductory/usage.html#backends - # From `lib/matplotlib/rcsetup.py`: - interactive_bk = [ + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + # https://matplotlib.org/stable/users/explain/figure/backends.html + # matplotlib 3.9+: lib/matplotlib/backends/registry.py + # matplotlib 3.8-: lib/matplotlib/rcsetup.py + all_backends = [ # GTK - conditional("gtk", when="@:2"), - conditional("gtkagg", when="@:2"), - conditional("gtkcairo", when="@:2"), "gtk3agg", "gtk3cairo", conditional("gtk4agg", when="@3.5:"), conditional("gtk4cairo", when="@3.5:"), + # Cocoa + "macosx", + # Jupyter Notebook + "nbagg", + conditional("notebook", when="@3.9:"), # Qt conditional("qtagg", when="@3.5:"), conditional("qtcairo", when="@3.5:"), conditional("qt4agg", when="@:3.4"), - conditional("qt4cairo", when="@2.2:3.4"), + conditional("qt4cairo", when="@:3.4"), "qt5agg", - conditional("qt5cairo", when="@2.2:"), + "qt5cairo", # Tk "tkagg", "tkcairo", + # WebAgg + "webagg", # Wx "wx", "wxagg", - conditional("wxcairo", when="@2.2:"), - # Other - "macosx", - "nbagg", - "webagg", - ] - non_interactive_bk = [ + "wxcairo", + # Headless "agg", "cairo", - conditional("gdk", when="@:2"), "pdf", "pgf", "ps", "svg", "template", ] - all_backends = interactive_bk + non_interactive_bk default_backend = "agg" if sys.platform == "darwin": @@ -133,7 +134,7 @@ class PyMatplotlib(PythonPackage): variant("latex", default=False, description="Enable LaTeX text rendering support") variant("fonts", default=False, description="Enable support for system font detection") - # https://matplotlib.org/stable/devel/dependencies.html + # https://matplotlib.org/stable/install/dependencies.html # Runtime dependencies # Mandatory dependencies depends_on("python@3.9:", when="@3.8:", type=("build", "link", "run")) @@ -143,14 +144,17 @@ class PyMatplotlib(PythonPackage): depends_on("py-cycler@0.10:", type=("build", "run")) depends_on("py-fonttools@4.22:", when="@3.5:", type=("build", "run")) depends_on("py-kiwisolver@1.3.1:", when="@3.8.1:", type=("build", "run")) - depends_on("py-kiwisolver@1.0.1:", when="@2.2:", type=("build", "run")) - depends_on("py-numpy@1.21:1", when="@3.8:", type=("build", "link", "run")) - depends_on("py-numpy@1.20:", when="@3.7:", type=("build", "link", "run")) - depends_on("py-numpy@1.19:", when="@3.6:", type=("build", "link", "run")) - depends_on("py-numpy@1.17:", when="@3.5:", type=("build", "link", "run")) - depends_on("py-numpy@1.16:", when="@3.4:", type=("build", "link", "run")) - depends_on("py-numpy@1.15:", when="@3.3:", type=("build", "link", "run")) - depends_on("py-numpy@1.11:", type=("build", "run")) + depends_on("py-kiwisolver@1.0.1:", type=("build", "run")) + depends_on("py-numpy@1.23:", when="@3.9:", type=("build", "link", "run")) + depends_on("py-numpy@1.21:", when="@3.8", type=("build", "link", "run")) + depends_on("py-numpy@1.20:", when="@3.7", type=("build", "link", "run")) + depends_on("py-numpy@1.19:", when="@3.6", type=("build", "link", "run")) + depends_on("py-numpy@1.17:", when="@3.5", type=("build", "link", "run")) + depends_on("py-numpy@1.16:", when="@3.4", type=("build", "link", "run")) + depends_on("py-numpy@1.15:", when="@3.3", type=("build", "link", "run")) + depends_on("py-numpy@1.11:", when="@:3.2", type=("build", "link", "run")) + # https://github.com/matplotlib/matplotlib/issues/26778 + depends_on("py-numpy@:1", when="@:3.8.3", type=("build", "link", "run")) depends_on("py-packaging@20:", when="@3.6:", type=("build", "run")) depends_on("py-packaging", when="@3.5:", type=("build", "run")) depends_on("pil@8:", when="@3.8.1:", type=("build", "run")) @@ -163,16 +167,13 @@ class PyMatplotlib(PythonPackage): depends_on("py-python-dateutil@2.1:", type=("build", "run")) depends_on("py-importlib-resources@3.2:", when="@3.7: ^python@:3.9", type=("build", "run")) - # Historical dependencies - depends_on("py-pytz", type=("build", "run"), when="@:2") - depends_on("py-six@1.10.0:", type=("build", "run"), when="@2") - depends_on("py-six@1.9.0:", type=("build", "run"), when="@:1") - # Optional dependencies # Backends # Tk for backend in ["tkagg", "tkcairo"]: - depends_on("tk@8.4:8.5,8.6.2:", when="backend=" + backend, type="run") + depends_on("tk@8.5:", when="@3.8: backend=" + backend, type="run") + depends_on("tk@8.4:", when="@3.5: backend=" + backend, type="run") + depends_on("tk@8.3:", when="backend=" + backend, type="run") depends_on("python+tkinter", when="backend=" + backend, type="run") # Qt # matplotlib/backends/qt_compat.py @@ -186,12 +187,13 @@ class PyMatplotlib(PythonPackage): depends_on("py-pyqt6@6.1:", when="backend=" + backend, type="run") depends_on("qt-base+gui+widgets", when="backend=" + backend, type="run") # GTK - for backend in ["gtk", "gtkagg", "gtkcairo", "gtk3agg", "gtk3cairo", "gtk4agg", "gtk4cairo"]: + for backend in ["gtk3agg", "gtk3cairo", "gtk4agg", "gtk4cairo"]: depends_on("py-pygobject", when="backend=" + backend, type="run") - depends_on("py-pycairo@1.14:", when="backend=" + backend, type="run") + depends_on("py-pycairo@1.14:", when="@3.6: backend=" + backend, type="run") + depends_on("py-pycairo@1.11:", when="@3.3: backend=" + backend, type="run") + depends_on("py-pycairo", when="backend=" + backend, type="run") # Cairo for backend in [ - "gtkcairo", "gtk3cairo", "gtk4cairo", "qtcairo", @@ -201,12 +203,15 @@ class PyMatplotlib(PythonPackage): "wxcairo", "cairo", ]: - depends_on("py-pycairo@1.14:", when="backend=" + backend, type="run") + depends_on("py-pycairo@1.14:", when="@3.6: backend=" + backend, type="run") + depends_on("py-pycairo@1.11:", when="@3.3: backend=" + backend, type="run") + depends_on("py-pycairo", when="backend=" + backend, type="run") # Wx for backend in ["wx", "wxagg", "wxcairo"]: depends_on("py-wxpython@4:", when="backend=" + backend, type="run") # Other - depends_on("py-tornado@5:", when="backend=webagg", type="run") + depends_on("py-tornado@5:", when="@3.5: backend=webagg", type="run") + depends_on("py-tornado", when="backend=webagg", type="run") depends_on("py-ipykernel", when="backend=nbagg", type="run") # Optional dependencies @@ -219,7 +224,7 @@ class PyMatplotlib(PythonPackage): depends_on("pkgconfig", type="build") # C libraries - depends_on("freetype@2.3:") # freetype 2.6.1 needed for tests to pass + depends_on("freetype@2.3: build_system=autotools") depends_on("qhull@2020.2:", when="@3.4:") # starting from qhull 2020.2 libqhull.so on which py-matplotlib@3.3 versions # rely on does not exist anymore, only libqhull_r.so @@ -228,41 +233,43 @@ class PyMatplotlib(PythonPackage): # Dependencies for building matplotlib # Setup dependencies - depends_on("py-certifi@2020.6.20:", when="@3.3.1:", type="build") - depends_on("py-numpy@1.25:", when="@3.8:", type="build") - depends_on("py-pybind11@2.6:", when="@3.7:", type="build") - depends_on("py-setuptools@64:", when="@3.8.1:", type="build") - depends_on("py-setuptools@42:", when="@3.8:", type="build") - depends_on("py-setuptools@42:", when="@3.7.2:3.7", type=("build", "run")) - depends_on("py-setuptools", when="@:3.7.1", type=("build", "run")) + depends_on("py-meson-python@0.13.1:", when="@3.9:", type="build") + depends_on("ninja@1.8.2:", when="@3.9:", type="build") + depends_on("py-pybind11@2.6:", when="@3.7:", type=("build", "link")) depends_on("py-setuptools-scm@7:", when="@3.6:", type="build") depends_on("py-setuptools-scm@4:6", when="@3.5", type="build") + + # Historical dependencies + depends_on("py-certifi@2020.6.20:", when="@3.3.1:3.8", type="build") + depends_on("py-setuptools@64:", when="@3.8.1:3.8", type="build") + depends_on("py-setuptools@42:", when="@3.8.0", type="build") + depends_on("py-setuptools@42:", when="@3.7.2:3.7", type=("build", "run")) + depends_on("py-setuptools", when="@:3.7.1", type=("build", "run")) depends_on("py-setuptools-scm-git-archive", when="@3.5", type="build") # Testing dependencies - # https://matplotlib.org/stable/devel/development_setup.html#additional-dependencies-for-testing - depends_on("py-pytest@3.6:", type="test") - depends_on("ghostscript@9.0:", type="test") - # depends_on("inkscape@:0", type="test") + # Required + # https://github.com/spack/spack/issues/43597 + # depends_on("freetype@2.6.1 build_system=autotools", type="test") + depends_on("py-pytest@7:", type="test") msg = "MacOSX backend requires macOS 10.12+" conflicts("platform=linux", when="backend=macosx", msg=msg) - conflicts("platform=cray", when="backend=macosx", msg=msg) conflicts("platform=windows", when="backend=macosx", msg=msg) + conflicts("^tk@8.6.0:8.6.1") + # https://github.com/matplotlib/matplotlib/pull/21662 patch("matplotlibrc.patch", when="@3.5.0") - # Patch to pick up correct freetype headers - patch("freetype-include-path.patch", when="@2.2.2:2.9.9") - - @property - def config_file(self): - # https://github.com/matplotlib/matplotlib/pull/20871 - return "mplsetup.cfg" if self.spec.satisfies("@3.5:") else "setup.cfg" @property def archive_files(self): - return [os.path.join(self.build_directory, self.config_file)] + if self.spec.satisfies("@3.9:"): + return [os.path.join(self.stage.source_path, "build", "meson-logs", "meson-log.txt")] + elif self.spec.satisfies("@3.5:"): + return [os.path.join(self.build_directory, "mplsetup.cfg")] + else: + return [os.path.join(self.build_directory, "setup.cfg")] def flag_handler(self, name, flags): if name == "cxxflags": @@ -270,13 +277,62 @@ def flag_handler(self, name, flags): flags.append("-Wno-error=register") return (flags, None, None) + @when("@3.9:") + def config_settings(self, spec, prefix): + return { + "builddir": "build", + "compile-args": f"-j{make_jobs}", + "setup-args": { + "-Dsystem-freetype": True, + "-Dsystem-qhull": True, + "-DrcParams-backend": spec.variants["backend"].value, + # Avoids error where link time opt is used for compile but not link + "-Db_lto": not (self.spec.satisfies("%clang") or self.spec.satisfies("%oneapi")), + }, + } + + @run_after("install") + @on_package_attributes(run_tests=True) + def copy_reference_images(self): + # https://matplotlib.org/devdocs/devel/testing.html#obtain-the-reference-images + install_tree( + join_path("lib", "matplotlib", "tests", "baseline_images"), + join_path(python_platlib, "matplotlib", "tests", "baseline_images"), + ) + if self.spec.satisfies("@3.7:"): + for toolkit in ["axes_grid1", "axisartist", "mplot3d"]: + install_tree( + join_path("lib", "mpl_toolkits", toolkit, "tests", "baseline_images"), + join_path(python_platlib, "mpl_toolkits", toolkit, "tests", "baseline_images"), + ) + else: + install_tree( + join_path("lib", "mpl_toolkits", "tests", "baseline_images"), + join_path(python_platlib, "mpl_toolkits", "tests", "baseline_images"), + ) + + @run_after("install") + @on_package_attributes(run_tests=True) + def install_test(self): + # https://matplotlib.org/devdocs/devel/testing.html#run-the-tests + python("-m", "pytest", "--pyargs", "matplotlib.tests") + if self.spec.satisfies("@3.7:"): + for toolkit in ["axes_grid1", "axisartist", "mplot3d"]: + python("-m", "pytest", "--pyargs", f"mpl_toolkits.{toolkit}.tests") + else: + python("-m", "pytest", "--pyargs", "mpl_toolkits.tests") + + @when("@:3.8") def setup_build_environment(self, env): include = [] library = [] for dep in self.spec.dependencies(deptype="link"): query = self.spec[dep.name] include.extend(query.headers.directories) - library.extend(query.libs.directories) + try: + library.extend(query.libs.directories) + except spack.error.NoLibrariesError: + pass # Build uses a mix of Spack's compiler wrapper and the actual compiler, # so this is needed to get parts of the build working. @@ -284,13 +340,19 @@ def setup_build_environment(self, env): env.set("CPATH", ":".join(include)) env.set("LIBRARY_PATH", ":".join(library)) + @when("@:3.8") @run_before("install") def configure(self): """Set build options with regards to backend GUI libraries.""" backend = self.spec.variants["backend"].value - with open(self.config_file, "w") as config: + if self.spec.satisfies("@3.5:"): + config_file = "mplsetup.cfg" + else: + config_file = "setup.cfg" + + with open(config_file, "w") as config: # Default backend config.write("[rc_options]\n") config.write("backend = " + backend + "\n") @@ -304,9 +366,3 @@ def configure(self): # avoids error where link time opt is used for compile but not link if self.spec.satisfies("%clang") or self.spec.satisfies("%oneapi"): config.write("enable_lto = False\n") - - @run_after("install") - @on_package_attributes(run_tests=True) - def build_test(self): - pytest = which("pytest") - pytest() diff --git a/var/spack/repos/builtin/packages/py-maturin/package.py b/var/spack/repos/builtin/packages/py-maturin/package.py index 34e39ee79e7aa4..ab2858ec7d97e9 100644 --- a/var/spack/repos/builtin/packages/py-maturin/package.py +++ b/var/spack/repos/builtin/packages/py-maturin/package.py @@ -14,15 +14,33 @@ class PyMaturin(PythonPackage): homepage = "https://github.com/pyo3/maturin" pypi = "maturin/maturin-0.13.7.tar.gz" + maintainers("teaguesterling") + license("Apache-2.0") + version("1.6.0", sha256="b955025c24c8babc808db49e0ff90db8b4b1320dcc16b14eb26132841737230d") + version("1.5.1", sha256="3dd834ece80edb866af18cbd4635e0ecac40139c726428d5f1849ae154b26dca") version("1.4.0", sha256="ed12e1768094a7adeafc3a74ebdb8dc2201fa64c4e7e31f14cfc70378bf93790") version("1.1.0", sha256="4650aeaa8debd004b55aae7afb75248cbd4d61cd7da2dcf4ead8b22b58cecae0") version("0.14.17", sha256="fb4e3311e8ce707843235fbe8748a05a3ae166c3efd6d2aa335b53dfc2bd3b88") version("0.13.7", sha256="c0a77aa0c57f945649ca711c806203a1b6888ad49c2b8b85196ffdcf0421db77") - depends_on("py-setuptools", type="build") - depends_on("py-wheel@0.36.2:", type="build") - depends_on("py-setuptools-rust@1.4:", type="build") - depends_on("py-tomli@1.1:", when="^python@:3.10", type=("build", "run")) - depends_on("rust", type=("build", "run")) + with default_args(type="build"): + depends_on("py-setuptools") + depends_on("py-wheel@0.36.2:") + depends_on("py-setuptools-rust@1.4:") + + with default_args(type=("build", "run")): + depends_on("py-tomli@1.1:", when="^python@:3.10") + for rust, maturin in [ + ("1.70", "1.5.0"), + ("1.64", "1.0.0"), + ("1.62", "0.14.3"), + ("1.59", "0.13.3"), + ]: + depends_on(f"rust@{rust}:", when=f"@{maturin}:") + + # May be an accidental dependency, remove in the future + # https://git.alpinelinux.org/aports/commit/?id=7ad298b467403b96a6b97d050170e367f147a75f + # https://patchwork.yoctoproject.org/project/oe-core/patch/8803dc101b641c948805cab9e5784c38f43b0e51.1702791173.git.tim.orling@konsulko.com/ + depends_on("bzip2", when="platform=darwin") diff --git a/var/spack/repos/builtin/packages/py-mayavi/package.py b/var/spack/repos/builtin/packages/py-mayavi/package.py index 31e6c2bd43d81a..5f91cb917e0319 100644 --- a/var/spack/repos/builtin/packages/py-mayavi/package.py +++ b/var/spack/repos/builtin/packages/py-mayavi/package.py @@ -22,6 +22,9 @@ class PyMayavi(PythonPackage): url="https://files.pythonhosted.org/packages/source/m/mayavi/mayavi-4.7.1.tar.bz2", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-apptools", type=("build", "run")) depends_on("py-envisage", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-mdanalysis/package.py b/var/spack/repos/builtin/packages/py-mdanalysis/package.py index 69f5a0c85304ef..56edcbb7648a43 100644 --- a/var/spack/repos/builtin/packages/py-mdanalysis/package.py +++ b/var/spack/repos/builtin/packages/py-mdanalysis/package.py @@ -27,6 +27,9 @@ class PyMdanalysis(PythonPackage): version("2.4.3", sha256="c4fbdc414e4fdda69052fff2a6e412180fe6fa90a42c24793beee04123648c92") version("2.4.2", sha256="ae2ee5627391e73f74eaa3c547af3ec6ab8b040d27dedffe3a7ece8e0cd27636") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "analysis", default=True, @@ -42,9 +45,11 @@ class PyMdanalysis(PythonPackage): depends_on("py-cython@0.28:", type="build") # MDAnalysis required dependencies (install_requires) - depends_on("py-numpy@1.22.3:1", when="@2.6.0:", type=("build", "run")) + depends_on("py-numpy@1.22.3:", when="@2.6.0:", type=("build", "run")) depends_on("py-numpy@1.21.0:", when="@2.5.0:", type=("build", "run")) depends_on("py-numpy@1.20.0:", type=("build", "run")) + # https://github.com/MDAnalysis/mdanalysis/pull/4482 + depends_on("py-numpy@:1", type=("build", "run")) depends_on("py-griddataformats@0.4.0:", type=("build", "run")) depends_on("py-mmtf-python@1.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-meldmd/package.py b/var/spack/repos/builtin/packages/py-meldmd/package.py index d831c2d05617a8..2f8538154795af 100644 --- a/var/spack/repos/builtin/packages/py-meldmd/package.py +++ b/var/spack/repos/builtin/packages/py-meldmd/package.py @@ -20,6 +20,8 @@ class PyMeldmd(CMakePackage, PythonExtension, CudaPackage): version("0.6.1", sha256="aae8e5bfbdacc1e6de61768a3298314c51575cda477a511e98dc11f5730fd918") version("0.4.20", sha256="8c8d2b713f8dc0ecc137d19945b3957e12063c8dda569696e47c8820eeac6c92") + depends_on("cxx", type="build") # generated + extends("python") depends_on("python@3.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-melissa-core/package.py b/var/spack/repos/builtin/packages/py-melissa-core/package.py index 78358c4401dc00..f6b6b3c9c46421 100644 --- a/var/spack/repos/builtin/packages/py-melissa-core/package.py +++ b/var/spack/repos/builtin/packages/py-melissa-core/package.py @@ -23,6 +23,9 @@ class PyMelissaCore(PythonPackage): version("joss", tag="JOSS_v2", commit="20bbe68c1a7b73aa2ea3ad35681c332c7a5fc516") version("sc23", tag="SC23", commit="8bb5b6817d4abe4eaa5893552d711150e53535f3") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # define variants for the deep learning server (torch, tf) variant( "torch", default=False, description="Install Deep Learning requirements with Pytorch only" diff --git a/var/spack/repos/builtin/packages/py-memray/package.py b/var/spack/repos/builtin/packages/py-memray/package.py index c8f752729323ba..e5c6bbba0c8c6d 100644 --- a/var/spack/repos/builtin/packages/py-memray/package.py +++ b/var/spack/repos/builtin/packages/py-memray/package.py @@ -16,6 +16,9 @@ class PyMemray(PythonPackage): version("1.1.0", sha256="876e46e0cd42394be48b33f81314bc946f4eb023b04bf1def084c25ccf1d2bb6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.7:", type=("build", "link", "run")) depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-merlin/package.py b/var/spack/repos/builtin/packages/py-merlin/package.py index 344b31ae575513..74a5cc70904b67 100644 --- a/var/spack/repos/builtin/packages/py-merlin/package.py +++ b/var/spack/repos/builtin/packages/py-merlin/package.py @@ -20,6 +20,8 @@ class PyMerlin(PythonPackage): version("master", branch="master") version("1.10.3", sha256="6edaf17b502db090cef0bc53ae0118c55f77d7a16f43c7a235e0dd1770decadb") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type=("build", "run")) depends_on("py-cached-property", type=("build", "run")) depends_on("py-celery@5.0.3:+redis+sqlalchemy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-meshpy/package.py b/var/spack/repos/builtin/packages/py-meshpy/package.py index 8e1832b114d14b..8d171f36f56c0c 100644 --- a/var/spack/repos/builtin/packages/py-meshpy/package.py +++ b/var/spack/repos/builtin/packages/py-meshpy/package.py @@ -19,6 +19,8 @@ class PyMeshpy(PythonPackage): version("2022.1.3", sha256="a7158e31ece25fa6c6cebce9fd1e968157d661dc8769fb30ceba69c351478475") + depends_on("cxx", type="build") # generated + depends_on("python@3.6:3", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-pybind11", type="build") diff --git a/var/spack/repos/builtin/packages/py-meson-python/package.py b/var/spack/repos/builtin/packages/py-meson-python/package.py index 4171f48403fd29..d9df736858955f 100644 --- a/var/spack/repos/builtin/packages/py-meson-python/package.py +++ b/var/spack/repos/builtin/packages/py-meson-python/package.py @@ -11,11 +11,13 @@ class PyMesonPython(PythonPackage): homepage = "https://github.com/mesonbuild/meson-python" pypi = "meson_python/meson_python-0.7.0.tar.gz" + tags = ["build-tools"] maintainers("eli-schwartz", "adamjstewart", "rgommers") license("MIT") + version("0.16.0", sha256="9068c17e36c89d6c7ff709fffb2a8a9925e8cd0b02629728e5ceaf2ec505cb5f") version("0.15.0", sha256="fddb73eecd49e89c1c41c87937cd89c2d0b65a1c63ba28238681d4bd9484d26f") version("0.13.1", sha256="63b3170001425c42fa4cfedadb9051cbd28925ff8eed7c40d36ba0099e3c7618") version("0.12.0", sha256="8cb159a8093a2e73cfa897f8092ec93b74e3842f94dff7fde381c6fe0e0b064d") @@ -24,12 +26,19 @@ class PyMesonPython(PythonPackage): version("0.9.0", sha256="6aa5a09ff5cce1c5308938ebbf3eab5529413c8677055ace1ac8c83d8a07b29d") version("0.8.1", sha256="442f1fa4cf5db50eea61170a6059c10fafd70977f5dbdf3441c106cd23b05e4c") version("0.8.0", sha256="b5c8a2727e6f6feaffc1db513244c9bdb5d0f689b45e24f4529b649b7710daf7") - version("0.7.0", sha256="9fcfa350f44ca80dd4f5f9c3d251725434acf9a07d9618f382e6cc4629dcbe84") + version( + "0.7.0", + sha256="9fcfa350f44ca80dd4f5f9c3d251725434acf9a07d9618f382e6cc4629dcbe84", + deprecated=True, + ) + + depends_on("c", type="build") # generated depends_on("py-colorama", when="platform=windows", type=("build", "run")) depends_on("meson@0.63.3:", when="@0.11:", type=("build", "run")) depends_on("meson@0.63:", when="@0.9:0.10", type=("build", "run")) depends_on("meson@0.62:", type=("build", "run")) + depends_on("py-packaging@19:", when="@0.16:", type=("build", "run")) depends_on("py-pyproject-metadata@0.7.1:", when="@0.13:", type=("build", "run")) depends_on("py-pyproject-metadata@0.6.1:", when="@0.12:", type=("build", "run")) depends_on("py-pyproject-metadata@0.5:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-metomi-rose/package.py b/var/spack/repos/builtin/packages/py-metomi-rose/package.py index d6a6ae2caceb13..c9d35f1185108b 100644 --- a/var/spack/repos/builtin/packages/py-metomi-rose/package.py +++ b/var/spack/repos/builtin/packages/py-metomi-rose/package.py @@ -18,6 +18,8 @@ class PyMetomiRose(PythonPackage): version("2.1.0", sha256="1b60135a434fe4325d364a57e8f5e81e90f39b373b9d68733458c1adc2513c05") + depends_on("fortran", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-aiofiles", type=("build", "run")) depends_on("py-jinja2@2.10.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-metpy/package.py b/var/spack/repos/builtin/packages/py-metpy/package.py index f6bd28c139c8b6..3be38a414c857b 100644 --- a/var/spack/repos/builtin/packages/py-metpy/package.py +++ b/var/spack/repos/builtin/packages/py-metpy/package.py @@ -30,7 +30,8 @@ class PyMetpy(PythonPackage): depends_on("py-matplotlib@2.1.0:", type=("build", "run")) depends_on("py-numpy@1.16.0:", type=("build", "run")) depends_on("py-pandas@0.24.0:", type=("build", "run")) - depends_on("py-pint@0.10.1:", type=("build", "run")) + # Unable to Find "pint.unit" -- Module Not Found Error with py-pint@0.20: + depends_on("py-pint@0.10.1:0.19", type=("build", "run")) depends_on("py-pooch@0.1:", type=("build", "run")) depends_on("py-pyproj@2.3.0:", type=("build", "run")) depends_on("py-scipy@1.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-mikado/package.py b/var/spack/repos/builtin/packages/py-mikado/package.py index 0a0b8e3e397730..60a383fe1dcb57 100644 --- a/var/spack/repos/builtin/packages/py-mikado/package.py +++ b/var/spack/repos/builtin/packages/py-mikado/package.py @@ -16,6 +16,8 @@ class PyMikado(PythonPackage): version("1.2.4", sha256="c0485dba3b7c285599809e058c83f33b5efa9522d20d9f980423410604207f61") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-wheel@0.28.0:", type="build") depends_on("py-pyyaml", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-minkowskiengine/package.py b/var/spack/repos/builtin/packages/py-minkowskiengine/package.py index 41fa2afc87f241..6ae752d6fe970b 100644 --- a/var/spack/repos/builtin/packages/py-minkowskiengine/package.py +++ b/var/spack/repos/builtin/packages/py-minkowskiengine/package.py @@ -17,6 +17,8 @@ class PyMinkowskiengine(PythonPackage, CudaPackage): version("0.5.4", sha256="b1879c00d0b0b1d30ba622cce239886a7e3c78ee9da1064cdfe2f64c2ab15f94") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-pybind11", type="link") # in newer pip versions --install-option does not exist diff --git a/var/spack/repos/builtin/packages/py-misopy/package.py b/var/spack/repos/builtin/packages/py-misopy/package.py index 61d42fff953495..12f2433c6b06bf 100644 --- a/var/spack/repos/builtin/packages/py-misopy/package.py +++ b/var/spack/repos/builtin/packages/py-misopy/package.py @@ -17,6 +17,8 @@ class PyMisopy(PythonPackage): version("0.5.4", sha256="377a28b0c254b1920ffdc2d89cf96c3a21cadf1cf148ee6d6ef7a88ada067dfc") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("python@2.6:", type=("build", "run")) depends_on("py-numpy@1.5.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-ml-dtypes/package.py b/var/spack/repos/builtin/packages/py-ml-dtypes/package.py index 5e3f85ab7b63a0..eed59d4fbccea6 100644 --- a/var/spack/repos/builtin/packages/py-ml-dtypes/package.py +++ b/var/spack/repos/builtin/packages/py-ml-dtypes/package.py @@ -17,11 +17,18 @@ class PyMlDtypes(PythonPackage): license("Apache-2.0") + version("0.4.0", tag="v0.4.0", commit="9fc7e6773acb66fa496ed8d476a008a489a4da49") version("0.3.1", tag="v0.3.1", commit="bbeedd470ecac727c42e97648c0f27bfc312af30") version("0.2.0", tag="v0.2.0", commit="5b9fc9ad978757654843f4a8d899715dbea30e88") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("python@3.9:", when="@0.3:", type=("build", "link", "run")) depends_on("py-numpy@1.21:", type=("build", "link", "run")) + # https://github.com/jax-ml/ml_dtypes/pull/143 + depends_on("py-numpy@:1", when="@:0.3", type=("build", "link", "run")) # Build dependencies are overconstrained, older versions work just fine - depends_on("py-pybind11", type=("build", "link")) + depends_on("py-pybind11", when="@:0.3.1", type=("build", "link")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-mlflow/package.py b/var/spack/repos/builtin/packages/py-mlflow/package.py index b108dd9cf6b9b4..b1bd0831442133 100644 --- a/var/spack/repos/builtin/packages/py-mlflow/package.py +++ b/var/spack/repos/builtin/packages/py-mlflow/package.py @@ -43,14 +43,14 @@ class PyMlflow(PythonPackage): depends_on("py-pandas@:1", type=("build", "run")) depends_on("py-querystring-parser@:1", type=("build", "run")) depends_on("py-sqlalchemy@1.4.0:1", type=("build", "run")) - for platform in ["linux", "darwin", "cray"]: + for platform in ["linux", "darwin"]: depends_on("py-gunicorn@:20", type=("build", "run"), when=f"platform={platform}") depends_on("py-waitress@:2", type=("build", "run"), when="platform=windows") depends_on("py-scikit-learn@:1", type=("build", "run")) depends_on("py-pyarrow@4.0.0:10", type=("build", "run")) depends_on("py-shap@0.40:0", type=("build", "run")) depends_on("py-markdown@3.3:3", type=("build", "run")) - for platform in ["linux", "darwin", "cray"]: + for platform in ["linux", "darwin"]: depends_on("py-jinja2@2.11:3", type=("build", "run"), when=f"platform={platform}") depends_on("py-jinja2@3.0:3", type=("build", "run"), when="platform=windows") depends_on("py-matplotlib@:3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-mmcv/package.py b/var/spack/repos/builtin/packages/py-mmcv/package.py index 015c8ded2a66fa..1d62e15c550745 100644 --- a/var/spack/repos/builtin/packages/py-mmcv/package.py +++ b/var/spack/repos/builtin/packages/py-mmcv/package.py @@ -18,6 +18,8 @@ class PyMmcv(PythonPackage): version("0.5.1", sha256="7c5ad30d9b61e44019e81ef46c406aa85dd08b5d0ba12ddd5cdc9c445835a55e") + depends_on("cxx", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-addict", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-mne-bids/package.py b/var/spack/repos/builtin/packages/py-mne-bids/package.py new file mode 100644 index 00000000000000..453101527221db --- /dev/null +++ b/var/spack/repos/builtin/packages/py-mne-bids/package.py @@ -0,0 +1,29 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyMneBids(PythonPackage): + """MNE-BIDS: Organizing MEG, EEG, and iEEG data according to the BIDS + specification and facilitating their analysis with MNE-Python.""" + + homepage = "https://mne.tools/mne-bids" + pypi = "mne_bids/mne_bids-0.15.0.tar.gz" + git = "https://github.com/mne-tools/mne-bids" + + license("BSD-3-Clause") + + version("0.15.0", sha256="8a3ac7fb586ba2be70eb687c67ae060b42693078c56232180b27161124c22f72") + + variant("full", default=False, description="Enable full functionality.") + + depends_on("python@3.9:", type=("build", "run")) + depends_on("py-hatchling", type="build") + depends_on("py-hatch-vcs", type="build") + + depends_on("py-mne@1.5:", type=("build", "run")) + depends_on("py-numpy@1.21.2:", type=("build", "run")) + depends_on("py-scipy@1.7.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-mne/package.py b/var/spack/repos/builtin/packages/py-mne/package.py index e5fd29ebd51fa5..53edb8c9a5e31d 100644 --- a/var/spack/repos/builtin/packages/py-mne/package.py +++ b/var/spack/repos/builtin/packages/py-mne/package.py @@ -13,8 +13,11 @@ class PyMne(PythonPackage): pypi = "mne/mne-0.23.4.tar.gz" git = "https://github.com/mne-tools/mne-python.git" + maintainers("ChristopherChristofi") + license("BSD-3-Clause") + version("1.6.1", sha256="e4f5683d01cef675eddad788bdb6b44cc015dff0fb1ddfca3c4105edfb757ef8") version("1.4.2", sha256="dd2bf35a90d951bef15ff3a651045b0373eff26018a821667109c727d55c7d63") version("1.4.0", sha256="7834f5b79c2c9885ca601bbddd8db3c2b2f37c34443fc0caf0447751f6c37a2a") version("1.3.1", sha256="0d0626d3187dd0ee6f8740d054660a1b5fce4c879f814b745b13c5a587baf32b") @@ -33,14 +36,18 @@ class PyMne(PythonPackage): depends_on("py-setuptools-scm@6.2:", when="@1.4:", type="build") # requirements_base.txt with versions specified in README.rst (marked with *) + depends_on("py-numpy@1.21.2:", when="@1.6.1:", type=("build", "run")) depends_on("py-numpy@1.20.2:", when="@1.4:", type=("build", "run")) # * depends_on("py-numpy@1.18.1:", when="@1:", type=("build", "run")) # * depends_on("py-numpy@1.15.4:", when="@0.23:", type=("build", "run")) depends_on("py-numpy@1.11.3:", type=("build", "run")) + depends_on("py-numpy@:1", when="@:1.6", type=("build", "run")) + depends_on("py-scipy@1.7.1:", when="@1.6.1:", type=("build", "run")) depends_on("py-scipy@1.6.3:", when="@1.4:", type=("build", "run")) depends_on("py-scipy@1.4.1:", when="@1:", type=("build", "run")) # * depends_on("py-scipy@1.1.0:", when="@0.23:", type=("build", "run")) depends_on("py-scipy@0.17.1:", type=("build", "run")) + depends_on("py-matplotlib@3.5:", when="@1.6.1:", type=("build", "run")) depends_on("py-matplotlib@3.4:", when="@1:", type=("build", "run")) # * depends_on("py-matplotlib@3.1:", when="@1:", type=("build", "run")) # * depends_on("py-tqdm", when="@1:", type=("build", "run")) @@ -48,7 +55,11 @@ class PyMne(PythonPackage): depends_on("py-decorator", when="@1:", type=("build", "run")) depends_on("py-packaging", when="@1:", type=("build", "run")) depends_on("py-jinja2", when="@1:", type=("build", "run")) + depends_on( + "py-importlib-resources@5.10.2:", when="@1.6.1: ^python@:3.9", type=("build", "run") + ) depends_on("py-importlib-resources@5.10.2:", when="@1.4: ^python@:3.8", type=("build", "run")) + depends_on("py-lazy-loader@0.3:", when="@1.6.1:", type=("build", "run")) with when("+hdf5"): depends_on("py-h5io", type=("build", "run")) @@ -59,7 +70,6 @@ class PyMne(PythonPackage): depends_on("py-matplotlib@3.0.3:", type=("build", "run")) # * depends_on("py-pyqt5@5.10:,:5.15.1,5.15.4:", when="platform=linux", type=("build", "run")) depends_on("py-pyqt5@5.10:,:5.13", when="platform=darwin", type=("build", "run")) - depends_on("py-pyqt5@5.10:,:5.15.2,5.15.4:", when="platform=cray", type=("build", "run")) depends_on("py-pyqt5@5.10:,:5.15.2,5.15.4:", when="platform=win32", type=("build", "run")) depends_on("py-pyqt5-sip", type=("build", "run")) depends_on("py-sip", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-modin/package.py b/var/spack/repos/builtin/packages/py-modin/package.py index db594d0051f58f..b353982e1e0bd3 100644 --- a/var/spack/repos/builtin/packages/py-modin/package.py +++ b/var/spack/repos/builtin/packages/py-modin/package.py @@ -30,6 +30,8 @@ class PyModin(PythonPackage): depends_on("py-pandas@1.1.5", when="^python@:3.7", type=("build", "run")) depends_on("py-packaging", type=("build", "run")) depends_on("py-numpy@1.18.5:", type=("build", "run")) + # https://github.com/modin-project/modin/issues/7310 + depends_on("py-numpy@:1", when="@:0.30", type=("build", "run")) depends_on("py-fsspec", type=("build", "run")) depends_on("py-psutil", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-modules-gui/package.py b/var/spack/repos/builtin/packages/py-modules-gui/package.py new file mode 100644 index 00000000000000..f241e27d634a6a --- /dev/null +++ b/var/spack/repos/builtin/packages/py-modules-gui/package.py @@ -0,0 +1,25 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyModulesGui(PythonPackage): + """MoGui is a Graphical User Interface (GUI) for Environment Modules. + It helps users selecting modules to load and save module collections.""" + + homepage = "https://github.com/cea-hpc/mogui" + pypi = "modules-gui/modules-gui-0.2.tar.gz" + + maintainers("adrien-cotte") + + license("GPL-2.0") + + version("0.2", sha256="d58a3943f4631756afa4f84c13b70fae67a72365ab3cad28014f972b8d023aec") + + depends_on("py-setuptools@61:", type=("build")) + depends_on("py-setuptools-scm", type=("build")) + depends_on("py-pyqt5", type=("run")) + depends_on("environment-modules@5.2:", type=("run")) diff --git a/var/spack/repos/builtin/packages/py-morphio/package.py b/var/spack/repos/builtin/packages/py-morphio/package.py index 80705367d7fdc5..15f269967fb8da 100644 --- a/var/spack/repos/builtin/packages/py-morphio/package.py +++ b/var/spack/repos/builtin/packages/py-morphio/package.py @@ -15,12 +15,18 @@ class PyMorphio(PythonPackage): git = "https://github.com/BlueBrain/MorphIO.git" pypi = "morphio/MorphIO-3.3.2.tar.gz" - license("LGPL-3.0-or-later") + license("LGPL-3.0-or-later", when="@:3.3.6") + license("Apache-2.0", when="@3.3.7:") + + maintainers("tristan0x") version("master", branch="master", submodules=True) + version("3.3.7", sha256="7cb6676fcbaa2ac154742ca8aed3fcb03bb4643852e36e368858580133b61732") version("3.3.6", sha256="0f2e55470d92a3d89f2141ae905ee104fd16257b93dafb90682d90171de2f4e6") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@24.2:", type="build") depends_on("py-setuptools-scm", type="build") diff --git a/var/spack/repos/builtin/packages/py-mpi4py/package.py b/var/spack/repos/builtin/packages/py-mpi4py/package.py index 76e4891780a8e5..3045af9f5312e1 100644 --- a/var/spack/repos/builtin/packages/py-mpi4py/package.py +++ b/var/spack/repos/builtin/packages/py-mpi4py/package.py @@ -19,6 +19,7 @@ class PyMpi4py(PythonPackage): license("BSD-2-Clause") version("master", branch="master") + version("3.1.6", sha256="c8fa625e0f92b082ef955bfb52f19fa6691d29273d7d71135d295aa143dee6cb") version("3.1.5", sha256="a706e76db9255135c2fb5d1ef54cb4f7b0e4ad9e33cbada7de27626205f2a153") version("3.1.4", sha256="17858f2ebc623220d0120d1fa8d428d033dde749c4bc35b33d81a66ad7f93480") version("3.1.3", sha256="f1e9fae1079f43eafdd9f817cdb3fd30d709edc093b5d5dada57a461b2db3008") @@ -31,8 +32,13 @@ class PyMpi4py(PythonPackage): version("2.0.0", sha256="6543a05851a7aa1e6d165e673d422ba24e45c41e4221f0993fe1e5924a00cb81") version("1.3.1", sha256="e7bd2044aaac5a6ea87a87b2ecc73b310bb6efe5026031e33067ea3c2efc3507") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("py-setuptools@40.9:", type="build") - depends_on("py-cython@0.27:2", type="build") + depends_on("py-cython@0.27:2", when="@:3.1.6", type="build") + depends_on("py-cython@0.27:3", when="@master", type="build") depends_on("mpi") def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/py-mpmath/package.py b/var/spack/repos/builtin/packages/py-mpmath/package.py index f38a363292181d..9a10d0fb17bc11 100644 --- a/var/spack/repos/builtin/packages/py-mpmath/package.py +++ b/var/spack/repos/builtin/packages/py-mpmath/package.py @@ -14,10 +14,12 @@ class PyMpmath(PythonPackage): license("BSD-3-Clause") + version("1.3.0", sha256="7a28eb2a9774d00c7bc92411c19a89209d5da7c4c9a9e227be8330a23a25b91f") version("1.2.1", sha256="79ffb45cf9f4b101a807595bcb3e72e0396202e0b1d25d689134b48c4216a81a") version("1.1.0", sha256="fc17abe05fbab3382b61a123c398508183406fa132e0223874578e20946499f6") version("1.0.0", sha256="04d14803b6875fe6d69e6dccea87d5ae5599802e4b1df7997bddd2024001050c") version("0.19", sha256="68ddf6426dcda445323467d89892d2cffbbd1ae0b31ac1241b1b671749d63222") + depends_on("py-setuptools", type="build") depends_on("py-setuptools@36.7.0:", type="build", when="@1.2.0:") - depends_on("py-setuptools-scm@1.7.0:", type="build", when="@1.2.0:") + depends_on("py-setuptools-scm@1.7.0:", type="build", when="@1.2.0:1.2") diff --git a/var/spack/repos/builtin/packages/py-mrcfile/package.py b/var/spack/repos/builtin/packages/py-mrcfile/package.py index a07b505c57e310..833b730e5ac039 100644 --- a/var/spack/repos/builtin/packages/py-mrcfile/package.py +++ b/var/spack/repos/builtin/packages/py-mrcfile/package.py @@ -17,8 +17,10 @@ class PyMrcfile(PythonPackage): license("BSD-3-Clause") + version("1.4.3", sha256="0c2c702167c50c8b67e4ff7b1ec825a6bb60c0bff388950af08c79c5fd49e28b") version("1.3.0", sha256="034f1868abf87f4e494b8b039030b50045cabccf352b8b3e88a6bd3a6d665715") depends_on("python@3.4.0:") depends_on("py-setuptools", type="build") - depends_on("py-numpy@1.12.0:", type=("build", "run")) + depends_on("py-numpy@1.16.0:", when="@1.4.3:", type=("build", "run")) + depends_on("py-numpy@1.12.0:", when="@1.3.0", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-msgpack/package.py b/var/spack/repos/builtin/packages/py-msgpack/package.py index 44e6e84ec0db68..961e8d0a451c5e 100644 --- a/var/spack/repos/builtin/packages/py-msgpack/package.py +++ b/var/spack/repos/builtin/packages/py-msgpack/package.py @@ -26,6 +26,8 @@ class PyMsgpack(PythonPackage): version("0.6.1", sha256="734e1abc6f14671f28acd5266de336ae6d8de522fe1c8d0b7146365ad1fe6b0f") version("0.6.0", sha256="4478a5f68142414084cd43af8f21cef9619ad08bb3c242ea505330dade6ca9ea") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-setuptools@35.0.2:", when="@1.0.4:", type="build") depends_on("py-cython@0.29.30:0.29", when="@1.0.4:", type="build") diff --git a/var/spack/repos/builtin/packages/py-multidict/package.py b/var/spack/repos/builtin/packages/py-multidict/package.py index f37228dc1965e2..152becac958447 100644 --- a/var/spack/repos/builtin/packages/py-multidict/package.py +++ b/var/spack/repos/builtin/packages/py-multidict/package.py @@ -21,6 +21,8 @@ class PyMultidict(PythonPackage): version("5.1.0", sha256="25b4e5f22d3a37ddf3effc0710ba692cfc792c2b9edfb9c05aefe823256e84d5") version("4.7.6", sha256="fbb77a75e529021e7c4a8d4e823d88ef4d23674a202be4f5addffc72cbb91430") + depends_on("c", type="build") # generated + depends_on("py-setuptools@40:", type="build") # Historical dependencies diff --git a/var/spack/repos/builtin/packages/py-multiecho/package.py b/var/spack/repos/builtin/packages/py-multiecho/package.py index f1b5e7e8e16a6e..f9619d0abaa317 100644 --- a/var/spack/repos/builtin/packages/py-multiecho/package.py +++ b/var/spack/repos/builtin/packages/py-multiecho/package.py @@ -14,11 +14,16 @@ class PyMultiecho(PythonPackage): license("MIT") + version("0.29", sha256="df4860fe4478c162f976bdc4bdd2dc1c51ba2c33cb23658ac7218cf1597c4f0a") version("0.28", sha256="d0459bd03398547116d8e989b2d2b7922af0ae7ae77e233794dd7253a2abced3") - depends_on("python@3.6:3.9", type=("build", "run")) + depends_on("py-setuptools@62.2.0:", type="build", when="@0.29:") depends_on("py-setuptools", type="build") + depends_on("py-argparse-manpage+setuptools", type="build", when="@0.29:") depends_on("py-coloredlogs", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) depends_on("py-nibabel", type=("build", "run")) + + # Historical dependencies + depends_on("python@3.6:3.9", type=("build", "run"), when="@0.28") diff --git a/var/spack/repos/builtin/packages/py-multiqc/package.py b/var/spack/repos/builtin/packages/py-multiqc/package.py index 161d46cb356783..eb4d18e969907a 100644 --- a/var/spack/repos/builtin/packages/py-multiqc/package.py +++ b/var/spack/repos/builtin/packages/py-multiqc/package.py @@ -14,38 +14,45 @@ class PyMultiqc(PythonPackage): homepage = "https://multiqc.info" pypi = "multiqc/multiqc-1.0.tar.gz" - license("GPL-3.0-only") + license("GPL-3.0-only", checked_by="A_N_Other") + version("1.21", sha256="63bc87e251dbf788dcc8a45e58482ea09b26d05957bf50c77c684d5f0972a495") version("1.15", sha256="ce5359a12226cf4ce372c6fdad142cfe2ae7501ffa97ac7aab544ced4db5ea3c") version("1.14", sha256="dcbba405f0c9521ed2bbd7e8f7a9200643047311c9619878b81d167300149362") version("1.13", sha256="0564fb0f894e6ca0822a0f860941b3ed2c33dce407395ac0c2103775d45cbfa0") - version("1.7", sha256="02e6a7fac7cd9ed036dcc6c92b8f8bcacbd28983ba6be53afb35e08868bd2d68") - version("1.5", sha256="fe0ffd2b0d1067365ba4e54ae8991f2f779c7c684b037549b617020ea883310a") - version("1.3", sha256="cde17845680131e16521ace04235bb9496c78c44cdc7b5a0fb6fd93f4ad7a13b") - version("1.0", sha256="1a49331a3d3f2e591a6e9902bc99b16e9205731f0cd2d6eaeee0da3d0f0664c9") - depends_on("python@2.7:", when="@:1.7", type=("build", "run")) - depends_on("python@3:", when="@1.9:", type=("build", "run")) + # dependency defintions move from setup.py to pyproject.toml as of @1.21: + + # build deps depends_on("py-setuptools", type="build") - depends_on("py-matplotlib@2.1.1:", type=("build", "run"), when="@1.13:") - depends_on("py-matplotlib@2.1.1:2", type=("build", "run"), when="@1.7") - depends_on("py-matplotlib@:2.1.0", type=("build", "run"), when="@1.5") - depends_on("py-matplotlib", type=("build", "run"), when="@:1.3") - depends_on("py-networkx@2.5.1:", type=("build", "run"), when="@1.13:") - depends_on("py-networkx@:1", type=("build", "run"), when="@1.3") - depends_on("py-numpy", type=("build", "run")) + + # current run deps depends_on("py-click", type=("build", "run")) - depends_on("py-coloredlogs", type=("build", "run"), when="@1.13:") - depends_on("py-future@0.14.1:", type=("build", "run")) + depends_on("py-humanize", type=("build", "run"), when="@1.18:") + depends_on("py-importlib-metadata", type=("build", "run"), when="@1.16:") depends_on("py-jinja2@3.0.0:", type=("build", "run"), when="@1.14:") depends_on("py-jinja2@2.9:", type=("build", "run"), when="@:1.13") - depends_on("py-lzstring", type=("build", "run")) + depends_on("py-kaleido", type=("build", "run"), when="@1.20:") depends_on("py-markdown", type=("build", "run"), when="@1.3:") - depends_on("py-pyyaml", type=("build", "run")) - depends_on("py-pyyaml@4:", type=("build", "run"), when="@1.13:") + depends_on("py-matplotlib@2.1.1:", type=("build", "run"), when="@1.13:") + depends_on("py-numpy", type=("build", "run")) + depends_on("py-packaging", type=("build", "run"), when="@1.16:") depends_on("py-requests", type=("build", "run"), when="@1.3:") + depends_on("py-pillow@10:", type=("build", "run"), when="@1.20:") + depends_on("py-plotly@5.18:", type=("build", "run"), when="@1.21:") + depends_on("py-plotly", type=("build", "run"), when="@1.20") + depends_on("py-pyyaml@4:", type=("build", "run"), when="@1.13:") + depends_on("py-pyyaml", type=("build", "run")) + depends_on("py-pyaml-env", type=("build", "run"), when="@1.18:") depends_on("py-rich@10:", type=("build", "run"), when="@1.13:") depends_on("py-rich-click", type=("build", "run"), when="@1.13:") - depends_on("py-simplejson", type=("build", "run")) - depends_on("py-spectra@0.0.10:", type=("build", "run"), when="@1.5:") - depends_on("py-spectra", type=("build", "run")) + depends_on("py-coloredlogs", type=("build", "run"), when="@1.13:") + depends_on("py-spectra@0.0.10:", type=("build", "run"), when="@1.4:") + depends_on("py-spectra", type=("build", "run"), when="@1.18:") + + # retired run deps + depends_on("py-future@0.14.1:", type=("build", "run"), when="@1.13:1.19") + depends_on("py-lzstring", type=("build", "run"), when="@:1.16") + depends_on("py-networkx@2.5.1:", type=("build", "run"), when="@1.13:1.20") + depends_on("py-networkx@:1", type=("build", "run"), when="@1.3") + depends_on("py-simplejson", type=("build", "run"), when="@:1.15") diff --git a/var/spack/repos/builtin/packages/py-murmurhash/package.py b/var/spack/repos/builtin/packages/py-murmurhash/package.py index ecd8d65d1ea7af..fb4e74b0d6149e 100644 --- a/var/spack/repos/builtin/packages/py-murmurhash/package.py +++ b/var/spack/repos/builtin/packages/py-murmurhash/package.py @@ -17,5 +17,7 @@ class PyMurmurhash(PythonPackage): version("1.0.2", sha256="c7a646f6b07b033642b4f52ae2e45efd8b80780b3b90e8092a0cec935fbf81e2") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-wheel@0.32.0:0.32", type="build") diff --git a/var/spack/repos/builtin/packages/py-mx/package.py b/var/spack/repos/builtin/packages/py-mx/package.py index f247ea1b0ddc67..684903fadba57a 100644 --- a/var/spack/repos/builtin/packages/py-mx/package.py +++ b/var/spack/repos/builtin/packages/py-mx/package.py @@ -21,5 +21,7 @@ class PyMx(PythonPackage): version("3.2.8", sha256="0da55233e45bc3f88870e62e60a79c2c86bad4098b8128343fd7be877f44a3c0") + depends_on("c", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-mxfold2/package.py b/var/spack/repos/builtin/packages/py-mxfold2/package.py index 92df3ac7f2aa17..184247aef8c1fb 100644 --- a/var/spack/repos/builtin/packages/py-mxfold2/package.py +++ b/var/spack/repos/builtin/packages/py-mxfold2/package.py @@ -19,6 +19,8 @@ class PyMxfold2(PythonPackage): version("0.1.1", sha256="9f39c6ff4138212d1ad2639005f5c05ffb4df0f7e22f5e7ad49466a05aa047e5") + depends_on("cxx", type="build") # generated + depends_on("python@3.7:", type=("build", "run")) depends_on("py-torch@1.7:~valgrind", type=("build", "run")) depends_on("py-torchvision", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-myhdl/package.py b/var/spack/repos/builtin/packages/py-myhdl/package.py index 0b669e65294774..e0066613682f7e 100644 --- a/var/spack/repos/builtin/packages/py-myhdl/package.py +++ b/var/spack/repos/builtin/packages/py-myhdl/package.py @@ -17,5 +17,7 @@ class PyMyhdl(PythonPackage): version("0.9.0", sha256="52d12a5fe2cda22558806272af3c2b519b6f7095292b8e6c8ad255fb604507a5") + depends_on("c", type="build") # generated + depends_on("python@2.6:2.8,3.4:") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-mypy/package.py b/var/spack/repos/builtin/packages/py-mypy/package.py index 3c7164f651a355..7a6f438f7236bf 100644 --- a/var/spack/repos/builtin/packages/py-mypy/package.py +++ b/var/spack/repos/builtin/packages/py-mypy/package.py @@ -53,6 +53,9 @@ class PyMypy(PythonPackage): version("0.740", sha256="48c8bc99380575deb39f5d3400ebb6a8a1cb5cc669bbba4d3bb30f904e0a0e7d") version("0.670", sha256="e80fd6af34614a0e898a57f14296d0dacb584648f0339c2e000ddbf0f4cc2f8d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # pyproject.toml depends_on("py-setuptools@40.6.2:", when="@0.790:", type="build") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-mysql-connector-python/package.py b/var/spack/repos/builtin/packages/py-mysql-connector-python/package.py index 81f152e53b16cf..926d45d551c885 100644 --- a/var/spack/repos/builtin/packages/py-mysql-connector-python/package.py +++ b/var/spack/repos/builtin/packages/py-mysql-connector-python/package.py @@ -20,5 +20,8 @@ class PyMysqlConnectorPython(PythonPackage): version("8.0.13", sha256="d4c0834c583cdb90c0aeae90b1917d58355a4bf9b0266c16fd58874a5607f9d4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type=("build", "run")) depends_on("py-protobuf@3.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-mysqlclient/package.py b/var/spack/repos/builtin/packages/py-mysqlclient/package.py index c864f5a32ba63d..220be7e7d7fff0 100644 --- a/var/spack/repos/builtin/packages/py-mysqlclient/package.py +++ b/var/spack/repos/builtin/packages/py-mysqlclient/package.py @@ -22,5 +22,7 @@ class PyMysqlclient(PythonPackage): version("1.4.4", sha256="9c737cc55a5dc8dd3583a942d5a9b21be58d16f00f5fefca4e575e7d9682e98c") version("1.3.13", sha256="ff8ee1be84215e6c30a746b728c41eb0701a46ca76e343af445b35ce6250644f") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("mysql") diff --git a/var/spack/repos/builtin/packages/py-mysqldb1/package.py b/var/spack/repos/builtin/packages/py-mysqldb1/package.py index 8a332fa90f84b5..355aa30d9eaf3e 100644 --- a/var/spack/repos/builtin/packages/py-mysqldb1/package.py +++ b/var/spack/repos/builtin/packages/py-mysqldb1/package.py @@ -18,5 +18,7 @@ class PyMysqldb1(PythonPackage): url="https://github.com/farcepest/MySQLdb1/archive/MySQLdb-1.2.5.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("mysql@:6") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-namex/package.py b/var/spack/repos/builtin/packages/py-namex/package.py index de93e1e98c8748..4a5b73a0f39d0c 100644 --- a/var/spack/repos/builtin/packages/py-namex/package.py +++ b/var/spack/repos/builtin/packages/py-namex/package.py @@ -14,6 +14,7 @@ class PyNamex(PythonPackage): license("Apache-2.0") + version("0.0.8", sha256="32a50f6c565c0bb10aa76298c959507abdc0e850efe085dc38f3440fcb3aa90b") version("0.0.7", sha256="84ba65bc4d22bd909e3d26bf2ffb4b9529b608cb3f9a4336f776b04204ced69b") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-nanobind/package.py b/var/spack/repos/builtin/packages/py-nanobind/package.py index eaf5572a362273..5ea6ca685eb448 100644 --- a/var/spack/repos/builtin/packages/py-nanobind/package.py +++ b/var/spack/repos/builtin/packages/py-nanobind/package.py @@ -7,9 +7,7 @@ class PyNanobind(PythonPackage): - """nanobind -- Seamless operability between C++11 and Python. - - nanobind is a small binding library that exposes C++ types in + """nanobind is a small binding library that exposes C++ types in Python and vice versa. It is reminiscent of Boost.Python and pybind11 and uses near-identical syntax. In contrast to these existing tools, nanobind is more efficient: bindings compile in a shorter amount of time, @@ -25,6 +23,12 @@ class PyNanobind(PythonPackage): license("BSD-3-Clause") version("master", branch="master", submodules=True) + version( + "2.0.0", tag="v2.0.0", commit="8d7f1ee0621c17fa370b704b2100ffa0243d5bfb", submodules=True + ) + version( + "1.9.2", tag="v1.9.2", commit="80a30c8efb093b14f0e744bc7f6a9ef34beb3f7f", submodules=True + ) version( "1.8.0", tag="v1.8.0", commit="1a309ba444a47e081dc6213d72345a2fbbd20795", submodules=True ) @@ -50,14 +54,17 @@ class PyNanobind(PythonPackage): "1.2.0", tag="v1.2.0", commit="ec9350b805d2fe568f65746fd69225eedc5e37ae", submodules=True ) + depends_on("cxx", type="build") # generated + depends_on("python@3.8:", type=("build", "run")) depends_on("py-setuptools@42:", type="build") depends_on("py-scikit-build", type="build") + depends_on("py-typing-extensions", when="@2:", type="build") depends_on("cmake@3.17:", type="build") depends_on("ninja", type="build") @property def cmake_prefix_paths(self): - paths = [join_path(self.prefix, self.spec["python"].package.platlib, "nanobind", "cmake")] + paths = [join_path(python_platlib, "nanobind", "cmake")] return paths diff --git a/var/spack/repos/builtin/packages/py-natsort/package.py b/var/spack/repos/builtin/packages/py-natsort/package.py index d360b11b8efa7d..23c8499c556920 100644 --- a/var/spack/repos/builtin/packages/py-natsort/package.py +++ b/var/spack/repos/builtin/packages/py-natsort/package.py @@ -14,6 +14,8 @@ class PyNatsort(PythonPackage): license("MIT") + version("8.4.0", sha256="e42c6730e93382f743e09eb24b8d48034d81d089bd259183a88e2c4190e3db90") + version("8.2.0", sha256="0ce4562913d89a6f413fc68c9937cb0fc32be1268f73ac4b68e2646aeae458c6") version("7.1.1", sha256="ada96d9ca0db0d44b891718ff7baff5ac34cf5b6d9def356c0f7a8ea67ae2113") version("7.1.0", sha256="c3de32c8e5e91cf4f2dd1655b4c167ca4676cc28ce397050fc8d229582a71f0d") version("7.0.1", sha256="1a422a344d089f7a2acba788087ca6253ca47a544bda677721f99516cdfd8668") diff --git a/var/spack/repos/builtin/packages/py-neobolt/package.py b/var/spack/repos/builtin/packages/py-neobolt/package.py index 6cf9fd00b5533d..7cc399be5a77da 100644 --- a/var/spack/repos/builtin/packages/py-neobolt/package.py +++ b/var/spack/repos/builtin/packages/py-neobolt/package.py @@ -14,5 +14,7 @@ class PyNeobolt(PythonPackage): version("1.7.16", sha256="ca4e87679fe3ed39aec23638658e02dbdc6bbc3289a04e826f332e05ab32275d") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("python@2.7:2.8,3.4:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-neptune-client/package.py b/var/spack/repos/builtin/packages/py-neptune-client/package.py new file mode 100644 index 00000000000000..af0196746eb671 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-neptune-client/package.py @@ -0,0 +1,43 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyNeptuneClient(PythonPackage): + """ + Flexible metadata store for MLOps, built for research and + production teams that run a lot of experiments. + """ + + homepage = "https://neptune.ai/" + pypi = "neptune-client/neptune-client-0.16.7.tar.gz" + + version("0.16.7", sha256="9b8bf2f59cb6b7ed6d96ea221b68ea20d9d481a1a4672d8173648ef998134454") + version("0.16.1", sha256="821238f510486feacd87c745f4646916259a416545ab678b47195729c071f249") + + depends_on("python@3.7.0:", type=("build", "run")) + depends_on("py-setuptools", type="build") + + depends_on("py-versioneer", type="build") + depends_on("py-bravado", type=("build", "run")) + depends_on("py-click@7.0:", type=("build", "run")) + depends_on("py-future@0.17.1:", type=("build", "run")) + depends_on("py-oauthlib@2.1.0:", type=("build", "run")) + depends_on("py-pandas", type=("build", "run")) + depends_on("pil@1.1.6:", type=("build", "run")) + depends_on("py-pyjwt", type=("build", "run")) + depends_on("py-requests@2.20.0:", type=("build", "run")) + depends_on("py-requests-oauthlib@1.0.0:", type=("build", "run")) + depends_on("py-six@1.12.0:", type=("build", "run")) + depends_on("py-websocket-client@0.35:0,1.0.1:", type=("build", "run")) + depends_on("py-gitpython@2.0.8:", type=("build", "run")) + depends_on("py-boto3@1.16.0:", type=("build", "run")) + depends_on("py-packaging", type=("build", "run")) + depends_on("py-urllib3", type=("build", "run")) + depends_on("py-dataclasses@0.6:", when="^python@:3.6", type=("build", "run")) + depends_on("py-swagger-spec-validator@2.7.4:", type=("build", "run")) + depends_on("py-psutil", type=("build", "run")) + depends_on("py-jsonschema@:3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-nest-asyncio/package.py b/var/spack/repos/builtin/packages/py-nest-asyncio/package.py index 9cf65d6e334168..6bba7b02caf0dc 100644 --- a/var/spack/repos/builtin/packages/py-nest-asyncio/package.py +++ b/var/spack/repos/builtin/packages/py-nest-asyncio/package.py @@ -15,6 +15,9 @@ class PyNestAsyncio(PythonPackage): license("BSD-2-Clause") + version("1.6.0", sha256="6f172d5449aca15afd6c646851f4e31e02c598d553a667e38cafa997cfec55fe") + version("1.5.9", sha256="d1e1144e9c6e3e6392e0fcf5211cb1c8374b5648a98f1ebe48e5336006b41907") + version("1.5.8", sha256="25aa2ca0d2a5b5531956b9e273b45cf664cae2b145101d73b86b199978d48fdb") version("1.5.6", sha256="d267cc1ff794403f7df692964d1d2a3fa9418ffea2a3f6859a439ff482fef290") version("1.5.5", sha256="e442291cd942698be619823a17a86a5759eabe1f8613084790de189fe9e16d65") version("1.5.4", sha256="f969f6013a16fadb4adcf09d11a68a4f617c6049d7af7ac2c676110169a63abd") diff --git a/var/spack/repos/builtin/packages/py-netcdf4/package.py b/var/spack/repos/builtin/packages/py-netcdf4/package.py index 84a28e0f33ca65..e36ed870ea0073 100644 --- a/var/spack/repos/builtin/packages/py-netcdf4/package.py +++ b/var/spack/repos/builtin/packages/py-netcdf4/package.py @@ -35,6 +35,8 @@ class PyNetcdf4(PythonPackage): depends_on("py-numpy", when="@1.6.5:", type=("build", "link", "run")) depends_on("py-numpy@1.9:", when="@1.5.4:1.6.2", type=("build", "link", "run")) depends_on("py-numpy@1.7:", type=("build", "link", "run")) + # https://github.com/Unidata/netcdf4-python/pull/1317 + depends_on("py-numpy@:1", when="@:1.6", type=("build", "link", "run")) depends_on("py-mpi4py", when="+mpi", type=("build", "run")) depends_on("netcdf-c", when="-mpi") depends_on("netcdf-c+mpi", when="+mpi") @@ -48,6 +50,20 @@ class PyNetcdf4(PythonPackage): # following patch disables the usage of pkg-config at all. patch("disable_pkgconf.patch") + # https://github.com/Unidata/netcdf4-python/pull/1322 + patch( + "https://github.com/Unidata/netcdf4-python/commit/49dcd0b5bd25824c254770c0d41445133fc13a46.patch?full_index=1", + sha256="71eefe1d3065ad050fb72eb61d916ae1374a3fafd96ddaee6499cda952d992c4", + when="@1.6: %gcc@14:", + ) + + def flag_handler(self, name, flags): + if name == "cflags": + if self.spec.satisfies("%oneapi"): + flags.append("-Wno-error=int-conversion") + + return flags, None, None + def setup_build_environment(self, env): """Ensure installed netcdf and hdf5 libraries are used""" # Explicitly set these variables so setup.py won't erroneously pick up diff --git a/var/spack/repos/builtin/packages/py-netifaces/package.py b/var/spack/repos/builtin/packages/py-netifaces/package.py index 5cf1394c7bb0b2..fb8096d1e2afb2 100644 --- a/var/spack/repos/builtin/packages/py-netifaces/package.py +++ b/var/spack/repos/builtin/packages/py-netifaces/package.py @@ -18,4 +18,6 @@ class PyNetifaces(PythonPackage): version("0.10.5", sha256="59d8ad52dd3116fcb6635e175751b250dc783fb011adba539558bd764e5d628b") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-netket/package.py b/var/spack/repos/builtin/packages/py-netket/package.py index 02f83773298118..a8322db54fc821 100644 --- a/var/spack/repos/builtin/packages/py-netket/package.py +++ b/var/spack/repos/builtin/packages/py-netket/package.py @@ -26,9 +26,11 @@ class PyNetket(PythonPackage): version("1.0.3", sha256="b8e54d7ad8b379b740def640d748c6560943aed473755389fc5cf1020b9007de") version("1.0.2", sha256="229c906e92a432bbbd0ff0527874f41318f8fc480d12a33c8184f30960ae628b") + depends_on("cxx", type="build") # generated + # build only deps depends_on("py-setuptools", type="build") - depends_on("py-cmake@3.12:", type="build") + depends_on("cmake@3.12:", type="build") depends_on("blas") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/py-networkit/package.py b/var/spack/repos/builtin/packages/py-networkit/package.py index 283ba61173980c..4f360c448495ee 100644 --- a/var/spack/repos/builtin/packages/py-networkit/package.py +++ b/var/spack/repos/builtin/packages/py-networkit/package.py @@ -31,6 +31,8 @@ class PyNetworkit(PythonPackage): version("7.0", sha256="eea4b5e565d6990b674e1c7f4d598be9377d57b61d0d82883ecc39edabaf3631") version("6.1", sha256="f7fcb50dec66a8253f85c10ff9314100de013c7578d531c81d3f71bc6cf8f093") + depends_on("cxx", type="build") # generated + # Required dependencies depends_on("cmake", type="build") depends_on("libnetworkit@9.0", type=("build", "link"), when="@9.0") diff --git a/var/spack/repos/builtin/packages/py-networkx/package.py b/var/spack/repos/builtin/packages/py-networkx/package.py index 09d123e0a36c3b..c8bf1ac0f93147 100644 --- a/var/spack/repos/builtin/packages/py-networkx/package.py +++ b/var/spack/repos/builtin/packages/py-networkx/package.py @@ -50,6 +50,8 @@ class PyNetworkx(PythonPackage): # From requirements/default.txt depends_on("py-numpy@1.20:", when="@3:", type=("build", "run")) depends_on("py-numpy@1.19:", when="@2.8.6:", type=("build", "run")) + # https://github.com/networkx/networkx/pull/7390 + depends_on("py-numpy@:1", when="@:3.2", type=("build", "run")) depends_on("py-scipy@1.8:", when="@2.8.6:", type=("build", "run")) depends_on("py-matplotlib@3.4:", when="@2.8.6:", type=("build", "run")) depends_on("py-pandas@1.3:", when="@2.8.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-nibabel/package.py b/var/spack/repos/builtin/packages/py-nibabel/package.py index 382e95ac3bb114..6b17213491e89c 100644 --- a/var/spack/repos/builtin/packages/py-nibabel/package.py +++ b/var/spack/repos/builtin/packages/py-nibabel/package.py @@ -13,8 +13,12 @@ class PyNibabel(PythonPackage): pypi = "nibabel/nibabel-3.2.1.tar.gz" git = "https://github.com/nipy/nibabel" - license("PDDL-1.0") + maintainers("ChristopherChristofi") + # As detailed: https://nipy.org/nibabel/legal.html + license("MIT AND BSD-3-Clause AND PSF-2.0 AND PDDL-1.0") + + version("5.2.1", sha256="b6c80b2e728e4bc2b65f1142d9b8d2287a9102a8bf8477e115ef0d8334559975") version("5.1.0", sha256="ce73ca5e957209e7219a223cb71f77235c9df2acf4d3f27f861ba38e9481ac53") version("4.0.2", sha256="45c49b5349351b45f6c045a91aa02b4f0d367686ff3284632ef95ac65b930786") version("3.2.2", sha256="b0dcc174b30405ce9e8fec1eab3cbbb20f5c5e4920976c08b22e050b7c124f94") @@ -26,12 +30,14 @@ class PyNibabel(PythonPackage): depends_on("py-hatchling", when="@5:", type="build") depends_on("py-hatch-vcs", when="@5:", type="build") + depends_on("py-numpy@1.20:", when="@5.2.1:", type=("build", "run")) depends_on("py-numpy@1.19:", when="@5:", type=("build", "run")) depends_on("py-numpy@1.17:", when="@4:", type=("build", "run")) depends_on("py-numpy@1.14:", when="@3.2:", type=("build", "run")) depends_on("py-numpy@1.8:", type=("build", "run")) depends_on("py-packaging@17:", when="@4:", type=("build", "run")) depends_on("py-packaging@14.3:", when="@3.1:", type=("build", "run")) + depends_on("py-importlib-resources@1.3:", when="@5.2.1: ^python@:3.9", type=("build", "run")) depends_on("py-importlib-resources@1.3:", when="@5.1: ^python@:3.8", type=("build", "run")) depends_on("py-pytest", type="test") diff --git a/var/spack/repos/builtin/packages/py-nilearn/package.py b/var/spack/repos/builtin/packages/py-nilearn/package.py index b98c4bc7497af7..ea5884fa6bea1d 100644 --- a/var/spack/repos/builtin/packages/py-nilearn/package.py +++ b/var/spack/repos/builtin/packages/py-nilearn/package.py @@ -13,6 +13,11 @@ class PyNilearn(PythonPackage): pypi = "nilearn/nilearn-0.7.1.tar.gz" git = "https://github.com/nilearn/nilearn" + maintainers("ChristopherChristofi") + + license("BSD") + + version("0.10.3", sha256="77819331314c4ca5c15c07634f69f855fafdf9add051b1882e3a600ad52757d8") version("0.10.1", sha256="928a364e7ed77d15d02b7f227197ea7c78f44f2fe780feb555d6d7cf9232f846") version("0.10.0", sha256="cc7f1068e038076527ead1bd363436f88f5e8d21e8bb57b323b30b926fc7553a") version("0.9.2", sha256="8da8d3835d92cd7b8a6cc92455a489d7e7f5994cf64fc71bce653e362773b9e4") @@ -23,8 +28,6 @@ class PyNilearn(PythonPackage): version("0.6.2", sha256="cfc6cfda59a6f4247189f8ccf92e364de450460a15c0ec21bdb857c420dd198c") version("0.4.2", sha256="5049363eb6da2e7c35589477dfc79bf69929ca66de2d7ed2e9dc07acf78636f4") - depends_on("python@3.7:", when="@0.10:", type=("build", "run")) - depends_on("py-hatchling", when="@0.10.1:", type="build") depends_on("py-hatch-vcs", when="@0.10.1:", type="build") depends_on("py-setuptools", when="@:0.10.0", type="build") @@ -36,6 +39,7 @@ class PyNilearn(PythonPackage): depends_on("py-joblib@0.12:", when="@0.7:", type=("build", "run")) depends_on("py-joblib@0.11:", when="@0.6:", type=("build", "run")) depends_on("py-lxml", when="@0.9.1:", type=("build", "run")) + depends_on("py-nibabel@4.0.0:", when="@0.10.3:", type=("build", "run")) depends_on("py-nibabel@3.2:", when="@0.10:", type=("build", "run")) depends_on("py-nibabel@3:", when="@0.9.1:", type=("build", "run")) depends_on("py-nibabel@2.5:", when="@0.8:", type=("build", "run")) @@ -60,6 +64,7 @@ class PyNilearn(PythonPackage): # older py-nilearn versions use import sklearn.external.joblib which was # deprecated in py-scikit-learn@0.23: depends_on("py-scikit-learn@0.15:0.22", when="@:0.5", type=("build", "run")) + depends_on("py-scipy@1.8:", when="@0.10.3:", type=("build", "run")) depends_on("py-scipy@1.6:", when="@0.10:", type=("build", "run")) depends_on("py-scipy@1.5:", when="@0.9.1:", type=("build", "run")) depends_on("py-scipy@1.2:", when="@0.8:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-ninja/package.py b/var/spack/repos/builtin/packages/py-ninja/package.py index db6cbd2417117a..5153281d74db92 100644 --- a/var/spack/repos/builtin/packages/py-ninja/package.py +++ b/var/spack/repos/builtin/packages/py-ninja/package.py @@ -9,14 +9,21 @@ class PyNinja(PythonPackage): - """Ninja is a small build system with a focus on speed.""" + """Ninja is a small build system with a focus on speed. + + Deprecated: use ninja instead. + """ homepage = "https://ninja-build.org" pypi = "ninja/ninja-1.10.2.tar.gz" license("Apache-2.0") - version("1.10.2", sha256="bb5e54b9a7343b3a8fc6532ae2c169af387a45b0d4dd5b72c2803e21658c5791") + version( + "1.10.2", + sha256="bb5e54b9a7343b3a8fc6532ae2c169af387a45b0d4dd5b72c2803e21658c5791", + deprecated=True, + ) depends_on("cmake@3.6:", type="build") depends_on("py-setuptools@42:", type="build") diff --git a/var/spack/repos/builtin/packages/py-nodeenv/package.py b/var/spack/repos/builtin/packages/py-nodeenv/package.py index ef8028d21f7b3b..6fddf220e42358 100644 --- a/var/spack/repos/builtin/packages/py-nodeenv/package.py +++ b/var/spack/repos/builtin/packages/py-nodeenv/package.py @@ -16,5 +16,6 @@ class PyNodeenv(PythonPackage): version("1.7.0", sha256="e0e7f7dfb85fc5394c6fe1e8fa98131a2473e04311a45afb6508f7cf1836fa2b") version("1.3.3", sha256="ad8259494cf1c9034539f6cced78a1da4840a4b157e23640bc4a0c0546b0cb7a") + depends_on("python +ssl", when="@1.5:", type=("build", "run")) depends_on("py-setuptools", when="@1.7:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-nuitka/package.py b/var/spack/repos/builtin/packages/py-nuitka/package.py new file mode 100644 index 00000000000000..c51300eafd9102 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-nuitka/package.py @@ -0,0 +1,27 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyNuitka(PythonPackage): + """Nuitka is the Python compiler. It is written in Python. It is a + seamless replacement or extension to the Python interpreter and + compiles every construct that Python has, when itself run with that + Python version.""" + + homepage = "https://nuitka.net/" + pypi = "Nuitka/Nuitka-2.2.1.tar.gz" + git = "https://github.com/Nuitka/Nuitka.git" + + license("Apache-2.0") + + version("2.2.1", sha256="7bf67e80f94c93017fbaacfe1e277b92422d234a3c849a1555e43848f5fb27a1") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + depends_on("py-setuptools", type="build") + depends_on("py-ordered-set", type="build") diff --git a/var/spack/repos/builtin/packages/py-numba/package.py b/var/spack/repos/builtin/packages/py-numba/package.py index 2b5b29bba384ea..edab57b2c30980 100644 --- a/var/spack/repos/builtin/packages/py-numba/package.py +++ b/var/spack/repos/builtin/packages/py-numba/package.py @@ -28,6 +28,9 @@ class PyNumba(PythonPackage): version("0.50.1", sha256="89e81b51b880f9b18c82b7095beaccc6856fcf84ba29c4f0ced42e4e5748a3a7") version("0.48.0", sha256="9d21bc77e67006b5723052840c88cc59248e079a907cc68f1a1a264e1eaba017") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("tbb", default=False, description="Build with Intel Threading Building Blocks") depends_on("python@3.8:3.11", when="@0.57:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-numcodecs/package.py b/var/spack/repos/builtin/packages/py-numcodecs/package.py index 5414661794c0a9..b81a9b4e4a4c60 100644 --- a/var/spack/repos/builtin/packages/py-numcodecs/package.py +++ b/var/spack/repos/builtin/packages/py-numcodecs/package.py @@ -27,6 +27,8 @@ class PyNumcodecs(PythonPackage): version("0.7.3", sha256="022b12ad83eb623ec53f154859d49f6ec43b15c36052fa864eaf2d9ee786dd85") version("0.6.4", sha256="ef4843d5db4d074e607e9b85156835c10d006afc10e175bda62ff5412fca6e4d") + depends_on("c", type="build") # generated + variant("msgpack", default=False, description="Codec to encode data as msgpacked bytes.") depends_on("python@3.8:", when="@0.11:", type=("build", "link", "run")) @@ -37,6 +39,8 @@ class PyNumcodecs(PythonPackage): depends_on("py-setuptools-scm@1.5.5: +toml", type="build") depends_on("py-cython", type="build") depends_on("py-numpy@1.7:", type=("build", "run")) + # https://github.com/zarr-developers/numcodecs/issues/521 + depends_on("py-numpy@:1", when="@:0.12.0", type=("build", "run")) depends_on("py-py-cpuinfo", when="@0.11:", type="build") depends_on("py-entrypoints", when="@0.10.1:0.11", type=("build", "run")) depends_on("py-msgpack", type=("build", "run"), when="+msgpack") diff --git a/var/spack/repos/builtin/packages/py-numexpr/package.py b/var/spack/repos/builtin/packages/py-numexpr/package.py index 9e340b58fc90ea..adb2f75115b62e 100644 --- a/var/spack/repos/builtin/packages/py-numexpr/package.py +++ b/var/spack/repos/builtin/packages/py-numexpr/package.py @@ -14,6 +14,8 @@ class PyNumexpr(PythonPackage): license("MIT") + version("2.9.0", sha256="4df4163fcab20030137e8f2aa23e88e1e42e6fe702387cfd95d7675e1d84645e") + version("2.8.8", sha256="10b377c6ec6d9c01349d00e16dd82e6a6f4439c8c2b1945e490df1436c1825f5") version("2.8.4", sha256="0e21addd25db5f62d60d97e4380339d9c1fb2de72c88b070c279776ee6455d10") version("2.8.3", sha256="389ceefca74eff30ec3fd03fc4c3b7ab3df8f22d1f235117a392ce702ed208c0") version("2.7.3", sha256="00d6b1518605afe0ed10417e0ff07123e5d531c02496c6eed7dd4b9923238e1e") @@ -25,12 +27,18 @@ class PyNumexpr(PythonPackage): version("2.5", sha256="4ca111a9a27c9513c2e2f5b70c0a84ea69081d7d8e4512d4c3f26a485292de0d") version("2.4.6", sha256="2681faf55a3f19ba4424cc3d6f0a10610ebd49f029f8453f0ba64dd5c0fe4e0f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.7:", when="@2.8.3:", type=("build", "run")) + depends_on("python@3.9:", when="@2.8.7:", type=("build", "run")) depends_on("py-setuptools", type="build") - depends_on("py-numpy@1.13.3:", type=("build", "run"), when="@2.8.3:") + depends_on("py-numpy@1.13.3:1.25", type=("build", "run"), when="@2.8.3:") # https://github.com/pydata/numexpr/issues/397 depends_on("py-numpy@1.7:1.22", type=("build", "run"), when="@:2.7") + # https://github.com/pydata/numexpr/pull/478 + depends_on("py-numpy@:1", when="@:2.9", type=("build", "run")) # Historical dependencies depends_on("py-packaging", type=("build", "run"), when="@2.8.3") diff --git a/var/spack/repos/builtin/packages/py-numexpr3/package.py b/var/spack/repos/builtin/packages/py-numexpr3/package.py index 5162eca2a3d6d7..478ec2c5cb77f3 100644 --- a/var/spack/repos/builtin/packages/py-numexpr3/package.py +++ b/var/spack/repos/builtin/packages/py-numexpr3/package.py @@ -24,6 +24,9 @@ class PyNumexpr3(PythonPackage): license("BSD-3-Clause") version("3.0.1a1", sha256="de06f1b4206704b5bc19ea09b5c94350b97c211c26bc866f275252a8461b87e6") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated # TODO: Add CMake build system for better control of passing flags related # to CPU ISA. diff --git a/var/spack/repos/builtin/packages/py-numpy-quaternion/package.py b/var/spack/repos/builtin/packages/py-numpy-quaternion/package.py index fffb983756b84c..e7e7e1a60a3c59 100644 --- a/var/spack/repos/builtin/packages/py-numpy-quaternion/package.py +++ b/var/spack/repos/builtin/packages/py-numpy-quaternion/package.py @@ -26,6 +26,8 @@ class PyNumpyQuaternion(PythonPackage): sha256="b0dc670b2adc8ff2fb8d6105a48769873f68d6ccbe20af6a19e899b1e8d48aaf", ) + depends_on("c", type="build") # generated + variant("scipy", default=True, description="Build with scipy support") variant("numba", default=True, description="Build with numba support") diff --git a/var/spack/repos/builtin/packages/py-numpy-stl/package.py b/var/spack/repos/builtin/packages/py-numpy-stl/package.py index 827b52416214d2..559fa83fd47726 100644 --- a/var/spack/repos/builtin/packages/py-numpy-stl/package.py +++ b/var/spack/repos/builtin/packages/py-numpy-stl/package.py @@ -17,6 +17,8 @@ class PyNumpyStl(PythonPackage): version("3.0.0", sha256="578b78eacb0529ac9aba2f17dcc363d58c7c3c5708710c18f8c1e9965f2e81ac") version("2.10.1", sha256="f6b529b8a8112dfe456d4f7697c7aee0aca62be5a873879306afe4b26fca963c") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-numpy/package.py b/var/spack/repos/builtin/packages/py-numpy/package.py index c63ea665f2bfdb..02fc694df90743 100644 --- a/var/spack/repos/builtin/packages/py-numpy/package.py +++ b/var/spack/repos/builtin/packages/py-numpy/package.py @@ -22,6 +22,8 @@ class PyNumpy(PythonPackage): license("BSD-3-Clause") version("main", branch="main") + version("2.0.1", sha256="485b87235796410c3519a699cfe1faab097e509e90ebb05dcd098db2ae87e7b3") + version("2.0.0", sha256="cf5d1c9e6837f8af9f92b6bd3e86d513cdc11f60fd62185cc49ec7d1aba34864") version("1.26.4", sha256="2a02aba9ed12e4ac4eb3ea9421c420301a0c6460d9830d74a9df87efa4912010") version("1.26.3", sha256="697df43e2b6310ecc9d95f05d5ef20eacc09c7c4ecc9da3f235d39e71b7da1e4") version("1.26.2", sha256="f65738447676ab5777f11e6bbbdb8ce11b785e105f690bc45966574816b6d3ea") @@ -73,45 +75,55 @@ class PyNumpy(PythonPackage): version("1.17.4", sha256="f58913e9227400f1395c7b800503ebfdb0772f1c33ff8cb4d6451c06cabdf316") version("1.17.3", sha256="a0678793096205a4d784bd99f32803ba8100f639cf3b932dc63b21621390ea7e") + depends_on("c", type="build") + depends_on("cxx", type="build") + # Based on PyPI wheel availability - depends_on("python@3.9:3.12", when="@1.26:", type=("build", "link", "run")) - depends_on("python@3.9:3.11", when="@1.25", type=("build", "link", "run")) - depends_on("python@3.8:3.11", when="@1.23.2:1.24", type=("build", "link", "run")) - depends_on("python@3.8:3.10", when="@1.22:1.23.1", type=("build", "link", "run")) - depends_on("python@:3.10", when="@1.21.2:1.21", type=("build", "link", "run")) - depends_on("python@:3.9", when="@1.19.3:1.21.1", type=("build", "link", "run")) - depends_on("python@:3.8", when="@1.17.3:1.19.2", type=("build", "link", "run")) - - # Required to use --config-settings - depends_on("py-pip@23.1:", when="@1.26:", type="build") - - # Build dependencies (do not include upper bound unless known issues) - depends_on("py-cython@0.29.34:", when="@1.26:", type="build") - depends_on("py-cython@0.29.34:2", when="@1.25", type="build") - depends_on("py-cython@0.29.30:2", when="@1.22.4:1.24", type="build") - depends_on("py-cython@0.29.24:2", when="@1.21.2:1.22.3", type="build") - depends_on("py-cython@0.29.21:2", when="@1.19.1:1.21.1", type="build") - depends_on("py-cython@0.29.14:2", when="@1.18.1:1.19.0", type="build") - depends_on("py-cython@0.29.13:2", when="@1.18.0", type="build") - depends_on("py-meson-python@0.15:", when="@1.26.4:", type="build") + with default_args(type=("build", "link", "run")): + depends_on("python@3.9:3.12", when="@1.26:") + depends_on("python@3.9:3.11", when="@1.25") + depends_on("python@3.8:3.11", when="@1.23.2:1.24") + depends_on("python@3.8:3.10", when="@1.22:1.23.1") + depends_on("python@:3.10", when="@1.21.2:1.21") + depends_on("python@:3.9", when="@1.19.3:1.21.1") + depends_on("python@:3.8", when="@1.17.3:1.19.2") + + with default_args(type="build"): + # Required to use --config-settings + depends_on("py-pip@23.1:", when="@1.26:") + + # Build dependencies (do not include upper bound unless known issues) + depends_on("py-cython@3.0.6:", when="@2:") + depends_on("py-cython@0.29.34:", when="@1.26:") + depends_on("py-cython@0.29.34:2", when="@1.25") + depends_on("py-cython@0.29.30:2", when="@1.22.4:1.24") + depends_on("py-cython@0.29.24:2", when="@1.21.2:1.22.3") + depends_on("py-cython@0.29.21:2", when="@1.19.1:1.21.1") + depends_on("py-cython@0.29.14:2", when="@1.18.1:1.19.0") + depends_on("py-cython@0.29.13:2", when="@1.18.0") + depends_on("py-meson-python@0.15:", when="@1.26.4:") depends_on("blas") depends_on("lapack") # test_requirements.txt - depends_on("py-pytest", type="test") - depends_on("py-hypothesis", when="@1.19:", type="test") - depends_on("py-typing-extensions@4.2:", when="@1.23:", type="test") + with default_args(type="test"): + depends_on("py-pytest") + depends_on("py-hypothesis", when="@1.19:") + depends_on("py-typing-extensions@4.2:", when="@1.23:") # Historical dependencies - depends_on("py-pyproject-metadata@0.7.1:", when="@1.26.0:1.26.3", type="build") - depends_on("py-tomli@1:", when="@1.26.0:1.26.3 ^python@:3.10", type="build") - depends_on("py-setuptools@60:", when="@1.26.0:1.26.3 ^python@3.12:", type="build") - depends_on("py-setuptools@:63", when="@:1.25", type=("build", "run")) - depends_on("py-setuptools@:59", when="@:1.22.1", type=("build", "run")) - depends_on("py-colorama", when="@1.26.0:1.26.3 platform=windows", type="build") - depends_on("ninja@1.8.2:", when="@1.26.0:1.26.3", type="build") - depends_on("pkgconfig", when="@1.26.0:1.26.3", type="build") + with default_args(type="build"): + depends_on("py-pyproject-metadata@0.7.1:", when="@1.26.0:1.26.3") + depends_on("py-tomli@1:", when="@1.26.0:1.26.3 ^python@:3.10") + depends_on("py-setuptools@60:", when="@1.26.0:1.26.3 ^python@3.12:") + depends_on("py-colorama", when="@1.26.0:1.26.3 platform=windows") + depends_on("ninja@1.8.2:", when="@1.26.0:1.26.3") + depends_on("pkgconfig", when="@1.26.0:1.26.3") + + with default_args(type=("build", "run")): + depends_on("py-setuptools@:63", when="@:1.25") + depends_on("py-setuptools@:59", when="@:1.22.1") # Add Fujitsu Fortran compiler patch("add_fj_compiler.patch", when="@1.19.3:1.19.5%fj") @@ -167,6 +179,8 @@ class PyNumpy(PythonPackage): # See https://github.com/numpy/numpy/issues/22011 conflicts("%intel", when="@1.23.0:1.23.3") conflicts("%oneapi", when="@1.23.0:1.23.3") + # https://github.com/spack/spack/pull/44735 + conflicts("%oneapi", when="@2:") @property def archive_files(self): @@ -394,9 +408,14 @@ def set_blas_lapack(self): @when("@1.26:") def setup_build_environment(self, env): - # https://github.com/scipy/scipy/issues/19357 if self.spec.satisfies("%apple-clang@15:"): + # https://github.com/scipy/scipy/issues/19357 env.append_flags("LDFLAGS", "-Wl,-ld_classic") + elif self.spec.satisfies("%msvc"): + # For meson build system, compiler paths must be in quotes + # to prevent paths from being split by spaces. + env.set("CC", f'"{self.compiler.cc}"') + env.set("CXX", f'"{self.compiler.cxx}"') @when("@:1.25") def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/py-nvidia-dali/package.py b/var/spack/repos/builtin/packages/py-nvidia-dali/package.py index fb844e65723116..d43371b80db941 100644 --- a/var/spack/repos/builtin/packages/py-nvidia-dali/package.py +++ b/var/spack/repos/builtin/packages/py-nvidia-dali/package.py @@ -16,162 +16,187 @@ class PyNvidiaDali(PythonPackage): homepage = "https://developer.nvidia.com/dali" url = "https://developer.download.nvidia.com/compute/redist/" - skip_version_audit = ["platform=darwin"] + skip_version_audit = ["platform=darwin", "platform=windows"] maintainers("thomas-bouvier") system = platform.system().lower() arch = platform.machine() if "linux" in system and arch == "x86_64": + version( + "1.36.0-cuda120", + sha256="9a7754aacb245785462592aec89cbaec72e0a84d84399a061a563546bbf44805", + preferred=True, + url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.36.0-13435171-py3-none-manylinux2014_x86_64.whl", + expand=False, + ) + version( + "1.36.0-cuda110", + sha256="aa0e4a6def4b25ec1110e3488b020bc9997e0fde376a123e0b6414fc16684673", + url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.36.0-13435172-py3-none-manylinux2014_x86_64.whl", + expand=False, + ) version( "1.27.0-cuda120", sha256="d8def4361bd9f888ddac3e2316b9eb89ee216f280c0973be12b8e1061d1ff108", - expand=False, - preferred=True, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.27.0-8625314-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.27.0-cuda110", sha256="9edf5097787cb1bbbbabc291d814bf367c5f5a986cffa101205fe31c86418a66", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.27.0-8625303-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.26.0-cuda120", sha256="784dbad4e4e1399b4d2f51bfa1a01e3e23f6fb37e8f327cf136df9c1b5fb8470", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.26.0-8269288-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.26.0-cuda110", sha256="545b56c104def627d6c2ead747875eaadba2e12610850b4480f718dc3e8a9177", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.26.0-8269290-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.25.0-cuda120", sha256="72591f0db9fe6dd82035b2b6cc41aed478e48656ba99e81344a9cb59123710aa", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.25.0-7922358-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.25.0-cuda110", sha256="9901cfa0f67674e5d2b77dbd90d3506b42390d12fc5996593fd395c0370ea46f", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.25.0-7922357-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.24.0-cuda120", sha256="f280fba3e917a0c47e705fa488c6d53e5c50629b3664fe6cf95d0913213f3b13", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.24.0-7582307-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.24.0-cuda110", sha256="5988317a5f17fdefa9254bebb6f8dc344c2b0bd958badf6688172e537d324d60", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.24.0-7582302-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.23.0-cuda120", sha256="d10a14074df6cdd38adb1181785372ab8ace677323fdf62d2bc07e28a8469ef0", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.23.0-7355174-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.23.0-cuda110", sha256="ede8245d3f7df181abdc5c5109a79be1ba9b6d888ca9f693f62db2c95efad267", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.23.0-7355173-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.22.0-cuda120", sha256="6cbd9e3139d4c203f61f960f5ad1fc4b461621a60b7fa7ef0ba6d77c780b35f4", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.22.0-6971317-py3-none-manylinux2014_x86_64.whl", + expand=False, ) version( "1.22.0-cuda110", sha256="8c3ccc7eddc1f63d3f858448c5c384ab129273e0c140e091aca2a98d48c5a80c", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.22.0-6988993-py3-none-manylinux2014_x86_64.whl", + expand=False, ) elif "linux" in system and arch == "aarch64": + version( + "1.36.0-cuda120", + sha256="575ae1ff9b7633c847182163e2d339f2bdafe8dd0ca4ca6e3092a02890f803c2", + preferred=True, + url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.36.0-13435171-py3-none-manylinux2014_aarch64.whl", + expand=False, + ) + version( + "1.36.0-cuda110", + sha256="505301223134b7efd8522a949f9b33725701579a775c9abcdd8b11f1118cec3a", + url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.36.0-13435172-py3-none-manylinux2014_aarch64.whl", + expand=False, + ) version( "1.27.0-cuda120", sha256="57700656c4dd411497d3f8c690d409c71d6a8e9c2cc5e70499098dd0a01fd56b", - expand=False, - preferred=True, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.27.0-8625314-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.27.0-cuda110", sha256="8c28429f979c3fcb45f40f08efdae4b6ed3f4743634d41722a6c94d18c4cd995", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.27.0-8625303-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.26.0-cuda120", sha256="9672969cab3d1a009b9e2bf3b139aec06af46f67a45a128098f8279736848079", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.26.0-8269288-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.26.0-cuda110", sha256="e90fcb896cc0ee22a0fa5476a8fde8227412683796367334636c3f844e208975", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.26.0-8269290-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.25.0-cuda120", sha256="f497ce8bf0df83e5c72b393a621d910bc712c6cdc4bbba6db50cf1cbc47d881b", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.25.0-7922358-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.25.0-cuda110", sha256="2eb94223ac980658606af6a56720ce963f4fd877c1291d08517f82ce435b4155", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.25.0-7922357-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.24.0-cuda120", sha256="2a7fab1d94b23edde1cee5b93918aca6b86417e3ffb4544adcb9961c73375014", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.24.0-7582307-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.24.0-cuda110", sha256="84711689dacc787dfd90bfc66da7ce4b1884a006b763109e9ecf0b07aefacbc2", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.24.0-7582302-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.23.0-cuda120", sha256="911d16b40c95b8cc700d3c96b40d3144953e7ffbb191ec22a75990c76cf638c3", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.23.0-7355174-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.23.0-cuda110", sha256="ca58f2990825d18736c872f48d3f5e5dbda8de136ab6339f1f9f6984d7b3dffe", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.23.0-7355173-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.22.0-cuda120", sha256="5e496eebeba3bc1cddd18e081c8c45121283478931cbe9b64912d2394d0942ca", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda120/nvidia_dali_cuda120-1.22.0-6971317-py3-none-manylinux2014_aarch64.whl", + expand=False, ) version( "1.22.0-cuda110", sha256="0da47629fec01abf418fda0eeb393998820e40f6fae6b4c7d3e625aa4cdba6bd", - expand=False, url="https://developer.download.nvidia.com/compute/redist/nvidia-dali-cuda110/nvidia_dali_cuda110-1.22.0-6988993-py3-none-manylinux2014_aarch64.whl", + expand=False, ) cuda120_versions = ( + "@1.36.0-cuda120", "@1.27.0-cuda120", "@1.26.0-cuda120", "@1.25.0-cuda120", @@ -180,6 +205,7 @@ class PyNvidiaDali(PythonPackage): "@1.22.0-cuda120", ) cuda110_versions = ( + "@1.36.0-cuda110", "@1.27.0-cuda110", "@1.26.0-cuda110", "@1.25.0-cuda110", @@ -193,7 +219,8 @@ class PyNvidiaDali(PythonPackage): for v in cuda110_versions: depends_on("cuda@11", when=v, type=("build", "run")) - depends_on("python@3.6:3.11", when="@1.23:", type=("build", "run")) + depends_on("python@3.8:3.12", when="@1.36:", type=("build", "run")) + depends_on("python@3.6:3.11", when="@1.23:1.27", type=("build", "run")) depends_on("python@3.6:3.10", when="@:1.22", type=("build", "run")) depends_on("py-astunparse@1.6.0:", type=("build", "run")) depends_on("py-gast@0.3.3:", when="@1.27:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-obspy/package.py b/var/spack/repos/builtin/packages/py-obspy/package.py new file mode 100644 index 00000000000000..956b80e830dabc --- /dev/null +++ b/var/spack/repos/builtin/packages/py-obspy/package.py @@ -0,0 +1,39 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyObspy(PythonPackage): + """ObsPy is an open-source project dedicated to provide a Python + framework for processing seismological data""" + + homepage = "https://github.com/obspy/obspy" + pypi = "obspy/obspy-1.4.0.tar.gz" + + maintainers("snehring") + + license("LGPL-3.0-only", checked_by="snehring") + + version("1.4.1", sha256="9cf37b0ce03de43d80398703c006bfddbd709f32e8460a9404b27df998d3f747") + version("1.4.0", sha256="336a6e1d9a485732b08173cb5dc1dd720a8e53f3b54c180a62bb8ceaa5fe5c06") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + + depends_on("python@3.8:3", type=("build", "run")) + + depends_on("py-setuptools", type="build") + + depends_on("py-numpy@1.20:", type=("build", "run")) + # importing hann from scipy.signal is deprecated, removed in 1.13 + # to be fixed in 1.4.1 + depends_on("py-scipy@1.7:1", type=("build", "run"), when="@1.4.1:") + depends_on("py-scipy@1.7:1.12.0", type=("build", "run"), when="@1.4.0") + depends_on("py-matplotlib@3.3:", type=("build", "run")) + depends_on("py-lxml", type=("build", "run")) + depends_on("py-sqlalchemy", type=("build", "run")) + depends_on("py-decorator", type=("build", "run")) + depends_on("py-requests", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-okada-wrapper/package.py b/var/spack/repos/builtin/packages/py-okada-wrapper/package.py new file mode 100644 index 00000000000000..5d404f4677e698 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-okada-wrapper/package.py @@ -0,0 +1,30 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyOkadaWrapper(PythonPackage): + """Python and MATLAB wrappers for the Okada Green's function codes""" + + homepage = "https://github.com/tbenthompson/okada_wrapper" + pypi = "okada_wrapper/okada_wrapper-18.12.07.3.tar.gz" + + maintainers("snehring") + + license("MIT", checked_by="snehring") + + version( + "18.12.07.3", sha256="ee296ad6e347c8df400f6f3d1badc371925add8d1af33854634c2fe1a2b2c855" + ) + + depends_on("fortran", type="build") # generated + + # https://github.com/tbenthompson/okada_wrapper/issues/8 + depends_on("python@3:3.11", type=("build", "run")) + + depends_on("py-setuptools", type="build") + + depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-onnx/package.py b/var/spack/repos/builtin/packages/py-onnx/package.py index 323b6a6b6aa9b5..63f3869b94a305 100644 --- a/var/spack/repos/builtin/packages/py-onnx/package.py +++ b/var/spack/repos/builtin/packages/py-onnx/package.py @@ -21,7 +21,11 @@ class PyOnnx(PythonPackage): license("Apache-2.0") + version("1.16.1", sha256="8299193f0f2a3849bfc069641aa8e4f93696602da8d165632af8ee48ec7556b6") + version("1.16.0", sha256="237c6987c6c59d9f44b6136f5819af79574f8d96a760a1fa843bede11f3822f7") version("1.15.0", sha256="b18461a7d38f286618ca2a6e78062a2a9c634ce498e631e708a8041b00094825") + version("1.14.1", sha256="70903afe163643bd71195c78cedcc3f4fa05a2af651fd950ef3acbb15175b2d1") + version("1.14.0", sha256="43b85087c6b919de66872a043c7f4899fe6f840e11ffca7e662b2ce9e4cc2927") version("1.13.1", sha256="0bdcc25c2c1ce4a8750e4ffbd93ae945442e7fac6e51176f38e366b74a97dfd9") version("1.13.0", sha256="410b39950367857f97b65093681fe2495a2e23d63777a8aceaf96c56a16d166e") version("1.12.0", sha256="13b3e77d27523b9dbf4f30dfc9c959455859d5e34e921c44f712d69b8369eff9") @@ -31,11 +35,14 @@ class PyOnnx(PythonPackage): version("1.6.0", sha256="3b88c3fe521151651a0403c4d131cb2e0311bd28b753ef692020a432a81ce345") version("1.5.0", sha256="1a584a4ef62a6db178c257fffb06a9d8e61b41c0a80bfd8bcd8a253d72c4b0b4") + depends_on("cxx", type="build") # generated + # CMakeLists.txt depends_on("cmake@3.1:", type="build") + depends_on("py-pybind11@2.2:", type=("build", "link")) # requirements.txt - depends_on("py-setuptools@61:", type="build") + depends_on("py-setuptools@64:", type="build") depends_on("py-setuptools", type="build") depends_on("py-protobuf@3.20.2:", type=("build", "run"), when="@1.15:") depends_on("py-protobuf@3.20.2:3", type=("build", "run"), when="@1.13") @@ -51,11 +58,12 @@ class PyOnnx(PythonPackage): depends_on("py-protobuf+cpp", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) depends_on("py-numpy@1.16.6:", type=("build", "run"), when="@1.8.1:1.13") + depends_on("py-numpy@1.20:", type=("build", "run"), when="@1.16.0:") # Historical dependencies depends_on("py-six", type=("build", "run"), when="@:1.8.1") - depends_on("py-typing-extensions@3.6.2.1:", type=("build", "run"), when="@:1.13") - depends_on("py-pytest-runner", type="build", when="@:1.13") + depends_on("py-typing-extensions@3.6.2.1:", type=("build", "run"), when="@:1.14") + depends_on("py-pytest-runner", type="build", when="@:1.14") # 'python_out' does not recognize dllexport_decl. patch("remove_dllexport_decl.patch", when="@:1.6.0") diff --git a/var/spack/repos/builtin/packages/py-onnxruntime/package.py b/var/spack/repos/builtin/packages/py-onnxruntime/package.py index e4ba9d13d80de3..aa633a4a393613 100644 --- a/var/spack/repos/builtin/packages/py-onnxruntime/package.py +++ b/var/spack/repos/builtin/packages/py-onnxruntime/package.py @@ -26,6 +26,9 @@ class PyOnnxruntime(CMakePackage, PythonExtension): version("1.10.0", tag="v1.10.0", commit="0d9030e79888d1d5828730b254fedc53c7b640c1") version("1.7.2", tag="v1.7.2", commit="5bc92dff16b0ddd5063b717fb8522ca2ad023cb0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cuda", default=False, description="Build with CUDA support") # cmake/CMakeLists.txt @@ -55,6 +58,7 @@ class PyOnnxruntime(CMakePackage, PythonExtension): depends_on("protobuf@:3.19", when="@:1.11") depends_on("py-cerberus", type=("build", "run")) depends_on("py-onnx", type=("build", "run")) + depends_on("py-onnx@:1.15.0", type=("build", "run"), when="@:1.17.1") depends_on("zlib-api") depends_on("libpng") depends_on("cuda", when="+cuda") diff --git a/var/spack/repos/builtin/packages/py-opencensus-context/package.py b/var/spack/repos/builtin/packages/py-opencensus-context/package.py index 4364138728f0b4..dc9a0f28d398ad 100644 --- a/var/spack/repos/builtin/packages/py-opencensus-context/package.py +++ b/var/spack/repos/builtin/packages/py-opencensus-context/package.py @@ -15,8 +15,4 @@ class PyOpencensusContext(PythonPackage): license("Apache-2.0") - version( - "0.1.1", - sha256="1a3fdf6bec537031efcc93d51b04f1edee5201f8c9a0c85681d63308b76f5702", - expand=False, - ) + version("0.1.1", sha256="1a3fdf6bec537031efcc93d51b04f1edee5201f8c9a0c85681d63308b76f5702") diff --git a/var/spack/repos/builtin/packages/py-openmc/package.py b/var/spack/repos/builtin/packages/py-openmc/package.py index 1ace8bc018cb56..3272eae617ac91 100644 --- a/var/spack/repos/builtin/packages/py-openmc/package.py +++ b/var/spack/repos/builtin/packages/py-openmc/package.py @@ -17,12 +17,14 @@ class PyOpenmc(PythonPackage): programming model.""" homepage = "https://docs.openmc.org/" - url = "https://github.com/openmc-dev/openmc/tarball/v0.13.3" + url = "https://github.com/openmc-dev/openmc/tarball/v0.15.0" git = "https://github.com/openmc-dev/openmc.git" maintainers("paulromano") version("develop", branch="develop") version("master", branch="master") + version("0.15.0", commit="55b52b7ef3c9415ce045712132bf31c2a013d8c8", submodules=True) + version("0.14.0", commit="fa2330103de61a864c958d1a7250f11e5dd91468", submodules=True) version("0.13.3", commit="27cb0dc97960fe6d750eb5a93584a9a0ca532ac8", submodules=True) version("0.13.2", commit="030f73a8690ed19e91806e46c8caf338d252e74a", submodules=True) version("0.13.1", commit="33bc948f4b855c037975f16d16091fe4ecd12de3", submodules=True) @@ -32,12 +34,17 @@ class PyOpenmc(PythonPackage): version("0.12.0", commit="93d6165ecb455fc57242cd03a3f0805089c0e0b9", submodules=True) version("0.11.0", sha256="19a9d8e9c3b581e9060fbd96d30f1098312d217cb5c925eb6372a5786d9175af") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Enable MPI support") # keep py-openmc and openmc at the same version for ver in [ "develop", "master", + "0.15.0", + "0.14.0", "0.13.3", "0.13.2", "0.13.1", @@ -55,7 +62,8 @@ class PyOpenmc(PythonPackage): ) depends_on("git", type="build") - depends_on("python@3.7:", type=("build", "run"), when="@0.13.2:") + depends_on("python@3.10:", type=("build", "run"), when="@0.15.0:") + depends_on("python@3.7:", type=("build", "run"), when="@0.13.2:0.14.0") depends_on("python@3.6:", type=("build", "run"), when="@0.13.0:0.13.1") depends_on("python@3.5:", type=("build", "run"), when="@:0.12") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-openmesh/package.py b/var/spack/repos/builtin/packages/py-openmesh/package.py index 3dcd44e89020f4..09fc0273c3deff 100644 --- a/var/spack/repos/builtin/packages/py-openmesh/package.py +++ b/var/spack/repos/builtin/packages/py-openmesh/package.py @@ -18,6 +18,9 @@ class PyOpenmesh(PythonPackage): version("1.2.1", sha256="6fd3fa41a68148e4a7523f562426aa9758bf65ccc6642abcf79c37bae9c6af3c") version("1.1.3", sha256="c1d24abc85b7b518fe619639f89750bf19ed3b8938fed4dd739a72f1e6f8b0f6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-setuptools-scm", type="build") depends_on("cmake@3.1:", when="@1.1.3 platform=windows", type="build") diff --git a/var/spack/repos/builtin/packages/py-openslide-python/package.py b/var/spack/repos/builtin/packages/py-openslide-python/package.py index 16806c586ff933..12e29e4f24bb78 100644 --- a/var/spack/repos/builtin/packages/py-openslide-python/package.py +++ b/var/spack/repos/builtin/packages/py-openslide-python/package.py @@ -17,6 +17,8 @@ class PyOpenslidePython(PythonPackage): version("1.1.2", sha256="83e064ab4a29658e7ddf86bf1d3e54d2508cc19ece35d55b55519c826e45d83f") version("1.1.1", sha256="33c390fe43e3d7d443fafdd66969392d3e9efd2ecd5d4af73c3dbac374485ed5") + depends_on("c", type="build") # generated + depends_on("openslide@3.4.0:") depends_on("python@2.6:2.8,3.3:", type=("build", "run")) # https://github.com/openslide/openslide-python/pull/76 diff --git a/var/spack/repos/builtin/packages/py-opentuner/package.py b/var/spack/repos/builtin/packages/py-opentuner/package.py index 1547f1f152ed03..dcf344929e43a4 100644 --- a/var/spack/repos/builtin/packages/py-opentuner/package.py +++ b/var/spack/repos/builtin/packages/py-opentuner/package.py @@ -19,6 +19,8 @@ class PyOpentuner(PythonPackage): version("0.8.7", commit="070c5cef6d933eb760a2f9cd5cd08c95f27aee75") version("0.8.2", commit="8e720a2094e7964d7a1225e58aca40b0e78bff7d") + depends_on("cxx", type="build") # generated + depends_on("python@3:", type=("build", "run"), when="@0.8.1:") depends_on("py-fn-py@0.2.12:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-optree/package.py b/var/spack/repos/builtin/packages/py-optree/package.py new file mode 100644 index 00000000000000..96e10b8fff50a7 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-optree/package.py @@ -0,0 +1,25 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyOptree(PythonPackage): + """Optimized PyTree Utilities.""" + + homepage = "https://github.com/metaopt/optree" + pypi = "optree/optree-0.10.0.tar.gz" + + license("Apache-2.0") + + version("0.10.0", sha256="dc7e8880f997365083191784d141c790833877af71aec8825c7f2b7f7f43c98e") + + depends_on("cxx", type="build") # generated + + depends_on("cmake@3.11:", type="build") + depends_on("python", type=("build", "link", "run")) + depends_on("py-setuptools", type="build") + depends_on("py-pybind11", type=("build", "link")) + depends_on("py-typing-extensions@4:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-or-tools/package.py b/var/spack/repos/builtin/packages/py-or-tools/package.py index a9debf9a3b33f9..2e917b5a7cf2e8 100644 --- a/var/spack/repos/builtin/packages/py-or-tools/package.py +++ b/var/spack/repos/builtin/packages/py-or-tools/package.py @@ -19,6 +19,8 @@ class PyOrTools(CMakePackage): version("7.8", sha256="d93a9502b18af51902abd130ff5f23768fcf47e266e6d1f34b3586387aa2de68") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.14:", type="build") depends_on("py-pip", type="build") depends_on("py-wheel", type="build") diff --git a/var/spack/repos/builtin/packages/py-oracledb/package.py b/var/spack/repos/builtin/packages/py-oracledb/package.py index f53f97fd3834ee..3e50ac8da0c8d6 100644 --- a/var/spack/repos/builtin/packages/py-oracledb/package.py +++ b/var/spack/repos/builtin/packages/py-oracledb/package.py @@ -18,6 +18,8 @@ class PyOracledb(PythonPackage): version("1.2.2", sha256="dd9f63084e44642b484a46b2fcfb4fc921f39facf494a1bab00628fa6409f4fc") + depends_on("c", type="build") # generated + depends_on("py-setuptools@40.6.0:", type="build") depends_on("py-cryptography@3.2.1:", type=("build", "run")) depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-ordered-set/package.py b/var/spack/repos/builtin/packages/py-ordered-set/package.py index 4ef84915c7574b..dc06702eb37333 100644 --- a/var/spack/repos/builtin/packages/py-ordered-set/package.py +++ b/var/spack/repos/builtin/packages/py-ordered-set/package.py @@ -16,7 +16,10 @@ class PyOrderedSet(PythonPackage): license("MIT") + version("4.1.0", sha256="694a8e44c87657c59292ede72891eb91d34131f6531463aab3009191c77364a8") version("4.0.2", sha256="ba93b2df055bca202116ec44b9bead3df33ea63a7d5827ff8e16738b97f33a95") depends_on("python@3.5:", type=("build", "run")) - depends_on("py-setuptools", type="build") + depends_on("python@3.7:", type=("build", "run"), when="@4.1:") + depends_on("py-setuptools", type="build", when="@:4.0") + depends_on("py-flit-core@3.2:3", type="build", when="@4.1:") diff --git a/var/spack/repos/builtin/packages/py-orjson/package.py b/var/spack/repos/builtin/packages/py-orjson/package.py index 4bddb15e5099ea..b3e966897e29b2 100644 --- a/var/spack/repos/builtin/packages/py-orjson/package.py +++ b/var/spack/repos/builtin/packages/py-orjson/package.py @@ -14,6 +14,19 @@ class PyOrjson(PythonPackage): license("Apache-2.0") + version("3.10.3", sha256="2b166507acae7ba2f7c315dcf185a9111ad5e992ac81f2d507aac39193c2c818") + version("3.9.15", sha256="95cae920959d772f30ab36d3b25f83bb0f3be671e986c72ce22f8fa700dae061") + version("3.8.14", sha256="5ea93fd3ef7be7386f2516d728c877156de1559cda09453fc7dd7b696d0439b3") version("3.8.7", sha256="8460c8810652dba59c38c80d27c325b5092d189308d8d4f3e688dbd8d4f3b2dc") - depends_on("py-maturin@0.13:0.14", type="build") + depends_on("c", type="build") # generated + + with default_args(type="build"): + with when("@3.8"): + depends_on("rust@1.60:") + depends_on("python@3.7:") + depends_on("py-maturin@0.13:0.14") + with when("@03.9:"): + depends_on("rust@1.72:") + depends_on("python@3.8:") + depends_on("py-maturin@1") diff --git a/var/spack/repos/builtin/packages/py-osqp/package.py b/var/spack/repos/builtin/packages/py-osqp/package.py index e23c1a9cbe7a4d..3c8f5fe8116e19 100644 --- a/var/spack/repos/builtin/packages/py-osqp/package.py +++ b/var/spack/repos/builtin/packages/py-osqp/package.py @@ -22,6 +22,8 @@ class PyOsqp(PythonPackage): ) version("0.6.1", sha256="47b17996526d6ecdf35cfaead6e3e05d34bc2ad48bcb743153cefe555ecc0e8c") + depends_on("c", type="build") # generated + depends_on("cmake", type="build") depends_on("py-setuptools", type="build") depends_on("py-setuptools@40.8.0:", when="@0.6.2.post8:", type="build") diff --git a/var/spack/repos/builtin/packages/py-pandas/package.py b/var/spack/repos/builtin/packages/py-pandas/package.py index cfeb0bf703e286..ae9d8dc1bd1951 100644 --- a/var/spack/repos/builtin/packages/py-pandas/package.py +++ b/var/spack/repos/builtin/packages/py-pandas/package.py @@ -17,10 +17,10 @@ class PyPandas(PythonPackage): skip_modules = ["pandas.tests", "pandas.plotting._matplotlib", "pandas.core._numba.kernels"] - maintainers("adamjstewart") - license("Apache-2.0") + maintainers("adamjstewart", "rgommers") + version("2.2.2", sha256="9e79019aba43cb4fda9e4d983f8e88ca0373adbb697ae9c6c43093218de28b54") version("2.2.1", sha256="0ab90f87093c13f3e8fa45b48ba9f39181046e8f3317d3aadb2fffbb1b978572") version("2.2.0", sha256="30b83f7c3eb217fb4d1b494a57a2fda5444f17834f5df2de6b2ffff68dc3c8e2") version("2.1.4", sha256="fcb68203c833cc735321512e13861358079a96c174a61f5116a1de89c58c0ef7") @@ -68,6 +68,8 @@ class PyPandas(PythonPackage): version("0.25.3", sha256="52da74df8a9c9a103af0a72c9d5fdc8e0183a90884278db7f386b5692a2220a4") version("0.25.2", sha256="ca91a19d1f0a280874a24dca44aadce42da7f3a7edb7e9ab7c7baad8febee2be") + depends_on("c", type="build") # generated + variant("performance", default=True, description="Build recommended performance dependencies") variant("excel", when="@1.4:", default=False, description="Build with support for Excel") @@ -93,16 +95,17 @@ class PyPandas(PythonPackage): depends_on("py-cython@0.29.13:2", when="@1.0", type="build") depends_on("py-versioneer+toml", when="@2:", type="build") - depends_on("py-numpy@1.22.4:2", when="@2.1.2:", type=("build", "run")) depends_on("py-numpy@1.22.4:", when="@2.1:", type=("build", "run")) depends_on("py-numpy@1.20.3:", when="@1.5:", type=("build", "run")) - depends_on("py-numpy@1.18.5:", when="@1.4:", type=("build", "run")) - depends_on("py-numpy@1.17.3:", when="@1.3:", type=("build", "run")) - depends_on("py-numpy@1.16.5:", when="@1.2:", type=("build", "run")) - depends_on("py-numpy@1.15.4:", when="@1.1:", type=("build", "run")) - depends_on("py-numpy@1.13.3:", when="@0.25:", type=("build", "run")) + depends_on("py-numpy@1.18.5:", when="@1.4", type=("build", "run")) + depends_on("py-numpy@1.17.3:", when="@1.3", type=("build", "run")) + depends_on("py-numpy@1.16.5:", when="@1.2", type=("build", "run")) + depends_on("py-numpy@1.15.4:", when="@1.1", type=("build", "run")) + depends_on("py-numpy@1.13.3:", when="@1.0", type=("build", "run")) # 'NUMPY_IMPORT_ARRAY_RETVAL' was removed in numpy@1.19 - depends_on("py-numpy@:1.18", when="@:0.25", type=("build", "run")) + depends_on("py-numpy@1.13.3:1.18", when="@0.25", type=("build", "run")) + # https://github.com/pandas-dev/pandas/issues/55519 + depends_on("py-numpy@:1", when="@:2.2.1", type=("build", "run")) depends_on("py-python-dateutil@2.8.2:", when="@2:", type=("build", "run")) depends_on("py-python-dateutil@2.8.1:", when="@1.4:", type=("build", "run")) depends_on("py-python-dateutil@2.7.3:", when="@1.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-parmed/package.py b/var/spack/repos/builtin/packages/py-parmed/package.py index d7d281012fefd5..755d097f9932c2 100644 --- a/var/spack/repos/builtin/packages/py-parmed/package.py +++ b/var/spack/repos/builtin/packages/py-parmed/package.py @@ -19,5 +19,7 @@ class PyParmed(PythonPackage): version("3.4.3", sha256="90afb155e3ffe69230a002922b28968464126d4450059f0bd97ceca679c6627c") + depends_on("cxx", type="build") # generated + depends_on("python@2.7:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-parsl/package.py b/var/spack/repos/builtin/packages/py-parsl/package.py index edc2b4b0554901..2e128a25e90f3a 100644 --- a/var/spack/repos/builtin/packages/py-parsl/package.py +++ b/var/spack/repos/builtin/packages/py-parsl/package.py @@ -24,6 +24,8 @@ class PyParsl(PythonPackage): version("1.2.0", sha256="342c74ee39fa210d74b8adfb455f0a9c20d9f059ec5bd9d60c5bdc9929abcdcc") version("1.1.0", sha256="6a623d3550329f028775950d23a2cafcb0f82b199f15940180410604aa5d102c") + depends_on("c", type="build") # generated + variant("monitoring", default=False, description="enable live monitoring") # See https://parsl.readthedocs.io/en/stable/userguide/monitoring.html diff --git a/var/spack/repos/builtin/packages/py-partd/package.py b/var/spack/repos/builtin/packages/py-partd/package.py index 13fdca33dba3f3..19a507574cdf37 100644 --- a/var/spack/repos/builtin/packages/py-partd/package.py +++ b/var/spack/repos/builtin/packages/py-partd/package.py @@ -12,8 +12,10 @@ class PyPartd(PythonPackage): homepage = "https://github.com/dask/partd/" pypi = "partd/partd-0.3.8.tar.gz" - license("BSD-3-Clause") + license("BSD-3-Clause", checked_by="wdconinc") + version("1.4.2", sha256="d022c33afbdc8405c226621b015e8067888173d85f7f5ecebb3cafed9a20f02c") + version("1.4.1", sha256="56c25dd49e6fea5727e731203c466c6e092f308d8f0024e199d02f6aa2167f67") version("1.4.0", sha256="aa0ff35dbbcc807ae374db56332f4c1b39b46f67bf2975f5151e0b4186aed0d5") version("1.1.0", sha256="6e258bf0810701407ad1410d63d1a15cfd7b773fd9efe555dac6bb82cc8832b0") version("0.3.10", sha256="33722a228ebcd1fa6f44b1631bdd4cff056376f89eb826d7d880b35b637bcfba") @@ -21,6 +23,9 @@ class PyPartd(PythonPackage): depends_on("python@3.5:", type=("build", "run"), when="@1.1.0:") depends_on("python@3.7:", type=("build", "run"), when="@1.4.0:") + depends_on("python@3.9:", type=("build", "run"), when="@1.4.2:") depends_on("py-setuptools", type="build") + depends_on("py-setuptools@61.2:", type="build", when="@1.4.2:") + depends_on("py-versioneer@0.29 +toml", type="build", when="@1.4.2:") depends_on("py-locket", type=("build", "run")) depends_on("py-toolz", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pbr/package.py b/var/spack/repos/builtin/packages/py-pbr/package.py index 41621f4a025e49..e5bac4262e7b1b 100644 --- a/var/spack/repos/builtin/packages/py-pbr/package.py +++ b/var/spack/repos/builtin/packages/py-pbr/package.py @@ -24,5 +24,7 @@ class PyPbr(PythonPackage): version("1.10.0", sha256="186428c270309e6fdfe2d5ab0949ab21ae5f7dea831eab96701b86bd666af39c") version("1.8.1", sha256="e2127626a91e6c885db89668976db31020f0af2da728924b56480fc7ccf09649") + depends_on("c", type="build") # generated + depends_on("python@2.6:", type=("build", "run")) depends_on("py-setuptools", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pdm-pep517/package.py b/var/spack/repos/builtin/packages/py-pdm-pep517/package.py index 488972ed509b20..59f4a6fff54a95 100644 --- a/var/spack/repos/builtin/packages/py-pdm-pep517/package.py +++ b/var/spack/repos/builtin/packages/py-pdm-pep517/package.py @@ -17,4 +17,6 @@ class PyPdmPep517(PythonPackage): version("1.0.4", sha256="392f8c2b47c6ec20550cb8e19e24b9dbd27373413f067b56ecd75f9767f93015") + depends_on("c", type="build") # generated + depends_on("python@3.7:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-peachpy/package.py b/var/spack/repos/builtin/packages/py-peachpy/package.py index c2026641b628ae..ea98e2ce6a9c96 100644 --- a/var/spack/repos/builtin/packages/py-peachpy/package.py +++ b/var/spack/repos/builtin/packages/py-peachpy/package.py @@ -16,6 +16,9 @@ class PyPeachpy(PythonPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-opcodes@0.3.13:", type="build") depends_on("py-six", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pennylane-lightning-kokkos/package.py b/var/spack/repos/builtin/packages/py-pennylane-lightning-kokkos/package.py index 22a0d776bfa703..9f5b20a915facb 100644 --- a/var/spack/repos/builtin/packages/py-pennylane-lightning-kokkos/package.py +++ b/var/spack/repos/builtin/packages/py-pennylane-lightning-kokkos/package.py @@ -2,8 +2,6 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) - - from spack.package import * @@ -13,21 +11,28 @@ class PyPennylaneLightningKokkos(CMakePackage, PythonExtension, CudaPackage, ROC homepage = "https://docs.pennylane.ai/projects/lightning-kokkos" git = "https://github.com/PennyLaneAI/pennylane-lightning-kokkos.git" - url = "https://github.com/PennyLaneAI/pennylane-lightning-kokkos/archive/refs/tags/v0.32.0.tar.gz" maintainers("AmintorDusko", "vincentmr") license("Apache-2.0") version("main", branch="main") - + version("master", branch="master") + version("0.35.1", sha256="d39a2749d08ef2ba336ed2d6f77b3bd5f6d1b25292263a41b97943ae7538b7da") + version("0.35.0", sha256="1a16fd3dbf03788e4f8dd510bbb668e7a7073ca62be4d9414e2c32e0166e8bda") + version("0.34.0", sha256="398c3a1d4450a9f3e146204c22329da9adc3f83a1685ae69187f3b25f47824c0") + version("0.33.1", sha256="878f63cd1afadd52386b1aca9c0e3fb0a097b64ce8e347b325ebc7cac722e5e0") + version("0.33.0", sha256="c4cab4a8a1a53edc0990a2a429805dca1c6a46a7ffcc6f77c985b88cd6ff6247") version("0.32.0", sha256="06f19dfb1073387ef9ee30c38ea44884844a771373256b694a0e1ceb87195bb2") version("0.31.0", sha256="fe10322fee0fa7df45cd3a81d6c229a79c7dfa7f20ff7d67c65c9a28f494dc89") version("0.30.0", sha256="7c8f0e0431f8052993cd8033a316f53590c7bf5419445d0725e214b93cbc661b") version("0.29.1", sha256="f51ba7718defc7bb5064f690f381e04b2ec58cb09f22a171ae5f410860716e30") + depends_on("cxx", type="build") # generated + depends_on("kokkos@:3.7.2", when="@:0.30", type=("run", "build")) - depends_on("kokkos@4:", when="@0.31:", type=("run", "build")) + depends_on("kokkos@4:4.1", when="@0.31", type=("run", "build")) + depends_on("kokkos@4:4.2", when="@0.32:", type=("run", "build")) # kokkos backends backends = { @@ -70,16 +75,20 @@ class PyPennylaneLightningKokkos(CMakePackage, PythonExtension, CudaPackage, ROC depends_on("cmake@3.20:", type="build") depends_on("ninja", type="build") depends_on("python@3.8:", type=("build", "run")) + depends_on("python@3.9:", type=("build", "run"), when="@0.32:") depends_on("py-setuptools", type="build") depends_on("py-pybind11", type="link") depends_on("py-pip", type="build") depends_on("py-wheel", type="build") - depends_on("py-pennylane@0.28:", type=("build", "run"), when="@:0.30") - depends_on("py-pennylane@0.30:", type=("build", "run"), when="@0.31:") + depends_on("py-pennylane@0.28:0.30", type=("build", "run"), when="@:0.30") + depends_on("py-pennylane@0.30:", type=("build", "run"), when="@0.31") # This requirement differs from `pennylane>=0.30` in `setup.py`, # but the introduction of `StatePrep` demands `pennylane>=0.32` - depends_on("py-pennylane@0.32:", type=("build", "run"), when="@0.32:") + depends_on("py-pennylane@0.32:", type=("build", "run"), when="@0.32") depends_on("py-pennylane-lightning~kokkos", type=("build", "run"), when="@:0.31") + for v in range(33, 36): + depends_on(f"py-pennylane@0.{v}:", type="run", when=f"@0.{v}") + depends_on(f"py-pennylane-lightning@0.{v}", type=("build", "run"), when=f"@0.{v}") # variant defined dependencies depends_on("llvm-openmp", when="+openmp %apple-clang") @@ -89,16 +98,27 @@ class PyPennylaneLightningKokkos(CMakePackage, PythonExtension, CudaPackage, ROC depends_on("py-pytest-mock", type="test") depends_on("py-flaky", type="test") + def url_for_version(self, version): + extra = "-kokkos" if version <= Version("0.32.0") else "" + return f"https://github.com/PennyLaneAI/pennylane-lightning{extra}/archive/refs/tags/v{version}.tar.gz" + class CMakeBuilder(spack.build_systems.cmake.CMakeBuilder): build_directory = "build" + def setup_build_environment(self, env): + env.set("PL_BACKEND", "lightning_kokkos") + cm_args = " ".join([s[2:] for s in self.cmake_args()]) + env.set("CMAKE_ARGS", f"{cm_args}") + def cmake_args(self): """ Here we specify all variant options that can be dynamically specified at build time """ + args_prefix = "PLKOKKOS_" if self.spec.version < Version("0.33") else "" + args = [ - self.define_from_variant("PLKOKKOS_BUILD_TESTS", "cpptests"), + self.define_from_variant(f"{args_prefix}BUILD_TESTS", "cpptests"), self.define_from_variant("PLKOKKOS_ENABLE_NATIVE", "native"), self.define_from_variant("PLKOKKOS_ENABLE_SANITIZER", "sanitize"), ] @@ -108,13 +128,16 @@ def cmake_args(self): args.append( "-DPLKOKKOS_ENABLE_WARNINGS=OFF" ) # otherwise build might fail due to Kokkos::InitArguments deprecated + if self.spec.version >= Version("0.33"): + args.append("-DPL_BACKEND=lightning_kokkos") return args def build(self, pkg, spec, prefix): - super().build(pkg, spec, prefix) - cm_args = ";".join([s[2:] for s in self.cmake_args()]) - args = ["-i", f"--define={cm_args}"] - python("setup.py", "build_ext", *args) + if self.spec.version < Version("0.32"): + super().build(pkg, spec, prefix) + cm_args = ";".join([s[2:] for s in self.cmake_args()]) + args = ["-i", f"--define={cm_args}"] + python("setup.py", "build_ext", *args) def install(self, pkg, spec, prefix): pip_args = std_pip_args + [f"--prefix={prefix}", "."] diff --git a/var/spack/repos/builtin/packages/py-pennylane-lightning/package.py b/var/spack/repos/builtin/packages/py-pennylane-lightning/package.py index d2cf5c0d4e055c..fb8d29715c73e8 100644 --- a/var/spack/repos/builtin/packages/py-pennylane-lightning/package.py +++ b/var/spack/repos/builtin/packages/py-pennylane-lightning/package.py @@ -12,18 +12,25 @@ class PyPennylaneLightning(CMakePackage, PythonExtension): homepage = "https://docs.pennylane.ai/projects/lightning" git = "https://github.com/PennyLaneAI/pennylane-lightning.git" - url = "https://github.com/PennyLaneAI/pennylane-lightning/archive/refs/tags/v0.32.0.tar.gz" + url = "https://github.com/PennyLaneAI/pennylane-lightning/archive/refs/tags/v0.35.1.tar.gz" - maintainers("mlxd", "AmintorDusko") + maintainers("mlxd", "AmintorDusko", "vincentmr") license("Apache-2.0") version("master", branch="master") + version("0.35.1", sha256="d39a2749d08ef2ba336ed2d6f77b3bd5f6d1b25292263a41b97943ae7538b7da") + version("0.35.0", sha256="1a16fd3dbf03788e4f8dd510bbb668e7a7073ca62be4d9414e2c32e0166e8bda") + version("0.34.0", sha256="398c3a1d4450a9f3e146204c22329da9adc3f83a1685ae69187f3b25f47824c0") + version("0.33.1", sha256="878f63cd1afadd52386b1aca9c0e3fb0a097b64ce8e347b325ebc7cac722e5e0") + version("0.33.0", sha256="c4cab4a8a1a53edc0990a2a429805dca1c6a46a7ffcc6f77c985b88cd6ff6247") version("0.32.0", sha256="124edae1828c7e72e7b3bfbb0e75e98a07a490d7f1eab19eebb3311bfa8a23d4") version("0.31.0", sha256="b177243625b6fdac0699d163bbc330c92ca87fb9f427643785069273d2a255f6") version("0.30.0", sha256="0f4032409d20d00991b5d14fe0b2b928baca4a13c5a1b16eab91f61f9273e58d") version("0.29.0", sha256="da9912f0286d1a54051cc19cf8bdbdcd732795636274c95f376db72a88e52d85") + depends_on("cxx", type="build") # generated + variant("blas", default=True, description="Build with BLAS support") variant( "dispatcher", @@ -64,6 +71,11 @@ class PyPennylaneLightning(CMakePackage, PythonExtension): class CMakeBuilder(spack.build_systems.cmake.CMakeBuilder): build_directory = "build" + def setup_build_environment(self, env): + env.set("PL_BACKEND", "lightning_qubit") + cm_args = " ".join([s[2:] for s in self.cmake_args()]) + env.set("CMAKE_ARGS", f"{cm_args}") + def cmake_args(self): """ Here we specify all variant options that can be dynamicaly specified at build time @@ -74,9 +86,10 @@ def cmake_args(self): self.define_from_variant("ENABLE_BLAS", "blas"), self.define_from_variant("CMAKE_VERBOSE_MAKEFILE:BOOL", "verbose"), self.define_from_variant("BUILD_TESTS", "cpptests"), - self.define_from_variant("BUILD_BENCHMARKS", "cppbenchmarks"), self.define_from_variant("ENABLE_GATE_DISPATCHER", "dispatcher"), ] + if self.spec.version < Version("0.32"): + args.append(self.define_from_variant("BUILD_BENCHMARKS", "cppbenchmarks")) if "+kokkos" in self.spec: args += [ @@ -90,16 +103,12 @@ def cmake_args(self): return args def build(self, pkg, spec, prefix): - super().build(pkg, spec, prefix) - cm_args = ";".join( - [ - s[2:] - for s in self.cmake_args() - if s[2:] not in ["BUILD_TESTS:BOOL=ON", "BUILD_BENCHMARKS:BOOL=ON"] - ] - ) - args = ["-i", f"--define={cm_args}"] - python("setup.py", "build_ext", *args) + if self.spec.version < Version("0.32"): + super().build(pkg, spec, prefix) + skipped_args = ["BUILD_TESTS:BOOL=ON", "BUILD_BENCHMARKS:BOOL=ON"] + cm_args = ";".join([s[2:] for s in self.cmake_args() if s[2:] not in skipped_args]) + args = ["-i", f"--define={cm_args}"] + python("setup.py", "build_ext", *args) def install(self, pkg, spec, prefix): pip_args = std_pip_args + ["--prefix=" + prefix, "."] diff --git a/var/spack/repos/builtin/packages/py-pennylane/package.py b/var/spack/repos/builtin/packages/py-pennylane/package.py index 0464309adb107d..3bf4b82c8c0ce4 100644 --- a/var/spack/repos/builtin/packages/py-pennylane/package.py +++ b/var/spack/repos/builtin/packages/py-pennylane/package.py @@ -12,13 +12,18 @@ class PyPennylane(PythonPackage): homepage = "https://docs.pennylane.ai/" git = "https://github.com/PennyLaneAI/pennylane.git" - url = "https://github.com/PennyLaneAI/pennylane/archive/refs/tags/v0.32.0.tar.gz" + url = "https://github.com/PennyLaneAI/pennylane/archive/refs/tags/v0.35.1.tar.gz" - maintainers("mlxd", "AmintorDusko", "marcodelapierre") + maintainers("mlxd", "AmintorDusko", "marcodelapierre", "vincentmr") license("Apache-2.0") version("master", branch="master") + version("0.35.1", sha256="5a234d0605012f3d0201fdcfd2bfe84205a09c8ac42801fe7123eddddec71366") + version("0.35.0", sha256="3b99185661e8a0d0f7bc2dcc9cfa51dde20e99708c3c7d858c4732f0eb774716") + version("0.34.0", sha256="f76f544212c028a8f882ce7f66639e7f7c4c9213277bde0454c7f3a7d9d46538") + version("0.33.1", sha256="89d02bfe3a37abd13dcdb2f34f00a38e9e60a13af66a97911c8558f77ff4e32e") + version("0.33.0", sha256="b41c843a432c5869fc63dc35c9e9d53bec64d296ca0e0eeb1c9b83d95a68c3f1") version("0.32.0", sha256="8a2206268d7cae0a59f9067b6075175eec93f4843519b371f02716c49a22e750") version("0.31.0", sha256="f3b68700825c120e44434ed2b2ab71d0be9d3111f3043077ec0598661ec33477") version("0.30.0", sha256="7fe4821fbc733e3e40d7011e054bd2e31edde3151fd9539025c827a5a3579d6b") @@ -28,10 +33,12 @@ class PyPennylane(PythonPackage): depends_on("python@3.9:", type=("build", "run"), when="@0.32.0:") depends_on("py-pip", type=("build", "run")) # Runtime req for pennylane.about() depends_on("py-setuptools", type="build") + depends_on("py-setuptools", type=("build", "run"), when="@0.33") - depends_on("py-numpy@:1.23", type=("build", "run")) + depends_on("py-numpy", type=("build", "run")) + depends_on("py-numpy@:1.23", type=("build", "run"), when="@:0.32.0") depends_on("py-scipy", type=("build", "run")) - depends_on("py-scipy@:1.10", type=("build", "run"), when="@:0.31.0") + depends_on("py-scipy@:1.10.0", type=("build", "run"), when="@:0.31") depends_on("py-networkx", type=("build", "run")) depends_on("py-rustworkx", type=("build", "run"), when="@0.30.0:") depends_on("py-retworkx", type=("build", "run"), when="@0.28.0:0.29.1") @@ -39,21 +46,24 @@ class PyPennylane(PythonPackage): depends_on("py-toml", type=("build", "run")) depends_on("py-appdirs", type=("build", "run")) depends_on("py-semantic-version@2.7:", type=("build", "run")) - depends_on("py-autoray@0.3.1:", type=("build", "run")) + depends_on("py-autoray@0.3.1:", type=("build", "run"), when="@:0.32.0") + depends_on("py-autoray@0.6.1:", type=("build", "run"), when="@0.33.0:") depends_on("py-cachetools", type=("build", "run")) - for v in range(30, 33): - depends_on(f"py-pennylane-lightning@0.{v}.0:", type=("build", "run"), when=f"@0.{v}.0:") depends_on( "py-pennylane-lightning@0.28.0:0.29.0", type=("build", "run"), when="@0.28.0:0.29.1" ) + for v in range(30, 36): + depends_on(f"py-pennylane-lightning@0.{v}:", type=("build", "run"), when=f"@0.{v}:") depends_on("py-requests", type=("build", "run")) depends_on("py-typing-extensions", type=("build", "run"), when="@0.32.0:") - # Test deps + # The following packages are required by the `pl-device-test binary` depends_on("py-pytest", type="test") - depends_on("py-pytest-xdist@3.2:", type="test") depends_on("py-pytest-mock", type="test") depends_on("py-flaky", type="test") + depends_on("py-pytest-benchmark", type="test", when="@0.34.0:") + # Additional test deps + depends_on("py-pytest-xdist@3.2:", type="test") @run_after("install") @on_package_attributes(run_tests=True) diff --git a/var/spack/repos/builtin/packages/py-petsc4py/package.py b/var/spack/repos/builtin/packages/py-petsc4py/package.py index ede2ff11b55f90..8e33851c83c16e 100644 --- a/var/spack/repos/builtin/packages/py-petsc4py/package.py +++ b/var/spack/repos/builtin/packages/py-petsc4py/package.py @@ -20,6 +20,14 @@ class PyPetsc4py(PythonPackage): license("BSD-2-Clause") version("main", branch="main") + version("3.21.3", sha256="1c3664d5b527354171077c89c4b1fef3df4a41be7196d12bca74b2759c7e2648") + version("3.21.2", sha256="6ce1e1a45407da300c6869d0d9abe17b5b077424aa4895713642dda0bb19ab4e") + version("3.21.1", sha256="ea8c6afb16541167d39f87d5fcad98c32d856fe8a2173504ef2a31c16647d53d") + version("3.21.0", sha256="b2000a3f8ef60920e1f82fa4772372d7941bc737bcc421a234a2507097a44d00") + version("3.20.6", sha256="bcc4cb35231ba6664309ea195cc8ce8a9bb61f3e24b39be480eee59c52139dc2") + version("3.20.5", sha256="2f40a6a7bfdaa2bca7c1f3e739ab7c74aba8d95db05aa1d120826eec904bbc16") + version("3.20.4", sha256="3ebdb4c605ad59d71b7b7adc5f06b6d2a7ce9225c9b56e672923cb5bd6e43440") + version("3.20.3", sha256="8e10884df5ca38191b71294dc7e89f7479b18cca83fedfe27f89105e57c40785") version("3.20.2", sha256="d3f24aa6612ded3e9b9ae11d5533f319d1df1705bea6d81385fea023d01175c9") version("3.20.1", sha256="dcc9092040d13130496f1961b79c36468f383b6ede398080e004f1966c06ad38") version("3.20.0", sha256="c2461eef3977ae5c214ad252520adbb92ec3a31d00e79391dd92535077bbf03e") @@ -62,10 +70,14 @@ class PyPetsc4py(PythonPackage): version("3.12.0", sha256="4c94a1dbbf244b249436b266ac5fa4e67080d205420805deab5ec162b979df8d") version("3.11.0", sha256="ec114b303aadaee032c248a02021e940e43c6437647af0322d95354e6f2c06ad") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Activates MPI support") patch("ldshared.patch", when="@:3.18") + depends_on("py-cython@3:", when="@3.20:", type="build") depends_on("py-cython@0.29.32:", when="^python@3.11:", type="build") depends_on("py-cython@0.24:", type="build") depends_on("python@2.6:2.8,3.3:", type=("build", "run")) @@ -76,7 +88,7 @@ class PyPetsc4py(PythonPackage): depends_on("petsc+mpi", when="+mpi") depends_on("petsc~mpi", when="~mpi") depends_on("petsc@main", when="@main") - for ver in ["3.20", "3.19", "3.18", "3.17", "3.16", "3.15", "3.13", "3.12", "3.11"]: + for ver in ["3.21", "3.20", "3.19", "3.18", "3.17", "3.16", "3.15", "3.13", "3.12", "3.11"]: depends_on(f"petsc@{ver}", when=f"@{ver}") depends_on("petsc@3.14.2:3.14", when="@3.14.1:3.14") depends_on("petsc@3.14.0:3.14.1", when="@3.14.0") diff --git a/var/spack/repos/builtin/packages/py-pexpect/package.py b/var/spack/repos/builtin/packages/py-pexpect/package.py index 5a6346338ab527..8507059bace6cf 100644 --- a/var/spack/repos/builtin/packages/py-pexpect/package.py +++ b/var/spack/repos/builtin/packages/py-pexpect/package.py @@ -17,6 +17,8 @@ class PyPexpect(PythonPackage): version("4.2.1", sha256="3d132465a75b57aa818341c6521392a06cc660feb3988d7f1074f39bd23c9a92") version("3.3", sha256="dfea618d43e83cfff21504f18f98019ba520f330e4142e5185ef7c73527de5ba") + depends_on("c", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") depends_on("py-ptyprocess", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-phanotate/package.py b/var/spack/repos/builtin/packages/py-phanotate/package.py index 3f88711942b9ab..3dfa74297cdb8c 100644 --- a/var/spack/repos/builtin/packages/py-phanotate/package.py +++ b/var/spack/repos/builtin/packages/py-phanotate/package.py @@ -21,6 +21,8 @@ class PyPhanotate(PythonPackage): version("1.5.0", sha256="589e441d2369e5550aef98b8d99fd079d130363bf881a70ac862fc7a8e0d2c88") + depends_on("c", type="build") # generated + depends_on("python@3.5.3:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-fastpath@1.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-phonopy/package.py b/var/spack/repos/builtin/packages/py-phonopy/package.py index a92e563e6102d9..770bc90c6777a9 100644 --- a/var/spack/repos/builtin/packages/py-phonopy/package.py +++ b/var/spack/repos/builtin/packages/py-phonopy/package.py @@ -17,6 +17,8 @@ class PyPhonopy(PythonPackage): version("1.10.0", sha256="6b7c540bbbb033203c45b8472696db02a3a55913a0e5eb23de4dc9a3bee473f7") + depends_on("c", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-photutils/package.py b/var/spack/repos/builtin/packages/py-photutils/package.py index c0b56c9ba434bb..455ebd3ec1d201 100644 --- a/var/spack/repos/builtin/packages/py-photutils/package.py +++ b/var/spack/repos/builtin/packages/py-photutils/package.py @@ -19,6 +19,8 @@ class PyPhotutils(PythonPackage): version("1.5.0", sha256="014f7aa5a571401094d5cf9ffb57803b48869233feb80476ce377ecb91113689") + depends_on("c", type="build") # generated + maintainers("meyersbs") # From setup.cfg diff --git a/var/spack/repos/builtin/packages/py-phydms/package.py b/var/spack/repos/builtin/packages/py-phydms/package.py index bd8e1826cc3640..3fafdb822a16a8 100644 --- a/var/spack/repos/builtin/packages/py-phydms/package.py +++ b/var/spack/repos/builtin/packages/py-phydms/package.py @@ -20,6 +20,8 @@ class PyPhydms(PythonPackage): version("2.4.1", sha256="04eb50bdb07907214050d19214d9bc8cf2002e24ca30fbe6e0f23f013d584d5c") + depends_on("c", type="build") # generated + depends_on("python@3.5:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-phylophlan/package.py b/var/spack/repos/builtin/packages/py-phylophlan/package.py index 648f4924a3afc3..4c31ba94d97f0f 100644 --- a/var/spack/repos/builtin/packages/py-phylophlan/package.py +++ b/var/spack/repos/builtin/packages/py-phylophlan/package.py @@ -34,5 +34,5 @@ class PyPhylophlan(PythonPackage): depends_on("mafft@7.310:", type=("build", "run")) depends_on("fasttree@2.1.8:", type=("build", "run")) depends_on("raxml@8.2.10:", type=("build", "run")) - depends_on("iqtree2", type=("build", "run")) + depends_on("iq-tree@2", type=("build", "run")) depends_on("mash", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pickle5/package.py b/var/spack/repos/builtin/packages/py-pickle5/package.py index e5b6372aa7a929..f2c03dc1081ff0 100644 --- a/var/spack/repos/builtin/packages/py-pickle5/package.py +++ b/var/spack/repos/builtin/packages/py-pickle5/package.py @@ -18,5 +18,7 @@ class PyPickle5(PythonPackage): version("0.0.11", sha256="7e013be68ba7dde1de5a8dbcc241f201dab1126e326715916ce4a26c27919ffc") + depends_on("c", type="build") # generated + depends_on("python@3.5:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pillow-simd/package.py b/var/spack/repos/builtin/packages/py-pillow-simd/package.py index cdcdc09364ca9c..e3d71e68d65c81 100644 --- a/var/spack/repos/builtin/packages/py-pillow-simd/package.py +++ b/var/spack/repos/builtin/packages/py-pillow-simd/package.py @@ -16,8 +16,6 @@ class PyPillowSimd(PyPillowBase): homepage = "https://github.com/uploadcare/pillow-simd" pypi = "Pillow-SIMD/Pillow-SIMD-7.0.0.post3.tar.gz" - license("HPND") - version( "9.0.0.post1", sha256="918541cfaa90ba3c0e1bae5da31ba1b1f52b09c0009bd90183b787af4e018263" ) @@ -28,6 +26,8 @@ class PyPillowSimd(PyPillowBase): "6.2.2.post1", sha256="d29b673ac80091797f1e8334458be307e4ac4ab871b0e495cfe56cb7b1d7704e" ) + depends_on("c", type="build") # generated + for ver in ["6.2.2.post1", "7.0.0.post3", "9.0.0.post1"]: provides("pil@" + ver, when="@" + ver) diff --git a/var/spack/repos/builtin/packages/py-pillow/package.py b/var/spack/repos/builtin/packages/py-pillow/package.py index eb380ea75aa6fc..7eff0630dba655 100644 --- a/var/spack/repos/builtin/packages/py-pillow/package.py +++ b/var/spack/repos/builtin/packages/py-pillow/package.py @@ -10,11 +10,11 @@ class PyPillowBase(PythonPackage): """Base class for Pillow and its fork Pillow-SIMD.""" maintainers("adamjstewart") - + license("HPND") provides("pil") # These defaults correspond to Pillow defaults - # https://pillow.readthedocs.io/en/stable/installation.html#external-libraries + # https://pillow.readthedocs.io/en/stable/installation/building-from-source.html VARIANTS_IN_SETUP_CFG = ( "zlib", "jpeg", @@ -40,18 +40,25 @@ class PyPillowBase(PythonPackage): variant("raqm", when="@8.2:", default=False, description="RAQM support") # Required dependencies - # https://pillow.readthedocs.io/en/latest/installation.html#python-support - depends_on("python@3.8:3.11", when="@10:", type=("build", "link", "run")) - depends_on("python@3.7:3.11", when="@9.3:9.5", type=("build", "link", "run")) - depends_on("python@3.7:3.10", when="@9.0:9.2", type=("build", "link", "run")) - depends_on("python@3.6:3.10", when="@8.3.2:8.4", type=("build", "link", "run")) - depends_on("python@3.6:3.9", when="@8:8.3.1", type=("build", "link", "run")) - depends_on("python@3.5:3.8", when="@7.0:7.2", type=("build", "link", "run")) - depends_on("python@2.7:2.8,3.5:3.8", when="@6.2.1:6.2.2", type=("build", "link", "run")) - depends_on("py-setuptools", type="build") + # https://pillow.readthedocs.io/en/stable/installation/python-support.html + with default_args(type=("build", "link", "run")): + depends_on("python@3.8:3.13", when="@10.4:") + depends_on("python@3.8:3.12", when="@10.1:10.3") + depends_on("python@3.8:3.11", when="@10.0") + depends_on("python@3.7:3.11", when="@9.3:9.5") + depends_on("python@3.7:3.10", when="@9.0:9.2") + depends_on("python@3.6:3.10", when="@8.3.2:8.4") + depends_on("python@3.6:3.9", when="@8:8.3.1") + depends_on("python@3.5:3.8", when="@7.0:7.2") + depends_on("python@2.7:2.8,3.5:3.8", when="@6.2.1:6.2.2") + + # pyproject.toml + with default_args(type="build"): + depends_on("py-setuptools@67.8:", when="@10:") + depends_on("py-setuptools") # Optional dependencies - # https://pillow.readthedocs.io/en/latest/installation.html#external-libraries + # https://pillow.readthedocs.io/en/stable/installation/building-from-source.html depends_on("zlib-api", when="+zlib") depends_on("jpeg", when="+jpeg") depends_on("libtiff", when="+tiff") @@ -95,7 +102,7 @@ def variant_to_cfg(variant): setup.write("[install]\n") def setup_build_environment(self, env): - env.set("MAX_CONCURRENCY", str(make_jobs)) + env.set("MAX_CONCURRENCY", make_jobs) class PyPillow(PyPillowBase): @@ -105,10 +112,13 @@ class PyPillow(PyPillowBase): capabilities.""" homepage = "https://python-pillow.org/" - pypi = "Pillow/Pillow-7.2.0.tar.gz" - - license("HPND") + pypi = "pillow/pillow-10.2.0.tar.gz" + version("10.4.0", sha256="166c1cd4d24309b30d61f79f4a9114b7b2313d7450912277855ff5dfd7cd4a06") + version("10.3.0", sha256="9d2455fbf44c914840c793e89aa82d0e1763a14253a000743719ae5946814b2d") + version("10.2.0", sha256="e87f0b2c78157e12d7686b27d63c070fd65d994e8ddae6f328e0dcf4a0cd007e") + version("10.1.0", sha256="e6bf8de6c36ed96c86ea3b6e1d5273c53f46ef518a062464cd7ef5dd2cf92e38") + version("10.0.1", sha256="d72967b06be9300fed5cfbc8b5bafceec48bf7cdc7dab66b1d2549035287191d") version("10.0.0", sha256="9c82b5b3e043c7af0d95792d0d20ccf68f61a1fec6b3530e718b688422727396") version("9.5.0", sha256="bf548479d336726d7a0eceb6e767e179fbde37833ae42794602631a070d630f1") version("9.4.0", sha256="a1c2d7780448eb93fbcc3789bf3916aa5720d942e37945f4056680317f1cd23e") @@ -125,7 +135,14 @@ class PyPillow(PyPillowBase): version("6.2.2", sha256="db9ff0c251ed066d367f53b64827cc9e18ccea001b986d08c265e53625dab950") version("6.2.1", sha256="bf4e972a88f8841d8fdc6db1a75e0f8d763e66e3754b03006cbc3854d89f1cb1") + depends_on("c", type="build") # generated + for ver in [ + "10.4.0", + "10.3.0", + "10.2.0", + "10.1.0", + "10.0.1", "10.0.0", "9.5.0", "9.4.0", @@ -143,3 +160,11 @@ class PyPillow(PyPillowBase): "6.2.1", ]: provides("pil@" + ver, when="@" + ver) + + def url_for_version(self, version): + url = "https://files.pythonhosted.org/packages/source/{0}/{0}illow/{0}illow-{1}.tar.gz" + if version >= Version("10.2"): + letter = "p" + else: + letter = "P" + return url.format(letter, version) diff --git a/var/spack/repos/builtin/packages/py-pint/package.py b/var/spack/repos/builtin/packages/py-pint/package.py index cbd8f48575fbdc..3d5aa155912a49 100644 --- a/var/spack/repos/builtin/packages/py-pint/package.py +++ b/var/spack/repos/builtin/packages/py-pint/package.py @@ -21,6 +21,7 @@ class PyPint(PythonPackage): version("0.22", sha256="2d139f6abbcf3016cad7d3cec05707fe908ac4f99cf59aedfd6ee667b7a64433") version("0.21.1", sha256="5d5b6b518d0c5a7ab03a776175db500f1ed1523ee75fb7fafe38af8149431c8d") version("0.20.1", sha256="387cf04078dc7dfe4a708033baad54ab61d82ab06c4ee3d4922b1e45d5626067") + version("0.19.2", sha256="e1d4989ff510b378dad64f91711e7bdabe5ca78d75b06a18569ac454678c4baf") version("0.18", sha256="8c4bce884c269051feb7abc69dbfd18403c0c764abc83da132e8a7222f8ba801") version("0.17", sha256="f4d0caa713239e6847a7c6eefe2427358566451fe56497d533f21fb590a3f313") version("0.11", sha256="308f1070500e102f83b6adfca6db53debfce2ffc5d3cbe3f6c367da359b5cf4d") diff --git a/var/spack/repos/builtin/packages/py-pip/package.py b/var/spack/repos/builtin/packages/py-pip/package.py index de4bff43cccd38..111e50911b87b1 100644 --- a/var/spack/repos/builtin/packages/py-pip/package.py +++ b/var/spack/repos/builtin/packages/py-pip/package.py @@ -2,8 +2,8 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) - import os +import sys from spack.package import * @@ -24,71 +24,19 @@ class PyPip(Package, PythonExtension): license("MIT") - version( - "23.1.2", - sha256="3ef6ac33239e4027d9a5598a381b9d30880a1477e50039db2eac6e8a8f6d1b18", - expand=False, - ) - version( - "23.0", - sha256="b5f88adff801f5ef052bcdef3daa31b55eb67b0fccd6d0106c206fa248e0463c", - expand=False, - ) - version( - "22.2.2", - sha256="b61a374b5bc40a6e982426aede40c9b5a08ff20e640f5b56977f4f91fed1e39a", - expand=False, - ) - version( - "22.1.2", - sha256="a3edacb89022ef5258bf61852728bf866632a394da837ca49eb4303635835f17", - expand=False, - ) - version( - "21.3.1", - sha256="deaf32dcd9ab821e359cd8330786bcd077604b5c5730c0b096eda46f95c24a2d", - expand=False, - ) - version( - "21.1.2", - sha256="f8ea1baa693b61c8ad1c1d8715e59ab2b93cd3c4769bacab84afcc4279e7a70e", - expand=False, - ) - version( - "20.2", - sha256="d75f1fc98262dabf74656245c509213a5d0f52137e40e8f8ed5cc256ddd02923", - expand=False, - ) - version( - "19.3", - sha256="e100a7eccf085f0720b4478d3bb838e1c179b1e128ec01c0403f84e86e0e2dfb", - expand=False, - ) - version( - "19.1.1", - sha256="993134f0475471b91452ca029d4390dc8f298ac63a712814f101cd1b6db46676", - expand=False, - ) - version( - "19.0.3", - sha256="bd812612bbd8ba84159d9ddc0266b7fbce712fc9bc98c82dee5750546ec8ec64", - expand=False, - ) - version( - "18.1", - sha256="7909d0a0932e88ea53a7014dfd14522ffef91a464daaaf5c573343852ef98550", - expand=False, - ) - version( - "10.0.1", - sha256="717cdffb2833be8409433a93746744b59505f42146e8d37de6c62b430e25d6d7", - expand=False, - ) - version( - "9.0.1", - sha256="690b762c0a8460c303c089d5d0be034fb15a5ea2b75bdf565f40421f542fefb0", - expand=False, - ) + version("23.1.2", sha256="3ef6ac33239e4027d9a5598a381b9d30880a1477e50039db2eac6e8a8f6d1b18") + version("23.0", sha256="b5f88adff801f5ef052bcdef3daa31b55eb67b0fccd6d0106c206fa248e0463c") + version("22.2.2", sha256="b61a374b5bc40a6e982426aede40c9b5a08ff20e640f5b56977f4f91fed1e39a") + version("22.1.2", sha256="a3edacb89022ef5258bf61852728bf866632a394da837ca49eb4303635835f17") + version("21.3.1", sha256="deaf32dcd9ab821e359cd8330786bcd077604b5c5730c0b096eda46f95c24a2d") + version("21.1.2", sha256="f8ea1baa693b61c8ad1c1d8715e59ab2b93cd3c4769bacab84afcc4279e7a70e") + version("20.2", sha256="d75f1fc98262dabf74656245c509213a5d0f52137e40e8f8ed5cc256ddd02923") + version("19.3", sha256="e100a7eccf085f0720b4478d3bb838e1c179b1e128ec01c0403f84e86e0e2dfb") + version("19.1.1", sha256="993134f0475471b91452ca029d4390dc8f298ac63a712814f101cd1b6db46676") + version("19.0.3", sha256="bd812612bbd8ba84159d9ddc0266b7fbce712fc9bc98c82dee5750546ec8ec64") + version("18.1", sha256="7909d0a0932e88ea53a7014dfd14522ffef91a464daaaf5c573343852ef98550") + version("10.0.1", sha256="717cdffb2833be8409433a93746744b59505f42146e8d37de6c62b430e25d6d7") + version("9.0.1", sha256="690b762c0a8460c303c089d5d0be034fb15a5ea2b75bdf565f40421f542fefb0") extends("python") depends_on("python@3.7:", when="@22:", type=("build", "run")) @@ -96,6 +44,15 @@ class PyPip(Package, PythonExtension): # Uses collections.MutableMapping depends_on("python@:3.9", when="@:19.1", type=("build", "run")) + resource( + name="pip-bootstrap", + url="https://bootstrap.pypa.io/pip/zipapp/pip-22.3.1.pyz", + checksum="c9363c70ad91d463f9492a8a2c89f60068f86b0239bd2a6aa77367aab5fefb3e", + when="platform=windows", + placement={"pip-22.3.1.pyz": "pip.pyz"}, + expand=False, + ) + def url_for_version(self, version): url = "https://files.pythonhosted.org/packages/{0}/p/pip/pip-{1}-{0}-none-any.whl" if version >= Version("21"): @@ -110,10 +67,15 @@ def install(self, spec, prefix): # itself, see: # https://discuss.python.org/t/bootstrapping-a-specific-version-of-pip/12306 whl = self.stage.archive_file - args = [os.path.join(whl, "pip")] + std_pip_args + ["--prefix=" + prefix, whl] + args = std_pip_args + ["--prefix=" + prefix, whl] + if sys.platform == "win32": + # On Windows for newer versions of pip, you must bootstrap pip first. + # In order to achieve this, use the pip.pyz zipapp version of pip to + # bootstrap the pip wheel install. + args.insert(0, os.path.join(self.stage.source_path, "pip.pyz")) + else: + args.insert(0, os.path.join(whl, "pip")) python(*args) - def setup_dependent_package(self, module, dependent_spec): - pip = dependent_spec["python"].command - pip.add_default_arg("-m", "pip") - setattr(module, "pip", pip) + def setup_dependent_package(self, module, dependent_spec: Spec): + setattr(module, "pip", python.with_default_args("-m", "pip")) diff --git a/var/spack/repos/builtin/packages/py-pivy/package.py b/var/spack/repos/builtin/packages/py-pivy/package.py index 1df73c9419fbfa..95c5ab871b49d1 100644 --- a/var/spack/repos/builtin/packages/py-pivy/package.py +++ b/var/spack/repos/builtin/packages/py-pivy/package.py @@ -16,6 +16,8 @@ class PyPivy(PythonPackage): version("0.6.8", sha256="c443dd7dd724b0bfa06427478b9d24d31e0c3b5138ac5741a2917a443b28f346") + depends_on("cxx", type="build") # generated + depends_on("coin3d") depends_on("py-setuptools", type="build") depends_on("cmake@3.18:", type="build") diff --git a/var/spack/repos/builtin/packages/py-plotly/package.py b/var/spack/repos/builtin/packages/py-plotly/package.py index 2b2a02adb13086..25cb44c4dba3e8 100644 --- a/var/spack/repos/builtin/packages/py-plotly/package.py +++ b/var/spack/repos/builtin/packages/py-plotly/package.py @@ -16,11 +16,18 @@ class PyPlotly(PythonPackage): license("MIT") + version("5.20.0", sha256="bf901c805d22032cfa534b2ff7c5aa6b0659e037f19ec1e0cca7f585918b5c89") + version("5.19.0", sha256="5ea91a56571292ade3e3bc9bf712eba0b95a1fb0a941375d978cc79432e055f4") + version("5.18.0", sha256="360a31e6fbb49d12b007036eb6929521343d6bee2236f8459915821baefa2cbb") + version("5.17.0", sha256="290d796bf7bab87aad184fe24b86096234c4c95dcca6ecbca02d02bdf17d3d97") + version("5.16.1", sha256="295ac25edeb18c893abb71dcadcea075b78fd6fdf07cee4217a4e1009667925b") + version("5.15.0", sha256="822eabe53997d5ebf23c77e1d1fcbf3bb6aa745eb05d532afd4b6f9a2e2ab02f") version("5.14.1", sha256="bcac86d7fcba3eff7260c1eddc36ca34dae2aded10a0709808446565e0e53b93") version("5.2.2", sha256="809f0674a7991daaf4f287964d617d24e9fa44463acd5a5352ebd874cfd98b07") version("2.2.0", sha256="ca668911ffb4d11fed6d7fbb12236f8ecc6a7209db192326bcb64bdb41451a58") - depends_on("python@3.6:", when="@5.2.2:", type=("build", "run")) + depends_on("python@3.6:3.11", when="@5.2.2:5.18.0", type=("build", "run")) + depends_on("python@3.8:3.11", when="@5.19.0:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-setuptools@40.8.0:", when="@5.14.1:", type="build") diff --git a/var/spack/repos/builtin/packages/py-pluggy/package.py b/var/spack/repos/builtin/packages/py-pluggy/package.py index 2efde37f3b4662..4c68dc482a7009 100644 --- a/var/spack/repos/builtin/packages/py-pluggy/package.py +++ b/var/spack/repos/builtin/packages/py-pluggy/package.py @@ -14,6 +14,7 @@ class PyPluggy(PythonPackage): license("MIT") + version("1.5.0", sha256="2cffa88e94fdc978c4c574f15f9e59b7f4201d439195c3715ca9e2486f1d0cf1") version("1.4.0", sha256="8c85c2876142a764e5b7548e7d9a0e0ddb46f5185161049a79b7e974454223be") version("1.0.0", sha256="4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159") version("0.13.0", sha256="fa5fa1622fa6dd5c030e9cad086fa19ef6a0cf6d7a2d12318e10cb49d6d68f34") @@ -23,10 +24,13 @@ class PyPluggy(PythonPackage): version("0.7.1", sha256="95eb8364a4708392bae89035f45341871286a333f749c3141c20573d2b3876e1") version("0.6.0", sha256="7f8ae7f5bdf75671a718d2daf0a64b7885f74510bcd98b1a0bb420eb9a9d0cff") - depends_on("python@3.8:", when="@1.3:", type=("build", "run")) - depends_on("python@3.7:", when="@1.1:", type=("build", "run")) - depends_on("py-setuptools@45:", when="@1.1:", type="build") - depends_on("py-setuptools", type="build") - depends_on("py-setuptools-scm@6.2.3:+toml", when="@1.1:", type="build") - depends_on("py-setuptools-scm", type="build") - depends_on("py-importlib-metadata@0.12:", when="^python@:3.7", type=("build", "run")) + with default_args(type="build"): + depends_on("py-setuptools@45:", when="@1.1:") + depends_on("py-setuptools") + depends_on("py-setuptools-scm@6.2.3:+toml", when="@1.1:") + depends_on("py-setuptools-scm") + + with default_args(type=("build", "run")): + depends_on("python@3.8:", when="@1.3:") + depends_on("python@3.7:", when="@1.1:") + depends_on("py-importlib-metadata@0.12:", when="^python@:3.7") diff --git a/var/spack/repos/builtin/packages/py-poetry-core/package.py b/var/spack/repos/builtin/packages/py-poetry-core/package.py index 83454d9ee74a0f..9e82b28a786332 100644 --- a/var/spack/repos/builtin/packages/py-poetry-core/package.py +++ b/var/spack/repos/builtin/packages/py-poetry-core/package.py @@ -22,6 +22,8 @@ class PyPoetryCore(PythonPackage): version("1.0.8", sha256="951fc7c1f8d710a94cb49019ee3742125039fc659675912ea614ac2aa405b118") version("1.0.7", sha256="98c11c755a16ef6c5673c22ca94a3802a7df4746a0853a70b6fae8b9f5cac206") + depends_on("c", type="build") # generated + depends_on("python@3.8:3", when="@1.7.0:", type=("build", "run")) depends_on("python@3.7:3", when="@1.1.0:", type=("build", "run")) depends_on("python@:3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-poetry/package.py b/var/spack/repos/builtin/packages/py-poetry/package.py index 68b2ae95e47715..0191c806bb2542 100644 --- a/var/spack/repos/builtin/packages/py-poetry/package.py +++ b/var/spack/repos/builtin/packages/py-poetry/package.py @@ -20,6 +20,8 @@ class PyPoetry(PythonPackage): version("1.1.13", sha256="b905ed610085f568aa61574e0e09260c02bff9eae12ff672af39e9f399357ac4") version("1.1.12", sha256="5c66e2357fe37b552462a88b7d31bfa2ed8e84172208becd666933c776252567") + depends_on("c", type="build") # generated + depends_on("python@3.8:3", when="@1.6.0:", type=("build", "run")) depends_on("python@3.7:3", when="@1.2.0:", type=("build", "run")) depends_on("python@2.7,3.5:3", type=("build", "run")) @@ -71,7 +73,7 @@ class PyPoetry(PythonPackage): depends_on("py-virtualenv@20.4.3:20.4.4,20.4.7:", when="@1.2", type=("build", "run")) depends_on("py-virtualenv@20.0.26:20", when="@:1.1", type=("build", "run")) depends_on("py-xattr@0.10", when="platform=darwin @1.6.1", type=("build", "run")) - depends_on("py-xattr@0.9.7:0.9", when="platform=darwin @1.2:") + depends_on("py-xattr@0.9.7:0.9", when="platform=darwin @1.2") depends_on("py-urllib3@1.26.0:1", when="@1.2") depends_on("py-dulwich@0.21.2:0.21", when="@1.6.1", type=("build", "run")) depends_on("py-dulwich@0.20.46:0.20", when="@1.2.1") diff --git a/var/spack/repos/builtin/packages/py-pomegranate/package.py b/var/spack/repos/builtin/packages/py-pomegranate/package.py index 00055adcd24ad7..0a5af32a44616e 100644 --- a/var/spack/repos/builtin/packages/py-pomegranate/package.py +++ b/var/spack/repos/builtin/packages/py-pomegranate/package.py @@ -16,6 +16,8 @@ class PyPomegranate(PythonPackage): version("0.12.0", sha256="8b00c88f7cf9cad8d38ea00ea5274821376fefb217a1128afe6b1fcac54c975a") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cython@0.22.1:", type="build") depends_on("py-numpy@1.8.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pot/package.py b/var/spack/repos/builtin/packages/py-pot/package.py index 4f7c63b602c2fa..5468559b7a7a97 100644 --- a/var/spack/repos/builtin/packages/py-pot/package.py +++ b/var/spack/repos/builtin/packages/py-pot/package.py @@ -20,6 +20,8 @@ class PyPot(PythonPackage): version("0.7.0", sha256="d4ac2bc8791f049a3166820d51e218d6c299885449b735eafef8d18c76d4ad06") + depends_on("cxx", type="build") # generated + # Avoid that CC and CXX are overridden with g++ in setup.py. patch("175.patch", when="@0.7.0") diff --git a/var/spack/repos/builtin/packages/py-pretty-errors/package.py b/var/spack/repos/builtin/packages/py-pretty-errors/package.py new file mode 100644 index 00000000000000..87ad191a49d590 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-pretty-errors/package.py @@ -0,0 +1,20 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyPrettyErrors(PythonPackage): + """Prettifies Python exception output to make it legible.""" + + homepage = "https://github.com/onelivesleft/PrettyErrors/" + pypi = "pretty-errors/pretty_errors-1.2.25.tar.gz" + + license("MIT") + + version("1.2.25", sha256="a16ba5c752c87c263bf92f8b4b58624e3b1e29271a9391f564f12b86e93c6755") + + depends_on("py-setuptools", type="build") + depends_on("py-colorama", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-projectq/package.py b/var/spack/repos/builtin/packages/py-projectq/package.py index eac6aec7f09bbf..488e540cd66b97 100644 --- a/var/spack/repos/builtin/packages/py-projectq/package.py +++ b/var/spack/repos/builtin/packages/py-projectq/package.py @@ -25,6 +25,8 @@ class PyProjectq(PythonPackage): version("develop", branch="develop") version("0.3.6", commit="fa484fe037a3a1772127bbd00fe4628ddba34611") + depends_on("cxx", type="build") # generated + # Dependencies depends_on("py-setuptools", type=("build")) depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-prompt-toolkit/package.py b/var/spack/repos/builtin/packages/py-prompt-toolkit/package.py index 70146e632ac177..e0f2933f60d45f 100644 --- a/var/spack/repos/builtin/packages/py-prompt-toolkit/package.py +++ b/var/spack/repos/builtin/packages/py-prompt-toolkit/package.py @@ -18,6 +18,7 @@ class PyPromptToolkit(PythonPackage): license("BSD-3-Clause") + version("3.0.43", sha256="3527b7af26106cbc65a040bcc84839a3566ec1b051bb0bfe953631e704b0ff7d") version("3.0.38", sha256="23ac5d50538a9a38c8bde05fecb47d0b403ecd0662857a86f886f798563d5b9b") version("3.0.31", sha256="9ada952c9d1787f52ff6d5f3484d0b4df8952787c087edf6a1f7c2cb1ea88148") version("3.0.29", sha256="bd640f60e8cecd74f0dc249713d433ace2ddc62b65ee07f96d358e0b152b6ea7") diff --git a/var/spack/repos/builtin/packages/py-protobuf/package.py b/var/spack/repos/builtin/packages/py-protobuf/package.py index b5f0171d010a95..d372dc8804157b 100644 --- a/var/spack/repos/builtin/packages/py-protobuf/package.py +++ b/var/spack/repos/builtin/packages/py-protobuf/package.py @@ -17,6 +17,8 @@ class PyProtobuf(PythonPackage): homepage = "https://developers.google.com/protocol-buffers/" pypi = "protobuf/protobuf-3.11.0.tar.gz" + version("5.26.1", sha256="8ca2a1d97c290ec7b16e4e5dff2e5ae150cc1582f55b5ab300d45cb0dfa90e51") + version("4.25.3", sha256="25b5d0b42fd000320bd7830b349e3b696435f3b329810427a6bcce6a5492cc5c") version("4.24.3", sha256="12e9ad2ec079b833176d2921be2cb24281fa591f0b119b208b788adc48c2561d") version("4.23.3", sha256="7a92beb30600332a52cdadbedb40d33fd7c8a0d7f549c440347bc606fb3fe34b") version("4.21.9", sha256="61f21493d96d2a77f9ca84fefa105872550ab5ef71d21c458eb80edcf4885a99") @@ -42,6 +44,7 @@ class PyProtobuf(PythonPackage): version("3.15.6", sha256="2b974519a2ae83aa1e31cff9018c70bbe0e303a46a598f982943c49ae1d4fcd3") version("3.15.5", sha256="be8a929c6178bb6cbe9e2c858be62fa08966a39ae758a8493a88f0ed1efb6097") version("3.15.1", sha256="824dbae3390fcc3ea1bf96748e6da951a601802894cf7e1465e72b4732538cab") + version("3.13.0", sha256="6a82e0c8bb2bf58f606040cc5814e07715b2094caeba281e2e7d0b0e2e397db5") version("3.12.2", sha256="49ef8ab4c27812a89a76fa894fe7a08f42f2147078392c0dee51d4a444ef6df5") version("3.11.2", sha256="3d7a7d8d20b4e7a8f63f62de2d192cfd8b7a53c56caba7ece95367ca2b80c574") version("3.11.1", sha256="aecdf12ef6dc7fd91713a6da93a86c2f2a8fe54840a3b1670853a2b7402e77c9") @@ -59,6 +62,8 @@ class PyProtobuf(PythonPackage): version("3.3.0", sha256="1cbcee2c45773f57cb6de7ee0eceb97f92b9b69c0178305509b162c0160c1f04") version("3.0.0", sha256="ecc40bc30f1183b418fe0ec0c90bc3b53fa1707c4205ee278c6b90479e5b6ff5") + depends_on("c", type="build") # generated + variant("cpp", default=False, when="@:4.21", description="Enable the cpp implementation") depends_on("python", type=("build", "link", "run")) @@ -75,6 +80,7 @@ class PyProtobuf(PythonPackage): depends_on(f"protobuf@3.{ver}", when=f"@3.{ver}+cpp") conflicts("+cpp", when="^python@3.11:") + conflicts("%gcc@14", when="@:4.24.3") @property def build_directory(self): diff --git a/var/spack/repos/builtin/packages/py-psalg/package.py b/var/spack/repos/builtin/packages/py-psalg/package.py index 9302655371795f..98a464a2c6f787 100644 --- a/var/spack/repos/builtin/packages/py-psalg/package.py +++ b/var/spack/repos/builtin/packages/py-psalg/package.py @@ -16,6 +16,9 @@ class PyPsalg(PythonPackage): version("3.3.37", sha256="127a5ae44c9272039708bd877849a3af354ce881fde093a2fc6fe0550b698b72") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("psalg") diff --git a/var/spack/repos/builtin/packages/py-psana/package.py b/var/spack/repos/builtin/packages/py-psana/package.py index a35d1e08a38203..b9f2e4a9e97bca 100644 --- a/var/spack/repos/builtin/packages/py-psana/package.py +++ b/var/spack/repos/builtin/packages/py-psana/package.py @@ -17,6 +17,9 @@ class PyPsana(PythonPackage): version("3.3.37", sha256="127a5ae44c9272039708bd877849a3af354ce881fde093a2fc6fe0550b698b72") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("setup.patch") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-psutil/package.py b/var/spack/repos/builtin/packages/py-psutil/package.py index 4441e530034f11..78f0e9802b6556 100644 --- a/var/spack/repos/builtin/packages/py-psutil/package.py +++ b/var/spack/repos/builtin/packages/py-psutil/package.py @@ -27,6 +27,8 @@ class PyPsutil(PythonPackage): version("5.4.5", sha256="ebe293be36bb24b95cdefc5131635496e88b17fabbcf1e4bc9b5c01f5e489cfe") version("5.0.1", sha256="9d8b7f8353a2b2eb6eb7271d42ec99d0d264a9338a37be46424d56b4e473b39e") + depends_on("c", type="build") # generated + # pyproject.toml depends_on("py-setuptools@43:", when="@5.9.4:", type="build") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-psyclone/package.py b/var/spack/repos/builtin/packages/py-psyclone/package.py index ce5b26621f7e00..a2a41482d4b4ea 100644 --- a/var/spack/repos/builtin/packages/py-psyclone/package.py +++ b/var/spack/repos/builtin/packages/py-psyclone/package.py @@ -34,6 +34,8 @@ class PyPsyclone(PythonPackage): version("2.0.0", sha256="94766ffda760404af99f85d70341376192e4a1b8e16e7ae5df980038898a9c41") version("1.5.1", sha256="f053ad7316623b2a4002afc79607abda3b22306645e86f2312d9f3fe56d312dc") + depends_on("fortran", type="build") # generated + # Current dependencies depends_on("py-setuptools", type="build") depends_on("py-pyparsing", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-psycopg2/package.py b/var/spack/repos/builtin/packages/py-psycopg2/package.py index cc6e805592912e..ca4d21ca8ac0f1 100644 --- a/var/spack/repos/builtin/packages/py-psycopg2/package.py +++ b/var/spack/repos/builtin/packages/py-psycopg2/package.py @@ -16,6 +16,8 @@ class PyPsycopg2(PythonPackage): version("2.9.1", sha256="de5303a6f1d0a7a34b9d40e4d3bef684ccc44a49bbe3eb85e3c0bffb4a131b7c") version("2.8.6", sha256="fb23f6c71107c37fd667cb4ea363ddeb936b348bbd6449278eb92c189699f543") + depends_on("c", type="build") # generated + # https://www.psycopg.org/docs/install.html#prerequisites # https://github.com/psycopg/psycopg2/blob/master/doc/src/install.rst # https://www.psycopg.org/docs/news.html#news diff --git a/var/spack/repos/builtin/packages/py-py-spy/package.py b/var/spack/repos/builtin/packages/py-py-spy/package.py index c150d6e9476bc4..a13c6d4e09a44c 100644 --- a/var/spack/repos/builtin/packages/py-py-spy/package.py +++ b/var/spack/repos/builtin/packages/py-py-spy/package.py @@ -17,6 +17,8 @@ class PyPySpy(Package): version("0.3.8", sha256="9dbfd0ea79ef31a2966891e86cf6238ed3831938cf562e71848e07b7009cf57d") version("0.3.3", sha256="41454d3d9132da45c72f7574faaff65f40c757720293a277ffa5ec5a4b44f902") + depends_on("c", type="build") # generated + # TODO: uses cargo to download and build dozens of dependencies. # Need to figure out how to manage these with Spack once we have a # CargoPackage base class. diff --git a/var/spack/repos/builtin/packages/py-py2bit/package.py b/var/spack/repos/builtin/packages/py-py2bit/package.py index ea15abb9e10417..08ad9f8ebc6a50 100644 --- a/var/spack/repos/builtin/packages/py-py2bit/package.py +++ b/var/spack/repos/builtin/packages/py-py2bit/package.py @@ -15,4 +15,6 @@ class PyPy2bit(PythonPackage): version("0.2.1", sha256="34f7ac22be0eb4b5493063826bcc2016a78eb216bb7130890b50f3572926aeb1") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-py4j/package.py b/var/spack/repos/builtin/packages/py-py4j/package.py index 17a251913bbe3f..26b4076f4509ae 100644 --- a/var/spack/repos/builtin/packages/py-py4j/package.py +++ b/var/spack/repos/builtin/packages/py-py4j/package.py @@ -15,6 +15,9 @@ class PyPy4j(PythonPackage): license("BSD-3-Clause") + maintainers("teaguesterling") + + version("0.10.9.7", sha256="0b6e5315bb3ada5cf62ac651d107bb2ebc02def3dee9d9548e3baac644ea8dbb") version("0.10.9.5", sha256="276a4a3c5a2154df1860ef3303a927460e02e97b047dc0a47c1c3fb8cce34db6") version("0.10.9.3", sha256="0d92844da4cb747155b9563c44fc322c9a1562b3ef0979ae692dbde732d784dd") version("0.10.9", sha256="36ec57f43ff8ced260a18aa9a4e46c3500a730cac8860e259cbaa546c2b9db2f") @@ -23,7 +26,10 @@ class PyPy4j(PythonPackage): version("0.10.4", sha256="406fbfdbcbbb398739f61fafd25724670a405a668eb08c1721d832eadce06aae") version("0.10.3", sha256="f4570108ad014dd52a65c2288418e31cb8227b5ecc39ad7fc7fe98314f7a26f2") + variant("java", default=True, description="Require java via Spack instead of using system JRE") + depends_on("py-setuptools", type="build") + depends_on("java", when="+java", type="run") def url_for_version(self, version): url = "https://pypi.io/packages/source/p/py4j/" diff --git a/var/spack/repos/builtin/packages/py-pyaml-env/package.py b/var/spack/repos/builtin/packages/py-pyaml-env/package.py new file mode 100644 index 00000000000000..298fc9f778397e --- /dev/null +++ b/var/spack/repos/builtin/packages/py-pyaml-env/package.py @@ -0,0 +1,20 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyPyamlEnv(PythonPackage): + """Provides yaml file parsing with environment variable resolution""" + + homepage = "https://github.com/mkaranasou/pyaml_env" + pypi = "pyaml_env/pyaml_env-1.2.1.tar.gz" + + license("MIT", checked_by="A_N_Other") + + version("1.2.1", sha256="6d5dc98c8c82df743a132c196e79963050c9feb05b0a6f25f3ad77771d3d95b0") + + depends_on("py-setuptools", type="build") + depends_on("py-pyyaml@5:7", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pyarrow/package.py b/var/spack/repos/builtin/packages/py-pyarrow/package.py index 99d7c8adc8fe34..3d6bf8acded8a1 100644 --- a/var/spack/repos/builtin/packages/py-pyarrow/package.py +++ b/var/spack/repos/builtin/packages/py-pyarrow/package.py @@ -20,6 +20,8 @@ class PyPyarrow(PythonPackage, CudaPackage): license("Apache-2.0") + version("16.1.0", sha256="15fbb22ea96d11f0b5768504a3f961edab25eaf4197c341720c4a387f6c60315") + version("15.0.2", sha256="9c9bc803cb3b7bfacc1e96ffbfd923601065d9d3f911179d81e72d99fd74a3d9") version("14.0.2", sha256="36cef6ba12b499d864d1def3e990f97949e0b79400d08b7cf74504ffbd3eb025") version("13.0.0", sha256="83333726e83ed44b0ac94d8d7a21bbdee4a05029c3b1e8db58a863eec8fd8a33") version("12.0.1", sha256="cce317fc96e5b71107bf1f9f184d5e54e2bd14bbf3f9a3d62819961f0af86fec") @@ -35,6 +37,8 @@ class PyPyarrow(PythonPackage, CudaPackage): version("0.11.0", sha256="07a6fd71c5d7440f2c42383dd2c5daa12d7f0a012f1e88288ed08a247032aead") version("0.9.0", sha256="7db8ce2f0eff5a00d6da918ce9f9cfec265e13f8a119b4adb1595e5b19fd6242") + depends_on("cxx", type="build") # generated + variant("parquet", default=False, description="Build with Parquet support") variant("orc", default=False, description="Build with orc support") variant("dataset", default=False, description="Build with Dataset support") @@ -61,7 +65,11 @@ class PyPyarrow(PythonPackage, CudaPackage): depends_on("py-pip@:23.0", type="build") depends_on("py-numpy@1.16.6:", type=("build", "run"), when="@3:") - depends_on("py-numpy@1.14:", type=("build", "run"), when="@0.15:") + # Prior to python 3.9 numpy must be >=0.14,<1.25 + depends_on("py-numpy@0.14:1.24", when="^python@:3.8", type=("build", "run")) + depends_on("py-numpy@1.25:", when="^python@3.9:", type=("build", "run")) + # https://github.com/apache/arrow/issues/39532 + depends_on("py-numpy@:1", when="@:15", type=("build", "run")) arrow_versions = ( "@0.9.0", @@ -78,6 +86,8 @@ class PyPyarrow(PythonPackage, CudaPackage): "@12.0.1", "@13.0.0", "@14.0.2", + "@15.0.2", + "@16.1.0", ) for v in arrow_versions: depends_on("arrow+python" + v, when=v) diff --git a/var/spack/repos/builtin/packages/py-pybedtools/package.py b/var/spack/repos/builtin/packages/py-pybedtools/package.py index 5b15211bece085..b0690d4d30e288 100644 --- a/var/spack/repos/builtin/packages/py-pybedtools/package.py +++ b/var/spack/repos/builtin/packages/py-pybedtools/package.py @@ -14,6 +14,7 @@ class PyPybedtools(PythonPackage): license("MIT") + version("0.10.0", sha256="1a6fbaad23b013becc741d7d5922a2df03e391bc44ff92772ffb7dd456711161") version("0.9.0", sha256="9267c92cd764173449d9c31baedac0659b4eccc3d7c05e22ec378f86c0fc30a3") version("0.8.0", sha256="4eebd2cd1764ee1c604fd881703c3e329195485350b987b7fb8db42d232984f6") version("0.7.10", sha256="518a2311bd33f29cf2ee8fc1a028dda8c8e380c9fc83fcb0fbaa206933174b50") @@ -25,6 +26,8 @@ class PyPybedtools(PythonPackage): version("0.7.4", sha256="15cfae9e8a207ded403ad9fa2e77f09d14c2fe377d1bc5f8b063647e2d0554e0") version("0.6.9", sha256="56915b3e2200c6fb56260a36f839e66ce27d7dd3ef55fba278c3931b786fbfd1") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@0.6c5:", type="build") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-pybigwig/package.py b/var/spack/repos/builtin/packages/py-pybigwig/package.py index 814fa8d37fefee..cab48156ac11c3 100644 --- a/var/spack/repos/builtin/packages/py-pybigwig/package.py +++ b/var/spack/repos/builtin/packages/py-pybigwig/package.py @@ -16,6 +16,8 @@ class PyPybigwig(PythonPackage): version("0.3.12", sha256="e01991790ece496bf6d3f00778dcfb136dd9ca0fd28acc1b3fb43051ad9b8403") version("0.3.4", sha256="8c97a19218023190041c0e426f1544f7a4944a7bb4568faca1d85f1975af9ee2") + depends_on("c", type="build") # generated + variant("numpy", default=True, description="Enable support for numpy integers and vectors") patch("python3_curl.patch", when="@:0.3.12 ^python@3:") diff --git a/var/spack/repos/builtin/packages/py-pybind11/package.py b/var/spack/repos/builtin/packages/py-pybind11/package.py index b4baeeb0355e37..46db4dc9d1cfb7 100644 --- a/var/spack/repos/builtin/packages/py-pybind11/package.py +++ b/var/spack/repos/builtin/packages/py-pybind11/package.py @@ -27,6 +27,7 @@ class PyPybind11(CMakePackage, PythonExtension): maintainers("ax3l") version("master", branch="master") + version("2.12.0", sha256="bf8f242abd1abcd375d516a7067490fb71abd79519a282d22b6e4d19282185a7") version("2.11.1", sha256="d475978da0cdc2d43b73f30910786759d593a9d8ee05b1b6846d1eb16c6d2e0c") version("2.11.0", sha256="7af30a84c6810e721829c4646e31927af9d8861e085aa5dd37c3c8b8169fcda1") version("2.10.4", sha256="832e2f309c57da9c1e6d4542dedd34b24e4192ecb4d62f6f4866a737454c9970") @@ -52,6 +53,8 @@ class PyPybind11(CMakePackage, PythonExtension): version("2.1.1", sha256="f2c6874f1ea5b4ad4ffffe352413f7d2cd1a49f9050940805c2a082348621540") version("2.1.0", sha256="2860f2b8d0c9f65f0698289a161385f59d099b7ead1bf64e8993c486f2b93ee0") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@42:", type="build") depends_on("py-pytest", type="test") depends_on("py-pip", type="build") @@ -101,7 +104,6 @@ def install_test(self): with working_dir("spack-test", create=True): # test include helper points to right location - python = self.spec["python"].command py_inc = python( "-c", "import pybind11 as py; print(py.get_include())", output=str ).strip() diff --git a/var/spack/repos/builtin/packages/py-pybrain/package.py b/var/spack/repos/builtin/packages/py-pybrain/package.py index 17d34438a0e995..0fc1558d43f742 100644 --- a/var/spack/repos/builtin/packages/py-pybrain/package.py +++ b/var/spack/repos/builtin/packages/py-pybrain/package.py @@ -18,5 +18,7 @@ class PyPybrain(PythonPackage): version("0.3.3.post", commit="dcdf32ba1805490cefbc0bdeb227260d304fdb42") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-scipy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pycairo/package.py b/var/spack/repos/builtin/packages/py-pycairo/package.py index c9eccce8077566..1f8d0e61066485 100644 --- a/var/spack/repos/builtin/packages/py-pycairo/package.py +++ b/var/spack/repos/builtin/packages/py-pycairo/package.py @@ -20,6 +20,8 @@ class PyPycairo(PythonPackage): version("1.24.0", sha256="1444d52f1bb4cc79a4a0c0fe2ccec4bd78ff885ab01ebe1c0f637d8392bcafb6") version("1.20.0", sha256="5695a10cb7f9ae0d01f665b56602a845b0a8cb17e2123bfece10c2e58552468c") + depends_on("c", type="build") # generated + depends_on("python@3.8:", when="@1.23:", type=("build", "run")) depends_on("python@3.6:3", when="@1.20:1.22", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pycares/package.py b/var/spack/repos/builtin/packages/py-pycares/package.py index e8dba26fb7d74b..c13e54cdeff154 100644 --- a/var/spack/repos/builtin/packages/py-pycares/package.py +++ b/var/spack/repos/builtin/packages/py-pycares/package.py @@ -18,6 +18,8 @@ class PyPycares(PythonPackage): version("3.0.0", sha256="28dc2bd59cf20399a6af4383cc8f57970cfca8b808ca05d6493812862ef0ca9c") + depends_on("c", type="build") # generated + depends_on("python@2.6:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-cffi", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pycifrw/package.py b/var/spack/repos/builtin/packages/py-pycifrw/package.py index 9d9474cf7b7a6c..37d6c4c37a3925 100644 --- a/var/spack/repos/builtin/packages/py-pycifrw/package.py +++ b/var/spack/repos/builtin/packages/py-pycifrw/package.py @@ -17,4 +17,6 @@ class PyPycifrw(PythonPackage): version("4.4.1", sha256="cef7662f475e0eb78a55c2d55774d474e888c96b0539e5f08550afa902cdc4e1") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pycocotools/package.py b/var/spack/repos/builtin/packages/py-pycocotools/package.py index a751e5e935e42f..46117215faec02 100644 --- a/var/spack/repos/builtin/packages/py-pycocotools/package.py +++ b/var/spack/repos/builtin/packages/py-pycocotools/package.py @@ -15,6 +15,9 @@ class PyPycocotools(PythonPackage): version("2.0.6", sha256="7fe089b05cc18e806dcf3bd764708d86dab922a100f3734eb77fb77a70a1d18c") version("2.0.2", sha256="24717a12799b4471c2e54aa210d642e6cd4028826a1d49fcc2b0e3497e041f1a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python", type=("build", "link", "run")) depends_on("py-cython@0.27.3:", when="@2.0.4:", type="build") depends_on("py-cython@0.27.3:", when="@:2.0.3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pycompadre/package.py b/var/spack/repos/builtin/packages/py-pycompadre/package.py index b749b164c58e61..559cb5f0e70147 100644 --- a/var/spack/repos/builtin/packages/py-pycompadre/package.py +++ b/var/spack/repos/builtin/packages/py-pycompadre/package.py @@ -22,6 +22,10 @@ class PyPycompadre(PythonPackage): version("master", branch="master", preferred=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("trilinos", default=False, description="Use Kokkos from Trilinos") variant( "debug", diff --git a/var/spack/repos/builtin/packages/py-pycortex/package.py b/var/spack/repos/builtin/packages/py-pycortex/package.py index 9817e95d5de6c2..261af67f219003 100644 --- a/var/spack/repos/builtin/packages/py-pycortex/package.py +++ b/var/spack/repos/builtin/packages/py-pycortex/package.py @@ -20,6 +20,8 @@ class PyPycortex(PythonPackage): version("1.2.2", sha256="ac46ed6a1dc727c3126c2b5d7916fc0ac21a6510c32a5edcd3b8cfb7b2128414") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") depends_on("py-future", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pycparser/package.py b/var/spack/repos/builtin/packages/py-pycparser/package.py index e5f085dee1b069..3626a5f75528c2 100644 --- a/var/spack/repos/builtin/packages/py-pycparser/package.py +++ b/var/spack/repos/builtin/packages/py-pycparser/package.py @@ -21,5 +21,7 @@ class PyPycparser(PythonPackage): version("2.17", sha256="0aac31e917c24cb3357f5a4d5566f2cc91a19ca41862f6c3c22dc60a629673b6") version("2.13", sha256="b399599a8a0e386bfcbc5e01a38d79dd6e926781f9e358cd5512f41ab7d20eb7") + depends_on("c", type="build") # generated + depends_on("python@2.7:2.8,3.4:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pycrypto/package.py b/var/spack/repos/builtin/packages/py-pycrypto/package.py index acfd315a041660..a047548c0806a7 100644 --- a/var/spack/repos/builtin/packages/py-pycrypto/package.py +++ b/var/spack/repos/builtin/packages/py-pycrypto/package.py @@ -14,5 +14,7 @@ class PyPycrypto(PythonPackage): version("2.6.1", sha256="f2ce1e989b272cfcb677616763e0a2e7ec659effa67a88aa92b3a65528f60a3c") + depends_on("c", type="build") # generated + # depends_on('py-setuptools', type='build') depends_on("gmp") diff --git a/var/spack/repos/builtin/packages/py-pycryptodome/package.py b/var/spack/repos/builtin/packages/py-pycryptodome/package.py index 73298b196d199d..f3b013985a52f2 100644 --- a/var/spack/repos/builtin/packages/py-pycryptodome/package.py +++ b/var/spack/repos/builtin/packages/py-pycryptodome/package.py @@ -15,4 +15,6 @@ class PyPycryptodome(PythonPackage): version("3.16.0", sha256="0e45d2d852a66ecfb904f090c3f87dc0dfb89a499570abad8590f10d9cffb350") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pycuda/package.py b/var/spack/repos/builtin/packages/py-pycuda/package.py index 3cb89290b84d74..2115934ea60830 100644 --- a/var/spack/repos/builtin/packages/py-pycuda/package.py +++ b/var/spack/repos/builtin/packages/py-pycuda/package.py @@ -22,6 +22,8 @@ class PyPycuda(PythonPackage): version("2019.1.2", sha256="ada56ce98a41f9f95fe18809f38afbae473a5c62d346cfa126a2d5477f24cc8a") version("2016.1.2", sha256="a7dbdac7e2f0c0d2ad98f5f281d5a9d29d6673b3c20210e261b96e9a2d0b6e37") + depends_on("cxx", type="build") # generated + @run_before("install") def configure(self): pyver = self.spec["python"].version.up_to(2).joined diff --git a/var/spack/repos/builtin/packages/py-pycurl/package.py b/var/spack/repos/builtin/packages/py-pycurl/package.py index 79a95c85735425..2a2e0993132f55 100644 --- a/var/spack/repos/builtin/packages/py-pycurl/package.py +++ b/var/spack/repos/builtin/packages/py-pycurl/package.py @@ -19,6 +19,8 @@ class PyPycurl(PythonPackage): version("7.44.1", sha256="5bcef4d988b74b99653602101e17d8401338d596b9234d263c728a0c3df003e8") version("7.43.0", sha256="aa975c19b79b6aa6c0518c0cc2ae33528900478f0b500531dbcdbf05beec584c") + depends_on("c", type="build") # generated + depends_on("python@2.6:", type=("build", "run")) depends_on("python@3.5:", when="@7.44.1:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyeda/package.py b/var/spack/repos/builtin/packages/py-pyeda/package.py index 83f9bc1a6f63e1..01627e5c18157b 100644 --- a/var/spack/repos/builtin/packages/py-pyeda/package.py +++ b/var/spack/repos/builtin/packages/py-pyeda/package.py @@ -16,5 +16,7 @@ class PyPyeda(PythonPackage): version("0.28.0", sha256="07185f458d5d0b2ba5058da8b95dad6ab7684ceaf41237a25bcd3f005490f59d") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("python@3.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pyelftools/package.py b/var/spack/repos/builtin/packages/py-pyelftools/package.py index 5699b1b14ecd8f..bbaf9d8b44889e 100644 --- a/var/spack/repos/builtin/packages/py-pyelftools/package.py +++ b/var/spack/repos/builtin/packages/py-pyelftools/package.py @@ -23,4 +23,7 @@ class PyPyelftools(PythonPackage): version("0.24", sha256="e9dd97d685a5b96b88a988dabadb88e5a539b64cd7d7927fac9a7368dc4c459c") version("0.23", sha256="fc57aadd096e8f9b9b03f1a9578f673ee645e1513a5ff0192ef439e77eab21de") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyerfa/package.py b/var/spack/repos/builtin/packages/py-pyerfa/package.py index 6b7e51ed2e4022..719fd60d75a4fd 100644 --- a/var/spack/repos/builtin/packages/py-pyerfa/package.py +++ b/var/spack/repos/builtin/packages/py-pyerfa/package.py @@ -22,12 +22,18 @@ class PyPyerfa(PythonPackage): license("BSD-3-Clause") + version("2.0.1.1", sha256="dbac74ef8d3d3b0f22ef0ad3bbbdb30b2a9e10570b1fa5a98be34c7be36c9a6b") version("2.0.0.1", sha256="2fd4637ffe2c1e6ede7482c13f583ba7c73119d78bef90175448ce506a0ede30") + depends_on("c", type="build") # generated + # From setup.cfg depends_on("python@3.7:", type=("build", "run")) + depends_on("py-numpy@1.25:2", when="@2.0.1.1", type=("build", "run")) depends_on("py-numpy@1.17:", type=("build", "run")) + depends_on("py-setuptools-scm@6.2:", when="@2.0.1.1", type="build") depends_on("py-setuptools-scm@3.4:+toml", type="build") + # From pyproject.toml depends_on("py-setuptools@42:", type="build") depends_on("py-packaging", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyfits/package.py b/var/spack/repos/builtin/packages/py-pyfits/package.py index 8abe148fdb72df..cc21bd31a92890 100644 --- a/var/spack/repos/builtin/packages/py-pyfits/package.py +++ b/var/spack/repos/builtin/packages/py-pyfits/package.py @@ -15,5 +15,7 @@ class PyPyfits(PythonPackage): version("3.5", sha256="fd32596ee09170a70ddc87d0dfc5503d860ef6b68abcff486d7aa6993dff6162") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pyfr/package.py b/var/spack/repos/builtin/packages/py-pyfr/package.py index 48c328be64184e..482a64854e936d 100644 --- a/var/spack/repos/builtin/packages/py-pyfr/package.py +++ b/var/spack/repos/builtin/packages/py-pyfr/package.py @@ -24,46 +24,56 @@ class PyPyfr(PythonPackage, CudaPackage, ROCmPackage): version("master", branch="master") # pypi releases + version( + "2.0.3", + sha256="1fd2ca377596ab541d929d2c7b2d27e376e21b5dd6c4c0e7653bbb53864dee61", + preferred=True, + ) + version("2.0.2", sha256="2c6bf460ffec446a933451792c09d3cd85d6703f14636d99810d61823b8d92c7") version("1.15.0", sha256="6a634b9d32447f45d3c24c9de0ed620a0a0a781be7cc5e57b1c1bf44a4650d8d") version("1.14.0", sha256="ebf40ce0896cce9ac802e03fd9430b5be30ea837c31224531a6d5fd68f820766") version("1.13.0", sha256="ac6ecec738d4e23799ab8c50dea9bdbd7d37bc971bd33f22720c5a230b8e7b2f") - variant("metis", default=True, description="Metis for mesh partitioning") - variant("scotch", default=False, description="Scotch for mesh partitioning") + variant("metis", default=False, when="@:1.15.0", description="Metis for mesh partitioning") + variant("scotch", default=True, description="Scotch for mesh partitioning") variant("cuda", default=False, description="CUDA backend support") variant("hip", default=False, description="HIP backend support") variant("libxsmm", default=True, description="LIBXSMM for OpenMP backend") - variant("scipy", default=True, description="Scipy acceleration for point sampling") # Required dependencies - depends_on("python@3.9:", type=("build", "run")) - depends_on("py-setuptools", type="build") + depends_on("python@3.9:", when="@:1.15.0", type=("build", "run")) + depends_on("python@3.10:", when="@2.0.2:", type=("build", "run")) + depends_on("py-setuptools", type=("build", "run")) depends_on("py-gimmik@2.3:2", when="@:1.14.0", type=("build", "run")) - depends_on("py-gimmik@3", when="@1.15.0:", type=("build", "run")) + depends_on("py-gimmik@3", when="@1.15.0", type=("build", "run")) + depends_on("py-gimmik@3.2.1:", when="@2.0.2:", type=("build", "run")) depends_on("py-h5py@2.10:", type=("build", "run")) depends_on("py-mako@1.0.0:", type=("build", "run")) depends_on("py-mpi4py@3.1.0:", type=("build", "run")) - depends_on("py-numpy@1.20:", type=("build", "run")) + depends_on("py-numpy@1.20:", when="@:1.15.0", type=("build", "run")) + depends_on("py-numpy@1.26.4:", when="@2.0.2:", type=("build", "run")) depends_on("py-platformdirs@2.2.0:", type=("build", "run")) depends_on("py-pytools@2016.2.1:", type=("build", "run")) + depends_on("py-rtree@1.0.1:", when="@2.0.2:", type=("build", "run")) # Optional dependencies - depends_on("py-scipy", when="+scipy", type=("build", "run")) - depends_on("metis@5.0:", when="+metis", type=("run")) + depends_on("metis@5.0.0:5.1.0", when="@:1.15.0 +metis", type=("run")) depends_on("scotch@7.0.1: +link_error_lib", when="+scotch", type=("run")) depends_on("cuda@8.0: +allow-unsupported-compilers", when="@:1.14.0 +cuda", type=("run")) depends_on("cuda@11.4.0: +allow-unsupported-compilers", when="@1.15.0: +cuda", type=("run")) - depends_on("rocblas@5.2.0:", when="+hip", type=("run")) + depends_on("rocblas@5.2.0:", when="@:1.15.0 +hip", type=("run")) + depends_on("rocblas@6.0.0:", when="@2.0.2: +hip", type=("run")) depends_on("libxsmm@1.18:+shared blas=0", when="+libxsmm", type=("run")) - # Conflicts for compilers not supporting OpenMP 5.1+ from v1.15.0: - conflicts("%gcc@:11", when="@1.15.0: +libxsmm", msg="OpenMP 5.1+ supported compiler required!") - - # Explicitly add dependencies to PYFR_LIBRARY_PATH environment variable + # Explicitly add dependencies to environment variables def setup_run_environment(self, env): - deps = ["metis", "scotch", "libxsmm", "cuda", "hip", "rocblas"] + deps = ["metis", "scotch", "libxsmm", "hip", "rocblas"] pyfr_library_path = [] for dep in deps: if "+{}".format(dep) in self.spec: pyfr_library_path.extend(self.spec[dep].libs.directories) env.set("PYFR_LIBRARY_PATH", ":".join(pyfr_library_path)) + + # LD_LIBRARY_PATH needed for cuda + if "+cuda" in self.spec: + env.prepend_path("LD_LIBRARY_PATH", self.spec["cuda"].libs.directories[0]) diff --git a/var/spack/repos/builtin/packages/py-pygdal/package.py b/var/spack/repos/builtin/packages/py-pygdal/package.py index 2e995e8bbeaf8d..50fef6a1ce401d 100644 --- a/var/spack/repos/builtin/packages/py-pygdal/package.py +++ b/var/spack/repos/builtin/packages/py-pygdal/package.py @@ -30,6 +30,9 @@ class PyPygdal(PythonPackage): version("2.4.1.6", sha256="5d1af98ad09f59e34e3b332cf20630b532b33c7120295aaaabbccebf58a11aa4") version("2.4.0.6", sha256="728d11f3ecae0cd3493cd27dab599a0b6184f5504cc172d49400d88ea2b24a9c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.6:", when="@3.3:", type="build") depends_on("py-setuptools", type="build") depends_on("py-numpy@1.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pygeos/package.py b/var/spack/repos/builtin/packages/py-pygeos/package.py index 773d42c94d67f9..2b4a843dbdfc88 100644 --- a/var/spack/repos/builtin/packages/py-pygeos/package.py +++ b/var/spack/repos/builtin/packages/py-pygeos/package.py @@ -25,6 +25,8 @@ class PyPygeos(PythonPackage): version("0.9", sha256="c0584b20e95f80ee57277a6eb1e5d7f86600f8b1ef3c627d238e243afdcc0cc7") version("0.8", sha256="45b7e1aaa5fc9ff53565ef089fb75c53c419ace8cee18385ec1d7c1515c17cbc") + depends_on("c", type="build") # generated + depends_on("python", type=("build", "link", "run")) depends_on("py-cython@0.29:0", when="@0.14:", type="build") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-pygit2/package.py b/var/spack/repos/builtin/packages/py-pygit2/package.py index f5cf5c4e3fffca..0ce4e292d887bf 100644 --- a/var/spack/repos/builtin/packages/py-pygit2/package.py +++ b/var/spack/repos/builtin/packages/py-pygit2/package.py @@ -20,6 +20,8 @@ class PyPygit2(PythonPackage): version("1.4.0", sha256="cbeb38ab1df9b5d8896548a11e63aae8a064763ab5f1eabe4475e6b8a78ee1c8") version("1.3.0", sha256="0be93f6a8d7cbf0cc79ae2f0afb1993fc055fc0018c27e2bd01ba143e51d4452") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") # https://www.pygit2.org/install.html#version-numbers depends_on("libgit2@1.6", when="@1.12") diff --git a/var/spack/repos/builtin/packages/py-pygments/package.py b/var/spack/repos/builtin/packages/py-pygments/package.py index 3b661527f1ac8b..c2837796e689d4 100644 --- a/var/spack/repos/builtin/packages/py-pygments/package.py +++ b/var/spack/repos/builtin/packages/py-pygments/package.py @@ -10,11 +10,12 @@ class PyPygments(PythonPackage): """Pygments is a syntax highlighting package written in Python.""" homepage = "https://pygments.org/" - pypi = "Pygments/Pygments-2.4.2.tar.gz" + pypi = "Pygments/pygments-2.18.0.tar.gz" git = "https://github.com/pygments/pygments.git" license("BSD-2-Clause") + version("2.18.0", sha256="786ff802f32e91311bff3889f6e9a86e81505fe99f2735bb6d60ae0c5004f199") version("2.16.1", sha256="1daff0494820c69bc8941e407aa20f577374ee88364ee10a98fdbe0aece96e29") version("2.16.0", sha256="4f6df32f21dca07a54a0a130bda9a25d2241e9e0a206841d061c85a60cc96145") version("2.15.1", sha256="8ace4d3c1dd481894b2005f560ead0f9f19ee64fe983366be1a21e171d12775c") @@ -29,6 +30,13 @@ class PyPygments(PythonPackage): version("2.0.1", sha256="5e039e1d40d232981ed58914b6d1ac2e453a7e83ddea22ef9f3eeadd01de45cb") version("2.0.2", sha256="7320919084e6dac8f4540638a46447a3bd730fca172afc17d2c03eed22cf4f51") - depends_on("python@3.7:", when="@2.15:", type=("build", "run")) - depends_on("py-setuptools@61:", when="@2.15:", type=("build", "run")) - depends_on("py-setuptools", type=("build", "run")) + depends_on("py-hatchling", when="@2.17:", type="build") + depends_on("py-setuptools@61:", when="@2.15:2.16", type=("build", "run")) + depends_on("py-setuptools", when="@:2.14", type=("build", "run")) + + def url_for_version(self, version): + url = "https://files.pythonhosted.org/packages/source/P/Pygments/{}-{}.tar.gz" + name = "Pygments" + if version >= Version("2.17"): + name = name.lower() + return url.format(name, version) diff --git a/var/spack/repos/builtin/packages/py-pygmt/package.py b/var/spack/repos/builtin/packages/py-pygmt/package.py new file mode 100644 index 00000000000000..a900cd043c0d76 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-pygmt/package.py @@ -0,0 +1,31 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyPygmt(PythonPackage): + """A Python interface for the Generic Mapping Tools.""" + + homepage = "https://github.com/GenericMappingTools/pygmt" + pypi = "pygmt/pygmt-0.9.0.tar.gz" + + maintainers("snehring") + + license("BSD-3-Clause", checked_by="snehring") + + version("0.9.0", sha256="1090be7a3745e982af130a0289b9ceb60289b9c2c50fc2e0f681004ed7a1a20e") + + depends_on("python@3.9:3", type=("build", "run")) + + depends_on("py-setuptools@64:", type="build") + depends_on("py-setuptools-scm@6.2:", type="build") + + depends_on("py-numpy@1.21:", type=("build", "run")) + depends_on("py-pandas", type=("build", "run")) + depends_on("py-xarray", type=("build", "run")) + depends_on("py-netcdf4", type=("build", "run")) + depends_on("py-packaging", type=("build", "run")) + depends_on("gmt@6.3.0:+graphicsmagick", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pygobject/package.py b/var/spack/repos/builtin/packages/py-pygobject/package.py index cb926dcd9f54f7..a853bf860dbcd7 100644 --- a/var/spack/repos/builtin/packages/py-pygobject/package.py +++ b/var/spack/repos/builtin/packages/py-pygobject/package.py @@ -31,6 +31,8 @@ class PyPygobject(PythonPackage): deprecated=True, ) + depends_on("c", type="build") # generated + extends("python") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pygpu/package.py b/var/spack/repos/builtin/packages/py-pygpu/package.py index f0457335956f04..3a92491d5b05ca 100644 --- a/var/spack/repos/builtin/packages/py-pygpu/package.py +++ b/var/spack/repos/builtin/packages/py-pygpu/package.py @@ -22,6 +22,8 @@ class PyPygpu(PythonPackage): version("0.6.1", sha256="b2466311e0e3bacdf7a586bba0263f6d232bf9f8d785e91ddb447653741e6ea5") version("0.6.0", sha256="a58a0624e894475a4955aaea25e82261c69b4d22c8f15ec07041a4ba176d35af") + depends_on("c", type="build") # generated + depends_on("python", type=("build", "link", "run")) depends_on("libgpuarray@0.7.6", when="@0.7.6") depends_on("libgpuarray@0.7.5", when="@0.7.5") diff --git a/var/spack/repos/builtin/packages/py-pyhdf/package.py b/var/spack/repos/builtin/packages/py-pyhdf/package.py new file mode 100644 index 00000000000000..e1059e20971e20 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-pyhdf/package.py @@ -0,0 +1,49 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyPyhdf(PythonPackage): + """pyhdf is a python wrapper around the NCSA HDF version 4 library. + The SD (Scientific Dataset), VS (Vdata) and V (Vgroup) APIs are + currently implemented. NetCDF files can also be read and modified.""" + + homepage = "https://github.com/fhs/pyhdf" + pypi = "pyhdf/pyhdf-0.10.4.tar.gz" + git = "https://github.com/fhs/pyhdf.git" + + maintainers("climbfuji") + + license("MIT") + + version("master", branch="master") + version("0.10.4", sha256="ea09b2bdafc9be0f7f43d72ff122d8efbde61881f4da3a659b33be5e29215f93") + + depends_on("c", type="build") # generated + + # Python versions + depends_on("py-setuptools", type="build") + + # Dependencies + depends_on("zlib-api", type=("build", "run")) + depends_on("hdf@4.2", type=("build", "run")) + depends_on("py-numpy", type=("build", "run")) + depends_on("jpeg", type=("build", "run")) + + def setup_build_environment(self, env): + inc_dirs = [] + lib_dirs = [] + # Strip -I and -L from spec include_flags / search_flags + inc_dirs.append(self.spec["zlib-api"].headers.include_flags.lstrip("-I")) + inc_dirs.append(self.spec["hdf"].headers.include_flags.lstrip("-I")) + inc_dirs.append(self.spec["jpeg"].headers.include_flags.lstrip("-I")) + lib_dirs.append(self.spec["zlib-api"].libs.search_flags.lstrip("-L")) + lib_dirs.append(self.spec["hdf"].libs.search_flags.lstrip("-L")) + lib_dirs.append(self.spec["jpeg"].libs.search_flags.lstrip("-L")) + env.set("INCLUDE_DIRS", ":".join(inc_dirs)) + env.set("LIBRARY_DIRS", ":".join(lib_dirs)) + if self.spec["hdf"].satisfies("@:4.1"): + env.set("NO_COMPRESS", "1") diff --git a/var/spack/repos/builtin/packages/py-pyheadtail/package.py b/var/spack/repos/builtin/packages/py-pyheadtail/package.py index a64d591b242656..35ed6f6c320d26 100644 --- a/var/spack/repos/builtin/packages/py-pyheadtail/package.py +++ b/var/spack/repos/builtin/packages/py-pyheadtail/package.py @@ -17,6 +17,9 @@ class PyPyheadtail(PythonPackage): version("1.14.1", sha256="bf90ac7e8764176c55e82c363cad7ab43543863b6ef482760ced23b78e917bb4") version("1.13.1", sha256="29c742573a918126b5a9c21806ee0ec6a34ec642a0e6ad200f6d4551bf1bb310") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("python", type=("build", "run")) depends_on("python@3:", when="@1.13.5:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyhull/package.py b/var/spack/repos/builtin/packages/py-pyhull/package.py index 3db784d4d89047..307416ddf58ac3 100644 --- a/var/spack/repos/builtin/packages/py-pyhull/package.py +++ b/var/spack/repos/builtin/packages/py-pyhull/package.py @@ -21,6 +21,8 @@ class PyPyhull(PythonPackage): version("2015.2.1", sha256="d2ff0aa3298b548287587609a24f4e2aae7f7b8b1df152a90cd313260abc3a24") + depends_on("c", type="build") # generated + # From setup.py: depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pyinstrument-cext/package.py b/var/spack/repos/builtin/packages/py-pyinstrument-cext/package.py index 83bbdedd5bf89e..c10fea144f875c 100644 --- a/var/spack/repos/builtin/packages/py-pyinstrument-cext/package.py +++ b/var/spack/repos/builtin/packages/py-pyinstrument-cext/package.py @@ -16,4 +16,6 @@ class PyPyinstrumentCext(PythonPackage): version("0.2.2", sha256="f29e25f71d74c0415ca9310e5567fff0f5d29f4240a09a885abf8b0eed71cc5b") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyinstrument/package.py b/var/spack/repos/builtin/packages/py-pyinstrument/package.py index 39a2048a4e86f7..6c2a128fbb31f1 100644 --- a/var/spack/repos/builtin/packages/py-pyinstrument/package.py +++ b/var/spack/repos/builtin/packages/py-pyinstrument/package.py @@ -19,6 +19,8 @@ class PyPyinstrument(PythonPackage): version("3.1.3", sha256="353c7000a6563b16c0be0c6a04104d42b3154c5cd7c1979ab66efa5fdc5f5571") version("3.1.0", sha256="10c1fed4996a72c3e1e2bac1940334756894dbd116df3cc3b2d9743f2ae43016") + depends_on("c", type="build") # generated + variant("jupyter", default=False, description="Support Jupyter/IPython magic", when="@4.1:") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pykerberos/package.py b/var/spack/repos/builtin/packages/py-pykerberos/package.py index 729216c85c0cec..a3be907887c0c5 100644 --- a/var/spack/repos/builtin/packages/py-pykerberos/package.py +++ b/var/spack/repos/builtin/packages/py-pykerberos/package.py @@ -16,6 +16,8 @@ class PyPykerberos(PythonPackage): version("1.2.4", sha256="9d701ebd8fc596c99d3155d5ba45813bd5908d26ef83ba0add250edb622abed4") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("krb5", type=("build", "link")) diff --git a/var/spack/repos/builtin/packages/py-pykokkos-base/package.py b/var/spack/repos/builtin/packages/py-pykokkos-base/package.py index 6bf307a58eee00..2428793eb4012b 100644 --- a/var/spack/repos/builtin/packages/py-pykokkos-base/package.py +++ b/var/spack/repos/builtin/packages/py-pykokkos-base/package.py @@ -21,6 +21,8 @@ class PyPykokkosBase(CMakePackage, PythonExtension): version("0.0.4", commit="2efe1220d0128d3f2d371c9ed5234c4978d73a77", submodules=False) version("0.0.3", commit="4fe4421ac624ba2efe1eee265153e690622a18a5", submodules=False) + depends_on("cxx", type="build") # generated + variant( "layouts", default=True, description="Build Kokkos View/DynRankView with layout variants" ) diff --git a/var/spack/repos/builtin/packages/py-pylikwid/package.py b/var/spack/repos/builtin/packages/py-pylikwid/package.py index b76aa855fa758a..58cb767071b764 100644 --- a/var/spack/repos/builtin/packages/py-pylikwid/package.py +++ b/var/spack/repos/builtin/packages/py-pylikwid/package.py @@ -22,6 +22,8 @@ class PyPylikwid(PythonPackage): version("0.4.0", sha256="f7894a6d7ebcea7da133ef639599a314f850f55cd6c5ffdd630bb879bd2aa0b8") + depends_on("c", type="build") # generated + variant("cuda", default=False, description="with Nvidia GPU profiling support") # pip silently replaces distutils with setuptools diff --git a/var/spack/repos/builtin/packages/py-pylith/package.py b/var/spack/repos/builtin/packages/py-pylith/package.py new file mode 100644 index 00000000000000..401a5e5eff6930 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-pylith/package.py @@ -0,0 +1,28 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyPylith(AutotoolsPackage, PythonExtension): + """PyLith does dynamic and quasi-static simulations of crustal deformation. + PyLith is an open-source finite-element code for dynamic and quasi-static + simulations of crustal deformation, primarily earthquakes and volcanoes.""" + + homepage = "https://geodynamics.org/resources/pylith" + url = "https://github.com/geodynamics/pylith/releases/download/v4.0.0/pylith-4.0.0.tar.gz" + + license("MIT", checked_by="downloadico") + + version("4.0.0", sha256="31e0131683292ee2e62f2c818cc2777f026104ae73d7a8368975dd6560292689") + + depends_on("cxx", type="build") # generated + + depends_on("py-setuptools") + depends_on("py-cig-pythia") + depends_on("spatialdata") + depends_on("netcdf-c") + depends_on("petsc@=3.20.2+hdf5") + depends_on("py-h5py") diff --git a/var/spack/repos/builtin/packages/py-pymatgen/package.py b/var/spack/repos/builtin/packages/py-pymatgen/package.py index 083724ddb3ac81..1af08be7c9e8d3 100644 --- a/var/spack/repos/builtin/packages/py-pymatgen/package.py +++ b/var/spack/repos/builtin/packages/py-pymatgen/package.py @@ -52,3 +52,8 @@ class PyPymatgen(PythonPackage): depends_on("py-uncertainties@3.1.4:", when="@2021.1.1:", type=("build", "run")) depends_on("py-pybtex", when="@2022.1.9:", type=("build", "run")) depends_on("py-tqdm", when="@2022.1.9:", type=("build", "run")) + + # <<< manual changes + # https://github.com/materialsproject/pymatgen/commit/29b5b909e109cb04d4b118d0de5b3929819b9378 + depends_on("py-cython@:2", when="@:2023.7.16", type="build") + # manual changes >>> diff --git a/var/spack/repos/builtin/packages/py-pymol/package.py b/var/spack/repos/builtin/packages/py-pymol/package.py index fe9bcce3a8d6ee..1889677b20512e 100644 --- a/var/spack/repos/builtin/packages/py-pymol/package.py +++ b/var/spack/repos/builtin/packages/py-pymol/package.py @@ -19,6 +19,9 @@ class PyPymol(PythonPackage): version("2.4.0", sha256="5ede4ce2e8f53713c5ee64f5905b2d29bf01e4391da7e536ce8909d6b9116581") version("2.3.0", sha256="62aa21fafd1db805c876f89466e47513809f8198395e1f00a5f5cc40d6f40ed0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python+tkinter@2.7:", type=("build", "link", "run"), when="@2.3.0:2.4.0") depends_on("python+tkinter@3.6:", type=("build", "link", "run"), when="@2.5.0:") # in newer pip versions --install-option does not exist @@ -58,7 +61,7 @@ def install_launcher(self): script = join_path(python_platlib, "pymol", "__init__.py") shebang = "#!/bin/sh\n" - fdata = 'exec {0} {1} "$@"'.format(self.spec["python"].command, script) + fdata = f'exec {python.path} {script} "$@"' with open(fname, "w") as new: new.write(shebang + fdata) set_executable(fname) diff --git a/var/spack/repos/builtin/packages/py-pymongo/package.py b/var/spack/repos/builtin/packages/py-pymongo/package.py index 7c7469e628f576..234b6119672d8c 100644 --- a/var/spack/repos/builtin/packages/py-pymongo/package.py +++ b/var/spack/repos/builtin/packages/py-pymongo/package.py @@ -25,6 +25,8 @@ class PyPymongo(PythonPackage): version("3.6.0", sha256="c6de26d1e171cdc449745b82f1addbc873d105b8e7335097da991c0fc664a4a8") version("3.3.0", sha256="3d45302fc2622fabf34356ba274c69df41285bac71bbd229f1587283b851b91e") + depends_on("c", type="build") # generated + depends_on("python@2.7:2.8,3.4:", type=("build", "run")) depends_on("python@3.7:", when="@4.2.0:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pymoo/package.py b/var/spack/repos/builtin/packages/py-pymoo/package.py index 023f81d859b25e..51bed567428187 100644 --- a/var/spack/repos/builtin/packages/py-pymoo/package.py +++ b/var/spack/repos/builtin/packages/py-pymoo/package.py @@ -22,6 +22,8 @@ class PyPymoo(PythonPackage): version("0.5.0", sha256="2fbca1716f6b45e430197ce4ce2210070fd3b6b9ec6b17bb25d98486115272c2") version("0.4.2", sha256="6ec382a7d29c8775088eec7f245a30fd384b42c40f230018dea0e3bcd9aabdf1") + depends_on("cxx", type="build") # generated + depends_on("python@3.4:", type=("build", "run")) depends_on("py-autograd", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pynacl/package.py b/var/spack/repos/builtin/packages/py-pynacl/package.py index 8c564b421c77a2..2e2a0c632a9ef5 100644 --- a/var/spack/repos/builtin/packages/py-pynacl/package.py +++ b/var/spack/repos/builtin/packages/py-pynacl/package.py @@ -16,6 +16,8 @@ class PyPynacl(PythonPackage): version("1.5.0", sha256="8ac7448f09ab85811607bdd21ec2464495ac8b7c66d146bf545b0f08fb9220ba") version("1.4.0", sha256="54e9a2c849c742006516ad56a88f5c74bf2ce92c9f67435187c3c5953b346505") + depends_on("c", type="build") # generated + depends_on("python@2.7:2.8,3.4:", type=("build", "run")) depends_on("python@3.6:", type=("build", "run"), when="@1.5.0:") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pynio/package.py b/var/spack/repos/builtin/packages/py-pynio/package.py index 59ea20288f45c0..a7e4b5f1a3f648 100644 --- a/var/spack/repos/builtin/packages/py-pynio/package.py +++ b/var/spack/repos/builtin/packages/py-pynio/package.py @@ -18,6 +18,9 @@ class PyPynio(PythonPackage): version("1.5.4", sha256="e5bb57d902740d25e4781a9f89e888149f55f2ffe60f9a5ad71069f017c89e1a") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("hdf5", default=False, description="Include HDF5 support") variant("gdal", default=False, description="Include GDAL support") diff --git a/var/spack/repos/builtin/packages/py-pynn/package.py b/var/spack/repos/builtin/packages/py-pynn/package.py index 8b7e40fed7e749..67949ae15ef9e7 100644 --- a/var/spack/repos/builtin/packages/py-pynn/package.py +++ b/var/spack/repos/builtin/packages/py-pynn/package.py @@ -24,6 +24,8 @@ class PyPynn(PythonPackage): version("0.8.1", sha256="ce94246284588414d1570c1d5d697805f781384e771816727c830b01ee30fe39") version("0.7.5", sha256="15f75f422f3b71c6129ecef23f29d8baeb3ed6502e7a321b8a2596c78ef7e03c") + depends_on("cxx", type="build") # generated + depends_on("python@2.6:2.8,3.3:", type=("build", "run")) depends_on("python@3.7:", type=("build", "run"), when="@0.10.0:") diff --git a/var/spack/repos/builtin/packages/py-pynvtx/package.py b/var/spack/repos/builtin/packages/py-pynvtx/package.py index 86065133e703c4..15c25c30ad8256 100644 --- a/var/spack/repos/builtin/packages/py-pynvtx/package.py +++ b/var/spack/repos/builtin/packages/py-pynvtx/package.py @@ -22,5 +22,7 @@ class PyPynvtx(PythonPackage): version("0.3.3", sha256="8877b2d90bbf9d279d517a80a8f35a0a0a8179ebabf0729e806798a84bee6c72") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@40.8:", type="build") depends_on("py-pybind11", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/py-pyodbc/package.py b/var/spack/repos/builtin/packages/py-pyodbc/package.py index 05cc05cf01b7e6..ad2e8d9c5be5a8 100644 --- a/var/spack/repos/builtin/packages/py-pyodbc/package.py +++ b/var/spack/repos/builtin/packages/py-pyodbc/package.py @@ -18,6 +18,8 @@ class PyPyodbc(PythonPackage): version("4.0.26", sha256="e52700b5d24a846483b5ab80acd9153f8e593999c9184ffea11596288fb33de3") + depends_on("cxx", type="build") # generated + depends_on("python@2.7:2.8,3.4:", type=("build", "link", "run")) depends_on("py-setuptools", type="build") depends_on("unixodbc") diff --git a/var/spack/repos/builtin/packages/py-pyomo/package.py b/var/spack/repos/builtin/packages/py-pyomo/package.py index a1c83b415dba2a..212a50eb0b5d5e 100644 --- a/var/spack/repos/builtin/packages/py-pyomo/package.py +++ b/var/spack/repos/builtin/packages/py-pyomo/package.py @@ -18,6 +18,7 @@ class PyPyomo(PythonPackage): # Maintainer accurate as of 2024-02-21 maintainers("mrmundt") + version("6.7.2", sha256="53bef766854f7607ca1fcfe3f218594ab382f137a275cee3d925d2b2f96876bf") version("6.7.1", sha256="735b66c45937f1caa43f073d8218a4918b6de658914a699397d38d5b8c219a40") version("6.7.0", sha256="a245ec609ef2fd907269f0b8e0923f74d5bf868b2ec0e62bf2a30b3f253bd17b") version("6.6.2", sha256="c8ad55213ff8b1a2c4e469110db8079722d5a6f364c6c46a42e2f750fc9e4d26") @@ -45,6 +46,9 @@ class PyPyomo(PythonPackage): version("5.6.7", sha256="fc97cc9d5a55c5185358ba65c1f9530c9af17e67a9aae7b36c3414f159030ae0") version("5.6.6", sha256="813e14a604b9d3ac63bdd0880c07f5f4e1b8f0a8a10345f1b42bee762219c001") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cython", default=False, description="Enable cythonization of Pyomo.") variant("tests", default=False, description="Install testing dependencies.", when="@6.1:") variant( @@ -94,7 +98,8 @@ class PyPyomo(PythonPackage): depends_on("py-sphinx-toolbox@2.16:", when="@6.7.1:+docs", type=("run")) depends_on("py-sphinx-jinja2-compat@0.1.1:", when="@6.7.1:+docs", type=("run")) depends_on("py-enum-tools", when="@6.7.1:+docs", type=("run")) - depends_on("py-numpy", when="@6.1:+docs", type=("run")) + # Pyomo does not support NumPy2 (May 9, 2024) + depends_on("py-numpy@1", when="@6.1:+docs", type=("run")) depends_on("py-scipy", when="@6.4.2:+docs", type=("run")) # when optional is requested @@ -102,7 +107,8 @@ class PyPyomo(PythonPackage): depends_on("py-ipython", when="@6.1:+optional", type=("run")) depends_on("py-matplotlib@:3.6.0,3.6.2:", when="@6.1:+optional", type=("run")) depends_on("py-networkx", when="@6.1:+optional", type=("run")) - depends_on("py-numpy", when="@6.1:+optional", type=("run")) + # Pyomo does not support NumPy2 (May 9, 2024) + depends_on("py-numpy@1", when="@6.1:+optional", type=("run")) depends_on("py-openpyxl", when="@6.1:+optional", type=("run")) depends_on("py-pint", when="@6.1:+optional", type=("run")) depends_on("py-plotly", when="@6.6:+optional", type=("run")) diff --git a/var/spack/repos/builtin/packages/py-pyopencl/package.py b/var/spack/repos/builtin/packages/py-pyopencl/package.py index 48cf56912e1001..5e2c6ed30f686a 100644 --- a/var/spack/repos/builtin/packages/py-pyopencl/package.py +++ b/var/spack/repos/builtin/packages/py-pyopencl/package.py @@ -19,6 +19,8 @@ class PyPyopencl(PythonPackage): version("2020.2.2", sha256="31fcc79fb6862998e98d91a624c0bd4f0ab4c5d418d199912d4d312c64e437ec") + depends_on("cxx", type="build") # generated + depends_on("ocl-icd", type=("build", "link", "run")) depends_on("opencl", type=("build", "link", "run")) depends_on("python@3.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pyopengl/package.py b/var/spack/repos/builtin/packages/py-pyopengl/package.py new file mode 100644 index 00000000000000..64f4913dc2812c --- /dev/null +++ b/var/spack/repos/builtin/packages/py-pyopengl/package.py @@ -0,0 +1,68 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# 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 * + + +class PyPyopengl(PythonPackage): + """PyOpenGL is the most common cross platform Python binding to OpenGL and related APIs.""" + + homepage = "http://pyopengl.sourceforge.net" + pypi = "pyopengl/PyOpenGL-3.1.6.tar.gz" + + version("3.1.6", sha256="8ea6c8773927eda7405bffc6f5bb93be81569a7b05c8cac50cd94e969dce5e27") + + variant("glu", default=True, description="Enable OpenGL Utility (GLU) binding.") + variant("glut", default=True, description="Enable OpenGL Utility Toolkit (GLUT) binding.") + + conflicts("osmesa", when="^glx") + + depends_on("py-setuptools", type="build") + # actually installing PyOpenGL itself just requires python + # but tests (and possibly dependent packages) need OpenGL libraries + depends_on("gl", type="link") + depends_on("glu", when="+glu", type="link") + depends_on("freeglut+shared", when="+glut", type="link") + + def setup_run_environment(self, env): + # PyOpenGL uses ctypes.cdll (or similar), which searches LD_LIBRARY_PATH + lib_dirs = self.spec["gl"].libs.directories + if "^glx" in self.spec: + lib_dirs.extend(self.spec["glx"].libs.directories) + env.set("PYOPENGL_PLATFORM", "glx") + if "^osmesa" in self.spec: + lib_dirs.extend(self.spec["osmesa"].libs.directories) + env.set("PYOPENGL_PLATFORM", "osmesa") + if "+glu" in self.spec: + lib_dirs.extend(self.spec["glu"].libs.directories) + if "+glut" in self.spec: + lib_dirs.extend(self.spec["freeglut"].libs.directories) + libs = ":".join(lib_dirs) + if sys.platform == "darwin": + env.prepend_path("DYLD_FALLBACK_LIBRARY_PATH", libs) + else: + env.prepend_path("LD_LIBRARY_PATH", libs) + + def setup_dependent_build_environment_(self, env, dependent_spec): + self.setup_run_environment(env) + + # only test import available module + @property + def import_modules(self): + modules = ["OpenGL", "OpenGL.GL"] + if "gl=glx" in self.spec: + modules.append("OpenGL.GLX") + if "gl=osmesa" in self.spec: + modules.append("OpenGL.osmesa") + if "+glu" in self.spec: + modules.append("OpenGL.GLU") + if "+glut" in self.spec: + modules.append("OpenGL.GLUT") + if "^python+tkinter" in self.spec: + modules.append("OpenGL.Tk") + + return modules diff --git a/var/spack/repos/builtin/packages/py-pypar/package.py b/var/spack/repos/builtin/packages/py-pypar/package.py index 49d9d4fba555d9..804b25c862d7fd 100644 --- a/var/spack/repos/builtin/packages/py-pypar/package.py +++ b/var/spack/repos/builtin/packages/py-pypar/package.py @@ -18,6 +18,8 @@ class PyPypar(PythonPackage): version("2.1.5_108", sha256="6076c47d32d48424a07c7b7b29ac16e12cc4b2d28b681b895f94fa76cd82fa12") + depends_on("c", type="build") # generated + depends_on("mpi") # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyparsing/package.py b/var/spack/repos/builtin/packages/py-pyparsing/package.py index 4210a17aee91c5..46b980da8a743e 100644 --- a/var/spack/repos/builtin/packages/py-pyparsing/package.py +++ b/var/spack/repos/builtin/packages/py-pyparsing/package.py @@ -14,6 +14,9 @@ class PyPyparsing(PythonPackage): license("MIT") + version("3.1.2", sha256="a1bac0ce561155ecc3ed78ca94d3c9378656ad4c94c1270de543f621420f94ad") + version("3.1.1", sha256="ede28a1a32462f5a9705e07aea48001a08f7cf81a021585011deba701581a0db") + version("3.1.0", sha256="edb662d6fe322d6e990b1594b5feaeadf806803359e3d4d42f11e295e588f0ea") version("3.0.9", sha256="2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb") version("3.0.6", sha256="d9bdec0013ef1eb5a84ab39a3b3868911598afa494f5faa038647101504e2b81") version("2.4.7", sha256="c203ec8783bf771a155b207279b9bccb8dea02d8f0c9e5f8ead507bc3246ecc1") diff --git a/var/spack/repos/builtin/packages/py-pyprecice/package.py b/var/spack/repos/builtin/packages/py-pyprecice/package.py index 19b81e062801b6..dba3a938f79410 100644 --- a/var/spack/repos/builtin/packages/py-pyprecice/package.py +++ b/var/spack/repos/builtin/packages/py-pyprecice/package.py @@ -37,6 +37,8 @@ class PyPyprecice(PythonPackage): version("2.0.0.2", sha256="5f055d809d65ec2e81f4d001812a250f50418de59990b47d6bcb12b88da5f5d7") version("2.0.0.1", sha256="96eafdf421ec61ad6fcf0ab1d3cf210831a815272984c470b2aea57d4d0c9e0e") + depends_on("cxx", type="build") # generated + for ver in [ "develop", "2.5.0", diff --git a/var/spack/repos/builtin/packages/py-pyqt4/package.py b/var/spack/repos/builtin/packages/py-pyqt4/package.py index 31e481d3052fc9..1c28fd8b243576 100644 --- a/var/spack/repos/builtin/packages/py-pyqt4/package.py +++ b/var/spack/repos/builtin/packages/py-pyqt4/package.py @@ -19,6 +19,8 @@ class PyPyqt4(SIPPackage): version("4.12.3", sha256="a00f5abef240a7b5852b7924fa5fdf5174569525dc076cd368a566619e56d472") + depends_on("cxx", type="build") # generated + # API files can be installed regardless if QScintilla is installed or not variant("qsci_api", default=False, description="Install PyQt API file for QScintilla") @@ -48,7 +50,7 @@ def configure_args(self): "--destdir", python_platlib, "--pyuic4-interpreter", - self.spec["python"].command.path, + python.path, "--sipdir", self.prefix.share.sip.PyQt4, "--stubsdir", diff --git a/var/spack/repos/builtin/packages/py-pyqt5-sip/package.py b/var/spack/repos/builtin/packages/py-pyqt5-sip/package.py index e93543146b0d52..c6612970b3c132 100644 --- a/var/spack/repos/builtin/packages/py-pyqt5-sip/package.py +++ b/var/spack/repos/builtin/packages/py-pyqt5-sip/package.py @@ -14,7 +14,17 @@ class PyPyqt5Sip(PythonPackage): license("GPL-2.0-only") + version("12.13.0", sha256="7f321daf84b9c9dbca61b80e1ef37bdaffc0e93312edae2cd7da25b953971d91") version("12.12.1", sha256="8fdc6e0148abd12d977a1d3828e7b79aae958e83c6cb5adae614916d888a6b10") version("12.9.0", sha256="d3e4489d7c2b0ece9d203ae66e573939f7f60d4d29e089c9f11daa17cfeaae32") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@30.3:", type="build") + + patch( + "https://src.fedoraproject.org/rpms/python-pyqt5-sip/raw/841f58ce66df4dfcf11713e7adb6bd301403d5a8/f/afc99fa84d0d.patch", + sha256="82a326749b145b30eda3f0040cd7099c4c06a57a5e9626687b0a983de1ebfc3e", + when="@12.12: %gcc@14:", + ) diff --git a/var/spack/repos/builtin/packages/py-pyqt5/package.py b/var/spack/repos/builtin/packages/py-pyqt5/package.py index 1f74582a44b271..4f1c904396f75d 100644 --- a/var/spack/repos/builtin/packages/py-pyqt5/package.py +++ b/var/spack/repos/builtin/packages/py-pyqt5/package.py @@ -19,6 +19,8 @@ class PyPyqt5(SIPPackage): version("5.15.9", sha256="dc41e8401a90dc3e2b692b411bd5492ab559ae27a27424eed4bd3915564ec4c0") + depends_on("cxx", type="build") # generated + # pyproject.toml depends_on("py-sip@6.6.2:6", type="build") depends_on("py-pyqt-builder@1.14.1:1", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyqt6-sip/package.py b/var/spack/repos/builtin/packages/py-pyqt6-sip/package.py index 36a42e13170e50..5b853be73f43d9 100644 --- a/var/spack/repos/builtin/packages/py-pyqt6-sip/package.py +++ b/var/spack/repos/builtin/packages/py-pyqt6-sip/package.py @@ -14,6 +14,10 @@ class PyPyqt6Sip(PythonPackage): license("GPL-2.0-or-later") + version("13.6.0", sha256="2486e1588071943d4f6657ba09096dc9fffd2322ad2c30041e78ea3f037b5778") version("13.5.1", sha256="d1e9141752966669576d04b37ba0b122abbc41cc9c35493751028d7d91c4dd49") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@30.3:", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyqt6/package.py b/var/spack/repos/builtin/packages/py-pyqt6/package.py index 6e6de0ead7c89a..ac4701048709f4 100644 --- a/var/spack/repos/builtin/packages/py-pyqt6/package.py +++ b/var/spack/repos/builtin/packages/py-pyqt6/package.py @@ -15,15 +15,22 @@ class PyPyqt6(SIPPackage): license("GPL-3.0-or-later") + version("6.7.0", sha256="3d31b2c59dc378ee26e16586d9469842483588142fc377280aad22aaf2fa6235") + version("6.6.1", sha256="9f158aa29d205142c56f0f35d07784b8df0be28378d20a97bcda8bd64ffd0379") version("6.5.2", sha256="1487ee7350f9ffb66d60ab4176519252c2b371762cbe8f8340fd951f63801280") version("6.5.1", sha256="e166a0568c27bcc8db00271a5043936226690b6a4a74ce0a5caeb408040a97c3") + depends_on("cxx", type="build") # generated + # pyproject.toml - depends_on("py-sip@6.5:6", type="build") + depends_on("python@3.8:", type=("build", "run"), when="@6.7:") + depends_on("py-sip@6.8:6", type="build", when="@6.7:") + depends_on("py-sip@6.5:6", type="build", when="@:6.6") depends_on("py-pyqt-builder@1.15:1", type="build") # PKG-INFO - depends_on("py-pyqt6-sip@13.4:13", type=("build", "run")) + depends_on("py-pyqt6-sip@13.6:13", type=("build", "run"), when="@5.3:") + depends_on("py-pyqt6-sip@13.4:13", type=("build", "run"), when="@:5.2") # README depends_on("qt-base@6") diff --git a/var/spack/repos/builtin/packages/py-pyrevolve/package.py b/var/spack/repos/builtin/packages/py-pyrevolve/package.py index 12c053a1577f9c..c72a3f22646fca 100644 --- a/var/spack/repos/builtin/packages/py-pyrevolve/package.py +++ b/var/spack/repos/builtin/packages/py-pyrevolve/package.py @@ -19,6 +19,8 @@ class PyPyrevolve(PythonPackage): version("2.2", sha256="b49aea5cd6c520ac5fcd1d25fa23fe2c5502741d2965f3eee10be067e7b0efb4") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-contexttimer", type=("build", "run")) depends_on("py-cython@0.17:", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyrfr/package.py b/var/spack/repos/builtin/packages/py-pyrfr/package.py index 7d1c1e992a64d4..c4840f84091f45 100644 --- a/var/spack/repos/builtin/packages/py-pyrfr/package.py +++ b/var/spack/repos/builtin/packages/py-pyrfr/package.py @@ -17,6 +17,8 @@ class PyPyrfr(PythonPackage): version("0.8.2", sha256="c18a6e8f0bd971c1ea449b6dd0997a6ec1fe9a031883400bdcc95fa5ddd65975") + depends_on("cxx", type="build") # generated + depends_on("python@3:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("swig") diff --git a/var/spack/repos/builtin/packages/py-pyro-ppl/package.py b/var/spack/repos/builtin/packages/py-pyro-ppl/package.py index 9ba34d0ecab521..68441e21e925f8 100644 --- a/var/spack/repos/builtin/packages/py-pyro-ppl/package.py +++ b/var/spack/repos/builtin/packages/py-pyro-ppl/package.py @@ -20,6 +20,8 @@ class PyPyroPpl(PythonPackage): version("1.8.1", sha256="d7c049eb2e7485a612b4dd99c24c309cc860c7cbc6b1973387034f5436d1c8d6") version("1.8.0", sha256="68e4ea30f219227dd88e55de2550d3f8c20a20adbdb67ad1e13b50868bb2ac0c") + depends_on("cxx", type="build") # generated + depends_on("python@3.7:", when="@1.8.1:", type=("build", "run")) depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyrocko/package.py b/var/spack/repos/builtin/packages/py-pyrocko/package.py new file mode 100644 index 00000000000000..4b9ad7292ec7b1 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-pyrocko/package.py @@ -0,0 +1,33 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyPyrocko(PythonPackage): + """Pyrocko is an open source seismology toolbox and library, written in the + Python programming language""" + + homepage = "https://pyrocko.org/" + pypi = "pyrocko/pyrocko-2023.6.29.tar.gz" + + maintainers("snehring") + + license("GPL-3.0", checked_by="snehring") + + version("2024.1.10", sha256="4fb2c72d0b036ce3c70bfd066e1ce4946eb93d9190d202e9fc689c1f29e4845f") + version("2023.6.29", sha256="779a234592bfcfa1c96939fee53d0dfc5cadf111432a2679f08166cfd8bcae41") + + depends_on("c", type="build") # generated + + depends_on("python@3.7:", type=("build", "run")) + + depends_on("py-setuptools", type="build") + + depends_on("py-numpy@1.16:", type=("build", "run")) + depends_on("py-scipy@1:", type=("build", "run")) + depends_on("py-pyyaml", type=("build", "run")) + depends_on("py-matplotlib", type=("build", "run")) + depends_on("py-requests", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pyrsistent/package.py b/var/spack/repos/builtin/packages/py-pyrsistent/package.py index 9ef98a0f4dc5da..fc85e14944bb8b 100644 --- a/var/spack/repos/builtin/packages/py-pyrsistent/package.py +++ b/var/spack/repos/builtin/packages/py-pyrsistent/package.py @@ -22,6 +22,8 @@ class PyPyrsistent(PythonPackage): version("0.16.0", sha256="28669905fe725965daa16184933676547c5bb40a5153055a8dee2a4bd7933ad3") version("0.15.7", sha256="cdc7b5e3ed77bed61270a47d35434a30617b9becdf2478af76ad2c6ade307280") + depends_on("c", type="build") # generated + depends_on("python", type=("build", "link", "run")) depends_on("py-setuptools@42:", when="@0.18.0:", type="build") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pysam/package.py b/var/spack/repos/builtin/packages/py-pysam/package.py index 42993ca040a23e..7e83b7f0bfd00e 100644 --- a/var/spack/repos/builtin/packages/py-pysam/package.py +++ b/var/spack/repos/builtin/packages/py-pysam/package.py @@ -24,6 +24,8 @@ class PyPysam(PythonPackage): version("0.14.1", sha256="2e86f5228429d08975c8adb9030296699012a8deba8ba26cbfc09b374f792c97") version("0.7.7", sha256="c9f3018482eec99ee199dda3fdef2aa7424dde6574672a4c0d209a10985755cc") + depends_on("c", type="build") # generated + depends_on("py-setuptools@59.0:", when="@0.21:", type="build") depends_on("py-setuptools", type="build") depends_on("py-cython@0.29.30:2", when="@0.21:", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyscf/package.py b/var/spack/repos/builtin/packages/py-pyscf/package.py index 311193bc6f1684..4a12b557265e14 100644 --- a/var/spack/repos/builtin/packages/py-pyscf/package.py +++ b/var/spack/repos/builtin/packages/py-pyscf/package.py @@ -12,12 +12,16 @@ class PyPyscf(PythonPackage): by Python.""" homepage = "https://pyscf.org" - pypi = "pyscf/pyscf-2.2.0.tar.gz" + pypi = "pyscf/pyscf-2.5.0.tar.gz" maintainers("naromero77") license("Apache-2.0") + version("2.6.2", sha256="744c89a8e4d38c4b5562f75fa68f9d079faeb23602d255fba0eb6d1bac97bca2") + version("2.6.1", sha256="faeaeeb0c07fec5018937655511709a9c2445e3d7c421c0fa1ae5d889e4ab455") + version("2.6.0", sha256="08ff920fedd4b257273d235fb4492535147c1e3154de5ab02b5446de93e200d8") + version("2.5.0", sha256="9596603c914fb3fba853607e96366fa541012faffd59a4ea052f0122dcea5343") version("2.4.0", sha256="af0597c481851b5448e7055c3160aef28dc12a1e0b35dda8279555c0780c0d45") version("2.3.0", sha256="71781de62c25924fd4e93ffeb0451ec0d0b3646fe426c75023f4f519f0f35d85") version("2.2.1", sha256="4ff6851351caadc5dfa543b6b2c5fbd926ded87e3cc39faa0054e1e5090ed69a") @@ -28,6 +32,8 @@ class PyPyscf(PythonPackage): version("1.7.5", sha256="52856b39f0ada2f6340757caa65dc5c1d9a3cdfceea2a6615ad8af92664a6c69") version("1.7.3", sha256="62a26146a222140395b276ea33182f87809a21989ddcf78e2dcb8e35ebc57af2") + depends_on("c", type="build") # generated + # dependencies depends_on("cmake@3.10:", type="build", when="@2.1:") depends_on("cmake@2.8:", type="build") @@ -36,9 +42,12 @@ class PyPyscf(PythonPackage): depends_on("py-setuptools", type="build") depends_on("py-numpy@1.8.0:", type=("build", "run")) depends_on("py-numpy@1.13.0:", type=("build", "run"), when="@2:") + depends_on("py-numpy@1", type=("build", "run"), when="@:2.6.0") conflicts("^py-numpy@1.16:1.17", when="@2:") - depends_on("py-scipy@0.12:", type=("build", "run")) - depends_on("py-scipy@0.19:", type=("build", "run"), when="@2.1:") + depends_on("py-scipy@0.12:1.10", type=("build", "run"), when="@:2.0") + depends_on("py-scipy@0.19:1.10", type=("build", "run"), when="@2.1:2.2") + # https://github.com/pyscf/pyscf/issues/1783 + depends_on("py-scipy@0.19:", type=("build", "run"), when="@2.3:") conflicts("^py-scipy@1.5.0:1.5.1", when="@2:") depends_on("py-h5py@2.3.0:", type=("build", "run")) depends_on("py-h5py@2.7.0:", type=("build", "run"), when="@2:") diff --git a/var/spack/repos/builtin/packages/py-pyscipopt/package.py b/var/spack/repos/builtin/packages/py-pyscipopt/package.py index a7a23dd147757a..ac333be5ad3d85 100644 --- a/var/spack/repos/builtin/packages/py-pyscipopt/package.py +++ b/var/spack/repos/builtin/packages/py-pyscipopt/package.py @@ -16,6 +16,8 @@ class PyPyscipopt(PythonPackage): version("3.4.0", sha256="8da4db57b21010e0d5a863292dd455c88dd71ecec12a8439171c213a8092f88a") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") depends_on("py-wheel", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyseer/package.py b/var/spack/repos/builtin/packages/py-pyseer/package.py new file mode 100644 index 00000000000000..53c7c7fc0c76da --- /dev/null +++ b/var/spack/repos/builtin/packages/py-pyseer/package.py @@ -0,0 +1,31 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class PyPyseer(PythonPackage): + """Sequence Elements Enrichment Analysis (SEER), python implementation""" + + homepage = "https://pyseer.readthedocs.io/en/master/" + + # Not availible on PyPI + url = "https://github.com/mgalardini/pyseer/releases/download/1.3.11/pyseer-1.3.11.tar.gz" + + version("1.3.11", sha256="384313a3a14b92f873eaad53f77a319d90b584b9253785a7ca1dfc7d9220c91e") + + depends_on("py-setuptools", type="build") + depends_on("py-numpy", type=("build", "run")) + depends_on("py-scipy", type=("build", "run")) + depends_on("py-pandas", type=("build", "run")) + depends_on("py-statsmodels@0.10.0:", type=("build", "run")) + depends_on("py-scikit-learn", type=("build", "run")) + depends_on("py-pysam", type=("build", "run")) + depends_on("py-dendropy", type=("build", "run")) + depends_on("py-matplotlib", type=("build", "run")) + depends_on("py-pybedtools", type=("build", "run")) + depends_on("py-tqdm", type=("build", "run")) + depends_on("py-glmnet-python@1.0.2", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pyside/package.py b/var/spack/repos/builtin/packages/py-pyside/package.py index 16e95b4f7197b6..bb33a8d495b5b5 100644 --- a/var/spack/repos/builtin/packages/py-pyside/package.py +++ b/var/spack/repos/builtin/packages/py-pyside/package.py @@ -28,6 +28,8 @@ class PyPyside(PythonPackage): version("1.2.2", sha256="53129fd85e133ef630144c0598d25c451eab72019cdcb1012f2aec773a3f25be") + depends_on("cxx", type="build") # generated + # to prevent error: 'PyTypeObject' {aka 'struct _typeobject'} has no member # named 'tp_print' depends_on("python@:3.8", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pyside2/package.py b/var/spack/repos/builtin/packages/py-pyside2/package.py index a1bbd619aef878..062da2bcea2556 100644 --- a/var/spack/repos/builtin/packages/py-pyside2/package.py +++ b/var/spack/repos/builtin/packages/py-pyside2/package.py @@ -44,6 +44,8 @@ class PyPyside2(PythonPackage): "5.12.5", tag="v5.12.5", commit="af0953e0d261ab9b1fc498d63e8d790a329dd285", submodules=True ) + depends_on("cxx", type="build") # generated + variant( "doc", default=False, diff --git a/var/spack/repos/builtin/packages/py-pysimdjson/package.py b/var/spack/repos/builtin/packages/py-pysimdjson/package.py index 48685e6dc9fcd1..d046150ddb52bf 100644 --- a/var/spack/repos/builtin/packages/py-pysimdjson/package.py +++ b/var/spack/repos/builtin/packages/py-pysimdjson/package.py @@ -21,6 +21,8 @@ class PyPysimdjson(PythonPackage): version("4.0.3", sha256="61900992d7f992b073a8c5f93cafa4af9bfd3209624baa775699b0fdd6f67517") version("3.2.0", sha256="643baa0941752367761dbc091bf552bf4ca196cf67bf41ef89c90c2db2ec1477") + depends_on("cxx", type="build") # generated + depends_on("python@3.6:", type=("build", "run"), when="@4.0.3:") depends_on("python@3.5:", type=("build", "run"), when="@:4.0.2") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyspark/package.py b/var/spack/repos/builtin/packages/py-pyspark/package.py index 087378d753d9eb..b7097230fa0d43 100644 --- a/var/spack/repos/builtin/packages/py-pyspark/package.py +++ b/var/spack/repos/builtin/packages/py-pyspark/package.py @@ -12,6 +12,11 @@ class PyPyspark(PythonPackage): homepage = "https://spark.apache.org" pypi = "pyspark/pyspark-3.0.1.tar.gz" + maintainers("teaguesterling") + + version("3.5.1", sha256="dd6569e547365eadc4f887bf57f153e4d582a68c4b490de475d55b9981664910") + version("3.4.3", sha256="8d7025fa274830cb6c3bd592228be3d9345cb3b8b1e324018c2aa6e75f48a208") + version("3.3.4", sha256="1f866be47130a522355240949ed50d9812a8f327bd7619f043ffe07fbcf7f7b6") version("3.3.1", sha256="e99fa7de92be406884bfd831c32b9306a3a99de44cfc39a2eefb6ed07445d5fa") version("3.3.0", sha256="7ebe8e9505647b4d124d5a82fca60dfd3891021cf8ad6c5ec88777eeece92cf7") version("3.2.1", sha256="0b81359262ec6e9ac78c353344e7de026027d140c6def949ff0d80ab70f89a54") @@ -19,11 +24,40 @@ class PyPyspark(PythonPackage): version("3.1.2", sha256="5e25ebb18756e9715f4d26848cc7e558035025da74b4fc325a0ebc05ff538e65") version("3.0.1", sha256="38b485d3634a86c9a2923c39c8f08f003fdd0e0a3d7f07114b2fb4392ce60479") + variant("java", default=True, description="Include Java requirements via py-py4j") + variant("pandas", default=True, description="Include Pandas support") + variant("connect", default=True, description="Include SparkConnect support", when="@3.4:") + + # Noted on https://spark.apache.org/docs/latest/api/python/getting_started/install.html#dependencies + with default_args(type="run"): + depends_on("py-pyarrow@4:", when="+pandas@3.5:") + depends_on("py-pyarrow@1:", when="+pandas@:3.4") + depends_on("py-pandas@1.0.5:", when="+pandas") + depends_on("py-numpy@1.15:", when="+pandas") + + with when("@3.5:"): + depends_on("py-grpcio@1.56:", when="+connect") + depends_on("py-grpcio-status@1.56:", when="+connect") + depends_on("py-googleapis-common-protos@1.56.4:", when="+connect") + + with when("@3.4:"): + depends_on("py-grpcio@1.48.1:", when="+connect") + depends_on("py-grpcio-status@1.48.1:", when="+connect") + depends_on("py-googleapis-common-protos@1.56.4:", when="+connect") + depends_on("py-setuptools", type="build") - depends_on("py-py4j@0.10.9.5", when="@3.3.0:", type=("build", "run")) - depends_on("py-py4j@0.10.9.3", when="@3.2.1", type=("build", "run")) - depends_on("py-py4j@0.10.9", when="@3.0.1:3.1.3", type=("build", "run")) + with default_args(type=("build", "run")): + depends_on("py-py4j~java", when="~java") + for py4j_version, pyspark_version in [ + ("0.10.9.7", "3.4:"), + ("0.10.9.5", "3.3:"), + ("0.10.9.3", "3.2.1"), + ("0.10.9", "3.0.1:3.1.3"), + ]: + depends_on(f"py-py4j@{py4j_version}:", when=f"@{pyspark_version}") def setup_run_environment(self, env): - env.set("PYSPARK_PYTHON", self.spec["python"].command.path) - env.set("PYSPARK_DRIVER_PYTHON", self.spec["python"].command.path) + env.set("PYSPARK_PYTHON", python.path) + env.set("PYSPARK_DRIVER_PYTHON", python.path) + if self.spec.satisfies("+pandas ^java@11:"): + env.append_flags("SPARK_SUBMIT_OPTS", "-Dio.netty.tryReflectionSetAccessible=true") diff --git a/var/spack/repos/builtin/packages/py-pyspoa/package.py b/var/spack/repos/builtin/packages/py-pyspoa/package.py index 8a8d218743c094..dc309fd3b920f8 100644 --- a/var/spack/repos/builtin/packages/py-pyspoa/package.py +++ b/var/spack/repos/builtin/packages/py-pyspoa/package.py @@ -17,6 +17,9 @@ class PyPyspoa(PythonPackage): version("0.0.8", sha256="8299d18066b498a6ef294c5a33a99266ded06eeb022f67488d2caecba974b0a4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") - depends_on("cmake@3.18.4", type="build") + depends_on("cmake@3:", type="build") depends_on("py-pybind11@2.4:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pysqlite3/package.py b/var/spack/repos/builtin/packages/py-pysqlite3/package.py index c7d57dd2e35d41..efab982077db6e 100644 --- a/var/spack/repos/builtin/packages/py-pysqlite3/package.py +++ b/var/spack/repos/builtin/packages/py-pysqlite3/package.py @@ -17,6 +17,8 @@ class PyPysqlite3(PythonPackage): version("0.4.7", sha256="0352864898aa406beb762f4a620594c950a9a4430caab679bce574065698c8ac") version("0.4.6", sha256="7ec4d4c477fa96609c1517afbc33bf02747588e528e79c695de95907cea7bf30") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("sqlite", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/py-pytest-cpp/package.py b/var/spack/repos/builtin/packages/py-pytest-cpp/package.py index a277ffc310caed..5503cfbbd530c5 100644 --- a/var/spack/repos/builtin/packages/py-pytest-cpp/package.py +++ b/var/spack/repos/builtin/packages/py-pytest-cpp/package.py @@ -18,6 +18,8 @@ class PyPytestCpp(PythonPackage): version("1.5.0", sha256="efb7eaac30f9f61515be181d04b70d80d60ce8871426f726ef1844e2db4f3353") version("1.4.0", sha256="aa3a04fe7906e50094d1a9b8d38bc10eb59d0a8330a11a0f7a660405228b48ca") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-setuptools-scm", type="build") depends_on("py-pytest@:5.3,5.4.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pytest-mpi/package.py b/var/spack/repos/builtin/packages/py-pytest-mpi/package.py new file mode 100644 index 00000000000000..3efc1c68038251 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-pytest-mpi/package.py @@ -0,0 +1,21 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class PyPytestMpi(PythonPackage): + """Pytest plugin to collect information from tests.""" + + homepage = "https://pytest-mpi.readthedocs.io" + pypi = "pytest-mpi/pytest-mpi-0.6.tar.gz" + + license("BSD-3-Clause") + + maintainers("tristan0x") + + version("0.6", sha256="09b3cd3511f8f3cd4d205f54d4a7223724fed0ab68b872ed1123d312152325a9") + + depends_on("py-setuptools@42:", type="build") + depends_on("py-pytest@3.4:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pytest/package.py b/var/spack/repos/builtin/packages/py-pytest/package.py index 5a4ef2d5f0d4e6..1e50386ac63ea3 100644 --- a/var/spack/repos/builtin/packages/py-pytest/package.py +++ b/var/spack/repos/builtin/packages/py-pytest/package.py @@ -14,7 +14,9 @@ class PyPytest(PythonPackage): git = "https://github.com/pytest-dev/pytest" license("MIT") + maintainers("adamjstewart") + version("8.2.1", sha256="5046e5b46d8e4cac199c373041f26be56fdb81eb4e67dc11d4e10811fc3408fd") version("8.0.0", sha256="249b1b0864530ba251b7438274c4d251c58d868edaaec8762893ad4a0d71c36c") version("7.4.4", sha256="2cf0005922c6ace4a3e2ec8b4080eb0d9753fdc93107415332f50ce9e7994280") version("7.3.2", sha256="ee990a3cc55ba808b80795a79944756f315c67c12b56abd3ac993a7b8c17030b") @@ -39,53 +41,56 @@ class PyPytest(PythonPackage): version("3.0.7", sha256="b70696ebd1a5e6b627e7e3ac1365a4bc60aaf3495e843c1e70448966c5224cab") version("3.0.2", sha256="64d8937626dd2a4bc15ef0edd307d26636a72a3f3f9664c424d78e40efb1e339") - # python_requires - depends_on("python@3.8:", when="@8:", type=("build", "run")) - depends_on("python@3.7:", when="@7.1:", type=("build", "run")) - # see https://github.com/pytest-dev/pytest/releases/tag/7.3.2 - depends_on("python@:3.11", when="@:7.3.1", type=("build", "run")) + with default_args(type="build"): + depends_on("py-setuptools@61:", when="@8.1:") + depends_on("py-setuptools@45:", when="@7:") + depends_on("py-setuptools@42:", when="@6.2:") + depends_on("py-setuptools@40:", when="@3.9.2:6.1") + depends_on("py-setuptools@30.3:", when="@3.9.0:3.9.1") + depends_on("py-setuptools") + depends_on("py-setuptools-scm@6.2.3:+toml", when="@7:") + depends_on("py-setuptools-scm@3.4:+toml", when="@6.2:") + depends_on("py-setuptools-scm", when="@3.1:") - # setup_requires - depends_on("py-setuptools@45.0:", when="@7:", type=("build", "run")) - depends_on("py-setuptools@42.0:", when="@6.2:", type=("build", "run")) - depends_on("py-setuptools@40.0:", when="@3.9.2:6.1", type=("build", "run")) - depends_on("py-setuptools@30.3:", when="@3.9.0:3.9.1", type=("build", "run")) - depends_on("py-setuptools", type=("build", "run")) - depends_on("py-setuptools-scm@6.2.3: +toml", when="@7:", type="build") - depends_on("py-setuptools-scm@3.4: +toml", when="@6.2:", type="build") - depends_on("py-setuptools-scm", when="@3.1:", type="build") + with default_args(type=("build", "run")): + depends_on("python@3.8:", when="@8:") + depends_on("python@3.7:", when="@7.1:") + # see https://github.com/pytest-dev/pytest/releases/tag/8.2.1 + depends_on("python@:3.12", when="@:8.2.0") + # see https://github.com/pytest-dev/pytest/releases/tag/7.3.2 + depends_on("python@:3.11", when="@:7.3.1") - # install_requires - depends_on("py-iniconfig", when="@6.0:", type=("build", "run")) - depends_on("py-packaging", when="@4.6:", type=("build", "run")) - depends_on("py-pluggy@1.3:1", when="@8:", type=("build", "run")) - depends_on("py-pluggy@0.12:1", when="@6.2:7", type=("build", "run")) - depends_on("py-pluggy@0.12:0", when="@4.6:6.1", type=("build", "run")) - depends_on("py-pluggy@0.9.0:0.9,0.11:0", when="@4.5.0:4.5", type=("build", "run")) - depends_on("py-pluggy@0.11:", when="@4.4.2:4.4", type=("build", "run")) - depends_on("py-pluggy@0.9:", when="@4.4.0:4.4.1", type=("build", "run")) - depends_on("py-pluggy@0.7:", when="@3.7:4.3", type=("build", "run")) - depends_on("py-pluggy@0.5:0.7", when="@3.6.4:3.6", type=("build", "run")) - depends_on("py-pluggy@0.5:0.6", when="@:3.6.3", type=("build", "run")) - depends_on("py-colorama", when="platform=windows", type=("build", "run")) - depends_on("py-exceptiongroup@1:", when="@7: ^python@:3.10", type=("build", "run")) - depends_on("py-importlib-metadata@0.12:", when="@5.1: ^python@:3.7", type=("build", "run")) - depends_on("py-importlib-metadata@0.12:", when="@4.6:5.0", type=("build", "run")) - depends_on("py-tomli@1:", when="@7.1: ^python@:3.10", type=("build", "run")) - depends_on("py-tomli@1:", when="@7.0", type=("build", "run")) + depends_on("py-colorama", when="platform=windows") + depends_on("py-exceptiongroup@1:", when="@7:^python@:3.10") + depends_on("py-iniconfig", when="@6.0:") + depends_on("py-packaging", when="@4.6:") + depends_on("py-pluggy@1.5:1", when="@8.2:") + depends_on("py-pluggy@1.3:1", when="@8:") + depends_on("py-pluggy@0.12:1", when="@6.2:7") + depends_on("py-pluggy@0.12:0", when="@4.6:6.1") + depends_on("py-pluggy@0.9.0:0.9,0.11:0", when="@4.5.0:4.5") + depends_on("py-pluggy@0.11:", when="@4.4.2:4.4") + depends_on("py-pluggy@0.9:", when="@4.4.0:4.4.1") + depends_on("py-pluggy@0.7:", when="@3.7:4.3") + depends_on("py-pluggy@0.5:0.7", when="@3.6.4:3.6") + depends_on("py-pluggy@0.5:0.6", when="@:3.6.3") + depends_on("py-tomli@1:", when="@7.1: ^python@:3.10") + depends_on("py-tomli@1:", when="@7.0") - # Historic dependencies - depends_on("py-attrs@19.2.0:", when="@6.2:7.2", type=("build", "run")) - depends_on("py-attrs@17.4.0:", when="@3.5:6.1", type=("build", "run")) - depends_on("py-attrs@17.2.0:", when="@3.3:3.4", type=("build", "run")) - depends_on("py-py@1.8.2:", when="@6:7.1", type=("build", "run")) - depends_on("py-py@1.5.0:", when="@3.3:5", type=("build", "run")) - depends_on("py-py@1.4.33:", when="@3.1.2:3.2.3,3.2.5:3.2", type=("build", "run")) - depends_on("py-py@1.4.33:1.4", when="@3.2.4", type=("build", "run")) - depends_on("py-py@1.4.29:", when="@:3.1.1", type=("build", "run")) - depends_on("py-atomicwrites@1.0:", when="@5.3:7.1.2 platform=windows", type=("build", "run")) - depends_on("py-atomicwrites@1.0:", when="@3.6:5.2", type=("build", "run")) - depends_on("py-toml", when="@6", type=("build", "run")) - depends_on("py-six@1.10.0:", when="@3.3:4", type=("build", "run")) - depends_on("py-more-itertools@4.0.0:", when="@3.5.1:5", type=("build", "run")) - depends_on("py-wcwidth", when="@4.5:5", type=("build", "run")) + # Historic dependencies + depends_on("py-importlib-metadata@0.12:", when="@5.1:^python@:3.7") + depends_on("py-importlib-metadata@0.12:", when="@4.6:5.0") + depends_on("py-attrs@19.2.0:", when="@6.2:7.2") + depends_on("py-attrs@17.4.0:", when="@3.5:6.1") + depends_on("py-attrs@17.2.0:", when="@3.3:3.4") + depends_on("py-py@1.8.2:", when="@6:7.1") + depends_on("py-py@1.5.0:", when="@3.3:5") + depends_on("py-py@1.4.33:", when="@3.1.2:3.2.3,3.2.5:3.2") + depends_on("py-py@1.4.33:1.4", when="@3.2.4") + depends_on("py-py@1.4.29:", when="@:3.1.1") + depends_on("py-atomicwrites@1.0:", when="@5.3:7.1.2 platform=windows") + depends_on("py-atomicwrites@1.0:", when="@3.6:5.2") + depends_on("py-toml", when="@6") + depends_on("py-six@1.10.0:", when="@3.3:4") + depends_on("py-more-itertools@4.0.0:", when="@3.5.1:5") + depends_on("py-wcwidth", when="@4.5:5") diff --git a/var/spack/repos/builtin/packages/py-python-crfsuite/package.py b/var/spack/repos/builtin/packages/py-python-crfsuite/package.py index 6c8fd4fd69ac18..f61a582959321c 100644 --- a/var/spack/repos/builtin/packages/py-python-crfsuite/package.py +++ b/var/spack/repos/builtin/packages/py-python-crfsuite/package.py @@ -16,5 +16,8 @@ class PyPythonCrfsuite(PythonPackage): version("0.9.7", sha256="3b4538d2ce5007e4e42005818247bf43ade89ef08a66d158462e2f7c5d63cee7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-python-fmask/package.py b/var/spack/repos/builtin/packages/py-python-fmask/package.py index d2a931c858d583..d475e3641468fd 100644 --- a/var/spack/repos/builtin/packages/py-python-fmask/package.py +++ b/var/spack/repos/builtin/packages/py-python-fmask/package.py @@ -13,14 +13,19 @@ class PyPythonFmask(PythonPackage): homepage = "https://www.pythonfmask.org/en/latest/" url = "https://github.com/ubarsc/python-fmask/releases/download/pythonfmask-0.5.8/python-fmask-0.5.8.tar.gz" + maintainers("gillins", "neilflood") + license("GPL-3.0-only") + version("0.5.9", sha256="7e2875abab87da545d3ec06b9dad704105729977ad1e479a3d9d3b8294c49e44") version("0.5.8", sha256="d55f54d3fecde818374017fdbe0ad173c893ef74c79ba2a7bc1890b7ec416c2f") version("0.5.7", sha256="da9dad1b977a50599d068dedaed007100b20322a79ca5d78f702712647c2c3f3") version("0.5.6", sha256="a63abd12d36fb4ec010e618bcabd5e2f782a0479ebcbf40aec1bcef943c00c5c") version("0.5.5", sha256="8257227d2527ea5fbd229f726d06d05986914beafd090acef05772a27dbbf062") version("0.5.4", sha256="ed20776f6b63615f664da89a9e3951c79437b66c2bf88fe19a93c2cc7dc40c82") + depends_on("c", type="build") # generated + # Note: Dependencies are listed here: https://github.com/ubarsc/python-fmask/blob/master/doc/source/index.rst#introduction # pip silently replaces distutils with setuptools diff --git a/var/spack/repos/builtin/packages/py-python-javabridge/package.py b/var/spack/repos/builtin/packages/py-python-javabridge/package.py index 172ceb9eb5ef55..debdad7c59a180 100644 --- a/var/spack/repos/builtin/packages/py-python-javabridge/package.py +++ b/var/spack/repos/builtin/packages/py-python-javabridge/package.py @@ -15,6 +15,8 @@ class PyPythonJavabridge(PythonPackage): version("4.0.3", sha256="3fee0c235efcfe866f95695fdc0b6289eab2371043b32ff4ca6feff098de59c5") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-cython@0.29.16:", type="build") depends_on("py-numpy@1.20.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-python-json-logger/package.py b/var/spack/repos/builtin/packages/py-python-json-logger/package.py index e5ce437c83c225..424c9c6c637200 100644 --- a/var/spack/repos/builtin/packages/py-python-json-logger/package.py +++ b/var/spack/repos/builtin/packages/py-python-json-logger/package.py @@ -15,6 +15,7 @@ class PyPythonJsonLogger(PythonPackage): license("BSD-2-Clause") version("2.0.7", sha256="23e7ec02d34237c5aa1e29a070193a4ea87583bb4e7f8fd06d3de8264c4b2e1c") + version("2.0.2", sha256="202a4f29901a4b8002a6d1b958407eeb2dd1d83c18b18b816f5b64476dde9096") version("0.1.11", sha256="b7a31162f2a01965a5efb94453ce69230ed208468b0bbc7fdfc56e6d8df2e281") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-python-ldap/package.py b/var/spack/repos/builtin/packages/py-python-ldap/package.py index a5e675e069f396..3d1126d469697b 100644 --- a/var/spack/repos/builtin/packages/py-python-ldap/package.py +++ b/var/spack/repos/builtin/packages/py-python-ldap/package.py @@ -22,6 +22,8 @@ class PyPythonLdap(PythonPackage): version("3.2.0", sha256="7d1c4b15375a533564aad3d3deade789221e450052b21ebb9720fb822eccdb8e") version("3.0.0", sha256="86746b912a2cd37a54b06c694f021b0c8556d4caeab75ef50435ada152e2fbe1") + depends_on("c", type="build") # generated + # See https://github.com/python-ldap/python-ldap/issues/432 depends_on("openldap+client_only @:2.4", type=("build", "link", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-python-levenshtein/package.py b/var/spack/repos/builtin/packages/py-python-levenshtein/package.py index db5641154d863c..d834a0ec44a10f 100644 --- a/var/spack/repos/builtin/packages/py-python-levenshtein/package.py +++ b/var/spack/repos/builtin/packages/py-python-levenshtein/package.py @@ -17,4 +17,6 @@ class PyPythonLevenshtein(PythonPackage): version("0.12.0", sha256="033a11de5e3d19ea25c9302d11224e1a1898fe5abd23c61c7c360c25195e3eb1") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-python-libsbml/package.py b/var/spack/repos/builtin/packages/py-python-libsbml/package.py index 44ccf7db162904..4678079a97a46d 100644 --- a/var/spack/repos/builtin/packages/py-python-libsbml/package.py +++ b/var/spack/repos/builtin/packages/py-python-libsbml/package.py @@ -19,6 +19,9 @@ class PyPythonLibsbml(PythonPackage): "5.19.5", tag="v5.19.5", commit="6081d9e1b0aa2b3ff4198b39680b726094c47e85", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("swig", type="build") diff --git a/var/spack/repos/builtin/packages/py-python-lsp-jsonrpc/package.py b/var/spack/repos/builtin/packages/py-python-lsp-jsonrpc/package.py index 9c507d367d5050..e3ec86ab1a98e0 100644 --- a/var/spack/repos/builtin/packages/py-python-lsp-jsonrpc/package.py +++ b/var/spack/repos/builtin/packages/py-python-lsp-jsonrpc/package.py @@ -16,7 +16,11 @@ class PyPythonLspJsonrpc(PythonPackage): license("MIT") + version("1.1.2", sha256="4688e453eef55cd952bff762c705cedefa12055c0aec17a06f595bcc002cc912") version("1.0.0", sha256="7bec170733db628d3506ea3a5288ff76aa33c70215ed223abdb0d95e957660bd") depends_on("py-setuptools", type="build") + depends_on("py-setuptools@61.2.0:", type="build", when="@1.1.0:") + depends_on("py-setuptools-scm@3.4.3:+toml", type="build", when="@1.1.0:") + depends_on("py-ujson@3.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-python-lsp-server/package.py b/var/spack/repos/builtin/packages/py-python-lsp-server/package.py index 1292ae77fe944a..3c1e23e990bdeb 100644 --- a/var/spack/repos/builtin/packages/py-python-lsp-server/package.py +++ b/var/spack/repos/builtin/packages/py-python-lsp-server/package.py @@ -16,15 +16,22 @@ class PyPythonLspServer(PythonPackage): license("MIT") + version("1.10.0", sha256="0c9a52dcc16cd0562404d529d50a03372db1ea6fb8dfcc3792b3265441c814f4") version("1.7.1", sha256="67473bb301f35434b5fa8b21fc5ed5fac27dc8a8446ccec8bae456af52a0aef6") version("1.7.0", sha256="401ce78ea2e98cadd02d94962eb32c92879caabc8055b9a2f36d7ef44acc5435") version("1.6.0", sha256="d75cdff9027c4212e5b9e861e9a0219219c8e2c69508d9f24949951dabd0dc1b") depends_on("python@3.7:", type=("build", "run")) - depends_on("py-setuptools@61.2.0:", type=("build", "run")) + depends_on("python@3.8:", type=("build", "run"), when="@1.8.0:") + depends_on("py-setuptools@61.2.0:", type=("build", "run"), when="@:1.7") + depends_on("py-setuptools@61.2.0:", type="build", when="@1.8.0:") depends_on("py-setuptools-scm@3.4.3:+toml", type="build") + depends_on("py-docstring-to-markdown", type=("build", "run")) - depends_on("py-jedi@0.17.2:0.18", type=("build", "run")) + depends_on("py-importlib-metadata@4.8.3:", type=("build", "run"), when="@1.8.0: ^python@:3.9") + depends_on("py-jedi@0.17.2:0.18", type=("build", "run"), when="@:1.7") + depends_on("py-jedi@0.17.2:0.19", type=("build", "run"), when="@1.8.0:") depends_on("py-pluggy@1.0.0:", type=("build", "run")) - depends_on("py-python-lsp-jsonrpc@1.0.0:", type=("build", "run")) + depends_on("py-python-lsp-jsonrpc@1.0.0:1", type=("build", "run")) + depends_on("py-python-lsp-jsonrpc@1.1.0:1", type=("build", "run"), when="@1.8.0:") depends_on("py-ujson@3.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-python-lzo/package.py b/var/spack/repos/builtin/packages/py-python-lzo/package.py index 4b0c83fa670e34..482c74ad12e6c6 100644 --- a/var/spack/repos/builtin/packages/py-python-lzo/package.py +++ b/var/spack/repos/builtin/packages/py-python-lzo/package.py @@ -18,6 +18,8 @@ class PyPythonLzo(PythonPackage): version("1.15", sha256="a57aaa00c5c3a0515dd9f7426ba2cf601767dc19dc023d8b99d4a13b0a327b49") version("1.12", sha256="97a8e46825e8f1abd84c2a3372bc09adae9745a5be5d3af2692cd850dac35345") + depends_on("c", type="build") # generated + depends_on("py-setuptools@42:", when="@1.13:", type="build") depends_on("py-setuptools", type="build") depends_on("lzo") diff --git a/var/spack/repos/builtin/packages/py-python-mapnik/package.py b/var/spack/repos/builtin/packages/py-python-mapnik/package.py index 199f20295bae34..fb042f45f95377 100644 --- a/var/spack/repos/builtin/packages/py-python-mapnik/package.py +++ b/var/spack/repos/builtin/packages/py-python-mapnik/package.py @@ -20,6 +20,8 @@ class PyPythonMapnik(PythonPackage): version("3.0.16", sha256="643117752fa09668a1e26a360d13cd137329ae2013eb14ad92ab72fbc479fc70") version("3.0.13", sha256="ced684745e778c0cac0edba89c09c6f9b9f1db18fc12744ed4710a88b78a3389") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("mapnik", type=("build", "link", "run")) depends_on("boost +python+thread") diff --git a/var/spack/repos/builtin/packages/py-python-ptrace/package.py b/var/spack/repos/builtin/packages/py-python-ptrace/package.py index 5f9260bb27fcb3..94273241f6570d 100644 --- a/var/spack/repos/builtin/packages/py-python-ptrace/package.py +++ b/var/spack/repos/builtin/packages/py-python-ptrace/package.py @@ -16,4 +16,6 @@ class PyPythonPtrace(PythonPackage): version("0.9.8", sha256="1e3bc6223f626aaacde8a7979732691c11b13012e702fee9ae16c87f71633eaa") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-python-rapidjson/package.py b/var/spack/repos/builtin/packages/py-python-rapidjson/package.py index 0925652e6032e3..ed6c3f3de16224 100644 --- a/var/spack/repos/builtin/packages/py-python-rapidjson/package.py +++ b/var/spack/repos/builtin/packages/py-python-rapidjson/package.py @@ -20,6 +20,8 @@ class PyPythonRapidjson(PythonPackage): version("1.5", sha256="04323e63cf57f7ed927fd9bcb1861ef5ecb0d4d7213f2755969d4a1ac3c2de6f") version("0.9.1", sha256="ad80bd7e4bb15d9705227630037a433e2e2a7982b54b51de2ebabdd1611394a1") + depends_on("cxx", type="build") # generated + depends_on("python@3.4:", type=("build", "run")) depends_on("python@3.6:", type=("build", "run"), when="@1.5:") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pythonsollya/package.py b/var/spack/repos/builtin/packages/py-pythonsollya/package.py index 84a715c8d106f9..c8f427f873de9c 100644 --- a/var/spack/repos/builtin/packages/py-pythonsollya/package.py +++ b/var/spack/repos/builtin/packages/py-pythonsollya/package.py @@ -34,9 +34,4 @@ class PyPythonsollya(PythonPackage): @run_before("install") def patch(self): - filter_file( - "PYTHON ?= python2", - "PYTHON ?= " + self.spec["python"].command.path, - "GNUmakefile", - string=True, - ) + filter_file("PYTHON ?= python2", f"PYTHON ?= {python.path}", "GNUmakefile", string=True) diff --git a/var/spack/repos/builtin/packages/py-pythran/package.py b/var/spack/repos/builtin/packages/py-pythran/package.py index 8acf51630a6947..11828a77c3eef4 100644 --- a/var/spack/repos/builtin/packages/py-pythran/package.py +++ b/var/spack/repos/builtin/packages/py-pythran/package.py @@ -15,9 +15,14 @@ class PyPythran(PythonPackage): homepage = "https://github.com/serge-sans-paille/pythran" pypi = "pythran/pythran-0.9.11.tar.gz" + tags = ["build-tools"] license("BSD-3-Clause") + maintainers("rgommers") + version("0.16.1", sha256="861748c0f9c7d422b32724b114b3817d818ed4eab86c09781aa0a3f7ceabb7f9") + version("0.16.0", sha256="37dcf6aa9713b352b05004e3a20d14b3de7399bb0d7fe2027bd2b9e2833fe65a") + version("0.15.0", sha256="f9bc61bcb96df2cd4b578abc5a62dfb3fbb0b0ef02c264513dfb615c5f87871c") version("0.12.2", sha256="2344c7ad76255f31f79d87877cc6bb8bddc5e5593015dae29b3f821c6c06a627") version("0.12.0", sha256="eff3dd0d3eebe57372f0d14f82985525e9bcdfb5b1d1010e1932cf9207060f9f") version("0.11.0", sha256="0b2cba712e09f7630879dff69f268460bfe34a6d6000451b47d598558a92a875") @@ -33,15 +38,22 @@ class PyPythran(PythonPackage): version("0.9.4", sha256="ec9c91f5331454263b064027292556a184a9f55a50f8615e09b08f57a4909855") version("0.9.3", sha256="217427a8225a331fdc8f3efe57871aed775cdf2c6e847a0a83df0aaae4b02493") - depends_on("py-setuptools", type="build") + depends_on("cxx", type="build") # generated + + # https://github.com/serge-sans-paille/pythran/pull/2196 + depends_on("py-setuptools@62:", when="@0.15:", type=("build", "run")) + depends_on("py-setuptools", type=("build", "run")) depends_on("py-ply@3.4:", type=("build", "run")) + depends_on("py-gast@0.5", when="@0.15:", type=("build", "run")) # upper bound due to https://github.com/scipy/scipy/issues/18390 - depends_on("py-gast@0.5:0.5.3", when="@0.9.12:", type=("build", "run")) + depends_on("py-gast@0.5:0.5.3", when="@0.9.12:0.12", type=("build", "run")) depends_on("py-gast@0.4", when="@0.9.7:0.9.11", type=("build", "run")) depends_on("py-gast@0.3.3:0.3", when="@0.9.6", type=("build", "run")) depends_on("py-gast@0.3:", when="@0.9.4:0.9.5", type=("build", "run")) depends_on("py-gast", when="@:0.9.3", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) + # https://github.com/serge-sans-paille/pythran/issues/2189 + depends_on("py-numpy@:1", when="@:0.15", type=("build", "run")) depends_on("py-beniget@0.4", when="@0.9.12:", type=("build", "run")) depends_on("py-beniget@0.3", when="@0.9.7:0.9.11", type=("build", "run")) depends_on("py-beniget@0.2.1:0.2", when="@0.9.6", type=("build", "run")) @@ -69,6 +81,8 @@ class PyPythran(PythonPackage): conflicts("%apple-clang@13:", when="@:0.10") # https://github.com/serge-sans-paille/pythran/issues/2101 conflicts("^python@3.11:", when="@:0.12.1") + # from distutils.errors import CompileError in run.py + conflicts("^python@3.12:", when="@:0.15") @property def headers(self): diff --git a/var/spack/repos/builtin/packages/py-pytng/package.py b/var/spack/repos/builtin/packages/py-pytng/package.py index d499861c064691..6a1f605db674ad 100644 --- a/var/spack/repos/builtin/packages/py-pytng/package.py +++ b/var/spack/repos/builtin/packages/py-pytng/package.py @@ -20,6 +20,9 @@ class PyPytng(PythonPackage): version("0.3.0", sha256="f563f9ea260ca8c8e17b3bcf9458bae35aedd5c58e1c5ac4dfff77a1e036506e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.8:", type=("build", "run")) depends_on("py-cython@0.28:2", type="build") diff --git a/var/spack/repos/builtin/packages/py-pytorch-lightning/package.py b/var/spack/repos/builtin/packages/py-pytorch-lightning/package.py index de9c0bcb190748..133f882e378592 100644 --- a/var/spack/repos/builtin/packages/py-pytorch-lightning/package.py +++ b/var/spack/repos/builtin/packages/py-pytorch-lightning/package.py @@ -16,6 +16,7 @@ class PyPytorchLightning(PythonPackage): license("Apache-2.0") + version("2.0.7", sha256="4e6bc1e1f7b0c69016ea2fe0616b18fa62bd3d8661c7ff02c11d317746cfc5f5") version("2.0.0", sha256="632dec9af8036f726904e691c505d7650658ef0f4054a062c9e6a940ca09dfd8") version("1.9.4", sha256="188a7f4468acf23512e7f4903253d86fc7929a49f0c09d699872e364162001e8") version("1.9.3", sha256="479164caea190d49ee2a218eef7e001888be56db912b417639b047e8f9ca8a07") @@ -51,7 +52,8 @@ class PyPytorchLightning(PythonPackage): # src/pytorch_lightning/__setup__.py depends_on("python@3.8:", when="@2:", type=("build", "run")) - depends_on("py-setuptools", type="build") + # https://github.com/Lightning-AI/pytorch-lightning/pull/20081 + depends_on("py-setuptools", type=("build", "run")) # requirements/pytorch/base.txt depends_on("py-numpy@1.17.2:", when="@1.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pyuwsgi/package.py b/var/spack/repos/builtin/packages/py-pyuwsgi/package.py index 17ddbb007534bf..d5f059604bf705 100644 --- a/var/spack/repos/builtin/packages/py-pyuwsgi/package.py +++ b/var/spack/repos/builtin/packages/py-pyuwsgi/package.py @@ -17,4 +17,7 @@ class PyPyuwsgi(PythonPackage): version("2.0.21", sha256="211e8877f5191e347ba905232d04ab30e05ce31ba7a6dac4bfcb48de9845bb52") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyvista/package.py b/var/spack/repos/builtin/packages/py-pyvista/package.py index a8bd256f0db3ab..6ff66b6f69ea05 100644 --- a/var/spack/repos/builtin/packages/py-pyvista/package.py +++ b/var/spack/repos/builtin/packages/py-pyvista/package.py @@ -26,6 +26,8 @@ class PyPyvista(PythonPackage): depends_on("py-setuptools", type="build") depends_on("py-matplotlib@3.0.1:", when="@0.39:", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) + # https://github.com/pyvista/pyvista/releases/tag/v0.44.0 + depends_on("py-numpy@:1", when="@:0.43", type=("build", "run")) depends_on("pil", type=("build", "run")) depends_on("py-pooch", when="@0.37:", type=("build", "run")) depends_on("py-scooby@0.5.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pywavelets/package.py b/var/spack/repos/builtin/packages/py-pywavelets/package.py index 88fb7879391185..bcbd942707435b 100644 --- a/var/spack/repos/builtin/packages/py-pywavelets/package.py +++ b/var/spack/repos/builtin/packages/py-pywavelets/package.py @@ -20,6 +20,8 @@ class PyPywavelets(PythonPackage): version("1.1.1", sha256="1a64b40f6acb4ffbaccce0545d7fc641744f95351f62e4c6aaa40549326008c9") version("0.5.2", sha256="ce36e2f0648ea1781490b09515363f1f64446b0eac524603e5db5e180113bed9") + depends_on("c", type="build") # generated + depends_on("python@3.8:", when="@1.4.1:", type=("build", "run")) depends_on("python@3.5:", when="@1.1.1:", type=("build", "run")) depends_on("py-setuptools@:64", type="build") @@ -29,3 +31,5 @@ class PyPywavelets(PythonPackage): depends_on("py-numpy@1.17.3:", when="@1.2:", type=("build", "run")) depends_on("py-numpy@1.13.3:", when="@1.1.1:", type=("build", "run")) depends_on("py-numpy@1.9.1:", type=("build", "run")) + # https://github.com/PyWavelets/pywt/pull/731 + depends_on("py-numpy@:1", when="@:1.5", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-pywcs/package.py b/var/spack/repos/builtin/packages/py-pywcs/package.py index 8b4ca6624aef0a..a6c1c39bce9209 100644 --- a/var/spack/repos/builtin/packages/py-pywcs/package.py +++ b/var/spack/repos/builtin/packages/py-pywcs/package.py @@ -15,6 +15,9 @@ class PyPywcs(PythonPackage): version("1.12.1", sha256="efd4e0ea190e3a2521ebcde583452e126acdeac85cc8a9c78c8a96f10805b5e1") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("python@2.6:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-d2to1@0.2.3:", type="build") diff --git a/var/spack/repos/builtin/packages/py-pywin32/package.py b/var/spack/repos/builtin/packages/py-pywin32/package.py index da6f0d74399c42..c00666169979e2 100644 --- a/var/spack/repos/builtin/packages/py-pywin32/package.py +++ b/var/spack/repos/builtin/packages/py-pywin32/package.py @@ -16,4 +16,6 @@ class PyPywin32(PythonPackage): version("306", sha256="16e5ad3efbbf997080f67c3010bd4eb0067d499bbade9be1b240b7e85325c167") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyworld/package.py b/var/spack/repos/builtin/packages/py-pyworld/package.py index 5f6f6562523bf0..e8b20d7acf9533 100644 --- a/var/spack/repos/builtin/packages/py-pyworld/package.py +++ b/var/spack/repos/builtin/packages/py-pyworld/package.py @@ -19,6 +19,8 @@ class PyPyworld(PythonPackage): version("0.3.0", sha256="e19b5d8445e0c4fc45ded71863aeaaf2680064b4626b0e7c90f72e9ace9f6b5b") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy@:1.19", type=("build", "run")) depends_on("py-cython@0.24.0:", type="build") diff --git a/var/spack/repos/builtin/packages/py-pyyaml/package.py b/var/spack/repos/builtin/packages/py-pyyaml/package.py index 048b3e7d9f6686..1e995439a2dbaf 100644 --- a/var/spack/repos/builtin/packages/py-pyyaml/package.py +++ b/var/spack/repos/builtin/packages/py-pyyaml/package.py @@ -15,6 +15,7 @@ class PyPyyaml(PythonPackage): license("MIT") + version("6.0.1", sha256="bfdf460b1736c775f2ba9f6a92bca30bc2095067b8a9d77876d1fad6cc3b4a43") version("6.0", sha256="68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2") version("5.4.1", sha256="607774cbba28732bfa802b54baa7484215f530991055bb562efbed5b2f20a45e") version("5.3.1", sha256="b8eac752c5e14d3eca0e6dd9199cd627518cb5ec06add0de9d32baeee6fe645d") diff --git a/var/spack/repos/builtin/packages/py-pyzmq/package.py b/var/spack/repos/builtin/packages/py-pyzmq/package.py index 63956fb6e99b1b..660c658e9039d6 100644 --- a/var/spack/repos/builtin/packages/py-pyzmq/package.py +++ b/var/spack/repos/builtin/packages/py-pyzmq/package.py @@ -33,6 +33,9 @@ class PyPyzmq(PythonPackage): version("16.0.2", sha256="0322543fff5ab6f87d11a8a099c4c07dd8a1719040084b6ce9162bcdf5c45c9d") version("14.7.0", sha256="77994f80360488e7153e64e5959dc5471531d1648e3a4bff14a714d074a38cc2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@2.6:2.7,3.2:3.8", type=("build", "run"), when="@:14") # pyproject.toml diff --git a/var/spack/repos/builtin/packages/py-qdldl/package.py b/var/spack/repos/builtin/packages/py-qdldl/package.py index acd5cc9b99816b..3609976d89a8aa 100644 --- a/var/spack/repos/builtin/packages/py-qdldl/package.py +++ b/var/spack/repos/builtin/packages/py-qdldl/package.py @@ -21,6 +21,9 @@ class PyQdldl(PythonPackage): "0.1.5.post3", sha256="69c092f6e1fc23fb779a80a62e6fcdfe2eba05c925860248c4d6754f4736938f" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@18.0:", type="build") depends_on("py-pybind11", type="build") depends_on("py-numpy@1.7:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-qiskit-aer/package.py b/var/spack/repos/builtin/packages/py-qiskit-aer/package.py index 0d5d5a0d9a796f..2c1a2b4011551c 100644 --- a/var/spack/repos/builtin/packages/py-qiskit-aer/package.py +++ b/var/spack/repos/builtin/packages/py-qiskit-aer/package.py @@ -19,6 +19,8 @@ class PyQiskitAer(PythonPackage, CudaPackage): version("0.11.1", sha256="ff136a086d0473346e5f5309ae34cc78b103dcd8a898344c6e5f86de91af41a1") version("0.9.1", sha256="3bf5f615aaae7cc5f816c39a4e9108aabaed0cc894fb6f841e48ffd56574e7eb") + depends_on("cxx", type="build") # generated + depends_on("python@3.6:", type=("build", "run"), when="@0.9.1") depends_on("python@3.7:", type=("build", "run"), when="@0.11.1") depends_on("py-setuptools@40.1.0:", type="build") @@ -30,7 +32,7 @@ class PyQiskitAer(PythonPackage, CudaPackage): depends_on("py-qiskit-terra@0.21.0:", type=("build", "run"), when="@0.11.1") depends_on("py-scipy@1.0:", type=("build", "run")) depends_on("py-scikit-build@0.11.0:", type="build") - depends_on("py-cmake@:3.16,3.18:", type="build") + depends_on("cmake@:3.16,3.18:", type="build") depends_on("mpi", when="+mpi") depends_on("nlohmann-json@3.1.1:") depends_on("spdlog@1.5.0:") diff --git a/var/spack/repos/builtin/packages/py-qiskit-nature/package.py b/var/spack/repos/builtin/packages/py-qiskit-nature/package.py index 566edca7d4fae1..be640acc06aced 100644 --- a/var/spack/repos/builtin/packages/py-qiskit-nature/package.py +++ b/var/spack/repos/builtin/packages/py-qiskit-nature/package.py @@ -19,6 +19,8 @@ class PyQiskitNature(PythonPackage): version("0.2.2", sha256="ce3558d4acf2511111cc398361146af36391d67e5a9fe9c4bd0f727cb56022bf") + depends_on("fortran", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools@40.1.0:", type="build") diff --git a/var/spack/repos/builtin/packages/py-qmtest/package.py b/var/spack/repos/builtin/packages/py-qmtest/package.py index 01bad9ce4c5792..d938ef1fc1a784 100644 --- a/var/spack/repos/builtin/packages/py-qmtest/package.py +++ b/var/spack/repos/builtin/packages/py-qmtest/package.py @@ -18,6 +18,9 @@ class PyQmtest(PythonPackage): version("2.4.1", sha256="098f705aea9c8f7f5b6b5fe131974cee33b50cad3e13977e39708f306ce9ac91") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Patch to fix python 3.10 and above compatibility patch("wininst.patch", when="@2.4.1^python@3.10:") diff --git a/var/spack/repos/builtin/packages/py-quantiphy/package.py b/var/spack/repos/builtin/packages/py-quantiphy/package.py new file mode 100644 index 00000000000000..528ce4dc5b2bf1 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-quantiphy/package.py @@ -0,0 +1,22 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyQuantiphy(PythonPackage): + """physical quantities (numbers with units)""" + + homepage = "https://quantiphy.readthedocs.io" + pypi = "quantiphy/quantiphy-2.20.tar.gz" + + maintainers("ax3l") + + license("MIT", checked_by="ax3l") + + version("2.20", sha256="ba5375ac55c3b90077a793588dd5a88aaf81b2c3b0fc9c9359513ac39f6ed84d") + + depends_on("python@3.6:", type=("build", "run")) + depends_on("py-flit-core@2:3", type=("build")) diff --git a/var/spack/repos/builtin/packages/py-quantum-blackbird/package.py b/var/spack/repos/builtin/packages/py-quantum-blackbird/package.py index adf5ab6dbdcdf9..d4d1baa6790b36 100644 --- a/var/spack/repos/builtin/packages/py-quantum-blackbird/package.py +++ b/var/spack/repos/builtin/packages/py-quantum-blackbird/package.py @@ -20,6 +20,8 @@ class PyQuantumBlackbird(PythonPackage): version("0.5.0", sha256="065c73bf5263ce8f9b72dcd2b434f3bfbb471f0a6907c97a617ec0c8bde01db3") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy@1.16:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-quast/package.py b/var/spack/repos/builtin/packages/py-quast/package.py index 46032d7dd1fcf9..c6ddc7f9fd1272 100644 --- a/var/spack/repos/builtin/packages/py-quast/package.py +++ b/var/spack/repos/builtin/packages/py-quast/package.py @@ -23,6 +23,9 @@ class PyQuast(PythonPackage): version("4.6.1", sha256="7ace5bebebe9d2a70ad45e5339f998bd651c1c6b9025f7a3b51f44c87ea5bae0") version("4.6.0", sha256="3a7ee7a2abfeb0541b299b67f263ba95f9743f8809ddf5dfaca9c3c8f9b6a215") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost@1.56.0") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/py-qutip/package.py b/var/spack/repos/builtin/packages/py-qutip/package.py index 2b3237341d3d85..fce20b2198612e 100644 --- a/var/spack/repos/builtin/packages/py-qutip/package.py +++ b/var/spack/repos/builtin/packages/py-qutip/package.py @@ -18,9 +18,13 @@ class PyQutip(PythonPackage): version("4.7.1", sha256="9a87178e68b145c2145b526caa943ccc8400a111325ced45bd17f9b893663af2") version("4.7.0", sha256="a9dde64457991ef1c5a7d4186b5348a16a71480a610f1c0902e4d656ddc12e31") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-packaging", type=("build", "run")) depends_on("py-cython@0.29.20:", type="build") depends_on("py-numpy@1.16.6:", type=("build", "run")) + # https://github.com/qutip/qutip/pull/2421 + depends_on("py-numpy@:1", type=("build", "run")) depends_on("py-scipy@1.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-radical-gtod/package.py b/var/spack/repos/builtin/packages/py-radical-gtod/package.py index 5c6679f63be8d9..1b5ec630078482 100644 --- a/var/spack/repos/builtin/packages/py-radical-gtod/package.py +++ b/var/spack/repos/builtin/packages/py-radical-gtod/package.py @@ -45,6 +45,8 @@ class PyRadicalGtod(PythonPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("py-radical-utils", type=("build", "run"), when="@1.13:") depends_on("python@3.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-rapidfuzz/package.py b/var/spack/repos/builtin/packages/py-rapidfuzz/package.py index 37c7925f8d8871..189c3e448476f6 100644 --- a/var/spack/repos/builtin/packages/py-rapidfuzz/package.py +++ b/var/spack/repos/builtin/packages/py-rapidfuzz/package.py @@ -18,6 +18,8 @@ class PyRapidfuzz(PythonPackage): version("2.2.0", sha256="acb8839aac452ec61a419fdc8799e8a6e6cd21bed53d04678cdda6fba1247e2f") version("1.8.2", sha256="d6efbb2b6b18b3a67d7bdfbcd9bb72732f55736852bbef823bdf210f9e0c6c90") + depends_on("cxx", type="build") # generated + depends_on("python", type=("build", "link", "run")) depends_on("py-setuptools@42:", when="@2:", type="build") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-rarfile/package.py b/var/spack/repos/builtin/packages/py-rarfile/package.py index 34f09c3e66c25c..17847df62ac4c3 100644 --- a/var/spack/repos/builtin/packages/py-rarfile/package.py +++ b/var/spack/repos/builtin/packages/py-rarfile/package.py @@ -13,7 +13,9 @@ class PyRarfile(PythonPackage): pypi = "rarfile/rarfile-4.0.tar.gz" license("ISC") + maintainers("adamjstewart") + version("4.2", sha256="8e1c8e72d0845ad2b32a47ab11a719bc2e41165ec101fd4d3fe9e92aa3f469ef") version("4.1", sha256="db60b3b5bc1c4bdeb941427d50b606d51df677353385255583847639473eda48") version("4.0", sha256="67548769229c5bda0827c1663dce3f54644f9dbfba4ae86d4da2b2afd3e602a1") diff --git a/var/spack/repos/builtin/packages/py-rasterio/package.py b/var/spack/repos/builtin/packages/py-rasterio/package.py index db5a1ec0e6a69a..b5beaae8f2f9d2 100644 --- a/var/spack/repos/builtin/packages/py-rasterio/package.py +++ b/var/spack/repos/builtin/packages/py-rasterio/package.py @@ -22,6 +22,7 @@ class PyRasterio(PythonPackage): license("BSD-3-Clause") version("master", branch="master") + version("1.3.10", sha256="ce182c735b4f9e8735d90600607ecab15ef895eb8aa660bf665751529477e326") version("1.3.9", sha256="fc6d0d290492fa1a5068711cfebb21cc936968891b7ed9da0690c8a7388885c5") version("1.3.8", sha256="ffdd18e78efdf8ad5861065fd812a66dd34264293317ff6540a078ea891cdef8") version("1.3.7", sha256="abfdcb8f10210b8fad939f40d545d6c47e9e3b5cf4a43773ca8dd11c58204304") @@ -39,7 +40,8 @@ class PyRasterio(PythonPackage): # From pyproject.toml depends_on("py-setuptools@67.8:", when="@1.3.9:", type="build") - depends_on("py-cython@0.29.29:", when="@1.3.3:", type="build") + depends_on("py-cython@3.0.2:", when="@1.3.10:", type="build") + depends_on("py-cython@0.29.29:", when="@1.3.3:1.3.9", type="build") depends_on("py-cython@0.29.24:0.29", when="@1.3.0:1.3.2", type="build") # From setup.py @@ -52,9 +54,12 @@ class PyRasterio(PythonPackage): depends_on("py-click@4:", when="@1.2.4:", type=("build", "run")) depends_on("py-click@4:7", when="@:1.2.3", type=("build", "run")) depends_on("py-cligj@0.5:", type=("build", "run")) + depends_on("py-importlib-metadata", when="@1.3.10: ^python@:3.9", type=("build", "run")) depends_on("py-numpy@1.18:", when="@1.3:", type=("build", "link", "run")) depends_on("py-numpy@1.15:", when="@1.2:", type=("build", "link", "run")) depends_on("py-numpy", type=("build", "link", "run")) + # https://github.com/rasterio/rasterio/issues/3024 + depends_on("py-numpy@:1", when="@:1.3.9", type=("build", "link", "run")) depends_on("py-snuggs@1.4.1:", type=("build", "run")) depends_on("py-click-plugins", type=("build", "run")) depends_on("py-setuptools", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-ray/package.py b/var/spack/repos/builtin/packages/py-ray/package.py index b434096c4388d6..c79a391c4946e4 100644 --- a/var/spack/repos/builtin/packages/py-ray/package.py +++ b/var/spack/repos/builtin/packages/py-ray/package.py @@ -18,6 +18,9 @@ class PyRay(PythonPackage): version("2.0.1", sha256="b8b2f0a99d2ac4c001ff11c78b4521b217e2a02df95fb6270fd621412143f28b") version("0.8.7", sha256="2df328f1bcd3eeb4fa33119142ea0d669396f4ab2a3e78db90178757aa61534b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("default", default=False, description="Install default extras", when="@2.0.1") depends_on("python@3.6:3.10", when="@2.0.1", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-regex/package.py b/var/spack/repos/builtin/packages/py-regex/package.py index 57d7619b240f44..7f5d2c99e37677 100644 --- a/var/spack/repos/builtin/packages/py-regex/package.py +++ b/var/spack/repos/builtin/packages/py-regex/package.py @@ -29,5 +29,7 @@ class PyRegex(PythonPackage): "2017.07.11", sha256="dbda8bdc31a1c85445f1a1b29d04abda46e5c690f8f933a9cc3a85a358969616" ) + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("python@3.6:", when="@2022.8.17:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-reproject/package.py b/var/spack/repos/builtin/packages/py-reproject/package.py index b4595518ce7b8d..30b2e6aeb87d6e 100644 --- a/var/spack/repos/builtin/packages/py-reproject/package.py +++ b/var/spack/repos/builtin/packages/py-reproject/package.py @@ -26,6 +26,8 @@ class PyReproject(PythonPackage): version("0.7.1", sha256="95c0fa49e6b4e36455b91fa09ad1b71b230c990ad91d948af67ea3509a1a4ccb") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-setuptools-scm", type="build") diff --git a/var/spack/repos/builtin/packages/py-requests/package.py b/var/spack/repos/builtin/packages/py-requests/package.py index 4b88746a5358c8..6cad175f44b384 100644 --- a/var/spack/repos/builtin/packages/py-requests/package.py +++ b/var/spack/repos/builtin/packages/py-requests/package.py @@ -15,6 +15,7 @@ class PyRequests(PythonPackage): license("Apache-2.0") + version("2.32.2", sha256="dd951ff5ecf3e3b3aa26b40703ba77495dab41da839ae72ef3c8e5d8e2433289") version("2.31.0", sha256="942c5a758f98d790eaed1a29cb6eefc7ffb0d1cf7af05c3d2791656dbd6ad1e1") version("2.28.2", sha256="98b1b2782e3c6c4904938b84c0eb932721069dfdb9134313beff7c83c2df24bf") version("2.28.1", sha256="7c5599b102feddaa661c826c56ab4fee28bfd17f5abca1ebbe3e7f19d7c97983") diff --git a/var/spack/repos/builtin/packages/py-rich/package.py b/var/spack/repos/builtin/packages/py-rich/package.py index 51ef332d7f19bb..fe40bdf31e3977 100644 --- a/var/spack/repos/builtin/packages/py-rich/package.py +++ b/var/spack/repos/builtin/packages/py-rich/package.py @@ -16,7 +16,9 @@ class PyRich(PythonPackage): license("MIT") + version("13.7.1", sha256="9be308cb1fe2f1f57d67ce99e95af38a1e2bc71ad9813b0e247cf7ffbcc3a432") version("13.4.2", sha256="d653d6bccede5844304c605d5aac802c7cf9621efd700b46c7ec2b51ea914898") + version("12.6.0", sha256="ba3a3775974105c221d31141f2c116f4fd65c5ceb0698657a11e9f295ec93fd0") version("12.5.1", sha256="63a5c5ce3673d3d5fbbf23cd87e11ab84b6b451436f1b7f19ec54b6bc36ed7ca") version("10.14.0", sha256="8bfe4546d56b4131298d3a9e571a0742de342f1593770bd0d4707299f772a0af") version("10.9.0", sha256="ba285f1c519519490034284e6a9d2e6e3f16dc7690f2de3d9140737d81304d22") diff --git a/var/spack/repos/builtin/packages/py-rios/package.py b/var/spack/repos/builtin/packages/py-rios/package.py index a91712e25e586a..7b2830201e92c7 100644 --- a/var/spack/repos/builtin/packages/py-rios/package.py +++ b/var/spack/repos/builtin/packages/py-rios/package.py @@ -17,8 +17,13 @@ class PyRios(PythonPackage): homepage = "https://www.rioshome.org/en/latest/" url = "https://github.com/ubarsc/rios/releases/download/rios-1.4.16/rios-1.4.16.tar.gz" + maintainers("neilflood", "gillins") + license("GPL-3.0-only") + version("2.0.2", sha256="c5949f581fd6657e3257c69b382971ce5831a403a2edc8971b61197bdc78e5a4") + version("2.0.1", sha256="8b8bcbf11a45af46d25b95d9d4a402ec0466ed117b3464f4226a6a466d9687b5") + version("1.4.17", sha256="81007af2d0bcf2a3bf064dc2445087f8b2264c941fa66441b2b1b503168e677d") version("1.4.16", sha256="2f553d85ff4ff26bfda2a8c6bd3d9dcce5ace847f7d9bd2f072c8943f3758ded") version("1.4.15", sha256="71670508dbffcd8f5d24fbb25e6a2b7e1d23b5e899ddc78c90d403bd65981cf4") version("1.4.14", sha256="ea22fde3fe70004aa1ad46bd36fad58f3346e9c161ca44ac913518a6e4fcad82") @@ -27,10 +32,28 @@ class PyRios(PythonPackage): version("1.4.11", sha256="b7ae5311f987b32f1afe1fabc16f25586de8d15c17a69405d1950aeada7b748e") version("1.4.10", sha256="6324acccc6018f9e06c40370bc366dc459890e8c09d26e0ebd245f6fd46dad71") - variant("parallel", default=True, description="Enables the parallel processing module") + # https://github.com/ubarsc/rios/pull/90 + conflicts("^py-numpy@2:", when="@:2.0.1") + + # In 1.4.x, parallel processing was an extra add-on + variant( + "parallel", + default=True, + when="@1.4.16:1.4", + description="Enables the 1.4.x parallel processing module (deprecated)", + ) + # In 2.x, there is substantial concurrency always built-in, but using it + # across multiple machines requires an extra dependency. + variant( + "multimachine", + default=False, + when="@2:", + description="Enable compute worker kinds that run across multiple machines", + ) # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) depends_on("gdal+python", type=("build", "run")) - depends_on("py-cloudpickle", type=("build", "run"), when="@1.4.16:+parallel") + depends_on("py-cloudpickle", type="run", when="@1.4.16:1.4+parallel") + depends_on("py-cloudpickle", type="run", when="@2:+multimachine") diff --git a/var/spack/repos/builtin/packages/py-river/package.py b/var/spack/repos/builtin/packages/py-river/package.py index 02550c3dd32a37..26eac0748ed8a0 100644 --- a/var/spack/repos/builtin/packages/py-river/package.py +++ b/var/spack/repos/builtin/packages/py-river/package.py @@ -18,6 +18,8 @@ class PyRiver(PythonPackage): version("0.13.0", sha256="9d068b7a9db32302fbd581af81315681dfe61774a5d777fb3d5982d3c3061340") + depends_on("c", type="build") # generated + # pyproject.toml depends_on("py-cython", type="build") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-rmm/package.py b/var/spack/repos/builtin/packages/py-rmm/package.py index f5f7df552d9070..f5ed07409f2418 100644 --- a/var/spack/repos/builtin/packages/py-rmm/package.py +++ b/var/spack/repos/builtin/packages/py-rmm/package.py @@ -18,6 +18,8 @@ class PyRmm(PythonPackage): version("0.15.0", sha256="599f97b95d169a90d11296814763f7e151a8a1e060ba10bc6c8f4684a5cd7972") + depends_on("cxx", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-rtree/package.py b/var/spack/repos/builtin/packages/py-rtree/package.py index 51f0a1420a40cf..cff9e27399817e 100644 --- a/var/spack/repos/builtin/packages/py-rtree/package.py +++ b/var/spack/repos/builtin/packages/py-rtree/package.py @@ -10,12 +10,13 @@ class PyRtree(PythonPackage): """R-Tree spatial index for Python GIS.""" homepage = "https://github.com/Toblerity/rtree" - pypi = "Rtree/Rtree-0.8.3.tar.gz" + pypi = "Rtree/rtree-1.3.0.tar.gz" maintainers("adamjstewart", "hobu") license("MIT") + version("1.3.0", sha256="b36e9dd2dc60ffe3d02e367242d2c26f7281b00e1aaf0c39590442edaaadd916") version("1.2.0", sha256="f5145f7852bf7f95c126fb16bf1a4c2ca9300ae151b07f8a0f7083ea47912675") version("1.1.0", sha256="6f8ee504dde5d005b25b08aaf5be0b3404af3ad5fece6e1ddcde35908a798a95") version("1.0.1", sha256="222121699c303a64065d849bf7038b1ecabc37b65c7fa340bedb38ef0e805429") @@ -30,6 +31,13 @@ class PyRtree(PythonPackage): depends_on("py-typing-extensions@3.7:", when="@1: ^python@:3.7", type=("build", "run")) depends_on("libspatialindex@1.8.5:") + def url_for_version(self, version): + url = "https://files.pythonhosted.org/packages/source/R/Rtree/{}-{}.tar.gz" + name = "Rtree" + if version >= Version("1.3.0"): + name = name.lower() + return url.format(name, version) + def setup_build_environment(self, env): env.set("SPATIALINDEX_C_LIBRARY", self.spec["libspatialindex"].libs[0]) diff --git a/var/spack/repos/builtin/packages/py-ruamel-ordereddict/package.py b/var/spack/repos/builtin/packages/py-ruamel-ordereddict/package.py index b29f6a1441a09d..6d1916affa7d94 100644 --- a/var/spack/repos/builtin/packages/py-ruamel-ordereddict/package.py +++ b/var/spack/repos/builtin/packages/py-ruamel-ordereddict/package.py @@ -21,4 +21,6 @@ class PyRuamelOrdereddict(PythonPackage): version("0.4.14", sha256="281051d26eb2b18ef3d920e1e260716a52bd058a6b1a2f324102fc6a15cb8d4a") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-ruamel-yaml-clib/package.py b/var/spack/repos/builtin/packages/py-ruamel-yaml-clib/package.py index c9fc6572a0790f..0989481157965c 100644 --- a/var/spack/repos/builtin/packages/py-ruamel-yaml-clib/package.py +++ b/var/spack/repos/builtin/packages/py-ruamel-yaml-clib/package.py @@ -19,6 +19,8 @@ class PyRuamelYamlClib(PythonPackage): version("0.2.7", sha256="1f08fd5a2bea9c4180db71678e850b995d2a5f4537be0e94557668cf0f5f9497") version("0.2.0", sha256="b66832ea8077d9b3f6e311c4a53d06273db5dc2db6e8a908550f3c14d67e718c") + depends_on("c", type="build") # generated + depends_on("python", type=("build", "link", "run")) # to prevent legacy-install-failure depends_on("python@:3.9", when="@0.2.0", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/py-ruff/package.py b/var/spack/repos/builtin/packages/py-ruff/package.py index 89fda4deec22d0..88c67398e59d27 100644 --- a/var/spack/repos/builtin/packages/py-ruff/package.py +++ b/var/spack/repos/builtin/packages/py-ruff/package.py @@ -14,17 +14,15 @@ class PyRuff(PythonPackage): git = "https://github.com/astral-sh/ruff.git" license("MIT") + maintainers("adamjstewart") + version("0.4.5", sha256="286eabd47e7d4d521d199cab84deca135557e6d1e0f0d01c29e757c3cb151b54") + version("0.4.0", sha256="7457308d9ebf00d6a1c9a26aa755e477787a636c90b823f91cd7d4bea9e89260") + version("0.3.7", sha256="d5c1aebee5162c2226784800ae031f660c350e7a3402c4d1f8ea4e97e232e3ba") version("0.3.0", sha256="0886184ba2618d815067cf43e005388967b67ab9c80df52b32ec1152ab49f53a") version("0.1.6", sha256="1b09f29b16c6ead5ea6b097ef2764b42372aebe363722f1605ecbcd2b9207184") - version( - "0.0.276", - sha256="d456c86eb6ce9225507f24fcc7bf72fa031bb7cc750023310e62889bf4ad4b6a", - deprecated=True, - ) depends_on("py-maturin@1", type="build") # Found in Cargo.toml - depends_on("rust@1.71:", when="@0.1.6:", type="build") - depends_on("rust@1.70:", when="@0.0.276:", type="build") + depends_on("rust@1.71:", type="build") diff --git a/var/spack/repos/builtin/packages/py-safetensors/package.py b/var/spack/repos/builtin/packages/py-safetensors/package.py index 70df04ceccd773..f0f11247c55c2a 100644 --- a/var/spack/repos/builtin/packages/py-safetensors/package.py +++ b/var/spack/repos/builtin/packages/py-safetensors/package.py @@ -12,7 +12,9 @@ class PySafetensors(PythonPackage): homepage = "https://github.com/huggingface/safetensors" pypi = "safetensors/safetensors-0.3.1.tar.gz" + version("0.4.3", sha256="2f85fc50c4e07a21e95c24e07460fe6f7e2859d0ce88092838352b798ce711c2") version("0.3.1", sha256="571da56ff8d0bec8ae54923b621cda98d36dcef10feb36fd492c4d0c2cd0e869") depends_on("py-setuptools", type="build") depends_on("py-setuptools-rust", type="build") + depends_on("py-maturin", type="build", when="@0.4.3") diff --git a/var/spack/repos/builtin/packages/py-scandir/package.py b/var/spack/repos/builtin/packages/py-scandir/package.py index fe1b75317bb043..df09535c75f94b 100644 --- a/var/spack/repos/builtin/packages/py-scandir/package.py +++ b/var/spack/repos/builtin/packages/py-scandir/package.py @@ -18,4 +18,6 @@ class PyScandir(PythonPackage): version("1.9.0", sha256="44975e209c4827fc18a3486f257154d34ec6eaec0f90fef0cca1caa482db7064") version("1.6", sha256="e0278a2d4bc6c0569aedbe66bf26c8ab5b2b08378b3289de49257f23ac624338") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type=("build")) diff --git a/var/spack/repos/builtin/packages/py-scientificpython/package.py b/var/spack/repos/builtin/packages/py-scientificpython/package.py index 14e3de34e34bbe..c5bbdea26e617f 100644 --- a/var/spack/repos/builtin/packages/py-scientificpython/package.py +++ b/var/spack/repos/builtin/packages/py-scientificpython/package.py @@ -19,6 +19,8 @@ class PyScientificpython(PythonPackage): version("2.8.1", sha256="d9ef354736410bbb2e8be33cb7433cf62114307a44e3a96baaa793b58b4b518b") + depends_on("c", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-scikit-build-core/package.py b/var/spack/repos/builtin/packages/py-scikit-build-core/package.py index fbe3ed171299e4..d80b5a92d67c81 100644 --- a/var/spack/repos/builtin/packages/py-scikit-build-core/package.py +++ b/var/spack/repos/builtin/packages/py-scikit-build-core/package.py @@ -19,10 +19,17 @@ class PyScikitBuildCore(PythonPackage): license("Apache-2.0") + version("0.9.5", sha256="2a4cb119cc968fe87ae05582979657cc0e7be45655798446eabbe490e61ce072") + version("0.8.2", sha256="50ec24b9568c9aa6e27233deeb2978932bc79856212b30575cbfa4049655c436") + version("0.7.1", sha256="565f33e15f5aa4514248c508ce3ce40fb6f406f8c3983e891561757b1c9f78ab") version("0.6.1", sha256="392254a4ca7235c27a4be98cc24cd708f563171961ce37cff66120ebfda20b7a") version("0.6.0", sha256="1bea5ed83610b367f3446badd996f2356690548188d6d38e5b93152df311a7ae") version("0.2.0", sha256="d2a76d9447a412038dc5e25dd259b03c25278661a0c7c3da766bb971c1a9acd2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("pyproject", default=False, description="Enable pyproject.toml support") depends_on("python@3.7:", type=("build", "run")) @@ -32,29 +39,44 @@ class PyScikitBuildCore(PythonPackage): depends_on("py-hatch-vcs", type="build") # Dependencies + depends_on("py-exceptiongroup@1:", when="@0.9: ^python@:3.10", type=("build", "run")) depends_on("py-exceptiongroup", when="^python@:3.10", type=("build", "run")) + depends_on("py-importlib-metadata@1:", when="@0.9: ^python@:3.7") depends_on("py-importlib-metadata", when="@0.3.0: ^python@:3.7") depends_on("py-importlib-resources@1.3:", when="^python@:3.8", type=("build", "run")) + depends_on("py-packaging@21.3:", type=("build", "run"), when="@0.9:") depends_on("py-packaging@20.9:", type=("build", "run")) + depends_on("py-pathspec@0.10.1:", type=("build", "run"), when="@0.9:") + depends_on("py-tomli@1.2.2:", when="@0.9: ^python@:3.10", type=("build", "run")) depends_on("py-tomli@1.1:", when="^python@:3.10", type=("build", "run")) - depends_on("py-typing-extensions@3.10:", when="^python@:3.7", type=("build", "run")) + depends_on("py-typing-extensions@3.10:", when="@0.8: ^python@:3.8", type=("build", "run")) + depends_on("py-typing-extensions@3.10:", when="@:0.7 ^python@:3.7", type=("build", "run")) depends_on("cmake@3.15:", type=("build", "run")) # Optional dependencies - depends_on("py-pyproject-metadata@0.5:", when="+pyproject", type=("build", "run")) - depends_on("py-pathspec@0.10.1:", when="+pyproject", type=("build", "run")) + depends_on("py-pyproject-metadata@0.5:", when="@:0.8 +pyproject", type=("build", "run")) + depends_on("py-pathspec@0.10.1:", when="@:0.8 +pyproject", type=("build", "run")) # Test dependencies - depends_on("py-build +virtualenv", type="test") + depends_on("py-build@0.8:", when="@0.9:", type="test") + depends_on("py-build +virtualenv", when="@:0.8", type="test") depends_on("py-cattrs@22.2:", type="test") depends_on("py-importlib-metadata", when="^python@:3.7", type="test") - depends_on("py-pathspec@0.10.1:", type="test") + depends_on("py-pybind11@2.12:", when="@0.9:", type="test") + depends_on("py-pathspec@0.10.1:", when="@:0.8", type="test") + depends_on("py-pybind11@2.12:", when="@0.9:", type="test") depends_on("py-pybind11", type="test") - depends_on("py-pyproject-metadata@0.5:", type="test") + depends_on("py-pyproject-metadata@0.5:", when="@:0.8", type="test") depends_on("py-pytest@7:", type="test") depends_on("py-pytest-subprocess@1.5:", type="test") + depends_on("py-setuptools@43:", when="@0.9: ^python@:3.8", type="test") + depends_on("py-setuptools@45:", when="@0.9: ^python@3.9", type="test") + depends_on("py-setuptools@49:", when="@0.9: ^python@3.10:3.11", type="test") + depends_on("py-setuptools@66.1:", when="@0.9: ^python@3.12:", type="test") + depends_on("py-virtualenv@20.0.28:", when="@0.9:", type="test") depends_on("py-setuptools", type="test") depends_on("py-virtualenv", when="@0.6:", type="test") + depends_on("py-wheel@0.40:", when="@0.9:", type="test") depends_on("py-wheel", type="test") @run_after("install") diff --git a/var/spack/repos/builtin/packages/py-scikit-build/package.py b/var/spack/repos/builtin/packages/py-scikit-build/package.py index e1396d17e9f402..1965141616ef9e 100644 --- a/var/spack/repos/builtin/packages/py-scikit-build/package.py +++ b/var/spack/repos/builtin/packages/py-scikit-build/package.py @@ -28,6 +28,9 @@ class PyScikitBuild(PythonPackage): version("0.11.1", sha256="da40dfd69b2456fad1349a894b90180b43712152b8a85d2a00f4ae2ce8ac9a5c") version("0.10.0", sha256="7342017cc82dd6178e3b19377389b8a8d1f8b429d9cdb315cfb1094e34a0f526") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("py-hatchling", when="@0.17:", type="build") depends_on("py-hatch-fancy-pypi-readme", when="@0.17:", type="build") depends_on("py-hatch-vcs", when="@0.17:", type="build") diff --git a/var/spack/repos/builtin/packages/py-scikit-fmm/package.py b/var/spack/repos/builtin/packages/py-scikit-fmm/package.py index e97e8d4489ec11..d412207954d051 100644 --- a/var/spack/repos/builtin/packages/py-scikit-fmm/package.py +++ b/var/spack/repos/builtin/packages/py-scikit-fmm/package.py @@ -20,5 +20,7 @@ class PyScikitFmm(PythonPackage): version("master", branch="master") version("2019.1.30", sha256="eb64b6d8e30b8df8f8636d5fc4fd7ca6a9b05938ccd62518c80c1d9e823069dd") + depends_on("cxx", type="build") # generated + depends_on("py-numpy@1.0.2:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-scikit-image/package.py b/var/spack/repos/builtin/packages/py-scikit-image/package.py index 038b62b85bbd67..9f78e611bc32a5 100644 --- a/var/spack/repos/builtin/packages/py-scikit-image/package.py +++ b/var/spack/repos/builtin/packages/py-scikit-image/package.py @@ -14,6 +14,9 @@ class PyScikitImage(PythonPackage): pypi = "scikit-image/scikit_image-0.17.2.tar.gz" git = "https://github.com/scikit-image/scikit-image.git" + maintainers("adamjstewart") + license("BSD-3-Clause") + skip_modules = [ # Requires pytest "skimage.filters.rank.tests", @@ -21,6 +24,12 @@ class PyScikitImage(PythonPackage): "skimage.future.graph", ] + version("0.24.0", sha256="5d16efe95da8edbeb363e0c4157b99becbd650a60b77f6e3af5768b66cf007ab") + version("0.23.2", sha256="c9da4b2c3117e3e30364a3d14496ee5c72b09eb1a4ab1292b302416faa360590") + version("0.23.1", sha256="4ff756161821568ed56523f1c4ab9094962ba79e817a9a8e818d9f51d223d669") + version("0.23.0", sha256="f412b79c6cdf4371a7332cfc769bd62440a7e1375e8e7da171d67965d0156d48") + version("0.22.0", sha256="018d734df1d2da2719087d15f679d19285fce97cd37695103deadfaef2873236") + version("0.21.0", sha256="b33e823c54e6f11873ea390ee49ef832b82b9f70752c8759efd09d5a4e3d87f0") version("0.20.0", sha256="2cd784fce18bd31d71ade62c6221440199ead03acf7544086261ee032264cf61") version("0.19.3", sha256="24b5367de1762da6ee126dd8f30cc4e7efda474e0d7d70685433f0e3aa2ec450") version("0.18.3", sha256="ecae99f93f4c5e9b1bf34959f4dc596c41f2f6b2fc407d9d9ddf85aebd3137ca") @@ -29,6 +38,9 @@ class PyScikitImage(PythonPackage): version("0.14.2", sha256="1afd0b84eefd77afd1071c5c1c402553d67be2d7db8950b32d6f773f25850c1f") version("0.12.3", sha256="82da192f0e524701e89c5379c79200bc6dc21373f48bf7778a864c583897d7c7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Get dependencies for: # # @0.20: from pyproject.toml @@ -36,67 +48,94 @@ class PyScikitImage(PythonPackage): # @0.14:0.17 from requirements/build.txt, requirements/default.txt # @:0.13 from requirements.txt, DEPENDS.txt - depends_on("python@3.8:", when="@0.20:", type=("build", "link", "run")) - - depends_on("py-numpy@1.21.1:", when="@0.20:", type=("build", "link", "run")) - depends_on("py-numpy@1.17,1.18.1:", when="@0.19", type=("build", "link", "run")) - depends_on("py-numpy@1.16.5:1.17,1.18.1:", when="@0.18", type=("build", "link", "run")) - depends_on("py-numpy@1.15.1:1.17,1.18.1:", when="@0.17", type=("build", "link", "run")) - depends_on("py-numpy@1.14.1:", when="@0.16", type=("build", "link", "run")) - depends_on("py-numpy@1.11:", when="@0.13:0.15", type=("build", "link", "run")) - depends_on("py-numpy@1.7.2:", when="@:0.12", type=("build", "run")) - depends_on("py-scipy@1.8:", when="@0.20:", type=("build", "run")) - depends_on("py-scipy@1.4.1:", when="@0.19:", type=("build", "run")) - depends_on("py-scipy@1.0.1:", when="@0.17:", type=("build", "run")) - depends_on("py-scipy@0.19:", when="@0.16:", type=("build", "run")) - depends_on("py-scipy@0.17:", when="@0.13:", type=("build", "run")) - depends_on("py-scipy@0.9:", type=("build", "run")) - depends_on("py-networkx@2.8:", when="@0.20:", type=("build", "run")) - depends_on("py-networkx@2.2:", when="@0.19:", type=("build", "run")) - depends_on("py-networkx@2:", when="@0.15:", type=("build", "run")) - depends_on("py-networkx@1.8:", type=("build", "run")) - depends_on("pil@9.0.1:", when="@0.20:", type=("build", "run")) - depends_on("pil@6.1:7.0,7.1.2:8.2,8.3.1:", when="@0.19:", type=("build", "run")) - depends_on("pil@4.3:7.0,7.1.2:", when="@0.17:", type=("build", "run")) - depends_on("pil@4.3:", when="@0.14:", type=("build", "run")) - depends_on("pil@2.1:", type=("build", "run")) - depends_on("py-imageio@2.4.1:", when="@0.19:", type=("build", "run")) - depends_on("py-imageio@2.3:", when="@0.16:", type=("build", "run")) - depends_on("py-imageio@2.0.1:", when="@0.15:", type=("build", "run")) - depends_on("py-tifffile@2019.7.26:", when="@0.17:", type=("build", "run")) - depends_on("py-pywavelets@1.1.1:", when="@0.17:", type=("build", "run")) - depends_on("py-pywavelets@0.4:", when="@0.13:", type=("build", "run")) - depends_on("py-packaging@20:", when="@0.19:", type=("build", "run")) - depends_on("py-lazy-loader@0.1:", when="@0.20:", type=("build", "run")) - - depends_on("py-meson-python@0.13:", when="@0.20:", type="build") - depends_on("py-setuptools@67:", when="@0.20:", type="build") - depends_on("py-setuptools@:59.4", when="@0.19.1:0.19", type="build") - depends_on("py-setuptools@51:", when="@0.18:", type="build") - depends_on("py-setuptools", type="build") - depends_on("py-cython@0.29.24:", when="@0.20:", type="build") - depends_on("py-cython@0.29.24:2", when="@0.19", type="build") - depends_on("py-cython@0.29.21:", when="@0.18", type="build") - depends_on("py-cython@0.29.13:", when="@0.17", type="build") - depends_on("py-cython@0.25:0.28.1,0.28.3:0.28,0.29.1:", when="@0.15:0.16", type="build") - depends_on("py-cython@0.23.4:0.28.1,0.28.3:0.28,0.29.1:", when="@0.14.3:0.14", type="build") - depends_on("py-cython@0.23.4:0.28.1", when="@0.14.2", type="build") - depends_on("py-cython@0.23.4:", when="@0.14.1", type="build") - depends_on("py-cython@0.21:", when="@0.12", type="build") - depends_on("py-pythran", when="@0.19:", type="build") + with default_args(type=("build", "run")): + depends_on("python@3.10:", when="@0.23") + depends_on("python@3.9:", when="@0.22:") + + with default_args(type=("build", "link", "run")): + depends_on("py-numpy@1.23:", when="@0.23:") + depends_on("py-numpy@1.22:", when="@0.22:") + depends_on("py-numpy@1.21.1:", when="@0.20:") + depends_on("py-numpy@1.17,1.18.1:", when="@0.19") + depends_on("py-numpy@1.16.5:1.17,1.18.1:", when="@0.18") + depends_on("py-numpy@1.15.1:1.17,1.18.1:", when="@0.17") + depends_on("py-numpy@1.14.1:", when="@0.16") + depends_on("py-numpy@1.11:", when="@0.13:0.15") + depends_on("py-numpy@1.7.2:", when="@:0.12") + # https://github.com/scikit-image/scikit-image/issues/7282 + depends_on("py-numpy@:1", when="@:0.23.0") + + with default_args(type=("build", "run")): + depends_on("py-scipy@1.9:", when="@0.23:") + depends_on("py-scipy@1.8:", when="@0.20:") + depends_on("py-scipy@1.4.1:", when="@0.19:") + depends_on("py-scipy@1.0.1:", when="@0.17:") + depends_on("py-scipy@0.19:", when="@0.16:") + depends_on("py-scipy@0.17:", when="@0.13:") + depends_on("py-scipy@0.9:") + depends_on("py-networkx@2.8:", when="@0.20:") + depends_on("py-networkx@2.2:", when="@0.19:") + depends_on("py-networkx@2:", when="@0.15:") + depends_on("py-networkx@1.8:") + depends_on("pil@9.1:", when="@0.23:") + depends_on("pil@9.0.1:", when="@0.20:") + depends_on("pil@6.1:7.0,7.1.2:8.2,8.3.1:", when="@0.19:") + depends_on("pil@4.3:7.0,7.1.2:", when="@0.17:") + depends_on("pil@4.3:", when="@0.14:") + depends_on("pil@2.1:") + depends_on("py-imageio@2.33:", when="@0.23:") + depends_on("py-imageio@2.27:", when="@0.21:") + depends_on("py-imageio@2.4.1:", when="@0.19:") + depends_on("py-imageio@2.3:", when="@0.16:") + depends_on("py-imageio@2.0.1:", when="@0.15:") + depends_on("py-tifffile@2022.8.12:", when="@0.21:") + depends_on("py-tifffile@2019.7.26:", when="@0.17:") + depends_on("py-packaging@21:", when="@0.21:") + depends_on("py-packaging@20:", when="@0.19:") + depends_on("py-lazy-loader@0.4:", when="@0.23:") + depends_on("py-lazy-loader@0.3:", when="@0.22:") + depends_on("py-lazy-loader@0.2:", when="@0.21:") + depends_on("py-lazy-loader@0.1:", when="@0.20:") + + with default_args(type="build"): + depends_on("py-meson-python@0.15:", when="@0.23:") + depends_on("py-meson-python@0.14:", when="@0.22:") + depends_on("py-meson-python@0.13:", when="@0.20:") + depends_on("py-setuptools@67:", when="@0.20:") + depends_on("py-setuptools@:59.4", when="@0.19.1:0.19") + depends_on("py-setuptools@51:", when="@0.18:") + depends_on("py-setuptools") + depends_on("ninja", when="@0.20:") + depends_on("py-cython@3.0.4:", when="@0.23:") + depends_on("py-cython@0.29.32:", when="@0.21:") + depends_on("py-cython@0.29.24:", when="@0.20:") + depends_on("py-cython@0.29.24:2", when="@0.19") + depends_on("py-cython@0.29.21:", when="@0.18") + depends_on("py-cython@0.29.13:", when="@0.17") + depends_on("py-cython@0.25:0.28.1,0.28.3:0.28,0.29.1:", when="@0.15:0.16") + depends_on("py-cython@0.23.4:0.28.1,0.28.3:0.28,0.29.1:", when="@0.14.3:0.14") + depends_on("py-cython@0.23.4:0.28.1", when="@0.14.2") + depends_on("py-cython@0.23.4:", when="@0.14.1") + depends_on("py-cython@0.21:", when="@0.12") + depends_on("py-pythran", when="@0.19:") # dependencies for old versions - depends_on("py-numpydoc@0.6:", when="@0.13.0:0.13", type="build") - depends_on("py-matplotlib@2.0:2,3.0.1:", when="@0.15:0.18", type=("build", "run")) - depends_on("py-matplotlib@2:", when="@0.14:0.18", type=("build", "run")) - depends_on("py-matplotlib@1.3.1:", when="@:0.18", type=("build", "run")) - depends_on("py-six@1.10:", when="@0.14.0:0.14", type=("build", "run")) - depends_on("py-six@1.7.3:", when="@:0.14", type=("build", "run")) - depends_on("py-pooch@0.5.2:", when="@0.17.0:0.17.1", type=("build", "run")) - depends_on("py-dask+array@1:", when="@0.14.2", type=("build", "run")) - depends_on("py-dask+array@0.9:", when="@0.14.0:0.14.1", type=("build", "run")) - depends_on("py-dask+array@0.5:", when="@:0.13", type=("build", "run")) - depends_on("py-cloudpickle@0.2.1:", when="@0.14.0:0.14", type=("build", "run")) + with default_args(type="build"): + depends_on("py-numpydoc@0.6:", when="@0.13.0:0.13") + + with default_args(type=("build", "run")): + depends_on("py-pywavelets@1.1.1:", when="@0.17:0.21") + depends_on("py-pywavelets@0.4:", when="@0.13:0.16") + depends_on("py-matplotlib@2.0:2,3.0.1:", when="@0.15:0.18") + depends_on("py-matplotlib@2:", when="@0.14:0.18") + depends_on("py-matplotlib@1.3.1:", when="@:0.18") + depends_on("py-six@1.10:", when="@0.14.0:0.14") + depends_on("py-six@1.7.3:", when="@:0.14") + depends_on("py-pooch@0.5.2:", when="@0.17.0:0.17.1") + depends_on("py-dask+array@1:", when="@0.14.2") + depends_on("py-dask+array@0.9:", when="@0.14.0:0.14.1") + depends_on("py-dask+array@0.5:", when="@:0.13") + depends_on("py-cloudpickle@0.2.1:", when="@0.14.0:0.14") def url_for_version(self, version): url = ( diff --git a/var/spack/repos/builtin/packages/py-scikit-learn-extra/package.py b/var/spack/repos/builtin/packages/py-scikit-learn-extra/package.py index 2aab648a082929..d6935fb7801d08 100644 --- a/var/spack/repos/builtin/packages/py-scikit-learn-extra/package.py +++ b/var/spack/repos/builtin/packages/py-scikit-learn-extra/package.py @@ -21,10 +21,13 @@ class PyScikitLearnExtra(PythonPackage): version("0.2.0", sha256="3b1bb5fedde47920eb4b3fa0a0c18f80cc7359d9d0496720178788c6153b8019") + depends_on("cxx", type="build") # generated + # For upperbound see https://github.com/scikit-learn-contrib/scikit-learn-extra/issues/164 depends_on("python@3.6:3.10", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-cython@0.28.5:", type="build") depends_on("py-numpy@1.13.3:", type=("build", "run")) depends_on("py-scipy@0.19.1:", type=("build", "run")) - depends_on("py-scikit-learn@0.23:", type=("build", "run")) + # For upperbound see https://github.com/scikit-learn-contrib/scikit-learn-extra/issues/171 + depends_on("py-scikit-learn@0.23:1.2", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-scikit-learn/package.py b/var/spack/repos/builtin/packages/py-scikit-learn/package.py index aab35fc6bbbab5..fcbcee75e02322 100644 --- a/var/spack/repos/builtin/packages/py-scikit-learn/package.py +++ b/var/spack/repos/builtin/packages/py-scikit-learn/package.py @@ -11,14 +11,17 @@ class PyScikitLearn(PythonPackage): """A set of python modules for machine learning and data mining.""" homepage = "https://scikit-learn.org/" - pypi = "scikit-learn/scikit-learn-0.24.0.tar.gz" + pypi = "scikit-learn/scikit_learn-1.5.0.tar.gz" git = "https://github.com/scikit-learn/scikit-learn.git" - maintainers("adamjstewart") - license("BSD-3-Clause") + maintainers("adamjstewart", "rgommers") - version("master", branch="master") + version("main", branch="main") + version("master", branch="main", deprecated=True) + version("1.5.1", sha256="0ea5d40c0e3951df445721927448755d3fe1d80833b0b7308ebff5d2a45e6414") + version("1.5.0", sha256="789e3db01c750ed6d496fa2db7d50637857b451e57bcae863bff707c1247bef7") + version("1.4.2", sha256="daa1c471d95bad080c6e44b4946c9390a4842adc3082572c20e4f8884e39e959") version("1.4.0", sha256="d4373c984eba20e393216edd51a3e3eede56cbe93d4247516d205643c3b93121") version("1.3.2", sha256="a2f54c76accc15a34bfb9066e6c7a56c1e7235dda5762b990792330b52ccfb05") version("1.3.1", sha256="1a231cced3ee3fa04756b4a7ab532dc9417acd581a330adff5f2c01ac2831fcf") @@ -45,78 +48,74 @@ class PyScikitLearn(PythonPackage): version("0.22.1", sha256="51ee25330fc244107588545c70e2f3570cfc4017cff09eed69d6e1d82a212b7d") version("0.22", sha256="314abf60c073c48a1e95feaae9f3ca47a2139bd77cebb5b877c23a45c9e03012") - variant("openmp", default=True, description="Build with OpenMP support") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated # Based on PyPI wheel availability - depends_on("python@3.9:3.12", when="@1.4:", type=("build", "link", "run")) - depends_on("python@3.8:3.12", when="@1.3.1:1.3", type=("build", "link", "run")) - depends_on("python@3.8:3.11", when="@1.1.3:1.3.0", type=("build", "link", "run")) - depends_on("python@3.8:3.10", when="@1.1.0:1.1.2", type=("build", "link", "run")) - depends_on("python@:3.10", when="@1.0.2", type=("build", "link", "run")) - depends_on("python@:3.9", when="@0.24:1.0.1", type=("build", "link", "run")) - depends_on("python@:3.8", when="@0.22:0.23", type=("build", "link", "run")) - - # pyproject.toml - depends_on("py-setuptools", type="build") - depends_on("py-setuptools@:59", when="@:1.2.1", type="build") - depends_on("py-cython@0.29.33:", when="@1.4:", type="build") - depends_on("py-cython@0.29.33:2", when="@1.3", type="build") - depends_on("py-cython@0.29.24:2", when="@1.0.2:", type="build") - depends_on("py-cython@0.28.5:2", when="@0.21:", type="build") - - # sklearn/_min_dependencies.py - depends_on("py-numpy@1.19.5:", when="@1.4:", type=("build", "link", "run")) - depends_on("py-numpy@1.17.3:", when="@1.1:", type=("build", "link", "run")) - depends_on("py-numpy@1.14.6:", when="@1.0:", type=("build", "link", "run")) - depends_on("py-numpy@1.13.3:", when="@0.23:", type=("build", "link", "run")) - depends_on("py-numpy@1.11.0:", when="@0.21:", type=("build", "link", "run")) - depends_on("py-scipy@1.6:", when="@1.4:", type=("build", "run")) - depends_on("py-scipy@1.5:", when="@1.3:", type=("build", "run")) - depends_on("py-scipy@1.3.2:", when="@1.1:", type=("build", "run")) - depends_on("py-scipy@1.1.0:", when="@1.0:", type=("build", "run")) - depends_on("py-scipy@0.19.1:", when="@0.23:", type=("build", "run")) - depends_on("py-scipy@0.17.0:", when="@0.21:", type=("build", "run")) - depends_on("py-joblib@1.2:", when="@1.4:", type=("build", "run")) - depends_on("py-joblib@1.1.1:", when="@1.2:", type=("build", "run")) - depends_on("py-joblib@1:", when="@1.1:", type=("build", "run")) - depends_on("py-joblib@0.11:", type=("build", "run")) - depends_on("py-threadpoolctl@2.0.0:", when="@0.23:", type=("build", "run")) - depends_on("llvm-openmp", when="%apple-clang +openmp") - - # Test dependencies - depends_on("py-matplotlib@3.3.4:", type="test") - depends_on("py-scikit-image@0.17.2:", type="test") - depends_on("py-pandas@1.1.5:", type="test") - depends_on("py-pytest@7.1.2:", type="test") - depends_on("py-pyamg@4:", type="test") - depends_on("py-polars@0.19.12:", when="@1.4:", type="test") - depends_on("py-pyarrow@12:", when="@1.4:", type="test") - depends_on("py-pooch@1.6:", when="@1.2:", type="test") - - # Release tarballs are already cythonized. If you wanted to build a release - # version without OpenMP support, you would need to delete all .c files - # that include omp.h, as well as PKG-INFO. - # See https://github.com/scikit-learn/scikit-learn/issues/14332 - conflicts("~openmp", when="@:999", msg="Only master supports ~openmp") + with default_args(type=("build", "link", "run")): + depends_on("python@3.9:3.12", when="@1.4:") + depends_on("python@3.8:3.12", when="@1.3.1:1.3") + depends_on("python@3.8:3.11", when="@1.1.3:1.3.0") + depends_on("python@3.8:3.10", when="@1.1.0:1.1.2") + depends_on("python@:3.10", when="@1.0.2") + depends_on("python@:3.9", when="@0.24:1.0.1") + depends_on("python@:3.8", when="@0.22:0.23") + + with default_args(type="build"): + depends_on("py-meson-python@0.16:", when="@1.5.1:") + depends_on("py-meson-python@0.15:", when="@1.5:") + depends_on("py-cython@3.0.10:", when="@1.5:") + depends_on("py-cython@3.0.8:", when="@1.4.2:") + depends_on("py-cython@0.29.33:", when="@1.4.0:1.4.1") + depends_on("py-cython@0.29.33:2", when="@1.3") + depends_on("py-cython@0.29.24:2", when="@1.0.2:1.2") + depends_on("py-cython@0.28.5:2", when="@0.21:1.0.1") + + with default_args(type=("build", "link", "run")): + depends_on("py-numpy@1.19.5:", when="@1.4:") + depends_on("py-numpy@1.17.3:", when="@1.1:1.3") + depends_on("py-numpy@1.14.6:", when="@1.0") + depends_on("py-numpy@1.13.3:", when="@0.23:0.24") + depends_on("py-numpy@1.11.0:", when="@0.21:0.22") + # https://github.com/scikit-learn/scikit-learn/issues/27075 + depends_on("py-numpy@:1", when="@:1.4.1") + + with default_args(type=("build", "run")): + depends_on("py-scipy@1.6:", when="@1.4:") + depends_on("py-scipy@1.5:", when="@1.3:") + depends_on("py-scipy@1.3.2:", when="@1.1:") + depends_on("py-scipy@1.1.0:", when="@1.0:") + depends_on("py-scipy@0.19.1:", when="@0.23:") + depends_on("py-scipy@0.17.0:", when="@0.21:") + depends_on("py-joblib@1.2:", when="@1.4:") + depends_on("py-joblib@1.1.1:", when="@1.2:") + depends_on("py-joblib@1:", when="@1.1:") + depends_on("py-joblib@0.11:") + depends_on("py-threadpoolctl@3.1:", when="@1.5:") + depends_on("py-threadpoolctl@2.0:", when="@0.23:") + + depends_on("llvm-openmp", when="%apple-clang") + + # Historical dependencies + with default_args(type="build"): + depends_on("py-setuptools", when="@:1.4") + depends_on("py-setuptools@:59", when="@:1.2.1") + + def url_for_version(self, version): + url = "https://files.pythonhosted.org/packages/source/s/scikit-learn/{}-{}.tar.gz" + if version >= Version("1.5"): + name = "scikit_learn" + else: + name = "scikit-learn" + return url.format(name, version) def setup_build_environment(self, env): - # enable parallel builds of the sklearn backend + # Enable parallel builds of the sklearn backend env.append_flags("SKLEARN_BUILD_PARALLEL", str(make_jobs)) - # https://scikit-learn.org/stable/developers/advanced_installation.html#building-from-source - if self.spec.satisfies("~openmp"): - env.set("SKLEARN_NO_OPENMP", "True") - # https://scikit-learn.org/stable/developers/advanced_installation.html#mac-osx - elif self.spec.satisfies("@0.21: %apple-clang +openmp"): + # https://scikit-learn.org/stable/developers/advanced_installation.html#macos + if self.spec.satisfies("%apple-clang"): env.append_flags("CPPFLAGS", self.compiler.openmp_flag) env.append_flags("CFLAGS", self.spec["llvm-openmp"].headers.include_flags) env.append_flags("CXXFLAGS", self.spec["llvm-openmp"].headers.include_flags) env.append_flags("LDFLAGS", self.spec["llvm-openmp"].libs.ld_flags) - - @run_after("install") - @on_package_attributes(run_tests=True) - def install_test(self): - # https://scikit-learn.org/stable/developers/advanced_installation.html#testing - with working_dir("spack-test", create=True): - pytest = which("pytest") - pytest(join_path(self.prefix, python_purelib, "sklearn")) diff --git a/var/spack/repos/builtin/packages/py-scikit-sparse/package.py b/var/spack/repos/builtin/packages/py-scikit-sparse/package.py index a348d9407328c1..a96abf60f0f513 100644 --- a/var/spack/repos/builtin/packages/py-scikit-sparse/package.py +++ b/var/spack/repos/builtin/packages/py-scikit-sparse/package.py @@ -28,6 +28,8 @@ class PyScikitSparse(PythonPackage): depends_on("py-cython@0.22:", when="@0.4.12", type="build") depends_on("py-cython@0.22:0.29", when="@:0.4.11", type="build") depends_on("py-numpy@1.13.3:", type=("build", "link", "run")) + # https://github.com/scikit-sparse/scikit-sparse/issues/120 + depends_on("py-numpy@:1", type=("build", "link", "run")) depends_on("py-scipy@0.19:", type="run") depends_on("suite-sparse", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/py-scikits-odes/package.py b/var/spack/repos/builtin/packages/py-scikits-odes/package.py index 73643d80318050..725af79875ab6a 100644 --- a/var/spack/repos/builtin/packages/py-scikits-odes/package.py +++ b/var/spack/repos/builtin/packages/py-scikits-odes/package.py @@ -21,6 +21,9 @@ class PyScikitsOdes(PythonPackage): version("2.7.0", sha256="a71e19e1485893754ae8c050668232fcc694f17b83602e75fbebf7bf9f975e1e") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("py-setuptools@:64.0.0", type="build") # Upstream incorrectly only lists py-numpy only as a build dependency even diff --git a/var/spack/repos/builtin/packages/py-scipy/package.py b/var/spack/repos/builtin/packages/py-scipy/package.py index 83eb63894f29e2..3eab9ceda47039 100644 --- a/var/spack/repos/builtin/packages/py-scipy/package.py +++ b/var/spack/repos/builtin/packages/py-scipy/package.py @@ -18,6 +18,10 @@ class PyScipy(PythonPackage): license("BSD-3-Clause") version("main", branch="main") + version("1.14.0", sha256="b5923f48cb840380f9854339176ef21763118a7300a88203ccd0bdd26e58527b") + version("1.13.1", sha256="095a87a0312b08dfd6a6155cbbd310a8c51800fc931b8c0b84003014b874ed3c") + version("1.13.0", sha256="58569af537ea29d3f78e5abd18398459f195546bb3be23d16677fb26616cc11e") + version("1.12.0", sha256="4bf5abab8a36d20193c698b0f1fc282c1d083c94723902c447e5d2f1780936a3") version("1.11.4", sha256="90a2b78e7f5733b9de748f589f09225013685f9b218275257f8a8168ededaeaa") version("1.11.3", sha256="bba4d955f54edd61899776bad459bf7326e14b9fa1c552181f0479cc60a568cd") version("1.11.2", sha256="b29318a5e39bd200ca4381d80b065cdf3076c7d7281c5e36569e99273867f61d") @@ -49,55 +53,67 @@ class PyScipy(PythonPackage): version("1.3.3", sha256="64bf4e8ae0db2d42b58477817f648d81e77f0b381d0ea4427385bba3f959380a") version("1.3.2", sha256="a03939b431994289f39373c57bbe452974a7da724ae7f9620a1beee575434da4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Based on wheel availability on PyPI - depends_on("python@3.9:3.12", when="@1.11:", type=("build", "link", "run")) - depends_on("python@3.8:3.11", when="@1.9.2:1.10", type=("build", "link", "run")) - depends_on("python@3.8:3.10", when="@1.8:1.9.1", type=("build", "link", "run")) - depends_on("python@:3.10", when="@1.7.2:1.7", type=("build", "link", "run")) - depends_on("python@:3.9", when="@1.5.4:1.7.1", type=("build", "link", "run")) - depends_on("python@:3.8", when="@1.3.2:1.5.3", type=("build", "link", "run")) - - depends_on("py-meson-python@0.12.1:", when="@1.11:", type="build") - depends_on("py-meson-python@0.11:", when="@1.10:", type="build") - depends_on("py-meson-python@0.9:", when="@1.9.2:", type="build") - depends_on("py-meson-python@0.8.1:", when="@1.9.1:", type="build") - depends_on("py-meson-python@0.7:", when="@1.9:", type="build") - depends_on("meson", when="@1.9.0:1.9.1", type="build") - depends_on("py-cython@0.29.35:2", when="@1.11:", type="build") - depends_on("py-cython@0.29.32:2", when="@1.9.2:", type="build") - depends_on("py-cython@0.29.21:2", when="@1.9:", type="build") - depends_on("py-cython@0.29.18:2", when="@1.7:", type="build") - depends_on("py-pybind11@2.10.4:2.11.0", when="@1.11.3:", type=("build", "link")) - depends_on("py-pybind11@2.10.4:2.10", when="@1.11.0:1.11.2", type=("build", "link")) - depends_on("py-pybind11@2.10.1", when="@1.10", type=("build", "link")) - depends_on("py-pybind11@2.4.3:2.10", when="@1.9.1:1.9", type=("build", "link")) - depends_on("py-pybind11@2.4.3:2.9", when="@1.9.0", type=("build", "link")) - depends_on("py-pybind11@2.4.3:2.8", when="@1.8", type=("build", "link")) - depends_on("py-pybind11@2.4.3:2.7", when="@1.7.2:1.7", type=("build", "link")) - depends_on("py-pybind11@2.4.3:2.6", when="@1.6.2:1.7.1", type=("build", "link")) - depends_on("py-pybind11@2.4.3:", when="@1.5:1.6.1", type=("build", "link")) - depends_on("py-pybind11@2.4.0:", when="@1.4.1:1.4", type=("build", "link")) - depends_on("py-pybind11@2.2.4:", when="@1.4.0", type=("build", "link")) - depends_on("py-pythran@0.12:", when="@1.10:", type="build") - depends_on("py-pythran@0.10:", when="@1.8", type="build") - depends_on("py-pythran@0.9.12:", when="@1.7.2:", type="build") - depends_on("py-pythran@0.9.11:", when="@1.7:", type="build") - depends_on("py-wheel@:0.40", when="@1.11.0:1.11.2", type="build") - depends_on("py-wheel@:0.38", when="@1.10", type="build") - depends_on("py-wheel@:0.37", when="@:1.9", type="build") - depends_on("pkgconfig", when="@1.9:", type="build") - depends_on("py-setuptools", when="@:1.8", type="build") - depends_on("py-setuptools@:59", when="@1.8", type="build") - depends_on("py-setuptools@:57", when="@1.7", type="build") - depends_on("py-setuptools@:51.0.0", when="@1.6", type="build") - depends_on("py-numpy@1.21.6:1.27", when="@1.11:", type=("build", "link", "run")) - depends_on("py-numpy@1.19.5:1.26", when="@1.10", type=("build", "link", "run")) - depends_on("py-numpy@1.18.5:1.25", when="@1.9", type=("build", "link", "run")) - depends_on("py-numpy@1.17.3:1.24", when="@1.8", type=("build", "link", "run")) - depends_on("py-numpy@1.16.5:1.22", when="@1.6:1.7", type=("build", "link", "run")) - depends_on("py-numpy@1.14.5:1.21", when="@1.5", type=("build", "link", "run")) - depends_on("py-numpy@1.13.3:1.21", when="@1.3:1.4", type=("build", "link", "run")) - depends_on("py-pytest", type="test") + with default_args(type=("build", "link", "run")): + depends_on("python@3.10:3.12", when="@1.14:") + depends_on("python@3.9:3.12", when="@1.11.2:1.13") + depends_on("python@3.8:3.11", when="@1.9.2:1.11.1") + depends_on("python@3.8:3.10", when="@1.8:1.9.1") + depends_on("python@:3.10", when="@1.7.2:1.7") + depends_on("python@:3.9", when="@1.5.4:1.7.1") + depends_on("python@:3.8", when="@1.3.2:1.5.3") + + # Build dependencies (do not include upper bound unless known issues) + with default_args(type="build"): + depends_on("py-meson-python@0.15:", when="@1.12:") + depends_on("py-meson-python@0.12.1:", when="@1.11:") + depends_on("py-meson-python@0.11:", when="@1.10:") + depends_on("py-meson-python@0.9:", when="@1.9.2:") + depends_on("py-meson-python@0.8.1:", when="@1.9.1:") + depends_on("py-meson-python@0.7:", when="@1.9:") + depends_on("py-cython@3.0.8:", when="@1.13:") + depends_on("py-cython@0.29.35:", when="@1.12") + depends_on("py-cython@0.29.35:2", when="@1.11") + depends_on("py-cython@0.29.32:2", when="@1.9.2:1.10") + depends_on("py-cython@0.29.21:2", when="@1.9.0:1.9.1") + depends_on("py-cython@0.29.18:2", when="@1.7:1.8") + with default_args(type=("build", "link")): + depends_on("py-pybind11@2.12:", when="@1.13:") + depends_on("py-pybind11@2.10.4:", when="@1.11:") + depends_on("py-pybind11@2.10.1:", when="@1.10:") + depends_on("py-pybind11@2.4.3:", when="@1.5:") + depends_on("py-pybind11@2.4.0:", when="@1.4.1:") + depends_on("py-pybind11@2.2.4:", when="@1.4.0:") + depends_on("py-pythran@0.14:", when="@1.13:") + depends_on("py-pythran@0.15:", when="@1.12") + depends_on("py-pythran@0.12:", when="@1.10:") + depends_on("py-pythran@0.10:", when="@1.8:") + depends_on("py-pythran@0.9.12:", when="@1.7.2:") + depends_on("py-pythran@0.9.11:", when="@1.7:") + depends_on("pkgconfig", when="@1.9:") + + # Run dependencies + with default_args(type=("build", "link", "run")): + depends_on("py-numpy@1.23.5:2.2", when="@1.14:") + depends_on("py-numpy@1.22.4:2.2", when="@1.13") + depends_on("py-numpy@1.22.4:1.28", when="@1.12") + depends_on("py-numpy@1.21.6:1.27", when="@1.11") + depends_on("py-numpy@1.19.5:1.26", when="@1.10") + depends_on("py-numpy@1.18.5:1.25", when="@1.9") + depends_on("py-numpy@1.17.3:1.24", when="@1.8") + depends_on("py-numpy@1.16.5:1.22", when="@1.6:1.7") + depends_on("py-numpy@1.14.5:1.21", when="@1.5") + depends_on("py-numpy@1.13.3:1.21", when="@1.3:1.4") + + # Test dependencies + with default_args(type="test"): + depends_on("py-pytest") + depends_on("py-pooch") + depends_on("py-hypothesis@6.30:") # Required to use --config-settings depends_on("py-pip@23.1:", when="@1.9:", type="build") @@ -108,10 +124,19 @@ class PyScipy(PythonPackage): depends_on("lapack") depends_on("blas") + # Historical dependencies + with default_args(type="build"): + depends_on("meson", when="@1.9.0:1.9.1") + depends_on("py-setuptools", when="@:1.8") + depends_on("py-setuptools@:59", when="@1.8") + depends_on("py-setuptools@:57", when="@1.7") + depends_on("py-setuptools@:51.0.0", when="@1.6") + # meson.build # https://docs.scipy.org/doc/scipy/dev/toolchain.html#compilers conflicts("%gcc@:7", when="@1.10:", msg="SciPy requires GCC >= 8.0") conflicts("%gcc@:4.7", when="@:1.9", msg="SciPy requires GCC >= 4.8") + conflicts("%apple-clang@:9", when="@1.10:", msg="SciPy requires Apple Clang >= 10") conflicts( "%msvc@:19.19", when="@1.10:", @@ -119,6 +144,9 @@ class PyScipy(PythonPackage): "when building with MSVC", ) + # https://github.com/scipy/scipy/issues/19831 + conflicts("^openblas@0.3.26:", when="@:1.12") + # https://github.com/scipy/scipy/issues/19352 conflicts("^py-cython@3.0.3") diff --git a/var/spack/repos/builtin/packages/py-scs/package.py b/var/spack/repos/builtin/packages/py-scs/package.py index e5f2f5e4facda9..4970a55504aa94 100644 --- a/var/spack/repos/builtin/packages/py-scs/package.py +++ b/var/spack/repos/builtin/packages/py-scs/package.py @@ -20,6 +20,8 @@ class PyScs(PythonPackage, CudaPackage): version("3.2.2", sha256="7206a2ad27ca031d693d65cbcbcfc661498f3983838079a66579bcc784b25293") version("2.1.1-2", sha256="f816cfe3d4b4cff3ac2b8b96588c5960ddd2a3dc946bda6b09db04e7bc6577f2") + depends_on("c", type="build") # generated + variant( "float32", default=False, diff --git a/var/spack/repos/builtin/packages/py-seaborn/package.py b/var/spack/repos/builtin/packages/py-seaborn/package.py index 5fbc1cbff38265..49333345d4ed6d 100644 --- a/var/spack/repos/builtin/packages/py-seaborn/package.py +++ b/var/spack/repos/builtin/packages/py-seaborn/package.py @@ -19,6 +19,7 @@ class PySeaborn(PythonPackage): license("BSD-2-Clause") + version("0.13.2", sha256="93e60a40988f4d65e9f4885df477e2fdaff6b73a9ded434c1ab356dd57eefff7") version("0.12.2", sha256="374645f36509d0dcab895cba5b47daf0586f77bfe3b36c97c607db7da5be0139") version("0.12.0", sha256="893f17292d8baca616c1578ddb58eb25c72d622f54fc5ee329c8207dc9b57b23") version("0.11.2", sha256="cf45e9286d40826864be0e3c066f98536982baf701a7caa386511792d61ff4f6") @@ -38,6 +39,8 @@ class PySeaborn(PythonPackage): depends_on("py-numpy@1.15:", when="@0.11:", type=("build", "run")) depends_on("py-numpy@1.9.3:", when="@0.9:", type=("build", "run")) depends_on("py-numpy", type=("build", "run")) + # https://github.com/mwaskom/seaborn/pull/3683 + depends_on("py-numpy@:1", when="@:0.13.1", type=("build", "run")) depends_on("py-pandas@0.25:", when="@0.12:", type=("build", "run")) depends_on("py-pandas@0.23:", when="@0.11:", type=("build", "run")) depends_on("py-pandas@0.22:", when="@0.10:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-sentencepiece/package.py b/var/spack/repos/builtin/packages/py-sentencepiece/package.py index f955d19ccd49bc..2a1fdff88f5a27 100644 --- a/var/spack/repos/builtin/packages/py-sentencepiece/package.py +++ b/var/spack/repos/builtin/packages/py-sentencepiece/package.py @@ -22,6 +22,8 @@ class PySentencepiece(PythonPackage): version("0.1.91", sha256="acbc7ea12713cd2a8d64892f8d2033c7fd2bb4faecab39452496120ace9a4b1b") version("0.1.85", sha256="dd4956287a1b6af3cbdbbd499b7227a859a4e3f41c9882de5e6bdd929e219ae6") + depends_on("cxx", type="build") # generated + depends_on("sentencepiece") depends_on("sentencepiece@0.1.85", when="@0.1.85") depends_on("sentencepiece@0.1.91", when="@0.1.91") diff --git a/var/spack/repos/builtin/packages/py-setproctitle/package.py b/var/spack/repos/builtin/packages/py-setproctitle/package.py index 5d5ffa01d14bda..369d0c58d78ecb 100644 --- a/var/spack/repos/builtin/packages/py-setproctitle/package.py +++ b/var/spack/repos/builtin/packages/py-setproctitle/package.py @@ -17,4 +17,6 @@ class PySetproctitle(PythonPackage): version("1.1.10", sha256="6283b7a58477dd8478fbb9e76defb37968ee4ba47b05ec1c053cb39638bd7398") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-setuptools-rust/package.py b/var/spack/repos/builtin/packages/py-setuptools-rust/package.py index 9be074f7141c4c..f058014ddcf1f5 100644 --- a/var/spack/repos/builtin/packages/py-setuptools-rust/package.py +++ b/var/spack/repos/builtin/packages/py-setuptools-rust/package.py @@ -14,6 +14,9 @@ class PySetuptoolsRust(PythonPackage): license("MIT") + version("1.9.0", sha256="704df0948f2e4cc60c2596ad6e840ea679f4f43e58ed4ad0c1857807240eab96") + version("1.8.1", sha256="94b1dd5d5308b3138d5b933c3a2b55e6d6927d1a22632e509fcea9ddd0f7e486") + version("1.7.0", sha256="c7100999948235a38ae7e555fe199aa66c253dc384b125f5d85473bf81eae3a3") version("1.6.0", sha256="c86e734deac330597998bfbc08da45187e6b27837e23bd91eadb320732392262") version("1.5.1", sha256="0e05e456645d59429cb1021370aede73c0760e9360bbfdaaefb5bced530eb9d7") version("1.4.1", sha256="18ff850831f58ee21d5783825c99fad632da21e47645e9427fd7dec048029e76") @@ -23,12 +26,14 @@ class PySetuptoolsRust(PythonPackage): depends_on("py-setuptools@62.4:", when="@1.4.0:", type=("build", "run")) depends_on("py-setuptools@46.1:", type=("build", "run")) depends_on("py-setuptools", type=("build", "run")) + depends_on("py-setuptools-scm", when="@1.7.0:", type=("build", "run")) depends_on("py-semantic-version@2.8.2:2", when="@1.2.0:", type=("build", "run")) depends_on("py-semantic-version@2.6.0:", type=("build", "run")) - depends_on("py-typing-extensions@3.7.4.3:", when="@1.2.0:", type=("build", "run")) + depends_on("py-tomli@1.2.1:", when="^python@:3.10", type=("build", "run")) depends_on("rust", type="run") # Historical dependencies + depends_on("py-typing-extensions@3.7.4.3:", when="@1.2.0:1.7.0", type=("build", "run")) depends_on("py-setuptools-scm+toml@6.3.2:", when="@1.2.0:1.4.1", type="build") depends_on("py-setuptools-scm+toml@3.4.3:", when="@:1.1", type="build") depends_on("py-toml@0.9.0:", type=("build", "run"), when="@0.12.1") diff --git a/var/spack/repos/builtin/packages/py-setuptools-scm/package.py b/var/spack/repos/builtin/packages/py-setuptools-scm/package.py index b1f5910a4f17aa..f1ee81b5e9ce4a 100644 --- a/var/spack/repos/builtin/packages/py-setuptools-scm/package.py +++ b/var/spack/repos/builtin/packages/py-setuptools-scm/package.py @@ -11,9 +11,11 @@ class PySetuptoolsScm(PythonPackage): homepage = "https://github.com/pypa/setuptools_scm" pypi = "setuptools_scm/setuptools_scm-4.1.2.tar.gz" + tags = ["build-tools"] license("MIT") + version("8.0.4", sha256="b5f43ff6800669595193fd09891564ee9d1d7dcb196cab4b2506d53a2e1c95c7") version("7.1.0", sha256="6c508345a771aad7d56ebff0e70628bf2b0ec7573762be9960214730de278f27") version("7.0.5", sha256="031e13af771d6f892b941adb6ea04545bbf91ebc5ce68c78aaf3fff6e1fb4844") version("7.0.3", sha256="cf8ab8e235bed840cd4559b658af0d8e8a70896a191bbc510ee914ec5325332d") @@ -35,6 +37,7 @@ class PySetuptoolsScm(PythonPackage): depends_on("python@2.7:2.8,3.4:", type=("build", "run")) depends_on("py-packaging@20.0:", when="@6.3:", type=("build", "run")) + depends_on("py-setuptools@61:", when="@8:", type=("build", "run")) depends_on("py-setuptools@45:", when="@6:", type=("build", "run")) depends_on("py-setuptools@42:", when="@5:", type=("build", "run")) depends_on("py-setuptools@34.4:", type=("build", "run")) @@ -46,3 +49,11 @@ class PySetuptoolsScm(PythonPackage): depends_on("py-importlib-metadata", when="@7: ^python@:3.7", type=("build", "run")) depends_on("git", type=("build", "run")) + + def url_for_version(self, version): + # setuptools_scm-7.1.0.tar.gz with an underscore became + # setuptools-scm-8.0.4.tar.gz with a dash + url = super().url_for_version(version) + if version >= Version(8): + return url.replace("_", "-") + return url diff --git a/var/spack/repos/builtin/packages/py-setuptools/package.py b/var/spack/repos/builtin/packages/py-setuptools/package.py index 8d2ab500e95cbf..d6d34ef12a14c4 100644 --- a/var/spack/repos/builtin/packages/py-setuptools/package.py +++ b/var/spack/repos/builtin/packages/py-setuptools/package.py @@ -18,201 +18,45 @@ class PySetuptools(PythonPackage): # Requires railroad skip_modules = ["setuptools._vendor", "pkg_resources._vendor"] - version( - "69.2.0", - sha256="c21c49fb1042386df081cb5d86759792ab89efca84cf114889191cd09aacc80c", - expand=False, - ) - version( - "69.1.1", - sha256="02fa291a0471b3a18b2b2481ed902af520c69e8ae0919c13da936542754b4c56", - expand=False, - ) - version( - "69.0.3", - sha256="385eb4edd9c9d5c17540511303e39a147ce2fc04bc55289c322b9e5904fe2c05", - expand=False, - ) - version( - "68.2.2", - sha256="b454a35605876da60632df1a60f736524eb73cc47bbc9f3f1ef1b644de74fd2a", - expand=False, - ) - version( - "68.0.0", - sha256="11e52c67415a381d10d6b462ced9cfb97066179f0e871399e006c4ab101fc85f", - expand=False, - ) - version( - "67.6.0", - sha256="b78aaa36f6b90a074c1fa651168723acbf45d14cb1196b6f02c0fd07f17623b2", - expand=False, - ) - version( - "65.5.0", - sha256="f62ea9da9ed6289bfe868cd6845968a2c854d1427f8548d52cae02a42b4f0356", - expand=False, - ) - version( - "65.0.0", - sha256="fe9a97f68b064a6ddd4bacfb0b4b93a4c65a556d97ce906255540439d0c35cef", - expand=False, - ) - version( - "64.0.0", - sha256="63f463b90ff5e0a1422010100268fd688e15c44ae0798659013c8412963e15e4", - expand=False, - ) - version( - "63.4.3", - sha256="7f61f7e82647f77d4118eeaf43d64cbcd4d87e38af9611694d4866eb070cd10d", - expand=False, - ) - version( - "63.0.0", - sha256="045aec56a3eee5c82373a70e02db8b6da9a10f7faf61ff89a14ab66c738ed370", - expand=False, - ) - version( - "62.6.0", - sha256="c1848f654aea2e3526d17fc3ce6aeaa5e7e24e66e645b5be2171f3f6b4e5a178", - expand=False, - ) - version( - "62.4.0", - sha256="5a844ad6e190dccc67d6d7411d119c5152ce01f7c76be4d8a1eaa314501bba77", - expand=False, - ) - version( - "62.3.2", - sha256="68e45d17c9281ba25dc0104eadd2647172b3472d9e01f911efa57965e8d51a36", - expand=False, - ) - version( - "59.4.0", - sha256="feb5ff19b354cde9efd2344ef6d5e79880ce4be643037641b49508bbb850d060", - expand=False, - ) - version( - "58.2.0", - sha256="2551203ae6955b9876741a26ab3e767bb3242dafe86a32a749ea0d78b6792f11", - expand=False, - ) - version( - "57.4.0", - sha256="a49230977aa6cfb9d933614d2f7b79036e9945c4cdd7583163f4e920b83418d6", - expand=False, - ) - version( - "57.1.0", - sha256="ddae4c1b9220daf1e32ba9d4e3714df6019c5b583755559be84ff8199f7e1fe3", - expand=False, - ) - version( - "51.0.0", - sha256="8c177936215945c9a37ef809ada0fab365191952f7a123618432bbfac353c529", - expand=False, - ) - version( - "50.3.2", - sha256="2c242a0856fbad7efbe560df4a7add9324f340cf48df43651e9604924466794a", - expand=False, - ) - version( - "50.1.0", - sha256="4537c77e6e7dc170081f8547564551d4ff4e4999717434e1257600bbd3a23296", - expand=False, - ) - version( - "49.6.0", - sha256="4dd5bb0a0a0cff77b46ca5dd3a84857ee48c83e8223886b556613c724994073f", - expand=False, - ) - version( - "49.2.0", - sha256="272c7f48f5cddc5af5901f4265274c421c7eede5c8bc454ac2903d3f8fc365e9", - expand=False, - ) - version( - "46.1.3", - sha256="4fe404eec2738c20ab5841fa2d791902d2a645f32318a7850ef26f8d7215a8ee", - expand=False, - ) - version( - "44.1.1", - sha256="27a714c09253134e60a6fa68130f78c7037e5562c4f21f8f318f2ae900d152d5", - expand=False, - ) - version( - "44.1.0", - sha256="992728077ca19db6598072414fb83e0a284aca1253aaf2e24bb1e55ee6db1a30", - expand=False, - ) - version( - "43.0.0", - sha256="a67faa51519ef28cd8261aff0e221b6e4c370f8fb8bada8aa3e7ad8945199963", - expand=False, - ) - version( - "41.4.0", - sha256="8d01f7ee4191d9fdcd9cc5796f75199deccb25b154eba82d44d6a042cf873670", - expand=False, - ) - version( - "41.3.0", - sha256="e9832acd9be6f3174f4c34b40e7d913a146727920cbef6465c1c1bd2d21a4ec4", - expand=False, - ) - version( - "41.0.1", - sha256="c7769ce668c7a333d84e17fe8b524b1c45e7ee9f7908ad0a73e1eda7e6a5aebf", - expand=False, - ) - version( - "41.0.0", - sha256="e67486071cd5cdeba783bd0b64f5f30784ff855b35071c8670551fd7fc52d4a1", - expand=False, - ) - version( - "40.8.0", - sha256="e8496c0079f3ac30052ffe69b679bd876c5265686127a3159cfa415669b7f9ab", - expand=False, - ) - version( - "40.4.3", - sha256="ce4137d58b444bac11a31d4e0c1805c69d89e8ed4e91fde1999674ecc2f6f9ff", - expand=False, - ) - version( - "40.2.0", - sha256="ea3796a48a207b46ea36a9d26de4d0cc87c953a683a7b314ea65d666930ea8e6", - expand=False, - ) - version( - "39.2.0", - sha256="8fca9275c89964f13da985c3656cb00ba029d7f3916b37990927ffdf264e7926", - expand=False, - ) - version( - "39.0.1", - sha256="8010754433e3211b9cdbbf784b50f30e80bf40fc6b05eb5f865fab83300599b8", - expand=False, - ) - version( - "25.2.0", - sha256="2845247c359bb91097ccf8f6be8a69edfa44847f3d2d5def39aa43c3d7f615ca", - expand=False, - ) - version( - "20.7.0", - sha256="8917a52aa3a389893221b173a89dae0471022d32bff3ebc31a1072988aa8039d", - expand=False, - ) - version( - "20.6.7", - sha256="9982ee4d279a2541dc1a7efee994ff9c535cfc05315e121e09df7f93da48c442", - expand=False, - ) + version("69.2.0", sha256="c21c49fb1042386df081cb5d86759792ab89efca84cf114889191cd09aacc80c") + version("69.1.1", sha256="02fa291a0471b3a18b2b2481ed902af520c69e8ae0919c13da936542754b4c56") + version("69.0.3", sha256="385eb4edd9c9d5c17540511303e39a147ce2fc04bc55289c322b9e5904fe2c05") + version("68.2.2", sha256="b454a35605876da60632df1a60f736524eb73cc47bbc9f3f1ef1b644de74fd2a") + version("68.0.0", sha256="11e52c67415a381d10d6b462ced9cfb97066179f0e871399e006c4ab101fc85f") + version("67.6.0", sha256="b78aaa36f6b90a074c1fa651168723acbf45d14cb1196b6f02c0fd07f17623b2") + version("65.5.0", sha256="f62ea9da9ed6289bfe868cd6845968a2c854d1427f8548d52cae02a42b4f0356") + version("65.0.0", sha256="fe9a97f68b064a6ddd4bacfb0b4b93a4c65a556d97ce906255540439d0c35cef") + version("64.0.0", sha256="63f463b90ff5e0a1422010100268fd688e15c44ae0798659013c8412963e15e4") + version("63.4.3", sha256="7f61f7e82647f77d4118eeaf43d64cbcd4d87e38af9611694d4866eb070cd10d") + version("63.0.0", sha256="045aec56a3eee5c82373a70e02db8b6da9a10f7faf61ff89a14ab66c738ed370") + version("62.6.0", sha256="c1848f654aea2e3526d17fc3ce6aeaa5e7e24e66e645b5be2171f3f6b4e5a178") + version("62.4.0", sha256="5a844ad6e190dccc67d6d7411d119c5152ce01f7c76be4d8a1eaa314501bba77") + version("62.3.2", sha256="68e45d17c9281ba25dc0104eadd2647172b3472d9e01f911efa57965e8d51a36") + version("59.4.0", sha256="feb5ff19b354cde9efd2344ef6d5e79880ce4be643037641b49508bbb850d060") + version("58.2.0", sha256="2551203ae6955b9876741a26ab3e767bb3242dafe86a32a749ea0d78b6792f11") + version("57.4.0", sha256="a49230977aa6cfb9d933614d2f7b79036e9945c4cdd7583163f4e920b83418d6") + version("57.1.0", sha256="ddae4c1b9220daf1e32ba9d4e3714df6019c5b583755559be84ff8199f7e1fe3") + version("51.0.0", sha256="8c177936215945c9a37ef809ada0fab365191952f7a123618432bbfac353c529") + version("50.3.2", sha256="2c242a0856fbad7efbe560df4a7add9324f340cf48df43651e9604924466794a") + version("50.1.0", sha256="4537c77e6e7dc170081f8547564551d4ff4e4999717434e1257600bbd3a23296") + version("49.6.0", sha256="4dd5bb0a0a0cff77b46ca5dd3a84857ee48c83e8223886b556613c724994073f") + version("49.2.0", sha256="272c7f48f5cddc5af5901f4265274c421c7eede5c8bc454ac2903d3f8fc365e9") + version("46.1.3", sha256="4fe404eec2738c20ab5841fa2d791902d2a645f32318a7850ef26f8d7215a8ee") + version("44.1.1", sha256="27a714c09253134e60a6fa68130f78c7037e5562c4f21f8f318f2ae900d152d5") + version("44.1.0", sha256="992728077ca19db6598072414fb83e0a284aca1253aaf2e24bb1e55ee6db1a30") + version("43.0.0", sha256="a67faa51519ef28cd8261aff0e221b6e4c370f8fb8bada8aa3e7ad8945199963") + version("41.4.0", sha256="8d01f7ee4191d9fdcd9cc5796f75199deccb25b154eba82d44d6a042cf873670") + version("41.3.0", sha256="e9832acd9be6f3174f4c34b40e7d913a146727920cbef6465c1c1bd2d21a4ec4") + version("41.0.1", sha256="c7769ce668c7a333d84e17fe8b524b1c45e7ee9f7908ad0a73e1eda7e6a5aebf") + version("41.0.0", sha256="e67486071cd5cdeba783bd0b64f5f30784ff855b35071c8670551fd7fc52d4a1") + version("40.8.0", sha256="e8496c0079f3ac30052ffe69b679bd876c5265686127a3159cfa415669b7f9ab") + version("40.4.3", sha256="ce4137d58b444bac11a31d4e0c1805c69d89e8ed4e91fde1999674ecc2f6f9ff") + version("40.2.0", sha256="ea3796a48a207b46ea36a9d26de4d0cc87c953a683a7b314ea65d666930ea8e6") + version("39.2.0", sha256="8fca9275c89964f13da985c3656cb00ba029d7f3916b37990927ffdf264e7926") + version("39.0.1", sha256="8010754433e3211b9cdbbf784b50f30e80bf40fc6b05eb5f865fab83300599b8") + version("25.2.0", sha256="2845247c359bb91097ccf8f6be8a69edfa44847f3d2d5def39aa43c3d7f615ca") + version("20.7.0", sha256="8917a52aa3a389893221b173a89dae0471022d32bff3ebc31a1072988aa8039d") + version("20.6.7", sha256="9982ee4d279a2541dc1a7efee994ff9c535cfc05315e121e09df7f93da48c442") extends("python") diff --git a/var/spack/repos/builtin/packages/py-sfepy/package.py b/var/spack/repos/builtin/packages/py-sfepy/package.py index 93d2812d70ed16..da0ced6e3a9e5d 100644 --- a/var/spack/repos/builtin/packages/py-sfepy/package.py +++ b/var/spack/repos/builtin/packages/py-sfepy/package.py @@ -21,6 +21,8 @@ class PySfepy(PythonPackage): version("2021.3", sha256="b2a760b0f3277ac223ff25821a4156b48d06b3769e6a9a3bd0bffef5a43cbe17") + depends_on("c", type="build") # generated + variant("petsc", default=False, description="Enable PETSc support") variant("slepc", default=False, description="Enable SLEPc support") variant("pyamg", default=False, description="Enable PyAMG support") diff --git a/var/spack/repos/builtin/packages/py-shap/package.py b/var/spack/repos/builtin/packages/py-shap/package.py index 6c6bf451103f47..859a6640f4d22a 100644 --- a/var/spack/repos/builtin/packages/py-shap/package.py +++ b/var/spack/repos/builtin/packages/py-shap/package.py @@ -17,6 +17,8 @@ class PyShap(PythonPackage): version("0.41.0", sha256="a49ea4d65aadbc845a695fa3d7ea0bdfc8c928b8e213b0feedf5868ade4b3ca5") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-shapely/package.py b/var/spack/repos/builtin/packages/py-shapely/package.py index eedffbf9b4d096..33c75a934e2844 100644 --- a/var/spack/repos/builtin/packages/py-shapely/package.py +++ b/var/spack/repos/builtin/packages/py-shapely/package.py @@ -21,6 +21,8 @@ class PyShapely(PythonPackage): license("BSD-3-Clause") version("main", branch="main") + version("2.0.5", sha256="bff2366bc786bfa6cb353d6b47d0443c570c32776612e527ee47b6df63fcfe32") + version("2.0.4", sha256="5dc736127fac70009b8d309a0eeb74f3e08979e530cf7017f2f507ef62e6cfb8") version("2.0.3", sha256="4d65d0aa7910af71efa72fd6447e02a8e5dd44da81a983de9d736d6e6ccbe674") version("2.0.2", sha256="1713cc04c171baffc5b259ba8531c58acc2a301707b7f021d88a15ed090649e7") version("2.0.1", sha256="66a6b1a3e72ece97fc85536a281476f9b7794de2e646ca8a4517e2e3c1446893") @@ -35,13 +37,17 @@ class PyShapely(PythonPackage): version("1.7.0", sha256="e21a9fe1a416463ff11ae037766fe410526c95700b9e545372475d2361cc951e") version("1.6.4", sha256="b10bc4199cfefcf1c0e5d932eac89369550320ca4bdf40559328d85f1ca4f655") + depends_on("c", type="build") # generated + # pyproject.toml depends_on("py-cython", when="@2.0.2:", type="build") depends_on("py-cython@0.29:0", when="@2.0.0:2.0.1", type="build") depends_on("py-cython@0.29.24:2", when="@:1", type="build") depends_on("py-setuptools@61:", when="@2:", type="build") depends_on("py-setuptools@:63", when="@:1", type="build") - depends_on("py-numpy@1.14:1", when="@2:", type=("build", "link", "run")) + depends_on("py-numpy@1.14:2", when="@2.0.4:", type=("build", "link", "run")) + # https://github.com/shapely/shapely/issues/1972 + depends_on("py-numpy@1.14:1", when="@2.0.0:2.0.3", type=("build", "link", "run")) depends_on("py-numpy@:1", when="@1", type=("build", "link", "run")) depends_on("py-pytest", type="test") depends_on("py-pytest-cov", type="test") diff --git a/var/spack/repos/builtin/packages/py-shiboken/package.py b/var/spack/repos/builtin/packages/py-shiboken/package.py index d8faeac4b76648..0899a10a353624 100644 --- a/var/spack/repos/builtin/packages/py-shiboken/package.py +++ b/var/spack/repos/builtin/packages/py-shiboken/package.py @@ -16,6 +16,8 @@ class PyShiboken(PythonPackage): version("1.2.2", sha256="0baee03c6244ab56e42e4200d0cb5e234682b11cc296ed0a192fe457d054972f") + depends_on("cxx", type="build") # generated + depends_on("cmake@2.6:", type="build") # to prevent error: 'PyTypeObject' {aka 'struct _typeobject'} has no member diff --git a/var/spack/repos/builtin/packages/py-shiboken2/package.py b/var/spack/repos/builtin/packages/py-shiboken2/package.py index c29d1dc8497440..fa90c0b61aba58 100644 --- a/var/spack/repos/builtin/packages/py-shiboken2/package.py +++ b/var/spack/repos/builtin/packages/py-shiboken2/package.py @@ -13,19 +13,19 @@ class PyShiboken2(PythonPackage): homepage = "https://www.pyside.org/" + skip_version_audit = ["platform=windows"] + if sys.platform.startswith("linux"): version( "5.15.2", url="https://files.pythonhosted.org/packages/cp35.cp36.cp37.cp38.cp39/s/shiboken2/shiboken2-5.15.2-5.15.2-cp35.cp36.cp37.cp38.cp39-abi3-manylinux1_x86_64.whl", sha256="4aee1b91e339578f9831e824ce2a1ec3ba3a463f41fda8946b4547c7eb3cba86", - expand=False, ) elif sys.platform == "darwin": version( "5.15.2", url="https://files.pythonhosted.org/packages/cp35.cp36.cp37.cp38.cp39/s/shiboken2/shiboken2-5.15.2-5.15.2-cp35.cp36.cp37.cp38.cp39-abi3-macosx_10_13_intel.whl", sha256="edc12a4df2b5be7ca1e762ab94e331ba9e2fbfe3932c20378d8aa3f73f90e0af", - expand=False, ) depends_on("python@3.5:3.9", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-shroud/package.py b/var/spack/repos/builtin/packages/py-shroud/package.py index 1a6c64d9627f75..ca5b7a838c5c97 100644 --- a/var/spack/repos/builtin/packages/py-shroud/package.py +++ b/var/spack/repos/builtin/packages/py-shroud/package.py @@ -24,5 +24,9 @@ class PyShroud(PythonPackage): version("0.9.0", tag="v0.9.0", commit="94aa2831290d10b604df16cb87ee17aa722fb998") version("0.8.0", tag="v0.8.0", commit="b58ac35f41514428d08849a578c45ad444bfddc9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("py-setuptools", type=("build", "run")) depends_on("py-pyyaml@4.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-simpleeval/package.py b/var/spack/repos/builtin/packages/py-simpleeval/package.py index 2d9a46e35c8f03..caa620b525782f 100644 --- a/var/spack/repos/builtin/packages/py-simpleeval/package.py +++ b/var/spack/repos/builtin/packages/py-simpleeval/package.py @@ -16,7 +16,8 @@ class PySimpleeval(PythonPackage): license("MIT") + version("0.9.13", sha256="4a30f9cc01825fe4c719c785e3762623e350c4840d5e6855c2a8496baaa65fac") version("0.9.12", sha256="3e0be507486d4e21cf9d08847c7e57dd61a1603950399985f7c5a0be7fd33e36") depends_on("py-setuptools@30.3.0:", type="build") - depends_on("py-build", type="build") + depends_on("py-build", type="build", when="@:0.9.12") diff --git a/var/spack/repos/builtin/packages/py-simplejson/package.py b/var/spack/repos/builtin/packages/py-simplejson/package.py index dcac15ee93f8bf..63b35bae3e994a 100644 --- a/var/spack/repos/builtin/packages/py-simplejson/package.py +++ b/var/spack/repos/builtin/packages/py-simplejson/package.py @@ -31,4 +31,6 @@ class PySimplejson(PythonPackage): version("3.8.0", sha256="217e4797da3a9a4a9fbe6722e0db98070b8443a88212d7acdbd241a7668141d9") version("3.3.0", sha256="7a8a6bd82e111976aeb06138316ab10847adf612925072eaff8512228bcf9a1f") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-simpletraj/package.py b/var/spack/repos/builtin/packages/py-simpletraj/package.py index 8a9310196ad613..a3b5430203032a 100644 --- a/var/spack/repos/builtin/packages/py-simpletraj/package.py +++ b/var/spack/repos/builtin/packages/py-simpletraj/package.py @@ -17,6 +17,8 @@ class PySimpletraj(PythonPackage): # Versions version("0.5", sha256="860ccba82e7a6085ef1cbff74eb2db53df65fd58edabae3c45b8c45a219b8a3b") + depends_on("c", type="build") # generated + # Dependencies depends_on("py-setuptools", type="build") depends_on("python@3.8:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-simpy/package.py b/var/spack/repos/builtin/packages/py-simpy/package.py new file mode 100644 index 00000000000000..03213f022d4518 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-simpy/package.py @@ -0,0 +1,21 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PySimpy(PythonPackage): + """SimPy is a process-based discrete-event simulation framework based on standard Python.""" + + homepage = "https://simpy.readthedocs.io/" + pypi = "simpy/simpy-4.0.2.tar.gz" + + version("4.1.1", sha256="06d0750a7884b11e0e8e20ce0bc7c6d4ed5f1743d456695340d13fdff95001a6") + version("4.0.2", sha256="6d8adc0229df6b02fb7e26dcd1338703b4f4f63f167a5ac2a7213cb80aba4484") + + depends_on("py-setuptools@42:", type="build", when="@4.0.2") + depends_on("py-setuptools@64:", type="build", when="@4.1.1:") + depends_on("py-setuptools-scm@3.4:+toml", type="build", when="@4.0.2") + depends_on("py-setuptools-scm@8.0:+toml", type="build", when="@4.1.1:") diff --git a/var/spack/repos/builtin/packages/py-sip/package.py b/var/spack/repos/builtin/packages/py-sip/package.py index 966f8766fbcd68..703fce900c1ff9 100644 --- a/var/spack/repos/builtin/packages/py-sip/package.py +++ b/var/spack/repos/builtin/packages/py-sip/package.py @@ -16,6 +16,7 @@ class PySip(PythonPackage): license("GPL-2.0-or-later") + version("6.8.5", sha256="5dddd5966e9875d89ecde9d3e6ac63225f9972e4d25c09e20fa22f1819409c70") version("6.7.9", sha256="35d51fc10f599d3696abb50f29d068ad04763df7b77808c76b74597660f99b17") version("6.6.2", sha256="0e3efac1c5dfd8e525ae57140927df26993e13f58b89d1577c314f4105bfd90d") version("6.4.0", sha256="42ec368520b8da4a0987218510b1b520b4981e4405086c1be384733affc2bcb0") @@ -28,6 +29,8 @@ class PySip(PythonPackage): version("4.19.15", sha256="02bff1ac89253e12cdf1406ad39f841d0e264b0d96a7de13dfe9e29740df2053") version("4.19.13", sha256="92193fcf990503bf29f03e290efc4ee1812d556efc18acf5c8b88c090177a630") + depends_on("c", type="build") # generated + variant( "module", default="sip", @@ -37,14 +40,16 @@ class PySip(PythonPackage): multi=False, ) - depends_on("py-ply", when="@6.6:", type=("build", "run")) + depends_on("py-ply", type=("build", "run"), when="@6.6:") with when("@5:"): depends_on("python", type=("build", "link", "run")) depends_on("py-packaging", type=("build", "run")) - depends_on("py-setuptools@30.3:", type=("build", "run")) - depends_on("py-tomli", when="@6.7: ^python@:3.10", type=("build", "run")) - depends_on("py-toml", when="@:6.6", type=("build", "run")) + depends_on("py-setuptools@64:", type=("build", "run"), when="@6.8.4:") + depends_on("py-setuptools@30.3:", type=("build", "run"), when="@:6.8.3") + depends_on("py-setuptools-scm@8:", type="build", when="@6.8.4:") + depends_on("py-tomli", type=("build", "run"), when="@6.7: ^python@:3.10") + depends_on("py-toml", type=("build", "run"), when="@:6.6") with when("@:4"): # Requires distutils diff --git a/var/spack/repos/builtin/packages/py-slepc4py/package.py b/var/spack/repos/builtin/packages/py-slepc4py/package.py index 91763a868876e5..59fd8fc378a727 100644 --- a/var/spack/repos/builtin/packages/py-slepc4py/package.py +++ b/var/spack/repos/builtin/packages/py-slepc4py/package.py @@ -18,6 +18,7 @@ class PySlepc4py(PythonPackage): license("BSD-2-Clause") version("main", branch="main") + version("3.21.0", sha256="bfbd90162633486f67a448d2052e1f7182529d18e8bde87367bc4f4dd58e857f") version("3.20.2", sha256="89ebd1964edd0eb63d4dbfa977d6f35408f4e19a3da290696fd1197901544bd8") version("3.20.1", sha256="7e6d156f7b0891bfa0616b38a502460c62797f16ca146b321e16cce4cf139d07") version("3.20.0", sha256="56cbea1f56746136e5a934bf4a481e566f35e475cb950c0a5bce7d5c3cc7690a") @@ -51,12 +52,12 @@ class PySlepc4py(PythonPackage): depends_on("py-petsc4py", type=("build", "run")) depends_on("py-petsc4py@main", when="@main", type=("build", "run")) - for ver in ["3.20", "3.19", "3.18", "3.17", "3.16", "3.15", "3.13", "3.12", "3.11"]: + for ver in ["3.21", "3.20", "3.19", "3.18", "3.17", "3.16", "3.15", "3.13", "3.12", "3.11"]: depends_on(f"py-petsc4py@{ver}", when=f"@{ver}", type=("build", "run")) depends_on("slepc") depends_on("slepc@main", when="@main") - for ver in ["3.20", "3.19", "3.18", "3.17", "3.16", "3.15", "3.13", "3.12", "3.11"]: + for ver in ["3.21", "3.20", "3.19", "3.18", "3.17", "3.16", "3.15", "3.13", "3.12", "3.11"]: depends_on(f"slepc@{ver}", when=f"@{ver}") @property diff --git a/var/spack/repos/builtin/packages/py-smartredis/package.py b/var/spack/repos/builtin/packages/py-smartredis/package.py index f45b38572c4c88..b1a6186499e29f 100644 --- a/var/spack/repos/builtin/packages/py-smartredis/package.py +++ b/var/spack/repos/builtin/packages/py-smartredis/package.py @@ -20,6 +20,9 @@ class PySmartredis(PythonPackage): version("0.4.1", sha256="fff16ed1eb09648ac3c3f845373beb37f3ffe7414d8745ae36af9daf585f8c5b") version("0.4.0", sha256="d12779aa8bb038e837c25eac41b178aab9e16b729d50ee360b5af8f813d9f1dd") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("python@3.7:3.10", type=("build", "run")) depends_on("py-setuptools@42:", type=("build",)) diff --git a/var/spack/repos/builtin/packages/py-smartsim/package.py b/var/spack/repos/builtin/packages/py-smartsim/package.py index 8014fe9da11b35..482b71c983491d 100644 --- a/var/spack/repos/builtin/packages/py-smartsim/package.py +++ b/var/spack/repos/builtin/packages/py-smartsim/package.py @@ -27,7 +27,7 @@ class PySmartsim(PythonPackage): depends_on("python@3.8:3.10", type=("build", "run")) depends_on("py-setuptools@39.2:", type=("build",)) - depends_on("py-cmake@3.13:", type=("build",)) + depends_on("cmake@3.13:", type=("build",)) depends_on("py-psutil@5.7.2:", type=("build", "run")) depends_on("py-coloredlogs@10:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-sncosmo/package.py b/var/spack/repos/builtin/packages/py-sncosmo/package.py index 802be084b43807..7dfe7ce2f8112c 100644 --- a/var/spack/repos/builtin/packages/py-sncosmo/package.py +++ b/var/spack/repos/builtin/packages/py-sncosmo/package.py @@ -17,6 +17,8 @@ class PySncosmo(PythonPackage): version("1.2.0", sha256="f3969eec5b25f60c70418dbd64765a2b4735bb53c210c61d0aab68916daea588") + depends_on("c", type="build") # generated + # Required dependencies depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-sonlib/package.py b/var/spack/repos/builtin/packages/py-sonlib/package.py index 73c2457b61f1f1..1095819687ab4c 100644 --- a/var/spack/repos/builtin/packages/py-sonlib/package.py +++ b/var/spack/repos/builtin/packages/py-sonlib/package.py @@ -27,4 +27,7 @@ class PySonlib(PythonPackage): version("devel", branch="master") version("20200401", commit="7ebe2ede05a6ee366d93a7a993db69a99943a68f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-spacy/package.py b/var/spack/repos/builtin/packages/py-spacy/package.py index d0c4badc8ba53c..cf4620953b4961 100644 --- a/var/spack/repos/builtin/packages/py-spacy/package.py +++ b/var/spack/repos/builtin/packages/py-spacy/package.py @@ -20,6 +20,8 @@ class PySpacy(PythonPackage): version("2.3.2", sha256="818de26e0e383f64ccbe3db185574920de05923d8deac8bbb12113b9e33cee1f") version("2.2.4", sha256="f0f3a67c5841e6e35d62c98f40ebb3d132587d3aba4f4dccac5056c4e90ff5b9") + depends_on("cxx", type="build") # generated + depends_on("python@2.7:2.8,3.4:", type=("build", "run"), when="@2.2.4:2.2") depends_on("python@2.7:2.8,3.5:", type=("build", "run"), when="@2.3.0:") depends_on("py-cython@0.25:", type="build") diff --git a/var/spack/repos/builtin/packages/py-spdlog/package.py b/var/spack/repos/builtin/packages/py-spdlog/package.py index ec4282228631b8..79204b0381d8a9 100644 --- a/var/spack/repos/builtin/packages/py-spdlog/package.py +++ b/var/spack/repos/builtin/packages/py-spdlog/package.py @@ -24,6 +24,8 @@ class PySpdlog(PythonPackage): version("master", branch="master", submodules=True) version("2.0.0", sha256="b8d3732839850da414a47e91547ee1246f0690cb83f43f11a1fbaec40b7b968c") + depends_on("cxx", type="build") # generated + depends_on("py-pybind11@2.2:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-pytest-runner", type="build") diff --git a/var/spack/repos/builtin/packages/py-spglib/package.py b/var/spack/repos/builtin/packages/py-spglib/package.py index eb65819c927b18..dda1f57ecadbf5 100644 --- a/var/spack/repos/builtin/packages/py-spglib/package.py +++ b/var/spack/repos/builtin/packages/py-spglib/package.py @@ -20,5 +20,9 @@ class PySpglib(PythonPackage): version("1.16.1", sha256="9fd2fefbd83993b135877a69c498d8ddcf20a9980562b65b800cfb4cdadad003") version("1.9.9.18", sha256="cbbb8383320b500dc6100b83d5e914a26a97ef8fc97c82d8921b10220e4126cd") + depends_on("c", type="build") # generated + depends_on("py-setuptools@18.0:", type="build") depends_on("py-numpy", type=("build", "run")) + # https://github.com/spglib/spglib/issues/407 + depends_on("py-numpy@:1", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-sphinx-immaterial/package.py b/var/spack/repos/builtin/packages/py-sphinx-immaterial/package.py index a198b6ada8d040..be4781dd11f840 100644 --- a/var/spack/repos/builtin/packages/py-sphinx-immaterial/package.py +++ b/var/spack/repos/builtin/packages/py-sphinx-immaterial/package.py @@ -16,6 +16,8 @@ class PySphinxImmaterial(PythonPackage): version("0.11.2", sha256="a1c8387ca8b4da282949e474647d06f3b2f7d12fe54e9e662b962771012bf257") + depends_on("cxx", type="build") # generated + depends_on("python@3.8:", type=("build", "run")) depends_on("py-setuptools@42:", type="build") depends_on("py-setuptools-scm@6.3.2:", type="build") diff --git a/var/spack/repos/builtin/packages/py-sphinx/package.py b/var/spack/repos/builtin/packages/py-sphinx/package.py index 2e5f84e0d4b116..450f56fa2221fa 100644 --- a/var/spack/repos/builtin/packages/py-sphinx/package.py +++ b/var/spack/repos/builtin/packages/py-sphinx/package.py @@ -16,6 +16,20 @@ class PySphinx(PythonPackage): license("BSD-2-Clause") + version("7.4.5", sha256="a4abe5385bf856df094c1e6cadf24a2351b12057be3670b99a12c05a01d209f5") + version("7.4.4", sha256="43c911f997a4530b6cffd4ff8d5516591f6c60d178591f4406f0dd02282e3f64") + version("7.4.3", sha256="bd846bcb09fd2b6e94ce3e1ad50f4618bccf03cc7c17d0f3fa87393c0bd9178b") + version("7.4.2", sha256="946f1a6fa317b02f76deee78392ba712badc01cccd231b5995d933ae3365a151") + version("7.4.1", sha256="09539a16d74d1850b123cdd0752b9d24f3adc025ff887d611d1010348cd3648c") + version("7.4.0", sha256="8385520a28dc129ebf8b5fccfa1beb71215fd4455c6d10fa418e08c3c7a2ff9c") + version("7.3.7", sha256="a4a7db75ed37531c05002d56ed6948d4c42f473a36f46e1382b0bd76ca9627bc") + version("7.3.6", sha256="fc9f3d13fed5c9a0e677d368090e209899ce5d0081eb552b657e2923e57517f0") + version("7.3.5", sha256="30d03bbaa53b77d38863fd6b95cc4edb4a84a1512787b3b0c12fb3b4fb25d9e9") + version("7.3.4", sha256="614826a7cf76f0a4525875c3ed55e2c3618f906897cb7ad53511c5fedcbb35aa") + version("7.3.3", sha256="1918ba7a7c52f88b5a41ab7e8c55828235994968cfaeb5d10532711e1264087f") + version("7.3.2", sha256="404a4610689936c2259711e9927174489bac500baa398f31f9ab641e42981e9d") + version("7.3.1", sha256="9d9e436f536620e13cea3becf107cd5b2fe65922c9fc24d1945543b6657f3468") + version("7.3.0", sha256="7ad02a0677d43cbaab3f9477355a412e449472d3f4693e2df3842e7ccb7ae7c8") version("7.2.6", sha256="9a5160e1ea90688d5963ba09a2dcd8bdd526620edbb65c328728f1b2228d5ab5") version("7.2.5", sha256="1a9290001b75c497fd087e92b0334f1bbfa1a1ae7fddc084990c4b7bd1130b88") version("7.2.4", sha256="1aeec862bf1edff4374012ac38082e0d1daa066c9e327841a846401164797988") @@ -83,55 +97,69 @@ class PySphinx(PythonPackage): depends_on("py-flit-core@3.7:", when="@5.2:", type="build") - depends_on("python@3.9:", when="@7.2:", type=("build", "run")) - depends_on("python@3.8:", when="@6:", type=("build", "run")) - - depends_on("py-sphinxcontrib-applehelp", when="@2:", type=("build", "run")) - depends_on("py-sphinxcontrib-devhelp", when="@2:", type=("build", "run")) - depends_on("py-sphinxcontrib-jsmath", when="@2:", type=("build", "run")) - depends_on("py-sphinxcontrib-htmlhelp@2:", when="@4.1.1:", type=("build", "run")) - depends_on("py-sphinxcontrib-htmlhelp", when="@2:", type=("build", "run")) - depends_on("py-sphinxcontrib-serializinghtml@1.1.9:", when="@7.2.3:", type=("build", "run")) - depends_on("py-sphinxcontrib-serializinghtml@1.1.5:", when="@4.1.1:", type=("build", "run")) - depends_on("py-sphinxcontrib-serializinghtml", when="@2:", type=("build", "run")) - depends_on("py-sphinxcontrib-qthelp", when="@2:", type=("build", "run")) - depends_on("py-jinja2@3:", when="@5.2:", type=("build", "run")) - depends_on("py-jinja2@2.3:2", when="@:4.0.1", type=("build", "run")) - depends_on("py-jinja2@2.3:", type=("build", "run")) - depends_on("py-pygments@2.14:", when="@7.2:", type=("build", "run")) - depends_on("py-pygments@2.13:", when="@6.0.1:", type=("build", "run")) - depends_on("py-pygments@2.12:", when="@5.2:", type=("build", "run")) - depends_on("py-pygments@2:", type=("build", "run")) - depends_on("py-docutils@0.18.1:0.20", when="@7.0.1:", type=("build", "run")) - depends_on("py-docutils@0.18.1:0.19", when="@6.2:7.0.0", type=("build", "run")) - depends_on("py-docutils@0.18:0.19", when="@6.0:6.1", type=("build", "run")) - depends_on("py-docutils@0.14:0.19", when="@5.1:5", type=("build", "run")) - depends_on("py-docutils@0.14:0.18", when="@5.0", type=("build", "run")) - depends_on("py-docutils@0.14:0.17", when="@4", type=("build", "run")) - depends_on("py-docutils@0.12:0.16", when="@:3", type=("build", "run")) - depends_on("py-snowballstemmer@2:", when="@5.2:", type=("build", "run")) - depends_on("py-snowballstemmer@1.1:", type=("build", "run")) - depends_on("py-babel@2.9:", when="@5.2:", type=("build", "run")) - depends_on("py-babel@1.3:", type=("build", "run")) - depends_on("py-alabaster@0.7", type=("build", "run")) - depends_on("py-imagesize@1.3:", when="@5.2:", type=("build", "run")) - depends_on("py-imagesize", when="@1.4:", type=("build", "run")) - depends_on("py-requests@2.25:", when="@6:", type=("build", "run")) - depends_on("py-requests@2.5:", when="@2:", type=("build", "run")) - depends_on("py-requests@2.4:", when="@1.5.2:", type=("build", "run")) - depends_on("py-packaging@21:", when="@5.2:", type=("build", "run")) - depends_on("py-packaging", when="@1.7:", type=("build", "run")) - depends_on("py-importlib-metadata@4.8:", when="@5.2: ^python@:3.9", type=("build", "run")) - depends_on("py-importlib-metadata@4.4:", when="@4.4: ^python@:3.9", type=("build", "run")) - depends_on("py-colorama@0.4.5:", when="@5.2: platform=windows", type=("build", "run")) - depends_on("py-colorama@0.3.5:", when="platform=windows", type=("build", "run")) + with default_args(type=("build", "run")): + depends_on("python@3.9:", when="@7.2:") + depends_on("python@3.8:", when="@6:") + depends_on("py-sphinxcontrib-applehelp", when="@2:") + depends_on("py-sphinxcontrib-devhelp", when="@2:") + depends_on("py-sphinxcontrib-jsmath", when="@2:") + depends_on("py-sphinxcontrib-htmlhelp@2:", when="@4.1.1:") + depends_on("py-sphinxcontrib-htmlhelp", when="@2:") + depends_on("py-sphinxcontrib-serializinghtml@1.1.9:", when="@7.2.3:") + depends_on("py-sphinxcontrib-serializinghtml@1.1.5:", when="@4.1.1:") + depends_on("py-sphinxcontrib-serializinghtml", when="@2:") + depends_on("py-sphinxcontrib-qthelp", when="@2:") + depends_on("py-jinja2@3.1:", when="@7.4:") + depends_on("py-jinja2@3:", when="@5.2:") + depends_on("py-jinja2@2.3:2", when="@:4.0.1") + depends_on("py-jinja2@2.3:") + depends_on("py-pygments@2.17:", when="@7.4:") + depends_on("py-pygments@2.14:", when="@7.2:") + depends_on("py-pygments@2.13:", when="@6.0.1:") + depends_on("py-pygments@2.12:", when="@5.2:") + depends_on("py-pygments@2:") + depends_on("py-docutils@0.20:0.21", when="@7.4:") + depends_on("py-docutils@0.18.1:0.21", when="@7.3") + depends_on("py-docutils@0.18.1:0.20", when="@7.0.1:7.2") + depends_on("py-docutils@0.18.1:0.19", when="@6.2:7.0.0") + depends_on("py-docutils@0.18:0.19", when="@6.0:6.1") + depends_on("py-docutils@0.14:0.19", when="@5.1:5") + depends_on("py-docutils@0.14:0.18", when="@5.0") + depends_on("py-docutils@0.14:0.17", when="@4") + depends_on("py-docutils@0.12:0.16", when="@:3") + depends_on("py-snowballstemmer@2.2:", when="@7.4:") + depends_on("py-snowballstemmer@2:", when="@5.2:") + depends_on("py-snowballstemmer@1.1:") + depends_on("py-babel@2.13:", when="@7.4:") + depends_on("py-babel@2.9:", when="@5.2:") + depends_on("py-babel@1.3:") + depends_on("py-alabaster@0.7.14:0.7", when="@7.3:") + depends_on("py-alabaster@0.7") + depends_on("py-imagesize@1.3:", when="@5.2:") + depends_on("py-imagesize", when="@1.4:") + depends_on("py-requests@2.30:", when="@7.4:") + depends_on("py-requests@2.25:", when="@6:") + depends_on("py-requests@2.5:", when="@2:") + depends_on("py-requests@2.4:", when="@1.5.2:") + depends_on("py-packaging@23:", when="@7.4:") + depends_on("py-packaging@21:", when="@5.2:") + depends_on("py-packaging", when="@1.7:") + depends_on("py-importlib-metadata@6:", when="@7.4: ^python@:3.9") + depends_on("py-importlib-metadata@4.8:", when="@5.2: ^python@:3.9") + depends_on("py-importlib-metadata@4.4:", when="@4.4: ^python@:3.9") + depends_on("py-tomli@2:", when="@7.3.1: ^python@:3.10") + depends_on("py-colorama@0.4.6:", when="@7.4: platform=windows") + depends_on("py-colorama@0.4.5:", when="@5.2: platform=windows") + depends_on("py-colorama@0.3.5:", when="platform=windows") # Historical dependencies depends_on("py-setuptools", when="@4.4:5.1", type="build") - depends_on("py-setuptools", when="@:4.3", type=("build", "run")) - depends_on("py-sphinxcontrib-websupport", when="@1.6:1", type=("build", "run")) - depends_on("py-six@1.5:", when="@:1", type=("build", "run")) - depends_on("py-sphinx-rtd-theme@0.1:", when="@:1.3", type=("build", "run")) + + with default_args(type=("build", "run")): + depends_on("py-setuptools", when="@:4.3") + depends_on("py-sphinxcontrib-websupport", when="@1.6:1") + depends_on("py-six@1.5:", when="@:1") + depends_on("py-sphinx-rtd-theme@0.1:", when="@:1.3") def url_for_version(self, version): url = "https://files.pythonhosted.org/packages/source/S/Sphinx/{}-{}.tar.gz" diff --git a/var/spack/repos/builtin/packages/py-srsly/package.py b/var/spack/repos/builtin/packages/py-srsly/package.py index d545991b31fb6c..2163eea77442d9 100644 --- a/var/spack/repos/builtin/packages/py-srsly/package.py +++ b/var/spack/repos/builtin/packages/py-srsly/package.py @@ -20,6 +20,9 @@ class PySrsly(PythonPackage): version("2.0.0", sha256="785b00e00406120dbef4ca82925051e6b60fe870c5f84f0d22b3632d574eb870") version("1.0.2", sha256="59258b81d567df207f8a0a33c4b5fa232afccf1d927c8ce3ba5395bfd64c0ed8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.6:", when="@2:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-wheel", when="@2:", type="build") diff --git a/var/spack/repos/builtin/packages/py-statsmodels/package.py b/var/spack/repos/builtin/packages/py-statsmodels/package.py index d4ea3153fc2223..b9d4d55600028d 100644 --- a/var/spack/repos/builtin/packages/py-statsmodels/package.py +++ b/var/spack/repos/builtin/packages/py-statsmodels/package.py @@ -28,6 +28,9 @@ class PyStatsmodels(PythonPackage): version("0.10.2", sha256="9cd2194c6642a8754e85f9a6e6912cdf996bebf6ff715d3cc67f65dadfd37cc9") version("0.10.1", sha256="320659a80f916c2edf9dfbe83512d9004bb562b72eedb7d9374562038697fa10") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("python@3.8:", when="@0.14:", type=("build", "link", "run")) depends_on("python", type=("build", "link", "run")) @@ -51,6 +54,8 @@ class PyStatsmodels(PythonPackage): depends_on("py-numpy@1.17:", when="@0.13:", type=("build", "link", "run")) depends_on("py-numpy@1.15:", when="@0.12.1:", type=("build", "link", "run")) depends_on("py-numpy@1.11:", when="@0.10.1:", type=("build", "link", "run")) + # https://github.com/statsmodels/statsmodels/issues/9194 + depends_on("py-numpy@:1", when="@:0.14.1", type=("build", "link", "run")) depends_on("py-scipy@1.4:", when="@0.13.5:", type=("build", "run")) conflicts("^py-scipy@1.9.2") depends_on("py-scipy@1.3:", when="@0.13:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-storm/package.py b/var/spack/repos/builtin/packages/py-storm/package.py index 1f344b74ace03a..60458f92ebdb89 100644 --- a/var/spack/repos/builtin/packages/py-storm/package.py +++ b/var/spack/repos/builtin/packages/py-storm/package.py @@ -21,6 +21,8 @@ class PyStorm(PythonPackage): url="https://files.pythonhosted.org/packages/source/s/storm/storm-0.23.tar.bz2", ) + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-six", type=("build", "run")) depends_on("py-zope-interface@4:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-stratify/package.py b/var/spack/repos/builtin/packages/py-stratify/package.py index 05fbe674c8eea1..690cb190e1df7c 100644 --- a/var/spack/repos/builtin/packages/py-stratify/package.py +++ b/var/spack/repos/builtin/packages/py-stratify/package.py @@ -19,6 +19,8 @@ class PyStratify(PythonPackage): version("0.1", sha256="5426f3b66e45e1010952d426e5a7be42cd45fe65f1cd73a98fee1eb7c110c6ee") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) depends_on("py-cython", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-stsci-distutils/package.py b/var/spack/repos/builtin/packages/py-stsci-distutils/package.py index a8d3eab8fa1aec..da2fb77f426e13 100644 --- a/var/spack/repos/builtin/packages/py-stsci-distutils/package.py +++ b/var/spack/repos/builtin/packages/py-stsci-distutils/package.py @@ -15,5 +15,7 @@ class PyStsciDistutils(PythonPackage): version("0.3.8", sha256="a52f3ec3b392a9cecd98d143b678c27346cbfa8f34c34698821d7e167907edce") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-d2to1", type="build") diff --git a/var/spack/repos/builtin/packages/py-swagger-spec-validator/package.py b/var/spack/repos/builtin/packages/py-swagger-spec-validator/package.py new file mode 100644 index 00000000000000..86d120d5e0cd02 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-swagger-spec-validator/package.py @@ -0,0 +1,24 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PySwaggerSpecValidator(PythonPackage): + """ + A Python library that validates Swagger Specs against + the Swagger 1.2 or Swagger 2.0 specification. + """ + + homepage = "https://github.com/Yelp/swagger_spec_validator" + pypi = "swagger-spec-validator/swagger-spec-validator-2.7.6.tar.gz" + + version("2.7.6", sha256="73f33e631a58f407265f2f813d194f2762a2b86f9aa905e7eee3df9b7f9428d3") + + depends_on("py-setuptools", type="build") + depends_on("py-jsonschema", type=("build", "run")) + depends_on("py-pyyaml", type=("build", "run")) + depends_on("py-six", type=("build", "run")) + depends_on("py-pyrsistent@:0.16", when="^python@:3.0", type="build") diff --git a/var/spack/repos/builtin/packages/py-symengine/package.py b/var/spack/repos/builtin/packages/py-symengine/package.py index 771264075042e4..074b2264add0c7 100644 --- a/var/spack/repos/builtin/packages/py-symengine/package.py +++ b/var/spack/repos/builtin/packages/py-symengine/package.py @@ -25,6 +25,8 @@ class PySymengine(PythonPackage): ) version("0.2.0", sha256="78a14aea7aad5e7cbfb5cabe141581f9bba30e3c319690e5db8ad99fdf2d8885") + depends_on("cxx", type="build") # generated + # Build dependencies depends_on("python@2.7:2.8,3.3:", type=("build", "run"), when="@0.2.0") depends_on("python@3.6:3", type=("build", "run"), when="@0.8.1:") diff --git a/var/spack/repos/builtin/packages/py-systemd-python/package.py b/var/spack/repos/builtin/packages/py-systemd-python/package.py index b1f01c0dc1e2b3..4130a852e58fbb 100644 --- a/var/spack/repos/builtin/packages/py-systemd-python/package.py +++ b/var/spack/repos/builtin/packages/py-systemd-python/package.py @@ -17,6 +17,8 @@ class PySystemdPython(PythonPackage): version("235", sha256="4e57f39797fd5d9e2d22b8806a252d7c0106c936039d1e71c8c6b8008e695c0a") version("234", sha256="fd0e44bf70eadae45aadc292cb0a7eb5b0b6372cd1b391228047d33895db83e7") + depends_on("c", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/py-tables/package.py b/var/spack/repos/builtin/packages/py-tables/package.py index 262e7e4b82f3b2..e2242acf8cc348 100644 --- a/var/spack/repos/builtin/packages/py-tables/package.py +++ b/var/spack/repos/builtin/packages/py-tables/package.py @@ -27,6 +27,9 @@ class PyTables(PythonPackage): version("3.3.0", sha256="8383ccf02e041a5d55494a09fc5514140b4653055a2732c981b5fd0f7408822c") version("3.2.2", sha256="3564b351a71ec1737b503b001eb7ceae1f65d5d6e3ffe1ea75aafba10f37fa84") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("zlib", default=True, description="Support for zlib compression") variant("bzip2", default=False, description="Support for bzip2 compression") variant("lzo", default=False, description="Support for lzo compression") @@ -45,6 +48,8 @@ class PyTables(PythonPackage): # requirements.txt depends_on("py-numpy@1.19:", when="@3.8:", type=("build", "run")) depends_on("py-numpy@1.9.3:", type=("build", "run")) + # https://github.com/PyTables/PyTables/issues/1083 + depends_on("py-numpy@:1", type=("build", "run")) depends_on("py-numexpr@2.6.2:", type=("build", "run")) depends_on("py-packaging", when="@3.7:", type=("build", "run")) depends_on("py-py-cpuinfo", when="@3.8:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-tabulate/package.py b/var/spack/repos/builtin/packages/py-tabulate/package.py index 07ed086d6401a6..d27fdb52bdc27c 100644 --- a/var/spack/repos/builtin/packages/py-tabulate/package.py +++ b/var/spack/repos/builtin/packages/py-tabulate/package.py @@ -9,11 +9,13 @@ class PyTabulate(PythonPackage): """Pretty-print tabular data""" - homepage = "https://bitbucket.org/astanin/python-tabulate" - pypi = "tabulate/tabulate-0.8.6.tar.gz" + homepage = "https://github.com/astanin/python-tabulate" + pypi = "tabulate/tabulate-0.9.0.tar.gz" license("MIT") + version("0.9.0", sha256="0095b12bf5966de529c0feb1fa08671671b3368eec77d7ef7ab114be2c068b3c") + version("0.8.10", sha256="6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519") version("0.8.9", sha256="eb1d13f25760052e8931f2ef80aaf6045a6cceb47514db8beab24cded16f13a7") version("0.8.7", sha256="db2723a20d04bcda8522165c73eea7c300eda74e0ce852d9022e0159d7895007") version("0.8.6", sha256="5470cc6687a091c7042cee89b2946d9235fe9f6d49c193a4ae2ac7bf386737c8") diff --git a/var/spack/repos/builtin/packages/py-tatsu/package.py b/var/spack/repos/builtin/packages/py-tatsu/package.py index f1a612b2942293..a558d1805b4fd8 100644 --- a/var/spack/repos/builtin/packages/py-tatsu/package.py +++ b/var/spack/repos/builtin/packages/py-tatsu/package.py @@ -24,3 +24,8 @@ class PyTatsu(PythonPackage): depends_on("py-setuptools", type="build") # optional dependency, otherwise falls back to standard implementation depends_on("py-regex@2018.8:", type=("build", "run"), when="+future_regex") + + # <<< manual changes + # https://github.com/neogeny/TatSu/commit/a4fd84a2785fb0820ed65fe80ebd768458643b66 + depends_on("python@:3.9", type=("build", "run"), when="@:4") + # manual changes >>> diff --git a/var/spack/repos/builtin/packages/py-tensorboard-plugin-wit/package.py b/var/spack/repos/builtin/packages/py-tensorboard-plugin-wit/package.py index cb0fd3de571bd8..df82cd896020a4 100644 --- a/var/spack/repos/builtin/packages/py-tensorboard-plugin-wit/package.py +++ b/var/spack/repos/builtin/packages/py-tensorboard-plugin-wit/package.py @@ -25,21 +25,9 @@ class PyTensorboardPluginWit(PythonPackage): license("Apache-2.0") - version( - "1.8.1", - sha256="ff26bdd583d155aa951ee3b152b3d0cffae8005dc697f72b44a8e8c2a77a8cbe", - expand=False, - ) - version( - "1.8.0", - sha256="2a80d1c551d741e99b2f197bb915d8a133e24adb8da1732b840041860f91183a", - expand=False, - ) - version( - "1.7.0", - sha256="ee775f04821185c90d9a0e9c56970ee43d7c41403beb6629385b39517129685b", - expand=False, - ) + version("1.8.1", sha256="ff26bdd583d155aa951ee3b152b3d0cffae8005dc697f72b44a8e8c2a77a8cbe") + version("1.8.0", sha256="2a80d1c551d741e99b2f197bb915d8a133e24adb8da1732b840041860f91183a") + version("1.7.0", sha256="ee775f04821185c90d9a0e9c56970ee43d7c41403beb6629385b39517129685b") depends_on("py-setuptools@36.2.0:", type="build") depends_on("python@3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-tensorboard/package.py b/var/spack/repos/builtin/packages/py-tensorboard/package.py index 9f39ece8c635d3..83f3f1a464c6ed 100644 --- a/var/spack/repos/builtin/packages/py-tensorboard/package.py +++ b/var/spack/repos/builtin/packages/py-tensorboard/package.py @@ -21,173 +21,69 @@ class PyTensorboard(PythonPackage): license("Apache-2.0") - version( - "2.16.2", - sha256="9f2b4e7dad86667615c0e5cd072f1ea8403fc032a299f0072d6f74855775cc45", - expand=False, - ) - version( - "2.16.1", - sha256="928b62567911a8eeb2ebeb7482a9e4599b35f6713a6f2c56655259c18a139569", - expand=False, - ) - version( - "2.16.0", - sha256="263b909a2009cb3a79daa6abe64c1785cc317c25a54e4db2fecb6429ffc54c58", - expand=False, - ) - version( - "2.15.2", - sha256="a6f6443728064d962caea6d34653e220e34ef8df764cb06a8212c17e1a8f0622", - expand=False, - ) - version( - "2.15.1", - sha256="c46c1d1cf13a458c429868a78b2531d8ff5f682058d69ec0840b0bc7a38f1c0f", - expand=False, - ) - version( - "2.15.0", - sha256="c05b4d02a3a9fd4bd6c25265087d52b49b790a871ddf98f4fb32fe97cbbc7ad0", - expand=False, - ) - version( - "2.14.1", - sha256="3db108fb58f023b6439880e177743c5f1e703e9eeb5fb7d597871f949f85fd58", - expand=False, - ) - version( - "2.14.0", - sha256="3667f9745d99280836ad673022362c840f60ed8fefd5a3e30bf071f5a8fd0017", - expand=False, - ) - version( - "2.13.0", - sha256="ab69961ebddbddc83f5fa2ff9233572bdad5b883778c35e4fe94bf1798bd8481", - expand=False, - ) - version( - "2.12.3", - sha256="b4a69366784bc347e02fbe7d847e01896a649ca52f8948a11005e205dcf724fb", - expand=False, - ) - version( - "2.12.2", - sha256="811ab0d27a139445836db9fd4f974424602c3dce12379364d379bcba7c783a68", - expand=False, - ) - version( - "2.12.1", - sha256="58f1c2a25b4829b9c48d2b1ec951dedc9325dcd1ea4b0f601d241d2887d0ed65", - expand=False, - ) - version( - "2.12.0", - sha256="3cbdc32448d7a28dc1bf0b1754760c08b8e0e2e37c451027ebd5ff4896613012", - expand=False, - ) - version( - "2.11.2", - sha256="cbaa2210c375f3af1509f8571360a19ccc3ded1d9641533414874b5deca47e89", - expand=False, - ) - version( - "2.11.1", - sha256="0c7529f3f43691e8cc2ece8e564c2e103c51ade317c6af626d415239b5088018", - expand=False, - ) - version( - "2.11.0", - sha256="a0e592ee87962e17af3f0dce7faae3fbbd239030159e9e625cce810b7e35c53d", - expand=False, - ) - version( - "2.10.1", - sha256="fb9222c1750e2fa35ef170d998a1e229f626eeced3004494a8849c88c15d8c1c", - expand=False, - ) - version( - "2.10.0", - sha256="76c91a5e8959cd2208cc32cb17a0cb002badabb66a06ac2af02a7810f49a59e3", - expand=False, - ) - version( - "2.9.1", - sha256="baa727f791776f9e5841d347127720ceed4bbd59c36b40604b95fb2ae6029276", - expand=False, - ) - version( - "2.9.0", - sha256="bd78211076dca5efa27260afacfaa96cd05c7db12a6c09cc76a1d6b2987ca621", - expand=False, - ) - version( - "2.8.0", - sha256="65a338e4424e9079f2604923bdbe301792adce2ace1be68da6b3ddf005170def", - expand=False, - ) - version( - "2.7.0", - sha256="239f78a4a8dff200ce585a030c787773a8c1184d5c159252f5f85bac4e3c3b38", - expand=False, - ) - version( - "2.6.0", - sha256="f7dac4cdfb52d14c9e3f74585ce2aaf8e6203620a864e51faf84988b09f7bbdb", - expand=False, - ) - version( - "2.5.0", - sha256="e167460085b6528956b33bab1c970c989cdce47a6616273880733f5e7bde452e", - expand=False, - ) - version( - "2.4.1", - sha256="7b8c53c396069b618f6f276ec94fc45d17e3282d668979216e5d30be472115e4", - expand=False, - ) - version( - "2.4.0", - sha256="cde0c663a85609441cb4d624e7255fd8e2b6b1d679645095aac8a234a2812738", - expand=False, - ) - version( - "2.3.0", - sha256="d34609ed83ff01dd5b49ef81031cfc9c166bba0dabd60197024f14df5e8eae5e", - expand=False, - ) - version( - "2.2.0", - sha256="bb6bbc75ad2d8511ba6cbd49e4417276979f49866e11841e83da8298727dbaed", - expand=False, - ) + version("2.17.0", sha256="859a499a9b1fb68a058858964486627100b71fcb21646861c61d31846a6478fb") + version("2.16.2", sha256="9f2b4e7dad86667615c0e5cd072f1ea8403fc032a299f0072d6f74855775cc45") + version("2.16.1", sha256="928b62567911a8eeb2ebeb7482a9e4599b35f6713a6f2c56655259c18a139569") + version("2.16.0", sha256="263b909a2009cb3a79daa6abe64c1785cc317c25a54e4db2fecb6429ffc54c58") + version("2.15.2", sha256="a6f6443728064d962caea6d34653e220e34ef8df764cb06a8212c17e1a8f0622") + version("2.15.1", sha256="c46c1d1cf13a458c429868a78b2531d8ff5f682058d69ec0840b0bc7a38f1c0f") + version("2.15.0", sha256="c05b4d02a3a9fd4bd6c25265087d52b49b790a871ddf98f4fb32fe97cbbc7ad0") + version("2.14.1", sha256="3db108fb58f023b6439880e177743c5f1e703e9eeb5fb7d597871f949f85fd58") + version("2.14.0", sha256="3667f9745d99280836ad673022362c840f60ed8fefd5a3e30bf071f5a8fd0017") + version("2.13.0", sha256="ab69961ebddbddc83f5fa2ff9233572bdad5b883778c35e4fe94bf1798bd8481") + version("2.12.3", sha256="b4a69366784bc347e02fbe7d847e01896a649ca52f8948a11005e205dcf724fb") + version("2.12.2", sha256="811ab0d27a139445836db9fd4f974424602c3dce12379364d379bcba7c783a68") + version("2.12.1", sha256="58f1c2a25b4829b9c48d2b1ec951dedc9325dcd1ea4b0f601d241d2887d0ed65") + version("2.12.0", sha256="3cbdc32448d7a28dc1bf0b1754760c08b8e0e2e37c451027ebd5ff4896613012") + version("2.11.2", sha256="cbaa2210c375f3af1509f8571360a19ccc3ded1d9641533414874b5deca47e89") + version("2.11.1", sha256="0c7529f3f43691e8cc2ece8e564c2e103c51ade317c6af626d415239b5088018") + version("2.11.0", sha256="a0e592ee87962e17af3f0dce7faae3fbbd239030159e9e625cce810b7e35c53d") + version("2.10.1", sha256="fb9222c1750e2fa35ef170d998a1e229f626eeced3004494a8849c88c15d8c1c") + version("2.10.0", sha256="76c91a5e8959cd2208cc32cb17a0cb002badabb66a06ac2af02a7810f49a59e3") + version("2.9.1", sha256="baa727f791776f9e5841d347127720ceed4bbd59c36b40604b95fb2ae6029276") + version("2.9.0", sha256="bd78211076dca5efa27260afacfaa96cd05c7db12a6c09cc76a1d6b2987ca621") + version("2.8.0", sha256="65a338e4424e9079f2604923bdbe301792adce2ace1be68da6b3ddf005170def") + version("2.7.0", sha256="239f78a4a8dff200ce585a030c787773a8c1184d5c159252f5f85bac4e3c3b38") + version("2.6.0", sha256="f7dac4cdfb52d14c9e3f74585ce2aaf8e6203620a864e51faf84988b09f7bbdb") + version("2.5.0", sha256="e167460085b6528956b33bab1c970c989cdce47a6616273880733f5e7bde452e") + version("2.4.1", sha256="7b8c53c396069b618f6f276ec94fc45d17e3282d668979216e5d30be472115e4") + version("2.4.0", sha256="cde0c663a85609441cb4d624e7255fd8e2b6b1d679645095aac8a234a2812738") + version("2.3.0", sha256="d34609ed83ff01dd5b49ef81031cfc9c166bba0dabd60197024f14df5e8eae5e") + version("2.2.0", sha256="bb6bbc75ad2d8511ba6cbd49e4417276979f49866e11841e83da8298727dbaed") - depends_on("python@3.9:", type=("build", "run"), when="@2.14:") - depends_on("python@3.8:", type=("build", "run"), when="@2.12:") - depends_on("py-absl-py@0.4:", type=("build", "run")) - depends_on("py-grpcio@1.48.2:", type=("build", "run"), when="@2.12:") - depends_on("py-grpcio@1.24.3:", type=("build", "run"), when="@2.3:") - depends_on("py-grpcio@1.23.3:", type=("build", "run"), when="@2.2") - depends_on("py-markdown@2.6.8:", type=("build", "run")) - depends_on("py-numpy@1.12.0:", type=("build", "run")) - depends_on("py-protobuf@3.19.6:4.23,4.24.1:", type=("build", "run"), when="@2.15.2:") - depends_on("py-protobuf@3.19.6:4.23", type=("build", "run"), when="@2.12:2.15.1") - depends_on("py-protobuf@3.9.2:3", type=("build", "run"), when="@2.11") - depends_on("py-protobuf@3.9.2:3.19", type=("build", "run"), when="@2.9:2.10") - depends_on("py-protobuf@3.6.0:3.19", type=("build", "run"), when="@:2.8") - depends_on("py-setuptools@41.0.0:", type=("build", "run")) - depends_on("py-six@1.10.0:", type=("build", "run"), when="@:2.4,2.14:") - depends_on("py-tensorboard-data-server@0.7", type=("build", "run"), when="@2.12:") - depends_on("py-tensorboard-data-server@0.6", type=("build", "run"), when="@2.5:2.11") - depends_on("py-werkzeug@1.0.1:", type=("build", "run"), when="@2.9:") - depends_on("py-werkzeug@0.11.15:", type=("build", "run")) + with default_args(type=("build", "run")): + depends_on("python@3.9:", when="@2.14:") + depends_on("python@3.8:", when="@2.12:") + depends_on("py-absl-py@0.4:") + depends_on("py-grpcio@1.48.2:", when="@2.12:") + depends_on("py-grpcio@1.24.3:", when="@2.3:") + depends_on("py-grpcio@1.23.3:", when="@2.2") + depends_on("py-markdown@2.6.8:") + depends_on("py-numpy@1.12.0:") + # https://github.com/tensorflow/tensorboard/pull/6871 + depends_on("py-numpy@:1") + # https://github.com/tensorflow/tensorboard/pull/5138 + depends_on("py-numpy@:1.23", when="@:2.5") + depends_on("py-protobuf@3.19.6:4", when="@2.17:") + depends_on("py-protobuf@3.19.6:", when="@2.15.2:2.16") + depends_on("py-protobuf@3.19.6:4.23", when="@2.12:2.15.1") + depends_on("py-protobuf@3.9.2:3", when="@2.11") + depends_on("py-protobuf@3.9.2:3.19", when="@2.9:2.10") + depends_on("py-protobuf@3.6.0:3.19", when="@:2.8") + depends_on("py-setuptools@41.0.0:") + depends_on("py-six@1.10.0:", when="@:2.4,2.14:") + depends_on("py-tensorboard-data-server@0.7", when="@2.12:") + depends_on("py-tensorboard-data-server@0.6", when="@2.5:2.11") + depends_on("py-werkzeug@1.0.1:", when="@2.9:") + depends_on("py-werkzeug@0.11.15:") - # Historical dependencies - depends_on("py-google-auth@1.6.3:2", type=("build", "run"), when="@2.7:2.15") - depends_on("py-google-auth@1.6.3:1", type=("build", "run"), when="@:2.6") - depends_on("py-google-auth-oauthlib@0.5:1", type=("build", "run"), when="@2.15") - depends_on("py-google-auth-oauthlib@0.5:1.0", type=("build", "run"), when="@2.12.1:2.14") - depends_on("py-google-auth-oauthlib@0.4.1:0.4", type=("build", "run"), when="@:2.12.0") - depends_on("py-requests@2.21.0:2", type=("build", "run"), when="@:2.15") - depends_on("py-tensorboard-plugin-wit@1.6.0:", type=("build", "run"), when="@:2.13") - depends_on("py-wheel@0.26:", type="build", when="@:2.13") + # Historical dependencies + depends_on("py-google-auth@1.6.3:2", when="@2.7:2.15") + depends_on("py-google-auth@1.6.3:1", when="@:2.6") + depends_on("py-google-auth-oauthlib@0.5:1", when="@2.15") + depends_on("py-google-auth-oauthlib@0.5:1.0", when="@2.12.1:2.14") + depends_on("py-google-auth-oauthlib@0.4.1:0.4", when="@:2.12.0") + depends_on("py-requests@2.21.0:2", when="@:2.15") + depends_on("py-tensorboard-plugin-wit@1.6.0:", when="@:2.13") + + conflicts("^py-protobuf@4.24.0") diff --git a/var/spack/repos/builtin/packages/py-tensorflow-estimator/package.py b/var/spack/repos/builtin/packages/py-tensorflow-estimator/package.py index eba0f1dbe98481..02ed47516997f3 100644 --- a/var/spack/repos/builtin/packages/py-tensorflow-estimator/package.py +++ b/var/spack/repos/builtin/packages/py-tensorflow-estimator/package.py @@ -9,8 +9,9 @@ class PyTensorflowEstimator(Package): - """TensorFlow Estimator is a high-level TensorFlow API that greatly - simplifies machine learning programming.""" + """TensorFlow Estimator is a high-level API that encapsulates + model training, evaluation, prediction, and exporting. + """ homepage = "https://github.com/tensorflow/estimator" url = "https://github.com/tensorflow/estimator/archive/v2.2.0.tar.gz" @@ -28,39 +29,41 @@ class PyTensorflowEstimator(Package): version("2.8.0", sha256="58a2c3562ca6491c257e9a4d9bd8825667883257edcdb452181efa691c586b17") version("2.7.0", sha256="e5164e802638d3cf110ecc17912be9d514a9d3354ec48e77200b9403dcc15965") version("2.6.0", sha256="947705c60c50da0b4a8ceec1bc058aaf6bf567a7efdcd50d5173ebf6bafcf30f") - version("2.5.0", sha256="66661f30ea05d57377c45267ca770935fb8c54f85b7901f0a7deb91766fe9f45") version("2.4.0", sha256="e6ea12014c3d8c89a81ace95f8f8b7c39ffcd3e4e4626709e4aee0010eefd962") version("2.3.0", sha256="75403e7de7e8ec30ec0781ede56ed84cbe5e90daad64a9c242cd489c8fe63a17") version("2.2.0", sha256="2d68cb6e6442e7dcbfa2e092aa25bdcb0eda420536a829b85d732854a4c85d46") extends("python") - # tensorflow_estimator/tools/pip_package/setup.py - depends_on("python@3.7:", when="@2.9:", type=("build", "run")) - - for ver in ["2.14", "2.13", "2.12", "2.11", "2.10", "2.9", "2.8", "2.7", "2.6"]: - depends_on("py-keras@" + ver, when="@" + ver, type=("build", "run")) - - for ver in [ - "2.14", - "2.13", - "2.12", - "2.11", - "2.10", - "2.9", - "2.8", - "2.7", - "2.6", - "2.5", - "2.4", - "2.3", - "2.2", - ]: - depends_on("py-tensorflow@" + ver, when="@" + ver, type=("build", "run")) - - depends_on("bazel@0.19.0:", type="build") - depends_on("py-pip", type="build") - depends_on("py-wheel", type="build") + with default_args(type="build"): + depends_on("bazel@0.19.0:") + depends_on("py-pip") + depends_on("py-wheel") + + # See expect_*_installed in tensorflow_estimator/python/estimator/BUILD + with default_args(type=("build", "run")): + depends_on("py-absl-py") + depends_on("py-h5py") + depends_on("py-numpy") + depends_on("py-pandas") + depends_on("py-six") + for ver in [ + "2.14", + "2.13", + "2.12", + "2.11", + "2.10", + "2.9", + "2.8", + "2.7", + "2.6", + "2.4", + "2.3", + "2.2", + ]: + depends_on(f"py-tensorboard@{ver}", when=f"@{ver}") + depends_on(f"py-tensorflow@{ver}", when=f"@{ver}") + depends_on(f"py-keras@{ver}", when=f"@{ver}") def install(self, spec, prefix): self.tmp_path = tempfile.mkdtemp(prefix="spack") diff --git a/var/spack/repos/builtin/packages/py-tensorflow-probability/package.py b/var/spack/repos/builtin/packages/py-tensorflow-probability/package.py index 38af49c19996a5..9f8360d432dcc6 100644 --- a/var/spack/repos/builtin/packages/py-tensorflow-probability/package.py +++ b/var/spack/repos/builtin/packages/py-tensorflow-probability/package.py @@ -23,8 +23,9 @@ class PyTensorflowProbability(Package): license("Apache-2.0") - # TODO: reactivate once TF 2.15 is ready https://github.com/spack/spack/pull/41069 - # version("0.23.0", sha256="a00769550da9284acbd69e32a005507153ad39b0c190feca2bbbf6373366cc14") + # tf-keras does not (yet) exist on Spack, i.e. the TF extra won't work, see below + # version("0.24.0", sha256="3d75418cef09ea357ee879347133ab784fe4637a5ba251a8e06ef930dd970a3e") + version("0.23.0", sha256="a00769550da9284acbd69e32a005507153ad39b0c190feca2bbbf6373366cc14") version("0.22.1", sha256="9c1203b454aaeb48ac67dea862a411dba6b04f67c1e874e0e83bd1d7f13829a3") version("0.22.0", sha256="f9ce55b00c8069246d701c04eaafccde413355f6e76ccf9e549772ecfa0349a4") version("0.21.0", sha256="69b7510b38b2e48bcfb9ff570ef598d489e4f1bcbe13276f5dd91c878b8d56d1") @@ -59,11 +60,13 @@ class PyTensorflowProbability(Package): # tensorflow_probability/python/__init__.py # TODO: reactivate the JAX versions once the JAX package is available with newer versions # also add jaxlib as a dependency - # TODO: reactivate once TF 2.15 is ready https://github.com/spack/spack/pull/41069 variant("py-tensorflow", default=False, description="Build with TensorFlow support") with when("+py-tensorflow"): - # depends_on("py-tensorflow@2.15", when="@0.23", type=("build", "run")) + # TODO(0.24): requires tf-keras on Spack + # depends_on("py-tf-keras", when="@0.24:", type=("build", "run")) + # depends_on("py-tensorflow@2.16", when="@0.24", type=("build", "run")) + depends_on("py-tensorflow@2.15", when="@0.23", type=("build", "run")) depends_on("py-tensorflow@2.14:2", when="@0.22", type=("build", "run")) depends_on("py-tensorflow@2.13:2", when="@0.21", type=("build", "run")) depends_on("py-tensorflow@2.12:2", when="@0.20", type=("build", "run")) @@ -71,11 +74,11 @@ class PyTensorflowProbability(Package): # jaxlib is not required, as it's already a dependency of py-jax variant("py-jax", default=False, description="Build with JAX support") - with when("+py-jax"): # TODO: reactivate once the JAX package is available with newer versions - # depends_on("py-jax@0.4.20:0.4", when="@0.23", type=("build", "run")) - # depends_on("py-jax@0.4.16:0.4", when="@0.22", type=("build", "run")) - # depends_on("py-jax@0.4.14:0.4", when="@0.21", type=("build", "run")) - # depends_on("py-jax@0.4.8:0.4", when="@0.20", type=("build", "run")) + with when("+py-jax"): + depends_on("py-jax@0.4.20:0.4", when="@0.23", type=("build", "run")) + depends_on("py-jax@0.4.16:0.4", when="@0.22", type=("build", "run")) + depends_on("py-jax@0.4.14:0.4", when="@0.21", type=("build", "run")) + depends_on("py-jax@0.4.8:0.4", when="@0.20", type=("build", "run")) depends_on("py-jax@0.3.25:3", when="@0.19", type=("build", "run")) depends_on( diff --git a/var/spack/repos/builtin/packages/py-tensorflow/absl_neon.patch b/var/spack/repos/builtin/packages/py-tensorflow/absl_neon.patch new file mode 100644 index 00000000000000..595cce7bdbd199 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-tensorflow/absl_neon.patch @@ -0,0 +1,55 @@ +From 32321ebf22c32ed4bbc9f98b44f2a67fe6c86823 Mon Sep 17 00:00:00 2001 +From: Andrew Elble +Date: Wed, 1 May 2024 18:46:42 -0400 +Subject: [PATCH] patch + +--- + third_party/absl/absl_neon.patch | 23 +++++++++++++++++++++++ + third_party/absl/workspace.bzl | 1 + + 2 files changed, 24 insertions(+) + create mode 100644 third_party/absl/absl_neon.patch + +diff --git a/third_party/absl/absl_neon.patch b/third_party/absl/absl_neon.patch +new file mode 100644 +index 000000000000..d4eb77bc3f86 +--- /dev/null ++++ b/third_party/absl/absl_neon.patch +@@ -0,0 +1,23 @@ ++From: Andrew Elble ++Date: Thu, 25 Apr 2024 08:09:36 -0400 ++Subject: [PATCH] fix ++ ++--- ++ absl/base/config.h | 2 +- ++ 1 file changed, 1 insertion(+), 1 deletion(-) ++ ++diff --git a/absl/base/config.h b/absl/base/config.h ++index 5fa9f0efe5a4..bfedf4e1d7bd 100644 ++--- a/absl/base/config.h +++++ b/absl/base/config.h ++@@ -962,7 +962,7 @@ static_assert(ABSL_INTERNAL_INLINE_NAMESPACE_STR[0] != 'h' || ++ // https://llvm.org/docs/CompileCudaWithLLVM.html#detecting-clang-vs-nvcc-from-code ++ #ifdef ABSL_INTERNAL_HAVE_ARM_NEON ++ #error ABSL_INTERNAL_HAVE_ARM_NEON cannot be directly set ++-#elif defined(__ARM_NEON) && !defined(__CUDA_ARCH__) +++#elif defined(__ARM_NEON) && !(defined(__NVCC__) && defined(__CUDACC__)) ++ #define ABSL_INTERNAL_HAVE_ARM_NEON 1 ++ #endif ++ ++-- ++2.31.1 +diff --git a/third_party/absl/workspace.bzl b/third_party/absl/workspace.bzl +index 06f75166ce4b..56d146d65abe 100644 +--- a/third_party/absl/workspace.bzl ++++ b/third_party/absl/workspace.bzl +@@ -42,6 +42,7 @@ def repo(): + build_file = "//third_party/absl:com_google_absl.BUILD", + system_build_file = "//third_party/absl:system.BUILD", + system_link_files = SYS_LINKS, ++ patch_file = ["//third_party/absl:absl_neon.patch"], + strip_prefix = "abseil-cpp-{commit}".format(commit = ABSL_COMMIT), + urls = tf_mirror_urls("https://github.com/abseil/abseil-cpp/archive/{commit}.tar.gz".format(commit = ABSL_COMMIT)), + ) +-- +2.31.1 + diff --git a/var/spack/repos/builtin/packages/py-tensorflow/package.py b/var/spack/repos/builtin/packages/py-tensorflow/package.py index 5de25247e20fb3..1d86e81fd0cfef 100644 --- a/var/spack/repos/builtin/packages/py-tensorflow/package.py +++ b/var/spack/repos/builtin/packages/py-tensorflow/package.py @@ -3,27 +3,64 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os import sys import tempfile from spack.package import * +rocm_dependencies = [ + "hip", + "rocrand", + "rocblas", + "rocfft", + "hipfft", + "rccl", + "hipsparse", + "rocprim", + "llvm-amdgpu", + "hsa-rocr-dev", + "rocminfo", + "hipsolver", + "hiprand", + "rocsolver", + "hipsolver", + "hipblas", + "hipcub", + "rocm-core", + "roctracer-dev", + "miopen-hip", +] + class PyTensorflow(Package, CudaPackage, ROCmPackage, PythonExtension): """TensorFlow is an open source machine learning framework for everyone.""" homepage = "https://www.tensorflow.org" url = "https://github.com/tensorflow/tensorflow/archive/v2.3.1.tar.gz" + git = "https://github.com/tensorflow/tensorflow.git" maintainers("adamjstewart", "aweits") import_modules = ["tensorflow"] license("Apache-2.0") + version("2.17.0", sha256="9cc4d5773b8ee910079baaecb4086d0c28939f024dd74b33fc5e64779b6533dc") + version("2.16.2", sha256="023849bf253080cb1e4f09386f5eb900492da2288274086ed6cfecd6d99da9eb") version("2.16.1", sha256="c729e56efc945c6df08efe5c9f5b8b89329c7c91b8f40ad2bb3e13900bd4876d") + version( + "2.16.1-rocm-enhanced", + sha256="6765e85675734b8fe17bca3c0669aec2f9ee97699b413780bcf3c6f00661ce72", + url="https://github.com/ROCm/tensorflow-upstream/archive/refs/tags/r2.16-rocm-enhanced.tar.gz", + ) version("2.15.1", sha256="f36416d831f06fe866e149c7cd752da410a11178b01ff5620e9f265511ed57cf") version("2.15.0", sha256="9cec5acb0ecf2d47b16891f8bc5bc6fbfdffe1700bdadc0d9ebe27ea34f0c220") version("2.14.1", sha256="6b31ed347ed7a03c45b906aa41628ac91c3db7c84cb816971400d470e58ba494") + version( + "2.14-rocm-enhanced", + git="https://github.com/ROCm/tensorflow-upstream.git", + branch="r2.14-rocm-enhanced-nohipblaslt-build", + ) version("2.14.0", sha256="ce357fd0728f0d1b0831d1653f475591662ec5bca736a94ff789e6b1944df19f") version("2.13.1", sha256="89c07aebd4f41fbe0d08cc88aef00305542134f2f16d3b62918dc3c1182f33e2") version("2.13.0", sha256="e58c939079588623e6fa1d054aec2f90f95018266e0a970fd353a5244f5173dc") @@ -83,6 +120,9 @@ class PyTensorflow(Package, CudaPackage, ROCmPackage, PythonExtension): version("2.2.1", sha256="e6a28e64236d729e598dbeaa02152219e67d0ac94d6ed22438606026a02e0f88") version("2.2.0", sha256="69cd836f87b8c53506c4f706f655d423270f5a563b76dc1cfa60fbc3184185a3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mkl", default=False, description="Build with MKL support") variant("jemalloc", default=False, description="Build with jemalloc as malloc support") variant("gcp", default=False, description="Build with Google Cloud Platform support") @@ -114,144 +154,144 @@ class PyTensorflow(Package, CudaPackage, ROCmPackage, PythonExtension): extends("python") - # Python support based on wheel availability - depends_on("python@3.9:3.12", when="@2.16:", type=("build", "run")) - depends_on("python@3.9:3.11", when="@2.14:2.15", type=("build", "run")) - depends_on("python@3.8:3.11", when="@2.12:2.13", type=("build", "run")) - depends_on("python@:3.10", when="@2.8:2.11", type=("build", "run")) - depends_on("python@:3.9", when="@2.5:2.7", type=("build", "run")) - depends_on("python@:3.8", when="@2.2:2.4", type=("build", "run")) - - # See .bazelversion - depends_on("bazel@6.5.0", type="build", when="@2.16:") - depends_on("bazel@6.1.0", type="build", when="@2.14:2.15") - depends_on("bazel@5.3.0", type="build", when="@2.11:2.13") - depends_on("bazel@5.1.1", type="build", when="@2.10") - # See _TF_MIN_BAZEL_VERSION and _TF_MAX_BAZEL_VERSION in configure.py - depends_on("bazel@4.2.2:5.99.0", type="build", when="@2.9") - depends_on("bazel@4.2.1:4.99.0", type="build", when="@2.8") - depends_on("bazel@3.7.2:4.99.0", type="build", when="@2.7") - depends_on("bazel@3.7.2:3.99.0", type="build", when="@2.5:2.6") - depends_on("bazel@3.1.0:3.99.0", type="build", when="@2.3:2.4") - depends_on("bazel@2.0.0", type="build", when="@2.2") - - depends_on("swig", type="build") - depends_on("py-pip", type="build") - depends_on("py-wheel", type="build") - - # Listed under REQUIRED_PACKAGES in tensorflow/tools/pip_package/setup.py - depends_on("py-absl-py@1:", type=("build", "run"), when="@2.9:") - depends_on("py-absl-py@0.4:", type=("build", "run"), when="@2.7:2.8") - depends_on("py-absl-py@0.10:0", type=("build", "run"), when="@2.4:2.6") - depends_on("py-absl-py@0.7:", type=("build", "run"), when="@:2.3") - depends_on("py-astunparse@1.6:", type=("build", "run"), when="@2.7:") - depends_on("py-astunparse@1.6.3:1.6", type=("build", "run"), when="@2.4:2.6") - depends_on("py-astunparse@1.6.3", type=("build", "run"), when="@2.2:2.3") - depends_on("py-flatbuffers@23.5.26:", type=("build", "run"), when="@2.14:") - depends_on("py-flatbuffers@23.1.21:", type=("build", "run"), when="@2.13") - depends_on("py-flatbuffers@2:", type=("build", "run"), when="@2.10:2.12") - depends_on("py-flatbuffers@1.12:1", type=("build", "run"), when="@2.9") - depends_on("py-flatbuffers@1.12:", type=("build", "run"), when="@2.8") - depends_on("py-flatbuffers@1.12:2", type=("build", "run"), when="@2.7") - depends_on("py-flatbuffers@1.12", type=("build", "run"), when="@2.4:2.6") - depends_on("py-gast@0.2.1:0.4,0.5.3:", type=("build", "run"), when="@2.14:") - depends_on("py-gast@0.2.1:0.4.0", type=("build", "run"), when="@2.9:2.13") - depends_on("py-gast@0.2.1:", type=("build", "run"), when="@2.8") - depends_on("py-gast@0.2.1:0.4", type=("build", "run"), when="@2.7") - depends_on("py-gast@0.4.0", type=("build", "run"), when="@2.5:2.6") - depends_on("py-gast@0.3.3", type=("build", "run"), when="@2.2:2.4") - depends_on("py-gast@0.2.2", type=("build", "run"), when="@:2.1") - depends_on("py-google-pasta@0.1.1:", type=("build", "run"), when="@2.7:") - depends_on("py-google-pasta@0.2:0", type=("build", "run"), when="@2.4:2.6") - depends_on("py-google-pasta@0.1.8:", type=("build", "run"), when="@2.2:2.3") - depends_on("py-google-pasta@0.1.6:", type=("build", "run"), when="@:2.1") - depends_on("py-h5py@3.10:", type=("build", "run"), when="@2.16:") - depends_on("py-h5py@2.9:", type=("build", "run"), when="@2.7:2.15") - depends_on("py-h5py@3.1", type=("build", "run"), when="@2.5:2.6") - depends_on("py-h5py@2.10", type=("build", "run"), when="@2.2:2.4") - depends_on("py-h5py@:2.10.0", type=("build", "run"), when="@2.1.3:2.1") - # propagate the mpi variant setting for h5py/hdf5 to avoid unexpected crashes - depends_on("py-h5py+mpi", type=("build", "run"), when="@2.1.3:+mpi") - depends_on("py-h5py~mpi", type=("build", "run"), when="@2.1.3:~mpi") - depends_on("hdf5+mpi", type="build", when="@2.1.3:+mpi") - depends_on("hdf5~mpi", type="build", when="@2.1.3:~mpi") - depends_on("py-libclang@13:", type=("build", "run"), when="@2.9:") - depends_on("py-libclang@9.0.1:", type=("build", "run"), when="@2.7:2.8") - depends_on("py-ml-dtypes@0.3.1:0.3", type=("build", "run"), when="@2.15.1:") - depends_on("py-ml-dtypes@0.2", type=("build", "run"), when="@2.15.0") - depends_on("py-ml-dtypes@0.2.0", type=("build", "run"), when="@2.14") - depends_on("py-numpy@1.23.5:", type=("build", "run"), when="@2.14:") - depends_on("py-numpy@1.22:1.24.3", type=("build", "run"), when="@2.13:") - depends_on("py-numpy@1.22:1.23", type=("build", "run"), when="@2.12") - depends_on("py-numpy@1.20:", type=("build", "run"), when="@2.8:2.11") - depends_on("py-numpy@1.14.5:", type=("build", "run"), when="@2.7") - depends_on("py-numpy@1.19.2:1.19", type=("build", "run"), when="@2.4:2.6") - # https://github.com/tensorflow/tensorflow/issues/40688 - depends_on("py-numpy@1.16.0:1.18", type=("build", "run"), when="@:2.3") - depends_on("py-opt-einsum@2.3.2:", type=("build", "run"), when="@:2.3,2.7:") - depends_on("py-opt-einsum@3.3", type=("build", "run"), when="@2.4:2.6") - depends_on("py-packaging", type=("build", "run"), when="@2.9:") - depends_on("py-protobuf@3.20.3:4.20,4.21.6:4", type=("build", "run"), when="@2.12:") - depends_on("py-protobuf@3.9.2:", type=("build", "run"), when="@2.3:2.11") - depends_on("py-protobuf@3.8.0:", type=("build", "run"), when="@:2.2") - # https://github.com/protocolbuffers/protobuf/issues/10051 - # https://github.com/tensorflow/tensorflow/issues/56266 - depends_on("py-protobuf@:3.19", type=("build", "run"), when="@:2.11") - # Must be matching versions of py-protobuf and protobuf - conflicts("^py-protobuf~cpp") - depends_on("py-requests@2.21:2", type=("build", "run"), when="@2.16:") - depends_on("py-requests", type=("build", "run")) - depends_on("py-setuptools", type=("build", "run")) - depends_on("py-six@1.12:", type=("build", "run"), when="@:2.3,2.7:") - depends_on("py-six@1.15", type=("build", "run"), when="@2.4:2.6") - depends_on("py-termcolor@1.1:", type=("build", "run"), when="@:2.3,2.7:") - depends_on("py-termcolor@1.1", type=("build", "run"), when="@2.4:2.6") - depends_on("py-typing-extensions@3.6.6:", type=("build", "run"), when="@2.7:2.12,2.14:") - depends_on("py-typing-extensions@3.6.6:4.5", type=("build", "run"), when="@2.13") - depends_on("py-typing-extensions@3.7.4:3.7", type=("build", "run"), when="@2.4:2.6") - depends_on("py-wrapt@1.11:", type=("build", "run"), when="@2.7:2.11,2.13,2.16:") - depends_on("py-wrapt@1.11:1.14", type=("build", "run"), when="@2.12,2.14:2.15") - depends_on("py-wrapt@1.12.1:1.12", type=("build", "run"), when="@2.4:2.6") - depends_on("py-wrapt@1.11.1:", type=("build", "run"), when="@:2.3") - - # TODO: add packages for these dependencies - # depends_on('py-tensorflow-io-gcs-filesystem@0.23.1:', type=('build', 'run'), when='@2.8:') - # depends_on('py-tensorflow-io-gcs-filesystem@0.21:', type=('build', 'run'), when='@2.7') - - if sys.byteorder == "little": - # Only builds correctly on little-endian machines - depends_on("py-grpcio@1.24.3:1", type=("build", "run"), when="@2.7:") - depends_on("py-grpcio@1.37.0:1", type=("build", "run"), when="@2.6") - depends_on("py-grpcio@1.34", type=("build", "run"), when="@2.5") - depends_on("py-grpcio@1.32", type=("build", "run"), when="@2.4") - depends_on("py-grpcio@1.8.6:", type=("build", "run"), when="@:2.3") - - for minor_ver in range(5, 17): - depends_on( - "py-tensorboard@2.{}".format(minor_ver), - type=("build", "run"), - when="@2.{}".format(minor_ver), - ) - # TODO: is this still true? We now install tensorboard from wheel for all versions - # depends_on('py-tensorboard', when='@:2.4') # circular dep - # depends_on('py-tensorflow-estimator') # circular dep - # depends_on('py-keras') # circular dep - - # tensorflow/tools/pip_package/build_pip_package.sh - depends_on("patchelf", when="@2.13: platform=linux", type="build") - # https://github.com/tensorflow/tensorflow/issues/60179#issuecomment-1491238631 - depends_on("coreutils", when="@2.13: platform=darwin", type="build") - - # No longer a dependency in latest versions - depends_on("py-jax@0.3.15:", type=("build", "run"), when="@2.12") - depends_on("py-keras-preprocessing@1.1.1:", type=("build", "run"), when="@2.7:2.10") - depends_on("py-keras-preprocessing@1.1.2:1.1", type=("build", "run"), when="@2.4:2.6") - depends_on("py-keras-preprocessing@1.1.1:1.1", type=("build", "run"), when="@2.3") - depends_on("py-keras-preprocessing@1.1:", type=("build", "run"), when="@2.2") - depends_on("py-scipy@1.4.1", type=("build", "run"), when="@2.2.0,2.3.0") - depends_on("py-wheel@0.32:0", type=("build", "run"), when="@2.7") - depends_on("py-wheel@0.35:0", type=("build", "run"), when="@2.4:2.6") - depends_on("py-wheel@0.26:", type=("build", "run"), when="@:2.3") + with default_args(type="build"): + # See .bazelversion + depends_on("bazel@6.5.0", when="@2.16:") + depends_on("bazel@6.1.0", when="@2.14:2.15") + depends_on("bazel@5.3.0", when="@2.11:2.13") + depends_on("bazel@5.1.1", when="@2.10") + # See _TF_MIN_BAZEL_VERSION and _TF_MAX_BAZEL_VERSION in configure.py + depends_on("bazel@4.2.2:5.99.0", when="@2.9") + depends_on("bazel@4.2.1:4.99.0", when="@2.8") + depends_on("bazel@3.7.2:4.99.0", when="@2.7") + depends_on("bazel@3.7.2:3.99.0", when="@2.5:2.6") + depends_on("bazel@3.1.0:3.99.0", when="@2.3:2.4") + depends_on("bazel@2.0.0", when="@2.2") + + # tensorflow/tools/pip_package/build_pip_package.sh + depends_on("patchelf", when="@2.13: platform=linux") + # https://github.com/tensorflow/tensorflow/issues/60179#issuecomment-1491238631 + depends_on("coreutils", when="@2.13: platform=darwin") + + depends_on("swig") + depends_on("py-pip") + depends_on("py-wheel") + + with default_args(type=("build", "run")): + # Python support based on wheel availability + depends_on("python@3.9:3.12", when="@2.16:") + depends_on("python@3.9:3.11", when="@2.14:2.15") + depends_on("python@3.8:3.11", when="@2.12:2.13") + depends_on("python@:3.10", when="@2.8:2.11") + depends_on("python@:3.9", when="@2.5:2.7") + depends_on("python@:3.8", when="@2.2:2.4") + + # Listed under REQUIRED_PACKAGES in tensorflow/tools/pip_package/setup.py + depends_on("py-absl-py@1:", when="@2.9:") + depends_on("py-absl-py@0.4:", when="@2.7:2.8") + depends_on("py-absl-py@0.10:0", when="@2.4:2.6") + depends_on("py-absl-py@0.7:", when="@:2.3") + depends_on("py-astunparse@1.6:", when="@2.7:") + depends_on("py-astunparse@1.6.3:1.6", when="@2.4:2.6") + depends_on("py-astunparse@1.6.3", when="@2.2:2.3") + depends_on("py-flatbuffers@24.3.25:", when="@2.17:") + depends_on("py-flatbuffers@23.5.26:", when="@2.14:") + depends_on("py-flatbuffers@23.1.21:", when="@2.13") + depends_on("py-flatbuffers@2:", when="@2.10:2.12") + depends_on("py-flatbuffers@1.12:1", when="@2.9") + depends_on("py-flatbuffers@1.12:", when="@2.8") + depends_on("py-flatbuffers@1.12:2", when="@2.7") + depends_on("py-flatbuffers@1.12", when="@2.4:2.6") + depends_on("py-gast@0.2.1:0.4,0.5.3:", when="@2.14:") + depends_on("py-gast@0.2.1:0.4.0", when="@2.9:2.13") + depends_on("py-gast@0.2.1:", when="@2.8") + depends_on("py-gast@0.2.1:0.4", when="@2.7") + depends_on("py-gast@0.4.0", when="@2.5:2.6") + depends_on("py-gast@0.3.3", when="@2.2:2.4") + depends_on("py-gast@0.2.2", when="@:2.1") + depends_on("py-google-pasta@0.1.1:", when="@2.7:") + depends_on("py-google-pasta@0.2:0", when="@2.4:2.6") + depends_on("py-google-pasta@0.1.8:", when="@2.2:2.3") + depends_on("py-google-pasta@0.1.6:", when="@:2.1") + depends_on("py-h5py@3.10:", when="@2.16:") + depends_on("py-h5py@2.9:", when="@2.7:2.15") + depends_on("py-h5py@3.1", when="@2.5:2.6") + depends_on("py-h5py@2.10", when="@2.2:2.4") + depends_on("py-h5py@:2.10.0", when="@2.1.3:2.1") + # propagate the mpi variant setting for h5py/hdf5 to avoid unexpected crashes + depends_on("py-h5py+mpi", when="@2.1.3:+mpi") + depends_on("py-h5py~mpi", when="@2.1.3:~mpi") + depends_on("hdf5+mpi", when="@2.1.3:+mpi") + depends_on("hdf5~mpi", when="@2.1.3:~mpi") + depends_on("py-libclang@13:", when="@2.9:") + depends_on("py-libclang@9.0.1:", when="@2.7:2.8") + depends_on("py-ml-dtypes@0.3.1:0.4", when="@2.17:") + depends_on("py-ml-dtypes@0.3.1:0.3", when="@2.15.1:2.16") + depends_on("py-ml-dtypes@0.2", when="@2.15.0") + depends_on("py-ml-dtypes@0.2.0", when="@2.14") + depends_on("py-numpy@1.23.5:", when="@2.14:") + depends_on("py-numpy@1.22:1.24.3", when="@2.13:") + depends_on("py-numpy@1.22:1.23", when="@2.12") + depends_on("py-numpy@1.20:", when="@2.8:2.11") + depends_on("py-numpy@1.14.5:", when="@2.7") + depends_on("py-numpy@1.19.2:1.19", when="@2.4:2.6") + # https://github.com/tensorflow/tensorflow/issues/40688 + depends_on("py-numpy@1.16.0:1.18", when="@:2.3") + # https://github.com/tensorflow/tensorflow/issues/67291 + depends_on("py-numpy@:1") + depends_on("py-opt-einsum@2.3.2:", when="@:2.3,2.7:") + depends_on("py-opt-einsum@3.3", when="@2.4:2.6") + depends_on("py-packaging", when="@2.9:") + depends_on("py-protobuf@3.20.3:4.20,4.21.6:4", when="@2.12:") + depends_on("py-protobuf@3.9.2:", when="@2.3:2.11") + depends_on("py-protobuf@3.8.0:", when="@:2.2") + # https://github.com/protocolbuffers/protobuf/issues/10051 + # https://github.com/tensorflow/tensorflow/issues/56266 + depends_on("py-protobuf@:3.19", when="@:2.11") + depends_on("py-requests@2.21:2", when="@2.16:") + depends_on("py-requests") + depends_on("py-setuptools") + depends_on("py-six@1.12:", when="@:2.3,2.7:") + depends_on("py-six@1.15", when="@2.4:2.6") + depends_on("py-termcolor@1.1:", when="@:2.3,2.7:") + depends_on("py-termcolor@1.1", when="@2.4:2.6") + depends_on("py-typing-extensions@3.6.6:", when="@2.7:2.12,2.14:") + depends_on("py-typing-extensions@3.6.6:4.5", when="@2.13") + depends_on("py-typing-extensions@3.7.4:3.7", when="@2.4:2.6") + depends_on("py-wrapt@1.11:", when="@2.7:2.11,2.13,2.16:") + depends_on("py-wrapt@1.11:1.14", when="@2.12,2.14:2.15") + depends_on("py-wrapt@1.12.1:1.12", when="@2.4:2.6") + depends_on("py-wrapt@1.11.1:", when="@:2.3") + + # TODO: add packages for these dependencies + # depends_on('py-tensorflow-io-gcs-filesystem@0.23.1:', when='@2.8:') + # depends_on('py-tensorflow-io-gcs-filesystem@0.21:', when='@2.7') + + if sys.byteorder == "little": + # Only builds correctly on little-endian machines + depends_on("py-grpcio@1.24.3:1", when="@2.7:") + depends_on("py-grpcio@1.37.0:1", when="@2.6") + depends_on("py-grpcio@1.34", when="@2.5") + depends_on("py-grpcio@1.32", when="@2.4") + depends_on("py-grpcio@1.8.6:", when="@:2.3") + + for minor_ver in range(2, 18): + depends_on("py-tensorboard@2.{}".format(minor_ver), when="@2.{}".format(minor_ver)) + + # TODO: support circular run-time dependencies + # depends_on('py-tensorflow-estimator') + # depends_on('py-keras') + + # Historical dependencies + depends_on("py-jax@0.3.15:", when="@2.12") + depends_on("py-keras-preprocessing@1.1.1:", when="@2.7:2.10") + depends_on("py-keras-preprocessing@1.1.2:1.1", when="@2.4:2.6") + depends_on("py-keras-preprocessing@1.1.1:1.1", when="@2.3") + depends_on("py-keras-preprocessing@1.1:", when="@2.2") + depends_on("py-scipy@1.4.1", when="@2.2.0,2.3.0") + depends_on("py-wheel@0.32:0", when="@2.7") + depends_on("py-wheel@0.35:0", when="@2.4:2.6") + depends_on("py-wheel@0.26:", when="@:2.3") # TODO: add packages for some of these dependencies depends_on("mkl", when="+mkl") @@ -271,12 +311,12 @@ class PyTensorflow(Package, CudaPackage, ROCmPackage, PythonExtension): depends_on("cuda@:11.4", when="@2.4:2.7") depends_on("cuda@:10.2", when="@:2.3") - depends_on("cudnn@8.9:", when="@2.15:") - depends_on("cudnn@8.7:", when="@2.14:") - depends_on("cudnn@8.6:", when="@2.12:") - depends_on("cudnn@8.1:", when="@2.5:") - depends_on("cudnn@8.0:", when="@2.4:") - depends_on("cudnn@7.6:", when="@2.1:") + depends_on("cudnn@8.9:8", when="@2.15:") + depends_on("cudnn@8.7:8", when="@2.14:") + depends_on("cudnn@8.6:8", when="@2.12:") + depends_on("cudnn@8.1:8", when="@2.5:") + depends_on("cudnn@8.0:8", when="@2.4:") + depends_on("cudnn@7.6:8", when="@2.1:") depends_on("cudnn@:7", when="@:2.2") # depends_on('tensorrt', when='+tensorrt') @@ -286,20 +326,9 @@ class PyTensorflow(Package, CudaPackage, ROCmPackage, PythonExtension): # depends_on('android-sdk', when='+android') with when("+rocm"): - depends_on("hip") - depends_on("rocrand") - depends_on("rocblas") - depends_on("rocfft") - depends_on("hipfft") - depends_on("rccl", when="+nccl") - depends_on("hipsparse") - depends_on("hipcub") - depends_on("rocsolver") - depends_on("rocprim") - depends_on("miopen-hip") - depends_on("llvm-amdgpu") - depends_on("hsa-rocr-dev") - depends_on("rocminfo") + for pkg_dep in rocm_dependencies: + depends_on(f"{pkg_dep}@6.0:", when="@2.14:") + depends_on(pkg_dep) # Check configure and configure.py to see when these variants are supported conflicts("+mkl", when="platform=darwin", msg="Darwin is not yet supported") @@ -308,11 +337,6 @@ class PyTensorflow(Package, CudaPackage, ROCmPackage, PythonExtension): when="platform=darwin", msg="Currently jemalloc is only support on Linux platform", ) - conflicts( - "+jemalloc", - when="platform=cray", - msg="Currently jemalloc is only support on Linux platform", - ) conflicts("+opencl", when="platform=windows") conflicts("+computecpp", when="~opencl") conflicts( @@ -335,32 +359,29 @@ class PyTensorflow(Package, CudaPackage, ROCmPackage, PythonExtension): when="platform=darwin", msg="Currently TensorRT is only supported on Linux platform", ) - conflicts( - "+tensorrt", - when="platform=cray", - msg="Currently TensorRT is only supported on Linux platform", - ) conflicts("+nccl", when="~cuda~rocm") conflicts( "+nccl", when="platform=darwin", msg="Currently NCCL is only supported on Linux platform" ) - conflicts( - "+nccl", when="platform=cray", msg="Currently NCCL is only supported on Linux platform" - ) conflicts("+mpi", when="platform=windows") conflicts("+ios", when="platform=linux", msg="iOS support only available on macOS") - conflicts("+ios", when="platform=cray", msg="iOS support only available on macOS") # https://github.com/tensorflow/tensorflow/pull/45404 conflicts("platform=darwin target=aarch64:", when="@:2.4") # https://github.com/tensorflow/tensorflow/pull/39225 conflicts("target=aarch64:", when="@:2.2") - conflicts("~rocm", when="@2.7.4-rocm-enhanced,2.11.0-rocm-enhanced") - conflicts("+rocm", when="@:2.7.4-a,2.7.4.0:2.11.0-a,2.11.0.0:") - + conflicts( + "~rocm", + when="@2.7.4-rocm-enhanced,2.11.0-rocm-enhanced,2.14-rocm-enhanced,2.16.1-rocm-enhanced", + ) + conflicts("+rocm", when="@:2.7.4-a,2.7.4.0:2.11.0-a,2.11.0.0:2.14-a,2.14-z:2.16.1-a,2.16.1-z:") # wheel 0.40 upgrades vendored packaging, trips over tensorflow-io-gcs-filesystem identifier conflicts("^py-wheel@0.40:", when="@2.11:2.13") + # Must be matching versions of py-protobuf and protobuf + conflicts("^py-protobuf~cpp") # https://www.tensorflow.org/install/source#tested_build_configurations + # https://github.com/tensorflow/tensorflow/issues/70199 + conflicts("%gcc", when="@2.17:") conflicts("%gcc@:9.3.0", when="@2.9:") conflicts("%gcc@:7.3.0") @@ -399,6 +420,32 @@ class PyTensorflow(Package, CudaPackage, ROCmPackage, PythonExtension): # protobuf definitions. patch("0008-Fix-protobuf-errors-when-using-system-protobuf.patch", when="@2.5:2.6") + # see https://github.com/tensorflow/tensorflow/issues/62490 + # and https://github.com/abseil/abseil-cpp/issues/1665 + patch("absl_neon.patch", when="@2.16.1: target=aarch64:") + + # reverting change otherwise the c467913 commit patch won't apply + patch( + "https://github.com/ROCm/tensorflow-upstream/commit/fd6b0a4356c66f5f30cedbc62b24f18d9e32806f.patch?full_index=1", + sha256="43f1519dfc618b4fb568f760d559c063234248fa12c47a35c1cf3b7114756424", + when="@2.16.1-rocm-enhanced +rocm", + reverse=True, + ) + patch( + "https://github.com/ROCm/tensorflow-upstream/commit/c467913bf4411ce2681391f37a9adf6031d23c2c.patch?full_index=1", + sha256="82554a84d19d99180a6bec274c6106dd217361e809b446e2e4bc4b6b979bdf7a", + when="@2.16.1-rocm-enhanced +rocm", + ) + patch( + "https://github.com/ROCm/tensorflow-upstream/commit/f4f4e8698b90755b0b5ea2d9da1933b0b988b111.patch?full_index=1", + sha256="a4c0fd62a0af3ba113c8933fa531dd17fa6667e507202a144715cd87fbdaf476", + when="@2.16.1-rocm-enhanced: +rocm", + ) + patch( + "https://github.com/ROCm/tensorflow-upstream/commit/8b7fcccb2914078737689347540cb79ace579bbb.patch?full_index=1", + sha256="75a61a79ce3aae51fda920f677f4dc045374b20e25628626eb37ca19c3a3b4c4", + when="@2.16.1-rocm-enhanced +rocm", + ) phases = ["configure", "build", "install"] # https://www.tensorflow.org/install/source @@ -406,7 +453,7 @@ def setup_build_environment(self, env): spec = self.spec # Please specify the location of python - env.set("PYTHON_BIN_PATH", spec["python"].command.path) + env.set("PYTHON_BIN_PATH", python.path) # Please input the desired Python library path to use env.set("PYTHON_LIB_PATH", python_platlib) @@ -508,6 +555,14 @@ def setup_build_environment(self, env): # Do you wish to build TensorFlow with ROCm support? if "+rocm" in spec: env.set("TF_NEED_ROCM", "1") + env.set("TF_HIPBLASLT", "0") + env.set("MIOPEN_PATH", spec["miopen-hip"].prefix) + env.set("ROCTRACER_PATH", spec["roctracer-dev"].prefix) + env.set("LLVM_PATH", spec["llvm-amdgpu"].prefix) + for pkg_dep in rocm_dependencies: + pkg_dep_cap = pkg_dep.upper().replace("-", "_") + env.set(f"{pkg_dep_cap}_PATH", spec[pkg_dep].prefix) + env.set("TF_ROCM_AMDGPU_TARGETS", ",".join(self.spec.variants["amdgpu_target"].value)) else: env.set("TF_NEED_ROCM", "0") @@ -601,10 +656,7 @@ def setup_build_environment(self, env): # Please specify optimization flags to use during compilation when # bazel option '--config=opt' is specified - env.set( - "CC_OPT_FLAGS", - spec.target.optimization_flags(spec.compiler.name, spec.compiler.version), - ) + env.set("CC_OPT_FLAGS", spec.architecture.target.optimization_flags(spec.compiler)) # Would you like to interactively configure ./WORKSPACE for # Android builds? @@ -703,6 +755,18 @@ def post_configure_fixes(self): with open(".tf_configure.bazelrc", mode="a") as f: f.write('build --action_env LD_LIBRARY_PATH="' + slibs + '"') + if spec.satisfies("@2.16.1-rocm-enhanced +rocm"): + if os.path.exists(spec["llvm-amdgpu"].prefix.bin.clang): + filter_file( + "/usr/lib/llvm-17/bin/clang", spec["llvm-amdgpu"].prefix.bin.clang, ".bazelrc" + ) + else: + filter_file( + "/usr/lib/llvm-17/bin/clang", + spec["llvm-amdgpu"].prefix.llvm.bin.clang, + ".bazelrc", + ) + filter_file("build:opt --copt=-march=native", "", ".tf_configure.bazelrc") filter_file("build:opt --host_copt=-march=native", "", ".tf_configure.bazelrc") @@ -768,12 +832,20 @@ def build(self, spec, prefix): if "~nccl" in spec: args.append("--config=nonccl") - if "+numa" in spec: - args.append("--config=numa") + # https://github.com/tensorflow/tensorflow/issues/63080 + if self.spec.satisfies("@2.14:"): + args.append(f"--define=with_numa_support={'+numa' in spec}") + else: + if "+numa" in spec: + args.append("--config=numa") args.append("--config=v2") - args.append("//tensorflow/tools/pip_package:build_pip_package") + # https://github.com/tensorflow/tensorflow/issues/63298 + if self.spec.satisfies("@2.17:"): + args.append("//tensorflow/tools/pip_package:wheel") + else: + args.append("//tensorflow/tools/pip_package:build_pip_package") bazel(*args) diff --git a/var/spack/repos/builtin/packages/py-tensorstore/package.py b/var/spack/repos/builtin/packages/py-tensorstore/package.py index 61fdd3b919303c..2df1af67b02af2 100644 --- a/var/spack/repos/builtin/packages/py-tensorstore/package.py +++ b/var/spack/repos/builtin/packages/py-tensorstore/package.py @@ -16,6 +16,8 @@ class PyTensorstore(PythonPackage): version("0.1.54", sha256="e1a9dcb0be7c828f752375409537d4b39c658dd6c6a0873fe21a24a556ec0e2a") + depends_on("cxx", type="build") # generated + # .bazelversion depends_on("bazel@6.4.0", type="build") diff --git a/var/spack/repos/builtin/packages/py-tesorter/package.py b/var/spack/repos/builtin/packages/py-tesorter/package.py index feb1848bf5f2e8..3cdebb3b7a8176 100644 --- a/var/spack/repos/builtin/packages/py-tesorter/package.py +++ b/var/spack/repos/builtin/packages/py-tesorter/package.py @@ -3,6 +3,8 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +from glob import glob + from spack.package import * @@ -29,5 +31,20 @@ class PyTesorter(PythonPackage): depends_on("py-biopython", type=("build", "run")) depends_on("py-xopen", type=("build", "run")) - depends_on("hmmer@3.3:", type="run") + depends_on("hmmer@3.3:", type=("build", "run")) depends_on("blast-plus", type="run") + + @run_after("install") + def run_hmmpress(self): + hmmpress = Executable(self.spec["hmmer"].prefix.bin.hmmpress) + db_dir = join_path( + self.prefix, + "lib", + f"python{self.spec['python'].version.dotted[:2]}", + "site-packages", + "TEsorter", + "database", + ) + with working_dir(db_dir): + for f in glob("*.hmm"): + hmmpress(f) diff --git a/var/spack/repos/builtin/packages/py-tfdlpack/package.py b/var/spack/repos/builtin/packages/py-tfdlpack/package.py index ac747b3f36a82f..f3c79f69a8860e 100644 --- a/var/spack/repos/builtin/packages/py-tfdlpack/package.py +++ b/var/spack/repos/builtin/packages/py-tfdlpack/package.py @@ -22,6 +22,9 @@ class PyTfdlpack(CMakePackage, PythonExtension): "0.1.1", tag="v0.1.1", commit="a1fdb53096158c2ec9189bb1ff46c92c6f571bbe", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cuda", default=True, description="Build with CUDA support") depends_on("cmake@3.5:", type="build") diff --git a/var/spack/repos/builtin/packages/py-theano/package.py b/var/spack/repos/builtin/packages/py-theano/package.py index a9ba9cc9e93eac..e2595f4e18f24e 100644 --- a/var/spack/repos/builtin/packages/py-theano/package.py +++ b/var/spack/repos/builtin/packages/py-theano/package.py @@ -23,6 +23,8 @@ class PyTheano(PythonPackage, CudaPackage): version("1.0.1", sha256="88d8aba1fe2b6b75eacf455d01bc7e31e838c5a0fb8c13dde2d9472495ff4662") version("0.8.2", sha256="7463c8f7ed1a787bf881f36d38a38607150186697e7ce7e78bfb94b7c6af8930") + depends_on("c", type="build") # generated + depends_on("python@2.6:2.8,3.3:", type=("build", "run")) depends_on("py-setuptools", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-thinc/package.py b/var/spack/repos/builtin/packages/py-thinc/package.py index 1dbfac1e074032..35e0eb8f47886a 100644 --- a/var/spack/repos/builtin/packages/py-thinc/package.py +++ b/var/spack/repos/builtin/packages/py-thinc/package.py @@ -18,6 +18,9 @@ class PyThinc(PythonPackage): version("7.4.1", sha256="0139fa84dc9b8d88af15e648fc4ae13d899b8b5e49cb26a8f4a0604ee9ad8a9e") version("7.4.0", sha256="523e9be1bfaa3ed1d03d406ce451b6b4793a9719d5b83d2ea6b3398b96bc58b8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-murmurhash@0.28:1.0", type=("build", "run")) depends_on("py-cymem@2.0.2:2.0", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-thop/package.py b/var/spack/repos/builtin/packages/py-thop/package.py index d45ef6b0152be2..7e74efa8b85991 100644 --- a/var/spack/repos/builtin/packages/py-thop/package.py +++ b/var/spack/repos/builtin/packages/py-thop/package.py @@ -18,7 +18,6 @@ class PyThop(PythonPackage): version( "0.1.1.post2209072238", sha256="01473c225231927d2ad718351f78ebf7cffe6af3bed464c4f1ba1ef0f7cdda27", - expand=False, ) depends_on("py-torch", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-tifffile/package.py b/var/spack/repos/builtin/packages/py-tifffile/package.py index ed0942d8dbdb15..11b0077542bc0c 100644 --- a/var/spack/repos/builtin/packages/py-tifffile/package.py +++ b/var/spack/repos/builtin/packages/py-tifffile/package.py @@ -31,3 +31,5 @@ class PyTifffile(PythonPackage): depends_on("py-numpy@1.19.2:", when="@2022.2.2:", type=("build", "run")) depends_on("py-numpy@1.15.1:", when="@2020.10.1:", type=("build", "run")) depends_on("py-numpy@1.8.2:", type=("build", "run")) + # https://github.com/cgohlke/tifffile/issues/252 + depends_on("py-numpy@:1", when="@:2024.4.23", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-tinyarray/package.py b/var/spack/repos/builtin/packages/py-tinyarray/package.py index 1267ff0b60a5bc..8a57abe08048a6 100644 --- a/var/spack/repos/builtin/packages/py-tinyarray/package.py +++ b/var/spack/repos/builtin/packages/py-tinyarray/package.py @@ -29,6 +29,8 @@ class PyTinyarray(PythonPackage): version("1.2.2", sha256="660d6d8532e1db5efbebae2861e5733a7082486fbdeb47d57d84b8f477d697e4") version("1.2.1", sha256="47a06f801ed4b3d438f4f7098e244cd0c6d7db09428b1bc5ee813e52234dee9f") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") # See https://gitlab.kwant-project.org/kwant/tinyarray/-/merge_requests/14 diff --git a/var/spack/repos/builtin/packages/py-tokenizers/package.py b/var/spack/repos/builtin/packages/py-tokenizers/package.py index 8a5b4a88a9f6ca..4ff2c87d319725 100644 --- a/var/spack/repos/builtin/packages/py-tokenizers/package.py +++ b/var/spack/repos/builtin/packages/py-tokenizers/package.py @@ -13,6 +13,7 @@ class PyTokenizers(PythonPackage): homepage = "https://github.com/huggingface/tokenizers" pypi = "tokenizers/tokenizers-0.6.0.tar.gz" + version("0.19.1", sha256="ee59e6680ed0fdbe6b724cf38bd70400a0c1dd623b07ac729087270caeac88e3") version("0.15.0", sha256="10c7e6e7b4cabd757da59e93f5f8d1126291d16f8b54f28510825ef56a3e5d0e") version("0.13.3", sha256="2e546dbb68b623008a5442353137fbb0123d311a6d7ba52f2667c8862a75af2e") version("0.13.1", sha256="3333d1cee5c8f47c96362ea0abc1f81c77c9b92c6c3d11cbf1d01985f0d5cf1d") diff --git a/var/spack/repos/builtin/packages/py-tomopy/package.py b/var/spack/repos/builtin/packages/py-tomopy/package.py index 3940c9a9dbf349..ffbd7416d08008 100644 --- a/var/spack/repos/builtin/packages/py-tomopy/package.py +++ b/var/spack/repos/builtin/packages/py-tomopy/package.py @@ -21,6 +21,9 @@ class PyTomopy(PythonPackage): version("1.11.0", sha256="4e5691c2b083753692ba4376ce301578037071c83fc61a6ae9e5bc9e6fcd3d1f") version("1.0.0", sha256="ee45f7a062e5a66d6f18a904d2e204e48d85a1ce1464156f9e2f6353057dfe4c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # GPU accel needs PTL which is a git submodule. Thus, we can only build it on master depends_on("cuda", when="@master") # The shared opencv is not found by during runtest. Not using GOT/PLT is faster too diff --git a/var/spack/repos/builtin/packages/py-torch-cluster/package.py b/var/spack/repos/builtin/packages/py-torch-cluster/package.py index feb225ff9a5945..2843481d150af5 100644 --- a/var/spack/repos/builtin/packages/py-torch-cluster/package.py +++ b/var/spack/repos/builtin/packages/py-torch-cluster/package.py @@ -7,40 +7,32 @@ class PyTorchCluster(PythonPackage): - """This package consists of a small extension library of highly optimized graph cluster - algorithms for the use in PyTorch. - """ + """PyTorch Extension Library of Optimized Graph Cluster Algorithms.""" homepage = "https://github.com/rusty1s/pytorch_cluster" - url = "https://github.com/rusty1s/pytorch_cluster/archive/1.5.7.tar.gz" + pypi = "torch-cluster/torch_cluster-1.6.3.tar.gz" + git = "https://github.com/rusty1s/pytorch_cluster.git" license("MIT") + maintainers("adamjstewart") - version("1.6.3", sha256="0e2b08095e03cf87ce9b23b7a7352236a25d3ed92d92351dc020fd927ea8dbfe") - version("1.5.8", sha256="95c6e81e9c4a6235e1b2152ab917021d2060ad995199f6bd7fb39986d37310f0") - version("1.5.7", sha256="71701d2f7f3e458ebe5904c982951349fdb60e6f1654e19c7e102a226e2de72e") + version("1.6.3", sha256="78d5a930a5bbd0d8788df8c6d66addd68d6dd292fe3edb401e3dacba26308152") - variant("cuda", default=False, description="Enables CUDA support") + depends_on("cxx", type="build") # generated + depends_on("python", type=("build", "link", "run")) depends_on("py-setuptools", type="build") depends_on("py-scipy", type=("build", "run")) - depends_on("py-torch+cuda", when="+cuda", type=("build", "link", "run")) - depends_on("py-torch~cuda", when="~cuda", type=("build", "link", "run")) - # https://github.com/rusty1s/pytorch_cluster/issues/120 - depends_on("py-torch~openmp", when="@:1.5 %apple-clang", type=("build", "link", "run")) - - # Historical dependencies - depends_on("py-pytest-runner", when="@:1.5", type="build") + # Undocumented dependencies + depends_on("py-torch", type=("build", "link", "run")) def setup_build_environment(self, env): - if "+cuda" in self.spec: - cuda_arches = list(self.spec["py-torch"].variants["cuda_arch"].value) - for i, x in enumerate(cuda_arches): - cuda_arches[i] = "{0}.{1}".format(x[0:-1], x[-1]) - env.set("TORCH_CUDA_ARCH_LIST", str.join(" ", cuda_arches)) - - env.set("FORCE_CUDA", "1") - env.set("CUDA_HOME", self.spec["cuda"].prefix) + if "+cuda" in self.spec["py-torch"]: + env.set("FORCE_CUDA", 1) + env.set("FORCE_ONLY_CUDA", 0) + env.set("FORCE_ONLY_CPU", 0) else: - env.set("FORCE_CUDA", "0") + env.set("FORCE_CUDA", 0) + env.set("FORCE_ONLY_CUDA", 0) + env.set("FORCE_ONLY_CPU", 1) diff --git a/var/spack/repos/builtin/packages/py-torch-geometric/package.py b/var/spack/repos/builtin/packages/py-torch-geometric/package.py index 89b5ffe181cb78..4d5c5dcff4776a 100644 --- a/var/spack/repos/builtin/packages/py-torch-geometric/package.py +++ b/var/spack/repos/builtin/packages/py-torch-geometric/package.py @@ -8,76 +8,30 @@ class PyTorchGeometric(PythonPackage): - """PyTorch Geometric (PyG) is a geometric deep learning extension - library for PyTorch. It consists of various methods for deep - learning on graphs and other irregular structures, also known as - geometric deep learning, from a variety of published papers. In - addition, it consists of an easy-to-use mini-batch loader for many - small and single giant graphs, multi gpu-support, a large number - of common benchmark datasets (based on simple interfaces to create - your own), and helpful transforms, both for learning on arbitrary - graphs as well as on 3D meshes or point clouds.""" + """Graph Neural Network Library for PyTorch.""" - homepage = "https://github.com/pyg-team/pytorch_geometric" - pypi = "torch-geometric/torch_geometric-2.1.0.post1.tar.gz" + homepage = "https://pyg.org/" + pypi = "torch-geometric/torch_geometric-2.5.3.tar.gz" + git = "https://github.com/pyg-team/pytorch_geometric.git" license("MIT") - - version( - "2.1.0.post1", sha256="32347402076ccf60fa50312825178f1e3e5ce5e7b3b3a8b2729ac699da24525d" - ) - version("1.6.3", sha256="347f693bebcc8a621eda4867dafab91c04db5f596d7ed7ecb89b242f8ab5c6a1") - version("1.6.0", sha256="fbf43fe15421c9affc4fb361ba4db55cb9d3c64d0c29576bb58d332bf6d27fef") - - variant("cuda", default=False, description="Enable CUDA support") - - # setup.py - depends_on("python@3.7:", when="@2:", type=("build", "run")) - depends_on("python@3.6:", type=("build", "run")) - depends_on("py-setuptools", type="build") - depends_on("py-tqdm", type=("build", "run")) - depends_on("py-numpy", type=("build", "run")) - depends_on("py-scipy", type=("build", "run")) - depends_on("py-jinja2", type=("build", "run")) - depends_on("py-requests", type=("build", "run")) - depends_on("py-pyparsing", when="@2:", type=("build", "run")) - depends_on("py-scikit-learn", type=("build", "run")) - - # README.md - depends_on("py-torch-scatter+cuda", when="+cuda", type=("build", "run")) - depends_on("py-torch-scatter~cuda", when="~cuda", type=("build", "run")) - depends_on("py-torch-sparse+cuda", when="+cuda", type=("build", "run")) - depends_on("py-torch-sparse~cuda", when="~cuda", type=("build", "run")) - - # Optional dependencies - depends_on("py-torch-cluster+cuda", when="+cuda", type=("build", "run")) - depends_on("py-torch-cluster~cuda", when="~cuda", type=("build", "run")) - depends_on("py-torch-spline-conv+cuda", when="+cuda", type=("build", "run")) - depends_on("py-torch-spline-conv~cuda", when="~cuda", type=("build", "run")) - - # Undocumented dependencies - depends_on("py-torch", type=("build", "run")) - - # Historic or optional dependencies - with when("@:1"): - depends_on("py-pytest-runner", type="build") - depends_on("py-networkx", type=("build", "run")) - depends_on("py-python-louvain", type=("build", "run"), when="@1.6.2:") - depends_on("py-numba", type=("build", "run")) - depends_on("py-pandas", type=("build", "run")) - depends_on("py-rdflib", type=("build", "run")) - depends_on("py-googledrivedownloader", type=("build", "run")) - depends_on("py-h5py~mpi", type=("build", "run")) - depends_on("py-ase", type=("build", "run")) - - def setup_build_environment(self, env): - if "+cuda" in self.spec: - cuda_arches = list(self.spec["py-torch"].variants["cuda_arch"].value) - for i, x in enumerate(cuda_arches): - cuda_arches[i] = "{0}.{1}".format(x[0:-1], x[-1]) - env.set("TORCH_CUDA_ARCH_LIST", str.join(" ", cuda_arches)) - - env.set("FORCE_CUDA", "1") - env.set("CUDA_HOME", self.spec["cuda"].prefix) - else: - env.set("FORCE_CUDA", "0") + maintainers("adamjstewart") + + version("2.5.3", sha256="ad0761650c8fa56cdc46ee61c564fd4995f07f079965fe732b3a76d109fd3edc") + + depends_on("py-flit-core@3.2:3", type="build") + + with default_args(type=("build", "run")): + depends_on("py-tqdm") + depends_on("py-numpy") + depends_on("py-scipy") + depends_on("py-fsspec") + depends_on("py-jinja2") + depends_on("py-aiohttp") + depends_on("py-requests") + depends_on("py-pyparsing") + depends_on("py-scikit-learn") + depends_on("py-psutil@5.8:") + + # Undocumented dependencies + depends_on("py-torch") diff --git a/var/spack/repos/builtin/packages/py-torch-nvidia-apex/package.py b/var/spack/repos/builtin/packages/py-torch-nvidia-apex/package.py index 45f9b279cb2b90..385fc7d0c4f7af 100644 --- a/var/spack/repos/builtin/packages/py-torch-nvidia-apex/package.py +++ b/var/spack/repos/builtin/packages/py-torch-nvidia-apex/package.py @@ -19,8 +19,11 @@ class PyTorchNvidiaApex(PythonPackage, CudaPackage): version("master", branch="master") version("2020-10-19", commit="8a1ed9e8d35dfad26fb973996319965e4224dcdd") + depends_on("cxx", type="build") # generated + depends_on("python@3:", type=("build", "run")) depends_on("py-setuptools", type="build") + depends_on("py-packaging", type="build") depends_on("py-torch@0.4:", type=("build", "run")) depends_on("cuda@9:", when="+cuda") depends_on("py-pybind11", type=("build", "link", "run")) @@ -34,15 +37,10 @@ class PyTorchNvidiaApex(PythonPackage, CudaPackage): def setup_build_environment(self, env): if "+cuda" in self.spec: env.set("CUDA_HOME", self.spec["cuda"].prefix) - if self.spec.variants["cuda_arch"].value[0] != "none": - torch_cuda_arch = ";".join( - "{0:.1f}".format(float(i) / 10.0) - for i in self.spec.variants["cuda_arch"].value - ) - env.set("TORCH_CUDA_ARCH_LIST", torch_cuda_arch) else: env.unset("CUDA_HOME") + @when("^python@:3.10") def global_options(self, spec, prefix): args = [] if spec.satisfies("^py-torch@1.0:"): @@ -50,3 +48,11 @@ def global_options(self, spec, prefix): if "+cuda" in spec: args.append("--cuda_ext") return args + + @when("^python@3.11:") + def config_settings(self, spec, prefix): + return { + "builddir": "build", + "compile-args": f"-j{make_jobs}", + "--global-option": "--cpp_ext --cuda_ext", + } diff --git a/var/spack/repos/builtin/packages/py-torch-scatter/package.py b/var/spack/repos/builtin/packages/py-torch-scatter/package.py index 52804ef4b67feb..0e9589618d3fff 100644 --- a/var/spack/repos/builtin/packages/py-torch-scatter/package.py +++ b/var/spack/repos/builtin/packages/py-torch-scatter/package.py @@ -7,34 +7,31 @@ class PyTorchScatter(PythonPackage): - """This package consists of a small extension library of - highly optimized sparse update (scatter and segment) - operations for the use in PyTorch, which are missing in the - main package.""" + """PyTorch Extension Library of Optimized Scatter Operations.""" homepage = "https://github.com/rusty1s/pytorch_scatter" - url = "https://github.com/rusty1s/pytorch_scatter/archive/2.0.5.tar.gz" + pypi = "torch-scatter/torch_scatter-2.1.2.tar.gz" + git = "https://github.com/rusty1s/pytorch_scatter.git" license("MIT") + maintainers("adamjstewart") - version("2.0.5", sha256="e29b364beaa9c84a99e0e236be89ed19d4452d89010ff736184ddcce488b47f6") + version("2.1.2", sha256="69b3aa435f2424ac6a1bfb6ff702da6eb73b33ca0db38fb26989c74159258e47") - variant("cuda", default=False, description="Enable CUDA support") + depends_on("cxx", type="build") # generated - depends_on("python@3.6:", type=("build", "run")) + depends_on("python", type=("build", "link", "run")) depends_on("py-setuptools", type="build") - depends_on("py-pytest-runner", type="build") - depends_on("py-torch+cuda", when="+cuda") - depends_on("py-torch~cuda", when="~cuda") + + # Undocumented dependencies + depends_on("py-torch", type=("build", "link", "run")) def setup_build_environment(self, env): - if "+cuda" in self.spec: - cuda_arches = list(self.spec["py-torch"].variants["cuda_arch"].value) - for i, x in enumerate(cuda_arches): - cuda_arches[i] = "{0}.{1}".format(x[0:-1], x[-1]) - env.set("TORCH_CUDA_ARCH_LIST", str.join(" ", cuda_arches)) - - env.set("FORCE_CUDA", "1") - env.set("CUDA_HOME", self.spec["cuda"].prefix) + if "+cuda" in self.spec["py-torch"]: + env.set("FORCE_CUDA", 1) + env.set("FORCE_ONLY_CUDA", 0) + env.set("FORCE_ONLY_CPU", 0) else: - env.set("FORCE_CUDA", "0") + env.set("FORCE_CUDA", 0) + env.set("FORCE_ONLY_CUDA", 0) + env.set("FORCE_ONLY_CPU", 1) diff --git a/var/spack/repos/builtin/packages/py-torch-sparse/package.py b/var/spack/repos/builtin/packages/py-torch-sparse/package.py index 8a1ed1a57d02e1..c05ce351095153 100644 --- a/var/spack/repos/builtin/packages/py-torch-sparse/package.py +++ b/var/spack/repos/builtin/packages/py-torch-sparse/package.py @@ -7,36 +7,56 @@ class PyTorchSparse(PythonPackage): - """This package consists of a small extension library of - optimized sparse matrix operations with autograd support.""" + """PyTorch Extension Library of Optimized Autograd Sparse Matrix Operations.""" - homepage = "https://github.com/rusty1s/pytorch_sparse/" - url = "https://github.com/rusty1s/pytorch_sparse/archive/0.6.7.tar.gz" + homepage = "https://github.com/rusty1s/pytorch_sparse" + pypi = "torch-sparse/torch_sparse-0.6.18.tar.gz" + git = "https://github.com/rusty1s/pytorch_sparse.git" license("MIT") + maintainers("adamjstewart") - version("0.6.17", sha256="c964a70ed978bff65009250eb12fae96317c60c9a04d7d1b07f0beee8b4b9c22") - version("0.6.8", sha256="98f7ff1f0f9cd5031bc81c70c11970c3864545ae33677025a6efd2466a97e6f9") - version("0.6.7", sha256="0d038a1502548692972a085cd0496460b5d2050bb7328427add990f081d6c44d") + version("0.6.18", sha256="2f14c510a6e93f404c6ea357210615b3c15a71731f9dbd86f25434e34fb5a741") + version("0.6.17", sha256="06e268dd77f73eb641da8f9383306d7afac6423383c9197b9df120955e2a96bd") + version("0.6.8", sha256="312fb5ae6e4e575fca4bbc0bd092af85e7679d5b8e53459f24492fc2a073c7b6") + version("0.6.7", sha256="f69b2ed35baf2a9853234756a2b19e6f7ce88d2c1f029d1c7ca166d91e1adbd0") - variant("cuda", default=False, description="Enable CUDA support") + depends_on("cxx", type="build") # generated depends_on("py-setuptools", type="build") - depends_on("py-pytest-runner", when="@:0.6.8", type="build") depends_on("py-scipy", type=("build", "run")) - depends_on("py-torch", type=("build", "run")) - depends_on("py-torch-scatter+cuda", when="+cuda") - depends_on("py-torch-scatter~cuda", when="~cuda") + + # Undocumented dependencies + depends_on("py-torch", type=("build", "link", "run")) + depends_on("py-torch-scatter", type=("build", "run")) depends_on("parallel-hashmap", when="@0.6.17:") + # Historical dependencies + depends_on("py-pytest-runner", when="@:0.6.8", type="build") + + def patch(self): + # Force build against externally-installed hashmap + filter_file( + "include_dirs=[extensions_dir, phmap_dir]", + "include_dirs=[extensions_dir]", + "setup.py", + string=True, + ) + def setup_build_environment(self, env): - if "+cuda" in self.spec: - cuda_arches = list(self.spec["py-torch"].variants["cuda_arch"].value) - for i, x in enumerate(cuda_arches): - cuda_arches[i] = "{0}.{1}".format(x[0:-1], x[-1]) - env.set("TORCH_CUDA_ARCH_LIST", str.join(" ", cuda_arches)) - - env.set("FORCE_CUDA", "1") - env.set("CUDA_HOME", self.spec["cuda"].prefix) + if self.spec.satisfies("@0.6.9:"): + if "+cuda" in self.spec["py-torch"]: + env.set("FORCE_CUDA", 1) + env.set("FORCE_ONLY_CUDA", 0) + env.set("FORCE_ONLY_CPU", 0) + else: + env.set("FORCE_CUDA", 0) + env.set("FORCE_ONLY_CUDA", 0) + env.set("FORCE_ONLY_CPU", 1) else: - env.set("FORCE_CUDA", "0") + if "+cuda" in self.spec["py-torch"]: + env.set("FORCE_CUDA", 1) + env.set("FORCE_CPU", 0) + else: + env.set("FORCE_CUDA", 0) + env.set("FORCE_CPU", 1) diff --git a/var/spack/repos/builtin/packages/py-torch-spline-conv/package.py b/var/spack/repos/builtin/packages/py-torch-spline-conv/package.py index e1bc630e543f64..c91b4538206804 100644 --- a/var/spack/repos/builtin/packages/py-torch-spline-conv/package.py +++ b/var/spack/repos/builtin/packages/py-torch-spline-conv/package.py @@ -7,32 +7,31 @@ class PyTorchSplineConv(PythonPackage): - """This is a PyTorch implementation of the spline-based - convolution operator of SplineCNN.""" + """Implementation of the Spline-Based Convolution Operator of SplineCNN in PyTorch.""" homepage = "https://github.com/rusty1s/pytorch_spline_conv" - url = "https://github.com/rusty1s/pytorch_spline_conv/archive/1.2.0.tar.gz" + pypi = "torch-spline-conv/torch_spline_conv-1.2.2.tar.gz" + git = "https://github.com/rusty1s/pytorch_spline_conv.git" license("MIT") + maintainers("adamjstewart") - version("1.2.0", sha256="ab8da41357c8a4785662366655bb6dc5e84fd0e938008194955409aefe535009") + version("1.2.2", sha256="ed45a81da29f774665dbdd4709d7e534cdf16d2e7006dbd06957f35bd09661b2") - variant("cuda", default=False, description="Enable CUDA support") + depends_on("cxx", type="build") # generated - depends_on("python@3.6:", type=("build", "run")) + depends_on("python", type=("build", "link", "run")) depends_on("py-setuptools", type="build") - depends_on("py-pytest-runner", type="build") - depends_on("py-torch+cuda", when="+cuda") - depends_on("py-torch~cuda", when="~cuda") + + # Undocumented dependencies + depends_on("py-torch", type=("build", "link", "run")) def setup_build_environment(self, env): - if "+cuda" in self.spec: - cuda_arches = list(self.spec["py-torch"].variants["cuda_arch"].value) - for i, x in enumerate(cuda_arches): - cuda_arches[i] = "{0}.{1}".format(x[0:-1], x[-1]) - env.set("TORCH_CUDA_ARCH_LIST", str.join(" ", cuda_arches)) - - env.set("FORCE_CUDA", "1") - env.set("CUDA_HOME", self.spec["cuda"].prefix) + if "+cuda" in self.spec["py-torch"]: + env.set("FORCE_CUDA", 1) + env.set("FORCE_ONLY_CUDA", 0) + env.set("FORCE_ONLY_CPU", 0) else: - env.set("FORCE_CUDA", "0") + env.set("FORCE_CUDA", 0) + env.set("FORCE_ONLY_CUDA", 0) + env.set("FORCE_ONLY_CPU", 1) diff --git a/var/spack/repos/builtin/packages/py-torch/package.py b/var/spack/repos/builtin/packages/py-torch/package.py index 2a91f36d26069a..9a91da04336f1c 100644 --- a/var/spack/repos/builtin/packages/py-torch/package.py +++ b/var/spack/repos/builtin/packages/py-torch/package.py @@ -26,6 +26,9 @@ class PyTorch(PythonPackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("main", branch="main") + version("2.3.1", tag="v2.3.1", commit="63d5e9221bedd1546b7d364b5ce4171547db12a9") + version("2.3.0", tag="v2.3.0", commit="97ff6cfd9c86c5c09d7ce775ab64ec5c99230f5d") + version("2.2.2", tag="v2.2.2", commit="39901f229520a5256505ec24782f716ee7ddc843") version("2.2.1", tag="v2.2.1", commit="6c8c5ad5eaf47a62fafbb4a2747198cbffbf1ff0") version("2.2.0", tag="v2.2.0", commit="8ac9b20d4b090c213799e81acf48a55ea8d437d6") version("2.1.2", tag="v2.1.2", commit="a8e7c98cb95ff97bb30a728c6b2a1ce6bff946eb") @@ -53,6 +56,10 @@ class PyTorch(PythonPackage, CudaPackage, ROCmPackage): version("1.5.0", tag="v1.5.0", commit="4ff3872a2099993bf7e8c588f7182f3df777205b") version("1.4.1", tag="v1.4.1", commit="74044638f755cd8667bedc73da4dbda4aa64c948") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + is_darwin = sys.platform == "darwin" # All options are defined in CMakeLists.txt. @@ -74,18 +81,14 @@ class PyTorch(PythonPackage, CudaPackage, ROCmPackage): when="@1.12: platform=darwin", ) variant("nccl", default=True, description="Use NCCL", when="+cuda platform=linux") - variant("nccl", default=True, description="Use NCCL", when="+cuda platform=cray") variant("nccl", default=True, description="Use NCCL", when="+rocm platform=linux") - variant("nccl", default=True, description="Use NCCL", when="+rocm platform=cray") # Requires AVX2: https://discuss.pytorch.org/t/107518 variant("nnpack", default=True, description="Use NNPACK", when="target=x86_64_v3:") variant("numa", default=True, description="Use NUMA", when="platform=linux") - variant("numa", default=True, description="Use NUMA", when="platform=cray") variant("numpy", default=True, description="Use NumPy") variant("openmp", default=True, description="Use OpenMP for parallel code") variant("qnnpack", default=True, description="Use QNNPACK (quantized 8-bit operators)") variant("valgrind", default=True, description="Use Valgrind", when="@1.8: platform=linux") - variant("valgrind", default=True, description="Use Valgrind", when="@1.8: platform=cray") variant("xnnpack", default=True, description="Use XNNPACK", when="@1.5:") variant("mkldnn", default=True, description="Use MKLDNN") variant("distributed", default=not is_darwin, description="Use distributed") @@ -104,6 +107,10 @@ class PyTorch(PythonPackage, CudaPackage, ROCmPackage): description="Enable breakpad crash dump library", when="@1.10:1.11", ) + # py-torch has strict dependencies on old protobuf/py-protobuf versions that + # cause problems with other packages that require newer versions of protobuf + # and py-protobuf --> provide an option to use the internal/vendored protobuf. + variant("custom-protobuf", default=False, description="Use vendored protobuf") conflicts("+cuda+rocm") conflicts("+tensorpipe", when="+rocm ^hip@:5.1", msg="TensorPipe not supported until ROCm 5.2") @@ -132,89 +139,126 @@ class PyTorch(PythonPackage, CudaPackage, ROCmPackage): # Required dependencies # Based on PyPI wheel availability - depends_on("python@3.8:3.12", when="@2.2:", type=("build", "link", "run")) - depends_on("python@3.8:3.11", when="@2.0:2.1", type=("build", "link", "run")) - depends_on("python@:3.10", when="@1.11:1", type=("build", "link", "run")) - depends_on("python@:3.9", when="@1.7.1:1.10", type=("build", "link", "run")) - depends_on("python@:3.8", when="@1.4:1.7.0", type=("build", "link", "run")) + with default_args(type=("build", "link", "run")): + depends_on("python@3.8:3.12", when="@2.2:") + depends_on("python@3.8:3.11", when="@2.0:2.1") + depends_on("python@:3.10", when="@1.11:1") + depends_on("python@:3.9", when="@1.7.1:1.10") + depends_on("python@:3.8", when="@1.4:1.7.0") # CMakelists.txt - depends_on("cmake@3.18:", when="@2:", type="build") - depends_on("cmake@3.13:", when="@1.11:", type="build") - depends_on("cmake@3.10:", when="@1.10:", type="build") - depends_on("cmake@3.5:", type="build") - - # pyproject.toml - depends_on("py-setuptools", type=("build", "run")) - depends_on("py-astunparse", when="@1.13:", type=("build", "run")) - depends_on("py-numpy@1.16.6:", type=("build", "run")) - depends_on("ninja@1.5:", when="@1.1:", type="build") - depends_on("py-pyyaml", type=("build", "run")) - depends_on("py-requests", when="@1.13:", type=("build", "run")) - depends_on("py-cffi", when="@:1", type=("build", "run")) - depends_on("py-future", when="@1.5:1", type=("build", "run")) - depends_on("py-six", when="@1.13:1", type=("build", "run")) - - # setup.py - depends_on("py-filelock", when="@2:", type=("build", "run")) - depends_on("py-typing-extensions@4.8:", when="@2.2:", type=("build", "run")) - depends_on("py-typing-extensions@3.6.2.1:", when="@1.7:", type=("build", "run")) - depends_on("py-sympy", when="@2:", type=("build", "run")) - depends_on("py-networkx", when="@2:", type=("build", "run")) - depends_on("py-jinja2", when="@2:", type=("build", "run")) - depends_on("py-fsspec", when="@2.1:", type=("build", "run")) + with default_args(type="build"): + depends_on("cmake@3.18:", when="@2:") + depends_on("cmake@3.13:", when="@1.11:") + depends_on("cmake@3.10:", when="@1.10:") + depends_on("cmake@3.5:") + depends_on("ninja@1.5:") + + with default_args(type=("build", "run")): + # setup.py + depends_on("py-filelock", when="@2:") + depends_on("py-typing-extensions@4.8:", when="@2.2:") + depends_on("py-typing-extensions@3.6.2.1:", when="@1.7:") + depends_on("py-sympy", when="@2:") + depends_on("py-networkx", when="@2:") + depends_on("py-jinja2", when="@2:") + depends_on("py-fsspec", when="@2.1:") + depends_on("mkl@2021.1.1:2021.4.0", when="@2.3: platform=windows") + + # pyproject.toml + depends_on("py-setuptools") + depends_on("py-astunparse", when="@1.13:") + depends_on("py-numpy@1.16.6:") + # https://github.com/pytorch/pytorch/issues/107302 + depends_on("py-numpy@:1", when="@:2.2") + depends_on("py-pyyaml") + depends_on("py-requests", when="@1.13:") # Undocumented dependencies depends_on("py-tqdm", type="run") depends_on("blas") depends_on("lapack") - # third_party - depends_on("py-pybind11@2.11.0", when="@2.1:", type=("build", "link", "run")) - depends_on("py-pybind11@2.10.1", when="@2.0", type=("build", "link", "run")) - depends_on("py-pybind11@2.10.0", when="@1.13:1", type=("build", "link", "run")) - depends_on("py-pybind11@2.6.2", when="@1.8:1.12", type=("build", "link", "run")) - depends_on("py-pybind11@2.3.0", when="@:1.7", type=("build", "link", "run")) - depends_on("py-protobuf@3.12.2:", when="@1.10:", type=("build", "run")) - depends_on("py-protobuf@:3.14", when="@:1.9", type=("build", "run")) - depends_on("protobuf@3.12.2:", when="@1.10:") - depends_on("protobuf@:3.14", when="@:1.9") - # https://github.com/protocolbuffers/protobuf/issues/10051 - # https://github.com/pytorch/pytorch/issues/78362 - depends_on("py-protobuf@:3", type=("build", "run")) - depends_on("protobuf@:3", type=("build", "run")) - depends_on("eigen") - # https://github.com/pytorch/pytorch/issues/60329 - # depends_on("cpuinfo@2023-01-13", when="@2.1:") - # depends_on("cpuinfo@2022-08-19", when="@1.13:2.0") - # depends_on("cpuinfo@2020-12-17", when="@1.8:1.12") - # depends_on("cpuinfo@2020-06-11", when="@1.6:1.7") - depends_on("sleef@3.5.1_2020-12-22", when="@1.8:") - depends_on("sleef@3.4.0_2019-07-30", when="@1.6:1.7") + # Third party dependencies depends_on("fp16@2020-05-14", when="@1.6:") + depends_on("fxdiv@2020-04-17", when="@1.6:") + # https://github.com/pytorch/pytorch/issues/60332 + # depends_on("xnnpack@2024-02-29", when="@2.3:+xnnpack") + # depends_on("xnnpack@2022-12-21", when="@2.0:2.2+xnnpack") + # depends_on("xnnpack@2022-02-16", when="@1.12:1+xnnpack") + # depends_on("xnnpack@2021-06-21", when="@1.10:1.11+xnnpack") + # depends_on("xnnpack@2021-02-22", when="@1.8:1.9+xnnpack") + # depends_on("xnnpack@2020-03-23", when="@1.6:1.7+xnnpack") + depends_on("benchmark", when="@1.6:+test") + depends_on("cpuinfo@2023-11-04", when="@2.3:") + depends_on("cpuinfo@2023-01-13", when="@2.1:2.2") + depends_on("cpuinfo@2022-08-19", when="@1.13:2.0") + depends_on("cpuinfo@2020-12-17", when="@1.8:1.12") + depends_on("cpuinfo@2020-06-11", when="@1.6:1.7") + depends_on("eigen") + depends_on("gloo@2023-12-03", when="@2.3:+gloo") + depends_on("gloo@2023-05-19", when="@2.1:2.2+gloo") + depends_on("gloo@2023-01-17", when="@2.0+gloo") + depends_on("gloo@2022-05-18", when="@1.13:1+gloo") + depends_on("gloo@2021-05-21", when="@1.10:1.12+gloo") + depends_on("gloo@2021-05-04", when="@1.9+gloo") + depends_on("gloo@2020-09-18", when="@1.7:1.8+gloo") + depends_on("gloo@2020-03-17", when="@1.6+gloo") + depends_on("gloo+cuda", when="@1.6:+gloo+cuda") + depends_on("nccl", when="+nccl+cuda") + # https://github.com/pytorch/pytorch/issues/60331 + # depends_on("onnx@1.16.0", when="@2.3:+onnx_ml") + # depends_on("onnx@1.15.0", when="@2.2+onnx_ml") + # depends_on("onnx@1.14.1", when="@2.1+onnx_ml") + # depends_on("onnx@1.13.1", when="@2.0+onnx_ml") + # depends_on("onnx@1.12.0", when="@1.13:1+onnx_ml") + # depends_on("onnx@1.11.0", when="@1.12+onnx_ml") + # depends_on("onnx@1.10.1_2021-10-08", when="@1.11+onnx_ml") + # depends_on("onnx@1.10.1", when="@1.10+onnx_ml") + # depends_on("onnx@1.8.0_2020-11-03", when="@1.8:1.9+onnx_ml") + # depends_on("onnx@1.7.0_2020-05-31", when="@1.6:1.7+onnx_ml") + with when("~custom-protobuf"): + depends_on("protobuf@3.13.0", when="@1.10:") + depends_on("protobuf@3.11.4", when="@1.6:1.9") + depends_on("protobuf@3.6.1", when="@1.1:1.5") + depends_on("protobuf@3.5.0", when="@1.0") + with default_args(type=("build", "run")): + depends_on("py-protobuf@3.13", when="@1.10:") + depends_on("py-protobuf@3.11", when="@1.6:1.9") + depends_on("py-protobuf@3.6", when="@1.1:1.5") + depends_on("py-protobuf@3.5", when="@1.0") + depends_on("psimd@2020-05-17", when="@1.6:") depends_on("pthreadpool@2023-08-29", when="@2.2:") depends_on("pthreadpool@2021-04-13", when="@1.9:2.1") depends_on("pthreadpool@2020-10-05", when="@1.8") depends_on("pthreadpool@2020-06-15", when="@1.6:1.7") - depends_on("psimd@2020-05-17", when="@1.6:") - depends_on("fxdiv@2020-04-17", when="@1.6:") - depends_on("benchmark", when="@1.6:+test") + with default_args(type=("build", "link", "run")): + depends_on("py-pybind11@2.12.0", when="@2.3:") + depends_on("py-pybind11@2.11.0", when="@2.1:2.2") + depends_on("py-pybind11@2.10.1", when="@2.0") + depends_on("py-pybind11@2.10.0", when="@1.13:1") + depends_on("py-pybind11@2.6.2", when="@1.8:1.12") + depends_on("py-pybind11@2.3.0", when="@:1.7") + depends_on("sleef@3.5.1_2020-12-22", when="@1.8:") + depends_on("sleef@3.4.0_2019-07-30", when="@1.6:1.7") # Optional dependencies - # cmake/public/cuda.cmake - depends_on("cuda@11:", when="@2:+cuda", type=("build", "link", "run")) - depends_on("cuda@10.2:", when="@1.11:1+cuda", type=("build", "link", "run")) - # https://discuss.pytorch.org/t/compiling-1-10-1-from-source-with-gcc-11-and-cuda-11-5/140971 - depends_on("cuda@10.2:11.4", when="@1.10+cuda", type=("build", "link", "run")) - depends_on("cuda@9.2:11.4", when="@1.6:1.9+cuda", type=("build", "link", "run")) - depends_on("cuda@9:11.4", when="@:1.5+cuda", type=("build", "link", "run")) + with default_args(type=("build", "link", "run")): + # cmake/public/cuda.cmake + # https://github.com/pytorch/pytorch/issues/122169 + depends_on("cuda@11:12.3", when="@2:+cuda") + depends_on("cuda@10.2:12.3", when="@1.11:1+cuda") + # https://discuss.pytorch.org/t/compiling-1-10-1-from-source-with-gcc-11-and-cuda-11-5/140971 + depends_on("cuda@10.2:11.4", when="@1.10+cuda") + depends_on("cuda@9.2:11.4", when="@1.6:1.9+cuda") + depends_on("cuda@9:11.4", when="@:1.5+cuda") # https://github.com/pytorch/pytorch#prerequisites - depends_on("cudnn@8.5:", when="@2.3:+cudnn") - depends_on("cudnn@7:", when="@1.6:+cudnn") + # https://github.com/pytorch/pytorch/issues/119400 + depends_on("cudnn@8.5:9.0", when="@2.3:+cudnn") + depends_on("cudnn@7:8", when="@1.6:2.2+cudnn") depends_on("cudnn@7", when="@:1.5+cudnn") depends_on("magma+cuda", when="+magma+cuda") depends_on("magma+rocm", when="+magma+rocm") - depends_on("nccl", when="+nccl+cuda") depends_on("numactl", when="+numa") depends_on("llvm-openmp", when="%apple-clang +openmp") depends_on("valgrind", when="+valgrind") @@ -233,37 +277,20 @@ class PyTorch(PythonPackage, CudaPackage, ROCmPackage): depends_on("rocblas") depends_on("miopen-hip") depends_on("rocminfo") - # https://github.com/pytorch/pytorch/issues/60332 - # depends_on("xnnpack@2022-12-21", when="@2:+xnnpack") - # depends_on("xnnpack@2022-02-16", when="@1.12:1+xnnpack") - # depends_on("xnnpack@2021-06-21", when="@1.10:1.11+xnnpack") - # depends_on("xnnpack@2021-02-22", when="@1.8:1.9+xnnpack") - # depends_on("xnnpack@2020-03-23", when="@1.6:1.7+xnnpack") depends_on("mpi", when="+mpi") - depends_on("gloo@2023-05-19", when="@2.1:+gloo") - depends_on("gloo@2023-01-17", when="@2.0+gloo") - depends_on("gloo@2022-05-18", when="@1.13:1+gloo") - depends_on("gloo@2021-05-21", when="@1.10:1.12+gloo") - depends_on("gloo@2021-05-04", when="@1.9+gloo") - depends_on("gloo@2020-09-18", when="@1.7:1.8+gloo") - depends_on("gloo@2020-03-17", when="@1.6+gloo") - depends_on("gloo+cuda", when="@1.6:+gloo+cuda") - # https://github.com/pytorch/pytorch/issues/60331 - # depends_on("onnx@1.15.0", when="@2.2:+onnx_ml") - # depends_on("onnx@1.14.1", when="@2.1+onnx_ml") - # depends_on("onnx@1.13.1", when="@2.0+onnx_ml") - # depends_on("onnx@1.12.0", when="@1.13:1+onnx_ml") - # depends_on("onnx@1.11.0", when="@1.12+onnx_ml") - # depends_on("onnx@1.10.1_2021-10-08", when="@1.11+onnx_ml") - # depends_on("onnx@1.10.1", when="@1.10+onnx_ml") - # depends_on("onnx@1.8.0_2020-11-03", when="@1.8:1.9+onnx_ml") - # depends_on("onnx@1.7.0_2020-05-31", when="@1.6:1.7+onnx_ml") depends_on("mkl", when="+mkldnn") # Test dependencies - depends_on("py-hypothesis", type="test") - depends_on("py-six", type="test") - depends_on("py-psutil", type="test") + with default_args(type="test"): + depends_on("py-hypothesis") + depends_on("py-six") + depends_on("py-psutil") + + # Historical dependencies + with default_args(type=("build", "run")): + depends_on("py-cffi", when="@:1") + depends_on("py-future", when="@1.5:1") + depends_on("py-six", when="@1.13:1") conflicts("%gcc@:9.3", when="@2.2:", msg="C++17 support required") @@ -458,6 +485,13 @@ def patch(self): "caffe2/CMakeLists.txt", ) + def torch_cuda_arch_list(self, env): + if "+cuda" in self.spec: + torch_cuda_arch = ";".join( + "{0:.1f}".format(float(i) / 10.0) for i in self.spec.variants["cuda_arch"].value + ) + env.set("TORCH_CUDA_ARCH_LIST", torch_cuda_arch) + def setup_build_environment(self, env): """Set environment variables used to control the build. @@ -500,10 +534,8 @@ def enable_or_disable(variant, keyword="USE", var=None): if "+cuda" in self.spec: env.set("CUDA_HOME", self.spec["cuda"].prefix) # Linux/macOS env.set("CUDA_PATH", self.spec["cuda"].prefix) # Windows - torch_cuda_arch = ";".join( - "{0:.1f}".format(float(i) / 10.0) for i in self.spec.variants["cuda_arch"].value - ) - env.set("TORCH_CUDA_ARCH_LIST", torch_cuda_arch) + self.torch_cuda_arch_list(env) + if self.spec.satisfies("%clang"): for flag in self.spec.compiler_flags["cxxflags"]: if "gcc-toolchain" in flag: @@ -623,33 +655,38 @@ def enable_or_disable(variant, keyword="USE", var=None): env.set("WITH_BLAS", "generic") # Don't use vendored third-party libraries when possible - env.set("BUILD_CUSTOM_PROTOBUF", "OFF") - env.set("USE_SYSTEM_NCCL", "ON") + # env.set("USE_SYSTEM_LIBS", "ON") + env.set("USE_SYSTEM_BENCHMARK", "ON") + env.set("USE_SYSTEM_CPUINFO", "ON") env.set("USE_SYSTEM_EIGEN_INSTALL", "ON") - env.set("pybind11_DIR", self.spec["py-pybind11"].prefix) - env.set("pybind11_INCLUDE_DIR", self.spec["py-pybind11"].prefix.include) - if self.spec.satisfies("@1.10:"): - env.set("USE_SYSTEM_PYBIND11", "ON") - if self.spec.satisfies("@1.6:"): - # env.set("USE_SYSTEM_LIBS", "ON") - # https://github.com/pytorch/pytorch/issues/60329 - # env.set("USE_SYSTEM_CPUINFO", "ON") - env.set("USE_SYSTEM_SLEEF", "ON") - env.set("USE_SYSTEM_GLOO", "ON") - env.set("USE_SYSTEM_FP16", "ON") - env.set("USE_SYSTEM_PTHREADPOOL", "ON") - env.set("USE_SYSTEM_PSIMD", "ON") - env.set("USE_SYSTEM_FXDIV", "ON") - env.set("USE_SYSTEM_BENCHMARK", "ON") - # https://github.com/pytorch/pytorch/issues/60331 - # env.set("USE_SYSTEM_ONNX", "ON") - # https://github.com/pytorch/pytorch/issues/60332 - # env.set("USE_SYSTEM_XNNPACK", "ON") + env.set("USE_SYSTEM_FP16", "ON") + env.set("USE_SYSTEM_FXDIV", "ON") + env.set("USE_SYSTEM_GLOO", "ON") + env.set("USE_SYSTEM_NCCL", "ON") + # https://github.com/pytorch/pytorch/issues/60331 + # env.set("USE_SYSTEM_ONNX", "ON") + env.set("USE_SYSTEM_PSIMD", "ON") + env.set("USE_SYSTEM_PTHREADPOOL", "ON") + env.set("USE_SYSTEM_PYBIND11", "ON") + env.set("USE_SYSTEM_SLEEF", "ON") + # env.set("USE_SYSTEM_TBB", "ON") + # env.set("USE_SYSTEM_UCC", "ON") + # https://github.com/pytorch/pytorch/issues/60332 + # env.set("USE_SYSTEM_XNNPACK", "ON") + # env.set("USE_SYSTEM_ZSTD", "ON") + + if self.spec.satisfies("+custom-protobuf"): + env.set("BUILD_CUSTOM_PROTOBUF", "ON") + else: + env.set("BUILD_CUSTOM_PROTOBUF", "OFF") # https://github.com/pytorch/pytorch/issues/111086 if self.spec.satisfies("%apple-clang@15:"): env.append_flags("LDFLAGS", "-Wl,-ld_classic") + def setup_run_environment(self, env): + self.torch_cuda_arch_list(env) + @run_before("install") def build_amd(self): if "+rocm" in self.spec: @@ -663,7 +700,5 @@ def install_test(self): @property def cmake_prefix_paths(self): - cmake_prefix_paths = [ - join_path(self.prefix, self.spec["python"].package.platlib, "torch", "share", "cmake") - ] + cmake_prefix_paths = [join_path(python_platlib, "torch", "share", "cmake")] return cmake_prefix_paths diff --git a/var/spack/repos/builtin/packages/py-torchaudio/package.py b/var/spack/repos/builtin/packages/py-torchaudio/package.py index 8c12089e15e020..f7ac883ac7918e 100644 --- a/var/spack/repos/builtin/packages/py-torchaudio/package.py +++ b/var/spack/repos/builtin/packages/py-torchaudio/package.py @@ -15,8 +15,12 @@ class PyTorchaudio(PythonPackage): submodules = True license("BSD-2-Clause") + maintainers("adamjstewart") version("main", branch="main") + version("2.3.1", tag="v2.3.1", commit="3edcf69e78a3c9a3077a11159861422440ec7d4a") + version("2.3.0", tag="v2.3.0", commit="952ea7457bcc3ed0669e7741ff23015c426d6322") + version("2.2.2", tag="v2.2.2", commit="cefdb369247668e1dba74de503d4d996124b6b11") version("2.2.1", tag="v2.2.1", commit="06ea59c97d56868e487490702d01b3cf59103b9c") version("2.2.0", tag="v2.2.0", commit="08901ade5d17d3e3cf6fc039cbd601cbd2853686") version("2.1.2", tag="v2.1.2", commit="c4c1957d24b423200fd83591d46066135979a5a8") @@ -44,6 +48,9 @@ class PyTorchaudio(PythonPackage): version("0.5.0", tag="v0.5.0", commit="09494ea545738538f9db2dceeffe10d421060ee5") version("0.4.0", tag="v0.4.0", commit="8afed303af3de41f3586007079c0534543c8f663") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + with default_args(type=("build", "link", "run")): # Based on PyPI wheel availability depends_on("python@3.8:3.12", when="@2.2:") @@ -53,6 +60,9 @@ class PyTorchaudio(PythonPackage): depends_on("python@:3.8", when="@:0.7.0") depends_on("py-torch@main", when="@main") + depends_on("py-torch@2.3.1", when="@2.3.1") + depends_on("py-torch@2.3.0", when="@2.3.0") + depends_on("py-torch@2.2.2", when="@2.2.2") depends_on("py-torch@2.2.1", when="@2.2.1") depends_on("py-torch@2.2.0", when="@2.2.0") depends_on("py-torch@2.1.2", when="@2.1.2") @@ -97,11 +107,6 @@ def setup_build_environment(self, env): if "+cuda" in self.spec["py-torch"]: env.set("USE_CUDA", 1) - torch_cuda_arch_list = ";".join( - "{0:.1f}".format(float(i) / 10.0) - for i in self.spec["py-torch"].variants["cuda_arch"].value - ) - env.set("TORCH_CUDA_ARCH_LIST", torch_cuda_arch_list) else: env.set("USE_CUDA", 0) diff --git a/var/spack/repos/builtin/packages/py-torchdata/package.py b/var/spack/repos/builtin/packages/py-torchdata/package.py index 244621dac61f61..8ace2d51ff474a 100644 --- a/var/spack/repos/builtin/packages/py-torchdata/package.py +++ b/var/spack/repos/builtin/packages/py-torchdata/package.py @@ -28,6 +28,8 @@ class PyTorchdata(PythonPackage): version("0.4.0", sha256="b4ec446a701680faa620fcb828b98ba36a63fa79da62a1e568d4a683889172da") version("0.3.0", sha256="ac36188bf133cf5f1041a28ccb3ee82ba52d4b5d99617be37d64d740acd6cfd4") + depends_on("cxx", type="build") # generated + # https://github.com/pytorch/data#version-compatibility depends_on("python@3.8:3.11", when="@0.6:", type=("build", "run")) depends_on("python@3.7:3.10", when="@:0.5", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-torchgeo/package.py b/var/spack/repos/builtin/packages/py-torchgeo/package.py index b3a630274d99b2..9ebee2bdde5ae0 100644 --- a/var/spack/repos/builtin/packages/py-torchgeo/package.py +++ b/var/spack/repos/builtin/packages/py-torchgeo/package.py @@ -64,6 +64,8 @@ class PyTorchgeo(PythonPackage): depends_on("py-matplotlib@3.3:", type=("build", "run")) depends_on("py-numpy@1.19.3:", when="@0.5:", type=("build", "run")) depends_on("py-numpy@1.17.2:", type=("build", "run")) + # https://github.com/microsoft/torchgeo/pull/2151 + depends_on("py-numpy@:1", when="@:0.5", type=("build", "run")) depends_on("py-pandas@1.1.3:", when="@0.5:", type=("build", "run")) depends_on("pil@8:", when="@0.5:", type=("build", "run")) depends_on("pil@6.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-torchmetrics/package.py b/var/spack/repos/builtin/packages/py-torchmetrics/package.py index b767185185995c..122fb8c485aed9 100644 --- a/var/spack/repos/builtin/packages/py-torchmetrics/package.py +++ b/var/spack/repos/builtin/packages/py-torchmetrics/package.py @@ -16,6 +16,8 @@ class PyTorchmetrics(PythonPackage): license("Apache-2.0") + version("1.4.0", sha256="0b1e5acdcc9beb05bfe369d3d56cfa5b143f060ebfd6079d19ccc59ba46465b3") + version("1.3.2", sha256="0a67694a4c4265eeb54cda741eaf5cb1f3a71da74b7e7e6215ad156c9f2379f6") version("1.3.1", sha256="8d371f7597a1a5eb02d5f2ed59642d6fef09093926997ce91e18b1147cc8defa") version("1.3.0", sha256="e8ac3adcc61e7a847d0504b0a0e0a3b7f57796178b239c6fafb5d20c0c9460ac") version("1.2.1", sha256="217387738f84939c39b534b20d4983e737cc448d27aaa5340e0327948d97ca3e") @@ -46,17 +48,19 @@ class PyTorchmetrics(PythonPackage): depends_on("py-setuptools", type="build") # requirements/base.txt (upper bound is removed during processing) - depends_on("py-numpy@1.20.1:", when="@1:", type=("build", "run")) - depends_on("py-numpy@1.17.2:", when="@0.4:", type=("build", "run")) - depends_on("py-numpy", when="@0.3:", type=("build", "run")) - depends_on("py-packaging@17.2:", when="@1.2.1:", type=("build", "run")) - depends_on("py-packaging", when="@0.3:1.1.0", type=("build", "run")) - depends_on("py-torch@1.10:", when="@1.3:", type=("build", "run")) - depends_on("py-torch@1.8.1:", when="@0.11:", type=("build", "run")) - depends_on("py-torch@1.3.1:", type=("build", "run")) - depends_on("py-typing-extensions", when="@0.9: ^python@:3.8", type=("build", "run")) - depends_on("py-lightning-utilities@0.8:", when="@1.1:", type=("build", "run")) - depends_on("py-lightning-utilities@0.7:", when="@1:", type=("build", "run")) - - # Historical dependencies - depends_on("py-pydeprecate@0.3", when="@0.7:0.8", type=("build", "run")) + with default_args(type=("build", "run")): + depends_on("py-numpy@1.20.1:", when="@1:") + depends_on("py-numpy@1.17.2:", when="@0.4:") + depends_on("py-numpy", when="@0.3:") + depends_on("py-packaging@17.2:", when="@1.2.1:") + depends_on("py-packaging", when="@0.3:1.1.0") + depends_on("py-torch@1.10:", when="@1.3:") + depends_on("py-torch@1.8.1:", when="@0.11:") + depends_on("py-torch@1.3.1:") + depends_on("py-typing-extensions", when="@0.9: ^python@:3.8") + depends_on("py-lightning-utilities@0.8:", when="@1.1:") + depends_on("py-lightning-utilities@0.7:", when="@1:") + depends_on("py-pretty-errors@1.2.25", when="@1.4:") + + # Historical dependencies + depends_on("py-pydeprecate@0.3", when="@0.7:0.8") diff --git a/var/spack/repos/builtin/packages/py-torchtext/package.py b/var/spack/repos/builtin/packages/py-torchtext/package.py index 3ec373283bf236..95fde8068ac14e 100644 --- a/var/spack/repos/builtin/packages/py-torchtext/package.py +++ b/var/spack/repos/builtin/packages/py-torchtext/package.py @@ -19,6 +19,8 @@ class PyTorchtext(PythonPackage): license("BSD-3-Clause") version("main", branch="main") + version("0.18.0", tag="v0.18.0", commit="9bed85d7a7ae13cf8c28598a88d8e461fe1afcb4") + version("0.17.2", tag="v0.17.2", commit="5c34b86897a93ad6564543130661c260a760b356") version("0.17.1", tag="v0.17.1", commit="15e55dd73b5de8c179c7bd5cc9e2cc813830fb34") version("0.17.0", tag="v0.17.0", commit="400da5c61bab4abaaeaeca91744ca031ad9b2edf") version("0.16.2", tag="v0.16.2", commit="299b90e908c1b492139a4cf9da3912660e79a06b") @@ -40,15 +42,21 @@ class PyTorchtext(PythonPackage): version("0.6.0", tag="0.6.0", commit="3a54c7f52584f201c17ca7489b52b812152612dc") version("0.5.0", tag="0.5.0", commit="0169cde2f1d446ae886ef0be07e9a673585ed256") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + with default_args(type=("build", "link", "run")): # Based on PyPI wheel availability - depends_on("python@3.8:3.11", when="@0.15:") + depends_on("python@3.8:3.12", when="@0.17.2:") + depends_on("python@3.8:3.11", when="@0.15:0.17.1") depends_on("python@:3.10", when="@0.13:0.14") depends_on("python@:3.9", when="@0.8.1:0.12") depends_on("python@:3.8", when="@:0.8.0") # https://github.com/pytorch/text#installation depends_on("py-torch@main", when="@main") + depends_on("py-torch@2.3.0", when="@0.18.0") + depends_on("py-torch@2.2.2", when="@0.17.2") depends_on("py-torch@2.2.1", when="@0.17.1") depends_on("py-torch@2.2.0", when="@0.17.0") depends_on("py-torch@2.1.2", when="@0.16.2") diff --git a/var/spack/repos/builtin/packages/py-torchvision/package.py b/var/spack/repos/builtin/packages/py-torchvision/package.py index dda702ea43cb55..543c744ee3a31f 100644 --- a/var/spack/repos/builtin/packages/py-torchvision/package.py +++ b/var/spack/repos/builtin/packages/py-torchvision/package.py @@ -19,6 +19,9 @@ class PyTorchvision(PythonPackage): license("BSD-3-Clause") version("main", branch="main") + version("0.18.1", sha256="347d472a9ceecc44e0bee1eda140d63cfaffc74a54ec07d4b98da7698ce75516") + version("0.18.0", sha256="3e61cbac33986a862a59cd733fd65da8b2c2a6160a66556cfa0e850f62fd43c7") + version("0.17.2", sha256="0f9304acd77aafb7cfaf3fd5e318b2986ecc73547394b971d710eacd59f3e78e") version("0.17.1", sha256="a01c7bce4098c41b62cd3a08d87569113e25d12994b1370f0fd5f531952b6cef") version("0.17.0", sha256="55e395d5c7d9bf7658c82ac633cac2224aa168e1bfe8bb5b2b2a296c792a3500") version("0.16.2", sha256="8c1f2951e98d8ada6e5a468f179af4be9f56d2ebc3ab057af873da61669806d7") @@ -48,6 +51,8 @@ class PyTorchvision(PythonPackage): version("0.6.0", sha256="02de11b3abe6882de4032ce86dab9c7794cbc84369b44d04e667486580f0f1f7") version("0.5.0", sha256="eb9afc93df3d174d975ee0914057a9522f5272310b4d56c150b955c287a4d74d") + depends_on("cxx", type="build") # generated + desc = "Enable support for native encoding/decoding of {} formats in torchvision.io" variant("png", default=True, description=desc.format("PNG")) variant("jpeg", default=True, description=desc.format("JPEG")) @@ -65,6 +70,9 @@ class PyTorchvision(PythonPackage): # https://github.com/pytorch/vision#installation depends_on("py-torch@main", when="@main") + depends_on("py-torch@2.3.1", when="@0.18.1") + depends_on("py-torch@2.3.0", when="@0.18.0") + depends_on("py-torch@2.2.2", when="@0.17.2") depends_on("py-torch@2.2.1", when="@0.17.1") depends_on("py-torch@2.2.0", when="@0.17.0") depends_on("py-torch@2.1.2", when="@0.16.2") @@ -99,6 +107,8 @@ class PyTorchvision(PythonPackage): # setup.py depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) + # https://github.com/pytorch/vision/issues/8460 + depends_on("py-numpy@:1", when="@:0.18", type=("build", "run")) depends_on("pil@5.3:", when="@0.10:", type=("build", "run")) depends_on("pil@4.1.1:", type=("build", "run")) @@ -146,11 +156,6 @@ def setup_build_environment(self, env): if "^cuda" in self.spec: env.set("CUDA_HOME", self.spec["cuda"].prefix) - torch_cuda_arch_list = ";".join( - "{0:.1f}".format(float(i) / 10.0) - for i in self.spec["py-torch"].variants["cuda_arch"].value - ) - env.set("TORCH_CUDA_ARCH_LIST", torch_cuda_arch_list) for gpu in ["cuda", "mps"]: env.set(f"FORCE_{gpu.upper()}", int(f"+{gpu}" in self.spec["py-torch"])) diff --git a/var/spack/repos/builtin/packages/py-tornado/package.py b/var/spack/repos/builtin/packages/py-tornado/package.py index 61765112fed6f8..3106ffb01b63bb 100644 --- a/var/spack/repos/builtin/packages/py-tornado/package.py +++ b/var/spack/repos/builtin/packages/py-tornado/package.py @@ -22,5 +22,7 @@ class PyTornado(PythonPackage): version("5.1.1", sha256="4e5158d97583502a7e2739951553cbd88a72076f152b4b11b64b9a10c4c49409") version("4.4", sha256="3176545b6cb2966870db4def4f646da6ab7a0c19400576969c57279a7561ab02") + depends_on("c", type="build") # generated + depends_on("python@3.8:", when="@6.3:", type=("build", "run")) depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-tqdm/package.py b/var/spack/repos/builtin/packages/py-tqdm/package.py index dd379e923d8d06..f4dce81b48563b 100644 --- a/var/spack/repos/builtin/packages/py-tqdm/package.py +++ b/var/spack/repos/builtin/packages/py-tqdm/package.py @@ -12,6 +12,7 @@ class PyTqdm(PythonPackage): homepage = "https://github.com/tqdm/tqdm" pypi = "tqdm/tqdm-4.45.0.tar.gz" + version("4.66.3", sha256="23097a41eba115ba99ecae40d06444c15d1c0c698d527a01c6c8bd1c5d0647e5") version("4.66.1", sha256="d88e651f9db8d8551a62556d3cff9e3034274ca5d66e93197cf2490e2dcb69c7") version("4.65.0", sha256="1871fb68a86b8fb3b59ca4cdd3dcccbc7e6d613eeed31f4c332531977b89beb5") version("4.64.1", sha256="5f4f682a004951c1b450bc753c710e9280c5746ce6ffedee253ddbcbf54cf1e4") diff --git a/var/spack/repos/builtin/packages/py-traitlets/package.py b/var/spack/repos/builtin/packages/py-traitlets/package.py index 77537822c6e475..3a6178ce8db092 100644 --- a/var/spack/repos/builtin/packages/py-traitlets/package.py +++ b/var/spack/repos/builtin/packages/py-traitlets/package.py @@ -12,6 +12,11 @@ class PyTraitlets(PythonPackage): homepage = "https://github.com/ipython/traitlets" pypi = "traitlets/traitlets-5.0.4.tar.gz" + version("5.14.3", sha256="9ed0579d3502c94b4b3732ac120375cda96f923114522847de4b3bb98b96b6b7") + version("5.13.0", sha256="9b232b9430c8f57288c1024b34a8f0251ddcc47268927367a0dd3eeaca40deb5") + version("5.12.0", sha256="833273bf645d8ce31dcb613c56999e2e055b1ffe6d09168a164bcd91c36d5d35") + version("5.11.2", sha256="7564b5bf8d38c40fa45498072bf4dc5e8346eb087bbf1e2ae2d8774f6a0f078e") + version("5.10.1", sha256="db9c4aa58139c3ba850101913915c042bdba86f7c8a0dda1c6f7f92c5da8e542") version("5.9.0", sha256="f6cde21a9c68cf756af02035f72d5a723bf607e862e7be33ece505abf4a3bad9") version("5.7.1", sha256="fde8f62c05204ead43c2c1b9389cfc85befa7f54acb5da28529d671175bb4108") version("5.3.0", sha256="0bb9f1f9f017aa8ec187d8b1b2a7a6626a2a1d877116baba52a129bfa124f8e2") diff --git a/var/spack/repos/builtin/packages/py-traits/package.py b/var/spack/repos/builtin/packages/py-traits/package.py index 404c73b8e931db..8bccce306bf779 100644 --- a/var/spack/repos/builtin/packages/py-traits/package.py +++ b/var/spack/repos/builtin/packages/py-traits/package.py @@ -22,4 +22,6 @@ class PyTraits(PythonPackage): version("6.2.0", sha256="16fa1518b0778fd53bf0547e6a562b1787bf68c8f6b7995a13bd1902529fdb0c") version("6.0.0", sha256="dbcd70166feca434130a1193284d5819ca72ffbc8dbce8deeecc0cebb41a3bfb") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-transformer-engine/package.py b/var/spack/repos/builtin/packages/py-transformer-engine/package.py new file mode 100644 index 00000000000000..175b3336261e2b --- /dev/null +++ b/var/spack/repos/builtin/packages/py-transformer-engine/package.py @@ -0,0 +1,50 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyTransformerEngine(PythonPackage): + """ + A library for accelerating Transformer models on NVIDIA GPUs, including fp8 precision on Hopper + GPUs. + """ + + homepage = "https://github.com/NVIDIA/TransformerEngine" + url = "https://github.com/NVIDIA/TransformerEngine/archive/refs/tags/v0.0.tar.gz" + git = "https://github.com/NVIDIA/TransformerEngine.git" + maintainers("aurianer") + + license("Apache-2.0") + + version("1.4", tag="v1.4", submodules=True) + version("main", branch="main", submodules=True) + + depends_on("cxx", type="build") # generated + + variant("userbuffers", default=True, description="Enable userbuffers, this option needs MPI.") + + depends_on("py-setuptools", type="build") + depends_on("cmake@3.18:") + depends_on("py-pydantic") + depends_on("py-importlib-metadata") + + with default_args(type=("build", "run")): + depends_on("py-accelerate") + depends_on("py-datasets") + depends_on("py-flash-attn@2.2:2.4.2") + depends_on("py-packaging") + depends_on("py-torchvision") + depends_on("py-transformers") + depends_on("mpi", when="+userbuffers") + + with default_args(type=("build", "link", "run")): + depends_on("py-torch+cuda+cudnn") + + def setup_build_environment(self, env): + env.set("NVTE_FRAMEWORK", "pytorch") + if self.spec.satisfies("+userbuffers"): + env.set("NVTE_WITH_USERBUFFERS", "1") + env.set("MPI_HOME", self.spec["mpi"].prefix) diff --git a/var/spack/repos/builtin/packages/py-transformers/package.py b/var/spack/repos/builtin/packages/py-transformers/package.py index e1b34bb65deb2a..05401c850db24d 100644 --- a/var/spack/repos/builtin/packages/py-transformers/package.py +++ b/var/spack/repos/builtin/packages/py-transformers/package.py @@ -18,33 +18,44 @@ class PyTransformers(PythonPackage): license("Apache-2.0") + version("4.42.3", sha256="7539873ff45809145265cbc94ea4619d2713c41ceaa277b692d8b0be3430f7eb") + version("4.38.1", sha256="86dc84ccbe36123647e84cbd50fc31618c109a41e6be92514b064ab55bf1304c") version("4.35.2", sha256="2d125e197d77b0cdb6c9201df9fa7e2101493272e448b9fba9341c695bee2f52") version("4.31.0", sha256="4302fba920a1c24d3a429a29efff6a63eac03f3f3cf55b55927fc795d01cb273") version("4.24.0", sha256="486f353a8e594002e48be0e2aba723d96eda839e63bfe274702a4b5eda85559b") version("4.6.1", sha256="83dbff763b7e7dc57cbef1a6b849655d4fcab6bffdd955c5e8bea12a4f76dc10") version("2.8.0", sha256="b9f29cdfd39c28f29e0806c321270dea337d6174a7aa60daf9625bf83dbb12ee") - depends_on("py-setuptools", type="build") - depends_on("py-filelock", type=("build", "run")) - depends_on("py-huggingface-hub@0.16.4:0", when="@4.34:", type=("build", "run")) - depends_on("py-huggingface-hub@0.14.1:0", when="@4.26:", type=("build", "run")) - depends_on("py-huggingface-hub@0.10:0", when="@4.24:", type=("build", "run")) - depends_on("py-huggingface-hub@0.0.8", when="@4.6.1", type=("build", "run")) - depends_on("py-numpy@1.17:", when="@4.6:", type=("build", "run")) - depends_on("py-numpy", type=("build", "run")) - depends_on("py-packaging@20:", when="@4.24:", type=("build", "run")) - depends_on("py-packaging", when="@4.6.1", type=("build", "run")) - depends_on("py-pyyaml@5.1:", when="@4.24:", type=("build", "run")) - depends_on("py-regex@:2019.12.16,2019.12.18:", type=("build", "run")) - depends_on("py-requests", type=("build", "run")) - depends_on("py-safetensors@0.3.1:", when="@4.31:", type=("build", "run")) - depends_on("py-tokenizers@0.14:0.18", when="@4.35:", type=("build", "run")) - depends_on("py-tokenizers@0.11.1:0.11.2,0.11.4:0.13", when="@4.24:4.33", type=("build", "run")) - depends_on("py-tokenizers@0.10.1:0.10", when="@4.6.1", type=("build", "run")) - depends_on("py-tokenizers@0.5.2", when="@2.8.0", type=("build", "run")) - depends_on("py-tqdm@4.27:", type=("build", "run")) - - # Historical requirements - depends_on("py-sacremoses", when="@:4.6", type=("build", "run")) - depends_on("py-boto3", when="@2.8.0", type=("build", "run")) - depends_on("py-sentencepiece", when="@2.8.0", type=("build", "run")) + depends_on("cxx", type="build") # generated + + with default_args(type="build"): + depends_on("py-setuptools") + + with default_args(type=("build", "run")): + depends_on("py-filelock") + depends_on("py-huggingface-hub@0.23.2:", when="@4.42.3:") + depends_on("py-huggingface-hub@0.19.3:", when="@4.38.1:") + depends_on("py-huggingface-hub@0.16.4:0", when="@4.34:") + depends_on("py-huggingface-hub@0.14.1:0", when="@4.26:") + depends_on("py-huggingface-hub@0.10:0", when="@4.24:") + depends_on("py-huggingface-hub@0.0.8", when="@4.6.1") + depends_on("py-numpy@1.17:", when="@4.6:") + depends_on("py-numpy") + depends_on("py-packaging@20:", when="@4.24:") + depends_on("py-packaging", when="@4.6.1") + depends_on("py-pyyaml@5.1:", when="@4.24:") + depends_on("py-regex@:2019.12.16,2019.12.18:") + depends_on("py-requests") + depends_on("py-safetensors@0.4.1:", when="@4.38.1:") + depends_on("py-safetensors@0.3.1:", when="@4.31:") + depends_on("py-tokenizers@0.19", when="@4.40.0:") + depends_on("py-tokenizers@0.14:0.18", when="@4.35:4.39.3") + depends_on("py-tokenizers@0.11.1:0.11.2,0.11.4:0.13", when="@4.24:4.33") + depends_on("py-tokenizers@0.10.1:0.10", when="@4.6.1") + depends_on("py-tokenizers@0.5.2", when="@2.8.0") + depends_on("py-tqdm@4.27:") + + # Historical requirements + depends_on("py-sacremoses", when="@:4.6") + depends_on("py-boto3", when="@2.8.0") + depends_on("py-sentencepiece", when="@2.8.0") diff --git a/var/spack/repos/builtin/packages/py-triangle/package.py b/var/spack/repos/builtin/packages/py-triangle/package.py index f54aa8641c23f8..d236b1f5c1caf1 100644 --- a/var/spack/repos/builtin/packages/py-triangle/package.py +++ b/var/spack/repos/builtin/packages/py-triangle/package.py @@ -16,6 +16,8 @@ class PyTriangle(PythonPackage): version("20200424", sha256="fc207641f8f39986f7d2bee1b91688a588cd235d2e67777422f94e61fece27e9") + depends_on("c", type="build") # generated + depends_on("python@:3.9", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-triton/package.py b/var/spack/repos/builtin/packages/py-triton/package.py index 4b73388d5fd2e3..0c326c44d4c4f1 100644 --- a/var/spack/repos/builtin/packages/py-triton/package.py +++ b/var/spack/repos/builtin/packages/py-triton/package.py @@ -11,13 +11,25 @@ class PyTriton(PythonPackage): homepage = "https://github.com/openai/triton" url = "https://github.com/openai/triton/archive/refs/tags/v2.1.0.tar.gz" + git = "https://github.com/openai/triton.git" license("MIT") + version("main", branch="main") version("2.1.0", sha256="4338ca0e80a059aec2671f02bfc9320119b051f378449cf5f56a1273597a3d99") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@40.8:", type="build") depends_on("cmake@3.18:", type="build") depends_on("py-filelock", type=("build", "run")) + depends_on("zlib-api", type="link") + conflicts("^openssl@3.3.0") + + def setup_build_environment(self, env): + """Set environment variables used to control the build""" + if self.spec.satisfies("%clang"): + env.set("TRITON_BUILD_WITH_CLANG_LLD", "True") build_directory = "python" diff --git a/var/spack/repos/builtin/packages/py-trx-python/package.py b/var/spack/repos/builtin/packages/py-trx-python/package.py new file mode 100644 index 00000000000000..9f7c09fcb6c533 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-trx-python/package.py @@ -0,0 +1,28 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyTrxPython(PythonPackage): + """Experiments with new file format for tractography.""" + + homepage = "https://tee-ar-ex.github.io/trx-python/" + pypi = "trx-python/trx-python-0.2.9.tar.gz" + + maintainers("ChristopherChristofi") + + license("BSD-2-Clause") + + version("0.2.9", sha256="16b4104d7c991879c601f60e8d587decac50ce60388aae8d0c754a92136d1caf") + + depends_on("py-setuptools@42.0:", type="build") + depends_on("py-setuptools-scm@3.4:+toml", type=("build", "run")) + depends_on("py-setuptools-scm-git-archive", type="build") + depends_on("py-packaging@19.0:", type="build") + depends_on("py-cython@0.29:", type="build") + depends_on("py-deepdiff", type=("build", "run")) + depends_on("py-nibabel@5:", type=("build", "run")) + depends_on("py-numpy@1.22:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-tuiview/package.py b/var/spack/repos/builtin/packages/py-tuiview/package.py index 91fd4b4b6e56ea..ca95de3d40c456 100644 --- a/var/spack/repos/builtin/packages/py-tuiview/package.py +++ b/var/spack/repos/builtin/packages/py-tuiview/package.py @@ -16,6 +16,9 @@ class PyTuiview(PythonPackage): "https://github.com/ubarsc/tuiview/releases/download/tuiview-1.2.13/TuiView-1.2.13.tar.gz" ) + maintainers("neilflood", "gillins") + + version("1.2.14", sha256="80cf4ac607b37bb9d7348b3d40e1e18910323f7ad47e79ae850cbb4750775f7c") version("1.2.13", sha256="48c8d4175c324f70941dc49c5a119882c9d501bd20bc13c76bc2455dee5236a5") version("1.2.12", sha256="3f0c1673f2f861db01726f3d7f6f1dde4a42ec57894a79b89457c398768dd25f") version("1.2.11", sha256="81f870ad98ec1e3175f25028d261135b6198fa85038bfaa900789e04e3cf8517") @@ -25,6 +28,8 @@ class PyTuiview(PythonPackage): version("1.2.7", sha256="35dfeb79b2bb57dfb5b8c90c3edf8c8a0a3f89cef85c33f9935e4a4add282aaf") version("1.2.6", sha256="61b136fa31c949d7a7a4dbf8562e6fc677d5b1845b152ec39e337f4eb2e91662") + depends_on("c", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") depends_on("py-pyqt5", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-tuswsgi/package.py b/var/spack/repos/builtin/packages/py-tuswsgi/package.py index 5efbb80603270f..066f8c7e03fede 100644 --- a/var/spack/repos/builtin/packages/py-tuswsgi/package.py +++ b/var/spack/repos/builtin/packages/py-tuswsgi/package.py @@ -15,11 +15,7 @@ class PyTuswsgi(PythonPackage): license("MIT") - version( - "0.5.4", - sha256="f681a386254a161a97301a67c01ee7da77419c007d9bc43dbd48d5a987491a5e", - expand=False, - ) + version("0.5.4", sha256="f681a386254a161a97301a67c01ee7da77419c007d9bc43dbd48d5a987491a5e") depends_on("python@3.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-tweedledum/package.py b/var/spack/repos/builtin/packages/py-tweedledum/package.py index 9e4be8b77cc45f..f46ccf8bdefce0 100644 --- a/var/spack/repos/builtin/packages/py-tweedledum/package.py +++ b/var/spack/repos/builtin/packages/py-tweedledum/package.py @@ -20,11 +20,13 @@ class PyTweedledum(PythonPackage): license("MIT") version("1.1.1", sha256="58d6f7a988b10c31be3faa1faf3e58288ef7e8159584bfa6ded45742f390309f") + + depends_on("cxx", type="build") # generated depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools@42:", type="build") depends_on("py-scikit-build@0.12:", type="build") - depends_on("py-cmake@3.18:", type="build") - depends_on("py-ninja", type="build") + depends_on("cmake@3.18:", type="build") + depends_on("ninja", type="build") depends_on("py-wheel", type="build") depends_on("eigen@3.3:") depends_on("nlohmann-json@3.9.0:") diff --git a/var/spack/repos/builtin/packages/py-typed-ast/package.py b/var/spack/repos/builtin/packages/py-typed-ast/package.py index 45f96fdddfd409..62d15f6978bbda 100644 --- a/var/spack/repos/builtin/packages/py-typed-ast/package.py +++ b/var/spack/repos/builtin/packages/py-typed-ast/package.py @@ -25,6 +25,8 @@ class PyTypedAst(PythonPackage): url="https://files.pythonhosted.org/packages/source/t/typed-ast/typed-ast-1.3.5.tar.gz", ) + depends_on("c", type="build") # generated + variant( "wheel", default=False, diff --git a/var/spack/repos/builtin/packages/py-ucx-py/package.py b/var/spack/repos/builtin/packages/py-ucx-py/package.py index d8bcd05a5fe744..233eb1d6de7178 100644 --- a/var/spack/repos/builtin/packages/py-ucx-py/package.py +++ b/var/spack/repos/builtin/packages/py-ucx-py/package.py @@ -20,6 +20,8 @@ class PyUcxPy(PythonPackage): version("0.16.0", sha256="12c1c982ee337b8dc026d3a6e8e63d96bf021c5c555fe173642908d3c3bec36e") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("python@3.6:", type=("build", "run")) depends_on("py-cython@0.29.14:2", type="build") diff --git a/var/spack/repos/builtin/packages/py-uhi/package.py b/var/spack/repos/builtin/packages/py-uhi/package.py index ced9b7d3a8d01f..e237f75f95f0d6 100644 --- a/var/spack/repos/builtin/packages/py-uhi/package.py +++ b/var/spack/repos/builtin/packages/py-uhi/package.py @@ -15,11 +15,13 @@ class PyUhi(PythonPackage): license("BSD-3-Clause") + version("0.4.0", sha256="0dcb6b19775087d38a31ee388cb2c70f2ecfe04c4ffe2ca63223410cae5beefa") version("0.3.3", sha256="800caf3a5f1273b08bcc3bb4b49228fe003942e23423812b0110546aad9a24be") version("0.3.2", sha256="fd6ed2ae8ce68ba6be37b872de86e7775b45d54f858768c8fdaba162b6452ab2") version("0.3.1", sha256="6f1ebcadd1d0628337a30b012184325618047abc01c3539538b1655c69101d91") version("0.3.0", sha256="3f441bfa89fae11aa762ae1ef1b1b454362d228e9084477773ffb82d6e9f5d2c") + depends_on("python@3.7:", type=("build", "run"), when="@0.4:") depends_on("python@3.6:", type=("build", "run")) depends_on("py-numpy@1.13.3:", type=("build", "run")) depends_on("py-typing-extensions@3.7:", type=("build", "run"), when="^python@:3.7") diff --git a/var/spack/repos/builtin/packages/py-ujson/package.py b/var/spack/repos/builtin/packages/py-ujson/package.py index 1b50fb9c2ebb6a..5c5c2140c57af7 100644 --- a/var/spack/repos/builtin/packages/py-ujson/package.py +++ b/var/spack/repos/builtin/packages/py-ujson/package.py @@ -17,6 +17,9 @@ class PyUjson(PythonPackage): version("4.0.2", sha256="c615a9e9e378a7383b756b7e7a73c38b22aeb8967a8bfbffd4741f7ffd043c4d") version("1.35", sha256="f66073e5506e91d204ab0c614a148d5aa938bdbf104751be66f8ad7a222f5f86") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@42:", when="@5:", type="build") depends_on("py-setuptools", type="build") depends_on("py-setuptools-scm@3.4:+toml", when="@5:", type="build") diff --git a/var/spack/repos/builtin/packages/py-umi-tools/package.py b/var/spack/repos/builtin/packages/py-umi-tools/package.py index bf737721f26f37..f3461e3a34197c 100644 --- a/var/spack/repos/builtin/packages/py-umi-tools/package.py +++ b/var/spack/repos/builtin/packages/py-umi-tools/package.py @@ -20,6 +20,8 @@ class PyUmiTools(PythonPackage): version("0.5.4", sha256="a03e6babf188d0618a63f083b4da18120b9e8b4d473af71b585dba7de347e962") version("0.5.3", sha256="d599f15c48c96a96ba667db1f364ebfed4ba733dd30469f9656c1717282d2ecb") + depends_on("c", type="build") # generated + depends_on("py-setuptools@1.1:", type="build") depends_on("py-numpy@1.7:", type=("build", "run")) depends_on("py-pandas@0.12:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-unicycler/package.py b/var/spack/repos/builtin/packages/py-unicycler/package.py index a0a521d84703bf..24de27c9dc9a68 100644 --- a/var/spack/repos/builtin/packages/py-unicycler/package.py +++ b/var/spack/repos/builtin/packages/py-unicycler/package.py @@ -26,6 +26,8 @@ class PyUnicycler(PythonPackage): version("0.4.6", sha256="56f6f358a5d1f8dd0fcd1df04504079fc42cec8453a36ee59ff89295535d03f5") version("0.4.5", sha256="67043656b31a4809f8fa8f73368580ba7658c8440b9f6d042c7f70b5eb6b19ae") + depends_on("cxx", type="build") # generated + depends_on("python@3.4:", type=("build", "link", "run")) depends_on("py-setuptools", type=("build", "run")) depends_on("racon", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/py-unshare/package.py b/var/spack/repos/builtin/packages/py-unshare/package.py index c80b6f8b2c25e6..5811d0644fbacd 100644 --- a/var/spack/repos/builtin/packages/py-unshare/package.py +++ b/var/spack/repos/builtin/packages/py-unshare/package.py @@ -15,6 +15,8 @@ class PyUnshare(PythonPackage): version("0.22", sha256="d521d72cca6e876f22cbd5ff5eb51f1beef75e8f9c53b599b55fa05fba1dd3a6") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") conflicts("platform=darwin", msg="unshare is linux-only") diff --git a/var/spack/repos/builtin/packages/py-urwid/package.py b/var/spack/repos/builtin/packages/py-urwid/package.py index b2b98cb77701c7..6c3d6eb4e7324c 100644 --- a/var/spack/repos/builtin/packages/py-urwid/package.py +++ b/var/spack/repos/builtin/packages/py-urwid/package.py @@ -17,4 +17,6 @@ class PyUrwid(PythonPackage): version("2.1.2", sha256="588bee9c1cb208d0906a9f73c613d2bd32c3ed3702012f51efe318a3f2127eae") version("1.3.0", sha256="29f04fad3bf0a79c5491f7ebec2d50fa086e9d16359896c9204c6a92bc07aba2") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-uvicorn/package.py b/var/spack/repos/builtin/packages/py-uvicorn/package.py index bc05d7e2207444..1465d116a8ed8c 100644 --- a/var/spack/repos/builtin/packages/py-uvicorn/package.py +++ b/var/spack/repos/builtin/packages/py-uvicorn/package.py @@ -31,6 +31,5 @@ class PyUvicorn(PythonPackage): depends_on("py-pyyaml@5.1:", type=("build", "run")) depends_on("py-uvloop@0.14,0.15.2:", when="platform=linux", type=("build", "run")) depends_on("py-uvloop@0.14,0.15.2:", when="platform=darwin", type=("build", "run")) - depends_on("py-uvloop@0.14,0.15.2:", when="platform=cray", type=("build", "run")) depends_on("py-watchfiles@0.13:", type=("build", "run")) depends_on("py-websockets@10.4:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-uvloop/package.py b/var/spack/repos/builtin/packages/py-uvloop/package.py index 10c875940c75f2..7bdacaad781d9f 100644 --- a/var/spack/repos/builtin/packages/py-uvloop/package.py +++ b/var/spack/repos/builtin/packages/py-uvloop/package.py @@ -14,9 +14,19 @@ class PyUvloop(PythonPackage): license("Apache-2.0") + version("0.19.0", sha256="0246f4fd1bf2bf702e06b0d45ee91677ee5c31242f39aab4ea6fe0c51aedd0fd") + version("0.18.0", sha256="d5d1135beffe9cd95d0350f19e2716bc38be47d5df296d7cc46e3b7557c0d1ff") + version("0.17.0", sha256="0ddf6baf9cf11a1a22c71487f39f15b2cf78eb5bde7e5b45fbb99e8a9d91b9e1") version("0.16.0", sha256="f74bc20c7b67d1c27c72601c78cf95be99d5c2cdd4514502b4f3eb0933ff1228") version("0.14.0", sha256="123ac9c0c7dd71464f58f1b4ee0bbd81285d96cdda8bc3519281b8973e3a461e") + depends_on("c", type="build") # generated + + depends_on("python@3.8:", when="@0.19:", type=("build", "run")) depends_on("python@3.7:", when="@0.15:", type=("build", "run")) depends_on("python@3.5:", type=("build", "run")) - depends_on("py-setuptools", type="build") + + with default_args(type="build"): + depends_on("py-setuptools") + depends_on("py-setuptools@60:", when="@0.18:") + depends_on("py-cython@0.29.36:0.29", when="@0.17:") # May have been required for 0.16: diff --git a/var/spack/repos/builtin/packages/py-uwsgi/package.py b/var/spack/repos/builtin/packages/py-uwsgi/package.py index 2783c910071c58..21e987d0bc020f 100644 --- a/var/spack/repos/builtin/packages/py-uwsgi/package.py +++ b/var/spack/repos/builtin/packages/py-uwsgi/package.py @@ -17,5 +17,8 @@ class PyUwsgi(PythonPackage): version("2.0.18", sha256="4972ac538800fb2d421027f49b4a1869b66048839507ccf0aa2fda792d99f583") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("python", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/py-vascpy/package.py b/var/spack/repos/builtin/packages/py-vascpy/package.py new file mode 100644 index 00000000000000..b5db82ee5af56b --- /dev/null +++ b/var/spack/repos/builtin/packages/py-vascpy/package.py @@ -0,0 +1,33 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyVascpy(PythonPackage): + """Python library for reading, writing, and manipulating large-scale vasculature + datasets""" + + homepage = "https://github.com/BlueBrain/vascpy" + git = "https://github.com/BlueBrain/vascpy.git" + pypi = "vascpy/vascpy-0.1.0.tar.gz" + + license("Apache-2.0") + + maintainers("tristan0x") + + version("main", branch="main") + version("0.1.1", sha256="1b6bd1399a0388b36241364de74ef709cda2b659e45448fbbdd7efc93bbd8b27") + + depends_on("py-setuptools-scm@3.4:", type="build") + depends_on("py-setuptools@42:", type="build") + + depends_on("py-click@8.0.0:", type=("build", "run")) + depends_on("py-h5py@3.4.0:", type=("build", "run")) + depends_on("py-libsonata@0.1.8:", type=("build", "run")) + depends_on("py-morphio@3.0.0:", type=("build", "run")) + depends_on("py-numpy@1.17.0:", type=("build", "run")) + depends_on("py-pandas@1.0.0:", type=("build", "run")) + depends_on("py-scipy@1.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-versioneer/package.py b/var/spack/repos/builtin/packages/py-versioneer/package.py index 5eb5ae59e5e7f2..f7b50a4760f4eb 100644 --- a/var/spack/repos/builtin/packages/py-versioneer/package.py +++ b/var/spack/repos/builtin/packages/py-versioneer/package.py @@ -24,6 +24,8 @@ class PyVersioneer(PythonPackage): version("0.26", sha256="84fc729aa296d1d26645a8f62f178019885ff6f9a1073b29a4a228270ac5257b") version("0.18", sha256="ead1f78168150011189521b479d3a0dd2f55c94f5b07747b484fd693c3fbf335") + depends_on("c", type="build") # generated + variant("toml", default=True, description="Install TOML support", when="@0.26:") depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-virtualenv/package.py b/var/spack/repos/builtin/packages/py-virtualenv/package.py index 4b720793a41cb4..1c01c5f622856b 100644 --- a/var/spack/repos/builtin/packages/py-virtualenv/package.py +++ b/var/spack/repos/builtin/packages/py-virtualenv/package.py @@ -28,6 +28,8 @@ class PyVirtualenv(PythonPackage): version("13.0.1", sha256="36c2cfae0f9c6462264bb19c478fc6bab3478cf0575f1027452e975a1ed84dbd") version("1.11.6", sha256="3e7a4c151e2ee97f51db0215bfd2a073b04a91e9786df6cb67c916f16abe04f7") + depends_on("c", type="build") # generated + depends_on("py-hatch-vcs@0.3:", when="@20.18:", type="build") depends_on("py-hatchling@1.17.1:", when="@20.23.1:", type="build") depends_on("py-hatchling@1.14:", when="@20.22:", type="build") diff --git a/var/spack/repos/builtin/packages/py-vl-convert-python/package.py b/var/spack/repos/builtin/packages/py-vl-convert-python/package.py index 3dcd6711d1b088..115e7ca251518f 100644 --- a/var/spack/repos/builtin/packages/py-vl-convert-python/package.py +++ b/var/spack/repos/builtin/packages/py-vl-convert-python/package.py @@ -7,12 +7,23 @@ class PyVlConvertPython(PythonPackage): - """Convert Vega-Lite chart specifications to SVG, PNG, or Vega""" + """Convert Vega-Lite chart specifications to SVG, PNG, PDF, or Vega""" - homepage = "https://github.com/jonmmease/vl-convert" - pypi = "vl_convert_python/vl_convert_python-0.13.1.tar.gz" + homepage = "https://github.com/vega/vl-convert" + pypi = "vl_convert_python/vl_convert_python-1.4.0.tar.gz" - version("0.13.1", sha256="d70a608257dd6b5b782d96cccebfe7289992e522e47a8bebb7d928253ca8b396") + version("1.4.0", sha256="264d6f2338c7d3474e60c6907cca016b880b0c1c9be302bb84abc6690188a7e9") + + version( + "1.3.0", + sha256="de1462151dfbba7b2a17881dac1d2269662012c252f1e9d1537a4daed5e36067", + deprecated=True, + ) + version( + "0.13.1", + sha256="d70a608257dd6b5b782d96cccebfe7289992e522e47a8bebb7d928253ca8b396", + deprecated=True, + ) depends_on("python@3.7:", type=("build", "run")) @@ -20,3 +31,4 @@ class PyVlConvertPython(PythonPackage): depends_on("py-maturin@1.1:1", type="build") depends_on("cmake", type="build") # some rust dependencies need this + depends_on("protobuf", type="build") # rust dependency prost need this diff --git a/var/spack/repos/builtin/packages/py-warpx/package.py b/var/spack/repos/builtin/packages/py-warpx/package.py index 17483e1c30c83c..beea6bdce7fe9b 100644 --- a/var/spack/repos/builtin/packages/py-warpx/package.py +++ b/var/spack/repos/builtin/packages/py-warpx/package.py @@ -50,6 +50,8 @@ class PyWarpx(PythonPackage): version("22.02", sha256="d74b593d6f396e037970c5fbe10c2e5d71d557a99c97d40e4255226bc6c26e42") version("22.01", sha256="e465ffadabb7dc360c63c4d3862dc08082b5b0e77923d3fb05570408748b0d28") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") for v in [ @@ -91,9 +93,7 @@ class PyWarpx(PythonPackage): depends_on("py-picmistandard@0.0.18", type=("build", "run"), when="@22.01") depends_on("py-setuptools@42:", type="build") # Since we use PYWARPX_LIB_DIR to pull binaries out of the - # 'warpx' spack package, we don't need py-cmake as declared - # depends_on('py-cmake@3.15:3', type='build') - # depends_on('py-cmake@3.18:3', type='build', when='@22.01:') + # 'warpx' spack package, we don't need cmake as declared depends_on("warpx +lib ~mpi +shared", type=("build", "link"), when="~mpi") depends_on("warpx +lib +mpi +shared", type=("build", "link"), when="+mpi") diff --git a/var/spack/repos/builtin/packages/py-watchdog/package.py b/var/spack/repos/builtin/packages/py-watchdog/package.py index cb9bcfb44be7dd..e18bbff581b2ae 100644 --- a/var/spack/repos/builtin/packages/py-watchdog/package.py +++ b/var/spack/repos/builtin/packages/py-watchdog/package.py @@ -26,6 +26,8 @@ class PyWatchdog(PythonPackage): version("0.8.0", sha256="a86bb2d8b94bb4bf76fcc2ff36f741c0e511ec24c4d3a1059b47d49e377d64f5") version("0.7.1", sha256="54ca64fdf0a2fb23cecba6349f9587e62fd31840ae22a71898a65adb8c6b52f9") + depends_on("c", type="build") # generated + variant( "watchmedo", default=False, diff --git a/var/spack/repos/builtin/packages/py-webcolors/package.py b/var/spack/repos/builtin/packages/py-webcolors/package.py index 834ba71967344f..4114f988309929 100644 --- a/var/spack/repos/builtin/packages/py-webcolors/package.py +++ b/var/spack/repos/builtin/packages/py-webcolors/package.py @@ -12,9 +12,14 @@ class PyWebcolors(PythonPackage): homepage = "https://pypi.org/project/webcolors/" pypi = "webcolors/webcolors-1.11.1.tar.gz" - license("BSD-3-Clause") + license("BSD-3-Clause", checked_by="wdconinc") + version("24.6.0", sha256="1d160d1de46b3e81e58d0a280d0c78b467dc80f47294b91b1ad8029d2cedb55b") + version("1.13", sha256="c225b674c83fa923be93d235330ce0300373d02885cef23238813b0d5668304a") + version("1.12", sha256="16d043d3a08fd6a1b1b7e3e9e62640d09790dce80d2bdd4792a175b35fe794a9") version("1.11.1", sha256="76f360636957d1c976db7466bc71dcb713bb95ac8911944dffc55c01cb516de6") depends_on("python@3.5:", type=("build", "run")) - depends_on("py-setuptools", type=("build")) + depends_on("python@3.7:", type=("build", "run"), when="@1.12:") + depends_on("python@3.8:", type=("build", "run"), when="@24.6:") + depends_on("py-setuptools@61:", type=("build")) diff --git a/var/spack/repos/builtin/packages/py-webkit-server/package.py b/var/spack/repos/builtin/packages/py-webkit-server/package.py index 7302c5e2b9b4f9..eaf6bd6c06be24 100644 --- a/var/spack/repos/builtin/packages/py-webkit-server/package.py +++ b/var/spack/repos/builtin/packages/py-webkit-server/package.py @@ -18,5 +18,7 @@ class PyWebkitServer(PythonPackage): version("develop", branch="master") version("1.0", sha256="836dac18c823bf7737461a2d938c66c7b3601c858897e6c92c7ba0e33574a2bc") + depends_on("cxx", type="build") # generated + # pip silently replaces distutils with setuptools depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-websockets/package.py b/var/spack/repos/builtin/packages/py-websockets/package.py index c820112eb517a8..e8f6344102519c 100644 --- a/var/spack/repos/builtin/packages/py-websockets/package.py +++ b/var/spack/repos/builtin/packages/py-websockets/package.py @@ -21,4 +21,6 @@ class PyWebsockets(PythonPackage): version("10.1", sha256="181d2b25de5a437b36aefedaf006ecb6fa3aa1328ec0236cdde15f32f9d3ff6d") version("8.1", sha256="5c65d2da8c6bce0fca2528f69f44b2f977e06954c8512a952222cea50dad430f") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-whatshap/package.py b/var/spack/repos/builtin/packages/py-whatshap/package.py index d2141255b8e0bb..1229823c2782f2 100644 --- a/var/spack/repos/builtin/packages/py-whatshap/package.py +++ b/var/spack/repos/builtin/packages/py-whatshap/package.py @@ -18,6 +18,8 @@ class PyWhatshap(PythonPackage): version("0.17", sha256="5f342cbd28f5d3e79490754f067aa67e8bb059da1c042d944b9f75663ef6b055") + depends_on("cxx", type="build") # generated + depends_on("python@3.4:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-cython@0.17:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-wheel/package.py b/var/spack/repos/builtin/packages/py-wheel/package.py index 07798585efdfe4..38e4c3062d690a 100644 --- a/var/spack/repos/builtin/packages/py-wheel/package.py +++ b/var/spack/repos/builtin/packages/py-wheel/package.py @@ -13,66 +13,18 @@ class PyWheel(Package, PythonExtension): url = "https://files.pythonhosted.org/packages/py3/w/wheel/wheel-0.41.2-py3-none-any.whl" list_url = "https://pypi.org/simple/wheel/" - version( - "0.41.2", - sha256="75909db2664838d015e3d9139004ee16711748a52c8f336b52882266540215d8", - expand=False, - ) - version( - "0.37.1", - sha256="4bdcd7d840138086126cd09254dc6195fb4fc6f01c050a1d7236f2630db1d22a", - expand=False, - ) - version( - "0.37.0", - sha256="21014b2bd93c6d0034b6ba5d35e4eb284340e09d63c59aef6fc14b0f346146fd", - expand=False, - ) - version( - "0.36.2", - sha256="78b5b185f0e5763c26ca1e324373aadd49182ca90e825f7853f4b2509215dc0e", - expand=False, - ) - version( - "0.35.1", - sha256="497add53525d16c173c2c1c733b8f655510e909ea78cc0e29d374243544b77a2", - expand=False, - ) - version( - "0.34.2", - sha256="df277cb51e61359aba502208d680f90c0493adec6f0e848af94948778aed386e", - expand=False, - ) - version( - "0.33.6", - sha256="f4da1763d3becf2e2cd92a14a7c920f0f00eca30fdde9ea992c836685b9faf28", - expand=False, - ) - version( - "0.33.4", - sha256="5e79117472686ac0c4aef5bad5172ea73a1c2d1646b808c35926bd26bdfb0c08", - expand=False, - ) - version( - "0.33.1", - sha256="8eb4a788b3aec8abf5ff68d4165441bc57420c9f64ca5f471f58c3969fe08668", - expand=False, - ) - version( - "0.32.3", - sha256="1e53cdb3f808d5ccd0df57f964263752aa74ea7359526d3da6c02114ec1e1d44", - expand=False, - ) - version( - "0.29.0", - sha256="ea8033fc9905804e652f75474d33410a07404c1a78dd3c949a66863bd1050ebd", - expand=False, - ) - version( - "0.26.0", - sha256="c92ed3a2dd87c54a9e20024fb0a206fe591c352c745fff21e8f8c6cdac2086ea", - expand=False, - ) + version("0.41.2", sha256="75909db2664838d015e3d9139004ee16711748a52c8f336b52882266540215d8") + version("0.37.1", sha256="4bdcd7d840138086126cd09254dc6195fb4fc6f01c050a1d7236f2630db1d22a") + version("0.37.0", sha256="21014b2bd93c6d0034b6ba5d35e4eb284340e09d63c59aef6fc14b0f346146fd") + version("0.36.2", sha256="78b5b185f0e5763c26ca1e324373aadd49182ca90e825f7853f4b2509215dc0e") + version("0.35.1", sha256="497add53525d16c173c2c1c733b8f655510e909ea78cc0e29d374243544b77a2") + version("0.34.2", sha256="df277cb51e61359aba502208d680f90c0493adec6f0e848af94948778aed386e") + version("0.33.6", sha256="f4da1763d3becf2e2cd92a14a7c920f0f00eca30fdde9ea992c836685b9faf28") + version("0.33.4", sha256="5e79117472686ac0c4aef5bad5172ea73a1c2d1646b808c35926bd26bdfb0c08") + version("0.33.1", sha256="8eb4a788b3aec8abf5ff68d4165441bc57420c9f64ca5f471f58c3969fe08668") + version("0.32.3", sha256="1e53cdb3f808d5ccd0df57f964263752aa74ea7359526d3da6c02114ec1e1d44") + version("0.29.0", sha256="ea8033fc9905804e652f75474d33410a07404c1a78dd3c949a66863bd1050ebd") + version("0.26.0", sha256="c92ed3a2dd87c54a9e20024fb0a206fe591c352c745fff21e8f8c6cdac2086ea") extends("python") depends_on("python +ctypes", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-wordcloud/package.py b/var/spack/repos/builtin/packages/py-wordcloud/package.py index aba30c805eb395..9e6f36cdf55d93 100644 --- a/var/spack/repos/builtin/packages/py-wordcloud/package.py +++ b/var/spack/repos/builtin/packages/py-wordcloud/package.py @@ -16,6 +16,8 @@ class PyWordcloud(PythonPackage): version("1.8.1", sha256="e6ef771aac17c1cf8558c8d5ef025796184066d7b78f8118aefe011fb0d22952") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy@1.6.1:", type=("build", "run")) depends_on("pil", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-workload-automation/package.py b/var/spack/repos/builtin/packages/py-workload-automation/package.py index 05ee82d1bc21ce..28e707b44df6e4 100644 --- a/var/spack/repos/builtin/packages/py-workload-automation/package.py +++ b/var/spack/repos/builtin/packages/py-workload-automation/package.py @@ -25,6 +25,8 @@ class PyWorkloadAutomation(PythonPackage): version("2.7.0", sha256="e9005b9db18e205bf6c4b3e09b15a118abeede73700897427565340dcd589fbb") version("2.6.0", sha256="b94341fb067592cebe0db69fcf7c00c82f96b4eb7c7210e34b38473869824cce") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-python-dateutil", type=("build", "run")) depends_on("py-pexpect@3.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-wrapt/package.py b/var/spack/repos/builtin/packages/py-wrapt/package.py index 4c22c0676fe375..b6bde1a38cc6d2 100644 --- a/var/spack/repos/builtin/packages/py-wrapt/package.py +++ b/var/spack/repos/builtin/packages/py-wrapt/package.py @@ -22,4 +22,6 @@ class PyWrapt(PythonPackage): version("1.11.1", sha256="4aea003270831cceb8a90ff27c4031da6ead7ec1886023b80ce0dfe0adf61533") version("1.10.10", sha256="42160c91b77f1bc64a955890038e02f2f72986c01d462d53cb6cb039b995cdd9") + depends_on("c", type="build") # generated + depends_on("py-setuptools@38.3:", type="build") diff --git a/var/spack/repos/builtin/packages/py-wxflow/package.py b/var/spack/repos/builtin/packages/py-wxflow/package.py new file mode 100644 index 00000000000000..969453b4a76785 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-wxflow/package.py @@ -0,0 +1,46 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyWxflow(PythonPackage): + """ + Common set of tools used in weather workflows. + See https://wxflow.readthedocs.io/en/latest/ for documentation. + """ + + homepage = "https://github.com/NOAA-EMC/wxflow" + pypi = "wxflow/wxflow-0.1.0.tar.gz" + + maintainers("aerorahul", "WalterKolczynski-NOAA", "AlexanderRichert-NOAA") + + license("LGPL-3.0-only", checked_by="AlexanderRichert-NOAA") + + version("0.2.0", sha256="a0fa903c6bb65e2cfa9deebcc8ec03d8eced82eac54288e73bd9137fcc0457d4") + version("0.1.0", sha256="4de120688affd7589bd9df0288139d16e97a93bc37efcfaf09fccc1c6ed43ab1") + + depends_on("python@3.6:", type=("build", "run")) + depends_on("py-setuptools", type="build") + + depends_on("py-numpy@1.21.6:", type=("build", "run")) + depends_on("py-pyyaml@6:", type=("build", "run")) + depends_on("py-jinja2@3.1.2:", type=("build", "run")) + + depends_on("py-pytest", type="test") + + @on_package_attributes(run_tests=True) + def patch(self): + # Disable code coverage generation + filter_file(r"\s\-\-cov[^\s]+", "", "setup.cfg") + + @run_after("install") + @on_package_attributes(run_tests=True) + def check(self): + env["PYTHONPATH"] = ":".join( + (join_path(self.build_directory, "build/lib"), env["PYTHONPATH"]) + ) + pytest = which(join_path(self.spec["py-pytest"].prefix.bin, "pytest")) + pytest("-v", self.build_directory) diff --git a/var/spack/repos/builtin/packages/py-wxpython/package.py b/var/spack/repos/builtin/packages/py-wxpython/package.py index 87d1e314ebfe2b..6fceaa583d3a7e 100644 --- a/var/spack/repos/builtin/packages/py-wxpython/package.py +++ b/var/spack/repos/builtin/packages/py-wxpython/package.py @@ -15,6 +15,9 @@ class PyWxpython(PythonPackage): version("4.1.1", sha256="00e5e3180ac7f2852f342ad341d57c44e7e4326de0b550b9a5c4a8361b6c3528") version("4.0.6", sha256="35cc8ae9dd5246e2c9861bb796026bbcb9fb083e4d49650f776622171ecdab37") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("wxwidgets") # Needed for the build.py script diff --git a/var/spack/repos/builtin/packages/py-x21/package.py b/var/spack/repos/builtin/packages/py-x21/package.py index c4ad8c9c097551..4838b1ecbd3f1d 100644 --- a/var/spack/repos/builtin/packages/py-x21/package.py +++ b/var/spack/repos/builtin/packages/py-x21/package.py @@ -30,33 +30,27 @@ def url_for_version(self, version): version( "0.2.6-py3.8", sha256="bbbfdb6b56562ecc81f0dc39e009713157011fbb50d47353eb25f633acf77204", - expand=False, ) version( "0.2.6-py3.9", sha256="d7b4f06a71ac27d05ae774752b3ca396134916427f371b5995b07f0f43205043", - expand=False, ) version( "0.2.6-py3.10", sha256="2cbda690757f1fc80edfe48fcb13f168068f1784f0cb8c300a0d8051714d0452", - expand=False, ) elif sys.platform.startswith("linux"): version( "0.2.6-py3.8", sha256="64275052bcda784395bc613f750b8b5a6b1ddbfa4e7a590cb8e209543f0ca0c4", - expand=False, ) version( "0.2.6-py3.9", sha256="e20b29650fcbf0be116ac93511033bf10debc76261b7350e018ff91b92ff950d", - expand=False, ) version( "0.2.6-py3.10", sha256="7c5c58ff6dc81caac6815578f78cf545e719beb0bf4017f77120d38025d2bc7d", - expand=False, ) depends_on("python@3.8.0:3.8", type=("build", "run"), when="@0.2.6-py3.8") diff --git a/var/spack/repos/builtin/packages/py-xattr/package.py b/var/spack/repos/builtin/packages/py-xattr/package.py index 1ef69e00b28675..98cdea6e7bf795 100644 --- a/var/spack/repos/builtin/packages/py-xattr/package.py +++ b/var/spack/repos/builtin/packages/py-xattr/package.py @@ -25,6 +25,8 @@ class PyXattr(PythonPackage): version("0.9.7", sha256="b0bbca828e04ef2d484a6522ae7b3a7ccad5e43fa1c6f54d78e24bb870f49d44") version("0.9.6", sha256="7cb1b28eeab4fe99cc4350e831434142fce658f7d03f173ff7722144e6a47458") + depends_on("c", type="build") # generated + depends_on("python@2.7:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-cffi@1.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-xdot/package.py b/var/spack/repos/builtin/packages/py-xdot/package.py index bf898a117e451a..73d703a287bf36 100644 --- a/var/spack/repos/builtin/packages/py-xdot/package.py +++ b/var/spack/repos/builtin/packages/py-xdot/package.py @@ -50,8 +50,7 @@ def post_install(self): dst, ) # regenerate the byte-compiled __init__.py - python3 = spec["python"].command - python3("-m", "compileall", dst) + python("-m", "compileall", dst) def setup_run_environment(self, env): spec = self.spec diff --git a/var/spack/repos/builtin/packages/py-xgboost/package.py b/var/spack/repos/builtin/packages/py-xgboost/package.py index 2fa4b187ed61ab..9b9818dda74e0e 100644 --- a/var/spack/repos/builtin/packages/py-xgboost/package.py +++ b/var/spack/repos/builtin/packages/py-xgboost/package.py @@ -25,6 +25,8 @@ class PyXgboost(PythonPackage): version("1.5.2", sha256="404dc09dca887ef5a9bc0268f882c54b33bfc16ac365a859a11e7b24d49da387") version("1.3.3", sha256="397051647bb837915f3ff24afc7d49f7fca57630ffd00fb5ef66ae2a0881fb43") + depends_on("cxx", type="build") # generated + variant("pandas", default=False, description="Enable Pandas extensions for training.") variant( "scikit-learn", default=False, description="Enable scikit-learn extensions for training." @@ -42,6 +44,8 @@ class PyXgboost(PythonPackage): depends_on("py-pip@:23.0", type="build") depends_on("py-numpy", type=("build", "run")) + # https://github.com/dmlc/xgboost/issues/10221 + depends_on("py-numpy@:1", when="@:2.0", type=("build", "run")) depends_on("py-scipy", type=("build", "run")) depends_on("py-pandas", when="+pandas", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-xpyb/package.py b/var/spack/repos/builtin/packages/py-xpyb/package.py index 27afdad8d92387..c590f3eca865b0 100644 --- a/var/spack/repos/builtin/packages/py-xpyb/package.py +++ b/var/spack/repos/builtin/packages/py-xpyb/package.py @@ -15,6 +15,8 @@ class PyXpyb(AutotoolsPackage): version("1.3.1", sha256="4056d11f94f17ed4342563955682193c7d004e80e5fa689816f87f3795549c17") + depends_on("c", type="build") # generated + extends("python") depends_on("libxcb@1.5:") diff --git a/var/spack/repos/builtin/packages/py-xtb/package.py b/var/spack/repos/builtin/packages/py-xtb/package.py index 589e45aa853450..1bc19445148ae4 100644 --- a/var/spack/repos/builtin/packages/py-xtb/package.py +++ b/var/spack/repos/builtin/packages/py-xtb/package.py @@ -25,3 +25,10 @@ class PyXtb(PythonPackage): depends_on("py-meson-python", type="build") depends_on("py-numpy", type=("build", "run")) depends_on("xtb", type=("build", "run")) + + # from https://github.com/grimme-lab/xtb-python/pull/114 + patch( + "https://github.com/grimme-lab/xtb-python/commit/df7e0010a679f5f00456bf09fcd9330cd7c56c39.patch?full_index=1", + when="@:22.1", + sha256="0242a4b79b7e24cfec3c0e6661e744eeb6a786d7", + ) diff --git a/var/spack/repos/builtin/packages/py-xxhash/package.py b/var/spack/repos/builtin/packages/py-xxhash/package.py index 6b2110d85deed0..581d657b7732b2 100644 --- a/var/spack/repos/builtin/packages/py-xxhash/package.py +++ b/var/spack/repos/builtin/packages/py-xxhash/package.py @@ -18,6 +18,8 @@ class PyXxhash(PythonPackage): version("3.2.0", sha256="1afd47af8955c5db730f630ad53ae798cf7fae0acb64cebb3cf94d35c47dd088") version("2.0.2", sha256="b7bead8cf6210eadf9cecf356e17af794f57c0939a3d420a00d87ea652f87b49") + depends_on("c", type="build") # generated + depends_on("python@2.6:2,3.3:", type=("build", "run")) depends_on("py-setuptools", type="build") depends_on("py-setuptools@45:", type="build", when="@3.2.0:") diff --git a/var/spack/repos/builtin/packages/py-yajl/package.py b/var/spack/repos/builtin/packages/py-yajl/package.py index 6eae1130195731..abd3b491b7325d 100644 --- a/var/spack/repos/builtin/packages/py-yajl/package.py +++ b/var/spack/repos/builtin/packages/py-yajl/package.py @@ -14,4 +14,6 @@ class PyYajl(PythonPackage): version("0.3.5", sha256="432321ea613692a4782a2368a300f57b59c64a3c8508c7465af3fdc045e7bcc2") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-yarl/package.py b/var/spack/repos/builtin/packages/py-yarl/package.py index 27df06fa84bf97..d07f7f8a7ac6b6 100644 --- a/var/spack/repos/builtin/packages/py-yarl/package.py +++ b/var/spack/repos/builtin/packages/py-yarl/package.py @@ -21,6 +21,8 @@ class PyYarl(PythonPackage): version("1.4.2", sha256="58cd9c469eced558cd81aa3f484b2924e8897049e06889e8ff2510435b7ef74b") version("1.3.0", sha256="024ecdc12bc02b321bc66b41327f930d1c2c543fa9a561b39861da9388ba7aa9") + depends_on("c", type="build") # generated + depends_on("py-setuptools@40:", type="build", when="@1.7.2:") depends_on("py-setuptools", type="build") depends_on("py-cython", type="build") diff --git a/var/spack/repos/builtin/packages/py-your/package.py b/var/spack/repos/builtin/packages/py-your/package.py new file mode 100644 index 00000000000000..a0e90fc7bde592 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-your/package.py @@ -0,0 +1,34 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyYour(PythonPackage): + """Python library to read and process pulsar data in several different formats""" + + homepage = "https://github.com/thepetabyteproject/your" + + # pypi tarball has requirements.txt missing + url = "https://github.com/thepetabyteproject/your/archive/refs/tags/0.6.7.tar.gz" + + maintainers("aweaver1fandm") + + license("GPL-3.0") + + version("0.6.7", sha256="f2124a630d413621cce067805feb6b9c21c5c8938f41188bd89684968478d814") + + depends_on("python@3.8:", type=("build", "run")) + depends_on("py-setuptools", type="build") + + depends_on("py-astropy@6.1.0:", type=("build", "run")) + depends_on("py-matplotlib@3.2.1:", type=("build", "run")) + depends_on("py-numpy@1.18.4:", type=("build", "run")) + depends_on("py-h5py@2.10:", type=("build", "run")) + depends_on("py-scikit-image@0.14.2:", type=("build", "run")) + depends_on("py-scipy@1.3:", type=("build", "run")) + depends_on("py-numba@0.48:", type=("build", "run")) + depends_on("py-pandas@1.0.3:", type=("build", "run")) + depends_on("py-rich@8:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-yt/package.py b/var/spack/repos/builtin/packages/py-yt/package.py index 183362dfe365d2..f42db02498dfb0 100644 --- a/var/spack/repos/builtin/packages/py-yt/package.py +++ b/var/spack/repos/builtin/packages/py-yt/package.py @@ -40,6 +40,9 @@ class PyYt(PythonPackage): version("3.2.3", sha256="4d6ccf345d9fab965335c9faf8708c7eea79366b81d77f0f302808be3e82c0ed") version("3.2.2", sha256="78866f51e4751534ad60987000f149a8295952b99b37ca249d45e4d11095a5df") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("astropy", default=True, description="enable astropy support") variant("h5py", default=True, description="enable h5py support") variant("scipy", default=True, description="enable scipy support") @@ -56,6 +59,8 @@ class PyYt(PythonPackage): depends_on("py-more-itertools@8.4:", when="@4.1.2:") depends_on("py-numpy@1.10.4:", type=("build", "run")) depends_on("py-numpy@1.14.5:", type=("build", "run"), when="@4.1.2:") + # https://github.com/yt-project/yt/pull/4859 + depends_on("py-numpy@:1", when="@:4.3.0", type=("build", "run")) depends_on("py-packaging@20.9:", type=("build", "run"), when="@4.1.2:") # PIL/pillow and pyparsing dependency is handled by matplotlib depends_on("py-tomli-w@0.4:", type=("build", "run"), when="@4.1.2:") diff --git a/var/spack/repos/builtin/packages/py-ytopt-autotune/package.py b/var/spack/repos/builtin/packages/py-ytopt-autotune/package.py index eefccd11079ad6..96f03473a40667 100644 --- a/var/spack/repos/builtin/packages/py-ytopt-autotune/package.py +++ b/var/spack/repos/builtin/packages/py-ytopt-autotune/package.py @@ -21,6 +21,8 @@ class PyYtoptAutotune(PythonPackage): version("1.1.0", sha256="5ee7fa6a1c83131c5ceba1537b25f00de84182e4d0e6ebd0fd6efa4e8aee1bc4") version("1.0.0", sha256="13f10594156a7a220561467fdbee52173238ea82c07e8188fdf6584d4524f46f") + depends_on("c", type="build") # generated + patch("version.patch", when="@1.1.0") depends_on("python@3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-ytopt/package.py b/var/spack/repos/builtin/packages/py-ytopt/package.py index b4431367936271..dee48ed6696c66 100644 --- a/var/spack/repos/builtin/packages/py-ytopt/package.py +++ b/var/spack/repos/builtin/packages/py-ytopt/package.py @@ -22,6 +22,9 @@ class PyYtopt(PythonPackage): version("0.0.2", sha256="5a624aa678b976ff6ef867610bafcb0dfd5c8af0d880138ca5d56d3f776e6d71") version("0.0.1", sha256="3ca616922c8e76e73f695a5ddea5dd91b0103eada726185f008343cc5cbd7744") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "online", default=False, diff --git a/var/spack/repos/builtin/packages/py-z3-solver/package.py b/var/spack/repos/builtin/packages/py-z3-solver/package.py index bbd74462c35582..851ed124fb3b3f 100644 --- a/var/spack/repos/builtin/packages/py-z3-solver/package.py +++ b/var/spack/repos/builtin/packages/py-z3-solver/package.py @@ -16,5 +16,7 @@ class PyZ3Solver(PythonPackage): version("4.12.3.0", sha256="b6719daf9676711a8f1c708af0ea185578b0f22a3cb9bf9a55735e21691dc38d") + depends_on("cxx", type="build") # generated + depends_on("py-setuptools@46.4:", type="build") depends_on("cmake", type="build") diff --git a/var/spack/repos/builtin/packages/py-zarr/package.py b/var/spack/repos/builtin/packages/py-zarr/package.py index 6d3dbf9b2d47c0..7da4fce325ca6d 100644 --- a/var/spack/repos/builtin/packages/py-zarr/package.py +++ b/var/spack/repos/builtin/packages/py-zarr/package.py @@ -31,6 +31,8 @@ class PyZarr(PythonPackage): depends_on("py-asciitree", type=("build", "run")) depends_on("py-numpy@1.21.1:", type=("build", "run"), when="@2.17:") depends_on("py-numpy@1.7:", type=("build", "run")) + # https://github.com/zarr-developers/zarr-python/issues/1818 + depends_on("py-numpy@:1", when="@:2.17", type=("build", "run")) depends_on("py-fasteners", type=("build", "run")) depends_on("py-numcodecs@0.10:", type=("build", "run"), when="@2.17:") depends_on("py-numcodecs@0.6.4:", type=("build", "run"), when="@2.4.0:") diff --git a/var/spack/repos/builtin/packages/py-zfit/package.py b/var/spack/repos/builtin/packages/py-zfit/package.py index c8810f9cd60451..a09d14175cab9c 100644 --- a/var/spack/repos/builtin/packages/py-zfit/package.py +++ b/var/spack/repos/builtin/packages/py-zfit/package.py @@ -18,15 +18,17 @@ class PyZfit(PythonPackage): maintainers("jonas-eschle") license("BSD-3-Clause", checked_by="jonas-eschle") - # TODO: reactivate once TF 2.15 is ready https://github.com/spack/spack/pull/41069 - # version("0.18.1", sha256="fbc6b3a636d8dc74fb2e69dfec5855f534c4583ec18efac9e9107ad45b18eb43") - # version("0.18.0", sha256="21d9479480f74945c67707b715780693bd4e94062c551bf41fe04a2eddb47fab") + tags = ["likelihood", "statistics", "inference", "fitting", "hep"] + + version("0.18.2", sha256="099b111e135937966b4c6342c7738731f112aea33e1b9f4a9785d2eac9e530f1") + version("0.18.1", sha256="fbc6b3a636d8dc74fb2e69dfec5855f534c4583ec18efac9e9107ad45b18eb43") + version("0.18.0", sha256="21d9479480f74945c67707b715780693bd4e94062c551bf41fe04a2eddb47fab") version("0.17.0", sha256="cd60dfc360c82666af4e8dddd78edb0ab95a095b9dd0868457f0981dc03afa5a") version("0.16.0", sha256="b3b170af23b61d7e265d6fb1bab1d052003f3fb41b3c537527cc1e5a1066dc10") version("0.15.5", sha256="00a1138429e8a7f830c9e229b9c0bcd6071b95dadd8c87eb81191079fb679225") version("0.14.1", sha256="66d1e349403f1d6c6350138d0f2b422046bcbdfb34fd95453dadae29a8b0c98a") - depends_on("python@3.8:3.11", type=("build", "run")) + depends_on("python@3.9:3.11", type=("build", "run")) depends_on("py-setuptools@42:", type="build") depends_on("py-setuptools-scm-git-archive", type="build") depends_on("py-setuptools-scm@3.4:+toml", type="build") @@ -37,9 +39,8 @@ class PyZfit(PythonPackage): # TODO: remove "build" once fixed in spack that tests need "run", not "build" with default_args(type=("build", "run")): - # TODO: reactivate once TF 2.15 is ready https://github.com/spack/spack/pull/41069 - # depends_on("py-tensorflow@2.15", type=("run"), when="@0.18") - # depends_on("py-tensorflow-probability@0.23", type=("run"), when="@0.18") + depends_on("py-tensorflow@2.15", type=("run"), when="@0.18") + depends_on("py-tensorflow-probability@0.23", type=("run"), when="@0.18") depends_on("py-tensorflow@2.13", when="@0.15:0.17") depends_on("py-tensorflow-probability@0.21", when="@0.16:0.17") @@ -54,7 +55,7 @@ class PyZfit(PythonPackage): with when("+hs3"): depends_on("py-asdf") - depends_on("py-attrs", when="@0.15:18.0") + depends_on("py-attrs", when="@0.15:") depends_on("py-typing-extensions", when="^python@:3.8") depends_on("py-boost-histogram") depends_on("py-colorama") diff --git a/var/spack/repos/builtin/packages/py-zipfile-deflate64/package.py b/var/spack/repos/builtin/packages/py-zipfile-deflate64/package.py index fdeb2965dc8cac..4858f4267ebe1d 100644 --- a/var/spack/repos/builtin/packages/py-zipfile-deflate64/package.py +++ b/var/spack/repos/builtin/packages/py-zipfile-deflate64/package.py @@ -16,6 +16,8 @@ class PyZipfileDeflate64(PythonPackage): version("0.2.0", sha256="875a3299de102edf1c17f8cafcc528b1ca80b62dc4814b9cb56867ec59fbfd18") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools@42:", type="build") depends_on("py-setuptools-scm@3.4:+toml", type="build") diff --git a/var/spack/repos/builtin/packages/py-zope-interface/package.py b/var/spack/repos/builtin/packages/py-zope-interface/package.py index 5ac69637f1164d..5e7270ba43f1e9 100644 --- a/var/spack/repos/builtin/packages/py-zope-interface/package.py +++ b/var/spack/repos/builtin/packages/py-zope-interface/package.py @@ -21,6 +21,8 @@ class PyZopeInterface(PythonPackage): version("5.1.0", sha256="40e4c42bd27ed3c11b2c983fecfb03356fae1209de10686d03c02c8696a1d90e") version("4.5.0", sha256="57c38470d9f57e37afb460c399eb254e7193ac7fb8042bd09bdc001981a9c74c") + depends_on("c", type="build") # generated + depends_on("python@2.7:2.8,3.4:", type=("build", "run"), when="@4.5.0") depends_on("python@2.7:2.8,3.5:", type=("build", "run"), when="@5.1.0:") diff --git a/var/spack/repos/builtin/packages/pygmo/package.py b/var/spack/repos/builtin/packages/pygmo/package.py index 31095ec8db9f91..bd04f292aae63d 100644 --- a/var/spack/repos/builtin/packages/pygmo/package.py +++ b/var/spack/repos/builtin/packages/pygmo/package.py @@ -21,6 +21,8 @@ class Pygmo(CMakePackage): version("master", branch="master") version("2.18.0", sha256="9f081cc973297894af09f713f889870ac452bfb32b471f9f7ba08a5e0bb9a125") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") # Run-time dependencies diff --git a/var/spack/repos/builtin/packages/pypy-bootstrap/package.py b/var/spack/repos/builtin/packages/pypy-bootstrap/package.py index 9917ff34c33dad..d05aca50017ae6 100644 --- a/var/spack/repos/builtin/packages/pypy-bootstrap/package.py +++ b/var/spack/repos/builtin/packages/pypy-bootstrap/package.py @@ -39,6 +39,8 @@ class PypyBootstrap(Package): elif platform.system() == "Windows": version("2.7-v7.3.12", "84cd3b98812d47a1ddb36f3417cc96b3dbdfa32c2b4e16438f205e1253f7ccea") + depends_on("c", type="build") # generated + def url_for_version(self, version): url = "https://downloads.python.org/pypy/pypy{}-{}.{}" ext = "tar.bz2" diff --git a/var/spack/repos/builtin/packages/pypy/package.py b/var/spack/repos/builtin/packages/pypy/package.py index b44516b870ebe8..e0380753335d05 100644 --- a/var/spack/repos/builtin/packages/pypy/package.py +++ b/var/spack/repos/builtin/packages/pypy/package.py @@ -21,6 +21,9 @@ class Pypy(Package): "3.10-v7.3.12", sha256="86e4e4eacc36046c6182f43018796537fe33a60e1d2a2cc6b8e7f91a5dcb3e42" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("ctypes", default=True, description="Build ctypes module") variant("zlib", default=True, description="Build zlib module") variant("bz2", default=True, description="Build bz2 module") diff --git a/var/spack/repos/builtin/packages/pythia6/package.py b/var/spack/repos/builtin/packages/pythia6/package.py index c3e358f2cadedd..f28bf5c970de27 100644 --- a/var/spack/repos/builtin/packages/pythia6/package.py +++ b/var/spack/repos/builtin/packages/pythia6/package.py @@ -41,6 +41,8 @@ class Pythia6(CMakePackage): sha256="01cbff47e99365b5e46f6d62c1735d3cae1932c4710604850d59f538cb758020", ) + depends_on("fortran", type="build") # generated + # Root's TPythia6 interface requires extra sources to be built into # the Pythia6 library. variant("root", default=False, description="Build extra (non OEM) code to allow use by Root.") diff --git a/var/spack/repos/builtin/packages/pythia8/package.py b/var/spack/repos/builtin/packages/pythia8/package.py index b1a69b0ecfd4c6..b483dd036258ae 100644 --- a/var/spack/repos/builtin/packages/pythia8/package.py +++ b/var/spack/repos/builtin/packages/pythia8/package.py @@ -22,6 +22,7 @@ class Pythia8(AutotoolsPackage): license("GPL-2.0-only") + version("8.311", sha256="2782d5e429c1543c67375afe547fd4c4ca0720309deb008f7db78626dc7d1464") version("8.310", sha256="90c811abe7a3d2ffdbf9b4aeab51cf6e0a5a8befb4e3efa806f3d5b9c311e227") version("8.309", sha256="5bdafd9f2c4a1c47fd8a4e82fb9f0d8fcfba4de1003b8e14be4e0347436d6c33") version("8.308", sha256="c2e8c8d38136d85fc0bc9c9fad4c2db679b0819b7d2b6fc9a47f80f99538b4e3") @@ -57,7 +58,18 @@ class Pythia8(AutotoolsPackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + + variant( + "cxxstd", + default="11", + values=("11", "17", "20", "23"), + multi=False, + description="Use the specified C++ standard when building", + ) + variant("shared", default=True, description="Build shared library") + variant("gzip", default=False, description="Build with gzip support, for reading lhe.gz files") variant( "hepmc", default=True, description="Export PYTHIA events to the HEPMC format, version 2" ) @@ -83,6 +95,7 @@ class Pythia8(AutotoolsPackage): variant("mpich", default=False, description="Multi-threading support via MPICH") variant("hdf5", default=False, description="Support the use of HDF5 format") + depends_on("zlib-api", when="+gzip") depends_on("rsync", type="build") depends_on("hepmc", when="+hepmc") depends_on("hepmc3", when="+hepmc3") @@ -115,6 +128,21 @@ class Pythia8(AutotoolsPackage): conflicts("+hdf5", when="@:8.304", msg="HDF5 support was added in 8.304") conflicts("+hdf5", when="~mpich", msg="MPICH is required for reading HDF5 files") + filter_compiler_wrappers("Makefile.inc", relative_root="share/Pythia8/examples") + + @run_before("configure") + def setup_cxxstd(self): + filter_file( + r"-std=c\+\+[0-9][0-9]", f"-std=c++{self.spec.variants['cxxstd'].value}", "configure" + ) + + # Fix for https://gitlab.com/Pythia8/releases/-/issues/428 + @when("@:8.311") + def patch(self): + filter_file( + r"[/]examples[/]Makefile[.]inc\|;n' \\", "/examples/Makefile.inc|' \\", "configure" + ) + def configure_args(self): args = [] @@ -135,15 +163,11 @@ def configure_args(self): if "+madgraph5amc" in self.spec: args.append("--with-mg5mes=" + self.spec["madgraph5amc"].prefix) - else: - args.append("--without-mg5mes") args += self.with_or_without("hepmc3", activation_value="prefix") if "+fastjet" in self.spec: args.append("--with-fastjet3=" + self.spec["fastjet"].prefix) - else: - args.append("--without-fastjet3") args += self.with_or_without("evtgen", activation_value="prefix") args += self.with_or_without("root", activation_value="prefix") @@ -159,6 +183,10 @@ def configure_args(self): if self.spec.satisfies("+hdf5"): args.append("--with-highfive=" + self.spec["highfive"].prefix) + args += self.with_or_without( + "gzip", activation_value=lambda x: self.spec["zlib-api"].prefix + ) + return args def url_for_version(self, version): diff --git a/var/spack/repos/builtin/packages/python-venv/package.py b/var/spack/repos/builtin/packages/python-venv/package.py new file mode 100644 index 00000000000000..a814f472210949 --- /dev/null +++ b/var/spack/repos/builtin/packages/python-venv/package.py @@ -0,0 +1,101 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os +import shutil + +import llnl.util.filesystem as fs + +from spack.package import * + + +class PythonVenv(Package): + """A Spack managed Python virtual environment""" + + homepage = "https://docs.python.org/3/library/venv.html" + has_code = False + + maintainers("haampie") + + version("1.0") + + extends("python") + + def install(self, spec, prefix): + # Create a virtual environment + python("-m", "venv", "--without-pip", prefix) + + def add_files_to_view(self, view, merge_map: Dict[str, str], skip_if_exists=True): + for src, dst in merge_map.items(): + if skip_if_exists and os.path.lexists(dst): + continue + + name = os.path.basename(dst) + + # Replace the VIRTUAL_ENV variable in the activate scripts after copying + if name.lower().startswith("activate"): + shutil.copy(src, dst) + fs.filter_file( + self.spec.prefix, + os.path.abspath(view.get_projection_for_spec(self.spec)), + dst, + string=True, + ) + else: + view.link(src, dst) + + @property + def bindir(self): + windows = self.spec.satisfies("platform=windows") + return join_path(self.prefix, "Scripts" if windows else "bin") + + @property + def command(self): + """Returns a python Executable instance""" + python_name = "python" if self.spec.satisfies("platform=windows") else "python3" + return which(python_name, path=self.bindir) + + def _get_path(self, name) -> str: + return self.command( + "-Ec", f"import sysconfig; print(sysconfig.get_path('{name}'))", output=str + ).strip() + + @property + def platlib(self) -> str: + """Directory for site-specific, platform-specific files.""" + relative_platlib = os.path.relpath(self._get_path("platlib"), self.prefix) + assert not relative_platlib.startswith("..") + return relative_platlib + + @property + def purelib(self) -> str: + """Directory for site-specific, non-platform-specific files.""" + relative_purelib = os.path.relpath(self._get_path("purelib"), self.prefix) + assert not relative_purelib.startswith("..") + return relative_purelib + + @property + def headers(self): + return HeaderList([]) + + @property + def libs(self): + return LibraryList([]) + + def setup_dependent_run_environment(self, env, dependent_spec): + """Set PYTHONPATH to include the site-packages directory for the + extension and any other python extensions it depends on.""" + # Packages may be installed in platform-specific or platform-independent site-packages + # directories + for directory in {self.platlib, self.purelib}: + path = os.path.join(dependent_spec.prefix, directory) + if os.path.isdir(path): + env.prepend_path("PYTHONPATH", path) + + def setup_dependent_package(self, module, dependent_spec): + """Called before python modules' install() methods.""" + module.python = self.command + module.python_platlib = join_path(dependent_spec.prefix, self.platlib) + module.python_purelib = join_path(dependent_spec.prefix, self.purelib) diff --git a/var/spack/repos/builtin/packages/python/package.py b/var/spack/repos/builtin/packages/python/package.py index 76d97525c5d8fa..0392cda87b5303 100644 --- a/var/spack/repos/builtin/packages/python/package.py +++ b/var/spack/repos/builtin/packages/python/package.py @@ -8,22 +8,38 @@ import os import platform import re -import stat import subprocess import sys from shutil import copy -from typing import Dict, List, Tuple +from typing import Dict, List import llnl.util.tty as tty -from llnl.util.filesystem import is_nonsymlink_exe_with_shebang, path_contains_subdirectory from llnl.util.lang import dedupe from spack.build_environment import dso_suffix, stat_suffix from spack.package import * -from spack.util.environment import is_system_path from spack.util.prefix import Prefix +def make_pyvenv_cfg(python_spec: "spack.spec.Spec", venv_prefix: str) -> str: + """Make a pyvenv_cfg file for a given (real) python command and venv prefix.""" + python_cmd = python_spec.command.path + lines = [ + # directory containing python command + f"home = {os.path.dirname(python_cmd)}", + # venv should not allow site packages from the real python to be loaded + "include-system-site-packages = false", + # version of the python command + f"version = {python_spec.version}", + # the path to the python command + f"executable = {python_cmd}", + # command "used" to create the pyvenv.cfg + f"command = {python_cmd} -m venv --without-pip {venv_prefix}", + ] + + return "\n".join(lines) + "\n" + + class Python(Package): """The Python programming language.""" @@ -43,13 +59,18 @@ class Python(Package): license("0BSD") + version("3.12.4", sha256="01b3c1c082196f3b33168d344a9c85fb07bfe0e7ecfe77fee4443420d1ce2ad9") + version("3.12.3", sha256="a6b9459f45a6ebbbc1af44f5762623fa355a0c87208ed417628b379d762dddb0") + version("3.12.2", sha256="a7c4f6a9dc423d8c328003254ab0c9338b83037bd787d680826a5bf84308116e") version("3.12.1", sha256="d01ec6a33bc10009b09c17da95cc2759af5a580a7316b3a446eb4190e13f97b2") version("3.12.0", sha256="51412956d24a1ef7c97f1cb5f70e185c13e3de1f50d131c0aac6338080687afb") version( - "3.11.7", - sha256="068c05f82262e57641bd93458dfa883128858f5f4997aad7a36fd25b13b29209", + "3.11.9", + sha256="e7de3240a8bc2b1e1ba5c81bf943f06861ff494b69fda990ce2722a504c6153d", preferred=True, ) + version("3.11.8", sha256="d3019a613b9e8761d260d9ebe3bd4df63976de30464e5c0189566e1ae3f61889") + version("3.11.7", sha256="068c05f82262e57641bd93458dfa883128858f5f4997aad7a36fd25b13b29209") version("3.11.6", sha256="c049bf317e877cbf9fce8c3af902436774ecef5249a29d10984ca3a37f7f4736") version("3.11.5", sha256="a12a0a013a30b846c786c010f2c19dd36b7298d888f7c4bd1581d90ce18b5e58") version("3.11.4", sha256="85c37a265e5c9dd9f75b35f954e31fbfc10383162417285e30ad25cc073a0d63") @@ -57,6 +78,7 @@ class Python(Package): version("3.11.2", sha256="2411c74bda5bbcfcddaf4531f66d1adc73f247f529aee981b029513aefdbf849") version("3.11.1", sha256="baed518e26b337d4d8105679caf68c5c32630d702614fc174e98cb95c46bdfa4") version("3.11.0", sha256="64424e96e2457abbac899b90f9530985b51eef2905951febd935f0e73414caeb") + version("3.10.14", sha256="cefea32d3be89c02436711c95a45c7f8e880105514b78680c14fe76f5709a0f6") version("3.10.13", sha256="698ec55234c1363bd813b460ed53b0f108877c7a133d48bde9a50a1eb57b7e65") version("3.10.12", sha256="a43cd383f3999a6f4a7db2062b2fc9594fefa73e175b3aedafa295a51a7bb65c") version("3.10.11", sha256="f3db31b668efa983508bd67b5712898aa4247899a346f2eb745734699ccd3859") @@ -71,6 +93,7 @@ class Python(Package): version("3.10.2", sha256="3c0ede893011319f9b0a56b44953a3d52c7abf9657c23fb4bc9ced93b86e9c97") version("3.10.1", sha256="b76117670e7c5064344b9c138e141a377e686b9063f3a8a620ff674fa8ec90d3") version("3.10.0", sha256="c4e0cbad57c90690cb813fb4663ef670b4d0f587d8171e2c42bd4c9245bd2758") + version("3.9.19", sha256="f5f9ec8088abca9e399c3b62fd8ef31dbd2e1472c0ccb35070d4d136821aaf71") version("3.9.18", sha256="504ce8cfd59addc04c22f590377c6be454ae7406cb1ebf6f5a350149225a9354") version("3.9.17", sha256="8ead58f669f7e19d777c3556b62fae29a81d7f06a7122ff9bc57f7dd82d7e014") version("3.9.16", sha256="1ad539e9dbd2b42df714b69726e0693bc6b9d2d2c8e91c2e43204026605140c5") @@ -90,6 +113,7 @@ class Python(Package): version("3.9.2", sha256="7899e8a6f7946748830d66739f2d8f2b30214dad956e56b9ba216b3de5581519") version("3.9.1", sha256="29cb91ba038346da0bd9ab84a0a55a845d872c341a4da6879f462e94c741f117") version("3.9.0", sha256="df796b2dc8ef085edae2597a41c1c0a63625ebd92487adaef2fed22b567873e8") + version("3.8.19", sha256="c7fa55a36e5c7a19ec37d8f90f60a2197548908c9ac8b31e7c0dbffdd470eeac") version("3.8.18", sha256="7c5df68bab1be81a52dea0cc2e2705ea00553b67107a301188383d7b57320b16") version("3.8.17", sha256="def428fa6cf61b66bcde72e3d9f7d07d33b2e4226f04f9d6fce8384c055113ae") version("3.8.16", sha256="71ca9d935637ed2feb59e90a368361dc91eca472a90acb1d344a2e8178ccaf10") @@ -200,6 +224,9 @@ class Python(Package): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + extendable = True # Variants to avoid cyclical dependencies for concretizer @@ -239,7 +266,6 @@ class Python(Package): variant("tix", default=False, description="Build Tix module", when="+tkinter") variant("crypt", default=True, description="Build crypt module", when="@:3.12 platform=linux") variant("crypt", default=True, description="Build crypt module", when="@:3.12 platform=darwin") - variant("crypt", default=True, description="Build crypt module", when="@:3.12 platform=cray") if sys.platform != "win32": depends_on("gmake", type="build") @@ -545,7 +571,8 @@ def win_installer(self, prefix): copy(lib, prefix) else: copy(lib, prefix.DLLs) - static_libraries = glob.glob("%s\\*.lib") + static_libraries = glob.glob("%s\\*.lib" % build_root) + os.makedirs(prefix.libs, exist_ok=True) for lib in static_libraries: copy(lib, prefix.libs) @@ -1114,7 +1141,7 @@ def platlib(self): path = self.config_vars["platlib"] if path.startswith(prefix): return path.replace(prefix, "") - return os.path.join("lib64", "python{}".format(self.version.up_to(2)), "site-packages") + return os.path.join("lib64", f"python{self.version.up_to(2)}", "site-packages") @property def purelib(self): @@ -1134,7 +1161,7 @@ def purelib(self): path = self.config_vars["purelib"] if path.startswith(prefix): return path.replace(prefix, "") - return os.path.join("lib", "python{}".format(self.version.up_to(2)), "site-packages") + return os.path.join("lib", f"python{self.version.up_to(2)}", "site-packages") @property def include(self): @@ -1162,34 +1189,6 @@ def setup_dependent_build_environment(self, env, dependent_spec): """Set PYTHONPATH to include the site-packages directory for the extension and any other python extensions it depends on. """ - # Ensure the current Python is first in the PATH - path = os.path.dirname(self.command.path) - if not is_system_path(path): - env.prepend_path("PATH", path) - - # Add installation prefix to PYTHONPATH, needed to run import tests - prefixes = set() - if dependent_spec.package.extends(self.spec): - prefixes.add(dependent_spec.prefix) - - # Add direct build/run/test dependencies to PYTHONPATH, - # needed to build the package and to run import tests - for direct_dep in dependent_spec.dependencies(deptype=("build", "run", "test")): - if direct_dep.package.extends(self.spec): - prefixes.add(direct_dep.prefix) - - # Add recursive run dependencies of all direct dependencies, - # needed by direct dependencies at run-time - for indirect_dep in direct_dep.traverse(deptype="run"): - if indirect_dep.package.extends(self.spec): - prefixes.add(indirect_dep.prefix) - - for prefix in prefixes: - # Packages may be installed in platform-specific or platform-independent - # site-packages directories - for directory in {self.platlib, self.purelib}: - env.prepend_path("PYTHONPATH", os.path.join(prefix, directory)) - # We need to make sure that the extensions are compiled and linked with # the Spack wrapper. Paths to the executables that are used for these # operations are normally taken from the sysconfigdata file, which we @@ -1235,9 +1234,7 @@ def setup_dependent_build_environment(self, env, dependent_spec): # invoked directly (no change would be required in that case # because Spack arranges for the Spack ld wrapper to be the # first instance of "ld" in PATH). - new_link = config_link.replace( - " {0} ".format(config_compile), " {0} ".format(new_compile) - ) + new_link = config_link.replace(f" {config_compile} ", f" {new_compile} ") # There is logic in the sysconfig module that is sensitive to the # fact that LDSHARED is set in the environment, therefore we export @@ -1250,65 +1247,49 @@ def setup_dependent_run_environment(self, env, dependent_spec): """Set PYTHONPATH to include the site-packages directory for the extension and any other python extensions it depends on. """ - if dependent_spec.package.extends(self.spec): - # Packages may be installed in platform-specific or platform-independent - # site-packages directories - for directory in {self.platlib, self.purelib}: - env.prepend_path("PYTHONPATH", os.path.join(dependent_spec.prefix, directory)) + if not dependent_spec.package.extends(self.spec) or dependent_spec.dependencies( + "python-venv" + ): + return + + # Packages may be installed in platform-specific or platform-independent site-packages + # directories + for directory in {self.platlib, self.purelib}: + env.prepend_path("PYTHONPATH", os.path.join(dependent_spec.prefix, directory)) def setup_dependent_package(self, module, dependent_spec): """Called before python modules' install() methods.""" - module.python = self.command - module.python_include = join_path(dependent_spec.prefix, self.include) module.python_platlib = join_path(dependent_spec.prefix, self.platlib) module.python_purelib = join_path(dependent_spec.prefix, self.purelib) def add_files_to_view(self, view, merge_map, skip_if_exists=True): - # The goal is to copy the `python` executable, so that its search paths are relative to the - # view instead of the install prefix. This is an obsolete way of creating something that - # resembles a virtual environnent. Also we copy scripts with shebang lines. Finally we need - # to re-target symlinks pointing to copied files. - bin_dir = self.spec.prefix.bin if sys.platform != "win32" else self.spec.prefix - copied_files: Dict[Tuple[int, int], str] = {} # File identifier -> source - delayed_links: List[Tuple[str, str]] = [] # List of symlinks from merge map - for src, dst in merge_map.items(): - if skip_if_exists and os.path.lexists(dst): - continue - - # Files not in the bin dir are linked the default way. - if not path_contains_subdirectory(src, bin_dir): - view.link(src, dst, spec=self.spec) - continue - - s = os.lstat(src) - - # Symlink is delayed because we may need to re-target if its target is copied in view - if stat.S_ISLNK(s.st_mode): - delayed_links.append((src, dst)) - continue - - # Anything that's not a symlink gets copied. Scripts with shebangs are immediately - # updated when necessary. - copied_files[(s.st_dev, s.st_ino)] = dst - copy(src, dst) - if is_nonsymlink_exe_with_shebang(src): - filter_file( - self.spec.prefix, os.path.abspath(view.get_projection_for_spec(self.spec)), dst - ) - - # Finally re-target the symlinks that point to copied files. - for src, dst in delayed_links: - try: - s = os.stat(src) - target = copied_files[(s.st_dev, s.st_ino)] - except (OSError, KeyError): - target = None - if target: - os.symlink(os.path.relpath(target, os.path.dirname(dst)), dst) - else: - view.link(src, dst, spec=self.spec) + """Make the view a virtual environment if it isn't one already. + + If `python-venv` is linked into the view, it will already be a virtual + environment. If not, then this is an older python that doesn't use the + python-venv support, or we may be using python packages that + use ``depends_on("python")`` but not ``extends("python")``. + + We used to copy the python interpreter in, but we can get the same effect in a + simpler way by adding a ``pyvenv.cfg`` to the environment. + + """ + super().add_files_to_view(view, merge_map, skip_if_exists=skip_if_exists) + + # location of python inside the view, where we will put the venv config + projection = view.get_projection_for_spec(self.spec) + pyvenv_cfg = os.path.join(projection, "pyvenv.cfg") + if os.path.lexists(pyvenv_cfg): + return + + # don't put a pyvenv.cfg in a copy view + if view.link_type == "copy": + return + + with open(pyvenv_cfg, "w") as cfg_file: + cfg_file.write(make_pyvenv_cfg(self.spec["python"], projection)) def test_hello_world(self): """run simple hello world program""" diff --git a/var/spack/repos/builtin/packages/q-e-sirius/package.py b/var/spack/repos/builtin/packages/q-e-sirius/package.py index 92593111c7d556..e376eece0fe40f 100644 --- a/var/spack/repos/builtin/packages/q-e-sirius/package.py +++ b/var/spack/repos/builtin/packages/q-e-sirius/package.py @@ -27,7 +27,10 @@ class QESirius(CMakePackage): submodules=True, ) - variant("mpi", default=True, description="Builds with MPI support") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=True, description="Enables OpenMP support") variant("libxc", default=False, description="Support functionals through libxc") variant("sirius_apps", default=False, description="Build SIRIUS standalone binaries") @@ -47,7 +50,7 @@ class QESirius(CMakePackage): depends_on("sirius +openmp", when="+openmp") depends_on("sirius@develop", when="@develop-ristretto") - depends_on("mpi", when="+mpi") + depends_on("mpi") depends_on("elpa", when="+elpa") depends_on("libxc", when="+libxc") depends_on("fftw-api@3") @@ -56,12 +59,9 @@ class QESirius(CMakePackage): depends_on("git", type="build") depends_on("pkgconfig", type="build") - conflicts("~mpi", when="+scalapack", msg="SCALAPACK requires MPI support") conflicts("~scalapack", when="+elpa", msg="ELPA requires SCALAPACK support") - with when("+mpi"): - depends_on("mpi") - variant("scalapack", default=True, description="Enables scalapack support") + variant("scalapack", default=True, description="Enables scalapack support") with when("+scalapack"): depends_on("scalapack") @@ -82,7 +82,7 @@ def cmake_args(self): "-DQE_ENABLE_CUDA=OFF", "-DQE_LAPACK_INTERNAL=OFF", "-DQE_ENABLE_DOC=OFF", - self.define_from_variant("QE_ENABLE_MPI", "mpi"), + "-DQE_ENABLE_MPI=ON", self.define_from_variant("QE_ENABLE_OPENMP", "openmp"), self.define_from_variant("QE_ENABLE_ELPA", "elpa"), self.define_from_variant("QE_ENABLE_LIBXC", "libxc"), diff --git a/var/spack/repos/builtin/packages/qb3/package.py b/var/spack/repos/builtin/packages/qb3/package.py index cf73be4670ac04..522f32ad6d4c28 100644 --- a/var/spack/repos/builtin/packages/qb3/package.py +++ b/var/spack/repos/builtin/packages/qb3/package.py @@ -16,6 +16,8 @@ class Qb3(CMakePackage): version("master", branch="master") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.5:", type="build") depends_on("libicd") diff --git a/var/spack/repos/builtin/packages/qca/package.py b/var/spack/repos/builtin/packages/qca/package.py index 1313a3558b109e..30247fc324af46 100644 --- a/var/spack/repos/builtin/packages/qca/package.py +++ b/var/spack/repos/builtin/packages/qca/package.py @@ -28,6 +28,9 @@ class Qca(CMakePackage): version("2.2.1", sha256="c67fc0fa8ae6cb3d0ba0fbd8fca8ee8e4c5061b99f1fd685fd7d9800cef17f6b") version("2.1.3", sha256="a5135ffb0250a40e9c361eb10cd3fe28293f0cf4e5c69d3761481eafd7968067") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("qt@4.2:") depends_on("qt@:5.10.0", when="@2.1.3") diff --git a/var/spack/repos/builtin/packages/qcachegrind/package.py b/var/spack/repos/builtin/packages/qcachegrind/package.py index 5328f8dc2f92a4..68bb80a8df7537 100644 --- a/var/spack/repos/builtin/packages/qcachegrind/package.py +++ b/var/spack/repos/builtin/packages/qcachegrind/package.py @@ -22,6 +22,8 @@ class Qcachegrind(QMakePackage): version("20.12.2", sha256="935cf6665fac274f84af84d0a30cc2fdf27d437234b9accbf8ec0a5dba6ad867") version("20.08.0", sha256="ffb50a7c536042ff11eed714b359b8bc419cb12402a31ebe78c3d06363f234e6") + depends_on("cxx", type="build") # generated + depends_on("qt@5.2:") depends_on("graphviz", type="run") diff --git a/var/spack/repos/builtin/packages/qcat/package.py b/var/spack/repos/builtin/packages/qcat/package.py index a6ebd8ae4b8751..5ccaf8d4090eb0 100644 --- a/var/spack/repos/builtin/packages/qcat/package.py +++ b/var/spack/repos/builtin/packages/qcat/package.py @@ -19,6 +19,8 @@ class Qcat(CMakePackage): version("master", branch="master") version("1.4", commit="f16032cf237837b1d32dde0c3daa6ad1ca4a912f") + depends_on("c", type="build") # generated + depends_on("zstd") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/qctool/package.py b/var/spack/repos/builtin/packages/qctool/package.py new file mode 100644 index 00000000000000..51f66823e5d513 --- /dev/null +++ b/var/spack/repos/builtin/packages/qctool/package.py @@ -0,0 +1,32 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Qctool(WafPackage): + """QCTOOL is a command-line utility program for manipulation and quality + control of gwas datasets and other genome-wide data. This repository contains + the source code for QCTOOL and a number of other command-line programs that + manipulate gwas datasets and other genomic data, such as: Inthinnerator, + HPTEST, and LDBIRD.""" + + homepage = "https://www.chg.ox.ac.uk/~gav/qctool_v2/index.html" + + license("BSL-1.0") + + version( + "2.2.0", + sha256="7ba47998a2559193483cebe3710ce14d4e5d55d2e123840b4d1614b88459a9fc", + url="https://enkre.net/cgi-bin/code/qctool/tarball/86639c1ad4/qctool-86639c1ad4.tar.gz", + ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + # Required external libraries as detailed in Prerequisites: + # https://enkre.net/cgi-bin/code/qctool/wiki?name=Compiling+QCTOOL + depends_on("zlib") diff --git a/var/spack/repos/builtin/packages/qd/package.py b/var/spack/repos/builtin/packages/qd/package.py index aaa6fd1b343684..b80efee78edd88 100644 --- a/var/spack/repos/builtin/packages/qd/package.py +++ b/var/spack/repos/builtin/packages/qd/package.py @@ -20,6 +20,10 @@ class Qd(AutotoolsPackage): version("2.3.13", commit="a57dde96b3255b80f7f39cd80217c213bf78d949") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/qemu/package.py b/var/spack/repos/builtin/packages/qemu/package.py index e5fdd5fd107838..5d81b6e9b57ef6 100644 --- a/var/spack/repos/builtin/packages/qemu/package.py +++ b/var/spack/repos/builtin/packages/qemu/package.py @@ -104,6 +104,9 @@ class Qemu(AutotoolsPackage): version("0.10.0", sha256="cd554729fa9d0ec17164afbc1cea62d02bde3db8e16db3fd1b8e71d8e1b3dd41") version("0.9.1", sha256="a9655a471d0649f5540b890447b35849c162d9b986bf2bbddcb68461748e0f42") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("glib@2.40:") depends_on("pixman@0.21.8:") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/qgis/package.py b/var/spack/repos/builtin/packages/qgis/package.py index 051a78660df694..83d12423576416 100644 --- a/var/spack/repos/builtin/packages/qgis/package.py +++ b/var/spack/repos/builtin/packages/qgis/package.py @@ -60,6 +60,9 @@ class Qgis(CMakePackage): version("3.4.15", sha256="81c93b72adbea41bd765294c0cdb09476a632d8b3f90101abc409ca9ea7fb04d") version("3.4.14", sha256="e138716c7ea84011d3b28fb9c75e6a79322fb66f532246393571906a595d7261") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("3d", default=False, description="Build QGIS 3D library") variant("analysis", default=True, description="Build QGIS analysis library") variant("apidoc", default=False, description="Build QGIS API doxygen documentation") @@ -188,9 +191,7 @@ class Qgis(CMakePackage): @run_before("cmake", when="^py-pyqt5") def fix_pyqt5_cmake(self): cmfile = FileFilter(join_path("cmake", "FindPyQt5.cmake")) - pyqtpath = join_path( - self.spec["py-pyqt5"].prefix, self.spec["python"].package.platlib, "PyQt5" - ) + pyqtpath = join_path(self.spec["py-pyqt5"].package.module.python_platlib, "PyQt5") cmfile.filter( 'SET(PYQT5_MOD_DIR "${Python_SITEARCH}/PyQt5")', 'SET(PYQT5_MOD_DIR "' + pyqtpath + '")', @@ -210,7 +211,7 @@ def fix_qsci_sip(self): pyqtx = "PyQt6" sip_inc_dir = join_path( - self.spec["qscintilla"].prefix, self.spec["python"].package.platlib, pyqtx, "bindings" + self.spec["qscintilla"].package.module.python_platlib, pyqtx, "bindings" ) with open(join_path("python", "gui", "pyproject.toml.in"), "a") as tomlfile: tomlfile.write(f'\n[tool.sip.project]\nsip-include-dirs = ["{sip_inc_dir}"]\n') diff --git a/var/spack/repos/builtin/packages/qgraf/package.py b/var/spack/repos/builtin/packages/qgraf/package.py index 722d97b8fa0de1..72b311a5980352 100644 --- a/var/spack/repos/builtin/packages/qgraf/package.py +++ b/var/spack/repos/builtin/packages/qgraf/package.py @@ -17,7 +17,10 @@ class Qgraf(Package): version("3.4.2", sha256="cfc029fb871c78943865ef8b51ebcd3cd4428448b8816714b049669dfdeab8aa") + depends_on("fortran", type="build") # generated + def install(self, spec, prefix): fortran = Executable(spack_fc) fortran("qgraf-{0}.f".format(self.spec.version), "-o", "qgraf") - install_tree(".", prefix) + mkdirp(prefix.bin) + install("./qgraf", prefix.bin) diff --git a/var/spack/repos/builtin/packages/qhull/package.py b/var/spack/repos/builtin/packages/qhull/package.py index c612e8e8163915..20f168d22da1e9 100644 --- a/var/spack/repos/builtin/packages/qhull/package.py +++ b/var/spack/repos/builtin/packages/qhull/package.py @@ -27,6 +27,9 @@ class Qhull(CMakePackage): version("2015.2", sha256="8b6dd67ff77ce1ee814da84f4134ef4bdce1f1031e570b8d83019ccef58b1c00") version("2012.1", sha256="cb1296fbb9ec8b7d6e8f4c239ad165590616f242c7c46f790c27d8dcebe96c6a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("qhull-unused-intel-17.02.patch", when="@2015.2") depends_on("cmake@3.0:", type="build") diff --git a/var/spack/repos/builtin/packages/qjson/package.py b/var/spack/repos/builtin/packages/qjson/package.py index 15605094e8c734..798d7ec477c49f 100644 --- a/var/spack/repos/builtin/packages/qjson/package.py +++ b/var/spack/repos/builtin/packages/qjson/package.py @@ -17,6 +17,8 @@ class Qjson(CMakePackage): version("0.9.0", sha256="e812617477f3c2bb990561767a4cd8b1d3803a52018d4878da302529552610d4") + depends_on("cxx", type="build") # generated + depends_on("qt") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/qmcpack/package.py b/var/spack/repos/builtin/packages/qmcpack/package.py index 33e1580946fe2d..5b9996e04f7427 100644 --- a/var/spack/repos/builtin/packages/qmcpack/package.py +++ b/var/spack/repos/builtin/packages/qmcpack/package.py @@ -47,6 +47,9 @@ class Qmcpack(CMakePackage, CudaPackage): version("3.1.1", tag="v3.1.1", commit="07611637f823187ac5133d6e2249cdb86b92b04d") version("3.1.0", tag="v3.1.0", commit="146d920cf33590eac6a7a976f88871c1fe6418a6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # These defaults match those in the QMCPACK manual variant( "build_type", diff --git a/var/spack/repos/builtin/packages/qmd-progress/package.py b/var/spack/repos/builtin/packages/qmd-progress/package.py index f3b0580d581770..02edafb729ed70 100644 --- a/var/spack/repos/builtin/packages/qmd-progress/package.py +++ b/var/spack/repos/builtin/packages/qmd-progress/package.py @@ -23,6 +23,9 @@ class QmdProgress(CMakePackage): version("1.1.0", sha256="757d2606d7b7f38e7f8f491bf7369b88de55062bae0b12a9928f0a5acae993bd") version("1.0.0", sha256="eed87e68b4a1533a3ed70c1662feca4ac890b985f3326fc94522c2f71f198fdc") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("graphlib", default=False, description="Build with Metis Suppport") variant("mpi", default=True, description="Build with MPI Support") variant("shared", default=True, description="Build shared libs") diff --git a/var/spack/repos/builtin/packages/qnnpack/package.py b/var/spack/repos/builtin/packages/qnnpack/package.py index 8acd47432103f4..072dbfc1572205 100644 --- a/var/spack/repos/builtin/packages/qnnpack/package.py +++ b/var/spack/repos/builtin/packages/qnnpack/package.py @@ -22,6 +22,9 @@ class Qnnpack(CMakePackage): version("2018-12-27", commit="6c62fddc6d15602be27e9e4cbb9e985151d2fa82") # py-torch@1.2 version("2018-12-04", commit="ef05e87cef6b8e719989ce875b5e1c9fdb304c05") # py-torch@1.0:1.1 + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@3.5:", type="build") depends_on("python", type="build") diff --git a/var/spack/repos/builtin/packages/qoz/package.py b/var/spack/repos/builtin/packages/qoz/package.py index 2cf3db6dcbf5b9..23f3a542f56944 100644 --- a/var/spack/repos/builtin/packages/qoz/package.py +++ b/var/spack/repos/builtin/packages/qoz/package.py @@ -12,9 +12,14 @@ class Qoz(CMakePackage): git = "https://github.com/robertu94/QoZ" homepage = git + version("2023.11.07", commit="611369be4b1cc7a12eaae02600baf8d232d4caa5") + version("2023.03.09", commit="537f6a52a39396f9c05e16a12ab160d8dc8b9d56") version("2022.04.26", commit="d28a7a8c9f703075441b700202b8a1ee185ded00") version("2023.03.09", commit="537f6a52a39396f9c05e16a12ab160d8dc8b9d56") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + maintainers("disheng222") depends_on("zstd") diff --git a/var/spack/repos/builtin/packages/qpdf/package.py b/var/spack/repos/builtin/packages/qpdf/package.py new file mode 100644 index 00000000000000..35da1767ef6f7e --- /dev/null +++ b/var/spack/repos/builtin/packages/qpdf/package.py @@ -0,0 +1,48 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + + +from spack.package import * + + +class Qpdf(CMakePackage): + """ + QPDF is a command-line tool and C++ library that performs + content-preserving transformations on PDF files. + """ + + homepage = "https://qpdf.sourceforge.io/" + url = "https://github.com/qpdf/qpdf/releases/download/v11.9.0/qpdf-11.9.0.tar.gz" + + maintainers("taliaferro") + + license("Apache-2.0", checked_by="taliaferro") + + version("11.9.0", sha256="9f5d6335bb7292cc24a7194d281fc77be2bbf86873e8807b85aeccfbff66082f") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant( + "crypto", + values=["openssl", "gnutls", "native", "implicit"], + default="implicit", + multi=False, + description="Provider of cryptographic functions.", + ) + + depends_on("zlib-api") + depends_on("jpeg") + depends_on("openssl", when="crypto=openssl") + depends_on("gnutls", when="crypto=gnutls") + + def cmake_args(self): + args = [] + if not self.spec.satisfies("crypto=implicit"): + crypto_type = self.spec.variants["crypto"].value.upper() + args.append("USE_IMPLICIT_CRYPTO=0") + args.append(f"REQUIRE_CRYPTO_{crypto_type}=1") + + return args diff --git a/var/spack/repos/builtin/packages/qperf/package.py b/var/spack/repos/builtin/packages/qperf/package.py index eb4344129828d4..695dd55daef6e1 100644 --- a/var/spack/repos/builtin/packages/qperf/package.py +++ b/var/spack/repos/builtin/packages/qperf/package.py @@ -20,6 +20,8 @@ class Qperf(AutotoolsPackage): version("0.4.11", sha256="b0ef2ffe050607566d06102b4ef6268aad08fdc52898620d429096e7b0767e75") version("0.4.10", sha256="94e26725b4f962eacca36d8ef48cd1fb5043721ac82c3f44018319e47a96cf6b") + depends_on("c", type="build") # generated + variant("verbs", default=True, description="Build with verbs support") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/qrmumps/package.py b/var/spack/repos/builtin/packages/qrmumps/package.py index d026958928448c..11dce1d20f9759 100644 --- a/var/spack/repos/builtin/packages/qrmumps/package.py +++ b/var/spack/repos/builtin/packages/qrmumps/package.py @@ -13,12 +13,16 @@ class Qrmumps(CMakePackage): homepage = "https://gitlab.com/qr_mumps/qr_mumps" git = "https://gitlab.com/qr_mumps/qr_mumps" - url = "https://gitlab.com/qr_mumps/qr_mumps/-/archive/3.0.4/qr_mumps-3.0.4.tar.gz" + url = "https://gitlab.com/qr_mumps/qr_mumps/-/archive/3.1/qr_mumps-3.1.tar.gz" maintainers("fpruvost") version("master", branch="master") + version("3.1", sha256="6e39dbfa1e6ad3730b006c8953a43cc6da3dfc91f00edeb68a641d364703b773") version("3.0.4", sha256="621a294c3bf1e60e4ea6ae29c0586760648947f650e0f86bbabaf82805fc17db") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("amd", default=True, description="Enable AMD ordering") variant("metis", default=True, description="Enable Metis ordering") variant("scotch", default=True, description="Enable Scotch ordering") diff --git a/var/spack/repos/builtin/packages/qrupdate/package.py b/var/spack/repos/builtin/packages/qrupdate/package.py index bdb85917bafe23..a7cbb2631aa096 100644 --- a/var/spack/repos/builtin/packages/qrupdate/package.py +++ b/var/spack/repos/builtin/packages/qrupdate/package.py @@ -20,6 +20,8 @@ class Qrupdate(MakefilePackage, SourceforgePackage): version("1.1.2", sha256="e2a1c711dc8ebc418e21195833814cb2f84b878b90a2774365f0166402308e08") + depends_on("fortran", type="build") # generated + depends_on("blas") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/qscintilla/package.py b/var/spack/repos/builtin/packages/qscintilla/package.py index bbf0b5a3090a5a..53e8e407f67a7f 100644 --- a/var/spack/repos/builtin/packages/qscintilla/package.py +++ b/var/spack/repos/builtin/packages/qscintilla/package.py @@ -24,6 +24,8 @@ class Qscintilla(QMakePackage): version("2.13.3", sha256="711d28e37c8fccaa8229e8e39a5b3b2d97f3fffc63da10b71c71b84fa3649398") version("2.12.0", sha256="2116181cce3076aa4897e36182532d0e6768081fb0cf6dcdd5be720519ab1434") + depends_on("cxx", type="build") # generated + variant("designer", default=False, description="Enable pluging for Qt-Designer") variant("python", default=False, description="Build python bindings") @@ -101,7 +103,7 @@ def make_qsci_python(self): with working_dir(join_path(self.stage.source_path, "Python")): copy(ftoml, "pyproject.toml") sip_inc_dir = join_path( - self.spec[py_pyqtx].prefix, self.spec["python"].package.platlib, pyqtx, "bindings" + self.spec[py_pyqtx].package.module.python_platlib, pyqtx, "bindings" ) with open("pyproject.toml", "a") as tomlfile: diff --git a/var/spack/repos/builtin/packages/qt-base/package.py b/var/spack/repos/builtin/packages/qt-base/package.py index 73817c28f48e75..b21ad2fe16d64b 100644 --- a/var/spack/repos/builtin/packages/qt-base/package.py +++ b/var/spack/repos/builtin/packages/qt-base/package.py @@ -93,6 +93,11 @@ class QtBase(QtPackage): license("BSD-3-Clause") + version("6.7.2", sha256="96b96e4fd0fc306502ed8b94a34cfa0bacc8a25d43c2e958dd6772b28f6b0e42") + version("6.7.1", sha256="d6950597ce1fc2e1cf374c3aa70c2d72532bb74150e9853d7127af86a8a6c7b4") + version("6.7.0", sha256="e17f016ec987092423e86d732c0f9786124598877fa00970fd806da113c02ca5") + version("6.6.3", sha256="11abfcae323d295129f644f1828064e05af7d64d49edb0e00bfb8e8cb9691259") + version("6.6.2", sha256="2cbdc4791c5838fddb1ce7ee693b165bb4acf3f81acd6c1bf9e56413b25050df") version("6.6.1", sha256="eb091c56e8c572d35d3da36f94f9e228892d43aecb559fa4728a19f0e44914c4") version("6.6.0", sha256="882f39ea3a40a0894cd64e515ce51711a4fab79b8c47bc0fe0279e99493a62cf") version("6.5.3", sha256="174021c4a630df2e7e912c2e523844ad3cb5f90967614628fd8aa15ddbab8bc5") @@ -109,6 +114,9 @@ class QtBase(QtPackage): version("6.2.4", sha256="657d1405b5e15afcf322cc75b881f62d6a56f16383707742a99eb87f53cb63de") version("6.2.3", sha256="2dd095fa82bff9e0feb7a9004c1b2fb910f79ecc6111aa64637c95a02b7a8abb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("dbus", default=False, description="Build with D-Bus support.") variant( "framework", default=bool(MACOS_VERSION), description="Build as a macOS Framework package." @@ -130,6 +138,8 @@ class QtBase(QtPackage): variant("widgets", default=True, when="+gui", description="Build with widgets.") # Dependencies, then variant- and version-specific dependencies + depends_on("cmake@3.21:", type="build", when="~shared") + depends_on("cmake@3.21:", type="build", when="platform=darwin") depends_on("double-conversion") depends_on("icu4c") depends_on("libxml2") diff --git a/var/spack/repos/builtin/packages/qt-declarative/package.py b/var/spack/repos/builtin/packages/qt-declarative/package.py index 42afc99912c153..b7961cf9ce372d 100644 --- a/var/spack/repos/builtin/packages/qt-declarative/package.py +++ b/var/spack/repos/builtin/packages/qt-declarative/package.py @@ -16,6 +16,11 @@ class QtDeclarative(QtPackage): license("BSD-3-Clause") + version("6.7.2", sha256="3b91d1b75f22221f39b93647d73c9fe7fc4b9c8d45ff0cec402626eab15d8dd8") + version("6.7.1", sha256="fdf4099cbced3ce56e5151122ae1eb924886492f9fc2eb6a353d60a23e8fde14") + version("6.7.0", sha256="dc3fec16cbe0f706b2b6114e5dbb884269543f2d679a0a3a63b4f686156adf73") + version("6.6.3", sha256="34757cb6f2960aaee2849ff9fabe3ec06499fb07f41ab4f9351ce602b85bebd3") + version("6.6.2", sha256="6079545e04e7704fcab8e50687e1ee9df8d3bb43288a1602ff0f142e640a5b51") version("6.6.1", sha256="b1f5a75c2ea967d21b2c45f56ba1de66e2bf14a581b2f0d8e776441f1bebd0e7") version("6.6.0", sha256="2e52ef00736a9954426adf454cfb365fabdffb5703c814c188bc866cbf9f4dad") version("6.5.3", sha256="563924e58ac517492acb1952af0fb950cd54045ef6d61b98de06fac728239811") @@ -32,6 +37,9 @@ class QtDeclarative(QtPackage): version("6.2.4", sha256="cd939d99c37e7723268804b9516e32f8dd64b985d847469c78b66b5f4481c548") version("6.2.3", sha256="eda82abfe685a6ab5664e4268954622ccd05cc9ec8fb16eaa453c54900591baf") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Testing requires +network depends_on("qt-base +network", type="test") diff --git a/var/spack/repos/builtin/packages/qt-quick3d/package.py b/var/spack/repos/builtin/packages/qt-quick3d/package.py index 0fea0bdab09de5..a08ad81acbe10a 100644 --- a/var/spack/repos/builtin/packages/qt-quick3d/package.py +++ b/var/spack/repos/builtin/packages/qt-quick3d/package.py @@ -16,6 +16,11 @@ class QtQuick3d(QtPackage): license("BSD-3-Clause") + version("6.7.2", sha256="67021658cb10bfa6d969c4219d599ab2f4775d08fb4ae56da17fbec305088b55") + version("6.7.1", sha256="c889b70305da7595df87c3bd062474787b722ab216bc2e6226e33fae3ec3459d") + version("6.7.0", sha256="3adb7cc458c21a4642e7138cc0ca12934cd7075633d06c46c689f65718c8ba73") + version("6.6.3", sha256="6990aac1434722cdf54fa6b3ebbae6d2af4d4dc89d6d33a2146c83c49be59ecb") + version("6.6.2", sha256="b99184a1ef912219374b2bb9a9b1899c1c55694736bc3185e2306db16c66b4ab") version("6.6.1", sha256="57abc6e178d2b28cfac544c71cb20f362409267be5422ca3fbaa46a1bbfd5515") version("6.6.0", sha256="2cda12649cfb6c23261c48e626714ca7eb01fa4b20e0bed02031f9c488c820ad") version("6.5.3", sha256="5df7494824c44fc73c03348b218166db5c4d8d42bd7d221f15e58c962cf657e5") @@ -32,6 +37,8 @@ class QtQuick3d(QtPackage): version("6.2.4", sha256="7292ed4373a92913c6811f2faa5191f0426f84bd93a3f6eb7d54b62626b56db5") version("6.2.3", sha256="35d06edbdd83b7d781b70e0bada18911fa9b774b6403589d5b21813a73584d80") + depends_on("cxx", type="build") # generated + depends_on("qt-base +network", when="@6.3.0:") depends_on("assimp@5.0.1:") diff --git a/var/spack/repos/builtin/packages/qt-quicktimeline/package.py b/var/spack/repos/builtin/packages/qt-quicktimeline/package.py index a312f667ee268c..7227ae1b04f3e1 100644 --- a/var/spack/repos/builtin/packages/qt-quicktimeline/package.py +++ b/var/spack/repos/builtin/packages/qt-quicktimeline/package.py @@ -16,6 +16,11 @@ class QtQuicktimeline(QtPackage): license("BSD-3-Clause") + version("6.7.2", sha256="ad5370a3b193c5d30a824a1def0608e12fb735c4ff20ae55161a6f6e202e091d") + version("6.7.1", sha256="98766368b4650eef583f76d257573e6785938b89c9eb2fc57577f4c199b12a1f") + version("6.7.0", sha256="9c8d953d4dfbe2a42dbbd88c26b4b01f6caab4d525ec01eb66edc71e9ee39172") + version("6.6.3", sha256="6dccea9ebc8a6507ffb046cada1dd339b8187923bb74b938f8ccdcb0a5590095") + version("6.6.2", sha256="76e629f019f6bdd9d46efbde2704dfe104231879ad60eebd81d9585250aa618b") version("6.6.1", sha256="fe77555566bd6bb0ef0cb67b6ad09e225399fba3d2ec388de84e8a6200c0e2fc") version("6.6.0", sha256="06b94443da3f81153f04dca0cce781481462310d51f97d5550f81322a7a88cd0") version("6.5.3", sha256="fddd90cdb15af093673c6da924e18e22ebd364b9ab215356e1b40db28ac66640") @@ -32,6 +37,8 @@ class QtQuicktimeline(QtPackage): version("6.2.4", sha256="d73cb33e33f0b7a1825b863c22e6b552ae86aa841bcb805a41aca02526a4e8bc") version("6.2.3", sha256="bbb913398d8fb6b5b20993b5e02317de5c1e4b23a5357dd5d08a237ada6cc7e2") + depends_on("cxx", type="build") # generated + for _v in QtBase.versions: v = str(_v) depends_on("qt-base@" + v, when="@" + v) diff --git a/var/spack/repos/builtin/packages/qt-shadertools/package.py b/var/spack/repos/builtin/packages/qt-shadertools/package.py index 6c06e8992a122c..f1ef9717b78094 100644 --- a/var/spack/repos/builtin/packages/qt-shadertools/package.py +++ b/var/spack/repos/builtin/packages/qt-shadertools/package.py @@ -18,6 +18,11 @@ class QtShadertools(QtPackage): license("BSD-3-Clause") + version("6.7.2", sha256="256ff8199d9f6e97bef57f602c5fa7a32e3c7588bf7efe39e412b810c7ed4ffc") + version("6.7.1", sha256="56cfba20c7e8f7a218cac68d237a63ea342ac9a67211ecdf3c7152572632448b") + version("6.7.0", sha256="82d9ef04a470db30e90253ddc72fcbc8fea2ecad419a735ecf64bb965560197f") + version("6.6.3", sha256="a0e44248cec9011166794da895952cc1f98ddbfa77180174da925c5f749391a8") + version("6.6.2", sha256="c6d06a660779990f69b8b2e21eb01ada784f9144cbaeb718ee0da01c33ce2141") version("6.6.1", sha256="1206110464f8829e34ca7277bdcd2044e96a98078c9ab9f8b96ed526a4d81526") version("6.6.0", sha256="8b34908f8bbc7fb00a00babede91dbbeec9826f5138d390041f239d483e1162a") version("6.5.3", sha256="e6c627763db8c60799218947443efb90fb3511342f2212f5e99cd98f6942ed08") @@ -34,6 +39,8 @@ class QtShadertools(QtPackage): version("6.2.4", sha256="c3332d91e0894086634d5f8d40638439e6e3653a3a185e1b5f5d23ae3b9f51a1") version("6.2.3", sha256="658c4acc2925e57d35bbd38cdf49c08297555ed7d632f9e86bfef76e6d861562") + depends_on("cxx", type="build") # generated + depends_on("qt-base +gui") for _v in QtBase.versions: diff --git a/var/spack/repos/builtin/packages/qt-svg/package.py b/var/spack/repos/builtin/packages/qt-svg/package.py index c20ffe0ab797c3..d42435979a0981 100644 --- a/var/spack/repos/builtin/packages/qt-svg/package.py +++ b/var/spack/repos/builtin/packages/qt-svg/package.py @@ -18,6 +18,11 @@ class QtSvg(QtPackage): license("BSD-3-Clause") + version("6.7.2", sha256="c0e140bbba4157cdbbe0e84ddbb4e238b87aa0ca7b870bad283d8cf2a7fa74b6") + version("6.7.1", sha256="55134e1242305e554610bf1a77e71d3d15104ee819a3c87def1f8b736d5ecf0e") + version("6.7.0", sha256="ea023d11c710145786833649c3dc79dd099110fc3a9756a8a88699eeaac949f1") + version("6.6.3", sha256="75006cc389ac86f2705dbb93a8c278b6b96c6cfa46304640312367e61740170d") + version("6.6.2", sha256="4228731a00899ee27bf59e131fa0d3e9105d3f479ac27bc8cfd458e409398ec0") version("6.6.1", sha256="b947acd83ac51116f29c7f7278d9faed19b8c11e021dbf08616e7d6200118db8") version("6.6.0", sha256="4fd6b4d9307c3cd8fd207e60334823fed07a9acb32f7d53cd9c9be9b6a2f8a30") version("6.5.3", sha256="fb8e5574c2480aab78062fad2d0a521633b4591ada600130b918b703c2ddb09a") @@ -30,6 +35,8 @@ class QtSvg(QtPackage): version("6.4.0", sha256="375eb69f320121e42d5dc107f9455008980c149646931b8ace19e6bc235dcd80") version("6.3.2", sha256="781055bca458be46ef69f2fff147a00226e41f3a23d02c91238b0328a7156518") + depends_on("cxx", type="build") # generated + variant("widgets", default=False, description="Build SVG widgets.") depends_on("qt-base +gui") diff --git a/var/spack/repos/builtin/packages/qt/package.py b/var/spack/repos/builtin/packages/qt/package.py index ceb3011e935311..aed8175a63b8ef 100644 --- a/var/spack/repos/builtin/packages/qt/package.py +++ b/var/spack/repos/builtin/packages/qt/package.py @@ -33,6 +33,8 @@ class Qt(Package): license("LGPL-3.0-only") + version("5.15.14", sha256="fdd3a4f197d2c800ee0085c721f4bef60951cbda9e9c46e525d1412f74264ed7") + version("5.15.13", sha256="9550ec8fc758d3d8d9090e261329700ddcd712e2dda97e5fcfeabfac22bea2ca") version("5.15.12", sha256="93f2c0889ee2e9cdf30c170d353c3f829de5f29ba21c119167dee5995e48ccce") version("5.15.11", sha256="7426b1eaab52ed169ce53804bdd05dfe364f761468f888a0f15a308dc1dc2951") version("5.15.10", sha256="b545cb83c60934adc9a6bbd27e2af79e5013de77d46f5b9f5bb2a3c762bf55ca") @@ -55,6 +57,9 @@ class Qt(Package): version("4.8.5", sha256="eb728f8268831dc4373be6403b7dd5d5dde03c169ad6882f9a8cb560df6aa138") version("3.3.8b", sha256="1b7a1ff62ec5a9cb7a388e2ba28fda6f960b27f27999482ebeceeadb72ac9f6e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("debug", default=False, description="Build debug version.") variant("dbus", default=False, description="Build with D-Bus support.") variant("doc", default=False, description="Build QDoc and documentation.") @@ -251,6 +256,11 @@ class Qt(Package): # https://doc.qt.io/qt-5.14/supported-platforms.html conflicts("%gcc@:4", when="@5.14:") + # Compiling with oneAPI compilers icx, icpx requires patching + # This has only been tested for 5.15.14 so far + conflicts("%oneapi", when="@:5.15.13") + patch("qt51514-oneapi.patch", when="@5.15.14: %oneapi") + # Non-macOS dependencies and special macOS constraints if MACOS_VERSION is None: with when("+gui"): @@ -280,12 +290,17 @@ class Qt(Package): # Mapping for compilers/systems in the QT 'mkspecs' compiler_mapping = { "intel": ("icc",), + # This only works because we apply patch "qt51514-oneapi.patch" + # above that replaces calls to "icc" with calls to "icx" in + # qtbase/mkspecs/* + "oneapi": ("icc",), "apple-clang": ("clang-libc++", "clang"), "clang": ("clang-libc++", "clang"), + "aocc": ("clang-libc++", "clang"), "fj": ("clang",), "gcc": ("g++",), } - platform_mapping = {"darwin": ("macx"), "cray": ("linux")} + platform_mapping = {"darwin": ("macx")} def url_for_version(self, version): # URL keeps getting more complicated with every release diff --git a/var/spack/repos/builtin/packages/qt/qt51514-oneapi.patch b/var/spack/repos/builtin/packages/qt/qt51514-oneapi.patch new file mode 100644 index 00000000000000..e4335ec25bbbc5 --- /dev/null +++ b/var/spack/repos/builtin/packages/qt/qt51514-oneapi.patch @@ -0,0 +1,31 @@ +--- a/qtbase/mkspecs/common/icc-base-unix.conf 2024-05-07 23:17:16.000000000 -0600 ++++ b/qtbase/mkspecs/common/icc-base-unix.conf 2024-07-10 21:32:47.808327220 -0600 +@@ -16,7 +16,7 @@ + QMAKE_CFLAGS_OPTIMIZE = -O2 + QMAKE_CFLAGS_OPTIMIZE_SIZE = -Os + +-QMAKE_CC = icc ++QMAKE_CC = icx + QMAKE_LEX = flex + QMAKE_LEXFLAGS = + QMAKE_YACC = yacc +@@ -61,7 +61,7 @@ + QMAKE_CFLAGS_SHANI += -msha + QMAKE_CFLAGS_VAES += -mvaes + +-QMAKE_CXX = icpc ++QMAKE_CXX = icpx + QMAKE_CXXFLAGS = $$QMAKE_CFLAGS + QMAKE_CXXFLAGS_APP = $$QMAKE_CFLAGS_APP + QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS +@@ -92,8 +92,8 @@ + QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden + QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS -fvisibility-inlines-hidden + +-QMAKE_LINK = icpc +-QMAKE_LINK_SHLIB = icpc ++QMAKE_LINK = icpx ++QMAKE_LINK_SHLIB = icpx + QMAKE_LFLAGS = + QMAKE_LFLAGS_RELEASE = + QMAKE_LFLAGS_DEBUG = diff --git a/var/spack/repos/builtin/packages/qtgraph/package.py b/var/spack/repos/builtin/packages/qtgraph/package.py index ed5d649dcbee1a..78aff2df9a3f97 100644 --- a/var/spack/repos/builtin/packages/qtgraph/package.py +++ b/var/spack/repos/builtin/packages/qtgraph/package.py @@ -20,6 +20,8 @@ class Qtgraph(QMakePackage): version("develop", branch="master") version("1.0.0.0", branch="1.0.0.0") + depends_on("cxx", type="build") # generated + # qtgraph depends on these packages depends_on("qt@5.10.0:", when="@1.0.0.0:") diff --git a/var/spack/repos/builtin/packages/qthreads/package.py b/var/spack/repos/builtin/packages/qthreads/package.py index 391afc70f357bd..51f83c2b8f9e2f 100644 --- a/var/spack/repos/builtin/packages/qthreads/package.py +++ b/var/spack/repos/builtin/packages/qthreads/package.py @@ -45,6 +45,9 @@ class Qthreads(AutotoolsPackage): version("1.11", sha256="dbde6c7cb7de7e89921e47363d09cecaebf775c9d090496c2be8350355055571") version("1.10", sha256="29fbc2e54bcbc814c1be13049790ee98c505f22f22ccee34b7c29a4295475656") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("restrict.patch", when="@:1.10") patch("trap.patch", when="@:1.10") diff --git a/var/spack/repos/builtin/packages/qtkeychain/package.py b/var/spack/repos/builtin/packages/qtkeychain/package.py index b6ebbf2379f97f..3909afe98ab9eb 100644 --- a/var/spack/repos/builtin/packages/qtkeychain/package.py +++ b/var/spack/repos/builtin/packages/qtkeychain/package.py @@ -16,6 +16,8 @@ class Qtkeychain(CMakePackage): version("0.9.1", sha256="9c2762d9d0759a65cdb80106d547db83c6e9fdea66f1973c6e9014f867c6f28e") + depends_on("cxx", type="build") # generated + depends_on("qt+dbus") depends_on("libsecret") diff --git a/var/spack/repos/builtin/packages/qtltools/package.py b/var/spack/repos/builtin/packages/qtltools/package.py index b9393e8721bf1e..71388a715afb14 100644 --- a/var/spack/repos/builtin/packages/qtltools/package.py +++ b/var/spack/repos/builtin/packages/qtltools/package.py @@ -17,6 +17,8 @@ class Qtltools(MakefilePackage): version("1.3.1", sha256="033b9b61923fd65c4b8b80bc0add321e6fd6fb40de49d15c2dfe6a4d7e60764a") version("1.3", sha256="032020d7e038eac4ec01701343a887bced7cca356cbd24b3d5bbadf83686faeb") + depends_on("cxx", type="build") # generated + depends_on("boost +pic +iostreams +program_options") depends_on("gsl") depends_on("htslib ~libcurl ~libdeflate") diff --git a/var/spack/repos/builtin/packages/qualimap/package.py b/var/spack/repos/builtin/packages/qualimap/package.py index bfa8af70600088..69a327b5521e77 100644 --- a/var/spack/repos/builtin/packages/qualimap/package.py +++ b/var/spack/repos/builtin/packages/qualimap/package.py @@ -17,6 +17,7 @@ class Qualimap(Package): license("GPL-2.0-or-later") + version("2.3", sha256="2a04dd864b712da30923cce3bc8dfc6ea59612118e8b0ff1a246fe43b8d34c40") version("2.2.1", sha256="08f1d66e49c83c76c56c4225c53aee44f41e0592c8bdc84b8c4ecd975700e045") depends_on("java", type="run") diff --git a/var/spack/repos/builtin/packages/quantum-espresso/package.py b/var/spack/repos/builtin/packages/quantum-espresso/package.py index 39e9fa7d9c18f7..23509f06c4c915 100644 --- a/var/spack/repos/builtin/packages/quantum-espresso/package.py +++ b/var/spack/repos/builtin/packages/quantum-espresso/package.py @@ -48,6 +48,10 @@ class QuantumEspresso(CMakePackage, Package): version("5.4", sha256="e3993fccae9cea04a5c6492e8b961a053a63727051cb5c4eb6008f62cda8f335") version("5.3", sha256="3b26038efb9e3f8ac7a2b950c31d8c29169a3556c0b68c299eb88a4be8dc9048") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + resource( name="environ", git="https://github.com/environ-developers/Environ.git", @@ -296,6 +300,11 @@ class QuantumEspresso(CMakePackage, Package): conflicts("@6.5:", when="+environ", msg="6.4.x is the latest QE series supported by Environ") + # 7.3 - a compile-time problem fixed in 7.3.1 + patch_url = "https://gitlab.com/QEF/q-e/-/commit/b98ff7539e5731728d2d49ac01021a57f2594027.diff" + patch_checksum = "04c125d249d1f076abe04bc4de39bd3b44a41a78d6233b638a17bd96f91443d5" + patch(patch_url, sha256=patch_checksum, when="@=7.3+elpa build_system=cmake") + # QE 7.1 fix post-processing install part 1/2 # see: https://gitlab.com/QEF/q-e/-/merge_requests/2005 patch_url = "https://gitlab.com/QEF/q-e/-/commit/4ca3afd4c6f27afcf3f42415a85a353a7be1bd37.diff" diff --git a/var/spack/repos/builtin/packages/qucs/package.py b/var/spack/repos/builtin/packages/qucs/package.py index 7d948dac68136f..cf5794016c923f 100644 --- a/var/spack/repos/builtin/packages/qucs/package.py +++ b/var/spack/repos/builtin/packages/qucs/package.py @@ -25,6 +25,9 @@ class Qucs(AutotoolsPackage): version("0.0.19", sha256="45c6434fde24c533e63550675ac21cdbd3cc6cbba29b82a1dc3f36e7dd4b3b3e") version("0.0.18", sha256="3609a18b57485dc9f19886ac6694667f3251702175bd1cbbbea37981b2c482a7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Can use external simulators: variant( "simulators", diff --git a/var/spack/repos/builtin/packages/quickjs/package.py b/var/spack/repos/builtin/packages/quickjs/package.py index 69347260894212..40b6deb3f137f0 100644 --- a/var/spack/repos/builtin/packages/quickjs/package.py +++ b/var/spack/repos/builtin/packages/quickjs/package.py @@ -27,6 +27,8 @@ class Quickjs(MakefilePackage): "2020-09-06", sha256="0021a3e8cdc6b61e225411d05e2841d2437e1ccf4b4cabb9a5f7685ebfb57717" ) + depends_on("c", type="build") # generated + variant("lto", default=True, when="%gcc", description="Enable link-time optimization") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/quicksilver/package.py b/var/spack/repos/builtin/packages/quicksilver/package.py index 81dfebea653a51..61357eed447601 100644 --- a/var/spack/repos/builtin/packages/quicksilver/package.py +++ b/var/spack/repos/builtin/packages/quicksilver/package.py @@ -22,6 +22,8 @@ class Quicksilver(MakefilePackage): version("master", branch="master") version("1.0", sha256="83371603b169ec75e41fb358881b7bd498e83597cd251ff9e5c35769ef22c59a") + depends_on("cxx", type="build") # generated + variant("openmp", default=True, description="Build with OpenMP support") variant("mpi", default=True, description="Build with MPI support") diff --git a/var/spack/repos/builtin/packages/quo-vadis/package.py b/var/spack/repos/builtin/packages/quo-vadis/package.py index 52ab8be754eae5..6bb6bd8ed414b7 100644 --- a/var/spack/repos/builtin/packages/quo-vadis/package.py +++ b/var/spack/repos/builtin/packages/quo-vadis/package.py @@ -19,6 +19,10 @@ class QuoVadis(CMakePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=True, description="Build with Fortran bindings") variant("mpi", default=True, description="Build with MPI support") variant("mpipat", default=False, description="Affirm MPI processes are threads") diff --git a/var/spack/repos/builtin/packages/quota/package.py b/var/spack/repos/builtin/packages/quota/package.py index 0e2fe920281991..0235a9e4fae586 100644 --- a/var/spack/repos/builtin/packages/quota/package.py +++ b/var/spack/repos/builtin/packages/quota/package.py @@ -16,5 +16,7 @@ class Quota(AutotoolsPackage): version("4.05", sha256="ef3b5b5d1014ed1344b46c1826145e20cbef8db967b522403c9a060761cf7ab9") + depends_on("c", type="build") # generated + def setup_run_environment(self, env): env.prepend_path("PATH", self.prefix.sbin) diff --git a/var/spack/repos/builtin/packages/qwt/package.py b/var/spack/repos/builtin/packages/qwt/package.py index d9540fdf795235..5258f7cfaedce7 100644 --- a/var/spack/repos/builtin/packages/qwt/package.py +++ b/var/spack/repos/builtin/packages/qwt/package.py @@ -24,6 +24,8 @@ class Qwt(QMakePackage): version("6.1.3", sha256="f3ecd34e72a9a2b08422fb6c8e909ca76f4ce5fa77acad7a2883b701f4309733") version("5.2.2", sha256="36bf2ee51ca9c74fde1322510ffd39baac0db60d5d410bb157968a78d9c1464b") + depends_on("cxx", type="build") # generated + variant("designer", default=False, description="Build extensions to QT designer") variant("opengl", default=False, description="Build OpenGL plot canvas") diff --git a/var/spack/repos/builtin/packages/qwtpolar/package.py b/var/spack/repos/builtin/packages/qwtpolar/package.py index 7e6fa96220a21f..0ade4950765dbd 100644 --- a/var/spack/repos/builtin/packages/qwtpolar/package.py +++ b/var/spack/repos/builtin/packages/qwtpolar/package.py @@ -16,6 +16,8 @@ class Qwtpolar(QMakePackage): version("1.1.1", sha256="6168baa9dbc8d527ae1ebf2631313291a1d545da268a05f4caa52ceadbe8b295") + depends_on("cxx", type="build") # generated + depends_on("qt@4.4:") depends_on("qwt@6.1:") diff --git a/var/spack/repos/builtin/packages/r-abaenrichment/package.py b/var/spack/repos/builtin/packages/r-abaenrichment/package.py index 52b9b30bce92e7..57a724e1410c06 100644 --- a/var/spack/repos/builtin/packages/r-abaenrichment/package.py +++ b/var/spack/repos/builtin/packages/r-abaenrichment/package.py @@ -33,6 +33,8 @@ class RAbaenrichment(RPackage): version("1.8.0", commit="cb8155ee9a04fb55b2a2e8c23df7c0be15bb2624") version("1.6.0", commit="d2a0467dcb7aa6e103e3b83dccd6510b0e142ac1") + depends_on("cxx", type="build") # generated + depends_on("r+X", type=("build", "run")) depends_on("r@3.2:", type=("build", "run")) depends_on("r@3.4:", type=("build", "run"), when="@1.8.0:") diff --git a/var/spack/repos/builtin/packages/r-acgh/package.py b/var/spack/repos/builtin/packages/r-acgh/package.py index 4ff4c218c4fee3..14d7d2fc8fff19 100644 --- a/var/spack/repos/builtin/packages/r-acgh/package.py +++ b/var/spack/repos/builtin/packages/r-acgh/package.py @@ -27,6 +27,8 @@ class RAcgh(RPackage): version("1.56.0", commit="f3531ec99fc181044bdcb6a01c9976029efb6235") version("1.54.0", commit="be2ed339449f55c8d218e10c435e4ad356683693") + depends_on("cxx", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-cluster", type=("build", "run")) depends_on("r-survival", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-acme/package.py b/var/spack/repos/builtin/packages/r-acme/package.py index 4e8b08b81e613b..24eb557dd215d9 100644 --- a/var/spack/repos/builtin/packages/r-acme/package.py +++ b/var/spack/repos/builtin/packages/r-acme/package.py @@ -32,6 +32,8 @@ class RAcme(RPackage): version("2.34.0", commit="1f53d43e420e245423fdf2711d0dcb345f829469") version("2.32.0", commit="76372255d7714a0c8128a11c028bf70214dac407") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-biobase@2.5.5:", type=("build", "run")) depends_on("r-biocgenerics", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-ade4/package.py b/var/spack/repos/builtin/packages/r-ade4/package.py index 00e03cb21ae1a5..3e98e658e158cd 100644 --- a/var/spack/repos/builtin/packages/r-ade4/package.py +++ b/var/spack/repos/builtin/packages/r-ade4/package.py @@ -30,6 +30,9 @@ class RAde4(RPackage): version("1.7-11", sha256="4ccd799ae99bd625840b866a697c4a48adb751660470bf0d6cf9207b1927a572") version("1.7-6", sha256="80848e1650dcc0ec921c130efa6f7e9b307f0d107c63e49faa52296eda19cc52") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-mass", type=("build", "run")) depends_on("r-pixmap", type=("build", "run"), when="@1.7-16:") diff --git a/var/spack/repos/builtin/packages/r-adegenet/package.py b/var/spack/repos/builtin/packages/r-adegenet/package.py index 50ab73ce474140..446132448816f3 100644 --- a/var/spack/repos/builtin/packages/r-adegenet/package.py +++ b/var/spack/repos/builtin/packages/r-adegenet/package.py @@ -32,6 +32,8 @@ class RAdegenet(RPackage): version("2.1.0", sha256="7ee44061002b41164bbc09256307ab02e536f4f2ac03f36c7dc8f85f6af4639a") version("2.0.1", sha256="7eddf46e64f680d54d034b68c50900d9bd5bc2e08309d062e230121b7460bb10") + depends_on("c", type="build") # generated + depends_on("r@2.14:", type=("build", "run")) depends_on("r-ade4", type=("build", "run")) depends_on("r-mass", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-adsplit/package.py b/var/spack/repos/builtin/packages/r-adsplit/package.py index 8a582acb5376d0..b2d58a8cf56f3d 100644 --- a/var/spack/repos/builtin/packages/r-adsplit/package.py +++ b/var/spack/repos/builtin/packages/r-adsplit/package.py @@ -27,6 +27,8 @@ class RAdsplit(RPackage): version("1.48.0", commit="57dfcd93b9232cf53f05c34179ecb759bb7aff46") version("1.46.0", commit="7e81a83f34d371447f491b3a146bf6851e260c7c") + depends_on("cxx", type="build") # generated + depends_on("r@2.1.0:", type=("build", "run")) depends_on("r-annotationdbi", type=("build", "run")) depends_on("r-biobase@1.5.12:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-affxparser/package.py b/var/spack/repos/builtin/packages/r-affxparser/package.py index 543556040ab382..8dd71d08e0821f 100644 --- a/var/spack/repos/builtin/packages/r-affxparser/package.py +++ b/var/spack/repos/builtin/packages/r-affxparser/package.py @@ -31,4 +31,7 @@ class RAffxparser(RPackage): version("1.50.0", commit="01ef641727eadc2cc17b5dbb0b1432364436e3d5") version("1.48.0", commit="2461ea88f310b59c4a9a997a4b3dadedbd65a4aa") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.14.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-affy/package.py b/var/spack/repos/builtin/packages/r-affy/package.py index 5fe87012da9dca..30dd0e578905d8 100644 --- a/var/spack/repos/builtin/packages/r-affy/package.py +++ b/var/spack/repos/builtin/packages/r-affy/package.py @@ -26,6 +26,8 @@ class RAffy(RPackage): version("1.56.0", commit="d36a7b8f05b1ef60162d94e75037d45c48f88871") version("1.54.0", commit="a815f02906fcf491b28ed0a356d6fce95a6bd20e") + depends_on("c", type="build") # generated + depends_on("r@2.8.0:4.0", type=("build", "run"), when="@:1.68.0") depends_on("r-biocgenerics@0.1.12:", type=("build", "run")) depends_on("r-biobase@2.5.5:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-affyio/package.py b/var/spack/repos/builtin/packages/r-affyio/package.py index b32ca1b9443ff8..d8cd59aad64602 100644 --- a/var/spack/repos/builtin/packages/r-affyio/package.py +++ b/var/spack/repos/builtin/packages/r-affyio/package.py @@ -26,6 +26,8 @@ class RAffyio(RPackage): version("1.48.0", commit="01727a4492c3a0d50453fc91892e04bf5f7fcadb") version("1.46.0", commit="977597f2772e08273d86579486f452170566c880") + depends_on("c", type="build") # generated + depends_on("r@2.6.0:", type=("build", "run")) depends_on("r-zlibbioc", type=("build", "run")) depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/r-affyplm/package.py b/var/spack/repos/builtin/packages/r-affyplm/package.py index b760df5b0206d2..b1b685e85a5074 100644 --- a/var/spack/repos/builtin/packages/r-affyplm/package.py +++ b/var/spack/repos/builtin/packages/r-affyplm/package.py @@ -28,6 +28,8 @@ class RAffyplm(RPackage): version("1.54.0", commit="09cf5f6e01dd2d0aae3e9ddab27301f04bfd645c") version("1.52.1", commit="e8613a6018c4ee58045df6bf19128844f50a1f43") + depends_on("c", type="build") # generated + depends_on("r@2.6.0:", type=("build", "run")) depends_on("r-biocgenerics@0.3.2:", type=("build", "run")) depends_on("r-affy@1.11.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-amap/package.py b/var/spack/repos/builtin/packages/r-amap/package.py index b440581cced234..70f1a10a92c94a 100644 --- a/var/spack/repos/builtin/packages/r-amap/package.py +++ b/var/spack/repos/builtin/packages/r-amap/package.py @@ -21,5 +21,9 @@ class RAmap(RPackage): version("0.8-17", sha256="6b8473d1d35a9cbc611661882c8f681162e8f913f911ccd51629200ae72289c6") version("0.8-16", sha256="d3775ad7f660581f7d2f070e426be95ae0d6743622943e6f5491988e5217d4e2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@2.10.0:", type=("build", "run")) depends_on("r@3.6.0:", type=("build", "run"), when="@0.8-17:") diff --git a/var/spack/repos/builtin/packages/r-analysispageserver/package.py b/var/spack/repos/builtin/packages/r-analysispageserver/package.py index 386fcac2a07211..b192ed5e60633f 100644 --- a/var/spack/repos/builtin/packages/r-analysispageserver/package.py +++ b/var/spack/repos/builtin/packages/r-analysispageserver/package.py @@ -21,6 +21,9 @@ class RAnalysispageserver(RPackage): version("1.12.0", commit="146501974ef1938ee1ec4eb293ea7eeca331a0dc") version("1.10.0", commit="876c87073be116fa15a1afdd407e21152eb80d50") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r-log4r", type=("build", "run")) depends_on("r-rjson", type=("build", "run")) depends_on("r-biobase", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-aneufinder/package.py b/var/spack/repos/builtin/packages/r-aneufinder/package.py index a4ef4ec68a064c..dda959bf5a051f 100644 --- a/var/spack/repos/builtin/packages/r-aneufinder/package.py +++ b/var/spack/repos/builtin/packages/r-aneufinder/package.py @@ -26,6 +26,8 @@ class RAneufinder(RPackage): version("1.6.0", commit="0cfbdd1951fb4df5622e002260cfa86294d65d1d") version("1.4.0", commit="e5bdf4d5e4f84ee5680986826ffed636ed853b8e") + depends_on("cxx", type="build") # generated + depends_on("r@3.3:", type=("build", "run")) depends_on("r@3.5:", type=("build", "run"), when="@1.10.2:") depends_on("r-genomicranges", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-anytime/package.py b/var/spack/repos/builtin/packages/r-anytime/package.py index 292e55f637caf6..c6e03b157efa82 100644 --- a/var/spack/repos/builtin/packages/r-anytime/package.py +++ b/var/spack/repos/builtin/packages/r-anytime/package.py @@ -20,6 +20,8 @@ class RAnytime(RPackage): version("0.3.9", sha256="1096c15249ac70997a8a41c37eeb2a6d38530621abeae05d3dcd96a8acc7574a") + depends_on("cxx", type="build") # generated + depends_on("r@3.2.0:", type=("build", "run")) depends_on("r-rcpp@0.12.9:", type=("build", "run")) depends_on("r-bh", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-arrangements/package.py b/var/spack/repos/builtin/packages/r-arrangements/package.py index e45989522be1ff..34c186409c06b1 100644 --- a/var/spack/repos/builtin/packages/r-arrangements/package.py +++ b/var/spack/repos/builtin/packages/r-arrangements/package.py @@ -23,6 +23,8 @@ class RArrangements(RPackage): version("1.1.9", sha256="e9b5dcb185ec9b28201b196384b04a8d5a15f4ddb9e0b0b2a0c718635ff7345b") + depends_on("c", type="build") # generated + depends_on("r@3.4.0:", type=("build", "run")) depends_on("r-gmp", type=("build", "run")) depends_on("r-r6", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-ash/package.py b/var/spack/repos/builtin/packages/r-ash/package.py index 44ff67e71e8de3..de2ec6bb691fb0 100644 --- a/var/spack/repos/builtin/packages/r-ash/package.py +++ b/var/spack/repos/builtin/packages/r-ash/package.py @@ -17,3 +17,5 @@ class RAsh(RPackage): license("GPL-2.0-or-later") version("1.0-15", sha256="8b0a7bc39dd0ce2172f09edc5b5e029347d041a4d508bbff3f3fd6f69450c2ab") + + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-asreml/package.py b/var/spack/repos/builtin/packages/r-asreml/package.py new file mode 100644 index 00000000000000..5cd9e69c6fffef --- /dev/null +++ b/var/spack/repos/builtin/packages/r-asreml/package.py @@ -0,0 +1,43 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + + +class RAsreml(RPackage): + """ASReml-R is a statistical package that fits linear mixed models using + Residual Maximum Likelihood (REML) in the R environment.""" + + homepage = "https://vsni.co.uk/software/asreml-r" + + manual_download = True + license_required = True + license_vars = ["vsni_LICENSE"] + license_files = ["vsni.lic"] + + maintainers("snehring") + + license("UNKNOWN", checked_by="snehring") + + version( + "4.2.0.302_R42", sha256="93196b68a987fd0a8d26fa7463cab60bd35c7be750c4832332945d71907425cd" + ) + version( + "4.2.0.302_R43", sha256="0a685521c80e3263ebb852886d3e1bd31213bd83507e7fffca34261ae18523f9" + ) + + depends_on("r@4.2.0:4.2", type=("build", "run"), when="@4.2.0.302_R42") + depends_on("r@4.3.0:4.3", type=("build", "run"), when="@4.2.0.302_R43") + depends_on("r-data-table", type=("build", "run")) + depends_on("r-ggplot2", type=("build", "run")) + depends_on("r-jsonlite", type=("build", "run")) + + def url_for_version(self, version): + return f"file://{os.getcwd()}//asreml_{version}_x86_64-pc-linux-gnu.tar.gz" + + def setup_run_environment(self, env): + env.set("vsni_LICENSE", join_path(self.prefix, "vsni.lic")) diff --git a/var/spack/repos/builtin/packages/r-bamsignals/package.py b/var/spack/repos/builtin/packages/r-bamsignals/package.py index 87e8bb932928ed..2911316cc24873 100644 --- a/var/spack/repos/builtin/packages/r-bamsignals/package.py +++ b/var/spack/repos/builtin/packages/r-bamsignals/package.py @@ -27,6 +27,9 @@ class RBamsignals(RPackage): version("1.10.0", commit="7499312ce71e8680680eda10b49d7dff682fc776") version("1.8.0", commit="b123b83e8e026c9ec91209d4498aff3e95a5de23") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.2.0:", type=("build", "run")) depends_on("r@3.5.0:", type=("build", "run"), when="@1.28.0:") depends_on("r-biocgenerics", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-base64enc/package.py b/var/spack/repos/builtin/packages/r-base64enc/package.py index 452015432cca48..f733104ad4f7d1 100644 --- a/var/spack/repos/builtin/packages/r-base64enc/package.py +++ b/var/spack/repos/builtin/packages/r-base64enc/package.py @@ -18,4 +18,6 @@ class RBase64enc(RPackage): version("0.1-3", sha256="6d856d8a364bcdc499a0bf38bfd283b7c743d08f0b288174fba7dbf0a04b688d") + depends_on("c", type="build") # generated + depends_on("r@2.9.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-bbmisc/package.py b/var/spack/repos/builtin/packages/r-bbmisc/package.py index 1affd66f3c4c3c..7354c642d5ddce 100644 --- a/var/spack/repos/builtin/packages/r-bbmisc/package.py +++ b/var/spack/repos/builtin/packages/r-bbmisc/package.py @@ -18,5 +18,7 @@ class RBbmisc(RPackage): version("1.12", sha256="900a633f69b7d9b13d58709eeae2fca2c1bc510765d778623a2af32cc870053e") version("1.11", sha256="1ea48c281825349d8642a661bb447e23bfd651db3599bf72593bfebe17b101d2") + depends_on("c", type="build") # generated + depends_on("r-checkmate@1.8.0:", type=("build", "run")) depends_on("r-data-table", type=("build", "run"), when="@1.12:") diff --git a/var/spack/repos/builtin/packages/r-beachmat/package.py b/var/spack/repos/builtin/packages/r-beachmat/package.py index 32afab212951bb..1eb9ae6668001a 100644 --- a/var/spack/repos/builtin/packages/r-beachmat/package.py +++ b/var/spack/repos/builtin/packages/r-beachmat/package.py @@ -27,6 +27,8 @@ class RBeachmat(RPackage): version("1.2.1", commit="ebae81772045a314e568c2f7d73ea3b27e7bf7d8") version("1.0.2", commit="6bd57b91d6428ac916f46572d685d3cb01a757f7") + depends_on("cxx", type="build") # generated + depends_on("r@3.4:", type=("build", "run")) depends_on("r@3.5:", type=("build", "run"), when="@1.2.1:1.4.0") depends_on("r-delayedarray", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-beeswarm/package.py b/var/spack/repos/builtin/packages/r-beeswarm/package.py index dc105aa4a7dfa8..b4abbf665f6e30 100644 --- a/var/spack/repos/builtin/packages/r-beeswarm/package.py +++ b/var/spack/repos/builtin/packages/r-beeswarm/package.py @@ -18,3 +18,5 @@ class RBeeswarm(RPackage): version("0.4.0", sha256="51f4339bf4080a2be84bb49a844c636625657fbed994abeaa42aead916c3d504") version("0.2.3", sha256="0115425e210dced05da8e162c8455526a47314f72e441ad2a33dcab3f94ac843") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-bfast/package.py b/var/spack/repos/builtin/packages/r-bfast/package.py index 7d933ac4ab813f..fd394995648290 100644 --- a/var/spack/repos/builtin/packages/r-bfast/package.py +++ b/var/spack/repos/builtin/packages/r-bfast/package.py @@ -32,6 +32,8 @@ class RBfast(RPackage): version("1.6.1", sha256="aaf479af1924691cbec8c67c68005c00d97cead51b2b44863c18acd4cea453ee") version("1.5.7", sha256="01585fe8944d05ebdb13795214077bc1365f0c0372e2a1f7edb914356dace558") + depends_on("cxx", type="build") # generated + depends_on("r@2.15.0:", type=("build", "run")) depends_on("r@3.0.0:", type=("build", "run"), when="@1.6.1:") depends_on("r-strucchangercpp", type=("build", "run"), when="@1.6.1:") diff --git a/var/spack/repos/builtin/packages/r-bio3d/package.py b/var/spack/repos/builtin/packages/r-bio3d/package.py index ebd95fd3656059..a93794734e4583 100644 --- a/var/spack/repos/builtin/packages/r-bio3d/package.py +++ b/var/spack/repos/builtin/packages/r-bio3d/package.py @@ -32,6 +32,9 @@ class RBio3d(RPackage): version("2.4-1", sha256="679fbd87fe9fb82a65427d281d3b68906509e411270cd87d2deb95d404333c1f") version("2.3-4", sha256="f9b39ab242cbedafcd98c1732cb1f5c0dd9ef66e28be39695e3420dd93e2bafe") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.1.0:", type=("build", "run")) depends_on("r-rcpp", type=("build", "run")) depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/r-biobase/package.py b/var/spack/repos/builtin/packages/r-biobase/package.py index bdc2abc2ff3fbd..cc525ccaa51d68 100644 --- a/var/spack/repos/builtin/packages/r-biobase/package.py +++ b/var/spack/repos/builtin/packages/r-biobase/package.py @@ -25,6 +25,8 @@ class RBiobase(RPackage): version("2.38.0", commit="83f89829e0278ac014b0bc6664e621ac147ba424") version("2.36.2", commit="15f50912f3fa08ccb15c33b7baebe6b8a59ce075") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-biocgenerics@0.3.2:", type=("build", "run")) depends_on("r-biocgenerics@0.27.1:", type=("build", "run"), when="@2.42.0:") diff --git a/var/spack/repos/builtin/packages/r-biocneighbors/package.py b/var/spack/repos/builtin/packages/r-biocneighbors/package.py index c9b62f26a2ca6b..e2118563c1b818 100644 --- a/var/spack/repos/builtin/packages/r-biocneighbors/package.py +++ b/var/spack/repos/builtin/packages/r-biocneighbors/package.py @@ -29,6 +29,8 @@ class RBiocneighbors(RPackage): version("1.2.0", commit="f754c6300f835142536a4594ddf750481e0fe273") version("1.0.0", commit="e252fc04b6d22097f2c5f74406e77d85e7060770") + depends_on("cxx", type="build") # generated + depends_on("r@3.5:", type=("build", "run"), when="@1.0.0") depends_on("r-rcpp", type=("build", "run")) depends_on("r-s4vectors", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-biocparallel/package.py b/var/spack/repos/builtin/packages/r-biocparallel/package.py index 3f61181f28f860..5caab131cb78b6 100644 --- a/var/spack/repos/builtin/packages/r-biocparallel/package.py +++ b/var/spack/repos/builtin/packages/r-biocparallel/package.py @@ -27,6 +27,8 @@ class RBiocparallel(RPackage): version("1.12.0", commit="2143a9addceed0151a27b95c70aadd2add5cbace") version("1.10.1", commit="a76c58cf99fd585ba5ea33065649e68f1afe0a7d") + depends_on("cxx", type="build") # generated + depends_on("r@3.5.0:", type=("build", "run"), when="@1.28.3:") depends_on("r-futile-logger", type=("build", "run")) depends_on("r-snow", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-biocsingular/package.py b/var/spack/repos/builtin/packages/r-biocsingular/package.py index 4546a53020a6c6..382eda5e3a424f 100644 --- a/var/spack/repos/builtin/packages/r-biocsingular/package.py +++ b/var/spack/repos/builtin/packages/r-biocsingular/package.py @@ -24,6 +24,8 @@ class RBiocsingular(RPackage): version("1.6.0", commit="11baf1080d6f791439cd5d97357589d6451643d9") version("1.0.0", commit="d2b091c072d0312698c9bb6611eb1bdf8aebf833") + depends_on("cxx", type="build") # generated + depends_on("r-biocgenerics", type=("build", "run")) depends_on("r-s4vectors", type=("build", "run")) depends_on("r-matrix", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-biostrings/package.py b/var/spack/repos/builtin/packages/r-biostrings/package.py index 796a66344f01b0..6164529db2b465 100644 --- a/var/spack/repos/builtin/packages/r-biostrings/package.py +++ b/var/spack/repos/builtin/packages/r-biostrings/package.py @@ -27,6 +27,8 @@ class RBiostrings(RPackage): version("2.46.0", commit="3bf6978c155498b50607d1bb471d1687d185a0fa") version("2.44.2", commit="e4a2b320fb21c5cab3ece7b3c6fecaedfb1e5200") + depends_on("c", type="build") # generated + depends_on("r@2.8.0:", type=("build", "run")) depends_on("r@3.5.0:", type=("build", "run"), when="@2.50.2:") depends_on("r@4.0.0:", type=("build", "run"), when="@2.62.0:") diff --git a/var/spack/repos/builtin/packages/r-biovizbase/package.py b/var/spack/repos/builtin/packages/r-biovizbase/package.py index d2f16d9104cf3a..a5cf3b4eed9b62 100644 --- a/var/spack/repos/builtin/packages/r-biovizbase/package.py +++ b/var/spack/repos/builtin/packages/r-biovizbase/package.py @@ -27,6 +27,8 @@ class RBiovizbase(RPackage): version("1.26.0", commit="640742f48384f01d117b70dc5c64737e97ae9b4b") version("1.24.0", commit="ae9cd2ff665b74a8f45ed9c1d17fc0a778b4af6c") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r@3.5.0:", type=("build", "run"), when="@1.38.0:") depends_on("r-scales", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-bit/package.py b/var/spack/repos/builtin/packages/r-bit/package.py index c386c3b77b47ea..5975ecd8271fc6 100644 --- a/var/spack/repos/builtin/packages/r-bit/package.py +++ b/var/spack/repos/builtin/packages/r-bit/package.py @@ -23,4 +23,6 @@ class RBit(RPackage): version("1.1-14", sha256="5cbaace1fb643a665a6ca69b90f7a6d624270de82420ca7a44f306753fcef254") version("1.1-12", sha256="ce281c87fb7602bf1a599e72f3e25f9ff7a13e390c124a4506087f69ad79d128") + depends_on("c", type="build") # generated + depends_on("r@2.9.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-bit64/package.py b/var/spack/repos/builtin/packages/r-bit64/package.py index a7e9027e821b00..717700888fe483 100644 --- a/var/spack/repos/builtin/packages/r-bit64/package.py +++ b/var/spack/repos/builtin/packages/r-bit64/package.py @@ -28,6 +28,8 @@ class RBit64(RPackage): version("4.0.5", sha256="25df6826ea5e93241c4874cad4fa8dadc87a40f4ff74c9107aa12a9e033e1578") version("0.9-7", sha256="7b9aaa7f971198728c3629f9ba1a1b24d53db5c7e459498b0fdf86bbd3dff61f") + depends_on("c", type="build") # generated + depends_on("r@3.0.1:", type=("build", "run")) depends_on("r-bit@1.1-12:", type=("build", "run")) depends_on("r-bit@4.0.0:", type=("build", "run"), when="@4.0.5:") diff --git a/var/spack/repos/builtin/packages/r-bitops/package.py b/var/spack/repos/builtin/packages/r-bitops/package.py index 07d2a29ad29e26..2816e2f8001961 100644 --- a/var/spack/repos/builtin/packages/r-bitops/package.py +++ b/var/spack/repos/builtin/packages/r-bitops/package.py @@ -18,3 +18,5 @@ class RBitops(RPackage): version("1.0-7", sha256="e9b5fc92c39f94a10cd0e13f3d6e2a9c17b75ea01467077a51d47a5f708517c4") version("1.0-6", sha256="9b731397b7166dd54941fb0d2eac6df60c7a483b2e790f7eb15b4d7b79c9d69c") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-bluster/package.py b/var/spack/repos/builtin/packages/r-bluster/package.py index da733833a5025d..367682bbb7739a 100644 --- a/var/spack/repos/builtin/packages/r-bluster/package.py +++ b/var/spack/repos/builtin/packages/r-bluster/package.py @@ -20,6 +20,8 @@ class RBluster(RPackage): version("1.8.0", commit="156115c8960c0b66b2c588d9fd8bbdfe56e5f0be") version("1.6.0", commit="ff86c7d8d36233e838d4f00e6a4e173e7bf16816") + depends_on("cxx", type="build") # generated + depends_on("r-cluster", type=("build", "run")) depends_on("r-matrix", type=("build", "run")) depends_on("r-rcpp", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-bridgesampling/package.py b/var/spack/repos/builtin/packages/r-bridgesampling/package.py index 61a5c61511e2ea..501306d0d00ad9 100644 --- a/var/spack/repos/builtin/packages/r-bridgesampling/package.py +++ b/var/spack/repos/builtin/packages/r-bridgesampling/package.py @@ -21,6 +21,8 @@ class RBridgesampling(RPackage): version("1.1-2", sha256="54ecd39aa2e36d4d521d3d36425f9fe56a3f8547df6048c814c5931d790f3e6b") + depends_on("cxx", type="build") # generated + depends_on("r@3.0.0:", type=("build", "run")) depends_on("r-mvtnorm", type=("build", "run")) depends_on("r-matrix", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-bsseq/package.py b/var/spack/repos/builtin/packages/r-bsseq/package.py index 27fd2500d5bc0f..8285f4545aff17 100644 --- a/var/spack/repos/builtin/packages/r-bsseq/package.py +++ b/var/spack/repos/builtin/packages/r-bsseq/package.py @@ -23,6 +23,8 @@ class RBsseq(RPackage): version("1.22.0", commit="d4f7301dcd4a03431b0833302b5a79c6f1b186cc") version("1.20.0", commit="07e398bc38ba903881df9a5d0577cca15788e0cd") + depends_on("cxx", type="build") # generated + depends_on("r@3.5:", type=("build", "run")) depends_on("r@4.0:", type=("build", "run"), when="@1.26.0:") depends_on("r-biocgenerics", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-c50/package.py b/var/spack/repos/builtin/packages/r-c50/package.py index 76ef1fa69747f6..955bc7b1cf0c42 100644 --- a/var/spack/repos/builtin/packages/r-c50/package.py +++ b/var/spack/repos/builtin/packages/r-c50/package.py @@ -23,6 +23,8 @@ class RC50(RPackage): version("0.1.1", sha256="03bc1fc2f64bcd5c680568a24902deafab1965074a66f8802bc4cd0335bd01df") version("0.1.0-24", sha256="617ee8ae617a075213414c07739ce92d9e6927783d01588fd0e2315157065e9d") + depends_on("c", type="build") # generated + depends_on("r@2.10.0:", type=("build", "run")) depends_on("r-partykit", type=("build", "run")) depends_on("r-cubist@0.2.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-caret/package.py b/var/spack/repos/builtin/packages/r-caret/package.py index ca64c4c695088d..38f5118a2dc0ac 100644 --- a/var/spack/repos/builtin/packages/r-caret/package.py +++ b/var/spack/repos/builtin/packages/r-caret/package.py @@ -26,6 +26,8 @@ class RCaret(RPackage): version("6.0-73", sha256="90a0a4a10f1a3b37502cb0ed7d8830063d059a548faabb9cc5d8d34736c7eacb") version("6.0-70", sha256="21c5bdf7cf07bece38729465366564d8ca104c2466ee9fd800ca1fd88eb82f38") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r@3.2.0:", type=("build", "run"), when="@6.0-82:") depends_on("r-ggplot2", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-catools/package.py b/var/spack/repos/builtin/packages/r-catools/package.py index db3c6466e8cde2..1d4a163a9f8bf3 100644 --- a/var/spack/repos/builtin/packages/r-catools/package.py +++ b/var/spack/repos/builtin/packages/r-catools/package.py @@ -23,6 +23,9 @@ class RCatools(RPackage): version("1.17.1.1", sha256="d53e2c5c77f1bd4744703d7196dbc9b4671a120bbb5b9b3edc45fc57c0650c06") version("1.17.1", sha256="d32a73febf00930355cc00f3e4e71357412e0f163faae6a4bf7f552cacfe9af4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.2.0:", type=("build", "run")) depends_on("r@3.6.0:", type=("build", "run"), when="@1.18.1:") depends_on("r-bitops", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-chipseq/package.py b/var/spack/repos/builtin/packages/r-chipseq/package.py index bad1c3369226c4..9980a4e6ff8fdb 100644 --- a/var/spack/repos/builtin/packages/r-chipseq/package.py +++ b/var/spack/repos/builtin/packages/r-chipseq/package.py @@ -21,6 +21,8 @@ class RChipseq(RPackage): version("1.44.0", commit="b64d0d28e9fcf0fdab9a7f9c521baf729426a594") version("1.40.0", commit="84bcbc0b7ad732730b5989a308f1624a6a358df1") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-biocgenerics@0.1.0:", type=("build", "run")) depends_on("r-s4vectors@0.17.25:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-cner/package.py b/var/spack/repos/builtin/packages/r-cner/package.py index bdfd6383ed3567..6b897405dfd70c 100644 --- a/var/spack/repos/builtin/packages/r-cner/package.py +++ b/var/spack/repos/builtin/packages/r-cner/package.py @@ -25,6 +25,8 @@ class RCner(RPackage): version("1.14.0", commit="b8634d65c51728c815127e22b45eba7c9b9db897") version("1.12.1", commit="90d611f9cd19a73d0fe92ab03ef428519d64c017") + depends_on("c", type="build") # generated + depends_on("r@3.2.2:", type=("build", "run")) depends_on("r@3.4:", type=("build", "run"), when="@1.14.0:") depends_on("r-biostrings@2.33.4:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-colorspace/package.py b/var/spack/repos/builtin/packages/r-colorspace/package.py index 0bcc256bd38ff8..b5d6797bda4ef3 100644 --- a/var/spack/repos/builtin/packages/r-colorspace/package.py +++ b/var/spack/repos/builtin/packages/r-colorspace/package.py @@ -38,4 +38,6 @@ class RColorspace(RPackage): version("1.3-2", sha256="dd9fd2342b650456901d014e7ff6d2e201f8bec0b555be63b1a878d2e1513e34") version("1.2-6", sha256="ba3165c5b906edadcd1c37cad0ef58f780b0af651f3fdeb49fbb2dc825251679") + depends_on("c", type="build") # generated + depends_on("r@3.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-colourpicker/package.py b/var/spack/repos/builtin/packages/r-colourpicker/package.py index 157c0f0d1c70e1..f95a51ac3d3972 100644 --- a/var/spack/repos/builtin/packages/r-colourpicker/package.py +++ b/var/spack/repos/builtin/packages/r-colourpicker/package.py @@ -20,6 +20,7 @@ class RColourpicker(RPackage): license("MIT") + version("1.3.0", sha256="c7f2618cd1ae1f7ac15aee072c648e6494dfff6714e13dc7cd1da993d1102510") version("1.2.0", sha256="bc2c80eee046219038baef9f8f213c9824d7fec7f893f6a1b881dd44b4a8638a") version("1.1.1", sha256="a0d09982b048b143e2c3438ccec039dd20d6f892fa0dedc9fdcb0d40de883ce0") version("1.1.0", sha256="2dfbb6262d187d3b17357ff9c22670ced3621feda5b2a2a500558478e4d551e2") diff --git a/var/spack/repos/builtin/packages/r-compquadform/package.py b/var/spack/repos/builtin/packages/r-compquadform/package.py index 1e45e86015363c..8dd2294e8184d4 100644 --- a/var/spack/repos/builtin/packages/r-compquadform/package.py +++ b/var/spack/repos/builtin/packages/r-compquadform/package.py @@ -16,3 +16,6 @@ class RCompquadform(RPackage): cran = "CompQuadForm" version("1.4.3", sha256="042fc56c800dd8f5f47a017e2efa832caf74f0602824abf7099898d9708660c4") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-conquer/package.py b/var/spack/repos/builtin/packages/r-conquer/package.py index 83045c8164676c..422156ccb2e09a 100644 --- a/var/spack/repos/builtin/packages/r-conquer/package.py +++ b/var/spack/repos/builtin/packages/r-conquer/package.py @@ -24,6 +24,8 @@ class RConquer(RPackage): version("1.2.1", sha256="1354f90f962a2124e155227cdc0ed2c6e54682f1e08934c49a827e51dc112f45") version("1.0.2", sha256="542f6154ce1ffec0c1b4dd4e1f5b86545015f4b378c4c66a0840c65c57d674ff") + depends_on("cxx", type="build") # generated + depends_on("r@3.5.0:", type=("build", "run")) depends_on("r-rcpp@1.0.3:", type=("build", "run")) depends_on("r-matrix", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-curl/package.py b/var/spack/repos/builtin/packages/r-curl/package.py index c688656ad03620..20b768c144e07b 100644 --- a/var/spack/repos/builtin/packages/r-curl/package.py +++ b/var/spack/repos/builtin/packages/r-curl/package.py @@ -27,12 +27,38 @@ class RCurl(RPackage): version("4.3.3", sha256="3567b6acad40dad68acfe07511c853824839d451a50219a96dd6d125ed617c9e") version("4.3.2", sha256="90b1facb4be8b6315bb3d272ba2dd90b88973f6ea1ab7f439550230f8500a568") version("4.3", sha256="7406d485bb50a6190e3ed201e3489063fd249b8b3b1b4f049167ac405a352edb") - version("4.0", sha256="09a99c9c86666449188fbb211cb1e9fbdb5108ab56f0d09322cd0ae50e926171") - version("3.3", sha256="0cb0b9a9280edc42ebed94708541ec86b4f48779e722171e45227eab8a88a5bd") - version("3.0", sha256="7bf8e3ae7cc77802ae300277e85d925d4c0611a9b7dad5c5601e0d2cbe14a506") - version("2.3", sha256="f901dad6bb70a6875a85da75bcbb42afffdcdf4ef221909733826bcb012d7c3d") - version("1.0", sha256="f8927228754fdfb21dbf08b9e67c5f97e06764c4adf327a4126eed84b1508f3d") - version("0.9.7", sha256="46e150998723fd1937da598f47f49fe47e40c1f57ec594436c6ef1e0145b44dc") + + # requires deprecated curl + version( + "4.0", + sha256="09a99c9c86666449188fbb211cb1e9fbdb5108ab56f0d09322cd0ae50e926171", + deprecated=True, + ) + version( + "3.3", + sha256="0cb0b9a9280edc42ebed94708541ec86b4f48779e722171e45227eab8a88a5bd", + deprecated=True, + ) + version( + "3.0", + sha256="7bf8e3ae7cc77802ae300277e85d925d4c0611a9b7dad5c5601e0d2cbe14a506", + deprecated=True, + ) + version( + "2.3", + sha256="f901dad6bb70a6875a85da75bcbb42afffdcdf4ef221909733826bcb012d7c3d", + deprecated=True, + ) + version( + "1.0", + sha256="f8927228754fdfb21dbf08b9e67c5f97e06764c4adf327a4126eed84b1508f3d", + deprecated=True, + ) + version( + "0.9.7", + sha256="46e150998723fd1937da598f47f49fe47e40c1f57ec594436c6ef1e0145b44dc", + deprecated=True, + ) depends_on("r@3.0.0:", type=("build", "run")) depends_on("curl", when="@4.3:") diff --git a/var/spack/repos/builtin/packages/r-dada2/package.py b/var/spack/repos/builtin/packages/r-dada2/package.py index 8f4d0e7e444fb5..8f6be657091da9 100644 --- a/var/spack/repos/builtin/packages/r-dada2/package.py +++ b/var/spack/repos/builtin/packages/r-dada2/package.py @@ -18,6 +18,8 @@ class RDada2(RPackage): version("1.20", sha256="351b80dc5cdd587f5d4fe2541574e3d0cf7966342ee913b47cb20c7eb150e3f5") version("1.14", sha256="19980b9d7b0a0e80e86010357cae11d1fc07c2d02067c4445169143cf1f99906") + depends_on("cxx", type="build") # generated + depends_on("r@3.4:", type=("build", "run")) depends_on("r-rcpp@0.12.0:", type=("build", "run")) depends_on("r-biostrings@2.42.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-decipher/package.py b/var/spack/repos/builtin/packages/r-decipher/package.py index f04955e0c0b7e6..fe7f930cab630b 100644 --- a/var/spack/repos/builtin/packages/r-decipher/package.py +++ b/var/spack/repos/builtin/packages/r-decipher/package.py @@ -24,6 +24,8 @@ class RDecipher(RPackage): version("2.6.0", commit="ed9acaa35c8774cb0ea01cd7cc2e46d063d8c70e") version("2.4.0", commit="1a57b8e4c7d7dec1c233f79c9a88d3705e0ad432") + depends_on("c", type="build") # generated + depends_on("r@3.3.0:", type=("build", "run")) depends_on("r@3.5.0:", type=("build", "run"), when="@2.18.1:") depends_on("r-biostrings@2.35.12:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-delayedarray/package.py b/var/spack/repos/builtin/packages/r-delayedarray/package.py index c5e6108253439c..31f81e18964b12 100644 --- a/var/spack/repos/builtin/packages/r-delayedarray/package.py +++ b/var/spack/repos/builtin/packages/r-delayedarray/package.py @@ -31,6 +31,8 @@ class RDelayedarray(RPackage): version("0.4.1", commit="ffe932ef8c255614340e4856fc6e0b44128a27a1") version("0.2.7", commit="909c2ce1665ebae2543172ead50abbe10bd42bc4") + depends_on("c", type="build") # generated + depends_on("r@3.4:", type=("build", "run")) depends_on("r@4.0.0:", type=("build", "run"), when="@0.20.0:") depends_on("r-matrix", type=("build", "run"), when="@0.10.0:") diff --git a/var/spack/repos/builtin/packages/r-densvis/package.py b/var/spack/repos/builtin/packages/r-densvis/package.py index 6099cff50c7db3..7a1d66c6121b02 100644 --- a/var/spack/repos/builtin/packages/r-densvis/package.py +++ b/var/spack/repos/builtin/packages/r-densvis/package.py @@ -37,6 +37,8 @@ class RDensvis(RPackage): version("1.10.0", commit="833db1fb7b2a5667575cc2e7c2fefc8360c8d7fb") + depends_on("cxx", type="build") # generated + depends_on("r-rcpp", type=("build", "run")) depends_on("r-basilisk", type=("build", "run")) depends_on("r-assertthat", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-deoptim/package.py b/var/spack/repos/builtin/packages/r-deoptim/package.py index 9e44e7d04ae986..af382d43234ca0 100644 --- a/var/spack/repos/builtin/packages/r-deoptim/package.py +++ b/var/spack/repos/builtin/packages/r-deoptim/package.py @@ -22,4 +22,6 @@ class RDeoptim(RPackage): version("2.2-4", sha256="0a547784090d1e9b93efc53768110621f35bed3692864f6ce5c0dda2ebd6d482") version("2.2-3", sha256="af2120feea3a736ee7a5a93c6767d464abc0d45ce75568074b233405e73c9a5d") + depends_on("c", type="build") # generated + depends_on("r-parallelly", type=("build", "run"), when="@2.2-7:2.2-7") diff --git a/var/spack/repos/builtin/packages/r-deseq/package.py b/var/spack/repos/builtin/packages/r-deseq/package.py index cfdf5f47cc2a66..4dca7fd96c36a5 100644 --- a/var/spack/repos/builtin/packages/r-deseq/package.py +++ b/var/spack/repos/builtin/packages/r-deseq/package.py @@ -23,6 +23,8 @@ class RDeseq(RPackage): version("1.30.0", commit="90c93d991dd980d538c13b0361d3345f9546794e") version("1.28.0", commit="738371466e6ccf00179fd35b617c8ba0e1e91630") + depends_on("c", type="build") # generated + depends_on("r-biocgenerics@0.7.5:", type=("build", "run")) depends_on("r-biobase@2.21.7:", type=("build", "run")) depends_on("r-locfit", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-deseq2/package.py b/var/spack/repos/builtin/packages/r-deseq2/package.py index d646aa2f5761d3..5bb4ffe19da6fb 100644 --- a/var/spack/repos/builtin/packages/r-deseq2/package.py +++ b/var/spack/repos/builtin/packages/r-deseq2/package.py @@ -28,6 +28,8 @@ class RDeseq2(RPackage): version("1.18.1", commit="ef65091d46436af68915124b752f5e1cc55e93a7") version("1.16.1", commit="f41d9df2de25fb57054480e50bc208447a6d82fb") + depends_on("cxx", type="build") # generated + depends_on("r-s4vectors@0.9.25:", type=("build", "run")) depends_on("r-s4vectors@0.23.18:", type=("build", "run"), when="@1.30.0:") depends_on("r-iranges", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-dicekriging/package.py b/var/spack/repos/builtin/packages/r-dicekriging/package.py index 1e91e9ecb03f0e..23d4333e68e2e1 100644 --- a/var/spack/repos/builtin/packages/r-dicekriging/package.py +++ b/var/spack/repos/builtin/packages/r-dicekriging/package.py @@ -18,3 +18,5 @@ class RDicekriging(RPackage): version("1.5.8", sha256="11d02b894cb509dbb8887ae27b6d08ba25aa52ac3ece134c3759c2b3b1bf4d77") version("1.5.6", sha256="25466d2db9f17083d1c7b9545e5ec88f630be934f9373c2f7b36c38de4e64e92") version("1.5.5", sha256="55fe161f867a0c3772023c3047041b877aa54d29cb474ec87293ec31cc5cb30c") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-diffobj/package.py b/var/spack/repos/builtin/packages/r-diffobj/package.py index e6c2cb2b65b277..b34eab29aac028 100644 --- a/var/spack/repos/builtin/packages/r-diffobj/package.py +++ b/var/spack/repos/builtin/packages/r-diffobj/package.py @@ -19,5 +19,7 @@ class RDiffobj(RPackage): version("0.3.5", sha256="d860a79b1d4c9e369282d7391b539fe89228954854a65ba47181407c53e3cf60") version("0.3.3", sha256="414e5573470b9565b9149a0a61c7e8344fb37f889d23dc4e131acc8aa62e6df4") + depends_on("c", type="build") # generated + depends_on("r@3.1.0:", type=("build", "run")) depends_on("r-crayon@1.3.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-dirichletmultinomial/package.py b/var/spack/repos/builtin/packages/r-dirichletmultinomial/package.py index b6af1bebb652bd..569468a4b0b43a 100644 --- a/var/spack/repos/builtin/packages/r-dirichletmultinomial/package.py +++ b/var/spack/repos/builtin/packages/r-dirichletmultinomial/package.py @@ -29,6 +29,8 @@ class RDirichletmultinomial(RPackage): version("1.20.0", commit="251529f301da1482551142240aeb6baf8dab2272") version("1.18.0", commit="81ccc8d83b8ef84f5d3e877bc0a04233a0f63c51") + depends_on("c", type="build") # generated + depends_on("r-s4vectors", type=("build", "run")) depends_on("r-iranges", type=("build", "run")) depends_on("r-biocgenerics", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-dnacopy/package.py b/var/spack/repos/builtin/packages/r-dnacopy/package.py index f1b23120c3731c..3f6cd7391df172 100644 --- a/var/spack/repos/builtin/packages/r-dnacopy/package.py +++ b/var/spack/repos/builtin/packages/r-dnacopy/package.py @@ -25,3 +25,6 @@ class RDnacopy(RPackage): version("1.54.0", commit="fe2657936afbce8ee03221461dff4265e3ded4c4") version("1.52.0", commit="2632fbecec4cef3705b85676942a59188ae9bba4") version("1.50.1", commit="a20153029e28c009df813dbaf13d9f519fafa4e8") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-dss/package.py b/var/spack/repos/builtin/packages/r-dss/package.py index 188e324ae46256..9fb917dece1b12 100644 --- a/var/spack/repos/builtin/packages/r-dss/package.py +++ b/var/spack/repos/builtin/packages/r-dss/package.py @@ -27,6 +27,8 @@ class RDss(RPackage): version("2.34.0", commit="f9819c7d7927c8e6d9963632cdeab36c8c22caa8") version("2.32.0", commit="ffb502d20810a873c2376199d44adedf7c83912d") + depends_on("c", type="build") # generated + depends_on("r@3.3:", type=("build", "run")) depends_on("r@3.5.0:", type=("build", "run"), when="@2.44.0:") depends_on("r-biobase", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-dtw/package.py b/var/spack/repos/builtin/packages/r-dtw/package.py index ba2f720d91cf61..518ea8392b5774 100644 --- a/var/spack/repos/builtin/packages/r-dtw/package.py +++ b/var/spack/repos/builtin/packages/r-dtw/package.py @@ -30,5 +30,7 @@ class RDtw(RPackage): version("1.15", sha256="28ba2110d4c305f332fad93337cdae24b9de4163b8ddf33d476f9dddc63160f1") version("1.14-3", sha256="6989358d8d97428418c2b34ae38647efcee2e0ce095800a657d5d83d7083c9e3") + depends_on("c", type="build") # generated + depends_on("r@2.10.0:", type=("build", "run")) depends_on("r-proxy", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-ebseq/package.py b/var/spack/repos/builtin/packages/r-ebseq/package.py index 4be0874887a8d0..99c2366a0377ed 100644 --- a/var/spack/repos/builtin/packages/r-ebseq/package.py +++ b/var/spack/repos/builtin/packages/r-ebseq/package.py @@ -24,6 +24,8 @@ class REbseq(RPackage): version("2.0.0", commit="f1d4e4419988ab98540739c9349559fd437cb59f") version("1.40.0", commit="7d1d2a2b4ea0df8cddfb5e57d6431f3948c5c4ca") + depends_on("cxx", type="build") # generated + depends_on("r@3.0:", type=("build", "run")) depends_on("r-bh", type=("build", "run")) depends_on("r-blockmodeling", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-edger/package.py b/var/spack/repos/builtin/packages/r-edger/package.py index 2e0345e4891948..074ac32b4a5585 100644 --- a/var/spack/repos/builtin/packages/r-edger/package.py +++ b/var/spack/repos/builtin/packages/r-edger/package.py @@ -31,6 +31,9 @@ class REdger(RPackage): version("3.20.9", commit="acbcbbee939f399673678653678cd9cb4917c4dc") version("3.18.1", commit="101106f3fdd9e2c45d4a670c88f64c12e97a0495") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.15.0:", type=("build", "run")) depends_on("r@3.6.0:", type=("build", "run"), when="@3.26.8:") depends_on("r-limma", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-ellipsis/package.py b/var/spack/repos/builtin/packages/r-ellipsis/package.py index f0b9ea8882172e..8ad707ebe368f5 100644 --- a/var/spack/repos/builtin/packages/r-ellipsis/package.py +++ b/var/spack/repos/builtin/packages/r-ellipsis/package.py @@ -23,6 +23,8 @@ class REllipsis(RPackage): version("0.3.0", sha256="0bf814cb7a1f0ee1f2949bdc98752a0d535f2a9489280dd4d8fcdb10067ee907") version("0.2.0.1", sha256="0e6528c5e8016c3617cc1cfcdb5a4bfeb073e0bd5ea76b43e56b0c3208a0a943") + depends_on("c", type="build") # generated + depends_on("r@3.1:", type=("build", "run")) depends_on("r@3.2:", type=("build", "run"), when="@0.3:") depends_on("r-rlang@0.3.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-energy/package.py b/var/spack/repos/builtin/packages/r-energy/package.py index 2948c5e1f24198..a3ce0ada52cdaa 100644 --- a/var/spack/repos/builtin/packages/r-energy/package.py +++ b/var/spack/repos/builtin/packages/r-energy/package.py @@ -31,6 +31,9 @@ class REnergy(RPackage): version("1.7-6", sha256="900edbb28e1f1bccd78580828470628cf75eb6333b63e1a58e4da7fc5c5fa89a") version("1.7-5", sha256="24c2cf080939f8f56cd9cda06d2dfc30d0389cd3ec7250af4f9a09a4c06b6996") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r@3.1:", type=("build", "run"), when="@1.7-11:") depends_on("r-rcpp@0.12.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-exomecopy/package.py b/var/spack/repos/builtin/packages/r-exomecopy/package.py index 893d6c28b265eb..3138155652f66d 100644 --- a/var/spack/repos/builtin/packages/r-exomecopy/package.py +++ b/var/spack/repos/builtin/packages/r-exomecopy/package.py @@ -24,6 +24,8 @@ class RExomecopy(RPackage): version("1.36.0", commit="cbe3134acbbc9b7d5426ae2f142dc64cadb3fc26") version("1.32.0", commit="c9a884427d91b6d62ddc16a939bd808e389d3ea6") + depends_on("c", type="build") # generated + depends_on("r-iranges@2.5.27:", type=("build", "run")) depends_on("r-genomicranges@1.23.16:", type=("build", "run")) depends_on("r-rsamtools", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-expint/package.py b/var/spack/repos/builtin/packages/r-expint/package.py index b16b9089bef11f..1fec40d8ab73b7 100644 --- a/var/spack/repos/builtin/packages/r-expint/package.py +++ b/var/spack/repos/builtin/packages/r-expint/package.py @@ -27,4 +27,6 @@ class RExpint(RPackage): version("0.1-6", sha256="c7d13a8e299a91e94622047fe22b0006137e7bf82e34d10871b631fa58115145") version("0.1-5", sha256="b03d60938cd6cf615aa3a02b1bf73436785eca89eaff56059ee0807b8244718a") + depends_on("c", type="build") # generated + depends_on("r@3.3.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-fftwtools/package.py b/var/spack/repos/builtin/packages/r-fftwtools/package.py index 3072b692e56b6a..f6655e079ea717 100644 --- a/var/spack/repos/builtin/packages/r-fftwtools/package.py +++ b/var/spack/repos/builtin/packages/r-fftwtools/package.py @@ -26,6 +26,8 @@ class RFftwtools(RPackage): version("0.9-9", sha256="a9273b7e495d228d740ab4525467e4bbefe8614bd2d97e7234017f1305f51441") version("0.9-8", sha256="4641c8cd70938c2a8bde0b6da6cf7f83e96175ef52f1ca42ec3920a1dabf1bdb") + depends_on("c", type="build") # generated + depends_on("r@2.15.2:", type=("build", "run")) depends_on("r@3.0:", type=("build", "run"), when="@0.9-11:") depends_on("fftw@3.1.2:") diff --git a/var/spack/repos/builtin/packages/r-fgsea/package.py b/var/spack/repos/builtin/packages/r-fgsea/package.py index a4b092cdf9cbf4..9efe984cfb780c 100644 --- a/var/spack/repos/builtin/packages/r-fgsea/package.py +++ b/var/spack/repos/builtin/packages/r-fgsea/package.py @@ -29,6 +29,8 @@ class RFgsea(RPackage): version("1.4.1", commit="73de5ff364e520ac99507a9ee5a61a0d23d3c44e") version("1.2.1", commit="99b04eef664204d0dca4b9f8027cd7eefb006b72") + depends_on("cxx", type="build") # generated + depends_on("r@3.3:", type=("build", "run")) depends_on("r-rcpp", type=("build", "run")) depends_on("r-data-table", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-flashclust/package.py b/var/spack/repos/builtin/packages/r-flashclust/package.py index 0bd9a53583970c..24845b619afc06 100644 --- a/var/spack/repos/builtin/packages/r-flashclust/package.py +++ b/var/spack/repos/builtin/packages/r-flashclust/package.py @@ -13,4 +13,6 @@ class RFlashclust(RPackage): version("1.01-2", sha256="48a7849bb86530465ff3fbfac1c273f0df4b846e67d5eee87187d250c8bf9450") + depends_on("fortran", type="build") # generated + depends_on("r@2.3.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-gcrma/package.py b/var/spack/repos/builtin/packages/r-gcrma/package.py index 869d0f98486f96..3156c6ad247a7d 100644 --- a/var/spack/repos/builtin/packages/r-gcrma/package.py +++ b/var/spack/repos/builtin/packages/r-gcrma/package.py @@ -24,6 +24,8 @@ class RGcrma(RPackage): version("2.50.0", commit="cbba460d131e1073059500b8d7b168a78f963992") version("2.48.0", commit="3ea0eb0b5c15ffb24df76620667ae7996ed715b4") + depends_on("c", type="build") # generated + depends_on("r@2.6.0:", type=("build", "run")) depends_on("r-affy@1.23.2:", type=("build", "run")) depends_on("r-biobase", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-gdsfmt/package.py b/var/spack/repos/builtin/packages/r-gdsfmt/package.py index b2f85fbc0c74f2..d429d3d37bb986 100644 --- a/var/spack/repos/builtin/packages/r-gdsfmt/package.py +++ b/var/spack/repos/builtin/packages/r-gdsfmt/package.py @@ -37,4 +37,7 @@ class RGdsfmt(RPackage): version("1.14.1", commit="15743647b7eea5b82d3284858b4591fb6e59959d") version("1.12.0", commit="d705a95b0bea7be2a2b37e939f45017337ba0fb6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.15.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-geiger/package.py b/var/spack/repos/builtin/packages/r-geiger/package.py index 62d8a896cd7c74..3cfefe918250c4 100644 --- a/var/spack/repos/builtin/packages/r-geiger/package.py +++ b/var/spack/repos/builtin/packages/r-geiger/package.py @@ -24,6 +24,9 @@ class RGeiger(RPackage): version("2.0.6.1", sha256="2a95e20a3a90c096343b014344dd97e699e954da99c151c17fc6c245c77dba0b") version("2.0.6", sha256="e13b2c526378eaf9356b00bbe21b3c2c956327f8062fed638ccc1f49591c3eff") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.15.0:", type=("build", "run")) depends_on("r-ape@3.0-6:", type=("build", "run")) depends_on("r-mass", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-genefilter/package.py b/var/spack/repos/builtin/packages/r-genefilter/package.py index 74936d9ab5a0a6..0000d78ac34a4d 100644 --- a/var/spack/repos/builtin/packages/r-genefilter/package.py +++ b/var/spack/repos/builtin/packages/r-genefilter/package.py @@ -25,6 +25,10 @@ class RGenefilter(RPackage): version("1.60.0", commit="c98f695253c330a9380b2b4ffa27f3b7d66773e4") version("1.58.1", commit="ace2556049677f60882adfe91f8cc96791556fc2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r-matrixgenerics@1.11.1:", type=("build", "run"), when="@1.82.0:") depends_on("r-annotationdbi", type=("build", "run")) depends_on("r-annotate", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-genie3/package.py b/var/spack/repos/builtin/packages/r-genie3/package.py index 3a79f63b99feee..dd339468929c1a 100644 --- a/var/spack/repos/builtin/packages/r-genie3/package.py +++ b/var/spack/repos/builtin/packages/r-genie3/package.py @@ -24,5 +24,7 @@ class RGenie3(RPackage): version("1.2.1", commit="1b56fe8184d521d1bb247f000efe9e2b540604c9") version("1.0.0", commit="eb7c95ed12ea50d61e8fa20bc2b25ae9d74c302f") + depends_on("c", type="build") # generated + depends_on("r-reshape2", type=("build", "run")) depends_on("r-dplyr", type=("build", "run"), when="@1.16.0:") diff --git a/var/spack/repos/builtin/packages/r-genomicalignments/package.py b/var/spack/repos/builtin/packages/r-genomicalignments/package.py index 3a4364713d0606..7b5b9083c90a48 100644 --- a/var/spack/repos/builtin/packages/r-genomicalignments/package.py +++ b/var/spack/repos/builtin/packages/r-genomicalignments/package.py @@ -28,6 +28,8 @@ class RGenomicalignments(RPackage): version("1.14.2", commit="57b0b35d8b36069d4d94af86af051f0129b28eef") version("1.12.2", commit="b5d6f19e4a89b6c1c3e9e58e5ea4eb13870874ef") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r@4.0.0:", type=("build", "run"), when="@1.30.0:") depends_on("r-biocgenerics@0.15.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-genomicranges/package.py b/var/spack/repos/builtin/packages/r-genomicranges/package.py index ca13cefcbfca3b..a439fe10653d30 100644 --- a/var/spack/repos/builtin/packages/r-genomicranges/package.py +++ b/var/spack/repos/builtin/packages/r-genomicranges/package.py @@ -33,6 +33,8 @@ class RGenomicranges(RPackage): version("1.30.3", commit="e99979054bc50ed8c0109bc54563036c1b368997") version("1.28.6", commit="197472d618f3ed04c795dc6ed435500c29619563") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r@4.0.0:", type=("build", "run"), when="@1.46.1:") depends_on("r-biocgenerics@0.21.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-geojsonsf/package.py b/var/spack/repos/builtin/packages/r-geojsonsf/package.py index 8307479d69d31a..92e9a8980cfaab 100644 --- a/var/spack/repos/builtin/packages/r-geojsonsf/package.py +++ b/var/spack/repos/builtin/packages/r-geojsonsf/package.py @@ -18,6 +18,8 @@ class RGeojsonsf(RPackage): version("2.0.3", sha256="275ca14672d982e6a95884515f49d8a0aad14f3be62ea01b675a91b0bffb46d1") version("2.0.1", sha256="42df40433bfbece5a39cd97b5bd4690b4424855241fcc3e7322ee68a3988bfbf") + depends_on("cxx", type="build") # generated + depends_on("r@3.3.0:", type=("build", "run")) depends_on("r-rcpp", type=("build", "run")) depends_on("r-geometries", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-geometry/package.py b/var/spack/repos/builtin/packages/r-geometry/package.py index 855612ecc9ab83..5ff51298d1f709 100644 --- a/var/spack/repos/builtin/packages/r-geometry/package.py +++ b/var/spack/repos/builtin/packages/r-geometry/package.py @@ -27,6 +27,9 @@ class RGeometry(RPackage): version("0.4.6.1", sha256="52c87a43cdf414c08b8183441c44497039cba92a9cff719debf09ad8d5d7f472") version("0.4.6", sha256="910465a8c8043faca73bcc7c81c9249b9938677ee6649468003b438a6503f5d8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.0.0:", type=("build", "run")) depends_on("r-magic", type=("build", "run")) depends_on("r-rcpp", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-geosphere/package.py b/var/spack/repos/builtin/packages/r-geosphere/package.py index c9079b02a4a68c..79e82e106fecfe 100644 --- a/var/spack/repos/builtin/packages/r-geosphere/package.py +++ b/var/spack/repos/builtin/packages/r-geosphere/package.py @@ -23,6 +23,9 @@ class RGeosphere(RPackage): version("1.5-7", sha256="9d9b555e2d59a5ae174ae654652121f169fbc3e9cf66c2491bfbe0684b6dd8a0") version("1.5-5", sha256="8b6fe012744fc45b88e0ef6f20e60e103ef013e761e99dcff3f9dceeedbdce6d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.0.0:", type=("build", "run")) depends_on("r-rcpp", type=("build", "run"), when="@1.5-18:") depends_on("r-sp", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-ggplot2/package.py b/var/spack/repos/builtin/packages/r-ggplot2/package.py index 21ec26809f5c38..a7f919b38cc0f8 100644 --- a/var/spack/repos/builtin/packages/r-ggplot2/package.py +++ b/var/spack/repos/builtin/packages/r-ggplot2/package.py @@ -18,6 +18,10 @@ class RGgplot2(RPackage): license("MIT") + version("3.5.1", sha256="7c58b424f99b3634038e6f6d1fe4b0241b8aecb50e9c50466d5590f7e3144721") + version("3.5.0", sha256="07fa1cd4e02d409ade32e69a9088d9209f864c6ddd70fa2f904769dec21090e2") + version("3.4.4", sha256="2d76ec065d3e604d019506f45b3b713ae20f38e47dbebfb5ba1648b47fe63e46") + version("3.4.3", sha256="5ce29ace6be7727be434506a1c759dfc322f65b17eabeec863b93be10f91a543") version("3.4.2", sha256="70230aa70a2c6f844fc41dd93e5f62af6859dfed390026ae58f223637e5283ca") version("3.4.0", sha256="a82f9e52f974389439765f71a8206ec26e3be30a8864d2c784d5ea8abcb0473e") version("3.3.6", sha256="bfcb4eb92a0fcd3fab713aca4bb25e916e05914f2540271a45522ad7e43943a9") @@ -44,7 +48,8 @@ class RGgplot2(RPackage): depends_on("r-rlang@1.0.0:", type=("build", "run"), when="@3.4.0:") depends_on("r-rlang@1.1.0:", type=("build", "run"), when="@3.4.2:") depends_on("r-scales@0.5.0:", type=("build", "run")) - depends_on("r-scales@1.2.0:", type=("build", "run"), when="@3.4.0:") + depends_on("r-scales@1.2.0:", type=("build", "run"), when="@3.4.0:3.4.4") + depends_on("r-scales@1.3.0:", type=("build", "run"), when="@3.5.0:") depends_on("r-tibble", type=("build", "run")) depends_on("r-vctrs@0.5.0:", type=("build", "run"), when="@3.4.0:") depends_on("r-withr@2.0.0:", type=("build", "run"), when="@3.0.0:") diff --git a/var/spack/repos/builtin/packages/r-glmgampoi/package.py b/var/spack/repos/builtin/packages/r-glmgampoi/package.py index 186701a6f085ac..ffe7569bfdbd28 100644 --- a/var/spack/repos/builtin/packages/r-glmgampoi/package.py +++ b/var/spack/repos/builtin/packages/r-glmgampoi/package.py @@ -20,6 +20,8 @@ class RGlmgampoi(RPackage): version("1.10.0", commit="048e17384209fc07031e09875ec6eea35e90ef46") version("1.8.0", commit="b723d61e05c1ad50a3cf6a6393ec3d97adc7edb4") + depends_on("cxx", type="build") # generated + depends_on("r-rcpp", type=("build", "run")) depends_on("r-delayedmatrixstats", type=("build", "run")) depends_on("r-matrixstats", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-goftest/package.py b/var/spack/repos/builtin/packages/r-goftest/package.py index 9516bd7f126a49..c78dc78470ad07 100644 --- a/var/spack/repos/builtin/packages/r-goftest/package.py +++ b/var/spack/repos/builtin/packages/r-goftest/package.py @@ -19,4 +19,6 @@ class RGoftest(RPackage): version("1.2-3", sha256="3a5f74b6ae7ece5b294781ae57782abe12375d61789c55ff5e92e4aacf347f19") version("1.2-2", sha256="e497992666b002b6c6bed73bf05047ad7aa69eb58898da0ad8f1f5b2219e7647") + depends_on("c", type="build") # generated + depends_on("r@3.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-gofuncr/package.py b/var/spack/repos/builtin/packages/r-gofuncr/package.py index 4f402c206636c1..58f5b7fc0532c7 100644 --- a/var/spack/repos/builtin/packages/r-gofuncr/package.py +++ b/var/spack/repos/builtin/packages/r-gofuncr/package.py @@ -37,6 +37,9 @@ class RGofuncr(RPackage): version("1.2.0", commit="140a3cea4fe34d32fef9be756f85e337ce3deded") version("1.0.0", commit="becd4ddde085c5477042adb856e7a4f40dbd648e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r+X", type=("build", "run")) depends_on("r@3.4:", type=("build", "run")) depends_on("r-vioplot@0.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-gosemsim/package.py b/var/spack/repos/builtin/packages/r-gosemsim/package.py index 9e81019131d298..4153891ce4d087 100644 --- a/var/spack/repos/builtin/packages/r-gosemsim/package.py +++ b/var/spack/repos/builtin/packages/r-gosemsim/package.py @@ -30,6 +30,8 @@ class RGosemsim(RPackage): version("2.4.1", commit="0656e845860d14e054670ffc246a1c53f699299c") version("2.2.0", commit="247434790e6c8cf99e5643f569390362b8c87c52") + depends_on("cxx", type="build") # generated + depends_on("r@3.3.2:", type=("build", "run")) depends_on("r@3.4.0:", type=("build", "run"), when="@2.8.0:") depends_on("r@3.5.0:", type=("build", "run"), when="@2.16.1:") diff --git a/var/spack/repos/builtin/packages/r-gower/package.py b/var/spack/repos/builtin/packages/r-gower/package.py index 2f6f7156d69492..ffc86a9be75cad 100644 --- a/var/spack/repos/builtin/packages/r-gower/package.py +++ b/var/spack/repos/builtin/packages/r-gower/package.py @@ -21,3 +21,5 @@ class RGower(RPackage): version("1.0.0", sha256="671cb7baafe05140d822e8f26f9cd3576fc3bf4c6572b7223fb54da754ea385d") version("0.2.2", sha256="3f022010199fafe34f6e7431730642a76893e6b4249b84e5a61012cb83483631") version("0.2.1", sha256="af3fbe91cf818c0841b2c0ec4ddf282c182a588031228c8d88f7291b2cdff100") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-graph/package.py b/var/spack/repos/builtin/packages/r-graph/package.py index e3fe8eeb7eeee9..54014bac7a6781 100644 --- a/var/spack/repos/builtin/packages/r-graph/package.py +++ b/var/spack/repos/builtin/packages/r-graph/package.py @@ -24,5 +24,7 @@ class RGraph(RPackage): version("1.56.0", commit="c4abe227dac525757679743e6fb4f49baa34acad") version("1.54.0", commit="2a8b08520096241620421078fc1098f4569c7301") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-biocgenerics@0.13.11:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-gsl/package.py b/var/spack/repos/builtin/packages/r-gsl/package.py index 726445818c1bae..5bcf3a7d14cec3 100644 --- a/var/spack/repos/builtin/packages/r-gsl/package.py +++ b/var/spack/repos/builtin/packages/r-gsl/package.py @@ -20,6 +20,8 @@ class RGsl(RPackage): version("2.1-7.1", sha256="ee98d1382d37ffa77538a90ccdbf44affbf1710a9e66b8ada73fa72e67921985") version("2.1-6", sha256="f5d463239693f146617018987687db31b163653708cbae0b730b9b7bed81995c") + depends_on("c", type="build") # generated + depends_on("r@3.1.0:", type=("build", "run")) depends_on("r@4.0.0:", type=("build", "run"), when="@2.1-8:") depends_on("gsl@2.1:") diff --git a/var/spack/repos/builtin/packages/r-gstat/package.py b/var/spack/repos/builtin/packages/r-gstat/package.py index a747cab40fe4d7..b214c37f007f56 100644 --- a/var/spack/repos/builtin/packages/r-gstat/package.py +++ b/var/spack/repos/builtin/packages/r-gstat/package.py @@ -26,6 +26,8 @@ class RGstat(RPackage): version("2.0-6", sha256="6711e68aa2444cf2927879a03a976d8caeca5eac98d806b19a6a7178b90bfcab") version("2.0-3", sha256="20a93fe6bf89221a5888de273bddf9a98187806d507cd3cd6297c2b13e7acce1") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-lattice", type=("build", "run")) depends_on("r-sp@0.9-72:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-haven/package.py b/var/spack/repos/builtin/packages/r-haven/package.py index e034e646c57ee9..220171dbcea1f1 100644 --- a/var/spack/repos/builtin/packages/r-haven/package.py +++ b/var/spack/repos/builtin/packages/r-haven/package.py @@ -16,6 +16,8 @@ class RHaven(RPackage): license("MIT") + version("2.5.4", sha256="9e1531bb37aa474abd91db5e0ed9e3a355c03faa65f4e653b3ea68b7c61ea835") + version("2.5.3", sha256="9a5999afad09f0cf80515241b2ff19a0c480658c4bd3810638ad52762e04b7e3") version("2.5.2", sha256="2131fb0377ae1beffae54bf4beb8b3a876e9b6b9841a5acc39a2a2615023561d") version("2.5.1", sha256="9f40462097a0b1cf3831bca493851fe4a6b3570d957a775ca81940f241c50a70") version("2.5.0", sha256="b580311bc1b28efc6b123e29a331282b9f7eb552c485f4e5cacab39fe534aff4") @@ -25,6 +27,9 @@ class RHaven(RPackage): version("2.1.0", sha256="c0a1cf1b039549fb3ad833f9644ed3f142790236ad755d2ee7bd3d8109e3ae74") version("1.1.0", sha256="089fb4d0955f320abc48d0a3031799f96f3a20b82492474743903fdf12001d19") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.1:", type=("build", "run")) depends_on("r@3.2:", type=("build", "run"), when="@2.1.1:") depends_on("r@3.4:", type=("build", "run"), when="@2.5.0:") diff --git a/var/spack/repos/builtin/packages/r-hdf5array/package.py b/var/spack/repos/builtin/packages/r-hdf5array/package.py index a8b419a351505c..97a95e286d3b82 100644 --- a/var/spack/repos/builtin/packages/r-hdf5array/package.py +++ b/var/spack/repos/builtin/packages/r-hdf5array/package.py @@ -32,6 +32,8 @@ class RHdf5array(RPackage): version("1.6.0", commit="95f2f8d3648143abe9dc77c76340c5edf4114c82") version("1.4.8", commit="79ab96d123c8da8f8ead81f678fe714c0958ff45") + depends_on("c", type="build") # generated + depends_on("r@3.4:", type=("build", "run")) depends_on("r-delayedarray@0.2.4:", type=("build", "run")) depends_on("r-delayedarray@0.3.18:", type=("build", "run"), when="@1.6.0:") diff --git a/var/spack/repos/builtin/packages/r-hdrcde/package.py b/var/spack/repos/builtin/packages/r-hdrcde/package.py index 4ff2c07428a803..d4207c9e1aa074 100644 --- a/var/spack/repos/builtin/packages/r-hdrcde/package.py +++ b/var/spack/repos/builtin/packages/r-hdrcde/package.py @@ -20,6 +20,9 @@ class RHdrcde(RPackage): version("3.4", sha256="4341c6a021da46dcae3b1ef6d580e84dcf625c2b2139f537d0c26ec90899149b") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@2.15:", type=("build", "run")) depends_on("r-locfit", type=("build", "run")) depends_on("r-ash", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-hexbin/package.py b/var/spack/repos/builtin/packages/r-hexbin/package.py index 3324d1b2e0f4ce..b0272f450e4a2a 100644 --- a/var/spack/repos/builtin/packages/r-hexbin/package.py +++ b/var/spack/repos/builtin/packages/r-hexbin/package.py @@ -23,5 +23,8 @@ class RHexbin(RPackage): version("1.27.2", sha256="46d47b1efef75d6f126af686a4dd614228b60418b9a5bde9e9e5d11200a0ee52") version("1.27.1", sha256="075935a3ae2d90e44aca6ebbd368dc6f7e59d322e36e0e0932dedbf01330ad08") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@2.0.1:", type=("build", "run")) depends_on("r-lattice", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-humaniformat/package.py b/var/spack/repos/builtin/packages/r-humaniformat/package.py index ee8057d6874b34..0f92da22e289cf 100644 --- a/var/spack/repos/builtin/packages/r-humaniformat/package.py +++ b/var/spack/repos/builtin/packages/r-humaniformat/package.py @@ -25,4 +25,6 @@ class RHumaniformat(RPackage): version("0.6.0", sha256="861232c66bf6d4ff91b073193506104f4d99eca5e9a9488327f39ef2bfb45e6d") version("0.5.0", sha256="02b585e3623a5c5faa7dc3abff92b932d748900be39097c5db8434b8e92709a0") + depends_on("cxx", type="build") # generated + depends_on("r-rcpp", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-illuminaio/package.py b/var/spack/repos/builtin/packages/r-illuminaio/package.py index 9f5a60263d182c..3cf67aea1be812 100644 --- a/var/spack/repos/builtin/packages/r-illuminaio/package.py +++ b/var/spack/repos/builtin/packages/r-illuminaio/package.py @@ -24,4 +24,6 @@ class RIlluminaio(RPackage): version("0.20.0", commit="d226628133b2396be9e7a6bf043f0309bd70c4ec") version("0.18.0", commit="e6b8ab1f8eacb760aebdb4828e9cfbf07da06eda") + depends_on("c", type="build") # generated + depends_on("r-base64", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-impute/package.py b/var/spack/repos/builtin/packages/r-impute/package.py index ecc5b356f8f945..7a9a5589531002 100644 --- a/var/spack/repos/builtin/packages/r-impute/package.py +++ b/var/spack/repos/builtin/packages/r-impute/package.py @@ -24,4 +24,6 @@ class RImpute(RPackage): version("1.52.0", commit="7fa1b917a5dd60f2aaf52d9aae1fcd2c93511d63") version("1.50.1", commit="31d1cc141797afdc83743e1d95aab8a90ee19b71") + depends_on("fortran", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-ipred/package.py b/var/spack/repos/builtin/packages/r-ipred/package.py index 6e4d00a80e9490..b07211585534a2 100644 --- a/var/spack/repos/builtin/packages/r-ipred/package.py +++ b/var/spack/repos/builtin/packages/r-ipred/package.py @@ -24,6 +24,8 @@ class RIpred(RPackage): version("0.9-8", sha256="9c1d11c3cb0d72be7870e70a216e589e403bbfee38c796fe75cd0611d878ac07") version("0.9-5", sha256="3a466417808e17c4c6cd0f2b577407355d9da79a341558b42a8b76e24b6f6ba4") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-rpart@3.1-8:", type=("build", "run")) depends_on("r-mass", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-iranges/package.py b/var/spack/repos/builtin/packages/r-iranges/package.py index 47a37a38ef8599..ac91c21088f90f 100644 --- a/var/spack/repos/builtin/packages/r-iranges/package.py +++ b/var/spack/repos/builtin/packages/r-iranges/package.py @@ -31,6 +31,8 @@ class RIranges(RPackage): version("2.12.0", commit="1b1748655a8529ba87ad0f223f035ef0c08e7fcd") version("2.10.5", commit="b00d1d5025e3c480d17c13100f0da5a0132b1614") + depends_on("c", type="build") # generated + depends_on("r@3.1.0:", type=("build", "run")) depends_on("r@4.0.0:", type=("build", "run"), when="@2.24.1:") depends_on("r-biocgenerics@0.21.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-irlba/package.py b/var/spack/repos/builtin/packages/r-irlba/package.py index 1d6ad085206d1f..21a594f5d80098 100644 --- a/var/spack/repos/builtin/packages/r-irlba/package.py +++ b/var/spack/repos/builtin/packages/r-irlba/package.py @@ -25,5 +25,7 @@ class RIrlba(RPackage): version("2.1.2", sha256="5183e8dd7943df11c0f44460566adf06c03d5320f142699298f516d423b06ce1") version("2.0.0", sha256="15f8d6c1107d6bb872411efd61e6077d9d7ac826f4da2d378999889a7b1ebabe") + depends_on("c", type="build") # generated + depends_on("r@3.6.2:", type=("build", "run"), when="@2.3.5:") depends_on("r-matrix", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-isoband/package.py b/var/spack/repos/builtin/packages/r-isoband/package.py index 2533c6c6f81e1a..97819fcb6096a9 100644 --- a/var/spack/repos/builtin/packages/r-isoband/package.py +++ b/var/spack/repos/builtin/packages/r-isoband/package.py @@ -22,4 +22,6 @@ class RIsoband(RPackage): version("0.2.5", sha256="46f53fa066f0966f02cb2bf050190c0d5e950dab2cdf565feb63fc092c886ba5") version("0.2.3", sha256="f9d3318fdf6d147dc2e2c7015ea7de42a55fa33d6232b952f982df96066b7ffe") + depends_on("cxx", type="build") # generated + depends_on("r-testthat", type=("build", "run"), when="@0.2.3") diff --git a/var/spack/repos/builtin/packages/r-jomo/package.py b/var/spack/repos/builtin/packages/r-jomo/package.py index 36a96efafd8ab2..726512f37ee4f7 100644 --- a/var/spack/repos/builtin/packages/r-jomo/package.py +++ b/var/spack/repos/builtin/packages/r-jomo/package.py @@ -28,6 +28,8 @@ class RJomo(RPackage): version("2.6-7", sha256="6e83dab51103511038a3e9a3c762e00cc45ae7080c0a0f64e37bcea8c488db53") version("2.6-2", sha256="67496d6d69ddbe9a796789fd8b3ac32cada09a81cf5a8e7b925a21e085e2d87f") + depends_on("c", type="build") # generated + depends_on("r-lme4", type=("build", "run")) depends_on("r-survival", type=("build", "run")) depends_on("r-mass", type=("build", "run"), when="@2.6-7:") diff --git a/var/spack/repos/builtin/packages/r-jpeg/package.py b/var/spack/repos/builtin/packages/r-jpeg/package.py index 0709499e83d327..1436a1543a5d67 100644 --- a/var/spack/repos/builtin/packages/r-jpeg/package.py +++ b/var/spack/repos/builtin/packages/r-jpeg/package.py @@ -22,5 +22,7 @@ class RJpeg(RPackage): version("0.1-8.1", sha256="1db0a4976fd9b2ae27a37d3e856cca35bc2909323c7a40724846a5d3c18915a9") version("0.1-8", sha256="d032befeb3a414cefdbf70ba29a6c01541c54387cc0a1a98a4022d86cbe60a16") + depends_on("c", type="build") # generated + depends_on("r@2.9.0:", type=("build", "run")) depends_on("jpeg") diff --git a/var/spack/repos/builtin/packages/r-jsonify/package.py b/var/spack/repos/builtin/packages/r-jsonify/package.py index 4887837dbdd639..f98a52dea98530 100644 --- a/var/spack/repos/builtin/packages/r-jsonify/package.py +++ b/var/spack/repos/builtin/packages/r-jsonify/package.py @@ -21,6 +21,8 @@ class RJsonify(RPackage): version("1.2.2", sha256="3745e962592f021a3deaed8b2f6b99c4f7181f28e095300a96d1c2b08af4af2f") version("1.2.1", sha256="929191ab32e34af6a02ad991e29314cc78ea40763fcf232388ef2d132137fbce") + depends_on("cxx", type="build") # generated + depends_on("r@3.3.0:", type=("build", "run")) depends_on("r-rcpp@0.12.18:", type=("build", "run")) depends_on("r-rapidjsonr@1.2.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-jsonlite/package.py b/var/spack/repos/builtin/packages/r-jsonlite/package.py index 952b58337a561c..2d3c0d57c7ed44 100644 --- a/var/spack/repos/builtin/packages/r-jsonlite/package.py +++ b/var/spack/repos/builtin/packages/r-jsonlite/package.py @@ -24,6 +24,9 @@ class RJsonlite(RPackage): license("MIT") + version("1.8.8", sha256="7de21316984c3ba3d7423d12f43d1c30c716007c5e39bf07e11885e0ceb0caa4") + version("1.8.7", sha256="7d42b7784b72d728698ea02b97818df51e2015ffa39fec2eaa2400771b0f601c") + version("1.8.5", sha256="dc3cca4bdca1b6d6836c412760ea9656140683126c54cb89c3e42219dec4a3ad") version("1.8.4", sha256="79eaabe042226b0918aa828cc63d54fee8be67ae7c67f5e0d3010f468efb1278") version("1.8.3", sha256="c57f1daf681fc7d5db893693a65ac61a48ddd7aabf66b28647b0e30df92ac8f0") version("1.8.2", sha256="677b645c081a7e004b71f0c48a1d46c1be9715163ccb6b419fbb0342a6c9cc3a") @@ -36,3 +39,5 @@ class RJsonlite(RPackage): version("1.2", sha256="cb6b4660468d2db84ed09c7b8fefd169fcfc13e1e6b4e7ce64dce2713f34264d") version("1.0", sha256="d756dd6367e3fc515c855bb0b34a3a81955f8aeb494db029a893f3cdfcff962d") version("0.9.21", sha256="079349342ea6eb92bd5fa8f6a7c08d9e3652c3d41010b64afbc3297671eb3791") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-kernlab/package.py b/var/spack/repos/builtin/packages/r-kernlab/package.py index ec7f355a92e004..7e1289948d4ed6 100644 --- a/var/spack/repos/builtin/packages/r-kernlab/package.py +++ b/var/spack/repos/builtin/packages/r-kernlab/package.py @@ -26,4 +26,7 @@ class RKernlab(RPackage): version("0.9-26", sha256="954940478c6fcf60433e50e43cf10d70bcb0a809848ca8b9d683bf371cd56077") version("0.9-25", sha256="b9de072754bb03c02c4d6a5ca20f2290fd090de328b55ab334ac0b397ac2ca62") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-kknn/package.py b/var/spack/repos/builtin/packages/r-kknn/package.py index 1c674e39de5a4e..e4c2d931a521c2 100644 --- a/var/spack/repos/builtin/packages/r-kknn/package.py +++ b/var/spack/repos/builtin/packages/r-kknn/package.py @@ -18,6 +18,8 @@ class RKknn(RPackage): version("1.3.1", sha256="22840e70ec2afa40371e274b583634c8f6d27149a87253ee411747d5db78f3db") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-igraph@1.0:", type=("build", "run")) depends_on("r-matrix", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-lars/package.py b/var/spack/repos/builtin/packages/r-lars/package.py index e150766a921dec..e0fa34532a420b 100644 --- a/var/spack/repos/builtin/packages/r-lars/package.py +++ b/var/spack/repos/builtin/packages/r-lars/package.py @@ -21,4 +21,7 @@ class RLars(RPackage): version("1.1", sha256="a8e4a0efb9ca6760dec1cadf395d9a805508455a2c3ced18cc53d9b8fa70cdc0") version("0.9-8", sha256="8c64cb31073ea0785346bb716485da8db2fae14153a52e5a8d151bc9cb4906e5") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-lazyeval/package.py b/var/spack/repos/builtin/packages/r-lazyeval/package.py index cbaafd963bbb4e..f90efdeea60f96 100644 --- a/var/spack/repos/builtin/packages/r-lazyeval/package.py +++ b/var/spack/repos/builtin/packages/r-lazyeval/package.py @@ -21,4 +21,6 @@ class RLazyeval(RPackage): version("0.2.1", sha256="83b3a43e94c40fe7977e43eb607be0a3cd64c02800eae4f2774e7866d1e93f61") version("0.2.0", sha256="13738f55b2044184fe91f53d17516a445dfb508227527921218cda6f01f98dcb") + depends_on("c", type="build") # generated + depends_on("r@3.1.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-libpressio/package.py b/var/spack/repos/builtin/packages/r-libpressio/package.py index cc397330a3f8e1..7e0203978201a8 100644 --- a/var/spack/repos/builtin/packages/r-libpressio/package.py +++ b/var/spack/repos/builtin/packages/r-libpressio/package.py @@ -25,6 +25,8 @@ class RLibpressio(RPackage): version("1.1", sha256="b86a541e095b6e41b3548f6cd734c1ff50c70edda2806ed66b5205880fbfbb96") version("0.0.1", sha256="a508cf3ec1b06c417e0de0e1e4180f3175ead2e4ec23b374425fcf2abfaa1b88") + depends_on("cxx", type="build") # generated + variant( "third_party", description="include support for 3rd party compressor modules", default=True ) diff --git a/var/spack/repos/builtin/packages/r-limma/package.py b/var/spack/repos/builtin/packages/r-limma/package.py index 5e3b183a8dc495..ea57708e3f1075 100644 --- a/var/spack/repos/builtin/packages/r-limma/package.py +++ b/var/spack/repos/builtin/packages/r-limma/package.py @@ -26,5 +26,7 @@ class RLimma(RPackage): version("3.34.9", commit="6755278a929f942a49e2441fb002a3ed393e1139") version("3.32.10", commit="593edf28e21fe054d64137ae271b8a52ab05bc60") + depends_on("c", type="build") # generated + depends_on("r@2.3.0:", type=("build", "run")) depends_on("r@3.6.0:", type=("build", "run"), when="@3.40.6:") diff --git a/var/spack/repos/builtin/packages/r-lmtest/package.py b/var/spack/repos/builtin/packages/r-lmtest/package.py index ed98a3f759b591..f7bd808a4b8991 100644 --- a/var/spack/repos/builtin/packages/r-lmtest/package.py +++ b/var/spack/repos/builtin/packages/r-lmtest/package.py @@ -24,5 +24,8 @@ class RLmtest(RPackage): version("0.9-36", sha256="be9f168d6554e9cd2be0f9d8fc3244f055dce90d1fca00f05bcbd01daa4ed56b") version("0.9-34", sha256="86eead67ed6d6c6be3fbee97d5ce45e6ca06a981f974ce01a7754a9e33770d2e") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@3.0.0:", type=("build", "run")) depends_on("r-zoo", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-lobstr/package.py b/var/spack/repos/builtin/packages/r-lobstr/package.py index f322a9ab4cd8aa..77670f9a55c63d 100644 --- a/var/spack/repos/builtin/packages/r-lobstr/package.py +++ b/var/spack/repos/builtin/packages/r-lobstr/package.py @@ -23,6 +23,8 @@ class RLobstr(RPackage): version("1.0.1", sha256="25fb288f73dbaf680ebbf27a50da338868c55d788501118fd33748854c5104fb") version("1.0.0", sha256="9d24de1519c51b3bac79066a1abf623b939e884ba5b3005110bb9c2016954b3d") + depends_on("cxx", type="build") # generated + depends_on("r@3.1:", type=("build", "run")) depends_on("r@3.2:", type=("build", "run"), when="@1.1.1:") depends_on("r-crayon", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-log4r/package.py b/var/spack/repos/builtin/packages/r-log4r/package.py index 53dd72495441ae..c7bade880eb945 100644 --- a/var/spack/repos/builtin/packages/r-log4r/package.py +++ b/var/spack/repos/builtin/packages/r-log4r/package.py @@ -21,3 +21,5 @@ class RLog4r(RPackage): version("0.3.2", sha256="14ba6b096283279f0accbde26a600771ab2df271db6c8eeb04d6f113107825a3") version("0.3.0", sha256="8e5d0221298410e48bee9d9a983a23e1834ce88592f9d931471bfdb05f37a691") version("0.2", sha256="321bee6babb92376b538624027a36e7d2a6c8edb360aa38ab0a6762dfea9081f") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-lsei/package.py b/var/spack/repos/builtin/packages/r-lsei/package.py index cf29fe58b37c32..55332f86820da6 100644 --- a/var/spack/repos/builtin/packages/r-lsei/package.py +++ b/var/spack/repos/builtin/packages/r-lsei/package.py @@ -23,3 +23,6 @@ class RLsei(RPackage): version("1.3-0", sha256="6289058f652989ca8a5ad6fa324ce1762cc9e36c42559c00929b70f762066ab6") version("1.2-0", sha256="4781ebd9ef93880260d5d5f23066580ac06061e95c1048fb25e4e838963380f6") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-magrittr/package.py b/var/spack/repos/builtin/packages/r-magrittr/package.py index 989ca317de2390..d3aeb1a1d99796 100644 --- a/var/spack/repos/builtin/packages/r-magrittr/package.py +++ b/var/spack/repos/builtin/packages/r-magrittr/package.py @@ -24,4 +24,6 @@ class RMagrittr(RPackage): version("2.0.1", sha256="75c265d51cc2b34beb27040edb09823c7b954d3990a7a931e40690b75d4aad5f") version("1.5", sha256="05c45943ada9443134caa0ab24db4a962b629f00b755ccf039a2a2a7b2c92ae8") + depends_on("c", type="build") # generated + depends_on("r@3.4.0:", type=("build", "run"), when="@2.0.3:") diff --git a/var/spack/repos/builtin/packages/r-makecdfenv/package.py b/var/spack/repos/builtin/packages/r-makecdfenv/package.py index 21d255366d84d4..7fa20490d3e64d 100644 --- a/var/spack/repos/builtin/packages/r-makecdfenv/package.py +++ b/var/spack/repos/builtin/packages/r-makecdfenv/package.py @@ -27,6 +27,8 @@ class RMakecdfenv(RPackage): version("1.54.0", commit="3ff646ddc4b028e46b1e091ff9c2d17ce77cec26") version("1.52.0", commit="b88a3e93e3b7feeeca69eda7c1fc5a0826c81120") + depends_on("c", type="build") # generated + depends_on("r@2.6.0:", type=("build", "run")) depends_on("r-affyio", type=("build", "run")) depends_on("r-biobase", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-mapproj/package.py b/var/spack/repos/builtin/packages/r-mapproj/package.py index 3c9963ffcdf029..08b9ea6351b409 100644 --- a/var/spack/repos/builtin/packages/r-mapproj/package.py +++ b/var/spack/repos/builtin/packages/r-mapproj/package.py @@ -23,5 +23,7 @@ class RMapproj(RPackage): version("1.2-5", sha256="f3026a3a69a550c923b44c18b1ccc60d98e52670a438250d13f3c74cf2195f66") version("1.2-4", sha256="cf8a1535f57e7cca0a71b3a551e77ad3e7a78f61a94bb19effd3de19dbe7dceb") + depends_on("c", type="build") # generated + depends_on("r@3.0.0:", type=("build", "run")) depends_on("r-maps@2.3-0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-memuse/package.py b/var/spack/repos/builtin/packages/r-memuse/package.py index e1abbbc6315efd..4177e53fb75d9d 100644 --- a/var/spack/repos/builtin/packages/r-memuse/package.py +++ b/var/spack/repos/builtin/packages/r-memuse/package.py @@ -25,4 +25,6 @@ class RMemuse(RPackage): version("4.2-1", sha256="f5e9dbaad4efbbfe219a93f446e318a00cad5b294bfc60ca2146eca894b47cf3") version("4.1-0", sha256="58d6d1ca5d6bd481f4ed299eff6a9d5660eb0f8db1abe54c49e144093cba72ad") + depends_on("c", type="build") # generated + depends_on("r@3.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-metapod/package.py b/var/spack/repos/builtin/packages/r-metapod/package.py index 595c008a667327..1a43e60491bdcd 100644 --- a/var/spack/repos/builtin/packages/r-metapod/package.py +++ b/var/spack/repos/builtin/packages/r-metapod/package.py @@ -23,4 +23,6 @@ class RMetapod(RPackage): version("1.6.0", commit="cfeaa959f5c6b2119df270f40af9c3ea718c4b00") version("1.4.0", commit="e71c2072e5b39f74599e279b28f4da7923b515fb") + depends_on("cxx", type="build") # generated + depends_on("r-rcpp", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-mime/package.py b/var/spack/repos/builtin/packages/r-mime/package.py index 2ba4d9bff8f5ec..b9ac2896a1f97d 100644 --- a/var/spack/repos/builtin/packages/r-mime/package.py +++ b/var/spack/repos/builtin/packages/r-mime/package.py @@ -23,3 +23,5 @@ class RMime(RPackage): version("0.6", sha256="4775b605ab0117406bee7953c8af59eea8b35e67d1bd63f4007686a7097fc401") version("0.5", sha256="fcc72115afb0eb43237da872754464f37ae9ae097f332ec7984149b5e3a82145") version("0.4", sha256="d790c7e38371d03774a7d53f75aed3151835b1aebbb663b0fe828b221e6bac90") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-mixtools/package.py b/var/spack/repos/builtin/packages/r-mixtools/package.py index 64a6c88194020b..b7f3b321307bb1 100644 --- a/var/spack/repos/builtin/packages/r-mixtools/package.py +++ b/var/spack/repos/builtin/packages/r-mixtools/package.py @@ -32,6 +32,8 @@ class RMixtools(RPackage): version("1.1.0", sha256="543fd8d8dc8d4b6079ebf491cf97f27d6225e1a6e65d8fd48553ada23ba88d8f") version("1.0.4", sha256="62f4b0a17ce520c4f8ed50ab44f120e459143b461a9e420cd39056ee4fc8798c") + depends_on("c", type="build") # generated + depends_on("r@3.2:", type=("build", "run")) depends_on("r@3.5.0:", type=("build", "run"), when="@1.2.0:") depends_on("r@4.0.0:", type=("build", "run"), when="@2.0.0:") diff --git a/var/spack/repos/builtin/packages/r-mlrmbo/package.py b/var/spack/repos/builtin/packages/r-mlrmbo/package.py index 0b945e185af090..db8931d1769dcb 100644 --- a/var/spack/repos/builtin/packages/r-mlrmbo/package.py +++ b/var/spack/repos/builtin/packages/r-mlrmbo/package.py @@ -31,6 +31,8 @@ class RMlrmbo(RPackage): version("1.1.1", sha256="e87d9912a9b4a968364584205b8ef6f7fea0b5aa043c8d31331a7b7be02dd7e4") version("1.1.0", sha256="6ae82731a566333f06085ea2ce23ff2a1007029db46eea57d06194850350a8a0") + depends_on("c", type="build") # generated + depends_on("r+X", type=("build", "run")) depends_on("r-mlr@2.10:", type=("build", "run")) depends_on("r-paramhelpers@1.10:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-mnormt/package.py b/var/spack/repos/builtin/packages/r-mnormt/package.py index 06d34557911f0f..5b498b1989462c 100644 --- a/var/spack/repos/builtin/packages/r-mnormt/package.py +++ b/var/spack/repos/builtin/packages/r-mnormt/package.py @@ -24,5 +24,8 @@ class RMnormt(RPackage): version("2.0.2", sha256="5c6aa036d3f1035ffe8f9a8e95bb908b191b126b016591cf893c50472851f334") version("1.5-5", sha256="ff78d5f935278935f1814a69e5a913d93d6dd2ac1b5681ba86b30c6773ef64ac") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@2.2.0:", type=("build", "run")) depends_on("r-tmvnsim@1.0-2:", type=("build", "run"), when="@2.0.2") diff --git a/var/spack/repos/builtin/packages/r-modelmetrics/package.py b/var/spack/repos/builtin/packages/r-modelmetrics/package.py index 7cfe7a9e124b70..8c2d175f5a8f8f 100644 --- a/var/spack/repos/builtin/packages/r-modelmetrics/package.py +++ b/var/spack/repos/builtin/packages/r-modelmetrics/package.py @@ -20,6 +20,8 @@ class RModelmetrics(RPackage): version("1.2.0", sha256="3021ae88733695a35d66e279e8e61861431f14c9916a341f0a562f675cf6ede9") version("1.1.0", sha256="487d53fda57da4b29f83a927dda8b1ae6655ab044ee3eec33c38aeb27eed3d85") + depends_on("cxx", type="build") # generated + depends_on("r@3.2.2:", type=("build", "run")) depends_on("r-rcpp", type=("build", "run")) depends_on("r-data-table", type=("build", "run"), when="@1.2.0:") diff --git a/var/spack/repos/builtin/packages/r-mscoreutils/package.py b/var/spack/repos/builtin/packages/r-mscoreutils/package.py index 769d7528c6b3dc..c532fa691d0fca 100644 --- a/var/spack/repos/builtin/packages/r-mscoreutils/package.py +++ b/var/spack/repos/builtin/packages/r-mscoreutils/package.py @@ -24,6 +24,8 @@ class RMscoreutils(RPackage): version("1.8.0", commit="8b7e2c31009276aad0b418ba5cdfc94d03e1973e") version("1.6.0", commit="9ed95b2d20dacaa83567fadd04349c81db9127ef") + depends_on("c", type="build") # generated + depends_on("r@3.6.0:", type=("build", "run")) depends_on("r-s4vectors", type=("build", "run")) depends_on("r-mass", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-msnbase/package.py b/var/spack/repos/builtin/packages/r-msnbase/package.py index e7c550f9ca256f..bdbfd7b28eaa1c 100644 --- a/var/spack/repos/builtin/packages/r-msnbase/package.py +++ b/var/spack/repos/builtin/packages/r-msnbase/package.py @@ -26,6 +26,9 @@ class RMsnbase(RPackage): version("2.4.2", commit="c045d65daa730c7837852e6343a05cae9644ab5e") version("2.2.0", commit="d6e8fb7f106d05096fa9074da0f829ac8f02c197") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.1:", type=("build", "run")) depends_on("r@3.5:", type=("build", "run"), when="@2.16.1:") depends_on("r-biocgenerics@0.7.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-multtest/package.py b/var/spack/repos/builtin/packages/r-multtest/package.py index 6fa806025d26d8..3f60c5577ae7fc 100644 --- a/var/spack/repos/builtin/packages/r-multtest/package.py +++ b/var/spack/repos/builtin/packages/r-multtest/package.py @@ -40,6 +40,8 @@ class RMulttest(RPackage): version("2.34.0", commit="6ef873e05e6c93ede54f3421424f56eda057cd54") version("2.32.0", commit="c5e890dfbffcc3a3f107303a24b6085614312f4a") + depends_on("c", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-biocgenerics", type=("build", "run")) depends_on("r-biobase", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-mzr/package.py b/var/spack/repos/builtin/packages/r-mzr/package.py index df724a5961390e..0ae7b4beecb465 100644 --- a/var/spack/repos/builtin/packages/r-mzr/package.py +++ b/var/spack/repos/builtin/packages/r-mzr/package.py @@ -30,6 +30,8 @@ class RMzr(RPackage): version("2.12.0", commit="f05eb27ae31c3d019cca10fc3b9ee513cbcdfc5a") version("2.10.0", commit="a6168b68e48c281e88de9647254a8db1e21df388") + depends_on("cxx", type="build") # generated + depends_on("r@4.0.0:", type=("build", "run"), when="@2.30.0:") depends_on("r-rcpp@0.10.1:", type=("build", "run")) depends_on("r-biobase", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-np/package.py b/var/spack/repos/builtin/packages/r-np/package.py index 2ba3eda569b288..7e8c0498cfe818 100644 --- a/var/spack/repos/builtin/packages/r-np/package.py +++ b/var/spack/repos/builtin/packages/r-np/package.py @@ -30,6 +30,8 @@ class RNp(RPackage): version("0.60-8", sha256="924c342feb2a862fa3871a45db5f8434dbbfb900cfc40c001a0872108a3a069e") version("0.60-2", sha256="25d667fc1056899516584b9d5d933377e6f4694d8e5e868dd047db572b69417f") + depends_on("c", type="build") # generated + depends_on("r-boot", type=("build", "run")) depends_on("r-cubature", type=("build", "run")) depends_on("r-quadprog", type=("build", "run"), when="@0.60-8:") diff --git a/var/spack/repos/builtin/packages/r-openxlsx/package.py b/var/spack/repos/builtin/packages/r-openxlsx/package.py index f16120e2579819..d9a311a07d2780 100644 --- a/var/spack/repos/builtin/packages/r-openxlsx/package.py +++ b/var/spack/repos/builtin/packages/r-openxlsx/package.py @@ -24,6 +24,8 @@ class ROpenxlsx(RPackage): version("4.2.3", sha256="cdef89d826e50bef772af3e5eae935ca0316626a6e22f55f7631eac733b5e46f") version("4.1.0.1", sha256="8b7011debe14714de035ef42797c8caa923162d5dc3cc3c2a299fc10eff3d4d1") + depends_on("cxx", type="build") # generated + depends_on("r@3.3.0:", type=("build", "run")) depends_on("r-stringi", type=("build", "run"), when="@4.2.3:") depends_on("r-zip", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-paramhelpers/package.py b/var/spack/repos/builtin/packages/r-paramhelpers/package.py index cde9476185829c..a4fd0660058570 100644 --- a/var/spack/repos/builtin/packages/r-paramhelpers/package.py +++ b/var/spack/repos/builtin/packages/r-paramhelpers/package.py @@ -24,6 +24,8 @@ class RParamhelpers(RPackage): version("1.11", sha256="1614f4c0842cf822befc01228ab7263417f3423dd6a1dc24347b14f8491637a0") version("1.10", sha256="80629ba62e93b0b706bf2e451578b94fbb9c5b95ff109ecfb5b011bfe0a0fa5b") + depends_on("c", type="build") # generated + depends_on("r-backports", type=("build", "run"), when="@1.11:") depends_on("r-bbmisc@1.10:", type=("build", "run")) depends_on("r-checkmate@1.8.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-partykit/package.py b/var/spack/repos/builtin/packages/r-partykit/package.py index fa35055cee0970..c65bd967e30c3f 100644 --- a/var/spack/repos/builtin/packages/r-partykit/package.py +++ b/var/spack/repos/builtin/packages/r-partykit/package.py @@ -33,6 +33,8 @@ class RPartykit(RPackage): version("1.2-3", sha256="56749b246e283f94ac2ad2cdcfc0a477e05cd44b5e8f6e462c26f4dff818da35") version("1.1-1", sha256="d9f4762690cd85ee4e3dc44f5a14069d10a1900afdfbcdc284d2a94b4a8e8332") + depends_on("c", type="build") # generated + depends_on("r@3.1.0:", type=("build", "run")) depends_on("r@3.5.0:", type=("build", "run"), when="@1.2-11:") depends_on("r-libcoin@1.0-0:", type=("build", "run"), when="@1.2-0:") diff --git a/var/spack/repos/builtin/packages/r-pbivnorm/package.py b/var/spack/repos/builtin/packages/r-pbivnorm/package.py index bd56dd5148dfcf..5a6594a8d09e18 100644 --- a/var/spack/repos/builtin/packages/r-pbivnorm/package.py +++ b/var/spack/repos/builtin/packages/r-pbivnorm/package.py @@ -17,3 +17,5 @@ class RPbivnorm(RPackage): license("GPL-2.0-or-later") version("0.6.0", sha256="07c37d507cb8f8d2d9ae51a9a6d44dfbebd8a53e93c242c4378eaddfb1cc5f16") + + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-pcamethods/package.py b/var/spack/repos/builtin/packages/r-pcamethods/package.py index 413fea97a9f355..fc8241adb5d9fa 100644 --- a/var/spack/repos/builtin/packages/r-pcamethods/package.py +++ b/var/spack/repos/builtin/packages/r-pcamethods/package.py @@ -34,6 +34,8 @@ class RPcamethods(RPackage): version("1.70.0", commit="3368fad48ea930775505fd26e4179d7714d633d8") version("1.68.0", commit="c8d7c93dcaf7ef728f3d089ae5d55771b320bdab") + depends_on("cxx", type="build") # generated + depends_on("r-biobase", type=("build", "run")) depends_on("r-biocgenerics", type=("build", "run")) depends_on("r-rcpp@0.11.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-phangorn/package.py b/var/spack/repos/builtin/packages/r-phangorn/package.py index c417b5662c3db4..08a9af61f886e0 100644 --- a/var/spack/repos/builtin/packages/r-phangorn/package.py +++ b/var/spack/repos/builtin/packages/r-phangorn/package.py @@ -26,6 +26,9 @@ class RPhangorn(RPackage): version("2.5.3", sha256="a306585a0aabe7360a2adaf9116ae2993fb5ceff641b198f2e01e4329d3768af") version("2.3.1", sha256="518c31f5b2c5f0a655d02a3c71b00c30caea2794dfc31f9d63f3d505bd7863eb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.2.0:", type=("build", "run")) depends_on("r@4.1.0:", type=("build", "run"), when="@2.8.1:") depends_on("r-digest", type=("build", "run"), when="@2.10.0:") diff --git a/var/spack/repos/builtin/packages/r-phantompeakqualtools/package.py b/var/spack/repos/builtin/packages/r-phantompeakqualtools/package.py index a9fcf1aa80aded..ff1d6269cefabc 100644 --- a/var/spack/repos/builtin/packages/r-phantompeakqualtools/package.py +++ b/var/spack/repos/builtin/packages/r-phantompeakqualtools/package.py @@ -18,6 +18,9 @@ class RPhantompeakqualtools(RPackage): version("1.14", sha256="d03be6163e82aed72298e54a92c181570f9975a395f57a69b21ac02b1001520b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost@1.41.0:") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/r-picante/package.py b/var/spack/repos/builtin/packages/r-picante/package.py index 0e5644de7074b3..5ab8c73e0dd08c 100644 --- a/var/spack/repos/builtin/packages/r-picante/package.py +++ b/var/spack/repos/builtin/packages/r-picante/package.py @@ -28,6 +28,8 @@ class RPicante(RPackage): version("1.6-2", sha256="4db3a5a0fe5e4e9197c96245195843294fbb8d0a324edcde70c6ab01276ab7ff") version("1.6-1", sha256="2708315b26737857a6729fd67bde06bc939930035c5b09a8bba472a593f24000") + depends_on("c", type="build") # generated + depends_on("r-ape", type=("build", "run")) depends_on("r-vegan", type=("build", "run")) depends_on("r-nlme", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-pkgload/package.py b/var/spack/repos/builtin/packages/r-pkgload/package.py index 0ad45d99b548db..5d22035a99e780 100644 --- a/var/spack/repos/builtin/packages/r-pkgload/package.py +++ b/var/spack/repos/builtin/packages/r-pkgload/package.py @@ -17,6 +17,9 @@ class RPkgload(RPackage): license("GPL-3.0-only") + version("1.3.4", sha256="60b04b948cda4dc56257b1e89f9b0a4b1273cacecdb2bd995d66dd76e89926ce") + version("1.3.3", sha256="b0898122876479cc4a35cd566654b3a7b50f8ac105565dbf3f8b9d4283816959") + version("1.3.2.1", sha256="a1987b123fcbdb9d908b6dc55a04d3cf47d68cfa5090186e4876a429313374b2") version("1.3.2", sha256="35d19a032bfeeefcab92d76a768b4a420c2ede0920badaf48cca878592b46b2f") version("1.3.1", sha256="c6b8b70d7b7e194e7d44a42364f0362e971d9ab9c5794c4ae5ed4f9e61b1679a") version("1.3.0", sha256="5af653c901662260cc221971cc968355428cc6183b61c15be80aa9545f9f4228") @@ -33,10 +36,12 @@ class RPkgload(RPackage): depends_on("r-glue", type=("build", "run"), when="@1.3.0:") depends_on("r-fs", type=("build", "run"), when="@1.3.0:") depends_on("r-rlang", type=("build", "run")) - depends_on("r-rlang@1.0.3:", type=("build", "run"), when="@1.3.0:") + depends_on("r-rlang@1.0.3:", type=("build", "run"), when="@1.3.0:1.3.3") + depends_on("r-rlang@1.1.1:", type=("build", "run"), when="@1.3.4:") depends_on("r-rprojroot", type=("build", "run")) depends_on("r-withr", type=("build", "run")) depends_on("r-withr@2.4.3:", type=("build", "run"), when="@1.3.0:") depends_on("r-pkgbuild", type=("build", "run"), when="@:1.1.0") + depends_on("r-pkgbuild", type=("build", "run"), when="@1.3.4:") depends_on("r-rstudioapi", type=("build", "run"), when="@:1.2.4") diff --git a/var/spack/repos/builtin/packages/r-png/package.py b/var/spack/repos/builtin/packages/r-png/package.py index 41950df3dc5469..3780eab83a2ee6 100644 --- a/var/spack/repos/builtin/packages/r-png/package.py +++ b/var/spack/repos/builtin/packages/r-png/package.py @@ -20,5 +20,7 @@ class RPng(RPackage): version("0.1-8", sha256="5a36fabb6d62ba2533d3fc4cececd07891942cfb76fe689ec0d550d08762f61c") version("0.1-7", sha256="e269ff968f04384fc9421d17cfc7c10cf7756b11c2d6d126e9776f5aca65553c") + depends_on("c", type="build") # generated + depends_on("r@2.9.0:", type=("build", "run")) depends_on("libpng") diff --git a/var/spack/repos/builtin/packages/r-preprocesscore/package.py b/var/spack/repos/builtin/packages/r-preprocesscore/package.py index 080ff674cad4ba..11c9fb8484da6d 100644 --- a/var/spack/repos/builtin/packages/r-preprocesscore/package.py +++ b/var/spack/repos/builtin/packages/r-preprocesscore/package.py @@ -23,3 +23,5 @@ class RPreprocesscore(RPackage): version("1.42.0", commit="2e3a8baeacfaa1526d51252642772ea951015bba") version("1.40.0", commit="969bb0e5cbd63d569502ae4e6eaadc1e216646dd") version("1.38.1", commit="c58cb4c720eda0f1c733b989b14912093a7c5fbc") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-proxy/package.py b/var/spack/repos/builtin/packages/r-proxy/package.py index 52f3d7809fbbc7..6be53d753c8aa4 100644 --- a/var/spack/repos/builtin/packages/r-proxy/package.py +++ b/var/spack/repos/builtin/packages/r-proxy/package.py @@ -22,5 +22,7 @@ class RProxy(RPackage): version("0.4-23", sha256="9dd4eb0978f40e4fcb55c8a8a26266d32eff9c63ac9dfe70cf1f664ca9c3669d") version("0.4-19", sha256="6b27e275018366e6024382704da9a9757c8878535dbcd7d450824b70e2e34d51") + depends_on("c", type="build") # generated + depends_on("r@3.3.2:", type=("build", "run")) depends_on("r@3.4.0:", type=("build", "run"), when="@0.4-21:") diff --git a/var/spack/repos/builtin/packages/r-pryr/package.py b/var/spack/repos/builtin/packages/r-pryr/package.py index 80240fa83d64f0..7fa806f0e0d27e 100644 --- a/var/spack/repos/builtin/packages/r-pryr/package.py +++ b/var/spack/repos/builtin/packages/r-pryr/package.py @@ -23,6 +23,8 @@ class RPryr(RPackage): version("0.1.3", sha256="6acd88341dde4fe247a5cafd3949b281dc6742b7d60f68b57c1feb84b96739ac") version("0.1.2", sha256="65c2b7c9f96e2aa683ac9cdab3c215fd3039ecd66a2ba7002a8e77881428c3c6") + depends_on("cxx", type="build") # generated + depends_on("r@3.1.0:", type=("build", "run")) depends_on("r-stringr", type=("build", "run")) depends_on("r-codetools", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-ptw/package.py b/var/spack/repos/builtin/packages/r-ptw/package.py index 7d753a046706f1..6136284070ae55 100644 --- a/var/spack/repos/builtin/packages/r-ptw/package.py +++ b/var/spack/repos/builtin/packages/r-ptw/package.py @@ -30,5 +30,7 @@ class RPtw(RPackage): version("1.9-13", sha256="7855e74a167db3d3eba9df9d9c3daa25d7cf487cbcfe8b095f16d96eba862f46") version("1.9-12", sha256="cdb1752e04e661e379f11867b0a17e2177e9ee647c54bbcc37d39d6b8c062b84") + depends_on("c", type="build") # generated + depends_on("r-nloptr", type=("build", "run")) depends_on("r-rcppde", type=("build", "run"), when="@1.9-16:") diff --git a/var/spack/repos/builtin/packages/r-qqconf/package.py b/var/spack/repos/builtin/packages/r-qqconf/package.py index 1637124429addd..bf4658c6a71d6d 100644 --- a/var/spack/repos/builtin/packages/r-qqconf/package.py +++ b/var/spack/repos/builtin/packages/r-qqconf/package.py @@ -21,6 +21,8 @@ class RQqconf(RPackage): version("1.3.0", sha256="1c42ab81403568f3ad53217cc85190dad7c2fae957bfd0f0f30d57be0a065087") version("1.2.3", sha256="9b5b6042ea8e52e6e049807c0b5e3bfd534b624bd257be769de69cf505fece62") + depends_on("cxx", type="build") # generated + depends_on("r@3.0.0:", type=("build", "run")) depends_on("r@4.0.0:", type=("build", "run"), when="@1.3.0:") depends_on("r-mass@7.3-50:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-quadprog/package.py b/var/spack/repos/builtin/packages/r-quadprog/package.py index 91319e9e8f492d..d21581112927e6 100644 --- a/var/spack/repos/builtin/packages/r-quadprog/package.py +++ b/var/spack/repos/builtin/packages/r-quadprog/package.py @@ -21,4 +21,7 @@ class RQuadprog(RPackage): version("1.5-6", sha256="1443e5ffdf884b13dd454e4f6aa260fce6ec47e6845d85b62238c206ce57dcba") version("1.5-5", sha256="d999620688354c283de5bb305203f5db70271b4dfdc23577cae8c2ba94c9e349") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@3.1.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-randomforest/package.py b/var/spack/repos/builtin/packages/r-randomforest/package.py index 5349bc60c23864..2c8eff647bd659 100644 --- a/var/spack/repos/builtin/packages/r-randomforest/package.py +++ b/var/spack/repos/builtin/packages/r-randomforest/package.py @@ -20,6 +20,9 @@ class RRandomforest(RPackage): version("4.6-14", sha256="f4b88920419eb0a89d0bc5744af0416d92d112988702dc726882394128a8754d") version("4.6-12", sha256="6e512f8f88a51c01a918360acba61f1f39432f6e690bc231b7864218558b83c4") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@2.5.0:", type=("build", "run")) depends_on("r@3.2.2:", type=("build", "run"), when="@4.6-14:") depends_on("r@4.1.0:", type=("build", "run"), when="@4.7-1.1:") diff --git a/var/spack/repos/builtin/packages/r-rann/package.py b/var/spack/repos/builtin/packages/r-rann/package.py index b09253a0a3847e..f940d9e2cff4a7 100644 --- a/var/spack/repos/builtin/packages/r-rann/package.py +++ b/var/spack/repos/builtin/packages/r-rann/package.py @@ -19,3 +19,6 @@ class RRann(RPackage): cran = "RANN" version("2.6.1", sha256="b299c3dfb7be17aa41e66eff5674fddd2992fb6dd3b10bc59ffbf0c401697182") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-rappdirs/package.py b/var/spack/repos/builtin/packages/r-rappdirs/package.py index da734837889fe2..2e829111d035f4 100644 --- a/var/spack/repos/builtin/packages/r-rappdirs/package.py +++ b/var/spack/repos/builtin/packages/r-rappdirs/package.py @@ -20,5 +20,7 @@ class RRappdirs(RPackage): version("0.3.3", sha256="49959f65b45b0b189a2792d6c1339bef59674ecae92f8c2ed9f26ff9e488c184") version("0.3.1", sha256="2fd891ec16d28862f65bb57e4a78f77a597930abb59380e757afd8b6c6d3264a") + depends_on("c", type="build") # generated + depends_on("r@2.14:", type=("build", "run")) depends_on("r@3.2:", type=("build", "run"), when="@0.3.2:") diff --git a/var/spack/repos/builtin/packages/r-rbgl/package.py b/var/spack/repos/builtin/packages/r-rbgl/package.py index 4807eb795d5ead..09aaa528737476 100644 --- a/var/spack/repos/builtin/packages/r-rbgl/package.py +++ b/var/spack/repos/builtin/packages/r-rbgl/package.py @@ -27,5 +27,7 @@ class RRbgl(RPackage): version("1.54.0", commit="e9c743d380e83c155495cb8732102f01f213c905") version("1.52.0", commit="93e8fcfafec8f1cd5638fe30dc0f9506d15b49c0") + depends_on("cxx", type="build") # generated + depends_on("r-graph", type=("build", "run")) depends_on("r-bh", type=("build", "run"), when="@1.60.0:") diff --git a/var/spack/repos/builtin/packages/r-rcpp/package.py b/var/spack/repos/builtin/packages/r-rcpp/package.py index 8653f446c46ca7..f6e52df3a1cf6d 100644 --- a/var/spack/repos/builtin/packages/r-rcpp/package.py +++ b/var/spack/repos/builtin/packages/r-rcpp/package.py @@ -23,6 +23,8 @@ class RRcpp(RPackage): cran = "Rcpp" + version("1.0.12", sha256="0c7359cc43beee02761aa3df2baccede1182d29d28c9cd49964b609305062bd0") + version("1.0.11", sha256="df757c3068599c6c05367900bcad93547ba3422d59802dbaca20fd74d4d2fa5f") version("1.0.10", sha256="1e65e24a9981251ab5fc4f9fd65fe4eab4ba0255be3400a8c5abe20b62b5d546") version("1.0.9", sha256="807cec06dc4a96d54904360f6144466f084a7ed411ce5d2eea486a9b3c229176") version("1.0.8.3", sha256="9da5b84cdaf56e972b41e669d496b1ece2e91bcd435505c68b9f2bd98375f8bf") @@ -45,6 +47,9 @@ class RRcpp(RPackage): version("0.12.6", sha256="1bb54e03b817a3d6ab5917f1bbf5250c6b33f61e466628a378022ed65a010141") version("0.12.5", sha256="13449481c91b5271b34d81f462864864c1905bb05021781eee11c36fdafa80ef") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # leave the r dependency also for newer versions # (not listed in Description for @1.0.5:) depends_on("r@3.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rcppcctz/package.py b/var/spack/repos/builtin/packages/r-rcppcctz/package.py index 6858c016212411..da5445c13f76c2 100644 --- a/var/spack/repos/builtin/packages/r-rcppcctz/package.py +++ b/var/spack/repos/builtin/packages/r-rcppcctz/package.py @@ -25,4 +25,6 @@ class RRcppcctz(RPackage): version("0.2.4", sha256="98b6867d38abe03957fe803e88b6cc2d122b85a68ef07fa86f7e1009d6c00819") version("0.2.3", sha256="0fefcc98387b2c1a5907e5230babb46e2cc11b603424f458f515e445a3236031") + depends_on("cxx", type="build") # generated + depends_on("r-rcpp@0.11.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rcppdate/package.py b/var/spack/repos/builtin/packages/r-rcppdate/package.py index 8135cc8a8232de..ec3c7e4914662e 100644 --- a/var/spack/repos/builtin/packages/r-rcppdate/package.py +++ b/var/spack/repos/builtin/packages/r-rcppdate/package.py @@ -23,3 +23,5 @@ class RRcppdate(RPackage): version("0.0.3", sha256="9c5ee7cf76d63cd51e8faff831f5f865762868d7d705395960c0f22e9b238bdb") version("0.0.1", sha256="117721fc677dfb4209200a7ff894fbbb8ee1b652d01b3878b11c3253733b4a5f") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-rcppde/package.py b/var/spack/repos/builtin/packages/r-rcppde/package.py index 25680af5618d8d..351c87ca7f49bd 100644 --- a/var/spack/repos/builtin/packages/r-rcppde/package.py +++ b/var/spack/repos/builtin/packages/r-rcppde/package.py @@ -23,5 +23,7 @@ class RRcppde(RPackage): version("0.1.7", sha256="4a238ee97e574cb44b12e4962b9927dd811f087fc13fc777637ec6fe12bd86a0") version("0.1.6", sha256="c9386709f72cdc33505b3ac675c173013fe098434b7c21bc09eb625b529132c5") + depends_on("cxx", type="build") # generated + depends_on("r-rcpp", type=("build", "run")) depends_on("r-rcpparmadillo", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rcppgsl/package.py b/var/spack/repos/builtin/packages/r-rcppgsl/package.py index 27e486c3104edd..23487f0d088cac 100644 --- a/var/spack/repos/builtin/packages/r-rcppgsl/package.py +++ b/var/spack/repos/builtin/packages/r-rcppgsl/package.py @@ -29,5 +29,8 @@ class RRcppgsl(RPackage): version("0.3.11", sha256="f094ea26c99b04d9e203986a1f2003f02472ceca0e2ef1c3beefd3ae80aeada8") version("0.3.10", sha256="8612087da02fb791f427fed310c23d0482a8eb60fb089119f018878143f95451") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r-rcpp@0.11.0:", type=("build", "run")) depends_on("gsl") diff --git a/var/spack/repos/builtin/packages/r-rcppml/package.py b/var/spack/repos/builtin/packages/r-rcppml/package.py index 7f986444e6c67a..2bf3bc249e0b21 100644 --- a/var/spack/repos/builtin/packages/r-rcppml/package.py +++ b/var/spack/repos/builtin/packages/r-rcppml/package.py @@ -16,6 +16,8 @@ class RRcppml(RPackage): version("0.3.7", sha256="325c6515085527eb9123cc5e87e028547065771ed4d623048f41886ae28908c6") + depends_on("cxx", type="build") # generated + depends_on("r-rcpp", type=("build", "run")) depends_on("r-matrix", type=("build", "run")) depends_on("r-rcppeigen", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rcppprogress/package.py b/var/spack/repos/builtin/packages/r-rcppprogress/package.py index 115f7978c43a90..9693b278bcf7c6 100644 --- a/var/spack/repos/builtin/packages/r-rcppprogress/package.py +++ b/var/spack/repos/builtin/packages/r-rcppprogress/package.py @@ -23,4 +23,6 @@ class RRcppprogress(RPackage): version("0.2", sha256="ca32624739058f1b5aab18b09dc4c613ecfd18a3ace39f3b97790232db829481") version("0.1", sha256="04f71d3391b7dfab997afadf7ffdd87b88037f7fbc751bea544ad2a65e2872bf") + depends_on("cxx", type="build") # generated + depends_on("r-rcpp@0.9.4:", type=("build", "run"), when="@:0.4") diff --git a/var/spack/repos/builtin/packages/r-rcpptoml/package.py b/var/spack/repos/builtin/packages/r-rcpptoml/package.py index 78954874e32375..ccb7b5be6eb94a 100644 --- a/var/spack/repos/builtin/packages/r-rcpptoml/package.py +++ b/var/spack/repos/builtin/packages/r-rcpptoml/package.py @@ -22,5 +22,7 @@ class RRcpptoml(RPackage): version("0.2.2", sha256="371391f9ca82221e76a424082ea9ebc5ea2c50f14e8408469b09d7dc3e6f63aa") version("0.1.7", sha256="2f09f00cbee6c6eeff5d5f0195c10de0155496de15fbe8189c18627ee3090541") + depends_on("cxx", type="build") # generated + depends_on("r@3.3.0:", type=("build", "run")) depends_on("r-rcpp@0.11.5:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rcppziggurat/package.py b/var/spack/repos/builtin/packages/r-rcppziggurat/package.py index 5b10ed4f15aafe..e261a2745cccb3 100644 --- a/var/spack/repos/builtin/packages/r-rcppziggurat/package.py +++ b/var/spack/repos/builtin/packages/r-rcppziggurat/package.py @@ -20,6 +20,9 @@ class RRcppziggurat(RPackage): version("0.1.6", sha256="9c78255ca476c945c05a564d1e4da363de714d890e0e27f3b252fd73c50eed71") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r-rcpp", type=("build", "run")) depends_on("r-rcppgsl", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-reshape2/package.py b/var/spack/repos/builtin/packages/r-reshape2/package.py index 713f78c9d2ad52..eff1aeeafee538 100644 --- a/var/spack/repos/builtin/packages/r-reshape2/package.py +++ b/var/spack/repos/builtin/packages/r-reshape2/package.py @@ -21,6 +21,8 @@ class RReshape2(RPackage): version("1.4.2", sha256="6d3783610379be4c5676d9236cf66276a166b5b96c18f2759e9b219758959b6b") version("1.4.1", sha256="fbd49f75a5b0b7266378515af98db310cf6c772bf6e68bed01f38ee99b408042") + depends_on("cxx", type="build") # generated + depends_on("r@3.1:", type=("build", "run"), when="@1.4.3:") depends_on("r-plyr@1.8.1:", type=("build", "run")) depends_on("r-rcpp", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-restfulr/package.py b/var/spack/repos/builtin/packages/r-restfulr/package.py index d325d585dcb3f3..499f102c541c2d 100644 --- a/var/spack/repos/builtin/packages/r-restfulr/package.py +++ b/var/spack/repos/builtin/packages/r-restfulr/package.py @@ -18,6 +18,8 @@ class RRestfulr(RPackage): version("0.0.15", sha256="40ff8f1fb2987af2223e1a855bb1680c5ce2143fbce7ebc42f1edb291f80e692") version("0.0.13", sha256="7b59f5887aaf02f46a80617f4d1e0ffd4e11e4840e9e2fbd486a9a9c7f2d64b6") + depends_on("c", type="build") # generated + depends_on("r@3.4.0:", type=("build", "run")) depends_on("r-xml", type=("build", "run")) depends_on("r-rcurl", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rferns/package.py b/var/spack/repos/builtin/packages/r-rferns/package.py index 8dcaeff9c0ad5e..20d67a8e0c8320 100644 --- a/var/spack/repos/builtin/packages/r-rferns/package.py +++ b/var/spack/repos/builtin/packages/r-rferns/package.py @@ -19,3 +19,5 @@ class RRferns(RPackage): version("5.0.0", sha256="78da671e18dc1fb499eddcc6db7eedd69cef673ba0b46c873bd95615cbb583fb") version("4.0.0", sha256="cc8cea0893390bf5db0fb0f59748d5bf6f29537d68bedca900268fd551489128") version("3.0.0", sha256="35e7e31a6497e415a0fe578678cf9b2f537b21319e4c015a1e2dade00310227c") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-rgraphviz/package.py b/var/spack/repos/builtin/packages/r-rgraphviz/package.py index eb0fb02104432b..a5266eb9121db1 100644 --- a/var/spack/repos/builtin/packages/r-rgraphviz/package.py +++ b/var/spack/repos/builtin/packages/r-rgraphviz/package.py @@ -25,6 +25,9 @@ class RRgraphviz(RPackage): version("2.22.0", commit="5b8ebbf9b38574c08959dd4632e802b3fbccc121") version("2.20.0", commit="eface6298150667bb22eac672f1a45e52fbf8c90") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r+X", type=("build", "run")) depends_on("r@2.6.0:", type=("build", "run")) depends_on("r-graph", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rhdf5/package.py b/var/spack/repos/builtin/packages/r-rhdf5/package.py index a312524388e8ea..43f1f23795ed0e 100644 --- a/var/spack/repos/builtin/packages/r-rhdf5/package.py +++ b/var/spack/repos/builtin/packages/r-rhdf5/package.py @@ -30,6 +30,9 @@ class RRhdf5(RPackage): version("2.22.0", commit="4431bdc0a2bcbb8086ee08a0f2300129b808d1be") version("2.20.0", commit="37b5165325062728bbec9167f89f5f4b794f30bc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.5.0:", type=("build", "run"), when="@2.26.2:") depends_on("r@4.0.0:", type=("build", "run"), when="@2.38.0:") depends_on("r-rhdf5lib", type=("build", "run"), when="@2.24.0:") diff --git a/var/spack/repos/builtin/packages/r-rhdf5filters/package.py b/var/spack/repos/builtin/packages/r-rhdf5filters/package.py index 560cf9dba4a4f5..06153a6dcc9528 100644 --- a/var/spack/repos/builtin/packages/r-rhdf5filters/package.py +++ b/var/spack/repos/builtin/packages/r-rhdf5filters/package.py @@ -21,6 +21,9 @@ class RRhdf5filters(RPackage): version("1.6.0", commit="5f7f3a5b7dabd6e7d0c50cda70290e2472ff4f53") version("1.2.0", commit="25af0180f926b4b3ea11b30ec9277d26ad3d56b3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r-rhdf5lib", type=("build", "run")) depends_on("gmake", type="build") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/r-rhdf5lib/package.py b/var/spack/repos/builtin/packages/r-rhdf5lib/package.py index 05433c61ef7617..382396126ad306 100644 --- a/var/spack/repos/builtin/packages/r-rhdf5lib/package.py +++ b/var/spack/repos/builtin/packages/r-rhdf5lib/package.py @@ -23,6 +23,8 @@ class RRhdf5lib(RPackage): version("1.2.1", commit="dbf85dbedb736d5a696794d52875729c8514494e") version("1.0.0", commit="79608038c2016a518ba747fe6a2bf02ce53a75f9") + depends_on("c", type="build") # generated + depends_on("r@3.3.0:", type="build", when="@1.12.1:") depends_on("r@4.0.0:", type="build", when="@1.16.0:") depends_on("r@4.2.0:", type=("build", "run"), when="@1.22.0:") diff --git a/var/spack/repos/builtin/packages/r-rhtslib/package.py b/var/spack/repos/builtin/packages/r-rhtslib/package.py index 8f2896c7b6acf8..96726aade7fd3b 100644 --- a/var/spack/repos/builtin/packages/r-rhtslib/package.py +++ b/var/spack/repos/builtin/packages/r-rhtslib/package.py @@ -38,6 +38,8 @@ class RRhtslib(RPackage): version("1.10.0", commit="53dcf7dfe35d735283956c77c011a97ca3f4eb26") version("1.8.0", commit="3b5493473bed42958614091c58c739932ffcfa79") + depends_on("c", type="build") # generated + depends_on("r-zlibbioc", type=("build", "run")) depends_on("bzip2", type=("build", "link", "run")) depends_on("xz", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/r-rinside/package.py b/var/spack/repos/builtin/packages/r-rinside/package.py index b2f222bdd11828..693d8ea3861459 100644 --- a/var/spack/repos/builtin/packages/r-rinside/package.py +++ b/var/spack/repos/builtin/packages/r-rinside/package.py @@ -33,4 +33,7 @@ class RRinside(RPackage): version("0.2.14", sha256="8de5340993fe879ca00fa559c5b1b27b408ba78bfc5f67d36d6f0b8d8e8649cf") version("0.2.13", sha256="be1da861f4f8c1292f0691bce05978e409a081f24ad6006ae173a6a89aa4d031") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r-rcpp", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rjson/package.py b/var/spack/repos/builtin/packages/r-rjson/package.py index d45011509d2b76..55bfe6a4af01a5 100644 --- a/var/spack/repos/builtin/packages/r-rjson/package.py +++ b/var/spack/repos/builtin/packages/r-rjson/package.py @@ -20,5 +20,8 @@ class RRjson(RPackage): version("0.2.19", sha256="5c2672461986f2b715416cab92ed262abe9875f31299bc8a1a072ef7c6dd49bc") version("0.2.15", sha256="77d00d8f6a1c936329b46f3b8b0be79a165f8c5f1989497f942ecc53dcf6f2ef") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.1.0:", type=("build", "run")) depends_on("r@4.0.0:", type=("build", "run"), when="@0.2.21:") diff --git a/var/spack/repos/builtin/packages/r-rle/package.py b/var/spack/repos/builtin/packages/r-rle/package.py index 60b2088e53da6c..5623401066f77c 100644 --- a/var/spack/repos/builtin/packages/r-rle/package.py +++ b/var/spack/repos/builtin/packages/r-rle/package.py @@ -18,4 +18,6 @@ class RRle(RPackage): version("0.9.2", sha256="803cbe310af6e882e27be61d37d660dbe5910ac1ee1eff61a480bcf724a04f69") + depends_on("c", type="build") # generated + depends_on("r@3.5:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rmutil/package.py b/var/spack/repos/builtin/packages/r-rmutil/package.py index 9405ff6fbc8877..bff73411916c3a 100644 --- a/var/spack/repos/builtin/packages/r-rmutil/package.py +++ b/var/spack/repos/builtin/packages/r-rmutil/package.py @@ -23,4 +23,7 @@ class RRmutil(RPackage): version("1.1.5", sha256="6077e643d6daeba6edcf49d928320b54cc6aa6ff59934f9e9e6071a2f9afb2f6") version("1.1.3", sha256="7abaf41e99d1c4a0e4082c4594964ac1421c53b4268116c82fa55aa8bc0582da") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@1.4:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rnaseqmap/package.py b/var/spack/repos/builtin/packages/r-rnaseqmap/package.py index 6f9cadba5d3e1f..82256402c2c9f7 100644 --- a/var/spack/repos/builtin/packages/r-rnaseqmap/package.py +++ b/var/spack/repos/builtin/packages/r-rnaseqmap/package.py @@ -22,6 +22,8 @@ class RRnaseqmap(RPackage): version("2.36.0", commit="69c46fa467be0ac30776ede85a521f7622539b7e") version("2.34.0", commit="7881bc00600ed824ac437edf3cfba35573261e46") + depends_on("c", type="build") # generated + depends_on("r@2.11.0:", type=("build", "run")) depends_on("r-biobase", type=("build", "run")) depends_on("r-rsamtools", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rncl/package.py b/var/spack/repos/builtin/packages/r-rncl/package.py index 7fef555fec1cd3..fde4673d6c8dfd 100644 --- a/var/spack/repos/builtin/packages/r-rncl/package.py +++ b/var/spack/repos/builtin/packages/r-rncl/package.py @@ -23,6 +23,9 @@ class RRncl(RPackage): version("0.8.6", sha256="fcc972c04fb43ace0876eb640a6433caddf6ec8304f7ceee37107d812ce68ffb") version("0.8.4", sha256="6b19d0dd9bb08ecf99766be5ad684bcd1894d1cd9291230bdd709dbd3396496b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.1.1:", type=("build", "run")) depends_on("r-rcpp@0.11.0:", type=("build", "run")) depends_on("r-progress@1.1.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-roc/package.py b/var/spack/repos/builtin/packages/r-roc/package.py index 35d02e07bde02d..a56f672ff2f12a 100644 --- a/var/spack/repos/builtin/packages/r-roc/package.py +++ b/var/spack/repos/builtin/packages/r-roc/package.py @@ -20,5 +20,7 @@ class RRoc(RPackage): version("1.66.0", commit="62701ee41f48f99d15344127384fa032db69486f") version("1.62.0", commit="60250fdb091f6a938709b8a2cffe6442ee22a9a2") + depends_on("cxx", type="build") # generated + depends_on("r@1.9.0:", type=("build", "run")) depends_on("r-knitr", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rook/package.py b/var/spack/repos/builtin/packages/r-rook/package.py index a7ccc3e09485cd..4abc733ae3b72b 100644 --- a/var/spack/repos/builtin/packages/r-rook/package.py +++ b/var/spack/repos/builtin/packages/r-rook/package.py @@ -18,5 +18,7 @@ class RRook(RPackage): version("1.2", sha256="c79ae4b5164daffd4e7cf74bd23c1b08a3948bf343dfe9570d57f39cbf8e5f62") version("1.1-1", sha256="00f4ecfa4c5c57018acbb749080c07154549a6ecaa8d4130dd9de79427504903") + depends_on("c", type="build") # generated + depends_on("r@2.13.0:", type=("build", "run")) depends_on("r-brew", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rots/package.py b/var/spack/repos/builtin/packages/r-rots/package.py index d85b123da8d838..0aef4000837d5c 100644 --- a/var/spack/repos/builtin/packages/r-rots/package.py +++ b/var/spack/repos/builtin/packages/r-rots/package.py @@ -25,6 +25,8 @@ class RRots(RPackage): version("1.6.0", commit="3567ac1142ba97770b701ee8e5f9e3e6c781bd56") version("1.4.0", commit="2e656514a4bf5a837ee6e14ce9b28a61dab955e7") + depends_on("cxx", type="build") # generated + depends_on("r@3.3:", type=("build", "run")) depends_on("r-rcpp", type=("build", "run")) depends_on("r-biobase", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rsamtools/package.py b/var/spack/repos/builtin/packages/r-rsamtools/package.py index 60489b90021b31..6ce8eae4892fcd 100644 --- a/var/spack/repos/builtin/packages/r-rsamtools/package.py +++ b/var/spack/repos/builtin/packages/r-rsamtools/package.py @@ -31,6 +31,9 @@ class RRsamtools(RPackage): version("1.30.0", commit="61b365fe3762e796b3808cec7238944b7f68d7a6") version("1.28.0", commit="dfa5b6abef68175586f21add7927174786412472") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.5.0:", type=("build", "run"), when="@2.10.0:") depends_on("r-genomeinfodb@1.1.3:", type=("build", "run")) depends_on("r-genomicranges@1.21.6:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rspectra/package.py b/var/spack/repos/builtin/packages/r-rspectra/package.py index 93fe03871aa62b..76a264fd1cf995 100644 --- a/var/spack/repos/builtin/packages/r-rspectra/package.py +++ b/var/spack/repos/builtin/packages/r-rspectra/package.py @@ -26,6 +26,9 @@ class RRspectra(RPackage): version("0.16-0", sha256="aaf1cfc9ffe3a4c6684247899924e1c18306971dfef4bae1dc596a2fb42a64a9") version("0.15-0", sha256="1ad5698201007044a0420cb10b7c48e94312a8a1d22b9d946d5de1c6743969a9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.0.2:", type=("build", "run")) depends_on("r-matrix@1.1-0:", type=("build", "run")) depends_on("r-rcpp@0.11.5:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rsubread/package.py b/var/spack/repos/builtin/packages/r-rsubread/package.py index 2b6ba1166d70c6..6f867a3e010afa 100644 --- a/var/spack/repos/builtin/packages/r-rsubread/package.py +++ b/var/spack/repos/builtin/packages/r-rsubread/package.py @@ -14,6 +14,8 @@ class RRsubread(RPackage): version("2.16.0", commit="62b92c9ed3fc2be89ed9f29e3db1809d1e115dbc") version("2.14.2", commit="863bd98c6523b888da59335a6acb516d2676d412") + depends_on("c", type="build") # generated + depends_on("r", type=("build", "run")) depends_on("r-matrix", type=("build", "run")) depends_on("r-r-utils", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rtracklayer/package.py b/var/spack/repos/builtin/packages/r-rtracklayer/package.py index 3acc58d1c71446..7e2d1b42711a63 100644 --- a/var/spack/repos/builtin/packages/r-rtracklayer/package.py +++ b/var/spack/repos/builtin/packages/r-rtracklayer/package.py @@ -30,6 +30,8 @@ class RRtracklayer(RPackage): version("1.38.3", commit="f20db703c09dc7e808c09e9b78c15aec9e546248") version("1.36.6", commit="8c0ac7230f94e0c5a981acbb178c8de70e968131") + depends_on("c", type="build") # generated + depends_on("r@3.3:", type=("build", "run")) depends_on("r-genomicranges@1.21.20:", type=("build", "run")) depends_on("r-genomicranges@1.37.2:", type=("build", "run"), when="@1.50.0:") diff --git a/var/spack/repos/builtin/packages/r-ruv/package.py b/var/spack/repos/builtin/packages/r-ruv/package.py index 8abccd4aae4ebf..fc18dfdc1c7ebe 100644 --- a/var/spack/repos/builtin/packages/r-ruv/package.py +++ b/var/spack/repos/builtin/packages/r-ruv/package.py @@ -28,6 +28,8 @@ class RRuv(RPackage): version("0.9.7.1", sha256="a0c54e56ba3d8f6ae178ae4d0e417a79295abf5dcb68bbae26c4b874734d98d8") + depends_on("c", type="build") # generated + depends_on("r-ggplot2", type=("build", "run")) depends_on("r-scales", type=("build", "run")) depends_on("r-gridextra", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-rviennacl/package.py b/var/spack/repos/builtin/packages/r-rviennacl/package.py index 78f4f5e32c0635..c12caca3bd72b9 100644 --- a/var/spack/repos/builtin/packages/r-rviennacl/package.py +++ b/var/spack/repos/builtin/packages/r-rviennacl/package.py @@ -20,3 +20,5 @@ class RRviennacl(RPackage): cran = "RViennaCL" version("1.7.1.8", sha256="adcc74537337582153d5b11d281e391e91a7f3afae116aa1b9a034ffd11b0252") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-s4vectors/package.py b/var/spack/repos/builtin/packages/r-s4vectors/package.py index 1527b55ca7dd3f..7a8760619591f6 100644 --- a/var/spack/repos/builtin/packages/r-s4vectors/package.py +++ b/var/spack/repos/builtin/packages/r-s4vectors/package.py @@ -32,6 +32,8 @@ class RS4vectors(RPackage): version("0.16.0", commit="00fec03fcbcb7cff37917fab0da28d91fdf9dc3d") version("0.14.7", commit="40af17fe0b8e93b6a72fc787540d2961773b8e23") + depends_on("c", type="build") # generated + depends_on("r@3.3.0:", type=("build", "run")) depends_on("r@4.0.0:", type=("build", "run"), when="@0.28.1:") depends_on("r-biocgenerics@0.21.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-samr/package.py b/var/spack/repos/builtin/packages/r-samr/package.py index fe5d05918a5bce..fbbcf2b6c450d8 100644 --- a/var/spack/repos/builtin/packages/r-samr/package.py +++ b/var/spack/repos/builtin/packages/r-samr/package.py @@ -19,6 +19,9 @@ class RSamr(RPackage): version("3.0", sha256="25f88ac002c2adce8881a562241bc12d683810a05defb553e8e3d4878f037506") version("2.0", sha256="090b5becd91d60f4bb8269df5c9bc19a03c09917d327b28e75b0ee7b80624e67") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r-impute", type=("build", "run")) depends_on("r-matrixstats", type=("build", "run")) depends_on("r-shiny", type=("build", "run"), when="@3.0:") diff --git a/var/spack/repos/builtin/packages/r-scales/package.py b/var/spack/repos/builtin/packages/r-scales/package.py index d431c428f886a4..38e64733b39619 100644 --- a/var/spack/repos/builtin/packages/r-scales/package.py +++ b/var/spack/repos/builtin/packages/r-scales/package.py @@ -16,6 +16,7 @@ class RScales(RPackage): license("MIT") + version("1.3.0", sha256="b33e0f6b44259551ce02befd52eac53602509fbfdd903920620c658c50f35888") version("1.2.1", sha256="59453e6dbdafee93dfb101e4d86048a62a12898134259d3ef02d65aeec57ed08") version("1.2.0", sha256="185d50240e6b3e84d36ec7fbca6aef7a85db7c8c1b0dde51d4af28d363ce02df") version("1.1.1", sha256="40b2b66522f1f314a20fd09426011b0cdc9d16b23ee2e765fe1930292dd03705") diff --git a/var/spack/repos/builtin/packages/r-scran/package.py b/var/spack/repos/builtin/packages/r-scran/package.py index 494607b9525140..84ce4cb73beb74 100644 --- a/var/spack/repos/builtin/packages/r-scran/package.py +++ b/var/spack/repos/builtin/packages/r-scran/package.py @@ -22,6 +22,8 @@ class RScran(RPackage): version("1.24.1", commit="1a83eb7c948b1dc49253080c23b26cefb3a0f3b9") version("1.24.0", commit="c3f9e169c4538ce827d4f14a4141571c2366cd31") + depends_on("cxx", type="build") # generated + depends_on("r-singlecellexperiment", type=("build", "run")) depends_on("r-scuttle", type=("build", "run")) depends_on("r-summarizedexperiment", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-scs/package.py b/var/spack/repos/builtin/packages/r-scs/package.py index c6f31f98e0fd17..3055748a612847 100644 --- a/var/spack/repos/builtin/packages/r-scs/package.py +++ b/var/spack/repos/builtin/packages/r-scs/package.py @@ -25,5 +25,7 @@ class RScs(RPackage): version("3.2.4", sha256="c3f39874bf4532fa8c2f2e2c41533ba4fe20b61cf6dfc6314407dc981621298f") version("3.0-1", sha256="d6881eeec7282f8bfbf60847327786e7f90299e4b8c0b084d8bd11fec7705913") + depends_on("c", type="build") # generated + depends_on("r@3.5.0:", type=("build", "run")) depends_on("gmake", type="build") diff --git a/var/spack/repos/builtin/packages/r-scuttle/package.py b/var/spack/repos/builtin/packages/r-scuttle/package.py index 42e8ac5e8fa5f0..48f4b0e58f942a 100644 --- a/var/spack/repos/builtin/packages/r-scuttle/package.py +++ b/var/spack/repos/builtin/packages/r-scuttle/package.py @@ -23,6 +23,8 @@ class RScuttle(RPackage): version("1.4.0", commit="b335263dd56bb859b5dd3ea27ee00dffa0215313") version("1.0.4", commit="a827e2759d80e6c3510e2f8fd4bd680274206d9f") + depends_on("cxx", type="build") # generated + depends_on("r-singlecellexperiment", type=("build", "run")) depends_on("r-matrix", type=("build", "run")) depends_on("r-rcpp", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-shiny/package.py b/var/spack/repos/builtin/packages/r-shiny/package.py index b969837c621cae..91acdf5b46587f 100644 --- a/var/spack/repos/builtin/packages/r-shiny/package.py +++ b/var/spack/repos/builtin/packages/r-shiny/package.py @@ -18,6 +18,7 @@ class RShiny(RPackage): license("GPL-3.0-only OR custom") + version("1.8.1.1", sha256="a38d5fb5d750e2c2091ce9101f138c1f9bc7009bbb195227a3519c5d97e36753") version("1.7.4", sha256="bbfcdd7375013b8f59248b3f3f4e752acd445feb25179f3f7f65cd69614da4b5") version("1.7.3", sha256="b8ca9a39fa69ea9b270a7e9037198d95122c79bd493b865d909d343dd3523ada") version("1.7.2", sha256="23b5bfee8d597b4147e07c89391a735361cd9f69abeecfd9bd38a14d35fe6252") @@ -51,12 +52,13 @@ class RShiny(RPackage): depends_on("r-rlang@0.4.10:", type=("build", "run"), when="@1.7.1:") depends_on("r-fastmap@1.0.0:", type=("build", "run"), when="@1.5.0:") depends_on("r-fastmap@1.1.0:", type=("build", "run"), when="@1.7.1:") + depends_on("r-fastmap@1.1.1:", type=("build", "run"), when="@1.7.5:") depends_on("r-withr", type=("build", "run"), when="@1.5.0:") depends_on("r-commonmark@1.7:", type=("build", "run"), when="@1.5.0:") depends_on("r-glue@1.3.2:", type=("build", "run"), when="@1.5.0:") depends_on("r-bslib@0.3.0:", type=("build", "run"), when="@1.7.1:") depends_on("r-cachem", type=("build", "run"), when="@1.7.1:") - depends_on("r-ellipsis", type=("build", "run"), when="@1.7.1:") depends_on("r-lifecycle@0.2.0:", type=("build", "run"), when="@1.7.1:") depends_on("r-digest", type=("build", "run"), when="@:1.5.0") + depends_on("r-ellipsis", type=("build", "run"), when="@1.7.1:1.8.0") diff --git a/var/spack/repos/builtin/packages/r-shortread/package.py b/var/spack/repos/builtin/packages/r-shortread/package.py index da27db85af7190..c23df0d017b068 100644 --- a/var/spack/repos/builtin/packages/r-shortread/package.py +++ b/var/spack/repos/builtin/packages/r-shortread/package.py @@ -29,6 +29,9 @@ class RShortread(RPackage): version("1.36.1", commit="176c34eddf4a416d30c69cb4ac197141ba42e66f") version("1.34.2", commit="25daac63b301df66a8ef6e98cc2977522c6786cd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r-biocgenerics@0.22.1:", type=("build", "run")) depends_on("r-biocgenerics@0.23.3:", type=("build", "run"), when="@1.36.1:") depends_on("r-biocparallel", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-simpleaffy/package.py b/var/spack/repos/builtin/packages/r-simpleaffy/package.py index d56ef2989372a8..005c2ffc062a8e 100644 --- a/var/spack/repos/builtin/packages/r-simpleaffy/package.py +++ b/var/spack/repos/builtin/packages/r-simpleaffy/package.py @@ -26,6 +26,8 @@ class RSimpleaffy(RPackage): version("2.54.0", commit="6876e028d412b14504ad3915cbec1a189e9c6478") version("2.52.0", commit="f2b43fb9b8e6fa4c03fe28b4efb3144a0a42a385") + depends_on("c", type="build") # generated + depends_on("r@2.0.0:", type=("build", "run")) depends_on("r-biocgenerics@0.1.12:", type=("build", "run")) depends_on("r-biobase", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-sitmo/package.py b/var/spack/repos/builtin/packages/r-sitmo/package.py index 09de1b2c2a9797..6d40cc9fd73056 100644 --- a/var/spack/repos/builtin/packages/r-sitmo/package.py +++ b/var/spack/repos/builtin/packages/r-sitmo/package.py @@ -26,5 +26,7 @@ class RSitmo(RPackage): version("2.0.2", sha256="448ef8d56e36783354011845daf33f1efb83ea3b9685eea75eaf5134e24fa8c2") version("2.0.1", sha256="0c90d357af334d5c99c8956739dc12623ddd87dda5efa59f4a43f7393c87ed2a") + depends_on("cxx", type="build") # generated + depends_on("r@3.2.0:", type=("build", "run")) depends_on("r-rcpp@0.12.13:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-smoof/package.py b/var/spack/repos/builtin/packages/r-smoof/package.py index 6a3144ec782348..fb1262b617ccba 100644 --- a/var/spack/repos/builtin/packages/r-smoof/package.py +++ b/var/spack/repos/builtin/packages/r-smoof/package.py @@ -24,6 +24,9 @@ class RSmoof(RPackage): version("1.5.1", sha256="cfb6f6460e9593351428656b225b5ba3867a216d35a05f2babdb20db6ba35306") version("1.5", sha256="9b73ad5bfc8e1120c9651539ea52b1468f316cc7fc5fef8afd6d357adf01504c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r+X", type=("build", "run")) depends_on("r-paramhelpers@1.8:", type=("build", "run")) depends_on("r-checkmate@1.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-snprelate/package.py b/var/spack/repos/builtin/packages/r-snprelate/package.py index 5ce53283911787..18d57ae809f69f 100644 --- a/var/spack/repos/builtin/packages/r-snprelate/package.py +++ b/var/spack/repos/builtin/packages/r-snprelate/package.py @@ -40,5 +40,8 @@ class RSnprelate(RPackage): version("1.12.2", commit="dce2e2b6f36483a9f905bb5df6ae834a9f1136fe") version("1.10.2", commit="3f5c4010871df742e7a460586b38ad0c2fd37aeb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.15:", type=("build", "run")) depends_on("r-gdsfmt@1.8.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-snpstats/package.py b/var/spack/repos/builtin/packages/r-snpstats/package.py index aed788cd8ed5dc..b5ac2a05b6789b 100644 --- a/var/spack/repos/builtin/packages/r-snpstats/package.py +++ b/var/spack/repos/builtin/packages/r-snpstats/package.py @@ -26,6 +26,8 @@ class RSnpstats(RPackage): version("1.28.0", commit="8df9f4188f720dfbb4f4f4ec255cd2e22f3f4426") version("1.26.0", commit="7c9b3304073e0556d694a8531882b349822fdda8") + depends_on("c", type="build") # generated + depends_on("r@2.10.0:", type=("build", "run")) depends_on("r-survival", type=("build", "run")) depends_on("r-matrix", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-som/package.py b/var/spack/repos/builtin/packages/r-som/package.py index 4c1515240d5f7b..e1f509b344c1d8 100644 --- a/var/spack/repos/builtin/packages/r-som/package.py +++ b/var/spack/repos/builtin/packages/r-som/package.py @@ -21,4 +21,6 @@ class RSom(RPackage): version("0.3-3", sha256="434e2210df3e6a459a8588606676c02494f58c5b52e25291d142121b7b9be5c7") version("0.3-2", sha256="b46ecb79c08f3d4cf9527d5c7f85a235808dda45dae7f50909b2df90e7b9e543") + depends_on("cxx", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-sourcetools/package.py b/var/spack/repos/builtin/packages/r-sourcetools/package.py index f356242224e5eb..09aa05e2ca1fd1 100644 --- a/var/spack/repos/builtin/packages/r-sourcetools/package.py +++ b/var/spack/repos/builtin/packages/r-sourcetools/package.py @@ -22,4 +22,7 @@ class RSourcetools(RPackage): version("0.1.6", sha256="c9f48d2f0b7f7ed0e7fecdf8e730b0b80c4d567f0e1e880d118b0944b1330c51") version("0.1.5", sha256="c2373357ad76eaa7d03f9f01c19b5001a3e4db788acbca068b0abbe7a99ea64b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.0.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-sparsematrixstats/package.py b/var/spack/repos/builtin/packages/r-sparsematrixstats/package.py index 4b513cd2f41120..c863828a2d7d9c 100644 --- a/var/spack/repos/builtin/packages/r-sparsematrixstats/package.py +++ b/var/spack/repos/builtin/packages/r-sparsematrixstats/package.py @@ -23,6 +23,8 @@ class RSparsematrixstats(RPackage): version("1.6.0", commit="78627a842790af42b6634893087b2bb1f4ac0392") version("1.2.1", commit="9726f3d5e0f03b50c332d85d5e4c339c18b0494c") + depends_on("cxx", type="build") # generated + depends_on("r-matrixgenerics", type=("build", "run")) depends_on("r-matrixgenerics@1.5.3:", type=("build", "run"), when="@1.6.0:") depends_on("r-rcpp", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-spatialpack/package.py b/var/spack/repos/builtin/packages/r-spatialpack/package.py index 8e996635505157..3810d83924b77b 100644 --- a/var/spack/repos/builtin/packages/r-spatialpack/package.py +++ b/var/spack/repos/builtin/packages/r-spatialpack/package.py @@ -24,6 +24,9 @@ class RSpatialpack(RPackage): version("0.3-8", sha256="a0e54b5dee3cd30a634e2d30380fe163942b672073fd909be888803332ed5151") version("0.3", sha256="4c80fc1c77bc97fc678e6e201ecf7f0f89dcf3417b3b497a28a3639e9b30bd8a") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r@3.5.0:", type=("build", "run"), when="@0.3-8196:") depends_on("r-fastmatrix", type=("build", "run"), when="@0.3-8196:") diff --git a/var/spack/repos/builtin/packages/r-statmod/package.py b/var/spack/repos/builtin/packages/r-statmod/package.py index 3f5ba597577145..50f955cbfa0663 100644 --- a/var/spack/repos/builtin/packages/r-statmod/package.py +++ b/var/spack/repos/builtin/packages/r-statmod/package.py @@ -28,4 +28,7 @@ class RStatmod(RPackage): version("1.4.32", sha256="2f67a1cfa66126e6345f8a40564a3077d08f1748f17cb8c8fb05c94ed0f57e20") version("1.4.30", sha256="9d2c1722a85f53623a9ee9f73d835119ae22ae2b8ec7b50d675401e314ea641f") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("r@3.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-strucchange/package.py b/var/spack/repos/builtin/packages/r-strucchange/package.py index c8828973b8765b..f5710547b6e5da 100644 --- a/var/spack/repos/builtin/packages/r-strucchange/package.py +++ b/var/spack/repos/builtin/packages/r-strucchange/package.py @@ -27,6 +27,8 @@ class RStrucchange(RPackage): version("1.5-2", sha256="7d247c5ae6f5a63c80e478799d009c57fb8803943aa4286d05f71235cc1002f8") version("1.5-1", sha256="740e2e20477b9fceeef767ae1002adc5ec397cb0f7daba5289a2c23b0dddaf31") + depends_on("c", type="build") # generated + depends_on("r@2.10.0:", type=("build", "run")) depends_on("r-zoo", type=("build", "run")) depends_on("r-sandwich", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-strucchangercpp/package.py b/var/spack/repos/builtin/packages/r-strucchangercpp/package.py index 0485cece4f508b..2c4f6fd16c6928 100644 --- a/var/spack/repos/builtin/packages/r-strucchangercpp/package.py +++ b/var/spack/repos/builtin/packages/r-strucchangercpp/package.py @@ -26,6 +26,8 @@ class RStrucchangercpp(RPackage): "1.5-3-1.0.4", sha256="f506fcb593ce4bacf1892de25154257d0fe02260ef956a75438c6330195cd86d" ) + depends_on("cxx", type="build") # generated + depends_on("r@2.10.0:", type=("build", "run")) depends_on("r-zoo", type=("build", "run")) depends_on("r-sandwich", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-suppdists/package.py b/var/spack/repos/builtin/packages/r-suppdists/package.py index 04368370a6d0dd..232c1a3b014a4e 100644 --- a/var/spack/repos/builtin/packages/r-suppdists/package.py +++ b/var/spack/repos/builtin/packages/r-suppdists/package.py @@ -20,4 +20,6 @@ class RSuppdists(RPackage): version("1.1-9.7", sha256="6b5527e2635c0ff762eb7af8154704c85e66d7f79a9524089a5c98dfa94dab08") version("1.1-9.5", sha256="680b67145c07d44e200275e08e48602fe19cd99fb106c05422b3f4a244c071c4") + depends_on("cxx", type="build") # generated + depends_on("r@3.3.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-sva/package.py b/var/spack/repos/builtin/packages/r-sva/package.py index 5d56201407ebda..e8a9c700ea609a 100644 --- a/var/spack/repos/builtin/packages/r-sva/package.py +++ b/var/spack/repos/builtin/packages/r-sva/package.py @@ -41,6 +41,8 @@ class RSva(RPackage): version("3.26.0", commit="3cc5e75413c35ed5511892f5c36a8b5cb454937e") version("3.24.4", commit="ed2ebb6e33374dc9ec50e6ea97cc1d9aef836c73") + depends_on("c", type="build") # generated + depends_on("r@3.2:", type=("build", "run")) depends_on("r-mgcv", type=("build", "run")) depends_on("r-genefilter", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-tfbstools/package.py b/var/spack/repos/builtin/packages/r-tfbstools/package.py index 2e73e8248c994a..cc32e0a644ef33 100644 --- a/var/spack/repos/builtin/packages/r-tfbstools/package.py +++ b/var/spack/repos/builtin/packages/r-tfbstools/package.py @@ -29,6 +29,8 @@ class RTfbstools(RPackage): version("1.16.0", commit="565436a5a674d4dea7279e796a20c5bd2034f65a") version("1.14.2", commit="e429fdefb6f7ee4585dd2a8ca3d0ced7a5bed4ff") + depends_on("c", type="build") # generated + depends_on("r@3.2.2:", type=("build", "run")) depends_on("r-biobase@2.28:", type=("build", "run")) depends_on("r-biostrings@2.36.4:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-tfmpvalue/package.py b/var/spack/repos/builtin/packages/r-tfmpvalue/package.py index c899a4a4cff30c..0f650954a41e26 100644 --- a/var/spack/repos/builtin/packages/r-tfmpvalue/package.py +++ b/var/spack/repos/builtin/packages/r-tfmpvalue/package.py @@ -22,5 +22,8 @@ class RTfmpvalue(RPackage): version("0.0.8", sha256="6d052529f7b59d0384edc097f724f70468013777b6adf4c63e61a359029d3841") version("0.0.6", sha256="cee3aa2d4e22856865d820f695e29a5f23486e5e08cd42cb95a0728f5f9522a1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.0.1:", type=("build", "run")) depends_on("r-rcpp@0.11.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-tibble/package.py b/var/spack/repos/builtin/packages/r-tibble/package.py index c01e9dfc96a4ae..a2fe8bd4433c83 100644 --- a/var/spack/repos/builtin/packages/r-tibble/package.py +++ b/var/spack/repos/builtin/packages/r-tibble/package.py @@ -31,6 +31,8 @@ class RTibble(RPackage): version("1.2", sha256="ed8a8bd0591223f742be80fd1cd8c4a9618d0f04011ec95c272b61ea45193104") version("1.1", sha256="10ea18890e5514faa4c2c05fa231a6e2bbb7689f3800850cead214306414c88e") + depends_on("c", type="build") # generated + depends_on("r@3.1.2:", type=("build", "run")) depends_on("r@3.1.0:", type=("build", "run"), when="@1.3.0:") depends_on("r@3.4.0:", type=("build", "run"), when="@3.2.1:") diff --git a/var/spack/repos/builtin/packages/r-tmvnsim/package.py b/var/spack/repos/builtin/packages/r-tmvnsim/package.py index 69cf0c88fea486..6beba71357147b 100644 --- a/var/spack/repos/builtin/packages/r-tmvnsim/package.py +++ b/var/spack/repos/builtin/packages/r-tmvnsim/package.py @@ -24,3 +24,6 @@ class RTmvnsim(RPackage): license("GPL-2.0-only") version("1.0-2", sha256="97f63d0bab3b240cc7bdbe6e6e74e90ad25a4382a345ee51a26fe3959edeba0f") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-triebeard/package.py b/var/spack/repos/builtin/packages/r-triebeard/package.py index e20dcf6e0d87dd..98590e0259db90 100644 --- a/var/spack/repos/builtin/packages/r-triebeard/package.py +++ b/var/spack/repos/builtin/packages/r-triebeard/package.py @@ -21,4 +21,6 @@ class RTriebeard(RPackage): version("0.4.1", sha256="192f2fef6341e43bd56ef4f9841e813e07be990f4ffcf38c5606259630efe0f7") version("0.3.0", sha256="bf1dd6209cea1aab24e21a85375ca473ad11c2eff400d65c6202c0fb4ef91ec3") + depends_on("cxx", type="build") # generated + depends_on("r-rcpp", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-truncnorm/package.py b/var/spack/repos/builtin/packages/r-truncnorm/package.py index 2ffcf43b654239..44d17bb4ad3614 100644 --- a/var/spack/repos/builtin/packages/r-truncnorm/package.py +++ b/var/spack/repos/builtin/packages/r-truncnorm/package.py @@ -20,5 +20,7 @@ class RTruncnorm(RPackage): version("1.0-8", sha256="49564e8d87063cf9610201fbc833859ed01935cc0581b9e21c42a0d21a47c87e") version("1.0.0", sha256="dc1b018cb6d9ad5beb2d9e2f3ebe56c3f69d7a98fc5a1d963dd7933d209ac272") + depends_on("c", type="build") # generated + depends_on("r@2.7.0:", type=("build", "run")) depends_on("r@3.4.0:", type=("build", "run"), when="@1.0-8:") diff --git a/var/spack/repos/builtin/packages/r-udunits2/package.py b/var/spack/repos/builtin/packages/r-udunits2/package.py index 22e2884e9ba1c3..be6878d2e74473 100644 --- a/var/spack/repos/builtin/packages/r-udunits2/package.py +++ b/var/spack/repos/builtin/packages/r-udunits2/package.py @@ -19,5 +19,7 @@ class RUdunits2(RPackage): version("0.13.2", sha256="ee00898801b3282717cba40a9ef930515506386aa82a050356d1a9c80a9f5969") version("0.13", sha256="d155d3c07f6202b65dec4075ffd1e1c3f4f35f5fdece8cfb319d39256a3e5b79") + depends_on("c", type="build") # generated + depends_on("r@2.10.0:", type=("build", "run")) depends_on("udunits") diff --git a/var/spack/repos/builtin/packages/r-urltools/package.py b/var/spack/repos/builtin/packages/r-urltools/package.py index 013d8555d7f4a7..9dde5976a7d7df 100644 --- a/var/spack/repos/builtin/packages/r-urltools/package.py +++ b/var/spack/repos/builtin/packages/r-urltools/package.py @@ -22,6 +22,9 @@ class RUrltools(RPackage): version("1.7.3", sha256="6020355c1b16a9e3956674e5dea9ac5c035c8eb3eb6bbdd841a2b5528cafa313") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.10:", type=("build", "run")) depends_on("r-rcpp", type=("build", "run")) depends_on("r-triebeard", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-variantannotation/package.py b/var/spack/repos/builtin/packages/r-variantannotation/package.py index 6df0be0c65a37f..6b84d24c8d8119 100644 --- a/var/spack/repos/builtin/packages/r-variantannotation/package.py +++ b/var/spack/repos/builtin/packages/r-variantannotation/package.py @@ -25,6 +25,8 @@ class RVariantannotation(RPackage): version("1.24.5", commit="468d7f53fd743e04c9af853d58e871b4cc13a090") version("1.22.3", commit="3a91b6d4297aa416d5f056dec6f8925eb1a8eaee") + depends_on("c", type="build") # generated + depends_on("r@2.8.0:", type=("build", "run")) depends_on("r@4.0.0:", type=("build", "run"), when="@1.40.0:") depends_on("r-biocgenerics@0.15.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-vctrs/package.py b/var/spack/repos/builtin/packages/r-vctrs/package.py index 49e8bf5e37c670..4e6a1e96613d21 100644 --- a/var/spack/repos/builtin/packages/r-vctrs/package.py +++ b/var/spack/repos/builtin/packages/r-vctrs/package.py @@ -18,7 +18,14 @@ class RVctrs(RPackage): license("MIT") + version("0.6.5", sha256="43167d2248fd699594044b5c8f1dbb7ed163f2d64761e08ba805b04e7ec8e402") + version("0.6.4", sha256="8a80192356e724d21bd89a0ce3e5835856fd5bb1651e7fc205c6fee58fd001c8") + version("0.6.3", sha256="93dc220dcde8b440586b2260460ef354e827a17dfec1ea6a9815585a10cfa5c2") version("0.6.2", sha256="feecabe11f6c55e04377d36fa59842187f0a6fe52aaf867c08289a948781ee84") + version("0.6.1", sha256="77552463bd7c40af2618d635de6bb9ad1614d161a5e34d90167601dc5e8e1283") + version("0.6.0", sha256="be0b712c4e6aae353120a60ded6a4301eb9631c8d256927b79b9ad83b4299757") + version("0.5.2", sha256="76bf10243b9b31e23f56ffdaa1677a01767699e2098487f86bd42cb801d8c047") + version("0.5.1", sha256="497982f717f21e7612b84940e95c282e2a96b942e6d47108f92cd92b7341db07") version("0.5.0", sha256="7c372e13c39ddace9c9bb9f33238de6dd2cd0f37dcc7054ba6435d271e5df686") version("0.4.2", sha256="5414d1d6977163b4e85efa40d6facdd98089d6ffd460daaba729d4200942d815") version("0.4.1", sha256="9676881e009aa1217818f326338e8b35dd9a9438918f8b1ac249f4c8afe460dd") @@ -27,6 +34,9 @@ class RVctrs(RPackage): version("0.3.5", sha256="11605d98106e294dae1a9b205462dd3906a6159a647150752b85dd290f6635cc") version("0.2.0", sha256="5bce8f228182ecaa51230d00ad8a018de9cf2579703e82244e0931fe31f20016") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@3.2:", type=("build", "run")) depends_on("r@3.3:", type=("build", "run"), when="@0.3.5:") depends_on("r@3.5.0:", type=("build", "run"), when="@0.6.2:") diff --git a/var/spack/repos/builtin/packages/r-vsn/package.py b/var/spack/repos/builtin/packages/r-vsn/package.py index f89be049975787..d814c3c5f82273 100644 --- a/var/spack/repos/builtin/packages/r-vsn/package.py +++ b/var/spack/repos/builtin/packages/r-vsn/package.py @@ -35,6 +35,8 @@ class RVsn(RPackage): version("3.46.0", commit="7ecfd20452348da27d6fcc052cbff2b9be777792") version("3.44.0", commit="e54513fcdd07ccfb8094359e93cef145450f0ee0") + depends_on("c", type="build") # generated + depends_on("r@3.0.0:", type=("build", "run")) depends_on("r@3.4.0:", type=("build", "run"), when="@3.46.0:") depends_on("r@4.0.0:", type=("build", "run"), when="@3.62.0:") diff --git a/var/spack/repos/builtin/packages/r-xde/package.py b/var/spack/repos/builtin/packages/r-xde/package.py index 309e099ede1f50..dc1264e2e193e4 100644 --- a/var/spack/repos/builtin/packages/r-xde/package.py +++ b/var/spack/repos/builtin/packages/r-xde/package.py @@ -26,6 +26,9 @@ class RXde(RPackage): version("2.24.0", commit="fd5f245f82893657dc36e5a67a1d3b8255772462") version("2.22.0", commit="25bcec965ae42a410dd285a9db9be46d112d8e81") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r@2.10.0:", type=("build", "run")) depends_on("r-biobase@2.5.5:", type=("build", "run")) depends_on("r-biocgenerics", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-xnomial/package.py b/var/spack/repos/builtin/packages/r-xnomial/package.py index 1d58c27b9bcbb2..60e7d84e370f59 100644 --- a/var/spack/repos/builtin/packages/r-xnomial/package.py +++ b/var/spack/repos/builtin/packages/r-xnomial/package.py @@ -26,4 +26,6 @@ class RXnomial(RPackage): version("1.0.4", sha256="e6237f79d96f02bb30af1cf055ae9f70541abba34ce045a9d4359b5304189dd7") + depends_on("c", type="build") # generated + depends_on("r@2.14:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-xvector/package.py b/var/spack/repos/builtin/packages/r-xvector/package.py index 55a3b400cc03ce..47bd682206394a 100644 --- a/var/spack/repos/builtin/packages/r-xvector/package.py +++ b/var/spack/repos/builtin/packages/r-xvector/package.py @@ -26,6 +26,8 @@ class RXvector(RPackage): version("0.18.0", commit="27acf47282c9880b54d04dff46c1e50f0c87fa6b") version("0.16.0", commit="54615888e1a559da4a81de33e934fc0f1c3ad99f") + depends_on("c", type="build") # generated + depends_on("r@2.8.0:", type=("build", "run")) depends_on("r@4.0.0:", type=("build", "run"), when="@0.34.0:") depends_on("r-biocgenerics@0.19.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r-zlibbioc/package.py b/var/spack/repos/builtin/packages/r-zlibbioc/package.py index ed618d261f4e95..c658f0baec65d7 100644 --- a/var/spack/repos/builtin/packages/r-zlibbioc/package.py +++ b/var/spack/repos/builtin/packages/r-zlibbioc/package.py @@ -26,3 +26,5 @@ class RZlibbioc(RPackage): version("1.26.0", commit="2e3ab097caa09a5e3ddaa3469b13e19a7224da0d") version("1.24.0", commit="2990059338d1b987d098c009b0bfa806bd24afec") version("1.22.0", commit="30377f830af2bc1ff17bbf3fdd2cb6442015fea5") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/r-zoo/package.py b/var/spack/repos/builtin/packages/r-zoo/package.py index 907daa0f33c38f..50e4a5b1b9cd51 100644 --- a/var/spack/repos/builtin/packages/r-zoo/package.py +++ b/var/spack/repos/builtin/packages/r-zoo/package.py @@ -30,6 +30,8 @@ class RZoo(RPackage): version("1.7-14", sha256="4858675fed056a4329c4998517cc944db386447483390bd342de719e0509f598") version("1.7-13", sha256="0ca5264d6077c785963705e462aec3e57e0d0651379f9bf4ee32e4f3b25dc754") + depends_on("c", type="build") # generated + depends_on("r@2.10.0:", type=("build", "run")) depends_on("r@3.1.0:", type=("build", "run"), when="@1.8-2:") depends_on("r-lattice@0.20-27:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/r/package.py b/var/spack/repos/builtin/packages/r/package.py index 65e6baa6b6d27d..26bbd789ecf634 100644 --- a/var/spack/repos/builtin/packages/r/package.py +++ b/var/spack/repos/builtin/packages/r/package.py @@ -16,12 +16,14 @@ class R(AutotoolsPackage): Please consult the R project homepage for further information.""" homepage = "https://www.r-project.org" - url = "https://cloud.r-project.org/src/base/R-3/R-3.4.3.tar.gz" + url = "https://cloud.r-project.org/src/base/R-4/R-4.4.0.tar.gz" extendable = True license("GPL-2.0-or-later") + version("4.4.0", sha256="ace4125f9b976d2c53bcc5fca30c75e30d4edc401584859cbadb080e72b5f030") + version("4.3.3", sha256="80851231393b85bf3877ee9e39b282e750ed864c5ec60cbd68e6e139f0520330") version("4.3.2", sha256="b3f5760ac2eee8026a3f0eefcb25b47723d978038eee8e844762094c860c452a") version("4.3.1", sha256="8dd0bf24f1023c6f618c3b317383d291b4a494f40d73b983ac22ffea99e4ba99") version("4.3.0", sha256="45dcc48b6cf27d361020f77fde1a39209e997b81402b3663ca1c010056a6a609") @@ -64,6 +66,9 @@ class R(AutotoolsPackage): version("3.1.3", sha256="07e98323935baa38079204bfb9414a029704bb9c0ca5ab317020ae521a377312") version("3.1.2", sha256="bcd150afcae0e02f6efb5f35a6ab72432be82e849ec52ce0bb89d8c342a8fa7a") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("X", default=False, description="Enable X11 support (TCLTK, PNG, JPEG, TIFF, CAIRO)") variant("memory_profiling", default=False, description="Enable memory profiling") variant("rmath", default=False, description="Build standalone Rmath library") @@ -112,6 +117,13 @@ class R(AutotoolsPackage): # gets stored as compressed byte code, which is not relocatable patch("relocate-which.patch") + # CVE-2024-27322 Patch only needed in R 4.3.3 and below; doesn't apply to R older than 3.5.0. + patch( + "https://github.com/r-devel/r-svn/commit/f7c46500f455eb4edfc3656c3fa20af61b16abb7.patch?full_index=1", + sha256="56c77763cb104aa9cb63420e585da63cb2c23bc03fa3ef9d088044eeff9d7380", + when="@3.5.0:4.3.3", + ) + build_directory = "spack-build" # R custom URL version diff --git a/var/spack/repos/builtin/packages/r3d/package.py b/var/spack/repos/builtin/packages/r3d/package.py index 63f13ec2387d5a..40f44e2afa61df 100644 --- a/var/spack/repos/builtin/packages/r3d/package.py +++ b/var/spack/repos/builtin/packages/r3d/package.py @@ -21,6 +21,9 @@ class R3d(CMakePackage): version("2018-12-19", commit="47308f68c782ed3227d3dab1eff24d41f6421f21", deprecated=True) version("2018-01-07", commit="d6799a582256a120ef3bd7e18959e96cba0e5495", deprecated=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "r3d_max_verts", default="0", diff --git a/var/spack/repos/builtin/packages/rabbitmq-c/package.py b/var/spack/repos/builtin/packages/rabbitmq-c/package.py index 3e7396a1b3b7de..7a4ca6a064c6dc 100644 --- a/var/spack/repos/builtin/packages/rabbitmq-c/package.py +++ b/var/spack/repos/builtin/packages/rabbitmq-c/package.py @@ -21,6 +21,8 @@ class RabbitmqC(CMakePackage): version("0.13.0", sha256="8b224e41bba504fc52b02f918d8df7e4bf5359d493cbbff36c06078655c676e6") version("0.11.0", sha256="437d45e0e35c18cf3e59bcfe5dfe37566547eb121e69fca64b98f5d2c1c2d424") + depends_on("c", type="build") # generated + variant("ssl", default=True, description="Required to connect to RabbitMQ using SSL/TLS") variant("shared", default=True, description="Build shared library") variant("static", default=True, description="Build static library") diff --git a/var/spack/repos/builtin/packages/racket/package.py b/var/spack/repos/builtin/packages/racket/package.py index a9cfa27dea5183..25188da281c9b0 100644 --- a/var/spack/repos/builtin/packages/racket/package.py +++ b/var/spack/repos/builtin/packages/racket/package.py @@ -17,6 +17,9 @@ class Racket(MakefilePackage): version("8.3", sha256="3b963cd29ae119e1acc2c6dc4781bd9f25027979589caaae3fdfc021aac2324b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libffi", type=("build", "link", "run")) depends_on("patchutils") depends_on("libtool", type=("build")) diff --git a/var/spack/repos/builtin/packages/racon/package.py b/var/spack/repos/builtin/packages/racon/package.py index 4ba7ec80e059d2..f2a93947d26627 100644 --- a/var/spack/repos/builtin/packages/racon/package.py +++ b/var/spack/repos/builtin/packages/racon/package.py @@ -25,6 +25,9 @@ class Racon(CMakePackage): version("1.3.0", sha256="f2331fb88eae5c54227dc16651607af6f045ae1ccccc1d117011762927d4606a") version("1.2.1", sha256="6e4b752b7cb6ab13b5e8cb9db58188cf1a3a61c4dcc565c8849bf4868b891bf8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.2:", type="build") depends_on("python", type="build") depends_on("sse2neon", when="target=aarch64:") diff --git a/var/spack/repos/builtin/packages/raft/package.py b/var/spack/repos/builtin/packages/raft/package.py index 919a555a008fae..9e9a37d84a8366 100644 --- a/var/spack/repos/builtin/packages/raft/package.py +++ b/var/spack/repos/builtin/packages/raft/package.py @@ -18,6 +18,8 @@ class Raft(CMakePackage): version("develop", branch="master") version("1.2.3", sha256="c41630e74491c8db272dcf4707e9b11cdcb226c0b7e978ca6eba8006f47bdae6") + depends_on("c", type="build") # generated + depends_on("mpi") depends_on("cmake", type="build") depends_on("hdf5") diff --git a/var/spack/repos/builtin/packages/ragel/package.py b/var/spack/repos/builtin/packages/ragel/package.py index 62d97dde140e7c..0e6029e0e291ae 100644 --- a/var/spack/repos/builtin/packages/ragel/package.py +++ b/var/spack/repos/builtin/packages/ragel/package.py @@ -24,4 +24,7 @@ class Ragel(AutotoolsPackage): version("6.10", sha256="5f156edb65d20b856d638dd9ee2dfb43285914d9aa2b6ec779dac0270cd56c3f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("colm", type="build") diff --git a/var/spack/repos/builtin/packages/raja/package.py b/var/spack/repos/builtin/packages/raja/package.py index 07428c50cea7b3..d235a618518876 100644 --- a/var/spack/repos/builtin/packages/raja/package.py +++ b/var/spack/repos/builtin/packages/raja/package.py @@ -6,33 +6,79 @@ import socket from spack.package import * -from spack.pkg.builtin.camp import hip_repair_cache + +from .blt import llnl_link_helpers + + +# Starting with 2022.03.0, the only submodule we want to fetch is tpl/desul +# since there is no package for it. Other RAJA submodules are defined as +# dependencies. +def submodules(package): + submodules = [] + submodules.append("tpl/desul") + return submodules class Raja(CachedCMakePackage, CudaPackage, ROCmPackage): """RAJA Parallel Framework.""" - homepage = "https://software.llnl.gov/RAJA/" + homepage = "https://github.com/LLNL/RAJA" git = "https://github.com/LLNL/RAJA.git" tags = ["radiuss", "e4s"] - maintainers("davidbeckingsale") + maintainers("davidbeckingsale", "adrienbernede") license("BSD-3-Clause") - version("develop", branch="develop", submodules=False) - version("main", branch="main", submodules=False) + version("develop", branch="develop", submodules=submodules) + version("main", branch="main", submodules=submodules) + version( + "2024.02.2", + tag="v2024.02.2", + commit="593f756b14ac57ded33ee61d8d2292d4beb840e6", + submodules=submodules, + ) + version( + "2024.02.1", + tag="v2024.02.1", + commit="3ada0950b0774ec907d30a9eceaf6af7478b833b", + submodules=submodules, + ) + version( + "2024.02.0", + tag="v2024.02.0", + commit="82d1b926ada0fbb15a4a6e0adadc30c715cfda7b", + submodules=submodules, + ) + version( + "2023.06.1", + tag="v2023.06.1", + commit="9b5f61edf3aa1e6fdbc9a4b30828c81504639963", + submodules=submodules, + ) + version( + "2023.06.0", + tag="v2023.06.0", + commit="e330b2560747d5417cd7bd265fab3fb91d32ecbd", + submodules=submodules, + ) + version( + "2022.10.5", + tag="v2022.10.5", + commit="3774f51339459bbbdb77055aa23f82919b6335b6", + submodules=submodules, + ) version( "2022.10.4", tag="v2022.10.4", commit="c2a6b1740759ae3ae7c85b35e20dbffbe235355d", - submodules=False, + submodules=submodules, ) version( "2022.03.0", tag="v2022.03.0", commit="4351fe6a50bd579511a625b017c9e054885e7fd2", - submodules=False, + submodules=submodules, ) version( "0.14.0", @@ -107,6 +153,8 @@ class Raja(CachedCMakePackage, CudaPackage, ROCmPackage): "0.4.0", tag="v0.4.0", commit="31b2a48192542c2da426885baa5af0ed57606b78", submodules="True" ) + depends_on("cxx", type="build") # generated + # export targets when building pre-2.4.0 release with BLT 0.4.0+ patch( "https://github.com/LLNL/RAJA/commit/eca1124ee4af380d6613adc6012c307d1fd4176b.patch?full_index=1", @@ -122,8 +170,14 @@ class Raja(CachedCMakePackage, CudaPackage, ROCmPackage): when="^hip@6.0", ) - variant("openmp", default=True, description="Build OpenMP backend") - variant("shared", default=True, description="Build Shared Libs") + variant("openmp", default=False, description="Build OpenMP backend") + variant("shared", default=False, description="Build shared libs") + variant("desul", default=False, description="Build desul atomics backend") + variant("vectorization", default=False, description="Build SIMD/SIMT intrinsics support") + variant( + "omptask", default=False, description="Build OpenMP task variants of internal algorithms" + ) + variant("plugins", default=False, description="Enable runtime plugins") variant("examples", default=True, description="Build examples.") variant("exercises", default=True, description="Build exercises.") @@ -131,24 +185,42 @@ class Raja(CachedCMakePackage, CudaPackage, ROCmPackage): # and remove the +tests conflict below. variant("tests", default=False, description="Build tests") + # we don’t use variants to express the failing test, we only add a variant to + # define whether we want to run all the tests (including those known to fail) + # or only the passing ones. + variant( + "run-all-tests", + default=False, + description="Run all the tests, including those known to fail.", + ) + depends_on("blt", type="build") + depends_on("blt@0.6.2:", type="build", when="@2024.02.1:") + depends_on("blt@0.6.1:", type="build", when="@2024.02.0:") + depends_on("blt@0.5.3", type="build", when="@2023.06.0:2023.06.1") + depends_on("blt@0.5.2:0.5.3", type="build", when="@2022.10.5") depends_on("blt@0.5.0:0.5.3", type="build", when="@0.14.1:2022.10.4") depends_on("blt@0.4.1", type="build", when="@0.14.0") - depends_on("blt@0.4.0:", type="build", when="@0.13.0") - depends_on("blt@0.3.6:", type="build", when="@:0.12.0") + depends_on("blt@0.4.0:0.4.1", type="build", when="@0.13.0") + depends_on("blt@0.3.6:0.4.1", type="build", when="@:0.12.0") conflicts("^blt@:0.3.6", when="+rocm") + depends_on("camp+openmp", when="+openmp") + depends_on("camp@main", when="@develop") + depends_on("camp@main", when="@main") + depends_on("camp@2024.02.1:", type="build", when="@2024.02.1:") + depends_on("camp@2024.02.0:", type="build", when="@2024.02.0:") + depends_on("camp@2023.06.0", type="build", when="@2023.06.0:2023.06.1") + depends_on("camp@2022.10.1:2023.06.0", type="build", when="@2022.10.3:2022.10.5") + depends_on("camp@2022.10.0:2023.06.0", type="build", when="@2022.10.0:2022.10.2") + depends_on("camp@2022.03.2", type="build", when="@2022.03.0:2022.03.1") depends_on("camp@0.2.2:0.2.3", when="@0.14.0") depends_on("camp@0.1.0", when="@0.10.0:0.13.0") - depends_on("camp@2022.03.2:2022.03", when="@2022.03.0:2022.03") - depends_on("camp@2022.10:", when="@2022.10:") - depends_on("camp@main", when="@main") - depends_on("camp@main", when="@develop") - depends_on("camp+openmp", when="+openmp") - depends_on("cmake@:3.20", when="@:2022.03+rocm", type="build") - depends_on("cmake@3.23:", when="@2022.10:+rocm", type="build") + depends_on("cmake@3.23:", when="@2022.10.0:+rocm", type="build") + depends_on("cmake@3.20:", when="@2022.10.0:", type="build") depends_on("cmake@3.14:", when="@2022.03.0:", type="build") + depends_on("cmake@:3.20", when="@:2022.03+rocm", type="build") depends_on("llvm-openmp", when="+openmp %apple-clang") @@ -159,7 +231,7 @@ class Raja(CachedCMakePackage, CudaPackage, ROCmPackage): depends_on( "camp+rocm amdgpu_target={0}".format(arch), when="amdgpu_target={0}".format(arch) ) - conflicts("+openmp") + conflicts("+openmp", when="@:2022.03") with when("+cuda @0.12.0:"): depends_on("camp+cuda") @@ -182,49 +254,47 @@ def cache_name(self): hostname = socket.gethostname() if "SYS_TYPE" in env: hostname = hostname.rstrip("1234567890") - return "{0}-{1}-{2}@{3}.cmake".format( + return "{0}-{1}-{2}@{3}-{4}.cmake".format( hostname, self._get_sys_type(self.spec), self.spec.compiler.name, self.spec.compiler.version, + self.spec.dag_hash(8), ) def initconfig_compiler_entries(self): spec = self.spec + compiler = self.compiler + # Default entries are already defined in CachedCMakePackage, inherit them: entries = super().initconfig_compiler_entries() + if "+rocm" in spec: entries.insert(0, cmake_cache_path("CMAKE_CXX_COMPILER", spec["hip"].hipcc)) + + llnl_link_helpers(entries, spec, compiler) + return entries def initconfig_hardware_entries(self): spec = self.spec entries = super().initconfig_hardware_entries() + entries.append("#------------------{0}".format("-" * 30)) + entries.append("# Package custom hardware settings") + entries.append("#------------------{0}\n".format("-" * 30)) + entries.append(cmake_cache_option("ENABLE_OPENMP", "+openmp" in spec)) if "+cuda" in spec: entries.append(cmake_cache_option("ENABLE_CUDA", True)) - - if not spec.satisfies("cuda_arch=none"): - cuda_arch = spec.variants["cuda_arch"].value - entries.append(cmake_cache_string("CUDA_ARCH", "sm_{0}".format(cuda_arch[0]))) - entries.append( - cmake_cache_string("CMAKE_CUDA_ARCHITECTURES", "{0}".format(cuda_arch[0])) - ) else: entries.append(cmake_cache_option("ENABLE_CUDA", False)) if "+rocm" in spec: entries.append(cmake_cache_option("ENABLE_HIP", True)) - entries.append(cmake_cache_path("HIP_ROOT_DIR", "{0}".format(spec["hip"].prefix))) - hip_repair_cache(entries, spec) hipcc_flags = [] - if self.spec.satisfies("@0.14.0"): + if self.spec.satisfies("@0.14.0:"): hipcc_flags.append("-std=c++14") - archs = self.spec.variants["amdgpu_target"].value - if archs != "none": - arch_str = ",".join(archs) - hipcc_flags.append("--amdgpu-target={0}".format(arch_str)) entries.append(cmake_cache_string("HIP_HIPCC_FLAGS", " ".join(hipcc_flags))) else: entries.append(cmake_cache_option("ENABLE_HIP", False)) @@ -237,11 +307,39 @@ def initconfig_package_entries(self): option_prefix = "RAJA_" if spec.satisfies("@0.14.0:") else "" + # TPL locations + entries.append("#------------------{0}".format("-" * 60)) + entries.append("# TPLs") + entries.append("#------------------{0}\n".format("-" * 60)) + entries.append(cmake_cache_path("BLT_SOURCE_DIR", spec["blt"].prefix)) if "camp" in self.spec: entries.append(cmake_cache_path("camp_DIR", spec["camp"].prefix)) + + # Build options + entries.append("#------------------{0}".format("-" * 60)) + entries.append("# Build Options") + entries.append("#------------------{0}\n".format("-" * 60)) + + entries.append(cmake_cache_string("CMAKE_BUILD_TYPE", spec.variants["build_type"].value)) entries.append(cmake_cache_option("BUILD_SHARED_LIBS", "+shared" in spec)) + + entries.append(cmake_cache_option("RAJA_ENABLE_DESUL_ATOMICS", "+desul" in spec)) + + entries.append(cmake_cache_option("RAJA_ENABLE_VECTORIZATION", "+vectorization" in spec)) + + entries.append(cmake_cache_option("RAJA_ENABLE_OPENMP_TASK", "+omptask" in spec)) + + # C++14 + if spec.satisfies("@0.14.0:"): + entries.append(cmake_cache_string("BLT_CXX_STD", "c++14")) + + if "+desul" in spec: + if "+cuda" in spec: + entries.append(cmake_cache_string("CMAKE_CUDA_STANDARD", "14")) + entries.append(cmake_cache_option("RAJA_ENABLE_RUNTIME_PLUGINS", "+plugins" in spec)) + entries.append( cmake_cache_option("{}ENABLE_EXAMPLES".format(option_prefix), "+examples" in spec) ) @@ -254,19 +352,50 @@ def initconfig_package_entries(self): else: entries.append(cmake_cache_option("ENABLE_EXERCISES", "+exercises" in spec)) + # TODO: Treat the workaround when building tests with spack wrapper + # For now, removing it to test CI, which builds tests outside of wrapper. # Work around spack adding -march=ppc64le to SPACK_TARGET_ARGS which # is used by the spack compiler wrapper. This can go away when BLT # removes -Werror from GTest flags - if self.spec.satisfies("%clang target=ppc64le:") or not self.run_tests: + # + # if self.spec.satisfies("%clang target=ppc64le:") + # or (not self.run_tests and "+tests" not in spec): + if not self.run_tests and "+tests" not in spec: entries.append(cmake_cache_option("ENABLE_TESTS", False)) else: entries.append(cmake_cache_option("ENABLE_TESTS", True)) + if "+run-all-tests" not in spec: + if spec.satisfies("%clang@12.0.0:13.9.999"): + entries.append( + cmake_cache_string( + "CTEST_CUSTOM_TESTS_IGNORE", + "test-algorithm-sort-OpenMP.exe;test-algorithm-stable-sort-OpenMP.exe", + ) + ) + excluded_tests = [ + "test-algorithm-sort-Cuda.exe", + "test-algorithm-stable-sort-Cuda.exe", + "test-algorithm-sort-OpenMP.exe", + "test-algorithm-stable-sort-OpenMP.exe", + ] + if spec.satisfies("+cuda %clang@12.0.0:13.9.999"): + entries.append( + cmake_cache_string("CTEST_CUSTOM_TESTS_IGNORE", ";".join(excluded_tests)) + ) + if spec.satisfies("+cuda %xl@16.1.1.12"): + entries.append( + cmake_cache_string( + "CTEST_CUSTOM_TESTS_IGNORE", + "test-algorithm-sort-Cuda.exe;test-algorithm-stable-sort-Cuda.exe", + ) + ) + + entries.append(cmake_cache_option("RAJA_HOST_CONFIG_LOADED", True)) return entries def cmake_args(self): - options = [] - return options + return [] @property def build_relpath(self): diff --git a/var/spack/repos/builtin/packages/ramulator/package.py b/var/spack/repos/builtin/packages/ramulator/package.py index 724a26fc27a3d6..dcb9c6ff6f7a1d 100644 --- a/var/spack/repos/builtin/packages/ramulator/package.py +++ b/var/spack/repos/builtin/packages/ramulator/package.py @@ -21,6 +21,8 @@ class Ramulator(MakefilePackage): version("sst", commit="7d2e72306c6079768e11a1867eb67b60cee34a1c") + depends_on("cxx", type="build") # generated + patch("ramulator_sha_7d2e723_gcc48Patch.patch", when="@sst") patch("ramulator_sha_7d2e723_libPatch.patch", when="@sst") diff --git a/var/spack/repos/builtin/packages/randfold/package.py b/var/spack/repos/builtin/packages/randfold/package.py index ae2dbac959f237..a4c70f5ed4ec12 100644 --- a/var/spack/repos/builtin/packages/randfold/package.py +++ b/var/spack/repos/builtin/packages/randfold/package.py @@ -16,6 +16,8 @@ class Randfold(MakefilePackage): version("2.0.1", sha256="b286145deb9ac6197062d98e209da095f00c45a5a615616bcf2b2a6609ed113f") + depends_on("c", type="build") # generated + depends_on("squid") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/random123/package.py b/var/spack/repos/builtin/packages/random123/package.py index efc681f98c1204..efcd5e9b87ca4d 100644 --- a/var/spack/repos/builtin/packages/random123/package.py +++ b/var/spack/repos/builtin/packages/random123/package.py @@ -33,6 +33,9 @@ class Random123(Package): url="https://www.deshawresearch.com/downloads/download_random123.cgi/Random123-1.09.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("ibmxl.patch", when="@1.09") patch("arm-gcc.patch", when="@1.09") patch("v1132-xl161.patch", when="@1.13.2") diff --git a/var/spack/repos/builtin/packages/range-v3/package.py b/var/spack/repos/builtin/packages/range-v3/package.py index 40227261c0fe06..feed5f0cfc64a9 100644 --- a/var/spack/repos/builtin/packages/range-v3/package.py +++ b/var/spack/repos/builtin/packages/range-v3/package.py @@ -24,6 +24,7 @@ class RangeV3(CMakePackage): license("BSL-1.0") version("master", branch="master") + version("0.12.0", sha256="015adb2300a98edfceaf0725beec3337f542af4915cec4d0b89fa0886f4ba9cb") version("0.11.0", sha256="376376615dbba43d3bef75aa590931431ecb49eb36d07bb726a19f680c75e20c") version("0.10.0", sha256="5a1cd44e7315d0e8dcb1eee4df6802221456a9d1dbeac53da02ac7bd4ea150cd") version("0.5.0", sha256="32e30b3be042246030f31d40394115b751431d9d2b4e0f6d58834b2fd5594280") @@ -40,6 +41,8 @@ class RangeV3(CMakePackage): version("0.2.1", sha256="25d5e3dad8052d668873e960bd78f068bebfba3bd28a278f805ea386f9438790") version("0.2.0", sha256="49b1a62a7a36dab582521c8034d8e736a8922af664d007c1529d3162b1294331") + depends_on("cxx", type="build") # generated + # Note that as of 0.3.6 range is a header-only library so it is not # necessary to match standards with packages using this # one. Eventually range-v3 will be obsoleted by the C++ standard. diff --git a/var/spack/repos/builtin/packages/rankstr/package.py b/var/spack/repos/builtin/packages/rankstr/package.py index 899e8ed1c3a1dc..f9df699bcf1700 100644 --- a/var/spack/repos/builtin/packages/rankstr/package.py +++ b/var/spack/repos/builtin/packages/rankstr/package.py @@ -25,6 +25,8 @@ class Rankstr(CMakePackage): version("0.0.3", sha256="d32052fbecd44299e13e69bf2dd7e5737c346404ccd784b8c2100ceed99d8cd3") version("0.0.2", sha256="b88357bf88cdda9565472543225d6b0fa50f0726f6e2d464c92d31a98b493abb") + depends_on("c", type="build") # generated + depends_on("mpi") variant("shared", default=True, description="Build with shared libraries") @@ -36,8 +38,5 @@ def cmake_args(self): if spec.satisfies("@0.1.0:"): args.append(self.define_from_variant("BUILD_SHARED_LIBS", "shared")) - else: - if spec.satisfies("platform=cray"): - args.append(self.define("RANKSTR_LINK_STATIC", True)) return args diff --git a/var/spack/repos/builtin/packages/rapidjson/package.py b/var/spack/repos/builtin/packages/rapidjson/package.py index fdd0b7f903ac68..a60a8525e1bab1 100644 --- a/var/spack/repos/builtin/packages/rapidjson/package.py +++ b/var/spack/repos/builtin/packages/rapidjson/package.py @@ -22,6 +22,8 @@ class Rapidjson(CMakePackage): version("1.0.1", sha256="a9003ad5c6384896ed4fd1f4a42af108e88e1b582261766df32d717ba744ee73") version("1.0.0", sha256="4189b32b9c285f34b37ffe4c0fd5627c1e59c2444daacffe5a96fdfbf08d139b") + depends_on("cxx", type="build") # generated + variant("doc", default=False, description="Build and install documentation") depends_on("doxygen+graphviz", when="+doc") diff --git a/var/spack/repos/builtin/packages/raptor2/package.py b/var/spack/repos/builtin/packages/raptor2/package.py index 5c9bf22a4610fd..d792938853e757 100644 --- a/var/spack/repos/builtin/packages/raptor2/package.py +++ b/var/spack/repos/builtin/packages/raptor2/package.py @@ -14,6 +14,9 @@ class Raptor2(AutotoolsPackage): license("LGPL-2.1-or-later") + version("2.0.16", sha256="089db78d7ac982354bdbf39d973baf09581e6904ac4c92a98c5caadb3de44680") version("2.0.15", sha256="ada7f0ba54787b33485d090d3d2680533520cd4426d2f7fb4782dd4a6a1480ed") + depends_on("c", type="build") # generated + depends_on("libxml2") diff --git a/var/spack/repos/builtin/packages/rarpd/package.py b/var/spack/repos/builtin/packages/rarpd/package.py index c9eb493031807c..2ab4f945375e7b 100644 --- a/var/spack/repos/builtin/packages/rarpd/package.py +++ b/var/spack/repos/builtin/packages/rarpd/package.py @@ -23,6 +23,8 @@ class Rarpd(MakefilePackage): "0.981107-fixes", sha256="92b44adc4a061dcedeb01f7e1c1700374199cccceef1a798de97303d387bb4c2" ) + depends_on("c", type="build") # generated + @property def install_targets(self): return ["PREFIX={0}".format(self.prefix), "install"] diff --git a/var/spack/repos/builtin/packages/rasdaemon/package.py b/var/spack/repos/builtin/packages/rasdaemon/package.py index 4d3a07af0a9614..8f488e5833673a 100644 --- a/var/spack/repos/builtin/packages/rasdaemon/package.py +++ b/var/spack/repos/builtin/packages/rasdaemon/package.py @@ -23,6 +23,8 @@ class Rasdaemon(AutotoolsPackage): version("0.6.5", sha256="1d85580778a0b7c0587b42e24dfe6c02f4c07c6ca9bbb80737d50b58ac830c92") version("0.6.4", sha256="c70e2dae1e15af496873b9e5a4d89847759fffd6cbf5ed1d74d28cd250c0771b") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/rasqal/package.py b/var/spack/repos/builtin/packages/rasqal/package.py index bce50a0341670e..417412704e4148 100644 --- a/var/spack/repos/builtin/packages/rasqal/package.py +++ b/var/spack/repos/builtin/packages/rasqal/package.py @@ -21,4 +21,6 @@ class Rasqal(AutotoolsPackage): version("0.9.32", sha256="eeba03218e3b7dfa033934d523a1a64671a9a0f64eadc38a01e4b43367be2e8f") version("0.9.31", sha256="28d743c9f1b0e5b0486ae4a945fa1e021c8495707e7adbfa0e232244b28b7fee") + depends_on("c", type="build") # generated + depends_on("raptor2") diff --git a/var/spack/repos/builtin/packages/ratel/package.py b/var/spack/repos/builtin/packages/ratel/package.py index 34b2a6c08b6f54..5de9d55acf512f 100644 --- a/var/spack/repos/builtin/packages/ratel/package.py +++ b/var/spack/repos/builtin/packages/ratel/package.py @@ -21,6 +21,8 @@ class Ratel(MakefilePackage, CudaPackage, ROCmPackage): version("0.2.1", tag="v0.2.1", commit="043b61696a2407205fdfd898681467d1a7ff59e0") version("0.1.2", tag="v0.1.2", commit="94ad630bf897d231af7a94bf08257f6067258aae") + depends_on("c", type="build") # generated + # development version depends_on("libceed@develop", when="@develop") depends_on("petsc@main", when="@develop") diff --git a/var/spack/repos/builtin/packages/ravel/package.py b/var/spack/repos/builtin/packages/ravel/package.py index accaf42d88a666..c952b9d71f2e2a 100644 --- a/var/spack/repos/builtin/packages/ravel/package.py +++ b/var/spack/repos/builtin/packages/ravel/package.py @@ -14,6 +14,8 @@ class Ravel(CMakePackage): url = "https://github.com/llnl/ravel/archive/v1.0.0.tar.gz" version("1.0.0", sha256="e1e1ac6d70c9aae915623d81a8f1258488fd26f880612fe21f2e032827aa93eb") + + depends_on("cxx", type="build") # generated # See https://github.com/LLNL/ravel/pull/18 patch("qpainterpath.patch") diff --git a/var/spack/repos/builtin/packages/raxml-ng/package.py b/var/spack/repos/builtin/packages/raxml-ng/package.py index 4564eaca280fa6..6f33e5f56b5667 100644 --- a/var/spack/repos/builtin/packages/raxml-ng/package.py +++ b/var/spack/repos/builtin/packages/raxml-ng/package.py @@ -27,6 +27,9 @@ class RaxmlNg(CMakePackage): version("1.0.2", submodules=True) version("1.0.1", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Use MPI") depends_on("bison") diff --git a/var/spack/repos/builtin/packages/raxml/package.py b/var/spack/repos/builtin/packages/raxml/package.py index ee3669cf3dde86..4691a5c496acb3 100644 --- a/var/spack/repos/builtin/packages/raxml/package.py +++ b/var/spack/repos/builtin/packages/raxml/package.py @@ -21,6 +21,8 @@ class Raxml(Package): version("8.2.12", sha256="338f81b52b54e16090e193daf36c1d4baa9b902705cfdc7f4497e3e09718533b") version("8.2.11", sha256="08cda74bf61b90eb09c229e39b1121c6d95caf182708e8745bd69d02848574d7") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Enable MPI parallel support") variant("pthreads", default=False, description="Enable pthreads version") diff --git a/var/spack/repos/builtin/packages/ray/package.py b/var/spack/repos/builtin/packages/ray/package.py index bc75c8a9380f21..593457182a3473 100644 --- a/var/spack/repos/builtin/packages/ray/package.py +++ b/var/spack/repos/builtin/packages/ray/package.py @@ -16,6 +16,8 @@ class Ray(CMakePackage, SourceforgePackage): version("2.3.1", sha256="3122edcdf97272af3014f959eab9a0f0e5a02c8ffc897d842b06b06ccd748036") + depends_on("cxx", type="build") # generated + depends_on("mpi") @run_after("build") diff --git a/var/spack/repos/builtin/packages/rayleigh/package.py b/var/spack/repos/builtin/packages/rayleigh/package.py new file mode 100644 index 00000000000000..df8d46e6158947 --- /dev/null +++ b/var/spack/repos/builtin/packages/rayleigh/package.py @@ -0,0 +1,75 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + + +class Rayleigh(MakefilePackage): + """Rayleigh is a 3-D convection code designed for the study of + dynamo behavior in spherical geometry.""" + + homepage = "https://github.com/geodynamics/Rayleigh" + url = "https://github.com/geodynamics/Rayleigh/archive/refs/tags/v1.0.1.tar.gz" + git = "https://github.com/geodynamics/Rayleigh.git" + + maintainers("tukss") + + version("main", branch="main") + version("1.2.0", sha256="e90acf18d47f6066fa68fd7b16c70ad9781a00be9e97467e9a388773e21e9e09") + version("1.1.0", sha256="93fbbdbde6088807638e4dcbd4d622203fd4753c1831bab2cb8eaeca5cba45c3") + version("1.0.1", sha256="9c9e3b0b180f32a889f158e2ea2967f4ac2bb2124f5d264f230efb8c8f19ea36") + version("1.0.0", sha256="4f2e8249256adff8c4b0bc377ceacf8a6441dcee54b7d36c784f05a454dc6dcf") + version("0.9.1", sha256="ab96445fc61822fe2d2cba8729a85b36de6b541febf5759de6d614847844573f") + version("0.9.0", sha256="63a80d1619cb639f3cb01ab82a441b77d736eee94469c47c50ab740fa81c08f4") + + depends_on("c", type="build") + depends_on("fortran", type="build") + + depends_on("mpi") + depends_on("fftw-api@3") + depends_on("lapack") + + def setup_build_environment(self, env): + spec = self.spec + if spec.satisfies("^cray-mpich"): + # The Cray wrapper takes care of linking MPI correctly for all compilers. + env.set("FC", "ftn") + else: + env.set("FC", spec["mpi"].mpifc) + + def edit(self, spec, prefix): + # Note that Rayleigh's configure script is a handcrafted file that is not generated + # by autotools. This is why we use MakefilePackage and call it manually. + # We pass in /dev/null as input to prevent interactive questions in configure. + configure("--prefix={}".format(prefix), *self.configure_args(), **{"input": os.devnull}) + + def configure_args(self): + spec = self.spec + args = [] + if spec.satisfies("^mkl"): + args.append("--with-mkl={}".format(spec["mkl"].prefix)) + else: + if not spec.satisfies("^cray-fftw"): + args.append("--with-fftw={}".format(spec["fftw"].prefix)) + + if spec.satisfies("^openblas"): + args.append("--openblas") + elif not spec.satisfies("^cray-libsci"): + args.append("--with-lapack={}".format(spec["lapack"].prefix)) + args.append("--with-blas={}".format(spec["blas"].prefix)) + else: + # Cray options are handled through modules and the compiler wrapper. + args.append("--LIBFLAGS=") + args.append("--INCLUDE=") + + args.append("--FFLAGS_DBG=-O0 -g") + args.append( + "--FFLAGS_OPT=-O3 {}".format( + spec.target.optimization_flags(spec.compiler.name, str(spec.compiler.version)) + ) + ) + return args diff --git a/var/spack/repos/builtin/packages/raylib/package.py b/var/spack/repos/builtin/packages/raylib/package.py index 3c1543676b3427..e7bfd6fc37914e 100644 --- a/var/spack/repos/builtin/packages/raylib/package.py +++ b/var/spack/repos/builtin/packages/raylib/package.py @@ -19,6 +19,8 @@ class Raylib(CMakePackage): version("5.0", sha256="98f049b9ea2a9c40a14e4e543eeea1a7ec3090ebdcd329c4ca2cf98bc9793482") + depends_on("c", type="build") # generated + # The package includes an llvm variant, which is disabled by default to simplify the build. # If enabled, allows Mesa to utilize software-based OpenGL rendering on systems without a GPU. variant("llvm", default=False, description="Enables LLVM support in Mesa") diff --git a/var/spack/repos/builtin/packages/rccl-tests/package.py b/var/spack/repos/builtin/packages/rccl-tests/package.py index a27bebac07bffc..2dc5378ba75767 100644 --- a/var/spack/repos/builtin/packages/rccl-tests/package.py +++ b/var/spack/repos/builtin/packages/rccl-tests/package.py @@ -22,6 +22,8 @@ class RcclTests(MakefilePackage): version("develop", branch="develop", preferred=True) version("master", branch="master") + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="with MPI support") depends_on("hip") diff --git a/var/spack/repos/builtin/packages/rccl/0002-Fix-numactl-rocm-smi-path-issue.patch b/var/spack/repos/builtin/packages/rccl/0002-Fix-numactl-rocm-smi-path-issue.patch deleted file mode 100644 index 30c8b92a68d2e8..00000000000000 --- a/var/spack/repos/builtin/packages/rccl/0002-Fix-numactl-rocm-smi-path-issue.patch +++ /dev/null @@ -1,24 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 1deb1ba..f2bbf30 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -117,6 +117,8 @@ include_directories(src) - include_directories(src/include) - include_directories(src/collectives) - include_directories(src/collectives/device) -+include_directories(${NUMACTL_DIR}/include) -+link_directories(${NUMACTL_DIR}/lib) - - set(CU_SOURCES - src/collectives/device/all_reduce.cu -@@ -241,8 +243,8 @@ if("${HIP_COMPILER}" MATCHES "hcc") - endif() - endif() - --target_include_directories(rccl PRIVATE ${ROCM_PATH}/rocm_smi/include) --target_link_libraries(rccl PRIVATE hip::device dl -lrocm_smi64 -L${ROCM_PATH}/rocm_smi/lib) -+target_include_directories(rccl PRIVATE ${ROCM_SMI_DIR}/include) -+target_link_libraries(rccl PRIVATE hip::device dl -lrocm_smi64 -L${ROCM_SMI_DIR}/lib) - target_link_libraries(rccl INTERFACE hip::host) - - #Setup librccl.so version diff --git a/var/spack/repos/builtin/packages/rccl/package.py b/var/spack/repos/builtin/packages/rccl/package.py index 49f78b500351fe..9b886e264107d4 100644 --- a/var/spack/repos/builtin/packages/rccl/package.py +++ b/var/spack/repos/builtin/packages/rccl/package.py @@ -16,11 +16,14 @@ class Rccl(CMakePackage): homepage = "https://github.com/ROCm/rccl" git = "https://github.com/ROCm/rccl.git" - url = "https://github.com/ROCm/rccl/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rccl/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") libraries = ["librccl"] + version("6.1.2", sha256="98af99c12d800f5439c7740d797162c35810a25e08e3b11b397d3300d3c0148e") + version("6.1.1", sha256="6368275059ba190d554535d5aeaa5c2510d944b56efd85c90a1701d0292a14c5") + version("6.1.0", sha256="c6308f6883cbd63dceadbe4ee154cc6fa9e6bdccbd2f0fda295b564b0cf01e9a") version("6.0.2", sha256="5c8495acba3d620b751e729d1157e7b4eea8f5e5692c50ce47c5204d3dfd443c") version("6.0.0", sha256="0496d5a5f2e48c92cd390ab318df31a53cf7ec590988c2574c9f3d99c38b0fa7") version("5.7.1", sha256="fb4c1f0084196d1226ce8a726d0f012d3890b54508a06ca87bbda619be8b90b1") @@ -29,16 +32,14 @@ class Rccl(CMakePackage): version("5.6.0", sha256="cce13c8a9e233e7ddf91a67b1626b7aaeaf818fefe61af8de6b6b6ff47cb358c") version("5.5.1", sha256="f6b9dc6dafeb49d95c085825876b09317d8252771c746ccf5aa19a9204a404b2") version("5.5.0", sha256="be2964b408741d046bcd606d339a233d1d1deac7b841647ec53d6d62d71452ba") - version("5.4.3", sha256="a2524f602bd7b3b6afeb8ba9aff660216ee807fa836e46442d068b5ed5f51a4d") - version("5.4.0", sha256="213f4f3d75389be588673e43f563e5c0d6908798228b0b6a71f27138fd4ed0c7") - version("5.3.3", sha256="8995a2d010ad0748fc85ac06e8da7e8d110ba996db04d42b77526c9c059c05bb") - version("5.3.0", sha256="51da5099fa58c2be882319cebe9ceabe2062feebcc0c5849e8c109030882c10a") with default_args(deprecated=True): - version("5.2.3", sha256="ecba09f4c95b4b2dae81b88231a972ac956d29909b5e712e21cf2a74bd251ff4") - version("5.2.1", sha256="cfd17dc003f19900e44928d81111570d3720d4905321f2a18c909909c4bee822") - version("5.2.0", sha256="6ee3a04da0d16eb53f768a088633a7d8ecc4416a2d0c07f7ba8426ab7892b060") - version("5.1.3", sha256="56491257f27b48bf85f4b91434a2a6e49a448337c889db181b02c8a4a260a4bc") - version("5.1.0", sha256="02b0180857e615326f9cab775573436b9162899ad8e526830f54392b8a51b1f5") + version("5.4.3", sha256="a2524f602bd7b3b6afeb8ba9aff660216ee807fa836e46442d068b5ed5f51a4d") + version("5.4.0", sha256="213f4f3d75389be588673e43f563e5c0d6908798228b0b6a71f27138fd4ed0c7") + version("5.3.3", sha256="8995a2d010ad0748fc85ac06e8da7e8d110ba996db04d42b77526c9c059c05bb") + version("5.3.0", sha256="51da5099fa58c2be882319cebe9ceabe2062feebcc0c5849e8c109030882c10a") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated amdgpu_targets = ROCmPackage.amdgpu_targets @@ -49,7 +50,6 @@ class Rccl(CMakePackage): sticky=True, ) - patch("0002-Fix-numactl-rocm-smi-path-issue.patch", when="@:5.2.1") patch("0003-Fix-numactl-rocm-smi-path-issue.patch", when="@5.2.3:5.6") patch("0004-Set-rocm-core-path-for-version-file.patch", when="@6.0:") @@ -58,11 +58,6 @@ class Rccl(CMakePackage): depends_on("numactl@2:") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -75,22 +70,17 @@ class Rccl(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"comgr@{ver}", when=f"@{ver}") depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") + depends_on(f"rocm-smi-lib@{ver}", when=f"@{ver}") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", - "5.3.0", - "5.3.3", - "5.4.0", - "5.4.3", "5.5.0", "5.5.1", "5.6.0", @@ -99,10 +89,9 @@ class Rccl(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.2", ]: - depends_on(f"rocm-smi-lib@{ver}", when=f"@{ver}") - - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") depends_on("googletest@1.11.0:", when="@5.3:") @@ -138,9 +127,7 @@ def cmake_args(self): return args def test(self): - if self.spec.satisfies("@:5.3.0"): - print("Skipping: stand-alone tests") - return test_dir = join_path(self.spec["rccl"].prefix, "bin") with working_dir(test_dir, create=True): - self.run_test("UnitTests") + exe = Executable("rccl-UnitTests") + exe() diff --git a/var/spack/repos/builtin/packages/rclone/package.py b/var/spack/repos/builtin/packages/rclone/package.py index 2582cf1327bad0..005e2ebbfb07f0 100644 --- a/var/spack/repos/builtin/packages/rclone/package.py +++ b/var/spack/repos/builtin/packages/rclone/package.py @@ -17,6 +17,7 @@ class Rclone(Package): license("MIT") + version("1.65.2", sha256="1305c913ac3684d02ce2bade0a23a2115c1ec03c9447d1562bb6cd9fa2573412") version("1.65.1", sha256="904b906cc465dd679a00487497e3891d33fca6b6e25c184400bccfb248344f39") version("1.65.0", sha256="45ec732d50b2517dc2c860317a3bf79867634a8143e4a441a3e399434ad6c141") version("1.64.2", sha256="0c74d8fb887691e04e865e3b6bc32e8af47c3e54a9922ffdbed38c8323e281c9") @@ -38,6 +39,8 @@ class Rclone(Package): version("1.55.1", sha256="25da7fc5c9269b3897f27b0d946919df595c6dda1b127085fda0fe32aa59d29d") version("1.55.0", sha256="75accdaedad3b82edc185dc8824a19a59c30dc6392de7074b6cd98d1dc2c9040") + depends_on("c", type="build") # generated + depends_on("go@1.14:", type="build") depends_on("go@1.17:", type="build", when="@1.58.0:") depends_on("go@1.18:", type="build", when="@1.62.0:") diff --git a/var/spack/repos/builtin/packages/rdc/package.py b/var/spack/repos/builtin/packages/rdc/package.py index 4df742f634b7cd..57deb2529d6135 100644 --- a/var/spack/repos/builtin/packages/rdc/package.py +++ b/var/spack/repos/builtin/packages/rdc/package.py @@ -13,7 +13,7 @@ class Rdc(CMakePackage): """ROCm Data Center Tool""" homepage = "https://github.com/ROCm/rdc" - url = "https://github.com/ROCm/rdc/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rdc/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") @@ -27,7 +27,9 @@ def url_for_version(self, version): return url.format(version) license("MIT") - + version("6.1.2", sha256="5553b76d4c8b6381d236197613720587377d03d4fd43a5a20bb6a716d49f7dfc") + version("6.1.1", sha256="c133ebd20bf42e543d13c5b84ea420a7f7c069c77b1d6dcae9680de924e5f539") + version("6.1.0", sha256="a8ad5d880645c9e95c9c90b0c9026627b22467e3e879525fff38ccd924f36c39") version("6.0.2", sha256="00defa3b68c340d7f46b8cb06b37ab0602a7949bfddc884b01c163a1526502f8") version("6.0.0", sha256="5e3847a919d5f7efe99d8d76c96e78401659eccd1fb234b1b8cb4304096d6e89") version("5.7.1", sha256="5251eb3085f2019246b332e9552dfae1572cf64ddf58306b81cbe7108019ffee") @@ -36,30 +38,23 @@ def url_for_version(self, version): version("5.6.0", sha256="5213cd89215463862f6a1e9480ebe017944a6bb6b0db1722628afaa34af57991") version("5.5.1", sha256="a58a319ee702cf61cf71a4eba647c231392f68449b35419d941079c6de944844") version("5.5.0", sha256="56e85e77581963fbcfcc43e091a91773de470152347808ae730bcaf92c9f5ee8") - version("5.4.3", sha256="c44f0b070b5650bc78e2eb968aae57a8ac1e1fd160e897055b79f3026c4fbad3") - version("5.4.0", sha256="268aab43e31045443b08a21aee8750da4cf04750c6f419ec171ec704d377a4e4") - version("5.3.3", sha256="1bf1a02f305e3a629801e62584116a34eafbd1b26627837a2a8c10550fcf611b") - version("5.3.0", sha256="ce9c85dad8e0c0b21e8e5938bf16f86a62dc5f6ded5f453c61acd43666634d6b") with default_args(deprecated=True): - version("5.2.3", sha256="5ba060449bbf5e84979cb4c62eb1dac9b0e3eca45e930d2e20e7beaa87361b39") - version("5.2.1", sha256="84b3c3754b8c9732ee6d00d37881591d3d6876feb8f29746d9eb18faea7ad035") - version("5.2.0", sha256="2f35f74485e783f56ea724a7c69ce825f181fcdbe89de453d97ce6a3d3176ae0") - version("5.1.3", sha256="ac3e594d7b245c787d6d9b63f551ca898d4d9403fbec0e4502f9970575e031b8") - version("5.1.0", sha256="3cf58cb07ef241b3b73b23af83b6477194884feba642584a491e67deeceff038") + version("5.4.3", sha256="c44f0b070b5650bc78e2eb968aae57a8ac1e1fd160e897055b79f3026c4fbad3") + version("5.4.0", sha256="268aab43e31045443b08a21aee8750da4cf04750c6f419ec171ec704d377a4e4") + version("5.3.3", sha256="1bf1a02f305e3a629801e62584116a34eafbd1b26627837a2a8c10550fcf611b") + version("5.3.0", sha256="ce9c85dad8e0c0b21e8e5938bf16f86a62dc5f6ded5f453c61acd43666634d6b") + + depends_on("cxx", type="build") # generated depends_on("cmake@3.15:", type="build") depends_on("grpc@1.28.1+shared", type="build", when="@:5.3") depends_on("grpc@1.44.0+shared", when="@5.4.0:5.4") - depends_on("grpc@1.55.0+shared", when="@5.5.0:") + depends_on("grpc@1.55.0+shared", when="@5.5.0:6.0") + depends_on("grpc@1.59.1+shared", when="@6.1:") depends_on("protobuf") depends_on("libcap") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -72,19 +67,14 @@ def url_for_version(self, version): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"rocm-smi-lib@{ver}", type=("build", "link"), when=f"@{ver}") + depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", - "5.3.0", - "5.3.3", - "5.4.0", - "5.4.3", "5.5.0", "5.5.1", "5.6.0", @@ -93,10 +83,10 @@ def url_for_version(self, version): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: - depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") - - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") def patch(self): diff --git a/var/spack/repos/builtin/packages/rdkit/package.py b/var/spack/repos/builtin/packages/rdkit/package.py index 60263763ec96fa..4017b494366b59 100644 --- a/var/spack/repos/builtin/packages/rdkit/package.py +++ b/var/spack/repos/builtin/packages/rdkit/package.py @@ -18,6 +18,7 @@ class Rdkit(CMakePackage): license("BSD-3-Clause") + version("2024_03_3", sha256="52f79c6bf1d446cdb5c86a35de655d96bad0c52a5f4ecbe15f08eaf334e6f76a") version("2023_03_1", sha256="db346afbd0ba52c843926a2a62f8a38c7b774ffab37eaf382d789a824f21996c") version("2022_09_5", sha256="2efe7ce3b527df529ed3e355e2aaaf14623e51876be460fa4ad2b7f7ad54c9b1") version("2021_09_5", sha256="f720b3f6292c4cd0a412a073d848ffac01a43960082e33ee54b68798de0cbfa1") @@ -46,6 +47,10 @@ class Rdkit(CMakePackage): version("2020_09_1", sha256="ac105498be52ff77f7e9328c41d0e61a2318cac0789d6efc30f5f50dc78a992c") version("2020_03_6", sha256="a3663295a149aa0307ace6d1995094d0334180bc8f892fa325558a110154272b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("freetype", default=True, description="Build freetype support") with when("@2022_09_5:"): @@ -69,6 +74,8 @@ class Rdkit(CMakePackage): depends_on("eigen@3:", when="+descriptors3d") depends_on("python@3:", when="+python") depends_on("py-numpy", when="+python") + # https://github.com/rdkit/rdkit/issues/7477 + depends_on("py-numpy@:1", when="@:2024.03.3+python") extends("python", when="+python") @@ -81,6 +88,8 @@ class Rdkit(CMakePackage): with when("@:2021_09_5"): depends_on("python@3:") depends_on("py-numpy") + # https://github.com/rdkit/rdkit/issues/7477 + depends_on("py-numpy@:1") extends("python") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/rdma-core/libdrm.patch b/var/spack/repos/builtin/packages/rdma-core/libdrm.patch new file mode 100644 index 00000000000000..41048b39cb447b --- /dev/null +++ b/var/spack/repos/builtin/packages/rdma-core/libdrm.patch @@ -0,0 +1,11 @@ +--- a/CMakeLists.txt 2024-06-24 15:48:01.389773228 +0200 ++++ b/CMakeLists.txt 2024-06-25 09:51:13.637660505 +0200 +@@ -539,7 +539,7 @@ + # drm headers + + # Check if the headers have been installed by kernel-headers +-find_path(DRM_INCLUDE_DIRS "drm.h" PATH_SUFFIXES "drm") ++find_path(DRM_INCLUDE_DIRS "drm.h" PATH_SUFFIXES "drm" "libdrm") + + # Alternatively the headers could have been installed by libdrm + if (NOT DRM_INCLUDE_DIRS) diff --git a/var/spack/repos/builtin/packages/rdma-core/package.py b/var/spack/repos/builtin/packages/rdma-core/package.py index 8c2998e5da05df..4d3a8fe23987c1 100644 --- a/var/spack/repos/builtin/packages/rdma-core/package.py +++ b/var/spack/repos/builtin/packages/rdma-core/package.py @@ -18,6 +18,10 @@ class RdmaCore(CMakePackage): license("GPL-2.0-only OR BSD-2-Clause") + version("52.0", sha256="1f0ce5f2462c982b20d21156707076278807a7adf4d10e9142f3be4bec1b2b83") + version("51.0", sha256="0a4a55b1351356c2750f26ec9010e8c7370402a13c95799cb8b447cf0134dd61") + version("50.0", sha256="405b9dd551120da9d1b8944c5ad24ab1f478fb13caedf5bf0d47053a6d6e20cc") + version("49.1", sha256="2e531d398073dd7ed28d95c94fa698e1a831952b508e9af93e36644dcd399936") version("49.0", sha256="953546ad2b179f9ce68dc21eb1eb26003098ea1bf0f87a4baed45bcea134b2b4") version("47.1", sha256="5d92058473b90be231c17220ce456837cb6da9975de498bd63b9660baa25afd6") version("46.2", sha256="c59c3c79fbae6038d7c6d16b37132e433e19f4a86d41341c6b7974b830b0d4fa") @@ -66,6 +70,10 @@ class RdmaCore(CMakePackage): version("17.1", sha256="b47444b7c05d3906deb8771eec3e634984dd83f5e620d5e37d3a83f74f0cc1ba") version("13", sha256="e5230fd7cda610753ad1252b40a28b1e9cf836423a10d8c2525b081527760d97") + depends_on("c", type="build") # generated + + patch("libdrm.patch", when="@34:") + variant( "static", default=True, diff --git a/var/spack/repos/builtin/packages/re2/package.py b/var/spack/repos/builtin/packages/re2/package.py index 0932968d18e81c..ad569fa98c16ac 100644 --- a/var/spack/repos/builtin/packages/re2/package.py +++ b/var/spack/repos/builtin/packages/re2/package.py @@ -28,6 +28,8 @@ class Re2(CMakePackage): "2020-04-01", sha256="98794bc5416326817498384a9c43cbb5a406bab8da9f84f83c39ecad43ed5cea" ) + depends_on("cxx", type="build") # generated + variant("shared", default=False, description="Build shared instead of static libraries") variant("pic", default=True, description="Enable position independent code") @@ -40,5 +42,6 @@ def cmake_args(self): args = [ self.define_from_variant("BUILD_SHARED_LIBS", "shared"), self.define_from_variant("CMAKE_POSITION_INDEPENDENT_CODE", "pic"), + f"-DCMAKE_CXX_STANDARD={self.spec['abseil-cpp'].variants['cxxstd'].value}", ] return args diff --git a/var/spack/repos/builtin/packages/re2c/package.py b/var/spack/repos/builtin/packages/re2c/package.py index 6f621b5d3adb9b..57436bcf494ff2 100644 --- a/var/spack/repos/builtin/packages/re2c/package.py +++ b/var/spack/repos/builtin/packages/re2c/package.py @@ -17,6 +17,10 @@ class Re2c(Package): license("Public-Domain") + # Python 3.7 is required for re2c@3.1, but the clingo bootstrap on OpenSUSE Leap uses + # the system Python 3.6 such that the bootstrap fails with an UnsatisfiableVersionSpecError + # version("3.1", sha256="0ac299ad359e3f512b06a99397d025cfff81d3be34464ded0656f8a96676c029") + version("3.0", sha256="b3babbbb1461e13fe22c630a40c43885efcfbbbb585830c6f4c0d791cf82ba0b") version("2.2", sha256="0fc45e4130a8a555d68e230d1795de0216dfe99096b61b28e67c86dfd7d86bda") version("2.1.1", sha256="036ee264fafd5423141ebd628890775aa9447a4c4068a6307385d7366fe711f8") version("2.1", sha256="8cba0d95c246c670de8f97f57def83a9c0f2113eaa6f7e4867a941f48f633540") @@ -27,9 +31,16 @@ class Re2c(Package): version("1.3", sha256="f37f25ff760e90088e7d03d1232002c2c2672646d5844fdf8e0d51a5cd75a503") version("1.2.1", sha256="1a4cd706b5b966aeffd78e3cf8b24239470ded30551e813610f9cd1a4e01b817") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + phases = ["configure", "build", "install"] depends_on("cmake", when="platform=windows") + depends_on("gmake", when="platform=linux") + depends_on("gmake", when="platform=darwin") + depends_on("gmake", when="platform=freebsd") + # depends_on("python@3:", when="@3.1:", type="build") @property def make_tool(self): diff --git a/var/spack/repos/builtin/packages/readfq/package.py b/var/spack/repos/builtin/packages/readfq/package.py index 280ca5cf3b31c7..2a7a77776074fd 100644 --- a/var/spack/repos/builtin/packages/readfq/package.py +++ b/var/spack/repos/builtin/packages/readfq/package.py @@ -18,5 +18,7 @@ class Readfq(Package): version("2013.04.10", commit="4fb766095d8f459e0f8025be70f9173673905d12") + depends_on("c", type="build") # generated + def install(self, spec, prefix): install_tree(".", prefix.bin) diff --git a/var/spack/repos/builtin/packages/readline/package.py b/var/spack/repos/builtin/packages/readline/package.py index 3ef4ee6894d3c0..5140bb79d2d9eb 100644 --- a/var/spack/repos/builtin/packages/readline/package.py +++ b/var/spack/repos/builtin/packages/readline/package.py @@ -26,6 +26,8 @@ class Readline(AutotoolsPackage, GNUMirrorPackage): version("7.0", sha256="750d437185286f40a369e1e4f4764eda932b9459b5ec9a731628393dd3d32334") version("6.3", sha256="56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43") + depends_on("c", type="build") # generated + depends_on("ncurses") patches = [ diff --git a/var/spack/repos/builtin/packages/recola-sm/package.py b/var/spack/repos/builtin/packages/recola-sm/package.py index 93d104250d60f8..22458b88e7e523 100644 --- a/var/spack/repos/builtin/packages/recola-sm/package.py +++ b/var/spack/repos/builtin/packages/recola-sm/package.py @@ -21,6 +21,8 @@ class RecolaSm(CMakePackage): version("2.2.3", sha256="9ebdc4fd8ca48789de0b6bbb2ab7e4845c92d19dfe0c3f67866cbf114d6242a5") + depends_on("fortran", type="build") # generated + depends_on("collier") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/recola/package.py b/var/spack/repos/builtin/packages/recola/package.py index 1ea5a04dece85d..649262918eb96d 100644 --- a/var/spack/repos/builtin/packages/recola/package.py +++ b/var/spack/repos/builtin/packages/recola/package.py @@ -39,6 +39,10 @@ class Recola(CMakePackage): sha256="dc7db5ac9456dda2e6c03a63ad642066b0b5e4ceb8cae1f2a13ab33b35caaba8", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("collier") depends_on("recola-sm") depends_on("python@3:", when="+python") diff --git a/var/spack/repos/builtin/packages/recon/package.py b/var/spack/repos/builtin/packages/recon/package.py index fa6117fffe8036..1bbea3c956fa05 100644 --- a/var/spack/repos/builtin/packages/recon/package.py +++ b/var/spack/repos/builtin/packages/recon/package.py @@ -19,6 +19,8 @@ class Recon(MakefilePackage): version("1.05", sha256="4d4f76f439bcffd50380cffc41a80dc15fa4a80f38a04234e24da893ed7c025a") + depends_on("c", type="build") # generated + variant("repeatmasker", default=False, description="Use RepeatMasker developer patches (1.08)") patch("repeatmasker_recon.patch", when="+repeatmasker") diff --git a/var/spack/repos/builtin/packages/recorder/package.py b/var/spack/repos/builtin/packages/recorder/package.py index 064e20f62efd30..5cd4e84b95ee2c 100644 --- a/var/spack/repos/builtin/packages/recorder/package.py +++ b/var/spack/repos/builtin/packages/recorder/package.py @@ -24,6 +24,9 @@ class Recorder(AutotoolsPackage): version("2.1.5", sha256="6d2f8b942f61da498e25327e79c1a25b2244f4f78a9cf5482fb4aaa32d7332a1") version("2.1.4", sha256="f66756595a7f310929c247ae03fd08a18d9843f578fffa1e3072f557bf5a158e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("posix", default=True, description="Enable POSIX level tracing.") variant( "mpi", diff --git a/var/spack/repos/builtin/packages/redis-ai/package.py b/var/spack/repos/builtin/packages/redis-ai/package.py index b790fd638a4f76..2bdf71bdd78f6a 100644 --- a/var/spack/repos/builtin/packages/redis-ai/package.py +++ b/var/spack/repos/builtin/packages/redis-ai/package.py @@ -22,6 +22,9 @@ class RedisAi(MakefilePackage): "1.2.7", tag="v1.2.7", commit="1bf38d86233ba06e1350ca9de794df2b07cdb274", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("torch", default=True, description="Build with the pytorch backend") variant("cuda", default=False, description="Use CUDA") variant("rocm", default=False, description="Use ROCm") diff --git a/var/spack/repos/builtin/packages/redis-plus-plus/package.py b/var/spack/repos/builtin/packages/redis-plus-plus/package.py index 04fe1d0df8f99e..87c68a5e9e1f36 100644 --- a/var/spack/repos/builtin/packages/redis-plus-plus/package.py +++ b/var/spack/repos/builtin/packages/redis-plus-plus/package.py @@ -34,6 +34,8 @@ class RedisPlusPlus(CMakePackage): version("1.3.5", sha256="a49a72fef26ed39d36a278fcc4e4d92822e111697b5992d8f26f70d16edc6c1f") version("1.3.4", sha256="b9f2b3e0f084fe9a7360e44a9ae28aa42067fbaf027734989c778865c2d5dca5") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.18:", type="build") depends_on("hiredis@1.0.0:", type=("build", "link")) depends_on("hiredis@1.0.0:+ssl", type=("build", "link"), when="+tls") diff --git a/var/spack/repos/builtin/packages/redis/package.py b/var/spack/repos/builtin/packages/redis/package.py index e2e325faf70974..f32406ee2e6563 100644 --- a/var/spack/repos/builtin/packages/redis/package.py +++ b/var/spack/repos/builtin/packages/redis/package.py @@ -52,6 +52,9 @@ class Redis(MakefilePackage): version("4.0.12", sha256="6447259d2eed426a949c9c13f8fdb2d91fb66d9dc915dd50db13b87f46d93162") version("4.0.11", sha256="fc53e73ae7586bcdacb4b63875d1ff04f68c5474c1ddeda78f00e5ae2eed1bbb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("tls", default=False, when="@6:", description="Builds with TLS support") depends_on("openssl@1.1:", type=("build", "link"), when="+tls") diff --git a/var/spack/repos/builtin/packages/redland-bindings/package.py b/var/spack/repos/builtin/packages/redland-bindings/package.py index 964f62108f023b..9225f8af2994a8 100644 --- a/var/spack/repos/builtin/packages/redland-bindings/package.py +++ b/var/spack/repos/builtin/packages/redland-bindings/package.py @@ -3,8 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import os - from spack.package import * @@ -20,6 +18,8 @@ class RedlandBindings(AutotoolsPackage): version("1.0.16.1", sha256="065037ef61e9b78f642e75b9c2a42700eb1a87d903f2f9963d86591c7d916826") version("1.0.14.1", sha256="a8cc365fccf292c56d53341ecae57fe8727e5002e048ca25f6251b5e595aec40") + depends_on("c", type="build") # generated + depends_on("swig", type="build") depends_on("redland") depends_on("krb5") @@ -27,11 +27,4 @@ class RedlandBindings(AutotoolsPackage): extends("python") def configure_args(self): - plib = self.spec["python"].prefix.lib - plib64 = self.spec["python"].prefix.lib64 - mybase = self.prefix.lib - if os.path.isdir(plib64) and not os.path.isdir(plib): - mybase = self.prefix.lib64 - pver = "python{0}".format(self.spec["python"].version.up_to(2)) - myplib = join_path(mybase, pver, "site-packages") - return ["--with-python", "PYTHON_LIB={0}".format(myplib)] + return ["--with-python", f"PYTHON_LIB={python_platlib}"] diff --git a/var/spack/repos/builtin/packages/redland/package.py b/var/spack/repos/builtin/packages/redland/package.py index 1c8fc89e53571b..4707207de668f2 100644 --- a/var/spack/repos/builtin/packages/redland/package.py +++ b/var/spack/repos/builtin/packages/redland/package.py @@ -19,5 +19,7 @@ class Redland(AutotoolsPackage): version("1.0.16", sha256="d9a274fc086e61119d5c9beafb8d05527e040ec86f4c0961276ca8de0a049dbd") version("1.0.15", sha256="0e1f5825b6357c9b490da866c95ae1d895dbb5f445013d2511c37df822ee9ec6") + depends_on("c", type="build") # generated + depends_on("raptor2") depends_on("rasqal") diff --git a/var/spack/repos/builtin/packages/redset/package.py b/var/spack/repos/builtin/packages/redset/package.py index 5df8a0e25e2ece..6ef28e138e6f17 100644 --- a/var/spack/repos/builtin/packages/redset/package.py +++ b/var/spack/repos/builtin/packages/redset/package.py @@ -26,6 +26,8 @@ class Redset(CMakePackage): version("0.0.4", sha256="c33fce458d5582f01ad632c6fae8eb0a03eaef00e3c240c713b03bb95e2787ad") version("0.0.3", sha256="30ac1a960f842ae23a960a88b312af3fddc4795f2053eeeec3433a61e4666a76") + depends_on("c", type="build") # generated + depends_on("mpi") depends_on("kvtree+mpi") depends_on("rankstr") @@ -51,8 +53,5 @@ def cmake_args(self): if spec.satisfies("@0.1.0:"): args.append(self.define_from_variant("BUILD_SHARED_LIBS", "shared")) - else: - if spec.satisfies("platform=cray"): - args.append(self.define("REDSET_LINK_STATIC", True)) return args diff --git a/var/spack/repos/builtin/packages/reframe/package.py b/var/spack/repos/builtin/packages/reframe/package.py index dce47d20183b5b..5a142a94a157c1 100644 --- a/var/spack/repos/builtin/packages/reframe/package.py +++ b/var/spack/repos/builtin/packages/reframe/package.py @@ -85,6 +85,9 @@ class Reframe(Package): version("2.17.2", sha256="092241cdc15918040aacb922c806aecb59c5bdc3ff7db034a4f355d39aecc101") version("2.17.1", sha256="0b0d32a892607840a7d668f5dcea6f03f7022a26b23e5042a0faf5b8c41cb146") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("docs", default=False, description="Build ReFrame's man page documentation") variant("gelf", default=False, description="Add graylog handler support") diff --git a/var/spack/repos/builtin/packages/regale/package.py b/var/spack/repos/builtin/packages/regale/package.py index 8cb597774053f1..fed8981c4689c8 100644 --- a/var/spack/repos/builtin/packages/regale/package.py +++ b/var/spack/repos/builtin/packages/regale/package.py @@ -17,6 +17,9 @@ class Regale(CMakePackage): version("1.0", sha256="894b0927372467e765049e79b855a9a277def65638013f68a1f2b6e837e35663") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("eprosima-fastdds") variant("examples", default=False, description="Build examples") diff --git a/var/spack/repos/builtin/packages/regtools/package.py b/var/spack/repos/builtin/packages/regtools/package.py index 181e46c66c9414..b262a746099286 100644 --- a/var/spack/repos/builtin/packages/regtools/package.py +++ b/var/spack/repos/builtin/packages/regtools/package.py @@ -17,6 +17,9 @@ class Regtools(CMakePackage): version("1.0.0", sha256="ed2b9db6b71b943924002653caee18511a22ed7cc3c88f428e7e9e0c2e4f431b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install(join_path(self.build_directory, "regtools"), prefix.bin) diff --git a/var/spack/repos/builtin/packages/relax/package.py b/var/spack/repos/builtin/packages/relax/package.py index d591b95500a911..c826a84c4f4d3b 100644 --- a/var/spack/repos/builtin/packages/relax/package.py +++ b/var/spack/repos/builtin/packages/relax/package.py @@ -17,6 +17,8 @@ class Relax(CMakePackage): version("root6", sha256="1d24b1a0884bbe99d60f7d02fea45d59695c158ab5e53516ac3fb780eb460bb4") + depends_on("cxx", type="build") # generated + depends_on("clhep") depends_on("gsl") depends_on("hepmc@:2") diff --git a/var/spack/repos/builtin/packages/remhos/package.py b/var/spack/repos/builtin/packages/remhos/package.py index f53de7fcb2e1d2..7b6942626e7328 100644 --- a/var/spack/repos/builtin/packages/remhos/package.py +++ b/var/spack/repos/builtin/packages/remhos/package.py @@ -27,6 +27,8 @@ class Remhos(MakefilePackage): version("develop", branch="master") version("1.0", sha256="e60464a867fe5b1fd694fbb37bb51773723427f071c0ae26852a2804c08bbb32") + depends_on("cxx", type="build") # generated + variant("metis", default=True, description="Enable/disable METIS support") depends_on("mfem+mpi+metis", when="+metis") diff --git a/var/spack/repos/builtin/packages/rempi/package.py b/var/spack/repos/builtin/packages/rempi/package.py index a3651b37a7f166..fb35e8ddf8e417 100644 --- a/var/spack/repos/builtin/packages/rempi/package.py +++ b/var/spack/repos/builtin/packages/rempi/package.py @@ -18,6 +18,10 @@ class Rempi(AutotoolsPackage): version("1.1.0", sha256="4fd94fca52311fd19dc04a32547841e6c1c1656b7999b2f76f537d6ec24efccc") version("1.0.0", sha256="1cb21f457cf8a04632150156a2ba699dd0c3f81d47e8881a9b943b9bf575fa01") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("zlib-api") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/rendercheck/package.py b/var/spack/repos/builtin/packages/rendercheck/package.py index ab98014564af34..113bf059e53fcd 100644 --- a/var/spack/repos/builtin/packages/rendercheck/package.py +++ b/var/spack/repos/builtin/packages/rendercheck/package.py @@ -15,6 +15,8 @@ class Rendercheck(AutotoolsPackage, XorgPackage): version("1.5", sha256="1553fef61c30f2524b597c3758cc8d3f8dc1f52eb8137417fa0667b0adc8a604") + depends_on("c", type="build") # generated + depends_on("libxrender") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/reprimand/package.py b/var/spack/repos/builtin/packages/reprimand/package.py index 905e309d2ff331..521ac78f42c34a 100644 --- a/var/spack/repos/builtin/packages/reprimand/package.py +++ b/var/spack/repos/builtin/packages/reprimand/package.py @@ -27,6 +27,8 @@ class Reprimand(MesonPackage): version("1.4", sha256="260730696175fa21d35d1a92df2c68b69243bb617083c82616efcb4720d557e8") version("1.3", sha256="8e9f05b1f065a876d1405562285a9f64d1b31c4a436d5a6bb1f023212b40314e") + depends_on("cxx", type="build") # generated + # Add missing #include statments; see # patch("include.patch", when="@1.3") diff --git a/var/spack/repos/builtin/packages/resolve/package.py b/var/spack/repos/builtin/packages/resolve/package.py index 82234bf66bea04..d70c9ccf8ff1d8 100644 --- a/var/spack/repos/builtin/packages/resolve/package.py +++ b/var/spack/repos/builtin/packages/resolve/package.py @@ -23,6 +23,8 @@ class Resolve(CMakePackage, CudaPackage, ROCmPackage): ) version("develop", submodules=False, branch="develop") + depends_on("cxx", type="build") # generated + variant("klu", default=True, description="Use KLU, AMD and COLAMD Libraries from SuiteSparse") depends_on("suite-sparse", when="+klu") diff --git a/var/spack/repos/builtin/packages/revbayes/package.py b/var/spack/repos/builtin/packages/revbayes/package.py index 709c3dadd96564..097747e00ce128 100644 --- a/var/spack/repos/builtin/packages/revbayes/package.py +++ b/var/spack/repos/builtin/packages/revbayes/package.py @@ -30,6 +30,9 @@ class Revbayes(CMakePackage): version("1.0.11", sha256="03052194baa220dde7e622a739f09f34393f67ea00a0b163b409d313d7fc7c02") version("1.0.10", sha256="6a3cf303e7224b0b32637bd8e2c3c2cf2621f5dbe599cd74ce4b0c215d0fcd2d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Enable MPI parallel support") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/rgb/package.py b/var/spack/repos/builtin/packages/rgb/package.py index e30b4cea82074a..22bde52c3ab2b9 100644 --- a/var/spack/repos/builtin/packages/rgb/package.py +++ b/var/spack/repos/builtin/packages/rgb/package.py @@ -23,6 +23,8 @@ class Rgb(AutotoolsPackage, XorgPackage): version("1.1.0", sha256="77142e3d6f06cfbfbe440e29596765259988a22db40b1e706e14b8ba4c962aa5") version("1.0.6", sha256="cb998035e08b9f58ad3150cab60461c3225bdd075238cffc665e24da40718933") + depends_on("c", type="build") # generated + depends_on("xorg-server") depends_on("xproto") diff --git a/var/spack/repos/builtin/packages/rhash/package.py b/var/spack/repos/builtin/packages/rhash/package.py index 6a53f98ab4d166..c0f31f1586c83b 100644 --- a/var/spack/repos/builtin/packages/rhash/package.py +++ b/var/spack/repos/builtin/packages/rhash/package.py @@ -22,6 +22,8 @@ class Rhash(MakefilePackage): version("1.4.2", sha256="600d00f5f91ef04194d50903d3c79412099328c42f28ff43a0bdb777b00bec62") version("1.3.5", sha256="98e0688acae29e68c298ffbcdbb0f838864105f9b2bd8857980664435b1f1f2e") + depends_on("c", type="build") # generated + # configure: fix clang detection on macOS # Patch accepted and merged upstream, remove on next release patch( diff --git a/var/spack/repos/builtin/packages/rinetd/package.py b/var/spack/repos/builtin/packages/rinetd/package.py index bad9485262b15f..92a8ec1b1f0e7e 100644 --- a/var/spack/repos/builtin/packages/rinetd/package.py +++ b/var/spack/repos/builtin/packages/rinetd/package.py @@ -19,6 +19,8 @@ class Rinetd(AutotoolsPackage): version("0.70", sha256="e69538e9d1fdc1ba5cc24733a52c571568e9cad0876c09144aa1eaa71e13fba5") version("0.63", sha256="1f0e8cda524b8f4811a876e69e16d11f12c33a63d00b55c66e2129f87444000c") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/riscv-gnu-toolchain/package.py b/var/spack/repos/builtin/packages/riscv-gnu-toolchain/package.py index 64b880da333300..cc0e26048d186c 100644 --- a/var/spack/repos/builtin/packages/riscv-gnu-toolchain/package.py +++ b/var/spack/repos/builtin/packages/riscv-gnu-toolchain/package.py @@ -115,6 +115,10 @@ class RiscvGnuToolchain(AutotoolsPackage): submodules=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Dependencies: depends_on("pkgconfig", type="build") depends_on("autoconf", when="@main:", type="build") diff --git a/var/spack/repos/builtin/packages/rivet/package.py b/var/spack/repos/builtin/packages/rivet/package.py index d055f7d8a40923..00ae0783dca58e 100644 --- a/var/spack/repos/builtin/packages/rivet/package.py +++ b/var/spack/repos/builtin/packages/rivet/package.py @@ -31,6 +31,9 @@ class Rivet(AutotoolsPackage): version("3.0.1", sha256="e7551168b86a05c9c029c319c313a0aa142a476195e7ff986c896c1b868f89dd") version("3.0.0", sha256="3944434d3791dccb54f7b2257589df6252cc7c065ce9deb57fbef466ff9e62b1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("hepmc", default="2", values=("2", "3"), description="HepMC version to link against") # According to A. Buckley (main Rivet developer): @@ -54,7 +57,7 @@ class Rivet(AutotoolsPackage): depends_on("hepmc", when="hepmc=2") depends_on("hepmc3", when="hepmc=3") - depends_on("fastjet") + depends_on("fastjet plugins=cxx") depends_on("fastjet@3.4.0:", when="@3.1.7:") depends_on("fjcontrib") depends_on("python", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/rkcommon/package.py b/var/spack/repos/builtin/packages/rkcommon/package.py index ffcd012d32498a..b50dc13510722b 100644 --- a/var/spack/repos/builtin/packages/rkcommon/package.py +++ b/var/spack/repos/builtin/packages/rkcommon/package.py @@ -14,10 +14,9 @@ class Rkcommon(CMakePackage): url = "https://github.com/ospray/rkcommon/archive/v1.4.1.tar.gz" git = "https://github.com/ospray/rkcommon.git" - # maintainers("github_user1",o"github_user2") - license("Apache-2.0") + version("1.13.0", sha256="8ae9f911420085ceeca36e1f16d1316a77befbf6bf6de2a186d65440ac66ff1f") version("1.12.0", sha256="6abb901073811cdbcbe336772e1fcb458d78cab5ad8d5d61de2b57ab83581e80") version("1.11.0", sha256="9cfeedaccdefbdcf23c465cb1e6c02057100c4a1a573672dc6cfea5348cedfdd") version("1.10.0", sha256="57a33ce499a7fc5a5aaffa39ec7597115cf69ed4ff773546b5b71ff475ee4730") @@ -31,6 +30,8 @@ class Rkcommon(CMakePackage): version("1.4.2", sha256="2d1c0046cf583d3040fc9bb3b8ddcb1a2262d3f48aebd0973e6bd6cabb487f9e") version("1.4.1", sha256="f5968f5865fa5fe938843e1db621795524e7d31b37ce6024ba2978bb293ddfcf") + depends_on("cxx", type="build") # generated + depends_on("tbb") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/rkt-base/package.py b/var/spack/repos/builtin/packages/rkt-base/package.py index ea277d91206600..1a24aaf7f7dccf 100644 --- a/var/spack/repos/builtin/packages/rkt-base/package.py +++ b/var/spack/repos/builtin/packages/rkt-base/package.py @@ -15,6 +15,9 @@ class RktBase(RacketPackage): maintainers("elfprince13") version("8.3", commit="cab83438422bfea0e4bd74bc3e8305e6517cf25f") # tag='v8.3' + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("racket@8.3", type=("build", "run"), when="@8.3") racket_name = "base" diff --git a/var/spack/repos/builtin/packages/rkt-compiler-lib/package.py b/var/spack/repos/builtin/packages/rkt-compiler-lib/package.py index f91a118a53604b..dfbe793fafa127 100644 --- a/var/spack/repos/builtin/packages/rkt-compiler-lib/package.py +++ b/var/spack/repos/builtin/packages/rkt-compiler-lib/package.py @@ -15,6 +15,9 @@ class RktCompilerLib(RacketPackage): maintainers("elfprince13") version("8.3", commit="cab83438422bfea0e4bd74bc3e8305e6517cf25f") # tag='v8.3' + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("rkt-base@8.3", type=("build", "run"), when="@8.3") depends_on("rkt-scheme-lib@8.3", type=("build", "run"), when="@8.3") depends_on("rkt-rackunit-lib@8.3", type=("build", "run"), when="@8.3") diff --git a/var/spack/repos/builtin/packages/rkt-racket-lib/package.py b/var/spack/repos/builtin/packages/rkt-racket-lib/package.py index 00861c615b7b58..ef5647719af1a0 100644 --- a/var/spack/repos/builtin/packages/rkt-racket-lib/package.py +++ b/var/spack/repos/builtin/packages/rkt-racket-lib/package.py @@ -15,6 +15,9 @@ class RktRacketLib(RacketPackage): maintainers("elfprince13") version("8.3", commit="cab83438422bfea0e4bd74bc3e8305e6517cf25f") # tag="v8.3" + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("racket@8.3", type=("build", "run"), when="@8.3") racket_name = "racket-lib" diff --git a/var/spack/repos/builtin/packages/rkt-zo-lib/package.py b/var/spack/repos/builtin/packages/rkt-zo-lib/package.py index 579be294ca25ec..92cbffcf7b00d1 100644 --- a/var/spack/repos/builtin/packages/rkt-zo-lib/package.py +++ b/var/spack/repos/builtin/packages/rkt-zo-lib/package.py @@ -14,6 +14,9 @@ class RktZoLib(RacketPackage): maintainers("elfprince13") version("1.3", commit="cab83438422bfea0e4bd74bc3e8305e6517cf25f") # tag='v1.3' + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("rkt-base@8.3:", type=("build", "run"), when="@1.3") racket_name = "zo-lib" diff --git a/var/spack/repos/builtin/packages/rlwrap/package.py b/var/spack/repos/builtin/packages/rlwrap/package.py index 9a3d8f29594662..e2f52d07287ef0 100644 --- a/var/spack/repos/builtin/packages/rlwrap/package.py +++ b/var/spack/repos/builtin/packages/rlwrap/package.py @@ -21,6 +21,8 @@ class Rlwrap(AutotoolsPackage): version("0.44", sha256="cd7ff50cde66e443cbea0049b4abf1cca64a74948371fa4f1b5d9a5bbce1e13c") version("0.43", sha256="8e86d0b7882d9b8a73d229897a90edc207b1ae7fa0899dca8ee01c31a93feb2f") + depends_on("c", type="build") # generated + depends_on("readline@4.2:") def url_for_version(self, version): diff --git a/var/spack/repos/builtin/packages/rmgdft/package.py b/var/spack/repos/builtin/packages/rmgdft/package.py index 55acee0203627c..8165f07d548f3b 100644 --- a/var/spack/repos/builtin/packages/rmgdft/package.py +++ b/var/spack/repos/builtin/packages/rmgdft/package.py @@ -16,6 +16,7 @@ class Rmgdft(CMakePackage, CudaPackage): maintainers("elbriggs") tags = ["ecp", "ecp-apps"] version("master", branch="master") + version("6.1.0", tag="v6.1.0", commit="4dd5862725006b35d3118705197f89f13b24b858") version("5.4.0", tag="v5.4.0", commit="471251b191abb5f6ffdca4333c1fcb2add3c52f2") version("5.3.1", tag="v5.3.1", commit="dd6217ed82a8fe335acd0c030023b539d1be920a") version("5.2.0", tag="v5.2.0", commit="e95a84a258f84a3c33f36eb34ebb9daba691b649") @@ -23,6 +24,10 @@ class Rmgdft(CMakePackage, CudaPackage): version("5.0.4", tag="v5.0.4", commit="30faadeff7dc896169d011910831263fb19eb965") version("5.0.1", tag="v5.0.1", commit="60b3ad64b09a4fccdd2b84052350e7947e3e8ad0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "build_type", default="Release", diff --git a/var/spack/repos/builtin/packages/rmlab/package.py b/var/spack/repos/builtin/packages/rmlab/package.py index d9aa91441cb784..836f52039b2cf4 100644 --- a/var/spack/repos/builtin/packages/rmlab/package.py +++ b/var/spack/repos/builtin/packages/rmlab/package.py @@ -18,6 +18,8 @@ class Rmlab(CMakePackage): version("develop", branch="develop") + depends_on("cxx", type="build") # generated + variant("png", default=True, description="Enable PNG conversion support") # modern CMake diff --git a/var/spack/repos/builtin/packages/rnaz/package.py b/var/spack/repos/builtin/packages/rnaz/package.py index 7031c2dc9b692a..d25e2572337be1 100644 --- a/var/spack/repos/builtin/packages/rnaz/package.py +++ b/var/spack/repos/builtin/packages/rnaz/package.py @@ -16,6 +16,9 @@ class Rnaz(AutotoolsPackage): version("2.1.1", commit="f2c19f7237f2eb3df04f4747c8c11616447ec095") version("2.1", sha256="b32ec0361889319f2058f224d6c456c853dbc30dff4dba90c53a8f9fd7b83be5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + with when("@2.1.1:"): depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/rng-tools/package.py b/var/spack/repos/builtin/packages/rng-tools/package.py index 40341e0b157710..23283c21dc159d 100644 --- a/var/spack/repos/builtin/packages/rng-tools/package.py +++ b/var/spack/repos/builtin/packages/rng-tools/package.py @@ -21,6 +21,8 @@ class RngTools(AutotoolsPackage): version("6.9", sha256="a57a7f51a2e3c0faa8afb979709a4c0cbea36d0b52fd835b104f8fb4fd1fa610") version("6.8", sha256="93e548d4aaf2a1897d4b677f41d8473db1c7f57648adeca18cafa1907e410bb3") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/rngstreams/package.py b/var/spack/repos/builtin/packages/rngstreams/package.py index f5a86039eb809b..f95f4a55e7f5bd 100644 --- a/var/spack/repos/builtin/packages/rngstreams/package.py +++ b/var/spack/repos/builtin/packages/rngstreams/package.py @@ -15,3 +15,5 @@ class Rngstreams(AutotoolsPackage): license("GPL-3.0-only") version("1.0.1", sha256="966195febb9fb9417e4e361948843425aee12efc8b4e85332acbcd011ff2d9b0") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/rnpletal/package.py b/var/spack/repos/builtin/packages/rnpletal/package.py index b055e9496891a2..f7f862af075180 100644 --- a/var/spack/repos/builtin/packages/rnpletal/package.py +++ b/var/spack/repos/builtin/packages/rnpletal/package.py @@ -24,6 +24,9 @@ class Rnpletal(AutotoolsPackage): # which carry no version number. version("develop", sha256="2886f96393b64703fccf61b3dbc34e0fa45a79297232be76352f29cb83863d4d") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + maintainers("eschnett") variant( diff --git a/var/spack/repos/builtin/packages/rocalution/0003-fix-compilation-for-rocalution-5.2.0.patch b/var/spack/repos/builtin/packages/rocalution/0003-fix-compilation-for-rocalution-5.2.0.patch deleted file mode 100644 index 7090e92e1cf03e..00000000000000 --- a/var/spack/repos/builtin/packages/rocalution/0003-fix-compilation-for-rocalution-5.2.0.patch +++ /dev/null @@ -1,35 +0,0 @@ -From 58046aee2ab5d53092811e77ae9b17a226aadf90 Mon Sep 17 00:00:00 2001 -From: Renjith Ravindran -Date: Mon, 8 Aug 2022 22:52:43 +0000 -Subject: [PATCH] Fix for compilation failure in rocalution 5.2.0 - ---- - src/solvers/multigrid/ruge_stueben_amg.hpp | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) - -diff --git a/src/solvers/multigrid/ruge_stueben_amg.hpp b/src/solvers/multigrid/ruge_stueben_amg.hpp -index 24ee942..7f25796 100644 ---- a/src/solvers/multigrid/ruge_stueben_amg.hpp -+++ b/src/solvers/multigrid/ruge_stueben_amg.hpp -@@ -58,14 +58,16 @@ namespace rocalution - ROCALUTION_EXPORT - virtual void Print(void) const; - -+#if defined(WIN32) || defined(_WIN32) || defined(__WIN32) - /** \brief Set coupling strength */ - ROCALUTION_EXPORT --#if defined(WIN32) || defined(_WIN32) || defined(__WIN32) -+ void SetCouplingStrength(ValueType eps); - #else - [[deprecated("This function will be removed in a future release. Use " - "SetStrengthThreshold() instead")]] --#endif -+ ROCALUTION_EXPORT - void SetCouplingStrength(ValueType eps); -+#endif - - /** \brief Set strength threshold */ - ROCALUTION_EXPORT --- -2.25.1 - diff --git a/var/spack/repos/builtin/packages/rocalution/package.py b/var/spack/repos/builtin/packages/rocalution/package.py index 24d6b8a7791eaa..94802cd20809dc 100644 --- a/var/spack/repos/builtin/packages/rocalution/package.py +++ b/var/spack/repos/builtin/packages/rocalution/package.py @@ -19,7 +19,7 @@ class Rocalution(CMakePackage): homepage = "https://github.com/ROCm/rocALUTION" git = "https://github.com/ROCm/rocALUTION.git" - url = "https://github.com/ROCm/rocALUTION/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rocALUTION/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("cgmb", "srekolam", "renjithravindrankannath") @@ -27,6 +27,9 @@ class Rocalution(CMakePackage): license("MIT") + version("6.1.2", sha256="5f9fb302ab1951a1caf54ed31b41d6f41a353dd4b5ee32bc3de2e9f9244dd4ef") + version("6.1.1", sha256="1f80b33813291c2e81e5b1efc325d3f5bb6592c8670c016930d01e73e74ab46b") + version("6.1.0", sha256="699a9b73844fcd4e30d0607b4042dc779f9bcdc27ad732e7a038968ff555af2b") version("6.0.2", sha256="453f889677728b510286d4c72952b343cac63c45e2cb8b801d8388a2ec599d2a") version("6.0.0", sha256="cabf37691b8db00c82bda49c7dcfaefd9b9067b7d097afa43b7a5f86c45bff99") version("5.7.1", sha256="b95afa1285759843c5fea1ad6e1c1edf283922e0d448db03a3e1f42b6942bc24") @@ -35,16 +38,13 @@ class Rocalution(CMakePackage): version("5.6.0", sha256="7397a2039e9615c0cf6776c33c4083c00b185b5d5c4149c89fea25a8976a3097") version("5.5.1", sha256="4612e30a0290b1732c8862eea655122abc2d22ce4345b8498fe4127697e880b4") version("5.5.0", sha256="626e966b67b83a1ef79f9bf27aba998c49cf65c4208092516aa1e32a6cbd8c36") - version("5.4.3", sha256="39d00951a9b3cbdc4205a7e3ce75c026d9428c71c784815288c445f84a7f8a0e") - version("5.4.0", sha256="dccf004434e0fee6d0c7bedd46827f5a2af0392bc4807a08403b130e461f55eb") - version("5.3.3", sha256="3af022250bc25bebdee12bfb8fdbab4b60513b537b9fe15dfa82ded8850c5066") - version("5.3.0", sha256="f623449789a5c9c9137ae51d4dbbee5c6940d8813826629cb4b7e84f07fab494") with default_args(deprecated=True): - version("5.2.3", sha256="8e0d77099bf7dc0d00505e1c936b072a59719102c75398dc1416cbef31902253") - version("5.2.1", sha256="f246bd5b5d1b5821c29b566610a1c1d5c5cc361e0e5c373b8b04168b05e9b26f") - version("5.2.0", sha256="a5aac471bbec87d019ad7c6db779c73327ad40ecdea09dc5ab2106e62cd6b7eb") - version("5.1.3", sha256="7febe8179f120cbe58ea255bc233ad5d1b4c106f3934eb8e670135a8b7bd09c7") - version("5.1.0", sha256="d9122189103ebafe7ec5aeb50e60f3e02af5c2747021f9071aab91e7f875c29e") + version("5.4.3", sha256="39d00951a9b3cbdc4205a7e3ce75c026d9428c71c784815288c445f84a7f8a0e") + version("5.4.0", sha256="dccf004434e0fee6d0c7bedd46827f5a2af0392bc4807a08403b130e461f55eb") + version("5.3.3", sha256="3af022250bc25bebdee12bfb8fdbab4b60513b537b9fe15dfa82ded8850c5066") + version("5.3.0", sha256="f623449789a5c9c9137ae51d4dbbee5c6940d8813826629cb4b7e84f07fab494") + + depends_on("cxx", type="build") # generated amdgpu_targets = ROCmPackage.amdgpu_targets @@ -58,11 +58,6 @@ class Rocalution(CMakePackage): depends_on("cmake@3.5:", type="build") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -75,6 +70,9 @@ class Rocalution(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"rocprim@{ver}", when=f"@{ver}") @@ -88,9 +86,6 @@ class Rocalution(CMakePackage): depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") depends_on("googletest@1.10.0:", type="test") - # This fix is added to address the compilation failure and it is - # already taken in 5.2.3 rocm release. - patch("0003-fix-compilation-for-rocalution-5.2.0.patch", when="@5.2") # Fix build for most Radeon 5000 and Radeon 6000 series GPUs. patch("0004-fix-navi-1x.patch", when="@5.2.0:5.3") @@ -122,9 +117,7 @@ def cmake_args(self): self.define("BUILD_CLIENTS_SAMPLES", "OFF"), self.define("BUILD_CLIENTS_TESTS", self.run_tests), ] - if self.spec.satisfies("@:5.1"): - args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.cmake)) - elif self.spec.satisfies("@5.2:"): + if self.spec.satisfies("@5.2:"): args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.lib.cmake.hip)) if "auto" not in self.spec.variants["amdgpu_target"]: args.append(self.define_from_variant("AMDGPU_TARGETS", "amdgpu_target")) diff --git a/var/spack/repos/builtin/packages/rocblas/0003-Fix-rocblas-gentest.patch b/var/spack/repos/builtin/packages/rocblas/0003-Fix-rocblas-gentest.patch deleted file mode 100644 index 4bc1631fec73e4..00000000000000 --- a/var/spack/repos/builtin/packages/rocblas/0003-Fix-rocblas-gentest.patch +++ /dev/null @@ -1,9 +0,0 @@ -diff -r -u a/clients/common/rocblas_gentest.py b/clients/common/rocblas_gentest.py ---- a/clients/common/rocblas_gentest.py 2021-11-12 12:22:24.359556397 -0700 -+++ b/clients/common/rocblas_gentest.py 2021-11-12 12:22:41.464044040 -0700 -@@ -1,4 +1,4 @@ --#!/usr/bin/python3 -+#!/usr/bin/env python3 - """Copyright 2018-2020 Advanced Micro Devices, Inc. - Expand rocBLAS YAML test data file into binary Arguments records""" - diff --git a/var/spack/repos/builtin/packages/rocblas/package.py b/var/spack/repos/builtin/packages/rocblas/package.py index 8c00ddf1d602cb..4c91b3bd04eff1 100644 --- a/var/spack/repos/builtin/packages/rocblas/package.py +++ b/var/spack/repos/builtin/packages/rocblas/package.py @@ -13,7 +13,7 @@ class Rocblas(CMakePackage): homepage = "https://github.com/ROCm/rocBLAS/" git = "https://github.com/ROCm/rocBLAS.git" - url = "https://github.com/ROCm/rocBLAS/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rocBLAS/archive/rocm-6.1.1.tar.gz" tags = ["rocm"] maintainers("cgmb", "srekolam", "renjithravindrankannath", "haampie") @@ -23,6 +23,9 @@ class Rocblas(CMakePackage): version("develop", branch="develop") version("master", branch="master") + version("6.1.2", sha256="1e83918bd7b28ec9ee292c6fb7eb0fc5f4db2d5d831a9a3db541f14a90c20a1a") + version("6.1.1", sha256="c920742fb8f45512c360cdb40e37d0ac767f042e52f1981264853dab5ec2c876") + version("6.1.0", sha256="af00357909da60d82618038aa9a3cc1f9d4ce1bdfb54db20ec746b592d478edf") version("6.0.2", sha256="d1bf31063a2d349797b88c994c91d05f94e681bafb5550ad9b53529703d89dbb") version("6.0.0", sha256="befa4a75f1de0ea37f2358d4c2de5406d7bce671ca9936e2294b64d3b3bafb60") version("5.7.1", sha256="2984a5ed0ea5a05d40996ee3fddecb24399cbe8ea3e4921fc254e54d8f52fe4f") @@ -31,16 +34,15 @@ class Rocblas(CMakePackage): version("5.6.0", sha256="6a70b27eede02c45f46095a6ce8421af9a774a565e39f5e1074783ecf00c1ea7") version("5.5.1", sha256="7916a8d238d51cc239949d799f0b61c9d5cd63c6ccaed0e16749489b89ca8ff3") version("5.5.0", sha256="b5260517f199e806ae18f2c4495f163884e0d7a0a7c67af0770f7428ea50f898") - version("5.4.3", sha256="d82cd334b7a9b40d16ec4f4bb1fb5662382dcbfc86ee5e262413ed63d9e6a701") - version("5.4.0", sha256="261e05375024a01e68697c5d175210a07f0f5fc63a756234d996ddedffde78a2") - version("5.3.3", sha256="62a3b5f415bd8e0dcd0d68233d379f1a928ec0349977c32b4eea72ae5004e805") - version("5.3.0", sha256="8ea7269604cba949a6ea84b78dc92a44fa890427db88334da6358813f6512e34") with default_args(deprecated=True): - version("5.2.3", sha256="36f74ce53b82331a756c42f95f3138498d6f4a66f2fd370cff9ab18281bb12d5") - version("5.2.1", sha256="6be804ba8d9e491a85063c220cd0ddbf3d13e3b481eee31041c35a938723f4c6") - version("5.2.0", sha256="b178b7db5f0af55b21b5f744b8825f5e002daec69b4688e50df2bca2fac155bd") - version("5.1.3", sha256="915374431db8f0cecdc2bf318a0ad33c3a8eceedc461d7a06b92ccb02b07313c") - version("5.1.0", sha256="efa0c424b5ada697314aa8a78c19c93ade15f1612c4bfc8c53d71d1c9719aaa3") + version("5.4.3", sha256="d82cd334b7a9b40d16ec4f4bb1fb5662382dcbfc86ee5e262413ed63d9e6a701") + version("5.4.0", sha256="261e05375024a01e68697c5d175210a07f0f5fc63a756234d996ddedffde78a2") + version("5.3.3", sha256="62a3b5f415bd8e0dcd0d68233d379f1a928ec0349977c32b4eea72ae5004e805") + version("5.3.0", sha256="8ea7269604cba949a6ea84b78dc92a44fa890427db88334da6358813f6512e34") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated amdgpu_targets = ROCmPackage.amdgpu_targets @@ -62,18 +64,12 @@ class Rocblas(CMakePackage): depends_on("googletest@1.10.0:", type="test") depends_on("amdblis", type="test") - for ver in ["5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in ["5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: depends_on(f"rocm-openmp-extras@{ver}", type="test", when=f"@{ver}") depends_on("rocm-cmake@master", type="build", when="@master:") - depends_on("rocm-cmake", type="build") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -86,10 +82,14 @@ class Rocblas(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"llvm-amdgpu@{ver}", type="build", when=f"@{ver}") depends_on(f"rocminfo@{ver}", type="build", when=f"@{ver}") + depends_on(f"rocm-cmake@{ver}", type="build", when=f"@{ver}") depends_on("python@3.6:", type="build") @@ -106,11 +106,6 @@ class Rocblas(CMakePackage): depends_on("procps", type="build", when="@5.6:") for t_version, t_commit in [ - ("@5.1.0", "ea38f8661281a37cd81c96cc07868e3f07d2c4da"), - ("@5.1.3", "ea38f8661281a37cd81c96cc07868e3f07d2c4da"), - ("@5.2.0", "9ca08f38c4c3bfe6dfa02233637e7e3758c7b6db"), - ("@5.2.1", "9ca08f38c4c3bfe6dfa02233637e7e3758c7b6db"), - ("@5.2.3", "9ca08f38c4c3bfe6dfa02233637e7e3758c7b6db"), ("@5.3.0", "b33ca97af456cda14f7b1ec9bcc8aeab3ed6dd08"), ("@5.3.3", "006a5d653ce0d82fecb05d5e215d053749b57c04"), ("@5.4.0", "5aec08937473b27865fa969bb38a83bcf9463c2b"), @@ -123,6 +118,9 @@ class Rocblas(CMakePackage): ("@5.7.1", "97e0cfc2c8cb87a1e38901d99c39090dc4181652"), ("@6.0.0", "17df881bde80fc20f997dfb290f4bb4b0e05a7e9"), ("@6.0.2", "17df881bde80fc20f997dfb290f4bb4b0e05a7e9"), + ("@6.1.0", "2b55ccf58712f67b3df0ca53b0445f094fcb96b2"), + ("@6.1.1", "2b55ccf58712f67b3df0ca53b0445f094fcb96b2"), + ("@6.1.2", "2b55ccf58712f67b3df0ca53b0445f094fcb96b2"), ]: resource( name="Tensile", @@ -139,7 +137,6 @@ class Rocblas(CMakePackage): when=f"@{ver} +tensile", ) - patch("0003-Fix-rocblas-gentest.patch", when="@:5.1") # Finding Python package and set command python as python3 patch("0004-Find-python.patch", when="@5.2.0:5.4") patch("0006-Guard-use-of-OpenMP-to-make-it-optional-5.4.patch", when="@5.4") diff --git a/var/spack/repos/builtin/packages/rocfft/0003-Fix-clients-fftw3-include-dirs-rocm-4.5.patch b/var/spack/repos/builtin/packages/rocfft/0003-Fix-clients-fftw3-include-dirs-rocm-4.5.patch deleted file mode 100644 index aaf44a872a4e9c..00000000000000 --- a/var/spack/repos/builtin/packages/rocfft/0003-Fix-clients-fftw3-include-dirs-rocm-4.5.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/clients/CMakeLists.txt b/clients/CMakeLists.txt -index 7f14a55..a62fbd4 100644 ---- a/clients/CMakeLists.txt -+++ b/clients/CMakeLists.txt -@@ -103,6 +103,7 @@ if( BUILD_CLIENTS_TESTS OR BUILD_CLIENTS_SAMPLES ) - # look for installed FFTW if we weren't asked to build it - if( NOT BUILD_FFTW ) - find_package( FFTW 3.0 MODULE COMPONENTS FLOAT DOUBLE ) -+ set( FFTW_INCLUDES ${FFTW_INCLUDE_DIRS} ) - endif() - - # also try to build FFTW if FFTW isn't present diff --git a/var/spack/repos/builtin/packages/rocfft/0005-Fix-clients-tests-include-rocrand-fftw-include-dir-rocm-6.0.0.patch b/var/spack/repos/builtin/packages/rocfft/0005-Fix-clients-tests-include-rocrand-fftw-include-dir-rocm-6.0.0.patch new file mode 100644 index 00000000000000..8144fb8d292e0f --- /dev/null +++ b/var/spack/repos/builtin/packages/rocfft/0005-Fix-clients-tests-include-rocrand-fftw-include-dir-rocm-6.0.0.patch @@ -0,0 +1,39 @@ +diff --git a/clients/tests/CMakeLists.txt b/clients/tests/CMakeLists.txt +index d0b95b4..0339daa 100644 +--- a/clients/tests/CMakeLists.txt ++++ b/clients/tests/CMakeLists.txt +@@ -64,6 +64,10 @@ if( NOT hiprand_FOUND ) + find_package( hiprand REQUIRED ) + endif() + ++if( NOT rocrand_FOUND ) ++ find_package( rocrand REQUIRED ) ++endif() ++ + include( ROCMInstallTargets ) + + set( rocfft-test_source +@@ -109,6 +113,7 @@ option( BUILD_FFTW "Download and build FFTW" OFF ) + # look for installed FFTW if we weren't asked to build it + if( NOT BUILD_FFTW ) + find_package( FFTW 3.0 MODULE COMPONENTS FLOAT DOUBLE ) ++ set( FFTW_INCLUDES ${FFTW_INCLUDE_DIRS} ) + endif() + + include( ExternalProject ) +@@ -174,6 +179,7 @@ endif() + + set( rocfft-test_include_dirs + $ ++ $ + $ + $ + $ +@@ -216,6 +222,7 @@ target_link_libraries( rocfft-test + hip::device + roc::rocfft + hip::hiprand ++ roc::rocrand + ${rocfft-test_link_libs} + ) + diff --git a/var/spack/repos/builtin/packages/rocfft/package.py b/var/spack/repos/builtin/packages/rocfft/package.py index efec5bac212bde..121e9764361640 100644 --- a/var/spack/repos/builtin/packages/rocfft/package.py +++ b/var/spack/repos/builtin/packages/rocfft/package.py @@ -13,13 +13,16 @@ class Rocfft(CMakePackage): homepage = "https://github.com/ROCm/rocFFT/" git = "https://github.com/ROCm/rocFFT.git" - url = "https://github.com/ROCm/rocfft/archive/rocm-6.0.0.tar.gz" + url = "https://github.com/ROCm/rocfft/archive/rocm-6.1.1.tar.gz" tags = ["rocm"] maintainers("cgmb", "srekolam", "renjithravindrankannath", "haampie") libraries = ["librocfft"] license("MIT") + version("6.1.2", sha256="6f54609b0ecb8ceae8b7acd4c8692514c2c2dbaf0f8b199fe990fd4711428193") + version("6.1.1", sha256="d517a931d49a1e59df4e494ab2b68e301fe7ebf39723863985567467f111111c") + version("6.1.0", sha256="9e6643174a2b0f376127f43454e78d4feba6fac695d4cda9796da50005ecac66") version("6.0.2", sha256="d3e1f7a4dc661f1e5ffce02e2e01ae6c3c339bac8e93deaf175e4c03ddfea459") version("6.0.0", sha256="fb8ba56572702e77e4383d922cd1fee4ad3fa5f63a5ebdb3d9c354439a446992") version("5.7.1", sha256="202f11f60dc8738e29bbd1b397d419e032794f8bffb7f48f2b31f09cc5f08bc2") @@ -28,16 +31,13 @@ class Rocfft(CMakePackage): version("5.6.0", sha256="e3d4a6c1bdac78f9a22033f57011af783d560308103f73542f9e0e4dd133d38a") version("5.5.1", sha256="57423a64f5cdb1c37ff0891b6c17b59f73198d46be42db4ae23781ef2c0cd49d") version("5.5.0", sha256="9288152e66504b06082e4eed8cdb791b4f9ae2836b3defbeb4d2b54901b96485") - version("5.4.3", sha256="ed9664adc9825c237327497bc4b23f020d50be7645647f14a45f4d943dd506e7") - version("5.4.0", sha256="d35a67332f4425fba1824eed78cf98d5c9a17a422614ff3f4cba2461df952336") - version("5.3.3", sha256="678c18710578c1fb36a0009311bb79de7607c3468f9102cfba56a866ebb7ff78") - version("5.3.0", sha256="d655c5541c4aff4267e80e36d002fc3a55c2f84a0ae8631197c12af3bf03fa7d") with default_args(deprecated=True): - version("5.2.3", sha256="0cee37886f01f1afb3ae5dad1164c819573c13c6675bff4eb668de334adbff27") - version("5.2.1", sha256="6302349b6cc610a9a939377e2c7ffba946656a8d43f2e438ff0b3088f0f963ad") - version("5.2.0", sha256="ebba280b7879fb4bc529a68072b98d4e815201f90d24144d672094bc241743d4") - version("5.1.3", sha256="b4fcd03c1b07d465bb307ec33cc7fb50036dff688e497c5e52b2dec37f4cb618") - version("5.1.0", sha256="dc11c9061753ae43a9d5db9c4674aa113a8adaf50818b2701cbb940894147f68") + version("5.4.3", sha256="ed9664adc9825c237327497bc4b23f020d50be7645647f14a45f4d943dd506e7") + version("5.4.0", sha256="d35a67332f4425fba1824eed78cf98d5c9a17a422614ff3f4cba2461df952336") + version("5.3.3", sha256="678c18710578c1fb36a0009311bb79de7607c3468f9102cfba56a866ebb7ff78") + version("5.3.0", sha256="d655c5541c4aff4267e80e36d002fc3a55c2f84a0ae8631197c12af3bf03fa7d") + + depends_on("cxx", type="build") # generated amdgpu_targets = ROCmPackage.amdgpu_targets @@ -63,17 +63,9 @@ class Rocfft(CMakePackage): depends_on("boost@1.64.0: +program_options", type="test") depends_on("rocm-openmp-extras", type="test") depends_on("hiprand", type="test") - - def check(self): - exe = join_path(self.build_directory, "clients", "staging", "rocfft-test") - self.run_test(exe, options="--gtest_filter=mix*:adhoc*") + depends_on("rocrand", type="test") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -86,14 +78,21 @@ def check(self): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") - # Patch to add spack build test support. No longer required from 5.2 - patch("0003-Fix-clients-fftw3-include-dirs-rocm-4.5.patch", when="@:5.1") # Patch to add install prefix header location for sqlite for 5.4 patch("0004-fix-missing-sqlite-include-paths.patch", when="@5.4.0:5.5") + # Patch to fix the build issue when --test=root is enabled + # This adds the include headers from the rocrand and fftw in the cmakelists.txt + # issue is seen from 5.7.0 onwards + patch( + "0005-Fix-clients-tests-include-rocrand-fftw-include-dir-rocm-6.0.0.patch", when="@5.7.0:" + ) # Set LD_LIBRARY_PATH for executing the binaries from build directoryfix missing type # https://github.com/ROCm/rocFFT/pull/449) @@ -106,6 +105,12 @@ def check(self): def setup_build_environment(self, env): env.set("CXX", self.spec["hip"].hipcc) + @run_after("build") + @on_package_attributes(run_tests=True) + def check_build(self): + exe = Executable(join_path(self.build_directory, "clients", "staging", "rocfft-test")) + exe("--gtest_filter=mix*:adhoc*") + @classmethod def determine_version(cls, lib): match = re.search(r"lib\S*\.so\.\d+\.\d+\.(\d)(\d\d)(\d\d)", lib) diff --git a/var/spack/repos/builtin/packages/rocksdb/package.py b/var/spack/repos/builtin/packages/rocksdb/package.py index b8dd075da91789..6feab293aa8b5a 100644 --- a/var/spack/repos/builtin/packages/rocksdb/package.py +++ b/var/spack/repos/builtin/packages/rocksdb/package.py @@ -16,6 +16,8 @@ class Rocksdb(MakefilePackage): license("Apache-2.0 OR GPL-2.0-only") version("master", git=git, branch="master", submodules=True) + version("9.4.0", sha256="1f829976aa24b8ba432e156f52c9e0f0bd89c46dc0cc5a9a628ea70571c1551c") + version("9.2.1", sha256="bb20fd9a07624e0dc1849a8e65833e5421960184f9c469d508b58ed8f40a780f") version("8.6.7", sha256="cdb2fc3c6a556f20591f564cb8e023e56828469aa3f76e1d9535c443ba1f0c1a") version("8.1.1", sha256="9102704e169cfb53e7724a30750eeeb3e71307663852f01fa08d5a320e6155a8") version("7.7.3", sha256="b8ac9784a342b2e314c821f6d701148912215666ac5e9bdbccd93cf3767cb611") @@ -30,6 +32,9 @@ class Rocksdb(MakefilePackage): version("5.16.6", sha256="f0739edce1707568bdfb36a77638fd5bae287ca21763ce3e56cf0bfae8fff033") version("5.15.10", sha256="26d5d4259fa352ae1604b5b4d275f947cacc006f4f7d2ef0b815056601b807c0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("bz2", default=False, description="Enable bz2 compression support") variant("lz4", default=True, description="Enable lz4 compression support") variant("shared", default=True, description="Build shared library") diff --git a/var/spack/repos/builtin/packages/rocm-bandwidth-test/package.py b/var/spack/repos/builtin/packages/rocm-bandwidth-test/package.py index 984a45a0735c80..c1e290b669d6fe 100644 --- a/var/spack/repos/builtin/packages/rocm-bandwidth-test/package.py +++ b/var/spack/repos/builtin/packages/rocm-bandwidth-test/package.py @@ -12,12 +12,15 @@ class RocmBandwidthTest(CMakePackage): homepage = "https://github.com/ROCm/rocm_bandwidth_test" git = "https://github.com/ROCm/rocm_bandwidth_test.git" - url = "https://github.com/ROCm/rocm_bandwidth_test/archive/rocm-6.0.0.tar.gz" + url = "https://github.com/ROCm/rocm_bandwidth_test/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") version("master", branch="master") + version("6.1.2", sha256="4259d53350d6731613d36c03593750547f84f084569f8017783947486b8189da") + version("6.1.1", sha256="01da756228f2bfb5e25ddb74b75a5939693b1b4f4559f37cfc85729e36a98450") + version("6.1.0", sha256="b06522efbd1a55247412c8f535321058e2463eab4abd25505c37e8c67941ae26") version("6.0.2", sha256="af95fe84729701184aeb14917cee0d8d77ab1858ddcced01eb7380401e2134ae") version("6.0.0", sha256="9023401bd6a896059545b8e6263c6730afd89d7d45c0f5866261c300415532a6") version("5.7.1", sha256="7426ef1e317b8293e4d6389673cfa8c63efb3f7d061e2f50a6f0b1b706e2a2a7") @@ -26,25 +29,17 @@ class RocmBandwidthTest(CMakePackage): version("5.6.0", sha256="ae2f7263a21a3a650068f43e3112b2b765eea80a5af2297572f850c77f83c85e") version("5.5.1", sha256="768b3da49fe7d4bb4e6536a8ee15be9f5e865d961e813ed4a407f32402685e1f") version("5.5.0", sha256="1070ce14d45f34c2c6b2fb003184f3ae735ccfd640e9df1c228988b2a5a82949") - version("5.4.3", sha256="a2f5a75bf47db1e39a4626a9f5cd2d120bcafe56b1baf2455d794f7a4734993e") - version("5.4.0", sha256="47a1ef92e565d5ce7a167cc1ebe3d4198cc04d598b259426245b8c11eb795677") - version("5.3.3", sha256="2bc079297e639d45d57c8017f6f47bc44d4ed34613ec76c80574bb703d79b498") - version("5.3.0", sha256="a97365c04d79663db7c85027c63a12d56356abc0a351697f49c2d82bf9ef8999") with default_args(deprecated=True): - version("5.2.3", sha256="b76fe33898d67ec1f5f1ec58adaea88e88ed28b1f5470aa4c08c347d8f558af2") - version("5.2.1", sha256="ebdf868bef8ab6c7f32775ba6eab85cf3e078af1fc1b1a11fdbaad777f37a190") - version("5.2.0", sha256="046f2a6984c62899f57a557490136fbe7ab28e2fd334750abac71b03609226ef") - version("5.1.3", sha256="6a6e7fb998c886951db75dcf34dca523d9caaff8d0ccf2b7431504a1808b1ff3") - version("5.1.0", sha256="18fe51f0ba61760fc89ffc81f737fd4fa20fb4b00df3f35145be77c3e0a6162b") + version("5.4.3", sha256="a2f5a75bf47db1e39a4626a9f5cd2d120bcafe56b1baf2455d794f7a4734993e") + version("5.4.0", sha256="47a1ef92e565d5ce7a167cc1ebe3d4198cc04d598b259426245b8c11eb795677") + version("5.3.3", sha256="2bc079297e639d45d57c8017f6f47bc44d4ed34613ec76c80574bb703d79b498") + version("5.3.0", sha256="a97365c04d79663db7c85027c63a12d56356abc0a351697f49c2d82bf9ef8999") + + depends_on("cxx", type="build") # generated depends_on("cmake@3:", type="build") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -57,12 +52,27 @@ class RocmBandwidthTest(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", ]: depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") depends_on(f"hsakmt-roct@{ver}", when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") build_targets = ["package"] diff --git a/var/spack/repos/builtin/packages/rocm-clang-ocl/package.py b/var/spack/repos/builtin/packages/rocm-clang-ocl/package.py index 9a976458840f27..4197bf22898499 100644 --- a/var/spack/repos/builtin/packages/rocm-clang-ocl/package.py +++ b/var/spack/repos/builtin/packages/rocm-clang-ocl/package.py @@ -11,13 +11,18 @@ class RocmClangOcl(CMakePackage): homepage = "https://github.com/ROCm/clang-ocl" git = "https://github.com/ROCm/clang-ocl.git" - url = "https://github.com/ROCm/clang-ocl/archive/rocm-6.0.0.tar.gz" + url = "https://github.com/ROCm/clang-ocl/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] + test_requires_compiler = True + license("MIT") maintainers("srekolam", "renjithravindrankannath") version("master", branch="master") + version("6.1.2", sha256="cc9942539b5e50b97fa0d2425ba93aae7223635fecba869d8f43b2c26f9482ae") + version("6.1.1", sha256="21b8a6d521a8e584e18851d27b5ef328a63ea7ee9eb3cc52508b9bfcf975e119") + version("6.1.0", sha256="c983adad49ab5850307db1282f8bc957b9870d4ce37db8fbb43c52db6c90d0ed") version("6.0.2", sha256="a2f2fcb203737b1f436b4c2b78bbd696552f6de619ba0e7e8faf95a888869866") version("6.0.0", sha256="74b5a64c32f3c57e7e4de638fffabbf448ecdb3dd8e65678b7ba0633352b4ca3") version("5.7.1", sha256="32e4430d009cbbf5404ca9cbbb549b36897fa1826bc2285372e293cfe7531bf8") @@ -26,25 +31,15 @@ class RocmClangOcl(CMakePackage): version("5.6.0", sha256="1afc47dee02d73c10de422f254067f4ef3ff921c4a1204d54ecc40e61fc63497") version("5.5.1", sha256="bfa62ad14830e2bd5afbc346685216c69f8cbef0eb449954f793178e10b19a38") version("5.5.0", sha256="43a5459165693301ba2ebcc41b2b0705df9a3a47571d43bdc2cc49cfdd0833a7") - version("5.4.3", sha256="689e0354ea685bd488116de8eb902b902492e9ace184c3109b97b9a43f8b2d59") - version("5.4.0", sha256="602f8fb1f36587543cc0ee95fd1938f8eeb03de79119101e128150332cc8d89c") - version("5.3.3", sha256="549d5bf37507f67c5277abdeed4ec40b5d0edbfbb72907c685444c26b9ce6f8a") - version("5.3.0", sha256="66b80ba050848ad921496bd894e740e66afad0ba1923b385f01f2eeae97999ad") with default_args(deprecated=True): - version("5.2.3", sha256="9cdb387168975207314c08ba63ae7cd11f70542117a5390eddbec77ebb84bed0") - version("5.2.1", sha256="693a9a360cb2f7e6910a6714df236df6a9d984f94b01712103a520d8e506c03f") - version("5.2.0", sha256="a2059f6aeccc119abbd444cb37128e00e4854e22a88a47f120f8f8b947d862c5") - version("5.1.3", sha256="e19ee15f26fc03309398ac73cc738508c0e1617deccfd667d369a3948b5d3552") - version("5.1.0", sha256="38d9e2e98cff1a262fdd45c3239fd76a9f6ad5eff38a31aa19c3bb0faea53375") + version("5.4.3", sha256="689e0354ea685bd488116de8eb902b902492e9ace184c3109b97b9a43f8b2d59") + version("5.4.0", sha256="602f8fb1f36587543cc0ee95fd1938f8eeb03de79119101e128150332cc8d89c") + version("5.3.3", sha256="549d5bf37507f67c5277abdeed4ec40b5d0edbfbb72907c685444c26b9ce6f8a") + version("5.3.0", sha256="66b80ba050848ad921496bd894e740e66afad0ba1923b385f01f2eeae97999ad") depends_on("cmake@3.5:", type="build") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -57,14 +52,29 @@ class RocmClangOcl(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", ]: depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") depends_on(f"llvm-amdgpu@{ver}", when=f"@{ver}") - # support both builtin and standalone device libs depends_on(f"rocm-device-libs@{ver}", when=f"@{ver} ^llvm-amdgpu ~rocm-device-libs") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") test_src_dir = "test" @@ -73,19 +83,13 @@ class RocmClangOcl(CMakePackage): def cache_test_sources(self): """Copy the tests source files after the package is installed to an install test subdirectory for use during `spack test run`.""" - if self.spec.satisfies("@:5.1.0"): - return self.cache_extra_test_sources([self.test_src_dir]) - def test(self): - if self.spec.satisfies("@:5.1.0"): - print("Skipping: stand-alone tests") - return + def test_make(self): + """Test make""" test_dir = join_path(self.test_suite.current_test_cache_dir, self.test_src_dir) - with working_dir(test_dir, create=True): - cmake_bin = join_path(self.spec["cmake"].prefix.bin, "cmake") - prefixes = ";".join([self.spec["rocm-clang-ocl"].prefix]) - cc_options = ["-DCMAKE_PREFIX_PATH=" + prefixes, "."] - self.run_test(cmake_bin, cc_options) + with working_dir(test_dir): + cmake = self.spec["cmake"].command + cmake("-DCMAKE_PREFIX_PATH=" + self.spec["rocm-clang-ocl"].prefix, ".") + make = which("make") make() - make("clean") diff --git a/var/spack/repos/builtin/packages/rocm-cmake/package.py b/var/spack/repos/builtin/packages/rocm-cmake/package.py index cf7a5a16036f56..21cab81467347b 100644 --- a/var/spack/repos/builtin/packages/rocm-cmake/package.py +++ b/var/spack/repos/builtin/packages/rocm-cmake/package.py @@ -13,7 +13,7 @@ class RocmCmake(CMakePackage): homepage = "https://github.com/ROCm/rocm-cmake" git = "https://github.com/ROCm/rocm-cmake.git" - url = "https://github.com/ROCm/rocm-cmake/archive/rocm-5.6.0.tar.gz" + url = "https://github.com/ROCm/rocm-cmake/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") @@ -21,6 +21,9 @@ class RocmCmake(CMakePackage): license("MIT") version("master", branch="master") + version("6.1.2", sha256="0757bb90f25d6f1e6bc93bdd1e238f76bbaddf154d66f94f37e40c425dc6d259") + version("6.1.1", sha256="0eb81245f7573a3cadf9e91a854d9a0a014ce93610e4e7ea4d8309867a470bf6") + version("6.1.0", sha256="8b37d458e801b486521f12d18ca2103125173dd0f1130d37c8c36e795d34772b") version("6.0.2", sha256="7bd3ff971b1a898b8cf06b0ed9fac45891e2523ae651c3194ba36050ab45f869") version("6.0.0", sha256="82bd97ba23d1883ef38bb667e92f7367fedc50d6c11c82f54cced4ab04b0412d") version("5.7.1", sha256="4a4c6aa09576ccb834f869bdcb49e98cc0f0bac3678b802358065d1179a9d6f1") @@ -29,20 +32,29 @@ class RocmCmake(CMakePackage): version("5.6.0", sha256="a118ca937856a4d0039955a8aef2466ef1fd1f08f7f7221cda53e1b5d02e476a") version("5.5.1", sha256="60113412b35d94e20e8100ed3db688c35801991b4b8fa282fdc6fd6fd413fb6e") version("5.5.0", sha256="b7884c346737eba70ae11044e41598b2482a92e21f3e0719b1ca11619f02a20b") - version("5.4.3", sha256="c185b3a10d191d73b76770ca0f9d6bdc355ee91fe0c9016a3779c9cfe042ba0f") - version("5.4.0", sha256="617faa9a1e51db3c7a59bd0393e054ab67e57be357d59cb0cd9b677f47824946") - version("5.3.3", sha256="3e527f99db52e301ab4f1b994029585951e2ae685f0cdfb7b8529c72f4b77af4") - version("5.3.0", sha256="659a8327f13e6786103dd562d3632e89a51244548fca081f46c753857cf09d04") with default_args(deprecated=True): - version("5.2.3", sha256="c63b707ec07d24fda5a2a6fffeda4df4cc04ceea5df3b8822cbe4e6600e358b4") - version("5.2.1", sha256="3d179496fb8f5f96230f736a313990f66705dc91fd10948a3042b495a440bf63") - version("5.2.0", sha256="be8646c4f7babfe9a103c97d0e9f369322f8ac6cfa528edacdbdcf7f3ef44943") - version("5.1.3", sha256="19b2da0d56300aab454655b57435ab3ed9e101ecb96561336ea8865bbd993c23") - version("5.1.0", sha256="2eff47b7cf5bd56d465ff3c110eb936d31860df60182a82ba511ba11bbcf23fc") + version("5.4.3", sha256="c185b3a10d191d73b76770ca0f9d6bdc355ee91fe0c9016a3779c9cfe042ba0f") + version("5.4.0", sha256="617faa9a1e51db3c7a59bd0393e054ab67e57be357d59cb0cd9b677f47824946") + version("5.3.3", sha256="3e527f99db52e301ab4f1b994029585951e2ae685f0cdfb7b8529c72f4b77af4") + version("5.3.0", sha256="659a8327f13e6786103dd562d3632e89a51244548fca081f46c753857cf09d04") + + depends_on("cxx", type="build") # generated depends_on("cmake@3.6:", type="build") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") test_src_dir = "test" @@ -51,19 +63,15 @@ class RocmCmake(CMakePackage): def cache_test_sources(self): """Copy the tests source files after the package is installed to an install test subdirectory for use during `spack test run`.""" - if self.spec.satisfies("@:5.1.0"): - return self.cache_extra_test_sources([self.test_src_dir]) - def test(self): - if self.spec.satisfies("@:5.1.0"): - print("Skipping: stand-alone tests") - return + def test_cmake(self): + """Test cmake""" test_dir = join_path(self.test_suite.current_test_cache_dir, self.test_src_dir) with working_dir(test_dir, create=True): - cmake_bin = join_path(self.spec["cmake"].prefix.bin, "cmake") prefixes = ";".join([self.spec["rocm-cmake"].prefix]) cc_options = ["-DCMAKE_PREFIX_PATH=" + prefixes, "."] - self.run_test(cmake_bin, cc_options) + cmake = which(self.spec["cmake"].prefix.bin.cmake) + cmake(*cc_options) make() make("clean") diff --git a/var/spack/repos/builtin/packages/rocm-core/package.py b/var/spack/repos/builtin/packages/rocm-core/package.py index 868556c58598f4..c57faf1bd21aaf 100644 --- a/var/spack/repos/builtin/packages/rocm-core/package.py +++ b/var/spack/repos/builtin/packages/rocm-core/package.py @@ -20,6 +20,9 @@ class RocmCore(CMakePackage): libraries = ["librocm-core"] license("MIT") + version("6.1.2", sha256="ce9cbe12977f2058564ecb4cdcef4fd0d7880f6eff8591630f542441092f4fa3") + version("6.1.1", sha256="a27bebdd1ba9d387f33b82a67f64c55cb565b482fe5017d5b5726d68da1ab839") + version("6.1.0", sha256="9dfe542d1647c42993b06f594c316dad63ba6d6fb2a7398bd72c5768fd1d7b5b") version("6.0.2", sha256="04f01dca2862f0bf781de8afb74aabefc3c9b1d9f01bc8cadb2eb3d7395119cc") version("6.0.0", sha256="d950ee4b63336f34579b6e1dda2d05966b7afa9c84bcdc13874991d1147dc788") version("5.7.1", sha256="fc4915019ddfd126e8ef6a15006bce3aa7bd5fd11dc8eb04ce2ee6bdf9c6ae7f") @@ -29,6 +32,8 @@ class RocmCore(CMakePackage): version("5.5.1", sha256="bc73060432ffdc2e210394835d383890b9652476074ef4708d447473f273ce76") version("5.5.0", sha256="684d3312bb14f05dc280cf136f5eddff38ba340cd85c383d6a217d8e27d3d57d") + depends_on("cxx", type="build") # generated + def cmake_args(self): args = [self.define("ROCM_VERSION", self.spec.version)] return args diff --git a/var/spack/repos/builtin/packages/rocm-dbgapi/package.py b/var/spack/repos/builtin/packages/rocm-dbgapi/package.py index 2d935c9fa19255..baca1f2b9f19e4 100644 --- a/var/spack/repos/builtin/packages/rocm-dbgapi/package.py +++ b/var/spack/repos/builtin/packages/rocm-dbgapi/package.py @@ -16,7 +16,7 @@ class RocmDbgapi(CMakePackage): homepage = "https://github.com/ROCm/ROCdbgapi" git = "https://github.com/ROCm/ROCdbgapi.git" - url = "https://github.com/ROCm/ROCdbgapi/archive/rocm-6.0.0.tar.gz" + url = "https://github.com/ROCm/ROCdbgapi/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") @@ -25,6 +25,9 @@ class RocmDbgapi(CMakePackage): license("MIT") version("master", branch="amd-master") + version("6.1.2", sha256="6e55839e3d95c2cfe3ff89e3e31da77aeecc74012a17f5308589e8808df78026") + version("6.1.1", sha256="425a6cf6a3942c2854c1f5e7717bed906cf6c3753b46c44476f54bfef6188dac") + version("6.1.0", sha256="0985405b6fd44667a7ce8914aa39a7e651613e037e649fbdbfa2adcf744a2d50") version("6.0.2", sha256="39036f083de421f46afd8d3a8799576242ef64002643d7185767ccbba41ae854") version("6.0.0", sha256="4e823eba255e46b93aff05fd5938ef2a51693ffd74debebffc1aabfce613805c") version("5.7.1", sha256="0ee9c2f083868849f2ea0cec7010e0270c27e7679ccbbadd12072cc0ef6c8a6f") @@ -33,26 +36,18 @@ class RocmDbgapi(CMakePackage): version("5.6.0", sha256="9b66e47f4eccb3c8bbc324aade92aac6139539dda449427b7823d0c45341afc8") version("5.5.1", sha256="c41dfc62591bcf42003fe744d8bd03a51311d54e4b012f946ca0ede0c14dd977") version("5.5.0", sha256="ce572340a3fe99e4f1538eb614933153456003f8dfe9306a5735cdd25b451e25") - version("5.4.3", sha256="d647c9121a50f2c54367c567d8f39a145cb135e1ceed931581659f57f49f61e5") - version("5.4.0", sha256="895eb7056864daada40c3f9cd37645b0bdf4b6dc408b5f8cc974fc4cd9ab7ccb") - version("5.3.3", sha256="3c81cb23fe671d391557a63c13b6a13d4dc367db5cb5de55592a6758284d8a3f") - version("5.3.0", sha256="afffec78e34fe70952cd41efc3d7ba8f64e43acb2ad20aa35c9b8b591bed48ca") with default_args(deprecated=True): - version("5.2.3", sha256="17925d23f614ecb2b40dffe5e14535cba380d4f489ea1a027762c356be9fbc2b") - version("5.2.1", sha256="169e3914ebd99d6a5c034c568964b7bad56611262e292f77c0c65a7708e02376") - version("5.2.0", sha256="44f0528a7583bc59b6585166d2289970b20115c4c70e3bcc218aff19fc242b3f") - version("5.1.3", sha256="880f80ebf741e3451676837f720551e02cffd0b9346ca4dfa6cf7f7043282f2b") - version("5.1.0", sha256="406db4b20bda12f6f32cbef88b03110aa001bf7bef6676f36e909b53c8354e43") + version("5.4.3", sha256="d647c9121a50f2c54367c567d8f39a145cb135e1ceed931581659f57f49f61e5") + version("5.4.0", sha256="895eb7056864daada40c3f9cd37645b0bdf4b6dc408b5f8cc974fc4cd9ab7ccb") + version("5.3.3", sha256="3c81cb23fe671d391557a63c13b6a13d4dc367db5cb5de55592a6758284d8a3f") + version("5.3.0", sha256="afffec78e34fe70952cd41efc3d7ba8f64e43acb2ad20aa35c9b8b591bed48ca") + + depends_on("cxx", type="build") # generated depends_on("cmake@3:", type="build") depends_on("hwdata", when="@5.5.0:") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -65,12 +60,27 @@ class RocmDbgapi(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", ]: depends_on(f"hsa-rocr-dev@{ver}", type="build", when=f"@{ver}") depends_on(f"comgr@{ver}", type=("build", "link"), when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") @classmethod diff --git a/var/spack/repos/builtin/packages/rocm-debug-agent/package.py b/var/spack/repos/builtin/packages/rocm-debug-agent/package.py index e07e6b965880c3..a40c9523ab6b8f 100644 --- a/var/spack/repos/builtin/packages/rocm-debug-agent/package.py +++ b/var/spack/repos/builtin/packages/rocm-debug-agent/package.py @@ -13,11 +13,14 @@ class RocmDebugAgent(CMakePackage): homepage = "https://github.com/ROCm/rocr_debug_agent" git = "https://github.com/ROCm/rocr_debug_agent.git" - url = "https://github.com/ROCm/rocr_debug_agent/archive/rocm-6.0.0.tar.gz" + url = "https://github.com/ROCm/rocr_debug_agent/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") libraries = ["librocm-debug-agent"] + version("6.1.2", sha256="c7cb779915a3d61e39d92cef172997bcf5eae720308f6d9c363a2cbc71b5621c") + version("6.1.1", sha256="c631281b346bab9ec3607c59404f548f7cba084a05e9c9ceb3c3579c48361ad1") + version("6.1.0", sha256="f52700563e490d662b505693d485272d73521aabff306107586dd1149fb4a70e") version("6.0.2", sha256="da8da1241a6cbb9d0b2a3b81829faf632225a7a27ca881c9715b9f05bca54c89") version("6.0.0", sha256="705be2c2bd0f5c7d1e286eb9b94045b2bd017ff323f07bca9aa7c81f2d168524") version("5.7.1", sha256="3b8d2835935da98f41e7cfc5b808c596ac06dd705b9a07bb70283e002f8dea6a") @@ -26,26 +29,18 @@ class RocmDebugAgent(CMakePackage): version("5.6.0", sha256="0bed788f07906afeb9092d0bec184a7963233ac9d8ccd20b4afeb624a1d20698") version("5.5.1", sha256="1bb66734f11bb57df6efa507f0217651446653bf28b3ca36acfcf94511a7c2bc") version("5.5.0", sha256="4f2431a395a77a06dc417ed1e9188731b031a0c680e62c6eee19d60965317f5a") - version("5.4.3", sha256="b2c9ac198ea3cbf35e7e80f57c5d81c461de78b821d07b637ea4037a65cdf49f") - version("5.4.0", sha256="94bef73ea0a6d385dab2292ee591ca1dc268a5585cf9f1b5092a1530949f575e") - version("5.3.3", sha256="7170312d08e91334ee03586aa1f23d67f33d9ec0df25a5556cbfa3f210b15b06") - version("5.3.0", sha256="8dfb6aa442ce136207c0c089321c8099042395977b4a488e4ca219661df0cd78") with default_args(deprecated=True): - version("5.2.3", sha256="5d31372e2980738271ae26b92dcc402c387cdf5f23710ce6feeb2bd303ff7ea0") - version("5.2.1", sha256="a60c224c546a25dafcff1e50ce3a1605e152efdb36624a672ddb5812cd34773e") - version("5.2.0", sha256="f8e8d5ad691033d0c0f1850d69f35c98ba9722ab4adc66c4251f22257f56f0a2") - version("5.1.3", sha256="ef26130829f3348d503669467ab1ea39fb67d943d88d64e7ac04b9617ec6067d") - version("5.1.0", sha256="e0ceeef575d8645385bc6e4c9c3accaa192a93c42d83545cf5626c848f59806b") + version("5.4.3", sha256="b2c9ac198ea3cbf35e7e80f57c5d81c461de78b821d07b637ea4037a65cdf49f") + version("5.4.0", sha256="94bef73ea0a6d385dab2292ee591ca1dc268a5585cf9f1b5092a1530949f575e") + version("5.3.3", sha256="7170312d08e91334ee03586aa1f23d67f33d9ec0df25a5556cbfa3f210b15b06") + version("5.3.0", sha256="8dfb6aa442ce136207c0c089321c8099042395977b4a488e4ca219661df0cd78") + + depends_on("cxx", type="build") # generated depends_on("cmake@3:", type="build") depends_on("elfutils@:0.168", type="link") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -58,20 +53,16 @@ class RocmDebugAgent(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") depends_on(f"hsakmt-roct@{ver}", when=f"@{ver}") + depends_on(f"rocm-dbgapi@{ver}", when=f"@{ver}") + depends_on(f"hip@{ver}", when=f"@{ver}") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", - "5.3.0", - "5.3.3", - "5.4.0", - "5.4.3", "5.5.0", "5.5.1", "5.6.0", @@ -80,11 +71,9 @@ class RocmDebugAgent(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.2", ]: - depends_on(f"rocm-dbgapi@{ver}", when=f"@{ver}") - depends_on(f"hip@{ver}", when=f"@{ver}") - - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") # https://github.com/ROCm/rocr_debug_agent/pull/4 @@ -102,10 +91,5 @@ def determine_version(cls, lib): def cmake_args(self): spec = self.spec - args = [] - - if spec.satisfies("@:5.1"): - args.append(self.define("CMAKE_MODULE_PATH", spec["hip"].prefix.cmake)) - elif spec.satisfies("@5.2.0:"): - args.append(self.define("CMAKE_MODULE_PATH", spec["hip"].prefix.lib.cmake.hip)) + args = [self.define("CMAKE_MODULE_PATH", spec["hip"].prefix.lib.cmake.hip)] return args diff --git a/var/spack/repos/builtin/packages/rocm-device-libs/package.py b/var/spack/repos/builtin/packages/rocm-device-libs/package.py index dc89c38db020e0..9e7774d39f4fd1 100644 --- a/var/spack/repos/builtin/packages/rocm-device-libs/package.py +++ b/var/spack/repos/builtin/packages/rocm-device-libs/package.py @@ -12,12 +12,22 @@ class RocmDeviceLibs(CMakePackage): homepage = "https://github.com/ROCm/ROCm-Device-Libs" git = "https://github.com/ROCm/ROCm-Device-Libs.git" - url = "https://github.com/ROCm/ROCm-Device-Libs/archive/rocm-6.0.2.tar.gz" + + def url_for_version(self, version): + if version <= Version("6.0.2"): + url = "https://github.com/ROCm/ROCm-Device-Libs/archive/rocm-{0}.tar.gz" + else: + url = "https://github.com/ROCm/llvm-project/archive/rocm-{0}.tar.gz" + return url.format(version) + tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath", "haampie") version("master", branch="amd-stg-open") + version("6.1.2", sha256="300e9d6a137dcd91b18d5809a316fddb615e0e7f982dc7ef1bb56876dff6e097") + version("6.1.1", sha256="f1a67efb49f76a9b262e9735d3f75ad21e3bd6a05338c9b15c01e6c625c4460d") + version("6.1.0", sha256="6bd9912441de6caf6b26d1323e1c899ecd14ff2431874a2f5883d3bc5212db34") version("6.0.2", sha256="c6d88b9b46e39d5d21bd5a0c1eba887ec473a370b1ed0cebd1d2e910eedc5837") version("6.0.0", sha256="198df4550d4560537ba60ac7af9bde31d59779c8ec5d6309627f77a43ab6ef6f") version("5.7.1", sha256="703de8403c0bd0d80f37c970a698f10f148daf144d34f982e4484d04f7c7bbef") @@ -26,16 +36,15 @@ class RocmDeviceLibs(CMakePackage): version("5.6.0", sha256="efb5dcdca9b3a9fbe408d494fb4a23e0b78417eb5fa8eebd4a5d226088f28921") version("5.5.1", sha256="3b5f6dd85f0e3371f6078da7b59bf77d5b210e30f1cc66ef1e2de6bbcb775833") version("5.5.0", sha256="5ab95aeb9c8bed0514f96f7847e21e165ed901ed826cdc9382c14d199cbadbd3") - version("5.4.3", sha256="f4f7281f2cea6d268fcc3662b37410957d4f0bc23e0df9f60b12eb0fcdf9e26e") - version("5.4.0", sha256="d68813ded47179c39914c8d1b76af3dad8c714b10229d1e2246af67609473951") - version("5.3.3", sha256="963c9a0561111788b55a8c3b492e2a5737047914752376226c97a28122a4d768") - version("5.3.0", sha256="f7e1665a1650d3d0481bec68252e8a5e68adc2c867c63c570f6190a1d2fe735c") with default_args(deprecated=True): - version("5.2.3", sha256="16b7fc7db4759bd6fb54852e9855fa16ead76c97871d7e1e9392e846381d611a") - version("5.2.1", sha256="e5855387ce73ed483ed0d03dbfef31f297c6ca66cf816f6816fd5ee373fc8225") - version("5.2.0", sha256="901674bc941115c72f82c5def61d42f2bebee687aefd30a460905996f838e16c") - version("5.1.3", sha256="c41958560ec29c8bf91332b9f668793463904a2081c330c0d828bf2f91d4f04e") - version("5.1.0", sha256="47dbcb41fb4739219cadc9f2b5f21358ed2f9895ce786d2f7a1b2c4fd044d30f") + version("5.4.3", sha256="f4f7281f2cea6d268fcc3662b37410957d4f0bc23e0df9f60b12eb0fcdf9e26e") + version("5.4.0", sha256="d68813ded47179c39914c8d1b76af3dad8c714b10229d1e2246af67609473951") + version("5.3.3", sha256="963c9a0561111788b55a8c3b492e2a5737047914752376226c97a28122a4d768") + version("5.3.0", sha256="f7e1665a1650d3d0481bec68252e8a5e68adc2c867c63c570f6190a1d2fe735c") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated depends_on("cmake@3.13.4:", type="build") @@ -49,11 +58,6 @@ class RocmDeviceLibs(CMakePackage): depends_on("llvm-amdgpu ~rocm-device-libs") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -66,13 +70,35 @@ class RocmDeviceLibs(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", ]: depends_on(f"llvm-amdgpu@{ver}", when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") + @property + def root_cmakelists_dir(self): + if self.spec.satisfies("@:6.0"): + return "." + else: + return join_path("amd", "device-libs") + def cmake_args(self): spec = self.spec return [ diff --git a/var/spack/repos/builtin/packages/rocm-gdb/package.py b/var/spack/repos/builtin/packages/rocm-gdb/package.py index 9d0cb0bb174b10..210b1301032b94 100644 --- a/var/spack/repos/builtin/packages/rocm-gdb/package.py +++ b/var/spack/repos/builtin/packages/rocm-gdb/package.py @@ -12,12 +12,15 @@ class RocmGdb(AutotoolsPackage): based on GDB, the GNU source-level debugger.""" homepage = "https://github.com/ROCm/ROCgdb" - url = "https://github.com/ROCm/ROCgdb/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/ROCgdb/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] license("LGPL-2.0-or-later") maintainers("srekolam", "renjithravindrankannath") + version("6.1.2", sha256="19208de18d503e1da79dc0c9085221072a68e299f110dc836204364fa1b532cc") + version("6.1.1", sha256="3d982abc130a286d227948aca5783f2e4507ef4275be21dad0914e37217ba19e") + version("6.1.0", sha256="e90d855ca4c1478acf143d45ff0811e7ecd068711db155de6d5f3593cdef6230") version("6.0.2", sha256="69b7c3d63435e7d99088980498c68422e52b69244d10a3a62541633e733286e0") version("6.0.0", sha256="0db4ab32ca729e69688cdb238df274ce5cf58b5cb2538584662cca4358708c2b") version("5.7.1", sha256="5cd150b5796aea9d77efd43b89d30a34fa4125338179eb87c6053abcac9f3c62") @@ -26,16 +29,15 @@ class RocmGdb(AutotoolsPackage): version("5.6.0", sha256="997ef1883aac2769552bc7082c70b837f4e98b57d24c133cea52b9c92fb0dee1") version("5.5.1", sha256="359258548bc7e6abff16bb13c301339fb96560b2b961433c9e0712e4aaf2d9e1") version("5.5.0", sha256="d3b100e332facd9635e328f5efd9f0565250edbe05be986baa2e0470a19bcd79") - version("5.4.3", sha256="28c1ce39fb1fabe61f86f6e3c6940c10f9a8b8de77f7bb4fdd73b04e172f85f6") - version("5.4.0", sha256="7ee984d99818da04733030b140c1f0929639bc719a5e418d53cc2c2a8cbc9a79") - version("5.3.3", sha256="9fc3ccd9378ad40f2f0c9577bc400cc9a202d0ae4656378813b67653b9023c46") - version("5.3.0", sha256="402537baf0779cae586d608505e81173ba85f976fe993f1633e3afe81669350f") with default_args(deprecated=True): - version("5.2.3", sha256="c2df5cccd8bb07ea331b45091fb3141999a37a67696d273f3888b48f6d4281aa") - version("5.2.1", sha256="77169d88f24e6ccb6aef3945448b179edffe806a51a3e996236b08fb510f3979") - version("5.2.0", sha256="70c5b443292b9bb114844eb63b72cfab1b65f083511ee39d55db7a633c63bf5a") - version("5.1.3", sha256="81f5e368facdcc424a37cb5809f0b436bedb9a6d9af4d17785b3c446ab0a7821") - version("5.1.0", sha256="cf638149b269f838aaec59c5801098b9c0fc42f6c86a39309a8995b56978b424") + version("5.4.3", sha256="28c1ce39fb1fabe61f86f6e3c6940c10f9a8b8de77f7bb4fdd73b04e172f85f6") + version("5.4.0", sha256="7ee984d99818da04733030b140c1f0929639bc719a5e418d53cc2c2a8cbc9a79") + version("5.3.3", sha256="9fc3ccd9378ad40f2f0c9577bc400cc9a202d0ae4656378813b67653b9023c46") + version("5.3.0", sha256="402537baf0779cae586d608505e81173ba85f976fe993f1633e3afe81669350f") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated depends_on("cmake@3:", type="build") depends_on("texinfo", type="build") @@ -47,13 +49,9 @@ class RocmGdb(AutotoolsPackage): depends_on("zlib-api", type="link") depends_on("babeltrace@1.2.4", type="link") depends_on("gmp", type=("build", "link")) + depends_on("mpfr", type=("build", "link")) for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -66,11 +64,26 @@ class RocmGdb(AutotoolsPackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"rocm-dbgapi@{ver}", type="link", when=f"@{ver}") depends_on(f"comgr@{ver}", type="link", when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/rocm-opencl/package.py b/var/spack/repos/builtin/packages/rocm-opencl/package.py index fbef90f3845cc3..ea6e3779bfb384 100644 --- a/var/spack/repos/builtin/packages/rocm-opencl/package.py +++ b/var/spack/repos/builtin/packages/rocm-opencl/package.py @@ -5,6 +5,7 @@ import os import re +import sys from spack.package import * @@ -35,6 +36,9 @@ def url_for_version(self, version): license("MIT") version("master", branch="main") + version("6.1.2", sha256="1a1e21640035d957991559723cd093f0c7e202874423667d2ba0c7662b01fea4") + version("6.1.1", sha256="2db02f335c9d6fa69befcf7c56278e5cecfe3db0b457eaaa41206c2585ef8256") + version("6.1.0", sha256="49b23eef621f4e8e528bb4de8478a17436f42053a2f7fde21ff221aa683205c7") version("6.0.2", sha256="cb8ac610c8d4041b74fb3129c084f1e7b817ce1a5a9943feca1fa7531dc7bdcc") version("6.0.0", sha256="798b55b5b5fb90dd19db54f136d8d8e1da9ae1e408d5b12b896101d635f97e50") version("5.7.1", sha256="c78490335233a11b4d8a5426ace7417c555f5e2325de10422df06c0f0f00f7eb") @@ -43,16 +47,14 @@ def url_for_version(self, version): version("5.6.0", sha256="52ab260d00d279c2a86c353901ffd88ee61b934ad89e9eb480f210656705f04e") version("5.5.1", sha256="a8a62a7c6fc5398406d2203b8cb75621a24944688e545d917033d87de2724498") version("5.5.0", sha256="0df9fa0b8aa0c8e6711d34eec0fdf1ed356adcd9625bc8f1ce9b3e72090f3e4f") - version("5.4.3", sha256="b0f8339c844a2e62773bd85cd1e7c5ecddfe71d7c8e8d604e1a1d60900c30873") - version("5.4.0", sha256="a294639478e76c75dac0e094b418f9bd309309b07faf6af126cdfad9aab3c5c7") - version("5.3.3", sha256="cab394e6ef16c35bab8de29a66b96a7dc0e7d1297aaacba3718fa1d369233c9f") - version("5.3.0", sha256="d251e2efe95dc12f536ce119b2587bed64bbda013969fa72be58062788044a9e") with default_args(deprecated=True): - version("5.2.3", sha256="932ea3cd268410010c0830d977a30ef9c14b8c37617d3572a062b5d4595e2b94") - version("5.2.1", sha256="eb4ff433f8894ca659802f81792646034f8088b47aca6ad999292bcb8d6381d5") - version("5.2.0", sha256="80f73387effdcd987a150978775a87049a976aa74f5770d4420847b004dd59f0") - version("5.1.3", sha256="44a7fac721abcd93470e1a7e466bdea0c668c253dee93e4f1ea9a72dbce4ba31") - version("5.1.0", sha256="362d81303048cf7ed5d2f69fb65ed65425bc3da4734fff83e3b8fbdda51b0927") + version("5.4.3", sha256="b0f8339c844a2e62773bd85cd1e7c5ecddfe71d7c8e8d604e1a1d60900c30873") + version("5.4.0", sha256="a294639478e76c75dac0e094b418f9bd309309b07faf6af126cdfad9aab3c5c7") + version("5.3.3", sha256="cab394e6ef16c35bab8de29a66b96a7dc0e7d1297aaacba3718fa1d369233c9f") + version("5.3.0", sha256="d251e2efe95dc12f536ce119b2587bed64bbda013969fa72be58062788044a9e") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("cmake@3:", type="build") depends_on("gl@4.5:", type="link") @@ -67,11 +69,6 @@ def url_for_version(self, version): ("5.4.0", "46a1579310b3ab9dc8948d0fb5bed4c6b312f158ca76967af7ab69e328d43138"), ("5.3.3", "f8133a5934f9c53b253d324876d74f08a19e2f5b073bc94a62fe64b0d2183a18"), ("5.3.0", "2bf14116b5e2270928265f5d417b3d0f0f2e13cbc8ec5eb8c80d4d4a58ff7e94"), - ("5.2.3", "0493c414d4db1af8e1eb30a651d9512044644244488ebb13478c2138a7612998"), - ("5.2.1", "465ca9fa16869cd89dab8c2d66d9b9e3c14f744bbedaa1d215b0746d77a500ba"), - ("5.2.0", "37f5fce04348183bce2ece8bac1117f6ef7e710ca68371ff82ab08e93368bafb"), - ("5.1.3", "ddee63cdc6515c90bab89572b13e1627b145916cb8ede075ef8446cbb83f0a48"), - ("5.1.0", "f4f265604b534795a275af902b2c814f416434d9c9e16db81b3ed5d062187dfa"), ]: resource( name="rocclr", @@ -82,15 +79,23 @@ def url_for_version(self, version): placement="rocclr", when=f"@{d_version}", ) + # For avx build, the start address of values_ buffer in KernelParameters is not + # correct as it is computed based on 16-byte alignment. + patch( + "https://github.com/ROCm/clr/commit/c4f773db0b4ccbbeed4e3d6c0f6bff299c2aa3f0.patch?full_index=1", + sha256="5bb9b0e08888830ccf3a0a658529fe25f4ee62b5b8890f349bf2cc914236eb2f", + when="@5.7:6.0", + ) + patch( + "https://github.com/ROCm/clr/commit/7868876db742fb4d44483892856a66d2993add03.patch?full_index=1", + sha256="7668b2a710baf4cb063e6b00280fb75c4c3e0511575e8298a9c7ae5143f60b33", + when="@5.7:6.0", + ) + # Patch to set package installation path for OpenCL. patch("0001-fix-build-error-rocm-opencl-5.1.0.patch", when="@5.1") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -103,12 +108,31 @@ def url_for_version(self, version): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", ]: depends_on(f"comgr@{ver}", type="build", when=f"@{ver}") depends_on(f"hsa-rocr-dev@{ver}", type="link", when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in ["6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: + depends_on(f"aqlprofile@{ver}", type="link", when=f"@{ver}") + + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: + depends_on(f"rocm-core@{ver}", when=f"@{ver}") @classmethod @@ -144,13 +168,15 @@ def post_install(self): with open(join_path(vendor_config_path, config_file_name), "w") as f: f.write("libamdocl64.so") - test_src_dir = "tests/ocltst" + def test_ocltst(self): + """Run ocltst checks""" + test_dir = "tests/ocltst" if sys.platform == "win32" else "share/opencl/ocltst" + + os.environ["LD_LIBRARY_PATH"] += os.pathsep + join_path(self.prefix, test_dir) + + ocltst = which(join_path(self.prefix, test_dir, "ocltst")) + with test_part(self, "test_ocltst_runtime", purpose="check runtime"): + ocltst("-m", "liboclruntime.so", "-A", "oclruntime.exclude") - def test(self): - test_dir = join_path(self.spec["rocm-opencl"].prefix, self.test_src_dir) - with working_dir(test_dir, create=True): - os.environ["LD_LIBRARY_PATH"] += os.pathsep + test_dir - args = ["-m", "liboclruntime.so", "-A", "oclruntime.exclude"] - self.run_test("ocltst", args) - args = ["-m", "liboclperf.so", "-A", "oclperf.exclude"] - self.run_test("ocltst", args) + with test_part(self, "test_ocltst_perf", purpose="check perf"): + ocltst("-m", "liboclperf.so", "-A", "oclperf.exclude") diff --git a/var/spack/repos/builtin/packages/rocm-openmp-extras/0001-Linking-hsakmt-libdrm-and-numactl-libraries-6.1.patch b/var/spack/repos/builtin/packages/rocm-openmp-extras/0001-Linking-hsakmt-libdrm-and-numactl-libraries-6.1.patch new file mode 100644 index 00000000000000..03cacf5098150c --- /dev/null +++ b/var/spack/repos/builtin/packages/rocm-openmp-extras/0001-Linking-hsakmt-libdrm-and-numactl-libraries-6.1.patch @@ -0,0 +1,29 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index e8b5696..939a30b 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -122,7 +122,9 @@ find_path ( + ${CMAKE_BINARY_DIR}/runtime/src + ) + +-include_directories(${LIBOMPTARGET_INCLUDE_DIR} ${LIBOMP_OMP_TOOLS_INCLUDE_DIR}) ++include_directories(${LIBOMPTARGET_INCLUDE_DIR} ${LIBOMP_OMP_TOOLS_INCLUDE_DIR} ${HSAKMT_INC_PATH}) ++link_directories(${HSAKMT_LIB64} ${HSAKMT_LIB} ${LIBDRM_LIB} ${NUMACTL_DIR}/lib) ++ + + # Various LLVM_TOOLS are needed to build libomptarget + find_package(LLVM QUIET CONFIG PATHS +diff --git a/DeviceRTL/CMakeLists.txt b/DeviceRTL/CMakeLists.txt +index 66ccb43..6094d65 100644 +--- a/DeviceRTL/CMakeLists.txt ++++ b/DeviceRTL/CMakeLists.txt +@@ -13,6 +13,9 @@ + set(LIBOMPTARGET_BUILD_DEVICERTL_BCLIB TRUE CACHE BOOL + "Can be set to false to disable building this library.") + ++include_directories(${LIBOMPTARGET_INCLUDE_DIR} ${LIBOMP_OMP_TOOLS_INCLUDE_DIR} ${HSAKMT_INC_PATH}) ++link_directories(${HSAKMT_LIB64} ${HSAKMT_LIB} ${LIBDRM_LIB} ${NUMACTL_DIR}/lib) ++ + if (NOT LIBOMPTARGET_BUILD_DEVICERTL_BCLIB) + libomptarget_say("Not building DeviceRTL: Disabled by LIBOMPTARGET_BUILD_DEVICERTL_BCLIB") + return() diff --git a/var/spack/repos/builtin/packages/rocm-openmp-extras/package.py b/var/spack/repos/builtin/packages/rocm-openmp-extras/package.py index 597c0820a22b6a..21eca97fc5f959 100644 --- a/var/spack/repos/builtin/packages/rocm-openmp-extras/package.py +++ b/var/spack/repos/builtin/packages/rocm-openmp-extras/package.py @@ -15,11 +15,6 @@ # For example array[0] = 3.9.0, array[1] = 3.10.0, etc. aomp = [ - "e69fe0c933cb30daafe49d9f1df71fe16f387e0287bba921995feeefdf9ac262", - "8bab3d621343f419b29043ac0cb56e062f114991dc3ec1e33e786f771deecc8f", - "20e21312816272222d1f427ea72a99a9a67077078552f5e2638a40860d161d25", - "c0aa6997e889d6ce0e37cfa6a2e91c5c0b54cda1673abdcabcf34da1ba78ba72", - "4ba1792095427588c484feed01f2f48e66aaad26bc000cbc74a15032551699e7", "371ed037b95b83fac64fb2ff2fc17313fe7d3befc8671f0a08f0e2072393fa5b", "c86141fcde879fc78d06a41ba6a26ff528da539c6a1be8b714f635182c66e3f4", "bbca540897848fa95fd0f14fc05ab6deda31299a061424972d5e2bc09c7543dc", @@ -32,14 +27,12 @@ "ed7bbf92230b6535a353ed032a39a9f16e9987397798100392fc25e40c8a1a4e", "1b2c0934ef16e17b2377944fae8c9b3db6dc64b7e43932ddfe2eeefdf6821410", "d6e13a15d5d25990d4bacbac8fabe2eb07973829f2e69abbc628e0736f95caf9", + "832b7c48149a730619b577a2863b8d1bf1b2551eda5b815e1865a044929ab9fa", + "62a5036a2299ed2e3053ee00b7ea1800469cd545fea486fa17266a8b3acfaf5d", + "3de1c7a31a88c3f05a6a66ba6854ac8fdad1ce44462e561cb1e6ad59629029ce", ] devlib = [ - "47dbcb41fb4739219cadc9f2b5f21358ed2f9895ce786d2f7a1b2c4fd044d30f", - "c41958560ec29c8bf91332b9f668793463904a2081c330c0d828bf2f91d4f04e", - "901674bc941115c72f82c5def61d42f2bebee687aefd30a460905996f838e16c", - "e5855387ce73ed483ed0d03dbfef31f297c6ca66cf816f6816fd5ee373fc8225", - "16b7fc7db4759bd6fb54852e9855fa16ead76c97871d7e1e9392e846381d611a", "f7e1665a1650d3d0481bec68252e8a5e68adc2c867c63c570f6190a1d2fe735c", "963c9a0561111788b55a8c3b492e2a5737047914752376226c97a28122a4d768", "d68813ded47179c39914c8d1b76af3dad8c714b10229d1e2246af67609473951", @@ -52,14 +45,12 @@ "703de8403c0bd0d80f37c970a698f10f148daf144d34f982e4484d04f7c7bbef", "198df4550d4560537ba60ac7af9bde31d59779c8ec5d6309627f77a43ab6ef6f", "c6d88b9b46e39d5d21bd5a0c1eba887ec473a370b1ed0cebd1d2e910eedc5837", + "6bd9912441de6caf6b26d1323e1c899ecd14ff2431874a2f5883d3bc5212db34", + "f1a67efb49f76a9b262e9735d3f75ad21e3bd6a05338c9b15c01e6c625c4460d", + "300e9d6a137dcd91b18d5809a316fddb615e0e7f982dc7ef1bb56876dff6e097", ] llvm = [ - "db5d45c4a7842a908527c1b7b8d4a40c688225a41d23cfa382eab23edfffdd10", - "d236a2064363c0278f7ba1bb2ff1545ee4c52278c50640e8bb2b9cfef8a2f128", - "0f892174111b78a02d1a00f8f46d9f80b9abb95513a7af38ecf2a5a0882fe87f", - "3644e927d943d61e22672422591c47a62ff83e3d87ced68439822156d8f79abf", - "1b852711aec3137b568fb65f93606d37fdcd62e06f5da3766f2ffcd4e0c646df", "4e3fcddb5b8ea8dcaa4417e0e31a9c2bbdc9e7d4ac3401635a636df32905c93e", "5296d5e474811c7d1e456cb6d5011db248b79b8d0512155e8a6c2aa5b5f12d38", "ff54f45a17723892cd775c1eaff9e5860527fcfd33d98759223c70e3362335bf", @@ -72,14 +63,12 @@ "6b54c422e45ad19c9bf5ab090ec21753e7f7d854ca78132c30eb146657b168eb", "c673708d413d60ca8606ee75c77e9871b6953c59029c987b92f2f6e85f683626", "7d35acc84de1adee65406f92a369a30364703f84279241c444cd93a48c7eeb76", + "6bd9912441de6caf6b26d1323e1c899ecd14ff2431874a2f5883d3bc5212db34", + "f1a67efb49f76a9b262e9735d3f75ad21e3bd6a05338c9b15c01e6c625c4460d", + "300e9d6a137dcd91b18d5809a316fddb615e0e7f982dc7ef1bb56876dff6e097", ] flang = [ - "d95e36f3b93097ab6fb319c744ddc71cd94af0c358accc1e5224c2bbd431266d", - "d7847b5c6e1344dc0b4723dbe76a859257b4c242644dedb34e425f07738530d4", - "20f48cac9b58496230fa2428eba4e15ec0a6e92d429569b154a328b7a8c5da17", - "012a9c10a7d2a248dc40510e2f5c02a54b5f6bc39961500dc48b6780dac5ad67", - "496f00918721c72eae0bd926a5a8f1f35bd443f6b22bc08e2a42c67e44a4dbaf", "ef1256ddf6cd9de10a1b88df4736dce48295136983a7e31eadd942fb39b156f7", "ddccd866d0c01086087fe21b5711668f85bcf9cbd9f62853f8bda32eaedb5339", "fae8195a5e1b3778e31dbc6cbeedeae9998ea4b5a54215534af41e91fdcb8ba0", @@ -92,14 +81,12 @@ "8fd618d81af092416b267c4d00c801731f7a00c0f8d4aedb795e52a4ec1bf183", "fcb319ddb2aa3004a6ae60370ab4425f529336b1cee50f29200e697e61b53586", "8e6469415880bb068d788596b3ed713a24495eb42788f98cca92e73a2998f703", + "51ecd2c154568c971f5b46ff0e1e1b57063afe28d128fc88c503de88f7240267", + "1bcaa73e73a688cb092f01987cf3ec9ace4aa1fcaab2b812888c610722c4501d", + "12418ea61cca58811b7e75fd9df48be568b406f84a489a41ba5a1fd70c47f7ba", ] extras = [ - "c3a2a83d8f586ee765df96a692ebe010631446f700273fa31738ea260dfc35f7", - "2e3151a47d77166d071213af2a1691487691aae0abd5c1718d818a6d7d09cb2d", - "817c2e8975e56a8875ff56f9d1ea34d5e7e50f1b541b7f1236e3e5c8d9eee47f", - "8b738225f0be39f27bba64c014816cfa1b79f2c7cf2d0e31fbc0fffb6c26e429", - "f42ca7d85b0b64e6890502f1cf8309ef97f707829876742da2ea5c2cdf3ad8ac", "b3beee383d9c130666c230595c950bdc2ce4c7a99d728b9ddf1bca3963152223", "b26b9f4b11a9ccfab53d0dd55aada7e5b98f7ab51981cb033b376321dd44bf87", "2546becd4b182d1e366f47660c731c8ff7366b6306782f04706b6a7bf4e2094c", @@ -112,14 +99,12 @@ "8060c6879708faf5f7d417b19a479dec9b7b9583a1b885f12d247faf831f7f0b", "f37e1107e4da5b083e794244f3d0c9fd073ccb6fd6015e635349d8f0d679c4b8", "b2e117d703cefdc2858adaeee5bad95e9b6dab6263a9c13891a79a7b1e2defb6", + "57d6d9d26c0cb6ea7f8373996c41165f463ae7936d32e5793822cfae03900f8f", + "3dc837fbfcac64e000e1b5518e4f8a6b260eaf1a3e74152d8b8c22f128f575b7", + "2b9351fdb1cba229669233919464ae906ca8f70910c6fa508a2812b7c3bed123", ] versions = [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -132,6 +117,9 @@ "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ] versions_dict = dict() # type: Dict[str,Dict[str,str]] components = ["aomp", "devlib", "llvm", "flang", "extras"] @@ -149,12 +137,15 @@ class RocmOpenmpExtras(Package): """OpenMP support for ROCm LLVM.""" homepage = tools_url + "/aomp" - url = tools_url + "/aomp/archive/rocm-6.0.2.tar.gz" + url = tools_url + "/aomp/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] license("Apache-2.0") maintainers("srekolam", "renjithravindrankannath", "estewart08") + version("6.1.2", sha256=versions_dict["6.1.2"]["aomp"]) + version("6.1.1", sha256=versions_dict["6.1.1"]["aomp"]) + version("6.1.0", sha256=versions_dict["6.1.0"]["aomp"]) version("6.0.2", sha256=versions_dict["6.0.2"]["aomp"]) version("6.0.0", sha256=versions_dict["6.0.0"]["aomp"]) version("5.7.1", sha256=versions_dict["5.7.1"]["aomp"]) @@ -163,15 +154,16 @@ class RocmOpenmpExtras(Package): version("5.6.0", sha256=versions_dict["5.6.0"]["aomp"]) version("5.5.1", sha256=versions_dict["5.5.1"]["aomp"]) version("5.5.0", sha256=versions_dict["5.5.0"]["aomp"]) - version("5.4.3", sha256=versions_dict["5.4.3"]["aomp"]) - version("5.4.0", sha256=versions_dict["5.4.0"]["aomp"]) - version("5.3.3", sha256=versions_dict["5.3.3"]["aomp"]) - version("5.3.0", sha256=versions_dict["5.3.0"]["aomp"]) - version("5.2.3", sha256=versions_dict["5.2.3"]["aomp"], deprecated=True) - version("5.2.1", sha256=versions_dict["5.2.1"]["aomp"], deprecated=True) - version("5.2.0", sha256=versions_dict["5.2.0"]["aomp"], deprecated=True) - version("5.1.3", sha256=versions_dict["5.1.3"]["aomp"], deprecated=True) - version("5.1.0", sha256=versions_dict["5.1.0"]["aomp"], deprecated=True) + version("5.4.3", sha256=versions_dict["5.4.3"]["aomp"], deprecated=True) + version("5.4.0", sha256=versions_dict["5.4.0"]["aomp"], deprecated=True) + version("5.3.3", sha256=versions_dict["5.3.3"]["aomp"], deprecated=True) + version("5.3.0", sha256=versions_dict["5.3.0"]["aomp"], deprecated=True) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") depends_on("cmake@3:", type="build") depends_on("py-setuptools", type="build") @@ -183,15 +175,22 @@ class RocmOpenmpExtras(Package): depends_on("libdrm", when="@5.7:6.0") depends_on("numactl", when="@5.7:6.0") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -219,6 +218,40 @@ class RocmOpenmpExtras(Package): placement="rocm-device-libs", when=f"@{ver}", ) + resource( + name="flang", + url=f"{tools_url}/flang/archive/rocm-{ver}.tar.gz", + sha256=versions_dict[ver]["flang"], + expand=True, + destination="rocm-openmp-extras", + placement="flang", + when=f"@{ver}", + ) + + resource( + name="aomp-extras", + url=f"{tools_url}/aomp-extras/archive/rocm-{ver}.tar.gz", + sha256=versions_dict[ver]["extras"], + expand=True, + destination="rocm-openmp-extras", + placement="aomp-extras", + when=f"@{ver}", + ) + + resource( + name="llvm-project", + url=f"{compute_url}/llvm-project/archive/rocm-{ver}.tar.gz", + sha256=versions_dict[ver]["llvm"], + expand=True, + destination="rocm-openmp-extras", + placement="llvm-project", + when=f"@{ver}", + ) + for ver in ["6.1.0", "6.1.1", "6.1.2"]: + depends_on(f"hsakmt-roct@{ver}", when=f"@{ver}") + depends_on(f"comgr@{ver}", when=f"@{ver}") + depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") + depends_on(f"llvm-amdgpu@{ver}", when=f"@{ver}") resource( name="flang", @@ -250,6 +283,11 @@ class RocmOpenmpExtras(Package): when=f"@{ver}", ) patch("0001-Linking-hsakmt-libdrm-and-numactl-libraries.patch", when="@5.7:6.0") + patch( + "0001-Linking-hsakmt-libdrm-and-numactl-libraries-6.1.patch", + working_dir="rocm-openmp-extras/llvm-project/openmp/libomptarget", + when="@6.1", + ) def setup_run_environment(self, env): devlibs_prefix = self.spec["llvm-amdgpu"].prefix @@ -270,6 +308,14 @@ def setup_build_environment(self, env): llvm_prefix = self.spec["llvm-amdgpu"].prefix env.set("AOMP", "{0}".format(llvm_prefix)) env.set("FC", "{0}/bin/flang".format(openmp_extras_prefix)) + if self.spec.satisfies("+asan"): + env.set("SANITIZER", 1) + env.set("VERBOSE", 1) + env.set( + "LDSHARED", + self.spec["llvm-amdgpu"].prefix.bin.clang + + " -shared -Wl,-O1 -Wl,-Bsymbolic-functions -Wl,-z,relro -g -fwrapv -O2", + ) gfx_list = "gfx700 gfx701 gfx801 gfx803 gfx900 gfx902 gfx906 gfx908" if self.spec.version >= Version("4.3.1"): @@ -278,7 +324,6 @@ def setup_build_environment(self, env): def patch(self): src = self.stage.source_path - aomp_extras = "{0}/rocm-openmp-extras/aomp-extras/aomp-device-libs" libomptarget = "{0}/rocm-openmp-extras/llvm-project/openmp/libomptarget" flang = "{0}/rocm-openmp-extras/flang/" @@ -291,6 +336,23 @@ def patch(self): aomp_extras.format(src) + "/aompextras/CMakeLists.txt", libomptarget.format(src) + "/deviceRTLs/amdgcn/CMakeLists.txt", ) + if self.spec.satisfies("@6.1"): + filter_file( + r"${HSAKMT_LIB_PATH}", + "${HSAKMT_LIB_PATH} ${HSAKMT_LIB64}" + + "${HSAKMT_LIB} ${LIBDRM_LIB} ${NUMACTL_DIR}/lib", + libomptarget.format(src) + "/CMakeLists.txt", + ) + filter_file( + r"${LIBOMPTARGET_LLVM_INCLUDE_DIRS}", + "${LIBOMPTARGET_LLVM_INCLUDE_DIRS} ${HSAKMT_INC_PATH}", + libomptarget.format(src) + "/../CMakeLists.txt", + ) + filter_file( + r"${LIBOMPTARGET_LLVM_INCLUDE_DIRS}", + "${LIBOMPTARGET_LLVM_INCLUDE_DIRS} ${HSAKMT_INC_PATH}", + libomptarget.format(src) + "/CMakeLists.txt", + ) # Openmp adjustments # Fix relocation error with libffi by not using static lib. @@ -306,13 +368,6 @@ def patch(self): libomptarget.format(src) + "/deviceRTLs/amdgcn/CMakeLists.txt", ) - if self.spec.version <= Version("5.1.3"): - filter_file( - r"{ROCM_DIR}/amdgcn/bitcode", - "{DEVICE_LIBS_DIR}", - libomptarget.format(src) + "/deviceRTLs/libm/CMakeLists.txt", - ) - filter_file( "-nogpulib", "-nogpulib -nogpuinc", @@ -388,10 +443,13 @@ def install(self, spec, prefix): gfx_list = gfx_list.replace(" ", ";") openmp_extras_prefix = self.spec["rocm-openmp-extras"].prefix devlibs_prefix = self.spec["llvm-amdgpu"].prefix - devlibs_src = "{0}/rocm-openmp-extras/rocm-device-libs".format(src) + if self.spec.satisfies("@6.1:"): + devlibs_src = "{0}/rocm-openmp-extras/llvm-project/amd/device-libs".format(src) + else: + devlibs_src = "{0}/rocm-openmp-extras/rocm-device-libs".format(src) hsa_prefix = self.spec["hsa-rocr-dev"].prefix hsakmt_prefix = self.spec["hsakmt-roct"].prefix - if self.spec.satisfies("@5.7:6.0"): + if self.spec.satisfies("@5.7:6.1"): libdrm_prefix = self.spec["libdrm"].prefix numactl_prefix = self.spec["numactl"].prefix comgr_prefix = self.spec["comgr"].prefix @@ -471,7 +529,7 @@ def install(self, spec, prefix): "-DNEW_BC_PATH=1", "-DHSA_INCLUDE={0}/include/hsa".format(hsa_prefix), ] - if self.spec.satisfies("@5.7:6.0"): + if self.spec.satisfies("@5.7:6.1"): openmp_common_args += [ "-DLIBDRM_LIB={0}/lib".format(libdrm_prefix), "-DHSAKMT_INC_PATH={0}/include".format(hsakmt_prefix), diff --git a/var/spack/repos/builtin/packages/rocm-smi-lib/package.py b/var/spack/repos/builtin/packages/rocm-smi-lib/package.py index 7d50af78db0997..0675f774b58f1f 100644 --- a/var/spack/repos/builtin/packages/rocm-smi-lib/package.py +++ b/var/spack/repos/builtin/packages/rocm-smi-lib/package.py @@ -17,13 +17,16 @@ class RocmSmiLib(CMakePackage): homepage = "https://github.com/ROCm/rocm_smi_lib" git = "https://github.com/ROCm/rocm_smi_lib.git" - url = "https://github.com/ROCm/rocm_smi_lib/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rocm_smi_lib/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") libraries = ["librocm_smi64"] version("master", branch="master") + version("6.1.2", sha256="01f46fb1cb8c7a16a4c4db61871ee710ed37c0f8bd3a2dbe3415d3de2dffb4ef") + version("6.1.1", sha256="7fd2234b05eb6b9397c5508bb37e81fb16ce2cadc2c97298b2124b46c3687880") + version("6.1.0", sha256="d1a1b372489b27cb7eb8c91d74a71370ad9668dd5aaf89c0267172534e417e41") version("6.0.2", sha256="61e755d710ff38425df3d262d1ad4c510d52d3c64e3fe15140c2575eba316949") version("6.0.0", sha256="0053b42402fd007e5ca9b3186c70f2c6f1b3026558f328722adadc2838c51309") version("5.7.1", sha256="4d79cb0482b2f801cc7824172743e3dd2b44b9f6784d1ca2e5067f2fbb4ef803") @@ -32,24 +35,42 @@ class RocmSmiLib(CMakePackage): version("5.6.0", sha256="88be875948a29454b8aacced8bb8ad967502a7a074ecbc579ed673c1650a2f7e") version("5.5.1", sha256="37f32350bfaf6c697312628696d1b1d5fd9165f183882759bc6cb9a5d65b9430") version("5.5.0", sha256="0703f49b1c2924cc1d3f613258eabdff1925cb5bcf7cf22bb6b955dd065e4ce8") - version("5.4.3", sha256="34d550272e420684230ceb7845aefcef79b155e51cf9ec55e31fdba2a4ed177b") - version("5.4.0", sha256="4b110c9ec104ec39fc458b1b6f693662ab75395b75ed402b671d8e58c7ae63fe") - version("5.3.3", sha256="c2c2a377c2e84f0c40297a97b6060dddc49183c2771b833ebe91ed98a98e4119") - version("5.3.0", sha256="8f72ad825a021d5199fb73726b4975f20682beb966e0ec31b53132bcd56c5408") with default_args(deprecated=True): - version("5.2.3", sha256="fcf4f75a8daeca81ecb107989712c5f3776ee11e6eed870cb93efbf66ff1c384") - version("5.2.1", sha256="07ad3be6f8c7d3f0a1b8b79950cd7839fb82972cef373dccffdbda32a3aca760") - version("5.2.0", sha256="7bce567ff4e087598eace2cae72d24c98b2bcc93af917eafa61ec9d1e8ef4477") - version("5.1.3", sha256="8a19ce60dc9221545aa50e83e88d8c4be9bf7cde2425cefb13710131dc1d7b1b") - version("5.1.0", sha256="21b31b43015b77a9119cf4c1d4ff3864f9ef1f34e2a52a38f985a3f710dc5f87") + version("5.4.3", sha256="34d550272e420684230ceb7845aefcef79b155e51cf9ec55e31fdba2a4ed177b") + version("5.4.0", sha256="4b110c9ec104ec39fc458b1b6f693662ab75395b75ed402b671d8e58c7ae63fe") + version("5.3.3", sha256="c2c2a377c2e84f0c40297a97b6060dddc49183c2771b833ebe91ed98a98e4119") + version("5.3.0", sha256="8f72ad825a021d5199fb73726b4975f20682beb966e0ec31b53132bcd56c5408") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated variant("shared", default=True, description="Build shared or static library") + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") depends_on("cmake@3:", type="build") depends_on("python@3:", type=("build", "run")) - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") + + patch( + "https://github.com/ROCm/rocm_smi_lib/commit/11f12b86517d0e9868f4d16d74d4e8504c3ba7da.patch?full_index=1", + sha256="62be7262f6e1e71bf82a03f500a424a536638f04e913d0f4b477f60e8e1190fd", + when="@6.1.1:", + ) + patch("disable_pdf_generation_with_doxygen_and_latex.patch", when="@:5.6") def cmake_args(self): @@ -58,6 +79,8 @@ def cmake_args(self): self.define("CMAKE_INSTALL_LIBDIR", "lib"), self.define("BUILD_TESTS", self.run_tests), ] + if self.spec.satisfies("@5.7.0:"): + args.append(self.define_from_variant("ADDRESS_SANITIZER", "asan")) return args @classmethod diff --git a/var/spack/repos/builtin/packages/rocm-smi/package.py b/var/spack/repos/builtin/packages/rocm-smi/package.py deleted file mode 100644 index 4e927b1f01b225..00000000000000 --- a/var/spack/repos/builtin/packages/rocm-smi/package.py +++ /dev/null @@ -1,72 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) - - -import os - -from spack.package import * - - -class RocmSmi(MakefilePackage): - """This tool exposes functionality for clock and temperature - management of your ROCm enabled system - - Note: After ROCm 3.9, this project moved to - https://github.com/ROCm/rocm_smi_lib/tree/master/python_smi_tools - The spack package is called: rocm-smi-lib""" - - homepage = "https://github.com/ROCm/ROC-smi" - url = "https://github.com/ROCm/ROC-smi/archive/rocm-4.1.0.tar.gz" - - maintainers("srekolam", "renjithravindrankannath") - tags = ["rocm"] - - version( - "4.1.0", - sha256="5f9f551f93f673f4b508f47a7f24bce903288ffb08fa9e4c8e0956a4a57865c2", - deprecated=True, - ) - version( - "4.0.0", - sha256="bf8738ae81c0a02d83eb9437b93dc153fb63f659f3b04d454024e30678b43575", - deprecated=True, - ) - version( - "3.10.0", - sha256="b1c7e529e8fcc53fb6b40a4126651da0ab07bcb91faac99519ba9660412ea4ed", - deprecated=True, - ) - version( - "3.9.0", - sha256="af3cc6d5e2296f47b1873339faad2d27cf2f24725771bf34c7f644d20cc6ef3b", - deprecated=True, - ) - version( - "3.8.0", - sha256="248d9bddc3353c74defd57f203df0648278a4613f2af7fb838d92a4bc8de575d", - deprecated=True, - ) - version( - "3.7.0", - sha256="4e34b3b4e409bb89677882f47d9988d56bc2d9bb9893f0712c22a4b73789e06a", - deprecated=True, - ) - version( - "3.5.0", - sha256="4f46e947c415a4ac12b9f6989f15a42afe32551706b4f48476fba3abf92e8e7c", - deprecated=True, - ) - - depends_on("python@3:", type="run") - - def install(self, spec, prefix): - filter_file( - "^#!/usr/bin/python3", - "#!/usr/bin/env {0}".format(os.path.basename(self.spec["python"].command.path)), - "rocm_smi.py", - ) - mkdir(prefix.bin) - copy("rocm_smi.py", prefix.bin) - symlink("rocm_smi.py", prefix.bin.rocm_smi) diff --git a/var/spack/repos/builtin/packages/rocm-tensile/package.py b/var/spack/repos/builtin/packages/rocm-tensile/package.py index e841dea1ba2cc4..9894d524b3fa62 100644 --- a/var/spack/repos/builtin/packages/rocm-tensile/package.py +++ b/var/spack/repos/builtin/packages/rocm-tensile/package.py @@ -13,12 +13,15 @@ class RocmTensile(CMakePackage): homepage = "https://github.com/ROCm/Tensile/" git = "https://github.com/ROCm/Tensile.git" - url = "https://github.com/ROCm/Tensile/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/Tensile/archive/rocm-6.1.1.tar.gz" tags = ["rocm"] license("MIT") maintainers("srekolam", "renjithravindrankannath", "haampie") + version("6.1.2", sha256="6a08190f6d9c8cc76764a68e2dd3e7af4759d4146ddc1c4b3370c7762a6f6d83") + version("6.1.1", sha256="04fd76e6a0e9b7528e61df0721b03c0e977c145a2a1ea331d515c9167d7ac35f") + version("6.1.0", sha256="69bfdc711d3a86e6651b1dcfb2c461c7d3ae574e6d884833d4e07d3e7ad06491") version("6.0.2", sha256="1d8a92422560c1e908fa25fd97a4aa07a96659528a543f77618408ffcfe1f307") version("6.0.0", sha256="5d90add62d1439b7daf0527316e950e454e5d8beefb4f723865fe9ab26c7aa42") version("5.7.1", sha256="9211a51b23c22b7a79e4e494e8ff3c31e90bf21adb8cce260acc57891fb2c917") @@ -27,16 +30,13 @@ class RocmTensile(CMakePackage): version("5.6.0", sha256="383728ecf49def59ab9a7f8a1d1e2eaf8b528e36b461e27030a2aab1a1ed80cb") version("5.5.1", sha256="b65cb7335abe51ba33be9d46a5ede992b4e5932fa33797397899a6bf33a770e9") version("5.5.0", sha256="70fd736d40bb4c3461f07c77ad3ae6c485e3e842671ce9b223d023d836884ae2") - version("5.4.3", sha256="a4c5e62edd33ea6b8528eb3f017a14c28eaa67c540f5c9023f6a245340198b0f") - version("5.4.0", sha256="2da9c1df3c6d9b44afdad621ef59a03389fb1a38a61a8b8bad9c9991b97157eb") - version("5.3.3", sha256="ecb99243edf1cd2bb5e953915a7dae7867c3cdb0cd8ed15b8618aaaeb2bd7b29") - version("5.3.0", sha256="05c546986549154e6c7b4f57a0b3bfd5cb223d2393c206ff1702f89454c832f4") with default_args(deprecated=True): - version("5.2.3", sha256="840698bf2ac62e08ae76c3843f1dad5367ed098d42e6a5fa7953de70642fd2cf") - version("5.2.1", sha256="49582e28f7e14fed6a66c59482a41d3899c1eb8e7aa0ce40a7a2e806dadc536b") - version("5.2.0", sha256="aa6107944482ad278111d11d2e926393423fc70e7e1838574fe7ad9f553bdacf") - version("5.1.3", sha256="87020ca268e3a1ed8853f629839d6497764d862bd70b8775e98de439f6c89f1d") - version("5.1.0", sha256="0ac86a623597152c5b1d8bb5634aad3e55afa51959476aaa5e9869d259ddf375") + version("5.4.3", sha256="a4c5e62edd33ea6b8528eb3f017a14c28eaa67c540f5c9023f6a245340198b0f") + version("5.4.0", sha256="2da9c1df3c6d9b44afdad621ef59a03389fb1a38a61a8b8bad9c9991b97157eb") + version("5.3.3", sha256="ecb99243edf1cd2bb5e953915a7dae7867c3cdb0cd8ed15b8618aaaeb2bd7b29") + version("5.3.0", sha256="05c546986549154e6c7b4f57a0b3bfd5cb223d2393c206ff1702f89454c832f4") + + depends_on("cxx", type="build") # generated tensile_architecture = ( "all", @@ -63,11 +63,6 @@ class RocmTensile(CMakePackage): depends_on(Boost.with_default_variants) for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -80,6 +75,9 @@ class RocmTensile(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"rocm-cmake@{ver}", type="build", when=f"@{ver}") depends_on(f"hip@{ver}", when=f"@{ver}") diff --git a/var/spack/repos/builtin/packages/rocm-validation-suite/005-cleanup-path-reference-donot-download-googletest-yaml.patch b/var/spack/repos/builtin/packages/rocm-validation-suite/005-cleanup-path-reference-donot-download-googletest-yaml.patch deleted file mode 100644 index 2162ac451676c9..00000000000000 --- a/var/spack/repos/builtin/packages/rocm-validation-suite/005-cleanup-path-reference-donot-download-googletest-yaml.patch +++ /dev/null @@ -1,159 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 9ce8b3b..8644d10 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -43,14 +43,12 @@ endif(rocblas_FOUND) - # variables since we will pass them as cmake params appropriately, and - # all find_packages relevant to this build will be in ROCM path hence appending it to CMAKE_PREFIX_PATH - set(ROCM_PATH "/opt/rocm" CACHE PATH "ROCM install path") --set(CMAKE_INSTALL_PREFIX "/opt/rocm" CACHE PATH "CMAKE installation directory") --set(CMAKE_PACKAGING_INSTALL_PREFIX "/opt/rocm" CACHE PATH "Prefix used in built packages") -+set (CMAKE_PACKAGING_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}" ) - list(APPEND CMAKE_PREFIX_PATH "${ROCM_PATH}") --set(ROCR_INC_DIR "${ROCM_PATH}/include" CACHE PATH "Contains header files exported by ROC Runtime" FORCE) --set(ROCR_LIB_DIR "${ROCM_PATH}/lib" CACHE PATH "Contains library files exported by ROC Runtime" FORCE) --set(HIP_INC_DIR "${ROCM_PATH}/hip" ) --set(HIP_INC_DIR "${ROCM_PATH}/hip" CACHE PATH "Contains header files exported by ROC Runtime" FORCE) --set(ROCT_INC_DIR "${ROCM_PATH}/include" CACHE PATH "Contains header files exported by ROC Trunk" FORCE) -+set(ROCR_INC_DIR "${ROCM_PATH}/include" CACHE PATH "Contains header files exported by ROC Runtime") -+set(ROCR_LIB_DIR "${ROCM_PATH}/lib" CACHE PATH "Contains library files exported by ROC Runtime") -+set(HIP_INC_DIR "${ROCM_PATH}/hip" CACHE PATH "Contains header files exported by ROC Runtime") -+set(ROCT_INC_DIR "${ROCM_PATH}/include" CACHE PATH "Contains header files exported by ROC Trunk") - - - # -@@ -162,8 +160,6 @@ set(RVS_ROCBLAS "0" CACHE STRING "1 = use local rocBLAS") - set(RVS_ROCMSMI "0" CACHE STRING "1 = use local rocm_smi_lib") - - set(RVS_LIB_DIR "${CMAKE_BINARY_DIR}/rvslib" CACHE PATH "Contains RVS library") --set(YAML_INC_DIR "${CMAKE_BINARY_DIR}/yaml-src/include" CACHE PATH "Contains header files exported by yaml-cpp") --set(YAML_LIB_DIR "${CMAKE_BINARY_DIR}/yaml-build" CACHE PATH "Contains library files exported by yaml-cpp") - - if (${RVS_OS_TYPE} STREQUAL "centos") - set(ROCT_LIB_DIR "${ROCM_PATH}/lib64" CACHE PATH "Contains library files exported by ROC Trunk") -@@ -207,86 +203,6 @@ if (NOT DEFINED CPACK_GENERATOR ) - endif() - message (STATUS "CPACK_GENERATOR ${CPACK_GENERATOR}" ) - -- --################################################################################ --# Download and unpack yaml-cpp at configure time --configure_file(CMakeYamlDownload.cmake yaml-download/CMakeLists.txt) --execute_process(COMMAND ${CMAKE_COMMAND} -G "${CMAKE_GENERATOR}" . -- RESULT_VARIABLE result -- WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/yaml-download ) --if(result) -- message(FATAL_ERROR "CMake step for yaml-download failed: ${result}") --endif() --execute_process(COMMAND ${CMAKE_COMMAND} --build . -- RESULT_VARIABLE result -- WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/yaml-download ) --if(result) -- message(FATAL_ERROR "Build step for yaml-download failed: ${result}") --endif() --execute_process(COMMAND ${CMAKE_COMMAND} ${CMAKE_BINARY_DIR}/yaml-src -B${CMAKE_BINARY_DIR}/yaml-build -- RESULT_VARIABLE result -- WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/yaml-src ) --if(result) -- message(FATAL_ERROR "Config step for yaml-src failed: ${result}") --endif() -- --add_custom_target(rvs_yaml_target -- DEPENDS ${CMAKE_BINARY_DIR}/yaml-build/libyaml-cpp.a --) -- --add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/yaml-build/libyaml-cpp.a -- COMMAND make -C ${CMAKE_BINARY_DIR}/yaml-build -- WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/yaml-src -- COMMENT "Generating yaml-cpp targets" -- VERBATIM) -- --################################################################################ --## GOOGLE TEST --if(RVS_BUILD_TESTS) -- # Download and unpack googletest at configure time -- configure_file(CMakeGtestDownload.cmake googletest-download/CMakeLists.txt) -- execute_process(COMMAND ${CMAKE_COMMAND} -G "${CMAKE_GENERATOR}" . -- RESULT_VARIABLE result -- WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/googletest-download ) -- if(result) -- message(FATAL_ERROR "CMake step for googletest failed: ${result}") -- endif() -- execute_process(COMMAND ${CMAKE_COMMAND} --build . -- RESULT_VARIABLE result -- WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/googletest-download ) -- if(result) -- message(FATAL_ERROR "Build step for googletest failed: ${result}") -- endif() -- execute_process(COMMAND ${CMAKE_COMMAND} ${CMAKE_BINARY_DIR}/googletest-src -B${CMAKE_BINARY_DIR}/googletest-build -- RESULT_VARIABLE result -- WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/googletest-src ) -- if(result) -- message(FATAL_ERROR "Config step for googletest-src failed: ${result}") -- endif() -- -- add_custom_target(rvs_gtest_target -- DEPENDS ${CMAKE_BINARY_DIR}/googletest-build/lib/libgtest_main.a -- ) -- -- add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/googletest-build/lib/libgtest_main.a -- COMMAND make -C ${CMAKE_BINARY_DIR}/googletest-build -- WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/googletest-src -- COMMENT "Generating googletest targets" -- VERBATIM) -- -- ## Set default unit test framework include path -- if (NOT DEFINED UT_INC) -- set (UT_INC "${CMAKE_BINARY_DIR}/googletest-src/googletest/include") -- message ("UT_INC ${UT_INC}") -- endif () -- -- ## Set default unit test framework include path -- if (NOT DEFINED UT_LIB) -- set (UT_LIB "${CMAKE_BINARY_DIR}/googletest-build/lib") -- message ("UT_LIB ${UT_LIB}") -- endif() -- --endif() - ################################################################################ - ## rocBLAS - -@@ -410,16 +326,16 @@ if (RVS_ROCBLAS EQUAL 1) - set(ROCBLAS_INC_DIR "${CMAKE_BINARY_DIR}/rvs_rblas-src/build/release/rocblas-install") - set(ROCBLAS_LIB_DIR "${CMAKE_BINARY_DIR}/rvs_rblas-src/build/release/rocblas-install/lib/") - else() -- set(ROCBLAS_INC_DIR "${ROCM_PATH}/include") -- set(ROCBLAS_LIB_DIR "${ROCM_PATH}/lib") -+ set(ROCBLAS_INC_DIR "${ROCBLAS_DIR}/include") -+ set(ROCBLAS_LIB_DIR "${ROCBLAS_DIR}/lib") - endif() - - if (RVS_ROCMSMI EQUAL 1) - set(ROCM_SMI_INC_DIR "${CMAKE_BINARY_DIR}/rvs_smi-src/include") - set(ROCM_SMI_LIB_DIR "${CMAKE_BINARY_DIR}/rvs_smi-build") - else() -- set(ROCM_SMI_INC_DIR "${ROCM_PATH}/rocm_smi/include") -- set(ROCM_SMI_LIB_DIR "${ROCM_PATH}/rocm_smi/lib") -+ set(ROCM_SMI_INC_DIR "${ROCM_SMI_DIR}/include") -+ set(ROCM_SMI_LIB_DIR "${ROCM_SMI_DIR}/lib") - endif() - set(ROCM_SMI_LIB "rocm_smi64" CACHE STRING "rocm_smi library name") - -@@ -454,7 +370,7 @@ if (RVS_BUILD_TESTS) - add_subdirectory(testif.so) - endif() - --add_dependencies(rvshelper rvs_bin_folder rvs_doc rvs_yaml_target) -+add_dependencies(rvshelper rvs_bin_folder rvs_doc) - - - add_dependencies(pesm rvslib rvslibrt) -@@ -489,7 +405,7 @@ if (RVS_BUILD_TESTS) - WORKING_DIRECTORY ${CMAKE_BINARY_DIR} - COMMENT "Create the bintest directory" - VERBATIM) -- add_dependencies(rvshelper rvs_bintest_folder rvs_gtest_target) -+ add_dependencies(rvshelper rvs_bintest_folder) - endif() - - add_custom_target(rvs_doc ALL diff --git a/var/spack/repos/builtin/packages/rocm-validation-suite/006-library-path.patch b/var/spack/repos/builtin/packages/rocm-validation-suite/006-library-path.patch deleted file mode 100644 index 229e256f58bc0e..00000000000000 --- a/var/spack/repos/builtin/packages/rocm-validation-suite/006-library-path.patch +++ /dev/null @@ -1,371 +0,0 @@ -diff --git a/babel.so/CMakeLists.txt b/babel.so/CMakeLists.txt -index f4e57c7..fb66263 100644 ---- a/babel.so/CMakeLists.txt -+++ b/babel.so/CMakeLists.txt -@@ -113,13 +113,13 @@ set(ROCBLAS_LIB "rocblas") - set(HIP_HCC_LIB "amdhip64") - - # Determine Roc Runtime header files are accessible --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime_api.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime_api.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - -@@ -139,16 +139,16 @@ if(DEFINED RVS_ROCMSMI) - endif() - - --if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") -- message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) -+if(NOT EXISTS "${HIP_PATH}/lib/lib${HIP_HCC_LIB}.so") -+ message("ERROR: ROC Runtime libraries can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - - ## define include directories --include_directories(./ ../ ${ROCR_INC_DIR} ${HIP_INC_DIR}) -+include_directories(./ ../ ${HIP_PATH}) - - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) -+link_directories(${RVS_LIB_DIR} ${HIP_PATH}/lib/ ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) - ## additional libraries - set (PROJECT_LINK_LIBS rvslibrt rvslib libpthread.so libpci.so libm.so) - -diff --git a/edp.so/CMakeLists.txt b/edp.so/CMakeLists.txt -index 851e24c..3697b4f 100644 ---- a/edp.so/CMakeLists.txt -+++ b/edp.so/CMakeLists.txt -@@ -108,13 +108,13 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${HIP_HCC_BUILD_FLAGS}") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${HIP_HCC_BUILD_FLAGS}") - - # Determine Roc Runtime header files are accessible --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime_api.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime_api.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - -@@ -134,15 +134,15 @@ if(DEFINED RVS_ROCMSMI) - endif() - - --if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") -- message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) -+if(NOT EXISTS "${HIP_PATH}/lib/lib${HIP_HCC_LIB}.so") -+ message("ERROR: ROC Runtime libraries can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - - ## define include directories --include_directories(./ ../ ${ROCR_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_INC_DIR}) -+include_directories(./ ../ ${ROCBLAS_INC_DIR} ${HIP_PATH}) - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR}) -+link_directories(${RVS_LIB_DIR} ${ROCBLAS_LIB_DIR}) - ## additional libraries - set (PROJECT_LINK_LIBS rvslibrt rvslib libpthread.so libpciaccess.so libpci.so libm.so) - -diff --git a/gst.so/CMakeLists.txt b/gst.so/CMakeLists.txt -index 7ce465a..c61c52b 100644 ---- a/gst.so/CMakeLists.txt -+++ b/gst.so/CMakeLists.txt -@@ -117,13 +117,13 @@ else() - endif() - - # Determine Roc Runtime header files are accessible --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime_api.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime_api.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - -@@ -143,15 +143,15 @@ if(DEFINED RVS_ROCMSMI) - endif() - - --if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") -- message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) -+if(NOT EXISTS "${HIP_PATH}/lib/lib${HIP_HCC_LIB}.so") -+ message("ERROR: ROC Runtime libraries can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - - ## define include directories --include_directories(./ ../ ${ROCR_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_INC_DIR}) -+include_directories(./ ../ ${ROCBLAS_INC_DIR} ${HIP_PATH}) - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) -+link_directories(${RVS_LIB_DIR} ${HIP_PATH}/lib/ ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) - ## additional libraries - set (PROJECT_LINK_LIBS rvslibrt rvslib libpthread.so libpci.so libm.so) - -diff --git a/iet.so/CMakeLists.txt b/iet.so/CMakeLists.txt -index 278c084..5ba9007 100644 ---- a/iet.so/CMakeLists.txt -+++ b/iet.so/CMakeLists.txt -@@ -122,13 +122,13 @@ else() - endif() - - # Determine Roc Runtime header files are accessible --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime_api.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime_api.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - -@@ -147,8 +147,8 @@ if(DEFINED RVS_ROCMSMI) - endif() - endif() - --if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") -- message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) -+if(NOT EXISTS "${HIP_PATH}/lib/lib${HIP_HCC_LIB}.so") -+ message("ERROR: ROC Runtime libraries can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - -@@ -162,9 +162,9 @@ if(DEFINED RVS_ROCMSMI) - endif() - - ## define include directories --include_directories(./ ../ ${ROCM_SMI_INC_DIR} ${ROCBLAS_INC_DIR} ${ROCR_INC_DIR} ${HIP_INC_DIR}) -+include_directories(./ ../ ${ROCM_SMI_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_PATH}) - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ROCM_SMI_LIB_DIR} ${ASAN_LIB_PATH}) -+link_directories(${RVS_LIB_DIR} ${HIP_PATH}/lib/ ${ROCBLAS_LIB_DIR} ${ROCM_SMI_LIB_DIR} ${ASAN_LIB_PATH}) - ## additional libraries - set (PROJECT_LINK_LIBS rvslibrt rvslib libpthread.so libpci.so libm.so) - -diff --git a/mem.so/CMakeLists.txt b/mem.so/CMakeLists.txt -index ec1c01d..c8e040a 100644 ---- a/mem.so/CMakeLists.txt -+++ b/mem.so/CMakeLists.txt -@@ -114,13 +114,13 @@ set(ROCBLAS_LIB "rocblas") - set(HIP_HCC_LIB "amdhip64") - - # Determine Roc Runtime header files are accessible --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime_api.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime_api.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - -@@ -140,16 +140,16 @@ if(DEFINED RVS_ROCMSMI) - endif() - - --if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") -- message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) -+if(NOT EXISTS "${HIP_PATH}/lib/lib${HIP_HCC_LIB}.so") -+ message("ERROR: ROC Runtime libraries can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - - ## define include directories --include_directories(./ ../ ${ROCR_INC_DIR} ${HIP_INC_DIR}) -+include_directories(./ ../ ${HIP_PATH}) - - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) -+link_directories(${RVS_LIB_DIR} ${HIP_PATH}/lib/ ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) - ## additional libraries - set (PROJECT_LINK_LIBS rvslibrt rvslib libpthread.so libpci.so libm.so) - -diff --git a/pebb.so/CMakeLists.txt b/pebb.so/CMakeLists.txt -index f88f7c1..f5eb246 100644 ---- a/pebb.so/CMakeLists.txt -+++ b/pebb.so/CMakeLists.txt -@@ -135,20 +135,20 @@ else() - endif() - - # Determine Roc Runtime header files are accessible --if(NOT EXISTS ${ROCR_INC_DIR}/hsa/hsa.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set ROCR_INC_DIR path. Current value is : " ${ROCR_INC_DIR}) -+if(NOT EXISTS ${HSA_PATH}/include/hsa/hsa.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HSA_PATH path. Current value is : " ${HSA_PATH}) - RETURN() - endif() - --if(NOT EXISTS ${ROCR_LIB_DIR}/${CORE_RUNTIME_LIBRARY}.so) -- message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) -+if(NOT EXISTS ${HSA_PATH}/lib/${CORE_RUNTIME_LIBRARY}.so) -+ message("ERROR: ROC Runtime libraries can't be found under specified path. Please set HSA_PATH path. Current value is : " ${HSA_PATH}) - RETURN() - endif() - - ## define include directories --include_directories(./ ../ pci ${ROCR_INC_DIR}) -+include_directories(./ ../ pci ${HSA_PATH}) - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCT_LIB_DIR} ${ASAN_LIB_PATH}) -+link_directories(${RVS_LIB_DIR} ${HSA_PATH}/lib/ ${HSAKMT_LIB_DIR} ${ASAN_LIB_PATH}) - ## additional libraries - set (PROJECT_LINK_LIBS rvslibrt rvslib libpthread.so libpci.so libm.so) - -diff --git a/perf.so/CMakeLists.txt b/perf.so/CMakeLists.txt -index c99b511..35490fc 100644 ---- a/perf.so/CMakeLists.txt -+++ b/perf.so/CMakeLists.txt -@@ -117,13 +117,13 @@ else() - endif() - - # Determine Roc Runtime header files are accessible --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - --if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime_api.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) -+if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime_api.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - -@@ -143,15 +143,15 @@ if(DEFINED RVS_ROCMSMI) - endif() - - --if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") -- message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) -+if(NOT EXISTS "${HIP_PATH}/lib/lib${HIP_HCC_LIB}.so") -+ message("ERROR: ROC Runtime libraries can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) - RETURN() - endif() - - ## define include directories --include_directories(./ ../ ${ROCR_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_INC_DIR}) -+include_directories(./ ../ ${ROCBLAS_INC_DIR} ${HIP_PATH}) - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) -+link_directories(${RVS_LIB_DIR} ${HIP_PATH}/lib/ ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) - ## additional libraries - set (PROJECT_LINK_LIBS rvslibrt rvslib libpthread.so libpci.so libm.so) - -diff --git a/pesm.so/CMakeLists.txt b/pesm.so/CMakeLists.txt -index a887606..9bd797d 100644 ---- a/pesm.so/CMakeLists.txt -+++ b/pesm.so/CMakeLists.txt -@@ -118,7 +118,7 @@ endif() - ## define include directories - include_directories(./ ../ pci) - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) -+link_directories(${RVS_LIB_DIR} ${HSAKMT_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) - ## additional libraries - set (PROJECT_LINK_LIBS libpthread.so libpci.so libm.so) - -diff --git a/pqt.so/CMakeLists.txt b/pqt.so/CMakeLists.txt -index d59b254..7cb3743 100644 ---- a/pqt.so/CMakeLists.txt -+++ b/pqt.so/CMakeLists.txt -@@ -134,20 +134,20 @@ else() - endif() - - # Determine Roc Runtime header files are accessible --if(NOT EXISTS ${ROCR_INC_DIR}/hsa/hsa.h) -- message("ERROR: ROC Runtime headers can't be found under specified path. Please set ROCR_INC_DIR path. Current value is : " ${ROCR_INC_DIR}) -+if(NOT EXISTS ${HSA_PATH}/include/hsa/hsa.h) -+ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HSA_PATH path. Current value is : " ${HSA_PATH}) - RETURN() - endif() - --if(NOT EXISTS ${ROCR_LIB_DIR}/${CORE_RUNTIME_LIBRARY}.so) -- message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) -+if(NOT EXISTS ${HSA_PATH}/lib/${CORE_RUNTIME_LIBRARY}.so) -+ message("ERROR: ROC Runtime libraries can't be found under specified path. Please set HSA_PATH path. Current value is : " ${HSA_PATH}) - RETURN() - endif() - - ## define include directories --include_directories(./ ../ pci ${ROCR_INC_DIR}) -+include_directories(./ ../ pci ${HSA_PATH}) - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCT_LIB_DIR} ${ASAN_LIB_PATH}) -+link_directories(${RVS_LIB_DIR} ${HSA_PATH}/lib/ ${HSAKMT_LIB_DIR} ${ASAN_LIB_PATH}) - ## additional libraries - set (PROJECT_LINK_LIBS rvslibrt rvslib libpthread.so libpci.so libm.so) - -diff --git a/rcqt.so/CMakeLists.txt b/rcqt.so/CMakeLists.txt -index 072c49d..3f00c7a 100644 ---- a/rcqt.so/CMakeLists.txt -+++ b/rcqt.so/CMakeLists.txt -@@ -120,7 +120,7 @@ endif() - ## define include directories - include_directories(./ ../) - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ASAN_LIB_PATH}) -+link_directories(${RVS_LIB_DIR} ${ASAN_LIB_PATH} ${ASAN_LIB_PATH} ${HSAKMT_LIB_DIR}) - ## additional libraries - set (PROJECT_LINK_LIBS rvslibrt rvslib) - -diff --git a/rvslib/CMakeLists.txt b/rvslib/CMakeLists.txt -index 642902c..7acaec4 100644 ---- a/rvslib/CMakeLists.txt -+++ b/rvslib/CMakeLists.txt -@@ -120,7 +120,7 @@ endif() - - ## define include directories - include_directories(./ ../ -- ${ROCM_SMI_INC_DIR} ${ROCR_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_INC_DIR} -+ ${ROCM_SMI_INC_DIR} ${HIP_PATH} ${ROCBLAS_INC_DIR} ${HIP_PATH} - ) - link_directories(${ASAN_LIB_PATH}) - -diff --git a/testif.so/CMakeLists.txt b/testif.so/CMakeLists.txt -index 678c980..53e0aa9 100644 ---- a/testif.so/CMakeLists.txt -+++ b/testif.so/CMakeLists.txt -@@ -119,7 +119,7 @@ endif() - ## define include directories - include_directories(./ ../ pci) - # Add directories to look for library files to link --link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) -+link_directories(${RVS_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) - ## additional libraries - set (PROJECT_LINK_LIBS libpthread.so libpci.so libm.so) - diff --git a/var/spack/repos/builtin/packages/rocm-validation-suite/009-replacing-rocm-path-with-package-path-6.1.patch b/var/spack/repos/builtin/packages/rocm-validation-suite/009-replacing-rocm-path-with-package-path-6.1.patch new file mode 100644 index 00000000000000..422ab6ddc472fd --- /dev/null +++ b/var/spack/repos/builtin/packages/rocm-validation-suite/009-replacing-rocm-path-with-package-path-6.1.patch @@ -0,0 +1,543 @@ +From 18a4feabdac234a1af62ae458be44e24c63017e2 Mon Sep 17 00:00:00 2001 +From: Renjith Ravindran +Date: Mon, 20 May 2024 22:56:55 -0700 +Subject: [PATCH] Updating cmake with include and library path for spack for + 6.1 + +--- + CMakeLists.txt | 22 +++++++++++----------- + babel.so/CMakeLists.txt | 18 +++++++++--------- + cmake_modules/tests_unit.cmake | 3 ++- + edp.so/CMakeLists.txt | 8 ++++---- + gm.so/CMakeLists.txt | 6 +++--- + gpup.so/CMakeLists.txt | 6 +++--- + gst.so/CMakeLists.txt | 8 ++++---- + iet.so/CMakeLists.txt | 6 +++--- + mem.so/CMakeLists.txt | 6 +++--- + pbqt.so/CMakeLists.txt | 6 +++--- + pebb.so/CMakeLists.txt | 4 ++-- + peqt.so/CMakeLists.txt | 6 +++--- + perf.so/CMakeLists.txt | 8 ++++---- + pesm.so/CMakeLists.txt | 6 +++--- + rcqt.so/CMakeLists.txt | 6 +++--- + rvs/CMakeLists.txt | 16 +++++++++------- + rvslib/CMakeLists.txt | 2 +- + smqt.so/CMakeLists.txt | 6 +++--- + testif.so/CMakeLists.txt | 6 +++--- + tst.so/CMakeLists.txt | 2 +- + 20 files changed, 77 insertions(+), 74 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 6bce31b..f7e31c9 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -74,14 +74,14 @@ endif(rocblas_FOUND) + # Making ROCM_PATH, CMAKE_INSTALL_PREFIX, CPACK_PACKAGING_INSTALL_PREFIX as CACHE + # variables since we will pass them as cmake params appropriately, and + # all find_packages relevant to this build will be in ROCM path hence appending it to CMAKE_PREFIX_PATH +-set(ROCM_PATH "/opt/rocm" CACHE PATH "ROCM install path") +-set(CMAKE_INSTALL_PREFIX "/opt/rocm" CACHE PATH "CMAKE installation directory") +-set(CPACK_PACKAGING_INSTALL_PREFIX "/opt/rocm" CACHE PATH "Prefix used in built packages") ++set(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}") ++set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) ++set(CPACK_PACKAGING_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}") + list(APPEND CMAKE_PREFIX_PATH "${ROCM_PATH}") +-set(ROCR_INC_DIR "${ROCM_PATH}/include" CACHE PATH "Contains header files exported by ROC Runtime" FORCE) +-set(ROCR_LIB_DIR "${ROCM_PATH}/lib" CACHE PATH "Contains library files exported by ROC Runtime" FORCE) +-set(HIP_INC_DIR "${ROCM_PATH}" CACHE PATH "Contains header files exported by ROC Runtime") +-set(ROCT_INC_DIR "${ROCM_PATH}/include" CACHE PATH "Contains header files exported by ROC Trunk" FORCE) ++set(ROCR_INC_DIR "${HSA_PATH}/include" CACHE PATH "Contains header files exported by ROC Runtime") ++set(ROCR_LIB_DIR "${HSA_PATH}/lib" CACHE PATH "Contains library files exported by ROC Runtime") ++set(HIP_INC_DIR "${HIP_PATH}" CACHE PATH "Contains header files exported by ROC Runtime") ++set(ROCT_INC_DIR "${ROCM_PATH}/include" CACHE PATH "Contains header files exported by ROC Trunk") + + add_definitions(-DROCM_PATH="${ROCM_PATH}") + if(FETCH_ROCMPATH_FROM_ROCMCORE) +@@ -447,8 +447,8 @@ if (RVS_ROCBLAS EQUAL 1) + set(ROCBLAS_INC_DIR "${CMAKE_BINARY_DIR}/rvs_rblas-src/build/release/rocblas-install") + set(ROCBLAS_LIB_DIR "${CMAKE_BINARY_DIR}/rvs_rblas-src/build/release/rocblas-install/lib/") + else() +- set(ROCBLAS_INC_DIR "${ROCM_PATH}/include") +- set(ROCBLAS_LIB_DIR "${ROCM_PATH}/lib") ++ set(ROCBLAS_INC_DIR "${ROCBLAS_DIR}/include") ++ set(ROCBLAS_LIB_DIR "${ROCBLAS_DIR}/lib") + endif() + + if (RVS_ROCMSMI EQUAL 1) +@@ -463,8 +463,8 @@ else() + set(ROCM_SMI_LIB_DIR "${ROCM_PATH}/rocm_smi/lib") + else() + message( STATUS "ROCBLAS REORG Enabled Version: ${RVS_ROCBLAS_VERSION_FLAT}" ) +- set(ROCM_SMI_INC_DIR "${ROCM_PATH}/include") +- set(ROCM_SMI_LIB_DIR "${ROCM_PATH}/lib") ++ set(ROCM_SMI_INC_DIR "${ROCM_SMI_DIR}/include") ++ set(ROCM_SMI_LIB_DIR "${ROCM_SMI_DIR}/lib") + endif() + endif() + set(ROCM_SMI_LIB "rocm_smi64" CACHE STRING "rocm_smi library name") +diff --git a/babel.so/CMakeLists.txt b/babel.so/CMakeLists.txt +index 54a0e3a..bfa0069 100644 +--- a/babel.so/CMakeLists.txt ++++ b/babel.so/CMakeLists.txt +@@ -109,13 +109,13 @@ set(HIP_HCC_LIB "amdhip64") + add_compile_options(-DRVS_ROCBLAS_VERSION_FLAT=${RVS_ROCBLAS_VERSION_FLAT}) + + # Determine Roc Runtime header files are accessible +-if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime.h) +- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) ++if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime.h) ++ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) + RETURN() + endif() + +-if(NOT EXISTS ${HIP_INC_DIR}/include/hip/hip_runtime_api.h) +- message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_INC_DIR path. Current value is : " ${HIP_INC_DIR}) ++if(NOT EXISTS ${HIP_PATH}/include/hip/hip_runtime_api.h) ++ message("ERROR: ROC Runtime headers can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) + RETURN() + endif() + +@@ -135,16 +135,16 @@ if(DEFINED RVS_ROCMSMI) + endif() + + +-if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") +- message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) ++if(NOT EXISTS "${HIP_PATH}/lib/lib${HIP_HCC_LIB}.so") ++ message("ERROR: ROC Runtime libraries can't be found under specified path. Please set HIP_PATH path. Current value is : " ${HIP_PATH}) + RETURN() + endif() + + ## define include directories +-include_directories(./ ../ ${ROCR_INC_DIR} ${HIP_INC_DIR}) ++include_directories(./ ../ ${HIP_PATH}) + + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${HIP_PATH}/lib/ ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + ## additional libraries + set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so) + +@@ -156,7 +156,7 @@ add_library( ${RVS_TARGET} SHARED ${SOURCES}) + set_target_properties(${RVS_TARGET} PROPERTIES + SUFFIX .so.${LIB_VERSION_STRING} + LIBRARY_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) +-target_link_libraries(${RVS_TARGET} ${PROJECT_LINK_LIBS} ${HIP_HCC_LIB} ${ROCBLAS_LIB}) ++target_link_libraries(${RVS_TARGET} ${PROJECT_LINK_LIBS} ${HIP_HCC_LIB} ${ROCBLAS_LIB} ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + add_dependencies(${RVS_TARGET} rvslib) + + add_custom_command(TARGET ${RVS_TARGET} POST_BUILD +diff --git a/cmake_modules/tests_unit.cmake b/cmake_modules/tests_unit.cmake +index 9760b72..2d3a05b 100644 +--- a/cmake_modules/tests_unit.cmake ++++ b/cmake_modules/tests_unit.cmake +@@ -27,7 +27,7 @@ + ## define additional unit testing include directories + include_directories(${UT_INC}) + ## define additional unit testing lib directories +-link_directories(${UT_LIB} ${RVS_LIB_DIR}) ++link_directories(${UT_LIB} ${RVS_LIB_DIR} ${ROCM_SMI_LIB_DIR}) + + file(GLOB TESTSOURCES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} test/test*.cpp ) + #message ( "TESTSOURCES: ${TESTSOURCES}" ) +@@ -46,6 +46,7 @@ FOREACH(SINGLE_TEST ${TESTSOURCES}) + add_dependencies(${TEST_NAME} rvs_gtest_target) + target_link_libraries(${TEST_NAME} + ${UT_LINK_LIBS} rvslibut rvslib gtest_main gtest pthread pci ++ ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so + ) + target_compile_definitions(${TEST_NAME} PUBLIC RVS_UNIT_TEST) + if(DEFINED tcd.${TEST_NAME}) +diff --git a/edp.so/CMakeLists.txt b/edp.so/CMakeLists.txt +index 7dd34ea..a208bac 100644 +--- a/edp.so/CMakeLists.txt ++++ b/edp.so/CMakeLists.txt +@@ -128,17 +128,17 @@ if(DEFINED RVS_ROCMSMI) + endif() + + +-if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") ++if(NOT EXISTS "${HIP_INC_DIR}/lib/lib${HIP_HCC_LIB}.so") + message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) + RETURN() + endif() + + ## define include directories +-include_directories(./ ../ ${ROCR_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_INC_DIR}) ++include_directories(./ ../ ${ROCR_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_INC_DIR} ${YAML_CPP_INCLUDE_DIRS}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR}) ++link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ROCM_SMI_LIB_DIR}) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib libpthread.so libpciaccess.so libpci.so libm.so) ++set (PROJECT_LINK_LIBS rvslib libpthread.so libpciaccess.so libpci.so libm.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set (SOURCES src/rvs_module.cpp src/action.cpp src/edp_worker.cpp ) +diff --git a/gm.so/CMakeLists.txt b/gm.so/CMakeLists.txt +index d3caa84..73b83ce 100644 +--- a/gm.so/CMakeLists.txt ++++ b/gm.so/CMakeLists.txt +@@ -118,11 +118,11 @@ if(DEFINED RVS_ROCMSMI) + endif() + + ## define include directories +-include_directories(./ ../ ${ROCM_SMI_INC_DIR}) ++include_directories(./ ../ ${ROCM_SMI_INC_DIR} ${YAML_CPP_INCLUDE_DIRS}) + # Add directories to look for library files to link + link_directories(${RVS_LIB_DIR} ${ROCM_SMI_LIB_DIR} ${ASAN_LIB_PATH}) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so) ++set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so librocm_smi64.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set(SOURCES src/rvs_module.cpp src/action.cpp src/worker.cpp) +@@ -133,7 +133,7 @@ add_library( ${RVS_TARGET} SHARED ${SOURCES}) + set_target_properties(${RVS_TARGET} PROPERTIES + SUFFIX .so.${LIB_VERSION_STRING} + LIBRARY_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) +-target_link_libraries(${RVS_TARGET} ${PROJECT_LINK_LIBS} ${ROCM_SMI_LIB}) ++target_link_libraries(${RVS_TARGET} ${PROJECT_LINK_LIBS}) + add_dependencies(${RVS_TARGET} rvslib) + + add_custom_command(TARGET ${RVS_TARGET} POST_BUILD +diff --git a/gpup.so/CMakeLists.txt b/gpup.so/CMakeLists.txt +index 43d337a..9b07004 100644 +--- a/gpup.so/CMakeLists.txt ++++ b/gpup.so/CMakeLists.txt +@@ -109,11 +109,11 @@ else() + endif() + + ## define include directories +-include_directories(./ ../ include ../include) ++include_directories(./ ../ include ../include ${YAML_CPP_INCLUDE_DIRS}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib libpci.so libm.so) ++set (PROJECT_LINK_LIBS rvslib libpci.so libm.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set(SOURCES src/rvs_module.cpp src/action.cpp) +diff --git a/gst.so/CMakeLists.txt b/gst.so/CMakeLists.txt +index fd346ce..0debf98 100644 +--- a/gst.so/CMakeLists.txt ++++ b/gst.so/CMakeLists.txt +@@ -137,17 +137,17 @@ if(DEFINED RVS_ROCMSMI) + endif() + + +-if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") ++if(NOT EXISTS "${HIP_INC_DIR}/lib/lib${HIP_HCC_LIB}.so") + message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) + RETURN() + endif() + + ## define include directories +-include_directories(./ ../ ${ROCR_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_INC_DIR}) ++include_directories(./ ../ ${ROCR_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_INC_DIR} ${YAML_CPP_INCLUDE_DIRS}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${HIP_INC_DIR}/lib/ ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so) ++set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set(SOURCES src/rvs_module.cpp src/action.cpp src/gst_worker.cpp) +diff --git a/iet.so/CMakeLists.txt b/iet.so/CMakeLists.txt +index a85ca98..252e565 100644 +--- a/iet.so/CMakeLists.txt ++++ b/iet.so/CMakeLists.txt +@@ -140,7 +140,7 @@ if(DEFINED RVS_ROCMSMI) + endif() + endif() + +-if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") ++if(NOT EXISTS "${HIP_INC_DIR}/lib/lib${HIP_HCC_LIB}.so") + message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) + RETURN() + endif() +@@ -159,7 +159,7 @@ include_directories(./ ../ ${ROCM_SMI_INC_DIR} ${ROCBLAS_INC_DIR} ${ROCR_INC_DIR + # Add directories to look for library files to link + link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ROCM_SMI_LIB_DIR} ${ASAN_LIB_PATH}) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so) ++set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so librocm_smi64.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + set(SOURCES src/rvs_module.cpp src/action.cpp src/iet_worker.cpp ) + +@@ -168,7 +168,7 @@ add_library( ${RVS_TARGET} SHARED ${SOURCES}) + set_target_properties(${RVS_TARGET} PROPERTIES + SUFFIX .so.${LIB_VERSION_STRING} + LIBRARY_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) +-target_link_libraries(${RVS_TARGET} ${PROJECT_LINK_LIBS} ${HIP_HCC_LIB} ${ROCBLAS_LIB} ${ROCM_SMI_LIB}) ++target_link_libraries(${RVS_TARGET} ${PROJECT_LINK_LIBS} ${HIP_INC_DIR}/lib/ ${HIP_HCC_LIB} ${ROCBLAS_LIB}) + add_dependencies(${RVS_TARGET} rvslib) + + add_custom_command(TARGET ${RVS_TARGET} POST_BUILD +diff --git a/mem.so/CMakeLists.txt b/mem.so/CMakeLists.txt +index 5133337..2462bbc 100644 +--- a/mem.so/CMakeLists.txt ++++ b/mem.so/CMakeLists.txt +@@ -134,7 +134,7 @@ if(DEFINED RVS_ROCMSMI) + endif() + + +-if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") ++if(NOT EXISTS "${HIP_INC_DIR}/lib/lib${HIP_HCC_LIB}.so") + message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) + RETURN() + endif() +@@ -143,9 +143,9 @@ endif() + include_directories(./ ../ ${ROCR_INC_DIR} ${HIP_INC_DIR}) + + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${HIP_INC_DIR}/lib ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so) ++set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set(SOURCES src/rvs_module.cpp src/action.cpp src/rvs_memtest.cpp src/rvs_memworker.cpp) +diff --git a/pbqt.so/CMakeLists.txt b/pbqt.so/CMakeLists.txt +index 5ae675a..892b6ac 100644 +--- a/pbqt.so/CMakeLists.txt ++++ b/pbqt.so/CMakeLists.txt +@@ -136,11 +136,11 @@ if(NOT EXISTS ${ROCR_LIB_DIR}/${CORE_RUNTIME_LIBRARY}.so) + endif() + + ## define include directories +-include_directories(./ ../ pci ${ROCR_INC_DIR}) ++include_directories(./ ../ pci ${ROCR_INC_DIR} ${YAML_CPP_INCLUDE_DIRS}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCT_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${HSAKMT_LIB_DIR} ${ROCT_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so) ++set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set(SOURCES src/rvs_module.cpp src/action.cpp src/action_run.cpp +diff --git a/pebb.so/CMakeLists.txt b/pebb.so/CMakeLists.txt +index c4e2964..7a6b368 100644 +--- a/pebb.so/CMakeLists.txt ++++ b/pebb.so/CMakeLists.txt +@@ -139,9 +139,9 @@ endif() + ## define include directories + include_directories(./ ../ pci ${ROCR_INC_DIR}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCT_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${HSAKMT_LIB_DIR} ${ROCT_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR} ) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so) ++set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set(SOURCES src/rvs_module.cpp src/action.cpp src/action_run.cpp +diff --git a/peqt.so/CMakeLists.txt b/peqt.so/CMakeLists.txt +index ead507d..8623ee9 100644 +--- a/peqt.so/CMakeLists.txt ++++ b/peqt.so/CMakeLists.txt +@@ -107,9 +107,9 @@ else() + endif() + + ## define include directories +-include_directories(./ ../) ++include_directories(./ ../ ${HSA_PATH}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${HSA_PATH}/lib/ ${HSAKMT_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + ## additional libraries + set (PROJECT_LINK_LIBS rvslib libpci.so libm.so) + +@@ -121,7 +121,7 @@ add_library( ${RVS_TARGET} SHARED ${SOURCES}) + set_target_properties(${RVS_TARGET} PROPERTIES + SUFFIX .so.${LIB_VERSION_STRING} + LIBRARY_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) +-target_link_libraries(${RVS_TARGET} ${PROJECT_LINK_LIBS} ) ++target_link_libraries(${RVS_TARGET} ${PROJECT_LINK_LIBS} ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + add_dependencies(${RVS_TARGET} rvslib) + + add_custom_command(TARGET ${RVS_TARGET} POST_BUILD +diff --git a/perf.so/CMakeLists.txt b/perf.so/CMakeLists.txt +index 518dac9..02d2245 100644 +--- a/perf.so/CMakeLists.txt ++++ b/perf.so/CMakeLists.txt +@@ -137,7 +137,7 @@ if(DEFINED RVS_ROCMSMI) + endif() + + +-if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") ++if(NOT EXISTS "${HIP_INC_DIR}/lib/lib${HIP_HCC_LIB}.so") + message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) + RETURN() + endif() +@@ -145,9 +145,9 @@ endif() + ## define include directories + include_directories(./ ../ ${ROCR_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_INC_DIR}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${HIP_INC_DIR}/lib ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so) ++set (PROJECT_LINK_LIBS rvslib libpthread.so libpci.so libm.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set(SOURCES src/rvs_module.cpp src/action.cpp src/perf_worker.cpp) +@@ -157,7 +157,7 @@ add_library( ${RVS_TARGET} SHARED ${SOURCES}) + set_target_properties(${RVS_TARGET} PROPERTIES + SUFFIX .so.${LIB_VERSION_STRING} + LIBRARY_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) +-target_link_libraries(${RVS_TARGET} ${PROJECT_LINK_LIBS} ${HIP_HCC_LIB} ${ROCBLAS_LIB}) ++target_link_libraries(${RVS_TARGET} ${PROJECT_LINK_LIBS}) + add_dependencies(${RVS_TARGET} rvslib) + + add_custom_command(TARGET ${RVS_TARGET} POST_BUILD +diff --git a/pesm.so/CMakeLists.txt b/pesm.so/CMakeLists.txt +index 1f27f34..729fb5f 100644 +--- a/pesm.so/CMakeLists.txt ++++ b/pesm.so/CMakeLists.txt +@@ -107,11 +107,11 @@ else() + endif() + + ## define include directories +-include_directories(./ ../ pci) ++include_directories(./ ../ pci ${YAML_CPP_INCLUDE_DIRS}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + ## additional libraries +-set (PROJECT_LINK_LIBS libpthread.so libpci.so libm.so) ++set (PROJECT_LINK_LIBS libpthread.so libpci.so libm.so ${PROJECT_LINK_LIBS} ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set(SOURCES src/rvs_module.cpp src/action.cpp src/worker.cpp) +diff --git a/rcqt.so/CMakeLists.txt b/rcqt.so/CMakeLists.txt +index c0099ab..8d92982 100644 +--- a/rcqt.so/CMakeLists.txt ++++ b/rcqt.so/CMakeLists.txt +@@ -108,11 +108,11 @@ else() + endif() + + ## define include directories +-include_directories(./ ../) ++include_directories(./ ../ ${YAML_CPP_INCLUDE_DIRS}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${ASAN_LIB_PATH} ${ASAN_LIB_PATH} ${HSAKMT_LIB_DIR} ${ROCM_SMI_LIB_DIR}) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib) ++set (PROJECT_LINK_LIBS rvslib ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set(SOURCES +diff --git a/rvs/CMakeLists.txt b/rvs/CMakeLists.txt +index 3909be8..d55423b 100644 +--- a/rvs/CMakeLists.txt ++++ b/rvs/CMakeLists.txt +@@ -34,6 +34,7 @@ set ( RVS "rvs" ) + set ( RVS_PACKAGE "rvs-roct" ) + set ( RVS_COMPONENT "lib${RVS}" ) + set ( RVS_TARGET "${RVS}" ) ++set ( YAML_CPP_LIBRARIES "${YAML_CPP_LIB_PATH}") + + project ( ${RVS_TARGET} ) + +@@ -115,19 +116,20 @@ endif() + ## define include directories + include_directories(./ ../ ${YAML_CPP_INCLUDE_DIRS}) + ## define lib directories +-link_directories(${CMAKE_CURRENT_BINARY_DIR} ${RVS_LIB_DIR} ${ROCT_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ROCM_SMI_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${CMAKE_CURRENT_BINARY_DIR} ${RVS_LIB_DIR} ${RVS_LIB_DIR}/.. ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR} ${ROCT_LIB_DIR} ${ROCBLAS_LIB_DIR} ${YAML_CPP_LIBRARIES}) + + ## additional libraries +-set(ROCBLAS_LIB "rocblas") +-set(ROC_THUNK_NAME "hsakmt") +-set(CORE_RUNTIME_NAME "hsa-runtime") +-set(CORE_RUNTIME_TARGET "${CORE_RUNTIME_NAME}64") +-set(PROJECT_LINK_LIBS libdl.so libpthread.so libpci.so ${YAML_CPP_LIBRARIES}) ++set(ROCBLAS_LIB "${ROCBLAS_LIB_DIR}/librocblas.so") ++set(ROC_THUNK_NAME "${HSAKMT_LIB_DIR}/libhsakmt.a") ++set(CORE_RUNTIME_NAME "${HSA_PATH}/lib/libhsa-runtime64.so") ++set(YAML_CPP_LIB "${YAML_CPP_LIBRARIES}/libyaml-cpp.a") ++set(CORE_RUNTIME_TARGET "${CORE_RUNTIME_NAME}") ++set(PROJECT_LINK_LIBS libdl.so libpthread.so libpci.so) + + ## define target + add_executable(${RVS_TARGET} src/rvs.cpp) + target_link_libraries(${RVS_TARGET} rvslib +- ${ROCBLAS_LIB} ${ROCM_SMI_LIB} ${ROC_THUNK_NAME} ${CORE_RUNTIME_TARGET} ${ROCM_CORE} ${PROJECT_LINK_LIBS}) ++ ${ROCBLAS_LIB} ${ROCM_SMI_LIB} ${ROC_THUNK_NAME} ${CORE_RUNTIME_TARGET} ${ROCM_CORE} ${PROJECT_LINK_LIBS} ${YAML_CPP_LIB}) + add_dependencies(${RVS_TARGET} rvslib) + + install(TARGETS ${RVS_TARGET} +diff --git a/rvslib/CMakeLists.txt b/rvslib/CMakeLists.txt +index 8d29590..e824bdb 100644 +--- a/rvslib/CMakeLists.txt ++++ b/rvslib/CMakeLists.txt +@@ -116,7 +116,7 @@ endif() + + ## define include directories + include_directories(./ ../ ../rvs +- ${ROCM_SMI_INC_DIR} ${ROCR_INC_DIR} ${ROCBLAS_INC_DIR} ${HIP_INC_DIR}) ++ ${ROCM_SMI_INC_DIR} ${HIP_PATH} ${ROCBLAS_INC_DIR} ${YAML_CPP_INCLUDE_DIRS}) + + link_directories(${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + +diff --git a/smqt.so/CMakeLists.txt b/smqt.so/CMakeLists.txt +index 042586f..0133c00 100644 +--- a/smqt.so/CMakeLists.txt ++++ b/smqt.so/CMakeLists.txt +@@ -106,11 +106,11 @@ else() + endif() + + ## define include directories +-include_directories(./ ../ pci) ++include_directories(./ ../ pci ${YAML_CPP_INCLUDE_DIRS}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + ## additional libraries +-set (PROJECT_LINK_LIBS rvslib libpci.so libm.so) ++set (PROJECT_LINK_LIBS rvslib libpci.so libm.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + set(SOURCES src/rvs_module.cpp src/action.cpp) +diff --git a/testif.so/CMakeLists.txt b/testif.so/CMakeLists.txt +index 4cba0f9..691534a 100644 +--- a/testif.so/CMakeLists.txt ++++ b/testif.so/CMakeLists.txt +@@ -108,11 +108,11 @@ endif() + + + ## define include directories +-include_directories(./ ../ pci) ++include_directories(./ ../ pci ${YAML_CPP_INCLUDE_DIRS}) + # Add directories to look for library files to link +-link_directories(${RVS_LIB_DIR} ${ROCR_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH}) ++link_directories(${RVS_LIB_DIR} ${ROCBLAS_LIB_DIR} ${ASAN_LIB_PATH} ${ROCM_SMI_LIB_DIR}) + ## additional libraries +-set (PROJECT_LINK_LIBS libpthread.so libpci.so libm.so) ++set (PROJECT_LINK_LIBS libpthread.so libpci.so libm.so ${ROCBLAS_LIB_DIR}/librocblas.so ${HSAKMT_LIB_DIR}/libhsakmt.a ${HSA_PATH}/lib/libhsa-runtime64.so) + + ## define source files + ## set(SOURCES src/rvs_module.cpp src/action.cpp src/worker.cpp) +diff --git a/tst.so/CMakeLists.txt b/tst.so/CMakeLists.txt +index 1a1a8b0..0ca398d 100644 +--- a/tst.so/CMakeLists.txt ++++ b/tst.so/CMakeLists.txt +@@ -140,7 +140,7 @@ if(DEFINED RVS_ROCMSMI) + endif() + endif() + +-if(NOT EXISTS "${ROCR_LIB_DIR}/lib${HIP_HCC_LIB}.so") ++if(NOT EXISTS "${HIP_INC_DIR}/lib/lib${HIP_HCC_LIB}.so") + message("ERROR: ROC Runtime libraries can't be found under specified path. Please set ROCR_LIB_DIR path. Current value is : " ${ROCR_LIB_DIR}) + RETURN() + endif() +-- +2.43.0 + diff --git a/var/spack/repos/builtin/packages/rocm-validation-suite/package.py b/var/spack/repos/builtin/packages/rocm-validation-suite/package.py index af95d70c132166..b686e1b3bc3d6a 100644 --- a/var/spack/repos/builtin/packages/rocm-validation-suite/package.py +++ b/var/spack/repos/builtin/packages/rocm-validation-suite/package.py @@ -16,12 +16,15 @@ class RocmValidationSuite(CMakePackage): compatible platform.""" homepage = "https://github.com/ROCm/ROCmValidationSuite" - url = "https://github.com/ROCm/ROCmValidationSuite/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/ROCmValidationSuite/archive/rocm-6.1.1.tar.gz" tags = ["rocm"] license("MIT") maintainers("srekolam", "renjithravindrankannath") + version("6.1.2", sha256="8ff0c4ec538841d6b8d008d3849a99173cc5a02df5cf4a11dc1d52f630e079c5") + version("6.1.1", sha256="72d1a40bce5b68f7d5959e10c07576234640b9c9fcb24d6301a76336629d9962") + version("6.1.0", sha256="712f49bfe3a62c9f9cc6f9dc1c593b57e0b45158bb270d685d1141c9a9e90387") version("6.0.2", sha256="8286d00ce290eeace3697138da9d7a9669f54152e5febcd9e5c5156ae79f0c0c") version("6.0.0", sha256="a84e36b5e50e70ba033fb6bc6fa99da2e32bf7eaef2098df3164365a77a8f14c") version("5.7.1", sha256="202f2b6e014bbbeec40af5d3ec630c042f09a61087a77bd70715d81044ea4d65") @@ -30,19 +33,14 @@ class RocmValidationSuite(CMakePackage): version("5.6.0", sha256="54cc5167055870570c97ee7114f48d24d5415f984e0c9d7b58b83467e0cf18fb") version("5.5.1", sha256="0fbfaa9f68642b590ef04f9778013925bbf3f17bdcd35d4c85a8ffd091169a6e") version("5.5.0", sha256="296add772171db67ab8838d2db1ea56df21e895c0348c038768e40146e4fe86a") - version("5.4.3", sha256="1f0888e559104a4b8c2f5322f7463e425f2baaf12aeb1a8982a5974516e7b667") - version("5.4.0", sha256="ca2abfa739c2853f71453e65787e318ab879be8a6a362c4cb4d27baa90f3cd5f") - version("5.3.3", sha256="9acbc8de9b2e18659f51bd49f6e92ab6c93742e2ed0046322025f017fc12497f") - version("5.3.0", sha256="d6afb8a5f4eaf860fd510bcfe65e735cbf96d4b8817c758ea7aee84d4c994382") with default_args(deprecated=True): - version("5.2.3", sha256="5dfbd41c694bf2eb4368edad8653dc60ec2927d174fc7aaa5fa416156c5f921f") - version("5.2.1", sha256="a0ea3ab9cbb8ac17bfa4537713a4d7075f869949bfdead4565a46f75864bd4a9") - version("5.2.0", sha256="2dfef5d66f544230957ac9aaf647b2f1dccf3cc7592cc322cae9fbdcf3321365") - version("5.1.3", sha256="0140a4128c31749c078d9e1dc863cbbd690efc65843c34a4b80f0056e5b8c7b6") - version("5.1.0", sha256="d9b9771b885bd94e5d0352290d3fe0fa12f94ce3f384c3844002cd7614880010") + version("5.4.3", sha256="1f0888e559104a4b8c2f5322f7463e425f2baaf12aeb1a8982a5974516e7b667") + version("5.4.0", sha256="ca2abfa739c2853f71453e65787e318ab879be8a6a362c4cb4d27baa90f3cd5f") + version("5.3.3", sha256="9acbc8de9b2e18659f51bd49f6e92ab6c93742e2ed0046322025f017fc12497f") + version("5.3.0", sha256="d6afb8a5f4eaf860fd510bcfe65e735cbf96d4b8817c758ea7aee84d4c994382") + + depends_on("cxx", type="build") # generated - patch("005-cleanup-path-reference-donot-download-googletest-yaml.patch", when="@:5.2") - patch("006-library-path.patch", when="@:5.2") patch( "007-cleanup-path-reference-donot-download-googletest-yaml-library-path_5.3.patch", when="@5.3.0:5.5", @@ -52,7 +50,13 @@ class RocmValidationSuite(CMakePackage): when="@5.6", ) patch("008-correcting-library-and-include-path-WITHOUT-RVS-BUILD-TESTS.patch", when="@5.7") + + # Replacing ROCM_PATH with corresponding package prefix path. + # Adding missing package package prefix paths. + # It expects rocm components headers and libraries in /opt/rocm + # It doesn't find package to include the library and include path without this patch. patch("009-replacing-rocm-path-with-package-path.patch", when="@6.0") + patch("009-replacing-rocm-path-with-package-path-6.1.patch", when="@6.1") depends_on("cmake@3.5:", type="build") depends_on("zlib-api", type="link") depends_on("yaml-cpp~shared") @@ -64,11 +68,6 @@ def setup_build_environment(self, build_env): build_env.set("HIPCC_PATH", spec["hip"].prefix) for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -81,6 +80,9 @@ def setup_build_environment(self, build_env): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"rocminfo@{ver}", when=f"@{ver}") @@ -88,18 +90,18 @@ def setup_build_environment(self, build_env): depends_on(f"rocm-smi-lib@{ver}", when=f"@{ver}") def patch(self): - if self.spec.satisfies("@:5.1"): - filter_file( - r"@ROCM_PATH@/rvs", self.spec.prefix.rvs, "rvs/conf/deviceid.sh.in", string=True - ) - elif self.spec.satisfies("@5.2:5.4"): + if self.spec.satisfies("@5.2:5.4"): filter_file( r"@ROCM_PATH@/bin", self.spec.prefix.bin, "rvs/conf/deviceid.sh.in", string=True ) - elif self.spec.satisfies("@5.5:"): + elif self.spec.satisfies("@5.5:5.7"): filter_file( r"@ROCM_PATH@/rvs", self.spec.prefix.rvs, "rvs/conf/deviceid.sh.in", string=True ) + elif self.spec.satisfies("@6.0:"): + filter_file( + "@ROCM_PATH@/rvs", self.spec.prefix.bin, "rvs/conf/deviceid.sh.in", string=True + ) def cmake_args(self): args = [ @@ -108,8 +110,7 @@ def cmake_args(self): self.define("HSA_PATH", self.spec["hsa-rocr-dev"].prefix), self.define("ROCM_SMI_DIR", self.spec["rocm-smi-lib"].prefix), self.define("ROCBLAS_DIR", self.spec["rocblas"].prefix), - self.define("YAML_INC_DIR", self.spec["yaml-cpp"].prefix.include), - self.define("YAML_LIB_DIR", self.spec["yaml-cpp"].prefix.lib64), + self.define("YAML_CPP_INCLUDE_DIRS", self.spec["yaml-cpp"].prefix.include), self.define("UT_INC", self.spec["googletest"].prefix.include), ] libloc = self.spec["googletest"].prefix.lib64 @@ -120,4 +121,8 @@ def cmake_args(self): if not os.path.isdir(libloc): libloc = self.spec["hsakmt-roct"].prefix.lib args.append(self.define("HSAKMT_LIB_DIR", libloc)) + libloc = self.spec["yaml-cpp"].prefix.lib64 + if not os.path.isdir(libloc): + libloc = self.spec["yaml-cpp"].prefix.lib + args.append(self.define("YAML_CPP_LIB_PATH", libloc)) return args diff --git a/var/spack/repos/builtin/packages/rocminfo/package.py b/var/spack/repos/builtin/packages/rocminfo/package.py index ecf57fffdb29d0..f8fcc531707f48 100644 --- a/var/spack/repos/builtin/packages/rocminfo/package.py +++ b/var/spack/repos/builtin/packages/rocminfo/package.py @@ -12,12 +12,15 @@ class Rocminfo(CMakePackage): homepage = "https://github.com/ROCm/rocminfo" git = "https://github.com/ROCm/rocminfo.git" - url = "https://github.com/ROCm/rocminfo/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rocminfo/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath", "haampie") version("master", branch="master") + version("6.1.2", sha256="882ebe3db60b6290a81a98e0bac9b8923fbf83966f1706fd24484700b8213bcc") + version("6.1.1", sha256="ef5e33ad3d0bae462d01e1528ffa9c83c587ccbf7ef5947e096e550480d83819") + version("6.1.0", sha256="973352210fdc65932f0125e2db68729383727eaf4ebb7f52c88a948c14bbbb73") version("6.0.2", sha256="e616d364a48de18eaee661bdce999d095086905f49777663ca99312f40a63da1") version("6.0.0", sha256="bc29f1798644b6dea73895353dffada9db7366d0058274e587ebd3291a4d3844") version("5.7.1", sha256="642dc2ec4254b3c30c43064e6690861486db820b25f4906ec78bdb47e68dcd0b") @@ -26,25 +29,17 @@ class Rocminfo(CMakePackage): version("5.6.0", sha256="87d98a736e4f7510d1475d35717842068d826096a0af7c15a395bcf9d36d7fa0") version("5.5.1", sha256="bcab27bb3595d5a4c981e2416458d169e85c27e603c22e743d9240473bfbe98a") version("5.5.0", sha256="b6107d362b70e20a10911741eb44247139b4eb43489f7fa648daff880b6de37f") - version("5.4.3", sha256="72159eed31f8deee0df9228b9e306a18fe9efdd4d6c0eead871cad4617874170") - version("5.4.0", sha256="79123b92992cce75ae679caf9a6bf57b16d24e96e54b36eb002511f3800e29c6") - version("5.3.3", sha256="77e6adc81da6c1d153517e1d28db774205531a2ec188e6518f998328ef7897c6") - version("5.3.0", sha256="c279da1d946771d120611b64974fde751534e787a394ceb6b8e0b743c143d782") with default_args(deprecated=True): - version("5.2.3", sha256="38fe8db21077100ee2242bd087371f6b8e0078d3a269e145d3a4ab314d0b8902") - version("5.2.1", sha256="e8a3b3228387d164e21de060e18ac018eecb5e9abe0ae45830c51ead4b7f1004") - version("5.2.0", sha256="e721eb81efd384abd22ff01cdcbb6245b11084dc11a867c74c8ad6b028aa0404") - version("5.1.3", sha256="7aecd7b189e129b77c8f2af70be2926a0f3a5ee89814879bc8477924a7e6f2ae") - version("5.1.0", sha256="76f6cc9e69d9fc7e692e5c7db35e89079d3b1d2d47632e4742d612e743c396d3") + version("5.4.3", sha256="72159eed31f8deee0df9228b9e306a18fe9efdd4d6c0eead871cad4617874170") + version("5.4.0", sha256="79123b92992cce75ae679caf9a6bf57b16d24e96e54b36eb002511f3800e29c6") + version("5.3.3", sha256="77e6adc81da6c1d153517e1d28db774205531a2ec188e6518f998328ef7897c6") + version("5.3.0", sha256="c279da1d946771d120611b64974fde751534e787a394ceb6b8e0b743c143d782") + + depends_on("cxx", type="build") # generated depends_on("cmake@3:", type="build") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -57,12 +52,27 @@ class Rocminfo(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", "master", ]: depends_on(f"hsakmt-roct@{ver}", when=f"@{ver}") depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/rocmlir/package.py b/var/spack/repos/builtin/packages/rocmlir/package.py index ad16506d4f0be9..67f40176bb47cc 100644 --- a/var/spack/repos/builtin/packages/rocmlir/package.py +++ b/var/spack/repos/builtin/packages/rocmlir/package.py @@ -14,9 +14,13 @@ class Rocmlir(CMakePackage): homepage = "https://github.com/ROCm/rocMLIR" git = "https://github.com/ROCm/rocMLIR.git" - url = "https://github.com/ROCm/rocMLIR/archive/refs/tags/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rocMLIR/archive/refs/tags/rocm-6.1.2.tar.gz" - maintainers("srekolam") + maintainers("srekolam", "afzpatel", "renjithravindrankannath") + + version("6.1.2", sha256="9bde02b898896301a30e7007e384b9de9cf8feac04f44c91a3b625e74788fda6") + version("6.1.1", sha256="0847fd2325fb287538442cf09daf7fa76e7926a40eafd27049e0b5320371c1b5") + version("6.1.0", sha256="dd800783f1ce66ce7c560d5193d053ddf3797abae5ec9375c9842243f5a8ca0b") version("6.0.2", sha256="6ed039e8045169bb64c10fb063c2e1753b8d52d6d56c60e001c929082be1f20b") version("6.0.0", sha256="128915abdceaf5cef26a717d154f2b2f9466f6904f4490f158038878cedbf618") version("5.5.1", commit="8c29325e7e68e3248e863172bf0e7f97055d45ee") @@ -25,6 +29,10 @@ class Rocmlir(CMakePackage): version("5.4.0", sha256="3823f455ee392118c3281e27d45fa0e5381f3c4070eb4e06ba13bc6b34a90a60") with default_args(deprecated=True): version("5.3.0", sha256="e8471a13cb39d33adff34730d3162adaa5d20f9544d61a6a94b39b9b5762ad6d") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant( "build_type", default="Release", @@ -50,7 +58,19 @@ def patch(self): depends_on("half") depends_on("pkgconfig", type="build") - for ver in ["5.3.0", "5.4.0", "5.4.3", "5.5.0", "5.5.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.3.0", + "5.4.0", + "5.4.3", + "5.5.0", + "5.5.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: + depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"llvm-amdgpu@{ver}", when=f"@{ver}") depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") diff --git a/var/spack/repos/builtin/packages/rocprim/package.py b/var/spack/repos/builtin/packages/rocprim/package.py index f1d37f12e25858..db959c565e9991 100644 --- a/var/spack/repos/builtin/packages/rocprim/package.py +++ b/var/spack/repos/builtin/packages/rocprim/package.py @@ -11,12 +11,15 @@ class Rocprim(CMakePackage): homepage = "https://github.com/ROCm/rocPRIM" git = "https://github.com/ROCm/rocPRIM.git" - url = "https://github.com/ROCm/rocPRIM/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rocPRIM/archive/rocm-6.1.0.tar.gz" tags = ["rocm"] license("MIT") maintainers("cgmb", "srekolam", "renjithravindrankannath") + version("6.1.2", sha256="560b65fffb103c11bee710e4eb871fd47dd84dfe99f5762a19c5650e490fd85d") + version("6.1.1", sha256="94b265b6b4ed366b0ba008ef77ab6623b7b880b45874f202c887f01b67905922") + version("6.1.0", sha256="9f02e5f8be90baa679a28f83927495ddf0e17d684536e1f820021e8c3e8e6c84") version("6.0.2", sha256="d3998720d3206965335902f8f67ca497b320a33b810cd19b2a2264505cb38779") version("6.0.0", sha256="51f26c9f891a64c8db8df51d75d86d404d682092fd9d243e966ac6b2a6de381a") version("5.7.1", sha256="15d820a0f61aed60efbba88b6efe6942878b02d912f523f9cf8f33a4583d6cd7") @@ -25,16 +28,13 @@ class Rocprim(CMakePackage): version("5.6.0", sha256="360d6ece3c4a3c289dd88043432026fb989e982ae4d05230d8cdc858bcd50466") version("5.5.1", sha256="63cdc682afb39efd18f097faf695ce64c851c4a550a8ad96fa89d694451b6a42") version("5.5.0", sha256="968d9059f93d3f0f8a602f7b989e54e36cff2f9136486b6869e4534a5bf8c7d9") - version("5.4.3", sha256="7be6314a46195912d3203e7e59cb8880a46ed7c1fd221e92fadedd20532e0e48") - version("5.4.0", sha256="1740dca11c70ed350995331c292f7e3cb86273614e4a5ce9f0ea64dea5364318") - version("5.3.3", sha256="21a6b352ad3f5b2b7d05a5ed55e612feb3c5c19d34fdb8f80260b6d25af18b2d") - version("5.3.0", sha256="4885bd662b038c6e9f058a756fd838203dbd00227bfef6adaf31496010b100e4") with default_args(deprecated=True): - version("5.2.3", sha256="502f49cf3190f4ac20d0a6b19eb2d0786bb3c5661329940378081f1678aa8e82") - version("5.2.1", sha256="47f09536b0afbb7be4d6fb71cca9f0a4fa58dde29c83aee247d4b167f6f3acae") - version("5.2.0", sha256="f99eb7d2f6b1445742fba631a0dc8bb0d464a767a9c4fb79ac865d9570fe747b") - version("5.1.3", sha256="b5a08d2e76388bd1ffa6c946009928fe95de846ab6b65a6475998070c0cf6dc1") - version("5.1.0", sha256="dfe106c01155e00ed816f0231d1576ff8c08750cc8278fa453926f388dc6fe48") + version("5.4.3", sha256="7be6314a46195912d3203e7e59cb8880a46ed7c1fd221e92fadedd20532e0e48") + version("5.4.0", sha256="1740dca11c70ed350995331c292f7e3cb86273614e4a5ce9f0ea64dea5364318") + version("5.3.3", sha256="21a6b352ad3f5b2b7d05a5ed55e612feb3c5c19d34fdb8f80260b6d25af18b2d") + version("5.3.0", sha256="4885bd662b038c6e9f058a756fd838203dbd00227bfef6adaf31496010b100e4") + + depends_on("cxx", type="build") # generated amdgpu_targets = ROCmPackage.amdgpu_targets @@ -50,11 +50,6 @@ class Rocprim(CMakePackage): depends_on("googletest@1.10.0:", type="test") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -67,6 +62,9 @@ class Rocprim(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"comgr@{ver}", when=f"@{ver}") @@ -93,10 +91,9 @@ def cmake_args(self): if self.spec.satisfies("^cmake@3.21.0:3.21.2"): args.append(self.define("__skip_rocmclang", "ON")) - - if self.spec.satisfies("@:5.1"): - args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.cmake)) - elif self.spec.satisfies("@5.2:"): + if self.spec.satisfies("@5.2:"): + args.append(self.define("CMAKE_MODULE_PATH", self.spec["hip"].prefix.lib.cmake.hip)) + if self.spec.satisfies("@5.2:"): args.append(self.define("BUILD_FILE_REORG_BACKWARD_COMPATIBILITY", True)) return args diff --git a/var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests-5.6.patch b/var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests-5.6.patch new file mode 100644 index 00000000000000..dc94db638c47ab --- /dev/null +++ b/var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests-5.6.patch @@ -0,0 +1,74 @@ +From b28744bd1c0df82efc952e5ad208927007adf6f5 Mon Sep 17 00:00:00 2001 +From: Afzal Patel +Date: Fri, 2 Feb 2024 13:38:22 +0000 +Subject: [PATCH] Disable tests and add fPIC compile option + +--- + CMakeLists.txt | 32 ++++---------------------------- + 1 file changed, 4 insertions(+), 28 deletions(-) + +diff git a/CMakeLists.txt b/CMakeLists.txt +index 8f94b58..95b0387 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -44,7 +44,7 @@ endif() + + set(CMAKE_CXX_STANDARD 17) + set(CMAKE_CXX_STANDARD_REQUIRED ON) +-add_compile_options(-Wall) ++add_compile_options(-Wall -fPIC) + + set(THREADS_PREFER_PTHREAD_FLAG ON) + +@@ -162,17 +162,17 @@ add_subdirectory(src) + + if(${LIBRARY_TYPE} STREQUAL SHARED) + # Build samples +- add_subdirectory(samples) ++ # add_subdirectory(samples) + + # Build tests +- add_subdirectory(tests) ++ # add_subdirectory(tests) + endif() + + # Build Plugins + add_subdirectory(plugin) + + # Build tests +-add_subdirectory(${TEST_DIR} ${PROJECT_BINARY_DIR}/test) ++# add_subdirectory(${TEST_DIR} ${PROJECT_BINARY_DIR}/test) + + # Installation and packaging + set(DEST_NAME ${ROCPROFILER_NAME}) +@@ -239,30 +239,6 @@ install( + DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} + COMPONENT runtime) + +-# librocprof-tool.so +-install( +- FILES ${PROJECT_BINARY_DIR}/test/librocprof-tool.so +- DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} +- COMPONENT runtime) +- +-install( +- FILES ${PROJECT_BINARY_DIR}/test/librocprof-tool.so +- DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} +- COMPONENT asan) +- +-install( +- FILES ${PROJECT_BINARY_DIR}/test/rocprof-ctrl +- DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} +- PERMISSIONS +- OWNER_READ +- OWNER_WRITE +- OWNER_EXECUTE +- GROUP_READ +- GROUP_EXECUTE +- WORLD_READ +- WORLD_EXECUTE +- COMPONENT runtime) +- + # File reorg backward compatibility for non ASAN packaging + if ( NOT ENABLE_ASAN_PACKAGING ) + # File reorg Backward compatibility diff --git a/var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests-5.7.patch b/var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests-5.7.patch new file mode 100644 index 00000000000000..698a693ca72063 --- /dev/null +++ b/var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests-5.7.patch @@ -0,0 +1,68 @@ +From e7dd0146c83527e4977ecf51b22c9cb6939d74f2 Mon Sep 17 00:00:00 2001 +From: Afzal Patel +Date: Fri, 2 Feb 2024 13:50:58 +0000 +Subject: [PATCH] Disable tests and add fPIC compile option + +--- + CMakeLists.txt | 26 ++++---------------------- + 1 file changed, 4 insertions(+), 22 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index c8f5da7..5c2537a 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -44,7 +44,7 @@ endif() + + set(CMAKE_CXX_STANDARD 17) + set(CMAKE_CXX_STANDARD_REQUIRED ON) +-add_compile_options(-Wall) ++add_compile_options(-Wall -fPIC) + + set(THREADS_PREFER_PTHREAD_FLAG ON) + +@@ -162,17 +162,17 @@ add_subdirectory(src) + + if(${LIBRARY_TYPE} STREQUAL SHARED) + # Build samples +- add_subdirectory(samples) ++ # add_subdirectory(samples) + + # Build tests +- add_subdirectory(tests-v2) ++ # add_subdirectory(tests-v2) + endif() + + # Build Plugins + add_subdirectory(plugin) + + # Build tests +-add_subdirectory(${TEST_DIR} ${PROJECT_BINARY_DIR}/test) ++# add_subdirectory(${TEST_DIR} ${PROJECT_BINARY_DIR}/test) + + # Installation and packaging + set(DEST_NAME ${ROCPROFILER_NAME}) +@@ -236,24 +236,6 @@ install( + DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} + COMPONENT runtime) + +-# librocprof-tool.so +-install( +- FILES ${PROJECT_BINARY_DIR}/test/librocprof-tool.so +- DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} +- COMPONENT runtime) +- +-install( +- FILES ${PROJECT_BINARY_DIR}/test/librocprof-tool.so +- DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} +- COMPONENT asan) +- +-install( +- FILES ${PROJECT_BINARY_DIR}/test/rocprof-ctrl +- DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} +- PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ +- WORLD_EXECUTE +- COMPONENT runtime) +- + # File reorg backward compatibility for non ASAN packaging + if(NOT ENABLE_ASAN_PACKAGING) + # File reorg Backward compatibility diff --git a/var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests.patch b/var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests.patch new file mode 100644 index 00000000000000..8ff9eebe3eaa6a --- /dev/null +++ b/var/spack/repos/builtin/packages/rocprofiler-dev/0002-add-fPIC-and-disable-tests.patch @@ -0,0 +1,69 @@ +From d8a55fe10f0f88087d67a9d7bb1fce47fda8d86f Mon Sep 17 00:00:00 2001 +From: Afzal Patel +Date: Thu, 1 Feb 2024 18:06:40 +0000 +Subject: [PATCH] Disable tests and add fPIC compile option + +--- + CMakeLists.txt | 27 ++++----------------------- + 1 file changed, 4 insertions(+), 23 deletions(-) + +diff git a/CMakeLists.txt b/CMakeLists.txt +index 99fb394..63e65ca 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -44,7 +44,7 @@ endif() + + set(CMAKE_CXX_STANDARD 17) + set(CMAKE_CXX_STANDARD_REQUIRED ON) +-add_compile_options(-Wall) ++add_compile_options(-Wall -fPIC) + + set(THREADS_PREFER_PTHREAD_FLAG ON) + +@@ -162,17 +162,17 @@ add_subdirectory(src) + + if(${LIBRARY_TYPE} STREQUAL SHARED) + # Build samples +- add_subdirectory(samples) ++ # add_subdirectory(samples) + + # Build tests +- add_subdirectory(tests) ++ # add_subdirectory(tests) + endif() + + # Build Plugins + add_subdirectory(plugin) + + # Build tests +-add_subdirectory(${TEST_DIR} ${PROJECT_BINARY_DIR}/test) ++# add_subdirectory(${TEST_DIR} ${PROJECT_BINARY_DIR}/test) + + # Installation and packaging + set(DEST_NAME ${ROCPROFILER_NAME}) +@@ -238,25 +238,6 @@ install( + DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} + COMPONENT runtime) + +-# librocprof-tool.so +-install( +- FILES ${PROJECT_BINARY_DIR}/test/librocprof-tool.so +- DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} +- COMPONENT runtime) +- +-install( +- FILES ${PROJECT_BINARY_DIR}/test/rocprof-ctrl +- DESTINATION ${CMAKE_INSTALL_LIBDIR}/${ROCPROFILER_NAME} +- PERMISSIONS +- OWNER_READ +- OWNER_WRITE +- OWNER_EXECUTE +- GROUP_READ +- GROUP_EXECUTE +- WORLD_READ +- WORLD_EXECUTE +- COMPONENT runtime) +- + # File reorg Backward compatibility + option(FILE_REORG_BACKWARD_COMPATIBILITY + "Enable File Reorg with backward compatibility" ON) diff --git a/var/spack/repos/builtin/packages/rocprofiler-dev/0003-disable-tests.patch b/var/spack/repos/builtin/packages/rocprofiler-dev/0003-disable-tests.patch new file mode 100644 index 00000000000000..51a92ccfd1a947 --- /dev/null +++ b/var/spack/repos/builtin/packages/rocprofiler-dev/0003-disable-tests.patch @@ -0,0 +1,24 @@ +From 869c2dc4b88aa5beb5ab0e57aba85d0c520e7074 Mon Sep 17 00:00:00 2001 +From: Afzal Patel +Date: Fri, 2 Feb 2024 14:16:12 +0000 +Subject: [PATCH] Disable tests + +--- + CMakeLists.txt | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 9d52082..6f35926 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -176,8 +176,8 @@ endif() + enable_testing() + + # Temporarily for CI to work +-set(ROCPROFILER_BUILD_TESTS ON) +-set(ROCPROFILER_BUILD_CI ON) ++set(ROCPROFILER_BUILD_TESTS OFF) ++set(ROCPROFILER_BUILD_CI OFF) + + if(ROCPROFILER_BUILD_CI) + include(CTest) diff --git a/var/spack/repos/builtin/packages/rocprofiler-dev/package.py b/var/spack/repos/builtin/packages/rocprofiler-dev/package.py index 18150254dcc8c1..35702f97be9625 100644 --- a/var/spack/repos/builtin/packages/rocprofiler-dev/package.py +++ b/var/spack/repos/builtin/packages/rocprofiler-dev/package.py @@ -13,33 +13,95 @@ class RocprofilerDev(CMakePackage): homepage = "https://github.com/ROCm/rocprofiler" git = "https://github.com/ROCm/rocprofiler.git" - url = "https://github.com/ROCm/rocprofiler/archive/refs/tags/rocm-5.4.3.tar.gz" + url = "https://github.com/ROCm/rocprofiler/archive/refs/tags/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") libraries = ["librocprofiler64"] license("MIT") - version("5.4.3", sha256="86c3f43ee6cb9808796a21409c853cc8fd496578b9eef4de67ca77830229cac1") - version("5.4.0", sha256="0322cbe5d1d3182e616f472da31f0707ad6040833c38c28f2b39381a85210f43") - version("5.3.3", sha256="07ee28f3420a07fc9d45910e78ad7961b388109cfc0e74cfdf2666789e6af171") - version("5.3.0", sha256="b0905a329dc1c97a362b951f3f8ef5da9d171cabb001ed4253bd59a2742e7d39") + version("6.1.2", sha256="e6e8771b8c933c16a99192cc215fe964a95e1718ad286520c8272150e184bc06") + version("6.1.1", sha256="b4b01a02de5328c7383c2318a998da86a6a9372e1728fc88a21b52bc1cbe9d9d") + version("6.1.0", sha256="14ac0a451428465133583e83d9177ed34b3d4679515018a12ee74f5e0288c956") + version("6.0.2", sha256="d3f24e639a5e151fa418a92ae6fe150bdf14120b8982a5baa52844ce2fba0b82") + version("6.0.0", sha256="6aca327a6ba302b5957002e55ac640dd185d51a354da3859e957448a5fc36b14") + version("5.7.1", sha256="2fb7158592d89312ba419a272d907d8849373c0a676a83dd03c32b9942dfd27a") + version("5.7.0", sha256="003af33db5585e71823b2b58618d795df926f6bd25943f2add388db23f2bf377") + version("5.6.1", sha256="3e5eecce216418e61ffee893cbc8611e38305ee472d0e10d579eb74e287c8e1b") + version("5.6.0", sha256="ff811bd91580f60b6b4d397b6fce38d96f07debc6fd8a631b81d1b266cc9542d") + version("5.5.1", sha256="f5dbece5c205e37383fed4a2bd6042ff1c11f11f64dfbf65d7e23c0af6889a5a") + version("5.5.0", sha256="d9dd38c42b4b12d4149f1cc3fca1af5bec69c72f455653a8f4fd8195b3b95703") with default_args(deprecated=True): - version("5.2.3", sha256="4ed22e86633ab177eed85fed8994fcb71017c4c4774998e4d3fc36b6c0a15eac") - version("5.2.1", sha256="c6768ec428590aadfb0e7ef6e22b8dc5ac8ed97babeb56db07f2d5d41cd122e2") - version("5.2.0", sha256="1f4db27b56ef1863d4c9e1d96bac9117d66be45156d0637cfe4fd38cae61a23a") - version("5.1.3", sha256="eca7be451c7bf000fd9c75683e7f5dfbed32dbb385b5ac685d2251ee8c3abc96") - version("5.1.0", sha256="4a1c6ed887b0159392406af8796508df2794353a4c3aacc801116044fb4a10a5") + version("5.4.3", sha256="86c3f43ee6cb9808796a21409c853cc8fd496578b9eef4de67ca77830229cac1") + version("5.4.0", sha256="0322cbe5d1d3182e616f472da31f0707ad6040833c38c28f2b39381a85210f43") + version("5.3.3", sha256="07ee28f3420a07fc9d45910e78ad7961b388109cfc0e74cfdf2666789e6af171") + version("5.3.0", sha256="b0905a329dc1c97a362b951f3f8ef5da9d171cabb001ed4253bd59a2742e7d39") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("cmake@3:", type="build") - for ver in ["5.1.0", "5.1.3", "5.2.0", "5.2.1", "5.2.3", "5.3.0", "5.3.3", "5.4.0", "5.4.3"]: + + for ver in [ + "5.3.0", + "5.3.3", + "5.4.0", + "5.4.3", + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"hsakmt-roct@{ver}", when=f"@{ver}") depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") depends_on(f"rocminfo@{ver}", when=f"@{ver}") depends_on(f"roctracer-dev-api@{ver}", when=f"@{ver}") + for ver in ["5.7.0", "5.7.1", "6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: + depends_on(f"hip@{ver}", when=f"@{ver}") + depends_on(f"rocm-smi-lib@{ver}", when=f"@{ver}") + + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: + depends_on(f"aqlprofile@{ver}", when=f"@{ver}") + depends_on(f"comgr@{ver}", when=f"@{ver}") + + depends_on("numactl", type="link", when="@4.3.1") + depends_on("py-lxml", when="@5.5:") + depends_on("py-cppheaderparser", when="@5.5:") + depends_on("googletest@1.10.0:", when="@5.5:") + depends_on("py-pyyaml", when="@5.5:") + depends_on("py-barectf", when="@5.5:") + depends_on("py-setuptools", when="@5.5:") + depends_on("py-jsonschema", when="@5.5:") + depends_on("py-jinja2", when="@5.5:") + depends_on("py-termcolor", when="@5.5:") + depends_on("py-pandas", when="@6.0:") + # See https://github.com/ROCm/rocprofiler/pull/50 - patch("fix-includes.patch") - patch("0001-Continue-build-in-absence-of-aql-profile-lib.patch", when="@5.3:") + patch("fix-includes.patch", when="@:5.4") + patch("0001-Continue-build-in-absence-of-aql-profile-lib.patch", when="@5.3:5.4") + patch("0002-add-fPIC-and-disable-tests.patch", when="@5.5") + patch("0002-add-fPIC-and-disable-tests-5.6.patch", when="@5.6") + patch("0002-add-fPIC-and-disable-tests-5.7.patch", when="@5.7") + patch("0003-disable-tests.patch", when="@6.0:") def patch(self): filter_file( @@ -65,4 +127,11 @@ def cmake_args(self): "PROF_API_HEADER_PATH", self.spec["roctracer-dev-api"].prefix.roctracer.include.ext ), self.define("ROCM_ROOT_DIR", self.spec["hsakmt-roct"].prefix.include), + self.define("CMAKE_INSTALL_LIBDIR", "lib"), ] + + @run_after("install") + def post_install(self): + if self.spec.satisfies("@6.0:"): + install_tree(self.prefix.include.rocprofiler, self.prefix.rocprofiler.include) + install_tree(self.prefix.lib, self.prefix.rocprofiler.lib) diff --git a/var/spack/repos/builtin/packages/rocrand/package.py b/var/spack/repos/builtin/packages/rocrand/package.py index dac5ad8dcced13..b3fb00b0e4ff8f 100644 --- a/var/spack/repos/builtin/packages/rocrand/package.py +++ b/var/spack/repos/builtin/packages/rocrand/package.py @@ -3,7 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -import glob import os import re @@ -26,6 +25,9 @@ class Rocrand(CMakePackage): version("develop", branch="develop") version("master", branch="master") + version("6.1.2", sha256="ac3c858c0f76188ac50574591aa6b41b27bda2af5925314451a44242319f28c8") + version("6.1.1", sha256="d6302d014045694be85385cdc683ea75476e23fd92ae170079c261c0b041764b") + version("6.1.0", sha256="ea80c5d657fa48b1122a47986239a04118977195ee4826d2b14b8bfe0fabce6e") version("6.0.2", sha256="51d66c645987cbfb593aaa6be94109e87fe4cb7e9c70309eb3c159af0de292d7") version("6.0.0", sha256="cee93231c088be524bb2cb0e6093ec47e62e61a55153486bebbc2ca5b3d49360") version("5.7.1", sha256="885cd905bbd23d02ba8f3f87d5c0b79bc44bd020ea9af190f3959cf5aa33d07d") @@ -34,16 +36,14 @@ class Rocrand(CMakePackage): version("5.6.0", sha256="cc894d2f1af55e16b62c179062063946609c656043556189c656a115fd7d6f5f") version("5.5.1", sha256="e8bed3741b19e296bd698fc55b43686206f42f4deea6ace71513e0c48258cc6e") version("5.5.0", sha256="0481e7ef74c181026487a532d1c17e62dd468e508106edde0279ca1adeee6f9a") - version("5.4.3", sha256="463aa760e9f74e45b326765040bb8a8a4fa27aaeaa5e5df16f8289125f88a619") - version("5.4.0", sha256="0f6a0279b8b5a6dfbe32b45e1598218fe804fee36170d5c1f7b161c600544ef2") - version("5.3.3", sha256="b0aae79dce7f6f9ef76ad2594745fe1f589a7b675b22f35b4d2369e7d5e1985a") - version("5.3.0", sha256="be4c9f9433415bdfea50d9f47b8afb43ac315f205ed39674f863955a6c256dca") with default_args(deprecated=True): - version("5.2.3", sha256="01eda8022fab7bafb2c457fe26a9e9c99950ed1b772ae7bf8710b23a90b56e32") - version("5.2.1", sha256="4b2a7780f0112c12b5f307e1130e6b2c02ab984a0c1b94e9190dae38f0067600") - version("5.2.0", sha256="ab3057e7c17a9fbe584f89ef98ec92a74d638a98d333e7d0f64daf7bc9051e38") - version("5.1.3", sha256="4a19e1bcb60955a02a73ad64594c23886d6749afe06b0104e2b877dbe02c8d1c") - version("5.1.0", sha256="0c6f114a775d0b38be71f3f621a10bde2104a1f655d5d68c5fecb79b8b51a815") + version("5.4.3", sha256="463aa760e9f74e45b326765040bb8a8a4fa27aaeaa5e5df16f8289125f88a619") + version("5.4.0", sha256="0f6a0279b8b5a6dfbe32b45e1598218fe804fee36170d5c1f7b161c600544ef2") + version("5.3.3", sha256="b0aae79dce7f6f9ef76ad2594745fe1f589a7b675b22f35b4d2369e7d5e1985a") + version("5.3.0", sha256="be4c9f9433415bdfea50d9f47b8afb43ac315f205ed39674f863955a6c256dca") + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated amdgpu_targets = ROCmPackage.amdgpu_targets @@ -73,11 +73,6 @@ class Rocrand(CMakePackage): ("5.4.0", "125d691d3bcc6de5f5d63cf5f5a993c636251208"), ("5.3.3", "12e2f070337945318295c330bf69c6c060928b9e"), ("5.3.0", "12e2f070337945318295c330bf69c6c060928b9e"), - ("5.2.3", "12e2f070337945318295c330bf69c6c060928b9e"), - ("5.2.1", "12e2f070337945318295c330bf69c6c060928b9e"), - ("5.2.0", "12e2f070337945318295c330bf69c6c060928b9e"), - ("5.1.3", "20ac3db9d7462c15a3e96a6f0507cd5f2ee089c4"), - ("5.1.0", "20ac3db9d7462c15a3e96a6f0507cd5f2ee089c4"), ]: resource( name="hipRAND", @@ -105,11 +100,6 @@ class Rocrand(CMakePackage): ) for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -122,6 +112,9 @@ class Rocrand(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") @@ -134,26 +127,6 @@ def patch(self): def setup_build_environment(self, env): env.set("CXX", self.spec["hip"].hipcc) - @run_after("install") - def fix_library_locations(self): - if self.spec.satisfies("~hiprand"): - return - """Fix the rocRAND and hipRAND libraries location""" - # rocRAND installs librocrand.so* and libhiprand.so* to rocrand/lib and - # hiprand/lib, respectively. This confuses spack's RPATH management. We - # fix it by adding a symlink to the libraries. - if self.spec.satisfies("@5.1.0:5.1.3"): - if not os.path.isdir(os.path.join(self.prefix, "hiprand")): - os.mkdir(os.path.join(self.prefix, "hiprand")) - os.mkdir(os.path.join(self.prefix, "hiprand", "include")) - hiprand_include_path = join_path(self.prefix, "include", "hiprand") - with working_dir(hiprand_include_path): - hiprand_includes = glob.glob("*.h*") - hiprand_path = join_path(self.prefix, "hiprand", "include") - with working_dir(hiprand_path): - for header_file in hiprand_includes: - os.symlink(join_path("../../include/hiprand", header_file), header_file) - @classmethod def determine_version(cls, lib): match = re.search(r"lib\S*\.so\.\d+\.\d+\.(\d)(\d\d)(\d\d)", lib) diff --git a/var/spack/repos/builtin/packages/rocsolver/fmt-8.1-compatibility.patch b/var/spack/repos/builtin/packages/rocsolver/fmt-8.1-compatibility.patch deleted file mode 100644 index f9333667446999..00000000000000 --- a/var/spack/repos/builtin/packages/rocsolver/fmt-8.1-compatibility.patch +++ /dev/null @@ -1,143 +0,0 @@ ---- a/library/src/include/rocsolver_logvalue.hpp -+++ b/library/src/include/rocsolver_logvalue.hpp -@@ -8,6 +8,14 @@ - - #include "rocsolver_datatype2string.hpp" - -+/* The format function for user-defined types cannot be const before fmt v8.0 -+ but must be const in fmt v8.1 if the type is used in a tuple. */ -+#if FMT_VERSION < 80000 -+#define ROCSOLVER_FMT_CONST -+#else -+#define ROCSOLVER_FMT_CONST const -+#endif -+ - /*************************************************************************** - * Wrapper for types passed to logger, so we can more easily adjust the - * default way of printing built-in types without doing it globally. (e.g. -@@ -37,7 +45,7 @@ template - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(wrapper.value, ctx); - } -@@ -49,7 +57,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(wrapper.value ? '1' : '0', ctx); - } -@@ -58,7 +66,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2char_operation(wrapper.value), ctx); - } -@@ -67,7 +75,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2char_fill(wrapper.value), ctx); - } -@@ -76,7 +84,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2char_diagonal(wrapper.value), ctx); - } -@@ -85,7 +93,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2char_side(wrapper.value), ctx); - } -@@ -94,7 +102,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2char_direct(wrapper.value), ctx); - } -@@ -104,7 +112,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2char_storev(wrapper.value), ctx); - } -@@ -113,7 +121,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2char_workmode(wrapper.value), ctx); - } -@@ -122,7 +130,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2char_svect(wrapper.value), ctx); - } -@@ -131,7 +139,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2char_evect(wrapper.value), ctx); - } -@@ -140,7 +148,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2char_eform(wrapper.value), ctx); - } -@@ -149,7 +157,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2string_datatype(wrapper.value), ctx); - } -@@ -158,7 +166,7 @@ template <> - struct formatter> : formatter - { - template -- auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) -+ auto format(rocsolver_logvalue wrapper, FormatCtx& ctx) ROCSOLVER_FMT_CONST - { - return formatter::format(rocblas2string_initialization(wrapper.value), ctx); - } diff --git a/var/spack/repos/builtin/packages/rocsolver/package.py b/var/spack/repos/builtin/packages/rocsolver/package.py index 93ae0e1e3adbf9..4cc1e485ebf481 100644 --- a/var/spack/repos/builtin/packages/rocsolver/package.py +++ b/var/spack/repos/builtin/packages/rocsolver/package.py @@ -15,7 +15,7 @@ class Rocsolver(CMakePackage): homepage = "https://github.com/ROCm/rocSOLVER" git = "https://github.com/ROCm/rocSOLVER.git" - url = "https://github.com/ROCm/rocSOLVER/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rocSOLVER/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("cgmb", "srekolam", "renjithravindrankannath", "haampie") @@ -41,6 +41,9 @@ class Rocsolver(CMakePackage): version("develop", branch="develop") version("master", branch="master") + version("6.1.2", sha256="8cb45b6a4ed819b8e952c0bfdd8bf7dd941478ac656bea42a6d6751f459e66ea") + version("6.1.1", sha256="3bbba30fa7f187676caf858f66c2345e4dcc81b9546eca4a726c0b159dad22bd") + version("6.1.0", sha256="f1d7a4edf14ed0b2e2f74aa5cbc9db0c3b0dd31e50bbada1586cb353a28fe015") version("6.0.2", sha256="781d5df2886ab0d5087a215a33ac390dd27653b2a9b4a620c7d51b0ae56f63d2") version("6.0.0", sha256="5fcaba96f3efafc2ecc3f4ec104095d96545c16e1b9f95410bd571cb0fc643ae") version("5.7.1", sha256="83e0c137b8690dbeb2e85d9e25415d96bd06979f09f2b10b2aff8e4c9f833fa4") @@ -49,16 +52,14 @@ class Rocsolver(CMakePackage): version("5.6.0", sha256="54baa7f35f3c53da9005054e6f7aeecece5526dafcb277af32cbcb3996b0cbbc") version("5.5.1", sha256="8bf843e42d2e89203ea5fdb6e6082cea90da8d02920ab4c09bcc2b6f69909760") version("5.5.0", sha256="6775aa5b96731208c12c5b450cf218d4c262a80b7ea20c2c3034c448bb2ca4d2") - version("5.4.3", sha256="5308b68ea72f465239a4bb2ed1a0507f0df7c98d3df3fd1f392e6d9ed7975232") - version("5.4.0", sha256="69690839cb649dee43353b739d3e6b2312f3d965dfe66705c0ea910e57c6a8cb") - version("5.3.3", sha256="d2248b5e2e0b20e08dd1ee5408e38deb02ecd28096dc7c7f2539351df6cb6ad5") - version("5.3.0", sha256="4569f860d240d50e94e77d498050f5cafe5ad11daddaead3e7e9eaa1957878a7") with default_args(deprecated=True): - version("5.2.3", sha256="b278a1640f31fb1905f18dc5127d57e2b1d36fd2b4f39ae811b5537fa6ce87d4") - version("5.2.1", sha256="74c127efaefec70a14dff6fa0e92276f38a6c313bf1271d68d03a4222d1fc3b6") - version("5.2.0", sha256="94d46ebe1266eaa05df50c1789dc27d3f2dbf3cb5af156e757777a82ed6ef356") - version("5.1.3", sha256="5a8f3b95ac9a131c31538196e954ea53b863009c092cce0c0ef869a0cd5dd554") - version("5.1.0", sha256="88de515a6e75eaa3c50c9c8ae1e7ae8e3b46e712e388f44f79b63fefa9fc0831") + version("5.4.3", sha256="5308b68ea72f465239a4bb2ed1a0507f0df7c98d3df3fd1f392e6d9ed7975232") + version("5.4.0", sha256="69690839cb649dee43353b739d3e6b2312f3d965dfe66705c0ea910e57c6a8cb") + version("5.3.3", sha256="d2248b5e2e0b20e08dd1ee5408e38deb02ecd28096dc7c7f2539351df6cb6ad5") + version("5.3.0", sha256="4569f860d240d50e94e77d498050f5cafe5ad11daddaead3e7e9eaa1957878a7") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated depends_on("cmake@3.8:", type="build") depends_on("fmt@7:", type="build", when="@4.5.0:") @@ -67,8 +68,6 @@ class Rocsolver(CMakePackage): depends_on("googletest@1.10.0:", type="test") depends_on("netlib-lapack@3.7.1:", type="test") - # Backport https://github.com/ROCm/rocSOLVER/commit/2bbfb8976f6e4d667499c77e41a6433850063e88 - patch("fmt-8.1-compatibility.patch", when="@:5.1.3") # Maximize compatibility with other libraries that are using fmt. patch("fmt-9-compatibility.patch", when="@5.2.0:5.5") @@ -83,11 +82,6 @@ class Rocsolver(CMakePackage): depends_on(f"rocblas@{ver}", when=f"@{ver}") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -100,6 +94,9 @@ class Rocsolver(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"rocblas@{ver}", when=f"@{ver}") diff --git a/var/spack/repos/builtin/packages/rocsparse/0003-fix-navi-1x-rocm-4.5.patch b/var/spack/repos/builtin/packages/rocsparse/0003-fix-navi-1x-rocm-4.5.patch deleted file mode 100644 index ab84b91c6177d3..00000000000000 --- a/var/spack/repos/builtin/packages/rocsparse/0003-fix-navi-1x-rocm-4.5.patch +++ /dev/null @@ -1,78 +0,0 @@ -From f9446b8f4c3cb3a3c6d38734f9980712a82b9db9 Mon Sep 17 00:00:00 2001 -From: Cory Bloor -Date: Fri, 8 Jul 2022 20:53:32 -0600 -Subject: [PATCH] Improve guards for arch-specific instructions (#368) - -When choosing between a specialized implementation that uses -architecture-specific functionality and a generic fallback, it is -usually preferable to make the fallback the default. This will give the -software the best possible chance of functioning without modification -on future hardware. - -Of course, the library will still need code updates to function -optimally on hardware released after the software was written. - -rocSPARSE can also be compiled with CXXFLAGS=-DROCSPARSE_USE_MOVE_DPP=0 -to force the use of the fallback implementation. Or with the value 1 to -force the use of the specialized __hip_move_dpp implementation. - -This change fixes the compilation error: - - Illegal instruction detected: Invalid dpp_ctrl value: broadcasts are not supported on GFX10+ - -when building for unsupported Navi 1x and Navi 2x GPUs as was -reported in https://github.com/ROCmSoftwarePlatform/rocSPARSE/issues/250 ---- - library/src/include/common.h | 18 +++++++++++++++--- - 1 file changed, 15 insertions(+), 3 deletions(-) - -diff --git a/library/src/include/common.h b/library/src/include/common.h -index 6a4654af..975c5f7d 100644 ---- a/library/src/include/common.h -+++ b/library/src/include/common.h -@@ -34,6 +34,18 @@ - - // clang-format off - -+#ifndef ROCSPARSE_USE_MOVE_DPP -+#if defined(__gfx803__) || \ -+ defined(__gfx900__) || \ -+ defined(__gfx906__) || \ -+ defined(__gfx908__) || \ -+ defined(__gfx90a__) -+#define ROCSPARSE_USE_MOVE_DPP 1 -+#else -+#define ROCSPARSE_USE_MOVE_DPP 0 -+#endif -+#endif -+ - // BSR indexing macros - #define BSR_IND(j, bi, bj, dir) ((dir == rocsparse_direction_row) ? BSR_IND_R(j, bi, bj) : BSR_IND_C(j, bi, bj)) - #define BSR_IND_R(j, bi, bj) (block_dim * block_dim * (j) + (bi) * block_dim + (bj)) -@@ -233,7 +245,7 @@ __device__ __forceinline__ void rocsparse_blockreduce_min(int i, T* data) - if(BLOCKSIZE > 1) { if(i < 1 && i + 1 < BLOCKSIZE) { data[i] = min(data[i], data[i + 1]); } __syncthreads(); } - } - --#ifndef __gfx1030__ -+#if ROCSPARSE_USE_MOVE_DPP - // DPP-based wavefront reduction maximum - template - __device__ __forceinline__ void rocsparse_wfreduce_max(int* maximum) -@@ -499,7 +511,7 @@ __device__ __forceinline__ double rocsparse_wfreduce_sum(double sum) - sum = temp_sum.val; - return sum; - } --#else -+#else /* ROCSPARSE_USE_MOVE_DPP */ - template - __device__ __forceinline__ void rocsparse_wfreduce_max(int* maximum) - { -@@ -566,7 +578,7 @@ __device__ __forceinline__ double rocsparse_wfreduce_sum(double sum) - - return sum; - } --#endif -+#endif /* ROCSPARSE_USE_MOVE_DPP */ - - // DPP-based complex float wavefront reduction sum - template diff --git a/var/spack/repos/builtin/packages/rocsparse/0003-fix-navi-1x-rocm-5.2.patch b/var/spack/repos/builtin/packages/rocsparse/0003-fix-navi-1x-rocm-5.2.patch deleted file mode 100644 index 52bbe8336fb756..00000000000000 --- a/var/spack/repos/builtin/packages/rocsparse/0003-fix-navi-1x-rocm-5.2.patch +++ /dev/null @@ -1,78 +0,0 @@ -From f9446b8f4c3cb3a3c6d38734f9980712a82b9db9 Mon Sep 17 00:00:00 2001 -From: Cory Bloor -Date: Fri, 8 Jul 2022 20:53:32 -0600 -Subject: [PATCH] Improve guards for arch-specific instructions (#368) - -When choosing between a specialized implementation that uses -architecture-specific functionality and a generic fallback, it is -usually preferable to make the fallback the default. This will give the -software the best possible chance of functioning without modification -on future hardware. - -Of course, the library will still need code updates to function -optimally on hardware released after the software was written. - -rocSPARSE can also be compiled with CXXFLAGS=-DROCSPARSE_USE_MOVE_DPP=0 -to force the use of the fallback implementation. Or with the value 1 to -force the use of the specialized __hip_move_dpp implementation. - -This change fixes the compilation error: - - Illegal instruction detected: Invalid dpp_ctrl value: broadcasts are not supported on GFX10+ - -when building for unsupported Navi 1x and Navi 2x GPUs as was -reported in https://github.com/ROCmSoftwarePlatform/rocSPARSE/issues/250 ---- - library/src/include/common.h | 18 +++++++++++++++--- - 1 file changed, 15 insertions(+), 3 deletions(-) - -diff --git a/library/src/include/common.h b/library/src/include/common.h -index 6a4654af..975c5f7d 100644 ---- a/library/src/include/common.h -+++ b/library/src/include/common.h -@@ -34,6 +34,18 @@ - - // clang-format off - -+#ifndef ROCSPARSE_USE_MOVE_DPP -+#if defined(__gfx803__) || \ -+ defined(__gfx900__) || \ -+ defined(__gfx906__) || \ -+ defined(__gfx908__) || \ -+ defined(__gfx90a__) -+#define ROCSPARSE_USE_MOVE_DPP 1 -+#else -+#define ROCSPARSE_USE_MOVE_DPP 0 -+#endif -+#endif -+ - // BSR indexing macros - #define BSR_IND(j, bi, bj, dir) ((dir == rocsparse_direction_row) ? BSR_IND_R(j, bi, bj) : BSR_IND_C(j, bi, bj)) - #define BSR_IND_R(j, bi, bj) (block_dim * block_dim * (j) + (bi) * block_dim + (bj)) -@@ -233,7 +245,7 @@ __device__ __forceinline__ void rocsparse_blockreduce_min(int i, T* data) - if(BLOCKSIZE > 1) { if(i < 1 && i + 1 < BLOCKSIZE) { data[i] = min(data[i], data[i + 1]); } __syncthreads(); } - } - --#if (!defined(__gfx1030__)) && (!defined(__gfx1011__)) -+#if ROCSPARSE_USE_MOVE_DPP - // DPP-based wavefront reduction maximum - template - __device__ __forceinline__ void rocsparse_wfreduce_max(int* maximum) -@@ -499,7 +511,7 @@ __device__ __forceinline__ double rocsparse_wfreduce_sum(double sum) - sum = temp_sum.val; - return sum; - } --#else -+#else /* ROCSPARSE_USE_MOVE_DPP */ - template - __device__ __forceinline__ void rocsparse_wfreduce_max(int* maximum) - { -@@ -566,7 +578,7 @@ __device__ __forceinline__ double rocsparse_wfreduce_sum(double sum) - - return sum; - } --#endif -+#endif /* ROCSPARSE_USE_MOVE_DPP */ - - // DPP-based complex float wavefront reduction sum - template diff --git a/var/spack/repos/builtin/packages/rocsparse/package.py b/var/spack/repos/builtin/packages/rocsparse/package.py index a37ea3046830ae..93b5122b1a6578 100644 --- a/var/spack/repos/builtin/packages/rocsparse/package.py +++ b/var/spack/repos/builtin/packages/rocsparse/package.py @@ -17,7 +17,7 @@ class Rocsparse(CMakePackage): homepage = "https://github.com/ROCm/rocSPARSE" git = "https://github.com/ROCm/rocSPARSE.git" - url = "https://github.com/ROCm/rocSPARSE/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rocSPARSE/archive/rocm-6.1.1.tar.gz" tags = ["rocm"] maintainers("cgmb", "srekolam", "renjithravindrankannath") @@ -34,6 +34,9 @@ class Rocsparse(CMakePackage): variant("test", default=False, description="Build rocsparse-test client") license("MIT") + version("6.1.2", sha256="e8989c28085275e7c044b19fd2bc86d8493ce6a1b8545126f787722c535fe6eb") + version("6.1.1", sha256="9ac2bf84962cfdf24e4fa68e6f1d91ffdad5d5a5287ecdaddf331e6073ba57b3") + version("6.1.0", sha256="d69d9b0079159abb2d7514f8f45a41bb2cbcaf8b52e600e794aca3facf274b5e") version("6.0.2", sha256="00292eb7efe5719a65960bdbe391ba8e0ce610487eea11397aad6a14b11e12cd") version("6.0.0", sha256="bdc618677ec78830c6af315d61194d6ab8532345b8daeeb115aca96f274d4ca4") version("5.7.1", sha256="4c09b182b371124675d4057246021b5ed45e2833fdbf265b37a9b06b668baf0a") @@ -42,25 +45,19 @@ class Rocsparse(CMakePackage): version("5.6.0", sha256="5797db3deb4a532e691447e3e8c923b93bd9fe4c468f3a88f00cecd80bebcae4") version("5.5.1", sha256="1dd2d18898dfebdf898e8fe7d1c1198e8f8451fd70ff12a1990ec1419cf359e1") version("5.5.0", sha256="cbee79b637691bc710c1c83fbaa91db7498d38d4df873be23e28ed5617acde72") - version("5.4.3", sha256="9fb633f235eb0567cc54fae6bdc779f16bf0bb4e6f5bdddb40312c6d11ca8478") - version("5.4.0", sha256="c8f0e920a8ec15b9ae40564c68191363356cc4d793c16247bb6e11ef5293ed11") - version("5.3.3", sha256="4204035e952e20ada4526a94989e8e5c76c04574176fe63a021522862461c800") - version("5.3.0", sha256="521ca0e7b52f26edbff8507eb1479dc26019f456756d884d7b8b192c3ea518e8") with default_args(deprecated=True): - version("5.2.3", sha256="6da3f3303a8ada94c4dbff4b42ee33a2e2883a908ee21c41cb2aa7180382026a") - version("5.2.1", sha256="01f3535442740221edad2cde0a20b2499c807f6733d5016b33c47f34a5a55c49") - version("5.2.0", sha256="7ed929af16d2502135024a6463997d9a95f03899b8a33aa95db7029575c89572") - version("5.1.3", sha256="ef9641045b36c9aacc87e4fe7717b41b1e29d97e21432678dce7aca633a8edc2") - version("5.1.0", sha256="a2f0f8cb02b95993480bd7264fc65e8b11464a90b86f2dcd0dd82a2e6d4bd704") + version("5.4.3", sha256="9fb633f235eb0567cc54fae6bdc779f16bf0bb4e6f5bdddb40312c6d11ca8478") + version("5.4.0", sha256="c8f0e920a8ec15b9ae40564c68191363356cc4d793c16247bb6e11ef5293ed11") + version("5.3.3", sha256="4204035e952e20ada4526a94989e8e5c76c04574176fe63a021522862461c800") + version("5.3.0", sha256="521ca0e7b52f26edbff8507eb1479dc26019f456756d884d7b8b192c3ea518e8") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated depends_on("cmake@3.5:", type="build") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -73,6 +70,9 @@ class Rocsparse(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"rocprim@{ver}", when=f"@{ver}") @@ -82,9 +82,6 @@ class Rocsparse(CMakePackage): patch("0001-set-mtx-directory.patch", when="@:5.3 +test") # Enable use of Spack-provided Python. patch("0002-fix-gentest-shebang.patch", when="@:5.3 +test") - # Fix build for most Radeon 5000 and Radeon 6000 series GPUs. - patch("0003-fix-navi-1x-rocm-4.5.patch", when="@:5.1") - patch("0003-fix-navi-1x-rocm-5.2.patch", when="@5.2") depends_on("googletest@1.11.0:", when="@5.1.0: +test") depends_on("googletest@1.10.0:", when="+test") diff --git a/var/spack/repos/builtin/packages/rocthrust/package.py b/var/spack/repos/builtin/packages/rocthrust/package.py index 229724dc88ae05..c7222ece39ecc8 100644 --- a/var/spack/repos/builtin/packages/rocthrust/package.py +++ b/var/spack/repos/builtin/packages/rocthrust/package.py @@ -14,10 +14,13 @@ class Rocthrust(CMakePackage): homepage = "https://github.com/ROCm/rocThrust" git = "https://github.com/ROCm/rocThrust.git" - url = "https://github.com/ROCm/rocThrust/archive/rocm-6.0.0.tar.gz" + url = "https://github.com/ROCm/rocThrust/archive/rocm-6.1.0.tar.gz" tags = ["rocm"] maintainers("cgmb", "srekolam", "renjithravindrankannath") + version("6.1.2", sha256="149ca325fb8a8527781ec2853282a73bf66f60366652c19e8583afc3f1a9c4b6") + version("6.1.1", sha256="03420d8af687107775a1fbd3db5e8c9872c7c738747de77a5e8c0b3466a3321a") + version("6.1.0", sha256="8c36fb7b34758579601365a450700899133da5802e5c8370654051b190bd6e1c") version("6.0.2", sha256="8de9414f6b921ff549ba102239fcf65f5cc70ece5eec9753de5ec91870e6934d") version("6.0.0", sha256="a3fdafe4b6124118e07f23a3b0270d91740da324f61aaa3e8c034da08d9312b1") version("5.7.1", sha256="b7cb9ea6c42b2c6b610c34d2c438443e0f99245bd391aff18591949bf1cd53ee") @@ -26,16 +29,13 @@ class Rocthrust(CMakePackage): version("5.6.0", sha256="e52a27bcb4add38a5f0f3a5c7e409c230bf4ba9afae19bd2e06c2be00d39db59") version("5.5.1", sha256="66f126e5ea46ca761533411f81e83402773f95d3184cb7645ca73df227413023") version("5.5.0", sha256="c031f71cd4b6eaf98664fd2ad50fc18f7ccbfa67be415dca425169d2d1c81e9e") - version("5.4.3", sha256="d133e14ea6d27d358d1bd4d31b79fb1562d1aea7c400e5a2d28d0f159cb6c8a8") - version("5.4.0", sha256="a4799fb1086da3f70c9b95effb1f5f9033c861685e960a8759278463cc55a971") - version("5.3.3", sha256="0c2fc8d437efaf5c4c859d97adb049d4025025d0be0e0908f59a8112508234e5") - version("5.3.0", sha256="0e11b12f208d2751e3e507e3a32403c9bd45da4e191671d765d33abd727d9b96") with default_args(deprecated=True): - version("5.2.3", sha256="0f5ef39c5faab31eb34b48391d58096463969c133ca7ed09ab4e43caa5461b29") - version("5.2.1", sha256="5df35ff0970b83d68b69a07ae9ebb62955faac7401c91daa7929664fdd09d69b") - version("5.2.0", sha256="afa126218485586682c78e97df8025ae4efd32f3751c340e84c436e08868c326") - version("5.1.3", sha256="8d92de1e69815d92a423b7657f2f37c90f1d427f5bc92915c202d4c266254dad") - version("5.1.0", sha256="fee779ae3d55b97327d87beca784fc090fa02bc95238d9c3bf3021e266e73979") + version("5.4.3", sha256="d133e14ea6d27d358d1bd4d31b79fb1562d1aea7c400e5a2d28d0f159cb6c8a8") + version("5.4.0", sha256="a4799fb1086da3f70c9b95effb1f5f9033c861685e960a8759278463cc55a971") + version("5.3.3", sha256="0c2fc8d437efaf5c4c859d97adb049d4025025d0be0e0908f59a8112508234e5") + version("5.3.0", sha256="0e11b12f208d2751e3e507e3a32403c9bd45da4e191671d765d33abd727d9b96") + + depends_on("cxx", type="build") # generated amdgpu_targets = ROCmPackage.amdgpu_targets @@ -52,11 +52,6 @@ class Rocthrust(CMakePackage): depends_on("googletest@1.10.0:", type="test") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -69,17 +64,24 @@ class Rocthrust(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hip@{ver}", when=f"@{ver}") depends_on(f"rocprim@{ver}", when=f"@{ver}") depends_on(f"rocm-cmake@{ver}:", type="build", when=f"@{ver}") + def check(self): + with working_dir(self.builder.build_directory): + make("test") + def setup_build_environment(self, env): env.set("CXX", self.spec["hip"].hipcc) def cmake_args(self): args = [ - self.define("CMAKE_MODULE_PATH", "{0}/cmake".format(self.spec["hip"].prefix)), + self.define("CMAKE_MODULE_PATH", "{0}/lib/cmake/hip".format(self.spec["hip"].prefix)), self.define("BUILD_TEST", self.run_tests), ] diff --git a/var/spack/repos/builtin/packages/roctracer-dev-api/package.py b/var/spack/repos/builtin/packages/roctracer-dev-api/package.py index 3f0a4a6197e989..d86e278afed71c 100644 --- a/var/spack/repos/builtin/packages/roctracer-dev-api/package.py +++ b/var/spack/repos/builtin/packages/roctracer-dev-api/package.py @@ -13,12 +13,15 @@ class RoctracerDevApi(Package): homepage = "https://github.com/ROCm/roctracer" git = "https://github.com/ROCm/roctracer.git" - url = "https://github.com/ROCm/roctracer/archive/refs/tags/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/roctracer/archive/refs/tags/rocm-6.1.2.tar.gz" tags = ["rocm"] license("MIT") maintainers("srekolam", "renjithravindrankannath") + version("6.1.2", sha256="073e67e728d5eda16d7944f3abd96348b3f278e9f36cab3ac22773ebaad0d2d6") + version("6.1.1", sha256="9cb77fd700a0d615056f0db1e9500b73bd0352214f33bdac520e25b9125a926a") + version("6.1.0", sha256="3f8e296c4d04123a7177d815ca166e978b085ad7c816ac298e6bb47a299fa187") version("6.0.2", sha256="1e0105b32fdd9c010aab304bb2ca1a5a38ba323cea610afe1135657edda8f26e") version("6.0.0", sha256="941166a0363c5689bfec118d54e986c43fb1ec8cbf18d95721d9a824bd52c0f8") version("5.7.1", sha256="ec0453adac7e62b142eb0df1e1e2506863aac4c3f2ce9d117c3184c08c0c6b48") @@ -27,16 +30,13 @@ class RoctracerDevApi(Package): version("5.6.0", sha256="cbcfe4fa2e8b627006b320a93992fb3078696d8ef2ef049b4b880b6b7d57e13e") version("5.5.1", sha256="3afc31ebfdb14b0365185ca6b9326a83b1503a94a51d910f5ce7ced192d8c133") version("5.5.0", sha256="fe9ad95628fa96639db6fc33f78d334c814c7161b4a754598f5a4a7852625777") - version("5.4.3", sha256="6b5111be5efd4d7fd6935ca99b06fab19b43d97a58d26fc1fe6e783c4de9a926") - version("5.4.0", sha256="04c1e955267a3e8440833a177bb976f57697aba0b90c325d07fc0c6bd4065aea") - version("5.3.3", sha256="f2cb1e6bb69ea1a628c04f984741f781ae1d8498dc58e15795bb03015f924d13") - version("5.3.0", sha256="36f1da60863a113bb9fe2957949c661f00a702e249bb0523cda1fb755c053808") with default_args(deprecated=True): - version("5.2.3", sha256="93f4bb7529db732060bc12055aa10dc346a459a1086cddd5d86c7b509301be4f") - version("5.2.1", sha256="e200b5342bdf840960ced6919d4bf42c8f30f8013513f25a2190ee8767667e59") - version("5.2.0", sha256="9747356ce61c57d22c2e0a6c90b66a055e435d235ba3459dc3e3f62aabae6a03") - version("5.1.3", sha256="45f19875c15eb609b993788b47fd9c773b4216074749d7744f3a671be17ef33c") - version("5.1.0", sha256="58b535f5d6772258190e4adcc23f37c916f775057a91b960e1f2ee1f40ed5aac") + version("5.4.3", sha256="6b5111be5efd4d7fd6935ca99b06fab19b43d97a58d26fc1fe6e783c4de9a926") + version("5.4.0", sha256="04c1e955267a3e8440833a177bb976f57697aba0b90c325d07fc0c6bd4065aea") + version("5.3.3", sha256="f2cb1e6bb69ea1a628c04f984741f781ae1d8498dc58e15795bb03015f924d13") + version("5.3.0", sha256="36f1da60863a113bb9fe2957949c661f00a702e249bb0523cda1fb755c053808") + + depends_on("cxx", type="build") # generated def install(self, spec, prefix): source_directory = self.stage.source_path diff --git a/var/spack/repos/builtin/packages/roctracer-dev/package.py b/var/spack/repos/builtin/packages/roctracer-dev/package.py index f72e77e5004d32..a2b145a8ce0bbe 100644 --- a/var/spack/repos/builtin/packages/roctracer-dev/package.py +++ b/var/spack/repos/builtin/packages/roctracer-dev/package.py @@ -15,13 +15,16 @@ class RoctracerDev(CMakePackage, ROCmPackage): homepage = "https://github.com/ROCm/roctracer" git = "https://github.com/ROCm/roctracer.git" - url = "https://github.com/ROCm/roctracer/archive/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/roctracer/archive/rocm-6.1.2.tar.gz" tags = ["rocm"] maintainers("srekolam", "renjithravindrankannath") libraries = ["libroctracer64"] license("MIT") + version("6.1.2", sha256="073e67e728d5eda16d7944f3abd96348b3f278e9f36cab3ac22773ebaad0d2d6") + version("6.1.1", sha256="9cb77fd700a0d615056f0db1e9500b73bd0352214f33bdac520e25b9125a926a") + version("6.1.0", sha256="3f8e296c4d04123a7177d815ca166e978b085ad7c816ac298e6bb47a299fa187") version("6.0.2", sha256="1e0105b32fdd9c010aab304bb2ca1a5a38ba323cea610afe1135657edda8f26e") version("6.0.0", sha256="941166a0363c5689bfec118d54e986c43fb1ec8cbf18d95721d9a824bd52c0f8") version("5.7.1", sha256="ec0453adac7e62b142eb0df1e1e2506863aac4c3f2ce9d117c3184c08c0c6b48") @@ -30,27 +33,21 @@ class RoctracerDev(CMakePackage, ROCmPackage): version("5.6.0", sha256="cbcfe4fa2e8b627006b320a93992fb3078696d8ef2ef049b4b880b6b7d57e13e") version("5.5.1", sha256="3afc31ebfdb14b0365185ca6b9326a83b1503a94a51d910f5ce7ced192d8c133") version("5.5.0", sha256="fe9ad95628fa96639db6fc33f78d334c814c7161b4a754598f5a4a7852625777") - version("5.4.3", sha256="6b5111be5efd4d7fd6935ca99b06fab19b43d97a58d26fc1fe6e783c4de9a926") - version("5.4.0", sha256="04c1e955267a3e8440833a177bb976f57697aba0b90c325d07fc0c6bd4065aea") - version("5.3.3", sha256="f2cb1e6bb69ea1a628c04f984741f781ae1d8498dc58e15795bb03015f924d13") - version("5.3.0", sha256="36f1da60863a113bb9fe2957949c661f00a702e249bb0523cda1fb755c053808") with default_args(deprecated=True): - version("5.2.3", sha256="93f4bb7529db732060bc12055aa10dc346a459a1086cddd5d86c7b509301be4f") - version("5.2.1", sha256="e200b5342bdf840960ced6919d4bf42c8f30f8013513f25a2190ee8767667e59") - version("5.2.0", sha256="9747356ce61c57d22c2e0a6c90b66a055e435d235ba3459dc3e3f62aabae6a03") - version("5.1.3", sha256="45f19875c15eb609b993788b47fd9c773b4216074749d7744f3a671be17ef33c") - version("5.1.0", sha256="58b535f5d6772258190e4adcc23f37c916f775057a91b960e1f2ee1f40ed5aac") + version("5.4.3", sha256="6b5111be5efd4d7fd6935ca99b06fab19b43d97a58d26fc1fe6e783c4de9a926") + version("5.4.0", sha256="04c1e955267a3e8440833a177bb976f57697aba0b90c325d07fc0c6bd4065aea") + version("5.3.3", sha256="f2cb1e6bb69ea1a628c04f984741f781ae1d8498dc58e15795bb03015f924d13") + version("5.3.0", sha256="36f1da60863a113bb9fe2957949c661f00a702e249bb0523cda1fb755c053808") + + depends_on("cxx", type="build") # generated + + variant("asan", default=False, description="Build with address-sanitizer enabled or disabled") depends_on("cmake@3:", type="build") depends_on("python@3:", type="build") depends_on("py-cppheaderparser", type="build") for ver in [ - "5.1.0", - "5.1.3", - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -63,15 +60,30 @@ class RoctracerDev(CMakePackage, ROCmPackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on(f"hsakmt-roct@{ver}", when=f"@{ver}") depends_on(f"hsa-rocr-dev@{ver}", when=f"@{ver}") depends_on(f"rocminfo@{ver}", when=f"@{ver}") depends_on(f"hip@{ver}", when=f"@{ver}") - for ver in ["5.1.0", "5.1.3", "5.2.0", "5.2.1", "5.2.3", "5.3.0", "5.3.3", "5.4.0", "5.4.3"]: + for ver in ["5.3.0", "5.3.3", "5.4.0", "5.4.3"]: depends_on(f"rocprofiler-dev@{ver}", when=f"@{ver}") - for ver in ["5.5.0", "5.5.1", "5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in [ + "5.5.0", + "5.5.1", + "5.6.0", + "5.6.1", + "5.7.0", + "5.7.1", + "6.0.0", + "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", + ]: depends_on(f"rocm-core@{ver}", when=f"@{ver}") patch("0001-include-rocprofiler-dev-path.patch", when="@5.3:5.4") @@ -101,6 +113,10 @@ def patch(self): "hsaap.py", ) + def setup_build_environment(self, env): + if self.spec.satisfies("+asan"): + self.asan_on(env) + def cmake_args(self): args = [ self.define("HIP_VDI", "1"), @@ -114,3 +130,9 @@ def cmake_args(self): args.append("-DCMAKE_INSTALL_LIBDIR=lib") return args + + @run_after("install") + def post_install(self): + if self.spec.satisfies("@6.0:"): + install_tree(self.prefix.include.roctracer, self.prefix.roctracer.include) + install_tree(self.prefix.lib, self.prefix.roctracer.lib) diff --git a/var/spack/repos/builtin/packages/rocwmma/package.py b/var/spack/repos/builtin/packages/rocwmma/package.py index 276bf96faffa0d..b7275d02c54613 100644 --- a/var/spack/repos/builtin/packages/rocwmma/package.py +++ b/var/spack/repos/builtin/packages/rocwmma/package.py @@ -21,12 +21,15 @@ class Rocwmma(CMakePackage): homepage = "https://github.com/ROCm/rocWMMA" git = "https://github.com/ROCm/rocWMMA.git" - url = "https://github.com/ROCm/rocWMMA/archive/refs/tags/rocm-6.0.2.tar.gz" + url = "https://github.com/ROCm/rocWMMA/archive/refs/tags/rocm-6.1.2.tar.gz" tags = ["rocm"] license("MIT") maintainers("srekolam", "renjithravindrankannath") + version("6.1.2", sha256="7f6171bea5c8b7cdaf5c64dbfb76eecf606f2d34e8409153a74b56027c5e92a7") + version("6.1.1", sha256="6e0c15c78feb8fb475ed028ed9b0337feeb45bfce1e206fe5f236a55e33f6135") + version("6.1.0", sha256="ca29f33cfe6894909159ad68d786eacd469febab33883886a202f13ae061f691") version("6.0.2", sha256="61c6cc095b4ac555f4be4b55f6a7e3194c8c54bffc57bfeb0c02191119ac5dc8") version("6.0.0", sha256="f9e97e7c6c552d43ef8c7348e4402bead2cd978d0f81a9657d6a0f6c83a6139b") version("5.7.1", sha256="a998a1385e6ad7062707ddb9ff82bef727ca48c39a10b4d861667024e3ffd2a3") @@ -35,14 +38,13 @@ class Rocwmma(CMakePackage): version("5.6.0", sha256="78b6ab10fce71d10a9d762b2eaab3390eb13b05c764f47a3b0a303ec3d37acf8") version("5.5.1", sha256="ada30d5e52df5da0d3f4e212a25efb492dbedc129628f4db4ef4ed77667da228") version("5.5.0", sha256="b9e1938cba111eeea295414c42de34d54a878f0d41a26e433809d60c12d31dbf") - version("5.4.3", sha256="0968366c83b78a9d058d483be536aba03e79b300ccb6890d3da43298be54c288") - version("5.4.0", sha256="a18724c3b45d171e54ef9f85c269124ce8d29b6a2f9dbd76a4806bda2933f7a7") - version("5.3.3", sha256="cd9bc09f98fb78e53ba4bde1dcfe1817c34c2822234a82b1128d36d92b97ae79") - version("5.3.0", sha256="04bac641ba18059118d3faa5f21fe3bf3e285055d40930489ebf27ffc8e5d16e") with default_args(deprecated=True): - version("5.2.3", sha256="7f42e9742eff258f7c09c518c5ea9c71a224574e1c075d7e1c4e464192fc4920") - version("5.2.1", sha256="73adb6a0ae99051493459a9902ad718b0452d6d819583a58d713ce52fa813f21") - version("5.2.0", sha256="257ccd1cf2bc1d8064e72e78d276ef7446b2cb7e2dec05ff8331bb44eff2b7cb") + version("5.4.3", sha256="0968366c83b78a9d058d483be536aba03e79b300ccb6890d3da43298be54c288") + version("5.4.0", sha256="a18724c3b45d171e54ef9f85c269124ce8d29b6a2f9dbd76a4806bda2933f7a7") + version("5.3.3", sha256="cd9bc09f98fb78e53ba4bde1dcfe1817c34c2822234a82b1128d36d92b97ae79") + version("5.3.0", sha256="04bac641ba18059118d3faa5f21fe3bf3e285055d40930489ebf27ffc8e5d16e") + + depends_on("cxx", type="build") # generated # gfx908:xnack-;gfx90a:xnack-;gfx90a:xnack+ # are only targets currently supported for @5.2.0 @@ -68,9 +70,6 @@ class Rocwmma(CMakePackage): depends_on("googletest@1.10.0:", type="test") for ver in [ - "5.2.0", - "5.2.1", - "5.2.3", "5.3.0", "5.3.3", "5.4.0", @@ -83,6 +82,9 @@ class Rocwmma(CMakePackage): "5.7.1", "6.0.0", "6.0.2", + "6.1.0", + "6.1.1", + "6.1.2", ]: depends_on("rocm-cmake@%s:" % ver, type="build", when="@" + ver) depends_on("llvm-amdgpu@" + ver, type="build", when="@" + ver) @@ -90,7 +92,7 @@ class Rocwmma(CMakePackage): depends_on("rocblas@" + ver, type="build", when="@" + ver) depends_on("rocm-openmp-extras@" + ver, type="build", when="@" + ver) - for ver in ["5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in ["5.6.0", "5.6.1", "5.7.0", "5.7.1", "6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: depends_on("rocm-smi-lib@" + ver, when="@" + ver) for tgt in itertools.chain(["auto"], amdgpu_targets): diff --git a/var/spack/repos/builtin/packages/roms/package.py b/var/spack/repos/builtin/packages/roms/package.py index 1f8b78c80eaa65..4514a1c67eb164 100644 --- a/var/spack/repos/builtin/packages/roms/package.py +++ b/var/spack/repos/builtin/packages/roms/package.py @@ -22,6 +22,8 @@ class Roms(MakefilePackage): version("3.9", sha256="8e93f6ed40040e3f1b88d456ea9411ed3c06f280dc50b2787d6e5f793f58f1bc") version("3.8", sha256="99fb69239e70edaef35771d82e203e43cd301dde4f2a5662da038499b7258ae7") + depends_on("fortran", type="build") # generated + variant("openmp", default=False, description="Turn on shared-memory parallelization in ROMS") variant("mpi", default=True, description="Turn on distributed-memory parallelization in ROMS") variant( diff --git a/var/spack/repos/builtin/packages/root/package.py b/var/spack/repos/builtin/packages/root/package.py index 5bdaed289a35c3..d797a4c33a45c3 100644 --- a/var/spack/repos/builtin/packages/root/package.py +++ b/var/spack/repos/builtin/packages/root/package.py @@ -4,6 +4,7 @@ # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os import sys from spack.operating_systems.mac_os import macos_version @@ -22,9 +23,7 @@ class Root(CMakePackage): tags = ["hep"] - maintainers( - "drbenmorgan", "gartung", "greenc-FNAL", "HadrienG2", "marcmengel", "vitodb", "vvolkl" - ) + maintainers("drbenmorgan", "gartung", "greenc-FNAL", "marcmengel", "vitodb", "vvolkl") # ###################### Versions ########################## @@ -35,8 +34,14 @@ class Root(CMakePackage): version("develop", branch="master") # Production version + version("6.32.02", sha256="3d0f76bf05857e1807ccfb2c9e014f525bcb625f94a2370b455f4b164961602d") + version("6.32.00", sha256="12f203681a59041c474ce9523761e6f0e8861b3bee78df5f799a8db55189e5d2") + version("6.30.08", sha256="8bb8594867b9ded20a65e59f2cb6da965aa30851b8960f8cbf76293aec046b69") + version("6.30.06", sha256="300db7ed1b678ed2fb9635ca675921a1945c7c2103da840033b493091f55700c") + version("6.30.04", sha256="2b4180b698f39cc65d91084d833a884515b325bc5f673c8e39abe818b025d8cc") version("6.30.02", sha256="7965a456d1ad1ee0d5fe4769bf5a8fec291af684ed93db0f3080a9c362435183") version("6.30.00", sha256="0592c066954cfed42312957c9cb251654456064fe2d8dabdcb8826f1c0099d71") + version("6.28.12", sha256="fcd325267d238e9c6008f56a3a7e7c87fd864b1e633b0ffcf1f82b7e7ad3d249") version("6.28.10", sha256="69d6fdeb607e6b20bd02c757fa6217024c0b6132c1e9b1dff4d85d9a2bb7e51e") version("6.28.06", sha256="af3b673b9aca393a5c9ae1bf86eab2672aaf1841b658c5c6e7a30ab93c586533") version("6.28.04", sha256="70f7f86a0cd5e3f2a0befdc59942dd50140d990ab264e8e56c7f17f6bfe9c965") @@ -51,6 +56,7 @@ class Root(CMakePackage): version("6.26.00", sha256="5fb9be71fdf0c0b5e5951f89c2f03fcb5e74291d043f6240fb86f5ca977d4b31") version("6.24.08", sha256="882c41fe36e94456fb10443d08ef9152375a90d1f910a10add1793d6e838bc44") version("6.24.06", sha256="907f69f4baca1e4f30eeb4979598ca7599b6aa803ca046e80e25b6bbaa0ef522") + version("6.24.04", sha256="4a416f3d7aa25dba46d05b641505eb074c5f07b3ec1d21911451046adaea3ee7") version("6.24.02", sha256="0507e1095e279ccc7240f651d25966024325179fa85a1259b694b56723ad7c1c") version("6.24.00", sha256="9da30548a289211c3122d47dacb07e85d35e61067fac2be6c5a5ff7bda979989") version("6.22.08", sha256="6f061ff6ef8f5ec218a12c4c9ea92665eea116b16e1cd4df4f96f00c078a2f6f") @@ -81,6 +87,10 @@ class Root(CMakePackage): version("6.06.04", sha256="ab86dcc80cbd8e704099af0789e23f49469932ac4936d2291602301a7aa8795b") version("6.06.02", sha256="18a4ce42ee19e1a810d5351f74ec9550e6e422b13b5c58e0c3db740cdbc569d1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # ###################### Patches ########################## # Widely used patch (CMS, FNAL) to increase the size of static @@ -117,6 +127,18 @@ class Root(CMakePackage): patch("webgui.patch", level=0, when="@6.26.00:6.26.10,6.28.00:6.28.08,6.30.00 +webgui") + # Back-ported patches fixing segfault in weighted likelihood fits + patch( + "https://github.com/root-project/root/commit/2f00d6df258906c1f6fe848135a88b836db3077f.patch?full_index=1", + sha256="8da36032082e65ae246c03558a4c3fd67b157d1d0c6d20adac9de263279d1db6", + when="@6.28:6.28.12", + ) + patch( + "https://github.com/root-project/root/commit/14838b35600b08278e69bc3d8d8669773bc11399.patch?full_index=1", + sha256="4647898ef28cb1adbaacdeedb04b417d69ccbaf02fc2b3aab20e07c0b2a96a0f", + when="@6.30:6.30.04", + ) + if sys.platform == "darwin": # Resolve non-standard use of uint, _cf_ # https://sft.its.cern.ch/jira/browse/ROOT-7886. @@ -130,6 +152,12 @@ class Root(CMakePackage): sha256="559495f7bdd6b7674d3b1019da9b76e8b374f6dca3dbe72fb1320b0be2b00e53", when="@6.30:6.30.3 ~aqua", ) + # Fix build issues with libAfterImage for macOS + patch( + "https://github.com/root-project/root/pull/15044.patch?full_index=1", + sha256="e68be5fe7b1ec873da134bd39c5c72730c4ca06d51b52eb436ae44fe81cd472d", + when="@:6.30.04 +x", + ) # ###################### Variants ########################## # See README.md for specific notes about what ROOT configuration @@ -259,6 +287,11 @@ class Root(CMakePackage): depends_on("cmake@3.19:", type="build", when="@6.28.00: platform=darwin") depends_on("pkgconfig", type="build") + # 6.32.00 requires sys/random.h + with when("@6.32.00:"): + depends_on("glibc@2.25:", when="^[virtuals=libc] glibc") + depends_on("musl@1.1.20:", when="^[virtuals=libc] musl") + depends_on("freetype") depends_on("jpeg") depends_on("libice") @@ -347,7 +380,8 @@ class Root(CMakePackage): depends_on("vc@1.3.0:", when="@6.09.02: +vc") depends_on("vc@1.4.4:", when="@6.29.02: +vc") depends_on("vdt", when="+vdt") - depends_on("veccore", when="+veccore") + depends_on("veccore@0.4.0:", when="@6.09.04: +veccore") + depends_on("veccore@0.4.2:", when="@6.11.02: +veccore") depends_on("libxml2", when="+xml") depends_on("xrootd", when="+xrootd") depends_on("xrootd@:4", when="@:6.22.03 +xrootd") @@ -522,7 +556,6 @@ def cmake_args(self): # Options controlling gross build / config behavior. options += [ - define("exceptions", True), define("explicitlink", True), define("fail-on-missing", True), define_from_variant("fortran"), @@ -542,16 +575,18 @@ def cmake_args(self): define("CLING_CXX_PATH", self.compiler.cxx), ] - if self.spec.satisfies("@:6.28.99"): + if self.spec.satisfies("@:6.28"): options.append(define("cxxmodules", False)) + if self.spec.satisfies("@:6.30"): + options.append(define("exceptions", True)) + # Options related to ROOT's ability to download and build its own # dependencies. Per Spack convention, this should generally be avoided. afterimage_enabled = ("+x" in self.spec) if "platform=darwin" not in self.spec else True options += [ - define("builtin_afterimage", afterimage_enabled), define("builtin_cfitsio", False), define("builtin_davix", False), define("builtin_fftw3", False), @@ -576,6 +611,9 @@ def cmake_args(self): define("builtin_zlib", False), ] + if self.spec.satisfies("@:6.32"): + options.append(define("builtin_afterimage", afterimage_enabled)) + # Features options += [ define("afdsmrgd", False), @@ -614,7 +652,6 @@ def cmake_args(self): define_from_variant("memstat"), # See conflicts define("minimal", False), define_from_variant("minuit"), - define_from_variant("minuit2", "minuit"), define_from_variant("mlp"), define("monalisa", False), define_from_variant("mysql"), @@ -679,6 +716,9 @@ def cmake_args(self): if self.spec.satisfies("@6.25.02:"): options.append(define_from_variant("tmva-sofie")) + if self.spec.satisfies("@:6.30"): + options.append(define_from_variant("minuit2", "minuit")) + # #################### Compiler options #################### if sys.platform == "darwin" and self.compiler.cc == "gcc": @@ -731,13 +771,22 @@ def add_include_path(dep_name): add_include_path("xproto") if "+opengl" in spec and "platform=darwin" not in spec: add_include_path("glew") - add_include_path("mesa-glu") + add_include_path("glu") if "platform=darwin" in spec: # Newer deployment targets cause fatal errors in rootcling, so # override with an empty value even though it may lead to link # warnings when building against ROOT env.unset("MACOSX_DEPLOYMENT_TARGET") + @property + def root_library_path(self): + # Where possible, we do not use LD_LIBRARY_PATH as that is non-portable + # and pollutes the standard library-loading mechanisms on Linux systems. + # The ROOT_LIBRARY_PATH environment variable was added to ROOT 6.26. + if self.spec.satisfies("@:6.25"): + return "LD_LIBRARY_PATH" + return "ROOT_LIBRARY_PATH" + def setup_run_environment(self, env): env.set("ROOTSYS", self.prefix) env.set("ROOT_VERSION", "v{0}".format(self.version.up_to(1))) @@ -745,8 +794,12 @@ def setup_run_environment(self, env): # the following vars are copied from thisroot.sh; silence a cppyy warning env.set("CLING_STANDARD_PCH", "none") env.set("CPPYY_API_PATH", "none") + if "+rpath" not in self.spec: + env.prepend_path(self.root_library_path, self.prefix.lib.root) - def setup_dependent_build_environment(self, env, dependent_spec): + def setup_dependent_build_environment( + self, env: spack.util.environment.EnvironmentModifications, dependent_spec + ): env.set("ROOTSYS", self.prefix) env.set("ROOT_VERSION", "v{0}".format(self.version.up_to(1))) env.prepend_path("PYTHONPATH", self.prefix.lib.root) @@ -754,16 +807,20 @@ def setup_dependent_build_environment(self, env, dependent_spec): env.append_path("CMAKE_MODULE_PATH", self.prefix.cmake) env.prepend_path("ROOT_INCLUDE_PATH", dependent_spec.prefix.include) if "+rpath" not in self.spec: - env.prepend_path("LD_LIBRARY_PATH", self.prefix.lib.root) + env.prepend_path(self.root_library_path, self.prefix.lib.root) if "platform=darwin" in self.spec: # Newer deployment targets cause fatal errors in rootcling env.unset("MACOSX_DEPLOYMENT_TARGET") - def setup_dependent_run_environment(self, env, dependent_spec): - env.set("ROOTSYS", self.prefix) - env.set("ROOT_VERSION", "v{0}".format(self.version.up_to(1))) - env.prepend_path("PYTHONPATH", self.prefix.lib.root) - env.prepend_path("PATH", self.prefix.bin) + def setup_dependent_run_environment( + self, env: spack.util.environment.EnvironmentModifications, dependent_spec + ): env.prepend_path("ROOT_INCLUDE_PATH", dependent_spec.prefix.include) - if "+rpath" not in self.spec: - env.prepend_path("LD_LIBRARY_PATH", self.prefix.lib.root) + # For dependents that build dictionaries, ROOT needs to know where the + # dictionaries have been installed. This can be facilitated by + # automatically prepending dependent package library paths to + # ROOT_LIBRARY_PATH (for @6.26:) or LD_LIBRARY_PATH (for older + # versions). + for lib_path in (dependent_spec.prefix.lib, dependent_spec.prefix.lib64): + if os.path.exists(lib_path): + env.prepend_path(self.root_library_path, lib_path) diff --git a/var/spack/repos/builtin/packages/rosco/intel-oneapi-29.patch b/var/spack/repos/builtin/packages/rosco/intel-oneapi-29.patch new file mode 100644 index 00000000000000..58d6e4bd076fe6 --- /dev/null +++ b/var/spack/repos/builtin/packages/rosco/intel-oneapi-29.patch @@ -0,0 +1,13 @@ +diff --git a/rosco/controller/CMakeLists.txt b/rosco/controller/CMakeLists.txt +index 0d29085..46705c2 100644 +--- a/rosco/controller/CMakeLists.txt ++++ b/rosco/controller/CMakeLists.txt +@@ -11,7 +11,7 @@ endif() + message(STATUS "CMAKE_Fortran_COMPILER_ID = ${CMAKE_Fortran_COMPILER_ID}") + if(APPLE OR UNIX) + # Enable .dll export +-if (CMAKE_Fortran_COMPILER_ID STREQUAL "Intel") ++if (CMAKE_Fortran_COMPILER_ID MATCHES "^Intel") + set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -DIMPLICIT_DLLEXPORT -r8 -double-size 64 -cpp -no-wrap-margin") + else() + set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -DIMPLICIT_DLLEXPORT -ffree-line-length-0 -fdefault-real-8 -fdefault-double-8 -cpp") diff --git a/var/spack/repos/builtin/packages/rosco/intel-oneapi-2x.patch b/var/spack/repos/builtin/packages/rosco/intel-oneapi-2x.patch new file mode 100644 index 00000000000000..fce7258e2035de --- /dev/null +++ b/var/spack/repos/builtin/packages/rosco/intel-oneapi-2x.patch @@ -0,0 +1,13 @@ +diff --git a/ROSCO/CMakeLists.txt b/ROSCO/CMakeLists.txt +index b450a30..9506267 100644 +--- a/ROSCO/CMakeLists.txt ++++ b/ROSCO/CMakeLists.txt +@@ -11,7 +11,7 @@ endif() + message(STATUS "CMAKE_Fortran_COMPILER_ID = ${CMAKE_Fortran_COMPILER_ID}") + if(APPLE OR UNIX) + # Enable .dll export +-if (CMAKE_Fortran_COMPILER_ID STREQUAL "Intel") ++if (CMAKE_Fortran_COMPILER_ID MATCHES "^Intel") + set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -DIMPLICIT_DLLEXPORT -r8 -double-size 64 -cpp -no-wrap-margin") + else() + set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -DIMPLICIT_DLLEXPORT -ffree-line-length-0 -fdefault-real-8 -fdefault-double-8 -cpp") diff --git a/var/spack/repos/builtin/packages/rosco/package.py b/var/spack/repos/builtin/packages/rosco/package.py new file mode 100644 index 00000000000000..59c33292ade4d7 --- /dev/null +++ b/var/spack/repos/builtin/packages/rosco/package.py @@ -0,0 +1,66 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Rosco(CMakePackage): + """ + ROSCO controls package for OpenFAST from NREL + Note: this only builds ROSCO controls library for inclusion with OpenFAST + If the toolbox or tuning scripts are needed, please build manually + """ + + homepage = "https://rosco.readthedocs.io/en/latest/" + url = "https://github.com/NREL/ROSCO/archive/refs/tags/v2.9.0.tar.gz" + git = "https://github.com/NREL/ROSCO.git" + + maintainers("dzalkind", "ndevelder") + + version("develop", branch="develop") + version("main", branch="main") + version("2.9.0", sha256="eb7f6220207b8a07c9570fb64bab591906b0c19d73ac4c24bb8dca252722ca79") + version("2.8.0", sha256="7a2e3a7bebdf6ee73884a9e3502f904cc3a3f1aa1bf672c223ecbaa041bfc48f") + version("2.7.0", sha256="b6a2cda92680cf6a460d194901a2f16c2635710a82788576a6383a3bb189fc83") + version("2.6.0", sha256="ca1c1a6ac53e8220b107accccfb8b5299772c38b7c77cd8d2ba383e9825daeaa") + version("2.5.1", sha256="55fe7bba612321baa6e089ee1156ef4db2e3bccf1b69534829b06f3367fff05d") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("shared", default=False, description="Build shared libraries") + variant("pic", default=False, description="Position independent code") + + patch("intel-oneapi-2x.patch", when="@2.5:2.8%oneapi") + patch("intel-oneapi-29.patch", when="@2.9.0:2.9.1%oneapi") + + @property + def root_cmakelists_dir(self): + if self.spec.version >= Version("2.9.0"): + return "rosco/controller" + else: + return "ROSCO" + + def cmake_args(self): + options = [] + + options.extend( + [ + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + self.define_from_variant("CMAKE_POSITION_INDEPENDENT_CODE", "pic"), + ] + ) + + return options + + def setup_run_environment(self, env): + env.set("ROSCO_DISCON", self.prefix.lib + "/libdiscon.so") + env.set("ROSCO_DISCON_DIR", self.prefix.lib) + + def flag_handler(self, name, flags): + if name == "fflags" and self.compiler.fc.endswith("gfortran"): + flags.extend(["-ffree-line-length-0"]) + + return (None, None, flags) diff --git a/var/spack/repos/builtin/packages/ross/package.py b/var/spack/repos/builtin/packages/ross/package.py index 53910e4039be0c..77a4cb7fe5a83e 100644 --- a/var/spack/repos/builtin/packages/ross/package.py +++ b/var/spack/repos/builtin/packages/ross/package.py @@ -17,6 +17,7 @@ class Ross(CMakePackage): version("develop", branch="develop") version("master", branch="master") + version("8.0.0", sha256="5339c9afcf77821fb6ebbcd93b8a1e651c7883e94dff250528815a08f84f1694") version("7.2.0", sha256="c937f4c7baa1918b6cd08f4eafae8cab44eddcd4aaa1175c23ff8562583ad726") version("7.1.1", sha256="550e3288cefedcbc7e6ca16cfbee0477b70399d63e94f554b60b32d714029722") version("7.1.0", sha256="478063f36d96466faef3db3cc15e1c0e1a8b60b9152fcce0eedf367be8252733") @@ -24,6 +25,8 @@ class Ross(CMakePackage): version("7.0.0", sha256="fd16be2c86d9d71ae64eef67c02933471ab758c8a5b01b04fe358d9228fc581e") version("6.0.0", sha256="07ff70518a58503e116bb7386f490e901212798afdd471da1bcd34f78a7e6030") + depends_on("c", type="build") # generated + depends_on("mpi") depends_on("cmake@3.5:", when="@7.0.1:", type="build") @@ -32,8 +35,8 @@ def cmake_args(self): args = [] args.append("-DBUILD_SHARED_LIBS=ON") - args.append("-DARCH=%s" % self.spec.target) - args.append("-DCMAKE_C_COMPILER=%s" % self.spec["mpi"].mpicc) - args.append("-DCMAKE_CXX_COMPILER=%s" % self.spec["mpi"].mpicxx) + args.append(f"-DARCH={self.spec.target}") + args.append(f"-DCMAKE_C_COMPILER={self.spec['mpi'].mpicc}") + args.append(f"-DCMAKE_CXX_COMPILER={self.spec['mpi'].mpicxx}") return args diff --git a/var/spack/repos/builtin/packages/routino/package.py b/var/spack/repos/builtin/packages/routino/package.py index 602e18a3079266..33dd2f9037d206 100644 --- a/var/spack/repos/builtin/packages/routino/package.py +++ b/var/spack/repos/builtin/packages/routino/package.py @@ -17,6 +17,9 @@ class Routino(MakefilePackage): version("3.3.3", sha256="abd82b77c314048f45030f7219887ca241b46d40641db6ccb462202b97a047f5") version("3.2", sha256="e2a431eaffbafab630835966d342e4ae25d5edb94c8ed419200e1ffb50bc7552") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("bzip2") diff --git a/var/spack/repos/builtin/packages/rpcsvc-proto/package.py b/var/spack/repos/builtin/packages/rpcsvc-proto/package.py index 30cf5138be5ea5..cd18cc8dd52675 100644 --- a/var/spack/repos/builtin/packages/rpcsvc-proto/package.py +++ b/var/spack/repos/builtin/packages/rpcsvc-proto/package.py @@ -14,11 +14,14 @@ class RpcsvcProto(AutotoolsPackage): license("BSD-3-Clause") + version("1.4.4", sha256="81c3aa27edb5d8a18ef027081ebb984234d5b5860c65bd99d4ac8f03145a558b") version("1.4.3", sha256="69315e94430f4e79c74d43422f4a36e6259e97e67e2677b2c7d7060436bd99b1") version("1.4.2", sha256="678851b9f7ddf4410d2859c12016b65a6dd1a0728d478f18aeb54d165352f17c") version("1.4.1", sha256="9429e143bb8dd33d34bf0663f571d4d4a1103e1afd7c49791b367b7ae1ef7f35") version("1.4", sha256="4149d5f05d8f7224a4d207362fdfe72420989dc1b028b28b7b62b6c2efe22345") + depends_on("c", type="build") # generated + depends_on("gettext") def configure_args(self): @@ -32,6 +35,6 @@ def change_makefile(self): # Add 'cpp' path for rpcgen filter_file( "rpcgen/rpcgen", - "rpcgen/rpcgen -Y {0}/lib/spack/env".format(spack.paths.spack_root), + f"rpcgen/rpcgen -Y {spack.paths.spack_root}/lib/spack/env", "rpcsvc/Makefile", ) diff --git a/var/spack/repos/builtin/packages/rpm/package.py b/var/spack/repos/builtin/packages/rpm/package.py index 840651798bf381..bf1953a27b58ba 100644 --- a/var/spack/repos/builtin/packages/rpm/package.py +++ b/var/spack/repos/builtin/packages/rpm/package.py @@ -27,6 +27,9 @@ class Rpm(AutotoolsPackage): version("4.16.1.2", sha256="3d2807807a8ccaa92a8ced74e09b5bf5b2417a5bbf9bee4abc7c6aa497547bf3") version("4.16.0", sha256="a62b744e3404b107e8467e1a36ff0f2bf9e5c1b748dbfeb36db54bbb859446ea") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "crypto", values=("openssl", "libgcrypt"), diff --git a/var/spack/repos/builtin/packages/rpp/0003-changes-to-rpp-unit-tests-6.1.patch b/var/spack/repos/builtin/packages/rpp/0003-changes-to-rpp-unit-tests-6.1.patch new file mode 100644 index 00000000000000..be8a28b60d9379 --- /dev/null +++ b/var/spack/repos/builtin/packages/rpp/0003-changes-to-rpp-unit-tests-6.1.patch @@ -0,0 +1,56 @@ +From d94cc49d93800b7b50d2582b28a2b6c84fdb166b Mon Sep 17 00:00:00 2001 +From: sreenivasa murthy kolam +Date: Thu, 20 Jun 2024 10:17:09 +0000 +Subject: [PATCH] changes to cmakelists.txt to include half and turbo-jpeg + +--- + utilities/test_suite/HIP/CMakeLists.txt | 4 ++-- + utilities/test_suite/HOST/CMakeLists.txt | 5 ++++- + 2 files changed, 6 insertions(+), 3 deletions(-) + +diff --git a/utilities/test_suite/HIP/CMakeLists.txt b/utilities/test_suite/HIP/CMakeLists.txt +index b8bf361..bfac5ec 100644 +--- a/utilities/test_suite/HIP/CMakeLists.txt ++++ b/utilities/test_suite/HIP/CMakeLists.txt +@@ -80,7 +80,7 @@ if (hip_FOUND AND OpenCV_FOUND) + + add_executable(Tensor_hip Tensor_hip.cpp) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DGPU_SUPPORT=1 -DRPP_BACKEND_HIP=1 -std=gnu++17") +- target_link_libraries(Tensor_hip ${OpenCV_LIBS} -lturbojpeg -lrpp ${hip_LIBRARIES} pthread ${LINK_LIBRARY_LIST} hip::device) ++ target_link_libraries(Tensor_hip ${OpenCV_LIBS} -lrpp ${hip_LIBRARIES} pthread ${LINK_LIBRARY_LIST} hip::device) + else() + message(FATAL_ERROR "-- ${Red}Error: OpenCV and hip must be installed to install ${PROJECT_NAME} successfully!${ColourReset}") + endif() +@@ -96,4 +96,4 @@ if(NIFTI_FOUND AND OpenCV_FOUND) + target_link_libraries(Tensor_voxel_hip ${OpenCV_LIBS} -lturbojpeg -lrpp ${hip_LIBRARIES} pthread ${LINK_LIBRARY_LIST} hip::device ${NIFTI_PACKAGE_PREFIX}NIFTI::${NIFTI_PACKAGE_PREFIX}niftiio) + else() + message("-- ${Yellow}Warning: libniftiio must be installed to install ${PROJECT_NAME}/Tensor_voxel_hip successfully!${ColourReset}") +-endif() +\ No newline at end of file ++endif() +diff --git a/utilities/test_suite/HOST/CMakeLists.txt b/utilities/test_suite/HOST/CMakeLists.txt +index 43be2b2..c119f28 100644 +--- a/utilities/test_suite/HOST/CMakeLists.txt ++++ b/utilities/test_suite/HOST/CMakeLists.txt +@@ -69,6 +69,9 @@ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS} -ggdb -O0") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS}") + set(LINK_LIBRARY_LIST ${LINK_LIBRARY_LIST} OpenMP::OpenMP_CXX) + ++find_path(HALF_INCLUDE_DIR half.hpp) ++include_directories(${HALF_INCLUDE_DIR}) ++ + if(TurboJpeg_FOUND) + message("-- ${Green}${PROJECT_NAME} set to build with rpp and TurboJpeg${ColourReset}") + include_directories(${TurboJpeg_INCLUDE_DIRS}) +@@ -85,7 +88,7 @@ if (OpenCV_FOUND) + + add_executable(Tensor_host Tensor_host.cpp) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++17") +- target_link_libraries(Tensor_host ${OpenCV_LIBS} -lturbojpeg -lrpp pthread ${LINK_LIBRARY_LIST}) ++ target_link_libraries(Tensor_host ${OpenCV_LIBS} -lrpp pthread ${LINK_LIBRARY_LIST}) + else() + message("-- ${Red}Error: OpenCV must be installed to install ${PROJECT_NAME} successfully!${ColourReset}") + endif() +-- +2.39.3 + diff --git a/var/spack/repos/builtin/packages/rpp/package.py b/var/spack/repos/builtin/packages/rpp/package.py index f30b4830e31ba5..957d90bba432d2 100644 --- a/var/spack/repos/builtin/packages/rpp/package.py +++ b/var/spack/repos/builtin/packages/rpp/package.py @@ -15,7 +15,7 @@ class Rpp(CMakePackage): homepage = "https://github.com/GPUOpen-ProfessionalCompute-Libraries/rpp" git = "https://github.com/GPUOpen-ProfessionalCompute-Libraries/rpp.git" - url = "https://github.com/GPUOpen-ProfessionalCompute-Libraries/rpp/archive/refs/tags/rocm-6.0.2.tar.gz" + url = "https://github.com/GPUOpen-ProfessionalCompute-Libraries/rpp/archive/refs/tags/rocm-6.1.2.tar.gz" def url_for_version(self, version): if version >= Version("5.7.0"): @@ -28,7 +28,9 @@ def url_for_version(self, version): maintainers("srekolam", "afzpatel") license("MIT") - + version("6.1.2", sha256="3a529bdd17b448a9e05a6aac1b5e173a077f4a4a1fd2ed759bcea331acd2829f") + version("6.1.1", sha256="9ca385c6f208a0bbf2be60ad15697d35371992d49ed30077b69e22090cef657c") + version("6.1.0", sha256="026c5ac7a92e14e35b9e7630a2ebfff3f4b3544b988eb9aa8af9991d4beea242") version("6.0.2", sha256="2686eb4099233db4444fcd2f77af9b00d38d829f05de2403bed37b1b28f2653c") version("6.0.0", sha256="3626a648bc773520f5cd5ca15f494de6e74b422baf32491750ce0737c3367f15") version("5.7.1", sha256="36fff5f1c52d969c3e2e0c75b879471f731770f193c9644aa6ab993fb8fa4bbf") @@ -40,6 +42,8 @@ def url_for_version(self, version): version("0.99", sha256="f1d7ec65d0148ddb7b3ce836a7e058727036df940d72d1683dee590a913fd44a") version("0.98", sha256="191b5d89bf990ae22b5ef73675b89ed4371c3ce342ab9cc65383fa12ef13086e") version("0.97", sha256="8ce1a869ff67a29579d87d399d8b0bd97bf12ae1b6b1ca1f161cb8a262fb9939") + + depends_on("cxx", type="build") # generated variant( "build_type", default="Release", @@ -63,7 +67,8 @@ def url_for_version(self, version): # adds half.hpp include directory and modifies how the libjpegturbo # library is linked for the rpp unit test - patch("0003-changes-to-rpp-unit-tests.patch", when="+add_tests") + patch("0003-changes-to-rpp-unit-tests.patch", when="@5.7:6.0 +add_tests") + patch("0003-changes-to-rpp-unit-tests-6.1.patch", when="@6.1 +add_tests") def patch(self): if self.spec.satisfies("+hip"): @@ -102,6 +107,18 @@ def patch(self): "utilities/test_suite/HIP/CMakeLists.txt", string=True, ) + filter_file( + "${ROCM_PATH}/share/rpp/test/cmake", + self.spec.prefix.share.rpp.test.cmake, + "utilities/test_suite/HOST/CMakeLists.txt", + string=True, + ) + filter_file( + "${ROCM_PATH}/share/rpp/test/cmake", + self.spec.prefix.share.rpp.test.cmake, + "utilities/test_suite/HIP/CMakeLists.txt", + string=True, + ) depends_on("cmake@3.5:", type="build") depends_on("pkgconfig", type="build") @@ -123,7 +140,7 @@ def patch(self): with when("+hip"): with when("@5.7:"): - for ver in ["5.7.0", "5.7.1", "6.0.0", "6.0.2"]: + for ver in ["5.7.0", "5.7.1", "6.0.0", "6.0.2", "6.1.0", "6.1.1", "6.1.2"]: depends_on("hip@" + ver, when="@" + ver) with when("@:1.2"): depends_on("hip@5:") @@ -133,6 +150,8 @@ def patch(self): def setup_run_environment(self, env): if self.spec.satisfies("+add_tests"): env.set("TURBO_JPEG_PATH", self.spec["libjpeg-turbo"].prefix) + if self.spec.satisfies("@6.1:"): + env.prepend_path("LD_LIBRARY_PATH", self.spec["hsa-rocr-dev"].prefix.lib) def cmake_args(self): spec = self.spec @@ -151,9 +170,3 @@ def cmake_args(self): ) ) return args - - @run_after("install") - def add_tests(self): - if self.spec.satisfies("+add_tests"): - install_tree("utilities", self.spec.prefix.utilities) - install_tree("cmake", self.spec.prefix.cmake) diff --git a/var/spack/repos/builtin/packages/rr/package.py b/var/spack/repos/builtin/packages/rr/package.py index c89b3a457cab07..6c4bdeb11f3c36 100644 --- a/var/spack/repos/builtin/packages/rr/package.py +++ b/var/spack/repos/builtin/packages/rr/package.py @@ -16,6 +16,9 @@ class Rr(CMakePackage): version("4.4.0", sha256="b2b24a3f67df47576126421746cd2942a458d2825faa76e8bb3ca43edffa03d3") version("4.3.0", sha256="46933cdd706d71c3de05b55937c85ee055c08e67e5c1e6a1278c7feb187ca37a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gdb") depends_on("git") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/rsbench/package.py b/var/spack/repos/builtin/packages/rsbench/package.py index 449af96b288108..7c2cd25bbd75f5 100644 --- a/var/spack/repos/builtin/packages/rsbench/package.py +++ b/var/spack/repos/builtin/packages/rsbench/package.py @@ -14,10 +14,14 @@ class Rsbench(MakefilePackage): homepage = "https://github.com/ANL-CESAR/RSBench" url = "https://github.com/ANL-CESAR/RSBench/archive/v2.tar.gz" + version("13", sha256="4ddba1fe2f657103e5e50199b7dd2eab62069ddf17350489c18238908dd73b61") version("12", sha256="2e437dbdaf7bf12bb9ade429d46a9e74fd519fc4686777a452770790d0546499") version("2", sha256="1e97a38a863836e98cedc5cc669f8fdcaed905fafdc921d2bce32319b3e157ff") version("0", sha256="95c06cf4cb6f396f9964d5e4b58a477bf9d7131cd39804480f1cb74e9310b271") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + tags = ["proxy-app"] # To-Do: Add build support for other parallelism versions in v12: @@ -31,24 +35,25 @@ def build_directory(self): @property def build_targets(self): + spec = self.spec targets = [] cflags = "-std=gnu99 -O3" ldflags = "-lm" - if self.compiler.name == "gcc": + if spec.satisfies("%gcc"): cflags += " -ffast-math " - elif self.compiler.name == "intel": + elif spec.satisfies("%intel"): cflags += " -xhost -ansi-alias -no-prec-div " - elif self.compiler.name == "pgi" or self.compiler.name == "nvhpc": + elif spec.satisfies("%pgi") or spec.satisfies("%nvhpc"): cflags += " -fastsse " - elif self.compiler.name == "arm": + elif spec.satisfies("%arm"): cflags += " -ffast-math " cflags += self.compiler.openmp_flag - targets.append("CFLAGS={0}".format(cflags)) - targets.append("LDFLAGS={0}".format(ldflags)) + targets.append(f"CFLAGS={cflags}") + targets.append(f"LDFLAGS={ldflags}") return targets diff --git a/var/spack/repos/builtin/packages/rsem/package.py b/var/spack/repos/builtin/packages/rsem/package.py index 1038f21a63b81a..10169e174b6ffc 100644 --- a/var/spack/repos/builtin/packages/rsem/package.py +++ b/var/spack/repos/builtin/packages/rsem/package.py @@ -19,6 +19,9 @@ class Rsem(MakefilePackage): version("1.3.1", sha256="93c749a03ac16e94b1aab94d032d4fd5687d3261316ce943ecb89d3ae3ec2e11") version("1.3.0", sha256="ecfbb79c23973e1c4134f05201f4bd89b0caf0ce4ae1ffd7c4ddc329ed4e05d2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("r", type=("build", "run")) depends_on("perl", type=("build", "run")) depends_on("python", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/rsl/package.py b/var/spack/repos/builtin/packages/rsl/package.py index 8627f862d63f0c..25b3a3bc90198b 100644 --- a/var/spack/repos/builtin/packages/rsl/package.py +++ b/var/spack/repos/builtin/packages/rsl/package.py @@ -17,6 +17,8 @@ class Rsl(AutotoolsPackage): version("1.50", sha256="9e4e3fe45eb1e4aebea63255d4956b00eb69527044a83f182cde1b43510bd342") + depends_on("c", type="build") # generated + depends_on("bzip2") depends_on("jpeg") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/rstart/package.py b/var/spack/repos/builtin/packages/rstart/package.py index 14442b8692ac1a..3c52dfcc837f3b 100644 --- a/var/spack/repos/builtin/packages/rstart/package.py +++ b/var/spack/repos/builtin/packages/rstart/package.py @@ -20,6 +20,8 @@ class Rstart(AutotoolsPackage, XorgPackage): version("1.0.6", sha256="28aa687437efeee70965a0878f9db79397cf691f4011268e16bc835627e23ec5") version("1.0.5", sha256="5271c0c2675b4ad09aace7edddfdd137af10fc754afa6260d8eb5d0bba7098c7") + depends_on("c", type="build") # generated + depends_on("xproto") depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") diff --git a/var/spack/repos/builtin/packages/rstudio/package.py b/var/spack/repos/builtin/packages/rstudio/package.py index e28b243e4d9c89..569e9909e2b6e3 100644 --- a/var/spack/repos/builtin/packages/rstudio/package.py +++ b/var/spack/repos/builtin/packages/rstudio/package.py @@ -16,6 +16,9 @@ class Rstudio(CMakePackage): version("1.4.1717", sha256="3af234180fd7cef451aef40faac2c7b52860f14a322244c1c7aede029814d261") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("notebook", default=False, description="Enable notebook support.") depends_on("r@3.0.1:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/rsync/package.py b/var/spack/repos/builtin/packages/rsync/package.py index aba593db40d723..e33eeed3686dbe 100644 --- a/var/spack/repos/builtin/packages/rsync/package.py +++ b/var/spack/repos/builtin/packages/rsync/package.py @@ -16,6 +16,7 @@ class Rsync(AutotoolsPackage): license("GPL-3.0-or-later") + version("3.3.0", sha256="7399e9a6708c32d678a72a63219e96f23be0be2336e50fd1348498d07041df90") version("3.2.7", sha256="4e7d9d3f6ed10878c58c5fb724a67dacf4b6aac7340b13e488fb2dc41346f2bb") version("3.2.6", sha256="fb3365bab27837d41feaf42e967c57bd3a47bc8f10765a3671efd6a3835454d3") version("3.2.5", sha256="2ac4d21635cdf791867bc377c35ca6dda7f50d919a58be45057fd51600c69aba") @@ -26,6 +27,9 @@ class Rsync(AutotoolsPackage): version("3.1.2", sha256="ecfa62a7fa3c4c18b9eccd8c16eaddee4bd308a76ea50b5c02a5840f09c0a1c2") version("3.1.1", sha256="7de4364fcf5fe42f3bdb514417f1c40d10bbca896abe7e7f2c581c6ea08a2621") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("popt") depends_on("openssl", when="@3.2:") diff --git a/var/spack/repos/builtin/packages/rsyslog/package.py b/var/spack/repos/builtin/packages/rsyslog/package.py index 9722a270bd87e0..6de8baf1116cd6 100644 --- a/var/spack/repos/builtin/packages/rsyslog/package.py +++ b/var/spack/repos/builtin/packages/rsyslog/package.py @@ -18,6 +18,8 @@ class Rsyslog(AutotoolsPackage): version("8.2004.0", sha256="b56b985fec076a22160471d389b7ff271909dfd86513dad31e401a775a6dfdc2") version("8.2002.0", sha256="b31d56311532335212ef2ea7be4501508224cb21f1bef9d262c6d78e21959ea1") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/rt-tests/package.py b/var/spack/repos/builtin/packages/rt-tests/package.py index f02be36b17a0d6..094370110dade0 100644 --- a/var/spack/repos/builtin/packages/rt-tests/package.py +++ b/var/spack/repos/builtin/packages/rt-tests/package.py @@ -20,6 +20,8 @@ class RtTests(MakefilePackage): version("1.2", sha256="7ccde036059c87681a4b00e7138678d9551b1232113441f6edda31ea45452426") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) mkdirp(prefix.share.man) diff --git a/var/spack/repos/builtin/packages/rtags/package.py b/var/spack/repos/builtin/packages/rtags/package.py index 16641b714ef11c..49e6424eed6fae 100644 --- a/var/spack/repos/builtin/packages/rtags/package.py +++ b/var/spack/repos/builtin/packages/rtags/package.py @@ -19,6 +19,9 @@ class Rtags(CMakePackage): version("2.20", sha256="9d73399421327147dc47b0ae5b95e12e8355f30291ad1954a78c0ef68b4b501f") version("2.17", sha256="288fa49fedf647fb15e2ef10f0ebcd9de1a4ef1bbae3a3940870e136d32a3a60") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("llvm@3.3: +clang") depends_on("zlib-api") depends_on("openssl") diff --git a/var/spack/repos/builtin/packages/rtmpdump/package.py b/var/spack/repos/builtin/packages/rtmpdump/package.py index e8a5bc843237d1..718b48f434f62a 100644 --- a/var/spack/repos/builtin/packages/rtmpdump/package.py +++ b/var/spack/repos/builtin/packages/rtmpdump/package.py @@ -18,6 +18,8 @@ class Rtmpdump(MakefilePackage): version("2021-02-19", commit="f1b83c10d8beb43fcc70a6e88cf4325499f25857") + depends_on("c", type="build") # generated + variant("tls", default="openssl", description="TLS backend", values=("gnutls", "openssl")) depends_on("openssl@:3", when="tls=openssl") diff --git a/var/spack/repos/builtin/packages/ruby-hpricot/package.py b/var/spack/repos/builtin/packages/ruby-hpricot/package.py index 1d30534f8e87bf..e75068b6be1fb2 100644 --- a/var/spack/repos/builtin/packages/ruby-hpricot/package.py +++ b/var/spack/repos/builtin/packages/ruby-hpricot/package.py @@ -19,3 +19,5 @@ class RubyHpricot(RubyPackage): license("MIT") version("0.8.6", sha256="792f63cebe2f2b02058974755b4c8a3aef52e5daf37f779a34885d5ff2876017") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/ruby-narray/package.py b/var/spack/repos/builtin/packages/ruby-narray/package.py index 5b976cd4e104ee..32c6759221b839 100644 --- a/var/spack/repos/builtin/packages/ruby-narray/package.py +++ b/var/spack/repos/builtin/packages/ruby-narray/package.py @@ -21,4 +21,6 @@ class RubyNarray(RubyPackage): version("master", branch="master") version("0.9.1.8", sha256="48814c6ebf2c4846fcf6cfd2705a15a97a608960c1676cb6c7b5c9254b0dd51b") + depends_on("c", type="build") # generated + depends_on("ruby@2.2:2", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/ruby-rake/package.py b/var/spack/repos/builtin/packages/ruby-rake/package.py index 768b2427917745..b40db761008e67 100644 --- a/var/spack/repos/builtin/packages/ruby-rake/package.py +++ b/var/spack/repos/builtin/packages/ruby-rake/package.py @@ -18,4 +18,6 @@ class RubyRake(RubyPackage): version("13.0.6", sha256="a39d555a08a3cbd6961a98d0bf222a01018683760664ede3c1610af5ca5de0cc") version("13.0.1", sha256="d865329b5e0c38bd9d11ce70bd1ad6e0d5676c4eee74fd818671c55ec49d92fd") + depends_on("c", type="build") # generated + depends_on("ruby@2.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/ruby-rdiscount/package.py b/var/spack/repos/builtin/packages/ruby-rdiscount/package.py index b85aa30bd27307..a8c13d4a5a78d0 100644 --- a/var/spack/repos/builtin/packages/ruby-rdiscount/package.py +++ b/var/spack/repos/builtin/packages/ruby-rdiscount/package.py @@ -17,4 +17,6 @@ class RubyRdiscount(RubyPackage): version("2.2.0.2", sha256="a6956059fc61365c242373b03c5012582d7342842eae38fe59ebc1bc169744db") + depends_on("c", type="build") # generated + depends_on("ruby@1.9.3:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/ruby/package.py b/var/spack/repos/builtin/packages/ruby/package.py index e71aa852d91889..298c7e2882f2aa 100644 --- a/var/spack/repos/builtin/packages/ruby/package.py +++ b/var/spack/repos/builtin/packages/ruby/package.py @@ -24,6 +24,8 @@ class Ruby(AutotoolsPackage, NMakePackage): license("Ruby AND BSD-2-Clause AND MIT", checked_by="tgamblin") + version("3.3.4", sha256="fe6a30f97d54e029768f2ddf4923699c416cdbc3a6e96db3e2d5716c7db96a34") + version("3.3.2", sha256="3be1d100ebf2a0ce60c2cd8d22cd9db4d64b3e04a1943be2c4ff7b520f2bcb5b") version("3.3.0", sha256="96518814d9832bece92a85415a819d4893b307db5921ae1f0f751a9a89a56b7d") version("3.1.0", sha256="50a0504c6edcb4d61ce6b8cfdbddaa95707195fab0ecd7b5e92654b2a9412854") version("3.0.2", sha256="5085dee0ad9f06996a8acec7ebea4a8735e6fac22f22e2d98c3f2bc3bef7e6f1") @@ -35,9 +37,12 @@ class Ruby(AutotoolsPackage, NMakePackage): version("2.5.3", sha256="9828d03852c37c20fa333a0264f2490f07338576734d910ee3fd538c9520846c") version("2.2.0", sha256="7671e394abfb5d262fbcd3b27a71bf78737c7e9347fa21c39e58b0bb9c4840fc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_system("autotools", "nmake", default="autotools") - for _platform_condition in ("platform=linux", "platform=darwin", "platform=cray"): + for _platform_condition in ("platform=linux", "platform=darwin"): with when(_platform_condition): variant("openssl", default=True, description="Enable OpenSSL support") variant("readline", default=False, description="Enable Readline support") diff --git a/var/spack/repos/builtin/packages/runc/package.py b/var/spack/repos/builtin/packages/runc/package.py index d1088eb20557c3..ae539d25299f64 100644 --- a/var/spack/repos/builtin/packages/runc/package.py +++ b/var/spack/repos/builtin/packages/runc/package.py @@ -19,6 +19,8 @@ class Runc(MakefilePackage): version("1.1.4", sha256="9f5972715dffb0b2371e4d678c1206cc8c4ec5eb80f2d48755d150bac49be35b") version("1.0.2", sha256="740acb49e33eaf4958b5109c85363c1d3900f242d4cab47fbdbefa6f8f3c6909") + depends_on("c", type="build") # generated + depends_on("go", type="build") depends_on("go-md2man", type="build") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/rust-bindgen/package.py b/var/spack/repos/builtin/packages/rust-bindgen/package.py index b05818412e1b40..7d20ad4e749ea6 100644 --- a/var/spack/repos/builtin/packages/rust-bindgen/package.py +++ b/var/spack/repos/builtin/packages/rust-bindgen/package.py @@ -18,6 +18,8 @@ class RustBindgen(Package): version("0.20.5", sha256="4f5236e7979d262c43267afba365612b1008b91b8f81d1efc6a8a2199d52bb37") + depends_on("cxx", type="build") # generated + extends("rust") depends_on("llvm") diff --git a/var/spack/repos/builtin/packages/rust-bootstrap/package.py b/var/spack/repos/builtin/packages/rust-bootstrap/package.py index ea73046f9ced74..6a83358fbf0fcb 100644 --- a/var/spack/repos/builtin/packages/rust-bootstrap/package.py +++ b/var/spack/repos/builtin/packages/rust-bootstrap/package.py @@ -16,11 +16,24 @@ class RustBootstrap(Package): maintainers("alecbcs") + skip_version_audit = ["platform=windows"] + # List binary rust releases for multiple operating systems and architectures. # These binary versions are not intended to stay up-to-date. Instead we # should update these binary releases as bootstrapping requirements are # modified by new releases of Rust. rust_releases = { + "1.78.0": { + "darwin": { + "x86_64": "6c91ed3bd90253961fcb4a2991b8b22e042e2aaa9aba9f389f1e17008171d898", + "aarch64": "3be74c31ee8dc4f1d49e2f2888228de374138eaeca1876d0c1b1a61df6023b3b", + }, + "linux": { + "x86_64": "1307747915e8bd925f4d5396ab2ae3d8d9c7fad564afbc358c081683d0f22e87", + "aarch64": "131eda738cd977fff2c912e5838e8e9b9c260ecddc1247c0fe5473bf09c594af", + "powerpc64le": "c5aedb12c552daa18072e386697205fb7b91cef1e8791fe6fb74834723851388", + }, + }, "1.75.0": { "darwin": { "x86_64": "ad066e4dec7ae5948c4e7afe68e250c336a5ab3d655570bb119b3eba9cf22851", @@ -110,6 +123,9 @@ class RustBootstrap(Package): version(release, sha256=rust_releases[release][os][target]) def url_for_version(self, version): + if self.os not in ("linux", "darwin"): + return None + # Allow maintainers to checksum multiple architectures via # `spack checksum rust-bootstrap@1.70.0-darwin-aarch64`. match = re.search(r"(\S+)-(\S+)-(\S+)", str(version)) diff --git a/var/spack/repos/builtin/packages/rust/package.py b/var/spack/repos/builtin/packages/rust/package.py index bbfbde58d084b3..230d64ca05a453 100644 --- a/var/spack/repos/builtin/packages/rust/package.py +++ b/var/spack/repos/builtin/packages/rust/package.py @@ -36,6 +36,7 @@ class Rust(Package): version("nightly") # Stable versions. + version("1.78.0", sha256="ff544823a5cb27f2738128577f1e7e00ee8f4c83f2a348781ae4fc355e91d5a9") version("1.76.0", sha256="9e5cff033a7f0d2266818982ad90e4d3e4ef8f8ee1715776c6e25073a136c021") version("1.75.0", sha256="5b739f45bc9d341e2d1c570d65d2375591e22c2d23ef5b8a37711a0386abc088") version("1.74.0", sha256="882b584bc321c5dcfe77cdaa69f277906b936255ef7808fcd5c7492925cf1049") @@ -44,6 +45,9 @@ class Rust(Package): version("1.65.0", sha256="5828bb67f677eabf8c384020582b0ce7af884e1c84389484f7f8d00dd82c0038") version("1.60.0", sha256="20ca826d1cf674daf8e22c4f8c4b9743af07973211c839b85839742314c838b7") + depends_on("c", type="build") + depends_on("cxx", type="build") + variant( "dev", default=False, @@ -53,13 +57,20 @@ class Rust(Package): variant("src", default=True, description="Include standard library source files.") # Core dependencies - depends_on("cmake@3.13.4:", type="build") depends_on("curl+nghttp2") depends_on("libgit2") + depends_on("libssh2") depends_on("ninja", type="build") depends_on("openssl") depends_on("pkgconfig", type="build") depends_on("python", type="build") + depends_on("zlib-api") + + # cmake dependency comes from LLVM. Rust has their own fork of LLVM, with tags corresponding + # to each Rust release, so it's easy to loop through tags and grep for "cmake_minimum_required" + depends_on("cmake@3.4.3:", type="build", when="@:1.51") + depends_on("cmake@3.13.4:", type="build", when="@1.52:1.72") + depends_on("cmake@3.20.0:", type="build", when="@1.73:") # Compiling Rust requires a previous version of Rust. # The easiest way to bootstrap a Rust environment is to @@ -72,12 +83,19 @@ class Rust(Package): depends_on("rust-bootstrap@nightly", type="build", when="@nightly") # Stable version dependencies + depends_on("rust-bootstrap", type="build") depends_on("rust-bootstrap@1.59:1.60", type="build", when="@1.60") depends_on("rust-bootstrap@1.64:1.65", type="build", when="@1.65") depends_on("rust-bootstrap@1.69:1.70", type="build", when="@1.70") depends_on("rust-bootstrap@1.72:1.73", type="build", when="@1.73") depends_on("rust-bootstrap@1.73:1.74", type="build", when="@1.74") depends_on("rust-bootstrap@1.74:1.75", type="build", when="@1.75") + depends_on("rust-bootstrap@1.77:1.78", type="build", when="@1.78") + + # src/llvm-project/llvm/cmake/modules/CheckCompilerVersion.cmake + conflicts("%gcc@:7.3", when="@1.73:", msg="Host GCC version must be at least 7.4") + # https://github.com/rust-lang/llvm-project/commit/4d039a7a71899038b3bc6ed6fe5a8a48d915caa0 + conflicts("%gcc@13:", when="@:1.63", msg="Rust<1.64 not compatible with GCC>=13") extendable = True executables = ["^rustc$", "^cargo$"] @@ -85,15 +103,27 @@ class Rust(Package): phases = ["configure", "build", "install"] @classmethod - def determine_version(csl, exe): - output = Executable(exe)("--version", output=str, error=str) + def determine_spec_details(cls, prefix, exes_in_prefix): + rustc_candidates = [x for x in exes_in_prefix if os.path.basename(x) == "rustc"] + cargo_candidates = [x for x in exes_in_prefix if os.path.basename(x) == "cargo"] + # Both rustc and cargo must be present + if not (rustc_candidates and cargo_candidates): + return + output = Executable(rustc_candidates[0])("--version", output=str, error=str) match = re.match(r"rustc (\S+)", output) - return match.group(1) if match else None + if match: + version_str = match.group(1) + return Spec.from_detection(f"rust@{version_str}") def setup_dependent_package(self, module, dependent_spec): module.cargo = Executable(os.path.join(self.spec.prefix.bin, "cargo")) def setup_build_environment(self, env): + # Manually instruct Cargo dependency libssh2-sys to build with + # the Spack installed libssh2 package. For more info see + # https://github.com/alexcrichton/ssh2-rs/issues/173 + env.set("LIBSSH2_SYS_USE_PKG_CONFIG", "1") + # Manually inject the path of ar for build. ar = which("ar", required=True) env.set("AR", ar.path) diff --git a/var/spack/repos/builtin/packages/sabre/package.py b/var/spack/repos/builtin/packages/sabre/package.py index 341e026645c556..61829b80ad3c5d 100644 --- a/var/spack/repos/builtin/packages/sabre/package.py +++ b/var/spack/repos/builtin/packages/sabre/package.py @@ -24,6 +24,8 @@ class Sabre(MakefilePackage): version("2013-09-27", commit="039a55e500ba07b7e6432ea6ec2ddcfb3471d949") + depends_on("c", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/saga-gis/package.py b/var/spack/repos/builtin/packages/saga-gis/package.py index ed313b19cc1237..2322be0f6386ba 100644 --- a/var/spack/repos/builtin/packages/saga-gis/package.py +++ b/var/spack/repos/builtin/packages/saga-gis/package.py @@ -39,6 +39,9 @@ class SagaGis(AutotoolsPackage, SourceforgePackage): version("2.3.1", branch="release-2-3-1", deprecated=True) version("2.3.0", branch="release-2-3-0", deprecated=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("gui", default=True, description="Build GUI and interactive SAGA tools") variant("odbc", default=True, description="Build with ODBC support") diff --git a/var/spack/repos/builtin/packages/sailfish/package.py b/var/spack/repos/builtin/packages/sailfish/package.py index c6e65a2c00b19e..e5af8d79d7a9aa 100644 --- a/var/spack/repos/builtin/packages/sailfish/package.py +++ b/var/spack/repos/builtin/packages/sailfish/package.py @@ -17,6 +17,9 @@ class Sailfish(CMakePackage): version("0.10.1", sha256="a0d6d944382f2e07ffbfd0371132588e2f22bb846ecfc3d3435ff3d81b30d6c6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost@1.55:") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/salmon-tddft/package.py b/var/spack/repos/builtin/packages/salmon-tddft/package.py index 55da0a2cd50151..38803fe5306c32 100644 --- a/var/spack/repos/builtin/packages/salmon-tddft/package.py +++ b/var/spack/repos/builtin/packages/salmon-tddft/package.py @@ -23,6 +23,9 @@ class SalmonTddft(CMakePackage): version("2.0.0", sha256="c3bb80bc5d338cba21cd8f345acbf2f2d81ef75af069a0a0ddbdc0acf358456c") version("1.2.1", sha256="a5045149e49abe9dd9edefe00cd1508a1323081bc3d034632176b728effdbaeb") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=False, description="Enable MPI") variant("libxc", default=False, description="Enable libxc") variant("scalapack", default=False, description="Enable scalapack") diff --git a/var/spack/repos/builtin/packages/salmon/package.py b/var/spack/repos/builtin/packages/salmon/package.py index 9b90af0ff01d0f..13d9b718657a30 100644 --- a/var/spack/repos/builtin/packages/salmon/package.py +++ b/var/spack/repos/builtin/packages/salmon/package.py @@ -23,6 +23,9 @@ class Salmon(CMakePackage): version("0.9.1", sha256="3a32c28d217f8f0af411c77c04144b1fa4e6fd3c2f676661cc875123e4f53520") version("0.8.2", sha256="299168e873e71e9b07d63a84ae0b0c41b0876d1ad1d434b326a5be2dce7c4b91") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "build_type", default="RELEASE", diff --git a/var/spack/repos/builtin/packages/salome-med/package.py b/var/spack/repos/builtin/packages/salome-med/package.py index 19c0eca618b8e3..08a7762cadbbb8 100644 --- a/var/spack/repos/builtin/packages/salome-med/package.py +++ b/var/spack/repos/builtin/packages/salome-med/package.py @@ -25,6 +25,10 @@ class SalomeMed(CMakePackage): version("3.3.1", sha256="856e9c4bb75eb0cceac3d5a5c65b1ce52fb3c46b9182920e1c9f34ae69bd2d5f") version("3.2.0", sha256="d52e9a1bdd10f31aa154c34a5799b48d4266dc6b4a5ee05a9ceda525f2c6c138") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=False, description="Enable MPI") variant("static", default=False, description="Enable static library build") variant("fortran", default=False, description="Enable Fortran") diff --git a/var/spack/repos/builtin/packages/salome-medcoupling/package.py b/var/spack/repos/builtin/packages/salome-medcoupling/package.py index 629141d67279dd..89f681b200a5c9 100644 --- a/var/spack/repos/builtin/packages/salome-medcoupling/package.py +++ b/var/spack/repos/builtin/packages/salome-medcoupling/package.py @@ -26,6 +26,9 @@ class SalomeMedcoupling(CMakePackage): version("9.4.0", tag="V9_4_0", commit="984fe46c4076f08f42ef43e290e3cd1aea5a8182") version("9.3.0", tag="V9_3_0", commit="32521cd6e5c113de5db7953a80149e5ab492120a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("static", default=False, description="Enable static library build") variant("mpi", default=False, description="Enable MPI") variant("in64", default=False, description="Enable 64 bits indexes") diff --git a/var/spack/repos/builtin/packages/sam2p/package.py b/var/spack/repos/builtin/packages/sam2p/package.py index 7b90b5b59da6ea..b87e5abec71f2d 100644 --- a/var/spack/repos/builtin/packages/sam2p/package.py +++ b/var/spack/repos/builtin/packages/sam2p/package.py @@ -20,6 +20,9 @@ class Sam2p(Package): version("master", branch="master") version("2021-05-04", commit="f3e9cc0a2df1880a63f9f37c96e3595bca890cfa") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): compile_sh = Executable("./compile.sh") compile_sh() diff --git a/var/spack/repos/builtin/packages/sambamba/package.py b/var/spack/repos/builtin/packages/sambamba/package.py index c8600dc279c419..c436775d139bbd 100644 --- a/var/spack/repos/builtin/packages/sambamba/package.py +++ b/var/spack/repos/builtin/packages/sambamba/package.py @@ -18,6 +18,8 @@ class Sambamba(Package): "0.6.6", tag="v0.6.6", commit="63cfd5c7b3053e1f7045dec0b5a569f32ef73d06", submodules=True ) + depends_on("c", type="build") # generated + depends_on("ldc~shared", type=("build", "link")) depends_on("python", type="build") diff --git a/var/spack/repos/builtin/packages/samblaster/package.py b/var/spack/repos/builtin/packages/samblaster/package.py index 9191ab9ae0800a..7814c4f4e4fd8f 100644 --- a/var/spack/repos/builtin/packages/samblaster/package.py +++ b/var/spack/repos/builtin/packages/samblaster/package.py @@ -15,9 +15,12 @@ class Samblaster(MakefilePackage): license("MIT") + version("0.1.26", sha256="6b42a53d64a3ed340852028546693a24c860f236fd70e90c2b24fde9dcc4fd63") version("0.1.24", sha256="72c42e0a346166ba00152417c82179bd5139636fea859babb06ca855af93d11f") version("0.1.23", sha256="0d35ce629771946e3d6fc199025747054e5512bffa1ba4446ed81160fffee57a") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("samblaster", prefix.bin) diff --git a/var/spack/repos/builtin/packages/samtools/package.py b/var/spack/repos/builtin/packages/samtools/package.py index c6b0018ecf1bec..6328bdf90a974c 100644 --- a/var/spack/repos/builtin/packages/samtools/package.py +++ b/var/spack/repos/builtin/packages/samtools/package.py @@ -44,6 +44,9 @@ class Samtools(Package): url="https://github.com/samtools/samtools/archive/0.1.8.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("ncurses") depends_on("perl", type="run") diff --git a/var/spack/repos/builtin/packages/sandbox/package.py b/var/spack/repos/builtin/packages/sandbox/package.py index 2bd88f2295158a..a24c819a38e46f 100644 --- a/var/spack/repos/builtin/packages/sandbox/package.py +++ b/var/spack/repos/builtin/packages/sandbox/package.py @@ -17,4 +17,6 @@ class Sandbox(AutotoolsPackage): version("2.25", sha256="24055986a1ed9b933da608e41e3284ee53c5a724f3c2457009f8e09e9c581ca8") version("2.12", sha256="265a490a8c528237c55ad26dfd7f62336fa5727c82358fc9cfbaa2e52c47fc50") + depends_on("c", type="build") # generated + depends_on("gawk", type="build") diff --git a/var/spack/repos/builtin/packages/sartre/package.py b/var/spack/repos/builtin/packages/sartre/package.py index e22e69092008be..d9a4e232162fa6 100644 --- a/var/spack/repos/builtin/packages/sartre/package.py +++ b/var/spack/repos/builtin/packages/sartre/package.py @@ -21,6 +21,10 @@ class Sartre(CMakePackage): version("1.39", sha256="82ed77243bea61bb9335f705c4b132f0b53d0de17c26b89389fa9cd3adcef44d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + parallel = False depends_on("gsl") diff --git a/var/spack/repos/builtin/packages/sarus/package.py b/var/spack/repos/builtin/packages/sarus/package.py index 8fe36fdef9d11a..eba4e9ca1e157b 100644 --- a/var/spack/repos/builtin/packages/sarus/package.py +++ b/var/spack/repos/builtin/packages/sarus/package.py @@ -31,6 +31,8 @@ class Sarus(CMakePackage): version("1.0.1", commit="abb8c314a196207204826f7b60e5064677687405") version("1.0.0", commit="d913b1d0ef3729f9f41ac5bd06dd5615c407ced4") + depends_on("cxx", type="build") # generated + variant( "ssh", default=False, diff --git a/var/spack/repos/builtin/packages/satsuma2/package.py b/var/spack/repos/builtin/packages/satsuma2/package.py index 3dfa800cf08ae2..996783d4a04825 100644 --- a/var/spack/repos/builtin/packages/satsuma2/package.py +++ b/var/spack/repos/builtin/packages/satsuma2/package.py @@ -19,6 +19,9 @@ class Satsuma2(CMakePackage): version("2021-03-04", commit="37c5f386819614cd3ce96016b423ddc4df1d86ec") version("2016-11-22", commit="da694aeecf352e344b790bea4a7aaa529f5b69e6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + maintainers("snehring") def patch(self): diff --git a/var/spack/repos/builtin/packages/saws/package.py b/var/spack/repos/builtin/packages/saws/package.py index 55514d4b02dd6f..365f5be2969d6a 100644 --- a/var/spack/repos/builtin/packages/saws/package.py +++ b/var/spack/repos/builtin/packages/saws/package.py @@ -19,4 +19,6 @@ class Saws(AutotoolsPackage): version("0.1.1", tag="v0.1.1", commit="c483e262b22bdf83ab026d20c35f0e09465d768d") version("0.1.0", tag="v0.1.0", commit="312ccc1698cf6c489c0d1eff6db46f54bd9031b7") + depends_on("c", type="build") # generated + depends_on("python", type="build") diff --git a/var/spack/repos/builtin/packages/sblim-sfcc/package.py b/var/spack/repos/builtin/packages/sblim-sfcc/package.py index f3e70b5fc8d46f..a3c7cfd052c4ac 100644 --- a/var/spack/repos/builtin/packages/sblim-sfcc/package.py +++ b/var/spack/repos/builtin/packages/sblim-sfcc/package.py @@ -18,6 +18,9 @@ class SblimSfcc(AutotoolsPackage): version("2_2_7", sha256="bb85bc75efd112411eb76e83a38413a33b3fb8b6b725c8d08fe326efcbea427f") version("2_2_6", sha256="65a8b70047c449f8b60e519ec1a47aa50b6476d3876a698e8484467650e9ee78") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/sbml/package.py b/var/spack/repos/builtin/packages/sbml/package.py index d30d2ee6b487b5..9a5c04a1ab9a07 100644 --- a/var/spack/repos/builtin/packages/sbml/package.py +++ b/var/spack/repos/builtin/packages/sbml/package.py @@ -25,6 +25,9 @@ class Sbml(CMakePackage): version("5.10.2", sha256="83f32a143cf657672b1050f5f79d3591c418fc59570d180fb1f39b103f4e5286") version("5.10.0", sha256="2cd8b37018ce8b1df869c8c182803addbce6d451512ae25a7f527b49981f0966") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): url = "https://downloads.sourceforge.net/project/sbml/libsbml/{0}/stable/libSBML-{1}-core-plus-packages-src.tar.gz".format( version, version diff --git a/var/spack/repos/builtin/packages/sbp/package.py b/var/spack/repos/builtin/packages/sbp/package.py index 22cc6128837b48..030d02a4f2649f 100644 --- a/var/spack/repos/builtin/packages/sbp/package.py +++ b/var/spack/repos/builtin/packages/sbp/package.py @@ -20,6 +20,9 @@ class Sbp(CMakePackage): "3.4.10", tag="v3.4.10", commit="d8ec454a3d7f1b2f8b8f515934612c184b8d5fa3", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + root_cmakelists_dir = "c" def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/sbt/package.py b/var/spack/repos/builtin/packages/sbt/package.py index 2f34e6da376e06..bbcd75469abf6e 100644 --- a/var/spack/repos/builtin/packages/sbt/package.py +++ b/var/spack/repos/builtin/packages/sbt/package.py @@ -14,6 +14,7 @@ class Sbt(Package): license("Apache-2.0") + version("1.10.0", sha256="154b7de6c19207c73d0a304f901c8c4b6ead9a9c3a99a98a9d72ac19419d2640") version("1.8.3", sha256="21f4210786fd68fd15dca3f4c8ee9cae0db249c54e1b0ef6e829e9fa4936423a") version("1.1.6", sha256="f545b530884e3abbca026df08df33d5a15892e6d98da5b8c2297413d1c7b68c1") version("1.1.5", sha256="8303d7496bc70eb441e8136bd29ffc295c629dadecefa4e7a475176ab4d282d5") diff --git a/var/spack/repos/builtin/packages/scafacos/package.py b/var/spack/repos/builtin/packages/scafacos/package.py index dcad460838fd41..387eb50dd40180 100644 --- a/var/spack/repos/builtin/packages/scafacos/package.py +++ b/var/spack/repos/builtin/packages/scafacos/package.py @@ -22,6 +22,10 @@ class Scafacos(AutotoolsPackage): version("1.0.1", sha256="2b125f313795c81b0e87eb920082e91addf94c17444f9486d979e691aaded99b") version("1.0.0", sha256="cc5762edbecfec0323126b6a6a535dcc3e134fcfef4b00f63eb05fae15244a96") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("fftw") depends_on("file") depends_on("gmp") diff --git a/var/spack/repos/builtin/packages/scalasca/package.py b/var/spack/repos/builtin/packages/scalasca/package.py index 35e34fef5dec63..4023b4f9030d07 100644 --- a/var/spack/repos/builtin/packages/scalasca/package.py +++ b/var/spack/repos/builtin/packages/scalasca/package.py @@ -28,6 +28,9 @@ class Scalasca(AutotoolsPackage): version("2.2.2", sha256="909567ca294366119bbcb7e8122b94f43982cbb328e18c6f6ce7a722d72cd6d4") version("2.1", sha256="fefe43f10becf7893863380546c80ac8db171a3b1ebf97d0258602667572c2fc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("mpi") # version 2.6.1+ diff --git a/var/spack/repos/builtin/packages/scale/package.py b/var/spack/repos/builtin/packages/scale/package.py index d8ef261220564d..8d9171756f6384 100644 --- a/var/spack/repos/builtin/packages/scale/package.py +++ b/var/spack/repos/builtin/packages/scale/package.py @@ -30,6 +30,9 @@ class Scale(MakefilePackage): version("5.3.6", sha256="3ab0d42cdb16eee568c65b880899e861e464e92088ceb525066c726f31d04848") version("5.2.6", sha256="e63141d05810e3f41fc89c9eb15e2319d753832adabdac8f7c8dd7acc0f5f8ed") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi@2:", type=("build", "link", "run")) depends_on("netcdf-c") depends_on("netcdf-fortran") diff --git a/var/spack/repos/builtin/packages/scallop/package.py b/var/spack/repos/builtin/packages/scallop/package.py index e3150343e95aaa..1d79822e7ce20e 100644 --- a/var/spack/repos/builtin/packages/scallop/package.py +++ b/var/spack/repos/builtin/packages/scallop/package.py @@ -16,6 +16,8 @@ class Scallop(AutotoolsPackage): version("0.10.5", sha256="b09e3c61f1b3b1da2a96d9d8429d80326a3bb14f5fe6af9b5e87570d4b86937a") version("0.10.3", sha256="04eb3ab27ed8c7ae38e1780d6b2af16b6a2c01807ffafd59e819d33bfeff58a0") + depends_on("cxx", type="build") # generated + depends_on("clp") depends_on("boost") depends_on("htslib@1.5:") diff --git a/var/spack/repos/builtin/packages/scalpel/package.py b/var/spack/repos/builtin/packages/scalpel/package.py index 85e1ff2ee61ab3..e639d275e6b2b6 100644 --- a/var/spack/repos/builtin/packages/scalpel/package.py +++ b/var/spack/repos/builtin/packages/scalpel/package.py @@ -20,6 +20,9 @@ class Scalpel(MakefilePackage, SourceforgePackage): version("0.5.4", sha256="506f731b3886def158c15fd8b74fa98390f304a507d2040972e6b09ddefac8f0") version("0.5.3", sha256="d45b569fe3aa5934883bc7216c243d53168351c23e020d96a46fa77a1563b65e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl@5.10.0:") # bamtools needs to build before the others. diff --git a/var/spack/repos/builtin/packages/scan-for-matches/package.py b/var/spack/repos/builtin/packages/scan-for-matches/package.py index 6df17616b8be0d..cdfdc7eb7c4c5a 100644 --- a/var/spack/repos/builtin/packages/scan-for-matches/package.py +++ b/var/spack/repos/builtin/packages/scan-for-matches/package.py @@ -15,6 +15,8 @@ class ScanForMatches(Package): version("2010-7-16", sha256="c6b17930efbdfbac28b57c3a0b4f8c26effb36c48988d82e41c81c6962e2d68f") + depends_on("c", type="build") # generated + def install(self, spec, prefix): cc = Executable(self.compiler.cc) cc("-O", "-o", "scan_for_matches", "ggpunit.c", "scan_for_matches.c") diff --git a/var/spack/repos/builtin/packages/scantailor/package.py b/var/spack/repos/builtin/packages/scantailor/package.py index 7618e5bfd0aea1..3256626dd4a02a 100644 --- a/var/spack/repos/builtin/packages/scantailor/package.py +++ b/var/spack/repos/builtin/packages/scantailor/package.py @@ -20,6 +20,8 @@ class Scantailor(CMakePackage): version("0.2.7", sha256="3e27647621d43638888a268902f8fa098b06a70a5da5d0623b1c11220a367910") + depends_on("cxx", type="build") # generated + depends_on("qt@5:") depends_on("libjpeg") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/scc/package.py b/var/spack/repos/builtin/packages/scc/package.py index c6d70053b38900..8c2c1aa3bcbcf7 100644 --- a/var/spack/repos/builtin/packages/scc/package.py +++ b/var/spack/repos/builtin/packages/scc/package.py @@ -19,4 +19,8 @@ class Scc(GoPackage): license("MIT") + version("3.3.2", sha256="2bbfed4cf34bbe50760217b479331cf256285335556a0597645b7250fb603388") version("3.1.0", sha256="bffea99c7f178bc48bfba3c64397d53a20a751dfc78221d347aabdce3422fd20") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/scine-core/package.py b/var/spack/repos/builtin/packages/scine-core/package.py index b006e324f873d8..049b3881530fac 100644 --- a/var/spack/repos/builtin/packages/scine-core/package.py +++ b/var/spack/repos/builtin/packages/scine-core/package.py @@ -18,8 +18,11 @@ class ScineCore(CMakePackage): license("BSD-3-Clause") version("master", branch="master") + version("6.0.0", sha256="6e47e49694002f9d847507c9aacfe53b2befbff5aa380f8860468afdfe880461") version("4.0.2", sha256="7181c6f93d71def22f1e0e5767afc7587c04b49abc03516f6926394868e7adc6") + depends_on("cxx", type="build") # generated + resource( name="dev", url="https://github.com/qcscine/development-utils/archive/refs/tags/5.0.1.tar.gz", diff --git a/var/spack/repos/builtin/packages/scine-database/package.py b/var/spack/repos/builtin/packages/scine-database/package.py index 7efd86781b0ac6..8bab8c53580f77 100644 --- a/var/spack/repos/builtin/packages/scine-database/package.py +++ b/var/spack/repos/builtin/packages/scine-database/package.py @@ -20,6 +20,8 @@ class ScineDatabase(CMakePackage): version("master", branch="master") version("1.1.0", sha256="a9144631dfb90e06f6924cf58fc5db13719cf8577fcd3bbf788a135060a70c18") + depends_on("cxx", type="build") # generated + resource( name="dev", url="https://github.com/qcscine/development-utils/archive/refs/tags/5.0.1.tar.gz", diff --git a/var/spack/repos/builtin/packages/scine-molassembler/package.py b/var/spack/repos/builtin/packages/scine-molassembler/package.py index 6c1bc8766376d4..da2c314cc72c24 100644 --- a/var/spack/repos/builtin/packages/scine-molassembler/package.py +++ b/var/spack/repos/builtin/packages/scine-molassembler/package.py @@ -20,6 +20,8 @@ class ScineMolassembler(CMakePackage): version("master", branch="master") version("1.2.1", sha256="c9fea41d383b7f54cf8a3ed4dabebe9e942fe3ef5b47895e3533e8ce42dacd38") + depends_on("cxx", type="build") # generated + resource( name="dev", url="https://github.com/qcscine/development-utils/archive/refs/tags/5.0.1.tar.gz", diff --git a/var/spack/repos/builtin/packages/scine-qcmaquis/cmake_molcas_interface.patch b/var/spack/repos/builtin/packages/scine-qcmaquis/cmake_molcas_interface.patch new file mode 100644 index 00000000000000..ce70786bdb734b --- /dev/null +++ b/var/spack/repos/builtin/packages/scine-qcmaquis/cmake_molcas_interface.patch @@ -0,0 +1,19 @@ +diff --git a/dmrg/lib/interfaces/openmolcas/CMakeLists.txt b/dmrg/lib/interfaces/openmolcas/CMakeLists.txt +index 46e569074..83fda1ca6 100644 +--- a/dmrg/lib/interfaces/openmolcas/CMakeLists.txt ++++ b/dmrg/lib/interfaces/openmolcas/CMakeLists.txt +@@ -24,7 +24,13 @@ add_library(qcmaquis-hdf5-interface ${HDF5_INTERFACE_SOURCES}) + + target_link_libraries(qcmaquis-hdf5-interface ${HDF5_LIBRARIES}) + +-set_target_properties(qcmaquis-driver PROPERTIES COMPILE_FLAGS "-cpp") ++if ("${CMAKE_Fortran_COMPILER_ID}" STREQUAL "GNU") ++ target_compile_options(qcmaquis-driver PRIVATE "-cpp") ++elseif ("${CMAKE_Fortran_COMPILER_ID}" STREQUAL "Intel") ++ target_compile_options(qcmaquis-driver PRIVATE "-fpp") ++elseif ("${CMAKE_Fortran_COMPILER_ID}" STREQUAL "Clang") ++ target_compile_options(qcmaquis-driver PRIVATE "-x f95") ++endif() + + if ("${CMAKE_Fortran_COMPILER_ID}" STREQUAL "GNU" + AND CMAKE_Fortran_COMPILER_VERSION VERSION_GREATER 10.0) diff --git a/var/spack/repos/builtin/packages/scine-qcmaquis/package.py b/var/spack/repos/builtin/packages/scine-qcmaquis/package.py index 8bf3c206761bd3..8406d00de71276 100644 --- a/var/spack/repos/builtin/packages/scine-qcmaquis/package.py +++ b/var/spack/repos/builtin/packages/scine-qcmaquis/package.py @@ -3,6 +3,8 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os + from spack.package import * @@ -15,14 +17,13 @@ class ScineQcmaquis(CMakePackage): maintainers("adam-grofe") version("master", branch="master") + version("3.1.4", branch="release-3.1.4") version("3.1.3", branch="release-3.1.3") - version("3.1.2", branch="release-3.1.2", preferred=True) - variant( - "blas", - values=("openblas", "mkl"), - default="openblas", - description="Which blas library to use.", - ) + version("3.1.2", branch="release-3.1.2") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant( "symmetries", default="SU2U1PG,TwoU1PG", @@ -30,9 +31,10 @@ class ScineQcmaquis(CMakePackage): values=("U1", "TwoU1", "TwoU1PG", "NU1", "Z2", "SU2U1", "SU2U1PG", "U1DG", "NONE"), multi=True, ) + variant("openmolcas", default=False, description="Build the OpenMOLCAS Fortran interface.") variant( "build_tests", - default=True, + default=False, description="Whether to build unit tests using gtest and gmock", ) @@ -40,17 +42,42 @@ class ScineQcmaquis(CMakePackage): depends_on("hdf5~mpi") depends_on("lapack") - depends_on("openblas+ilp64 threads=openmp", when="blas=openblas") - depends_on("intel-oneapi-mkl", when="blas=mkl") + + depends_on("blas") + for _pkg in ["openblas"] + list(INTEL_MATH_LIBRARIES): + with when(f"^[virtuals=blas] {_pkg}"): + depends_on(f"{_pkg}+ilp64 threads=openmp") + depends_on("gsl") - depends_on("boost+program_options+filesystem+system+thread+serialization+chrono") + depends_on("boost+program_options+filesystem+system+thread+serialization+chrono @1.56:") depends_on("googletest+gmock", when="+build_tests") + depends_on("globalarrays", when="+openmolcas") + + patch("cmake_molcas_interface.patch") + def cmake_args(self): args = [ self.define_from_variant("BUILD_SYMMETRIES", "symmetries"), + self.define_from_variant("BUILD_OPENMOLCAS_INTERFACE", "openmolcas"), self.define_from_variant("QCMAQUIS_TESTS", "build_tests"), + self.define("LAPACK_64_BIT", True), ] + if "+openmolcas" in self.spec: + globalarrays_libdir = self.spec["globalarrays"].prefix.lib + args.extend( + [ + self.define("BUILD_OPENMOLCAS_MPI", True), + self.define("GA_INCLUDE_DIR", self.spec["globalarrays"].prefix.include), + self.define( + "GA_LIBRARIES", + [ + os.path.join(globalarrays_libdir, "libga.so"), + os.path.join(globalarrays_libdir, "libarmci.so"), + ], + ), + ] + ) return args def patch(self): diff --git a/var/spack/repos/builtin/packages/scine-readuct/package.py b/var/spack/repos/builtin/packages/scine-readuct/package.py index f00bc645e48bd6..935baf2b6eb536 100644 --- a/var/spack/repos/builtin/packages/scine-readuct/package.py +++ b/var/spack/repos/builtin/packages/scine-readuct/package.py @@ -21,6 +21,8 @@ class ScineReaduct(CMakePackage): version("4.1.0", sha256="9cec0192a444403d6a8fd096509798c49fbd1eec298ec7194aba915e31f50782") + depends_on("cxx", type="build") # generated + resource( name="dev", url="https://github.com/qcscine/development-utils/archive/refs/tags/5.0.1.tar.gz", diff --git a/var/spack/repos/builtin/packages/scine-serenity/package.py b/var/spack/repos/builtin/packages/scine-serenity/package.py index 7dd6d8dd396fbe..ed666fc88cd304 100644 --- a/var/spack/repos/builtin/packages/scine-serenity/package.py +++ b/var/spack/repos/builtin/packages/scine-serenity/package.py @@ -20,6 +20,8 @@ class ScineSerenity(CMakePackage): version("master", branch="master") version("1.0.1", sha256="e2e5cc265a68ccab05f1bc934b957ca07c4f1c6004e662684023da451da69299") + depends_on("cxx", type="build") # generated + resource( name="dev", url="https://github.com/qcscine/development-utils/archive/refs/tags/5.0.1.tar.gz", diff --git a/var/spack/repos/builtin/packages/scine-sparrow/package.py b/var/spack/repos/builtin/packages/scine-sparrow/package.py index 44d1ccf84a8f44..50ef10fe6a305f 100644 --- a/var/spack/repos/builtin/packages/scine-sparrow/package.py +++ b/var/spack/repos/builtin/packages/scine-sparrow/package.py @@ -36,6 +36,8 @@ class ScineSparrow(CMakePackage): version("3.1.0", sha256="91412de0f2670a1735c4ca76406db5bea04236eeac0bc1f93ccfe18104aa7ce4") version("3.0.0", sha256="70636871694c9363ae3fb2df5050bddb22667b71d875d5a7e9afd872f6a2b65d") + depends_on("cxx", type="build") # generated + resource( name="dev", url="https://github.com/qcscine/development-utils/archive/refs/tags/5.0.1.tar.gz", diff --git a/var/spack/repos/builtin/packages/scine-utilities/package.py b/var/spack/repos/builtin/packages/scine-utilities/package.py index 3dcf0fb2a9e112..1784dedffd5a90 100644 --- a/var/spack/repos/builtin/packages/scine-utilities/package.py +++ b/var/spack/repos/builtin/packages/scine-utilities/package.py @@ -21,6 +21,8 @@ class ScineUtilities(CMakePackage): version("6.0.0", sha256="e4387d5562b7442a8e31e4dfc028bacfeb6d12e39f2d8aa6effc6db380863b4a") version("5.0.0", sha256="a304c89d9a196fe304f38610dea6b066d74590c0d434e4bd09a9796340700465") + depends_on("cxx", type="build") # generated + resource( name="dev", url="https://github.com/qcscine/development-utils/archive/refs/tags/5.0.1.tar.gz", diff --git a/var/spack/repos/builtin/packages/scine-xtb/package.py b/var/spack/repos/builtin/packages/scine-xtb/package.py index 9cd7dca1827763..676ddaa2331bdb 100644 --- a/var/spack/repos/builtin/packages/scine-xtb/package.py +++ b/var/spack/repos/builtin/packages/scine-xtb/package.py @@ -20,6 +20,8 @@ class ScineXtb(CMakePackage): version("master", branch="master") version("1.0.2", sha256="9beb1103467f3cfd9ad33beb2f3ec650bc3e6dc7094876774be3cc4e6f210487") + depends_on("cxx", type="build") # generated + resource( name="dev", url="https://github.com/qcscine/development-utils/archive/refs/tags/5.0.1.tar.gz", diff --git a/var/spack/repos/builtin/packages/scitokens-cpp/package.py b/var/spack/repos/builtin/packages/scitokens-cpp/package.py index c52e8500981f40..1426828700f0eb 100644 --- a/var/spack/repos/builtin/packages/scitokens-cpp/package.py +++ b/var/spack/repos/builtin/packages/scitokens-cpp/package.py @@ -17,6 +17,9 @@ class ScitokensCpp(CMakePackage): license("Apache-2.0") + version("1.1.1", sha256="a9091b888fc778282caf2a6808c86f685d2411557673152d58fe53932a6c7212") + version("1.1.0", sha256="9c4afd6638e94855ede52ecfc3d4f05082f2bdf151a9ab8dafcc2bb7cd4d9039") + version("1.0.2", sha256="cdc1e80e0cba9ca0e16de2efa10ec5e38765792bf5107024bfb66ddad5a16a85") version("1.0.1", sha256="d4660521fa17189e7a7858747d066052dd8ea8f430ce7649911c157d4423c412") version("1.0.0", sha256="88376c5cd065aac8d92445184a02ccf5186dc4890ccd7518e88be436978675c0") version("0.7.3", sha256="7d3c438596588cd74cf1af8255c55f44ca86a34293b81415ee24b33de64f886a") @@ -24,6 +27,8 @@ class ScitokensCpp(CMakePackage): version("0.7.1", sha256="44a1bca188897b1e97645149d1f6bc187cd0e482ad36159ca376834f028ce5ef") version("0.7.0", sha256="72600cf32523b115ec7abf4ac33fa369e0a655b3d3b390e1f68363e6c4e961b6") + depends_on("cxx", type="build") # generated + variant( "cxxstd", default="11", @@ -41,7 +46,9 @@ class ScitokensCpp(CMakePackage): depends_on("pkgconfig", type="build") depends_on("uuid", type="build") + # Some jwt-cpp releases introduce breaking API changes conflicts("^jwt-cpp@0.5:", when="@:0.7") + conflicts("^jwt-cpp@0.7:", when="@:1.1") # https://github.com/scitokens/scitokens-cpp/issues/72 @when("@0.7.0 ^openssl@3:") diff --git a/var/spack/repos/builtin/packages/scons/package.py b/var/spack/repos/builtin/packages/scons/package.py index 77cd015bea0962..1295ed6a90c70b 100644 --- a/var/spack/repos/builtin/packages/scons/package.py +++ b/var/spack/repos/builtin/packages/scons/package.py @@ -17,6 +17,7 @@ class Scons(PythonPackage): license("MIT") + version("4.7.0", sha256="d8b617f6610a73e46509de70dcf82f76861b79762ff602d546f4e80918ec81f3") version("4.5.2", sha256="813360b2bce476bc9cc12a0f3a22d46ce520796b352557202cb07d3e402f5458") version("4.5.1", sha256="9daeabe4d87ba2bd4ea15410765fc1ed2d931b723e4dc730a487a3911b9a1738") version("4.4.0", sha256="7703c4e9d2200b4854a31800c1dbd4587e1fa86e75f58795c740bcfa7eca7eaa") @@ -41,7 +42,7 @@ class Scons(PythonPackage): def url_for_version(self, version): url = "https://files.pythonhosted.org/packages/source/{0}/{1}/{1}-{2}.tar.gz" - if version >= Version("4.0.0"): + if self.spec.satisfies("@4.0.0:"): name = "SCons" else: name = "scons" diff --git a/var/spack/repos/builtin/packages/scorec-core/package.py b/var/spack/repos/builtin/packages/scorec-core/package.py index b5f4c35efb440d..9b2648aa1dc47d 100644 --- a/var/spack/repos/builtin/packages/scorec-core/package.py +++ b/var/spack/repos/builtin/packages/scorec-core/package.py @@ -18,6 +18,10 @@ class ScorecCore(CMakePackage): version("develop") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("zoltan") depends_on("cmake@3.0:", type="build") diff --git a/var/spack/repos/builtin/packages/scorep/package.py b/var/spack/repos/builtin/packages/scorep/package.py index fd0f6f842d1f96..02c8718a7270e6 100644 --- a/var/spack/repos/builtin/packages/scorep/package.py +++ b/var/spack/repos/builtin/packages/scorep/package.py @@ -69,6 +69,10 @@ class Scorep(AutotoolsPackage): deprecated="true", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + def url_for_version(self, version): if version < Version("7.0"): return "https://www.vi-hps.org/cms/upload/packages/scorep/scorep-{0}.tar.gz".format( @@ -153,6 +157,14 @@ def find_libpath(self, libname, root): return None return libs.directories[0] + # handle any mapping of Spack compiler names to Score-P args + # this should continue to exist for backward compatibility + def clean_compiler(self, compiler): + renames = {"cce": "cray"} + if compiler in renames: + return renames[compiler] + return compiler + def configure_args(self): spec = self.spec @@ -162,9 +174,9 @@ def configure_args(self): "--enable-shared", ] - cname = spec.compiler.name - if not spec.satisfies("platform=cray"): - config_args.append("--with-nocross-compiler-suite={0}".format(cname)) + cname = self.clean_compiler(spec.compiler.name) + + config_args.append("--with-nocross-compiler-suite={0}".format(cname)) if self.version >= Version("4.0"): config_args.append("--with-cubew=%s" % spec["cubew"].prefix.bin) @@ -189,8 +201,7 @@ def configure_args(self): config_args.append("--with-rocm=%s" % spec["hip"].prefix) config_args += self.with_or_without("shmem") - if not spec.satisfies("platform=cray"): - config_args += self.with_or_without("mpi") + config_args += self.with_or_without("mpi") if spec.satisfies("^intel-mpi"): config_args.append("--with-mpi=intel3") @@ -200,7 +211,7 @@ def configure_args(self): or spec.satisfies("^cray-mpich") ): config_args.append("--with-mpi=mpich3") - elif spec.satisfies("^openmpi"): + elif spec.satisfies("^openmpi") or spec.satisfies("^hpcx-mpi"): config_args.append("--with-mpi=openmpi") if spec.satisfies("^binutils"): diff --git a/var/spack/repos/builtin/packages/scorpio/package.py b/var/spack/repos/builtin/packages/scorpio/package.py index 360e54dc06dcc7..535e10d8aef1c2 100644 --- a/var/spack/repos/builtin/packages/scorpio/package.py +++ b/var/spack/repos/builtin/packages/scorpio/package.py @@ -24,6 +24,9 @@ class Scorpio(CMakePackage): version("2021-12-10", commit="b802f16877a6562ccdbeca8887910d3bd3e25cbb", preferred=True) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.16:", type="build") depends_on("mpi") depends_on("hdf5@1.10.6: +hl +mpi") diff --git a/var/spack/repos/builtin/packages/scotch/package.py b/var/spack/repos/builtin/packages/scotch/package.py index 124426d1a016a8..54f21c3b483490 100644 --- a/var/spack/repos/builtin/packages/scotch/package.py +++ b/var/spack/repos/builtin/packages/scotch/package.py @@ -37,9 +37,16 @@ class Scotch(CMakePackage, MakefilePackage): version("6.0.0", sha256="8206127d038bda868dda5c5a7f60ef8224f2e368298fbb01bf13fa250e378dd4") version("5.1.10b", sha256="54c9e7fafefd49d8b2017d179d4f11a655abe10365961583baaddc4eeb6a9add") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + build_system(conditional("cmake", when="@7:"), "makefile", default="cmake") variant("threads", default=True, description="use POSIX Pthreads within Scotch and PT-Scotch") - variant("mpi_thread", default=False, description="use multi-threaded algorithms") + variant( + "mpi_thread", + default=False, + description="use multi-threaded algorithms in conjunction with MPI", + ) variant("mpi", default=True, description="Compile parallel libraries") variant("compression", default=True, description="May use compressed files") variant("esmumps", default=False, description="Compile esmumps (needed by mumps)") @@ -48,6 +55,7 @@ class Scotch(CMakePackage, MakefilePackage): "metis", default=False, description="Expose vendored METIS/ParMETIS libraries and wrappers" ) variant("int64", default=False, description="Use int64_t for SCOTCH_Num typedef") + variant("noarch", default=False, description="Unset SPACK_TARGET_ARGS") variant( "link_error_lib", default=False, @@ -69,6 +77,9 @@ class Scotch(CMakePackage, MakefilePackage): patch("libscotchmetis-return-6.0.5a.patch", when="@6.0.5a") patch("libscotch-scotcherr-link-7.0.1.patch", when="@7.0.1 +link_error_lib") + # Avoid OpenMPI segfaults by using MPI_Comm_F2C for parmetis communicator + patch("parmetis-mpi.patch", when="@6.1.1:7.0.3 +metis ^openmpi") + # Vendored dependency of METIS/ParMETIS conflicts with standard # installations conflicts("metis", when="+metis") @@ -127,6 +138,10 @@ def cmake_args(self): return args + @when("+noarch") + def setup_build_environment(self, env): + env.unset("SPACK_TARGET_ARGS") + class MakefileBuilder(spack.build_systems.makefile.MakefileBuilder): build_directory = "src" diff --git a/var/spack/repos/builtin/packages/scotch/parmetis-mpi.patch b/var/spack/repos/builtin/packages/scotch/parmetis-mpi.patch new file mode 100644 index 00000000000000..23190ad584f640 --- /dev/null +++ b/var/spack/repos/builtin/packages/scotch/parmetis-mpi.patch @@ -0,0 +1,127 @@ +diff --git a/src/libscotchmetis/parmetis_dgraph_order_f.c b/src/libscotchmetis/parmetis_dgraph_order_f.c +index 44c2ede..549a834 100644 +--- a/src/libscotchmetis/parmetis_dgraph_order_f.c ++++ b/src/libscotchmetis/parmetis_dgraph_order_f.c +@@ -46,7 +46,7 @@ + /** # Version 6.0 : from : 13 sep 2012 **/ + /** to : 18 may 2019 **/ + /** # Version 7.0 : from : 21 jan 2023 **/ +-/** to : 21 jan 2023 **/ ++/** to : 30 jun 2023 **/ + /** **/ + /************************************************************/ + +@@ -76,11 +76,14 @@ const SCOTCH_Num * const numflag, \ + const SCOTCH_Num * const options, \ + SCOTCH_Num * const order, \ + SCOTCH_Num * const sizes, \ +-MPI_Comm * const commptr, \ ++const MPI_Fint * const commptr, \ + int * const revaptr), \ + (vtxdist, xadj, adjncy, numflag, options, order, sizes, commptr, revaptr)) + { +- *revaptr = SCOTCH_ParMETIS_V3_NodeND (vtxdist, xadj, adjncy, numflag, options, order, sizes, commptr); ++ MPI_Comm commdat; ++ ++ commdat = MPI_Comm_f2c (*commptr); ++ *revaptr = SCOTCH_ParMETIS_V3_NodeND (vtxdist, xadj, adjncy, numflag, options, order, sizes, &commdat); + } + + /*******************/ +@@ -101,10 +104,13 @@ const SCOTCH_Num * const numflag, \ + const SCOTCH_Num * const options, \ + SCOTCH_Num * const order, \ + SCOTCH_Num * const sizes, \ +-MPI_Comm * const commptr), \ ++const MPI_Fint * const commptr), \ + (vtxdist, xadj, adjncy, numflag, options, order, sizes, commptr)) + { +- METISNAMEU (ParMETIS_V3_NodeND) (vtxdist, xadj, adjncy, numflag, options, order, sizes, commptr); ++ MPI_Comm commdat; ++ ++ commdat = MPI_Comm_f2c (*commptr); ++ METISNAMEU (ParMETIS_V3_NodeND) (vtxdist, xadj, adjncy, numflag, options, order, sizes, &commdat); + } + + #endif /* SCOTCH_METIS_PREFIX */ +diff --git a/src/libscotchmetis/parmetis_dgraph_part_f.c b/src/libscotchmetis/parmetis_dgraph_part_f.c +index 2b76818..3bf66af 100644 +--- a/src/libscotchmetis/parmetis_dgraph_part_f.c ++++ b/src/libscotchmetis/parmetis_dgraph_part_f.c +@@ -44,7 +44,7 @@ + /** # Version 6.0 : from : 13 sep 2012 **/ + /** to : 18 may 2019 **/ + /** # Version 7.0 : from : 21 jan 2023 **/ +-/** to : 21 jan 2023 **/ ++/** to : 30 jun 2023 **/ + /** **/ + /************************************************************/ + +@@ -81,12 +81,15 @@ const float * const ubvec, \ + const SCOTCH_Num * const options, \ + SCOTCH_Num * const edgecut, \ + SCOTCH_Num * const part, \ +-MPI_Comm * const commptr, \ ++const MPI_Fint * const commptr, \ + int * const revaptr), \ + (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr, revaptr)) + { ++ MPI_Comm commdat; ++ ++ commdat = MPI_Comm_f2c (*commptr); + *revaptr = SCOTCH_ParMETIS_V3_PartKway (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, +- ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr); ++ ncon, nparts, tpwgts, ubvec, options, edgecut, part, &commdat); + } + + /* +@@ -111,12 +114,15 @@ const float * const ubvec, \ + const SCOTCH_Num * const options, \ + SCOTCH_Num * const edgecut, \ + SCOTCH_Num * const part, \ +-MPI_Comm * const commptr, \ ++const MPI_Fint * const commptr, \ + int * const revaptr), \ + (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr, revaptr)) + { ++ MPI_Comm commdat; ++ ++ commdat = MPI_Comm_f2c (*commptr); + *revaptr = SCOTCH_ParMETIS_V3_PartGeomKway (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, +- ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr); ++ ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, &commdat); + } + + /*******************/ +@@ -144,10 +150,13 @@ const float * const ubvec, \ + const SCOTCH_Num * const options, \ + SCOTCH_Num * const edgecut, \ + SCOTCH_Num * const part, \ +-MPI_Comm * const commptr), \ ++const MPI_Fint * const commptr), \ + (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr)) + { +- METISNAMEU (ParMETIS_V3_PartKway) (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr); ++ MPI_Comm commdat; ++ ++ commdat = MPI_Comm_f2c (*commptr); ++ METISNAMEU (ParMETIS_V3_PartKway) (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ncon, nparts, tpwgts, ubvec, options, edgecut, part, &commdat); + } + + /* +@@ -172,10 +181,13 @@ const float * const ubvec, + const SCOTCH_Num * const options, \ + SCOTCH_Num * const edgecut, \ + SCOTCH_Num * const part, \ +-MPI_Comm * const commptr), \ ++const MPI_Fint * const commptr), \ + (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr)) + { +- METISNAMEU (ParMETIS_V3_PartGeomKway) (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr); ++ MPI_Comm commdat; ++ ++ commdat = MPI_Comm_f2c (*commptr); ++ METISNAMEU (ParMETIS_V3_PartGeomKway) (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, &commdat); + } + + #endif /* SCOTCH_METIS_PREFIX */ diff --git a/var/spack/repos/builtin/packages/scr/package.py b/var/spack/repos/builtin/packages/scr/package.py index 7f377832dfc0c4..9737365255d905 100644 --- a/var/spack/repos/builtin/packages/scr/package.py +++ b/var/spack/repos/builtin/packages/scr/package.py @@ -65,6 +65,10 @@ class Scr(CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("zlib-api") @@ -302,9 +306,6 @@ def cmake_args(self): # PDSH required before this point args.append(self.define("WITH_PDSH_PREFIX", spec["pdsh"].prefix)) - if "platform=cray" in spec: - args.append(self.define("SCR_LINK_STATIC", False)) - return args @run_after("install") diff --git a/var/spack/repos/builtin/packages/screen/package.py b/var/spack/repos/builtin/packages/screen/package.py index d4c4dc5ecf3213..1d450d6dbbe6d3 100644 --- a/var/spack/repos/builtin/packages/screen/package.py +++ b/var/spack/repos/builtin/packages/screen/package.py @@ -37,6 +37,8 @@ class Screen(AutotoolsPackage, GNUMirrorPackage): version("3.7.2", sha256="6a882385d2810b8220b9e03c75c5fa184dcbd1afdb95974bbac396bb749a6cc0") version("3.7.1", sha256="0cd5b1a2cbba6bb2f2bc2145aec650abf02541fd3a2071117a99e4982f6e01da") + depends_on("c", type="build") # generated + depends_on("ncurses") depends_on("autoconf", type="build", when="@4.9.0:") depends_on("automake", type="build", when="@4.9.0:") diff --git a/var/spack/repos/builtin/packages/scripts/package.py b/var/spack/repos/builtin/packages/scripts/package.py index d7e3b34c3d2a2f..c34ecb5bd0d72f 100644 --- a/var/spack/repos/builtin/packages/scripts/package.py +++ b/var/spack/repos/builtin/packages/scripts/package.py @@ -14,6 +14,8 @@ class Scripts(AutotoolsPackage, XorgPackage): version("1.0.1", sha256="0ed6dabdbe821944d61830489ad5f21bd934550456b9157a1cd8a32f76e08279") + depends_on("cxx", type="build") # generated + depends_on("libx11") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/scrot/package.py b/var/spack/repos/builtin/packages/scrot/package.py index 0aeb0ba2a06123..23709f59a20144 100644 --- a/var/spack/repos/builtin/packages/scrot/package.py +++ b/var/spack/repos/builtin/packages/scrot/package.py @@ -20,6 +20,8 @@ class Scrot(AutotoolsPackage): version("1.6", sha256="42f64d38f04ec530c8b4ebdae04cce8b6893b2f8d30627391d390edcba917090") version("1.5", sha256="42fcf1c97940f4b4e34ca69990a0fc9b98991357bd6a4b67f30ebe0ccc10f093") + depends_on("c", type="build") # generated + depends_on("giblib", when="@:1.5") depends_on("imlib2") depends_on("libtool") diff --git a/var/spack/repos/builtin/packages/scs/package.py b/var/spack/repos/builtin/packages/scs/package.py index cdb33aa6fbcb34..585998738a2816 100644 --- a/var/spack/repos/builtin/packages/scs/package.py +++ b/var/spack/repos/builtin/packages/scs/package.py @@ -17,6 +17,8 @@ class Scs(MakefilePackage): version("2.1.1", sha256="0e20b91e8caf744b84aa985ba4e98cc7235ee33612b2bad2bf31ea5ad4e07d93") + depends_on("c", type="build") # generated + variant("cuda", default=False, description="Build with Cuda support") depends_on("blas") diff --git a/var/spack/repos/builtin/packages/sctk/package.py b/var/spack/repos/builtin/packages/sctk/package.py index b0c6ff307430d1..f3311e57214680 100644 --- a/var/spack/repos/builtin/packages/sctk/package.py +++ b/var/spack/repos/builtin/packages/sctk/package.py @@ -37,6 +37,9 @@ class Sctk(Package): url="https://www.openslr.org/resources/4/sctk-2.4.0-20091110-0958.tar.bz2", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): make("config") make("all") diff --git a/var/spack/repos/builtin/packages/sdl2-image/package.py b/var/spack/repos/builtin/packages/sdl2-image/package.py index 4e94341aec863a..87f2265999efe3 100644 --- a/var/spack/repos/builtin/packages/sdl2-image/package.py +++ b/var/spack/repos/builtin/packages/sdl2-image/package.py @@ -15,7 +15,10 @@ class Sdl2Image(AutotoolsPackage): license("Zlib") + version("2.8.2", sha256="8f486bbfbcf8464dd58c9e5d93394ab0255ce68b51c5a966a918244820a76ddc") version("2.6.3", sha256="931c9be5bf1d7c8fae9b7dc157828b7eee874e23c7f24b44ba7eff6b4836312c") version("2.0.1", sha256="3a3eafbceea5125c04be585373bfd8b3a18f259bd7eae3efc4e6d8e60e0d7f64") + depends_on("c", type="build") # generated + depends_on("sdl2") diff --git a/var/spack/repos/builtin/packages/sdl2-ttf/package.py b/var/spack/repos/builtin/packages/sdl2-ttf/package.py index 9bc5c7a69ba861..9ab51ccaf392f3 100644 --- a/var/spack/repos/builtin/packages/sdl2-ttf/package.py +++ b/var/spack/repos/builtin/packages/sdl2-ttf/package.py @@ -17,6 +17,9 @@ class Sdl2Ttf(CMakePackage): version("2.20.2", sha256="9dc71ed93487521b107a2c4a9ca6bf43fb62f6bddd5c26b055e6b91418a22053") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("sdl2") maintainers("georgemalerbo", "amklinv") diff --git a/var/spack/repos/builtin/packages/sdl2/package.py b/var/spack/repos/builtin/packages/sdl2/package.py index d8c598de9fa368..55ea3b0be6124e 100644 --- a/var/spack/repos/builtin/packages/sdl2/package.py +++ b/var/spack/repos/builtin/packages/sdl2/package.py @@ -20,15 +20,19 @@ class Sdl2(CMakePackage): license("Zlib") + version("2.30.3", sha256="820440072f8f5b50188c1dae104f2ad25984de268785be40c41a099a510f0aec") version("2.26.5", sha256="ad8fea3da1be64c83c45b1d363a6b4ba8fd60f5bde3b23ec73855709ec5eabf7") version("2.24.1", sha256="bc121588b1105065598ce38078026a414c28ea95e66ed2adab4c44d80b309e1b") version("2.0.22", sha256="fe7cbf3127882e3fc7259a75a0cb585620272c51745d3852ab9dd87960697f2e") version("2.0.14", sha256="d8215b571a581be1332d2106f8036fcb03d12a70bae01e20f424976d275432bc") version("2.0.5", sha256="442038cf55965969f2ff06d976031813de643af9c9edc9e331bd761c242e8785") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.5:", type="build") if sys.platform.startswith("linux"): depends_on("libxext", type="link") def cmake_args(self): - return ["-DSSEMATH={0}".format("OFF" if self.spec.target.family == "aarch64" else "ON")] + return [f"-DSSEMATH={'OFF' if self.spec.target.family == 'aarch64' else 'ON'}"] diff --git a/var/spack/repos/builtin/packages/sdsl-lite/package.py b/var/spack/repos/builtin/packages/sdsl-lite/package.py index 928f3ca12c8500..b8f44c8dc73611 100644 --- a/var/spack/repos/builtin/packages/sdsl-lite/package.py +++ b/var/spack/repos/builtin/packages/sdsl-lite/package.py @@ -20,6 +20,9 @@ class SdslLite(Package): expand=False, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake", type="build") depends_on("tar", type="build") diff --git a/var/spack/repos/builtin/packages/seacas/package.py b/var/spack/repos/builtin/packages/seacas/package.py index 30aab746a31a8a..986068e16a7090 100644 --- a/var/spack/repos/builtin/packages/seacas/package.py +++ b/var/spack/repos/builtin/packages/seacas/package.py @@ -31,10 +31,19 @@ class Seacas(CMakePackage): url = "https://github.com/sandialabs/seacas/archive/v2019-08-20.tar.gz" maintainers("gsjaardema") - license("Intel") + license("BSD-3-Clause") # ###################### Versions ########################## version("master", branch="master") + version( + "2024-07-10", sha256="b2ba6ca80359fed8ed2a8a210052582c7a3b7b837253bd1e9be941047dcab3ff" + ) + version( + "2024-06-27", sha256="a28db6aa3d03ff0a54a091210cf867661427f0b22ac08f89a4cc3bd8e0c704b2" + ) + version( + "2024-04-03", sha256="edf1aacbde87212b10737d3037107dba5cf7e2cce167863e2ebb200dc1a3fbb5" + ) version( "2024-03-11", sha256="b849d958b34e77300aaf331f29c3e6fe417fd82600850a82e674a9b7ba4045ff" ) @@ -65,48 +74,80 @@ class Seacas(CMakePackage): "2022-01-27", sha256="beff12583814dcaf75cf8f1a78bb183c1dcc8937bc18d5206672e3a692db05e0" ) version( - "2021-10-11", sha256="f8a6dac813c0937fed4a5377123aa61d47eb459ba87ddf368d02ebe10c2c3a0d" + "2021-10-11", + sha256="f8a6dac813c0937fed4a5377123aa61d47eb459ba87ddf368d02ebe10c2c3a0d", + deprecated=True, ) version( - "2021-09-30", sha256="5d061e35e93eb81214da3b67ddda2829cf5efed38a566be6363a9866ba2f9ab3" + "2021-09-30", + sha256="5d061e35e93eb81214da3b67ddda2829cf5efed38a566be6363a9866ba2f9ab3", + deprecated=True, ) version( - "2021-05-12", sha256="92663767f0317018d6f6e422e8c687e49f6f7eb2b92e49e837eb7dc0ca0ac33d" + "2021-05-12", + sha256="92663767f0317018d6f6e422e8c687e49f6f7eb2b92e49e837eb7dc0ca0ac33d", + deprecated=True, ) version( - "2021-04-05", sha256="76f66eec1fec7aba30092c94c7609495e6b90d9dcb6f35b3ee188304d02c6e04" + "2021-04-05", + sha256="76f66eec1fec7aba30092c94c7609495e6b90d9dcb6f35b3ee188304d02c6e04", + deprecated=True, ) version( - "2021-01-20", sha256="7814e81981d03009b6816be3eb4ed3845fd02cc69e006ee008a2cbc85d508246" + "2021-01-20", + sha256="7814e81981d03009b6816be3eb4ed3845fd02cc69e006ee008a2cbc85d508246", + deprecated=True, ) version( - "2021-01-06", sha256="b233502a7dc3e5ab69466054cf358eb033e593b8679c6721bf630b03999bd7e5" + "2021-01-06", + sha256="b233502a7dc3e5ab69466054cf358eb033e593b8679c6721bf630b03999bd7e5", + deprecated=True, ) version( - "2020-08-13", sha256="e5eaf203eb2dbfb33c61ccde26deea459d058aaea79b0847e2f4bdb0cef1ddcb" + "2020-08-13", + sha256="e5eaf203eb2dbfb33c61ccde26deea459d058aaea79b0847e2f4bdb0cef1ddcb", + deprecated=True, ) version( - "2020-05-12", sha256="7fc6915f60568b36e052ba07a77d691c99abe42eaba6ae8a6dc74bb33490ed60" + "2020-05-12", + sha256="7fc6915f60568b36e052ba07a77d691c99abe42eaba6ae8a6dc74bb33490ed60", + deprecated=True, ) version( - "2020-03-16", sha256="2eb404f3dcb17c3e7eacf66978372830d40ef3722788207741fcd48417807af6" + "2020-03-16", + sha256="2eb404f3dcb17c3e7eacf66978372830d40ef3722788207741fcd48417807af6", + deprecated=True, ) version( - "2020-01-16", sha256="5ae84f61e410a4f3f19153737e0ac0493b144f20feb1bbfe2024f76613d8bff5" + "2020-01-16", + sha256="5ae84f61e410a4f3f19153737e0ac0493b144f20feb1bbfe2024f76613d8bff5", + deprecated=True, ) version( - "2019-12-18", sha256="f82cfa276ebc5fe6054852383da16eba7a51c81e6640c73b5f01fc3109487c6f" + "2019-12-18", + sha256="f82cfa276ebc5fe6054852383da16eba7a51c81e6640c73b5f01fc3109487c6f", + deprecated=True, ) version( - "2019-10-14", sha256="ca4cf585cdbc15c25f302140fe1f61ee1a30d72921e032b9a854492b6c61fb91" + "2019-10-14", + sha256="ca4cf585cdbc15c25f302140fe1f61ee1a30d72921e032b9a854492b6c61fb91", + deprecated=True, ) version( - "2019-08-20", sha256="a82c1910c2b37427616dc3716ca0b3c1c77410db6723aefb5bea9f47429666e5" + "2019-08-20", + sha256="a82c1910c2b37427616dc3716ca0b3c1c77410db6723aefb5bea9f47429666e5", + deprecated=True, ) version( - "2019-07-26", sha256="651dac832b0cfee0f63527f563415c8a65b8e4d79242735c1e2aec606f6b2e17" + "2019-07-26", + sha256="651dac832b0cfee0f63527f563415c8a65b8e4d79242735c1e2aec606f6b2e17", + deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # ###################### Variants ########################## # Package options # The I/O libraries (exodus, IOSS) are always built @@ -130,25 +171,58 @@ class Seacas(CMakePackage): ) # Build options - variant("fortran", default=not is_windows, description="Compile with Fortran support") + variant("fortran", default=not is_windows, description="Compile with Fortran support.") # Enable this on Windows at your own risk, SEACAS exports no symbols and so cannot be # meaningfully linked against as a shared library - variant("shared", default=True, description="Enables the build of shared libraries") + variant("shared", default=True, description="Enables the build of shared libraries.") variant("mpi", default=True, description="Enables MPI parallelism.") - variant("tests", default=True, description="Enable the SEACAS tests to build") + variant("tests", default=True, description="Enable building the SEACAS tests.") variant( - "thread_safe", default=False, description="Enable thread-safe exodus and IOSS libraries" + "thread_safe", default=False, description="Enable thread-safe exodus and IOSS libraries." ) # TPLs (alphabet order) - variant("adios2", default=False, description="Enable ADIOS2") - variant("cgns", default=True, description="Enable CGNS") - variant("faodel", default=False, description="Enable Faodel") - variant("matio", default=True, description="Compile with matio (MatLab) support") - variant("metis", default=False, description="Compile with METIS and ParMETIS") - variant("pamgen", default=False, description="Compile with pamgen") - variant("x11", default=True, description="Compile with X11") - variant("zlib", default=False, description="Compile with zlib") + variant( + "adios2", + default=False, + description="Enable ADIOS2. See https://github.com/ornladios/ADIOS2", + ) + variant("cgns", default=True, description="Enable CGNS.") + variant( + "faodel", + default=False, + description="Enable Faodel. See https://github.com/sandialabs/faodel", + ) + variant( + "matio", + default=True, + description="Compile with matio (MatLab) support." + " Enables exo2mat and mat2exo translators.", + ) + variant( + "metis", + default=False, + description="Compile with METIS and ParMETIS. " + "Provides additional parallel decomposition options.", + ) + variant( + "pamgen", + default=False, + description="Compile with pamgen. " + "Provides another ioss database option for internal generation of mesh models.", + ) + variant( + "x11", + default=True, + description="Compile with X11. " + "Needed if building blot (visualizer) and fastq (2D mesh generation).", + ) + variant( + "zlib", + default=False, + description="Compile with zlib. " + "Sometimes needed when building static libraries on some systems.", + ) # ###################### Dependencies ########################## depends_on("cmake@3.22:", when="@2023-10-24:", type="build") depends_on("cmake@3.17:", when="@:2023-05-30", type="build") @@ -167,6 +241,19 @@ class Seacas(CMakePackage): depends_on("fmt@9.1.0", when="@2022-10-14:2023-05-30") depends_on("fmt@8.1.0:9", when="@2022-03-04:2022-05-16") + # if fmt@9.1.0%gcc is mixed with an %apple-clang seacas build + # it triggers a bug in apple-clang w.r.t how symbols are mangled + # https://github.com/spack/spack/issues/44330 + conflicts( + "^fmt@9%gcc", + msg="""Cannot mix gcc/apple-clang toolchains + for this library combination. + See https://github.com/spack/spack/issues/44330""", + when="%apple-clang", + ) + + depends_on("catch2@3:", when="@2024-03-11:+tests") + depends_on("matio", when="+matio") depends_on("libx11", when="+x11") @@ -238,7 +325,7 @@ def cmake_args(self): define(project_name_base + "_ENABLE_SEACAS", True), ] ) - if "~shared" in self.spec: + if "~shared" in self.spec and not is_windows: options.append(self.define(f"{project_name_base}_EXTRA_LINK_FLAGS", "z;dl")) options.append(from_variant("TPL_ENABLE_MPI", "mpi")) if "+mpi" in spec and not is_windows: diff --git a/var/spack/repos/builtin/packages/seacr/package.py b/var/spack/repos/builtin/packages/seacr/package.py new file mode 100644 index 00000000000000..fafe5e6c9d4eaa --- /dev/null +++ b/var/spack/repos/builtin/packages/seacr/package.py @@ -0,0 +1,33 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + + +class Seacr(Package): + """SEACR (Sparse Enrichment Analysis for CUT&RUN) is intended to call peaks and + enriched regions from sparse CUT&RUN or chromatin profiling data in which the + background is dominated by zeros""" + + homepage = "https://github.com/FredHutch/SEACR" + git = "https://github.com/FredHutch/SEACR.git" + + license("GPL-2.0-only", checked_by="A-N-Other") + + version("1.4-b2", tag="v1.4-beta.2", commit="5179a70494eb129fcb1d640177de73f6509654e7") + version("1.3", tag="v1.3", commit="5a0efe59f06fb17cf9d34d415bb0c1a1f7a77a3c", preferred=True) + + # Dependencies as per the README.md + depends_on("r", type="run") + depends_on("bedtools2", type="run") + + def install(self, spec, prefix): + mkdirp(prefix.bin) + script_name = f"SEACR_{self.version.up_to(2)}" + os.chmod(f"{script_name}.sh", 0o755) + install(f"{script_name}.sh", prefix.bin.SEACR) + install(f"{script_name}.R", prefix.bin) diff --git a/var/spack/repos/builtin/packages/seal/package.py b/var/spack/repos/builtin/packages/seal/package.py index a101a276234152..59f8c991944700 100644 --- a/var/spack/repos/builtin/packages/seal/package.py +++ b/var/spack/repos/builtin/packages/seal/package.py @@ -31,3 +31,6 @@ class Seal(CMakePackage): version("3.6.1", sha256="e399c0df7fb60ad450a0ccfdc81b99d19308d0fc1f730d4cad4748dfb2fdb516") version("3.6.0", sha256="79c0e45bf301f4577a7633b14e8b26e37eefc89fd4f6a29d13f87e5f22a372ad") version("3.5.9", sha256="23bf3bf7ae1dae5dae271244a5baa66fa01856c52e263fe8368c3a40f2399fc7") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/sed/package.py b/var/spack/repos/builtin/packages/sed/package.py index ee9e868a7065d8..0c556310799ebf 100644 --- a/var/spack/repos/builtin/packages/sed/package.py +++ b/var/spack/repos/builtin/packages/sed/package.py @@ -20,6 +20,8 @@ class Sed(AutotoolsPackage, GNUMirrorPackage): version("4.8", sha256="f79b0cfea71b37a8eeec8490db6c5f7ae7719c35587f21edb0617f370eeff633") version("4.2.2", sha256="f048d1838da284c8bc9753e4506b85a1e0cc1ea8999d36f6995bcb9460cddbd7") + depends_on("c", type="build") # generated + # Avoid symlinking GNUMakefile to GNUMakefile build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/selalib/package.py b/var/spack/repos/builtin/packages/selalib/package.py index 0486604567f5aa..ade72efed12c5e 100644 --- a/var/spack/repos/builtin/packages/selalib/package.py +++ b/var/spack/repos/builtin/packages/selalib/package.py @@ -18,6 +18,10 @@ class Selalib(CMakePackage): version("main", branch="main") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fmempool", default=False, description="Use memory pool") variant("mpi", default=True, description="Build with MPI support") variant("openmp", default=True, description="Build with OpenMP support") diff --git a/var/spack/repos/builtin/packages/semiprof/package.py b/var/spack/repos/builtin/packages/semiprof/package.py index d26b4248c798af..2a0475715493ab 100644 --- a/var/spack/repos/builtin/packages/semiprof/package.py +++ b/var/spack/repos/builtin/packages/semiprof/package.py @@ -21,6 +21,8 @@ class Semiprof(CMakePackage): version("0.1", sha256="4fb3823c65a4f5dfbe05e8cbe1911dfd25cd7740597f82c7b3a84472de26f0dc") + depends_on("cxx", type="build") # generated + def cmake_args(self): return [ self.define("SEMIPROF_WITH_INSTALL", True), diff --git a/var/spack/repos/builtin/packages/sensei/package.py b/var/spack/repos/builtin/packages/sensei/package.py index 96e4dd4393c6ed..95374e63b5f27f 100644 --- a/var/spack/repos/builtin/packages/sensei/package.py +++ b/var/spack/repos/builtin/packages/sensei/package.py @@ -35,6 +35,9 @@ class Sensei(CMakePackage): version("1.1.0", sha256="769e0b5db50be25666c0d13176a7e4f89cbffe19cdc12349437d0efff615b200") version("1.0.0", sha256="5b8609352048e048e065a7b99f615a602f84b3329085e40274341488ef1b9522") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Enables shared libraries") variant("ascent", default=False, description="Build with ParaView-Catalyst support") variant("catalyst", default=False, description="Build with ParaView-Catalyst support") diff --git a/var/spack/repos/builtin/packages/sentencepiece/package.py b/var/spack/repos/builtin/packages/sentencepiece/package.py index 845dea6add8b72..a954519ece3ce1 100644 --- a/var/spack/repos/builtin/packages/sentencepiece/package.py +++ b/var/spack/repos/builtin/packages/sentencepiece/package.py @@ -22,5 +22,7 @@ class Sentencepiece(CMakePackage): version("0.1.91", sha256="acbc7ea12713cd2a8d64892f8d2033c7fd2bb4faecab39452496120ace9a4b1b") version("0.1.85", sha256="dd4956287a1b6af3cbdbbd499b7227a859a4e3f41c9882de5e6bdd929e219ae6") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build") depends_on("gperftools") # optional, 10-40% performance improvement diff --git a/var/spack/repos/builtin/packages/seq-gen/package.py b/var/spack/repos/builtin/packages/seq-gen/package.py index 2aa4cca47e5095..c67831285d2022 100644 --- a/var/spack/repos/builtin/packages/seq-gen/package.py +++ b/var/spack/repos/builtin/packages/seq-gen/package.py @@ -26,6 +26,8 @@ class SeqGen(MakefilePackage): version("1.3.4", sha256="092ec2255ce656a02b2c3012c32443c7d8e38c692f165fb155b304ca030cbb59") + depends_on("c", type="build") # generated + build_directory = "source" def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/seqan/package.py b/var/spack/repos/builtin/packages/seqan/package.py index 5650cc43a0add8..0fc2a493ab1fa3 100644 --- a/var/spack/repos/builtin/packages/seqan/package.py +++ b/var/spack/repos/builtin/packages/seqan/package.py @@ -20,6 +20,8 @@ class Seqan(CMakePackage): version("2.4.0", sha256="d7084d17729214003e84818e0280a16f223c8f1c6a30eeef040c27e0c0047bd7") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.4.0:", type="build") depends_on("python@2.7.0:", type="build") depends_on("py-nose", type="build") diff --git a/var/spack/repos/builtin/packages/seqfu/package.py b/var/spack/repos/builtin/packages/seqfu/package.py new file mode 100644 index 00000000000000..53de9fd0a2528f --- /dev/null +++ b/var/spack/repos/builtin/packages/seqfu/package.py @@ -0,0 +1,35 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Seqfu(Package): + """seqfu - Sequece Fastx Utilities""" + + homepage = "https://github.com/telatin/seqfu2" + url = "https://github.com/telatin/seqfu2/archive/refs/tags/v1.20.3.tar.gz" + + license("GPL-3.0", checked_by="dialvarezs") + + version("1.20.3", sha256="1b287b99f3f1ac7045f4d551e781d6780ce168ba8e0a7bfaa0f5490f32e15938") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + depends_on("nim@2", type="build") + depends_on("zlib", type="build") + + patch("wno_incompatible_pointer_types.patch", when="%gcc@14:") + + def setup_build_environment(self, env): + env.set("NIMBLE_DIR", ".nimble") + + def install(self, spec, prefix): + nimble = Executable("nimble") + nimble("install", "-y", "--depsOnly") + + make(parallel=False) + install_tree("bin", join_path(prefix, "bin")) diff --git a/var/spack/repos/builtin/packages/seqfu/wno_incompatible_pointer_types.patch b/var/spack/repos/builtin/packages/seqfu/wno_incompatible_pointer_types.patch new file mode 100644 index 00000000000000..b8c2e93d7b15e2 --- /dev/null +++ b/var/spack/repos/builtin/packages/seqfu/wno_incompatible_pointer_types.patch @@ -0,0 +1,13 @@ +diff --git a/Makefile b/Makefile +index 287bb7c..7fb9434 100644 +--- a/Makefile ++++ b/Makefile +@@ -7,7 +7,7 @@ SCRIPTS=./scripts + SOURCE=./src + DATA=./data + VERSION := $(shell grep version seqfu.nimble | grep -o "[0-9]\\+\.[0-9]\\+\.[0-9]\\+") +-NIMPARAM := --gc:orc -d:NimblePkgVersion=$(VERSION) -d:release --opt:speed ++NIMPARAM := --gc:orc -d:NimblePkgVersion=$(VERSION) -d:release --opt:speed --passC:"-Wno-error=incompatible-pointer-types" + TARGETS=$(BIN)/seqfu $(BIN)/fu-msa $(BIN)/fu-primers $(BIN)/dadaist2-mergeseqs $(BIN)/fu-shred $(BIN)/fu-homocomp $(BIN)/fu-multirelabel $(BIN)/fu-index $(BIN)/fu-cov $(BIN)/fu-16Sregion $(BIN)/fu-nanotags $(BIN)/fu-orf $(BIN)/fu-sw $(BIN)/fu-virfilter $(BIN)/fu-tabcheck $(BIN)/byteshift $(BIN)/SeqCountHelper $(BIN)/fu-secheck + PYTARGETS=$(BIN)/fu-split $(BIN)/fu-pecheck $(BIN)/fu-readtope + diff --git a/var/spack/repos/builtin/packages/seqkit/package.py b/var/spack/repos/builtin/packages/seqkit/package.py index 05a2d6ed00381e..639f7cbbaf2841 100644 --- a/var/spack/repos/builtin/packages/seqkit/package.py +++ b/var/spack/repos/builtin/packages/seqkit/package.py @@ -6,17 +6,24 @@ from spack.package import * -class Seqkit(Package): - """A cross-platform and ultrafast toolkit for FASTA/Q file manipulation - in Golang.""" +class GoBuilder(spack.build_systems.go.GoBuilder): + @property + def build_directory(self): + return join_path(self.pkg.stage.source_path, "seqkit") - homepage = "https://bioinf.shenwei.me/seqkit" - url = ( - "https://github.com/shenwei356/seqkit/releases/download/v0.10.1/seqkit_linux_amd64.tar.gz" - ) - version("0.10.1", sha256="82f1c86dc4bd196403a56c2bf3ec063e5674a71777e68d940c4cc3d8411d2e9d") +class Seqkit(GoPackage): + """seqkit: a cross-platform and ultrafast toolkit for FASTA/Q file manipulation""" - def install(self, spec, prefix): - mkdir(prefix.bin) - install("seqkit", prefix.bin) + homepage = "https://bioinf.shenwei.me/seqkit/" + url = "https://github.com/shenwei356/seqkit/archive/refs/tags/v2.4.0.tar.gz" + + license("MIT", checked_by="A-N-Other") + + version("2.8.2", sha256="9cf1e744b785fa673af5a7a1ce2f96d52dc03e14b6537097df86aa6266204556") + version("2.7.0", sha256="b5c723ffd4640659860fc70a71c218d8f53bea0eae571cecc98eff04c7291e02") + version("2.6.1", sha256="d88249bd3b630c908ebd308abaa9cd7acb7a781c12bab877d3daaab56f43c443") + version("2.5.1", sha256="76d105921f918be20e616fbb607fe0fb2db603535a254ec0f853cb36bef817da") + version("2.4.0", sha256="c319f3d5feb7c99309e654042432959f01bbc5f7e4c71f55dc9854df46c73c7f") + + depends_on("go@1.17:", type="build") diff --git a/var/spack/repos/builtin/packages/seqprep/package.py b/var/spack/repos/builtin/packages/seqprep/package.py index ab756237428426..4140b78554031c 100644 --- a/var/spack/repos/builtin/packages/seqprep/package.py +++ b/var/spack/repos/builtin/packages/seqprep/package.py @@ -17,6 +17,8 @@ class Seqprep(MakefilePackage): version("1.3.2", sha256="2b8a462a0e0a3e51f70be7730dc77b1f2bb69e74845dd0fbd2110a921c32265a") + depends_on("c", type="build") # generated + depends_on("zlib-api", type="link") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/seqtk/package.py b/var/spack/repos/builtin/packages/seqtk/package.py index 6334292fbb92af..12a665479f628a 100644 --- a/var/spack/repos/builtin/packages/seqtk/package.py +++ b/var/spack/repos/builtin/packages/seqtk/package.py @@ -19,6 +19,8 @@ class Seqtk(Package): version("1.2", sha256="bd53316645ab10f0aaba59e1e72c28442ee4c9c37fddaacce5e24757eff78d7b") version("1.1", sha256="f01b9f9af6e443673a0105a7536a01957a4fc371826385a1f3dd1e417aa91d52") + depends_on("c", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/serenity-libint/package.py b/var/spack/repos/builtin/packages/serenity-libint/package.py index 3447d11845fe48..3677f35e02144c 100644 --- a/var/spack/repos/builtin/packages/serenity-libint/package.py +++ b/var/spack/repos/builtin/packages/serenity-libint/package.py @@ -9,8 +9,7 @@ class SerenityLibint(CMakePackage): """Serenity fork of libint, which is difficult to reproduce from libint itself""" - homepage = "https://thclab.uni-muenster.de/serenity/libint" - url = "https://thclab.uni-muenster.de/serenity/libint/-/raw/e3eb756c/libint-2.7.0-beta.6.tgz" + url = "https://www.uni-muenster.de/Chemie.oc/THCLAB/libint/libint-2.7.0-beta.6.tgz" license("LGPL-3.0-or-later") @@ -18,6 +17,10 @@ class SerenityLibint(CMakePackage): "2.7.0-beta.6", sha256="53af60c7be74374b2a2d893b3d2d37fa6a3078a72d98067bf71ba4ede4e807df" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("boost") depends_on("eigen@3:") # Probably overdepending? depends_on("gmp+cxx") diff --git a/var/spack/repos/builtin/packages/serenity/package.py b/var/spack/repos/builtin/packages/serenity/package.py index 12c05b147ab339..e8a70da49b1afa 100644 --- a/var/spack/repos/builtin/packages/serenity/package.py +++ b/var/spack/repos/builtin/packages/serenity/package.py @@ -16,21 +16,33 @@ class Serenity(CMakePackage): license("LGPL-3.0-only") version("master", branch="master") + version("1.6.1", sha256="cc04b13c2e8a010d07389b2fed98981deacf085778d5375b3b6e89b967c3a5e6") version("1.4.0", sha256="c7a87fc8e6f8ca21685a27e08d09d49824d9a1e9947fc6abb40d20fbba0cc6e8") + depends_on("cxx", type="build") # generated + variant("blas", default=True, description="Use BLAS library with Eigen") variant("lapack", default=True, description="Use Lapack library with Eigen") variant("python", default=False, description="Build Python bindings") + variant("prefer_xcfun", default=True, description="Prefer XCFun instead of LibXC") + variant( + "laplace_minimax", + default=False, + description="Download and use Laplace-Minimax", + when="@1.6.1:", + ) depends_on("blas", when="+blas") depends_on("cmake@3.12:", type="build") - depends_on("boost") + depends_on("boost+system+filesystem+program_options cxxstd=17 @1.65.0:") depends_on("eigen@3:") - depends_on("googletest@1.8.1:", type="test") - depends_on("hdf5@1.10.1:") + depends_on("googletest@1.8.1:", type="test", when="@1.4.0") + depends_on("googletest@1.13.0:", type="test", when="@1.6.1:") + depends_on("hdf5@1.10.1:+hl+cxx") depends_on("lapack", when="+lapack") depends_on("libecpint") - depends_on("libxc@5.0.0") + depends_on("libxc@6.1.0", when="@1.6.1:") + depends_on("libxc@5.0.0", when="@1.4.0") depends_on("pkgconfig", type="build") depends_on("python@3.6:", when="+python", type=("build", "run")) depends_on("py-pip", when="+python", type="build") @@ -40,6 +52,12 @@ class Serenity(CMakePackage): extends("python", when="+python") + patch( + "https://github.com/qcserenity/serenity/commit/af9f76d013e240d971337a467a03640cb9aabfb7.patch?full_index=1", + sha256="45cce5e4d47b681891e78725b2cf5031d306337a5c7b8e62cd4891beb4a7b8b6", + when="@1.6.1:", + ) + def patch(self): filter_file( "include(CMakeParseArguments)", @@ -48,7 +66,7 @@ def patch(self): string=True, ) - if self.run_tests: + if self.spec.satisfies(":@1.4"): filter_file( "find_package(GTest 1.8.1 QUIET)", "find_package(GTest REQUIRED)", @@ -63,63 +81,75 @@ def patch(self): string=True, ) - filter_file( - "function(import_libecpint)", - "function(import_libecpint)\n" - "find_package(ecpint CONFIG REQUIRED)\n" - "add_library(ecpint INTERFACE IMPORTED)\n" - "target_link_libraries(ecpint INTERFACE ECPINT::ecpint)\n", - "cmake/ImportLibecpint.cmake", - string=True, - ) + filter_file( + "function(import_libecpint)", + "function(import_libecpint)\n" + "find_package(ecpint CONFIG REQUIRED)\n" + "add_library(ecpint INTERFACE IMPORTED)\n" + "target_link_libraries(ecpint INTERFACE ECPINT::ecpint)\n", + "cmake/ImportLibecpint.cmake", + string=True, + ) - filter_file( - "function(import_libint)", - "function(import_libint)\n" - "find_package(Libint2 CONFIG REQUIRED)\n" - "add_library(libint2-static INTERFACE IMPORTED)\n" - "target_link_libraries(libint2-static INTERFACE Libint2::libint2)\n", - "cmake/ImportLibint.cmake", - string=True, - ) + filter_file( + "function(import_libint)", + "function(import_libint)\n" + "find_package(Libint2 CONFIG REQUIRED)\n" + "add_library(libint2-static INTERFACE IMPORTED)\n" + "target_link_libraries(libint2-static INTERFACE Libint2::libint2)\n", + "cmake/ImportLibint.cmake", + string=True, + ) - filter_file( - "function(import_libxc)", - "function(import_libxc)\n" - "find_package(PkgConfig QUIET)\n" - "pkg_check_modules(pc_libxc libxc)\n" - "if(pc_libxc_FOUND)\n" - "add_library(xc INTERFACE IMPORTED)\n" - "target_link_libraries(xc INTERFACE ${pc_libxc_LINK_LIBRARIES})\n" - "target_include_directories(xc INTERFACE ${pc_libxc_INCLUDE_DIRS})\n" - "endif()", - "cmake/ImportLibxc.cmake", - string=True, - ) + filter_file( + "function(import_libxc)", + "function(import_libxc)\n" + "find_package(PkgConfig QUIET)\n" + "pkg_check_modules(pc_libxc libxc)\n" + "if(pc_libxc_FOUND)\n" + "add_library(xc INTERFACE IMPORTED)\n" + "target_link_libraries(xc INTERFACE ${pc_libxc_LINK_LIBRARIES})\n" + "target_include_directories(xc INTERFACE ${pc_libxc_INCLUDE_DIRS})\n" + 'message("XC: included ${pc_libxc_LINK_LIBRARIES} ${pc_libxc_INCLUDE_DIRS}")\n' + "endif()", + "cmake/ImportLibxc.cmake", + string=True, + ) - filter_file( - "function(import_pybind11)", - "function(import_pybind11)\nfind_package(pybind11 REQUIRED)", - "cmake/ImportPybind11.cmake", - string=True, - ) + filter_file( + "function(import_pybind11)", + "function(import_pybind11)\nfind_package(pybind11 REQUIRED)", + "cmake/ImportPybind11.cmake", + string=True, + ) - filter_file( - "function(import_xcfun)", - "function(import_xcfun)\n" - "find_package(XCFun CONFIG REQUIRED)\n" - "add_library(xcfun INTERFACE IMPORTED)\n" - "target_link_libraries(xcfun INTERFACE XCFun::xcfun)\n", - "cmake/ImportXCFun.cmake", - string=True, - ) + filter_file( + "function(import_xcfun)", + "function(import_xcfun)\n" + "find_package(XCFun CONFIG REQUIRED)\n" + "add_library(xcfun INTERFACE IMPORTED)\n" + "target_link_libraries(xcfun INTERFACE XCFun::xcfun)\n", + "cmake/ImportXCFun.cmake", + string=True, + ) + else: + filter_file( + "find_package(GTest QUIET)", + "find_package(GTest REQUIRED)", + "cmake/ImportGTest.cmake", + string=True, + ) + + filter_file( + "find_package(GMock QUIET)", "return()", "cmake/ImportGTest.cmake", string=True + ) def cmake_args(self): - return [ - self.define("SERENITY_BUILD_TESTS", self.run_tests), - self.define_from_variant("SERENITY_BUILD_PYTHON_BINDINGS", "python"), + args = [ + self.define("SERENITY_ENABLE_TESTS", self.run_tests), + self.define_from_variant("SERENITY_PYTHON_BINDINGS", "python"), self.define("SERENITY_MARCH", ""), - self.define("SERENITY_PREFER_XCFUN", False), + self.define_from_variant("SERENITY_PREFER_XCFUN", "prefer_xcfun"), self.define("SERENITY_USE_XCFUN", True), self.define("SERENITY_USE_LIBXC", True), self.define( @@ -137,3 +167,18 @@ def cmake_args(self): self.define("BOOST_NO_SYSTEM_PATHS", True), self.define("Boost_NO_BOOST_CMAKE", True), ] + if self.spec.satisfies("@1.6.1:"): + args += [ + self.define("SERENITY_DOWNLOAD_DEPENDENCIES", False), + self.define_from_variant("SERENITY_USE_LAPLACE_MINIMAX", "laplace_minimax"), + ] + if "+python" in self.spec: + args.append(self.define("PYTHON_EXECUTABLE", self.spec["python"].command.path)) + return args + + def setup_run_environment(self, env): + # set up environment like if we sourced dev/templates/serenity.sh + env.set("SERENITY_HOME", self.prefix) + env.set("SERENITY_BIN", self.prefix.bin) + env.set("SERENITY_RESOURCES", join_path(self.prefix.share, "serenity/data/")) + env.prepend_path("PYTHONPATH", self.prefix.lib) diff --git a/var/spack/repos/builtin/packages/serf/package.py b/var/spack/repos/builtin/packages/serf/package.py index 192d84f4a9d94e..a0a68e16a6456b 100644 --- a/var/spack/repos/builtin/packages/serf/package.py +++ b/var/spack/repos/builtin/packages/serf/package.py @@ -21,6 +21,8 @@ class Serf(SConsPackage): version("1.3.9", sha256="549c2d21c577a8a9c0450facb5cca809f26591f048e466552240947bdf7a87cc") version("1.3.8", sha256="e0500be065dbbce490449837bb2ab624e46d64fc0b090474d9acaa87c82b2590") + depends_on("c", type="build") # generated + variant( "debug", default=False, description="Enable debugging info and strict compile warnings" ) diff --git a/var/spack/repos/builtin/packages/serialbox/package.py b/var/spack/repos/builtin/packages/serialbox/package.py index 8ec0fe3b4c4b43..0618fe9db2bffb 100644 --- a/var/spack/repos/builtin/packages/serialbox/package.py +++ b/var/spack/repos/builtin/packages/serialbox/package.py @@ -24,6 +24,10 @@ class Serialbox(CMakePackage): version("2.5.4", sha256="f4aee8ef284f58e6847968fe4620e222ac7019d805bbbb26c199e4b6a5094fee") version("2.5.3", sha256="696499b3f43978238c3bcc8f9de50bce2630c07971c47c9e03af0324652b2d5d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("c", default=True, description="enable C interface") variant("python", default=False, description="enable Python interface") variant("fortran", default=False, description="enable Fortran interface") diff --git a/var/spack/repos/builtin/packages/sessreg/package.py b/var/spack/repos/builtin/packages/sessreg/package.py index 12d0804d92eed8..4873193756c303 100644 --- a/var/spack/repos/builtin/packages/sessreg/package.py +++ b/var/spack/repos/builtin/packages/sessreg/package.py @@ -21,6 +21,8 @@ class Sessreg(AutotoolsPackage, XorgPackage): version("1.1.1", sha256="3e38f72ff690eaffc0f5eaff533a236bb5e93d4b91ed4fff60e9a2505347d009") version("1.1.0", sha256="e561edb48dfc3b0624554169c15f9dd2c3139e83084cb323b0c712724f2b6043") + depends_on("c", type="build") # generated + depends_on("xproto@7.0.25:") depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") diff --git a/var/spack/repos/builtin/packages/setserial/package.py b/var/spack/repos/builtin/packages/setserial/package.py index 65bb951974a9ca..2b2bd5267c52ab 100644 --- a/var/spack/repos/builtin/packages/setserial/package.py +++ b/var/spack/repos/builtin/packages/setserial/package.py @@ -18,6 +18,8 @@ class Setserial(AutotoolsPackage): version("2.17", sha256="7e4487d320ac31558563424189435d396ddf77953bb23111a17a3d1487b5794a") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) mkdirp(prefix.usr.man.man8) diff --git a/var/spack/repos/builtin/packages/setxkbmap/package.py b/var/spack/repos/builtin/packages/setxkbmap/package.py index d68814690a67af..4dff2c389875d6 100644 --- a/var/spack/repos/builtin/packages/setxkbmap/package.py +++ b/var/spack/repos/builtin/packages/setxkbmap/package.py @@ -16,10 +16,13 @@ class Setxkbmap(AutotoolsPackage, XorgPackage): license("MIT") + version("1.3.4", sha256="cc4113eab3cd70c28c986174aa30e62690e789723c874acc53e8d1f058d11f92") version("1.3.3", sha256="51ba28edf93a464a7444b53b154fd5e93dedd1e9bbcc85b636f4cf56986c4842") version("1.3.2", sha256="7e934afc55f161406f7dd99b5be8837e5d1478d8263776697b159d48461a1d3c") version("1.3.1", sha256="e24a73669007fa3b280eba4bdc7f75715aeb2e394bf2d63f5cc872502ddde264") + depends_on("c", type="build") # generated + depends_on("libxkbfile") depends_on("libx11") depends_on("libxrandr", when="@1.3.3:") diff --git a/var/spack/repos/builtin/packages/sfcgal/package.py b/var/spack/repos/builtin/packages/sfcgal/package.py index 88fd3e8ff62dbd..d7a6f00e9b69e4 100644 --- a/var/spack/repos/builtin/packages/sfcgal/package.py +++ b/var/spack/repos/builtin/packages/sfcgal/package.py @@ -34,6 +34,8 @@ class Sfcgal(CMakePackage): url=old_github_urlbase.format("1.3.7"), ) + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.6:", type="build") # Ref: https://oslandia.github.io/SFCGAL/installation.html, but starts to work @4.7: # Ref: https://gitlab.com/sfcgal/SFCGAL/-/blob/v1.5.1/NEWS?ref_type=tags diff --git a/var/spack/repos/builtin/packages/sfcio/package.py b/var/spack/repos/builtin/packages/sfcio/package.py index aa762cebc5d048..fc0141a966a550 100644 --- a/var/spack/repos/builtin/packages/sfcio/package.py +++ b/var/spack/repos/builtin/packages/sfcio/package.py @@ -21,6 +21,8 @@ class Sfcio(CMakePackage): version("develop", branch="develop") version("1.4.1", sha256="d9f900cf18ec1a839b4128c069b1336317ffc682086283443354896746b89c59") + depends_on("fortran", type="build") # generated + def setup_run_environment(self, env): lib = find_libraries("libsfcio", root=self.prefix, shared=False, recursive=True) # Only one library version, but still need to set _4 to make NCO happy diff --git a/var/spack/repos/builtin/packages/sga/package.py b/var/spack/repos/builtin/packages/sga/package.py index f99cf55c9718e1..3a6802f85c4350 100644 --- a/var/spack/repos/builtin/packages/sga/package.py +++ b/var/spack/repos/builtin/packages/sga/package.py @@ -24,6 +24,9 @@ class Sga(AutotoolsPackage): version("0.10.8", sha256="55c5e0e425e14902e83d68cfb8cee4c86ee186459e54113a484b2a1b06d223c8") version("0.10.3", sha256="c000823a58428d9db2979b30a571ad89aec78a8cb1af60bae1ce252dd4e8adac") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("sparsehash") depends_on("jemalloc") diff --git a/var/spack/repos/builtin/packages/sgpp/package.py b/var/spack/repos/builtin/packages/sgpp/package.py index c7eb4177c0abe9..caae561d41b8a9 100644 --- a/var/spack/repos/builtin/packages/sgpp/package.py +++ b/var/spack/repos/builtin/packages/sgpp/package.py @@ -22,6 +22,8 @@ class Sgpp(SConsPackage): version("3.4.0", sha256="450d4002850b0a48c561abe221b634261ca44eee111ca605c3e80797182f40b3") version("3.3.0", sha256="ca4d5b79f315b425ce69b04940c141451a76848bf1bd7b96067217304c68e2d4") version("3.2.0", sha256="dab83587fd447f92ed8546eacaac6b8cbe65b8db5e860218c0fa2e42f776962d") + + depends_on("cxx", type="build") # generated # Note: Older versions of SGpp required Python 2 (and offered Python 2 bindings) and have # thus been removed from this list as Spack now requires Python 3. # The last spack release with support for Python 2 is v0.19 - there, the spack package diff --git a/var/spack/repos/builtin/packages/shadow/package.py b/var/spack/repos/builtin/packages/shadow/package.py index c6b1df9b8c9af8..aaed47308ae094 100644 --- a/var/spack/repos/builtin/packages/shadow/package.py +++ b/var/spack/repos/builtin/packages/shadow/package.py @@ -16,7 +16,10 @@ class Shadow(AutotoolsPackage): license("BSD-3-Clause") + version("4.15.1", sha256="b34686b89b279887ffbf1f33128902ccc0fa1a998a3add44213bb12d7385b218") version("4.13", sha256="813057047499c7fe81108adcf0cffa3ad4ec75e19a80151f9cbaa458ff2e86cd") version("4.8.1", sha256="3ee3081fbbcbcfea5c8916419e46bc724807bab271072104f23e7a29e9668f3a") version("4.7", sha256="5135b0ca2a361a218fab59e63d9c1720d2a8fc1faa520c819a654b638017286f") version("4.6", sha256="4668f99bd087399c4a586084dc3b046b75f560720d83e92fd23bf7a89dda4d31") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/shapeit4/package.py b/var/spack/repos/builtin/packages/shapeit4/package.py index 42d5e950ac1e8f..2b6552061731c1 100644 --- a/var/spack/repos/builtin/packages/shapeit4/package.py +++ b/var/spack/repos/builtin/packages/shapeit4/package.py @@ -18,6 +18,8 @@ class Shapeit4(MakefilePackage): version("4.2.2", sha256="9f109e307b5cc22ab68e7bf77de2429a9bbb2212d66303386e6a3dd81a5bc556") version("4.1.3", sha256="d209731277b00bca1e3478b7e0a0cbe40fbe23826c3d640ad12e0dd6033cbbb8") + depends_on("cxx", type="build") # generated + maintainers("ilbiondo") depends_on("htslib") diff --git a/var/spack/repos/builtin/packages/shapelib/package.py b/var/spack/repos/builtin/packages/shapelib/package.py index a10310cc6ab03c..756f7ea1e4cdce 100644 --- a/var/spack/repos/builtin/packages/shapelib/package.py +++ b/var/spack/repos/builtin/packages/shapelib/package.py @@ -17,4 +17,8 @@ class Shapelib(CMakePackage): license("LGPL-2.0-only OR MIT") + version("1.6.0", sha256="0bfd1eab9616ca3c420a5ad674b0d07c7c5018620d6ab6ae43917daa18ff0d1e") version("1.5.0", sha256="48de3a6a8691b0b111b909c0b908af4627635c75322b3a501c0c0885f3558cad") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/shapemapper/package.py b/var/spack/repos/builtin/packages/shapemapper/package.py index 730326f7fa2802..32b3165fe12415 100644 --- a/var/spack/repos/builtin/packages/shapemapper/package.py +++ b/var/spack/repos/builtin/packages/shapemapper/package.py @@ -31,6 +31,8 @@ class Shapemapper(CMakePackage): url="https://github.com/Weeks-UNC/shapemapper2/releases/download/2.1.5/shapemapper-2.1.5-source-only.tar.gz", ) + depends_on("cxx", type="build") # generated + depends_on("bowtie2@2.3.0:", type="run", when="@2.1.5") depends_on("bowtie2@2.3.4:", type="run", when="@2.2.0:") depends_on("perl+threads", type="run") diff --git a/var/spack/repos/builtin/packages/shared-mime-info/package.py b/var/spack/repos/builtin/packages/shared-mime-info/package.py index 7da52d5052d61a..72ec9447bed4e0 100644 --- a/var/spack/repos/builtin/packages/shared-mime-info/package.py +++ b/var/spack/repos/builtin/packages/shared-mime-info/package.py @@ -18,6 +18,8 @@ class SharedMimeInfo(AutotoolsPackage): version("1.9", sha256="5c0133ec4e228e41bdf52f726d271a2d821499c2ab97afd3aa3d6cf43efcdc83") version("1.8", sha256="2af55ef1a0319805b74ab40d331a3962c905477d76c086f49e34dc96363589e9") + depends_on("c", type="build") # generated + parallel = False depends_on("glib") diff --git a/var/spack/repos/builtin/packages/shark/package.py b/var/spack/repos/builtin/packages/shark/package.py index fcec7ed1f1ff58..58eb5dcccec183 100644 --- a/var/spack/repos/builtin/packages/shark/package.py +++ b/var/spack/repos/builtin/packages/shark/package.py @@ -20,6 +20,8 @@ class Shark(CMakePackage): version("4.0.0", sha256="19d4099776327d5f8a2e2be286818c6081c61eb13ca279c1e438c86e70d90210") version("3.1.4", sha256="160c35ddeae3f6aeac3ce132ea4ba2611ece39eee347de2faa3ca52639dc6311") + depends_on("cxx", type="build") # generated + # TODO: replace this with an explicit list of components of Boost, # for instance depends_on('boost +filesystem') # See https://github.com/spack/spack/pull/22303 for reference diff --git a/var/spack/repos/builtin/packages/sheenbidi/package.py b/var/spack/repos/builtin/packages/sheenbidi/package.py index 5b9351b2a4ecdd..27c06e4e024234 100644 --- a/var/spack/repos/builtin/packages/sheenbidi/package.py +++ b/var/spack/repos/builtin/packages/sheenbidi/package.py @@ -16,4 +16,8 @@ class Sheenbidi(MesonPackage): license("Apache-2.0") + version("2.7", sha256="620f732141fd62354361f921a67ba932c44d94e73f127379a0c73ad40c7fa6e0") version("2.6", sha256="f538f51a7861dd95fb9e3f4ad885f39204b5c670867019b5adb7c4b410c8e0d9") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/sherpa/package.py b/var/spack/repos/builtin/packages/sherpa/package.py index 5bb347021635d2..f132fb06788778 100644 --- a/var/spack/repos/builtin/packages/sherpa/package.py +++ b/var/spack/repos/builtin/packages/sherpa/package.py @@ -118,6 +118,10 @@ class Sherpa(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + _cxxstd_values = ("11", "14", "17") variant( "cxxstd", @@ -159,10 +163,12 @@ class Sherpa(AutotoolsPackage): # Note that the delphes integration seems utterly broken: https://sherpa.hepforge.org/trac/ticket/305 - depends_on("autoconf", type="build") - depends_on("automake", type="build") - depends_on("libtool", type="build") - depends_on("m4", type="build") + # autotools dependencies are needed at runtime to compile processes + # at least as long as sherpa is an autotools package + depends_on("autoconf") + depends_on("automake") + depends_on("libtool") + depends_on("m4") depends_on("texinfo", type="build") depends_on("sqlite") @@ -187,6 +193,8 @@ class Sherpa(AutotoolsPackage): depends_on("hztool", when="+hztool") # depends_on('cernlib', when='+cernlib') + filter_compiler_wrappers("share/SHERPA-MC/makelibs") + for std in _cxxstd_values: depends_on("root cxxstd=" + std, when="+root cxxstd=" + std) @@ -261,3 +269,14 @@ def flag_handler(self, name, flags): flags.append("-m64") return (None, None, flags) + + # This may not be needed when this package is changed to be a CMake package + # since it's specific to makelibs + def install(self, spec, prefix): + # Make sure the path to the provided libtool is used instead of the system one + filter_file( + r"autoreconf -fi", + f"autoreconf -fi -I {self.spec['libtool'].prefix.share.aclocal}", + "AMEGIC++/Main/makelibs", + ) + make("install") diff --git a/var/spack/repos/builtin/packages/shocklibs/package.py b/var/spack/repos/builtin/packages/shocklibs/package.py index 079f3d6e497619..79fc07ae21a910 100644 --- a/var/spack/repos/builtin/packages/shocklibs/package.py +++ b/var/spack/repos/builtin/packages/shocklibs/package.py @@ -14,7 +14,10 @@ class Shocklibs(Package): license("BSD-2-Clause") + version("0.9.29", sha256="81c61f22b869b9923065ee57f9bcf62d95bf266887b09486f6c8e6aa07aa2c0a") version("0.9.24", sha256="465d06f33df2570eaf3ffd535a38fc464084ac95a2f145ead5c71f34beeb0a35") + depends_on("c", type="build") # generated + def install(self, spec, prefix): install_tree("libs", prefix.libs) diff --git a/var/spack/repos/builtin/packages/shoremap/package.py b/var/spack/repos/builtin/packages/shoremap/package.py index be2c189b4f2387..6eae1ff1fba985 100644 --- a/var/spack/repos/builtin/packages/shoremap/package.py +++ b/var/spack/repos/builtin/packages/shoremap/package.py @@ -23,6 +23,8 @@ class Shoremap(MakefilePackage): version("3.6", sha256="0da4179e92cbc68434a9d8eff7bd5fff55c89fd9a543a2db6bd0f69074f2ec70") + depends_on("cxx", type="build") # generated + depends_on("dislin") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/showfont/package.py b/var/spack/repos/builtin/packages/showfont/package.py index 794ed08ae67f82..77793004157c17 100644 --- a/var/spack/repos/builtin/packages/showfont/package.py +++ b/var/spack/repos/builtin/packages/showfont/package.py @@ -17,6 +17,8 @@ class Showfont(AutotoolsPackage, XorgPackage): version("1.0.6", sha256="006c5cb931e33c8c073215cf106a9c7fe93b81ccb4268274bb33dd5697e1f425") version("1.0.5", sha256="566e34a145ea73397724d46e84f6a9b3691cf55d0fcb96ec7f917b2b39265ebb") + depends_on("c", type="build") # generated + depends_on("libfs") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/shtools/package.py b/var/spack/repos/builtin/packages/shtools/package.py index 6bfdb4e0504741..2213eca0825790 100644 --- a/var/spack/repos/builtin/packages/shtools/package.py +++ b/var/spack/repos/builtin/packages/shtools/package.py @@ -20,6 +20,9 @@ class Shtools(MakefilePackage): version("4.8", sha256="c36fc86810017e544abbfb12f8ddf6f101a1ac8b89856a76d7d9801ffc8dac44") version("4.5", sha256="1975a2a2bcef8c527d321be08c13c2bc479e0d6b81c468a3203f95df59be4f89") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Note: This package also provides Python wrappers. We do not # install these properly yet, only the Fortran library is # installed. diff --git a/var/spack/repos/builtin/packages/shuffile/package.py b/var/spack/repos/builtin/packages/shuffile/package.py index ee1697dacd04c0..116254b1faaab1 100644 --- a/var/spack/repos/builtin/packages/shuffile/package.py +++ b/var/spack/repos/builtin/packages/shuffile/package.py @@ -25,6 +25,8 @@ class Shuffile(CMakePackage): version("0.0.4", sha256="f0249ab31fc6123103ad67b1eaf799277c72adcf0dfcddf8c3a18bad2d45031d") version("0.0.3", sha256="a3f685526a1146a5ad8dbacdc5f9c2e1152d9761a1a179c1db34f55afc8372f6") + depends_on("c", type="build") # generated + depends_on("mpi") depends_on("kvtree+mpi") depends_on("zlib-api", type="link") @@ -44,8 +46,5 @@ def cmake_args(self): if spec.satisfies("@0.1.0:"): args.append(self.define_from_variant("BUILD_SHARED_LIBS", "shared")) - else: - if spec.satisfies("platform=cray"): - args.append(self.define("SHUFFILE_LINK_STATIC", True)) return args diff --git a/var/spack/repos/builtin/packages/sicer2/package.py b/var/spack/repos/builtin/packages/sicer2/package.py index 6a6f79a957cd85..3c638453f0fd3a 100644 --- a/var/spack/repos/builtin/packages/sicer2/package.py +++ b/var/spack/repos/builtin/packages/sicer2/package.py @@ -16,6 +16,8 @@ class Sicer2(PythonPackage): version("1.0.3", sha256="003e0f46fb45717fa6b1c94b2c21416161f5b3a4896fbb335cf2024daf2560dd") + depends_on("c", type="build") # generated + depends_on("py-setuptools", type="build") depends_on("py-numpy", type=("build", "run")) depends_on("py-scipy@1.0.0:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/sickle/package.py b/var/spack/repos/builtin/packages/sickle/package.py index ad0db8556895ff..f4706dc67b6cd5 100644 --- a/var/spack/repos/builtin/packages/sickle/package.py +++ b/var/spack/repos/builtin/packages/sickle/package.py @@ -19,6 +19,8 @@ class Sickle(MakefilePackage): version("1.33", sha256="eab271d25dc799e2ce67c25626128f8f8ed65e3cd68e799479bba20964624734") + depends_on("c", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/sicm/package.py b/var/spack/repos/builtin/packages/sicm/package.py index 68ab4de4efebd0..32ecbb9458b02b 100644 --- a/var/spack/repos/builtin/packages/sicm/package.py +++ b/var/spack/repos/builtin/packages/sicm/package.py @@ -16,6 +16,10 @@ class Sicm(CMakePackage): version("master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("jemalloc jemalloc_prefix=je_") depends_on("numactl") diff --git a/var/spack/repos/builtin/packages/siesta/package.py b/var/spack/repos/builtin/packages/siesta/package.py index aa41d69581b9ed..62dbfe920e227a 100644 --- a/var/spack/repos/builtin/packages/siesta/package.py +++ b/var/spack/repos/builtin/packages/siesta/package.py @@ -30,6 +30,9 @@ class Siesta(MakefilePackage): url="http://departments.icmab.es/leem/siesta/CodeAccess/Code/siesta-3.2-pl-5.tgz", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + patch("configure.patch", when="@:4.0") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/sigcpp/package.py b/var/spack/repos/builtin/packages/sigcpp/package.py index b4afc0f1b31d07..375f7c3c37ff63 100644 --- a/var/spack/repos/builtin/packages/sigcpp/package.py +++ b/var/spack/repos/builtin/packages/sigcpp/package.py @@ -17,9 +17,12 @@ class Sigcpp(CMakePackage): license("LGPL-3.0-only") + version("3.6.0", sha256="bbe81e4f6d8acb41a9795525a38c0782751dbc4af3d78a9339f4a282e8a16c38") version("3.2.0", sha256="f9c36331b5d5ac7a1651477288f47eec51394c03ade8bb1a05d1c46eac5f77e7") version("3.0.7", sha256="063b6ab86e4d8703ea65d894d78e8482b1fc34b92be8849f82ce1c5b05cf2b8d") + depends_on("cxx", type="build") # generated + variant("doc", default=True, description="Keep man files") @run_after("install") diff --git a/var/spack/repos/builtin/packages/sigio/package.py b/var/spack/repos/builtin/packages/sigio/package.py index 1fc5edd76a421b..681b46b7626431 100644 --- a/var/spack/repos/builtin/packages/sigio/package.py +++ b/var/spack/repos/builtin/packages/sigio/package.py @@ -21,6 +21,8 @@ class Sigio(CMakePackage): version("develop", branch="develop") version("2.3.2", sha256="333f3cf3a97f97103cbafcafc2ad89b24faa55b1332a98adc1637855e8a5b613") + depends_on("fortran", type="build") # generated + def setup_run_environment(self, env): lib = find_libraries("libsigio", root=self.prefix, shared=False, recursive=True) # Only one library version, but still need to set _4 to make NCO happy diff --git a/var/spack/repos/builtin/packages/signify/package.py b/var/spack/repos/builtin/packages/signify/package.py index 5c7e6c37c1241a..d63eed1060a372 100644 --- a/var/spack/repos/builtin/packages/signify/package.py +++ b/var/spack/repos/builtin/packages/signify/package.py @@ -14,9 +14,12 @@ class Signify(MakefilePackage): license("ISC") + version("32", sha256="48cfd7bfe55be01909b37e78045f240b950ea51c954bab205bcdcddc0492dca4") version("31", sha256="8111af7424f4cc69dab5cd43a14ccd607ca2d171ac77dd3ae288264a53254e5f") version("23", sha256="1c690bf0e4283e0764a4a9dd784cb3debf4bb456b975b275dd1aaac7d5afe030") + depends_on("c", type="build") # generated + depends_on("libbsd@0.8:") def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/silo/package.py b/var/spack/repos/builtin/packages/silo/package.py index 435255a4dea5cf..df4617244a9281 100644 --- a/var/spack/repos/builtin/packages/silo/package.py +++ b/var/spack/repos/builtin/packages/silo/package.py @@ -50,6 +50,10 @@ class Silo(AutotoolsPackage): version("4.9", sha256="90f3d069963d859c142809cfcb034bc83eb951f61ac02ccb967fc8e8d0409854") version("4.8", sha256="c430c1d33fcb9bc136a99ad473d535d6763bd1357b704a915ba7b1081d58fb21") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("fortran", default=True, description="Enable Fortran support") variant("shared", default=True, description="Build shared libraries") variant("silex", default=False, description="Builds Silex, a GUI for viewing Silo files") diff --git a/var/spack/repos/builtin/packages/simde/package.py b/var/spack/repos/builtin/packages/simde/package.py index becbbdea6e8b33..17cd3a66fab24b 100644 --- a/var/spack/repos/builtin/packages/simde/package.py +++ b/var/spack/repos/builtin/packages/simde/package.py @@ -24,5 +24,7 @@ class Simde(MesonPackage): version("0.7.2", sha256="366d5e9a342c30f1e40d1234656fb49af5ee35590aaf53b3c79b2afb906ed4c8") version("0.6.0", sha256="25a8b8c69c17ddc2f6209e86caa6b12d4ed91c0f841617efc56e5675eea84915") + depends_on("c", type="build") # generated + patch("sve-gcc.patch", when="@0.6.0 %gcc") conflicts("%gcc@8", when="target=a64fx", msg="Internal compiler error with gcc8 and a64fx") diff --git a/var/spack/repos/builtin/packages/simgrid/package.py b/var/spack/repos/builtin/packages/simgrid/package.py index d164029b39960f..a7d7b7de872e67 100644 --- a/var/spack/repos/builtin/packages/simgrid/package.py +++ b/var/spack/repos/builtin/packages/simgrid/package.py @@ -119,6 +119,10 @@ class Simgrid(CMakePackage): version("develop", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("doc", default=False, description="Build documentation") variant("smpi", default=True, description="SMPI provides MPI") variant("examples", default=False, description="Install examples") diff --git a/var/spack/repos/builtin/packages/simmetrix-simmodsuite/package.py b/var/spack/repos/builtin/packages/simmetrix-simmodsuite/package.py index 65fe64d19d67a0..19a9f2fa1c06d0 100644 --- a/var/spack/repos/builtin/packages/simmetrix-simmodsuite/package.py +++ b/var/spack/repos/builtin/packages/simmetrix-simmodsuite/package.py @@ -542,8 +542,9 @@ class SimmetrixSimmodsuite(Package): variant("paralleladapt", default=False, description="enable parallel adaptation") depends_on("mpi") + depends_on("libtirpc", type="link") - oslib = "x64_rhel7_gcc48" + oslib = "x64_rhel8_gcc83" for release in RELEASES: # define the version using the mscore tarball @@ -571,12 +572,12 @@ class SimmetrixSimmodsuite(Package): simmetrix_resource(_name, url, sha256, condition) def setup_dependent_build_environment(self, env, dependent_spec): - archlib = join_path(prefix.lib, self.oslib) + archlib = join_path(self.prefix.lib, self.oslib) env.append_path("CMAKE_PREFIX_PATH", archlib) simmetrix_setkernelcmakeprefixpath(self.spec, archlib, env) def setup_run_environment(self, env): - archlib = join_path(prefix.lib, self.oslib) + archlib = join_path(self.prefix.lib, self.oslib) env.append_path("CMAKE_PREFIX_PATH", archlib) simmetrix_setkernelcmakeprefixpath(self.spec, archlib, env) diff --git a/var/spack/repos/builtin/packages/simple-dftd3/package.py b/var/spack/repos/builtin/packages/simple-dftd3/package.py index dda976818a48d9..e79bf2f9a2bffd 100644 --- a/var/spack/repos/builtin/packages/simple-dftd3/package.py +++ b/var/spack/repos/builtin/packages/simple-dftd3/package.py @@ -24,6 +24,9 @@ class SimpleDftd3(MesonPackage): version("0.6.0", sha256="c057361565f570cb128489c70131487f71b6891a40e5292dfe37041596810dfe") version("0.5.1", sha256="0411fdaebe438f652a970cb232ae3199c4cc840366ed05fda4c38e634632040d") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=True, description="Use OpenMP parallelisation") variant("python", default=False, description="Build Python extension module") diff --git a/var/spack/repos/builtin/packages/simplemoc/package.py b/var/spack/repos/builtin/packages/simplemoc/package.py index edae6d58e48f5e..9699d1bd52f05c 100644 --- a/var/spack/repos/builtin/packages/simplemoc/package.py +++ b/var/spack/repos/builtin/packages/simplemoc/package.py @@ -20,6 +20,8 @@ class Simplemoc(MakefilePackage): version("4", sha256="a39906014fdb234c43bf26e1919bdc8a13097788812e0b353a492b8e568816a6") + depends_on("c", type="build") # generated + tags = ["proxy-app"] variant("mpi", default=True, description="Build with MPI support") diff --git a/var/spack/repos/builtin/packages/simsipm/package.py b/var/spack/repos/builtin/packages/simsipm/package.py index c60d3c1fe82199..8cdce1904a6ab4 100644 --- a/var/spack/repos/builtin/packages/simsipm/package.py +++ b/var/spack/repos/builtin/packages/simsipm/package.py @@ -24,6 +24,8 @@ class Simsipm(CMakePackage): version("2.0.2", sha256="ba60ed88b54b1b29d089f583dbce93b3272b0b13d47772941339f1503ee3fa48") version("1.2.4", sha256="1c633bebb19c490b5e6dfa5ada4a6bc7ec36348237c2626d57843a25af923211") + depends_on("cxx", type="build") # generated + variant("python", default=False, description="Build pybind11-based python bindings") variant("openmp", default=False, description="Use OpenMP", when="@:1") diff --git a/var/spack/repos/builtin/packages/simul/package.py b/var/spack/repos/builtin/packages/simul/package.py index a415be56c79745..b8eda857f53930 100644 --- a/var/spack/repos/builtin/packages/simul/package.py +++ b/var/spack/repos/builtin/packages/simul/package.py @@ -18,6 +18,8 @@ class Simul(Package): version("1.14", sha256="cbc70881b2a03e9a5076dbdf82b6fdfa48351ab381e379935b9c7db0ee315c92") version("1.13", sha256="42a67258181fbf723cfe13d4d2dabc5aed0d0daa606b9d817108c354e37d1c64") + depends_on("c", type="build") # generated + depends_on("mpi") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/simulationio/package.py b/var/spack/repos/builtin/packages/simulationio/package.py index 0ca06958f0136f..04b3efd8c1ecef 100644 --- a/var/spack/repos/builtin/packages/simulationio/package.py +++ b/var/spack/repos/builtin/packages/simulationio/package.py @@ -23,6 +23,8 @@ class Simulationio(CMakePackage): version("9.0.2", sha256="3dd3422e64f6a75215783f6157effd07430e1d0af5884e565f73388a815511f8") version("9.0.1", sha256="c2f6c99417165f6eb8cbb9c44822d119586675abb34eabd553eb80f44b53e0c8") + depends_on("cxx", type="build") # generated + variant("asdf", default=True, description="Enable ASDF bindings") variant("julia", default=False, description="Enable Julia bindings") variant("python", default=True, description="Enable Python bindings", when="@9:") diff --git a/var/spack/repos/builtin/packages/sina/package.py b/var/spack/repos/builtin/packages/sina/package.py index 1131cfba3a0398..fd46c1e1e0763d 100644 --- a/var/spack/repos/builtin/packages/sina/package.py +++ b/var/spack/repos/builtin/packages/sina/package.py @@ -20,6 +20,9 @@ class Sina(CachedCMakePackage): version("1.11.0", sha256="a080f6583101696a6354940f00646ef892e1b2f8fc3f1b1907ba1c3ade6d4b47") version("1.10.0", sha256="b34379ce8cc5eca5a0f16893053fac75be14c2109d1beed4c6d48e11f9b281c7") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("docs", default=False, description="Allow generating documentation") variant("adiak", default=False, description="Create interface for calling Sina through Adiak") variant("test", default=False, description="Build tests") diff --git a/var/spack/repos/builtin/packages/singularity-eos/package.py b/var/spack/repos/builtin/packages/singularity-eos/package.py index 45970a4f5c09dc..ac3fc6655ef3f0 100644 --- a/var/spack/repos/builtin/packages/singularity-eos/package.py +++ b/var/spack/repos/builtin/packages/singularity-eos/package.py @@ -34,6 +34,9 @@ class SingularityEos(CMakePackage, CudaPackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # build with kokkos, kokkos-kernels for offloading support variant("kokkos", default=False, description="Enable kokkos") variant( diff --git a/var/spack/repos/builtin/packages/singularity-legacy/package.py b/var/spack/repos/builtin/packages/singularity-legacy/package.py index 3cd875286a5456..9780439e871dfe 100644 --- a/var/spack/repos/builtin/packages/singularity-legacy/package.py +++ b/var/spack/repos/builtin/packages/singularity-legacy/package.py @@ -36,6 +36,8 @@ class SingularityLegacy(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("libarchive", when="@2.5.2:") # these are only needed if we're grabbing the unreleased tree depends_on("m4", type="build", when="@2.6-release") diff --git a/var/spack/repos/builtin/packages/singularity/package.py b/var/spack/repos/builtin/packages/singularity/package.py index 317c3ac8278b32..b5b6c4895059d5 100644 --- a/var/spack/repos/builtin/packages/singularity/package.py +++ b/var/spack/repos/builtin/packages/singularity/package.py @@ -132,4 +132,6 @@ class Singularity(SingularityBase): deprecated=True, ) + depends_on("c", type="build") # generated + patch("singularity_v3.4.0_remove_root_check.patch", level=0, when="@3.4.0:3.4.1") diff --git a/var/spack/repos/builtin/packages/singularityce/package.py b/var/spack/repos/builtin/packages/singularityce/package.py index a85c45ba403e51..4969b1e3c27fbb 100644 --- a/var/spack/repos/builtin/packages/singularityce/package.py +++ b/var/spack/repos/builtin/packages/singularityce/package.py @@ -218,3 +218,5 @@ class Singularityce(SingularityBase): version("3.9.9", sha256="1381433d64138c08e93ffacdfb4844e82c2288f1e39a9d2c631a1c4021381f2a") version("3.9.1", sha256="1ba3bb1719a420f48e9b0a6afdb5011f6c786d0f107ef272528c632fff9fd153") version("3.8.0", sha256="5fa2c0e7ef2b814d8aa170826b833f91e5031a85d85cd1292a234e6c55da1be1") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/sio/package.py b/var/spack/repos/builtin/packages/sio/package.py index 972f6821076d2f..c549311fa185f8 100644 --- a/var/spack/repos/builtin/packages/sio/package.py +++ b/var/spack/repos/builtin/packages/sio/package.py @@ -27,6 +27,9 @@ class Sio(CMakePackage): version("0.0.3", sha256="4c8b9c08480fb53cd10abb0e1260071a8c3f68d06a8acfd373f6560a916155cc") version("0.0.2", sha256="e4cd2aeaeaa23c1da2c20c5c08a9b72a31b16b7a8f5aa6d480dcd561ef667657") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "builtin_zlib", default=True, diff --git a/var/spack/repos/builtin/packages/sionlib/package.py b/var/spack/repos/builtin/packages/sionlib/package.py index c329066b0eaa7d..b69e418f4454d3 100644 --- a/var/spack/repos/builtin/packages/sionlib/package.py +++ b/var/spack/repos/builtin/packages/sionlib/package.py @@ -23,6 +23,10 @@ class Sionlib(AutotoolsPackage): extension="tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") patch("for_aarch64.patch", when="target=aarch64:") diff --git a/var/spack/repos/builtin/packages/sirius/package.py b/var/spack/repos/builtin/packages/sirius/package.py index c57daf47a3b4fc..a438b264c400eb 100644 --- a/var/spack/repos/builtin/packages/sirius/package.py +++ b/var/spack/repos/builtin/packages/sirius/package.py @@ -82,6 +82,9 @@ class Sirius(CMakePackage, CudaPackage, ROCmPackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("openmp", default=True, description="Build with OpenMP support") variant("fortran", default=False, description="Build Fortran bindings") @@ -108,6 +111,15 @@ class Sirius(CMakePackage, CudaPackage, ROCmPackage): ) variant("nvtx", default=False, description="Use NVTX profiler") + with when("@7.6:"): + variant( + "pugixml", + default=False, + description="Enable direct reading of UPF v2 pseudopotentials", + ) + conflicts("+tests~pugixml") + depends_on("pugixml", when="+pugixml") + depends_on("cmake@3.23:", type="build") depends_on("mpi") depends_on("gsl") @@ -146,7 +158,8 @@ class Sirius(CMakePackage, CudaPackage, ROCmPackage): depends_on("spla@1.1.0:") depends_on("spla+cuda", when="+cuda") depends_on("spla+rocm", when="+rocm") - depends_on("spla+openmp", when="+openmp") + # spla removed the openmp option in 1.6.0 + conflicts("^spla@:1.5~openmp", when="+openmp") depends_on("nlcglib", when="+nlcglib") depends_on("nlcglib+rocm", when="+nlcglib+rocm") @@ -162,18 +175,38 @@ class Sirius(CMakePackage, CudaPackage, ROCmPackage): depends_on("dla-future +cuda", when="+cuda") depends_on("dla-future +rocm", when="+rocm") + conflicts("^pika@:0.22.1", when="+cuda") + conflicts("^pika@:0.22.1", when="+rocm") + depends_on("rocblas", when="+rocm") depends_on("rocsolver", when="@7.5.0: +rocm") + # FindHIP cmake script only works for < 4.1, but HIP 4.1 is not provided by spack anymore + conflicts("+rocm", when="@:7.2.0") + conflicts("^libxc@5.0.0") # known to produce incorrect results conflicts("+single_precision", when="@:7.2.4") conflicts("+scalapack", when="^cray-libsci") # Propagate openmp to blas - depends_on("openblas threads=openmp", when="+openmp ^[virtuals=blas] openblas") + depends_on("openblas threads=openmp", when="+openmp ^[virtuals=blas,lapack] openblas") depends_on("amdblis threads=openmp", when="+openmp ^[virtuals=blas] amdblis") depends_on("blis threads=openmp", when="+openmp ^[virtuals=blas] blis") - depends_on("intel-mkl threads=openmp", when="+openmp ^[virtuals=blas] intel-mkl") + depends_on( + "intel-mkl threads=openmp", when="+openmp ^[virtuals=blas,lapack,fftw-api] intel-mkl" + ) + depends_on( + "intel-oneapi-mkl threads=openmp", + when="+openmp ^[virtuals=blas,lapack,fftw-api] intel-oneapi-mkl", + ) + depends_on( + "intel-oneapi-mkl+cluster", + when="+scalapack ^[virtuals=blas,lapack,fftw-api] intel-oneapi-mkl", + ) + + conflicts("intel-mkl", when="@develop") # TODO: Change to @7.5.3 + # MKLConfig.cmake introduced in 2021.3 + conflicts("intel-oneapi-mkl@:2021.2", when="^intel-oneapi-mkl") depends_on("wannier90", when="@7.5.0: +wannier90") depends_on("wannier90+shared", when="@7.5.0: +wannier90+shared") @@ -183,7 +216,7 @@ class Sirius(CMakePackage, CudaPackage, ROCmPackage): depends_on("eigen@3.4.0:", when="@7.3.2: +tests") - depends_on("costa", when="@7.3.2:") + depends_on("costa+shared", when="@7.3.2:") with when("@7.5: +memory_pool"): depends_on("umpire~cuda~rocm", when="~cuda~rocm") @@ -218,6 +251,7 @@ def cmake_args(self): self.define_from_variant(cm_label + "USE_PROFILER", "profiler"), self.define_from_variant(cm_label + "USE_NVTX", "nvtx"), self.define_from_variant(cm_label + "USE_WANNIER90", "wannier90"), + self.define_from_variant(cm_label + "USE_PUGIXML", "pugixml"), self.define_from_variant("BUILD_SHARED_LIBS", "shared"), self.define_from_variant("BUILD_TESTING", "tests"), ] @@ -250,9 +284,43 @@ def cmake_args(self): if "^cray-libsci" in spec: args.append(self.define(cm_label + "USE_CRAY_LIBSCI", "ON")) - if spec["blas"].name in ["intel-mkl", "intel-parallel-studio", "intel-oneapi-mkl"]: + if spec["blas"].name in INTEL_MATH_LIBRARIES: args.append(self.define(cm_label + "USE_MKL", "ON")) + if spec.satisfies("@develop"): # TODO: Change to @7.5.3: + mkl_mapper = { + "threading": { + "none": "sequential", + "openmp": "gnu_thread", + "tbb": "tbb_thread", + }, + "mpi": {"intel-mpi": "intelmpi", "mpich": "mpich", "openmpi": "openmpi"}, + } + + mkl_threads = mkl_mapper["threading"][ + spec["intel-oneapi-mkl"].variants["threads"].value + ] + + mpi_provider = spec["mpi"].name + if mpi_provider in ["mpich", "cray-mpich", "mvapich", "mvapich2"]: + mkl_mpi = mkl_mapper["mpi"]["mpich"] + else: + mkl_mpi = mkl_mapper["mpi"][mpi_provider] + + args.extend( + [ + self.define("MKL_INTERFACE", "lp64"), + self.define("MKL_THREADING", mkl_threads), + self.define("MKL_MPI", mkl_mpi), + ] + ) + + if "+scalapack" in self.spec: + # options provided by `MKLConfig.cmake` + args.extend( + [self.define("ENABLE_BLACS", "On"), self.define("ENABLE_SCALAPACK", "On")] + ) + if "+elpa" in spec: elpa_incdir = os.path.join(spec["elpa"].headers.directories[0], "elpa") args.append(self.define(cm_label + "ELPA_INCLUDE_DIR", elpa_incdir)) diff --git a/var/spack/repos/builtin/packages/skopeo/package.py b/var/spack/repos/builtin/packages/skopeo/package.py index 218b98bfc3a989..3603636b625ad6 100644 --- a/var/spack/repos/builtin/packages/skopeo/package.py +++ b/var/spack/repos/builtin/packages/skopeo/package.py @@ -22,6 +22,8 @@ class Skopeo(MakefilePackage): version("0.1.37", sha256="49c0c1b2c2f32422d3230f827ae405fc554fb34af41a54e59b2121ac1500505d") version("0.1.36", sha256="42f9b0bf53ae44bc294be400e2c5259f977ffa4d5dbac3576b0b5e23d59791fd") + depends_on("c", type="build") # generated + depends_on("go") depends_on("go-md2man", type="build") depends_on("gpgme") diff --git a/var/spack/repos/builtin/packages/sl/package.py b/var/spack/repos/builtin/packages/sl/package.py index 8061eb601ea5b7..69c57f8390b6a4 100644 --- a/var/spack/repos/builtin/packages/sl/package.py +++ b/var/spack/repos/builtin/packages/sl/package.py @@ -16,6 +16,8 @@ class Sl(MakefilePackage): version("5.02", sha256="1e5996757f879c81f202a18ad8e982195cf51c41727d3fea4af01fdcbbb5563a") + depends_on("c", type="build") # generated + depends_on("ncurses") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/slang/package.py b/var/spack/repos/builtin/packages/slang/package.py index 3da247a8e2dca8..cd21296584bc09 100644 --- a/var/spack/repos/builtin/packages/slang/package.py +++ b/var/spack/repos/builtin/packages/slang/package.py @@ -18,4 +18,6 @@ class Slang(AutotoolsPackage): version("2.3.2", sha256="fc9e3b0fc4f67c3c1f6d43c90c16a5c42d117b8e28457c5b46831b8b5d3ae31a") version("2.3.1", sha256="a810d5da7b0c0c8c335393c6b4f12884be6fa7696d9ca9521ef21316a4e00f9d") + depends_on("c", type="build") # generated + parallel = False diff --git a/var/spack/repos/builtin/packages/slate/package.py b/var/spack/repos/builtin/packages/slate/package.py index de5ec795ebd23c..01393ef5cb4d1b 100644 --- a/var/spack/repos/builtin/packages/slate/package.py +++ b/var/spack/repos/builtin/packages/slate/package.py @@ -26,6 +26,9 @@ class Slate(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("master", branch="master") + version( + "2024.05.31", sha256="9c5d4d6779d8935b6fe41031b46e11ab92102f13c5f684022287c8616661b775" + ) version( "2023.11.05", sha256="d3d925adec137ef4b7d876b2d7d0f8f2ff9d8485fa4125454a42f5da4ac026f3" ) @@ -51,6 +54,10 @@ class Slate(CMakePackage, CudaPackage, ROCmPackage): "2020.10.00", sha256="ff58840cdbae2991d100dfbaf3ef2f133fc2f43fc05f207dc5e38a41137882ab" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + patch("omp.patch", when="@2023.11.05") variant( @@ -82,6 +89,7 @@ class Slate(CMakePackage, CudaPackage, ROCmPackage): for val in ROCmPackage.amdgpu_targets: depends_on("blaspp +rocm amdgpu_target=%s" % val, when="amdgpu_target=%s" % val) depends_on("lapackpp +rocm amdgpu_target=%s" % val, when="amdgpu_target=%s" % val) + depends_on("lapackpp@2024.05.31:", when="@2024.05.31:") depends_on("lapackpp@2023.11.05:", when="@2023.11.05:") depends_on("lapackpp@2023.08.25:", when="@2023.08.25:") depends_on("lapackpp@2022.07.00:", when="@2022.07.00:") @@ -89,8 +97,12 @@ class Slate(CMakePackage, CudaPackage, ROCmPackage): depends_on("lapackpp@2021.04.00:", when="@2021.05.01:") depends_on("lapackpp@2020.10.02", when="@2020.10.00") depends_on("lapackpp@master", when="@master") - depends_on("scalapack", type="test") + depends_on("scalapack", when="@:2022.07.00", type="test") + depends_on("python", type="test") depends_on("hipify-clang", when="@:2021.05.02 +rocm ^hip@5:") + depends_on("comgr", when="+rocm") + depends_on("rocblas", when="+rocm") + depends_on("rocsolver", when="+rocm") requires("%oneapi", when="+sycl", msg="slate+sycl must be compiled with %oneapi") @@ -136,8 +148,8 @@ def cmake_args(self): archs = ";".join(spec.variants["amdgpu_target"].value) config.append("-DCMAKE_HIP_ARCHITECTURES=%s" % archs) - if self.run_tests: - config.append("-DSCALAPACK_LIBRARIES=%s" % spec["scalapack"].libs.joined(";")) + slibs = spec["scalapack"].libs.joined(";") if "scalapack" in spec else "none" + config.append(f"-DSCALAPACK_LIBRARIES={slibs}") return config @run_after("install") @@ -157,23 +169,26 @@ def mpi_launcher(self): commands = ["srun", "mpirun", "mpiexec"] return which(*commands, path=searchpath) or which(*commands) - def test(self): + def test_example(self): + """build and run slate example""" + if self.spec.satisfies("@2020.10.00") or "+mpi" not in self.spec: - print("Skipping: stand-alone tests") - return + raise SkipTest("Package must be installed with +mpi and version @2021.05.01 or later") test_dir = join_path(self.test_suite.current_test_cache_dir, "examples", "build") with working_dir(test_dir, create=True): - cmake_bin = join_path(self.spec["cmake"].prefix.bin, "cmake") - deps = "blaspp lapackpp mpi" + cmake = self.spec["cmake"].command + + # This package must directly depend on all packages listed here. + # Otherwise, it will not work when some packages are external to spack. + deps = "slate blaspp lapackpp mpi" if self.spec.satisfies("+rocm"): - deps += " rocblas hip llvm-amdgpu comgr hsa-rocr-dev rocsolver" + deps += " rocblas hip llvm-amdgpu comgr hsa-rocr-dev rocsolver " prefixes = ";".join([self.spec[x].prefix for x in deps.split()]) - self.run_test(cmake_bin, ["-DCMAKE_PREFIX_PATH=" + prefixes, ".."]) + + cmake("-DCMAKE_PREFIX_PATH=" + prefixes, "..") + make = which("make") make() - test_args = ["-n", "4", "./ex05_blas"] launcher = self.mpi_launcher() - if not launcher: - raise RuntimeError("Cannot run tests due to absence of MPI launcher") - self.run_test(launcher.command, test_args, purpose="SLATE smoke test") - make("clean") + assert launcher is not None, "Cannot run tests due to absence of MPI launcher" + launcher("-n", "4", "./ex05_blas") diff --git a/var/spack/repos/builtin/packages/sleef/package.py b/var/spack/repos/builtin/packages/sleef/package.py index 55854015aa1ee1..02cf199e6299c8 100644 --- a/var/spack/repos/builtin/packages/sleef/package.py +++ b/var/spack/repos/builtin/packages/sleef/package.py @@ -10,7 +10,7 @@ class Sleef(CMakePackage): """SIMD Library for Evaluating Elementary Functions, vectorized libm and DFT.""" homepage = "https://sleef.org" - url = "https://github.com/shibatch/sleef/archive/3.6.tar.gz" + url = "https://github.com/shibatch/sleef/archive/3.6.1.tar.gz" git = "https://github.com/shibatch/sleef.git" maintainers("blapie") @@ -18,7 +18,8 @@ class Sleef(CMakePackage): license("BSL-1.0") version("master", branch="master") - version("3.6", commit="a99491afee2bae0b11e9ffbf3211349f43a5fd10", preferred=True) + version("3.6.1", commit="6ee14bcae5fe92c2ff8b000d5a01102dab08d774", preferred=True) + version("3.6", commit="a99491afee2bae0b11e9ffbf3211349f43a5fd10") version("3.5.1_2020-12-22", commit="e0a003ee838b75d11763aa9c3ef17bf71a725bff") # py-torch@1.8: version("3.5.1", sha256="415ee9b1bcc5816989d3d4d92afd0cd3f9ee89cbd5a33eb008e69751e40438ab") version( @@ -45,6 +46,8 @@ class Sleef(CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + generator("ninja") depends_on("cmake@3.18:", type="build") diff --git a/var/spack/repos/builtin/packages/slepc/package.py b/var/spack/repos/builtin/packages/slepc/package.py index be22b6ce7fa5a4..41c5c6d17bb907 100644 --- a/var/spack/repos/builtin/packages/slepc/package.py +++ b/var/spack/repos/builtin/packages/slepc/package.py @@ -22,6 +22,7 @@ class Slepc(Package, CudaPackage, ROCmPackage): test_requires_compiler = True version("main", branch="main") + version("3.21.0", sha256="782833f0caa6585509a837ccd470265c62a1bb56ba64e54c38bde6c63d92629e") version("3.20.2", sha256="125258c87360e326675238eaeb21ce2fbb3f27f4eeb1c72062043931aea05493") version("3.20.1", sha256="5a36b664895881d3858d0644f56bf7bb922bdab70d732fa11cbf6442fec11806") version("3.20.0", sha256="780c50260a9bc9b72776cb920774800c73832370938f1d48c2ea5c66d31b7380") @@ -57,6 +58,10 @@ class Slepc(Package, CudaPackage, ROCmPackage): version("3.11.1", sha256="4816070d4ecfeea6212c6944cee22dc7b4763df1eaf6ab7847cc5ac5132608fb") version("3.11.0", sha256="bf29043c311fe2c549a25e2b0835095723a3eebc1dff288a233b32913b5762a2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("arpack", default=True, description="Enables Arpack wrappers") variant("blopex", default=False, description="Enables BLOPEX wrappers") variant("hpddm", default=False, description="Enables HPDDM wrappers") @@ -66,7 +71,19 @@ class Slepc(Package, CudaPackage, ROCmPackage): # Cannot mix release and development versions of SLEPc and PETSc: depends_on("petsc@main", when="@main") - for ver in ["3.20", "3.19", "3.18", "3.17", "3.16", "3.15", "3.14", "3.13", "3.12", "3.11"]: + for ver in [ + "3.21", + "3.20", + "3.19", + "3.18", + "3.17", + "3.16", + "3.15", + "3.14", + "3.13", + "3.12", + "3.11", + ]: depends_on(f"petsc@{ver}", when=f"@{ver}") depends_on("petsc+cuda", when="+cuda") depends_on("arpack-ng~mpi", when="+arpack^petsc~mpi~int64") diff --git a/var/spack/repos/builtin/packages/slirp4netns/package.py b/var/spack/repos/builtin/packages/slirp4netns/package.py index 83e97fcc5b3980..b799b7fa102cc4 100644 --- a/var/spack/repos/builtin/packages/slirp4netns/package.py +++ b/var/spack/repos/builtin/packages/slirp4netns/package.py @@ -18,6 +18,8 @@ class Slirp4netns(AutotoolsPackage): version("1.2.0", sha256="b584edde686d3cfbac210cbdb93c4b0ba5d8cc0a6a4d92b9dfc3c5baec99c727") version("1.1.12", sha256="279dfe58a61b9d769f620b6c0552edd93daba75d7761f7c3742ec4d26aaa2962") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/sloccount/package.py b/var/spack/repos/builtin/packages/sloccount/package.py index ace22a2d3d0726..fbd2cd8a00579a 100644 --- a/var/spack/repos/builtin/packages/sloccount/package.py +++ b/var/spack/repos/builtin/packages/sloccount/package.py @@ -19,6 +19,9 @@ class Sloccount(MakefilePackage): version("2.26", sha256="fa7fa2bbf2f627dd2d0fdb958bd8ec4527231254c120a8b4322405d8a4e3d12b") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # md5sum needed at run-time depends_on("coreutils", type=("build", "run")) depends_on("flex", type="build") diff --git a/var/spack/repos/builtin/packages/slurm-drmaa/package.py b/var/spack/repos/builtin/packages/slurm-drmaa/package.py index c240de83291d9c..26c0fecbaefbb5 100644 --- a/var/spack/repos/builtin/packages/slurm-drmaa/package.py +++ b/var/spack/repos/builtin/packages/slurm-drmaa/package.py @@ -26,6 +26,8 @@ class SlurmDrmaa(AutotoolsPackage): version("main", branch="main", submodules=True) version("1.1.2", sha256="5bfe25d501de83729df3c8c8f28535b9da3e99aea7738e259903abd6f1f5c836") + depends_on("c", type="build") # generated + # Remove this patch when it is merged into main: patch( "https://github.com/natefoo/slurm-drmaa/pull/62.patch?full_index=1", diff --git a/var/spack/repos/builtin/packages/slurm/package.py b/var/spack/repos/builtin/packages/slurm/package.py index 058bcf9adac0a9..d3f475af008d78 100644 --- a/var/spack/repos/builtin/packages/slurm/package.py +++ b/var/spack/repos/builtin/packages/slurm/package.py @@ -122,6 +122,8 @@ class Slurm(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + variant("gtk", default=False, description="Enable GTK+ support") variant("mariadb", default=False, description="Use MariaDB instead of MySQL") diff --git a/var/spack/repos/builtin/packages/smalt/package.py b/var/spack/repos/builtin/packages/smalt/package.py index 4890f6d867419a..2a2b9ee11dabef 100644 --- a/var/spack/repos/builtin/packages/smalt/package.py +++ b/var/spack/repos/builtin/packages/smalt/package.py @@ -15,3 +15,5 @@ class Smalt(AutotoolsPackage, SourceforgePackage): license("GPL-3.0-only") version("0.7.6", sha256="89ccdfe471edba3577b43de9ebfdaedb5cd6e26b02bf4000c554253433796b31") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/smartdenovo/package.py b/var/spack/repos/builtin/packages/smartdenovo/package.py index 2a933fdf0c36e3..47206e5170dffa 100644 --- a/var/spack/repos/builtin/packages/smartdenovo/package.py +++ b/var/spack/repos/builtin/packages/smartdenovo/package.py @@ -17,6 +17,8 @@ class Smartdenovo(MakefilePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("sse2neon", when="target=aarch64:") patch( diff --git a/var/spack/repos/builtin/packages/smartmontools/package.py b/var/spack/repos/builtin/packages/smartmontools/package.py index a8fa3cde213d3c..7edcb317f381dd 100644 --- a/var/spack/repos/builtin/packages/smartmontools/package.py +++ b/var/spack/repos/builtin/packages/smartmontools/package.py @@ -16,6 +16,9 @@ class Smartmontools(AutotoolsPackage): version("6.6", sha256="51f43d0fb064fccaf823bbe68cf0d317d0895ff895aa353b3339a3b316a53054") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def setup_run_environment(self, env): env.prepend_path("PATH", self.prefix.sbin) env.prepend_path("LD_LIBRARY_PATH", self.prefix.usr.lib) diff --git a/var/spack/repos/builtin/packages/smproxy/package.py b/var/spack/repos/builtin/packages/smproxy/package.py index 1c9d463ea60abb..81d2530895549f 100644 --- a/var/spack/repos/builtin/packages/smproxy/package.py +++ b/var/spack/repos/builtin/packages/smproxy/package.py @@ -16,6 +16,8 @@ class Smproxy(AutotoolsPackage, XorgPackage): version("1.0.7", sha256="aabd5e644512442da2bca1ce65ccee403b760a08e354b3474753ed36033e3d21") version("1.0.6", sha256="a01374763426a5fdcbc7a65edc54e2070cdbca4df41dddd3051c7586e4c814c9") + depends_on("c", type="build") # generated + depends_on("libsm") depends_on("libice") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/snakemake/package.py b/var/spack/repos/builtin/packages/snakemake/package.py index f0f86277316cc7..754affb32d49b6 100644 --- a/var/spack/repos/builtin/packages/snakemake/package.py +++ b/var/spack/repos/builtin/packages/snakemake/package.py @@ -130,5 +130,6 @@ class Snakemake(PythonPackage): ) depends_on("py-requests", when="+http", type=("build", "run")) - def test(self): - Executable("snakemake")("--version") + def test_run(self): + """Test if snakemake runs with the version option""" + Executable(self.prefix.bin.snakemake)("--version") diff --git a/var/spack/repos/builtin/packages/snap-berkeley/package.py b/var/spack/repos/builtin/packages/snap-berkeley/package.py index 03fed202d81a16..4fa5f6a9e01e5a 100644 --- a/var/spack/repos/builtin/packages/snap-berkeley/package.py +++ b/var/spack/repos/builtin/packages/snap-berkeley/package.py @@ -29,6 +29,8 @@ class SnapBerkeley(MakefilePackage): preferred=True, ) + depends_on("cxx", type="build") # generated + depends_on("zlib-api") conflicts("%gcc@6:", when="@:1.0beta.18") diff --git a/var/spack/repos/builtin/packages/snap-korf/package.py b/var/spack/repos/builtin/packages/snap-korf/package.py index 1887b94da563f8..92089ca03eabf0 100644 --- a/var/spack/repos/builtin/packages/snap-korf/package.py +++ b/var/spack/repos/builtin/packages/snap-korf/package.py @@ -21,6 +21,8 @@ class SnapKorf(MakefilePackage): "2013-11-29", sha256="e2a236392d718376356fa743aa49a987aeacd660c6979cee67121e23aeffc66a" ) + depends_on("c", type="build") # generated + depends_on("perl", type=("build", "run")) def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/snap/package.py b/var/spack/repos/builtin/packages/snap/package.py index 1c26c4a03c8a72..7ecaf3af9fbb1c 100644 --- a/var/spack/repos/builtin/packages/snap/package.py +++ b/var/spack/repos/builtin/packages/snap/package.py @@ -23,6 +23,10 @@ class Snap(MakefilePackage): version("master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=False, description="Build with OpenMP support") variant("opt", default=True, description="Build with debugging") variant("mpi", default=True, description="Build with MPI support") diff --git a/var/spack/repos/builtin/packages/snappy/package.py b/var/spack/repos/builtin/packages/snappy/package.py index 796ea1af8493ed..cae3472c411f0e 100644 --- a/var/spack/repos/builtin/packages/snappy/package.py +++ b/var/spack/repos/builtin/packages/snappy/package.py @@ -19,6 +19,8 @@ class Snappy(CMakePackage): version("1.1.8", sha256="16b677f07832a612b0836178db7f374e414f94657c138e6993cbfc5dcc58651f") version("1.1.7", sha256="3dfa02e873ff51a11ee02b9ca391807f0c8ea0529a4924afa645fbf97163f9d4") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("pic", default=True, description="Build position independent code") diff --git a/var/spack/repos/builtin/packages/snbone/package.py b/var/spack/repos/builtin/packages/snbone/package.py index 3671cda0640999..f01017d4f5e622 100644 --- a/var/spack/repos/builtin/packages/snbone/package.py +++ b/var/spack/repos/builtin/packages/snbone/package.py @@ -16,6 +16,9 @@ class Snbone(MakefilePackage): version("develop") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + tags = ["proxy-app"] depends_on("metis") diff --git a/var/spack/repos/builtin/packages/sniffles/package.py b/var/spack/repos/builtin/packages/sniffles/package.py index 2c8e4d65c536a6..c9033e53f76202 100644 --- a/var/spack/repos/builtin/packages/sniffles/package.py +++ b/var/spack/repos/builtin/packages/sniffles/package.py @@ -17,6 +17,9 @@ class Sniffles(CMakePackage): version("1.0.7", sha256="03fa703873bdf9c32055c584448e1eece45f94b4bc68e60c9624cf3841e6d8a9") version("1.0.5", sha256="386c6536bdaa4637579e235bac48444c08297337c490652d1e165accd34b258f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api", type="link") depends_on("bamtools", type="link") diff --git a/var/spack/repos/builtin/packages/snptest/package.py b/var/spack/repos/builtin/packages/snptest/package.py index 1795b605e7f718..8146c3558c1d7f 100644 --- a/var/spack/repos/builtin/packages/snptest/package.py +++ b/var/spack/repos/builtin/packages/snptest/package.py @@ -13,8 +13,9 @@ class Snptest(Package): homepage = "https://mathgen.stats.ox.ac.uk/genetics_software/snptest/snptest.html" url = "https://www.well.ox.ac.uk/~gav/resources/snptest_v2.5.2_linux_x86_64_dynamic.tgz" + version("2.5.6", sha256="22582e49f4a16edf52fe44e8f5e6f3479871658ec1be6341275f6f15d9cbd301") version("2.5.2", sha256="1ffa3ebafa2c5db4866a38e01bb09f43df7973d053423ce67221cb3f8acb30f6") def install(self, spec, prefix): mkdirp(prefix.bin) - install("snptest_v{0}".format(self.version), prefix.bin) + install(f"snptest_v{self.version}", prefix.bin) diff --git a/var/spack/repos/builtin/packages/soapdenovo-trans/package.py b/var/spack/repos/builtin/packages/soapdenovo-trans/package.py index b57bc0e2cd8a66..33c7d269d3ce65 100644 --- a/var/spack/repos/builtin/packages/soapdenovo-trans/package.py +++ b/var/spack/repos/builtin/packages/soapdenovo-trans/package.py @@ -20,6 +20,8 @@ class SoapdenovoTrans(MakefilePackage): version("1.0.5", sha256="c1903c0d81142270db95916e2833400f72c4841b5c9194f182c19ebda418936f") version("1.0.4", sha256="378a54cde0ebe240fb515ba67197c053cf95393645c1ae1399b3a611be2a9795") + depends_on("c", type="build") # generated + depends_on("zlib-api", type="link") depends_on("samtools@0.1.8", type="link", when="target=aarch64:") diff --git a/var/spack/repos/builtin/packages/soapdenovo2/package.py b/var/spack/repos/builtin/packages/soapdenovo2/package.py index 201506ba90c071..364f0b261078c9 100644 --- a/var/spack/repos/builtin/packages/soapdenovo2/package.py +++ b/var/spack/repos/builtin/packages/soapdenovo2/package.py @@ -24,6 +24,9 @@ class Soapdenovo2(MakefilePackage): version("242", sha256="a0043ceb41bc17a1c3fd2b8abe4f9029a60ad3edceb2b15af3c2cfabd36aa11b") version("240", sha256="cc9e9f216072c0bbcace5efdead947e1c3f41f09baec5508c7b90f933a090909") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def flag_handler(self, name, flags): if name.lower() == "cflags" and self.spec.satisfies("%gcc@10:"): flags.append("-fcommon") diff --git a/var/spack/repos/builtin/packages/socat/package.py b/var/spack/repos/builtin/packages/socat/package.py index 6b19b479a613e8..1d6873fa9b6039 100644 --- a/var/spack/repos/builtin/packages/socat/package.py +++ b/var/spack/repos/builtin/packages/socat/package.py @@ -24,6 +24,8 @@ class Socat(AutotoolsPackage): version("1.7.4.4", sha256="fbd42bd2f0e54a3af6d01bdf15385384ab82dbc0e4f1a5e153b3e0be1b6380ac") + depends_on("c", type="build") # generated + depends_on("openssl") depends_on("readline") depends_on("ncurses") diff --git a/var/spack/repos/builtin/packages/soci/package.py b/var/spack/repos/builtin/packages/soci/package.py index ef165f41953dff..a6506b78d2453a 100644 --- a/var/spack/repos/builtin/packages/soci/package.py +++ b/var/spack/repos/builtin/packages/soci/package.py @@ -27,6 +27,8 @@ class Soci(CMakePackage): url="https://github.com/SOCI/soci/archive/3.2.2.tar.gz", ) + depends_on("cxx", type="build") # generated + variant( "cxxstd", default=11, diff --git a/var/spack/repos/builtin/packages/sofa-c/package.py b/var/spack/repos/builtin/packages/sofa-c/package.py index 758b5c3583e157..7269cf13b6a5ad 100644 --- a/var/spack/repos/builtin/packages/sofa-c/package.py +++ b/var/spack/repos/builtin/packages/sofa-c/package.py @@ -14,6 +14,8 @@ class SofaC(MakefilePackage): version("20180130", sha256="de09807198c977e1c58ea1d0c79c40bdafef84f2072eab586a7ac246334796db") + depends_on("c", type="build") # generated + @property def build_directory(self): return join_path(self.version, "c", "src") diff --git a/var/spack/repos/builtin/packages/sollve/package.py b/var/spack/repos/builtin/packages/sollve/package.py index 3cb3e5cd7eb8a4..fcfe622eed3b01 100644 --- a/var/spack/repos/builtin/packages/sollve/package.py +++ b/var/spack/repos/builtin/packages/sollve/package.py @@ -16,8 +16,6 @@ class Sollve(CMakePackage): homepage = "https://www.bnl.gov/compsci/projects/SOLLVE/" git = "https://github.com/SOLLVE/llvm.git" - family = "compiler" # Used by lmod - # NOTE: The debug version of LLVM is an order of magnitude larger than # the release version, and may take up 20-30 GB of space. If you want # to save space, build with `build_type=Release`. diff --git a/var/spack/repos/builtin/packages/sollya/package.py b/var/spack/repos/builtin/packages/sollya/package.py index f146d78900554a..5e1af4fdde51ca 100644 --- a/var/spack/repos/builtin/packages/sollya/package.py +++ b/var/spack/repos/builtin/packages/sollya/package.py @@ -19,6 +19,9 @@ class Sollya(AutotoolsPackage): version("7.0", sha256="15745871f7dd3e96e12915098dd6df2078b815853a38143b2bc6c01477044984") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gmp") depends_on("mpfi") depends_on("mpfr") diff --git a/var/spack/repos/builtin/packages/solr/package.py b/var/spack/repos/builtin/packages/solr/package.py index 5b7ff248e79598..0a14f666a3dc28 100644 --- a/var/spack/repos/builtin/packages/solr/package.py +++ b/var/spack/repos/builtin/packages/solr/package.py @@ -21,6 +21,7 @@ class Solr(Package): license("CC-BY-2.5") + version("8.11.3", sha256="178300ae095094c2060a1060cf475aa935f1202addfb5bacb38e8712ccb56455") version("8.11.2", sha256="54d6ebd392942f0798a60d50a910e26794b2c344ee97c2d9b50e678a7066d3a6") version("8.6.0", sha256="4519ccdb531619df770f1065db6adcedc052c7aa94b42806d541966550956aa5") version("8.5.2", sha256="c457d6c7243241cad141e1df34c6f669d58a6c60e537f4217d032616dd066dcf") diff --git a/var/spack/repos/builtin/packages/somatic-sniper/package.py b/var/spack/repos/builtin/packages/somatic-sniper/package.py index da9be147fa448b..cda1c6eb788151 100644 --- a/var/spack/repos/builtin/packages/somatic-sniper/package.py +++ b/var/spack/repos/builtin/packages/somatic-sniper/package.py @@ -16,6 +16,9 @@ class SomaticSniper(CMakePackage): version("1.0.5.0", sha256="fc41e90237b059fcc591e404830c4b1be678642dd5afd76ce545b97b4b7b3de1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("ncurses") parallel = False diff --git a/var/spack/repos/builtin/packages/sombrero/package.py b/var/spack/repos/builtin/packages/sombrero/package.py index 4fcde4280dc817..5e900524f3cc16 100644 --- a/var/spack/repos/builtin/packages/sombrero/package.py +++ b/var/spack/repos/builtin/packages/sombrero/package.py @@ -36,6 +36,8 @@ class Sombrero(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("mpi") maintainers("mmesiti", "edbennett") diff --git a/var/spack/repos/builtin/packages/sonlib/package.py b/var/spack/repos/builtin/packages/sonlib/package.py index 7c31f41883bde3..eaacf8e9429a95 100644 --- a/var/spack/repos/builtin/packages/sonlib/package.py +++ b/var/spack/repos/builtin/packages/sonlib/package.py @@ -26,6 +26,9 @@ class Sonlib(MakefilePackage): version("master", branch="master") version("2020-04-01", commit="7ebe2ede05a6ee366d93a7a993db69a99943a68f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def setup_build_environment(self, env): binpath = os.path.join(self.stage.source_path, "bin") libpath = os.path.join(self.stage.source_path, "lib") diff --git a/var/spack/repos/builtin/packages/sortmerna/package.py b/var/spack/repos/builtin/packages/sortmerna/package.py index 11213ac876187d..f174b2cb4783da 100644 --- a/var/spack/repos/builtin/packages/sortmerna/package.py +++ b/var/spack/repos/builtin/packages/sortmerna/package.py @@ -17,6 +17,9 @@ class Sortmerna(CMakePackage): version("2017-07-13", commit="8bde6fa113a5d99a23ae81b48eeea6760e966094") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("sse2neon", when="target=aarch64:") diff --git a/var/spack/repos/builtin/packages/sos/package.py b/var/spack/repos/builtin/packages/sos/package.py index fc3465624bf881..8deba7e875c3f1 100644 --- a/var/spack/repos/builtin/packages/sos/package.py +++ b/var/spack/repos/builtin/packages/sos/package.py @@ -15,7 +15,7 @@ class Sos(AutotoolsPackage): # notify when the package is updated. maintainers("rscohn2") - license("GPL-2.0-or-later") + license("BSD-3-Clause") version("1.5.2", sha256="c9df8c6ab43890e5d8970467c188ae2fad736845875ca4c370ff047dbb37d017") version("1.5.1", sha256="0a6303dcbdd713ef2d83c617c1eb821227603c98cb9816c53585fd993da8a984") @@ -24,12 +24,47 @@ class Sos(AutotoolsPackage): variant("xpmem", default=False, description="Enable xpmem for transport") variant("ofi", default=True, description="Enable ofi for transport") + variant( + "manual-progress", + default=False, + description="Enable intermittent progress calls in transport layer", + ) + variant( + "ofi-manual-progress", + default=False, + when="+ofi", + description="Use FI_MANUAL_PROGRESS for data progress control mode", + ) variant("shr-atomics", default=False, description="Enable shared memory atomic operations") + variant( + "av-map", + default=False, + description="Enable av-map instead of av-table in the OFI transport", + ) + variant( + "completion-polling", + default=False, + description="Enable polling in quiet, fence, and local completion operations", + ) + variant( + "thread-completion", + default=False, + description="Support SHMEM_THREAD_MULTIPLE in OFI transport using FI_THREAD_COMPLETION", + ) + variant("error-checking", default=False, description="Enable error checking for SHMEM calls") + variant( + "lengthy-tests", + default=False, + description="Execute long running tests as part of 'make check'", + ) + variant("rpath", default=True, description="Use rpath in compiler wrappers ") + variant("hard-polling", default=False, description="Enable hard polling of wait calls") depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") depends_on("m4", type="build") + depends_on("hydra", type=("build", "run"), when="+ofi") depends_on("libfabric", type="link", when="+ofi") depends_on("xpmem", type="link", when="+xpmem") @@ -39,8 +74,6 @@ class Sos(AutotoolsPackage): filter_compiler_wrappers("oshcc", "oshc++", "oshcc", "oshfort", relative_root="bin") def setup_dependent_build_environment(self, env, dependent_spec): - self.setup_compiler_environment(env) - # Enable the osh wrappers to use spack wrappers when inside spack # with env variables env.set("SHMEM_CC", spack_cc) @@ -57,5 +90,14 @@ def configure_args(self): args.extend(self.with_or_without("ofi")) # This option is not compatiable with remote atomics args.extend(self.enable_or_disable("shr-atomics")) + args.extend(self.enable_or_disable("av-map")) + args.extend(self.enable_or_disable("completion-polling")) + args.extend(self.enable_or_disable("thread-completion")) + args.extend(self.enable_or_disable("error-checking")) + args.extend(self.enable_or_disable("lengthy-tests")) + args.extend(self.enable_or_disable("rpath")) + args.extend(self.enable_or_disable("manual-progress")) + args.extend(self.enable_or_disable("ofi-manual-progress")) + args.extend(self.enable_or_disable("hard-polling")) args.append("--enable-pmi-simple") return args diff --git a/var/spack/repos/builtin/packages/sosflow/package.py b/var/spack/repos/builtin/packages/sosflow/package.py index 0551a3bd6aab96..709d1374a6abc5 100644 --- a/var/spack/repos/builtin/packages/sosflow/package.py +++ b/var/spack/repos/builtin/packages/sosflow/package.py @@ -16,6 +16,9 @@ class Sosflow(CMakePackage): version("spack", tag="spack-build-v0.9901", commit="57c77f18af88b01615d5900124f9cfd1770c8241") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libevpath") depends_on("sqlite@3:") depends_on("pkgconfig") diff --git a/var/spack/repos/builtin/packages/source-highlight/package.py b/var/spack/repos/builtin/packages/source-highlight/package.py index c4fdf0f0c294e9..8ac6ef672fc107 100644 --- a/var/spack/repos/builtin/packages/source-highlight/package.py +++ b/var/spack/repos/builtin/packages/source-highlight/package.py @@ -22,6 +22,9 @@ class SourceHighlight(AutotoolsPackage, GNUMirrorPackage): version("3.1.9", sha256="3a7fd28378cb5416f8de2c9e77196ec915145d44e30ff4e0ee8beb3fe6211c91") version("3.1.8", sha256="01336a7ea1d1ccc374201f7b81ffa94d0aecb33afc7d6903ebf9fbf33a55ada3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch( "https://git.savannah.gnu.org/cgit/src-highlite.git/" + "patch/lib?id=904949c9026cb772dc93fbe0947a252ef47127f4", diff --git a/var/spack/repos/builtin/packages/sowing/package.py b/var/spack/repos/builtin/packages/sowing/package.py index d4f4b32edad961..e0428b7e7323d5 100644 --- a/var/spack/repos/builtin/packages/sowing/package.py +++ b/var/spack/repos/builtin/packages/sowing/package.py @@ -17,10 +17,15 @@ class Sowing(AutotoolsPackage): git = "https://bitbucket.org/petsc/pkg-sowing" maintainers("balay") + version("master", branch="master") version("1.1.26-p8", sha256="2ef4d6db2075230247306e3d0194ffb3e4591aeb05bd244647c72dc1a4e52994") version("1.1.26-p1", sha256="fa0bd07295e5d768f2c33c8ab32205cc6411d42cb40bde0700fb57f9ee31c3d9") version("1.1.25-p1", sha256="c3a5bb170fffeeb1405ec4c3a048744a528d2bef24de29b6ac5e970cfeaddab5") version("1.1.23-p1", sha256="3e36f59e06fccbbf7b78d185c5654edaf70cf76f1c584bcbf08c39d7f29125e8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + def build(self, spec, prefix): make("ALL", parallel=False) diff --git a/var/spack/repos/builtin/packages/sox/package.py b/var/spack/repos/builtin/packages/sox/package.py index f3f74d329970be..a4e6887449b474 100644 --- a/var/spack/repos/builtin/packages/sox/package.py +++ b/var/spack/repos/builtin/packages/sox/package.py @@ -14,6 +14,8 @@ class Sox(AutotoolsPackage): version("14.4.2", sha256="81a6956d4330e75b5827316e44ae381e6f1e8928003c6aa45896da9041ea149c") + depends_on("c", type="build") # generated + variant("mp3", default=False, description="Build with mp3 support") depends_on("bzip2") diff --git a/var/spack/repos/builtin/packages/sp/package.py b/var/spack/repos/builtin/packages/sp/package.py index ca081bf5542f1f..ad490236b8c2a2 100644 --- a/var/spack/repos/builtin/packages/sp/package.py +++ b/var/spack/repos/builtin/packages/sp/package.py @@ -22,6 +22,8 @@ class Sp(CMakePackage): version("2.4.0", sha256="dbb4280e622d2683b68a28f8e3837744adf9bbbb1e7940856e8f4597f481c708") version("2.3.3", sha256="c0d465209e599de3c0193e65671e290e9f422f659f1da928505489a3edeab99f") + depends_on("fortran", type="build") # generated + variant("shared", default=False, description="Build shared library", when="@2.4:") variant("openmp", default=False, description="Use OpenMP threading") variant("pic", default=False, description="Enable position-independent code (PIC)") diff --git a/var/spack/repos/builtin/packages/spaceranger/package.py b/var/spack/repos/builtin/packages/spaceranger/package.py new file mode 100644 index 00000000000000..9b02fc09423f1a --- /dev/null +++ b/var/spack/repos/builtin/packages/spaceranger/package.py @@ -0,0 +1,38 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + + +class Spaceranger(Package): + """Space Ranger is a set of analysis pipelines that process Visium data with brightfield + and fluorescence microscope images. Space Ranger allows users to map the whole + transcriptome in formalin fixed paraffin embedded (FFPE) and fresh frozen (FF) tissues. + + This package requires the user to accept a license and to download the tarball manually. + Once downloaded, the file should be placed within a manual mirror or within the current + directory. For instructions on making a manual mirror, see + https://spack.readthedocs.io/en/latest/mirrors.html""" + + homepage = "https://www.10xgenomics.com/support/software/space-ranger/latest" + manual_download = True + license_url = "support.10xgenomics.com/license" + + version("2.1.1", sha256="e3c2982ae91afc4031f7b29e4b27ea012243e1c61ca8fa246b8c1f6ef7c7c241") + + # spaceranger is distributed as precompiled binaries that are not compatible with + # processors without the avx instruction set ... + # https://www.10xgenomics.com/support/software/space-ranger/downloads/space-ranger-system-requirements + conflicts("target=:k10") # last AMD processor not to support avx + conflicts("target=:westmere") # last Intel processor not to support avx + conflicts("target=:x86_64_v2") # last generic architecture not to support avx + + def url_for_version(self, version): + return "file://{0}/spaceranger-{1}.tar.gz".format(os.getcwd(), version) + + def install(self, spec, prefix): + install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/spack/package.py b/var/spack/repos/builtin/packages/spack/package.py index 2be50b2314c9c4..ca4d8b7e6ba152 100644 --- a/var/spack/repos/builtin/packages/spack/package.py +++ b/var/spack/repos/builtin/packages/spack/package.py @@ -42,6 +42,10 @@ class Spack(Package): version("0.16.1", sha256="8d893036b24d9ee0feee41ac33dd66e4fc68d392918f346f8a7a36a69c567567") version("0.16.0", sha256="064b2532c70916c7684d4c7c973416ac32dd2ea15f5c392654c75258bfc8c6c2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("development_tools", default=False, description="Build development dependencies") variant( "fetchers", @@ -115,7 +119,6 @@ class Spack(Package): depends_on("binutils", type="run", when="@:0.20") depends_on("gnupg", type="run") depends_on("patchelf", type="run", when="platform=linux") - depends_on("patchelf", type="run", when="platform=cray") # See https://github.com/spack/spack/pull/24686 # and #25595, #25726, #25853, #25923, #25924 upstream in python/cpython diff --git a/var/spack/repos/builtin/packages/spades/package.py b/var/spack/repos/builtin/packages/spades/package.py index d5cbb114392c64..7ce989fb6b5374 100644 --- a/var/spack/repos/builtin/packages/spades/package.py +++ b/var/spack/repos/builtin/packages/spades/package.py @@ -12,7 +12,9 @@ class Spades(CMakePackage): homepage = "https://cab.spbu.ru/software/spades/" url = "https://github.com/ablab/spades/releases/download/v3.15.3/SPAdes-3.15.3.tar.gz" + maintainers("snehring") + version("4.0.0", sha256="07c02eb1d9d90f611ac73bdd30ddc242ed51b00c8a3757189e8a8137ad8cfb8b") version("3.15.5", sha256="155c3640d571f2e7b19a05031d1fd0d19bd82df785d38870fb93bd241b12bbfa") version("3.15.3", sha256="b2e5a9fd7a65aee5ab886222d6af4f7b7bc7f755da7a03941571fabd6b9e1499") version("3.15.0", sha256="6719489fa4bed6dd96d78bdd4001a30806d5469170289085836711d1ffb8b28b") @@ -22,13 +24,25 @@ class Spades(CMakePackage): version("3.11.1", sha256="3ab85d86bf7d595bd8adf11c971f5d258bbbd2574b7c1703b16d6639a725b474") version("3.10.1", sha256="d49dd9eb947767a14a9896072a1bce107fb8bf39ed64133a9e2f24fb1f240d96") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python", type=("build", "run")) depends_on("zlib-api") depends_on("bzip2") + variant("sra", default=True, description="Build with ncbi sra file support", when="@4:") + variant("tools", default=True, description="Build additional tools", when="@4:") + # SPAdes will explicitly not compile with gcc < 5.3.0 conflicts("%gcc@:5.2.9") conflicts("%gcc@7.1.0:", when="@:3.10.1") root_cmakelists_dir = "src" + + def cmake_args(self): + args = [self.define_from_variant("SPADES_USE_NCBISDK", "sra")] + if self.spec.satisfies("+tools"): + args.append("-DSPADES_ENABLE_PROJECTS:STRING=all") + return args diff --git a/var/spack/repos/builtin/packages/span-lite/package.py b/var/spack/repos/builtin/packages/span-lite/package.py index 0ea94646d69362..f256873a2ba2f0 100644 --- a/var/spack/repos/builtin/packages/span-lite/package.py +++ b/var/spack/repos/builtin/packages/span-lite/package.py @@ -20,6 +20,7 @@ class SpanLite(CMakePackage): license("BSL-1.0") + version("0.11.0", sha256="ef4e028e18ff21044da4b4641ca1bc8a2e2d656e2028322876c0e1b9b6904f9d") version("0.10.3", sha256="04ac8148760369f11d4cdbc7969d66cb3d372357b6b5c7744841a60551ccb50b") version("0.9.2", sha256="7562802aac9b78e0140c3d59933cf4dc5825c0712c63daad2f7fff8c67e62eb4") version("0.8.1", sha256="2136dba54988c16b03f7c652ea977205bf624bfde90c24331177027d6529386d") @@ -30,10 +31,12 @@ class SpanLite(CMakePackage): version("0.2.0", sha256="6e3305fe868442410a00962a39fc59ed494cecc4f99fe2aff187e33932f06e46") version("0.1.0", sha256="0a84b9369f86beba326e2160b683fd0922f416ce136437751a9ed70afcc67a1c") + depends_on("cxx", type="build") # generated + def cmake_args(self): return [ "-DSPAN_LITE_EXPORT_PACKAGE=ON", - "-DSPAN_LITE_OPT_BUILD_TESTS=%s" % ("ON" if self.run_tests else "OFF"), + f"-DSPAN_LITE_OPT_BUILD_TESTS={'ON' if self.run_tests else 'OFF'}", "-DSPAN_LITE_OPT_BUILD_EXAMPLES=OFF", ] diff --git a/var/spack/repos/builtin/packages/spark/package.py b/var/spack/repos/builtin/packages/spark/package.py index faf15b8398c4d4..46e3551604778e 100644 --- a/var/spack/repos/builtin/packages/spark/package.py +++ b/var/spack/repos/builtin/packages/spark/package.py @@ -16,6 +16,8 @@ class Spark(Package): homepage = "https://spark.apache.org" url = "https://archive.apache.org/dist/spark/spark-2.0.0/spark-2.0.0-bin-without-hadoop.tgz" + maintainers("teaguesterling") + variant("hadoop", default=False, description="Build with Hadoop") depends_on("java", type=("build", "run")) @@ -23,6 +25,10 @@ class Spark(Package): license("Apache-2.0") + version("3.5.1", sha256="5548c02625676fa97cb6b8072f131ed0b860a09d1e86be4e025d0cbfa869bc4a") + version("3.4.3", sha256="85caa74671d46640a2ecccc5248ef673842b507b9843aeebccd6891721b6673f") + version("3.3.4", sha256="793205ff45ce2cb4d91bb2c2724c14fb2a2a49754b93f36c60c4f47e100c2b10") + version("3.2.4", sha256="9a824ad6d73797d602027d650f515d8b68269ffa52a64ff15cfedf10d85fe049") version("3.1.1", sha256="2d16f527016993e69a7c801233e661a170e3099ae2d9b950f7457729d63062f4") version("3.0.2", sha256="1a904f9bfa44a1218cb440c99800dd2ae729249a73c63b3bb10e431ed5b58406") version("3.0.1", sha256="ddda310ac09e3f2da9c33ad278b1665fbad2411d8da127d0de86b90019e962dc") diff --git a/var/spack/repos/builtin/packages/sparrow/package.py b/var/spack/repos/builtin/packages/sparrow/package.py index 249d8e12fb78d1..0abf013b726b80 100644 --- a/var/spack/repos/builtin/packages/sparrow/package.py +++ b/var/spack/repos/builtin/packages/sparrow/package.py @@ -35,6 +35,8 @@ class Sparrow(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + resource( name="dev", url="https://github.com/qcscine/development-utils/archive/refs/tags/4.0.0.tar.gz", diff --git a/var/spack/repos/builtin/packages/sparse/package.py b/var/spack/repos/builtin/packages/sparse/package.py index c1d7313076b65c..5221b3a4463aa5 100644 --- a/var/spack/repos/builtin/packages/sparse/package.py +++ b/var/spack/repos/builtin/packages/sparse/package.py @@ -19,6 +19,8 @@ class Sparse(MakefilePackage): version("1.4b", sha256="63e6646244fd8f4d89f7f70fbf4cfd46b7688d21b22840a0ce57d294a7496d28") + depends_on("c", type="build") # generated + variant("pic", default=True, description="Build with position independent code") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/sparsehash/package.py b/var/spack/repos/builtin/packages/sparsehash/package.py index 77559709326968..1be4970216f084 100644 --- a/var/spack/repos/builtin/packages/sparsehash/package.py +++ b/var/spack/repos/builtin/packages/sparsehash/package.py @@ -16,3 +16,6 @@ class Sparsehash(AutotoolsPackage): version("2.0.4", sha256="8cd1a95827dfd8270927894eb77f62b4087735cbede953884647f16c521c7e58") version("2.0.3", sha256="05e986a5c7327796dad742182b2d10805a8d4f511ad090da0490f146c1ff7a8c") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/sparskit/package.py b/var/spack/repos/builtin/packages/sparskit/package.py index 67d3741712e88f..5792c22417738c 100644 --- a/var/spack/repos/builtin/packages/sparskit/package.py +++ b/var/spack/repos/builtin/packages/sparskit/package.py @@ -24,6 +24,9 @@ class Sparskit(MakefilePackage): url="http://www-users.cs.umn.edu/~saad/software/SPARSKIT/SPARSKIT2.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + # The library uses blas routine which needs to be known when the lib is used. # A dependent package should add self.spec['blas'].libs.ld_flags # at the end of its link line. diff --git a/var/spack/repos/builtin/packages/sparta/package.py b/var/spack/repos/builtin/packages/sparta/package.py index 059779186389cf..4a73b6705bc846 100644 --- a/var/spack/repos/builtin/packages/sparta/package.py +++ b/var/spack/repos/builtin/packages/sparta/package.py @@ -14,6 +14,7 @@ class Sparta(Package): homepage = "https://github.com/atulkakrana/sPARTA.github" url = "https://github.com/atulkakrana/sPARTA/archive/1.25.tar.gz" + version("1.27", sha256="6f66a646bd4ecf14fc4dc1e5729e44a740c205b5f0e0f7771ae22f14b047931e") version("1.25", sha256="007997b9bf5041ae35c9bb79455d533c0f0773f9dd3ba4e5ddf306139625681f") depends_on("bowtie2") diff --git a/var/spack/repos/builtin/packages/spath/package.py b/var/spack/repos/builtin/packages/spath/package.py index 62cac22998c280..037dfff2bc6f1c 100644 --- a/var/spack/repos/builtin/packages/spath/package.py +++ b/var/spack/repos/builtin/packages/spath/package.py @@ -25,6 +25,8 @@ class Spath(CMakePackage): version("0.0.2", sha256="7a65be59c3d27e92ed4718fba1a97a4a1c68e0a552b54de13d58afe3d8199cf7") version("0.0.1", sha256="f41c0ac74e6fb8acfd0c072d756db0fc9c00441f22be492cc4ad25f7fb596a24") + depends_on("c", type="build") # generated + depends_on("zlib-api", type="link", when="@:0.0.2") variant("mpi", default=True, description="Build with MPI support") @@ -41,8 +43,5 @@ def cmake_args(self): if spec.satisfies("@0.1.0:"): args.append(self.define_from_variant("BUILD_SHARED_LIBS", "shared")) - else: - if spec.satisfies("platform=cray"): - args.append(self.define("SPATH_LINK_STATIC", True)) return args diff --git a/var/spack/repos/builtin/packages/spatialdata/package.py b/var/spack/repos/builtin/packages/spatialdata/package.py new file mode 100644 index 00000000000000..38dee9dae61977 --- /dev/null +++ b/var/spack/repos/builtin/packages/spatialdata/package.py @@ -0,0 +1,69 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Spatialdata(AutotoolsPackage): + """SpatialData provides an interface to Proj.4 for converting coordinates + + Spatialdata is a C++ library for + + interpolating values for spatially distributed data, + converting coordinates among geographic projections using Proj, + nondimensionalization of quantities, + specification of units via Pyre (optional). + + This library is used in the finite-element code PyLith + (https://github.com/geodynamics/pylith). The primary focus is specification + of parameters that vary in space, such as values for boundary conditions + and parameters of constitutive models. This provides a specification of + these parameters independent of the discretization.""" + + homepage = "https://geodynamics.org/resources/spatialdata/" + url = "https://github.com/geodynamics/spatialdata/archive/refs/tags/v3.1.0.tar.gz" + git = "https://github.com/geodynamics/spatialdata.git" + + license("MIT", checked_by="downloadico") + + version("develop", branch="develop", submodules="true") + version("3.1.0", sha256="dd6caccbf41a51928183d6a1caf2380aa0ed0f2c8c71ecc9b2cd9e3f23aa418c") + + depends_on("cxx", type="build") # generated + + # M4 macros shared for the CIG codes + resource( + name="autoconf_cig", + git="https://github.com/geodynamics/autoconf_cig.git", + commit="e490e14fb13595428d39055304bcf0ee7ab94806", + ) + + depends_on("autoconf", type="build") + depends_on("automake", type="build") + depends_on("libtool", type="build") + depends_on("m4", type="build") + depends_on("swig", type="build") + + depends_on("python") + depends_on("py-setuptools") + depends_on("py-cig-pythia") + depends_on("proj@6:") + depends_on("py-numpy") + + def autoreconf(self, spec, prefix): + autoupdate("--include=autoconf_cig", "--include=m4") + autoreconf( + "--install", + "--verbose", + "--force", + "--include=autoconf_cig", + "--include=m4", + "--include=" + spec["libtool"].prefix + "/share/aclocal/", + ) + + def configure_args(self): + args = [] + args.append("--enable-swig") + return args diff --git a/var/spack/repos/builtin/packages/spdk/package.py b/var/spack/repos/builtin/packages/spdk/package.py index d4766691db68cd..6c6f71af5f3f98 100644 --- a/var/spack/repos/builtin/packages/spdk/package.py +++ b/var/spack/repos/builtin/packages/spdk/package.py @@ -27,6 +27,9 @@ class Spdk(AutotoolsPackage): "23.01", tag="v23.01", commit="10edc60aa8b5f1b04d6496fea976dec75e276a95", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("crypto", default=False, description="Build vbdev crypto module") variant("dpdk", default=False, description="Build with dpdk") variant("fio", default=False, description="Build fio plugin") diff --git a/var/spack/repos/builtin/packages/spdlog/package.py b/var/spack/repos/builtin/packages/spdlog/package.py index 26e0c987c35694..f812cc1613506f 100644 --- a/var/spack/repos/builtin/packages/spdlog/package.py +++ b/var/spack/repos/builtin/packages/spdlog/package.py @@ -14,6 +14,8 @@ class Spdlog(CMakePackage): license("MIT") + version("1.14.1", sha256="1586508029a7d0670dfcb2d97575dcdc242d3868a259742b69f100801ab4e16b") + version("1.13.0", sha256="534f2ee1a4dcbeb22249856edfb2be76a1cf4f708a20b0ac2ed090ee24cfdbc9") version("1.12.0", sha256="4dccf2d10f410c1e2feaff89966bfc49a1abb29ef6f08246335b110e001e09a9") version("1.11.0", sha256="ca5cae8d6cac15dae0ec63b21d6ad3530070650f68076f3a4a862ca293a858bb") version("1.10.0", sha256="697f91700237dbae2326b90469be32b876b2b44888302afbc7aceb68bcfe8224") @@ -48,10 +50,13 @@ class Spdlog(CMakePackage): version("0.10.0", sha256="fbbc53c1cc09b93b4c3d76b683bbe9315e2efe3727701227374dce6aa4264075") version("0.9.0", sha256="bbbe5a855c8b309621352921d650449eb2f741d35d55ec50fb4d8122ddfb8f01") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries (v1.4.0+)") depends_on("cmake@3.2:", when="@:1.7.0", type="build") depends_on("cmake@3.10:", when="@1.8.0:", type="build") + depends_on("cmake@3.11:", when="@1.13.0:", type="build") depends_on("fmt@5.3:") depends_on("fmt@7:", when="@1.7:") @@ -68,7 +73,7 @@ class Spdlog(CMakePackage): def cmake_args(self): args = [] - if self.spec.version >= Version("1.4.0"): + if self.spec.satisfies("@1.4.0:"): args.extend( [ self.define_from_variant("SPDLOG_BUILD_SHARED", "shared"), diff --git a/var/spack/repos/builtin/packages/specfem3d-globe/package.py b/var/spack/repos/builtin/packages/specfem3d-globe/package.py index 937975855c08c6..2c1bd39c21a744 100644 --- a/var/spack/repos/builtin/packages/specfem3d-globe/package.py +++ b/var/spack/repos/builtin/packages/specfem3d-globe/package.py @@ -19,6 +19,10 @@ class Specfem3dGlobe(AutotoolsPackage, CudaPackage): version("8.0.0", sha256="3e234e66fce4cc5484c651584187b255f951ee6cd1ec057e6aa6d42aced9052d") version("7.0.2", sha256="78b4cfbe4e5121927ab82a8c2e821b65cdfff3e94d017303bf21af7805186d9b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("opencl", default=False, description="Build with OpenCL code generator") variant("openmp", default=True, description="Build with OpenMP code generator") variant("double-precision", default=False, description="Treat REAL as double precision") diff --git a/var/spack/repos/builtin/packages/spectra/package.py b/var/spack/repos/builtin/packages/spectra/package.py index 5288beecfe5b65..66f2dc2e0e0f4b 100644 --- a/var/spack/repos/builtin/packages/spectra/package.py +++ b/var/spack/repos/builtin/packages/spectra/package.py @@ -28,5 +28,8 @@ class Spectra(CMakePackage): version("1.0.0", sha256="45228b7d77b916b5384245eb13aa24bc994f3b0375013a8ba6b85adfd2dafd67") version("0.9.0", sha256="2966757d432e8fba5958c2a05ad5674ce34eaae3718dd546c1ba8760b80b7a3d") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.5:") depends_on("eigen") diff --git a/var/spack/repos/builtin/packages/spectre/package.py b/var/spack/repos/builtin/packages/spectre/package.py index 5a03ccc6c00b10..166292d8243483 100644 --- a/var/spack/repos/builtin/packages/spectre/package.py +++ b/var/spack/repos/builtin/packages/spectre/package.py @@ -31,9 +31,27 @@ class Spectre(CMakePackage): license("MIT") version("develop", branch="develop") + version( + "2024.06.18", sha256="75ca22f3f9d59887b4ae40397fffc0ada9f218cbb23013e86e14deabb30490f7" + ) + version( + "2024.06.05", sha256="7f1dcb5dc067a3977d1720ab655507f52821d898ea1e2b2a82c52dd9e246804f" + ) + version( + "2024.05.11", sha256="be3a91011dd52adfe6f1263a1ee4bf8c51ac95c7d537ad934453997637e5d31a" + ) + version( + "2024.04.12", sha256="2ca46e1c493225e9067546595b1bb234d8634de4974ba87a7b8f011e686b44b6" + ) + version( + "2024.03.19", sha256="42a25c8827b56268d9826239cde521491be19318d83785b35cd0265a9f6a1f7c" + ) version( "2024.02.05", sha256="cf5c4da473d665d0cac0a32562b1b8e8c0f1a77eebca8c3171e52cdf3056fdb3" ) + version( + "2023.12.08", sha256="662b4df6b6cdb097f9edcba869b3e05affeae485de8766ca66bf21399c39a9d8" + ) version( "2023.10.11", sha256="f25d17bc80cc49ebdd81726326701fe9ecd2b6705d86e6e3d48d9e4a458c8aff" ) @@ -110,6 +128,10 @@ class Spectre(CMakePackage): "2021.12.15", sha256="4bfe9e27412e263ffdc6fcfcb84011f16d34a9fdd633ad7fc84a34c898f67e5c" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Configuration variants variant( "executables", @@ -131,7 +153,7 @@ class Spectre(CMakePackage): ), description="Executables to install", ) - variant("python", default=False, description="Build Python bindings") + variant("python", default=True, description="Build Python bindings") variant("doc", default=False, description="Build documentation") # Build type and debug symbols: # - Both Debug and Release builds have debug symbols enabled by default in @@ -153,6 +175,15 @@ class Spectre(CMakePackage): default="system", description="Which memory allocator to use", ) + variant( + "openmp", + default=False, + when="@2024.03.19:", + description=( + "Enable OpenMP parallelization in some parts of the code" + " (Python bindings and exporter)" + ), + ) variant( "formaline", default=True, @@ -166,15 +197,20 @@ class Spectre(CMakePackage): ) # Compiler support + conflicts("%gcc@:8", when="@2022.06.14:") conflicts("%gcc@:6") + conflicts("%clang@:12", when="@2023.10.11:") conflicts("%clang@:7") + conflicts("%apple-clang@:12", when="@2023.10.11:") conflicts("%apple-clang@:10") # Build dependencies + depends_on("cmake@3.18:", when="@2023.02.09:", type="build") depends_on("cmake@3.12:", type="build") depends_on("python@2.7:", type="build") # Link dependencies + depends_on("charmpp@7.0.0:", when="@2022.09.02:") depends_on("charmpp@6.10.2:") depends_on("blaze@3.8") depends_on("boost@1.60:+math+program_options") @@ -183,13 +219,14 @@ class Spectre(CMakePackage): depends_on("hdf5") depends_on("jemalloc", when="memory_allocator=jemalloc") depends_on("libsharp~mpi~openmp") - depends_on("libxsmm@1.16.1:") + depends_on("libxsmm@1.16.1:1") depends_on("blas") depends_on("lapack") depends_on("yaml-cpp@0.6:") # Test dependencies - depends_on("catch2@2.8:", type="test") + depends_on("catch2@3.4.0:3", when="@2023.08.18:", type="test") + depends_on("catch2@2.8:2", when="@:2023.07.29", type="test") depends_on("py-numpy@1.10:", type="test") depends_on("py-scipy", type="test") depends_on("py-h5py", type="test") @@ -197,12 +234,19 @@ class Spectre(CMakePackage): # Python bindings with when("+python"): extends("python") + depends_on("python@3.8:", when="@2023.08.18:", type=("build", "run")) depends_on("python@3.7:", type=("build", "run")) depends_on("py-pybind11@2.6:", type="build") + depends_on("py-click", when="@2022.12.16:", type=("build", "run")) + depends_on("py-h5py@3.5.0:", type=("build", "run")) + depends_on("py-humanize", when="@2023.04.07:", type=("build", "run")) + depends_on("py-jinja2", when="@2023.07.29:", type=("build", "run")) depends_on("py-numpy@1.10:", type=("build", "run")) depends_on("py-scipy", type=("build", "run")) depends_on("py-matplotlib", type=("build", "run")) - depends_on("py-h5py", type=("build", "run")) + depends_on("py-pandas@1.5:1", when="@2023.04.07:", type=("build", "run")) + depends_on("py-pyyaml", type=("build", "run")) + depends_on("py-rich", when="@2022.12.16:", type=("build", "run")) # Docs with when("+doc"): @@ -316,6 +360,7 @@ def cmake_args(self): self.define("USE_GIT_HOOKS", False), self.define("USE_IWYU", False), self.define_from_variant("USE_FORMALINE", "formaline"), + self.define_from_variant("ENABLE_OPENMP", "openmp"), self.define_from_variant("MEMORY_ALLOCATOR").upper(), self.define_from_variant("ENABLE_PROFILING", "profiling"), self.define("USE_PCH", True), diff --git a/var/spack/repos/builtin/packages/spectrum-mpi/package.py b/var/spack/repos/builtin/packages/spectrum-mpi/package.py index ca7a55e599c2a6..eeb878b8768bde 100644 --- a/var/spack/repos/builtin/packages/spectrum-mpi/package.py +++ b/var/spack/repos/builtin/packages/spectrum-mpi/package.py @@ -136,11 +136,11 @@ def setup_dependent_build_environment(self, env, dependent_spec): env.set("MPIF77", os.path.join(self.prefix.bin, "mpif77")) env.set("MPIF90", os.path.join(self.prefix.bin, "mpif90")) - env.set("OMPI_CC", spack_cc) - env.set("OMPI_CXX", spack_cxx) - env.set("OMPI_FC", spack_fc) - env.set("OMPI_F77", spack_f77) - + dependent_module = dependent_spec.package.module + env.set("OMPI_CC", dependent_module.spack_cc) + env.set("OMPI_CXX", dependent_module.spack_cxx) + env.set("OMPI_FC", dependent_module.spack_fc) + env.set("OMPI_F77", dependent_module.spack_f77) env.prepend_path("LD_LIBRARY_PATH", self.prefix.lib) def setup_run_environment(self, env): diff --git a/var/spack/repos/builtin/packages/speex/package.py b/var/spack/repos/builtin/packages/speex/package.py index 63867eca451957..e031643acbb7bb 100644 --- a/var/spack/repos/builtin/packages/speex/package.py +++ b/var/spack/repos/builtin/packages/speex/package.py @@ -17,3 +17,5 @@ class Speex(AutotoolsPackage): version("1.2.1", sha256="4b44d4f2b38a370a2d98a78329fefc56a0cf93d1c1be70029217baae6628feea") version("1.2.0", sha256="eaae8af0ac742dc7d542c9439ac72f1f385ce838392dc849cae4536af9210094") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/speexdsp/package.py b/var/spack/repos/builtin/packages/speexdsp/package.py index 8e5ebd571cc0e6..8d83eb28a5c02a 100644 --- a/var/spack/repos/builtin/packages/speexdsp/package.py +++ b/var/spack/repos/builtin/packages/speexdsp/package.py @@ -17,6 +17,8 @@ class Speexdsp(AutotoolsPackage): version("1.2.1", sha256="d17ca363654556a4ff1d02cc13d9eb1fc5a8642c90b40bd54ce266c3807b91a7") version("1.2.0", sha256="d7032f607e8913c019b190c2bccc36ea73fc36718ee38b5cdfc4e4c0a04ce9a4") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/sperr/package.py b/var/spack/repos/builtin/packages/sperr/package.py index 7b8cc77f4cab18..b8f0543006a920 100644 --- a/var/spack/repos/builtin/packages/sperr/package.py +++ b/var/spack/repos/builtin/packages/sperr/package.py @@ -26,6 +26,9 @@ class Sperr(CMakePackage): version("0.6.2", sha256="d986997e2d79a1f27146ad02c623359976a1e72a1ab0d957e128d430cda3782d") version("0.5", sha256="20ad48c0e7599d3e5866e024d0c49648eb817f72ad5459f5468122cf14a97171") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Variants variant("shared", description="build shared libaries", default=True) variant("openmp", description="use OpenMP in 3D inputs", default=True) diff --git a/var/spack/repos/builtin/packages/spfft/package.py b/var/spack/repos/builtin/packages/spfft/package.py index 79e283f533b41a..391a3868a21def 100644 --- a/var/spack/repos/builtin/packages/spfft/package.py +++ b/var/spack/repos/builtin/packages/spfft/package.py @@ -21,6 +21,7 @@ class Spfft(CMakePackage, CudaPackage, ROCmPackage): version("develop", branch="develop") version("master", branch="master") + version("1.1.0", sha256="231454a3142bc56249b1b551ac5175882311365509cc111d7ad0e91ed5537102") version("1.0.6", sha256="e1b927c61f8abbb4a9937653f917169e6253e8c40b850df491594310943ca14b") version("1.0.5", sha256="2a59d856286ea8559f00a32fc38f9f7546209cfa90112232a5288a69689a6e05") version("1.0.4", sha256="41e63880d95343da0d8c3dbe5bfb3d46a1d612199cc9cc13a936f1628a7fdb8e") @@ -50,8 +51,12 @@ class Spfft(CMakePackage, CudaPackage, ROCmPackage): depends_on("fftw-api@3") depends_on("mpi", when="+mpi") depends_on("cmake@3.11:", type="build") + depends_on("cmake@3.18:", type="build", when="@1.1.0:") + depends_on("cmake@3.21:", type="build", when="@1.1.0: +rocm") - depends_on("cuda@:10", when="@:0.9.11 +cuda") + depends_on("cuda@9:10", when="@:0.9.11 +cuda") + depends_on("cuda@9:", when="@0.9.12:1.0.6 +cuda") + depends_on("cuda@11:", when="@1.1.0: +cuda") # Workaround for compiler bug in ROCm 4.5+ added in SpFFT 1.0.6 conflicts("+rocm", when="@:1.0.5") @@ -59,6 +64,8 @@ class Spfft(CMakePackage, CudaPackage, ROCmPackage): with when("+rocm"): depends_on("rocfft") depends_on("hipfft") + # hip 6.0 requires v1.1.0 and later + conflicts("^hip@6.0.0:", when="@:1.0.6 +rocm") # Fix compilation error in some cases due to missing include statement # before version 1.0.3 @@ -82,7 +89,13 @@ def cmake_args(self): if cuda_arch[0] != "none": args += [self.define("CMAKE_CUDA_ARCHITECTURES", cuda_arch)] - if spec.satisfies("+rocm"): + if spec.satisfies("@1.1.0: +rocm"): + # v1.1.0 switched to CMake HIP language feature + args += ["-DSPFFT_GPU_BACKEND=ROCM"] + rocm_arch = self.spec.variants["amdgpu_target"].value + if rocm_arch[0] != "none": + args += [self.define("CMAKE_HIP_ARCHITECTURES", rocm_arch)] + elif spec.satisfies("+rocm"): archs = ",".join(self.spec.variants["amdgpu_target"].value) args += [ "-DSPFFT_GPU_BACKEND=ROCM", diff --git a/var/spack/repos/builtin/packages/spglib/package.py b/var/spack/repos/builtin/packages/spglib/package.py index 9818f4b3fd5878..7420d3ad75855e 100644 --- a/var/spack/repos/builtin/packages/spglib/package.py +++ b/var/spack/repos/builtin/packages/spglib/package.py @@ -20,6 +20,8 @@ class Spglib(CMakePackage): license("BSD-3-Clause") + version("2.4.0", sha256="e33694b189c6864f719a59c31e2af55301a524fb68ba9fb65f08e95af471847d") + version("2.3.1", sha256="c295dbea7d2fc9e50639aa14331fef277878c35f00ef0766e688bfbb7b17d44c") version("2.3.0", sha256="c05eb869018efe2efe5dcb2654cda19c5dd4c07434874205fa542f7766f7548e") version("2.2.0", sha256="ac929e20ec9d4621411e2cdec59b1442e02506c1e546005bbe2c7f781e9bd49a") version("2.1.0", sha256="31bca273a1bc54e1cff4058eebe7c0a35d5f9b489579e84667d8e005c73dcc13") @@ -51,6 +53,10 @@ class Spglib(CMakePackage): version("1.10.1", sha256="8ed979cda82f6d440567197ec191bffcb82ee83c5bfe8a484c5a008dd00273f0") version("1.10.0", sha256="117fff308731784bea2ddaf3d076f0ecbf3981b31ea1c1bfd5ce4f057a5325b1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=True, description="Build with OpenMP support", when="@1.16.2:") variant("fortran", default=True, description="Build Fortran interface", when="@1.16.4:") variant("tests", default=False, description="Build with tests", when="@2.1.0:") diff --git a/var/spack/repos/builtin/packages/sph2pipe/package.py b/var/spack/repos/builtin/packages/sph2pipe/package.py index 562ac4b553e356..6e61c2cc9d177d 100644 --- a/var/spack/repos/builtin/packages/sph2pipe/package.py +++ b/var/spack/repos/builtin/packages/sph2pipe/package.py @@ -15,4 +15,6 @@ class Sph2pipe(CMakePackage): version("2.5", sha256="5be236dc94ed0a301c5c8a369f849f76799ec7e70f25dfc0521068d9d1d4d3e3") + depends_on("c", type="build") # generated + patch("cmake.patch") diff --git a/var/spack/repos/builtin/packages/spindle/package.py b/var/spack/repos/builtin/packages/spindle/package.py index b1b2e1e526504b..d20ed13e560cdf 100644 --- a/var/spack/repos/builtin/packages/spindle/package.py +++ b/var/spack/repos/builtin/packages/spindle/package.py @@ -19,6 +19,9 @@ class Spindle(AutotoolsPackage): version("0.12", sha256="3fd9d0afefa9072fffdf2cfd80a0b5e557e201a0b0eb02e7379eae65e64eb1f2") version("0.8.1", sha256="c1e099e913faa8199be5811dc7b8be0266f0d1fd65f0a3a25bb46fbc70954ed6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("launchmon") # All versions provide the runtime option --no-mpi to not use MPI, but mpi # is needed for the build: diff --git a/var/spack/repos/builtin/packages/spiner/package.py b/var/spack/repos/builtin/packages/spiner/package.py index 485387254b744f..24e549ce77f4e9 100644 --- a/var/spack/repos/builtin/packages/spiner/package.py +++ b/var/spack/repos/builtin/packages/spiner/package.py @@ -38,6 +38,8 @@ class Spiner(CMakePackage, CudaPackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + # When overriding/overloading varaints, the last variant is always used, except for # "when" clauses. Therefore, call the whens FIRST then the non-whens. # https://spack.readthedocs.io/en/latest/packaging_guide.html#overriding-variants diff --git a/var/spack/repos/builtin/packages/spiral-package-fftx/package.py b/var/spack/repos/builtin/packages/spiral-package-fftx/package.py index 979b705a4d4a38..5ac50c06e60084 100644 --- a/var/spack/repos/builtin/packages/spiral-package-fftx/package.py +++ b/var/spack/repos/builtin/packages/spiral-package-fftx/package.py @@ -30,6 +30,9 @@ class SpiralPackageFftx(Package): version("1.2.1", sha256="3f15aa5949c1b09eb59257cf1c5f6fcddc6e46f77ae9d5fce8acd8b9f99ce941") version("1.1.1", sha256="99ec7fab9274d378524b4933917fae23f9590255518c7a124cb46bd5e8d9af37") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # FFTX package is an extension for Spiral (spec: spiral-software). def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/spiral-software/package.py b/var/spack/repos/builtin/packages/spiral-software/package.py index cc380f8078133c..9d7892fd22a0d2 100644 --- a/var/spack/repos/builtin/packages/spiral-software/package.py +++ b/var/spack/repos/builtin/packages/spiral-software/package.py @@ -26,6 +26,8 @@ class SpiralSoftware(CMakePackage): version("8.4.0", sha256="d0c58de65c678130eeee6b8b8b48061bbe463468990f66d9b452225ce46dee19") version("8.3.0", sha256="41cf0e7f14f9497e98353baa1ef4ca6204ce5ca525db8093f5bb44e89992abdf") + depends_on("c", type="build") # generated + extendable = True # No dependencies. Spiral pacakges are listed here as variants. If a diff --git a/var/spack/repos/builtin/packages/spla/package.py b/var/spack/repos/builtin/packages/spla/package.py index 417b96af573f28..bd81ac3b0add5e 100644 --- a/var/spack/repos/builtin/packages/spla/package.py +++ b/var/spack/repos/builtin/packages/spla/package.py @@ -19,6 +19,8 @@ class Spla(CMakePackage): license("BSD-3-Clause") + version("1.6.1", sha256="62b51e6ce05c41cfc1c6f6600410f9549a209c50f0331e1db41047f94493e02f") + version("1.6.0", sha256="917c24e2a768499967eba47b2cc2475df9fabee327b7821d24970b6a08055c09") version("1.5.5", sha256="bc0c366e228344b1b2df55b9ce750d73c1165380e512da5a04d471db126d66ce") version("1.5.4", sha256="de30e427d24c741e2e4fcae3d7668162056ac2574afed6522c0bb49d6f1d0f79") version("1.5.3", sha256="527c06e316ce46ec87309a16bfa4138b1abad23fd276fe789c78a2de84f05637") @@ -35,7 +37,11 @@ class Spla(CMakePackage): version("develop", branch="develop") version("master", branch="master") - variant("openmp", default=True, description="Build with OpenMP support") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("openmp", default=True, when="@:1.5.5", description="Build with OpenMP support") variant("static", default=False, description="Build as static library") variant("cuda", default=False, description="CUDA backend") variant("rocm", default=False, description="ROCm backend") @@ -51,10 +57,15 @@ class Spla(CMakePackage): depends_on("mpi") depends_on("blas") depends_on("cmake@3.10:", type="build") + depends_on("cmake@3.18:", type="build", when="@1.6.0:") depends_on("cuda", when="+cuda") - depends_on("rocblas", when="+rocm") + depends_on("cuda@11:", when="@1.6.0: +cuda") + depends_on("hip", when="+rocm") + depends_on("rocblas", when="+rocm") + conflicts("^rocblas@6.0.0:", when="@:1.5.5 +rocm") + conflicts("^hip@6.0.0:", when="@:1.6.0 +rocm") # v1.6.1 includes fix for hip 6.0 # Propagate openmp to blas depends_on("openblas threads=openmp", when="+openmp ^[virtuals=blas] openblas") @@ -67,30 +78,36 @@ class Spla(CMakePackage): patch("0001-amd_blis.patch", when="@1.3.0:1.4.0 ^amdblis") def cmake_args(self): + spec = self.spec + args = [ - self.define_from_variant("SPLA_OMP", "openmp"), self.define_from_variant("SPLA_FORTRAN", "fortran"), self.define_from_variant("SPLA_STATIC", "static"), ] - if "+cuda" in self.spec: + if "+cuda" in spec: args += ["-DSPLA_GPU_BACKEND=CUDA"] - elif "+rocm" in self.spec: + elif "+rocm" in spec: args += ["-DSPLA_GPU_BACKEND=ROCM"] else: args += ["-DSPLA_GPU_BACKEND=OFF"] - if self.spec["blas"].name == "openblas": - args += ["-DSPLA_HOST_BLAS=OPENBLAS"] - elif self.spec["blas"].name in ["amdblis", "blis"]: - args += ["-DSPLA_HOST_BLAS=BLIS"] - elif self.spec["blas"].name == "atlas": - args += ["-DSPLA_HOST_BLAS=ATLAS"] - elif self.spec["blas"].name == "intel-mkl": - args += ["-DSPLA_HOST_BLAS=MKL"] - elif self.spec["blas"].name == "netlib-lapack": - args += ["-DSPLA_HOST_BLAS=GENERIC"] - elif self.spec["blas"].name == "cray-libsci": - args += ["-DSPLA_HOST_BLAS=CRAY_LIBSCI"] + # v1.6.0: No longer has custom BLAS detection and only uses the FindBLAS CMake module. + if spec.satisfies("@:1.5.5"): + args += [self.define_from_variant("SPLA_OMP", "openmp")] + if spec["blas"].name == "openblas": + args += ["-DSPLA_HOST_BLAS=OPENBLAS"] + elif spec["blas"].name in ["amdblis", "blis"]: + args += ["-DSPLA_HOST_BLAS=BLIS"] + elif spec["blas"].name == "atlas": + args += ["-DSPLA_HOST_BLAS=ATLAS"] + elif spec["blas"].name == "intel-mkl": + args += ["-DSPLA_HOST_BLAS=MKL"] + elif spec["blas"].name == "netlib-lapack": + args += ["-DSPLA_HOST_BLAS=GENERIC"] + elif spec["blas"].name == "cray-libsci": + args += ["-DSPLA_HOST_BLAS=CRAY_LIBSCI"] + else: + args += [self.define("BLAS_LIBRARIES", spec["blas"].libs.joined(";"))] return args diff --git a/var/spack/repos/builtin/packages/spot/package.py b/var/spack/repos/builtin/packages/spot/package.py index d5aa234e98e554..776e744bdf8b38 100644 --- a/var/spack/repos/builtin/packages/spot/package.py +++ b/var/spack/repos/builtin/packages/spot/package.py @@ -16,12 +16,17 @@ class Spot(AutotoolsPackage): license("MIT") + version("2.12", sha256="26ba076ad57ec73d2fae5482d53e16da95c47822707647e784d8c7cec0d10455") + version("2.11.6", sha256="a692794f89c0db3956ba5919bdd5313e372e0de34000a9022f29e1c6e91c538a") version("2.11.5", sha256="3acfd5cd112d00576ac234baeb34e1c6adf8c03155d4cda973e6317ac8bd1774") version("2.11.4", sha256="91ecac6202819ea1de4534902ce457ec6eec0573d730584d6494d06b0bcaa0b4") version("2.9.4", sha256="e11208323baabe9b5f98098d4b9bb39803fb102a68abbbaf900f1fcd578f0f85") version("1.99.3", sha256="86964af559994af4451a8dca663a9e1db6e869ed60e747ab60ce72dddc31b61b") version("1.2.6", sha256="360678c75f6741f697e8e56cdbc9937f104eb723a839c3629f0dc5dc6de11bfc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("python", default=True, description="Enable python API") depends_on("python@3.3:", when="@1.99.5: +python") diff --git a/var/spack/repos/builtin/packages/sprng/package.py b/var/spack/repos/builtin/packages/sprng/package.py index 4c014a3b8ad10e..44d871a0094d59 100644 --- a/var/spack/repos/builtin/packages/sprng/package.py +++ b/var/spack/repos/builtin/packages/sprng/package.py @@ -22,6 +22,10 @@ class Sprng(AutotoolsPackage): version("5.0", sha256="9172a495472cc24893e7489ce9b5654300dc60cba4430e436ce50d28eb749a66") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") variant("fortran", default=False, description="Enable Fortran support") diff --git a/var/spack/repos/builtin/packages/sqlcipher/package.py b/var/spack/repos/builtin/packages/sqlcipher/package.py index 52887ccff05e37..64de6d7367e477 100644 --- a/var/spack/repos/builtin/packages/sqlcipher/package.py +++ b/var/spack/repos/builtin/packages/sqlcipher/package.py @@ -27,6 +27,9 @@ class Sqlcipher(AutotoolsPackage): version("4.0.0", sha256="c8f5fc6d800aae6107bf23900144804db5510c2676c93fbb269e4a0700837d68") version("3.4.2", sha256="69897a5167f34e8a84c7069f1b283aba88cdfa8ec183165c4a5da2c816cfaadb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("openssl") depends_on("tcl", type=["build"]) depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/sqlite-jdbc/package.py b/var/spack/repos/builtin/packages/sqlite-jdbc/package.py index b39bdea8947d4e..a403288030fd75 100644 --- a/var/spack/repos/builtin/packages/sqlite-jdbc/package.py +++ b/var/spack/repos/builtin/packages/sqlite-jdbc/package.py @@ -18,3 +18,5 @@ class SqliteJdbc(MavenPackage): version("3.32.3.2", sha256="9168ad02cb8b01449271eabd8a2a81461954c2c3fa854d3828a37dc07a1fefec") version("3.32.3.1", sha256="455e2a009101ede40f9510cf2c34e76f30d411f290957bfd9296da12d6e06591") version("3.32.3", sha256="19725caa4742960d385472a6094b8164bb8f29e816f04b830fa65c56517b4564") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/sqlite/package.py b/var/spack/repos/builtin/packages/sqlite/package.py index 09d6f5c1f0a0fc..4b3b3734898ca7 100644 --- a/var/spack/repos/builtin/packages/sqlite/package.py +++ b/var/spack/repos/builtin/packages/sqlite/package.py @@ -23,6 +23,10 @@ class Sqlite(AutotoolsPackage, NMakePackage): license("blessing") + version("3.46.0", sha256="6f8e6a7b335273748816f9b3b62bbdc372a889de8782d7f048c653a447417a7d") + version("3.45.3", sha256="b2809ca53124c19c60f42bf627736eae011afdcc205bb48270a5ee9a38191531") + version("3.45.1", sha256="cd9c27841b7a5932c9897651e20b86c701dd740556989b01ca596fcfa3d49a0a") + version("3.44.2", sha256="1c6719a148bc41cf0f2bbbe3926d7ce3f5ca09d878f1246fcc20767b175bb407") version("3.43.2", sha256="6d422b6f62c4de2ca80d61860e3a3fb693554d2f75bb1aaca743ccc4d6f609f0") version("3.42.0", sha256="7abcfd161c6e2742ca5c6c0895d1f853c940f203304a0b49da4e1eca5d088ca6") version("3.40.1", sha256="2c5dea207fa508d765af1ef620b637dcb06572afa6f01f0815bd5bbf864b33d9") @@ -50,11 +54,13 @@ class Sqlite(AutotoolsPackage, NMakePackage): version("3.27.1", sha256="54a92b8ff73ff6181f89b9b0c08949119b99e8cccef93dbef90e852a8b10f4f8") version("3.27.0", sha256="dbfb0fb4fc32569fa427d3658e888f5e3b84a0952f706ccab1fd7c62a54f10f0") version("3.26.0", sha256="5daa6a3fb7d1e8c767cd59c4ded8da6e4b00c61d3b466d0685e35c4dd6d7bf5d") + + depends_on("c", type="build") # generated # All versions prior to 3.26.0 are vulnerable to Magellan when FTS # is enabled, see https://blade.tencent.com/magellan/index_en.html # no hard readline dep on Windows + no variant support, makefile has minimal to no options - for plat in ["linux", "darwin", "cray", "freebsd"]: + for plat in ["linux", "darwin", "freebsd"]: variant( "column_metadata", default=True, @@ -178,11 +184,13 @@ def query_fts(version): return all_variants def url_for_version(self, version): - full_version = list(version.version) + [0 * (4 - len(version.version))] - version_string = str(full_version[0]) + "".join(["%02d" % v for v in full_version[1:]]) + if len(version) < 3: + raise ValueError(f"Unsupported sqlite version: {version}") # See https://www.sqlite.org/chronology.html for version -> year # correspondence. - if version >= Version("3.41.0"): + if version >= Version("3.45.0"): + year = "2024" + elif version >= Version("3.41.0"): year = "2023" elif version >= Version("3.37.2"): year = "2022" @@ -205,8 +213,8 @@ def url_for_version(self, version): elif version >= Version("3.7.16"): year = "2013" else: - raise ValueError("Unsupported version {0}".format(version)) - return "https://www.sqlite.org/{0}/sqlite-autoconf-{1}.tar.gz".format(year, version_string) + raise ValueError(f"Unsupported sqlite version {version}") + return f"https://www.sqlite.org/{year}/sqlite-autoconf-{version[0]}{version[1]:02}{version[2]:02}00.tar.gz" @property def libs(self): @@ -271,7 +279,7 @@ def build_libsqlitefunctions(self): libraryname = "libsqlitefunctions." + dso_suffix cc = Executable(spack_cc) cc( - self.compiler.cc_pic_flag, + self.pkg.compiler.cc_pic_flag, "-lm", "-shared", "extension-functions.c", diff --git a/var/spack/repos/builtin/packages/sqlitebrowser/package.py b/var/spack/repos/builtin/packages/sqlitebrowser/package.py index 1b23b7f7d436b2..bd5c82f0e5b365 100644 --- a/var/spack/repos/builtin/packages/sqlitebrowser/package.py +++ b/var/spack/repos/builtin/packages/sqlitebrowser/package.py @@ -19,6 +19,9 @@ class Sqlitebrowser(CMakePackage): version("3.12.2", sha256="645f98d38e5d128a449e93cebf03c8070f9eacd2d16b10e433a781d54a9d478a") version("3.10.1", sha256="36eb53bc75192c687dce298c79f1532c410ce4ecbeeacfb07b9d02a307f16bef") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + msg = "sqlitebrowser requires C++11 support" conflicts("%gcc@:4.8.0", msg=msg) conflicts("%apple-clang@:3.9", msg=msg) diff --git a/var/spack/repos/builtin/packages/squashfs-mount/package.py b/var/spack/repos/builtin/packages/squashfs-mount/package.py index b90f3f5a6d1522..e1f9deb2957d7c 100644 --- a/var/spack/repos/builtin/packages/squashfs-mount/package.py +++ b/var/spack/repos/builtin/packages/squashfs-mount/package.py @@ -20,6 +20,8 @@ class SquashfsMount(MakefilePackage): version("0.4.0", sha256="0b17c797b4befdab172fc58a74f3b647bbdf127ff5bdaf7c21d907b7a9714339") version("0.1.0", sha256="37841ede7a7486d437fd06ae13e432560f81806f69addc72cfc8e564c8727bc6") + depends_on("c", type="build") # generated + variant("suid", default=False, description="Make squashfs-mount a suid executable") depends_on("util-linux", type="link") diff --git a/var/spack/repos/builtin/packages/squashfs/package.py b/var/spack/repos/builtin/packages/squashfs/package.py index 73d37fab5b9a93..e53f1b253b7745 100644 --- a/var/spack/repos/builtin/packages/squashfs/package.py +++ b/var/spack/repos/builtin/packages/squashfs/package.py @@ -52,6 +52,8 @@ class Squashfs(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + variant("gzip", default=True, description="Enable gzip compression support") variant("lz4", default=False, description="Enable LZ4 compression support") variant("lzo", default=False, description="Enable LZO compression support") diff --git a/var/spack/repos/builtin/packages/squashfuse/package.py b/var/spack/repos/builtin/packages/squashfuse/package.py index 757332d0785caf..c1e30b0ce07926 100644 --- a/var/spack/repos/builtin/packages/squashfuse/package.py +++ b/var/spack/repos/builtin/packages/squashfuse/package.py @@ -17,6 +17,8 @@ class Squashfuse(AutotoolsPackage): license("BSD-2-Clause") version("master", branch="master") + version("0.5.2", sha256="54e4baaa20796e86a214a1f62bab07c7c361fb7a598375576d585712691178f5") + version("0.5.1", sha256="4dd81ea10323078193e5435ad8481b59f3ac8539648ddc732bcaea50b13966c9") version("0.5.0", sha256="d7602c7a3b1d0512764547d27cb8cc99d1b21181e1c9819e76461ee96c2ab4d9") version("0.4.0", sha256="646e31449b7914d2404933aea88f8d5f72c5d135d7deae3370ccb394c40d114a") version("0.2.0", sha256="e8eea1b013b41d0a320e5a07b131bc70df14e6b3f2d3a849bdee66d100186f4f") @@ -28,6 +30,8 @@ class Squashfuse(AutotoolsPackage): version("0.1.104", sha256="aa52460559e0d0b1753f6b1af5c68cfb777ca5a13913285e93f4f9b7aa894b3a") version("0.1.103", sha256="42d4dfd17ed186745117cfd427023eb81effff3832bab09067823492b6b982e7") + depends_on("c", type="build") # generated + variant("shared", default=True, description="Enable shared libraries") variant("static", default=True, description="Enable static libraries") variant("min_size", default=False, description="Build small binaries") diff --git a/var/spack/repos/builtin/packages/squid/package.py b/var/spack/repos/builtin/packages/squid/package.py index 87b89b53223a73..b54a346e274872 100644 --- a/var/spack/repos/builtin/packages/squid/package.py +++ b/var/spack/repos/builtin/packages/squid/package.py @@ -15,3 +15,5 @@ class Squid(AutotoolsPackage): license("GPL-2.0-or-later") version("1.9g", sha256="302f42e8794aa4dbcfa0996c14fb7a70a7c4397fc45c2bbd2748055460d8dca7") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/sra-tools/package.py b/var/spack/repos/builtin/packages/sra-tools/package.py index 19461f17d42ed0..7ae214e1da9fa0 100644 --- a/var/spack/repos/builtin/packages/sra-tools/package.py +++ b/var/spack/repos/builtin/packages/sra-tools/package.py @@ -16,6 +16,9 @@ class SraTools(CMakePackage): version("3.0.3", tag="3.0.3", commit="01f0aa21bb20b84c68ea34404d43da680811e27a") version("3.0.0", tag="3.0.0", commit="bd2053a1049e64207e75f4395fd1be7f1572a5aa") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("openjdk") depends_on("flex@2.6:") depends_on("libxml2") diff --git a/var/spack/repos/builtin/packages/srcml-identifier-getter-tool/package.py b/var/spack/repos/builtin/packages/srcml-identifier-getter-tool/package.py index 4dcf19637bde9e..ec2225bc84496e 100644 --- a/var/spack/repos/builtin/packages/srcml-identifier-getter-tool/package.py +++ b/var/spack/repos/builtin/packages/srcml-identifier-getter-tool/package.py @@ -16,6 +16,8 @@ class SrcmlIdentifierGetterTool(CMakePackage): version("2022-10-17", commit="01394c247ae6f61cc5864a9697e72e3623d8e7fb", submodules=True) + depends_on("cxx", type="build") # generated + depends_on("libxml2") depends_on("zlib-api") depends_on("lzma") diff --git a/var/spack/repos/builtin/packages/srcml/package.py b/var/spack/repos/builtin/packages/srcml/package.py index ceae7cb7de9fc4..c7030d413b9e8d 100644 --- a/var/spack/repos/builtin/packages/srcml/package.py +++ b/var/spack/repos/builtin/packages/srcml/package.py @@ -23,6 +23,9 @@ class Srcml(CMakePackage): version("1.0.0", sha256="3ddf33271c3b3953d5e3ecbb14c4f925fc0e609a81250d921d3516537dcffae2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.14:", type="build") depends_on("antlr+cxx+java+pic") depends_on("libxslt") diff --git a/var/spack/repos/builtin/packages/sse2neon/package.py b/var/spack/repos/builtin/packages/sse2neon/package.py index 9ac1f23a12a660..4535f5a3dbecbc 100644 --- a/var/spack/repos/builtin/packages/sse2neon/package.py +++ b/var/spack/repos/builtin/packages/sse2neon/package.py @@ -18,10 +18,13 @@ class Sse2neon(Package): license("MIT") version("master", branch="master") + version("1.7.0", sha256="cee6d54922dbc9d4fa57749e3e4b46161b7f435a22e592db9da008051806812a") version("1.6.0", sha256="06f4693219deccb91b457135d836fc514a1c0a57e9fa66b143982901d2d19677") version("1.5.1", sha256="4001e2dfb14fcf3831211581ed83bcc83cf6a3a69f638dcbaa899044a351bb2a") version("1.5.0", sha256="92ab852aac6c8726a615f77438f2aa340f168f9f6e70c72033d678613e97b65a") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.include) install("*.h", prefix.include) diff --git a/var/spack/repos/builtin/packages/sshfs/package.py b/var/spack/repos/builtin/packages/sshfs/package.py index 36dc287f873d5b..ff85c913711733 100644 --- a/var/spack/repos/builtin/packages/sshfs/package.py +++ b/var/spack/repos/builtin/packages/sshfs/package.py @@ -19,6 +19,8 @@ class Sshfs(MesonPackage): version("3.7.1", sha256="fe5d3436d61b46974889e0c4515899c21a9d67851e3793c209989f72353d7750") + depends_on("c", type="build") # generated + depends_on("glib") depends_on("fuse@3.1.0:") diff --git a/var/spack/repos/builtin/packages/sshpass/package.py b/var/spack/repos/builtin/packages/sshpass/package.py index bd8250dc6f6636..989ddcd40dd18e 100644 --- a/var/spack/repos/builtin/packages/sshpass/package.py +++ b/var/spack/repos/builtin/packages/sshpass/package.py @@ -25,6 +25,8 @@ class Sshpass(AutotoolsPackage): version("1.01", sha256="e2adc378d61b72e63b4381fe123de3c63bd4093c9553d3219e83878f379754f4") version("1.00", sha256="71d4be85a464a8ce2ae308bc04dcb342918f3989b6a81c74217b5df7f11471f8") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/ssht/package.py b/var/spack/repos/builtin/packages/ssht/package.py index d71bfab09f05cf..76bb77cfcb6055 100644 --- a/var/spack/repos/builtin/packages/ssht/package.py +++ b/var/spack/repos/builtin/packages/ssht/package.py @@ -34,6 +34,9 @@ class Ssht(CMakePackage): version("1.3.3", sha256="1f3b89e29d89fa79170b9979046a55c81b588d9dd563fd36f37887495b71dd28") version("1.3.2", sha256="6cb3b6f94fb90dff45ba59da30a8ccd9667d8e319bed437f19d2287f59e35dd1") version("1.3.0", sha256="9e2c220a70d662714ff601a121b674c8423866058279e000cbbee532d31dd3c9") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated # version('1.2b1', commit='7378ce8853897cbd1b08adebf7ec088c1e40f860') depends_on("fftw @3.0.0:") diff --git a/var/spack/repos/builtin/packages/ssmtp/package.py b/var/spack/repos/builtin/packages/ssmtp/package.py index 282a35146a915e..24bc2d0bc0ad4e 100644 --- a/var/spack/repos/builtin/packages/ssmtp/package.py +++ b/var/spack/repos/builtin/packages/ssmtp/package.py @@ -17,6 +17,8 @@ class Ssmtp(AutotoolsPackage): version("2.64", sha256="22c37dc90c871e8e052b2cab0ad219d010fa938608cd66b21c8f3c759046fa36") + depends_on("c", type="build") # generated + variant("ssl", default=True, description="Enable support for secure connection to mail server") variant("inet6", default=True, description="Enable support for IPv6 transport") variant("md5auth", default=True, description="Enable support for MD5 authentication") diff --git a/var/spack/repos/builtin/packages/sst-core/package.py b/var/spack/repos/builtin/packages/sst-core/package.py index 7f512e7cd919a3..7d0176c4524728 100644 --- a/var/spack/repos/builtin/packages/sst-core/package.py +++ b/var/spack/repos/builtin/packages/sst-core/package.py @@ -41,6 +41,8 @@ class SstCore(AutotoolsPackage): version("develop", branch="devel") version("master", branch="master") + depends_on("cxx", type="build") # generated + variant( "pdes_mpi", default=True, diff --git a/var/spack/repos/builtin/packages/sst-dumpi/package.py b/var/spack/repos/builtin/packages/sst-dumpi/package.py index c53e0cd97709e0..fd4cee80038bfc 100644 --- a/var/spack/repos/builtin/packages/sst-dumpi/package.py +++ b/var/spack/repos/builtin/packages/sst-dumpi/package.py @@ -30,6 +30,10 @@ class SstDumpi(AutotoolsPackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf@1.68:", type="build") depends_on("automake@1.11.1:", type="build") depends_on("libtool@1.2.4:", type="build") diff --git a/var/spack/repos/builtin/packages/sst-elements/package.py b/var/spack/repos/builtin/packages/sst-elements/package.py index 93f621c60702bf..1cbeca76aaf812 100644 --- a/var/spack/repos/builtin/packages/sst-elements/package.py +++ b/var/spack/repos/builtin/packages/sst-elements/package.py @@ -41,6 +41,10 @@ class SstElements(AutotoolsPackage): version("develop", branch="devel") version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Contact SST developers (https://github.com/sstsimulator) # if your use case requires support for: # - balar diff --git a/var/spack/repos/builtin/packages/sst-macro/package.py b/var/spack/repos/builtin/packages/sst-macro/package.py index c04358ab06bea0..1319fc4eafb84f 100644 --- a/var/spack/repos/builtin/packages/sst-macro/package.py +++ b/var/spack/repos/builtin/packages/sst-macro/package.py @@ -42,6 +42,10 @@ class SstMacro(AutotoolsPackage): version("master", branch="master") version("develop", branch="devel") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + for version_name in ("master", "develop"): depends_on("autoconf@1.68:", type="build", when="@{}".format(version_name)) depends_on("automake@1.11.1:", type="build", when="@{}".format(version_name)) diff --git a/var/spack/repos/builtin/packages/sst-transports/package.py b/var/spack/repos/builtin/packages/sst-transports/package.py index a3d84df8188c3a..04425eac728e2b 100644 --- a/var/spack/repos/builtin/packages/sst-transports/package.py +++ b/var/spack/repos/builtin/packages/sst-transports/package.py @@ -19,6 +19,9 @@ class SstTransports(CMakePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("sst-macro") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/stacks/package.py b/var/spack/repos/builtin/packages/stacks/package.py index 8fed579fd7bffb..74279d07283e4d 100644 --- a/var/spack/repos/builtin/packages/stacks/package.py +++ b/var/spack/repos/builtin/packages/stacks/package.py @@ -19,6 +19,9 @@ class Stacks(AutotoolsPackage): version("2.3b", sha256="a46786d8811a730ebcdc17891e89f50d4f4ae196734439dac86091f45c92ac72") version("1.46", sha256="45a0725483dc0c0856ad6b1f918e65d91c1f0fe7d8bf209f76b93f85c29ea28a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("sparsehash", default=True, description="Improve Stacks memory usage with SparseHash") depends_on("perl", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/staden-io-lib/package.py b/var/spack/repos/builtin/packages/staden-io-lib/package.py index 18531e0a7f00e8..f5ae09ca6682cb 100644 --- a/var/spack/repos/builtin/packages/staden-io-lib/package.py +++ b/var/spack/repos/builtin/packages/staden-io-lib/package.py @@ -19,6 +19,8 @@ class StadenIoLib(AutotoolsPackage): version("1.14.8", sha256="3bd560309fd6d70b14bbb8230e1baf8706b804eb6201220bb6c3d6db72003d1b") + depends_on("c", type="build") # generated + variant("curl", default=False, description="Build with curl support") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/star/package.py b/var/spack/repos/builtin/packages/star/package.py index c72e1c09642b46..be17fbfc14a6bf 100644 --- a/var/spack/repos/builtin/packages/star/package.py +++ b/var/spack/repos/builtin/packages/star/package.py @@ -14,6 +14,7 @@ class Star(MakefilePackage): license("MIT") + version("2.7.11b", sha256="3f65305e4112bd154c7e22b333dcdaafc681f4a895048fa30fa7ae56cac408e7") version("2.7.11a", sha256="542457b1a4fee73f27a581b1776e9f73ad2b4d7e790388b6dc71147bd039f99a") version("2.7.10b", sha256="0d1b71de6c5be1c5d90b32130d2abcd5785a4fc7c1e9bf19cc391947f2dc46e5") version("2.7.10a", sha256="af0df8fdc0e7a539b3ec6665dce9ac55c33598dfbc74d24df9dae7a309b0426a") @@ -36,10 +37,15 @@ class Star(MakefilePackage): url="https://github.com/alexdobin/STAR/archive/STAR_2.4.2a.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") # required for certain steps in the makefile depends_on("xxd", type="build") + conflicts("zlib-ng") # https://github.com/alexdobin/STAR/issues/2063 + build_directory = "source" def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/starlight/package.py b/var/spack/repos/builtin/packages/starlight/package.py index b9b11bc3300846..2ce197cf6e53df 100644 --- a/var/spack/repos/builtin/packages/starlight/package.py +++ b/var/spack/repos/builtin/packages/starlight/package.py @@ -29,6 +29,10 @@ class Starlight(CMakePackage): url="https://starlight.hepforge.org/downloads?f=starlight_r300.tar", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + patch( "https://gitlab.cern.ch/sft/lcgcmake/-/raw/master/generators/patches/starlight-r313.patch", sha256="c70f70fd7c96dc0417f9254d25b584222abcb2c452e1e6dd4b8cfb0b64bf10e0", diff --git a/var/spack/repos/builtin/packages/starpu/package.py b/var/spack/repos/builtin/packages/starpu/package.py index 013c0784f93511..8fcc35dd124102 100644 --- a/var/spack/repos/builtin/packages/starpu/package.py +++ b/var/spack/repos/builtin/packages/starpu/package.py @@ -30,7 +30,10 @@ class Starpu(AutotoolsPackage): maintainers("nfurmento", "sthibaul") - version("1.4.4", sha256="054ca4d584400f2f8b794e6bd14c076a7a810c63ad5594d2c4133f50b8e59cb9") + version("1.4.7", sha256="1eb3df551089153fe6e0b172ad95118434b4a81ea9eaa5a2c38725d0db53b13e") + version("1.4.6", sha256="579f38e150ab78c9ab299649d8649a043dbf49786e54acbf3dad90c160672cc7") + version("1.4.5", sha256="28f389b34df57a2a4e4743b40554b0f8d098ff2199e9eb8fbbe20aa377b64541") + version("1.4.4", sha256="37f37739911451bbea063cff52779114f76bc681ea8de3a2ab65fc517d0ea112") version("1.4.3", sha256="848cce0a2fbaa75b104d9878da928e19b1c3bc9b978193081672ac882e63bbea") version("1.4.2", sha256="6c1fce80593a96d599881c1e9697a10e2072195b1c4c64a99528192b6715ddd6") version("1.4.1", sha256="f023aa53da245a0f43944c3a13f63b4bfdf1324f3e66bf5cd367ce51e2044925") @@ -62,6 +65,11 @@ class Starpu(AutotoolsPackage): version("git-1.1", branch="starpu-1.1") version("git-1.2", branch="starpu-1.2") version("git-1.3", branch="starpu-1.3") + version("git-1.4", branch="starpu-1.4") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant("shared", default=True, description="Build STARPU as a shared library") variant("fast", default=True, description="Disable runtime assertions") @@ -83,6 +91,7 @@ class Starpu(AutotoolsPackage): depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") + depends_on("py-setuptools", type="build") depends_on("m4", type="build") depends_on("hwloc") depends_on("hwloc+cuda", when="+cuda") diff --git a/var/spack/repos/builtin/packages/startup-notification/package.py b/var/spack/repos/builtin/packages/startup-notification/package.py index 6ec0622e0f3e6d..a4d228ef06522e 100644 --- a/var/spack/repos/builtin/packages/startup-notification/package.py +++ b/var/spack/repos/builtin/packages/startup-notification/package.py @@ -17,6 +17,9 @@ class StartupNotification(AutotoolsPackage): version("0.12", sha256="3c391f7e930c583095045cd2d10eb73a64f085c7fde9d260f2652c7cb3cfbe4a") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxcb") depends_on("xcb-util") + depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/stat/package.py b/var/spack/repos/builtin/packages/stat/package.py index fab3a29213a582..2d089b38ef99e4 100644 --- a/var/spack/repos/builtin/packages/stat/package.py +++ b/var/spack/repos/builtin/packages/stat/package.py @@ -42,6 +42,10 @@ class Stat(AutotoolsPackage): url="https://github.com/LLNL/STAT/files/2489327/stat-4.0.1.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # TODO: dysect requires Dyninst patch for version 3.0.0b variant("dysect", default=False, description="enable DySectAPI") variant("examples", default=False, description="enable examples") diff --git a/var/spack/repos/builtin/packages/stc/package.py b/var/spack/repos/builtin/packages/stc/package.py index 75ab2ee83711a8..b5283aceb6fe34 100644 --- a/var/spack/repos/builtin/packages/stc/package.py +++ b/var/spack/repos/builtin/packages/stc/package.py @@ -21,7 +21,7 @@ class Stc(AutotoolsPackage): version("0.8.3", sha256="d61ca80137a955b12e84e41cb8a78ce1a58289241a2665076f12f835cf68d798") version("0.8.2", sha256="13f0f03fdfcca3e63d2d58d7e7dbdddc113d5b9826c9357ab0713b63e8e42c5e") - depends_on("java", type=("build", "run")) + depends_on("java@11", type=("build", "run")) depends_on("ant", type="build") depends_on("turbine", type=("build", "run")) depends_on("turbine@master", type=("build", "run"), when="@master") diff --git a/var/spack/repos/builtin/packages/stdexec/package.py b/var/spack/repos/builtin/packages/stdexec/package.py index 2d17bb1626faf3..95b6707b1c51eb 100644 --- a/var/spack/repos/builtin/packages/stdexec/package.py +++ b/var/spack/repos/builtin/packages/stdexec/package.py @@ -19,10 +19,19 @@ class Stdexec(CMakePackage): version("23.03", sha256="2c9dfb6e56a190543049d2300ccccd1b626f4bb82af5b607869c626886fadd15") version("main", branch="main") + depends_on("cxx", type="build") + depends_on("cmake@3.23.1:", type="build") conflicts("%gcc@:10") conflicts("%clang@:12") + @when("@:23.03") def build(self, spec, prefix): pass + + def cmake_args(self): + return [ + self.define("STDEXEC_BUILD_TESTS", self.run_tests), + self.define("STDEXEC_BUILD_EXAMPLES", False), + ] diff --git a/var/spack/repos/builtin/packages/steps/package.py b/var/spack/repos/builtin/packages/steps/package.py index f616d30d152363..99f8c0306d290c 100644 --- a/var/spack/repos/builtin/packages/steps/package.py +++ b/var/spack/repos/builtin/packages/steps/package.py @@ -15,19 +15,22 @@ class Steps(CMakePackage): maintainers("tristan0x") license("GPL-3.0-or-later") + submodules = True - version("develop", branch="master", submodules=True) - version("4.1.1", submodules=True) + version("develop", branch="master") + version("5.0.1", tag="5.0.1", commit="1f2eb8193edc1c75e0877fe37e39452b399242c9") + version("4.1.1", tag="4.1.1", commit="fdb6d9e02a69dae698f66013117fc3f08f808f45") + depends_on("cxx", type="build") # generated + + variant("blender", default=False, description="Build stepsblender package") variant( "codechecks", default=False, description="Perform additional code checks like code formatting or static analysis", ) variant("lapack", default=False, description="Use new BDSystem/Lapack code for E-Field solver") - variant( - "distmesh", default=True, when="+mpi", description="Add solvers based on distributed mesh" - ) + variant("distmesh", default=True, description="Add solvers based on distributed mesh") variant("petsc", default=True, description="Use PETSc library for parallel E-Field solver") variant("mpi", default=True, description="Use MPI for parallel solvers") variant("coverage", default=False, description="Enable code coverage") @@ -45,21 +48,26 @@ class Steps(CMakePackage): variant( "likwid", default=False, description="Build in likwid support (Instrumentor Interface)" ) + variant("vesicle", default=True, when="@5:", description="Add vesicle model") # Build with `ninja` instead of `make` generator("ninja") + conflicts("+distmesh~mpi", msg="steps+distmesh requires +mpi") depends_on("benchmark", type=("build", "test")) depends_on("blas") depends_on("boost", type="build") depends_on("caliper", when="+caliper") depends_on("easyloggingpp", when="~bundle") + depends_on("eigen", when="@5:") depends_on("gmsh", when="+distmesh") + depends_on("gsl", when="+vesicle") depends_on("lapack", when="+lapack") depends_on("lcov", when="+coverage", type="build") depends_on("likwid", when="+likwid") depends_on("metis+int64") depends_on("mpi", when="+mpi") + depends_on("ninja", type="build") depends_on("omega-h+gmsh+mpi", when="~bundle+distmesh") depends_on("petsc~debug+int64+mpi", when="+petsc+mpi") depends_on("petsc~debug+int64~mpi", when="+petsc~mpi") @@ -67,24 +75,31 @@ class Steps(CMakePackage): depends_on("py-cython") depends_on("py-gcovr", when="+coverage", type="build") depends_on("py-h5py", type=("build", "test", "run")) + depends_on("py-pip", type="build", when="@5:") depends_on("py-matplotlib", type=("build", "test")) + depends_on("py-build", type="build", when="@5:") depends_on("py-mpi4py", when="+distmesh", type=("build", "test", "run")) depends_on("py-numpy", type=("build", "test", "run")) depends_on("py-scipy", type=("build", "test", "run")) depends_on("python", type=("build", "test", "run")) depends_on("random123", when="~bundle") - depends_on("sundials@:2.99.99+int64", when="~bundle") - - patch("for_aarch64.patch", when="target=aarch64:") + depends_on("sundials@:2+int64", when="@:5~bundle") + depends_on("sundials@:6+int64", when="@develop~bundle") def patch(self): # easylogging requires compilation by # its dependents: splice in disabling all errors filter_file(r"(-Wno-double-promotion)", r"-Wno-error \1", "src/steps/util/CMakeLists.txt") + # unittest2 is unmaintained, shan't be used and does not build with modern Python + filter_file("unittest2", "", "requirements.txt", ignore_absent=True) def cmake_args(self): + python_interpreter = self.spec["python"].prefix.bin.python + str( + self.spec["python"].version.up_to(1) + ) args = [ - self.define("BLAS_LIBRARIES", self.spec["blas"].libs.joined(";")), + self.define("BLAS_LIBRARIES", self.spec["blas"].libs), + self.define("PYTHON_EXECUTABLE", python_interpreter), self.define("STEPS_INSTALL_PYTHON_DEPS", False), self.define_from_variant("BUILD_STOCHASTIC_TESTS", "stochtests"), self.define_from_variant("BUILD_TESTING", "codechecks"), @@ -94,6 +109,8 @@ def cmake_args(self): self.define_from_variant("STEPS_USE_CALIPER_PROFILING", "caliper"), self.define_from_variant("STEPS_USE_DIST_MESH", "distmesh"), self.define_from_variant("STEPS_USE_LIKWID_PROFILING", "likwid"), + self.define_from_variant("STEPS_USE_STEPSBLENDER", "blender"), + self.define_from_variant("STEPS_USE_VESICLE_SOLVER", "vesicle"), self.define_from_variant("USE_BDSYSTEM_LAPACK", "lapack"), self.define_from_variant("USE_MPI", "mpi"), self.define_from_variant("USE_PETSC", "petsc"), diff --git a/var/spack/repos/builtin/packages/stinger/package.py b/var/spack/repos/builtin/packages/stinger/package.py index 8f11bf8429bd9c..0ae1fd5173317e 100644 --- a/var/spack/repos/builtin/packages/stinger/package.py +++ b/var/spack/repos/builtin/packages/stinger/package.py @@ -16,6 +16,9 @@ class Stinger(CMakePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + parallel = False def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/storm/package.py b/var/spack/repos/builtin/packages/storm/package.py index d18dfd853e5b80..2e7a971b6b9d72 100644 --- a/var/spack/repos/builtin/packages/storm/package.py +++ b/var/spack/repos/builtin/packages/storm/package.py @@ -20,6 +20,7 @@ class Storm(Package): license("CC-BY-4.0") + version("2.6.2", sha256="640c2c54a593cdcffef9441336738774ae618830d3e63eb8e770c22d68beed30") version("2.3.0", sha256="49c2255b26633c6fd96399c520339e459fcda29a0e7e6d0c8775cefcff6c3636") version("2.2.0", sha256="f621163f349a8e85130bc3d2fbb34e3b08f9c039ccac5474f3724e47a3a38675") version("2.1.0", sha256="e279a495dda42af7d9051543989f74a1435a5bda53e795a1de4a1def32027fc4") diff --git a/var/spack/repos/builtin/packages/stow/package.py b/var/spack/repos/builtin/packages/stow/package.py index cec0871bd52a69..180c69920beedd 100644 --- a/var/spack/repos/builtin/packages/stow/package.py +++ b/var/spack/repos/builtin/packages/stow/package.py @@ -19,6 +19,7 @@ class Stow(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-or-later") + version("2.4.0", sha256="a7bac673daa246cf54ffb48a113eadd204a615630e76b53b5f64d81a275b77b3") version("2.3.1", sha256="26a6cfdfdaca0eea742db5487798c15fcd01889dc86bc5aa62614ec9415a422f") version("2.2.2", sha256="a0022034960e47a8d23dffb822689f061f7a2d9101c9835cf11bf251597aa6fd") version("2.2.0", sha256="86bc30fe1d322a5c80ff3bd7580c2758149aad7c3bbfa18b48a9d95c25d66b05") diff --git a/var/spack/repos/builtin/packages/strace/package.py b/var/spack/repos/builtin/packages/strace/package.py index 9870692bccd01d..6fd298cfff9b40 100644 --- a/var/spack/repos/builtin/packages/strace/package.py +++ b/var/spack/repos/builtin/packages/strace/package.py @@ -36,6 +36,8 @@ class Strace(AutotoolsPackage): version("5.0", sha256="3b7ad77eb2b81dc6078046a9cc56eed5242b67b63748e7fc28f7c2daf4e647da") version("4.21", sha256="5c7688db44073e94c59a5627744e5699454419824cc8166e8bcfd7ec58375c37") + depends_on("c", type="build") # generated + conflicts("platform=darwin", msg="strace runs only on Linux.") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/stream/package.py b/var/spack/repos/builtin/packages/stream/package.py index 842a9b2e8a8875..f10b894b85212f 100644 --- a/var/spack/repos/builtin/packages/stream/package.py +++ b/var/spack/repos/builtin/packages/stream/package.py @@ -16,6 +16,9 @@ class Stream(MakefilePackage): version("5.10") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=False, description="Build with OpenMP support") variant("stream_array_size", default="none", description="Size of work arrays in elements") diff --git a/var/spack/repos/builtin/packages/stress/package.py b/var/spack/repos/builtin/packages/stress/package.py index ec7859d3c99f4a..531aa8ec868289 100644 --- a/var/spack/repos/builtin/packages/stress/package.py +++ b/var/spack/repos/builtin/packages/stress/package.py @@ -20,3 +20,5 @@ class Stress(AutotoolsPackage): license("GPL-2.0-or-later") version("1.0.4", sha256="b03dbb9664d7f8dcb3eadc918c2e8eb822f5a3ba47d9bd51246540bac281bd75") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/stressapptest/package.py b/var/spack/repos/builtin/packages/stressapptest/package.py index 84191c6c06426d..27ad1f603f39d0 100644 --- a/var/spack/repos/builtin/packages/stressapptest/package.py +++ b/var/spack/repos/builtin/packages/stressapptest/package.py @@ -23,3 +23,6 @@ class Stressapptest(AutotoolsPackage): version("1.0.9", sha256="2ba470587ad4f6ae92057d427c3a2a2756e5f10bd25cd91e62eaef55a40b30a1") version("1.0.8", sha256="b0432f39055166156ed04eb234f3c226b17a42f802a3f81d76ee999838e205df") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/string-view-lite/package.py b/var/spack/repos/builtin/packages/string-view-lite/package.py index 1f93927eb02b8f..261ba49a15e68f 100644 --- a/var/spack/repos/builtin/packages/string-view-lite/package.py +++ b/var/spack/repos/builtin/packages/string-view-lite/package.py @@ -26,6 +26,8 @@ class StringViewLite(CMakePackage): version("0.2.0", sha256="c8ae699dfd2ccd15c5835e9b1d246834135bbb91b82f7fc4211b8ac366bffd34") version("0.1.0", sha256="7de87d6595230a6085655dab6145340bc423f2cf206263ef73c9b78f7b153340") + depends_on("cxx", type="build") # generated + def cmake_args(self): return [ "-DSTRINGVIEW_LITE_OPT_BUILD_TESTS=%s" % ("ON" if self.run_tests else "OFF"), diff --git a/var/spack/repos/builtin/packages/stringtie/package.py b/var/spack/repos/builtin/packages/stringtie/package.py index 13428929af2724..566fce744fb227 100644 --- a/var/spack/repos/builtin/packages/stringtie/package.py +++ b/var/spack/repos/builtin/packages/stringtie/package.py @@ -20,6 +20,9 @@ class Stringtie(MakefilePackage): version("1.3.4a", sha256="6164a5fa9bf8807ef68ec89f47e3a61fe57fa07fe858f52fb6627f705bf71add") version("1.3.3b", sha256="30e8a3a29b474f0abeef1540d9b4624a827d8b29d7347226d86a38afea28bc0f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") def build(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/structure/package.py b/var/spack/repos/builtin/packages/structure/package.py index 6620fc0536b84c..90ffb21a85e548 100644 --- a/var/spack/repos/builtin/packages/structure/package.py +++ b/var/spack/repos/builtin/packages/structure/package.py @@ -15,6 +15,8 @@ class Structure(MakefilePackage): version("2.3.4", sha256="f2b72b9189a514f53e921bbdc1aa3dbaca7ac34a8467af1f972c7e4fc9c0bb37") + depends_on("c", type="build") # generated + def url_for_version(self, version): url = "http://web.stanford.edu/group/pritchardlab/structure_software/release_versions/v{0}/structure_kernel_source.tar.gz" return url.format(version) diff --git a/var/spack/repos/builtin/packages/strumpack/package.py b/var/spack/repos/builtin/packages/strumpack/package.py index 348a74947e05b5..eb20c3812ffacd 100644 --- a/var/spack/repos/builtin/packages/strumpack/package.py +++ b/var/spack/repos/builtin/packages/strumpack/package.py @@ -3,8 +3,6 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) -from platform import machine - from spack.package import * from spack.util.environment import set_env @@ -53,6 +51,10 @@ class Strumpack(CMakePackage, CudaPackage, ROCmPackage): version("3.2.0", sha256="34d93e1b2a3b8908ef89804b7e08c5a884cbbc0b2c9f139061627c0d2de282c1") version("3.1.1", sha256="c1c3446ee023f7b24baa97b24907735e89ce4ae9f5ef516645dfe390165d1778") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("mpi", default=True, description="Use MPI") variant( @@ -177,7 +179,13 @@ def cmake_args(self): if "%cce" in spec: # Assume the proper Cray CCE module (cce) is loaded: - craylibs_path = env["CRAYLIBS_" + machine().upper()] + craylibs_var = "CRAYLIBS_" + str(spec.target.family).upper() + craylibs_path = env.get(craylibs_var, None) + if not craylibs_path: + raise InstallError( + f"The environment variable {craylibs_var} is not defined.\n" + "\tMake sure the 'cce' module is in the compiler spec." + ) env.setdefault("LDFLAGS", "") env["LDFLAGS"] += " -Wl,-rpath," + craylibs_path @@ -191,30 +199,14 @@ def test_data_dir(self): add_sparse = not self.spec.satisfies("@:5.1.1") return join_path("examples", "sparse" if add_sparse else "", "data") - # TODO: Replace this method and its 'get' use for cmake path with - # join_path(self.spec['cmake'].prefix.bin, 'cmake') once stand-alone - # tests can access build dependencies through self.spec['cmake']. - def cmake_bin(self, set=True): - """(Hack) Set/get cmake dependency path.""" - filepath = join_path(self.install_test_root, "cmake_bin_path.txt") - if set: - with open(filepath, "w") as out_file: - cmake_bin = join_path(self.spec["cmake"].prefix.bin, "cmake") - out_file.write("{0}\n".format(cmake_bin)) - else: - with open(filepath, "r") as in_file: - return in_file.read().strip() - @run_after("install") def cache_test_sources(self): """Copy the example source files after the package is installed to an install test subdirectory for use during `spack test run`.""" self.cache_extra_test_sources([self.test_data_dir, self.test_src_dir]) - # TODO: Remove once self.spec['cmake'] is available here - self.cmake_bin(set=True) - - def _test_example(self, test_prog, test_dir, test_cmd, test_args): + def _test_example(self, test_prog, test_cmd, test_args): + test_dir = join_path(self.test_suite.current_test_cache_dir, self.test_src_dir) cmake_filename = join_path(test_dir, "CMakeLists.txt") with open(cmake_filename, "w") as mkfile: mkfile.write("cmake_minimum_required(VERSION 3.15)\n") @@ -225,50 +217,42 @@ def _test_example(self, test_prog, test_dir, test_cmd, test_args): "target_link_libraries({0} ".format(test_prog) + "PRIVATE STRUMPACK::strumpack)\n" ) - # TODO: Remove/replace once self.spec['cmake'] is available here - cmake_bin = self.cmake_bin(set=False) + with working_dir(test_dir): + opts = self.builder.std_cmake_args + opts += self.cmake_args() + opts += ["."] + cmake = self.spec["cmake"].command + cmake(*opts) - opts = self.std_cmake_args - opts += self.cmake_args() - opts += ["."] + make = which("make") + make(test_prog) - self.run_test( - cmake_bin, - opts, - [], - installed=False, - purpose="test: generating makefile", - work_dir=test_dir, - ) - self.run_test( - "make", test_prog, purpose="test: building {0}".format(test_prog), work_dir=test_dir - ) - with set_env(OMP_NUM_THREADS="1"): - self.run_test( - test_cmd, - test_args, - installed=False, - purpose="test: running {0}".format(test_prog), - skip_missing=False, - work_dir=test_dir, - ) + with set_env(OMP_NUM_THREADS="1"): + exe = which(test_cmd) + exe(*test_args) - def test(self): - """Run the stand-alone tests for the installed software.""" - test_dir = join_path(self.test_suite.current_test_cache_dir, self.test_src_dir) + def test_sparse_seq(self): + """Run sequential test_sparse""" + if "+mpi" in self.spec: + raise SkipTest("Package must be installed with '~mpi'") test_exe = "test_sparse_seq" - test_exe_mpi = "test_sparse_mpi" exe_arg = [join_path("..", self.test_data_dir, "pde900.mtx")] - if "+mpi" in self.spec: - test_args = ["-n", "1", test_exe_mpi] - test_args.extend(exe_arg) - mpiexe_list = ["srun", "mpirun", "mpiexec"] - for mpiexe in mpiexe_list: - if which(mpiexe) is not None: - self._test_example(test_exe_mpi, test_dir, mpiexe, test_args) - break - else: - self._test_example(test_exe, test_dir, test_exe, exe_arg) + self._test_example(test_exe, test_exe, exe_arg) + + def test_sparse_mpi(self): + """Run parallel test_sparse""" + if "+mpi" not in self.spec: + raise SkipTest("Package must be installed with '+mpi'") + test_exe_mpi = "test_sparse_mpi" + test_args = ["-n", "1", test_exe_mpi, join_path("..", self.test_data_dir, "pde900.mtx")] + mpiexe_list = ["srun", "mpirun", "mpiexec"] + for exe in mpiexe_list: + try: + self._test_example(test_exe_mpi, exe, test_args) + return + except Exception: + pass + assert False, "No MPI executable was found" def check(self): """Skip the builtin testsuite, use the stand-alone tests instead.""" diff --git a/var/spack/repos/builtin/packages/su2/package.py b/var/spack/repos/builtin/packages/su2/package.py index 0fbd50ad7c1247..5ec32895a40db6 100644 --- a/var/spack/repos/builtin/packages/su2/package.py +++ b/var/spack/repos/builtin/packages/su2/package.py @@ -18,6 +18,8 @@ class Su2(MesonPackage): license("BSD-3-Clause") + version("8.0.1", commit="8ef4b1be045122b2fdb485bfb5fe4eecd1bc4246", submodules=True) + version("8.0.0", commit="1fe59817e984f67ff55146d90d0059e27b772891", submodules=True) version("7.5.1", commit="09ba9e3a9605c02d38290e34f42aa6982cb4dd05", submodules=True) version("7.5.0", commit="8e8ea59fe6225c8ec4e94d0e0a4b6690ea4294e5", submodules=True) version("7.4.0", commit="745e5d922c63c8ec6963b31808c20df2e3bfd075", submodules=True) @@ -36,6 +38,10 @@ class Su2(MesonPackage): version("7.0.0", sha256="6207dcca15eaebc11ce12b2866c937b4ad9b93274edf6f23d0487948ac3963b8") version("6.2.0", sha256="ffc953326e8432a1a6534556a5f6cf086046d3149cfcec6b4e7390eebe30ce2e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=False, description="Enable MPI support") variant("openmp", default=False, description="Enable OpenMP support") variant("tecio", default=True, description="Enable TECIO support") @@ -76,6 +82,9 @@ class Su2(MesonPackage): # This fix is considered meaningless and will be removed in the next version(@7.6:) of SU2. patch("meson_version.patch", when="@7.4.0:7.5.1") + # Remove the timestamp check of preconfigure.py for version(@8:) + patch("remove_preconfigure_timestamp_check.patch", when="@8.0.0:") + def patch(self): if self.spec.satisfies("+autodiff") or self.spec.satisfies("+directdiff"): filter_file( diff --git a/var/spack/repos/builtin/packages/su2/remove_preconfigure_timestamp_check.patch b/var/spack/repos/builtin/packages/su2/remove_preconfigure_timestamp_check.patch new file mode 100644 index 00000000000000..a0f844f65a948d --- /dev/null +++ b/var/spack/repos/builtin/packages/su2/remove_preconfigure_timestamp_check.patch @@ -0,0 +1,13 @@ +--- a/meson.build 2022-12-20 21:08:29.000000000 +0900 ++++ b/meson.build 2023-05-19 03:24:08.870966665 +0900 +@@ -6,10 +6,6 @@ + 'c_std=c99', + 'cpp_std=c++11']) + +-fsmod = import('fs') +-if not fsmod.exists('su2preconfig.timestamp') +- error('SU2 must be (pre-)configured with the extended Meson script (./meson.py) or with the ./preconfigure.py script in the SU2 root directory.') +-endif + + pymod = import('python') + python = pymod.find_installation() diff --git a/var/spack/repos/builtin/packages/subread/package.py b/var/spack/repos/builtin/packages/subread/package.py index bc5b2b8c4df4cb..7ab7f678c52413 100644 --- a/var/spack/repos/builtin/packages/subread/package.py +++ b/var/spack/repos/builtin/packages/subread/package.py @@ -27,6 +27,8 @@ class Subread(MakefilePackage): version("1.6.0", sha256="31251ec4c134e3965d25ca3097890fb37e2c7a4163f6234515534fd325b1002a") version("1.5.2", sha256="a8c5f0e09ed3a105f01866517a89084c7302ff70c90ef8714aeaa2eab181a0aa") + depends_on("c", type="build") # generated + depends_on("zlib-api") def build(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/subversion/package.py b/var/spack/repos/builtin/packages/subversion/package.py index 42e1f63eca0544..f64614d5b9c11b 100644 --- a/var/spack/repos/builtin/packages/subversion/package.py +++ b/var/spack/repos/builtin/packages/subversion/package.py @@ -37,6 +37,9 @@ class Subversion(AutotoolsPackage): version("1.8.17", sha256="1b2cb9a0ca454035e55b114ee91c6433b9ede6c2893f2fb140939094d33919e4") version("1.8.13", sha256="17e8900a877ac9f0d5ef437c20df437fec4eb2c5cb9882609d2277e2312da52c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("serf", default=True, description="Serf HTTP client library") variant("perl", default=False, description="Build with Perl bindings") variant("apxs", default=True, description="Build with APXS") diff --git a/var/spack/repos/builtin/packages/suite-sparse/package.py b/var/spack/repos/builtin/packages/suite-sparse/package.py index 248024cc695229..dfdb8ae91023be 100644 --- a/var/spack/repos/builtin/packages/suite-sparse/package.py +++ b/var/spack/repos/builtin/packages/suite-sparse/package.py @@ -3,6 +3,8 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os.path + from spack.package import * @@ -17,6 +19,9 @@ class SuiteSparse(Package): license("Apache-2.0") + version("7.7.0", sha256="529b067f5d80981f45ddf6766627b8fc5af619822f068f342aab776e683df4f3") + version("7.3.1", sha256="b512484396a80750acf3082adc1807ba0aabb103c2e09be5691f46f14d0a9718") + version("7.2.1", sha256="304e959a163ff74f8f4055dade3e0b5498d9aa3b1c483633bb400620f521509f") version("5.13.0", sha256="59c6ca2959623f0c69226cf9afb9a018d12a37fab3a8869db5f6d7f83b6b147d") version("5.12.0", sha256="5fb0064a3398111976f30c5908a8c0b40df44c6dd8f0cc4bfa7b9e45d8c647de") version("5.11.0", sha256="fdd957ed06019465f7de73ce931afaf5d40e96e14ae57d91f60868b8c123c4c8") @@ -39,6 +44,10 @@ class SuiteSparse(Package): version("4.5.5", sha256="80d1d9960a6ec70031fecfe9adfe5b1ccd8001a7420efb50d6fa7326ef14af91") version("4.5.3", sha256="b6965f9198446a502cde48fb0e02236e75fa5700b94c7306fc36599d57b563f4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "pic", default=True, @@ -65,6 +74,7 @@ class SuiteSparse(Package): depends_on("gmp", when="@5.8.0:") depends_on("m4", type="build", when="@5.0.0:") depends_on("cmake", when="+graphblas @5.2.0:", type="build") + depends_on("cmake@3.22:", when="@6:", type="build") depends_on("metis@5.1.0", when="@4.5.1:") with when("+tbb"): @@ -146,7 +156,7 @@ def symbol_suffix_blas(self, spec, args): ) for symbol in symbols: - args.append("CFLAGS+=-D{0}={1}{2}".format(symbol, symbol, suffix)) + args.append(f"CFLAGS+=-D{symbol}={symbol}{suffix}") def install(self, spec, prefix): # The build system of SuiteSparse is quite old-fashioned. @@ -168,23 +178,24 @@ def install(self, spec, prefix): # completely disabled. See # [SuiteSparse/SuiteSparse_config/SuiteSparse_config.mk] for more. "CUDA=no", - "CUDA_PATH=%s" % (spec["cuda"].prefix if "+cuda" in spec else ""), - "CFOPENMP=%s" % (self.compiler.openmp_flag if "+openmp" in spec else ""), - "CFLAGS=-O3 %s" % cc_pic_flag, + f"CUDA_PATH={spec['cuda'].prefix if '+cuda' in spec else ''}", + f"CFOPENMP={self.compiler.openmp_flag if '+openmp' in spec else ''}", + f"CFLAGS=-O3 {cc_pic_flag}", # Both FFLAGS and F77FLAGS are used in SuiteSparse makefiles; # FFLAGS is used in CHOLMOD, F77FLAGS is used in AMD and UMFPACK. - "FFLAGS=%s" % f77_pic_flag, - "F77FLAGS=%s" % f77_pic_flag, + f"FFLAGS={f77_pic_flag}", + f"F77FLAGS={f77_pic_flag}", # use Spack's metis in CHOLMOD/Partition module, # otherwise internal Metis will be compiled - "MY_METIS_LIB=%s" % spec["metis"].libs.ld_flags, - "MY_METIS_INC=%s" % spec["metis"].prefix.include, + f"MY_METIS_LIB={spec['metis'].libs.ld_flags}", + f"MY_METIS_INC={spec['metis'].prefix.include}", # Make sure Spack's Blas/Lapack is used. Otherwise System's # Blas/Lapack might be picked up. Need to add -lstdc++, following # with the TCOV path of SparseSuite 4.5.1's Suitesparse_config.mk, # even though this fix is ugly - "BLAS=%s" % (spec["blas"].libs.ld_flags + (" -lstdc++" if "@4.5.1" in spec else "")), - "LAPACK=%s" % spec["lapack"].libs.ld_flags, + f"BLAS={spec['blas'].libs.ld_flags + (' -lstdc++' if '@4.5.1' in spec else '')}", + f"LAPACK={spec['lapack'].libs.ld_flags}", + f"JOBS={make_jobs}", ] # Recent versions require c11 but some demos do not get the c11 from @@ -193,7 +204,7 @@ def install(self, spec, prefix): # not an issue because c11 or newer is their default. However, for some # compilers (e.g. xlc) the c11 flag is necessary. if spec.satisfies("@5.4:5.7.1") and ("%xl" in spec or "%xl_r" in spec): - make_args += ["CFLAGS+=%s" % self.compiler.c11_flag] + make_args += [f"CFLAGS+={self.compiler.c11_flag}"] # 64bit blas in UMFPACK: if ( @@ -219,21 +230,52 @@ def install(self, spec, prefix): # Intel TBB in SuiteSparseQR if "+tbb" in spec: - make_args += ["SPQR_CONFIG=-DHAVE_TBB", "TBB=%s" % spec["tbb"].libs.ld_flags] + make_args += ["SPQR_CONFIG=-DHAVE_TBB", f"TBB={spec['tbb'].libs.ld_flags}"] if "@5.3:" in spec: # Without CMAKE_LIBRARY_PATH defined, the CMake file in the # Mongoose directory finds libsuitesparseconfig.so in system # directories like /usr/lib. - make_args += [ - "CMAKE_OPTIONS=-DCMAKE_INSTALL_PREFIX=%s" % prefix - + " -DCMAKE_LIBRARY_PATH=%s" % prefix.lib + cmake_args = [ + f"-DCMAKE_INSTALL_PREFIX={prefix}", + f"-DCMAKE_LIBRARY_PATH={prefix.lib}", + f"-DBLAS_ROOT={spec['blas'].prefix}", + f"-DLAPACK_ROOT={spec['lapack'].prefix}", + # *_LIBRARIES is critical to pick up static + # libraries (if intended) and also to avoid + # unintentional system blas/lapack packages + f'-DBLAS_LIBRARIES="{";".join(spec["blas"].libs)}"', + f'-DLAPACK_LIBRARIES="{";".join(spec["lapack"].libs)}"', + "-DCMAKE_VERBOSE_MAKEFILE=ON", ] + if spec.satisfies("@:7.3"): + cmake_args += [ + f"-DNOPENMP={'OFF' if '+openmp' in spec else 'ON'}", + f"-DENABLE_CUDA={'ON' if '+cuda' in spec else 'OFF'}", + ] + else: + cmake_args += [ + f"-DSUITESPARSE_USE_OPENMP={'ON' if '+openmp' in spec else 'OFF'}", + f"-DSUITESPARSE_USE_CUDA={'ON' if '+cuda' in spec else 'OFF'}", + ] + make_args += [f"CMAKE_OPTIONS={' '.join(cmake_args)}"] if spec.satisfies("%gcc platform=darwin"): make_args += ["LDLIBS=-lm"] - make_args.append("INSTALL=%s" % prefix) + if "%cce" in spec: + # Assume the proper Cray CCE module (cce) is loaded: + craylibs_var = "CRAYLIBS_" + str(spec.target.family).upper() + craylibs_path = env.get(craylibs_var, None) + if not craylibs_path: + raise InstallError( + f"The environment variable {craylibs_var} is not defined.\n" + "\tMake sure the 'cce' module is in the compiler spec." + ) + env.setdefault("LDFLAGS", "") + env["LDFLAGS"] += " -Wl,-rpath," + craylibs_path + + make_args.append(f"INSTALL={prefix}") # Filter the targets we're interested in targets = [ @@ -255,15 +297,28 @@ def install(self, spec, prefix): targets.extend(["SPQR"]) if spec.satisfies("+graphblas"): targets.append("GraphBLAS") - if spec.satisfies("@5.8.0:"): + if spec.satisfies("@5.8.0:6"): targets.append("SLIP_LU") # Finally make and install - make("-C", "SuiteSparse_config", "config", *make_args) + if spec.satisfies("@6:"): + make("-C", "SuiteSparse_config", *make_args) + else: + make("-C", "SuiteSparse_config", "config", *make_args) for target in targets: make("-C", target, "library", *make_args) make("-C", target, "install", *make_args) + # Starting with v7.4.0 headers are installed in a subdirectory called + # 'suitesparse' by default. For backward compatibility, after + # installation, we create links for all files from 'suitesparse' in the + # containing directory, '/include': + if spec.satisfies("@7.4:"): + with working_dir(prefix.include): + for f in find("suitesparse", "*", recursive=False): + sf = os.path.basename(f) + symlink(join_path("suitesparse", sf), sf) + @run_after("install") def fix_darwin_install(self): # The shared libraries are not installed correctly on Darwin: @@ -296,5 +351,10 @@ def libs(self): query_parameters = self.spec.last_query.extra_parameters comps = all_comps if not query_parameters else query_parameters return find_libraries( - ["lib" + c for c in comps], root=self.prefix.lib, shared=True, recursive=False + # Libraries may be installed under both `lib/` and `lib64/`, + # don't force searching under `lib/` only. + ["lib" + c for c in comps], + root=self.prefix, + shared=True, + recursive=True, ) diff --git a/var/spack/repos/builtin/packages/sumo/package.py b/var/spack/repos/builtin/packages/sumo/package.py index a8b49d2e7579e4..e67d61d219d5d0 100644 --- a/var/spack/repos/builtin/packages/sumo/package.py +++ b/var/spack/repos/builtin/packages/sumo/package.py @@ -19,6 +19,8 @@ class Sumo(CMakePackage): version("1.5.0", sha256="be6ba0361b487a5e71c81e60b4c07a67826d5e170500c10c37374c1086ac2cb6") + depends_on("cxx", type="build") # generated + variant("gdal", default=True, description="gdal support, for arcgis") variant("ffmpeg", default=False, description="ffmpeg support, for video output") variant( diff --git a/var/spack/repos/builtin/packages/sundials/package.py b/var/spack/repos/builtin/packages/sundials/package.py index 3b635c1e946314..22068629d1aa73 100644 --- a/var/spack/repos/builtin/packages/sundials/package.py +++ b/var/spack/repos/builtin/packages/sundials/package.py @@ -17,7 +17,7 @@ class Sundials(CMakePackage, CudaPackage, ROCmPackage): homepage = "https://computing.llnl.gov/projects/sundials" url = "https://github.com/LLNL/sundials/releases/download/v2.7.0/sundials-2.7.0.tar.gz" - git = "https://github.com/llnl/sundials.git" + git = "https://github.com/LLNL/sundials.git" tags = ["radiuss", "e4s"] test_requires_compiler = True @@ -28,6 +28,8 @@ class Sundials(CMakePackage, CudaPackage, ROCmPackage): # Versions # ========================================================================== version("develop", branch="develop") + version("7.1.1", tag="v7.1.1", commit="c28eaa3764a03705d61decb6025b409360e9d53f") + version("7.0.0", sha256="d762a7950ef4097fbe9d289f67a8fb717a0b9f90f87ed82170eb5c36c0a07989") version("6.7.0", sha256="5f113a1564a9d2d98ff95249f4871a4c815a05dbb9b8866a82b13ab158c37adb") version("6.6.2", sha256="08f8223a5561327e44c072e46faa7f665c0c0bc8cd7e45d23f486c3d24c65009") version("6.6.1", sha256="21f71e4aef95b18f954c8bbdc90b62877443950533d595c68051ab768b76984b") @@ -62,6 +64,10 @@ class Sundials(CMakePackage, CudaPackage, ROCmPackage): version("2.7.0", sha256="d39fcac7175d701398e4eb209f7e92a5b30a78358d4a0c0fcc23db23c11ba104") version("2.6.2", sha256="d8ed0151509dd2b0f317b318a4175f8b95a174340fc3080b8c20617da8aa4d2f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # ========================================================================== # Variants # ========================================================================== @@ -84,10 +90,10 @@ class Sundials(CMakePackage, CudaPackage, ROCmPackage): values=("99", "11", "14", "17"), ) - # Logging + # Logging (default=0 when "@6.2.0:6.7.0", default=2 when "@7.0.0:") variant( "logging-level", - default="0", + default="2", description="logging level\n 0 = no logging,\n 1 = errors,\n " "2 = errors + warnings,\n 3 = errors + " "warnings + info,\n 4 = errors + warnings + info + debugging, " @@ -97,12 +103,12 @@ class Sundials(CMakePackage, CudaPackage, ROCmPackage): when="@6.2.0:", ) - # MPI logging + # MPI logging (option removed in 7.0) variant( "logging-mpi", default="OFF", description="enable MPI support in the logger", - when="@6.2.0:", + when="@6.2.0:6.7.0", ) # Real type @@ -165,10 +171,11 @@ class Sundials(CMakePackage, CudaPackage, ROCmPackage): variant("examples", default=True, description="Enable examples") variant("examples-install", default=True, description="Install examples") - # Generic (std-c) math libraries (UNIX only) + # Generic (std-c) math libraries (UNIX only) (option removed in 7.0) variant( "generic-math", default=True, + when="@:6.7.0", description="Use generic (std-c) math libraries on unix systems", ) @@ -221,8 +228,7 @@ class Sundials(CMakePackage, CudaPackage, ROCmPackage): # ========================================================================== # Build dependencies - depends_on("cmake@3.12:", type="build") - depends_on("cmake@3.18:", when="+cuda", type="build") + depends_on("cmake@3.18:", type="build") # MPI related dependencies depends_on("mpi", when="+mpi") @@ -282,6 +288,10 @@ class Sundials(CMakePackage, CudaPackage, ROCmPackage): # ========================================================================== # Patches # ========================================================================== + # https://github.com/LLNL/sundials/pull/434 + # https://github.com/LLNL/sundials/pull/437 + patch("sundials-hip-platform.patch", when="@7.0.0 +rocm") + # https://github.com/spack/spack/issues/29526 patch("nvector-pic.patch", when="@6.1.0:6.2.0 +rocm") diff --git a/var/spack/repos/builtin/packages/sundials/sundials-hip-platform.patch b/var/spack/repos/builtin/packages/sundials/sundials-hip-platform.patch new file mode 100644 index 00000000000000..c4092c9385340a --- /dev/null +++ b/var/spack/repos/builtin/packages/sundials/sundials-hip-platform.patch @@ -0,0 +1,33 @@ +diff -ruN spack-src/cmake/SundialsSetupHIP.cmake spack-src-patched/cmake/SundialsSetupHIP.cmake +--- spack-src/cmake/SundialsSetupHIP.cmake 2024-02-29 22:47:30.000000000 +0000 ++++ spack-src-patched/cmake/SundialsSetupHIP.cmake 2024-06-07 15:22:57.920619263 +0000 +@@ -32,9 +32,9 @@ + + if(NOT DEFINED HIP_PLATFORM) + if(NOT DEFINED ENV{HIP_PLATFORM}) +- set(HIP_PLATFORM "hcc" CACHE STRING "HIP platform (hcc, nvcc)") ++ set(HIP_PLATFORM "amd" CACHE STRING "HIP platform (amd, nvidia)") + else() +- set(HIP_PLATFORM "$ENV{HIP_PLATFORM}" CACHE STRING "HIP platform (hcc, nvcc)") ++ set(HIP_PLATFORM "$ENV{HIP_PLATFORM}" CACHE STRING "HIP platform (amd, nvidia)") + endif() + endif() + +diff -ruN spack-src/include/sundials/sundials_hip_policies.hpp spack-src-patched/include/sundials/sundials_hip_policies.hpp +--- spack-src/include/sundials/sundials_hip_policies.hpp 2024-02-29 22:47:30.000000000 +0000 ++++ spack-src-patched/include/sundials/sundials_hip_policies.hpp 2024-06-07 15:23:15.752724851 +0000 +@@ -27,10 +27,12 @@ + namespace sundials { + namespace hip { + +-#if defined(__HIP_PLATFORM_HCC__) ++#if defined(__HIP_PLATFORM_HCC__) || defined(__HIP_PLATFORM_AMD__) + constexpr const sunindextype WARP_SIZE = 64; +-#elif defined(__HIP_PLATFORM_NVCC__) ++#elif defined(__HIP_PLATFORM_NVCC__) || defined(__HIP_PLATFORM_NVDIA__) + constexpr const sunindextype WARP_SIZE = 32; ++#else ++#error "Unknown HIP_PLATFORM, report to github.com/LLNL/sundials/issues" + #endif + constexpr const sunindextype MAX_BLOCK_SIZE = 1024; + constexpr const sunindextype MAX_WARPS = MAX_BLOCK_SIZE / WARP_SIZE; diff --git a/var/spack/repos/builtin/packages/superchic/package.py b/var/spack/repos/builtin/packages/superchic/package.py index e1cbcf3c7a320b..6d874bfd6f47d4 100644 --- a/var/spack/repos/builtin/packages/superchic/package.py +++ b/var/spack/repos/builtin/packages/superchic/package.py @@ -23,6 +23,8 @@ class Superchic(MakefilePackage): version("3.06", sha256="17b4f56e85634f3c9708d5263772d7035fe4d7fb91a11bbffe889e0860efbd02") version("3.05", sha256="032f5c784f284ca02003a990234b099f61cd125791d56715680cd342e55c7da1") + depends_on("fortran", type="build") # generated + depends_on("lhapdf") depends_on("apfel", when="@4.01:") diff --git a/var/spack/repos/builtin/packages/superlu-dist/package.py b/var/spack/repos/builtin/packages/superlu-dist/package.py index e4ccfe3665623d..1a2809eb0df62d 100644 --- a/var/spack/repos/builtin/packages/superlu-dist/package.py +++ b/var/spack/repos/builtin/packages/superlu-dist/package.py @@ -45,6 +45,10 @@ class SuperluDist(CMakePackage, CudaPackage, ROCmPackage): version("5.1.0", sha256="73f292ab748b590b6dd7469e6986aeb95d279b8b8b3da511c695a396bdbc996c") version("5.0.0", sha256="78d1d6460ff16b3f71e4bcd7306397574d54d421249553ccc26567f00a10bfc6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("int64", default=False, description="Build with 64 bit integers") variant( "openmp", @@ -93,8 +97,8 @@ def append_from_variant(*args): append_define("CMAKE_CXX_COMPILER", spec["mpi"].mpicxx) append_define("CMAKE_INSTALL_LIBDIR", self.prefix.lib) append_define("CMAKE_INSTALL_BINDIR", self.prefix.bin) - append_define("TPL_BLAS_LIBRARIES", spec["blas"].libs) - append_define("TPL_LAPACK_LIBRARIES", spec["lapack"].libs) + append_define("TPL_BLAS_LIBRARIES", spec["blas"].libs.ld_flags) + append_define("TPL_LAPACK_LIBRARIES", spec["lapack"].libs.ld_flags) append_define("TPL_ENABLE_LAPACKLIB", True) append_define("USE_XSDK_DEFAULTS", True) diff --git a/var/spack/repos/builtin/packages/superlu-mt/package.py b/var/spack/repos/builtin/packages/superlu-mt/package.py index 788500d536d05b..ca14d064f0972f 100644 --- a/var/spack/repos/builtin/packages/superlu-mt/package.py +++ b/var/spack/repos/builtin/packages/superlu-mt/package.py @@ -19,6 +19,9 @@ class SuperluMt(Package): version("3.1", sha256="407b544b9a92b2ed536b1e713e80f986824cf3016657a4bfc2f3e7d2a76ecab6") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("int64", default=False, description="Build with 64 bit integers") variant("pic", default=True, description="Build with position independent code") variant("blas", default=True, description="Build with external BLAS library") diff --git a/var/spack/repos/builtin/packages/superlu/package.py b/var/spack/repos/builtin/packages/superlu/package.py index df5c7bcaaf00f6..5528378c80cc9a 100644 --- a/var/spack/repos/builtin/packages/superlu/package.py +++ b/var/spack/repos/builtin/packages/superlu/package.py @@ -34,16 +34,17 @@ class Superlu(CMakePackage, Package): version( "4.3", sha256="169920322eb9b9c6a334674231479d04df72440257c17870aaa0139d74416781", - deprecated=True, url="https://crd-legacy.lbl.gov/~xiaoye/SuperLU/superlu_4.3.tar.gz", ) version( "4.2", sha256="5a06e19bf5a597405dfeea39fe92aa8c5dd41da73c72c7187755a75f581efb28", - deprecated=True, url="https://crd-legacy.lbl.gov/~xiaoye/SuperLU/superlu_4.2.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + build_system( conditional("cmake", when="@5:"), conditional("generic", when="@:4"), default="cmake" ) diff --git a/var/spack/repos/builtin/packages/sw4/package.py b/var/spack/repos/builtin/packages/sw4/package.py index a277513d66d991..a4e250f9af61f2 100644 --- a/var/spack/repos/builtin/packages/sw4/package.py +++ b/var/spack/repos/builtin/packages/sw4/package.py @@ -20,6 +20,9 @@ class Sw4(MakefilePackage): version("developer", branch="developer") version("3.0", tag="v3.0", commit="13e6d431976f7fc49124c997bf87353aa7afd35e") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=True, description="build with OpenMP") variant("hdf5", default=True, description="build with HDF5") variant("proj", default=True, description="build with proj") diff --git a/var/spack/repos/builtin/packages/swan/package.py b/var/spack/repos/builtin/packages/swan/package.py index e510cb90f331bc..d88c7bf1f1bff7 100644 --- a/var/spack/repos/builtin/packages/swan/package.py +++ b/var/spack/repos/builtin/packages/swan/package.py @@ -32,6 +32,8 @@ class Swan(MakefilePackage): version("4141", sha256="5d411e6602bd4ef764f6c7d23e5e25b588e955cb21a606d6d8a7bc4c9393aa0a") + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("netcdf-fortran") depends_on("perl", type="build") diff --git a/var/spack/repos/builtin/packages/swap-assembler/package.py b/var/spack/repos/builtin/packages/swap-assembler/package.py index ef7c2eb7d813ad..56c31d94391500 100644 --- a/var/spack/repos/builtin/packages/swap-assembler/package.py +++ b/var/spack/repos/builtin/packages/swap-assembler/package.py @@ -16,6 +16,8 @@ class SwapAssembler(MakefilePackage): version("0.4", sha256="45632e25578aacfbacd76df9697cbc798e09ac92284d9c9c07be15e0eb348e0d") + depends_on("cxx", type="build") # generated + depends_on("mpich") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/swarm/package.py b/var/spack/repos/builtin/packages/swarm/package.py index 9bcc5b9b2771dd..7837296ff43024 100644 --- a/var/spack/repos/builtin/packages/swarm/package.py +++ b/var/spack/repos/builtin/packages/swarm/package.py @@ -17,6 +17,8 @@ class Swarm(MakefilePackage): version("3.0.0", sha256="b63761a9914ebf1fee14befaffd93af9c795b692c006c644d049a6d985b55810") version("2.1.13", sha256="ec4b22cc1874ec6d2c89fe98e23a2fb713aec500bc4a784f0556389d22c02650") + depends_on("cxx", type="build") # generated + conflicts("@2.1.13", when="target=aarch64:") build_directory = "src" diff --git a/var/spack/repos/builtin/packages/swftools/package.py b/var/spack/repos/builtin/packages/swftools/package.py index ecf06eb8d3cabb..8fbdc29189256e 100644 --- a/var/spack/repos/builtin/packages/swftools/package.py +++ b/var/spack/repos/builtin/packages/swftools/package.py @@ -21,6 +21,9 @@ class Swftools(AutotoolsPackage): version("0.9.2", sha256="bf6891bfc6bf535a1a99a485478f7896ebacbe3bbf545ba551298080a26f01f1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + patch("configure.patch") patch("swfs_Makefile.in.patch") patch( diff --git a/var/spack/repos/builtin/packages/swiftsim/package.py b/var/spack/repos/builtin/packages/swiftsim/package.py index 5bb38e1bebcbd5..a92e992a74ed7f 100644 --- a/var/spack/repos/builtin/packages/swiftsim/package.py +++ b/var/spack/repos/builtin/packages/swiftsim/package.py @@ -23,6 +23,8 @@ class Swiftsim(AutotoolsPackage): version("0.7.0", sha256="d570e83e1038eb31bc7ae95d1903a2371fffbca90d08f60b6b32bb0fd8a6f516") version("0.3.0", sha256="dd26075315cb2754dc1292e8d838bbb83739cff7f068a98319b80b9c2b0f84bc") + depends_on("c", type="build") # generated + variant("mpi", default=True, description="Enable distributed memory parallelism") # Build dependencies diff --git a/var/spack/repos/builtin/packages/swig/package.py b/var/spack/repos/builtin/packages/swig/package.py index 99e35b1b3e4b87..93893d8ddaf6b6 100644 --- a/var/spack/repos/builtin/packages/swig/package.py +++ b/var/spack/repos/builtin/packages/swig/package.py @@ -69,6 +69,9 @@ class Swig(AutotoolsPackage, SourceforgePackage): url="https://github.com/swig-fortran/swig/archive/v4.0.2+fortran.tar.gz", ) + depends_on("c", type="build") + depends_on("cxx", type="build") + depends_on("pcre", when="@:4.0") depends_on("pcre2", when="@4.1:") depends_on("zlib-api") @@ -148,7 +151,7 @@ class AutotoolsBuilder(spack.build_systems.autotools.AutotoolsBuilder): def create_symlink(self): # CMake compatibility: see https://github.com/spack/spack/pull/6240 with working_dir(self.prefix.bin): - os.symlink("swig", "swig{0}".format(self.spec.version.up_to(2))) + os.symlink("swig", "swig{0}.0".format(self.spec.version.up_to(1))) @when(Swig.AUTOCONF_VERSIONS) def autoreconf(self, pkg, spec, prefix): diff --git a/var/spack/repos/builtin/packages/swipl/package.py b/var/spack/repos/builtin/packages/swipl/package.py index 3d4db45c9c5a27..3942c0ceb8063b 100644 --- a/var/spack/repos/builtin/packages/swipl/package.py +++ b/var/spack/repos/builtin/packages/swipl/package.py @@ -27,6 +27,9 @@ class Swipl(CMakePackage): version("8.2.0", sha256="d8c9f3adb9cd997a5fed7b5f5dbfe971d2defda969b9066ada158e4202c09c3c") version("8.0.3", sha256="cee59c0a477c8166d722703f6e52f962028f3ac43a5f41240ecb45dbdbe2d6ae") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("gmp", default=True, description="bignum and rational number support") variant("xpce", default=True, description="GUI support") variant("ssl", default=True, description="SSL support") diff --git a/var/spack/repos/builtin/packages/symengine/package.py b/var/spack/repos/builtin/packages/symengine/package.py index 68f45f6139700f..e46081268862f1 100644 --- a/var/spack/repos/builtin/packages/symengine/package.py +++ b/var/spack/repos/builtin/packages/symengine/package.py @@ -30,6 +30,9 @@ class Symengine(CMakePackage): version("0.2.0", sha256="64d050b0b9decd12bf4ea3b7d18d3904dd7cb8baaae9fbac1b8068e3c59709be") version("0.1.0", sha256="daba3ba0ae91983a772f66bf755b1953c354fe6dc353588b23705d9a79b011fc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "boostmp", default=False, description="Compile with Boost multi-precision integer library" ) diff --git a/var/spack/repos/builtin/packages/symlinks/package.py b/var/spack/repos/builtin/packages/symlinks/package.py index 5d5f8cef227a4b..b6ba210f1df785 100644 --- a/var/spack/repos/builtin/packages/symlinks/package.py +++ b/var/spack/repos/builtin/packages/symlinks/package.py @@ -14,6 +14,8 @@ class Symlinks(MakefilePackage): version("1.4", sha256="b0bb689dd0a2c46d9a7dd111b053707aba7b9cf29c4f0bad32984b14bdbe0399") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): filter_file("/usr/local", prefix, "Makefile", string=True) filter_file("-o root -g root", "", "Makefile") diff --git a/var/spack/repos/builtin/packages/sympack/package.py b/var/spack/repos/builtin/packages/sympack/package.py index 7796aa224678ba..211265ab01a693 100644 --- a/var/spack/repos/builtin/packages/sympack/package.py +++ b/var/spack/repos/builtin/packages/sympack/package.py @@ -22,6 +22,9 @@ class Sympack(CMakePackage, CudaPackage): version("2.0.1", sha256="21c172e902531c94c3bb5932c15de4b4ec9adf9c0d8e2071bb12cdbdfa25ca52") version("2.0", sha256="93fcfbadab73718e249e7ed12641a3c6be58b19cafdf6bad12a6a09c3d1eb4a1") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@3.11:", type="build") depends_on("upcxx@2019.9.0:") diff --git a/var/spack/repos/builtin/packages/sympol/package.py b/var/spack/repos/builtin/packages/sympol/package.py index 45511c400e998d..325d8e1317874b 100644 --- a/var/spack/repos/builtin/packages/sympol/package.py +++ b/var/spack/repos/builtin/packages/sympol/package.py @@ -18,6 +18,9 @@ class Sympol(CMakePackage): version("0.1.8", sha256="8f4c013fa563e696fc8c27c408fd1f3d47783639815e8141e3a99826f1f3d54f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@2.6:", type="build") depends_on("bliss") diff --git a/var/spack/repos/builtin/packages/sys-sage/package.py b/var/spack/repos/builtin/packages/sys-sage/package.py index c96dd329a39d0a..cc5c1895b38e7d 100644 --- a/var/spack/repos/builtin/packages/sys-sage/package.py +++ b/var/spack/repos/builtin/packages/sys-sage/package.py @@ -21,6 +21,8 @@ class SysSage(CMakePackage): version("master", branch="master") version("develop", branch="develop") + depends_on("cxx", type="build") # generated + conflicts("%gcc@:7", msg="gcc can be used from version 8 and above") variant( diff --git a/var/spack/repos/builtin/packages/sysbench/package.py b/var/spack/repos/builtin/packages/sysbench/package.py index b1843bf49d9cb4..768220ea9b908e 100644 --- a/var/spack/repos/builtin/packages/sysbench/package.py +++ b/var/spack/repos/builtin/packages/sysbench/package.py @@ -18,6 +18,9 @@ class Sysbench(AutotoolsPackage): version("1.0.19", sha256="39cde56b58754d97b2fe6a1688ffc0e888d80c262cf66daee19acfb2997f9bdd") version("1.0.18", sha256="c679b285e633c819d637bdafaeacc1bec13f37da5b3357c7e17d97a71bf28cb1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/syscalc/package.py b/var/spack/repos/builtin/packages/syscalc/package.py index eb59fef8c4a262..c266720811ace4 100644 --- a/var/spack/repos/builtin/packages/syscalc/package.py +++ b/var/spack/repos/builtin/packages/syscalc/package.py @@ -19,6 +19,9 @@ class Syscalc(MakefilePackage): extension=".tgz", ) + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + tags = ["hep"] depends_on("lhapdf@6:") diff --git a/var/spack/repos/builtin/packages/sysfsutils/package.py b/var/spack/repos/builtin/packages/sysfsutils/package.py index b2267ef7218d67..99a372849790c4 100644 --- a/var/spack/repos/builtin/packages/sysfsutils/package.py +++ b/var/spack/repos/builtin/packages/sysfsutils/package.py @@ -23,6 +23,8 @@ class Sysfsutils(AutotoolsPackage): version("0_4_0", sha256="9c78edb118c6bd962e04558ddb2df46d456273284fe3f23bb930dc287225aea5") version("0_3_0", sha256="f10250aa09513d245cb4ed61ac0dbfd7dfb2e7810bcd8804a07b3fe18f08a74a") + depends_on("c", type="build") # generated + @when("target=aarch64:") def configure_args(self): args = ["--build=arm-linux"] diff --git a/var/spack/repos/builtin/packages/sysget/package.py b/var/spack/repos/builtin/packages/sysget/package.py index bbad2d22448e45..afb5106025618a 100644 --- a/var/spack/repos/builtin/packages/sysget/package.py +++ b/var/spack/repos/builtin/packages/sysget/package.py @@ -21,6 +21,8 @@ class Sysget(MakefilePackage): version("2.2", sha256="8f55ee8402d6de3cc16fa0577148b484e35da6688ad5f3ee3e9c1be04c88863a") version("2.1", sha256="0590aaae10494ca76c6749264925feb0e40b6e4b3822a8a4d148761addcb66c1") + depends_on("cxx", type="build") # generated + def edit(self, spec, prefix): if os.path.exists("Makefile"): makefile = FileFilter("Makefile") diff --git a/var/spack/repos/builtin/packages/sysstat/package.py b/var/spack/repos/builtin/packages/sysstat/package.py index e4fab86b95cfd7..c70c052a5a3b6f 100644 --- a/var/spack/repos/builtin/packages/sysstat/package.py +++ b/var/spack/repos/builtin/packages/sysstat/package.py @@ -20,6 +20,8 @@ class Sysstat(AutotoolsPackage): version("12.4.5", sha256="4e35abdd9eaf766ecdab55786f459093f3e1c350db23e57a15561afda417ff0d") version("12.2.0", sha256="614ab9fe8e7937a3edb7b2b6760792a3764ea3a7310ac540292dd0e3dfac86a6") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("gettext") depends_on("lm-sensors") diff --git a/var/spack/repos/builtin/packages/systemc/package.py b/var/spack/repos/builtin/packages/systemc/package.py index 403bbf28a224f9..89ed1c6bec5ce9 100644 --- a/var/spack/repos/builtin/packages/systemc/package.py +++ b/var/spack/repos/builtin/packages/systemc/package.py @@ -19,6 +19,9 @@ class Systemc(CMakePackage): version("2.3.3", sha256="5781b9a351e5afedabc37d145e5f7edec08f3fd5de00ffeb8fa1f3086b1f7b3f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "cxxstd", values=("11", "14", "17", "20"), diff --git a/var/spack/repos/builtin/packages/systemd/package.py b/var/spack/repos/builtin/packages/systemd/package.py new file mode 100644 index 00000000000000..da78562d9537d4 --- /dev/null +++ b/var/spack/repos/builtin/packages/systemd/package.py @@ -0,0 +1,143 @@ +# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + + +class Systemd(MesonPackage): + """systemd is a suite of basic building blocks for a Linux system. + It provides a system and service manager that runs as PID 1 and + starts the rest of the system.""" + + homepage = "https://systemd.io/" + url = "https://github.com/systemd/systemd/archive/refs/tags/v255.tar.gz" + license("GPL-2.0-only") + + version("255", sha256="28854ffb2cb5f9e07fcbdbaf1e03a80b3462a12edeef84893ca2f37b22e4491e") + + depends_on("c", type="build") # generated + + depends_on("meson@0.60.0:", type="build") + depends_on("ninja", type="build") + depends_on("py-jinja2", type="build") + depends_on("util-linux@2.30:") # libmount + depends_on("gperf") + depends_on("libcap") + depends_on("pkgconfig") + + conflicts("%gcc@:8.4") + conflicts("%clang@:7") + + def meson_args(self): + # Setting prefix is required here because without this the installation + # prefix would be repeated twice because of the required use of DESTDIR + # during the install phase. + # Similarly libdir must be set to prevent the regular prefix path from + # influencing the placement of the installed files. + args = [ + "-Dprefix=/", + "-Dlibdir=/lib", + "-Dlibidn2=disabled", + "-Dopenssl=disabled", + "-Dpcre2=disabled", + "-Dinitrd=false", + "-Dresolve=false", + "-Defi=false", + "-Dtpm=false", + "-Dcreate-log-dirs=false", + "-Dseccomp=disabled", + "-Dselinux=disabled", + "-Dapparmor=disabled", + "-Dsmack=false", + "-Dpolkit=disabled", + "-Dima=false", + "-Dacl=disabled", + "-Daudit=disabled", + "-Dblkid=disabled", + "-Dfdisk=disabled", + "-Dkmod=false", + "-Dpam=disabled", + "-Dpasswdqc=disabled", + "-Dpwquality=disabled", + "-Dmicrohttpd=disabled", + "-Dlibcryptsetup=disabled", + "-Dlibcurl=disabled", + "-Dlibiptc=disabled", + "-Dqrencode=disabled", + "-Dgcrypt=disabled", + "-Dgnutls=disabled", + "-Dp11kit=disabled", + "-Dlibfido2=disabled", + "-Dtpm2=disabled", + "-Delfutils=disabled", + "-Dzlib=disabled", + "-Dbzip2=disabled", + "-Dxz=disabled", + "-Dlz4=disabled", + "-Dzstd=disabled", + "-Dxkbcommon=disabled", + "-Dbootloader=disabled", + "-Dnscd=false", # support for... + "-Dutmp=false", + "-Dhibernate=false", + "-Dldconfig=false", + "-Denvironment-d=false", + "-Dbinfmt=false", + "-Dremote=disabled", + "-Dfirstboot=false", + "-Drandomseed=false", + "-Dbacklight=false", + "-Dvconsole=false", + "-Dvmspawn=disabled", + "-Dquotacheck=false", + "-Dsysusers=false", + "-Dstoragetm=false", + "-Dtmpfiles=false", + "-Dimportd=disabled", + "-Dhwdb=false", + "-Drfkill=false", + "-Dgshadow=false", + "-Dkmod=disabled", + "-Dxenctrl=disabled", + "-Drepart=disabled", # install the... + "-Dsysupdate=disabled", + "-Dcoredump=false", + "-Dpstore=false", + "-Doomd=false", + "-Dlogind=false", + "-Dhostnamed=false", + "-Dlocaled=false", + "-Dmachined=false", + "-Dportabled=false", + "-Dsysext=false", + "-Duserdb=false", + "-Dhomed=disabled", + "-Dnetworkd=false", + "-Dtimedated=false", + "-Dtimesyncd=false", + "-Dxdg-autostart=false", + "-Ddefault-network=false", # install... + "-Dnss-myhostname=false", + "-Dnss-mymachines=disabled", + "-Dnss-resolve=disabled", + "-Dnss-systemd=false", + "-Dhtml=disabled", + "-Dtranslations=false", + "-Dinstall-sysconfdir=false", + "-Dkernel-install=false", + "-Dukify=disabled", + "-Danalyze=false", + ] + + return args + + def install(self, spec, prefix): + # DESTDIR is required because without it the install phase will attempt + # to install files in the root file system by default. + os.environ["DESTDIR"] = prefix + with working_dir(self.build_directory): + ninja("install") diff --git a/var/spack/repos/builtin/packages/systemtap/package.py b/var/spack/repos/builtin/packages/systemtap/package.py index 8e5a3184489786..e7132981cf337e 100644 --- a/var/spack/repos/builtin/packages/systemtap/package.py +++ b/var/spack/repos/builtin/packages/systemtap/package.py @@ -24,6 +24,9 @@ class Systemtap(AutotoolsPackage): version("4.2", sha256="0984ebe3162274988252ec35074021dc1e8420d87a8b35f437578562fce08781") version("4.1", sha256="8efa1ee2b34f1c6b2f33a25313287d59c8ed1b00265e900aea874da8baca1e1d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("gettext") depends_on("elfutils@0.151:") depends_on("sqlite") diff --git a/var/spack/repos/builtin/packages/sz-cpp/package.py b/var/spack/repos/builtin/packages/sz-cpp/package.py index f59ea178fcb271..c76174fb4e9aeb 100644 --- a/var/spack/repos/builtin/packages/sz-cpp/package.py +++ b/var/spack/repos/builtin/packages/sz-cpp/package.py @@ -16,6 +16,8 @@ class SzCpp(CMakePackage): version("2022-01-27", commit="9441b79abc89d4bcce53fe18edf0df53fd92d1d7") + depends_on("cxx", type="build") # generated + variant("shared", description="build shared libs", default=True) depends_on("zstd") diff --git a/var/spack/repos/builtin/packages/sz/package.py b/var/spack/repos/builtin/packages/sz/package.py index 30c9faa74fbeee..22c08a12817b7e 100644 --- a/var/spack/repos/builtin/packages/sz/package.py +++ b/var/spack/repos/builtin/packages/sz/package.py @@ -46,12 +46,17 @@ class Sz(CMakePackage, AutotoolsPackage): version("1.4.10.0", sha256="cf23cf1ffd7c69c3d3128ae9c356b6acdc03a38f92c02db5d9bfc04f3fabc506") version("1.4.9.2", sha256="9dc785274d068d04c2836955fc93518a9797bfd409b46fea5733294b7c7c18f8") + depends_on("c", type="build") + depends_on("cxx", type="build") + build_system( conditional("autotools", when="@:2.1.8.0"), conditional("cmake", when="@2.1.8.1:"), default="cmake", ) + variant("openmp", default=False, description="build the multithreaded version using openmp") + variant("examples", default=False, description="build examples") variant("python", default=False, description="builds the python wrapper") variant("netcdf", default=False, description="build the netcdf reader") variant("hdf5", default=False, description="build the hdf5 filter") @@ -201,6 +206,8 @@ def cmake_args(self): self.define_from_variant("BUILD_STATS", "stats"), self.define("BUILD_TESTS", self.pkg.run_tests), self.define_from_variant("BUILD_PYTHON_WRAPPER", "python"), + self.define_from_variant("BUILD_OPENMP", "openmp"), + self.define_from_variant("BUILD_SZ_EXAMPLES", "examples"), ] if "+python" in self.spec: diff --git a/var/spack/repos/builtin/packages/sz3/package.py b/var/spack/repos/builtin/packages/sz3/package.py index 9e94f347059d2f..5722cced398384 100644 --- a/var/spack/repos/builtin/packages/sz3/package.py +++ b/var/spack/repos/builtin/packages/sz3/package.py @@ -16,12 +16,16 @@ class Sz3(CMakePackage): tags = ["e4s"] version("master") + version("3.1.8", commit="e308ebf8528c233286874b920c72c0a6c0218fb2") version("3.1.7", commit="c49fd17f2d908835c41000c1286c510046c0480e") version("3.1.5.4", commit="4c6ddf628f27d36b28d1bbda02174359cd05573d") version("3.1.5.1", commit="5736a63b917e439dd62248b4ff6234e96726af5d") version("3.1.3.1", commit="323cb17b412d657c4be681b52c34beaf933fe7af") version("3.1.3", commit="695dff8dc326f3b165f6676d810f46add088a585") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("hdf5", default=False, description="enable hdf5 filter support") variant("mdz", default=True, description="build mdz executable") @@ -42,12 +46,18 @@ def cmake_args(self): self.define_from_variant("BUILD_H5Z_FILTER", "hdf5"), ] - def test(self): + def test_sz3_smoke_test(self): + """Run sz3 smoke test""" if self.spec.satisfies("@:3.1.6"): - print("smoke tests are only supported on 3.1.7 and later, skipping") - return - - self.run_test(self.prefix.bin.sz3_smoke_test, purpose="sz3 works") + raise SkipTest("Package must be installed as version 3.1.7 or later") + exe = which(self.prefix.bin.sz3_smoke_test) + exe() - if "+mdz" in self.spec: - self.run_test(self.prefix.bin.mdz_smoke_test, purpose="mdz works") + def test_mdz_smoke_test(self): + """Run mdz smoke test""" + if self.spec.satisfies("@:3.1.6"): + raise SkipTest("Package must be installed as version 3.1.7 or later") + if "+mdz" not in self.spec: + raise SkipTest("Package must be installed with '+mdz'") + exe = which(self.prefix.bin.mdz_smoke_test) + exe() diff --git a/var/spack/repos/builtin/packages/szauto/package.py b/var/spack/repos/builtin/packages/szauto/package.py index 02c19e38bf5fd1..b470291068ff26 100644 --- a/var/spack/repos/builtin/packages/szauto/package.py +++ b/var/spack/repos/builtin/packages/szauto/package.py @@ -19,5 +19,8 @@ class Szauto(CMakePackage): version("1.2.1", sha256="55c58f58df3a874f684ef864a9247907df0501e5598c089fd2d855ae0309b03a") version("1.0.0", commit="03f3ab0312bd1de647e9d65746add73a0e8602d2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zstd") depends_on("pkgconfig") diff --git a/var/spack/repos/builtin/packages/szx/package.py b/var/spack/repos/builtin/packages/szx/package.py new file mode 100644 index 00000000000000..9d05663fceb0ed --- /dev/null +++ b/var/spack/repos/builtin/packages/szx/package.py @@ -0,0 +1,51 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class Szx(CMakePackage, AutotoolsPackage, CudaPackage): + """An ultra fast error bounded compressor for scientific datasets""" + + homepage = "https://github.com/szcompressor/szx" + url = "https://github.com/szcompressor/SZx/archive/refs/tags/1.1.1.tar.gz" + git = "https://github.com/szcompressor/szx" + + maintainers = ["robertu94"] + + version("main", branch="main") + version("1.1.1", commit="b1609dde7702135b647fb92f91833fc84de2492e") + version("1.1.0", commit="194a9dc91ee8c46632f79de3c87a63ec29c52b26") + + depends_on("cxx", type="build") # generated + build_system( + conditional("cmake", when="@1.1.1:"), + conditional("autotools", when="@:1.1.0"), + default="cmake", + ) + + variant("cli", default=True, description="install the CLI", when="@1.1.1:") + variant("examples", default=False, description="install the examples", when="@1.1.1:") + conflicts("+cuda", when="@:1.1.0") + + with when("build_system=autotools"): + depends_on("autoconf", type="build") + depends_on("automake", type="build") + depends_on("libtool", type="build") + + class AutotoolsBuilder(spack.build_systems.autotools.AutotoolsBuilder): + force_autoreconf = True + + def configure_args(self): + args = ["--enable-openmp", "--enable-fortran"] + return args + + class CMakeBuilder(spack.build_systems.cmake.CMakeBuilder): + def cmake_args(self): + args = [ + self.define_from_variant("SZx_INSTALL_CLI", "cli"), + self.define_from_variant("SZx_INSTALL_EXAMPLES", "examples"), + self.define_from_variant("SZx_BUILD_CUDA", "cuda"), + ] + return args diff --git a/var/spack/repos/builtin/packages/t8code/package.py b/var/spack/repos/builtin/packages/t8code/package.py index 79f3b07930c7d9..50cb91b6da83f6 100644 --- a/var/spack/repos/builtin/packages/t8code/package.py +++ b/var/spack/repos/builtin/packages/t8code/package.py @@ -20,8 +20,15 @@ class T8code(AutotoolsPackage): license("GPL-2.0-or-later") + version("2.0.0", sha256="b83f6c204cdb663cec7e0c1059406afc4c06df236b71d7b190fb698bec44c1e0") + version("1.6.1", sha256="dc96effa7c1ad1d50437fefdd0963f6ef7c943eb10a372a4e8546a5f2970a412") + version("1.6.0", sha256="94fb8dd9d9401130867ff18e8f71249cbb0fc34995fd04412a983eb2c93db3d5") + version("1.5.0", sha256="22ce6492c0f808c6859a42921352d857639fddd48ecdc9935e419db95c466f28") version("1.4.1", sha256="b0ec0c9b4a182f8ac7e930ba80cd20e6dc5baefc328630e4a9dac8c688749e9a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Enable MPI parallel code") variant("vtk", default=False, description="Enable vtk-dependent code") variant("petsc", default=False, description="Enable PETSc-dependent code") diff --git a/var/spack/repos/builtin/packages/tabix/package.py b/var/spack/repos/builtin/packages/tabix/package.py index 7ae1e07804c4eb..5f3c28f7d4aad5 100644 --- a/var/spack/repos/builtin/packages/tabix/package.py +++ b/var/spack/repos/builtin/packages/tabix/package.py @@ -14,6 +14,8 @@ class Tabix(MakefilePackage): version("2013-12-16", commit="1ae158ac79b459f5feeed7490c67519b14ce9f35") + depends_on("c", type="build") # generated + depends_on("perl", type=("build", "run")) depends_on("python", type=("build", "run")) depends_on("zlib-api", type="link") diff --git a/var/spack/repos/builtin/packages/talass/package.py b/var/spack/repos/builtin/packages/talass/package.py index d98e7d01ce5521..56c4d7e6eed858 100644 --- a/var/spack/repos/builtin/packages/talass/package.py +++ b/var/spack/repos/builtin/packages/talass/package.py @@ -22,6 +22,8 @@ class Talass(CMakePackage): version("process-statistics", branch="process-statistics") version("2018-10-29", commit="5d459c0dd89e733fa301391908a5b79fe2850ad7") + depends_on("cxx", type="build") # generated + # The default precision and index space sizes variant( "precision", diff --git a/var/spack/repos/builtin/packages/talloc/package.py b/var/spack/repos/builtin/packages/talloc/package.py index 567950dcdcd543..58fda93013561b 100644 --- a/var/spack/repos/builtin/packages/talloc/package.py +++ b/var/spack/repos/builtin/packages/talloc/package.py @@ -15,10 +15,13 @@ class Talloc(AutotoolsPackage): license("LGPL-3.0-or-later") + version("2.4.2", sha256="85ecf9e465e20f98f9950a52e9a411e14320bc555fa257d87697b7e7a9b1d8a6") version("2.4.0", sha256="6df36862c42466ef88f360444513870ef46934f9016c84383cc4008a7d0c46ba") version("2.3.1", sha256="ef4822d2fdafd2be8e0cabc3ec3c806ae29b8268e932c5e9a4cd5585f37f9f77") version("2.3.0", sha256="75d5bcb34482545a82ffb06da8f6c797f963a0da450d0830c669267b14992fc6") version("2.1.9", sha256="f0aad4cb88a3322207c82136ddc07bed48a37c2c21f82962d6c5ccb422711062") + depends_on("c", type="build") # generated + extends("python") depends_on("python@3:") diff --git a/var/spack/repos/builtin/packages/tamaas/package.py b/var/spack/repos/builtin/packages/tamaas/package.py index 298287e463b98d..57ce90a4717181 100644 --- a/var/spack/repos/builtin/packages/tamaas/package.py +++ b/var/spack/repos/builtin/packages/tamaas/package.py @@ -17,7 +17,10 @@ class Tamaas(SConsPackage): maintainers("prs513rosewood") version("master", branch="master") - version("2.6.0", sha256="e3a262e5b893aa1e23554b6bd6b41af68c841ef4ffd862bb8e50a1a17ac15af6") + version("2.8.0", sha256="8ec49bf484a622c0554452416d1804eefbd545da79ced352f2ea63bbd17c83f0") + version("2.7.1", sha256="d7de6db3f5532bb9c8ab7e8cca1cdb5c133050dd5720249dde07027b0d41641f") + version("2.7.0", sha256="bc5717c1ead621cb9c18a073fdafbe8778fd160ad23d80c98283445d79066579") + version("2.6.0", sha256="4aafa0f727f43afc6ae45705ae80cf113a6a95e728bdf536c22b3b39be87f153") version( "2.5.0.post1", sha256="28e52dc5b8a5f77588c73a6ef396c44c6a8e9d77e3e4929a4ab07232dc9bc565" ) @@ -25,6 +28,8 @@ class Tamaas(SConsPackage): version("2.3.1", sha256="7d63e374cbc7b5b93578ece7be5c084d1c2f0dbe1d57c4f0c8abd5ff5fff9ab0") version("2.3.0", sha256="0529e015c6cb5bbabaea5dce6efc5ec0f2aa76c00541f0d90ad0e2e3060a4520") + depends_on("cxx", type="build") # generated + variant("python", default=True, description="Provide Python bindings for Tamaas") variant( "solvers", @@ -32,6 +37,7 @@ class Tamaas(SConsPackage): when="+python", description="Enables extra Scipy-based nonlinear solvers", ) + variant("petsc", default=False, when="@2.8.0:", description="Additional PETSc solvers") # Python 3.6 causes unicode issues with scons depends_on("python@3.7:", type="build", when="~python") @@ -46,6 +52,10 @@ class Tamaas(SConsPackage): conflicts("%clang@:5") conflicts("%intel") + # MPI type-traits issues (constexpr vs static const) in recent gcc + # fixed for tamaas versions > 2.6.0 + patch("recent_compilers.patch", when="@:2.6.0%gcc@11:") + with when("+python"): extends("python") depends_on("python@3.7:", type=("build", "run")) @@ -53,6 +63,9 @@ class Tamaas(SConsPackage): depends_on("py-scipy", when="+solvers", type="run") depends_on("py-pybind11", type="build") depends_on("py-wheel", type="build") + depends_on("py-pip", type="build") + + depends_on("petsc", type="build", when="+petsc") def build_args(self, spec, prefix): args = [ @@ -76,4 +89,17 @@ def build_args(self, spec, prefix): if spec.satisfies("+python"): args += ["PYBIND11_ROOT={}".format(spec["py-pybind11"].prefix)] + if spec.satisfies("+petsc"): + args += ["PETSC_ROOT={}".format(spec["petsc"].prefix), "use_petsc=True"] + return args + + def install(self, spec, prefix): + """Install the package.""" + args = self.install_args(spec, prefix) + + scons("install-lib", *args) + + if spec.satisfies("+python"): + args = ["-m", "pip"] + std_pip_args + ["--prefix=" + prefix, "build-release/python"] + python(*args) diff --git a/var/spack/repos/builtin/packages/tamaas/recent_compilers.patch b/var/spack/repos/builtin/packages/tamaas/recent_compilers.patch new file mode 100644 index 00000000000000..11a288ed164d00 --- /dev/null +++ b/var/spack/repos/builtin/packages/tamaas/recent_compilers.patch @@ -0,0 +1,57 @@ +diff --git a/src/core/mpi_interface.cpp b/src/core/mpi_interface.cpp +index e7f9f72..f602fb1 100644 +--- a/src/core/mpi_interface.cpp ++++ b/src/core/mpi_interface.cpp +@@ -36,6 +36,30 @@ comm& comm::world() { + static comm _world{MPI_COMM_WORLD}; + return _world; + } ++ ++// Define type traits for MPI data types ++#define TYPE(t, mpi_t) \ ++ const MPI_Datatype type_trait::value { mpi_t } ++TYPE(double, MPI_DOUBLE); ++TYPE(int, MPI_INT); ++TYPE(unsigned int, MPI_UNSIGNED); ++TYPE(long double, MPI_LONG_DOUBLE); ++TYPE(long, MPI_LONG); ++TYPE(unsigned long, MPI_UNSIGNED_LONG); ++TYPE(::thrust::complex, MPI_CXX_DOUBLE_COMPLEX); ++TYPE(::thrust::complex, MPI_CXX_LONG_DOUBLE_COMPLEX); ++TYPE(bool, MPI_CXX_BOOL); ++#undef TYPE ++ ++// Define type traits for MPI operations ++#define OPERATION(op, mpi_op) \ ++ const MPI_Op operation_trait::value { mpi_op } ++OPERATION(plus, MPI_SUM); ++OPERATION(min, MPI_MIN); ++OPERATION(max, MPI_MAX); ++OPERATION(times, MPI_PROD); ++#undef OPERATION ++ + } // namespace mpi_impl + #endif + +diff --git a/src/core/mpi_interface.hh b/src/core/mpi_interface.hh +index b4cfc81..b53c826 100644 +--- a/src/core/mpi_interface.hh ++++ b/src/core/mpi_interface.hh +@@ -149,7 +149,7 @@ struct type_trait; + #define TYPE(t, mpi_t) \ + template <> \ + struct type_trait { \ +- static constexpr MPI_Datatype value = mpi_t; \ ++ static const MPI_Datatype value; \ + } + TYPE(double, MPI_DOUBLE); + TYPE(int, MPI_INT); +@@ -168,7 +168,7 @@ struct operation_trait; + #define OPERATION(op, mpi_op) \ + template <> \ + struct operation_trait { \ +- static constexpr MPI_Op value = mpi_op; \ ++ static const MPI_Op value; \ + } + OPERATION(plus, MPI_SUM); + OPERATION(min, MPI_MIN); diff --git a/var/spack/repos/builtin/packages/tandem/package.py b/var/spack/repos/builtin/packages/tandem/package.py index b9cc617e0ef941..3211f5724f4f99 100644 --- a/var/spack/repos/builtin/packages/tandem/package.py +++ b/var/spack/repos/builtin/packages/tandem/package.py @@ -25,6 +25,9 @@ class Tandem(CMakePackage, CudaPackage, ROCmPackage): "1.1.0", tag="v1.1.0", commit="17c42dc9ae0ec519dcc1b5732681b2e4054666f1", submodules=True ) version("1.0", tag="v1.0", commit="eccab10cbdf5842ed9903fac7a023be5e2779f36", submodules=True) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated patch("fix_v1.0_compilation.diff", when="@1.0") maintainers("dmay23", "Thomas-Ulrich") diff --git a/var/spack/repos/builtin/packages/tangram/package.py b/var/spack/repos/builtin/packages/tangram/package.py index 4c0886d94c9ebc..b23d0cda0e793a 100644 --- a/var/spack/repos/builtin/packages/tangram/package.py +++ b/var/spack/repos/builtin/packages/tangram/package.py @@ -24,6 +24,9 @@ class Tangram(CMakePackage): version("1.0.1", sha256="8f2f8c01bb2d726b0f64e5a5bc3aa2bd8057ccaee7a29c68f1439d16e39aaa90") version("master", branch="master", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Enable interface reconstruction with MPI") variant("thrust", default=False, description="Enable on-node parallelism with NVidia Thrust") variant( diff --git a/var/spack/repos/builtin/packages/tar/package.py b/var/spack/repos/builtin/packages/tar/package.py index 7b5af9403c2b61..5fadb4229baadc 100644 --- a/var/spack/repos/builtin/packages/tar/package.py +++ b/var/spack/repos/builtin/packages/tar/package.py @@ -6,7 +6,6 @@ import re from spack.package import * -from spack.util.environment import is_system_path class Tar(AutotoolsPackage, GNUMirrorPackage): @@ -29,6 +28,8 @@ class Tar(AutotoolsPackage, GNUMirrorPackage): version("1.29", sha256="cae466e6e58c7292355e7080248f244db3a4cf755f33f4fa25ca7f9a7ed09af0") version("1.28", sha256="6a6b65bac00a127a508533c604d5bf1a3d40f82707d56f20cefd38a05e8237de") + depends_on("c", type="build") # generated + # A saner default than gzip? variant( "zip", @@ -74,10 +75,10 @@ def configure_args(self): "--with-bzip2={0}".format(spec["bzip2"].prefix.bin.bzip2), ] - if spec["iconv"].name == "libc": + if spec["iconv"].name == "libiconv": + args.append(f"--with-libiconv-prefix={spec['iconv'].prefix}") + else: args.append("--without-libiconv-prefix") - elif not is_system_path(spec["iconv"].prefix): - args.append("--with-libiconv-prefix={0}".format(spec["iconv"].prefix)) if "^zstd" in spec: args.append("--with-zstd={0}".format(spec["zstd"].prefix.bin.zstd)) diff --git a/var/spack/repos/builtin/packages/task/package.py b/var/spack/repos/builtin/packages/task/package.py index 65f71a6218d186..786127d604f046 100644 --- a/var/spack/repos/builtin/packages/task/package.py +++ b/var/spack/repos/builtin/packages/task/package.py @@ -14,12 +14,23 @@ class Task(CMakePackage): license("MIT") + version("3.0.0", sha256="30f397081044f5dc2e5a0ba51609223011a23281cd9947ea718df98d149fcc83") version("2.6.2", sha256="b1d3a7f000cd0fd60640670064e0e001613c9e1cb2242b9b3a9066c78862cfec") version("2.5.1", sha256="d87bcee58106eb8a79b850e9abc153d98b79e00d50eade0d63917154984f2a15") version("2.4.4", sha256="7ff406414e0be480f91981831507ac255297aab33d8246f98dbfd2b1b2df8e3b") + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8:", type="build") depends_on("gnutls") depends_on("uuid") + depends_on("rust@1.64.0:", when="@3.0.0:") conflicts("%gcc@:4.7") + + def patch(self): + if self.spec.satisfies("@3.0.0:"): + # new major release adds rust to the codebase. A bug in cmake/Corrosion + # causes release builds with the integration tests to fail. + # See https://github.com/GothenburgBitFactory/taskwarrior/issues/3294 + filter_file('"taskchampion/integration-tests",', "", "Cargo.toml") diff --git a/var/spack/repos/builtin/packages/taskflow/package.py b/var/spack/repos/builtin/packages/taskflow/package.py index 1e00312654a5b9..8be3f42b56f16d 100644 --- a/var/spack/repos/builtin/packages/taskflow/package.py +++ b/var/spack/repos/builtin/packages/taskflow/package.py @@ -18,9 +18,14 @@ class Taskflow(CMakePackage): license("MIT") version("master", branch="master") + version("3.7.0", sha256="788b88093fb3788329ebbf7c7ee05d1f8960d974985a301798df01e77e04233b") version("3.6.0", sha256="5a1cd9cf89f93a97fcace58fd73ed2fc8ee2053bcb43e047acb6bc121c3edf4c") version("2.7.0", sha256="bc2227dcabec86abeba1fee56bb357d9d3c0ef0184f7c2275d7008e8758dfc3e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Compiler must offer C++14 support conflicts("%gcc@:4.8") conflicts("%clang@:3.5") diff --git a/var/spack/repos/builtin/packages/tasmanian/package.py b/var/spack/repos/builtin/packages/tasmanian/package.py index c9285453f4dd9b..6a43c5ee04f1f1 100644 --- a/var/spack/repos/builtin/packages/tasmanian/package.py +++ b/var/spack/repos/builtin/packages/tasmanian/package.py @@ -34,6 +34,9 @@ class Tasmanian(CMakePackage, CudaPackage, ROCmPackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("xsdkflags", default=False, description="enable XSDK defaults for Tasmanian") variant("openmp", default=False, description="add OpenMP support to Tasmanian") diff --git a/var/spack/repos/builtin/packages/tau/package.py b/var/spack/repos/builtin/packages/tau/package.py index 1827282c55bbff..ed3aaafe405ae8 100644 --- a/var/spack/repos/builtin/packages/tau/package.py +++ b/var/spack/repos/builtin/packages/tau/package.py @@ -28,6 +28,7 @@ class Tau(Package): license("MIT") version("master", branch="master") + version("2.33.2", sha256="8ee81fe75507612379f70033183bed2a90e1245554b2a78196b6c5145da44f27") version("2.33.1", sha256="13cc5138e110932f34f02ddf548db91d8219ccb7ff9a84187f0790e40a502403") version("2.33", sha256="04d9d67adb495bc1ea56561f33c5ce5ba44f51cc7f64996f65bd446fac5483d9") version("2.32.1", sha256="0eec3de46b0873846dfc639270c5e30a226b463dd6cb41aa12e975b7563f0eeb") @@ -55,6 +56,10 @@ class Tau(Package): version("2.24", sha256="5d28e8b26561c7cd7d0029b56ec0f95fc26803ac0b100c98e00af0b02e7f55e2") version("2.23.1", sha256="31a4d0019cec6ef57459a9cd18a220f0130838a5f1a0b5ea7879853f5a38cf88") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Disable some default dependencies on Darwin/OSX darwin_default = False if sys.platform != "darwin": @@ -84,6 +89,7 @@ class Tau(Package): variant("level_zero", default=False, description="Activates Intel OneAPI Level Zero support") variant("rocprofiler", default=False, description="Activates ROCm rocprofiler support") variant("roctracer", default=False, description="Activates ROCm roctracer support") + variant("rocprofv2", default=False, description="Activates ROCm rocprofiler support") variant("opencl", default=False, description="Activates OpenCL support") variant("fortran", default=darwin_default, description="Activates Fortran support") variant("io", default=True, description="Activates POSIX I/O support") @@ -106,7 +112,15 @@ class Tau(Package): ) variant("dyninst", default=False, description="Activates dyninst support") + variant( + "disable-no-pie", + default=False, + description="Do not add -no-pie while linking with Ubuntu.", + ) + + depends_on("gmake", type="build") depends_on("cmake@3.14:", type="build", when="%clang") + depends_on("cmake@3.14:", type="build", when="%aocc") depends_on("zlib-api", type="link") depends_on("pdt", when="+pdt") # Required for TAU instrumentation depends_on("scorep", when="+scorep") @@ -118,10 +132,12 @@ class Tau(Package): depends_on("elf", when="+elf") # TAU requires the ELF header support, libiberty and demangle. depends_on("binutils+libiberty+headers+plugins", when="+binutils") - # Build errors with Python 3.9 - depends_on("python@2.7:3.8", when="@:2.31.0+python") - # python 3.11 doesn't work as of 2.32 - depends_on("python@2.7:3.10", when="@2.31.1:+python") + with when("+python"): + depends_on("python@2.7:") + # Build errors with Python 3.9 + depends_on("python@:3.8", when="@:2.31.0") + # python 3.11 doesn't work in the 2.32 releases + depends_on("python@:3.10", when="@:2.32.1") depends_on("libunwind", when="+libunwind") depends_on("mpi", when="+mpi", type=("build", "run", "link")) depends_on("cuda", when="+cuda") @@ -130,9 +146,12 @@ class Tau(Package): depends_on("sqlite", when="+sqlite") depends_on("hwloc") depends_on("rocprofiler-dev", when="+rocprofiler") + depends_on("rocprofiler-dev@6.0.0:", when="@2.34: +rocprofv2") depends_on("roctracer-dev", when="+roctracer") depends_on("hsa-rocr-dev", when="+rocm") depends_on("rocm-smi-lib", when="@2.32.1: +rocm") + depends_on("rocm-core", when="@2.34: +rocm") + depends_on("hip", when="@2.34: +roctracer") depends_on("java", type="run") # for paraprof depends_on("oneapi-level-zero", when="+level_zero") depends_on("dyninst@12.3.0:", when="+dyninst") @@ -145,9 +164,27 @@ class Tau(Package): conflicts("+adios2", when="@:2.29.1") conflicts("+sqlite", when="@:2.29.1") conflicts("+dyninst", when="@:2.32.1") - + conflicts("+disable-no-pie", when="@:2.33.2") patch("unwind.patch", when="@2.29.0") + conflicts("+rocprofiler", when="+roctracer", msg="Use either rocprofiler or roctracer") + conflicts("+rocprofv2", when="+rocprofiler", msg="Rocprofv2 does not need rocprofiler") + conflicts("+rocprofv2", when="+roctracer", msg="Rocprofv2 does not need roctracer") + requires("+rocm", when="+rocprofiler", msg="Rocprofiler requires ROCm") + requires("+rocm", when="+roctracer", msg="Roctracer requires ROCm") + + requires( + "+rocprofiler", + "+roctracer", + "+rocprofv2", + policy="one_of", + when="+rocm", + msg="Using ROCm, select either +rocprofiler, +roctracer or +rocprofv2", + ) + + # https://github.com/UO-OACISS/tau2/commit/1d2cb6b + patch("tau-rocm-disable-llvm-plugin.patch", when="@2.33.2 +rocm") + filter_compiler_wrappers("Makefile", relative_root="include") filter_compiler_wrappers("Makefile.tau*", relative_root="lib") filter_compiler_wrappers("Makefile.tau*", relative_root="lib64") @@ -220,9 +257,6 @@ def install(self, spec, prefix): if "+x86_64" in spec: options.append("-arch=x86_64") - if ("platform=cray" in self.spec) and ("+x86_64" not in spec): - options.append("-arch=craycnl") - if "+pdt" in spec: options.append("-pdt=%s" % spec["pdt"].prefix) if spec["pdt"].satisfies("%intel"): @@ -277,8 +311,8 @@ def install(self, spec, prefix): env["F77"] = spec["mpi"].mpif77 env["FC"] = spec["mpi"].mpifc if spec["mpi"].name == "intel-oneapi-mpi": - options.append("-mpiinc=%s" % spec["mpi"].package.component_prefix) - options.append("-mpilib=%s" % spec["mpi"].package.component_prefix) + options.append("-mpiinc=%s/include" % spec["mpi"].package.component_prefix) + options.append("-mpilib=%s/lib" % spec["mpi"].package.component_prefix) else: options.append("-mpiinc=%s" % spec["mpi"].prefix.include) options.append("-mpilib=%s" % spec["mpi"].prefix.lib) @@ -309,12 +343,20 @@ def install(self, spec, prefix): options.append("-rocm=%s" % spec["hsa-rocr-dev"].prefix) if spec.satisfies("@2.32.1"): options.append("-rocmsmi=%s" % spec["rocm-smi-lib"].prefix) + if spec.satisfies("@2.34:"): + options.append("-rocm-core=%s" % spec["rocm-core"].prefix) if "+rocprofiler" in spec: options.append("-rocprofiler=%s" % spec["rocprofiler-dev"].prefix) if "+roctracer" in spec: options.append("-roctracer=%s" % spec["roctracer-dev"].prefix) + if spec.satisfies("@2.34:"): + options.append("-hip=%s" % spec["hip"].prefix) + + if "+rocprofv2" in spec: + options.append("-rocprofiler=%s" % spec["rocprofiler-dev"].prefix) + options.append("-rocprofv2") if "+adios2" in spec: options.append("-adios=%s" % spec["adios2"].prefix) @@ -352,6 +394,8 @@ def install(self, spec, prefix): if found: break options.append("-pythonlib=%s" % lib_path) + if "+disable-no-pie" in spec: + options.append("-disable-no-pie-on-ubuntu") if "+dyninst" in spec: options.append("-dyninst=%s" % spec["dyninst"].prefix) @@ -412,6 +456,7 @@ def setup_run_environment(self, env): syscall_test = join_path("examples", "syscall") ompt_test = join_path("examples", "openmp", "c++") python_test = join_path("examples", "python") + disable_tests = False @run_after("install") def setup_build_tests(self): @@ -435,155 +480,106 @@ def setup_build_tests(self): if "+python" in self.spec: self.cache_extra_test_sources(self.python_test) - def _run_dyninst_test(self, test_dir): - dyn_dir = join_path(test_dir, self.dyninst_test) - flags = "serial" - if "+mpi" in self.spec: - flags = "mpi" - self.run_test("make", ["all"], [], 0, False, "Build example code", False, dyn_dir) - self.run_test( - "tau_run", - ["-T", flags, "./klargest", "-v", "-o", "./klargest.i"], - [], - 0, - False, - "Instrument code with dyninst", - False, - dyn_dir, - ) - self.run_test( - "./klargest.i", [], [], 0, False, "Execute instrumented code", False, dyn_dir - ) - self.run_test( - "pprof", - [], - [], - 0, - False, - "Run pprof profile analysis tool on profile output", - False, - dyn_dir, - ) - - def _run_tau_test( - self, main_test_dir, test_dir, test_name, test_exe, tau_exec_flags=[], use_tau_exec=False - ): - inst_test_dir = join_path(main_test_dir, test_dir) - print(inst_test_dir) - test_description = "Build {} test code".format(test_name) - self.run_test("make", ["all"], [], 0, False, test_description, False, inst_test_dir) - if "+mpi" in self.spec: - if use_tau_exec: - test_args = ["-n", "4", "tau_exec", "-T", "mpi"] + tau_exec_flags + def _run_python_test(self, test_name, purpose, work_dir): + tau_python = which(self.prefix.bin.tau_python) + tau_py_inter = "-tau-python-interpreter=" + self.spec["python"].prefix.bin.python + pprof = which(self.prefix.bin.pprof) + with test_part(self, f"{test_name}", purpose, work_dir): + if "+mpi" in self.spec: + flag = "mpi" + mpirun = which(self.spec["mpi"].prefix.bin.mpirun) + mpirun( + "-np", + "4", + self.prefix.bin.tau_python, + tau_py_inter, + "-T", + flag, + "firstprime.py", + ) else: - test_args = ["-n", "4"] + tau_exec_flags - test_args.append(test_exe) - mpiexe_list = ["mpirun", "mpiexec", "srun"] - for mpiexe in mpiexe_list: - if which(mpiexe) is not None: - test_description = "Run {} test with mpi".format(test_name) - self.run_test( - mpiexe, test_args, [], 0, False, test_description, False, inst_test_dir - ) - break - else: - if use_tau_exec: - test_app = "tau_exec" - test_args = ["-T", "serial"] + tau_exec_flags - test_args.append(test_exe) + flag = "serial" + tau_python(tau_py_inter, "-T", flag, "firstprime.py") + pprof() + + def _run_default_test(self, test_name, purpose, work_dir): + tau_exec = which(self.prefix.bin.tau_exec) + pprof = which(self.prefix.bin.pprof) + with test_part(self, f"{test_name}", purpose, work_dir): + make("all") + if "+mpi" in self.spec: + flags = ["-T", "mpi"] + mpirun = which(self.spec["mpi"].prefix.bin.mpirun) + mpirun("-np", "4", self.prefix.bin.tau_exec, *flags, "./matmult") else: - test_app = test_exe - test_args = [] - test_description = "Run sequential {} test".format(test_name) - self.run_test( - test_app, test_args, [], 0, False, test_description, False, inst_test_dir - ) - self.run_test( - "pprof", - [], - [], - 0, - False, - "Run pprof profile analysis tool on profile output", - False, - inst_test_dir, - ) - - def _run_python_test(self, test_dir): - python_dir = join_path(test_dir, self.python_test) - flags = "serial" - if "+mpi" in self.spec: - flags = "mpi" - self.run_test( - "tau_python", - ["-T", flags, "firstprime.py"], - [], - 0, - False, - "Pyhon example", - False, - python_dir, - ) - self.run_test( - "pprof", - [], - [], - 0, - False, - "Run pprof profile analysis tool on profile output", - False, - python_dir, - ) - - def test(self): - test_dir = self.test_suite.current_test_cache_dir - # Run mm test program pulled from the build - if "+ompt" in self.spec: - tau_exec_flags = ["-ompt"] - self._run_tau_test(test_dir, self.ompt_test, "OMPT example", "mandel", tau_exec_flags) - else: - self._run_tau_test(test_dir, self.matmult_test, "matrix multiplication", "matmult") - if "+dyninst" in self.spec: - self._run_dyninst_test(test_dir) + flags = ["-T", "serial"] + tau_exec(*flags, "./matmult") + pprof() + + def _run_ompt_test(self, test_name, purpose, work_dir): + tau_exec = which(self.prefix.bin.tau_exec) + pprof = which(self.prefix.bin.pprof) + with test_part(self, f"{test_name}", purpose, work_dir): + make("all") + if "+mpi" in self.spec: + flags = ["-T", "mpi", "-ompt"] + mpirun = which(self.spec["mpi"].prefix.bin.mpirun) + mpirun("-np", "4", self.prefix.bin.tau_exec, *flags, "./mandel") + else: + flags = ["-T", "serial", "-ompt"] + tau_exec(*flags, "./mandel") + pprof() + + def _run_rocm_test(self, test_name, purpose, work_dir): + tau_exec = which(self.prefix.bin.tau_exec) + pprof = which(self.prefix.bin.pprof) + with test_part(self, f"{test_name}", purpose, work_dir): + make("all") + if "+mpi" in self.spec: + flags = ["-T", "mpi", "-rocm"] + mpirun = which(self.spec["mpi"].prefix.bin.mpirun) + mpirun("-np", "4", self.prefix.bin.tau_exec, *flags, "./gpu-stream-hip") + else: + flags = ["-T", "serial", "-rocm"] + tau_exec(*flags, "./gpu-stream-hip") + pprof() + + def test_python(self): + """test python variant""" + if self.disable_tests: + return if "+python" in self.spec: - self._run_python_test(test_dir) - if "+cuda" in self.spec: - tau_exec_flags = ["-cupti"] - self._run_tau_test( - test_dir, - self.cuda_test, - "CUDA example", - "dataElem_um", - tau_exec_flags, - use_tau_exec=True, - ) - if "+level_zero" in self.spec: - tau_exec_flags = ["-l0"] - self._run_tau_test( - test_dir, - self.level_zero_test, - "Level Zero example", - "complex_mult.exe", - tau_exec_flags, - use_tau_exec=True, - ) - if "+rocm" in self.spec and ("+rocprofiler" in self.spec or "+roctracer" in self.spec): - tau_exec_flags = ["-rocm"] - self._run_tau_test( - test_dir, - self.rocm_test, - "Rocm example", - "vectoradd_hip.exe", - tau_exec_flags, - use_tau_exec=True, - ) - if "+syscall" in self.spec: - tau_exec_flags = ["-syscall"] - self._run_tau_test( - test_dir, - self.syscall_test, - "Syscall example", - "syscall_test", - tau_exec_flags, - use_tau_exec=True, - ) + # current_test_cache_dir.examples.python + python_test_dir = join_path(self.test_suite.current_test_cache_dir, self.python_test) + self._run_python_test("test_tau_python", "Testing tau_python", python_test_dir) + + def test_default(self): + """default matmult test""" + if self.disable_tests: + return + if "+ompt" in self.spec: + return + default_test_dir = join_path(self.test_suite.current_test_cache_dir, self.matmult_test) + self._run_default_test("test_default", "Testing TAU", default_test_dir) + + def test_ompt(self): + """ompt test""" + if self.disable_tests: + return + if "+ompt" in self.spec: + ompt_test_dir = join_path(self.test_suite.current_test_cache_dir, self.ompt_test) + self._run_ompt_test("test_ompt", "Testing ompt", ompt_test_dir) + + def test_rocm(self): + """rocm test""" + # Disabled, see PR#43682 + # make is unable to find rocm_agent_enumerator + # when testing, with spack load, there is no issue + return + if self.disable_tests: + return + if "+rocm" in self.spec and ( + "+rocprofiler" in self.spec or "+roctracer" in self.spec or "+rocprofv2" in self.spec + ): + rocm_test_dir = join_path(self.test_suite.current_test_cache_dir, self.rocm_test) + self._run_rocm_test("test_rocm", "Testing rocm", rocm_test_dir) diff --git a/var/spack/repos/builtin/packages/tau/tau-rocm-disable-llvm-plugin.patch b/var/spack/repos/builtin/packages/tau/tau-rocm-disable-llvm-plugin.patch new file mode 100644 index 00000000000000..0f863c6a9a445a --- /dev/null +++ b/var/spack/repos/builtin/packages/tau/tau-rocm-disable-llvm-plugin.patch @@ -0,0 +1,19 @@ +diff -ruN spack-src/configure spack-src-patched/configure +--- spack-src/configure 2024-04-16 00:20:41.000000000 +0000 ++++ spack-src-patched/configure 2024-06-12 19:35:50.799407280 +0000 +@@ -3101,7 +3101,6 @@ + rocprofiler=yes + tauoptions="${tauoptions}-rocm" + pthread=yes +- build_llvm_plugin=yes + shift + ;; + +@@ -3118,7 +3117,6 @@ + rocprofiler=yes + tauoptions="${tauoptions}-rocm" + pthread=yes +- build_llvm_plugin=yes + shift + ;; + diff --git a/var/spack/repos/builtin/packages/tauola/package.py b/var/spack/repos/builtin/packages/tauola/package.py index 7275fb93583aed..93e41f380f003a 100644 --- a/var/spack/repos/builtin/packages/tauola/package.py +++ b/var/spack/repos/builtin/packages/tauola/package.py @@ -18,6 +18,10 @@ class Tauola(AutotoolsPackage): version("1.1.8", sha256="3f734e8a967682869cca2c1ffebd3e055562613c40853cc81820d8b666805ed5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("hepmc", default=True, description="Enable hepmc 2.x support") variant("hepmc3", default=False, description="Enable hepmc3 support") variant("lhapdf", default=True, description="Enable lhapdf support. Required for TauSpinner.") diff --git a/var/spack/repos/builtin/packages/tblite/package.py b/var/spack/repos/builtin/packages/tblite/package.py index 52661f07449400..68cea15883f839 100644 --- a/var/spack/repos/builtin/packages/tblite/package.py +++ b/var/spack/repos/builtin/packages/tblite/package.py @@ -19,6 +19,9 @@ class Tblite(MesonPackage): version("0.3.0", sha256="46d77c120501ac55ed6a64dea8778d6593b26fb0653c591f8e8c985e35884f0a") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=True, description="Use OpenMP parallelisation") variant("python", default=False, description="Build Python extension module") diff --git a/var/spack/repos/builtin/packages/tcl-itcl/package.py b/var/spack/repos/builtin/packages/tcl-itcl/package.py index d7a42c60f8c099..0d33f8c973de7f 100644 --- a/var/spack/repos/builtin/packages/tcl-itcl/package.py +++ b/var/spack/repos/builtin/packages/tcl-itcl/package.py @@ -16,6 +16,8 @@ class TclItcl(AutotoolsPackage): version("4.0.4", sha256="63860438ca22f70049aecff70dc607b31bb1bea0edcc736e36ac6e36c24aecde") + depends_on("c", type="build") # generated + extends("tcl") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/tcl-tcllib/package.py b/var/spack/repos/builtin/packages/tcl-tcllib/package.py index d0a0ccaa3d7f4e..5b0231c5833481 100644 --- a/var/spack/repos/builtin/packages/tcl-tcllib/package.py +++ b/var/spack/repos/builtin/packages/tcl-tcllib/package.py @@ -27,4 +27,7 @@ class TclTcllib(AutotoolsPackage): version("1.15", sha256="6d308980d9dace24c6252b96223c1646e83795ba03dbf996525ad27e1b56bffd") version("1.14", sha256="dd149fcb37ceb04da83531276a9d7563827807dcee49f9b9f63bedea9e130584") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + extends("tcl") diff --git a/var/spack/repos/builtin/packages/tcl-tclxml/package.py b/var/spack/repos/builtin/packages/tcl-tclxml/package.py index 5d39a94ec79b6c..97183cf5b469ce 100644 --- a/var/spack/repos/builtin/packages/tcl-tclxml/package.py +++ b/var/spack/repos/builtin/packages/tcl-tclxml/package.py @@ -20,6 +20,8 @@ class TclTclxml(AutotoolsPackage): version("3.2", sha256="f4116b6680b249ce74b856a121762361ca09e6256f0c8ad578d1c661b822cb39") version("3.1", sha256="9b017f29c7a06fa1a57d1658bd1d3867297c26013604bdcc4d7b0ca2333552c9") + depends_on("c", type="build") # generated + extends("tcl") depends_on("tcl-tcllib") diff --git a/var/spack/repos/builtin/packages/tcl/package.py b/var/spack/repos/builtin/packages/tcl/package.py index 0d1dd1e8191af6..d95d80331e5c1c 100644 --- a/var/spack/repos/builtin/packages/tcl/package.py +++ b/var/spack/repos/builtin/packages/tcl/package.py @@ -52,13 +52,15 @@ class Tcl(AutotoolsPackage, NMakePackage, SourceforgePackage, TclHelper): version("8.6.3", sha256="6ce0778de0d50daaa9c345d7c1fd1288fb658f674028812e7eeee992e3051005") version("8.5.19", sha256="d3f04456da873d17f02efc30734b0300fb6c3b85028d445fe284b83253a6db18") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + extendable = True depends_on("zlib-api") - # No compiler wrappers on Windows - for plat in ["linux", "darwin", "cray", "freebsd"]: - filter_compiler_wrappers("tclConfig.sh", relative_root="lib", when=f"platform={plat}") + if sys.platform != "win32": + filter_compiler_wrappers("tclConfig.sh", relative_root="lib") build_system("autotools", "nmake") patch("tcl-quote-cc-path.patch", when="platform=windows") diff --git a/var/spack/repos/builtin/packages/tclap/package.py b/var/spack/repos/builtin/packages/tclap/package.py index a2ab335f318f64..56e759821f917e 100644 --- a/var/spack/repos/builtin/packages/tclap/package.py +++ b/var/spack/repos/builtin/packages/tclap/package.py @@ -19,3 +19,5 @@ class Tclap(AutotoolsPackage, SourceforgePackage): version("1.2.3", sha256="19e7db5281540f154348770bc3a7484575f4f549aef8e00aabcc94b395f773c9") version("1.2.2", sha256="f5013be7fcaafc69ba0ce2d1710f693f61e9c336b6292ae4f57554f59fde5837") version("1.2.1", sha256="9f9f0fe3719e8a89d79b6ca30cf2d16620fba3db5b9610f9b51dd2cd033deebb") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/tcoffee/package.py b/var/spack/repos/builtin/packages/tcoffee/package.py index 1564b43ef891f8..c6cdbc2d9f8341 100644 --- a/var/spack/repos/builtin/packages/tcoffee/package.py +++ b/var/spack/repos/builtin/packages/tcoffee/package.py @@ -14,6 +14,9 @@ class Tcoffee(MakefilePackage): version("2017-08-17", commit="f389b558e91d0f82e7db934d9a79ce285f853a71") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("perl", type=("build", "run")) depends_on("blast-plus") depends_on("dialign-tx") diff --git a/var/spack/repos/builtin/packages/tcpdump/package.py b/var/spack/repos/builtin/packages/tcpdump/package.py index 57c2a3f0dc2d40..de2b66e1354570 100644 --- a/var/spack/repos/builtin/packages/tcpdump/package.py +++ b/var/spack/repos/builtin/packages/tcpdump/package.py @@ -24,5 +24,7 @@ class Tcpdump(AutotoolsPackage): version("4.9.2", sha256="798b3536a29832ce0cbb07fafb1ce5097c95e308a6f592d14052e1ef1505fe79") version("4.9.1", sha256="f9448cf4deb2049acf713655c736342662e652ef40dbe0a8f6f8d5b9ce5bd8f3") + depends_on("c", type="build") # generated + depends_on("libpcap") depends_on("libpcap@1.10.0:", when="@4.99.0:") diff --git a/var/spack/repos/builtin/packages/tcsh/package.py b/var/spack/repos/builtin/packages/tcsh/package.py index 5196673c87dab7..2b8a1d9a6c8de4 100644 --- a/var/spack/repos/builtin/packages/tcsh/package.py +++ b/var/spack/repos/builtin/packages/tcsh/package.py @@ -30,6 +30,8 @@ class Tcsh(AutotoolsPackage): version("6.21.00", sha256="c438325448371f59b12a4c93bfd3f6982e6f79f8c5aef4bc83aac8f62766e972") version("6.20.00", sha256="b89de7064ab54dac454a266cfe5d8bf66940cb5ed048d0c30674ea62e7ecef9d") + depends_on("c", type="build") # generated + # Upstream patches fedora_patch( "96b95844cc685b11ed0cc215137e394da4505d41", diff --git a/var/spack/repos/builtin/packages/tdengine/package.py b/var/spack/repos/builtin/packages/tdengine/package.py index 6b6d5488873be1..e6760d3078ca72 100644 --- a/var/spack/repos/builtin/packages/tdengine/package.py +++ b/var/spack/repos/builtin/packages/tdengine/package.py @@ -18,6 +18,9 @@ class Tdengine(CMakePackage): version("2.0.3.2", sha256="3eb8df894998d5592cce377b4f7e267972aee8adf9fc1ce60d1af532ffa9c1c6") version("2.0.3.1", sha256="69418815afcac8051f1aab600415669003b4aeec4ec2aaf09cab24636edaf51f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + @when("target=aarch64:") def cmake_args(self): args = ["-DCPUTYPE=aarch64"] diff --git a/var/spack/repos/builtin/packages/tealeaf/package.py b/var/spack/repos/builtin/packages/tealeaf/package.py index 64cd5a5db38759..443c8997334983 100644 --- a/var/spack/repos/builtin/packages/tealeaf/package.py +++ b/var/spack/repos/builtin/packages/tealeaf/package.py @@ -24,6 +24,10 @@ class Tealeaf(MakefilePackage): version("1.0", sha256="e11799d1a3fbe76041333ba98858043b225c5d65221df8c600479bc55e7197ce") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/teckit/package.py b/var/spack/repos/builtin/packages/teckit/package.py index ad918cfdb6e8c6..987d7feae9afcb 100644 --- a/var/spack/repos/builtin/packages/teckit/package.py +++ b/var/spack/repos/builtin/packages/teckit/package.py @@ -30,6 +30,9 @@ class Teckit(AutotoolsPackage): version("2.5.6", commit="41c20be2793e1afcbb8de6339af89d1eeab84fe8") version("2.5.5", commit="2733fd9895819e3697257550cc39b8e419c1ee7e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/telegraf/package.py b/var/spack/repos/builtin/packages/telegraf/package.py index 92d4084bc05046..2523852bd48ccd 100644 --- a/var/spack/repos/builtin/packages/telegraf/package.py +++ b/var/spack/repos/builtin/packages/telegraf/package.py @@ -16,6 +16,7 @@ class Telegraf(MakefilePackage): license("MIT") + version("1.30.2", sha256="3514d870fe1899f20c5d1f1545233413cbe11061b23a0cafbd44b861a9295dc6") version("1.20.3", sha256="cf8fd4d38970648281101e8a71b1a48c5765c8aaa9d67619c00272c9192e9057") version("1.19.3", sha256="d2fb8a3519a5690c801e1221e22c3693ed95204f70f6c57eb13267ca1964c659") diff --git a/var/spack/repos/builtin/packages/tempestremap/package.py b/var/spack/repos/builtin/packages/tempestremap/package.py index faf870e61fe018..5733663bbd4256 100644 --- a/var/spack/repos/builtin/packages/tempestremap/package.py +++ b/var/spack/repos/builtin/packages/tempestremap/package.py @@ -28,6 +28,8 @@ class Tempestremap(AutotoolsPackage): version("2.0.1", sha256="a3f1bef8cc413a689d429ac56f2bcc2e1d282d99797c3375233de792a7448ece") version("2.0.0", sha256="5850e251a4ad04fc924452f49183e5e12c38725832a568e57fa424a844b8a000") + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/templight-tools/package.py b/var/spack/repos/builtin/packages/templight-tools/package.py index c2951943bad17e..ea41e74827c7be 100644 --- a/var/spack/repos/builtin/packages/templight-tools/package.py +++ b/var/spack/repos/builtin/packages/templight-tools/package.py @@ -16,5 +16,7 @@ class TemplightTools(CMakePackage): version("develop", branch="master") + depends_on("cxx", type="build") # generated + depends_on("cmake @2.8.7:", type="build") depends_on("boost @1.48.1: +exception+filesystem+system+graph+program_options+test+container") diff --git a/var/spack/repos/builtin/packages/templight/package.py b/var/spack/repos/builtin/packages/templight/package.py index 76df5f2bed9eed..5bf08fa5f81a65 100644 --- a/var/spack/repos/builtin/packages/templight/package.py +++ b/var/spack/repos/builtin/packages/templight/package.py @@ -18,8 +18,6 @@ class Templight(CMakePackage): git = "https://github.com/mikael-s-persson/templight.git" llvm_svn = "http://llvm.org/svn/llvm-project/{0}/trunk" - family = "compiler" # Used by lmod - # Templight is a patch to clang, so we have three versions to care about: # - The one that will be used in Spack specifications # - The git branch that we need to fetch from in the templight repo @@ -63,6 +61,8 @@ class Templight(CMakePackage): ) version("2018.07.20", commit="91589f95427620dd0a2346bd69ba922f374aa42a") + + depends_on("cxx", type="build") # generated resource( name="llvm-r337566", svn=llvm_svn.format("llvm"), diff --git a/var/spack/repos/builtin/packages/tempo/package.py b/var/spack/repos/builtin/packages/tempo/package.py index 95215a857d0a2f..9fe09fb22f9614 100644 --- a/var/spack/repos/builtin/packages/tempo/package.py +++ b/var/spack/repos/builtin/packages/tempo/package.py @@ -15,6 +15,9 @@ class Tempo(AutotoolsPackage): version("develop") version("LWA-10-17-2020", commit="6bab1083350eca24745eafed79a55156bdd1e7d5") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/tengine/package.py b/var/spack/repos/builtin/packages/tengine/package.py index 73412eb30d7585..23753d44f0b42f 100644 --- a/var/spack/repos/builtin/packages/tengine/package.py +++ b/var/spack/repos/builtin/packages/tengine/package.py @@ -12,10 +12,14 @@ class Tengine(AutotoolsPackage): homepage = "https://tengine.taobao.org/" url = "https://github.com/alibaba/tengine/archive/2.3.2.tar.gz" + version("3.1.0", sha256="64ed7155c0c904ce0fe7199c21b8eb6c2abfc267278fa8af832c0cb781e864dc") version("2.3.2", sha256="a65998a35739a59f8a16ec4c6090a59e569ba5a1a3f68fecad952057c1a18fea") version("2.3.1", sha256="3dd93f813b80ed7581a81079a2037df6e4777b7e760fd6635b4009d344a5ab1c") version("2.3.0", sha256="17cf1380d4faefb70707970437b3f8b66f6ff4530b5e6e61970b35f59b2e2624") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pcre") def setup_run_environment(self, env): diff --git a/var/spack/repos/builtin/packages/tensorflow-serving-client/package.py b/var/spack/repos/builtin/packages/tensorflow-serving-client/package.py index 38dd6e7fd2cb8e..5b63beeb16980d 100644 --- a/var/spack/repos/builtin/packages/tensorflow-serving-client/package.py +++ b/var/spack/repos/builtin/packages/tensorflow-serving-client/package.py @@ -22,5 +22,7 @@ class TensorflowServingClient(CMakePackage): version("2.1.0", sha256="7a31d8cfa1d861f73953d4728665dd6d74e205d1fa01062a6c2b1aeee4674f73") version("2.0.0", sha256="55310ad484f257173ad5194df7f7116b2049260c3d29049ef8d789d1d8bd9948") + depends_on("cxx", type="build") # generated + depends_on("protobuf") depends_on("grpc") diff --git a/var/spack/repos/builtin/packages/tensorpipe/package.py b/var/spack/repos/builtin/packages/tensorpipe/package.py index e2e58e2efc87e8..efe9beb8ae40b3 100644 --- a/var/spack/repos/builtin/packages/tensorpipe/package.py +++ b/var/spack/repos/builtin/packages/tensorpipe/package.py @@ -31,6 +31,9 @@ class Tensorpipe(CMakePackage): "2020-06-26", commit="3b8089c9c6717038cff44b70b881d0ad6c93e679", submodules=True ) # py-torch@1.6 + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@3.5:", type="build") depends_on("libuv@1.26:") diff --git a/var/spack/repos/builtin/packages/termcap/package.py b/var/spack/repos/builtin/packages/termcap/package.py index 58cf70e46605a6..d8b702aa3abd75 100644 --- a/var/spack/repos/builtin/packages/termcap/package.py +++ b/var/spack/repos/builtin/packages/termcap/package.py @@ -18,3 +18,5 @@ class Termcap(AutotoolsPackage): version("1.3.1", sha256="91a0e22e5387ca4467b5bcb18edf1c51b930262fd466d5fda396dd9d26719100") version("1.3", sha256="3eb4b98ae08408ca65dd9275f3c8e56e2feac1261fae914a9b21273db51cf000") + + depends_on("c", type="build") # generated diff --git a/var/spack/repos/builtin/packages/tesseract/package.py b/var/spack/repos/builtin/packages/tesseract/package.py index f74fdda513ddbe..7f8359f29713ce 100644 --- a/var/spack/repos/builtin/packages/tesseract/package.py +++ b/var/spack/repos/builtin/packages/tesseract/package.py @@ -18,6 +18,8 @@ class Tesseract(AutotoolsPackage): version("4.1.0", sha256="5c5ed5f1a76888dc57a83704f24ae02f8319849f5c4cf19d254296978a1a1961") version("4.0.0", sha256="a1f5422ca49a32e5f35c54dee5112b11b99928fc9f4ee6695cdc6768d69f61dd") + depends_on("cxx", type="build") # generated + # do not fetch the jar files from Makefile patch("java_Makefile.patch") diff --git a/var/spack/repos/builtin/packages/test-drive/package.py b/var/spack/repos/builtin/packages/test-drive/package.py index 921bc213c23ca5..194cfbfe13f64a 100644 --- a/var/spack/repos/builtin/packages/test-drive/package.py +++ b/var/spack/repos/builtin/packages/test-drive/package.py @@ -17,3 +17,5 @@ class TestDrive(MesonPackage): license("Apache-2.0") version("0.4.0", "effabe5d46ea937a79f3ea8d37eea43caf38f9f1377398bad0ca02784235e54a") + + depends_on("fortran", type="build") # generated diff --git a/var/spack/repos/builtin/packages/tests-sos/package.py b/var/spack/repos/builtin/packages/tests-sos/package.py new file mode 100644 index 00000000000000..41a6274e7042cc --- /dev/null +++ b/var/spack/repos/builtin/packages/tests-sos/package.py @@ -0,0 +1,36 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class TestsSos(AutotoolsPackage): + """Sandia OpenSHMEM unit tests and performance testing suite.""" + + homepage = "https://github.com/openshmem-org/tests-sos" + url = "https://github.com/openshmem-org/tests-sos/archive/refs/tags/v1.5.2.tar.gz" + + maintainers("jack-morrison") + + version("1.5.2", sha256="3a063963ef779419aadc6b21ff2f1e4dcdd3e95fa8ed23545434e56757f3187f") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + depends_on("autoconf", type="build") + depends_on("automake", type="build") + depends_on("libtool", type="build") + depends_on("m4", type="build") + depends_on("sos", type=("build", "run")) + + def autoreconf(self, spec, prefix): + bash = which("bash") + bash("./autogen.sh") + + def setup_build_environment(self, env): + env.set("CC", "oshcc") + env.set("CXX", "oshc++") + env.set("FC", "oshfort") diff --git a/var/spack/repos/builtin/packages/tetgen/package.py b/var/spack/repos/builtin/packages/tetgen/package.py index 7faeedc9fe9317..ce56f975aee8b5 100644 --- a/var/spack/repos/builtin/packages/tetgen/package.py +++ b/var/spack/repos/builtin/packages/tetgen/package.py @@ -42,6 +42,8 @@ class Tetgen(Package): url="http://www.tetgen.org/files/tetgen1.4.3.tar.gz", ) + depends_on("cxx", type="build") # generated + variant("pic", default=True, description="Builds the library in pic mode.") variant("debug", default=False, description="Builds the library in debug mode.") variant( diff --git a/var/spack/repos/builtin/packages/tethex/package.py b/var/spack/repos/builtin/packages/tethex/package.py index 2698cde1c28110..028040d497edd7 100644 --- a/var/spack/repos/builtin/packages/tethex/package.py +++ b/var/spack/repos/builtin/packages/tethex/package.py @@ -20,6 +20,8 @@ class Tethex(CMakePackage): version("develop", branch="master") version("0.0.7", sha256="5f93f434c6d110be3d8d0eba69336864d0e5a26aba2d444eb25adbd2caf73645") + depends_on("cxx", type="build") # generated + variant( "build_type", default="Release", diff --git a/var/spack/repos/builtin/packages/texinfo/package.py b/var/spack/repos/builtin/packages/texinfo/package.py index bc1bc5b64be871..ae3cfc95822dc5 100644 --- a/var/spack/repos/builtin/packages/texinfo/package.py +++ b/var/spack/repos/builtin/packages/texinfo/package.py @@ -25,6 +25,7 @@ class Texinfo(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-or-later") + version("7.1", sha256="dd5710b3a53ac002644677a06145748e260592a35be182dc830ebebb79c5d5a0") version("7.0.3", sha256="3cc5706fb086b895e1dc2b407aade9f95a3a233ff856273e2b659b089f117683") version("7.0", sha256="9261d4ee11cdf6b61895e213ffcd6b746a61a64fe38b9741a3aaa73125b35170") version("6.8", sha256="8e09cf753ad1833695d2bac0f57dc3bd6bcbbfbf279450e1ba3bc2d7fb297d08") @@ -37,6 +38,9 @@ class Texinfo(AutotoolsPackage, GNUMirrorPackage): version("5.1", sha256="50e8067f9758bb2bf175b69600082ac4a27c464cb4bcd48a578edd3127216600") version("5.0", sha256="2c579345a39a2a0bb4b8c28533f0b61356504a202da6a25d17d4d866af7f5803") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl") depends_on("ncurses") depends_on("gettext") @@ -61,7 +65,7 @@ class Texinfo(AutotoolsPackage, GNUMirrorPackage): def build_targets(self): targets = [] if self.spec.satisfies("@7.0:"): - targets.append("CFLAGS={}".format(self.compiler.c11_flag)) + targets.append(f"CFLAGS={self.compiler.c11_flag}") return targets def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/texlive/package.py b/var/spack/repos/builtin/packages/texlive/package.py index 928a2a868050e3..55645523d0cc1f 100644 --- a/var/spack/repos/builtin/packages/texlive/package.py +++ b/var/spack/repos/builtin/packages/texlive/package.py @@ -82,6 +82,10 @@ class Texlive(AutotoolsPackage): when="@{0}".format(release["version"]), ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # The following variant is only for the "live" binary installation. # There does not seem to be a complete list of schemes. # Examples include: diff --git a/var/spack/repos/builtin/packages/texstudio/package.py b/var/spack/repos/builtin/packages/texstudio/package.py index a775f1688696df..c33575a8c2a20a 100644 --- a/var/spack/repos/builtin/packages/texstudio/package.py +++ b/var/spack/repos/builtin/packages/texstudio/package.py @@ -25,6 +25,9 @@ class Texstudio(QMakePackage): version("2.12.12", sha256="5978daa806c616f9a1eea231bb613f0bc1037d7d2435ee5ca6b14fe88a2caa8c") version("2.12.10", sha256="92cf9cbb536e58a5929611fa40438cd9d7ea6880022cd3c5de0483fd15d3df0b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "poppler", default=True, diff --git a/var/spack/repos/builtin/packages/textparser/package.py b/var/spack/repos/builtin/packages/textparser/package.py index 54658a61baeff1..fff741ef064db8 100644 --- a/var/spack/repos/builtin/packages/textparser/package.py +++ b/var/spack/repos/builtin/packages/textparser/package.py @@ -18,6 +18,10 @@ class Textparser(CMakePackage): version("master", branch="master") version("1.8.8", commit="31ec1f23df21611d0765c27a6458fdbbf4cde66d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Activate MPI support") variant("fapi", default=False, description="This option is for building Fortran API.") variant( diff --git a/var/spack/repos/builtin/packages/tfel/package.py b/var/spack/repos/builtin/packages/tfel/package.py index 39d13b29cda0ef..fab93d082f81a4 100644 --- a/var/spack/repos/builtin/packages/tfel/package.py +++ b/var/spack/repos/builtin/packages/tfel/package.py @@ -49,26 +49,32 @@ class Tfel(CMakePackage): # released version version( - "4.2.0", - sha256="cf8a309c4d19a8e36232f8540ff28aa0d6285645f8dfb1ac57dd481ba3453e02", + "4.2.1", + sha256="14f27257014a992a4e511f35390e4b9a086f6a5ed74087f891f8c00306f1758f", preferred=True, ) + version("4.2.0", sha256="cf8a309c4d19a8e36232f8540ff28aa0d6285645f8dfb1ac57dd481ba3453e02") + version("4.1.2", sha256="e9e7c2aeef7d19f92ffd83b2a7fc54186e648d25e42696b5cba7c4bfa194276a") version("4.1.1", sha256="e0f229094e88a2d6c6a78ae60fa77d2f4b8294e9d810c21fd7df61004bf29a33") version("4.1.0", sha256="7505c41da9df5fb3c281651ff29b58a18fd4d91b92f839322f0267269c5f1375") + version("4.0.3", sha256="c21c13fbd5ad8f52e9874a7931c619b9b7e69d69a2ab003e09628a1e9945542d") version("4.0.2", sha256="f5c8a285e00f334fd3e1a95f9a393fed393990ee827dae3766da1decfaa1074e") version("4.0.1", sha256="f54741b7e654cb12511ca68c6494a4789ba41b5ada4cd345ad2bc7da631309d1") version("4.0.0", sha256="7a0c32c8a9cd2fd65cbcb54fff802f303665d7cba5d46f92ff3d55f057c92845") + version("3.4.6", sha256="88c3d076ca360ffbadb6ffeb6cbc1267a9da0e098e7c182407501820ba2bf6e7") version("3.4.5", sha256="064d6926106e0052829182087a025f58fc3e98dfb69967e0795d9cdb4e1500b9") version("3.4.4", sha256="a518a7a761fec6c92fab6dc9df5694c28aad2554c7c649d707dfdc71fe93d2ca") version("3.4.3", sha256="e58515effe57d473385fe0b592d9e1d1286c0901496c61268d9efd92a2550849") version("3.4.2", sha256="f39e65b2282fd3b108081388f161ba662407b192fed68fafe324c7528026a202") version("3.4.1", sha256="04cd4257e39e1b05e02b12ad941106fff4d439934bdfe6e950c08bab23e2a4ba") version("3.4.0", sha256="176feb4c1726d0f21f4c656b20620dce6f99ab7f5f09a66905aeb643a316bbc1") + version("3.3.5", sha256="4319a7a6363f69f7f0c78abb0741bc90b49dc777831c2886b13aca61c79bae04") version("3.3.4", sha256="3829e0b07520a14b17a8e75f879683a0d97b04b897aeb3ad0dd96dc94c0fcd6b") version("3.3.3", sha256="5a1fb43a8086e594e0a7234c1f227e6e005d384fd84affe3acadccb68fe2bbf6") version("3.3.2", sha256="17127ffdf92367c10041258f70a88ac3dcb0a7d89c1766a6aa1ebaeb4d03d55d") version("3.3.1", sha256="ad07329c25874832fbacc999b5f88d9b9ab84415bc897a6f3cae5b4afcd7661f") version("3.3.0", sha256="884ad68b0fbbededc3a602d559433c24114ae4534dc9f0a759d31ca3589dace0") + version("3.2.10", sha256="3fe24a2811811d68ce5735f601d12fae7b1da465ac5b2917bd0887782218f2bd") version("3.2.9", sha256="4ee26f2b5db24dc10113100ae0165cbbe8c7960c99c0e64ec96410788774aa54") version("3.2.8", sha256="8bc3db975a87c3f0da3a857ab45cd237ee02f4ab35094a7db28b01d92676a78c") version("3.2.7", sha256="05a055a955dd52f0b2dbf9d518a86c58805b2b63f3766268d72cacd6126c187d") @@ -79,6 +85,7 @@ class Tfel(CMakePackage): version("3.2.2", sha256="69b01ae0d1f9140b619aaa9135948284ff40d4654672c335e55ab4934c02eb43") version("3.2.1", sha256="12786480524a7fe86889120fb334fa00211dfd44ad5ec71e2279e7adf1ddc807") version("3.2.0", sha256="089d79745e9f267a2bd03dcd8841d484e668bd27f5cc2ff7453634cb39016848") + version("3.1.13", sha256="f0e5dddb5d32931dcab2d060029da31aacb47cd3251297d701b86d93c8fa0255") version("3.1.12", sha256="770aa4680063ddd7be4f735ed1ec9402e83502d1ceb688c79cdba27490b7bf98") version("3.1.11", sha256="578e3463db029bfed7b24bfa1226394e6998cc95959b46246ab9bf5cfb6d65f0") version("3.1.10", sha256="635a2507f139bb6d893e0a7bb223cd1d9ddab5dfddee179a3b2e9f8b0b63e065") @@ -92,6 +99,7 @@ class Tfel(CMakePackage): version("3.1.2", sha256="2eaa191f0699031786d8845ac769320a42c7e035991d82b3738289886006bfba") version("3.1.1", sha256="a4c0c21c6c22752cc90c82295a6bafe637b3395736c66fcdfcfe4aeccb5be7af") version("3.1.0", sha256="dd67b400b5f157aef503aa3615b9bf6b52333876a29e75966f94ee3f79ab37ad") + version("3.0.13", sha256="04987d318c46294853481fa987dd09e8ca38493b8994a363d20623f9b8f009ff") version("3.0.12", sha256="f7dae9e5a00c721445b3167ec7bc71747bab047ddb36103f232b72d3e4d3cd00") version("3.0.11", sha256="3d2d249534563887d301f6be5c4c2e4be33258b9d712d550d4c71271b764cc2d") version("3.0.10", sha256="1604f22948b4af6ef84839d97909f7011ce614254e1a6de092ddc61832f7d343") @@ -107,6 +115,10 @@ class Tfel(CMakePackage): version("3.0.0", sha256="b2cfaa3d7900b4f32f327565448bf9cb8e4242763f651bff8f231f378a278f9e") version("2.0.4", sha256="cac078435aad73d9a795516f161b320d204d2099d6a286e786359f484355a43a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # solvers interfaces variant("castem", default=True, description="Enables Cast3M interface") variant("aster", default=True, description="Enables Code_Aster interface") @@ -194,6 +206,9 @@ def cmake_args(self): return args + def setup_run_environment(self, env): + env.append_path("LD_LIBRARY_PATH", self.prefix.lib) + def check(self): """Skip the target 'test' which doesn't build all test programs used by tests""" with working_dir(self.build_directory): diff --git a/var/spack/repos/builtin/packages/the-silver-searcher/package.py b/var/spack/repos/builtin/packages/the-silver-searcher/package.py index 5d0d3caa9ba52e..ac3285a6cb4b86 100644 --- a/var/spack/repos/builtin/packages/the-silver-searcher/package.py +++ b/var/spack/repos/builtin/packages/the-silver-searcher/package.py @@ -19,6 +19,8 @@ class TheSilverSearcher(AutotoolsPackage): version("0.32.0", sha256="944ca77e498f344b2bfbd8df6d5d8df7bbc1c7e080b50c0bab3d1a9a55151b60") version("0.30.0", sha256="b4bf9e50bf48bc5fde27fc386f7bcad8644ef15a174c862a10813e81bd127e69") + depends_on("c", type="build") # generated + depends_on("pcre") depends_on("xz") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/thepeg/package.py b/var/spack/repos/builtin/packages/thepeg/package.py index e15de0489037c6..318049a1b349d0 100644 --- a/var/spack/repos/builtin/packages/thepeg/package.py +++ b/var/spack/repos/builtin/packages/thepeg/package.py @@ -40,6 +40,8 @@ class Thepeg(AutotoolsPackage): # version('1.9.1', sha256='8ec6d0669eba51e308be4e33aeb219999418170eae3aad93ec1491c942c2a4e9') version("1.9.0", sha256="3ee58e5e3a26184567df1b9a10ca70df228e86f322e72f018dd7d8d5a4700a5d") version("1.8.3", sha256="55ede3a3dd0bd07b90d0d49cf7ae28c18cd965780fdf53528508b97d57152fc7") + + depends_on("cxx", type="build") # generated # version('1.8.2', sha256='44ccd0d70e42bb6ecd801a51bade6c25b3953c56f33017402d4f52ee6492dffa') # version('1.8.1', sha256='84c2a212a681545cddd541dca191eb65d96f41df86c87480b6f4f7d4f9683562') # version('1.8.0', sha256='4b22fda1078f410b999a23a17f611c9ae3a7f0f4cee4e83dc82c9336b7adf037') diff --git a/var/spack/repos/builtin/packages/thermo4pfm/package.py b/var/spack/repos/builtin/packages/thermo4pfm/package.py index 421fc050281468..a6418a1cb1c1cb 100644 --- a/var/spack/repos/builtin/packages/thermo4pfm/package.py +++ b/var/spack/repos/builtin/packages/thermo4pfm/package.py @@ -18,4 +18,6 @@ class Thermo4pfm(CMakePackage): version("1.1.1", sha256="cff3c83405224a39bb34c57e444e208e94c6782d84303acd0588d1dfa61513a1") + depends_on("cxx", type="build") # generated + depends_on("boost") diff --git a/var/spack/repos/builtin/packages/thornado-mini/package.py b/var/spack/repos/builtin/packages/thornado-mini/package.py index efe7b935cb04d0..65cbf0ee7a0257 100644 --- a/var/spack/repos/builtin/packages/thornado-mini/package.py +++ b/var/spack/repos/builtin/packages/thornado-mini/package.py @@ -21,6 +21,8 @@ class ThornadoMini(MakefilePackage): version("1.0", sha256="8a9f97acc823d374cce567831270cfcc50fa968949e49159c7e3442b93a2827d") + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("hdf5+fortran") depends_on("lapack") diff --git a/var/spack/repos/builtin/packages/thrift/package.py b/var/spack/repos/builtin/packages/thrift/package.py index 4ad8a10f1b0d97..8c6f6aaeecff87 100644 --- a/var/spack/repos/builtin/packages/thrift/package.py +++ b/var/spack/repos/builtin/packages/thrift/package.py @@ -35,6 +35,9 @@ class Thrift(Package): version("0.10.0", sha256="2289d02de6e8db04cbbabb921aeb62bfe3098c4c83f36eec6c31194301efa10b") version("0.9.3", sha256="b0740a070ac09adde04d43e852ce4c320564a292f26521c46b78e0641564969e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("pic", default=True, description="Build position independent code") variant("c", default=True, description="Build support for C-family languages") variant("java", default=False, description="Build support for java") diff --git a/var/spack/repos/builtin/packages/thrust/package.py b/var/spack/repos/builtin/packages/thrust/package.py index ab37e4b347d446..5d70406dc68275 100644 --- a/var/spack/repos/builtin/packages/thrust/package.py +++ b/var/spack/repos/builtin/packages/thrust/package.py @@ -6,15 +6,22 @@ from spack.package import * -class Thrust(Package): +class Thrust(Package, CMakePackage): """Thrust is a parallel algorithms library which resembles the C++ Standard Template Library (STL).""" homepage = "https://thrust.github.io" url = "https://github.com/NVIDIA/thrust/archive/1.12.0.tar.gz" + git = "https://github.com/NVIDIA/thrust.git" license("BSL-1.0") + # to support CMake build system package installation, Thrust + # submodules must be downloaded, which aren't included in tarballs + version("1.17.2", commit="1ac51f2b6219ff17d15d93f2e0be85038556f346", submodules=True) + version("1.17.1", commit="4dd337f41622f5624359d6a958e3cb6ac7c6f57e", submodules=True) + version("1.17.0", commit="6a3078c64cab0e2f276340fa5dcafa0d758ed890", submodules=True) + # versions prior to 1.17 install from tarballs version("1.16.0", sha256="93b9553e3ee544e05395022bea67e6d600f8f3eb680950ec7cf73c0f55162487") version("1.15.0", sha256="0eeaf5a77cd7cb143f3443bd96b215ae1c4eacf18a712762e6a5c85213f80cc2") version("1.14.0", sha256="ddba9f3ed47b1a33562a4aea2d000a2ca2abcd45ff760af12aa81b8b7e492962") @@ -45,7 +52,32 @@ class Thrust(Package): version("1.8.3", sha256="2254200512fde7f4fd0fc74306286e192ea6ac9037576dbd31309c0579229dbb") version("1.8.2", sha256="83bc9e7b769daa04324c986eeaf48fcb53c2dda26bcc77cb3c07f4b1c359feb8") - def install(self, spec, prefix): + depends_on("cxx", type="build") # generated + + # leave the build system of pre-1.17 as originally implemented, + # but use CMake for newer versions + build_system( + conditional("cmake", when="@1.17:"), conditional("generic", when="@:1.16"), default="cmake" + ) + + # minimum CMake version is 3.15 for plain package installation (no + # examples, tests, etc) + depends_on("cmake@3.15:", when="@1.17:", type="build") + + +class CMakeBuilder(spack.build_systems.cmake.CMakeBuilder): + def cmake_args(self): + return [ + self.define("THRUST_ENABLE_HEADER_TESTING", "OFF"), + self.define("THRUST_ENABLE_TESTING", "OFF"), + self.define("THRUST_ENABLE_EXAMPLES", "OFF"), + self.define("THRUST_ENABLE_BENCHMARKS", "OFF"), + self.define("THRUST_INCLUDE_CUB_CMAKE", "OFF"), + ] + + +class GenericBuilder(spack.build_systems.generic.GenericBuilder): + def install(self, pkg, spec, prefix): install_tree("doc", join_path(prefix, "doc")) install_tree("examples", join_path(prefix, "examples")) install_tree("thrust", join_path(prefix, "include", "thrust")) diff --git a/var/spack/repos/builtin/packages/tig/package.py b/var/spack/repos/builtin/packages/tig/package.py index 04f93a8ece8add..31da344e44323e 100644 --- a/var/spack/repos/builtin/packages/tig/package.py +++ b/var/spack/repos/builtin/packages/tig/package.py @@ -14,7 +14,10 @@ class Tig(AutotoolsPackage): license("GPL-2.0-or-later") + version("2.5.10", sha256="f655cc1366fc10058a2bd505bb88ca78e653ff7526c1b81774c44b9d841210e3") version("2.5.8", sha256="b70e0a42aed74a4a3990ccfe35262305917175e3164330c0889bd70580406391") version("2.2.2", sha256="316214d87f7693abc0cbe8ebbb85decdf5e1b49d7ad760ac801af3dd73385e35") + depends_on("c", type="build") # generated + depends_on("ncurses") diff --git a/var/spack/repos/builtin/packages/tiled-mm/package.py b/var/spack/repos/builtin/packages/tiled-mm/package.py index 9b65bec94c77a1..9a2ea91555ce81 100644 --- a/var/spack/repos/builtin/packages/tiled-mm/package.py +++ b/var/spack/repos/builtin/packages/tiled-mm/package.py @@ -20,10 +20,13 @@ class TiledMm(CMakePackage, CudaPackage, ROCmPackage): version("master", branch="master") + version("2.3.1", sha256="68914a483e62f796b790ea428210b1d5ef5943d6289e53d1aa62f56a20fbccc8") version("2.3", sha256="504c6201f5a9be9741c55036bf8e2656ae3f4bc19996295b264ee5e303c9253c") version("2.2", sha256="6d0b49c9588ece744166822fd44a7bc5bec3dc666b836de8bf4bf1a7bb675aac") version("2.0", sha256="ea554aea8c53d7c8e40044e6d478c0e8137d7e8b09d7cb9650703430d92cf32e") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("examples", default=False, description="Enable examples") variant("tests", default=False, description="Enable tests") diff --git a/var/spack/repos/builtin/packages/time/package.py b/var/spack/repos/builtin/packages/time/package.py index bb9be7139423fe..7e6e7d8578d5e1 100644 --- a/var/spack/repos/builtin/packages/time/package.py +++ b/var/spack/repos/builtin/packages/time/package.py @@ -18,4 +18,6 @@ class Time(AutotoolsPackage, GNUMirrorPackage): version("1.9", sha256="fbacf0c81e62429df3e33bda4cee38756604f18e01d977338e23306a3e3b521e") + depends_on("c", type="build") # generated + build_directory = "spack-build" diff --git a/var/spack/repos/builtin/packages/timedatex/package.py b/var/spack/repos/builtin/packages/timedatex/package.py index 2f9483160efbcb..09555fe7e4edf5 100644 --- a/var/spack/repos/builtin/packages/timedatex/package.py +++ b/var/spack/repos/builtin/packages/timedatex/package.py @@ -23,6 +23,8 @@ class Timedatex(MakefilePackage): version("0.5", sha256="bc54960bb9554bb2b34985ba2b8a78480db568c3c6a9d26f2ab34de1bc0aab11") version("0.4", sha256="204285eb03c6cec9ae1c7fdb99e7c996259ec5a918d72bf6bc28564a6f738d4a") + depends_on("c", type="build") # generated + depends_on("glib") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/timemory/package.py b/var/spack/repos/builtin/packages/timemory/package.py index 290a85bc9f042f..5ae88c6d466e80 100644 --- a/var/spack/repos/builtin/packages/timemory/package.py +++ b/var/spack/repos/builtin/packages/timemory/package.py @@ -28,6 +28,10 @@ class Timemory(CMakePackage, PythonExtension): version("3.0.1", commit="ef638e1cde90275ce7c0e12fc4902c27bcbdeefd", submodules=True) version("3.0.0", commit="b36b1673b2c6b7ff3126d8261bef0f8f176c7beb", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Build shared libraries") variant("static", default=False, description="Build static libraries") variant("pic", default=True, description="Build position independent code") diff --git a/var/spack/repos/builtin/packages/timew/package.py b/var/spack/repos/builtin/packages/timew/package.py new file mode 100644 index 00000000000000..aaf3318511d529 --- /dev/null +++ b/var/spack/repos/builtin/packages/timew/package.py @@ -0,0 +1,22 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Timew(CMakePackage): + """ + Timewarrior is Free and Open Source Software that tracks time from the + command line. + """ + + homepage = "https://timewarrior.net/" + url = "https://github.com/GothenburgBitFactory/timewarrior/releases/download/v1.7.1/timew-1.7.1.tar.gz" + + license("MIT", checked_by="taliaferro") + + version("1.7.1", sha256="5e0817fbf092beff12598537c894ec1f34b0a21019f5a3001fe4e6d15c11bd94") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/tini/package.py b/var/spack/repos/builtin/packages/tini/package.py index 5fdf47d9ae3c27..29b67ea32845d9 100644 --- a/var/spack/repos/builtin/packages/tini/package.py +++ b/var/spack/repos/builtin/packages/tini/package.py @@ -17,4 +17,6 @@ class Tini(CMakePackage): license("MIT") version("0.19.0", sha256="0fd35a7030052acd9f58948d1d900fe1e432ee37103c5561554408bdac6bbf0d") + + depends_on("c", type="build") # generated patch("tini_static_rpath_issue.patch", when="@0.19.0:") diff --git a/var/spack/repos/builtin/packages/tiny-tensor-compiler/package.py b/var/spack/repos/builtin/packages/tiny-tensor-compiler/package.py new file mode 100644 index 00000000000000..cba0e2cb8b4df8 --- /dev/null +++ b/var/spack/repos/builtin/packages/tiny-tensor-compiler/package.py @@ -0,0 +1,52 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + + +class TinyTensorCompiler(CMakePackage): + """A compiler for tensor computations on GPUs and other devices, + supporting the OpenCL, Level Zero, and SYCL runtime.""" + + homepage = "https://github.com/intel/tiny-tensor-compiler" + url = "https://github.com/intel/tiny-tensor-compiler/archive/refs/tags/v0.3.1.tar.gz" + + maintainers("uphoffc") + + license("BSD-3-Clause", checked_by="uphoffc") + + version("0.3.1", sha256="e512b92f9ef8f21362ea4a8f2655338769bc7fcf9de543e3dc7db86b696695b3") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant("shared", default=True, description="Shared library") + variant("level-zero", default=False, description="Build tinytc_ze (Level Zero runtime)") + variant("opencl", default=True, description="Build tintc_cl (OpenCL runtime)") + variant("sycl", default=False, description="Build tinytc_sycl (SYCL runtime)") + + requires("+opencl +level-zero", when="+sycl") + + depends_on("cmake@3.23.0:", type="build") + depends_on("double-batched-fft-library ~sycl ~level-zero ~opencl@0.5.1:", type="link") + depends_on("oneapi-level-zero@1.13:", when="+level-zero") + depends_on("opencl-c-headers@2022.01.04:", when="+opencl") + depends_on("opencl-icd-loader@2022.01.04:", when="+opencl", type="link") + depends_on("re2c@3.0:", type="build") + depends_on("bison@3.8.2:", type="build") + + def cmake_args(self): + cxx_compiler = os.path.basename(self.compiler.cxx) + if self.spec.satisfies("+sycl") and cxx_compiler not in ["icpx"]: + raise InstallError("The tinytc_sycl library requires the oneapi C++ compiler") + + return [ + self.define_from_variant("BUILD_SHARED_LIBS", "shared"), + self.define_from_variant("BUILD_SYCL", "sycl"), + self.define_from_variant("BUILD_LEVEL_ZERO", "level-zero"), + self.define_from_variant("BUILD_OPENCL", "opencl"), + ] diff --git a/var/spack/repos/builtin/packages/tinygltf/package.py b/var/spack/repos/builtin/packages/tinygltf/package.py index 31f7e6581df17c..63c189c263432d 100644 --- a/var/spack/repos/builtin/packages/tinygltf/package.py +++ b/var/spack/repos/builtin/packages/tinygltf/package.py @@ -16,9 +16,13 @@ class Tinygltf(CMakePackage): license("MIT") version("release", branch="release") + version("2.8.21", sha256="e567257d7addde58b0a483832cbaa5dd8f15e5bcaee6f023831e215d1a2c0502") version("2.8.14", sha256="63cd43746c9ddfe5777494500422e831a312299e386fbf80922839dc1a5575f8") version("2.7.0", sha256="a1bbc0b831719e3a809a1bb01ce299a60e80b4e15221f58e822303ba22a69d45") version("2.6.3", sha256="f61e4a501baa7fbf31b18ea0f6815a59204ad0de281f7b04f0168f6bbd17c340") version("2.5.0", sha256="5d85bd556b60b1b69527189293cfa4902957d67fabb8582b6532f23a5ef27ec1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.6:", type="build") diff --git a/var/spack/repos/builtin/packages/tinyobjloader/package.py b/var/spack/repos/builtin/packages/tinyobjloader/package.py index 8f89fb0369edce..49743a4cb8d671 100644 --- a/var/spack/repos/builtin/packages/tinyobjloader/package.py +++ b/var/spack/repos/builtin/packages/tinyobjloader/package.py @@ -16,4 +16,6 @@ class Tinyobjloader(CMakePackage): version("1.0.6", sha256="19ee82cd201761954dd833de551edb570e33b320d6027e0d91455faf7cd4c341") + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8.11:", type="build") diff --git a/var/spack/repos/builtin/packages/tinyxml2/package.py b/var/spack/repos/builtin/packages/tinyxml2/package.py index 4aca62c7e4af58..3c6eb0eb1f8dd7 100644 --- a/var/spack/repos/builtin/packages/tinyxml2/package.py +++ b/var/spack/repos/builtin/packages/tinyxml2/package.py @@ -14,6 +14,10 @@ class Tinyxml2(CMakePackage): license("Zlib") + version("10.0.0", sha256="3bdf15128ba16686e69bce256cc468e76c7b94ff2c7f391cc5ec09e40bff3839") + version("9.0.0", sha256="cc2f1417c308b1f6acc54f88eb70771a0bf65f76282ce5c40e54cfe52952702c") + version("8.0.0", sha256="6ce574fbb46751842d23089485ae73d3db12c1b6639cda7721bf3a7ee862012c") + version("7.0.0", sha256="fa0d1c745d65d4d833e62cb183e23c2034dc7a35ec1a4977e808bdebb9b4fe60") version("6.2.0", sha256="cdf0c2179ae7a7931dba52463741cf59024198bbf9673bf08415bcb46344110f") version("4.0.1", sha256="14b38ef25cc136d71339ceeafb4856bb638d486614103453eccd323849267f20") version("4.0.0", sha256="90add44f06de081047d431c08d7269c25b4030e5fe19c3bc8381c001ce8f258c") @@ -21,3 +25,15 @@ class Tinyxml2(CMakePackage): version("2.2.0", sha256="f891224f32e7a06bf279290619cec80cc8ddc335c13696872195ffb87f5bce67") version("2.1.0", sha256="4bdd6569fdce00460bf9cda0ff5dcff46d342b4595900d849cc46a277a74cce6") version("2.0.2", sha256="3cc3aa09cd1ce77736f23488c7cb24e65e11daed4e870ddc8d352aa4070c7c74") + + depends_on("cxx", type="build") # generated + + variant("shared", default=False, description="Build shared library") + + def cmake_args(self): + args = [] + + if self.spec.satisfies("+shared"): + args.append("-DBUILD_SHARED_LIBS=ON") + + return args diff --git a/var/spack/repos/builtin/packages/tioga/package.py b/var/spack/repos/builtin/packages/tioga/package.py index 8a453c39f9d168..79684d2cbcb66a 100644 --- a/var/spack/repos/builtin/packages/tioga/package.py +++ b/var/spack/repos/builtin/packages/tioga/package.py @@ -20,8 +20,13 @@ class Tioga(CMakePackage): # The original TIOGA repo has possibly been abandoned, # so work on TIOGA has continued in the Exawind project version("develop", git="https://github.com/Exawind/tioga.git", branch="exawind") + version("1.1.0", git="https://github.com/Exawind/tioga.git", tag="v1.1.0") + version("1.0.0", git="https://github.com/Exawind/tioga.git", tag="v1.0.0") version("master", branch="master") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=sys.platform != "darwin", description="Build shared libraries") variant("pic", default=True, description="Position independent code") variant("nodegid", default=True, description="Enable support for global Node IDs") diff --git a/var/spack/repos/builtin/packages/tippecanoe/package.py b/var/spack/repos/builtin/packages/tippecanoe/package.py index 420aa6cc643270..3a38b6971eec4e 100644 --- a/var/spack/repos/builtin/packages/tippecanoe/package.py +++ b/var/spack/repos/builtin/packages/tippecanoe/package.py @@ -18,6 +18,9 @@ class Tippecanoe(MakefilePackage): version("1.36.0", sha256="0e385d1244a0d836019f64039ea6a34463c3c2f49af35d02c3bf241aec41e71b") version("1.34.3", sha256="7a2dd2376a93d66a82c8253a46dbfcab3eaaaaca7bf503388167b9ee251bee54") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("sqlite") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/tiptop/package.py b/var/spack/repos/builtin/packages/tiptop/package.py index 6848c1adf46826..075509922b8e59 100644 --- a/var/spack/repos/builtin/packages/tiptop/package.py +++ b/var/spack/repos/builtin/packages/tiptop/package.py @@ -16,6 +16,8 @@ class Tiptop(AutotoolsPackage): version("master", commit="529886d445ec32febad14246245372a8f244b3eb") + depends_on("c", type="build") # generated + depends_on("papi") depends_on("byacc", type="build") depends_on("flex", type="build") diff --git a/var/spack/repos/builtin/packages/tiramisu/package.py b/var/spack/repos/builtin/packages/tiramisu/package.py index c6e74e1546b997..d30e4196122aa0 100644 --- a/var/spack/repos/builtin/packages/tiramisu/package.py +++ b/var/spack/repos/builtin/packages/tiramisu/package.py @@ -23,6 +23,9 @@ class Tiramisu(CMakePackage, CudaPackage, PythonExtension): version("master", branch="master") version("2023-2-8", commit="2cd0c43cc1656bfa43cfb6e81d06f770cbf7251e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("python", default=True, description="Install python bindings.") extends("python", when="+python") variant( diff --git a/var/spack/repos/builtin/packages/tix/package.py b/var/spack/repos/builtin/packages/tix/package.py index c9513d5e9b6f9c..de73e2516e0427 100644 --- a/var/spack/repos/builtin/packages/tix/package.py +++ b/var/spack/repos/builtin/packages/tix/package.py @@ -21,6 +21,8 @@ class Tix(AutotoolsPackage): version("8.4.3", sha256="562f040ff7657e10b5cffc2c41935f1a53c6402eb3d5f3189113d734fd6c03cb") + depends_on("c", type="build") # generated + extends("tcl", type=("build", "link", "run")) depends_on("tk", type=("build", "link", "run")) @@ -77,12 +79,12 @@ def darwin_fix(self): if "platform=darwin" in self.spec: fix_darwin_install_name(self.prefix.lib.Tix + str(self.version)) - def test(self): + def test_tcl(self): + """Test that tix can be loaded""" test_data_dir = self.test_suite.current_test_data_dir test_file = test_data_dir.join("test.tcl") - self.run_test( - self.spec["tcl"].command.path, test_file, purpose="test that tix can be loaded" - ) + tcl = self.spec["tcl"].command + tcl(test_file) @property def libs(self): diff --git a/var/spack/repos/builtin/packages/tixi/package.py b/var/spack/repos/builtin/packages/tixi/package.py index 269f1477f96135..8540ef640c0cb5 100644 --- a/var/spack/repos/builtin/packages/tixi/package.py +++ b/var/spack/repos/builtin/packages/tixi/package.py @@ -22,6 +22,10 @@ class Tixi(CMakePackage): version("3.0.3", sha256="3584e0cec6ab811d74fb311a9af0663736b1d7f11b81015fcb378efaf5ad3589") version("2.2.4", sha256="9080d2a617b7c411b9b4086de23998ce86e261b88075f38c73d3ce25da94b21c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "shared", default=True, description="Enables the build of shared libraries", when="@3.0.3:" ) diff --git a/var/spack/repos/builtin/packages/tkrzw/package.py b/var/spack/repos/builtin/packages/tkrzw/package.py index 1b8f584b8c00c0..17b2250421c979 100644 --- a/var/spack/repos/builtin/packages/tkrzw/package.py +++ b/var/spack/repos/builtin/packages/tkrzw/package.py @@ -16,6 +16,7 @@ class Tkrzw(AutotoolsPackage): license("Apache-2.0") version("master", branch="master") + version("1.0.29", sha256="abaabd6fc89a19ed8a202ac3711bc3b0763d928bc3a8eeeea73a3679f7e7f790") version("0.9.44", sha256="088ac619fbf7fc22c110674b3f8fe8d8573a1d7088e5616b268fd9f68ba25650") version("0.9.43", sha256="60f7b579edb4f911ecaf35ff6c07f53b3d566424d8bf179b1991ade5071f0bbc") version("0.9.42", sha256="135fb404d5a1b0bcee717f8e648a6f5ff140ec30069fecfde3b380f611356535") @@ -61,6 +62,9 @@ class Tkrzw(AutotoolsPackage): version("0.9.2", sha256="9040af148ab3f35c6f1d4c83f2eba8b68625dbd760f2c0537a9981dbc9bbc661") version("0.9.1", sha256="1062502f93d4a9b387372d89265a9ede1704c6bcadd9aac23f5fc8383e26045a") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "compression", values=any_combination_of("zlib", "lz4", "lzma", "zstd"), diff --git a/var/spack/repos/builtin/packages/tl-expected/package.py b/var/spack/repos/builtin/packages/tl-expected/package.py index cf91fbf1a4a94b..0bd6107cfc9c93 100644 --- a/var/spack/repos/builtin/packages/tl-expected/package.py +++ b/var/spack/repos/builtin/packages/tl-expected/package.py @@ -23,3 +23,5 @@ class TlExpected(CMakePackage): # so I will use the latest commit at the time of writing: version("2022-11-24", commit="b74fecd4448a1a5549402d17ddc51e39faa5020c") version("1.0.0", sha256="8f5124085a124113e75e3890b4e923e3a4de5b26a973b891b3deb40e19c03cee") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/tldd/package.py b/var/spack/repos/builtin/packages/tldd/package.py index b9a75f9703f1a1..4be634fdf2539b 100644 --- a/var/spack/repos/builtin/packages/tldd/package.py +++ b/var/spack/repos/builtin/packages/tldd/package.py @@ -17,6 +17,8 @@ class Tldd(MakefilePackage): version("2018-10-05", commit="61cb512cc992ea6cbb7239e99ec7ac92ea072507") version("master", branch="master") + depends_on("cxx", type="build") # generated + depends_on("pstreams@0.8.0:") def patch(self): diff --git a/var/spack/repos/builtin/packages/tmux/package.py b/var/spack/repos/builtin/packages/tmux/package.py index f9c77ad0fdc596..11c1f7fa5045ee 100644 --- a/var/spack/repos/builtin/packages/tmux/package.py +++ b/var/spack/repos/builtin/packages/tmux/package.py @@ -20,6 +20,7 @@ class Tmux(AutotoolsPackage): license("ISC") + version("3.4", sha256="551ab8dea0bf505c0ad6b7bb35ef567cdde0ccb84357df142c254f35a23e19aa") version("3.3a", sha256="e4fd347843bd0772c4f48d6dde625b0b109b7a380ff15db21e97c11a4dcdf93f") version("3.2a", sha256="551553a4f82beaa8dadc9256800bcc284d7c000081e47aa6ecbb6ff36eacd05f") version("3.2", sha256="664d345338c11cbe429d7ff939b92a5191e231a7c1ef42f381cebacb1e08a399") @@ -42,6 +43,8 @@ class Tmux(AutotoolsPackage): version("1.9a", sha256="c5e3b22b901cf109b20dab54a4a651f0471abd1f79f6039d79b250d21c2733f5") version("master", branch="master") + depends_on("c", type="build") # generated + variant( "utf8proc", default=False, description="Build with UTF-8 support from utf8proc library" ) @@ -57,6 +60,8 @@ class Tmux(AutotoolsPackage): depends_on("automake", when="@master") depends_on("autoconf", when="@master") + depends_on("yacc", type="build", when="@3:") + conflicts("+static", when="platform=darwin", msg="Static build not supported on MacOS") @run_before("autoreconf") diff --git a/var/spack/repos/builtin/packages/tnftp/package.py b/var/spack/repos/builtin/packages/tnftp/package.py index 00a70d38e02ad3..db140c2474b4a9 100644 --- a/var/spack/repos/builtin/packages/tnftp/package.py +++ b/var/spack/repos/builtin/packages/tnftp/package.py @@ -17,5 +17,7 @@ class Tnftp(AutotoolsPackage): version("20230507", sha256="be0134394bd7d418a3b34892b0709eeb848557e86474e1786f0d1a887d3a6580") + depends_on("c", type="build") # generated + depends_on("bison") depends_on("ncurses") diff --git a/var/spack/repos/builtin/packages/toml-f/package.py b/var/spack/repos/builtin/packages/toml-f/package.py index 4a55fa0bb56bdb..544f5b420acf3f 100644 --- a/var/spack/repos/builtin/packages/toml-f/package.py +++ b/var/spack/repos/builtin/packages/toml-f/package.py @@ -25,4 +25,6 @@ class TomlF(MesonPackage): version("0.2.4", sha256="ebfeb1e201725b98bae3e656bde4eea2db90154efa8681de758f1389fec902cf") version("0.2.3", sha256="2dca7ff6d3e35415cd92454c31560d2b656c014af8236be09c54c13452e4539c") + depends_on("fortran", type="build") # generated + depends_on("meson@0.57.2:", type="build") diff --git a/var/spack/repos/builtin/packages/toml11/package.py b/var/spack/repos/builtin/packages/toml11/package.py index cec19cf10ae529..79038f5c6b48e7 100644 --- a/var/spack/repos/builtin/packages/toml11/package.py +++ b/var/spack/repos/builtin/packages/toml11/package.py @@ -18,6 +18,11 @@ class Toml11(CMakePackage): license("MIT") + version("4.0.2", sha256="d1bec1970d562d328065f2667b23f9745a271bf3900ca78e92b71a324b126070") + version("4.0.1", sha256="96965cb00ca7757c611c169cd5a6fb15736eab1cd1c1a88aaa62ad9851d926aa") + version("4.0.0", sha256="f3dc3095f22e38745a5d448ac629f69b7ee76d2b3e6d653e4ce021deb7f7266e") + version("3.8.1", sha256="6a3d20080ecca5ea42102c078d3415bef80920f6c4ea2258e87572876af77849") + version("3.8.0", sha256="36ce64b09f9151b57ba1970f12a591006fcae17b751ba011314c1f5518e77bc7") version("3.7.1", sha256="afeaa9aa0416d4b6b2cd3897ca55d9317084103077b32a852247d8efd4cf6068") version("3.7.0", sha256="a0b6bec77c0e418eea7d270a4437510884f2fe8f61e7ab121729624f04c4b58e") version("3.6.1", sha256="ca4c390ed8da0d77ae6eca30e70ab0bf5cc92adfc1bc2f71a2066bc5656d8d96") @@ -29,3 +34,14 @@ class Toml11(CMakePackage): version("3.2.1", sha256="370f17409cfcbf3f629728ed7ec2e1573544058615fb5d066f4f7c14693143a9") version("3.2.0", sha256="3d54cac38ea24477190e0535377e824bf06562970ef4d35b59aa9729437e1019") version("3.1.0", sha256="3a118f32e5343998f37be9807c72fd11c3168fe12a5b1abfdc0f1e60de6380a4") + + depends_on("cxx", type="build") # generated + + variant( + "cxx_std", default="11", description="C++ standard", values=("11", "14", "17"), multi=False + ) + + @when("@3.8.0:") + def cmake_args(self): + args = [self.define_from_variant("CMAKE_CXX_STANDARD", "cxx_std")] + return args diff --git a/var/spack/repos/builtin/packages/tophat/package.py b/var/spack/repos/builtin/packages/tophat/package.py index a2083894dc5db7..ebf9794514457d 100644 --- a/var/spack/repos/builtin/packages/tophat/package.py +++ b/var/spack/repos/builtin/packages/tophat/package.py @@ -17,6 +17,9 @@ class Tophat(AutotoolsPackage): version("2.1.2", sha256="15016b82255dad085d4ee7d970e50f0e53a280d466335553d47790d8344ff4b1") version("2.1.1", sha256="991b1b7c840a5f5c4e9a15b2815983257d2b0748246af0b9094c7d07552b023e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") # 2.1.1 only builds with automake@1.15.1. There's a patch here: # https://github.com/spack/spack/pull/8244, which was incorporated diff --git a/var/spack/repos/builtin/packages/totalview/package.py b/var/spack/repos/builtin/packages/totalview/package.py index ff20fe302f0ab3..ea1c84b9e6685a 100644 --- a/var/spack/repos/builtin/packages/totalview/package.py +++ b/var/spack/repos/builtin/packages/totalview/package.py @@ -44,13 +44,6 @@ class Totalview(Package): # resource once the target architecture is known. # Version 2022.3.6 - resource( - name="crayx86", - url="file://totalview_2022.3.6_linux_x86-64.tar", - destination=".", - sha256="a2639c52bfd4c7484b728d6a0158239074ff0e0c52208a5452b12b878016a519", - when="@2022.3.6 platform=cray target=x86_64:", - ) resource( name="x86-64", url="file://totalview.2022.3.6-linux-x86-64.tar", @@ -81,13 +74,6 @@ class Totalview(Package): ) # Version 2022.2.13 - resource( - name="crayx86", - url="file://totalview_2022.2.13_linux_x86-64.tar", - destination=".", - sha256="aebd11b837ce18b8200859ea762caa56e2cea346daa114f2841aa0f05a422309", - when="@2022.2.13 platform=cray target=x86_64:", - ) resource( name="x86-64", url="file://totalview.2022.2.13-linux-x86-64.tar", @@ -118,13 +104,6 @@ class Totalview(Package): ) # Version 2022.1.11 - resource( - name="crayx86", - url="file://totalview_2022.1.11_linux_x86-64.tar", - destination=".", - sha256="3ec9a7d702572dbbafa41726a036c94b549f9a5911ed6fd6aa55f7b377554bac", - when="@2022.1.11 platform=cray target=x86_64:", - ) resource( name="x86-64", url="file://totalview.2022.1.11-linux-x86-64.tar", @@ -155,13 +134,6 @@ class Totalview(Package): ) # Version 2021.4.10 - resource( - name="crayx86", - url="file://totalview_2021.4.10_linux_x86-64.tar", - destination=".", - sha256="7e5509b2cfb219100b0032304bdad7d422657c0736c386ba64bdb1bf11d10a1d", - when="@2021.4.10 platform=cray target=x86_64:", - ) resource( name="x86-64", url="file://totalview.2021.4.10-linux-x86-64.tar", @@ -230,8 +202,6 @@ def install(self, spec, prefix): arg_list.extend(["-platform", "linux-x86-64"]) elif spec.target.family == "x86_64" and spec.platform == "darwin": arg_list.extend(["-platform", "darwin-x86"]) - elif spec.target.family == "x86_64" and spec.platform == "cray": - arg_list.extend(["-platform", "linux-x86-64"]) elif spec.target.family == "x86": arg_list.extend(["-platform", "linux-x86"]) elif spec.target.family == "aarch64": diff --git a/var/spack/repos/builtin/packages/tpm2-tss/package.py b/var/spack/repos/builtin/packages/tpm2-tss/package.py index 1cbb0a75754423..bc3f80a1bdc8ab 100644 --- a/var/spack/repos/builtin/packages/tpm2-tss/package.py +++ b/var/spack/repos/builtin/packages/tpm2-tss/package.py @@ -14,10 +14,13 @@ class Tpm2Tss(AutotoolsPackage): license("BSD-2-Clause") + version("4.1.1", sha256="da5b09d5a82d381f7bbd2e1d2db494213f7148659cfaf1b9e423b4df62f48504") version("3.0.0", sha256="e88e91aeee2e01ccc45596fb8afcc3b521a660dcebe5a6e1b14ea5e9e5c15cf5") version("2.4.2", sha256="1cec5e834a6a750b138cabcd100b3fcd12b16cd21fa4f9103739914743511f75") version("2.4.1", sha256="cc6f0691307f3c65d5a1375e2cd22508cc72850dbc70eb820b892f0b3d0cbea2") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/tracer/package.py b/var/spack/repos/builtin/packages/tracer/package.py index a6e4e70c6d9c76..3bc8d4a8d696e3 100644 --- a/var/spack/repos/builtin/packages/tracer/package.py +++ b/var/spack/repos/builtin/packages/tracer/package.py @@ -19,6 +19,8 @@ class Tracer(MakefilePackage): version("develop", branch="master") version("2.2", tag="v2.2", commit="fdd1b07a1a0faca14aac53dcbcbccc44237ae7cb") + depends_on("cxx", type="build") # generated + variant("otf2", default=True, description="Use OTF2 traces for simulation") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/tracy-client/package.py b/var/spack/repos/builtin/packages/tracy-client/package.py index 3237119b8783d5..a1c0854166d3cd 100644 --- a/var/spack/repos/builtin/packages/tracy-client/package.py +++ b/var/spack/repos/builtin/packages/tracy-client/package.py @@ -22,6 +22,9 @@ class TracyClient(CMakePackage): version("0.8.2", sha256="4784eddd89c17a5fa030d408392992b3da3c503c872800e9d3746d985cfcc92a") version("0.8.1", sha256="004992012b2dc879a9f6d143cbf94d7ea30e88135db3ef08951605d214892891") + depends_on("c", type="build") + depends_on("cxx", type="build") + variant("shared", default=True, description="Build the client library as a shared library") tracy_options = { diff --git a/var/spack/repos/builtin/packages/tracy/package.py b/var/spack/repos/builtin/packages/tracy/package.py index fbb74fd7df4f34..e9102607c853b9 100644 --- a/var/spack/repos/builtin/packages/tracy/package.py +++ b/var/spack/repos/builtin/packages/tracy/package.py @@ -22,6 +22,9 @@ class Tracy(MakefilePackage): version("0.8.2", sha256="4784eddd89c17a5fa030d408392992b3da3c503c872800e9d3746d985cfcc92a") version("0.8.1", sha256="004992012b2dc879a9f6d143cbf94d7ea30e88135db3ef08951605d214892891") + depends_on("c", type="build") + depends_on("cxx", type="build") + depends_on("capstone") depends_on("dbus") depends_on("freetype") diff --git a/var/spack/repos/builtin/packages/tramonto/package.py b/var/spack/repos/builtin/packages/tramonto/package.py index 718949a66a4f55..627872ac675990 100644 --- a/var/spack/repos/builtin/packages/tramonto/package.py +++ b/var/spack/repos/builtin/packages/tramonto/package.py @@ -14,6 +14,9 @@ class Tramonto(CMakePackage): version("develop", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("trilinos@:12+nox") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/transposome/package.py b/var/spack/repos/builtin/packages/transposome/package.py index 0a07f5c5703ee6..386f3f9cd5075a 100644 --- a/var/spack/repos/builtin/packages/transposome/package.py +++ b/var/spack/repos/builtin/packages/transposome/package.py @@ -16,4 +16,6 @@ class Transposome(PerlPackage): version("0.12.1", sha256="fc3706a883cba58626ccd753df7a77f0baf52ff3b1d8aa7644a7f474f296a603") version("0.11.2", sha256="f0bfdb33c34ada726b36c7b7ed6defa8540a7f8abe08ad46b3ccfec5dcd4720d") + depends_on("cxx", type="build") # generated + depends_on("blast-plus") diff --git a/var/spack/repos/builtin/packages/transset/package.py b/var/spack/repos/builtin/packages/transset/package.py index 7df51842e3d005..4c0dd0d9950a49 100644 --- a/var/spack/repos/builtin/packages/transset/package.py +++ b/var/spack/repos/builtin/packages/transset/package.py @@ -18,6 +18,8 @@ class Transset(AutotoolsPackage, XorgPackage): version("1.0.2", sha256="5c7d7d1bac36137f41ac3db84d7ed9b9fdac868608572bcba0bc1de40510ca67") version("1.0.1", sha256="87c560e69e05ae8a5bad17ff62ac31cda43a5065508205b109c756c0ab857d55") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("xproto@7.0.17:") diff --git a/var/spack/repos/builtin/packages/tree-sitter/package.py b/var/spack/repos/builtin/packages/tree-sitter/package.py index bfb36001fea734..c6872b43a916a2 100644 --- a/var/spack/repos/builtin/packages/tree-sitter/package.py +++ b/var/spack/repos/builtin/packages/tree-sitter/package.py @@ -19,12 +19,25 @@ class TreeSitter(MakefilePackage): license("MIT") + version("0.22.6", sha256="e2b687f74358ab6404730b7fb1a1ced7ddb3780202d37595ecd7b20a8f41861f") + version("0.22.5", sha256="6bc22ca7e0f81d77773462d922cf40b44bfd090d92abac75cb37dbae516c2417") + version("0.22.4", sha256="919b750da9af1260cd989498bc84c63391b72ee2aa2ec20fc84882544eb7a229") + version("0.22.3", sha256="b394b948646e67c81319f3b859a09b50280b16c66b4445ae1958b35aa4eed586") + version("0.22.2", sha256="0c829523b876d4a37e1bd46a655c133a93669c0fe98fcd84972b168849c27afc") + version("0.22.1", sha256="b21065e78da33e529893c954e712ad15d9ad44a594b74567321d4a3a007d6090") + version("0.22.0", sha256="1cc0c832c6cc3d04f0b702247fac3dac45f958b0ee1f946619b7ae7b67258060") + version("0.21.0", sha256="6bb60e5b63c1dc18aba57a9e7b3ea775b4f9ceec44cc35dac4634d26db4eb69c") + version("0.20.9", sha256="9b2fd489a7281e3a7e5e7cbbf3a974e5a6a115889ae65676d61b79bdae96464e") version("0.20.8", sha256="6181ede0b7470bfca37e293e7d5dc1d16469b9485d13f13a605baec4a8b1f791") + version("0.20.7", sha256="b355e968ec2d0241bbd96748e00a9038f83968f85d822ecb9940cbe4c42e182e") version("0.20.6", sha256="4d37eaef8a402a385998ff9aca3e1043b4a3bba899bceeff27a7178e1165b9de") version("0.20.4", sha256="979ad0b36eb90975baf0c65d155d106276cac08afb1c2fe0ad54d4b7d498ce39") version("0.20.3", sha256="ab52fe93e0c658cff656b9d10d67cdd29084247052964eba13ed6f0e9fa3bd36") version("0.20.2", sha256="2a0445f8172bbf83db005aedb4e893d394e2b7b33251badd3c94c2c5cc37c403") version("0.20.1", sha256="12a3f7206af3028dbe8a0de50d8ebd6d7010bf762db918acae76fc7585f1258d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def edit(self, spec, prefix): env["PREFIX"] = prefix diff --git a/var/spack/repos/builtin/packages/treelite/package.py b/var/spack/repos/builtin/packages/treelite/package.py index c3ee15474c9af1..a7bf2c853fb799 100644 --- a/var/spack/repos/builtin/packages/treelite/package.py +++ b/var/spack/repos/builtin/packages/treelite/package.py @@ -17,6 +17,9 @@ class Treelite(CMakePackage): version("0.93", sha256="7d347372f7fdc069904afe93e69ed0bf696ba42d271fe2f8bf6835d2ab2f45d5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("protobuf", default=False, description="Build with protobuf") variant("python", default=True, description="Build with python support") @@ -26,6 +29,8 @@ class Treelite(CMakePackage): depends_on("py-wheel", when="+python", type="build") depends_on("py-setuptools", when="+python", type="build") depends_on("py-numpy", when="+python", type=("build", "run")) + # https://github.com/dmlc/treelite/issues/560 + depends_on("py-numpy@:1", when="@:4.2.0+python", type=("build", "run")) depends_on("py-scipy", when="+python", type=("build", "run")) build_directory = "build" diff --git a/var/spack/repos/builtin/packages/trexio/package.py b/var/spack/repos/builtin/packages/trexio/package.py index e47b403096833f..540bd82eab225a 100644 --- a/var/spack/repos/builtin/packages/trexio/package.py +++ b/var/spack/repos/builtin/packages/trexio/package.py @@ -23,6 +23,9 @@ class Trexio(AutotoolsPackage): version("2.1.0", sha256="232866c943b98fa8a42d34b55e940f7501634eb5bd426555ba970f5c09775e83") version("2.0.0", sha256="6eeef2da44259718b43991eedae4b20d4f90044e38f3b44a8beea52c38b14cb4") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("hdf5", default=True, description="Enable HDF5 support") depends_on("emacs@26.0:", type="build", when="@master") diff --git a/var/spack/repos/builtin/packages/trf/package.py b/var/spack/repos/builtin/packages/trf/package.py index 7d02ecce6b19f5..3efb595978ca4d 100644 --- a/var/spack/repos/builtin/packages/trf/package.py +++ b/var/spack/repos/builtin/packages/trf/package.py @@ -38,6 +38,8 @@ class Trf(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + @when("@4.07b") def autoreconf(self, spec, prefix): touch("configure") diff --git a/var/spack/repos/builtin/packages/trident/package.py b/var/spack/repos/builtin/packages/trident/package.py index 53839256f4f651..810763971ad074 100644 --- a/var/spack/repos/builtin/packages/trident/package.py +++ b/var/spack/repos/builtin/packages/trident/package.py @@ -17,6 +17,7 @@ class Trident(Package): license("Apache-2.0") + version("24.02.0", sha256="a0e73a935079114e8a7010766e8a229084638c3c58a7ab6688c51b2d8fd1efa0") version("23.01.1", sha256="d0aedf2446e09b15abe9b0f052f42145c6acf23014a6e009e22cff5a2ad6c77d") version("20.01.1", sha256="02ba92e569916b98fb1b563c5ef03a94fd7981c3ac1ecb47e69ebb45471dc976") version("20.01.0", sha256="5de190579acf62f5e9945dfd45aeb21989272c4972e85cb10256b7ec605c29c7") diff --git a/var/spack/repos/builtin/packages/trilinos-catalyst-ioss-adapter/package.py b/var/spack/repos/builtin/packages/trilinos-catalyst-ioss-adapter/package.py index 891929bdb48647..5dd2a1f27099fd 100644 --- a/var/spack/repos/builtin/packages/trilinos-catalyst-ioss-adapter/package.py +++ b/var/spack/repos/builtin/packages/trilinos-catalyst-ioss-adapter/package.py @@ -15,9 +15,15 @@ class TrilinosCatalystIossAdapter(CMakePackage): version("develop", branch="develop") version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("bison", type="build") depends_on("flex", type="build") - depends_on("paraview+mpi+python+osmesa") + depends_on("paraview+mpi+python") + depends_on("gl", type="run") + requires("^[virtuals=gl] osmesa", msg="OSMesa is required for paraview") depends_on("py-numpy", type=("build", "run")) # Here we avoid paraview trying to use netcdf-c~parallel-netcdf # which is netcdf-c's default, even though paraview depends on 'netcdf-c' diff --git a/var/spack/repos/builtin/packages/trilinos/package.py b/var/spack/repos/builtin/packages/trilinos/package.py index c6629d58f998a4..ce7ce27fb746e2 100644 --- a/var/spack/repos/builtin/packages/trilinos/package.py +++ b/var/spack/repos/builtin/packages/trilinos/package.py @@ -5,6 +5,7 @@ import os import pathlib +import re import sys from spack.build_environment import dso_suffix @@ -42,6 +43,7 @@ class Trilinos(CMakePackage, CudaPackage, ROCmPackage): version("master", branch="master") version("develop", branch="develop") + version("15.1.1", sha256="2108d633d2208ed261d09b2d6b2fbae7a9cdc455dd963c9c94412d38d8aaefe4") version("15.0.0", sha256="5651f1f967217a807f2c418a73b7e649532824dbf2742fa517951d6cc11518fb") version("14.4.0", sha256="8e7d881cf6677aa062f7bfea8baa1e52e8956aa575d6a4f90f2b6f032632d4c6") version("14.2.0", sha256="c96606e5cd7fc9d25b9dc20719cd388658520d7cbbd2b4de77a118440d1e0ccb") @@ -69,6 +71,10 @@ class Trilinos(CMakePackage, CudaPackage, ROCmPackage): version("11.14.2", sha256="f22b2b0df7b88e28b992e19044ba72b845292b93cbbb3a948488199647381119") version("11.14.1", sha256="f10fc0a496bf49427eb6871c80816d6e26822a39177d850cc62cf1484e4eec07") + depends_on("c", type="build") + depends_on("cxx", type="build") + depends_on("fortran", type="build", when="+fortran") + # ###################### Variants ########################## # Build options @@ -102,6 +108,13 @@ class Trilinos(CMakePackage, CudaPackage, ROCmPackage): variant("uvm", default=False, when="@13.2: +cuda", description="Turn on UVM for CUDA build") variant("wrapper", default=False, description="Use nvcc-wrapper for CUDA build") + # Makes the Teuchos Memory Management classes (Teuchos::RCP, Teuchos::Ptr, Teuchos::Array, + # Teuchos::ArrayView, and Teuchos::ArrayRCP) thread-safe. Requires at least the OMP kokkos + # backend to be enabled. Without, this seemingly does nothing + variant( + "threadsafe", default=False, when="+openmp", description="Enable threadsafe in Teuchos" + ) + # TPLs (alphabet order) variant("adios2", default=False, description="Enable ADIOS2") variant("boost", default=False, description="Compile with Boost") @@ -243,6 +256,9 @@ class Trilinos(CMakePackage, CudaPackage, ROCmPackage): conflicts("@:12 gotype=long") with when("+piro"): conflicts("~stratimikos") + conflicts("~thyra") + conflicts("~tpetra") + conflicts("@15: ~teko") conflicts("~nox") # Tpetra stack @@ -292,6 +308,10 @@ class Trilinos(CMakePackage, CudaPackage, ROCmPackage): conflicts("~ifpack") conflicts("~aztec") + with when("+tempus"): + conflicts("~nox") + conflicts("~thyra") + # Known requirements from tribits dependencies conflicts("~thyra", when="+stratimikos") conflicts("+adelus", when="~kokkos") @@ -302,7 +322,6 @@ class Trilinos(CMakePackage, CudaPackage, ROCmPackage): conflicts("+minitensor", when="~boost") conflicts("+phalanx", when="~sacado") conflicts("+stokhos", when="~kokkos") - conflicts("+tempus", when="~nox") # Only allow DTK with Trilinos 12.14, 12.18 conflicts("+dtk", when="~boost") @@ -318,6 +337,9 @@ class Trilinos(CMakePackage, CudaPackage, ROCmPackage): conflicts("+strumpack", when="@:13.0") # Can only use one type of SuperLU conflicts("+superlu-dist", when="+superlu") + # Amesos and Ifpack only support up to SuperLU 4.x.y interfaces + conflicts("+amesos", when="+superlu@5:") + conflicts("+ifpack", when="+superlu@5:") # For Trilinos v11 we need to force SuperLUDist=OFF, since only the # deprecated SuperLUDist v3.3 together with an Amesos patch is working. conflicts("+superlu-dist", when="@11.4.1:11.14.3") @@ -383,29 +405,32 @@ class Trilinos(CMakePackage, CudaPackage, ROCmPackage): # ###################### Dependencies ########################## # External Kokkos - depends_on("kokkos@4.1.00", when="@14.4.0: +kokkos") + depends_on("kokkos@4.3.01", when="@master: +kokkos") + depends_on("kokkos@4.2.01", when="@15.1.0:15.1.1 +kokkos") + depends_on("kokkos@4.1.00", when="@14.4.0:15.0.0 +kokkos") + depends_on("kokkos +wrapper", when="trilinos@14.4.0: +kokkos +wrapper") depends_on("kokkos ~wrapper", when="trilinos@14.4.0: +kokkos ~wrapper") for a in CudaPackage.cuda_arch_values: - arch_str = "+cuda cuda_arch=" + a - kokkos_spec = "kokkos@4.1.00 " + arch_str - depends_on(kokkos_spec, when="@14.4.0 +kokkos " + arch_str) + arch_str = "+cuda cuda_arch={0}".format(a) + kokkos_spec = "kokkos {0}".format(arch_str) + depends_on(kokkos_spec, when="@14.4.0: +kokkos {0}".format(arch_str)) for a in ROCmPackage.amdgpu_targets: arch_str = "+rocm amdgpu_target={0}".format(a) - kokkos_spec = "kokkos@4.1.00 {0}".format(arch_str) - depends_on(kokkos_spec, when="@14.4.0 +kokkos {0}".format(arch_str)) + kokkos_spec = "kokkos {0}".format(arch_str) + depends_on(kokkos_spec, when="@14.4.0: +kokkos {0}".format(arch_str)) depends_on("adios2", when="+adios2") depends_on("binder@1.3:", when="@15: +python", type="build") depends_on("blas") depends_on("boost+graph+math+exception+stacktrace", when="+boost") - depends_on("boost+graph+math+exception+stacktrace", when="@:14.0.0 +stk") + depends_on("boost+graph+math+exception+stacktrace", when="@:13.4.0 +stk") depends_on("cgns", when="+exodus") depends_on("cmake@3.23:", type="build", when="@14.0.0:") depends_on("hdf5+hl", when="+hdf5") - for plat in ["cray", "darwin", "linux"]: + for plat in ["darwin", "linux"]: depends_on("hypre~internal-superlu~int64", when="+hypre platform=%s" % plat) depends_on("hypre-cmake~int64", when="+hypre platform=windows") depends_on("kokkos-nvcc-wrapper", when="+wrapper") @@ -429,9 +454,11 @@ class Trilinos(CMakePackage, CudaPackage, ROCmPackage): depends_on("scalapack", when="+mumps") depends_on("scalapack", when="+strumpack+mpi") depends_on("strumpack+shared", when="+strumpack") - depends_on("suite-sparse", when="+suite-sparse") + depends_on("suite-sparse@:7.3.1", when="+suite-sparse") depends_on("superlu-dist", when="+superlu-dist") - depends_on("superlu@4.3 +pic", when="+superlu") + depends_on("superlu@3:5.2", when="@12.18.1: +superlu") + depends_on("superlu@3:5.1.1", when="@12.14.1 +superlu") + depends_on("superlu@3:4", when="@:12.12.1 +superlu") depends_on("swig", when="@:14 +python") depends_on("zlib-api", when="+zoltan") @@ -583,6 +610,30 @@ def cmake_args(self): define = self.define define_from_variant = self.define_from_variant + if self.spec.satisfies("@master: +kokkos"): + with open( + os.path.join(self.stage.source_path, "packages", "kokkos", "CMakeLists.txt") + ) as f: + all_txt = f.read() + r = dict( + re.findall(r".*set\s?\(\s?Kokkos_VERSION_(MAJOR|MINOR|PATCH)\s?(\d+)", all_txt) + ) + kokkos_version_in_trilinos_source = Version( + ".".join([r["MAJOR"], r["MINOR"], r["PATCH"].zfill(2)]) + ) + kokkos_version_specified = spec["kokkos"].version + if kokkos_version_in_trilinos_source != kokkos_version_specified: + raise InstallError( + "For Trilinos@[master,develop], ^kokkos version in spec must " + "match version in Trilinos source code. Specify ^kokkos@{0} ".format( + kokkos_version_in_trilinos_source + ) + + "for trilinos@[master,develop] instead of ^kokkos@{0}.\n".format( + kokkos_version_specified + ) + + "Trilinos recipe maintainers, please update the ^kokkos version range" + ) + def _make_definer(prefix): def define_enable(suffix, value=None): key = prefix + suffix @@ -619,6 +670,7 @@ def define_enable(suffix, value=None): define_trilinos_enable( "EXPLICIT_INSTANTIATION", "explicit_template_instantiation" ), + define_from_variant("Trilinos_ENABLE_THREAD_SAFE", "threadsafe"), ] ) diff --git a/var/spack/repos/builtin/packages/trimal/package.py b/var/spack/repos/builtin/packages/trimal/package.py index abf454f927c554..5f4ba78289ed7b 100644 --- a/var/spack/repos/builtin/packages/trimal/package.py +++ b/var/spack/repos/builtin/packages/trimal/package.py @@ -17,6 +17,8 @@ class Trimal(MakefilePackage): version("1.4.1", sha256="cb8110ca24433f85c33797b930fa10fe833fa677825103d6e7f81dd7551b9b4e") + depends_on("cxx", type="build") # generated + build_directory = "source" def install(self, sinstall_treepec, prefix): diff --git a/var/spack/repos/builtin/packages/trinity/package.py b/var/spack/repos/builtin/packages/trinity/package.py index 2edfaefc9b34f6..8195ddda8f8058 100644 --- a/var/spack/repos/builtin/packages/trinity/package.py +++ b/var/spack/repos/builtin/packages/trinity/package.py @@ -46,6 +46,9 @@ class Trinity(MakefilePackage): ) version("2.6.6", sha256="868dfadeefaf2d3c6150a88d5e86fbc09466d69bbf4a65f70b4f5a7485668984") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake", type="build") depends_on("java@8:", type=("build", "run")) depends_on("bowtie2") diff --git a/var/spack/repos/builtin/packages/trnascan-se/package.py b/var/spack/repos/builtin/packages/trnascan-se/package.py index c7e043f505a216..d22647f2c694ed 100644 --- a/var/spack/repos/builtin/packages/trnascan-se/package.py +++ b/var/spack/repos/builtin/packages/trnascan-se/package.py @@ -14,16 +14,19 @@ class TrnascanSe(AutotoolsPackage): license("GPL-3.0-or-later") + version("2.0.12", sha256="96fa4af507cd918c1c623763d9260bd6ed055d091662b44314426f6bbf447251") version("2.0.11", sha256="29b74edd0f84ad88139035e119b66397c54a37428e0b61c66a1b3d4733adcd1e") version("2.0.0", sha256="0dde1c07142e4bf77b21d53ddf3eeb1ef8c52248005a42323d13f8d7c798100c") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("infernal@1.1:", type="run", when="@2.0.0:") def patch(self): filter_file( "infernal_dir: {bin_dir}", - "infernal_dir: %s" % self.spec["infernal"].prefix.bin, + f"infernal_dir: {self.spec['infernal'].prefix.bin}", "tRNAscan-SE.conf.src", string=True, ) diff --git a/var/spack/repos/builtin/packages/trompeloeil/package.py b/var/spack/repos/builtin/packages/trompeloeil/package.py index 1cd132278a582f..f2ed10d5272618 100644 --- a/var/spack/repos/builtin/packages/trompeloeil/package.py +++ b/var/spack/repos/builtin/packages/trompeloeil/package.py @@ -17,6 +17,9 @@ class Trompeloeil(CMakePackage): license("BSL-1.0") version("master", branch="master") + version("47", sha256="4a1d79260c1e49e065efe0817c8b9646098ba27eed1802b0c3ba7d959e4e5e84") version("45", sha256="124b0aa45d84415193719376b6557fc1f1180cbfebf4dc4f7ca247cb404d6bd8") version("44", sha256="004877db6ba22f24c7867e112e081eeb68858122f55ebe7c7dd9d8d9e3b46c88") version("43", sha256="86a0afa2e97347202a0a883ab43da78c1d4bfff0d6cb93205cfc433d0d9eb9eb") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/truchas/package.py b/var/spack/repos/builtin/packages/truchas/package.py index ad31afc053ee39..ded94cb68ff979 100644 --- a/var/spack/repos/builtin/packages/truchas/package.py +++ b/var/spack/repos/builtin/packages/truchas/package.py @@ -27,6 +27,10 @@ class Truchas(CMakePackage): version("23.06", sha256="a786caba5129d7e33ba42a06751d6c570bd3b9697e3404276a56216d27820c68") version("22.04.1", sha256="ed2000f27ee5c4bd3024063a374023878c61e8a3c76c37542fffd341d1226dc1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # ------------------------------------------------------------ # # Variants # ------------------------------------------------------------ # diff --git a/var/spack/repos/builtin/packages/tskit/package.py b/var/spack/repos/builtin/packages/tskit/package.py index 54445ec56227fc..8a03cc558a9698 100644 --- a/var/spack/repos/builtin/packages/tskit/package.py +++ b/var/spack/repos/builtin/packages/tskit/package.py @@ -15,8 +15,11 @@ class Tskit(PythonPackage): license("MIT") + version("0.5.6", sha256="ddfe213f1cb063cdb6982177230a2805ecd7dfc7ccd73026e13878abffd2ce46") version("0.3.1", sha256="b9c5a9b2fb62a615e389036946345ef8a35b09f1ffee541995b16f97fedb3d36") + depends_on("c", type="build") # generated + depends_on("python@3.6:", type=("build", "run")) depends_on("py-setuptools", type=("build", "run")) depends_on("py-svgwrite", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/tulip/package.py b/var/spack/repos/builtin/packages/tulip/package.py index 226a01c5bfae19..aa30d842f14146 100644 --- a/var/spack/repos/builtin/packages/tulip/package.py +++ b/var/spack/repos/builtin/packages/tulip/package.py @@ -24,6 +24,9 @@ class Tulip(CMakePackage): version("5.4.0", sha256="2175e4e1a79028ab7a2479e882242f304fd3e01fedf80e1f29f8f5e9a6eb1325") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + extends("python") depends_on("py-pyqt5", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/turbine/package.py b/var/spack/repos/builtin/packages/turbine/package.py index 801bf8e5a8fb43..7bd02a83e9361b 100644 --- a/var/spack/repos/builtin/packages/turbine/package.py +++ b/var/spack/repos/builtin/packages/turbine/package.py @@ -18,6 +18,9 @@ class Turbine(AutotoolsPackage): version("1.3.0", sha256="9709e5dada91a7dce958a7967d6ff2bd39ccc9e7da62d05a875324b5089da393") version("1.2.3", sha256="a3156c7e0b39e166da3de8892f55fa5d535b0c99c87a9add067c801098fe51ba") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("python", default=False, description="Enable calling python") variant("r", default=False, description="Enable calling R") variant("hdf5", default=False, description="Enable HDF5 support") diff --git a/var/spack/repos/builtin/packages/turnserver/package.py b/var/spack/repos/builtin/packages/turnserver/package.py index 2ff2fc4deeca05..8662815c59d562 100644 --- a/var/spack/repos/builtin/packages/turnserver/package.py +++ b/var/spack/repos/builtin/packages/turnserver/package.py @@ -16,4 +16,6 @@ class Turnserver(AutotoolsPackage): version("4.5.1.3", sha256="408bf7fde455d641bb2a23ba2df992ea0ae87b328de74e66e167ef58d8e9713a") + depends_on("c", type="build") # generated + depends_on("libevent") diff --git a/var/spack/repos/builtin/packages/twm/package.py b/var/spack/repos/builtin/packages/twm/package.py index b350728d02396e..6b5209da9b2fb5 100644 --- a/var/spack/repos/builtin/packages/twm/package.py +++ b/var/spack/repos/builtin/packages/twm/package.py @@ -22,6 +22,8 @@ class Twm(AutotoolsPackage, XorgPackage): version("1.0.10", sha256="679a1d07078c918fa32454498dc15573b299bbb0f001499e213c408e4b2170f5") version("1.0.9", sha256="1c325e8456a200693c816baa27ceca9c5e5e0f36af63d98f70a335853a0039e8") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/tycho2/package.py b/var/spack/repos/builtin/packages/tycho2/package.py index 16c73d0654a81d..50f99f750562fb 100644 --- a/var/spack/repos/builtin/packages/tycho2/package.py +++ b/var/spack/repos/builtin/packages/tycho2/package.py @@ -19,6 +19,8 @@ class Tycho2(MakefilePackage): version("develop", branch="master") + depends_on("cxx", type="build") # generated + depends_on("mpi") def patch(self): diff --git a/var/spack/repos/builtin/packages/typhon/package.py b/var/spack/repos/builtin/packages/typhon/package.py index 04f9f9300bca30..5470d6a2eb7132 100644 --- a/var/spack/repos/builtin/packages/typhon/package.py +++ b/var/spack/repos/builtin/packages/typhon/package.py @@ -24,6 +24,9 @@ class Typhon(CMakePackage): version("3.0.1", sha256="8d6e19192e52eadf92175423ae0efd8a1a343c2ea2bc48aacb9028074447c2bb") version("3.0", sha256="b9736269ebe9c0fd7efabc4716b0543144780ed26ddaf595083354113aa2efd7") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/typhonio/package.py b/var/spack/repos/builtin/packages/typhonio/package.py index 0833a30a06e91e..b0197f7d0b0d1a 100644 --- a/var/spack/repos/builtin/packages/typhonio/package.py +++ b/var/spack/repos/builtin/packages/typhonio/package.py @@ -19,6 +19,9 @@ class Typhonio(CMakePackage): version("develop", branch="cmake_build") version("1.6_CMake", sha256="c9b7b2a7f4fa0b786f6b69c6426b67f42efc4ea6871323139d52cd44f4d0ff7c") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "build_type", default="Release", diff --git a/var/spack/repos/builtin/packages/ucc/package.py b/var/spack/repos/builtin/packages/ucc/package.py index a77295aca5d39a..fa612b3722440b 100644 --- a/var/spack/repos/builtin/packages/ucc/package.py +++ b/var/spack/repos/builtin/packages/ucc/package.py @@ -15,8 +15,12 @@ class Ucc(AutotoolsPackage, CudaPackage): maintainers("zzzoom") + version("1.3.0", sha256="b56379abe5f1c125bfa83be305d78d81a64aa271b7b5fff0ac17b86725ff3acf") version("1.2.0", sha256="c1552797600835c0cf401b82dc89c4d27d5717f4fb805d41daca8e19f65e509d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("cuda", default=False, description="Enable CUDA TL") variant("nccl", default=False, description="Enable NCCL TL", when="+cuda") # RCCL build not tested diff --git a/var/spack/repos/builtin/packages/uchardet/package.py b/var/spack/repos/builtin/packages/uchardet/package.py index 0af81372d9cb83..3be62d1d0beaf3 100644 --- a/var/spack/repos/builtin/packages/uchardet/package.py +++ b/var/spack/repos/builtin/packages/uchardet/package.py @@ -19,6 +19,7 @@ class Uchardet(CMakePackage): license("MPL-1.1") version("master", branch="master") + version("0.0.8", sha256="8351328cdfbcb2432e63938721dd781eb8c11ebc56e3a89d0f84576b96002c61") version("0.0.7", sha256="8351328cdfbcb2432e63938721dd781eb8c11ebc56e3a89d0f84576b96002c61") version("0.0.6", sha256="8351328cdfbcb2432e63938721dd781eb8c11ebc56e3a89d0f84576b96002c61") version("0.0.5", sha256="7c5569c8ee1a129959347f5340655897e6a8f81ec3344de0012a243f868eabd1") @@ -26,6 +27,9 @@ class Uchardet(CMakePackage): version("0.0.3", sha256="8caba57524b6e306e764b4dabf5bfec48b6f9d89b73543ed7c95263890e2006f") version("0.0.2", sha256="eb59b5b36269212a0d5f44d654cdbeb02e4e43ff59e3ce0205d6a64670991e83") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def url_for_version(self, version): if version >= Version("0.0.6"): url = "https://www.freedesktop.org/software/uchardet/releases/uchardet-0.0.6.tar.xz" diff --git a/var/spack/repos/builtin/packages/ucsc-bedclip/package.py b/var/spack/repos/builtin/packages/ucsc-bedclip/package.py index 5173346a714c00..f9b34ee28f84f9 100644 --- a/var/spack/repos/builtin/packages/ucsc-bedclip/package.py +++ b/var/spack/repos/builtin/packages/ucsc-bedclip/package.py @@ -16,8 +16,11 @@ class UcscBedclip(Package): version("377", sha256="932f149c19641064a9cd3f2382cbb54b45a9292b8444792872d531346925d676") version("449", sha256="b5a86863d6cfe2120f6c796a13b1572ad05b22622f6534b95c9d26ccbede09b7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libpng") - depends_on("libuuid") + depends_on("uuid") depends_on("gmake") depends_on("mysql-connector-c") depends_on("openssl") diff --git a/var/spack/repos/builtin/packages/ucsc-bedgraphtobigwig/package.py b/var/spack/repos/builtin/packages/ucsc-bedgraphtobigwig/package.py index 14833362282c13..2d66fd771ca8cc 100644 --- a/var/spack/repos/builtin/packages/ucsc-bedgraphtobigwig/package.py +++ b/var/spack/repos/builtin/packages/ucsc-bedgraphtobigwig/package.py @@ -16,8 +16,11 @@ class UcscBedgraphtobigwig(Package): version("449", sha256="b5a86863d6cfe2120f6c796a13b1572ad05b22622f6534b95c9d26ccbede09b7") version("445", sha256="c7abb5db6a5e16a79aefcee849d2b59dbc71ee112ca1e41fea0afb25229cf56c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libpng") - depends_on("libuuid") + depends_on("uuid") depends_on("gmake") depends_on("openssl") depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/ucx/package.py b/var/spack/repos/builtin/packages/ucx/package.py index a50f11cba49f71..d3c40aaa74d82a 100644 --- a/var/spack/repos/builtin/packages/ucx/package.py +++ b/var/spack/repos/builtin/packages/ucx/package.py @@ -20,9 +20,11 @@ class Ucx(AutotoolsPackage, CudaPackage): license("BSD-3-Clause") # Current - version("1.15.0", sha256="4b202087076bc1c98f9249144f0c277a8ea88ad4ca6f404f94baa9cb3aebda6d") + version("1.17.0", sha256="34658e282f99f89ce7a991c542e9727552734ac6ad408c52f22b4c2653b04276") # Still supported + version("1.16.0", sha256="f73770d3b583c91aba5fb07557e655ead0786e057018bfe42f0ebe8716e9d28c") + version("1.15.0", sha256="4b202087076bc1c98f9249144f0c277a8ea88ad4ca6f404f94baa9cb3aebda6d") version("1.14.1", sha256="baa0634cafb269a3112f626eb226bcd2ca8c9fcf0fec3b8e2a3553baad5f77aa") version("1.14.0", sha256="9bd95e2059de5dece9dddd049aacfca3d21bfca025748a6a0b1be4486e28afdd") version("1.13.1", sha256="efc37829b68e131d2acc82a3fd4334bfd611156a756837ffeb650ab9a9dd3828") @@ -53,6 +55,9 @@ class Ucx(AutotoolsPackage, CudaPackage): version("1.2.1", sha256="fc63760601c03ff60a2531ec3c6637e98f5b743576eb410f245839c84a0ad617") version("1.2.0", sha256="1e1a62d6d0f89ce59e384b0b5b30b416b8fd8d7cedec4182a5319d0dfddf649c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + simd_values = ("avx", "sse41", "sse42") variant("assertions", default=False, description="Enable assertions") @@ -160,6 +165,9 @@ def patch(self): "-L$with_rocm/hip/lib -L$with_rocm/lib", "$ROCM_LDFLAGS", "configure", string=True ) + if self.spec.satisfies("@:1.15 ^hip@6:"): + filter_file("HIP_PLATFORM_HCC", "HIP_PLATFORM_AMD", "configure", string=True) + @when("@1.9-dev") def autoreconf(self, spec, prefix): Executable("./autogen.sh")() diff --git a/var/spack/repos/builtin/packages/udunits/package.py b/var/spack/repos/builtin/packages/udunits/package.py index e5f366a66bb645..559d5f11cb88f0 100644 --- a/var/spack/repos/builtin/packages/udunits/package.py +++ b/var/spack/repos/builtin/packages/udunits/package.py @@ -36,6 +36,8 @@ class Udunits(AutotoolsPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("expat") variant("shared", default=True, description="Build shared library") diff --git a/var/spack/repos/builtin/packages/ufo-core/package.py b/var/spack/repos/builtin/packages/ufo-core/package.py index 3154723acfe89b..703b7e8364af85 100644 --- a/var/spack/repos/builtin/packages/ufo-core/package.py +++ b/var/spack/repos/builtin/packages/ufo-core/package.py @@ -17,7 +17,10 @@ class UfoCore(CMakePackage): license("LGPL-3.0-only") + version("0.16.0", sha256="ff895386e10920ec399b9951a231e517bd6cf5f70c3b527430c2c1fccff6f181") version("0.14.0", sha256="3bf0d1924d6ae3f51673cc8b0b31b17873e79f1a0129a9af54b4062b1b2b3ad7") + depends_on("c", type="build") # generated + depends_on("glib") depends_on("json-glib") diff --git a/var/spack/repos/builtin/packages/ufo-filters/package.py b/var/spack/repos/builtin/packages/ufo-filters/package.py index de57eec948ca7b..18d951bd80794e 100644 --- a/var/spack/repos/builtin/packages/ufo-filters/package.py +++ b/var/spack/repos/builtin/packages/ufo-filters/package.py @@ -16,4 +16,7 @@ class UfoFilters(CMakePackage): version("0.14.1", sha256="084d7cdef59205e1a048e5c142be1ffeaacedc42965824b642e8302ef30ebb13") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("ufo-core") diff --git a/var/spack/repos/builtin/packages/ufs-utils/package.py b/var/spack/repos/builtin/packages/ufs-utils/package.py index 1333ef3f4c19f0..2af09c08b5a524 100644 --- a/var/spack/repos/builtin/packages/ufs-utils/package.py +++ b/var/spack/repos/builtin/packages/ufs-utils/package.py @@ -49,6 +49,9 @@ class UfsUtils(CMakePackage): submodules=True, ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("cmake@3.23:") depends_on("bacio") diff --git a/var/spack/repos/builtin/packages/ufs-weather-model/package.py b/var/spack/repos/builtin/packages/ufs-weather-model/package.py index ff30c425f0b3b3..cc0fa715a8a68c 100644 --- a/var/spack/repos/builtin/packages/ufs-weather-model/package.py +++ b/var/spack/repos/builtin/packages/ufs-weather-model/package.py @@ -17,8 +17,9 @@ class UfsWeatherModel(CMakePackage): url = "https://github.com/ufs-community/ufs-weather-model/archive/refs/tags/ufs-v1.1.0.tar.gz" git = "https://github.com/ufs-community/ufs-weather-model.git" - maintainers("t-brown") + maintainers("AlexanderRichert-NOAA") + version("develop", branch="develop", submodules=True) version( "2.0.0", tag="ufs-v2.0.0", @@ -32,12 +33,48 @@ class UfsWeatherModel(CMakePackage): submodules=True, ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + + variant("mpi", default=True, description="Enable MPI") variant( "32bit", default=True, description="Enable 32-bit single precision arithmetic in dycore" ) - variant("avx2", default=False, description="Enable AVX2 instructions") variant( - "ccpp", default=True, description="Enable the Common Community Physics Package (CCPP))" + "ccpp_32bit", + default=False, + description="Enable CCPP_32BIT (single precision arithmetic in slow physics)", + ) + variant("debug", default=False, description="Enable DEBUG mode", when="@develop") + variant( + "debug_linkmpi", + default=True, + description="Enable linkmpi option when DEBUG mode is on", + when="@develop", + ) + variant("inline_post", default=False, description="Enable inline post") + variant("multi_gases", default=False, description="Enable multi gases in physics routines") + variant("moving_nest", default=False, description="Enable moving nest code", when="@develop") + variant("openmp", default=True, description="Enable OpenMP") + variant("pdlib", default=False, description="Enable PDLIB (WW3)", when="@develop") + variant("parallel_netcdf", default=True, description="Enable parallel NetCDF") + variant( + "jedi_driver", + default=False, + description="Enable JEDI as top level driver", + when="@develop", + ) + variant( + "cmeps_aoflux", + default=False, + description="Enable atmosphere-ocean flux calculation in mediator", + when="@develop", + ) + variant( + "ccpp", + default=True, + description="Enable the Common Community Physics Package (CCPP)", + when="@:2.0.0", ) variant( "ccpp_suites", @@ -45,37 +82,96 @@ class UfsWeatherModel(CMakePackage): description="CCPP suites to compile", values=("FV3_GFS_v15p2", "FV3_RRFS_v1alpha", "FV3_GFS_v15p2,FV3_RRFS_v1alpha"), multi=True, + when="@:2.0.0", + ) + dev_ccpp_default = [ + "FV3_GFS_v16", + "FV3_GFS_v16_flake", + "FV3_GFS_v17_p8", + "FV3_GFS_v17_p8_rrtmgp", + "FV3_GFS_v15_thompson_mynn_lam3km", + "FV3_WoFS_v0", + "FV3_GFS_v17_p8_mynn", + "FV3_GFS_v17_p8_ugwpv1", + ] + variant( + "ccpp_suites", + default=",".join(dev_ccpp_default), + description="CCPP suites to compile", + multi=True, + when="@develop", ) - variant("inline_post", default=False, description="Compile post processing inline") - variant("multi_gases", default=False, description="Enable multi gases in physics routines") - variant("openmp", default=True, description="Enable OpenMP") - variant("parallel_netcdf", default=True, description="Enable parallel I/O in netCDF") variant( "quad_precision", default=False, description="Enable quad precision for certain grid metric terms in dycore", + when="@:2.0.0", ) - variant( - "simdmultiarch", default=False, description="Enable multi-target SIMD instruction sets" - ) + variant("mom6solo", default=False, description="Build MOM6 solo executable", when="@develop") + + variant("app", default="ATM", description="UFS application", when="@develop") depends_on("bacio") - depends_on("esmf@:8.0.0") - depends_on("mpi") - depends_on("nemsio") + depends_on("mpi", when="+mpi") depends_on("netcdf-c") depends_on("netcdf-fortran") depends_on("sp") depends_on("w3emc") - depends_on("w3nco") - depends_on("python", type="build") + depends_on("esmf@:8.0.0", when="@:2.0.0") + depends_on("nemsio", when="@:2.0.0") + depends_on("w3nco", when="@:2.0.0") + depends_on("bacio@2.4.0:", when="@develop") + depends_on("crtm", when="@develop") + depends_on("esmf@8.3.0:", when="@develop") + depends_on("fms@2022.04: +deprecated_io precision=32,64 constants=GFS", when="@develop") + depends_on("g2", when="@develop") + depends_on("g2tmpl", when="@develop") + depends_on("hdf5+hl+mpi", when="@develop") + depends_on("ip@:4", when="@develop") + depends_on("netcdf-c~parallel-netcdf+mpi", when="@develop") + for app in [ + "ATMW", + "ATML", + "NG-GODAS", + "S2S", + "S2SA", + "S2SW", + "S2SWA", + "S2SWAL", + "HAFS", + "HAFSW", + "HAFS-ALL", + "LND", + ]: + depends_on("parallelio@2.5.3: +fortran~pnetcdf~shared", when="@develop app=%s" % app) + depends_on("python@3.6:", type="build", when="@develop") + depends_on("sp@2.3.3:", when="@develop") + depends_on("w3emc@2.9.2:", when="@develop") + + with when("@develop app=S2SA"): + depends_on("mapl") + depends_on("gftl-shared") + with when("@develop app=S2SWA"): + depends_on("mapl") + depends_on("gftl-shared") + with when("@develop app=ATMAERO"): + depends_on("mapl") + depends_on("gftl-shared") + depends_on("scotch", when="+pdlib") + + depends_on("w3nco", when="@:2.0.0") + depends_on("python", type="build", when="@:2.0.0") + + conflicts("%gcc@:8", when="@develop") def setup_build_environment(self, env): spec = self.spec + env.set("CC", spec["mpi"].mpicc) + env.set("CXX", spec["mpi"].mpicxx) + env.set("FC", spec["mpi"].mpifc) env.set("CMAKE_C_COMPILER", spec["mpi"].mpicc) env.set("CMAKE_CXX_COMPILER", spec["mpi"].mpicxx) env.set("CMAKE_Fortran_COMPILER", spec["mpi"].mpifc) - env.set("ESMFMKFILE", join_path(spec["esmf"].prefix.lib, "esmf.mk")) env.set("CCPP_SUITES", ",".join([x for x in spec.variants["ccpp_suites"].value if x])) @@ -91,25 +187,50 @@ def setup_build_environment(self, env): raise InstallError(msg.format(spec.platform, self.compiler.name)) def cmake_args(self): - from_variant = self.define_from_variant args = [ - from_variant("32BIT", "32bit"), - from_variant("AVX2", "avx2"), - from_variant("CCPP", "ccpp"), - from_variant("INLINE_POST", "inline_post"), - from_variant("MULTI_GASES", "multi_gases"), - from_variant("OPENMP", "openmp"), - from_variant("PARALLEL_NETCDF", "parallel_netcdf"), - from_variant("QUAD_PRECISION", "quad_precision"), - from_variant("SIMDMULTIARCH", "simdmultiarch"), + self.define("AVX2", False), # use target settings from Spack + self.define("SIMDMULTIARCH", False), # use target settings from Spack + self.define_from_variant("CCPP_SUITES", "ccpp_suites").replace(";", ","), + ] + variants = [ + "32bit", + "app", + "ccpp_32bit", + "cmeps_aoflux", + "debug", + "debug_linkmpi", + "inline_post", + "jedi_driver", + "moving_nest", + "mpi", + "multi_gases", + "openmp", + "parallel_netcdf", + "pdlib", ] + for variant in variants: + args.append(self.define_from_variant(variant.upper(), variant)) + + if self.spec.satisfies("@:2.0.0"): + args.append(self.define_from_variant("CCPP", "ccpp")) + args.append(self.define_from_variant("QUAD_PRECISION", "quad_precision")) return args + # This patch can be removed once https://github.com/NOAA-EMC/WW3/issues/1021 + # is resolved. + @when("+pdlib ^scotch+shared") + def patch(self): + filter_file(r"(lib[^ ]+)\.a", r"\1.so", "WW3/cmake/FindSCOTCH.cmake") + filter_file("STATIC", "SHARED", "WW3/cmake/FindSCOTCH.cmake") + @run_after("install") def install_additional_files(self): mkdirp(prefix.bin) - ufs_src = join_path(self.build_directory, "NEMS.exe") + if self.spec.satisfies("@develop"): + ufs_src = join_path(self.build_directory, "ufs_model") + else: + ufs_src = join_path(self.build_directory, "NEMS.exe") ufs_dst = join_path(prefix.bin, "ufs_weather_model") install(ufs_src, ufs_dst) set_executable(ufs_dst) diff --git a/var/spack/repos/builtin/packages/uftrace/package.py b/var/spack/repos/builtin/packages/uftrace/package.py index ef411830d17c3b..bf478b5455f3b6 100644 --- a/var/spack/repos/builtin/packages/uftrace/package.py +++ b/var/spack/repos/builtin/packages/uftrace/package.py @@ -13,7 +13,7 @@ class Uftrace(AutotoolsPackage): """Dynamic function graph tracer for Linux which demangles C, C++ and Rust calls""" homepage = "https://uftrace.github.io/slide/" - url = "https://github.com/namhyung/uftrace/archive/v0.11.tar.gz" + url = "https://github.com/namhyung/uftrace/archive/v0.16.tar.gz" git = "https://github.com/namhyung/uftrace.git" executables = ["^uftrace$"] maintainers("bernhardkaindl") @@ -23,8 +23,10 @@ class Uftrace(AutotoolsPackage): # The build process uses 'git describe --tags' to get the package version version("master", branch="master", get_full_repo=True) - version("0.11", sha256="101dbb13cb3320ee76525ec26426f2aa1de4e3ee5af74f79cb403ae4d2c6c871") - version("0.10", sha256="b8b56d540ea95c3eafe56440d6a998e0a140d53ca2584916b6ca82702795bbd9") + version("0.16", sha256="dd0549f610d186b6f25fa2334a5e82b6ddc232ec6ca088dbb41b3fe66961d6bb") + + depends_on("c", type="build") + depends_on("cxx", type="build") # full demangler support with libstdc++ variant("doc", default=False, description="Build uftrace's documentation") variant("python2", default=False, description="Build uftrace with python2 support") variant("python3", default=True, description="Build uftrace with python3 support") @@ -35,16 +37,12 @@ class Uftrace(AutotoolsPackage): depends_on("lsof", type="test") depends_on("pkgconfig", type="build") depends_on("libunwind") + depends_on("libtraceevent") depends_on("ncurses") depends_on("python@2.7:", when="+python2") depends_on("python@3.5:", when="+python3") depends_on("lua-luajit") - # Fix the version string if building below another git repo. Submitted upstream: - @when("@:0.11") - def patch(self): - filter_file("shell git", "shell test -e .git && git", "Makefile") - def check(self): make("test", *["V=1", "-j{0}".format(max(int(make_jobs), 20))]) # In certain cases, tests using TCP/IP can hang. Ensure that spack can continue: @@ -56,26 +54,23 @@ def install(self, spec, prefix): def installcheck(self): pass - def test(self): + def test_uftrace(self): """Perform stand-alone/smoke tests using the installed package.""" - uftrace = self.prefix.bin.uftrace - self.run_test( - uftrace, - ["-A", ".", "-R", ".", "-P", "main", uftrace, "-V"], - [ - r"dwarf", - r"luajit", - r"tui", - r"sched", - r"dynamic", - r"main\(2, ", - r" getopt_long\(2, ", - r" .*printf.*\(", - r"} = 0; /\* main \*/", - ], - installed=True, - purpose="test: testing the installation", - ) + uftrace = which(self.prefix.bin.uftrace) + options = (["-A", ".", "-R", ".", "-P", "main", uftrace, "-V"],) + expected = [ + r"dwarf", + r"luajit", + r"tui", + r"sched", + r"dynamic", + r"main\(2, ", + r" getopt_long\(2, ", + r" .*printf.*\(", + r"} = 0; /\* main \*/", + ] + out = uftrace(*options, output=str.split, error=str.split) + check_outputs(expected, out) @classmethod def determine_version(cls, exe): diff --git a/var/spack/repos/builtin/packages/umap/package.py b/var/spack/repos/builtin/packages/umap/package.py index 57cbcb3202db0c..9f45d9c8a9ed7a 100644 --- a/var/spack/repos/builtin/packages/umap/package.py +++ b/var/spack/repos/builtin/packages/umap/package.py @@ -20,6 +20,7 @@ class Umap(CMakePackage): license("LGPL-2.1-or-later") version("develop", branch="develop") + version("2.1.1", sha256="6257e1ffd667a7d14e2061671328ccf7ecda27bc98fafb10f45502f967b1a115") version("2.1.0", sha256="dfdc5b717aecdbfbb0da22e8567b9f2ffbc3607000a31122bf7c5ab3b85cecd9") version("2.0.0", sha256="85c4bc68e8790393847a84eb54eaf6fc321acade382a399a2679d541b0e34150") version("1.0.0", sha256="c746de3fae5bfc5bbf36234d5e888ea45eeba374c26cd8b5a817d0c08e454ed5") @@ -28,6 +29,9 @@ class Umap(CMakePackage): version("0.0.2", sha256="eccc987b414bc568bd33b569ab6e18c328409499f11e65ac5cd5c3e1a8b47509") version("0.0.1", sha256="49020adf55aa3f8f03757373b21ff229d2e8cf4155d54835019cd4745c1291ef") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("logging", default=False, description="Build with logging enabled.") variant("tests", default=False, description="Build test programs.") diff --git a/var/spack/repos/builtin/packages/umesimd/package.py b/var/spack/repos/builtin/packages/umesimd/package.py index 3a9286864b3e7c..5d2d329d732e37 100644 --- a/var/spack/repos/builtin/packages/umesimd/package.py +++ b/var/spack/repos/builtin/packages/umesimd/package.py @@ -23,3 +23,5 @@ class Umesimd(CMakePackage): version("0.4.1", sha256="e05b9f886164826005c8db5d2240f22cb88593c05b4fe45c81aba4d1d57a9bfa") version("0.3.2", sha256="90399fa64489ca4d492a57a49582f5b827d4710a691f533822fd61edc346e8f6") version("0.3.1", sha256="9bab8b4c70e11dbdd864a09053225c74cfabb801739e09a314ddeb1d84a43f0a") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/umoci/package.py b/var/spack/repos/builtin/packages/umoci/package.py index 562dfbf53d2a04..544c7dbefef9a8 100644 --- a/var/spack/repos/builtin/packages/umoci/package.py +++ b/var/spack/repos/builtin/packages/umoci/package.py @@ -22,6 +22,8 @@ class Umoci(MakefilePackage): version("0.4.1", sha256="0d83e01167383f529d726e9fd455660d4837371d5f0d82fad405f3ae6ae52486") version("0.4.0", sha256="66997e270dee8abc9796385b162a1e8e32dd2ee2359e5200af4e6671cc1e76a0") + depends_on("c", type="build") # generated + depends_on("go") depends_on("go-md2man", type="build") diff --git a/var/spack/repos/builtin/packages/umpire/dual_blt_import_umpire_2022.10_2023.06.patch b/var/spack/repos/builtin/packages/umpire/dual_blt_import_umpire_2022.10_2023.06.patch new file mode 100644 index 00000000000000..c8edc8012dfcfe --- /dev/null +++ b/var/spack/repos/builtin/packages/umpire/dual_blt_import_umpire_2022.10_2023.06.patch @@ -0,0 +1,106 @@ +diff --git a/cmake/SetupUmpireThirdParty.cmake b/cmake/SetupUmpireThirdParty.cmake +index fc351369..6e82ab6e 100644 +--- a/cmake/SetupUmpireThirdParty.cmake ++++ b/cmake/SetupUmpireThirdParty.cmake +@@ -80,29 +80,40 @@ if (UMPIRE_ENABLE_SQLITE_EXPERIMENTAL) + find_package(SQLite3 REQUIRED) + endif() + +-set(UMPIRE_NEEDS_BLT_TPLS False) +-if (UMPIRE_ENABLE_MPI OR UMPIRE_ENABLE_HIP OR UMPIRE_ENABLE_OPENMP OR UMPIRE_ENABLE_CUDA) +- set(UMPIRE_NEEDS_BLT_TPLS True) +- +- if (NOT BLT_EXPORTED) +- set(BLT_EXPORTED On CACHE BOOL "" FORCE) +- blt_import_library(NAME blt_stub EXPORTABLE On) +- set_target_properties(blt_stub PROPERTIES EXPORT_NAME blt::blt_stub) +- install(TARGETS blt_stub +- EXPORT bltTargets) +- blt_export_tpl_targets(EXPORT bltTargets NAMESPACE blt) +- install(EXPORT bltTargets +- DESTINATION lib/cmake/umpire) +- elseif (UMPIRE_ENABLE_MPI) ++ ++################################################# ++# use bonafide cmake targets for openmp and mpi ++################################################# ++set(umpire_mpi_deps "") ++if (UMPIRE_ENABLE_MPI) ++ if(ENABLE_FIND_MPI) ++ set (umpire_mpi_deps MPI::MPI_CXX) ++ endif() ++endif() ++ ++set(umpire_openmp_deps "") ++if (UMPIRE_ENABLE_OPENMP) ++ set (umpire_openmp_deps OpenMP::OpenMP_CXX) ++endif () ++ ++################################################# ++# export necessary blt targets ++################################################# ++ ++set(UMPIRE_BLT_TPL_DEPS_EXPORTS) ++ ++blt_list_append(TO UMPIRE_BLT_TPL_DEPS_EXPORTS ELEMENTS cuda cuda_runtime IF UMPIRE_ENABLE_CUDA) ++blt_list_append(TO UMPIRE_BLT_TPL_DEPS_EXPORTS ELEMENTS blt_hip blt_hip_runtime IF UMPIRE_ENABLE_HIP) ++ ++foreach(dep ${UMPIRE_BLT_TPL_DEPS_EXPORTS}) + # If the target is EXPORTABLE, add it to the export set +- get_target_property(_is_imported mpi IMPORTED) ++ get_target_property(_is_imported ${dep} IMPORTED) + if(NOT ${_is_imported}) +- install(TARGETS mpi +- EXPORT ${arg_EXPORT}) +- # Namespace target to avoid conflicts +- set_target_properties(mpi PROPERTIES EXPORT_NAME blt::mpi) +- install(EXPORT bltTargets +- DESTINATION lib/cmake/umpire) ++ install(TARGETS ${dep} ++ EXPORT umpire-targets ++ DESTINATION lib/cmake/umpire) ++ # Namespace target to avoid conflicts ++ set_target_properties(${dep} PROPERTIES EXPORT_NAME umpire::blt_tpl_exports_${dep}) + endif() +- endif() +-endif() ++endforeach() ++ +diff --git a/src/umpire/interface/c_fortran/CMakeLists.txt b/src/umpire/interface/c_fortran/CMakeLists.txt +index ab675adf..22e4dc90 100644 +--- a/src/umpire/interface/c_fortran/CMakeLists.txt ++++ b/src/umpire/interface/c_fortran/CMakeLists.txt +@@ -43,7 +43,7 @@ set_source_files_properties( + set(umpire_interface_c_fortran_depends camp umpire_util) + blt_list_append( TO umpire_interface_c_fortran_depends ELEMENTS cuda_runtime IF UMPIRE_ENABLE_CUDA ) +-blt_list_append( TO umpire_interface_c_fortran_depends ELEMENTS blt::hip_runtime IF UMPIRE_ENABLE_HIP ) +-blt_list_append( TO umpire_interface_c_fortran_depends ELEMENTS mpi IF UMPIRE_ENABLE_MPI ) ++blt_list_append( TO umpire_interface_c_fortran_depends ELEMENTS blt_hip_runtime IF UMPIRE_ENABLE_HIP ) ++blt_list_append( TO umpire_interface_c_fortran_depends ELEMENTS ${umpire_mpi_deps} IF UMPIRE_ENABLE_MPI ) + + blt_add_library( + NAME umpire_interface +diff --git a/src/umpire/util/CMakeLists.txt b/src/umpire/util/CMakeLists.txt +index 551f8188..02eb13e4 100644 +--- a/src/umpire/util/CMakeLists.txt ++++ b/src/umpire/util/CMakeLists.txt +@@ -73,14 +73,15 @@ endif() + + if (UMPIRE_ENABLE_MPI) + set (umpire_util_depends +- ${umpire_util_depends} +- mpi) ++ ${umpire_util_depends} ++ ${umpire_mpi_deps} ++ ) + endif () + + if (UMPIRE_ENABLE_OPENMP_TARGET) + set (umpire_util_depends +- ${umpire_util_depends} +- openmp) ++ ${umpire_util_depends} ++ ${umpire_openmp_deps}) + endif () + + if (UMPIRE_ENABLE_HIP) diff --git a/var/spack/repos/builtin/packages/umpire/export_includes.patch b/var/spack/repos/builtin/packages/umpire/export_includes.patch new file mode 100644 index 00000000000000..c5a56518ff502f --- /dev/null +++ b/var/spack/repos/builtin/packages/umpire/export_includes.patch @@ -0,0 +1,130 @@ +diff --git a/src/tpl/CMakeLists.txt b/src/tpl/CMakeLists.txt +index 6803f0a4..60269f88 100644 +--- a/src/tpl/CMakeLists.txt ++++ b/src/tpl/CMakeLists.txt +@@ -50,7 +50,13 @@ target_include_directories( + umpire_tpl_json + INTERFACE + $ +- $ ++ $) ++ ++blt_convert_to_system_includes(TARGET umpire_tpl_json) ++ ++target_include_directories( ++ umpire_tpl_json ++ INTERFACE + $) + + install(FILES +@@ -64,8 +70,6 @@ install(TARGETS + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib) + +-blt_patch_target(NAME umpire_tpl_json +- TREAT_INCLUDES_AS_SYSTEM ON) + + # + # CLI11 Option Parsing Headers +@@ -82,7 +86,13 @@ target_include_directories( + umpire_tpl_CLI11 + INTERFACE + $ +- $ ++ $) ++ ++blt_convert_to_system_includes(TARGET umpire_tpl_CLI11) ++ ++target_include_directories( ++ umpire_tpl_CLI11 ++ INTERFACE + $) + + install(FILES +@@ -96,9 +106,6 @@ install(TARGETS + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib) + +-blt_patch_target(NAME umpire_tpl_CLI11 +- TREAT_INCLUDES_AS_SYSTEM ON) +- + add_subdirectory(umpire/judy) + + if (NOT TARGET camp) +@@ -153,7 +160,14 @@ target_include_directories( + umpire_tpl_fmt + INTERFACE + $ +- $ ++ $) ++ ++# Avoid warnings from fmt (so we can still use -Werror) ++blt_convert_to_system_includes(TARGET umpire_tpl_fmt) ++ ++target_include_directories( ++ umpire_tpl_fmt ++ INTERFACE + $) + + if (C_COMPILER_FAMILY_IS_XL) +@@ -168,21 +182,17 @@ if (C_COMPILER_FAMILY_IS_PGI) + set(_fmt_warning_disable_flag + "--diag_suppress 1625;--diag_suppress 185;--diag_suppress 811;--diag_suppress 186") + +- if (ENABLE_FORTRAN) ++ if (ENABLE_FORTRAN) + target_compile_options(umpire_tpl_fmt + INTERFACE + $<$>:${_fmt_warning_disable_flag}>) +- else () +- target_compile_options(umpire_tpl_fmt +- INTERFACE +- ${_fmt_warning_disable_flag}) +- endif () ++ else () ++ target_compile_options(umpire_tpl_fmt ++ INTERFACE ++ ${_fmt_warning_disable_flag}) ++ endif () + endif () + +-# Avoid warnings from fmt (so we can still use -Werror) +-blt_patch_target(NAME umpire_tpl_fmt +- TREAT_INCLUDES_AS_SYSTEM ON) +- + if (C_COMPILER_FAMILY_IS_GNU) + target_compile_options(umpire_tpl_fmt + INTERFACE +diff --git a/src/umpire/interface/c_fortran/CMakeLists.txt b/src/umpire/interface/c_fortran/CMakeLists.txt +index cf0d6932..ab675adf 100644 +--- a/src/umpire/interface/c_fortran/CMakeLists.txt ++++ b/src/umpire/interface/c_fortran/CMakeLists.txt +@@ -57,15 +57,22 @@ target_include_directories( + PUBLIC + $ + $ +- $:${CMAKE_Fortran_MODULE_DIRECTORY}>> +- $:include/umpire>> # for Fortran module files + $) + + install(FILES + ${umpire_interface_c_fortran_headers} + DESTINATION include/umpire/interface/c_fortran) + +-install(DIRECTORY +- ${CMAKE_Fortran_MODULE_DIRECTORY}/ +- DESTINATION include/umpire +- FILES_MATCHING PATTERN "*.mod") ++if(UMPIRE_ENABLE_FORTRAN) ++ target_include_directories( ++ umpire_interface ++ PUBLIC ++ $ ++ $) ++ ++ install(DIRECTORY ++ ${CMAKE_Fortran_MODULE_DIRECTORY}/ ++ DESTINATION include/umpire ++ FILES_MATCHING PATTERN "*.mod") ++endif() ++ diff --git a/var/spack/repos/builtin/packages/umpire/package.py b/var/spack/repos/builtin/packages/umpire/package.py index 48ee22cf91c113..75d638dddc9b14 100644 --- a/var/spack/repos/builtin/packages/umpire/package.py +++ b/var/spack/repos/builtin/packages/umpire/package.py @@ -9,7 +9,8 @@ import llnl.util.tty as tty from spack.package import * -from spack.pkg.builtin.camp import hip_repair_cache + +from .blt import llnl_link_helpers class Umpire(CachedCMakePackage, CudaPackage, ROCmPackage): @@ -20,12 +21,29 @@ class Umpire(CachedCMakePackage, CudaPackage, ROCmPackage): git = "https://github.com/LLNL/Umpire.git" tags = ["radiuss", "e4s"] - maintainers("davidbeckingsale") + maintainers("davidbeckingsale", "adrienbernede") license("MIT") version("develop", branch="develop", submodules=False) - version("main", branch="main", submodules=False) + version( + "2024.02.1", + tag="v2024.02.1", + commit="3058d562fc707650e904f9321b1ee9bcebad3ae2", + submodules=False, + ) + version( + "2024.02.0", + tag="v2024.02.0", + commit="1db3fef913a70d8882ca510a4830c77c388873e0", + submodules=False, + ) + version( + "2023.06.0", + tag="v2023.06.0", + commit="1e5ef604de88e81bb3b6fc4a5d914be833529da5", + submodules=False, + ) version( "2022.10.0", tag="v2022.10.0", @@ -126,6 +144,15 @@ class Umpire(CachedCMakePackage, CudaPackage, ROCmPackage): "0.1.3", tag="v0.1.3", commit="cc347edeb17f5f30f694aa47f395d17369a2e449", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + + # Some projects importing both camp and umpire targets end up with conflicts in BLT targets + # import. This is not addressing the root cause, which will be addressed in BLT@5.4.0 and will + # require adapting umpire build system. + patch("dual_blt_import_umpire_2022.10_2023.06.patch", when="@2022.10.0:2023.06.0") + patch("export_includes.patch", when="@2022.10.0") patch("std-filesystem-pr784.patch", when="@2022.03.1 +rocm ^blt@0.5.2:") patch("camp_target_umpire_3.0.0.patch", when="@3.0.0") patch("cmake_version_check.patch", when="@4.1") @@ -140,15 +167,15 @@ class Umpire(CachedCMakePackage, CudaPackage, ROCmPackage): # https://github.com/LLNL/Umpire/pull/805 patch( - "https://github.com/LLNL/Umpire/pull/805/commits/47ff0aa1f7a01a917c3b7ac618e8a9e44a10fd25.patch?full_index=1", - sha256="7ed5d2c315a3b31e339f664f6108e32d7cb4cb8e9f22e5c78a65ba02625ccc09", + "https://github.com/LLNL/Umpire/commit/47ff0aa1f7a01a917c3b7ac618e8a9e44a10fd25.patch?full_index=1", + sha256="802f074a05e1cb1f428e13d99c5fcb1435f86bd8f36a1ea2f7b6756e6625e0a0", when="@2022.10.0", ) # https://github.com/LLNL/Umpire/pull/816 patch( - "https://github.com/LLNL/Umpire/pull/816/commits/2292d1d6078f6d9523b7ad0886ffa053644569d5.patch?full_index=1", - sha256="0f43cad7cdaec3c225ab6414ab9f81bd405a1157abf5a508e515bcb6ca53326d", + "https://github.com/LLNL/Umpire/commit/2292d1d6078f6d9523b7ad0886ffa053644569d5.patch?full_index=1", + sha256="170dbcadb9ae36c7e211119c17a812695f11f4fe1be290b750f7af4fb4896192", when="@2022.10.0", ) @@ -161,11 +188,19 @@ class Umpire(CachedCMakePackage, CudaPackage, ROCmPackage): variant("fortran", default=False, description="Build C/Fortran API") variant("c", default=True, description="Build C API") + variant("mpi", default=False, description="Enable MPI support") + variant("ipc_shmem", default=False, description="Enable POSIX shared memory") + variant( + "sqlite_experimental", + default=False, + description="Enable sqlite integration with umpire events (Experimental)", + ) variant("numa", default=False, description="Enable NUMA support") variant("shared", default=True, description="Enable Shared libs") variant("openmp", default=False, description="Build with OpenMP support") + variant("openmp_target", default=False, description="Build with OpenMP 4.5 support") variant("deviceconst", default=False, description="Enables support for constant device memory") - variant("examples", default=True, description="Build Umpire Examples") + variant("examples", default=False, description="Build Umpire Examples") variant( "tests", default="none", @@ -173,29 +208,48 @@ class Umpire(CachedCMakePackage, CudaPackage, ROCmPackage): multi=False, description="Tests to run", ) - variant("device_alloc", default=True, description="Build Umpire Device Allocator") - - depends_on("cmake@3.8:", type="build") - depends_on("cmake@3.9:", when="+cuda", type="build") + variant("tools", default=False, description="Enable tools") + variant("backtrace", default=False, description="Enable backtrace tools") + variant("dev_benchmarks", default=False, description="Enable developer benchmarks") + variant("device_alloc", default=False, description="Enable DeviceAllocator") + variant("werror", default=False, description="Enable warnings as errors") + variant("asan", default=False, description="Enable ASAN") + variant("sanitizer_tests", default=False, description="Enable address sanitizer tests") + + depends_on("cmake@3.23:", when="@2022.10.0: +rocm", type="build") + depends_on("cmake@3.20:", when="@2022.10.0:", type="build") + depends_on("cmake@:3.20", when="@2022.03.0:2022.03 +rocm", type="build") depends_on("cmake@3.14:", when="@2022.03.0:", type="build") + depends_on("cmake@3.9:", when="+cuda", type="build") + depends_on("cmake@3.8:", type="build") depends_on("blt", type="build") + depends_on("blt@0.6.1:", type="build", when="@2024.02.0:") + depends_on("blt@0.5.3", type="build", when="@2023.06.0") depends_on("blt@0.5.2:0.5.3", type="build", when="@2022.10.0") depends_on("blt@0.5.0:0.5.3", type="build", when="@2022.03.0:2022.03.1") depends_on("blt@0.4.1", type="build", when="@6.0.0") - depends_on("blt@0.4.0:", type="build", when="@4.1.3:5.0.1") - depends_on("blt@0.3.6:", type="build", when="@:4.1.2") + depends_on("blt@0.4.0:0.4.1", type="build", when="@4.1.3:5.0.1") + depends_on("blt@0.3.6:0.4.1", type="build", when="@:4.1.2") conflicts("^blt@:0.3.6", when="+rocm") - depends_on("camp", when="@5.0.0:") - depends_on("camp@0.2.2:0.2.3", when="@6.0.0") - depends_on("camp@0.1.0", when="@5.0.0:5.0.1") - depends_on("camp@2022.03.2:", when="@2022.03.0:") - depends_on("camp@main", when="@main") - depends_on("camp@main", when="@develop") + depends_on("camp") depends_on("camp+openmp", when="+openmp") depends_on("camp~cuda", when="~cuda") - depends_on("camp~rocm", when="~rocm") + depends_on("camp@main", when="@develop") + depends_on("camp@2024.02.0:", when="@2024.02.0:") + depends_on("camp@2023.06.0", when="@2023.06.0") + depends_on("camp@2022.10.0:2023.06.0", when="@2022.10.0") + depends_on("camp@2022.03.2:2023.06.0", when="@2022.03.0:2022.03.1") + depends_on("camp@0.2.2:0.2.3", when="@6.0.0") + depends_on("camp@0.1.0", when="@5.0.0:5.0.1") + + depends_on("sqlite", when="+sqlite_experimental") + depends_on("mpi", when="+mpi") + + depends_on("fmt@9.1:", when="@2024.02.0:") + # For some reason, we need c++ 17 explicitly only with intel + depends_on("fmt@9.1: cxxstd=17", when="@2024.02.0: %intel@19.1") with when("@5.0.0:"): with when("+cuda"): @@ -213,7 +267,26 @@ class Umpire(CachedCMakePackage, CudaPackage, ROCmPackage): conflicts("+numa", when="@:0.3.2") conflicts("~c", when="+fortran", msg="Fortran API requires C API") + + # device allocator must be used with more current umpire versions, rocm 5.4.0 and greater, + # and with either rocm or cuda enabled conflicts("+device_alloc", when="@:2022.03.0") + conflicts("+device_alloc", when="^hip@:5.3.99") + conflicts("+device_alloc", when="~rocm~cuda") + + conflicts("+deviceconst", when="~rocm~cuda") + conflicts("~openmp", when="+openmp_target", msg="OpenMP target requires OpenMP") + conflicts("+cuda", when="+rocm") + conflicts("+tools", when="+rocm") + conflicts( + "+rocm", + when="+openmp_target", + msg="Cant support both rocm and openmp device backends at once", + ) + conflicts("+ipc_shmem", when="@:5.0.1") + + conflicts("+sqlite_experimental", when="@:6.0.0") + conflicts("+sanitizer_tests", when="~asan") # device allocator exports device code, which requires static libs # currently only available for cuda. @@ -230,15 +303,18 @@ def cache_name(self): hostname = socket.gethostname() if "SYS_TYPE" in env: hostname = hostname.rstrip("1234567890") - return "{0}-{1}-{2}@{3}.cmake".format( + return "{0}-{1}-{2}@{3}-{4}.cmake".format( hostname, self._get_sys_type(self.spec), self.spec.compiler.name, self.spec.compiler.version, + self.spec.dag_hash(8), ) def initconfig_compiler_entries(self): spec = self.spec + compiler = self.compiler + # Default entries are already defined in CachedCMakePackage, inherit them: entries = super().initconfig_compiler_entries() if "+rocm" in spec: @@ -246,57 +322,62 @@ def initconfig_compiler_entries(self): option_prefix = "UMPIRE_" if spec.satisfies("@2022.03.0:") else "" - if "+fortran" in spec and self.compiler.fc is not None: + if "+fortran" in spec and compiler.fc is not None: entries.append(cmake_cache_option("ENABLE_FORTRAN", True)) else: entries.append(cmake_cache_option("ENABLE_FORTRAN", False)) entries.append(cmake_cache_option("{}ENABLE_C".format(option_prefix), "+c" in spec)) + llnl_link_helpers(entries, spec, compiler) + return entries def initconfig_hardware_entries(self): spec = self.spec entries = super().initconfig_hardware_entries() + entries.append("#------------------{0}".format("-" * 30)) + entries.append("# Package custom hardware settings") + entries.append("#------------------{0}\n".format("-" * 30)) + option_prefix = "UMPIRE_" if spec.satisfies("@2022.03.0:") else "" if "+cuda" in spec: entries.append(cmake_cache_option("ENABLE_CUDA", True)) - - if not spec.satisfies("cuda_arch=none"): - cuda_arch = spec.variants["cuda_arch"].value - entries.append(cmake_cache_string("CUDA_ARCH", "sm_{0}".format(cuda_arch[0]))) - entries.append( - cmake_cache_string("CMAKE_CUDA_ARCHITECTURES", "{0}".format(cuda_arch[0])) - ) - flag = "-arch sm_{0}".format(cuda_arch[0]) - entries.append(cmake_cache_string("CMAKE_CUDA_FLAGS", "{0}".format(flag))) - - entries.append( - cmake_cache_option( - "{}ENABLE_DEVICE_CONST".format(option_prefix), spec.satisfies("+deviceconst") - ) - ) + # Umpire used to pick only the first architecture in the list. The shared logic in + # CachedCMakePackage keeps the list of architectures. else: entries.append(cmake_cache_option("ENABLE_CUDA", False)) if "+rocm" in spec: entries.append(cmake_cache_option("ENABLE_HIP", True)) - entries.append(cmake_cache_path("HIP_ROOT_DIR", "{0}".format(spec["hip"].prefix))) - hip_repair_cache(entries, spec) - archs = self.spec.variants["amdgpu_target"].value - if archs != "none": - arch_str = ",".join(archs) - entries.append( - cmake_cache_string("HIP_HIPCC_FLAGS", "--amdgpu-target={0}".format(arch_str)) - ) - entries.append( - cmake_cache_string("CMAKE_HIP_ARCHITECTURES", "{0}".format(arch_str)) - ) else: entries.append(cmake_cache_option("ENABLE_HIP", False)) + entries.append( + cmake_cache_option( + "{}ENABLE_DEVICE_CONST".format(option_prefix), "+deviceconst" in spec + ) + ) + + entries.append( + cmake_cache_option( + "{}ENABLE_OPENMP_TARGET".format(option_prefix), "+openmp_target" in spec + ) + ) + + if "+openmp_target" in spec and "%xl" in spec: + entries.append(cmake_cache_string("OpenMP_CXX_FLAGS", "-qsmp;-qoffload")) + + return entries + + def initconfig_mpi_entries(self): + spec = self.spec + + entries = super(Umpire, self).initconfig_mpi_entries() + entries.append(cmake_cache_option("ENABLE_MPI", "+mpi" in spec)) + return entries def initconfig_package_entries(self): @@ -313,24 +394,73 @@ def initconfig_package_entries(self): entries.append(cmake_cache_path("BLT_SOURCE_DIR", spec["blt"].prefix)) if spec.satisfies("@5.0.0:"): entries.append(cmake_cache_path("camp_DIR", spec["camp"].prefix)) - entries.append(cmake_cache_option("{}ENABLE_NUMA".format(option_prefix), "+numa" in spec)) + + if spec.satisfies("@2024.02.0:"): + entries.append(cmake_cache_path("fmt_DIR", spec["fmt"].prefix)) + + # Build options + entries.append("#------------------{0}".format("-" * 60)) + entries.append("# Build Options") + entries.append("#------------------{0}\n".format("-" * 60)) + + entries.append(cmake_cache_string("CMAKE_BUILD_TYPE", spec.variants["build_type"].value)) + entries.append(cmake_cache_option("BUILD_SHARED_LIBS", "+shared" in spec)) + entries.append(cmake_cache_option("ENABLE_WARNINGS_AS_ERRORS", "+werror" in spec)) + + # Generic options that have a prefixed equivalent in Umpire CMake entries.append(cmake_cache_option("ENABLE_OPENMP", "+openmp" in spec)) - entries.append(cmake_cache_option("ENABLE_BENCHMARKS", "tests=benchmarks" in spec)) + entries.append(cmake_cache_option("ENABLE_EXAMPLES", "+examples" in spec)) + entries.append(cmake_cache_option("ENABLE_DOCS", False)) + if "tests=benchmarks" in spec or "+dev_benchmarks" in spec: + # BLT requires ENABLE_TESTS=True to enable benchmarks + entries.append(cmake_cache_option("ENABLE_BENCHMARKS", True)) + entries.append(cmake_cache_option("ENABLE_TESTS", True)) + else: + entries.append(cmake_cache_option("ENABLE_BENCHMARKS", False)) + entries.append(cmake_cache_option("ENABLE_TESTS", "tests=none" not in spec)) + + # Prefixed options that used to be name without one + entries.append(cmake_cache_option("{}ENABLE_NUMA".format(option_prefix), "+numa" in spec)) + entries.append( + cmake_cache_option( + "{}ENABLE_DEVELOPER_BENCHMARKS".format(option_prefix), "+dev_benchmarks" in spec + ) + ) + entries.append( + cmake_cache_option("{}ENABLE_TOOLS".format(option_prefix), "+tools" in spec) + ) + entries.append( + cmake_cache_option("{}ENABLE_BACKTRACE".format(option_prefix), "+backtrace" in spec) + ) + entries.append(cmake_cache_option("{}ENABLE_ASAN".format(option_prefix), "+asan" in spec)) entries.append( - cmake_cache_option("{}ENABLE_EXAMPLES".format(option_prefix), "+examples" in spec) + cmake_cache_option( + "{}ENABLE_SANITIZER_TESTS".format(option_prefix), "+sanitizer_tests" in spec + ) ) - entries.append(cmake_cache_option("{}ENABLE_DOCS".format(option_prefix), False)) + + # Recent options, were never name without prefix entries.append( cmake_cache_option("UMPIRE_ENABLE_DEVICE_ALLOCATOR", "+device_alloc" in spec) ) - entries.append(cmake_cache_option("BUILD_SHARED_LIBS", "+shared" in spec)) - entries.append(cmake_cache_option("ENABLE_TESTS", "tests=none" not in spec)) + entries.append( + cmake_cache_option("UMPIRE_ENABLE_SQLITE_EXPERIMENTAL", "+sqlite_experimental" in spec) + ) + if "+sqlite_experimental" in spec: + entries.append(cmake_cache_path("SQLite3_ROOT", spec["sqlite"].prefix)) + + # This option was renamed later than the others + if spec.satisfies("@2022.10.0:"): + entries.append( + cmake_cache_option("UMPIRE_ENABLE_IPC_SHARED_MEMORY", "+ipc_shmem" in spec) + ) + else: + entries.append(cmake_cache_option("ENABLE_IPC_SHARED_MEMORY", "+ipc_shmem" in spec)) return entries def cmake_args(self): - options = [] - return options + return [] def test(self): """Perform stand-alone checks on the installed package.""" diff --git a/var/spack/repos/builtin/packages/uncrustify/package.py b/var/spack/repos/builtin/packages/uncrustify/package.py index 4e0d627b833b40..e082a34bcc9e91 100644 --- a/var/spack/repos/builtin/packages/uncrustify/package.py +++ b/var/spack/repos/builtin/packages/uncrustify/package.py @@ -33,6 +33,9 @@ class Uncrustify(CMakePackage, AutotoolsPackage): version("0.62", commit="5987f2223f16b993dbece1360363eef9515fe5e8") version("0.61", sha256="1df0e5a2716e256f0a4993db12f23d10195b3030326fdf2e07f8e6421e172df9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_system( conditional("cmake", when="@0.64:"), conditional("autotools", when="@:0.63"), diff --git a/var/spack/repos/builtin/packages/unibilium/package.py b/var/spack/repos/builtin/packages/unibilium/package.py index b5b54d6838b842..9ad5173b85fd82 100644 --- a/var/spack/repos/builtin/packages/unibilium/package.py +++ b/var/spack/repos/builtin/packages/unibilium/package.py @@ -17,6 +17,9 @@ class Unibilium(Package): version("2.0.0", sha256="78997d38d4c8177c60d3d0c1aa8c53fd0806eb21825b7b335b1768d7116bc1c1") version("1.2.0", sha256="623af1099515e673abfd3cae5f2fa808a09ca55dda1c65a7b5c9424eb304ead8") + depends_on("c", type="build") # generated + + depends_on("gmake", type="build") depends_on("libtool", type="build") depends_on("perl", type="build") depends_on("gzip", type="build") diff --git a/var/spack/repos/builtin/packages/unifdef/package.py b/var/spack/repos/builtin/packages/unifdef/package.py index a1a8da0e98ca41..b9cdf43116eae8 100644 --- a/var/spack/repos/builtin/packages/unifdef/package.py +++ b/var/spack/repos/builtin/packages/unifdef/package.py @@ -23,6 +23,8 @@ class Unifdef(MakefilePackage): version("2.12", sha256="43ce0f02ecdcdc723b2475575563ddb192e988c886d368260bc0a63aee3ac400") version("2.11", sha256="828ffc270ac262b88fe011136acef2780c05b0dc3c5435d005651740788d4537") + depends_on("c", type="build") # generated + def edit(self, spec, prefix): makefile = FileFilter("Makefile") makefile.filter(r"\$\{HOME\}", prefix) diff --git a/var/spack/repos/builtin/packages/unifyfs/package.py b/var/spack/repos/builtin/packages/unifyfs/package.py index 0c0585e9bd9e5a..e1e2146648ccbc 100644 --- a/var/spack/repos/builtin/packages/unifyfs/package.py +++ b/var/spack/repos/builtin/packages/unifyfs/package.py @@ -27,6 +27,10 @@ class Unifyfs(AutotoolsPackage): version("1.0.1", sha256="d92800778661b15ab50275c4efe345a6c60d8f1802a0d5909fda38db91b12116") version("1.0", sha256="c9ad0d15d382773841a3dab89c661fbdcfd686ec37fa263eb22713f6404258f5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "auto-mount", default=True, diff --git a/var/spack/repos/builtin/packages/unigen/package.py b/var/spack/repos/builtin/packages/unigen/package.py index 732e8f0a6c1c28..ddfd81e2a7e8e8 100644 --- a/var/spack/repos/builtin/packages/unigen/package.py +++ b/var/spack/repos/builtin/packages/unigen/package.py @@ -23,6 +23,8 @@ class Unigen(MakefilePackage): license("GPL-3.0-only") version("2.3", sha256="8783bcabbdf8c50dab6e93153cff9cfb267a9a9e61aef51bf1e17679ba42a717") + + depends_on("cxx", type="build") # generated patch("unigen-2.3.patch", level=0) depends_on("root", type=("build", "link")) diff --git a/var/spack/repos/builtin/packages/unison/package.py b/var/spack/repos/builtin/packages/unison/package.py index 5888b674ecb9ee..202b93a5310f78 100644 --- a/var/spack/repos/builtin/packages/unison/package.py +++ b/var/spack/repos/builtin/packages/unison/package.py @@ -32,6 +32,8 @@ class Unison(MakefilePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("ocaml@4.10.0:~force-safe-string", type=("build", "link")) with when("@:2.51.2"): diff --git a/var/spack/repos/builtin/packages/units/package.py b/var/spack/repos/builtin/packages/units/package.py index 45e4660cff1c48..86ae202792890f 100644 --- a/var/spack/repos/builtin/packages/units/package.py +++ b/var/spack/repos/builtin/packages/units/package.py @@ -14,7 +14,10 @@ class Units(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-only") + version("2.23", sha256="d957b451245925c9e614c4513397449630eaf92bd62b8495ba09bbe351a17370") version("2.22", sha256="5d13e1207721fe7726d906ba1d92dc0eddaa9fc26759ed22e3b8d1a793125848") version("2.13", sha256="0ba5403111f8e5ea22be7d51ab74c8ccb576dc30ddfbf18a46cb51f9139790ab") + depends_on("c", type="build") # generated + depends_on("python", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/unittest-cpp/package.py b/var/spack/repos/builtin/packages/unittest-cpp/package.py index 0c71fdc9b72c57..f605896a98b74a 100644 --- a/var/spack/repos/builtin/packages/unittest-cpp/package.py +++ b/var/spack/repos/builtin/packages/unittest-cpp/package.py @@ -21,3 +21,5 @@ class UnittestCpp(CMakePackage): version("2.0.0", sha256="74852198877dc2fdebdc4e5e9bd074018bf8ee03a13de139bfe41f4585b2f5b9") version("1.6.0", sha256="9fa7e797816e16669d68171418b0dc41ec6b7eaf8483f782441f5f159598c3c0") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/universal-ctags/package.py b/var/spack/repos/builtin/packages/universal-ctags/package.py index 899b475d48eaa0..9cbe8558f07be2 100644 --- a/var/spack/repos/builtin/packages/universal-ctags/package.py +++ b/var/spack/repos/builtin/packages/universal-ctags/package.py @@ -19,6 +19,9 @@ class UniversalCtags(AutotoolsPackage): license("GPL-2.0-or-later") version("master", branch="master") + version( + "6.1.20240505.0", sha256="d9329d9d28c8280fcf8626594813958d9f90160ad6c7f10b0341a577d5b53527" + ) version( "5.9.20210912.0", sha256="5082d4f7e5695be3d697c46e2232d76c6d8adff51d22ba7a4b869362f444ee21" ) @@ -26,6 +29,10 @@ class UniversalCtags(AutotoolsPackage): "5.9.20210808.0", sha256="7f5f88d20750dfa2437ca9d163972b8684e3cf16de022a5177f322be92f528cc" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/universal/package.py b/var/spack/repos/builtin/packages/universal/package.py index c873dd0b6e47c7..9dd7734cd8daa0 100644 --- a/var/spack/repos/builtin/packages/universal/package.py +++ b/var/spack/repos/builtin/packages/universal/package.py @@ -17,3 +17,6 @@ class Universal(CMakePackage): license("MIT") version("3.68", sha256="67de4e0a3276b873a298ab98f1237ff3fd23240178e71405bf813ee38e4b1f62") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/unixodbc/package.py b/var/spack/repos/builtin/packages/unixodbc/package.py index 171c25961e5d51..13cded541f84d1 100644 --- a/var/spack/repos/builtin/packages/unixodbc/package.py +++ b/var/spack/repos/builtin/packages/unixodbc/package.py @@ -18,6 +18,8 @@ class Unixodbc(AutotoolsPackage): version("2.3.4", sha256="2e1509a96bb18d248bf08ead0d74804957304ff7c6f8b2e5965309c632421e39") + depends_on("c", type="build") # generated + depends_on("iconv") depends_on("libtool") diff --git a/var/spack/repos/builtin/packages/unqlite/package.py b/var/spack/repos/builtin/packages/unqlite/package.py index 301a0b2eed43b2..420afc96261f64 100644 --- a/var/spack/repos/builtin/packages/unqlite/package.py +++ b/var/spack/repos/builtin/packages/unqlite/package.py @@ -19,6 +19,8 @@ class Unqlite(CMakePackage): version("master", branch="master") version("1.1.9", sha256="33d5b5e7b2ca223942e77d31112d2e20512bc507808414451c8a98a7be5e15c0") + depends_on("c", type="build") # generated + # This patch corresponds to https://github.com/symisc/unqlite/pull/99 patch("0001-Removed-the-STATIC-key-word-to-enable-building-a-sha.patch", when="@1.1.9") diff --git a/var/spack/repos/builtin/packages/unrar/package.py b/var/spack/repos/builtin/packages/unrar/package.py index 339f255161a170..22c77232adac88 100644 --- a/var/spack/repos/builtin/packages/unrar/package.py +++ b/var/spack/repos/builtin/packages/unrar/package.py @@ -17,6 +17,8 @@ class Unrar(MakefilePackage): version("5.8.2", sha256="33386623fd3fb153b56292df4a6a69b457e69e1803b6d07b614e5fd22fb33dda") version("5.8.1", sha256="035f1f436f0dc2aea09aec146b9cc3e47ca2442f2c62b4ad9374c7c9cc20e632") + depends_on("cxx", type="build") # generated + def edit(self, spec, prefix): makefile = FileFilter("makefile") makefile.filter("LIBFLAGS=-fPIC", "LIBFLAGS={0}".format(self.compiler.cc_pic_flag)) diff --git a/var/spack/repos/builtin/packages/unuran/package.py b/var/spack/repos/builtin/packages/unuran/package.py index 9e185e5a631590..6779f6a9cc8bca 100644 --- a/var/spack/repos/builtin/packages/unuran/package.py +++ b/var/spack/repos/builtin/packages/unuran/package.py @@ -16,6 +16,9 @@ class Unuran(AutotoolsPackage): version("1.8.1", sha256="c270ae96857857dbac6450043df865e0517f52856ddbe5202fd35583b13c5193") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Enable the build of shared libraries") variant( "rngstreams", diff --git a/var/spack/repos/builtin/packages/unzip/package.py b/var/spack/repos/builtin/packages/unzip/package.py index 553a3da2988445..470376a47fdb7d 100644 --- a/var/spack/repos/builtin/packages/unzip/package.py +++ b/var/spack/repos/builtin/packages/unzip/package.py @@ -16,15 +16,13 @@ class Unzip(MakefilePackage): version("6.0", sha256="036d96991646d0449ed0aa952e4fbe21b476ce994abc276e49d30e686708bd37") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # clang and oneapi need this patch, likely others # There is no problem with it on gcc, so make it a catch all patch("configure-cflags.patch") - # The Cray cc wrapper doesn't handle the '-s' flag (strip) cleanly. - @when("platform=cray") - def patch(self): - filter_file(r"^LFLAGS2=.*", "LFLAGS2=", join_path("unix", "configure")) - def get_make_args(self): make_args = ["-f", join_path("unix", "Makefile")] @@ -33,7 +31,7 @@ def get_make_args(self): cflags.append("-Wno-error=implicit-int") cflags.append("-DLARGE_FILE_SUPPORT") - make_args.append('LOC="{}"'.format(" ".join(cflags))) + make_args.append(f"LOC=\"{' '.join(cflags)}\"") return make_args @property @@ -42,8 +40,8 @@ def build_targets(self): return self.get_make_args() + [target] def url_for_version(self, version): - return "http://downloads.sourceforge.net/infozip/unzip{0}.tar.gz".format(version.joined) + return f"http://downloads.sourceforge.net/infozip/unzip{version.joined}.tar.gz" @property def install_targets(self): - return self.get_make_args() + ["prefix={0}".format(self.prefix), "install"] + return self.get_make_args() + [f"prefix={self.prefix}", "install"] diff --git a/var/spack/repos/builtin/packages/upcxx/fix_configure_ldflags.patch b/var/spack/repos/builtin/packages/upcxx/fix_configure_ldflags.patch new file mode 100644 index 00000000000000..f41bc982f5a336 --- /dev/null +++ b/var/spack/repos/builtin/packages/upcxx/fix_configure_ldflags.patch @@ -0,0 +1,26 @@ +diff --git a/configure b/configure +index 27c35a43..b0f3cbe9 100755 +--- a/configure ++++ b/configure +@@ -1168,7 +1168,7 @@ if [[ $UPCXX_CUDA -eq 1 ]]; then + # check that the CUDA Driver API is linkable, adding explicit link flags if needed + echo -e "#include \n#include \nint main() { cuInit(0); return 0; }" >| conftest.cpp + for ldextra in '' '-lcuda' '-framework CUDA' 'FAIL'; do +- eval $CXX $UPCXX_CUDA_CPPFLAGS conftest.cpp -o conftest.exe $UPCXX_CUDA_LIBFLAGS $ldextra &> /dev/null ++ eval $CXX $UPCXX_CUDA_CPPFLAGS $LDFLAGS conftest.cpp -o conftest.exe $UPCXX_CUDA_LIBFLAGS $ldextra &> /dev/null + if [[ $? -eq 0 ]] && ( ./conftest.exe 2>/dev/null ); then + [[ -n "$ldextra" ]] && UPCXX_CUDA_LIBFLAGS+=" $ldextra" + break +diff --git a/utils/system-checks.sh b/utils/system-checks.sh +index 728792d0..e065f636 100644 +--- a/utils/system-checks.sh ++++ b/utils/system-checks.sh +@@ -493,7 +493,7 @@ _EOF + check_maybe_c_compiler + return 2 + fi +- if ! (set -x; eval $CXX $CXXFLAGS $CXXSTDFLAG -o conftest.o conftest-cc.o conftest-cxx.o -lm) >> $DETAIL_LOG 2>&1 ; then ++ if ! (set -x; eval $CXX $CXXFLAGS $CXXSTDFLAG $LDFLAGS -o conftest.o conftest-cc.o conftest-cxx.o -lm) >> $DETAIL_LOG 2>&1 ; then + echo "ERROR: CXX=$CXX failed to link object files produced by CC=$CC and CXX=$CXX" + echo "ERROR: See $DETAIL_LOG for details. Last four lines are as follows:" + tail -4 $DETAIL_LOG diff --git a/var/spack/repos/builtin/packages/upcxx/package.py b/var/spack/repos/builtin/packages/upcxx/package.py index f2996d0682a697..91971025683297 100644 --- a/var/spack/repos/builtin/packages/upcxx/package.py +++ b/var/spack/repos/builtin/packages/upcxx/package.py @@ -9,24 +9,30 @@ from spack.package import * +@llnl.util.lang.memoized def is_CrayXC(): - return (spack.platforms.host().name in ["linux", "cray"]) and ( + return spack.platforms.host().name == "linux" and ( os.environ.get("CRAYPE_NETWORK_TARGET") == "aries" ) +@llnl.util.lang.memoized def is_CrayEX(): - if spack.platforms.host().name in ["linux", "cray"]: + if spack.platforms.host().name == "linux": target = os.environ.get("CRAYPE_NETWORK_TARGET") if target in ["ofi", "ucx"]: # normal case return True elif target is None: # but some systems lack Cray PrgEnv fi_info = which("fi_info") - if fi_info and fi_info("-l", output=str).find("cxi") >= 0: + if ( + fi_info + and fi_info("-l", output=str, error=str, fail_on_error=False).find("cxi") >= 0 + ): return True return False +@llnl.util.lang.memoized def cross_detect(): if is_CrayXC(): if which("srun"): @@ -90,9 +96,14 @@ class Upcxx(Package, CudaPackage, ROCmPackage): deprecated=True, sha256="01be35bef4c0cfd24e9b3d50c88866521b9cac3ad4cbb5b1fc97aea55078810f", ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated # Do NOT add older versions here. # UPC++ releases over 2 years old are not supported. + patch("fix_configure_ldflags.patch", when="@2021.9.0:master") + variant("mpi", default=False, description="Enables MPI-based spawners and mpi-conduit") variant( @@ -136,15 +147,18 @@ class Upcxx(Package, CudaPackage, ROCmPackage): ) # UPC++ always relies on GASNet-EX. - # The default (and recommendation) is to use the implicit, embedded version. # This variant allows overriding with a particular version of GASNet-EX sources, # although this is not officially supported and some combinations might be rejected. - variant("gasnet", default=False, description="Override embedded GASNet-EX version") + # Original default was to use the embedded version of GASNet-EX, + # but currently there are newer versions in Spack so we default to that instead. + variant("gasnet", default=True, description="Override embedded GASNet-EX with Spack's") depends_on("gasnet conduits=none", when="+gasnet") depends_on("mpi", when="+mpi") depends_on("python@2.7.5:", type=("build", "run")) + depends_on("libfabric", when=is_CrayEX()) + conflicts("^hip@:4.4.0", when="+rocm") depends_on("oneapi-level-zero@1.8.0:", when="+level_zero") @@ -206,8 +220,8 @@ def install(self, spec, prefix): if is_CrayEX(): # Probe to find the right libfabric provider (SlingShot 10 vs 11) - fi_info = which("fi_info")("-l", output=str) - if fi_info.find("cxi") >= 0: + fi_info = which(spec["libfabric"].prefix.bin.fi_info) or which("fi_info") + if fi_info is None or fi_info("-l", output=str).find("cxi") >= 0: provider = "cxi" else: provider = "verbs;ofi_rxm" @@ -238,13 +252,16 @@ def install(self, spec, prefix): if "+cuda" in spec: options.append("--enable-cuda") + options.append("--with-cuda-home=" + spec["cuda"].prefix) options.append("--with-nvcc=" + spec["cuda"].prefix.bin.nvcc) + options.append( + "--with-ldflags=" + self.compiler.cc_rpath_arg + spec["cuda"].prefix.lib64 + ) if "+rocm" in spec: options.append("--enable-hip") - options.append( - "--with-ld-flags=" + self.compiler.cc_rpath_arg + spec["hip"].prefix.lib - ) + options.append("--with-hip-home=" + spec["hip"].prefix) + options.append("--with-ldflags=" + self.compiler.cc_rpath_arg + spec["hip"].prefix.lib) if "+level_zero" in spec: options.append("--enable-ze") diff --git a/var/spack/repos/builtin/packages/upp/package.py b/var/spack/repos/builtin/packages/upp/package.py index 3a6c52686e649b..b8b7fe13edb394 100644 --- a/var/spack/repos/builtin/packages/upp/package.py +++ b/var/spack/repos/builtin/packages/upp/package.py @@ -43,6 +43,9 @@ class Upp(CMakePackage): ) version("8.2.0", sha256="38de2178dc79420f42aa3fb8b85796fc49d43d66f90e5276e47ab50c282627ac") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=True, description="Use OpenMP threading") variant("postexec", default=True, description="Build NCEPpost executable") variant("wrf-io", default=False, description="Build with WRF-IO library") diff --git a/var/spack/repos/builtin/packages/uqtk/package.py b/var/spack/repos/builtin/packages/uqtk/package.py index 4eb4e7fbdb4bf2..929b7c26507764 100644 --- a/var/spack/repos/builtin/packages/uqtk/package.py +++ b/var/spack/repos/builtin/packages/uqtk/package.py @@ -22,6 +22,10 @@ class Uqtk(CMakePackage): version("3.1.0", sha256="56ecd3d13bdd908d568e9560dc52cc0f66d7bdcdbe64ab2dd0147a7cf1734f97") version("3.0.4", sha256="0a72856438134bb571fd328d1d30ce3d0d7aead32eda9b7fb6e436a27d546d2e") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "python", default=True, description="Compile Python scripts and interface to C++ libraries" ) diff --git a/var/spack/repos/builtin/packages/uriparser/package.py b/var/spack/repos/builtin/packages/uriparser/package.py index b9bc7a850120ae..0c6dacbfeb9b26 100644 --- a/var/spack/repos/builtin/packages/uriparser/package.py +++ b/var/spack/repos/builtin/packages/uriparser/package.py @@ -28,6 +28,9 @@ class Uriparser(CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("docs", default=False, description="Build API documentation") depends_on("cmake@3.3:", type="build") diff --git a/var/spack/repos/builtin/packages/usbutils/package.py b/var/spack/repos/builtin/packages/usbutils/package.py index a74b154e2a96e7..9228889ec29530 100644 --- a/var/spack/repos/builtin/packages/usbutils/package.py +++ b/var/spack/repos/builtin/packages/usbutils/package.py @@ -19,6 +19,8 @@ class Usbutils(AutotoolsPackage): version("011", sha256="9cf6e8c3030efc6abbb3c12de4da49816e0d6c6429f43fa3afb874cf72c2c869") version("010", sha256="e32f3debe6c1308bb9aa9a92c3d86f8565a6f6cf7711bccb07b0f83bf530717d") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/usearch/0001-Don-t-statically-link.patch b/var/spack/repos/builtin/packages/usearch/0001-Don-t-statically-link.patch new file mode 100644 index 00000000000000..f5912596632351 --- /dev/null +++ b/var/spack/repos/builtin/packages/usearch/0001-Don-t-statically-link.patch @@ -0,0 +1,26 @@ +From 8df3df8574522ec75c085d35f7c42a65dfe16cf4 Mon Sep 17 00:00:00 2001 +From: Alex C Leute +Date: Thu, 18 Jul 2024 14:39:35 -0400 +Subject: [PATCH] Don't statically link + +--- + src/Makefile | 3 --- + 1 file changed, 3 deletions(-) + +diff --git a/src/Makefile b/src/Makefile +index e849853..b796f52 100644 +--- a/src/Makefile ++++ b/src/Makefile +@@ -15,9 +15,6 @@ CXXFLAGS := $(CFLAGS) -DNDEBUG -pthread -O3 -ffast-math -march=native --std=c++1 + + UNAME_S := $(shell uname -s) + LDFLAGS := $(LDFLAGS) -O3 -pthread -lpthread +-ifeq ($(UNAME_S),Linux) +- LDFLAGS += -static +-endif + + HDRS = \ + accepter.h \ +-- +2.43.5 + diff --git a/var/spack/repos/builtin/packages/usearch/package.py b/var/spack/repos/builtin/packages/usearch/package.py index 6ce96241bcf20c..300a13b688a22b 100644 --- a/var/spack/repos/builtin/packages/usearch/package.py +++ b/var/spack/repos/builtin/packages/usearch/package.py @@ -8,28 +8,52 @@ from spack.package import * -class Usearch(Package): +class Usearch(MakefilePackage): """USEARCH is a unique sequence analysis tool with thousands of users world-wide. - Note: A manual download is required for USEARCH. - Spack will search your current directory for the download file. - Alternatively, add this file to a mirror so that Spack can find it. - For instructions on how to set up a mirror, see + Note: A manual download is required for USEARCH when @:11.0.667. Spack + will search your current directory for the download file. Alternatively, + add this file to a mirror so that Spack can find it. For instructions on + how to set up a mirror, see https://spack.readthedocs.io/en/latest/mirrors.html""" homepage = "https://www.drive5.com/usearch/" + url = "https://github.com/rcedgar/usearch12/archive/refs/tags/v12.0-beta1.tar.gz" maintainers("snehring") - manual_download = True + build_directory = "src" + version( + "12.0-beta1", sha256="dbb06e4733801dab1c405616880261bd885ab171dfdb1d44e8ede48d739cdc43" + ) version("11.0.667", sha256="1be0faa1380100296029064e4cf9665d723d43f03c794da444c5b1a6b6799ac2") version("10.0.240", sha256="297ba03cb5bdc60c9727b7949cc08bfeecad8b290c2844b5ad011f72a7e1399c") + with when("@12:"): + depends_on("c", type="build") + depends_on("cxx", type="build") + depends_on("ccache", type="build") + + patch("0001-Don-t-statically-link.patch", when="@12:") + + @property + def manual_download(self): + return self.spec.satisfies("@:11.0.667") + def url_for_version(self, version): - return "file://{0}/usearch{1}_i86linux32.gz".format(os.getcwd(), version) + if version <= Version("11.0.667"): + return "file://{0}/usearch{1}_i86linux32.gz".format(os.getcwd(), version) + return super().url_for_version(version) + + def build(self, spec, prefix): + if not self.spec.satisfies("@:11.0.667"): + super().build(spec, prefix) def install(self, spec, prefix): mkdirp(prefix.bin) - install("usearch{0}_i86linux32".format(self.version), prefix.bin.usearch) + if self.spec.satisfies("@:11.0.667"): + install("usearch{0}_i86linux32".format(self.version), prefix.bin.usearch) + else: + install("bin/usearch{0}".format(self.version.up_to(1)), prefix.bin.usearch) set_executable(prefix.bin.usearch) diff --git a/var/spack/repos/builtin/packages/userspace-rcu/package.py b/var/spack/repos/builtin/packages/userspace-rcu/package.py index adbfe989b6159c..732b0c693f5c1f 100644 --- a/var/spack/repos/builtin/packages/userspace-rcu/package.py +++ b/var/spack/repos/builtin/packages/userspace-rcu/package.py @@ -30,6 +30,8 @@ class UserspaceRcu(AutotoolsPackage): version("0.10.2", sha256="e117c416fced894e24720cc1b38247074a13020f19d6704b38e554cbcb993d06") version("0.9.6", sha256="4d9e4ca40c079e0b0e9f912a9092589b97fbaf80eb6537e9ae70d48c09472efa") + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/ut/package.py b/var/spack/repos/builtin/packages/ut/package.py index 1f76e497d0de88..fc4add539ccfc8 100644 --- a/var/spack/repos/builtin/packages/ut/package.py +++ b/var/spack/repos/builtin/packages/ut/package.py @@ -22,6 +22,8 @@ class Ut(CMakePackage): version("2.0.0", sha256="8b5b11197d1308dfc1fe20efd6a656e0c833dbec2807e2292967f6e2f7c0420f") version("1.1.9", sha256="1a666513157905aa0e53a13fac602b5673dcafb04a869100a85cd3f000c2ed0d") + depends_on("cxx", type="build") + generator("ninja") depends_on("cmake@3.21:3.25", type="build", when="@master") diff --git a/var/spack/repos/builtin/packages/utf8proc/package.py b/var/spack/repos/builtin/packages/utf8proc/package.py index 1ab8b537e18741..ae92704ecadc72 100644 --- a/var/spack/repos/builtin/packages/utf8proc/package.py +++ b/var/spack/repos/builtin/packages/utf8proc/package.py @@ -13,6 +13,7 @@ class Utf8proc(CMakePackage): homepage = "https://juliastrings.github.io/utf8proc/" url = "https://github.com/JuliaStrings/utf8proc/archive/v2.4.0.tar.gz" + version("2.9.0", sha256="18c1626e9fc5a2e192311e36b3010bfc698078f692888940f1fa150547abb0c1") version("2.8.0", sha256="a0a60a79fe6f6d54e7d411facbfcc867a6e198608f2cd992490e46f04b1bcecc") version("2.7.0", sha256="4bb121e297293c0fd55f08f83afab6d35d48f0af4ecc07523ad8ec99aa2b12a1") version("2.6.1", sha256="4c06a9dc4017e8a2438ef80ee371d45868bda2237a98b26554de7a95406b283b") @@ -20,6 +21,8 @@ class Utf8proc(CMakePackage): version("2.5.0", sha256="d4e8dfc898cfd062493cb7f42d95d70ccdd3a4cd4d90bec0c71b47cca688f1be") version("2.4.0", sha256="b2e5d547c1d94762a6d03a7e05cea46092aab68636460ff8648f1295e2cdfbd7") + depends_on("c", type="build") # generated + variant("shared", default=False, description="Build a shared version of the library") def cmake_args(self): diff --git a/var/spack/repos/builtin/packages/uthash/package.py b/var/spack/repos/builtin/packages/uthash/package.py index 1b176904a79670..61b1535e2eb73d 100644 --- a/var/spack/repos/builtin/packages/uthash/package.py +++ b/var/spack/repos/builtin/packages/uthash/package.py @@ -16,6 +16,9 @@ class Uthash(Package): version("2.3.0", sha256="e10382ab75518bad8319eb922ad04f907cb20cccb451a3aa980c9d005e661acc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.include) for header in find(join_path(self.stage.source_path, "src"), "*.h"): diff --git a/var/spack/repos/builtin/packages/util-linux-uuid/package.py b/var/spack/repos/builtin/packages/util-linux-uuid/package.py index d41a9a93ae805b..4b8171e5ba4fab 100644 --- a/var/spack/repos/builtin/packages/util-linux-uuid/package.py +++ b/var/spack/repos/builtin/packages/util-linux-uuid/package.py @@ -14,13 +14,17 @@ class UtilLinuxUuid(AutotoolsPackage): list_url = "https://www.kernel.org/pub/linux/utils/util-linux" list_depth = 1 - license("GPL-2.0-or-later") + license("BSD-3-Clause", checked_by="wdconinc") + version("2.40.2", sha256="7bec316b713a14c6be1a5721aa0e56a3b6170277329e6e1f1a56013cc91eece0") + version("2.40.1", sha256="8e396eececae2b3b68db232c33b8810faa7c31f6df19f98f512739293d5829b7") version("2.38.1", sha256="0820eb8eea90408047e3715424bc6be771417047f683950fecb4bdd2e2cbbc6e") version("2.37.4", sha256="c8b7b4fa541f974cc32c1c6559d9bfca33651020a456ad6ee5fc9b0cacd00151") version("2.36.2", sha256="f5dbe79057e7d68e1a46fc04083fc558b26a49499b1b3f50e4f4893150970463") version("2.36", sha256="82942cd877a989f6d12d4ce2c757fb67ec53d8c5cd9af0537141ec5f84a2eea3") + depends_on("c", type="build") # generated + conflicts("%gcc@:4", when="@2.37:") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/util-linux/package.py b/var/spack/repos/builtin/packages/util-linux/package.py index 72529d2a356ab5..e4a67d8ed94ad6 100644 --- a/var/spack/repos/builtin/packages/util-linux/package.py +++ b/var/spack/repos/builtin/packages/util-linux/package.py @@ -16,8 +16,11 @@ class UtilLinux(AutotoolsPackage): list_url = "https://www.kernel.org/pub/linux/utils/util-linux" list_depth = 1 - license("GPL-2.0-only") + license("GPL-2.0-only", checked_by="wdconinc") + version("2.40.2", sha256="7bec316b713a14c6be1a5721aa0e56a3b6170277329e6e1f1a56013cc91eece0") + version("2.40", sha256="2a51d08cb71fd8e491e0cf633032c928f9a2848417f8441cb8cf7ef9971de916") + version("2.39.3", sha256="40ea07584d56c310455471afa92c119ec259776a561af7159cc802344c2c370d") version("2.39.1", sha256="d7c8a58eb2c7248a32754eb3a3b6772e368b984d9907ada834c2cf3e13024270") version("2.38.1", sha256="0820eb8eea90408047e3715424bc6be771417047f683950fecb4bdd2e2cbbc6e") version("2.38", sha256="c31d4e54f30b56b0f7ec8b342658c07de81378f2c067941c2b886da356f8ad42") @@ -36,6 +39,8 @@ class UtilLinux(AutotoolsPackage): version("2.29.1", sha256="a6a7adba65a368e6dad9582d9fbedee43126d990df51266eaee089a73c893653") version("2.25", sha256="7e43273a9e2ab99b5a54ac914fddf5d08ba7ab9b114c550e9f03474672bd23a1") + depends_on("c", type="build") # generated + depends_on("python@2.7:", type="build") depends_on("pkgconfig", type="build") depends_on("ncurses", type="link") @@ -76,6 +81,10 @@ def configure_args(self): ["--disable-ipcs", "--disable-ipcrm", "--disable-wall", "--disable-libmount"] ) + if self.spec.satisfies("@2.40:"): + # Disable liblastlog2, which depends on sqlite + config_args.append("--disable-liblastlog2") + return config_args def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/util-macros/package.py b/var/spack/repos/builtin/packages/util-macros/package.py index feca9d82d142a1..1f6411e2bd9c26 100644 --- a/var/spack/repos/builtin/packages/util-macros/package.py +++ b/var/spack/repos/builtin/packages/util-macros/package.py @@ -11,18 +11,24 @@ class UtilMacros(AutotoolsPackage, XorgPackage): other Xorg modular packages, and is needed to generate new versions of their configure scripts with autoconf.""" - homepage = "https://cgit.freedesktop.org/xorg/util/macros/" - xorg_mirror_path = "util/util-macros-1.19.1.tar.bz2" + homepage = "https://gitlab.freedesktop.org/xorg/util/macros" + xorg_mirror_path = "util/util-macros-1.19.1.tar.xz" - maintainers("robert-mijakovic") + maintainers("robert-mijakovic", "wdconinc") license("MIT") + version("1.20.1", sha256="0b308f62dce78ac0f4d9de6888234bf170f276b64ac7c96e99779bb4319bcef5") version("1.19.3", sha256="0f812e6e9d2786ba8f54b960ee563c0663ddbe2434bf24ff193f5feab1f31971") version("1.19.2", sha256="d7e43376ad220411499a79735020f9d145fdc159284867e99467e0d771f3e712") version("1.19.1", sha256="18d459400558f4ea99527bc9786c033965a3db45bf4c6a32eefdc07aa9e306a6") version("1.19.0", sha256="2835b11829ee634e19fa56517b4cfc52ef39acea0cd82e15f68096e27cbed0ba") + # note: url_for_version can only return a single url, no mirrors + def url_for_version(self, version): + if self.spec.satisfies("@:1.19"): + return spack.url.substitute_version(self.urls[0].replace("xz", "bz2"), version) + def setup_dependent_build_environment(self, env, dependent_spec): """Adds the ACLOCAL path for autotools.""" env.append_path("ACLOCAL_PATH", self.prefix.share.aclocal) diff --git a/var/spack/repos/builtin/packages/uvw/package.py b/var/spack/repos/builtin/packages/uvw/package.py index 685ab77ffbb723..b99312427166bf 100644 --- a/var/spack/repos/builtin/packages/uvw/package.py +++ b/var/spack/repos/builtin/packages/uvw/package.py @@ -21,6 +21,8 @@ class Uvw(CMakePackage): version("1.13.0", sha256="cc9944e5a2cdeb19bb74c61c3c02816c5a02b4339f3ad16e979bb7c8640e22c0") version("1.12.0", sha256="b7751294fa00e8a96cd7d70989beda7a6117f5d9f4751306b7b2bbbb4702aac8") + depends_on("cxx", type="build") # generated + variant("docs", default=False, description="Builds and install the documentation") depends_on("libuv", type="link") diff --git a/var/spack/repos/builtin/packages/vacuumms/package.py b/var/spack/repos/builtin/packages/vacuumms/package.py index 96b07689e6ca6b..eb5418df90731a 100644 --- a/var/spack/repos/builtin/packages/vacuumms/package.py +++ b/var/spack/repos/builtin/packages/vacuumms/package.py @@ -16,25 +16,51 @@ class Vacuumms(CMakePackage): under Linux on x86_64 and ARM64. Please submit questions, pull requests, and bug reports via github. https://dl.acm.org/doi/abs/10.1145/2335755.2335826""" - homepage = "https://github.com/frankwillmore/VACUUMMS" - url = "https://github.com/frankwillmore/VACUUMMS/archive/refs/tags/v1.0.0.tar.gz" - git = "https://github.com/frankwillmore/VACUUMMS.git" + homepage = "https://github.com/VACUUMMS/VACUUMMS" + url = "https://github.com/VACUUMMS/VACUUMMS/archive/refs/tags/v1.0.0.tar.gz" + git = "https://github.com/VACUUMMS/VACUUMMS.git" maintainers("frankwillmore") - license("Unlicense") + license("MIT") - version("master", branch="master") - version("1.1.1", tag="v1.1.1", commit="a395930c87f5b52ab0ab8db278bd2bde592e8f12") + # This is the main branch, for the latest functionality + version("develop", branch="develop") + + version( + "1.2.0", + sha256="1836e6c29d1e83a79f9c6a9b686d1419bd72618aba7c46d3d038373808519d56", + preferred=True, + deprecated=False, + ) + version( + "1.1.4", + sha256="13052bafca8622df5f14613b3d4cddd50bae725e0c13c1df7f3cdee28a2e673a", + deprecated=False, + ) version( "1.0.0", sha256="c18fe52f5041880da7f50d3808d37afb3e9c936a56f80f67838d045bf7af372f", deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant("test", default=True, description="enable CMake testing") variant("tiff", default=False, description="Build TIFF utilities") variant("cuda", default=False, description="Build CUDA applications and utilities") + variant("variational", default=False, description="Build VARIATIONAL module") + variant("voronoi", default=False, description="Build VORONOI applications and utilities") + variant( + "VOROPP_HOME", + default="/opt/voropp", + description="voro++ location", + multi=False, + when="+voronoi", + ) + depends_on("voropp", type=("link", "run"), when="+voronoi") depends_on("libtiff", type=("link", "run"), when="+tiff") depends_on("cuda", type=("link", "run"), when="+cuda") depends_on("libx11", type=("link", "run")) @@ -44,6 +70,10 @@ class Vacuumms(CMakePackage): def cmake_args(self): return [ + self.define_from_variant("ENABLE_TESTING", "test"), self.define_from_variant("BUILD_CUDA_COMPONENTS", "cuda"), self.define_from_variant("BUILD_TIFF_UTILS", "tiff"), + self.define_from_variant("BUILD_VARIATIONAL_MODULE", "variational"), + self.define_from_variant("BUILD_VORONOI_UTILS", "voronoi"), + self.define_from_variant("VOROPP_HOME", "VOROPP_HOME"), ] diff --git a/var/spack/repos/builtin/packages/vala/package.py b/var/spack/repos/builtin/packages/vala/package.py index e7e03a4462f4f4..5fbec5e05dcb09 100644 --- a/var/spack/repos/builtin/packages/vala/package.py +++ b/var/spack/repos/builtin/packages/vala/package.py @@ -32,6 +32,8 @@ class Vala(AutotoolsPackage): version("0.48.15", sha256="5f64283f8e69a48c73256cb93578c7db4c35c0b7df079568a4d5b6065b602a50") version("0.48.14", sha256="dca57de29f4ce18ee8c6b1e4f1b37ca3843d19dae5c455fceebccc5ae3ffe347") + depends_on("c", type="build") # generated + variant("doc", default=False, description="build valadoc") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/valgrind/package.py b/var/spack/repos/builtin/packages/valgrind/package.py index 0820d4c6b664b1..a87966faf9e1a1 100644 --- a/var/spack/repos/builtin/packages/valgrind/package.py +++ b/var/spack/repos/builtin/packages/valgrind/package.py @@ -27,6 +27,9 @@ class Valgrind(AutotoolsPackage, SourcewarePackage): license("GPL-2.0-or-later") version("develop", branch="master") + version("3.23.0", sha256="c5c34a3380457b9b75606df890102e7df2c702b9420c2ebef9540f8b5d56264d") + version("3.22.0", sha256="c811db5add2c5f729944caf47c4e7a65dcaabb9461e472b578765dd7bf6d2d4c") + version("3.21.0", sha256="10ce1618bb3e33fad16eb79552b0a3e1211762448a0d7fce11c8a6243b9ac971") version("3.20.0", sha256="8536c031dbe078d342f121fa881a9ecd205cb5a78e639005ad570011bdb9f3c6") version("3.19.0", sha256="dd5e34486f1a483ff7be7300cc16b4d6b24690987877c3278d797534d6738f02") version("3.18.1", sha256="00859aa13a772eddf7822225f4b46ee0d39afbe071d32778da4d99984081f7f5") @@ -41,6 +44,9 @@ class Valgrind(AutotoolsPackage, SourcewarePackage): version("3.10.1", sha256="fa253dc26ddb661b6269df58144eff607ea3f76a9bcfe574b0c7726e1dfcb997") version("3.10.0", sha256="03047f82dfc6985a4c7d9d2700e17bc05f5e1a0ca6ad902e5d6c81aeb720edc9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Activates MPI support for valgrind") variant("boost", default=True, description="Activates boost support for valgrind") variant("only64bit", default=True, description="Sets --enable-only64bit option for valgrind") diff --git a/var/spack/repos/builtin/packages/valijson/package.py b/var/spack/repos/builtin/packages/valijson/package.py index 0b7f2ddf1b1e5a..888737395417dc 100644 --- a/var/spack/repos/builtin/packages/valijson/package.py +++ b/var/spack/repos/builtin/packages/valijson/package.py @@ -18,4 +18,7 @@ class Valijson(CMakePackage): license("BSD-2-Clause") version("master", branch="master") + version("1.0.2", sha256="35d86e54fc727f1265226434dc996e33000a570f833537a25c8b702b0b824431") version("1.0", sha256="6b9f0bc89880feb3fe09aa469cd81f6168897d2fbb4e715853da3b94afd3779a") + + depends_on("cxx", type="build") # generated diff --git a/var/spack/repos/builtin/packages/vampirtrace/package.py b/var/spack/repos/builtin/packages/vampirtrace/package.py index bc28a286d0466f..2809c5d74ff64e 100644 --- a/var/spack/repos/builtin/packages/vampirtrace/package.py +++ b/var/spack/repos/builtin/packages/vampirtrace/package.py @@ -16,6 +16,10 @@ class Vampirtrace(AutotoolsPackage): version("5.14.4", sha256="1719a1666dd274c221b781631958cae56aa8bcb3f22861fb4ba6526c1b465a30") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("mpi", default=True, description="Enable MPI support") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin/packages/vapor/package.py b/var/spack/repos/builtin/packages/vapor/package.py index 72507b8b86f8ff..e6a2bf2349235f 100644 --- a/var/spack/repos/builtin/packages/vapor/package.py +++ b/var/spack/repos/builtin/packages/vapor/package.py @@ -29,6 +29,9 @@ class Vapor(CMakePackage): preferred=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("doc", default=True, description="Build docs using Doxygen") variant("ospray", default=False, description="Enable OSPRay raytracing") diff --git a/var/spack/repos/builtin/packages/vardictjava/package.py b/var/spack/repos/builtin/packages/vardictjava/package.py index e48185dca3d558..967ca0b938adec 100644 --- a/var/spack/repos/builtin/packages/vardictjava/package.py +++ b/var/spack/repos/builtin/packages/vardictjava/package.py @@ -16,6 +16,7 @@ class Vardictjava(Package): "https://github.com/AstraZeneca-NGS/VarDictJava/releases/download/v1.5.1/VarDict-1.5.1.tar" ) + version("1.8.3", sha256="020a84d6718531097a05207a59d85d80803b0eda074ea6c0a3d1842cc84f2daf") version("1.5.1", sha256="f1d710d238e8ab41b02a99fa8698baeee8c8668635a847b826913dd03a9176b9") depends_on("java@8:", type="run") diff --git a/var/spack/repos/builtin/packages/variorum/package.py b/var/spack/repos/builtin/packages/variorum/package.py index 201061aeff4d08..a1c0ce5f15f941 100644 --- a/var/spack/repos/builtin/packages/variorum/package.py +++ b/var/spack/repos/builtin/packages/variorum/package.py @@ -19,6 +19,8 @@ class Variorum(CMakePackage): license("MIT") + version("dev", branch="dev") + version("0.8.0", sha256="0e7288d523488b2a585af8ffeb7874721526f46df563b21fc51e8846bf65f7d8") version("0.7.0", sha256="36ec0219379ea2b7c8f9770b3271335c776ff5a3de71585714c33356345b2f0c") version("0.6.0", sha256="c0928a0e6901808ee50142d1034de15edc2c90d7d1b9fbce43757226e7c04306") version("0.5.0", sha256="de331762e7945ee882d08454ff9c66436e2b6f87f761d2b31c6ab3028723bfed") @@ -28,6 +30,10 @@ class Variorum(CMakePackage): version("0.2.0", sha256="b8c010b26aad8acc75d146c4461532cf5d9d3d24d6fc30ee68f6330a68e65744") version("0.1.0", tag="v0.1.0", commit="7747ee48cc60567bb3f09e732f24c041ecac894d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + ############ # Variants # ############ diff --git a/var/spack/repos/builtin/packages/varnish-cache/package.py b/var/spack/repos/builtin/packages/varnish-cache/package.py index 9d3fd83987ddbc..2950922511ee9c 100644 --- a/var/spack/repos/builtin/packages/varnish-cache/package.py +++ b/var/spack/repos/builtin/packages/varnish-cache/package.py @@ -20,6 +20,8 @@ class VarnishCache(AutotoolsPackage): version("6.3.0", sha256="c7170d4bc57f1d2454da046fc5e43e2d19a804448d2dd839fa5c33f76bd677bb") version("6.2.3", sha256="64cd273aa155c78c21e74def53622be5920c8a7d952fee74f0663e57a01c9a9d") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/vasp/package.py b/var/spack/repos/builtin/packages/vasp/package.py index 1f67e9b006bff9..aa937bc4ab4b1a 100644 --- a/var/spack/repos/builtin/packages/vasp/package.py +++ b/var/spack/repos/builtin/packages/vasp/package.py @@ -8,7 +8,7 @@ from spack.package import * -class Vasp(MakefilePackage): +class Vasp(MakefilePackage, CudaPackage): """ The Vienna Ab initio Simulation Package (VASP) is a computer program for atomic scale materials modelling, @@ -18,14 +18,32 @@ class Vasp(MakefilePackage): homepage = "https://vasp.at" url = "file://{0}/vasp.5.4.4.pl2.tgz".format(os.getcwd()) + maintainers("snehring") manual_download = True + version("6.4.3", sha256="fe30e773f2a3e909b5e0baa9654032dfbdeff7ec157bc348cee7681a7b6c24f4") version("6.3.2", sha256="f7595221b0f9236a324ea8afe170637a578cdd5a837cc7679e7f7812f6edf25a") version("6.3.0", sha256="adcf83bdfd98061016baae31616b54329563aa2739573f069dd9df19c2071ad3") - version("6.2.0", sha256="49e7ba351bd634bc5f5f67a8ef1e38e64e772857a1c02f602828898a84197e25") - version("6.1.1", sha256="e37a4dfad09d3ad0410833bcd55af6b599179a085299026992c2d8e319bf6927") - version("5.4.4.pl2", sha256="98f75fd75399a23d76d060a6155f4416b340a1704f256a00146f89024035bc8e") - version("5.4.4", sha256="5bd2449462386f01e575f9adf629c08cb03a13142806ffb6a71309ca4431cfb3") + version( + "6.2.0", + sha256="49e7ba351bd634bc5f5f67a8ef1e38e64e772857a1c02f602828898a84197e25", + deprecated=True, + ) + version( + "6.1.1", + sha256="e37a4dfad09d3ad0410833bcd55af6b599179a085299026992c2d8e319bf6927", + deprecated=True, + ) + version( + "5.4.4.pl2", + sha256="98f75fd75399a23d76d060a6155f4416b340a1704f256a00146f89024035bc8e", + deprecated=True, + ) + version( + "5.4.4", + sha256="5bd2449462386f01e575f9adf629c08cb03a13142806ffb6a71309ca4431cfb3", + deprecated=True, + ) resource( name="vaspsol", @@ -34,270 +52,289 @@ class Vasp(MakefilePackage): when="+vaspsol", ) - variant("openmp", default=False, description="Enable openmp build") - with when("+openmp"): - conflicts("^fftw~openmp") - conflicts("^amdfftw~openmp") - conflicts("^amdblis threads=none") - conflicts("^amdblis threads=pthreads") - conflicts("^openblas threads=none") - conflicts("^openblas threads=pthreads") + variant("openmp", default=False, when="@6:", description="Enable openmp build") - variant("scalapack", default=False, description="Enables build with SCALAPACK") + variant("scalapack", default=False, when="@:5", description="Enables build with SCALAPACK") variant("cuda", default=False, description="Enables running on Nvidia GPUs") - variant("fftlib", default=False, description="Enables fftlib build") - with when("+fftlib"): - conflicts("@:6.1.1", msg="fftlib support started from 6.2.0") - conflicts("~openmp", msg="fftlib is intended to be used with openmp") + variant("fftlib", default=True, when="@6.2: +openmp", description="Enables fftlib build") variant( "vaspsol", default=False, + when="@:6.2", description="Enable VASPsol implicit solvation model\n" "https://github.com/henniggroup/VASPsol", ) variant("shmem", default=True, description="Enable use_shmem build flag") + variant("hdf5", default=False, when="@6.2:", description="Enabled HDF5 support") depends_on("rsync", type="build") depends_on("blas") depends_on("lapack") depends_on("fftw-api") + depends_on("fftw+openmp", when="+openmp ^[virtuals=fftw-api] fftw") + depends_on("amdfftw+openmp", when="+openmp ^[virtuals=fftw-api] amdfftw") + depends_on("amdblis threads=openmp", when="+openmp ^[virtuals=blas] amdblis") + depends_on("openblas threads=openmp", when="+openmp ^[virtuals=blas] openblas") depends_on("mpi", type=("build", "link", "run")) + # fortran oddness requires the below + depends_on("openmpi%aocc", when="%aocc ^[virtuals=mpi] openmpi") + depends_on("openmpi%gcc", when="%gcc ^[virtuals=mpi] openmpi") depends_on("scalapack", when="+scalapack") - depends_on("cuda", when="+cuda") - depends_on("qd", when="%nvhpc") + # wiki (and makefiles) suggest scalapack is expected in 6: + depends_on("scalapack", when="@6:") + depends_on("nccl", when="@6.3: +cuda") + depends_on("hdf5+fortran+mpi", when="+hdf5") + # at the very least the nvhpc mpi seems required + depends_on("nvhpc+mpi+lapack+blas", when="%nvhpc") conflicts( "%gcc@:8", msg="GFortran before 9.x does not support all features needed to build VASP" ) conflicts("+vaspsol", when="+cuda", msg="+vaspsol only available for CPU") - conflicts("+openmp", when="@:6.1.1", msg="openmp support started from 6.2") - - parallel = False + requires("%nvhpc", when="@6.3: +cuda", msg="vasp requires nvhpc to build the openacc build") + # the mpi compiler wrappers in nvhpc assume nvhpc is the underlying compiler, seemingly + conflicts("^[virtuals=mpi] nvhpc", when="%gcc", msg="nvhpc mpi requires nvhpc compiler") + conflicts("^[virtuals=mpi] nvhpc", when="%aocc", msg="nvhpc mpi requires nvhpc compiler") + conflicts( + "cuda_arch=none", when="@6.3: +cuda", msg="CUDA arch required when building openacc port" + ) def edit(self, spec, prefix): - if "%gcc" in spec: - if "+openmp" in spec: - make_include = join_path("arch", "makefile.include.linux_gnu_omp") - else: - make_include = join_path("arch", "makefile.include.linux_gnu") - elif "%nvhpc" in spec: - make_include = join_path("arch", "makefile.include.linux_pgi") - filter_file("-pgc++libs", "-c++libs", make_include, string=True) - filter_file("pgcc", spack_cc, make_include) - filter_file("pgc++", spack_cxx, make_include, string=True) - filter_file("pgfortran", spack_fc, make_include) - filter_file( - "/opt/pgi/qd-2.3.17/install/include", spec["qd"].prefix.include, make_include - ) - filter_file("/opt/pgi/qd-2.3.17/install/lib", spec["qd"].prefix.lib, make_include) - elif "%aocc" in spec: - if "+openmp" in spec: - if "@6.3.0" in spec: - copy( - join_path("arch", "makefile.include.gnu_ompi_aocl_omp"), - join_path("arch", "makefile.include.linux_aocc_omp"), - ) - make_include = join_path("arch", "makefile.include.linux_aocc_omp") - - elif "@6.3.2:" in spec: - make_include = join_path("arch", "makefile.include.aocc_ompi_aocl_omp") - else: - copy( - join_path("arch", "makefile.include.linux_gnu_omp"), - join_path("arch", "makefile.include.linux_aocc_omp"), - ) - make_include = join_path("arch", "makefile.include.linux_aocc_omp") - else: - if "@6.3.0:" in spec: - copy( - join_path("arch", "makefile.include.gnu_ompi_aocl"), - join_path("arch", "makefile.include.linux_aocc"), - ) - make_include = join_path("arch", "makefile.include.linux_aocc") - if "@6.3.2:" in spec: - make_include = join_path("arch", "makefile.include.aocc_ompi_aocl") - else: - copy( - join_path("arch", "makefile.include.linux_gnu"), - join_path("arch", "makefile.include.linux_aocc"), - ) - make_include = join_path("arch", "makefile.include.linux_aocc_omp") - filter_file("^CC_LIB[ ]{0,}=.*$", "CC_LIB={0}".format(spack_cc), make_include) - if "@6.3.0:" in spec: - filter_file("gcc", "{0} {1}".format(spack_fc, "-Mfree"), make_include, string=True) - else: - filter_file("gcc", "{0}".format(spack_fc), make_include, string=True) - filter_file("g++", spack_cxx, make_include, string=True) - - filter_file("^CFLAGS_LIB[ ]{0,}=.*$", "CFLAGS_LIB = -O3", make_include) - filter_file("^FFLAGS_LIB[ ]{0,}=.*$", "FFLAGS_LIB = -O3", make_include) - filter_file("^OFLAG[ ]{0,}=.*$", "OFLAG = -O3", make_include) - filter_file( - "^FC[ ]{0,}=.*$", "FC = {0}".format(spec["mpi"].mpifc), make_include, string=True - ) - filter_file( - "^FCL[ ]{0,}=.*$", - '"FCL = {0}".format(spec["mpi"].mpifc)', - make_include, - string=True, - ) - filter_file( - "-fallow-argument-mismatch", " -fno-fortran-main", make_include, string=True - ) - - filter_file("^OBJECTS_LIB[ ]{0,}=.*$", "OBJECTS_LIB ?=", make_include) - filter_file("-march=native", " ", make_include) - else: - if "+openmp" in spec: - make_include = join_path( - "arch", "makefile.include.linux_{0}_omp".format(spec.compiler.name) - ) - else: - make_include = join_path("arch", "makefile.include.linux_" + spec.compiler.name) - - # Recent versions of vasp have renamed the makefile.include files - # to leave out the linux_ string - if not os.path.exists(make_include): - make_include = make_include.replace("linux_", "") - os.rename(make_include, "makefile.include") - - # This bunch of 'filter_file()' is to make these options settable - # as environment variables - filter_file("^CPP_OPTIONS[ ]{0,}=[ ]{0,}", "CPP_OPTIONS ?= ", "makefile.include") - filter_file("^FFLAGS[ ]{0,}=[ ]{0,}", "FFLAGS ?= ", "makefile.include") - - filter_file("^LIBDIR[ ]{0,}=.*$", "", "makefile.include") - filter_file("^BLAS[ ]{0,}=.*$", "BLAS ?=", "makefile.include") - filter_file("^LAPACK[ ]{0,}=.*$", "LAPACK ?=", "makefile.include") - filter_file("^FFTW[ ]{0,}?=.*$", "FFTW ?=", "makefile.include") - filter_file("^MPI_INC[ ]{0,}=.*$", "MPI_INC ?=", "makefile.include") - filter_file("-DscaLAPACK.*$\n", "", "makefile.include") - filter_file("^SCALAPACK[ ]{0,} =.*$", "SCALAPACK ?=", "makefile.include") - - if "+cuda" in spec: - filter_file("^OBJECTS_GPU[ ]{0,}=.*$", "OBJECTS_GPU ?=", "makefile.include") - - filter_file("^CPP_GPU[ ]{0,}=.*$", "CPP_GPU ?=", "makefile.include") - - filter_file("^CFLAGS[ ]{0,}=.*$", "CFLAGS ?=", "makefile.include") - - if "+fftlib" in spec: - filter_file("^#FCL[ ]{0,}=fftlib.o", "FCL += fftlib/fftlib.o", "makefile.include") - filter_file("^#CXX_FFTLIB", "CXX_FFTLIB", "makefile.include") - filter_file("^#INCS_FFTLIB", "INCS_FFTLIB", "makefile.include") - filter_file("^#LIBS", "LIBS", "makefile.include") - filter_file( - "LIBS[ ]{0,}=.*$", "LIBS=-lstdc++ fftlib/fftlib.o -ldl", "makefile.include" - ) - if "+vaspsol" in spec: - copy("VASPsol/src/solvation.F", "src/") - - def setup_build_environment(self, spack_env): - spec = self.spec - cpp_options = [ - "-DMPI -DMPI_BLOCK=8000", + "-DMPI", + "-DMPI_BLOCK=8000", "-Duse_collective", "-DCACHE_SIZE=4000", "-Davoidalloc", "-Duse_bse_te", "-Dtbdyn", + "-Dfock_dblbuf", ] + objects_lib = ["linpack_double.o"] + llibs = list(self.compiler.stdcxx_libs) + cflags = ["-fPIC", "-DAAD_"] + fflags = ["-w"] + incs = [spec["fftw-api"].headers.include_flags] - if "+shmem" in spec: - cpp_options.append("-Duse_shmem") + if self.spec.satisfies("@6:"): + cpp_options.append("-Dvasp6") + + llibs.extend([spec["blas"].libs.ld_flags, spec["lapack"].libs.ld_flags]) + + fc = [spec["mpi"].mpifc] + fcl = [spec["mpi"].mpifc] + + include_prefix = "" + omp_flag = "-fopenmp" - if "%nvhpc" in self.spec: - cpp_options.extend(['-DHOST=\\"LinuxPGI\\"', "-DPGI16", "-Dqd_emulate"]) - elif "%aocc" in self.spec: - cpp_options.extend( - [ - '-DHOST=\\"LinuxAMD\\"', - "-Dfock_dblbuf", - "-Dsysv", - "-Dshmem_bcast_buffer", - "-DNGZhalf", - ] + if spec.satisfies("+shmem"): + cpp_options.append("-Duse_shmem") + objects_lib.append("getshmem.o") + + if spec.satisfies("@:6.2"): + include_prefix = "linux_" + include_string = f"makefile.include.{include_prefix}" + + # gcc + if spec.satisfies("%gcc"): + include_string += "gnu" + if spec.satisfies("+openmp"): + include_string += "_omp" + make_include = join_path("arch", include_string) + # nvhpc + elif spec.satisfies("%nvhpc"): + qd_root = join_path( + spec["nvhpc"].prefix, + f"Linux_{spec['nvhpc'].target.family.name}", + str(spec["nvhpc"].version.dotted), + "compilers", + "extras", + "qd", ) - if "@6.3.0:" and "^amdfftw@4.0:" in self.spec: + nvroot = join_path(spec["nvhpc"].prefix, f"Linux_{spec['nvhpc'].target.family.name}") + if spec.satisfies("@6.3:"): + cpp_options.extend(['-DHOST=\\"LinuxNV\\"', "-Dqd_emulate"]) + else: + cpp_options.extend(['-DHOST=\\"LinuxPGI\\"', "-DPGI16", "-Dqd_emulate", "-Mfree"]) + + fflags.extend(["-Mnoupcase", "-Mbackslash", "-Mlarge_arrays"]) + incs.append(f"-I{join_path(qd_root, 'include', 'qd')}") + llibs.extend([f"-L{join_path(qd_root, 'lib')}", "-lqdmod", "-lqd"]) + + if spec.satisfies("@:6.2"): + make_include = join_path("arch", f"{include_string}pgi") + filter_file("pgcc", spack_cc, make_include) + filter_file("pgc++", spack_cxx, make_include, string=True) + filter_file("pgfortran", spack_fc, make_include) + else: + include_string += "nvhpc" + if spec.satisfies("+openmp"): + include_string += "_omp" + if spec.satisfies("+cuda"): + include_string += "_acc" + make_include = join_path("arch", include_string) + omp_flag = "-mp" + filter_file(r"^QD[ \t]*\??=.*$", f"QD = {qd_root}", make_include) + filter_file("NVROOT[ \t]*=.*$", f"NVROOT = {nvroot}", make_include) + # aocc + elif spec.satisfies("%aocc"): + cpp_options.extend(['-DHOST=\\"LinuxAMD\\"', "-Dshmem_bcast_buffer", "-DNGZhalf"]) + fflags.extend(["-fno-fortran-main", "-Mbackslash", "-ffunc-args-alias"]) + if spec.satisfies("@6.3.0: ^amdfftw@4.0:"): cpp_options.extend(["-Dfftw_cache_plans", "-Duse_fftw_plan_effort"]) - if "+openmp" in self.spec: - cpp_options.extend(["-D_OPENMP"]) - cpp_options.extend(["-Mfree "]) + if spec.satisfies("+openmp"): + if spec.satisfies("@6.3.2:"): + include_string += "aocc_ompi_aocl_omp" + elif spec.satisfies("@=6.3.0"): + include_string += "gnu_ompi_aocl_omp" + else: + include_string += "gnu_omp" + else: + if spec.satisfies("@6.3.2:"): + include_string += "aocc_ompi_aocl" + elif spec.satisfies("@=6.3.0"): + include_string += "gnu_ompi_aocl" + else: + include_string += "gnu" + make_include = join_path("arch", include_string) + filter_file("^CC_LIB[ ]{0,}=.*$", f"CC_LIB={spack_cc}", make_include) + if spec.satisfies("@6:6.3.0"): + filter_file("gcc", f"{spack_fc} -Mfree", make_include, string=True) + filter_file( + "-fallow-argument-mismatch", " -fno-fortran-main", make_include, string=True + ) + # fj + elif spec.satisfies("@6.4.3: %fj target=a64fx"): + include_string += "fujitsu_a64fx" + omp_flag = "-Kopenmp" + fc.extend(["simd_nouse_multiple_structures", "-X03"]) + fcl.append("simd_nouse_multiple_structures") + cpp_options.append('-DHOST=\\"FJ-A64FX\\"') + fflags.append("-Koptmsg=2") + llibs.extend(["-SSL2BLAMP", "-SCALAPACK"]) + if spec.satisfies("+openmp"): + include_string += "_omp" + make_include = join_path("arch", include_string) + else: + if spec.satisfies("+openmp"): + make_include = join_path("arch", f"{include_string}{spec.compiler.name}_omp") + # if the above doesn't work, fallback to gnu + if not os.path.exists(make_include): + make_include = join_path("arch", f"{include_string}.gnu_omp") + else: + make_include = join_path( + "arch", f"{include_string}{include_prefix}" + spec.compiler.name + ) + if not os.path.exists(make_include): + make_include = join_path("arch", f"{include_string}.gnu") cpp_options.append('-DHOST=\\"LinuxGNU\\"') - if self.spec.satisfies("@6:"): - cpp_options.append("-Dvasp6") - - cflags = ["-fPIC", "-DADD_"] - fflags = [] - if "%gcc" in spec or "%intel" in spec: - fflags.append("-w") - elif "%nvhpc" in spec: - fflags.extend(["-Mnoupcase", "-Mbackslash", "-Mlarge_arrays"]) - elif "%aocc" in spec: - fflags.extend(["-fno-fortran-main", "-Mbackslash"]) - objects_lib = ["linpack_double.o", "getshmem.o"] - spack_env.set("OBJECTS_LIB", " ".join(objects_lib)) - - spack_env.set("BLAS", spec["blas"].libs.ld_flags) - spack_env.set("LAPACK", spec["lapack"].libs.ld_flags) - if "^amdfftw" in spec: - spack_env.set("AMDFFTW_ROOT", spec["fftw-api"].prefix) + if spec.satisfies("+openmp"): + cpp_options.extend(["-Dsysv", "-D_OPENMP"]) + llibs.extend(["-ldl", spec["fftw-api:openmp"].libs.ld_flags]) + fc.append(omp_flag) + fcl.append(omp_flag) else: - spack_env.set("FFTW", spec["fftw-api"].libs.ld_flags) - spack_env.set("MPI_INC", spec["mpi"].prefix.include) - - if "%nvhpc" in spec: - spack_env.set("QD", spec["qd"].prefix) + llibs.append(spec["fftw-api"].libs.ld_flags) - if "+scalapack" in spec: + if spec.satisfies("^scalapack"): cpp_options.append("-DscaLAPACK") - spack_env.set("SCALAPACK", spec["scalapack"].libs.ld_flags) - - if "+cuda" in spec: - cpp_gpu = [ - "-DCUDA_GPU", - "-DRPROMU_CPROJ_OVERLAP", - "-DCUFFT_MIN=28", - "-DUSE_PINNED_MEMORY", - ] - - objects_gpu = [ - "fftmpiw.o", - "fftmpi_map.o", - "fft3dlib.o", - "fftw3d_gpu.o", - "fftmpiw_gpu.o", - ] - - cflags.extend(["-DGPUSHMEM=300", "-DHAVE_CUBLAS"]) - - spack_env.set("CUDA_ROOT", spec["cuda"].prefix) - spack_env.set("CPP_GPU", " ".join(cpp_gpu)) - spack_env.set("OBJECTS_GPU", " ".join(objects_gpu)) - - if "+vaspsol" in spec: + if spec.satisfies("%nvhpc"): + llibs.append("-Mscalapack") + else: + llibs.append(spec["scalapack"].libs.ld_flags) + + if spec.satisfies("+cuda"): + if spec.satisfies("@6.3:"): + # openacc + cpp_options.extend(["-D_OPENACC", "-DUSENCCL"]) + llibs.extend(["-cudalib=cublas,cusolver,cufft,nccl", "-cuda"]) + fc.append("-acc") + fcl.append("-acc") + cuda_flags = [f"cuda{str(spec['cuda'].version.dotted[0:2])}", "rdc"] + for f in spec.variants["cuda_arch"].value: + cuda_flags.append(f"cc{f}") + fc.append(f"-gpu={','.join(cuda_flags)}") + fcl.append(f"-gpu={','.join(cuda_flags)}") + fcl.extend(list(self.compiler.stdcxx_libs)) + cc = [spec["mpi"].mpicc, "-acc"] + if spec.satisfies("+openmp"): + cc.append(omp_flag) + filter_file("^CC[ \t]*=.*$", f"CC = {' '.join(cc)}", make_include) + + else: + # old cuda thing + cflags.extend(["-DGPUSHMEM=300", "-DHAVE_CUBLAS"]) + filter_file(r"^CUDA_ROOT[ \t]*\?=.*$", spec["cuda"].prefix, make_include) + + if spec.satisfies("+vaspsol"): cpp_options.append("-Dsol_compat") + copy("VASPsol/src/solvation.F", "src/") + + if spec.satisfies("+hdf5"): + cpp_options.append("-DVASP_HDF5") + llibs.append(spec["hdf5:fortran"].libs.ld_flags) + incs.append(spec["hdf5"].headers.include_flags) if spec.satisfies("%gcc@10:"): fflags.append("-fallow-argument-mismatch") - if spec.satisfies("%aocc"): - fflags.append("-fno-fortran-main -Mbackslash -ffunc-args-alias") - # Finally - spack_env.set("CPP_OPTIONS", " ".join(cpp_options)) - spack_env.set("CFLAGS", " ".join(cflags)) - spack_env.set("FFLAGS", " ".join(fflags)) + filter_file(r"^VASP_TARGET_CPU[ ]{0,}\?=.*", "", make_include) + + if spec.satisfies("@:5"): + filter_file("-DscaLAPACK.*$\n", "", make_include) + + if spec.satisfies("+fftlib"): + cxxftlib = ( + f"CXX_FFTLIB = {spack_cxx} {omp_flag}" + f" -DFFTLIB_THREADSAFE{' '.join(list(self.compiler.stdcxx_libs))}" + ) + filter_file("^#FCL[ ]{0,}=fftlib.o", "FCL += fftlib/fftlib.o", make_include) + filter_file("^#CXX_FFTLIB.*$", cxxftlib, make_include) + filter_file( + "^#INCS_FFTLIB.*$", + f"INCS_FFTLIB = -I./include {spec['fftw-api'].headers.include_flags}", + make_include, + ) + filter_file(r"#LIBS[ \t]*\+=.*$", "LIBS = fftlib", make_include) + llibs.append("-ldl") + fcl.append(join_path("fftlib", "fftlib.o")) + + # clean multiline CPP options at begining of file + filter_file(r"^[ \t]+(-D[a-zA-Z0-9_=]+[ ]*)+[ ]*\\*$", "", make_include) + # replace relevant variables in the makefile.include + filter_file("^FFLAGS[ \t]*=.*$", f"FFLAGS = {' '.join(fflags)}", make_include) + filter_file(r"^FFLAGS[ \t]*\+=.*$", "", make_include) + filter_file( + "^CPP_OPTIONS[ \t]*=.*$", f"CPP_OPTIONS = {' '.join(cpp_options)}", make_include + ) + filter_file(r"^INCS[ \t]*\+?=.*$", f"INCS = {' '.join(incs)}", make_include) + filter_file(r"^LLIBS[ \t]*\+?=.*$", f"LLIBS = {' '.join(llibs)}", make_include) + filter_file(r"^LLIBS[ \t]*\+=[ ]*-.*$", "", make_include) + filter_file("^CFLAGS[ \t]*=.*$", f"CFLAGS = {' '.join(cflags)}", make_include) + filter_file( + "^OBJECTS_LIB[ \t]*=.*$", f"OBJECTS_LIB = {' '.join(objects_lib)}", make_include + ) + filter_file("^FC[ \t]*=.*$", f"FC = {' '.join(fc)}", make_include) + filter_file("^FCL[ \t]*=.*$", f"FCL = {' '.join(fcl)}", make_include) + + os.rename(make_include, "makefile.include") + + def setup_build_environment(self, spack_env): + if self.spec.satisfies("%nvhpc +cuda"): + spack_env.set("NVHPC_CUDA_HOME", self.spec["cuda"].prefix) def build(self, spec, prefix): - if "+cuda" in self.spec: - make("gpu", "gpu_ncl") + if spec.satisfies("@:6.2"): + if spec.satisfies("+cuda"): + make("DEPS=1", "all") + else: + make("DEPS=1", "std", "gam", "ncl") else: - make("std", "gam", "ncl") + make("DEPS=1, all") def install(self, spec, prefix): install_tree("bin/", prefix.bin) diff --git a/var/spack/repos/builtin/packages/vbfnlo/package.py b/var/spack/repos/builtin/packages/vbfnlo/package.py index 69d9e2807da875..77648aef6148a0 100644 --- a/var/spack/repos/builtin/packages/vbfnlo/package.py +++ b/var/spack/repos/builtin/packages/vbfnlo/package.py @@ -38,6 +38,9 @@ class Vbfnlo(AutotoolsPackage): sha256="13e33d73d8a8ef64094621f87e6f94e01712e76cc19a86298d0b52cfcb9decca", preferred=True, ) + + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated # version('2.7.0', sha256='0e96c0912599e3000fffec5305700b947b604a7b06c7975851503f445311e4ef') # Documentation is broken on some systems: diff --git a/var/spack/repos/builtin/packages/vbz-compression/package.py b/var/spack/repos/builtin/packages/vbz-compression/package.py index 52712253b46618..feba17e46cef5f 100644 --- a/var/spack/repos/builtin/packages/vbz-compression/package.py +++ b/var/spack/repos/builtin/packages/vbz-compression/package.py @@ -30,6 +30,9 @@ class VbzCompression(CMakePackage): version("1.0.0", commit="2db0e3f62fa7a612dc42dc802401c26781eed068", submodules=True) version("0.9.3", commit="9a748efcdd0754be835e1080cf7086f3451e17d1", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.11:", type="build") depends_on("zstd@1.3.1:") depends_on("hdf5@1.8.16:") diff --git a/var/spack/repos/builtin/packages/vc/package.py b/var/spack/repos/builtin/packages/vc/package.py index a5d549c360ffc6..98c2276544b27e 100644 --- a/var/spack/repos/builtin/packages/vc/package.py +++ b/var/spack/repos/builtin/packages/vc/package.py @@ -13,8 +13,9 @@ class Vc(CMakePackage): git = "https://github.com/VcDevel/Vc.git" url = "https://github.com/VcDevel/Vc/archive/refs/tags/1.3.3.tar.gz" - license("BSD-3-Clause") + license("BSD-3-Clause", checked_by="wdconinc") + version("1.4.5", sha256="eb734ef4827933fcd67d4c74aef54211b841c350a867c681c73003eb6d511a48") version("1.4.4", sha256="5933108196be44c41613884cd56305df320263981fe6a49e648aebb3354d57f3") version("1.4.3", sha256="988ea0053f3fbf17544ca776a2749c097b3139089408b0286fa4e9e8513e037f") version("1.4.2", sha256="50d3f151e40b0718666935aa71d299d6370fafa67411f0a9e249fbce3e6e3952") @@ -24,6 +25,10 @@ class Vc(CMakePackage): version("1.2.0", sha256="9cd7b6363bf40a89e8b1d2b39044b44a4ce3f1fd6672ef3fc45004198ba28a2b") version("1.1.0", sha256="281b4c6152fbda11a4b313a0a0ca18565ee049a86f35f672f1383967fef8f501") + depends_on("cxx", type="build") # generated + + depends_on("cmake@3.5:", type="build", when="@1.4.5:") + @run_before("cmake") def fetch_additional_sources(self): """Starting from 1.4:, the test suite requires both the virtest framework diff --git a/var/spack/repos/builtin/packages/vcftools/package.py b/var/spack/repos/builtin/packages/vcftools/package.py index e533200232f59f..adb359bbb220e3 100644 --- a/var/spack/repos/builtin/packages/vcftools/package.py +++ b/var/spack/repos/builtin/packages/vcftools/package.py @@ -23,6 +23,9 @@ class Vcftools(AutotoolsPackage): # version('0.1.15', sha256='31e47afd5be679d89ece811a227525925b6907cce4af2c86f10f465e080383e3') version("0.1.14", sha256="76d799dd9afcb12f1ed42a07bc2886cd1a989858a4d047f24d91dcf40f608582") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("perl", type=("build", "run")) depends_on("zlib-api") depends_on("pkgconfig") diff --git a/var/spack/repos/builtin/packages/vdt/package.py b/var/spack/repos/builtin/packages/vdt/package.py index 0b5a2aafdf9e90..8e6afa6eee3adb 100644 --- a/var/spack/repos/builtin/packages/vdt/package.py +++ b/var/spack/repos/builtin/packages/vdt/package.py @@ -22,6 +22,9 @@ class Vdt(CMakePackage): version("0.3.7", sha256="713a7e6d76d98f3b2b56b5216e7d5906e30f17865a5c7c889968e9a0b0664949") version("0.3.6", sha256="fb8f6386f2cd1eeb03db43f2b5c83a172107949bb5e5e8d4dfa603660a9757b0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "preload", default=False, diff --git a/var/spack/repos/builtin/packages/veccore/package.py b/var/spack/repos/builtin/packages/veccore/package.py index f8a7ab885ebd24..38f714e2fa422f 100644 --- a/var/spack/repos/builtin/packages/veccore/package.py +++ b/var/spack/repos/builtin/packages/veccore/package.py @@ -34,6 +34,8 @@ class Veccore(CMakePackage): version("0.4.0", sha256="0a38b958c92647c30b5709d17edaf39d241b92b988f1040c0fbe24932b42927e") version("0.3.2", sha256="d72b03df00f5e94b2d07f78ab3af6d9d956c19e9a1fae07267b48f6fc8d7713f") + depends_on("cxx", type="build") + variant("vc", default=False, description="Enable Vc backend") depends_on("vc@1.2.0:", when="@0.2.0: +vc") diff --git a/var/spack/repos/builtin/packages/vecgeom/package.py b/var/spack/repos/builtin/packages/vecgeom/package.py index 48284544866fdb..34695cf6b431f1 100644 --- a/var/spack/repos/builtin/packages/vecgeom/package.py +++ b/var/spack/repos/builtin/packages/vecgeom/package.py @@ -21,6 +21,11 @@ class Vecgeom(CMakePackage, CudaPackage): maintainers("drbenmorgan", "sethrj") version("master", branch="master") + version( + "1.2.8", + url="https://gitlab.cern.ch/VecGeom/VecGeom/uploads/db11697eb81d6f369e9ded1078de946b/VecGeom-v1.2.8.tar.gz", + sha256="769f59e8377f8268e253a9b2a3eee86868a9ebc1fa66c968b96e19c31440c12b", + ) version( "1.2.7", url="https://gitlab.cern.ch/VecGeom/VecGeom/uploads/e4172cca4f6f731ef15e2780ecbb1645/VecGeom-v1.2.7.tar.gz", @@ -148,6 +153,8 @@ class Vecgeom(CMakePackage, CudaPackage): deprecated=True, ) + depends_on("cxx", type="build") + _cxxstd_values = (conditional("11", "14", when="@:1.1"), "17", conditional("20", when="@1.2:")) variant( "cxxstd", diff --git a/var/spack/repos/builtin/packages/veclibfort/package.py b/var/spack/repos/builtin/packages/veclibfort/package.py index 22d03f08735378..a6949f31130037 100644 --- a/var/spack/repos/builtin/packages/veclibfort/package.py +++ b/var/spack/repos/builtin/packages/veclibfort/package.py @@ -23,6 +23,9 @@ class Veclibfort(Package): version("0.4.3", sha256="fe9e7e0596bfb4aa713b2273b21e7d96c0d7a6453ee4b214a8a50050989d5586") version("0.4.2", sha256="c61316632bffa1c76e3c7f92b11c9def4b6f41973ecf9e124d68de6ae37fbc85") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Build shared libraries as well as static libs.") # virtual dependency diff --git a/var/spack/repos/builtin/packages/vecmem/package.py b/var/spack/repos/builtin/packages/vecmem/package.py index 30186fd24d977a..5eddb8b61a779d 100644 --- a/var/spack/repos/builtin/packages/vecmem/package.py +++ b/var/spack/repos/builtin/packages/vecmem/package.py @@ -13,10 +13,21 @@ class Vecmem(CMakePackage, CudaPackage): url = "https://github.com/acts-project/vecmem/archive/refs/tags/v0.5.0.tar.gz" list_url = "https://github.com/acts-project/vecmem/tags" - maintainers("wdconinc", "HadrienG2") + maintainers("wdconinc", "stephenswat") license("MPL-2.0-no-copyleft-exception") + version("1.6.0", sha256="797b016ac0b79bb39abad059ffa9f4817e519218429c9ab4c115f989616bd5d4") + version("1.5.0", sha256="5d7a2d2dd8eb961af12a1ed9e4e427b89881e843064ffa96ad0cf0934ba9b7ae") + version("1.4.0", sha256="545dfb4de4f9f3d773eef6a0e3297ebf981bb81950930d0991ad739e31ab16af") + version("1.3.1", sha256="09b108b0b48d564bbc1b9893ad9c3f7fa0b7914179f55be4c81f88a93e25f2e2") + version("1.3.0", sha256="53367db3084de56891ff885754c8fc2427d9ae69a351dd4d984558edf4162bad") + version("1.2.0", sha256="2cca8c1143803f209b58e49e9f2d58ebeeec4c815e7d99b0da9f61a319274aa9") + version("1.1.0", sha256="4d1f08a28268708819b68ed547eac912ec46e6707b059f0cc4aa7103a525164e") + version("1.0.0", sha256="59f478e036aed384eed1ecee1a99c5c52983534d3007d9f9203b7cb12c6ffa19") + version("0.27.0", sha256="f50a32214500767402930d4650243583769684c28fa29fe17f17f393a37ce0f2") + version("0.26.0", sha256="0e67acc197c4c1052288957c6419478c243aca718b64d383decd758d3c8f49ee") + version("0.25.0", sha256="90a87f00d45216cf4548fbcd6bb255dc15190873dc52936293a8c13f82e907f3") version("0.24.0", sha256="b395c013fba4e01f02939fefac14b357dbfd8e572b5c8f4ee5a1414adbd2ea93") version("0.22.0", sha256="b8811723bee60b0ea289d4c8b73363883e7c856859baf4cb6276b38816b0b258") version("0.21.0", sha256="97df3beb9a59b89b65c51ceb7e7c9b09172b3875b25f2d8fc070e4f9b061b631") @@ -41,21 +52,35 @@ class Vecmem(CMakePackage, CudaPackage): version("0.2.0", sha256="33aea135989684e325cb097e455ff0f9d1a9e85ff32f671e3b3ed6cc036176ac") version("0.1.0", sha256="19e24e3262aa113cd4242e7b94e2de34a4b362e78553730a358f64351c6a0a01") + depends_on("cxx", type="build") # generated + variant("hip", default=False, description="Build the vecmem::hip library") variant("sycl", default=False, description="Build the vecmem::sycl library") depends_on("cmake@3.17:", type="build") depends_on("hip", when="+hip") depends_on("sycl", when="+sycl") - depends_on("googletest", type="test") + + # FIXME: due to #29447, googletest is not available to cmake when building with --test, + # and we can choose between always depending on googletest, or using FetchContent + # depends_on("googletest", type="test") + + def setup_build_environment(self, env): + if self.spec.satisfies("+sycl"): + env.set("SYCLCXX", self.compiler.cxx) + if self.spec.satisfies("%oneapi"): + env.set("SYCLFLAGS", "-fsycl") def cmake_args(self): args = [ + self.define("FETCHCONTENT_FULLY_DISCONNECTED", False), # see FIXME above self.define_from_variant("VECMEM_BUILD_CUDA_LIBRARY", "cuda"), self.define_from_variant("VECMEM_BUILD_HIP_LIBRARY", "hip"), self.define_from_variant("VECMEM_BUILD_SYCL_LIBRARY", "sycl"), + self.define("BUILD_TESTING", self.run_tests), self.define("VECMEM_BUILD_TESTING", self.run_tests), - self.define("VECMEM_USE_SYSTEM_GOOGLETEST", True), + self.define("VECMEM_USE_SYSTEM_LIBS", True), + self.define("VECMEM_USE_SYSTEM_GOOGLETEST", False), # see FIXME above ] if "+cuda" in self.spec: diff --git a/var/spack/repos/builtin/packages/vectorclass-version2/package.py b/var/spack/repos/builtin/packages/vectorclass-version2/package.py index 784ece9330960f..dc9a83bc425efc 100644 --- a/var/spack/repos/builtin/packages/vectorclass-version2/package.py +++ b/var/spack/repos/builtin/packages/vectorclass-version2/package.py @@ -20,6 +20,8 @@ class VectorclassVersion2(Package): version("2.01.04", sha256="7885c343b1af9eb940f4debdd7cd19544130a06ed70e0000e1a8471fb9c15118") + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): # Put all cpp files to an include folder # (makes a filesystem view with this diff --git a/var/spack/repos/builtin/packages/veloc/package.py b/var/spack/repos/builtin/packages/veloc/package.py index 079d773d514667..9d42a6d8006883 100644 --- a/var/spack/repos/builtin/packages/veloc/package.py +++ b/var/spack/repos/builtin/packages/veloc/package.py @@ -29,10 +29,14 @@ class Veloc(CMakePackage): version("1.1", sha256="2bbdacf3e0ce4e7c9e360874d8d85b405525bdc7bd992bdb1f1ba49218072160") version("1.0", sha256="d594b73d6549a61fce8e67b8984a17cebc3e766fc520ed1636ae3683cdde77cb") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libpthread-stubs") depends_on("mpi") depends_on("boost") depends_on("er") + depends_on("er@0.4:", when="@1.7:") depends_on("axl@:0.3.0", when="@:1.5") depends_on("axl@0.5.0:", when="@1.6:") depends_on("openssl") diff --git a/var/spack/repos/builtin/packages/verible/package.py b/var/spack/repos/builtin/packages/verible/package.py index c1a68fcf511f4d..c993d69727edeb 100644 --- a/var/spack/repos/builtin/packages/verible/package.py +++ b/var/spack/repos/builtin/packages/verible/package.py @@ -34,6 +34,11 @@ class Verible(Package): version("master", branch="master") + version( + "0.0.3624", + sha256="e5995644e092e72c9d37c492f319b0d4861a3c63d03d1c3cfefe2363bcd6b74f", + url="https://github.com/chipsalliance/verible/archive/refs/tags/v0.0-3624-gd256d779.tar.gz", + ) version( "0.0.3607", sha256="5ea427ed843916f8c1b5d7263c1aaad526dc7181de5afcf84542bca4c4f8f1ca", @@ -60,6 +65,8 @@ class Verible(Package): url="https://github.com/chipsalliance/verible/archive/refs/tags/v0.0-3428-gcfcbb82b.tar.gz", ) + depends_on("cxx", type="build") # generated + maintainers("davekeeshan") depends_on("flex", type="build") diff --git a/var/spack/repos/builtin/packages/verilator/package.py b/var/spack/repos/builtin/packages/verilator/package.py index caf2f1ad2ba3e0..7500e252d93163 100644 --- a/var/spack/repos/builtin/packages/verilator/package.py +++ b/var/spack/repos/builtin/packages/verilator/package.py @@ -33,7 +33,7 @@ class Verilator(AutotoolsPackage): designs with thousands of modules.""" homepage = "https://www.veripool.org/projects/verilator" - url = "https://github.com/verilator/verilator/archive/refs/tags/v5.022.tar.gz" + url = "https://github.com/verilator/verilator/archive/refs/tags/v5.026.tar.gz" git = "https://github.com/verilator/verilator.git" maintainers("davekeeshan") @@ -42,6 +42,8 @@ class Verilator(AutotoolsPackage): version("master", branch="master") + version("5.026", sha256="87fdecf3967007d9ee8c30191ff2476f2a33635d0e0c6e3dbf345cc2f0c50b78") + version("5.024", sha256="88b04c953e7165c670d6a700f202cef99c746a0867b4e2efe1d7ea789dee35f3") version("5.022", sha256="3c2f5338f4b6ce7e2f47a142401acdd18cbf4c5da06092618d6d036c0afef12d") version("5.020", sha256="41ca9abfadf8d2413efbff7f8277379733d0095957fe7769dc38f8fd1bc899a6") version("5.018", sha256="8b544273eedee379e3c1a3bb849e14c754c9b5035d61ad03acdf3963092ba6c0") @@ -69,26 +71,31 @@ class Verilator(AutotoolsPackage): version("4.110", sha256="603c23944577a5d53a2e09191d04d5c61740a77b58f3a590a70e56f4526a5a0b") version("4.108", sha256="ce521dc57754e5a325ff7000c434ce23674c8e1de30e1f2a6506dc3a33bd7c55") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") depends_on("help2man", type="build") depends_on("bison", type="build") depends_on("flex") - depends_on("ccache", type=("build", "run"), when="@5.018:") depends_on("perl", type=("build", "run")) + depends_on("ccache", type=("build", "run"), when="@5.018:") conflicts("%gcc@:6", msg="C++14 support required") # we need to fix the CXX and LINK paths, as they point to the spack # wrapper scripts which aren't usable without spack filter_compiler_wrappers("verilated.mk", relative_root="include") + filter_compiler_wrappers("verilated.mk", relative_root="share/verilator/include") + @when("@:5.022") def setup_run_environment(self, env): env.prepend_path("VERILATOR_ROOT", self.prefix) def autoreconf(self, spec, prefix): - autoconf = which("autoconf") autoconf() # verilator requires access to its shipped scripts (bin) and include diff --git a/var/spack/repos/builtin/packages/verrou/package.py b/var/spack/repos/builtin/packages/verrou/package.py index dc0cba56c68d5f..a32b6a9299617c 100644 --- a/var/spack/repos/builtin/packages/verrou/package.py +++ b/var/spack/repos/builtin/packages/verrou/package.py @@ -25,14 +25,15 @@ class Verrou(AutotoolsPackage): url = "https://github.com/edf-hpc/verrou/archive/v2.0.0.tar.gz" git = "https://github.com/edf-hpc/verrou.git" - maintainers("HadrienG2") - license("GPL-2.0-only") version("develop", branch="master") version("2.2.0", sha256="d4ea3d19f0c61329723907b5b145d85776bb702643c1605a31f584484d2c5efc") version("2.1.0", sha256="b1ba49f84aebab15b8ab5649946c9c31b53ad1499f6ffb681c98db41ed28566d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # The server is sometimes a bit slow to respond timeout = {"timeout": 60} diff --git a/var/spack/repos/builtin/packages/vgm/package.py b/var/spack/repos/builtin/packages/vgm/package.py index 5ec8dd46eb636b..468e6272805080 100644 --- a/var/spack/repos/builtin/packages/vgm/package.py +++ b/var/spack/repos/builtin/packages/vgm/package.py @@ -33,6 +33,8 @@ class Vgm(CMakePackage): version("4-00", sha256="c24de76f919dca7c92b3c9fce7a39142c6e61fd39f691d2e4df15fe413b5190d") version("3-06", sha256="41948869f2e4dcfa31f4bad42b938c25dd174660c427feb2f9effa9af5e59c7d") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.8:", type="build") depends_on("clhep") depends_on("root") diff --git a/var/spack/repos/builtin/packages/viennarna/package.py b/var/spack/repos/builtin/packages/viennarna/package.py index c492c2ba1ef882..6c74d9b4f759ca 100644 --- a/var/spack/repos/builtin/packages/viennarna/package.py +++ b/var/spack/repos/builtin/packages/viennarna/package.py @@ -21,6 +21,10 @@ class Viennarna(AutotoolsPackage): version("2.4.3", sha256="4cda6e22029b34bb9f5375181562f69e4a780a89ead50fe952891835e9933ac0") version("2.3.5", sha256="26b62a00da21bc5597b580ab8fef4e624234ec446d7d3cb0ce22803a5d7074ca") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "sse", default=True, description="Enable SSE in order to substantially speed up execution" ) diff --git a/var/spack/repos/builtin/packages/viewres/package.py b/var/spack/repos/builtin/packages/viewres/package.py index 73ea05962684d4..66b4df553242fd 100644 --- a/var/spack/repos/builtin/packages/viewres/package.py +++ b/var/spack/repos/builtin/packages/viewres/package.py @@ -20,6 +20,8 @@ class Viewres(AutotoolsPackage, XorgPackage): version("1.0.5", sha256="9dee5e6b0a18961bb5c33f3f654605d45912087b6ba781cb2277d1941fa35a4b") version("1.0.4", sha256="fd2aaec85c952fd6984fe14d0fcbda4d2ab9849a9183e4787b0ef552a10a87a1") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/vigra/package.py b/var/spack/repos/builtin/packages/vigra/package.py index 6178b1b1a64a2f..54de86618bfd10 100644 --- a/var/spack/repos/builtin/packages/vigra/package.py +++ b/var/spack/repos/builtin/packages/vigra/package.py @@ -23,6 +23,9 @@ class Vigra(CMakePackage): version("master", branch="master") version("1.11.1", sha256="a5564e1083f6af6a885431c1ee718bad77d11f117198b277557f8558fa461aaf") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("png", default=False, description="Include support for PNG images") variant("jpeg", default=False, description="Include support for JPEG images") variant("tiff", default=False, description="Include support for TIFF images") diff --git a/var/spack/repos/builtin/packages/vim/package.py b/var/spack/repos/builtin/packages/vim/package.py index 583d12c8f914c7..c246f1c1cd766f 100644 --- a/var/spack/repos/builtin/packages/vim/package.py +++ b/var/spack/repos/builtin/packages/vim/package.py @@ -17,10 +17,12 @@ class Vim(AutotoolsPackage): homepage = "https://www.vim.org" url = "https://github.com/vim/vim/archive/v8.1.0338.tar.gz" + maintainers("sethrj") license("Vim") + version("9.1.0437", sha256="7024fbf8d0e8eec2eae21d279d487b60c58dc4ba3d42146388dc3743506d1fe6") version("9.0.0045", sha256="594a31e96e3eda07a358db305de939ca749693b4684de9e027bfa70311b1994d") version( "9.0.0000", @@ -39,6 +41,9 @@ class Vim(AutotoolsPackage): version("8.0.0134", sha256="1b3e3e7d187eed55cbdb0a1dae6b8f3b885005fbae84222420877d7afa3b2310") version("7.4.2367", sha256="a9ae4031ccd73cc60e771e8bf9b3c8b7f10f63a67efce7f61cd694cd8d7cda5c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + _features = ("huge", "big", "normal", "small", "tiny") variant("cscope", default=False, description="build with cscope support") diff --git a/var/spack/repos/builtin/packages/virtualgl/package.py b/var/spack/repos/builtin/packages/virtualgl/package.py index d7f9330e60ccae..72e8a574a434e6 100644 --- a/var/spack/repos/builtin/packages/virtualgl/package.py +++ b/var/spack/repos/builtin/packages/virtualgl/package.py @@ -19,6 +19,9 @@ class Virtualgl(CMakePackage): version("2.5.2", sha256="4f43387678b289a24139c5b7c3699740ca555a9f10011c979e51aa4df2b93238") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # This package will only work with libjpeg-turbo, not other jpeg providers depends_on("libjpeg-turbo") depends_on("glu") diff --git a/var/spack/repos/builtin/packages/virtuoso/package.py b/var/spack/repos/builtin/packages/virtuoso/package.py index 806ca826717e7c..18b36fc3c2f390 100644 --- a/var/spack/repos/builtin/packages/virtuoso/package.py +++ b/var/spack/repos/builtin/packages/virtuoso/package.py @@ -17,6 +17,9 @@ class Virtuoso(AutotoolsPackage): version("7.2.5.1-dev", commit="3ff1d4b3de3977337baf909c264968b9f70b7d2c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("dbpedia-vad", default=False, description="DBpedia vad package") variant("demo-vad", default=False, description="Demo vad package") variant("fct-vad", default=True, description="Facet Browser vad package") diff --git a/var/spack/repos/builtin/packages/visit-cgns/package.py b/var/spack/repos/builtin/packages/visit-cgns/package.py index c85b86bc998f2a..ef611aa0492be3 100644 --- a/var/spack/repos/builtin/packages/visit-cgns/package.py +++ b/var/spack/repos/builtin/packages/visit-cgns/package.py @@ -39,6 +39,10 @@ class VisitCgns(CMakePackage): version("2.10.2", sha256="89ecdfaf197ef431685e31b75628774deb6cd75d3e332ef26505774403e8beff") version("2.10.1", sha256="6b53dea89a241fd03300a7a3a50c0f773e2fb8458cd3ad06816e9bd2f0337cd8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake", type="build") depends_on("cgns@3.3.1+int64~scoping~legacy", when="@2.10.1:3.1.4") depends_on("cgns+int64~scoping~legacy") diff --git a/var/spack/repos/builtin/packages/visit-ffp/package.py b/var/spack/repos/builtin/packages/visit-ffp/package.py index c12fe75ee1a3b2..6766495fd0eda0 100644 --- a/var/spack/repos/builtin/packages/visit-ffp/package.py +++ b/var/spack/repos/builtin/packages/visit-ffp/package.py @@ -32,6 +32,10 @@ class VisitFfp(CMakePackage): version("3.1.1", sha256="0b60ac52fd00aff3cf212a310e36e32e13ae3ca0ddd1ea3f54f75e4d9b6c6cf0") version("3.0.1", sha256="a506d4d83b8973829e68787d8d721199523ce7ec73e7594e93333c214c2c12bd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("stripack", default=True, description="Enable STRIPACK unit sphere Delaunay meshing") depends_on("cmake", type="build") diff --git a/var/spack/repos/builtin/packages/visit-mfem/package.py b/var/spack/repos/builtin/packages/visit-mfem/package.py index 76c3abf5f23159..9fb677fc889e99 100644 --- a/var/spack/repos/builtin/packages/visit-mfem/package.py +++ b/var/spack/repos/builtin/packages/visit-mfem/package.py @@ -39,6 +39,10 @@ class VisitMfem(CMakePackage): version("2.10.2", sha256="89ecdfaf197ef431685e31b75628774deb6cd75d3e332ef26505774403e8beff") version("2.10.1", sha256="6b53dea89a241fd03300a7a3a50c0f773e2fb8458cd3ad06816e9bd2f0337cd8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake", type="build") depends_on("mfem") depends_on("visit") diff --git a/var/spack/repos/builtin/packages/visit-silo/package.py b/var/spack/repos/builtin/packages/visit-silo/package.py index d31402e3f93651..3dc7a4bbc650e3 100644 --- a/var/spack/repos/builtin/packages/visit-silo/package.py +++ b/var/spack/repos/builtin/packages/visit-silo/package.py @@ -44,6 +44,10 @@ class VisitSilo(CMakePackage): version("2.10.2", sha256="89ecdfaf197ef431685e31b75628774deb6cd75d3e332ef26505774403e8beff") version("2.10.1", sha256="6b53dea89a241fd03300a7a3a50c0f773e2fb8458cd3ad06816e9bd2f0337cd8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake", type="build") depends_on("silo") depends_on("visit") diff --git a/var/spack/repos/builtin/packages/visit-unv/package.py b/var/spack/repos/builtin/packages/visit-unv/package.py index d7cbbf4ad2a0cc..768ac3f66e8d20 100644 --- a/var/spack/repos/builtin/packages/visit-unv/package.py +++ b/var/spack/repos/builtin/packages/visit-unv/package.py @@ -37,6 +37,10 @@ class VisitUnv(CMakePackage): version("2.10.2", sha256="89ecdfaf197ef431685e31b75628774deb6cd75d3e332ef26505774403e8beff") version("2.10.1", sha256="6b53dea89a241fd03300a7a3a50c0f773e2fb8458cd3ad06816e9bd2f0337cd8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake", type="build") depends_on("visit") diff --git a/var/spack/repos/builtin/packages/visit/package.py b/var/spack/repos/builtin/packages/visit/package.py index 3f806196fd27f5..ab24314e357bf1 100644 --- a/var/spack/repos/builtin/packages/visit/package.py +++ b/var/spack/repos/builtin/packages/visit/package.py @@ -71,11 +71,14 @@ class Visit(CMakePackage): version("3.1.1", sha256="0b60ac52fd00aff3cf212a310e36e32e13ae3ca0ddd1ea3f54f75e4d9b6c6cf0") version("3.0.1", sha256="a506d4d83b8973829e68787d8d721199523ce7ec73e7594e93333c214c2c12bd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + root_cmakelists_dir = "src" generator("ninja") variant("gui", default=True, description="Enable VisIt's GUI") - variant("osmesa", default=False, description="Use OSMesa for off-screen CPU rendering") variant("adios2", default=True, description="Enable ADIOS2 file format") variant("hdf5", default=True, description="Enable HDF5 file format") variant("netcdf", default=True, description="Enable NetCDF file format") @@ -105,16 +108,15 @@ class Visit(CMakePackage): # Fix const-correctness in VTK interface patch("vtk-8.2-constcorrect.patch", when="@3.3.3 ^vtk@8.2.1a") - # Exactly one of 'gui' or 'osmesa' has to be enabled - conflicts("+gui", when="+osmesa") + conflicts( + "+gui", when="^[virtuals=gl] osmesa", msg="GUI cannot be activated with OSMesa front-end" + ) depends_on("cmake@3.14.7:", type="build") - depends_on("mpi", when="+mpi") # VTK flavors depends_on("vtk@8.1:8 +opengl2") - depends_on("vtk +osmesa", when="+osmesa") depends_on("vtk +qt", when="+gui") depends_on("vtk +python", when="+python") depends_on("vtk +mpi", when="+mpi") @@ -125,11 +127,12 @@ class Visit(CMakePackage): depends_on( "vtk", patches=[patch("vtk_rendering_opengl2_x11.patch")], - when="~osmesa platform=linux ^vtk@8", + when="platform=linux ^[virtuals=gl] glx ^vtk@8", ) depends_on("vtk", patches=[patch("vtk_wrapping_python_x11.patch")], when="+python ^vtk@8") depends_on("glu") + depends_on("gl") # VisIt doesn't work with later versions of qt. depends_on("qt+gui+opengl@5:5.14", when="+gui") @@ -291,10 +294,11 @@ def cmake_args(self): self.define("VISIT_OSMESA_DIR", "IGNORE"), self.define("OpenGL_GL_PREFERENCE", "LEGACY"), self.define("OPENGL_INCLUDE_DIR", spec["gl"].headers.directories[0]), + self.define("OPENGL_gl_LIBRARY", spec["gl"].libs[0]), self.define("OPENGL_glu_LIBRARY", spec["glu"].libs[0]), ] ) - if "+osmesa" in spec: + if spec.satisfies("^[virtuals=gl] osmesa"): args.extend( [ self.define("HAVE_OSMESA", True), @@ -302,8 +306,6 @@ def cmake_args(self): self.define("OPENGL_gl_LIBRARY", spec["osmesa"].libs[0]), ] ) - else: - args.append(self.define("OPENGL_gl_LIBRARY", spec["gl"].libs[0])) if "+hdf5" in spec: args.append(self.define("HDF5_DIR", spec["hdf5"].prefix)) diff --git a/var/spack/repos/builtin/packages/vite/package.py b/var/spack/repos/builtin/packages/vite/package.py index bf45ae8e66b135..3f760fd70dbe57 100644 --- a/var/spack/repos/builtin/packages/vite/package.py +++ b/var/spack/repos/builtin/packages/vite/package.py @@ -20,6 +20,9 @@ class Vite(CMakePackage): version("master", branch="master") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build") depends_on("qt+opengl") depends_on("glm") diff --git a/var/spack/repos/builtin/packages/vmatch/package.py b/var/spack/repos/builtin/packages/vmatch/package.py index e5778416c0d073..f533443886fc2f 100644 --- a/var/spack/repos/builtin/packages/vmatch/package.py +++ b/var/spack/repos/builtin/packages/vmatch/package.py @@ -15,5 +15,7 @@ class Vmatch(Package): version("2.3.0", sha256="5e18d0dddf04e86dad193fcdde6e48f3901365932634125602d8808f35acf979") + depends_on("c", type="build") # generated + def install(self, spec, prefix): install_tree(self.stage.source_path, prefix.bin) diff --git a/var/spack/repos/builtin/packages/vmc/package.py b/var/spack/repos/builtin/packages/vmc/package.py index 683f58c350af51..b7b04b7a89486f 100644 --- a/var/spack/repos/builtin/packages/vmc/package.py +++ b/var/spack/repos/builtin/packages/vmc/package.py @@ -23,6 +23,8 @@ class Vmc(CMakePackage): version("1-0-p2", sha256="46b4c82b0b7516502e88db920732fc78f06f0393ac740a17816f2eb53f80e75e") version("1-0-p1", sha256="4a20515f7de426797955cec4a271958b07afbaa330770eeefb5805c882ad9749") + depends_on("cxx", type="build") # generated + patch("dict_fixes_101.patch", when="@1-0-p1") depends_on("root@6.18.04: ~vmc") diff --git a/var/spack/repos/builtin/packages/vmd/package.py b/var/spack/repos/builtin/packages/vmd/package.py index f4986e0c6d4ff4..15b58af21b07d0 100644 --- a/var/spack/repos/builtin/packages/vmd/package.py +++ b/var/spack/repos/builtin/packages/vmd/package.py @@ -24,7 +24,7 @@ class Vmd(Package): homepage = "https://www.ks.uiuc.edu/Research/vmd/" version( "1.9.3", - sha256="145b4d0cc10b56cadeb71e16c54ab8be713e268f11491714cd617422758ec643", + sha256="9427a7acb1c7809525f70f635bceeb7eff8e7574e7e3565d6f71f3d6ce405a71", url="file://{0}/vmd-1.9.3.bin.LINUXAMD64-CUDA8-OptiX4-OSPRay111p1.opengl.tar.gz".format( os.getcwd() ), diff --git a/var/spack/repos/builtin/packages/volk/package.py b/var/spack/repos/builtin/packages/volk/package.py index 601c5190c301d3..79c02bbb0c6316 100644 --- a/var/spack/repos/builtin/packages/volk/package.py +++ b/var/spack/repos/builtin/packages/volk/package.py @@ -31,5 +31,8 @@ class Volk(CMakePackage): version("2.3.0", sha256="f42c928f561b128acfe4adb21227e4a62a3f6ab8103592fc3233765ff326d5fc") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3.4:", type=("build", "run")) depends_on("py-mako@0.4.2:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/voropp/package.py b/var/spack/repos/builtin/packages/voropp/package.py index 5a07ef7130673a..641e2c5ec47d9a 100644 --- a/var/spack/repos/builtin/packages/voropp/package.py +++ b/var/spack/repos/builtin/packages/voropp/package.py @@ -20,6 +20,8 @@ class Voropp(MakefilePackage): version("0.4.6", sha256="ef7970071ee2ce3800daa8723649ca069dc4c71cc25f0f7d22552387f3ea437e") + depends_on("cxx", type="build") # generated + def edit(self, spec, prefix): filter_file(r"CC=g\+\+", "CC={0}".format(self.compiler.cxx), "config.mk") filter_file(r"PREFIX=/usr/local", "PREFIX={0}".format(self.prefix), "config.mk") diff --git a/var/spack/repos/builtin/packages/votca-csg/package.py b/var/spack/repos/builtin/packages/votca-csg/package.py index 04ad3d39e51750..2be5343d725df2 100644 --- a/var/spack/repos/builtin/packages/votca-csg/package.py +++ b/var/spack/repos/builtin/packages/votca-csg/package.py @@ -83,6 +83,8 @@ class VotcaCsg(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8:", type="build") for v in [ "1.4", diff --git a/var/spack/repos/builtin/packages/votca-csgapps/package.py b/var/spack/repos/builtin/packages/votca-csgapps/package.py index 2654417761a2cd..16f9358e0a8093 100644 --- a/var/spack/repos/builtin/packages/votca-csgapps/package.py +++ b/var/spack/repos/builtin/packages/votca-csgapps/package.py @@ -67,6 +67,8 @@ class VotcaCsgapps(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + for v in ["1.4", "1.4.1", "1.5", "1.5.1", "1.6", "1.6.1", "1.6.2", "1.6.3", "1.6.4"]: depends_on("votca-csg@%s" % v, when="@%s:%s.0" % (v, v)) depends_on("boost+exception+math+serialization+container") diff --git a/var/spack/repos/builtin/packages/votca-ctp/package.py b/var/spack/repos/builtin/packages/votca-ctp/package.py index e1846fe900ff7e..a56fbe0622a963 100644 --- a/var/spack/repos/builtin/packages/votca-ctp/package.py +++ b/var/spack/repos/builtin/packages/votca-ctp/package.py @@ -31,6 +31,9 @@ class VotcaCtp(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("cmake@2.8:", type="build") depends_on("votca-tools@1.5.1") depends_on("votca-csg@1.5.1") diff --git a/var/spack/repos/builtin/packages/votca-tools/package.py b/var/spack/repos/builtin/packages/votca-tools/package.py index bb47d42a67c345..990a5f683909d7 100644 --- a/var/spack/repos/builtin/packages/votca-tools/package.py +++ b/var/spack/repos/builtin/packages/votca-tools/package.py @@ -83,6 +83,8 @@ class VotcaTools(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + # https://github.com/votca/tools/pull/229, fix mkl in exported target patch( "https://github.com/votca/tools/pull/229.patch?full_index=1", diff --git a/var/spack/repos/builtin/packages/votca-xtp/package.py b/var/spack/repos/builtin/packages/votca-xtp/package.py index 5276740f710e2d..3156ab4f121982 100644 --- a/var/spack/repos/builtin/packages/votca-xtp/package.py +++ b/var/spack/repos/builtin/packages/votca-xtp/package.py @@ -78,6 +78,8 @@ class VotcaXtp(CMakePackage): deprecated=True, ) + depends_on("cxx", type="build") # generated + depends_on("cmake@2.8:", type="build") for v in [ "1.4.1", diff --git a/var/spack/repos/builtin/packages/votca/package.py b/var/spack/repos/builtin/packages/votca/package.py index e0edcfefc954c9..c6788fbc60fea2 100644 --- a/var/spack/repos/builtin/packages/votca/package.py +++ b/var/spack/repos/builtin/packages/votca/package.py @@ -20,11 +20,14 @@ class Votca(CMakePackage): maintainers("junghans") version("master", branch="master") + version("2024.1", sha256="68669a7d09020f780d2633eb865c6c53e5fb38d155f80c9670ebf9d10d10bee6") version("2024", sha256="7f342e857f4a6ba6d25937f63830afa3c32cbd906255c8d78aa6c500cfd418c8") version("2023", sha256="6150a38c77379d05592a56ae4392a00c4636d02198bb06108a3dc739a45115f8") version("2022.1", sha256="358119b2645fe60f88ca621aed508c49fb61f88d29d3e3fa24b5b831ed4a66ec") version("2022", sha256="7991137098ff4511f4ca2c6f1b6c45f53d92d9f84e5c0d0e32fbc31768f73a83") + depends_on("cxx", type="build") # generated + variant("mkl", default=False, description="Build with MKL support") variant( "new-gmx", default=False, description="Build against gromacs>2019 - no tabulated kernels" @@ -39,7 +42,10 @@ class Votca(CMakePackage): depends_on("expat") depends_on("fftw-api@3") depends_on("eigen@3.3:") - depends_on("boost") + depends_on("boost+filesystem+system+regex+timer") + depends_on("boost@1.71:") + depends_on("boost@1.71:1.84", when="@=2024") + depends_on("boost@1.71:1.82", when="@:2023") depends_on("mkl", when="+mkl") depends_on("hdf5+cxx~mpi") depends_on("gromacs~mpi@5.1:") diff --git a/var/spack/repos/builtin/packages/vpfft/package.py b/var/spack/repos/builtin/packages/vpfft/package.py index e2b09e2dc24e05..31f3830d30a13f 100644 --- a/var/spack/repos/builtin/packages/vpfft/package.py +++ b/var/spack/repos/builtin/packages/vpfft/package.py @@ -24,6 +24,8 @@ class Vpfft(MakefilePackage): version("develop") + depends_on("cxx", type="build") # generated + depends_on("eigen") depends_on("fftw") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/vpic/package.py b/var/spack/repos/builtin/packages/vpic/package.py index c51eaf3cb2fea6..7cfd778434a9ee 100644 --- a/var/spack/repos/builtin/packages/vpic/package.py +++ b/var/spack/repos/builtin/packages/vpic/package.py @@ -24,6 +24,9 @@ class Vpic(CMakePackage): version("develop", branch="master", submodules=True) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build") depends_on("mpi") diff --git a/var/spack/repos/builtin/packages/vsearch/package.py b/var/spack/repos/builtin/packages/vsearch/package.py index 29c9f563d47033..81b0613da13979 100644 --- a/var/spack/repos/builtin/packages/vsearch/package.py +++ b/var/spack/repos/builtin/packages/vsearch/package.py @@ -20,6 +20,9 @@ class Vsearch(AutotoolsPackage): version("2.13.3", sha256="e5f34ece28b76403d3ba4a673eca41178fe399c35a1023dbc87d0c0da5efaa52") version("2.4.3", sha256="f7ffc2aec5d76bdaf1ffe7fb733102138214cec3e3846eb225455dcc3c088141") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("m4", type="build") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/vsftpd/package.py b/var/spack/repos/builtin/packages/vsftpd/package.py index 33d197d039038a..a10eb6d31949ee 100644 --- a/var/spack/repos/builtin/packages/vsftpd/package.py +++ b/var/spack/repos/builtin/packages/vsftpd/package.py @@ -19,6 +19,8 @@ class Vsftpd(MakefilePackage): version("3.0.2", sha256="be46f0e2c5528fe021fafc8dab1ecfea0c1f183063a06977f8537fcd0b195e56") version("3.0.1", sha256="65487a9fccc0ae566df5999a84448a9ccb57b556b7643ffd345540299487784c") + depends_on("c", type="build") # generated + depends_on("libcap") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/vt/package.py b/var/spack/repos/builtin/packages/vt/package.py index 9a4d34449c6608..5bd8e126ccf36d 100644 --- a/var/spack/repos/builtin/packages/vt/package.py +++ b/var/spack/repos/builtin/packages/vt/package.py @@ -12,9 +12,13 @@ class Vt(MakefilePackage): homepage = "https://genome.sph.umich.edu/wiki/vt" url = "https://github.com/atks/vt/archive/0.577.tar.gz" + version("0.57721", sha256="8f06d464ec5458539cfa30f81a034f47fe7f801146fe8ca80c14a3816b704e17") version("0.5772", sha256="b147520478a2f7c536524511e48133d0360e88282c7159821813738ccbda97e7") version("0.577", sha256="009e2592e787ab37e471b4e8a66520141bb2791ca78142ca1767d27036f460d0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") def install(self, spec, spack): diff --git a/var/spack/repos/builtin/packages/vtable-dumper/package.py b/var/spack/repos/builtin/packages/vtable-dumper/package.py index 7be75560d0400d..75bff498fe9f7b 100644 --- a/var/spack/repos/builtin/packages/vtable-dumper/package.py +++ b/var/spack/repos/builtin/packages/vtable-dumper/package.py @@ -18,6 +18,8 @@ class VtableDumper(MakefilePackage): version("1.1", sha256="f0a57a7b82a0a56845cea9ab56ad449e63f5f01c6a0c9f1467efa4ef60dd4a93") version("1.0", sha256="a222de5a19bf716ab2f35148f43bbf8a052772b54ff622c6387a4ba2440fb9a0") + depends_on("c", type="build") # generated + depends_on("libelf") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/vtk-h/package.py b/var/spack/repos/builtin/packages/vtk-h/package.py index 9a159e4e0bdd1c..011e479ff16e13 100644 --- a/var/spack/repos/builtin/packages/vtk-h/package.py +++ b/var/spack/repos/builtin/packages/vtk-h/package.py @@ -60,6 +60,9 @@ class VtkH(CMakePackage, CudaPackage): version("0.5.3", sha256="0c4aae3bd2a5906738a6806de2b62ea2049ac8b40ebe7fc2ba25505272c2d359") version("0.5.2", sha256="db2e6250c0ece6381fc90540317ad7b5869dbcce0231ce9be125916a77bfdb25") + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Build vtk-h as shared libs") variant("mpi", default=True, description="build mpi support") # set to false for systems that implicitly link mpi diff --git a/var/spack/repos/builtin/packages/vtk-m/package.py b/var/spack/repos/builtin/packages/vtk-m/package.py index 6c7e3cda9dfc5c..c17a85318a1c39 100644 --- a/var/spack/repos/builtin/packages/vtk-m/package.py +++ b/var/spack/repos/builtin/packages/vtk-m/package.py @@ -29,6 +29,7 @@ class VtkM(CMakePackage, CudaPackage, ROCmPackage): version("master", branch="master") version("release", branch="release") + version("2.2.0-rc1", sha256="32643cf3564fa77f8e2a2a5456a574b6b2355bb68918eb62ccde493993ade1a3") version( "2.1.0", sha256="9cf3522b6dc0675281a1a16839464ebd1cc5f9c08c20eabee1719b3bcfdcf41f", @@ -51,6 +52,8 @@ class VtkM(CMakePackage, CudaPackage, ROCmPackage): version("1.2.0", sha256="607272992e05f8398d196f0acdcb4af025a4a96cd4f66614c6341f31d4561763") version("1.1.0", sha256="78618c81ca741b1fbba0853cb5d7af12c51973b514c268fc96dfb36b853cdb18") + depends_on("cxx", type="build") # generated + variant("shared", default=False, description="build shared libs") variant("doubleprecision", default=True, description="enable double precision") @@ -139,6 +142,10 @@ class VtkM(CMakePackage, CudaPackage, ROCmPackage): # Patch patch("diy-include-cstddef.patch", when="@1.5.3:1.8.0") + # VTK-M PR#3215 + # https://gitlab.kitware.com/vtk/vtk-m/-/merge_requests/3215 + patch("vtkm-mr3215-ext-geom-fix.patch", when="@2.1") + # VTK-M PR#2972 # https://gitlab.kitware.com/vtk/vtk-m/-/merge_requests/2972 patch("vtkm-cuda-swap-conflict-pr2972.patch", when="@1.9 +cuda ^cuda@12:") @@ -147,6 +154,13 @@ class VtkM(CMakePackage, CudaPackage, ROCmPackage): # https://gitlab.kitware.com/vtk/vtk-m/-/merge_requests/3160 patch("mr3160-rocthrust-fix.patch", when="@2.1:") + # Disable Thrust patch that is no longer needed in modern Thrust + patch( + "https://github.com/Kitware/VTK-m/commit/4a4466e7c8cd44d2be2bd3fe6f359faa8e9547aa.patch?full_index=1", + sha256="58dc104ba05ec99c359eeec3ac094cdb071053a4250f4ad9d72ef6a356c4346e", + when="@1.6.0: +cuda ^cuda@12.5:", + ) + def cmake_args(self): spec = self.spec options = [] @@ -192,6 +206,9 @@ def cmake_args(self): # vtk-m detectes tbb via TBB_ROOT env var os.environ["TBB_ROOT"] = spec["tbb"].prefix + if "+kokkos" in spec and "+rocm" in spec and spec.satisfies("^kokkos@4:"): + options.append(f"-DCMAKE_CXX_COMPILER:BOOL={spec['hip'].prefix.bin.hipcc}") + # Support for relocatable code if "~shared" in spec and "+fpic" in spec: options.append("-DCMAKE_POSITION_INDEPENDENT_CODE:BOOL=ON") @@ -226,14 +243,12 @@ def cmake_args(self): return options - # Delegate in the vtk-m built smoke test - def smoke_test(self): + def test_smoke_test(self): + """Build and run ctests""" spec = self.spec if "+examples" not in spec: - raise RuntimeError( - "Examples needed for smoke test missing", "reinstall with `+examples` variant" - ) + raise SkipTest("Package must be installed with +examples") testdir = "smoke_test_build" with working_dir(testdir, create=True): @@ -248,7 +263,4 @@ def smoke_test(self): @run_after("install") @on_package_attributes(run_tests=True) def build_test(self): - self.smoke_test() - - def test(self): - self.smoke_test() + self.test_smoke_test() diff --git a/var/spack/repos/builtin/packages/vtk-m/vtkm-mr3215-ext-geom-fix.patch b/var/spack/repos/builtin/packages/vtk-m/vtkm-mr3215-ext-geom-fix.patch new file mode 100644 index 00000000000000..ed82e5630e0107 --- /dev/null +++ b/var/spack/repos/builtin/packages/vtk-m/vtkm-mr3215-ext-geom-fix.patch @@ -0,0 +1,145 @@ +From 49518e5054c607942f644c82a5289e12b0f50476 Mon Sep 17 00:00:00 2001 +From: Kenneth Moreland +Date: Fri, 3 May 2024 09:22:56 -0400 +Subject: [PATCH] Fix bug with ExtractGeometry filter + +The `ExtractGeometry` filter was outputing datasets containing +`CellSetPermutation` as the representation for the cells. Although this is +technically correct and a very fast implementation, it is essentially +useless. The problem is that any downstream processing will have to know +that the data has a `CellSetPermutation`. None do (because the permutation +can be on any other cell set type, which creates an explosion of possible +cell types). + +Like was done with `Threshold` a while ago, this problem is fixed by deep +copying the result into a `CellSetExplicit`. This behavior is consistent +with VTK. +--- + .../changelog/extract-geometry-permutation.md | 13 +++++++ + .../testing/UnitTestExtractGeometryFilter.cxx | 13 ++++++- + .../worklet/ExtractGeometry.h | 34 +++++++------------ + 3 files changed, 37 insertions(+), 23 deletions(-) + create mode 100644 docs/changelog/extract-geometry-permutation.md + +diff --git a/docs/changelog/extract-geometry-permutation.md b/docs/changelog/extract-geometry-permutation.md +new file mode 100644 +index 0000000000..8a90495f76 +--- /dev/null ++++ b/docs/changelog/extract-geometry-permutation.md +@@ -0,0 +1,13 @@ ++# Fix bug with ExtractGeometry filter ++ ++The `ExtractGeometry` filter was outputing datasets containing ++`CellSetPermutation` as the representation for the cells. Although this is ++technically correct and a very fast implementation, it is essentially ++useless. The problem is that any downstream processing will have to know ++that the data has a `CellSetPermutation`. None do (because the permutation ++can be on any other cell set type, which creates an explosion of possible ++cell types). ++ ++Like was done with `Threshold` a while ago, this problem is fixed by deep ++copying the result into a `CellSetExplicit`. This behavior is consistent ++with VTK. +diff --git a/vtkm/filter/entity_extraction/testing/UnitTestExtractGeometryFilter.cxx b/vtkm/filter/entity_extraction/testing/UnitTestExtractGeometryFilter.cxx +index 675df8f77c..14de333666 100644 +--- a/vtkm/filter/entity_extraction/testing/UnitTestExtractGeometryFilter.cxx ++++ b/vtkm/filter/entity_extraction/testing/UnitTestExtractGeometryFilter.cxx +@@ -11,6 +11,7 @@ + #include + #include + ++#include + #include + + using vtkm::cont::testing::MakeTestDataSet; +@@ -41,11 +42,21 @@ public: + vtkm::cont::DataSet output = extractGeometry.Execute(dataset); + VTKM_TEST_ASSERT(test_equal(output.GetNumberOfCells(), 8), "Wrong result for ExtractGeometry"); + ++ vtkm::filter::clean_grid::CleanGrid cleanGrid; ++ cleanGrid.SetCompactPointFields(true); ++ cleanGrid.SetMergePoints(false); ++ vtkm::cont::DataSet cleanOutput = cleanGrid.Execute(output); ++ + vtkm::cont::ArrayHandle outCellData; +- output.GetField("cellvar").GetData().AsArrayHandle(outCellData); ++ cleanOutput.GetField("cellvar").GetData().AsArrayHandle(outCellData); + + VTKM_TEST_ASSERT(outCellData.ReadPortal().Get(0) == 21.f, "Wrong cell field data"); + VTKM_TEST_ASSERT(outCellData.ReadPortal().Get(7) == 42.f, "Wrong cell field data"); ++ ++ vtkm::cont::ArrayHandle outPointData; ++ cleanOutput.GetField("pointvar").GetData().AsArrayHandle(outPointData); ++ VTKM_TEST_ASSERT(outPointData.ReadPortal().Get(0) == 99); ++ VTKM_TEST_ASSERT(outPointData.ReadPortal().Get(7) == 90); + } + + static void TestUniformByBox1() +diff --git a/vtkm/filter/entity_extraction/worklet/ExtractGeometry.h b/vtkm/filter/entity_extraction/worklet/ExtractGeometry.h +index 97521335f2..449d7eae60 100644 +--- a/vtkm/filter/entity_extraction/worklet/ExtractGeometry.h ++++ b/vtkm/filter/entity_extraction/worklet/ExtractGeometry.h +@@ -10,11 +10,13 @@ + #ifndef vtkm_m_worklet_ExtractGeometry_h + #define vtkm_m_worklet_ExtractGeometry_h + ++#include + #include + + #include + #include + #include ++#include + #include + #include + #include +@@ -114,28 +116,13 @@ public: + } + }; + +- //////////////////////////////////////////////////////////////////////////////////// +- // Extract cells by ids permutes input data +- template +- vtkm::cont::CellSetPermutation Run(const CellSetType& cellSet, +- const vtkm::cont::ArrayHandle& cellIds) +- { +- using OutputType = vtkm::cont::CellSetPermutation; +- +- vtkm::cont::ArrayCopy(cellIds, this->ValidCellIds); +- +- return OutputType(this->ValidCellIds, cellSet); +- } +- +- //////////////////////////////////////////////////////////////////////////////////// +- // Extract cells by implicit function permutes input data + template +- vtkm::cont::CellSetPermutation Run(const CellSetType& cellSet, +- const vtkm::cont::CoordinateSystem& coordinates, +- const ImplicitFunction& implicitFunction, +- bool extractInside, +- bool extractBoundaryCells, +- bool extractOnlyBoundaryCells) ++ vtkm::cont::CellSetExplicit<> Run(const CellSetType& cellSet, ++ const vtkm::cont::CoordinateSystem& coordinates, ++ const ImplicitFunction& implicitFunction, ++ bool extractInside, ++ bool extractBoundaryCells, ++ bool extractOnlyBoundaryCells) + { + // Worklet output will be a boolean passFlag array + vtkm::cont::ArrayHandle passFlags; +@@ -149,7 +136,10 @@ public: + vtkm::cont::Algorithm::CopyIf(indices, passFlags, this->ValidCellIds); + + // generate the cellset +- return vtkm::cont::CellSetPermutation(this->ValidCellIds, cellSet); ++ vtkm::cont::CellSetPermutation permutedCellSet(this->ValidCellIds, cellSet); ++ ++ vtkm::cont::CellSetExplicit<> outputCells; ++ return vtkm::worklet::CellDeepCopy::Run(permutedCellSet); + } + + vtkm::cont::ArrayHandle GetValidCellIds() const { return this->ValidCellIds; } +-- +GitLab + diff --git a/var/spack/repos/builtin/packages/vtk/package.py b/var/spack/repos/builtin/packages/vtk/package.py index 6ba0bb3f4d504b..ff2eb0ca50988f 100644 --- a/var/spack/repos/builtin/packages/vtk/package.py +++ b/var/spack/repos/builtin/packages/vtk/package.py @@ -20,10 +20,15 @@ class Vtk(CMakePackage): url = "https://www.vtk.org/files/release/9.0/VTK-9.0.0.tar.gz" list_url = "https://www.vtk.org/download/" - maintainers("chuckatkins", "danlipsa") + maintainers("danlipsa", "vicentebolea") license("BSD-3-Clause") + version( + "9.3.1", + sha256="8354ec084ea0d2dc3d23dbe4243823c4bfc270382d0ce8d658939fd50061cab8", + preferred=True, + ) version("9.2.6", sha256="06fc8d49c4e56f498c40fcb38a563ed8d4ec31358d0101e8988f0bb4d539dd12") version("9.2.2", sha256="1c5b0a2be71fac96ff4831af69e350f7a0ea3168981f790c000709dcf9121075") version("9.1.0", sha256="8fed42f4f8f1eb8083107b68eaa9ad71da07110161a3116ad807f43e5ca5ce96") @@ -49,9 +54,11 @@ class Vtk(CMakePackage): version("6.3.0", sha256="92a493354c5fa66bea73b5fc014154af5d9f3f6cee8d20a826f4cd5d4b0e8a5e") version("6.1.0", sha256="bd7df10a479606d529a8b71f466c44a2bdd11fd534c62ce0aa44fad91883fa34") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # VTK7 defaults to OpenGL2 rendering backend variant("opengl2", default=True, description="Enable OpenGL2 backend") - variant("osmesa", default=False, description="Enable OSMesa support") variant("python", default=False, description="Enable Python support", when="@8:") variant("qt", default=False, description="Build with support for Qt") variant("xdmf", default=False, description="Build XDMF file support") @@ -75,7 +82,7 @@ class Vtk(CMakePackage): patch("xdmf2-hdf51.13.2.patch", when="@9:9.2.2 +xdmf") # We cannot build with both osmesa and qt in spack - conflicts("+osmesa", when="+qt") + conflicts("^osmesa", when="+qt") conflicts("%gcc@13", when="@9.2") @@ -98,7 +105,7 @@ class Vtk(CMakePackage): # Broken downstream FindMPI patch("vtkm-findmpi-downstream.patch", when="@9.0.0") - for plat in ["linux", "darwin", "freebsd", "cray"]: + for plat in ["linux", "darwin", "freebsd"]: # use internal FindHDF5 patch("internal_findHDF5.patch", when=f"@:8 platform={plat}") @@ -124,15 +131,11 @@ class Vtk(CMakePackage): patch("vtk_movie_link_ogg.patch", when="@8.2") patch("vtk_use_sqlite_name_vtk_expects.patch", when="@8.2") patch("vtk_proj_include_no_strict.patch", when="@9: platform=windows") + # a patch with the same name is also applied to paraview + # the two patches are the same but for the path to the files they patch patch("vtk_alias_hdf5.patch", when="@9: platform=windows") patch("vtk_findproj_config.patch", when="platform=windows") - with when("~osmesa"): - depends_on("glx", when="platform=linux") - depends_on("glx", when="platform=cray") - depends_on("libxt", when="platform=linux") - depends_on("libxt", when="platform=cray") - - depends_on("osmesa", when="+osmesa") + depends_on("libxt", when="^[virtuals=gl] glx platform=linux") # VTK will need Qt5OpenGL, and qt needs '-opengl' for that depends_on("qt+opengl", when="+qt") @@ -176,8 +179,9 @@ class Vtk(CMakePackage): depends_on("utf8cpp", when="@9:") depends_on("gl2ps", when="@8.1:") depends_on("gl2ps@1.4.1:", when="@9:") - depends_on("proj@4", when="@8.2.0") - depends_on("proj@4:", when="@9:") + # "8.2.1a" uses an internal proj so this special cases 8.2.1a + depends_on("proj@4:7", when="@:8.2.0, 9:9.1") + depends_on("proj@8:", when="@9.2:") depends_on("cgns@4.1.1:+mpi", when="@9.1: +mpi") depends_on("cgns@4.1.1:~mpi", when="@9.1: ~mpi") with when("@9.1:"): @@ -213,6 +217,14 @@ class Vtk(CMakePackage): when="@9.1", ) + # vtk@9 does not compile with gcc 13 or 14 + # https://gitlab.kitware.com/vtk/vtk/-/issues/18782 + patch( + "https://gitlab.kitware.com/vtk/vtk/-/merge_requests/9996.diff", + sha256="dab51ffd0d62b00c089c1245e6b105f740106b53893305c87193d4ba03a948e0", + when="@9.1:9.2 %gcc@13:", + ) + @when("@9.2:") def patch(self): # provide definition for Ioss::Init::Initializer::Initializer(), @@ -275,6 +287,7 @@ def cmake_args(self): cmake_args.extend( [ "-DVTK_USE_EXTERNAL:BOOL=ON", + "-DVTK_MODULE_USE_EXTERNAL_VTK_fast_float:BOOL=OFF", "-DVTK_MODULE_USE_EXTERNAL_VTK_libharu:BOOL=OFF", "-DVTK_MODULE_USE_EXTERNAL_VTK_pegtl:BOOL=OFF", "-DHDF5_ROOT={0}".format(spec["hdf5"].prefix), @@ -415,7 +428,7 @@ def cmake_args(self): cmake_args.append("-DVTK_RENDERING_BACKEND:STRING=" + opengl_ver) - if "+osmesa" in spec: + if spec.satisfies("^[virtuals=gl] osmesa"): cmake_args.extend( [ "-DVTK_USE_X:BOOL=OFF", diff --git a/var/spack/repos/builtin/packages/vvtest/package.py b/var/spack/repos/builtin/packages/vvtest/package.py index 8bc51b502204f1..106a497924e3ea 100644 --- a/var/spack/repos/builtin/packages/vvtest/package.py +++ b/var/spack/repos/builtin/packages/vvtest/package.py @@ -24,6 +24,8 @@ class Vvtest(Package): version("1.1.0", sha256="674585f12d393ab9745a5ab26f59cb0f0e213f9c597b37467125979b5955ca79") version("1.0.0", sha256="acd04e8e6635ed1b1725b793e8287a58831d6380759a81159142a6ff3397a8dd") + depends_on("c", type="build") # generated + depends_on("python@2.6.0:3", type=("build", "run")) def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/w3emc/package.py b/var/spack/repos/builtin/packages/w3emc/package.py index f27000dbda3033..ecbd078f8100b7 100644 --- a/var/spack/repos/builtin/packages/w3emc/package.py +++ b/var/spack/repos/builtin/packages/w3emc/package.py @@ -27,6 +27,9 @@ class W3emc(CMakePackage): version("2.9.0", sha256="994f59635ab91e34e96cab5fbaf8de54389d09461c7bac33b3104a1187e6c98a") version("2.7.3", sha256="eace811a1365f69b85fdf2bcd93a9d963ba72de5a7111e6fa7c0e6578b69bfbc") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("pic", default=True, description="Build with position-independent-code") variant("bufr", default=False, description="Build with BUFR routines", when="@2.10:") variant( diff --git a/var/spack/repos/builtin/packages/w3m/package.py b/var/spack/repos/builtin/packages/w3m/package.py index 80aa64adca3415..2027b7f90bca05 100644 --- a/var/spack/repos/builtin/packages/w3m/package.py +++ b/var/spack/repos/builtin/packages/w3m/package.py @@ -29,6 +29,9 @@ class W3m(AutotoolsPackage): version("0.5.3", sha256="e994d263f2fd2c22febfbe45103526e00145a7674a0fda79c822b97c2770a9e3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # mandatory dependency depends_on("bdw-gc") diff --git a/var/spack/repos/builtin/packages/w3nco/package.py b/var/spack/repos/builtin/packages/w3nco/package.py index 495293c1a61a54..c8de32376eb16a 100644 --- a/var/spack/repos/builtin/packages/w3nco/package.py +++ b/var/spack/repos/builtin/packages/w3nco/package.py @@ -19,3 +19,16 @@ class W3nco(CMakePackage): maintainers("t-brown", "AlexanderRichert-NOAA", "Hang-Lei-NOAA", "edwardhartnett") version("2.4.1", sha256="48b06e0ea21d3d0fd5d5c4e7eb50b081402567c1bff6c4abf4fd4f3669070139") + + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + + def flag_handler(self, name, flags): + if name == "cflags": + if ( + self.spec.satisfies("%oneapi") + or self.spec.satisfies("%apple-clang") + or self.spec.satisfies("%clang") + ): + flags.append("-Wno-error=implicit-function-declaration") + return (flags, None, None) diff --git a/var/spack/repos/builtin/packages/wannier90/package.py b/var/spack/repos/builtin/packages/wannier90/package.py index 8bb4310893611c..0e1e71fed100d0 100644 --- a/var/spack/repos/builtin/packages/wannier90/package.py +++ b/var/spack/repos/builtin/packages/wannier90/package.py @@ -27,6 +27,9 @@ class Wannier90(MakefilePackage): version("2.1.0", sha256="ee90108d4bc4aa6a1cf16d72abebcb3087cf6c1007d22dda269eb7e7076bddca") version("2.0.1", sha256="05ea7cd421a219ce19d379ad6ae3d9b1a84be4ffb367506ffdfab1e729309e94") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") depends_on("lapack") depends_on("blas") diff --git a/var/spack/repos/builtin/packages/warpx/package.py b/var/spack/repos/builtin/packages/warpx/package.py index 07068f950a5707..fb7d66384ffcca 100644 --- a/var/spack/repos/builtin/packages/warpx/package.py +++ b/var/spack/repos/builtin/packages/warpx/package.py @@ -57,6 +57,8 @@ class Warpx(CMakePackage): version("21.06", sha256="a26039dc4061da45e779dd5002467c67a533fc08d30841e01e7abb3a890fbe30") version("21.05", sha256="f835f0ae6c5702550d23191aa0bb0722f981abb1460410e3d8952bc3d945a9fc") version("21.04", sha256="51d2d8b4542eada96216e8b128c0545c4b7527addc2038efebe586c32c4020a0") + + depends_on("cxx", type="build") # generated # 20.01+ requires C++14 or newer variant("app", default=True, description="Build the WarpX executable application") @@ -144,6 +146,7 @@ class Warpx(CMakePackage): with when("+openpmd"): depends_on("openpmd-api@0.13.1:") depends_on("openpmd-api@0.14.2:", when="@21.09:") + depends_on("openpmd-api@0.15.1:", when="@23.05:") depends_on("openpmd-api ~mpi", when="~mpi") depends_on("openpmd-api +mpi", when="+mpi") @@ -254,7 +257,7 @@ def libs(self): def _get_input_options(self, dim, post_install): spec = self.spec examples_dir = join_path( - self.install_test_root if post_install else self.stage.source_path, + install_test_root(self) if post_install else self.stage.source_path, self.examples_src_dir, ) inputs_nD = {"1": "inputs_1d", "2": "inputs_2d", "3": "inputs_3d", "rz": "inputs_rz"} @@ -289,25 +292,33 @@ def check(self): def copy_test_sources(self): """Copy the example input files after the package is installed to an install test subdirectory for use during `spack test run`.""" - self.cache_extra_test_sources([self.examples_src_dir]) + cache_extra_test_sources(self, [self.examples_src_dir]) - def test(self): - """Perform smoke tests on the installed package.""" + def run_warpx(self, dim): if "+app" not in self.spec: - print("WarpX smoke tests skipped: requires variant +app") - return - - # our executable names are a variant-dependent and naming evolves - for dim in self.spec.variants["dims"].value: - exe_nD = {"1": "warpx.1d", "2": "warpx.2d", "3": "warpx.3d", "rz": "warpx.rz"} - exe = find(self.prefix.bin, exe_nD[dim] + ".*", recursive=False)[0] - - cli_args = self._get_input_options(dim, True) - self.run_test( - exe, - cli_args, - [], - installed=True, - purpose="Smoke test for WarpX", - skip_missing=False, - ) + raise SkipTest("Package must be installed with +app") + if dim not in self.spec.variants["dims"].value: + raise SkipTest(f"Package must be installed with {dim} in dims") + dim_arg = f"{dim}d" if dim.isdigit() else dim + if self.spec.satisfies("@:23.05") and not dim.isdigit(): + dim_arg = dim_arg.upper() + exe = find(self.prefix.bin, f"warpx.{dim_arg}.*", recursive=False)[0] + cli_args = self._get_input_options(dim, True) + warpx = which(exe) + warpx(*cli_args) + + def test_warpx_1d(self): + """Run warpx 1d test""" + self.run_warpx("1") + + def test_warpx_2d(self): + """Run warpx 2d test""" + self.run_warpx("2") + + def test_warpx_3d(self): + """Run warpx 3d test""" + self.run_warpx("3") + + def test_warpx_rz(self): + """Run warpx rz test""" + self.run_warpx("rz") diff --git a/var/spack/repos/builtin/packages/watch/package.py b/var/spack/repos/builtin/packages/watch/package.py index 5b8712599f2d43..fae74fc445632a 100644 --- a/var/spack/repos/builtin/packages/watch/package.py +++ b/var/spack/repos/builtin/packages/watch/package.py @@ -21,6 +21,8 @@ class Watch(AutotoolsPackage): version("master", branch="master") version("3.3.15", tag="v3.3.15", commit="7bb949bcba13c107fa0f45d2d0298b1ad6b6d6cc") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/wayland-protocols/package.py b/var/spack/repos/builtin/packages/wayland-protocols/package.py index 5fd0ab5ac86e07..52596f24c188bc 100644 --- a/var/spack/repos/builtin/packages/wayland-protocols/package.py +++ b/var/spack/repos/builtin/packages/wayland-protocols/package.py @@ -28,6 +28,9 @@ class WaylandProtocols(MesonPackage, AutotoolsPackage): license("MIT") + version("1.34", sha256="cd3cc9dedb838e6fc8f55bbeb688e8569ffac7df53bc59dbfac8acbb39267f05") + version("1.33", sha256="71a7d2f062d463aa839497ddfac97e4bd3f00aa306e014f94529aa3a2be193a8") + version("1.32", sha256="444b5d823ad0163dfe505c97ea1a0689ca7e2978a87cf59b03f06573b87db260") version("1.31", sha256="04d3f66eca99d638ec8dbfdfdf79334290e22028f7d0b04c7034d9ef18a3248a") version("1.30", sha256="1c02ce27d5267c904f2f0d31039265f3e4112f15bf274b1c72bdacd5322f243d") version("1.29", sha256="4a85786ae69cd6d53bbe9278572f3c3d6ea342875ea444960edb6089237c3a18") diff --git a/var/spack/repos/builtin/packages/wayland/package.py b/var/spack/repos/builtin/packages/wayland/package.py index 7b0d7eb3fb7250..e44b87c17af023 100644 --- a/var/spack/repos/builtin/packages/wayland/package.py +++ b/var/spack/repos/builtin/packages/wayland/package.py @@ -39,6 +39,9 @@ class Wayland(MesonPackage, AutotoolsPackage): version("1.17.93", sha256="293536ad23bfed15fc34e2a63bbb511167e8b096c0eba35e805cb64d46ad62ae") version("1.17.92", sha256="d944a7b999cfe6fee5327a2315c8e5891222c5a88a96e1ca73485978e4990512") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + with when("build_system=autotools"): depends_on("autoconf", type="build") depends_on("automake", type="build") @@ -59,7 +62,7 @@ class Wayland(MesonPackage, AutotoolsPackage): depends_on("doxygen", type="build") depends_on("xmlto", type="build") depends_on("libxslt", type="build") - depends_on("graphviz+libgd", type="build") + depends_on("graphviz+expat+libgd", type="build") @when("build_system=autotools") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/wcs/package.py b/var/spack/repos/builtin/packages/wcs/package.py index 0070396347acec..5b9800233c20c6 100644 --- a/var/spack/repos/builtin/packages/wcs/package.py +++ b/var/spack/repos/builtin/packages/wcs/package.py @@ -19,6 +19,8 @@ class Wcs(CMakePackage): version("master", branch="master") version("develop", branch="devel") + depends_on("cxx", type="build") # generated + depends_on("boost+graph+filesystem+regex+system") # TODO: replace this with an explicit list of components of Boost, diff --git a/var/spack/repos/builtin/packages/webbench/package.py b/var/spack/repos/builtin/packages/webbench/package.py index eaf47ee8d8ee29..67e47a24aa6318 100644 --- a/var/spack/repos/builtin/packages/webbench/package.py +++ b/var/spack/repos/builtin/packages/webbench/package.py @@ -16,6 +16,8 @@ class Webbench(MakefilePackage): version("1.5", commit="b1acf3c01cc914729fe188dfc8ed761858028d4f") + depends_on("c", type="build") # generated + depends_on("ntirpc") def setup_build_environment(self, env): diff --git a/var/spack/repos/builtin/packages/weechat/package.py b/var/spack/repos/builtin/packages/weechat/package.py index c93b9658319591..b305941aa89d6a 100644 --- a/var/spack/repos/builtin/packages/weechat/package.py +++ b/var/spack/repos/builtin/packages/weechat/package.py @@ -18,6 +18,9 @@ class Weechat(CMakePackage): version("2.9", sha256="3a78063b76c42ba306eacf8f74cb8c9a260f8a61d1915d0b5d76f11d2be69a53") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("perl", default=False, description="Include perl support") variant("lua", default=False, description="Include lua support") variant("ruby", default=False, description="Include ruby support") diff --git a/var/spack/repos/builtin/packages/weighttp/package.py b/var/spack/repos/builtin/packages/weighttp/package.py index d27a8c070fbd35..9650d9707cf753 100644 --- a/var/spack/repos/builtin/packages/weighttp/package.py +++ b/var/spack/repos/builtin/packages/weighttp/package.py @@ -18,6 +18,8 @@ class Weighttp(AutotoolsPackage): version("0.3", sha256="376e2311af2decb8f6051e4f968d7c0ba92ca60cd563d768beb4868eb9679f45") version("0.2", sha256="bc2b3955126010ce27e0829285720f973df9f144e9cca2568569a657a3d5e634") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/wget/package.py b/var/spack/repos/builtin/packages/wget/package.py index ac6bce959358d8..41dcdf41939891 100644 --- a/var/spack/repos/builtin/packages/wget/package.py +++ b/var/spack/repos/builtin/packages/wget/package.py @@ -17,6 +17,8 @@ class Wget(AutotoolsPackage, GNUMirrorPackage): license("GPL-3.0-or-later WITH OpenSSL-Exception") + version("1.24.5", sha256="fa2dc35bab5184ecbc46a9ef83def2aaaa3f4c9f3c97d4bd19dcb07d4da637de") + version("1.21.4", sha256="81542f5cefb8faacc39bbbc6c82ded80e3e4a88505ae72ea51df27525bcde04c") version("1.21.3", sha256="5726bb8bc5ca0f6dc7110f6416e4bb7019e2d2ff5bf93d1ca2ffcc6656f220e5") version("1.21.2", sha256="e6d4c76be82c676dd7e8c61a29b2ac8510ae108a810b5d1d18fc9a1d2c9a2497") version("1.21.1", sha256="59ba0bdade9ad135eda581ae4e59a7a9f25e3a4bde6a5419632b31906120e26e") @@ -26,6 +28,8 @@ class Wget(AutotoolsPackage, GNUMirrorPackage): version("1.17", sha256="3e04ad027c5b6ebd67c616eec13e66fbedb3d4d8cbe19cc29dadde44b92bda55") version("1.16", sha256="b977fc10ac7a72d987d48136251aeb332f2dced1aabd50d6d56bdf72e2b79101") + depends_on("c", type="build") # generated + variant( "ssl", default="openssl", values=("gnutls", "openssl"), description="Specify SSL backend" ) diff --git a/var/spack/repos/builtin/packages/wgl/package.py b/var/spack/repos/builtin/packages/wgl/package.py index 9a3a0bc7e7d6f4..b420cdcf644d80 100644 --- a/var/spack/repos/builtin/packages/wgl/package.py +++ b/var/spack/repos/builtin/packages/wgl/package.py @@ -14,7 +14,7 @@ class Wgl(Package): homepage = "https://learn.microsoft.com/en-us/windows/win32/opengl/wgl-and-windows-reference" has_code = False - tags = ["windows"] + tags = ["windows", "windows-system"] # hard code the extension as shared lib libraries = ["OpenGL32.Lib"] @@ -36,6 +36,10 @@ class Wgl(Package): version("10.0.26639") version("10.0.20348") + variant( + "plat", values=("x64", "x86", "arm", "arm64"), default="x64", description="Toolchain arch" + ) + # As per https://github.com/spack/spack/pull/31748 this provisory version represents # an arbitrary openGL version designed for maximum compatibility with calling packages # this current version simply reflects the latest OpenGL vesion available at the time of @@ -58,7 +62,7 @@ class Wgl(Package): depends_on("win-sdk@10.0.14393", when="@10.0.14393") # WGL has no meaning on other platforms, should not be able to spec - for plat in ["linux", "darwin", "cray"]: + for plat in ["linux", "darwin"]: conflicts("platform=%s" % plat) @classmethod @@ -68,6 +72,16 @@ def determine_version(cls, lib): ver_str = re.search(version_match_pat, lib) return ver_str if not ver_str else Version(ver_str.group()) + @classmethod + def determine_variants(cls, libs, ver_str): + """Allow for determination of toolchain arch for detected WGL""" + variants = [] + for lib in libs: + base, lib_name = os.path.split(lib) + _, arch = os.path.split(base) + variants.append("plat=%s" % arch) + return variants + def _spec_arch_to_sdk_arch(self): spec_arch = str(self.spec.architecture.target.microarchitecture.family).lower() _64bit = "64" in spec_arch diff --git a/var/spack/repos/builtin/packages/wgrib2/package.py b/var/spack/repos/builtin/packages/wgrib2/package.py index 52ad78f32b4196..1cc9c824d92b5e 100644 --- a/var/spack/repos/builtin/packages/wgrib2/package.py +++ b/var/spack/repos/builtin/packages/wgrib2/package.py @@ -38,6 +38,9 @@ class Wgrib2(MakefilePackage): extension="tar.gz", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("netcdf3", default=True, description="Link in netcdf3 library to write netcdf3 files") variant( "netcdf4", default=False, description="Link in netcdf4 library to write netcdf3/4 files" @@ -150,7 +153,7 @@ def edit(self, spec, prefix): makefile.filter(r"^%s=.*" % makefile_option, "{}={}".format(makefile_option, value)) def setup_build_environment(self, env): - if self.spec.compiler.name in "intel": + if self.spec.compiler.name in ["oneapi", "intel"]: comp_sys = "intel_linux" elif self.spec.compiler.name in ["gcc", "clang", "apple-clang"]: comp_sys = "gnu_linux" diff --git a/var/spack/repos/builtin/packages/wgsim/package.py b/var/spack/repos/builtin/packages/wgsim/package.py index f2a6d25535b30b..8c471e56423607 100644 --- a/var/spack/repos/builtin/packages/wgsim/package.py +++ b/var/spack/repos/builtin/packages/wgsim/package.py @@ -20,6 +20,8 @@ class Wgsim(Package): version("2011.10.17", commit="a12da3375ff3b51a5594d4b6fa35591173ecc229") + depends_on("c", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/which/package.py b/var/spack/repos/builtin/packages/which/package.py index 1c36d3ed396309..8fc8eb0fe14f45 100644 --- a/var/spack/repos/builtin/packages/which/package.py +++ b/var/spack/repos/builtin/packages/which/package.py @@ -18,6 +18,8 @@ class Which(AutotoolsPackage): version("2.21", sha256="f4a245b94124b377d8b49646bf421f9155d36aa7614b6ebf83705d3ffc76eaad") + depends_on("c", type="build") # generated + executables = ["which"] @classmethod diff --git a/var/spack/repos/builtin/packages/whip/package.py b/var/spack/repos/builtin/packages/whip/package.py index 138ce77477831f..f6b826a7fa23a1 100644 --- a/var/spack/repos/builtin/packages/whip/package.py +++ b/var/spack/repos/builtin/packages/whip/package.py @@ -18,9 +18,12 @@ class Whip(CMakePackage, CudaPackage, ROCmPackage): license("BSD-3-Clause") version("main", branch="main") + version("0.3.0", sha256="0c803e9453bc9c0cc8fbead507635b5c30465b6c2d46328f2a6a1140b4a8ff48") version("0.2.0", sha256="d8fec662526accbd1624922fdf01a077d6f312cf253382660e4a2f65e28e8686") version("0.1.0", sha256="5d557794f4afc8332fc660948a342f69e22bc9e5d575ffb3e3944cf526db5ec9") + depends_on("cxx", type="build") + depends_on("cmake@3.22:", type="build") # Exactly one of +cuda and +rocm need to be set diff --git a/var/spack/repos/builtin/packages/whizard/package.py b/var/spack/repos/builtin/packages/whizard/package.py index 0995fc6c0f6f8f..3e07f677d68374 100644 --- a/var/spack/repos/builtin/packages/whizard/package.py +++ b/var/spack/repos/builtin/packages/whizard/package.py @@ -3,6 +3,8 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os + from spack.package import * @@ -25,6 +27,7 @@ class Whizard(AutotoolsPackage): license("GPL-2.0-or-later") version("master", branch="master") + version("3.1.4", sha256="9da9805251d786adaf4ad5a112f9c4ee61d515778af0d2623d6460c3f1f900cd") version("3.1.2", sha256="4f706f8ef02a580ae4dba867828691dfe0b3f9f9b8982b617af72eb8cd4c6fa3") version("3.1.1", sha256="dd48e4e39b8a4990be47775ec6171f89d8147cb2e9e293afc7051a7dbc5a23ef") version("3.1.0", sha256="9dc5e6d1a25d2fc708625f85010cb81b63559ff02cceb9b35024cf9f426c0ad9") @@ -41,6 +44,10 @@ class Whizard(AutotoolsPackage): version("2.8.1", sha256="0c759ce0598e25f38e04659f745c5963d238c4b5c12209f16449b6c0bc6dc64e") version("2.8.0", sha256="3b5175eafa879d1baca20237d18fb2b18bee89631e73ada499de9c082d009696") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "hepmc", default="3", @@ -51,6 +58,7 @@ class Whizard(AutotoolsPackage): variant("pythia8", default=True, description="builds with pythia8") variant("fastjet", default=False, description="builds with fastjet") + variant("gosam", default=False, description="builds with gosam") variant("lcio", default=False, description="builds with lcio") variant("lhapdf", default=False, description="builds with fastjet") variant("openmp", default=False, description="builds with openmp") @@ -64,19 +72,25 @@ class Whizard(AutotoolsPackage): depends_on("hepmc3", when="hepmc=3") depends_on("lcio", when="+lcio") depends_on("pythia8", when="+pythia8") + depends_on("pythia8@:8.309", when="@:3.1.3+pythia8") depends_on("lhapdf", when="+lhapdf") depends_on("fastjet", when="+fastjet") + depends_on("py-gosam", when="+gosam") + depends_on("gosam-contrib", when="+gosam") + depends_on("qgraf", when="+gosam") + depends_on( "openloops@2.0.0: +compile_extra num_jobs=1 " "processes=eett,eevvjj,ppllj,tbw", when="+openloops", ) depends_on("texlive", when="+latex") + depends_on("ghostscript", when="+latex") depends_on("zlib-api") # Fix for https://github.com/key4hep/key4hep-spack/issues/71 # NOTE: This will become obsolete in a future release of whizard, so once # that happens, this needs to be adapted with a when clause - patch("parallel_build_fix.patch", when="@3:") + patch("parallel_build_fix.patch", when="@3:3.1.3") patch("parallel_build_fix_2.8.patch", when="@2.8") # Make sure that the patch actually has an effect by running autoreconf force_autoreconf = True @@ -123,6 +137,14 @@ def setup_build_environment(self, env): env.set("FC", self.compiler.fc) env.set("F77", self.compiler.fc) + @run_before("autoreconf") + def prepare_whizard(self): + # As described in the manual (SVN Repository version) + # https://whizard.hepforge.org/manual/manual003.html#sec%3Aprerequisites + if not os.path.exists("configure.ac"): + shell = which("sh") + shell("build_master.sh") + def configure_args(self): spec = self.spec enable_hepmc = "no" if "hepmc=off" in spec else "yes" @@ -133,10 +155,10 @@ def configure_args(self): # todo: hoppet # todo: recola # todo: looptools - # todo: gosam # todo: pythia6 ] args.extend(self.enable_or_disable("fastjet")) + args.extend(self.enable_or_disable("gosam")) args.extend(self.enable_or_disable("pythia8")) args.extend(self.enable_or_disable("lcio")) args.extend(self.enable_or_disable("lhapdf")) @@ -144,8 +166,8 @@ def configure_args(self): if "+openloops" in spec: args.append(f"--with-openloops={spec['openloops'].prefix}") - if "+openmp" not in spec: - args.append("--disable-openmp") + if "+openmp" in spec: + args.append("--enable-fc-openmp") return args def url_for_version(self, version): diff --git a/var/spack/repos/builtin/packages/wi4mpi/package.py b/var/spack/repos/builtin/packages/wi4mpi/package.py index 808dc1d08bc5da..4e800940076ea3 100644 --- a/var/spack/repos/builtin/packages/wi4mpi/package.py +++ b/var/spack/repos/builtin/packages/wi4mpi/package.py @@ -27,6 +27,10 @@ class Wi4mpi(CMakePackage): version("3.2.2", sha256="23ac69740577d66a68ddd5360670f0a344e3c47a5d146033c63a67e54e56c66f") version("3.2.1", sha256="0d928cb930b6cb1ae648eca241db59812ee0e5c041faf2f57728bbb6ee4e36df") version("3.2.0", sha256="3322f6823dbec1d58a1fcf163b2bcdd7b9cd75dc6c7f78865fc6cb0a91bf6f94") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated variant( "build_type", default="Release", diff --git a/var/spack/repos/builtin/packages/win-sdk/package.py b/var/spack/repos/builtin/packages/win-sdk/package.py index 3c96fb1a9161c8..7d40c225396aa5 100644 --- a/var/spack/repos/builtin/packages/win-sdk/package.py +++ b/var/spack/repos/builtin/packages/win-sdk/package.py @@ -19,7 +19,7 @@ class WinSdk(Package): homepage = "https://developer.microsoft.com/en-us/windows/downloads/windows-sdk/" has_code = False - tags = ["windows"] + tags = ["windows", "windows-system"] # The sdk has many libraries and executables. Record one for detection purposes libraries = ["rcdll.dll"] @@ -55,7 +55,7 @@ class WinSdk(Package): # For now we don't support Windows development env # on other platforms - for plat in ["linux", "darwin", "cray"]: + for plat in ["linux", "darwin"]: conflicts("platform=%s" % plat) @classmethod diff --git a/var/spack/repos/builtin/packages/win-wdk/package.py b/var/spack/repos/builtin/packages/win-wdk/package.py index 8bf9f5b9d0a1d2..2138cbea2ffcad 100644 --- a/var/spack/repos/builtin/packages/win-wdk/package.py +++ b/var/spack/repos/builtin/packages/win-wdk/package.py @@ -18,7 +18,7 @@ class WinWdk(Package): """ homepage = "https://learn.microsoft.com/en-us/windows-hardware/drivers/" - tags = ["windows"] + tags = ["windows", "windows-system"] # The wdk has many libraries and executables. Record one for detection purposes libraries = ["mmos.lib"] @@ -81,7 +81,7 @@ class WinWdk(Package): depends_on("win-sdk@10.0.15063", when="@10.0.15063") depends_on("win-sdk@10.0.14393", when="@10.0.14393") - for plat in ["linux", "darwin", "cray"]: + for plat in ["linux", "darwin"]: conflicts("platform=%s" % plat) @classmethod diff --git a/var/spack/repos/builtin/packages/winbison/package.py b/var/spack/repos/builtin/packages/winbison/package.py index 877188c0cd5d17..5b492f3183140b 100644 --- a/var/spack/repos/builtin/packages/winbison/package.py +++ b/var/spack/repos/builtin/packages/winbison/package.py @@ -36,6 +36,9 @@ class Winbison(CMakePackage): version("2.5.14", sha256="2ace5c964fb4b45279544669950412dbe4e86908c03bd5ebc8c8d306e458e97d") version("2.4.12", sha256="fcffc223897e14f2b5dce2db1c832f297cc43a1204e4b3fd713f1dc410e956e4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_directory = "spack-build" cmake_dir = os.path.join(build_directory, "CMakeBuild") diff --git a/var/spack/repos/builtin/packages/wiredtiger/package.py b/var/spack/repos/builtin/packages/wiredtiger/package.py index 23675d7713b9e5..6f509117badb99 100644 --- a/var/spack/repos/builtin/packages/wiredtiger/package.py +++ b/var/spack/repos/builtin/packages/wiredtiger/package.py @@ -15,6 +15,9 @@ class Wiredtiger(AutotoolsPackage): version("10.0.0", sha256="4830107ac744c0459ef99697652aa3e655c2122005a469a49d221e692fb834a5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("python@3:", type=("build", "run"), when="+python") depends_on("swig", type=("build", "run"), when="+python") depends_on("lz4", when="+lz4") diff --git a/var/spack/repos/builtin/packages/wireshark/package.py b/var/spack/repos/builtin/packages/wireshark/package.py index 129677f177b435..951b1252385c1a 100644 --- a/var/spack/repos/builtin/packages/wireshark/package.py +++ b/var/spack/repos/builtin/packages/wireshark/package.py @@ -21,6 +21,9 @@ class Wireshark(CMakePackage): version("3.0.8", sha256="b4bd8189934d82330a053c5b10398f2b625b1e1c8818831ab61739b2d7aa7561") version("2.6.0", sha256="711c7f01d27a8817d58277a5487cef3e3c7bab1c8caaf8f4c92aa21015b9117f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("libssh", default=False, description="Build with libssh") variant("nghttp2", default=False, description="Build with nghttp2") variant("qt", default=False, description="Build with qt") diff --git a/var/spack/repos/builtin/packages/wonton/package.py b/var/spack/repos/builtin/packages/wonton/package.py index 6a6dcf0482391a..f73136012f539c 100644 --- a/var/spack/repos/builtin/packages/wonton/package.py +++ b/var/spack/repos/builtin/packages/wonton/package.py @@ -29,6 +29,9 @@ class Wonton(CMakePackage): version("1.2.10", sha256="c5c2c99f040f1fa5a8da21ac5ccbbc5b226d1fd43ce3eb14c76d211601b65a72") version("1.2.1", sha256="4f00513d1abe86f256214d2b5171b1575b2cd464df8609307c24cbc4c595c305") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("lapacke", default=True, description="Use LAPACKE solvers") # Variants for controlling parallelism diff --git a/var/spack/repos/builtin/packages/wordnet/package.py b/var/spack/repos/builtin/packages/wordnet/package.py index d7bd40e0920c4a..efaed4924b0563 100644 --- a/var/spack/repos/builtin/packages/wordnet/package.py +++ b/var/spack/repos/builtin/packages/wordnet/package.py @@ -16,6 +16,8 @@ class Wordnet(AutotoolsPackage): version("3.0", sha256="640db279c949a88f61f851dd54ebbb22d003f8b90b85267042ef85a3781d3a52") + depends_on("c", type="build") # generated + depends_on("tk") depends_on("tcl") diff --git a/var/spack/repos/builtin/packages/wps/package.py b/var/spack/repos/builtin/packages/wps/package.py index 3a3aaa69f5bafc..89633e7c8dd088 100644 --- a/var/spack/repos/builtin/packages/wps/package.py +++ b/var/spack/repos/builtin/packages/wps/package.py @@ -22,6 +22,10 @@ class Wps(Package): version("4.3", sha256="1913cb24de549f029d65635feea27f3304a8f42ec025954a0887651fc89d1e9e") version("4.2", sha256="3e175d033355d3e7638be75bc7c0bc0de6da299ebd175a9bbc1b7a121acd0168") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Serial variant recommended in WRF/WPS docs variant( "build_type", diff --git a/var/spack/repos/builtin/packages/wrf-io/package.py b/var/spack/repos/builtin/packages/wrf-io/package.py index 6b80fdeef76ea1..1d8353fa559601 100644 --- a/var/spack/repos/builtin/packages/wrf-io/package.py +++ b/var/spack/repos/builtin/packages/wrf-io/package.py @@ -22,6 +22,9 @@ class WrfIo(CMakePackage): version("develop", branch="develop") version("1.2.0", sha256="000cf5294a2c68460085258186e1f36c86d3d0d9c433aa969a0f92736b745617") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("openmp", default=False, description="Enable multithreading with OpenMP") depends_on("netcdf-c") diff --git a/var/spack/repos/builtin/packages/wrf/package.py b/var/spack/repos/builtin/packages/wrf/package.py index 15f81f0aace253..6ffc1a42eacf6e 100644 --- a/var/spack/repos/builtin/packages/wrf/package.py +++ b/var/spack/repos/builtin/packages/wrf/package.py @@ -70,6 +70,11 @@ class Wrf(Package): maintainers("MichaelLaufer", "ptooley") tags = ["windows"] + version( + "4.5.2", + sha256="408ba6aa60d9cd51d6bad2fa075a3d37000eb581b5d124162885b049c892bbdc", + url="https://github.com/wrf-model/WRF/releases/download/v4.5.2/v4.5.2.tar.gz", + ) version( "4.5.1", sha256="9d557c34c105db4d41e727843ecb19199233c7cf82c5369b34a2ce8efe65e2d1", @@ -102,6 +107,9 @@ class Wrf(Package): url="https://github.com/wrf-model/WRF/archive/V3.9.1.1.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant( "build_type", default="dmpar", @@ -159,13 +167,13 @@ class Wrf(Package): patch("patches/4.0/tirpc_detect.patch", when="@4.0") patch("patches/4.0/add_aarch64.patch", when="@4.0") - patch("patches/4.2/arch.Config.pl.patch", when="@4.2:") + patch("patches/4.2/arch.Config.pl.patch", when="@4.2:4.5.1") patch("patches/4.2/arch.configure.defaults.patch", when="@=4.2") patch("patches/4.2/4.2.2_arch.configure.defaults.patch", when="@4.2.2") patch("patches/4.2/arch.conf_tokens.patch", when="@4.2:") patch("patches/4.2/arch.postamble.patch", when="@4.2") patch("patches/4.2/configure.patch", when="@4.2:4.3.3") - patch("patches/4.2/external.io_netcdf.makefile.patch", when="@4.2:") + patch("patches/4.2/external.io_netcdf.makefile.patch", when="@4.2:4.5.1") patch("patches/4.2/var.gen_be.Makefile.patch", when="@4.2:") patch("patches/4.2/Makefile.patch", when="@4.2") patch("patches/4.2/tirpc_detect.patch", when="@4.2") @@ -173,7 +181,7 @@ class Wrf(Package): patch("patches/4.2/add_aarch64_acfl.patch", when="@4.2:4.3.1 %arm target=aarch64:") patch("patches/4.2/configure_aocc_2.3.patch", when="@4.2 %aocc@:2.4.0") patch("patches/4.2/configure_aocc_3.0.patch", when="@4.2 %aocc@3.0.0:3.2.0") - patch("patches/4.2/hdf5_fix.patch", when="@4.2: %aocc") + patch("patches/4.2/hdf5_fix.patch", when="@4.2:4.5.1 %aocc") patch("patches/4.2/derf_fix.patch", when="@=4.2 %aocc") patch( "patches/4.2/add_tools_flags_acfl2304.patch", @@ -183,14 +191,14 @@ class Wrf(Package): patch("patches/4.3/add_aarch64.patch", when="@4.3.2:4.4.2 %gcc target=aarch64:") patch("patches/4.3/add_aarch64_acfl.patch", when="@4.3.2:4.4.2 %arm target=aarch64:") - patch("patches/4.4/arch.postamble.patch", when="@4.4:") + patch("patches/4.4/arch.postamble.patch", when="@4.4:4.5.1") patch("patches/4.4/configure.patch", when="@4.4:4.4.2") patch("patches/4.4/ifx.patch", when="@4.4: %oneapi") patch("patches/4.5/configure.patch", when="@4.5:") # Fix WRF to remove deprecated ADIOS2 functions # https://github.com/wrf-model/WRF/pull/1860 - patch("patches/4.5/adios2-remove-deprecated-functions.patch", when="@4.5: ^adios2@2.9:") + patch("patches/4.5/adios2-remove-deprecated-functions.patch", when="@=4.5.0 ^adios2@2.9:") # Various syntax fixes found by FPT tool patch( @@ -200,9 +208,9 @@ class Wrf(Package): ) patch("patches/4.2/configure_fujitsu.patch", when="@4 %fj") - patch("patches/4.3/Makefile.patch", when="@4.3:") + patch("patches/4.3/Makefile.patch", when="@4.3:4.5.1") patch("patches/4.3/arch.postamble.patch", when="@4.3:4.3.3") - patch("patches/4.3/fujitsu.patch", when="@4.3: %fj") + patch("patches/4.3/fujitsu.patch", when="@4.3:4.4 %fj") # Syntax errors in physics routines patch( "https://github.com/wrf-model/WRF/commit/7c6fd575b7a8fe5715b07b38db160e606c302956.patch?full_index=1", @@ -216,13 +224,13 @@ class Wrf(Package): ) # Add ARM compiler support patch( - "https://github.com/wrf-model/WRF/pull/1888/commits/4a084e03575da65f254917ef5d8eb39074abd3fc.patch", - sha256="c522c4733720df9a18237c06d8ab6199fa9674d78375b644aec7017cb38af9c5", + "https://github.com/wrf-model/WRF/commit/4a084e03575da65f254917ef5d8eb39074abd3fc.patch?full_index=1", + sha256="2d06d709074ded9bd6842aa83c0dfdad5a4e4e2df99e2e5d4a82579f0486117e", when="@4.5: %arm", ) patch( - "https://github.com/wrf-model/WRF/pull/1888/commits/6087d9192f7f91967147e50f5bc8b9e49310cf98.patch", - sha256="f82a18cf7334e0cbbfdf4ef3aa91ca26d4a372709f114ce0116b3fbb136ffac6", + "https://github.com/wrf-model/WRF/commit/6087d9192f7f91967147e50f5bc8b9e49310cf98.patch?full_index=1", + sha256="7c6487aefaa6cda0fff3976e78da07b09d2ba6c005d649f35a0f8f1694a0b2bb", when="@4.5: %arm", ) @@ -251,6 +259,10 @@ class Wrf(Package): depends_on("m4", type="build") depends_on("libtool", type="build") depends_on("adios2", when="@4.5: +adios2") + + conflicts( + "%oneapi", when="@:4.3", msg="Intel oneapi compiler patch only added for version 4.4" + ) phases = ["configure", "build", "install"] def setup_run_environment(self, env): @@ -259,7 +271,13 @@ def setup_run_environment(self, env): env.append_path("PATH", self.prefix.tools) def setup_build_environment(self, env): - env.set("NETCDF", self.spec["netcdf-c"].prefix) + # From 4.5.2 the split-netcdf patches are not needed, + # just tell the build system where netcdf and netcdf-c are: + if self.spec.satisfies("@4.5.2:"): + env.set("NETCDF", self.spec["netcdf-fortran"].prefix) + env.set("NETCDF_C", self.spec["netcdf-c"].prefix) + else: + env.set("NETCDF", self.spec["netcdf-c"].prefix) if "+pnetcdf" in self.spec: env.set("PNETCDF", self.spec["parallel-netcdf"].prefix) # Add WRF-Chem module @@ -381,6 +399,9 @@ def do_configure_fixup(self): config.filter("^DM_FC.*mpif90", "DM_FC = {0}".format(self.spec["mpi"].mpifc)) config.filter("^DM_CC.*mpicc", "DM_CC = {0}".format(self.spec["mpi"].mpicc)) + if self.spec.satisfies("@:4.0.3 %intel@2018:"): + config.filter(r"-openmp", "-qopenmp") + @run_before("configure") def fortran_check(self): if not self.compiler.fc: diff --git a/var/spack/repos/builtin/packages/wrk/package.py b/var/spack/repos/builtin/packages/wrk/package.py index cb2c400a48bef4..aada2b01337f83 100644 --- a/var/spack/repos/builtin/packages/wrk/package.py +++ b/var/spack/repos/builtin/packages/wrk/package.py @@ -22,6 +22,8 @@ class Wrk(MakefilePackage): version("4.0.0", sha256="8fa8fb05f4663d03c1ca7804367eb602882f9630441bd56e8e9aaf3a2bd26067") version("3.1.2", sha256="da88a25f0eeb9e1fd6a9dcf4a96859e9e758f9446f0787cf7c95e4ccde14eefc") + depends_on("c", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install("wrk", prefix.bin) diff --git a/var/spack/repos/builtin/packages/wsmancli/package.py b/var/spack/repos/builtin/packages/wsmancli/package.py index c5e53721315324..dc1dd65951676e 100644 --- a/var/spack/repos/builtin/packages/wsmancli/package.py +++ b/var/spack/repos/builtin/packages/wsmancli/package.py @@ -17,6 +17,9 @@ class Wsmancli(AutotoolsPackage): version("2.5.0", sha256="9e60e9b21d14328feadceeaf0c3c233d7ee701e7814010ede23367a9bd5efb33") version("2.3.2", sha256="b5ffd4c4cdbcde7cf8cf84be3a3c1b92d84ffb8b492e6008a83e090c760d6c2d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/wt/package.py b/var/spack/repos/builtin/packages/wt/package.py index eb43df3d582f6c..a26ba6d7ee16a9 100644 --- a/var/spack/repos/builtin/packages/wt/package.py +++ b/var/spack/repos/builtin/packages/wt/package.py @@ -19,6 +19,9 @@ class Wt(CMakePackage): version("master", branch="master") version("3.3.7", sha256="054af8d62a7c158df62adc174a6a57610868470a07e7192ee7ce60a18552851d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # wt builds in parallel, but requires more than 5 GByte RAM per -j # which most machines do not provide and crash the build parallel = False diff --git a/var/spack/repos/builtin/packages/wtdbg2/package.py b/var/spack/repos/builtin/packages/wtdbg2/package.py index 07d9022276cc5d..f40d5e292d87ed 100644 --- a/var/spack/repos/builtin/packages/wtdbg2/package.py +++ b/var/spack/repos/builtin/packages/wtdbg2/package.py @@ -14,8 +14,11 @@ class Wtdbg2(MakefilePackage): license("GPL-3.0-only") + version("2.5", sha256="a2ffc8503d29f491a9a38ef63230d5b3c96db78377b5d25c91df511d0df06413") version("2.3", sha256="fb61d38a4c60a39b3b194e63b855141c05ddcbe71cf244ae613766a9b0a56621") + depends_on("c", type="build") # generated + depends_on("zlib-api") depends_on("sse2neon", when="target=aarch64:") @@ -27,4 +30,4 @@ def edit(self, spec, prefix): makefile.filter("-mpopcnt -msse4.2", "") def install(self, spec, prefix): - make("install", "BIN=%s" % prefix.bin) + make("install", f"BIN={prefix.bin}") diff --git a/var/spack/repos/builtin/packages/wxparaver/package.py b/var/spack/repos/builtin/packages/wxparaver/package.py index 831831e76b8cd0..8e1d9c75432630 100644 --- a/var/spack/repos/builtin/packages/wxparaver/package.py +++ b/var/spack/repos/builtin/packages/wxparaver/package.py @@ -27,6 +27,9 @@ class Wxparaver(AutotoolsPackage): version("4.7.1", sha256="8cbec0c5e0f8a849820f6682cbb0920ea234bb7f20d1483e38ea5d0b0ee045cd") version("4.7.0", sha256="81e02bcc1853455b13435172a4336ba85ba05020887d322c9678c97def03d76f") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("boost@1.36: +serialization") depends_on("wxwidgets@2.8:") # NOTE: using external for this one is usually simpler depends_on("wxpropgrid@1.4:") diff --git a/var/spack/repos/builtin/packages/wxpropgrid/package.py b/var/spack/repos/builtin/packages/wxpropgrid/package.py index b105d4f92881bd..9c725872071dc1 100644 --- a/var/spack/repos/builtin/packages/wxpropgrid/package.py +++ b/var/spack/repos/builtin/packages/wxpropgrid/package.py @@ -17,6 +17,8 @@ class Wxpropgrid(Package, SourceforgePackage): version("1.4.15", sha256="f0c9a86656828f592c8e57d2c89401f07f0af6a45b17bbca3990e8d29121c2b8") + depends_on("cxx", type="build") # generated + depends_on("wxwidgets") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/wxwidgets/package.py b/var/spack/repos/builtin/packages/wxwidgets/package.py index de62cbb39a3f59..6b896039b133bb 100644 --- a/var/spack/repos/builtin/packages/wxwidgets/package.py +++ b/var/spack/repos/builtin/packages/wxwidgets/package.py @@ -23,12 +23,17 @@ class Wxwidgets(AutotoolsPackage): git = "https://github.com/wxWidgets/wxWidgets.git" version("develop", branch="master") + version("3.2.5", sha256="0ad86a3ad3e2e519b6a705248fc9226e3a09bbf069c6c692a02acf7c2d1c6b51") + version("3.2.4", sha256="0640e1ab716db5af2ecb7389dbef6138d7679261fbff730d23845ba838ca133e") version("3.2.2.1", sha256="dffcb6be71296fff4b7f8840eb1b510178f57aa2eb236b20da41182009242c02") version("3.2.2", sha256="8edf18672b7bc0996ee6b7caa2bee017a9be604aad1ee471e243df7471f5db5d") version("3.1.0", sha256="e082460fb6bf14b7dd6e8ac142598d1d3d0b08a7b5ba402fdbf8711da7e66da8") version("3.0.2", sha256="346879dc554f3ab8d6da2704f651ecb504a22e9d31c17ef5449b129ed711585d") version("3.0.1", sha256="bd671b79ec56af8fb3844e11cafceac1a4276fb02c79404d06b91b6c19d2c5f5") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("opengl", default=False, description="Enable OpenGL support") patch("math_include.patch", when="@3.0.1:3.0.2") diff --git a/var/spack/repos/builtin/packages/x11perf/package.py b/var/spack/repos/builtin/packages/x11perf/package.py index ef3e402e6605e2..f7c94db6a96bc6 100644 --- a/var/spack/repos/builtin/packages/x11perf/package.py +++ b/var/spack/repos/builtin/packages/x11perf/package.py @@ -9,12 +9,14 @@ class X11perf(AutotoolsPackage, XorgPackage): """Simple X server performance benchmarker.""" - homepage = "https://cgit.freedesktop.org/xorg/app/x11perf" + homepage = "https://gitlab.freedesktop.org/xorg/app/x11perf" xorg_mirror_path = "app/x11perf-1.6.0.tar.gz" version("1.6.1", sha256="a1874618df0e30ae1a9b2470fb50e77a40c4a6f6ddf87a5c154f7a3b913ac0b3") version("1.6.0", sha256="d33051c4e93100ab60609aee14ff889bb2460f28945063d793e21eda19381abb") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxmu") depends_on("libxrender") diff --git a/var/spack/repos/builtin/packages/x264/package.py b/var/spack/repos/builtin/packages/x264/package.py index 5bd179b8e81330..2d222278a30135 100644 --- a/var/spack/repos/builtin/packages/x264/package.py +++ b/var/spack/repos/builtin/packages/x264/package.py @@ -13,8 +13,11 @@ class X264(AutotoolsPackage): license("GPL-2.0-or-later") + version("20240314", commit="585e01997f0c7e6d72c8ca466406d955c07de912") version("20210613", commit="5db6aa6cab1b146e07b60cc1736a01f21da01154") + depends_on("c", type="build") # generated + depends_on("nasm") def configure_args(self): diff --git a/var/spack/repos/builtin/packages/xalan-c/package.py b/var/spack/repos/builtin/packages/xalan-c/package.py index 29dfbed8fb5b15..6e01b278dab06b 100644 --- a/var/spack/repos/builtin/packages/xalan-c/package.py +++ b/var/spack/repos/builtin/packages/xalan-c/package.py @@ -22,6 +22,9 @@ class XalanC(CMakePackage): version("1.12", sha256="ee7d4b0b08c5676f5e586c7154d94a5b32b299ac3cbb946e24c4375a25552da7") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant( "transcoder", default="default", diff --git a/var/spack/repos/builtin/packages/xapian-core/package.py b/var/spack/repos/builtin/packages/xapian-core/package.py index 9117b3bb1f3774..025666420652ac 100644 --- a/var/spack/repos/builtin/packages/xapian-core/package.py +++ b/var/spack/repos/builtin/packages/xapian-core/package.py @@ -21,4 +21,7 @@ class XapianCore(AutotoolsPackage): version("1.4.11", sha256="9f16b2f3e2351a24034d7636f73566ab74c3f0729e9e0492934e956b25c5bc07") version("1.4.3", sha256="7d5295511ca2de70463a29e75f6a2393df5dc1485bf33074b778c66e1721e475") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("zlib-api") diff --git a/var/spack/repos/builtin/packages/xauth/package.py b/var/spack/repos/builtin/packages/xauth/package.py index c4a792f1d44a8d..7d233c857529ae 100644 --- a/var/spack/repos/builtin/packages/xauth/package.py +++ b/var/spack/repos/builtin/packages/xauth/package.py @@ -10,7 +10,7 @@ class Xauth(AutotoolsPackage, XorgPackage): """The xauth program is used to edit and display the authorization information used in connecting to the X server.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xauth" + homepage = "https://gitlab.freedesktop.org/xorg/app/xauth" xorg_mirror_path = "app/xauth-1.0.9.tar.gz" license("custom") @@ -21,6 +21,8 @@ class Xauth(AutotoolsPackage, XorgPackage): version("1.0.10", sha256="5196821221d824b9bc278fa6505c595acee1d374518a52217d9b64d3c63dedd0") version("1.0.9", sha256="0709070caf23ba2fb99536907b75be1fe31853999c62d3e87a6a8d26ba8a8cdb") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxau") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/xbacklight/package.py b/var/spack/repos/builtin/packages/xbacklight/package.py index 0392228ac297fc..542bbabb41a32f 100644 --- a/var/spack/repos/builtin/packages/xbacklight/package.py +++ b/var/spack/repos/builtin/packages/xbacklight/package.py @@ -12,7 +12,7 @@ class Xbacklight(AutotoolsPackage, XorgPackage): supporting backlight brightness control and changes them all in the same way.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xbacklight" + homepage = "https://gitlab.freedesktop.org/xorg/app/xbacklight" xorg_mirror_path = "app/xbacklight-1.2.1.tar.gz" license("MIT") @@ -21,6 +21,8 @@ class Xbacklight(AutotoolsPackage, XorgPackage): version("1.2.2", sha256="9812497b95b28776539808ba75e8b8a2d48a57416e172e04e9580e65c76a61bb") version("1.2.1", sha256="82c80cd851e3eb6d7a216d92465fcf6d5e456c2d5ac12c63cd2757b39fb65b10") + depends_on("c", type="build") # generated + depends_on("libxcb") depends_on("xcb-util") diff --git a/var/spack/repos/builtin/packages/xbae/package.py b/var/spack/repos/builtin/packages/xbae/package.py new file mode 100644 index 00000000000000..38b74d64af9f99 --- /dev/null +++ b/var/spack/repos/builtin/packages/xbae/package.py @@ -0,0 +1,27 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Xbae(AutotoolsPackage): + """The Xbae widget set consists of the well known XbaeMatrix widget, + and Caption and XbaeInput widgets.""" + + homepage = "https://sourceforge.net/projects/xbae/" + url = "https://sourceforge.net/projects/xbae/files/xbae/4.60.4/xbae-4.60.4.tar.gz" + + license("MIT", checked_by="wdconinc") # Old style, Bellcore variant + + version("4.60.4", sha256="eb72702ed0a36d043f2075a9d5a4545556da1b8dab4d67d85fca92f37aeb04a8") + + depends_on("c", type="build") # generated + + depends_on("libtool", type="build") + depends_on("libxext") + depends_on("libxmu") + depends_on("libxpm") + depends_on("libxt") + depends_on("motif") diff --git a/var/spack/repos/builtin/packages/xbiff/package.py b/var/spack/repos/builtin/packages/xbiff/package.py index 0e7f535e307bdd..0709fbf0e0ccaf 100644 --- a/var/spack/repos/builtin/packages/xbiff/package.py +++ b/var/spack/repos/builtin/packages/xbiff/package.py @@ -11,7 +11,7 @@ class Xbiff(AutotoolsPackage, XorgPackage): It only handles mail stored in a filesystem accessible file, not via IMAP, POP or other remote access protocols.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xbiff" + homepage = "https://gitlab.freedesktop.org/xorg/app/xbiff" xorg_mirror_path = "app/xbiff-1.0.3.tar.gz" license("X11") @@ -19,6 +19,8 @@ class Xbiff(AutotoolsPackage, XorgPackage): version("1.0.4", sha256="8a0ca5628e6893340a2448b461a103b48a174ae777500beb9a9f56f99330ce62") version("1.0.3", sha256="b4b702348674985741685e3ec7fcb5640ffb7bf20e753fc2d708f70f2e4c304d") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/xbitmaps/package.py b/var/spack/repos/builtin/packages/xbitmaps/package.py index 172f716cbc141d..87d799efe55b2a 100644 --- a/var/spack/repos/builtin/packages/xbitmaps/package.py +++ b/var/spack/repos/builtin/packages/xbitmaps/package.py @@ -10,7 +10,7 @@ class Xbitmaps(AutotoolsPackage, XorgPackage): """The xbitmaps package contains bitmap images used by multiple applications built in Xorg.""" - homepage = "https://cgit.freedesktop.org/xorg/data/bitmaps/" + homepage = "https://gitlab.freedesktop.org/xorg/data/bitmaps/" xorg_mirror_path = "data/xbitmaps-1.1.1.tar.gz" license("MIT") diff --git a/var/spack/repos/builtin/packages/xbraid/package.py b/var/spack/repos/builtin/packages/xbraid/package.py index eb845dad60f430..4f77813bc5bf68 100644 --- a/var/spack/repos/builtin/packages/xbraid/package.py +++ b/var/spack/repos/builtin/packages/xbraid/package.py @@ -13,10 +13,15 @@ class Xbraid(MakefilePackage): url = "https://github.com/XBraid/xbraid/archive/v2.2.0.tar.gz" tags = ["radiuss"] + version("3.1.0", sha256="3419b22918c65555e8c552b70a0837a251a74c471dac8e4a7b2272bf7d955c88") version("3.0.0", sha256="06988c0599cd100d3b3f3ebb183c9ad34a4021922e0896815cbedc659aaadce6") version("2.3.0", sha256="706f0acde201c7c336ade3604679759752a74e2cd6c2a29a8bf5676b6e54b704") version("2.2.0", sha256="082623b2ddcd2150b3ace65b96c1e00be637876ec6c94dc8fefda88743b35ba3") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("mpi") @when("@:2.2.0") diff --git a/var/spack/repos/builtin/packages/xcalc/package.py b/var/spack/repos/builtin/packages/xcalc/package.py index ea4145c2725f0e..c9aae5b2b17111 100644 --- a/var/spack/repos/builtin/packages/xcalc/package.py +++ b/var/spack/repos/builtin/packages/xcalc/package.py @@ -10,7 +10,7 @@ class Xcalc(AutotoolsPackage, XorgPackage): """xcalc is a scientific calculator X11 client that can emulate a TI-30 or an HP-10C.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xcalc" + homepage = "https://gitlab.freedesktop.org/xorg/app/xcalc" xorg_mirror_path = "app/xcalc-1.0.6.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Xcalc(AutotoolsPackage, XorgPackage): version("1.0.7", sha256="2b00129583f51a45acfcaaa461750169e530996e190b31f7a92891846380f1f5") version("1.0.6", sha256="7fd5cd9a35160925c41cbadfb1ea23599fa20fd26cd873dab20a650b24efe8d1") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxt") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xcb-demo/package.py b/var/spack/repos/builtin/packages/xcb-demo/package.py index f023755b03afb4..09be1af0900ee9 100644 --- a/var/spack/repos/builtin/packages/xcb-demo/package.py +++ b/var/spack/repos/builtin/packages/xcb-demo/package.py @@ -14,6 +14,8 @@ class XcbDemo(AutotoolsPackage): version("0.1", sha256="19ace2812a05313747356dc5e2331a9a6f5eb46631a26819cf30eeeaa38077f9") + depends_on("c", type="build") # generated + depends_on("libxcb") depends_on("xcb-util") depends_on("xcb-util-image") diff --git a/var/spack/repos/builtin/packages/xcb-proto/package.py b/var/spack/repos/builtin/packages/xcb-proto/package.py index 1d345d6b731475..31e87a34538591 100644 --- a/var/spack/repos/builtin/packages/xcb-proto/package.py +++ b/var/spack/repos/builtin/packages/xcb-proto/package.py @@ -6,33 +6,41 @@ from spack.package import * -class XcbProto(AutotoolsPackage): +class XcbProto(AutotoolsPackage, XorgPackage): """xcb-proto provides the XML-XCB protocol descriptions that libxcb uses to generate the majority of its code and API.""" homepage = "https://xcb.freedesktop.org/" - url = "https://xorg.freedesktop.org/archive/individual/proto/xcb-proto-1.14.1.tar.xz" + xorg_mirror_path = "proto/xcb-proto-1.14.1.tar.xz" license("MIT") maintainers("wdconinc") + version("1.17.0", sha256="2c1bacd2110f4799f74de6ebb714b94cf6f80fb112316b1219480fd22562148c") version("1.16.0", sha256="a75a1848ad2a89a82d841a51be56ce988ff3c63a8d6bf4383ae3219d8d915119") version("1.15.2", sha256="7072beb1f680a2fe3f9e535b797c146d22528990c72f63ddb49d2f350a3653ed") version("1.14.1", sha256="f04add9a972ac334ea11d9d7eb4fc7f8883835da3e4859c9afa971efdf57fcc3") version("1.14", sha256="186a3ceb26f9b4a015f5a44dcc814c93033a5fc39684f36f1ecc79834416a605") - version("1.13", sha256="0698e8f596e4c0dbad71d3dc754d95eb0edbb42df5464e0f782621216fa33ba7") - version("1.12", sha256="cfa49e65dd390233d560ce4476575e4b76e505a0e0bacdfb5ba6f8d0af53fd59") - version("1.11", sha256="d12152193bd71aabbdbb97b029717ae6d5d0477ab239614e3d6193cc0385d906") + version( + "1.13", + sha256="0698e8f596e4c0dbad71d3dc754d95eb0edbb42df5464e0f782621216fa33ba7", + url="https://xcb.freedesktop.org/dist/xcb-proto-1.13.tar.gz", + deprecated=True, + ) + version( + "1.12", + sha256="cfa49e65dd390233d560ce4476575e4b76e505a0e0bacdfb5ba6f8d0af53fd59", + url="https://xcb.freedesktop.org/dist/xcb-proto-1.12.tar.gz", + deprecated=True, + ) + version( + "1.11", + sha256="d12152193bd71aabbdbb97b029717ae6d5d0477ab239614e3d6193cc0385d906", + url="https://xcb.freedesktop.org/dist/xcb-proto-1.11.tar.gz", + deprecated=True, + ) extends("python") patch("xcb-proto-1.12-schema-1.patch", when="@1.12") - - def url_for_version(self, version): - if version >= Version("1.14"): - url = "https://xorg.freedesktop.org/archive/individual/proto/xcb-proto-{0}.tar.xz" - else: - url = "http://xcb.freedesktop.org/dist/xcb-proto-{0}.tar.gz" - - return url.format(version) diff --git a/var/spack/repos/builtin/packages/xcb-util-cursor/package.py b/var/spack/repos/builtin/packages/xcb-util-cursor/package.py index 3c408d0ed6fdd2..31b19f9a9bdab4 100644 --- a/var/spack/repos/builtin/packages/xcb-util-cursor/package.py +++ b/var/spack/repos/builtin/packages/xcb-util-cursor/package.py @@ -24,8 +24,11 @@ class XcbUtilCursor(AutotoolsPackage, XorgPackage): "0.1.3", sha256="a322332716a384c94d3cbf98f2d8fe2ce63c2fe7e2b26664b6cea1d411723df8", url="https://xcb.freedesktop.org/dist/xcb-util-cursor-0.1.4.tar.gz", + deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("libxcb@1.4:") depends_on("xcb-util-renderutil") depends_on("xcb-util-image") diff --git a/var/spack/repos/builtin/packages/xcb-util-errors/package.py b/var/spack/repos/builtin/packages/xcb-util-errors/package.py index c6f28d2ccb3ef4..0a4dea8c4b239e 100644 --- a/var/spack/repos/builtin/packages/xcb-util-errors/package.py +++ b/var/spack/repos/builtin/packages/xcb-util-errors/package.py @@ -22,8 +22,11 @@ class XcbUtilErrors(AutotoolsPackage, XorgPackage): "1.0", sha256="7752a722e580efdbada30632cb23aed35c18757399ac3b547b59fd7257cf5e33", url="https://xcb.freedesktop.org/dist/xcb-util-errors-1.0.tar.gz", + deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("libxcb@1.4:") depends_on("xcb-proto") diff --git a/var/spack/repos/builtin/packages/xcb-util-image/package.py b/var/spack/repos/builtin/packages/xcb-util-image/package.py index ecd793cb640080..0702e1e36d941c 100644 --- a/var/spack/repos/builtin/packages/xcb-util-image/package.py +++ b/var/spack/repos/builtin/packages/xcb-util-image/package.py @@ -24,8 +24,11 @@ class XcbUtilImage(AutotoolsPackage, XorgPackage): "0.4.0", sha256="cb2c86190cf6216260b7357a57d9100811bb6f78c24576a3a5bfef6ad3740a42", url="https://xcb.freedesktop.org/dist/xcb-util-image-0.4.0.tar.gz", + deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("libxcb@1.4:") depends_on("xcb-util") diff --git a/var/spack/repos/builtin/packages/xcb-util-keysyms/package.py b/var/spack/repos/builtin/packages/xcb-util-keysyms/package.py index e7c19ebb57fdec..af65e8994abb6c 100644 --- a/var/spack/repos/builtin/packages/xcb-util-keysyms/package.py +++ b/var/spack/repos/builtin/packages/xcb-util-keysyms/package.py @@ -24,8 +24,11 @@ class XcbUtilKeysyms(AutotoolsPackage, XorgPackage): "0.4.0", sha256="0807cf078fbe38489a41d755095c58239e1b67299f14460dec2ec811e96caa96", url="https://xcb.freedesktop.org/dist/xcb-util-keysyms-0.4.0.tar.gz", + deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("libxcb@1.4:") depends_on("xproto@7.0.8:") diff --git a/var/spack/repos/builtin/packages/xcb-util-renderutil/package.py b/var/spack/repos/builtin/packages/xcb-util-renderutil/package.py index 6ae06aa0bdc46c..59fa41039a667e 100644 --- a/var/spack/repos/builtin/packages/xcb-util-renderutil/package.py +++ b/var/spack/repos/builtin/packages/xcb-util-renderutil/package.py @@ -24,8 +24,11 @@ class XcbUtilRenderutil(AutotoolsPackage, XorgPackage): "0.3.9", sha256="55eee797e3214fe39d0f3f4d9448cc53cffe06706d108824ea37bb79fcedcad5", url="https://xcb.freedesktop.org/dist/xcb-util-renderutil-0.3.9.tar.gz", + deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("libxcb@1.4:") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/xcb-util-wm/package.py b/var/spack/repos/builtin/packages/xcb-util-wm/package.py index 3f825e83b5db3c..b6386eb8035f0a 100644 --- a/var/spack/repos/builtin/packages/xcb-util-wm/package.py +++ b/var/spack/repos/builtin/packages/xcb-util-wm/package.py @@ -24,8 +24,11 @@ class XcbUtilWm(AutotoolsPackage, XorgPackage): "0.4.1", sha256="038b39c4bdc04a792d62d163ba7908f4bb3373057208c07110be73c1b04b8334", url="https://xcb.freedesktop.org/dist/xcb-util-wm-0.4.1.tar.gz", + deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("m4", type="build") depends_on("libxcb@1.4:") diff --git a/var/spack/repos/builtin/packages/xcb-util-xrm/package.py b/var/spack/repos/builtin/packages/xcb-util-xrm/package.py index cdf160d1491e8c..3eda838445698e 100644 --- a/var/spack/repos/builtin/packages/xcb-util-xrm/package.py +++ b/var/spack/repos/builtin/packages/xcb-util-xrm/package.py @@ -19,6 +19,8 @@ class XcbUtilXrm(AutotoolsPackage): # in order to build it. version("1.2", tag="v1.2", commit="a45b3d0bbaa94bf8a68405ab8c5c61404da464ce", submodules=True) + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/xcb-util/package.py b/var/spack/repos/builtin/packages/xcb-util/package.py index 65f539510fef62..060bdba882a70b 100644 --- a/var/spack/repos/builtin/packages/xcb-util/package.py +++ b/var/spack/repos/builtin/packages/xcb-util/package.py @@ -26,6 +26,8 @@ class XcbUtil(AutotoolsPackage, XorgPackage): url="https://xcb.freedesktop.org/dist/xcb-util-0.4.0.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("libxcb@1.4:") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/xcdf/package.py b/var/spack/repos/builtin/packages/xcdf/package.py index 8de53544631fc7..2ab94a4c365816 100644 --- a/var/spack/repos/builtin/packages/xcdf/package.py +++ b/var/spack/repos/builtin/packages/xcdf/package.py @@ -17,6 +17,8 @@ class Xcdf(CMakePackage): version("3.01", sha256="39fe816f40d6af18e16e71ffcf958258fdac4959ac894a60d1b863efaa57754e") version("3.00.03", sha256="4e445a2fea947ba14505d08177c8d5b55856f8411f28de1fe4d4c00f6824b711") + depends_on("cxx", type="build") # generated + patch("remove_python_support.patch", when="@3.00.03") depends_on("python@3.7:", when="@3.01:") diff --git a/var/spack/repos/builtin/packages/xcfun/package.py b/var/spack/repos/builtin/packages/xcfun/package.py index 737e8b356ed862..8c9b0440deb753 100644 --- a/var/spack/repos/builtin/packages/xcfun/package.py +++ b/var/spack/repos/builtin/packages/xcfun/package.py @@ -22,6 +22,10 @@ class Xcfun(CMakePackage): version("2.0.1", sha256="719383c3fffdd5da5b005f56ffd97457b0b2fb48317e955263ef5384d53ddfca") version("2.0.0", sha256="34398e935c522d0b55e1803fd6116e7cd40677d1add8894ef08362361705cf25") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + extends("python") depends_on("cmake@3.14:", type="build") depends_on("python@3:") diff --git a/var/spack/repos/builtin/packages/xclip/package.py b/var/spack/repos/builtin/packages/xclip/package.py index 9335a847299565..0cd0e9c16e0cdc 100644 --- a/var/spack/repos/builtin/packages/xclip/package.py +++ b/var/spack/repos/builtin/packages/xclip/package.py @@ -21,6 +21,8 @@ class Xclip(AutotoolsPackage): version("0.13", commit="9aa7090c3b8b437c6489edca32ae43d82e0c1281") + depends_on("c", type="build") # generated + depends_on("libxmu") depends_on("libx11") depends_on("autoconf", type="build") diff --git a/var/spack/repos/builtin/packages/xclipboard/package.py b/var/spack/repos/builtin/packages/xclipboard/package.py index df29c0afefccb3..f9c14f6edb3f11 100644 --- a/var/spack/repos/builtin/packages/xclipboard/package.py +++ b/var/spack/repos/builtin/packages/xclipboard/package.py @@ -12,12 +12,14 @@ class Xclipboard(AutotoolsPackage, XorgPackage): CLIPBOARD selections for later use. It stores each CLIPBOARD selection as a separate string, each of which can be selected.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xclipboard" + homepage = "https://gitlab.freedesktop.org/xorg/app/xclipboard" xorg_mirror_path = "app/xclipboard-1.1.3.tar.gz" version("1.1.4", sha256="c40cb97f6c8597ba74a3de5c188d4429f686e4d395b85dac0ec8c7311bdf3d10") version("1.1.3", sha256="a8c335cf166cbb27ff86569503db7e639f85741ad199bfb3ba45dd0cfda3da7f") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libxt@1.1:") diff --git a/var/spack/repos/builtin/packages/xclock/package.py b/var/spack/repos/builtin/packages/xclock/package.py index d7f3ff4c9c8d99..8b74db2e60d280 100644 --- a/var/spack/repos/builtin/packages/xclock/package.py +++ b/var/spack/repos/builtin/packages/xclock/package.py @@ -11,7 +11,7 @@ class Xclock(AutotoolsPackage, XorgPackage): the time in analog or digital form, continuously updated at a frequency which may be specified by the user.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xclock" + homepage = "https://gitlab.freedesktop.org/xorg/app/xclock" xorg_mirror_path = "app/xclock-1.0.7.tar.gz" license("MIT") @@ -22,6 +22,8 @@ class Xclock(AutotoolsPackage, XorgPackage): version("1.0.8", sha256="bb6f2439e6037759dc1682d80a3fe0232e7b55aa9b38548203e746d290b246bd") version("1.0.7", sha256="e730bd575938d5628ef47003a9d4d41b882621798227f5d0c12f4a26365ed1b5") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xcmiscproto/package.py b/var/spack/repos/builtin/packages/xcmiscproto/package.py index d358bc2b9c8519..0cd8d9999fcdba 100644 --- a/var/spack/repos/builtin/packages/xcmiscproto/package.py +++ b/var/spack/repos/builtin/packages/xcmiscproto/package.py @@ -12,7 +12,7 @@ class Xcmiscproto(AutotoolsPackage, XorgPackage): This extension defines a protocol that provides Xlib two ways to query the server for available resource IDs.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/xcmiscproto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/xcmiscproto" xorg_mirror_path = "proto/xcmiscproto-1.2.2.tar.gz" version("1.2.2", sha256="48013cfbe4bd5580925a854a43e2bccbb4c7a5a31128070644617b6dc7f8ef85") diff --git a/var/spack/repos/builtin/packages/xcmsdb/package.py b/var/spack/repos/builtin/packages/xcmsdb/package.py index 4537b3f4383591..a918e086e55724 100644 --- a/var/spack/repos/builtin/packages/xcmsdb/package.py +++ b/var/spack/repos/builtin/packages/xcmsdb/package.py @@ -12,7 +12,7 @@ class Xcmsdb(AutotoolsPackage, XorgPackage): specified in section 7, Device Color Characterization, of the X11 Inter-Client Communication Conventions Manual (ICCCM).""" - homepage = "https://cgit.freedesktop.org/xorg/app/xcmsdb" + homepage = "https://gitlab.freedesktop.org/xorg/app/xcmsdb" xorg_mirror_path = "app/xcmsdb-1.0.5.tar.gz" license("custom") @@ -20,6 +20,8 @@ class Xcmsdb(AutotoolsPackage, XorgPackage): version("1.0.6", sha256="640b42c746eb34bdd71ca2850f2bc9fb0ade194c9f152a8d002425a0684df077") version("1.0.5", sha256="8442352ee5eb3ea0d3a489c26d734e784ef6964150c2a173401d0dc6638ca236") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/xcompmgr/package.py b/var/spack/repos/builtin/packages/xcompmgr/package.py index d555c4369c9963..3fcb79a1d1f8f2 100644 --- a/var/spack/repos/builtin/packages/xcompmgr/package.py +++ b/var/spack/repos/builtin/packages/xcompmgr/package.py @@ -11,7 +11,7 @@ class Xcompmgr(AutotoolsPackage, XorgPackage): XFIXES, DAMAGE, RENDER, and COMPOSITE extensions. It enables basic eye-candy effects.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xcompmgr" + homepage = "https://gitlab.freedesktop.org/xorg/app/xcompmgr" xorg_mirror_path = "app/xcompmgr-1.1.7.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Xcompmgr(AutotoolsPackage, XorgPackage): version("1.1.8", sha256="ba10933678a5665d06fa7096bd08f37316add8ed84aaacd7ba26a97e8f2e0498") version("1.1.7", sha256="ef4b23c370f99403bbd9b6227f8aa4edc3bc83fc6d57ee71f6f442397cef505a") + depends_on("c", type="build") # generated + depends_on("libxcomposite") depends_on("libxfixes") depends_on("libxdamage") diff --git a/var/spack/repos/builtin/packages/xconsole/package.py b/var/spack/repos/builtin/packages/xconsole/package.py index 2a8b3fecc42899..b22ae751d821e7 100644 --- a/var/spack/repos/builtin/packages/xconsole/package.py +++ b/var/spack/repos/builtin/packages/xconsole/package.py @@ -10,13 +10,16 @@ class Xconsole(AutotoolsPackage, XorgPackage): """xconsole displays in a X11 window the messages which are usually sent to /dev/console.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xconsole" + homepage = "https://gitlab.freedesktop.org/xorg/app/xconsole" xorg_mirror_path = "app/xconsole-1.0.6.tar.gz" + version("1.1.0", sha256="fe5d2ba99b754909b2a04ce4abf054cd1e3134a830d69aea82e8465cc9f73942") version("1.0.8", sha256="1897be35738489f92ef511caef189db8d5079469374021dc09b59e89992b7c29") version("1.0.7", sha256="91bc7327643b1ca57800a37575930af16fbea485d426a96d8f465de570aa6eb3") version("1.0.6", sha256="28151453a0a687462516de133bac0287b488a2ff56da78331fee34bc1bf3e7d5") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libxt@1.0:") diff --git a/var/spack/repos/builtin/packages/xcursor-themes/package.py b/var/spack/repos/builtin/packages/xcursor-themes/package.py index 316e7e42db1b8a..dedf61d02204e2 100644 --- a/var/spack/repos/builtin/packages/xcursor-themes/package.py +++ b/var/spack/repos/builtin/packages/xcursor-themes/package.py @@ -11,9 +11,12 @@ class XcursorThemes(Package, XorgPackage): originally created for the XFree86 Project, and now shipped as part of the X.Org software distribution.""" - homepage = "https://cgit.freedesktop.org/xorg/data/cursors" + homepage = "https://gitlab.freedesktop.org/xorg/data/cursors" xorg_mirror_path = "data/xcursor-themes-1.0.4.tar.gz" + version("1.0.7", sha256="dcb68b6265235db3064a4427e2bc5ae0d30f21f7468dd7534553715d1c39d009") + version("1.0.6", sha256="22638f7bd6257adf889d25af9c8a7b2cfdcf5a5e18339d25fbb092dbf6c663c1") + version("1.0.5", sha256="85636a3774debe830a15b9cd3c438171356fb451d7e3667212777a55d88f7897") version("1.0.4", sha256="8ed23bab13a4010fe4e95b37eefb634e31ac7cb8240b8b3b7d919c3a2db09503") depends_on("libxcursor") @@ -21,6 +24,7 @@ class XcursorThemes(Package, XorgPackage): depends_on("xcursorgen", type="build") depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") + depends_on("util-macros@1.20:", type="build", when="@1.0.7:") def install(self, spec, prefix): configure("--prefix={0}".format(prefix)) diff --git a/var/spack/repos/builtin/packages/xcursorgen/package.py b/var/spack/repos/builtin/packages/xcursorgen/package.py index 0a082116b1b833..6672be219fae22 100644 --- a/var/spack/repos/builtin/packages/xcursorgen/package.py +++ b/var/spack/repos/builtin/packages/xcursorgen/package.py @@ -9,13 +9,15 @@ class Xcursorgen(AutotoolsPackage, XorgPackage): """xcursorgen prepares X11 cursor sets for use with libXcursor.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xcursorgen" + homepage = "https://gitlab.freedesktop.org/xorg/app/xcursorgen" xorg_mirror_path = "app/xcursorgen-1.0.6.tar.gz" version("1.0.8", sha256="b8bb2756918343b8bc15a4ce875e9efb6c4e7777adba088280e53dd09753b6ac") version("1.0.7", sha256="6bc32d4977ffd60c00583bfd217f1d1245ca54dafbfbbcdbf14f696f9487b83e") version("1.0.6", sha256="4559f2b6eaa93de4cb6968679cf40e39bcbe969b62ebf3ff84f6780f8048ef8c") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxcursor") depends_on("libpng@1.2.0:") diff --git a/var/spack/repos/builtin/packages/xdbedizzy/package.py b/var/spack/repos/builtin/packages/xdbedizzy/package.py index 22e8a1de489a1f..1945ac1911682c 100644 --- a/var/spack/repos/builtin/packages/xdbedizzy/package.py +++ b/var/spack/repos/builtin/packages/xdbedizzy/package.py @@ -10,11 +10,13 @@ class Xdbedizzy(AutotoolsPackage, XorgPackage): """xdbedizzy is a demo of the X11 Double Buffer Extension (DBE) creating a double buffered spinning scene.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xdbedizzy" + homepage = "https://gitlab.freedesktop.org/xorg/app/xdbedizzy" xorg_mirror_path = "app/xdbedizzy-1.1.0.tar.gz" version("1.1.0", sha256="810e88b087b76f8b5993db4fc5165de3e5d29b0d4bf0e893750ee408fc7a5c0a") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/xdelta/package.py b/var/spack/repos/builtin/packages/xdelta/package.py index 551a4d2cba4bfa..eeba577cffc387 100644 --- a/var/spack/repos/builtin/packages/xdelta/package.py +++ b/var/spack/repos/builtin/packages/xdelta/package.py @@ -17,6 +17,9 @@ class Xdelta(AutotoolsPackage): version("3.0.11", sha256="28278a4d73127f3d2b00bbde179f8ee1f289ccd3f7f2ac7cd837f6580f90a7b7") version("3.0.10", sha256="a3f9c177ec2b91e6d8ec82ee7f0bcbbb2d18fed7d743d7577a990c01235e657d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/xditview/package.py b/var/spack/repos/builtin/packages/xditview/package.py index 48e809ab3ad132..4c0c9790b3ab9b 100644 --- a/var/spack/repos/builtin/packages/xditview/package.py +++ b/var/spack/repos/builtin/packages/xditview/package.py @@ -9,7 +9,7 @@ class Xditview(AutotoolsPackage, XorgPackage): """xditview displays ditroff output on an X display.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xditview" + homepage = "https://gitlab.freedesktop.org/xorg/app/xditview" xorg_mirror_path = "app/xditview-1.0.4.tar.gz" license("X11") @@ -18,6 +18,8 @@ class Xditview(AutotoolsPackage, XorgPackage): version("1.0.5", sha256="67c4522a24dd7e8762ae458fe216c5bddc12101af295e78c19ff7313fa8cbfad") version("1.0.4", sha256="73ad88cfc879edcc6ede65999c11d670da27575388126795d71f3ad60286d379") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xdm/package.py b/var/spack/repos/builtin/packages/xdm/package.py index 7b811992aeb59a..909b877c394634 100644 --- a/var/spack/repos/builtin/packages/xdm/package.py +++ b/var/spack/repos/builtin/packages/xdm/package.py @@ -9,16 +9,19 @@ class Xdm(AutotoolsPackage, XorgPackage): """X Display Manager / XDMCP server.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xdm" + homepage = "https://gitlab.freedesktop.org/xorg/app/xdm" xorg_mirror_path = "app/xdm-1.1.11.tar.gz" license("MIT") + version("1.1.16", sha256="931013642b7fab893f374eb1aa6f9ad043c88b654802fc51f841cea76aff44e0") version("1.1.14", sha256="bcc543c3c120094d58d9cc9837958d4303693c2116ba342ba3dd9440137b4026") version("1.1.13", sha256="2f05aa58c205dcf10443ba414d27535b74ec11466dc95228343b0ce4f0c2a307") version("1.1.12", sha256="8ea737945f69e172afbbc8b5060e4c7ea8079f402eb0a458572197c907020bb4") version("1.1.11", sha256="38c544a986143b1f24566c1a0111486b339b92224b927be78714eeeedca12a14") + depends_on("c", type="build") # generated + depends_on("libxmu") depends_on("libx11") depends_on("libxau") diff --git a/var/spack/repos/builtin/packages/xdmf3/package.py b/var/spack/repos/builtin/packages/xdmf3/package.py index 22a6d923455226..4909c669e3437d 100644 --- a/var/spack/repos/builtin/packages/xdmf3/package.py +++ b/var/spack/repos/builtin/packages/xdmf3/package.py @@ -22,6 +22,10 @@ class Xdmf3(CMakePackage): # but the current version, 3.x, is maintained on the master branch. version("2019-01-14", commit="8d9c98081d89ac77a132d56bc8bef53581db4078") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("shared", default=True, description="Enable shared libraries") variant("mpi", default=True, description="Enable MPI") diff --git a/var/spack/repos/builtin/packages/xdotool/package.py b/var/spack/repos/builtin/packages/xdotool/package.py index 66df65bb4784ff..877e9241873927 100644 --- a/var/spack/repos/builtin/packages/xdotool/package.py +++ b/var/spack/repos/builtin/packages/xdotool/package.py @@ -30,6 +30,8 @@ class Xdotool(MakefilePackage): "3.20150503.1", sha256="e8326883bd5e91bede7336cbee186e6e9143f40b3fb61c84afc9bb31b87e96d1" ) + depends_on("c", type="build") # generated + depends_on("libxext") depends_on("libxtst") depends_on("libxi") diff --git a/var/spack/repos/builtin/packages/xdpyinfo/package.py b/var/spack/repos/builtin/packages/xdpyinfo/package.py index 9cf8c460cd5a17..b558de378daddf 100644 --- a/var/spack/repos/builtin/packages/xdpyinfo/package.py +++ b/var/spack/repos/builtin/packages/xdpyinfo/package.py @@ -14,7 +14,7 @@ class Xdpyinfo(AutotoolsPackage, XorgPackage): and the server, and the different types of screens, visuals, and X11 protocol extensions that are available.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xdpyinfo" + homepage = "https://gitlab.freedesktop.org/xorg/app/xdpyinfo" xorg_mirror_path = "app/xdpyinfo-1.3.2.tar.gz" license("custom") @@ -22,6 +22,8 @@ class Xdpyinfo(AutotoolsPackage, XorgPackage): version("1.3.3", sha256="2ae7b8213ea839b8376843477496276e8d69550c48bff081e16376539fc27c5a") version("1.3.2", sha256="ef39935e8e9b328e54a85d6218d410d6939482da6058db1ee1b39749d98cbcf2") + depends_on("c", type="build") # generated + depends_on("libxext") depends_on("libx11") depends_on("libxtst") diff --git a/var/spack/repos/builtin/packages/xdriinfo/package.py b/var/spack/repos/builtin/packages/xdriinfo/package.py index d9d1b15ec36a14..b0ed3d5f9852d1 100644 --- a/var/spack/repos/builtin/packages/xdriinfo/package.py +++ b/var/spack/repos/builtin/packages/xdriinfo/package.py @@ -9,7 +9,7 @@ class Xdriinfo(AutotoolsPackage, XorgPackage): """xdriinfo - query configuration information of X11 DRI drivers.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xdriinfo" + homepage = "https://gitlab.freedesktop.org/xorg/app/xdriinfo" xorg_mirror_path = "app/xdriinfo-1.0.5.tar.gz" license("custom") @@ -18,6 +18,8 @@ class Xdriinfo(AutotoolsPackage, XorgPackage): version("1.0.6", sha256="c59d1d97d8b1066ea470407237c87fb131ca9f6c4db4652a6e9461ae03c698ad") version("1.0.5", sha256="e4e6abaa4591c540ab63133927a6cebf0a5f4d27dcd978878ab4a422d62a838e") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("expat") depends_on("libxshmfence") diff --git a/var/spack/repos/builtin/packages/xedit/package.py b/var/spack/repos/builtin/packages/xedit/package.py index dad2b3cdec2737..07bfc8ff269416 100644 --- a/var/spack/repos/builtin/packages/xedit/package.py +++ b/var/spack/repos/builtin/packages/xedit/package.py @@ -9,7 +9,7 @@ class Xedit(AutotoolsPackage, XorgPackage): """Xedit is a simple text editor for X.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xedit" + homepage = "https://gitlab.freedesktop.org/xorg/app/xedit" xorg_mirror_path = "app/xedit-1.2.2.tar.gz" license("BSD-3-Clause") @@ -17,6 +17,8 @@ class Xedit(AutotoolsPackage, XorgPackage): version("1.2.3", sha256="3c8be175613f72858b24d973b0d66ae2d3c9a48a5f0bd637920d85b283feede7") version("1.2.2", sha256="7e2dacbc2caed81d462ee028e108866893217d55e35e4b860b09be2b409ee18f") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libxt@1.0:") diff --git a/var/spack/repos/builtin/packages/xeniumranger/package.py b/var/spack/repos/builtin/packages/xeniumranger/package.py new file mode 100644 index 00000000000000..d08ceb553d7207 --- /dev/null +++ b/var/spack/repos/builtin/packages/xeniumranger/package.py @@ -0,0 +1,38 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +import os + +from spack.package import * + + +class Xeniumranger(Package): + """The Xenium In Situ software suite is a set of software applications for analyzing and + visualizing in situ gene expression data produced by the Xenium Analyzer. Xenium Ranger + provides flexible off-instrument reanalysis of Xenium In Situ data. + + This package requires the user to accept a license and to download the tarball manually. + Once downloaded, the file should be placed within a manual mirror or within the current + directory. For instructions on making a manual mirror, see + https://spack.readthedocs.io/en/latest/mirrors.html""" + + homepage = "https://www.10xgenomics.com/support/software/xenium-ranger/latest" + manual_download = True + license_url = "support.10xgenomics.com/license" + + version("1.7.1", sha256="3bfa85de75ef473b54a5a6d853649999e446f2f00cc202750bb22af5078965a1") + + # xeniumranger is distributed as precompiled binaries that are not compatible with + # processors without the avx instruction set ... + # https://www.10xgenomics.com/support/software/xenium-ranger/downloads/XR-system-requirements + conflicts("target=:k10") # last AMD processor not to support avx + conflicts("target=:westmere") # last Intel processor not to support avx + conflicts("target=:x86_64_v2") # last generic architecture not to support avx + + def url_for_version(self, version): + return "file://{0}/xeniumranger-{1}.tar.gz".format(os.getcwd(), version) + + def install(self, spec, prefix): + install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/xerces-c/package.py b/var/spack/repos/builtin/packages/xerces-c/package.py index 5c42b25cb59abf..a62f25746e37fc 100644 --- a/var/spack/repos/builtin/packages/xerces-c/package.py +++ b/var/spack/repos/builtin/packages/xerces-c/package.py @@ -20,6 +20,7 @@ class XercesC(AutotoolsPackage): license("Apache-2.0") + version("3.2.5", sha256="1db4028c9b7f1f778efbf4a9462d65e13f9938f2c22f9e9994e12c49ba97e252") version("3.2.4", sha256="74aa626fc71e729ee227602870dd29a5a01cd8c9c1c7330837a51da2eb5722cc") version("3.2.3", sha256="45c2329e684405f2b8854ecbddfb8d5b055cdf0fe4d35736cc352c504989bbb6") version("3.2.2", sha256="1f2a4d1dbd0086ce0f52b718ac0fa4af3dc1ce7a7ff73a581a05fbe78a82bce0") @@ -27,6 +28,9 @@ class XercesC(AutotoolsPackage): version("3.1.4", sha256="9408f12c1628ecf80730bedbe8b2caad810edd01bb4c66f77b60c873e8cc6891") version("3.1.3", sha256="fc5e5e0247b108b8d64d75aeb124cabdee9b7fcd725a89fe2242b4637b25c1fa") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + # Whilst still using Autotools, can use full cxxstd with 'default' # If build is moved to CMake, then will also need a patch to Xerces-C's # CMakeLists.txt as a specific standard cannot be forced diff --git a/var/spack/repos/builtin/packages/xeus/package.py b/var/spack/repos/builtin/packages/xeus/package.py index ab4cd48d19bfea..624835fc75992d 100644 --- a/var/spack/repos/builtin/packages/xeus/package.py +++ b/var/spack/repos/builtin/packages/xeus/package.py @@ -22,6 +22,8 @@ class Xeus(CMakePackage): version("0.15.0", sha256="bc99235b24d5757dc129f3ed531501fb0d0667913927ed39ee24281952649183") version("0.14.1", sha256="a6815845d4522ec279f142d3b4e92ef52cd80847b512146a65f256a77e058cfe") + depends_on("cxx", type="build") # generated + variant("examples", default=False, description="Build examples") variant("shared", default=True, description="Build shared libraries") diff --git a/var/spack/repos/builtin/packages/xev/package.py b/var/spack/repos/builtin/packages/xev/package.py index e6c418d4c77b0e..f5db651986b50f 100644 --- a/var/spack/repos/builtin/packages/xev/package.py +++ b/var/spack/repos/builtin/packages/xev/package.py @@ -15,16 +15,19 @@ class Xev(AutotoolsPackage, XorgPackage): debugging and development tool, and should not be needed in normal usage.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xev" + homepage = "https://gitlab.freedesktop.org/xorg/app/xev" xorg_mirror_path = "app/xev-1.2.2.tar.gz" license("MIT") + version("1.2.6", sha256="e2e3527023017af3a9bfbef0a90f8e46ac354c506b51f0ee3834b30823e43b25") version("1.2.5", sha256="a948974ede621a8402ed9ea64f1ec83992285aa4fbb9d40b52985156c61a358a") version("1.2.4", sha256="6b1f94813f008a4ba45e0a2d4e1b64deaab1def56fabd7fac3621106cbaa3383") version("1.2.3", sha256="a3c5fbf339f43ba625a6d84e52ab1a7170581505ef498be6aa4e7bdfbd8d5cef") version("1.2.2", sha256="e4c0c7b6f411e8b9731f2bb10d729d167bd00480d172c28b62607a6ea9e45c57") + depends_on("c", type="build") # generated + depends_on("libxrandr@1.2:") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xextproto/package.py b/var/spack/repos/builtin/packages/xextproto/package.py index 1b5f4ca83efc8f..47dc4a4df24520 100644 --- a/var/spack/repos/builtin/packages/xextproto/package.py +++ b/var/spack/repos/builtin/packages/xextproto/package.py @@ -9,7 +9,7 @@ class Xextproto(AutotoolsPackage, XorgPackage): """X Protocol Extensions.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/xextproto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/xextproto" xorg_mirror_path = "proto/xextproto-7.3.0.tar.gz" version("7.3.0", sha256="1b1bcdf91221e78c6c33738667a57bd9aaa63d5953174ad8ed9929296741c9f5") diff --git a/var/spack/repos/builtin/packages/xeyes/package.py b/var/spack/repos/builtin/packages/xeyes/package.py index 8d72001bb563c4..711ee12c490f42 100644 --- a/var/spack/repos/builtin/packages/xeyes/package.py +++ b/var/spack/repos/builtin/packages/xeyes/package.py @@ -9,7 +9,7 @@ class Xeyes(AutotoolsPackage, XorgPackage): """xeyes - a follow the mouse X demo, using the X SHAPE extension""" - homepage = "https://cgit.freedesktop.org/xorg/app/xeyes" + homepage = "https://gitlab.freedesktop.org/xorg/app/xeyes" xorg_mirror_path = "app/xeyes-1.1.1.tar.gz" license("MIT") @@ -18,6 +18,8 @@ class Xeyes(AutotoolsPackage, XorgPackage): version("1.1.2", sha256="4a675b34854da362bd8dff4f21ff92e0c19798b128ea0af24b7fc7c5ac2feea3") version("1.1.1", sha256="3a1871a560ab87c72a2e2ecb7fd582474448faec3e254c9bd8bead428ab1bca3") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxt") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/xf86bigfontproto/package.py b/var/spack/repos/builtin/packages/xf86bigfontproto/package.py index 7ef9adf3273b73..0504e17e492588 100644 --- a/var/spack/repos/builtin/packages/xf86bigfontproto/package.py +++ b/var/spack/repos/builtin/packages/xf86bigfontproto/package.py @@ -9,7 +9,7 @@ class Xf86bigfontproto(AutotoolsPackage, XorgPackage): """X.org XF86BigFontProto protocol headers.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/xf86bigfontproto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/xf86bigfontproto" xorg_mirror_path = "proto/xf86bigfontproto-1.2.0.tar.gz" version("1.2.0", sha256="d190e6462b2bbbac6ee9a007fb8eccb9ad9f5f70544154f388266f031d4bbb23") diff --git a/var/spack/repos/builtin/packages/xf86dga/package.py b/var/spack/repos/builtin/packages/xf86dga/package.py index 64a48a6b0889c1..4400f34a3dc636 100644 --- a/var/spack/repos/builtin/packages/xf86dga/package.py +++ b/var/spack/repos/builtin/packages/xf86dga/package.py @@ -9,11 +9,13 @@ class Xf86dga(AutotoolsPackage, XorgPackage): """dga is a simple test client for the XFree86-DGA extension.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xf86dga" + homepage = "https://gitlab.freedesktop.org/xorg/app/xf86dga" xorg_mirror_path = "app/xf86dga-1.0.3.tar.gz" version("1.0.3", sha256="acbf89f60a99b18c161d2beb0e4145a0fdf6c516f7f45fa52e547d88491f75c9") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxxf86dga@1.1:") diff --git a/var/spack/repos/builtin/packages/xf86dgaproto/package.py b/var/spack/repos/builtin/packages/xf86dgaproto/package.py index 7242c4c3ba9875..e60bdb49423a29 100644 --- a/var/spack/repos/builtin/packages/xf86dgaproto/package.py +++ b/var/spack/repos/builtin/packages/xf86dgaproto/package.py @@ -9,7 +9,7 @@ class Xf86dgaproto(AutotoolsPackage, XorgPackage): """X.org XF86DGAProto protocol headers.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/xf86dgaproto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/xf86dgaproto" xorg_mirror_path = "proto/xf86dgaproto-2.1.tar.gz" version("2.1", sha256="73bc6fc830cce5a0ec9c750d4702601fc0fca12d6353ede8b4c0092c9c4ca2af") diff --git a/var/spack/repos/builtin/packages/xf86driproto/package.py b/var/spack/repos/builtin/packages/xf86driproto/package.py index 953be0c91295a8..defa0dd09213e8 100644 --- a/var/spack/repos/builtin/packages/xf86driproto/package.py +++ b/var/spack/repos/builtin/packages/xf86driproto/package.py @@ -13,7 +13,7 @@ class Xf86driproto(AutotoolsPackage, XorgPackage): the video hardware without requiring data to be passed through the X server.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/xf86driproto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/xf86driproto" xorg_mirror_path = "proto/xf86driproto-2.1.1.tar.gz" license("MIT") diff --git a/var/spack/repos/builtin/packages/xf86miscproto/package.py b/var/spack/repos/builtin/packages/xf86miscproto/package.py index 69de74bb79465d..7487eb933cae2d 100644 --- a/var/spack/repos/builtin/packages/xf86miscproto/package.py +++ b/var/spack/repos/builtin/packages/xf86miscproto/package.py @@ -12,7 +12,7 @@ class Xf86miscproto(AutotoolsPackage, XorgPackage): supported by the XFree86 X server and versions of the Xorg X server prior to Xorg 1.6.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/xf86miscproto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/xf86miscproto" xorg_mirror_path = "proto/xf86miscproto-0.9.3.tar.gz" version("0.9.3", sha256="1b05cb76ac165c703b82bdd270b86ebbc4d42a7d04d299050b07ba2099c31352") diff --git a/var/spack/repos/builtin/packages/xf86rushproto/package.py b/var/spack/repos/builtin/packages/xf86rushproto/package.py index 4ad729f9155a2d..9ac71210a3c709 100644 --- a/var/spack/repos/builtin/packages/xf86rushproto/package.py +++ b/var/spack/repos/builtin/packages/xf86rushproto/package.py @@ -9,7 +9,7 @@ class Xf86rushproto(AutotoolsPackage, XorgPackage): """X.org XF86RushProto protocol headers.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/xf86rushproto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/xf86rushproto" xorg_mirror_path = "proto/xf86rushproto-1.1.2.tar.gz" version("1.1.2", sha256="7d420ae7e5f0dd94c6010c764c66acc93eed7df7f81bcf93d2a57739970ec841") diff --git a/var/spack/repos/builtin/packages/xf86vidmodeproto/package.py b/var/spack/repos/builtin/packages/xf86vidmodeproto/package.py index 1f310726d2e3da..65feeed2876407 100644 --- a/var/spack/repos/builtin/packages/xf86vidmodeproto/package.py +++ b/var/spack/repos/builtin/packages/xf86vidmodeproto/package.py @@ -12,7 +12,7 @@ class Xf86vidmodeproto(AutotoolsPackage, XorgPackage): This extension defines a protocol for dynamically configuring modelines and gamma.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/xf86vidmodeproto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/xf86vidmodeproto" xorg_mirror_path = "proto/xf86vidmodeproto-2.3.1.tar.gz" version("2.3.1", sha256="c3512b11cefa7558576551f8582c6e7071c8a24d78176059d94b84b48b262979") diff --git a/var/spack/repos/builtin/packages/xfd/package.py b/var/spack/repos/builtin/packages/xfd/package.py index e5a69e915920d3..1d11e330aad93b 100644 --- a/var/spack/repos/builtin/packages/xfd/package.py +++ b/var/spack/repos/builtin/packages/xfd/package.py @@ -10,7 +10,7 @@ class Xfd(AutotoolsPackage, XorgPackage): """xfd - display all the characters in a font using either the X11 core protocol or libXft2.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xfd" + homepage = "https://gitlab.freedesktop.org/xorg/app/xfd" xorg_mirror_path = "app/xfd-1.1.2.tar.gz" license("X11") @@ -19,6 +19,8 @@ class Xfd(AutotoolsPackage, XorgPackage): version("1.1.3", sha256="4a1bd18f324c239b1a807ed4ccaeb172ba771d65a7307fb492d8dd8d27f01527") version("1.1.2", sha256="4eff3e15b2526ceb48d0236d7ca126face399289eabc0ef67e6ed3b3fdcb60ad") + depends_on("c", type="build") # generated + depends_on("fontconfig") depends_on("gettext") depends_on("libxaw") diff --git a/var/spack/repos/builtin/packages/xfindproxy/package.py b/var/spack/repos/builtin/packages/xfindproxy/package.py index e2bb1ef186407b..5f81012e9b9613 100644 --- a/var/spack/repos/builtin/packages/xfindproxy/package.py +++ b/var/spack/repos/builtin/packages/xfindproxy/package.py @@ -14,11 +14,13 @@ class Xfindproxy(AutotoolsPackage, XorgPackage): services, starts new proxies when necessary, and makes sure that proxies are shared whenever possible.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xfindproxy" + homepage = "https://gitlab.freedesktop.org/xorg/app/xfindproxy" xorg_mirror_path = "app/xfindproxy-1.0.4.tar.gz" version("1.0.4", sha256="fa6152fcf9c16fbb2ef52259731df5df899a39a86894b0508456613f26ff924a") + depends_on("c", type="build") # generated + depends_on("libice") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xfontsel/package.py b/var/spack/repos/builtin/packages/xfontsel/package.py index 5ad88b7f1ab018..a719a841c7e78e 100644 --- a/var/spack/repos/builtin/packages/xfontsel/package.py +++ b/var/spack/repos/builtin/packages/xfontsel/package.py @@ -11,7 +11,7 @@ class Xfontsel(AutotoolsPackage, XorgPackage): protocol fonts known to your X server, examine samples of each, and retrieve the X Logical Font Description ("XLFD") full name for a font.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xfontsel" + homepage = "https://gitlab.freedesktop.org/xorg/app/xfontsel" xorg_mirror_path = "app/xfontsel-1.0.5.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Xfontsel(AutotoolsPackage, XorgPackage): version("1.0.6", sha256="a7b025cb96b678f03caeb61a2770890359bdab34dc37e09d447b30c54c4df35e") version("1.0.5", sha256="9b3ad0cc274398d22be9fa7efe930f4e3749fd4b1b61d9c31a7fb6c1f1ff766e") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xforms/package.py b/var/spack/repos/builtin/packages/xforms/package.py index 003b57fef5e8c0..7474b1074d074d 100644 --- a/var/spack/repos/builtin/packages/xforms/package.py +++ b/var/spack/repos/builtin/packages/xforms/package.py @@ -19,6 +19,8 @@ class Xforms(AutotoolsPackage): version("1.2.3", sha256="7989b39598c769820ad451ad91e5cb0de29946940c8240aac94ca8238c2def61") version("1.0.91", sha256="88684237c77489bcb1fbc9a794621a2919aa800e1c0a6d83d679b97980e3441d") + depends_on("c", type="build") # generated + depends_on("libx11", type="link") depends_on("libxpm", type="link") depends_on("jpeg", type="link") diff --git a/var/spack/repos/builtin/packages/xfs/package.py b/var/spack/repos/builtin/packages/xfs/package.py index 0641d14a979a7d..1b4ebf3cd5a243 100644 --- a/var/spack/repos/builtin/packages/xfs/package.py +++ b/var/spack/repos/builtin/packages/xfs/package.py @@ -9,7 +9,7 @@ class Xfs(AutotoolsPackage, XorgPackage): """X Font Server.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xfs" + homepage = "https://gitlab.freedesktop.org/xorg/app/xfs" xorg_mirror_path = "app/xfs-1.1.4.tar.gz" license("X11") @@ -18,6 +18,9 @@ class Xfs(AutotoolsPackage, XorgPackage): version("1.2.0", sha256="56ebdc5ff85af332a0c5dc60c9b971551624bbc312bf6af3d13b925600ea367f") version("1.1.4", sha256="28f89b854d1ff14fa1efa5b408e5e1c4f6a145420310073c4e44705feeb6d23b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libxfont@1.4.5:", when="@:1.1") depends_on("libxfont2@2.0.1:", when="@1.2:") depends_on("font-util") diff --git a/var/spack/repos/builtin/packages/xfsdump/package.py b/var/spack/repos/builtin/packages/xfsdump/package.py index dde23593d41f59..481a7b506a3cc7 100644 --- a/var/spack/repos/builtin/packages/xfsdump/package.py +++ b/var/spack/repos/builtin/packages/xfsdump/package.py @@ -16,6 +16,8 @@ class Xfsdump(MakefilePackage): version("3.1.5", sha256="ba5bb91413ccb5a0eaffaa84f242baa08520a09f7b990b28bbd0d33a4390f7b6") version("3.1.4", sha256="a75d5c7dabd3dd4184008efcfd30d0c96b6ab318edaad9659ce180dfb9652b01") + depends_on("c", type="build") # generated + depends_on("gettext") depends_on("autoconf", type="build") depends_on("automake", type="build") diff --git a/var/spack/repos/builtin/packages/xfsinfo/package.py b/var/spack/repos/builtin/packages/xfsinfo/package.py index fc8b1ebca800ee..255d3b5c587251 100644 --- a/var/spack/repos/builtin/packages/xfsinfo/package.py +++ b/var/spack/repos/builtin/packages/xfsinfo/package.py @@ -13,13 +13,15 @@ class Xfsinfo(AutotoolsPackage, XorgPackage): clients and the server, and the font catalogues and alternate servers that are available.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xfsinfo" + homepage = "https://gitlab.freedesktop.org/xorg/app/xfsinfo" xorg_mirror_path = "app/xfsinfo-1.0.5.tar.gz" version("1.0.7", sha256="df874933710c9c38640496a2121d73272501b9620bdb95784e9e67b913788151") version("1.0.6", sha256="a817e553703748fe2d721b1fe8ea95687ee78f7aef25427ed72d9584494d91e1") version("1.0.5", sha256="56a0492ed2cde272dc8f4cff4ba0970ccb900e51c10bb8ec62747483d095fd69") + depends_on("c", type="build") # generated + depends_on("libfs") depends_on("xproto@7.0.17:") diff --git a/var/spack/repos/builtin/packages/xfsprogs/package.py b/var/spack/repos/builtin/packages/xfsprogs/package.py index b67540ecb7e6e1..2cc15a88613b0f 100644 --- a/var/spack/repos/builtin/packages/xfsprogs/package.py +++ b/var/spack/repos/builtin/packages/xfsprogs/package.py @@ -21,6 +21,8 @@ class Xfsprogs(AutotoolsPackage): version("4.20.0", sha256="beafdfd080352a8c9d543491e0874d0e8809cb643a3b9d352d5feed38d77022a") + depends_on("c", type="build") # generated + depends_on("libinih") depends_on("gettext") depends_on("uuid") diff --git a/var/spack/repos/builtin/packages/xfwp/package.py b/var/spack/repos/builtin/packages/xfwp/package.py index 2ee35cea525cf9..2d7c105280faed 100644 --- a/var/spack/repos/builtin/packages/xfwp/package.py +++ b/var/spack/repos/builtin/packages/xfwp/package.py @@ -9,11 +9,13 @@ class Xfwp(AutotoolsPackage, XorgPackage): """xfwp proxies X11 protocol connections, such as through a firewall.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xfwp" + homepage = "https://gitlab.freedesktop.org/xorg/app/xfwp" xorg_mirror_path = "app/xfwp-1.0.3.tar.gz" version("1.0.3", sha256="6fe243bde0374637e271a3f038b5d6d79a04621fc18162727782392069c5c04d") + depends_on("c", type="build") # generated + depends_on("libice") depends_on("xproto") diff --git a/var/spack/repos/builtin/packages/xgamma/package.py b/var/spack/repos/builtin/packages/xgamma/package.py index c5d08e2421fd31..47f1e0b3fe1b9c 100644 --- a/var/spack/repos/builtin/packages/xgamma/package.py +++ b/var/spack/repos/builtin/packages/xgamma/package.py @@ -10,7 +10,7 @@ class Xgamma(AutotoolsPackage, XorgPackage): """xgamma allows X users to query and alter the gamma correction of a monitor via the X video mode extension (XFree86-VidModeExtension).""" - homepage = "https://cgit.freedesktop.org/xorg/app/xgamma" + homepage = "https://gitlab.freedesktop.org/xorg/app/xgamma" xorg_mirror_path = "app/xgamma-1.0.6.tar.gz" license("custom") @@ -18,6 +18,8 @@ class Xgamma(AutotoolsPackage, XorgPackage): version("1.0.7", sha256="61f5ef02883d65ab464678ad3d8c5445a0ff727fe6255af90b1b842ddf77370d") version("1.0.6", sha256="66da1d67e84146518b69481c6283c5d8f1027ace9ff7e214d3f81954842e796a") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxxf86vm") diff --git a/var/spack/repos/builtin/packages/xgboost/package.py b/var/spack/repos/builtin/packages/xgboost/package.py index dd82b452d164b2..bfc451f8353336 100644 --- a/var/spack/repos/builtin/packages/xgboost/package.py +++ b/var/spack/repos/builtin/packages/xgboost/package.py @@ -37,6 +37,9 @@ class Xgboost(CMakePackage, CudaPackage): "1.3.3", tag="v1.3.3", commit="000292ce6d99ed658f6f9aebabc6e9b330696e7e", submodules=True ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("nccl", default=False, description="Build with NCCL to enable distributed GPU support") variant("openmp", default=True, description="Build with OpenMP support") diff --git a/var/spack/repos/builtin/packages/xgc/package.py b/var/spack/repos/builtin/packages/xgc/package.py index 4ddedf216b11a7..7e6629a34dc311 100644 --- a/var/spack/repos/builtin/packages/xgc/package.py +++ b/var/spack/repos/builtin/packages/xgc/package.py @@ -10,12 +10,14 @@ class Xgc(AutotoolsPackage, XorgPackage): """xgc is an X11 graphics demo that shows various features of the X11 core protocol graphics primitives.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xgc" + homepage = "https://gitlab.freedesktop.org/xorg/app/xgc" xorg_mirror_path = "app/xgc-1.0.5.tar.gz" version("1.0.6", sha256="8b5cfc547c04a2bd0807be700349522c0e717e34387019dd209eefa83cfa74f0") version("1.0.5", sha256="16645fb437699bad2360f36f54f42320e33fce5a0ab9a086f6e0965963205b02") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xhmm/package.py b/var/spack/repos/builtin/packages/xhmm/package.py index fb3eb7f2706f71..b573f2a818424d 100644 --- a/var/spack/repos/builtin/packages/xhmm/package.py +++ b/var/spack/repos/builtin/packages/xhmm/package.py @@ -17,6 +17,9 @@ class Xhmm(MakefilePackage): version("20160104", commit="cc14e528d90932f059ac4fe94e869e81221fd732") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("lapack") def edit(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/xhost/package.py b/var/spack/repos/builtin/packages/xhost/package.py index 9e083dcb2552d9..44c547cfa04bf6 100644 --- a/var/spack/repos/builtin/packages/xhost/package.py +++ b/var/spack/repos/builtin/packages/xhost/package.py @@ -10,7 +10,7 @@ class Xhost(AutotoolsPackage, XorgPackage): """xhost is used to manage the list of host names or user names allowed to make connections to the X server.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xhost" + homepage = "https://gitlab.freedesktop.org/xorg/app/xhost" xorg_mirror_path = "app/xhost-1.0.7.tar.gz" license("MIT") @@ -19,6 +19,8 @@ class Xhost(AutotoolsPackage, XorgPackage): version("1.0.8", sha256="e5aabce1533dc778ceb5bbc207105cf3770f710629caceaad64675b00c38c3f8") version("1.0.7", sha256="8dd1b6245dfbdef45a64a18ea618f233f77432c2f30881b1db9dc40d510d9490") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxmu") depends_on("libxau") diff --git a/var/spack/repos/builtin/packages/xineramaproto/package.py b/var/spack/repos/builtin/packages/xineramaproto/package.py index 43327786feaa59..fe47a592f6a56b 100644 --- a/var/spack/repos/builtin/packages/xineramaproto/package.py +++ b/var/spack/repos/builtin/packages/xineramaproto/package.py @@ -12,7 +12,7 @@ class Xineramaproto(AutotoolsPackage, XorgPackage): This is an X extension that allows multiple physical screens controlled by a single X server to appear as a single screen.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/xineramaproto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/xineramaproto" xorg_mirror_path = "proto/xineramaproto-1.2.1.tar.gz" version("1.2.1", sha256="d99e121edf7b310008d7371ac5dbe3aa2810996d476b754dc78477cc26e5e7c1") diff --git a/var/spack/repos/builtin/packages/xinit/package.py b/var/spack/repos/builtin/packages/xinit/package.py index 1d9bdf11d065bb..e0d70ec09b67ce 100644 --- a/var/spack/repos/builtin/packages/xinit/package.py +++ b/var/spack/repos/builtin/packages/xinit/package.py @@ -11,7 +11,7 @@ class Xinit(AutotoolsPackage, XorgPackage): first client program on systems that are not using a display manager such as xdm.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xinit" + homepage = "https://gitlab.freedesktop.org/xorg/app/xinit" xorg_mirror_path = "app/xinit-1.3.4.tar.gz" license("MIT") @@ -21,6 +21,9 @@ class Xinit(AutotoolsPackage, XorgPackage): version("1.4.0", sha256="17548a5df41621b87d395f1074dfb88b0dc6917f9127540b89c6de4a80f33776") version("1.3.4", sha256="754c284875defa588951c1d3d2b20897d3b84918d0a97cb5a4724b00c0da0746") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("libx11") depends_on("xproto@7.0.17:") diff --git a/var/spack/repos/builtin/packages/xinput/package.py b/var/spack/repos/builtin/packages/xinput/package.py index b6e9007af47b5b..32265c1bb651ec 100644 --- a/var/spack/repos/builtin/packages/xinput/package.py +++ b/var/spack/repos/builtin/packages/xinput/package.py @@ -9,7 +9,7 @@ class Xinput(AutotoolsPackage, XorgPackage): """xinput is a utility to configure and test XInput devices.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xinput" + homepage = "https://gitlab.freedesktop.org/xorg/app/xinput" xorg_mirror_path = "app/xinput-1.6.2.tar.gz" license("MIT") @@ -17,6 +17,8 @@ class Xinput(AutotoolsPackage, XorgPackage): version("1.6.3", sha256="9f29f9bfe387c5a3d582f9edc8c5a753510ecc6fdfb154c03b5cea5975b10ce4") version("1.6.2", sha256="2c8ca5ff2a8703cb7d898629a4311db720dbd30d0c162bfe37f18849a727bd42") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxext") depends_on("libxi@1.5.99.1:") diff --git a/var/spack/repos/builtin/packages/xkbcomp/package.py b/var/spack/repos/builtin/packages/xkbcomp/package.py index 3e5c6783d0a6b7..0b75d3709feb3f 100644 --- a/var/spack/repos/builtin/packages/xkbcomp/package.py +++ b/var/spack/repos/builtin/packages/xkbcomp/package.py @@ -14,18 +14,21 @@ class Xkbcomp(AutotoolsPackage, XorgPackage): keyboard. It also includes a number of keyboard controls designed to make keyboards more accessible to people with physical impairments.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xkbcomp" + homepage = "https://gitlab.freedesktop.org/xorg/app/xkbcomp" xorg_mirror_path = "app/xkbcomp-1.3.1.tar.gz" license("MIT") maintainers("wdconinc") + version("1.4.7", sha256="00cecc490fcbe2f789cf13c408c459673c2c33ab758d802677321cffcda35373") version("1.4.6", sha256="b216a2c8c0eab83f3dc4a3d5ee2bdf7827b30e49c8907035d0f222138eca0987") version("1.4.5", sha256="e88a4d86b9925ea1e8685dd5ea29c815abafb8ddf19bf5f1a1e0650839252c23") version("1.4.4", sha256="159fba6b62ef4a3fb16ef7fc4eb4fc26f3888652471ceb604c495783dda020bc") version("1.3.1", sha256="018e83a922430652d4bc3f3db610d2296e618c76c9b3fbcdccde975aeb655749") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxkbfile") diff --git a/var/spack/repos/builtin/packages/xkbevd/package.py b/var/spack/repos/builtin/packages/xkbevd/package.py index 6aec9481662a14..b19781d43983ca 100644 --- a/var/spack/repos/builtin/packages/xkbevd/package.py +++ b/var/spack/repos/builtin/packages/xkbevd/package.py @@ -9,12 +9,14 @@ class Xkbevd(AutotoolsPackage, XorgPackage): """XKB event daemon demo.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xkbevd" + homepage = "https://gitlab.freedesktop.org/xorg/app/xkbevd" xorg_mirror_path = "app/xkbevd-1.1.4.tar.gz" version("1.1.5", sha256="5d6b65a417be57e19a76277601da83271b19de6e71cb0e8821441f6fb9973c47") version("1.1.4", sha256="97dc2c19617da115c3d1183807338fa78c3fd074d8355d10a484f7b1c5b18459") + depends_on("c", type="build") # generated + depends_on("libxkbfile") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xkbprint/package.py b/var/spack/repos/builtin/packages/xkbprint/package.py index 92e1f634f8a351..9942bbd2a2f94d 100644 --- a/var/spack/repos/builtin/packages/xkbprint/package.py +++ b/var/spack/repos/builtin/packages/xkbprint/package.py @@ -10,13 +10,15 @@ class Xkbprint(AutotoolsPackage, XorgPackage): """xkbprint generates a printable or encapsulated PostScript description of an XKB keyboard description.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xkbprint" + homepage = "https://gitlab.freedesktop.org/xorg/app/xkbprint" xorg_mirror_path = "app/xkbprint-1.0.4.tar.gz" version("1.0.6", sha256="0d4602034cde190ca3d8f5c1051d34cebff5c0d92f7a32422a4de9d2313698ad") version("1.0.5", sha256="af5d91b7e5b05f7d081b66e93fca0112cca049b7b6a644b2637b344d52054ac3") version("1.0.4", sha256="169ebbf57fc8b7685c577c73a435998a38c27e0d135ce0a55fccc64cbebec768") + depends_on("c", type="build") # generated + depends_on("libxkbfile") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xkbutils/package.py b/var/spack/repos/builtin/packages/xkbutils/package.py index ab80af7039060b..cb6cf1b028475a 100644 --- a/var/spack/repos/builtin/packages/xkbutils/package.py +++ b/var/spack/repos/builtin/packages/xkbutils/package.py @@ -10,12 +10,15 @@ class Xkbutils(AutotoolsPackage, XorgPackage): """xkbutils is a collection of small utilities utilizing the XKeyboard (XKB) extension to the X11 protocol.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xkbutils" + homepage = "https://gitlab.freedesktop.org/xorg/app/xkbutils" xorg_mirror_path = "app/xkbutils-1.0.4.tar.gz" + version("1.0.6", sha256="d747d4ce5c390223e3bfdb13a1f673d3e19ae46ded25838cb8b28b1bafe1b9bd") version("1.0.5", sha256="b87072f0d7e75f56ee04455e1feab92bb5847aee4534b18c2e08b926150279ff") version("1.0.4", sha256="cf31303cbdd6a86c34cab46f4b6e0c7acd2e84578593b334a146142894529bca") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxt") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xkill/package.py b/var/spack/repos/builtin/packages/xkill/package.py index 52f43925797f12..fff9bfdc6fe807 100644 --- a/var/spack/repos/builtin/packages/xkill/package.py +++ b/var/spack/repos/builtin/packages/xkill/package.py @@ -11,7 +11,7 @@ class Xkill(AutotoolsPackage, XorgPackage): clients. This program is very dangerous, but is useful for aborting programs that have displayed undesired windows on a user's screen.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xkill" + homepage = "https://gitlab.freedesktop.org/xorg/app/xkill" xorg_mirror_path = "app/xkill-1.0.4.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Xkill(AutotoolsPackage, XorgPackage): version("1.0.5", sha256="98fab8a8af78d5aae4e1f284b580c60e3d25ed2a72daa4dbce419b28d8adaf8a") version("1.0.4", sha256="f80115f2dcca3d4b61f3c28188752c21ca7b2718b54b6e0274c0497a7f827da0") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxmu") diff --git a/var/spack/repos/builtin/packages/xl/detection_test.yaml b/var/spack/repos/builtin/packages/xl/detection_test.yaml new file mode 100644 index 00000000000000..da7b2fa92f50b5 --- /dev/null +++ b/var/spack/repos/builtin/packages/xl/detection_test.yaml @@ -0,0 +1,31 @@ +paths: +- layout: + - executables: + - "bin/xlc" + - "bin/xlc++" + - "bin/xlc_r" + - "bin/xlc++_r" + script: | + echo "IBM XL C/C++ for Linux, V16.1.1 (5725-C73, 5765-J13)" + echo "Version: 16.01.0001.0006" + - executables: + - "bin/xlf" + - "bin/xlf_r" + - "bin/xlcuf" + script: | + echo "IBM XL Fortran for Linux, V16.1.1 (5725-C73, 5765-J13)" + echo "Version: 16.01.0001.0006" + platforms: ["linux"] + results: + - spec: "xl~r@16.1" + extra_attributes: + compilers: + c: ".*/bin/xlc" + cxx: ".*/bin/xlc[+][+]" + fortran: ".*/bin/xlf" + - spec: "xl+r@16.1" + extra_attributes: + compilers: + c: ".*/bin/xlc_r" + cxx: ".*/bin/xlc[+][+]_r" + fortran: ".*/bin/xlf_r" diff --git a/var/spack/repos/builtin/packages/xl/package.py b/var/spack/repos/builtin/packages/xl/package.py new file mode 100644 index 00000000000000..379c35810beda5 --- /dev/null +++ b/var/spack/repos/builtin/packages/xl/package.py @@ -0,0 +1,65 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) +from spack.package import * + + +class Xl(Package, CompilerPackage): + """IBM XL C/C++/Fortran is an advanced, high-performance compiler that can be + used for developing complex, computationally intensive programs, including + interlanguage calls with C and Fortran programs. + """ + + homepage = "https://www.ibm.com/support/knowledgecenter/SSXVZZ_16.1.1/com.ibm.compilers.linux.doc/welcome.html" + + variant("r", default=True, description="The _r version of compilers") + + def install(self, spec, prefix): + raise InstallError( + "XL compilers are not installable yet, but can be " + "detected on a system where they are supplied by vendor" + ) + + compiler_languages = ["c", "cxx", "fortran"] + c_names = ["xlc", "xlc_r"] + cxx_names = ["xlc++", "xlC", "xlc++_r", "xlC_r"] + fortran_names = ["xlf", "xlf_r"] # TODO complete this + compiler_version_argument = "-qversion" + compiler_version_regex = r"([0-9]?[0-9]\.[0-9])" + + @classmethod + def determine_variants(cls, exes, version_str): + _r_exes = [e for e in exes if e.endswith("_r")] + _exes = [e for e in exes if not e.endswith("_r")] + + _r_compilers = cls.determine_compiler_paths(exes=_r_exes) if _r_exes else None + _compilers = cls.determine_compiler_paths(exes=_exes) if _exes else None + + results = [] + if _r_compilers: + results.append(("+r", {"compilers": _r_compilers})) + if _compilers: + results.append(("~r", {"compilers": _compilers})) + return results + + @property + def cc(self): + if self.spec.external: + return self.spec.extra_attributes["compilers"]["c"] + msg = "cannot retrieve C compiler [spec is not concrete]" + assert self.spec.concrete, msg + + @property + def cxx(self): + if self.spec.external: + return self.spec.extra_attributes["compilers"]["cxx"] + msg = "cannot retrieve C++ compiler [spec is not concrete]" + assert self.spec.concrete, msg + + @property + def fortran(self): + if self.spec.external: + return self.spec.extra_attributes["compilers"]["fortran"] + msg = "cannot retrieve Fortran compiler [spec is not concrete]" + assert self.spec.concrete, msg diff --git a/var/spack/repos/builtin/packages/xlc/detection_test.yaml b/var/spack/repos/builtin/packages/xlc/detection_test.yaml deleted file mode 100644 index e76c608abaaa7c..00000000000000 --- a/var/spack/repos/builtin/packages/xlc/detection_test.yaml +++ /dev/null @@ -1,18 +0,0 @@ -paths: - - layout: - - executables: - - "bin/xlc" - - "bin/xlc++" - - "bin/xlc_r" - - "bin/xlc++_r" - script: | - echo "IBM XL C/C++ for Linux, V16.1.1 (5725-C73, 5765-J13)" - echo "Version: 16.01.0001.0006" - - executables: - - "bin/xlcuf" - script: | - echo "IBM XL Fortran for Linux, V16.1.1 (5725-C73, 5765-J13)" - echo "Version: 16.01.0001.0006" - results: - - spec: "xlc+r@16.1" - - spec: "xlc~r@16.1" diff --git a/var/spack/repos/builtin/packages/xlc/package.py b/var/spack/repos/builtin/packages/xlc/package.py deleted file mode 100644 index 983db7739b46b6..00000000000000 --- a/var/spack/repos/builtin/packages/xlc/package.py +++ /dev/null @@ -1,81 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -import collections -import re - -import llnl.util.tty as tty - -import spack.compiler -from spack.package import * - - -class Xlc(Package): - """IBM XL C/C++ is an advanced, high-performance compiler that can be - used for developing complex, computationally intensive programs, including - interlanguage calls with C and Fortran programs. - """ - - homepage = "https://www.ibm.com/support/knowledgecenter/SSXVZZ_16.1.1/com.ibm.compilers.linux.doc/welcome.html" - - variant("r", default=True, description="The _r version of compilers") - - def install(self, spec, prefix): - raise InstallError( - "XL compilers are not installable yet, but can be " - "detected on a system where they are supplied by vendor" - ) - - executables = [r"xlc", r"xlC", r"xlc\+\+"] - - @classmethod - def determine_version(cls, exe): - version_regex = re.compile(r"([0-9]?[0-9]\.[0-9])") - try: - output = spack.compiler.get_compiler_version_output(exe, "-qversion") - # Exclude spurious Fortran compilers - if "Fortran" in output: - return None - - match = version_regex.search(output) - if match: - return match.group(1) - except spack.util.executable.ProcessError: - pass - except Exception as e: - tty.debug(str(e)) - - @classmethod - def determine_variants(cls, exes, version_str): - variants = collections.defaultdict(dict) - for exe in exes: - # Determine the variant of the spec - variant_str = "+r" if "_r" in exe else "~r" - if "xlc++" in exe: - variants[variant_str]["cxx"] = exe - continue - - if "xlc" in exe: - variants[variant_str]["c"] = exe - continue - - results = [] - for variant_str, compilers in variants.items(): - results.append((variant_str, {"compilers": compilers})) - - return results - - @property - def cc(self): - if self.spec.external: - return self.spec.extra_attributes["compilers"]["c"] - msg = "cannot retrieve C compiler [spec is not concrete]" - assert self.spec.concrete, msg - - @property - def cxx(self): - if self.spec.external: - return self.spec.extra_attributes["compilers"]["cxx"] - msg = "cannot retrieve C compiler [spec is not concrete]" - assert self.spec.concrete, msg diff --git a/var/spack/repos/builtin/packages/xlf/detection_test.yaml b/var/spack/repos/builtin/packages/xlf/detection_test.yaml deleted file mode 100644 index 461ef007d74a55..00000000000000 --- a/var/spack/repos/builtin/packages/xlf/detection_test.yaml +++ /dev/null @@ -1,11 +0,0 @@ -paths: - - layout: - - executables: - - "bin/xlf" - - "bin/xlf_r" - script: | - echo "IBM XL Fortran for Linux, V16.1.1 (5725-C73, 5765-J13)" - echo "Version: 16.01.0001.0006" - results: - - spec: "xlf+r@16.1" - - spec: "xlf~r@16.1" diff --git a/var/spack/repos/builtin/packages/xlf/package.py b/var/spack/repos/builtin/packages/xlf/package.py deleted file mode 100644 index dc26e7fd91630f..00000000000000 --- a/var/spack/repos/builtin/packages/xlf/package.py +++ /dev/null @@ -1,69 +0,0 @@ -# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other -# Spack Project Developers. See the top-level COPYRIGHT file for details. -# -# SPDX-License-Identifier: (Apache-2.0 OR MIT) -import collections -import os.path -import re - -import llnl.util.tty as tty - -import spack.compiler -from spack.package import * - - -class Xlf(Package): - """IBM XL Fortran is an advanced, high-performance compiler that can be - used for developing complex, computationally intensive programs, including - interlanguage calls with C and Fortran programs. - """ - - homepage = "https://www.ibm.com/support/knowledgecenter/SSXVZZ_16.1.1/com.ibm.compilers.linux.doc/welcome.html" - - variant("r", default=True, description="The _r version of compilers") - - def install(self, spec, prefix): - raise InstallError( - "XL compilers are not installable yet, but can be " - "detected on a system where they are supplied by vendor" - ) - - executables = [r"xlf"] - - @classmethod - def determine_version(cls, exe): - version_regex = re.compile(r"([0-9]?[0-9]\.[0-9])") - try: - output = spack.compiler.get_compiler_version_output(exe, "-qversion") - match = version_regex.search(output) - if match: - return match.group(1) - except spack.util.executable.ProcessError: - pass - except Exception as e: - tty.debug(e) - - @classmethod - def determine_variants(cls, exes, version_str): - variants = collections.defaultdict(dict) - for exe in exes: - if os.path.basename(exe) == "xlf": - variants["~r"]["fortran"] = exe - continue - - if os.path.basename(exe) == "xlf_r": - variants["+r"]["fortran"] = exe - continue - - results = [] - for variant_str, compilers in variants.items(): - results.append((variant_str, {"compilers": compilers})) - - return results - - @property - def fortran(self): - if self.spec.external: - return self.spec.extra_attributes["compilers"]["fortran"] - msg = "cannot retrieve C compiler [spec is not concrete]" - assert self.spec.concrete, msg diff --git a/var/spack/repos/builtin/packages/xload/package.py b/var/spack/repos/builtin/packages/xload/package.py index 7c6b24fcde1dc0..103729c83b5e17 100644 --- a/var/spack/repos/builtin/packages/xload/package.py +++ b/var/spack/repos/builtin/packages/xload/package.py @@ -10,15 +10,18 @@ class Xload(AutotoolsPackage, XorgPackage): """xload displays a periodically updating histogram of the system load average.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xload" + homepage = "https://gitlab.freedesktop.org/xorg/app/xload" xorg_mirror_path = "app/xload-1.1.3.tar.gz" license("MIT") + version("1.2.0", sha256="0d3b84d22d2d85e9c3c152e48871e490dfcaad420f8836333f1323c5a690d55f") version("1.1.4", sha256="4e3d240ab63e02f2ddac8182519d94bea82bda4887e3e364dd8832a04ca8436a") version("1.1.3", sha256="9952e841d25ab2fd0ce5e27ba91858331c3f97575d726481772d4deb89432483") version("1.1.2", sha256="4863ad339d22c41a0ca030dc5886404f5ae8b8c47cd5e09f0e36407edbdbe769") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xlogo/package.py b/var/spack/repos/builtin/packages/xlogo/package.py index aa556d31abdfc1..1f809b927440d2 100644 --- a/var/spack/repos/builtin/packages/xlogo/package.py +++ b/var/spack/repos/builtin/packages/xlogo/package.py @@ -9,13 +9,15 @@ class Xlogo(AutotoolsPackage, XorgPackage): """The xlogo program simply displays the X Window System logo.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xlogo" + homepage = "https://gitlab.freedesktop.org/xorg/app/xlogo" xorg_mirror_path = "app/xlogo-1.0.4.tar.gz" version("1.0.6", sha256="0b0dbd90f53103b9241cc3a68c232213cec5c1d9a839604e59d128e4d81d1a4d") version("1.0.5", sha256="28f51b64e3bce6aa5ac0e35d0c12121e6e0311d3bd8b48664a57a74f6be651eb") version("1.0.4", sha256="0072eb3b41af77d5edfafb12998c7dd875f2795dc94735a998fd2ed8fc246e57") + depends_on("c", type="build") # generated + depends_on("libsm") depends_on("libxaw") depends_on("libxmu") diff --git a/var/spack/repos/builtin/packages/xlsatoms/package.py b/var/spack/repos/builtin/packages/xlsatoms/package.py index 7f28f2bd5b1432..4108c17e4f7f9d 100644 --- a/var/spack/repos/builtin/packages/xlsatoms/package.py +++ b/var/spack/repos/builtin/packages/xlsatoms/package.py @@ -9,13 +9,15 @@ class Xlsatoms(AutotoolsPackage, XorgPackage): """xlsatoms lists the interned atoms defined on an X11 server.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xlsatoms" + homepage = "https://gitlab.freedesktop.org/xorg/app/xlsatoms" xorg_mirror_path = "app/xlsatoms-1.1.2.tar.gz" version("1.1.4", sha256="e3b4dce0e6bf3b60bc308ed184d2dc201ea4af6ce03f0126aa303ccd1ccb1237") version("1.1.3", sha256="2a5a3ac0ded207c31ac1c2e9b8ae0030bba7ff604fea87a92781186ba71cbffa") version("1.1.2", sha256="5400e22211795e40c4c4d28a048250f92bfb8c373004f0e654a2ad3138c2b36d") + depends_on("c", type="build") # generated + depends_on("libxcb", when="@1.1:") depends_on("libx11", when="@:1.0") diff --git a/var/spack/repos/builtin/packages/xlsclients/package.py b/var/spack/repos/builtin/packages/xlsclients/package.py index bf42cd27cda516..94510a3b14b710 100644 --- a/var/spack/repos/builtin/packages/xlsclients/package.py +++ b/var/spack/repos/builtin/packages/xlsclients/package.py @@ -10,13 +10,15 @@ class Xlsclients(AutotoolsPackage, XorgPackage): """xlsclients is a utility for listing information about the client applications running on a X11 server.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xlsclients" + homepage = "https://gitlab.freedesktop.org/xorg/app/xlsclients" xorg_mirror_path = "app/xlsclients-1.1.3.tar.gz" version("1.1.5", sha256="225d75e4c0b0929f16f974e20931ab85204b40098d92a5479b0b9379120637e5") version("1.1.4", sha256="0b46e8289413c3e7c437a95ecd6494f99d27406d3a0b724ef995a98cbd6c33e8") version("1.1.3", sha256="4670a4003aae01e9172efb969246c3d8f33481f290aa8726ff50398c838e6994") + depends_on("c", type="build") # generated + depends_on("libxcb@1.6:", when="@1.1:") depends_on("libx11", when="@:1.0") diff --git a/var/spack/repos/builtin/packages/xlsfonts/package.py b/var/spack/repos/builtin/packages/xlsfonts/package.py index 4efceb02beea17..49e7b872f3b708 100644 --- a/var/spack/repos/builtin/packages/xlsfonts/package.py +++ b/var/spack/repos/builtin/packages/xlsfonts/package.py @@ -10,13 +10,15 @@ class Xlsfonts(AutotoolsPackage, XorgPackage): """xlsfonts lists fonts available from an X server via the X11 core protocol.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xlsfonts" + homepage = "https://gitlab.freedesktop.org/xorg/app/xlsfonts" xorg_mirror_path = "app/xlsfonts-1.0.5.tar.gz" version("1.0.7", sha256="b92d4954eaf525674ff83f7e85240ef166c240a774277f71c30674f9f7794171") version("1.0.6", sha256="870bbcfb903e790e730ea8ee964c72ce4a4df60f7a4b39541b88193d1e8c9453") version("1.0.5", sha256="2a7aeca1023a3918ad2a1af2258ed63d8f8b6c48e53841b3a3f15fb9a0c008ce") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("xproto@7.0.17:") diff --git a/var/spack/repos/builtin/packages/xmag/package.py b/var/spack/repos/builtin/packages/xmag/package.py index 18ece436a9755f..a11dc957d6a13d 100644 --- a/var/spack/repos/builtin/packages/xmag/package.py +++ b/var/spack/repos/builtin/packages/xmag/package.py @@ -9,7 +9,7 @@ class Xmag(AutotoolsPackage, XorgPackage): """xmag displays a magnified snapshot of a portion of an X11 screen.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xmag" + homepage = "https://gitlab.freedesktop.org/xorg/app/xmag" xorg_mirror_path = "app/xmag-1.0.6.tar.gz" license("custom") @@ -17,6 +17,8 @@ class Xmag(AutotoolsPackage, XorgPackage): version("1.0.7", sha256="bf94f5ac6ad0dd423b3ee8fb78710d1e47ad7e9fc8b4cf561851fba5370e38eb") version("1.0.6", sha256="07c5ec9114376dcd9a3303a38779e79b949d486f3b832d4a438550357d797aa5") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xman/package.py b/var/spack/repos/builtin/packages/xman/package.py index 48ed103f021cca..52b498c3fd1f20 100644 --- a/var/spack/repos/builtin/packages/xman/package.py +++ b/var/spack/repos/builtin/packages/xman/package.py @@ -10,7 +10,7 @@ class Xman(AutotoolsPackage, XorgPackage): """xman is a graphical manual page browser using the Athena Widgets (Xaw) toolkit.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xman" + homepage = "https://gitlab.freedesktop.org/xorg/app/xman" xorg_mirror_path = "app/xman-1.1.4.tar.gz" license("X11") @@ -18,6 +18,8 @@ class Xman(AutotoolsPackage, XorgPackage): version("1.1.5", sha256="ff0aeb164fcb736b381bd7722c27aa0284cafb9a5d1b3940c3c3ee0af642f204") version("1.1.4", sha256="72fd0d479624a31d9a7330e5fdd220b7aa144744781f8e78aa12deece86e05c7") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xmessage/package.py b/var/spack/repos/builtin/packages/xmessage/package.py index 26727768863084..fff7c6901ee0cc 100644 --- a/var/spack/repos/builtin/packages/xmessage/package.py +++ b/var/spack/repos/builtin/packages/xmessage/package.py @@ -11,7 +11,7 @@ class Xmessage(AutotoolsPackage, XorgPackage): on an "okay" button to dismiss it or can select one of several buttons to answer a question. xmessage can also exit after a specified time.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xmessage" + homepage = "https://gitlab.freedesktop.org/xorg/app/xmessage" xorg_mirror_path = "app/xmessage-1.0.4.tar.gz" license("MIT") @@ -20,6 +20,8 @@ class Xmessage(AutotoolsPackage, XorgPackage): version("1.0.5", sha256="99533a90ab66e268180a8400796950a7f560ea9421e2c3f32284cabc1858806b") version("1.0.4", sha256="883099c3952c8cace5bd11d3df2e9ca143fc07375997435d5ff4f2d50353acca") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xmh/package.py b/var/spack/repos/builtin/packages/xmh/package.py index e751b144d8c0ea..875a90396a5227 100644 --- a/var/spack/repos/builtin/packages/xmh/package.py +++ b/var/spack/repos/builtin/packages/xmh/package.py @@ -11,12 +11,15 @@ class Xmh(AutotoolsPackage, XorgPackage): MH Message Handling System. To actually do things with your mail, it makes calls to the MH package.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xmh" + homepage = "https://gitlab.freedesktop.org/xorg/app/xmh" xorg_mirror_path = "app/xmh-1.0.3.tar.gz" + version("1.0.5", sha256="3ab74096031ba89bcc88a46dbfa652837c4aeb6a36168ff9799782efe88128b8") version("1.0.4", sha256="2034f24fb3181b6e07ebf7235d2845a7ebb18d533aa405dbc99235eec4ab410f") version("1.0.3", sha256="f90baf2615a4e1e01232c50cfd36ee4d50ad2fb2f76b8b5831fb796661f194d2") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxmu") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xmlf90/package.py b/var/spack/repos/builtin/packages/xmlf90/package.py index 5151ef10e21dfa..c8a0937c29a902 100644 --- a/var/spack/repos/builtin/packages/xmlf90/package.py +++ b/var/spack/repos/builtin/packages/xmlf90/package.py @@ -25,6 +25,8 @@ class Xmlf90(AutotoolsPackage): version("1.5.3", tag="xmlf90-1.5.3", commit="d55a5bcf8a0d4e592a03585209435d342d8e6d0f") version("1.5.2", tag="xmlf90-1.5.2", commit="b238aec8719b7c40c7b7252c5f200818a0d5004a") + depends_on("fortran", type="build") # generated + depends_on("autoconf@2.69:", type="build") depends_on("automake@1.14:", type="build") depends_on("libtool@2.4.2:", type="build") diff --git a/var/spack/repos/builtin/packages/xmlrpc-c/package.py b/var/spack/repos/builtin/packages/xmlrpc-c/package.py index 080b08658495c8..e32b2a0a012ef7 100644 --- a/var/spack/repos/builtin/packages/xmlrpc-c/package.py +++ b/var/spack/repos/builtin/packages/xmlrpc-c/package.py @@ -17,6 +17,9 @@ class XmlrpcC(AutotoolsPackage): version("1.51.06", sha256="06dcd87d9c88374559369ffbe83b3139cf41418c1a2d03f20e08808085f89fd0") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("curl", default=False, description="Build the XMLRPC curl client") depends_on("curl", when="+curl") diff --git a/var/spack/repos/builtin/packages/xmlto/package.py b/var/spack/repos/builtin/packages/xmlto/package.py index d70e6f6dda5cd0..6b87b226c6c62b 100644 --- a/var/spack/repos/builtin/packages/xmlto/package.py +++ b/var/spack/repos/builtin/packages/xmlto/package.py @@ -19,6 +19,8 @@ class Xmlto(AutotoolsPackage): version("0.0.28", sha256="2f986b7c9a0e9ac6728147668e776d405465284e13c74d4146c9cbc51fd8aad3") + depends_on("c", type="build") # generated + # FIXME: missing a lot of dependencies depends_on("docbook-xsl", type=("build", "run")) depends_on("libxml2", type=("build", "run")) # xmllint diff --git a/var/spack/repos/builtin/packages/xmodmap/package.py b/var/spack/repos/builtin/packages/xmodmap/package.py index d3544926c5c453..700564f1f3d5ff 100644 --- a/var/spack/repos/builtin/packages/xmodmap/package.py +++ b/var/spack/repos/builtin/packages/xmodmap/package.py @@ -13,7 +13,7 @@ class Xmodmap(AutotoolsPackage, XorgPackage): session startup script to configure the keyboard according to personal tastes.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xmodmap" + homepage = "https://gitlab.freedesktop.org/xorg/app/xmodmap" xorg_mirror_path = "app/xmodmap-1.0.9.tar.gz" license("MIT") @@ -22,6 +22,8 @@ class Xmodmap(AutotoolsPackage, XorgPackage): version("1.0.10", sha256="d4e9dc4cb034d0d774d059498d05348869934c52b0f24b0f3913823090b88640") version("1.0.9", sha256="73427a996f0fcda2a2c7ac96cfc4edd5985aeb13b48053f55ae7f63a668fadef") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("xproto@7.0.25:") diff --git a/var/spack/repos/builtin/packages/xmore/package.py b/var/spack/repos/builtin/packages/xmore/package.py index 782484dc156edd..2642215c4f3c00 100644 --- a/var/spack/repos/builtin/packages/xmore/package.py +++ b/var/spack/repos/builtin/packages/xmore/package.py @@ -9,12 +9,14 @@ class Xmore(AutotoolsPackage, XorgPackage): """xmore - plain text display program for the X Window System.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xmore" + homepage = "https://gitlab.freedesktop.org/xorg/app/xmore" xorg_mirror_path = "app/xmore-1.0.2.tar.gz" version("1.0.3", sha256="00e2f55ce4d2699a97f70060d309898c92ed2a42b9e16f21047a3654432a92b6") version("1.0.2", sha256="7371631d05986f1111f2026a77e43e048519738cfcc493c6222b66e7b0f309c0") + depends_on("c", type="build") # generated + depends_on("libxaw") depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xnnpack/package.py b/var/spack/repos/builtin/packages/xnnpack/package.py index 9549e256db2613..6611fe71907e79 100644 --- a/var/spack/repos/builtin/packages/xnnpack/package.py +++ b/var/spack/repos/builtin/packages/xnnpack/package.py @@ -22,6 +22,9 @@ class Xnnpack(CMakePackage): version("2020-03-23", commit="1b354636b5942826547055252f3b359b54acff95") # py-torch@1.6:1.7 version("2020-02-24", commit="7493bfb9d412e59529bcbced6a902d44cfa8ea1c") # py-torch@1.5 + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + generator("ninja") depends_on("cmake@3.5:", type="build") depends_on("python", type="build") diff --git a/var/spack/repos/builtin/packages/xorg-cf-files/package.py b/var/spack/repos/builtin/packages/xorg-cf-files/package.py index 578c10e7f4d2e4..d02e7c757c4561 100644 --- a/var/spack/repos/builtin/packages/xorg-cf-files/package.py +++ b/var/spack/repos/builtin/packages/xorg-cf-files/package.py @@ -12,11 +12,12 @@ class XorgCfFiles(AutotoolsPackage, XorgPackage): have not been verified or tested in over a decade), and for many of the libraries formerly delivered in the X.Org monolithic releases.""" - homepage = "https://cgit.freedesktop.org/xorg/util/cf" + homepage = "https://gitlab.freedesktop.org/xorg/util/cf" xorg_mirror_path = "util/xorg-cf-files-1.0.6.tar.gz" license("custom") + version("1.0.8", sha256="c6f1c9ffce96278a9d7c72d081e508d81c219dec69ae0dbaf8ae88f4bc9ef977") version("1.0.6", sha256="6d56094e5d1a6c7d7a9576ac3a0fc2c042344509ea900d59f4b23df668b96c7a") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/xorg-docs/package.py b/var/spack/repos/builtin/packages/xorg-docs/package.py index 73a861422d9e23..78b772a7e769d2 100644 --- a/var/spack/repos/builtin/packages/xorg-docs/package.py +++ b/var/spack/repos/builtin/packages/xorg-docs/package.py @@ -12,15 +12,17 @@ class XorgDocs(AutotoolsPackage, XorgPackage): The preferred documentation format for these documents is DocBook XML.""" - homepage = "https://cgit.freedesktop.org/xorg/doc/xorg-docs" + homepage = "https://gitlab.freedesktop.org/xorg/doc/xorg-docs" xorg_mirror_path = "doc/xorg-docs-1.7.1.tar.gz" maintainers("wdconinc") + version("1.7.3", sha256="30f8fc4b435cda82f21d08d81c2e2fc9046ec7e20945e32ab7b63326674cf8c5") version("1.7.2", sha256="0c1e018868a00cb5a5bc8622ffd87e706e119ffa0949edde00d0d0d912663677") version("1.7.1", sha256="360707db2ba48f6deeb53d570deca9fa98218af48ead4a726a67f63e3ef63816") depends_on("pkgconfig", type="build") - depends_on("util-macros", type="build") + depends_on("util-macros@1.8:", type="build") + depends_on("util-macros@1.20:", type="build", when="@1.7.3:") depends_on("xorg-sgml-doctools@1.8:", type="build") depends_on("xmlto", type="build") diff --git a/var/spack/repos/builtin/packages/xorg-gtest/package.py b/var/spack/repos/builtin/packages/xorg-gtest/package.py index 1a22f1256536c3..55d1fddddd175f 100644 --- a/var/spack/repos/builtin/packages/xorg-gtest/package.py +++ b/var/spack/repos/builtin/packages/xorg-gtest/package.py @@ -15,6 +15,8 @@ class XorgGtest(AutotoolsPackage, XorgPackage): version("0.7.1", sha256="6cedc7904c698472783203bd686e777db120b808bb4052e451a822e437b72682") + depends_on("cxx", type="build") # generated + depends_on("libx11") depends_on("libxi") depends_on("xorg-server") diff --git a/var/spack/repos/builtin/packages/xorg-server/package.py b/var/spack/repos/builtin/packages/xorg-server/package.py index 3bafc23339d2d8..f72115569578af 100644 --- a/var/spack/repos/builtin/packages/xorg-server/package.py +++ b/var/spack/repos/builtin/packages/xorg-server/package.py @@ -19,6 +19,9 @@ class XorgServer(AutotoolsPackage, XorgPackage): "1.18.99.901", sha256="c8425163b588de2ee7e5c8e65b0749f2710f55a7e02a8d1dc83b3630868ceb21" ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("pixman@0.27.2:") depends_on("font-util") depends_on("libxshmfence@1.1:") diff --git a/var/spack/repos/builtin/packages/xorg-sgml-doctools/package.py b/var/spack/repos/builtin/packages/xorg-sgml-doctools/package.py index a92365b1344784..a796f927c12bc8 100644 --- a/var/spack/repos/builtin/packages/xorg-sgml-doctools/package.py +++ b/var/spack/repos/builtin/packages/xorg-sgml-doctools/package.py @@ -11,15 +11,17 @@ class XorgSgmlDoctools(AutotoolsPackage, XorgPackage): sheets used in building/formatting the documentation provided in other X.Org packages.""" - homepage = "https://cgit.freedesktop.org/xorg/doc/xorg-sgml-doctools" + homepage = "https://gitlab.freedesktop.org/xorg/doc/xorg-sgml-doctools" xorg_mirror_path = "doc/xorg-sgml-doctools-1.11.tar.gz" maintainers("wdconinc") license("MIT") + version("1.12.1", sha256="8de3406f96a02bc3ab51ff47ba1612d9a11fc25d2edcaa06caa2cb2420d7bae0") version("1.12", sha256="985a0329e6a6dadd6ad517f8d54f8766ab4b52bb8da7b07d02ec466bec444bdb") version("1.11", sha256="986326d7b4dd2ad298f61d8d41fe3929ac6191c6000d6d7e47a8ffc0c34e7426") depends_on("pkgconfig", type="build") - depends_on("util-macros", type="build") + depends_on("util-macros@1.8:", type="build") + depends_on("util-macros@1.20:", type="build", when="@1.12.1:") diff --git a/var/spack/repos/builtin/packages/xphelloworld/package.py b/var/spack/repos/builtin/packages/xphelloworld/package.py index 3eec5ffc2163e5..47d4bca340d33c 100644 --- a/var/spack/repos/builtin/packages/xphelloworld/package.py +++ b/var/spack/repos/builtin/packages/xphelloworld/package.py @@ -9,11 +9,13 @@ class Xphelloworld(AutotoolsPackage, XorgPackage): """Xprint sample applications.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xphelloworld" + homepage = "https://gitlab.freedesktop.org/xorg/app/xphelloworld" xorg_mirror_path = "app/xphelloworld-1.0.1.tar.gz" version("1.0.1", sha256="ead6437c4dc9540698a41e174c9d1ac792de07baeead81935d72cb123196f866") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxaw") depends_on("libxprintapputil") diff --git a/var/spack/repos/builtin/packages/xplsprinters/package.py b/var/spack/repos/builtin/packages/xplsprinters/package.py index 901bfaa0e4836f..332064d4f4befe 100644 --- a/var/spack/repos/builtin/packages/xplsprinters/package.py +++ b/var/spack/repos/builtin/packages/xplsprinters/package.py @@ -9,11 +9,13 @@ class Xplsprinters(AutotoolsPackage, XorgPackage): """List Xprint printers.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xplsprinters" + homepage = "https://gitlab.freedesktop.org/xorg/app/xplsprinters" xorg_mirror_path = "app/xplsprinters-1.0.1.tar.gz" version("1.0.1", sha256="33377e499429ce3e100fbd7b59153c87ad79bf55872561db08419f69cac4fbfd") + depends_on("c", type="build") # generated + depends_on("libxp") depends_on("libxprintutil") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xpmem/package.py b/var/spack/repos/builtin/packages/xpmem/package.py index cd437e3cf76530..20d88b8ced1dd9 100644 --- a/var/spack/repos/builtin/packages/xpmem/package.py +++ b/var/spack/repos/builtin/packages/xpmem/package.py @@ -35,6 +35,8 @@ class Xpmem(AutotoolsPackage): version("2.6.3", sha256="ee239a32269f33234cdbdb94db29c12287862934c0784328d34aff82a9fa8b54") version("2.6.2", sha256="2c1a93b4cb20ed73c2093435a7afec513e0e797aa1e49d4d964cc6bdae89d65b") + depends_on("c", type="build") # generated + variant("kernel-module", default=True, description="Enable building the kernel module") # Added RHEL 8.3 kernel support diff --git a/var/spack/repos/builtin/packages/xpr/package.py b/var/spack/repos/builtin/packages/xpr/package.py index 291aa4e031add6..d1896a6843410e 100644 --- a/var/spack/repos/builtin/packages/xpr/package.py +++ b/var/spack/repos/builtin/packages/xpr/package.py @@ -10,13 +10,15 @@ class Xpr(AutotoolsPackage, XorgPackage): """xpr takes as input a window dump file produced by xwd and formats it for output on various types of printers.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xpr" + homepage = "https://gitlab.freedesktop.org/xorg/app/xpr" xorg_mirror_path = "app/xpr-1.0.4.tar.gz" version("1.1.0", sha256="fabd02fb1a52358d521f1be7422738bc8c9b511a8d82a163888f628db6f6cb18") version("1.0.5", sha256="7a429478279a2b0f2363b24b8279ff132cc5e83762d3329341490838b0723757") version("1.0.4", sha256="9ec355388ae363fd40239a3fa56908bb2f3e53b5bfc872cf0182d14d730c6207") + depends_on("c", type="build") # generated + depends_on("libxmu") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xprehashprinterlist/package.py b/var/spack/repos/builtin/packages/xprehashprinterlist/package.py index 5ad7f37fb3ccc2..b6477d53aae4b2 100644 --- a/var/spack/repos/builtin/packages/xprehashprinterlist/package.py +++ b/var/spack/repos/builtin/packages/xprehashprinterlist/package.py @@ -9,11 +9,13 @@ class Xprehashprinterlist(AutotoolsPackage, XorgPackage): """Rehash list of Xprint printers.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xprehashprinterlist" + homepage = "https://gitlab.freedesktop.org/xorg/app/xprehashprinterlist" xorg_mirror_path = "app/xprehashprinterlist-1.0.1.tar.gz" version("1.0.1", sha256="396986da064b584138cfcff79a8aed12590a9dab24f1cd2d80b08bc1cb896a43") + depends_on("c", type="build") # generated + depends_on("libxp") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xprop/package.py b/var/spack/repos/builtin/packages/xprop/package.py index b426118a02f53e..c97c07727d8acc 100644 --- a/var/spack/repos/builtin/packages/xprop/package.py +++ b/var/spack/repos/builtin/packages/xprop/package.py @@ -10,17 +10,20 @@ class Xprop(AutotoolsPackage, XorgPackage): """xprop is a command line tool to display and/or set window and font properties of an X server.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xprop" + homepage = "https://gitlab.freedesktop.org/xorg/app/xprop" xorg_mirror_path = "app/xprop-1.2.2.tar.gz" license("MIT") + version("1.2.7", sha256="11c06a876b0aa0bfac6cbfe4b3ebe1f5062f8b39b9b1b6c136a8629265f134b6") version("1.2.6", sha256="58ee5ee0c47fa454d3b16312e778c3f549605a8ad0fd0daafc70d2d6174b116d") version("1.2.5", sha256="b7bf6b6be6cf23e7966a153fc84d5901c14f01ee952fbd9d930aa48e2385d670") version("1.2.4", sha256="dddb6e208ffa515e68f001c22077a465f1365a4bcf91d9b37f336a6c0d15400d") version("1.2.3", sha256="82c13f40577e10b6f3f0160a21b1e46c00a0c719aa560618b961c453e1b5c80d") version("1.2.2", sha256="3db78771ce8fb8954fb242ed9d4030372523649c5e9c1a9420340020dd0afbc2") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("xproto@7.0.17:") diff --git a/var/spack/repos/builtin/packages/xproperty/package.py b/var/spack/repos/builtin/packages/xproperty/package.py index 9d8a0d1483192d..9944f6da8eb5da 100644 --- a/var/spack/repos/builtin/packages/xproperty/package.py +++ b/var/spack/repos/builtin/packages/xproperty/package.py @@ -20,6 +20,8 @@ class Xproperty(CMakePackage): version("master", branch="master") version("0.11.0", sha256="bf86a11c6758308aa0aa0f64d8dd24cd3e9d78378467b74002f552bfb75fc0eb") + depends_on("cxx", type="build") # generated + depends_on("xtl@0.7.0:0.7", when="@0.11.0:") # C++14 support diff --git a/var/spack/repos/builtin/packages/xproto/package.py b/var/spack/repos/builtin/packages/xproto/package.py index b7403f13bd03cb..fccbd571e4d188 100644 --- a/var/spack/repos/builtin/packages/xproto/package.py +++ b/var/spack/repos/builtin/packages/xproto/package.py @@ -16,7 +16,7 @@ class Xproto(AutotoolsPackage, XorgPackage): but are depended upon by many other X Window System packages to provide common definitions and porting layer.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/x11proto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/x11proto" xorg_mirror_path = "proto/xproto-7.0.31.tar.gz" version("7.0.31", sha256="6d755eaae27b45c5cc75529a12855fed5de5969b367ed05003944cf901ed43c7") diff --git a/var/spack/repos/builtin/packages/xproxymanagementprotocol/package.py b/var/spack/repos/builtin/packages/xproxymanagementprotocol/package.py index a9a148972290ed..b724478e973407 100644 --- a/var/spack/repos/builtin/packages/xproxymanagementprotocol/package.py +++ b/var/spack/repos/builtin/packages/xproxymanagementprotocol/package.py @@ -11,7 +11,7 @@ class Xproxymanagementprotocol(AutotoolsPackage, XorgPackage): way for application servers to easily locate proxy services available to them.""" - homepage = "https://cgit.freedesktop.org/xorg/proto/pmproto" + homepage = "https://gitlab.freedesktop.org/xorg/proto/pmproto" xorg_mirror_path = "proto/xproxymanagementprotocol-1.0.3.tar.gz" version("1.0.3", sha256="c1501045ec781f36b6f867611ab2b4e81be542f5c669b2fd0cc4ec1340c42bcf") diff --git a/var/spack/repos/builtin/packages/xqilla/package.py b/var/spack/repos/builtin/packages/xqilla/package.py index 03efa9b1b4bbdc..e4d7b21ee43746 100644 --- a/var/spack/repos/builtin/packages/xqilla/package.py +++ b/var/spack/repos/builtin/packages/xqilla/package.py @@ -17,6 +17,9 @@ class Xqilla(AutotoolsPackage, SourceforgePackage): version("2.3.3", sha256="8f76b9b4f966f315acc2a8e104e426d8a76ba4ea3441b0ecfdd1e39195674fd6") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("debug", default=False, description="Build a debugging version.") variant("shared", default=True, description="Build shared libraries.") diff --git a/var/spack/repos/builtin/packages/xrandr/package.py b/var/spack/repos/builtin/packages/xrandr/package.py index cbebdf46176c46..a6186fabf53722 100644 --- a/var/spack/repos/builtin/packages/xrandr/package.py +++ b/var/spack/repos/builtin/packages/xrandr/package.py @@ -10,7 +10,7 @@ class Xrandr(AutotoolsPackage, XorgPackage): """xrandr - primitive command line interface to X11 Resize, Rotate, and Reflect (RandR) extension.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xrandr" + homepage = "https://gitlab.freedesktop.org/xorg/app/xrandr" xorg_mirror_path = "app/xrandr-1.5.0.tar.gz" license("MIT") @@ -21,6 +21,8 @@ class Xrandr(AutotoolsPackage, XorgPackage): version("1.5.1", sha256="7b99edb7970a1365eaf5bcaf552144e4dfc3ccf510c4abc08569849929fb366e") version("1.5.0", sha256="ddfe8e7866149c24ccce8e6aaa0623218ae19130c2859cadcaa4228d8bb4a46d") + depends_on("c", type="build") # generated + depends_on("libxrandr@1.5:") depends_on("libxrender") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xrdb/package.py b/var/spack/repos/builtin/packages/xrdb/package.py index d60b5a4ddb0a6a..4b702d444fdbc4 100644 --- a/var/spack/repos/builtin/packages/xrdb/package.py +++ b/var/spack/repos/builtin/packages/xrdb/package.py @@ -9,7 +9,7 @@ class Xrdb(AutotoolsPackage, XorgPackage): """xrdb - X server resource database utility.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xrdb" + homepage = "https://gitlab.freedesktop.org/xorg/app/xrdb" xorg_mirror_path = "app/xrdb-1.1.0.tar.gz" license("MIT") @@ -19,6 +19,8 @@ class Xrdb(AutotoolsPackage, XorgPackage): version("1.1.1", sha256="d19f856296c5f1742a703afc620654efc76fedfb86e1afe0bff9f1038b9e8a47") version("1.1.0", sha256="44b0b6b7b7eb80b83486dfea67c880f6b0059052386c7ddec4d58fd2ad9ae8e9") + depends_on("c", type="build") # generated + depends_on("libxmu") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xrdcl-record/package.py b/var/spack/repos/builtin/packages/xrdcl-record/package.py index 606fade55c4295..684715eb9f8764 100644 --- a/var/spack/repos/builtin/packages/xrdcl-record/package.py +++ b/var/spack/repos/builtin/packages/xrdcl-record/package.py @@ -17,4 +17,6 @@ class XrdclRecord(CMakePackage): version("5.4.2", sha256="fb76284491ff4e723bce4c9e9d87347e98e278e70c597167bc39a162bc876734") + depends_on("cxx", type="build") # generated + depends_on("xrootd") diff --git a/var/spack/repos/builtin/packages/xrefresh/package.py b/var/spack/repos/builtin/packages/xrefresh/package.py index d9fa199988387d..e34713194f08dc 100644 --- a/var/spack/repos/builtin/packages/xrefresh/package.py +++ b/var/spack/repos/builtin/packages/xrefresh/package.py @@ -9,15 +9,18 @@ class Xrefresh(AutotoolsPackage, XorgPackage): """xrefresh - refresh all or part of an X screen.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xrefresh" + homepage = "https://gitlab.freedesktop.org/xorg/app/xrefresh" xorg_mirror_path = "app/xrefresh-1.0.5.tar.gz" license("MIT") + version("1.1.0", sha256="cbf0d3ed80f03188841a96ceb20e615b40a006e3928be2e179d9d5a0ded639b2") version("1.0.7", sha256="f2817920f119bd9146ed3cde223b8a4ab17cb72da4ece7bddde35e18b31aa337") version("1.0.6", sha256="0dda726365d341c00aed0f9cfebf3d2cfaa0c661212c73c0114cbb4ce92f357e") version("1.0.5", sha256="b373cc1ecd37c3d787e7074ce89a8a06ea173d7ba9e73fa48de973c759fbcf38") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("xproto@7.0.17:") diff --git a/var/spack/repos/builtin/packages/xrootd/package.py b/var/spack/repos/builtin/packages/xrootd/package.py index 8b96436899329c..c40619922ecfeb 100644 --- a/var/spack/repos/builtin/packages/xrootd/package.py +++ b/var/spack/repos/builtin/packages/xrootd/package.py @@ -11,14 +11,24 @@ class Xrootd(CMakePackage): """The XROOTD project aims at giving high performance, scalable fault tolerant access to data repositories of many kinds.""" - homepage = "http://xrootd.org" + homepage = "https://xrootd.slac.stanford.edu" url = "https://xrootd.slac.stanford.edu/download/v5.5.1/xrootd-5.5.1.tar.gz" list_url = "https://xrootd.slac.stanford.edu/dload.html" + git = "https://github.com/xrootd/xrootd.git" maintainers("gartung", "greenc-FNAL", "marcmengel", "vitodb", "wdconinc") license("LGPL-3.0-only") + version("5.7.0", sha256="214599bba98bc69875b82ac74f2d4b9ac8a554a1024119d8a9802b3d8b9986f8") + version("5.6.9", sha256="44196167fbcf030d113e3749dfdecab934c43ec15e38e77481e29aac191ca3a8") + version("5.6.8", sha256="19268fd9f0307d936da3598a5eb8471328e059c58f60d91d1ce7305ca0d57528") + version("5.6.7", sha256="4089ce3a69fcf6566d320ef1f4a73a1d6332e6835b7566e17548569bdea78a8d") + version("5.6.6", sha256="b265a75be750472561df9ff321dd0b2102bd64ca19451d312799f501edc597ba") + version("5.6.5", sha256="600874e7c5cdb11d20d6bd6c549b04a3c5beb230d755829726cd15fab99073b1") + version("5.6.4", sha256="52f041ab2eaa4bf7c6087a7246c3d5f90fbab0b0622b57c018b65f60bf677fad") + version("5.6.3", sha256="72000835497f6337c3c6a13c6d39a51fa6a5f3a1ccd34214f2d92f7d47cc6b6c") + version("5.6.2", sha256="7d7c262714268b92dbe370a9ae72275cc07f0cdbed400afd9989c366fed04c00") version("5.6.1", sha256="9afc48ab0fb3ba69611b1edc1b682a185d49b45caf197323eecd1146d705370c") version("5.6.0", sha256="cda0d32d29f94220be9b6627a80386eb33fac2dcc25c8104569eaa4ea3563009") version("5.5.5", sha256="0710caae527082e73d3bf8f9d1dffe95808afd3fcaaaa15ab0b937b8b226bc1f") @@ -54,7 +64,16 @@ class Xrootd(CMakePackage): version("4.4.0", sha256="f066e7488390c0bc50938d23f6582fb154466204209ca92681f0aa06340e77c8") version("4.3.0", sha256="d34865772d975b5d58ad80bb05312bf49aaf124d5431e54dc8618c05a0870e3c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("davix", default=True, description="Build with Davix") + variant( + "ec", + default=True, + description="Build with erasure coding component support", + when="@5.7.0:", + ) variant("http", default=True, description="Build with HTTP support") variant("krb5", default=False, description="Build with KRB5 support") variant("python", default=False, description="Build pyxroot Python extension") @@ -84,7 +103,16 @@ class Xrootd(CMakePackage): values=("98", "11", "14", "17", "20"), multi=False, description="Use the specified C++ standard when building", - when="@5.2.0:", + when="@5.2.0:5.6.99", + ) + + variant( + "cxxstd", + default="17", + values=("98", "11", "14", "17", "20"), + multi=False, + description="Use the specified C++ standard when building", + when="@5.7.0:", ) variant( @@ -112,6 +140,8 @@ class Xrootd(CMakePackage): conflicts("^cmake@:3.0", when="@5.0.0") conflicts("^cmake@:3.15.99", when="@5.5.4:5.5") depends_on("davix", when="+davix") + depends_on("isa-l", when="+ec") + depends_on("pkgconfig", type="build", when="+davix") depends_on("libxml2", when="+http") depends_on("uuid", when="@4.11.0:") depends_on("openssl@:1", when="@:5.4") @@ -193,6 +223,7 @@ def cmake_args(self): define_from_variant("ENABLE_READLINE", "readline"), define_from_variant("ENABLE_KRB5", "krb5"), define_from_variant("ENABLE_SCITOKENS", "scitokens-cpp"), + define_from_variant("ENABLE_XRDEC", "ec"), define_from_variant("XRDCL_ONLY", "client_only"), define("ENABLE_CEPH", False), define("ENABLE_CRYPTO", True), @@ -200,6 +231,7 @@ def cmake_args(self): define("ENABLE_MACAROONS", False), define("ENABLE_VOMS", False), define("FORCE_ENABLED", True), + define("USE_SYSTEM_ISAL", True), ] # see https://github.com/spack/spack/pull/11581 if "+python" in self.spec: diff --git a/var/spack/repos/builtin/packages/xrx/package.py b/var/spack/repos/builtin/packages/xrx/package.py index b354252f5c1ca3..4ff7f058f7190f 100644 --- a/var/spack/repos/builtin/packages/xrx/package.py +++ b/var/spack/repos/builtin/packages/xrx/package.py @@ -14,11 +14,13 @@ class Xrx(AutotoolsPackage, XorgPackage): browser must identify specific instances of the services in the request to invoke the application.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xrx" + homepage = "https://gitlab.freedesktop.org/xorg/app/xrx" xorg_mirror_path = "app/xrx-1.0.4.tar.gz" version("1.0.4", sha256="1ffa1c2af28587c6ed7ded3af2e62e93bad8f9900423d09c45b1d59449d15134") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxt") depends_on("libxext") diff --git a/var/spack/repos/builtin/packages/xsbench/package.py b/var/spack/repos/builtin/packages/xsbench/package.py index 5525b5be471770..f92a0c4fb6fa4a 100644 --- a/var/spack/repos/builtin/packages/xsbench/package.py +++ b/var/spack/repos/builtin/packages/xsbench/package.py @@ -24,6 +24,9 @@ class Xsbench(MakefilePackage, CudaPackage): version("14", sha256="595afbcba8c1079067d5d17eedcb4ab0c1d115f83fd6f8c3de01d74b23015e2d") version("13", sha256="b503ea468d3720a0369304924477b758b3d128c8074776233fa5d567b7ffcaa2") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=True, description="Build with MPI support") variant("openmp", default=True, description="Build with OpenMP support") variant("cuda", default=False, when="@19:", description="Build with CUDA support") diff --git a/var/spack/repos/builtin/packages/xscope/package.py b/var/spack/repos/builtin/packages/xscope/package.py index 43b8a3aa4dcd24..5bbddce9dde678 100644 --- a/var/spack/repos/builtin/packages/xscope/package.py +++ b/var/spack/repos/builtin/packages/xscope/package.py @@ -9,7 +9,7 @@ class Xscope(AutotoolsPackage, XorgPackage): """XSCOPE -- a program to monitor X11/Client conversations.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xscope" + homepage = "https://gitlab.freedesktop.org/xorg/app/xscope" xorg_mirror_path = "app/xscope-1.4.1.tar.gz" license("MIT") @@ -18,6 +18,8 @@ class Xscope(AutotoolsPackage, XorgPackage): version("1.4.2", sha256="e12d634a69ce1ec36b0afd1d40814215e262801a030ddf83d7d0348cd046b381") version("1.4.1", sha256="f99558a64e828cd2c352091ed362ad2ef42b1c55ef5c01cbf782be9735bb6de3") + depends_on("c", type="build") # generated + depends_on("xproto@7.0.17:") depends_on("xtrans") depends_on("pkgconfig", type="build") diff --git a/var/spack/repos/builtin/packages/xsd/package.py b/var/spack/repos/builtin/packages/xsd/package.py index 44fa3fc14b1110..d820ef58fc4b70 100644 --- a/var/spack/repos/builtin/packages/xsd/package.py +++ b/var/spack/repos/builtin/packages/xsd/package.py @@ -18,6 +18,9 @@ class Xsd(MakefilePackage): version("4.0.0", sha256="eca52a9c8f52cdbe2ae4e364e4a909503493a0d51ea388fc6c9734565a859817") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("xerces-c") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/xsdk-examples/package.py b/var/spack/repos/builtin/packages/xsdk-examples/package.py index 4978f57049d925..6a08c12b04c7aa 100644 --- a/var/spack/repos/builtin/packages/xsdk-examples/package.py +++ b/var/spack/repos/builtin/packages/xsdk-examples/package.py @@ -24,6 +24,9 @@ class XsdkExamples(CMakePackage, CudaPackage, ROCmPackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("xsdk+cuda", when="+cuda") depends_on("xsdk~cuda", when="~cuda") for sm_ in CudaPackage.cuda_arch_values: diff --git a/var/spack/repos/builtin/packages/xset/package.py b/var/spack/repos/builtin/packages/xset/package.py index 8727bbdb435fca..ca8b35d147c02f 100644 --- a/var/spack/repos/builtin/packages/xset/package.py +++ b/var/spack/repos/builtin/packages/xset/package.py @@ -9,7 +9,7 @@ class Xset(AutotoolsPackage, XorgPackage): """User preference utility for X.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xset" + homepage = "https://gitlab.freedesktop.org/xorg/app/xset" xorg_mirror_path = "app/xset-1.2.3.tar.gz" license("MIT") @@ -18,6 +18,8 @@ class Xset(AutotoolsPackage, XorgPackage): version("1.2.4", sha256="3a05e8626298c7a79002ec5fb4949dcba8abc7a2b95c03ed5e0f5698c3b4dea0") version("1.2.3", sha256="5ecb2bb2cbf3c9349b735080b155a08c97b314dacedfc558c7f5a611ee1297f7") + depends_on("c", type="build") # generated + depends_on("libxmu") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xsetmode/package.py b/var/spack/repos/builtin/packages/xsetmode/package.py index bc477070784267..0b9012cdb91198 100644 --- a/var/spack/repos/builtin/packages/xsetmode/package.py +++ b/var/spack/repos/builtin/packages/xsetmode/package.py @@ -9,11 +9,13 @@ class Xsetmode(AutotoolsPackage, XorgPackage): """Set the mode for an X Input device.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xsetmode" + homepage = "https://gitlab.freedesktop.org/xorg/app/xsetmode" xorg_mirror_path = "app/xsetmode-1.0.0.tar.gz" version("1.0.0", sha256="9ee0d6cf72dfaacb997f9570779dcbc42f5395ae102180cb19382860b4b02ef3") + depends_on("c", type="build") # generated + depends_on("libxi") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xsetpointer/package.py b/var/spack/repos/builtin/packages/xsetpointer/package.py index 0a77e1f8440269..95fa11e3b00c3e 100644 --- a/var/spack/repos/builtin/packages/xsetpointer/package.py +++ b/var/spack/repos/builtin/packages/xsetpointer/package.py @@ -9,11 +9,13 @@ class Xsetpointer(AutotoolsPackage, XorgPackage): """Set an X Input device as the main pointer.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xsetpointer" + homepage = "https://gitlab.freedesktop.org/xorg/app/xsetpointer" xorg_mirror_path = "app/xsetpointer-1.0.1.tar.gz" version("1.0.1", sha256="54be93b20fd6f1deac67246d6e214a60b02dcfbf05295e43751f7a04edb986ac") + depends_on("c", type="build") # generated + depends_on("libxi", type="link") depends_on("libx11", type="link") depends_on("inputproto@1.4:") diff --git a/var/spack/repos/builtin/packages/xsetroot/package.py b/var/spack/repos/builtin/packages/xsetroot/package.py index 4c701d31dd39b8..51e6ebad4db489 100644 --- a/var/spack/repos/builtin/packages/xsetroot/package.py +++ b/var/spack/repos/builtin/packages/xsetroot/package.py @@ -9,7 +9,7 @@ class Xsetroot(AutotoolsPackage, XorgPackage): """xsetroot - root window parameter setting utility for X.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xsetroot" + homepage = "https://gitlab.freedesktop.org/xorg/app/xsetroot" xorg_mirror_path = "app/xsetroot-1.1.1.tar.gz" license("MIT") @@ -18,6 +18,8 @@ class Xsetroot(AutotoolsPackage, XorgPackage): version("1.1.2", sha256="9d007f5119be09924ac3a5d2bd506f32e6c164b82633c88d2aff26311e1a2a2b") version("1.1.1", sha256="6cdd48757d18835251124138b4a8e4008c3bbc51cf92533aa39c6ed03277168b") + depends_on("c", type="build") # generated + depends_on("libxmu") depends_on("libx11") depends_on("libxcursor") diff --git a/var/spack/repos/builtin/packages/xsimd/package.py b/var/spack/repos/builtin/packages/xsimd/package.py index b17899e084dee5..e869da903cedd6 100644 --- a/var/spack/repos/builtin/packages/xsimd/package.py +++ b/var/spack/repos/builtin/packages/xsimd/package.py @@ -33,6 +33,8 @@ class Xsimd(CMakePackage): version("4.0.0", sha256="67b818601c15ef15ea4d611a8cd7382588c340ebd9146c799a0210d212540455") version("3.1.0", sha256="d56288826f6b82fd9583f83ace6aa2306ba2ae82cec003de1d04ce17fbb1e91f") + depends_on("cxx", type="build") # generated + depends_on("googletest", type="test") # C++14 support diff --git a/var/spack/repos/builtin/packages/xsm/package.py b/var/spack/repos/builtin/packages/xsm/package.py index 5104bb886f8ad4..f14a71f49c5f4e 100644 --- a/var/spack/repos/builtin/packages/xsm/package.py +++ b/var/spack/repos/builtin/packages/xsm/package.py @@ -9,13 +9,15 @@ class Xsm(AutotoolsPackage, XorgPackage): """X Session Manager.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xsm" + homepage = "https://gitlab.freedesktop.org/xorg/app/xsm" xorg_mirror_path = "app/xsm-1.0.3.tar.gz" version("1.0.5", sha256="e8a2f64b5a37be39a81877cd4069745a226a31493080f03ae74b76fb3f17b7a6") version("1.0.4", sha256="d12fb0071719de5845d41602963988e4b889f482427c13ce8e515f5ca51c0564") version("1.0.3", sha256="f70815139d62416dbec5915ec37db66f325932a69f6350bb1a74c0940cdc796a") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxt@1.1.0:") depends_on("libice") diff --git a/var/spack/repos/builtin/packages/xstdcmap/package.py b/var/spack/repos/builtin/packages/xstdcmap/package.py index bf4d21b0edc909..e6935f4fde239b 100644 --- a/var/spack/repos/builtin/packages/xstdcmap/package.py +++ b/var/spack/repos/builtin/packages/xstdcmap/package.py @@ -12,13 +12,15 @@ class Xstdcmap(AutotoolsPackage, XorgPackage): create standard colormap definitions in order to facilitate sharing of scarce colormap resources among clients using PseudoColor visuals.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xstdcmap" + homepage = "https://gitlab.freedesktop.org/xorg/app/xstdcmap" xorg_mirror_path = "app/xstdcmap-1.0.3.tar.gz" version("1.0.5", sha256="70bd5909d6f1b4d9b038593f72ce70b0095a6f773e1dd8059136bbeb021b8771") version("1.0.4", sha256="7b1a23ba7ac623803101b6f9df37889fb1ef2f1bb53da25a415c8a88eebc8073") version("1.0.3", sha256="b97aaa883a9eedf9c3056ea1a7e818e3d93b63aa1f54193ef481d392bdef5711") + depends_on("c", type="build") # generated + depends_on("libxmu") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xtb/package.py b/var/spack/repos/builtin/packages/xtb/package.py index b8bab6d0d17079..6dfc4ed96550a1 100644 --- a/var/spack/repos/builtin/packages/xtb/package.py +++ b/var/spack/repos/builtin/packages/xtb/package.py @@ -20,6 +20,9 @@ class Xtb(MesonPackage): version("6.5.1", sha256="0922205cc224fe79e28f3d75be4e10c03efa8f3f666aedec8346fed82b272cad") version("6.5.0", sha256="5f780656bf7b440a8e1f753a9a877401a7d497fb3160762f48bdefc8a9914976") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + depends_on("blas") depends_on("lapack") depends_on("meson@0.57.2:", type="build") diff --git a/var/spack/repos/builtin/packages/xtcdata/package.py b/var/spack/repos/builtin/packages/xtcdata/package.py index fa87a2f6cf1792..1fb2064788aaad 100644 --- a/var/spack/repos/builtin/packages/xtcdata/package.py +++ b/var/spack/repos/builtin/packages/xtcdata/package.py @@ -16,4 +16,7 @@ class Xtcdata(CMakePackage): version("3.3.37", sha256="127a5ae44c9272039708bd877849a3af354ce881fde093a2fc6fe0550b698b72") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + root_cmakelists_dir = "xtcdata" diff --git a/var/spack/repos/builtin/packages/xtensor-blas/package.py b/var/spack/repos/builtin/packages/xtensor-blas/package.py index c43cd4a4da3cc8..3d4060979afed3 100644 --- a/var/spack/repos/builtin/packages/xtensor-blas/package.py +++ b/var/spack/repos/builtin/packages/xtensor-blas/package.py @@ -23,6 +23,8 @@ class XtensorBlas(CMakePackage): version("0.18.0", sha256="fba992bc08323bc40fd04d6549e50e43b97942624a51e08129102d18c135eec0") version("0.17.2", sha256="2798c7e230d0c4b2d357bba20a0ef23a2b774d892be31ebbf702cb9935ea9f64") + depends_on("cxx", type="build") # generated + depends_on("cmake@3.1:", type="build") # the information below can be found in the xtensor-blas README depends_on("xtensor@0.24.0:", when="@0.20:") diff --git a/var/spack/repos/builtin/packages/xtensor-python/package.py b/var/spack/repos/builtin/packages/xtensor-python/package.py index 0d277428cdf3fd..cd5d6caba30b7e 100644 --- a/var/spack/repos/builtin/packages/xtensor-python/package.py +++ b/var/spack/repos/builtin/packages/xtensor-python/package.py @@ -21,6 +21,8 @@ class XtensorPython(CMakePackage): version("0.23.1", sha256="450b25f5c739df174b2a50774b89e68b23535fdc37cb55bd542ffdb7c78991ab") version("0.17.0", sha256="30f2e8c99376e38f942d62c0d2959bc1e52a562a4f8cc5e27ddc4d572a25e34c") + depends_on("cxx", type="build") # generated + depends_on("xtensor", when="@develop") depends_on("xtensor@0.20.6:0.20", when="@0.23.1") depends_on("xtensor@0.15.1:0.15", when="@0.17.0") diff --git a/var/spack/repos/builtin/packages/xtensor/package.py b/var/spack/repos/builtin/packages/xtensor/package.py index b7f1a3fa9e9858..58c20ab95e585d 100644 --- a/var/spack/repos/builtin/packages/xtensor/package.py +++ b/var/spack/repos/builtin/packages/xtensor/package.py @@ -27,6 +27,8 @@ class Xtensor(CMakePackage): version("0.15.1", sha256="2f4ac632f7aa8c8e9da99ebbfc949d9129b4d644f715ef16c27658bf4fddcdd3") version("0.13.1", sha256="f9ce4cd2110386d49e3f36bbab62da731c557b6289be19bc172bd7209b92a6bc") + depends_on("cxx", type="build") # generated + variant("xsimd", default=True, description="Enable SIMD intrinsics") variant("tbb", default=True, description="Enable TBB parallelization") diff --git a/var/spack/repos/builtin/packages/xtl/package.py b/var/spack/repos/builtin/packages/xtl/package.py index c9d3029548c8d9..f3dcf90fa0bf76 100644 --- a/var/spack/repos/builtin/packages/xtl/package.py +++ b/var/spack/repos/builtin/packages/xtl/package.py @@ -25,6 +25,8 @@ class Xtl(CMakePackage): version("0.3.4", sha256="618536c3998091b0bdd7f8202e8bec9c34e82409c8ee0ea179a2759bdea426e2") version("0.3.3", sha256="1110364c2ea0a2536ec6673e46afcb8fa7e92a66593211270bbeb26b85342600") + depends_on("cxx", type="build") # generated + # C++14 support conflicts("%gcc@:4.8") conflicts("%clang@:3.6") diff --git a/var/spack/repos/builtin/packages/xtrans/package.py b/var/spack/repos/builtin/packages/xtrans/package.py index 83b2c02c38f58e..92a5c73d87dea3 100644 --- a/var/spack/repos/builtin/packages/xtrans/package.py +++ b/var/spack/repos/builtin/packages/xtrans/package.py @@ -12,7 +12,7 @@ class Xtrans(AutotoolsPackage, XorgPackage): single place to add new transport types. It is used by the X server, libX11, libICE, the X font server, and related components.""" - homepage = "https://cgit.freedesktop.org/xorg/lib/libxtrans" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libxtrans" xorg_mirror_path = "lib/xtrans-1.3.5.tar.gz" license("MIT") @@ -23,5 +23,7 @@ class Xtrans(AutotoolsPackage, XorgPackage): version("1.4.0", sha256="48ed850ce772fef1b44ca23639b0a57e38884045ed2cbb18ab137ef33ec713f9") version("1.3.5", sha256="b7a577c1b6c75030145e53b4793db9c88f9359ac49e7d771d4385d21b3e5945d") + depends_on("c", type="build") # generated + depends_on("pkgconfig", type="build") depends_on("util-macros", type="build") diff --git a/var/spack/repos/builtin/packages/xtrap/package.py b/var/spack/repos/builtin/packages/xtrap/package.py index 9f2abfbb095a0b..99fef53039b9e8 100644 --- a/var/spack/repos/builtin/packages/xtrap/package.py +++ b/var/spack/repos/builtin/packages/xtrap/package.py @@ -9,12 +9,14 @@ class Xtrap(AutotoolsPackage, XorgPackage): """XTrap sample clients.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xtrap" + homepage = "https://gitlab.freedesktop.org/xorg/app/xtrap" xorg_mirror_path = "app/xtrap-1.0.2.tar.gz" version("1.0.3", sha256="c6b86b921a748acbf1d82590fbd9c4575f970220760088f0e0efac6fd93d6dc3") version("1.0.2", sha256="e8916e05bfb0d72a088aaaac0feaf4ad7671d0f509d1037fb3c0c9ea131b93d2") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxtrap") diff --git a/var/spack/repos/builtin/packages/xts/package.py b/var/spack/repos/builtin/packages/xts/package.py index 31ff532a8dc482..48597dd682e093 100644 --- a/var/spack/repos/builtin/packages/xts/package.py +++ b/var/spack/repos/builtin/packages/xts/package.py @@ -15,6 +15,8 @@ class Xts(AutotoolsPackage, XorgPackage): version("0.99.1", sha256="d04d987b9a9f8b3921dfe8de8577d0c2a0f21d2c4c3196948fc9805838a352e6") + depends_on("c", type="build") # generated + depends_on("libx11", type="link") depends_on("libxext", type="link") depends_on("libxi", type="link") diff --git a/var/spack/repos/builtin/packages/xv/package.py b/var/spack/repos/builtin/packages/xv/package.py index 30a56226ee54b8..8947f35608f301 100644 --- a/var/spack/repos/builtin/packages/xv/package.py +++ b/var/spack/repos/builtin/packages/xv/package.py @@ -23,7 +23,10 @@ class Xv(CMakePackage): version("4.2.0", sha256="2871338c517a7444fc9d6a3d146bc2c5c7bd98b50c83369b24d24ad49fa0ab87") + depends_on("c", type="build") # generated + depends_on("libjpeg") depends_on("libpng") depends_on("libtiff") depends_on("libx11") + depends_on("libxt") diff --git a/var/spack/repos/builtin/packages/xvidtune/package.py b/var/spack/repos/builtin/packages/xvidtune/package.py index eeb9d3096a2fb9..c1c8dd40928b67 100644 --- a/var/spack/repos/builtin/packages/xvidtune/package.py +++ b/var/spack/repos/builtin/packages/xvidtune/package.py @@ -10,7 +10,7 @@ class Xvidtune(AutotoolsPackage, XorgPackage): """xvidtune is a client interface to the X server video mode extension (XFree86-VidModeExtension).""" - homepage = "https://cgit.freedesktop.org/xorg/app/xvidtune" + homepage = "https://gitlab.freedesktop.org/xorg/app/xvidtune" xorg_mirror_path = "app/xvidtune-1.0.3.tar.gz" license("MIT") @@ -18,6 +18,8 @@ class Xvidtune(AutotoolsPackage, XorgPackage): version("1.0.4", sha256="e5982c9e6c5009f0061c187a9cc82368215bd004cfa464a3d738c90e1d258668") version("1.0.3", sha256="c0e158388d60e1ce054ce462958a46894604bd95e13093f3476ec6d9bbd786d4") + depends_on("c", type="build") # generated + depends_on("libxxf86vm") depends_on("libxt") depends_on("libxaw") diff --git a/var/spack/repos/builtin/packages/xvinfo/package.py b/var/spack/repos/builtin/packages/xvinfo/package.py index 5b1f3aabb1a773..a09ed8ca299b54 100644 --- a/var/spack/repos/builtin/packages/xvinfo/package.py +++ b/var/spack/repos/builtin/packages/xvinfo/package.py @@ -10,7 +10,7 @@ class Xvinfo(AutotoolsPackage, XorgPackage): """xvinfo prints out the capabilities of any video adaptors associated with the display that are accessible through the X-Video extension.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xvinfo" + homepage = "https://gitlab.freedesktop.org/xorg/app/xvinfo" xorg_mirror_path = "app/xvinfo-1.1.3.tar.gz" license("MIT") @@ -19,6 +19,8 @@ class Xvinfo(AutotoolsPackage, XorgPackage): version("1.1.4", sha256="43d06be36fe10f247295fbe2edf1062740064343f2228d6a61b4f9feac4f7396") version("1.1.3", sha256="1c1c2f97abfe114389e94399cc7bf3dfd802ed30ad41ba23921d005bd8a6c39f") + depends_on("c", type="build") # generated + depends_on("libxv") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xwd/package.py b/var/spack/repos/builtin/packages/xwd/package.py index 954b8b2d6d8d52..9f9fd8ccf7e55e 100644 --- a/var/spack/repos/builtin/packages/xwd/package.py +++ b/var/spack/repos/builtin/packages/xwd/package.py @@ -9,7 +9,7 @@ class Xwd(AutotoolsPackage, XorgPackage): """xwd - dump an image of an X window.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xwd" + homepage = "https://gitlab.freedesktop.org/xorg/app/xwd" xorg_mirror_path = "app/xwd-1.0.6.tar.gz" license("custom") @@ -18,6 +18,8 @@ class Xwd(AutotoolsPackage, XorgPackage): version("1.0.7", sha256="1c5e86806234a96a29c90be1872128293c6def5ba69ecb70e161efe325e2ba03") version("1.0.6", sha256="ff01f0a4b736f955aaf7c8c3942211bc52f9fb75d96f2b19777f33fff5dc5b83") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("libxkbfile") diff --git a/var/spack/repos/builtin/packages/xwidgets/package.py b/var/spack/repos/builtin/packages/xwidgets/package.py index aa108f75876e32..2ccdec69e0f35c 100644 --- a/var/spack/repos/builtin/packages/xwidgets/package.py +++ b/var/spack/repos/builtin/packages/xwidgets/package.py @@ -20,6 +20,8 @@ class Xwidgets(CMakePackage): version("master", branch="master") version("0.25.0", sha256="7b6d36999e3b926c40389167c48b33f234a075365f089f89571b33a160421d8e") + depends_on("cxx", type="build") # generated + depends_on("xtl@0.7.0:0.7", when="@0.25.0:") depends_on("xproperty@0.11.0:0.11", when="@0.25.0:") depends_on("xeus@1.0:1", when="@0.25.0:") diff --git a/var/spack/repos/builtin/packages/xwininfo/package.py b/var/spack/repos/builtin/packages/xwininfo/package.py index 57f8308b5d3d35..cbb43815696b65 100644 --- a/var/spack/repos/builtin/packages/xwininfo/package.py +++ b/var/spack/repos/builtin/packages/xwininfo/package.py @@ -10,15 +10,18 @@ class Xwininfo(AutotoolsPackage, XorgPackage): """xwininfo prints information about windows on an X server. Various information is displayed depending on which options are selected.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xwininfo" + homepage = "https://gitlab.freedesktop.org/xorg/app/xwininfo" xorg_mirror_path = "app/xwininfo-1.1.3.tar.gz" license("MIT") + version("1.1.6", sha256="2d52151de9d2808343c715c480e7d37f88958c8b7fcd090178b097436d987c2b") version("1.1.5", sha256="aaa915909bb509320c3c775c79babaccc063fd3edc39e520a3c0352e265e9f58") version("1.1.4", sha256="3561f6c37eec416ad306f41ff24172b86cbed00854dff8912915e97d2cc17c34") version("1.1.3", sha256="784f8b9c9ddab24ce4faa65fde6430a8d7cf3c0564573582452cc99c599bd941") + depends_on("c", type="build") # generated + depends_on("libxcb@1.6:") depends_on("libx11") diff --git a/var/spack/repos/builtin/packages/xwud/package.py b/var/spack/repos/builtin/packages/xwud/package.py index 9a5098c512d0c4..a3aacae4a28b8a 100644 --- a/var/spack/repos/builtin/packages/xwud/package.py +++ b/var/spack/repos/builtin/packages/xwud/package.py @@ -10,13 +10,15 @@ class Xwud(AutotoolsPackage, XorgPackage): """xwud allows X users to display in a window an image saved in a specially formatted dump file, such as produced by xwd.""" - homepage = "https://cgit.freedesktop.org/xorg/app/xwud" + homepage = "https://gitlab.freedesktop.org/xorg/app/xwud" xorg_mirror_path = "app/xwud-1.0.4.tar.gz" version("1.0.6", sha256="262171b0c434966ddbbe8a54afb9615567ad74d4cc2e823e14e51e099ec3ab0d") version("1.0.5", sha256="24d51e236ec3d1dd57c73679136029a14808aee5a2edda152d61598ba018c697") version("1.0.4", sha256="b7c124ccd87f529daedb7ef01c670ce6049fe141fd9ba7f444361de34510cd6c") + depends_on("c", type="build") # generated + depends_on("libx11") depends_on("xproto@7.0.17:") diff --git a/var/spack/repos/builtin/packages/xxd-standalone/package.py b/var/spack/repos/builtin/packages/xxd-standalone/package.py index c0bf61e3c76574..7ba6f40e850f57 100644 --- a/var/spack/repos/builtin/packages/xxd-standalone/package.py +++ b/var/spack/repos/builtin/packages/xxd-standalone/package.py @@ -25,6 +25,9 @@ class XxdStandalone(MakefilePackage): version("8.2.1201", sha256="39032fe866f44724b104468038dc9ac4ff2c00a4b18c9a1e2c27064ab1f1143d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): mkdirp(prefix.bin) install(os.path.join(self.build_directory, "src", "xxd", "xxd"), prefix.bin) diff --git a/var/spack/repos/builtin/packages/xxdiff/package.py b/var/spack/repos/builtin/packages/xxdiff/package.py index 6acd871f836701..52fa2f0a3dbf57 100644 --- a/var/spack/repos/builtin/packages/xxdiff/package.py +++ b/var/spack/repos/builtin/packages/xxdiff/package.py @@ -19,6 +19,9 @@ class Xxdiff(MakefilePackage): version("master", branch="master") version("2023-01-10", commit="604300ea9875611726ba885fb14f872b964df579") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("flex@2.5.31:", type="build") depends_on("bison", type="build") depends_on("qt@5:", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/xxhash/package.py b/var/spack/repos/builtin/packages/xxhash/package.py index 99661986c42598..a4a94e56f39742 100644 --- a/var/spack/repos/builtin/packages/xxhash/package.py +++ b/var/spack/repos/builtin/packages/xxhash/package.py @@ -19,6 +19,7 @@ class Xxhash(MakefilePackage): license("BSD-2-Clause") + version("0.8.2", sha256="baee0c6afd4f03165de7a4e67988d16f0f2b257b51d0e3cb91909302a26a79c4") version("0.8.1", sha256="3bb6b7d6f30c591dd65aaaff1c8b7a5b94d81687998ca9400082c739a690436c") version("0.8.0", sha256="7054c3ebd169c97b64a92d7b994ab63c70dd53a06974f1f630ab782c28db0f4f") version("0.7.4", sha256="4d9706c9da4fbdf901598f5e3b71db0eddd4ac962e827a73ebf75d66dfd820fe") @@ -31,6 +32,9 @@ class Xxhash(MakefilePackage): version("0.5.1", sha256="0171af39eefa06be1e616bc43b250d13bba417e4741135ec85c1fe8dc391997d") version("0.5.0", sha256="9605cd18d40d798eb1262bc0c2a154e1a3c138a6a9a0c4c792e855d0c08c23e1") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + @property def build_targets(self): targets = [] diff --git a/var/spack/repos/builtin/packages/xyce/package.py b/var/spack/repos/builtin/packages/xyce/package.py index 7422419c30ac59..7d1631975c8683 100644 --- a/var/spack/repos/builtin/packages/xyce/package.py +++ b/var/spack/repos/builtin/packages/xyce/package.py @@ -60,6 +60,9 @@ class Xyce(CMakePackage): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("cmake@3.22:", type="build") depends_on("flex") depends_on("bison") diff --git a/var/spack/repos/builtin/packages/xz/package.py b/var/spack/repos/builtin/packages/xz/package.py index 6df6f4d5508da3..a5d4bbc89cecae 100644 --- a/var/spack/repos/builtin/packages/xz/package.py +++ b/var/spack/repos/builtin/packages/xz/package.py @@ -28,6 +28,8 @@ class Xz(MSBuildPackage, AutotoolsPackage, SourceforgePackage): license("GPL-2.0-or-later AND Public-Domain AND LGPL-2.1-or-later", checked_by="tgamblin") + # NOTE: don't add XZ 5.6 until this compromise is resolved: + # https://www.openwall.com/lists/oss-security/2024/03/29/4 version("5.4.6", sha256="913851b274e8e1d31781ec949f1c23e8dbcf0ecf6e73a2436dc21769dd3e6f49") version("5.4.5", sha256="8ccf5fff868c006f29522e386fb4c6a1b66463fbca65a4cfc3c4bd596e895e79") version("5.4.1", sha256="dd172acb53867a68012f94c17389401b2f274a1aa5ae8f84cbfb8b7e383ea8d3") @@ -41,6 +43,8 @@ class Xz(MSBuildPackage, AutotoolsPackage, SourceforgePackage): version("5.2.1", sha256="679148f497e0bff2c1adce42dee5a23f746e71321c33ebb0f641a302e30c2a80") version("5.2.0", sha256="f7357d7455a1670229b3cca021da71dd5d13b789db62743c20624bdffc9cc4a5") + depends_on("c", type="build") # generated + variant("pic", default=False, description="Compile with position independent code.") variant( diff --git a/var/spack/repos/builtin/packages/yade/package.py b/var/spack/repos/builtin/packages/yade/package.py index eabbcc4ccd4b1c..5590d270a3a346 100644 --- a/var/spack/repos/builtin/packages/yade/package.py +++ b/var/spack/repos/builtin/packages/yade/package.py @@ -26,6 +26,8 @@ class Yade(CMakePackage): version("2017.01a", sha256="cd35caa6b6a017ee82f894e7d6f0826fddc1d921aea04b5896d3f1da95cb649b") version("2016.06a", sha256="6e7374d2dcb7c90026be9229a6b30373f9d82fdefd3dc1f952aa6262924f2579") + depends_on("cxx", type="build") # generated + depends_on("cmake", type="build") depends_on("gcc@11.4:", type=("build", "run")) depends_on("boost@1.47:", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/yafyaml/package.py b/var/spack/repos/builtin/packages/yafyaml/package.py index 5959d295f292b8..5d2f4e3ff2a610 100644 --- a/var/spack/repos/builtin/packages/yafyaml/package.py +++ b/var/spack/repos/builtin/packages/yafyaml/package.py @@ -49,6 +49,8 @@ class Yafyaml(CMakePackage): version("0.5.1", sha256="7019460314e388b2d556db75d5eb734237a18494f79b921613addb96b7b7ce2f") version("0.5.0", sha256="8ac5d41b1020e9311ac87f50dbd61b9f3e3188f3599ce463ad59650208fdb8ad") + depends_on("fortran", type="build") # generated + depends_on("gftl-shared") depends_on("gftl") depends_on("cmake@3.12:", type="build") diff --git a/var/spack/repos/builtin/packages/yaksa/package.py b/var/spack/repos/builtin/packages/yaksa/package.py index e24ee70d050be5..7a3c16d023d5d9 100644 --- a/var/spack/repos/builtin/packages/yaksa/package.py +++ b/var/spack/repos/builtin/packages/yaksa/package.py @@ -29,6 +29,8 @@ class Yaksa(AutotoolsPackage, CudaPackage, ROCmPackage): version("0.3", sha256="c9e5291211bee8852831bb464f430ad5ba1541e31db5718a6fa2f2d3329fc2d9") version("0.2", sha256="9401cb6153dc8c34ddb9781bbabd418fd26b0a27b5da3294ecc21af7be9c86f2") + depends_on("c", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/yambo/package.py b/var/spack/repos/builtin/packages/yambo/package.py index d554b0bbbc9719..8b9609b7346059 100644 --- a/var/spack/repos/builtin/packages/yambo/package.py +++ b/var/spack/repos/builtin/packages/yambo/package.py @@ -22,11 +22,15 @@ class Yambo(AutotoolsPackage): license("GPL-2.0-or-later") + version("5.2.1", sha256="0ac362854313927d75bbf87be98ff58447f3805f79724c38dc79df07f03a7046") version("5.1.1", sha256="c85036ca60507e627c47b6c6aee8241830349e88110e1ce9132ef03ab2c4e9f6") version("4.2.2", sha256="86b4ebe679387233266aba49948246c85a32b1e6840d024f162962bd0112448c") version("4.2.1", sha256="8ccd0ca75cc32d9266d4a37edd2a7396cf5038f3a68be07c0f0f77d1afc72bdc") version("4.2.0", sha256="9f78c4237ff363ff4e9ea5eeea671b6fff783d9a6078cc31b0b1abeb1f040f4d") + depends_on("c", type="build") # generated + depends_on("fortran", type="build") # generated + variant("dp", default=False, description="Enable double precision") variant( "profile", @@ -94,7 +98,7 @@ def configure_args(self): # As of version 4.2.1 there are hard-coded paths that make # the build process fail if the target prefix is not the # configure directory - "--prefix={0}".format(self.stage.source_path), + f"--prefix={self.stage.source_path}", "--disable-keep-objects", "--with-editor=none", ] @@ -111,7 +115,7 @@ def configure_args(self): args.extend(self.enable_or_disable("openmp")) # LAPACK - if "+mpi" in spec: + if spec.satisfies("+mpi"): args.append( "--with-scalapack-libs={0}".format( spec["scalapack"].libs + spec["lapack"].libs + spec["blas"].libs @@ -119,10 +123,7 @@ def configure_args(self): ) args.extend( - [ - "--with-blas-libs={0}".format(spec["blas"].libs), - "--with-lapack-libs={0}".format(spec["lapack"].libs), - ] + [f"--with-blas-libs={spec['blas'].libs}", f"--with-lapack-libs={spec['lapack'].libs}"] ) # Netcdf @@ -130,17 +131,17 @@ def configure_args(self): [ "--enable-netcdf-hdf5", "--enable-hdf5-compression", - "--with-hdf5-libs={0}".format(spec["hdf5"].libs), - "--with-netcdf-path={0}".format(spec["netcdf-c"].prefix), - "--with-netcdff-path={0}".format(spec["netcdf-fortran"].prefix), + f"--with-hdf5-libs={spec['hdf5'].libs}", + f"--with-netcdf-path={spec['netcdf-c'].prefix}", + f"--with-netcdff-path={spec['netcdf-fortran'].prefix}", ] ) args.extend(self.enable_or_disable("io")) # Other dependencies - args.append("--with-fft-path={0}".format(spec["fftw"].prefix)) - args.append("--with-libxc-path={0}".format(spec["libxc"].prefix)) + args.append(f"--with-fft-path={spec['fftw'].prefix}") + args.append(f"--with-libxc-path={spec['libxc'].prefix}") return args diff --git a/var/spack/repos/builtin/packages/yaml-cpp/package.py b/var/spack/repos/builtin/packages/yaml-cpp/package.py index 5954481cff980c..4107b769dc7b7e 100644 --- a/var/spack/repos/builtin/packages/yaml-cpp/package.py +++ b/var/spack/repos/builtin/packages/yaml-cpp/package.py @@ -27,6 +27,8 @@ class YamlCpp(CMakePackage): version("0.5.3", sha256="decc5beabb86e8ed9ebeb04358d5363a5c4f72d458b2c788cb2f3ac9c19467b2") version("0.3.0", sha256="ab8d0e07aa14f10224ed6682065569761f363ec44bc36fcdb2946f6d38fe5a89") + depends_on("cxx", type="build") # generated + variant("shared", default=True, description="Build shared instead of static libraries") variant("pic", default=True, description="Build with position independent code") variant("tests", default=False, description="Build yaml-cpp tests using internal gtest") diff --git a/var/spack/repos/builtin/packages/yara/package.py b/var/spack/repos/builtin/packages/yara/package.py index e80978bd1c83db..7b2da9e1e8767d 100644 --- a/var/spack/repos/builtin/packages/yara/package.py +++ b/var/spack/repos/builtin/packages/yara/package.py @@ -17,6 +17,9 @@ class Yara(AutotoolsPackage): version("3.9.0", sha256="ebe7fab0abadb90449a62afbd24e196e18b177efe71ffd8bf22df95c5386f64d") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/yasm/package.py b/var/spack/repos/builtin/packages/yasm/package.py index 4c2f9ae8b690a4..46a921ac91e328 100644 --- a/var/spack/repos/builtin/packages/yasm/package.py +++ b/var/spack/repos/builtin/packages/yasm/package.py @@ -21,6 +21,8 @@ class Yasm(AutotoolsPackage): version("develop", branch="master") version("1.3.0", sha256="3dce6601b495f5b3d45b59f7d2492a340ee7e84b5beca17e48f862502bd5603f") + depends_on("c", type="build") # generated + depends_on("autoconf", when="@develop") depends_on("automake", when="@develop") depends_on("libtool", when="@develop") diff --git a/var/spack/repos/builtin/packages/yoda/package.py b/var/spack/repos/builtin/packages/yoda/package.py index 1360dd130615b1..a545be413a6d75 100644 --- a/var/spack/repos/builtin/packages/yoda/package.py +++ b/var/spack/repos/builtin/packages/yoda/package.py @@ -17,6 +17,13 @@ class Yoda(AutotoolsPackage): license("GPL-3.0-or-later") + version("2.0.0", sha256="680f43dabebb3167ce1c5dee72d1c2c285c3190751245aa51e3260a005a99575") + version( + "1.9.10", + sha256="0a708ee9d704945d3387cc437b15ffddf382c70fe5bab39ed2bdbf83c2c28c6f", + preferred=True, + ) + version("1.9.9", sha256="ebcad55369a1cedcee3a2de059407c851652ba44495113f5c09d8c2e57f516aa") version("1.9.8", sha256="7bc3062468abba50aff3ecb8b22ce677196036009890688ef4533aaa7f92e6e4") version("1.9.7", sha256="8d07bb04dcb79364858718a18203452d8d9fa00029fa94239eafa8529032b8ff") version("1.9.6", sha256="21523fa2f6b6c8f3348959f3a948734a930ca25951d3c9190b4424e13735f2a4") @@ -66,6 +73,9 @@ class Yoda(AutotoolsPackage): version("1.0.4", sha256="697fe397c69689feecb2a731e19b2ff85e19343b8198c4f18a7064c4f7123950") version("1.0.3", sha256="6a1d1d75d9d74da457726ea9463c1b0b6ba38d4b43ef54e1c33f885e70fdae4b") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("root", default=False, description="Enable ROOT interface") depends_on("python", type=("build", "link", "run")) diff --git a/var/spack/repos/builtin/packages/yorick/package.py b/var/spack/repos/builtin/packages/yorick/package.py index fa3ef816f07b89..c4a97d688be80d 100644 --- a/var/spack/repos/builtin/packages/yorick/package.py +++ b/var/spack/repos/builtin/packages/yorick/package.py @@ -24,6 +24,10 @@ class Yorick(Package): version("2.2.04", sha256="4a4f3a18aed533cc5fadbb3d4bafb48f04834a22cbff6ad5c19d9dba74facbda") version("f90-plugin", branch="f90-plugin") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + variant("X", default=False, description="Enable X11 support") depends_on("libx11", when="+X") diff --git a/var/spack/repos/builtin/packages/yosys/package.py b/var/spack/repos/builtin/packages/yosys/package.py index 5af8c37e8c677d..e407d7a18a1e75 100644 --- a/var/spack/repos/builtin/packages/yosys/package.py +++ b/var/spack/repos/builtin/packages/yosys/package.py @@ -20,7 +20,7 @@ class Yosys(MakefilePackage): """ homepage = "https://yosyshq.net/yosys" - url = "https://github.com/YosysHQ/yosys/archive/refs/tags/yosys-0.37.tar.gz" + url = "https://github.com/YosysHQ/yosys/archive/refs/tags/yosys-0.40.tar.gz" git = "https://github.com/YosysHQ/yosys.git" maintainers("davekeeshan") @@ -29,6 +29,9 @@ class Yosys(MakefilePackage): version("master", branch="master") + version("0.41", sha256="b0037d0a5864550a07a72ba81346e52a7d5f76b3027ef1d7c71b975d2c8bd2b2") + version("0.40", sha256="c1d42ad90d587b587210b40cf3c5584e41e20f656e8630c33b6583322e8b764e") + version("0.39", sha256="a66d95747b21d03e5b9c274d3f7cb0f7dd99610891dd66920bfaee25bc30dad1") version("0.38", sha256="5f3d7bb12c5371db00586700a658a9196008a9457839f046403a660fe0c7a1df") version("0.37", sha256="98e91253b116728e5db037512a4d837529d408269358f06fe7b4633c89cf8756") version("0.36", sha256="d69beedcb76db80681c2a0f445046311f3ba16716d5d0c3c5034dabcb6bd9b23") @@ -49,6 +52,9 @@ class Yosys(MakefilePackage): version("0.21", sha256="2b0e140f47d682e1069b1ca53b1fd91cbb1c1546932bd5cb95566f59a673cd8d") version("0.20", sha256="ee261487badf1b554616d555da8496a7c84ef21ae66a979ddd946b6949a780a4") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("abc", default=True, description="build with abc support") variant("ccache", default=False, description="build with ccache support") @@ -57,7 +63,7 @@ class Yosys(MakefilePackage): depends_on("bison") depends_on("libffi") depends_on("readline") - depends_on("pkg-config") + depends_on("pkgconfig") depends_on("tcl") depends_on("zlib") depends_on("llvm") diff --git a/var/spack/repos/builtin/packages/yq/package.py b/var/spack/repos/builtin/packages/yq/package.py new file mode 100644 index 00000000000000..e3f74037b0aa20 --- /dev/null +++ b/var/spack/repos/builtin/packages/yq/package.py @@ -0,0 +1,23 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Yq(GoPackage): + """yq is a portable command-line YAML, JSON, XML, CSV, TOML and properties processor. + This is different from the py-yq package that is a wrapper around jq.""" + + homepage = "https://mikefarah.gitbook.io/yq" + url = "https://github.com/mikefarah/yq/archive/refs/tags/v4.43.1.tar.gz" + + maintainers("teaguesterling") + + license("MIT", checked_by="teaguesterling") + + version("4.43.1", sha256="e5581d28bae2bcdf70501dfd251233c592eb3e39a210956ee74965b784435d63") + version("4.41.1", sha256="25d61e72887f57510f88d1a30d515c7e2d79e7c6dce5c96aea7c069fcbc089e7") + version("4.40.7", sha256="c38024d40ee37d26caba1824965d9ea1d65468f48b2bacd45647ff4f547fa59f") + version("4.35.2", sha256="8b17d710c56f764e9beff06d7a7b1c77d87c4ba4219ce4ce67e7ee29670f4f13") diff --git a/var/spack/repos/builtin/packages/z-checker/package.py b/var/spack/repos/builtin/packages/z-checker/package.py index fde46b05137a8c..87c22c954768a5 100644 --- a/var/spack/repos/builtin/packages/z-checker/package.py +++ b/var/spack/repos/builtin/packages/z-checker/package.py @@ -23,6 +23,9 @@ class ZChecker(AutotoolsPackage): version("0.6.0", sha256="b01c2c78157234a734c2f4c10a7ab82c329d3cd1a8389d597e09386fa33a3117") version("0.5.0", sha256="ad5e68472c511b393ee1ae67d2e3072a22004001cf19a14bd99a2e322a6ce7f9") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("mpi", default=False, description="Enable mpi compilation") depends_on("mpi", when="+mpi") diff --git a/var/spack/repos/builtin/packages/z3/package.py b/var/spack/repos/builtin/packages/z3/package.py index e386e050c848ce..219fbe7b15ab75 100644 --- a/var/spack/repos/builtin/packages/z3/package.py +++ b/var/spack/repos/builtin/packages/z3/package.py @@ -28,6 +28,9 @@ class Z3(CMakePackage): version("4.8.7", sha256="8c1c49a1eccf5d8b952dadadba3552b0eac67482b8a29eaad62aa7343a0732c3") version("4.5.0", sha256="aeae1d239c5e06ac183be7dd853775b84698db1265cb2258e5918a28372d4a0c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("python", default=False, description="Enable python binding") depends_on("python", type="build", when="~python") depends_on("python", type=("build", "run"), when="+python") @@ -53,13 +56,6 @@ def cmake_args(self): ] if spec.satisfies("+python"): - args.append( - self.define( - "CMAKE_INSTALL_PYTHON_PKG_DIR", - join_path( - prefix.lib, "python%s" % spec["python"].version.up_to(2), "site-packages" - ), - ) - ) + args.append(self.define("CMAKE_INSTALL_PYTHON_PKG_DIR", python_platlib)) return args diff --git a/var/spack/repos/builtin/packages/zabbix/package.py b/var/spack/repos/builtin/packages/zabbix/package.py index 0d3b389b73360b..aeb8bfd1d11037 100644 --- a/var/spack/repos/builtin/packages/zabbix/package.py +++ b/var/spack/repos/builtin/packages/zabbix/package.py @@ -19,6 +19,9 @@ class Zabbix(AutotoolsPackage): version("4.0.24", sha256="c7e4962d745277d67797d90e124555ce27d198822a7e65c55d86aee45d3e93fc") version("4.0.23", sha256="652143614f52411cad47db64e93bf3ba1cd547d6ca9591296223b5f0528b3b61") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("autoconf", type="build") depends_on("automake", type="build") depends_on("libtool", type="build") diff --git a/var/spack/repos/builtin/packages/zerosum/package.py b/var/spack/repos/builtin/packages/zerosum/package.py new file mode 100644 index 00000000000000..01b16b70decf9c --- /dev/null +++ b/var/spack/repos/builtin/packages/zerosum/package.py @@ -0,0 +1,76 @@ +# Copyright 2013-2024 Lawrence Livermore National Security, LLC and other +# Spack Project Developers. See the top-level COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class Zerosum(CMakePackage): + """Utility for monitoring process, thread, OS and HW resources, + including GPU utilization. + """ + + homepage = "https://github.com/UO-OACISS/zerosum" + url = "https://github.com/UO-OACISS/zerosum.git" + git = "https://github.com/UO-OACISS/zerosum" + + maintainers("khuck", "wspear", "sameershende") + + license("MIT", checked_by="khuck") + + version("main", branch="main") + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + + variant("perfstubs", default=True, description="Enable PerfStubs support") + variant("hwloc", default=True, description="Enable HWLOC support") + variant("mpi", default=True, description="Enable MPI support") + variant("cuda", default=False, description="Enable CUDA support") + variant("hip", default=False, description="Enable HIP support") + variant("sycl", default=False, description="Enable SYCL support") + variant("openmp", default=True, description="Enable OpenMP support") + # GCC has no support for OMPT, and doesn't plan to add it any time soon. + # For that reason, we disable OMPT support by default. + variant("ompt", default=False, when="%gcc", description="Enable OpenMP Tools support") + # All other compilers default to having the support enabled. + # This works because Spack allows overriding of variants: + # "When a variant is defined multiple times, whether in the same package + # file or in a subclass and a superclass, the _last_ definition is used + # for all attributes except for the when clauses." + variant("ompt", default=True, description="Enable OpenMP Tools support") + + depends_on("cmake", type="build") + depends_on("hwloc", when="+hwloc") + depends_on("mpi", when="+mpi") + depends_on("rocm-smi-lib", when="+hip") + depends_on("cuda", when="+cuda") + depends_on("hip", when="+hip") + depends_on("sycl", when="+sycl") + + # GCC has no support for OMPT, and doesn't plan to add it any time soon. + # For that reason, we let the user know this support is not allowed. + conflicts("+ompt", when="%gcc") + + conflicts("platform=darwin", msg="zerosum runs only on Linux.") + conflicts("platform=windows", msg="zerosum runs only on Linux.") + + def cmake_args(self): + args = [ + self.define_from_variant("ZeroSum_WITH_PerfStubs", "perfstubs"), + self.define_from_variant("ZeroSum_WITH_HWLOC", "hwloc"), + self.define_from_variant("ZeroSum_WITH_MPI", "mpi"), + self.define_from_variant("ZeroSum_WITH_CUDA", "cuda"), + self.define_from_variant("ZeroSum_WITH_HIP", "hip"), + self.define_from_variant("ZeroSum_WITH_SYCL", "sycl"), + self.define_from_variant("ZeroSum_WITH_OPENMP", "openmp"), + self.define_from_variant("ZeroSum_WITH_OMPT", "ompt"), + ] + + if "+cuda" in self.spec: + args.append(self.define("CUDAToolkit_ROOT", self.spec["cuda"].prefix)) + if "+hip" in self.spec: + args.append(self.define("ROCM_ROOT}", self.spec["hip"].prefix)) + + return args diff --git a/var/spack/repos/builtin/packages/zfp/package.py b/var/spack/repos/builtin/packages/zfp/package.py index 805c4dcafd3e82..00c671ddc9d4a4 100644 --- a/var/spack/repos/builtin/packages/zfp/package.py +++ b/var/spack/repos/builtin/packages/zfp/package.py @@ -43,6 +43,10 @@ class Zfp(CMakePackage, CudaPackage): url="https://github.com/LLNL/zfp/archive/0.5.1/zfp-0.5.1.tar.gz", ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + # Dependencies depends_on("cmake@3.9.0:", type="build") depends_on("cuda@7:", type=("build", "test", "run"), when="+cuda") diff --git a/var/spack/repos/builtin/packages/zfs/package.py b/var/spack/repos/builtin/packages/zfs/package.py index fb31c68811b315..b4197c639a4977 100644 --- a/var/spack/repos/builtin/packages/zfs/package.py +++ b/var/spack/repos/builtin/packages/zfs/package.py @@ -22,6 +22,8 @@ class Zfs(AutotoolsPackage): version("0.8.1", sha256="0af79fde44b7b8ecb94d5166ce2e4fff7409c20ed874c2d759db92909e6c2799") version("0.8.0", sha256="0fd92e87f4b9df9686f18e2ac707c16b2eeaf00f682d41c20ea519f3a0fe4705") + depends_on("c", type="build") # generated + depends_on("uuid") depends_on("libtirpc") depends_on("util-linux") diff --git a/var/spack/repos/builtin/packages/zig/package.py b/var/spack/repos/builtin/packages/zig/package.py index cfeda3ac65c28b..aea0a86818ce81 100644 --- a/var/spack/repos/builtin/packages/zig/package.py +++ b/var/spack/repos/builtin/packages/zig/package.py @@ -17,11 +17,13 @@ class Zig(CMakePackage): license("MIT") + version("0.13.0", tag="0.13.0", commit="cf90dfd3098bef5b3c22d5ab026173b3c357f2dd") + version("0.12.0", tag="0.12.0", commit="a685ab1499d6560c523f0dbce2890dc140671e43") version("0.11.0", tag="0.11.0", commit="67709b638224ac03820226c6744d8b6ead59184c") version("0.10.1", tag="0.10.1", commit="b57081f039bd3f8f82210e8896e336e3c3a6869b") - version( - "0.9.1", tag="0.9.1", commit="6d44a6222d6eba600deb7f16c124bfa30628fb60", deprecated=True - ) + + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated variant( "build_type", @@ -31,9 +33,10 @@ class Zig(CMakePackage): ) depends_on("llvm targets=all") - depends_on("llvm@13", when="@0.9.1") depends_on("llvm@15", when="@0.10.1") depends_on("llvm@16", when="@0.11.0") + depends_on("llvm@17", when="@0.12.0") + depends_on("llvm@18", when="@0.13.0") depends_on("git", type="build") depends_on("ccache") diff --git a/var/spack/repos/builtin/packages/zip/11-typo-it-is-ambiguities-not-amgibuities.patch b/var/spack/repos/builtin/packages/zip/11-typo-it-is-ambiguities-not-amgibuities.patch new file mode 100644 index 00000000000000..aa61ba5fc5be19 --- /dev/null +++ b/var/spack/repos/builtin/packages/zip/11-typo-it-is-ambiguities-not-amgibuities.patch @@ -0,0 +1,26 @@ +From: Santiago Vila +Subject: manpage typo: amgibuities -> ambiguities +X-Debian-version: 3.0-12 + +--- a/man/zip.1 ++++ b/man/zip.1 +@@ -297,7 +297,7 @@ + If Zip64 support for large files and archives is enabled and + \fIzip\fR is used as a filter, \fIzip\fR creates a Zip64 archive + that requires a PKZIP 4.5 or later compatible unzip to read it. This is +-to avoid amgibuities in the zip file structure as defined in the current ++to avoid ambiguities in the zip file structure as defined in the current + zip standard (PKWARE AppNote) where the decision to use Zip64 needs to + be made before data is written for the entry, but for a stream the size + of the data is not known at that point. If the data is known to be smaller +--- a/zip.txt ++++ b/zip.txt +@@ -184,7 +184,7 @@ + + If Zip64 support for large files and archives is enabled and zip is + used as a filter, zip creates a Zip64 archive that requires a PKZIP 4.5 +- or later compatible unzip to read it. This is to avoid amgibuities in ++ or later compatible unzip to read it. This is to avoid ambiguities in + the zip file structure as defined in the current zip standard (PKWARE + AppNote) where the decision to use Zip64 needs to be made before data + is written for the entry, but for a stream the size of the data is not diff --git a/var/spack/repos/builtin/packages/zip/12-gcc14-no-implicit-declarations-fix.patch b/var/spack/repos/builtin/packages/zip/12-gcc14-no-implicit-declarations-fix.patch new file mode 100644 index 00000000000000..2f2f7c164b7c36 --- /dev/null +++ b/var/spack/repos/builtin/packages/zip/12-gcc14-no-implicit-declarations-fix.patch @@ -0,0 +1,71 @@ +diff --git a/unix/configure b/unix/configure +index 6a3d1d9..148a6d6 100644 +--- a/unix/configure ++++ b/unix/configure +@@ -509,17 +509,32 @@ $CC $CFLAGS -c conftest.c >/dev/null 2>/dev/null + # Check for missing functions + # add NO_'function_name' to flags if missing + +-for func in rmdir strchr strrchr rename mktemp mktime mkstemp ++for func_hdr in unistd/rmdir string/strchr string/strrchr stdio/renaae \ ++ stdlib/mktemp time/mktime stdlib/mkstemp + do +- echo Check for $func ++ hdr=${func_hdr%/*} ++ func=${func_hdr#*/} ++ echo -n Check for $func + echo "int main(){ $func(); return 0; }" > conftest.c + $CC $BFLAG -o conftest conftest.c >/dev/null 2>/dev/null +- [ $? -ne 0 ] && CFLAGS="${CFLAGS} -DNO_`echo $func | tr '[a-z]' '[A-Z]'`" +-done ++ if [ $? -ne 0 ] ; then ++ echo " ... in $hdr" ++ cat > conftest.c << _EOF_ ++#include <$hdr.h> ++int main(){ $func(); return 0; } ++_EOF_ ++ [ $? -ne 0 ] && CFLAGS="${CFLAGS} -DNO_`echo $func | tr '[a-z]' '[A-Z]'`" ++ else ++ echo ++ fi ++ done + + + echo Check for memset +-echo "int main(){ char k; memset(&k,0,0); return 0; }" > conftest.c ++cat > conftest.c << _EOF_ ++#include ++int main(){ char k; memset(&k,0,0); return 0; } ++_EOF_ + $CC -o conftest conftest.c >/dev/null 2>/dev/null + [ $? -ne 0 ] && CFLAGS="${CFLAGS} -DZMEM" + +@@ -544,7 +559,7 @@ $CC -o conftest conftest.c >/dev/null 2>/dev/null + echo Check for errno declaration + cat > conftest.c << _EOF_ + #include +-main() ++int main() + { + errno = 0; + return 0; +@@ -556,6 +571,7 @@ $CC $CFLAGS -c conftest.c >/dev/null 2>/dev/null + + echo Check for directory libraries + cat > conftest.c << _EOF_ ++#include + int main() { return closedir(opendir(".")); } + _EOF_ + +diff --git a/timezone.c b/timezone.c +index 485ec02..325fd5a 100644 +--- a/timezone.c ++++ b/timezone.c +@@ -39,6 +39,7 @@ + + #include "zip.h" + #include "timezone.h" ++#include + #include + #include + diff --git a/var/spack/repos/builtin/packages/zip/package.py b/var/spack/repos/builtin/packages/zip/package.py index 354f6d624d7365..3e387ec029053c 100644 --- a/var/spack/repos/builtin/packages/zip/package.py +++ b/var/spack/repos/builtin/packages/zip/package.py @@ -18,6 +18,8 @@ class Zip(MakefilePackage): version("3.0", sha256="f0e8bb1f9b7eb0b01285495a2699df3a4b766784c1765a8f1aeedf63c0806369") + depends_on("c", type="build") # generated + depends_on("bzip2") # Upstream is unmaintained, get patches from: @@ -32,6 +34,11 @@ class Zip(MakefilePackage): patch("08-hardening-build-fix-1.patch") patch("09-hardening-build-fix-2.patch") patch("10-remove-build-date.patch") + patch("11-typo-it-is-ambiguities-not-amgibuities.patch") + + # Configure and header changes needed for comatibility with strict gcc14+ + # these are not from the debian branch + patch("12-gcc14-no-implicit-declarations-fix.patch", when="%gcc@14:") executables = ["^zip$"] @@ -42,7 +49,7 @@ def determine_version(cls, exe): return match.group(1) if match else None def url_for_version(self, version): - return "http://downloads.sourceforge.net/infozip/zip{0}.tar.gz".format(version.joined) + return f"http://downloads.sourceforge.net/infozip/zip{version.joined}.tar.gz" def build(self, spec, prefix): make("-f", "unix/Makefile", "CC=" + spack_cc, "generic") diff --git a/var/spack/repos/builtin/packages/zlib-ng/package.py b/var/spack/repos/builtin/packages/zlib-ng/package.py index 26cdcb7c28f35b..c8d8a98addd9c9 100644 --- a/var/spack/repos/builtin/packages/zlib-ng/package.py +++ b/var/spack/repos/builtin/packages/zlib-ng/package.py @@ -18,24 +18,24 @@ class ZlibNg(AutotoolsPackage, CMakePackage): license("Zlib") + version("2.2.1", sha256="ec6a76169d4214e2e8b737e0850ba4acb806c69eeace6240ed4481b9f5c57cdf") + version("2.1.7", sha256="59e68f67cbb16999842daeb517cdd86fc25b177b4affd335cd72b76ddc2a46d8") version("2.1.6", sha256="a5d504c0d52e2e2721e7e7d86988dec2e290d723ced2307145dedd06aeb6fef2") version("2.1.5", sha256="3f6576971397b379d4205ae5451ff5a68edf6c103b2f03c4188ed7075fbb5f04") version("2.1.4", sha256="a0293475e6a44a3f6c045229fe50f69dc0eebc62a42405a51f19d46a5541e77a") - version( - "2.1.3", - sha256="d20e55f89d71991c59f1c5ad1ef944815e5850526c0d9cd8e504eaed5b24491a", - deprecated=True, - ) - version( - "2.1.2", - sha256="383560d6b00697c04e8878e26c0187b480971a8bce90ffd26a5a7b0f7ecf1a33", - deprecated=True, - ) version("2.0.7", sha256="6c0853bb27738b811f2b4d4af095323c3d5ce36ceed6b50e5f773204fb8f7200") version("2.0.0", sha256="86993903527d9b12fc543335c19c1d33a93797b3d4d37648b5addae83679ecd8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("compat", default=True, description="Enable compatibility API") variant("opt", default=True, description="Enable optimizations") + variant("shared", default=True, description="Build shared library") + variant("pic", default=True, description="Enable position-independent code (PIC)") + + conflicts("+shared~pic") + variant("new_strategies", default=True, description="Enable new deflate strategies") provides("zlib-api", when="+compat") @@ -44,30 +44,44 @@ class ZlibNg(AutotoolsPackage, CMakePackage): # reused. build_system("autotools", "cmake", default="autotools") - # rpath shenanigans, see https://github.com/zlib-ng/zlib-ng/pull/1546 - with when("@2.1.3"): - patch("pr-1546.patch", when="platform=darwin") - patch("pr-1542.patch") # fix sse4.2 detection - patch("pr-1561.patch", when="build_system=autotools") # drop bash dependency - patch("pr-1562.patch") # improve intrinsics detection + # fix building with NVHPC, see https://github.com/zlib-ng/zlib-ng/pull/1698 + patch("pr-1698.patch", when="@2.1.4:%nvhpc+opt") with when("build_system=cmake"): depends_on("cmake@3.5.1:", type="build") depends_on("cmake@3.14.0:", type="build", when="@2.1.0:") + conflicts("%nvhpc@:20", msg="the compiler is too old and too broken") + @property def libs(self): name = "libz" if self.spec.satisfies("+compat") else "libz-ng" - return find_libraries(name, root=self.prefix, recursive=True, shared=True) + return find_libraries( + name, root=self.prefix, recursive=True, shared=self.spec.satisfies("+shared") + ) + + def flag_handler(self, name, flags): + if name == "cflags" and self.spec.satisfies("+pic build_system=autotools"): + flags.append(self.compiler.cc_pic_flag) + return (flags, None, None) class AutotoolsBuilder(autotools.AutotoolsBuilder): + @run_before("configure") + def pretend_gcc(self): + # All nice things (PIC flags, symbol versioning) that happen to the compilers that are + # recognized as gcc (%gcc, %clang, %intel, %oneapi) we want for some other compilers too: + if self.spec.compiler.name in ["nvhpc"]: + filter_file(r"^gcc=0$", "gcc=1", join_path(self.configure_directory, "configure")) + def configure_args(self): args = [] if self.spec.satisfies("+compat"): args.append("--zlib-compat") if self.spec.satisfies("~opt"): args.append("--without-optimizations") + if self.spec.satisfies("~shared"): + args.append("--static") if self.spec.satisfies("~new_strategies"): args.append("--without-new-strategies") return args @@ -78,5 +92,8 @@ def cmake_args(self): return [ self.define_from_variant("ZLIB_COMPAT", "compat"), self.define_from_variant("WITH_OPTIM", "opt"), + self.define("BUILD_SHARED_LIBS", self.spec.satisfies("+shared")), + self.define_from_variant("CMAKE_POSITION_INDEPENDENT_CODE", "pic"), self.define_from_variant("WITH_NEW_STRATEGIES", "new_strategies"), + self.define("ZLIB_ENABLE_TESTS", self.pkg.run_tests), ] diff --git a/var/spack/repos/builtin/packages/zlib-ng/pr-1542.patch b/var/spack/repos/builtin/packages/zlib-ng/pr-1542.patch deleted file mode 100644 index 675c2c1a3d0ac5..00000000000000 --- a/var/spack/repos/builtin/packages/zlib-ng/pr-1542.patch +++ /dev/null @@ -1,224 +0,0 @@ -From 8c5d5eca51d9e4cd9aa046dba8f939b3f4012256 Mon Sep 17 00:00:00 2001 -From: Hans Kristian Rosbach -Date: Fri, 21 Jul 2023 13:43:15 +0200 -Subject: [PATCH 1/3] Clean up SSE4.2 support, and no longer use asm fallback - or gcc builtin. - -Defines changing meaning: -X86_SSE42 used to mean the compiler supports crc asm fallback. -X86_SSE42_CRC_INTRIN used to mean compiler supports SSE4.2 intrinsics. - -X86_SSE42 now means compiler supports SSE4.2 intrinsics. - -This therefore also fixes the adler32_sse42 checks, since those were depending -on SSE4.2 intrinsics but was mistakenly checking the X86_SSE42 define. -Now the X86_SSE42 define actually means what it appears to. ---- - CMakeLists.txt | 5 +---- - arch/x86/insert_string_sse42.c | 36 +++++---------------------------- - cmake/detect-intrinsics.cmake | 23 +++------------------ - configure | 37 ++++++++-------------------------- - win32/Makefile.msc | 1 - - 5 files changed, 17 insertions(+), 85 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 420a5c78..1e42239a 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -827,15 +827,12 @@ if(WITH_OPTIM) - endif() - if(WITH_SSE42) - check_sse42_intrinsics() -- if(HAVE_SSE42CRC_INLINE_ASM OR HAVE_SSE42CRC_INTRIN) -+ if(HAVE_SSE42_INTRIN) - add_definitions(-DX86_SSE42) - set(SSE42_SRCS ${ARCHDIR}/adler32_sse42.c ${ARCHDIR}/insert_string_sse42.c) - add_feature_info(SSE42_CRC 1 "Support SSE4.2 optimized CRC hash generation, using \"${SSE42FLAG}\"") - list(APPEND ZLIB_ARCH_SRCS ${SSE42_SRCS}) - set_property(SOURCE ${SSE42_SRCS} PROPERTY COMPILE_FLAGS "${SSE42FLAG} ${NOLTOFLAG}") -- if(HAVE_SSE42CRC_INTRIN) -- add_definitions(-DX86_SSE42_CRC_INTRIN) -- endif() - else() - set(WITH_SSE42 OFF) - endif() -diff --git a/arch/x86/insert_string_sse42.c b/arch/x86/insert_string_sse42.c -index 565d92f9..ae092a7e 100644 ---- a/arch/x86/insert_string_sse42.c -+++ b/arch/x86/insert_string_sse42.c -@@ -5,38 +5,13 @@ - * - */ - -+#ifdef X86_SSE42 - #include "../../zbuild.h" --#include --#ifdef _MSC_VER --# include --#endif -+#include - #include "../../deflate.h" - --#ifdef X86_SSE42_CRC_INTRIN --# ifdef _MSC_VER --# define HASH_CALC(s, h, val)\ -- h = _mm_crc32_u32(h, val) --# else --# define HASH_CALC(s, h, val)\ -- h = __builtin_ia32_crc32si(h, val) --# endif --#else --# ifdef _MSC_VER --# define HASH_CALC(s, h, val) {\ -- __asm mov edx, h\ -- __asm mov eax, val\ -- __asm crc32 eax, edx\ -- __asm mov h, eax\ -- } --# else --# define HASH_CALC(s, h, val) \ -- __asm__ __volatile__ (\ -- "crc32 %1,%0\n\t"\ -- : "+r" (h)\ -- : "r" (val)\ -- ); --# endif --#endif -+#define HASH_CALC(s, h, val)\ -+ h = _mm_crc32_u32(h, val) - - #define HASH_CALC_VAR h - #define HASH_CALC_VAR_INIT uint32_t h = 0 -@@ -45,6 +20,5 @@ - #define INSERT_STRING insert_string_sse42 - #define QUICK_INSERT_STRING quick_insert_string_sse42 - --#ifdef X86_SSE42 --# include "../../insert_string_tpl.h" -+#include "../../insert_string_tpl.h" - #endif -diff --git a/cmake/detect-intrinsics.cmake b/cmake/detect-intrinsics.cmake -index 9cbc5908..52c54dc8 100644 ---- a/cmake/detect-intrinsics.cmake -+++ b/cmake/detect-intrinsics.cmake -@@ -481,35 +481,18 @@ macro(check_sse42_intrinsics) - set(SSE42FLAG "-msse4.2") - endif() - endif() -- # Check whether compiler supports SSE4.2 CRC inline asm -+ # Check whether compiler supports SSE4.2 intrinsics - set(CMAKE_REQUIRED_FLAGS "${SSE42FLAG} ${NATIVEFLAG}") - check_c_source_compile_or_run( -- "int main(void) { -- unsigned val = 0, h = 0; -- #if defined(_MSC_VER) -- { __asm mov edx, h __asm mov eax, val __asm crc32 eax, edx __asm mov h, eax } -- #else -- __asm__ __volatile__ ( \"crc32 %1,%0\" : \"+r\" (h) : \"r\" (val) ); -- #endif -- return (int)h; -- }" -- HAVE_SSE42CRC_INLINE_ASM -- ) -- # Check whether compiler supports SSE4.2 CRC intrinsics -- check_c_source_compile_or_run( -- "#include -+ "#include - int main(void) { - unsigned crc = 0; - char c = 'c'; -- #if defined(_MSC_VER) - crc = _mm_crc32_u32(crc, c); -- #else -- crc = __builtin_ia32_crc32qi(crc, c); -- #endif - (void)crc; - return 0; - }" -- HAVE_SSE42CRC_INTRIN -+ HAVE_SSE42_INTRIN - ) - set(CMAKE_REQUIRED_FLAGS) - endmacro() -diff --git a/configure b/configure -index 8714590e..6b4e7fff 100755 ---- a/configure -+++ b/configure -@@ -1431,38 +1431,23 @@ EOF - } - - check_sse42_intrinsics() { -- # Check whether compiler supports SSE4.2 CRC inline asm -- cat > $test.c << EOF --int main(void) { -- unsigned val = 0, h = 0; -- __asm__ __volatile__ ( "crc32 %1,%0" : "+r" (h) : "r" (val) ); -- return (int) h; --} --EOF -- if try ${CC} ${CFLAGS} ${sse42flag} $test.c; then -- echo "Checking for SSE4.2 CRC inline assembly ... Yes." | tee -a configure.log -- HAVE_SSE42CRC_INLINE_ASM=1 -- else -- echo "Checking for SSE4.2 CRC inline assembly ... No." | tee -a configure.log -- HAVE_SSE42CRC_INLINE_ASM=0 -- fi -- -- # Check whether compiler supports SSE4.2 CRC intrinsics -+ # Check whether compiler supports SSE4.2 intrinsics - cat > $test.c << EOF -+#include - int main(void) { - unsigned crc = 0; - char c = 'c'; -- crc = __builtin_ia32_crc32qi(crc, c); -+ crc = _mm_crc32_u32(crc, c); - (void)crc; - return 0; - } - EOF - if try ${CC} ${CFLAGS} ${sse42flag} $test.c; then -- echo "Checking for SSE4.2 CRC intrinsics ... Yes." | tee -a configure.log -- HAVE_SSE42CRC_INTRIN=1 -+ echo "Checking for SSE4.2 intrinsics ... Yes." | tee -a configure.log -+ HAVE_SSE42_INTRIN=1 - else -- echo "Checking for SSE4.2 CRC intrinsics ... No." | tee -a configure.log -- HAVE_SSE42CRC_INTRIN=0 -+ echo "Checking for SSE4.2 intrinsics ... No." | tee -a configure.log -+ HAVE_SSE42_INTRIN=0 - fi - } - -@@ -1606,15 +1591,9 @@ case "${ARCH}" in - - check_sse42_intrinsics - -- if test ${HAVE_SSE42CRC_INTRIN} -eq 1 || test ${HAVE_SSE42CRC_INLINE_ASM} -eq 1; then -+ if test ${HAVE_SSE42_INTRIN} -eq 1; then - CFLAGS="${CFLAGS} -DX86_SSE42" - SFLAGS="${SFLAGS} -DX86_SSE42" -- -- if test ${HAVE_SSE42CRC_INTRIN} -eq 1; then -- CFLAGS="${CFLAGS} -DX86_SSE42_CRC_INTRIN" -- SFLAGS="${SFLAGS} -DX86_SSE42_CRC_INTRIN" -- fi -- - ARCH_STATIC_OBJS="${ARCH_STATIC_OBJS} adler32_sse42.o insert_string_sse42.o" - ARCH_SHARED_OBJS="${ARCH_SHARED_OBJS} adler32_sse42.lo insert_string_sse42.lo" - fi -diff --git a/win32/Makefile.msc b/win32/Makefile.msc -index 9ed26f28..3035072b 100644 ---- a/win32/Makefile.msc -+++ b/win32/Makefile.msc -@@ -31,7 +31,6 @@ WFLAGS = \ - -DX86_PCLMULQDQ_CRC \ - -DX86_SSE2 \ - -DX86_SSE42 \ -- -DX86_SSE42_CRC_INTRIN \ - -DX86_SSSE3 \ - -DX86_AVX2 - --- -2.39.2 - diff --git a/var/spack/repos/builtin/packages/zlib-ng/pr-1546.patch b/var/spack/repos/builtin/packages/zlib-ng/pr-1546.patch deleted file mode 100644 index 8966cdd36bf439..00000000000000 --- a/var/spack/repos/builtin/packages/zlib-ng/pr-1546.patch +++ /dev/null @@ -1,182 +0,0 @@ -From 101bc10dcef8d2cb45a51534180c7134001b07a9 Mon Sep 17 00:00:00 2001 -From: Harmen Stoppels -Date: Mon, 24 Jul 2023 09:37:57 +0200 -Subject: [PATCH 1/3] Relative paths CMAKE_INSTALL_*, absolute paths - CMAKE_INSTALL_FULL_*; use @rpath/libname as install name on macOS - ---- - CMakeLists.txt | 46 ++-------------------------------------------- - configure | 7 +------ - test/pkgcheck.sh | 2 +- - 3 files changed, 4 insertions(+), 51 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 003e66db7..46b85bc48 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -951,36 +951,8 @@ if(NOT CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_CURRENT_BINARY_DIR) - endif() - endif() - --# Refer to prefix symbolically to ease relocation by end user, --# as Makefile-generated .pc file does. --string(FIND "${CMAKE_INSTALL_INCLUDEDIR}" "${CMAKE_INSTALL_PREFIX}/" INCLUDEDIR_POS) --string(FIND "${CMAKE_INSTALL_LIBDIR}" "${CMAKE_INSTALL_PREFIX}/" LIBDIR_POS) --string(LENGTH "${CMAKE_INSTALL_PREFIX}/" INSTALL_PREFIX_LEN) -- --if(NOT IS_ABSOLUTE "${CMAKE_INSTALL_INCLUDEDIR}") -- set(PC_INC_INSTALL_DIR "\${prefix}/${CMAKE_INSTALL_INCLUDEDIR}") --elseif(INCLUDEDIR_POS EQUAL 0) -- string(SUBSTRING "${CMAKE_INSTALL_INCLUDEDIR}" "${INSTALL_PREFIX_LEN}" "-1" INCLUDEDIR_RELATIVE) -- set(PC_INC_INSTALL_DIR "\${prefix}/${INCLUDEDIR_RELATIVE}") --else() -- set(PC_INC_INSTALL_DIR "${CMAKE_INSTALL_INCLUDEDIR}") --endif() -- --if(APPLE) -- option(WITH_RPATH "Enable RPATH for shared library" OFF) --endif() --if(NOT IS_ABSOLUTE "${CMAKE_INSTALL_LIBDIR}") -- if(APPLE AND WITH_RPATH) -- set(PC_LIB_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}") -- else() -- set(PC_LIB_INSTALL_DIR "\${exec_prefix}/${CMAKE_INSTALL_LIBDIR}") -- endif() --elseif(LIBDIR_POS EQUAL 0) -- string(SUBSTRING "${CMAKE_INSTALL_LIBDIR}" "${INSTALL_PREFIX_LEN}" "-1" LIBDIR_RELATIVE) -- set(PC_LIB_INSTALL_DIR "\${exec_prefix}/${LIBDIR_RELATIVE}") --else() -- set(PC_LIB_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}") --endif() -+set(PC_INC_INSTALL_DIR "${CMAKE_INSTALL_FULL_INCLUDEDIR}") -+set(PC_LIB_INSTALL_DIR "${CMAKE_INSTALL_FULL_LIBDIR}") - - #============================================================================ - # zlib -@@ -1142,11 +1114,6 @@ if(NOT DEFINED BUILD_SHARED_LIBS OR BUILD_SHARED_LIBS) - if(NOT APPLE) - set_target_properties(zlib PROPERTIES LINK_FLAGS - "-Wl,--version-script,\"${CMAKE_CURRENT_SOURCE_DIR}/zlib${SUFFIX}.map\"") -- elseif(IS_ABSOLUTE "${CMAKE_INSTALL_LIBDIR}" OR NOT WITH_RPATH) -- # Match configure/make's behavior (i.e. don't use @rpath on mac when using absolute path). -- set_target_properties(zlib PROPERTIES INSTALL_NAME_DIR "@rpath/${CMAKE_INSTALL_FULL_LIBDIR}") -- else() -- set_target_properties(zlib PROPERTIES INSTALL_NAME_DIR "@rpath/${CMAKE_INSTALL_LIBDIR}") - endif() - endif() - if(MSYS) -@@ -1183,11 +1150,6 @@ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/zlib${SUFFIX}.h.in - configure_file(${CMAKE_CURRENT_SOURCE_DIR}/gzread.c.in - ${CMAKE_CURRENT_BINARY_DIR}/gzread.c @ONLY) - --# Fix install directory after generating zlib.pc/zlib-ng.pc --if (NOT IS_ABSOLUTE CMAKE_INSTALL_LIBDIR AND WITH_RPATH) -- set(CMAKE_INSTALL_LIBDIR "/${CMAKE_INSTALL_LIBDIR}") --endif() -- - if (NOT ZLIB_SYMBOL_PREFIX STREQUAL "") - add_feature_info(ZLIB_SYMBOL_PREFIX ON "Publicly exported symbols have a custom prefix") - configure_file(${CMAKE_CURRENT_SOURCE_DIR}/zlib_name_mangling${SUFFIX}.h.in -@@ -1286,8 +1248,4 @@ endif() - - add_feature_info(INSTALL_UTILS INSTALL_UTILS "Copy minigzip and minideflate during install") - --if(APPLE) -- add_feature_info(WITH_RPATH WITH_RPATH "Enable RPATH for shared library") --endif() -- - FEATURE_SUMMARY(WHAT ALL INCLUDE_QUIET_PACKAGES) -diff --git a/configure b/configure -index 29a64badf..6881f7af5 100755 ---- a/configure -+++ b/configure -@@ -513,12 +513,7 @@ if test "$gcc" -eq 1 && ($cc $CFLAGS -c $test.c) >> configure.log 2>&1; then - SHAREDLIBM=${LIBNAME}.$VER1$shared_ext - SHAREDTARGET=$SHAREDLIBV - LDSHARED=${LDSHARED-"$cc"} -- case ${libdir} in -- /*) -- LDSHAREDFLAGS="-dynamiclib -install_name ${libdir}/${SHAREDLIBM} -compatibility_version ${VER1} -current_version ${VER3}" ;; -- *) -- LDSHAREDFLAGS="-dynamiclib -install_name @rpath/${libdir}/${SHAREDLIBM} -compatibility_version ${VER1} -current_version ${VER3}" ;; -- esac -+ LDSHAREDFLAGS="-dynamiclib -install_name @rpath/${SHAREDLIBM} -compatibility_version ${VER1} -current_version ${VER3}" - if libtool -V 2>&1 | grep Apple > /dev/null; then - AR="libtool" - else -diff --git a/test/pkgcheck.sh b/test/pkgcheck.sh -index 629f98ade..6641b300a 100644 ---- a/test/pkgcheck.sh -+++ b/test/pkgcheck.sh -@@ -81,7 +81,7 @@ Darwin) - sysctl -n machdep.cpu.features - sysctl -n machdep.cpu.leaf7_features - sysctl -n machdep.cpu.extfeatures -- CMAKE_ARGS="-DCMAKE_INSTALL_LIBDIR=lib -DPKGCONFIG_INSTALL_DIR=/lib/pkgconfig -DWITH_RPATH=on ${CMAKE_ARGS}" -+ CMAKE_ARGS="-DCMAKE_INSTALL_LIBDIR=lib ${CMAKE_ARGS}" - CONFIGURE_ARGS="--libdir=lib ${CONFIGURE_ARGS}" - ;; - *) - -From c6fbd1459eda454402c3450c670b7e538233b8d4 Mon Sep 17 00:00:00 2001 -From: Harmen Stoppels -Date: Mon, 24 Jul 2023 11:37:31 +0200 -Subject: [PATCH 2/3] relocatable pc files by default, while allowing - discouraged absolute paths for CMAKE_INSTALL_[LIB|INCLUDE]DIR - ---- - CMakeLists.txt | 15 +++++++++++++-- - 1 file changed, 13 insertions(+), 2 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 46b85bc48..1894d10d5 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -951,8 +951,19 @@ if(NOT CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_CURRENT_BINARY_DIR) - endif() - endif() - --set(PC_INC_INSTALL_DIR "${CMAKE_INSTALL_FULL_INCLUDEDIR}") --set(PC_LIB_INSTALL_DIR "${CMAKE_INSTALL_FULL_LIBDIR}") -+# The user is allowed (but discouraged) to set absolute CMAKE_INSTALL_*DIR paths. -+# If they do, we copy these non-relocatable paths into the pkg-config file. -+if(IS_ABSOLUTE "${CMAKE_INSTALL_INCLUDEDIR}") -+ set(PC_INC_INSTALL_DIR "${CMAKE_INSTALL_INCLUDEDIR}") -+else() -+ set(PC_INC_INSTALL_DIR "\${prefix}/${CMAKE_INSTALL_INCLUDEDIR}") -+endif() -+ -+if(IS_ABSOLUTE "${CMAKE_INSTALL_LIBDIR}") -+ set(PC_LIB_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}") -+else() -+ set(PC_LIB_INSTALL_DIR "\${exec_prefix}/${CMAKE_INSTALL_LIBDIR}") -+endif() - - #============================================================================ - # zlib - -From 0bae8f7d8379e5863b7c9328f0d71a87a33ca02f Mon Sep 17 00:00:00 2001 -From: Harmen Stoppels -Date: Mon, 24 Jul 2023 10:20:32 +0200 -Subject: [PATCH 3/3] Remove relative configure --lib - ---- - test/pkgcheck.sh | 5 ----- - 1 file changed, 5 deletions(-) - -diff --git a/test/pkgcheck.sh b/test/pkgcheck.sh -index 6641b300a..94a67a191 100644 ---- a/test/pkgcheck.sh -+++ b/test/pkgcheck.sh -@@ -81,11 +81,6 @@ Darwin) - sysctl -n machdep.cpu.features - sysctl -n machdep.cpu.leaf7_features - sysctl -n machdep.cpu.extfeatures -- CMAKE_ARGS="-DCMAKE_INSTALL_LIBDIR=lib ${CMAKE_ARGS}" -- CONFIGURE_ARGS="--libdir=lib ${CONFIGURE_ARGS}" -- ;; --*) -- CMAKE_ARGS="-DCMAKE_INSTALL_LIBDIR=lib ${CMAKE_ARGS}" - ;; - esac - diff --git a/var/spack/repos/builtin/packages/zlib-ng/pr-1561.patch b/var/spack/repos/builtin/packages/zlib-ng/pr-1561.patch deleted file mode 100644 index f87aea684bd916..00000000000000 --- a/var/spack/repos/builtin/packages/zlib-ng/pr-1561.patch +++ /dev/null @@ -1,210 +0,0 @@ -From f6fb1d350a7b8210cc9c45ed502b3cc34e4dac32 Mon Sep 17 00:00:00 2001 -From: Harmen Stoppels -Date: Mon, 21 Aug 2023 10:13:10 +0200 -Subject: [PATCH 2/3] PR #1561 - ---- - configure | 50 +++++++++++++++++++++++++------------------------- - 1 file changed, 25 insertions(+), 25 deletions(-) - -diff --git a/configure b/configure -index 6b4e7fff..fc78a135 100755 ---- a/configure -+++ b/configure -@@ -1,4 +1,4 @@ --#!/usr/bin/env bash -+#!/bin/sh - # configure script for zlib. - # - # Normally configure builds both a static and a shared library. -@@ -230,13 +230,13 @@ test=ztest$$ - # put arguments in log, also put test file in log if used in arguments - show() - { -- case "$*" in -+ case "$@" in - *$test.c*) - echo "=== $test.c ===" >> configure.log - cat $test.c >> configure.log - echo "===" >> configure.log;; - esac -- echo $* >> configure.log -+ echo "$@" >> configure.log - } - - # check for gcc vs. cc and set compile and link flags based on the system identified by uname -@@ -246,7 +246,7 @@ int main() {return getchar();} - EOF - - cc=${CC-${CROSS_PREFIX}gcc} --echo -n "Checking for compiler... " | tee -a configure.log -+printf "Checking for compiler... " | tee -a configure.log - case "$cc" in - *gcc*) gcc=1 ;; - *clang*) gcc=1 ;; -@@ -401,7 +401,7 @@ if test "$gcc" -eq 1 && ($cc $CFLAGS -c $test.c) >> configure.log 2>&1; then - SFLAGS="${SFLAGS} -DNDEBUG" - fi - if test -z "$uname"; then -- uname=$((uname -s || echo unknown) 2>/dev/null) -+ uname=$( (uname -s || echo unknown) 2>/dev/null) - fi - case "$uname" in - Linux* | linux* | GNU | GNU/* | solaris*) -@@ -483,7 +483,7 @@ if test "$gcc" -eq 1 && ($cc $CFLAGS -c $test.c) >> configure.log 2>&1; then - fi - RC="${CROSS_PREFIX}windres" - RCFLAGS="-I ${BUILDDIR}" -- if [ "$CC" == "mingw32-gcc" ]; then -+ if [ "$CC" = "mingw32-gcc" ]; then - case $ARCH in - i386 | i486 | i586 | i686) RCFLAGS="${RCFLAGS} -F pe-i386";; - esac; -@@ -498,7 +498,7 @@ if test "$gcc" -eq 1 && ($cc $CFLAGS -c $test.c) >> configure.log 2>&1; then - HP-UX*) - LDSHARED=${LDSHARED-"$cc"} - LDSHAREDFLAGS="-shared" -- case $((uname -m || echo unknown) 2>/dev/null) in -+ case $( (uname -m || echo unknown) 2>/dev/null) in - ia64) - shared_ext='.so' - SHAREDLIB='${LIBNAME}.so' ;; -@@ -539,14 +539,14 @@ else - gcc=0 - echo "$CC" | tee -a configure.log - if test -z "$uname"; then -- uname=$((uname -sr || echo unknown) 2>/dev/null) -+ uname=$( (uname -sr || echo unknown) 2>/dev/null) - fi - case "$uname" in - HP-UX*) SFLAGS=${CFLAGS-"-O +z"} - CFLAGS=${CFLAGS-"-O"} - LDSHARED=${LDSHARED-"ld"} - LDSHAREDFLAGS="-b" -- case $((uname -m || echo unknown) 2>/dev/null) in -+ case $( (uname -m || echo unknown) 2>/dev/null) in - ia64) - shared_ext='.so' - SHAREDLIB='${LIBNAME}.so' ;; -@@ -591,15 +591,15 @@ EOF - if ($CC -c $CFLAGS $test.c) 2>/dev/null; then - try() - { -- show $* -- test "$(\( $* \) 2>&1 | tee -a configure.log)" = "" -+ show "$@" -+ test "$( ("$@") 2>&1 | tee -a configure.log)" = "" - } - echo - using any output from compiler to indicate an error >> configure.log - else - try() - { -- show $* -- ( $* ) >> configure.log 2>&1 -+ show "$@" -+ ( "$@" ) >> configure.log 2>&1 - ret=$? - if test $ret -ne 0; then - echo "(exit code $ret)" >> configure.log -@@ -627,7 +627,7 @@ extern int getchar(); - int hello() {return getchar();} - EOF - if test $shared -eq 1; then -- echo -n "Checking for shared library support... " | tee -a configure.log -+ printf "Checking for shared library support... " | tee -a configure.log - # we must test in two steps (cc then ld), required at least on SunOS 4.x - if try $CC -w -c $SFLAGS $test.c && - try $LDSHARED $LDSHAREDFLAGS $LDFLAGS -o $test$shared_ext $test.o $LDSHAREDLIBC; then -@@ -784,7 +784,7 @@ fi - # Rename @ZLIB_SYMBOL_PREFIX@ to $symbol_prefix in gzread.c, zlib.h and zlib_name_mangling.h - sed < $SRCDIR/gzread.c.in "s/@ZLIB_SYMBOL_PREFIX@/$symbol_prefix/g" > gzread.c - sed < $SRCDIR/zlib${SUFFIX}.h.in "s/@ZLIB_SYMBOL_PREFIX@/$symbol_prefix/g" > zlib${SUFFIX}.h --if [[ ! -z $symbol_prefix ]]; then -+if [ ! -z "$symbol_prefix" ]; then - sed < $SRCDIR/zlib_name_mangling${SUFFIX}.h.in "s/@ZLIB_SYMBOL_PREFIX@/$symbol_prefix/g" > zlib_name_mangling${SUFFIX}.h - else - # symbol_prefix is not set, copy the empty mangling header -@@ -814,7 +814,7 @@ fi - echo >> configure.log - - # check for ptrdiff_t and save result in zconf.h --echo -n "Checking for ptrdiff_t... " | tee -a configure.log -+printf "Checking for ptrdiff_t... " | tee -a configure.log - cat > $test.c < - int fun(ptrdiff_t *a) { (void)a; return 0; } -@@ -826,7 +826,7 @@ else - sed < zconf${SUFFIX}.h "/^#ifdef NEED_PTRDIFF_T.* may be/s/def NEED_PTRDIFF_T\(.*\) may be/ 1\1 was/" > zconf${SUFFIX}.temp.h - mv zconf${SUFFIX}.temp.h zconf${SUFFIX}.h - -- echo -n "Checking for sizeof(void *)... " | tee -a configure.log -+ printf "Checking for sizeof(void *)... " | tee -a configure.log - cat > $test.c < - #define COMPILE_TIME_ASSERT(pred) struct s { int x: (pred) ? 1 : -1; } -@@ -864,7 +864,7 @@ if test $compat -eq 1; then - esac - fi - --if [[ ! -z $DEFFILE ]]; then -+if [ ! -z "$DEFFILE" ]; then - mkdir -p win32 - sed < $SRCDIR/$DEFFILE.in "s/@ZLIB_SYMBOL_PREFIX@/$symbol_prefix/g" > $DEFFILE - fi -@@ -1476,14 +1476,14 @@ EOF - - check_vgfma_intrinsics() { - # Check whether "VECTOR GALOIS FIELD MULTIPLY SUM AND ACCUMULATE" intrinsic is available -- echo -n "Checking for -mzarch... " | tee -a configure.log -+ printf "Checking for -mzarch... " | tee -a configure.log - if try $CC -x c -c /dev/null -o /dev/null -mzarch; then - echo Yes. | tee -a configure.log - vgfmaflag="${vgfmaflag} -mzarch" - else - echo No. | tee -a configure.log - fi -- echo -n "Checking for -fzvector... " | tee -a configure.log -+ printf "Checking for -fzvector... " | tee -a configure.log - if try $CC -x c -c /dev/null -o /dev/null -fzvector; then - echo Yes. | tee -a configure.log - vgfmaflag="${vgfmaflag} -fzvector" -@@ -1500,7 +1500,7 @@ int main(void) { - return c[0]; - } - EOF -- echo -n "Checking for VGFMA support... " | tee -a configure.log -+ printf "Checking for VGFMA support... " | tee -a configure.log - if try $CC -c $CFLAGS $vgfmaflag $test.c; then - HAVE_VGFMA_INTRIN=1 - echo "Yes." | tee -a configure.log -@@ -2156,11 +2156,11 @@ for file in $SRCDIR/*.c $SRCDIR/test/*.c $SRCDIR/test/fuzz/*.c $SRCDIR/$ARCHDIR/ - # Check that the include file exists in the current dir, - # otherwise it may be one of the system include header. - if test -e $SRCDIR/$i; then -- echo -n " \$(SRCDIR)/$i" -+ printf " \$(SRCDIR)/$i" - fi - # We also need to check whether the include file is in the ARCHDIR. - if test -e $SRCDIR/$ARCHDIR/$i; then -- echo -n " \$(SRCDIR)/$ARCHDIR/$i" -+ printf " \$(SRCDIR)/$ARCHDIR/$i" - fi - done) - obj=$(basename $(echo $file | sed -e 's/\.c/\.o/g' -e 's#^\./##g')) -@@ -2233,11 +2233,11 @@ for file in $SRCDIR/$ARCHDIR/*.c; do - # Check that the include file exists in the current dir, - # otherwise it may be one of the system include header. - if test -e $SRCDIR/$i; then -- echo -n " \$(SRCTOP)/$i" -+ printf " \$(SRCTOP)/$i" - fi - # We also need to check whether the include file is in the ARCHDIR. - if test -e $SRCDIR/$ARCHDIR/$i; then -- echo -n " \$(SRCDIR)/$i" -+ printf " \$(SRCDIR)/$i" - fi - done) - obj=$(basename $(echo $file | sed -e 's/\.c/\.o/g' -e 's#^\./##g')) --- -2.39.2 - diff --git a/var/spack/repos/builtin/packages/zlib-ng/pr-1562.patch b/var/spack/repos/builtin/packages/zlib-ng/pr-1562.patch deleted file mode 100644 index 70806e900c36c5..00000000000000 --- a/var/spack/repos/builtin/packages/zlib-ng/pr-1562.patch +++ /dev/null @@ -1,432 +0,0 @@ -From 13df84c54aaf06cc7aeb1813ef60b17591d29ea3 Mon Sep 17 00:00:00 2001 -From: Harmen Stoppels -Date: Mon, 21 Aug 2023 11:10:29 +0200 -Subject: [PATCH 3/3] PR #1562 - ---- - cmake/detect-intrinsics.cmake | 118 ++++++++++++---------------------- - configure | 115 ++++++++++----------------------- - 2 files changed, 73 insertions(+), 160 deletions(-) - -diff --git a/cmake/detect-intrinsics.cmake b/cmake/detect-intrinsics.cmake -index 52c54dc8..d476093f 100644 ---- a/cmake/detect-intrinsics.cmake -+++ b/cmake/detect-intrinsics.cmake -@@ -62,28 +62,19 @@ macro(check_avx512_intrinsics) - set(CMAKE_REQUIRED_FLAGS "${AVX512FLAG} ${NATIVEFLAG}") - check_c_source_compile_or_run( - "#include -- int main(void) { -- __m512i x = _mm512_set1_epi8(2); -- const __m512i y = _mm512_set_epi32(0x1020304, 0x5060708, 0x90a0b0c, 0xd0e0f10, -- 0x11121314, 0x15161718, 0x191a1b1c, 0x1d1e1f20, -- 0x21222324, 0x25262728, 0x292a2b2c, 0x2d2e2f30, -- 0x31323334, 0x35363738, 0x393a3b3c, 0x3d3e3f40); -- x = _mm512_sub_epi8(x, y); -- (void)x; -- return 0; -- }" -+ __m512i f(__m512i y) { -+ __m512i x = _mm512_set1_epi8(2); -+ return _mm512_sub_epi8(x, y); -+ } -+ int main(void) { return 0; }" - HAVE_AVX512_INTRIN - ) - - # Evidently both GCC and clang were late to implementing these - check_c_source_compile_or_run( - "#include -- int main(void) { -- __mmask16 a = 0xFF; -- a = _knot_mask16(a); -- (void)a; -- return 0; -- }" -+ __mmask16 f(__mmask16 x) { return _knot_mask16(x); } -+ int main(void) { return 0; }" - HAVE_MASK_INTRIN - ) - set(CMAKE_REQUIRED_FLAGS) -@@ -117,17 +108,11 @@ macro(check_avx512vnni_intrinsics) - set(CMAKE_REQUIRED_FLAGS "${AVX512VNNIFLAG} ${NATIVEFLAG}") - check_c_source_compile_or_run( - "#include -- int main(void) { -- __m512i x = _mm512_set1_epi8(2); -- const __m512i y = _mm512_set_epi8(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, -- 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, -- 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, -- 56, 57, 58, 59, 60, 61, 62, 63, 64); -+ __m512i f(__m512i x, __m512i y) { - __m512i z = _mm512_setzero_epi32(); -- z = _mm512_dpbusd_epi32(z, x, y); -- (void)z; -- return 0; -- }" -+ return _mm512_dpbusd_epi32(z, x, y); -+ } -+ int main(void) { return 0; }" - HAVE_AVX512VNNI_INTRIN - ) - set(CMAKE_REQUIRED_FLAGS) -@@ -151,13 +136,11 @@ macro(check_avx2_intrinsics) - set(CMAKE_REQUIRED_FLAGS "${AVX2FLAG} ${NATIVEFLAG}") - check_c_source_compile_or_run( - "#include -- int main(void) { -- __m256i x = _mm256_set1_epi16(2); -+ __m256i f(__m256i x) { - const __m256i y = _mm256_set1_epi16(1); -- x = _mm256_subs_epu16(x, y); -- (void)x; -- return 0; -- }" -+ return _mm256_subs_epu16(x, y); -+ } -+ int main(void) { return 0; }" - HAVE_AVX2_INTRIN - ) - set(CMAKE_REQUIRED_FLAGS) -@@ -204,12 +187,8 @@ macro(check_neon_ld4_intrinsics) - #else - # include - #endif -- int main(void) { -- int stack_var[16]; -- int32x4x4_t v = vld1q_s32_x4(stack_var); -- (void)v; -- return 0; -- }" -+ int32x4x4_t f(int var[16]) { return vld1q_s32_x4(var); } -+ int main(void) { return 0; }" - NEON_HAS_LD4) - set(CMAKE_REQUIRED_FLAGS) - endmacro() -@@ -226,13 +205,9 @@ macro(check_pclmulqdq_intrinsics) - set(CMAKE_REQUIRED_FLAGS "${PCLMULFLAG} ${NATIVEFLAG}") - check_c_source_compile_or_run( - "#include -- int main(void) { -- __m128i a = _mm_setzero_si128(); -- __m128i b = _mm_setzero_si128(); -- __m128i c = _mm_clmulepi64_si128(a, b, 0x10); -- (void)c; -- return 0; -- }" -+ #include -+ __m128i f(__m128i a, __m128i b) { return _mm_clmulepi64_si128(a, b, 0x10); } -+ int main(void) { return 0; }" - HAVE_PCLMULQDQ_INTRIN - ) - set(CMAKE_REQUIRED_FLAGS) -@@ -252,13 +227,12 @@ macro(check_vpclmulqdq_intrinsics) - set(CMAKE_REQUIRED_FLAGS "${VPCLMULFLAG} ${NATIVEFLAG}") - check_c_source_compile_or_run( - "#include -- int main(void) { -- __m512i a = _mm512_setzero_si512(); -+ #include -+ __m512i f(__m512i a) { - __m512i b = _mm512_setzero_si512(); -- __m512i c = _mm512_clmulepi64_epi128(a, b, 0x10); -- (void)c; -- return 0; -- }" -+ return _mm512_clmulepi64_epi128(a, b, 0x10); -+ } -+ int main(void) { return 0; }" - HAVE_VPCLMULQDQ_INTRIN - ) - set(CMAKE_REQUIRED_FLAGS) -@@ -431,11 +405,8 @@ macro(check_sse2_intrinsics) - set(CMAKE_REQUIRED_FLAGS "${SSE2FLAG} ${NATIVEFLAG}") - check_c_source_compile_or_run( - "#include -- int main(void) { -- __m128i zero = _mm_setzero_si128(); -- (void)zero; -- return 0; -- }" -+ __m128i f(__m128i x, __m128i y) { return _mm_sad_epu8(x, y); } -+ int main(void) { return 0; }" - HAVE_SSE2_INTRIN - ) - set(CMAKE_REQUIRED_FLAGS) -@@ -457,14 +428,11 @@ macro(check_ssse3_intrinsics) - set(CMAKE_REQUIRED_FLAGS "${SSSE3FLAG} ${NATIVEFLAG}") - check_c_source_compile_or_run( - "#include -- int main(void) { -- __m128i u, v, w; -- u = _mm_set1_epi32(1); -- v = _mm_set1_epi32(2); -- w = _mm_hadd_epi32(u, v); -- (void)w; -- return 0; -- }" -+ __m128i f(__m128i u) { -+ __m128i v = _mm_set1_epi32(1); -+ return _mm_hadd_epi32(u, v); -+ } -+ int main(void) { return 0; }" - HAVE_SSSE3_INTRIN - ) - endmacro() -@@ -485,13 +453,8 @@ macro(check_sse42_intrinsics) - set(CMAKE_REQUIRED_FLAGS "${SSE42FLAG} ${NATIVEFLAG}") - check_c_source_compile_or_run( - "#include -- int main(void) { -- unsigned crc = 0; -- char c = 'c'; -- crc = _mm_crc32_u32(crc, c); -- (void)crc; -- return 0; -- }" -+ unsigned int f(unsigned int a, unsigned int b) { return _mm_crc32_u32(a, b); } -+ int main(void) { return 0; }" - HAVE_SSE42_INTRIN - ) - set(CMAKE_REQUIRED_FLAGS) -@@ -529,13 +492,12 @@ macro(check_xsave_intrinsics) - set(CMAKE_REQUIRED_FLAGS "${XSAVEFLAG} ${NATIVEFLAG}") - check_c_source_compiles( - "#ifdef _WIN32 -- # include -- #else -- # include -- #endif -- int main(void) { -- return _xgetbv(0); -- }" -+ # include -+ #else -+ # include -+ #endif -+ unsigned int f(unsigned int a) { return _xgetbv(a); } -+ int main(void) { return 0; }" - HAVE_XSAVE_INTRIN FAIL_REGEX "not supported") - set(CMAKE_REQUIRED_FLAGS) - endmacro() -diff --git a/configure b/configure -index fc78a135..e5a1965f 100755 ---- a/configure -+++ b/configure -@@ -1023,12 +1023,8 @@ fi - - # Check for __builtin_ctz() support in compiler - cat > $test.c << EOF --int main(void) { -- unsigned int zero = 0; -- long test = __builtin_ctz(zero); -- (void)test; -- return 0; --} -+long f(unsigned int x) { return __builtin_ctz(x); } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} $test.c $LDSHAREDLIBC; then - echo "Checking for __builtin_ctz ... Yes." | tee -a configure.log -@@ -1040,12 +1036,8 @@ fi - - # Check for __builtin_ctzll() support in compiler - cat > $test.c << EOF --int main(void) { -- unsigned long long zero = 0; -- long test = __builtin_ctzll(zero); -- (void)test; -- return 0; --} -+long f(unsigned long long x) { return __builtin_ctzll(x); } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} $test.c $LDSHAREDLIBC; then - echo "Checking for __builtin_ctzll ... Yes." | tee -a configure.log -@@ -1059,13 +1051,11 @@ check_avx2_intrinsics() { - # Check whether compiler supports AVX2 intrinsics - cat > $test.c << EOF - #include --int main(void) { -- __m256i x = _mm256_set1_epi16(2); -+__m256i f(__m256i x) { - const __m256i y = _mm256_set1_epi16(1); -- x = _mm256_subs_epu16(x, y); -- (void)x; -- return 0; -+ return _mm256_subs_epu16(x, y); - } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} ${avx2flag} $test.c; then - echo "Checking for AVX2 intrinsics ... Yes." | tee -a configure.log -@@ -1080,16 +1070,11 @@ check_avx512_intrinsics() { - # Check whether compiler supports AVX512 intrinsics - cat > $test.c << EOF - #include --int main(void) { -- __m512i x = _mm512_set1_epi8(2); -- const __m512i y = _mm512_set_epi32(0x1020304, 0x5060708, 0x90a0b0c, 0xd0e0f10, -- 0x11121314, 0x15161718, 0x191a1b1c, 0x1d1e1f20, -- 0x21222324, 0x25262728, 0x292a2b2c, 0x2d2e2f30, -- 0x31323334, 0x35363738, 0x393a3b3c, 0x3d3e3f40); -- x = _mm512_sub_epi8(x, y); -- (void)x; -- return 0; -+__m512i f(__m512i y) { -+ __m512i x = _mm512_set1_epi8(2); -+ return _mm512_sub_epi8(x, y); - } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} ${avx512flag} $test.c; then - echo "Checking for AVX512 intrinsics ... Yes." | tee -a configure.log -@@ -1133,17 +1118,11 @@ check_avx512vnni_intrinsics() { - # Check whether compiler supports AVX512-VNNI intrinsics - cat > $test.c << EOF - #include --int main(void) { -- __m512i x = _mm512_set1_epi8(2); -- const __m512i y = _mm512_set_epi8(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, -- 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, -- 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, -- 56, 57, 58, 59, 60, 61, 62, 63, 64); -+__m512i f(__m512i x, __m512i y) { - __m512i z = _mm512_setzero_epi32(); -- z = _mm512_dpbusd_epi32(z, x, y); -- (void)z; -- return 0; -+ return _mm512_dpbusd_epi32(z, x, y); - } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} ${avx512vnniflag} $test.c; then - echo "Checking for AVX512VNNI intrinsics ... Yes." | tee -a configure.log -@@ -1158,12 +1137,8 @@ check_mask_intrinsics() { - # Check whether compiler supports AVX512 k-mask intrinsics - cat > $test.c << EOF - #include --int main(void) { -- __mmask16 a = 0xFF; -- a = _knot_mask16(a); -- (void)a; -- return 0; --} -+__mmask16 f(__mmask16 x) { return _knot_mask16(x); } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} ${avx512flag} $test.c; then - echo "Checking for AVX512 k-mask intrinsics ... Yes." | tee -a configure.log -@@ -1230,12 +1205,8 @@ check_neon_ld4_intrinsics() { - #else - # include - #endif --int main(void) { -- int stack_var[16]; -- int32x4x4_t v = vld1q_s32_x4(stack_var); -- (void)v; -- return 0; --} -+int32x4x4_t f(int var[16]) { return vld1q_s32_x4(var); } -+int main(void) { return 0; } - EOF - if try $CC -c $CFLAGS $neonflag $test.c; then - NEON_HAS_LD4=1 -@@ -1251,13 +1222,8 @@ check_pclmulqdq_intrinsics() { - cat > $test.c << EOF - #include - #include --int main(void) { -- __m128i a = _mm_setzero_si128(); -- __m128i b = _mm_setzero_si128(); -- __m128i c = _mm_clmulepi64_si128(a, b, 0x10); -- (void)c; -- return 0; --} -+__m128i f(__m128i a, __m128i b) { return _mm_clmulepi64_si128(a, b, 0x10); } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} ${pclmulflag} $test.c; then - echo "Checking for PCLMULQDQ intrinsics ... Yes." | tee -a configure.log -@@ -1273,13 +1239,11 @@ check_vpclmulqdq_intrinsics() { - cat > $test.c << EOF - #include - #include --int main(void) { -- __m512i a = _mm512_setzero_si512(); -+__m512i f(__m512i a) { - __m512i b = _mm512_setzero_si512(); -- __m512i c = _mm512_clmulepi64_epi128(a, b, 0x10); -- (void)c; -- return 0; -+ return _mm512_clmulepi64_epi128(a, b, 0x10); - } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} ${vpclmulflag} $test.c; then - echo "Checking for VPCLMULQDQ intrinsics ... Yes." | tee -a configure.log -@@ -1298,9 +1262,8 @@ check_xsave_intrinsics() { - #else - # include - #endif --int main(void) { -- return _xgetbv(0); --} -+unsigned int f(unsigned int a) { return _xgetbv(a); } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} ${xsaveflag} $test.c; then - echo "Checking for XSAVE intrinsics ... Yes." | tee -a configure.log -@@ -1415,11 +1378,8 @@ check_sse2_intrinsics() { - # Check whether compiler supports SSE2 intrinsics - cat > $test.c << EOF - #include --int main(void) { -- __m128i zero = _mm_setzero_si128(); -- (void)zero; -- return 0; --} -+__m128i f(__m128i x, __m128i y) { return _mm_sad_epu8(x, y); } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} ${sse2flag} $test.c; then - echo "Checking for SSE2 intrinsics ... Yes." | tee -a configure.log -@@ -1434,13 +1394,8 @@ check_sse42_intrinsics() { - # Check whether compiler supports SSE4.2 intrinsics - cat > $test.c << EOF - #include --int main(void) { -- unsigned crc = 0; -- char c = 'c'; -- crc = _mm_crc32_u32(crc, c); -- (void)crc; -- return 0; --} -+unsigned int f(unsigned int a, unsigned int b) { return _mm_crc32_u32(a, b); } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} ${sse42flag} $test.c; then - echo "Checking for SSE4.2 intrinsics ... Yes." | tee -a configure.log -@@ -1455,15 +1410,11 @@ check_ssse3_intrinsics() { - # Check whether compiler supports SSSE3 intrinsics - cat > $test.c << EOF - #include --int main(void) --{ -- __m128i u, v, w; -- u = _mm_set1_epi32(1); -- v = _mm_set1_epi32(2); -- w = _mm_hadd_epi32(u, v); -- (void)w; -- return 0; -+__m128i f(__m128i u) { -+ __m128i v = _mm_set1_epi32(1); -+ return _mm_hadd_epi32(u, v); - } -+int main(void) { return 0; } - EOF - if try ${CC} ${CFLAGS} ${ssse3flag} $test.c; then - echo "Checking for SSSE3 intrinsics ... Yes." | tee -a configure.log --- -2.39.2 - diff --git a/var/spack/repos/builtin/packages/zlib-ng/pr-1698.patch b/var/spack/repos/builtin/packages/zlib-ng/pr-1698.patch new file mode 100644 index 00000000000000..7bea02d0ca8a9e --- /dev/null +++ b/var/spack/repos/builtin/packages/zlib-ng/pr-1698.patch @@ -0,0 +1,31 @@ +From fb504432aae51c45397f3e563c659c11d68a10e2 Mon Sep 17 00:00:00 2001 +From: Sergey Kosukhin +Date: Tue, 12 Mar 2024 15:46:52 +0100 +Subject: [PATCH] Fix building with NVHPC + +--- + arch/x86/x86_intrins.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/arch/x86/x86_intrins.h b/arch/x86/x86_intrins.h +index 52e1085d66..0e596d18a1 100644 +--- a/arch/x86/x86_intrins.h ++++ b/arch/x86/x86_intrins.h +@@ -7,7 +7,7 @@ + #ifdef __AVX2__ + #include + +-#if (!defined(__clang__) && defined(__GNUC__) && __GNUC__ < 10) \ ++#if (!defined(__clang__) && !defined(__NVCOMPILER) && defined(__GNUC__) && __GNUC__ < 10) \ + || (defined(__apple_build_version__) && __apple_build_version__ < 9020039) + static inline __m256i _mm256_zextsi128_si256(__m128i a) { + __m128i r; +@@ -29,7 +29,7 @@ static inline __m512i _mm512_zextsi128_si512(__m128i a) { + /* GCC <9 is missing some AVX512 intrinsics. + */ + #ifdef __AVX512F__ +-#if (!defined(__clang__) && defined(__GNUC__) && __GNUC__ < 9) ++#if (!defined(__clang__) && !defined(__NVCOMPILER) && defined(__GNUC__) && __GNUC__ < 9) + #include + + #define PACK(c0, c1, c2, c3) (((int)(unsigned char)(c0) << 24) | ((int)(unsigned char)(c1) << 16) | \ diff --git a/var/spack/repos/builtin/packages/zlib/package.py b/var/spack/repos/builtin/packages/zlib/package.py index d17db27bef5216..32a40fb31dfd68 100644 --- a/var/spack/repos/builtin/packages/zlib/package.py +++ b/var/spack/repos/builtin/packages/zlib/package.py @@ -8,6 +8,7 @@ # The AutotoolsPackage causes zlib to fail to build with PGI import glob import os +import re import spack.build_systems.generic import spack.build_systems.makefile @@ -24,6 +25,10 @@ class Zlib(MakefilePackage, Package): url = "http://zlib.net/fossils/zlib-1.2.11.tar.gz" git = "https://github.com/madler/zlib.git" + tags = ["core-packages"] + libraries = ["libz", "zlib", "zlibstatic", "zlibd", "zlibstaticd"] + + version("1.3.1", sha256="9a93b2b7dfdac77ceba5a558a580e74667dd6fede4585b91eefb60f03b72df23") version("1.3", sha256="ff0ba4c292013dbc27530b3a81e1f9a813cd39de01ca5e0f8bf355702efa593e") version("1.2.13", sha256="b3a24de97a8fdbc835b9833169501030b8977031bcb54b3b3ac13740f846ab30") version( @@ -47,6 +52,9 @@ class Zlib(MakefilePackage, Package): deprecated=True, ) + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + build_system("makefile", conditional("generic", when="platform=windows"), default="makefile") variant("pic", default=True, description="Produce position-independent code (for shared libs)") @@ -62,6 +70,18 @@ class Zlib(MakefilePackage, Package): license("Zlib") + @classmethod + def determine_version(cls, lib): + for library in cls.libraries: + for ext in library_extensions: + if ext == "dylib": + pattern = re.compile(rf"{library}\.(\d+\.\d+\.\d+)\.{ext}") + else: + pattern = re.compile(rf"{library}\.{ext}\.(\d+\.\d+\.\d+)") + match = re.search(pattern, lib) + if match: + return match.group(1) + @property def libs(self): shared = "+shared" in self.spec @@ -105,9 +125,8 @@ def edit(self, pkg, spec, prefix): r"\1 {0}".format(self.pkg.compiler.cc_pic_flag), "Makefile", ) - if any(self.spec.satisfies("platform={0}".format(p)) for p in ["linux", "cray"]): + if self.spec.satisfies("platform=linux"): # Without the following, the shared library will not have a soname entry. - # Currently, we support linux and cray platforms only. filter_file( r"^(LDSHARED *= *).*$", # Note that we should use '-Wl,` and not self.pkg.compiler.linker_arg diff --git a/var/spack/repos/builtin/packages/zoltan/package.py b/var/spack/repos/builtin/packages/zoltan/package.py index 63427a6a9000c5..86121f412e65e6 100644 --- a/var/spack/repos/builtin/packages/zoltan/package.py +++ b/var/spack/repos/builtin/packages/zoltan/package.py @@ -28,6 +28,10 @@ class Zoltan(AutotoolsPackage): version("3.901", sha256="030c22d9f7532d3076e40cba1f03a63b2ee961d8cc9a35149af4a3684922a910") version("3.83", sha256="17320a9f08e47f30f6f3846a74d15bfea6f3c1b937ca93c0ab759ca02c40e56c") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + depends_on("fortran", type="build") # generated + patch("notparallel.patch", when="@3.8") variant("debug", default=False, description="Builds a debug version of the library.") diff --git a/var/spack/repos/builtin/packages/zookeeper/package.py b/var/spack/repos/builtin/packages/zookeeper/package.py index edac1784e72827..12d4e37eb90575 100644 --- a/var/spack/repos/builtin/packages/zookeeper/package.py +++ b/var/spack/repos/builtin/packages/zookeeper/package.py @@ -19,5 +19,8 @@ class Zookeeper(Package): version("3.4.11", sha256="f6bd68a1c8f7c13ea4c2c99f13082d0d71ac464ffaf3bf7a365879ab6ad10e84") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def install(self, spec, prefix): install_tree(".", prefix) diff --git a/var/spack/repos/builtin/packages/zopfli/package.py b/var/spack/repos/builtin/packages/zopfli/package.py index b1ec085cfb6230..8e5931a67d011a 100644 --- a/var/spack/repos/builtin/packages/zopfli/package.py +++ b/var/spack/repos/builtin/packages/zopfli/package.py @@ -19,6 +19,9 @@ class Zopfli(CMakePackage): version("1.0.3", sha256="e955a7739f71af37ef3349c4fa141c648e8775bceb2195be07e86f8e638814bd") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + def cmake_args(self): args = [self.define_from_variant("ZOPFLI_BUILD_SHARED", "shared")] diff --git a/var/spack/repos/builtin/packages/zsh/package.py b/var/spack/repos/builtin/packages/zsh/package.py index 11ca3f8cce1430..7f7af8a24daa5c 100644 --- a/var/spack/repos/builtin/packages/zsh/package.py +++ b/var/spack/repos/builtin/packages/zsh/package.py @@ -17,6 +17,8 @@ class Zsh(AutotoolsPackage): license("custom") + version("5.9", sha256="9b8d1ecedd5b5e81fbf1918e876752a7dd948e05c1a0dba10ab863842d45acd5") + version("5.8.1", sha256="b6973520bace600b4779200269b1e5d79e5f505ac4952058c11ad5bbf0dd9919") version("5.8", sha256="dcc4b54cc5565670a65581760261c163d720991f0d06486da61f8d839b52de27") version("5.7.1", sha256="7260292c2c1d483b2d50febfa5055176bd512b32a8833b116177bf5f01e77ee8") version("5.6.2", sha256="a50bd66c0557e8eca3b8fa24e85d0de533e775d7a22df042da90488623752e9e") @@ -24,6 +26,8 @@ class Zsh(AutotoolsPackage): version("5.3.1", sha256="fc886cb2ade032d006da8322c09a7e92b2309177811428b121192d44832920da") version("5.1.1", sha256="74e9453b5470b3c0970f9f93cfd603d241c3d7b1968adc0e4b3951073e8d3dec") + depends_on("c", type="build") # generated + # Testing for terminal related things causes failures in e.g. Jenkins. # See e.g. https://www.zsh.org/mla/users/2003/msg00845.html, # although the name of the option has evolved since then. diff --git a/var/spack/repos/builtin/packages/zstd/package.py b/var/spack/repos/builtin/packages/zstd/package.py index cdfdff74baf418..e6b97661e27ee3 100644 --- a/var/spack/repos/builtin/packages/zstd/package.py +++ b/var/spack/repos/builtin/packages/zstd/package.py @@ -24,6 +24,7 @@ class Zstd(CMakePackage, MakefilePackage): license("BSD-3-Clause OR GPL-2.0-or-later") version("develop", branch="dev") + version("1.5.6", sha256="30f35f71c1203369dc979ecde0400ffea93c27391bfd2ac5a9715d2173d92ff7") version("1.5.5", sha256="98e9c3d949d1b924e28e01eccb7deed865eefebf25c2f21c702e5cd5b63b85e1") version("1.5.4", sha256="35ad983197f8f8eb0c963877bf8be50490a0b3df54b4edeb8399ba8a8b2f60a4") version("1.5.2", sha256="f7de13462f7a82c29ab865820149e778cbfe01087b3a55b5332707abf9db4a6e") @@ -40,6 +41,9 @@ class Zstd(CMakePackage, MakefilePackage): version("1.3.0", sha256="0fdba643b438b7cbce700dcc0e7b3e3da6d829088c63757a5984930e2f70b348") version("1.1.2", sha256="980b8febb0118e22f6ed70d23b5b3e600995dbf7489c1f6d6122c1411cdda8d8") + depends_on("c", type="build") # generated + depends_on("cxx", type="build") # generated + variant("programs", default=False, description="Build executables") variant( "libs", @@ -55,6 +59,8 @@ class Zstd(CMakePackage, MakefilePackage): description="Enable support for additional compression methods in programs", ) + depends_on("cmake@3.5:", type="build", when="build_system=cmake @1.5.6:") + depends_on("zlib-api", when="compression=zlib") depends_on("lz4", when="compression=lz4") depends_on("xz", when="compression=lzma") @@ -63,6 +69,8 @@ class Zstd(CMakePackage, MakefilePackage): # (last tested: nvhpc@22.3) conflicts("+programs %nvhpc") + conflicts("platform=windows", when="@1.5.6") + build_system("cmake", "makefile", default="makefile") diff --git a/var/spack/repos/builtin/packages/zstr/package.py b/var/spack/repos/builtin/packages/zstr/package.py index 26131cecf4764d..e056d9aea9452d 100644 --- a/var/spack/repos/builtin/packages/zstr/package.py +++ b/var/spack/repos/builtin/packages/zstr/package.py @@ -24,6 +24,8 @@ class Zstr(Package): version("1.0.1", sha256="e17e67e00ede182504b3165cebd802420770541465d4ba41df1a15bf4c2a63b7") version("1.0.0", sha256="9f4fa8cb0d2cbba03dfe67900c48b6e75c8380d9263a0ac71d795f11e0224b96") + depends_on("cxx", type="build") # generated + depends_on("zlib-api") def install(self, spec, prefix): diff --git a/var/spack/repos/builtin/packages/zziplib/package.py b/var/spack/repos/builtin/packages/zziplib/package.py index 13fc3fee33fef0..fbccabdc7de1f4 100644 --- a/var/spack/repos/builtin/packages/zziplib/package.py +++ b/var/spack/repos/builtin/packages/zziplib/package.py @@ -20,6 +20,8 @@ class Zziplib(AutotoolsPackage, CMakePackage): version("0.13.72", sha256="93ef44bf1f1ea24fc66080426a469df82fa631d13ca3b2e4abaeab89538518dc") version("0.13.69", sha256="846246d7cdeee405d8d21e2922c6e97f55f24ecbe3b6dcf5778073a88f120544") + depends_on("c", type="build") # generated + patch("python2to3.patch", when="@:0.13.69") # Switch to CMake from 0.13.70, first working release is 0.13.71 diff --git a/var/spack/repos/compiler_runtime.test/packages/gcc/package.py b/var/spack/repos/compiler_runtime.test/packages/gcc/package.py index c70ff4faff2698..6d8decc26b2dca 100644 --- a/var/spack/repos/compiler_runtime.test/packages/gcc/package.py +++ b/var/spack/repos/compiler_runtime.test/packages/gcc/package.py @@ -14,7 +14,7 @@ class Gcc(Package): version("12.3.0") @classmethod - def runtime_constraints(cls, *, compiler, pkg): + def runtime_constraints(cls, *, spec, pkg): pkg("*").depends_on( "gcc-runtime", when="%gcc", @@ -22,11 +22,14 @@ def runtime_constraints(cls, *, compiler, pkg): description="If any package uses %gcc, it depends on gcc-runtime", ) pkg("*").depends_on( - f"gcc-runtime@{str(compiler.version)}:", - when=f"%{str(compiler.spec)}", + f"gcc-runtime@{str(spec.version)}:", + when=f"%{str(spec)}", type="link", - description=f"If any package uses %{str(compiler.spec)}, " - f"it depends on gcc-runtime@{str(compiler.version)}:", + description=f"If any package uses %{str(spec)}, " + f"it depends on gcc-runtime@{str(spec.version)}:", ) # The version of gcc-runtime is the same as the %gcc used to "compile" it - pkg("gcc-runtime").requires(f"@={str(compiler.version)}", when=f"%{str(compiler.spec)}") + pkg("gcc-runtime").requires(f"@={str(spec.version)}", when=f"%{str(spec)}") + + # If a node used %gcc@X.Y its dependencies must use gcc-runtime@:X.Y + pkg("*").propagate(f"%gcc@:{str(spec.version)}", when=f"%{str(spec)}") diff --git a/var/spack/repos/compiler_runtime.test/packages/a/package.py b/var/spack/repos/compiler_runtime.test/packages/pkg-a/package.py similarity index 87% rename from var/spack/repos/compiler_runtime.test/packages/a/package.py rename to var/spack/repos/compiler_runtime.test/packages/pkg-a/package.py index 01cb6fe3ccc9ae..22ca47cf130330 100644 --- a/var/spack/repos/compiler_runtime.test/packages/a/package.py +++ b/var/spack/repos/compiler_runtime.test/packages/pkg-a/package.py @@ -5,9 +5,9 @@ from spack.package import * -class A(Package): +class PkgA(Package): homepage = "http://www.example.com" has_code = False version("1.0") - depends_on("b") + depends_on("pkg-b") diff --git a/var/spack/repos/compiler_runtime.test/packages/b/package.py b/var/spack/repos/compiler_runtime.test/packages/pkg-b/package.py similarity index 93% rename from var/spack/repos/compiler_runtime.test/packages/b/package.py rename to var/spack/repos/compiler_runtime.test/packages/pkg-b/package.py index e840a363a5c476..d4147bf47e646f 100644 --- a/var/spack/repos/compiler_runtime.test/packages/b/package.py +++ b/var/spack/repos/compiler_runtime.test/packages/pkg-b/package.py @@ -5,7 +5,7 @@ from spack.package import * -class B(Package): +class PkgB(Package): homepage = "http://www.example.com" has_code = False diff --git a/var/spack/repos/duplicates.test/packages/python-venv b/var/spack/repos/duplicates.test/packages/python-venv new file mode 120000 index 00000000000000..a9a1ce867a8623 --- /dev/null +++ b/var/spack/repos/duplicates.test/packages/python-venv @@ -0,0 +1 @@ +../../builtin.mock/packages/python-venv \ No newline at end of file diff --git a/var/spack/repos/tutorial/packages/mpich/package.py b/var/spack/repos/tutorial/packages/mpich/package.py index 06138bee9462cd..c625ecbc175da8 100644 --- a/var/spack/repos/tutorial/packages/mpich/package.py +++ b/var/spack/repos/tutorial/packages/mpich/package.py @@ -88,16 +88,10 @@ def setup_dependent_build_environment(self, env, dependent_spec): pass def setup_dependent_package(self, module, dependent_spec): - if "platform=cray" in self.spec: - self.spec.mpicc = spack_cc - self.spec.mpicxx = spack_cxx - self.spec.mpifc = spack_fc - self.spec.mpif77 = spack_f77 - else: - self.spec.mpicc = join_path(self.prefix.bin, "mpicc") - self.spec.mpicxx = join_path(self.prefix.bin, "mpic++") - self.spec.mpifc = join_path(self.prefix.bin, "mpif90") - self.spec.mpif77 = join_path(self.prefix.bin, "mpif77") + self.spec.mpicc = join_path(self.prefix.bin, "mpicc") + self.spec.mpicxx = join_path(self.prefix.bin, "mpic++") + self.spec.mpifc = join_path(self.prefix.bin, "mpif90") + self.spec.mpif77 = join_path(self.prefix.bin, "mpif77") self.spec.mpicxx_shared_libs = [ join_path(self.prefix.lib, "libmpicxx.{0}".format(dso_suffix)), From e7fe3f6b163cd355037dd83e276cc66e26119cfd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Aug 2024 22:54:43 +0000 Subject: [PATCH 56/56] build(deps): bump mypy in /.github/workflows/requirements Bumps [mypy](https://github.com/python/mypy) from 1.8.0 to 1.11.1. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.8.0...v1.11.1) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/requirements/style/requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/requirements/style/requirements.txt b/.github/workflows/requirements/style/requirements.txt index 6cd71ed1280f30..6e87fabd80150c 100644 --- a/.github/workflows/requirements/style/requirements.txt +++ b/.github/workflows/requirements/style/requirements.txt @@ -2,6 +2,6 @@ black==24.8.0 clingo==5.7.1 flake8==7.1.1 isort==5.13.2 -mypy==1.8.0 +mypy==1.11.1 types-six==1.16.21.20240513 vermin==1.6.0