From 1ad9f6268b7c6da466f9ce33387887dd94c55acd Mon Sep 17 00:00:00 2001 From: Milton Woods Date: Tue, 2 Jul 2019 11:24:45 +1000 Subject: [PATCH] New packages: libmo-unpack and py-mo-pack (#11895) * libmo-unpack: package to encode and decode UM fields * py-mo-pack: python interface for libmo-unpack --- .../builtin/packages/libmo-unpack/package.py | 18 +++++++++++++++++ .../builtin/packages/py-mo-pack/package.py | 20 +++++++++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 var/spack/repos/builtin/packages/libmo-unpack/package.py create mode 100644 var/spack/repos/builtin/packages/py-mo-pack/package.py diff --git a/var/spack/repos/builtin/packages/libmo-unpack/package.py b/var/spack/repos/builtin/packages/libmo-unpack/package.py new file mode 100644 index 0000000000..af76b682cb --- /dev/null +++ b/var/spack/repos/builtin/packages/libmo-unpack/package.py @@ -0,0 +1,18 @@ +# Copyright 2013-2019 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 import * + + +class LibmoUnpack(CMakePackage): + """A library for handling the WGDOS and RLE compression schemes + used in UM files.""" + + homepage = "https://github.com/SciTools/libmo_unpack" + url = "https://github.com/SciTools/libmo_unpack/archive/v3.1.2.tar.gz" + + version('3.1.2', sha256='e09ef3e6f1075144acc5d6466b4ef70b2fe32ed4ab1840dd4fb7e15a40f3d370') + + depends_on('check') diff --git a/var/spack/repos/builtin/packages/py-mo-pack/package.py b/var/spack/repos/builtin/packages/py-mo-pack/package.py new file mode 100644 index 0000000000..0d4bee45f7 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-mo-pack/package.py @@ -0,0 +1,20 @@ +# Copyright 2013-2019 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 import * + + +class PyMoPack(PythonPackage): + """Packing methods used to encode and decode the data payloads of + Met Office Unified Model 'fields'""" + + homepage = "https://github.com/SciTools/mo_pack" + url = "https://github.com/SciTools/mo_pack/archive/v0.2.0.tar.gz" + + version('0.2.0', sha256='4aa70e1f846b666670843bc2514435dedf7393203e88abaf74d48f8f2717a726') + + depends_on('libmo-unpack') + depends_on('py-numpy', type=('build', 'run')) + depends_on('py-cython', type=('build', 'run'))