diff --git a/var/spack/repos/builtin/packages/bazel/cppcompileaction-7.0.0.patch b/var/spack/repos/builtin/packages/bazel/cppcompileaction-7.0.0.patch new file mode 100644 index 0000000000..b182f98f82 --- /dev/null +++ b/var/spack/repos/builtin/packages/bazel/cppcompileaction-7.0.0.patch @@ -0,0 +1,12 @@ +diff --color=auto --color=auto -Naur a/src/main/java/com/google/devtools/build/lib/rules/cpp/HeaderDiscovery.java b/src/main/java/com/google/devtools/build/lib/rules/cpp/HeaderDiscovery.java +--- a/src/main/java/com/google/devtools/build/lib/rules/cpp/HeaderDiscovery.java 1980-01-01 00:00:00 ++++ b/src/main/java/com/google/devtools/build/lib/rules/cpp/HeaderDiscovery.java 2024-02-15 13:36:37 +@@ -143,7 +143,7 @@ + LabelConstants.EXPERIMENTAL_EXTERNAL_PATH_PREFIX.getRelative( + execPath.relativeTo(execRoot.getParentDirectory())); + } else { +- absolutePathProblems.add(execPathFragment.getPathString()); ++ // absolutePathProblems.add(execPathFragment.getPathString()); + continue; + } + } diff --git a/var/spack/repos/builtin/packages/bazel/package.py b/var/spack/repos/builtin/packages/bazel/package.py index b152c1445b..30ca644ad4 100644 --- a/var/spack/repos/builtin/packages/bazel/package.py +++ b/var/spack/repos/builtin/packages/bazel/package.py @@ -24,6 +24,17 @@ class Bazel(Package): license("Apache-2.0") + version("7.0.2", sha256="dea2b90575d43ef3e41c402f64c2481844ecbf0b40f8548b75a204a4d504e035") + version("7.0.1", sha256="596b13e071d27c43343ec8f5d263cb5312fafe7ef8702401f7ed492f182f4e6c") + version("7.0.0", sha256="477e54f6374001f439a9471ba1de9d7824daf129db95510849ecc5e19ce88170") + version("6.5.0", sha256="fc89da919415289f29e4ff18a5e01270ece9a6fe83cb60967218bac4a3bb3ed2") + version("6.4.0", sha256="bd88ff602c8bbb29ee82ba2a6b12ad092d51ec668c6577f9628f18e48ff4e51e") + version("6.3.2", sha256="8cd7feac58193be2bcba451ba6688a46824d37ca6359ff58e0d44eb98f042948") + version("6.3.1", sha256="2676319e86c5aeab142dccd42434364a33aa330a091c13562b7de87a10e68775") + version("6.3.0", sha256="902198981b1d26112fc05913e79f1b3e9772c3f95594caf85619d041ba06ede0") + version("6.2.1", sha256="4cf4d264bff388ee0012735728630d23832d3c9d021383b2fadceadb0775dd6b") + version("6.2.0", sha256="f1e8f788637ac574d471d619d2096baaca04a19b57a034399e079633db441945") + version("6.1.2", sha256="6fb3ee22fe9fa86d82e173572d504c089f10825d749725592626e090b38c9679") version("6.1.1", sha256="6b900f26d676c7eca1d2e7dff9b71890dabd3ff59cab2a2d2178bc8a0395342a") version("6.1.0", sha256="c4b85675541cf66ee7cb71514097fdd6c5fc0e02527243617a4f20ca6b4f2932") version("6.0.0", sha256="7bc0c5145c19a56d82a08fce6908c5e1a0e75e4fbfb3b6f12b4deae7f4b38cbc") @@ -35,6 +46,7 @@ class Bazel(Package): version("5.1.1", sha256="7f5d3bc1d344692b2400f3765fd4b5c0b636eb4e7a8a7b17923095c7b56a4f78") version("5.1.0", sha256="4de301f509fc6d0cbc697b2017384ecdc94df8f36245bbcbedc7ea6780acc9f5") version("5.0.0", sha256="072dd62d237dbc11e0bac02e118d8c2db4d0ba3ba09f1a0eb1e2a460fb8419db") + version("4.2.4", sha256="d5ba2ef28da5275f22e832aaa7f9319c61ea5db9b6a3e23b28a6a64ad03078f3") version("4.2.3", sha256="b0e84d0538f3ec2b95a49bae31a5066f0967281a3ca99965016fbe178acd2d3d") version("4.2.2", sha256="9981d0d53a356c4e87962847750a97c9e8054e460854748006c80f0d7e2b2d33") version("4.2.1", sha256="12ea7aa11e2bdb12de1dceb9939a22e96f5a480437cb17c123379d8e0fdf5e82") @@ -68,7 +80,6 @@ class Bazel(Package): ) # https://bazel.build/install/compile-source#bootstrap-unix-prereq - depends_on("java", type=("build", "run")) depends_on("java@11", when="@5.3:", type=("build", "run")) depends_on("java@8,11", when="@3.3:5.2", type=("build", "run")) depends_on("java@8", when="@0.6:3.2", type=("build", "run")) @@ -86,10 +97,11 @@ class Bazel(Package): patch("compile-0.29.patch") # Disable dependency search - patch("cppcompileaction-0.3.2.patch", when="+nodepfail") + patch("cppcompileaction-7.0.0.patch", when="@7: +nodepfail") + patch("cppcompileaction-0.3.2.patch", when="@:6 +nodepfail") # https://github.com/bazelbuild/bazel/issues/17956 - patch("apple-clang-14.0.3.patch", when="@:5.4.0,6.0:6.1") + patch("apple-clang-14.0.3.patch", when="@:5.4.0,6.0:6.1.1") # https://github.com/bazelbuild/bazel/issues/17958 patch( diff --git a/var/spack/repos/builtin/packages/py-jax/package.py b/var/spack/repos/builtin/packages/py-jax/package.py index 76c6ce28e7..5c1f8b7079 100644 --- a/var/spack/repos/builtin/packages/py-jax/package.py +++ b/var/spack/repos/builtin/packages/py-jax/package.py @@ -23,23 +23,53 @@ class PyJax(PythonPackage): license("Apache-2.0") + version("0.4.23", sha256="2a229a5a758d1b803891b2eaed329723f6b15b4258b14dc0ccb1498c84963685") version("0.4.3", sha256="d43f08f940aa30eb339965cfb3d6bee2296537b0dc2f0c65ccae3009279529ae") - version("0.3.23", sha256="bff436e15552a82c0ebdef32737043b799e1e10124423c57a6ae6118c3a7b6cd") - version("0.2.25", sha256="822e8d1e06257eaa0fdc4c0a0686c4556e9f33647fa2a766755f984786ae7446") + 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 _minimum_jaxlib_version in jax/version.py - jax_to_jaxlib = {"0.4.3": "0.4.2", "0.3.23": "0.3.15", "0.2.25": "0.1.69"} - - for jax, jaxlib in jax_to_jaxlib.items(): - depends_on(f"py-jaxlib@{jaxlib}:", when=f"@{jax}", 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")) # Historical dependencies depends_on("py-absl-py", when="@:0.3", type=("build", "run")) diff --git a/var/spack/repos/builtin/packages/py-jaxlib/package.py b/var/spack/repos/builtin/packages/py-jaxlib/package.py index 23ddc076d4..4030a1f0ae 100644 --- a/var/spack/repos/builtin/packages/py-jaxlib/package.py +++ b/var/spack/repos/builtin/packages/py-jaxlib/package.py @@ -19,23 +19,47 @@ class PyJaxlib(PythonPackage, CudaPackage): license("Apache-2.0") + version("0.4.25", sha256="fc1197c401924942eb14185a61688d0c476e3e81ff71f9dc95e620b57c06eec8") + version("0.4.24", sha256="c4e6963c2c36f634a9a1765e476a1ed4e6c4a7954465ebf72e29f344c28ddc28") version("0.4.3", sha256="2104735dc22be2b105e5517bd5bc6ae97f40e8e9e54928cac1585c6112a3d910") - version("0.3.22", sha256="680a6f5265ba26d5515617a95ae47244005366f879a5c321782fde60f34e6d0d") - version("0.1.74", sha256="bbc78c7a4927012dcb1b7cd135c7521f782d7dad516a2401b56d3190f81afe35") + 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-scipy@1.5:", 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@5.1.1:5.9", when="@0.3:", type="build") - # https://github.com/google/jax/issues/8440 - depends_on("bazel@4.1:4", when="@0.1", type="build") + 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") @@ -56,6 +80,9 @@ class PyJaxlib(PythonPackage, CudaPackage): "https://developer.nvidia.com/cuda-gpus", ) + # https://github.com/google/jax/issues/19992 + conflicts("@0.4.24:", when="target=ppc64le:") + def patch(self): self.tmp_path = tempfile.mkdtemp(prefix="spack") self.buildtmp = tempfile.mkdtemp(prefix="spack") @@ -79,10 +106,13 @@ def patch(self): "build/build.py", string=True, ) + build_wheel = join_path("build", "build_wheel.py") + if self.spec.satisfies("@0.4.14:"): + build_wheel = join_path("jaxlib", "tools", "build_wheel.py") filter_file( "args = parser.parse_args()", "args, junk = parser.parse_known_args()", - "build/build_wheel.py", + build_wheel, string=True, ) diff --git a/var/spack/repos/builtin/packages/py-keras/package.py b/var/spack/repos/builtin/packages/py-keras/package.py index 614174fcac..f9eb62b9a6 100644 --- a/var/spack/repos/builtin/packages/py-keras/package.py +++ b/var/spack/repos/builtin/packages/py-keras/package.py @@ -19,6 +19,7 @@ class PyKeras(PythonPackage): git = "https://github.com/keras-team/keras.git" pypi = "keras/keras-3.0.0.tar.gz" + version("3.0.5", sha256="df3d3795e12c3f6035e811c43c13f1eb41e37241796a0fea120ede4ebe1c4496") version("3.0.4", sha256="ff2204792582e3889c51c77722cc6e8258dbb1ece7db192f5a9bcd1887cf3385") version("3.0.3", sha256="1e455a82be63b7fb4f699e26bd1e04b7dbcbf66fa3a799117afca9ab067b5d61") version("3.0.2", sha256="526b6c053cdd880a33467c5bfd5c460a5bdc0c58869c2683171c2dec2ad3c2d0") @@ -65,6 +66,7 @@ class PyKeras(PythonPackage): 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")) @@ -77,6 +79,7 @@ class PyKeras(PythonPackage): # depends_on("py-tensorflow@2.16.0", 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 diff --git a/var/spack/repos/builtin/packages/py-tensorflow-hub/package.py b/var/spack/repos/builtin/packages/py-tensorflow-hub/package.py index 7e13114b6b..58916a38d0 100644 --- a/var/spack/repos/builtin/packages/py-tensorflow-hub/package.py +++ b/var/spack/repos/builtin/packages/py-tensorflow-hub/package.py @@ -24,7 +24,8 @@ class PyTensorflowHub(Package): extends("python") - depends_on("bazel", type="build") + # TODO: Directories have changed in Bazel 7, need to update manual install logic + depends_on("bazel@:6", type="build") depends_on("py-pip", type="build") depends_on("py-wheel", type="build") depends_on("py-setuptools", type="build") 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 053405e09f..38af49c199 100644 --- a/var/spack/repos/builtin/packages/py-tensorflow-probability/package.py +++ b/var/spack/repos/builtin/packages/py-tensorflow-probability/package.py @@ -83,7 +83,8 @@ class PyTensorflowProbability(Package): ) # keep here for backwards compatibility depends_on("py-tensorflow@2.4:", when="@0.12:0.17", type=("build", "run")) - depends_on("bazel@3.2:", type="build") + # TODO: Directories have changed in Bazel 7, need to update manual install logic + depends_on("bazel@3.2:6", type="build") def install(self, spec, prefix): self.tmp_path = tempfile.mkdtemp(prefix="spack")