5541250
Name:           netcdf4-python
bbad65a
Version:        1.5.2
bbad65a
Release:        1%{?dist}
5541250
Summary:        Python/numpy interface to netCDF
5541250
5541250
License:        MIT
Orion Poplawski b5bc88b
URL:            https://github.com/Unidata/netcdf4-python
20f48a6
Source0:        https://github.com/Unidata/netcdf4-python/archive/v%{version}rel/%{name}-%{version}.tar.gz
5541250
# No rpath for library
37e4090
# http://code.google.com/p/netcdf4-python/issues/detail?id=138
5541250
Patch0:         netcdf4-python-norpath.patch
b7eed1f
# Don't link against hdf5 and z libraries
37e4090
# http://code.google.com/p/netcdf4-python/issues/detail?id=139
b7eed1f
Patch1:         netcdf4-python-libs.patch
5541250
Orion Poplawski cf4c2af
%if 0%{?fedora} < 30
5541250
BuildRequires:  python2-devel
Orion Poplawski 55c1f15
BuildRequires:  python2-setuptools >= 18.0
Orion Poplawski cf4c2af
# Added in 1.4.0
Orion Poplawski cf4c2af
#BuildRequires:  python2-cftime
fbfa33d
BuildRequires:  python2-Cython
fbfa33d
BuildRequires:  python2-dateutil
2f8e5fc
# EL6 has python 2.6 and needs ordereddict
2f8e5fc
%if 0%{?rhel} && 0%{?rhel} <= 6
2f8e5fc
BuildRequires:  python-ordereddict
2f8e5fc
%endif
fbfa33d
BuildRequires:  python2-numpy
Orion Poplawski cf4c2af
%endif
Orion Poplawski 19477ac
BuildRequires:  python%{python3_pkgversion}-devel
Orion Poplawski cf4c2af
BuildRequires:  python%{python3_pkgversion}-setuptools >= 18
5d77751
BuildRequires:  python%{python3_pkgversion}-cftime
Orion Poplawski 19477ac
BuildRequires:  python%{python3_pkgversion}-Cython
Orion Poplawski 19477ac
BuildRequires:  python%{python3_pkgversion}-dateutil
Orion Poplawski 19477ac
BuildRequires:  python%{python3_pkgversion}-numpy
5541250
BuildRequires:  netcdf-devel
Orion Poplawski 5ed2f39
# python3 is default in fedora, but not EPEL
Orion Poplawski 5ed2f39
%if 0%{?fedora}
Orion Poplawski 5ed2f39
Requires:       python%{python3_pkgversion}-netcdf4 = %{version}-%{release}
Orion Poplawski 5ed2f39
%else
Orion Poplawski 5ed2f39
Requires:       python2-netcdf4 = %{version}-%{release}
Orion Poplawski 5ed2f39
%endif
Orion Poplawski 5ed2f39
Orion Poplawski 5ed2f39
%description
Orion Poplawski 5ed2f39
netCDF version 4 has many features not found in earlier versions of the
Orion Poplawski 5ed2f39
library and is implemented on top of HDF5. This module can read and write
Orion Poplawski 5ed2f39
files in both the new netCDF 4 and the old netCDF 3 format, and can create
Orion Poplawski 5ed2f39
files that are readable by HDF5 clients. The API modeled after
Orion Poplawski 5ed2f39
Scientific.IO.NetCDF, and should be familiar to users of that module.
Orion Poplawski 5ed2f39
Orion Poplawski 5ed2f39
Most new features of netCDF 4 are implemented, such as multiple unlimited
Orion Poplawski 5ed2f39
dimensions, groups and zlib data compression. All the new numeric data types
Orion Poplawski 5ed2f39
(such as 64 bit and unsigned integer types) are implemented. Compound and
Orion Poplawski 5ed2f39
variable length (vlen) data types are supported, but the enum and opaque data
Orion Poplawski 5ed2f39
types are not. Mixtures of compound and vlen data types (compound types
Orion Poplawski 5ed2f39
containing vlens, and vlens containing compound types) are not supported.
5541250
Orion Poplawski 5ed2f39
Orion Poplawski 5ed2f39
%package -n python2-netcdf4
Orion Poplawski 5ed2f39
Summary:        Python/numpy interface to netCDF
2f8e5fc
# EL6 has python 2.6 and needs ordereddict
2f8e5fc
%if 0%{?rhel} && 0%{?rhel} <= 6
2f8e5fc
Requires:       python-ordereddict
2f8e5fc
%endif
Orion Poplawski cf4c2af
# Added in 1.4.0
Orion Poplawski cf4c2af
#Requires:       python2-cftime
fbfa33d
Requires:       python2-Cython
fbfa33d
Requires:       python2-numpy
Orion Poplawski 766b79c
%{?python_provide:%python_provide python2-netcdf4}
Orion Poplawski 5ed2f39
Provides:       netcdf4-python2 = %{version}-%{release}
5541250
Orion Poplawski 5ed2f39
%description -n python2-netcdf4
5541250
netCDF version 4 has many features not found in earlier versions of the
5541250
library and is implemented on top of HDF5. This module can read and write
5541250
files in both the new netCDF 4 and the old netCDF 3 format, and can create
5541250
files that are readable by HDF5 clients. The API modeled after
5541250
Scientific.IO.NetCDF, and should be familiar to users of that module.
5541250
5541250
Most new features of netCDF 4 are implemented, such as multiple unlimited
5541250
dimensions, groups and zlib data compression. All the new numeric data types
5541250
(such as 64 bit and unsigned integer types) are implemented. Compound and
5541250
variable length (vlen) data types are supported, but the enum and opaque data
5541250
types are not. Mixtures of compound and vlen data types (compound types
5541250
containing vlens, and vlens containing compound types) are not supported.
5541250
5541250
Orion Poplawski 5ed2f39
%package -n python%{python3_pkgversion}-netcdf4
5541250
Summary:        Python/numpy interface to netCDF
5d77751
Requires:       python%{python3_pkgversion}-cftime
Orion Poplawski 19477ac
Requires:       python%{python3_pkgversion}-Cython
Orion Poplawski 19477ac
Requires:       python%{python3_pkgversion}-numpy
Orion Poplawski 766b79c
%{?python_provide:%python_provide python%{python3_pkgversion}-netcdf4}
Orion Poplawski 5ed2f39
Obsoletes:      netcdf4-python%{python3_pkgversion} < 1.2.7-3
Orion Poplawski 5ed2f39
Provides:       netcdf4-python%{python3_pkgversion} = %{version}-%{release}
5541250
Orion Poplawski 5ed2f39
%description -n python%{python3_pkgversion}-netcdf4
5541250
netCDF version 4 has many features not found in earlier versions of the
5541250
library and is implemented on top of HDF5. This module can read and write
5541250
files in both the new netCDF 4 and the old netCDF 3 format, and can create
5541250
files that are readable by HDF5 clients. The API modeled after
5541250
Scientific.IO.NetCDF, and should be familiar to users of that module.
5541250
5541250
Most new features of netCDF 4 are implemented, such as multiple unlimited
5541250
dimensions, groups and zlib data compression. All the new numeric data types
5541250
(such as 64 bit and unsigned integer types) are implemented. Compound and
5541250
variable length (vlen) data types are supported, but the enum and opaque data
5541250
types are not. Mixtures of compound and vlen data types (compound types
5541250
containing vlens, and vlens containing compound types) are not supported.
5541250
5541250
5541250
%prep
20f48a6
%setup -q -n %{name}-%{version}rel
5541250
%patch0 -p1 -b .norpath
b7eed1f
%patch1 -p1 -b .libs
5541250
5541250
5541250
%build
Orion Poplawski cf4c2af
%if 0%{?fedora} < 30
Orion Poplawski 1de811c
%py2_build
Orion Poplawski cf4c2af
%endif
Orion Poplawski cf4c2af
Orion Poplawski 1de811c
%py3_build
5541250
5541250
5541250
%install
Orion Poplawski 5ed2f39
# python3 is default in fedora, but not EPEL
Orion Poplawski 5ed2f39
%if 0%{?fedora}
Orion Poplawski cf4c2af
%if 0%{?fedora} < 30
Orion Poplawski 5ed2f39
%py2_install
Orion Poplawski cf4c2af
%endif
Orion Poplawski 5ed2f39
%py3_install
Orion Poplawski 5ed2f39
%else
Orion Poplawski 1de811c
%py3_install
Orion Poplawski 1de811c
%py2_install
Orion Poplawski 5ed2f39
%endif
5541250
5541250
 
