Subject: imap-uw suggestion
To: None <tech-pkg@netbsd.org>
From: Louis Guillaume <lguillaume@berklee.edu>
List: tech-pkg
Date: 01/21/2004 01:40:13
I've been patching src/osdep/unix/env_unix.c in the imap-uw package
manually for a while now so that I can specify a "mailsubdir" on my imap
server. Finally I got tired of doing it over and over. This avoids the
users' imap folders ending up in their home directory (which is the
default).
This may not be the best approach in pkgsrc, but here's what I did on
our system and it seems to work ok. Apply this patch and build with
IMAP_UW_MAILSUBDIR="mail" and all imap folders show up in ${HOME}/mail
for each user.
--- Makefile.orig 2004-01-21 05:41:21.000000000 +0000
+++ Makefile 2004-01-21 06:19:35.000000000 +0000
@@ -113,8 +113,15 @@
done
BUILD_DEFS+= IMAP_UW_MAILSPOOLHOME
+BUILD_DEFS+= IMAP_UW_MAILSUBDIR
post-patch:
+.if defined(IMAP_UW_MAILSUBDIR)
+ cd ${WRKSRC}/src/osdep/unix && \
+ ${SED} -e 's|mailsubdir = NIL|mailsubdir =
"${IMAP_UW_MAILSUBDIR}"|' \
+ env_unix.c > env_unix.c.new && \
+ ${MV} -f env_unix.c.new env_unix.c
+.endif
.if defined(IMAP_UW_MAILSPOOLHOME)
cd ${WRKSRC}/src/osdep/unix && \
${SED} -e 's|@SPOOLDIR@|myhomedir ()|' \