New port: mail/cclient

PR:		19691
Submitted by:	Kelly Yancey
Reviewed by:	will
This commit is contained in:
Kelly Yancey 2000-07-14 09:27:33 +00:00
parent 207dfe2107
commit 6e041d5a54
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=30603
9 changed files with 263 additions and 0 deletions

69
mail/cclient/Makefile Normal file
View file

@ -0,0 +1,69 @@
# New ports collection makefile for: cclient
# Date created: 2 July 2000
# Whom: Kelly Yancey <kbyanc@posi.net>
#
# $FreeBSD$
#
PORTNAME= cclient
PORTVERSION= 4.7c
CATEGORIES= mail devel
MASTER_SITES= ftp://ftp.cac.washington.edu/imap/ \
ftp://ftp.funet.fi/pub/mirrors/ftp.cac.washington.edu/mail/ \
http://mirror.nucba.ac.jp/mirror/imap/ \
ftp://ftp.uni-halle.de/pub/mail/pine/
DISTNAME= imap-${PORTVERSION}2
EXTRACT_SUFX= .tar.Z
MAINTAINER= kbyanc@posi.net
WRKSRC= ${WRKDIR}/imap-${PORTVERSION}
INSTALLS_SHLIB= yes
PAMAUTH?= yes
.if ${PAMAUTH} != "no"
ALL_TARGET= bfp
.else
ALL_TARGET= bsf
.endif
SHLIBBASE= c-client4
SHLIBMAJ= 7
SHLIBNAME= lib${SHLIBBASE}.so.${SHLIBMAJ}
MAKE_ENV= SHLIBNAME=${SHLIBNAME} SHLIBBASE=${SHLIBBASE}
PLIST_SUB= SHLIBNAME=${SHLIBNAME} SHLIBBASE=${SHLIBBASE}
.include <bsd.port.pre.mk>
.if ${PORTOBJFORMAT} == "aout"
SHLIBNAME= lib${SHLIBBASE}.so.${SHLIBMAJ}.0
.endif
post-configure:
@${ECHO_MSG} ">> The c-client shared library will be named ${SHLIBNAME}"
.if ${PAMAUTH} != "no"
@${ECHO_MSG} ">> Building with PAM support"
@${ECHO_MSG} ">> You can disable PAM support building with \"PAMAUTH=no\""
.endif
HEADERS= dummy.h env.h env_unix.h fdstring.h flstring.h fs.h ftl.h \
imap4r1.h linkage.c linkage.h mail.h misc.h nl.h nntp.h \
osdep.h pop3.h rfc822.h smtp.h tcp.h
do-install:
${MKDIR} ${PREFIX}/include/c-client
.for f in ${HEADERS}
${INSTALL_DATA} ${WRKSRC}/c-client/${f} ${PREFIX}/include/c-client
.endfor
${INSTALL} ${COPY} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \
${WRKSRC}/c-client/${SHLIBNAME} ${PREFIX}/lib
${LN} -sf ${SHLIBNAME} ${PREFIX}/lib/lib${SHLIBBASE}.so
${INSTALL_DATA} ${WRKSRC}/c-client/c-client.a \
${PREFIX}/lib/lib${SHLIBBASE}.a
post-install:
.if ${PAMAUTH} != "no"
@${CAT} ${FILESDIR}/MESSAGE.PAM
.endif
.include <bsd.port.post.mk>

2
mail/cclient/distinfo Normal file
View file

@ -0,0 +1,2 @@
MD5 (imap-4.7c2.tar.Z) = 1a27c7684094a8c94baf294552467060
MD5 (pine-4.20-maildir_3.patch) = 2f6cd0ed750321d074cc53171d308291

View file

@ -0,0 +1,9 @@
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
PAM authentication support is now compiled in by default; you may need to add
the following lines to /etc/pam.conf:
imap auth required pam_unix.so try_first_pass
imap account required pam_unix.so try_first_pass
pop auth required pam_unix.so try_first_pass
pop account required pam_unix.so try_first_pass
= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =

View file

