Skip to content
Permalink
Browse files

Add rc.d script to control qmail, provided by Lubomir Sedlacik

<salo@Xtrmntr.org> in pkg/15326.

Add example mailer.conf.

Bump PKGREVISION.

Clarify binary package situation: We don't allow binary packages
to be created because they don't currently work. Additionally, if
someone were to make them work, we'd be unable to distribute them
because we apply a few patches to the qmail source.

Thanks to zuntum and jlam for discussion and assistance.
  • Loading branch information
schmonz
schmonz committed Jul 28, 2002
1 parent 2e5aa97 commit e0d07f05de92a892ef30eb4d3d27683ad2a7a6fb
Showing with 66 additions and 9 deletions.
  1. +3 −1 mail/qmail/MESSAGE
  2. +27 −7 mail/qmail/Makefile
  3. +5 −1 mail/qmail/PLIST
  4. +6 −0 mail/qmail/files/mailer.conf
  5. +25 −0 mail/qmail/files/qmail.sh
@@ -1,8 +1,10 @@
======================================================================
$NetBSD: MESSAGE,v 1.3 2002/01/21 16:00:51 zuntum Exp $
$NetBSD: MESSAGE,v 1.4 2002/07/28 01:54:37 schmonz Exp $

To be able to view manpages either add "${QMAILDIR}/man/" to the
_default line in /etc/man.conf or specify this directory in
MANPATH variable in your environment.

To start qmail at startup set qmail=YES in /etc/rc.conf.

======================================================================
@@ -1,10 +1,10 @@
# $NetBSD: Makefile,v 1.13 2002/07/22 23:30:29 wiz Exp $
# $NetBSD: Makefile,v 1.14 2002/07/28 01:54:37 schmonz Exp $
#

DISTNAME= qmail-1.03
PKGREVISION= 2
PKGREVISION= 3
CATEGORIES= mail
MASTER_SITES= http://cr.yp.to/software/ \
MASTER_SITES= http://cr.yp.to/software/ \
ftp://ftp.ntnu.no/pub/unix/mail/qmail/ \
ftp://ftp.jp.qmail.org/qmail/ \
ftp://ftp.rifkin.technion.ac.il/pub/qmail/ \
@@ -20,9 +20,17 @@ DEPENDS+= qmail-users>=1.0:../../mail/qmail-users
ALL_TARGET= it man
INSTALL_TARGET= setup check

NO_PACKAGE= YES
RESTRICTED= "djb does not permit modified binary packages"
NO_BIN_ON_CDROM= ${RESTRICTED}
NO_BIN_ON_FTP= ${RESTRICTED}

OWN_DIRS+= ${QMAILDIR}
NO_PACKAGE= "needs work to function properly as a binary package"

OWN_DIRS+= ${QMAILDIR}

FILES_SUBST+= QMAILDIR=${QMAILDIR}
RCD_SCRIPTS= qmail
RCD_SCRIPTS_EXAMPLEDIR= ${QMAILDIR}/etc/rc.d

.include "../../mk/bsd.prefs.mk"

@@ -31,14 +39,26 @@ LOCALBASE= /

DEINSTALL_EXTRA_TMPL= ${PKGDIR}/DEINSTALL

pre-build:
do-configure:
${ECHO} ${CC} ${CFLAGS} > ${WRKSRC}/conf-cc
${ECHO} ${CC} ${_STRIPFLAG_CC} > ${WRKSRC}/conf-ld
${ECHO} ${QMAILDIR} > ${WRKSRC}/conf-qmail

pre-install:
@${SED} ${FILES_SUBST_SED} ${FILESDIR}/qmail.sh \
> ${WRKDIR}/qmail
@${SED} ${FILES_SUBST_SED} ${FILESDIR}/mailer.conf \
> ${WRKDIR}/mailer.conf.qmail

post-install:
${INSTALL_DATA_DIR} ${QMAILDIR}/etc
${INSTALL_DATA} ${WRKDIR}/mailer.conf.qmail ${QMAILDIR}/etc

${INSTALL_SCRIPT_DIR} ${RCD_SCRIPTS_EXAMPLEDIR}
${INSTALL_SCRIPT} ${WRKDIR}/qmail ${RCD_SCRIPTS_EXAMPLEDIR}

${INSTALL_DATA_DIR} ${QMAILDIR}/alias
cd ${QMAILDIR}/alias && \
cd ${QMAILDIR}/alias && \
${TOUCH} .qmail-postmaster .qmail-mailer-daemon .qmail-root

.include "../../mk/bsd.pkg.install.mk"
@@ -1,4 +1,6 @@
@comment $NetBSD: PLIST,v 1.2 2002/01/21 18:45:04 zuntum Exp $
@comment $NetBSD: PLIST,v 1.3 2002/07/28 01:54:37 schmonz Exp $
${QMAILDIR}/etc/mailer.conf.qmail
${QMAILDIR}/etc/rc.d/qmail
${QMAILDIR}/doc/FAQ
${QMAILDIR}/doc/UPGRADE
${QMAILDIR}/doc/SENDMAIL
@@ -187,6 +189,8 @@ ${QMAILDIR}/man/man8/qmail-command.8
@dirrm ${QMAILDIR}/man/man7
@dirrm ${QMAILDIR}/man/man8
@dirrm ${QMAILDIR}/man
@dirrm ${QMAILDIR}/etc/rc.d
@dirrm ${QMAILDIR}/etc
@dirrm ${QMAILDIR}/doc
@dirrm ${QMAILDIR}/boot
@dirrm ${QMAILDIR}/bin
@@ -0,0 +1,6 @@
# $NetBSD: mailer.conf,v 1.1 2002/07/28 01:54:37 schmonz Exp $
#
# Use "qmail" as replacement for "sendmail".
#
sendmail @QMAILDIR@/bin/sendmail
send-mail @QMAILDIR@/bin/sendmail
@@ -0,0 +1,25 @@
#!/bin/sh
#
# $NetBSD: qmail.sh,v 1.1 2002/07/28 01:54:37 schmonz Exp $
#

# PROVIDE: mail
# REQUIRE: LOGIN

. /etc/rc.subr

name="qmail"
rcvar=${name}
required_files="@QMAILDIR@/rc @QMAILDIR@/control/me"
command="@QMAILDIR@/bin/qmail-send"
start_precmd="qmail_precmd"
extra_commands="reload"

qmail_precmd()
{
command="@QMAILDIR@/rc"
command_args="&"
}

load_rc_config $name
run_rc_command "$1"

0 comments on commit e0d07f0

Please sign in to comment.
You can’t perform that action at this time.