2f8e5fc
%check
2f8e5fc
cd test
5d77751
export NO_NET=1
Orion Poplawski cf4c2af
%if 0%{?fedora} < 30
Orion Poplawski 1de811c
PYTHONPATH=$(echo ../build/lib.*%{python2_version}) %{__python2} run_all.py
Orion Poplawski cf4c2af
%endif
Orion Poplawski 9ab8811
%ifarch s390x
Orion Poplawski 9ab8811
# FAIL: runTest (tst_compoundvar.VariablesTestCase) -> assert (cmptype4 == dtype4a) # data type should be aligned
Orion Poplawski 9ab8811
PYTHONPATH=$(echo ../build/lib.*%{python3_version}) %{__python3} run_all.py || :
Orion Poplawski 9ab8811
%else
Orion Poplawski 1de811c
PYTHONPATH=$(echo ../build/lib.*%{python3_version}) %{__python3} run_all.py
Orion Poplawski 9ab8811
%endif
5541250
5541250
5541250
%files
Orion Poplawski 49ac374
%license COPYING
5541250
%{_bindir}/nc3tonc4
5541250
%{_bindir}/nc4tonc3
Orion Poplawski dc1a9e3
%{_bindir}/ncinfo
5541250
Orion Poplawski cf4c2af
%if 0%{?fedora} < 30
Orion Poplawski 5ed2f39
%files -n python2-netcdf4
Orion Poplawski 5ed2f39
%license COPYING
Orion Poplawski 5ed2f39
%doc Changelog docs examples README.md
Orion Poplawski 5ed2f39
%{python2_sitearch}/*
Orion Poplawski cf4c2af
%endif
Orion Poplawski 5ed2f39
Orion Poplawski 5ed2f39
%files -n python%{python3_pkgversion}-netcdf4
Orion Poplawski 49ac374
%license COPYING
Orion Poplawski 49ac374
%doc Changelog docs examples README.md
5541250
%{python3_sitearch}/*
5541250
5541250
5541250
%changelog
bbad65a
* Tue Sep 10 2019 Orion Poplawski <orion@nwra.com> - 1.5.2-1
bbad65a
- Update to 1.5.2
bbad65a
bf4e66f
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 1.5.1.2-3
bf4e66f
- Rebuilt for Python 3.8
bf4e66f
f3d2daf
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.1.2-2
f3d2daf
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
f3d2daf
23cdf03
* Mon May  6 2019 Orion Poplawski <orion@nwra.com> - 1.5.1.2-1
23cdf03
- Update to 1.5.1.2
23cdf03
e0101c1
* Wed May  1 2019 Orion Poplawski <orion@nwra.com> - 1.5.1-1
e0101c1
- Update to 1.5.1
e0101c1
20f48a6
* Tue Apr  2 2019 Orion Poplawski <orion@nwra.com> - 1.5.0.1-1
20f48a6
- Update to 1.5.0.1
20f48a6
8ae04a2
* Mon Mar 18 2019 Orion Poplawski <orion@nwra.com> - 1.4.3.2-2
8ae04a2
- Rebuild for netcdf 4.6.3
8ae04a2
5d77751
* Sat Mar  9 2019 Orion Poplawski <orion@nwra.com> - 1.4.3.2-1
5d77751
- Update to 1.4.3.2
5d77751
f45df36
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.1-2
f45df36
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
f45df36
Orion Poplawski cf4c2af
* Sun Oct 7 2018 Orion Poplawski <orion@nwra.com> - 1.3.1-1
Orion Poplawski cf4c2af
- Update to 1.3.1
Orion Poplawski cf4c2af
- Drop Python 2 in Fedora (bugz #1634978)
Orion Poplawski cf4c2af
dba91d1
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.9-7
dba91d1
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
dba91d1
31f65b9
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 1.2.9-6
31f65b9
- Rebuilt for Python 3.7
31f65b9
fbfa33d
* Tue Mar 13 2018 Iryna Shcherbina <ishcherb@redhat.com> - 1.2.9-5
fbfa33d
- Update Python 2 dependency declarations to new packaging standards
fbfa33d
  (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
fbfa33d
b50d6e2
* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.9-4
b50d6e2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
b50d6e2
a187ea2
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.9-3
a187ea2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
a187ea2
aaec9a6
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.9-2
aaec9a6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
aaec9a6
Orion Poplawski 55c1f15
* Tue Jun 20 2017 Orion Poplawski <orion@cora.nwra.com> - 1.2.9-1
Orion Poplawski 55c1f15
- Update to 1.2.9
Orion Poplawski 55c1f15
Orion Poplawski 766b79c
* Tue Mar 7 2017 Orion Poplawski <orion@cora.nwra.com> - 1.2-7-4
Orion Poplawski 766b79c
- Provide python-netcdf4
Orion Poplawski 766b79c
Orion Poplawski 5ed2f39
* Thu Mar 2 2017 Orion Poplawski <orion@cora.nwra.com> - 1.2-7-3
Orion Poplawski 5ed2f39
- Move python libraries into python?- sub-packages
Orion Poplawski 5ed2f39
- Make python3 default for Fedora
Orion Poplawski 5ed2f39
de25804
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.2.7-2
de25804
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
de25804
Orion Poplawski 6cf42fd
* Sun Jan 8 2017 Orion Poplawski <orion@cora.nwra.com> - 1.2.7-1
Orion Poplawski 6cf42fd
- Update to 1.2.7
Orion Poplawski 6cf42fd
Orion Poplawski 0f63f2a
* Wed Dec 21 2016 Orion Poplawski <orion@cora.nwra.com> - 1.2.6-2
Orion Poplawski 0f63f2a
- Add upstream patch for python 3.6 support
Orion Poplawski 0f63f2a
2d3e5ac
* Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 1.2.6-2
2d3e5ac
- Rebuild for Python 3.6
2d3e5ac
Orion Poplawski e4a3010
* Sun Dec 11 2016 Orion Poplawski <orion@cora.nwra.com> - 1.2.6-1
Orion Poplawski e4a3010
- Update to 1.2.6
Orion Poplawski e4a3010
Orion Poplawski 19477ac
* Tue Nov 29 2016 Orion Poplawski <orion@cora.nwra.com> - 1.2.5-1
Orion Poplawski 19477ac
- Update to 1.2.5
Orion Poplawski 19477ac
- Enable python 3 for EPEL
Orion Poplawski 19477ac
d0314ad
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.4-2
d0314ad
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
d0314ad
Orion Poplawski aad80f6
* Fri Apr 15 2016 Orion Poplawski <orion@cora.nwra.com> - 1.2.4-1
Orion Poplawski aad80f6
- Update to 1.2.4
Orion Poplawski aad80f6
- Add pthon2/3-netcdf4 provides
Orion Poplawski aad80f6
Orion Poplawski 49ac374
* Fri Mar 11 2016 Orion Poplawski <orion@cora.nwra.com> - 1.2.3-1
Orion Poplawski 49ac374
- Update to 1.2.3
Orion Poplawski 49ac374
- Drop numpy patch
Orion Poplawski 49ac374
- Use %%license
Orion Poplawski 49ac374
Orion Poplawski 1de811c
* Sun Feb 7 2016 Orion Poplawski <orion@cora.nwra.com> - 1.2.2-1
Orion Poplawski 1de811c
- Update to 1.2.2
Orion Poplawski 1de811c
- Modernize spec
Orion Poplawski 1de811c
- Add upstream patch for numpy support
Orion Poplawski 1de811c
df91fc5
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.6-5
df91fc5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
df91fc5
Orion Poplawski 1fa58e3
* Fri Jan 22 2016 Orion Poplawski <orion@cora.nwra.com> - 1.1.6-4
Orion Poplawski 1fa58e3
- Rebuild for netcdf 4.4.0
Orion Poplawski 1fa58e3
691ae7d
* Tue Nov 10 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.6-3
691ae7d
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
691ae7d
de50ec2
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.6-2
de50ec2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
de50ec2
Orion Poplawski 04cf85f
* Tue Mar 10 2015 Orion Poplawski <orion@cora.nwra.com> - 1.1.6-1
Orion Poplawski 04cf85f
- Update to 1.1.6
Orion Poplawski 04cf85f
Orion Poplawski f016c5b
* Sat Feb 21 2015 Orion Poplawski <orion@cora.nwra.com> - 1.1.4-1
Orion Poplawski f016c5b
- Update to 1.1.4
Orion Poplawski f016c5b
Orion Poplawski d37ae69
* Sun Dec 21 2014 Orion Poplawski <orion@cora.nwra.com> - 1.1.3-1
Orion Poplawski d37ae69
- Update to 1.1.3
Orion Poplawski d37ae69
1e4cccd
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.0-2
1e4cccd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
1e4cccd
9b13f86
* Wed Jul 9 2014 Orion Poplawski <orion@cora.nwra.com> - 1.1.0-1
9b13f86
- Update to 1.1.0
9b13f86
e464538
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.9-3
e464538
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
e464538
24f33a1
* Fri May 9 2014 Orion Poplawski <orion@cora.nwra.com> - 1.0.9-2
24f33a1
- Rebuild for Python 3.4
24f33a1
c039654
* Fri May 9 2014 Orion Poplawski <orion@cora.nwra.com> - 1.0.9-1
c039654
- Update to 1.0.9
c6ff814
- Remove rpaths
3e59383
- Add BR python{,3}-dateutil for tests
40e5c37
- Add BR/R on Cython
c039654
Orion Poplawski b5bc88b
* Thu Mar 6 2014 Orion Poplawski <orion@cora.nwra.com> - 1.0.8-1
Orion Poplawski b5bc88b
- Update to 1.0.8
Orion Poplawski b5bc88b
- Update URL/source to github
Orion Poplawski b5bc88b
Orion Poplawski dc1a9e3
* Thu Feb 6 2014 Orion Poplawski <orion@cora.nwra.com> - 1.0.7-1
Orion Poplawski dc1a9e3
- Update to 1.0.7
Orion Poplawski dc1a9e3
0fbf366
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.2-2
0fbf366
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
0fbf366
2f8e5fc
* Thu Feb 21 2013 Orion Poplawski <orion@cora.nwra.com> - 1.0.2-1
2f8e5fc
- Update to 1.0.2
2f8e5fc
- Remove bundled ordereddict (Bug #913528), require it on EL6
2f8e5fc
- Run tests
2f8e5fc
9b8c9a5
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0-3.fix1
9b8c9a5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
9b8c9a5
b7eed1f
* Wed Sep 12 2012 Orion Poplawski <orion@cora.nwra.com> - 1.0-2.fix1
b7eed1f
- Add patch to link only against netcdf
b7eed1f
5541250
* Thu May 24 2012 Orion Poplawski <orion@cora.nwra.com> - 1.0-1.fix1
5541250
- Update to 1.0fix1
5541250
5541250
* Thu Apr 5 2012 Orion Poplawski <orion@cora.nwra.com> - 0.9.9-1
5541250
- Update to 0.9.9
5541250
5541250
* Thu Sep 8 2011 Orion Poplawski <orion@cora.nwra.com> - 0.9.7-1
5541250
- Initial package