Update to the latest release (0.6.14) and take over maintainership as
discussed with Evaldo Gardenali.
This commit is contained in:
parent
c66e9f9dd5
commit
0529ceb620
7 changed files with 80 additions and 24 deletions
|
@ -1,10 +1,10 @@
|
|||
# $NetBSD: Makefile,v 1.8 2006/10/29 08:32:48 shattered Exp $
|
||||
# $NetBSD: Makefile,v 1.9 2008/05/06 13:21:23 htepper Exp $
|
||||
|
||||
DISTNAME= openct-0.6.6
|
||||
DISTNAME= openct-0.6.14
|
||||
CATEGORIES= security
|
||||
MASTER_SITES= http://www.opensc-project.org/files/openct/
|
||||
|
||||
MAINTAINER= evaldo@gardenali.biz
|
||||
MAINTAINER= hasso@estpak.ee
|
||||
HOMEPAGE= http://www.opensc-project.org/openct/
|
||||
COMMENT= Smart Card Reader drivers and middleware
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
@comment $NetBSD: PLIST.common,v 1.2 2005/11/24 02:12:05 udontknow Exp $
|
||||
@comment $NetBSD: PLIST.common,v 1.3 2008/05/06 13:21:23 htepper Exp $
|
||||
bin/openct-tool
|
||||
include/openct/apdu.h
|
||||
include/openct/buffer.h
|
||||
|
@ -10,6 +10,7 @@ include/openct/error.h
|
|||
include/openct/ifd.h
|
||||
include/openct/logging.h
|
||||
include/openct/openct.h
|
||||
include/openct/path.h
|
||||
include/openct/protocol.h
|
||||
include/openct/server.h
|
||||
include/openct/socket.h
|
||||
|
|
|
@ -1,8 +1,2 @@
|
|||
@comment $NetBSD: PLIST.pcsc-lite,v 1.1 2005/07/23 16:31:21 udontknow Exp $
|
||||
lib/openct-ifd.bundle/Contents/Info.plist
|
||||
lib/openct-ifd.bundle/Contents/${OPSYS}/openct-ifd.so
|
||||
lib/openct-ifd.bundle/Contents/PkgInfo
|
||||
@comment $NetBSD: PLIST.pcsc-lite,v 1.2 2008/05/06 13:21:23 htepper Exp $
|
||||
lib/openct-ifd.la
|
||||
@dirrm lib/openct-ifd.bundle/Contents/${OPSYS}
|
||||
@dirrm lib/openct-ifd.bundle/Contents
|
||||
@dirrm lib/openct-ifd.bundle
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: buildlink3.mk,v 1.2 2006/04/06 07:18:13 jeremy-c-reed Exp $
|
||||
# $NetBSD: buildlink3.mk,v 1.3 2008/05/06 13:21:23 htepper Exp $
|
||||
|
||||
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
|
||||
OPENCT_BUILDLINK3_MK:= ${OPENCT_BUILDLINK3_MK}+
|
||||
|
@ -11,7 +11,7 @@ BUILDLINK_PACKAGES:= ${BUILDLINK_PACKAGES:Nopenct}
|
|||
BUILDLINK_PACKAGES+= openct
|
||||
|
||||
.if !empty(OPENCT_BUILDLINK3_MK:M+)
|
||||
BUILDLINK_API_DEPENDS.openct+= openct>=0.6.5
|
||||
BUILDLINK_API_DEPENDS.openct+= openct>=0.6.14
|
||||
BUILDLINK_PKGSRCDIR.openct?= ../../wip/openct
|
||||
.endif # OPENCT_BUILDLINK3_MK
|
||||
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
$NetBSD: distinfo,v 1.2 2005/11/24 02:12:05 udontknow Exp $
|
||||
$NetBSD: distinfo,v 1.3 2008/05/06 13:21:23 htepper Exp $
|
||||
|
||||
SHA1 (openct-0.6.6.tar.gz) = ba1137098e3357863a54aba44a4306567c5141c4
|
||||
RMD160 (openct-0.6.6.tar.gz) = cbeb9b594af1b83e721d550dc8de0a012a782433
|
||||
Size (openct-0.6.6.tar.gz) = 563890 bytes
|
||||
SHA1 (openct-0.6.14.tar.gz) = a4432c69d87310bc653666aa41444703c64ff024
|
||||
RMD160 (openct-0.6.14.tar.gz) = bf7bf2b711b8e7d365749d36593114aba2fecf6d
|
||||
Size (openct-0.6.14.tar.gz) = 670510 bytes
|
||||
SHA1 (patch-aa) = b3a8e640a0264ceda656397add19b3eb62ad0373
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: options.mk,v 1.4 2005/11/24 02:12:05 udontknow Exp $
|
||||
# $NetBSD: options.mk,v 1.5 2008/05/06 13:21:23 htepper Exp $
|
||||
|
||||
PKG_OPTIONS_VAR= PKG_OPTIONS.openct
|
||||
PKG_SUPPORTED_OPTIONS= pcsc-lite usb
|
||||
|
@ -6,7 +6,7 @@ PKG_SUPPORTED_OPTIONS= pcsc-lite usb
|
|||
.include "../../mk/bsd.options.mk"
|
||||
|
||||
.if !empty(PKG_OPTIONS:Mpcsc-lite)
|
||||
.include "../../wip/pcsc-lite/buildlink3.mk"
|
||||
.include "../../security/pcsc-lite/buildlink3.mk"
|
||||
CONFIGURE_ARGS+= --with-pcsclite
|
||||
PLIST_SRC+= ${PKGDIR}/PLIST.pcsc-lite
|
||||
.else
|
||||
|
|
60
openct/patches/patch-aa
Normal file
60
openct/patches/patch-aa
Normal file
|
@ -0,0 +1,60 @@
|
|||
Index: src/ifd/sys-bsd.c
|
||||
===================================================================
|
||||
--- src/ifd/sys-bsd.c (revision 1032)
|
||||
+++ src/ifd/sys-bsd.c (working copy)
|
||||
@@ -13,7 +13,11 @@
|
||||
#include "internal.h"
|
||||
#if defined(__NetBSD__) || defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__)
|
||||
#include <sys/types.h>
|
||||
+#if defined(__DragonFly__)
|
||||
+#include <bus/usb/usb.h>
|
||||
+#else
|
||||
#include <dev/usb/usb.h>
|
||||
+#endif
|
||||
#include <sys/stat.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/poll.h>
|
||||
@@ -91,14 +95,28 @@
|
||||
int direction =
|
||||
(ep & IFD_USB_ENDPOINT_DIR_MASK) == IFD_USB_ENDPOINT_IN ? 1 : 0;
|
||||
int endpoint = (ep & ~IFD_USB_ENDPOINT_DIR_MASK);
|
||||
+ int one = 1;
|
||||
+ int ret;
|
||||
|
||||
ct_debug("ifd_sysdep_usb_bulk: endpoint=%d direction=%d", endpoint,
|
||||
direction);
|
||||
- if (open_ep(dev->name, 0, endpoint, O_RDWR | O_NONBLOCK)) {
|
||||
+
|
||||
+ if (direction)
|
||||
+ ret = open_ep(dev->name, 0, endpoint, O_RDONLY | O_NONBLOCK);
|
||||
+ else
|
||||
+ ret = open_ep(dev->name, 0, endpoint, O_WRONLY | O_NONBLOCK);
|
||||
+
|
||||
+ if (ret) {
|
||||
ct_debug("ifd_sysdep_usb_bulk: opening endpoint failed");
|
||||
return -1;
|
||||
}
|
||||
if (direction) {
|
||||
+ if (ioctl(interfaces[0][endpoint].ep_fd, USB_SET_SHORT_XFER,
|
||||
+ &one) < 0) {
|
||||
+ ifd_debug(6, "ifd_sysdep_usb_bulk: USB_SET_SHORT_XFER"
|
||||
+ " failed: %s", strerror(errno));
|
||||
+ ct_error("usb_bulk read failed: %s", strerror(errno));
|
||||
+ }
|
||||
if ((bytes_to_process =
|
||||
read(interfaces[0][endpoint].ep_fd, buffer, len)) < 0) {
|
||||
ifd_debug(6, "ifd_sysdep_usb_bulk: read failed: %s",
|
||||
@@ -204,7 +222,12 @@
|
||||
(cap->endpoint & IFD_USB_ENDPOINT_DIR_MASK) ==
|
||||
IFD_USB_ENDPOINT_IN ? 1 : 0;
|
||||
int endpoint = (cap->endpoint & ~IFD_USB_ENDPOINT_DIR_MASK);
|
||||
- close_ep(0, endpoint);
|
||||
+ /*
|
||||
+ * Keep interrupt endpoint open. Open/close dance leads us to lost
|
||||
+ * events for some reason.
|
||||
+ *
|
||||
+ * close_ep(0, endpoint);
|
||||
+ */
|
||||
if (cap)
|
||||
free(cap);
|
||||
return 0;
|
Loading…
Reference in a new issue