Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package python-pyo for openSUSE:Factory checked in at 2025-05-22 16:56:18 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-pyo (Old) and /work/SRC/openSUSE:Factory/.python-pyo.new.2732 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pyo" Thu May 22 16:56:18 2025 rev:5 rq:1278976 version:1.0.5 Changes: -------- --- /work/SRC/openSUSE:Factory/python-pyo/python-pyo.changes 2024-06-12 15:40:02.889925088 +0200 +++ /work/SRC/openSUSE:Factory/.python-pyo.new.2732/python-pyo.changes 2025-05-22 16:56:38.105318038 +0200 @@ -1,0 +2,11 @@ +Wed May 21 07:28:23 UTC 2025 - Daniel Garcia <daniel.gar...@suse.com> + +- Use libalternatives +- Add python-standard-aifc for python >= 3.13 + +------------------------------------------------------------------- +Tue May 20 14:57:24 UTC 2025 - Matej Cepl <mc...@cepl.eu> + +- Switch building to use of PEP517 backend. + +------------------------------------------------------------------- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-pyo.spec ++++++ --- /var/tmp/diff_new_pack.OVZYqJ/_old 2025-05-22 16:56:38.721343964 +0200 +++ /var/tmp/diff_new_pack.OVZYqJ/_new 2025-05-22 16:56:38.721343964 +0200 @@ -1,7 +1,7 @@ # # spec file for package python-pyo # -# Copyright (c) 2024 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,8 +16,12 @@ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} -%define skip_python2 1 +%if 0%{?suse_version} > 1500 +%bcond_without libalternatives +%else +%bcond_with libalternatives +%endif + Name: python-pyo Version: 1.0.5 Release: 0 @@ -30,7 +34,9 @@ # PATCH-FIX-UPSTREAM - Fix multiple incorrect declarations and signatures of callback functions Patch: https://github.com/belangeo/pyo/pull/277.patch BuildRequires: %{python_module devel} +BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: pkgconfig BuildRequires: portmidi-devel @@ -39,6 +45,18 @@ BuildRequires: pkgconfig(liblo) BuildRequires: pkgconfig(portaudiocpp) BuildRequires: pkgconfig(sndfile) +# Test build requires, aifc is no longer part of python standard lib +# since python3.13: +# https://github.com/belangeo/pyo/issues/286 +BuildRequires: python313-standard-aifc +Requires: (python-standard-aifc if python-base >= 3.13) +%if %{with libalternatives} +Requires: alts +BuildRequires: alts +%else +Requires(post): update-alternatives +Requires(postun): update-alternatives +%endif %python_subpackages %description @@ -52,15 +70,35 @@ %build export CFLAGS="%{optflags}" -%python_build --use-jack --use-double +%{pyproject_wheel -C "--build-option=--use-jack" -C "--build-option=--use-double" .} %install -%python_install --use-jack --use-double +%pyproject_install + +# Fix non-executable-script editor and examples +%{python_expand # +for i in editor examples/algorithmic examples/sequencing examples/matrix examples/fft examples/sampling examples/synthesis +do +sed -i "/^#!\s*\/usr\/bin\/env python/d" %{buildroot}%{$python_sitearch}/pyo/$i/*.py +done +} + %python_clone -a %{buildroot}%{_bindir}/epyo %python_expand %fdupes %{buildroot}%{$python_sitearch} %check +# Change directory to avoid importing from source +mkdir -p test +pushd test # testsuite is broken and can not be run even from github tarball +%{python_expand # +PYTHONPATH=%{buildroot}%{$python_sitearch} $python -c "import pyo; print(pyo.PYO_VERSION)" +} +popd + +%pre +# If libalternatives is used: Removing old update-alternatives entries. +%python_libalternatives_reset_alternative epyo %post %python_install_alternative epyo @@ -72,5 +110,7 @@ %doc README.md %license LICENSE %python_alternative %{_bindir}/epyo -%{python_sitearch}/* +%{python_sitearch}/pyo +%{python_sitearch}/pyo64 +%{python_sitearch}/pyo-%{version}*-info