Skip to content
  • Paul Spooren's avatar
    scripts: JSON merge don't crash if no JSON found · 14cbd8fb
    Paul Spooren authored
    
    
    The JSON `WORK_DIR` ($(KDIR)/json_info_files) is only created if the new
    image generation methods from `image.mk` are used. However some targets
    like `armvirt` do not use it yet, so the folder is never created.
    
    The `json_overview_image_info.py` script used to raise an error if the
    given `WORK_DIR` isn't a folder, however it should just notify about
    missing JSON files.
    
    This patch removes the Python assert and exists with code 0 even if no
    JSON files were found, as this is not necessarily an error but simply
    not yet implemented. Using `glob` on an not existing `Path` results in
    an empty list, therefore the for loop won't run.
    
    Signed-off-by: default avatarPaul Spooren <mail@aparcar.org>
    CC: Petr Štetiar <ynezz@true.cz>
    14cbd8fb