bug-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: FW: [gnu.org #219540] Suggestion


From: Paul D. Smith
Subject: Re: FW: [gnu.org #219540] Suggestion
Date: Wed, 26 Jan 2005 13:33:56 -0500

%% "Cris" <address@hidden> writes:

  >> Has anyone considered adding a module to gmake which shows the
  >> progress of a make or the estimated time left?
  >> 
  >> Maybe something as simple as an echo which tells you the completion
  >> percentage based on the number of lines completed in the Makefile.
  >> 
  >> I hate watching or flicking back and forth between terminal for
  >> something to build with no indication with how much is completed.

The problem is that make has absolutely no idea when it will be done.
Make reads the makefile, then starts at the first target and builds
things that need to be built, until nothing else needs to be built; then
it's done.

Make has no idea how many of the targets in the makefile will actually
be built during any given invocation, so it cannot provide an estimate
of what percentage complete it is.  And of course there's no way make
can know how _long_ any given target will take to build, so even if it
knew how many were left, an estimate of the estimated time to completion
is right out.


There is a patch on the GNU make Savannah site which tries to add this
functionality; it does this by having make run through once with the "no
build" flag, to see how many things would be built, then doing it a
second time actually building things.

Of course this is not 100% accurate since in some makefiles building one
target will cause other targets to not need to be built and that can't
be determined until the build is actually done, but it's mostly
accurate, at the price of some performance.

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <address@hidden>          Find some GNU make tips at:
 http://www.gnu.org                      http://make.paulandlesley.org
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist




reply via email to

[Prev in Thread] Current Thread [Next in Thread]