Blame SPECS/python-mimeparse.spec

0ab677
# what it's called on pypi
0ab677
%global srcname python-mimeparse
0ab677
# what it's imported as
0ab677
%global libname mimeparse
0ab677
# name of egg info directory
0ab677
%global eggname python_mimeparse
0ab677
# package name fragment
0ab677
%global pkgname mimeparse
0ab677
0ab677
%global common_description %{expand:
0ab677
This module provides basic functions for parsing mime-type names
0ab677
and matching them against a list of media-ranges.}
0ab677
0ab677
%if (%{defined fedora} && 0%{?fedora} < 32) || (%{defined rhel} && 0%{?rhel} < 8)
0ab677
%bcond_without  python2
0ab677
%endif
0ab677
0ab677
0ab677
Name:           python-%{pkgname}
0ab677
Version:        1.6.0
0ab677
Release:        16%{?dist}
0ab677
Summary:        Python module for parsing mime-type names
0ab677
License:        MIT
0ab677
URL:            https://github.com/dbtsai/python-mimeparse
0ab677
Source0:        %pypi_source
0ab677
BuildArch:      noarch
0ab677
0ab677
0ab677
%description %{common_description}
0ab677
0ab677
0ab677
%if %{with python2}
0ab677
%package -n python2-%{pkgname}
0ab677
Summary:        %{summary}
0ab677
BuildRequires:  python2-devel
0ab677
BuildRequires:  python2-setuptools
0ab677
%{?python_provide:%python_provide python2-%{pkgname}}
0ab677
0ab677
0ab677
%description -n python2-%{pkgname} %{common_description}
0ab677
%endif
0ab677
0ab677
0ab677
%package -n python3-%{pkgname}
0ab677
Summary:        %{summary}
0ab677
BuildRequires:  python3-devel
0ab677
BuildRequires:  python3-setuptools
0ab677
%{?python_provide:%python_provide python3-%{pkgname}}
0ab677
0ab677
0ab677
%description -n python3-%{pkgname} %{common_description}
0ab677
0ab677
0ab677
%prep
0ab677
%setup -q -n %{srcname}-%{version}
0ab677
rm -rf %{eggname}.egg-info
0ab677
0ab677
0ab677
%build
0ab677
%if %{with python2}
0ab677
%py2_build
0ab677
%endif
0ab677
%py3_build
0ab677
0ab677
0ab677
%install
0ab677
%if %{with python2}
0ab677
%py2_install
0ab677
%endif
0ab677
%py3_install
0ab677
0ab677
0ab677
%check
0ab677
%if %{with python2}
0ab677
PYTHONPATH=%{buildroot}%{python2_sitelib} %{__python2} mimeparse_test.py --verbose
0ab677
%endif
0ab677
PYTHONPATH=%{buildroot}%{python3_sitelib} %{__python3} mimeparse_test.py --verbose
0ab677
0ab677
0ab677
%if %{with python2}
0ab677
%files -n python2-%{pkgname}
0ab677
%license LICENSE
0ab677
%doc README.rst
0ab677
%{python2_sitelib}/%{libname}.py*
0ab677
%{python2_sitelib}/%{eggname}-%{version}-py%{python2_version}.egg-info
0ab677
%endif
0ab677
0ab677
0ab677
%files -n python3-%{pkgname}
0ab677
%license LICENSE
0ab677
%doc README.rst
0ab677
%{python3_sitelib}/%{libname}.py
0ab677
%{python3_sitelib}/__pycache__/%{libname}.cpython-%{python3_version_nodots}*.py*
0ab677
%{python3_sitelib}/%{eggname}-%{version}-py%{python3_version}.egg-info
0ab677
0ab677
0ab677
%changelog
0ab677
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.0-16
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
0ab677
0ab677
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.0-15
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
0ab677
0ab677
* Fri May 22 2020 Miro Hrončok <mhroncok@redhat.com> - 1.6.0-14
0ab677
- Rebuilt for Python 3.9
0ab677
0ab677
* Fri Apr 10 2020 Carl George <carl@george.computer> - 1.6.0-13
0ab677
- Run tests with files from buildroot instead of builddir
0ab677
0ab677
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.0-12
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
0ab677
0ab677
* Sat Oct 05 2019 Carl George <carl@george.computer> - 1.6.0-11
0ab677
- Disable python2 subpackage on F32+ and EL8+ rhbz#1757447
0ab677
0ab677
* Wed Aug 14 2019 Miro Hrončok <mhroncok@redhat.com> - 1.6.0-10
0ab677
- Rebuilt for Python 3.8
0ab677
0ab677
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.0-9
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
0ab677
0ab677
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.0-8
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
0ab677
0ab677
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.0-7
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
0ab677
0ab677
* Thu Jun 14 2018 Miro Hrončok <mhroncok@redhat.com> - 1.6.0-6
0ab677
- Rebuilt for Python 3.7
0ab677
0ab677
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.0-5
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
0ab677
0ab677
* Thu Sep 07 2017 Carl George <carl@george.computer> - 1.6.0-4
0ab677
- Enable python34 subpackage for EPEL
0ab677
0ab677
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.0-3
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
0ab677
0ab677
* Thu May 04 2017 Carl George <carl.george@rackspace.com> - 1.6.0-2
0ab677
- Spec file clean up
0ab677
0ab677
* Tue Feb 28 2017 Carl George <carl.george@rackspace.com> - 1.6.0-1
0ab677
- New upstream https://github.com/dbtsai/python-mimeparse
0ab677
- Modernize spec file per Python Packaging Guidelines
0ab677
0ab677
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.4-11
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
0ab677
0ab677
* Fri Dec 09 2016 Charalampos Stratakis <cstratak@redhat.com> - 0.1.4-10
0ab677
- Rebuild for Python 3.6
0ab677
0ab677
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.4-9
0ab677
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
0ab677
0ab677
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.4-8
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
0ab677
0ab677
* Tue Nov 10 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.4-7
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
0ab677
0ab677
* Wed Sep 02 2015 Jan Kaluza <jkaluza@redhat.com> - 0.1.4-6
0ab677
- provide python2-mimeparse (#1241680)
0ab677
0ab677
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.4-5
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
0ab677
0ab677
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.4-4
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
0ab677
0ab677
* Wed May 14 2014 Bohuslav Kabrda <bkabrda@redhat.com> - 0.1.4-3
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Changes/Python_3.4
0ab677
0ab677
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.4-2
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
0ab677
0ab677
* Sat May 18 2013 Pádraig Brady <P@draigBrady.com> - 0.1.4-1
0ab677
- Update to release 0.1.4
0ab677
0ab677
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.3-5
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
0ab677
0ab677
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.3-4
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
0ab677
0ab677
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.3-3
0ab677
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
0ab677
0ab677
* Tue Nov 22 2011 Jan Kaluza <jkaluza@redhat.com> - 0.1.3-2
0ab677
- python3 support disabled
0ab677
- removed useless spec file directives
0ab677
- run upstream test
0ab677
0ab677
* Wed Nov 02 2011 Jan Kaluza <jkaluza@redhat.com> - 0.1.3-1
0ab677
- Initial version