[PATCH v4 00/83] buildman: Refactor code and correct some pylint warnings
Simon Glass
sjg at chromium.org
Thu Jul 20 01:48:08 CEST 2023
The buildman code has grown considerable since it was originally written.
In places it can be quite hard to understanding and work with.
This series improves things, particularly in the control and builder
parts, splitting functions into smaller sizes.
More work remains in buildthead._write_result() and other places.
Changes in v4:
- Reword the warning message
- Use search() instead of fullmatch() to allow partial matches
- Add new patch to sort the maintainer warnings
- Add new patch to correct logic for missing maintainers
Changes in v3:
- Add new patch to fix verboose typo and add comment
- Add new patch to allow --debug to enable debugging
- Add new patch to exit with the return code consistently
- Add new patch to rename the ARM boards
- Add new patch to drop dead code to handle :CONFIG_ construct
- Add new patch to avoid globals in leaf functions
- Add new patch with a test for Boards.scan_defconfigs()
- Add new patch with a test for Boards.output_is_new()
- Add new patch with a partial test for ensure_board_list()
- Add new patch to tidy up common code in parse_file()
- Add new patch to warn about dangling maintainer entries
- Add new patch to refactor target handling in Boards.scan()
- Add new patch to detect boards with multiple CONFIG_TARGETs defined
- Add new patch to detect boards with no CONFIG_TARGET defined
- Add new patch to correct operation of MAINTAINERS N:
- Add new patch to display a single line for missing maintainers
- Add new patch with an option to check maintainers
- Use the new --maintainer-check option in CI
- Add new patch to test for excluding things
- Correct test failure when using incorrect variable
- Fix 'scrop' typo
- Add new patch to use -D for --debug
- Add new patch with an option to check maintains and targets
- Fix 'bulidman' typo in three patches
Changes in v2:
- Correct operation of -A
- Use snake case for tests
- Add new patch to print the architecture for a board
- Drop patch to move -A logic up a little (since it breaks it)
Simon Glass (83):
buildman: Fix verboose typo and add comment
buildman: Allow --debug to enable debugging
buildman: Exit with the return code consistently
buildman: Rename the ARM boards
buildman: Drop dead code to handle :CONFIG_ construct
buildman: Avoid globals in leaf functions
buildman: Add a test for Boards.scan_defconfigs()
buildman: Add a test for Boards.output_is_new()
buildman: Add a partial test for ensure_board_list()
buildman: Tidy up common code in parse_file()
buildman: Warn about dangling maintainer entries
buildman: Refactor target handling in Boards.scan()
buildman: Detect boards with multiple CONFIG_TARGETs defined
buildman: Detect boards with no CONFIG_TARGET defined
buildman: Correct operation of MAINTAINERS N:
buildman: Just display a single line for missing maintainers
buildman: Sort the maintainer warnings
buildman: Correct logic for missing maintainers
buildman: Add an option to check maintainers
buildman: Provide an argument to the -R option
buildman: Tidy up pylint warnings in main
buildman: Convert camel case in control.py
buildman: Fix most pylint warnings in control
buildman: Move full-help processing to main
buildman: Move series calculations into a separate function
buildman: Move fetch-arch code into a separate function
buildman: Add a test for the -A option
buildman: Drop use of builder in show_actions()
buildman: Move dry-run handling higher in do_buildman()
buildman: Add tests for excluding things
buildman: Move board-selection code into a function
bulidman: Move more code to determine_series()
buildman: Move Boards-object code into a function
bulidman: Move toolchain handling to a function
bulldman: Set up output_dir earlier
buildman: Move output-file setup into one place
buildman: Pass option values to get_action_summary()
buildman: Pass option values to show_actions()
buildman: Build option-adjusting into a function
buildman: Move counting of commits into a function
buildman: Move setting up the output dir into a function
buildman: Move commit numbering into determine_series()
buildman: Avoid too many returns in do_buildman()
buildman: Move remaining builder properties to constructor
buildman: Tweak commits and show_bloat
buildman: Moving running of the builder into a function
buildman: Drop some unnecessary variables
buildman: Adjust show_toolchain_prefix() to not return
buildman: Move checking for make into run_builder()
buildman: Move getting the adjust_cfg into run_builder()
buildman: Use get_alow_missing() directly to avoid var
buildman: Create a function to get number of built commits
buildman: Convert camel case in cmdline.py
buildman: Correct most pylint warnings in cmdline
buildman: Add a test for --boards
buildman: Convert to argparse
buildman: Convert camel case in bsettings.py
buildman: Convert camel case in builder.py
buildman: Split parser creation in two
buildman: Convert camel case in builderthread.py
buildman: Correct most pylint warnings in builderthread
buildman: Export _get_output_dir() to avoid warnings
buildman: Correct invalid use of out_dir variable
buildman: Drop unnecessary assignment of config_out
buildman: Start a function to set up the make arguments
buildman: Move setting of toolchain arguments to _build_args()
buildman: Move more things into _build_args()
buildman: Convert config_out to string IO
buildman: Move reconfigure code into its own function
buildman: Move bulid code into its own function
buildman: Move reading of the done file into a function
buildman: Move code to remove old outputs
buildman: Move code to decide output dirs
buildman: Move checkout code to a separate function
buildman: Create a function to handle config and build
buildman: Avoid passing result into _read_done_file()
buildman: Tidy up reporting of a toolchain error
buildman: Tidy up some comments in builderthread
buildman: Move copy_files() out ot BuilderThread class
buildman: Add a way to print the architecture for a board
buildman: Use -D for --debug
buildman: Add an option to check maintainers and targets
buildman: Enable test coverage
.azure-pipelines.yml | 2 +-
.gitlab-ci.yml | 2 +-
tools/buildman/board.py | 6 +-
tools/buildman/boards.py | 259 ++++--
tools/buildman/bsettings.py | 14 +-
tools/buildman/builder.py | 262 +++---
tools/buildman/builderthread.py | 652 +++++++++------
tools/buildman/buildman.rst | 32 +-
tools/buildman/cmdline.py | 180 ++--
tools/buildman/control.py | 790 ++++++++++++------
tools/buildman/func_test.py | 328 +++++++-
tools/buildman/main.py | 71 +-
tools/buildman/test.py | 28 +-
tools/buildman/test/Kconfig | 72 ++
tools/buildman/test/boards/board0/MAINTAINERS | 5 +
tools/buildman/test/boards/board2/MAINTAINERS | 5 +
tools/buildman/test/configs/board0_defconfig | 1 +
tools/buildman/test/configs/board2_defconfig | 1 +
tools/buildman/toolchain.py | 14 +-
tools/moveconfig.py | 2 +-
tools/u_boot_pylib/test_util.py | 10 +-
21 files changed, 1867 insertions(+), 869 deletions(-)
create mode 100644 tools/buildman/test/Kconfig
create mode 100644 tools/buildman/test/boards/board0/MAINTAINERS
create mode 100644 tools/buildman/test/boards/board2/MAINTAINERS
create mode 100644 tools/buildman/test/configs/board0_defconfig
create mode 100644 tools/buildman/test/configs/board2_defconfig
--
2.41.0.487.g6d72f3e995-goog
More information about the U-Boot
mailing list