From dc0401b39bd96ed75a31b204522dae8a5b5165c8d102f3de3a98c751cc23fbdb Mon Sep 17 00:00:00 2001 From: Jiri Slaby Date: Thu, 27 Jul 2023 06:42:10 +0000 Subject: [PATCH 1/3] add py 3.9 prereq OBS-URL: https://build.opensuse.org/package/show/devel:tools/b4?expand=0&rev=87 --- b4.changes | 5 +++++ b4.spec | 1 + 2 files changed, 6 insertions(+) diff --git a/b4.changes b/b4.changes index 6e68ce7..7b31ebe 100644 --- a/b4.changes +++ b/b4.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Jul 27 06:41:39 UTC 2023 - Jiri Slaby + +- add python3-base >= 3.9 to BuildRequires for 15.5 and older + ------------------------------------------------------------------- Mon Jun 26 05:20:06 UTC 2023 - Jiri Slaby diff --git a/b4.spec b/b4.spec index 83ffde1..7bc17c4 100644 --- a/b4.spec +++ b/b4.spec @@ -28,6 +28,7 @@ BuildRequires: fdupes BuildRequires: git-core BuildRequires: git-filter-repo >= 2.30 BuildRequires: python-rpm-macros +BuildRequires: python3-base >= 3.9 BuildRequires: python3-dkimpy >= 1.0.5 BuildRequires: python3-dnspython >= 2.0.0 BuildRequires: python3-patatt >= 0.5 From 221d855d023764227e49837cf83ff8a5ab54804066a487dc3a64a0ff2ee7a952 Mon Sep 17 00:00:00 2001 From: Jiri Slaby Date: Thu, 27 Jul 2023 07:01:29 +0000 Subject: [PATCH 2/3] add py 3.9 prereq OBS-URL: https://build.opensuse.org/package/show/devel:tools/b4?expand=0&rev=88 --- b4.changes | 1 + b4.spec | 1 + 2 files changed, 2 insertions(+) diff --git a/b4.changes b/b4.changes index 7b31ebe..2b297e7 100644 --- a/b4.changes +++ b/b4.changes @@ -2,6 +2,7 @@ Thu Jul 27 06:41:39 UTC 2023 - Jiri Slaby - add python3-base >= 3.9 to BuildRequires for 15.5 and older +- add %{?sle15_python_module_pythons} too ------------------------------------------------------------------- Mon Jun 26 05:20:06 UTC 2023 - Jiri Slaby diff --git a/b4.spec b/b4.spec index 7bc17c4..47ddbee 100644 --- a/b4.spec +++ b/b4.spec @@ -16,6 +16,7 @@ # +%{?sle15_python_module_pythons} Name: b4 Version: 0.12.3 Release: 0 From b78067e091659de5f514ebfa1a3eb02b2a88f311d28b2f8462e58204262dfbfe Mon Sep 17 00:00:00 2001 From: Jiri Slaby Date: Thu, 27 Jul 2023 07:56:02 +0000 Subject: [PATCH 3/3] add sle15 support OBS-URL: https://build.opensuse.org/package/show/devel:tools/b4?expand=0&rev=89 --- b4.changes | 3 ++- b4.spec | 21 +++++++++++---------- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/b4.changes b/b4.changes index 2b297e7..129a143 100644 --- a/b4.changes +++ b/b4.changes @@ -2,7 +2,8 @@ Thu Jul 27 06:41:39 UTC 2023 - Jiri Slaby - add python3-base >= 3.9 to BuildRequires for 15.5 and older -- add %{?sle15_python_module_pythons} too +- add %{?sle15_python_module_pythons} +- switch back to python_module macro to have all this working ------------------------------------------------------------------- Mon Jun 26 05:20:06 UTC 2023 - Jiri Slaby diff --git a/b4.spec b/b4.spec index 47ddbee..eff5bd3 100644 --- a/b4.spec +++ b/b4.spec @@ -16,6 +16,7 @@ # +%define pythons python3 %{?sle15_python_module_pythons} Name: b4 Version: 0.12.3 @@ -25,16 +26,16 @@ License: GPL-2.0-or-later Group: Development/Tools/Other URL: https://git.kernel.org/pub/scm/utils/b4/b4.git Source0: https://github.com/mricon/b4/archive/refs/tags/v%{version}.tar.gz#/%{name}-%{version}.tar.gz +BuildRequires: %{python_module base >= 3.9} +BuildRequires: %{python_module dkimpy >= 1.0.5} +BuildRequires: %{python_module dnspython >= 2.0.0} +BuildRequires: %{python_module patatt >= 0.5} +BuildRequires: %{python_module requests >= 2.24.0} +BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: git-core BuildRequires: git-filter-repo >= 2.30 BuildRequires: python-rpm-macros -BuildRequires: python3-base >= 3.9 -BuildRequires: python3-dkimpy >= 1.0.5 -BuildRequires: python3-dnspython >= 2.0.0 -BuildRequires: python3-patatt >= 0.5 -BuildRequires: python3-requests >= 2.24.0 -BuildRequires: python3-setuptools Requires: git-core Requires: git-filter-repo >= 2.30 Requires: python3-dkimpy @@ -62,14 +63,14 @@ rm -rf patatt sed -i.old '1{/#!.*/d}' b4/*.py %build -%python3_build +%python_build %install -%python3_install -%fdupes %{buildroot}%{python3_sitelib} +%python_install +%python_expand %fdupes %{buildroot}%{$python_sitelib} %check -python3 setup.py check +%python_exec setup.py check export PYTHONPATH="./" THEIRS=`%{buildroot}/%{_bindir}/b4 --version` OURS=`sed -n "s/__VERSION__ = '\(.*\)'/\1/p" b4/__init__.py`