@ -0,0 +1,21 @@
--- src/osdep/unix/os_bsi.h.orig Sat Oct 19 20:30:04 1996
+++ src/osdep/unix/os_bsi.h Sun May 24 10:46:33 1998
@@ -37,7 +37,18 @@
#include <unistd.h>
#include <string.h>
#include <sys/types.h>
+
+/*
+ * FreeBSD v3.x and onward whines about <sys/dir.h> being obsolete, so switch
+ * to POSIX semantics.
+ */
+#if __FreeBSD__ >= 3
+#include <dirent.h>
+#define direct dirent
+#else
#include <sys/dir.h>
+#endif
+
#include <fcntl.h>
#include <syslog.h>
#include <sys/file.h>

113
mail/cclient/files/patch-ab Normal file
View file

@ -0,0 +1,113 @@
--- src/osdep/unix/Makefile.orig Mon Jul 3 22:32:37 2000
+++ src/osdep/unix/Makefile Mon Jul 3 22:33:30 2000
@@ -86,7 +86,7 @@
# Commands possibly overriden by the individual port
ARRC=ar rc
-CC=cc
+#CC=cc
LN=ln -s
RANLIB=ranlib
@@ -104,7 +104,7 @@
dummy.o pseudo.o netmsg.o flstring.o fdstring.o \
rfc822.o nntp.o smtp.o imap4r1.o pop3.o \
unix.o mbox.o mbx.o mmdf.o tenex.o mtx.o news.o phile.o mh.o mx.o
-CFLAGS=$(BASECFLAGS) $(EXTRACFLAGS)
+CFLAGS+=$(BASECFLAGS) $(EXTRACFLAGS)
MAKE=make
MV=mv
RM=rm -rf
@@ -119,6 +119,10 @@
PASSWDTYPE=$(PASSWDTYPE) SPECIALAUTHENTICATORS="$(SPECIALAUTHENTICATORS)"
BUILD=$(MAKE) build $(BUILDOPTIONS)
+# Need this for the shared library rule to work correctly
+.SUFFIXES: .o .so
+SOFILES=${BINARIES:.o=.so}
+
# Here if no make argument established
missing: osdep.h
@@ -178,6 +182,15 @@
BASECFLAGS="-g -B/usr/lib/big/ -Dvoid=char -Dconst= -DNFSKLUDGE" \
RANLIB=true ARRC="ar -rc"
+bfp: # FreeBSD Pluggable Authentication Modules
+ $(BUILD) `cat EXTRASPECIALS` OS=bsi SIGTYPE=psx CHECKPW=pam \
+ SPOOLDIR=/var \
+ ACTIVEFILE=/usr/local/news/lib/active \
+ RSHPATH=/usr/bin/rsh \
+ LOCKPGM=$(PREFIX)/libexec/mlock \
+ BASECFLAGS="-DNFSKLUDGE" \
+ BASELDFLAGS="-lpam -lcrypt"
+
bs3: # BSD/i386 3.0 or higher
$(BUILD) `cat EXTRASPECIALS` OS=bsi CHECKPW=bsi LOGINPW=bsi \
SPOOLDIR=/var NEWSSPOOL=/var/news/spool \
@@ -194,7 +207,8 @@
SPOOLDIR=/var \
ACTIVEFILE=/usr/local/news/lib/active \
RSHPATH=/usr/bin/rsh \
- BASECFLAGS="-g -O -pipe -DNFSKLUDGE" \
+ LOCKPGM=$(PREFIX)/libexec/mlock \
+ BASECFLAGS="-DNFSKLUDGE" \
BASELDFLAGS="-lcrypt"
bsi: # BSD/i386
@@ -627,19 +641,31 @@
# Build it!
-build: clean once $(ARCHIVE)
+build: clean once $(ARCHIVE) $(SHLIBNAME)
-all: $(ARCHIVE)
+all: $(ARCHIVE) $(SHLIBNAME)
$(ARCHIVE): $(BINARIES)
sh -c '$(RM) $(ARCHIVE) || true'
@cat ARCHIVE
@$(SH) ARCHIVE
+$(SHLIBNAME): $(SOFILES)
+.if $(PORTOBJFORMAT) == "elf"
+ ld -shared -x -soname $(SHLIBNAME) -o $(SHLIBNAME) $(SOFILES)
+.else
+ ld -Bshareable -x -o $(SHLIBNAME) $(SOFILES)
+.endif
+ ln -s $(SHLIBNAME) lib$(SHLIBBASE).so
+
+.c.so: osdep.h
+ $(CC) -fpic -DPIC -c $(CFLAGS) ${@:.so=.c} -o $@
+
# Cleanup
clean:
sh -c '$(RM) auths.c flockbsd.c linkage.[ch] siglocal.c osdep*.[ch] *.o ARCHIVE *FLAGS *TYPE $(ARCHIVE) || true'
+ $(RM) *.so $(SHLIBNAME)
# Dependencies
@@ -673,7 +699,7 @@
# OS-dependent
-osdep.o:mail.h misc.h env.h fs.h ftl.h nl.h tcp.h \
+OSDEPS= mail.h misc.h env.h fs.h ftl.h nl.h tcp.h \
osdep.h env_unix.h tcp_unix.h \
osdep.c env_unix.c fs_unix.c ftl_unix.c nl_unix.c tcp_unix.c \
auths.c flock.c flockbsd.c flcksafe.c fsync.c gethstid.c \
@@ -685,7 +711,12 @@
write.c \
strerror.c strpbrk.c strstr.c strtok.c strtoul.c \
OSCFLAGS
+
+osdep.o: $(OSDEPS)
$(CC) $(CFLAGS) `cat OSCFLAGS` -c osdep.c
+
+osdep.so: $(OSDEPS)
+ $(CC) -fpic -DPIC -c $(CFLAGS) `cat OSCFLAGS` osdep.c -o $@
osdep.c: osdepbas.c osdepckp.c osdeplog.c
cat osdepbas.c osdepckp.c osdeplog.c > osdep.c

