diff options
author | Achim Gottinger <achim@gentoo.org> | 2000-12-11 18:20:17 +0000 |
---|---|---|
committer | Achim Gottinger <achim@gentoo.org> | 2000-12-11 18:20:17 +0000 |
commit | fb014417aab266dc9d40ee1e0a4c094169f3a1da (patch) | |
tree | 22a100b0a45e920a856a33541fc451462c62f9e2 /app-text | |
parent | *** empty log message *** (diff) | |
download | gentoo-2-fb014417aab266dc9d40ee1e0a4c094169f3a1da.tar.gz gentoo-2-fb014417aab266dc9d40ee1e0a4c094169f3a1da.tar.bz2 gentoo-2-fb014417aab266dc9d40ee1e0a4c094169f3a1da.zip |
*** empty log message ***
Diffstat (limited to 'app-text')
31 files changed, 0 insertions, 2764 deletions
diff --git a/app-text/aspell/aspell-0.32.5.ebuild b/app-text/aspell/aspell-0.32.5.ebuild deleted file mode 100644 index f4dc0c804507..000000000000 --- a/app-text/aspell/aspell-0.32.5.ebuild +++ /dev/null @@ -1,28 +0,0 @@ -# Copyright 1999-2000 Gentoo Technologies, Inc. -# Distributed under the terms of the GNU General Public License, v2 or later -# Author Achim Gottinger <achim@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/app-text/aspell/aspell-0.32.5.ebuild,v 1.1 2000/10/14 11:20:58 achim Exp $ - -P=${PN}-.32.5 -A=${P}.tar.gz -S=${WORKDIR}/${P} -DESCRIPTION="A spell checker replacement for ispell" -SRC_URI="http://download.sourceforge.net/aspell/${A}" -HOMEPAGE="http://aspell.sourceforge.net" - - -src_compile() { - - cd ${S} - try ./configure --prefix=/usr --host=${CHOST} - try make - -} - -src_install () { - - cd ${S} - try make DESTDIR=${D} install - -} - diff --git a/app-text/aspell/files/digest-aspell-0.32.5 b/app-text/aspell/files/digest-aspell-0.32.5 deleted file mode 100644 index ab93fbbc263c..000000000000 --- a/app-text/aspell/files/digest-aspell-0.32.5 +++ /dev/null @@ -1 +0,0 @@ -MD5 15723a7a0373977c21536a3134d5b7d8 aspell-.32.5.tar.gz diff --git a/app-text/dgs/dgs-0.5.9.1.ebuild b/app-text/dgs/dgs-0.5.9.1.ebuild deleted file mode 100644 index 0fef483f49f7..000000000000 --- a/app-text/dgs/dgs-0.5.9.1.ebuild +++ /dev/null @@ -1,32 +0,0 @@ -# Copyright 1999-2000 Gentoo Technologies, Inc. -# Distributed under the terms of the GNU General Public License, v2 or later -# Author Achim Gottinger <achim@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/app-text/dgs/dgs-0.5.9.1.ebuild,v 1.3 2000/11/01 04:44:13 achim Exp $ - -A=${P}.tar.gz -S=${WORKDIR}/dgs-0.5.9 -DESCRIPTION="A Ghostscript based DPS server" -SRC_URI="ftp://ftp.gnustep.org/pub/gnustep/dgs/${A}" -HOMEPAGE="http://www.aist-nara.ac.jp/~masata-y/dgs/index.html" - -DEPEND=">=sys-apps/bash-2.04 - >=sys-libs/glibc-2.1.3 - >=dev-libs/glib-1.2.8 - >=x11-base/xfree-4.0.1" - -src_compile() { - - cd ${S} - try ./configure --prefix=/usr --host=${CHOST} --with-x - try make - -} - -src_install () { - - cd ${S} - make prefix=${D}/usr install - prepman - dodoc ANNOUNCE ChangeLog FAQ NEWS NOTES README STATUS TODO Version -} - diff --git a/app-text/dgs/files/digest-dgs-0.5.9.1 b/app-text/dgs/files/digest-dgs-0.5.9.1 deleted file mode 100644 index d2d21ce0fcea..000000000000 --- a/app-text/dgs/files/digest-dgs-0.5.9.1 +++ /dev/null @@ -1 +0,0 @@ -MD5 7f1c0cb0f7fe1d1899b88e4d89809ac4 dgs-0.5.9.1.tar.gz diff --git a/app-text/docbook/files/digest-docbook-3.0-r1 b/app-text/docbook/files/digest-docbook-3.0-r1 deleted file mode 100644 index 8add2b3f5788..000000000000 --- a/app-text/docbook/files/digest-docbook-3.0-r1 +++ /dev/null @@ -1,2 +0,0 @@ -MD5 9a7f5b1b7dd52d0ca4fb080619f0459c docbk30.zip -MD5 c8a9561212c1a2ec6e48919640de9c67 ISOEnts.zip diff --git a/app-text/docbook/files/digest-docbook-4.1-r1 b/app-text/docbook/files/digest-docbook-4.1-r1 deleted file mode 100644 index 9543b0d1b871..000000000000 --- a/app-text/docbook/files/digest-docbook-4.1-r1 +++ /dev/null @@ -1,2 +0,0 @@ -MD5 489f6ff2a2173eb1e14216c10533ede2 docbk41.zip -MD5 c8a9561212c1a2ec6e48919640de9c67 ISOEnts.zip diff --git a/app-text/dsssl/files/digest-dsssl-db-1.56 b/app-text/dsssl/files/digest-dsssl-db-1.56 deleted file mode 100644 index 1e900b986447..000000000000 --- a/app-text/dsssl/files/digest-dsssl-db-1.56 +++ /dev/null @@ -1 +0,0 @@ -MD5 aeeb8502e78afd5f46fe34258732aa97 db156.zip diff --git a/app-text/ghostscript/files/digest-ghostscript-6.23 b/app-text/ghostscript/files/digest-ghostscript-6.23 deleted file mode 100644 index 1a24e5d4968f..000000000000 --- a/app-text/ghostscript/files/digest-ghostscript-6.23 +++ /dev/null @@ -1,2 +0,0 @@ -MD5 6872883a40a560273ea046873412e7c4 ghostscript-6.23.tar.gz -MD5 8250132d6fcc6eb1419f505f06c7690b ghostscript-fonts-std-6.0.tar.gz diff --git a/app-text/ghostscript/files/digest-ghostscript-6.23-r2 b/app-text/ghostscript/files/digest-ghostscript-6.23-r2 deleted file mode 100644 index 10fc3da383ca..000000000000 --- a/app-text/ghostscript/files/digest-ghostscript-6.23-r2 +++ /dev/null @@ -1,3 +0,0 @@ -MD5 6872883a40a560273ea046873412e7c4 ghostscript-6.23.tar.gz -MD5 8250132d6fcc6eb1419f505f06c7690b ghostscript-fonts-std-6.0.tar.gz -MD5 ed084c3c0c8cc8862a709308220542f4 print-4.0.0rc1.tar.gz diff --git a/app-text/ghostscript/files/digest-ghostscript-6.31 b/app-text/ghostscript/files/digest-ghostscript-6.31 deleted file mode 100644 index a4c526114631..000000000000 --- a/app-text/ghostscript/files/digest-ghostscript-6.31 +++ /dev/null @@ -1,3 +0,0 @@ -MD5 24231b31b5bcad79001566b8a19cff06 ghostscript-6.31.tar.gz -MD5 8250132d6fcc6eb1419f505f06c7690b ghostscript-fonts-std-6.0.tar.gz -MD5 162790709852395d2794bd45226156fa print-4.0.3.tar.gz diff --git a/app-text/ghostscript/ghostscript-6.23-r2.ebuild b/app-text/ghostscript/ghostscript-6.23-r2.ebuild deleted file mode 100644 index 0e48dddcb29c..000000000000 --- a/app-text/ghostscript/ghostscript-6.23-r2.ebuild +++ /dev/null @@ -1,85 +0,0 @@ -# Copyright 1999-2000 Gentoo Technologies, Inc. -# Distributed under the terms of the GNU General Public License, v2 or later -# Author Achim Gottinger <achim@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/app-text/ghostscript/ghostscript-6.23-r2.ebuild,v 1.3 2000/12/01 21:58:44 achim Exp $ - -P=ghostscript-6.23 -A="${P}.tar.gz ghostscript-fonts-std-6.0.tar.gz print-4.0.0rc1.tar.gz" -A1=jpegsrc.v6b.tar.gz -A2=zlib-1.1.3.tar.gz -A3=libpng-1.0.8.tar.gz - -S=${WORKDIR}/gs6.23 -DESCRIPTION="Aladin Ghostscript" -SRC_URI="http://download.sourceforge.net/ghostscript/${P}.tar.gz - http://download.sourceforge.net/gs-fonts/ghostscript-fonts-std-6.0.tar.gz - http://download.sourceforge.net/gimp-print/print-4.0.0rc1.tar.gz" - -DEPEND=">=sys-apps/bash-2.04 - >=sys-libs/glibc-2.1.3 - >=media-libs/libpng-1.0.7 - >=x11-base/xfree-4.0.1" - -src_unpack() { - unpack ${A} - cd ${S} - mkdir zlib - cd zlib - unpack ${A2} - cd .. - mkdir jpeg - cd jpeg - unpack ${A1} - cd .. - mkdir libpng - cd libpng - unpack ${A3} - cd ../src - cp ${O}/files/all-arch.mak all-arch.mak - cd ${WORKDIR}/print-4.0.0rc1/Ghost - cp *.c *.h ${S}/src - cat contrib.mak.addon >> ${S}/src/contrib.mak - cd ${S}/src - cp unix-gcc.mak unix-gcc.mak.orig - sed -e "s:^DEVICE_DEVS6=:DEVICE_DEVS6=\$\(DD\)stp\.dev :" \ - unix-gcc.mak.orig > unix-gcc.mak -} - -src_compile() { - cd ${S}/src - cp all-arch.mak all-arch.mak.orig - sed -e "s:^SRCDIR.*:SRCDIR = ${S}:" all-arch.mak.orig > all-arch.mak - cp unix-gcc.mak unix-gcc.mak.orig - sed -e "s:-O2:${CFLAGS}:" unix-gcc.mak.orig > unix-gcc.mak - cd .. - try make -f src/all-arch.mak linux prefix=/usr - cd ${WORKDIR}/print-4.0.0rc1/Ghost - try make -} - -src_install() { - cd ${S} - dobin bin/gs - try make -f src/all-arch.mak prefix=${D}/usr BINDIR=${D}/usr/bin install - cd ${WORKDIR} - cp -a fonts ${D}/usr/share/ghostscript - cd ${S} - - dodir /usr/doc/${PF} - rm -rf ${D}/usr/share/ghostscript/6.23/doc - dodoc doc/README doc/PUBLIC - docinto html - dodoc doc/*.html doc/*.htm - insinto /usr/share/emacs/site-lisp - doins doc/gsdoc.el - - cd ${WORKDIR}/print-4.0.0rc1/Ghost - dobin escputil - docinto stp - dodoc README* COPYING ChangeLog - cp -a stp-interface ${D}/usr/doc/${P}/stp -} - - - - diff --git a/app-text/ghostscript/ghostscript-6.31.ebuild b/app-text/ghostscript/ghostscript-6.31.ebuild deleted file mode 100644 index 4490286d1a9d..000000000000 --- a/app-text/ghostscript/ghostscript-6.31.ebuild +++ /dev/null @@ -1,88 +0,0 @@ -# Copyright 1999-2000 Gentoo Technologies, Inc. -# Distributed under the terms of the GNU General Public License, v2 or later -# Author Achim Gottinger <achim@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/app-text/ghostscript/ghostscript-6.31.ebuild,v 1.4 2000/12/11 18:05:42 achim Exp $ - -GPV="4.0.4" -A="${P}.tar.gz ghostscript-fonts-std-6.0.tar.gz print-${GPV}.tar.gz" -A1=jpegsrc.v6b.tar.gz -A2=zlib-1.1.3.tar.gz -A3=libpng-1.0.8.tar.gz - -S=${WORKDIR}/gs${PV} -DESCRIPTION="Aladin Ghostscript" -SRC_URI="http://download.sourceforge.net/ghostscript/${P}.tar.gz - http://download.sourceforge.net/gs-fonts/ghostscript-fonts-std-6.0.tar.gz - http://download.sourceforge.net/gimp-print/print-${GPV}.tar.gz - http://www.libpng.org/pub/png/src/${A3} - ftp://ftp.freesoftware.com/pub/infozip/zlib/${A2} - ftp://ftp.uu.net/graphics/jpeg/${A1}" - -DEPEND=">=sys-apps/bash-2.04 - >=sys-libs/glibc-2.1.3 - >=media-libs/libpng-1.0.7 - >=x11-base/xfree-4.0.1" - -src_unpack() { - unpack ${A} - cd ${S} - mkdir zlib - cd zlib - unpack ${A2} - cd .. - mkdir jpeg - cd jpeg - unpack ${A1} - cd .. - mkdir libpng - cd libpng - unpack ${A3} - cd ../src - cp ${O}/files/all-arch.mak all-arch.mak - cd ${WORKDIR}/print-${GPV}/Ghost - cp *.c *.h ${S}/src - cat contrib.mak.addon >> ${S}/src/contrib.mak - cd ${S}/src - cp unix-gcc.mak unix-gcc.mak.orig - sed -e "s:^DEVICE_DEVS6=:DEVICE_DEVS6=\$\(DD\)stp\.dev :" \ - unix-gcc.mak.orig > unix-gcc.mak -} - -src_compile() { - cd ${S}/src - cp all-arch.mak all-arch.mak.orig - sed -e "s:^SRCDIR.*:SRCDIR = ${S}:" all-arch.mak.orig > all-arch.mak - cp unix-gcc.mak unix-gcc.mak.orig - sed -e "s:-O2:${CFLAGS}:" unix-gcc.mak.orig > unix-gcc.mak - cd .. - try make -f src/all-arch.mak linux prefix=/usr - cd ${WORKDIR}/print-${GPV}/Ghost - try make -} - -src_install() { - cd ${S} - dobin bin/gs - try make -f src/all-arch.mak prefix=${D}/usr BINDIR=${D}/usr/bin install - cd ${WORKDIR} - cp -a fonts ${D}/usr/share/ghostscript - cd ${S} - - dodir /usr/doc/${PF} - rm -rf ${D}/usr/share/ghostscript/${PV}/doc - dodoc doc/README doc/PUBLIC - docinto html - dodoc doc/*.html doc/*.htm - insinto /usr/share/emacs/site-lisp - doins doc/gsdoc.el - - cd ${WORKDIR}/print-${GPV}/Ghost - dobin escputil - docinto stp - dodoc README* COPYING ChangeLog - cp -a stp-interface ${D}/usr/doc/${P}/stp -} - - - - diff --git a/app-text/metamail/files/digest-metamail-2.7-r1 b/app-text/metamail/files/digest-metamail-2.7-r1 deleted file mode 100644 index e4a8ed9fcf12..000000000000 --- a/app-text/metamail/files/digest-metamail-2.7-r1 +++ /dev/null @@ -1 +0,0 @@ -MD5 fd5617ea87e20d7f2fa839e1d1fede60 mm2.7.tar.Z diff --git a/app-text/metamail/files/digest-metamail-2.7-r2 b/app-text/metamail/files/digest-metamail-2.7-r2 deleted file mode 100644 index e4a8ed9fcf12..000000000000 --- a/app-text/metamail/files/digest-metamail-2.7-r2 +++ /dev/null @@ -1 +0,0 @@ -MD5 fd5617ea87e20d7f2fa839e1d1fede60 mm2.7.tar.Z diff --git a/app-text/metamail/files/mm-2.7-arghhh.patch b/app-text/metamail/files/mm-2.7-arghhh.patch deleted file mode 100644 index c4bbcb65bc98..000000000000 --- a/app-text/metamail/files/mm-2.7-arghhh.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- mm2.7/src/bin/showexternal~ Mon Jun 22 10:55:36 1998 -+++ mm2.7/src/bin/showexternal Tue Jun 23 21:16:04 1998 -@@ -215,7 +215,7 @@ - exit -1 - endif - echo Subject: Automated Mail Server Request > "$NEWNAME" -- echo To: ${server} >> "$NEWNAME" -+ echo To: "$server" >> "$NEWNAME" - echo "" >> "$NEWNAME" - sed -e 1,/^\$/d < $bodyfile >> "$NEWNAME" - echo "" >> "$NEWNAME" diff --git a/app-text/metamail/files/mm-2.7-csh.patch b/app-text/metamail/files/mm-2.7-csh.patch deleted file mode 100644 index a4e8a46fd756..000000000000 --- a/app-text/metamail/files/mm-2.7-csh.patch +++ /dev/null @@ -1,124 +0,0 @@ ---- mm2.7/src/metamail/mailto.c.cshfix Sat Oct 25 09:50:36 1997 -+++ mm2.7/src/metamail/mailto.c Sat Oct 25 09:51:03 1997 -@@ -200,9 +200,12 @@ - } - - TildeHelp() { -- char *pager = getenv("PAGER"); - char TmpName[100], CmdBuf[150]; -+ char *pager; - FILE *fp; -+ -+ if ((pager = getenv("METAMAIL_PAGER")) == NULL) -+ pager = getenv("PAGER"); - - strcpy(TmpName, tmpname()); - fp = fopen(TmpName, "w"); ---- mm2.7/src/bin/showexternal.cshfix Sat Oct 25 09:45:05 1997 -+++ mm2.7/src/bin/showexternal Sat Oct 25 09:46:25 1997 -@@ -19,6 +19,9 @@ - if (! $?METAMAIL_TMPDIR) then - set METAMAIL_TMPDIR=/tmp - endif -+if (! $?METAMAIL_PAGER) then -+ set METAMAIL_PAGER=more -+endif - if (! $?FTP) then - set FTP=ftp - endif -@@ -27,11 +30,19 @@ - echo "Usage: showexternal body-file access-type name [site [directory [mode [server]]]]" - exit -1 - endif --set bodyfile=$1 -+# Check argument integrity. Don't trust mail headers -+switch ("$1$2$3$4$5$6$7") -+case "*[ ]*": -+ echo "Illegal white space in arguments -- possibly a mail bomb?!" -+ echo "Command was:" -+ echo \'$0\' \'$1\' \'$2\' \'$3\' \'$4\' \'$5\' \'$6\' \'$7\' -+ exit 2 -+endsw -+set bodyfile="$1" - set atype=`echo $2 | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` - set name=$3 - if ($#argv > 3) then -- set site=$4 -+ set site="$4" - else - set site="" - endif -@@ -41,12 +52,12 @@ - set dir="" - endif - if ($#argv > 5) then -- set mode=$6 -+ set mode="$6" - else - set mode="" - endif - if ($#argv > 6) then -- set server=$7 -+ set server="$7" - else - set server="" - endif -@@ -96,7 +107,7 @@ - - ! - sed -e 1,/^\$/d < $bodyfile >> ${METAMAIL_TMPDIR}/ext.junk.$$ -- more ${METAMAIL_TMPDIR}/ext.junk.$$ -+ ${METAMAIL_PAGER} ${METAMAIL_TMPDIR}/ext.junk.$$ - rm ${METAMAIL_TMPDIR}/ext.junk.$$ - breaksw - default: ---- mm2.7/src/bin/showpartial.cshfix Sat Oct 25 09:46:37 1997 -+++ mm2.7/src/bin/showpartial Sat Oct 25 09:47:24 1997 -@@ -11,14 +11,14 @@ - echo "Usage: showpartial file id partnum totalnum" - exit -1 - endif --set file=$1 -+set file="$1" - # This next line is because message-id can contain weird chars - set id=`echo $2 | tr -d \!\$\&\*\(\)\|\'\"\;\/\<\>\\` - @ partnum = $3 - if ($#argv == 3 || $4 == "") then - set totalnum=-1 - else -- @ totalnum = $4 -+ @ totalnum = "$4" - endif - - if (! -d $TREEROOT) then ---- mm2.7/src/bin/sun-message.csh.cshfix Sat Oct 25 09:49:16 1997 -+++ mm2.7/src/bin/sun-message.csh Sat Oct 25 09:50:15 1997 -@@ -8,6 +8,10 @@ - mkdir /tmp/decode.$$ - cd /tmp/decode.$$ - -+if (! $?METAMAIL_PAGER) then -+ set METAMAIL_PAGER=more -+endif -+ - if ($2 == "uuencode") then - uudecode $1 - -@@ -37,7 +41,7 @@ - cd /tmp; /bin/rm -rf /tmp/decode.$$ - exit 0 - else if ($ans == 1) then -- more $fn -+ ${METAMAIL_PAGER} $fn - else if ($ans == 2) then - set nfn = "" - echo -n "Save as: $HOME/" -@@ -53,7 +57,7 @@ - set defans = "3" - end - else -- more $1 -+ ${METAMAIL_PAGER} $1 - endif - - diff --git a/app-text/metamail/files/mm-2.7-fonts.patch b/app-text/metamail/files/mm-2.7-fonts.patch deleted file mode 100644 index 5e607ce36d8d..000000000000 --- a/app-text/metamail/files/mm-2.7-fonts.patch +++ /dev/null @@ -1,16 +0,0 @@ ---- mm2.7/src/fonts/Makefile.marc Tue Feb 13 14:56:31 1996 -+++ mm2.7/src/fonts/Makefile Tue Feb 13 14:57:00 1996 -@@ -28,11 +28,11 @@ - -${DIRBUILDER} - - shownonascii: Xshownonascii -- sed -e s@/u/nsb/lib/fonts@`pwd`@ < Xshownonascii > shownonascii -+ sed -e s@/u/nsb/lib/fonts@/usr/lib/metamail/fonts@ < Xshownonascii > shownonascii - chmod +x shownonascii - - mailto-hebrew: Xmailto-hebrew -- sed -e s@/u/nsb/lib/fonts@`pwd`@ < Xmailto-hebrew > mailto-hebrew -+ sed -e s@/u/nsb/lib/fonts@/usr/lib/metamail/fonts@ < Xmailto-hebrew > mailto-hebrew - chmod +x mailto-hebrew - - clean: diff --git a/app-text/metamail/files/mm-2.7-glibc.patch b/app-text/metamail/files/mm-2.7-glibc.patch deleted file mode 100644 index eb76c7d5f435..000000000000 --- a/app-text/metamail/files/mm-2.7-glibc.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- mm2.7/src/metamail/metamail.c.ewt Mon Aug 26 17:16:59 1996 -+++ mm2.7/src/metamail/metamail.c Mon Aug 26 17:17:12 1996 -@@ -48,6 +48,7 @@ - #ifndef AMIGA - #ifdef SYSV - #include <termio.h> -+#include <sys/ioctl.h> - #include <unistd.h> - #else /* SYSV */ - #include <sgtty.h> diff --git a/app-text/metamail/files/mm-2.7-linux.patch b/app-text/metamail/files/mm-2.7-linux.patch deleted file mode 100644 index 54ac04200a77..000000000000 --- a/app-text/metamail/files/mm-2.7-linux.patch +++ /dev/null @@ -1,17 +0,0 @@ ---- mm2.7/src/config.h.linux Sun Jun 18 21:59:38 2000 -+++ mm2.7/src/config.h Sun Jun 18 21:59:10 2000 -@@ -100,9 +100,11 @@ - #endif - - #ifdef SYSV --#define killpg(a, b) kill(-(a), (b)) --#define bcopy(a, b, c) memcpy(b, a, c) --#define bzero(a, b) memset(a, 0, b) -+#ifndef linux -+# define killpg(a, b) kill(-(a), (b)) -+# define bcopy(a, b, c) memcpy(b, a, c) -+# define bzero(a, b) memset(a, 0, b) -+#endif - #define bcmp memcmp - #define index strchr - #define rindex strrchr diff --git a/app-text/metamail/files/mm-2.7-make.patch b/app-text/metamail/files/mm-2.7-make.patch deleted file mode 100644 index 749b175ab724..000000000000 --- a/app-text/metamail/files/mm-2.7-make.patch +++ /dev/null @@ -1,76 +0,0 @@ ---- mm2.7/src/Makefile.orig Wed Jan 26 12:32:33 1994 -+++ mm2.7/src/Makefile Wed Oct 11 21:44:12 1995 -@@ -38,7 +38,7 @@ - - STATICFLAG=FOOBAR${HOST_ARCH} - --CFLAGS = -g -I. ${$(STATICFLAG)} -+CFLAGS = $(RPM_OPT_FLAGS) -I. -DLINUX ${$(STATICFLAG)} - # The following is better if you want to make sure you run with SYSV defined - # CFLAGS = -g -I. ${$(STATICFLAG)} -DSYSV - # Also, for SGI Irix, compile in K&R mode -@@ -75,7 +75,7 @@ - INSTALL = install -c -s - - # Root of installation tree --INSTROOT = /usr/local -+INSTROOT = /usr - # - # This is where binaries should be copied - LOCALBINDIR = ${INSTROOT}/bin -@@ -91,7 +91,7 @@ - FONTSUFFIX=pcf - - # This is where the mailcap file should be put --MAILCAPDIR = ${INSTROOT}/etc -+MAILCAPDIR = /etc - - # This helps with the "for" constructs below on some platforms: - SHELL=/bin/sh -@@ -145,7 +145,7 @@ - echo "installing man page $$target";\ - ${CP} $$file $$target; \ - done) -- @echo "Renaming old mailcap file to $(MAILCAPDIR)/mailcap.old -+ @echo "Renaming old mailcap file to $(MAILCAPDIR)/mailcap.old" - -mv $(MAILCAPDIR)/mailcap $(MAILCAPDIR)/mailcap.old - @echo "installing file $(MAILCAPDIR)/mailcap" - ${CP} mailcap $(MAILCAPDIR) ---- mm2.7/src/Makefile.don Thu Feb 22 14:12:21 1996 -+++ mm2.7/src/Makefile Thu Feb 22 14:12:54 1996 -@@ -145,10 +145,6 @@ - echo "installing man page $$target";\ - ${CP} $$file $$target; \ - done) -- @echo "Renaming old mailcap file to $(MAILCAPDIR)/mailcap.old" -- -mv $(MAILCAPDIR)/mailcap $(MAILCAPDIR)/mailcap.old -- @echo "installing file $(MAILCAPDIR)/mailcap" -- ${CP} mailcap $(MAILCAPDIR) - - uninstall-all: - @(cd bin; \ -@@ -172,8 +168,6 @@ - echo "rm-ing man page $$target";\ - ${RM} $$target; \ - done) -- @echo "rm-ing file $(MAILCAPDIR)/mailcap" -- @${RM} $(MAILCAPDIR)/mailcap - - clean: - -${RM} -rf *.BAK ---- mm2.7/src/Makefile.don Thu Feb 22 14:19:05 1996 -+++ mm2.7/src/Makefile Thu Feb 22 14:19:27 1996 -@@ -138,13 +138,6 @@ - echo "installing man page $$target";\ - ${CP} $$file $$target; \ - done) -- @(cd man; \ -- for file in *.4; \ -- do \ -- target=$(MAN4DIR)/`basename $$file .4`.$(MAN4EXT); \ -- echo "installing man page $$target";\ -- ${CP} $$file $$target; \ -- done) - - uninstall-all: - @(cd bin; \ diff --git a/app-text/metamail/files/mm-2.7-ohnonotagain.patch b/app-text/metamail/files/mm-2.7-ohnonotagain.patch deleted file mode 100644 index 13a75a98b257..000000000000 --- a/app-text/metamail/files/mm-2.7-ohnonotagain.patch +++ /dev/null @@ -1,1794 +0,0 @@ -diff -d -r -u -P mm2.7.orig/src/bin/audiocompose mm2.7/src/bin/audiocompose ---- mm2.7.orig/src/bin/audiocompose Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/audiocompose Sat Jun 20 14:41:16 1998 -@@ -28,8 +28,8 @@ - set dev=/dev/audio - endif - --set audiofile=$1 --if (-e $audiofile && ! -z $audiofile) goto whatnext -+set audiofile="$1" -+if (-e "$audiofile" && ! -z "$audiofile") goto whatnext - - record: - echo -n "Press RETURN when you are ready to start recording: " -@@ -38,13 +38,22 @@ - # THIS IS UNBELIEVABLY GRUBBY - onintr cleanup - if (! $?RECORD_AUDIO) then -- (/bin/cat < $dev > $audiofile) & -+ (/bin/cat < $dev > "$audiofile") & - else -- ($RECORD_AUDIO > $audiofile) & -+ ($RECORD_AUDIO > "$audiofile") & - endif --jobs -l > ${METAMAIL_TMPDIR}/AUDCAT.$$ --set foo=`/bin/cat ${METAMAIL_TMPDIR}/AUDCAT.$$` --/bin/rm ${METAMAIL_TMPDIR}/AUDCAT.$$ -+# Generate temporary file name: -+if ( -x /bin/mktemp ) then -+ set TmpAudCat=`/bin/mktemp ${METAMAIL_TMPDIR}/AUDCAT.XXXXXXX` || exit 1 -+else if ( -x /usr/bin/mktemp ) then -+ set TmpAudCat=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/AUDCAT.XXXXXXX` || exit 1 -+else -+ set TmpAudCat=${METAMAIL_TMPDIR}/AUDCAT.$$ -+ rm -rf $TmpAudCat -+endif -+jobs -l > $TmpAudCat -+set foo=`/bin/cat $TmpAudCat` -+/bin/rm $TmpAudCat - set PID=$foo[2] - echo -n "press RETURN when you are done recording: " - set foo=$< -@@ -63,7 +72,7 @@ - set which = $< - switch ("$which") - case 1: -- cat $audiofile > $dev -+ cat "$audiofile" > $dev - breaksw - case 2: - goto record -diff -d -r -u -P mm2.7.orig/src/bin/audiosend mm2.7/src/bin/audiosend ---- mm2.7.orig/src/bin/audiosend Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/audiosend Sat Jun 20 14:42:48 1998 -@@ -29,7 +29,7 @@ - endif - - if ( $#argv == 1 ) then -- set to = $1 -+ set to = "$1" - else - echo -n "To: " - set to = $< -@@ -43,8 +43,23 @@ - echo -n "Press RETURN when you are ready to start recording: " - set foo = $< - --set fname = ${METAMAIL_TMPDIR}/audio-out.$$ --set fnameraw = ${METAMAIL_TMPDIR}/audio-raw.$$ -+# Generate work file names: -+if ( -x /bin/mktemp ) then -+ set fname=`/bin/mktemp ${METAMAIL_TMPDIR}/audio-out.XXXXXXX` || exit 1 -+else if ( -x /usr/bin/mktemp ) then -+ set fname=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/audio-out.XXXXXXX` || exit 1 -+else -+ set fname = ${METAMAIL_TMPDIR}/audio-out.$$ -+ rm -rf $fname -+endif -+if ( -x /bin/mktemp ) then -+ set fnameraw=`/bin/mktemp ${METAMAIL_TMPDIR}/audio-raw.XXXXXXX` || exit 1 -+else if ( -x /usr/bin/mktemp ) then -+ set fnameraw=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/audio-raw.XXXXXXX` || exit 1 -+else -+ set fnameraw = ${METAMAIL_TMPDIR}/audio-raw.$$ -+ rm -rf $fnameraw -+endif - - echo "To: " "$to" > $fname - echo "Subject: " "$subject" >> $fname -@@ -60,9 +75,18 @@ - else - ($RECORD_AUDIO > $fnameraw) & - endif --jobs -l > ${METAMAIL_TMPDIR}/AUDCAT.$$ --set foo=`/bin/cat ${METAMAIL_TMPDIR}/AUDCAT.$$` --/bin/rm ${METAMAIL_TMPDIR}/AUDCAT.$$ -+# Generate temporary file name: -+if ( -x /bin/mktemp ) then -+ set TmpAudCat=`/bin/mktemp ${METAMAIL_TMPDIR}/AUDCAT.XXXXXXX` || exit 1 -+else if ( -x /usr/bin/mktemp ) then -+ set TmpAudCat=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/AUDCAT.XXXXXXX` || exit 1 -+else -+ set TmpAudCat=${METAMAIL_TMPDIR}/AUDCAT.$$ -+ rm -rf $TmpAudCat -+endif -+jobs -l > $TmpAudCat -+set foo=`/bin/cat $TmpAudCat` -+/bin/rm $TmpAudCat - set PID=$foo[2] - echo -n "press RETURN when you are done recording: " - set foo=$< -@@ -86,7 +110,7 @@ - switch ("$which") - case 1: - echo -n "Sending mail, please wait... " -- /usr/lib/sendmail $to $cc < $fname -+ /usr/lib/sendmail "$to" "$cc" < $fname - if (! $status) then - echo "Done." - rm $fname -diff -d -r -u -P mm2.7.orig/src/bin/extcompose mm2.7/src/bin/extcompose ---- mm2.7.orig/src/bin/extcompose Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/extcompose Sat Jun 20 14:47:19 1998 -@@ -6,7 +6,7 @@ - echo "Usage: extcompose output-file-name" - exit 1 - endif --set OUTFNAME=$1 -+set OUTFNAME="$1" - - chooseaccesstype: - echo "" -@@ -19,21 +19,21 @@ - echo "" - echo -n "Please enter a number from 1 to 5: " - set ans=$< --if ($ans == 1) then -+if ("$ans" == 1) then - set accesstype=local-file --else if ($ans == 2) then -+else if ("$ans" == 2) then - set accesstype=afs --else if ($ans == 3) then -+else if ("$ans" == 3) then - set accesstype=anon-ftp --else if ($ans == 4) then -+else if ("$ans" == 4) then - set accesstype=ftp --else if ($ans == 5) then -+else if ("$ans" == 5) then - set accesstype=mail-server - else - echo "That is NOT one of your choices." - goto chooseaccesstype - endif --if ($accesstype == "ftp" || $accesstype == "anon-ftp") then -+if ("$accesstype" == "ftp" || "$accesstype" == "anon-ftp") then - echo -n "Enter the full Internet domain name of the FTP site: " - set site=$< - echo -n "Enter the name of the directory containing the file (RETURN for top-level): " -@@ -42,27 +42,27 @@ - set name = $< - echo -n "Enter the transfer mode (type 'image' for binary data, RETURN otherwise): " - set mode = $< -- if ($mode == "") set mode=ascii -- echo "Content-type: message/external-body; access-type=$accesstype; name="\"$name\"\; > $OUTFNAME -- echo -n " site="\"$site\" >> $OUTFNAME -- if ($directory != "") echo -n "; directory="\"$directory\">> $OUTFNAME -- if ($mode != "") echo -n "; mode="\"$mode\">> $OUTFNAME -- echo "">> $OUTFNAME --else if ($accesstype == "local-file" || $accesstype == "afs") then -+ if ("$mode" == "") set mode=ascii -+ echo "Content-type: message/external-body; access-type=$accesstype; name="\"$name\"\; > "$OUTFNAME" -+ echo -n " site="\"$site\" >> "$OUTFNAME" -+ if ("$directory" != "") echo -n "; directory="\"$directory\">> "$OUTFNAME" -+ if ("$mode" != "") echo -n "; mode="\"$mode\">> "$OUTFNAME" -+ echo "">> "$OUTFNAME" -+else if ("$accesstype" == "local-file" || "$accesstype" == "afs") then - fname: - echo -n "Enter the full path name for the file: " - set name = $< -- if (! -e $name) then -+ if (! -e "$name") then - echo "The file $name does not seem to exist." - goto fname - endif -- echo "Content-type: message/external-body; access-type=$accesstype; name="\"$name\"> $OUTFNAME --else if ($accesstype == "mail-server") then -+ echo "Content-type: message/external-body; access-type=$accesstype; name="\"$name\"> "$OUTFNAME" -+else if ("$accesstype" == "mail-server") then - echo -n "Enter the full email address for the mailserver: " - set server=$< -- echo "Content-type: message/external-body; access-type=$accesstype; server="\"$server\"> $OUTFNAME -+ echo "Content-type: message/external-body; access-type=$accesstype; server="\"$server\"> "$OUTFNAME" - else -- echo accesstype $accesstype not yet implemented -+ echo accesstype "$accesstype" not yet implemented - goto chooseaccesstype - endif - -@@ -92,12 +92,12 @@ - echo "That is not one of your choices." - goto getcenc - endsw --echo "" >> $OUTFNAME --echo "Content-type: " $ctype >> $OUTFNAME --if ($cenc != "") echo "Content-transfer-encoding: " $cenc >> $OUTFNAME --echo "" >> $OUTFNAME --if ($accesstype == "mail-server") then -+echo "" >> "$OUTFNAME" -+echo "Content-type: " "$ctype" >> "$OUTFNAME" -+if ("$cenc" != "") echo "Content-transfer-encoding: " "$cenc" >> "$OUTFNAME" -+echo "" >> "$OUTFNAME" -+if ("$accesstype" == "mail-server") then - echo "Please enter all the data to be sent to the mailserver in the message body, " - echo "ending with ^D or your usual end-of-data character:" -- cat >> $OUTFNAME -+ cat >> "$OUTFNAME" - endif -diff -d -r -u -P mm2.7.orig/src/bin/getfilename mm2.7/src/bin/getfilename ---- mm2.7.orig/src/bin/getfilename Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/getfilename Sat Jun 20 14:47:43 1998 -@@ -8,9 +8,9 @@ - echo Aborted - exit -1 - endif --if (! -r $fnam) then -+if (! -r "$fnam") then - echo No such file - exit -1 - endif --cp $fnam $2 -+cp "$fnam" "$2" - exit 0 -diff -d -r -u -P mm2.7.orig/src/bin/mailserver mm2.7/src/bin/mailserver ---- mm2.7.orig/src/bin/mailserver Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/mailserver Sat Jun 20 23:01:33 1998 -@@ -28,20 +28,28 @@ - rehash - set FromName="" - set Subject="" --set TmpFile=/tmp/ms.$$ -+# Generate temporary file name: -+if ( -x /bin/mktemp ) then -+ set TmpFile=`/bin/mktemp /tmp/ms.XXXXXXX` || exit 1 -+else if ( -x /usr/bin/mktemp ) then -+ set TmpFile=`/usr/bin/mktemp /tmp/ms.XXXXXXX` || exit 1 -+else -+ set TmpFile=/tmp/ms.$$ -+ rm -rf $TmpFile -+endif - set FOORAW=$< - while ("$FOORAW" != "") - set FOO=(` echo "$FOORAW" | tr "[" "x"`) - set BAR=($FOO) --set BARLC=(`echo $FOO | tr A-Z a-z`) --if ($BARLC[1] == "from:") then -+set BARLC=(`echo "$FOO" | tr A-Z a-z`) -+if ("$BARLC[1]" == "from:") then - if ("$FromName" == "") then -- set FromName = ($BAR[2-]) -+ set FromName = ("$BAR[2-]") - endif - else if ($BARLC[1] == "reply-to:") then -- set FromName = ($BAR[2-]) -+ set FromName = ("$BAR[2-]") - else if ($BARLC[1] == "subject:") then -- set Subject = ($BAR[2-]) -+ set Subject = ("$BAR[2-]") - endif - set FOORAW=$< - end -@@ -52,10 +60,10 @@ - endif - - if ("$FromName" == "") then -- cat > $TmpFile <<! --From: $LOCALADDR@`hostname` --To: $MAINTAINER --Subject: $Subject -+ echo From: "$LOCALADDR"@`hostname` > $TmpFile -+ echo To: "$MAINTAINER" >> $TmpFile -+ echo Subject: "$Subject" >> $TmpFile -+ cat >> $TmpFile <<! - - The metamail mailserver script, installed locally as $LOCALADDR,
has received a request without any reply address. - -@@ -68,18 +76,18 @@ - probably run in some circumstance other than mail delivery. - -------------------- - ! -- cat $TmpFile - | /usr/lib/sendmail $MAINTAINER -+ cat $TmpFile - | /usr/lib/sendmail "$MAINTAINER" - # Takes the rest of the message from standard input - rm $TmpFile - exit 0 - endif - --set danger=`echo $Subject | fgrep ..` --if ($danger != "") then -- cat > $TmpFile <<! --From: $LOCALADDR@`hostname` --To: $FromName --Subject: Re: $Subject -+set danger=`echo "$Subject" | fgrep ..` -+if ("$danger" != "") then -+ echo From: "$LOCALADDR"@`hostname` > $TmpFile -+ echo To: "$FromName" >> $TmpFile -+ echo Subject: Re: "$Subject" >> $TmpFile -+ cat >> $TmpFile <<! - - For security reasons, this mailserver automatically rejects all requests - that contain ".." in the path name. -@@ -93,60 +101,64 @@ - - cd $ROOTDIR - if (! -e "$Subject") then -- cat > $TmpFile <<! --From: $LOCALADDR@`hostname` --To: $FromName --Subject: Re: $Subject -- --You recently sent mail to this mail-server requesting the file: -- $Subject -- --That file does not exist, so your request could not be met. -- --Here is a list of the currently available files: ---------------------------------- --! -+ # We use a bunch of echo statements rather than a here-document -+ # so that we can be sure to quote all of our variables properly. -+ echo From: "$LOCALADDR"@`hostname` > $TmpFile -+ echo To: "$FromName" >> $TmpFile -+ echo Subject: Re: "$Subject" >> $TmpFile -+ echo "" >> $TmpFile -+ echo "You recently sent mail to this mail-server requesting the file:" >> $TmpFile -+ echo " $Subject" >> $TmpFile -+ echo "" >> $TmpFile -+ echo "That file does not exist, so your request could not be met." >> $TmpFile -+ echo "" >> $TmpFile -+ echo "Here is a list of the currently available files:" >> $TmpFile -+ echo "--------------------------------" >> $TmpFile - ls -R >> $TmpFile -+ echo "" >> $TmpFile - /usr/lib/sendmail -t < $TmpFile - rm $TmpFile - exit 0 - endif - --if (-e ${Subject}.ct) then -- set ct=`cat ${Subject}.ct` -+if (-e "${Subject}.ct") then -+ set ct=`cat "${Subject}.ct"` - else - set ct="application/octet-stream" - endif - - metasend -b -t "$FromName" -f "$Subject" -m "$ct" -s "Re: $Subject" - if ($status != 0) then -- cat > $TmpFile <<! --From: $LOCALADDR@`hostname` --To: $FromName --Subject: Re: $Subject -- --You recently sent mail to this mail-server requestion the file: -- $Subject -- --An unanticipated error apparently precluded delivery of the file. --Please accept our apologies. -- --Command failed: -- metasend -b -t "$FromName" -f "$Subject" -m "$ct" -s "Re: $Subject" -- --! -+ # We use a bunch of echo statements rather than a here-document -+ # so that we can be sure to quote all of our variables properly. -+ echo From: "$LOCALADDR"@`hostname` > $TmpFile -+ echo To: "$FromName" >> $TmpFile -+ echo Subject: Re: "$Subject" >> $TmpFile -+ echo "" >> $TmpFile -+ echo "You recently sent mail to this mail-server requestion the file:" >> $TmpFile -+ echo " $Subject" >> $TmpFile -+ echo "" >> $TmpFile -+ echo "An unanticipated error apparently precluded delivery of the file." >> $TmpFile -+ echo "Please accept our apologies." >> $TmpFile -+ echo "" >> $TmpFile -+ echo "Command failed:" >> $TmpFile -+ echo " metasend -b -t $FromName -f $Subject -m $ct -s Re: $Subject" >> $TmpFile -+ echo "" >> $TmpFile - /usr/lib/sendmail -t < $TmpFile - rm $TmpFile - exit 0 - endif - - if ("$LOGADDR" != "") then -- /usr/lib/sendmail -t <<! --From: ${LOCALADDR}@`hostname` --To: $LOGADDR --Subject: Autosend delivery report -+ echo From: "${LOCALADDR}"@`hostname` > $TmpFile -+ echo To: "$LOGADDR" >> $TmpFile -+ echo Subject: Autosend delivery report >> $TmpFile -+ echo "" >> $TmpFile -+ echo The file: "$Subject" >> $TmpFile -+ echo was sent to: "$FromName" >> $TmpFile -+ echo "" >> $TmpFile -+ /usr/lib/sendmail -t < $TmpFile -+endif - --The file: $Subject --was sent to: $FromName --! -+rm -f $TmpFile - exit 0 -diff -d -r -u -P mm2.7.orig/src/bin/metasend mm2.7/src/bin/metasend ---- mm2.7.orig/src/bin/metasend Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/metasend Sat Jun 20 14:59:30 1998 -@@ -45,7 +45,7 @@ - echo "-S requires a following argument, the SPLIT threshhold" - exit -1 - endif -- set splitsize=$1 -+ set splitsize="$1" - shift - breaksw - case "-b": -@@ -68,7 +68,7 @@ - echo "-i requires a following argument, the Content-ID value" - exit -1 - endif -- set cid=$1 -+ set cid="$1" - shift - breaksw - case "-I": -@@ -77,7 +77,7 @@ - echo "-I requires a following argument, the multipart Content-ID value" - exit -1 - endif -- set multicid=$1 -+ set multicid="$1" - shift - breaksw - case "-s": -@@ -122,12 +122,12 @@ - echo "-e requires a following argument, the ENCODING value" - exit -1 - endif -- set encode=$1 -- if ($encode == "base64") then -+ set encode="$1" -+ if ("$encode" == "base64") then - set encodingprog = "mimencode -b" -- else if ($encode == "x-uue") then -+ else if ("$encode" == "x-uue") then - set encodingprog = "uuencode mail-body" -- else if ($encode == "7bit") then -+ else if ("$encode" == "7bit") then - set encodingprog = cat - else - set encodingprog = "mimencode -q" -@@ -141,9 +141,9 @@ - echo "-f requires a following argument, the DATA FILE" - exit -1 - endif -- set datafile=$1 -- if (! -e $datafile) then -- echo The file $datafile does not exist. -+ set datafile="$1" -+ if (! -e "$datafile") then -+ echo The file "$datafile" does not exist. - exit -1 - endif - shift -@@ -154,10 +154,10 @@ - echo "-m requires a following argument, the MIME CONTENT-TYPE" - exit -1 - endif --# set ctyperaw = $1 --# set ctype=`echo $ctyperaw | tr \" \'` -+# set ctyperaw = "$1" -+# set ctype=`echo "$ctyperaw" | tr \" \'` - set ctype = "$1" -- if (`echo $ctype | grep /` == "") then -+ if (`echo "$ctype" | grep /` == "") then - echo "Invalid content-type specified" - exit -1 - endif -@@ -228,11 +228,11 @@ - endif - endif - set ctype${multipart} = "$ctype" -- set datafile${multipart} = $datafile -- set encode${multipart} = $encode -+ set datafile${multipart} = "$datafile" -+ set encode${multipart} = "$encode" - set cdescrip${multipart} = "$cdescrip" - set cid${multipart} = "$cid" -- set isentity${multipart} = $isentity -+ set isentity${multipart} = "$isentity" - set encodingprog${multipart} = "$encodingprog" - unset ctype - unset datafile -@@ -247,11 +247,11 @@ - shift - breaksw - default: -- echo UNRECOGNIZED METASEND OPTION: $1 -+ echo UNRECOGNIZED METASEND OPTION: "$1" - exit -1 - endsw - end --if ($batchmode == 0) then -+if ("$batchmode" == 0) then - if (! $?to) then - echo -n "To: " - set to = $< -@@ -271,18 +271,18 @@ - # set ctype=`echo $ctyperaw | tr \" \'` - set ctype = "$<" - endif -- if (`echo $ctype | grep /` == "") then -+ if (`echo "$ctype" | grep /` == "") then - echo "Invalid content-type specified" - unset ctype - goto anotherpart - endif --# if ($ctype != $ctyperaw) echo Double quotes not allowed, using $ctype -+# if ("$ctype" != "$ctyperaw") echo Double quotes not allowed, using "$ctype" - if (! $?datafile) then - getfile: - echo -n "Name of file containing $ctype data: " - set datafile = $< -- if (! -e $datafile) then -- echo The file $datafile does not exist. -+ if (! -e "$datafile") then -+ echo The file "$datafile" does not exist. - goto getfile - endif - endif -@@ -320,12 +320,12 @@ - set ans=$< - if ("$ans" =~ y*) then - set ctype${multipart} = "$ctype" -- set datafile${multipart} = $datafile -- set encode${multipart} = $encode -+ set datafile${multipart} = "$datafile" -+ set encode${multipart} = "$encode" - set encodingprog${multipart} = "$encodingprog" - set cdescrip${multipart} = "$cdescrip" - set cid${multipart} = "$cid" -- set isentity${multipart} = $isentity -+ set isentity${multipart} = "$isentity" - set cdescrip = "An object packed by metasend" - set isentity=0 - unset ctype -@@ -339,7 +339,7 @@ - goto anotherpart - endif - else -- if ($outputfile == "") then -+ if ("$outputfile" == "") then - if (! $?to || ! $?subject || ! $?ctype || ! $?datafile) then - echo metasend: in batch mode, if output is not directed to a file,-t, -s, -f, and -m are all required - exit -1 -@@ -359,12 +359,12 @@ - exit -1 - endif - endif -- if (! -e $datafile) then -- echo metasend: The file $datafile does not exist -+ if (! -e "$datafile") then -+ echo metasend: The file "$datafile" does not exist - exit -1 - endif - # if (! $?cc) set cc="" --# if ($ctype != $ctyperaw) echo Double quotes not allowed, using $ctype -+# if ("$ctype" != "$ctyperaw") echo Double quotes not allowed, using "$ctype" - if (! $?encode) then - if ("$ctype" =~ text*) then - set encodingprog = "mimencode -q" -@@ -373,11 +373,11 @@ - set encodingprog = "mimencode -b" - set encode = base64 - endif -- else if ($encode == "base64") then -+ else if ("$encode" == "base64") then - set encodingprog = "mimencode -b" -- else if ($encode == "x-uue") then -+ else if ("$encode" == "x-uue") then - set encodingprog = "uuencode mail-body" -- else if ($encode == "7bit") then -+ else if ("$encode" == "7bit") then - set encodingprog = cat - else - set encodingprog = "mimencode -q" -@@ -395,14 +395,22 @@ - endif - endif - set ctype${multipart} = "$ctype" --set datafile${multipart} = $datafile --set encode${multipart} = $encode -+set datafile${multipart} = "$datafile" -+set encode${multipart} = "$encode" - set cdescrip${multipart} = "$cdescrip" - set cid${multipart} = "$cid" --set isentity${multipart} = $isentity -+set isentity${multipart} = "$isentity" - set encodingprog${multipart} = "$encodingprog" - --set fname = ${METAMAIL_TMPDIR}/metasend.$$ -+# Generate file name: -+if ( -x /bin/mktemp ) then -+ set fname=`/bin/mktemp ${METAMAIL_TMPDIR}/metasend.XXXXXXX` || exit 1 -+else if ( -x /usr/bin/mktemp ) then -+ set fname=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/metasend.XXXXXXX` || exit 1 -+else -+ set fname=${METAMAIL_TMPDIR}/metasend.$$ -+ rm -rf $fname -+endif - echo "MIME-Version: 1.0" > $fname - if ($?to) then - echo "To: " "$to" >> $fname -@@ -429,17 +437,26 @@ - echo " boundary="\"$boundary\" >> $fname - echo "" >> $fname - if ($?preamblefile) then -- cat $preamblefile >> $fname -+ cat "$preamblefile" >> $fname - else - echo "This is a multimedia message in MIME format. If you are reading this" >> $fname - echo "prefix, your mail reader does not understand MIME. You may wish" >> $fname - echo "to look into upgrading to a newer version of your mail reader." >> $fname - endif - set i=1 -- set junkfile=${METAMAIL_TMPDIR}/mmjunk.$$ -- while ($multipart >= $i) -+ -+ # Generate temporary file name: -+ if ( -x /bin/mktemp ) then -+ set junkfile=`/bin/mktemp ${METAMAIL_TMPDIR}/mmjunk.XXXXXXX` || exit 1 -+ else if ( -x /usr/bin/mktemp ) then -+ set junkfile=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/mmjunk.XXXXXXX` || exit 1 -+ else -+ set junkfile=${METAMAIL_TMPDIR}/mmjunk.$$ -+ rm -rf $junkfile -+ endif -+ while ("$multipart" >= $i) - echo "" >> $fname -- echo --$boundary >> $fname -+ echo --"$boundary" >> $fname - echo set isentity=\$isentity$i > $junkfile - source $junkfile - if (! $isentity) then -@@ -463,27 +480,27 @@ - end - rm $junkfile - echo "" >> $fname -- echo --${boundary}-- >> $fname -+ echo --"${boundary}"-- >> $fname - echo "" >> $fname - else - if (! $isentity) then - echo "Content-ID: $cid" >> $fname -- echo "Content-type: " $ctype >> $fname -- echo "Content-Description: " $cdescrip >> $fname -- echo "Content-Transfer-Encoding: " $encode >> $fname -+ echo "Content-type: " "$ctype" >> $fname -+ echo "Content-Description: " "$cdescrip" >> $fname -+ echo "Content-Transfer-Encoding: " "$encode" >> $fname - endif - echo "" >> $fname -- $encodingprog < $datafile >> $fname -+ $encodingprog < "$datafile" >> $fname - # Ensure last line has trailing carriage return - echo "" >> $fname - endif --if ($outputfile == "") then -- if ($batchmode == 0) echo -n "Delivering mail, please wait... " -- splitmail -s $splitsize -d $fname -+if ("$outputfile" == "") then -+ if ("$batchmode" == 0) echo -n "Delivering mail, please wait... " -+ splitmail -s "$splitsize" -d "$fname" - if (! $status) then -- if ($batchmode == 0) echo "Mail delivery apparently succeeded." -+ if ("$batchmode" == 0) echo "Mail delivery apparently succeeded." - rm $fname -- else if ($MustDelete == 1) then -+ else if ("$MustDelete" == 1) then - echo Mail delivery failed - rm $fname - exit -1 -@@ -492,7 +509,7 @@ - exit -1 - endif - else -- mv $fname $outputfile -+ mv $fname "$outputfile" - if ($status) exit -1 - endif - exit 0 -diff -d -r -u -P mm2.7.orig/src/bin/patch-metamail mm2.7/src/bin/patch-metamail ---- mm2.7.orig/src/bin/patch-metamail Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/patch-metamail Sat Jun 20 23:18:20 1998 -@@ -5,40 +5,53 @@ - set DIRNAME=pub/nsb - set PREFIX="mm.patch." - -+if (! $?METAMAIL_TMPDIR) then -+ set METAMAIL_TMPDIR=/tmp -+endif -+ - if ($#argv < 2 || $#argv > 5) then - echo Usage: patch-metamail source-tree-root patch-number [hostname [dirname [prefix]]] - exit -1 - endif - --set TREEROOT=$1 --set PATCHNUMBER=$2 --if ($#argv > 2) set HOSTNAME=$3 --if ($#argv > 3) set DIRNAME=$4 --if ($#argv > 4) set PREFIX=$5 -+set TREEROOT="$1" -+set PATCHNUMBER="$2" -+if ($#argv > 2) set HOSTNAME="$3" -+if ($#argv > 3) set DIRNAME="$4" -+if ($#argv > 4) set PREFIX="$5" - - echo WARNING: This program, if allowed to do so, will attempt to - echo install a PATCH file for your metamail sources which are rooted --echo in the directory $TREEROOT. -+echo in the directory "$TREEROOT". - echo "" - echo It will use a patch file that it retrieves via anonymous ftp --echo from the host $HOSTNAME, in the directory $DIRNAME, --echo with filenames starting with ${PREFIX}. -+echo from the host "$HOSTNAME", in the directory "$DIRNAME", -+echo with filenames starting with "${PREFIX}". - echo "" - echo -n "Do you want to install the patch in directory $TREEROOT [y/n] ? " - set ans=$< --if ($ans == "y" || $ans == "Y") then -- cd $TREEROOT -+if ("$ans" == "y" || "$ans" == "Y") then -+ cd "$TREEROOT" - set ident=`whoami`@`hostname` -- echo Using anonymous ftp with password $ident -- ftp -n <<! --open $HOSTNAME --user anonymous $ident --cd $DIRNAME --binary --get ${PREFIX}${PATCHNUMBER} --quit --! -- patch -p < ${PREFIX}${PATCHNUMBER} -+ # Generate temporary file name: -+ if ( -x /bin/mktemp ) then -+ set TmpFtp=`/bin/mktemp ${METAMAIL_TMPDIR}/mm.ftp.XXXXXXX` || exit 1 -+ else if ( -x /usr/bin/mktemp ) then -+ set TmpFtp=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/mm.ftp.XXXXXXX` || exit 1 -+ else -+ set TmpFtp=${METAMAIL_TMPDIR}/mm.ftp.$$ -+ rm -rf $TmpFtp -+ endif -+ echo open "$HOSTNAME" > $TmpFtp -+ echo user anonymous "$ident" >> $TmpFtp -+ echo cd "$DIRNAME" >> $TmpFtp -+ echo binary >> $TmpFtp -+ echo get "${PREFIX}${PATCHNUMBER}" >> $TmpFtp -+ echo quit >> $TmpFtp -+ echo Using anonymous ftp with password "$ident" -+ ftp -n < $TmpFtp -+ rm -f $TmpFtp -+ patch -p < "${PREFIX}${PATCHNUMBER}" - else - echo Patch not installed - endif -diff -d -r -u -P mm2.7.orig/src/bin/rcvAppleSingle mm2.7/src/bin/rcvAppleSingle ---- mm2.7.orig/src/bin/rcvAppleSingle Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/rcvAppleSingle Sat Jun 20 14:08:30 1998 -@@ -13,7 +13,7 @@ - # Written by Patrik Faltstrom, paf@nada.kth.se, may 1993 - # - --FILENAME=$1 -+FILENAME="$1" - - # - # If $AFPDIR environment variable is set, all Macintosh filenames -@@ -31,12 +31,12 @@ - exit 1 - fi - --echo $NAME | grep '^/' > /dev/null -+echo "$NAME" | grep '^/' > /dev/null - if [ $? = 1 ]; then -- NAME=$AFPDIR/$NAME -+ NAME="$AFPDIR/$NAME" - fi - --cvt2cap $FILENAME $NAME -+cvt2cap "$FILENAME" "$NAME" - echo "Saved AppleMacintosh file as $NAME" - exit 0 - -diff -d -r -u -P mm2.7.orig/src/bin/showaudio mm2.7/src/bin/showaudio ---- mm2.7.orig/src/bin/showaudio Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/showaudio Sat Jun 20 15:01:55 1998 -@@ -33,7 +33,7 @@ - set ORG="Bellcore" - set STDINPUT=0 - if ("$1" == "-p") then -- set AUDIOPHONE=$2 -+ set AUDIOPHONE="$2" - shift - shift - endif -@@ -73,13 +73,13 @@ - echo "" - echo -n "Which do you prefer (1 or 2)? " - set ans=$< -- if ($ans == 2) then -+ if ("$ans" == 2) then - echo "OK, we'll use the telephone..." - set AUDIOPHONEFORCE=1 - echo "In the future, you can avoid this question by setting the environment variable" - echo "AUDIOPHONEFORCE to 1" - goto playphone -- else if ($ans == 1) then -+ else if ("$ans" == 1) then - echo "OK, Attempting to play the audio using your computer's speaker.." - set AUDIOSPEAKERFORCE=1 - echo "In the future, you can avoid this question by setting the environment variable" -@@ -93,8 +93,8 @@ - set audiohost=$thishost - if ($?DISPLAY) then - set audiohost=`echo $DISPLAY | sed -e 's/:.*//'` -- if ($audiohost == "unix") set audiohost=$thishost -- if ($audiohost == "") set audiohost=$thishost -+ if ("$audiohost" == "unix") set audiohost=$thishost -+ if ("$audiohost" == "") set audiohost=$thishost - endif - if ($?AUDIOHOST) then - set audiohost=$AUDIOHOST -@@ -127,9 +127,18 @@ - if ($#argv >= 1) then - exec /usr/sbin/sfplay -i mu-law chan 1 rate 8000 end $* - else -- cat > ${METAMAIL_TMPDIR}/audio.$$ -- /usr/sbin/sfplay -i mu-law chan 1 rate 8000 end ${METAMAIL_TMPDIR}/audio.$$ -- rm ${METAMAIL_TMPDIR}/audio.$$ -+ # Generate temporary file name: -+ if ( -x /bin/mktemp ) then -+ set TmpAudio=`/bin/mktemp ${METAMAIL_TMPDIR}/audio.XXXXXXX` || exit 1 -+ else if ( -x /usr/bin/mktemp ) then -+ set TmpAudio=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/audio.XXXXXXX` || exit 1 -+ else -+ set TmpAudio=${METAMAIL_TMPDIR}/audio.$$ -+ rm -rf $TmpAudio -+ endif -+ cat > $TmpAudio -+ /usr/sbin/sfplay -i mu-law chan 1 rate 8000 end $TmpAudio -+ rm $TmpAudio - exit 0 - endif - else if (-d /usr/sony) then -@@ -198,7 +207,15 @@ - echo "" - if (! $?MM_NOTTTY) set MM_NOTTTY=0 - if ($MM_NOTTTY == 1) then -- set fname=/tmp/mm.aud.$$ -+ # Generate unique file name: -+ if ( -x /bin/mktemp ) then -+ set fname=`/bin/mktemp /tmp/mm.aud.XXXXXXX` || exit 1 -+ else if ( -x /usr/bin/mktemp ) then -+ set fname=`/usr/bin/mktemp /tmp/mm.aud.XXXXXXX` || exit 1 -+ else -+ set fname=/tmp/mm.aud.$$ -+ rm -rf $fname -+ endif - else - echo -n "Do you want to write the audio out to a file [y] ? " - set ANS=$< -@@ -206,7 +223,7 @@ - echo -n "File name:" - set fname=$< - endif --cp $1 $fname --if ($status == 0) echo Wrote raw audio file: $fname -+cp "$1" "$fname" -+if ($status == 0) echo Wrote raw audio file: "$fname" - exit 0 - -diff -d -r -u -P mm2.7.orig/src/bin/showexternal mm2.7/src/bin/showexternal ---- mm2.7.orig/src/bin/showexternal Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/showexternal Sat Jun 20 23:20:49 1998 -@@ -40,14 +40,14 @@ - endsw - set bodyfile="$1" - set atype=`echo $2 | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` --set name=$3 -+set name="$3" - if ($#argv > 3) then - set site="$4" - else - set site="" - endif - if ($#argv > 4) then -- set dir=$5 -+ set dir="$5" - else - set dir="" - endif -@@ -62,10 +62,10 @@ - set server="" - endif - --if ("$server" == "" && $atype == "mail-server") then -+if ("$server" == "" && "$atype" == "mail-server") then - # Backward compatibility with some broken stuff -- set server=${name}@${site} -- echo WARNING -- old style mailserver syntax, using server $server -+ set server="${name}@${site}" -+ echo WARNING -- old style mailserver syntax, using server "$server" - endif - - set ctype="`grep -i content-type: $bodyfile | sed -e 's/............: //'`" -@@ -75,6 +75,10 @@ - set pass="" - set TMPDIR=${METAMAIL_TMPDIR}/XXXternal.$$ - mkdir $TMPDIR -+if ( $status != 0 ) then -+ echo Error creating temporary directory -+ exit 1 -+endif - pushd $TMPDIR - set NEWNAME="mm.ext.$$" - set NEEDSCONFIRMATION=1 -@@ -90,7 +94,16 @@ - echo automatically using the FTP protocol to a site on the network. - breaksw - case mail-server: -- cat > ${METAMAIL_TMPDIR}/ext.junk.$$ <<! -+ # Generate temporary file name: -+ if ( -x /bin/mktemp ) then -+ set TmpExtJunk=`/bin/mktemp ${METAMAIL_TMPDIR}/ext.junk.XXXXXXX` || exit 1 -+ else if ( -x /usr/bin/mktemp ) then -+ set TmpExtJunk=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/ext.junk.XXXXXXX` || exit 1 -+ else -+ set TmpExtJunk=${METAMAIL_TMPDIR}/ext.junk.$$ -+ rm -rf $TmpExtJunk -+ endif -+ cat > $TmpExtJunk <<! - This mail message contains a POINTER (reference) to data that is - not included in the message itself. Rather, the data can be retrieved - by sending a special mail message to a mail server on the network. -@@ -102,13 +115,13 @@ - This is the message that will be sent if you choose to go ahead and - retreive the external data: - --Subject: Automated Mail Server Request --To: ${server} -- - ! -- sed -e 1,/^\$/d < $bodyfile >> ${METAMAIL_TMPDIR}/ext.junk.$$ -- ${METAMAIL_PAGER} ${METAMAIL_TMPDIR}/ext.junk.$$ -- rm ${METAMAIL_TMPDIR}/ext.junk.$$ -+ echo Subject: Automated Mail Server Request >> $TmpExtJunk -+ echo To: "$server" >> $TmpExtJunk -+ echo "" >> $TmpExtJunk -+ sed -e 1,/^\$/d < $bodyfile >> $TmpExtJunk -+ ${METAMAIL_PAGER} $TmpExtJunk -+ rm $TmpExtJunk - breaksw - default: - # IGNORE ALL THE OTHERS -- AUTOMATIC FOR LOCAL-FILE, AFS. -@@ -157,17 +170,26 @@ - else - set MODECMD="type $mode" - endif -+ # Generate temporary file name: -+ if ( -x /bin/mktemp ) then -+ set TmpFtp=`/bin/mktemp ${METAMAIL_TMPDIR}/mm.ftp.XXXXXXX` || exit 1 -+ else if ( -x /usr/bin/mktemp ) then -+ set TmpFtp=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/mm.ftp.XXXXXXX` || exit 1 -+ else -+ set TmpFtp=${METAMAIL_TMPDIR}/mm.ftp.$$ -+ rm -rf $TmpFtp -+ endif -+ echo open "$site" > $TmpFtp -+ echo user "$username" "$pass" >> $TmpFtp -+ echo "$DIRCMD" >> $TmpFtp -+ echo "$MODECMD" >> $TmpFtp -+ echo get "$name" "$NEWNAME" >> $TmpFtp -+ echo quit >> $TmpFtp - echo OBTAINING MESSAGE BODY USING FTP -- echo SITE: $site USER $username -- $FTP -n <<! --open $site --user $username $pass --$DIRCMD --$MODECMD --get $name $NEWNAME --quit --! -- if (! -e $NEWNAME) then -+ echo SITE: "$site" USER "$username" -+ $FTP -n < $TmpFtp -+ rm -f $TmpFtp -+ if (! -e "$NEWNAME") then - echo FTP failed. - cd ${METAMAIL_TMPDIR} - rm -rf $TMPDIR -@@ -176,14 +198,14 @@ - breaksw - case afs: - case local-file: -- if (! -e $name) then -+ if (! -e "$name") then - echo local file not found - cd ${METAMAIL_TMPDIR} - rm -rf $TMPDIR - exit -1 - endif -- set NEWNAME=$name -- echo GETTING BODY FROM FILE NAMED: $NEWNAME -+ set NEWNAME="$name" # Note that this is not trusted data... -+ echo GETTING BODY FROM FILE NAMED: "$NEWNAME" - breaksw - case mail-server: # A very special case - if ("$bodyfile" == "") then -@@ -192,12 +214,12 @@ - rm -rf $TMPDIR - exit -1 - endif -- echo Subject: Automated Mail Server Request > $NEWNAME -- echo To: ${server} >> $NEWNAME -- echo "" >> $NEWNAME -- sed -e 1,/^\$/d < $bodyfile >> $NEWNAME -- echo "" >> $NEWNAME -- /usr/lib/sendmail -t < $NEWNAME -+ echo Subject: Automated Mail Server Request > "$NEWNAME" -+ echo To: ${server} >> "$NEWNAME" -+ echo "" >> "$NEWNAME" -+ sed -e 1,/^\$/d < $bodyfile >> "$NEWNAME" -+ echo "" >> "$NEWNAME" -+ /usr/lib/sendmail -t < "$NEWNAME" - if ($status) then - echo sendmail failed - cd ${METAMAIL_TMPDIR} -@@ -206,7 +228,7 @@ - endif - cd ${METAMAIL_TMPDIR} - rm -rf $TMPDIR -- echo Your $ctype data has been requested from a mail server. -+ echo Your "$ctype" data has been requested from a mail server. - exit 0 - default: - echo UNRECOGNIZED ACCESS-TYPE -@@ -214,19 +236,19 @@ - rm -rf $TMPDIR - exit -1 - endsw --if ($cenc == base64) then -- mimencode -u -b < $NEWNAME > OUT -- mv OUT $NEWNAME --else if ($cenc == quoted-printable) then -- mimencode -u -q < $NEWNAME > OUT -- mv OUT $NEWNAME -+if ("$cenc" == base64) then -+ mimencode -u -b < "$NEWNAME" > OUT -+ mv OUT "$NEWNAME" -+else if ("$cenc" == quoted-printable) then -+ mimencode -u -q < "$NEWNAME" > OUT -+ mv OUT "$NEWNAME" - endif - - popd --if ($atype == "local-file") then -- metamail -p -b -c "$ctype" $NEWNAME -+if ("$atype" == "local-file") then -+ metamail -p -b -c "$ctype" "$NEWNAME" - else -- metamail -p -b -c "$ctype" $TMPDIR/$NEWNAME -+ metamail -p -b -c "$ctype" "$TMPDIR/$NEWNAME" - endif - - if ($status) then -@@ -236,14 +258,14 @@ - exit -1 - endif - --if ($NEWNAME != $name) then -+if ("$NEWNAME" != "$name") then - echo "" -- echo The data just displayed is stored in the file $TMPDIR/$NEWNAME -+ echo The data just displayed is stored in the file "$TMPDIR/$NEWNAME" - echo "Do you want to delete it?" -- rm -i $TMPDIR/$NEWNAME -+ rm -i "$TMPDIR/$NEWNAME" - endif - --if (! -e ${TMPDIR}/${NEWNAME}) then -+if (! -e "${TMPDIR}/${NEWNAME}") then - cd ${METAMAIL_TMPDIR} - rmdir $TMPDIR - endif -diff -d -r -u -P mm2.7.orig/src/bin/showpartial mm2.7/src/bin/showpartial ---- mm2.7.orig/src/bin/showpartial Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/showpartial Sat Jun 20 14:25:55 1998 -@@ -14,78 +14,84 @@ - set file="$1" - # This next line is because message-id can contain weird chars - set id=`echo $2 | tr -d \!\$\&\*\(\)\|\'\"\;\/\<\>\\` --@ partnum = $3 --if ($#argv == 3 || $4 == "") then -+@ partnum = "$3" -+if ($#argv == 3 || "$4" == "") then - set totalnum=-1 - else - @ totalnum = "$4" - endif - --if (! -d $TREEROOT) then -+if ( -d $TREEROOT) then -+ if (! -o $TREEROOT) then -+ echo Error: You do not own $TREEROOT -+ exit -1 -+ endif -+else - mkdir $TREEROOT - if ($status) then - echo mkdir $TREEROOT failed - exit -1 - endif - endif --if (! -d ${TREEROOT}/$id) then -- mkdir ${TREEROOT}/$id -+if (! -d "${TREEROOT}/$id") then -+ mkdir "${TREEROOT}/$id" - if ($status) then -- echo mkdir ${TREEROOT}/$id failed -+ echo mkdir "${TREEROOT}/$id" failed - exit -1 - endif - endif --cp $file ${TREEROOT}/$id/$partnum -+cp "$file" "${TREEROOT}/$id/$partnum" - if ($status) then -- echo cp $file ${TREEROOT}/$id/$partnum failed -+ echo cp "$file" "${TREEROOT}/$id/$partnum" failed - exit -1 - endif --if ($totalnum == -1) then -- if (-e ${TREEROOT}/$id/CT) then -- set totalnum=`cat ${TREEROOT}/$id/CT` -+if ("$totalnum" == -1) then -+ if (-e "${TREEROOT}/$id/CT") then -+ set totalnum=`cat "${TREEROOT}/$id/CT"` - else - set totalnum=-1 #GROSS HACK - endif - else -- echo $totalnum >! ${TREEROOT}/$id/CT -+ echo "$totalnum" >! "${TREEROOT}/$id/CT" - endif - # Slightly bogus here -- the shell messes up the newlines in the headers - # If you put $MM_HEADERS in quotes, it doesn't help. --# if ($partnum == 1) then --# echo $MM_HEADERS > ${TREEROOT}/$id/HDRS -+# Note that this could very well constitute a security risk... -+# if ("$partnum" == 1) then -+# echo $MM_HEADERS > "${TREEROOT}/$id/HDRS" - # endif - set found=0 - set ix=1 - set list="" --set limit=$totalnum --if ($limit == -1) set limit=25 --while ($ix <= $limit) -- if (-e ${TREEROOT}/$id/$ix) then -+set limit="$totalnum" -+if ("$limit" == -1) set limit=25 -+while ("$ix" <= "$limit") -+ if (-e "${TREEROOT}/$id/$ix") then - set list="$list $ix" - @ found ++ - endif - @ ix ++ - end --if ($found == $totalnum) then -- cd ${TREEROOT}/$id -- cat $list > ${TREEROOT}/$id/FULL -+if ("$found" == "$totalnum") then -+ cd "${TREEROOT}/$id" -+ cat "$list" > "${TREEROOT}/$id/FULL" - # cat ${TREEROOT}/$id/HDRS $list > ${TREEROOT}/$id/FULL -- rm $list -- echo All parts of this ${totalnum}-part message have now been read. -- metamail -d ${TREEROOT}/$id/FULL -+ rm "$list" -+ echo All parts of this "${totalnum}"-part message have now been read. -+ metamail -d "${TREEROOT}/$id/FULL" - echo WARNING: To save space, the full file is now being deleted. -- echo You will have to read all $totalnum parts again to see the full message again. -- rm ${TREEROOT}/$id/FULL -- rm ${TREEROOT}/$id/CT --# rm ${TREEROOT}/$id/HDRS -+ echo You will have to read all "$totalnum" parts again to see the full message again. -+ rm "${TREEROOT}/$id/FULL" -+ rm "${TREEROOT}/$id/CT" -+# rm "${TREEROOT}/$id/HDRS" - cd -- rmdir ${TREEROOT}/$id -- rmdir ${TREEROOT} >& /dev/null -+ rmdir "${TREEROOT}/$id" -+ rmdir "${TREEROOT}" >& /dev/null - else -- if (${totalnum} == -1) then -- echo So far you have only read $found of the several parts of this message. -+ if ("${totalnum}" == -1) then -+ echo So far you have only read "$found" of the several parts of this message. - else -- echo So far you have only read $found of the $totalnum parts of this message. -+ echo So far you have only read "$found" of the "$totalnum" parts of this message. - endif - echo When you have read them all, then you will see the message in full. - endif -diff -d -r -u -P mm2.7.orig/src/bin/showpicture mm2.7/src/bin/showpicture ---- mm2.7.orig/src/bin/showpicture Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/showpicture Sat Jun 20 14:27:26 1998 -@@ -23,7 +23,7 @@ - set X_VIEWER="xloadimage -view -quiet -geometry +1+1" - # set X_VIEWER="xv -geometry +1+1" - endif --if ($1 == "-viewer" && $#argv > 1) then -+if ("$1" == "-viewer" && $#argv > 1) then - set X_VIEWER = "$2" - shift - shift -@@ -40,7 +40,15 @@ - echo be able to see the picture properly. - echo "" - if ($MM_NOTTTY) then -- set fname=${METAMAIL_TMPDIR}/sp.$$ -+ # Generate file name: -+ if ( -x /bin/mktemp ) then -+ set fname=`/bin/mktemp ${METAMAIL_TMPDIR}/sp.XXXXXXX` || exit 1 -+ else if ( -x /usr/bin/mktemp ) then -+ set fname=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/sp.XXXXXXX` || exit 1 -+ else -+ set fname=${METAMAIL_TMPDIR}/sp.$$ -+ rm -rf $fname -+ endif - echo "The picture is being automatically stored in the file $fname" - echo "If you do not want this file, please delete it." - else -@@ -50,20 +58,28 @@ - while ( 1 == 1) - echo -n "File name:" - set fname=$< -- if (! -f $fname) then -+ if (! -f "$fname") then - break - else - echo "$fname already exists. Try again" - endif - end - endif -- cp $1 $fname -- if ($status == 0) echo Wrote file $fname -+ cp "$1" "$fname" -+ if ($status == 0) echo Wrote file "$fname" - exit 0 - endif - - if ($#argv == 0) then -- set SQUIRREL=${METAMAIL_TMPDIR}/sp.$$ -+ # Generate file name: -+ if ( -x /bin/mktemp ) then -+ set SQUIRREL=`/bin/mktemp ${METAMAIL_TMPDIR}/sp.XXXXXXX` || exit 1 -+ else if ( -x /usr/bin/mktemp ) then -+ set SQUIRREL=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/sp.XXXXXXX` || exit 1 -+ else -+ set SQUIRREL=${METAMAIL_TMPDIR}/sp.$$ -+ rm -rf $SQUIRREL -+ endif - cat > $SQUIRREL - else - set SQUIRREL="$*" -diff -d -r -u -P mm2.7.orig/src/bin/sun-audio-file mm2.7/src/bin/sun-audio-file ---- mm2.7.orig/src/bin/sun-audio-file Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/sun-audio-file Sat Jun 20 14:28:11 1998 -@@ -12,7 +12,7 @@ - exit 1 - endif - --uudecode -o $fn < $1 -+uudecode -o $fn < "$1" - - audiotool $fn --rm -f $fn $1 -+rm -f $fn "$1" -diff -d -r -u -P mm2.7.orig/src/bin/sun-message.csh mm2.7/src/bin/sun-message.csh ---- mm2.7.orig/src/bin/sun-message.csh Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/sun-message.csh Sat Jun 20 14:29:41 1998 -@@ -8,6 +8,10 @@ - # $2 is untrustworthy data. Quote it. - # - mkdir /tmp/decode.$$ -+if ( $status != 0 ) then -+ echo "Error: cannot create temporary directory" -+ exit 1 -+endif - cd /tmp/decode.$$ - - if (! $?METAMAIL_PAGER) then -@@ -21,7 +25,7 @@ - exit 1 - endif - -- uudecode -o $fn $1 -+ uudecode -o $fn "$1" - - echo "The following file was uudecoded:" - echo "" -@@ -40,21 +44,21 @@ - echo -n "Which do you prefer (1 - 3)? [$defans] " - - set ans = $< -- if (x$ans == x) then -+ if ("x$ans" == x) then - set ans = $defans - endif -- if ($ans == 3) then -- rm $1 -+ if ("$ans" == 3) then -+ rm "$1" - cd /tmp; /bin/rm -rf /tmp/decode.$$ - exit 0 -- else if ($ans == 1) then -+ else if ("$ans" == 1) then - ${METAMAIL_PAGER} $fn -- else if ($ans == 2) then -+ else if ("$ans" == 2) then - set nfn = "" - echo -n "Save as: $HOME/" - set nfn = $< -- if (x$nfn != x) then -- /bin/cp $fn ${HOME}/$nfn -+ if ("x$nfn" != x) then -+ /bin/cp $fn "${HOME}/$nfn" - else - echo "Not Saved." - endif -@@ -64,7 +68,7 @@ - set defans = "3" - end - else -- ${METAMAIL_PAGER} $1 -+ ${METAMAIL_PAGER} "$1" - endif - - -diff -d -r -u -P mm2.7.orig/src/bin/sun-to-mime mm2.7/src/bin/sun-to-mime ---- mm2.7.orig/src/bin/sun-to-mime Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/sun-to-mime Sat Jun 20 14:31:12 1998 -@@ -8,10 +8,19 @@ - set METAMAIL_TMPDIR=/tmp - endif - --set TMPFILE=${METAMAIL_TMPDIR}/suntomime.$$ -+# Generate temporary file name: -+if ( -x /bin/mktemp ) then -+ set TMPFILE=`/bin/mktemp ${METAMAIL_TMPDIR}/suntomime.XXXXXXX` || exit 1 -+else if ( -x /usr/bin/mktemp ) then -+ set TMPFILE=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/suntomime.XXXXXXX` || exit 1 -+else -+ set TMPFILE=${METAMAIL_TMPDIR}/suntomime.$$ -+ rm -rf $TMPFILE -+endif -+ - echo "Content-type: multipart/mixed; boundary=--------" > $TMPFILE - echo "" >> $TMPFILE --sed -e 's/X-Sun-Data-Type:/Content-type:/' >> $TMPFILE < $1 -+sed -e 's/X-Sun-Data-Type:/Content-type:/' >> $TMPFILE < "$1" - echo "------------" >> $TMPFILE - #metamail -d -z $TMPFILE - metamail -z $TMPFILE -diff -d -r -u -P mm2.7.orig/src/bin/sun2mime mm2.7/src/bin/sun2mime ---- mm2.7.orig/src/bin/sun2mime Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/sun2mime Sat Jun 20 14:31:40 1998 -@@ -9,7 +9,16 @@ - if [ x$METAMAIL_TMPDIR = x ]; then - METAMAIL_TMPDIR=/tmp - fi --TMPFILE=${METAMAIL_TMPDIR}/suntomime.$$ -+ -+# Generate temporary file name: -+if [ -x /bin/mktemp ] ; then -+ TMPFILE=`/bin/mktemp ${METAMAIL_TMPDIR}/suntomime.XXXXXXX` || exit 1 -+elif [ -x /usr/bin/mktemp ] ; then -+ TMPFILE=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/suntomime.XXXXXXX` || exit 1 -+else -+ TMPFILE=${METAMAIL_TMPDIR}/suntomime.$$ -+ rm -rf $TMPFILE -+fi - - /bin/nawk ' - BEGIN { printf("Content-type: multipart/mixed; boundary=--------\n\n") -@@ -36,7 +45,7 @@ - print - } - END { printf("----------\n") } --' $1 > $TMPFILE -+' "$1" > $TMPFILE - - metamail -z $TMPFILE - rm -f $TMPFILE -diff -d -r -u -P mm2.7.orig/src/metamail/mailto.c mm2.7/src/metamail/mailto.c ---- mm2.7.orig/src/metamail/mailto.c Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/metamail/mailto.c Sat Jun 20 16:57:20 1998 -@@ -61,6 +61,7 @@ - #endif - - extern char *malloc(), *realloc(), *index(), *getmyname(); -+extern FILE *Fopen(); - struct mailpart *CreateNewPart(); - - /* The main data structure for the multiple parts of the mail */ -@@ -208,7 +209,7 @@ - pager = getenv("PAGER"); - - strcpy(TmpName, tmpname()); -- fp = fopen(TmpName, "w"); -+ fp = Fopen(TmpName, "w"); - if (!fp) fp = stdout; - fprintf(fp, "The following tilde escapes are BSD-mail-compatible:\n"); - fprintf(fp, "~? Show help on tilde escapes\n"); -@@ -594,7 +595,7 @@ - } - FirstPart = NewPart(); - CurrentPart = FirstPart; -- fpout = fopen(CurrentPart->filename, "w"); -+ fpout = Fopen(CurrentPart->filename, "w"); - if (!fpout) { - fprintf(stderr, "mailto: Can't open temporary file %s\n", CurrentPart->filename); - cleanexit(-1); -@@ -681,7 +682,7 @@ - CurrentPart->next = NewPart(); - CurrentPart->next->prev = CurrentPart; - CurrentPart = CurrentPart->next; -- fpout = fopen(CurrentPart->filename, "w"); -+ fpout = Fopen(CurrentPart->filename, "w"); - if (!fpout) { - fprintf(stderr, "mailto: Can't open temporary file %s\n", CurrentPart->filename); - cleanexit(-1); -@@ -720,7 +721,7 @@ - CurrentPart = CurrentPart->next; - CurrentPart->istext = 0; - CurrentPart->content_type = "message/rfc822"; -- fpout = fopen(CurrentPart->filename, "w"); -+ fpout = Fopen(CurrentPart->filename, "w"); - if (!fpout) { - fprintf(stderr, "mailto: Cannot open temporary file %s\n", CurrentPart->filename); - break; -@@ -732,7 +733,7 @@ - CurrentPart->next = NewPart(); - CurrentPart->next->prev = CurrentPart; - CurrentPart = CurrentPart->next; -- fpout = fopen(CurrentPart->filename, "w"); -+ fpout = Fopen(CurrentPart->filename, "w"); - if (!fpout) { - fprintf(stderr, "mailto: Can't open temporary file %s\n", CurrentPart->filename); - cleanexit(-1); -@@ -811,11 +812,11 @@ - char Cmd[TMPFILE_NAME_SIZE + 15]; - char *s=tmpname(); - fclose(fpout); -- fptmp = fopen(s, "w"); -+ fptmp = Fopen(s, "w"); - WriteOutMessage(fptmp, ToList, Subject, CCList, FirstPart); - TempCloseStyles(fptmp); - fclose(fptmp); -- fpout = fopen(CurrentPart->filename, "a"); -+ fpout = Fopen(CurrentPart->filename, "a"); - if (!fpout) { - fprintf(stderr, "mailto: Can't open temporary file %s\n", CurrentPart->filename); - cleanexit(-1); -@@ -899,7 +900,7 @@ - char *fname; - fclose(fpout); - fname = start; -- fptmp = fopen(fname, "w"); -+ fptmp = Fopen(fname, "w"); - WriteOutMessage(fptmp, ToList, Subject, CCList, FirstPart); - TempCloseStyles(fptmp); - if(fclose(fptmp)) { -@@ -907,7 +908,7 @@ - } else { - printf("Wrote draft to %s\n", fname); - } -- fpout = fopen(CurrentPart->filename, "a"); -+ fpout = Fopen(CurrentPart->filename, "a"); - if (!fpout) { - fprintf(stderr, "mailto: Can't open temporary file %s\n", CurrentPart->filename); - cleanexit(-1); -@@ -972,7 +973,7 @@ - CurrentPart = CurrentPart->next; - CurrentPart->istext = 0; - CurrentPart->content_type = "message/rfc822"; -- fpout = fopen(CurrentPart->filename, "w"); -+ fpout = Fopen(CurrentPart->filename, "w"); - if (!fpout) { - fprintf(stderr, "mailto: Cannot open temporary file %s\n", CurrentPart->filename); - break; -@@ -994,7 +995,7 @@ - CurrentPart->next = NewPart(); - CurrentPart->next->prev = CurrentPart; - CurrentPart = CurrentPart->next; -- fpout = fopen(CurrentPart->filename, "w"); -+ fpout = Fopen(CurrentPart->filename, "w"); - if (!fpout) { - fprintf(stderr, "mailto: Can't open temporary file %s\n", CurrentPart->filename); - cleanexit(-1); -@@ -1476,7 +1477,7 @@ - char DeadFile[1000]; - - sprintf(DeadFile, "%s/dead.letter", gethome()); -- fp = fopen(DeadFile, "w"); -+ fp = Fopen(DeadFile, "w"); - WriteOutMessage(fp, ToList, Subject, CCList, FirstPart); - if(fclose(fp)) { - perror("Could not write ~/dead.letter\n"); -@@ -1776,7 +1777,7 @@ - printf("Cannot read %s, data insertion cancelled\n", sdum); - return(NULL); - } -- fpo = fopen(mp->filename, "w"); -+ fpo = Fopen(mp->filename, "w"); - if (!fpo) { - printf("Cannot open temporary file, data insertion cancelled\n"); - return(NULL); -@@ -1794,7 +1795,7 @@ - int ct; - printf("\nEnter the MIME Content-type value for the data from file %s\n (type '?' for a list of locally-valid content-types): ", sdum); - fflush(stdout); -- gets(LineBuf); -+ fgets(LineBuf, sizeof(LineBuf), stdin); - if (index(LineBuf, '/')) { - char lc[100], *s, AnsBuf[100]; - strcpy(lc, LineBuf); -@@ -1812,7 +1813,7 @@ - } - if (mc) break; - printf("The MIME content-type '%s' is not listed in your local mailcap files,\nand may not be a valid MIME type. Do you want to use it anyway [no] ? ", LineBuf); -- s = gets(AnsBuf); -+ s = fgets(AnsBuf, sizeof(AnsBuf), stdin); - while (s && *s && isspace((unsigned char) *s)) ++s; - if (s && (*s == 'y' || *s == 'Y')) break; - continue; -@@ -1939,7 +1940,7 @@ - mp->encoding_type_needed = ENC_NONE; - } - newfilename = tmpname(); -- fpout = fopen(newfilename, "w"); -+ fpout = Fopen(newfilename, "w"); - if (!fpout) { - fprintf(stderr, "Cannot open file %s for writing, no data included.\n", newfilename); - free(CmdBuf); -@@ -2109,7 +2110,7 @@ - ContainsEightBitChar(FirstPart->filename)) { - FirstPart->encoding_type_needed = ENC_QP; - } -- fpout = fopen(FirstPart->filename, "a"); -+ fpout = Fopen(FirstPart->filename, "a"); - free(CmdBuf); - free(CmdBuf2); - return; -@@ -2159,7 +2160,7 @@ - lastmp = mp; - mp = mp->next; - } -- fpout = fopen(lastmp->filename, "a"); -+ fpout = Fopen(lastmp->filename, "a"); - free(CmdBuf); - free(CmdBuf2); - } -diff -d -r -u -P mm2.7.orig/src/metamail/metamail.c mm2.7/src/metamail/metamail.c ---- mm2.7.orig/src/metamail/metamail.c Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/metamail/metamail.c Sat Jun 20 16:54:29 1998 -@@ -112,6 +112,7 @@ - - char *FindParam(); - extern FILE *popen(); -+extern FILE *Fopen(); - static char *nomem = "Out of memory!"; - static char *mmversion = MM_VERSTRING; - static char *NoAskDefault = "text,text/plain,text/richtext"; -@@ -580,7 +581,7 @@ - int overwriteans = -1; - do { - printf("File %s exists. Do you want to overwrite it (y/n) ?\n", Fname); -- s = gets(AnsBuf); -+ s = fgets(AnsBuf, sizeof(AnsBuf), stdin); - if (!s) { - overwriteans = 0; - } else { -@@ -646,7 +647,7 @@ - if (Fname[0] == 0 || Fname[0] == '\n') { - ConsumeRestOfPart(NULL); - } else { -- fp = fopen(Fname, WRITE_BINARY); -+ fp = Fopen(Fname, WRITE_BINARY); - if (!fp) ExitWithError("Cannot open temporary file"); - TranslateInputToOutput(InputFP, fp, EncodingCode, ContentType); - ecode = fclose(fp); -@@ -961,7 +962,7 @@ - /* Create it, ugh. Also needs to affect later command. */ - MkTmpFileName(TmpName); - DeleteSourceFileWhenDone = 1; -- fptmp = fopen(TmpName, WRITE_BINARY); -+ fptmp = Fopen(TmpName, WRITE_BINARY); - if (!fptmp) ExitWithError("Can't open temporary file\n"); - while (fgets(LineBuf, LINE_BUF_SIZE, stdin)) { - fputs(LineBuf, fptmp); -@@ -1195,7 +1196,7 @@ - { - int j; - FILE *outfp; -- outfp = fopen(SquirrelFile, WRITE_BINARY); -+ outfp = Fopen(SquirrelFile, WRITE_BINARY); - if (!outfp) { - fprintf(stderr, "Cannot open %s to squirrel away a portion of a multipart/alternative\n", SquirrelFile); - return(-1); -@@ -1799,7 +1800,7 @@ - nameBuf[(cp - def) + 4] = 0; - cp++; /* Now points to value part of environment string. */ - -- if ((envFile = fopen(nameBuf, "w")) == NULL) { -+ if ((envFile = Fopen(nameBuf, "w")) == NULL) { - return(2); - } - -@@ -1824,7 +1825,7 @@ - } else { - printf("This message contains '%s'-format data.\nDo you want to view it using the '%s' command (y/n) [y] ? ", ctype, ShortCommand(progname)); - } -- s = gets(AnsBuf); -+ s = fgets(AnsBuf, sizeof(AnsBuf), stdin); - if (!s) return(0); /* EOF */ - while (s && *s && isspace((unsigned char) *s)) ++s; - if (*s == 'y' || *s == 'Y' || !*s || *s == '\n') return(1); -@@ -2037,7 +2038,7 @@ - } else { - /* What follows is REALLY bogus, but all my encoding stuff is pipe-oriented right now... */ - MkTmpFileName(TmpFile); -- fp = fopen(TmpFile, WRITE_BINARY); -+ fp = Fopen(TmpFile, WRITE_BINARY); - if (!fp) { - fprintf(stderr, "Could not open temporary file\n"); - } else { -@@ -2192,7 +2193,7 @@ - strcpy(thispart->fname, TmpFileNameBuf); - WriteTmpFile(thispart->fname, thispart->ctype); - strcat(TmpFileNameBuf, "H"); -- headfp = fopen(TmpFileNameBuf, "w"); -+ headfp = Fopen(TmpFileNameBuf, "w"); - if (headfp) { - fputs(mailheaders+12, headfp); - /* The +12 gets rid of MM_HEADERS=\n */ -@@ -2298,7 +2299,7 @@ - FILE *fpout; - int retval = 0; - -- fpout = fopen(fname, WRITE_BINARY); -+ fpout = Fopen(fname, WRITE_BINARY); - if (!fpout) { - perror("WriteTmpFile"); - ExitWithError("Can't create temporary file"); -@@ -2519,7 +2520,7 @@ - FILE *script; - - MkTmpFileName(nameBuf); -- if ((script = fopen(nameBuf, "w")) == NULL) { -+ if ((script = Fopen(nameBuf, "w")) == NULL) { - fprintf(stderr, "Unable to open %s for writing\n", nameBuf); - exit(1); - } -diff -d -r -u -P mm2.7.orig/src/metamail/shared.c mm2.7/src/metamail/shared.c ---- mm2.7.orig/src/metamail/shared.c Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/metamail/shared.c Sat Jun 20 16:51:54 1998 -@@ -1,6 +1,11 @@ - #include <stdio.h> - #include <ctype.h> - #include <config.h> -+#include <unistd.h> -+#include <string.h> -+#include <errno.h> -+#include <fcntl.h> -+#include <sys/stat.h> - #ifdef SYSV - #include <unistd.h> - #include <sys/utsname.h> -@@ -116,5 +121,55 @@ - initialized = 1; - } - return(hostname); -+} -+ -+ -+/* This fopen wrapper function is designed to avoid /tmp-file race -+ * conditions where a temporary filename is created and somebody -+ * throws a link in your way before the fopen(...,"w"). This -+ * would only happen if another user on the system were actively -+ * trying to trick you into destroying files. -+ * Sorry, but "a" mode is not really handled any safer than fopen, -+ * since I really have no criterium for deciding what files are -+ * OK to write to. */ -+FILE *Fopen(Fopen_path,Fopen_mode) -+char *Fopen_path; char *Fopen_mode; -+{ -+#ifdef MSDOS -+return(fopen(Fopen_path,Fopen_mode)); -+#else -+int Fopen_fd; -+struct stat Fopen_sb; -+int Fopen_appendmode = 0; -+int Fopen_readmode = 0; -+int Fopen_openflags = 0; -+int Fopen_r; -+if ( strchr(Fopen_mode,'r') != (char *)0 ) return(fopen(Fopen_path,Fopen_mode)); -+if ( strchr(Fopen_mode,'a') != (char *)0 ) Fopen_appendmode = 1; -+if ( strchr(Fopen_mode,'+') != (char *)0 ) Fopen_readmode = 1; -+if ( ( Fopen_appendmode && (strchr(Fopen_mode,'w') != (char *)0) ) || -+ ( (! Fopen_appendmode) && (strchr(Fopen_mode,'w') == (char *)0) ) ) -+ { -+ errno = EINVAL ; -+ return( (FILE *)0 ); -+ } -+if ( Fopen_appendmode ) -+ { -+ /* If "a" and file exists, pass it to the real fopen() */ -+ Fopen_r = stat(Fopen_path,&Fopen_sb) ; -+ if ( (Fopen_r != -1) || (errno != ENOENT) ) -+ return( fopen(Fopen_path,Fopen_mode) ); -+ } -+if ( Fopen_readmode ) -+ Fopen_openflags = O_RDWR|O_CREAT|O_EXCL ; -+else -+ Fopen_openflags = O_WRONLY|O_CREAT|O_EXCL ; -+if ( Fopen_appendmode ) Fopen_openflags |= O_APPEND ; -+remove( Fopen_path ); -+/* 0666? We'd better hope their umask is safe... */ -+Fopen_fd = open(Fopen_path,Fopen_openflags,0666); -+if ( Fopen_fd > -1 ) return( fdopen(Fopen_fd,Fopen_mode) ); -+return( (FILE *)0 ); -+#endif - } - -diff -d -r -u -P mm2.7.orig/src/metamail/splitmail.c mm2.7/src/metamail/splitmail.c ---- mm2.7.orig/src/metamail/splitmail.c Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/metamail/splitmail.c Sat Jun 20 15:57:02 1998 -@@ -26,6 +26,7 @@ - #include <config.h> - #include <ctype.h> - #include <time.h> -+#include <fcntl.h> - - #define MINCHUNKSIZE 20000 /* Better be enough to hold the headers, or we die! */ - extern char *malloc(), *index(), *getmyname(); -@@ -243,6 +244,7 @@ - char *deliverycmd, *prefix, *SharedHeaders, *SubjectBuf, *id, *MessageID, *bigbuf, *OrigID; - { - FILE *fpout; -+ int fd; - char OutputFile[1000]; - int code; - #if defined(sequent) -@@ -255,7 +257,11 @@ - fpout = popen(deliverycmd, "w"); - } else { - sprintf(OutputFile, "%s%d", prefix, whichpart); -- fpout = fopen(OutputFile, "w"); -+ /* fpout = fopen(OutputFile, "w"); */ -+ remove(OutputFile); -+ fpout = NULL; -+ fd = open(OutputFile, O_WRONLY|O_CREAT|O_EXCL, 0600); -+ if ( fd > -1 ) fpout = fdopen(fd, "w"); - } - if (!fpout) { - fprintf(stderr, "splitmail: Can't open %s for writing\n", DoDeliver ? deliverycmd : OutputFile); diff --git a/app-text/metamail/files/mm-2.7-sml.patch b/app-text/metamail/files/mm-2.7-sml.patch deleted file mode 100644 index 55496156294e..000000000000 --- a/app-text/metamail/files/mm-2.7-sml.patch +++ /dev/null @@ -1,104 +0,0 @@ ---- mm2.7/src/metamail/splitmail.c.sml Fri Jul 30 15:52:01 1999 -+++ mm2.7/src/metamail/splitmail.c Fri Jul 30 15:52:14 1999 -@@ -42,8 +42,8 @@ - #define VERBOSEDELIVERYCMD VerboseDeliveryCmd - #else - extern char *getenv(); --#define NORMALDELIVERYCMD "/usr/lib/sendmail -t -oi" --#define VERBOSEDELIVERYCMD "/usr/lib/sendmail -t -v -oi" -+#define NORMALDELIVERYCMD "/usr/sbin/sendmail -t -oi" -+#define VERBOSEDELIVERYCMD "/usr/sbin/sendmail -t -v -oi" - #endif - - usageexit() { ---- mm2.7/src/bin/audiosend.sml Fri Jul 30 15:49:33 1999 -+++ mm2.7/src/bin/audiosend Fri Jul 30 15:49:44 1999 -@@ -110,7 +110,7 @@ - switch ("$which") - case 1: - echo -n "Sending mail, please wait... " -- /usr/lib/sendmail "$to" "$cc" < $fname -+ /usr/sbin/sendmail "$to" "$cc" < $fname - if (! $status) then - echo "Done." - rm $fname ---- mm2.7/src/bin/showexternal.sml Fri Jul 30 15:50:02 1999 -+++ mm2.7/src/bin/showexternal Fri Jul 30 15:50:09 1999 -@@ -219,7 +219,7 @@ - echo "" >> "$NEWNAME" - sed -e 1,/^\$/d < $bodyfile >> "$NEWNAME" - echo "" >> "$NEWNAME" -- /usr/lib/sendmail -t < "$NEWNAME" -+ /usr/sbin/sendmail -t < "$NEWNAME" - if ($status) then - echo sendmail failed - cd ${METAMAIL_TMPDIR} ---- mm2.7/src/bin/mailserver.sml Fri Jul 30 15:50:19 1999 -+++ mm2.7/src/bin/mailserver Fri Jul 30 15:50:36 1999 -@@ -76,7 +76,7 @@ - probably run in some circumstance other than mail delivery. - -------------------- - ! -- cat $TmpFile - | /usr/lib/sendmail "$MAINTAINER" -+ cat $TmpFile - | /usr/sbin/sendmail "$MAINTAINER" - # Takes the rest of the message from standard input - rm $TmpFile - exit 0 -@@ -94,7 +94,7 @@ - - The file you requested, if it exists, will not be sent to you. - ! -- /usr/lib/sendmail -t < $TmpFile -+ /usr/sbin/sendmail -t < $TmpFile - rm $TmpFile - exit 0 - endif -@@ -116,7 +116,7 @@ - echo "--------------------------------" >> $TmpFile - ls -R >> $TmpFile - echo "" >> $TmpFile -- /usr/lib/sendmail -t < $TmpFile -+ /usr/sbin/sendmail -t < $TmpFile - rm $TmpFile - exit 0 - endif -@@ -144,7 +144,7 @@ - echo "Command failed:" >> $TmpFile - echo " metasend -b -t $FromName -f $Subject -m $ct -s Re: $Subject" >> $TmpFile - echo "" >> $TmpFile -- /usr/lib/sendmail -t < $TmpFile -+ /usr/sbin/sendmail -t < $TmpFile - rm $TmpFile - exit 0 - endif -@@ -157,7 +157,7 @@ - echo The file: "$Subject" >> $TmpFile - echo was sent to: "$FromName" >> $TmpFile - echo "" >> $TmpFile -- /usr/lib/sendmail -t < $TmpFile -+ /usr/sbin/sendmail -t < $TmpFile - endif - - rm -f $TmpFile ---- mm2.7/src/bin/showexternal.csh.sml Fri Jul 30 15:50:55 1999 -+++ mm2.7/src/bin/showexternal.csh Fri Jul 30 15:51:05 1999 -@@ -186,7 +186,7 @@ - echo "" >> $NEWNAME - sed -e 1,/^\$/d < $bodyfile >> $NEWNAME - echo "" >> $NEWNAME -- /usr/lib/sendmail -t < $NEWNAME -+ /usr/sbin/sendmail -t < $NEWNAME - if ($status) then - echo sendmail failed - cd ${METAMAIL_TMPDIR} ---- mm2.7/src/man/mailto.1.sml Fri Jul 30 15:51:30 1999 -+++ mm2.7/src/man/mailto.1 Fri Jul 30 15:51:37 1999 -@@ -230,7 +230,7 @@ - dot -- controls whether or not a period alone on a line - should be interpreted as terminating your mail - ignore -- controls whether or not interrupts are ignored -- verbose -- controls the verbosity of output from /usr/lib/sendmail -+ verbose -- controls the verbosity of output from /usr/sbin/sendmail - quiet -- controls the verbosity of output from the mailto program. - keepblind -- controls whether or not a 'blind' copy of the mail is kept. - commasonly -- controls whether or not a space character diff --git a/app-text/metamail/files/mm-2.7-sunquote.patch b/app-text/metamail/files/mm-2.7-sunquote.patch deleted file mode 100644 index 804091ba91d7..000000000000 --- a/app-text/metamail/files/mm-2.7-sunquote.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- mm2.7/src/bin/sun-message.csh~ Tue May 19 10:22:52 1998 -+++ mm2.7/src/bin/sun-message.csh Tue May 19 10:26:39 1998 -@@ -5,6 +5,8 @@ - # This is sun-message. It looks at $2 to figure out how to decode $1, then gives the - # user a short menu of choices, display, save, or quit. - # -+# $2 is untrustworthy data. Quote it. -+# - mkdir /tmp/decode.$$ - cd /tmp/decode.$$ - -@@ -12,7 +14,7 @@ - set METAMAIL_PAGER=more - endif - --if ($2 == "uuencode") then -+if ("$2" == "uuencode") then - set fn=`mktemp $METAMAIL_TMPDIR/audio.XXXXXX` - test -n "$fn" - if $? then diff --git a/app-text/metamail/files/mm-2.7-tmpfile.patch b/app-text/metamail/files/mm-2.7-tmpfile.patch deleted file mode 100644 index 970092f24577..000000000000 --- a/app-text/metamail/files/mm-2.7-tmpfile.patch +++ /dev/null @@ -1,114 +0,0 @@ -diff -d -r -u -P mm2.7.orig/src/bin/mailserver mm2.7/src/bin/mailserver ---- mm2.7.orig/src/bin/mailserver Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/mailserver Mon Jun 15 18:54:01 1998 -@@ -28,7 +28,15 @@ - rehash - set FromName="" - set Subject="" --set TmpFile=/tmp/ms.$$ -+# Generate temporary file name: -+if ( -x /bin/mktemp ) then -+ set TmpFile=`/bin/mktemp /tmp/ms.XXXXXXX` || exit 1 -+else if ( -x /usr/bin/mktemp ) then -+ set TmpFile=`/usr/bin/mktemp /tmp/ms.XXXXXXX` || exit 1 -+else -+ set TmpFile=/tmp/ms.$$ -+ rm -rf $TmpFile -+endif - set FOORAW=$< - while ("$FOORAW" != "") - set FOO=(` echo "$FOORAW" | tr "[" "x"`) -@@ -149,4 +157,5 @@ - The file: $Subject - was sent to: $FromName - ! -+rm -f $TmpFile - exit 0 -diff -d -r -u -P mm2.7.orig/src/bin/showaudio mm2.7/src/bin/showaudio ---- mm2.7.orig/src/bin/showaudio Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/showaudio Mon Jun 15 19:06:25 1998 -@@ -127,9 +127,18 @@ - if ($#argv >= 1) then - exec /usr/sbin/sfplay -i mu-law chan 1 rate 8000 end $* - else -- cat > ${METAMAIL_TMPDIR}/audio.$$ -- /usr/sbin/sfplay -i mu-law chan 1 rate 8000 end ${METAMAIL_TMPDIR}/audio.$$ -- rm ${METAMAIL_TMPDIR}/audio.$$ -+ # Generate temporary file name: -+ if ( -x /bin/mktemp ) then -+ set TmpAudio=`/bin/mktemp ${METAMAIL_TMPDIR}/audio.XXXXXXX` || exit 1 -+ else if ( -x /usr/bin/mktemp ) then -+ set TmpAudio=`/usr/bin/mktemp ${METAMAIL_TMPDIR}/audio.XXXXXXX` || exit 1 -+ else -+ set TmpAudio=${METAMAIL_TMPDIR}/audio.$$ -+ rm -rf $TmpAudio -+ endif -+ cat > $TmpAudio -+ /usr/sbin/sfplay -i mu-law chan 1 rate 8000 end $TmpAudio -+ rm $TmpAudio - exit 0 - endif - else if (-d /usr/sony) then -@@ -198,7 +207,15 @@ - echo "" - if (! $?MM_NOTTTY) set MM_NOTTTY=0 - if ($MM_NOTTTY == 1) then -- set fname=/tmp/mm.aud.$$ -+ # Generate unique file name: -+ if ( -x /bin/mktemp ) then -+ set fname=`/bin/mktemp /tmp/mm.aud.XXXXXXX` || exit 1 -+ else if ( -x /usr/bin/mktemp ) then -+ set fname=`/usr/bin/mktemp /tmp/mm.aud.XXXXXXX` || exit 1 -+ else -+ set fname=/tmp/mm.aud.$$ -+ rm -rf $fname -+ endif - else - echo -n "Do you want to write the audio out to a file [y] ? " - set ANS=$< -diff -d -r -u -P mm2.7.orig/src/bin/sun-message.csh mm2.7/src/bin/sun-message.csh ---- mm2.7.orig/src/bin/sun-message.csh Mon Jun 15 00:30:47 1998 -+++ mm2.7/src/bin/sun-message.csh Mon Jun 15 19:02:09 1998 -@@ -8,6 +8,10 @@ - # $2 is untrustworthy data. Quote it. - # - mkdir /tmp/decode.$$ -+if ( $? != 0 ) then -+ echo "Error: cannot create temporary directory" -+ exit 1 -+endif - cd /tmp/decode.$$ - - if (! $?METAMAIL_PAGER) then -diff -u -d -r -P mm2.7.orig/src/metamail/splitmail.c mm2.7/src/metamail/splitmail.c ---- mm2.7.orig/src/metamail/splitmail.c Sun Jun 14 12:00:20 1998 -+++ mm2.7/src/metamail/splitmail.c Sun Jun 14 12:01:09 1998 -@@ -26,6 +26,7 @@ - #include <config.h> - #include <ctype.h> - #include <time.h> -+#include <fcntl.h> - - #define MINCHUNKSIZE 20000 /* Better be enough to hold the headers, or we die! */ - extern char *malloc(), *index(), *getmyname(); -@@ -243,6 +244,7 @@ - char *deliverycmd, *prefix, *SharedHeaders, *SubjectBuf, *id, *MessageID, *bigbuf, *OrigID; - { - FILE *fpout; -+ int fd; - char OutputFile[1000]; - int code; - #if defined(sequent) -@@ -255,7 +257,10 @@ - fpout = popen(deliverycmd, "w"); - } else { - sprintf(OutputFile, "%s%d", prefix, whichpart); -- fpout = fopen(OutputFile, "w"); -+ remove(OutputFile); -+ fpout = NULL ; -+ fd = open(OutputFile, O_WRONLY|O_CREAT|O_EXCL, 0600); -+ if ( fd > -1 ) fpout = fdopen(fd, "w"); - } - if (!fpout) { - fprintf(stderr, "splitmail: Can't open %s for writing\n", DoDeliver ? deliverycmd : OutputFile); - diff --git a/app-text/metamail/files/mm-2.7-uudecode.patch b/app-text/metamail/files/mm-2.7-uudecode.patch deleted file mode 100644 index ea69c2c9efc4..000000000000 --- a/app-text/metamail/files/mm-2.7-uudecode.patch +++ /dev/null @@ -1,45 +0,0 @@ ---- mm2.7/src/bin/sun-audio-file.ewt Fri Oct 24 09:41:11 1997 -+++ mm2.7/src/bin/sun-audio-file Fri Oct 24 09:52:05 1997 -@@ -6,7 +6,13 @@ - set METAMAIL_TMPDIR=/tmp - endif - --cd ${METAMAIL_TMPDIR} --uudecode < $1 --audiotool audio-file --rm -f audio-file $1 -+set fn=`mktemp $METAMAIL_TMPDIR/audio.XXXXXX` -+test -n "$fn" -+if $? then -+ exit 1 -+endif -+ -+uudecode -o $fn < $1 -+ -+audiotool $fn -+rm -f $fn $1 ---- mm2.7/src/bin/sun-message.csh.ewt Fri Oct 24 09:44:07 1997 -+++ mm2.7/src/bin/sun-message.csh Fri Oct 24 09:52:30 1997 -@@ -9,7 +9,13 @@ - cd /tmp/decode.$$ - - if ($2 == "uuencode") then -- uudecode $1 -+ set fn=`mktemp $METAMAIL_TMPDIR/audio.XXXXXX` -+ test -n "$fn" -+ if $? then -+ exit 1 -+ endif -+ -+ uudecode -o $fn $1 - - echo "The following file was uudecoded:" - echo "" -@@ -17,7 +23,6 @@ - set defans = "1" - while (1) - ls -l -- set fn = * - - echo "" - echo "Please choose one:" diff --git a/app-text/metamail/metamail-2.7-r1.ebuild b/app-text/metamail/metamail-2.7-r1.ebuild deleted file mode 100644 index bb5a101594ce..000000000000 --- a/app-text/metamail/metamail-2.7-r1.ebuild +++ /dev/null @@ -1,45 +0,0 @@ -# Copyright 1999-2000 Gentoo Technologies, Inc. -# Distributed under the terms of the GNU General Public License, v2 or later -# Author Achim Gottinger <achim@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/app-text/metamail/metamail-2.7-r1.ebuild,v 1.6 2000/11/15 22:57:41 achim Exp $ - -P=metamail-2.7 -A=mm2.7.tar.Z -S=${WORKDIR}/mm2.7/src -DESCRIPTION="Metamail" -SRC_URI="ftp://thumper.bellcore.com/pub/nsb/${A} - ftp://ftp.bora.net/pub/free_servers/mail/metamail/${A}" - -DEPEND=">=x11-base/xfree-4.0.1" - -src_unpack() { - unpack ${A} - cd ${S} - cp Makefile Makefile.orig - sed -e "s:^CFLAGS =.*:CFLAGS = -fsigned-char -g -pipe -DLINUX -I \. ${CFLAGS}:" Makefile.orig > Makefile - cd metamail - cp Makefile Makefile.orig - sed -e "s/-ltermcap/-lncurses/" Makefile.orig > Makefile - cd ../richmail - cp Makefile Makefile.orig - sed -e "s/-ltermcap/-lncurses/" Makefile.orig > Makefile -} - -src_compile() { - cd ${S} - try make - try make -C fonts -} - -src_install() { - cd ${S} - into /usr - dobin bin/* - doman man/* - dodoc CREDITS README mailers.txt - insinto /usr/X11R6/lib/X11/fonts/misc - doins fonts/*.pcf -} - - - diff --git a/app-text/metamail/metamail-2.7-r2.ebuild b/app-text/metamail/metamail-2.7-r2.ebuild deleted file mode 100644 index f650026b4b2c..000000000000 --- a/app-text/metamail/metamail-2.7-r2.ebuild +++ /dev/null @@ -1,55 +0,0 @@ -# Copyright 1999-2000 Gentoo Technologies, Inc. -# Distributed under the terms of the GNU General Public License, v2 or later -# Author Achim Gottinger <achim@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/app-text/metamail/metamail-2.7-r2.ebuild,v 1.1 2000/11/15 21:56:01 achim Exp $ - -P=metamail-2.7 -A=mm2.7.tar.Z -S=${WORKDIR}/mm2.7/src -DESCRIPTION="Metamail" -SRC_URI="ftp://thumper.bellcore.com/pub/nsb/${A} - ftp://ftp.bora.net/pub/free_servers/mail/metamail/${A}" - -DEPEND=">=x11-base/xfree-4.0.1" - -src_unpack() { - unpack ${A} - cd ${S} - for i in make fonts glibc csh uudecode sunqote \ - ohnonotagain arghhh - do - echo - echo "Applying $i patch ..." - patch -p2 < ${FILESDIR}/mm-2.7-$i.patch - done - patch -p2 < ${FILESDIR}/metamail-2.7-nl.patch - - cp Makefile Makefile.orig - sed -e "s:^CFLAGS =.*:CFLAGS = -fsigned-char -g -pipe -DLINUX -I \. ${CFLAGS}:" Makefile.orig > Makefile - cd metamail - cp Makefile Makefile.orig - sed -e "s/-ltermcap/-lncurses/" Makefile.orig > Makefile - cd ../richmail - cp Makefile Makefile.orig - sed -e "s/-ltermcap/-lncurses/" Makefile.orig > Makefile - -} - -src_compile() { - cd ${S} - try make - try make -C fonts -} - -src_install() { - cd ${S} - into /usr - dobin bin/* - doman man/* - dodoc CREDITS README mailers.txt - insinto /usr/X11R6/lib/X11/fonts/misc - doins fonts/*.pcf -} - - - diff --git a/app-text/sablotron/files/digest-sablotron-0.44 b/app-text/sablotron/files/digest-sablotron-0.44 deleted file mode 100644 index 3ae4b7e2d3b7..000000000000 --- a/app-text/sablotron/files/digest-sablotron-0.44 +++ /dev/null @@ -1,2 +0,0 @@ -MD5 35874ea80215fea45f1af28a419c2ce2 Sablot-0.44.tar.gz -MD5 c2607a890d8f31cdd0ab3d3dc6c896a6 Sablot-Expat-1.1.2.tar.gz diff --git a/app-text/sablotron/sablotron-0.44.ebuild b/app-text/sablotron/sablotron-0.44.ebuild deleted file mode 100644 index 6f05ccbfb371..000000000000 --- a/app-text/sablotron/sablotron-0.44.ebuild +++ /dev/null @@ -1,43 +0,0 @@ -# Copyright 1999-2000 Gentoo Technologies, Inc. -# Distributed under the terms of the GNU General Public License, v2 or later -# Author Achim Gottinger <achim@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/app-text/sablotron/sablotron-0.44.ebuild,v 1.2 2000/11/01 04:44:13 achim Exp $ - -A="Sablot-${PV}.tar.gz Sablot-Expat-1.1.2.tar.gz" -S=${WORKDIR}/Sablot-${PV} -DESCRIPTION="An XSLT Parser in C++" -SRC_URI="http://www.gingerall.com/perl/rd?url=sablot/Sablot-${PV}.tar.gz - http://www.gingerall.com/perl/rd?url=sablot/Sablot-Expat-1.1.2.tar.gz" -HOMEPAGE="http://www.gingerall.com/charlie-bin/get/webGA/act/sablotron.act" - -DEPEND=">=sys-devel/gcc-2.95.2 - >=sys-libs/glibc-2.1.3" - -src_unpack() { - unpack Sablot-${PV}.tar.gz - cd ${S} - unpack Sablot-Expat-1.1.2.tar.gz -} -src_compile() { - - cd ${S} - try ./configure --prefix=/usr --host=${CHOST} - try make - -} - -src_install () { - - cd ${S} - dodir /usr/lib - dodir /usr/include - dodir /usr/bin - try make prefix=${D}/usr install - dodoc README - dodoc Sablot/RELEASE Sablot/TODO - docinto html/expat - dodoc Expat/distribution/expat.html -} - - - diff --git a/app-text/ttf2pt1/files/digest-ttf2pt1-3.3.0 b/app-text/ttf2pt1/files/digest-ttf2pt1-3.3.0 deleted file mode 100644 index 8266ad48f3f8..000000000000 --- a/app-text/ttf2pt1/files/digest-ttf2pt1-3.3.0 +++ /dev/null @@ -1 +0,0 @@ -MD5 ae685fc836bee971b168e6f92c7ce3c2 ttf2pt1-3.3.0.tgz diff --git a/app-text/ttf2pt1/ttf2pt1-3.3.0.ebuild b/app-text/ttf2pt1/ttf2pt1-3.3.0.ebuild deleted file mode 100644 index cdc157eb3d9a..000000000000 --- a/app-text/ttf2pt1/ttf2pt1-3.3.0.ebuild +++ /dev/null @@ -1,37 +0,0 @@ -# Copyright 1999-2000 Gentoo Technologies, Inc. -# Distributed under the terms of the GNU General Public License, v2 or later -# Author Achim Gottinger <achim@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/app-text/ttf2pt1/ttf2pt1-3.3.0.ebuild,v 1.2 2000/11/01 04:44:14 achim Exp $ - -A=${P}.tgz -S=${WORKDIR}/${P} -DESCRIPTION="Converts True Type to Type 1 fonts" -SRC_URI="http://download.sourceforge.net/ttf2pt1/${A}" -HOMEPAGE="http://ttf2pt1.sourceforge.net" - -DEPEND=">=sys-libs/glibc-2.1.3" - -src_unpack() { - unpack ${A} - cd ${S} - cp Makefile Makefile.orig - sed -e "s:CFLAGS= -O:CFLAGS= ${CFLAGS}:" Makefile.orig > Makefile - -} - -src_compile() { - - cd ${S} - try make all - -} - -src_install () { - - cd ${S} - into /usr - dobin t1asm ttf2pfa ttf2pt1 - dodoc CHANGES COPYRIGHT README - -} - |