Updated mail/postfix-current to 2.3-20060202
Postfix now preserves uppercase information while mapping addresses
with canonical, virtual, relocated or generic maps; this happens
even with $number substitutions in regular expression maps. However,
the local(8) and virtual(8) delivery agents still fold addresses
to lower case.
By default, Postfix now folds the search string to lowercase only
with tables that have fixed-case lookup fields such as btree:,
hash:, dbm:, ldap:, or *sql:. The search string is no longer case
folded with tables whose lookup fields can match both upper or lower
case, such as regexp:, pcre:, or cidr:.
For safety reasons, Postfix no longer allows $number substitution
in regexp: or pcre: transport tables or per-sender relayhost tables.
2006-02-05 13:55:32 +01:00
|
|
|
# $NetBSD: Makefile,v 1.57 2006/02/05 12:55:32 martti Exp $
|
2004-03-06 16:08:32 +01:00
|
|
|
|
Updated mail/postfix-current to 2.3-20060202
Postfix now preserves uppercase information while mapping addresses
with canonical, virtual, relocated or generic maps; this happens
even with $number substitutions in regular expression maps. However,
the local(8) and virtual(8) delivery agents still fold addresses
to lower case.
By default, Postfix now folds the search string to lowercase only
with tables that have fixed-case lookup fields such as btree:,
hash:, dbm:, ldap:, or *sql:. The search string is no longer case
folded with tables whose lookup fields can match both upper or lower
case, such as regexp:, pcre:, or cidr:.
For safety reasons, Postfix no longer allows $number substitution
in regexp: or pcre: transport tables or per-sender relayhost tables.
2006-02-05 13:55:32 +01:00
|
|
|
DISTNAME= postfix-2.3-20060202
|
2006-01-10 07:39:00 +01:00
|
|
|
#PKGREVISION= 1
|
2004-03-06 16:08:32 +01:00
|
|
|
CATEGORIES= mail
|
2004-04-12 18:04:45 +02:00
|
|
|
MASTER_SITES= ftp://ftp.porcupine.org/mirrors/postfix-release/experimental/ \
|
|
|
|
http://public.planetmirror.com.au/pub/postfix/experimental/
|
2004-03-06 16:08:32 +01:00
|
|
|
|
|
|
|
MAINTAINER= tech-pkg@NetBSD.org
|
|
|
|
HOMEPAGE= http://www.postfix.org/
|
|
|
|
COMMENT= Postfix SMTP server and tools
|
|
|
|
|
2005-09-30 08:04:32 +02:00
|
|
|
DIST_SUBDIR= postfix
|
|
|
|
|
2004-07-22 01:30:16 +02:00
|
|
|
CONFLICTS+= sendmail-[0-9]* fastforward>=0.51nb2
|
2004-03-07 11:16:05 +01:00
|
|
|
|
2004-03-06 16:08:32 +01:00
|
|
|
PKG_INSTALLATION_TYPES= overwrite pkgviews
|
|
|
|
|
2005-12-04 07:30:37 +01:00
|
|
|
USE_TOOLS+= perl
|
2005-12-03 20:29:37 +01:00
|
|
|
|
2004-07-31 07:53:44 +02:00
|
|
|
.include "../../mk/bsd.prefs.mk"
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2004-07-31 07:53:44 +02:00
|
|
|
# POSTFIX_QUEUE_DIR is the default queue directory for Postfix. This is
|
|
|
|
# merely a default, and may be changed by setting "queue_directory" in
|
|
|
|
# ${PKG_SYSCONFDIR}/main.cf.
|
|
|
|
#
|
|
|
|
POSTFIX_QUEUE_DIR?= ${VARBASE}/spool/postfix
|
|
|
|
|
|
|
|
# CCARGS is a list of options to pass to the preprocessor/compiler.
|
|
|
|
# AUXLIBS is a list of options to pass to the linker.
|
|
|
|
#
|
|
|
|
CCARGS= # empty
|
2005-07-31 05:58:45 +02:00
|
|
|
AUXLIBS= ${LDFLAGS}
|
2004-07-31 07:53:44 +02:00
|
|
|
FIX_RPATH+= AUXLIBS
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2004-08-07 10:11:25 +02:00
|
|
|
# Set some default paths to override ${WRKSRC}/src/global/mail_params.h.
|
2004-07-31 07:53:44 +02:00
|
|
|
CCARGS+= -DDEF_QUEUE_DIR=\"${POSTFIX_QUEUE_DIR}\"
|
|
|
|
CCARGS+= -DDEF_DAEMON_DIR=\"${LIBEXECDIR}\"
|
2004-08-07 10:11:25 +02:00
|
|
|
CCARGS+= -DDEF_COMMAND_DIR=\"${PREFIX}/sbin\"
|
|
|
|
CCARGS+= -DDEF_CONFIG_DIR=\"${PKG_SYSCONFDIR}\"
|
2004-03-06 16:08:32 +01:00
|
|
|
CCARGS+= -DDEF_SENDMAIL_PATH=\"${PREFIX}/sbin/sendmail\"
|
|
|
|
CCARGS+= -DDEF_MAILQ_PATH=\"${PREFIX}/bin/mailq\"
|
|
|
|
CCARGS+= -DDEF_NEWALIAS_PATH=\"${PREFIX}/bin/newaliases\"
|
2004-08-07 10:11:25 +02:00
|
|
|
CCARGS+= -DDEF_MANPAGE_DIR=\"${PREFIX}/man\"
|
|
|
|
CCARGS+= -DDEF_SAMPLE_DIR=\"${EXAMPLEDIR}\"
|
|
|
|
CCARGS+= -DDEF_README_DIR=\"${DOCDIR}\"
|
|
|
|
|
|
|
|
# Override those same default paths in the installed example main.cf.
|
|
|
|
SUBST_CLASSES+= postfix
|
|
|
|
SUBST_STAGE.postfix= post-configure
|
|
|
|
SUBST_FILES.postfix= conf/main.cf src/global/mail_params.h
|
|
|
|
SUBST_SED.postfix= \
|
|
|
|
-e "s|^\(queue_directory\) =.*|\1 = ${POSTFIX_QUEUE_DIR}|" \
|
|
|
|
-e "s|^\(command_directory\) =.*|\1 = ${PREFIX}/sbin|" \
|
|
|
|
-e "s|^\(daemon_directory\) =.*|\1 = ${LIBEXECDIR}|" \
|
|
|
|
-e "s|^\(sendmail_path\) =.*|\1 = ${PREFIX}/sbin/sendmail|" \
|
|
|
|
-e "s|^\(newaliases_path\) =.*|\1 = ${PREFIX}/bin/newaliases|" \
|
|
|
|
-e "s|^\(mailq_path\) =.*|\1 = ${PREFIX}/bin/mailq|" \
|
|
|
|
-e "s|^\(setgid_group\) =.*|\1 = maildrop|" \
|
|
|
|
-e "s|^\(manpage_directory\) =.*|\1 = ${PREFIX}/man|" \
|
|
|
|
-e "s|^\(sample_directory\) =.*|\1 = ${EXAMPLEDIR}|" \
|
|
|
|
-e "s|^\(readme_directory\) =.*|\1 = ${DOCDIR}|" \
|
|
|
|
-e "/^\#define DEF_SGID_GROUP[ ]/s,postdrop,maildrop,g"
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2004-08-05 05:04:33 +02:00
|
|
|
# options.mk appends to CCARGS and AUXLIBS the options needed to build
|
|
|
|
# Postfix with support for various add-on modules.
|
2004-07-31 07:53:44 +02:00
|
|
|
#
|
2004-08-05 05:04:33 +02:00
|
|
|
.include "options.mk"
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2004-07-31 07:53:44 +02:00
|
|
|
PKG_SYSCONFSUBDIR= postfix
|
|
|
|
LIBEXECDIR= ${PREFIX}/libexec/postfix
|
|
|
|
DOCDIR= ${PREFIX}/share/doc/postfix
|
|
|
|
EXAMPLEDIR= ${PREFIX}/share/examples/postfix
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2005-12-05 21:49:47 +01:00
|
|
|
FILES_SUBST+= EXAMPLEDIR=${EXAMPLEDIR:Q}
|
2004-07-31 07:53:44 +02:00
|
|
|
MESSAGE_SUBST+= EXAMPLEDIR=${EXAMPLEDIR}
|
|
|
|
MESSAGE_SUBST+= DOCDIR=${DOCDIR}
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2004-07-31 07:53:44 +02:00
|
|
|
MESSAGE_SRC+= ${PKGDIR}/MESSAGE
|
|
|
|
.if exists(${PKGDIR}/MESSAGE.${OPSYS})
|
|
|
|
MESSAGE_SRC+= ${PKGDIR}/MESSAGE.${OPSYS}
|
2004-03-06 16:08:32 +01:00
|
|
|
.endif
|
2004-07-31 07:53:44 +02:00
|
|
|
PLIST_SRC+= ${PKGDIR}/PLIST
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2004-12-03 16:14:50 +01:00
|
|
|
BUILD_TARGET= # empty
|
2005-12-05 21:49:47 +01:00
|
|
|
MAKE_ENV+= CC=${CC:Q} OPT=${CFLAGS:M*:Q}
|
|
|
|
MAKE_ENV+= AUXLIBS=${AUXLIBS:Q} CCARGS=${CCARGS:Q}
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2004-07-31 07:53:44 +02:00
|
|
|
RCD_SCRIPTS= postfix
|
2005-12-31 16:16:18 +01:00
|
|
|
OWN_DIRS+= ${POSTFIX_QUEUE_DIR} ${POSTFIX_QUEUE_DIR}/etc
|
2004-07-31 07:53:44 +02:00
|
|
|
MAKE_DIRS+= ${PKG_SYSCONFDIR}
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2004-07-31 07:53:44 +02:00
|
|
|
PKG_GROUPS?= postfix maildrop
|
2005-08-23 13:48:47 +02:00
|
|
|
PKG_USERS?= postfix:postfix::Postfix\ User:${POSTFIX_QUEUE_DIR}
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2004-07-31 07:53:44 +02:00
|
|
|
CONF_FILES= # empty
|
|
|
|
.for _file_ in main.cf master.cf postfix-files
|
|
|
|
CONF_FILES+= ${EXAMPLEDIR}/${_file_} ${PKG_SYSCONFDIR}/${_file_}
|
|
|
|
.endfor
|
2004-03-06 16:08:32 +01:00
|
|
|
CONF_FILES_PERMS= # empty
|
2004-07-31 07:53:44 +02:00
|
|
|
.for _file_ in post-install postfix-script
|
|
|
|
CONF_FILES_PERMS+= ${EXAMPLEDIR}/${_file_} ${PKG_SYSCONFDIR}/${_file_} \
|
2004-03-06 16:08:32 +01:00
|
|
|
${ROOT_USER} ${ROOT_GROUP} 755
|
|
|
|
.endfor
|
2004-07-31 07:53:44 +02:00
|
|
|
.if !empty(PKG_OPTIONS:Msasl)
|
|
|
|
MAKE_DIRS+= ${SASLLIBDIR}
|
|
|
|
CONF_FILES+= ${EXAMPLEDIR}/smtpd.conf ${SASLLIBDIR}/smtpd.conf
|
|
|
|
.endif
|
2004-03-06 16:08:32 +01:00
|
|
|
|
2005-09-30 08:04:32 +02:00
|
|
|
MAKE_ENV+= DEBUG= # empty
|
|
|
|
|
2006-01-10 21:21:32 +01:00
|
|
|
SUBST_CLASSES+= paths
|
|
|
|
SUBST_FILES.paths= ${WRKDIR}/mailer.conf
|
|
|
|
SUBST_SED.paths+= -e 's,@PREFIX@,${PREFIX},g'
|
|
|
|
SUBST_STAGE.paths= post-patch
|
|
|
|
|
|
|
|
post-extract:
|
|
|
|
${CP} ${FILESDIR}/mailer.conf ${WRKDIR}/mailer.conf
|
|
|
|
|
2004-03-06 16:08:32 +01:00
|
|
|
do-configure:
|
|
|
|
cd ${WRKSRC} && \
|
|
|
|
${SETENV} ${MAKE_ENV} ${MAKE} -f Makefile.init makefiles \
|
|
|
|
'CCARGS=${CCARGS}' 'AUXLIBS=${AUXLIBS}'
|
|
|
|
|
|
|
|
post-build:
|
2004-07-31 07:53:44 +02:00
|
|
|
.if !empty(PKG_OPTIONS:Msasl)
|
|
|
|
${ECHO} "pwcheck_method: ${PWCHECK_METHOD}" > ${WRKDIR}/smtpd.conf
|
2004-03-06 16:08:32 +01:00
|
|
|
.endif
|
2004-07-31 07:53:44 +02:00
|
|
|
|
2004-03-06 16:08:32 +01:00
|
|
|
do-install:
|
2004-07-31 07:53:44 +02:00
|
|
|
${INSTALL_DATA_DIR} ${LIBEXECDIR}
|
|
|
|
${INSTALL_DATA_DIR} ${EXAMPLEDIR}
|
|
|
|
${INSTALL_DATA_DIR} ${DOCDIR}
|
|
|
|
-${RM} -f ${WRKSRC}/conf/*.orig
|
|
|
|
.if !empty(PKG_OPTIONS:Msasl)
|
|
|
|
${INSTALL_DATA} ${WRKDIR}/smtpd.conf ${EXAMPLEDIR}
|
2004-03-06 16:08:32 +01:00
|
|
|
.endif
|
2004-07-31 07:53:44 +02:00
|
|
|
${INSTALL_SCRIPT} ${WRKSRC}/conf/post-install ${EXAMPLEDIR}
|
|
|
|
${INSTALL_SCRIPT} ${WRKSRC}/conf/postfix-script ${EXAMPLEDIR}
|
|
|
|
${INSTALL_DATA} ${WRKDIR}/mailer.conf ${EXAMPLEDIR}/mailer.conf
|
|
|
|
cd ${WRKSRC}; ${SH} ./postfix-install -non-interactive \
|
|
|
|
config_directory="${EXAMPLEDIR}"
|
2004-03-06 16:08:32 +01:00
|
|
|
|
|
|
|
.include "../../mk/bsd.pkg.mk"
|