From 6bb71b7abd0a2dbc45685bc36e60e245e39febe4d504e7ed0dcb605dfe535f6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Tue, 27 May 2025 11:28:38 +0000 Subject: [PATCH 1/4] - Convert to pip-based build OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-fann2?expand=0&rev=6 --- python-fann2.changes | 5 +++++ python-fann2.spec | 14 ++++++++------ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/python-fann2.changes b/python-fann2.changes index 0d3b76c..162cb2e 100644 --- a/python-fann2.changes +++ b/python-fann2.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue May 27 11:28:15 UTC 2025 - Markéta Machová + +- Convert to pip-based build + ------------------------------------------------------------------- Sat Jan 15 16:06:05 UTC 2022 - Dirk Müller diff --git a/python-fann2.spec b/python-fann2.spec index 7a75c75..e31c503 100644 --- a/python-fann2.spec +++ b/python-fann2.spec @@ -1,7 +1,7 @@ # # spec file for package python-fann2 # -# Copyright (c) 2022 SUSE LLC +# Copyright (c) 2025 SUSE LLC # # 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-%{**}} Name: python-fann2 Version: 1.2.0 Release: 0 @@ -26,13 +25,15 @@ Group: Development/Languages/Python URL: https://github.com/FutureLinkCorporation/fann2 Source: https://github.com/FutureLinkCorporation/fann2/archive/refs/tags/%{version}.tar.gz BuildRequires: %{python_module devel} +BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: gcc-c++ +BuildRequires: pkgconfig BuildRequires: python-rpm-macros BuildRequires: swig BuildRequires: pkgconfig(fann) - %python_subpackages %description @@ -49,10 +50,10 @@ updated to include support for python 2.x/3.x . %build export CFLAGS="%{optflags}" -%python_build +%pyproject_wheel %install -%python_install +%pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitearch} %python_expand rm %{buildroot}%{$python_sitearch}/fann2/fann2_wrap.cxx %python_expand rm %{buildroot}%{$python_sitearch}/fann2/fann_cpp_subclass.h @@ -63,6 +64,7 @@ export CFLAGS="%{optflags}" %files %{python_files} %doc README.rst %license LICENSE -%{python_sitearch}/* +%{python_sitearch}/fann2 +%{python_sitearch}/fann2-%{version}*-info %changelog From 7323aa2273b3f4793edc9d76eed58e07ace3174e3835c478a9b7d9975f1602e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Tue, 27 May 2025 11:31:02 +0000 Subject: [PATCH 2/4] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-fann2?expand=0&rev=7 --- python-fann2.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python-fann2.spec b/python-fann2.spec index e31c503..cbcfeff 100644 --- a/python-fann2.spec +++ b/python-fann2.spec @@ -65,6 +65,6 @@ export CFLAGS="%{optflags}" %doc README.rst %license LICENSE %{python_sitearch}/fann2 -%{python_sitearch}/fann2-%{version}*-info +%{python_sitearch}/fann-%{version}*-info %changelog From cdd74aec4a1ae374b52727a6778fc2ff29bf0a1047d08b8c1a31f80776715db3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Tue, 27 May 2025 11:32:59 +0000 Subject: [PATCH 3/4] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-fann2?expand=0&rev=8 --- python-fann2.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python-fann2.spec b/python-fann2.spec index cbcfeff..764fda4 100644 --- a/python-fann2.spec +++ b/python-fann2.spec @@ -65,6 +65,6 @@ export CFLAGS="%{optflags}" %doc README.rst %license LICENSE %{python_sitearch}/fann2 -%{python_sitearch}/fann-%{version}*-info +#%%{python_sitearch}/fann-%{version}*-info %changelog From 01127946b351afb42f5f20bbb16c91b22fab757d63da207628657a3858de79d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mark=C3=A9ta=20Machov=C3=A1?= Date: Tue, 27 May 2025 11:36:24 +0000 Subject: [PATCH 4/4] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-fann2?expand=0&rev=9 --- python-fann2.spec | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/python-fann2.spec b/python-fann2.spec index 764fda4..546a534 100644 --- a/python-fann2.spec +++ b/python-fann2.spec @@ -16,6 +16,8 @@ # +# bad upstream packaging +%define metadata_ver 1.1.2 Name: python-fann2 Version: 1.2.0 Release: 0 @@ -65,6 +67,6 @@ export CFLAGS="%{optflags}" %doc README.rst %license LICENSE %{python_sitearch}/fann2 -#%%{python_sitearch}/fann-%{version}*-info +%{python_sitearch}/fann2-%{metadata_ver}*-info %changelog