source: projects/specs/trunk/p/python-jinja2/python-jinja2-vl.spec @ 1741

Revision 1741, 6.1 KB checked in by munepi, 14 years ago (diff)

NEW calibre: updated/added calibre's dependencies

Line 
1%global with_python3 0
2%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
3
4# Enable building without docs to avoid a circular dependency between this
5# and python-sphinx:
6%global with_docs 0
7
8Name:           python-jinja2
9Version:        2.5.2
10Release:        1%{?_dist_release}
11Summary:        General purpose template engine
12Group:          Development/Languages
13License:        BSD
14URL:            http://jinja.pocoo.org/
15Source0:        http://pypi.python.org/packages/source/J/Jinja2/Jinja2-%{version}.tar.gz
16BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root
17BuildArch:      noarch
18BuildRequires:  python-devel
19BuildRequires:  python-setuptools
20BuildRequires:  python-markupsafe
21%if 0%{?with_docs}
22BuildRequires:  python-sphinx
23%endif # with_docs
24Requires:       python-babel >= 0.8
25Requires:       python-markupsafe
26%if 0%{?with_python3}
27BuildRequires:  python3-devel
28BuildRequires:  python3-setuptools
29BuildRequires:  python3-markupsafe
30Requires:       python3-markupsafe
31# babel isn't py3k ready yet, and is only a weak dependency
32#Requires:       python3-babel >= 0.8
33%endif # with_python3
34
35BuildRequires:  python-setuptools
36
37
38%description
39Jinja2 is a template engine written in pure Python.  It provides a
40Django inspired non-XML syntax but supports inline expressions and an
41optional sandboxed environment.
42
43If you have any exposure to other text-based template languages, such
44as Smarty or Django, you should feel right at home with Jinja2. It's
45both designer and developer friendly by sticking to Python's
46principles and adding functionality useful for templating
47environments.
48
49
50%if 0%{?with_python3}
51%package -n python3-jinja2
52Summary:        General purpose template engine
53Group:          Development/Languages
54
55
56%description -n python3-jinja2
57Jinja2 is a template engine written in pure Python.  It provides a
58Django inspired non-XML syntax but supports inline expressions and an
59optional sandboxed environment.
60
61If you have any exposure to other text-based template languages, such
62as Smarty or Django, you should feel right at home with Jinja2. It's
63both designer and developer friendly by sticking to Python's
64principles and adding functionality useful for templating
65environments.
66%endif # with_python3
67
68
69%prep
70%setup -q -n Jinja2-%{version}
71
72# cleanup
73find . -name '*.pyo' -o -name '*.pyc' -delete
74
75# fix EOL
76%__sed -i 's|\r$||g' LICENSE
77
78%if 0%{?with_python3}
79%__cp -a . %{py3dir}
80%endif # with_python3
81
82
83%build
84%{__python} setup.py build
85
86# for now, we build docs using Python 2.x and use that for both
87# packages.
88%if 0%{?with_docs}
89%__make -C docs html
90%endif # with_docs
91
92%if 0%{?with_python3}
93pushd %{py3dir}
94%{__python3} setup.py build
95popd
96%endif # with_python3
97
98
99%install
100%__rm -rf %{buildroot}
101%{__python} setup.py install -O1 --skip-build \
102            --root %{buildroot}
103
104# remove hidden file
105%__rm -rf docs/_build/html/.buildinfo
106
107%if 0%{?with_python3}
108pushd %{py3dir}
109%{__python3} setup.py install -O1 --skip-build \
110            --root %{buildroot}
111popd
112%endif # with_python3
113
114
115%clean
116%__rm -rf %{buildroot}
117
118
119%check
120%__make test
121
122
123%if 0%{?with_python3}
124pushd %{py3dir}
125%__make test
126popd
127%endif # with_python3
128
129
130%files
131%defattr(-,root,root,-)
132%doc AUTHORS CHANGES LICENSE
133%if 0%{?with_docs}
134%doc docs/_build/html
135%endif # with_docs
136%doc ext
137%doc examples
138%{python_sitelib}/*
139%exclude %{python_sitelib}/jinja2/_debugsupport.c
140
141
142%if 0%{?with_python3}
143%files -n python3-jinja2
144%defattr(-,root,root,-)
145%doc AUTHORS CHANGES LICENSE
146%if 0%{?with_docs}
147%doc docs/_build/html
148%endif # with_docs
149%doc ext
150%doc examples
151%{python3_sitelib}/*
152%exclude %{python3_sitelib}/jinja2/_debugsupport.c
153%endif # with_python3
154
155
156%changelog
157* Mon Aug 23 2010 Munehiro Yamamoto <munepi@vinelinux.org> - 2.5.2-1
158- initial build based on Fedora development
159
160* Thu Aug 19 2010 Thomas Moschny <thomas.moschny@gmx.de> - 2.5.2-1
161- Update to upstream version 2.5.2.
162- Package depends on python-markupsafe and is noarch now.
163
164* Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 2.5-4
165- add explicit build-requirement on python-setuptools
166- fix doc disablement for python3 subpackage
167
168* Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 2.5-3
169- support disabling documentation in the build to break a circular build-time
170dependency with python-sphinx; disable docs for now
171
172* Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 2.5-2
173- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
174
175* Tue Jul 13 2010 Thomas Moschny <thomas.moschny@gmx.de> - 2.5-1
176- Update to upstream version 2.5.
177- Create python3 subpackage.
178- Minor specfile fixes.
179- Add examples directory.
180- Thanks to Gareth Armstrong for additional hints.
181
182* Wed Apr 21 2010 Thomas Moschny <thomas.moschny@gmx.de> - 2.4.1-1
183- Update to 2.4.1.
184
185* Tue Apr 13 2010 Thomas Moschny <thomas.moschny@gmx.de> - 2.4-1
186- Update to 2.4.
187
188* Tue Feb 23 2010 Thomas Moschny <thomas.moschny@gmx.de> - 2.3.1-1
189- Update to 2.3.1.
190- Docs are built using Sphinx now.
191- Run the testsuite.
192
193* Sat Sep 19 2009 Thomas Moschny <thomas.moschny@gmx.de> - 2.2.1-1
194- Update to 2.2.1, mainly a bugfix release.
195- Remove patch no longer needed.
196- Remove conditional for FC-8.
197- Compilation of speedup module has to be explicitly requested now.
198
199* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.1.1-3
200- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
201
202* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.1.1-2
203- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
204
205* Sat Jan 10 2009 Thomas Moschny <thomas.moschny@gmx.de> - 2.1.1-1
206- Update to 2.1.1 (bugfix release).
207
208* Thu Dec 18 2008 Thomas Moschny <thomas.moschny@gmx.de> - 2.1-1
209- Update to 2.1, which fixes a number of bugs.
210  See http://jinja.pocoo.org/2/documentation/changelog#version-2-1.
211
212* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 2.0-3
213- Rebuild for Python 2.6
214
215* Tue Jul 22 2008 Thomas Moschny <thomas.moschny@gmx.de> - 2.0-2
216- Use rpm buildroot macro instead of RPM_BUILD_ROOT.
217
218* Sun Jul 20 2008 Thomas Moschny <thomas.moschny@gmx.de> - 2.0-1
219- Upstream released 2.0.
220
221* Sun Jun 29 2008 Thomas Moschny <thomas.moschny@gmx.de> - 2.0-0.1.rc1
222- Modified specfile from the existing python-jinja package.
Note: See TracBrowser for help on using the repository browser.