aboutsummaryrefslogtreecommitdiffstats
path: root/news
diff options
context:
space:
mode:
authorhoek <hoek@FreeBSD.org>1998-09-06 04:40:09 +0800
committerhoek <hoek@FreeBSD.org>1998-09-06 04:40:09 +0800
commita253ef5c2a94828e16fbc0b5e9d5c44eba11fc72 (patch)
tree15e8ddad68a5c2a73f2c6aaec88c82fcca99b497 /news
parentf55dd562d25c4f62c6ed7346d07272e86ecb9d2a (diff)
downloadfreebsd-ports-gnome-a253ef5c2a94828e16fbc0b5e9d5c44eba11fc72.tar.gz
freebsd-ports-gnome-a253ef5c2a94828e16fbc0b5e9d5c44eba11fc72.tar.zst
freebsd-ports-gnome-a253ef5c2a94828e16fbc0b5e9d5c44eba11fc72.zip
Don't assume env TMPDIR is defined.
PR: ports/7838
Diffstat (limited to 'news')
-rw-r--r--news/slurp/scripts/configure13
1 files changed, 8 insertions, 5 deletions
diff --git a/news/slurp/scripts/configure b/news/slurp/scripts/configure
index 894bc907041a..ac641dd012ba 100644
--- a/news/slurp/scripts/configure
+++ b/news/slurp/scripts/configure
@@ -1,18 +1,21 @@
#!/bin/sh
#
-# $Id$
+# $Id: configure,v 1.1 1997/11/13 23:14:58 jraynard Exp $
#
-echo "s!/usr/lib/news!${PREFIX}/news/lib!" > ${TMPDIR}/tmp.slurp.sed.$$
+TMPFILE=${TMPDIR:-/tmp}/tmp.slurp.sed.$$
+trap 'rm -f ${TMPFILE}' 1 2 13 15
+
+echo "s!/usr/lib/news!${PREFIX}/news/lib!" > ${TMPFILE}
if [ -d /var/news ]
then
- echo 's!/var/spool!/var!' >> ${TMPDIR}/tmp.slurp.sed.$$
+ echo 's!/var/spool!/var!' >> ${TMPFILE}
fi
-sed -f ${TMPDIR}/tmp.slurp.sed.$$ < ${WRKSRC}/conf.h > ${WRKSRC}/conf.h.tmp
+sed -f ${TMPFILE} < ${WRKSRC}/conf.h > ${WRKSRC}/conf.h.tmp
mv ${WRKSRC}/conf.h.tmp ${WRKSRC}/conf.h
-rm -f ${TMPDIR}/tmp.slurp.sed.$$
+rm -f ${TMPFILE}
rm -f ${WRKDIR}/syslog.h