diff options
author | James FitzGibbon <jfitz@FreeBSD.org> | 1997-03-26 02:14:02 +0000 |
---|---|---|
committer | James FitzGibbon <jfitz@FreeBSD.org> | 1997-03-26 02:14:02 +0000 |
commit | b7999ad641dccbce055ec379e33a65edcdf352b5 (patch) | |
tree | 10fe6ce8ecedf292e4675b5f35d1518324677c38 | |
parent | 78b8a13a08e19a43b784e020f5278c0a3709c204 (diff) | |
download | ports-b7999ad641dccbce055ec379e33a65edcdf352b5.tar.gz ports-b7999ad641dccbce055ec379e33a65edcdf352b5.zip |
Notes
-rw-r--r-- | mail/bulk_mailer/Makefile | 20 | ||||
-rw-r--r-- | mail/bulk_mailer/distinfo | 1 | ||||
-rw-r--r-- | mail/bulk_mailer/files/patch-aa | 57 | ||||
-rw-r--r-- | mail/bulk_mailer/files/patch-ab | 165 | ||||
-rw-r--r-- | mail/bulk_mailer/pkg-comment | 1 | ||||
-rw-r--r-- | mail/bulk_mailer/pkg-descr | 8 | ||||
-rw-r--r-- | mail/bulk_mailer/pkg-plist | 2 |
7 files changed, 254 insertions, 0 deletions
diff --git a/mail/bulk_mailer/Makefile b/mail/bulk_mailer/Makefile new file mode 100644 index 000000000000..2a2da880b316 --- /dev/null +++ b/mail/bulk_mailer/Makefile @@ -0,0 +1,20 @@ +# New ports collection makefile for: bulk_mailer +# Version required: 1.5 +# Date created: 20 March 1997 +# Whom: dlowe +# +# $Id$ +# + +DISTNAME= bulk_mailer-1.5 +CATEGORIES= mail + +MASTER_SITES= ftp://cs.utk.edu/pub/moore/bulk_mailer/ + +EXTRACT_SUFX= .tar +EXTRACT_BEFORE_ARGS= -C ${WRKDIR} -xf +NO_WRKSUBDIR= YES + +MAINTAINER= dlowe@saturn5.com + +.include <bsd.port.mk> diff --git a/mail/bulk_mailer/distinfo b/mail/bulk_mailer/distinfo new file mode 100644 index 000000000000..ce53f0ed4d9e --- /dev/null +++ b/mail/bulk_mailer/distinfo @@ -0,0 +1 @@ +MD5 (bulk_mailer-1.5.tar) = 610cb591f1476f60f937c33c6639704d diff --git a/mail/bulk_mailer/files/patch-aa b/mail/bulk_mailer/files/patch-aa new file mode 100644 index 000000000000..aee59a743951 --- /dev/null +++ b/mail/bulk_mailer/files/patch-aa @@ -0,0 +1,57 @@ +*** Makefile.orig Sun Jan 28 17:53:14 1996 +--- Makefile Fri Mar 22 19:39:36 1996 +*************** +*** 5,28 **** + # HASSTRERROR - whether system has strerror() call + # LIBS - local libraries to link in (e.g. -lresolv) + +! HASSTRDUP = # -DHAS_STRDUP +! HASSTRERROR = # -DHAS_STRERROR + LIBS = # -lresolv + + DEFINES = $(HASSTRDUP) $(HASSTRERROR) $(DEFAULT_DOMAIN) + +! CFLAGS = $(DEFINES) + + FILES = bulk_mailer.README INSTALL bulk_mailer.c patchlevel.h Makefile + + bulk_mailer: bulk_mailer.o + $(CC) $(CFLAGS) -o bulk_mailer bulk_mailer.o $(LIBS) + + bulk_mailer.o: bulk_mailer.c patchlevel.h + $(CC) -c $(CFLAGS) bulk_mailer.c + + install: bulk_mailer +! cp bulk_mailer /usr/local/bin + + clean: + rm -f bulk_mailer bulk_mailer.o +--- 5,32 ---- + # HASSTRERROR - whether system has strerror() call + # LIBS - local libraries to link in (e.g. -lresolv) + +! HASSTRDUP = -DHAS_STRDUP +! HASSTRERROR = -DHAS_STRERROR + LIBS = # -lresolv + + DEFINES = $(HASSTRDUP) $(HASSTRERROR) $(DEFAULT_DOMAIN) + +! CFLAGS = -O2 -Wall $(DEFINES) + + FILES = bulk_mailer.README INSTALL bulk_mailer.c patchlevel.h Makefile + ++ all: bulk_mailer ++ + bulk_mailer: bulk_mailer.o + $(CC) $(CFLAGS) -o bulk_mailer bulk_mailer.o $(LIBS) ++ strip bulk_mailer + + bulk_mailer.o: bulk_mailer.c patchlevel.h + $(CC) -c $(CFLAGS) bulk_mailer.c + + install: bulk_mailer +! install -c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} bulk_mailer ${PREFIX}/bin/bulk_mailer +! install -c -o ${SHAREOWN} -g ${SHAREGRP} -m ${SHAREMODE} bulk_mailer.README ${PREFIX}/share/doc/bulk_mailer.README + + clean: + rm -f bulk_mailer bulk_mailer.o diff --git a/mail/bulk_mailer/files/patch-ab b/mail/bulk_mailer/files/patch-ab new file mode 100644 index 000000000000..adecbd5a2794 --- /dev/null +++ b/mail/bulk_mailer/files/patch-ab @@ -0,0 +1,165 @@ +*** bulk_mailer.c.original Sun Feb 11 09:49:32 1996 +--- bulk_mailer.c Fri Mar 22 18:55:32 1996 +*************** +*** 87,92 **** +--- 87,95 ---- + #include <sysexits.h> + #include <errno.h> + #include <time.h> ++ #include <string.h> ++ #include <stdlib.h> ++ #include <unistd.h> + #include "patchlevel.h" + + #ifndef PIPECOMMAND +*************** +*** 260,274 **** + * memory, appending a NUL to the copy. + */ + +! static char * +! strndup (str, len) +! { +! char *result = malloc_or_else (len + 1); +! +! strncpy (result, str, len); +! result[len] = '\0'; +! return result; +! } + + /* + * sort by case-folded reversed domain +--- 263,277 ---- + * memory, appending a NUL to the copy. + */ + +! /* static char * */ +! /* strndup (str, len) */ +! /* { */ +! /* char *result = malloc_or_else (len + 1); */ +! +! /* strncpy (result, str, len); */ +! /* result[len] = '\0'; */ +! /* return result; */ +! /* } */ + + /* + * sort by case-folded reversed domain +*************** +*** 299,313 **** + { + char *at; + char *ptr; +! char *domain; + char tempbuf[1024]; +! char c; + + /* + * make sure there's room in the buffer. + */ + if (num_addrs >= num_addr_slots) { +! struct address *new; + + num_addr_slots += 1000; + if (address_list == NULL) +--- 302,316 ---- + { + char *at; + char *ptr; +! /* char *domain; */ + char tempbuf[1024]; +! /* char c; */ + + /* + * make sure there's room in the buffer. + */ + if (num_addrs >= num_addr_slots) { +! /* struct address *new; */ + + num_addr_slots += 1000; + if (address_list == NULL) +*************** +*** 903,909 **** + copy_message (out, in) + FILE *out, *in; + { +! int c; + char linebuf[32*1024]; + int has_valid_approved_hdr = 0; + int has_resent_to_hdr = 0; +--- 906,912 ---- + copy_message (out, in) + FILE *out, *in; + { +! /* int c; */ + char linebuf[32*1024]; + int has_valid_approved_hdr = 0; + int has_resent_to_hdr = 0; +*************** +*** 1077,1090 **** + */ + lines = 0; + while (fgets (linebuf, sizeof (linebuf), in) != NULL) { +! if (lines < 5 && + /* + * these often occur in English-text unsubscribe requests + */ + contains (linebuf, "delete me") || + contains (linebuf, "remove me") || + contains (linebuf, "subscribe") || +! contains (linebuf, "unsubscribe")) + saw_command = 1; + ++lines; + fputs (linebuf, out); +--- 1080,1093 ---- + */ + lines = 0; + while (fgets (linebuf, sizeof (linebuf), in) != NULL) { +! if (lines < 5 && ( + /* + * these often occur in English-text unsubscribe requests + */ + contains (linebuf, "delete me") || + contains (linebuf, "remove me") || + contains (linebuf, "subscribe") || +! contains (linebuf, "unsubscribe"))) + saw_command = 1; + ++lines; + fputs (linebuf, out); +*************** +*** 1181,1193 **** + int argc; + char *argv[]; + { +! int i; + FILE *fp; + FILE *tmp; + static char template[] = "/tmp/blkXXXXXX"; + char *tempname; +! int c; +! char buf[1024]; + + while (argc > 1 && (*argv[1] == '-' || *argv[1] == '+')) { + if (strcmp (argv[1], "-debug") == 0) +--- 1184,1196 ---- + int argc; + char *argv[]; + { +! /* int i; */ + FILE *fp; + FILE *tmp; + static char template[] = "/tmp/blkXXXXXX"; + char *tempname; +! /* int c; */ +! /* char buf[1024]; */ + + while (argc > 1 && (*argv[1] == '-' || *argv[1] == '+')) { + if (strcmp (argv[1], "-debug") == 0) +*************** +*** 1338,1341 **** +--- 1341,1345 ---- + + exit (EX_OK); + } ++ exit (EX_OK); + } diff --git a/mail/bulk_mailer/pkg-comment b/mail/bulk_mailer/pkg-comment new file mode 100644 index 000000000000..dbc8b2639bdc --- /dev/null +++ b/mail/bulk_mailer/pkg-comment @@ -0,0 +1 @@ +Speeds delivery to large mailing lists by sorting & batching addresses. diff --git a/mail/bulk_mailer/pkg-descr b/mail/bulk_mailer/pkg-descr new file mode 100644 index 000000000000..1579e1ababa4 --- /dev/null +++ b/mail/bulk_mailer/pkg-descr @@ -0,0 +1,8 @@ +This is a C program to do "bulk" mailing. For input, it takes a file +of recipient addresses (one address per line) and a message (with +headers already attached) to be sent to the recipients. It sorts the +recipient list by reversed domain (so similar ones sort together), +splits up the recipients into several groups containing no more than N +domains each, creates an SMTP envelope for each group of recipients, +and feeds that envelope to "/usr/sbin/sendmail -bs". + diff --git a/mail/bulk_mailer/pkg-plist b/mail/bulk_mailer/pkg-plist new file mode 100644 index 000000000000..80f2ba02c575 --- /dev/null +++ b/mail/bulk_mailer/pkg-plist @@ -0,0 +1,2 @@ +bin/bulk_mailer +share/doc/bulk_mailer.README |