From 3700dcbe7948308d531c4022b3c557b4b78675cfafba14846346a4fac2639aa8 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Thu, 4 Jan 2024 15:16:46 +0000 Subject: [PATCH 1/2] Accepting request 1136800 from home:ecsos:python - Add %{?sle15_python_module_pythons} OBS-URL: https://build.opensuse.org/request/show/1136800 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-freetype-py?expand=0&rev=16 --- python-freetype-py.changes | 5 +++++ python-freetype-py.spec | 3 +-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/python-freetype-py.changes b/python-freetype-py.changes index 87e8d3f..740ea5e 100644 --- a/python-freetype-py.changes +++ b/python-freetype-py.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Jan 4 12:45:19 UTC 2024 - ecsos + +- Add %{?sle15_python_module_pythons} + ------------------------------------------------------------------- Thu Dec 7 20:40:20 UTC 2023 - Dirk Müller diff --git a/python-freetype-py.spec b/python-freetype-py.spec index d436f95..195eca3 100644 --- a/python-freetype-py.spec +++ b/python-freetype-py.spec @@ -16,8 +16,7 @@ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} -%define skip_python2 1 +%{?sle15_python_module_pythons} Name: python-freetype-py Version: 2.4.0 Release: 0 From c377723a1f04e37bcac0890897c96356464f2cb1d262127861128e7d9f454f7e Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Thu, 4 Jan 2024 16:15:09 +0000 Subject: [PATCH 2/2] - Clean up the SPEC file. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-freetype-py?expand=0&rev=17 --- python-freetype-py.changes | 5 +++++ python-freetype-py.spec | 14 ++++++++------ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/python-freetype-py.changes b/python-freetype-py.changes index 740ea5e..d19e7db 100644 --- a/python-freetype-py.changes +++ b/python-freetype-py.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Jan 4 16:14:59 UTC 2024 - Matej Cepl + +- Clean up the SPEC file. + ------------------------------------------------------------------- Thu Jan 4 12:45:19 UTC 2024 - ecsos diff --git a/python-freetype-py.spec b/python-freetype-py.spec index 195eca3..a93ac57 100644 --- a/python-freetype-py.spec +++ b/python-freetype-py.spec @@ -1,7 +1,7 @@ # # spec file for package python-freetype-py # -# Copyright (c) 2023 SUSE LLC +# Copyright (c) 2024 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -25,10 +25,11 @@ License: BSD-3-Clause Group: Development/Languages/Python URL: https://github.com/rougier/freetype-py Source: https://files.pythonhosted.org/packages/source/f/freetype-py/freetype-py-%{version}.zip +BuildRequires: %{python_module pip} BuildRequires: %{python_module pytest} BuildRequires: %{python_module setuptools_scm} -BuildRequires: %{python_module setuptools} BuildRequires: %{python_module toml} +BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: freetype2 BuildRequires: python-rpm-macros @@ -42,14 +43,14 @@ Freetype python provides bindings for the FreeType library. Only the high-level API is bound. %prep -%setup -q -n freetype-py-%{version} +%autosetup -p1 -n freetype-py-%{version} sed -i -e '/^#!\//, 1d' freetype/ft_structs.py freetype/ft_types.py %build -%python_build +%pyproject_wheel %install -%python_install +%pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} %check @@ -58,6 +59,7 @@ sed -i -e '/^#!\//, 1d' freetype/ft_structs.py freetype/ft_types.py %files %{python_files} %license LICENSE.txt %doc README.rst -%{python_sitelib}/* +%{python_sitelib}/freetype +%{python_sitelib}/freetype_py-%{version}*-info %changelog