OBS-URL: https://build.opensuse.org/request/show/686999 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-netCDF4?expand=0&rev=3
96 lines
3.2 KiB
RPMSpec
96 lines
3.2 KiB
RPMSpec
#
|
|
# spec file for package python-netCDF4
|
|
#
|
|
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
|
Name: python-netCDF4
|
|
Version: 1.4.3.2
|
|
Release: 0
|
|
Summary: Python interface to netCDF 3 and 4
|
|
License: HPND AND MIT
|
|
Group: Development/Languages/Python
|
|
URL: https://github.com/Unidata/netcdf4-python
|
|
Source: https://files.pythonhosted.org/packages/source/n/netCDF4/netCDF4-%{version}.tar.gz
|
|
Patch0: netcdf-disable-broken-test.patch
|
|
BuildRequires: %{python_module Cython >= 0.21}
|
|
BuildRequires: %{python_module cftime}
|
|
BuildRequires: %{python_module devel}
|
|
BuildRequires: %{python_module numpy-devel >= 1.9.0}
|
|
BuildRequires: %{python_module setuptools >= 18.0}
|
|
BuildRequires: fdupes
|
|
BuildRequires: hdf-devel
|
|
BuildRequires: hdf5-devel
|
|
BuildRequires: libcurl-devel
|
|
BuildRequires: libjpeg-devel
|
|
BuildRequires: netcdf-devel
|
|
BuildRequires: python-rpm-macros
|
|
Requires: hdf
|
|
Requires: hdf5
|
|
Requires: netcdf
|
|
Requires: python-cftime
|
|
Requires: python-numpy >= 1.9.0
|
|
# SECTION tests
|
|
BuildRequires: %{python_module pytest}
|
|
BuildRequires: netcdf
|
|
# /SECTION
|
|
%python_subpackages
|
|
|
|
%description
|
|
netCDF version 4 has many features not found in earlier versions of
|
|
the library and is implemented on top of HDF5. This module can read
|
|
and write files in both the new netCDF 4 and the old netCDF 3
|
|
format, and can create files that are readable by HDF5 clients. The
|
|
API modelled after Scientific.IO.NetCDF, and should be familiar to
|
|
users of that module.
|
|
|
|
Most new features of netCDF 4 are implemented, such as multiple unlimited
|
|
dimensions, groups and zlib data compression. All the new numeric data types
|
|
(such as 64 bit and unsigned integer types) are implemented. Compound and
|
|
variable length (vlen) data types are supported, but the enum and opaque data
|
|
types are not. Mixtures of compound and vlen data types (compound types
|
|
containing vlens, and vlens containing compound types) are not supported.
|
|
|
|
%prep
|
|
%setup -q -n netCDF4-%{version}
|
|
%patch0 -p1
|
|
|
|
%build
|
|
export CFLAGS="%{optflags} -fno-strict-aliasing"
|
|
%python_build
|
|
|
|
%install
|
|
%python_install
|
|
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
|
|
|
%check
|
|
pushd test
|
|
export NO_NET=1
|
|
%{python_expand export PYTHONPATH=%{buildroot}%{$python_sitearch}
|
|
$python run_all.py
|
|
}
|
|
popd
|
|
|
|
%files %{python_files}
|
|
%doc Changelog README.md
|
|
%license COPYING
|
|
%python3_only %{_bindir}/nc3tonc4
|
|
%python3_only %{_bindir}/nc4tonc3
|
|
%python3_only %{_bindir}/ncinfo
|
|
%{python_sitearch}/*
|
|
|
|
%changelog
|