From 0db11f98fcf4f96459961c17607ac25a2559fff9 Mon Sep 17 00:00:00 2001 From: torstenb Date: Sun, 13 Feb 2000 20:17:43 +0000 Subject: - Upgrade to Postfix 19991231pl04 - Stylistic changes in Makefile - Changes in packaging, esp. pkg/INSTALL --- mail/postfix25/Makefile | 37 ++++++++++------------ mail/postfix25/distinfo | 2 +- mail/postfix25/pkg-install | 77 +++++++++++++++++++++++++++------------------- mail/postfix25/pkg-plist | 4 +-- 4 files changed, 64 insertions(+), 56 deletions(-) (limited to 'mail/postfix25') diff --git a/mail/postfix25/Makefile b/mail/postfix25/Makefile index 8da005d8623b..bc3a5c4c17be 100644 --- a/mail/postfix25/Makefile +++ b/mail/postfix25/Makefile @@ -6,8 +6,8 @@ # $FreeBSD$ # -DISTNAME= postfix-19991231-pl03 -PKGNAME= postfix-19991231.03 +DISTNAME= postfix-19991231-pl04 +PKGNAME= postfix-19991231.04 CATEGORIES= mail MASTER_SITES= ftp://ftp.merit.edu/postfix/official/ \ ftp://ftp.snoopy.net/pub/mirrors/postfix/official/ \ @@ -22,17 +22,17 @@ MAINTAINER= torstenb@FreeBSD.org # WARNING: this is based on a patch submitted by a user and has not been # tested. Use it at your own risk ! .if defined(USE_MYSQL) && ${USE_MYSQL} == YES -BUILD_DEPENDS+= ${PREFIX}/lib/mysql/libmysqlclient.a:${PORTSDIR}/databases/mysql322-client -POSTFIX_CCARGS+= -DHAS_MYSQL -I${PREFIX}/include/mysql -POSTFIX_AUXLIBS+= ${PREFIX}/lib/mysql/libmysqlclient.a -lm +BUILD_DEPENDS+= ${LOCALBASE}/lib/mysql/libmysqlclient.a:${PORTSDIR}/databases/mysql322-client +POSTFIX_CCARGS+= -DHAS_MYSQL -I${LOCALBASE}/include/mysql +POSTFIX_AUXLIBS+= ${LOCALBASE}/lib/mysql/libmysqlclient.a -lm .endif # WARNING: this is based on a patch submitted by a user and has not been # tested. Use it at your own risk ! .if defined(USE_LDAP) && ${USE_LDAP} == YES -BUILD_DEPENDS+= ${PREFIX}/lib/libldap.a:${PORTSDIR}/net/openldap -POSTFIX_CCARGS+= -DHAS_LDAP -I${PREFIX}/include -POSTFIX_AUXLIBS+= ${PREFIX}/lib/libldap.a ${PREFIX}/lib/liblber.a +BUILD_DEPENDS+= ${LOCALBASE}/lib/libldap.a:${PORTSDIR}/net/openldap +POSTFIX_CCARGS+= -DHAS_LDAP -I${LOCALBASE}/include +POSTFIX_AUXLIBS+= ${LOCALBASE}/lib/libldap.a ${PREFIX}/lib/liblber.a .endif ALL_TARGET= CCARGS="${POSTFIX_CCARGS}" AUXLIBS="${POSTFIX_AUXLIBS}" @@ -58,7 +58,6 @@ do-install: ${INSTALL} -C -o root -g wheel -m 0644 ${WRKSRC}/conf/$$f \ ${PREFIX}/etc/postfix/sample-$$f ; \ done - @exit @for f in sample-aliases.cf sample-canonical.cf sample-debug.cf \ sample-ldap.cf sample-local.cf sample-misc.cf sample-pcre.cf \ sample-rate.cf sample-relocated.cf sample-resource.cf \ @@ -75,12 +74,13 @@ do-install: ${INSTALL} -C -o root -g wheel -m 0755 -s \ ${WRKSRC}/libexec/$$f ${PREFIX}/libexec/postfix/$$f ;\ done - @for f in postalias postcat postconf postdrop postfix postkick \ - postlock postlog postmap postsuper sendmail smtp-sink \ - smtp-source ; do \ + @for f in postalias postcat postconf postfix postkick postlock postlog\ + postmap postsuper sendmail smtp-sink smtp-source ; do \ ${INSTALL} -C -o root -g wheel -m 0755 -s ${WRKSRC}/bin/$$f \ ${PREFIX}/sbin/$$f ;\ done + @${INSTALL} -C -o root -g maildrop -m 2755 -s ${WRKSRC}/bin/postdrop \ + ${PREFIX}/sbin/postdrop @for f in ${MAN1} ; do \ ${INSTALL} -C -o root -g wheel -m 0755 ${WRKSRC}/man/man1/$$f \ ${PREFIX}/man/man1/$$f ;\ @@ -94,21 +94,16 @@ do-install: ${PREFIX}/man/man8/$$f ;\ done @${MKDIR} -m 0755 /var/spool/postfix - @if [ ! -e ${PREFIX}/etc/postfix/main.cf ]; then \ - ${CP} -p ${PREFIX}/etc/postfix/sample-main.cf \ - ${PREFIX}/etc/postfix/main.cf; \ - fi - @if [ ! -e ${PREFIX}/etc/postfix/master.cf ]; then \ - ${CP} -p ${PREFIX}/etc/postfix/sample-master.cf \ - ${PREFIX}/etc/postfix/master.cf; \ - fi @${ECHO_MSG} "--------------------------------------------------" @${ECHO_MSG} "- To replace your existing sendmail with postfix -" @${ECHO_MSG} "- type \"make replace\" -" @${ECHO_MSG} "--------------------------------------------------" +pre-install: + @PKG_PREFIX=${PREFIX} ${SH} ${PKGDIR}/INSTALL ${PKGNAME} PRE-INSTALL + post-install: - @PREFIX=${PREFIX} ${SH} ${PKGDIR}/INSTALL ${PKGNAME} POST-INSTALL + @PKG_PREFIX=${PREFIX} ${SH} ${PKGDIR}/INSTALL ${PKGNAME} POST-INSTALL replace: @${ECHO_MSG} "===> Replacing sendmail" diff --git a/mail/postfix25/distinfo b/mail/postfix25/distinfo index 622c5106986c..b81e8ba3c9ee 100644 --- a/mail/postfix25/distinfo +++ b/mail/postfix25/distinfo @@ -1 +1 @@ -MD5 (postfix-19991231-pl03.tar.gz) = a68c8f2d4d077f455e3aa2e441852f88 +MD5 (postfix-19991231-pl04.tar.gz) = 4a57993049e0e1a092494272398a78e7 diff --git a/mail/postfix25/pkg-install b/mail/postfix25/pkg-install index 7b4849639b05..4ed960fb5bdc 100644 --- a/mail/postfix25/pkg-install +++ b/mail/postfix25/pkg-install @@ -33,45 +33,58 @@ yesno() { done } -if pw groupshow "${group}" 2>/dev/null; then - echo "You already have a group \"${group}\", so I will use it." -else - echo "You need a group \"${group}\"." - if yesno "Would you like me to create it" y; then - pw groupadd ${group} -h - || exit - echo "Done." +if [ x"$2" = xPRE-INSTALL ]; then + if pw groupshow "${group}" 2>/dev/null; then + echo "You already have a group \"${group}\", so I will use it." else - echo "Please create it, and try again." - exit 1 + echo "You need a group \"${group}\"." + if yesno "Would you like me to create it" y; then + pw groupadd ${group} -h - || exit + echo "Done." + else + echo "Please create it, and try again." + exit 1 + fi fi -fi -if pw groupshow "${group2}" 2>/dev/null; then - echo "You already have a group \"${group2}\", so I will use it." -else - echo "You need a group \"${group2}\"." - if yesno "Would you like me to create it" y; then - pw groupadd ${group2} -h - || exit - echo "Done." + if pw groupshow "${group2}" 2>/dev/null; then + echo "You already have a group \"${group2}\", so I will use it." else - echo "Please create it, and try again." - exit 1 + echo "You need a group \"${group2}\"." + if yesno "Would you like me to create it" y; then + pw groupadd ${group2} -h - || exit + echo "Done." + else + echo "Please create it, and try again." + exit 1 + fi fi -fi -if pw user show "${user}" 2>/dev/null; then - echo "You already have a user \"${user}\", so I will use it." -else - echo "You need a user \"${user}\"." - if yesno "Would you like me to create it" y; then - pw useradd ${user} -g ${group} -h - -d /nonexistent \ - -s /nonexistent -c "Postfix Mail System" || exit - echo "Done." + if pw user show "${user}" 2>/dev/null; then + echo "You already have a user \"${user}\", so I will use it." else - echo "Please create it, and try again." - exit 1 + echo "You need a user \"${user}\"." + if yesno "Would you like me to create it" y; then + pw useradd ${user} -g ${group} -h - -d /nonexistent \ + -s /nonexistent -c "Postfix Mail System" || exit + echo "Done." + else + echo "Please create it, and try again." + exit 1 + fi fi + fi -chown root:maildrop ${PREFIX}/sbin/postdrop -chmod 2755 ${PREFIX}/sbin/postdrop +if [ x"$2" = xPOST-INSTALL ]; then + if [ ! -e ${PKG_PREFIX}/etc/postfix/main.cf ]; then + cp -p ${PKG_PREFIX}/etc/postfix/sample-main.cf \ + ${PKG_PREFIX}/etc/postfix/main.cf + fi + if [ ! -e ${PKG_PREFIX}/etc/postfix/master.cf ]; then + cp -p ${PKG_PREFIX}/etc/postfix/sample-master.cf \ + ${PKG_PREFIX}/etc/postfix/master.cf + fi + chown root:maildrop ${PKG_PREFIX}/sbin/postdrop + chmod 2755 ${PKG_PREFIX}/sbin/postdrop +fi diff --git a/mail/postfix25/pkg-plist b/mail/postfix25/pkg-plist index 8fa639631947..af5f26a4396c 100644 --- a/mail/postfix25/pkg-plist +++ b/mail/postfix25/pkg-plist @@ -1,6 +1,4 @@ etc/postfix/LICENSE -etc/postfix/main.cf -etc/postfix/master.cf etc/postfix/postfix-script etc/postfix/sample-access etc/postfix/sample-aliases.cf @@ -47,3 +45,5 @@ sbin/smtp-sink sbin/smtp-source @exec mkdir -p -m 0755 /var/spool/postfix @exec chown root:wheel /var/spool/postfix +@dirrm libexec/postfix +@unexec rmdir %D/etc/postfix 2>/dev/null || true -- cgit