summaryrefslogtreecommitdiff
path: root/mk/bulk
diff options
context:
space:
mode:
authordmcmahill <dmcmahill@pkgsrc.org>2000-12-29 15:56:26 +0000
committerdmcmahill <dmcmahill@pkgsrc.org>2000-12-29 15:56:26 +0000
commit6b1411fce4b7f62f445aab5b44ee01992bef0e7c (patch)
treea663b04026b48e8790f5075cd0f01be8833cd451 /mk/bulk
parent0cd363dca1c181ea7acce3e1c81f7eee006eea7f (diff)
downloadpkgsrc-6b1411fce4b7f62f445aab5b44ee01992bef0e7c.tar.gz
add hostname and pid to the temp makefile name to avoid conflicts when
pkgsrc is shared via nfs where multiple machines may want to run the script at the same time. Also avoid conflicts if multiple copies are run on the same machine at once.
Diffstat (limited to 'mk/bulk')
-rw-r--r--mk/bulk/printdepends10
1 files changed, 5 insertions, 5 deletions
diff --git a/mk/bulk/printdepends b/mk/bulk/printdepends
index 6396e0316b7..82141c69bae 100644
--- a/mk/bulk/printdepends
+++ b/mk/bulk/printdepends
@@ -1,5 +1,5 @@
#!/bin/sh
-# $NetBSD: printdepends,v 1.3 2000/11/18 07:30:25 hubertf Exp $
+# $NetBSD: printdepends,v 1.4 2000/12/29 15:56:26 dmcmahill Exp $
#
# Print list of pkg dependencies suitable for tsort(1).
# Start in /usr/pkgsrc.
@@ -17,10 +17,10 @@ cwd=$PWD
#list=x11/gnome
#list='x11/xteddy x11/xsnow'
-
+mf=$cwd/.m.`hostname`.$$
# Makefile to print the DEPENDS' and BUILD_DEPENDS' directory parts
# bsd.pkg.mk is pulled in via the Makefile
-cat >$cwd/.m <<EOF
+cat >$mf <<EOF
bla:
@echo \${DEPENDS:C/^[^:]*://:C/:.*$//} \${BUILD_DEPENDS:C/^[^:]*://:C/:.*$//}
.include "Makefile"
@@ -31,7 +31,7 @@ for pkgdir in $list
do
cd $pkgdir
- l=`make -f - <$cwd/.m bla` # XXX NOT -f $cwd/.m !
+ l=`make -f - <$mf bla` # XXX NOT -f $mf !
if [ "$l" = "" ]; then
# No dependencies
echo "$pkgdir $pkgdir"
@@ -48,4 +48,4 @@ do
cd $cwd
done
-rm -f $cwd/.m
+rm -f $mf