pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/mail/qmail-run qmail will not start (under qmail-run o...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/c2a898f0392e
branches:  trunk
changeset: 388371:c2a898f0392e
user:      schmonz <schmonz%pkgsrc.org@localhost>
date:      Tue Dec 04 17:00:59 2018 +0000

description:
qmail will not start (under qmail-run or otherwise) without a few basic
config files. Removing them on uninstall if they haven't been changed
is already mail/qmail's job; creating them on install was being done
here, and this combination was probably responsible for `pkgin
full-upgrade` removing some config files and qmail no longer running.
Thanks to Nathan Arthur for the bug report.

Instead of running config-fast-pkgsrc here, rely on mail/qmail to do it.
For similar reasons, also expect mail/qmail to handle the three basic
aliases (root, mailer-daemon, postmaster) and QUEUE_EXTRA.

While here, set QMAILREMOTE in qmailsend_postenv in preparation for a
future update.

Bump version.

diffstat:

 mail/qmail-run/INSTALL            |  28 ----------------------------
 mail/qmail-run/Makefile           |   9 ++++-----
 mail/qmail-run/files/qmailsend.sh |   6 +++---
 3 files changed, 7 insertions(+), 36 deletions(-)

diffs (106 lines):

diff -r 9fe6a8e63ac0 -r c2a898f0392e mail/qmail-run/INSTALL
--- a/mail/qmail-run/INSTALL    Tue Dec 04 13:29:32 2018 +0000
+++ b/mail/qmail-run/INSTALL    Tue Dec 04 17:00:59 2018 +0000
@@ -1,34 +1,6 @@
-QMAIL_QUEUE_EXTRA=@QMAIL_QUEUE_EXTRA@
-
-psmsg='#
-# This file was auto-generated by pkgsrc.'
-
 case ${STAGE} in
 
 POST-INSTALL)
-       cd ${PREFIX}/share/qmail/setup && ./config-fast-pkgsrc `./hostname`
-
-       cd ${PKG_SYSCONFDIR}/.pkgsrc-defaults-do-not-edit
-       for i in locals rcpthosts; do
-               ${SORT} -u ${i} > ${i}.tmp && ${MV} ${i}.tmp ${i}
-       done
-
-       cd ${PKG_SYSCONFDIR}
-       for i in defaultdomain locals me plusdomain rcpthosts; do
-               [ -f control/${i} ] \
-                       || ${CP} .pkgsrc-defaults-do-not-edit/${i} control
-       done
-
-       cd ${PKG_SYSCONFDIR}/alias
-       for i in postmaster mailer-daemon root; do
-               ${TOUCH} .qmail-${i}
-               ${CHMOD} 644 .qmail-${i}
-       done
-       if ! [ -z ${QMAIL_QUEUE_EXTRA} ]; then
-               ${ECHO} "$psmsg" >> .qmail-${QMAIL_QUEUE_EXTRA}
-               ${CHMOD} 644 .qmail-${QMAIL_QUEUE_EXTRA}
-       fi
-
        cd ${PKG_SYSCONFDIR}
        for i in ofmip pop3 smtp; do
                ${CHMOD} 644 tcp.${i}
diff -r 9fe6a8e63ac0 -r c2a898f0392e mail/qmail-run/Makefile
--- a/mail/qmail-run/Makefile   Tue Dec 04 13:29:32 2018 +0000
+++ b/mail/qmail-run/Makefile   Tue Dec 04 17:00:59 2018 +0000
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.61 2018/11/28 16:22:41 schmonz Exp $
+# $NetBSD: Makefile,v 1.62 2018/12/04 17:00:59 schmonz Exp $
 #
 
-DISTNAME=              qmail-run-20181128
+DISTNAME=              qmail-run-20181204
 CATEGORIES=            mail
 MASTER_SITES=          # empty
 DISTFILES=             # empty
@@ -13,7 +13,7 @@
 DEPENDS+=              greetdelay-[0-9]*:../../mail/greetdelay
 DEPENDS+=              greylisting-spp-[0-9]*:../../mail/greylisting-spp
 DEPENDS+=              pkg_alternatives-[0-9]*:../../pkgtools/pkg_alternatives
