Upstream 2.8

This commit is contained in:
Haïkel Guémar 2015-07-27 00:15:37 +02:00
parent 49a7d7b434
commit 56175d160d

View File

@ -1,37 +1,37 @@
%if 0%{?fedora} %if 0%{?fedora}
%global with_python3 1 %global with_python3 1
%else
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
%endif %endif
%global pypi_name jinja2
# Enable building without docs to avoid a circular dependency between this # Enable building without docs to avoid a circular dependency between this
# and python-sphinx: # and python-sphinx:
%global with_docs 1 %global with_docs 1
Name: python-jinja2 Name: python-jinja2
Version: 2.7.3 Version: 2.8
Release: 3%{?dist} Release: 1%{?dist}
Summary: General purpose template engine Summary: General purpose template engine
Group: Development/Languages Group: Development/Languages
License: BSD License: BSD
URL: http://jinja.pocoo.org/ URL: http://jinja.pocoo.org/
Source0: http://pypi.python.org/packages/source/J/Jinja2/Jinja2-%{version}.tar.gz Source0: http://pypi.python.org/packages/source/J/Jinja2/Jinja2-%{version}.tar.gz
# see https://github.com/mitsuhiko/jinja2/pull/259
Patch0: 99d0f3165ace0befd9eafd661be6e0c23d5f9ba5.patch BuildArch: noarch
BuildArch: noarch BuildRequires: python2-devel
BuildRequires: python-devel BuildRequires: python-setuptools
BuildRequires: python-setuptools BuildRequires: python-markupsafe
BuildRequires: python-markupsafe BuildRequires: pytest
%if 0%{?with_docs} %if 0%{?with_docs}
BuildRequires: python-sphinx BuildRequires: python-sphinx
%endif # with_docs %endif # with_docs
Requires: python-babel >= 0.8 Requires: python-babel >= 0.8
Requires: python-markupsafe Requires: python-markupsafe
Requires: python-setuptools Requires: python-setuptools
%if 0%{?with_python3} %if 0%{?with_python3}
BuildRequires: python3-devel BuildRequires: python3-devel
BuildRequires: python3-setuptools BuildRequires: python3-setuptools
BuildRequires: python3-markupsafe BuildRequires: python3-markupsafe
BuildRequires: python3-pytest
%endif # with_python3 %endif # with_python3
@ -49,12 +49,12 @@ environments.
%if 0%{?with_python3} %if 0%{?with_python3}
%package -n python3-jinja2 %package -n python3-jinja2
Summary: General purpose template engine Summary: General purpose template engine
Group: Development/Languages Group: Development/Languages
Requires: python3-markupsafe Requires: python3-markupsafe
Requires: python3-setuptools Requires: python3-setuptools
# babel isn't py3k ready yet, and is only a weak dependency # babel isn't py3k ready yet, and is only a weak dependency
#Requires: python3-babel >= 0.8 #Requires: python3-babel >= 0.8
%description -n python3-jinja2 %description -n python3-jinja2
@ -72,7 +72,6 @@ environments.
%prep %prep
%setup -q -n Jinja2-%{version} %setup -q -n Jinja2-%{version}
%patch0 -p1
# cleanup # cleanup
find . -name '*.pyo' -o -name '*.pyc' -delete find . -name '*.pyo' -o -name '*.pyc' -delete
@ -86,7 +85,7 @@ cp -a . %{py3dir}
%build %build
%{__python} setup.py build %{__python2} setup.py build
# for now, we build docs using Python 2.x and use that for both # for now, we build docs using Python 2.x and use that for both
# packages. # packages.
@ -102,8 +101,8 @@ popd
%install %install
%{__python} setup.py install -O1 --skip-build \ %{__python2} setup.py install -O1 --skip-build \
--root %{buildroot} --root %{buildroot}
# remove hidden file # remove hidden file
rm -rf docs/_build/html/.buildinfo rm -rf docs/_build/html/.buildinfo
@ -111,7 +110,7 @@ rm -rf docs/_build/html/.buildinfo
%if 0%{?with_python3} %if 0%{?with_python3}
pushd %{py3dir} pushd %{py3dir}
%{__python3} setup.py install -O1 --skip-build \ %{__python3} setup.py install -O1 --skip-build \
--root %{buildroot} --root %{buildroot}
popd popd
%endif # with_python3 %endif # with_python3
@ -134,8 +133,9 @@ popd
%endif # with_docs %endif # with_docs
%doc ext %doc ext
%doc examples %doc examples
%{python_sitelib}/* %{python2_sitelib}/jinja2
%exclude %{python_sitelib}/jinja2/_debugsupport.c %{python2_sitelib}/Jinja2-%{version}-py?.?.egg-info
%exclude %{python2_sitelib}/jinja2/_debugsupport.c
%if 0%{?with_python3} %if 0%{?with_python3}
@ -146,12 +146,16 @@ popd
%endif # with_docs %endif # with_docs
%doc ext %doc ext
%doc examples %doc examples
%{python3_sitelib}/* %{python3_sitelib}/jinja2
%{python3_sitelib}/Jinja2-%{version}-py?.?.egg-info
%exclude %{python3_sitelib}/jinja2/_debugsupport.c %exclude %{python3_sitelib}/jinja2/_debugsupport.c
%endif # with_python3 %endif # with_python3
%changelog %changelog
* Sun Jul 26 2015 Haïkel Guémar <hguemar@fedoraproject.org> - 2.8-1
- Upstream 2.8
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.7.3-3 * Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.7.3-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild