From 621de62edc7366f88e8861dd085f30967a135752c8472d6abef8f47debd81dbe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Mon, 9 Jun 2025 14:38:22 +0000 Subject: [PATCH] - Convert to libalternatives OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pdd?expand=0&rev=16 --- python-pdd.changes | 5 +++++ python-pdd.spec | 12 +++++------- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/python-pdd.changes b/python-pdd.changes index 17b6076..de0ff3b 100644 --- a/python-pdd.changes +++ b/python-pdd.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Jun 9 14:37:32 UTC 2025 - Markéta Machová + +- Convert to libalternatives + ------------------------------------------------------------------- Tue Jun 3 09:20:47 UTC 2025 - Markéta Machová diff --git a/python-pdd.spec b/python-pdd.spec index ea46dab..503bbe1 100644 --- a/python-pdd.spec +++ b/python-pdd.spec @@ -16,6 +16,7 @@ # +%bcond_without libalternatives # pdd is not available for Python 2 Name: python-pdd Version: 1.7 @@ -29,12 +30,12 @@ BuildRequires: %{python_module devel} BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools} BuildRequires: %{python_module wheel} +BuildRequires: alts BuildRequires: fdupes BuildRequires: python-rpm-macros +Requires: alts Requires: python-python-dateutil Requires: python-setuptools -Requires(post): alts -Requires(postun): alts BuildArch: noarch # SECTION test requirements BuildRequires: %{python_module pytest} @@ -63,11 +64,8 @@ mv pdd.py pdd chmod 755 pdd %pytest test.py -%post -%python_install_alternative pdd - -%postun -%python_uninstall_alternative pdd +%pre +%python_libalternatives_reset_alternative pdd %files %{python_files} %doc README.md CHANGELOG