mirror of
https://git.freebsd.org/ports.git
synced 2025-06-15 17:50:31 -04:00
- adopt optionsNG
- trim historical header - tighten COMMENT Approved by: portmgr (bapt)
This commit is contained in:
parent
8bb5b1fd8f
commit
d3a27657aa
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=314621
5 changed files with 287 additions and 429 deletions
|
@ -1,9 +1,5 @@
|
||||||
# New ports collection makefile for: postfix-current
|
# Created by: torstenb
|
||||||
# Date created: 18 Mar 1999
|
|
||||||
# Whom: torstenb
|
|
||||||
#
|
|
||||||
# $FreeBSD$
|
# $FreeBSD$
|
||||||
#
|
|
||||||
|
|
||||||
PORTNAME= postfix
|
PORTNAME= postfix
|
||||||
DISTVERSION= 2.10-20130113
|
DISTVERSION= 2.10-20130113
|
||||||
|
@ -19,7 +15,7 @@ PKGNAMESUFFIX= -current
|
||||||
DIST_SUBDIR= ${PORTNAME}
|
DIST_SUBDIR= ${PORTNAME}
|
||||||
|
|
||||||
MAINTAINER= sahil@FreeBSD.org
|
MAINTAINER= sahil@FreeBSD.org
|
||||||
COMMENT= A secure alternative to widely-used Sendmail
|
COMMENT= Secure alternative to widely-used Sendmail
|
||||||
|
|
||||||
CONFLICTS= courier-0.* postfix-1.* postfix-2.* postfix-base-2.* \
|
CONFLICTS= courier-0.* postfix-1.* postfix-2.* postfix-base-2.* \
|
||||||
sendmail-8.* sendmail+*-8.* smail-3.* zmailer-2.* opensmtpd-[0-9]*
|
sendmail-8.* sendmail+*-8.* smail-3.* zmailer-2.* opensmtpd-[0-9]*
|
||||||
|
@ -31,36 +27,35 @@ USE_SUBMAKE= yes
|
||||||
USE_PERL5_BUILD=yes
|
USE_PERL5_BUILD=yes
|
||||||
SCRIPTS_ENV+= POSTFIX_DEFAULT_MTA="${POSTFIX_DEFAULT_MTA}"
|
SCRIPTS_ENV+= POSTFIX_DEFAULT_MTA="${POSTFIX_DEFAULT_MTA}"
|
||||||
|
|
||||||
# back compat pull in settings from POSTFIX_OPTIONS for convenience when
|
OPTIONS_DEFINE= PCRE SASL2 TLS BDB MYSQL PGSQL SQLITE OPENLDAP LDAP_SASL \
|
||||||
# make config is run (happens first time port is built, too)
|
CDB NIS VDA TEST SPF INST_BASE
|
||||||
.for o in SASL2 SASLKRB5 SASLKRB5MIT TLS BDB MySQL PgSQL OpenLDAP CDB NIS VDA Test SPF
|
PCRE_DESC= Perl Compatible Regular Expressions
|
||||||
STATUS_${o}=off
|
SASL2_DESC= Cyrus SASLv2 (Simple Auth. and Sec. Layer)
|
||||||
.endfor
|
DOVECOT_DESC= Dovecot 1.x SASL authentication method
|
||||||
.if defined(POSTFIX_OPTIONS)
|
DOVECOT2_DESC= Dovecot 2.x SASL authentication method
|
||||||
. for o in ${POSTFIX_OPTIONS}
|
SASLKRB5_DESC= If your SASL req. Kerberos5, select this
|
||||||
STATUS_${o}=on
|
SASLKMIT_DESC= If your SASL req. MIT Kerberos5, select this
|
||||||
. endfor
|
TLS_DESC= SSL and TLS support
|
||||||
.endif
|
BDB_DESC= Berkeley DB (uses WITH_BDB_VER)
|
||||||
|
MYSQL_DESC= MySQL maps (uses WITH_MYSQL_VER)
|
||||||
|
PGSQL_DESC= PostgreSQL maps (uses DEFAULT_PGSQL_VER)
|
||||||
|
SQLITE_DESC= SQLite maps
|
||||||
|
OPENLDAP_DESC= OpenLDAP maps (uses WITH_OPENLDAP_VER)
|
||||||
|
LDAP_SASL_DESC= OpenLDAP client-to-server SASL auth
|
||||||
|
CDB_DESC= CDB maps lookups
|
||||||
|
NIS_DESC= NIS maps lookups
|
||||||
|
VDA_DESC= VDA (Virtual Delivery Agent 32Bit)
|
||||||
|
TEST_DESC= SMTP/LMTP test server and generator
|
||||||
|
SPF_DESC= SPF support (via libspf2 1.2.x)
|
||||||
|
INST_BASE_DESC= Install into /usr and /etc/postfix
|
||||||
|
|
||||||
OPTIONS= PCRE "Perl Compatible Regular Expressions" on \
|
OPTIONS_RADIO= RG1 RG2
|
||||||
SASL2 "Cyrus SASLv2 (Simple Auth. and Sec. Layer)" ${STATUS_SASL2} \
|
OPTIONS_RADIO_RG1= DOVECOT DOVECOT2
|
||||||
DOVECOT "Dovecot 1.x SASL authentication method" off \
|
OPTIONS_RADIO_RG2= SASLKRB5 SASLKMIT
|
||||||
DOVECOT2 "Dovecot 2.x SASL authentication method" off \
|
RG1_DESC= Dovecot SASL authentication methods
|
||||||
SASLKRB5 "If your SASL req. Kerberos5, select this" ${STATUS_SASLKRB5} \
|
RG2_DESC= Kerberos network authentication protocol type
|
||||||
SASLKMIT "If your SASL req. MIT Kerberos5, select this" ${STATUS_SASLKRB5MIT} \
|
|
||||||
TLS "Enable SSL and TLS support" ${STATUS_TLS} \
|
OPTIONS_DEFAULT= PCRE
|
||||||
BDB "Berkeley DB (uses WITH_BDB_VER)" ${STATUS_BDB} \
|
|
||||||
MYSQL "MySQL maps (uses WITH_MYSQL_VER)" ${STATUS_MySQL} \
|
|
||||||
PGSQL "PostgreSQL maps (uses DEFAULT_PGSQL_VER)" ${STATUS_PgSQL} \
|
|
||||||
SQLITE "SQLite maps" off \
|
|
||||||
OPENLDAP "OpenLDAP maps (uses WITH_OPENLDAP_VER)" ${STATUS_OpenLDAP} \
|
|
||||||
LDAP_SASL "Enable OpenLDAP client-to-server SASL auth" off \
|
|
||||||
CDB "CDB maps lookups" ${STATUS_CDB} \
|
|
||||||
NIS "NIS maps lookups" ${STATUS_NIS} \
|
|
||||||
VDA "VDA (Virtual Delivery Agent 32Bit)" ${STATUS_VDA} \
|
|
||||||
TEST "SMTP/LMTP test server and generator" ${STATUS_Test} \
|
|
||||||
SPF "SPF support (via libspf2 1.2.x)" ${STATUS_SPF} \
|
|
||||||
INST_BASE "Install into /usr and /etc/postfix" off
|
|
||||||
|
|
||||||
.include <bsd.port.options.mk>
|
.include <bsd.port.options.mk>
|
||||||
|
|
||||||
|
@ -117,7 +112,7 @@ POSTFIX_CCARGS+= -DDEF_CONFIG_DIR=\\\"${ETCDIR}\\\" \
|
||||||
# Default requirement for postfix rc script
|
# Default requirement for postfix rc script
|
||||||
_REQUIRE= LOGIN cleanvar
|
_REQUIRE= LOGIN cleanvar
|
||||||
|
|
||||||
.if defined(WITH_PCRE)
|
.if ${PORT_OPTIONS:MPCRE}
|
||||||
LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
|
LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
|
||||||
POSTFIX_CCARGS+= -DHAS_PCRE -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_PCRE -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
||||||
|
@ -125,18 +120,14 @@ POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
||||||
POSTFIX_CCARGS+= -DNO_PCRE
|
POSTFIX_CCARGS+= -DNO_PCRE
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASL2)
|
.if ${PORT_OPTIONS:MSASL2}
|
||||||
LIB_DEPENDS+= sasl2:${PORTSDIR}/security/cyrus-sasl2
|
LIB_DEPENDS+= sasl2:${PORTSDIR}/security/cyrus-sasl2
|
||||||
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${LOCALBASE}/include -I${LOCALBASE}/include/sasl
|
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${LOCALBASE}/include -I${LOCALBASE}/include/sasl
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsasl2 -lpam -lcrypt
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsasl2 -lpam -lcrypt
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_DOVECOT) && defined(WITH_DOVECOT2)
|
.if ${PORT_OPTIONS:MDOVECOT} || ${PORT_OPTIONS:MDOVECOT2}
|
||||||
BROKEN= Select only one Dovecot option
|
.if ${PORT_OPTIONS:MDOVECOT}
|
||||||
.endif
|
|
||||||
|
|
||||||
.if defined(WITH_DOVECOT) || defined(WITH_DOVECOT2)
|
|
||||||
.if defined(WITH_DOVECOT)
|
|
||||||
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot
|
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot
|
||||||
.else
|
.else
|
||||||
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot2
|
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot2
|
||||||
|
@ -145,31 +136,25 @@ POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"
|
||||||
_REQUIRE+= dovecot
|
_REQUIRE+= dovecot
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKRB5)
|
.if ${PORT_OPTIONS:MSASLKRB5}
|
||||||
.if defined(WITH_SASLKMIT)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
.if ${OSVERSION} >= 800037
|
.if ${OSVERSION} >= 800037
|
||||||
KRB5_EXTR= -lhx509
|
KRB5_EXTR= -lhx509
|
||||||
.endif
|
.endif
|
||||||
POSTFIX_AUXLIBS+= -lkrb5 ${KRB5_EXTR} -lcrypto -lcrypt -lcom_err -lasn1 -lroken
|
POSTFIX_AUXLIBS+= -lkrb5 ${KRB5_EXTR} -lcrypto -lcrypt -lcom_err -lasn1 -lroken
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKMIT)
|
.if ${PORT_OPTIONS:MSASLKMIT}
|
||||||
.if defined(WITH_SASLKRB5)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
LIB_DEPENDS+= krb5.3:${PORTSDIR}/security/krb5
|
LIB_DEPENDS+= krb5.3:${PORTSDIR}/security/krb5
|
||||||
POSTFIX_AUXLIBS+= -Wl,--rpath,$${KRB5_HOME:-${LOCALBASE}}/lib -lkrb5 -lcrypto -lcrypt -lcom_err
|
POSTFIX_AUXLIBS+= -Wl,--rpath,$${KRB5_HOME:-${LOCALBASE}}/lib -lkrb5 -lcrypto -lcrypt -lcom_err
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_TLS)
|
.if ${PORT_OPTIONS:MTLS}
|
||||||
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
||||||
POSTFIX_CCARGS+= -DUSE_TLS -I${OPENSSLINC}
|
POSTFIX_CCARGS+= -DUSE_TLS -I${OPENSSLINC}
|
||||||
POSTFIX_AUXLIBS+= -L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
|
POSTFIX_AUXLIBS+= -L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SPF)
|
.if ${PORT_OPTIONS:MSPF}
|
||||||
LIB_DEPENDS+= spf2.3:${PORTSDIR}/mail/libspf2
|
LIB_DEPENDS+= spf2.3:${PORTSDIR}/mail/libspf2
|
||||||
PATCH_SITES+= ${MASTER_SITE_LOCAL}
|
PATCH_SITES+= ${MASTER_SITE_LOCAL}
|
||||||
PATCH_SITE_SUBDIR= mm
|
PATCH_SITE_SUBDIR= mm
|
||||||
|
@ -182,64 +167,66 @@ PLIST_SUB+= SPF=""
|
||||||
PLIST_SUB+= SPF="@comment "
|
PLIST_SUB+= SPF="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_BDB)
|
.if ${PORT_OPTIONS:MBDB}
|
||||||
USE_BDB= yes
|
USE_BDB= yes
|
||||||
POSTFIX_CCARGS+= -I${BDB_INCLUDE_DIR}
|
POSTFIX_CCARGS+= -I${BDB_INCLUDE_DIR}
|
||||||
POSTFIX_AUXLIBS+= -L${BDB_LIB_DIR} -l${BDB_LIB_NAME}
|
POSTFIX_AUXLIBS+= -L${BDB_LIB_DIR} -l${BDB_LIB_NAME}
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_MYSQL)
|
.if ${PORT_OPTIONS:MMYSQL}
|
||||||
USE_MYSQL= yes
|
USE_MYSQL= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql
|
POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib/mysql -lmysqlclient -lz -lcrypt -lm
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib/mysql -lmysqlclient -lz -lcrypt -lm
|
||||||
_REQUIRE+= mysql
|
_REQUIRE+= mysql
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_PGSQL)
|
.if ${PORT_OPTIONS:MPGSQL}
|
||||||
USE_PGSQL= yes
|
USE_PGSQL= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_PGSQL -I${LOCALBASE}/include -I${LOCALBASE}/pgsql/include
|
POSTFIX_CCARGS+= -DHAS_PGSQL -I${LOCALBASE}/include -I${LOCALBASE}/pgsql/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -L${LOCALBASE}/pgsql/lib -lpq -lcrypt
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -L${LOCALBASE}/pgsql/lib -lpq -lcrypt
|
||||||
_REQUIRE+= postgresql
|
_REQUIRE+= postgresql
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SQLITE)
|
.if ${PORT_OPTIONS:MSQLITE}
|
||||||
USE_SQLITE= yes
|
USE_SQLITE= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_SQLITE -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_SQLITE -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsqlite3
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsqlite3
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_OPENLDAP)
|
.if ${PORT_OPTIONS:MOPENLDAP}
|
||||||
USE_OPENLDAP= yes
|
USE_OPENLDAP= yes
|
||||||
.if defined(WITH_OPENLDAP_VER)
|
.if ${PORT_OPTIONS:MOPENLDAP_VER}
|
||||||
WANT_OPENLDAP_VER= ${WITH_OPENLDAP_VER}
|
WANT_OPENLDAP_VER= ${WITH_OPENLDAP_VER}
|
||||||
.endif
|
.endif
|
||||||
POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lldap -llber
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lldap -llber
|
||||||
_REQUIRE+= slapd
|
_REQUIRE+= slapd
|
||||||
.if defined(WITH_LDAP_SASL)
|
.if ${PORT_OPTIONS:MLDAP_SASL}
|
||||||
.if !defined(WITH_SASL2)
|
.if ! ${PORT_OPTIONS:MSASL2}
|
||||||
BROKEN= Compile with Cyrus SASL to use LDAP_SASL
|
PORT_OPTIONS+=SASL2
|
||||||
.endif
|
.endif
|
||||||
|
.if ${PORT_OPTIONS:MSASL2}
|
||||||
POSTFIX_CCARGS+= -DUSE_LDAP_SASL
|
POSTFIX_CCARGS+= -DUSE_LDAP_SASL
|
||||||
.endif
|
.endif
|
||||||
.endif
|
.endif
|
||||||
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_CDB)
|
.if ${PORT_OPTIONS:MCDB}
|
||||||
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcdb.a:${PORTSDIR}/databases/tinycdb
|
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcdb.a:${PORTSDIR}/databases/tinycdb
|
||||||
POSTFIX_CCARGS+= -DHAS_CDB -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_CDB -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lcdb
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lcdb
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_NIS)
|
.if ${PORT_OPTIONS:MNIS}
|
||||||
POSTFIX_CCARGS+= -DHAS_NIS
|
POSTFIX_CCARGS+= -DHAS_NIS
|
||||||
_REQUIRE+= ypserv
|
_REQUIRE+= ypserv
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_VDA)
|
.if ${PORT_OPTIONS:MVDA}
|
||||||
BROKEN= At the moment, VDA support is unavailable for ${PORTNAME}-${DISTVERSION}
|
BROKEN= At the moment, VDA support is unavailable for ${PORTNAME}-${DISTVERSION}
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_TEST)
|
.if ${PORT_OPTIONS:MTEST}
|
||||||
BINTEST= qmqp-sink qmqp-source smtp-sink smtp-source
|
BINTEST= qmqp-sink qmqp-source smtp-sink smtp-source
|
||||||
MANTEST= qmqp-sink.1 qmqp-source.1 smtp-sink.1 smtp-source.1
|
MANTEST= qmqp-sink.1 qmqp-source.1 smtp-sink.1 smtp-source.1
|
||||||
MAN1+= ${MANTEST}
|
MAN1+= ${MANTEST}
|
||||||
|
@ -248,11 +235,11 @@ PLIST_SUB+= TEST=""
|
||||||
PLIST_SUB+= TEST="@comment "
|
PLIST_SUB+= TEST="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_INST_BASE)
|
.if ${PORT_OPTIONS:MINST_BASE}
|
||||||
PKGNAMESUFFIX= -current-base
|
PKGNAMESUFFIX= -current-base
|
||||||
PREFIX= /usr
|
PREFIX= /usr
|
||||||
ETCDIR= /etc/postfix
|
ETCDIR= /etc/postfix
|
||||||
USE_RCORDER= postfix
|
USE_RC_SUBR= postfix
|
||||||
PLIST_SUB+= BASE=""
|
PLIST_SUB+= BASE=""
|
||||||
.else
|
.else
|
||||||
USE_RC_SUBR= postfix
|
USE_RC_SUBR= postfix
|
||||||
|
@ -261,10 +248,10 @@ PLIST_SUB+= BASE="@comment "
|
||||||
|
|
||||||
PLIST_SUB+= PFETC=${ETCDIR}
|
PLIST_SUB+= PFETC=${ETCDIR}
|
||||||
|
|
||||||
.if defined(NOPORTDOCS)
|
.if ${PORT_OPTIONS:MDOCS}
|
||||||
READMEDIR= no
|
|
||||||
.else
|
|
||||||
READMEDIR= ${DOCSDIR}
|
READMEDIR= ${DOCSDIR}
|
||||||
|
.else
|
||||||
|
READMEDIR= no
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
DAEMONDIR= ${PREFIX}/libexec/postfix
|
DAEMONDIR= ${PREFIX}/libexec/postfix
|
||||||
|
@ -290,21 +277,7 @@ REINPLACE= s!^PATH=.*!PATH=/bin:/sbin:/usr/bin:/usr/sbin:${PREFIX}/bin:${PREFIX}
|
||||||
s!($config_directory/(access|aliases|canonical|generic|header_checks|relocated|transport|virtual):f:root:-:644:)p1!\1o!;
|
s!($config_directory/(access|aliases|canonical|generic|header_checks|relocated|transport|virtual):f:root:-:644:)p1!\1o!;
|
||||||
|
|
||||||
pre-patch:
|
pre-patch:
|
||||||
.if defined(POSTFIX_OPTIONS)
|
.if ${PORT_OPTIONS:MSASL2} && ! ${PORT_OPTIONS:MMYSQL} && exists(${LOCALBASE}/lib/libsasl2.a)
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG} "***** ALERT *****"
|
|
||||||
@${ECHO_MSG} "POSTFIX_OPTIONS is no longer supported,"
|
|
||||||
@${ECHO_MSG} "${PORTNAME} uses options, consider running"
|
|
||||||
@${ECHO_MSG} "# make config"
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@sleep 10
|
|
||||||
.endif
|
|
||||||
|
|
||||||
.if defined(WITH_SASL2) && !defined(WITH_MYSQL) && exists(${LOCALBASE}/lib/libsasl2.a)
|
|
||||||
@if /usr/bin/nm ${LOCALBASE}/lib/libsasl2.a | ${GREP} -wq "mysql_init"; then \
|
@if /usr/bin/nm ${LOCALBASE}/lib/libsasl2.a | ${GREP} -wq "mysql_init"; then \
|
||||||
${ECHO_MSG}; \
|
${ECHO_MSG}; \
|
||||||
${ECHO_MSG} "Your SASL2 library it's compiled with MYSQL"; \
|
${ECHO_MSG} "Your SASL2 library it's compiled with MYSQL"; \
|
||||||
|
@ -350,12 +323,12 @@ do-install:
|
||||||
sendmail_path=${PREFIX}/sbin/sendmail
|
sendmail_path=${PREFIX}/sbin/sendmail
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
||||||
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MANPREFIX}/man/man1
|
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MAN1PREFIX}/man/man1
|
||||||
.for f in ${BINTEST}
|
.for f in ${BINTEST}
|
||||||
${INSTALL_PROGRAM} ${WRKSRC}/bin/${f} ${PREFIX}/bin
|
${INSTALL_PROGRAM} ${WRKSRC}/bin/${f} ${PREFIX}/bin
|
||||||
.endfor
|
.endfor
|
||||||
.for f in ${MANTEST}
|
.for f in ${MANTEST}
|
||||||
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MANPREFIX}/man/man1
|
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MAN1PREFIX}/man/man1
|
||||||
.endfor
|
.endfor
|
||||||
|
|
||||||
post-install:
|
post-install:
|
||||||
|
|
|
@ -1,9 +1,5 @@
|
||||||
# New ports collection makefile for: postfix
|
# Created by: torstenb
|
||||||
# Date created: 18 Mar 1999
|
|
||||||
# Whom: torstenb
|
|
||||||
#
|
|
||||||
# $FreeBSD$
|
# $FreeBSD$
|
||||||
#
|
|
||||||
|
|
||||||
PORTNAME= postfix
|
PORTNAME= postfix
|
||||||
PORTVERSION= 2.9.5
|
PORTVERSION= 2.9.5
|
||||||
|
@ -18,7 +14,7 @@ MASTER_SITE_SUBDIR= . old related/postfix
|
||||||
DIST_SUBDIR= ${PORTNAME}
|
DIST_SUBDIR= ${PORTNAME}
|
||||||
|
|
||||||
MAINTAINER= sahil@FreeBSD.org
|
MAINTAINER= sahil@FreeBSD.org
|
||||||
COMMENT= A secure alternative to widely-used Sendmail
|
COMMENT= Secure alternative to widely-used Sendmail
|
||||||
|
|
||||||
VDAVERSION= 2.9.5
|
VDAVERSION= 2.9.5
|
||||||
CONFLICTS= courier-0.* postfix-1.* postfix-2.[0-8].* postfix-base-2.[0-8].* \
|
CONFLICTS= courier-0.* postfix-1.* postfix-2.[0-8].* postfix-base-2.[0-8].* \
|
||||||
|
@ -32,36 +28,35 @@ USE_SUBMAKE= yes
|
||||||
USE_PERL5_BUILD=yes
|
USE_PERL5_BUILD=yes
|
||||||
SCRIPTS_ENV+= POSTFIX_DEFAULT_MTA="${POSTFIX_DEFAULT_MTA}"
|
SCRIPTS_ENV+= POSTFIX_DEFAULT_MTA="${POSTFIX_DEFAULT_MTA}"
|
||||||
|
|
||||||
# back compat pull in settings from POSTFIX_OPTIONS for convenience when
|
OPTIONS_DEFINE= PCRE SASL2 TLS BDB MYSQL PGSQL SQLITE OPENLDAP LDAP_SASL \
|
||||||
# make config is run (happens first time port is built, too)
|
CDB NIS VDA TEST SPF INST_BASE
|
||||||
.for o in SASL2 SASLKRB5 SASLKRB5MIT TLS BDB MySQL PgSQL OpenLDAP CDB NIS VDA Test SPF
|
PCRE_DESC= Perl Compatible Regular Expressions
|
||||||
STATUS_${o}=off
|
SASL2_DESC= Cyrus SASLv2 (Simple Auth. and Sec. Layer)
|
||||||
.endfor
|
DOVECOT_DESC= Dovecot 1.x SASL authentication method
|
||||||
.if defined(POSTFIX_OPTIONS)
|
DOVECOT2_DESC= Dovecot 2.x SASL authentication method
|
||||||
. for o in ${POSTFIX_OPTIONS}
|
SASLKRB5_DESC= If your SASL req. Kerberos5, select this
|
||||||
STATUS_${o}=on
|
SASLKMIT_DESC= If your SASL req. MIT Kerberos5, select this
|
||||||
. endfor
|
TLS_DESC= SSL and TLS support
|
||||||
.endif
|
BDB_DESC= Berkeley DB (uses WITH_BDB_VER)
|
||||||
|
MYSQL_DESC= MySQL maps (uses WITH_MYSQL_VER)
|
||||||
|
PGSQL_DESC= PostgreSQL maps (uses DEFAULT_PGSQL_VER)
|
||||||
|
SQLITE_DESC= SQLite maps
|
||||||
|
OPENLDAP_DESC= OpenLDAP maps (uses WITH_OPENLDAP_VER)
|
||||||
|
LDAP_SASL_DESC= OpenLDAP client-to-server SASL auth
|
||||||
|
CDB_DESC= CDB maps lookups
|
||||||
|
NIS_DESC= NIS maps lookups
|
||||||
|
VDA_DESC= VDA (Virtual Delivery Agent 32Bit)
|
||||||
|
TEST_DESC= SMTP/LMTP test server and generator
|
||||||
|
SPF_DESC= SPF support (via libspf2 1.2.x)
|
||||||
|
INST_BASE_DESC= Install into /usr and /etc/postfix
|
||||||
|
|
||||||
OPTIONS= PCRE "Perl Compatible Regular Expressions" on \
|
OPTIONS_RADIO= RG1 RG2
|
||||||
SASL2 "Cyrus SASLv2 (Simple Auth. and Sec. Layer)" ${STATUS_SASL2} \
|
OPTIONS_RADIO_RG1= DOVECOT DOVECOT2
|
||||||
DOVECOT "Dovecot 1.x SASL authentication method" off \
|
OPTIONS_RADIO_RG2= SASLKRB5 SASLKMIT
|
||||||
DOVECOT2 "Dovecot 2.x SASL authentication method" off \
|
RG1_DESC= Dovecot SASL authentication methods
|
||||||
SASLKRB5 "If your SASL req. Kerberos5, select this" ${STATUS_SASLKRB5} \
|
RG2_DESC= Kerberos network authentication protocol type
|
||||||
SASLKMIT "If your SASL req. MIT Kerberos5, select this" ${STATUS_SASLKRB5MIT} \
|
|
||||||
TLS "Enable SSL and TLS support" ${STATUS_TLS} \
|
OPTIONS_DEFAULT= PCRE
|
||||||
BDB "Berkeley DB (uses WITH_BDB_VER)" ${STATUS_BDB} \
|
|
||||||
MYSQL "MySQL maps (uses WITH_MYSQL_VER)" ${STATUS_MySQL} \
|
|
||||||
PGSQL "PostgreSQL maps (uses DEFAULT_PGSQL_VER)" ${STATUS_PgSQL} \
|
|
||||||
SQLITE "SQLite maps" off \
|
|
||||||
OPENLDAP "OpenLDAP maps (uses WITH_OPENLDAP_VER)" ${STATUS_OpenLDAP} \
|
|
||||||
LDAP_SASL "Enable OpenLDAP client-to-server SASL auth" off \
|
|
||||||
CDB "CDB maps lookups" ${STATUS_CDB} \
|
|
||||||
NIS "NIS maps lookups" ${STATUS_NIS} \
|
|
||||||
VDA "VDA (Virtual Delivery Agent 32Bit)" ${STATUS_VDA} \
|
|
||||||
TEST "SMTP/LMTP test server and generator" ${STATUS_Test} \
|
|
||||||
SPF "SPF support (via libspf2 1.2.x)" ${STATUS_SPF} \
|
|
||||||
INST_BASE "Install into /usr and /etc/postfix" off
|
|
||||||
|
|
||||||
.include <bsd.port.options.mk>
|
.include <bsd.port.options.mk>
|
||||||
|
|
||||||
|
@ -122,7 +117,7 @@ POSTFIX_CCARGS+= -DDEF_CONFIG_DIR=\\\"${ETCDIR}\\\" \
|
||||||
# Default requirement for postfix rc script
|
# Default requirement for postfix rc script
|
||||||
_REQUIRE= LOGIN cleanvar
|
_REQUIRE= LOGIN cleanvar
|
||||||
|
|
||||||
.if defined(WITH_PCRE)
|
.if ${PORT_OPTIONS:MPCRE}
|
||||||
LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
|
LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
|
||||||
POSTFIX_CCARGS+= -DHAS_PCRE -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_PCRE -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
||||||
|
@ -130,18 +125,14 @@ POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
||||||
POSTFIX_CCARGS+= -DNO_PCRE
|
POSTFIX_CCARGS+= -DNO_PCRE
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASL2)
|
.if ${PORT_OPTIONS:MSASL2}
|
||||||
LIB_DEPENDS+= sasl2:${PORTSDIR}/security/cyrus-sasl2
|
LIB_DEPENDS+= sasl2:${PORTSDIR}/security/cyrus-sasl2
|
||||||
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${LOCALBASE}/include -I${LOCALBASE}/include/sasl
|
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${LOCALBASE}/include -I${LOCALBASE}/include/sasl
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsasl2 -lpam -lcrypt
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsasl2 -lpam -lcrypt
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_DOVECOT) && defined(WITH_DOVECOT2)
|
.if ${PORT_OPTIONS:MDOVECOT} || ${PORT_OPTIONS:MDOVECOT2}
|
||||||
BROKEN= Select only one Dovecot option
|
.if ${PORT_OPTIONS:MDOVECOT}
|
||||||
.endif
|
|
||||||
|
|
||||||
.if defined(WITH_DOVECOT) || defined(WITH_DOVECOT2)
|
|
||||||
.if defined(WITH_DOVECOT)
|
|
||||||
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot
|
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot
|
||||||
.else
|
.else
|
||||||
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot2
|
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot2
|
||||||
|
@ -150,28 +141,22 @@ POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"
|
||||||
_REQUIRE+= dovecot
|
_REQUIRE+= dovecot
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKRB5)
|
.if ${PORT_OPTIONS:MSASLKRB5}
|
||||||
.if defined(WITH_SASLKMIT)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
POSTFIX_AUXLIBS+= -lkrb5 ${KRB5_EXTR} -lcrypto -lcrypt -lcom_err -lasn1 -lroken
|
POSTFIX_AUXLIBS+= -lkrb5 ${KRB5_EXTR} -lcrypto -lcrypt -lcom_err -lasn1 -lroken
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKMIT)
|
.if ${PORT_OPTIONS:MSASLKMIT}
|
||||||
.if defined(WITH_SASLKRB5)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
LIB_DEPENDS+= krb5.3:${PORTSDIR}/security/krb5
|
LIB_DEPENDS+= krb5.3:${PORTSDIR}/security/krb5
|
||||||
POSTFIX_AUXLIBS+= -Wl,--rpath,$${KRB5_HOME:-${LOCALBASE}}/lib -lkrb5 -lcrypto -lcrypt -lcom_err
|
POSTFIX_AUXLIBS+= -Wl,--rpath,$${KRB5_HOME:-${LOCALBASE}}/lib -lkrb5 -lcrypto -lcrypt -lcom_err
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_TLS)
|
.if ${PORT_OPTIONS:MTLS}
|
||||||
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
||||||
POSTFIX_CCARGS+= -DUSE_TLS -I${OPENSSLINC}
|
POSTFIX_CCARGS+= -DUSE_TLS -I${OPENSSLINC}
|
||||||
POSTFIX_AUXLIBS+= -L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
|
POSTFIX_AUXLIBS+= -L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SPF)
|
.if ${PORT_OPTIONS:MSPF}
|
||||||
LIB_DEPENDS+= spf2.3:${PORTSDIR}/mail/libspf2
|
LIB_DEPENDS+= spf2.3:${PORTSDIR}/mail/libspf2
|
||||||
PATCH_SITES+= ${MASTER_SITE_LOCAL}
|
PATCH_SITES+= ${MASTER_SITE_LOCAL}
|
||||||
PATCH_SITE_SUBDIR= mm
|
PATCH_SITE_SUBDIR= mm
|
||||||
|
@ -184,60 +169,62 @@ PLIST_SUB+= SPF=""
|
||||||
PLIST_SUB+= SPF="@comment "
|
PLIST_SUB+= SPF="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_BDB)
|
.if ${PORT_OPTIONS:MBDB}
|
||||||
USE_BDB= yes
|
USE_BDB= yes
|
||||||
POSTFIX_CCARGS+= -I${BDB_INCLUDE_DIR}
|
POSTFIX_CCARGS+= -I${BDB_INCLUDE_DIR}
|
||||||
POSTFIX_AUXLIBS+= -L${BDB_LIB_DIR} -l${BDB_LIB_NAME}
|
POSTFIX_AUXLIBS+= -L${BDB_LIB_DIR} -l${BDB_LIB_NAME}
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_MYSQL)
|
.if ${PORT_OPTIONS:MMYSQL}
|
||||||
USE_MYSQL= yes
|
USE_MYSQL= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql
|
POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib/mysql -lmysqlclient -lz -lcrypt -lm
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib/mysql -lmysqlclient -lz -lcrypt -lm
|
||||||
_REQUIRE+= mysql
|
_REQUIRE+= mysql
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_PGSQL)
|
.if ${PORT_OPTIONS:MPGSQL}
|
||||||
USE_PGSQL= yes
|
USE_PGSQL= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_PGSQL -I${LOCALBASE}/include -I${LOCALBASE}/pgsql/include
|
POSTFIX_CCARGS+= -DHAS_PGSQL -I${LOCALBASE}/include -I${LOCALBASE}/pgsql/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -L${LOCALBASE}/pgsql/lib -lpq -lcrypt
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -L${LOCALBASE}/pgsql/lib -lpq -lcrypt
|
||||||
_REQUIRE+= postgresql
|
_REQUIRE+= postgresql
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SQLITE)
|
.if ${PORT_OPTIONS:MSQLITE}
|
||||||
USE_SQLITE= yes
|
USE_SQLITE= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_SQLITE -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_SQLITE -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsqlite3
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsqlite3
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_OPENLDAP)
|
.if ${PORT_OPTIONS:MOPENLDAP}
|
||||||
USE_OPENLDAP= yes
|
USE_OPENLDAP= yes
|
||||||
.if defined(WITH_OPENLDAP_VER)
|
.if ${PORT_OPTIONS:MOPENLDAP_VER}
|
||||||
WANT_OPENLDAP_VER= ${WITH_OPENLDAP_VER}
|
WANT_OPENLDAP_VER= ${WITH_OPENLDAP_VER}
|
||||||
.endif
|
.endif
|
||||||
POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lldap -llber
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lldap -llber
|
||||||
_REQUIRE+= slapd
|
_REQUIRE+= slapd
|
||||||
.if defined(WITH_LDAP_SASL)
|
.if ${PORT_OPTIONS:MLDAP_SASL}
|
||||||
.if !defined(WITH_SASL2)
|
.if ! ${PORT_OPTIONS:MSASL2}
|
||||||
BROKEN= Compile with Cyrus SASL to use LDAP_SASL
|
PORT_OPTIONS+=SASL2
|
||||||
.endif
|
.endif
|
||||||
|
.if ${PORT_OPTIONS:MLSASL2}
|
||||||
POSTFIX_CCARGS+= -DUSE_LDAP_SASL
|
POSTFIX_CCARGS+= -DUSE_LDAP_SASL
|
||||||
.endif
|
.endif
|
||||||
.endif
|
.endif
|
||||||
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_CDB)
|
.if ${PORT_OPTIONS:MCDB}
|
||||||
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcdb.a:${PORTSDIR}/databases/tinycdb
|
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcdb.a:${PORTSDIR}/databases/tinycdb
|
||||||
POSTFIX_CCARGS+= -DHAS_CDB -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_CDB -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lcdb
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lcdb
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_NIS)
|
.if ${PORT_OPTIONS:MNIS}
|
||||||
POSTFIX_CCARGS+= -DHAS_NIS
|
POSTFIX_CCARGS+= -DHAS_NIS
|
||||||
_REQUIRE+= ypserv
|
_REQUIRE+= ypserv
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_VDA)
|
.if ${PORT_OPTIONS:MVDA}
|
||||||
PATCH_SITES+= http://vda.sourceforge.net/VDA/:vda
|
PATCH_SITES+= http://vda.sourceforge.net/VDA/:vda
|
||||||
PATCHFILES+= postfix-vda-v11-${VDAVERSION}.patch:vda
|
PATCHFILES+= postfix-vda-v11-${VDAVERSION}.patch:vda
|
||||||
PATCH_DIST_STRIP= -p1
|
PATCH_DIST_STRIP= -p1
|
||||||
|
@ -246,7 +233,7 @@ PLIST_SUB+= VDA=""
|
||||||
PLIST_SUB+= VDA="@comment "
|
PLIST_SUB+= VDA="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_TEST)
|
.if ${PORT_OPTIONS:MTEST}
|
||||||
BINTEST= qmqp-sink qmqp-source smtp-sink smtp-source
|
BINTEST= qmqp-sink qmqp-source smtp-sink smtp-source
|
||||||
MANTEST= qmqp-sink.1 qmqp-source.1 smtp-sink.1 smtp-source.1
|
MANTEST= qmqp-sink.1 qmqp-source.1 smtp-sink.1 smtp-source.1
|
||||||
MAN1+= ${MANTEST}
|
MAN1+= ${MANTEST}
|
||||||
|
@ -255,11 +242,11 @@ PLIST_SUB+= TEST=""
|
||||||
PLIST_SUB+= TEST="@comment "
|
PLIST_SUB+= TEST="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_INST_BASE)
|
.if ${PORT_OPTIONS:MINST_BASE}
|
||||||
PKGNAMESUFFIX= -base
|
PKGNAMESUFFIX= -base
|
||||||
PREFIX= /usr
|
PREFIX= /usr
|
||||||
ETCDIR= /etc/postfix
|
ETCDIR= /etc/postfix
|
||||||
USE_RCORDER= postfix
|
USE_RC_SUBR= postfix
|
||||||
PLIST_SUB+= BASE=""
|
PLIST_SUB+= BASE=""
|
||||||
.else
|
.else
|
||||||
USE_RC_SUBR= postfix
|
USE_RC_SUBR= postfix
|
||||||
|
@ -268,10 +255,10 @@ PLIST_SUB+= BASE="@comment "
|
||||||
|
|
||||||
PLIST_SUB+= PFETC=${ETCDIR}
|
PLIST_SUB+= PFETC=${ETCDIR}
|
||||||
|
|
||||||
.if defined(NOPORTDOCS)
|
.if ${PORT_OPTIONS:MDOCS}
|
||||||
READMEDIR= no
|
|
||||||
.else
|
|
||||||
READMEDIR= ${DOCSDIR}
|
READMEDIR= ${DOCSDIR}
|
||||||
|
.else
|
||||||
|
READMEDIR= no
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
DAEMONDIR= ${PREFIX}/libexec/postfix
|
DAEMONDIR= ${PREFIX}/libexec/postfix
|
||||||
|
@ -297,21 +284,7 @@ REINPLACE= s!^PATH=.*!PATH=/bin:/sbin:/usr/bin:/usr/sbin:${PREFIX}/bin:${PREFIX}
|
||||||
s!($config_directory/(access|aliases|canonical|generic|header_checks|relocated|transport|virtual):f:root:-:644:)p1!\1o!;
|
s!($config_directory/(access|aliases|canonical|generic|header_checks|relocated|transport|virtual):f:root:-:644:)p1!\1o!;
|
||||||
|
|
||||||
pre-patch:
|
pre-patch:
|
||||||
.if defined(POSTFIX_OPTIONS)
|
.if ${PORT_OPTIONS:MSASL2} && ! ${PORT_OPTIONS:MMYSQL} && exists(${LOCALBASE}/lib/libsasl2.a)
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG} "***** ALERT *****"
|
|
||||||
@${ECHO_MSG} "POSTFIX_OPTIONS is no longer supported,"
|
|
||||||
@${ECHO_MSG} "${PORTNAME} uses options, consider running"
|
|
||||||
@${ECHO_MSG} "# make config"
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@sleep 10
|
|
||||||
.endif
|
|
||||||
|
|
||||||
.if defined(WITH_SASL2) && !defined(WITH_MYSQL) && exists(${LOCALBASE}/lib/libsasl2.a)
|
|
||||||
@if /usr/bin/nm ${LOCALBASE}/lib/libsasl2.a | ${GREP} -wq "mysql_init"; then \
|
@if /usr/bin/nm ${LOCALBASE}/lib/libsasl2.a | ${GREP} -wq "mysql_init"; then \
|
||||||
${ECHO_MSG}; \
|
${ECHO_MSG}; \
|
||||||
${ECHO_MSG} "Your SASL2 library it's compiled with MYSQL"; \
|
${ECHO_MSG} "Your SASL2 library it's compiled with MYSQL"; \
|
||||||
|
@ -338,13 +311,13 @@ post-patch:
|
||||||
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
.endfor
|
.endfor
|
||||||
.if defined(WITH_SPF)
|
.if ${PORT_OPTIONS:MSPF}
|
||||||
@${ECHO} '$$readme_directory/SPF_README:f:root:-:644' \
|
@${ECHO} '$$readme_directory/SPF_README:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
||||||
${WRKSRC}/README_FILES/SPF_README
|
${WRKSRC}/README_FILES/SPF_README
|
||||||
.endif
|
.endif
|
||||||
.if defined(WITH_VDA)
|
.if ${PORT_OPTIONS:MVDA}
|
||||||
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
||||||
|
@ -369,12 +342,12 @@ do-install:
|
||||||
sendmail_path=${PREFIX}/sbin/sendmail
|
sendmail_path=${PREFIX}/sbin/sendmail
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
||||||
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MANPREFIX}/man/man1
|
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MAN1PREFIX}/man/man1
|
||||||
.for f in ${BINTEST}
|
.for f in ${BINTEST}
|
||||||
${INSTALL_PROGRAM} ${WRKSRC}/bin/${f} ${PREFIX}/bin
|
${INSTALL_PROGRAM} ${WRKSRC}/bin/${f} ${PREFIX}/bin
|
||||||
.endfor
|
.endfor
|
||||||
.for f in ${MANTEST}
|
.for f in ${MANTEST}
|
||||||
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MANPREFIX}/man/man1
|
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MAN1PREFIX}/man/man1
|
||||||
.endfor
|
.endfor
|
||||||
|
|
||||||
post-install:
|
post-install:
|
||||||
|
|
|
@ -1,9 +1,5 @@
|
||||||
# New ports collection makefile for: postfix
|
# Created by: torstenb
|
||||||
# Date created: 18 Mar 1999
|
|
||||||
# Whom: torstenb
|
|
||||||
#
|
|
||||||
# $FreeBSD$
|
# $FreeBSD$
|
||||||
#
|
|
||||||
|
|
||||||
PORTNAME= postfix
|
PORTNAME= postfix
|
||||||
PORTVERSION= 2.6.18
|
PORTVERSION= 2.6.18
|
||||||
|
@ -18,7 +14,7 @@ MASTER_SITE_SUBDIR= . old related/postfix
|
||||||
DIST_SUBDIR= ${PORTNAME}
|
DIST_SUBDIR= ${PORTNAME}
|
||||||
|
|
||||||
MAINTAINER= sahil@FreeBSD.org
|
MAINTAINER= sahil@FreeBSD.org
|
||||||
COMMENT= A secure alternative to widely-used Sendmail
|
COMMENT= Secure alternative to widely-used Sendmail
|
||||||
|
|
||||||
VDAVERSION= 2.6.5
|
VDAVERSION= 2.6.5
|
||||||
CONFLICTS= courier-0.* postfix-1.* postfix-2.[0-57-9].* postfix-current-2.* \
|
CONFLICTS= courier-0.* postfix-1.* postfix-2.[0-57-9].* postfix-current-2.* \
|
||||||
|
@ -32,32 +28,28 @@ USE_PERL5_BUILD=yes
|
||||||
USE_RC_SUBR= postfix
|
USE_RC_SUBR= postfix
|
||||||
SCRIPTS_ENV+= POSTFIX_DEFAULT_MTA="${POSTFIX_DEFAULT_MTA}"
|
SCRIPTS_ENV+= POSTFIX_DEFAULT_MTA="${POSTFIX_DEFAULT_MTA}"
|
||||||
|
|
||||||
# back compat pull in settings from POSTFIX_OPTIONS for convenience when
|
OPTIONS_DEFINE= PCRE SASL2 DOVECOT TLS BDB MYSQL PGSQL OPENLDAP CDB NIS VDA TEST
|
||||||
# make config is run (happens first time port is built, too)
|
PCRE_DESC= Perl Compatible Regular Expressions
|
||||||
.for o in SASL2 SASLKRB SASLKRB5 SASLKRB5MIT TLS BDB MySQL PgSQL OpenLDAP CDB NIS VDA Test
|
SASL2_DESC= Cyrus SASLv2 (Simple Auth. and Sec. Layer)
|
||||||
STATUS_${o}=off
|
DOVECOT_DESC= Dovecot SASL authentication method
|
||||||
.endfor
|
SASLKRB_DESC= If your SASL req. Kerberos, select this
|
||||||
.if defined(POSTFIX_OPTIONS)
|
SASLKRB5_DESC= If your SASL req. Kerberos5, select this
|
||||||
. for o in ${POSTFIX_OPTIONS}
|
SASLKMIT_DESC= If your SASL req. MIT Kerberos5, select this
|
||||||
STATUS_${o}=on
|
TLS_DESC= Enable SSL and TLS support
|
||||||
. endfor
|
BDB_DESC= Berkeley DB (uses WITH_BDB_VER)
|
||||||
.endif
|
MYSQL_DESC= MySQL maps (uses WITH_MYSQL_VER)
|
||||||
|
PGSQL_DESC= PostgreSQL maps (uses DEFAULT_PGSQL_VER)
|
||||||
|
OPENLDAP_DESC= penLDAP maps (uses WITH_OPENLDAP_VER)
|
||||||
|
CDB_DESC= CDB maps lookups
|
||||||
|
NIS_DESC= NIS maps lookups
|
||||||
|
VDA_DESC= VDA (Virtual Delivery Agent 32Bit)
|
||||||
|
TEST_DESC= SMTP/LMTP test server and generator
|
||||||
|
|
||||||
OPTIONS= PCRE "Perl Compatible Regular Expressions" on \
|
OPTIONS_RADIO= RG1
|
||||||
SASL2 "Cyrus SASLv2 (Simple Auth. and Sec. Layer)" ${STATUS_SASL2} \
|
RG1_DESC= Kerberos network authentication protocol type
|
||||||
DOVECOT "Dovecot SASL authentication method" off \
|
OPTIONS_RADIO_RG1= SASLKRB SASLKRB5 SASLKMIT
|
||||||
SASLKRB "If your SASL req. Kerberos, select this" ${STATUS_SASLKRB} \
|
|
||||||
SASLKRB5 "If your SASL req. Kerberos5, select this" ${STATUS_SASLKRB5} \
|
OPTIONS_DEFAULT= PCRE
|
||||||
SASLKMIT "If your SASL req. MIT Kerberos5, select this" ${STATUS_SASLKRB5MIT} \
|
|
||||||
TLS "Enable SSL and TLS support" ${STATUS_TLS} \
|
|
||||||
BDB "Berkeley DB (uses WITH_BDB_VER)" ${STATUS_BDB} \
|
|
||||||
MYSQL "MySQL maps (uses WITH_MYSQL_VER)" ${STATUS_MySQL} \
|
|
||||||
PGSQL "PostgreSQL maps (uses DEFAULT_PGSQL_VER)" ${STATUS_PgSQL} \
|
|
||||||
OPENLDAP "OpenLDAP maps (uses WITH_OPENLDAP_VER)" ${STATUS_OpenLDAP} \
|
|
||||||
CDB "CDB maps lookups" ${STATUS_CDB} \
|
|
||||||
NIS "NIS maps lookups" ${STATUS_NIS} \
|
|
||||||
VDA "VDA (Virtual Delivery Agent 32Bit)" ${STATUS_VDA} \
|
|
||||||
TEST "SMTP/LMTP test server and generator" ${STATUS_Test}
|
|
||||||
|
|
||||||
.include <bsd.port.options.mk>
|
.include <bsd.port.options.mk>
|
||||||
|
|
||||||
|
@ -111,7 +103,7 @@ POSTFIX_CCARGS+= -DDEF_CONFIG_DIR=\\\"${ETCDIR}\\\" \
|
||||||
# Default requirement for postfix rc script
|
# Default requirement for postfix rc script
|
||||||
_REQUIRE= LOGIN cleanvar
|
_REQUIRE= LOGIN cleanvar
|
||||||
|
|
||||||
.if defined(WITH_PCRE)
|
.if ${PORT_OPTIONS:MPCRE}
|
||||||
LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
|
LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
|
||||||
POSTFIX_CCARGS+= -DHAS_PCRE -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_PCRE -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
||||||
|
@ -119,69 +111,60 @@ POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
||||||
POSTFIX_CCARGS+= -DNO_PCRE
|
POSTFIX_CCARGS+= -DNO_PCRE
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASL2)
|
.if ${PORT_OPTIONS:MSASL2}
|
||||||
LIB_DEPENDS+= sasl2:${PORTSDIR}/security/cyrus-sasl2
|
LIB_DEPENDS+= sasl2:${PORTSDIR}/security/cyrus-sasl2
|
||||||
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${LOCALBASE}/include -I${LOCALBASE}/include/sasl
|
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${LOCALBASE}/include -I${LOCALBASE}/include/sasl
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsasl2 -lpam -lcrypt
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsasl2 -lpam -lcrypt
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_DOVECOT)
|
.if ${PORT_OPTIONS:MDOVECOT}
|
||||||
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot
|
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot
|
||||||
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"
|
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"
|
||||||
_REQUIRE+= dovecot
|
_REQUIRE+= dovecot
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKRB)
|
.if ${PORT_OPTIONS:MSASLKRB}
|
||||||
.if defined(WITH_SASLKRB5) || defined(WITH_SASLKMIT)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
POSTFIX_AUXLIBS+= -lkrb -lcrypto -lcom_err
|
POSTFIX_AUXLIBS+= -lkrb -lcrypto -lcom_err
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKRB5)
|
.if ${PORT_OPTIONS:MSASLKRB5}
|
||||||
.if defined(WITH_SASLKRB) || defined(WITH_SASLKMIT)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
POSTFIX_AUXLIBS+= -lkrb5 ${KRB5_EXTR} -lcrypto -lcrypt -lcom_err -lasn1 -lroken
|
POSTFIX_AUXLIBS+= -lkrb5 ${KRB5_EXTR} -lcrypto -lcrypt -lcom_err -lasn1 -lroken
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKMIT)
|
.if ${PORT_OPTIONS:MSASLKMIT}
|
||||||
.if defined(WITH_SASLKRB) || defined(WITH_SASLKRB5)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
LIB_DEPENDS+= krb5.3:${PORTSDIR}/security/krb5
|
LIB_DEPENDS+= krb5.3:${PORTSDIR}/security/krb5
|
||||||
POSTFIX_AUXLIBS+= -Wl,--rpath,$${KRB5_HOME:-${LOCALBASE}}/lib -lkrb5 -lcrypto -lcrypt -lcom_err
|
POSTFIX_AUXLIBS+= -Wl,--rpath,$${KRB5_HOME:-${LOCALBASE}}/lib -lkrb5 -lcrypto -lcrypt -lcom_err
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_TLS)
|
.if ${PORT_OPTIONS:MTLS}
|
||||||
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
||||||
POSTFIX_CCARGS+= -DUSE_TLS -I${OPENSSLINC}
|
POSTFIX_CCARGS+= -DUSE_TLS -I${OPENSSLINC}
|
||||||
POSTFIX_AUXLIBS+= -L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
|
POSTFIX_AUXLIBS+= -L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_BDB)
|
.if ${PORT_OPTIONS:MBDB}
|
||||||
USE_BDB= yes
|
USE_BDB= yes
|
||||||
POSTFIX_CCARGS+= -I${BDB_INCLUDE_DIR}
|
POSTFIX_CCARGS+= -I${BDB_INCLUDE_DIR}
|
||||||
POSTFIX_AUXLIBS+= -L${BDB_LIB_DIR} -l${BDB_LIB_NAME}
|
POSTFIX_AUXLIBS+= -L${BDB_LIB_DIR} -l${BDB_LIB_NAME}
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_MYSQL)
|
.if ${PORT_OPTIONS:MMYSQL}
|
||||||
USE_MYSQL= yes
|
USE_MYSQL= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql
|
POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib/mysql -lmysqlclient -lz -lcrypt -lm
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib/mysql -lmysqlclient -lz -lcrypt -lm
|
||||||
_REQUIRE+= mysql
|
_REQUIRE+= mysql
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_PGSQL)
|
.if ${PORT_OPTIONS:MPGSQL}
|
||||||
USE_PGSQL= yes
|
USE_PGSQL= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_PGSQL -I${LOCALBASE}/include -I${LOCALBASE}/pgsql/include
|
POSTFIX_CCARGS+= -DHAS_PGSQL -I${LOCALBASE}/include -I${LOCALBASE}/pgsql/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -L${LOCALBASE}/pgsql/lib -lpq -lcrypt
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -L${LOCALBASE}/pgsql/lib -lpq -lcrypt
|
||||||
_REQUIRE+= postgresql
|
_REQUIRE+= postgresql
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_OPENLDAP)
|
.if ${PORT_OPTIONS:MOPENLDAP}
|
||||||
USE_OPENLDAP= yes
|
USE_OPENLDAP= yes
|
||||||
.if defined(WITH_OPENLDAP_VER)
|
.if ${PORT_OPTIONS:MOPENLDAP_VER}
|
||||||
WANT_OPENLDAP_VER= ${WITH_OPENLDAP_VER}
|
WANT_OPENLDAP_VER= ${WITH_OPENLDAP_VER}
|
||||||
.endif
|
.endif
|
||||||
POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include
|
||||||
|
@ -189,19 +172,19 @@ POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lldap -llber
|
||||||
_REQUIRE+= slapd
|
_REQUIRE+= slapd
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_CDB)
|
.if ${PORT_OPTIONS:MCDB}
|
||||||
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcdb.a:${PORTSDIR}/databases/tinycdb
|
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcdb.a:${PORTSDIR}/databases/tinycdb
|
||||||
POSTFIX_CCARGS+= -DHAS_CDB -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_CDB -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lcdb
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lcdb
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_NIS)
|
.if ${PORT_OPTIONS:MNIS}
|
||||||
POSTFIX_CCARGS+= -DHAS_NIS
|
POSTFIX_CCARGS+= -DHAS_NIS
|
||||||
_REQUIRE+= ypserv
|
_REQUIRE+= ypserv
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
# 32Bit VDA patch (64Bit has different patch)
|
# 32Bit VDA patch (64Bit has different patch)
|
||||||
.if defined(WITH_VDA)
|
.if ${PORT_OPTIONS:MVDA}
|
||||||
PATCH_SITES+= http://vda.sourceforge.net/VDA/
|
PATCH_SITES+= http://vda.sourceforge.net/VDA/
|
||||||
PATCHFILES+= postfix-${VDAVERSION}-vda-ng.patch.gz
|
PATCHFILES+= postfix-${VDAVERSION}-vda-ng.patch.gz
|
||||||
PATCH_DIST_STRIP= -p1
|
PATCH_DIST_STRIP= -p1
|
||||||
|
@ -210,7 +193,7 @@ PLIST_SUB+= VDA=""
|
||||||
PLIST_SUB+= VDA="@comment "
|
PLIST_SUB+= VDA="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_TEST)
|
.if ${PORT_OPTIONS:MTEST}
|
||||||
BINTEST= qmqp-sink qmqp-source smtp-sink smtp-source
|
BINTEST= qmqp-sink qmqp-source smtp-sink smtp-source
|
||||||
MANTEST= qmqp-sink.1 qmqp-source.1 smtp-sink.1 smtp-source.1
|
MANTEST= qmqp-sink.1 qmqp-source.1 smtp-sink.1 smtp-source.1
|
||||||
MAN1+= ${MANTEST}
|
MAN1+= ${MANTEST}
|
||||||
|
@ -219,10 +202,10 @@ PLIST_SUB+= TEST=""
|
||||||
PLIST_SUB+= TEST="@comment "
|
PLIST_SUB+= TEST="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(NOPORTDOCS)
|
.if ${PORT_OPTIONS:MDOCS}
|
||||||
READMEDIR= no
|
|
||||||
.else
|
|
||||||
READMEDIR= ${DOCSDIR}
|
READMEDIR= ${DOCSDIR}
|
||||||
|
.else
|
||||||
|
READMEDIR= no
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
DAEMONDIR= ${PREFIX}/libexec/postfix
|
DAEMONDIR= ${PREFIX}/libexec/postfix
|
||||||
|
@ -248,21 +231,7 @@ REINPLACE= s!^PATH=.*!PATH=/bin:/sbin:/usr/bin:/usr/sbin:${PREFIX}/bin:${PREFIX}
|
||||||
s!($config_directory/(access|aliases|canonical|generic|header_checks|relocated|transport|virtual):f:root:-:644:)p1!\1o!;
|
s!($config_directory/(access|aliases|canonical|generic|header_checks|relocated|transport|virtual):f:root:-:644:)p1!\1o!;
|
||||||
|
|
||||||
pre-patch:
|
pre-patch:
|
||||||
.if defined(POSTFIX_OPTIONS)
|
.if ${PORT_OPTIONS:MSASL2} && ! ${PORT_OPTIONS:MMYSQL} && exists(${LOCALBASE}/lib/libsasl2.a)
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG} "***** ALERT *****"
|
|
||||||
@${ECHO_MSG} "POSTFIX_OPTIONS is no longer supported,"
|
|
||||||
@${ECHO_MSG} "${PORTNAME} uses options, consider running"
|
|
||||||
@${ECHO_MSG} "# make config"
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@sleep 10
|
|
||||||
.endif
|
|
||||||
|
|
||||||
.if defined(WITH_SASL2) && !defined(WITH_MYSQL) && exists(${LOCALBASE}/lib/libsasl2.a)
|
|
||||||
@if /usr/bin/nm ${LOCALBASE}/lib/libsasl2.a | ${GREP} -wq "mysql_init"; then \
|
@if /usr/bin/nm ${LOCALBASE}/lib/libsasl2.a | ${GREP} -wq "mysql_init"; then \
|
||||||
${ECHO_MSG}; \
|
${ECHO_MSG}; \
|
||||||
${ECHO_MSG} "Your SASL2 library it's compiled with MYSQL"; \
|
${ECHO_MSG} "Your SASL2 library it's compiled with MYSQL"; \
|
||||||
|
@ -291,7 +260,7 @@ post-patch:
|
||||||
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
.endfor
|
.endfor
|
||||||
.if defined(WITH_VDA)
|
.if ${PORT_OPTIONS:MVDA}
|
||||||
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
||||||
|
@ -316,12 +285,12 @@ do-install:
|
||||||
sendmail_path=${PREFIX}/sbin/sendmail
|
sendmail_path=${PREFIX}/sbin/sendmail
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
||||||
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MANPREFIX}/man/man1
|
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MAN1PREFIX}/man/man1
|
||||||
.for f in ${BINTEST}
|
.for f in ${BINTEST}
|
||||||
${INSTALL_PROGRAM} ${WRKSRC}/bin/${f} ${PREFIX}/bin
|
${INSTALL_PROGRAM} ${WRKSRC}/bin/${f} ${PREFIX}/bin
|
||||||
.endfor
|
.endfor
|
||||||
.for f in ${MANTEST}
|
.for f in ${MANTEST}
|
||||||
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MANPREFIX}/man/man1
|
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MAN1PREFIX}/man/man1
|
||||||
.endfor
|
.endfor
|
||||||
|
|
||||||
post-install:
|
post-install:
|
||||||
|
|
|
@ -1,9 +1,5 @@
|
||||||
# New ports collection makefile for: postfix
|
# Created by: torstenb
|
||||||
# Date created: 18 Mar 1999
|
|
||||||
# Whom: torstenb
|
|
||||||
#
|
|
||||||
# $FreeBSD$
|
# $FreeBSD$
|
||||||
#
|
|
||||||
|
|
||||||
PORTNAME= postfix
|
PORTNAME= postfix
|
||||||
PORTVERSION= 2.7.12
|
PORTVERSION= 2.7.12
|
||||||
|
@ -18,7 +14,7 @@ MASTER_SITE_SUBDIR= . old related/postfix
|
||||||
DIST_SUBDIR= ${PORTNAME}
|
DIST_SUBDIR= ${PORTNAME}
|
||||||
|
|
||||||
MAINTAINER= sahil@FreeBSD.org
|
MAINTAINER= sahil@FreeBSD.org
|
||||||
COMMENT= A secure alternative to widely-used Sendmail
|
COMMENT= Secure alternative to widely-used Sendmail
|
||||||
|
|
||||||
VDAVERSION= 2.7.8
|
VDAVERSION= 2.7.8
|
||||||
CONFLICTS= courier-0.* postfix-1.* postfix-2.[0-689].* postfix-base-2.[0-689].* \
|
CONFLICTS= courier-0.* postfix-1.* postfix-2.[0-689].* postfix-base-2.[0-689].* \
|
||||||
|
@ -32,34 +28,32 @@ USE_SUBMAKE= yes
|
||||||
USE_PERL5_BUILD=yes
|
USE_PERL5_BUILD=yes
|
||||||
SCRIPTS_ENV+= POSTFIX_DEFAULT_MTA="${POSTFIX_DEFAULT_MTA}"
|
SCRIPTS_ENV+= POSTFIX_DEFAULT_MTA="${POSTFIX_DEFAULT_MTA}"
|
||||||
|
|
||||||
# back compat pull in settings from POSTFIX_OPTIONS for convenience when
|
OPTIONS_DEFINE= PCRE SASL2 TLS BDB MYSQL PGSQL OPENLDAP CDB NIS VDA TEST SPF INST_BASE
|
||||||
# make config is run (happens first time port is built, too)
|
PCRE_DESC= Perl Compatible Regular Expressions
|
||||||
.for o in SASL2 SASLKRB5 SASLKRB5MIT TLS BDB MySQL PgSQL OpenLDAP CDB NIS VDA Test SPF
|
SASL2_DESC= Cyrus SASLv2 (Simple Auth. and Sec. Layer)
|
||||||
STATUS_${o}=off
|
DOVECOT_DESC= Dovecot 1.x SASL authentication method
|
||||||
.endfor
|
DOVECOT2_DESC= Dovecot 2.x SASL authentication method
|
||||||
.if defined(POSTFIX_OPTIONS)
|
SASLKRB5_DESC= If your SASL req. Kerberos5, select this
|
||||||
. for o in ${POSTFIX_OPTIONS}
|
SASLKMIT_DESC= If your SASL req. MIT Kerberos5, select this
|
||||||
STATUS_${o}=on
|
TLS_DESC= "Enable SSL and TLS support
|
||||||
. endfor
|
BDB_DESC= Berkeley DB (uses WITH_BDB_VER)
|
||||||
.endif
|
MYSQL_DESC= MySQL maps (uses WITH_MYSQL_VER)
|
||||||
|
PGSQL_DESC= PostgreSQL maps (uses DEFAULT_PGSQL_VER)
|
||||||
|
OPENLDAP_DESC= OpenLDAP maps (uses WITH_OPENLDAP_VER)
|
||||||
|
CDB_DESC= CDB maps lookups
|
||||||
|
NIS_DESC= NIS maps lookups
|
||||||
|
VDA_DESC= VDA (Virtual Delivery Agent 32Bit)
|
||||||
|
TEST_DESC= SMTP/LMTP test server and generator
|
||||||
|
SPF_DESC= SPF support (via libspf2 1.2.x)
|
||||||
|
INST_BASE_DESC= Install into /usr and /etc/postfix
|
||||||
|
|
||||||
OPTIONS= PCRE "Perl Compatible Regular Expressions" on \
|
OPTIONS_RADIO= RG1 RG2
|
||||||
SASL2 "Cyrus SASLv2 (Simple Auth. and Sec. Layer)" ${STATUS_SASL2} \
|
OPTIONS_RADIO_RG1= DOVECOT DOVECOT2
|
||||||
DOVECOT "Dovecot 1.x SASL authentication method" off \
|
OPTIONS_RADIO_RG2= SASLKRB5 SASLKMIT
|
||||||
DOVECOT2 "Dovecot 2.x SASL authentication method" off \
|
RG1_DESC= Dovecot SASL authentication methods
|
||||||
SASLKRB5 "If your SASL req. Kerberos5, select this" ${STATUS_SASLKRB5} \
|
RG2_DESC= Kerberos network authentication protocol type
|
||||||
SASLKMIT "If your SASL req. MIT Kerberos5, select this" ${STATUS_SASLKRB5MIT} \
|
|
||||||
TLS "Enable SSL and TLS support" ${STATUS_TLS} \
|
OPTIONS_DEFAULT= PCRE
|
||||||
BDB "Berkeley DB (uses WITH_BDB_VER)" ${STATUS_BDB} \
|
|
||||||
MYSQL "MySQL maps (uses WITH_MYSQL_VER)" ${STATUS_MySQL} \
|
|
||||||
PGSQL "PostgreSQL maps (uses DEFAULT_PGSQL_VER)" ${STATUS_PgSQL} \
|
|
||||||
OPENLDAP "OpenLDAP maps (uses WITH_OPENLDAP_VER)" ${STATUS_OpenLDAP} \
|
|
||||||
CDB "CDB maps lookups" ${STATUS_CDB} \
|
|
||||||
NIS "NIS maps lookups" ${STATUS_NIS} \
|
|
||||||
VDA "VDA (Virtual Delivery Agent 32Bit)" ${STATUS_VDA} \
|
|
||||||
TEST "SMTP/LMTP test server and generator" ${STATUS_Test} \
|
|
||||||
SPF "SPF support (via libspf2 1.2.x)" ${STATUS_SPF} \
|
|
||||||
INST_BASE "Install into /usr and /etc/postfix" off
|
|
||||||
|
|
||||||
.include <bsd.port.options.mk>
|
.include <bsd.port.options.mk>
|
||||||
|
|
||||||
|
@ -113,7 +107,7 @@ POSTFIX_CCARGS+= -DDEF_CONFIG_DIR=\\\"${ETCDIR}\\\" \
|
||||||
# Default requirement for postfix rc script
|
# Default requirement for postfix rc script
|
||||||
_REQUIRE= LOGIN cleanvar
|
_REQUIRE= LOGIN cleanvar
|
||||||
|
|
||||||
.if defined(WITH_PCRE)
|
.if ${PORT_OPTIONS:MPCRE}
|
||||||
LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
|
LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
|
||||||
POSTFIX_CCARGS+= -DHAS_PCRE -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_PCRE -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
||||||
|
@ -121,18 +115,14 @@ POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
||||||
POSTFIX_CCARGS+= -DNO_PCRE
|
POSTFIX_CCARGS+= -DNO_PCRE
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASL2)
|
.if ${PORT_OPTIONS:MSASL2}
|
||||||
LIB_DEPENDS+= sasl2:${PORTSDIR}/security/cyrus-sasl2
|
LIB_DEPENDS+= sasl2:${PORTSDIR}/security/cyrus-sasl2
|
||||||
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${LOCALBASE}/include -I${LOCALBASE}/include/sasl
|
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${LOCALBASE}/include -I${LOCALBASE}/include/sasl
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsasl2 -lpam -lcrypt
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsasl2 -lpam -lcrypt
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_DOVECOT) && defined(WITH_DOVECOT2)
|
.if ${PORT_OPTIONS:MDOVECOT} || ${PORT_OPTIONS:MDOVECOT2}
|
||||||
BROKEN= Select only one Dovecot option
|
.if ${PORT_OPTIONS:MDOVECOT}
|
||||||
.endif
|
|
||||||
|
|
||||||
.if defined(WITH_DOVECOT) || defined(WITH_DOVECOT2)
|
|
||||||
.if defined(WITH_DOVECOT)
|
|
||||||
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot
|
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot
|
||||||
.else
|
.else
|
||||||
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot2
|
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot2
|
||||||
|
@ -141,28 +131,22 @@ POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"
|
||||||
_REQUIRE+= dovecot
|
_REQUIRE+= dovecot
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKRB5)
|
.if ${PORT_OPTIONS:MSASLKRB5}
|
||||||
.if defined(WITH_SASLKMIT)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
POSTFIX_AUXLIBS+= -lkrb5 ${KRB5_EXTR} -lcrypto -lcrypt -lcom_err -lasn1 -lroken
|
POSTFIX_AUXLIBS+= -lkrb5 ${KRB5_EXTR} -lcrypto -lcrypt -lcom_err -lasn1 -lroken
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKMIT)
|
.if ${PORT_OPTIONS:MSASLKMIT}
|
||||||
.if defined(WITH_SASLKRB5)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
LIB_DEPENDS+= krb5.3:${PORTSDIR}/security/krb5
|
LIB_DEPENDS+= krb5.3:${PORTSDIR}/security/krb5
|
||||||
POSTFIX_AUXLIBS+= -Wl,--rpath,$${KRB5_HOME:-${LOCALBASE}}/lib -lkrb5 -lcrypto -lcrypt -lcom_err
|
POSTFIX_AUXLIBS+= -Wl,--rpath,$${KRB5_HOME:-${LOCALBASE}}/lib -lkrb5 -lcrypto -lcrypt -lcom_err
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_TLS)
|
.if ${PORT_OPTIONS:MTLS}
|
||||||
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
||||||
POSTFIX_CCARGS+= -DUSE_TLS -I${OPENSSLINC}
|
POSTFIX_CCARGS+= -DUSE_TLS -I${OPENSSLINC}
|
||||||
POSTFIX_AUXLIBS+= -L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
|
POSTFIX_AUXLIBS+= -L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SPF)
|
.if ${PORT_OPTIONS:MSPF}
|
||||||
LIB_DEPENDS+= spf2.3:${PORTSDIR}/mail/libspf2
|
LIB_DEPENDS+= spf2.3:${PORTSDIR}/mail/libspf2
|
||||||
PATCH_SITES+= ${MASTER_SITE_LOCAL}
|
PATCH_SITES+= ${MASTER_SITE_LOCAL}
|
||||||
PATCH_SITE_SUBDIR= mm
|
PATCH_SITE_SUBDIR= mm
|
||||||
|
@ -175,29 +159,29 @@ PLIST_SUB+= SPF=""
|
||||||
PLIST_SUB+= SPF="@comment "
|
PLIST_SUB+= SPF="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_BDB)
|
.if ${PORT_OPTIONS:MBDB}
|
||||||
USE_BDB= yes
|
USE_BDB= yes
|
||||||
POSTFIX_CCARGS+= -I${BDB_INCLUDE_DIR}
|
POSTFIX_CCARGS+= -I${BDB_INCLUDE_DIR}
|
||||||
POSTFIX_AUXLIBS+= -L${BDB_LIB_DIR} -l${BDB_LIB_NAME}
|
POSTFIX_AUXLIBS+= -L${BDB_LIB_DIR} -l${BDB_LIB_NAME}
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_MYSQL)
|
.if ${PORT_OPTIONS:MMYSQL}
|
||||||
USE_MYSQL= yes
|
USE_MYSQL= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql
|
POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib/mysql -lmysqlclient -lz -lcrypt -lm
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib/mysql -lmysqlclient -lz -lcrypt -lm
|
||||||
_REQUIRE+= mysql
|
_REQUIRE+= mysql
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_PGSQL)
|
.if ${PORT_OPTIONS:MPGSQL}
|
||||||
USE_PGSQL= yes
|
USE_PGSQL= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_PGSQL -I${LOCALBASE}/include -I${LOCALBASE}/pgsql/include
|
POSTFIX_CCARGS+= -DHAS_PGSQL -I${LOCALBASE}/include -I${LOCALBASE}/pgsql/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -L${LOCALBASE}/pgsql/lib -lpq -lcrypt
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -L${LOCALBASE}/pgsql/lib -lpq -lcrypt
|
||||||
_REQUIRE+= postgresql
|
_REQUIRE+= postgresql
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_OPENLDAP)
|
.if ${PORT_OPTIONS:MOPENLDAP}
|
||||||
USE_OPENLDAP= yes
|
USE_OPENLDAP= yes
|
||||||
.if defined(WITH_OPENLDAP_VER)
|
.if ${PORT_OPTIONS:MOPENLDAP_VER}
|
||||||
WANT_OPENLDAP_VER= ${WITH_OPENLDAP_VER}
|
WANT_OPENLDAP_VER= ${WITH_OPENLDAP_VER}
|
||||||
.endif
|
.endif
|
||||||
POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include
|
||||||
|
@ -205,18 +189,18 @@ POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lldap -llber
|
||||||
_REQUIRE+= slapd
|
_REQUIRE+= slapd
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_CDB)
|
.if ${PORT_OPTIONS:MCDB}
|
||||||
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcdb.a:${PORTSDIR}/databases/tinycdb
|
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcdb.a:${PORTSDIR}/databases/tinycdb
|
||||||
POSTFIX_CCARGS+= -DHAS_CDB -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_CDB -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lcdb
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lcdb
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_NIS)
|
.if ${PORT_OPTIONS:MNIS}
|
||||||
POSTFIX_CCARGS+= -DHAS_NIS
|
POSTFIX_CCARGS+= -DHAS_NIS
|
||||||
_REQUIRE+= ypserv
|
_REQUIRE+= ypserv
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_VDA)
|
.if ${PORT_OPTIONS:MVDA}
|
||||||
PATCH_SITES+= http://vda.sourceforge.net/VDA/:vda
|
PATCH_SITES+= http://vda.sourceforge.net/VDA/:vda
|
||||||
PATCHFILES+= postfix-vda-v10-${VDAVERSION}.patch:vda
|
PATCHFILES+= postfix-vda-v10-${VDAVERSION}.patch:vda
|
||||||
PATCH_DIST_STRIP= -p1
|
PATCH_DIST_STRIP= -p1
|
||||||
|
@ -225,7 +209,7 @@ PLIST_SUB+= VDA=""
|
||||||
PLIST_SUB+= VDA="@comment "
|
PLIST_SUB+= VDA="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_TEST)
|
.if ${PORT_OPTIONS:MTEST}
|
||||||
BINTEST= qmqp-sink qmqp-source smtp-sink smtp-source
|
BINTEST= qmqp-sink qmqp-source smtp-sink smtp-source
|
||||||
MANTEST= qmqp-sink.1 qmqp-source.1 smtp-sink.1 smtp-source.1
|
MANTEST= qmqp-sink.1 qmqp-source.1 smtp-sink.1 smtp-source.1
|
||||||
MAN1+= ${MANTEST}
|
MAN1+= ${MANTEST}
|
||||||
|
@ -234,11 +218,11 @@ PLIST_SUB+= TEST=""
|
||||||
PLIST_SUB+= TEST="@comment "
|
PLIST_SUB+= TEST="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_INST_BASE)
|
.if ${PORT_OPTIONS:MINST_BASE}
|
||||||
PKGNAMESUFFIX= -base
|
PKGNAMESUFFIX= -base
|
||||||
PREFIX= /usr
|
PREFIX= /usr
|
||||||
ETCDIR= /etc/postfix
|
ETCDIR= /etc/postfix
|
||||||
USE_RCORDER= postfix
|
USE_RC_SUBR= postfix
|
||||||
PLIST_SUB+= BASE=""
|
PLIST_SUB+= BASE=""
|
||||||
.else
|
.else
|
||||||
USE_RC_SUBR= postfix
|
USE_RC_SUBR= postfix
|
||||||
|
@ -247,10 +231,10 @@ PLIST_SUB+= BASE="@comment "
|
||||||
|
|
||||||
PLIST_SUB+= PFETC=${ETCDIR}
|
PLIST_SUB+= PFETC=${ETCDIR}
|
||||||
|
|
||||||
.if defined(NOPORTDOCS)
|
.if ${PORT_OPTIONS:MDOCS}
|
||||||
READMEDIR= no
|
|
||||||
.else
|
|
||||||
READMEDIR= ${DOCSDIR}
|
READMEDIR= ${DOCSDIR}
|
||||||
|
.else
|
||||||
|
READMEDIR= no
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
DAEMONDIR= ${PREFIX}/libexec/postfix
|
DAEMONDIR= ${PREFIX}/libexec/postfix
|
||||||
|
@ -276,21 +260,7 @@ REINPLACE= s!^PATH=.*!PATH=/bin:/sbin:/usr/bin:/usr/sbin:${PREFIX}/bin:${PREFIX}
|
||||||
s!($config_directory/(access|aliases|canonical|generic|header_checks|relocated|transport|virtual):f:root:-:644:)p1!\1o!;
|
s!($config_directory/(access|aliases|canonical|generic|header_checks|relocated|transport|virtual):f:root:-:644:)p1!\1o!;
|
||||||
|
|
||||||
pre-patch:
|
pre-patch:
|
||||||
.if defined(POSTFIX_OPTIONS)
|
.if ${PORT_OPTIONS:MSASL2} && ! ${PORT_OPTIONS:MMYSQL} && exists(${LOCALBASE}/lib/libsasl2.a)
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG} "***** ALERT *****"
|
|
||||||
@${ECHO_MSG} "POSTFIX_OPTIONS is no longer supported,"
|
|
||||||
@${ECHO_MSG} "${PORTNAME} uses options, consider running"
|
|
||||||
@${ECHO_MSG} "# make config"
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@sleep 10
|
|
||||||
.endif
|
|
||||||
|
|
||||||
.if defined(WITH_SASL2) && !defined(WITH_MYSQL) && exists(${LOCALBASE}/lib/libsasl2.a)
|
|
||||||
@if /usr/bin/nm ${LOCALBASE}/lib/libsasl2.a | ${GREP} -wq "mysql_init"; then \
|
@if /usr/bin/nm ${LOCALBASE}/lib/libsasl2.a | ${GREP} -wq "mysql_init"; then \
|
||||||
${ECHO_MSG}; \
|
${ECHO_MSG}; \
|
||||||
${ECHO_MSG} "Your SASL2 library it's compiled with MYSQL"; \
|
${ECHO_MSG} "Your SASL2 library it's compiled with MYSQL"; \
|
||||||
|
@ -319,13 +289,13 @@ post-patch:
|
||||||
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
.endfor
|
.endfor
|
||||||
.if defined(WITH_SPF)
|
.if ${PORT_OPTIONS:MSPF}
|
||||||
@${ECHO} '$$readme_directory/SPF_README:f:root:-:644' \
|
@${ECHO} '$$readme_directory/SPF_README:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
||||||
${WRKSRC}/README_FILES/SPF_README
|
${WRKSRC}/README_FILES/SPF_README
|
||||||
.endif
|
.endif
|
||||||
.if defined(WITH_VDA)
|
.if ${PORT_OPTIONS:MVDA}
|
||||||
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
||||||
|
@ -350,12 +320,12 @@ do-install:
|
||||||
sendmail_path=${PREFIX}/sbin/sendmail
|
sendmail_path=${PREFIX}/sbin/sendmail
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
||||||
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MANPREFIX}/man/man1
|
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MAN1PREFIX}/man/man1
|
||||||
.for f in ${BINTEST}
|
.for f in ${BINTEST}
|
||||||
${INSTALL_PROGRAM} ${WRKSRC}/bin/${f} ${PREFIX}/bin
|
${INSTALL_PROGRAM} ${WRKSRC}/bin/${f} ${PREFIX}/bin
|
||||||
.endfor
|
.endfor
|
||||||
.for f in ${MANTEST}
|
.for f in ${MANTEST}
|
||||||
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MANPREFIX}/man/man1
|
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MAN1PREFIX}/man/man1
|
||||||
.endfor
|
.endfor
|
||||||
|
|
||||||
post-install:
|
post-install:
|
||||||
|
|
|
@ -1,9 +1,5 @@
|
||||||
# New ports collection makefile for: postfix
|
# Created by: torstenb
|
||||||
# Date created: 18 Mar 1999
|
|
||||||
# Whom: torstenb
|
|
||||||
#
|
|
||||||
# $FreeBSD$
|
# $FreeBSD$
|
||||||
#
|
|
||||||
|
|
||||||
PORTNAME= postfix
|
PORTNAME= postfix
|
||||||
PORTVERSION= 2.8.13
|
PORTVERSION= 2.8.13
|
||||||
|
@ -18,7 +14,7 @@ MASTER_SITE_SUBDIR= . old related/postfix
|
||||||
DIST_SUBDIR= ${PORTNAME}
|
DIST_SUBDIR= ${PORTNAME}
|
||||||
|
|
||||||
MAINTAINER= sahil@FreeBSD.org
|
MAINTAINER= sahil@FreeBSD.org
|
||||||
COMMENT= A secure alternative to widely-used Sendmail
|
COMMENT= Secure alternative to widely-used Sendmail
|
||||||
|
|
||||||
VDAVERSION= 2.8.13
|
VDAVERSION= 2.8.13
|
||||||
CONFLICTS= courier-0.* postfix-1.* postfix-2.[0-79].* postfix-base-2.[0-79].* \
|
CONFLICTS= courier-0.* postfix-1.* postfix-2.[0-79].* postfix-base-2.[0-79].* \
|
||||||
|
@ -34,36 +30,35 @@ USE_SUBMAKE= yes
|
||||||
USE_PERL5_BUILD=yes
|
USE_PERL5_BUILD=yes
|
||||||
SCRIPTS_ENV+= POSTFIX_DEFAULT_MTA="${POSTFIX_DEFAULT_MTA}"
|
SCRIPTS_ENV+= POSTFIX_DEFAULT_MTA="${POSTFIX_DEFAULT_MTA}"
|
||||||
|
|
||||||
# back compat pull in settings from POSTFIX_OPTIONS for convenience when
|
OPTIONS_DEFINE= PCRE SASL2 TLS BDB MYSQL PGSQL SQLITE OPENLDAP \
|
||||||
# make config is run (happens first time port is built, too)
|
LDAP_SASL CDB NIS VDA TEST SPF INST_BASE
|
||||||
.for o in SASL2 SASLKRB5 SASLKRB5MIT TLS BDB MySQL PgSQL OpenLDAP CDB NIS VDA Test SPF
|
PCRE_DESC= Perl Compatible Regular Expressions
|
||||||
STATUS_${o}=off
|
SASL2_DESC= Cyrus SASLv2 (Simple Auth. and Sec. Layer)
|
||||||
.endfor
|
DOVECOT_DESC= Dovecot 1.x SASL authentication method
|
||||||
.if defined(POSTFIX_OPTIONS)
|
DOVECOT2_DESC= Dovecot 2.x SASL authentication method
|
||||||
. for o in ${POSTFIX_OPTIONS}
|
SASLKRB5_DESC= If your SASL req. Kerberos5, select this
|
||||||
STATUS_${o}=on
|
SASLKMIT_DESC= If your SASL req. MIT Kerberos5, select this
|
||||||
. endfor
|
TLS_DESC= SSL and TLS support
|
||||||
.endif
|
BDB_DESC= Berkeley DB (uses WITH_BDB_VER)
|
||||||
|
MYSQL_DESC= MySQL maps (uses WITH_MYSQL_VER)
|
||||||
|
PGSQL_DESC= PostgreSQL maps (uses DEFAULT_PGSQL_VER)
|
||||||
|
SQLITE_DESC= SQLite maps
|
||||||
|
OPENLDAP_DESC= OpenLDAP maps (uses WITH_OPENLDAP_VER)
|
||||||
|
LDAP_SASL_DESC= OpenLDAP client-to-server SASL auth
|
||||||
|
CDB_DESC= CDB maps lookups
|
||||||
|
NIS_DESC= NIS maps lookups
|
||||||
|
VDA_DESC= VDA (Virtual Delivery Agent 32Bit)
|
||||||
|
TEST_DESC= SMTP/LMTP test server and generator
|
||||||
|
SPF_DESC= SPF support (via libspf2 1.2.x)
|
||||||
|
INST_BASE_DESC= Install into /usr and /etc/postfix
|
||||||
|
|
||||||
OPTIONS= PCRE "Perl Compatible Regular Expressions" on \
|
OPTIONS_RADIO= RG1 RG2
|
||||||
SASL2 "Cyrus SASLv2 (Simple Auth. and Sec. Layer)" ${STATUS_SASL2} \
|
OPTIONS_RADIO_RG1= DOVECOT DOVECOT2
|
||||||
DOVECOT "Dovecot 1.x SASL authentication method" off \
|
OPTIONS_RADIO_RG2= SASLKRB5 SASLKMIT
|
||||||
DOVECOT2 "Dovecot 2.x SASL authentication method" off \
|
RG1_DESC= Dovecot SASL authentication methods
|
||||||
SASLKRB5 "If your SASL req. Kerberos5, select this" ${STATUS_SASLKRB5} \
|
RG2_DESC= Kerberos network authentication protocol type
|
||||||
SASLKMIT "If your SASL req. MIT Kerberos5, select this" ${STATUS_SASLKRB5MIT} \
|
|
||||||
TLS "Enable SSL and TLS support" ${STATUS_TLS} \
|
OPTIONS_DEFAULT= PCRE
|
||||||
BDB "Berkeley DB (uses WITH_BDB_VER)" ${STATUS_BDB} \
|
|
||||||
MYSQL "MySQL maps (uses WITH_MYSQL_VER)" ${STATUS_MySQL} \
|
|
||||||
PGSQL "PostgreSQL maps (uses DEFAULT_PGSQL_VER)" ${STATUS_PgSQL} \
|
|
||||||
SQLITE "SQLite maps" off \
|
|
||||||
OPENLDAP "OpenLDAP maps (uses WITH_OPENLDAP_VER)" ${STATUS_OpenLDAP} \
|
|
||||||
LDAP_SASL "Enable OpenLDAP client-to-server SASL auth" off \
|
|
||||||
CDB "CDB maps lookups" ${STATUS_CDB} \
|
|
||||||
NIS "NIS maps lookups" ${STATUS_NIS} \
|
|
||||||
VDA "VDA (Virtual Delivery Agent 32Bit)" ${STATUS_VDA} \
|
|
||||||
TEST "SMTP/LMTP test server and generator" ${STATUS_Test} \
|
|
||||||
SPF "SPF support (via libspf2 1.2.x)" ${STATUS_SPF} \
|
|
||||||
INST_BASE "Install into /usr and /etc/postfix" off
|
|
||||||
|
|
||||||
.include <bsd.port.options.mk>
|
.include <bsd.port.options.mk>
|
||||||
|
|
||||||
|
@ -124,7 +119,7 @@ POSTFIX_CCARGS+= -DDEF_CONFIG_DIR=\\\"${ETCDIR}\\\" \
|
||||||
# Default requirement for postfix rc script
|
# Default requirement for postfix rc script
|
||||||
_REQUIRE= LOGIN cleanvar
|
_REQUIRE= LOGIN cleanvar
|
||||||
|
|
||||||
.if defined(WITH_PCRE)
|
.if ${PORT_OPTIONS:MPCRE}
|
||||||
LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
|
LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
|
||||||
POSTFIX_CCARGS+= -DHAS_PCRE -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_PCRE -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
||||||
|
@ -132,18 +127,14 @@ POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lpcre
|
||||||
POSTFIX_CCARGS+= -DNO_PCRE
|
POSTFIX_CCARGS+= -DNO_PCRE
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASL2)
|
.if ${PORT_OPTIONS:MSASL2}
|
||||||
LIB_DEPENDS+= sasl2:${PORTSDIR}/security/cyrus-sasl2
|
LIB_DEPENDS+= sasl2:${PORTSDIR}/security/cyrus-sasl2
|
||||||
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${LOCALBASE}/include -I${LOCALBASE}/include/sasl
|
POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I${LOCALBASE}/include -I${LOCALBASE}/include/sasl
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsasl2 -lpam -lcrypt
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsasl2 -lpam -lcrypt
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_DOVECOT) && defined(WITH_DOVECOT2)
|
.if ${PORT_OPTIONS:MDOVECOT} || ${PORT_OPTIONS:MDOVECOT2}
|
||||||
BROKEN= Select only one Dovecot option
|
.if ${PORT_OPTIONS:MDOVECOT}
|
||||||
.endif
|
|
||||||
|
|
||||||
.if defined(WITH_DOVECOT) || defined(WITH_DOVECOT2)
|
|
||||||
.if defined(WITH_DOVECOT)
|
|
||||||
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot
|
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot
|
||||||
.else
|
.else
|
||||||
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot2
|
RUN_DEPENDS+= dovecot:${PORTSDIR}/mail/dovecot2
|
||||||
|
@ -152,28 +143,22 @@ POSTFIX_CCARGS+= -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\"
|
||||||
_REQUIRE+= dovecot
|
_REQUIRE+= dovecot
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKRB5)
|
.if ${PORT_OPTIONS:MSASLKRB5}
|
||||||
.if defined(WITH_SASLKMIT)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
POSTFIX_AUXLIBS+= -lkrb5 ${KRB5_EXTR} -lcrypto -lcrypt -lcom_err -lasn1 -lroken
|
POSTFIX_AUXLIBS+= -lkrb5 ${KRB5_EXTR} -lcrypto -lcrypt -lcom_err -lasn1 -lroken
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SASLKMIT)
|
.if ${PORT_OPTIONS:MSASLKMIT}
|
||||||
.if defined(WITH_SASLKRB5)
|
|
||||||
BROKEN= Select only one SASL Kerberos option
|
|
||||||
.endif
|
|
||||||
LIB_DEPENDS+= krb5.3:${PORTSDIR}/security/krb5
|
LIB_DEPENDS+= krb5.3:${PORTSDIR}/security/krb5
|
||||||
POSTFIX_AUXLIBS+= -Wl,--rpath,$${KRB5_HOME:-${LOCALBASE}}/lib -lkrb5 -lcrypto -lcrypt -lcom_err
|
POSTFIX_AUXLIBS+= -Wl,--rpath,$${KRB5_HOME:-${LOCALBASE}}/lib -lkrb5 -lcrypto -lcrypt -lcom_err
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_TLS)
|
.if ${PORT_OPTIONS:MTLS}
|
||||||
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
||||||
POSTFIX_CCARGS+= -DUSE_TLS -I${OPENSSLINC}
|
POSTFIX_CCARGS+= -DUSE_TLS -I${OPENSSLINC}
|
||||||
POSTFIX_AUXLIBS+= -L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
|
POSTFIX_AUXLIBS+= -L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SPF)
|
.if ${PORT_OPTIONS:MSPF}
|
||||||
LIB_DEPENDS+= spf2.3:${PORTSDIR}/mail/libspf2
|
LIB_DEPENDS+= spf2.3:${PORTSDIR}/mail/libspf2
|
||||||
PATCH_SITES+= ${MASTER_SITE_LOCAL}
|
PATCH_SITES+= ${MASTER_SITE_LOCAL}
|
||||||
PATCH_SITE_SUBDIR= mm
|
PATCH_SITE_SUBDIR= mm
|
||||||
|
@ -186,60 +171,62 @@ PLIST_SUB+= SPF=""
|
||||||
PLIST_SUB+= SPF="@comment "
|
PLIST_SUB+= SPF="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_BDB)
|
.if ${PORT_OPTIONS:MBDB}
|
||||||
USE_BDB= yes
|
USE_BDB= yes
|
||||||
POSTFIX_CCARGS+= -I${BDB_INCLUDE_DIR}
|
POSTFIX_CCARGS+= -I${BDB_INCLUDE_DIR}
|
||||||
POSTFIX_AUXLIBS+= -L${BDB_LIB_DIR} -l${BDB_LIB_NAME}
|
POSTFIX_AUXLIBS+= -L${BDB_LIB_DIR} -l${BDB_LIB_NAME}
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_MYSQL)
|
.if ${PORT_OPTIONS:MMYSQL}
|
||||||
USE_MYSQL= yes
|
USE_MYSQL= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql
|
POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib/mysql -lmysqlclient -lz -lcrypt -lm
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib/mysql -lmysqlclient -lz -lcrypt -lm
|
||||||
_REQUIRE+= mysql
|
_REQUIRE+= mysql
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_PGSQL)
|
.if ${PORT_OPTIONS:MPGSQL}
|
||||||
USE_PGSQL= yes
|
USE_PGSQL= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_PGSQL -I${LOCALBASE}/include -I${LOCALBASE}/pgsql/include
|
POSTFIX_CCARGS+= -DHAS_PGSQL -I${LOCALBASE}/include -I${LOCALBASE}/pgsql/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -L${LOCALBASE}/pgsql/lib -lpq -lcrypt
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -L${LOCALBASE}/pgsql/lib -lpq -lcrypt
|
||||||
_REQUIRE+= postgresql
|
_REQUIRE+= postgresql
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_SQLITE)
|
.if ${PORT_OPTIONS:MSQLITE}
|
||||||
USE_SQLITE= yes
|
USE_SQLITE= yes
|
||||||
POSTFIX_CCARGS+= -DHAS_SQLITE -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_SQLITE -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsqlite3
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lsqlite3
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_OPENLDAP)
|
.if ${PORT_OPTIONS:MOPENLDAP}
|
||||||
USE_OPENLDAP= yes
|
USE_OPENLDAP= yes
|
||||||
.if defined(WITH_OPENLDAP_VER)
|
.if ${PORT_OPTIONS:MOPENLDAP_VER}
|
||||||
WANT_OPENLDAP_VER= ${WITH_OPENLDAP_VER}
|
WANT_OPENLDAP_VER= ${WITH_OPENLDAP_VER}
|
||||||
.endif
|
.endif
|
||||||
POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lldap -llber
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lldap -llber
|
||||||
_REQUIRE+= slapd
|
_REQUIRE+= slapd
|
||||||
.if defined(WITH_LDAP_SASL)
|
.if ${PORT_OPTIONS:MLDAP_SASL}
|
||||||
.if !defined(WITH_SASL2)
|
.if ! ${PORT_OPTIONS:MSASL2}
|
||||||
BROKEN= Compile with Cyrus SASL to use LDAP_SASL
|
PORT_OPTIONS+=SASL2
|
||||||
.endif
|
.endif
|
||||||
|
.if ${PORT_OPTIONS:MLSASL2}
|
||||||
POSTFIX_CCARGS+= -DUSE_LDAP_SASL
|
POSTFIX_CCARGS+= -DUSE_LDAP_SASL
|
||||||
.endif
|
.endif
|
||||||
.endif
|
.endif
|
||||||
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_CDB)
|
.if ${PORT_OPTIONS:MCDB}
|
||||||
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcdb.a:${PORTSDIR}/databases/tinycdb
|
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcdb.a:${PORTSDIR}/databases/tinycdb
|
||||||
POSTFIX_CCARGS+= -DHAS_CDB -I${LOCALBASE}/include
|
POSTFIX_CCARGS+= -DHAS_CDB -I${LOCALBASE}/include
|
||||||
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lcdb
|
POSTFIX_AUXLIBS+= -L${LOCALBASE}/lib -lcdb
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_NIS)
|
.if ${PORT_OPTIONS:MNIS}
|
||||||
POSTFIX_CCARGS+= -DHAS_NIS
|
POSTFIX_CCARGS+= -DHAS_NIS
|
||||||
_REQUIRE+= ypserv
|
_REQUIRE+= ypserv
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_VDA)
|
.if ${PORT_OPTIONS:MVDA}
|
||||||
PATCH_SITES+= http://vda.sourceforge.net/VDA/:vda
|
PATCH_SITES+= http://vda.sourceforge.net/VDA/:vda
|
||||||
PATCHFILES+= postfix-vda-v10-${VDAVERSION}.patch:vda
|
PATCHFILES+= postfix-vda-v10-${VDAVERSION}.patch:vda
|
||||||
PATCH_DIST_STRIP= -p1
|
PATCH_DIST_STRIP= -p1
|
||||||
|
@ -248,7 +235,7 @@ PLIST_SUB+= VDA=""
|
||||||
PLIST_SUB+= VDA="@comment "
|
PLIST_SUB+= VDA="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_TEST)
|
.if ${PORT_OPTIONS:MTEST}
|
||||||
BINTEST= qmqp-sink qmqp-source smtp-sink smtp-source
|
BINTEST= qmqp-sink qmqp-source smtp-sink smtp-source
|
||||||
MANTEST= qmqp-sink.1 qmqp-source.1 smtp-sink.1 smtp-source.1
|
MANTEST= qmqp-sink.1 qmqp-source.1 smtp-sink.1 smtp-source.1
|
||||||
MAN1+= ${MANTEST}
|
MAN1+= ${MANTEST}
|
||||||
|
@ -257,11 +244,11 @@ PLIST_SUB+= TEST=""
|
||||||
PLIST_SUB+= TEST="@comment "
|
PLIST_SUB+= TEST="@comment "
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
.if defined(WITH_INST_BASE)
|
.if ${PORT_OPTIONS:MINST_BASE}
|
||||||
PKGNAMESUFFIX= -base
|
PKGNAMESUFFIX= -base
|
||||||
PREFIX= /usr
|
PREFIX= /usr
|
||||||
ETCDIR= /etc/postfix
|
ETCDIR= /etc/postfix
|
||||||
USE_RCORDER= postfix
|
USE_RC_SUBR= postfix
|
||||||
PLIST_SUB+= BASE=""
|
PLIST_SUB+= BASE=""
|
||||||
.else
|
.else
|
||||||
USE_RC_SUBR= postfix
|
USE_RC_SUBR= postfix
|
||||||
|
@ -270,10 +257,10 @@ PLIST_SUB+= BASE="@comment "
|
||||||
|
|
||||||
PLIST_SUB+= PFETC=${ETCDIR}
|
PLIST_SUB+= PFETC=${ETCDIR}
|
||||||
|
|
||||||
.if defined(NOPORTDOCS)
|
.if ${PORT_OPTIONS:MDOCS}
|
||||||
READMEDIR= no
|
|
||||||
.else
|
|
||||||
READMEDIR= ${DOCSDIR}
|
READMEDIR= ${DOCSDIR}
|
||||||
|
.else
|
||||||
|
READMEDIR= no
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
DAEMONDIR= ${PREFIX}/libexec/postfix
|
DAEMONDIR= ${PREFIX}/libexec/postfix
|
||||||
|
@ -299,21 +286,7 @@ REINPLACE= s!^PATH=.*!PATH=/bin:/sbin:/usr/bin:/usr/sbin:${PREFIX}/bin:${PREFIX}
|
||||||
s!($config_directory/(access|aliases|canonical|generic|header_checks|relocated|transport|virtual):f:root:-:644:)p1!\1o!;
|
s!($config_directory/(access|aliases|canonical|generic|header_checks|relocated|transport|virtual):f:root:-:644:)p1!\1o!;
|
||||||
|
|
||||||
pre-patch:
|
pre-patch:
|
||||||
.if defined(POSTFIX_OPTIONS)
|
.if ${PORT_OPTIONS:MSASL2} && ! ${PORT_OPTIONS:MMYSQL} && exists(${LOCALBASE}/lib/libsasl2.a)
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG} "***** ALERT *****"
|
|
||||||
@${ECHO_MSG} "POSTFIX_OPTIONS is no longer supported,"
|
|
||||||
@${ECHO_MSG} "${PORTNAME} uses options, consider running"
|
|
||||||
@${ECHO_MSG} "# make config"
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@${ECHO_MSG}
|
|
||||||
@sleep 10
|
|
||||||
.endif
|
|
||||||
|
|
||||||
.if defined(WITH_SASL2) && !defined(WITH_MYSQL) && exists(${LOCALBASE}/lib/libsasl2.a)
|
|
||||||
@if /usr/bin/nm ${LOCALBASE}/lib/libsasl2.a | ${GREP} -wq "mysql_init"; then \
|
@if /usr/bin/nm ${LOCALBASE}/lib/libsasl2.a | ${GREP} -wq "mysql_init"; then \
|
||||||
${ECHO_MSG}; \
|
${ECHO_MSG}; \
|
||||||
${ECHO_MSG} "Your SASL2 library it's compiled with MYSQL"; \
|
${ECHO_MSG} "Your SASL2 library it's compiled with MYSQL"; \
|
||||||
|
@ -340,13 +313,13 @@ post-patch:
|
||||||
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
.endfor
|
.endfor
|
||||||
.if defined(WITH_SPF)
|
.if ${PORT_OPTIONS:MSPF}
|
||||||
@${ECHO} '$$readme_directory/SPF_README:f:root:-:644' \
|
@${ECHO} '$$readme_directory/SPF_README:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
||||||
${WRKSRC}/README_FILES/SPF_README
|
${WRKSRC}/README_FILES/SPF_README
|
||||||
.endif
|
.endif
|
||||||
.if defined(WITH_VDA)
|
.if ${PORT_OPTIONS:MVDA}
|
||||||
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
||||||
>> ${WRKSRC}/conf/postfix-files
|
>> ${WRKSRC}/conf/postfix-files
|
||||||
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
@${REINPLACE_CMD} -E -e '${REINPLACE}' \
|
||||||
|
@ -371,12 +344,12 @@ do-install:
|
||||||
sendmail_path=${PREFIX}/sbin/sendmail
|
sendmail_path=${PREFIX}/sbin/sendmail
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
||||||
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MANPREFIX}/man/man1
|
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MAN1PREFIX}/man/man1
|
||||||
.for f in ${BINTEST}
|
.for f in ${BINTEST}
|
||||||
${INSTALL_PROGRAM} ${WRKSRC}/bin/${f} ${PREFIX}/bin
|
${INSTALL_PROGRAM} ${WRKSRC}/bin/${f} ${PREFIX}/bin
|
||||||
.endfor
|
.endfor
|
||||||
.for f in ${MANTEST}
|
.for f in ${MANTEST}
|
||||||
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MANPREFIX}/man/man1
|
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MAN1PREFIX}/man/man1
|
||||||
.endfor
|
.endfor
|
||||||
|
|
||||||
post-install:
|
post-install:
|
||||||
|
|
Loading…
Add table
Reference in a new issue