ports/53401: mail/qpopper: add knob WITHOUT_APOP, bring OpenSSL-support up to date, cleanup

Marius Strobl marius at alchemy.franken.de
Tue Jun 17 11:00:35 UTC 2003


>Number:         53401
>Category:       ports
>Synopsis:       mail/qpopper: add knob WITHOUT_APOP, bring OpenSSL-support up to date, cleanup
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Jun 17 04:00:33 PDT 2003
>Closed-Date:
>Last-Modified:
>Originator:     Marius Strobl
>Release:        FreeBSD 5.1-BETA sparc64
>Organization:
>Environment:
System: FreeBSD alchemy.franken.de 5.1-BETA FreeBSD 5.1-BETA #0: Thu May 29 14:55:16 CEST 2003 marius at alchemy.franken.de:/tmp/sys/sparc64/compile/alchemy sparc64
>Description:
	Below is a patch for the mail/qpopper port that does the following:

	- Add a knob WITHOUT_APOP for configurations where the apop-feature is
	  in the way.
	- Update OpenSSL-support, include security/openssl/bsd.openssl.mk,
	  remove usage of deprecated librsaref/libRSAglue, add a knob
	  WITHOUT_SSL.
	- Move MAINTAINER and COMMENT arround to make portlint happier (1 error,	  16 warnings versus 0 errors, 10 warnings).
	- Terminate all sentences in comments with a period.
	- Replace spaces with tabs in pre-everything:: messages to print out
	  an aligned table.
>How-To-Repeat:
>Fix:

Index: Makefile
===================================================================
RCS file: /usr/jail/217.24.217.12/usr/data/bsd/cvs/fbsd/ports/mail/qpopper/Makefile,v
retrieving revision 1.75
diff -u -r1.75 Makefile
--- Makefile	29 Apr 2003 23:05:40 -0000	1.75
+++ Makefile	22 May 2003 06:02:56 -0000
@@ -13,6 +13,9 @@
 MASTER_SITE_SUBDIR=	. old
 DISTNAME=	${PORTNAME}${PORTVERSION}
 
+MAINTAINER=	lioux at FreeBSD.org
+COMMENT=	Berkeley POP 3 server (now maintained by Qualcomm)
+
 .include <bsd.port.pre.mk>
 
 .if ${OSVERSION} >= 400014 && !defined(WITHOUT_IPV6)
@@ -21,26 +24,23 @@
 PATCH_DIST_STRIP=	-p1
 .endif
 
-MAINTAINER=	lioux at FreeBSD.org
-COMMENT=	Berkeley POP 3 server (now maintained by Qualcomm)
-
 USE_AUTOCONF=	yes
 USE_REINPLACE=	yes
 GNU_CONFIGURE=	yes
 CONFIGURE_ENV=	LIBS="-lcrypt -lmd -lutil -L${LOCALBASE}/lib" \
 		OS_DEFS="-DSETPROCTITLE ${OS_DEFS}"
-CONFIGURE_ARGS=	--enable-apop=${PREFIX}/etc/qpopper/pop.auth \
-		--enable-nonauth-file=${POPUSERS_FILE} \
-		--with-apopuid=pop --without-gdbm \
+CONFIGURE_ARGS=	--enable-nonauth-file=${POPUSERS_FILE} \
+		--without-gdbm \
 		--enable-keep-temp-drop
 
 PLIST_SUB=	EPOPPASSD=${EPOPPASSD} \
 		POP_USER=${POP_USER} \
 		POP_GROUP=${POP_GROUP} \
 		POP_MODE_DIR=${POP_MODE_DIR} \
-		POP_MODE_CONF=${POP_MODE_CONF}
+		POP_MODE_CONF=${POP_MODE_CONF} \
+		QPOPAUTH=${QPOPAUTH}
 
-MAN8=		qpopauth.8 qpopper.8
+MAN8=		qpopper.8
 
 # internal configuration
 POP_USER=	pop