View file

@ -0,0 +1,19 @@
--- Makefile.orig Mon Nov 15 22:20:34 1999
+++ Makefile Sun Dec 19 14:52:58 1999
@@ -49,6 +49,7 @@
# art AIX 2.2.1 for RT
# asv Altos SVR4
# aux A/UX
+# bfp FreeBSD with Pluggable Authentication Modules (PAM)
# bs3 BSD/i386 3.0 and higher
# bsd generic BSD 4.3 (as in ancient 1980s version)
# bsf FreeBSD
@@ -293,7 +294,7 @@
# Note on SCO you may have to set LN to "ln".
-a32 a41 aix bs3 bsf bsi bso d-g d54 do4 drs epx gas gh9 ghp gs5 gso gsu gul hpp hpx lnp lyn mct mnt neb nxt nx3 osf os4 ptx qnx sc5 sco sgi sg6 shp sl4 sl5 slx snx sol sos uw2: an
+a32 a41 aix bfp bs3 bsf bsi bso d-g d54 do4 drs epx gas gh9 ghp gs5 gso gsu gul hpp hpx lnp lyn mct mnt neb nxt nx3 osf os4 ptx qnx sc5 sco sgi sg6 shp sl4 sl5 slx snx sol sos uw2: an
$(BUILD) OS=$@
# If you use sv4, you may find that it works to move it to use the an process.

1
mail/cclient/pkg-comment Normal file
View file

@ -0,0 +1 @@
Mark Crispen's C-client mail access routines

6
mail/cclient/pkg-descr Normal file
View file

@ -0,0 +1,6 @@
C-client is a common API for accessing mailboxes. It is used internally by
the popular PINE mail reader as well as the University of Washington's IMAP
server.
-Kelly
kbyanc@posi.net

23
mail/cclient/pkg-plist Normal file
View file

@ -0,0 +1,23 @@
include/c-client/dummy.h
include/c-client/env.h
include/c-client/env_unix.h
include/c-client/fdstring.h
include/c-client/flstring.h
include/c-client/fs.h
include/c-client/ftl.h
include/c-client/imap4r1.h
include/c-client/linkage.c
include/c-client/linkage.h
include/c-client/mail.h
include/c-client/misc.h
include/c-client/nl.h
include/c-client/nntp.h
include/c-client/osdep.h
include/c-client/pop3.h
include/c-client/rfc822.h
include/c-client/smtp.h
include/c-client/tcp.h
lib/libc-client4.a
lib/libc-client4.so.7
lib/libc-client4.so
@dirrm include/c-client