py-psyclone and py-fparser: Add new releases (#42744)
* py-psyclone and py-fparser new releases added * py-fparser: add missing releases for py-psyclone * py-psyclone: actioned @adamjstewart comments * py-psyclone: removed py-pytest-pylint * py-pytest-pylint: added package @ latest version * py-pytest-pylint: reformatted * Update var/spack/repos/builtin/packages/py-psyclone/package.py Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com> * py-pytest-pylint: added build deps and runtime dep versions * py-pytest-pylint: removed version from setuptools * py-psyclone: add py-pytest-pylint test dep and alphabetize deps * Update var/spack/repos/builtin/packages/py-pytest-pylint/package.py Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com> * py-psyclone: deps ordered --------- Co-authored-by: Adam J. Stewart <ajstewart426@gmail.com>
This commit is contained in:
parent
03e22adb5b
commit
9a3d248348
@ -7,40 +7,56 @@
|
||||
|
||||
|
||||
class PyFparser(PythonPackage):
|
||||
"""Parser for Fortran 77..2003 code."""
|
||||
"""
|
||||
This project is based upon the Fortran (77..2003) parser
|
||||
originally developed by Pearu Peterson for the F2PY project,
|
||||
www.f2py.com. It provides a parser for Fortran source code
|
||||
implemented purely in Python with minimal dependencies.
|
||||
|
||||
"""
|
||||
|
||||
# Links
|
||||
homepage = "https://github.com/stfc/fparser"
|
||||
git = "https://github.com/stfc/fparser.git"
|
||||
pypi = "fparser/fparser-0.1.3.tar.gz"
|
||||
pypi = "fparser/fparser-0.1.4.tar.gz"
|
||||
|
||||
# License
|
||||
license("BSD-3-Clause")
|
||||
|
||||
# Releases
|
||||
version("develop", branch="master")
|
||||
version("0.1.4", sha256="00d4f7e9bbd8a9024c3c2f308dd3be9b0eeff3cb852772c9f3cf0c4909dbafd4")
|
||||
version("0.1.3", sha256="10ba8b2803632846f6f011278e3810188a078d89afcb4a38bed0cbf10f775736")
|
||||
version("0.0.16", sha256="a06389b95a1b9ed12f8141b69c67343da5ba0a29277b2997b02573a93af14e13")
|
||||
version("0.0.15", sha256="53a7f3e3a651b6d2a83c6cc8194d7de0abdc3bd54b2b83b0f379739b0dc74a9e")
|
||||
version("0.0.14", sha256="ed8ffcd4aecb7e1f09d019c9663aa0effb44f489e96a60759e83e6a3834220eb")
|
||||
version("0.0.13", sha256="3c7e939fcc6b010de717eb6bd5102750dea26f15b6f6346cb285652b6a55818a")
|
||||
version("0.0.12", sha256="9ea2cf3cdf64e440ab9d5b526dda2dc3528fe5aa7a85634e81b0ee3c0c39886f")
|
||||
version("0.0.6", sha256="bf8a419cb528df1bfc24ddd26d63f2ebea6f1e103f1a259d8d3a6c9b1cd53012")
|
||||
version("0.0.5", sha256="f3b5b0ac56fd22abed558c0fb0ba4f28edb8de7ef24cfda8ca8996562215822f")
|
||||
|
||||
depends_on("py-setuptools@42:", type="build", when="@0.1:")
|
||||
# Dependencies for latest version
|
||||
depends_on("py-setuptools@61:", type="build", when="@0.1.4:")
|
||||
depends_on("py-setuptools", type="build")
|
||||
depends_on("py-setuptools-scm@6.2:+toml", type=("build", "run"), when="@0.1:")
|
||||
depends_on("py-setuptools-scm-git-archive", type="build", when="@0.1:")
|
||||
depends_on("py-wheel@0.29:", type="build", when="@0.1:")
|
||||
|
||||
depends_on("py-importlib-metadata", type=("build", "run"), when="@0.1:")
|
||||
|
||||
# Historical dependencies
|
||||
depends_on("py-setuptools@42:", type="build", when="@0.1:")
|
||||
depends_on("py-numpy", type=("build", "run"), when="@:0.0.5")
|
||||
depends_on("py-nose", type=("build", "run"), when="@:0.0.7")
|
||||
# six is unused as of 0.0.15, but still listed in setup.py
|
||||
depends_on("py-six", type=("build", "run"), when="@0.0.6:0.0.16")
|
||||
|
||||
depends_on("py-pytest", type="test")
|
||||
# Dependencies only required for tests:
|
||||
depends_on("py-pytest@3.3:", type="test")
|
||||
|
||||
# Test
|
||||
@run_after("install")
|
||||
@on_package_attributes(run_tests=True)
|
||||
def check_build(self):
|
||||
# Ensure that pytest.ini exists inside the source tree,
|
||||
# otherwise an external pytest.ini can cause havoc:
|
||||
touch("pytest.ini")
|
||||
pytest = which("pytest")
|
||||
# Limit pystest to search inside the build tree
|
||||
with working_dir("src"):
|
||||
Executable("py.test")()
|
||||
pytest()
|
||||
|
@ -7,36 +7,73 @@
|
||||
|
||||
|
||||
class PyPsyclone(PythonPackage):
|
||||
"""Code generation for the PSyKAl framework from the GungHo project,
|
||||
as used by the LFRic model at the UK Met Office."""
|
||||
"""
|
||||
Code generation system developed to support domain-specific languages
|
||||
(DSLs) for finite element, finite volume and finite difference codes.
|
||||
Notably, it is used in the LFRic Project from the UK Met Office, and
|
||||
it also supports the GOcean (2D, finite difference) DSL.
|
||||
|
||||
"""
|
||||
|
||||
# Links
|
||||
homepage = "https://github.com/stfc/PSyclone"
|
||||
url = "https://github.com/stfc/PSyclone/archive/1.5.1.tar.gz"
|
||||
git = "https://github.com/stfc/PSyclone.git"
|
||||
pypi = "PSyclone/PSyclone-2.5.0.tar.gz"
|
||||
|
||||
# License
|
||||
license("BSD-3-Clause")
|
||||
|
||||
# Releases
|
||||
version("develop", branch="master")
|
||||
version("1.5.1", commit="eba7a097175b02f75dec70616cf267b7b3170d78")
|
||||
version("2.5.0", sha256="dd1b40d635423c6b23effd2c569908d319afa6153680692e1cbae27f7b5bf4dc")
|
||||
version("2.4.0", sha256="14fd3717f99b317471356c59c1d4c4c22c41fd264af11b78ed831dd2eb71a270")
|
||||
version("2.3.1", sha256="eee70b3069d71fcf95e9bc8796f0333bd502e0202a98df051b635b133432a082")
|
||||
version("2.3.0", sha256="a2cb3f03ad827de99af6acef794d354146443f21623830e4ff62282a81b7cdb3")
|
||||
version("2.2.0", sha256="da829e3b88bf8df7bdb1f261cfc9b20c119eae79fbbd92d970eefee7390ca159")
|
||||
version("2.1.0", sha256="7ef967146d0e2f4662d1d68472242d12f2097adb90646c5646c962ea2e0f187c")
|
||||
version("2.0.0", sha256="94766ffda760404af99f85d70341376192e4a1b8e16e7ae5df980038898a9c41")
|
||||
version("1.5.1", sha256="f053ad7316623b2a4002afc79607abda3b22306645e86f2312d9f3fe56d312dc")
|
||||
|
||||
# Current dependencies
|
||||
depends_on("py-setuptools", type="build")
|
||||
depends_on("py-pyparsing", type=("build", "run"))
|
||||
depends_on("py-fparser@0.1.4:", type=("build", "run"), when="@2.5.0")
|
||||
depends_on("py-configparser", type=("build", "run"))
|
||||
depends_on("py-jsonschema", type=("build", "run"), when="@2.5.0")
|
||||
depends_on("py-sympy", type=("build", "run"), when="@2.2.0:")
|
||||
|
||||
# Historical dependencies
|
||||
depends_on("py-six", type=("build", "run"), when="@2.0.0:2.3.1")
|
||||
depends_on("py-jsonschema@3.0.2", type=("build", "run"), when="@2.1.0:2.4.0")
|
||||
|
||||
# Test cases fail without compatible versions of py-fparser:
|
||||
depends_on("py-fparser@0.0.5", type=("build", "run"), when="@1.5.1")
|
||||
depends_on("py-fparser", type=("build", "run"), when="@1.5.2:")
|
||||
depends_on("py-fparser@0.1.3", type=("build", "run"), when="@2.4.0")
|
||||
depends_on("py-fparser@0.0.16", type=("build", "run"), when="@2.3.1")
|
||||
depends_on("py-fparser@0.0.15", type=("build", "run"), when="@2.3.0")
|
||||
depends_on("py-fparser@0.0.14", type=("build", "run"), when="@2.2.0")
|
||||
depends_on("py-fparser@0.0.13", type=("build", "run"), when="@2.1.0")
|
||||
depends_on("py-fparser@0.0.12", type=("build", "run"), when="@2.0.0")
|
||||
|
||||
# Dependencies only required for tests:
|
||||
depends_on("py-numpy", type="test")
|
||||
depends_on("py-nose", type="test")
|
||||
depends_on("py-pep8", type="test")
|
||||
depends_on("py-flake8", type="test")
|
||||
depends_on("py-pylint@:2", type="test")
|
||||
depends_on("py-pytest-cov", type="test")
|
||||
depends_on("py-pytest-pep8", type="test")
|
||||
depends_on("py-pytest-pylint", type="test")
|
||||
depends_on("py-pytest-flakes", type="test")
|
||||
depends_on("py-pytest-xdist", type="test")
|
||||
depends_on("py-pytest", type="test")
|
||||
|
||||
# Test
|
||||
@run_after("install")
|
||||
@on_package_attributes(run_tests=True)
|
||||
def check_build(self):
|
||||
# Limit py.test to search inside the build tree:
|
||||
touch("pytest.ini")
|
||||
pytest = which("pytest")
|
||||
# Limit pytest to search inside the build tree
|
||||
with working_dir("src"):
|
||||
Executable("py.test")()
|
||||
pytest()
|
||||
|
||||
def setup_build_environment(self, env):
|
||||
# Allow testing with installed executables:
|
||||
# Allow testing with installed executables
|
||||
env.prepend_path("PATH", self.prefix.bin)
|
||||
|
31
var/spack/repos/builtin/packages/py-pytest-pylint/package.py
Normal file
31
var/spack/repos/builtin/packages/py-pytest-pylint/package.py
Normal file
@ -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 PyPytestPylint(PythonPackage):
|
||||
"""Run pylint with pytest and have configurable rule types (i.e.
|
||||
Convention, Warn, and Error) fail the build. You can also specify a
|
||||
pylintrc file.
|
||||
|
||||
"""
|
||||
|
||||
homepage = "https://pypi.org/project/pytest-pylint/"
|
||||
pypi = "pytest-pylint/pytest-pylint-0.21.0.tar.gz"
|
||||
git = "https://github.com/pytest-dev/pytest"
|
||||
|
||||
license("MIT")
|
||||
|
||||
version("0.21.0", sha256="88764b8e1d5cfa18809248e0ccc2fc05035f08c35f0b0222ddcfea1c3c4e553e")
|
||||
|
||||
# python_requires
|
||||
depends_on("python@3.7:", type=("build", "run"))
|
||||
|
||||
# install_requires
|
||||
depends_on("py-setuptools", type=("build"))
|
||||
depends_on("py-pytest@7.0.0:", type=("build", "run"))
|
||||
depends_on("py-pylint@2.15.0:", type=("build", "run"))
|
||||
depends_on("py-tomli@1.1.0:", type=("build", "run"), when="^python@:3.10")
|
Loading…
Reference in New Issue
Block a user