aboutsummaryrefslogtreecommitdiff
path: root/mail/masqmail
diff options
context:
space:
mode:
authorPav Lucistnik <pav@FreeBSD.org>2004-05-02 20:24:06 +0000
committerPav Lucistnik <pav@FreeBSD.org>2004-05-02 20:24:06 +0000
commit76a68720b1213a9b63b1ac060b0cf7171bd02a19 (patch)
tree544f1c9bfd6458d0991ce753711f0d75c88c0040 /mail/masqmail
parent295c3d94abb1b04fd3cda15a19c1ba0bccb3fca3 (diff)
downloadports-76a68720b1213a9b63b1ac060b0cf7171bd02a19.tar.gz
ports-76a68720b1213a9b63b1ac060b0cf7171bd02a19.zip
Notes
Diffstat (limited to 'mail/masqmail')
-rw-r--r--mail/masqmail/Makefile57
-rw-r--r--mail/masqmail/distinfo2
-rw-r--r--mail/masqmail/files/masqmail.sh63
-rw-r--r--mail/masqmail/files/patch-Makefile.in18
-rw-r--r--mail/masqmail/files/patch-masqmail.c11
-rw-r--r--mail/masqmail/files/patch-mserver.c11
-rw-r--r--mail/masqmail/files/patch-pop3_in.c11
-rw-r--r--mail/masqmail/files/patch-smtp_out.c20
-rw-r--r--mail/masqmail/pkg-descr23
-rw-r--r--mail/masqmail/pkg-plist16
10 files changed, 232 insertions, 0 deletions
diff --git a/mail/masqmail/Makefile b/mail/masqmail/Makefile
new file mode 100644
index 000000000000..f5dc4de3e208
--- /dev/null
+++ b/mail/masqmail/Makefile
@@ -0,0 +1,57 @@
+# Ports collection makefile for: masqmail
+# Date created: 4 Apr 2004
+# Whom: Andrey Slusar <vasallia@ukr.net>
+#
+# $FreeBSD$
+#
+
+PORTNAME= masqmail
+PORTVERSION= 0.1.17
+CATEGORIES= mail
+MASTER_SITES= http://innominate.org/kurth/masqmail/download/
+DISTNAME= MasqMail-${PORTVERSION}
+
+MAINTAINER= vasallia@ukr.net
+COMMENT= Mail server for hosts, not permanently connected to the internet
+
+MAN5= masqmail.aliases.5 masqmail.conf.5 masqmail.get.5 masqmail.route.5
+MAN8= masqmail.8
+
+GNU_CONFIGURE= yes
+CONFIGURE_ARGS+= --mandir=${PREFIX}/man --with-user=mailnull --with-group=mail \
+ --with-conffile=${PREFIX}/etc/masqmail --with-logdir=/var/log/masqmail
+
+.if defined(WITHOUT_POP3)
+CONFIGURE_ARGS+= --disable-pop3
+.endif
+.if defined(WITH_AUTH)
+CONFIGURE_ARGS+= --enable-auth
+.endif
+.if defined(WITH_IDENT)
+CONFIGURE_ARGS+= --enable-ident
+.endif
+
+USE_GNOME= glib12
+USE_RC_SUBR= yes
+
+post-build:
+ @${SED} -e 's,%%PREFIX%%,${PREFIX},g' \
+ -e 's,%%RC_SUBR%%,${RC_SUBR},g' \
+ ${FILESDIR}/masqmail.sh > ${WRKDIR}/masqmail.sh
+
+post-install:
+ ${INSTALL_SCRIPT} ${WRKDIR}/masqmail.sh ${PREFIX}/etc/rc.d/masqmail.sh
+ ${MKDIR} ${PREFIX}/etc/masqmail
+ ${CHOWN} mailnull:mail ${PREFIX}/etc/masqmail
+ ${INSTALL_DATA} -o mailnull -g mail ${WRKSRC}/examples/masqmail.conf ${PREFIX}/etc/masqmail/masqmail.conf-dist
+ ${INSTALL_DATA} -o mailnull -g mail ${WRKSRC}/examples/example.get ${PREFIX}/etc/masqmail/masqmail.get-dist
+ ${INSTALL_DATA} -o mailnull -g mail ${WRKSRC}/examples/example.route ${PREFIX}/etc/masqmail/masqmail.route-dist
+
+.if !defined(NOPORTDOCS)
+ ${MKDIR} ${DOCSDIR}
+.for i in AUTHORS COPYING INSTALL NEWS README THOUGHTS TODO docs/install.html
+ ${INSTALL_DATA} ${WRKSRC}/${i} ${DOCSDIR}
+.endfor
+.endif
+
+.include <bsd.port.mk>
diff --git a/mail/masqmail/distinfo b/mail/masqmail/distinfo
new file mode 100644
index 000000000000..d44e6de9b33d
--- /dev/null
+++ b/mail/masqmail/distinfo
@@ -0,0 +1,2 @@
+MD5 (MasqMail-0.1.17.tar.gz) = d62975ed5c20d4cebe7ad9e20f439e15
+SIZE (MasqMail-0.1.17.tar.gz) = 175425
diff --git a/mail/masqmail/files/masqmail.sh b/mail/masqmail/files/masqmail.sh
new file mode 100644
index 000000000000..1af2b245b8dc
--- /dev/null
+++ b/mail/masqmail/files/masqmail.sh
@@ -0,0 +1,63 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: mail
+# REQUIRE: LOGIN
+# KEYWORD: FreeBSD shutdown
+# we make mail start late, so that things like .forward's are not
+# processed until the system is fully operational
+
+#
+# Add the following lines to /etc/rc.conf to enable masqmail:
+#
+#masqmail_enable="YES"
+#
+# See masqmail(8) for flags
+#
+
+. %%RC_SUBR%%
+
+name=masqmail
+rcvar=`set_rcvar`
+
+command=%%PREFIX%%/sbin/masqmail
+required_dirs=/var/log/masqmail
+required_files=%%PREFIX%%/etc/masqmail/masqmail.conf
+
+start_precmd=start_precmd
+stop_postcmd=stop_postcmd
+
+extra_commands="reload"
+
+start_precmd()
+{
+ case $sendmail_enable in
+ [Yy][Ee][Ss]|[Tt][Rr][Uu][Ee]|[Oo][Nn]|1)
+ warn "sendmail_enable should be set to NONE"
+ ;;
+ [Nn][Oo]|[Ff][Aa][Ll][Ss][Ee]|[Oo][Ff][Ff]|0)
+ case $sendmail_submit_enable in
+ [Yy][Ee][Ss]|[Tt][Rr][Uu][Ee]|[Oo][Nn]|1)
+ warn "sendmail_submit_enable should be set to NO"
+ ;;
+ esac
+ ;;
+ [Nn][Oo][Nn][Ee])
+ ;;
+ esac
+}
+
+stop_postcmd()
+{
+ rm -f $pidfile
+}
+
+# set defaults
+
+masqmail_enable=${masqmail_enable:-"NO"}
+masqmail_flags=${masqmail_flags:-"-bd -q30m"}
+
+load_rc_config $name
+run_rc_command "$1"
diff --git a/mail/masqmail/files/patch-Makefile.in b/mail/masqmail/files/patch-Makefile.in
new file mode 100644
index 000000000000..10fadd751a6b
--- /dev/null
+++ b/mail/masqmail/files/patch-Makefile.in
@@ -0,0 +1,18 @@
+--- Makefile.in.old Sun Apr 4 19:10:04 2004
++++ Makefile.in Sun Apr 4 19:10:29 2004
+@@ -375,13 +375,13 @@
+
+ $(DESTDIR)@with_logdir@:
+ mkdir -p $(DESTDIR)@with_logdir@
+- chown @with_user@.@with_group@ $(DESTDIR)@with_logdir@
++ chown @with_user@:@with_group@ $(DESTDIR)@with_logdir@
+
+ $(DESTDIR)@with_spooldir@:
+ mkdir -p $(DESTDIR)@with_spooldir@
+ mkdir -p $(DESTDIR)@with_spooldir@/input
+ mkdir -p $(DESTDIR)@with_spooldir@/popuidl
+- chown -R @with_user@.@with_group@ $(DESTDIR)@with_spooldir@
++ chown -R @with_user@:@with_group@ $(DESTDIR)@with_spooldir@
+
+ # Tell versions [3.59,3.63) of GNU make to not export all variables.
+ # Otherwise a system limit (for SysV at least) may be exceeded.
diff --git a/mail/masqmail/files/patch-masqmail.c b/mail/masqmail/files/patch-masqmail.c
new file mode 100644
index 000000000000..8e6e1945bca2
--- /dev/null
+++ b/mail/masqmail/files/patch-masqmail.c
@@ -0,0 +1,11 @@
+--- src/masqmail.c.old Mon Apr 5 01:18:16 2004
++++ src/masqmail.c Mon Apr 5 01:23:09 2004
+@@ -167,7 +167,7 @@
+
+ DEBUG(5) debugf("accepting smtp message on stdin\n");
+
+- if(getpeername(0, &saddr, &dummy) == 0){
++ if(getpeername(0, (struct sockaddr *)(&saddr), &dummy) == 0){
+ peername = g_strdup(inet_ntoa(saddr.sin_addr));
+ #ifdef ENABLE_IDENT
+ {
diff --git a/mail/masqmail/files/patch-mserver.c b/mail/masqmail/files/patch-mserver.c
new file mode 100644
index 000000000000..f6cf0fefe119
--- /dev/null
+++ b/mail/masqmail/files/patch-mserver.c
@@ -0,0 +1,11 @@
+--- src/mserver.c.old Mon Mar 19 17:45:28 2001
++++ src/mserver.c Mon Apr 5 01:27:29 2004
+@@ -56,7 +56,7 @@
+ if(init_sockaddr(&saddr, conf.mserver_iface)){
+ int sock = socket(PF_INET, SOCK_STREAM, 0);
+ int dup_sock;
+- if(connect(sock, &saddr, sizeof(saddr)) == 0){
++ if(connect(sock, (struct sockaddr *)(&saddr), sizeof(saddr)) == 0){
+ FILE *in, *out;
+ char buf[256];
+
diff --git a/mail/masqmail/files/patch-pop3_in.c b/mail/masqmail/files/patch-pop3_in.c
new file mode 100644
index 000000000000..a633dc2e3199
--- /dev/null
+++ b/mail/masqmail/files/patch-pop3_in.c
@@ -0,0 +1,11 @@
+--- src/pop3_in.c.old Mon Apr 5 01:13:51 2004
++++ src/pop3_in.c Mon Apr 5 01:15:27 2004
+@@ -372,7 +372,7 @@
+ DEBUG(5){
+ struct sockaddr_in name;
+ int len;
+- getsockname(sock, &name, &len);
++ getsockname(sock, (struct sockaddr *)(&name), &len);
+ debugf("socket: name.sin_addr = %s\n", inet_ntoa(name.sin_addr));
+ }
+ return popb;
diff --git a/mail/masqmail/files/patch-smtp_out.c b/mail/masqmail/files/patch-smtp_out.c
new file mode 100644
index 000000000000..1320e928138c
--- /dev/null
+++ b/mail/masqmail/files/patch-smtp_out.c
@@ -0,0 +1,20 @@
+--- src/smtp_out.c.old Mon Apr 5 01:07:18 2004
++++ src/smtp_out.c Mon Apr 5 01:08:18 2004
+@@ -60,7 +60,7 @@
+ struct hostent *host_entry;
+
+ if(do_correct){
+- getsockname(psb->sock, &sname, &len);
++ getsockname(psb->sock, (struct sockaddr *)(&sname), &len);
+ DEBUG(5) debugf("socket: name.sin_addr = %s\n", inet_ntoa(sname.sin_addr));
+ host_entry =
+ gethostbyaddr((const char *)&(sname.sin_addr),
+@@ -455,7 +455,7 @@
+ DEBUG(5){
+ struct sockaddr_in name;
+ int len = sizeof(struct sockaddr);
+- getsockname(sock, &name, &len);
++ getsockname(sock, (struct sockaddr *)(&name), &len);
+ debugf("socket: name.sin_addr = %s\n", inet_ntoa(name.sin_addr));
+ }
+ return psb;
diff --git a/mail/masqmail/pkg-descr b/mail/masqmail/pkg-descr
new file mode 100644
index 000000000000..7466f5810af1
--- /dev/null
+++ b/mail/masqmail/pkg-descr
@@ -0,0 +1,23 @@
+MasqMail is a mail server designed for hosts that do not have a permanent
+internet connection eg. a home network or a single host at home. It has
+special support for connections to different ISPs. It replaces sendmail or
+other MTAs such as qmail or exim.
+
+Features
+
+ * Delivers only when online to a destination 'outside' your LAN
+ * Support for multiple Providers (ie. Mail Servers, or direct delivery)
+ * Rewriting of Return addresses (Return-Path:, From:, Reply-To:),
+ configurable for each Provider separately
+ * can also be used as a Mail Server on a LAN
+ * alias support
+ * delivery to pipes
+ * delivery to MDAs (eg. procmail)
+ * Maildir support (version >= 0.2.5)
+ * routing depending on sender
+ * AUTH (RFC 2554) support (as client, since version 0.1.0)
+ * SMTP-after-POP
+ * POP3 client
+ * POP3 client daemon (fetch mail in regular intervals if online)
+
+WWW: http://innominate.org/kurth/masqmail/
diff --git a/mail/masqmail/pkg-plist b/mail/masqmail/pkg-plist
new file mode 100644
index 000000000000..6a9961269ccb
--- /dev/null
+++ b/mail/masqmail/pkg-plist
@@ -0,0 +1,16 @@
+etc/rc.d/masqmail.sh
+etc/masqmail/masqmail.conf-dist
+etc/masqmail/masqmail.get-dist
+etc/masqmail/masqmail.route-dist
+sbin/masqmail
+%%DOCSDIR%%/AUTHORS
+%%DOCSDIR%%/COPYING
+%%DOCSDIR%%/INSTALL
+%%DOCSDIR%%/NEWS
+%%DOCSDIR%%/README
+%%DOCSDIR%%/THOUGHTS
+%%DOCSDIR%%/TODO
+%%DOCSDIR%%/install.html
+@dirrm etc/masqmail
+@dirrm %%DOCSDIR%%
+@unexec rmdir /var/log/masqmail 2>/dev/null || true