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.

50 lines
1.6 KiB

  1. #
  2. # Copyright (C) 2015 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-crcmod
  9. PKG_VERSION:=1.7
  10. PKG_RELEASE:=1
  11. PKG_MAINTAINER:=Micke Prag <micke.prag@telldus.se>
  12. PKG_LICENSE:=MIT
  13. PKG_SOURCE:=crcmod-$(PKG_VERSION).tar.gz
  14. PKG_SOURCE_URL:=http://pypi.python.org/packages/source/c/crcmod/
  15. PKG_MD5SUM:=2d5b92117d958dcead94f9e17f54cd32
  16. PKG_BUILD_DIR:=$(BUILD_DIR)/crcmod-$(PKG_VERSION)
  17. PKG_BUILD_DEPENDS:=python
  18. include $(INCLUDE_DIR)/package.mk
  19. $(call include_mk, python-package.mk)
  20. define Package/python-crcmod
  21. SUBMENU:=Python
  22. SECTION:=lang
  23. CATEGORY:=Languages
  24. TITLE:=python-crcmod
  25. URL:=http://crcmod.sourceforge.net/
  26. DEPENDS:=+python-light
  27. endef
  28. define Package/python-crcmod/description
  29. The software in this package is a Python module for generating objects that compute the Cyclic Redundancy Check (CRC). There is no attempt in this package to explain how the CRC works. There are a number of resources on the web that give a good explanation of the algorithms. Just do a Google search for "crc calculation" and browse till you find what you need. Another resource can be found in chapter 20 of the book "Numerical Recipes in C" by Press et. al.
  30. endef
  31. define Build/Compile
  32. $(call Build/Compile/PyMod,,install --prefix="$(PKG_INSTALL_DIR)/usr")
  33. endef
  34. define Package/python-crcmod/install
  35. $(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)
  36. $(CP) \
  37. $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/* \
  38. $(1)$(PYTHON_PKG_DIR)
  39. endef
  40. $(eval $(call BuildPackage,python-crcmod))