You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

60 lines
1.5 KiB

  1. #
  2. # Copyright (C) 2014 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=python-setuptools
  9. PKG_VERSION:=7.0
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=setuptools-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=https://pypi.python.org/packages/source/s/setuptools/
  13. PKG_MD5SUM:=6245d6752e2ef803c365f560f7f2f940
  14. PKG_BUILD_DIR:=$(BUILD_DIR)/setuptools-$(PKG_VERSION)
  15. include $(INCLUDE_DIR)/package.mk
  16. $(call include_mk, python-package.mk)
  17. define Package/python-setuptools
  18. SUBMENU:=Python
  19. SECTION:=lang
  20. CATEGORY:=Languages
  21. TITLE:=Tool for installing Python packages.
  22. URL:=https://bitbucket.org/pypa/setuptools
  23. DEPENDS:=+python
  24. endef
  25. define Package/python-setuptools/description
  26. Easily download, build, install, upgrade, and uninstall Python packages
  27. endef
  28. define Build/Compile
  29. $(call Build/Compile/PyMod,,\
  30. install --prefix="$(PKG_INSTALL_DIR)/usr" \
  31. )
  32. endef
  33. define PyPackage/python-setuptools/filespec
  34. +|/usr/lib/python$(PYTHON_VERSION)/site-packages
  35. endef
  36. define Build/InstallDev
  37. $(INSTALL_DIR) $(2)/lib/python$(PYTHON_VERSION)/site-packages
  38. $(CP) \
  39. $(PKG_INSTALL_DIR)/usr/lib/python$(PYTHON_VERSION)/site-packages/* \
  40. $(HOST_PYTHON_LIB_DIR)/site-packages
  41. endef
  42. define PyPackage/python-setuptools/install
  43. $(INSTALL_DIR) $(1)/usr/bin
  44. $(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
  45. endef
  46. $(eval $(call PyPackage,python-setuptools))
  47. $(eval $(call BuildPackage,python-setuptools))