Subject: Re: pkgsrc progress bar?
To: None <tech-pkg@NetBSD.org>
From: Jeremy C. Reed <email@example.com>
Date: 01/20/2005 13:26:53
On Thu, 20 Jan 2005, Hubert Feyrer wrote:
> On Thu, 20 Jan 2005, Jeremy C. Reed wrote:
> > I say it is not possible because there are too many variables: different
> > operating systems, different compilers, different dependencies (native
> > versus pkgsrc for example), different supplementary tools (like sed, awk,
> > grep). I don't see how we can estimate how long something takes. And
> > building some database of known build times won't scale well. Even my AMD
> > K6-400 machines builds many packages faster than my 1000Mhz+ machines.
> Run the following command
> sh -c 's=2; for i in `jot 5` ; do date ; sleep $s ; done' \
> | progress -l 145 dd of=/dev/null
> Change the value of the 's' variable and you'll see that the output will
> be about the same. The only constant in there is the lenth of the output,
> and it shouln't matter too much if there a few bytes more or less.
> Saving these numbers is probably trivial during regular builds, just
> capture the numbers: make $BUILD_TARGET | tee /dev/tty | wc -l
Will this work when one step (one line) takes 25 minutes and 100 steps
(100 lines) takes a few seconds? Will the progress bar show how much
"time" or how many lines?
Jeremy C. Reed
BSD News, BSD tutorials, BSD links