%global forgeurl https://github.com/MagicStack/uvloop %global version %(date +%Y%m%d) %global commit 74f4c96d3fc5281b1820491d2568de771ea7851b %global _forgeversionsuffix %{scm}%(printf %.7s %{commit}) %global source_date_epoch_from_changelog 0 %forgemeta Name: python-uvloop Version: %{forgeversion} Release: %{autorelease} Summary: Ultra fast asyncio event loop License: MIT OR Apache-2.0 URL: %{forgeurl} Source0: %{forgesource} BuildRequires: pkgconfig(python3) BuildRequires: pkgconfig(libuv) BuildRequires: python3dist(cython) BuildRequires: python3dist(pip) BuildRequires: python3dist(setuptools) BuildRequires: python3dist(wheel) BuildRequires: gcc %description uvloop is a fast replacement of the built-in asyncio event loop. This software implementation is written in Cython and relies on libuv. %prep %forgesetup %__sed -i -e '/^\s*self\.use_system_libuv\s=\s/s/False/True/' setup.py %generate_buildrequires %pyproject_buildrequires %build %pyproject_wheel %check %pyproject_check_import %install %pyproject_install %pyproject_save_files uvloop %__install -p -m 644 -D -t %{buildroot}%{_licensedir}/%{name} LICENSE-APACHE LICENSE-MIT %__install -p -m 644 -D -t %{buildroot}%{_pkgdocdir} README.rst performance.png %files -f %{pyproject_files} %license %{_licensedir}/* %doc %{_pkgdocdir}