From 6da67a583b39387a3b86e7260f9323686810d0fa0f7a3d4a0c18d4353a387746 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Mon, 9 Jun 2025 12:43:05 +0000 Subject: [PATCH] - Convert to libalternatives OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-nwdiag?expand=0&rev=18 --- python-nwdiag.changes | 5 +++++ python-nwdiag.spec | 18 +++++++----------- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/python-nwdiag.changes b/python-nwdiag.changes index 1cab1e6..bc4940b 100644 --- a/python-nwdiag.changes +++ b/python-nwdiag.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Jun 9 12:42:25 UTC 2025 - Markéta Machová + +- Convert to libalternatives + ------------------------------------------------------------------- Mon Jun 2 14:49:06 UTC 2025 - Markéta Machová diff --git a/python-nwdiag.spec b/python-nwdiag.spec index e7c9983..88c24f9 100644 --- a/python-nwdiag.spec +++ b/python-nwdiag.spec @@ -16,6 +16,7 @@ # +%bcond_without libalternatives Name: python-nwdiag Version: 3.0.0 Release: 0 @@ -27,12 +28,12 @@ Source: https://files.pythonhosted.org/packages/source/n/nwdiag/nwdiag-% BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools} BuildRequires: %{python_module wheel} +BuildRequires: alts BuildRequires: fdupes BuildRequires: python-rpm-macros +Requires: alts Requires: python-blockdiag >= 1.5.0 Requires: python-setuptools -Requires(post): alts -Requires(postun): alts Suggests: python-docutils Suggests: python-nose Suggests: python-reportlab @@ -55,15 +56,10 @@ nwdiag generates network diagram images from text. %python_clone -a %{buildroot}%{_bindir}/nwdiag %python_expand %fdupes %{buildroot}%{$python_sitelib} -%post -%python_install_alternative packetdiag -%python_install_alternative rackdiag -%python_install_alternative nwdiag - -%postun -%python_uninstall_alternative packetdiag -%python_uninstall_alternative rackdiag -%python_uninstall_alternative nwdiag +%pre +%python_libalternatives_reset_alternative packetdiag +%python_libalternatives_reset_alternative rackdiag +%python_libalternatives_reset_alternative nwdiag %files %{python_files} %doc README.rst