diff --git a/python-fedora.spec b/python-fedora.spec index 98881b7..7738e11 100644 --- a/python-fedora.spec +++ b/python-fedora.spec @@ -1,4 +1,4 @@ -%if 0%{?fedora} +%if 0%{?fedora} || 0%{?rhel} >= 8 %global with_python3 1 %global py3dir ../python3 %else @@ -43,7 +43,7 @@ BuildRequires: python-sphinx %endif %endif -%if (0%{?fedora} && (0%{?fedora} <= 30)) || (0%{?rhel} >= 7) +%if (0%{?fedora} && (0%{?fedora} <= 30)) || (0%{?rhel} == 7) BuildRequires: python-cherrypy2 %endif %endif @@ -238,7 +238,7 @@ popd %endif pushd python2 -%if (0%{?rhel} != 6) && (0%{?fedora} < 31) +%if (0%{?rhel} < 8) && (0%{?fedora} < 31) ## No docs. Sphinx 2 in Fedora 31+ doesn't support Python 2 %{__python2} setup_docs.py build_sphinx %endif @@ -270,7 +270,7 @@ pushd python2 DESTDIR=%{buildroot} %{__python3} releaseutils.py install_catalogs # Cleanup doc -%if (0%{?rhel} != 6) && (0%{?fedora} < 31) +%if (0%{?rhel} < 8) && (0%{?fedora} < 31) mv build/sphinx/html doc/ if test -e doc/html/.buildinfo ; then rm doc/html/.buildinfo @@ -290,7 +290,7 @@ popd %files -f python2/%{name}.lang -n python2-fedora %license python2/COPYING %doc python2/NEWS python2/README.rst python2/AUTHORS -%if (0%{?rhel} != 6) && (0%{?fedora} < 31) +%if (0%{?rhel} < 8) && (0%{?fedora} < 31) %doc python2/doc %endif %{python2_sitelib}/fedora/ @@ -305,7 +305,7 @@ popd %files -f python3/%{name}.lang -n python3-fedora %license python3/COPYING %doc python2/NEWS python2/README.rst python2/AUTHORS -%if (0%{?rhel} != 6) && (0%{?fedora} < 31) +%if (0%{?rhel} < 8) && (0%{?fedora} < 31) %doc python2/doc %endif %{python3_sitelib}/fedora/