summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGrant Goodyear <g2boojum@gentoo.org>2002-06-10 20:14:43 +0000
committerGrant Goodyear <g2boojum@gentoo.org>2002-06-10 20:14:43 +0000
commitcad10b1d2e1caf9ec1aa4d885705628c84c97139 (patch)
tree4fa33529789d9c3fc15fede9478f64f506861ab0 /net-mail
parentupdated gentoo mirror URI (diff)
downloadgentoo-2-cad10b1d2e1caf9ec1aa4d885705628c84c97139.tar.gz
gentoo-2-cad10b1d2e1caf9ec1aa4d885705628c84c97139.tar.bz2
gentoo-2-cad10b1d2e1caf9ec1aa4d885705628c84c97139.zip
Closing bug #3416.
Diffstat (limited to 'net-mail')
-rw-r--r--net-mail/qmail/ChangeLog6
-rw-r--r--net-mail/qmail/files/1.03-r8/defaultdelivery2
-rw-r--r--net-mail/qmail/files/1.03-r8/dot_qmail1
-rw-r--r--net-mail/qmail/files/1.03-r8/qmail-control30
-rw-r--r--net-mail/qmail/files/1.03-r8/qmail-linksync.patch54
-rw-r--r--net-mail/qmail/files/1.03-r8/qmail-queue.patch49
-rw-r--r--net-mail/qmail/files/1.03-r8/rc4
-rw-r--r--net-mail/qmail/files/1.03-r8/run-qmailsend2
-rw-r--r--net-mail/qmail/files/1.03-r8/run-qmailsendlog2
-rw-r--r--net-mail/qmail/files/1.03-r8/run-qmailsmtpd6
-rw-r--r--net-mail/qmail/files/1.03-r8/run-qmailsmtpdlog2
-rw-r--r--net-mail/qmail/files/digest-qmail-1.03-r84
-rw-r--r--net-mail/qmail/qmail-1.03-r8.ebuild272
13 files changed, 433 insertions, 1 deletions
diff --git a/net-mail/qmail/ChangeLog b/net-mail/qmail/ChangeLog
index 7ee11fc79bdf..c5348b73567e 100644
--- a/net-mail/qmail/ChangeLog
+++ b/net-mail/qmail/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for net-mail/qmail
# Copyright 2002 Gentoo Technologies, Inc.; Distributed under the GPL
-# $Header: /var/cvsroot/gentoo-x86/net-mail/qmail/ChangeLog,v 1.4 2002/05/12 00:07:33 bangert Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-mail/qmail/ChangeLog,v 1.5 2002/06/10 20:14:43 g2boojum Exp $
+
+ 10 June 2002; Grant Goodyear <bangert@gentoo.org> qmail-1.03-r8.ebuild :
+
+ Added qmail-queue patch for qmail-scanner, closing bug #3416.
12 May 2002; Thilo Bangert <bangert@gentoo.org> qmail-1.03-r7.ebuild :
fixed location for dns patch. added new digest to reflect the change
diff --git a/net-mail/qmail/files/1.03-r8/defaultdelivery b/net-mail/qmail/files/1.03-r8/defaultdelivery
new file mode 100644
index 000000000000..d0ef7de8b590
--- /dev/null
+++ b/net-mail/qmail/files/1.03-r8/defaultdelivery
@@ -0,0 +1,2 @@
+|dot-forward .forward
+./.maildir/
diff --git a/net-mail/qmail/files/1.03-r8/dot_qmail b/net-mail/qmail/files/1.03-r8/dot_qmail
new file mode 100644
index 000000000000..7c9e5d08f067
--- /dev/null
+++ b/net-mail/qmail/files/1.03-r8/dot_qmail
@@ -0,0 +1 @@
+./.maildir/
diff --git a/net-mail/qmail/files/1.03-r8/qmail-control b/net-mail/qmail/files/1.03-r8/qmail-control
new file mode 100644
index 000000000000..35a2c785d622
--- /dev/null
+++ b/net-mail/qmail/files/1.03-r8/qmail-control
@@ -0,0 +1,30 @@
+#!/sbin/runscript
+# Copyright 1999-2002 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License, v2 or later
+# $Header: /var/cvsroot/gentoo-x86/net-mail/qmail/files/1.03-r8/qmail-control,v 1.1 2002/06/10 20:14:43 g2boojum Exp $
+
+opts="start stop restart reload"
+
+start() {
+ ebegin "Starting qmail mta ..."
+ svc -u /var/qmail/supervise/*
+ eend $?
+ ebegin "Starting qmail mta logging ..."
+ svc -u /var/qmail/supervise/*/log
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping qmail mta ..."
+ svc -d /var/qmail/supervise/*
+ eend $?
+ ebegin "Stopping qmail mta logging ..."
+ svc -d /var/qmail/supervise/*/log
+ eend $?
+}
+
+reload() {
+ ebegin "Reloading 'locals' and 'virtualdomains' control files."
+ svc -h /var/qmail/supervise/qmail-send
+ eend $?
+}
diff --git a/net-mail/qmail/files/1.03-r8/qmail-linksync.patch b/net-mail/qmail/files/1.03-r8/qmail-linksync.patch
new file mode 100644
index 000000000000..1b35f12aaa1f
--- /dev/null
+++ b/net-mail/qmail/files/1.03-r8/qmail-linksync.patch
@@ -0,0 +1,54 @@
+--- ../qmail-1.03.orig/qmail-local.c Mon Jun 15 12:53:16 1998
++++ qmail-local.c Sun Jul 16 16:19:04 2000
+@@ -1,5 +1,6 @@
+ #include <sys/types.h>
+ #include <sys/stat.h>
++#include <fcntl.h>
+ #include "readwrite.h"
+ #include "sig.h"
+ #include "env.h"
+@@ -128,6 +129,9 @@
+ if (close(fd) == -1) goto fail; /* NFS dorks */
+
+ if (link(fntmptph,fnnewtph) == -1) goto fail;
++ if ((fd = open(fnnewtph, O_RDONLY)) < 0 ||
++ fsync(fd) < 0 || close(fd) < 0) goto fail;
++
+ /* if it was error_exist, almost certainly successful; i hate NFS */
+ tryunlinktmp(); _exit(0);
+
+--- ../qmail-1.03.orig/qmail-queue.c Mon Jun 15 12:53:16 1998
++++ qmail-queue.c Sun Jul 16 16:19:33 2000
+@@ -1,5 +1,6 @@
+ #include <sys/types.h>
+ #include <sys/stat.h>
++#include <fcntl.h>
+ #include "readwrite.h"
+ #include "sig.h"
+ #include "exit.h"
+@@ -155,6 +156,7 @@
+ {
+ unsigned int len;
+ char ch;
++ int fd;
+
+ sig_blocknone();
+ umask(033);
+@@ -183,7 +185,7 @@
+ todofn = fnnum("todo/",0);
+ intdfn = fnnum("intd/",0);
+
+- if (link(pidfn,messfn) == -1) die(64);
++ if (link(pidfn,messfn) == -1) die(64);
+ if (unlink(pidfn) == -1) die(63);
+ flagmademess = 1;
+
+@@ -248,6 +250,8 @@
+ if (fsync(intdfd) == -1) die_write();
+
+ if (link(intdfn,todofn) == -1) die(66);
++ if ((fd = open(todofn, O_RDONLY)) < 0 ||
++ fsync(fd) < 0 || close(fd) < 0) die(66);
+
+ triggerpull();
+ die(0);
diff --git a/net-mail/qmail/files/1.03-r8/qmail-queue.patch b/net-mail/qmail/files/1.03-r8/qmail-queue.patch
new file mode 100644
index 000000000000..4edd5fad86e5
--- /dev/null
+++ b/net-mail/qmail/files/1.03-r8/qmail-queue.patch
@@ -0,0 +1,49 @@
+diff -u qmail-1.03-orig/Makefile qmail-1.03/Makefile
+--- qmail-1.03-orig/Makefile Mon Jun 15 04:53:16 1998
++++ Makefile Tue Jan 19 10:52:24 1999
+@@ -1483,12 +1483,12 @@
+ trigger.o fmtqfn.o quote.o now.o readsubdir.o qmail.o date822fmt.o \
+ datetime.a case.a ndelay.a getln.a wait.a seek.a fd.a sig.a open.a \
+ lock.a stralloc.a alloc.a substdio.a error.a str.a fs.a auto_qmail.o \
+-auto_split.o
++auto_split.o env.a
+ ./load qmail-send qsutil.o control.o constmap.o newfield.o \
+ prioq.o trigger.o fmtqfn.o quote.o now.o readsubdir.o \
+ qmail.o date822fmt.o datetime.a case.a ndelay.a getln.a \
+ wait.a seek.a fd.a sig.a open.a lock.a stralloc.a alloc.a \
+- substdio.a error.a str.a fs.a auto_qmail.o auto_split.o
++ substdio.a error.a str.a fs.a auto_qmail.o auto_split.o env.a
+
+ qmail-send.0: \
+ qmail-send.8
+diff -u qmail-1.03-orig/qmail.c qmail-1.03/qmail.c
+--- qmail-1.03-orig/qmail.c Mon Jun 15 04:53:16 1998
++++ qmail.c Tue Jan 19 09:57:36 1999
+@@ -6,14 +6,25 @@
+ #include "fd.h"
+ #include "qmail.h"
+ #include "auto_qmail.h"
++#include "env.h"
+
+-static char *binqqargs[2] = { "bin/qmail-queue", 0 } ;
++static char *binqqargs[2] = { 0, 0 } ;
++
++static void setup_qqargs()
++{
++ if(!binqqargs[0])
++ binqqargs[0] = env_get("QMAILQUEUE");
++ if(!binqqargs[0])
++ binqqargs[0] = "bin/qmail-queue";
++}
+
+ int qmail_open(qq)
+ struct qmail *qq;
+ {
+ int pim[2];
+ int pie[2];
++
++ setup_qqargs();
+
+ if (pipe(pim) == -1) return -1;
+ if (pipe(pie) == -1) { close(pim[0]); close(pim[1]); return -1; }
+
diff --git a/net-mail/qmail/files/1.03-r8/rc b/net-mail/qmail/files/1.03-r8/rc
new file mode 100644
index 000000000000..a7bbdc986766
--- /dev/null
+++ b/net-mail/qmail/files/1.03-r8/rc
@@ -0,0 +1,4 @@
+#!/bin/sh
+
+exec env - PATH="/var/qmail/bin:$PATH" \
+ qmail-start "`cat /var/qmail/control/defaultdelivery`"
diff --git a/net-mail/qmail/files/1.03-r8/run-qmailsend b/net-mail/qmail/files/1.03-r8/run-qmailsend
new file mode 100644
index 000000000000..8dbd3adf524f
--- /dev/null
+++ b/net-mail/qmail/files/1.03-r8/run-qmailsend
@@ -0,0 +1,2 @@
+#!/bin/sh
+exec /var/qmail/rc
diff --git a/net-mail/qmail/files/1.03-r8/run-qmailsendlog b/net-mail/qmail/files/1.03-r8/run-qmailsendlog
new file mode 100644
index 000000000000..5ff50d1e7711
--- /dev/null
+++ b/net-mail/qmail/files/1.03-r8/run-qmailsendlog
@@ -0,0 +1,2 @@
+#!/bin/sh
+exec /usr/bin/setuidgid qmaill /usr/bin/multilog t s2500000 /var/log/qmail/qmail-send
diff --git a/net-mail/qmail/files/1.03-r8/run-qmailsmtpd b/net-mail/qmail/files/1.03-r8/run-qmailsmtpd
new file mode 100644
index 000000000000..0d61202a7cf3
--- /dev/null
+++ b/net-mail/qmail/files/1.03-r8/run-qmailsmtpd
@@ -0,0 +1,6 @@
+#!/bin/sh
+QMAILDUID=`id -u qmaild`
+NOFILESGID=`id -g qmaild`
+exec /usr/bin/softlimit -m 2000000 \
+ /usr/bin/tcpserver -H -R -v -p -x /etc/tcp.smtp.cdb \
+ -u $QMAILDUID -g $NOFILESGID 0 smtp rblsmtpd /var/qmail/bin/qmail-smtpd 2>&1
diff --git a/net-mail/qmail/files/1.03-r8/run-qmailsmtpdlog b/net-mail/qmail/files/1.03-r8/run-qmailsmtpdlog
new file mode 100644
index 000000000000..2d9546146583
--- /dev/null
+++ b/net-mail/qmail/files/1.03-r8/run-qmailsmtpdlog
@@ -0,0 +1,2 @@
+#!/bin/sh
+exec /usr/bin/setuidgid qmaill /usr/bin/multilog t s2500000 /var/log/qmail/qmail-smtpd
diff --git a/net-mail/qmail/files/digest-qmail-1.03-r8 b/net-mail/qmail/files/digest-qmail-1.03-r8
new file mode 100644
index 000000000000..9ade032bccfa
--- /dev/null
+++ b/net-mail/qmail/files/digest-qmail-1.03-r8
@@ -0,0 +1,4 @@
+MD5 622f65f982e380dbe86e6574f3abcb7c qmail-1.03.tar.gz 220668
+MD5 39b6f70f65056472ff97ab40c1dba7b4 big-todo.103.patch 5546
+MD5 2ff58c3570870a8ff9a1d9eb9aec05a6 big-concurrency.patch 9331
+MD5 9140ad2b03017145cd7963c84bb24f16 qmail-103.patch 2104
diff --git a/net-mail/qmail/qmail-1.03-r8.ebuild b/net-mail/qmail/qmail-1.03-r8.ebuild
new file mode 100644
index 000000000000..fd01f87c5266
--- /dev/null
+++ b/net-mail/qmail/qmail-1.03-r8.ebuild
@@ -0,0 +1,272 @@
+# Copyright 1999-2001 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License, v2 or later
+# Maintainer: Thilo Bangert <bangert@gentoo.org>
+# /space/gentoo/cvsroot/gentoo-x86/net-mail/qmail/qmail-1.03-r7.ebuild,v 1.5 2002/05/17 09:33:43 bangert Exp
+
+S=${WORKDIR}/${P}
+DESCRIPTION="A modern replacement for sendmail which uses maildirs"
+HOMEPAGE="http://www.qmail.org/
+ http://www.jedi.claranet.fr/qmail-tuning.html
+ http://iain.cx/unix/qmail/mysql.php
+ http://www.nrg4u.com/"
+
+SRC_URI="http://cr.yp.to/software/qmail-1.03.tar.gz
+ http://www.qmail.org/big-todo.103.patch
+ http://www.qmail.org/big-concurrency.patch
+ http://www.ckdhr.com/ckd/qmail-103.patch"
+
+DEPEND="virtual/glibc
+ sys-apps/groff
+ >=sys-apps/ucspi-tcp-0.88
+ >=net-mail/checkpassword-0.90"
+
+RDEPEND="!virtual/mta
+ virtual/glibc
+ sys-apps/groff
+ >=sys-apps/ucspi-tcp-0.88
+ >=sys-apps/daemontools-0.76-r1
+ >=net-mail/checkpassword-0.90
+ >=net-mail/dot-forward-0.71"
+
+PROVIDE="virtual/mta"
+
+src_unpack() {
+
+ cd ${WORKDIR}
+ unpack qmail-1.03.tar.gz
+
+ cd ${S}
+
+ echo "Applying dns patch..."
+ patch < ${DISTDIR}/qmail-103.patch
+
+ echo "Applying big-todo patch..."
+ patch < ${DISTDIR}/big-todo.103.patch
+
+ echo "Applying big-concurrency patch..."
+ patch < ${DISTDIR}/big-concurrency.patch
+
+ echo "Applying Ext2FS/ReiserFS patch..."
+ patch < ${FILESDIR}/${PV}-${PR}/qmail-linksync.patch
+
+ echo "Applying QMAILQUEUE patch..."
+ patch < ${FILESDIR}/${PV}-${PR}/qmail-queue.patch
+
+ echo "gcc ${CFLAGS}" > conf-cc
+ echo "gcc" > conf-ld
+ echo "500" > conf-spawn
+
+}
+
+src_compile() {
+
+ cd ${S}
+
+ emake it man || die
+}
+
+
+
+src_install() {
+
+ cd ${S}
+
+ einfo "Setting up directory hierarchy ..."
+
+ diropts -m 755 -o root -g qmail
+ dodir /var/qmail
+
+ for i in bin boot control
+ do
+ dodir /var/qmail/${i}
+ done
+
+ dodir /var/qmail/users
+ touch ${D}/var/qmail/users/.keep
+
+ diropts -m 755 -o alias -g qmail
+ dodir /var/qmail/alias
+
+ einfo "Installing the qmail software ..."
+
+ insopts -o root -g qmail -m 755
+ insinto /var/qmail/boot
+ doins home home+df proc proc+df binm1 binm1+df binm2 binm2+df binm3 binm3+df
+
+ into /usr
+ dodoc FAQ UPGRADE SENDMAIL INSTALL* TEST* REMOVE* PIC* SECURITY
+ dodoc SYSDEPS TARGETS THANKS THOUGHTS TODO VERSION
+
+ insopts -o qmailq -g qmail -m 4711
+ insinto /var/qmail/bin
+ doins qmail-queue qmail-queue
+
+ insopts -o root -g qmail -m 700
+ insinto /var/qmail/bin
+ doins qmail-lspawn qmail-start qmail-newu qmail-newmrh
+
+ insopts -o root -g qmail -m 711
+ insinto /var/qmail/bin
+ doins qmail-getpw qmail-local qmail-remote qmail-rspawn \
+ qmail-clean qmail-send splogger qmail-pw2u
+
+ insopts -o root -g qmail -m 755
+ insinto /var/qmail/bin
+ doins qmail-inject predate datemail mailsubj qmail-showctl \
+ qmail-qread qmail-qstat qmail-tcpto qmail-tcpok qmail-pop3d \
+ qmail-popup qmail-qmqpc qmail-qmqpd qmail-qmtpd qmail-smtpd \
+ sendmail tcp-env qreceipt qsmhook qbiff forward preline \
+ condredirect bouncesaying except maildirmake maildir2mbox \
+ maildirwatch qail elq pinq config-fast
+
+ into /usr
+ for i in *.1 *.5 *.8
+ do
+ doman $i
+ done
+
+ einfo "Creating sendmail replacement ..."
+ diropts -m 755
+ dodir /usr/sbin /usr/lib
+ dosym /var/qmail/bin/sendmail /usr/sbin/sendmail
+ dosym /var/qmail/bin/sendmail /usr/lib/sendmail
+
+ einfo "Setting up the default aliases ..."
+ diropts -m 700 -o alias -g qmail
+ if [ ! -d ${ROOT}/var/qmail/alias/.maildir ] ; then
+ dodir /var/qmail/alias/.maildir
+ for i in cur new tmp
+ do
+ dodir /var/qmail/alias/.maildir/$i
+ done
+ fi
+
+ for i in mailer-daemon postmaster root
+ do
+ touch ${D}/var/qmail/alias/.qmail-${i}
+ fowners alias.qmail /var/qmail/alias/.qmail-${i}
+ done
+
+ einfo "Setting up maildirs by default in the account skeleton ..."
+ diropts -m 755 -o root -g root
+ insinto /etc/skel
+ ${D}/var/qmail/bin/maildirmake ${D}/etc/skel/.maildir
+ newins ${FILESDIR}/${PV}-${PR}/dot_qmail .qmail
+ fperms 644 /etc/skel/.qmail
+ insinto /root
+ ${D}/var/qmail/bin/maildirmake ${D}/root/.maildir
+ newins ${FILESDIR}/${PV}-${PR}/dot_qmail .qmail
+ fperms 644 /root/.qmail
+
+ einfo "Setting up daemontools ..."
+ insopts -o root -g root -m 755
+ diropts -m 755 -o root -g root
+ dodir /var/qmail/supervise
+ dodir /var/qmail/supervise/qmail-send
+ dodir /var/qmail/supervise/qmail-send/log
+ dodir /var/qmail/supervise/qmail-smtpd
+ dodir /var/qmail/supervise/qmail-smtpd/log
+ chmod +t ${D}/var/qmail/supervise/qmail-send
+ chmod +t ${D}/var/qmail/supervise/qmail-smtpd
+ diropts -m 755 -o qmaill
+ dodir /var/log/qmail
+ touch ${D}/var/log/qmail/.keep
+ dodir /var/log/qmail/qmail-send
+ touch ${D}/var/log/qmail/qmail-send/.keep
+ dodir /var/log/qmail/qmail-smtpd
+ touch ${D}/var/log/qmail/qmail-smtpd/.keep
+
+ insinto /var/qmail/supervise/qmail-send
+ newins ${FILESDIR}/${PV}-${PR}/run-qmailsend run
+ insinto /var/qmail/supervise/qmail-send/log
+ newins ${FILESDIR}/${PV}-${PR}/run-qmailsendlog run
+ insinto /var/qmail/supervise/qmail-smtpd
+ newins ${FILESDIR}/${PV}-${PR}/run-qmailsmtpd run
+ insinto /var/qmail/supervise/qmail-smtpd/log
+ newins ${FILESDIR}/${PV}-${PR}/run-qmailsmtpdlog run
+
+ einfo "Installing the qmail control file ..."
+ exeinto /var/qmail/bin
+ doexe ${FILESDIR}/${PV}-${PR}/qmail-control
+
+ einfo "Installing the qmail startup file ..."
+ insinto /var/qmail
+ doins ${FILESDIR}/${PV}-${PR}/rc
+ insinto /var/qmail/control
+ doins ${FILESDIR}/${PV}-${PR}/defaultdelivery
+
+}
+
+pkg_postinst() {
+
+ einfo "Setting up the message queue hierarchy ..."
+
+ install -d -m 750 -o qmailq -g qmail ${ROOT}/var/qmail/queue
+ install -d -m 750 -o qmailq -g qmail ${ROOT}/var/qmail/queue/todo
+ install -d -m 700 -o qmailq -g qmail ${ROOT}/var/qmail/queue/pid
+ install -d -m 700 -o qmails -g qmail ${ROOT}/var/qmail/queue/bounce
+ install -d -m 750 -o qmailq -g qmail ${ROOT}/var/qmail/queue/mess
+
+ for i in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
+ do
+ install -d -m 750 -o qmailq -g qmail ${ROOT}/var/qmail/queue/mess/${i}
+ install -d -m 750 -o qmailq -g qmail ${ROOT}/var/qmail/queue/todo/${i}
+ install -d -m 750 -o qmailq -g qmail ${ROOT}/var/qmail/queue/intd/${i}
+ done
+
+ for i in info local remote
+ do
+ install -d -m 700 -o qmails -g qmail ${ROOT}/var/qmail/queue/${i}
+ done
+
+ for i in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
+ do
+ install -d -m 700 -o qmails -g qmail ${ROOT}/var/qmail/queue/info/${i}
+ install -d -m 700 -o qmails -g qmail ${ROOT}/var/qmail/queue/local/${i}
+ install -d -m 700 -o qmails -g qmail ${ROOT}/var/qmail/queue/remote/${i}
+ done
+
+ install -d -m 750 -o qmailq -g qmail ${ROOT}/var/qmail/queue/lock
+
+ dd if=/dev/zero of=${ROOT}/var/qmail/queue/lock/tcpto bs=1024 count=1
+ chmod 644 ${ROOT}/var/qmail/queue/lock/tcpto
+ chown qmailr.qmail ${ROOT}/var/qmail/queue/lock/tcpto
+
+ touch ${ROOT}/var/qmail/queue/lock/sendmutex
+ chmod 600 ${ROOT}/var/qmail/queue/lock/sendmutex
+ chown qmails.qmail ${ROOT}/var/qmail/queue/lock/sendmutex
+
+ mkfifo ${ROOT}/var/qmail/queue/lock/trigger
+ chmod 622 ${ROOT}/var/qmail/queue/lock/trigger
+ chown qmails.qmail ${ROOT}/var/qmail/queue/lock/trigger
+
+ echo -e "\e[32;01m Please do not forget to run, the following syntax :\033[0m"
+ echo -e "\e[32;01m ebuild /var/db/pkg/${CATEGORY}/${PN}-${PV}-${PR}/${PN}-${PV}-${PR}.ebuild config \033[0m"
+ echo -e "\e[32;01m This will setup qmail to run out-of-the-box on your system. \033[0m"
+ echo -e ""
+ echo -e "\e[32;01m To start qmail at boot you have to enable the /etc/init.d/svscan rc file \033[0m"
+ echo -e "\e[32;01m and create the following links : \033[0m"
+ echo -e "\e[32;01m ln -s /var/qmail/supervise/qmail-send /service/qmail-send \033[0m"
+ echo -e "\e[32;01m ln -s /var/qmail/supervise/qmail-smtpd /service/qmail-smtpd \033[0m"
+
+}
+
+pkg_config() {
+
+ export qhost=`hostname`
+ if [ ${ROOT} = "/" ] ; then
+ if [ ! -f ${ROOT}/var/qmail/control/me ] ; then
+ ${ROOT}/var/qmail/bin/config-fast $qhost
+ fi
+ fi
+
+ echo "Accepting relaying by default from all ips configured on this machine."
+ LOCALIPS=`/sbin/ifconfig | grep inet | cut -d " " -f 12 -s | cut -b 6-20`
+ for ip in $LOCALIPS; do
+ echo "$ip:allow,RELAYCLIENT=\"\"" >> /etc/tcp.smtp
+ done
+ echo ":allow" >> /etc/tcp.smtp
+
+ tcprules /etc/tcp.smtp.cdb /etc/tcp.smtp.tmp < /etc/tcp.smtp
+
+}