# Created by pyp2rpm-3.3.2 %global pypi_name trololio %global mod_name Trololio %if (0%{?rhel} && 0%{?rhel} < 8) || (0%{?fedora} && 0%{?fedora} < 29) %bcond_without python2 %else %bcond_with python2 %endif %global sum Trollius and asyncio compatibility library %global desc \ Trololio provides a compatibility layer for Trollius and asyncio (aka Tulip). \ It addresses the differences listed in Trollius and Tulip: \ \ * Allows the use of Trollius' syntax with asyncio. \ * Provides missing objects and aliases for the others. \ * Synchronizes debug environnement variables. Name: python-%{pypi_name} Version: 1.0 Release: 15%{?dist} Summary: %{sum} License: MIT URL: http://github.com/ThinkChaos/Trololio/ Source0: https://files.pythonhosted.org/packages/source/t/%{pypi_name}/%{mod_name}-%{version}.zip # License file from source repository Source1: https://raw.githubusercontent.com/ThinkChaos/Trololio/25fe6b9a0d9e2dc69d59f1b5c6e6e56a6615c305/LICENSE#/Trololio-LICENSE BuildArch: noarch %if %{with python2} BuildRequires: python2-devel BuildRequires: python2-setuptools %endif BuildRequires: python%{python3_pkgversion}-devel BuildRequires: python%{python3_pkgversion}-setuptools %description %{desc} %if %{with python2} %package -n python2-%{pypi_name} Summary: %{sum} for Python 2 %{?python_provide:%python_provide python2-%{pypi_name}} %if (0%{?rhel} && 0%{?rhel} < 8) || (0%{?fedora} && 0%{?fedora} < 28) Requires: python-trollius %else Requires: python2-trollius %endif %description -n python2-%{pypi_name} %{desc} This package provides the Python 2 module. %endif %package -n python%{python3_pkgversion}-%{pypi_name} Summary: %{sum} for Python 3 %{?python_provide:%python_provide python%{python3_pkgversion}-%{pypi_name}} %description -n python%{python3_pkgversion}-%{pypi_name} %{desc} This package provides the Python 3 module. %prep %autosetup -n %{mod_name}-%{version} # Remove bundled egg-info rm -rf *.egg-info # Install license into source tree cp %{SOURCE1} LICENSE %build %if %{with python2} %py2_build %endif %py3_build %install %if %{with python2} %py2_install %endif %py3_install %if %{with python2} %files -n python2-%{pypi_name} %doc README.rst %license LICENSE %{python2_sitelib}/%{pypi_name}.py* %{python2_sitelib}/%{mod_name}-%{version}-py?.?.egg-info %endif %files -n python%{python3_pkgversion}-%{pypi_name} %doc README.rst %license LICENSE %{python3_sitelib}/__pycache__/* %{python3_sitelib}/%{pypi_name}.py %{python3_sitelib}/%{mod_name}-%{version}-py%{python3_version}.egg-info %changelog * Fri Jul 22 2022 Fedora Release Engineering - 1.0-15 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild * Mon Jun 13 2022 Python Maint - 1.0-14 - Rebuilt for Python 3.11 * Fri Jan 21 2022 Fedora Release Engineering - 1.0-13 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild * Tue Jul 27 2021 Fedora Release Engineering - 1.0-12 - Second attempt - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild * Fri Jun 04 2021 Python Maint - 1.0-11 - Rebuilt for Python 3.10 * Wed Jan 27 2021 Fedora Release Engineering - 1.0-10 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild * Wed Jul 29 2020 Fedora Release Engineering - 1.0-9 - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild * Tue May 26 2020 Miro Hrončok - 1.0-8 - Rebuilt for Python 3.9 * Thu Jan 30 2020 Fedora Release Engineering - 1.0-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild * Thu Oct 03 2019 Miro Hrončok - 1.0-6 - Rebuilt for Python 3.8.0rc1 (#1748018) * Mon Aug 19 2019 Miro Hrončok - 1.0-5 - Rebuilt for Python 3.8 * Fri Jul 26 2019 Fedora Release Engineering - 1.0-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild * Sat Feb 02 2019 Fedora Release Engineering - 1.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild * Fri Jul 13 2018 Neal Gompa - 1.0-2 - Fix dependency for python2-trololio for F27 * Mon Jul 09 2018 Neal Gompa - 1.0-1 - Initial package