Add chemfiles and py-chemfiles (#35410)

This commit is contained in:
Rocco Meli 2023-02-13 14:53:10 +01:00 committed by GitHub
parent 471684add4
commit 1bc425ddad
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 53 additions and 0 deletions

View File

@ -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 Chemfiles(CMakePackage):
"""Chemfiles is a library providing a simple and format agnostic interface for
reading and writing computational chemistry files: trajectories, configurations,
and topologies."""
homepage = "https://chemfiles.org"
url = "https://github.com/chemfiles/chemfiles/archive/refs/tags/0.10.3.tar.gz"
maintainers("RMeli")
version("0.10.3", sha256="5f53d87a668a85bebf04e0e8ace0f1db984573de1c54891ba7d37d31cced0408")
variant("shared", default=False, description="Build shared libraries")
def cmake_args(self):
args = [
self.define_from_variant("BUILD_SHARED_LIBS", "shared"),
]
return args

View File

@ -0,0 +1,26 @@
# 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 PyChemfiles(PythonPackage):
"""Python interface to chemfiles"""
homepage = "http://chemfiles.org/chemfiles.py/latest/"
pypi = "chemfiles/chemfiles-0.10.3.tar.gz"
maintainers("RMeli")
version("0.10.3", sha256="4bbb8b116492a57dbf6ddb4c84aad0133cd782e0cc0e53e4b957f2d93e6806ea")
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")