py-pynucleus: Add variant, modify dependencies (#41006)
This commit is contained in:
parent
49c2894def
commit
15dcd3c65c
@ -19,6 +19,9 @@ class PyPynucleus(PythonPackage):
|
|||||||
for ref in refs:
|
for ref in refs:
|
||||||
version(ref, branch=ref)
|
version(ref, branch=ref)
|
||||||
|
|
||||||
|
variant("examples", default=True, description="Install examples")
|
||||||
|
variant("tests", default=True, description="Install tests")
|
||||||
|
|
||||||
depends_on("python@3.10:", type=("build", "run"))
|
depends_on("python@3.10:", type=("build", "run"))
|
||||||
depends_on("py-mpi4py@2.0.0:", type=("build", "link", "run"))
|
depends_on("py-mpi4py@2.0.0:", type=("build", "link", "run"))
|
||||||
depends_on("py-cython@0.29.32:", type=("build", "run"))
|
depends_on("py-cython@0.29.32:", type=("build", "run"))
|
||||||
@ -30,14 +33,14 @@ class PyPynucleus(PythonPackage):
|
|||||||
depends_on("py-h5py", type=("build", "run"))
|
depends_on("py-h5py", type=("build", "run"))
|
||||||
depends_on("py-tabulate", type=("build", "run"))
|
depends_on("py-tabulate", type=("build", "run"))
|
||||||
depends_on("py-pyyaml", type=("build", "run"))
|
depends_on("py-pyyaml", type=("build", "run"))
|
||||||
depends_on("py-matplotlib+latex", type=("build", "run"))
|
depends_on("py-matplotlib", type=("build", "run"))
|
||||||
depends_on("py-scikit-sparse", type=("build", "run"))
|
depends_on("py-scikit-sparse", type=("build", "run"))
|
||||||
depends_on("py-modepy", type=("build", "run"))
|
depends_on("py-modepy", type=("build", "run"))
|
||||||
depends_on("py-meshpy", type=("build", "run"))
|
depends_on("py-meshpy", type=("build", "run"))
|
||||||
depends_on("py-pytools", type=("build", "run"))
|
depends_on("py-pytools", type=("build", "run"))
|
||||||
depends_on("py-psutil", type="run")
|
depends_on("py-psutil", type="run")
|
||||||
|
depends_on("py-pytest", when="+tests", type="run")
|
||||||
variant("examples", default=True, description="Install examples")
|
depends_on("py-pytest-html", when="+tests", type="run")
|
||||||
|
|
||||||
import_modules = [
|
import_modules = [
|
||||||
"PyNucleus",
|
"PyNucleus",
|
||||||
@ -64,5 +67,9 @@ def install_python(self):
|
|||||||
def install_additional_files(self):
|
def install_additional_files(self):
|
||||||
spec = self.spec
|
spec = self.spec
|
||||||
prefix = self.prefix
|
prefix = self.prefix
|
||||||
if "+examples" in spec:
|
if "+examples" in spec or "+tests" in spec:
|
||||||
install_tree("drivers", prefix.drivers)
|
install_tree("drivers", prefix.drivers)
|
||||||
|
if "+examples" in spec:
|
||||||
|
install_tree("examples", prefix.examples)
|
||||||
|
if "+tests" in spec:
|
||||||
|
install_tree("tests", prefix.tests)
|
||||||
|
Loading…
Reference in New Issue
Block a user