chore: Update Python packages to the modern RPM Python build system (#4816) (#4827)

* chore(shibuya): Update to modern Python macros, prep stuff for docs?



* chore(lomiri-ui-toolkit): Update to modern Python macros



* chore(spinxcontrib-moderncmakedomain): Follow guidelines for "canonical" name



* Oops



* fix(lomiri-ui-toolkit) More modern Python changes

* Aaaa

* chore(pillow-heif): Update to modern Python build systems

* chore(protobuf): Update to modern Python build systems

* refactor(sphinx-moderncmakedomain): Run tests with Nox instead

* fix(shibuya): Oops



---------


(cherry picked from commit b02f48f9c7)

Signed-off-by: Gilver <rockgrub@disroot.org>
Signed-off-by: RockGrub <RockGrub@users.noreply.github.com>
This commit is contained in:
Gilver
2025-05-14 07:45:37 -05:00
committed by GitHub
parent 6eb7213d78
commit db956352a5
5 changed files with 45 additions and 26 deletions
@@ -7,7 +7,7 @@
Name: python-%{srcname}
Version: 0.22.0
Release: 1%?dist
Release: 2%?dist
Summary: Python library for working with HEIF images and plugin for Pillow
License: BSD-3-Clause
@@ -22,6 +22,7 @@ BuildRequires: python%{python3_pkgversion}-devel
BuildRequires: python%{python3_pkgversion}-setuptools
BuildRequires: python%{python3_pkgversion}-pillow-devel
BuildRequires: libheif-devel
BuildRequires: python%{python3_pkgversion}dist(pip)
%if %{with doc}
BuildRequires: make
BuildRequires: python%{python3_pkgversion}-sphinx
@@ -72,7 +73,7 @@ Documentation for %{srcname}.
%build
# Native build
%py3_build
%pyproject_wheel
# Doc build
%if %{with doc}
@@ -83,7 +84,7 @@ rm -f docs/_build_py3/html/.buildinfo
%install
# Native build
%py3_install
%pyproject_install
%check
# Check Python 3 modules
@@ -97,7 +98,7 @@ popd
%doc README.md CHANGELOG.md
%license LICENSE.txt
%{python3_sitearch}/pillow_heif/
%{python3_sitearch}/pillow_heif-%{version}-py%{python3_version}.egg-info/
%{python3_sitearch}/pillow_heif-%{version}.dist-info/
%{python3_sitearch}/_pillow_heif.*.so
%files -n python%{python3_pkgversion}-%{srcname}-devel
@@ -2,7 +2,7 @@
%global pypi_name protobuf
Name: python-%{pypi_name}
Version: 6.30.1
Version: 6.30.2
Release: 2%?dist
Summary: Protocol Buffers
@@ -11,6 +11,7 @@ URL: https://developers.google.com/protocol-buffers/
Source0: %{pypi_source}
BuildRequires: python3-devel gcc
BuildRequires: python3dist(pip)
BuildRequires: python3dist(setuptools)
%description
@@ -30,15 +31,15 @@ Protocol Buffers are Google's data interchange format
rm -rf %{pypi_name}.egg-info
%build
%py3_build
%pyproject_wheel
%install
%py3_install
%pyproject_install
%files -n python3-%{pypi_name}
%doc README.md
%{python3_sitearch}/google
%{python3_sitearch}/%{pypi_name}-%{version}-py%{python3_version}.egg-info
%{python3_sitearch}/google/
%{python3_sitearch}/protobuf-%{version}.dist-info/
%changelog
* Sun Feb 19 2023 windowsboy111 <wboy111@outlook.com> - 4.22.0-1
@@ -5,13 +5,14 @@
Name: python-%{real_name}
Version: 3.29.0
Release: 1%{?dist}
Release: 2%{?dist}
Summary: Sphinx domain for modern CMake
License: BSD-3-Clause
URL: https://github.com/scikit-build/moderncmakedomain
Source0: %{pypi_source}
BuildRequires: python3-devel
BuildRequires: python3dist(hatchling)
BuildRequires: python3dist(nox)
BuildRequires: python3dist(pip)
BuildRequires: python3dist(pytest)
BuildRequires: python3dist(setuptools)
@@ -22,13 +23,14 @@ Packager: Gilver E. <rockgrub@disroot.org>
%description
Modern CMake domain entries, originally from Kitware.
%package -n python3-%{pypi_name}
%package -n python3-%{real_name}
Summary: %{summary}
Requires: python3dist(hatchling)
Requires: python3dist(sphinx)
%{?python_provide:%python_provide python3-%{pypi_name}}
Obsoletes: python3-%{pypi_name} < 3.29.0-2
%{?python_provide:%python_provide python3-%{real_name}}
%description -n python3-%{pypi_name}
%description -n python3-%{real_name}
Modern CMake domain entries, originally from Kitware.
%prep
@@ -41,9 +43,9 @@ Modern CMake domain entries, originally from Kitware.
%pyproject_install
%check
%pytest tests/*.py
nox -s tests
%files -n python3-%{pypi_name}
%files -n python3-%{real_name}
%doc PKG-INFO
%doc README.md
%license LICENSE