Blame SPECS/python-pint.spec

713c18
%global pypi_name Pint
713c18
%bcond_with docs
713c18
%bcond tests 0
713c18
713c18
Name:           python-pint
713c18
Version:        0.16.1
713c18
Release:        4%{?dist}
713c18
Summary:        Physical quantities module
713c18
713c18
License:        BSD
713c18
URL:            https://github.com/hgrecco/pint
713c18
Source0:        %pypi_source
713c18
713c18
BuildArch:      noarch
713c18
BuildRequires:  pyproject-rpm-macros
713c18
713c18
%description
713c18
Pint is Python module/package to define, operate and manipulate physical
713c18
quantities: the product of a numerical value and a unit of measurement.
713c18
It allows arithmetic operations between them and conversions from and
713c18
to different units.
713c18
713c18
It is distributed with a comprehensive list of physical units, prefixes
713c18
and constants.
713c18
713c18
%package -n python3-pint
713c18
Summary:        Physical quantities module
713c18
%{?python_provide:%python_provide python3-pint}
713c18
713c18
BuildRequires:  python3-numpy
713c18
BuildRequires:  python3-pytest
713c18
713c18
%description -n python3-pint
713c18
Pint is Python module/package to define, operate and manipulate physical
713c18
quantities: the product of a numerical value and a unit of measurement.
713c18
It allows arithmetic operations between them and conversions from and
713c18
to different units.
713c18
713c18
It is distributed with a comprehensive list of physical units, prefixes
713c18
and constants.
713c18
713c18
%if %{with docs}
713c18
%package -n python3-pint-doc
713c18
Summary:        Documentation for the pint module
713c18
%{?python_provide:%python_provide python3-pint-doc}
713c18
713c18
BuildRequires:  pandoc
713c18
BuildRequires:  python3-graphviz
713c18
BuildRequires:  python3-ipykernel
713c18
BuildRequires:  python3-jupyter-client
713c18
BuildRequires:  python3-matplotlib
713c18
BuildRequires:  python3-nbsphinx
713c18
BuildRequires:  python3-pandas
713c18
BuildRequires:  python3-dask
713c18
BuildRequires:  python3-pygments
713c18
BuildRequires:  python3-sphinx
713c18
BuildRequires:  python3-xarray
713c18
713c18
%description -n python3-pint-doc
713c18
Documentation for the pint module
713c18
%endif
713c18
713c18
%prep
713c18
%setup -q -n %{pypi_name}-%{version}
713c18
sed -i 's/, "setuptools_scm.*"//' pyproject.toml
713c18
713c18
# drop numpy version requirement
713c18
sed -i '/@helpers.requires_numpy_at_least("1.16")/d' pint/testsuite/test_quantity.py
713c18
713c18
%generate_buildrequires
713c18
%pyproject_buildrequires %{?with_docs:-x test}
713c18
713c18
%build
713c18
%pyproject_wheel
713c18
713c18
%if %{with docs}
713c18
export PYTHONPATH="$( pwd ):$PYTHONPATH"
713c18
sphinx-build-3 docs html
713c18
# remove the sphinx-build leftovers
713c18
713c18
rm -rf html/.{doctrees,buildinfo}
713c18
%endif
713c18
713c18
%install
713c18
%pyproject_install
713c18
713c18
%if %{with tests}
713c18
%check
713c18
%pytest
713c18
%endif
713c18
713c18
%files -n python3-pint
713c18
%license LICENSE
713c18
%{_bindir}/pint-convert
713c18
%{python3_sitelib}/pint
713c18
%{python3_sitelib}/Pint-%{version}.*
713c18
713c18
%if %{with docs}
713c18
%files -n python3-pint-doc
713c18
%doc html
713c18
%license docs/_themes/LICENSE
713c18
%endif
713c18
713c18
%changelog
713c18
* Fri Feb 14 2024 Joel Capitao <jcapitao@redhat.com> - 0.16.1-4
713c18
- Disable tests
713c18
713c18
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.16.1-3
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
713c18
713c18
* Sun Jan 24 2021 Matthias Runge <mrunge@redhat.com> - 0.16.1-2
713c18
- rebuild without bootstrap
713c18
- fix FTBFS (rhbz#1914333)
713c18
713c18
* Mon Sep 21 2020 Lumír Balhar <lbalhar@redhat.com> - 0.13-3
713c18
- Fix test dependencies and execution
713c18
713c18
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.13-2
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
713c18
713c18
* Tue Jun 23 2020 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 0.13-1
713c18
- Update to 0.13
713c18
713c18
* Tue May 26 2020 Miro Hrončok <mhroncok@redhat.com> - 0.10.1-3
713c18
- Rebuilt for Python 3.9
713c18
713c18
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.10.1-2
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
713c18
713c18
* Thu Jan 09 2020 Matthias Runge <mrunge@redhat.com> - 0.10.1-1
713c18
- update to 0.10.1 (rhbz#1789066)
713c18
- modernize specfile
713c18
713c18
* Thu Sep 05 2019 Matthias Runge <mrunge@redhat.com> - 0.9-5
713c18
- skip test_quantity for now (rhbz#1706212)
713c18
713c18
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 0.9-5
713c18
- Rebuilt for Python 3.8
713c18
713c18
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.9-4
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
713c18
713c18
* Wed Jul 10 2019 Matthias Runge <mrunge@redhat.com> - 0.9-3
713c18
- Use context manager for assertWarns and fix DeprecationWarning
713c18
  resolves: rhbz#1706212
713c18
713c18
* Sun Mar 17 2019 Miro Hrončok <mhroncok@redhat.com> - 0.9-2
713c18
- Subpackages python2-pint, python2-pint-doc have been removed
713c18
  See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
713c18
713c18
* Mon Feb 25 2019 Yatin Karel <ykarel@redhat.com> - 0.9-1
713c18
- Update to 0.9
713c18
713c18
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.6-16
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
713c18
713c18
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.6-15
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
713c18
713c18
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 0.6-14
713c18
- Rebuilt for Python 3.7
713c18
713c18
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.6-13
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
713c18
713c18
* Sat Jan 27 2018 Iryna Shcherbina <ishcherb@redhat.com> - 0.6-12
713c18
- Update Python 2 dependency declarations to new packaging standards
713c18
  (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
713c18
713c18
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.6-11
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
713c18
713c18
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.6-10
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
713c18
713c18
* Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 0.6-9
713c18
- Rebuild for Python 3.6
713c18
713c18
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6-8
713c18
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
713c18
713c18
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.6-7
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
713c18
713c18
* Tue Nov 10 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6-6
713c18
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
713c18
713c18
* Sun Sep 06 2015 Matthias Runge <mrunge@redhat.com> - 0.6-5
713c18
- fix uppercase/lowercase naming, fix obsoletes
713c18
713c18
* Fri Sep 04 2015 Chandan Kumar <chkumar246@gmail.com> - 0.6-4
713c18
- Add python2 and python3 subpackages
713c18
713c18
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6-3
713c18
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
713c18
713c18
* Mon Dec 15 2014 Matthias Runge <mrunge@redhat.com> - 0.6-2
713c18
- change BR python-devel to python2-devel (rhbz#1173109)
713c18
713c18
* Thu Dec 11 2014 Matthias Runge <mrunge@redhat.com> - 0.6-1
713c18
- Initial package.