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.

57 lines
1.7 KiB

  1. #
  2. # Copyright (C) 2016-2017 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-ldap
  9. PKG_VERSION:=2.4.32
  10. PKG_RELEASE:=1
  11. PKG_MAINTAINER:=Dmitry Trefilov <the-alien@live.ru>
  12. PKG_LICENSE:=Python-style
  13. PKG_LICENSE_FILES:=LICENSE
  14. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  15. PKG_SOURCE_URL:=https://pypi.python.org/packages/67/d9/fa0ea70d1792875745116ad62ac8d4bcb07550b15cded591bb57df6a6d9a
  16. PKG_HASH:=5810f1b5a9ae9255df99fb9c2dcab7352fed325687efda56c0faae1a82c5e3cb
  17. include $(INCLUDE_DIR)/package.mk
  18. include ../python-package.mk
  19. define Package/python-ldap
  20. SUBMENU:=Python
  21. SECTION:=lang
  22. CATEGORY:=Languages
  23. DEPENDS:=+libopenldap +python
  24. TITLE:=Python modules for implementing LDAP clients
  25. URL:=http://python-ldap.org/
  26. endef
  27. define Package/python-ldap/description
  28. python-ldap provides an object-oriented API to access LDAP directory
  29. servers from Python programs. Mainly it wraps the OpenLDAP 2.x libs
  30. for that purpose. Additionally the package contains modules for
  31. other LDAP-related stuff (e.g. processing LDIF, LDAPURLs, LDAPv3
  32. schema, LDAPv3 extended operations and controls, etc.).
  33. endef
  34. define Build/Compile
  35. $(call Build/Compile/PyMod,,build_ext \
  36. --include-dirs="$(STAGING_DIR)/usr/include:$(STAGING_DIR)/usr/include/sasl" \
  37. --library-dirs="$(STAGING_DIR)/usr/lib:$(STAGING_DIR)/usr/lib/sasl2" \
  38. build_py \
  39. install --prefix="$(PKG_INSTALL_DIR)/usr")
  40. endef
  41. define PyPackage/python-ldap/install
  42. $(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)
  43. $(CP) \
  44. $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/* \
  45. $(1)$(PYTHON_PKG_DIR)
  46. endef
  47. $(eval $(call PyPackage,python-ldap))
  48. $(eval $(call BuildPackage,python-ldap))