From 9ea85877e420af7ecb7d7b278755d2e55333f8af11d68c6441af0382e030b72c Mon Sep 17 00:00:00 2001 From: Nico Krapp Date: Mon, 12 May 2025 16:03:33 +0000 Subject: [PATCH] Accepting request 1276915 from home:mcalabkova:branches:devel:languages:python - Convert to pip-based build OBS-URL: https://build.opensuse.org/request/show/1276915 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-PyTrie?expand=0&rev=14 --- python-PyTrie.changes | 5 +++++ python-PyTrie.spec | 20 +++++++++++--------- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/python-PyTrie.changes b/python-PyTrie.changes index 9a27561..75c1e68 100644 --- a/python-PyTrie.changes +++ b/python-PyTrie.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon May 12 14:28:35 UTC 2025 - Markéta Machová + +- Convert to pip-based build + ------------------------------------------------------------------- Wed Nov 11 01:51:53 UTC 2020 - Steve Kowalik diff --git a/python-PyTrie.spec b/python-PyTrie.spec index e72402c..27c2836 100644 --- a/python-PyTrie.spec +++ b/python-PyTrie.spec @@ -1,7 +1,7 @@ # # spec file for package python-PyTrie # -# Copyright (c) 2020 SUSE LLC +# Copyright (c) 2025 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,8 +16,6 @@ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} -%define skip_python2 1 Name: python-PyTrie Version: 0.4.0 Release: 0 @@ -25,14 +23,16 @@ Summary: A pure Python implementation of the trie data structure License: BSD-3-Clause URL: https://github.com/gsakkis/pytrie/ Source: https://files.pythonhosted.org/packages/source/P/PyTrie/PyTrie-%{version}.tar.gz +BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools} BuildRequires: %{python_module sortedcontainers} BuildRequires: %{python_module testsuite} +BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-sortedcontainers -Provides: python-pytrie -Obsoletes: python-pytrie +Provides: python-pytrie = %{version} +Obsoletes: python-pytrie < %{version} BuildArch: noarch %python_subpackages @@ -49,18 +49,20 @@ prefix, and vice versa, finding the items whose keys are prefixes of a given key %autopatch -p1 %build -%python_build +%pyproject_wheel %install -%python_install +%pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} %check -%python_expand PYTHONPATH=%{buildroot}%{$python_sitelib} $python -m unittest discover +%pyunittest %files %{python_files} %license LICENSE %doc README.md -%{python_sitelib}/* +%{python_sitelib}/pytrie.py +%{python_sitelib}/[Pp]y[Tt]rie-%{version}*-info +%pycache_only %{python_sitelib}/__pycache__/pytrie* %changelog