%define scl rh-python36 %{?scl:%scl_package %{name}} %{!?scl:%global pkg_name %{name}} %define name zipp %define version 1.0.0 %define unmangled_version 1.0.0 %define unmangled_version 1.0.0 %define release 1 Summary: Backport of pathlib-compatible object wrapper for zip files %{?scl:Requires: %{scl}-runtime} %{?scl:BuildRequires: %{scl}-runtime} Name: %{?scl_prefix}zipp Version: %{version} Release: %{release} Source0: zipp-%{unmangled_version}.tar.gz License: UNKNOWN Group: Development/Libraries BuildRoot: %{_tmppath}/zipp-%{version}-%{release}-buildroot Prefix: %{_prefix} BuildArch: noarch Vendor: Jason R. Coombs Packager: Martin Juhl Url: https://github.com/jaraco/zipp %description .. image:: https://img.shields.io/pypi/v/zipp.svg :target: https://pypi.org/project/zipp .. image:: https://img.shields.io/pypi/pyversions/zipp.svg .. image:: https://img.shields.io/travis/jaraco/zipp/master.svg :target: https://travis-ci.org/jaraco/zipp .. image:: https://img.shields.io/badge/code%20style-black-000000.svg :target: https://github.com/ambv/black :alt: Code style: Black .. image:: https://img.shields.io/appveyor/ci/jaraco/zipp/master.svg :target: https://ci.appveyor.com/project/jaraco/zipp/branch/master .. .. image:: https://readthedocs.org/projects/zipp/badge/?version=latest .. :target: https://zipp.readthedocs.io/en/latest/?badge=latest A pathlib-compatible Zipfile object wrapper. A backport of the `Path object `_. %prep %{?scl:scl enable %{scl} - << \EOF} set -ex %setup -n zipp-%{unmangled_version} -n zipp-%{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)