|
@@ -0,0 +1,99 @@
|
|
1
|
+#
|
|
2
|
+# Copyright (C) 2009-2012 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:=pcsc-lite
|
|
11
|
+PKG_VERSION:=1.8.11
|
|
12
|
+PKG_RELEASE:=1
|
|
13
|
+
|
|
14
|
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
|
15
|
+PKG_SOURCE_URL:=https://alioth.debian.org/frs/download.php/file/3991
|
|
16
|
+PKG_MD5SUM:=73502ca4ba6526727f9f49c63d805408
|
|
17
|
+PKG_MAINTAINER:=Daniel Golle <daniel@makrotopia.org>
|
|
18
|
+
|
|
19
|
+PKG_FIXUP:=autoreconf
|
|
20
|
+PKG_INSTALL:=1
|
|
21
|
+
|
|
22
|
+include $(INCLUDE_DIR)/package.mk
|
|
23
|
+
|
|
24
|
+define Package/pcsc-lite/Default
|
|
25
|
+ TITLE:=Middleware to access a smart card using SCard API (PC/SC).
|
|
26
|
+ URL:=http://pcsclite.alioth.debian.org/
|
|
27
|
+endef
|
|
28
|
+
|
|
29
|
+define Package/pcsc-lite/Default/description
|
|
30
|
+ The purpose of PC/SC Lite is to provide a Windows(R) SCard
|
|
31
|
+ interface in a very small form factor for communicating to
|
|
32
|
+ smart cards and smart cards readers.
|
|
33
|
+endef
|
|
34
|
+
|
|
35
|
+define Package/libpcsclite
|
|
36
|
+ $(call Package/pcsc-lite/Default)
|
|
37
|
+ SECTION:=libs
|
|
38
|
+ CATEGORY:=Libraries
|
|
39
|
+ TITLE+= (library)
|
|
40
|
+ DEPENDS:=+libusb-1.0 +libpthread +librt
|
|
41
|
+endef
|
|
42
|
+
|
|
43
|
+define Package/libpcsclite/description
|
|
44
|
+ $(call Package/pcsc-lite/Default/description)
|
|
45
|
+ .
|
|
46
|
+ This package contains the PC/SC shared library.
|
|
47
|
+endef
|
|
48
|
+
|
|
49
|
+define Package/pcscd
|
|
50
|
+ $(call Package/pcsc-lite/Default)
|
|
51
|
+ SECTION:=utils
|
|
52
|
+ CATEGORY:=Utilities
|
|
53
|
+ TITLE+= (daemon)
|
|
54
|
+ DEPENDS:=+libpcsclite
|
|
55
|
+endef
|
|
56
|
+
|
|
57
|
+define Package/pcscd/description
|
|
58
|
+ $(call Package/pcsc-lite/Default/description)
|
|
59
|
+ .
|
|
60
|
+ This package contains the PC/SC daemon.
|
|
61
|
+endef
|
|
62
|
+
|
|
63
|
+TARGET_CFLAGS += $(FPIC)
|
|
64
|
+TARGET_LDFLAGS += -lpthread
|
|
65
|
+
|
|
66
|
+CONFIGURE_ARGS += \
|
|
67
|
+ --disable-libudev \
|
|
68
|
+ --enable-libusb \
|
|
69
|
+ --enable-static \
|
|
70
|
+ --enable-usbdropdir=/usr/lib/pcsc/drivers
|
|
71
|
+
|
|
72
|
+define Build/InstallDev
|
|
73
|
+ $(INSTALL_DIR) $(1)/usr/include/PCSC
|
|
74
|
+ $(CP) $(PKG_INSTALL_DIR)/usr/include/PCSC/* $(1)/usr/include/PCSC/
|
|
75
|
+ $(INSTALL_DIR) $(1)/usr/lib
|
|
76
|
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcsclite.{a,so*} $(1)/usr/lib/
|
|
77
|
+ $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
|
|
78
|
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libpcsclite.pc $(1)/usr/lib/pkgconfig/
|
|
79
|
+endef
|
|
80
|
+
|
|
81
|
+define Package/libpcsclite/install
|
|
82
|
+ $(INSTALL_DIR) $(1)/usr/lib
|
|
83
|
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcsclite.so.* $(1)/usr/lib/
|
|
84
|
+endef
|
|
85
|
+
|
|
86
|
+define Package/pcscd/conffiles
|
|
87
|
+/etc/reader.conf.d/reader.conf
|
|
88
|
+endef
|
|
89
|
+
|
|
90
|
+define Package/pcscd/install
|
|
91
|
+ $(INSTALL_DIR) $(1)/usr/sbin
|
|
92
|
+ $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/pcscd $(1)/usr/sbin/
|
|
93
|
+ $(INSTALL_DIR) $(1)/etc/init.d
|
|
94
|
+ $(INSTALL_BIN) ./files/pcscd.init $(1)/etc/init.d/pcscd
|
|
95
|
+ $(INSTALL_DIR) $(1)/etc/reader.conf.d
|
|
96
|
+endef
|
|
97
|
+
|
|
98
|
+$(eval $(call BuildPackage,libpcsclite))
|
|
99
|
+$(eval $(call BuildPackage,pcscd))
|