From 8c20821cf789f5706213672269143be8aeb772a8 Mon Sep 17 00:00:00 2001 From: Robert Schweikert Date: Tue, 21 May 2024 14:42:35 -0400 Subject: [PATCH] Switch build Switch the SLE build to Python 3.11. SUpport multiple python builds based on build service project setup. Switch to wheel build. --- csp-billing-adapter-amazon.spec | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/csp-billing-adapter-amazon.spec b/csp-billing-adapter-amazon.spec index 15efa69..003046f 100644 --- a/csp-billing-adapter-amazon.spec +++ b/csp-billing-adapter-amazon.spec @@ -15,9 +15,8 @@ # Please submit bugfixes or comments via https://bugs.opensuse.org/ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} -%global skip_python2 1 -%define pythons python3 +%{?sle15_python_module_pythons} + Name: csp-billing-adapter-amazon Version: 0.5.1 Release: 0 @@ -28,10 +27,12 @@ URL: https://github.com/SUSE-Enceladus/%{name} Source: https://files.pythonhosted.org/packages/source/c/%{name}/%{name}-%{version}.tar.gz BuildRequires: fdupes BuildRequires: python-rpm-macros -BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module csp-billing-adapter} +BuildRequires: %{python_module pip} BuildRequires: %{python_module pluggy} BuildRequires: %{python_module boto3} -BuildRequires: %{python_module csp-billing-adapter} +BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module wheel} %if %{with test} BuildRequires: %{python_module pytest} BuildRequires: %{python_module coverage} @@ -52,10 +53,10 @@ metering of usage in Amazon AWS. %autosetup -n %{name}-%{version} %build -%python_build +%pyproject_wheel %install -%python_install +%pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} %check