diff --git a/python-ansi2html.spec b/python-ansi2html.spec
index 50c5f01c8b..dd479194cd 100644
--- a/python-ansi2html.spec
+++ b/python-ansi2html.spec
@@ -13,7 +13,7 @@
Name: python-ansi2html
Version: 1.2.0
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Python module that converts text with ANSI color to HTML
Group: Development/Libraries
@@ -39,27 +39,35 @@ BuildRequires: python3-six
%if %{?rhel}%{!?rhel:0} >= 6
BuildRequires: python-ordereddict
-Requires: python-ordereddict
%endif
+%global _description\
+The ansi2html module can convert text with ANSI color codes to HTML.
+
+%description %_description
+
+%package -n python2-ansi2html
+Summary: %summary
+%if %{?rhel}%{!?rhel:0} >= 6
+Requires: python-ordereddict
+%endif
Requires: python
Requires: python-setuptools
Requires: python-six
+%{?python_provide:%python_provide python2-ansi2html}
-%description
-The ansi2html module can convert text with ANSI color codes to HTML.
+%description -n python2-ansi2html %_description
%if 0%{?with_python3}
%package -n python3-ansi2html
-Summary: Python 3 module that converts text with ANSI color to HTML
-Group: Development/Libraries
+Summary: %summary
Requires: python3
Requires: python3-setuptools
Requires: python3-six
+%{?python_provide:%python_provide python3-ansi2html}
-%description -n python3-ansi2html
-The ansi2html module can convert text with ANSI color codes to HTML.
+%description -n python3-ansi2html %_description
%endif
@@ -109,7 +117,7 @@ mkdir -p %{buildroot}/%{_mandir}/man1/
mv man/ansi2html.1 %{buildroot}/%{_mandir}/man1/ansi2html.1
-%files
+%files -n python2-ansi2html
%doc LICENSE README.rst
%{python2_sitelib}/ansi2html
%{python2_sitelib}/ansi2html-%{version}-*
@@ -127,6 +135,10 @@ mv man/ansi2html.1 %{buildroot}/%{_mandir}/man1/ansi2html.1
%changelog
+* Wed Aug 09 2017 Zbigniew Jędrzejewski-Szmek - 1.2.0-3
+- Python 2 binary package renamed to python2-ansi2html
+ See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3
+
* Thu Jul 27 2017 Fedora Release Engineering - 1.2.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild