diff options
author | dmcmahill <dmcmahill@pkgsrc.org> | 2001-07-13 15:14:57 +0000 |
---|---|---|
committer | dmcmahill <dmcmahill@pkgsrc.org> | 2001-07-13 15:14:57 +0000 |
commit | 6b21173ecbf71cfa72e7a7e5daceafff4fea5996 (patch) | |
tree | 09fa7739023b7bc521ed5967e9c0592482eeb599 /mk/bulk/printindex | |
parent | 4c2989abc98fc096d0986ba07760e8ff0c95e701 (diff) | |
download | pkgsrc-6b21173ecbf71cfa72e7a7e5daceafff4fea5996.tar.gz |
if a package subdirectory is listed in the category makefile, but doesn't
exist, then spit out a big warning to stderr (since we often capture stdout
for other purposes) and don't try and descend to that directory.
Diffstat (limited to 'mk/bulk/printindex')
-rw-r--r-- | mk/bulk/printindex | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/mk/bulk/printindex b/mk/bulk/printindex index 137cd8e662e..9f105612f49 100644 --- a/mk/bulk/printindex +++ b/mk/bulk/printindex @@ -1,5 +1,5 @@ #!/bin/sh -# $NetBSD: printindex,v 1.4 2001/03/31 04:09:58 dmcmahill Exp $ +# $NetBSD: printindex,v 1.5 2001/07/13 15:14:57 dmcmahill Exp $ # # # Copyright (c) 2001 The NetBSD Foundation, Inc. @@ -56,9 +56,15 @@ list=`grep '^[[:space:]]*'SUBDIR */Makefile | sed 's,/Makefile.*=[[:space:]]*,/, for pkgdir in $list do - cd $pkgdir - pkgname=`make show-var VARNAME=PKGNAME` - echo "$pkgdir $pkgname " + if [ ! -d $pkgdir ]; then + echo "WARNING: the package directory $pkgdir is listed in" > /dev/stderr + echo $pkgdir | sed 's;/.*;/Makefile;g' > /dev/stderr + echo "but the directory does not exist. Please fix this!" > /dev/stderr + else + cd $pkgdir + pkgname=`make show-var VARNAME=PKGNAME` + echo "$pkgdir $pkgname " + fi cd $cwd done |