pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/security/amavis-perl Convert to options framework.
details: https://anonhg.NetBSD.org/pkgsrc/rev/38315635026b
branches: trunk
changeset: 497635:38315635026b
user: wiz <wiz%pkgsrc.org@localhost>
date: Mon Aug 01 12:18:41 2005 +0000
description:
Convert to options framework.
diffstat:
security/amavis-perl/Makefile | 28 ++++------------------------
security/amavis-perl/options.mk | 22 ++++++++++++++++++++++
2 files changed, 26 insertions(+), 24 deletions(-)
diffs (102 lines):
diff -r 71e8e54ad15d -r 38315635026b security/amavis-perl/Makefile
--- a/security/amavis-perl/Makefile Mon Aug 01 12:15:40 2005 +0000
+++ b/security/amavis-perl/Makefile Mon Aug 01 12:18:41 2005 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.17 2005/07/10 11:55:28 kristerw Exp $
+# $NetBSD: Makefile,v 1.18 2005/08/01 12:18:41 wiz Exp $
DISTNAME= amavisd-${VERSION}
PKGNAME= amavis-perl-${VERSION}
@@ -34,11 +34,9 @@
DEPENDS+= p5-Net-[0-9]*:../../net/p5-Net
DEPENDS+= p5-Unix-Syslog-[0-9]*:../../sysutils/p5-Unix-Syslog
+.include "options.mk"
.include "../../mk/bsd.prefs.mk"
-.if defined(USE_MILTER) && ${USE_MILTER} == "YES"
-DEPENDS+= sendmail>=8.12.9nb1:../../mail/sendmail
-.endif
VERSION= 0.1
@@ -53,11 +51,6 @@
CONFIGURE_ENV+= file=${TOOLS_FILE_CMD}
CONFIGURE_ENV+= procmail="/usr/libexec/mail.local"
-# XXX Milter needs pthreads, and configure fails looking for it
-# because ${PREFIX}/include is not available in the include path.
-.if defined(USE_MILTER) && ${USE_MILTER} == "YES"
-CONFIGURE_ENV+= CFLAGS="-I${PREFIX}/include"
-.endif
CONFIGURE_ARGS+=--sysconfdir=${PREFIX}/etc/amavis
CONFIGURE_ARGS+=--with-virusdir=${VIRUSDIR}
@@ -65,15 +58,6 @@
CONFIGURE_ARGS+=--enable-all
CONFIGURE_ARGS+=--with-amavisuser=amavis
-.if defined(USE_MILTER) && ${USE_MILTER} == "YES"
-CONFIGURE_ARGS+=--enable-milter
-CONFIGURE_ARGS+=--with-milter-libs=${PREFIX}/lib
-CONFIGURE_ARGS+=--with-milter-includes=${PREFIX}/include
-.else
-CONFIGURE_ARGS+=--enable-smtp --with-smtp-port=${SMTPPORT}
-PLIST_SRC+= ${PKGDIR}/PLIST.nomilter
-.endif
-
INSTALLATION_DIRS= sbin man/man1 man/man5 man/man8
post-build:
@@ -82,7 +66,7 @@
do-install:
# Program files
-.if !defined(USE_MILTER) || ${USE_MILTER} != YES
+.if empty(PKG_OPTIONS:Mmilter)
${INSTALL_PROGRAM} ${WRKSRC}/amavis/amavis ${PREFIX}/sbin
.endif
${INSTALL_SCRIPT} ${WRKDIR}/amavisd ${PREFIX}/sbin
@@ -106,15 +90,11 @@
> ${WRKDIR}/amavis.m4
${INSTALL_DATA} ${WRKDIR}/amavis.m4 ${PREFIX}/share/doc/amavis
# Man pages
-.if !defined(USE_MILTER) || ${USE_MILTER} != YES
+.if empty(PKG_OPTIONS:Mmilter)
${INSTALL_DATA} ${WRKSRC}/doc/amavis.1 ${PREFIX}/man/man1
.endif
${INSTALL_DATA} ${WRKSRC}/doc/amavis-milter.1 ${PREFIX}/man/man1
${INSTALL_DATA} ${WRKSRC}/doc/amavisd.conf.5 ${PREFIX}/man/man5
${INSTALL_DATA} ${WRKSRC}/doc/amavisd.8 ${PREFIX}/man/man8
-.if defined(USE_MILTER) && ${USE_MILTER} == "YES"
-.include "../../mk/pthread.buildlink3.mk"
-.endif
-
.include "../../mk/bsd.pkg.mk"
diff -r 71e8e54ad15d -r 38315635026b security/amavis-perl/options.mk
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/security/amavis-perl/options.mk Mon Aug 01 12:18:41 2005 +0000
@@ -0,0 +1,22 @@
+# $NetBSD: options.mk,v 1.1 2005/08/01 12:18:41 wiz Exp $
+
+PKG_OPTIONS_VAR= PKG_OPTIONS.amavis-perl
+PKG_SUPPORTED_OPTIONS= milter
+
+.include "../../mk/bsd.options.mk"
+
+.if !empty(PKG_OPTIONS:Mmilter)
+DEPENDS+= sendmail>=8.12.9nb1:../../mail/sendmail
+
+# XXX Milter needs pthreads, and configure fails looking for it
+# because ${PREFIX}/include is not available in the include path.
+CONFIGURE_ENV+= CFLAGS="-I${PREFIX}/include"
+.include "../../mk/pthread.buildlink3.mk"
+
+CONFIGURE_ARGS+=--enable-milter
+CONFIGURE_ARGS+=--with-milter-libs=${PREFIX}/lib
+CONFIGURE_ARGS+=--with-milter-includes=${PREFIX}/include
+.else
+CONFIGURE_ARGS+=--enable-smtp --with-smtp-port=${SMTPPORT}
+PLIST_SRC+= ${PKGDIR}/PLIST.nomilter
+.endif
Home |
Main Index |
Thread Index |
Old Index