python-jinja2.mk 1.3 KB

123456789101112131415161718192021222324252627282930313233
  1. ################################################################################
  2. #
  3. # python-jinja2
  4. #
  5. ################################################################################
  6. # Please keep in sync with package/python3-jinja2/python3-jinja2.mk
  7. PYTHON_JINJA2_VERSION = 2.11.3
  8. PYTHON_JINJA2_SOURCE = Jinja2-$(PYTHON_JINJA2_VERSION).tar.gz
  9. PYTHON_JINJA2_SITE = https://files.pythonhosted.org/packages/4f/e7/65300e6b32e69768ded990494809106f87da1d436418d5f1367ed3966fd7
  10. PYTHON_JINJA2_SETUP_TYPE = setuptools
  11. PYTHON_JINJA2_LICENSE = BSD-3-Clause
  12. PYTHON_JINJA2_LICENSE_FILES = LICENSE.rst
  13. PYTHON_JINJA2_CPE_ID_VENDOR = pocoo
  14. PYTHON_JINJA2_CPE_ID_PRODUCT = jinja2
  15. # In host build, setup.py tries to download markupsafe if it is not installed
  16. HOST_PYTHON_JINJA2_DEPENDENCIES = host-python-markupsafe
  17. # Both asyncsupport.py and asyncfilters.py use async feature, that is
  18. # not available in Python 2 and some features available in Python 3.6.
  19. # So in both cases *.py compilation would produce compiler errors.
  20. # Hence remove both files after package extraction.
  21. ifeq ($(BR2_PACKAGE_PYTHON),y)
  22. define PYTHON_JINJA2_REMOVE_ASYNC_SUPPORT
  23. rm $(@D)/src/jinja2/asyncsupport.py $(@D)/src/jinja2/asyncfilters.py
  24. endef
  25. PYTHON_JINJA2_POST_EXTRACT_HOOKS = PYTHON_JINJA2_REMOVE_ASYNC_SUPPORT
  26. endif
  27. $(eval $(python-package))
  28. $(eval $(host-python-package))