openmm: Apply patch use FindCUDAToolkit (#42437)

This commit is contained in:
Mosè Giordano 2024-02-02 10:04:03 +00:00 committed by GitHub
parent 3d3d075496
commit 795360fe48
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -27,7 +27,7 @@ class Openmm(CMakePackage, CudaPackage):
install_targets = ["install", "PythonInstall"] install_targets = ["install", "PythonInstall"]
depends_on("python@2.7:", type=("build", "run")) depends_on("python@2.7:", type=("build", "run"))
depends_on("cmake@3.17:", type="build", when="@7.6.0:") depends_on("cmake@3.17:", type="build", when="@7.5.1:")
depends_on("cmake@3.1:", type="build") depends_on("cmake@3.1:", type="build")
# https://github.com/openmm/openmm/issues/3317 # https://github.com/openmm/openmm/issues/3317
depends_on("doxygen@:1.9.1", type="build", when="@:7.6.0") depends_on("doxygen@:1.9.1", type="build", when="@:7.6.0")
@ -39,6 +39,15 @@ class Openmm(CMakePackage, CudaPackage):
depends_on("cuda", when="+cuda", type=("build", "link", "run")) depends_on("cuda", when="+cuda", type=("build", "link", "run"))
extends("python") extends("python")
# Backport <https://github.com/openmm/openmm/pull/3154> to
# `openmm@7.5.1+cuda`, which is the version currently required by
# `py-alphafold`.
patch(
"https://github.com/openmm/openmm/pull/3154.patch?full_index=1",
sha256="90bc01b34cf998e90220669b3ed55cd3c42000ad364234033aac631ed754e9bd",
when="@7.5.1+cuda",
)
def patch(self): def patch(self):
install_string = 'set(PYTHON_SETUP_COMMAND "install ' '--prefix={0}")'.format(self.prefix) install_string = 'set(PYTHON_SETUP_COMMAND "install ' '--prefix={0}")'.format(self.prefix)