Blob Blame History Raw
%global pypi_name sphinx-notfound-page
%global srcname sphinx_notfound_page
%global importname notfound
%global project_owner readthedocs
%global github_name sphinx-notfound-page
%global desc Create a custom 404 page with absolute URLs hardcoded

%if 0%{?fedora} > 30 || 0%{?rhel} > 7
%bcond_with python2
%bcond_without python2

Name:           python-%{pypi_name}
Version:        0.4
Release:        6%{?dist}
Summary:        Create a custom 404 page with absolute URLs hardcoded

License:        MIT
URL:  {pypi_name}

BuildArch:      noarch


%if %{with python2}
%package -n python2-%{pypi_name}
Summary:        %{summary}
BuildRequires:  python2-devel
BuildRequires:  python2-setuptools
BuildRequires:  python2-sphinx
BuildRequires:  python2-pytest
Requires:       python2-setuptools
Requires:       python2-sphinx
%{?python_provide:%python_provide python2-%{pypi_name}}

%description -n python2-%{pypi_name}

%package -n     python%{python3_pkgversion}-%{pypi_name}
Summary:        %{summary}
BuildArch:      noarch
BuildRequires:  python%{python3_pkgversion}-devel
BuildRequires:  python%{python3_pkgversion}-setuptools
BuildRequires:  python%{python3_pkgversion}-sphinx
BuildRequires:  python3-pytest
Requires(post): %{_sbindir}/update-alternatives
Requires(postun): %{_sbindir}/update-alternatives
Requires:       python%{python3_pkgversion}-setuptools
Requires:       python%{python3_pkgversion}-sphinx
%{?python_provide:%python_provide python%{python3_pkgversion}-%{pypi_name}}

%description -n python%{python3_pkgversion}-%{pypi_name}

%autosetup -n %{pypi_name}-%{version} -p1

%if %{with python2}

%if %{with python2}


%if %{with python2}
PYTHONPATH="$(pwd)" py.test-%{python2_version} -v .
PYTHONPATH="$(pwd)" py.test-%{python3_version} -v .

%if %{with python2}
%files -n python2-%{pypi_name}
%license LICENSE
%doc README.rst CHANGELOG.rst docs

%files -n python%{python3_pkgversion}-%{pypi_name}
%license LICENSE
%doc README.rst CHANGELOG.rst docs

* Thu Jan 30 2020 Fedora Release Engineering <> - 0.4-6
- Rebuilt for

* Thu Oct 03 2019 Miro Hrončok <> - 0.4-5
- Rebuilt for Python 3.8.0rc1 (#1748018)

* Mon Aug 19 2019 Miro Hrončok <> - 0.4-4
- Rebuilt for Python 3.8

* Fri Jul 26 2019 Fedora Release Engineering <> - 0.4-3
- Rebuilt for

* Sat Jul 13 2019 Kevin Fenzi <> - 0.4-2
- Use bcond for python2 support.

* Wed Jul 03 2019 Kevin Fenzi <> - 0.4-1
- Initial version for Fedora.