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