diff --git a/security/pcsc-lite/Makefile b/security/pcsc-lite/Makefile index 646b2b3295d..de9a3a701b5 100644 --- a/security/pcsc-lite/Makefile +++ b/security/pcsc-lite/Makefile @@ -1,8 +1,9 @@ -# $OpenBSD: Makefile,v 1.15 2013/01/22 12:07:47 dcoppa Exp $ +# $OpenBSD: Makefile,v 1.16 2013/02/04 09:25:20 dcoppa Exp $ COMMENT= resource manager for PC/SC DISTNAME= pcsc-lite-1.8.8 +REVISION= 0 CATEGORIES= security SHARED_LIBS+= pcsclite 1.0 # 1.0.0 diff --git a/security/pcsc-lite/patches/patch-src_spy_libpcscspy_c b/security/pcsc-lite/patches/patch-src_spy_libpcscspy_c index 65ccca2def5..15b2849f078 100644 --- a/security/pcsc-lite/patches/patch-src_spy_libpcscspy_c +++ b/security/pcsc-lite/patches/patch-src_spy_libpcscspy_c @@ -1,6 +1,10 @@ -$OpenBSD: patch-src_spy_libpcscspy_c,v 1.1 2012/08/06 13:03:12 dcoppa Exp $ ---- src/spy/libpcscspy.c.orig Thu Aug 2 19:26:23 2012 -+++ src/spy/libpcscspy.c Mon Aug 6 09:33:15 2012 +$OpenBSD: patch-src_spy_libpcscspy_c,v 1.2 2013/02/04 09:25:20 dcoppa Exp $ + +Explicitly ignore the result of write(2): even if write(2) fails, +the show must go on (upstream svn revision 6511) + +--- src/spy/libpcscspy.c.orig Sun Aug 5 10:37:37 2012 ++++ src/spy/libpcscspy.c Mon Feb 4 09:53:46 2013 @@ -28,6 +28,7 @@ #include #include @@ -9,21 +13,35 @@ $OpenBSD: patch-src_spy_libpcscspy_c,v 1.1 2012/08/06 13:03:12 dcoppa Exp $ #include "misc.h" #include -@@ -168,7 +169,7 @@ static void spy_line_direct(char *line) +@@ -168,11 +169,11 @@ static void spy_line_direct(char *line) if (Log_fd < 0) return; - snprintf(threadid, sizeof threadid, "%lX@", pthread_self()); + snprintf(threadid, sizeof threadid, "%" PRIXPTR "@", (uintptr_t)pthread_self()); pthread_mutex_lock(&Log_fd_mutex); - write(Log_fd, threadid, strlen(threadid)); - write(Log_fd, line, strlen(line)); -@@ -195,7 +196,7 @@ static void spy_line(const char *fmt, ...) +- write(Log_fd, threadid, strlen(threadid)); +- write(Log_fd, line, strlen(line)); +- write(Log_fd, "\n", 1); ++ (void)write(Log_fd, threadid, strlen(threadid)); ++ (void)write(Log_fd, line, strlen(line)); ++ (void)write(Log_fd, "\n", 1); + pthread_mutex_unlock(&Log_fd_mutex); + } + +@@ -195,11 +196,11 @@ static void spy_line(const char *fmt, ...) printf("libpcsc-spy: Buffer is too small!\n"); return; } - snprintf(threadid, sizeof threadid, "%lX@", pthread_self()); + snprintf(threadid, sizeof threadid, "%" PRIXPTR "@", (uintptr_t)pthread_self()); pthread_mutex_lock(&Log_fd_mutex); - write(Log_fd, threadid, strlen(threadid)); - write(Log_fd, line, size); +- write(Log_fd, threadid, strlen(threadid)); +- write(Log_fd, line, size); +- write(Log_fd, "\n", 1); ++ (void)write(Log_fd, threadid, strlen(threadid)); ++ (void)write(Log_fd, line, size); ++ (void)write(Log_fd, "\n", 1); + pthread_mutex_unlock(&Log_fd_mutex); + } + diff --git a/security/pcsc-lite/pkg/PFRAG.shared b/security/pcsc-lite/pkg/PFRAG.shared deleted file mode 100644 index e1ac8957cd3..00000000000 --- a/security/pcsc-lite/pkg/PFRAG.shared +++ /dev/null @@ -1,3 +0,0 @@ -@comment $OpenBSD: PFRAG.shared,v 1.4 2012/08/06 13:03:12 dcoppa Exp $ -@lib lib/libpcsclite.so.${LIBpcsclite_VERSION} -@lib lib/libpcscspy.so.${LIBpcscspy_VERSION} diff --git a/security/pcsc-lite/pkg/PLIST b/security/pcsc-lite/pkg/PLIST index c44248c2368..802967ecf3a 100644 --- a/security/pcsc-lite/pkg/PLIST +++ b/security/pcsc-lite/pkg/PLIST @@ -1,5 +1,4 @@ -@comment $OpenBSD: PLIST,v 1.4 2012/08/06 13:03:12 dcoppa Exp $ -%%SHARED%% +@comment $OpenBSD: PLIST,v 1.5 2013/02/04 09:25:20 dcoppa Exp $ bin/pcsc-spy include/PCSC/ include/PCSC/debuglog.h @@ -10,8 +9,10 @@ include/PCSC/winscard.h include/PCSC/wintypes.h lib/libpcsclite.a lib/libpcsclite.la +@lib lib/libpcsclite.so.${LIBpcsclite_VERSION} lib/libpcscspy.a lib/libpcscspy.la +@lib lib/libpcscspy.so.${LIBpcscspy_VERSION} lib/pkgconfig/libpcsclite.pc @man man/man1/pcsc-spy.1 @man man/man5/reader.conf.5