python-jinja2-vl.spec 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215
  1. # async support is valid only on Python >= 3.6
  2. %bcond_without async
  3. # Enable building without docs to avoid a circular dependency between this
  4. # and python-sphinx:
  5. %bcond_with docs
  6. %global with_python3 1
  7. Summary: General purpose template engine
  8. Name: python-jinja2
  9. Version: 3.1.2
  10. Release: 1%{?_dist_release}
  11. Group: programming
  12. Vendor: Project Vine
  13. Distribution: Vine Linux
  14. License: BSD
  15. URL: https://jinja.palletsprojects.com/
  16. Source0: https://pypi.python.org/packages/source/J/Jinja2/Jinja2-%{version}.tar.gz
  17. BuildArch: noarch
  18. BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
  19. BuildRequires: python-rpm-macros
  20. BuildRequires: python-devel
  21. BuildRequires: python2-rpm-macros
  22. BuildRequires: python-setuptools
  23. BuildRequires: python-markupsafe
  24. %if %{with docs}
  25. BuildRequires: python-sphinx
  26. %endif # with docs
  27. Requires: python-babel >= 0.8
  28. Requires: python-markupsafe
  29. %if 0%{?with_python3}
  30. BuildRequires: python3-devel
  31. BuildRequires: python3-rpm-macros
  32. BuildRequires: python3-setuptools
  33. BuildRequires: python3-markupsafe
  34. # babel isn't py3k ready yet, and is only a weak dependency
  35. #Requires: python3-babel >= 0.8
  36. %endif # with_python3
  37. %description
  38. Jinja2 is a template engine written in pure Python. It provides a
  39. Django inspired non-XML syntax but supports inline expressions and an
  40. optional sandboxed environment.
  41. If you have any exposure to other text-based template languages, such
  42. as Smarty or Django, you should feel right at home with Jinja2. It's
  43. both designer and developer friendly by sticking to Python's
  44. principles and adding functionality useful for templating
  45. environments.
  46. %if 0%{?with_python3}
  47. %package -n python3-jinja2
  48. Summary: General purpose template engine
  49. Group: programming
  50. Requires: python3-markupsafe
  51. Requires: python3-babel
  52. %description -n python3-jinja2
  53. Jinja2 is a template engine written in pure Python. It provides a
  54. Django inspired non-XML syntax but supports inline expressions and an
  55. optional sandboxed environment.
  56. If you have any exposure to other text-based template languages, such
  57. as Smarty or Django, you should feel right at home with Jinja2. It's
  58. both designer and developer friendly by sticking to Python's
  59. principles and adding functionality useful for templating
  60. environments.
  61. %endif # with_python3
  62. %prep
  63. %setup -q -n Jinja2-%{version}
  64. # cleanup
  65. find . -name '*.pyo' -o -name '*.pyc' -delete
  66. %build
  67. %if 0%{?with_python3}
  68. %pip3_build_wheel
  69. %if %{with docs}
  70. make -C docs html PYTHONPATH=$(pwd) SPHINXBUILD=sphinx-build-3
  71. %endif # with docs
  72. %endif # with_python3
  73. %install
  74. %__rm -rf %{buildroot}
  75. # remove hidden file
  76. rm -rf docs/_build/html/.buildinfo
  77. %if %{with python3}
  78. %pip3_install_wheel
  79. # remove hidden file
  80. rm -rf docs/_build/html/.buildinfo
  81. %if ! %{with async}
  82. # these files are valid only on Python 3.6+
  83. rm %{buildroot}%{python3_sitelib}/jinja2/asyncsupport.py
  84. rm %{buildroot}%{python3_sitelib}/jinja2/asyncfilters.py
  85. %endif # ! with async
  86. %endif # with python3
  87. %clean
  88. %__rm -rf %{buildroot}
  89. %if 0%{?with_python3}
  90. %files -n python3-jinja2
  91. %defattr(-,root,root,-)
  92. %doc CHANGES.rst
  93. %doc ext
  94. %doc examples
  95. %license LICENSE*
  96. %if %{with docs}
  97. %doc docs/_build/html
  98. %endif # with docs
  99. %{python3_sitelib}/jinja2
  100. %{python3_sitelib}/Jinja2-*-info
  101. %endif # with_python3
  102. %changelog
  103. * Sun Oct 30 2022 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.1.2-1
  104. * Sun Aug 16 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.11.2-1
  105. - new upstream release.
  106. * Wed Nov 28 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.10-2
  107. - fixed R:.
  108. * Tue Nov 27 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.10-1
  109. - new upstream release.
  110. - added python3 support.
  111. * Sun Jan 12 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.5.5-3
  112. - rebuild with VineSeed environment
  113. * Sun Feb 19 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.5.5-2
  114. - rebuild with python-2.7.2
  115. * Thu May 5 2011 IWAI, Masaharu <iwai@alib.jp> 2.5.5-1
  116. - new upstream release
  117. - add Project and Distribution tags
  118. * Mon Aug 23 2010 Munehiro Yamamoto <munepi@vinelinux.org> - 2.5.2-1
  119. - initial build based on Fedora development
  120. * Thu Aug 19 2010 Thomas Moschny <thomas.moschny@gmx.de> - 2.5.2-1
  121. - Update to upstream version 2.5.2.
  122. - Package depends on python-markupsafe and is noarch now.
  123. * Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 2.5-4
  124. - add explicit build-requirement on python-setuptools
  125. - fix doc disablement for python3 subpackage
  126. * Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 2.5-3
  127. - support disabling documentation in the build to break a circular build-time
  128. dependency with python-sphinx; disable docs for now
  129. * Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 2.5-2
  130. - Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
  131. * Tue Jul 13 2010 Thomas Moschny <thomas.moschny@gmx.de> - 2.5-1
  132. - Update to upstream version 2.5.
  133. - Create python3 subpackage.
  134. - Minor specfile fixes.
  135. - Add examples directory.
  136. - Thanks to Gareth Armstrong for additional hints.
  137. * Wed Apr 21 2010 Thomas Moschny <thomas.moschny@gmx.de> - 2.4.1-1
  138. - Update to 2.4.1.
  139. * Tue Apr 13 2010 Thomas Moschny <thomas.moschny@gmx.de> - 2.4-1
  140. - Update to 2.4.
  141. * Tue Feb 23 2010 Thomas Moschny <thomas.moschny@gmx.de> - 2.3.1-1
  142. - Update to 2.3.1.
  143. - Docs are built using Sphinx now.
  144. - Run the testsuite.
  145. * Sat Sep 19 2009 Thomas Moschny <thomas.moschny@gmx.de> - 2.2.1-1
  146. - Update to 2.2.1, mainly a bugfix release.
  147. - Remove patch no longer needed.
  148. - Remove conditional for FC-8.
  149. - Compilation of speedup module has to be explicitly requested now.
  150. * Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.1.1-3
  151. - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
  152. * Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.1.1-2
  153. - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
  154. * Sat Jan 10 2009 Thomas Moschny <thomas.moschny@gmx.de> - 2.1.1-1
  155. - Update to 2.1.1 (bugfix release).
  156. * Thu Dec 18 2008 Thomas Moschny <thomas.moschny@gmx.de> - 2.1-1
  157. - Update to 2.1, which fixes a number of bugs.
  158. See http://jinja.pocoo.org/2/documentation/changelog#version-2-1.
  159. * Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 2.0-3
  160. - Rebuild for Python 2.6
  161. * Tue Jul 22 2008 Thomas Moschny <thomas.moschny@gmx.de> - 2.0-2
  162. - Use rpm buildroot macro instead of RPM_BUILD_ROOT.
  163. * Sun Jul 20 2008 Thomas Moschny <thomas.moschny@gmx.de> - 2.0-1
  164. - Upstream released 2.0.
  165. * Sun Jun 29 2008 Thomas Moschny <thomas.moschny@gmx.de> - 2.0-0.1.rc1
  166. - Modified specfile from the existing python-jinja package.