From f3a2ca8177e2f0635566fcdc60139a0960b7832442dc15adcc936123cf0bd7a7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Fri, 27 Jun 2025 15:07:51 +0000 Subject: [PATCH] - Convert to libalternatives OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-checkdmarc?expand=0&rev=17 --- python-checkdmarc.changes | 5 +++++ python-checkdmarc.spec | 12 +++++------- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/python-checkdmarc.changes b/python-checkdmarc.changes index dab0eae..87486ff 100644 --- a/python-checkdmarc.changes +++ b/python-checkdmarc.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Fri Jun 27 15:07:33 UTC 2025 - Markéta Machová + +- Convert to libalternatives + ------------------------------------------------------------------- Wed Jun 18 11:26:03 UTC 2025 - Martin Hauke diff --git a/python-checkdmarc.spec b/python-checkdmarc.spec index 64c52d1..e85331f 100644 --- a/python-checkdmarc.spec +++ b/python-checkdmarc.spec @@ -17,6 +17,7 @@ # +%bcond_without libalternatives %{?sle15_python_module_pythons} Name: python-checkdmarc Version: 5.8.6 @@ -30,8 +31,10 @@ BuildRequires: %{python_module hatchling} BuildRequires: %{python_module importlib_resources >= 6.0} BuildRequires: %{python_module pip} BuildRequires: %{python_module wheel} +BuildRequires: alts BuildRequires: fdupes BuildRequires: python-rpm-macros +Requires: alts Requires: python-cryptography Requires: python-dnspython >= 2.0.0 Requires: python-expiringdict >= 1.1.4 @@ -42,8 +45,6 @@ Requires: python-pyleri >= 1.3.2 Requires: python-requests >= 2.25.0 Requires: python-timeout-decorator >= 0.4.1 Requires: python-xmltodict -Requires(post): update-alternatives -Requires(postun): update-alternatives BuildArch: noarch # SECTION test requirements BuildRequires: %{python_module dnspython >= 2.0.0} @@ -73,11 +74,8 @@ A Python module and command line parser for SPF and DMARC records. %python_clone -a %{buildroot}%{_bindir}/checkdmarc %python_expand %fdupes %{buildroot}%{$python_sitelib} -%post -%python_install_alternative checkdmarc - -%postun -%python_uninstall_alternative checkdmarc +%pre +%python_libalternatives_reset_alternative checkdmarc %check %pyunittest -v tests.py