summaryrefslogtreecommitdiff
path: root/mail
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2004-07-30 21:05:41 +0000
committerjlam <jlam@pkgsrc.org>2004-07-30 21:05:41 +0000
commitb460ce1ab51a88c8a15737b9aaf78a949fe6f32e (patch)
tree90f33a51019f85b91b5f29838193d07638327f1c /mail
parent85306a83480ca871311e350b3814452b76f3b8a2 (diff)
downloadpkgsrc-b460ce1ab51a88c8a15737b9aaf78a949fe6f32e.tar.gz
Convert to use bsd.options.mk. The relevant options variable to set
for each package can be determined by invoking: make show-var VARNAME=PKG_OPTIONS_VAR The old options are still supported unless the variable named in PKG_OPTIONS_VAR is set within make(1) (usually via /etc/mk.conf).
Diffstat (limited to 'mail')
-rw-r--r--mail/cyrus-imapd22/Makefile34
-rw-r--r--mail/fetchmail/Makefile45
-rw-r--r--mail/mutt-devel/Makefile.options45
-rw-r--r--mail/postfix/Makefile12
-rw-r--r--mail/postfix/Makefile.options85
5 files changed, 139 insertions, 82 deletions
diff --git a/mail/cyrus-imapd22/Makefile b/mail/cyrus-imapd22/Makefile
index 8fc94a89468..f3cab8b8cc4 100644
--- a/mail/cyrus-imapd22/Makefile
+++ b/mail/cyrus-imapd22/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.17 2004/07/29 20:04:02 recht Exp $
+# $NetBSD: Makefile,v 1.18 2004/07/30 21:05:41 jlam Exp $
DISTNAME= cyrus-imapd-2.2.8
CATEGORIES= mail
@@ -49,12 +49,35 @@ CONFIGURE_ARGS+= --without-zephyr
CONFIGURE_ARGS+= --without-ucdsnmp
.if defined(KERBEROS)
-. if (${KERBEROS} == 4) && exists(/usr/include/kerberosIV/krb.h)
-PKG_USE_KERBEROS= yes
+. if !defined(PKG_OPTIONS.cyrus-imapd)
+. if defined(KERBEROS)
+. if ${KERBEROS} == "4"
+PKG_OPTIONS.cyrus-imapd+= kerberos4
+. else
+PKG_OPTIONS.cyrus-imapd+= kerberos
+. endif
+. endif
+. endif
+.endif
+
+PKG_OPTIONS_VAR= PKG_OPTIONS.cyrus-imapd
+PKG_SUPPORTED_OPTIONS= gssapi kerberos kerberos4
+.include "../../mk/bsd.options.mk"
+
+.if !empty(PKG_OPTIONS:Mkerberos)
+. if empty(PKG_OPTIONS:Mgssapi)
+PKG_OPTIONS+= gssapi
+. endif
+.endif
+
+.if !empty(PKG_OPTIONS:Mkerberos4)
+. if exists(/usr/include/kerberosIV/krb.h)
+CRYPTO+= uses Kerberos encryption code
CONFIGURE_ARGS+= --with-auth=krb
CONFIGURE_ARGS+= --with-krb=/usr
-. else
-. include "../../mk/krb5.buildlink3.mk"
+. endif
+.elif !empty(PKG_OPTIONS:Mgssapi)
+. include "../../mk/krb5.buildlink3.mk"
CONFIGURE_ARGS+= --with-auth=krb5
CONFIGURE_ARGS+= --enable-gssapi=${KRB5BASE}
CONFIGURE_ARGS+= --with-gss_impl=${GSSIMPL.${KRB5_TYPE}}
@@ -62,7 +85,6 @@ GSSIMPL.heimdal= heimdal
GSSIMPL.mit-krb5= mit
CONFIGURE_ENV+= COMPILE_ET=${KRB5BASE}/bin/compile_et
COMERRBASE= ${KRB5BASE}
-. endif
.else
CONFIGURE_ARGS+= --with-auth=unix
CONFIGURE_ARGS+= --without-krb
diff --git a/mail/fetchmail/Makefile b/mail/fetchmail/Makefile
index be1364eb26d..12b52e8ac7c 100644
--- a/mail/fetchmail/Makefile
+++ b/mail/fetchmail/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.144 2004/07/22 17:04:28 drochner Exp $
+# $NetBSD: Makefile,v 1.145 2004/07/30 21:05:41 jlam Exp $
DISTNAME= fetchmail-6.2.5
PKGREVISION= 2
@@ -26,33 +26,51 @@ LDFLAGS+= ${CFLAGS}
.include "../../mk/bsd.prefs.mk"
-FETCHMAIL_USE_SSL?= yes
-BUILD_DEFS+= FETCHMAIL_USE_SSL
+# Global and legacy options
+.if defined(KERBEROS) && defined(USE_INET6) || defined(FETCHMAIL_USE_SSL)
+. if !defined(PKG_OPTIONS.fetchmail)
+. if defined(KERBEROS)
+PKG_OPTIONS.fetchmail+= kerberos4
+. endif
+. if defined(USE_INET6) && !empty(USE_INET6:M[yY][eE][sS])
+PKG_OPTIONS.fetchmail+= inet6
+. endif
+. if defined(FETCHMAIL_USE_SSL) && !empty(FETCHMAIL_USE_SSL:M[yY][eE][sS])
+PKG_OPTIONS.fetchmail+= ssl
+. endif
+. endif
+.endif
-.if defined(FETCHMAIL_USE_SSL) && !empty(FETCHMAIL_USE_SSL:M[yY][eE][sS])
-. include "../../security/openssl/buildlink3.mk"
-CONFIGURE_ARGS+= --with-ssl=${SSLBASE}
-.else
-CONFIGURE_ARGS+= --without-ssl
+PKG_OPTIONS_VAR= PKG_OPTIONS.fetchmail
+PKG_SUPPORTED_OPTIONS= inet6 kerberos4 ssl
+.include "../../mk/bsd.options.mk"
+
+.if !empty(PKG_OPTIONS:Minet6)
+CONFIGURE_ARGS+= --enable-inet6
.endif
-.if defined(KERBEROS)
-PKG_USE_KERBEROS= yes
+.if !empty(PKG_OPTIONS:Mkerberos4)
+CRYPTO+= uses Kerberos encryption code
CONFIGURE_ARGS+= --with-kerberos=yes
-. if ${MACHINE_PLATFORM:MNetBSD-1.[0-4]*-i386} == ""
+. if empty(MACHINE_PLATFORM:MNetBSD-1.[0-4]*-i386)
REPLACE_KERBEROS_LIBS= # defined
. endif
.else
CONFIGURE_ARGS+= --with-kerberos=no
.endif
-.if defined(USE_INET6) && !empty(USE_INET6:M[yY][eE][sS])
-CONFIGURE_ARGS+= --enable-inet6
+.if !empty(PKG_OPTIONS:Mssl)
+. include "../../security/openssl/buildlink3.mk"
+CONFIGURE_ARGS+= --with-ssl=${SSLBASE}
+.else
+CONFIGURE_ARGS+= --without-ssl
.endif
DOCDIR= ${PREFIX}/share/doc/fetchmail
RCD_SCRIPTS= fetchmail
+.include "../../devel/gettext-lib/buildlink3.mk"
+
post-extract:
@${RM} -f ${WRKSRC}/intl/libintl.h
.if ${OPSYS} == "NetBSD"
@@ -86,5 +104,4 @@ post-install:
${INSTALL_DATA} $$file ${DOCDIR}; \
done
-.include "../../devel/gettext-lib/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/mail/mutt-devel/Makefile.options b/mail/mutt-devel/Makefile.options
index 43b2fd0fb81..3715c78aecc 100644
--- a/mail/mutt-devel/Makefile.options
+++ b/mail/mutt-devel/Makefile.options
@@ -1,52 +1,37 @@
-# $NetBSD: Makefile.options,v 1.2 2004/07/23 15:00:12 jlam Exp $
-#
-# MUTT_ALL_OPTIONS lists all of the currently-supported optional modules
-# that may be built into Mutt.
-#
-# MUTT_OPTIONS is a list of the modules that will be built into Mutt.
-#
-MUTT_ALL_OPTIONS= slang ncurses ssl sasl
+# $NetBSD: Makefile.options,v 1.3 2004/07/30 21:05:41 jlam Exp $
+# Global and legacy options
.if defined(MUTT_USE_SLANG) || defined(MUTT_USE_NCURSES) || \
defined(MUTT_USE_SSL) || defined(MUTT_USE_SASL)
-. if !defined(MUTT_OPTIONS)
+. if !defined(PKG_OPTIONS.mutt)
. if defined(MUTT_USE_SLANG) && !empty(MUTT_USE_SLANG:M[yY][eE][sS])
-MUTT_OPTIONS+= slang
+PKG_OPTIONS.mutt+= slang
. endif
. if defined(MUTT_USE_NCURSES) && !empty(MUTT_USE_NCURSES:M[yY][eE][sS])
-MUTT_OPTIONS+= ncurses
+PKG_OPTIONS.mutt+= ncurses
. endif
. if defined(MUTT_USE_SSL) && !empty(MUTT_USE_SSL:M[yY][eE][sS])
-MUTT_OPTIONS+= ssl
+PKG_OPTIONS.mutt+= ssl
. endif
. if defined(MUTT_USE_SASL) && !empty(MUTT_USE_SASL:M[yY][eE][sS])
-MUTT_OPTIONS+= sasl
+PKG_OPTIONS.mutt+= sasl
. endif
. endif
.endif
+PKG_OPTIONS.mutt?= ssl
-MUTT_OPTIONS?= ssl
-BUILD_DEFS+= MUTT_OPTIONS
-
-_MUTT_OPTIONS= # empty
-.for _opt_ in ${MUTT_OPTIONS}
-. if empty(_MUTT_OPTIONS:M${_opt_})
-. if !empty(MUTT_ALL_OPTIONS:M${_opt_})
-_MUTT_OPTIONS+= ${_opt_}
-. else
-PKG_FAIL_REASON+= "\"${_opt_}\" is not a supported Mutt build option."
-. endif
-. endif
-.endfor
+PKG_OPTIONS_VAR= PKG_OPTIONS.mutt
+PKG_SUPPORTED_OPTIONS= slang ncurses ssl sasl
+.include "../../mk/bsd.options.mk"
###
### Slang and ncurses
###
-.if !empty(_MUTT_OPTIONS:Mslang)
+.if !empty(PKG_OPTIONS:Mslang)
. include "../../devel/libslang/buildlink3.mk"
CONFIGURE_ARGS+= --with-slang=${BUILDLINK_PREFIX.libslang}
.else
-. if !empty(_MUTT_OPTIONS:Mslang)
+. if !empty(PKG_OPTIONS:Mslang)
USE_NCURSES= yes
. endif
. include "../../devel/ncurses/buildlink3.mk"
@@ -56,7 +41,7 @@ CONFIGURE_ARGS+= --with-curses=${BUILDLINK_PREFIX.ncurses}
###
### SASLv2
###
-.if !empty(_MUTT_OPTIONS:Msasl)
+.if !empty(PKG_OPTIONS:Msasl)
. include "../../security/cyrus-sasl2/buildlink3.mk"
CONFIGURE_ARGS+= --with-sasl2=${BUILDLINK_PREFIX.cyrus-sasl}
.endif
@@ -64,7 +49,7 @@ CONFIGURE_ARGS+= --with-sasl2=${BUILDLINK_PREFIX.cyrus-sasl}
###
### SSL
###
-.if !empty(_MUTT_OPTIONS:Mssl)
+.if !empty(PKG_OPTIONS:Mssl)
. include "../../security/openssl/buildlink3.mk"
CONFIGURE_ARGS+= --with-ssl=${SSLBASE}
.else
diff --git a/mail/postfix/Makefile b/mail/postfix/Makefile
index 7c0a7d6bc4b..e91b3b70c6c 100644
--- a/mail/postfix/Makefile
+++ b/mail/postfix/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.144 2004/07/29 10:15:38 martti Exp $
+# $NetBSD: Makefile,v 1.145 2004/07/30 21:05:41 jlam Exp $
DISTNAME= postfix-2.1.4
CATEGORIES= mail
@@ -42,9 +42,7 @@ CCARGS+= -DDEF_MAILQ_PATH=\"${PREFIX}/bin/mailq\"
CCARGS+= -DDEF_NEWALIAS_PATH=\"${PREFIX}/bin/newaliases\"
# Makefile.options appends to CCARGS and AUXLIBS the options needed to
-# build Postfix with support for various add-on modules. It also defines
-# _POSTFIX_OPTIONS, which is POSTFIX_OPTIONS filtered to only contain
-# supported modules.
+# build Postfix with support for various add-on modules.
#
.include "Makefile.options"
@@ -85,7 +83,7 @@ CONF_FILES_PERMS+= ${EXAMPLEDIR}/${_file_} ${PKG_SYSCONFDIR}/${_file_} \
${ROOT_USER} ${ROOT_GROUP} 755
.endfor
.undef _file_
-.if !empty(_POSTFIX_OPTIONS:Msasl)
+.if !empty(PKG_OPTIONS:Msasl)
MAKE_DIRS+= ${SASLLIBDIR}
CONF_FILES+= ${EXAMPLEDIR}/smtpd.conf ${SASLLIBDIR}/smtpd.conf
.endif
@@ -108,7 +106,7 @@ do-configure:
post-build:
@${SED} ${FILES_SUBST_SED} ${FILESDIR}/mailer.conf \
> ${WRKDIR}/mailer.conf
-.if !empty(_POSTFIX_OPTIONS:Msasl)
+.if !empty(PKG_OPTIONS:Msasl)
${ECHO} "pwcheck_method: ${PWCHECK_METHOD}" > ${WRKDIR}/smtpd.conf
.endif
@@ -121,7 +119,7 @@ do-install:
${INSTALL_DATA_DIR} ${EXAMPLEDIR}
${INSTALL_DATA_DIR} ${DOCDIR}
-${RM} -f ${WRKSRC}/conf/*.orig
-.if !empty(_POSTFIX_OPTIONS:Msasl)
+.if !empty(PKG_OPTIONS:Msasl)
${INSTALL_DATA} ${WRKDIR}/smtpd.conf ${EXAMPLEDIR}
.endif
@for i in ${POSTFIX_EXAMPLE_FILES}; do \
diff --git a/mail/postfix/Makefile.options b/mail/postfix/Makefile.options
index a871cc437de..b8d626445d2 100644
--- a/mail/postfix/Makefile.options
+++ b/mail/postfix/Makefile.options
@@ -1,29 +1,65 @@
-# $NetBSD: Makefile.options,v 1.4 2004/07/24 22:45:15 recht Exp $
-#
-# POSTFIX_ALL_OPTIONS lists all of the currently-supported optional modules
-# that may be built into Postfix.
+# $NetBSD: Makefile.options,v 1.5 2004/07/30 21:05:41 jlam Exp $
+
+# Global and legacy options
#
-# POSTFIX_OPTIONS is a list of the modules that will be built into Postfix.
+# XXX Support for the following variables will be removed after the
+# XXX pkgsrc-2004Q3 branch is released:
+# XXX
+# XXX POSTFIX_USE_INET6 POSTFIX_USE_TLS
+# XXX POSTFIX_USE_PCRE POSTFIX_USE_MYSQL
+# XXX POSTFIX_USE_PGSQL POSTFIX_USE_VERP
+# XXX POSTFIX_USE_SASL_AUTH POSTFIX_OPTIONS
#
-POSTFIX_ALL_OPTIONS= inet6 ldap mysql mysql4 pcre sasl tls
-POSTFIX_OPTIONS?= # empty
-BUILD_DEFS+= POSTFIX_OPTIONS
-
-_POSTFIX_OPTIONS= # empty
-.for _opt_ in ${POSTFIX_OPTIONS}
-. if empty(_POSTFIX_OPTIONS:M${_opt_})
-. if !empty(POSTFIX_ALL_OPTIONS:M${_opt_})
-_POSTFIX_OPTIONS+= ${_opt_}
-. else
-PKG_FAIL_REASON+= "\"${_opt_}\" is not a supported Postfix build option."
+.if defined(USE_SASL) || defined(USE_SASL2) || defined(USE_OPENLDAP) || \
+ defined(POSTFIX_USE_INET6) || defined(POSTFIX_USE_TLS) || \
+ defined(POSTFIX_USE_PCRE) || defined(POSTFIX_USE_MYSQL) || \
+ defined(POSTFIX_USE_PGSQL) || defined(POSTFIX_USE_VERP) || \
+ defined(POSTFIX_USE_SASL_AUTH)
+. if !defined(PKG_OPTIONS.postfix)
+. if defined(USE_SASL) && !empty(USE_SASL:M[yY][eE][sS])
+PKG_OPTIONS.postfix+= sasl
+. endif
+. if defined(USE_SASL2) && !empty(USE_SASL2:M[yY][eE][sS])
+PKG_OPTIONS.postfix+= sasl
+. endif
+. if defined(USE_OPENLDAP) && !empty(USE_OPENLDAP:M[yY][eE][sS])
+PKG_OPTIONS.postfix+= ldap
+. endif
+. if defined(POSTFIX_USE_INET6) && !empty(POSTFIX_USE_INET6:M[yY][eE][sS])
+PKG_OPTIONS.postfix+= inet6
+. endif
+. if defined(POSTFIX_USE_TLS) && !empty(POSTFIX_USE_TLS:M[yY][eE][sS])
+PKG_OPTIONS.postfix+= tls
+. endif
+. if defined(POSTFIX_USE_PCRE) && !empty(POSTFIX_USE_PCRE:M[yY][eE][sS])
+PKG_OPTIONS.postfix+= pcre
+. endif
+. if defined(POSTFIX_USE_MYSQL) && !empty(POSTFIX_USE_MYSQL:M[yY][eE][sS])
+PKG_OPTIONS.postfix+= mysql
+. endif
+. if defined(POSTFIX_USE_PGSQL) && !empty(POSTFIX_USE_PGSQL:M[yY][eE][sS])
+PKG_OPTIONS.postfix+= pgsql
+. endif
+. if defined(POSTFIX_USE_VERP) && !empty(POSTFIX_USE_VERP:M[yY][eE][sS])
+PKG_OPTIONS.postfix+= verp
+. endif
+. if defined(POSTFIX_USE_SASL_AUTH) && defined(POSTFIX_USE_SASL_AUTH)
+PKG_OPTIONS.postfix+= sasl
+. endif
+. if defined(POSTFIX_OPTIONS)
+PKG_OPTIONS.postfix= ${POSTFIX_OPTIONS}
. endif
. endif
-.endfor
+.endif
+
+PKG_OPTIONS_VAR= PKG_OPTIONS.postfix
+PKG_SUPPORTED_OPTIONS= inet6 ldap mysql mysql4 pcre sasl tls
+.include "../../mk/bsd.options.mk"
###
### IPv6 and STARTTLS support (http://www.ipnet6.org/postfix/)
###
-.if !empty(_POSTFIX_OPTIONS:Minet6) || !empty(_POSTFIX_OPTIONS:Mtls)
+.if !empty(PKG_OPTIONS:Minet6) || !empty(PKG_OPTIONS:Mtls)
. include "../../security/openssl/buildlink3.mk"
PATCHFILES+= tls+ipv6-1.25-pf-2.1.3.patch.gz
PATCH_SITES+= ftp://ftp.stack.nl/pub/postfix/tls+ipv6/1.25/
@@ -41,7 +77,7 @@ MESSAGE_SRC+= ${PKGDIR}/MESSAGE.tls
###
### Support "pcre" map type for regular expressions.
###
-.if !empty(_POSTFIX_OPTIONS:Mpcre)
+.if !empty(PKG_OPTIONS:Mpcre)
. include "../../devel/pcre/buildlink3.mk"
CCARGS+= -DHAS_PCRE
AUXLIBS+= -L${BUILDLINK_PREFIX.pcre}/lib \
@@ -54,7 +90,7 @@ CCARGS+= -DNO_PCRE
###
### Support LDAP directories for table lookups.
###
-.if !empty(_POSTFIX_OPTIONS:Mldap)
+.if !empty(PKG_OPTIONS:Mldap)
. include "../../databases/openldap/buildlink3.mk"
CCARGS+= -DHAS_LDAP
AUXLIBS+= -L${BUILDLINK_PREFIX.openldap}/lib \
@@ -72,12 +108,12 @@ AUXLIBS+= -L${BUILDLINK_PREFIX.db4}/lib \
###
### Support using a MySQL database server for table lookups.
###
-.if !empty(_POSTFIX_OPTIONS:Mmysql4)
+.if !empty(PKG_OPTIONS:Mmysql4)
. include "../../databases/mysql4-client/buildlink3.mk"
CCARGS+= -DHAS_MYSQL
CCARGS+= `${BUILDLINK_PREFIX.mysql-client}/bin/mysql_config --include`
AUXLIBS+= `${BUILDLINK_PREFIX.mysql-client}/bin/mysql_config --libs`
-.elif !empty(_POSTFIX_OPTIONS:Mmysql)
+.elif !empty(PKG_OPTIONS:Mmysql)
. include "../../databases/mysql-client/buildlink3.mk"
CCARGS+= -DHAS_MYSQL -I${BUILDLINK_PREFIX.mysql-client}/include/mysql
AUXLIBS+= -L${BUILDLINK_PREFIX.mysql-client}/lib/mysql \
@@ -88,7 +124,7 @@ AUXLIBS+= -L${BUILDLINK_PREFIX.mysql-client}/lib/mysql \
## ###
## ### Support using a PostgreSQL database server for table lookups.
## ###
-## .if !empty(_POSTFIX_OPTIONS:Mpgsql)
+## .if !empty(PKG_OPTIONS:Mpgsql)
## . include "../../mk/pgsql.buildlink3.mk"
## . include "../../security/openssl/buildlink3.mk"
## PATCHFILES+= postfix-pg.postfix-2.0.0.2.patch
@@ -104,7 +140,7 @@ AUXLIBS+= -L${BUILDLINK_PREFIX.mysql-client}/lib/mysql \
### SASL support for SMTP authentication. If neither SASLv1 or SASLv2 is
### explicitly specified, then build with SASLv2.
###
-.if !empty(_POSTFIX_OPTIONS:Msasl)
+.if !empty(PKG_OPTIONS:Msasl)
. if !defined(USE_SASL2) && !defined(USE_SASL)
. include "../../security/cyrus-sasl2/buildlink3.mk"
SASLLIBDIR= ${PREFIX}/lib/sasl2
@@ -130,7 +166,6 @@ AUXLIBS+= -L${BUILDLINK_PREFIX.cyrus-sasl}/lib \
-Wl,${RPATH_FLAG}${BUILDLINK_PREFIX.cyrus-sasl}/lib \
-lsasl
. endif
-
PLIST_SRC+= ${PKGDIR}/PLIST.sasl
MESSAGE_SRC+= ${PKGDIR}/MESSAGE.sasl
MESSAGE_SUBST+= PKG_SYSCONFDIR=${PKG_SYSCONFDIR}