mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-03-31 03:21:32 +00:00
moveconfig: Add a switch to only cleanup headers
In some case you may want to only cleanup the headers. Make it possible without waiting for all boards to compile. Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Acked-by: Masahiro Yamada <yamada.masahiro@socionext.com>
This commit is contained in:
parent
91040e8530
commit
2144f88044
1 changed files with 12 additions and 5 deletions
|
@ -146,6 +146,9 @@ Available options
|
||||||
Exit immediately if Make exits with a non-zero status while processing
|
Exit immediately if Make exits with a non-zero status while processing
|
||||||
a defconfig file.
|
a defconfig file.
|
||||||
|
|
||||||
|
-H, --headers-only
|
||||||
|
Only cleanup the headers; skip the defconfig processing
|
||||||
|
|
||||||
-j, --jobs
|
-j, --jobs
|
||||||
Specify the number of threads to run simultaneously. If not specified,
|
Specify the number of threads to run simultaneously. If not specified,
|
||||||
the number of threads is the same as the number of CPU cores.
|
the number of threads is the same as the number of CPU cores.
|
||||||
|
@ -720,8 +723,6 @@ def move_config(config_attrs, options):
|
||||||
the type, and the default value of the target config.
|
the type, and the default value of the target config.
|
||||||
options: option flags
|
options: option flags
|
||||||
"""
|
"""
|
||||||
check_top_directory()
|
|
||||||
|
|
||||||
if len(config_attrs) == 0:
|
if len(config_attrs) == 0:
|
||||||
print 'Nothing to do. exit.'
|
print 'Nothing to do. exit.'
|
||||||
sys.exit(0)
|
sys.exit(0)
|
||||||
|
@ -765,8 +766,6 @@ def move_config(config_attrs, options):
|
||||||
|
|
||||||
slots.show_failed_boards()
|
slots.show_failed_boards()
|
||||||
|
|
||||||
cleanup_headers(config_attrs, options.dry_run)
|
|
||||||
|
|
||||||
def bad_recipe(filename, linenum, msg):
|
def bad_recipe(filename, linenum, msg):
|
||||||
"""Print error message with the file name and the line number and exit."""
|
"""Print error message with the file name and the line number and exit."""
|
||||||
sys.exit("%s: line %d: error : " % (filename, linenum) + msg)
|
sys.exit("%s: line %d: error : " % (filename, linenum) + msg)
|
||||||
|
@ -854,6 +853,9 @@ def main():
|
||||||
parser.add_option('-e', '--exit-on-error', action='store_true',
|
parser.add_option('-e', '--exit-on-error', action='store_true',
|
||||||
default=False,
|
default=False,
|
||||||
help='exit immediately on any error')
|
help='exit immediately on any error')
|
||||||
|
parser.add_option('-H', '--headers-only', dest='cleanup_headers_only',
|
||||||
|
action='store_true', default=False,
|
||||||
|
help='only cleanup the headers')
|
||||||
parser.add_option('-j', '--jobs', type='int', default=cpu_count,
|
parser.add_option('-j', '--jobs', type='int', default=cpu_count,
|
||||||
help='the number of jobs to run simultaneously')
|
help='the number of jobs to run simultaneously')
|
||||||
parser.usage += ' recipe_file\n\n' + \
|
parser.usage += ' recipe_file\n\n' + \
|
||||||
|
@ -874,7 +876,12 @@ def main():
|
||||||
|
|
||||||
update_cross_compile()
|
update_cross_compile()
|
||||||
|
|
||||||
move_config(config_attrs, options)
|
check_top_directory()
|
||||||
|
|
||||||
|
if not options.cleanup_headers_only:
|
||||||
|
move_config(config_attrs, options)
|
||||||
|
|
||||||
|
cleanup_headers(config_attrs, options.dry_run)
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
main()
|
main()
|
||||||
|
|
Loading…
Add table
Reference in a new issue