From edf3f0daa603bb2b17a84fb0a447f20f5f72af9d530944da25c94bf56b9f593b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Tue, 17 Jun 2025 09:24:31 +0000 Subject: [PATCH] - Convert to libalternatives OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-calmjs?expand=0&rev=26 --- python-calmjs.changes | 5 +++++ python-calmjs.spec | 12 +++++------- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/python-calmjs.changes b/python-calmjs.changes index c07a42f..9a1f222 100644 --- a/python-calmjs.changes +++ b/python-calmjs.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue Jun 17 09:24:11 UTC 2025 - Markéta Machová + +- Convert to libalternatives + ------------------------------------------------------------------- Mon Jan 27 16:46:53 UTC 2025 - Markéta Machová diff --git a/python-calmjs.spec b/python-calmjs.spec index 3f9e00e..cbc95be 100644 --- a/python-calmjs.spec +++ b/python-calmjs.spec @@ -16,6 +16,7 @@ # +%bcond_without libalternatives %{?sle15_python_module_pythons} Name: python-calmjs Version: 3.4.4 @@ -31,13 +32,13 @@ BuildRequires: %{python_module calmjs.types} BuildRequires: %{python_module pip} BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools} +BuildRequires: alts BuildRequires: fdupes BuildRequires: python-rpm-macros +Requires: alts Requires: python-calmjs.parse >= 1.0.0 Requires: python-calmjs.types Requires: python-setuptools -Requires(post): update-alternatives -Requires(postun): update-alternatives BuildArch: noarch # SECTION test requirements BuildRequires: nodejs-common @@ -74,11 +75,8 @@ export LANG=en_US.UTF-8 # DistLoggerTestCase is not working correctly in obs build environment %pytest -v --pyargs calmjs.tests -k 'not DistLoggerTestCase' -%post -%python_install_alternative calmjs - -%postun -%python_uninstall_alternative calmjs +%pre +%python_libalternatives_reset_alternative calmjs %files %{python_files} %license LICENSE