@@ -68,50 +68,60 @@
 	@${ECHO_MSG} ""
 	@${ECHO_MSG} "You may use the following build options:"
 	@${ECHO_MSG} ""
-	@${ECHO_MSG} "WITH_APOP_ONLY=yes	builds with APOP authentication only"
-	@${ECHO_MSG} "WITH_DOCUMENTATION=yes	installs pdf documentation"
-	@${ECHO_MSG} "WITH_DRAC=yes		builds with Dynamic Relay Authorization"
+	@${ECHO_MSG} "WITH_APOP_ONLY=yes		builds with APOP authentication only"
+	@${ECHO_MSG} "WITHOUT_APOP=yes		builds without APOP authentication"
+	@${ECHO_MSG} "WITH_DOCUMENTATION=yes		installs pdf documentation"
+	@${ECHO_MSG} "WITH_DRAC=yes			builds with Dynamic Relay Authorization"
 	@${ECHO_MSG} "				Control support"
-	@${ECHO_MSG} "WITHOUT_IPV6=yes          builds without IPv6 support"
+	@${ECHO_MSG} "WITHOUT_IPV6=yes		builds without IPv6 support"
+	@${ECHO_MSG} "WITHOUT_SSL=yes			builds without SSL/TLS support"
 	@${ECHO_MSG} "WITH_FULL_POPD_DEBUG=yes	builds with more verbose debugging"
-	@${ECHO_MSG} "WITH_PAM=yes              builds with PAM authentication"
+	@${ECHO_MSG} "WITH_PAM=yes			builds with PAM authentication"
 	@${ECHO_MSG} "WITH_POPPASSD=yes		builds the poppassd daemon"
-	@${ECHO_MSG} "WITHOUT_QPOPAUTH_SETUID=yes  does not install qpopauth setuid to pop user"
+	@${ECHO_MSG} "WITHOUT_QPOPAUTH_SETUID=yes	does not install qpopauth setuid to pop user"
 	@${ECHO_MSG} "WITH_SAMPLE_POPUSERS_FILE=yes	builds a default (otherwise,"
 	@${ECHO_MSG} "				use an empty file) reject file"
-	@${ECHO_MSG} "WITH_STANDALONE_MODE=yes  builds qpopper to be run without inetd"
-	@${ECHO_MSG} "WITHOUT_U_OPTION=yes      forbids daemon command line option"
-	@${ECHO_MSG} "                 -u which allows, after a user authenticates,"
-	@${ECHO_MSG} "                 process options to be read from a file called"
-	@${ECHO_MSG} "                 .qpopper-options in the user's home directory"
-	@${ECHO_MSG} "                 This file can be owned by and writable by the"
-	@${ECHO_MSG} "                 user. If improperly written, may cause a buffer"
-	@${ECHO_MSG} "                 overflow which may remove such user's mail box"
+	@${ECHO_MSG} "WITH_STANDALONE_MODE=yes	builds qpopper to be run without inetd"
+	@${ECHO_MSG} "WITHOUT_U_OPTION=yes		forbids daemon command line option"
+	@${ECHO_MSG} "				-u which allows, after a user authenticates,"
+	@${ECHO_MSG} "				process options to be read from a file called"
+	@${ECHO_MSG} "				.qpopper-options in the user's home directory"
+	@${ECHO_MSG} "				This file can be owned by and writable by the"
+	@${ECHO_MSG} "				user. If improperly written, may cause a buffer"
+	@${ECHO_MSG} "				overflow which may remove such user's mail box"
 	@${ECHO_MSG} "WITH_Y_OPTION=yes		enables daemon command line option"
-	@${ECHO_MSG} "			-y which allows the user to specify a different"
-	@${ECHO_MSG} "			logging facility"
+	@${ECHO_MSG} "				-y which allows the user to specify a different"
+	@${ECHO_MSG} "				logging facility"
 
+.if defined(WITHOUT_APOP)
+QPOPAUTH=	"@comment "
+.else
+CONFIGURE_ARGS+=	--enable-apop=${PREFIX}/etc/qpopper/pop.auth \
+			--with-apopuid=pop
+MAN8+=		qpopauth.8
+QPOPAUTH=	""
 # If WITH_APOP_ONLY variable present in the environment, qpopper builds
 # with APOP authentication only.
 .if defined(APOP_ONLY) || defined(WITH_APOP_ONLY)
 OS_DEFS+=	-DAPOP_ONLY
 .endif
+.endif
 
 # Do not install documentation since it is in pdf format and normally
-# not used unless user wants it
+# not used unless user wants it.
 .if !defined(WITH_DOCUMENTATION)
 NOPORTDOCS=	yes
 .endif
 
 # If WITH_DRAC variable present in the environment, qpopper builds
-# with Dynamic Relay Authorization Control support
+# with Dynamic Relay Authorization Control support.
 .if defined(WITH_DRAC)
 CONFIGURE_ARGS+=	--with-drac
 BUILD_DEPENDS+=	${LOCALBASE}/lib/libdrac.a:${PORTSDIR}/mail/drac
 .endif
 
 # If WITH_FULL_POPD_DEBUG variable present in the environment, qpopper builds
-# with more verbose debugging. See also -d option to qpopper
+# with more verbose debugging. See also -d option to qpopper.
 .if defined(FULL_POPD_DEBUG) || defined(WITH_FULL_POPD_DEBUG)
 CONFIGURE_ARGS+=	--enable-debugging
 .endif
@@ -133,28 +143,21 @@
 .endif
 
 # If WITH STANDALONE_MODE variable present qpopper is built so it runs
-# without inetd
+# without inetd.
 .if defined(WITH_STANDALONE_MODE)
 CONFIGURE_ARGS+=	--enable-standalone
 .endif
 
 # If WITH_Y_OPTION variable present, qoppper daemon will
 # accept -y command line option which allows the user to specify a
-# different logging facility
+# different logging facility.
 .if defined(WITH_Y_OPTION)
 EXTRA_PATCHES+=	${FILESDIR}/extra-patch-popper::pop_init.c
 .endif
 
-.if exists(/usr/lib/libssl.a) && exists(/usr/lib/libcrypto.a)
-CONFIGURE_ARGS+=	--with-openssl=/usr
-.elif exists(${LOCALBASE}/lib/libssl.a) && exists(${LOCALBASE}/lib/libcrypto.a)
-LIB_DEPENDS+=	ssl.3:${PORTSDIR}/security/openssl
-CONFIGURE_ARGS+=	-with-includes=${LOCALBASE}/include/openssl --with-openssl=${LOCALBASE}
-CONFIGURE_ENV+=	RSAGLUE="${RSAGLUE}"
-.if exists(${LOCALBASE}/lib/librsaref.a)
-RSAGLUE=	-lrsaref
-.endif
-RSAGLUE+=	-lRSAglue
+.if !defined(WITHOUT_SSL)
+.include "${PORTSDIR}/security/openssl/bsd.openssl.mk"
+CONFIGURE_ARGS+=	--with-openssl=${OPENSSLBASE}
 .endif
 
 post-patch:
@@ -173,6 +176,7 @@
 	@(cd ${WRKSRC}; ${CHMOD} u+w configure*)
 
 do-install:
+.if !defined(WITHOUT_APOP)
 	@${INSTALL_PROGRAM} ${WRKSRC}/popper/popauth ${PREFIX}/bin/qpopauth
 # If WITHOUT_QPOPAUTH_SETUID variable present in the environment,
 # qpopper does not install qpopauth setuid to pop user so that
@@ -181,10 +185,11 @@
 	@${CHOWN} pop ${PREFIX}/bin/qpopauth
 	@${CHMOD} u+s ${PREFIX}/bin/qpopauth
 .endif
