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.

62 lines
1.8 KiB

  1. #
  2. # Copyright (C) 2011-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:=libp11
  9. PKG_VERSION:=0.4.9
  10. PKG_RELEASE:=1
  11. PKG_SOURCE_URL:=https://github.com/OpenSC/libp11/releases/download/$(PKG_NAME)-$(PKG_VERSION)/
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  13. PKG_HASH:=9d1c76d74c21ca224f96204982097ebc6b956f645b2b0b5f9c502a20e9ffcfd8
  14. PKG_MAINTAINER:=Daniel Golle <daniel@makrotopia.org>
  15. PKG_LICENSE:=LGPL-2.1+
  16. PKG_LICENSE_FILES:=COPYING
  17. PKG_BUILD_PARALLEL:=1
  18. PKG_FIXUP:=libtool
  19. PKG_INSTALL:=1
  20. include $(INCLUDE_DIR)/package.mk
  21. define Package/libp11
  22. SECTION:=libs
  23. CATEGORY:=Libraries
  24. TITLE:=PKCS#11 wrapper library
  25. URL:=https://www.opensc-project.org/opensc/wiki/libp11
  26. DEPENDS:=+libopenssl
  27. CONFLICTS:=engine_pkcs11
  28. endef
  29. define Package/libp11/description
  30. Libp11 is a library implementing a small layer on top of PKCS#11 API
  31. to make using PKCS#11 implementations easier.
  32. endef
  33. CONFIGURE_ARGS += --with-enginesdir=/usr/lib/engines
  34. define Build/InstallDev
  35. $(INSTALL_DIR) $(1)/usr/include/
  36. $(CP) $(PKG_INSTALL_DIR)/usr/include/*.h $(1)/usr/include/
  37. $(INSTALL_DIR) $(1)/usr/lib
  38. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libp11.{a,so} $(1)/usr/lib/
  39. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libp11.so* $(1)/usr/lib/
  40. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig/
  41. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libp11.pc $(1)/usr/lib/pkgconfig/libp11.pc
  42. endef
  43. define Package/libp11/install
  44. $(INSTALL_DIR) $(1)/usr/lib/
  45. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libp11.so.* $(1)/usr/lib/
  46. $(INSTALL_DIR) $(1)/usr/lib/engines
  47. $(CP) $(PKG_INSTALL_DIR)/usr/lib/engines/*.so* $(1)/usr/lib/engines
  48. $(LN) pkcs11.so $(1)/usr/lib/engines/libpkcs11.so
  49. endef
  50. $(eval $(call BuildPackage,libp11))