The graph-build-time help text currently looks like this:
usage: graph-build-time [-h] [--type GRAPH_TYPE] [--order GRAPH_ORDER]
[--alternate-colors] [--input OUTPUT] --output OUTPUT
Obviously, naming the parameter for --input as OUTPUT is not a very
good idea, so this commit fixes that to name it "INPUT", as expected.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Currently the graph-build-time script prints a python exception if a
needed module cannot be imported. Catch the exception and tell the user
which packages are missing, as we do for other missing dependencies.
Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
This instruction in the middle of 'import' lines looks very strange.
Also, it was not obvious to me what the 'Agg' backend is.
Both things are actually correct, but it took a while to find out why.
So clarify with a comment to save someone else's time.
[Peter: fix s/soe/some/ typo]
Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Cc: Sascha Arthur <sascha.arthur@gmail.com>
Cc: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
This patch is the result of 2to3.
Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Tested-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
As Samuel said:
In Python, None is a singleton, and it is recommended to use "is" or
"is not" for testing them [1].
[1] http://legacy.python.org/dev/peps/pep-0008/#programming-recommendations
Reported-by: Samuel Martin <s.martin49@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Some magic numbers obtained with trial-and-error and successive
iterations, to eventually get a nice graph.
[Thomas: remove excessive spaces in expressions.]
Reported-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
PDF files can not be easily embedded in other documents (eg. ODT, or HTML).
Add support for generating PNG graphs, by setting the GRAPH_OUT=pdf|png on
the command line:
make GRAPH_OUT=png graph-build graph-depends
The default is still to generate PDF graphs.
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
This script generates graphs of packages build time, from the timing
data generated by Buildroot in the $(O)/build-time.log file.
Example usage:
./support/scripts/graph-build-time \
--type=histogram --input=$(O)/build-time.log --output=foobar.pdf
Three graph types are available :
* histogram, which creates an histogram of the build time for each
package, decomposed by each step (extract, patch, configure,
etc.). The order in which the packages are shown is
configurable: by package name, by build order, or by duration
order. See the --order option.
* pie-packages, which creates a pie chart of the build time of
each package (without decomposition in steps). Packages that
contributed to less than 1% of the overall build time are all
grouped together in an "Other" entry.
* pie-steps, which creates a pie chart of the time spent globally
on each step (extract, patch, configure, etc...)
The default is to generate an histogram ordered by package name.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
[yann.morin.1998@free.fr: adapt to the format of the step-hooks build-time.log,
add sort order by name, default to name-ordered histogram, use our colours
for pie-charts, add alternate color-scheme, add short-options, add
--input/-i]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>