-DEPENDS_QMAIL=         qmail>=1.03nb41:../../mail/qmail
+DEPENDS_QMAIL=         qmail>=1.03nb42:../../mail/qmail
 DEPENDS+=              ${DEPENDS_QMAIL}
 DEPENDS+=              qmail-acceptutils>=20181128:../../mail/qmail-acceptutils
 DEPENDS+=              qmail-qfilter>1.5nb1:../../mail/qmail-qfilter
@@ -26,7 +26,6 @@
 FILES_SUBST+=          QMAIL_DAEMON_USER=${QMAIL_DAEMON_USER:Q}
 FILES_SUBST+=          QMAIL_LOG_USER=${QMAIL_LOG_USER:Q}
 FILES_SUBST+=          QMAIL_SEND_USER=${QMAIL_SEND_USER:Q}
-FILES_SUBST+=          QMAIL_QUEUE_EXTRA=${QMAIL_QUEUE_EXTRA:Q}
 FILES_SUBST+=          PKGNAME=${PKGNAME:Q}
 FILES_SUBST+=          UCSPI_SSL_USER=${UCSPI_SSL_USER:Q}
 FILES_SUBST+=          UCSPI_SSL_GROUP=${UCSPI_SSL_GROUP:Q}
@@ -55,7 +54,7 @@
 
 INSTALLATION_DIRS=     bin share/doc/qmail-run ${EGDIR}
 BUILD_DEFS+=           QMAIL_DAEMON_USER QMAIL_LOG_USER QMAIL_SEND_USER
-BUILD_DEFS+=           QMAIL_QMAIL_GROUP QMAIL_QUEUE_EXTRA PKG_SYSCONFBASE
+BUILD_DEFS+=           QMAIL_QMAIL_GROUP PKG_SYSCONFBASE
 BUILD_DEFS+=           UCSPI_SSL_USER UCSPI_SSL_GROUP
 
 .include "../../mk/bsd.prefs.mk"
diff -r 9fe6a8e63ac0 -r c2a898f0392e mail/qmail-run/files/qmailsend.sh
--- a/mail/qmail-run/files/qmailsend.sh Tue Dec 04 13:29:32 2018 +0000
+++ b/mail/qmail-run/files/qmailsend.sh Tue Dec 04 17:00:59 2018 +0000
@@ -1,6 +1,6 @@
 #!@RCD_SCRIPTS_SHELL@
 #
-# $NetBSD: qmailsend.sh,v 1.13 2018/11/03 17:08:26 schmonz Exp $
+# $NetBSD: qmailsend.sh,v 1.14 2018/12/04 17:00:59 schmonz Exp $
 #
 # @PKGNAME@ script to control qmail-send (local and outgoing mail).
 #
@@ -12,7 +12,7 @@
 name="qmailsend"
 
 # User-settable rc.conf variables and their default values:
-: ${qmailsend_postenv:="PATH=@PREFIX@/bin:$PATH"}
+: ${qmailsend_postenv:="QMAILREMOTE=@PREFIX@/bin/qmail-remote"}
 : ${qmailsend_defaultdelivery:="`@HEAD@ -1 @PKG_SYSCONFDIR@/control/defaultdelivery`"}
 : ${qmailsend_log:="YES"}
 : ${qmailsend_logcmd:="logger -t nbqmail/send -p mail.info"}
@@ -47,7 +47,7 @@
        fi
        # qmail-start(8) starts the various qmail processes, then execs
        # qmail-send(8). That's the process we want to signal later.
-       command="@PREFIX@/bin/pgrphack @SETENV@ - ${qmailsend_postenv}
+       command="@PREFIX@/bin/pgrphack @SETENV@ - PATH=@PREFIX@/bin:$PATH ${qmailsend_postenv}
 qmail-start '$qmailsend_defaultdelivery'
 ${qmailsend_logcmd}"
        command_args="&"



Home | Main Index | Thread Index | Old Index