We actually have SO_PEERCRED, so why not use it?
I've also bumped SHARED_LIBS minor number: is this correct?
ciao,
David
Index: Makefile
===================================================================
RCS file: /cvs/ports/security/libassuan/Makefile,v
retrieving revision 1.5
diff -u -p -r1.5 Makefile
--- Makefile 19 Aug 2010 12:54:14 -0000 1.5
+++ Makefile 14 Oct 2010 09:38:05 -0000
@@ -3,8 +3,8 @@
COMMENT= IPC library used by GnuPG and gpgme
DISTNAME= libassuan-2.0.1
-
-SHARED_LIBS += assuan 0.1 # 1.0
+REVISION= 0
+SHARED_LIBS += assuan 0.2 # 1.0
CATEGORIES= security devel
@@ -23,7 +23,8 @@ USE_LIBTOOL= Yes
MODULES= devel/gettext \
textproc/intltool
-LIB_DEPENDS= gpg-error::security/libgpg-error
+WANTLIB= gpg-error
+LIB_DEPENDS= ::security/libgpg-error
CONFIGURE_STYLE= gnu
Index: patches/patch-configure
===================================================================
RCS file: patches/patch-configure
diff -N patches/patch-configure
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-configure 14 Oct 2010 09:38:05 -0000
@@ -0,0 +1,17 @@
+$OpenBSD$
+--- configure.orig Mon Aug 9 12:33:37 2010
++++ configure Thu Oct 14 11:29:50 2010
+@@ -13333,11 +13333,12 @@ if test "${assuan_cv_sys_so_peercred+set}" = set;
then
+ else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
++#include <sys/types.h>
+ #include <sys/socket.h>
+ int
+ main ()
+ {
+-struct ucred cr;
++struct sockpeercred cr;
+ int cl = sizeof cr;
+ getsockopt (1, SOL_SOCKET, SO_PEERCRED, &cr, &cl);
+ ;
Index: patches/patch-src_assuan-socket-server_c
===================================================================
RCS file: patches/patch-src_assuan-socket-server_c
diff -N patches/patch-src_assuan-socket-server_c
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-src_assuan-socket-server_c 14 Oct 2010 09:38:05 -0000
@@ -0,0 +1,12 @@
+$OpenBSD$
+--- src/assuan-socket-server.c.orig Thu Oct 14 11:26:27 2010
++++ src/assuan-socket-server.c Thu Oct 14 11:27:15 2010
+@@ -51,7 +51,7 @@ accept_connection_bottom (assuan_context_t ctx)
+ ctx->peercred_valid = 0;
+ #ifdef HAVE_SO_PEERCRED
+ {
+- struct ucred cr;
++ struct sockpeercred cr;
+ socklen_t cl = sizeof cr;
+
+ if ( !getsockopt (fd, SOL_SOCKET, SO_PEERCRED, &cr, &cl))