diff options
author | rillig <rillig@pkgsrc.org> | 2005-11-05 10:14:43 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2005-11-05 10:14:43 +0000 |
commit | d0f4a6c3e3253774e6a926cb8d92c2a36be4250d (patch) | |
tree | ff7a3034b39bd7519a9470ec7c52ee5dc69883aa /mk/bulk | |
parent | 3d8a07e3a26fe89c5824888b1eaedbbc2f929697 (diff) | |
download | pkgsrc-d0f4a6c3e3253774e6a926cb8d92c2a36be4250d.tar.gz |
As the printdepends program takes quite a long time, every 50 packages a
status line is printed on stderr to get an impression about how the
program gets along.
Diffstat (limited to 'mk/bulk')
-rw-r--r-- | mk/bulk/printdepends | 23 |
1 files changed, 18 insertions, 5 deletions
diff --git a/mk/bulk/printdepends b/mk/bulk/printdepends index cfa95a8d0c5..ec48a807be8 100644 --- a/mk/bulk/printdepends +++ b/mk/bulk/printdepends @@ -1,5 +1,5 @@ #!/bin/sh -# $NetBSD: printdepends,v 1.17 2005/05/09 16:03:58 kristerw Exp $ +# $NetBSD: printdepends,v 1.18 2005/11/05 10:14:43 rillig Exp $ # # Copyright (c) 1999, 2000 Hubert Feyrer <hubertf@NetBSD.org> @@ -78,6 +78,15 @@ fi # cache the package list for printindex echo list='"'${list}'"' > .pkglist +pkgbar="" +for i in $list; do + pkgbar="${pkgbar} a" +done +npackages=`echo "$pkgbar" | wc -w` +npackages=`echo $npackages` + +cpackages=0 +cpackages_mod_50="" for pkgdir in $list do if [ ! -d $pkgdir ]; then @@ -85,9 +94,7 @@ do echo $pkgdir | ${SED} 's;/.*;/Makefile;g' > /dev/stderr echo "but the directory does not exist. Please fix this!" > /dev/stderr else - cd $pkgdir - - l=`${BMAKE} show-depends-dirs` + l=`cd $pkgdir && ${BMAKE} show-depends-dirs` if [ $? != 0 ]; then echo "WARNING (printdepends): the package in $pkgdir had problem with" > /dev/stderr echo " ${BMAKE} show-depends-dirs" > /dev/stderr @@ -108,5 +115,11 @@ do fi fi fi - cd $cwd + cpackages_mod_50="${cpackages_mod_50}+"; + case $cpackages_mod_50 in + ++++++++++++++++++++++++++++++++++++++++++++++++++) + cpackages_mod_50="" + cpackages=`expr $cpackages + 50` + echo "${cpackages} of ${npackages} packages finished." 1>&2;; + esac done |