From a11cb9d8f50f6846581446541996dfa81497e773496f8af60738df9fb1c9f184 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Tue, 27 May 2025 14:08:30 +0000 Subject: [PATCH 1/3] - Convert to pip-based build OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-gps3?expand=0&rev=3 --- python-gps3.changes | 5 +++++ python-gps3.spec | 24 ++++++++++++++---------- 2 files changed, 19 insertions(+), 10 deletions(-) diff --git a/python-gps3.changes b/python-gps3.changes index 835221e..ba35787 100644 --- a/python-gps3.changes +++ b/python-gps3.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue May 27 14:07:46 UTC 2025 - Markéta Machová + +- Convert to pip-based build + ------------------------------------------------------------------- Sun Nov 10 09:01:21 UTC 2019 - Martin Hauke diff --git a/python-gps3.spec b/python-gps3.spec index 920caa7..129a93a 100644 --- a/python-gps3.spec +++ b/python-gps3.spec @@ -1,6 +1,7 @@ # # spec file for package python-gps3 # +# Copyright (c) 2025 SUSE LLC # Copyright (c) 2019, Martin Hauke # # All modifications and additions to the file contributed by third parties @@ -12,21 +13,23 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# -%{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-gps3 Version: 0.33.3+git.20171101 Release: 0 -License: MIT Summary: Python interface for gpsd -Url: https://github.com/wadda/gps3 +License: MIT Group: Development/Languages/Python +URL: https://github.com/wadda/gps3 Source: gps3-%{version}.tar.xz -BuildRequires: python-rpm-macros +BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module wheel} BuildRequires: fdupes +BuildRequires: python-rpm-macros BuildArch: noarch %python_subpackages @@ -36,17 +39,17 @@ Python interface for gpsd. %prep %setup -q -n gps3-%{version} # don't use env -find . -name "*.py" -exec sed -i 's|#!/usr/bin/env python3.5|#!/usr/bin/python3|g' {} \; -find . -name "*.py" -exec sed -i 's|#!/usr/bin/env python3|#!/usr/bin/python3|g' {} \; +find . -name "*.py" -exec sed -i 's|#!%{_bindir}/env python3.5|#!%{_bindir}/python3|g' {} \; +find . -name "*.py" -exec sed -i 's|#!%{_bindir}/env python3|#!%{_bindir}/python3|g' {} \; # drop shebang find gps3/ -name "*.py" -exec sed -i -e '/^#!\//, 1d' {} \; find examples/ -name "*.py" -exec sed -i -e '/^#!\//, 1d' {} \; %build -%python_build +%pyproject_wheel %install -%python_install +%pyproject_install # remove examples rm -rf %{buildroot}%{_datadir}/gps3 %python_expand %fdupes %{buildroot}%{$python_sitelib} @@ -55,6 +58,7 @@ rm -rf %{buildroot}%{_datadir}/gps3 %license LICENSE %doc DESCRIPTION.rst README.md %doc examples/ -%{python_sitelib}/* +%{python_sitelib}/gps3 +%{python_sitelib}/gps3-%{version}*-info %changelog From 60be6cdc88c77cfe7697075ec16e9e24c5550222d0574583a3dbb8fde9e91a6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Tue, 27 May 2025 14:10:12 +0000 Subject: [PATCH 2/3] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-gps3?expand=0&rev=4 --- python-gps3.spec | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/python-gps3.spec b/python-gps3.spec index 129a93a..ecd507f 100644 --- a/python-gps3.spec +++ b/python-gps3.spec @@ -17,6 +17,7 @@ # +%define pkg_version 0.33.3 Name: python-gps3 Version: 0.33.3+git.20171101 Release: 0 @@ -59,6 +60,6 @@ rm -rf %{buildroot}%{_datadir}/gps3 %doc DESCRIPTION.rst README.md %doc examples/ %{python_sitelib}/gps3 -%{python_sitelib}/gps3-%{version}*-info +%{python_sitelib}/gps3-%{pkg_version}*-info %changelog From 3e5d28b169f80bb5c401a181aeb0d0c4d9b8827911f665d38f736219a09f48f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Tue, 27 May 2025 14:20:41 +0000 Subject: [PATCH 3/3] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-gps3?expand=0&rev=5 --- python-gps3.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python-gps3.spec b/python-gps3.spec index ecd507f..dd8e615 100644 --- a/python-gps3.spec +++ b/python-gps3.spec @@ -17,7 +17,7 @@ # -%define pkg_version 0.33.3 +%define pkg_version 0.33.0 Name: python-gps3 Version: 0.33.3+git.20171101 Release: 0