(sending again, as it didn't seem to get through... sorry if it does and causes double) While reading about Kerberos I noticed that among software supporting it Dovecot, so I decided to have a look at it. But it's configuring without support for Kerberos, even though it's in base system... So here's a small patch that at the very least makes it configure with GSSAPI support. It builds with this patch on i386, though configure spits out a warning... And that's the only thing I was able to test. So please have a look at this, say whether it's something that is good to have, or whether it's entirely broken and has no chance of working. -- viq
Index: Makefile =================================================================== RCS file: /cvs/ports/mail/dovecot/Makefile,v retrieving revision 1.39 diff -u -d -r1.39 Makefile --- Makefile 16 Apr 2006 06:59:29 -0000 1.39 +++ Makefile 7 May 2006 23:24:32 -0000 @@ -16,7 +16,7 @@ PERMIT_PACKAGE_FTP= Yes PERMIT_DISTFILES_CDROM= Yes PERMIT_DISTFILES_FTP= Yes -WANTLIB= c crypto ssl z +WANTLIB= c crypto ssl z krb5 gssapi crypto asn1 MODULES= converters/libiconv @@ -44,6 +44,8 @@ CONFIGURE_STYLE= autoconf AUTOCONF_VERSION= 2.59 CONFIGURE_ARGS+=--localstatedir=/var \ + --with-gssapi \ + --with-pic \ # --with-ioloop=kqueue \ # --with-notify=kqueue \ --with-ssl=openssl \ @@ -53,6 +55,10 @@ --without-vpopmail CONFIGURE_ENV= CFLAGS="${CFLAGS} -I${LOCALBASE}/include" \ LDFLAGS="-L${LOCALBASE}/lib" + +post-extract: + cp ${FILESDIR}/krb5-config ${WRKDIR}/bin + chmod a+x ${WRKDIR}/bin/krb5-config pre-build: @perl -pi -e s#_PREFIX_#\${PREFIX}#g ${WRKSRC}/dovecot-example.conf Index: files/krb5-config =================================================================== RCS file: files/krb5-config diff -N files/krb5-config --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ files/krb5-config 7 May 2006 23:55:20 -0000 @@ -0,0 +1,11 @@ +#! /bin/sh + +case x$1 in +x--libs) + echo '-lgssapi -lkrb5 -lasn1 -lcrypto';; +x--cflags) + echo '-I/usr/include/kerberosV';; +x--version) + echo 'heimdal';; +esac +exit 0 Index: patches/patch-configure_in =================================================================== RCS file: /cvs/ports/mail/dovecot/patches/patch-configure_in,v retrieving revision 1.9 diff -u -d -r1.9 patch-configure_in --- patches/patch-configure_in 16 Jan 2006 21:32:59 -0000 1.9 +++ patches/patch-configure_in 7 May 2006 23:24:34 -0000 @@ -1,6 +1,6 @@ $OpenBSD: patch-configure_in,v 1.9 2006/01/16 21:32:59 brad Exp $ ---- configure.in.orig Sun Jan 15 14:47:43 2006 -+++ configure.in Sun Jan 15 17:09:45 2006 +--- configure.in.orig Wed Apr 12 13:27:25 2006 ++++ configure.in Mon May 8 01:23:05 2006 @@ -12,6 +12,7 @@ AC_PROG_CPP AC_HEADER_STDC AC_C_INLINE @@ -9,3 +9,12 @@ AM_ICONV AC_CHECK_HEADERS(strings.h stdint.h unistd.h dirent.h \ +@@ -1366,7 +1367,7 @@ if test $want_gssapi = yes; then + # have gssapi.h + old_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS `krb5-config --cflags gssapi`" +- AC_CHECK_HEADER([gssapi/gssapi.h], [ ++ AC_CHECK_HEADER([gssapi.h], [ + AC_DEFINE(HAVE_GSSAPI,, Build with GSSAPI support) + have_gssapi=yes + ]) Index: patches/patch-src_auth_mech-gssapi_c =================================================================== RCS file: patches/patch-src_auth_mech-gssapi_c diff -N patches/patch-src_auth_mech-gssapi_c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ patches/patch-src_auth_mech-gssapi_c 7 May 2006 23:24:57 -0000 @@ -0,0 +1,12 @@ +$OpenBSD$ +--- src/auth/mech-gssapi.c.orig Mon May 8 01:23:43 2006 ++++ src/auth/mech-gssapi.c Mon May 8 01:23:56 2006 +@@ -27,7 +27,7 @@ + + #ifdef HAVE_GSSAPI + +-#include <gssapi/gssapi.h> ++#include <gssapi.h> + + /* Non-zero flags defined in RFC 2222 */ + enum sasl_gssapi_qop {