%global pypi_name Jinja2 %global package_name %(echo "%{pypi_name}" | tr '-' '_' | tr '[:upper:]' '[:lower:]') %{?scl:%global python3_pkgversion %{nil}} %{?scl:%scl_package python-%{package_name}} %{!?scl:%global pkg_name %{name}} Name: %{?scl_prefix}python%{python3_pkgversion}-%{package_name} Version: 2.10 Release: 1%{?dist} Summary: A small but fast and easy to use stand-alone template engine written in pure python. Group: Development/Libraries License: BSD URL: https://pypi.io/project/%{pypi_name} Source0: https://pypi.io/packages/source/%(echo "%{pypi_name}" | cut -c 1)/%{pypi_name}/%{pypi_name}-%{version}.tar.gz BuildArch: noarch BuildRequires: %{?scl_prefix_python}python%{python3_pkgversion}-devel BuildRequires: %{?scl_prefix_python}python%{python3_pkgversion}-setuptools %{?scl:BuildRequires: %{scl}-build %{scl}-runtime} Requires: %{?scl_prefix}python%{python3_pkgversion}-markupsafe >= 0.23 %{?scl:Requires: %{scl}-runtime} %description Jinja2 is a template engine written in pure Python. It provides a Django inspired non-XML syntax but supports inline expressions and an optional sandboxed environment. %prep %setup -q -n %{pypi_name}-%{version} rm -rf %{pypi_name}.egg-info %build %{?scl:scl enable %{scl} "} %{__python3} setup.py build %{?scl:"} %install %{?scl:scl enable %{scl} "} %{__python3} \ setup.py \ install \ -O1 \ --skip-build \ --root %{buildroot} \ --install-purelib %{python3_sitelib} %{?scl:"} %files %license LICENSE %doc AUTHORS %doc CHANGES.rst %doc README.rst %{python3_sitelib}/jinja2 %{python3_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info %changelog * Tue Dec 11 2018 Daniel Uvehag - 2.10-1 - Initial package.