aboutsummaryrefslogtreecommitdiffstats
path: root/mail/metamail
diff options
context:
space:
mode:
authorpawel <pawel@FreeBSD.org>2012-10-30 01:29:56 +0800
committerpawel <pawel@FreeBSD.org>2012-10-30 01:29:56 +0800
commit00e798fa652e21a70e82d50d36981b4bd5a28785 (patch)
treeb3e7d5eb5c0f847591ea6b6f1c81b1eacdcd2c9a /mail/metamail
parente1834dfc17553253f9406967d89411cdd6bbe505 (diff)
downloadfreebsd-ports-gnome-00e798fa652e21a70e82d50d36981b4bd5a28785.tar.gz
freebsd-ports-gnome-00e798fa652e21a70e82d50d36981b4bd5a28785.tar.zst
freebsd-ports-gnome-00e798fa652e21a70e82d50d36981b4bd5a28785.zip
- Fix build with clang
- Add LICENSE PR: ports/172719 Submitted by: KATO Tsuguru <tkato432@yahoo.com> Feature safe: yes
Diffstat (limited to 'mail/metamail')
-rw-r--r--mail/metamail/Makefile11
-rw-r--r--mail/metamail/files/patch-metamail__uue.c33
-rw-r--r--mail/metamail/files/patch-metamail_codes.c31
-rw-r--r--mail/metamail/files/patch-metamail_mailto.c67
-rw-r--r--mail/metamail/files/patch-metamail_metamail.c35
-rw-r--r--mail/metamail/files/patch-richmail__iso2022.c11
-rw-r--r--mail/metamail/files/patch-richmail_richtext.c22
7 files changed, 195 insertions, 15 deletions
diff --git a/mail/metamail/Makefile b/mail/metamail/Makefile
index fe309c7ad53d..8a4cdbccec6c 100644
--- a/mail/metamail/Makefile
+++ b/mail/metamail/Makefile
@@ -1,9 +1,5 @@
-# New ports collection makefile for: metamail
-# Date created: 17 Oct 1994
-# Whom: torstenb
-#
+# Created by: torstenb
# $FreeBSD$
-#
PORTNAME= metamail
PORTVERSION= 2.7
@@ -17,13 +13,14 @@ EXTRACT_SUFX= .tar.Z
MAINTAINER= ports@FreeBSD.org
COMMENT= Implementation of MIME, the Multipurpose Internet Mail Extensions
+LICENSE= MIT
+
OPTIONS_DEFINE= X11
OPTIONS_DEFAULT= X11
X11_DESC= X11 hebrew font support
-USE_GCC= any
-
WRKSRC= ${WRKDIR}/${DISTNAME}/src
+
MAN1= audiocompose.1 audiosend.1 extcompose.1 \
getfilename.1 mailto-hebrew.1 mailto.1 metamail.1 \
metasend.1 mime.1 mimencode.1 mmencode.1 \
diff --git a/mail/metamail/files/patch-metamail__uue.c b/mail/metamail/files/patch-metamail__uue.c
new file mode 100644
index 000000000000..27a629368053
--- /dev/null
+++ b/mail/metamail/files/patch-metamail__uue.c
@@ -0,0 +1,33 @@
+--- metamail/uue.c.orig 1993-07-29 03:31:02.000000000 +0900
++++ metamail/uue.c 2012-10-13 08:01:35.000000000 +0900
+@@ -72,26 +72,26 @@
+ while (1) {
+ if (getline (buf, sizeof buf, infp) < 0) {
+ fprintf (stderr, "Premature EOF!\n");
+- return;
++ return(0);
+ }
+ if (strncmp (buf, "begin", 5) == 0)
+ break;
+ else if (buf[0] == '-' && buf[1] == '-') {
+ if (boundaries && PendingBoundary (buf, boundaries, ctptr))
+- return;
++ return(0);
+ }
+ }
+ while (1) {
+ if (getline (buf, sizeof buf, infp) < 0) {
+ fprintf (stderr, "Premature EOF!\n");
+- return;
++ return(0);
+ }
+ else if (strncmp (buf, "end", 5) == 0)
+ break;
+ else if (buf[0] == '-' && buf[1] == '-') {
+ if (boundaries && PendingBoundary (buf, boundaries, ctptr)) {
+ fprintf (stderr, "premature end of x-uue body part\n");
+- return;
++ return(0);
+ }
+ else {
+ fprintf (stderr, "ignoring invalid boundary marker\n");
diff --git a/mail/metamail/files/patch-metamail_codes.c b/mail/metamail/files/patch-metamail_codes.c
index 140597ac45e5..d6a57f1e6b83 100644
--- a/mail/metamail/files/patch-metamail_codes.c
+++ b/mail/metamail/files/patch-metamail_codes.c
@@ -1,5 +1,5 @@
---- metamail/codes.c.orig Mon Sep 20 15:13:22 1993
-+++ metamail/codes.c Mon Dec 18 11:46:21 2006
+--- metamail/codes.c.orig 1993-09-20 22:13:22.000000000 +0900
++++ metamail/codes.c 2012-10-13 07:59:21.000000000 +0900
@@ -13,6 +13,7 @@
WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
*/
@@ -8,3 +8,30 @@
#include <ctype.h>
#include <config.h>
+@@ -203,7 +204,7 @@
+ && (Buf[0] == '-')
+ && (Buf[1] == '-')
+ && PendingBoundary(Buf, boundaries, boundaryct)) {
+- return;
++ return(0);
+ }
+ fprintf(stderr, "Ignoring unrecognized boundary line: %s\n", Buf);
+ continue;
+@@ -221,7 +222,7 @@
+ } while (c4 != EOF && isspace(c4));
+ if (c2 == EOF || c3 == EOF || c4 == EOF) {
+ fprintf(stderr, "Warning: base64 decoder saw premature EOF!\n");
+- return;
++ return(0);
+ }
+ if (c1 == '=' || c2 == '=') {
+ DataDone=1;
+@@ -371,7 +372,7 @@
+ && (Buf[0] == '-')
+ && (Buf[1] == '-')
+ && PendingBoundary(Buf, boundaries, boundaryct)) {
+- return;
++ return(0);
+ }
+ /* Not a boundary, now we must treat THIS line as q-p, sigh */
+ if (neednewline) {
diff --git a/mail/metamail/files/patch-metamail_mailto.c b/mail/metamail/files/patch-metamail_mailto.c
index 42c6451cadaa..7d3d78adc1e0 100644
--- a/mail/metamail/files/patch-metamail_mailto.c
+++ b/mail/metamail/files/patch-metamail_mailto.c
@@ -1,5 +1,5 @@
---- metamail/mailto.c.orig Wed Feb 9 21:30:26 1994
-+++ metamail/mailto.c Mon Dec 18 11:46:21 2006
+--- metamail/mailto.c.orig 1994-02-10 05:30:26.000000000 +0900
++++ metamail/mailto.c 2012-10-13 08:04:36.000000000 +0900
@@ -37,6 +37,8 @@
*/
@@ -25,6 +25,15 @@
&& strncmp(CharacterSet, "iso-8859-", 9)) {
fprintf(stderr, "mailto: Unsupported character set: %s\n", CharacterSet);
exit(-1);
+@@ -1072,7 +1074,7 @@
+ #endif
+ }
+ fprintf(fp, "Message-ID: %s\n", newid());
+- if (!FirstPart) return; /* empty body */
++ if (!FirstPart) return(0); /* empty body */
+ if (FirstPart->next) {
+ char boundary[120];
+ #ifdef AMIGA
@@ -1130,6 +1132,7 @@
if (part->isrich) {
if (strcmp(CharacterSet, "us-ascii")
@@ -41,6 +50,15 @@
|| part->encoding_type_needed != ENC_NONE)) {
fprintf(fp, "; charset=\"%s\"\n", CharacterSet);
} else fputs("\n", fp);
+@@ -1346,7 +1350,7 @@
+ }
+ part->isrich = 1;
+ PartEndsWithNewline=1;
+- return;
++ return(0);
+ }
+ InNewLineSequence = 0;
+ if (RightToLeftMode) {
@@ -1745,6 +1749,7 @@
}
printf("\n\nEnter your choice as a number from 0 to %d: ", i);
@@ -81,6 +99,15 @@
while (s && *s && isspace((unsigned char) *s)) ++s;
if (s && (*s == 'y' || *s == 'Y')) break;
continue;
+@@ -2109,7 +2118,7 @@
+ fpout = fopen(FirstPart->filename, "a");
+ free(CmdBuf);
+ free(CmdBuf2);
+- return;
++ return(0);
+ }
+ lastmp = mp = FirstPart;
+ while (mp) {
@@ -2137,6 +2146,7 @@
printf("2: %s\n", CmdBuf);
printf("\n\nEnter 1 or 2, or 0 to not edit it: ");
@@ -89,3 +116,39 @@
fgets(LineBuf, sizeof(LineBuf), stdin);
ans = atoi(LineBuf);
} else ans = 2;
+@@ -2221,7 +2231,7 @@
+ int LineAlloced = 0, LineCount = 0;
+
+ fp = fopen(fname, "r");
+- if (!fp) return;
++ if (!fp) return(0);
+ do {
+ LineBuf=NextAliasLine(LineBuf, &LineAlloced, &LineCount, fp, IsAndrew);
+ if (LineCount == 0) continue;
+@@ -2310,7 +2320,7 @@
+ if (s != s2) printf("mailto: ignoring bad alias line in init file: %s\n", aliasline);
+ free(s);
+ free(tmpalias);
+- return;
++ return(0);
+ }
+ *s2++ = '\0';
+ tmpalias->shortname = s;
+@@ -2364,7 +2374,7 @@
+ {
+ char *firstnonascii, *firstascii;
+
+- if (!s) return;
++ if (!s) return(0);
+ firstnonascii=firstbad(s);
+ if (firstnonascii) {
+ if (!strcmp(CharacterSet, "us-ascii")) {
+@@ -2454,7 +2464,7 @@
+ /* if (!lc2strcmp(name, tmpalias->shortname)) { */
+ *end = savechar;
+ EmitAddresses(fp, tmpalias->longname, hdr);
+- return;
++ return(0);
+ }
+ }
+ *end = savechar;
diff --git a/mail/metamail/files/patch-metamail_metamail.c b/mail/metamail/files/patch-metamail_metamail.c
index 612e522c2e32..381e051974db 100644
--- a/mail/metamail/files/patch-metamail_metamail.c
+++ b/mail/metamail/files/patch-metamail_metamail.c
@@ -1,5 +1,5 @@
---- metamail/metamail.c.orig Thu Feb 17 02:57:19 1994
-+++ metamail/metamail.c Mon Dec 18 11:46:22 2006
+--- metamail/metamail.c.orig 1994-02-17 10:57:19.000000000 +0900
++++ metamail/metamail.c 2012-10-16 01:27:14.000000000 +0900
@@ -20,6 +20,8 @@
******************************************************* */
@@ -108,6 +108,28 @@
while (s && *s && isspace((unsigned char) *s)) ++s;
if (*s == 'y' || *s == 'Y' || !*s || *s == '\n') return(1);
if (*s == 'n' || *s == 'N' || *s == 'q' || *s == 'Q') {
+@@ -1915,18 +1926,18 @@
+ if (!strcmp(KeyHeadList[numkeys], "*")
+ || !lc2strncmp(hdr, KeyHeadList[numkeys], len)) {
+ if (!KeyKeep) phead(hdr);
+- return;
++ return(0);
+ }
+ }
+ if (KeyKeep) phead(hdr);
+- return;
++ return(0);
+ }
+ if (!strncmp(hdr, "From ", 5) || !strncmp(hdr, ">From ", 6)) {
+ for (numkeys = 0; KeyHeadList[numkeys]; ++numkeys) {
+ if (!strcmp(KeyHeadList[numkeys], "*")
+ || !lc2strncmp(">from", KeyHeadList[numkeys], 5)) {
+ if (!KeyKeep) phead(hdr);
+- return;
++ return(0);
+ }
+ }
+ if (KeyKeep) phead(hdr);
@@ -2022,7 +2033,8 @@
if (lc2strcmp(charset, PrevCharset)) {
char *s2, *charsetinuse;
@@ -165,6 +187,15 @@
}
#else
if (HasSavedTtyState) {
+@@ -2660,7 +2672,7 @@
+ char Buf[100];
+ #endif
+
+- if (DefinitelyNotTty || MustNotBeTty) return;
++ if (DefinitelyNotTty || MustNotBeTty) return(0);
+ #if defined(MSDOS) || defined(AMIGA)
+ printf("Press RETURN to go on\n");
+ gets(Buf);
@@ -2681,15 +2693,15 @@
StartRawStdin() {
diff --git a/mail/metamail/files/patch-richmail__iso2022.c b/mail/metamail/files/patch-richmail__iso2022.c
new file mode 100644
index 000000000000..8632ad35dab2
--- /dev/null
+++ b/mail/metamail/files/patch-richmail__iso2022.c
@@ -0,0 +1,11 @@
+--- richmail/iso2022.c.orig 1992-12-23 02:50:21.000000000 +0900
++++ richmail/iso2022.c 2012-10-13 08:09:11.000000000 +0900
+@@ -84,7 +84,7 @@
+ OutCharSet = OUT_ASCII;
+ OutAsciiMode = RICH_ENC_US_ASCII;
+ if (!name)
+- return;
++ return(0);
+ if (!strncmp (name,"iso-2022-jp",11))
+ richtextencoding (RICH_ENC_JP_ASCII);
+ else if (!strncmp (name,"iso-2022-kr",11)) {
diff --git a/mail/metamail/files/patch-richmail_richtext.c b/mail/metamail/files/patch-richmail_richtext.c
index 2dd6b686a41e..8e6d5e6be68f 100644
--- a/mail/metamail/files/patch-richmail_richtext.c
+++ b/mail/metamail/files/patch-richmail_richtext.c
@@ -1,5 +1,5 @@
---- richmail/richtext.c.orig Wed Feb 9 17:31:18 1994
-+++ richmail/richtext.c Mon Dec 18 11:46:22 2006
+--- richmail/richtext.c.orig 1994-02-10 01:31:18.000000000 +0900
++++ richmail/richtext.c 2012-10-13 08:07:01.000000000 +0900
@@ -14,6 +14,8 @@
*/
@@ -26,6 +26,24 @@
#ifndef RICHTEXT_LIBRARY
+@@ -910,7 +922,7 @@
+ FILE *fp;
+ {
+ int inmargin=1;
+- if (!s) return;
++ if (!s) return(0);
+ while (s -> ch) {
+ if (inmargin && (s -> ch) == ' ') {
+ controloutput(MoveRight, 1);
+@@ -932,7 +944,7 @@
+ *BoldOn, *BoldOff;
+ {
+ if (OverStrike)
+- return;
++ return(0);
+
+ /* We always turn back on the appropriate terminal modes, because
+ on some terminals one thing turns off all of them */
@@ -989,16 +1001,6 @@
while(*s) (*RichtextPutc)((int)(*s++),fp);
}