forked from pool/python-html2text
- fix usage of libalternatives
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-html2text?expand=0&rev=45
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Jun 4 13:09:18 UTC 2025 - Nico Krapp <nico.krapp@suse.com>
|
||||
|
||||
- fix usage of libalternatives
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue May 27 16:19:15 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
#
|
||||
|
||||
|
||||
%bcond_without libalternatives
|
||||
%define upname html2text
|
||||
%{?sle15_python_module_pythons}
|
||||
Name: python-%{upname}
|
||||
@@ -30,10 +31,10 @@ BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module pytest}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: alts
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
Requires(post): alts
|
||||
Requires(preun): alts
|
||||
Requires: alts
|
||||
Provides: html2text = %{version}-%{release}
|
||||
Obsoletes: html2text < %{version}-%{release}
|
||||
BuildArch: noarch
|
||||
@@ -60,11 +61,11 @@ rm -r *.egg-info/
|
||||
|
||||
%python_clone -a %{buildroot}%{_bindir}/%{upname}
|
||||
|
||||
%post
|
||||
%python_install_alternative html2text
|
||||
%pre
|
||||
# Removing old update-alternatives entries.
|
||||
%python_libalternatives_reset_alternative <package-name>
|
||||
|
||||
%postun
|
||||
%python_uninstall_alternative html2text
|
||||
# post and postun macro call is not needed with only libalternatives
|
||||
|
||||
%check
|
||||
%pytest
|
||||
|
||||
Reference in New Issue
Block a user