path: root/tools/buildman/
Commit message (Collapse)AuthorAgeFilesLines
* buildman: allow more incremental buildingStephen Warren2016-05-171-8/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | One use-case for buildman is to continually run it interactively after each small step in a large refactoring operation. This gives more immediate feedback than making a number of commits and then going back and testing them. For this to work well, buildman needs to be extremely fast. At present, a couple issues prevent it being as fast as it could be: 1) Each time buildman runs "make %_defconfig", it runs "make mrproper" first. This throws away all previous build results, requiring a from-scratch build. Optionally avoiding this would speed up the build, at the cost of potentially causing or missing some build issues. 2) A build tree is created per thread rather than per board. When a thread switches between building different boards, this often causes many files to be rebuilt due to changing config options. Using a separate build tree for each board would avoid this. This does put more strain on the system's disk cache, but it is worth it on my system at least. This commit adds two command-line options to implement the changes described above; -I ("--incremental") turns of "make mrproper" and -P ("--per-board-out-dir") creats a build directory per board rather than per thread. Tested: ./tools/buildman/ tegra ./tools/buildman/ -I -P tegra ./tools/buildman/ -b tegra_dev tegra ./tools/buildman/ -b tegra_dev -I -P tegra ... each once after deleting the buildman result/work directory, and once "incrementally" after a previous identical invocation. Signed-off-by: Stephen Warren <> Reviewed-by: Tom Rini <> Acked-by: Simon Glass <> # v1 Tested-by: Simon Glass <> # v1 Acked-by: Simon Glass <>
* Keep 'SPL'Tom Rini2015-07-141-1/+1
| | | | | | | | | On i.MX platforms the SPL binary is called "SPL" so make sure we keep that. Cc: Simon Glass <> Signed-off-by: Tom Rini <> Acked-by: Simon Glass <>
* buildman: Make -V (verbose_build) really be verboseTom Rini2015-04-181-1/+3
| | | | | | | | | | The help text for -V says we will pass V=1 but all it really did was not pass in -s. Change the logic to pass make V=1 with given to buildman -V or -s to make otherwise. Cc: Simon Glass <> Signed-off-by: Tom Rini <> Acked-by: Simon Glass <>
* buildman: Keep more outputs with the --keep-outputs flagTom Rini2015-04-181-4/+3
| | | | | | | | | | | | | When told to keep outputs, be much more liberal in what files we keep. In addition to adding 'MLO', keep anything that matches u-boot-spl.* (so that we keep the map file as well) and anything we generate about 'u-boot itself. A large number of bootable formats now match this and thus it's easier to build many targets and then boot them afterwards using buildman. Cc: Simon Glass <> Signed-off-by: Tom Rini <> Acked-by: Simon Glass <>
* buildman: Store build config filesSimon Glass2015-04-181-7/+29
| | | | | | Store all config file output so that we can compare changes if requested. Signed-off-by: Simon Glass <>
* buildman: Adjust the 'aborted' heuristic for writing outputSimon Glass2015-04-181-5/+16
| | | | | | | | | | | | | | | | | | | | | | | | At present buildman tries to detect an aborted build and doesn't record a result in that case. This is to make sure that an abort (e.g. with Ctrl-C) does not mark the build as done. Without this option, buildman would never retry the build unless -f/-F are provided. The effect is that aborting the build creates 'fake errors' on whatever builds buildman happens to be working on at the time. Unfortunately the current test is not reliable and this detection can trigger if a required toolchain tool is missing. In this case the toolchain problem is never reported. Adjust the logic to continue processing the build result, mark the build as done (and failed), but with a return code which indicates that it should be retried. The correct fix is to fully and correctly detect an aborted build, quit buildman immediately and not write any partial build results in this case. Unfortunately this is currently beyond my powers and is left as an exercise for the reader (and patches are welcome). Signed-off-by: Simon Glass <>
* buildman: Show 'make' command line when -V is usedSimon Glass2015-04-181-1/+4
| | | | | | | When a verbose build it selected, show the make command before the output of that command. Signed-off-by: Simon Glass <>
* buildman: Add an option to write the full build outputSimon Glass2015-01-141-1/+2
| | | | | | | | Normally buildman runs with 'make -s' meaning that only errors and warnings appear in the log file. Add a -V option to run make in verbose mode, and with V=1, causing a full build log to be created. Signed-off-by: Simon Glass <>
* buildman: Add an option to use the full tool chain pathSimon Glass2015-01-141-2/+2
| | | | | | | | | | | | | | In some cases there may be multiple toolchains with the same name in the path. Provide an option to use the full path in the CROSS_COMPILE environment variable. Note: Wolfgang mentioned that this is dangerous since in some cases there may be other tools on the path that are needed. So this is set up as an option, not the default. I will need test confirmation (i.e. that this commit fixes a real problem) before merging it. Signed-off-by: Simon Glass <> Suggested-by: Steve Rae <>
* buildman: Save *.img files tooTom Rini2014-11-261-1/+1
| | | | | | | | When saving binary files we likely want to keep any .img files that have been generated as well. Signed-off-by: Tom Rini <> Acked-by: Simon Glass <>
* buildman: Create parent directories as necessaryThierry Reding2014-09-091-2/+5
| | | | | | | | | When creating build directories also create parents as necessary. This fixes a failure when building a hierarchical branch (i.e. foo/bar). Signed-off-by: Thierry Reding <> Acked-by: Simon Glass <> Tested-by: Tom Rini <>
* buildman: Correct counting of build failures on retrySimon Glass2014-09-091-7/+8
| | | | | | | | | | | | When a build is to be performed, buildman checks to see if it has already been done. In most cases it will not bother trying again. However, it was not reading the return code from the 'done' file, so if the result was a failure, it would not be counted. This depresses the 'failure' count stats that buildman prints in this case. Fix this bug by always reading the return code. Signed-off-by: Simon Glass <>
* buildman: Remove the directory prefix from each error lineSimon Glass2014-09-051-1/+3
| | | | | | | | | | | | | | | | | | | | The full path is long and also includes buildman private directories. Clean this up, so that only a relative U-Boot path is shown. This will change warnings like these: /home/sjg/c/src/third_party/u-boot/buildman5/.bm-work/00/arch/sandbox/cpu/cpu.c: In function 'timer_get_us': /home/sjg/c/src/third_party/u-boot/buildman5/.bm-work/00/arch/sandbox/cpu/cpu.c:40:9: warning: unused variable 'i' [-Wunused-variable] /home/sjg/c/src/third_party/u-boot/files/arch/sandbox/cpu/cpu.c: In function 'timer_get_us': /home/sjg/c/src/third_party/u-boot/files/arch/sandbox/cpu/cpu.c:40:9: warning: unused variable 'i' [-Wunused-variable] to: arch/sandbox/cpu/cpu.c: In function 'timer_get_us': arch/sandbox/cpu/cpu.c:40:9: warning: unused variable 'i' [-Wunused-variable] Signed-off-by: Simon Glass <>
* Makefile: remove generated boards.cfg within make distcleanRoger Meier2014-08-221-3/+3
| | | | | | | | | Signed-off-by: Roger Meier <> Reviewed-by: Masahiro Yamada <> Tested-by: Masahiro Yamada <> Cc: Tom Rini <> Cc: Wolfgang Denk <> Cc: Simon Glass <>
* buildman: Move BuilderThread code to its own fileSimon Glass2014-08-131-0/+434
The file is getting too long, so split out some code. Signed-off-by: Simon Glass <>
OpenPOWER on IntegriCloud