%global __python3 /usr/bin/python3.11 %global python3_pkgversion 3.11 Name: pycairo Version: 1.24.0 Release: 2%{?dist} Summary: Python bindings for the cairo library License: LGPL-2.1-only OR MPL-1.1 URL: https://www.cairographics.org/pycairo Source0: https://github.com/pygobject/pycairo/releases/download/v%{version}/pycairo-%{version}.tar.gz BuildRequires: gcc BuildRequires: pkgconfig(cairo) BuildRequires: python%{python3_pkgversion}-devel BuildRequires: python%{python3_pkgversion}-pytest BuildRequires: python%{python3_pkgversion}-setuptools %description Python bindings for the cairo library. %package -n python%{python3_pkgversion}-cairo Summary: Python %{python3_pkgversion} bindings for the cairo library %{?python_provide:%python_provide python%{python3_pkgversion}-cairo} %description -n python%{python3_pkgversion}-cairo Python %{python3_pkgversion} bindings for the cairo library. %package -n python%{python3_pkgversion}-cairo-devel Summary: Libraries and headers for py3cairo Requires: python%{python3_pkgversion}-cairo%{?_isa} = %{version}-%{release} Requires: python%{python3_pkgversion}-devel %description -n python%{python3_pkgversion}-cairo-devel This package contains files required to build wrappers for cairo add-on libraries so that they interoperate with py3cairo. %prep %autosetup -p1 %build %py3_build %install %py3_install %check %{__python3} setup.py test %files -n python%{python3_pkgversion}-cairo %license COPYING* %doc README.rst %{python3_sitearch}/cairo/ %{python3_sitearch}/pycairo*.egg-info %files -n python%{python3_pkgversion}-cairo-devel %dir %{_includedir}/pycairo %{_includedir}/pycairo/py3cairo.h %{_libdir}/pkgconfig/py3cairo.pc %changelog