%define scl rh-python36 %{?scl:%scl_package %{name}} %{!?scl:%global pkg_name %{name}} %define name typing_extensions %define version 3.7.4.1 %define unmangled_version 3.7.4.1 %define unmangled_version 3.7.4.1 %define release 1 Summary: Backported and Experimental Type Hints for Python 3.5+ %{?scl:Requires: %{scl}-runtime} %{?scl:BuildRequires: %{scl}-runtime} Name: %{?scl_prefix}typing_extensions Version: %{version} Release: %{release} Source0: typing_extensions-%{unmangled_version}.tar.gz License: PSF Group: Development/Libraries BuildRoot: %{_tmppath}/typing_extensions-%{version}-%{release}-buildroot Prefix: %{_prefix} BuildArch: noarch Vendor: Guido van Rossum, Jukka Lehtosalo, Lukasz Langa, Michael Lee Packager: Martin Juhl Url: https://github.com/python/typing/blob/master/typing_extensions/README.rst %description Typing Extensions -- Backported and Experimental Type Hints for Python The ``typing`` module was added to the standard library in Python 3.5 on a provisional basis and will no longer be provisional in Python 3.7. However, this means users of Python 3.5 - 3.6 who are unable to upgrade will not be able to take advantage of new types added to the ``typing`` module, such as ``typing.Text`` or ``typing.Coroutine``. The ``typing_extensions`` module contains both backports of these changes as well as experimental types that will eventually be added to the ``typing`` module, such as ``Protocol`` or ``TypedDict``. Users of other Python versions should continue to install and use the ``typing`` module from PyPi instead of using this one unless specifically writing code that must be compatible with multiple Python versions or requires experimental types. %prep %{?scl:scl enable %{scl} - << \EOF} set -ex %setup -n typing_extensions-%{unmangled_version} -n typing_extensions-%{unmangled_version} %{?scl:EOF} %build %{?scl:scl enable %{scl} - << \EOF} set -ex python3 setup.py build %{?scl:EOF} %install %{?scl:scl enable %{scl} - << \EOF} set -ex python3 setup.py install --single-version-externally-managed -O1 --root=$RPM_BUILD_ROOT --record=INSTALLED_FILES %{?scl:EOF} %clean %{?scl:scl enable %{scl} - << \EOF} set -ex rm -rf $RPM_BUILD_ROOT %{?scl:EOF} %files -f INSTALLED_FILES %defattr(-,root,root)