forked from pool/python-waitress
Accepting request 929842 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/929842 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-waitress?expand=0&rev=23
This commit is contained in:
commit
7f05dca947
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Fri Aug 27 12:27:31 UTC 2021 - Stefan Schubert <schubi@suse.de>
|
||||
|
||||
- Use libalternatives instead of update-alternatives.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Aug 27 11:27:31 UTC 2021 - pgajdos@suse.com
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# spec file
|
||||
# spec file for package python-waitress
|
||||
#
|
||||
# Copyright (c) 2021 SUSE LLC
|
||||
#
|
||||
@ -16,6 +16,12 @@
|
||||
#
|
||||
|
||||
|
||||
%if 0%{?suse_version} > 1500
|
||||
%bcond_without libalternatives
|
||||
%else
|
||||
%bcond_with libalternatives
|
||||
%endif
|
||||
|
||||
%global flavor @BUILD_FLAVOR@%{nil}
|
||||
|
||||
%if "%{flavor}" == "doc"
|
||||
@ -39,13 +45,18 @@ Source: https://files.pythonhosted.org/packages/source/w/waitress/waitre
|
||||
Source1: python3.inv
|
||||
Source2: fetch-intersphinx-inventories.sh
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
BuildRequires: python-rpm-macros >= 20210929
|
||||
%if "%{flavor}" == ""
|
||||
BuildRequires: %{python_module pytest-cov}
|
||||
BuildRequires: %{python_module pytest}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
%if %{with libalternatives}
|
||||
Requires: alts
|
||||
BuildRequires: alts
|
||||
%else
|
||||
Requires(post): update-alternatives
|
||||
Requires(postun):update-alternatives
|
||||
%endif
|
||||
%else
|
||||
# Documentation requirements
|
||||
BuildRequires: python3-Sphinx
|
||||
@ -81,6 +92,10 @@ http://docs.pylonsproject.org/projects/waitress/en/latest/ .
|
||||
# disable one test, that requires network
|
||||
%pytest -k 'not test_service_port'
|
||||
|
||||
%pre
|
||||
# If libalternatives is used: Removing old update-alternatives entries.
|
||||
%python_libalternatives_reset_alternative waitress-serve
|
||||
|
||||
%post
|
||||
%python_install_alternative waitress-serve
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user