-	@${INSTALL_PROGRAM} ${WRKSRC}/popper/popper ${PREFIX}/libexec/qpopper
 	@${INSTALL_MAN} ${WRKSRC}/man/popauth.8 ${MANPREFIX}/man/man8/qpopauth.8
-	@${INSTALL_MAN} ${WRKSRC}/man/popper.8 ${MANPREFIX}/man/man8/qpopper.8
 	@${LN} -sf ${PREFIX}/bin/qpopauth ${PREFIX}/bin/qapopauth
+.endif
+	@${INSTALL_PROGRAM} ${WRKSRC}/popper/popper ${PREFIX}/libexec/qpopper
+	@${INSTALL_MAN} ${WRKSRC}/man/popper.8 ${MANPREFIX}/man/man8/qpopper.8
 .if defined(WITH_POPPASSD)
 	@${INSTALL_PROGRAM} ${WRKSRC}/password/poppassd ${PREFIX}/libexec/qpoppassd
 .endif
@@ -199,7 +204,7 @@
 	@${SED} -e "s:/usr/local:${PREFIX}:g" ${PKGMESSAGE}
 
 # based on original from op port, written by Cyrille Lefevre
-# <clefevre at citeweb.net>
+# <clefevre at citeweb.net>.
 install-conf-file:
 	@if [ ! -f ${CONF_DIR}/${CONF_FILE}${SAMP_SUFX} ]; then \
 		if [ -f /etc/ftpusers ] && [ -n "${WITH_SAMPLE_POPUSERS_FILE}" ]; then \
Index: pkg-plist
===================================================================
RCS file: /usr/jail/217.24.217.12/usr/data/bsd/cvs/fbsd/ports/mail/qpopper/pkg-plist,v
retrieving revision 1.16
diff -u -r1.16 pkg-plist
--- pkg-plist	5 Jun 2002 01:28:48 -0000	1.16
+++ pkg-plist	22 May 2003 06:00:49 -0000
@@ -1,6 +1,6 @@
-bin/qpopauth
- at unexec rm -f %D/bin/qapopauth
- at exec ln -sf %D/bin/qpopauth %D/bin/qapopauth
+%%QPOPAUTH%%bin/qpopauth
+%%QPOPAUTH%%@unexec rm -f %D/bin/qapopauth
+%%QPOPAUTH%%@exec ln -sf %D/bin/qpopauth %D/bin/qapopauth
 libexec/qpopper
 %%EPOPPASSD%%libexec/qpoppassd
 @exec mkdir -p %D/etc/qpopper && chown %%POP_USER%%:%%POP_GROUP%% %D/etc/qpopper && chmod %%POP_MODE_DIR%% %D/etc/qpopper
Index: files/patch-configure.in
===================================================================
RCS file: /usr/jail/217.24.217.12/usr/data/bsd/cvs/fbsd/ports/mail/qpopper/files/patch-configure.in,v
retrieving revision 1.1
diff -u -r1.1 patch-configure.in
--- files/patch-configure.in	6 May 2001 03:28:06 -0000	1.1
+++ files/patch-configure.in	22 May 2003 06:00:49 -0000
@@ -1,14 +1,5 @@
 --- configure.in.orig	Sat May  5 14:32:51 2001
 +++ configure.in	Sat May  5 14:33:32 2001
-@@ -838,7 +838,7 @@
-     AC_DEFINE_UNQUOTED(QPOP_OPENSSL, "$openssl")
-     AC_DEFINE(QPOP_SSL)
-     SSL_DIR_INC="-I${openssl}/include"
--    SSL_LIBS="-L${openssl}/lib -lssl -lcrypto"
-+    SSL_LIBS="-L${openssl}/lib -lssl -lcrypto ${RSAGLUE}"
- fi
- 
- 
 @@ -1257,7 +1257,6 @@
  )
  
>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list