[MacPorts] #15939: port install : in need of a progressbar
MacPorts
noreply at macports.org
Mon Mar 12 12:40:28 UTC 2018
#15939: port install : in need of a progressbar
--------------------------+--------------------------------
Reporter: pc@… | Owner: macports-tickets@…
Type: enhancement | Status: new
Priority: Low | Milestone: MacPorts 2.6.0
Component: base | Version: 1.6.0
Resolution: | Keywords:
Port: |
--------------------------+--------------------------------
Comment (by RJVB):
> A first iteration could probably just move a progress indicator (not a
progress bar!) when a new line was printed by the build system.
That should be easy, IIRC all output already goes through single Tcl
function. It probably should also be a bit more elaborate than updating
the indicator on every new line (instead, update every N lines, where N is
determined from some sliding average over the number of lines printed per
second?).
See my comments above. The way to go is probably via a hook/callback
approach where different buildsystems can provide progress information.
CMake is probably not the only such system that can provide the required
information.
Muniversal builds are an annoyance in this matter, but only if you think
you have to hide the fact that such a build is going on. Assuming that a
display progress information is to be optional it's logical to assume that
users who are interested in this are also not uninterested in knowing what
part is being built. (I already patch my local muniversal PG so it tells
me that.)
The alternative is a simple *approximation*: scale by the number of
architectures. If the returned progress information is a
(currentFile,numberOfFiles) pair, multiply numberOfFiles by the number of
architectures and you're set. When the returned information is already a
percentage, divide it by that number and treat it as if on a circular
scale (progress from ((100/N -i)% to j% would become (100/N +j)%).
--
Ticket URL: <https://trac.macports.org/ticket/15939#comment:21>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list