From 36b0233e51bc6f9999ace3425328899fc03a8b37df414e5035983fc84b0d0275 Mon Sep 17 00:00:00 2001 From: Daniel Garcia Date: Mon, 9 Feb 2026 11:09:42 +0000 Subject: [PATCH] - Add pythons_for_pypi macro. This macro will help to build the python minimal stack for different python versions. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-packaging?expand=0&rev=92 --- python-packaging.changes | 6 ++++++ python-packaging.spec | 14 +++++++++++++- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/python-packaging.changes b/python-packaging.changes index 164b227..7ae0e38 100644 --- a/python-packaging.changes +++ b/python-packaging.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Feb 9 11:07:43 UTC 2026 - Daniel Garcia + +- Add pythons_for_pypi macro. This macro will help to build the python + minimal stack for different python versions. + ------------------------------------------------------------------- Fri Jan 30 10:34:36 UTC 2026 - ecsos diff --git a/python-packaging.spec b/python-packaging.spec index f9845f2..5a3a8d8 100644 --- a/python-packaging.spec +++ b/python-packaging.spec @@ -20,7 +20,8 @@ # in order to avoid rewriting for subpackage generator %define mypython python %global flavor @BUILD_FLAVOR@%{nil} -%if 0%{?suse_version} >= 1650 +%if 0%{?suse_version} >= 1600 + %if "%{flavor}" == "primary" # this one is goes into Ring0: Bootstrap for primary python stack %define pprefix %{primary_python} @@ -53,7 +54,18 @@ ExclusiveArch: do-not-build %bcond_with test %endif +%if "%{flavor}" == "" +%{?pythons_for_pypi} +%endif %{?sle15_python_module_pythons} + +%if "%{flavor}" == "" && "%{shrink:%{pythons}}" == "" +# Exclude for local osc build: unresolvable +%define python_module() empty-python-buildset +# Exclude for obs server +ExclusiveArch: do-not-build +%endif + Name: %{pprefix}-packaging%{?psuffix} Version: 26.0 Release: 0