From 049dbe02fdb5ec7bc16ea222ce4becebe1fa7e5dda489a2a6030e7063622f355 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Wed, 10 Dec 2025 09:54:00 +0000 Subject: [PATCH] Eliminate the need for setuptools_scm by adding no-setuptools_scm.patch. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-iniconfig?expand=0&rev=23 --- no-setuptools_scm.patch | 27 +++++++++++++++++++++++++++ python-iniconfig.changes | 6 ++++++ python-iniconfig.spec | 9 +++++---- 3 files changed, 38 insertions(+), 4 deletions(-) create mode 100644 no-setuptools_scm.patch diff --git a/no-setuptools_scm.patch b/no-setuptools_scm.patch new file mode 100644 index 0000000..615215c --- /dev/null +++ b/no-setuptools_scm.patch @@ -0,0 +1,27 @@ +--- + pyproject.toml | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) + +Index: iniconfig-2.3.0/pyproject.toml +=================================================================== +--- iniconfig-2.3.0.orig/pyproject.toml 2025-12-10 10:43:39.982953641 +0100 ++++ iniconfig-2.3.0/pyproject.toml 2025-12-10 10:52:41.551397217 +0100 +@@ -2,7 +2,6 @@ + build-backend = "setuptools.build_meta" + requires = [ + "setuptools>=77", +- "setuptools-scm>=8", + ] + + [project] +@@ -49,8 +48,8 @@ + [tool.setuptools.package-data] + iniconfig = [ "py.typed" ] + +-[tool.setuptools_scm] +-write_to = "src/iniconfig/_version.py" ++[tool.setuptools.dynamic] ++version = { attr = "iniconfig._version.__version__" } + + [tool.ruff] + diff --git a/python-iniconfig.changes b/python-iniconfig.changes index ae3bcab..28525bc 100644 --- a/python-iniconfig.changes +++ b/python-iniconfig.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Dec 10 09:30:44 UTC 2025 - Matej Cepl + +- Eliminate the need for setuptools_scm by adding + no-setuptools_scm.patch. + ------------------------------------------------------------------- Thu Dec 4 10:02:05 UTC 2025 - John Paul Adrian Glaubitz diff --git a/python-iniconfig.spec b/python-iniconfig.spec index cd33128..644d16e 100644 --- a/python-iniconfig.spec +++ b/python-iniconfig.spec @@ -1,7 +1,7 @@ # # spec file for package python-iniconfig # -# Copyright (c) 2025 SUSE LLC +# Copyright (c) 2025 SUSE LLC and contributors # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,7 +16,6 @@ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} %global flavor @BUILD_FLAVOR@%{nil} %if "%{flavor}" == "test" %define psuffix -%{flavor} @@ -35,10 +34,12 @@ Group: Development/Languages/Python URL: https://github.com/RonnyPfannschmidt/iniconfig Source: https://files.pythonhosted.org/packages/source/i/iniconfig/iniconfig-%{version}.tar.gz Source1: https://github.com/pytest-dev/iniconfig/archive/refs/tags/v%{version}.tar.gz#/iniconfig-%{version}-tests.tar.gz +# PATCH-FIX-OPENSUSE no-setuptools_scm.patch mcepl@suse.com +# don't use setuptools_scm +Patch0: no-setuptools_scm.patch BuildRequires: %{python_module base >= 3.8} BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools >= 77} -BuildRequires: %{python_module setuptools-scm >= 8} BuildRequires: fdupes BuildRequires: python-rpm-macros BuildArch: noarch @@ -61,7 +62,7 @@ having a unique set of features: * iniconfig raises an Error if two sections have the same name. %prep -%setup -q -n iniconfig-%{version} -a1 +%autosetup -p1 -n iniconfig-%{version} -a1 %if !%{with test} %build