diff options
-rw-r--r-- | devel/pcsc-lite/Makefile | 9 | ||||
-rw-r--r-- | devel/pcsc-lite/distinfo | 6 | ||||
-rw-r--r-- | devel/pcsc-lite/files/patch-pcscdaemon.c | 17 | ||||
-rw-r--r-- | devel/pcsc-lite/files/patch-winscard_msg_srv.c | 33 | ||||
-rw-r--r-- | devel/pcsc-lite/files/pcscd.in | 20 | ||||
-rw-r--r-- | devel/pcsc-lite/files/pcscd.sh | 29 | ||||
-rw-r--r-- | devel/pcsc-lite/pkg-plist | 3 |
7 files changed, 77 insertions, 40 deletions
diff --git a/devel/pcsc-lite/Makefile b/devel/pcsc-lite/Makefile index b92184fc311c..e966b4304ecd 100644 --- a/devel/pcsc-lite/Makefile +++ b/devel/pcsc-lite/Makefile @@ -6,10 +6,10 @@ # PORTNAME= pcsc-lite -PORTVERSION= 1.3.2 +PORTVERSION= 1.3.3 PORTEPOCH= 2 CATEGORIES= devel security -MASTER_SITES= http://alioth.debian.org/frs/download.php/1738/ +MASTER_SITES= http://alioth.debian.org/frs/download.php/1869/ DISTNAME= pcsc-lite-${PORTVERSION:S/.b./-beta/} MAINTAINER= arved@FreeBSD.org @@ -18,6 +18,7 @@ COMMENT= A smartcard development library GNU_CONFIGURE= yes USE_GMAKE= yes USE_GNOME= gnomehack pkgconfig +USE_RC_SUBR= pcscd USE_LDCONFIG= yes CONFIGURE_ENV+= LIBS="${LIBS} ${PTHREAD_LIBS}" \ @@ -36,7 +37,7 @@ USE_GETOPT_LONG=yes PKGMESSAGE= ${WRKDIR}/pkg-message MAN1= formaticc.1 MAN5= reader.conf.5 -MAN8= pcscd.8 +MAN8= pcscd.8 update-reader.conf.8 .if !defined(WITHOUT_USB) LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb @@ -72,8 +73,6 @@ post-install: ${TOUCH} ${PREFIX}/lib/pcsc/services/.keep_me ${INSTALL_DATA} ${WRKSRC}/etc/reader.conf \ ${PREFIX}/etc/reader.conf.sample - ${INSTALL_SCRIPT} ${FILESDIR}/pcscd.sh \ - ${PREFIX}/etc/rc.d/pcscd.sh.sample @${SED} 's,%%PREFIX%%,${PREFIX},g' < ${FILESDIR}/pkg-message.in > \ ${WRKDIR}/pkg-message @${CAT} ${PKGMESSAGE} diff --git a/devel/pcsc-lite/distinfo b/devel/pcsc-lite/distinfo index d2655cd27c09..de3d1c5a7459 100644 --- a/devel/pcsc-lite/distinfo +++ b/devel/pcsc-lite/distinfo @@ -1,3 +1,3 @@ -MD5 (pcsc-lite-1.3.2.tar.gz) = e9c8e5aa82e1710186ff31e4ff096888 -SHA256 (pcsc-lite-1.3.2.tar.gz) = 5311b77b029f9b185717876a34826eeaf0b2290f2628ba3b3a01bc0684aea72e -SIZE (pcsc-lite-1.3.2.tar.gz) = 854806 +MD5 (pcsc-lite-1.3.3.tar.gz) = 851b090aa0efedd0196f6afd9c0c61bb +SHA256 (pcsc-lite-1.3.3.tar.gz) = 8f3a565b13760e9e05ffff1944755f8651e105069fda96d56e8ae64ae17365f7 +SIZE (pcsc-lite-1.3.3.tar.gz) = 859571 diff --git a/devel/pcsc-lite/files/patch-pcscdaemon.c b/devel/pcsc-lite/files/patch-pcscdaemon.c new file mode 100644 index 000000000000..83a76a03b7fa --- /dev/null +++ b/devel/pcsc-lite/files/patch-pcscdaemon.c @@ -0,0 +1,17 @@ +--- src/pcscdaemon.c.orig Mon Jan 22 16:31:21 2007 ++++ src/pcscdaemon.c Mon Jan 22 16:33:52 2007 +@@ -199,6 +199,14 @@ + switch (rsp = SHMProcessEventsServer(&dwClientID, 0)) + { + ++ case 2: ++ /* /* ++ * timeout in SHMProcessEventsServer(): do nothing ++ * this is used to catch the Ctrl-C signal at some time when ++ * nothing else happens ++ */ ++ break; ++ + case 0: + Log2(PCSC_LOG_DEBUG, "A new context thread creation is requested: %d", dwClientID); + rv = CreateContextThread(&dwClientID); diff --git a/devel/pcsc-lite/files/patch-winscard_msg_srv.c b/devel/pcsc-lite/files/patch-winscard_msg_srv.c new file mode 100644 index 000000000000..0a5c681cb6ca --- /dev/null +++ b/devel/pcsc-lite/files/patch-winscard_msg_srv.c @@ -0,0 +1,33 @@ +--- src/winscard_msg_srv.c.orig Mon Jan 22 16:26:53 2007 ++++ src/winscard_msg_srv.c Mon Jan 22 16:29:52 2007 +@@ -169,6 +169,10 @@ + { + fd_set read_fd; + int selret; ++ struct timeval tv; ++ ++ tv.tv_sec = 1; ++ tv.tv_usec = 0; + + FD_ZERO(&read_fd); + +@@ -178,7 +182,7 @@ + FD_SET(commonSocket, &read_fd); + + selret = select(commonSocket + 1, &read_fd, (fd_set *) NULL, +- (fd_set *) NULL, NULL); ++ (fd_set *) NULL, &tv); + + if (selret < 0) + { +@@ -189,6 +193,10 @@ + strerror(errno)); + return -1; + } ++ ++ if (selret == 0) ++ /* timeout */ ++ return 2; + + /* + * A common pipe packet has arrived - it could be a new application diff --git a/devel/pcsc-lite/files/pcscd.in b/devel/pcsc-lite/files/pcscd.in new file mode 100644 index 000000000000..f5ff87d3151e --- /dev/null +++ b/devel/pcsc-lite/files/pcscd.in @@ -0,0 +1,20 @@ +#!/bin/sh +# +# $FreeBSD$ +# +# PROVIDE: pcscd +# REQUIRE: LOGIN +# Add the following lines to /etc/rc.conf.local or /etc/rc.conf +# to enable this service: +# +# pcscd_enable="YES" + +. %%RC_SUBR%% + +name="pcscd" +rcvar="pcscd_enable" + +command="%%PREFIX%%/sbin/pcscd" + +load_rc_config "$name" +run_rc_command "$1" diff --git a/devel/pcsc-lite/files/pcscd.sh b/devel/pcsc-lite/files/pcscd.sh deleted file mode 100644 index 716484f434c0..000000000000 --- a/devel/pcsc-lite/files/pcscd.sh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh -# $FreeBSD$ - -if ! PREFIX=$(expr $0 : "\(/.*\)/etc/rc\.d/$(basename $0)\$"); then - echo "$0: Cannot determine the PREFIX" >&2 - exit 1 -fi - -case "$1" in - - start) - if [ -x $PREFIX/sbin/pcscd ]; then - $PREFIX/sbin/pcscd -c $PREFIX/etc/reader.conf - echo -n ' pcscd' - fi - ;; - - stop) - /usr/bin/killall pcscd && echo -n ' pcscd' - ;; - - *) - echo "" - echo "Usage: `basename $0` { start | stop }" - echo "" - exit 64 - ;; -esac - diff --git a/devel/pcsc-lite/pkg-plist b/devel/pcsc-lite/pkg-plist index e6ba29bb87cf..96b202db4384 100644 --- a/devel/pcsc-lite/pkg-plist +++ b/devel/pcsc-lite/pkg-plist @@ -1,5 +1,3 @@ -bin/formaticc -etc/rc.d/pcscd.sh.sample etc/reader.conf.sample include/PCSC/debuglog.h include/PCSC/ifdhandler.h @@ -13,7 +11,6 @@ lib/libpcsclite.so.1 lib/pcsc/drivers/.keep_me lib/pcsc/services/.keep_me libdata/pkgconfig/libpcsclite.pc -sbin/installifd sbin/pcscd sbin/update-reader.conf %%PORTDOCS%%%%DOCSDIR%%/README.DAEMON |